-
Notifications
You must be signed in to change notification settings - Fork 516
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: 修改MarkdownDemo和RichTextEditorDemo的内容结构
- Loading branch information
Showing
4 changed files
with
41 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,21 @@ | ||
import React from "react"; | ||
import { Card } from "antd"; | ||
import Markdown from "@/components/Markdown"; | ||
export default () => { | ||
return <Markdown />; | ||
import TypingCard from "@/components/TypingCard"; | ||
|
||
const MarkdownDemo = () => { | ||
const cardContent = ` | ||
此页面用到的Markdown编辑器是<a href="https://github.com/nhn/tui.editor/tree/master/apps/react-editor" target="_blank">tui.editor(React版)</a>。 | ||
`; | ||
return ( | ||
<div className="app-container"> | ||
<TypingCard title="新手引导" source={cardContent} /> | ||
<br /> | ||
<Card bordered={false}> | ||
<Markdown /> | ||
</Card> | ||
</div> | ||
); | ||
}; | ||
|
||
export default MarkdownDemo; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,18 @@ | ||
import React from "react"; | ||
import RichTextEditor from "@/components/RichTextEditor"; | ||
export default () => { | ||
return <RichTextEditor />; | ||
import TypingCard from "@/components/TypingCard"; | ||
|
||
const RichTextEditorDemo = () => { | ||
const cardContent = ` | ||
此页面用到的富文本编辑器是<a href="https://github.com/jpuri/react-draft-wysiwyg">react-draft-wysiwyg</a>。 | ||
` | ||
return ( | ||
<div className="app-container"> | ||
<TypingCard title="新手引导" source={cardContent} /> | ||
<br /> | ||
<RichTextEditor /> | ||
</div> | ||
); | ||
}; | ||
|
||
export default RichTextEditorDemo; |