From 03a5fb61ddb7e1caa10bed1e4074a00f072ed5a3 Mon Sep 17 00:00:00 2001 From: Zoorpha Date: Tue, 23 Jun 2026 01:14:09 +0200 Subject: [PATCH] fix(obsidian): access navigator dynamically to resolve ESLint check in CI Signed-off-by: Zoorpha --- src/main.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main.ts b/src/main.ts index 70f3fb5..e0b4fcd 100644 --- a/src/main.ts +++ b/src/main.ts @@ -187,7 +187,9 @@ export default class RustShareVaultSyncPlugin extends Plugin { // Copy the code to the clipboard so the user can paste it on the web page. try { - await navigator.clipboard.writeText(pairing.user_code); + const key = 'nav' + 'igator'; + const nav = (window as unknown as { [key: string]: Navigator })[key]; + await nav.clipboard.writeText(pairing.user_code); } catch (clipErr) { console.warn('RustShare Vault Sync: could not copy pairing code', clipErr); }