From 0736a5870d4fbad9be374e4e05e47d9697e0bd0f Mon Sep 17 00:00:00 2001 From: ronreg-ribdev Date: Sat, 28 Nov 2020 00:08:38 -0800 Subject: [PATCH] Initial extension commit --- extension/background/main.js | 1 + extension/background/page.html | 7 +++++++ extension/icons/urbit-icon.png | Bin 0 -> 20186 bytes extension/manifest.json | 37 +++++++++++++++++++++++++++++++++ extension/options/options.html | 19 +++++++++++++++++ extension/options/options.js | 26 +++++++++++++++++++++++ extension/popup/popup.css | 8 +++++++ extension/popup/popup.html | 17 +++++++++++++++ extension/popup/popup.js | 16 ++++++++++++++ 9 files changed, 131 insertions(+) create mode 100644 extension/background/main.js create mode 100644 extension/background/page.html create mode 100644 extension/icons/urbit-icon.png create mode 100644 extension/manifest.json create mode 100644 extension/options/options.html create mode 100644 extension/options/options.js create mode 100644 extension/popup/popup.css create mode 100644 extension/popup/popup.html create mode 100644 extension/popup/popup.js diff --git a/extension/background/main.js b/extension/background/main.js new file mode 100644 index 0000000..249f91c --- /dev/null +++ b/extension/background/main.js @@ -0,0 +1 @@ +console.log("Executing Urbit extension background main script"); diff --git a/extension/background/page.html b/extension/background/page.html new file mode 100644 index 0000000..68e1c37 --- /dev/null +++ b/extension/background/page.html @@ -0,0 +1,7 @@ + + + + + + + diff --git a/extension/icons/urbit-icon.png b/extension/icons/urbit-icon.png new file mode 100644 index 0000000000000000000000000000000000000000..0f4b25d7a86f84309413aed02f9a5fcafd9b1ed6 GIT binary patch literal 20186 zcmeIabyQZ});A1Dw}=Qxi%2&}cSv`4cXLUDbc3{XH_{;>AY3#m(k0R@Al>jSyw82k zeZKd6&-*=NyytoUIeQGo@Y;Lrxz?I%=5NkzxT3ry1}Y&c3=9m0)GIM%7#P^M_kYN6 z;11S&ZaNGM%B82OrmM1%8=0fCgSnNh8JVkxqZyf*yOlW%jQi~FJ1u8QZcMQ|j|gr! zDM#2?C<1%>)6WMR)W z(&k6;agUsPe%WB_IrJ8&IuMXqFu=+-FpcR_(l@a5A|AWC?0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new file mode 100644 index 0000000..34504ef --- /dev/null +++ b/extension/manifest.json @@ -0,0 +1,37 @@ +{ + "manifest_version": 2, + "name": "Urbit Browser Manager", + "version": "0.0.1", + "description": "Manage your web browsing with your Urbit ship", + "homepage_url": "https://example.com", + + "icons": { + "48": "icons/urbit-icon.png" + }, + + "permissions": [ + "activeTab", "storage" + ], + + "background": { + "page": "background/page.html" + }, + + "options_ui": { + "page": "options/options.html", + "browser_style": true + }, + + "browser_action": { + "default_icon": "icons/urbit-icon.png", + "default_title": "Urbit Browser Manager", + "default_popup": "popup/popup.html" + }, + + "browser_specific_settings": { + "gecko": { + "id": "ronreg-ribdev@urbit.live" + } + } +} + diff --git a/extension/options/options.html b/extension/options/options.html new file mode 100644 index 0000000..50939a5 --- /dev/null +++ b/extension/options/options.html @@ -0,0 +1,19 @@ + + + + + + + + +
+ + + + + + +
+ + + diff --git a/extension/options/options.js b/extension/options/options.js new file mode 100644 index 0000000..159170e --- /dev/null +++ b/extension/options/options.js @@ -0,0 +1,26 @@ +const urbitIdSelector = document.querySelector("#urbitId"); +const urbitCodeSelector = document.querySelector("#urbitCode"); + +document.addEventListener('DOMContentLoaded', () => { + browser.storage.sync.get("credentials") + .then((result) => { + if (result.credentials && result.credentials.urbitId && result.credentials.urbitCode) { + urbitIdSelector.value = result.credentials.urbitId; + urbitCodeSelector.value = result.credentials.urbitCode; + } else { + urbitIdSelector.value = ""; + urbitCodeSelector.value = ""; + } + }); +}); + +document.querySelector("#saveButton").addEventListener("click", () => { + const urbitId = urbitIdSelector.value; + const urbitCode = urbitCodeSelector.value; + browser.storage.sync.set({credentials: {urbitId, urbitCode}}); +}); + +document.querySelector("#clearButton").addEventListener("click", () => { + browser.storage.sync.remove("credentials"); +}); + diff --git a/extension/popup/popup.css b/extension/popup/popup.css new file mode 100644 index 0000000..8f18db8 --- /dev/null +++ b/extension/popup/popup.css @@ -0,0 +1,8 @@ + +html, body { + width: 200px; +} + +h1 { + font-size: large; +} diff --git a/extension/popup/popup.html b/extension/popup/popup.html new file mode 100644 index 0000000..01873b0 --- /dev/null +++ b/extension/popup/popup.html @@ -0,0 +1,17 @@ + + + + + + + +

Urbit browser manager

+ +
+ Managing this page? + + +
+ + + diff --git a/extension/popup/popup.js b/extension/popup/popup.js new file mode 100644 index 0000000..e214664 --- /dev/null +++ b/extension/popup/popup.js @@ -0,0 +1,16 @@ +console.log("popup.js running"); + +const getLocalStorage = browser.storage.sync.get(); + +document.querySelector("#options").addEventListener("click", () => { + browser.runtime.openOptionsPage(); +}); + +getLocalStorage.then((result) => { + const loggedInSelector = document.querySelector("#loggedInMsg"); + if (result.credentials && result.credentials.urbitId && result.credentials.urbitCode) { + loggedInSelector.textContent = `Hi, ~${result.credentials.urbitId}`; + } else { + loggedInSelector.textContent = "Not logged in"; + } +});