Skip to content

Commit 7b898ad

Browse files
committed
Update Config
1 parent f307537 commit 7b898ad

File tree

2 files changed

+43
-5
lines changed

2 files changed

+43
-5
lines changed

src/js/config.js

Lines changed: 32 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,26 @@ const config = {
4646
},
4747
fa: 'javascript',
4848
},
49+
{
50+
name: 'Cache Cleaner',
51+
github: 'cssnr/cache-cleaner',
52+
url: 'https://github.com/cssnr/cache-cleaner',
53+
icon: 'https://raw.githubusercontent.com/cssnr/cache-cleaner/master/src/images/logo128.png',
54+
description:
55+
'Web Extension for Automatic Basic HTTP Authentication with many Options and Features.',
56+
badges: {
57+
Google: {
58+
id: 'nbkhplnnajkikghffmincdbipjalpobi',
59+
link: 'https://chromewebstore.google.com/detail/open-links-in-new-tab/nbkhplnnajkikghffmincdbipjalpobi',
60+
},
61+
Mozilla: {
62+
id: 'cache-cleaner-addon',
63+
link: 'https://addons.mozilla.org/addon/cache-cleaner-addon',
64+
},
65+
},
66+
links: {},
67+
fa: 'javascript',
68+
},
4969
{
5070
name: 'Auto Auth',
5171
github: 'cssnr/auto-auth',
@@ -63,9 +83,7 @@ const config = {
6383
link: 'https://addons.mozilla.org/addon/auto-auth',
6484
},
6585
},
66-
links: {
67-
Website: 'https://github.com/cssnr/auto-auth',
68-
},
86+
links: {},
6987
fa: 'javascript',
7088
},
7189
{
@@ -426,6 +444,17 @@ const config = {
426444
// links: {},
427445
fa: 'typescript',
428446
},
447+
{
448+
name: 'Env to/from Json',
449+
github: 'cssnr/env-json-action',
450+
url: 'https://github.com/cssnr/env-json-action',
451+
icon: '',
452+
description:
453+
'Convert Environment File to/from a JSON File w/ Outputs.',
454+
// badges: {},
455+
// links: {},
456+
fa: 'javascript',
457+
},
429458
{
430459
name: 'Push Artifacts',
431460
github: 'cssnr/push-artifacts-action',

src/js/theme.js

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// BS Theme Switcher JS
1+
// JS Bootstrap Theme Switcher
22

33
;(() => {
44
const getStoredTheme = () => localStorage.getItem('theme')
@@ -39,7 +39,8 @@
3939
// console.debug(`showActiveTheme: ${theme}`)
4040
const themeIcon = document.querySelector('#theme-icon')
4141
if (!themeIcon) {
42-
return console.debug('No Theme Icon to Set.')
42+
// console.debug('No Theme Icon to Set.')
43+
return
4344
}
4445
document.querySelectorAll('[data-bs-theme-value]').forEach((el) => {
4546
if (el.dataset.bsThemeValue === theme) {
@@ -54,6 +55,14 @@
5455
})
5556
}
5657

58+
window.addEventListener('storage', (event) => {
59+
// console.log('storage:', event)
60+
if (event.key === 'theme') {
61+
setTheme(event.newValue)
62+
showActiveTheme(event.newValue)
63+
}
64+
})
65+
5766
window
5867
.matchMedia('(prefers-color-scheme: dark)')
5968
.addEventListener('change', () => {

0 commit comments

Comments
 (0)