Skip to content

Commit

Permalink
调整 FloatBar 组件的渲染逻辑,支持报告模式下的只读状态
Browse files Browse the repository at this point in the history
  • Loading branch information
chenshuai2144 committed Nov 13, 2024
1 parent 06dbca5 commit 79b382d
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/MarkdownEditor/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -389,7 +389,13 @@ export const MarkdownEditor: React.FC<MarkdownEditorProps> = (props) => {
{...rest}
instance={instance}
/>
{readonly ? <FloatBar readonly /> : <FloatBar readonly={false} />}
{readonly ? (
props.reportMode ? (
<FloatBar readonly />
) : null
) : (
<FloatBar readonly={false} />
)}
{instance.current &&
mount &&
toc !== false &&
Expand Down

1 comment on commit 79b382d

@vercel
Copy link

@vercel vercel bot commented on 79b382d Nov 13, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.