From 79a0a690133a737a69c7a91ad73e96f60c7197ee Mon Sep 17 00:00:00 2001 From: nin-jin Date: Tue, 14 Nov 2023 08:43:40 +0000 Subject: [PATCH] separate lights and photo --- map.view.css | 10 ++++++++++ map.view.tree | 3 ++- map.view.ts | 7 ++++--- 3 files changed, 16 insertions(+), 4 deletions(-) diff --git a/map.view.css b/map.view.css index 8096621..098c45c 100644 --- a/map.view.css +++ b/map.view.css @@ -31,3 +31,13 @@ margin-left: auto; padding: var(--mol_gap_block); } + +[hyoo_map_tiles_tile] { + filter: var(--mol_theme_image); +} + +[hyoo_map_photo] { + [hyoo_map_tiles_tile] { + filter: none; + } +} diff --git a/map.view.tree b/map.view.tree index 225e1c9..f893d29 100644 --- a/map.view.tree +++ b/map.view.tree @@ -1,6 +1,6 @@ $hyoo_map $mol_view attr * - mol_theme <= theme \$mol_theme_light + hyoo_map_photo <= photo? false tiles_options * sketch \https://basemaps.cartocdn.com/rastertiles/voyager/{level}/{x}/{y}.png photo \https://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/{level}/{y}/{x} @@ -12,6 +12,7 @@ $hyoo_map $mol_view <= Search $mol_search query?val <=> query?val \ submit?event <=> search?event null + <= Lights $mol_lights_toggle <= Photo $mol_check_icon hint @ \Real Photos checked?val <=> photo?val false diff --git a/map.view.ts b/map.view.ts index c1426f6..63a4764 100644 --- a/map.view.ts +++ b/map.view.ts @@ -87,9 +87,10 @@ namespace $.$$ { return this.tiles_options()[ this.photo() ? 'photo' : 'sketch' ] } - theme() { - return this.photo() ? '$mol_theme_dark' : '$mol_theme_light' - } + // theme() { + // if( this.photo() ) return '$mol_theme_dark' + // return this.$.$mol_lights() ? '$mol_theme_light' : '$mol_theme_dark' + // } } }