Respect site cfg_json theme on first-run; add user_theme_selected flag; set flag when user selects theme or URL param
This commit is contained in:
@@ -440,11 +440,11 @@ const theme_options = [
|
||||
</div>
|
||||
<select
|
||||
bind:value={$ae_loc.theme_name}
|
||||
onchange={(e) =>
|
||||
document.documentElement.setAttribute(
|
||||
'data-theme',
|
||||
(e.target as HTMLSelectElement).value
|
||||
)}
|
||||
onchange={(e) => {
|
||||
const v = (e.target as HTMLSelectElement).value;
|
||||
document.documentElement.setAttribute('data-theme', v);
|
||||
ae_loc.update((l: any) => ({ ...l, theme_name: v, user_theme_selected: true }));
|
||||
}}
|
||||
class="select w-full border border-gray-300 bg-white text-sm text-gray-900 dark:border-gray-600 dark:bg-gray-700 dark:text-gray-100">
|
||||
{#each theme_options as opt (opt.value)}
|
||||
<option value={opt.value}
|
||||
|
||||
Reference in New Issue
Block a user