Build your personal knowledge base with Trilium Notes
TypeScript electronelectron-appknowledge-baseknowledge-graphknowledge-managementknowledge-management-graphlocal-firstnote-managmentnote-takernote-takingnotebooknotesnotes-apppersonal-knowledge-basepersonal-wikiscriptableself-hostedself-hostingwiki
client: fix some issues
Adorian Doran59365779f915
diff --git a/apps/client/src/services/utils.ts b/apps/client/src/services/utils.tsindex 8b15797f26..e805fc9268 100644--- a/apps/client/src/services/utils.ts+++ b/apps/client/src/services/utils.ts@@ -164,14 +164,14 @@ export function isMac() {* `!isMac && !isWindows` derivation so future platforms aren't misclassified as Linux.*/export function isLinux() {- return window.glob.platform === "linux";+ return window.glob?.platform === "linux";}/*** Returns `true` when the (server-reported) host platform is Windows.*/export function isWindows() {- return window.glob.platform === "win32";+ return window.glob?.platform === "win32";}export function isCtrlKey(evt: KeyboardEvent | MouseEvent | JQuery.ClickEvent | JQuery.ContextMenuEvent | JQuery.TriggeredEvent | React.PointerEvent<HTMLCanvasElement> | JQueryEventObject) {diff --git a/apps/client/src/widgets/sidebar/RightPanelContainer.tsx b/apps/client/src/widgets/sidebar/RightPanelContainer.tsxindex fe91a37cc1..5fc6845e7c 100644--- a/apps/client/src/widgets/sidebar/RightPanelContainer.tsx+++ b/apps/client/src/widgets/sidebar/RightPanelContainer.tsx@@ -48,7 +48,7 @@ export default function RightPanelContainer({ widgetsByParent }: { widgetsByPareuseTriliumEvent("peekRightPane", togglePeek);// Outside-press / Esc *soft*-dismisses the peek: it hides but stays mounted, so re-peeking is- // instant and preserves widget state. The × button and the peek button hard-close (unmount).+ // instant and preserves widget state. The × button and the docked toggle hard-close (unmount).usePeekDismiss(mode === "peek", dismiss, {keepOpenSelector: "#right-pane, .right-pane-peek-button",focusSelector: ".right-pane-peek-button"