mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-11 20:08:37 +00:00
fix(core): disable doc info and backlinks in readonly mode (#6033)
close AFF-671 <img width="1422" alt="image" src="https://github.com/toeverything/AFFiNE/assets/102217452/ef80b195-3d67-4751-82d9-12973f331798">
This commit is contained in:
@@ -1049,7 +1049,7 @@ export const PagePropertiesTable = ({ page }: { page: Doc }) => {
|
||||
// if the given page is not in the current workspace, then we don't render anything
|
||||
// eg. when it is in history modal
|
||||
|
||||
if (!manager.page) {
|
||||
if (!manager.page || manager.readonly) {
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
@@ -128,7 +128,7 @@ export const BlocksuiteDocEditor = forwardRef<
|
||||
}}
|
||||
></div>
|
||||
) : null}
|
||||
{docPage ? (
|
||||
{docPage && !page.readonly ? (
|
||||
<adapted.BiDirectionalLinkPanel doc={page} pageRoot={docPage} />
|
||||
) : null}
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user