From ca65a0288d9acb22e7950925471e04c8c0079adc Mon Sep 17 00:00:00 2001 From: Shiba <44804845+DeepDoge@users.noreply.github.com> Date: Wed, 10 Aug 2022 10:18:04 +0000 Subject: [PATCH 1/4] =?UTF-8?q?=F0=9F=8D=A3=20some=20little=20fixes=20in?= =?UTF-8?q?=20the=20code=20-=20nothing=20changed,=20just=20some=20little?= =?UTF-8?q?=20fixes?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/modules/crypto/index.ts | 18 +++++++----------- src/pages/popup/style.css | 8 +------- 2 files changed, 8 insertions(+), 18 deletions(-) diff --git a/src/modules/crypto/index.ts b/src/modules/crypto/index.ts index 7953d9c..21f9785 100644 --- a/src/modules/crypto/index.ts +++ b/src/modules/crypto/index.ts @@ -70,22 +70,18 @@ export function resetProfileSettings() { async function apiRequest(method: 'GET' | 'POST', pathname: string, data: T) { const settings = await getExtensionSettingsAsync() - /* const urlResolverSettings = ytUrlResolversSettings[settings.urlResolver] - if (!urlResolverSettings.signRequest) throw new Error() */ - const url = new URL(ytUrlResolversSettings.madiatorFinder.href/* urlResolverSettings.href */) + const url = new URL(ytUrlResolversSettings.madiatorFinder.href) url.pathname = path.join(url.pathname, pathname) url.searchParams.set('data', JSON.stringify(data)) - if (true/* requiresSignature */) { - if (!settings.privateKey || !settings.publicKey) - throw new Error('There is no profile.') + if (!settings.privateKey || !settings.publicKey) + throw new Error('There is no profile.') - url.searchParams.set('keys', JSON.stringify({ - signature: await sign(url.searchParams.toString(), settings.privateKey!), - publicKey: settings.publicKey - })) - } + url.searchParams.set('keys', JSON.stringify({ + signature: await sign(url.searchParams.toString(), settings.privateKey!), + publicKey: settings.publicKey + })) const respond = await fetch(url.href, { method }) diff --git a/src/pages/popup/style.css b/src/pages/popup/style.css index f492c52..506dfa9 100644 --- a/src/pages/popup/style.css +++ b/src/pages/popup/style.css @@ -28,18 +28,12 @@ section { gap: .75em; } -section>label { +label { font-size: 1.75em; font-weight: bold; text-align: center; } -section>b { - display: block; - width: 100%; - text-align: left; -} - section>* { padding: 0 1rem; } From 351ca5c6c3b16ba971f165f71d7ef57ec05799bd Mon Sep 17 00:00:00 2001 From: kodxana Date: Fri, 2 Sep 2022 13:19:07 +0200 Subject: [PATCH 2/4] Up Version --- manifest.v2.json | 2 +- manifest.v3.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/manifest.v2.json b/manifest.v2.json index 9489f9c..e03a10b 100644 --- a/manifest.v2.json +++ b/manifest.v2.json @@ -1,7 +1,7 @@ { "manifest_version": 2, "name": "Watch on LBRY", - "version": "2.0.0", + "version": "2.0.1", "icons": { "16": "assets/icons/wol/icon16.png", "48": "assets/icons/wol/icon48.png", diff --git a/manifest.v3.json b/manifest.v3.json index 25dee5b..a13d104 100644 --- a/manifest.v3.json +++ b/manifest.v3.json @@ -1,7 +1,7 @@ { "manifest_version": 3, "name": "Watch on LBRY", - "version": "2.0.0", + "version": "2.0.1", "icons": { "16": "assets/icons/wol/icon16.png", "48": "assets/icons/wol/icon48.png", From 529931c43b9fb774fe657e2cfe38e5a09dd7113f Mon Sep 17 00:00:00 2001 From: Shiba <44804845+DeepDoge@users.noreply.github.com> Date: Wed, 28 Sep 2022 14:38:37 +0300 Subject: [PATCH 3/4] =?UTF-8?q?=F0=9F=8D=99=20removed=20console.log=20s?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/modules/yt/urlCache.ts | 1 - src/scripts/background.ts | 1 - src/scripts/ytContent.tsx | 1 - 3 files changed, 3 deletions(-) diff --git a/src/modules/yt/urlCache.ts b/src/modules/yt/urlCache.ts index b2c58c1..897d725 100644 --- a/src/modules/yt/urlCache.ts +++ b/src/modules/yt/urlCache.ts @@ -75,7 +75,6 @@ async function get(id: string): Promise { await clearExpired() return undefined } - console.log('cache found', id, response.value) return response.value } diff --git a/src/scripts/background.ts b/src/scripts/background.ts index 3996ccf..9b5f7fb 100644 --- a/src/scripts/background.ts +++ b/src/scripts/background.ts @@ -20,7 +20,6 @@ chrome.runtime.onMessage.addListener(({ method, data }, sender, sendResponse) => const params: Parameters = JSON.parse(data) // Don't create a new Promise for same ID until on going one is over. const promise = onGoingLbryPathnameRequest[data] ?? (onGoingLbryPathnameRequest[data] = resolveById(...params)) - console.log('lbrypathname request', params, await promise) resolve(await promise) } catch (error) { sendResponse(`error: ${(error as any).toString()}`) diff --git a/src/scripts/ytContent.tsx b/src/scripts/ytContent.tsx index f4c69c2..4ab93d9 100644 --- a/src/scripts/ytContent.tsx +++ b/src/scripts/ytContent.tsx @@ -231,7 +231,6 @@ import { getExtensionSettingsAsync, getSourcePlatfromSettingsFromHostname, getTa console.error("Background error on:", params) throw new Error(`Background error. ${response ?? ''}`) } - console.log(response) return response ? JSON.parse(response) : null } From 6ba1a373a9488c7d0584b0a370c3e5d584882b14 Mon Sep 17 00:00:00 2001 From: Shiba <44804845+DeepDoge@users.noreply.github.com> Date: Sat, 1 Oct 2022 12:18:34 +0300 Subject: [PATCH 4/4] =?UTF-8?q?=F0=9F=8D=A3=20max-width=20on=20popup=20rem?= =?UTF-8?q?oved?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit was causing some issues with exotic browsers --- src/pages/popup/style.css | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/pages/popup/style.css b/src/pages/popup/style.css index 506dfa9..397f72b 100644 --- a/src/pages/popup/style.css +++ b/src/pages/popup/style.css @@ -1,6 +1,5 @@ #popup { width: 40em; - max-width: 100%; overflow: hidden; margin: auto; } @@ -53,4 +52,4 @@ section>* { .toggle-option { display: grid; gap: .5em; -} \ No newline at end of file +}