feat(core): avoid popup window being blocked (#6451)

This commit is contained in:
liuyi
2024-04-03 16:50:09 +08:00
committed by GitHub
parent 3e9e2ce93b
commit 6fa4b7da54
14 changed files with 78 additions and 28 deletions

View File

@@ -4,6 +4,7 @@ import { registerAffineCommand } from '@toeverything/infra';
import type { createStore } from 'jotai';
import { openSettingModalAtom } from '../atoms';
import { popupWindow } from '../utils';
export function registerAffineHelpCommands({
t,
@@ -20,7 +21,7 @@ export function registerAffineHelpCommands({
icon: <NewIcon />,
label: t['com.affine.cmdk.affine.whats-new'](),
run() {
window.open(runtimeConfig.changelogUrl, '_blank');
popupWindow(runtimeConfig.changelogUrl);
},
})
);