File tree Expand file tree Collapse file tree 3 files changed +6
-0
lines changed Expand file tree Collapse file tree 3 files changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -52,6 +52,9 @@ const Fullscreen: React.FC<{ command: ICommand; editorProps: IMarkdownEditor & T
5252 if ( editorProps && editorProps . container && editorProps . container . current && editorProps . editor ) {
5353 const container = editorProps . container . current ;
5454 document . body . style . overflow = full ? 'hidden' : 'initial' ;
55+ full
56+ ? document . body . classList . add ( `${ editorProps . prefixCls } -fullscreen` )
57+ : document . body . classList . remove ( `${ editorProps . prefixCls } -fullscreen` ) ;
5558 if ( container && full ) {
5659 container . style . zIndex = '999' ;
5760 container . style . position = 'fixed' ;
Original file line number Diff line number Diff line change @@ -34,6 +34,7 @@ export default function ToolBar(props: IToolBarProps) {
3434 execute ( editor . current ! ) ;
3535 }
3636 }
37+ editorProps . prefixCls = prefixCls ;
3738 return (
3839 < div
3940 className = { `${ prefixCls } -toolbar ${ className || '' } ${ mode ? `${ prefixCls } -toolbar-mode` : '' } ` }
Original file line number Diff line number Diff line change @@ -56,6 +56,7 @@ export interface IMarkdownEditor extends ReactCodeMirrorProps {
5656}
5757
5858export interface ToolBarProps {
59+ prefixCls ?: string ;
5960 editor : React . RefObject < ReactCodeMirrorRef > ;
6061 preview : React . RefObject < HTMLDivElement > ;
6162 container : React . RefObject < HTMLDivElement > ;
@@ -122,6 +123,7 @@ function MarkdownEditorInternal(
122123 ) ;
123124
124125 const toolBarProps : ToolBarProps = {
126+ prefixCls,
125127 preview : preview ,
126128 editor : codeMirror ,
127129 container : container ,
You can’t perform that action at this time.
0 commit comments