From 7ee2539969d1083ebd4aba83b574fa9e29ff2b4a Mon Sep 17 00:00:00 2001 From: ManeraKai Date: Thu, 10 Feb 2022 20:16:48 +0300 Subject: Fixed bugs. Added icons --- src/pages/options/general/general.html | 105 ++++++++++++++++++--- src/pages/options/imgur/imgur.html | 106 ++++++++++++++++++--- src/pages/options/init.js | 1 - src/pages/options/instagram/instagram.html | 106 ++++++++++++++++++--- src/pages/options/maps/maps.html | 106 ++++++++++++++++++--- src/pages/options/medium/medium.html | 106 ++++++++++++++++++--- src/pages/options/reddit/reddit.html | 106 ++++++++++++++++++--- src/pages/options/search/search.html | 106 ++++++++++++++++++--- src/pages/options/tiktok/tiktok.html | 147 +++++++++++++++++++++++++++++ src/pages/options/tiktok/tiktok.js | 21 +++++ src/pages/options/translate/translate.html | 104 +++++++++++++++++--- src/pages/options/twitter/twitter.html | 104 +++++++++++++++++--- src/pages/options/wikipedia/wikipedia.html | 105 ++++++++++++++++++--- src/pages/options/youtube/youtube.html | 106 ++++++++++++++++++--- src/pages/popup/popup.html | 117 +++++++++++++++++++---- src/pages/popup/style.css | 2 +- src/pages/stylesheets/styles.css | 20 +++- 17 files changed, 1314 insertions(+), 154 deletions(-) create mode 100644 src/pages/options/tiktok/tiktok.html create mode 100644 src/pages/options/tiktok/tiktok.js (limited to 'src/pages') diff --git a/src/pages/options/general/general.html b/src/pages/options/general/general.html index 5dff25b7..89b80b11 100644 --- a/src/pages/options/general/general.html +++ b/src/pages/options/general/general.html @@ -10,19 +10,100 @@ - diff --git a/src/pages/options/imgur/imgur.html b/src/pages/options/imgur/imgur.html index 9fdedd2e..32a4e67b 100644 --- a/src/pages/options/imgur/imgur.html +++ b/src/pages/options/imgur/imgur.html @@ -12,18 +12,100 @@ +
+ + + + + General +
+
+ + Youtube +
+
+ + Twitter +
+
+ + Instagram +
+
+ + TikTok +
+
+ + Reddit +
+
+ + Imgur +
+
+ + + + + Search +
+
+ + + + + Translate +
+
+ + + + + Maps +
+
+ + + + + + + + + + + + + + + + + Wikipedia +
+
+ + + + + + + + + + Medium +
+
diff --git a/src/pages/options/init.js b/src/pages/options/init.js index deabd92f..fdcca8e4 100644 --- a/src/pages/options/init.js +++ b/src/pages/options/init.js @@ -1,6 +1,5 @@ function changeTheme() { browser.storage.sync.get("theme", (result) => { - console.log("Chaning Theme") switch (result.theme) { case "dark-theme": document.body.classList.add("dark-theme"); diff --git a/src/pages/options/instagram/instagram.html b/src/pages/options/instagram/instagram.html index 1c67ecbc..ed9d7be9 100644 --- a/src/pages/options/instagram/instagram.html +++ b/src/pages/options/instagram/instagram.html @@ -12,18 +12,100 @@ +
+ + + + + General +
+
+ + Youtube +
+
+ + Twitter +
+
+ + Instagram +
+
+ + TikTok +
+
+ + Reddit +
+
+ + Imgur +
+
+ + + + + Search +
+
+ + + + + Translate +
+
+ + + + + Maps +
+
+ + + + + + + + + + + + + + + + + Wikipedia +
+
+ + + + + + + + + + Medium +
+
diff --git a/src/pages/options/maps/maps.html b/src/pages/options/maps/maps.html index e338b9fa..01233a07 100644 --- a/src/pages/options/maps/maps.html +++ b/src/pages/options/maps/maps.html @@ -13,18 +13,100 @@ +
+ + + + + General +
+
+ + Youtube +
+
+ + Twitter +
+
+ + Instagram +
+
+ + TikTok +
+
+ + Reddit +
+
+ + Imgur +
+
+ + + + + Search +
+
+ + + + + Translate +
+
+ + + + + Maps +
+
+ + + + + + + + + + + + + + + + + Wikipedia +
+
+ + + + + + + + + + Medium +
+
diff --git a/src/pages/options/medium/medium.html b/src/pages/options/medium/medium.html index 60f58d23..43e9e87d 100644 --- a/src/pages/options/medium/medium.html +++ b/src/pages/options/medium/medium.html @@ -12,18 +12,100 @@ +
+ + + + + General +
+
+ + Youtube +
+
+ + Twitter +
+
+ + Instagram +
+
+ + TikTok +
+
+ + Reddit +
+
+ + Imgur +
+
+ + + + + Search +
+
+ + + + + Translate +
+
+ + + + + Maps +
+
+ + + + + + + + + + + + + + + + + Wikipedia +
+
+ + + + + + + + + + Medium +
+
diff --git a/src/pages/options/reddit/reddit.html b/src/pages/options/reddit/reddit.html index 472f367f..89d5e4f1 100644 --- a/src/pages/options/reddit/reddit.html +++ b/src/pages/options/reddit/reddit.html @@ -12,18 +12,100 @@ +
+ + + + + General +
+
+ + Youtube +
+
+ + Twitter +
+
+ + Instagram +
+
+ + TikTok +
+
+ + Reddit +
+
+ + Imgur +
+
+ + + + + Search +
+
+ + + + + Translate +
+
+ + + + + Maps +
+
+ + + + + + + + + + + + + + + + + Wikipedia +
+
+ + + + + + + + + + Medium +
+
diff --git a/src/pages/options/search/search.html b/src/pages/options/search/search.html index 80d08f8c..f21b3aa3 100644 --- a/src/pages/options/search/search.html +++ b/src/pages/options/search/search.html @@ -12,18 +12,100 @@ +
+ + + + + General +
+
+ + Youtube +
+
+ + Twitter +
+
+ + Instagram +
+
+ + TikTok +
+
+ + Reddit +
+
+ + Imgur +
+
+ + + + + Search +
+
+ + + + + Translate +
+
+ + + + + Maps +
+
+ + + + + + + + + + + + + + + + + Wikipedia +
+
+ + + + + + + + + + Medium +
+
diff --git a/src/pages/options/tiktok/tiktok.html b/src/pages/options/tiktok/tiktok.html new file mode 100644 index 00000000..7c5aeac1 --- /dev/null +++ b/src/pages/options/tiktok/tiktok.html @@ -0,0 +1,147 @@ + + + + + + + + + + LibRedirect options: Twitter + + + + + +
+
+

Enable

+ +
+ +
+ +
+

Default Instances

+
+
+
+
+

Custom Instances

+
+
+
+ + +
+
+
+
+ + + + + + + + \ No newline at end of file diff --git a/src/pages/options/tiktok/tiktok.js b/src/pages/options/tiktok/tiktok.js new file mode 100644 index 00000000..f8ddb67e --- /dev/null +++ b/src/pages/options/tiktok/tiktok.js @@ -0,0 +1,21 @@ +import tiktokHelper from "../../../assets/javascripts/helpers/tiktok.js"; +import commonHelper from "../../../assets/javascripts/helpers/common.js"; + +let disableTiktokElement = document.getElementById("disable-tiktok"); +disableTiktokElement.addEventListener("change", + (event) => tiktokHelper.setDisableTiktok(!event.target.checked) +); + +tiktokHelper.init().then(() => { + disableTiktokElement.checked = !tiktokHelper.getDisableTiktok(); + + commonHelper.processDefaultCustomInstances( + 'proxiTok', + tiktokHelper, + document, + tiktokHelper.getProxiTokRedirectsChecks, + tiktokHelper.setProxiTokRedirectsChecks, + tiktokHelper.getProxiTokCustomRedirects, + tiktokHelper.setProxiTokCustomRedirects + ) +}) \ No newline at end of file diff --git a/src/pages/options/translate/translate.html b/src/pages/options/translate/translate.html index 04dfc2bb..36380865 100644 --- a/src/pages/options/translate/translate.html +++ b/src/pages/options/translate/translate.html @@ -12,17 +12,99 @@
diff --git a/src/pages/options/twitter/twitter.html b/src/pages/options/twitter/twitter.html index b47a094e..948f0be1 100644 --- a/src/pages/options/twitter/twitter.html +++ b/src/pages/options/twitter/twitter.html @@ -13,17 +13,99 @@
diff --git a/src/pages/options/wikipedia/wikipedia.html b/src/pages/options/wikipedia/wikipedia.html index 4bd0b5e8..7626f3b9 100644 --- a/src/pages/options/wikipedia/wikipedia.html +++ b/src/pages/options/wikipedia/wikipedia.html @@ -12,19 +12,100 @@ -

Enable

diff --git a/src/pages/options/youtube/youtube.html b/src/pages/options/youtube/youtube.html index 8c7ea787..767780f4 100644 --- a/src/pages/options/youtube/youtube.html +++ b/src/pages/options/youtube/youtube.html @@ -13,18 +13,100 @@ +
+ + + + + General +
+
+ + Youtube +
+
+ + Twitter +
+
+ + Instagram +
+
+ + TikTok +
+
+ + Reddit +
+
+ + Imgur +
+
+ + + + + Search +
+
+ + + + + Translate +
+
+ + + + + Maps +
+
+ + + + + + + + + + + + + + + + + Wikipedia +
+
+ + + + + + + + + + Medium +
+
diff --git a/src/pages/popup/popup.html b/src/pages/popup/popup.html index 126912a4..7ab71814 100644 --- a/src/pages/popup/popup.html +++ b/src/pages/popup/popup.html @@ -10,57 +10,138 @@
-

Youtube

+
+ +

Youtube

+
-

Twitter

+
+ +

Twitter

+
-

Instagram

+
+ + +

Instagram

+
-

Reddit

- +
+ + +

TikTok

+
+
-

Search

- +
+ +

Imgur

+
+
-

Translate

- +
+ + +

Reddit

+
+
-

Maps

- + +
+ + + + +

Search

+
+ +
-

Wikipedia

- +
+ + + + +

Translate

+
+
-

Imgur

- +
+ + + + +

Maps

+
+
-

TikTok

- +
+ + + + + + + + + + + + + + + + +

Wikipedia

+
+
-

Medium

+
+ + + + + + + + + +

Medium

+
+
diff --git a/src/pages/popup/style.css b/src/pages/popup/style.css index 098e6728..05c3947a 100644 --- a/src/pages/popup/style.css +++ b/src/pages/popup/style.css @@ -1,5 +1,5 @@ body { - width: 200px; + width: 230px; min-height: auto; background-color: var(--bg-main); } \ No newline at end of file diff --git a/src/pages/stylesheets/styles.css b/src/pages/stylesheets/styles.css index deabdc92..1ce529f1 100644 --- a/src/pages/stylesheets/styles.css +++ b/src/pages/stylesheets/styles.css @@ -25,6 +25,17 @@ div.some-block input[type="checkbox"] { -webkit-appearance: none; } +div.title { + display: flex; + align-items: center; +} + +img, svg { + margin-right: 10px; + height: 26px; + color: var(--text); +} + input[type="url"], input[type="text"], select { @@ -87,13 +98,17 @@ body.option { padding: 40px; } +section.links div { + margin: 20px 0; +} + section.links a { display: flex; align-items: center; font-size: 30px; text-decoration: none; color: white; - margin: 20px 0; + /* margin: 20px 0; */ font-weight: bold; transition: 0.1s; } @@ -301,7 +316,4 @@ body.light-theme textarea:focus { body.light-theme a { color: black; -} - -@media (prefers-color-scheme: light) { } \ No newline at end of file -- cgit 1.4.1