1.9.4
Add City calculation Fix profile selection to new calcs
This commit is contained in:
@@ -158,13 +158,14 @@
|
|||||||
|
|
||||||
/* Per-environment gradient themes — !important keeps the gradient fixed
|
/* Per-environment gradient themes — !important keeps the gradient fixed
|
||||||
under the brass hover overlay (ui.css :hover rules load later). */
|
under the brass hover overlay (ui.css :hover rules load later). */
|
||||||
.scope-env-row[data-env="open"] .cs-btn.on { background: linear-gradient(135deg, #7ec8e3 0%, #c8922a 100%) !important; border-color: #a07020 !important; color: #fff; }
|
.scope-env-row[data-env="open"] .cs-btn.on { background: linear-gradient(135deg, #5a8a28 0%, #b8d860 100%) !important; border-color: #4a7818 !important; color: #fff; }
|
||||||
.scope-env-row[data-env="forest"] .cs-btn.on { background: linear-gradient(135deg, #1b5e3b 0%, #57bf8a 100%) !important; border-color: #1b5e3b !important; color: #fff; }
|
.scope-env-row[data-env="forest"] .cs-btn.on { background: linear-gradient(135deg, #1b5e3b 0%, #57bf8a 100%) !important; border-color: #1b5e3b !important; color: #fff; }
|
||||||
.scope-env-row[data-env="alpine"] .cs-btn.on { background: linear-gradient(135deg, #a8cfe8 0%, #dff0fa 100%) !important; border-color: #6aaedd !important; color: #1a3a58; }
|
.scope-env-row[data-env="alpine"] .cs-btn.on { background: linear-gradient(135deg, #a8cfe8 0%, #dff0fa 100%) !important; border-color: #6aaedd !important; color: #1a3a58; }
|
||||||
.scope-env-row[data-env="beach"] .cs-btn.on { background: linear-gradient(135deg, #2a8fc8 0%, #e8d87a 100%) !important; border-color: #1e78b0 !important; color: #fff; }
|
.scope-env-row[data-env="beach"] .cs-btn.on { background: linear-gradient(135deg, #2a8fc8 0%, #e8d87a 100%) !important; border-color: #1e78b0 !important; color: #fff; }
|
||||||
.scope-env-row[data-env="river"] .cs-btn.on { background: linear-gradient(135deg, #2e6e5e 0%, #78c4a8 100%) !important; border-color: #2e6e5e !important; color: #fff; }
|
.scope-env-row[data-env="river"] .cs-btn.on { background: linear-gradient(135deg, #2e6e5e 0%, #78c4a8 100%) !important; border-color: #2e6e5e !important; color: #fff; }
|
||||||
.scope-env-row[data-env="desert"] .cs-btn.on { background: linear-gradient(135deg, #b86820 0%, #e8c458 100%) !important; border-color: #a05818 !important; color: #fff; }
|
.scope-env-row[data-env="desert"] .cs-btn.on { background: linear-gradient(135deg, #b86820 0%, #e8c458 100%) !important; border-color: #a05818 !important; color: #fff; }
|
||||||
.scope-env-row[data-env="openwater"] .cs-btn.on { background: linear-gradient(135deg, #0c4878 0%, #2898d8 100%) !important; border-color: #0c4878 !important; color: #fff; }
|
.scope-env-row[data-env="openwater"] .cs-btn.on { background: linear-gradient(135deg, #0c4878 0%, #2898d8 100%) !important; border-color: #0c4878 !important; color: #fff; }
|
||||||
|
.scope-env-row[data-env="urban"] .cs-btn.on { background: linear-gradient(135deg, #4a5568 0%, #a89880 100%) !important; border-color: #3a4455 !important; color: #fff; }
|
||||||
|
|
||||||
/* On hover the brass overlay covers the interior — force white text for contrast */
|
/* On hover the brass overlay covers the interior — force white text for contrast */
|
||||||
.scope-env-row .cs-btn.on:hover { color: #fff; }
|
.scope-env-row .cs-btn.on:hover { color: #fff; }
|
||||||
|
|||||||
+11
-5
@@ -122,13 +122,14 @@ export const POLLEN_TYPES = {
|
|||||||
// label - short display name
|
// label - short display name
|
||||||
// note - shown in column header tooltip to flag modified calculation
|
// note - shown in column header tooltip to flag modified calculation
|
||||||
export const UTCI_ENVIRONMENTS = {
|
export const UTCI_ENVIRONMENTS = {
|
||||||
open: { shortLabel: null, label: 'Open / Exposed', dirFactor: 1.00, difFactor: 1.00, globFactor: 1.00, taOffset: 0.0, note: null },
|
open: { shortLabel: null, label: 'Grass / Open Field', dirFactor: 1.00, difFactor: 1.00, globFactor: 1.00, taOffset: 0.0, note: null },
|
||||||
forest: { shortLabel: 'Forest', label: 'Forest / Woodland', dirFactor: 0.15, difFactor: 0.40, globFactor: 0.20, taOffset: -2.0, note: 'Canopy-shaded estimate - direct radiation reduced 85%, air temp adjusted for evapotranspiration cooling' },
|
urban: { shortLabel: 'City', label: 'Town / City', dirFactor: 0.70, difFactor: 0.75, globFactor: 0.82, taOffset: 2.5, note: 'Urban heat island estimate - UHI raises air temp ~2–3 °C, building canyons reduce direct and diffuse solar load, reflections from concrete and glass partially offset sky-view reduction' },
|
||||||
alpine: { shortLabel: 'Alpine', label: 'High Altitude / Alpine', dirFactor: 1.15, difFactor: 1.10, globFactor: 1.12, taOffset: -1.0, note: 'Alpine estimate assuming approx. 2000 m elevation - radiation enhanced ~15% through thinner atmosphere, adjusted for exposed ridge conditions' },
|
|
||||||
beach: { shortLabel: 'Beach', label: 'Beach / Lakeside', dirFactor: 1.12, difFactor: 1.06, globFactor: 1.10, taOffset: 0.0, note: 'Reflected radiation from water and sand surfaces increases effective solar load - no shade, higher UV dose' },
|
beach: { shortLabel: 'Beach', label: 'Beach / Lakeside', dirFactor: 1.12, difFactor: 1.06, globFactor: 1.10, taOffset: 0.0, note: 'Reflected radiation from water and sand surfaces increases effective solar load - no shade, higher UV dose' },
|
||||||
river: { shortLabel: 'Riverbank', label: 'River / Riverbank', dirFactor: 0.50, difFactor: 0.60, globFactor: 0.55, taOffset: -2.5, note: 'Shaded riverbank estimate - canopy and valley walls reduce direct sun, evaporative cooling from water surface lowers apparent air temp' },
|
river: { shortLabel: 'Riverbank', label: 'River / Riverbank', dirFactor: 0.50, difFactor: 0.60, globFactor: 0.55, taOffset: -2.5, note: 'Shaded riverbank estimate - canopy and valley walls reduce direct sun, evaporative cooling from water surface lowers apparent air temp' },
|
||||||
desert: { shortLabel: 'Desert', label: 'Desert / Arid', dirFactor: 1.22, difFactor: 1.10, globFactor: 1.18, taOffset: 3.5, note: 'Extreme radiation load from high albedo sand and bare ground - ground-level heat significantly raises effective felt temperature' },
|
forest: { shortLabel: 'Forest', label: 'Forest / Woodland', dirFactor: 0.15, difFactor: 0.40, globFactor: 0.20, taOffset: -2.0, note: 'Canopy-shaded estimate - direct radiation reduced 85%, air temp adjusted for evapotranspiration cooling' },
|
||||||
openwater: { shortLabel: 'Open Water', label: 'Open Water', dirFactor: 1.14, difFactor: 1.08, globFactor: 1.12, taOffset: 0.0, note: 'Open water - full solar exposure with additional radiation reflected from the water surface, no shade or shelter, no ground heat contribution' },
|
openwater: { shortLabel: 'Open Water', label: 'Open Water', dirFactor: 1.14, difFactor: 1.08, globFactor: 1.12, taOffset: 0.0, note: 'Open water - full solar exposure with additional radiation reflected from the water surface, no shade or shelter, no ground heat contribution' },
|
||||||
|
alpine: { shortLabel: 'Alpine', label: 'High Altitude / Alpine', dirFactor: 1.15, difFactor: 1.10, globFactor: 1.12, taOffset: -1.0, note: 'Alpine estimate assuming approx. 2000 m elevation - radiation enhanced ~15% through thinner atmosphere, adjusted for exposed ridge conditions' },
|
||||||
|
desert: { shortLabel: 'Desert', label: 'Desert / Arid', dirFactor: 1.22, difFactor: 1.10, globFactor: 1.18, taOffset: 3.5, note: 'Extreme radiation load from high albedo sand and bare ground - ground-level heat significantly raises effective felt temperature' },
|
||||||
};
|
};
|
||||||
|
|
||||||
// Maps OUTDOORS_VARIANTS keys to a default UTCI_ENVIRONMENTS key.
|
// Maps OUTDOORS_VARIANTS keys to a default UTCI_ENVIRONMENTS key.
|
||||||
@@ -139,11 +140,16 @@ export const VARIANT_DEFAULT_ENV = {
|
|||||||
forest: 'forest',
|
forest: 'forest',
|
||||||
park: 'forest',
|
park: 'forest',
|
||||||
beach: 'beach',
|
beach: 'beach',
|
||||||
sailing: 'beach',
|
sailing: 'openwater',
|
||||||
hiking: 'alpine',
|
hiking: 'alpine',
|
||||||
wintersports:'alpine',
|
wintersports:'alpine',
|
||||||
fishing: 'river',
|
fishing: 'river',
|
||||||
naturist: 'beach',
|
naturist: 'beach',
|
||||||
|
urban: 'urban',
|
||||||
|
farming: 'open',
|
||||||
|
construction:'urban',
|
||||||
|
office: 'urban',
|
||||||
|
windowcleaning:'urban',
|
||||||
};
|
};
|
||||||
|
|
||||||
// Left-to-right order of the profile buttons in the top filter bar.
|
// Left-to-right order of the profile buttons in the top filter bar.
|
||||||
|
|||||||
@@ -154,6 +154,9 @@ export function useAppState() {
|
|||||||
const hasIndoor = profile.cols['indoorT'] || profile.cols['managedT'];
|
const hasIndoor = profile.cols['indoorT'] || profile.cols['managedT'];
|
||||||
setIndoorMode(hasIndoor ? 'on' : 'off');
|
setIndoorMode(hasIndoor ? 'on' : 'off');
|
||||||
setIndoorManaged(false);
|
setIndoorManaged(false);
|
||||||
|
if (hasIndoor) setBuildingTypeAndSave('brick');
|
||||||
|
const defaultEnv = VARIANT_DEFAULT_ENV[key];
|
||||||
|
if (defaultEnv) setUtciEnvAndSave(defaultEnv);
|
||||||
} else {
|
} else {
|
||||||
// Custom profile initializes from config - blank slate, user picks columns.
|
// Custom profile initializes from config - blank slate, user picks columns.
|
||||||
const customCols = FILTER_PROFILES.custom?.cols;
|
const customCols = FILTER_PROFILES.custom?.cols;
|
||||||
|
|||||||
Reference in New Issue
Block a user