mirror of
https://github.com/toeverything/AFFiNE.git
synced 2024-09-11 11:47:00 +03:00
fix(core): can't enter presentation again in share page (#7262)
Fix [TOV-916](https://linear.app/affine-design/issue/TOV-916/分享页面的-present-按钮在第二次进入演示模式时未生效)
This commit is contained in:
parent
98e35384a6
commit
f9903fd748
@ -45,13 +45,9 @@ export const PresentButton = () => {
|
||||
const edgelessPage = editorHost?.querySelector('affine-edgeless-root');
|
||||
if (!edgelessPage) return;
|
||||
|
||||
edgelessPage.slots.edgelessToolUpdated.on(() => {
|
||||
return edgelessPage.slots.edgelessToolUpdated.on(() => {
|
||||
setIsPresent(edgelessPage.edgelessTool.type === 'frameNavigator');
|
||||
});
|
||||
|
||||
return () => {
|
||||
edgelessPage.slots.edgelessToolUpdated.dispose();
|
||||
};
|
||||
}).dispose;
|
||||
}, [editor?.host, isPresent]);
|
||||
|
||||
return (
|
||||
|
@ -35,6 +35,7 @@ const desktopWhiteList = [
|
||||
'/open-app/url',
|
||||
'/upgrade-success',
|
||||
'/ai-upgrade-success',
|
||||
'/share',
|
||||
];
|
||||
if (
|
||||
!environment.isDesktop &&
|
||||
|
Loading…
Reference in New Issue
Block a user