Optimize the project structure and introduce DDD design (#394)
This commit is contained in:
@@ -2,7 +2,7 @@ import React from 'react';
|
||||
import { Prism as SyntaxHighlighter } from 'react-syntax-highlighter';
|
||||
import { Box, Flex, useColorModeValue } from '@chakra-ui/react';
|
||||
import Icon from '@/components/Icon';
|
||||
import { useCopyData } from '@/hooks/useCopyData';
|
||||
import { useCopyData } from '@/web/common/hooks/useCopyData';
|
||||
|
||||
const codeLight: { [key: string]: React.CSSProperties } = {
|
||||
'code[class*=language-]': {
|
||||
|
||||
@@ -5,7 +5,7 @@ import RemarkGfm from 'remark-gfm';
|
||||
import RemarkMath from 'remark-math';
|
||||
import RehypeKatex from 'rehype-katex';
|
||||
import RemarkBreaks from 'remark-breaks';
|
||||
import { event } from '@/utils/plugin/eventbus';
|
||||
import { eventBus } from '@/web/common/utils/eventbus';
|
||||
|
||||
import 'katex/dist/katex.min.css';
|
||||
import styles from '../index.module.scss';
|
||||
@@ -27,7 +27,7 @@ function MyLink(e: any) {
|
||||
textDecoration={'underline'}
|
||||
cursor={'pointer'}
|
||||
onClick={() => {
|
||||
event.emit('guideClick', { text });
|
||||
eventBus.emit('guideClick', { text });
|
||||
}}
|
||||
>
|
||||
{text}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import React, { useMemo } from 'react';
|
||||
import { Box, useTheme } from '@chakra-ui/react';
|
||||
import { getFileAndOpen } from '@/utils/web/file';
|
||||
import { useToast } from '@/hooks/useToast';
|
||||
import { getFileAndOpen } from '@/web/common/utils/file';
|
||||
import { useToast } from '@/web/common/hooks/useToast';
|
||||
import { getErrText } from '@/utils/tools';
|
||||
|
||||
type QuoteItemType = {
|
||||
|
||||
Reference in New Issue
Block a user