General clean up. Nothing should be broken...
This commit is contained in:
@@ -86,7 +86,6 @@ let events_local_data_struct: key_val = {
|
|||||||
|
|
||||||
'show_element__cfg': true,
|
'show_element__cfg': true,
|
||||||
'show_element__cfg_detail': false,
|
'show_element__cfg_detail': false,
|
||||||
'show_element__access_type': true,
|
|
||||||
'theme_mode': 'dark',
|
'theme_mode': 'dark',
|
||||||
'theme_name': 'wintry',
|
'theme_name': 'wintry',
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
let log_lvl = 0;
|
let log_lvl = 0;
|
||||||
import { createEventDispatcher, onMount, tick } from 'svelte';
|
import { onMount, tick } from 'svelte';
|
||||||
|
|
||||||
// import { liveQuery } from "dexie";
|
// import { liveQuery } from "dexie";
|
||||||
|
|
||||||
@@ -17,7 +17,7 @@ let show_passcode_input: boolean = false;
|
|||||||
|
|
||||||
let trigger: null|string = null;
|
let trigger: null|string = null;
|
||||||
|
|
||||||
const dispatch = createEventDispatcher();
|
// const dispatch = createEventDispatcher();
|
||||||
|
|
||||||
|
|
||||||
onMount(() => {
|
onMount(() => {
|
||||||
@@ -112,7 +112,7 @@ function handle_check_access_type_passcode() {
|
|||||||
// ae_loc.set($ae_loc);
|
// ae_loc.set($ae_loc);
|
||||||
// console.log($ae_loc);
|
// console.log($ae_loc);
|
||||||
|
|
||||||
dispatch_access_type_changed();
|
// dispatch_access_type_changed();
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -132,7 +132,7 @@ function handle_check_access_type_passcode() {
|
|||||||
$ae_loc.hub.show_element__cfg = false;
|
$ae_loc.hub.show_element__cfg = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
dispatch_access_type_changed();
|
// dispatch_access_type_changed();
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
} else {
|
} else {
|
||||||
@@ -162,38 +162,38 @@ function handle_clear_access() {
|
|||||||
// ae_loc.set($ae_loc);
|
// ae_loc.set($ae_loc);
|
||||||
// console.log($ae_loc);
|
// console.log($ae_loc);
|
||||||
|
|
||||||
dispatch_access_type_changed();
|
// dispatch_access_type_changed();
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
function dispatch_access_type_changed() {
|
// function dispatch_access_type_changed() {
|
||||||
if (log_lvl) {
|
// if (log_lvl) {
|
||||||
console.log('*** dispatch_access_type_changed() ***');
|
// console.log('*** dispatch_access_type_changed() ***');
|
||||||
|
|
||||||
console.log(ae_util);
|
// console.log(ae_util);
|
||||||
console.log($ae_loc);
|
// console.log($ae_loc);
|
||||||
}
|
// }
|
||||||
|
|
||||||
dispatch('access_type_changed', {
|
// dispatch('access_type_changed', {
|
||||||
access_type: $ae_loc.access_type
|
// access_type: $ae_loc.access_type
|
||||||
});
|
// });
|
||||||
}
|
// }
|
||||||
|
|
||||||
function dispatch_edit_mode_changed() {
|
// function dispatch_edit_mode_changed() {
|
||||||
if (log_lvl) {
|
// if (log_lvl) {
|
||||||
console.log('*** dispatch_edit_mode_changed() ***');
|
// console.log('*** dispatch_edit_mode_changed() ***');
|
||||||
|
|
||||||
console.log(ae_util);
|
// console.log(ae_util);
|
||||||
console.log($ae_loc);
|
// console.log($ae_loc);
|
||||||
}
|
// }
|
||||||
|
|
||||||
window.localStorage.setItem('edit_mode', $ae_loc.edit_mode);
|
// window.localStorage.setItem('edit_mode', $ae_loc.edit_mode);
|
||||||
|
|
||||||
dispatch('edit_mode_changed', {
|
// dispatch('edit_mode_changed', {
|
||||||
edit_mode: $ae_loc.edit_mode
|
// edit_mode: $ae_loc.edit_mode
|
||||||
});
|
// });
|
||||||
}
|
// }
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
||||||
@@ -274,7 +274,7 @@ function dispatch_edit_mode_changed() {
|
|||||||
type="button"
|
type="button"
|
||||||
on:click={() => {
|
on:click={() => {
|
||||||
$ae_loc.edit_mode = false;
|
$ae_loc.edit_mode = false;
|
||||||
dispatch_edit_mode_changed();
|
// dispatch_edit_mode_changed();
|
||||||
}}
|
}}
|
||||||
class="btn btn-sm variant-ghost-success hover:variant-filled-success transition-all"
|
class="btn btn-sm variant-ghost-success hover:variant-filled-success transition-all"
|
||||||
title="Edit mode is currently enabled. Click to disable."
|
title="Edit mode is currently enabled. Click to disable."
|
||||||
@@ -287,7 +287,7 @@ function dispatch_edit_mode_changed() {
|
|||||||
type="button"
|
type="button"
|
||||||
on:click={() => {
|
on:click={() => {
|
||||||
$ae_loc.edit_mode = true;
|
$ae_loc.edit_mode = true;
|
||||||
dispatch_edit_mode_changed();
|
// dispatch_edit_mode_changed();
|
||||||
}}
|
}}
|
||||||
class="btn btn-sm variant-ghost-warning hover:variant-filled-warning transition-all"
|
class="btn btn-sm variant-ghost-warning hover:variant-filled-warning transition-all"
|
||||||
title="Edit mode is currently disabled. Click to enable."
|
title="Edit mode is currently disabled. Click to enable."
|
||||||
@@ -347,7 +347,7 @@ function dispatch_edit_mode_changed() {
|
|||||||
on:click={async () => {
|
on:click={async () => {
|
||||||
show_passcode_input = !show_passcode_input;
|
show_passcode_input = !show_passcode_input;
|
||||||
await tick();
|
await tick();
|
||||||
document.getElementById('access_passcode_input').focus();
|
document.getElementById('access_passcode_input')?.focus();
|
||||||
// element.focus({preventScroll:false});
|
// element.focus({preventScroll:false});
|
||||||
}}
|
}}
|
||||||
class="btn btn-sm variant-glass-success hover:variant-filled-warning access_type_unlock_btn transition-all"
|
class="btn btn-sm variant-glass-success hover:variant-filled-warning access_type_unlock_btn transition-all"
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<script lang="ts">
|
<script lang="ts">
|
||||||
import { createEventDispatcher, onMount } from 'svelte';
|
import { onMount } from 'svelte';
|
||||||
import { RadioGroup, RadioItem } from '@skeletonlabs/skeleton';
|
import { RadioGroup, RadioItem } from '@skeletonlabs/skeleton';
|
||||||
|
|
||||||
import { ae_util } from '$lib/ae_utils/ae_utils';
|
import { ae_util } from '$lib/ae_utils/ae_utils';
|
||||||
@@ -13,11 +13,11 @@ export let set_theme_mode: null|boolean = null;
|
|||||||
// export let theme_name: null|string = null;
|
// export let theme_name: null|string = null;
|
||||||
export let set_theme_name: null|boolean = null;
|
export let set_theme_name: null|boolean = null;
|
||||||
|
|
||||||
const dispatch = createEventDispatcher();
|
// const dispatch = createEventDispatcher();
|
||||||
|
|
||||||
|
|
||||||
onMount(() => {
|
onMount(() => {
|
||||||
console.log('** Element Mounted: ** Element App Config');
|
// console.log('** Element Mounted: ** Element App Config');
|
||||||
if (set_theme_mode) {
|
if (set_theme_mode) {
|
||||||
$slct_trigger = 'set_theme_mode';
|
$slct_trigger = 'set_theme_mode';
|
||||||
}
|
}
|
||||||
@@ -77,16 +77,16 @@ function handle_clear_storage(item: null|string) {
|
|||||||
// return true;
|
// return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
function dispatch_something_changed() {
|
// function dispatch_something_changed() {
|
||||||
console.log('*** dispatch_something_changed() ***');
|
// console.log('*** dispatch_something_changed() ***');
|
||||||
|
|
||||||
console.log(ae_util);
|
// console.log(ae_util);
|
||||||
console.log($ae_loc);
|
// console.log($ae_loc);
|
||||||
|
|
||||||
dispatch('access_type_changed', {
|
// dispatch('access_type_changed', {
|
||||||
access_type: $ae_loc.access_type
|
// access_type: $ae_loc.access_type
|
||||||
});
|
// });
|
||||||
}
|
// }
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
||||||
@@ -346,13 +346,12 @@ function dispatch_something_changed() {
|
|||||||
/* outline: solid thin red; */
|
/* outline: solid thin red; */
|
||||||
}
|
}
|
||||||
|
|
||||||
.access_type .current_text {
|
/* .access_type .current_text {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
} */
|
||||||
|
|
||||||
.access_type:hover .current_text {
|
/* .access_type:hover .current_text {
|
||||||
display: initial;
|
display: initial;
|
||||||
/* outline: solid thin red; */
|
} */
|
||||||
}
|
|
||||||
/* END: AE's Svelte App Config component */
|
/* END: AE's Svelte App Config component */
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -603,7 +603,7 @@ onMount(() => {
|
|||||||
{#if $ae_loc.hub?.show_element__access_type}
|
{#if $ae_loc.hub?.show_element__access_type}
|
||||||
<Element_access_type
|
<Element_access_type
|
||||||
hidden={$ae_loc.iframe && !$ae_loc.trusted_access}
|
hidden={$ae_loc.iframe && !$ae_loc.trusted_access}
|
||||||
/>
|
/>
|
||||||
{/if}
|
{/if}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user