diff --git a/com.pdma.notion-timer.sdPlugin/bin/plugin.js b/com.pdma.notion-timer.sdPlugin/bin/plugin.js index f72b632..d4884d2 100644 --- a/com.pdma.notion-timer.sdPlugin/bin/plugin.js +++ b/com.pdma.notion-timer.sdPlugin/bin/plugin.js @@ -6438,7 +6438,7 @@ async function stopTimer(token, entryId) { } // src/plugin.ts -var CURRENT_VERSION = "1.0.30"; +var CURRENT_VERSION = "1.0.31"; var GITEA_BASE = "https://gitea.pdmarf.co.uk/pdm/stream_deck_notion_timer/raw/branch/stable-rebuild"; var SIGNING_PUBLIC_KEY = `-----BEGIN PUBLIC KEY----- MCowBQYDK2VwAyEAN7ko8TUpuPzPAJuKAZCRjV0c4ZSlou5d9pUAF6o12b4= diff --git a/com.pdma.notion-timer.sdPlugin/bin/plugin.js.sig b/com.pdma.notion-timer.sdPlugin/bin/plugin.js.sig index b481ae9..a2f96ad 100644 --- a/com.pdma.notion-timer.sdPlugin/bin/plugin.js.sig +++ b/com.pdma.notion-timer.sdPlugin/bin/plugin.js.sig @@ -1 +1 @@ -U [/.C+l.g0h٬QVX8X cʯxНK/(| \ No newline at end of file +vXCkf*jvk 0OZj Y2ֈ=%/Ve[<07_ \ No newline at end of file diff --git a/com.pdma.notion-timer.sdPlugin/manifest.json b/com.pdma.notion-timer.sdPlugin/manifest.json index 70fe186..a708604 100644 --- a/com.pdma.notion-timer.sdPlugin/manifest.json +++ b/com.pdma.notion-timer.sdPlugin/manifest.json @@ -2,7 +2,7 @@ "Author": "Pete Marfleet", "Description": "Toggle Notion time tracking for a project with a single button press.", "Name": "Notion Timer", - "Version": "1.0.30", + "Version": "1.0.31", "SDKVersion": 2, "Software": { "MinimumVersion": "5.0" }, "OS": [{ "Platform": "mac", "MinimumVersion": "10.11" }], diff --git a/com.pdma.notion-timer.sdPlugin/ui/property-inspector.html b/com.pdma.notion-timer.sdPlugin/ui/property-inspector.html index 1e28e8f..3dc4c73 100644 --- a/com.pdma.notion-timer.sdPlugin/ui/property-inspector.html +++ b/com.pdma.notion-timer.sdPlugin/ui/property-inspector.html @@ -195,11 +195,20 @@ userId: document.getElementById("userId").value, }; $PI.setGlobalSettings(creds); + globalUserId = creds.userId; setCredStatus("Credentials saved.", "ok"); - if (creds.notionToken) { - setStatus("Loading…", ""); - $PI.sendToPlugin({ event: "refreshProjects", token: creds.notionToken }); - } + } + + function scheduleCredSave() { + clearTimeout(credSaveTimer); + credSaveTimer = setTimeout(function() { + saveCredentials(); + var token = document.getElementById("notionToken").value.trim(); + if (token) { + setStatus("Loading…", ""); + $PI.sendToPlugin({ event: "refreshProjects", token: token }); + } + }, 600); } function populateUsers(users, userId) { @@ -215,11 +224,6 @@ }); } - function scheduleCredSave() { - clearTimeout(credSaveTimer); - credSaveTimer = setTimeout(saveCredentials, 600); - } - function save() { var sel = document.getElementById("projectSelect"); var opt = sel.options[sel.selectedIndex]; diff --git a/notion-timer.streamDeckPlugin b/notion-timer.streamDeckPlugin index c133364..2ab5dc9 100644 Binary files a/notion-timer.streamDeckPlugin and b/notion-timer.streamDeckPlugin differ diff --git a/src/plugin.ts b/src/plugin.ts index 5019cf8..13e1ec3 100644 --- a/src/plugin.ts +++ b/src/plugin.ts @@ -1,4 +1,4 @@ -const CURRENT_VERSION = "1.0.30"; +const CURRENT_VERSION = "1.0.31"; const GITEA_BASE = "https://gitea.pdmarf.co.uk/pdm/stream_deck_notion_timer/raw/branch/stable-rebuild"; const SIGNING_PUBLIC_KEY = `-----BEGIN PUBLIC KEY----- MCowBQYDK2VwAyEAN7ko8TUpuPzPAJuKAZCRjV0c4ZSlou5d9pUAF6o12b4= diff --git a/version.json b/version.json index 2ebd68b..68603d5 100644 --- a/version.json +++ b/version.json @@ -1 +1 @@ -{ "version": "1.0.30" } +{ "version": "1.0.31" }