diff --git a/web/src/helpers/api.js b/web/src/helpers/api.js index d58487b5..73708b04 100644 --- a/web/src/helpers/api.js +++ b/web/src/helpers/api.js @@ -1,6 +1,6 @@ -import { getUserIdFromLocalStorage, showError } from './utils'; +import { getUserIdFromLocalStorage, showError, formatMessageForAPI, isValidMessage } from './utils'; import axios from 'axios'; -import { formatMessageForAPI } from './index.js'; +import { MESSAGE_ROLES } from '../constants/playground.constants'; export let API = axios.create({ baseURL: import.meta.env.VITE_REACT_APP_SERVER_URL diff --git a/web/src/helpers/render.js b/web/src/helpers/render.js index 862dd8eb..c8302feb 100644 --- a/web/src/helpers/render.js +++ b/web/src/helpers/render.js @@ -1,6 +1,6 @@ import i18next from 'i18next'; import { Modal, Tag, Typography } from '@douyinfe/semi-ui'; -import { copy, isMobile, showSuccess } from './index.js'; +import { copy, isMobile, showSuccess } from './utils'; import { visit } from 'unist-util-visit'; export function renderText(text, limit) {