fix(core): fallback when loading share page (#10428)
This commit is contained in:
@@ -189,7 +189,7 @@ const SharePageInner = ({
|
|||||||
]);
|
]);
|
||||||
|
|
||||||
const t = useI18n();
|
const t = useI18n();
|
||||||
const pageTitle = useLiveData(page?.title$) ?? t['unnamed']();
|
const pageTitle = useLiveData(page?.title$);
|
||||||
const { jumpToPageBlock, openPage } = useNavigateHelper();
|
const { jumpToPageBlock, openPage } = useNavigateHelper();
|
||||||
|
|
||||||
usePageDocumentTitle(pageTitle);
|
usePageDocumentTitle(pageTitle);
|
||||||
@@ -235,7 +235,7 @@ const SharePageInner = ({
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!workspace || !page || !editor) {
|
if (!workspace || !page || !editor) {
|
||||||
return;
|
return <AppContainer fallback />;
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
@@ -243,7 +243,7 @@ const SharePageInner = ({
|
|||||||
<FrameworkScope scope={page.scope}>
|
<FrameworkScope scope={page.scope}>
|
||||||
<FrameworkScope scope={editor.scope}>
|
<FrameworkScope scope={editor.scope}>
|
||||||
<ViewIcon icon={publishMode === 'page' ? 'doc' : 'edgeless'} />
|
<ViewIcon icon={publishMode === 'page' ? 'doc' : 'edgeless'} />
|
||||||
<ViewTitle title={pageTitle} />
|
<ViewTitle title={pageTitle ?? t['unnamed']()} />
|
||||||
<div className={styles.root}>
|
<div className={styles.root}>
|
||||||
<div className={styles.mainContainer}>
|
<div className={styles.mainContainer}>
|
||||||
<ShareHeader
|
<ShareHeader
|
||||||
|
|||||||
Reference in New Issue
Block a user