Working on update a lot of pages using the ae_loc hub section.
This commit is contained in:
@@ -26,23 +26,23 @@ onMount(() => {
|
||||
}
|
||||
});
|
||||
|
||||
// $: if ($slct_trigger == 'set_theme_mode' && $ae_loc?.hub?.theme_mode) {
|
||||
// console.log(`$ae_loc.hub.theme_mode=${$ae_loc?.hub?.theme_mode}`);
|
||||
// $: if ($slct_trigger == 'set_theme_mode' && $ae_loc?.app_cfg?.theme_mode) {
|
||||
// console.log(`$ae_loc.app_cfg.theme_mode=${$ae_loc?.app_cfg?.theme_mode}`);
|
||||
// $slct_trigger = null;
|
||||
// if ($ae_loc.hub.theme_mode == 'light') {
|
||||
// if ($ae_loc.app_cfg.theme_mode == 'light') {
|
||||
// document.documentElement.classList.remove('dark');
|
||||
// document.documentElement.classList.add('light');
|
||||
// } else if ($ae_loc.hub.theme_mode == 'dark') {
|
||||
// } else if ($ae_loc.app_cfg.theme_mode == 'dark') {
|
||||
// document.documentElement.classList.remove('light');
|
||||
// document.documentElement.classList.add('dark');
|
||||
// }
|
||||
// }
|
||||
|
||||
// $: if ($slct_trigger == 'set_theme_name' && $ae_loc?.hub?.theme_name) {
|
||||
// console.log(`$ae_loc?.hub?.theme_name=${$ae_loc?.hub?.theme_name}`);
|
||||
// $: if ($slct_trigger == 'set_theme_name' && $ae_loc?.app_cfg?.theme_name) {
|
||||
// console.log(`$ae_loc?.app_cfg?.theme_name=${$ae_loc?.app_cfg?.theme_name}`);
|
||||
// $slct_trigger = null;
|
||||
// // Update the body attribute named "data-theme" to the current theme name.
|
||||
// document.body.setAttribute('data-theme', $ae_loc?.hub?.theme_name);
|
||||
// document.body.setAttribute('data-theme', $ae_loc?.app_cfg?.theme_name);
|
||||
// }
|
||||
|
||||
// $: if (entered_passcode && entered_passcode.length >= 5) {
|
||||
@@ -95,7 +95,7 @@ function handle_clear_storage(item: null|string) {
|
||||
|
||||
<div
|
||||
class="ae_cfg_content text-xs space-y-4 my-4"
|
||||
class:hidden={!$ae_loc.hub.show_element__cfg_detail}
|
||||
class:hidden={!$ae_loc.app_cfg.show_element__cfg_detail}
|
||||
data-sveltekit-preload-data="false"
|
||||
>
|
||||
|
||||
@@ -149,7 +149,7 @@ function handle_clear_storage(item: null|string) {
|
||||
on:change={() => {
|
||||
$slct_trigger = 'set_theme_mode';
|
||||
}}
|
||||
bind:group={$ae_loc.hub.theme_mode}
|
||||
bind:group={$ae_loc.app_cfg.theme_mode}
|
||||
name="theme_light"
|
||||
value={'light'}
|
||||
>
|
||||
@@ -159,7 +159,7 @@ function handle_clear_storage(item: null|string) {
|
||||
on:change={() => {
|
||||
$slct_trigger = 'set_theme_mode';
|
||||
}}
|
||||
bind:group={$ae_loc.hub.theme_mode}
|
||||
bind:group={$ae_loc.app_cfg.theme_mode}
|
||||
name="theme_dark"
|
||||
value={'dark'}
|
||||
>
|
||||
@@ -174,7 +174,7 @@ function handle_clear_storage(item: null|string) {
|
||||
on:change={() => {
|
||||
$slct_trigger = 'set_theme_name';
|
||||
}}
|
||||
bind:value={$ae_loc.hub.theme_name}
|
||||
bind:value={$ae_loc.app_cfg.theme_name}
|
||||
class="select"
|
||||
title="Theme name"
|
||||
>
|
||||
@@ -269,7 +269,7 @@ function handle_clear_storage(item: null|string) {
|
||||
<button
|
||||
class="btn btn-sm variant-glass-warning ae_cfg_btn hover:transition-all"
|
||||
on:click={() => {
|
||||
$ae_loc.hub.show_element__cfg_detail = !$ae_loc.hub.show_element__cfg_detail;
|
||||
$ae_loc.app_cfg.show_element__cfg_detail = !$ae_loc.app_cfg.show_element__cfg_detail;
|
||||
}}
|
||||
>
|
||||
<span class="fas fa-cog mx-1"></span>
|
||||
|
||||
Reference in New Issue
Block a user