mirror of
https://github.com/haiwen/seahub.git
synced 2025-09-10 19:29:56 +00:00
[view history/snapshot/trash file] rewrote them with react
This commit is contained in:
23
frontend/src/components/file-content-view/markdown.js
Normal file
23
frontend/src/components/file-content-view/markdown.js
Normal file
@@ -0,0 +1,23 @@
|
||||
import React from 'react';
|
||||
import MarkdownViewer from '@seafile/seafile-editor/dist/viewer/markdown-viewer';
|
||||
|
||||
import '../../css/md-file-view.css';
|
||||
|
||||
const { fileContent } = window.app.pageOptions;
|
||||
|
||||
class FileContent extends React.Component {
|
||||
render() {
|
||||
return (
|
||||
<div className="file-view-content flex-1 o-auto">
|
||||
<div className="md-content">
|
||||
<MarkdownViewer
|
||||
markdownContent={fileContent}
|
||||
showTOC={false}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default FileContent;
|
Reference in New Issue
Block a user