diff --git a/.nojekyll b/.nojekyll new file mode 100644 index 0000000..e69de29 diff --git a/404.html b/404.html new file mode 100644 index 0000000..96fa727 --- /dev/null +++ b/404.html @@ -0,0 +1,13 @@ + + + + + WattPatrol + + + + + + + + diff --git a/assets/audio/lightbulb/ac-0.m4a b/assets/audio/lightbulb/ac-0.m4a new file mode 100644 index 0000000..50c3e02 Binary files /dev/null and b/assets/audio/lightbulb/ac-0.m4a differ diff --git a/assets/audio/lightbulb/ac-1.m4a b/assets/audio/lightbulb/ac-1.m4a new file mode 100644 index 0000000..5e02812 Binary files /dev/null and b/assets/audio/lightbulb/ac-1.m4a differ diff --git a/assets/audio/lightbulb/ac-2.m4a b/assets/audio/lightbulb/ac-2.m4a new file mode 100644 index 0000000..3dd34f9 Binary files /dev/null and b/assets/audio/lightbulb/ac-2.m4a differ diff --git a/assets/audio/lightbulb/ac-3.m4a b/assets/audio/lightbulb/ac-3.m4a new file mode 100644 index 0000000..00ac565 Binary files /dev/null and b/assets/audio/lightbulb/ac-3.m4a differ diff --git a/assets/audio/lightbulb/ceiling-fan-0.m4a b/assets/audio/lightbulb/ceiling-fan-0.m4a new file mode 100644 index 0000000..babfe4b Binary files /dev/null and b/assets/audio/lightbulb/ceiling-fan-0.m4a differ diff --git a/assets/audio/lightbulb/ceiling-fan-1.m4a b/assets/audio/lightbulb/ceiling-fan-1.m4a new file mode 100644 index 0000000..1b9d7e6 Binary files /dev/null and b/assets/audio/lightbulb/ceiling-fan-1.m4a differ diff --git a/assets/audio/lightbulb/dryer-0.m4a b/assets/audio/lightbulb/dryer-0.m4a new file mode 100644 index 0000000..5c18845 Binary files /dev/null and b/assets/audio/lightbulb/dryer-0.m4a differ diff --git a/assets/audio/lightbulb/dryer-1.m4a b/assets/audio/lightbulb/dryer-1.m4a new file mode 100644 index 0000000..80ba13b Binary files /dev/null and b/assets/audio/lightbulb/dryer-1.m4a differ diff --git a/assets/audio/lightbulb/dryer-2.m4a b/assets/audio/lightbulb/dryer-2.m4a new file mode 100644 index 0000000..27113d4 Binary files /dev/null and b/assets/audio/lightbulb/dryer-2.m4a differ diff --git a/assets/audio/lightbulb/idle-0.m4a b/assets/audio/lightbulb/idle-0.m4a new file mode 100644 index 0000000..0af7982 Binary files /dev/null and b/assets/audio/lightbulb/idle-0.m4a differ diff --git a/assets/audio/lightbulb/idle-1.m4a b/assets/audio/lightbulb/idle-1.m4a new file mode 100644 index 0000000..ca53dd6 Binary files /dev/null and b/assets/audio/lightbulb/idle-1.m4a differ diff --git a/assets/audio/lightbulb/light-0.m4a b/assets/audio/lightbulb/light-0.m4a new file mode 100644 index 0000000..af8aebd Binary files /dev/null and b/assets/audio/lightbulb/light-0.m4a differ diff --git a/assets/audio/lightbulb/light-1.m4a b/assets/audio/lightbulb/light-1.m4a new file mode 100644 index 0000000..993ab1c Binary files /dev/null and b/assets/audio/lightbulb/light-1.m4a differ diff --git a/assets/audio/lightbulb/light-2.m4a b/assets/audio/lightbulb/light-2.m4a new file mode 100644 index 0000000..5f301f7 Binary files /dev/null and b/assets/audio/lightbulb/light-2.m4a differ diff --git a/assets/audio/lightbulb/oven-0.m4a b/assets/audio/lightbulb/oven-0.m4a new file mode 100644 index 0000000..222c7b8 Binary files /dev/null and b/assets/audio/lightbulb/oven-0.m4a differ diff --git a/assets/audio/lightbulb/oven-1.m4a b/assets/audio/lightbulb/oven-1.m4a new file mode 100644 index 0000000..a168b55 Binary files /dev/null and b/assets/audio/lightbulb/oven-1.m4a differ diff --git a/assets/audio/lightbulb/oven-2.m4a b/assets/audio/lightbulb/oven-2.m4a new file mode 100644 index 0000000..125525a Binary files /dev/null and b/assets/audio/lightbulb/oven-2.m4a differ diff --git a/assets/audio/lightbulb/porch-light-0.m4a b/assets/audio/lightbulb/porch-light-0.m4a new file mode 100644 index 0000000..72eebe6 Binary files /dev/null and b/assets/audio/lightbulb/porch-light-0.m4a differ diff --git a/assets/audio/lightbulb/porch-light-1.m4a b/assets/audio/lightbulb/porch-light-1.m4a new file mode 100644 index 0000000..00cb7e7 Binary files /dev/null and b/assets/audio/lightbulb/porch-light-1.m4a differ diff --git a/assets/audio/lightbulb/refrigerator-0.m4a b/assets/audio/lightbulb/refrigerator-0.m4a new file mode 100644 index 0000000..164d1e9 Binary files /dev/null and b/assets/audio/lightbulb/refrigerator-0.m4a differ diff --git a/assets/audio/lightbulb/refrigerator-1.m4a b/assets/audio/lightbulb/refrigerator-1.m4a new file mode 100644 index 0000000..fb15d2e Binary files /dev/null and b/assets/audio/lightbulb/refrigerator-1.m4a differ diff --git a/assets/audio/lightbulb/solar-panel-0.m4a b/assets/audio/lightbulb/solar-panel-0.m4a new file mode 100644 index 0000000..6408876 Binary files /dev/null and b/assets/audio/lightbulb/solar-panel-0.m4a differ diff --git a/assets/audio/lightbulb/solar-panel-1.m4a b/assets/audio/lightbulb/solar-panel-1.m4a new file mode 100644 index 0000000..61fc5c5 Binary files /dev/null and b/assets/audio/lightbulb/solar-panel-1.m4a differ diff --git a/assets/audio/lightbulb/solar-panel-2.m4a b/assets/audio/lightbulb/solar-panel-2.m4a new file mode 100644 index 0000000..1b9337e Binary files /dev/null and b/assets/audio/lightbulb/solar-panel-2.m4a differ diff --git a/assets/audio/lightbulb/tv-0.m4a b/assets/audio/lightbulb/tv-0.m4a new file mode 100644 index 0000000..7273041 Binary files /dev/null and b/assets/audio/lightbulb/tv-0.m4a differ diff --git a/assets/audio/lightbulb/tv-1.m4a b/assets/audio/lightbulb/tv-1.m4a new file mode 100644 index 0000000..a7265ba Binary files /dev/null and b/assets/audio/lightbulb/tv-1.m4a differ diff --git a/assets/audio/lightbulb/washer-0.m4a b/assets/audio/lightbulb/washer-0.m4a new file mode 100644 index 0000000..c471760 Binary files /dev/null and b/assets/audio/lightbulb/washer-0.m4a differ diff --git a/assets/audio/lightbulb/washer-1.m4a b/assets/audio/lightbulb/washer-1.m4a new file mode 100644 index 0000000..82cd124 Binary files /dev/null and b/assets/audio/lightbulb/washer-1.m4a differ diff --git a/assets/audio/lightbulb/washer-2.m4a b/assets/audio/lightbulb/washer-2.m4a new file mode 100644 index 0000000..b05d3ad Binary files /dev/null and b/assets/audio/lightbulb/washer-2.m4a differ diff --git a/assets/fonts/comic.ttf b/assets/fonts/comic.ttf new file mode 100644 index 0000000..d17e1be Binary files /dev/null and b/assets/fonts/comic.ttf differ diff --git a/assets/fonts/digital-7.ttf b/assets/fonts/digital-7.ttf new file mode 100644 index 0000000..74209e6 Binary files /dev/null and b/assets/fonts/digital-7.ttf differ diff --git a/assets/images/background.png b/assets/images/background.png new file mode 100644 index 0000000..ced2117 Binary files /dev/null and b/assets/images/background.png differ diff --git a/assets/images/energy-meter/grid.png b/assets/images/energy-meter/grid.png new file mode 100644 index 0000000..15960ef Binary files /dev/null and b/assets/images/energy-meter/grid.png differ diff --git a/assets/images/energy-meter/meter.png b/assets/images/energy-meter/meter.png new file mode 100644 index 0000000..6d5cfbd Binary files /dev/null and b/assets/images/energy-meter/meter.png differ diff --git a/assets/images/house/ac.png b/assets/images/house/ac.png new file mode 100644 index 0000000..eb2f0a4 Binary files /dev/null and b/assets/images/house/ac.png differ diff --git a/assets/images/house/ac_glow.png b/assets/images/house/ac_glow.png new file mode 100644 index 0000000..d2ea805 Binary files /dev/null and b/assets/images/house/ac_glow.png differ diff --git a/assets/images/house/ac_off.png b/assets/images/house/ac_off.png new file mode 100644 index 0000000..987de91 Binary files /dev/null and b/assets/images/house/ac_off.png differ diff --git a/assets/images/house/ceilingfan.png b/assets/images/house/ceilingfan.png new file mode 100644 index 0000000..a0d9531 Binary files /dev/null and b/assets/images/house/ceilingfan.png differ diff --git a/assets/images/house/ceilingfan_glow.png b/assets/images/house/ceilingfan_glow.png new file mode 100644 index 0000000..8430ec8 Binary files /dev/null and b/assets/images/house/ceilingfan_glow.png differ diff --git a/assets/images/house/dryer.png b/assets/images/house/dryer.png new file mode 100644 index 0000000..a33f400 Binary files /dev/null and b/assets/images/house/dryer.png differ diff --git a/assets/images/house/dryer_glow.png b/assets/images/house/dryer_glow.png new file mode 100644 index 0000000..5640f83 Binary files /dev/null and b/assets/images/house/dryer_glow.png differ diff --git a/assets/images/house/house.png b/assets/images/house/house.png new file mode 100644 index 0000000..a190015 Binary files /dev/null and b/assets/images/house/house.png differ diff --git a/assets/images/house/light.png b/assets/images/house/light.png new file mode 100644 index 0000000..b1fbcf5 Binary files /dev/null and b/assets/images/house/light.png differ diff --git a/assets/images/house/light_glow.png b/assets/images/house/light_glow.png new file mode 100644 index 0000000..3507b39 Binary files /dev/null and b/assets/images/house/light_glow.png differ diff --git a/assets/images/house/oven.png b/assets/images/house/oven.png new file mode 100644 index 0000000..479eb22 Binary files /dev/null and b/assets/images/house/oven.png differ diff --git a/assets/images/house/oven_glow.png b/assets/images/house/oven_glow.png new file mode 100644 index 0000000..36b78e4 Binary files /dev/null and b/assets/images/house/oven_glow.png differ diff --git a/assets/images/house/porchlight.png b/assets/images/house/porchlight.png new file mode 100644 index 0000000..a88a854 Binary files /dev/null and b/assets/images/house/porchlight.png differ diff --git a/assets/images/house/porchlight_glow.png b/assets/images/house/porchlight_glow.png new file mode 100644 index 0000000..6bdb230 Binary files /dev/null and b/assets/images/house/porchlight_glow.png differ diff --git a/assets/images/house/refrigerator.png b/assets/images/house/refrigerator.png new file mode 100644 index 0000000..5ab56db Binary files /dev/null and b/assets/images/house/refrigerator.png differ diff --git a/assets/images/house/refrigerator_glow.png b/assets/images/house/refrigerator_glow.png new file mode 100644 index 0000000..126e91d Binary files /dev/null and b/assets/images/house/refrigerator_glow.png differ diff --git a/assets/images/house/solarpanel.png b/assets/images/house/solarpanel.png new file mode 100644 index 0000000..d4b359a Binary files /dev/null and b/assets/images/house/solarpanel.png differ diff --git a/assets/images/house/solarpanel_glow.png b/assets/images/house/solarpanel_glow.png new file mode 100644 index 0000000..1dfcbd0 Binary files /dev/null and b/assets/images/house/solarpanel_glow.png differ diff --git a/assets/images/house/tv.png b/assets/images/house/tv.png new file mode 100644 index 0000000..4a032b3 Binary files /dev/null and b/assets/images/house/tv.png differ diff --git a/assets/images/house/tv_glow.png b/assets/images/house/tv_glow.png new file mode 100644 index 0000000..a356d23 Binary files /dev/null and b/assets/images/house/tv_glow.png differ diff --git a/assets/images/house/washer.png b/assets/images/house/washer.png new file mode 100644 index 0000000..932cd89 Binary files /dev/null and b/assets/images/house/washer.png differ diff --git a/assets/images/house/washer_glow.png b/assets/images/house/washer_glow.png new file mode 100644 index 0000000..c853cf3 Binary files /dev/null and b/assets/images/house/washer_glow.png differ diff --git a/assets/images/lightbulb/lightbulb.png b/assets/images/lightbulb/lightbulb.png new file mode 100644 index 0000000..c2dba40 Binary files /dev/null and b/assets/images/lightbulb/lightbulb.png differ diff --git a/assets/images/lightbulb/speech-bubble.png b/assets/images/lightbulb/speech-bubble.png new file mode 100644 index 0000000..f69c44a Binary files /dev/null and b/assets/images/lightbulb/speech-bubble.png differ diff --git a/assets/images/preview.gif b/assets/images/preview.gif new file mode 100644 index 0000000..a21453f Binary files /dev/null and b/assets/images/preview.gif differ diff --git a/assets/images/sky/day.PNG b/assets/images/sky/day.PNG new file mode 100644 index 0000000..3d1e57c Binary files /dev/null and b/assets/images/sky/day.PNG differ diff --git a/assets/images/sky/evening.PNG b/assets/images/sky/evening.PNG new file mode 100644 index 0000000..8486198 Binary files /dev/null and b/assets/images/sky/evening.PNG differ diff --git a/assets/images/sky/night.PNG b/assets/images/sky/night.PNG new file mode 100644 index 0000000..8f05921 Binary files /dev/null and b/assets/images/sky/night.PNG differ diff --git a/assets/json/lightbulb-messages-audio.json b/assets/json/lightbulb-messages-audio.json new file mode 100644 index 0000000..5142ca9 --- /dev/null +++ b/assets/json/lightbulb-messages-audio.json @@ -0,0 +1,140 @@ +{ + "ac": [ + { + "msg": "ACs use a lot of energy!", + "file": "ac-0.m4a" + }, + { + "msg": "Make sure to close all windows if the AC is on!", + "file": "ac-1.m4a" + }, + { + "msg": "Make sure to turn off the AC when you leave the house!", + "file": "ac-2.m4a" + }, + { + "msg": "Using fans with the AC can help cool the house better!", + "file": "ac-3.m4a" + } + ], + "ceiling-fan": [ + { + "msg": "Fans use much less electricity than AC.", + "file": "ceiling-fan-0.m4a" + }, + { + "msg": "It is better to open the windows when you are using fans.", + "file": "ceiling-fan-1.m4a" + } + ], + "dryer": [ + { + "msg": "Drying machines use a lot of energy!", + "file": "dryer-0.m4a" + }, + { + "msg": "Using low heat will use less energy.", + "file": "dryer-1.m4a" + }, + { + "msg": "Drying your clothes out in the sun does not use any electricity!", + "file": "dryer-2.m4a" + } + ], + "idle": [ + { + "msg": "Turn on an appliance to see how much electricity it uses!", + "file": "idle-0.m4a" + }, + { + "msg": "You can tap the screen or use the switch!", + "file": "idle-1.m4a" + } + ], + "light": [ + { + "msg": "LED lights use less energy.", + "file": "light-0.m4a" + }, + { + "msg": "LED lights can last for a long time.", + "file": "light-1.m4a" + }, + { + "msg": "Turn off the light when you leave the room to save energy!", + "file": "light-2.m4a" + } + ], + "oven": [ + { + "msg": "Electric ovens need a lot of energy.", + "file": "oven-0.m4a" + }, + { + "msg": "Ovens can be HOT. Do not use the oven without an adult around!", + "file": "oven-1.m4a" + }, + { + "msg": "Cooking on the stove uses less energy than cooking in the oven.", + "file": "oven-2.m4a" + } + ], + "porch-light": [ + { + "msg": "Motion-activated porch lights can save energy.", + "file": "porch-light-0.m4a" + }, + { + "msg": "Solar-powered porch lights are a great option to save energy!", + "file": "porch-light-1.m4a" + } + ], + "refrigerator": [ + { + "msg": "Refrigerators are always on to keep your food cold.", + "file": "refrigerator-0.m4a" + }, + { + "msg": "Try not to leave the refrigerator open for long.", + "file": "refrigerator-1.m4a" + } + ], + "solar-panel": [ + { + "msg": "Solar panels turn sunlight into energy.", + "file": "solar-panel-0.m4a" + }, + { + "msg": "Solar panels work the best when it is sunny!", + "file": "solar-panel-1.m4a" + }, + { + "msg": "Solar energy is renewable energy.", + "file": "solar-panel-2.m4a" + } + ], + "tv": [ + { + "msg": "Old CRT TVs use more energy than new LED TVs.", + "file": "tv-0.m4a" + }, + { + "msg": "Turn off the TV when you are not watching to save energy!", + "file": "tv-1.m4a" + } + ], + "washer": [ + { + "msg": "Washing machines need electricity too!", + "file": "washer-0.m4a" + }, + { + "msg": "Washing clothes with hot water uses more energy.", + "file": "washer-1.m4a" + }, + { + "msg": "Many washers have eco-friendly settings!", + "file": "washer-2.m4a" + } + ] +} \ No newline at end of file diff --git a/assets/sounds/ac-loop.mp3 b/assets/sounds/ac-loop.mp3 new file mode 100644 index 0000000..ed0c193 Binary files /dev/null and b/assets/sounds/ac-loop.mp3 differ diff --git a/assets/sounds/ac-loop.wav b/assets/sounds/ac-loop.wav new file mode 100644 index 0000000..e5058e6 Binary files /dev/null and b/assets/sounds/ac-loop.wav differ diff --git a/assets/sounds/ac-off.mp3 b/assets/sounds/ac-off.mp3 new file mode 100644 index 0000000..df733cc Binary files /dev/null and b/assets/sounds/ac-off.mp3 differ diff --git a/assets/sounds/ac-off.wav b/assets/sounds/ac-off.wav new file mode 100644 index 0000000..923024c Binary files /dev/null and b/assets/sounds/ac-off.wav differ diff --git a/assets/sounds/ac-on.mp3 b/assets/sounds/ac-on.mp3 new file mode 100644 index 0000000..b9979cb Binary files /dev/null and b/assets/sounds/ac-on.mp3 differ diff --git a/assets/sounds/ac-on.wav b/assets/sounds/ac-on.wav new file mode 100644 index 0000000..514188f Binary files /dev/null and b/assets/sounds/ac-on.wav differ diff --git a/assets/sounds/ceilingfan-off.wav b/assets/sounds/ceilingfan-off.wav new file mode 100644 index 0000000..46544b6 Binary files /dev/null and b/assets/sounds/ceilingfan-off.wav differ diff --git a/assets/sounds/ceilingfan-on.wav b/assets/sounds/ceilingfan-on.wav new file mode 100644 index 0000000..db45219 Binary files /dev/null and b/assets/sounds/ceilingfan-on.wav differ diff --git a/assets/sounds/dryer-off.wav b/assets/sounds/dryer-off.wav new file mode 100644 index 0000000..827b734 Binary files /dev/null and b/assets/sounds/dryer-off.wav differ diff --git a/assets/sounds/dryer-on.wav b/assets/sounds/dryer-on.wav new file mode 100644 index 0000000..80dd9b5 Binary files /dev/null and b/assets/sounds/dryer-on.wav differ diff --git a/assets/sounds/fan-on.mp3 b/assets/sounds/fan-on.mp3 new file mode 100644 index 0000000..ca34eab Binary files /dev/null and b/assets/sounds/fan-on.mp3 differ diff --git a/assets/sounds/light-off.wav b/assets/sounds/light-off.wav new file mode 100644 index 0000000..13bd2d3 Binary files /dev/null and b/assets/sounds/light-off.wav differ diff --git a/assets/sounds/light-on.wav b/assets/sounds/light-on.wav new file mode 100644 index 0000000..d6d91a9 Binary files /dev/null and b/assets/sounds/light-on.wav differ diff --git a/assets/sounds/oven-off.wav b/assets/sounds/oven-off.wav new file mode 100644 index 0000000..39bfdf2 Binary files /dev/null and b/assets/sounds/oven-off.wav differ diff --git a/assets/sounds/oven-on.wav b/assets/sounds/oven-on.wav new file mode 100644 index 0000000..ef4286b Binary files /dev/null and b/assets/sounds/oven-on.wav differ diff --git a/assets/sounds/porchlight-off.wav b/assets/sounds/porchlight-off.wav new file mode 100644 index 0000000..9869a21 Binary files /dev/null and b/assets/sounds/porchlight-off.wav differ diff --git a/assets/sounds/porchlight-on.wav b/assets/sounds/porchlight-on.wav new file mode 100644 index 0000000..141de71 Binary files /dev/null and b/assets/sounds/porchlight-on.wav differ diff --git a/assets/sounds/refrigerator-off.wav b/assets/sounds/refrigerator-off.wav new file mode 100644 index 0000000..3d97de9 Binary files /dev/null and b/assets/sounds/refrigerator-off.wav differ diff --git a/assets/sounds/refrigerator-on.wav b/assets/sounds/refrigerator-on.wav new file mode 100644 index 0000000..6bec864 Binary files /dev/null and b/assets/sounds/refrigerator-on.wav differ diff --git a/assets/sounds/turnoff.mp3 b/assets/sounds/turnoff.mp3 new file mode 100644 index 0000000..26c2ed1 Binary files /dev/null and b/assets/sounds/turnoff.mp3 differ diff --git a/assets/sounds/turnon.mp3 b/assets/sounds/turnon.mp3 new file mode 100644 index 0000000..088d379 Binary files /dev/null and b/assets/sounds/turnon.mp3 differ diff --git a/assets/sounds/tv-off.wav b/assets/sounds/tv-off.wav new file mode 100644 index 0000000..9cd2751 Binary files /dev/null and b/assets/sounds/tv-off.wav differ diff --git a/assets/sounds/tv-on.wav b/assets/sounds/tv-on.wav new file mode 100644 index 0000000..87ed87b Binary files /dev/null and b/assets/sounds/tv-on.wav differ diff --git a/assets/sounds/washer-off.wav b/assets/sounds/washer-off.wav new file mode 100644 index 0000000..54a804a Binary files /dev/null and b/assets/sounds/washer-off.wav differ diff --git a/assets/sounds/washer-on.wav b/assets/sounds/washer-on.wav new file mode 100644 index 0000000..3c93ea4 Binary files /dev/null and b/assets/sounds/washer-on.wav differ diff --git a/favicon.ico b/favicon.ico new file mode 100644 index 0000000..57614f9 Binary files /dev/null and b/favicon.ico differ diff --git a/index.html b/index.html new file mode 100644 index 0000000..96fa727 --- /dev/null +++ b/index.html @@ -0,0 +1,13 @@ + + + + + WattPatrol + + + + + + + + diff --git a/main-2HYIQDIK.js b/main-2HYIQDIK.js new file mode 100644 index 0000000..8f500b9 --- /dev/null +++ b/main-2HYIQDIK.js @@ -0,0 +1,9 @@ +var ZD=Object.defineProperty,QD=Object.defineProperties;var KD=Object.getOwnPropertyDescriptors;var Xp=Object.getOwnPropertySymbols;var XD=Object.prototype.hasOwnProperty,JD=Object.prototype.propertyIsEnumerable;var Jp=(t,n,e)=>n in t?ZD(t,n,{enumerable:!0,configurable:!0,writable:!0,value:e}):t[n]=e,S=(t,n)=>{for(var e in n||={})XD.call(n,e)&&Jp(t,e,n[e]);if(Xp)for(var e of Xp(n))JD.call(n,e)&&Jp(t,e,n[e]);return t},ae=(t,n)=>QD(t,KD(n));var $c=null;var Uc=1,zc=Symbol("SIGNAL");function ne(t){let n=$c;return $c=t,n}function eg(){return $c}var Wc={version:0,lastCleanEpoch:0,dirty:!1,producerNode:void 0,producerLastReadVersion:void 0,producerIndexOfThis:void 0,nextProducerIndex:0,liveConsumerNode:void 0,liveConsumerIndexOfThis:void 0,consumerAllowSignalWrites:!1,consumerIsAlwaysLive:!1,producerMustRecompute:()=>!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{}};function e_(t){if(!(Qc(t)&&!t.dirty)&&!(!t.dirty&&t.lastCleanEpoch===Uc)){if(!t.producerMustRecompute(t)&&!qc(t)){t.dirty=!1,t.lastCleanEpoch=Uc;return}t.producerRecomputeValue(t),t.dirty=!1,t.lastCleanEpoch=Uc}}function Gc(t){return t&&(t.nextProducerIndex=0),ne(t)}function tg(t,n){if(ne(n),!(!t||t.producerNode===void 0||t.producerIndexOfThis===void 0||t.producerLastReadVersion===void 0)){if(Qc(t))for(let e=t.nextProducerIndex;et.nextProducerIndex;)t.producerNode.pop(),t.producerLastReadVersion.pop(),t.producerIndexOfThis.pop()}}function qc(t){Kc(t);for(let n=0;n0}function Kc(t){t.producerNode??=[],t.producerIndexOfThis??=[],t.producerLastReadVersion??=[]}function t_(t){t.liveConsumerNode??=[],t.liveConsumerIndexOfThis??=[]}function n_(t){return t.producerNode!==void 0}function i_(){throw new Error}var r_=i_;function ng(t){r_=t}function F(t){return typeof t=="function"}function Bi(t){let e=t(i=>{Error.call(i),i.stack=new Error().stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}var _o=Bi(t=>function(e){t(this),this.message=e?`${e.length} errors occurred during unsubscription: +${e.map((i,r)=>`${r+1}) ${i.toString()}`).join(` + `)}`:"",this.name="UnsubscriptionError",this.errors=e});function ri(t,n){if(t){let e=t.indexOf(n);0<=e&&t.splice(e,1)}}var we=class t{constructor(n){this.initialTeardown=n,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let n;if(!this.closed){this.closed=!0;let{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(let s of e)s.remove(this);else e.remove(this);let{initialTeardown:i}=this;if(F(i))try{i()}catch(s){n=s instanceof _o?s.errors:[s]}let{_finalizers:r}=this;if(r){this._finalizers=null;for(let s of r)try{ig(s)}catch(o){n=n??[],o instanceof _o?n=[...n,...o.errors]:n.push(o)}}if(n)throw new _o(n)}}add(n){var e;if(n&&n!==this)if(this.closed)ig(n);else{if(n instanceof t){if(n.closed||n._hasParent(this))return;n._addParent(this)}(this._finalizers=(e=this._finalizers)!==null&&e!==void 0?e:[]).push(n)}}_hasParent(n){let{_parentage:e}=this;return e===n||Array.isArray(e)&&e.includes(n)}_addParent(n){let{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(n),e):e?[e,n]:n}_removeParent(n){let{_parentage:e}=this;e===n?this._parentage=null:Array.isArray(e)&&ri(e,n)}remove(n){let{_finalizers:e}=this;e&&ri(e,n),n instanceof t&&n._removeParent(this)}};we.EMPTY=(()=>{let t=new we;return t.closed=!0,t})();var Xc=we.EMPTY;function Co(t){return t instanceof we||t&&"closed"in t&&F(t.remove)&&F(t.add)&&F(t.unsubscribe)}function ig(t){F(t)?t():t.unsubscribe()}var It={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1};var Ui={setTimeout(t,n,...e){let{delegate:i}=Ui;return i?.setTimeout?i.setTimeout(t,n,...e):setTimeout(t,n,...e)},clearTimeout(t){let{delegate:n}=Ui;return(n?.clearTimeout||clearTimeout)(t)},delegate:void 0};function xo(t){Ui.setTimeout(()=>{let{onUnhandledError:n}=It;if(n)n(t);else throw t})}function ns(){}var rg=Jc("C",void 0,void 0);function sg(t){return Jc("E",void 0,t)}function og(t){return Jc("N",t,void 0)}function Jc(t,n,e){return{kind:t,value:n,error:e}}var si=null;function $i(t){if(It.useDeprecatedSynchronousErrorHandling){let n=!si;if(n&&(si={errorThrown:!1,error:null}),t(),n){let{errorThrown:e,error:i}=si;if(si=null,e)throw i}}else t()}function ag(t){It.useDeprecatedSynchronousErrorHandling&&si&&(si.errorThrown=!0,si.error=t)}var oi=class extends we{constructor(n){super(),this.isStopped=!1,n?(this.destination=n,Co(n)&&n.add(this)):this.destination=a_}static create(n,e,i){return new zi(n,e,i)}next(n){this.isStopped?tu(og(n),this):this._next(n)}error(n){this.isStopped?tu(sg(n),this):(this.isStopped=!0,this._error(n))}complete(){this.isStopped?tu(rg,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(n){this.destination.next(n)}_error(n){try{this.destination.error(n)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}},s_=Function.prototype.bind;function eu(t,n){return s_.call(t,n)}var nu=class{constructor(n){this.partialObserver=n}next(n){let{partialObserver:e}=this;if(e.next)try{e.next(n)}catch(i){Eo(i)}}error(n){let{partialObserver:e}=this;if(e.error)try{e.error(n)}catch(i){Eo(i)}else Eo(n)}complete(){let{partialObserver:n}=this;if(n.complete)try{n.complete()}catch(e){Eo(e)}}},zi=class extends oi{constructor(n,e,i){super();let r;if(F(n)||!n)r={next:n??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&It.useDeprecatedNextContext?(s=Object.create(n),s.unsubscribe=()=>this.unsubscribe(),r={next:n.next&&eu(n.next,s),error:n.error&&eu(n.error,s),complete:n.complete&&eu(n.complete,s)}):r=n}this.destination=new nu(r)}};function Eo(t){It.useDeprecatedSynchronousErrorHandling?ag(t):xo(t)}function o_(t){throw t}function tu(t,n){let{onStoppedNotification:e}=It;e&&Ui.setTimeout(()=>e(t,n))}var a_={closed:!0,next:ns,error:o_,complete:ns};var Wi=typeof Symbol=="function"&&Symbol.observable||"@@observable";function qe(t){return t}function iu(...t){return ru(t)}function ru(t){return t.length===0?qe:t.length===1?t[0]:function(e){return t.reduce((i,r)=>r(i),e)}}var ie=(()=>{class t{constructor(e){e&&(this._subscribe=e)}lift(e){let i=new t;return i.source=this,i.operator=e,i}subscribe(e,i,r){let s=c_(e)?e:new zi(e,i,r);return $i(()=>{let{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return i=lg(i),new i((r,s)=>{let o=new zi({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return(i=this.source)===null||i===void 0?void 0:i.subscribe(e)}[Wi](){return this}pipe(...e){return ru(e)(this)}toPromise(e){return e=lg(e),new e((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return t.create=n=>new t(n),t})();function lg(t){var n;return(n=t??It.Promise)!==null&&n!==void 0?n:Promise}function l_(t){return t&&F(t.next)&&F(t.error)&&F(t.complete)}function c_(t){return t&&t instanceof oi||l_(t)&&Co(t)}function su(t){return F(t?.lift)}function Z(t){return n=>{if(su(n))return n.lift(function(e){try{return t(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}function W(t,n,e,i,r){return new ou(t,n,e,i,r)}var ou=class extends oi{constructor(n,e,i,r,s,o){super(n),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){n.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){n.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){n.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var n;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){let{closed:e}=this;super.unsubscribe(),!e&&((n=this.onFinalize)===null||n===void 0||n.call(this))}}};function Gi(){return Z((t,n)=>{let e=null;t._refCount++;let i=W(n,void 0,void 0,void 0,()=>{if(!t||t._refCount<=0||0<--t._refCount){e=null;return}let r=t._connection,s=e;e=null,r&&(!s||r===s)&&r.unsubscribe(),n.unsubscribe()});t.subscribe(i),i.closed||(e=t.connect())})}var qi=class extends ie{constructor(n,e){super(),this.source=n,this.subjectFactory=e,this._subject=null,this._refCount=0,this._connection=null,su(n)&&(this.lift=n.lift)}_subscribe(n){return this.getSubject().subscribe(n)}getSubject(){let n=this._subject;return(!n||n.isStopped)&&(this._subject=this.subjectFactory()),this._subject}_teardown(){this._refCount=0;let{_connection:n}=this;this._subject=this._connection=null,n?.unsubscribe()}connect(){let n=this._connection;if(!n){n=this._connection=new we;let e=this.getSubject();n.add(this.source.subscribe(W(e,void 0,()=>{this._teardown(),e.complete()},i=>{this._teardown(),e.error(i)},()=>this._teardown()))),n.closed&&(this._connection=null,n=we.EMPTY)}return n}refCount(){return Gi()(this)}};var cg=Bi(t=>function(){t(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});var Ee=(()=>{class t extends ie{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){let i=new Mo(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new cg}next(e){$i(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(let i of this.currentObservers)i.next(e)}})}error(e){$i(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;let{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){$i(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;let{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return((e=this.observers)===null||e===void 0?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){let{hasError:i,isStopped:r,observers:s}=this;return i||r?Xc:(this.currentObservers=null,s.push(e),new we(()=>{this.currentObservers=null,ri(s,e)}))}_checkFinalizedStatuses(e){let{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){let e=new ie;return e.source=this,e}}return t.create=(n,e)=>new Mo(n,e),t})(),Mo=class extends Ee{constructor(n,e){super(),this.destination=n,this.source=e}next(n){var e,i;(i=(e=this.destination)===null||e===void 0?void 0:e.next)===null||i===void 0||i.call(e,n)}error(n){var e,i;(i=(e=this.destination)===null||e===void 0?void 0:e.error)===null||i===void 0||i.call(e,n)}complete(){var n,e;(e=(n=this.destination)===null||n===void 0?void 0:n.complete)===null||e===void 0||e.call(n)}_subscribe(n){var e,i;return(i=(e=this.source)===null||e===void 0?void 0:e.subscribe(n))!==null&&i!==void 0?i:Xc}};var Pe=class extends Ee{constructor(n){super(),this._value=n}get value(){return this.getValue()}_subscribe(n){let e=super._subscribe(n);return!e.closed&&n.next(this._value),e}getValue(){let{hasError:n,thrownError:e,_value:i}=this;if(n)throw e;return this._throwIfClosed(),i}next(n){super.next(this._value=n)}};var au={now(){return(au.delegate||Date).now()},delegate:void 0};var So=class extends we{constructor(n,e){super()}schedule(n,e=0){return this}};var is={setInterval(t,n,...e){let{delegate:i}=is;return i?.setInterval?i.setInterval(t,n,...e):setInterval(t,n,...e)},clearInterval(t){let{delegate:n}=is;return(n?.clearInterval||clearInterval)(t)},delegate:void 0};var Io=class extends So{constructor(n,e){super(n,e),this.scheduler=n,this.work=e,this.pending=!1}schedule(n,e=0){var i;if(this.closed)return this;this.state=n;let r=this.id,s=this.scheduler;return r!=null&&(this.id=this.recycleAsyncId(s,r,e)),this.pending=!0,this.delay=e,this.id=(i=this.id)!==null&&i!==void 0?i:this.requestAsyncId(s,this.id,e),this}requestAsyncId(n,e,i=0){return is.setInterval(n.flush.bind(n,this),i)}recycleAsyncId(n,e,i=0){if(i!=null&&this.delay===i&&this.pending===!1)return e;e!=null&&is.clearInterval(e)}execute(n,e){if(this.closed)return new Error("executing a cancelled action");this.pending=!1;let i=this._execute(n,e);if(i)return i;this.pending===!1&&this.id!=null&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))}_execute(n,e){let i=!1,r;try{this.work(n)}catch(s){i=!0,r=s||new Error("Scheduled action threw falsy error")}if(i)return this.unsubscribe(),r}unsubscribe(){if(!this.closed){let{id:n,scheduler:e}=this,{actions:i}=e;this.work=this.state=this.scheduler=null,this.pending=!1,ri(i,this),n!=null&&(this.id=this.recycleAsyncId(e,n,null)),this.delay=null,super.unsubscribe()}}};var Yi=class t{constructor(n,e=t.now){this.schedulerActionCtor=n,this.now=e}schedule(n,e=0,i){return new this.schedulerActionCtor(this,n).schedule(i,e)}};Yi.now=au.now;var Oo=class extends Yi{constructor(n,e=Yi.now){super(n,e),this.actions=[],this._active=!1}flush(n){let{actions:e}=this;if(this._active){e.push(n);return}let i;this._active=!0;do if(i=n.execute(n.state,n.delay))break;while(n=e.shift());if(this._active=!1,i){for(;n=e.shift();)n.unsubscribe();throw i}}};var lu=new Oo(Io),ug=lu;var ot=new ie(t=>t.complete());function To(t){return t&&F(t.schedule)}function dg(t){return t[t.length-1]}function hg(t){return F(dg(t))?t.pop():void 0}function In(t){return To(dg(t))?t.pop():void 0}function pg(t,n,e,i){function r(s){return s instanceof e?s:new e(function(o){o(s)})}return new(e||(e=Promise))(function(s,o){function a(u){try{c(i.next(u))}catch(d){o(d)}}function l(u){try{c(i.throw(u))}catch(d){o(d)}}function c(u){u.done?s(u.value):r(u.value).then(a,l)}c((i=i.apply(t,n||[])).next())})}function fg(t){var n=typeof Symbol=="function"&&Symbol.iterator,e=n&&t[n],i=0;if(e)return e.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&i>=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")}function ai(t){return this instanceof ai?(this.v=t,this):new ai(t)}function gg(t,n,e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var i=e.apply(t,n||[]),r,s=[];return r=Object.create((typeof AsyncIterator=="function"?AsyncIterator:Object).prototype),a("next"),a("throw"),a("return",o),r[Symbol.asyncIterator]=function(){return this},r;function o(f){return function(p){return Promise.resolve(p).then(f,d)}}function a(f,p){i[f]&&(r[f]=function(g){return new Promise(function(m,v){s.push([f,g,m,v])>1||l(f,g)})},p&&(r[f]=p(r[f])))}function l(f,p){try{c(i[f](p))}catch(g){h(s[0][3],g)}}function c(f){f.value instanceof ai?Promise.resolve(f.value.v).then(u,d):h(s[0][2],f)}function u(f){l("next",f)}function d(f){l("throw",f)}function h(f,p){f(p),s.shift(),s.length&&l(s[0][0],s[0][1])}}function mg(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n=t[Symbol.asyncIterator],e;return n?n.call(t):(t=typeof fg=="function"?fg(t):t[Symbol.iterator](),e={},i("next"),i("throw"),i("return"),e[Symbol.asyncIterator]=function(){return this},e);function i(s){e[s]=t[s]&&function(o){return new Promise(function(a,l){o=t[s](o),r(a,l,o.done,o.value)})}}function r(s,o,a,l){Promise.resolve(l).then(function(c){s({value:c,done:a})},o)}}var Ao=t=>t&&typeof t.length=="number"&&typeof t!="function";function No(t){return F(t?.then)}function Ro(t){return F(t[Wi])}function ko(t){return Symbol.asyncIterator&&F(t?.[Symbol.asyncIterator])}function Po(t){return new TypeError(`You provided ${t!==null&&typeof t=="object"?"an invalid object":`'${t}'`} where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.`)}function u_(){return typeof Symbol!="function"||!Symbol.iterator?"@@iterator":Symbol.iterator}var Lo=u_();function Fo(t){return F(t?.[Lo])}function Vo(t){return gg(this,arguments,function*(){let e=t.getReader();try{for(;;){let{value:i,done:r}=yield ai(e.read());if(r)return yield ai(void 0);yield yield ai(i)}}finally{e.releaseLock()}})}function jo(t){return F(t?.getReader)}function Me(t){if(t instanceof ie)return t;if(t!=null){if(Ro(t))return d_(t);if(Ao(t))return h_(t);if(No(t))return f_(t);if(ko(t))return vg(t);if(Fo(t))return p_(t);if(jo(t))return g_(t)}throw Po(t)}function d_(t){return new ie(n=>{let e=t[Wi]();if(F(e.subscribe))return e.subscribe(n);throw new TypeError("Provided object does not correctly implement Symbol.observable")})}function h_(t){return new ie(n=>{for(let e=0;e{t.then(e=>{n.closed||(n.next(e),n.complete())},e=>n.error(e)).then(null,xo)})}function p_(t){return new ie(n=>{for(let e of t)if(n.next(e),n.closed)return;n.complete()})}function vg(t){return new ie(n=>{m_(t,n).catch(e=>n.error(e))})}function g_(t){return vg(Vo(t))}function m_(t,n){var e,i,r,s;return pg(this,void 0,void 0,function*(){try{for(e=mg(t);i=yield e.next(),!i.done;){let o=i.value;if(n.next(o),n.closed)return}}catch(o){r={error:o}}finally{try{i&&!i.done&&(s=e.return)&&(yield s.call(e))}finally{if(r)throw r.error}}n.complete()})}function Ke(t,n,e,i=0,r=!1){let s=n.schedule(function(){e(),r?t.add(this.schedule(null,i)):this.unsubscribe()},i);if(t.add(s),!r)return s}function Ho(t,n=0){return Z((e,i)=>{e.subscribe(W(i,r=>Ke(i,t,()=>i.next(r),n),()=>Ke(i,t,()=>i.complete(),n),r=>Ke(i,t,()=>i.error(r),n)))})}function Bo(t,n=0){return Z((e,i)=>{i.add(t.schedule(()=>e.subscribe(i),n))})}function yg(t,n){return Me(t).pipe(Bo(n),Ho(n))}function bg(t,n){return Me(t).pipe(Bo(n),Ho(n))}function wg(t,n){return new ie(e=>{let i=0;return n.schedule(function(){i===t.length?e.complete():(e.next(t[i++]),e.closed||this.schedule())})})}function Dg(t,n){return new ie(e=>{let i;return Ke(e,n,()=>{i=t[Lo](),Ke(e,n,()=>{let r,s;try{({value:r,done:s}=i.next())}catch(o){e.error(o);return}s?e.complete():e.next(r)},0,!0)}),()=>F(i?.return)&&i.return()})}function Uo(t,n){if(!t)throw new Error("Iterable cannot be null");return new ie(e=>{Ke(e,n,()=>{let i=t[Symbol.asyncIterator]();Ke(e,n,()=>{i.next().then(r=>{r.done?e.complete():e.next(r.value)})},0,!0)})})}function _g(t,n){return Uo(Vo(t),n)}function Cg(t,n){if(t!=null){if(Ro(t))return yg(t,n);if(Ao(t))return wg(t,n);if(No(t))return bg(t,n);if(ko(t))return Uo(t,n);if(Fo(t))return Dg(t,n);if(jo(t))return _g(t,n)}throw Po(t)}function Ce(t,n){return n?Cg(t,n):Me(t)}function k(...t){let n=In(t);return Ce(t,n)}function Zi(t,n){let e=F(t)?t:()=>t,i=r=>r.error(e());return new ie(n?r=>n.schedule(i,0,r):i)}function cu(t){return!!t&&(t instanceof ie||F(t.lift)&&F(t.subscribe))}var on=Bi(t=>function(){t(this),this.name="EmptyError",this.message="no elements in sequence"});function xg(t){return t instanceof Date&&!isNaN(t)}function J(t,n){return Z((e,i)=>{let r=0;e.subscribe(W(i,s=>{i.next(t.call(n,s,r++))}))})}var{isArray:v_}=Array;function y_(t,n){return v_(n)?t(...n):t(n)}function Eg(t){return J(n=>y_(t,n))}var{isArray:b_}=Array,{getPrototypeOf:w_,prototype:D_,keys:__}=Object;function Mg(t){if(t.length===1){let n=t[0];if(b_(n))return{args:n,keys:null};if(C_(n)){let e=__(n);return{args:e.map(i=>n[i]),keys:e}}}return{args:t,keys:null}}function C_(t){return t&&typeof t=="object"&&w_(t)===D_}function Sg(t,n){return t.reduce((e,i,r)=>(e[i]=n[r],e),{})}function rs(...t){let n=In(t),e=hg(t),{args:i,keys:r}=Mg(t);if(i.length===0)return Ce([],n);let s=new ie(x_(i,n,r?o=>Sg(r,o):qe));return e?s.pipe(Eg(e)):s}function x_(t,n,e=qe){return i=>{Ig(n,()=>{let{length:r}=t,s=new Array(r),o=r,a=r;for(let l=0;l{let c=Ce(t[l],n),u=!1;c.subscribe(W(i,d=>{s[l]=d,u||(u=!0,a--),a||i.next(e(s.slice()))},()=>{--o||i.complete()}))},i)},i)}}function Ig(t,n,e){t?Ke(e,t,n):n()}function Og(t,n,e,i,r,s,o,a){let l=[],c=0,u=0,d=!1,h=()=>{d&&!l.length&&!c&&n.complete()},f=g=>c{s&&n.next(g),c++;let m=!1;Me(e(g,u++)).subscribe(W(n,v=>{r?.(v),s?f(v):n.next(v)},()=>{m=!0},void 0,()=>{if(m)try{for(c--;l.length&&cp(v)):p(v)}h()}catch(v){n.error(v)}}))};return t.subscribe(W(n,f,()=>{d=!0,h()})),()=>{a?.()}}function Se(t,n,e=1/0){return F(n)?Se((i,r)=>J((s,o)=>n(i,s,r,o))(Me(t(i,r))),e):(typeof n=="number"&&(e=n),Z((i,r)=>Og(i,r,t,e)))}function Qi(t=1/0){return Se(qe,t)}function Tg(){return Qi(1)}function Ki(...t){return Tg()(Ce(t,In(t)))}function $o(t){return new ie(n=>{Me(t()).subscribe(n)})}function Ag(t=0,n,e=ug){let i=-1;return n!=null&&(To(n)?e=n:i=n),new ie(r=>{let s=xg(t)?+t-e.now():t;s<0&&(s=0);let o=0;return e.schedule(function(){r.closed||(r.next(o++),0<=i?this.schedule(void 0,i):r.complete())},s)})}function Xe(t,n){return Z((e,i)=>{let r=0;e.subscribe(W(i,s=>t.call(n,s,r++)&&i.next(s)))})}function On(t){return Z((n,e)=>{let i=null,r=!1,s;i=n.subscribe(W(e,void 0,void 0,o=>{s=Me(t(o,On(t)(n))),i?(i.unsubscribe(),i=null,s.subscribe(e)):r=!0})),r&&(i.unsubscribe(),i=null,s.subscribe(e))})}function Ng(t,n,e,i,r){return(s,o)=>{let a=e,l=n,c=0;s.subscribe(W(o,u=>{let d=c++;l=a?t(l,u,d):(a=!0,u),i&&o.next(l)},r&&(()=>{a&&o.next(l),o.complete()})))}}function li(t,n){return F(n)?Se(t,n,1):Se(t,1)}function Tn(t){return Z((n,e)=>{let i=!1;n.subscribe(W(e,r=>{i=!0,e.next(r)},()=>{i||e.next(t),e.complete()}))})}function an(t){return t<=0?()=>ot:Z((n,e)=>{let i=0;n.subscribe(W(e,r=>{++i<=t&&(e.next(r),t<=i&&e.complete())}))})}function uu(t){return J(()=>t)}function zo(t,n=qe){return t=t??E_,Z((e,i)=>{let r,s=!0;e.subscribe(W(i,o=>{let a=n(o);(s||!t(r,a))&&(s=!1,r=a,i.next(o))}))})}function E_(t,n){return t===n}function Wo(t=M_){return Z((n,e)=>{let i=!1;n.subscribe(W(e,r=>{i=!0,e.next(r)},()=>i?e.complete():e.error(t())))})}function M_(){return new on}function ss(t){return Z((n,e)=>{try{n.subscribe(e)}finally{e.add(t)}})}function jt(t,n){let e=arguments.length>=2;return i=>i.pipe(t?Xe((r,s)=>t(r,s,i)):qe,an(1),e?Tn(n):Wo(()=>new on))}function Xi(t){return t<=0?()=>ot:Z((n,e)=>{let i=[];n.subscribe(W(e,r=>{i.push(r),t{for(let r of i)e.next(r);e.complete()},void 0,()=>{i=null}))})}function du(t,n){let e=arguments.length>=2;return i=>i.pipe(t?Xe((r,s)=>t(r,s,i)):qe,Xi(1),e?Tn(n):Wo(()=>new on))}function hu(t,n){return Z(Ng(t,n,arguments.length>=2,!0))}function fu(...t){let n=In(t);return Z((e,i)=>{(n?Ki(t,e,n):Ki(t,e)).subscribe(i)})}function gt(t,n){return Z((e,i)=>{let r=null,s=0,o=!1,a=()=>o&&!r&&i.complete();e.subscribe(W(i,l=>{r?.unsubscribe();let c=0,u=s++;Me(t(l,u)).subscribe(r=W(i,d=>i.next(n?n(l,d,u,c++):d),()=>{r=null,a()}))},()=>{o=!0,a()}))})}function pu(t){return Z((n,e)=>{Me(t).subscribe(W(e,()=>e.complete(),ns)),!e.closed&&n.subscribe(e)})}function Ie(t,n,e){let i=F(t)||n||e?{next:t,error:n,complete:e}:t;return i?Z((r,s)=>{var o;(o=i.subscribe)===null||o===void 0||o.call(i);let a=!0;r.subscribe(W(s,l=>{var c;(c=i.next)===null||c===void 0||c.call(i,l),s.next(l)},()=>{var l;a=!1,(l=i.complete)===null||l===void 0||l.call(i),s.complete()},l=>{var c;a=!1,(c=i.error)===null||c===void 0||c.call(i,l),s.error(l)},()=>{var l,c;a&&((l=i.unsubscribe)===null||l===void 0||l.call(i)),(c=i.finalize)===null||c===void 0||c.call(i)}))}):qe}function Rg(t,n){return Z((e,i)=>{let{leading:r=!0,trailing:s=!1}=n??{},o=!1,a=null,l=null,c=!1,u=()=>{l?.unsubscribe(),l=null,s&&(f(),c&&i.complete())},d=()=>{l=null,c&&i.complete()},h=p=>l=Me(t(p)).subscribe(W(i,u,d)),f=()=>{if(o){o=!1;let p=a;a=null,i.next(p),!c&&h(p)}};e.subscribe(W(i,p=>{o=!0,a=p,!(l&&!l.closed)&&(r?f():h(p))},()=>{c=!0,!(s&&o&&l&&!l.closed)&&i.complete()}))})}function Go(t,n=lu,e){let i=Ag(t,n);return Rg(()=>i,e)}var Em="https://g.co/ng/security#xss",T=class extends Error{constructor(n,e){super(Sd(n,e)),this.code=n}};function Sd(t,n){return`${`NG0${Math.abs(t)}`}${n?": "+n:""}`}function gs(t){return{toString:t}.toString()}var qo="__parameters__";function S_(t){return function(...e){if(t){let i=t(...e);for(let r in i)this[r]=i[r]}}}function Mm(t,n,e){return gs(()=>{let i=S_(n);function r(...s){if(this instanceof r)return i.apply(this,s),this;let o=new r(...s);return a.annotation=o,a;function a(l,c,u){let d=l.hasOwnProperty(qo)?l[qo]:Object.defineProperty(l,qo,{value:[]})[qo];for(;d.length<=u;)d.push(null);return(d[u]=d[u]||[]).push(o),l}}return e&&(r.prototype=Object.create(e.prototype)),r.prototype.ngMetadataName=t,r.annotationCls=r,r})}var Le=globalThis;function de(t){for(let n in t)if(t[n]===de)return n;throw Error("Could not find renamed property on target object.")}function I_(t,n){for(let e in n)n.hasOwnProperty(e)&&!t.hasOwnProperty(e)&&(t[e]=n[e])}function Ze(t){if(typeof t=="string")return t;if(Array.isArray(t))return"["+t.map(Ze).join(", ")+"]";if(t==null)return""+t;if(t.overriddenName)return`${t.overriddenName}`;if(t.name)return`${t.name}`;let n=t.toString();if(n==null)return""+n;let e=n.indexOf(` +`);return e===-1?n:n.substring(0,e)}function kg(t,n){return t==null||t===""?n===null?"":n:n==null||n===""?t:t+" "+n}var O_=de({__forward_ref__:de});function ms(t){return t.__forward_ref__=ms,t.toString=function(){return Ze(this())},t}function Ye(t){return Sm(t)?t():t}function Sm(t){return typeof t=="function"&&t.hasOwnProperty(O_)&&t.__forward_ref__===ms}function A(t){return{token:t.token,providedIn:t.providedIn||null,factory:t.factory,value:void 0}}function ct(t){return{providers:t.providers||[],imports:t.imports||[]}}function Pa(t){return Pg(t,Om)||Pg(t,Tm)}function Im(t){return Pa(t)!==null}function Pg(t,n){return t.hasOwnProperty(n)?t[n]:null}function T_(t){let n=t&&(t[Om]||t[Tm]);return n||null}function Lg(t){return t&&(t.hasOwnProperty(Fg)||t.hasOwnProperty(A_))?t[Fg]:null}var Om=de({\u0275prov:de}),Fg=de({\u0275inj:de}),Tm=de({ngInjectableDef:de}),A_=de({ngInjectorDef:de}),N=class{constructor(n,e){this._desc=n,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,typeof e=="number"?this.__NG_ELEMENT_ID__=e:e!==void 0&&(this.\u0275prov=A({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}};function Am(t){return t&&!!t.\u0275providers}var N_=de({\u0275cmp:de}),R_=de({\u0275dir:de}),k_=de({\u0275pipe:de}),P_=de({\u0275mod:de}),oa=de({\u0275fac:de}),as=de({__NG_ELEMENT_ID__:de}),Vg=de({__NG_ENV_ID__:de});function vs(t){return typeof t=="string"?t:t==null?"":String(t)}function L_(t){return typeof t=="function"?t.name||t.toString():typeof t=="object"&&t!=null&&typeof t.type=="function"?t.type.name||t.type.toString():vs(t)}function F_(t,n){let e=n?`. Dependency path: ${n.join(" > ")} > ${t}`:"";throw new T(-200,t)}function Id(t,n){throw new T(-201,!1)}var G=function(t){return t[t.Default=0]="Default",t[t.Host=1]="Host",t[t.Self=2]="Self",t[t.SkipSelf=4]="SkipSelf",t[t.Optional=8]="Optional",t}(G||{}),Ou;function Nm(){return Ou}function Je(t){let n=Ou;return Ou=t,n}function Rm(t,n,e){let i=Pa(t);if(i&&i.providedIn=="root")return i.value===void 0?i.value=i.factory():i.value;if(e&G.Optional)return null;if(n!==void 0)return n;Id(t,"Injector")}var V_={},cs=V_,Tu="__NG_DI_FLAG__",aa="ngTempTokenPath",j_="ngTokenPath",H_=/\n/gm,B_="\u0275",jg="__source",ir;function U_(){return ir}function An(t){let n=ir;return ir=t,n}function $_(t,n=G.Default){if(ir===void 0)throw new T(-203,!1);return ir===null?Rm(t,void 0,n):ir.get(t,n&G.Optional?null:void 0,n)}function R(t,n=G.Default){return(Nm()||$_)(Ye(t),n)}function E(t,n=G.Default){return R(t,La(n))}function La(t){return typeof t>"u"||typeof t=="number"?t:0|(t.optional&&8)|(t.host&&1)|(t.self&&2)|(t.skipSelf&&4)}function Au(t){let n=[];for(let e=0;e ");else if(typeof n=="object"){let s=[];for(let o in n)if(n.hasOwnProperty(o)){let a=n[o];s.push(o+":"+(typeof a=="string"?JSON.stringify(a):Ze(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${t.replace(H_,` + `)}`}var ys=km(Mm("Optional"),8);var Fa=km(Mm("SkipSelf"),4);function di(t,n){let e=t.hasOwnProperty(oa);return e?t[oa]:null}function q_(t,n,e){if(t.length!==n.length)return!1;for(let i=0;iArray.isArray(e)?Od(e,n):n(e))}function Pm(t,n,e){n>=t.length?t.push(e):t.splice(n,0,e)}function la(t,n){return n>=t.length-1?t.pop():t.splice(n,1)[0]}function Z_(t,n,e,i){let r=t.length;if(r==n)t.push(e,i);else if(r===1)t.push(i,t[0]),t[0]=e;else{for(r--,t.push(t[r-1],t[r]);r>n;){let s=r-2;t[r]=t[s],r--}t[n]=e,t[n+1]=i}}function Q_(t,n,e){let i=bs(t,n);return i>=0?t[i|1]=e:(i=~i,Z_(t,i,n,e)),i}function gu(t,n){let e=bs(t,n);if(e>=0)return t[e|1]}function bs(t,n){return K_(t,n,1)}function K_(t,n,e){let i=0,r=t.length>>e;for(;r!==i;){let s=i+(r-i>>1),o=t[s<n?r=s:i=s+1}return~(r<n){o=s-1;break}}}for(;s-1){let s;for(;++rs?d="":d=r[u+1].toLowerCase(),i&2&&c!==d){if(Ot(i))return!1;o=!0}}}}return Ot(i)||o}function Ot(t){return(t&1)===0}function rC(t,n,e,i){if(n===null)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else i&8?r+="."+o:i&4&&(r+=" "+o);else r!==""&&!Ot(o)&&(n+=Bg(s,r),r=""),i=o,s=s||!Ot(i);e++}return r!==""&&(n+=Bg(s,r)),n}function cC(t){return t.map(lC).join(",")}function uC(t){let n=[],e=[],i=1,r=2;for(;i{let n=Wm(t),e=ae(S({},n),{decls:t.decls,vars:t.vars,template:t.template,consts:t.consts||null,ngContentSelectors:t.ngContentSelectors,onPush:t.changeDetection===Vm.OnPush,directiveDefs:null,pipeDefs:null,dependencies:n.standalone&&t.dependencies||null,getStandaloneInjector:null,signals:t.signals??!1,data:t.data||{},encapsulation:t.encapsulation||Ut.Emulated,styles:t.styles||mt,_:null,schemas:t.schemas||null,tView:null,id:""});Gm(e);let i=t.dependencies;return e.directiveDefs=$g(i,!1),e.pipeDefs=$g(i,!0),e.id=fC(e),e})}function dC(t){return Pn(t)||Bm(t)}function hC(t){return t!==null}function ut(t){return gs(()=>({type:t.type,bootstrap:t.bootstrap||mt,declarations:t.declarations||mt,imports:t.imports||mt,exports:t.exports||mt,transitiveCompileScopes:null,schemas:t.schemas||null,id:t.id||null}))}function Ug(t,n){if(t==null)return sr;let e={};for(let i in t)if(t.hasOwnProperty(i)){let r=t[i],s,o,a=kn.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),n?(e[s]=a!==kn.None?[i,a]:i,n[s]=o):e[s]=i}return e}function wt(t){return gs(()=>{let n=Wm(t);return Gm(n),n})}function Hm(t){return{type:t.type,name:t.name,factory:null,pure:t.pure!==!1,standalone:t.standalone===!0,onDestroy:t.type.prototype.ngOnDestroy||null}}function Pn(t){return t[N_]||null}function Bm(t){return t[R_]||null}function Um(t){return t[k_]||null}function $m(t){let n=Pn(t)||Bm(t)||Um(t);return n!==null?n.standalone:!1}function zm(t,n){let e=t[P_]||null;if(!e&&n===!0)throw new Error(`Type ${Ze(t)} does not have '\u0275mod' property.`);return e}function Wm(t){let n={};return{type:t.type,providersResolver:null,factory:null,hostBindings:t.hostBindings||null,hostVars:t.hostVars||0,hostAttrs:t.hostAttrs||null,contentQueries:t.contentQueries||null,declaredInputs:n,inputTransforms:null,inputConfig:t.inputs||sr,exportAs:t.exportAs||null,standalone:t.standalone===!0,signals:t.signals===!0,selectors:t.selectors||mt,viewQuery:t.viewQuery||null,features:t.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:Ug(t.inputs,n),outputs:Ug(t.outputs),debugInfo:null}}function Gm(t){t.features?.forEach(n=>n(t))}function $g(t,n){if(!t)return null;let e=n?Um:dC;return()=>(typeof t=="function"?t():t).map(i=>e(i)).filter(hC)}function fC(t){let n=0,e=[t.selectors,t.ngContentSelectors,t.hostVars,t.hostAttrs,t.consts,t.vars,t.decls,t.encapsulation,t.standalone,t.signals,t.exportAs,JSON.stringify(t.inputs),JSON.stringify(t.outputs),Object.getOwnPropertyNames(t.type.prototype),!!t.contentQueries,!!t.viewQuery].join("|");for(let r of e)n=Math.imul(31,n)+r.charCodeAt(0)<<0;return n+=2147483648,"c"+n}function pC(...t){return{\u0275providers:qm(!0,t),\u0275fromNgModule:!0}}function qm(t,...n){let e=[],i=new Set,r,s=o=>{e.push(o)};return Od(n,o=>{let a=o;Ru(a,s,[],i)&&(r||=[],r.push(a))}),r!==void 0&&Ym(r,s),e}function Ym(t,n){for(let e=0;e{n(s,i)})}}function Ru(t,n,e,i){if(t=Ye(t),!t)return!1;let r=null,s=Lg(t),o=!s&&Pn(t);if(!s&&!o){let l=t.ngModule;if(s=Lg(l),s)r=l;else return!1}else{if(o&&!o.standalone)return!1;r=t}let a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){let l=typeof o.dependencies=="function"?o.dependencies():o.dependencies;for(let c of l)Ru(c,n,e,i)}}else if(s){if(s.imports!=null&&!a){i.add(r);let c;try{Od(s.imports,u=>{Ru(u,n,e,i)&&(c||=[],c.push(u))})}finally{}c!==void 0&&Ym(c,n)}if(!a){let c=di(r)||(()=>new r);n({provide:r,useFactory:c,deps:mt},r),n({provide:Fm,useValue:r,multi:!0},r),n({provide:or,useValue:()=>R(r),multi:!0},r)}let l=s.providers;if(l!=null&&!a){let c=t;Ad(l,u=>{n(u,c)})}}else return!1;return r!==t&&t.providers!==void 0}function Ad(t,n){for(let e of t)Am(e)&&(e=e.\u0275providers),Array.isArray(e)?Ad(e,n):n(e)}var gC=de({provide:String,useValue:de});function Zm(t){return t!==null&&typeof t=="object"&&gC in t}function mC(t){return!!(t&&t.useExisting)}function vC(t){return!!(t&&t.useFactory)}function ar(t){return typeof t=="function"}function yC(t){return!!t.useClass}var Va=new N(""),ta={},bC={},mu;function Nd(){return mu===void 0&&(mu=new ca),mu}var lt=class{},ds=class extends lt{get destroyed(){return this._destroyed}constructor(n,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,Pu(n,o=>this.processProvider(o)),this.records.set(Lm,Ji(void 0,this)),r.has("environment")&&this.records.set(lt,Ji(void 0,this));let s=this.records.get(Va);s!=null&&typeof s.value=="string"&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(Fm,mt,G.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;let n=ne(null);try{for(let i of this._ngOnDestroyHooks)i.ngOnDestroy();let e=this._onDestroyHooks;this._onDestroyHooks=[];for(let i of e)i()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear(),ne(n)}}onDestroy(n){return this.assertNotDestroyed(),this._onDestroyHooks.push(n),()=>this.removeOnDestroy(n)}runInContext(n){this.assertNotDestroyed();let e=An(this),i=Je(void 0),r;try{return n()}finally{An(e),Je(i)}}get(n,e=cs,i=G.Default){if(this.assertNotDestroyed(),n.hasOwnProperty(Vg))return n[Vg](this);i=La(i);let r,s=An(this),o=Je(void 0);try{if(!(i&G.SkipSelf)){let l=this.records.get(n);if(l===void 0){let c=xC(n)&&Pa(n);c&&this.injectableDefInScope(c)?l=Ji(ku(n),ta):l=null,this.records.set(n,l)}if(l!=null)return this.hydrate(n,l)}let a=i&G.Self?Nd():this.parent;return e=i&G.Optional&&e===cs?null:e,a.get(n,e)}catch(a){if(a.name==="NullInjectorError"){if((a[aa]=a[aa]||[]).unshift(Ze(n)),s)throw a;return W_(a,n,"R3InjectorError",this.source)}else throw a}finally{Je(o),An(s)}}resolveInjectorInitializers(){let n=ne(null),e=An(this),i=Je(void 0),r;try{let s=this.get(or,mt,G.Self);for(let o of s)o()}finally{An(e),Je(i),ne(n)}}toString(){let n=[],e=this.records;for(let i of e.keys())n.push(Ze(i));return`R3Injector[${n.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new T(205,!1)}processProvider(n){n=Ye(n);let e=ar(n)?n:Ye(n&&n.provide),i=DC(n);if(!ar(n)&&n.multi===!0){let r=this.records.get(e);r||(r=Ji(void 0,ta,!0),r.factory=()=>Au(r.multi),this.records.set(e,r)),e=n,r.multi.push(n)}this.records.set(e,i)}hydrate(n,e){let i=ne(null);try{return e.value===ta&&(e.value=bC,e.value=e.factory()),typeof e.value=="object"&&e.value&&CC(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}finally{ne(i)}}injectableDefInScope(n){if(!n.providedIn)return!1;let e=Ye(n.providedIn);return typeof e=="string"?e==="any"||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(n){let e=this._onDestroyHooks.indexOf(n);e!==-1&&this._onDestroyHooks.splice(e,1)}};function ku(t){let n=Pa(t),e=n!==null?n.factory:di(t);if(e!==null)return e;if(t instanceof N)throw new T(204,!1);if(t instanceof Function)return wC(t);throw new T(204,!1)}function wC(t){if(t.length>0)throw new T(204,!1);let e=T_(t);return e!==null?()=>e.factory(t):()=>new t}function DC(t){if(Zm(t))return Ji(void 0,t.useValue);{let n=Qm(t);return Ji(n,ta)}}function Qm(t,n,e){let i;if(ar(t)){let r=Ye(t);return di(r)||ku(r)}else if(Zm(t))i=()=>Ye(t.useValue);else if(vC(t))i=()=>t.useFactory(...Au(t.deps||[]));else if(mC(t))i=()=>R(Ye(t.useExisting));else{let r=Ye(t&&(t.useClass||t.provide));if(_C(t))i=()=>new r(...Au(t.deps));else return di(r)||ku(r)}return i}function Ji(t,n,e=!1){return{factory:t,value:n,multi:e?[]:void 0}}function _C(t){return!!t.deps}function CC(t){return t!==null&&typeof t=="object"&&typeof t.ngOnDestroy=="function"}function xC(t){return typeof t=="function"||typeof t=="object"&&t instanceof N}function Pu(t,n){for(let e of t)Array.isArray(e)?Pu(e,n):e&&Am(e)?Pu(e.\u0275providers,n):n(e)}function qt(t,n){t instanceof ds&&t.assertNotDestroyed();let e,i=An(t),r=Je(void 0);try{return n()}finally{An(i),Je(r)}}function Km(){return Nm()!==void 0||U_()!=null}function EC(t){if(!Km())throw new T(-203,!1)}function MC(t){let n=Le.ng;if(n&&n.\u0275compilerFacade)return n.\u0275compilerFacade;throw new Error("JIT compiler unavailable")}function SC(t){return typeof t=="function"}var dn=0,B=1,P=2,$e=3,Tt=4,Nt=5,ua=6,da=7,At=8,lr=9,$t=10,Oe=11,hs=12,zg=13,mr=14,zt=15,hi=16,er=17,ln=18,ja=19,Xm=20,Nn=21,vu=22,vt=23,yt=25,Jm=1;var fi=7,ha=8,cr=9,at=10,fa=function(t){return t[t.None=0]="None",t[t.HasTransplantedViews=2]="HasTransplantedViews",t}(fa||{});function Rn(t){return Array.isArray(t)&&typeof t[Jm]=="object"}function hn(t){return Array.isArray(t)&&t[Jm]===!0}function Rd(t){return(t.flags&4)!==0}function Ha(t){return t.componentOffset>-1}function Ba(t){return(t.flags&1)===1}function Ln(t){return!!t.template}function Lu(t){return(t[P]&512)!==0}var Fu=class{constructor(n,e,i){this.previousValue=n,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}};function ev(t,n,e,i){n!==null?n.applyValueToInputSignal(n,i):t[e]=i}function Rt(){return tv}function tv(t){return t.type.prototype.ngOnChanges&&(t.setInput=OC),IC}Rt.ngInherit=!0;function IC(){let t=iv(this),n=t?.current;if(n){let e=t.previous;if(e===sr)t.previous=n;else for(let i in n)e[i]=n[i];t.current=null,this.ngOnChanges(n)}}function OC(t,n,e,i,r){let s=this.declaredInputs[i],o=iv(t)||TC(t,{previous:sr,current:null}),a=o.current||(o.current={}),l=o.previous,c=l[s];a[s]=new Fu(c&&c.currentValue,e,l===sr),ev(t,n,r,e)}var nv="__ngSimpleChanges__";function iv(t){return t[nv]||null}function TC(t,n){return t[nv]=n}var Wg=null;var Ht=function(t,n,e){Wg?.(t,n,e)},rv="svg",AC="math";function Wt(t){for(;Array.isArray(t);)t=t[dn];return t}function sv(t,n){return Wt(n[t])}function Dt(t,n){return Wt(n[t.index])}function ov(t,n){return t.data[n]}function av(t,n){return t[n]}function jn(t,n){let e=n[t];return Rn(e)?e:e[dn]}function NC(t){return(t[P]&4)===4}function kd(t){return(t[P]&128)===128}function RC(t){return hn(t[$e])}function ur(t,n){return n==null?null:t[n]}function lv(t){t[er]=0}function cv(t){t[P]&1024||(t[P]|=1024,kd(t)&&$a(t))}function kC(t,n){for(;t>0;)n=n[mr],t--;return n}function Ua(t){return!!(t[P]&9216||t[vt]?.dirty)}function Vu(t){t[$t].changeDetectionScheduler?.notify(8),t[P]&64&&(t[P]|=1024),Ua(t)&&$a(t)}function $a(t){t[$t].changeDetectionScheduler?.notify(0);let n=pi(t);for(;n!==null&&!(n[P]&8192||(n[P]|=8192,!kd(n)));)n=pi(n)}function uv(t,n){if((t[P]&256)===256)throw new T(911,!1);t[Nn]===null&&(t[Nn]=[]),t[Nn].push(n)}function PC(t,n){if(t[Nn]===null)return;let e=t[Nn].indexOf(n);e!==-1&&t[Nn].splice(e,1)}function pi(t){let n=t[$e];return hn(n)?n[$e]:n}var U={lFrame:bv(null),bindingsEnabled:!0,skipHydrationRootTNode:null};var dv=!1;function LC(){return U.lFrame.elementDepthCount}function FC(){U.lFrame.elementDepthCount++}function VC(){U.lFrame.elementDepthCount--}function hv(){return U.bindingsEnabled}function jC(){return U.skipHydrationRootTNode!==null}function HC(t){return U.skipHydrationRootTNode===t}function BC(){U.skipHydrationRootTNode=null}function ee(){return U.lFrame.lView}function Ae(){return U.lFrame.tView}function Di(t){return U.lFrame.contextLView=t,t[At]}function _i(t){return U.lFrame.contextLView=null,t}function ze(){let t=fv();for(;t!==null&&t.type===64;)t=t.parent;return t}function fv(){return U.lFrame.currentTNode}function UC(){let t=U.lFrame,n=t.currentTNode;return t.isParent?n:n.parent}function Ci(t,n){let e=U.lFrame;e.currentTNode=t,e.isParent=n}function Pd(){return U.lFrame.isParent}function pv(){U.lFrame.isParent=!1}function $C(){return U.lFrame.contextLView}function gv(){return dv}function Gg(t){dv=t}function Ld(){let t=U.lFrame,n=t.bindingRootIndex;return n===-1&&(n=t.bindingRootIndex=t.tView.bindingStartIndex),n}function zC(t){return U.lFrame.bindingIndex=t}function za(){return U.lFrame.bindingIndex++}function WC(t){let n=U.lFrame,e=n.bindingIndex;return n.bindingIndex=n.bindingIndex+t,e}function GC(){return U.lFrame.inI18n}function qC(t,n){let e=U.lFrame;e.bindingIndex=e.bindingRootIndex=t,ju(n)}function YC(){return U.lFrame.currentDirectiveIndex}function ju(t){U.lFrame.currentDirectiveIndex=t}function ZC(t){let n=U.lFrame.currentDirectiveIndex;return n===-1?null:t[n]}function mv(){return U.lFrame.currentQueryIndex}function Fd(t){U.lFrame.currentQueryIndex=t}function QC(t){let n=t[B];return n.type===2?n.declTNode:n.type===1?t[Nt]:null}function vv(t,n,e){if(e&G.SkipSelf){let r=n,s=t;for(;r=r.parent,r===null&&!(e&G.Host);)if(r=QC(s),r===null||(s=s[mr],r.type&10))break;if(r===null)return!1;n=r,t=s}let i=U.lFrame=yv();return i.currentTNode=n,i.lView=t,!0}function Vd(t){let n=yv(),e=t[B];U.lFrame=n,n.currentTNode=e.firstChild,n.lView=t,n.tView=e,n.contextLView=t,n.bindingIndex=e.bindingStartIndex,n.inI18n=!1}function yv(){let t=U.lFrame,n=t===null?null:t.child;return n===null?bv(t):n}function bv(t){let n={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:t,child:null,inI18n:!1};return t!==null&&(t.child=n),n}function wv(){let t=U.lFrame;return U.lFrame=t.parent,t.currentTNode=null,t.lView=null,t}var Dv=wv;function jd(){let t=wv();t.isParent=!0,t.tView=null,t.selectedIndex=-1,t.contextLView=null,t.elementDepthCount=0,t.currentDirectiveIndex=-1,t.currentNamespace=null,t.bindingRootIndex=-1,t.bindingIndex=-1,t.currentQueryIndex=0}function KC(t){return(U.lFrame.contextLView=kC(t,U.lFrame.contextLView))[At]}function vr(){return U.lFrame.selectedIndex}function gi(t){U.lFrame.selectedIndex=t}function Hd(){let t=U.lFrame;return ov(t.tView,t.selectedIndex)}function _v(){U.lFrame.currentNamespace=rv}function Cv(){XC()}function XC(){U.lFrame.currentNamespace=null}function JC(){return U.lFrame.currentNamespace}var xv=!0;function Wa(){return xv}function Ga(t){xv=t}function ex(t,n,e){let{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=n.type.prototype;if(i){let o=tv(n);(e.preOrderHooks??=[]).push(t,o),(e.preOrderCheckHooks??=[]).push(t,o)}r&&(e.preOrderHooks??=[]).push(0-t,r),s&&((e.preOrderHooks??=[]).push(t,s),(e.preOrderCheckHooks??=[]).push(t,s))}function qa(t,n){for(let e=n.directiveStart,i=n.directiveEnd;e=i)break}else n[l]<0&&(t[er]+=65536),(a>14>16&&(t[P]&3)===n&&(t[P]+=16384,qg(a,s)):qg(a,s)}var rr=-1,mi=class{constructor(n,e,i){this.factory=n,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}};function nx(t){return t instanceof mi}function ix(t){return(t.flags&8)!==0}function rx(t){return(t.flags&16)!==0}var bu={},Hu=class{constructor(n,e){this.injector=n,this.parentInjector=e}get(n,e,i){i=La(i);let r=this.injector.get(n,bu,i);return r!==bu||e===bu?r:this.parentInjector.get(n,e,i)}};function Mv(t){return t!==rr}function pa(t){return t&32767}function sx(t){return t>>16}function ga(t,n){let e=sx(t),i=n;for(;e>0;)i=i[mr],e--;return i}var Bu=!0;function ma(t){let n=Bu;return Bu=t,n}var ox=256,Sv=ox-1,Iv=5,ax=0,Bt={};function lx(t,n,e){let i;typeof e=="string"?i=e.charCodeAt(0)||0:e.hasOwnProperty(as)&&(i=e[as]),i==null&&(i=e[as]=ax++);let r=i&Sv,s=1<>Iv)]|=s}function va(t,n){let e=Ov(t,n);if(e!==-1)return e;let i=n[B];i.firstCreatePass&&(t.injectorIndex=n.length,wu(i.data,t),wu(n,null),wu(i.blueprint,null));let r=Bd(t,n),s=t.injectorIndex;if(Mv(r)){let o=pa(r),a=ga(r,n),l=a[B].data;for(let c=0;c<8;c++)n[s+c]=a[o+c]|l[o+c]}return n[s+8]=r,s}function wu(t,n){t.push(0,0,0,0,0,0,0,0,n)}function Ov(t,n){return t.injectorIndex===-1||t.parent&&t.parent.injectorIndex===t.injectorIndex||n[t.injectorIndex+8]===null?-1:t.injectorIndex}function Bd(t,n){if(t.parent&&t.parent.injectorIndex!==-1)return t.parent.injectorIndex;let e=0,i=null,r=n;for(;r!==null;){if(i=kv(r),i===null)return rr;if(e++,r=r[mr],i.injectorIndex!==-1)return i.injectorIndex|e<<16}return rr}function Uu(t,n,e){lx(t,n,e)}function Tv(t,n,e){if(e&G.Optional||t!==void 0)return t;Id(n,"NodeInjector")}function Av(t,n,e,i){if(e&G.Optional&&i===void 0&&(i=null),!(e&(G.Self|G.Host))){let r=t[lr],s=Je(void 0);try{return r?r.get(n,i,e&G.Optional):Rm(n,i,e&G.Optional)}finally{Je(s)}}return Tv(i,n,e)}function Nv(t,n,e,i=G.Default,r){if(t!==null){if(n[P]&2048&&!(i&G.Self)){let o=hx(t,n,e,i,Bt);if(o!==Bt)return o}let s=Rv(t,n,e,i,Bt);if(s!==Bt)return s}return Av(n,e,i,r)}function Rv(t,n,e,i,r){let s=ux(e);if(typeof s=="function"){if(!vv(n,t,i))return i&G.Host?Tv(r,e,i):Av(n,e,i,r);try{let o;if(o=s(i),o==null&&!(i&G.Optional))Id(e);else return o}finally{Dv()}}else if(typeof s=="number"){let o=null,a=Ov(t,n),l=rr,c=i&G.Host?n[zt][Nt]:null;for((a===-1||i&G.SkipSelf)&&(l=a===-1?Bd(t,n):n[a+8],l===rr||!Zg(i,!1)?a=-1:(o=n[B],a=pa(l),n=ga(l,n)));a!==-1;){let u=n[B];if(Yg(s,a,u.data)){let d=cx(a,n,e,o,i,c);if(d!==Bt)return d}l=n[a+8],l!==rr&&Zg(i,n[B].data[a+8]===c)&&Yg(s,a,n)?(o=u,a=pa(l),n=ga(l,n)):a=-1}}return r}function cx(t,n,e,i,r,s){let o=n[B],a=o.data[t+8],l=i==null?Ha(a)&&Bu:i!=o&&(a.type&3)!==0,c=r&G.Host&&s===a,u=ra(a,o,e,l,c);return u!==null?vi(n,o,u,a):Bt}function ra(t,n,e,i,r){let s=t.providerIndexes,o=n.data,a=s&1048575,l=t.directiveStart,c=t.directiveEnd,u=s>>20,d=i?a:a+u,h=r?a+u:c;for(let f=d;f=l&&p.type===e)return f}if(r){let f=o[l];if(f&&Ln(f)&&f.type===e)return l}return null}function vi(t,n,e,i){let r=t[e],s=n.data;if(nx(r)){let o=r;o.resolving&&F_(L_(s[e]));let a=ma(o.canSeeViewProviders);o.resolving=!0;let l,c=o.injectImpl?Je(o.injectImpl):null,u=vv(t,i,G.Default);try{r=t[e]=o.factory(void 0,s,t,i),n.firstCreatePass&&e>=i.directiveStart&&ex(e,s[e],n)}finally{c!==null&&Je(c),ma(a),o.resolving=!1,Dv()}}return r}function ux(t){if(typeof t=="string")return t.charCodeAt(0)||0;let n=t.hasOwnProperty(as)?t[as]:void 0;return typeof n=="number"?n>=0?n&Sv:dx:n}function Yg(t,n,e){let i=1<>Iv)]&i)}function Zg(t,n){return!(t&G.Self)&&!(t&G.Host&&n)}var ui=class{constructor(n,e){this._tNode=n,this._lView=e}get(n,e,i){return Nv(this._tNode,this._lView,n,La(i),e)}};function dx(){return new ui(ze(),ee())}function Ud(t){return gs(()=>{let n=t.prototype.constructor,e=n[oa]||$u(n),i=Object.prototype,r=Object.getPrototypeOf(t.prototype).constructor;for(;r&&r!==i;){let s=r[oa]||$u(r);if(s&&s!==e)return s;r=Object.getPrototypeOf(r)}return s=>new s})}function $u(t){return Sm(t)?()=>{let n=$u(Ye(t));return n&&n()}:di(t)}function hx(t,n,e,i,r){let s=t,o=n;for(;s!==null&&o!==null&&o[P]&2048&&!(o[P]&512);){let a=Rv(s,o,e,i|G.Self,Bt);if(a!==Bt)return a;let l=s.parent;if(!l){let c=o[Xm];if(c){let u=c.get(e,Bt,i);if(u!==Bt)return u}l=kv(o),o=o[mr]}s=l}return r}function kv(t){let n=t[B],e=n.type;return e===2?n.declTNode:e===1?t[Nt]:null}function Qg(t,n=null,e=null,i){let r=Pv(t,n,e,i);return r.resolveInjectorInitializers(),r}function Pv(t,n=null,e=null,i,r=new Set){let s=[e||mt,pC(t)];return i=i||(typeof t=="object"?void 0:Ze(t)),new ds(s,n||Nd(),i||null,r)}var bt=class t{static{this.THROW_IF_NOT_FOUND=cs}static{this.NULL=new ca}static create(n,e){if(Array.isArray(n))return Qg({name:""},e,n,"");{let i=n.name??"";return Qg({name:i},n.parent,n.providers,i)}}static{this.\u0275prov=A({token:t,providedIn:"any",factory:()=>R(Lm)})}static{this.__NG_ELEMENT_ID__=-1}};var fx=new N("");fx.__NG_ELEMENT_ID__=t=>{let n=ze();if(n===null)throw new T(204,!1);if(n.type&2)return n.value;if(t&G.Optional)return null;throw new T(204,!1)};var px="ngOriginalError";function Du(t){return t[px]}var Lv=!0,$d=(()=>{class t{static{this.__NG_ELEMENT_ID__=gx}static{this.__NG_ENV_ID__=e=>e}}return t})(),zu=class extends $d{constructor(n){super(),this._lView=n}onDestroy(n){return uv(this._lView,n),()=>PC(this._lView,n)}};function gx(){return new zu(ee())}var yr=(()=>{class t{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new Pe(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);let e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),this.pendingTasks.size===0&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275prov=A({token:t,providedIn:"root",factory:()=>new t})}}return t})();var Wu=class extends Ee{constructor(n=!1){super(),this.destroyRef=void 0,this.pendingTasks=void 0,this.__isAsync=n,Km()&&(this.destroyRef=E($d,{optional:!0})??void 0,this.pendingTasks=E(yr,{optional:!0})??void 0)}emit(n){let e=ne(null);try{super.next(n)}finally{ne(e)}}subscribe(n,e,i){let r=n,s=e||(()=>null),o=i;if(n&&typeof n=="object"){let l=n;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=this.wrapInTimeout(s),r&&(r=this.wrapInTimeout(r)),o&&(o=this.wrapInTimeout(o)));let a=super.subscribe({next:r,error:s,complete:o});return n instanceof we&&n.add(a),a}wrapInTimeout(n){return e=>{let i=this.pendingTasks?.add();setTimeout(()=>{n(e),i!==void 0&&this.pendingTasks?.remove(i)})}}},re=Wu;function ya(...t){}function Fv(t){let n,e;function i(){t=ya;try{e!==void 0&&typeof cancelAnimationFrame=="function"&&cancelAnimationFrame(e),n!==void 0&&clearTimeout(n)}catch{}}return n=setTimeout(()=>{t(),i()}),typeof requestAnimationFrame=="function"&&(e=requestAnimationFrame(()=>{t(),i()})),()=>i()}function Kg(t){return queueMicrotask(()=>t()),()=>{t=ya}}var zd="isAngularZone",ba=zd+"_ID",mx=0,ue=class t{constructor(n){this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new re(!1),this.onMicrotaskEmpty=new re(!1),this.onStable=new re(!1),this.onError=new re(!1);let{enableLongStackTrace:e=!1,shouldCoalesceEventChangeDetection:i=!1,shouldCoalesceRunChangeDetection:r=!1,scheduleInRootZone:s=Lv}=n;if(typeof Zone>"u")throw new T(908,!1);Zone.assertZonePatched();let o=this;o._nesting=0,o._outer=o._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(o._inner=o._inner.fork(new Zone.TaskTrackingZoneSpec)),e&&Zone.longStackTraceZoneSpec&&(o._inner=o._inner.fork(Zone.longStackTraceZoneSpec)),o.shouldCoalesceEventChangeDetection=!r&&i,o.shouldCoalesceRunChangeDetection=r,o.callbackScheduled=!1,o.scheduleInRootZone=s,bx(o)}static isInAngularZone(){return typeof Zone<"u"&&Zone.current.get(zd)===!0}static assertInAngularZone(){if(!t.isInAngularZone())throw new T(909,!1)}static assertNotInAngularZone(){if(t.isInAngularZone())throw new T(909,!1)}run(n,e,i){return this._inner.run(n,e,i)}runTask(n,e,i,r){let s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,n,vx,ya,ya);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(n,e,i){return this._inner.runGuarded(n,e,i)}runOutsideAngular(n){return this._outer.run(n)}},vx={};function Wd(t){if(t._nesting==0&&!t.hasPendingMicrotasks&&!t.isStable)try{t._nesting++,t.onMicrotaskEmpty.emit(null)}finally{if(t._nesting--,!t.hasPendingMicrotasks)try{t.runOutsideAngular(()=>t.onStable.emit(null))}finally{t.isStable=!0}}}function yx(t){if(t.isCheckStableRunning||t.callbackScheduled)return;t.callbackScheduled=!0;function n(){Fv(()=>{t.callbackScheduled=!1,Gu(t),t.isCheckStableRunning=!0,Wd(t),t.isCheckStableRunning=!1})}t.scheduleInRootZone?Zone.root.run(()=>{n()}):t._outer.run(()=>{n()}),Gu(t)}function bx(t){let n=()=>{yx(t)},e=mx++;t._inner=t._inner.fork({name:"angular",properties:{[zd]:!0,[ba]:e,[ba+e]:!0},onInvokeTask:(i,r,s,o,a,l)=>{if(wx(l))return i.invokeTask(s,o,a,l);try{return Xg(t),i.invokeTask(s,o,a,l)}finally{(t.shouldCoalesceEventChangeDetection&&o.type==="eventTask"||t.shouldCoalesceRunChangeDetection)&&n(),Jg(t)}},onInvoke:(i,r,s,o,a,l,c)=>{try{return Xg(t),i.invoke(s,o,a,l,c)}finally{t.shouldCoalesceRunChangeDetection&&!t.callbackScheduled&&!Dx(l)&&n(),Jg(t)}},onHasTask:(i,r,s,o)=>{i.hasTask(s,o),r===s&&(o.change=="microTask"?(t._hasPendingMicrotasks=o.microTask,Gu(t),Wd(t)):o.change=="macroTask"&&(t.hasPendingMacrotasks=o.macroTask))},onHandleError:(i,r,s,o)=>(i.handleError(s,o),t.runOutsideAngular(()=>t.onError.emit(o)),!1)})}function Gu(t){t._hasPendingMicrotasks||(t.shouldCoalesceEventChangeDetection||t.shouldCoalesceRunChangeDetection)&&t.callbackScheduled===!0?t.hasPendingMicrotasks=!0:t.hasPendingMicrotasks=!1}function Xg(t){t._nesting++,t.isStable&&(t.isStable=!1,t.onUnstable.emit(null))}function Jg(t){t._nesting--,Wd(t)}var wa=class{constructor(){this.hasPendingMicrotasks=!1,this.hasPendingMacrotasks=!1,this.isStable=!0,this.onUnstable=new re,this.onMicrotaskEmpty=new re,this.onStable=new re,this.onError=new re}run(n,e,i){return n.apply(e,i)}runGuarded(n,e,i){return n.apply(e,i)}runOutsideAngular(n){return n()}runTask(n,e,i,r){return n.apply(e,i)}};function wx(t){return Vv(t,"__ignore_ng_zone__")}function Dx(t){return Vv(t,"__scheduler_tick__")}function Vv(t,n){return!Array.isArray(t)||t.length!==1?!1:t[0]?.data?.[n]===!0}function _x(t="zone.js",n){return t==="noop"?new wa:t==="zone.js"?new ue(n):t}var cn=class{constructor(){this._console=console}handleError(n){let e=this._findOriginalError(n);this._console.error("ERROR",n),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(n){let e=n&&Du(n);for(;e&&Du(e);)e=Du(e);return e||null}},Cx=new N("",{providedIn:"root",factory:()=>{let t=E(ue),n=E(cn);return e=>t.runOutsideAngular(()=>n.handleError(e))}});function xx(){return br(ze(),ee())}function br(t,n){return new We(Dt(t,n))}var We=(()=>{class t{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=xx}}return t})();function Ex(t){return t instanceof We?t.nativeElement:t}function Mx(){return this._results[Symbol.iterator]()}var qu=class t{get changes(){return this._changes??=new re}constructor(n=!1){this._emitDistinctChangesOnly=n,this.dirty=!0,this._onDirty=void 0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;let e=t.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=Mx)}get(n){return this._results[n]}map(n){return this._results.map(n)}filter(n){return this._results.filter(n)}find(n){return this._results.find(n)}reduce(n,e){return this._results.reduce(n,e)}forEach(n){this._results.forEach(n)}some(n){return this._results.some(n)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(n,e){this.dirty=!1;let i=Y_(n);(this._changesDetected=!q_(this._results,i,e))&&(this._results=i,this.length=i.length,this.last=i[this.length-1],this.first=i[0])}notifyOnChanges(){this._changes!==void 0&&(this._changesDetected||!this._emitDistinctChangesOnly)&&this._changes.emit(this)}onDirty(n){this._onDirty=n}setDirty(){this.dirty=!0,this._onDirty?.()}destroy(){this._changes!==void 0&&(this._changes.complete(),this._changes.unsubscribe())}};function jv(t){return(t.flags&128)===128}var Hv=new Map,Sx=0;function Ix(){return Sx++}function Ox(t){Hv.set(t[ja],t)}function Yu(t){Hv.delete(t[ja])}var em="__ngContext__";function Fn(t,n){Rn(n)?(t[em]=n[ja],Ox(n)):t[em]=n}function Bv(t){return $v(t[hs])}function Uv(t){return $v(t[Tt])}function $v(t){for(;t!==null&&!hn(t);)t=t[Tt];return t}var Zu;function zv(t){Zu=t}function Wv(){if(Zu!==void 0)return Zu;if(typeof document<"u")return document;throw new T(210,!1)}var Ya=new N("",{providedIn:"root",factory:()=>Tx}),Tx="ng",Gd=new N(""),Hn=new N("",{providedIn:"platform",factory:()=>"unknown"});var qd=new N("",{providedIn:"root",factory:()=>Wv().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});var Ax="h",Nx="b";var Rx=()=>null;function Yd(t,n,e=!1){return Rx(t,n,e)}var Gv=!1,kx=new N("",{providedIn:"root",factory:()=>Gv});var Yo;function Px(){if(Yo===void 0&&(Yo=null,Le.trustedTypes))try{Yo=Le.trustedTypes.createPolicy("angular",{createHTML:t=>t,createScript:t=>t,createScriptURL:t=>t})}catch{}return Yo}function Za(t){return Px()?.createHTML(t)||t}var Zo;function Lx(){if(Zo===void 0&&(Zo=null,Le.trustedTypes))try{Zo=Le.trustedTypes.createPolicy("angular#unsafe-bypass",{createHTML:t=>t,createScript:t=>t,createScriptURL:t=>t})}catch{}return Zo}function tm(t){return Lx()?.createHTML(t)||t}var Da=class{constructor(n){this.changingThisBreaksApplicationSecurity=n}toString(){return`SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity} (see ${Em})`}};function ws(t){return t instanceof Da?t.changingThisBreaksApplicationSecurity:t}function Zd(t,n){let e=Fx(t);if(e!=null&&e!==n){if(e==="ResourceURL"&&n==="URL")return!0;throw new Error(`Required a safe ${n}, got a ${e} (see ${Em})`)}return e===n}function Fx(t){return t instanceof Da&&t.getTypeName()||null}function Vx(t){let n=new Ku(t);return jx()?new Qu(n):n}var Qu=class{constructor(n){this.inertDocumentHelper=n}getInertBodyElement(n){n=""+n;try{let e=new window.DOMParser().parseFromString(Za(n),"text/html").body;return e===null?this.inertDocumentHelper.getInertBodyElement(n):(e.firstChild?.remove(),e)}catch{return null}}},Ku=class{constructor(n){this.defaultDoc=n,this.inertDocument=this.defaultDoc.implementation.createHTMLDocument("sanitization-inert")}getInertBodyElement(n){let e=this.inertDocument.createElement("template");return e.innerHTML=Za(n),e}};function jx(){try{return!!new window.DOMParser().parseFromString(Za(""),"text/html")}catch{return!1}}var Hx=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:\/?#]*(?:[\/?#]|$))/i;function Qd(t){return t=String(t),t.match(Hx)?t:"unsafe:"+t}function fn(t){let n={};for(let e of t.split(","))n[e]=!0;return n}function Ds(...t){let n={};for(let e of t)for(let i in e)e.hasOwnProperty(i)&&(n[i]=!0);return n}var qv=fn("area,br,col,hr,img,wbr"),Yv=fn("colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr"),Zv=fn("rp,rt"),Bx=Ds(Zv,Yv),Ux=Ds(Yv,fn("address,article,aside,blockquote,caption,center,del,details,dialog,dir,div,dl,figure,figcaption,footer,h1,h2,h3,h4,h5,h6,header,hgroup,hr,ins,main,map,menu,nav,ol,pre,section,summary,table,ul")),$x=Ds(Zv,fn("a,abbr,acronym,audio,b,bdi,bdo,big,br,cite,code,del,dfn,em,font,i,img,ins,kbd,label,map,mark,picture,q,ruby,rp,rt,s,samp,small,source,span,strike,strong,sub,sup,time,track,tt,u,var,video")),nm=Ds(qv,Ux,$x,Bx),Qv=fn("background,cite,href,itemtype,longdesc,poster,src,xlink:href"),zx=fn("abbr,accesskey,align,alt,autoplay,axis,bgcolor,border,cellpadding,cellspacing,class,clear,color,cols,colspan,compact,controls,coords,datetime,default,dir,download,face,headers,height,hidden,hreflang,hspace,ismap,itemscope,itemprop,kind,label,lang,language,loop,media,muted,nohref,nowrap,open,preload,rel,rev,role,rows,rowspan,rules,scope,scrolling,shape,size,sizes,span,srclang,srcset,start,summary,tabindex,target,title,translate,type,usemap,valign,value,vspace,width"),Wx=fn("aria-activedescendant,aria-atomic,aria-autocomplete,aria-busy,aria-checked,aria-colcount,aria-colindex,aria-colspan,aria-controls,aria-current,aria-describedby,aria-details,aria-disabled,aria-dropeffect,aria-errormessage,aria-expanded,aria-flowto,aria-grabbed,aria-haspopup,aria-hidden,aria-invalid,aria-keyshortcuts,aria-label,aria-labelledby,aria-level,aria-live,aria-modal,aria-multiline,aria-multiselectable,aria-orientation,aria-owns,aria-placeholder,aria-posinset,aria-pressed,aria-readonly,aria-relevant,aria-required,aria-roledescription,aria-rowcount,aria-rowindex,aria-rowspan,aria-selected,aria-setsize,aria-sort,aria-valuemax,aria-valuemin,aria-valuenow,aria-valuetext"),Gx=Ds(Qv,zx,Wx),qx=fn("script,style,template"),Xu=class{constructor(){this.sanitizedSomething=!1,this.buf=[]}sanitizeChildren(n){let e=n.firstChild,i=!0,r=[];for(;e;){if(e.nodeType===Node.ELEMENT_NODE?i=this.startElement(e):e.nodeType===Node.TEXT_NODE?this.chars(e.nodeValue):this.sanitizedSomething=!0,i&&e.firstChild){r.push(e),e=Qx(e);continue}for(;e;){e.nodeType===Node.ELEMENT_NODE&&this.endElement(e);let s=Zx(e);if(s){e=s;break}e=r.pop()}}return this.buf.join("")}startElement(n){let e=im(n).toLowerCase();if(!nm.hasOwnProperty(e))return this.sanitizedSomething=!0,!qx.hasOwnProperty(e);this.buf.push("<"),this.buf.push(e);let i=n.attributes;for(let r=0;r"),!0}endElement(n){let e=im(n).toLowerCase();nm.hasOwnProperty(e)&&!qv.hasOwnProperty(e)&&(this.buf.push(""))}chars(n){this.buf.push(rm(n))}};function Yx(t,n){return(t.compareDocumentPosition(n)&Node.DOCUMENT_POSITION_CONTAINED_BY)!==Node.DOCUMENT_POSITION_CONTAINED_BY}function Zx(t){let n=t.nextSibling;if(n&&t!==n.previousSibling)throw Kv(n);return n}function Qx(t){let n=t.firstChild;if(n&&Yx(t,n))throw Kv(n);return n}function im(t){let n=t.nodeName;return typeof n=="string"?n:"FORM"}function Kv(t){return new Error(`Failed to sanitize html because the element is clobbered: ${t.outerHTML}`)}var Kx=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,Xx=/([^\#-~ |!])/g;function rm(t){return t.replace(/&/g,"&").replace(Kx,function(n){let e=n.charCodeAt(0),i=n.charCodeAt(1);return"&#"+((e-55296)*1024+(i-56320)+65536)+";"}).replace(Xx,function(n){return"&#"+n.charCodeAt(0)+";"}).replace(//g,">")}var Qo;function Xv(t,n){let e=null;try{Qo=Qo||Vx(t);let i=n?String(n):"";e=Qo.getInertBodyElement(i);let r=5,s=i;do{if(r===0)throw new Error("Failed to sanitize html because the input is unstable");r--,i=s,s=e.innerHTML,e=Qo.getInertBodyElement(i)}while(i!==s);let a=new Xu().sanitizeChildren(sm(e)||e);return Za(a)}finally{if(e){let i=sm(e)||e;for(;i.firstChild;)i.firstChild.remove()}}}function sm(t){return"content"in t&&Jx(t)?t.content:null}function Jx(t){return t.nodeType===Node.ELEMENT_NODE&&t.nodeName==="TEMPLATE"}var Qa=function(t){return t[t.NONE=0]="NONE",t[t.HTML=1]="HTML",t[t.STYLE=2]="STYLE",t[t.SCRIPT=3]="SCRIPT",t[t.URL=4]="URL",t[t.RESOURCE_URL=5]="RESOURCE_URL",t}(Qa||{});function Jv(t){let n=ey();return n?tm(n.sanitize(Qa.HTML,t)||""):Zd(t,"HTML")?tm(ws(t)):Xv(Wv(),vs(t))}function kt(t){let n=ey();return n?n.sanitize(Qa.URL,t)||"":Zd(t,"URL")?ws(t):Qd(vs(t))}function ey(){let t=ee();return t&&t[$t].sanitizer}var eE=/^>|^->||--!>|)/g,nE="\u200B$1\u200B";function iE(t){return t.replace(eE,n=>n.replace(tE,nE))}function ty(t){return t.ownerDocument.defaultView}function ny(t){return t instanceof Function?t():t}function rE(t){return(t??E(bt)).get(Hn)==="browser"}var Gt=function(t){return t[t.Important=1]="Important",t[t.DashCase=2]="DashCase",t}(Gt||{}),sE;function Kd(t,n){return sE(t,n)}function tr(t,n,e,i,r){if(i!=null){let s,o=!1;hn(i)?s=i:Rn(i)&&(o=!0,i=i[dn]);let a=Wt(i);t===0&&e!==null?r==null?ay(n,e,a):_a(n,e,a,r||null,!0):t===1&&e!==null?_a(n,e,a,r||null,!0):t===2?DE(n,a,o):t===3&&n.destroyNode(a),s!=null&&CE(n,t,s,e,r)}}function oE(t,n){return t.createText(n)}function aE(t,n,e){t.setValue(n,e)}function lE(t,n){return t.createComment(iE(n))}function iy(t,n,e){return t.createElement(n,e)}function cE(t,n){ry(t,n),n[dn]=null,n[Nt]=null}function uE(t,n,e,i,r,s){i[dn]=r,i[Nt]=n,Xa(t,i,e,1,r,s)}function ry(t,n){n[$t].changeDetectionScheduler?.notify(9),Xa(t,n,n[Oe],2,null,null)}function dE(t){let n=t[hs];if(!n)return _u(t[B],t);for(;n;){let e=null;if(Rn(n))e=n[hs];else{let i=n[at];i&&(e=i)}if(!e){for(;n&&!n[Tt]&&n!==t;)Rn(n)&&_u(n[B],n),n=n[$e];n===null&&(n=t),Rn(n)&&_u(n[B],n),e=n&&n[Tt]}n=e}}function hE(t,n,e,i){let r=at+i,s=e.length;i>0&&(e[r-1][Tt]=n),i0&&(t[e-1][Tt]=i[Tt]);let s=la(t,at+n);cE(i[B],i);let o=s[ln];o!==null&&o.detachView(s[B]),i[$e]=null,i[Tt]=null,i[P]&=-129}return i}function oy(t,n){if(!(n[P]&256)){let e=n[Oe];e.destroyNode&&Xa(t,n,e,3,null,null),dE(n)}}function _u(t,n){if(n[P]&256)return;let e=ne(null);try{n[P]&=-129,n[P]|=256,n[vt]&&Yc(n[vt]),pE(t,n),fE(t,n),n[B].type===1&&n[Oe].destroy();let i=n[hi];if(i!==null&&hn(n[$e])){i!==n[$e]&&Xd(i,n);let r=n[ln];r!==null&&r.detachView(t)}Yu(n)}finally{ne(e)}}function fE(t,n){let e=t.cleanup,i=n[da];if(e!==null)for(let s=0;s=0?i[o]():i[-o].unsubscribe(),s+=2}else{let o=i[e[s+1]];e[s].call(o)}i!==null&&(n[da]=null);let r=n[Nn];if(r!==null){n[Nn]=null;for(let s=0;s-1){let{encapsulation:s}=t.data[i.directiveStart+r];if(s===Ut.None||s===Ut.Emulated)return null}return Dt(i,e)}}function _a(t,n,e,i,r){t.insertBefore(n,e,i,r)}function ay(t,n,e){t.appendChild(n,e)}function om(t,n,e,i,r){i!==null?_a(t,n,e,i,r):ay(t,n,e)}function ly(t,n){return t.parentNode(n)}function vE(t,n){return t.nextSibling(n)}function yE(t,n,e){return wE(t,n,e)}function bE(t,n,e){return t.type&40?Dt(t,e):null}var wE=bE,am;function Ka(t,n,e,i){let r=gE(t,i,n),s=n[Oe],o=i.parent||n[Nt],a=yE(o,i,n);if(r!=null)if(Array.isArray(e))for(let l=0;lyt&&hy(t,n,yt,!1),Ht(o?2:0,r),e(i,r)}finally{gi(s),Ht(o?3:1,r)}}function eh(t,n,e){if(Rd(n)){let i=ne(null);try{let r=n.directiveStart,s=n.directiveEnd;for(let o=r;onull;function NE(t,n,e,i){let r=Cy(n);r.push(e),t.firstCreatePass&&xy(t).push(i,r.length-1)}function RE(t,n,e,i,r,s){let o=n?n.injectorIndex:-1,a=0;return jC()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:n,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}function lm(t,n,e,i,r){for(let s in n){if(!n.hasOwnProperty(s))continue;let o=n[s];if(o===void 0)continue;i??={};let a,l=kn.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let c=s;if(r!==null){if(!r.hasOwnProperty(s))continue;c=r[s]}t===0?cm(i,e,c,a,l):cm(i,e,c,a)}return i}function cm(t,n,e,i,r){let s;t.hasOwnProperty(e)?(s=t[e]).push(n,i):s=t[e]=[n,i],r!==void 0&&s.push(r)}function kE(t,n,e){let i=n.directiveStart,r=n.directiveEnd,s=t.data,o=n.attrs,a=[],l=null,c=null;for(let u=i;u0;){let e=t[--n];if(typeof e=="number"&&e<0)return e}return 0}function jE(t,n,e,i){let r=e.directiveStart,s=e.directiveEnd;Ha(e)&&GE(n,e,t.data[r+e.componentOffset]),t.firstCreatePass||va(e,n),Fn(i,n);let o=e.initialInputs;for(let a=r;a{$a(t.lView)},consumerOnSignalRead(){this.lView[vt]=this}});function lM(t){let n=t[vt]??Object.create(cM);return n.lView=t,n}var cM=ae(S({},Wc),{consumerIsAlwaysLive:!0,consumerMarkedDirty:t=>{let n=pi(t.lView);for(;n&&!Sy(n[B]);)n=pi(n);n&&cv(n)},consumerOnSignalRead(){this.lView[vt]=this}});function Sy(t){return t.type!==2}var uM=100;function Iy(t,n=!0,e=0){let i=t[$t],r=i.rendererFactory,s=!1;s||r.begin?.();try{dM(t,e)}catch(o){throw n&&Ey(t,o),o}finally{s||(r.end?.(),i.inlineEffectRunner?.flush())}}function dM(t,n){let e=gv();try{Gg(!0),id(t,n);let i=0;for(;Ua(t);){if(i===uM)throw new T(103,!1);i++,id(t,1)}}finally{Gg(e)}}function hM(t,n,e,i){let r=n[P];if((r&256)===256)return;let s=!1,o=!1;!s&&n[$t].inlineEffectRunner?.flush(),Vd(n);let a=!0,l=null,c=null;s||(Sy(t)?(c=rM(n),l=Gc(c)):eg()===null?(a=!1,c=lM(n),l=Gc(c)):n[vt]&&(Yc(n[vt]),n[vt]=null));try{lv(n),zC(t.bindingStartIndex),e!==null&&my(t,n,e,2,i);let u=(r&3)===3;if(!s)if(u){let f=t.preOrderCheckHooks;f!==null&&na(n,f,null)}else{let f=t.preOrderHooks;f!==null&&ia(n,f,0,null),yu(n,0)}if(o||fM(n),Oy(n,0),t.contentQueries!==null&&_y(t,n),!s)if(u){let f=t.contentCheckHooks;f!==null&&na(n,f)}else{let f=t.contentHooks;f!==null&&ia(n,f,1),yu(n,1)}ME(t,n);let d=t.components;d!==null&&Ay(n,d,0);let h=t.viewQuery;if(h!==null&&nd(2,h,i),!s)if(u){let f=t.viewCheckHooks;f!==null&&na(n,f)}else{let f=t.viewHooks;f!==null&&ia(n,f,2),yu(n,2)}if(t.firstUpdatePass===!0&&(t.firstUpdatePass=!1),n[vu]){for(let f of n[vu])f();n[vu]=null}s||(n[P]&=-73)}catch(u){throw s||$a(n),u}finally{c!==null&&(tg(c,l),a&&oM(c)),jd()}}function Oy(t,n){for(let e=Bv(t);e!==null;e=Uv(e))for(let i=at;i-1&&(Ju(n,i),la(e,i))}this._attachedToViewContainer=!1}oy(this._lView[B],this._lView)}onDestroy(n){uv(this._lView,n)}markForCheck(){ah(this._cdRefInjectingView||this._lView,4)}detach(){this._lView[P]&=-129}reattach(){Vu(this._lView),this._lView[P]|=128}detectChanges(){this._lView[P]|=1024,Iy(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new T(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null;let n=Lu(this._lView),e=this._lView[hi];e!==null&&!n&&Xd(e,this._lView),ry(this._lView[B],this._lView)}attachToAppRef(n){if(this._attachedToViewContainer)throw new T(902,!1);this._appRef=n;let e=Lu(this._lView),i=this._lView[hi];i!==null&&!e&&sy(i,this._lView),Vu(this._lView)}},bi=(()=>{class t{static{this.__NG_ELEMENT_ID__=vM}}return t})(),gM=bi,mM=class extends gM{constructor(n,e,i){super(),this._declarationLView=n,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(n,e){return this.createEmbeddedViewImpl(n,e)}createEmbeddedViewImpl(n,e,i){let r=tM(this._declarationLView,this._declarationTContainer,n,{embeddedViewInjector:e,dehydratedView:i});return new yi(r)}};function vM(){return lh(ze(),ee())}function lh(t,n){return t.type&4?new mM(n,t,br(t,n)):null}var lB=new RegExp(`^(\\d+)*(${Nx}|${Ax})*(.*)`);var yM=()=>null;function dm(t,n){return yM(t,n)}var dr=class{},ch=new N("",{providedIn:"root",factory:()=>!1});var Ny=new N(""),Ry=new N(""),rd=class{},xa=class{};function bM(t){let n=Error(`No component factory found for ${Ze(t)}.`);return n[wM]=t,n}var wM="ngComponent";var sd=class{resolveComponentFactory(n){throw bM(n)}},hr=class{static{this.NULL=new sd}},fr=class{},_t=(()=>{class t{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>DM()}}return t})();function DM(){let t=ee(),n=ze(),e=jn(n.index,t);return(Rn(e)?e:t)[Oe]}var _M=(()=>{class t{static{this.\u0275prov=A({token:t,providedIn:"root",factory:()=>null})}}return t})();function Ea(t,n,e){let i=e?t.styles:null,r=e?t.classes:null,s=0;if(n!==null)for(let o=0;o0&&uy(t,e,s.join(" "))}}function OM(t,n,e){let i=t.projection=[];for(let r=0;r{class t{static{this.__NG_ELEMENT_ID__=AM}}return t})();function AM(){let t=ze();return Py(t,ee())}var NM=pn,ky=class extends NM{constructor(n,e,i){super(),this._lContainer=n,this._hostTNode=e,this._hostLView=i}get element(){return br(this._hostTNode,this._hostLView)}get injector(){return new ui(this._hostTNode,this._hostLView)}get parentInjector(){let n=Bd(this._hostTNode,this._hostLView);if(Mv(n)){let e=ga(n,this._hostLView),i=pa(n),r=e[B].data[i+8];return new ui(r,e)}else return new ui(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(n){let e=fm(this._lContainer);return e!==null&&e[n]||null}get length(){return this._lContainer.length-at}createEmbeddedView(n,e,i){let r,s;typeof i=="number"?r=i:i!=null&&(r=i.index,s=i.injector);let o=dm(this._lContainer,n.ssrId),a=n.createEmbeddedViewImpl(e||{},s,o);return this.insertImpl(a,r,um(this._hostTNode,o)),a}createComponent(n,e,i,r,s){let o=n&&!SC(n),a;if(o)a=e;else{let p=e||{};a=p.index,i=p.injector,r=p.projectableNodes,s=p.environmentInjector||p.ngModuleRef}let l=o?n:new pr(Pn(n)),c=i||this.parentInjector;if(!s&&l.ngModule==null){let g=(o?c:this.parentInjector).get(lt,null);g&&(s=g)}let u=Pn(l.componentType??{}),d=dm(this._lContainer,u?.id??null),h=d?.firstChild??null,f=l.create(c,r,h,s);return this.insertImpl(f.hostView,a,um(this._hostTNode,d)),f}insert(n,e){return this.insertImpl(n,e,!0)}insertImpl(n,e,i){let r=n._lView;if(RC(r)){let a=this.indexOf(n);if(a!==-1)this.detach(a);else{let l=r[$e],c=new ky(l,l[Nt],l[$e]);c.detach(c.indexOf(n))}}let s=this._adjustIndex(e),o=this._lContainer;return nM(o,r,s,i),n.attachToViewContainerRef(),Pm(Cu(o),s,n),n}move(n,e){return this.insert(n,e)}indexOf(n){let e=fm(this._lContainer);return e!==null?e.indexOf(n):-1}remove(n){let e=this._adjustIndex(n,-1),i=Ju(this._lContainer,e);i&&(la(Cu(this._lContainer),e),oy(i[B],i))}detach(n){let e=this._adjustIndex(n,-1),i=Ju(this._lContainer,e);return i&&la(Cu(this._lContainer),e)!=null?new yi(i):null}_adjustIndex(n,e=0){return n??this.length+e}};function fm(t){return t[ha]}function Cu(t){return t[ha]||(t[ha]=[])}function Py(t,n){let e,i=n[t.index];return hn(i)?e=i:(e=Dy(i,n,null,t),n[t.index]=e,el(n,e)),kM(e,n,t,i),new ky(e,t,n)}function RM(t,n){let e=t[Oe],i=e.createComment(""),r=Dt(n,t),s=ly(e,r);return _a(e,s,i,vE(e,r),!1),i}var kM=FM,PM=()=>!1;function LM(t,n,e){return PM(t,n,e)}function FM(t,n,e,i){if(t[fi])return;let r;e.type&8?r=Wt(i):r=RM(n,e),t[fi]=r}var ad=class t{constructor(n){this.queryList=n,this.matches=null}clone(){return new t(this.queryList)}setDirty(){this.queryList.setDirty()}},ld=class t{constructor(n=[]){this.queries=n}createEmbeddedView(n){let e=n.queries;if(e!==null){let i=n.contentQueries!==null?n.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{let c=s[a+1],u=n[-l];for(let d=at;dn.trim())}function Vy(t,n,e){t.queries===null&&(t.queries=new cd),t.queries.track(new ud(n,e))}function GM(t,n){let e=t.contentQueries||(t.contentQueries=[]),i=e.length?e[e.length-1]:-1;n!==i&&e.push(t.queries.length-1,n)}function uh(t,n){return t.queries.getByIndex(n)}function qM(t,n){let e=t[B],i=uh(e,n);return i.crossesNgTemplate?dd(e,t,n,[]):Ly(e,t,i,n)}var pm=new Set;function dh(t){pm.has(t)||(pm.add(t),performance?.mark?.("mark_feature_usage",{detail:{feature:t}}))}function YM(t){return typeof t=="function"&&t[zc]!==void 0}function jy(t){return YM(t)&&typeof t.set=="function"}function ZM(t){let n=[],e=new Map;function i(r){let s=e.get(r);if(!s){let o=t(r);e.set(r,s=o.then(JM))}return s}return Ia.forEach((r,s)=>{let o=[];r.templateUrl&&o.push(i(r.templateUrl).then(c=>{r.template=c}));let a=typeof r.styles=="string"?[r.styles]:r.styles||[];if(r.styles=a,r.styleUrl&&r.styleUrls?.length)throw new Error("@Component cannot define both `styleUrl` and `styleUrls`. Use `styleUrl` if the component has one stylesheet, or `styleUrls` if it has multiple");if(r.styleUrls?.length){let c=r.styles.length,u=r.styleUrls;r.styleUrls.forEach((d,h)=>{a.push(""),o.push(i(d).then(f=>{a[c+h]=f,u.splice(u.indexOf(d),1),u.length==0&&(r.styleUrls=void 0)}))})}else r.styleUrl&&o.push(i(r.styleUrl).then(c=>{a.push(c),r.styleUrl=void 0}));let l=Promise.all(o).then(()=>eS(s));n.push(l)}),KM(),Promise.all(n).then(()=>{})}var Ia=new Map,QM=new Set;function KM(){let t=Ia;return Ia=new Map,t}function XM(){return Ia.size===0}function JM(t){return typeof t=="string"?t:t.text()}function eS(t){QM.delete(t)}function tS(t){return Object.getPrototypeOf(t.prototype).constructor}function tl(t){let n=tS(t.type),e=!0,i=[t];for(;n;){let r;if(Ln(t))r=n.\u0275cmp||n.\u0275dir;else{if(n.\u0275cmp)throw new T(903,!1);r=n.\u0275dir}if(r){if(e){i.push(r);let o=t;o.inputs=Ko(t.inputs),o.inputTransforms=Ko(t.inputTransforms),o.declaredInputs=Ko(t.declaredInputs),o.outputs=Ko(t.outputs);let a=r.hostBindings;a&&oS(t,a);let l=r.viewQuery,c=r.contentQueries;if(l&&rS(t,l),c&&sS(t,c),nS(t,r),I_(t.outputs,r.outputs),Ln(r)&&r.data.animation){let u=t.data;u.animation=(u.animation||[]).concat(r.data.animation)}}let s=r.features;if(s)for(let o=0;o=0;i--){let r=t[i];r.hostVars=n+=r.hostVars,r.hostAttrs=us(r.hostAttrs,e=us(e,r.hostAttrs))}}function Ko(t){return t===sr?{}:t===mt?[]:t}function rS(t,n){let e=t.viewQuery;e?t.viewQuery=(i,r)=>{n(i,r),e(i,r)}:t.viewQuery=n}function sS(t,n){let e=t.contentQueries;e?t.contentQueries=(i,r,s)=>{n(i,r,s),e(i,r,s)}:t.contentQueries=n}function oS(t,n){let e=t.hostBindings;e?t.hostBindings=(i,r)=>{n(i,r),e(i,r)}:t.hostBindings=n}var Vn=class{},fs=class{};var Oa=class extends Vn{constructor(n,e,i,r=!0){super(),this.ngModuleType=n,this._parent=e,this._bootstrapComponents=[],this.destroyCbs=[],this.componentFactoryResolver=new Ma(this);let s=zm(n);this._bootstrapComponents=ny(s.bootstrap),this._r3Injector=Pv(n,e,[{provide:Vn,useValue:this},{provide:hr,useValue:this.componentFactoryResolver},...i],Ze(n),new Set(["environment"])),r&&this.resolveInjectorInitializers()}resolveInjectorInitializers(){this._r3Injector.resolveInjectorInitializers(),this.instance=this._r3Injector.get(this.ngModuleType)}get injector(){return this._r3Injector}destroy(){let n=this._r3Injector;!n.destroyed&&n.destroy(),this.destroyCbs.forEach(e=>e()),this.destroyCbs=null}onDestroy(n){this.destroyCbs.push(n)}},Ta=class extends fs{constructor(n){super(),this.moduleType=n}create(n){return new Oa(this.moduleType,n,[])}};function aS(t,n,e){return new Oa(t,n,e,!1)}var hd=class extends Vn{constructor(n){super(),this.componentFactoryResolver=new Ma(this),this.instance=null;let e=new ds([...n.providers,{provide:Vn,useValue:this},{provide:hr,useValue:this.componentFactoryResolver}],n.parent||Nd(),n.debugName,new Set(["environment"]));this.injector=e,n.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(n){this.injector.onDestroy(n)}};function nl(t,n,e=null){return new hd({providers:t,parent:n,debugName:e,runEnvironmentInitializers:!0}).injector}function Hy(t){return hh(t)?Array.isArray(t)||!(t instanceof Map)&&Symbol.iterator in t:!1}function lS(t,n){if(Array.isArray(t))for(let e=0;e{class t{constructor(){this.impl=null}execute(){this.impl?.execute()}static{this.\u0275prov=A({token:t,providedIn:"root",factory:()=>new t})}}return t})(),fd=class t{constructor(){this.ngZone=E(ue),this.scheduler=E(dr),this.errorHandler=E(cn,{optional:!0}),this.sequences=new Set,this.deferredRegistrations=new Set,this.executing=!1}static{this.PHASES=[nr.EarlyRead,nr.Write,nr.MixedReadWrite,nr.Read]}execute(){this.executing=!0;for(let n of t.PHASES)for(let e of this.sequences)if(!(e.erroredOrDestroyed||!e.hooks[n]))try{e.pipelinedValue=this.ngZone.runOutsideAngular(()=>e.hooks[n](e.pipelinedValue))}catch(i){e.erroredOrDestroyed=!0,this.errorHandler?.handleError(i)}this.executing=!1;for(let n of this.sequences)n.afterRun(),n.once&&(this.sequences.delete(n),n.destroy());for(let n of this.deferredRegistrations)this.sequences.add(n);this.deferredRegistrations.size>0&&this.scheduler.notify(7),this.deferredRegistrations.clear()}register(n){this.executing?this.deferredRegistrations.add(n):(this.sequences.add(n),this.scheduler.notify(6))}unregister(n){this.executing&&this.sequences.has(n)?(n.erroredOrDestroyed=!0,n.pipelinedValue=void 0,n.once=!0):(this.sequences.delete(n),this.deferredRegistrations.delete(n))}static{this.\u0275prov=A({token:t,providedIn:"root",factory:()=>new t})}},pd=class{constructor(n,e,i,r){this.impl=n,this.hooks=e,this.once=i,this.erroredOrDestroyed=!1,this.pipelinedValue=void 0,this.unregisterOnDestroy=r?.onDestroy(()=>this.destroy())}afterRun(){this.erroredOrDestroyed=!1,this.pipelinedValue=void 0}destroy(){this.impl.unregister(this),this.unregisterOnDestroy?.()}};function ph(t,n){!n?.injector&&EC(ph);let e=n?.injector??E(bt);return rE(e)?(dh("NgAfterNextRender"),mS(t,e,n,!0)):vS}function gS(t,n){if(t instanceof Function){let e=[void 0,void 0,void 0,void 0];return e[n]=t,e}else return[t.earlyRead,t.write,t.mixedReadWrite,t.read]}function mS(t,n,e,i){let r=n.get(Uy);r.impl??=n.get(fd);let s=e?.phase??nr.MixedReadWrite,o=e?.manualCleanup!==!0?n.get($d):null,a=new pd(r.impl,gS(t,s),i,o);return r.impl.register(a),a}var vS={destroy(){}};function wr(t,n,e,i){let r=ee(),s=za();if(un(r,s,n)){let o=Ae(),a=Hd();qE(a,r,t,n,e,i)}return wr}function yS(t,n,e,i){return un(t,za(),e)?n+vs(e)+i:xi}function Xo(t,n){return t<<17|n<<2}function wi(t){return t>>17&32767}function bS(t){return(t&2)==2}function wS(t,n){return t&131071|n<<17}function gd(t){return t|2}function gr(t){return(t&131068)>>2}function xu(t,n){return t&-131069|n<<2}function DS(t){return(t&1)===1}function md(t){return t|1}function _S(t,n,e,i,r,s){let o=s?n.classBindings:n.styleBindings,a=wi(o),l=gr(o);t[i]=e;let c=!1,u;if(Array.isArray(e)){let d=e;u=d[1],(u===null||bs(d,u)>0)&&(c=!0)}else u=e;if(r)if(l!==0){let h=wi(t[a+1]);t[i+1]=Xo(h,a),h!==0&&(t[h+1]=xu(t[h+1],i)),t[a+1]=wS(t[a+1],i)}else t[i+1]=Xo(a,0),a!==0&&(t[a+1]=xu(t[a+1],i)),a=i;else t[i+1]=Xo(l,0),a===0?a=i:t[l+1]=xu(t[l+1],i),l=i;c&&(t[i+1]=gd(t[i+1])),gm(t,u,i,!0),gm(t,u,i,!1),CS(n,u,t,i,s),o=Xo(a,l),s?n.classBindings=o:n.styleBindings=o}function CS(t,n,e,i,r){let s=r?t.residualClasses:t.residualStyles;s!=null&&typeof n=="string"&&bs(s,n)>=0&&(e[i+1]=md(e[i+1]))}function gm(t,n,e,i){let r=t[e+1],s=n===null,o=i?wi(r):gr(r),a=!1;for(;o!==0&&(a===!1||s);){let l=t[o],c=t[o+1];xS(l,n)&&(a=!0,t[o+1]=i?md(c):gd(c)),o=i?wi(c):gr(c)}a&&(t[e+1]=i?gd(r):md(r))}function xS(t,n){return t===null||n==null||(Array.isArray(t)?t[1]:t)===n?!0:Array.isArray(t)&&typeof n=="string"?bs(t,n)>=0:!1}function Y(t,n,e){let i=ee(),r=za();if(un(i,r,n)){let s=Ae(),o=Hd();yy(s,o,i,t,n,i[Oe],e,!1)}return Y}function mm(t,n,e,i,r){let s=n.inputs,o=r?"class":"style";sh(t,e,s[o],o,i)}function Cs(t,n,e){return $y(t,n,e,!1),Cs}function Ei(t,n){return $y(t,n,null,!0),Ei}function $y(t,n,e,i){let r=ee(),s=Ae(),o=WC(2);if(s.firstUpdatePass&&MS(s,t,o,i),n!==xi&&un(r,o,n)){let a=s.data[vr()];AS(s,a,r,r[Oe],t,r[o+1]=NS(n,e),i,o)}}function ES(t,n){return n>=t.expandoStartIndex}function MS(t,n,e,i){let r=t.data;if(r[e+1]===null){let s=r[vr()],o=ES(t,e);RS(s,i)&&n===null&&!o&&(n=!1),n=SS(r,s,n,i),_S(r,s,n,e,o,i)}}function SS(t,n,e,i){let r=ZC(t),s=i?n.residualClasses:n.residualStyles;if(r===null)(i?n.classBindings:n.styleBindings)===0&&(e=Eu(null,t,n,e,i),e=ps(e,n.attrs,i),s=null);else{let o=n.directiveStylingLast;if(o===-1||t[o]!==r)if(e=Eu(r,t,n,e,i),s===null){let l=IS(t,n,i);l!==void 0&&Array.isArray(l)&&(l=Eu(null,t,n,l[1],i),l=ps(l,n.attrs,i),OS(t,n,i,l))}else s=TS(t,n,i)}return s!==void 0&&(i?n.residualClasses=s:n.residualStyles=s),e}function IS(t,n,e){let i=e?n.classBindings:n.styleBindings;if(gr(i)!==0)return t[wi(i)]}function OS(t,n,e,i){let r=e?n.classBindings:n.styleBindings;t[wi(r)]=i}function TS(t,n,e){let i,r=n.directiveEnd;for(let s=1+n.directiveStylingLast;s0;){let l=t[r],c=Array.isArray(l),u=c?l[1]:l,d=u===null,h=e[r+1];h===xi&&(h=d?mt:void 0);let f=d?gu(h,i):u===i?h:void 0;if(c&&!Aa(f)&&(f=gu(l,i)),Aa(f)&&(a=f,o))return a;let p=t[r+1];r=o?wi(p):gr(p)}if(n!==null){let l=s?n.residualClasses:n.residualStyles;l!=null&&(a=gu(l,i))}return a}function Aa(t){return t!==void 0}function NS(t,n){return t==null||t===""||(typeof n=="string"?t=t+n:typeof t=="object"&&(t=Ze(ws(t)))),t}function RS(t,n){return(t.flags&(n?8:16))!==0}function kS(t,n,e,i,r,s){let o=n.consts,a=ur(o,r),l=_s(n,t,2,i,a);return rh(n,e,l,ur(o,s)),l.attrs!==null&&Ea(l,l.attrs,!1),l.mergedAttrs!==null&&Ea(l,l.mergedAttrs,!0),n.queries!==null&&n.queries.elementStart(n,l),l}function L(t,n,e,i){let r=ee(),s=Ae(),o=yt+t,a=r[Oe],l=s.firstCreatePass?kS(o,s,r,n,e,i):s.data[o],c=PS(s,r,l,a,n,t);r[o]=c;let u=Ba(l);return Ci(l,!0),dy(a,c,l),!uS(l)&&Wa()&&Ka(s,r,c,l),LC()===0&&Fn(c,r),FC(),u&&(th(s,r,l),eh(s,l,r)),i!==null&&nh(r,l),L}function j(){let t=ze();Pd()?pv():(t=t.parent,Ci(t,!1));let n=t;HC(n)&&BC(),VC();let e=Ae();return e.firstCreatePass&&(qa(e,t),Rd(t)&&e.queries.elementEnd(t)),n.classesWithoutHost!=null&&ix(n)&&mm(e,n,ee(),n.classesWithoutHost,!0),n.stylesWithoutHost!=null&&rx(n)&&mm(e,n,ee(),n.stylesWithoutHost,!1),j}function le(t,n,e,i){return L(t,n,e,i),j(),le}var PS=(t,n,e,i,r,s)=>(Ga(!0),iy(i,r,JC()));function LS(t,n,e,i,r){let s=n.consts,o=ur(s,i),a=_s(n,t,8,"ng-container",o);o!==null&&Ea(a,o,!0);let l=ur(s,r);return rh(n,e,a,l),n.queries!==null&&n.queries.elementStart(n,a),a}function il(t,n,e){let i=ee(),r=Ae(),s=t+yt,o=r.firstCreatePass?LS(s,r,i,n,e):r.data[s];Ci(o,!0);let a=FS(r,i,o,t);return i[s]=a,Wa()&&Ka(r,i,a,o),Fn(a,i),Ba(o)&&(th(r,i,o),eh(r,o,i)),e!=null&&nh(i,o),il}function rl(){let t=ze(),n=Ae();return Pd()?pv():(t=t.parent,Ci(t,!1)),n.firstCreatePass&&(qa(n,t),Rd(t)&&n.queries.elementEnd(t)),rl}var FS=(t,n,e,i)=>(Ga(!0),lE(n[Oe],""));function sl(){return ee()}var ci=void 0;function VS(t){let n=t,e=Math.floor(Math.abs(t)),i=t.toString().replace(/^[^.]*\.?/,"").length;return e===1&&i===0?1:5}var jS=["en",[["a","p"],["AM","PM"],ci],[["AM","PM"],ci,ci],[["S","M","T","W","T","F","S"],["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],["Su","Mo","Tu","We","Th","Fr","Sa"]],ci,[["J","F","M","A","M","J","J","A","S","O","N","D"],["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],["January","February","March","April","May","June","July","August","September","October","November","December"]],ci,[["B","A"],["BC","AD"],["Before Christ","Anno Domini"]],0,[6,0],["M/d/yy","MMM d, y","MMMM d, y","EEEE, MMMM d, y"],["h:mm a","h:mm:ss a","h:mm:ss a z","h:mm:ss a zzzz"],["{1}, {0}",ci,"{1} 'at' {0}",ci],[".",",",";","%","+","-","E","\xD7","\u2030","\u221E","NaN",":"],["#,##0.###","#,##0%","\xA4#,##0.00","#E0"],"USD","$","US Dollar",{},"ltr",VS],Mu={};function gh(t){let n=HS(t),e=ym(n);if(e)return e;let i=n.split("-")[0];if(e=ym(i),e)return e;if(i==="en")return jS;throw new T(701,!1)}function ym(t){return t in Mu||(Mu[t]=Le.ng&&Le.ng.common&&Le.ng.common.locales&&Le.ng.common.locales[t]),Mu[t]}var Dr=function(t){return t[t.LocaleId=0]="LocaleId",t[t.DayPeriodsFormat=1]="DayPeriodsFormat",t[t.DayPeriodsStandalone=2]="DayPeriodsStandalone",t[t.DaysFormat=3]="DaysFormat",t[t.DaysStandalone=4]="DaysStandalone",t[t.MonthsFormat=5]="MonthsFormat",t[t.MonthsStandalone=6]="MonthsStandalone",t[t.Eras=7]="Eras",t[t.FirstDayOfWeek=8]="FirstDayOfWeek",t[t.WeekendRange=9]="WeekendRange",t[t.DateFormat=10]="DateFormat",t[t.TimeFormat=11]="TimeFormat",t[t.DateTimeFormat=12]="DateTimeFormat",t[t.NumberSymbols=13]="NumberSymbols",t[t.NumberFormats=14]="NumberFormats",t[t.CurrencyCode=15]="CurrencyCode",t[t.CurrencySymbol=16]="CurrencySymbol",t[t.CurrencyName=17]="CurrencyName",t[t.Currencies=18]="Currencies",t[t.Directionality=19]="Directionality",t[t.PluralCase=20]="PluralCase",t[t.ExtraData=21]="ExtraData",t}(Dr||{});function HS(t){return t.toLowerCase().replace(/_/g,"-")}var Na="en-US";var BS=Na;function US(t){typeof t=="string"&&(BS=t.toLowerCase().replace(/_/g,"-"))}var $S=(t,n,e)=>{};function xe(t,n,e,i){let r=ee(),s=Ae(),o=ze();return zy(s,r,r[Oe],o,t,n,i),xe}function zS(t,n,e,i){let r=t.cleanup;if(r!=null)for(let s=0;sl?a[l]:null}typeof o=="string"&&(s+=2)}return null}function zy(t,n,e,i,r,s,o){let a=Ba(i),c=t.firstCreatePass&&xy(t),u=n[At],d=Cy(n),h=!0;if(i.type&3||o){let g=Dt(i,n),m=o?o(g):g,v=d.length,y=o?C=>o(Wt(C[i.index])):i.index,w=null;if(!o&&a&&(w=zS(t,n,r,i.index)),w!==null){let C=w.__ngLastListenerFn__||w;C.__ngNextListenerFn__=s,w.__ngLastListenerFn__=s,h=!1}else{s=wm(i,n,u,s),$S(g,r,s);let C=e.listen(m,r,s);d.push(s,C),c&&c.push(r,y,v,v+1)}}else s=wm(i,n,u,s);let f=i.outputs,p;if(h&&f!==null&&(p=f[r])){let g=p.length;if(g)for(let m=0;m-1?jn(t.index,n):n;ah(o,5);let a=bm(n,e,i,s),l=r.__ngNextListenerFn__;for(;l;)a=bm(n,e,l,s)&&a,l=l.__ngNextListenerFn__;return a}}function Yt(t=1){return KC(t)}function mh(t,n,e,i){zM(t,n,e,i)}function Qe(t,n,e){$M(t,n,e)}function Ve(t){let n=ee(),e=Ae(),i=mv();Fd(i+1);let r=uh(e,i);if(t.dirty&&NC(n)===((r.metadata.flags&2)===2)){if(r.matches===null)t.reset([]);else{let s=qM(n,i);t.reset(s,Ex),t.notifyOnChanges()}return!0}return!1}function je(){return UM(ee(),mv())}function WS(t,n,e,i){e>=t.data.length&&(t.data[e]=null,t.blueprint[e]=null),n[e]=i}function vh(t){let n=$C();return av(n,yt+t)}function Bn(t,n=""){let e=ee(),i=Ae(),r=t+yt,s=i.firstCreatePass?_s(i,r,1,n,null):i.data[r],o=GS(i,e,s,n,t);e[r]=o,Wa()&&Ka(i,e,o,s),Ci(s,!1)}var GS=(t,n,e,i,r)=>(Ga(!0),oE(n[Oe],i));function xs(t){return ol("",t,""),xs}function ol(t,n,e){let i=ee(),r=yS(i,t,n,e);return r!==xi&&KE(i,vr(),r),ol}function yh(t,n,e){jy(n)&&(n=n());let i=ee(),r=za();if(un(i,r,n)){let s=Ae(),o=Hd();yy(s,o,i,t,n,i[Oe],e,!1)}return yh}function Wy(t,n){let e=jy(t);return e&&t.set(n),e}function bh(t,n){let e=ee(),i=Ae(),r=ze();return zy(i,e,e[Oe],r,t,n),bh}function qS(t,n,e){let i=Ae();if(i.firstCreatePass){let r=Ln(t);vd(e,i.data,i.blueprint,r,!0),vd(n,i.data,i.blueprint,r,!1)}}function vd(t,n,e,i,r){if(t=Ye(t),Array.isArray(t))for(let s=0;s>20;if(ar(t)||!t.multi){let f=new mi(c,r,Q),p=Iu(l,n,r?u:u+h,d);p===-1?(Uu(va(a,o),s,l),Su(s,t,n.length),n.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(f),o.push(f)):(e[p]=f,o[p]=f)}else{let f=Iu(l,n,u+h,d),p=Iu(l,n,u,u+h),g=f>=0&&e[f],m=p>=0&&e[p];if(r&&!m||!r&&!g){Uu(va(a,o),s,l);let v=QS(r?ZS:YS,e.length,r,i,c);!r&&m&&(e[p].providerFactory=v),Su(s,t,n.length,0),n.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(v),o.push(v)}else{let v=Gy(e[r?p:f],c,!r&&i);Su(s,t,f>-1?f:p,v)}!r&&i&&m&&e[p].componentProviders++}}}function Su(t,n,e,i){let r=ar(n),s=yC(n);if(r||s){let l=(s?Ye(n.useClass):n).prototype.ngOnDestroy;if(l){let c=t.destroyHooks||(t.destroyHooks=[]);if(!r&&n.multi){let u=c.indexOf(e);u===-1?c.push(e,[i,l]):c[u+1].push(i,l)}else c.push(e,l)}}}function Gy(t,n,e){return e&&t.componentProviders++,t.multi.push(n)-1}function Iu(t,n,e,i){for(let r=e;r{e.providersResolver=(i,r)=>qS(i,r?r(t):t,n)}}var KS=(()=>{class t{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){let i=qm(!1,e.type),r=i.length>0?nl([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(let e of this.cachedInjectors.values())e!==null&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=A({token:t,providedIn:"environment",factory:()=>new t(R(lt))})}}return t})();function Yy(t){dh("NgStandalone"),t.getStandaloneInjector=n=>n.get(KS).getOrCreateStandaloneInjector(t)}function dt(t,n,e,i){return XS(ee(),Ld(),t,n,e,i)}function Zy(t,n,e,i,r,s){return eI(ee(),Ld(),t,n,e,i,r,s)}function wh(t,n){let e=t[n];return e===xi?void 0:e}function XS(t,n,e,i,r,s){let o=n+e;return un(t,o,r)?fh(t,o+1,s?i.call(s,r):i(r)):wh(t,o+1)}function JS(t,n,e,i,r,s,o){let a=n+e;return By(t,a,r,s)?fh(t,a+2,o?i.call(o,r,s):i(r,s)):wh(t,a+2)}function eI(t,n,e,i,r,s,o,a){let l=n+e;return cS(t,l,r,s,o)?fh(t,l+3,a?i.call(a,r,s,o):i(r,s,o)):wh(t,l+3)}function Qy(t,n){let e=Ae(),i,r=t+yt;e.firstCreatePass?(i=tI(n,e.pipeRegistry),e.data[r]=i,i.onDestroy&&(e.destroyHooks??=[]).push(r,i.onDestroy)):i=e.data[r];let s=i.factory||(i.factory=di(i.type,!0)),o,a=Je(Q);try{let l=ma(!1),c=s();return ma(l),WS(e,ee(),r,c),c}finally{Je(a)}}function tI(t,n){if(n)for(let e=n.length-1;e>=0;e--){let i=n[e];if(t===i.name)return i}}function Ky(t,n,e,i){let r=t+yt,s=ee(),o=av(s,r);return nI(s,r)?JS(s,Ld(),n,o.transform,e,i,o):o.transform(e,i)}function nI(t,n){return t[B].data[n].pure}var Jo=null;function iI(t){Jo!==null&&(t.defaultEncapsulation!==Jo.defaultEncapsulation||t.preserveWhitespaces!==Jo.preserveWhitespaces)||(Jo=t)}var al=(()=>{class t{log(e){console.log(e)}warn(e){console.warn(e)}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"platform"})}}return t})();var Dh=new N(""),Es=new N(""),ll=(()=>{class t{constructor(e,i,r){this._ngZone=e,this.registry=i,this._isZoneStable=!0,this._callbacks=[],this.taskTrackingZone=null,_h||(rI(r),r.addToWindow(i)),this._watchAngularEvents(),e.run(()=>{this.taskTrackingZone=typeof Zone>"u"?null:Zone.current.get("TaskTrackingZone")})}_watchAngularEvents(){this._ngZone.onUnstable.subscribe({next:()=>{this._isZoneStable=!1}}),this._ngZone.runOutsideAngular(()=>{this._ngZone.onStable.subscribe({next:()=>{ue.assertNotInAngularZone(),queueMicrotask(()=>{this._isZoneStable=!0,this._runCallbacksIfReady()})}})})}isStable(){return this._isZoneStable&&!this._ngZone.hasPendingMacrotasks}_runCallbacksIfReady(){if(this.isStable())queueMicrotask(()=>{for(;this._callbacks.length!==0;){let e=this._callbacks.pop();clearTimeout(e.timeoutId),e.doneCb()}});else{let e=this.getPendingTasks();this._callbacks=this._callbacks.filter(i=>i.updateCb&&i.updateCb(e)?(clearTimeout(i.timeoutId),!1):!0)}}getPendingTasks(){return this.taskTrackingZone?this.taskTrackingZone.macroTasks.map(e=>({source:e.source,creationLocation:e.creationLocation,data:e.data})):[]}addCallback(e,i,r){let s=-1;i&&i>0&&(s=setTimeout(()=>{this._callbacks=this._callbacks.filter(o=>o.timeoutId!==s),e()},i)),this._callbacks.push({doneCb:e,timeoutId:s,updateCb:r})}whenStable(e,i,r){if(r&&!this.taskTrackingZone)throw new Error('Task tracking zone is required when passing an update callback to whenStable(). Is "zone.js/plugins/task-tracking" loaded?');this.addCallback(e,i,r),this._runCallbacksIfReady()}registerApplication(e){this.registry.registerApplication(e,this)}unregisterApplication(e){this.registry.unregisterApplication(e)}findProviders(e,i,r){return[]}static{this.\u0275fac=function(i){return new(i||t)(R(ue),R(cl),R(Es))}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac})}}return t})(),cl=(()=>{class t{constructor(){this._applications=new Map}registerApplication(e,i){this._applications.set(e,i)}unregisterApplication(e){this._applications.delete(e)}unregisterAllApplications(){this._applications.clear()}getTestability(e){return this._applications.get(e)||null}getAllTestabilities(){return Array.from(this._applications.values())}getAllRootElements(){return Array.from(this._applications.keys())}findTestabilityInTree(e,i=!0){return _h?.findTestabilityInTree(this,e,i)??null}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"platform"})}}return t})();function rI(t){_h=t}var _h;function _r(t){return!!t&&typeof t.then=="function"}function Xy(t){return!!t&&typeof t.subscribe=="function"}var ul=new N(""),Jy=(()=>{class t{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=E(ul,{optional:!0})??[]}runInitializers(){if(this.initialized)return;let e=[];for(let r of this.appInits){let s=r();if(_r(s))e.push(s);else if(Xy(s)){let o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}let i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),e.length===0&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})(),Ch=new N("");function sI(){ng(()=>{throw new T(600,!1)})}function oI(t){return t.isBoundToModule}var aI=10;function lI(t,n,e){try{let i=e();return _r(i)?i.catch(r=>{throw n.runOutsideAngular(()=>t.handleError(r)),r}):i}catch(i){throw n.runOutsideAngular(()=>t.handleError(i)),i}}function eb(t,n){return Array.isArray(n)?n.reduce(eb,t):S(S({},t),n)}var Un=(()=>{class t{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=E(Cx),this.afterRenderManager=E(Uy),this.zonelessEnabled=E(ch),this.dirtyFlags=0,this.deferredDirtyFlags=0,this.externalTestViews=new Set,this.beforeRender=new Ee,this.afterTick=new Ee,this.componentTypes=[],this.components=[],this.isStable=E(yr).hasPendingTasks.pipe(J(e=>!e)),this._injector=E(lt)}get allViews(){return[...this.externalTestViews.keys(),...this._views]}get destroyed(){return this._destroyed}whenStable(){let e;return new Promise(i=>{e=this.isStable.subscribe({next:r=>{r&&i()}})}).finally(()=>{e.unsubscribe()})}get injector(){return this._injector}bootstrap(e,i){let r=e instanceof xa;if(!this._injector.get(Jy).done){let h=!r&&$m(e),f=!1;throw new T(405,f)}let o;r?o=e:o=this._injector.get(hr).resolveComponentFactory(e),this.componentTypes.push(o.componentType);let a=oI(o)?void 0:this._injector.get(Vn),l=i||o.selector,c=o.create(bt.NULL,[],l,a),u=c.location.nativeElement,d=c.injector.get(Dh,null);return d?.registerApplication(u),c.onDestroy(()=>{this.detachView(c.hostView),sa(this.components,c),d?.unregisterApplication(u)}),this._loadComponent(c),c}tick(){this.zonelessEnabled||(this.dirtyFlags|=1),this._tick()}_tick(){if(this._runningTick)throw new T(101,!1);let e=ne(null);try{this._runningTick=!0,this.synchronize()}catch(i){this.internalErrorHandler(i)}finally{this._runningTick=!1,ne(e),this.afterTick.next()}}synchronize(){let e=null;this._injector.destroyed||(e=this._injector.get(fr,null,{optional:!0})),this.dirtyFlags|=this.deferredDirtyFlags,this.deferredDirtyFlags=0;let i=0;for(;this.dirtyFlags!==0&&i++Ua(e))){this.dirtyFlags|=2;return}else this.dirtyFlags&=-8}attachView(e){let i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){let i=e;sa(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);let i=this._injector.get(Ch,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>sa(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new T(406,!1);let e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})();function sa(t,n){let e=t.indexOf(n);e>-1&&t.splice(e,1)}function cI(t,n,e,i){if(!e&&!Ua(t))return;Iy(t,n,e&&!i?0:1)}var bd=class{constructor(n,e){this.ngModuleFactory=n,this.componentFactories=e}},dl=(()=>{class t{compileModuleSync(e){return new Ta(e)}compileModuleAsync(e){return Promise.resolve(this.compileModuleSync(e))}compileModuleAndAllComponentsSync(e){let i=this.compileModuleSync(e),r=zm(e),s=ny(r.declarations).reduce((o,a)=>{let l=Pn(a);return l&&o.push(new pr(l)),o},[]);return new bd(i,s)}compileModuleAndAllComponentsAsync(e){return Promise.resolve(this.compileModuleAndAllComponentsSync(e))}clearCache(){}clearCacheFor(e){}getModuleId(e){}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})(),uI=new N("");function dI(t,n,e){let i=new Ta(e);return Promise.resolve(i)}function Dm(t){for(let n=t.length-1;n>=0;n--)if(t[n]!==void 0)return t[n]}var hI=(()=>{class t{constructor(){this.zone=E(ue),this.changeDetectionScheduler=E(dr),this.applicationRef=E(Un)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.changeDetectionScheduler.runningTick||this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})();function fI({ngZoneFactory:t,ignoreChangesOutsideZone:n,scheduleInRootZone:e}){return t??=()=>new ue(ae(S({},tb()),{scheduleInRootZone:e})),[{provide:ue,useFactory:t},{provide:or,multi:!0,useFactory:()=>{let i=E(hI,{optional:!0});return()=>i.initialize()}},{provide:or,multi:!0,useFactory:()=>{let i=E(pI);return()=>{i.initialize()}}},n===!0?{provide:Ny,useValue:!0}:[],{provide:Ry,useValue:e??Lv}]}function tb(t){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:t?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:t?.runCoalescing??!1}}var pI=(()=>{class t{constructor(){this.subscription=new we,this.initialized=!1,this.zone=E(ue),this.pendingTasks=E(yr)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{ue.assertNotInAngularZone(),queueMicrotask(()=>{e!==null&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{ue.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})();var gI=(()=>{class t{constructor(){this.appRef=E(Un),this.taskService=E(yr),this.ngZone=E(ue),this.zonelessEnabled=E(ch),this.disableScheduling=E(Ny,{optional:!0})??!1,this.zoneIsDefined=typeof Zone<"u"&&!!Zone.root.run,this.schedulerTickApplyArgs=[{data:{__scheduler_tick__:!0}}],this.subscriptions=new we,this.angularZoneId=this.zoneIsDefined?this.ngZone._inner?.get(ba):null,this.scheduleInRootZone=!this.zonelessEnabled&&this.zoneIsDefined&&(E(Ry,{optional:!0})??!1),this.cancelScheduledCallback=null,this.useMicrotaskScheduler=!1,this.runningTick=!1,this.pendingRenderTaskId=null,this.subscriptions.add(this.appRef.afterTick.subscribe(()=>{this.runningTick||this.cleanup()})),this.subscriptions.add(this.ngZone.onUnstable.subscribe(()=>{this.runningTick||this.cleanup()})),this.disableScheduling||=!this.zonelessEnabled&&(this.ngZone instanceof wa||!this.zoneIsDefined)}notify(e){if(!this.zonelessEnabled&&e===5)return;switch(e){case 0:{this.appRef.dirtyFlags|=2;break}case 3:case 2:case 4:case 5:case 1:{this.appRef.dirtyFlags|=4;break}case 7:{this.appRef.deferredDirtyFlags|=8;break}case 9:case 8:case 6:case 10:default:this.appRef.dirtyFlags|=8}if(!this.shouldScheduleTick())return;let i=this.useMicrotaskScheduler?Kg:Fv;this.pendingRenderTaskId=this.taskService.add(),this.scheduleInRootZone?this.cancelScheduledCallback=Zone.root.run(()=>i(()=>this.tick())):this.cancelScheduledCallback=this.ngZone.runOutsideAngular(()=>i(()=>this.tick()))}shouldScheduleTick(){return!(this.disableScheduling||this.pendingRenderTaskId!==null||this.runningTick||this.appRef._runningTick||!this.zonelessEnabled&&this.zoneIsDefined&&Zone.current.get(ba+this.angularZoneId))}tick(){if(this.runningTick||this.appRef.destroyed)return;!this.zonelessEnabled&&this.appRef.dirtyFlags&7&&(this.appRef.dirtyFlags|=1);let e=this.taskService.add();try{this.ngZone.run(()=>{this.runningTick=!0,this.appRef._tick()},void 0,this.schedulerTickApplyArgs)}catch(i){throw this.taskService.remove(e),i}finally{this.cleanup()}this.useMicrotaskScheduler=!0,Kg(()=>{this.useMicrotaskScheduler=!1,this.taskService.remove(e)})}ngOnDestroy(){this.subscriptions.unsubscribe(),this.cleanup()}cleanup(){if(this.runningTick=!1,this.cancelScheduledCallback?.(),this.cancelScheduledCallback=null,this.pendingRenderTaskId!==null){let e=this.pendingRenderTaskId;this.pendingRenderTaskId=null,this.taskService.remove(e)}}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})();function mI(){return typeof $localize<"u"&&$localize.locale||Na}var hl=new N("",{providedIn:"root",factory:()=>E(hl,G.Optional|G.SkipSelf)||mI()});var Ra=new N("");function ea(t){return!t.moduleRef}function vI(t){let n=ea(t)?t.r3Injector:t.moduleRef.injector,e=n.get(ue);return e.run(()=>{ea(t)?t.r3Injector.resolveInjectorInitializers():t.moduleRef.resolveInjectorInitializers();let i=n.get(cn,null),r;if(e.runOutsideAngular(()=>{r=e.onError.subscribe({next:s=>{i.handleError(s)}})}),ea(t)){let s=()=>n.destroy(),o=t.platformInjector.get(Ra);o.add(s),n.onDestroy(()=>{r.unsubscribe(),o.delete(s)})}else{let s=()=>t.moduleRef.destroy(),o=t.platformInjector.get(Ra);o.add(s),t.moduleRef.onDestroy(()=>{sa(t.allPlatformModules,t.moduleRef),r.unsubscribe(),o.delete(s)})}return lI(i,e,()=>{let s=n.get(Jy);return s.runInitializers(),s.donePromise.then(()=>{let o=n.get(hl,Na);if(US(o||Na),ea(t)){let a=n.get(Un);return t.rootComponent!==void 0&&a.bootstrap(t.rootComponent),a}else return yI(t.moduleRef,t.allPlatformModules),t.moduleRef})})})}function yI(t,n){let e=t.injector.get(Un);if(t._bootstrapComponents.length>0)t._bootstrapComponents.forEach(i=>e.bootstrap(i));else if(t.instance.ngDoBootstrap)t.instance.ngDoBootstrap(e);else throw new T(-403,!1);n.push(t)}var nb=(()=>{class t{constructor(e){this._injector=e,this._modules=[],this._destroyListeners=[],this._destroyed=!1}bootstrapModuleFactory(e,i){let r=i?.scheduleInRootZone,s=()=>_x(i?.ngZone,ae(S({},tb({eventCoalescing:i?.ngZoneEventCoalescing,runCoalescing:i?.ngZoneRunCoalescing})),{scheduleInRootZone:r})),o=i?.ignoreChangesOutsideZone,a=[fI({ngZoneFactory:s,ignoreChangesOutsideZone:o}),{provide:dr,useExisting:gI}],l=aS(e.moduleType,this.injector,a);return vI({moduleRef:l,allPlatformModules:this._modules,platformInjector:this.injector})}bootstrapModule(e,i=[]){let r=eb({},i);return dI(this.injector,r,e).then(s=>this.bootstrapModuleFactory(s,r))}onDestroy(e){this._destroyListeners.push(e)}get injector(){return this._injector}destroy(){if(this._destroyed)throw new T(404,!1);this._modules.slice().forEach(i=>i.destroy()),this._destroyListeners.forEach(i=>i());let e=this._injector.get(Ra,null);e&&(e.forEach(i=>i()),e.clear()),this._destroyed=!0}get destroyed(){return this._destroyed}static{this.\u0275fac=function(i){return new(i||t)(R(bt))}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"platform"})}}return t})(),ls=null,ib=new N("");function bI(t){if(ls&&!ls.get(ib,!1))throw new T(400,!1);sI(),ls=t;let n=t.get(nb);return _I(t),n}function xh(t,n,e=[]){let i=`Platform: ${n}`,r=new N(i);return(s=[])=>{let o=rb();if(!o||o.injector.get(ib,!1)){let a=[...e,...s,{provide:r,useValue:!0}];t?t(a):bI(wI(a,i))}return DI(r)}}function wI(t=[],n){return bt.create({name:n,providers:[{provide:Va,useValue:"platform"},{provide:Ra,useValue:new Set([()=>ls=null])},...t]})}function DI(t){let n=rb();if(!n)throw new T(401,!1);return n}function rb(){return ls?.get(nb)??null}function _I(t){t.get(Gd,null)?.forEach(e=>e())}var Pt=(()=>{class t{static{this.__NG_ELEMENT_ID__=CI}}return t})();function CI(t){return xI(ze(),ee(),(t&16)===16)}function xI(t,n,e){if(Ha(t)&&!e){let i=jn(t.index,n);return new yi(i,i)}else if(t.type&175){let i=n[zt];return new yi(i,n)}return null}var wd=class{constructor(){}supports(n){return Hy(n)}create(n){return new Dd(n)}},EI=(t,n)=>n,Dd=class{constructor(n){this.length=0,this._linkedRecords=null,this._unlinkedRecords=null,this._previousItHead=null,this._itHead=null,this._itTail=null,this._additionsHead=null,this._additionsTail=null,this._movesHead=null,this._movesTail=null,this._removalsHead=null,this._removalsTail=null,this._identityChangesHead=null,this._identityChangesTail=null,this._trackByFn=n||EI}forEachItem(n){let e;for(e=this._itHead;e!==null;e=e._next)n(e)}forEachOperation(n){let e=this._itHead,i=this._removalsHead,r=0,s=null;for(;e||i;){let o=!i||e&&e.currentIndex<_m(i,r,s)?e:i,a=_m(o,r,s),l=o.currentIndex;if(o===i)r--,i=i._nextRemoved;else if(e=e._next,o.previousIndex==null)r++;else{s||(s=[]);let c=a-r,u=l-r;if(c!=u){for(let h=0;h{o=this._trackByFn(r,a),e===null||!Object.is(e.trackById,o)?(e=this._mismatch(e,a,o,r),i=!0):(i&&(e=this._verifyReinsertion(e,a,o,r)),Object.is(e.item,a)||this._addIdentityChange(e,a)),e=e._next,r++}),this.length=r;return this._truncate(e),this.collection=n,this.isDirty}get isDirty(){return this._additionsHead!==null||this._movesHead!==null||this._removalsHead!==null||this._identityChangesHead!==null}_reset(){if(this.isDirty){let n;for(n=this._previousItHead=this._itHead;n!==null;n=n._next)n._nextPrevious=n._next;for(n=this._additionsHead;n!==null;n=n._nextAdded)n.previousIndex=n.currentIndex;for(this._additionsHead=this._additionsTail=null,n=this._movesHead;n!==null;n=n._nextMoved)n.previousIndex=n.currentIndex;this._movesHead=this._movesTail=null,this._removalsHead=this._removalsTail=null,this._identityChangesHead=this._identityChangesTail=null}}_mismatch(n,e,i,r){let s;return n===null?s=this._itTail:(s=n._prev,this._remove(n)),n=this._unlinkedRecords===null?null:this._unlinkedRecords.get(i,null),n!==null?(Object.is(n.item,e)||this._addIdentityChange(n,e),this._reinsertAfter(n,s,r)):(n=this._linkedRecords===null?null:this._linkedRecords.get(i,r),n!==null?(Object.is(n.item,e)||this._addIdentityChange(n,e),this._moveAfter(n,s,r)):n=this._addAfter(new _d(e,i),s,r)),n}_verifyReinsertion(n,e,i,r){let s=this._unlinkedRecords===null?null:this._unlinkedRecords.get(i,null);return s!==null?n=this._reinsertAfter(s,n._prev,r):n.currentIndex!=r&&(n.currentIndex=r,this._addToMoves(n,r)),n}_truncate(n){for(;n!==null;){let e=n._next;this._addToRemovals(this._unlink(n)),n=e}this._unlinkedRecords!==null&&this._unlinkedRecords.clear(),this._additionsTail!==null&&(this._additionsTail._nextAdded=null),this._movesTail!==null&&(this._movesTail._nextMoved=null),this._itTail!==null&&(this._itTail._next=null),this._removalsTail!==null&&(this._removalsTail._nextRemoved=null),this._identityChangesTail!==null&&(this._identityChangesTail._nextIdentityChange=null)}_reinsertAfter(n,e,i){this._unlinkedRecords!==null&&this._unlinkedRecords.remove(n);let r=n._prevRemoved,s=n._nextRemoved;return r===null?this._removalsHead=s:r._nextRemoved=s,s===null?this._removalsTail=r:s._prevRemoved=r,this._insertAfter(n,e,i),this._addToMoves(n,i),n}_moveAfter(n,e,i){return this._unlink(n),this._insertAfter(n,e,i),this._addToMoves(n,i),n}_addAfter(n,e,i){return this._insertAfter(n,e,i),this._additionsTail===null?this._additionsTail=this._additionsHead=n:this._additionsTail=this._additionsTail._nextAdded=n,n}_insertAfter(n,e,i){let r=e===null?this._itHead:e._next;return n._next=r,n._prev=e,r===null?this._itTail=n:r._prev=n,e===null?this._itHead=n:e._next=n,this._linkedRecords===null&&(this._linkedRecords=new ka),this._linkedRecords.put(n),n.currentIndex=i,n}_remove(n){return this._addToRemovals(this._unlink(n))}_unlink(n){this._linkedRecords!==null&&this._linkedRecords.remove(n);let e=n._prev,i=n._next;return e===null?this._itHead=i:e._next=i,i===null?this._itTail=e:i._prev=e,n}_addToMoves(n,e){return n.previousIndex===e||(this._movesTail===null?this._movesTail=this._movesHead=n:this._movesTail=this._movesTail._nextMoved=n),n}_addToRemovals(n){return this._unlinkedRecords===null&&(this._unlinkedRecords=new ka),this._unlinkedRecords.put(n),n.currentIndex=null,n._nextRemoved=null,this._removalsTail===null?(this._removalsTail=this._removalsHead=n,n._prevRemoved=null):(n._prevRemoved=this._removalsTail,this._removalsTail=this._removalsTail._nextRemoved=n),n}_addIdentityChange(n,e){return n.item=e,this._identityChangesTail===null?this._identityChangesTail=this._identityChangesHead=n:this._identityChangesTail=this._identityChangesTail._nextIdentityChange=n,n}},_d=class{constructor(n,e){this.item=n,this.trackById=e,this.currentIndex=null,this.previousIndex=null,this._nextPrevious=null,this._prev=null,this._next=null,this._prevDup=null,this._nextDup=null,this._prevRemoved=null,this._nextRemoved=null,this._nextAdded=null,this._nextMoved=null,this._nextIdentityChange=null}},Cd=class{constructor(){this._head=null,this._tail=null}add(n){this._head===null?(this._head=this._tail=n,n._nextDup=null,n._prevDup=null):(this._tail._nextDup=n,n._prevDup=this._tail,n._nextDup=null,this._tail=n)}get(n,e){let i;for(i=this._head;i!==null;i=i._nextDup)if((e===null||e<=i.currentIndex)&&Object.is(i.trackById,n))return i;return null}remove(n){let e=n._prevDup,i=n._nextDup;return e===null?this._head=i:e._nextDup=i,i===null?this._tail=e:i._prevDup=e,this._head===null}},ka=class{constructor(){this.map=new Map}put(n){let e=n.trackById,i=this.map.get(e);i||(i=new Cd,this.map.set(e,i)),i.add(n)}get(n,e){let i=n,r=this.map.get(i);return r?r.get(n,e):null}remove(n){let e=n.trackById;return this.map.get(e).remove(n)&&this.map.delete(e),n}get isEmpty(){return this.map.size===0}clear(){this.map.clear()}};function _m(t,n,e){let i=t.previousIndex;if(i===null)return i;let r=0;return e&&i{if(e&&e.key===r)this._maybeAddToChanges(e,i),this._appendAfter=e,e=e._next;else{let s=this._getOrCreateRecordForKey(r,i);e=this._insertBeforeOrAppend(e,s)}}),e){e._prev&&(e._prev._next=null),this._removalsHead=e;for(let i=e;i!==null;i=i._nextRemoved)i===this._mapHead&&(this._mapHead=null),this._records.delete(i.key),i._nextRemoved=i._next,i.previousValue=i.currentValue,i.currentValue=null,i._prev=null,i._next=null}return this._changesTail&&(this._changesTail._nextChanged=null),this._additionsTail&&(this._additionsTail._nextAdded=null),this.isDirty}_insertBeforeOrAppend(n,e){if(n){let i=n._prev;return e._next=n,e._prev=i,n._prev=e,i&&(i._next=e),n===this._mapHead&&(this._mapHead=e),this._appendAfter=n,n}return this._appendAfter?(this._appendAfter._next=e,e._prev=this._appendAfter):this._mapHead=e,this._appendAfter=e,null}_getOrCreateRecordForKey(n,e){if(this._records.has(n)){let r=this._records.get(n);this._maybeAddToChanges(r,e);let s=r._prev,o=r._next;return s&&(s._next=o),o&&(o._prev=s),r._next=null,r._prev=null,r}let i=new Md(n);return this._records.set(n,i),i.currentValue=e,this._addToAdditions(i),i}_reset(){if(this.isDirty){let n;for(this._previousMapHead=this._mapHead,n=this._previousMapHead;n!==null;n=n._next)n._nextPrevious=n._next;for(n=this._changesHead;n!==null;n=n._nextChanged)n.previousValue=n.currentValue;for(n=this._additionsHead;n!=null;n=n._nextAdded)n.previousValue=n.currentValue;this._changesHead=this._changesTail=null,this._additionsHead=this._additionsTail=null,this._removalsHead=null}}_maybeAddToChanges(n,e){Object.is(e,n.currentValue)||(n.previousValue=n.currentValue,n.currentValue=e,this._addToChanges(n))}_addToAdditions(n){this._additionsHead===null?this._additionsHead=this._additionsTail=n:(this._additionsTail._nextAdded=n,this._additionsTail=n)}_addToChanges(n){this._changesHead===null?this._changesHead=this._changesTail=n:(this._changesTail._nextChanged=n,this._changesTail=n)}_forEach(n,e){n instanceof Map?n.forEach(e):Object.keys(n).forEach(i=>e(n[i],i))}},Md=class{constructor(n){this.key=n,this.previousValue=null,this.currentValue=null,this._nextPrevious=null,this._next=null,this._prev=null,this._nextAdded=null,this._nextRemoved=null,this._nextChanged=null}};function Cm(){return new Eh([new wd])}var Eh=(()=>{class t{static{this.\u0275prov=A({token:t,providedIn:"root",factory:Cm})}constructor(e){this.factories=e}static create(e,i){if(i!=null){let r=i.factories.slice();e=e.concat(r)}return new t(e)}static extend(e){return{provide:t,useFactory:i=>t.create(e,i||Cm()),deps:[[t,new Fa,new ys]]}}find(e){let i=this.factories.find(r=>r.supports(e));if(i!=null)return i;throw new T(901,!1)}}return t})();function xm(){return new Mh([new xd])}var Mh=(()=>{class t{static{this.\u0275prov=A({token:t,providedIn:"root",factory:xm})}constructor(e){this.factories=e}static create(e,i){if(i){let r=i.factories.slice();e=e.concat(r)}return new t(e)}static extend(e){return{provide:t,useFactory:i=>t.create(e,i||xm()),deps:[[t,new Fa,new ys]]}}find(e){let i=this.factories.find(r=>r.supports(e));if(i)return i;throw new T(901,!1)}}return t})();var sb=xh(null,"core",[]),ob=(()=>{class t{constructor(e){}static{this.\u0275fac=function(i){return new(i||t)(R(Un))}}static{this.\u0275mod=ut({type:t})}static{this.\u0275inj=ct({})}}return t})();function ab(t){let n=Pn(t);if(!n)return null;let e=new pr(n);return{get selector(){return e.selector},get type(){return e.componentType},get inputs(){return e.inputs},get outputs(){return e.outputs},get ngContentSelectors(){return e.ngContentSelectors},get isStandalone(){return n.standalone},get isSignal(){return n.signals}}}var gb=null;function Mi(){return gb}function mb(t){gb??=t}var fl=class{};var et=new N(""),Ph=(()=>{class t{historyGo(e){throw new Error("")}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:()=>E(OI),providedIn:"platform"})}}return t})(),vb=new N(""),OI=(()=>{class t extends Ph{constructor(){super(),this._doc=E(et),this._location=window.location,this._history=window.history}getBaseHrefFromDOM(){return Mi().getBaseHref(this._doc)}onPopState(e){let i=Mi().getGlobalEventTarget(this._doc,"window");return i.addEventListener("popstate",e,!1),()=>i.removeEventListener("popstate",e)}onHashChange(e){let i=Mi().getGlobalEventTarget(this._doc,"window");return i.addEventListener("hashchange",e,!1),()=>i.removeEventListener("hashchange",e)}get href(){return this._location.href}get protocol(){return this._location.protocol}get hostname(){return this._location.hostname}get port(){return this._location.port}get pathname(){return this._location.pathname}get search(){return this._location.search}get hash(){return this._location.hash}set pathname(e){this._location.pathname=e}pushState(e,i,r){this._history.pushState(e,i,r)}replaceState(e,i,r){this._history.replaceState(e,i,r)}forward(){this._history.forward()}back(){this._history.back()}historyGo(e=0){this._history.go(e)}getState(){return this._history.state}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:()=>new t,providedIn:"platform"})}}return t})();function Lh(t,n){if(t.length==0)return n;if(n.length==0)return t;let e=0;return t.endsWith("/")&&e++,n.startsWith("/")&&e++,e==2?t+n.substring(1):e==1?t+n:t+"/"+n}function lb(t){let n=t.match(/#|\?|$/),e=n&&n.index||t.length,i=e-(t[e-1]==="/"?1:0);return t.slice(0,i)+t.slice(e)}function mn(t){return t&&t[0]!=="?"?"?"+t:t}var Si=(()=>{class t{historyGo(e){throw new Error("")}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:()=>E(Fh),providedIn:"root"})}}return t})(),yb=new N(""),Fh=(()=>{class t extends Si{constructor(e,i){super(),this._platformLocation=e,this._removeListenerFns=[],this._baseHref=i??this._platformLocation.getBaseHrefFromDOM()??E(et).location?.origin??""}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(e){this._removeListenerFns.push(this._platformLocation.onPopState(e),this._platformLocation.onHashChange(e))}getBaseHref(){return this._baseHref}prepareExternalUrl(e){return Lh(this._baseHref,e)}path(e=!1){let i=this._platformLocation.pathname+mn(this._platformLocation.search),r=this._platformLocation.hash;return r&&e?`${i}${r}`:i}pushState(e,i,r,s){let o=this.prepareExternalUrl(r+mn(s));this._platformLocation.pushState(e,i,o)}replaceState(e,i,r,s){let o=this.prepareExternalUrl(r+mn(s));this._platformLocation.replaceState(e,i,o)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(e=0){this._platformLocation.historyGo?.(e)}static{this.\u0275fac=function(i){return new(i||t)(R(Ph),R(yb,8))}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})(),bb=(()=>{class t extends Si{constructor(e,i){super(),this._platformLocation=e,this._baseHref="",this._removeListenerFns=[],i!=null&&(this._baseHref=i)}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(e){this._removeListenerFns.push(this._platformLocation.onPopState(e),this._platformLocation.onHashChange(e))}getBaseHref(){return this._baseHref}path(e=!1){let i=this._platformLocation.hash??"#";return i.length>0?i.substring(1):i}prepareExternalUrl(e){let i=Lh(this._baseHref,e);return i.length>0?"#"+i:i}pushState(e,i,r,s){let o=this.prepareExternalUrl(r+mn(s));o.length==0&&(o=this._platformLocation.pathname),this._platformLocation.pushState(e,i,o)}replaceState(e,i,r,s){let o=this.prepareExternalUrl(r+mn(s));o.length==0&&(o=this._platformLocation.pathname),this._platformLocation.replaceState(e,i,o)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(e=0){this._platformLocation.historyGo?.(e)}static{this.\u0275fac=function(i){return new(i||t)(R(Ph),R(yb,8))}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac})}}return t})(),Cr=(()=>{class t{constructor(e){this._subject=new re,this._urlChangeListeners=[],this._urlChangeSubscription=null,this._locationStrategy=e;let i=this._locationStrategy.getBaseHref();this._basePath=NI(lb(cb(i))),this._locationStrategy.onPopState(r=>{this._subject.emit({url:this.path(!0),pop:!0,state:r.state,type:r.type})})}ngOnDestroy(){this._urlChangeSubscription?.unsubscribe(),this._urlChangeListeners=[]}path(e=!1){return this.normalize(this._locationStrategy.path(e))}getState(){return this._locationStrategy.getState()}isCurrentPathEqualTo(e,i=""){return this.path()==this.normalize(e+mn(i))}normalize(e){return t.stripTrailingSlash(AI(this._basePath,cb(e)))}prepareExternalUrl(e){return e&&e[0]!=="/"&&(e="/"+e),this._locationStrategy.prepareExternalUrl(e)}go(e,i="",r=null){this._locationStrategy.pushState(r,"",e,i),this._notifyUrlChangeListeners(this.prepareExternalUrl(e+mn(i)),r)}replaceState(e,i="",r=null){this._locationStrategy.replaceState(r,"",e,i),this._notifyUrlChangeListeners(this.prepareExternalUrl(e+mn(i)),r)}forward(){this._locationStrategy.forward()}back(){this._locationStrategy.back()}historyGo(e=0){this._locationStrategy.historyGo?.(e)}onUrlChange(e){return this._urlChangeListeners.push(e),this._urlChangeSubscription??=this.subscribe(i=>{this._notifyUrlChangeListeners(i.url,i.state)}),()=>{let i=this._urlChangeListeners.indexOf(e);this._urlChangeListeners.splice(i,1),this._urlChangeListeners.length===0&&(this._urlChangeSubscription?.unsubscribe(),this._urlChangeSubscription=null)}}_notifyUrlChangeListeners(e="",i){this._urlChangeListeners.forEach(r=>r(e,i))}subscribe(e,i,r){return this._subject.subscribe({next:e,error:i,complete:r})}static{this.normalizeQueryParams=mn}static{this.joinWithSlash=Lh}static{this.stripTrailingSlash=lb}static{this.\u0275fac=function(i){return new(i||t)(R(Si))}}static{this.\u0275prov=A({token:t,factory:()=>TI(),providedIn:"root"})}}return t})();function TI(){return new Cr(R(Si))}function AI(t,n){if(!t||!n.startsWith(t))return n;let e=n.substring(t.length);return e===""||["/",";","?","#"].includes(e[0])?e:n}function cb(t){return t.replace(/\/index.html$/,"")}function NI(t){if(new RegExp("^(https?:)?//").test(t)){let[,e]=t.split(/\/\/[^\/]+/);return e}return t}var wb=function(t){return t[t.Decimal=0]="Decimal",t[t.Percent=1]="Percent",t[t.Currency=2]="Currency",t[t.Scientific=3]="Scientific",t}(wb||{});var vn={Decimal:0,Group:1,List:2,PercentSign:3,PlusSign:4,MinusSign:5,Exponential:6,SuperscriptingExponent:7,PerMille:8,Infinity:9,NaN:10,TimeSeparator:11,CurrencyDecimal:12,CurrencyGroup:13};function Ms(t,n){let e=gh(t),i=e[Dr.NumberSymbols][n];if(typeof i>"u"){if(n===vn.CurrencyDecimal)return e[Dr.NumberSymbols][vn.Decimal];if(n===vn.CurrencyGroup)return e[Dr.NumberSymbols][vn.Group]}return i}function RI(t,n){return gh(t)[Dr.NumberFormats][n]}var kI=/^(\d+)?\.((\d+)(-(\d+))?)?$/,ub=22,pl=".",Ss="0",PI=";",LI=",",Sh="#";function FI(t,n,e,i,r,s,o=!1){let a="",l=!1;if(!isFinite(t))a=Ms(e,vn.Infinity);else{let c=BI(t);o&&(c=HI(c));let u=n.minInt,d=n.minFrac,h=n.maxFrac;if(s){let y=s.match(kI);if(y===null)throw new Error(`${s} is not a valid digit info`);let w=y[1],C=y[3],b=y[5];w!=null&&(u=Ih(w)),C!=null&&(d=Ih(C)),b!=null?h=Ih(b):C!=null&&d>h&&(h=d)}UI(c,d,h);let f=c.digits,p=c.integerLen,g=c.exponent,m=[];for(l=f.every(y=>!y);p0?m=f.splice(p,f.length):(m=f,f=[0]);let v=[];for(f.length>=n.lgSize&&v.unshift(f.splice(-n.lgSize,f.length).join(""));f.length>n.gSize;)v.unshift(f.splice(-n.gSize,f.length).join(""));f.length&&v.unshift(f.join("")),a=v.join(Ms(e,i)),m.length&&(a+=Ms(e,r)+m.join("")),g&&(a+=Ms(e,vn.Exponential)+"+"+g)}return t<0&&!l?a=n.negPre+a+n.negSuf:a=n.posPre+a+n.posSuf,a}function VI(t,n,e){let i=RI(n,wb.Decimal),r=jI(i,Ms(n,vn.MinusSign));return FI(t,r,n,vn.Group,vn.Decimal,e)}function jI(t,n="-"){let e={minInt:1,minFrac:0,maxFrac:0,posPre:"",posSuf:"",negPre:"",negSuf:"",gSize:0,lgSize:0},i=t.split(PI),r=i[0],s=i[1],o=r.indexOf(pl)!==-1?r.split(pl):[r.substring(0,r.lastIndexOf(Ss)+1),r.substring(r.lastIndexOf(Ss)+1)],a=o[0],l=o[1]||"";e.posPre=a.substring(0,a.indexOf(Sh));for(let u=0;u-1&&(n=n.replace(pl,"")),(s=n.search(/e/i))>0?(r<0&&(r=s),r+=+n.slice(s+1),n=n.substring(0,s)):r<0&&(r=n.length),s=0;n.charAt(s)===Ss;s++);if(s===(a=n.length))i=[0],r=1;else{for(a--;n.charAt(a)===Ss;)a--;for(r-=s,i=[],o=0;s<=a;s++,o++)i[o]=Number(n.charAt(s))}return r>ub&&(i=i.splice(0,ub-1),e=r-1,r=1),{digits:i,exponent:e,integerLen:r}}function UI(t,n,e){if(n>e)throw new Error(`The minimum number of digits after fraction (${n}) is higher than the maximum (${e}).`);let i=t.digits,r=i.length-t.integerLen,s=Math.min(Math.max(n,r),e),o=s+t.integerLen,a=i[o];if(o>0){i.splice(Math.max(t.integerLen,o));for(let d=o;d=5)if(o-1<0){for(let d=0;d>o;d--)i.unshift(0),t.integerLen++;i.unshift(1),t.integerLen++}else i[o-1]++;for(;r=c?p.pop():l=!1),h>=10?1:0},0);u&&(i.unshift(u),t.integerLen++)}function Ih(t){let n=parseInt(t);if(isNaN(n))throw new Error("Invalid integer literal when parsing "+t);return n}function Db(t,n){n=encodeURIComponent(n);for(let e of t.split(";")){let i=e.indexOf("="),[r,s]=i==-1?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===n)return decodeURIComponent(s)}return null}var Oh=/\s+/,db=[],ml=(()=>{class t{constructor(e,i){this._ngEl=e,this._renderer=i,this.initialClasses=db,this.stateMap=new Map}set klass(e){this.initialClasses=e!=null?e.trim().split(Oh):db}set ngClass(e){this.rawClass=typeof e=="string"?e.trim().split(Oh):e}ngDoCheck(){for(let i of this.initialClasses)this._updateState(i,!0);let e=this.rawClass;if(Array.isArray(e)||e instanceof Set)for(let i of e)this._updateState(i,!0);else if(e!=null)for(let i of Object.keys(e))this._updateState(i,!!e[i]);this._applyStateDiff()}_updateState(e,i){let r=this.stateMap.get(e);r!==void 0?(r.enabled!==i&&(r.changed=!0,r.enabled=i),r.touched=!0):this.stateMap.set(e,{enabled:i,changed:!0,touched:!0})}_applyStateDiff(){for(let e of this.stateMap){let i=e[0],r=e[1];r.changed?(this._toggleClass(i,r.enabled),r.changed=!1):r.touched||(r.enabled&&this._toggleClass(i,!1),this.stateMap.delete(i)),r.touched=!1}}_toggleClass(e,i){e=e.trim(),e.length>0&&e.split(Oh).forEach(r=>{i?this._renderer.addClass(this._ngEl.nativeElement,r):this._renderer.removeClass(this._ngEl.nativeElement,r)})}static{this.\u0275fac=function(i){return new(i||t)(Q(We),Q(_t))}}static{this.\u0275dir=wt({type:t,selectors:[["","ngClass",""]],inputs:{klass:[0,"class","klass"],ngClass:"ngClass"},standalone:!0})}}return t})();var Th=class{constructor(n,e,i,r){this.$implicit=n,this.ngForOf=e,this.index=i,this.count=r}get first(){return this.index===0}get last(){return this.index===this.count-1}get even(){return this.index%2===0}get odd(){return!this.even}},_b=(()=>{class t{set ngForOf(e){this._ngForOf=e,this._ngForOfDirty=!0}set ngForTrackBy(e){this._trackByFn=e}get ngForTrackBy(){return this._trackByFn}constructor(e,i,r){this._viewContainer=e,this._template=i,this._differs=r,this._ngForOf=null,this._ngForOfDirty=!0,this._differ=null}set ngForTemplate(e){e&&(this._template=e)}ngDoCheck(){if(this._ngForOfDirty){this._ngForOfDirty=!1;let e=this._ngForOf;if(!this._differ&&e)if(0)try{}catch{}else this._differ=this._differs.find(e).create(this.ngForTrackBy)}if(this._differ){let e=this._differ.diff(this._ngForOf);e&&this._applyChanges(e)}}_applyChanges(e){let i=this._viewContainer;e.forEachOperation((r,s,o)=>{if(r.previousIndex==null)i.createEmbeddedView(this._template,new Th(r.item,this._ngForOf,-1,-1),o===null?void 0:o);else if(o==null)i.remove(s===null?void 0:s);else if(s!==null){let a=i.get(s);i.move(a,o),hb(a,r)}});for(let r=0,s=i.length;r{let s=i.get(r.currentIndex);hb(s,r)})}static ngTemplateContextGuard(e,i){return!0}static{this.\u0275fac=function(i){return new(i||t)(Q(pn),Q(bi),Q(Eh))}}static{this.\u0275dir=wt({type:t,selectors:[["","ngFor","","ngForOf",""]],inputs:{ngForOf:"ngForOf",ngForTrackBy:"ngForTrackBy",ngForTemplate:"ngForTemplate"},standalone:!0})}}return t})();function hb(t,n){t.context.$implicit=n.item}var Is=(()=>{class t{constructor(e,i){this._viewContainer=e,this._context=new Ah,this._thenTemplateRef=null,this._elseTemplateRef=null,this._thenViewRef=null,this._elseViewRef=null,this._thenTemplateRef=i}set ngIf(e){this._context.$implicit=this._context.ngIf=e,this._updateView()}set ngIfThen(e){fb("ngIfThen",e),this._thenTemplateRef=e,this._thenViewRef=null,this._updateView()}set ngIfElse(e){fb("ngIfElse",e),this._elseTemplateRef=e,this._elseViewRef=null,this._updateView()}_updateView(){this._context.$implicit?this._thenViewRef||(this._viewContainer.clear(),this._elseViewRef=null,this._thenTemplateRef&&(this._thenViewRef=this._viewContainer.createEmbeddedView(this._thenTemplateRef,this._context))):this._elseViewRef||(this._viewContainer.clear(),this._thenViewRef=null,this._elseTemplateRef&&(this._elseViewRef=this._viewContainer.createEmbeddedView(this._elseTemplateRef,this._context)))}static ngTemplateContextGuard(e,i){return!0}static{this.\u0275fac=function(i){return new(i||t)(Q(pn),Q(bi))}}static{this.\u0275dir=wt({type:t,selectors:[["","ngIf",""]],inputs:{ngIf:"ngIf",ngIfThen:"ngIfThen",ngIfElse:"ngIfElse"},standalone:!0})}}return t})(),Ah=class{constructor(){this.$implicit=null,this.ngIf=null}};function fb(t,n){if(!!!(!n||n.createEmbeddedView))throw new Error(`${t} must be a TemplateRef, but received '${Ze(n)}'.`)}var Cb=(()=>{class t{constructor(e,i,r){this._ngEl=e,this._differs=i,this._renderer=r,this._ngStyle=null,this._differ=null}set ngStyle(e){this._ngStyle=e,!this._differ&&e&&(this._differ=this._differs.find(e).create())}ngDoCheck(){if(this._differ){let e=this._differ.diff(this._ngStyle);e&&this._applyChanges(e)}}_setStyle(e,i){let[r,s]=e.split("."),o=r.indexOf("-")===-1?void 0:Gt.DashCase;i!=null?this._renderer.setStyle(this._ngEl.nativeElement,r,s?`${i}${s}`:i,o):this._renderer.removeStyle(this._ngEl.nativeElement,r,o)}_applyChanges(e){e.forEachRemovedItem(i=>this._setStyle(i.key,null)),e.forEachAddedItem(i=>this._setStyle(i.key,i.currentValue)),e.forEachChangedItem(i=>this._setStyle(i.key,i.currentValue))}static{this.\u0275fac=function(i){return new(i||t)(Q(We),Q(Mh),Q(_t))}}static{this.\u0275dir=wt({type:t,selectors:[["","ngStyle",""]],inputs:{ngStyle:"ngStyle"},standalone:!0})}}return t})(),xb=(()=>{class t{constructor(e){this._viewContainerRef=e,this._viewRef=null,this.ngTemplateOutletContext=null,this.ngTemplateOutlet=null,this.ngTemplateOutletInjector=null}ngOnChanges(e){if(this._shouldRecreateView(e)){let i=this._viewContainerRef;if(this._viewRef&&i.remove(i.indexOf(this._viewRef)),!this.ngTemplateOutlet){this._viewRef=null;return}let r=this._createContextForwardProxy();this._viewRef=i.createEmbeddedView(this.ngTemplateOutlet,r,{injector:this.ngTemplateOutletInjector??void 0})}}_shouldRecreateView(e){return!!e.ngTemplateOutlet||!!e.ngTemplateOutletInjector}_createContextForwardProxy(){return new Proxy({},{set:(e,i,r)=>this.ngTemplateOutletContext?Reflect.set(this.ngTemplateOutletContext,i,r):!1,get:(e,i,r)=>{if(this.ngTemplateOutletContext)return Reflect.get(this.ngTemplateOutletContext,i,r)}})}static{this.\u0275fac=function(i){return new(i||t)(Q(pn))}}static{this.\u0275dir=wt({type:t,selectors:[["","ngTemplateOutlet",""]],inputs:{ngTemplateOutletContext:"ngTemplateOutletContext",ngTemplateOutlet:"ngTemplateOutlet",ngTemplateOutletInjector:"ngTemplateOutletInjector"},standalone:!0,features:[Rt]})}}return t})();function $I(t,n){return new T(2100,!1)}var Eb=(()=>{class t{constructor(e){this._locale=e}transform(e,i,r){if(!zI(e))return null;r||=this._locale;try{let s=WI(e);return VI(s,r,i)}catch(s){throw $I(t,s.message)}}static{this.\u0275fac=function(i){return new(i||t)(Q(hl,16))}}static{this.\u0275pipe=Hm({name:"number",type:t,pure:!0,standalone:!0})}}return t})();function zI(t){return!(t==null||t===""||t!==t)}function WI(t){if(typeof t=="string"&&!isNaN(Number(t)-parseFloat(t)))return Number(t);if(typeof t!="number")throw new Error(`${t} is not a number`);return t}var vl=(()=>{class t{static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275mod=ut({type:t})}static{this.\u0275inj=ct({})}}return t})(),Vh="browser",GI="server";function qI(t){return t===Vh}function jh(t){return t===GI}var Mb=(()=>{class t{static{this.\u0275prov=A({token:t,providedIn:"root",factory:()=>qI(E(Hn))?new Nh(E(et),window):new Rh})}}return t})(),Nh=class{constructor(n,e){this.document=n,this.window=e,this.offset=()=>[0,0]}setOffset(n){Array.isArray(n)?this.offset=()=>n:this.offset=n}getScrollPosition(){return[this.window.scrollX,this.window.scrollY]}scrollToPosition(n){this.window.scrollTo(n[0],n[1])}scrollToAnchor(n){let e=YI(this.document,n);e&&(this.scrollToElement(e),e.focus())}setHistoryScrollRestoration(n){this.window.history.scrollRestoration=n}scrollToElement(n){let e=n.getBoundingClientRect(),i=e.left+this.window.pageXOffset,r=e.top+this.window.pageYOffset,s=this.offset();this.window.scrollTo(i-s[0],r-s[1])}};function YI(t,n){let e=t.getElementById(n)||t.getElementsByName(n)[0];if(e)return e;if(typeof t.createTreeWalker=="function"&&t.body&&typeof t.body.attachShadow=="function"){let i=t.createTreeWalker(t.body,NodeFilter.SHOW_ELEMENT),r=i.currentNode;for(;r;){let s=r.shadowRoot;if(s){let o=s.getElementById(n)||s.querySelector(`[name="${n}"]`);if(o)return o}r=i.nextNode()}}return null}var Rh=class{setOffset(n){}getScrollPosition(){return[0,0]}scrollToPosition(n){}scrollToAnchor(n){}setHistoryScrollRestoration(n){}},gl=class{};var Uh=class extends fl{constructor(){super(...arguments),this.supportsDOMEvents=!0}},$h=class t extends Uh{static makeCurrent(){mb(new t)}onAndCancel(n,e,i){return n.addEventListener(e,i),()=>{n.removeEventListener(e,i)}}dispatchEvent(n,e){n.dispatchEvent(e)}remove(n){n.remove()}createElement(n,e){return e=e||this.getDefaultDocument(),e.createElement(n)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(n){return n.nodeType===Node.ELEMENT_NODE}isShadowRoot(n){return n instanceof DocumentFragment}getGlobalEventTarget(n,e){return e==="window"?window:e==="document"?n:e==="body"?n.body:null}getBaseHref(n){let e=QI();return e==null?null:KI(e)}resetBaseElement(){Os=null}getUserAgent(){return window.navigator.userAgent}getCookie(n){return Db(document.cookie,n)}},Os=null;function QI(){return Os=Os||document.querySelector("base"),Os?Os.getAttribute("href"):null}function KI(t){return new URL(t,document.baseURI).pathname}var zh=class{addToWindow(n){Le.getAngularTestability=(i,r=!0)=>{let s=n.findTestabilityInTree(i,r);if(s==null)throw new T(5103,!1);return s},Le.getAllAngularTestabilities=()=>n.getAllTestabilities(),Le.getAllAngularRootElements=()=>n.getAllRootElements();let e=i=>{let r=Le.getAllAngularTestabilities(),s=r.length,o=function(){s--,s==0&&i()};r.forEach(a=>{a.whenStable(o)})};Le.frameworkStabilizers||(Le.frameworkStabilizers=[]),Le.frameworkStabilizers.push(e)}findTestabilityInTree(n,e,i){if(e==null)return null;let r=n.getTestability(e);return r??(i?Mi().isShadowRoot(e)?this.findTestabilityInTree(n,e.host,!0):this.findTestabilityInTree(n,e.parentElement,!0):null)}},XI=(()=>{class t{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac})}}return t})(),Wh=new N(""),Tb=(()=>{class t{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new T(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||t)(R(Wh),R(ue))}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac})}}return t})(),bl=class{constructor(n){this._doc=n}},Hh="ng-app-id",Ab=(()=>{class t{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=jh(s),this.resetHostNodes()}addStyles(e){for(let i of e)this.changeUsageCount(i,1)===1&&this.onStyleAdded(i)}removeStyles(e){for(let i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){let e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(let i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(let i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(let i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){let i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){let e=this.doc.head?.querySelectorAll(`style[${Hh}="${this.appId}"]`);if(e?.length){let i=new Map;return e.forEach(r=>{r.textContent!=null&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){let r=this.styleRef;if(r.has(e)){let s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){let r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(Hh),s;{let o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(Hh,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){let r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){let e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||t)(R(et),R(Ya),R(qd,8),R(Hn))}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac})}}return t})(),Bh={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/Math/MathML"},qh=/%COMP%/g,Nb="%COMP%",JI=`_nghost-${Nb}`,eO=`_ngcontent-${Nb}`,tO=!0,nO=new N("",{providedIn:"root",factory:()=>tO});function iO(t){return eO.replace(qh,t)}function rO(t){return JI.replace(qh,t)}function Rb(t,n){return n.map(e=>e.replace(qh,t))}var Sb=(()=>{class t{constructor(e,i,r,s,o,a,l,c=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=c,this.rendererByCompId=new Map,this.platformIsServer=jh(a),this.defaultRenderer=new Ts(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===Ut.ShadowDom&&(i=ae(S({},i),{encapsulation:Ut.Emulated}));let r=this.getOrCreateRenderer(e,i);return r instanceof wl?r.applyToHost(e):r instanceof As&&r.applyStyles(),r}getOrCreateRenderer(e,i){let r=this.rendererByCompId,s=r.get(i.id);if(!s){let o=this.doc,a=this.ngZone,l=this.eventManager,c=this.sharedStylesHost,u=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case Ut.Emulated:s=new wl(l,c,i,this.appId,u,o,a,d);break;case Ut.ShadowDom:return new Gh(l,c,e,i,o,a,this.nonce,d);default:s=new As(l,c,i,u,o,a,d);break}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||t)(R(Tb),R(Ab),R(Ya),R(nO),R(et),R(Hn),R(ue),R(qd))}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac})}}return t})(),Ts=class{constructor(n,e,i,r){this.eventManager=n,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(n,e){return e?this.doc.createElementNS(Bh[e]||e,n):this.doc.createElement(n)}createComment(n){return this.doc.createComment(n)}createText(n){return this.doc.createTextNode(n)}appendChild(n,e){(Ib(n)?n.content:n).appendChild(e)}insertBefore(n,e,i){n&&(Ib(n)?n.content:n).insertBefore(e,i)}removeChild(n,e){e.remove()}selectRootElement(n,e){let i=typeof n=="string"?this.doc.querySelector(n):n;if(!i)throw new T(-5104,!1);return e||(i.textContent=""),i}parentNode(n){return n.parentNode}nextSibling(n){return n.nextSibling}setAttribute(n,e,i,r){if(r){e=r+":"+e;let s=Bh[r];s?n.setAttributeNS(s,e,i):n.setAttribute(e,i)}else n.setAttribute(e,i)}removeAttribute(n,e,i){if(i){let r=Bh[i];r?n.removeAttributeNS(r,e):n.removeAttribute(`${i}:${e}`)}else n.removeAttribute(e)}addClass(n,e){n.classList.add(e)}removeClass(n,e){n.classList.remove(e)}setStyle(n,e,i,r){r&(Gt.DashCase|Gt.Important)?n.style.setProperty(e,i,r&Gt.Important?"important":""):n.style[e]=i}removeStyle(n,e,i){i&Gt.DashCase?n.style.removeProperty(e):n.style[e]=""}setProperty(n,e,i){n!=null&&(n[e]=i)}setValue(n,e){n.nodeValue=e}listen(n,e,i){if(typeof n=="string"&&(n=Mi().getGlobalEventTarget(this.doc,n),!n))throw new Error(`Unsupported event target ${n} for event ${e}`);return this.eventManager.addEventListener(n,e,this.decoratePreventDefault(i))}decoratePreventDefault(n){return e=>{if(e==="__ngUnwrap__")return n;(this.platformIsServer?this.ngZone.runGuarded(()=>n(e)):n(e))===!1&&e.preventDefault()}}};function Ib(t){return t.tagName==="TEMPLATE"&&t.content!==void 0}var Gh=class extends Ts{constructor(n,e,i,r,s,o,a,l){super(n,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);let c=Rb(r.id,r.styles);for(let u of c){let d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=u,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(n){return n===this.hostEl?this.shadowRoot:n}appendChild(n,e){return super.appendChild(this.nodeOrShadowRoot(n),e)}insertBefore(n,e,i){return super.insertBefore(this.nodeOrShadowRoot(n),e,i)}removeChild(n,e){return super.removeChild(null,e)}parentNode(n){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(n)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}},As=class extends Ts{constructor(n,e,i,r,s,o,a,l){super(n,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Rb(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}},wl=class extends As{constructor(n,e,i,r,s,o,a,l){let c=r+"-"+i.id;super(n,e,i,s,o,a,l,c),this.contentAttr=iO(c),this.hostAttr=rO(c)}applyToHost(n){this.applyStyles(),this.setAttribute(n,this.hostAttr,"")}createElement(n,e){let i=super.createElement(n,e);return super.setAttribute(i,this.contentAttr,""),i}},sO=(()=>{class t extends bl{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||t)(R(et))}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac})}}return t})(),Ob=["alt","control","meta","shift"],oO={"\b":"Backspace"," ":"Tab","\x7F":"Delete","\x1B":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},aO={alt:t=>t.altKey,control:t=>t.ctrlKey,meta:t=>t.metaKey,shift:t=>t.shiftKey},lO=(()=>{class t extends bl{constructor(e){super(e)}supports(e){return t.parseEventName(e)!=null}addEventListener(e,i,r){let s=t.parseEventName(i),o=t.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Mi().onAndCancel(e,s.domEventName,o))}static parseEventName(e){let i=e.toLowerCase().split("."),r=i.shift();if(i.length===0||!(r==="keydown"||r==="keyup"))return null;let s=t._normalizeKey(i.pop()),o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Ob.forEach(c=>{let u=i.indexOf(c);u>-1&&(i.splice(u,1),o+=c+".")}),o+=s,i.length!=0||s.length===0)return null;let l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=oO[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),r==null||!r?!1:(r=r.toLowerCase(),r===" "?r="space":r==="."&&(r="dot"),Ob.forEach(o=>{if(o!==r){let a=aO[o];a(e)&&(s+=o+".")}}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{t.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return e==="esc"?"escape":e}static{this.\u0275fac=function(i){return new(i||t)(R(et))}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac})}}return t})();function cO(){$h.makeCurrent()}function uO(){return new cn}function dO(){return zv(document),document}var hO=[{provide:Hn,useValue:Vh},{provide:Gd,useValue:cO,multi:!0},{provide:et,useFactory:dO,deps:[]}],kb=xh(sb,"browser",hO),fO=new N(""),pO=[{provide:Es,useClass:zh,deps:[]},{provide:Dh,useClass:ll,deps:[ue,cl,Es]},{provide:ll,useClass:ll,deps:[ue,cl,Es]}],gO=[{provide:Va,useValue:"root"},{provide:cn,useFactory:uO,deps:[]},{provide:Wh,useClass:sO,multi:!0,deps:[et,ue,Hn]},{provide:Wh,useClass:lO,multi:!0,deps:[et]},Sb,Ab,Tb,{provide:fr,useExisting:Sb},{provide:gl,useClass:XI,deps:[]},[]],Pb=(()=>{class t{constructor(e){}static withServerTransition(e){return{ngModule:t,providers:[{provide:Ya,useValue:e.appId}]}}static{this.\u0275fac=function(i){return new(i||t)(R(fO,12))}}static{this.\u0275mod=ut({type:t})}static{this.\u0275inj=ct({providers:[...gO,...pO],imports:[vl,ob]})}}return t})();var Lb=(()=>{class t{constructor(e){this._doc=e}getTitle(){return this._doc.title}setTitle(e){this._doc.title=e||""}static{this.\u0275fac=function(i){return new(i||t)(R(et))}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})();var Vb=new N("");var mO={"[class.ng-untouched]":"isUntouched","[class.ng-touched]":"isTouched","[class.ng-pristine]":"isPristine","[class.ng-dirty]":"isDirty","[class.ng-valid]":"isValid","[class.ng-invalid]":"isInvalid","[class.ng-pending]":"isPending"},dU=ae(S({},mO),{"[class.ng-submitted]":"isSubmitted"});var ht=typeof window<"u"?window:{screen:{},navigator:{}},xr=(ht.matchMedia||function(){return{matches:!1}}).bind(ht),jb=!1,vO={get passive(){return jb=!0}},Hb=function(){};ht.addEventListener&&ht.addEventListener("p",Hb,vO);ht.removeEventListener&&ht.removeEventListener("p",Hb,!1);var Dl=jb,pU="PointerEvent"in ht,Yh="ontouchstart"in ht,yO="TouchEvent"in ht,bO=Yh||yO&&xr("(any-pointer: coarse)").matches,gU=(ht.navigator.maxTouchPoints||0)>0||bO,Bb=ht.navigator.userAgent||"",wO=xr("(pointer: coarse)").matches&&/iPad|Macintosh/.test(Bb)&&Math.min(ht.screen.width||0,ht.screen.height||0)>=768,mU=(xr("(pointer: coarse)").matches||!xr("(pointer: fine)").matches&&Yh)&&!/Windows.*Firefox/.test(Bb),vU=xr("(any-pointer: fine)").matches||xr("(any-hover: hover)").matches||wO||!Yh;var DO=(t,n,e)=>({tooltip:t,placement:n,content:e});function _O(t,n){}function CO(t,n){t&1&&gn(0,_O,0,0,"ng-template")}function xO(t,n){if(t&1&&(il(0),gn(1,CO,1,0,null,1),rl()),t&2){let e=Yt();q(),Y("ngTemplateOutlet",e.template)("ngTemplateOutletContext",Zy(2,DO,e.tooltip,e.placement,e.content))}}function EO(t,n){if(t&1&&(il(0),L(1,"div",2),Bn(2),j(),rl()),t&2){let e=Yt();q(),wr("title",e.tooltip)("data-tooltip-placement",e.placement),q(),ol(" ",e.content," ")}}var MO=["tooltipTemplate"],SO=["leftOuterSelectionBar"],IO=["rightOuterSelectionBar"],OO=["fullBar"],TO=["selectionBar"],AO=["minHandle"],NO=["maxHandle"],RO=["floorLabel"],kO=["ceilLabel"],PO=["minHandleLabel"],LO=["maxHandleLabel"],FO=["combinedLabel"],VO=["ticksElement"],jO=t=>({"ngx-slider-selected":t});function HO(t,n){if(t&1&&le(0,"ngx-slider-tooltip-wrapper",32),t&2){let e=Yt().$implicit,i=Yt();Y("template",i.tooltipTemplate)("tooltip",e.valueTooltip)("placement",e.valueTooltipPlacement)("content",e.value)}}function BO(t,n){if(t&1&&le(0,"span",33),t&2){let e=Yt().$implicit;Y("innerText",e.legend)}}function UO(t,n){if(t&1&&le(0,"span",34),t&2){let e=Yt().$implicit;Y("innerHTML",e.legend,Jv)}}function $O(t,n){if(t&1&&(L(0,"span",27),le(1,"ngx-slider-tooltip-wrapper",28),gn(2,HO,1,4,"ngx-slider-tooltip-wrapper",29)(3,BO,1,1,"span",30)(4,UO,1,1,"span",31),j()),t&2){let e=n.$implicit,i=Yt();Y("ngClass",dt(8,jO,e.selected))("ngStyle",e.style),q(),Y("template",i.tooltipTemplate)("tooltip",e.tooltip)("placement",e.tooltipPlacement),q(),Y("ngIf",e.value!==null&&e.value!==void 0),q(),Y("ngIf",e.legend!==null&&e.legend!==void 0&&i.allowUnsafeHtmlInSlider===!1),q(),Y("ngIf",e.legend!==null&&e.legend!==void 0&&(i.allowUnsafeHtmlInSlider===null||i.allowUnsafeHtmlInSlider===void 0||i.allowUnsafeHtmlInSlider))}}var Zt=function(t){return t[t.Low=0]="Low",t[t.High=1]="High",t[t.Floor=2]="Floor",t[t.Ceil=3]="Ceil",t[t.TickValue=4]="TickValue",t}(Zt||{}),Mr=class{floor=0;ceil=null;step=1;minRange=null;maxRange=null;pushRange=!1;minLimit=null;maxLimit=null;translate=null;combineLabels=null;getLegend=null;getStepLegend=null;stepsArray=null;bindIndexForStepsArray=!1;draggableRange=!1;draggableRangeOnly=!1;showSelectionBar=!1;showSelectionBarEnd=!1;showSelectionBarFromValue=null;showOuterSelectionBars=!1;hidePointerLabels=!1;hideLimitLabels=!1;autoHideLimitLabels=!0;readOnly=!1;disabled=!1;showTicks=!1;showTicksValues=!1;tickStep=null;tickValueStep=null;ticksArray=null;ticksTooltip=null;ticksValuesTooltip=null;vertical=!1;getSelectionBarColor=null;getTickColor=null;getPointerColor=null;keyboardSupport=!0;scale=1;rotate=0;enforceStep=!0;enforceRange=!0;enforceStepsArray=!0;noSwitching=!1;onlyBindHandles=!1;rightToLeft=!1;reversedControls=!1;boundPointerLabels=!0;logScale=!1;customValueToPosition=null;customPositionToValue=null;precisionLimit=12;selectionBarGradient=null;ariaLabel="ngx-slider";ariaLabelledBy=null;ariaLabelHigh="ngx-slider-max";ariaLabelledByHigh=null;handleDimension=null;barDimension=null;animate=!0;animateOnMove=!1},Ml=new N("AllowUnsafeHtmlInSlider"),I=function(t){return t[t.Min=0]="Min",t[t.Max=1]="Max",t}(I||{}),Qh=class{value;highValue;pointerType},_=class{static isNullOrUndefined(n){return n==null}static areArraysEqual(n,e){if(n.length!==e.length)return!1;for(let i=0;iMath.abs(n-s.value)),r=0;for(let s=0;s{s.events.next(a)};return n.addEventListener(e,o,{passive:!0,capture:!1}),s.teardownCallback=()=>{n.removeEventListener(e,o,{passive:!0,capture:!1})},s.eventsSubscription=s.events.pipe(_.isNullOrUndefined(r)?Ie(()=>{}):Go(r,void 0,{leading:!0,trailing:!0})).subscribe(a=>{i(a)}),s}detachEventListener(n){_.isNullOrUndefined(n.eventsSubscription)||(n.eventsSubscription.unsubscribe(),n.eventsSubscription=null),_.isNullOrUndefined(n.events)||(n.events.complete(),n.events=null),_.isNullOrUndefined(n.teardownCallback)||(n.teardownCallback(),n.teardownCallback=null)}attachEventListener(n,e,i,r){let s=new _l;s.eventName=e,s.events=new Ee;let o=a=>{s.events.next(a)};return s.teardownCallback=this.renderer.listen(n,e,o),s.eventsSubscription=s.events.pipe(_.isNullOrUndefined(r)?Ie(()=>{}):Go(r,void 0,{leading:!0,trailing:!0})).subscribe(a=>{i(a)}),s}},$n=(()=>{class t{elemRef;renderer;changeDetectionRef;_position=0;get position(){return this._position}_dimension=0;get dimension(){return this._dimension}_alwaysHide=!1;get alwaysHide(){return this._alwaysHide}_vertical=!1;get vertical(){return this._vertical}_scale=1;get scale(){return this._scale}_rotate=0;get rotate(){return this._rotate}opacity=1;visibility="visible";left="";bottom="";height="";width="";transform="";eventListenerHelper;eventListeners=[];constructor(e,i,r){this.elemRef=e,this.renderer=i,this.changeDetectionRef=r,this.eventListenerHelper=new Cl(this.renderer)}setAlwaysHide(e){this._alwaysHide=e,e?this.visibility="hidden":this.visibility="visible"}hide(){this.opacity=0}show(){this.alwaysHide||(this.opacity=1)}isVisible(){return this.alwaysHide?!1:this.opacity!==0}setVertical(e){this._vertical=e,this._vertical?(this.left="",this.width=""):(this.bottom="",this.height="")}setScale(e){this._scale=e}setRotate(e){this._rotate=e,this.transform="rotate("+e+"deg)"}getRotate(){return this._rotate}setPosition(e){this._position!==e&&!this.isRefDestroyed()&&this.changeDetectionRef.markForCheck(),this._position=e,this._vertical?this.bottom=Math.round(e)+"px":this.left=Math.round(e)+"px"}calculateDimension(){let e=this.getBoundingClientRect();this.vertical?this._dimension=(e.bottom-e.top)*this.scale:this._dimension=(e.right-e.left)*this.scale}setDimension(e){this._dimension!==e&&!this.isRefDestroyed()&&this.changeDetectionRef.markForCheck(),this._dimension=e,this._vertical?this.height=Math.round(e)+"px":this.width=Math.round(e)+"px"}getBoundingClientRect(){return this.elemRef.nativeElement.getBoundingClientRect()}on(e,i,r){let s=this.eventListenerHelper.attachEventListener(this.elemRef.nativeElement,e,i,r);this.eventListeners.push(s)}onPassive(e,i,r){let s=this.eventListenerHelper.attachPassiveEventListener(this.elemRef.nativeElement,e,i,r);this.eventListeners.push(s)}off(e){let i,r;_.isNullOrUndefined(e)?(i=[],r=this.eventListeners):(i=this.eventListeners.filter(s=>s.eventName!==e),r=this.eventListeners.filter(s=>s.eventName===e));for(let s of r)this.eventListenerHelper.detachEventListener(s);this.eventListeners=i}isRefDestroyed(){return _.isNullOrUndefined(this.changeDetectionRef)||this.changeDetectionRef.destroyed}static \u0275fac=function(i){return new(i||t)(Q(We),Q(_t),Q(Pt))};static \u0275dir=wt({type:t,selectors:[["","ngxSliderElement",""]],hostVars:14,hostBindings:function(i,r){i&2&&Cs("opacity",r.opacity)("visibility",r.visibility)("left",r.left)("bottom",r.bottom)("height",r.height)("width",r.width)("transform",r.transform)}})}return t})(),Zh=(()=>{class t extends $n{active=!1;role="";tabindex="";ariaOrientation="";ariaLabel="";ariaLabelledBy="";ariaValueNow="";ariaValueText="";ariaValueMin="";ariaValueMax="";focus(){this.elemRef.nativeElement.focus()}focusIfNeeded(){document.activeElement!==this.elemRef.nativeElement&&this.elemRef.nativeElement.focus()}constructor(e,i,r){super(e,i,r)}static \u0275fac=function(i){return new(i||t)(Q(We),Q(_t),Q(Pt))};static \u0275dir=wt({type:t,selectors:[["","ngxSliderHandle",""]],hostVars:11,hostBindings:function(i,r){i&2&&(wr("role",r.role)("tabindex",r.tabindex)("aria-orientation",r.ariaOrientation)("aria-label",r.ariaLabel)("aria-labelledby",r.ariaLabelledBy)("aria-valuenow",r.ariaValueNow)("aria-valuetext",r.ariaValueText)("aria-valuemin",r.ariaValueMin)("aria-valuemax",r.ariaValueMax),Ei("ngx-slider-active",r.active))},features:[tl]})}return t})(),Er=(()=>{class t extends $n{allowUnsafeHtmlInSlider;_value=null;get value(){return this._value}constructor(e,i,r,s){super(e,i,r),this.allowUnsafeHtmlInSlider=s}setValue(e){let i=!1;!this.alwaysHide&&(_.isNullOrUndefined(this.value)||this.value.length!==e.length||this.value.length>0&&this.dimension===0)&&(i=!0),this._value=e,this.allowUnsafeHtmlInSlider===!1?this.elemRef.nativeElement.innerText=e:this.elemRef.nativeElement.innerHTML=e,i&&this.calculateDimension()}static \u0275fac=function(i){return new(i||t)(Q(We),Q(_t),Q(Pt),Q(Ml,8))};static \u0275dir=wt({type:t,selectors:[["","ngxSliderLabel",""]],features:[tl]})}return t})(),zO=(()=>{class t{template;tooltip;placement;content;static \u0275fac=function(i){return new(i||t)};static \u0275cmp=Fe({type:t,selectors:[["ngx-slider-tooltip-wrapper"]],inputs:{template:"template",tooltip:"tooltip",placement:"placement",content:"content"},decls:2,vars:2,consts:[[4,"ngIf"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],[1,"ngx-slider-inner-tooltip"]],template:function(i,r){i&1&&gn(0,xO,2,6,"ng-container",0)(1,EO,3,3,"ng-container",0),i&2&&(Y("ngIf",r.template),q(),Y("ngIf",!r.template))},dependencies:[Is,xb],styles:[".ngx-slider-inner-tooltip[_ngcontent-%COMP%]{height:100%}"]})}return t})(),Kh=class{selected=!1;style={};tooltip=null;tooltipPlacement=null;value=null;valueTooltip=null;valueTooltipPlacement=null;legend=null},xl=class{active=!1;value=0;difference=0;position=0;lowLimit=0;highLimit=0},Sr=class{value;highValue;static compare(n,e){return _.isNullOrUndefined(n)&&_.isNullOrUndefined(e)||_.isNullOrUndefined(n)!==_.isNullOrUndefined(e)?!1:n.value===e.value&&n.highValue===e.highValue}},El=class extends Sr{forceChange;static compare(n,e){return _.isNullOrUndefined(n)&&_.isNullOrUndefined(e)||_.isNullOrUndefined(n)!==_.isNullOrUndefined(e)?!1:n.value===e.value&&n.highValue===e.highValue&&n.forceChange===e.forceChange}};var WO={provide:Vb,useExisting:ms(()=>Xh),multi:!0},Xh=(()=>{class t{renderer;elementRef;changeDetectionRef;zone;allowUnsafeHtmlInSlider;sliderElementNgxSliderClass=!0;value=null;valueChange=new re;highValue=null;highValueChange=new re;options=new Mr;userChangeStart=new re;userChange=new re;userChangeEnd=new re;manualRefreshSubscription;set manualRefresh(e){this.unsubscribeManualRefresh(),this.manualRefreshSubscription=e.subscribe(()=>{setTimeout(()=>this.calculateViewDimensionsAndDetectChanges())})}triggerFocusSubscription;set triggerFocus(e){this.unsubscribeTriggerFocus(),this.triggerFocusSubscription=e.subscribe(i=>{this.focusPointer(i)})}get range(){return!_.isNullOrUndefined(this.value)&&!_.isNullOrUndefined(this.highValue)}initHasRun=!1;inputModelChangeSubject=new Ee;inputModelChangeSubscription=null;outputModelChangeSubject=new Ee;outputModelChangeSubscription=null;viewLowValue=null;viewHighValue=null;viewOptions=new Mr;handleHalfDimension=0;maxHandlePosition=0;currentTrackingPointer=null;currentFocusPointer=null;firstKeyDown=!1;touchId=null;dragging=new xl;leftOuterSelectionBarElement;rightOuterSelectionBarElement;fullBarElement;selectionBarElement;minHandleElement;maxHandleElement;floorLabelElement;ceilLabelElement;minHandleLabelElement;maxHandleLabelElement;combinedLabelElement;ticksElement;tooltipTemplate;sliderElementVerticalClass=!1;sliderElementAnimateClass=!1;sliderElementWithLegendClass=!1;sliderElementDisabledAttr=null;sliderElementAriaLabel="ngx-slider";barStyle={};minPointerStyle={};maxPointerStyle={};fullBarTransparentClass=!1;selectionBarDraggableClass=!1;ticksUnderValuesClass=!1;get showTicks(){return this.viewOptions.showTicks}intermediateTicks=!1;ticks=[];eventListenerHelper=null;onMoveEventListener=null;onEndEventListener=null;moving=!1;resizeObserver=null;onTouchedCallback=null;onChangeCallback=null;constructor(e,i,r,s,o){this.renderer=e,this.elementRef=i,this.changeDetectionRef=r,this.zone=s,this.allowUnsafeHtmlInSlider=o,this.eventListenerHelper=new Cl(this.renderer)}ngOnInit(){this.viewOptions=new Mr,Object.assign(this.viewOptions,this.options),this.updateDisabledState(),this.updateVerticalState(),this.updateAriaLabel()}ngAfterViewInit(){this.applyOptions(),this.subscribeInputModelChangeSubject(),this.subscribeOutputModelChangeSubject(),this.renormaliseModelValues(),this.viewLowValue=this.modelValueToViewValue(this.value),this.range?this.viewHighValue=this.modelValueToViewValue(this.highValue):this.viewHighValue=null,this.updateVerticalState(),this.manageElementsStyle(),this.updateDisabledState(),this.calculateViewDimensions(),this.addAccessibility(),this.updateCeilLabel(),this.updateFloorLabel(),this.initHandles(),this.manageEventsBindings(),this.updateAriaLabel(),this.subscribeResizeObserver(),this.initHasRun=!0,this.isRefDestroyed()||this.changeDetectionRef.detectChanges()}ngOnChanges(e){!_.isNullOrUndefined(e.options)&&JSON.stringify(e.options.previousValue)!==JSON.stringify(e.options.currentValue)&&this.onChangeOptions(),(!_.isNullOrUndefined(e.value)||!_.isNullOrUndefined(e.highValue))&&this.inputModelChangeSubject.next({value:this.value,highValue:this.highValue,forceChange:!1,internalChange:!1})}ngOnDestroy(){this.unbindEvents(),this.unsubscribeResizeObserver(),this.unsubscribeInputModelChangeSubject(),this.unsubscribeOutputModelChangeSubject(),this.unsubscribeManualRefresh(),this.unsubscribeTriggerFocus()}writeValue(e){e instanceof Array?(this.value=e[0],this.highValue=e[1]):this.value=e,this.inputModelChangeSubject.next({value:this.value,highValue:this.highValue,forceChange:!1,internalChange:!1})}registerOnChange(e){this.onChangeCallback=e}registerOnTouched(e){this.onTouchedCallback=e}setDisabledState(e){this.viewOptions.disabled=e,this.updateDisabledState()}setAriaLabel(e){this.viewOptions.ariaLabel=e,this.updateAriaLabel()}onResize(e){this.calculateViewDimensionsAndDetectChanges()}subscribeInputModelChangeSubject(){this.inputModelChangeSubscription=this.inputModelChangeSubject.pipe(zo(El.compare),Xe(e=>!e.forceChange&&!e.internalChange)).subscribe(e=>this.applyInputModelChange(e))}subscribeOutputModelChangeSubject(){this.outputModelChangeSubscription=this.outputModelChangeSubject.pipe(zo(El.compare)).subscribe(e=>this.publishOutputModelChange(e))}subscribeResizeObserver(){Qt.isResizeObserverAvailable()&&(this.resizeObserver=new ResizeObserver(()=>this.calculateViewDimensionsAndDetectChanges()),this.resizeObserver.observe(this.elementRef.nativeElement))}unsubscribeResizeObserver(){Qt.isResizeObserverAvailable()&&this.resizeObserver!==null&&(this.resizeObserver.disconnect(),this.resizeObserver=null)}unsubscribeOnMove(){_.isNullOrUndefined(this.onMoveEventListener)||(this.eventListenerHelper.detachEventListener(this.onMoveEventListener),this.onMoveEventListener=null)}unsubscribeOnEnd(){_.isNullOrUndefined(this.onEndEventListener)||(this.eventListenerHelper.detachEventListener(this.onEndEventListener),this.onEndEventListener=null)}unsubscribeInputModelChangeSubject(){_.isNullOrUndefined(this.inputModelChangeSubscription)||(this.inputModelChangeSubscription.unsubscribe(),this.inputModelChangeSubscription=null)}unsubscribeOutputModelChangeSubject(){_.isNullOrUndefined(this.outputModelChangeSubscription)||(this.outputModelChangeSubscription.unsubscribe(),this.outputModelChangeSubscription=null)}unsubscribeManualRefresh(){_.isNullOrUndefined(this.manualRefreshSubscription)||(this.manualRefreshSubscription.unsubscribe(),this.manualRefreshSubscription=null)}unsubscribeTriggerFocus(){_.isNullOrUndefined(this.triggerFocusSubscription)||(this.triggerFocusSubscription.unsubscribe(),this.triggerFocusSubscription=null)}getPointerElement(e){return e===I.Min?this.minHandleElement:e===I.Max?this.maxHandleElement:null}getCurrentTrackingValue(){return this.currentTrackingPointer===I.Min?this.viewLowValue:this.currentTrackingPointer===I.Max?this.viewHighValue:null}modelValueToViewValue(e){return _.isNullOrUndefined(e)?NaN:!_.isNullOrUndefined(this.viewOptions.stepsArray)&&!this.viewOptions.bindIndexForStepsArray?_.findStepIndex(+e,this.viewOptions.stepsArray):+e}viewValueToModelValue(e){return!_.isNullOrUndefined(this.viewOptions.stepsArray)&&!this.viewOptions.bindIndexForStepsArray?this.getStepValue(e):e}getStepValue(e){let i=this.viewOptions.stepsArray[e];return _.isNullOrUndefined(i)?NaN:i.value}applyViewChange(){this.value=this.viewValueToModelValue(this.viewLowValue),this.range&&(this.highValue=this.viewValueToModelValue(this.viewHighValue)),this.outputModelChangeSubject.next({value:this.value,highValue:this.highValue,userEventInitiated:!0,forceChange:!1}),this.inputModelChangeSubject.next({value:this.value,highValue:this.highValue,forceChange:!1,internalChange:!0})}applyInputModelChange(e){let i=this.normaliseModelValues(e),r=!Sr.compare(e,i);r&&(this.value=i.value,this.highValue=i.highValue),this.viewLowValue=this.modelValueToViewValue(i.value),this.range?this.viewHighValue=this.modelValueToViewValue(i.highValue):this.viewHighValue=null,this.updateLowHandle(this.valueToPosition(this.viewLowValue)),this.range&&this.updateHighHandle(this.valueToPosition(this.viewHighValue)),this.updateSelectionBar(),this.updateTicksScale(),this.updateAriaAttributes(),this.range&&this.updateCombinedLabel(),this.outputModelChangeSubject.next({value:i.value,highValue:i.highValue,forceChange:r,userEventInitiated:!1})}publishOutputModelChange(e){let i=()=>{this.valueChange.emit(e.value),this.range&&this.highValueChange.emit(e.highValue),_.isNullOrUndefined(this.onChangeCallback)||(this.range?this.onChangeCallback([e.value,e.highValue]):this.onChangeCallback(e.value)),_.isNullOrUndefined(this.onTouchedCallback)||(this.range?this.onTouchedCallback([e.value,e.highValue]):this.onTouchedCallback(e.value))};e.userEventInitiated?(i(),this.userChange.emit(this.getChangeContext())):setTimeout(()=>{i()})}normaliseModelValues(e){let i=new Sr;if(i.value=e.value,i.highValue=e.highValue,!_.isNullOrUndefined(this.viewOptions.stepsArray)){if(this.viewOptions.enforceStepsArray){let r=_.findStepIndex(i.value,this.viewOptions.stepsArray);if(i.value=this.viewOptions.stepsArray[r].value,this.range){let s=_.findStepIndex(i.highValue,this.viewOptions.stepsArray);i.highValue=this.viewOptions.stepsArray[s].value}}return i}if(this.viewOptions.enforceStep&&(i.value=this.roundStep(i.value),this.range&&(i.highValue=this.roundStep(i.highValue))),this.viewOptions.enforceRange&&(i.value=ye.clampToRange(i.value,this.viewOptions.floor,this.viewOptions.ceil),this.range&&(i.highValue=ye.clampToRange(i.highValue,this.viewOptions.floor,this.viewOptions.ceil)),this.range&&e.value>e.highValue))if(this.viewOptions.noSwitching)i.value=i.highValue;else{let r=e.value;i.value=e.highValue,i.highValue=r}return i}renormaliseModelValues(){let e={value:this.value,highValue:this.highValue},i=this.normaliseModelValues(e);Sr.compare(i,e)||(this.value=i.value,this.highValue=i.highValue,this.outputModelChangeSubject.next({value:this.value,highValue:this.highValue,forceChange:!0,userEventInitiated:!1}))}onChangeOptions(){if(!this.initHasRun)return;let e=this.getOptionsInfluencingEventBindings(this.viewOptions);this.applyOptions();let i=this.getOptionsInfluencingEventBindings(this.viewOptions),r=!_.areArraysEqual(e,i);this.renormaliseModelValues(),this.viewLowValue=this.modelValueToViewValue(this.value),this.range?this.viewHighValue=this.modelValueToViewValue(this.highValue):this.viewHighValue=null,this.resetSlider(r)}applyOptions(){if(this.viewOptions=new Mr,Object.assign(this.viewOptions,this.options),this.viewOptions.draggableRange=this.range&&this.viewOptions.draggableRange,this.viewOptions.draggableRangeOnly=this.range&&this.viewOptions.draggableRangeOnly,this.viewOptions.draggableRangeOnly&&(this.viewOptions.draggableRange=!0),this.viewOptions.showTicks=this.viewOptions.showTicks||this.viewOptions.showTicksValues||!_.isNullOrUndefined(this.viewOptions.ticksArray),this.viewOptions.showTicks&&(!_.isNullOrUndefined(this.viewOptions.tickStep)||!_.isNullOrUndefined(this.viewOptions.ticksArray))&&(this.intermediateTicks=!0),this.viewOptions.showSelectionBar=this.viewOptions.showSelectionBar||this.viewOptions.showSelectionBarEnd||!_.isNullOrUndefined(this.viewOptions.showSelectionBarFromValue),_.isNullOrUndefined(this.viewOptions.stepsArray)?this.applyFloorCeilOptions():this.applyStepsArrayOptions(),_.isNullOrUndefined(this.viewOptions.combineLabels)&&(this.viewOptions.combineLabels=(e,i)=>e+" - "+i),this.viewOptions.logScale&&this.viewOptions.floor===0)throw Error("Can't use floor=0 with logarithmic scale")}applyStepsArrayOptions(){this.viewOptions.floor=0,this.viewOptions.ceil=this.viewOptions.stepsArray.length-1,this.viewOptions.step=1,_.isNullOrUndefined(this.viewOptions.translate)&&(this.viewOptions.translate=e=>this.viewOptions.bindIndexForStepsArray?String(this.getStepValue(e)):String(e))}applyFloorCeilOptions(){if(_.isNullOrUndefined(this.viewOptions.step)?this.viewOptions.step=1:(this.viewOptions.step=+this.viewOptions.step,this.viewOptions.step<=0&&(this.viewOptions.step=1)),_.isNullOrUndefined(this.viewOptions.ceil)||_.isNullOrUndefined(this.viewOptions.floor))throw Error("floor and ceil options must be supplied");this.viewOptions.ceil=+this.viewOptions.ceil,this.viewOptions.floor=+this.viewOptions.floor,_.isNullOrUndefined(this.viewOptions.translate)&&(this.viewOptions.translate=e=>String(e))}resetSlider(e=!0){this.manageElementsStyle(),this.addAccessibility(),this.updateCeilLabel(),this.updateFloorLabel(),e&&(this.unbindEvents(),this.manageEventsBindings()),this.updateDisabledState(),this.updateAriaLabel(),this.calculateViewDimensions(),this.refocusPointerIfNeeded()}focusPointer(e){e!==I.Min&&e!==I.Max&&(e=I.Min),e===I.Min?this.minHandleElement.focus():this.range&&e===I.Max&&this.maxHandleElement.focus()}refocusPointerIfNeeded(){_.isNullOrUndefined(this.currentFocusPointer)||this.getPointerElement(this.currentFocusPointer).focusIfNeeded()}manageElementsStyle(){this.updateScale(),this.floorLabelElement.setAlwaysHide(this.viewOptions.showTicksValues||this.viewOptions.hideLimitLabels),this.ceilLabelElement.setAlwaysHide(this.viewOptions.showTicksValues||this.viewOptions.hideLimitLabels);let e=this.viewOptions.showTicksValues&&!this.intermediateTicks;this.minHandleLabelElement.setAlwaysHide(e||this.viewOptions.hidePointerLabels),this.maxHandleLabelElement.setAlwaysHide(e||!this.range||this.viewOptions.hidePointerLabels),this.combinedLabelElement.setAlwaysHide(e||!this.range||this.viewOptions.hidePointerLabels),this.selectionBarElement.setAlwaysHide(!this.range&&!this.viewOptions.showSelectionBar),this.leftOuterSelectionBarElement.setAlwaysHide(!this.range||!this.viewOptions.showOuterSelectionBars),this.rightOuterSelectionBarElement.setAlwaysHide(!this.range||!this.viewOptions.showOuterSelectionBars),this.fullBarTransparentClass=this.range&&this.viewOptions.showOuterSelectionBars,this.selectionBarDraggableClass=this.viewOptions.draggableRange&&!this.viewOptions.onlyBindHandles,this.ticksUnderValuesClass=this.intermediateTicks&&this.options.showTicksValues,this.sliderElementVerticalClass!==this.viewOptions.vertical&&(this.updateVerticalState(),setTimeout(()=>{this.resetSlider()})),this.sliderElementAnimateClass!==this.viewOptions.animate&&setTimeout(()=>{this.sliderElementAnimateClass=this.viewOptions.animate}),this.updateRotate()}manageEventsBindings(){this.viewOptions.disabled||this.viewOptions.readOnly?this.unbindEvents():this.bindEvents()}updateDisabledState(){this.sliderElementDisabledAttr=this.viewOptions.disabled?"disabled":null}updateAriaLabel(){this.sliderElementAriaLabel=this.viewOptions.ariaLabel||"nxg-slider"}updateVerticalState(){this.sliderElementVerticalClass=this.viewOptions.vertical;for(let e of this.getAllSliderElements())_.isNullOrUndefined(e)||e.setVertical(this.viewOptions.vertical)}updateScale(){for(let e of this.getAllSliderElements())e.setScale(this.viewOptions.scale)}updateRotate(){for(let e of this.getAllSliderElements())e.setRotate(this.viewOptions.rotate)}getAllSliderElements(){return[this.leftOuterSelectionBarElement,this.rightOuterSelectionBarElement,this.fullBarElement,this.selectionBarElement,this.minHandleElement,this.maxHandleElement,this.floorLabelElement,this.ceilLabelElement,this.minHandleLabelElement,this.maxHandleLabelElement,this.combinedLabelElement,this.ticksElement]}initHandles(){this.updateLowHandle(this.valueToPosition(this.viewLowValue)),this.range&&this.updateHighHandle(this.valueToPosition(this.viewHighValue)),this.updateSelectionBar(),this.range&&this.updateCombinedLabel(),this.updateTicksScale()}addAccessibility(){this.updateAriaAttributes(),this.minHandleElement.role="slider",this.viewOptions.keyboardSupport&&!(this.viewOptions.readOnly||this.viewOptions.disabled)?this.minHandleElement.tabindex="0":this.minHandleElement.tabindex="",this.minHandleElement.ariaOrientation=this.viewOptions.vertical||this.viewOptions.rotate!==0?"vertical":"horizontal",_.isNullOrUndefined(this.viewOptions.ariaLabel)?_.isNullOrUndefined(this.viewOptions.ariaLabelledBy)||(this.minHandleElement.ariaLabelledBy=this.viewOptions.ariaLabelledBy):this.minHandleElement.ariaLabel=this.viewOptions.ariaLabel,this.range&&(this.maxHandleElement.role="slider",this.viewOptions.keyboardSupport&&!(this.viewOptions.readOnly||this.viewOptions.disabled)?this.maxHandleElement.tabindex="0":this.maxHandleElement.tabindex="",this.maxHandleElement.ariaOrientation=this.viewOptions.vertical||this.viewOptions.rotate!==0?"vertical":"horizontal",_.isNullOrUndefined(this.viewOptions.ariaLabelHigh)?_.isNullOrUndefined(this.viewOptions.ariaLabelledByHigh)||(this.maxHandleElement.ariaLabelledBy=this.viewOptions.ariaLabelledByHigh):this.maxHandleElement.ariaLabel=this.viewOptions.ariaLabelHigh)}updateAriaAttributes(){this.minHandleElement.ariaValueNow=(+this.value).toString(),this.minHandleElement.ariaValueText=this.viewOptions.translate(+this.value,Zt.Low),this.minHandleElement.ariaValueMin=this.viewOptions.floor.toString(),this.minHandleElement.ariaValueMax=this.viewOptions.ceil.toString(),this.range&&(this.maxHandleElement.ariaValueNow=(+this.highValue).toString(),this.maxHandleElement.ariaValueText=this.viewOptions.translate(+this.highValue,Zt.High),this.maxHandleElement.ariaValueMin=this.viewOptions.floor.toString(),this.maxHandleElement.ariaValueMax=this.viewOptions.ceil.toString())}calculateViewDimensions(){_.isNullOrUndefined(this.viewOptions.handleDimension)?this.minHandleElement.calculateDimension():this.minHandleElement.setDimension(this.viewOptions.handleDimension);let e=this.minHandleElement.dimension;this.handleHalfDimension=e/2,_.isNullOrUndefined(this.viewOptions.barDimension)?this.fullBarElement.calculateDimension():this.fullBarElement.setDimension(this.viewOptions.barDimension),this.maxHandlePosition=this.fullBarElement.dimension-e,this.initHasRun&&(this.updateFloorLabel(),this.updateCeilLabel(),this.initHandles())}calculateViewDimensionsAndDetectChanges(){this.calculateViewDimensions(),this.isRefDestroyed()||this.changeDetectionRef.detectChanges()}isRefDestroyed(){return this.changeDetectionRef.destroyed}updateTicksScale(){if(!this.viewOptions.showTicks&&this.sliderElementWithLegendClass){setTimeout(()=>{this.sliderElementWithLegendClass=!1});return}let e=_.isNullOrUndefined(this.viewOptions.ticksArray)?this.getTicksArray():this.viewOptions.ticksArray,i=this.viewOptions.vertical?"translateY":"translateX";this.viewOptions.rightToLeft&&e.reverse();let r=_.isNullOrUndefined(this.viewOptions.tickValueStep)?_.isNullOrUndefined(this.viewOptions.tickStep)?this.viewOptions.step:this.viewOptions.tickStep:this.viewOptions.tickValueStep,s=!1,o=e.map(a=>{let l=this.valueToPosition(a);this.viewOptions.vertical&&(l=this.maxHandlePosition-l);let c=i+"("+Math.round(l)+"px)",u=new Kh;u.selected=this.isTickSelected(a),u.style={"-webkit-transform":c,"-moz-transform":c,"-o-transform":c,"-ms-transform":c,transform:c},u.selected&&!_.isNullOrUndefined(this.viewOptions.getSelectionBarColor)&&(u.style["background-color"]=this.getSelectionBarColor()),!u.selected&&!_.isNullOrUndefined(this.viewOptions.getTickColor)&&(u.style["background-color"]=this.getTickColor(a)),_.isNullOrUndefined(this.viewOptions.ticksTooltip)||(u.tooltip=this.viewOptions.ticksTooltip(a),u.tooltipPlacement=this.viewOptions.vertical?"right":"top"),this.viewOptions.showTicksValues&&!_.isNullOrUndefined(r)&&ye.isModuloWithinPrecisionLimit(a,r,this.viewOptions.precisionLimit)&&(u.value=this.getDisplayValue(a,Zt.TickValue),_.isNullOrUndefined(this.viewOptions.ticksValuesTooltip)||(u.valueTooltip=this.viewOptions.ticksValuesTooltip(a),u.valueTooltipPlacement=this.viewOptions.vertical?"right":"top"));let d=null;if(_.isNullOrUndefined(this.viewOptions.stepsArray))_.isNullOrUndefined(this.viewOptions.getLegend)||(d=this.viewOptions.getLegend(a));else{let h=this.viewOptions.stepsArray[a];_.isNullOrUndefined(this.viewOptions.getStepLegend)?_.isNullOrUndefined(h)||(d=h.legend):d=this.viewOptions.getStepLegend(h)}return _.isNullOrUndefined(d)||(u.legend=d,s=!0),u});if(this.sliderElementWithLegendClass!==s&&setTimeout(()=>{this.sliderElementWithLegendClass=s}),!_.isNullOrUndefined(this.ticks)&&this.ticks.length===o.length)for(let a=0;a=this.viewLowValue)return!0}else if(this.viewOptions.showSelectionBar&&e<=this.viewLowValue)return!0}else{let i=this.viewOptions.showSelectionBarFromValue;if(this.viewLowValue>i&&e>=i&&e<=this.viewLowValue)return!0;if(this.viewLowValue=this.viewLowValue)return!0}return!!(this.range&&e>=this.viewLowValue&&e<=this.viewHighValue)}updateFloorLabel(){if(!this.floorLabelElement.alwaysHide){this.floorLabelElement.setValue(this.getDisplayValue(this.viewOptions.floor,Zt.Floor)),this.floorLabelElement.calculateDimension();let e=this.viewOptions.rightToLeft?this.fullBarElement.dimension-this.floorLabelElement.dimension:0;this.floorLabelElement.setPosition(e)}}updateCeilLabel(){if(!this.ceilLabelElement.alwaysHide){this.ceilLabelElement.setValue(this.getDisplayValue(this.viewOptions.ceil,Zt.Ceil)),this.ceilLabelElement.calculateDimension();let e=this.viewOptions.rightToLeft?0:this.fullBarElement.dimension-this.ceilLabelElement.dimension;this.ceilLabelElement.setPosition(e)}}updateHandles(e,i){e===I.Min?this.updateLowHandle(i):e===I.Max&&this.updateHighHandle(i),this.updateSelectionBar(),this.updateTicksScale(),this.range&&this.updateCombinedLabel()}getHandleLabelPos(e,i){let r=e===I.Min?this.minHandleLabelElement.dimension:this.maxHandleLabelElement.dimension,s=i-r/2+this.handleHalfDimension,o=this.fullBarElement.dimension-r;return this.viewOptions.boundPointerLabels?this.viewOptions.rightToLeft&&e===I.Min||!this.viewOptions.rightToLeft&&e===I.Max?Math.min(s,o):Math.min(Math.max(s,0),o):s}updateLowHandle(e){this.minHandleElement.setPosition(e),this.minHandleLabelElement.setValue(this.getDisplayValue(this.viewLowValue,Zt.Low)),this.minHandleLabelElement.setPosition(this.getHandleLabelPos(I.Min,e)),_.isNullOrUndefined(this.viewOptions.getPointerColor)||(this.minPointerStyle={backgroundColor:this.getPointerColor(I.Min)}),this.viewOptions.autoHideLimitLabels&&this.updateFloorAndCeilLabelsVisibility()}updateHighHandle(e){this.maxHandleElement.setPosition(e),this.maxHandleLabelElement.setValue(this.getDisplayValue(this.viewHighValue,Zt.High)),this.maxHandleLabelElement.setPosition(this.getHandleLabelPos(I.Max,e)),_.isNullOrUndefined(this.viewOptions.getPointerColor)||(this.maxPointerStyle={backgroundColor:this.getPointerColor(I.Max)}),this.viewOptions.autoHideLimitLabels&&this.updateFloorAndCeilLabelsVisibility()}updateFloorAndCeilLabelsVisibility(){if(this.viewOptions.hidePointerLabels)return;let e=!1,i=!1,r=this.isLabelBelowFloorLabel(this.minHandleLabelElement),s=this.isLabelAboveCeilLabel(this.minHandleLabelElement),o=this.isLabelAboveCeilLabel(this.maxHandleLabelElement),a=this.isLabelBelowFloorLabel(this.combinedLabelElement),l=this.isLabelAboveCeilLabel(this.combinedLabelElement);if(r?(e=!0,this.floorLabelElement.hide()):(e=!1,this.floorLabelElement.show()),s?(i=!0,this.ceilLabelElement.hide()):(i=!1,this.ceilLabelElement.show()),this.range){let c=this.combinedLabelElement.isVisible()?l:o,u=this.combinedLabelElement.isVisible()?a:r;c?this.ceilLabelElement.hide():i||this.ceilLabelElement.show(),u?this.floorLabelElement.hide():e||this.floorLabelElement.show()}}isLabelBelowFloorLabel(e){let i=e.position,r=e.dimension,s=this.floorLabelElement.position,o=this.floorLabelElement.dimension;return this.viewOptions.rightToLeft?i+r>=s-2:i<=s+o+2}isLabelAboveCeilLabel(e){let i=e.position,r=e.dimension,s=this.ceilLabelElement.position,o=this.ceilLabelElement.dimension;return this.viewOptions.rightToLeft?i<=s+o+2:i+r>=s-2}updateSelectionBar(){let e=0,i=0,r=this.viewOptions.rightToLeft?!this.viewOptions.showSelectionBarEnd:this.viewOptions.showSelectionBarEnd,s=this.viewOptions.rightToLeft?this.maxHandleElement.position+this.handleHalfDimension:this.minHandleElement.position+this.handleHalfDimension;if(this.range)i=Math.abs(this.maxHandleElement.position-this.minHandleElement.position),e=s;else if(_.isNullOrUndefined(this.viewOptions.showSelectionBarFromValue))r?(i=Math.ceil(Math.abs(this.maxHandlePosition-this.minHandleElement.position)+this.handleHalfDimension),e=Math.floor(this.minHandleElement.position+this.handleHalfDimension)):(i=this.minHandleElement.position+this.handleHalfDimension,e=0);else{let o=this.viewOptions.showSelectionBarFromValue,a=this.valueToPosition(o);(this.viewOptions.rightToLeft?this.viewLowValue<=o:this.viewLowValue>o)?(i=this.minHandleElement.position-a,e=a+this.handleHalfDimension):(i=a-this.minHandleElement.position,e=this.minHandleElement.position+this.handleHalfDimension)}if(this.selectionBarElement.setDimension(i),this.selectionBarElement.setPosition(e),this.range&&this.viewOptions.showOuterSelectionBars&&(this.viewOptions.rightToLeft?(this.rightOuterSelectionBarElement.setDimension(e),this.rightOuterSelectionBarElement.setPosition(0),this.fullBarElement.calculateDimension(),this.leftOuterSelectionBarElement.setDimension(this.fullBarElement.dimension-(e+i)),this.leftOuterSelectionBarElement.setPosition(e+i)):(this.leftOuterSelectionBarElement.setDimension(e),this.leftOuterSelectionBarElement.setPosition(0),this.fullBarElement.calculateDimension(),this.rightOuterSelectionBarElement.setDimension(this.fullBarElement.dimension-(e+i)),this.rightOuterSelectionBarElement.setPosition(e+i))),_.isNullOrUndefined(this.viewOptions.getSelectionBarColor)){if(!_.isNullOrUndefined(this.viewOptions.selectionBarGradient)){let o=_.isNullOrUndefined(this.viewOptions.showSelectionBarFromValue)?0:this.valueToPosition(this.viewOptions.showSelectionBarFromValue),a=o-e>0&&!r||o-e<=0&&r,l=this.viewOptions.vertical?a?"bottom":"top":a?"left":"right";this.barStyle={backgroundImage:"linear-gradient(to "+l+", "+this.viewOptions.selectionBarGradient.from+" 0%,"+this.viewOptions.selectionBarGradient.to+" 100%)"},this.viewOptions.vertical?(this.barStyle.backgroundPosition="center "+(o+i+e+(a?-this.handleHalfDimension:0))+"px",this.barStyle.backgroundSize="100% "+(this.fullBarElement.dimension-this.handleHalfDimension)+"px"):(this.barStyle.backgroundPosition=o-e+(a?this.handleHalfDimension:0)+"px center",this.barStyle.backgroundSize=this.fullBarElement.dimension-this.handleHalfDimension+"px 100%")}}else{let o=this.getSelectionBarColor();this.barStyle={backgroundColor:o}}}getSelectionBarColor(){return this.range?this.viewOptions.getSelectionBarColor(this.value,this.highValue):this.viewOptions.getSelectionBarColor(this.value)}getPointerColor(e){return e===I.Max?this.viewOptions.getPointerColor(this.highValue,e):this.viewOptions.getPointerColor(this.value,e)}getTickColor(e){return this.viewOptions.getTickColor(e)}updateCombinedLabel(){let e=null;if(this.viewOptions.rightToLeft?e=this.minHandleLabelElement.position-this.minHandleLabelElement.dimension-10<=this.maxHandleLabelElement.position:e=this.minHandleLabelElement.position+this.minHandleLabelElement.dimension+10>=this.maxHandleLabelElement.position,e){let i=this.getDisplayValue(this.viewLowValue,Zt.Low),r=this.getDisplayValue(this.viewHighValue,Zt.High),s=this.viewOptions.rightToLeft?this.viewOptions.combineLabels(r,i):this.viewOptions.combineLabels(i,r);this.combinedLabelElement.setValue(s);let o=this.viewOptions.boundPointerLabels?Math.min(Math.max(this.selectionBarElement.position+this.selectionBarElement.dimension/2-this.combinedLabelElement.dimension/2,0),this.fullBarElement.dimension-this.combinedLabelElement.dimension):this.selectionBarElement.position+this.selectionBarElement.dimension/2-this.combinedLabelElement.dimension/2;this.combinedLabelElement.setPosition(o),this.minHandleLabelElement.hide(),this.maxHandleLabelElement.hide(),this.combinedLabelElement.show()}else this.updateHighHandle(this.valueToPosition(this.viewHighValue)),this.updateLowHandle(this.valueToPosition(this.viewLowValue)),this.maxHandleLabelElement.show(),this.minHandleLabelElement.show(),this.combinedLabelElement.hide();this.viewOptions.autoHideLimitLabels&&this.updateFloorAndCeilLabelsVisibility()}getDisplayValue(e,i){return!_.isNullOrUndefined(this.viewOptions.stepsArray)&&!this.viewOptions.bindIndexForStepsArray&&(e=this.getStepValue(e)),this.viewOptions.translate(e,i)}roundStep(e,i){let r=_.isNullOrUndefined(i)?this.viewOptions.step:i,s=ye.roundToPrecisionLimit((e-this.viewOptions.floor)/r,this.viewOptions.precisionLimit);return s=Math.round(s)*r,ye.roundToPrecisionLimit(this.viewOptions.floor+s,this.viewOptions.precisionLimit)}valueToPosition(e){let i=_.linearValueToPosition;_.isNullOrUndefined(this.viewOptions.customValueToPosition)?this.viewOptions.logScale&&(i=_.logValueToPosition):i=this.viewOptions.customValueToPosition,e=ye.clampToRange(e,this.viewOptions.floor,this.viewOptions.ceil);let r=i(e,this.viewOptions.floor,this.viewOptions.ceil);return _.isNullOrUndefined(r)&&(r=0),this.viewOptions.rightToLeft&&(r=1-r),r*this.maxHandlePosition}positionToValue(e){let i=e/this.maxHandlePosition;this.viewOptions.rightToLeft&&(i=1-i);let r=_.linearPositionToValue;_.isNullOrUndefined(this.viewOptions.customPositionToValue)?this.viewOptions.logScale&&(r=_.logPositionToValue):r=this.viewOptions.customPositionToValue;let s=r(i,this.viewOptions.floor,this.viewOptions.ceil);return _.isNullOrUndefined(s)?0:s}getEventXY(e,i){if(e instanceof MouseEvent)return this.viewOptions.vertical||this.viewOptions.rotate!==0?e.clientY:e.clientX;let r=0,s=e.touches;if(!_.isNullOrUndefined(i)){for(let o=0;os?I.Max:this.viewOptions.rightToLeft?i>this.minHandleElement.position?I.Min:I.Max:ithis.onBarStart(null,e,i,!0,!0,!0)),this.viewOptions.draggableRangeOnly?(this.minHandleElement.on("mousedown",i=>this.onBarStart(I.Min,e,i,!0,!0)),this.maxHandleElement.on("mousedown",i=>this.onBarStart(I.Max,e,i,!0,!0))):(this.minHandleElement.on("mousedown",i=>this.onStart(I.Min,i,!0,!0)),this.range&&this.maxHandleElement.on("mousedown",i=>this.onStart(I.Max,i,!0,!0)),this.viewOptions.onlyBindHandles||(this.fullBarElement.on("mousedown",i=>this.onStart(null,i,!0,!0,!0)),this.ticksElement.on("mousedown",i=>this.onStart(null,i,!0,!0,!0,!0)))),this.viewOptions.onlyBindHandles||this.selectionBarElement.onPassive("touchstart",i=>this.onBarStart(null,e,i,!0,!0,!0)),this.viewOptions.draggableRangeOnly?(this.minHandleElement.onPassive("touchstart",i=>this.onBarStart(I.Min,e,i,!0,!0)),this.maxHandleElement.onPassive("touchstart",i=>this.onBarStart(I.Max,e,i,!0,!0))):(this.minHandleElement.onPassive("touchstart",i=>this.onStart(I.Min,i,!0,!0)),this.range&&this.maxHandleElement.onPassive("touchstart",i=>this.onStart(I.Max,i,!0,!0)),this.viewOptions.onlyBindHandles||(this.fullBarElement.onPassive("touchstart",i=>this.onStart(null,i,!0,!0,!0)),this.ticksElement.onPassive("touchstart",i=>this.onStart(null,i,!1,!1,!0,!0)))),this.viewOptions.keyboardSupport&&(this.minHandleElement.on("focus",()=>this.onPointerFocus(I.Min)),this.range&&this.maxHandleElement.on("focus",()=>this.onPointerFocus(I.Max)))}getOptionsInfluencingEventBindings(e){return[e.disabled,e.readOnly,e.draggableRange,e.draggableRangeOnly,e.onlyBindHandles,e.keyboardSupport]}unbindEvents(){this.unsubscribeOnMove(),this.unsubscribeOnEnd();for(let e of this.getAllSliderElements())_.isNullOrUndefined(e)||e.off()}onBarStart(e,i,r,s,o,a,l){i?this.onDragStart(e,r,s,o):this.onStart(e,r,s,o,a,l)}onStart(e,i,r,s,o,a){i.stopPropagation(),!Qt.isTouchEvent(i)&&!Dl&&i.preventDefault(),this.moving=!1,this.calculateViewDimensions(),_.isNullOrUndefined(e)&&(e=this.getNearestHandle(i)),this.currentTrackingPointer=e;let l=this.getPointerElement(e);if(l.active=!0,this.viewOptions.keyboardSupport&&l.focus(),r){this.unsubscribeOnMove();let c=u=>this.dragging.active?this.onDragMove(u):this.onMove(u);Qt.isTouchEvent(i)?this.onMoveEventListener=this.eventListenerHelper.attachPassiveEventListener(document,"touchmove",c):this.onMoveEventListener=this.eventListenerHelper.attachEventListener(document,"mousemove",c)}if(s){this.unsubscribeOnEnd();let c=u=>this.onEnd(u);Qt.isTouchEvent(i)?this.onEndEventListener=this.eventListenerHelper.attachPassiveEventListener(document,"touchend",c):this.onEndEventListener=this.eventListenerHelper.attachEventListener(document,"mouseup",c)}this.userChangeStart.emit(this.getChangeContext()),Qt.isTouchEvent(i)&&!_.isNullOrUndefined(i.changedTouches)&&_.isNullOrUndefined(this.touchId)&&(this.touchId=i.changedTouches[0].identifier),o&&this.onMove(i,!0),a&&this.onEnd(i)}onMove(e,i){let r=null;if(Qt.isTouchEvent(e)){let c=e.changedTouches;for(let u=0;u=this.maxHandlePosition?o=a:(o=this.positionToValue(s),i&&!_.isNullOrUndefined(this.viewOptions.tickStep)?o=this.roundStep(o,this.viewOptions.tickStep):o=this.roundStep(o)),this.positionTrackingHandle(o)}onEnd(e){Qt.isTouchEvent(e)&&e.changedTouches[0].identifier!==this.touchId||(this.moving=!1,this.viewOptions.animate&&(this.sliderElementAnimateClass=!0),this.touchId=null,this.viewOptions.keyboardSupport||(this.minHandleElement.active=!1,this.maxHandleElement.active=!1,this.currentTrackingPointer=null),this.dragging.active=!1,this.unsubscribeOnMove(),this.unsubscribeOnEnd(),this.userChangeEnd.emit(this.getChangeContext()))}onPointerFocus(e){let i=this.getPointerElement(e);i.on("blur",()=>this.onPointerBlur(i)),i.on("keydown",r=>this.onKeyboardEvent(r)),i.on("keyup",()=>this.onKeyUp()),i.active=!0,this.currentTrackingPointer=e,this.currentFocusPointer=e,this.firstKeyDown=!0}onKeyUp(){this.firstKeyDown=!0,this.userChangeEnd.emit(this.getChangeContext())}onPointerBlur(e){e.off("blur"),e.off("keydown"),e.off("keyup"),e.active=!1,_.isNullOrUndefined(this.touchId)&&(this.currentTrackingPointer=null,this.currentFocusPointer=null)}getKeyActions(e){let i=this.viewOptions.ceil-this.viewOptions.floor,r=e+this.viewOptions.step,s=e-this.viewOptions.step,o=e+i/10,a=e-i/10;this.viewOptions.reversedControls&&(r=e-this.viewOptions.step,s=e+this.viewOptions.step,o=e-i/10,a=e+i/10);let l={UP:r,DOWN:s,LEFT:s,RIGHT:r,PAGEUP:o,PAGEDOWN:a,HOME:this.viewOptions.reversedControls?this.viewOptions.ceil:this.viewOptions.floor,END:this.viewOptions.reversedControls?this.viewOptions.floor:this.viewOptions.ceil};return this.viewOptions.rightToLeft&&(l.LEFT=r,l.RIGHT=s,(this.viewOptions.vertical||this.viewOptions.rotate!==0)&&(l.UP=s,l.DOWN=r)),l}onKeyboardEvent(e){let i=this.getCurrentTrackingValue(),r=_.isNullOrUndefined(e.keyCode)?e.which:e.keyCode,s={38:"UP",40:"DOWN",37:"LEFT",39:"RIGHT",33:"PAGEUP",34:"PAGEDOWN",36:"HOME",35:"END"},o=this.getKeyActions(i),a=s[r],l=o[a];if(_.isNullOrUndefined(l)||_.isNullOrUndefined(this.currentTrackingPointer))return;e.preventDefault(),this.firstKeyDown&&(this.firstKeyDown=!1,this.userChangeStart.emit(this.getChangeContext()));let c=ye.clampToRange(l,this.viewOptions.floor,this.viewOptions.ceil),u=this.roundStep(c);if(!this.viewOptions.draggableRangeOnly)this.positionTrackingHandle(u);else{let d=this.viewHighValue-this.viewLowValue,h,f;this.currentTrackingPointer===I.Min?(h=u,f=u+d,f>this.viewOptions.ceil&&(f=this.viewOptions.ceil,h=f-d)):this.currentTrackingPointer===I.Max&&(f=u,h=u-d,h=this.maxHandlePosition-r,u,d;if(l){if(o.position===0)return;u=this.getMinValue(i,!0,!1),d=this.getMaxValue(i,!0,!1)}else if(c){if(a.position===this.maxHandlePosition)return;d=this.getMaxValue(i,!0,!0),u=this.getMinValue(i,!0,!0)}else u=this.getMinValue(i,!1,!1),d=this.getMaxValue(i,!1,!1);this.positionTrackingBar(u,d)}positionTrackingBar(e,i){!_.isNullOrUndefined(this.viewOptions.minLimit)&&ethis.viewOptions.maxLimit&&(i=this.viewOptions.maxLimit,e=ye.roundToPrecisionLimit(i-this.dragging.difference,this.viewOptions.precisionLimit)),this.viewLowValue=e,this.viewHighValue=i,this.applyViewChange(),this.updateHandles(I.Min,this.valueToPosition(e)),this.updateHandles(I.Max,this.valueToPosition(i))}positionTrackingHandle(e){e=this.applyMinMaxLimit(e),this.range&&(this.viewOptions.pushRange?e=this.applyPushRange(e):(this.viewOptions.noSwitching&&(this.currentTrackingPointer===I.Min&&e>this.viewHighValue?e=this.applyMinMaxRange(this.viewHighValue):this.currentTrackingPointer===I.Max&&ethis.viewHighValue?(this.viewLowValue=this.viewHighValue,this.applyViewChange(),this.updateHandles(I.Min,this.maxHandleElement.position),this.updateAriaAttributes(),this.currentTrackingPointer=I.Max,this.minHandleElement.active=!1,this.maxHandleElement.active=!0,this.viewOptions.keyboardSupport&&this.maxHandleElement.focus()):this.currentTrackingPointer===I.Max&&ethis.viewOptions.maxLimit?this.viewOptions.maxLimit:e}applyMinMaxRange(e){let i=this.currentTrackingPointer===I.Min?this.viewHighValue:this.viewLowValue,r=Math.abs(e-i);if(!_.isNullOrUndefined(this.viewOptions.minRange)&&rthis.viewOptions.maxRange){if(this.currentTrackingPointer===I.Min)return ye.roundToPrecisionLimit(this.viewHighValue-this.viewOptions.maxRange,this.viewOptions.precisionLimit);if(this.currentTrackingPointer===I.Max)return ye.roundToPrecisionLimit(this.viewLowValue+this.viewOptions.maxRange,this.viewOptions.precisionLimit)}return e}applyPushRange(e){let i=this.currentTrackingPointer===I.Min?this.viewHighValue-e:e-this.viewLowValue,r=_.isNullOrUndefined(this.viewOptions.minRange)?this.viewOptions.step:this.viewOptions.minRange,s=this.viewOptions.maxRange;return is&&(this.currentTrackingPointer===I.Min?(this.viewHighValue=ye.roundToPrecisionLimit(e+s,this.viewOptions.precisionLimit),this.applyViewChange(),this.updateHandles(I.Max,this.valueToPosition(this.viewHighValue))):this.currentTrackingPointer===I.Max&&(this.viewLowValue=ye.roundToPrecisionLimit(e-s,this.viewOptions.precisionLimit),this.applyViewChange(),this.updateHandles(I.Min,this.valueToPosition(this.viewLowValue))),this.updateAriaAttributes()),e}getChangeContext(){let e=new Qh;return e.pointerType=this.currentTrackingPointer,e.value=+this.value,this.range&&(e.highValue=+this.highValue),e}static \u0275fac=function(i){return new(i||t)(Q(_t),Q(We),Q(Pt),Q(ue),Q(Ml,8))};static \u0275cmp=Fe({type:t,selectors:[["ngx-slider"]],contentQueries:function(i,r,s){if(i&1&&mh(s,MO,5),i&2){let o;Ve(o=je())&&(r.tooltipTemplate=o.first)}},viewQuery:function(i,r){if(i&1&&(Qe(SO,5,$n),Qe(IO,5,$n),Qe(OO,5,$n),Qe(TO,5,$n),Qe(AO,5,Zh),Qe(NO,5,Zh),Qe(RO,5,Er),Qe(kO,5,Er),Qe(PO,5,Er),Qe(LO,5,Er),Qe(FO,5,Er),Qe(VO,5,$n)),i&2){let s;Ve(s=je())&&(r.leftOuterSelectionBarElement=s.first),Ve(s=je())&&(r.rightOuterSelectionBarElement=s.first),Ve(s=je())&&(r.fullBarElement=s.first),Ve(s=je())&&(r.selectionBarElement=s.first),Ve(s=je())&&(r.minHandleElement=s.first),Ve(s=je())&&(r.maxHandleElement=s.first),Ve(s=je())&&(r.floorLabelElement=s.first),Ve(s=je())&&(r.ceilLabelElement=s.first),Ve(s=je())&&(r.minHandleLabelElement=s.first),Ve(s=je())&&(r.maxHandleLabelElement=s.first),Ve(s=je())&&(r.combinedLabelElement=s.first),Ve(s=je())&&(r.ticksElement=s.first)}},hostVars:10,hostBindings:function(i,r){i&1&&xe("resize",function(o){return r.onResize(o)},!1,ty),i&2&&(wr("disabled",r.sliderElementDisabledAttr)("aria-label",r.sliderElementAriaLabel),Ei("ngx-slider",r.sliderElementNgxSliderClass)("vertical",r.sliderElementVerticalClass)("animate",r.sliderElementAnimateClass)("with-legend",r.sliderElementWithLegendClass))},inputs:{value:"value",highValue:"highValue",options:"options",manualRefresh:"manualRefresh",triggerFocus:"triggerFocus"},outputs:{valueChange:"valueChange",highValueChange:"highValueChange",userChangeStart:"userChangeStart",userChange:"userChange",userChangeEnd:"userChangeEnd"},features:[qy([WO]),Rt],decls:29,vars:13,consts:[["leftOuterSelectionBar",""],["rightOuterSelectionBar",""],["fullBar",""],["selectionBar",""],["minHandle",""],["maxHandle",""],["floorLabel",""],["ceilLabel",""],["minHandleLabel",""],["maxHandleLabel",""],["combinedLabel",""],["ticksElement",""],["ngxSliderElement","",1,"ngx-slider-span","ngx-slider-bar-wrapper","ngx-slider-left-out-selection"],[1,"ngx-slider-span","ngx-slider-bar"],["ngxSliderElement","",1,"ngx-slider-span","ngx-slider-bar-wrapper","ngx-slider-right-out-selection"],["ngxSliderElement","",1,"ngx-slider-span","ngx-slider-bar-wrapper","ngx-slider-full-bar"],["ngxSliderElement","",1,"ngx-slider-span","ngx-slider-bar-wrapper","ngx-slider-selection-bar"],[1,"ngx-slider-span","ngx-slider-bar","ngx-slider-selection",3,"ngStyle"],["ngxSliderHandle","",1,"ngx-slider-span","ngx-slider-pointer","ngx-slider-pointer-min",3,"ngStyle"],["ngxSliderHandle","",1,"ngx-slider-span","ngx-slider-pointer","ngx-slider-pointer-max",3,"ngStyle"],["ngxSliderLabel","",1,"ngx-slider-span","ngx-slider-bubble","ngx-slider-limit","ngx-slider-floor"],["ngxSliderLabel","",1,"ngx-slider-span","ngx-slider-bubble","ngx-slider-limit","ngx-slider-ceil"],["ngxSliderLabel","",1,"ngx-slider-span","ngx-slider-bubble","ngx-slider-model-value"],["ngxSliderLabel","",1,"ngx-slider-span","ngx-slider-bubble","ngx-slider-model-high"],["ngxSliderLabel","",1,"ngx-slider-span","ngx-slider-bubble","ngx-slider-combined"],["ngxSliderElement","",1,"ngx-slider-ticks",3,"hidden"],["class","ngx-slider-tick",3,"ngClass","ngStyle",4,"ngFor","ngForOf"],[1,"ngx-slider-tick",3,"ngClass","ngStyle"],[3,"template","tooltip","placement"],["class","ngx-slider-span ngx-slider-tick-value",3,"template","tooltip","placement","content",4,"ngIf"],["class","ngx-slider-span ngx-slider-tick-legend",3,"innerText",4,"ngIf"],["class","ngx-slider-span ngx-slider-tick-legend",3,"innerHTML",4,"ngIf"],[1,"ngx-slider-span","ngx-slider-tick-value",3,"template","tooltip","placement","content"],[1,"ngx-slider-span","ngx-slider-tick-legend",3,"innerText"],[1,"ngx-slider-span","ngx-slider-tick-legend",3,"innerHTML"]],template:function(i,r){i&1&&(L(0,"span",12,0),le(2,"span",13),j(),L(3,"span",14,1),le(5,"span",13),j(),L(6,"span",15,2),le(8,"span",13),j(),L(9,"span",16,3),le(11,"span",17),j(),le(12,"span",18,4)(14,"span",19,5)(16,"span",20,6)(18,"span",21,7)(20,"span",22,8)(22,"span",23,9)(24,"span",24,10),L(26,"span",25,11),gn(28,$O,5,10,"span",26),j()),i&2&&(q(6),Ei("ngx-slider-transparent",r.fullBarTransparentClass),q(3),Ei("ngx-slider-draggable",r.selectionBarDraggableClass),q(2),Y("ngStyle",r.barStyle),q(),Y("ngStyle",r.minPointerStyle),q(2),Cs("display",r.range?"inherit":"none"),Y("ngStyle",r.maxPointerStyle),q(12),Ei("ngx-slider-ticks-values-under",r.ticksUnderValuesClass),Y("hidden",!r.showTicks),q(2),Y("ngForOf",r.ticks))},dependencies:[ml,_b,Is,Cb,$n,Zh,Er,zO],styles:['.ngx-slider{display:inline-block;position:relative;height:4px;width:100%;margin:35px 0 15px;vertical-align:middle;-webkit-user-select:none;user-select:none;touch-action:pan-y} .ngx-slider.with-legend{margin-bottom:40px} .ngx-slider[disabled]{cursor:not-allowed} .ngx-slider[disabled] .ngx-slider-pointer{cursor:not-allowed;background-color:#d8e0f3} .ngx-slider[disabled] .ngx-slider-draggable{cursor:not-allowed} .ngx-slider[disabled] .ngx-slider-selection{background:#8b91a2} .ngx-slider[disabled] .ngx-slider-tick{cursor:not-allowed} .ngx-slider[disabled] .ngx-slider-tick.ngx-slider-selected{background:#8b91a2} .ngx-slider .ngx-slider-span{white-space:nowrap;position:absolute;display:inline-block} .ngx-slider .ngx-slider-base{width:100%;height:100%;padding:0} .ngx-slider .ngx-slider-bar-wrapper{left:0;box-sizing:border-box;margin-top:-16px;padding-top:16px;width:100%;height:32px;z-index:1} .ngx-slider .ngx-slider-draggable{cursor:move} .ngx-slider .ngx-slider-bar{left:0;width:100%;height:4px;z-index:1;background:#d8e0f3;-webkit-border-radius:2px;-moz-border-radius:2px;border-radius:2px} .ngx-slider .ngx-slider-bar-wrapper.ngx-slider-transparent .ngx-slider-bar{background:transparent} .ngx-slider .ngx-slider-bar-wrapper.ngx-slider-left-out-selection .ngx-slider-bar{background:#df002d} .ngx-slider .ngx-slider-bar-wrapper.ngx-slider-right-out-selection .ngx-slider-bar{background:#03a688} .ngx-slider .ngx-slider-selection{z-index:2;background:#0db9f0;-webkit-border-radius:2px;-moz-border-radius:2px;border-radius:2px} .ngx-slider .ngx-slider-pointer{cursor:pointer;width:32px;height:32px;top:-14px;background-color:#0db9f0;z-index:3;-webkit-border-radius:16px;-moz-border-radius:16px;border-radius:16px} .ngx-slider .ngx-slider-pointer:after{content:"";width:8px;height:8px;position:absolute;top:12px;left:12px;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px;background:#fff} .ngx-slider .ngx-slider-pointer:hover:after{background-color:#fff} .ngx-slider .ngx-slider-pointer.ngx-slider-active{z-index:4} .ngx-slider .ngx-slider-pointer.ngx-slider-active:after{background-color:#451aff} .ngx-slider .ngx-slider-bubble{cursor:default;bottom:16px;padding:1px 3px;color:#55637d;font-size:16px} .ngx-slider .ngx-slider-bubble.ngx-slider-limit{color:#55637d} .ngx-slider .ngx-slider-ticks{box-sizing:border-box;width:100%;height:0;position:absolute;left:0;top:-3px;margin:0;z-index:1;list-style:none} .ngx-slider .ngx-slider-ticks-values-under .ngx-slider-tick-value{top:auto;bottom:-36px} .ngx-slider .ngx-slider-tick{text-align:center;cursor:pointer;width:10px;height:10px;background:#d8e0f3;border-radius:50%;position:absolute;top:0;left:0;margin-left:11px} .ngx-slider .ngx-slider-tick.ngx-slider-selected{background:#0db9f0} .ngx-slider .ngx-slider-tick-value{position:absolute;top:-34px;transform:translate(-50%)} .ngx-slider .ngx-slider-tick-legend{position:absolute;top:24px;transform:translate(-50%);max-width:50px;white-space:normal} .ngx-slider.vertical{position:relative;width:4px;height:100%;margin:0 20px;padding:0;vertical-align:baseline;touch-action:pan-x} .ngx-slider.vertical .ngx-slider-base{width:100%;height:100%;padding:0} .ngx-slider.vertical .ngx-slider-bar-wrapper{top:auto;left:0;margin:0 0 0 -16px;padding:0 0 0 16px;height:100%;width:32px} .ngx-slider.vertical .ngx-slider-bar{bottom:0;left:auto;width:4px;height:100%} .ngx-slider.vertical .ngx-slider-pointer{left:-14px!important;top:auto;bottom:0} .ngx-slider.vertical .ngx-slider-bubble{left:16px!important;bottom:0} .ngx-slider.vertical .ngx-slider-ticks{height:100%;width:0;left:-3px;top:0;z-index:1} .ngx-slider.vertical .ngx-slider-tick{vertical-align:middle;margin-left:auto;margin-top:11px} .ngx-slider.vertical .ngx-slider-tick-value{left:24px;top:auto;transform:translateY(-28%)} .ngx-slider.vertical .ngx-slider-tick-legend{top:auto;right:24px;transform:translateY(-28%);max-width:none;white-space:nowrap} .ngx-slider.vertical .ngx-slider-ticks-values-under .ngx-slider-tick-value{bottom:auto;left:auto;right:24px} .ngx-slider *{transition:none} .ngx-slider.animate .ngx-slider-bar-wrapper{transition:all linear .3s} .ngx-slider.animate .ngx-slider-selection{transition:background-color linear .3s} .ngx-slider.animate .ngx-slider-pointer{transition:all linear .3s} .ngx-slider.animate .ngx-slider-pointer:after{transition:all linear .3s} .ngx-slider.animate .ngx-slider-bubble{transition:all linear .3s} .ngx-slider.animate .ngx-slider-bubble.ngx-slider-limit{transition:opacity linear .3s} .ngx-slider.animate .ngx-slider-bubble.ngx-slider-combined{transition:opacity linear .3s} .ngx-slider.animate .ngx-slider-tick{transition:background-color linear .3s}']})}return t})(),Ub=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=ut({type:t});static \u0275inj=ct({imports:[vl]})}return t})();var $="primary",Gs=Symbol("RouteTitle"),rf=class{constructor(n){this.params=n||{}}has(n){return Object.prototype.hasOwnProperty.call(this.params,n)}get(n){if(this.has(n)){let e=this.params[n];return Array.isArray(e)?e[0]:e}return null}getAll(n){if(this.has(n)){let e=this.params[n];return Array.isArray(e)?e:[e]}return[]}get keys(){return Object.keys(this.params)}};function Rr(t){return new rf(t)}function qO(t,n,e){let i=e.path.split("/");if(i.length>t.length||e.pathMatch==="full"&&(n.hasChildren()||i.lengthi[s]===r)}else return t===n}function ew(t){return t.length>0?t[t.length-1]:null}function Wn(t){return cu(t)?t:_r(t)?Ce(Promise.resolve(t)):k(t)}var ZO={exact:nw,subset:iw},tw={exact:QO,subset:KO,ignored:()=>!0};function $b(t,n,e){return ZO[e.paths](t.root,n.root,e.matrixParams)&&tw[e.queryParams](t.queryParams,n.queryParams)&&!(e.fragment==="exact"&&t.fragment!==n.fragment)}function QO(t,n){return Kt(t,n)}function nw(t,n,e){if(!Oi(t.segments,n.segments)||!Ol(t.segments,n.segments,e)||t.numberOfChildren!==n.numberOfChildren)return!1;for(let i in n.children)if(!t.children[i]||!nw(t.children[i],n.children[i],e))return!1;return!0}function KO(t,n){return Object.keys(n).length<=Object.keys(t).length&&Object.keys(n).every(e=>Jb(t[e],n[e]))}function iw(t,n,e){return rw(t,n,n.segments,e)}function rw(t,n,e,i){if(t.segments.length>e.length){let r=t.segments.slice(0,e.length);return!(!Oi(r,e)||n.hasChildren()||!Ol(r,e,i))}else if(t.segments.length===e.length){if(!Oi(t.segments,e)||!Ol(t.segments,e,i))return!1;for(let r in n.children)if(!t.children[r]||!iw(t.children[r],n.children[r],i))return!1;return!0}else{let r=e.slice(0,t.segments.length),s=e.slice(t.segments.length);return!Oi(t.segments,r)||!Ol(t.segments,r,i)||!t.children[$]?!1:rw(t.children[$],n,s,i)}}function Ol(t,n,e){return n.every((i,r)=>tw[e](t[r].parameters,i.parameters))}var bn=class{constructor(n=new se([],{}),e={},i=null){this.root=n,this.queryParams=e,this.fragment=i}get queryParamMap(){return this._queryParamMap??=Rr(this.queryParams),this._queryParamMap}toString(){return eT.serialize(this)}},se=class{constructor(n,e){this.segments=n,this.children=e,this.parent=null,Object.values(e).forEach(i=>i.parent=this)}hasChildren(){return this.numberOfChildren>0}get numberOfChildren(){return Object.keys(this.children).length}toString(){return Tl(this)}},Ii=class{constructor(n,e){this.path=n,this.parameters=e}get parameterMap(){return this._parameterMap??=Rr(this.parameters),this._parameterMap}toString(){return ow(this)}};function XO(t,n){return Oi(t,n)&&t.every((e,i)=>Kt(e.parameters,n[i].parameters))}function Oi(t,n){return t.length!==n.length?!1:t.every((e,i)=>e.path===n[i].path)}function JO(t,n){let e=[];return Object.entries(t.children).forEach(([i,r])=>{i===$&&(e=e.concat(n(r,i)))}),Object.entries(t.children).forEach(([i,r])=>{i!==$&&(e=e.concat(n(r,i)))}),e}var qs=(()=>{class t{static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:()=>new kr,providedIn:"root"})}}return t})(),kr=class{parse(n){let e=new af(n);return new bn(e.parseRootSegment(),e.parseQueryParams(),e.parseFragment())}serialize(n){let e=`/${Ns(n.root,!0)}`,i=iT(n.queryParams),r=typeof n.fragment=="string"?`#${tT(n.fragment)}`:"";return`${e}${i}${r}`}},eT=new kr;function Tl(t){return t.segments.map(n=>ow(n)).join("/")}function Ns(t,n){if(!t.hasChildren())return Tl(t);if(n){let e=t.children[$]?Ns(t.children[$],!1):"",i=[];return Object.entries(t.children).forEach(([r,s])=>{r!==$&&i.push(`${r}:${Ns(s,!1)}`)}),i.length>0?`${e}(${i.join("//")})`:e}else{let e=JO(t,(i,r)=>r===$?[Ns(t.children[$],!1)]:[`${r}:${Ns(i,!1)}`]);return Object.keys(t.children).length===1&&t.children[$]!=null?`${Tl(t)}/${e[0]}`:`${Tl(t)}/(${e.join("//")})`}}function sw(t){return encodeURIComponent(t).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function Sl(t){return sw(t).replace(/%3B/gi,";")}function tT(t){return encodeURI(t)}function of(t){return sw(t).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function Al(t){return decodeURIComponent(t)}function zb(t){return Al(t.replace(/\+/g,"%20"))}function ow(t){return`${of(t.path)}${nT(t.parameters)}`}function nT(t){return Object.entries(t).map(([n,e])=>`;${of(n)}=${of(e)}`).join("")}function iT(t){let n=Object.entries(t).map(([e,i])=>Array.isArray(i)?i.map(r=>`${Sl(e)}=${Sl(r)}`).join("&"):`${Sl(e)}=${Sl(i)}`).filter(e=>e);return n.length?`?${n.join("&")}`:""}var rT=/^[^\/()?;#]+/;function Jh(t){let n=t.match(rT);return n?n[0]:""}var sT=/^[^\/()?;=#]+/;function oT(t){let n=t.match(sT);return n?n[0]:""}var aT=/^[^=?&#]+/;function lT(t){let n=t.match(aT);return n?n[0]:""}var cT=/^[^&#]+/;function uT(t){let n=t.match(cT);return n?n[0]:""}var af=class{constructor(n){this.url=n,this.remaining=n}parseRootSegment(){return this.consumeOptional("/"),this.remaining===""||this.peekStartsWith("?")||this.peekStartsWith("#")?new se([],{}):new se([],this.parseChildren())}parseQueryParams(){let n={};if(this.consumeOptional("?"))do this.parseQueryParam(n);while(this.consumeOptional("&"));return n}parseFragment(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}parseChildren(){if(this.remaining==="")return{};this.consumeOptional("/");let n=[];for(this.peekStartsWith("(")||n.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),n.push(this.parseSegment());let e={};this.peekStartsWith("/(")&&(this.capture("/"),e=this.parseParens(!0));let i={};return this.peekStartsWith("(")&&(i=this.parseParens(!1)),(n.length>0||Object.keys(e).length>0)&&(i[$]=new se(n,e)),i}parseSegment(){let n=Jh(this.remaining);if(n===""&&this.peekStartsWith(";"))throw new T(4009,!1);return this.capture(n),new Ii(Al(n),this.parseMatrixParams())}parseMatrixParams(){let n={};for(;this.consumeOptional(";");)this.parseParam(n);return n}parseParam(n){let e=oT(this.remaining);if(!e)return;this.capture(e);let i="";if(this.consumeOptional("=")){let r=Jh(this.remaining);r&&(i=r,this.capture(i))}n[Al(e)]=Al(i)}parseQueryParam(n){let e=lT(this.remaining);if(!e)return;this.capture(e);let i="";if(this.consumeOptional("=")){let o=uT(this.remaining);o&&(i=o,this.capture(i))}let r=zb(e),s=zb(i);if(n.hasOwnProperty(r)){let o=n[r];Array.isArray(o)||(o=[o],n[r]=o),o.push(s)}else n[r]=s}parseParens(n){let e={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){let i=Jh(this.remaining),r=this.remaining[i.length];if(r!=="/"&&r!==")"&&r!==";")throw new T(4010,!1);let s;i.indexOf(":")>-1?(s=i.slice(0,i.indexOf(":")),this.capture(s),this.capture(":")):n&&(s=$);let o=this.parseChildren();e[s]=Object.keys(o).length===1?o[$]:new se([],o),this.consumeOptional("//")}return e}peekStartsWith(n){return this.remaining.startsWith(n)}consumeOptional(n){return this.peekStartsWith(n)?(this.remaining=this.remaining.substring(n.length),!0):!1}capture(n){if(!this.consumeOptional(n))throw new T(4011,!1)}};function aw(t){return t.segments.length>0?new se([],{[$]:t}):t}function lw(t){let n={};for(let[i,r]of Object.entries(t.children)){let s=lw(r);if(i===$&&s.segments.length===0&&s.hasChildren())for(let[o,a]of Object.entries(s.children))n[o]=a;else(s.segments.length>0||s.hasChildren())&&(n[i]=s)}let e=new se(t.segments,n);return dT(e)}function dT(t){if(t.numberOfChildren===1&&t.children[$]){let n=t.children[$];return new se(t.segments.concat(n.segments),n.children)}return t}function Vs(t){return t instanceof bn}function hT(t,n,e=null,i=null){let r=cw(t);return uw(r,n,e,i)}function cw(t){let n;function e(s){let o={};for(let l of s.children){let c=e(l);o[l.outlet]=c}let a=new se(s.url,o);return s===t&&(n=a),a}let i=e(t.root),r=aw(i);return n??r}function uw(t,n,e,i){let r=t;for(;r.parent;)r=r.parent;if(n.length===0)return ef(r,r,r,e,i);let s=fT(n);if(s.toRoot())return ef(r,r,new se([],{}),e,i);let o=pT(s,r,t),a=o.processChildren?Ps(o.segmentGroup,o.index,s.commands):hw(o.segmentGroup,o.index,s.commands);return ef(r,o.segmentGroup,a,e,i)}function Nl(t){return typeof t=="object"&&t!=null&&!t.outlets&&!t.segmentPath}function js(t){return typeof t=="object"&&t!=null&&t.outlets}function ef(t,n,e,i,r){let s={};i&&Object.entries(i).forEach(([l,c])=>{s[l]=Array.isArray(c)?c.map(u=>`${u}`):`${c}`});let o;t===n?o=e:o=dw(t,n,e);let a=aw(lw(o));return new bn(a,s,r)}function dw(t,n,e){let i={};return Object.entries(t.children).forEach(([r,s])=>{s===n?i[r]=e:i[r]=dw(s,n,e)}),new se(t.segments,i)}var Rl=class{constructor(n,e,i){if(this.isAbsolute=n,this.numberOfDoubleDots=e,this.commands=i,n&&i.length>0&&Nl(i[0]))throw new T(4003,!1);let r=i.find(js);if(r&&r!==ew(i))throw new T(4004,!1)}toRoot(){return this.isAbsolute&&this.commands.length===1&&this.commands[0]=="/"}};function fT(t){if(typeof t[0]=="string"&&t.length===1&&t[0]==="/")return new Rl(!0,0,t);let n=0,e=!1,i=t.reduce((r,s,o)=>{if(typeof s=="object"&&s!=null){if(s.outlets){let a={};return Object.entries(s.outlets).forEach(([l,c])=>{a[l]=typeof c=="string"?c.split("/"):c}),[...r,{outlets:a}]}if(s.segmentPath)return[...r,s.segmentPath]}return typeof s!="string"?[...r,s]:o===0?(s.split("/").forEach((a,l)=>{l==0&&a==="."||(l==0&&a===""?e=!0:a===".."?n++:a!=""&&r.push(a))}),r):[...r,s]},[]);return new Rl(e,n,i)}var Tr=class{constructor(n,e,i){this.segmentGroup=n,this.processChildren=e,this.index=i}};function pT(t,n,e){if(t.isAbsolute)return new Tr(n,!0,0);if(!e)return new Tr(n,!1,NaN);if(e.parent===null)return new Tr(e,!0,0);let i=Nl(t.commands[0])?0:1,r=e.segments.length-1+i;return gT(e,r,t.numberOfDoubleDots)}function gT(t,n,e){let i=t,r=n,s=e;for(;s>r;){if(s-=r,i=i.parent,!i)throw new T(4005,!1);r=i.segments.length}return new Tr(i,!1,r-s)}function mT(t){return js(t[0])?t[0].outlets:{[$]:t}}function hw(t,n,e){if(t??=new se([],{}),t.segments.length===0&&t.hasChildren())return Ps(t,n,e);let i=vT(t,n,e),r=e.slice(i.commandIndex);if(i.match&&i.pathIndexs!==$)&&t.children[$]&&t.numberOfChildren===1&&t.children[$].segments.length===0){let s=Ps(t.children[$],n,e);return new se(t.segments,s.children)}return Object.entries(i).forEach(([s,o])=>{typeof o=="string"&&(o=[o]),o!==null&&(r[s]=hw(t.children[s],n,o))}),Object.entries(t.children).forEach(([s,o])=>{i[s]===void 0&&(r[s]=o)}),new se(t.segments,r)}}function vT(t,n,e){let i=0,r=n,s={match:!1,pathIndex:0,commandIndex:0};for(;r=e.length)return s;let o=t.segments[r],a=e[i];if(js(a))break;let l=`${a}`,c=i0&&l===void 0)break;if(l&&c&&typeof c=="object"&&c.outlets===void 0){if(!Gb(l,c,o))return s;i+=2}else{if(!Gb(l,{},o))return s;i++}r++}return{match:!0,pathIndex:r,commandIndex:i}}function lf(t,n,e){let i=t.segments.slice(0,n),r=0;for(;r{typeof i=="string"&&(i=[i]),i!==null&&(n[e]=lf(new se([],{}),0,i))}),n}function Wb(t){let n={};return Object.entries(t).forEach(([e,i])=>n[e]=`${i}`),n}function Gb(t,n,e){return t==e.path&&Kt(n,e.parameters)}var Ls="imperative",Re=function(t){return t[t.NavigationStart=0]="NavigationStart",t[t.NavigationEnd=1]="NavigationEnd",t[t.NavigationCancel=2]="NavigationCancel",t[t.NavigationError=3]="NavigationError",t[t.RoutesRecognized=4]="RoutesRecognized",t[t.ResolveStart=5]="ResolveStart",t[t.ResolveEnd=6]="ResolveEnd",t[t.GuardsCheckStart=7]="GuardsCheckStart",t[t.GuardsCheckEnd=8]="GuardsCheckEnd",t[t.RouteConfigLoadStart=9]="RouteConfigLoadStart",t[t.RouteConfigLoadEnd=10]="RouteConfigLoadEnd",t[t.ChildActivationStart=11]="ChildActivationStart",t[t.ChildActivationEnd=12]="ChildActivationEnd",t[t.ActivationStart=13]="ActivationStart",t[t.ActivationEnd=14]="ActivationEnd",t[t.Scroll=15]="Scroll",t[t.NavigationSkipped=16]="NavigationSkipped",t}(Re||{}),xt=class{constructor(n,e){this.id=n,this.url=e}},Pr=class extends xt{constructor(n,e,i="imperative",r=null){super(n,e),this.type=Re.NavigationStart,this.navigationTrigger=i,this.restoredState=r}toString(){return`NavigationStart(id: ${this.id}, url: '${this.url}')`}},wn=class extends xt{constructor(n,e,i){super(n,e),this.urlAfterRedirects=i,this.type=Re.NavigationEnd}toString(){return`NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`}},pt=function(t){return t[t.Redirect=0]="Redirect",t[t.SupersededByNewNavigation=1]="SupersededByNewNavigation",t[t.NoDataFromResolver=2]="NoDataFromResolver",t[t.GuardRejected=3]="GuardRejected",t}(pt||{}),kl=function(t){return t[t.IgnoredSameUrlNavigation=0]="IgnoredSameUrlNavigation",t[t.IgnoredByUrlHandlingStrategy=1]="IgnoredByUrlHandlingStrategy",t}(kl||{}),yn=class extends xt{constructor(n,e,i,r){super(n,e),this.reason=i,this.code=r,this.type=Re.NavigationCancel}toString(){return`NavigationCancel(id: ${this.id}, url: '${this.url}')`}},zn=class extends xt{constructor(n,e,i,r){super(n,e),this.reason=i,this.code=r,this.type=Re.NavigationSkipped}},Hs=class extends xt{constructor(n,e,i,r){super(n,e),this.error=i,this.target=r,this.type=Re.NavigationError}toString(){return`NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`}},Pl=class extends xt{constructor(n,e,i,r){super(n,e),this.urlAfterRedirects=i,this.state=r,this.type=Re.RoutesRecognized}toString(){return`RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},cf=class extends xt{constructor(n,e,i,r){super(n,e),this.urlAfterRedirects=i,this.state=r,this.type=Re.GuardsCheckStart}toString(){return`GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},uf=class extends xt{constructor(n,e,i,r,s){super(n,e),this.urlAfterRedirects=i,this.state=r,this.shouldActivate=s,this.type=Re.GuardsCheckEnd}toString(){return`GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`}},df=class extends xt{constructor(n,e,i,r){super(n,e),this.urlAfterRedirects=i,this.state=r,this.type=Re.ResolveStart}toString(){return`ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},hf=class extends xt{constructor(n,e,i,r){super(n,e),this.urlAfterRedirects=i,this.state=r,this.type=Re.ResolveEnd}toString(){return`ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},ff=class{constructor(n){this.route=n,this.type=Re.RouteConfigLoadStart}toString(){return`RouteConfigLoadStart(path: ${this.route.path})`}},pf=class{constructor(n){this.route=n,this.type=Re.RouteConfigLoadEnd}toString(){return`RouteConfigLoadEnd(path: ${this.route.path})`}},gf=class{constructor(n){this.snapshot=n,this.type=Re.ChildActivationStart}toString(){return`ChildActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},mf=class{constructor(n){this.snapshot=n,this.type=Re.ChildActivationEnd}toString(){return`ChildActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},vf=class{constructor(n){this.snapshot=n,this.type=Re.ActivationStart}toString(){return`ActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},yf=class{constructor(n){this.snapshot=n,this.type=Re.ActivationEnd}toString(){return`ActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Ll=class{constructor(n,e,i){this.routerEvent=n,this.position=e,this.anchor=i,this.type=Re.Scroll}toString(){let n=this.position?`${this.position[0]}, ${this.position[1]}`:null;return`Scroll(anchor: '${this.anchor}', position: '${n}')`}},Bs=class{},Lr=class{constructor(n,e){this.url=n,this.navigationBehaviorOptions=e}};function bT(t,n){return t.providers&&!t._injector&&(t._injector=nl(t.providers,n,`Route: ${t.path}`)),t._injector??n}function Lt(t){return t.outlet||$}function wT(t,n){let e=t.filter(i=>Lt(i)===n);return e.push(...t.filter(i=>Lt(i)!==n)),e}function Ys(t){if(!t)return null;if(t.routeConfig?._injector)return t.routeConfig._injector;for(let n=t.parent;n;n=n.parent){let e=n.routeConfig;if(e?._loadedInjector)return e._loadedInjector;if(e?._injector)return e._injector}return null}var bf=class{get injector(){return Ys(this.route?.snapshot)??this.rootInjector}set injector(n){}constructor(n){this.rootInjector=n,this.outlet=null,this.route=null,this.children=new Zs(this.rootInjector),this.attachRef=null}},Zs=(()=>{class t{constructor(e){this.rootInjector=e,this.contexts=new Map}onChildOutletCreated(e,i){let r=this.getOrCreateContext(e);r.outlet=i,this.contexts.set(e,r)}onChildOutletDestroyed(e){let i=this.getContext(e);i&&(i.outlet=null,i.attachRef=null)}onOutletDeactivated(){let e=this.contexts;return this.contexts=new Map,e}onOutletReAttached(e){this.contexts=e}getOrCreateContext(e){let i=this.getContext(e);return i||(i=new bf(this.rootInjector),this.contexts.set(e,i)),i}getContext(e){return this.contexts.get(e)||null}static{this.\u0275fac=function(i){return new(i||t)(R(lt))}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})(),Fl=class{constructor(n){this._root=n}get root(){return this._root.value}parent(n){let e=this.pathFromRoot(n);return e.length>1?e[e.length-2]:null}children(n){let e=wf(n,this._root);return e?e.children.map(i=>i.value):[]}firstChild(n){let e=wf(n,this._root);return e&&e.children.length>0?e.children[0].value:null}siblings(n){let e=Df(n,this._root);return e.length<2?[]:e[e.length-2].children.map(r=>r.value).filter(r=>r!==n)}pathFromRoot(n){return Df(n,this._root).map(e=>e.value)}};function wf(t,n){if(t===n.value)return n;for(let e of n.children){let i=wf(t,e);if(i)return i}return null}function Df(t,n){if(t===n.value)return[n];for(let e of n.children){let i=Df(t,e);if(i.length)return i.unshift(n),i}return[]}var ft=class{constructor(n,e){this.value=n,this.children=e}toString(){return`TreeNode(${this.value})`}};function Or(t){let n={};return t&&t.children.forEach(e=>n[e.value.outlet]=e),n}var Vl=class extends Fl{constructor(n,e){super(n),this.snapshot=e,Tf(this,n)}toString(){return this.snapshot.toString()}};function fw(t){let n=DT(t),e=new Pe([new Ii("",{})]),i=new Pe({}),r=new Pe({}),s=new Pe({}),o=new Pe(""),a=new Fr(e,i,s,o,r,$,t,n.root);return a.snapshot=n.root,new Vl(new ft(a,[]),n)}function DT(t){let n={},e={},i={},r="",s=new Ar([],n,i,r,e,$,t,null,{});return new Hl("",new ft(s,[]))}var Fr=class{constructor(n,e,i,r,s,o,a,l){this.urlSubject=n,this.paramsSubject=e,this.queryParamsSubject=i,this.fragmentSubject=r,this.dataSubject=s,this.outlet=o,this.component=a,this._futureSnapshot=l,this.title=this.dataSubject?.pipe(J(c=>c[Gs]))??k(void 0),this.url=n,this.params=e,this.queryParams=i,this.fragment=r,this.data=s}get routeConfig(){return this._futureSnapshot.routeConfig}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=this.params.pipe(J(n=>Rr(n))),this._paramMap}get queryParamMap(){return this._queryParamMap??=this.queryParams.pipe(J(n=>Rr(n))),this._queryParamMap}toString(){return this.snapshot?this.snapshot.toString():`Future(${this._futureSnapshot})`}};function jl(t,n,e="emptyOnly"){let i,{routeConfig:r}=t;return n!==null&&(e==="always"||r?.path===""||!n.component&&!n.routeConfig?.loadComponent)?i={params:S(S({},n.params),t.params),data:S(S({},n.data),t.data),resolve:S(S(S(S({},t.data),n.data),r?.data),t._resolvedData)}:i={params:S({},t.params),data:S({},t.data),resolve:S(S({},t.data),t._resolvedData??{})},r&&gw(r)&&(i.resolve[Gs]=r.title),i}var Ar=class{get title(){return this.data?.[Gs]}constructor(n,e,i,r,s,o,a,l,c){this.url=n,this.params=e,this.queryParams=i,this.fragment=r,this.data=s,this.outlet=o,this.component=a,this.routeConfig=l,this._resolve=c}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=Rr(this.params),this._paramMap}get queryParamMap(){return this._queryParamMap??=Rr(this.queryParams),this._queryParamMap}toString(){let n=this.url.map(i=>i.toString()).join("/"),e=this.routeConfig?this.routeConfig.path:"";return`Route(url:'${n}', path:'${e}')`}},Hl=class extends Fl{constructor(n,e){super(e),this.url=n,Tf(this,e)}toString(){return pw(this._root)}};function Tf(t,n){n.value._routerState=t,n.children.forEach(e=>Tf(t,e))}function pw(t){let n=t.children.length>0?` { ${t.children.map(pw).join(", ")} } `:"";return`${t.value}${n}`}function tf(t){if(t.snapshot){let n=t.snapshot,e=t._futureSnapshot;t.snapshot=e,Kt(n.queryParams,e.queryParams)||t.queryParamsSubject.next(e.queryParams),n.fragment!==e.fragment&&t.fragmentSubject.next(e.fragment),Kt(n.params,e.params)||t.paramsSubject.next(e.params),YO(n.url,e.url)||t.urlSubject.next(e.url),Kt(n.data,e.data)||t.dataSubject.next(e.data)}else t.snapshot=t._futureSnapshot,t.dataSubject.next(t._futureSnapshot.data)}function _f(t,n){let e=Kt(t.params,n.params)&&XO(t.url,n.url),i=!t.parent!=!n.parent;return e&&!i&&(!t.parent||_f(t.parent,n.parent))}function gw(t){return typeof t.title=="string"||t.title===null}var _T=(()=>{class t{constructor(){this.activated=null,this._activatedRoute=null,this.name=$,this.activateEvents=new re,this.deactivateEvents=new re,this.attachEvents=new re,this.detachEvents=new re,this.parentContexts=E(Zs),this.location=E(pn),this.changeDetector=E(Pt),this.inputBinder=E(Wl,{optional:!0}),this.supportsBindingToComponentInputs=!0}get activatedComponentRef(){return this.activated}ngOnChanges(e){if(e.name){let{firstChange:i,previousValue:r}=e.name;if(i)return;this.isTrackedInParentContexts(r)&&(this.deactivate(),this.parentContexts.onChildOutletDestroyed(r)),this.initializeOutletWithName()}}ngOnDestroy(){this.isTrackedInParentContexts(this.name)&&this.parentContexts.onChildOutletDestroyed(this.name),this.inputBinder?.unsubscribeFromRouteData(this)}isTrackedInParentContexts(e){return this.parentContexts.getContext(e)?.outlet===this}ngOnInit(){this.initializeOutletWithName()}initializeOutletWithName(){if(this.parentContexts.onChildOutletCreated(this.name,this),this.activated)return;let e=this.parentContexts.getContext(this.name);e?.route&&(e.attachRef?this.attach(e.attachRef,e.route):this.activateWith(e.route,e.injector))}get isActivated(){return!!this.activated}get component(){if(!this.activated)throw new T(4012,!1);return this.activated.instance}get activatedRoute(){if(!this.activated)throw new T(4012,!1);return this._activatedRoute}get activatedRouteData(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}detach(){if(!this.activated)throw new T(4012,!1);this.location.detach();let e=this.activated;return this.activated=null,this._activatedRoute=null,this.detachEvents.emit(e.instance),e}attach(e,i){this.activated=e,this._activatedRoute=i,this.location.insert(e.hostView),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.attachEvents.emit(e.instance)}deactivate(){if(this.activated){let e=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(e)}}activateWith(e,i){if(this.isActivated)throw new T(4013,!1);this._activatedRoute=e;let r=this.location,o=e.snapshot.component,a=this.parentContexts.getOrCreateContext(this.name).children,l=new Cf(e,a,r.injector);this.activated=r.createComponent(o,{index:r.length,injector:l,environmentInjector:i}),this.changeDetector.markForCheck(),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.activateEvents.emit(this.activated.instance)}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275dir=wt({type:t,selectors:[["router-outlet"]],inputs:{name:"name"},outputs:{activateEvents:"activate",deactivateEvents:"deactivate",attachEvents:"attach",detachEvents:"detach"},exportAs:["outlet"],standalone:!0,features:[Rt]})}}return t})(),Cf=class t{__ngOutletInjector(n){return new t(this.route,this.childContexts,n)}constructor(n,e,i){this.route=n,this.childContexts=e,this.parent=i}get(n,e){return n===Fr?this.route:n===Zs?this.childContexts:this.parent.get(n,e)}},Wl=new N(""),qb=(()=>{class t{constructor(){this.outletDataSubscriptions=new Map}bindActivatedRouteToOutletComponent(e){this.unsubscribeFromRouteData(e),this.subscribeToRouteData(e)}unsubscribeFromRouteData(e){this.outletDataSubscriptions.get(e)?.unsubscribe(),this.outletDataSubscriptions.delete(e)}subscribeToRouteData(e){let{activatedRoute:i}=e,r=rs([i.queryParams,i.params,i.data]).pipe(gt(([s,o,a],l)=>(a=S(S(S({},s),o),a),l===0?k(a):Promise.resolve(a)))).subscribe(s=>{if(!e.isActivated||!e.activatedComponentRef||e.activatedRoute!==i||i.component===null){this.unsubscribeFromRouteData(e);return}let o=ab(i.component);if(!o){this.unsubscribeFromRouteData(e);return}for(let{templateName:a}of o.inputs)e.activatedComponentRef.setInput(a,s[a])});this.outletDataSubscriptions.set(e,r)}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac})}}return t})();function CT(t,n,e){let i=Us(t,n._root,e?e._root:void 0);return new Vl(i,n)}function Us(t,n,e){if(e&&t.shouldReuseRoute(n.value,e.value.snapshot)){let i=e.value;i._futureSnapshot=n.value;let r=xT(t,n,e);return new ft(i,r)}else{if(t.shouldAttach(n.value)){let s=t.retrieve(n.value);if(s!==null){let o=s.route;return o.value._futureSnapshot=n.value,o.children=n.children.map(a=>Us(t,a)),o}}let i=ET(n.value),r=n.children.map(s=>Us(t,s));return new ft(i,r)}}function xT(t,n,e){return n.children.map(i=>{for(let r of e.children)if(t.shouldReuseRoute(i.value,r.value.snapshot))return Us(t,i,r);return Us(t,i)})}function ET(t){return new Fr(new Pe(t.url),new Pe(t.params),new Pe(t.queryParams),new Pe(t.fragment),new Pe(t.data),t.outlet,t.component,t)}var $s=class{constructor(n,e){this.redirectTo=n,this.navigationBehaviorOptions=e}},mw="ngNavigationCancelingError";function Bl(t,n){let{redirectTo:e,navigationBehaviorOptions:i}=Vs(n)?{redirectTo:n,navigationBehaviorOptions:void 0}:n,r=vw(!1,pt.Redirect);return r.url=e,r.navigationBehaviorOptions=i,r}function vw(t,n){let e=new Error(`NavigationCancelingError: ${t||""}`);return e[mw]=!0,e.cancellationCode=n,e}function MT(t){return yw(t)&&Vs(t.url)}function yw(t){return!!t&&t[mw]}var ST=(t,n,e,i)=>J(r=>(new xf(n,r.targetRouterState,r.currentRouterState,e,i).activate(t),r)),xf=class{constructor(n,e,i,r,s){this.routeReuseStrategy=n,this.futureState=e,this.currState=i,this.forwardEvent=r,this.inputBindingEnabled=s}activate(n){let e=this.futureState._root,i=this.currState?this.currState._root:null;this.deactivateChildRoutes(e,i,n),tf(this.futureState.root),this.activateChildRoutes(e,i,n)}deactivateChildRoutes(n,e,i){let r=Or(e);n.children.forEach(s=>{let o=s.value.outlet;this.deactivateRoutes(s,r[o],i),delete r[o]}),Object.values(r).forEach(s=>{this.deactivateRouteAndItsChildren(s,i)})}deactivateRoutes(n,e,i){let r=n.value,s=e?e.value:null;if(r===s)if(r.component){let o=i.getContext(r.outlet);o&&this.deactivateChildRoutes(n,e,o.children)}else this.deactivateChildRoutes(n,e,i);else s&&this.deactivateRouteAndItsChildren(e,i)}deactivateRouteAndItsChildren(n,e){n.value.component&&this.routeReuseStrategy.shouldDetach(n.value.snapshot)?this.detachAndStoreRouteSubtree(n,e):this.deactivateRouteAndOutlet(n,e)}detachAndStoreRouteSubtree(n,e){let i=e.getContext(n.value.outlet),r=i&&n.value.component?i.children:e,s=Or(n);for(let o of Object.values(s))this.deactivateRouteAndItsChildren(o,r);if(i&&i.outlet){let o=i.outlet.detach(),a=i.children.onOutletDeactivated();this.routeReuseStrategy.store(n.value.snapshot,{componentRef:o,route:n,contexts:a})}}deactivateRouteAndOutlet(n,e){let i=e.getContext(n.value.outlet),r=i&&n.value.component?i.children:e,s=Or(n);for(let o of Object.values(s))this.deactivateRouteAndItsChildren(o,r);i&&(i.outlet&&(i.outlet.deactivate(),i.children.onOutletDeactivated()),i.attachRef=null,i.route=null)}activateChildRoutes(n,e,i){let r=Or(e);n.children.forEach(s=>{this.activateRoutes(s,r[s.value.outlet],i),this.forwardEvent(new yf(s.value.snapshot))}),n.children.length&&this.forwardEvent(new mf(n.value.snapshot))}activateRoutes(n,e,i){let r=n.value,s=e?e.value:null;if(tf(r),r===s)if(r.component){let o=i.getOrCreateContext(r.outlet);this.activateChildRoutes(n,e,o.children)}else this.activateChildRoutes(n,e,i);else if(r.component){let o=i.getOrCreateContext(r.outlet);if(this.routeReuseStrategy.shouldAttach(r.snapshot)){let a=this.routeReuseStrategy.retrieve(r.snapshot);this.routeReuseStrategy.store(r.snapshot,null),o.children.onOutletReAttached(a.contexts),o.attachRef=a.componentRef,o.route=a.route.value,o.outlet&&o.outlet.attach(a.componentRef,a.route.value),tf(a.route.value),this.activateChildRoutes(n,null,o.children)}else o.attachRef=null,o.route=r,o.outlet&&o.outlet.activateWith(r,o.injector),this.activateChildRoutes(n,null,o.children)}else this.activateChildRoutes(n,null,i)}},Ul=class{constructor(n){this.path=n,this.route=this.path[this.path.length-1]}},Nr=class{constructor(n,e){this.component=n,this.route=e}};function IT(t,n,e){let i=t._root,r=n?n._root:null;return Rs(i,r,e,[i.value])}function OT(t){let n=t.routeConfig?t.routeConfig.canActivateChild:null;return!n||n.length===0?null:{node:t,guards:n}}function jr(t,n){let e=Symbol(),i=n.get(t,e);return i===e?typeof t=="function"&&!Im(t)?t:n.get(t):i}function Rs(t,n,e,i,r={canDeactivateChecks:[],canActivateChecks:[]}){let s=Or(n);return t.children.forEach(o=>{TT(o,s[o.value.outlet],e,i.concat([o.value]),r),delete s[o.value.outlet]}),Object.entries(s).forEach(([o,a])=>Fs(a,e.getContext(o),r)),r}function TT(t,n,e,i,r={canDeactivateChecks:[],canActivateChecks:[]}){let s=t.value,o=n?n.value:null,a=e?e.getContext(t.value.outlet):null;if(o&&s.routeConfig===o.routeConfig){let l=AT(o,s,s.routeConfig.runGuardsAndResolvers);l?r.canActivateChecks.push(new Ul(i)):(s.data=o.data,s._resolvedData=o._resolvedData),s.component?Rs(t,n,a?a.children:null,i,r):Rs(t,n,e,i,r),l&&a&&a.outlet&&a.outlet.isActivated&&r.canDeactivateChecks.push(new Nr(a.outlet.component,o))}else o&&Fs(n,a,r),r.canActivateChecks.push(new Ul(i)),s.component?Rs(t,null,a?a.children:null,i,r):Rs(t,null,e,i,r);return r}function AT(t,n,e){if(typeof e=="function")return e(t,n);switch(e){case"pathParamsChange":return!Oi(t.url,n.url);case"pathParamsOrQueryParamsChange":return!Oi(t.url,n.url)||!Kt(t.queryParams,n.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!_f(t,n)||!Kt(t.queryParams,n.queryParams);case"paramsChange":default:return!_f(t,n)}}function Fs(t,n,e){let i=Or(t),r=t.value;Object.entries(i).forEach(([s,o])=>{r.component?n?Fs(o,n.children.getContext(s),e):Fs(o,null,e):Fs(o,n,e)}),r.component?n&&n.outlet&&n.outlet.isActivated?e.canDeactivateChecks.push(new Nr(n.outlet.component,r)):e.canDeactivateChecks.push(new Nr(null,r)):e.canDeactivateChecks.push(new Nr(null,r))}function Qs(t){return typeof t=="function"}function NT(t){return typeof t=="boolean"}function RT(t){return t&&Qs(t.canLoad)}function kT(t){return t&&Qs(t.canActivate)}function PT(t){return t&&Qs(t.canActivateChild)}function LT(t){return t&&Qs(t.canDeactivate)}function FT(t){return t&&Qs(t.canMatch)}function bw(t){return t instanceof on||t?.name==="EmptyError"}var Il=Symbol("INITIAL_VALUE");function Vr(){return gt(t=>rs(t.map(n=>n.pipe(an(1),fu(Il)))).pipe(J(n=>{for(let e of n)if(e!==!0){if(e===Il)return Il;if(e===!1||VT(e))return e}return!0}),Xe(n=>n!==Il),an(1)))}function VT(t){return Vs(t)||t instanceof $s}function jT(t,n){return Se(e=>{let{targetSnapshot:i,currentSnapshot:r,guards:{canActivateChecks:s,canDeactivateChecks:o}}=e;return o.length===0&&s.length===0?k(ae(S({},e),{guardsResult:!0})):HT(o,i,r,t).pipe(Se(a=>a&&NT(a)?BT(i,s,t,n):k(a)),J(a=>ae(S({},e),{guardsResult:a})))})}function HT(t,n,e,i){return Ce(t).pipe(Se(r=>GT(r.component,r.route,e,n,i)),jt(r=>r!==!0,!0))}function BT(t,n,e,i){return Ce(n).pipe(li(r=>Ki($T(r.route.parent,i),UT(r.route,i),WT(t,r.path,e),zT(t,r.route,e))),jt(r=>r!==!0,!0))}function UT(t,n){return t!==null&&n&&n(new vf(t)),k(!0)}function $T(t,n){return t!==null&&n&&n(new gf(t)),k(!0)}function zT(t,n,e){let i=n.routeConfig?n.routeConfig.canActivate:null;if(!i||i.length===0)return k(!0);let r=i.map(s=>$o(()=>{let o=Ys(n)??e,a=jr(s,o),l=kT(a)?a.canActivate(n,t):qt(o,()=>a(n,t));return Wn(l).pipe(jt())}));return k(r).pipe(Vr())}function WT(t,n,e){let i=n[n.length-1],s=n.slice(0,n.length-1).reverse().map(o=>OT(o)).filter(o=>o!==null).map(o=>$o(()=>{let a=o.guards.map(l=>{let c=Ys(o.node)??e,u=jr(l,c),d=PT(u)?u.canActivateChild(i,t):qt(c,()=>u(i,t));return Wn(d).pipe(jt())});return k(a).pipe(Vr())}));return k(s).pipe(Vr())}function GT(t,n,e,i,r){let s=n&&n.routeConfig?n.routeConfig.canDeactivate:null;if(!s||s.length===0)return k(!0);let o=s.map(a=>{let l=Ys(n)??r,c=jr(a,l),u=LT(c)?c.canDeactivate(t,n,e,i):qt(l,()=>c(t,n,e,i));return Wn(u).pipe(jt())});return k(o).pipe(Vr())}function qT(t,n,e,i){let r=n.canLoad;if(r===void 0||r.length===0)return k(!0);let s=r.map(o=>{let a=jr(o,t),l=RT(a)?a.canLoad(n,e):qt(t,()=>a(n,e));return Wn(l)});return k(s).pipe(Vr(),ww(i))}function ww(t){return iu(Ie(n=>{if(typeof n!="boolean")throw Bl(t,n)}),J(n=>n===!0))}function YT(t,n,e,i){let r=n.canMatch;if(!r||r.length===0)return k(!0);let s=r.map(o=>{let a=jr(o,t),l=FT(a)?a.canMatch(n,e):qt(t,()=>a(n,e));return Wn(l)});return k(s).pipe(Vr(),ww(i))}var zs=class{constructor(n){this.segmentGroup=n||null}},Ws=class extends Error{constructor(n){super(),this.urlTree=n}};function Ir(t){return Zi(new zs(t))}function ZT(t){return Zi(new T(4e3,!1))}function QT(t){return Zi(vw(!1,pt.GuardRejected))}var Ef=class{constructor(n,e){this.urlSerializer=n,this.urlTree=e}lineralizeSegments(n,e){let i=[],r=e.root;for(;;){if(i=i.concat(r.segments),r.numberOfChildren===0)return k(i);if(r.numberOfChildren>1||!r.children[$])return ZT(`${n.redirectTo}`);r=r.children[$]}}applyRedirectCommands(n,e,i,r,s){if(typeof e!="string"){let a=e,{queryParams:l,fragment:c,routeConfig:u,url:d,outlet:h,params:f,data:p,title:g}=r,m=qt(s,()=>a({params:f,data:p,queryParams:l,fragment:c,routeConfig:u,url:d,outlet:h,title:g}));if(m instanceof bn)throw new Ws(m);e=m}let o=this.applyRedirectCreateUrlTree(e,this.urlSerializer.parse(e),n,i);if(e[0]==="/")throw new Ws(o);return o}applyRedirectCreateUrlTree(n,e,i,r){let s=this.createSegmentGroup(n,e.root,i,r);return new bn(s,this.createQueryParams(e.queryParams,this.urlTree.queryParams),e.fragment)}createQueryParams(n,e){let i={};return Object.entries(n).forEach(([r,s])=>{if(typeof s=="string"&&s[0]===":"){let a=s.substring(1);i[r]=e[a]}else i[r]=s}),i}createSegmentGroup(n,e,i,r){let s=this.createSegments(n,e.segments,i,r),o={};return Object.entries(e.children).forEach(([a,l])=>{o[a]=this.createSegmentGroup(n,l,i,r)}),new se(s,o)}createSegments(n,e,i,r){return e.map(s=>s.path[0]===":"?this.findPosParam(n,s,r):this.findOrReturn(s,i))}findPosParam(n,e,i){let r=i[e.path.substring(1)];if(!r)throw new T(4001,!1);return r}findOrReturn(n,e){let i=0;for(let r of e){if(r.path===n.path)return e.splice(i),r;i++}return n}},Mf={matched:!1,consumedSegments:[],remainingSegments:[],parameters:{},positionalParamSegments:{}};function KT(t,n,e,i,r){let s=Dw(t,n,e);return s.matched?(i=bT(n,i),YT(i,n,e,r).pipe(J(o=>o===!0?s:S({},Mf)))):k(s)}function Dw(t,n,e){if(n.path==="**")return XT(e);if(n.path==="")return n.pathMatch==="full"&&(t.hasChildren()||e.length>0)?S({},Mf):{matched:!0,consumedSegments:[],remainingSegments:e,parameters:{},positionalParamSegments:{}};let r=(n.matcher||qO)(e,t,n);if(!r)return S({},Mf);let s={};Object.entries(r.posParams??{}).forEach(([a,l])=>{s[a]=l.path});let o=r.consumed.length>0?S(S({},s),r.consumed[r.consumed.length-1].parameters):s;return{matched:!0,consumedSegments:r.consumed,remainingSegments:e.slice(r.consumed.length),parameters:o,positionalParamSegments:r.posParams??{}}}function XT(t){return{matched:!0,parameters:t.length>0?ew(t).parameters:{},consumedSegments:t,remainingSegments:[],positionalParamSegments:{}}}function Yb(t,n,e,i){return e.length>0&&tA(t,e,i)?{segmentGroup:new se(n,eA(i,new se(e,t.children))),slicedSegments:[]}:e.length===0&&nA(t,e,i)?{segmentGroup:new se(t.segments,JT(t,e,i,t.children)),slicedSegments:e}:{segmentGroup:new se(t.segments,t.children),slicedSegments:e}}function JT(t,n,e,i){let r={};for(let s of e)if(Gl(t,n,s)&&!i[Lt(s)]){let o=new se([],{});r[Lt(s)]=o}return S(S({},i),r)}function eA(t,n){let e={};e[$]=n;for(let i of t)if(i.path===""&&Lt(i)!==$){let r=new se([],{});e[Lt(i)]=r}return e}function tA(t,n,e){return e.some(i=>Gl(t,n,i)&&Lt(i)!==$)}function nA(t,n,e){return e.some(i=>Gl(t,n,i))}function Gl(t,n,e){return(t.hasChildren()||n.length>0)&&e.pathMatch==="full"?!1:e.path===""}function iA(t,n,e){return n.length===0&&!t.children[e]}var Sf=class{};function rA(t,n,e,i,r,s,o="emptyOnly"){return new If(t,n,e,i,r,o,s).recognize()}var sA=31,If=class{constructor(n,e,i,r,s,o,a){this.injector=n,this.configLoader=e,this.rootComponentType=i,this.config=r,this.urlTree=s,this.paramsInheritanceStrategy=o,this.urlSerializer=a,this.applyRedirects=new Ef(this.urlSerializer,this.urlTree),this.absoluteRedirectCount=0,this.allowRedirects=!0}noMatchError(n){return new T(4002,`'${n.segmentGroup}'`)}recognize(){let n=Yb(this.urlTree.root,[],[],this.config).segmentGroup;return this.match(n).pipe(J(({children:e,rootSnapshot:i})=>{let r=new ft(i,e),s=new Hl("",r),o=hT(i,[],this.urlTree.queryParams,this.urlTree.fragment);return o.queryParams=this.urlTree.queryParams,s.url=this.urlSerializer.serialize(o),{state:s,tree:o}}))}match(n){let e=new Ar([],Object.freeze({}),Object.freeze(S({},this.urlTree.queryParams)),this.urlTree.fragment,Object.freeze({}),$,this.rootComponentType,null,{});return this.processSegmentGroup(this.injector,this.config,n,$,e).pipe(J(i=>({children:i,rootSnapshot:e})),On(i=>{if(i instanceof Ws)return this.urlTree=i.urlTree,this.match(i.urlTree.root);throw i instanceof zs?this.noMatchError(i):i}))}processSegmentGroup(n,e,i,r,s){return i.segments.length===0&&i.hasChildren()?this.processChildren(n,e,i,s):this.processSegment(n,e,i,i.segments,r,!0,s).pipe(J(o=>o instanceof ft?[o]:[]))}processChildren(n,e,i,r){let s=[];for(let o of Object.keys(i.children))o==="primary"?s.unshift(o):s.push(o);return Ce(s).pipe(li(o=>{let a=i.children[o],l=wT(e,o);return this.processSegmentGroup(n,l,a,o,r)}),hu((o,a)=>(o.push(...a),o)),Tn(null),du(),Se(o=>{if(o===null)return Ir(i);let a=_w(o);return oA(a),k(a)}))}processSegment(n,e,i,r,s,o,a){return Ce(e).pipe(li(l=>this.processSegmentAgainstRoute(l._injector??n,e,l,i,r,s,o,a).pipe(On(c=>{if(c instanceof zs)return k(null);throw c}))),jt(l=>!!l),On(l=>{if(bw(l))return iA(i,r,s)?k(new Sf):Ir(i);throw l}))}processSegmentAgainstRoute(n,e,i,r,s,o,a,l){return Lt(i)!==o&&(o===$||!Gl(r,s,i))?Ir(r):i.redirectTo===void 0?this.matchSegmentAgainstRoute(n,r,i,s,o,l):this.allowRedirects&&a?this.expandSegmentAgainstRouteUsingRedirect(n,r,e,i,s,o,l):Ir(r)}expandSegmentAgainstRouteUsingRedirect(n,e,i,r,s,o,a){let{matched:l,parameters:c,consumedSegments:u,positionalParamSegments:d,remainingSegments:h}=Dw(e,r,s);if(!l)return Ir(e);typeof r.redirectTo=="string"&&r.redirectTo[0]==="/"&&(this.absoluteRedirectCount++,this.absoluteRedirectCount>sA&&(this.allowRedirects=!1));let f=new Ar(s,c,Object.freeze(S({},this.urlTree.queryParams)),this.urlTree.fragment,Zb(r),Lt(r),r.component??r._loadedComponent??null,r,Qb(r)),p=jl(f,a,this.paramsInheritanceStrategy);f.params=Object.freeze(p.params),f.data=Object.freeze(p.data);let g=this.applyRedirects.applyRedirectCommands(u,r.redirectTo,d,f,n);return this.applyRedirects.lineralizeSegments(r,g).pipe(Se(m=>this.processSegment(n,i,e,m.concat(h),o,!1,a)))}matchSegmentAgainstRoute(n,e,i,r,s,o){let a=KT(e,i,r,n,this.urlSerializer);return i.path==="**"&&(e.children={}),a.pipe(gt(l=>l.matched?(n=i._injector??n,this.getChildConfig(n,i,r).pipe(gt(({routes:c})=>{let u=i._loadedInjector??n,{parameters:d,consumedSegments:h,remainingSegments:f}=l,p=new Ar(h,d,Object.freeze(S({},this.urlTree.queryParams)),this.urlTree.fragment,Zb(i),Lt(i),i.component??i._loadedComponent??null,i,Qb(i)),g=jl(p,o,this.paramsInheritanceStrategy);p.params=Object.freeze(g.params),p.data=Object.freeze(g.data);let{segmentGroup:m,slicedSegments:v}=Yb(e,h,f,c);if(v.length===0&&m.hasChildren())return this.processChildren(u,c,m,p).pipe(J(w=>new ft(p,w)));if(c.length===0&&v.length===0)return k(new ft(p,[]));let y=Lt(i)===s;return this.processSegment(u,c,m,v,y?$:s,!0,p).pipe(J(w=>new ft(p,w instanceof ft?[w]:[])))}))):Ir(e)))}getChildConfig(n,e,i){return e.children?k({routes:e.children,injector:n}):e.loadChildren?e._loadedRoutes!==void 0?k({routes:e._loadedRoutes,injector:e._loadedInjector}):qT(n,e,i,this.urlSerializer).pipe(Se(r=>r?this.configLoader.loadChildren(n,e).pipe(Ie(s=>{e._loadedRoutes=s.routes,e._loadedInjector=s.injector})):QT(e))):k({routes:[],injector:n})}};function oA(t){t.sort((n,e)=>n.value.outlet===$?-1:e.value.outlet===$?1:n.value.outlet.localeCompare(e.value.outlet))}function aA(t){let n=t.value.routeConfig;return n&&n.path===""}function _w(t){let n=[],e=new Set;for(let i of t){if(!aA(i)){n.push(i);continue}let r=n.find(s=>i.value.routeConfig===s.value.routeConfig);r!==void 0?(r.children.push(...i.children),e.add(r)):n.push(i)}for(let i of e){let r=_w(i.children);n.push(new ft(i.value,r))}return n.filter(i=>!e.has(i))}function Zb(t){return t.data||{}}function Qb(t){return t.resolve||{}}function lA(t,n,e,i,r,s){return Se(o=>rA(t,n,e,i,o.extractedUrl,r,s).pipe(J(({state:a,tree:l})=>ae(S({},o),{targetSnapshot:a,urlAfterRedirects:l}))))}function cA(t,n){return Se(e=>{let{targetSnapshot:i,guards:{canActivateChecks:r}}=e;if(!r.length)return k(e);let s=new Set(r.map(l=>l.route)),o=new Set;for(let l of s)if(!o.has(l))for(let c of Cw(l))o.add(c);let a=0;return Ce(o).pipe(li(l=>s.has(l)?uA(l,i,t,n):(l.data=jl(l,l.parent,t).resolve,k(void 0))),Ie(()=>a++),Xi(1),Se(l=>a===o.size?k(e):ot))})}function Cw(t){let n=t.children.map(e=>Cw(e)).flat();return[t,...n]}function uA(t,n,e,i){let r=t.routeConfig,s=t._resolve;return r?.title!==void 0&&!gw(r)&&(s[Gs]=r.title),dA(s,t,n,i).pipe(J(o=>(t._resolvedData=o,t.data=jl(t,t.parent,e).resolve,null)))}function dA(t,n,e,i){let r=sf(t);if(r.length===0)return k({});let s={};return Ce(r).pipe(Se(o=>hA(t[o],n,e,i).pipe(jt(),Ie(a=>{if(a instanceof $s)throw Bl(new kr,a);s[o]=a}))),Xi(1),uu(s),On(o=>bw(o)?ot:Zi(o)))}function hA(t,n,e,i){let r=Ys(n)??i,s=jr(t,r),o=s.resolve?s.resolve(n,e):qt(r,()=>s(n,e));return Wn(o)}function nf(t){return gt(n=>{let e=t(n);return e?Ce(e).pipe(J(()=>n)):k(n)})}var xw=(()=>{class t{buildTitle(e){let i,r=e.root;for(;r!==void 0;)i=this.getResolvedTitleForRoute(r)??i,r=r.children.find(s=>s.outlet===$);return i}getResolvedTitleForRoute(e){return e.data[Gs]}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:()=>E(fA),providedIn:"root"})}}return t})(),fA=(()=>{class t extends xw{constructor(e){super(),this.title=e}updateTitle(e){let i=this.buildTitle(e);i!==void 0&&this.title.setTitle(i)}static{this.\u0275fac=function(i){return new(i||t)(R(Lb))}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})(),Ks=new N("",{providedIn:"root",factory:()=>({})}),pA=(()=>{class t{static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275cmp=Fe({type:t,selectors:[["ng-component"]],standalone:!0,features:[Yy],decls:1,vars:0,template:function(i,r){i&1&&le(0,"router-outlet")},dependencies:[_T],encapsulation:2})}}return t})();function Af(t){let n=t.children&&t.children.map(Af),e=n?ae(S({},t),{children:n}):S({},t);return!e.component&&!e.loadComponent&&(n||e.loadChildren)&&e.outlet&&e.outlet!==$&&(e.component=pA),e}var $l=new N(""),Nf=(()=>{class t{constructor(){this.componentLoaders=new WeakMap,this.childrenLoaders=new WeakMap,this.compiler=E(dl)}loadComponent(e){if(this.componentLoaders.get(e))return this.componentLoaders.get(e);if(e._loadedComponent)return k(e._loadedComponent);this.onLoadStartListener&&this.onLoadStartListener(e);let i=Wn(e.loadComponent()).pipe(J(Ew),Ie(s=>{this.onLoadEndListener&&this.onLoadEndListener(e),e._loadedComponent=s}),ss(()=>{this.componentLoaders.delete(e)})),r=new qi(i,()=>new Ee).pipe(Gi());return this.componentLoaders.set(e,r),r}loadChildren(e,i){if(this.childrenLoaders.get(i))return this.childrenLoaders.get(i);if(i._loadedRoutes)return k({routes:i._loadedRoutes,injector:i._loadedInjector});this.onLoadStartListener&&this.onLoadStartListener(i);let s=gA(i,this.compiler,e,this.onLoadEndListener).pipe(ss(()=>{this.childrenLoaders.delete(i)})),o=new qi(s,()=>new Ee).pipe(Gi());return this.childrenLoaders.set(i,o),o}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})();function gA(t,n,e,i){return Wn(t.loadChildren()).pipe(J(Ew),Se(r=>r instanceof fs||Array.isArray(r)?k(r):Ce(n.compileModuleAsync(r))),J(r=>{i&&i(t);let s,o,a=!1;return Array.isArray(r)?(o=r,a=!0):(s=r.create(e).injector,o=s.get($l,[],{optional:!0,self:!0}).flat()),{routes:o.map(Af),injector:s}}))}function mA(t){return t&&typeof t=="object"&&"default"in t}function Ew(t){return mA(t)?t.default:t}var Rf=(()=>{class t{static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:()=>E(vA),providedIn:"root"})}}return t})(),vA=(()=>{class t{shouldProcessUrl(e){return!0}extract(e){return e}merge(e,i){return e}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})(),Mw=new N(""),Sw=new N("");function yA(t,n,e){let i=t.get(Sw),r=t.get(et);return t.get(ue).runOutsideAngular(()=>{if(!r.startViewTransition||i.skipNextTransition)return i.skipNextTransition=!1,new Promise(c=>setTimeout(c));let s,o=new Promise(c=>{s=c}),a=r.startViewTransition(()=>(s(),bA(t))),{onViewTransitionCreated:l}=i;return l&&qt(t,()=>l({transition:a,from:n,to:e})),o})}function bA(t){return new Promise(n=>{ph({read:()=>setTimeout(n)},{injector:t})})}var wA=new N(""),kf=(()=>{class t{get hasRequestedNavigation(){return this.navigationId!==0}constructor(){this.currentNavigation=null,this.currentTransition=null,this.lastSuccessfulNavigation=null,this.events=new Ee,this.transitionAbortSubject=new Ee,this.configLoader=E(Nf),this.environmentInjector=E(lt),this.urlSerializer=E(qs),this.rootContexts=E(Zs),this.location=E(Cr),this.inputBindingEnabled=E(Wl,{optional:!0})!==null,this.titleStrategy=E(xw),this.options=E(Ks,{optional:!0})||{},this.paramsInheritanceStrategy=this.options.paramsInheritanceStrategy||"emptyOnly",this.urlHandlingStrategy=E(Rf),this.createViewTransition=E(Mw,{optional:!0}),this.navigationErrorHandler=E(wA,{optional:!0}),this.navigationId=0,this.afterPreactivation=()=>k(void 0),this.rootComponentType=null;let e=r=>this.events.next(new ff(r)),i=r=>this.events.next(new pf(r));this.configLoader.onLoadEndListener=i,this.configLoader.onLoadStartListener=e}complete(){this.transitions?.complete()}handleNavigationRequest(e){let i=++this.navigationId;this.transitions?.next(ae(S(S({},this.transitions.value),e),{id:i}))}setupNavigations(e,i,r){return this.transitions=new Pe({id:0,currentUrlTree:i,currentRawUrl:i,extractedUrl:this.urlHandlingStrategy.extract(i),urlAfterRedirects:this.urlHandlingStrategy.extract(i),rawUrl:i,extras:{},resolve:()=>{},reject:()=>{},promise:Promise.resolve(!0),source:Ls,restoredState:null,currentSnapshot:r.snapshot,targetSnapshot:null,currentRouterState:r,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null}),this.transitions.pipe(Xe(s=>s.id!==0),J(s=>ae(S({},s),{extractedUrl:this.urlHandlingStrategy.extract(s.rawUrl)})),gt(s=>{let o=!1,a=!1;return k(s).pipe(gt(l=>{if(this.navigationId>s.id)return this.cancelNavigationTransition(s,"",pt.SupersededByNewNavigation),ot;this.currentTransition=s,this.currentNavigation={id:l.id,initialUrl:l.rawUrl,extractedUrl:l.extractedUrl,targetBrowserUrl:typeof l.extras.browserUrl=="string"?this.urlSerializer.parse(l.extras.browserUrl):l.extras.browserUrl,trigger:l.source,extras:l.extras,previousNavigation:this.lastSuccessfulNavigation?ae(S({},this.lastSuccessfulNavigation),{previousNavigation:null}):null};let c=!e.navigated||this.isUpdatingInternalState()||this.isUpdatedBrowserUrl(),u=l.extras.onSameUrlNavigation??e.onSameUrlNavigation;if(!c&&u!=="reload"){let d="";return this.events.next(new zn(l.id,this.urlSerializer.serialize(l.rawUrl),d,kl.IgnoredSameUrlNavigation)),l.resolve(!1),ot}if(this.urlHandlingStrategy.shouldProcessUrl(l.rawUrl))return k(l).pipe(gt(d=>{let h=this.transitions?.getValue();return this.events.next(new Pr(d.id,this.urlSerializer.serialize(d.extractedUrl),d.source,d.restoredState)),h!==this.transitions?.getValue()?ot:Promise.resolve(d)}),lA(this.environmentInjector,this.configLoader,this.rootComponentType,e.config,this.urlSerializer,this.paramsInheritanceStrategy),Ie(d=>{s.targetSnapshot=d.targetSnapshot,s.urlAfterRedirects=d.urlAfterRedirects,this.currentNavigation=ae(S({},this.currentNavigation),{finalUrl:d.urlAfterRedirects});let h=new Pl(d.id,this.urlSerializer.serialize(d.extractedUrl),this.urlSerializer.serialize(d.urlAfterRedirects),d.targetSnapshot);this.events.next(h)}));if(c&&this.urlHandlingStrategy.shouldProcessUrl(l.currentRawUrl)){let{id:d,extractedUrl:h,source:f,restoredState:p,extras:g}=l,m=new Pr(d,this.urlSerializer.serialize(h),f,p);this.events.next(m);let v=fw(this.rootComponentType).snapshot;return this.currentTransition=s=ae(S({},l),{targetSnapshot:v,urlAfterRedirects:h,extras:ae(S({},g),{skipLocationChange:!1,replaceUrl:!1})}),this.currentNavigation.finalUrl=h,k(s)}else{let d="";return this.events.next(new zn(l.id,this.urlSerializer.serialize(l.extractedUrl),d,kl.IgnoredByUrlHandlingStrategy)),l.resolve(!1),ot}}),Ie(l=>{let c=new cf(l.id,this.urlSerializer.serialize(l.extractedUrl),this.urlSerializer.serialize(l.urlAfterRedirects),l.targetSnapshot);this.events.next(c)}),J(l=>(this.currentTransition=s=ae(S({},l),{guards:IT(l.targetSnapshot,l.currentSnapshot,this.rootContexts)}),s)),jT(this.environmentInjector,l=>this.events.next(l)),Ie(l=>{if(s.guardsResult=l.guardsResult,l.guardsResult&&typeof l.guardsResult!="boolean")throw Bl(this.urlSerializer,l.guardsResult);let c=new uf(l.id,this.urlSerializer.serialize(l.extractedUrl),this.urlSerializer.serialize(l.urlAfterRedirects),l.targetSnapshot,!!l.guardsResult);this.events.next(c)}),Xe(l=>l.guardsResult?!0:(this.cancelNavigationTransition(l,"",pt.GuardRejected),!1)),nf(l=>{if(l.guards.canActivateChecks.length)return k(l).pipe(Ie(c=>{let u=new df(c.id,this.urlSerializer.serialize(c.extractedUrl),this.urlSerializer.serialize(c.urlAfterRedirects),c.targetSnapshot);this.events.next(u)}),gt(c=>{let u=!1;return k(c).pipe(cA(this.paramsInheritanceStrategy,this.environmentInjector),Ie({next:()=>u=!0,complete:()=>{u||this.cancelNavigationTransition(c,"",pt.NoDataFromResolver)}}))}),Ie(c=>{let u=new hf(c.id,this.urlSerializer.serialize(c.extractedUrl),this.urlSerializer.serialize(c.urlAfterRedirects),c.targetSnapshot);this.events.next(u)}))}),nf(l=>{let c=u=>{let d=[];u.routeConfig?.loadComponent&&!u.routeConfig._loadedComponent&&d.push(this.configLoader.loadComponent(u.routeConfig).pipe(Ie(h=>{u.component=h}),J(()=>{})));for(let h of u.children)d.push(...c(h));return d};return rs(c(l.targetSnapshot.root)).pipe(Tn(null),an(1))}),nf(()=>this.afterPreactivation()),gt(()=>{let{currentSnapshot:l,targetSnapshot:c}=s,u=this.createViewTransition?.(this.environmentInjector,l.root,c.root);return u?Ce(u).pipe(J(()=>s)):k(s)}),J(l=>{let c=CT(e.routeReuseStrategy,l.targetSnapshot,l.currentRouterState);return this.currentTransition=s=ae(S({},l),{targetRouterState:c}),this.currentNavigation.targetRouterState=c,s}),Ie(()=>{this.events.next(new Bs)}),ST(this.rootContexts,e.routeReuseStrategy,l=>this.events.next(l),this.inputBindingEnabled),an(1),Ie({next:l=>{o=!0,this.lastSuccessfulNavigation=this.currentNavigation,this.events.next(new wn(l.id,this.urlSerializer.serialize(l.extractedUrl),this.urlSerializer.serialize(l.urlAfterRedirects))),this.titleStrategy?.updateTitle(l.targetRouterState.snapshot),l.resolve(!0)},complete:()=>{o=!0}}),pu(this.transitionAbortSubject.pipe(Ie(l=>{throw l}))),ss(()=>{!o&&!a&&this.cancelNavigationTransition(s,"",pt.SupersededByNewNavigation),this.currentTransition?.id===s.id&&(this.currentNavigation=null,this.currentTransition=null)}),On(l=>{if(a=!0,yw(l))this.events.next(new yn(s.id,this.urlSerializer.serialize(s.extractedUrl),l.message,l.cancellationCode)),MT(l)?this.events.next(new Lr(l.url,l.navigationBehaviorOptions)):s.resolve(!1);else{let c=new Hs(s.id,this.urlSerializer.serialize(s.extractedUrl),l,s.targetSnapshot??void 0);try{let u=qt(this.environmentInjector,()=>this.navigationErrorHandler?.(c));if(u instanceof $s){let{message:d,cancellationCode:h}=Bl(this.urlSerializer,u);this.events.next(new yn(s.id,this.urlSerializer.serialize(s.extractedUrl),d,h)),this.events.next(new Lr(u.redirectTo,u.navigationBehaviorOptions))}else{this.events.next(c);let d=e.errorHandler(l);s.resolve(!!d)}}catch(u){this.options.resolveNavigationPromiseOnError?s.resolve(!1):s.reject(u)}}return ot}))}))}cancelNavigationTransition(e,i,r){let s=new yn(e.id,this.urlSerializer.serialize(e.extractedUrl),i,r);this.events.next(s),e.resolve(!1)}isUpdatingInternalState(){return this.currentTransition?.extractedUrl.toString()!==this.currentTransition?.currentUrlTree.toString()}isUpdatedBrowserUrl(){let e=this.urlHandlingStrategy.extract(this.urlSerializer.parse(this.location.path(!0))),i=this.currentNavigation?.targetBrowserUrl??this.currentNavigation?.extractedUrl;return e.toString()!==i?.toString()&&!this.currentNavigation?.extras.skipLocationChange}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})();function DA(t){return t!==Ls}var _A=(()=>{class t{static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:()=>E(CA),providedIn:"root"})}}return t})(),Of=class{shouldDetach(n){return!1}store(n,e){}shouldAttach(n){return!1}retrieve(n){return null}shouldReuseRoute(n,e){return n.routeConfig===e.routeConfig}},CA=(()=>{class t extends Of{static{this.\u0275fac=(()=>{let e;return function(r){return(e||(e=Ud(t)))(r||t)}})()}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})(),Iw=(()=>{class t{static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:()=>E(xA),providedIn:"root"})}}return t})(),xA=(()=>{class t extends Iw{constructor(){super(...arguments),this.location=E(Cr),this.urlSerializer=E(qs),this.options=E(Ks,{optional:!0})||{},this.canceledNavigationResolution=this.options.canceledNavigationResolution||"replace",this.urlHandlingStrategy=E(Rf),this.urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred",this.currentUrlTree=new bn,this.rawUrlTree=this.currentUrlTree,this.currentPageId=0,this.lastSuccessfulId=-1,this.routerState=fw(null),this.stateMemento=this.createStateMemento()}getCurrentUrlTree(){return this.currentUrlTree}getRawUrlTree(){return this.rawUrlTree}restoredState(){return this.location.getState()}get browserPageId(){return this.canceledNavigationResolution!=="computed"?this.currentPageId:this.restoredState()?.\u0275routerPageId??this.currentPageId}getRouterState(){return this.routerState}createStateMemento(){return{rawUrlTree:this.rawUrlTree,currentUrlTree:this.currentUrlTree,routerState:this.routerState}}registerNonRouterCurrentEntryChangeListener(e){return this.location.subscribe(i=>{i.type==="popstate"&&e(i.url,i.state)})}handleRouterEvent(e,i){if(e instanceof Pr)this.stateMemento=this.createStateMemento();else if(e instanceof zn)this.rawUrlTree=i.initialUrl;else if(e instanceof Pl){if(this.urlUpdateStrategy==="eager"&&!i.extras.skipLocationChange){let r=this.urlHandlingStrategy.merge(i.finalUrl,i.initialUrl);this.setBrowserUrl(i.targetBrowserUrl??r,i)}}else e instanceof Bs?(this.currentUrlTree=i.finalUrl,this.rawUrlTree=this.urlHandlingStrategy.merge(i.finalUrl,i.initialUrl),this.routerState=i.targetRouterState,this.urlUpdateStrategy==="deferred"&&!i.extras.skipLocationChange&&this.setBrowserUrl(i.targetBrowserUrl??this.rawUrlTree,i)):e instanceof yn&&(e.code===pt.GuardRejected||e.code===pt.NoDataFromResolver)?this.restoreHistory(i):e instanceof Hs?this.restoreHistory(i,!0):e instanceof wn&&(this.lastSuccessfulId=e.id,this.currentPageId=this.browserPageId)}setBrowserUrl(e,i){let r=e instanceof bn?this.urlSerializer.serialize(e):e;if(this.location.isCurrentPathEqualTo(r)||i.extras.replaceUrl){let s=this.browserPageId,o=S(S({},i.extras.state),this.generateNgRouterState(i.id,s));this.location.replaceState(r,"",o)}else{let s=S(S({},i.extras.state),this.generateNgRouterState(i.id,this.browserPageId+1));this.location.go(r,"",s)}}restoreHistory(e,i=!1){if(this.canceledNavigationResolution==="computed"){let r=this.browserPageId,s=this.currentPageId-r;s!==0?this.location.historyGo(s):this.currentUrlTree===e.finalUrl&&s===0&&(this.resetState(e),this.resetUrlToCurrentUrlTree())}else this.canceledNavigationResolution==="replace"&&(i&&this.resetState(e),this.resetUrlToCurrentUrlTree())}resetState(e){this.routerState=this.stateMemento.routerState,this.currentUrlTree=this.stateMemento.currentUrlTree,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,e.finalUrl??this.rawUrlTree)}resetUrlToCurrentUrlTree(){this.location.replaceState(this.urlSerializer.serialize(this.rawUrlTree),"",this.generateNgRouterState(this.lastSuccessfulId,this.currentPageId))}generateNgRouterState(e,i){return this.canceledNavigationResolution==="computed"?{navigationId:e,\u0275routerPageId:i}:{navigationId:e}}static{this.\u0275fac=(()=>{let e;return function(r){return(e||(e=Ud(t)))(r||t)}})()}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})(),ks=function(t){return t[t.COMPLETE=0]="COMPLETE",t[t.FAILED=1]="FAILED",t[t.REDIRECTING=2]="REDIRECTING",t}(ks||{});function Ow(t,n){t.events.pipe(Xe(e=>e instanceof wn||e instanceof yn||e instanceof Hs||e instanceof zn),J(e=>e instanceof wn||e instanceof zn?ks.COMPLETE:(e instanceof yn?e.code===pt.Redirect||e.code===pt.SupersededByNewNavigation:!1)?ks.REDIRECTING:ks.FAILED),Xe(e=>e!==ks.REDIRECTING),an(1)).subscribe(()=>{n()})}function EA(t){throw t}var MA={paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"},SA={paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"},Ti=(()=>{class t{get currentUrlTree(){return this.stateManager.getCurrentUrlTree()}get rawUrlTree(){return this.stateManager.getRawUrlTree()}get events(){return this._events}get routerState(){return this.stateManager.getRouterState()}constructor(){this.disposed=!1,this.console=E(al),this.stateManager=E(Iw),this.options=E(Ks,{optional:!0})||{},this.pendingTasks=E(yr),this.urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred",this.navigationTransitions=E(kf),this.urlSerializer=E(qs),this.location=E(Cr),this.urlHandlingStrategy=E(Rf),this._events=new Ee,this.errorHandler=this.options.errorHandler||EA,this.navigated=!1,this.routeReuseStrategy=E(_A),this.onSameUrlNavigation=this.options.onSameUrlNavigation||"ignore",this.config=E($l,{optional:!0})?.flat()??[],this.componentInputBindingEnabled=!!E(Wl,{optional:!0}),this.eventsSubscription=new we,this.resetConfig(this.config),this.navigationTransitions.setupNavigations(this,this.currentUrlTree,this.routerState).subscribe({error:e=>{this.console.warn(e)}}),this.subscribeToNavigationEvents()}subscribeToNavigationEvents(){let e=this.navigationTransitions.events.subscribe(i=>{try{let r=this.navigationTransitions.currentTransition,s=this.navigationTransitions.currentNavigation;if(r!==null&&s!==null){if(this.stateManager.handleRouterEvent(i,s),i instanceof yn&&i.code!==pt.Redirect&&i.code!==pt.SupersededByNewNavigation)this.navigated=!0;else if(i instanceof wn)this.navigated=!0;else if(i instanceof Lr){let o=i.navigationBehaviorOptions,a=this.urlHandlingStrategy.merge(i.url,r.currentRawUrl),l=S({browserUrl:r.extras.browserUrl,info:r.extras.info,skipLocationChange:r.extras.skipLocationChange,replaceUrl:r.extras.replaceUrl||this.urlUpdateStrategy==="eager"||DA(r.source)},o);this.scheduleNavigation(a,Ls,null,l,{resolve:r.resolve,reject:r.reject,promise:r.promise})}}OA(i)&&this._events.next(i)}catch(r){this.navigationTransitions.transitionAbortSubject.next(r)}});this.eventsSubscription.add(e)}resetRootComponentType(e){this.routerState.root.component=e,this.navigationTransitions.rootComponentType=e}initialNavigation(){this.setUpLocationChangeListener(),this.navigationTransitions.hasRequestedNavigation||this.navigateToSyncWithBrowser(this.location.path(!0),Ls,this.stateManager.restoredState())}setUpLocationChangeListener(){this.nonRouterCurrentEntryChangeSubscription??=this.stateManager.registerNonRouterCurrentEntryChangeListener((e,i)=>{setTimeout(()=>{this.navigateToSyncWithBrowser(e,"popstate",i)},0)})}navigateToSyncWithBrowser(e,i,r){let s={replaceUrl:!0},o=r?.navigationId?r:null;if(r){let l=S({},r);delete l.navigationId,delete l.\u0275routerPageId,Object.keys(l).length!==0&&(s.state=l)}let a=this.parseUrl(e);this.scheduleNavigation(a,i,o,s)}get url(){return this.serializeUrl(this.currentUrlTree)}getCurrentNavigation(){return this.navigationTransitions.currentNavigation}get lastSuccessfulNavigation(){return this.navigationTransitions.lastSuccessfulNavigation}resetConfig(e){this.config=e.map(Af),this.navigated=!1}ngOnDestroy(){this.dispose()}dispose(){this.navigationTransitions.complete(),this.nonRouterCurrentEntryChangeSubscription&&(this.nonRouterCurrentEntryChangeSubscription.unsubscribe(),this.nonRouterCurrentEntryChangeSubscription=void 0),this.disposed=!0,this.eventsSubscription.unsubscribe()}createUrlTree(e,i={}){let{relativeTo:r,queryParams:s,fragment:o,queryParamsHandling:a,preserveFragment:l}=i,c=l?this.currentUrlTree.fragment:o,u=null;switch(a??this.options.defaultQueryParamsHandling){case"merge":u=S(S({},this.currentUrlTree.queryParams),s);break;case"preserve":u=this.currentUrlTree.queryParams;break;default:u=s||null}u!==null&&(u=this.removeEmptyProps(u));let d;try{let h=r?r.snapshot:this.routerState.snapshot.root;d=cw(h)}catch{(typeof e[0]!="string"||e[0][0]!=="/")&&(e=[]),d=this.currentUrlTree.root}return uw(d,e,u,c??null)}navigateByUrl(e,i={skipLocationChange:!1}){let r=Vs(e)?e:this.parseUrl(e),s=this.urlHandlingStrategy.merge(r,this.rawUrlTree);return this.scheduleNavigation(s,Ls,null,i)}navigate(e,i={skipLocationChange:!1}){return IA(e),this.navigateByUrl(this.createUrlTree(e,i),i)}serializeUrl(e){return this.urlSerializer.serialize(e)}parseUrl(e){try{return this.urlSerializer.parse(e)}catch{return this.urlSerializer.parse("/")}}isActive(e,i){let r;if(i===!0?r=S({},MA):i===!1?r=S({},SA):r=i,Vs(e))return $b(this.currentUrlTree,e,r);let s=this.parseUrl(e);return $b(this.currentUrlTree,s,r)}removeEmptyProps(e){return Object.entries(e).reduce((i,[r,s])=>(s!=null&&(i[r]=s),i),{})}scheduleNavigation(e,i,r,s,o){if(this.disposed)return Promise.resolve(!1);let a,l,c;o?(a=o.resolve,l=o.reject,c=o.promise):c=new Promise((d,h)=>{a=d,l=h});let u=this.pendingTasks.add();return Ow(this,()=>{queueMicrotask(()=>this.pendingTasks.remove(u))}),this.navigationTransitions.handleNavigationRequest({source:i,restoredState:r,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,rawUrl:e,extras:s,resolve:a,reject:l,promise:c,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),c.catch(d=>Promise.reject(d))}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})();function IA(t){for(let n=0;n{class t{constructor(e,i,r,s,o){this.router=e,this.injector=r,this.preloadingStrategy=s,this.loader=o}setUpPreloading(){this.subscription=this.router.events.pipe(Xe(e=>e instanceof wn),li(()=>this.preload())).subscribe(()=>{})}preload(){return this.processRoutes(this.injector,this.router.config)}ngOnDestroy(){this.subscription&&this.subscription.unsubscribe()}processRoutes(e,i){let r=[];for(let s of i){s.providers&&!s._injector&&(s._injector=nl(s.providers,e,`Route: ${s.path}`));let o=s._injector??e,a=s._loadedInjector??o;(s.loadChildren&&!s._loadedRoutes&&s.canLoad===void 0||s.loadComponent&&!s._loadedComponent)&&r.push(this.preloadConfig(o,s)),(s.children||s._loadedRoutes)&&r.push(this.processRoutes(a,s.children??s._loadedRoutes))}return Ce(r).pipe(Qi())}preloadConfig(e,i){return this.preloadingStrategy.preload(i,()=>{let r;i.loadChildren&&i.canLoad===void 0?r=this.loader.loadChildren(e,i):r=k(null);let s=r.pipe(Se(o=>o===null?k(void 0):(i._loadedRoutes=o.routes,i._loadedInjector=o.injector,this.processRoutes(o.injector??e,o.routes))));if(i.loadComponent&&!i._loadedComponent){let o=this.loader.loadComponent(i);return Ce([s,o]).pipe(Qi())}else return s})}static{this.\u0275fac=function(i){return new(i||t)(R(Ti),R(dl),R(lt),R(zl),R(Nf))}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})(),Tw=new N(""),AA=(()=>{class t{constructor(e,i,r,s,o={}){this.urlSerializer=e,this.transitions=i,this.viewportScroller=r,this.zone=s,this.options=o,this.lastId=0,this.lastSource="imperative",this.restoredId=0,this.store={},o.scrollPositionRestoration||="disabled",o.anchorScrolling||="disabled"}init(){this.options.scrollPositionRestoration!=="disabled"&&this.viewportScroller.setHistoryScrollRestoration("manual"),this.routerEventsSubscription=this.createScrollEvents(),this.scrollEventsSubscription=this.consumeScrollEvents()}createScrollEvents(){return this.transitions.events.subscribe(e=>{e instanceof Pr?(this.store[this.lastId]=this.viewportScroller.getScrollPosition(),this.lastSource=e.navigationTrigger,this.restoredId=e.restoredState?e.restoredState.navigationId:0):e instanceof wn?(this.lastId=e.id,this.scheduleScrollEvent(e,this.urlSerializer.parse(e.urlAfterRedirects).fragment)):e instanceof zn&&e.code===kl.IgnoredSameUrlNavigation&&(this.lastSource=void 0,this.restoredId=0,this.scheduleScrollEvent(e,this.urlSerializer.parse(e.url).fragment))})}consumeScrollEvents(){return this.transitions.events.subscribe(e=>{e instanceof Ll&&(e.position?this.options.scrollPositionRestoration==="top"?this.viewportScroller.scrollToPosition([0,0]):this.options.scrollPositionRestoration==="enabled"&&this.viewportScroller.scrollToPosition(e.position):e.anchor&&this.options.anchorScrolling==="enabled"?this.viewportScroller.scrollToAnchor(e.anchor):this.options.scrollPositionRestoration!=="disabled"&&this.viewportScroller.scrollToPosition([0,0]))})}scheduleScrollEvent(e,i){this.zone.runOutsideAngular(()=>{setTimeout(()=>{this.zone.run(()=>{this.transitions.events.next(new Ll(e,this.lastSource==="popstate"?this.store[this.restoredId]:null,i))})},0)})}ngOnDestroy(){this.routerEventsSubscription?.unsubscribe(),this.scrollEventsSubscription?.unsubscribe()}static{this.\u0275fac=function(i){fy()}}static{this.\u0275prov=A({token:t,factory:t.\u0275fac})}}return t})();function NA(t){return t.routerState.root}function Xs(t,n){return{\u0275kind:t,\u0275providers:n}}function RA(){let t=E(bt);return n=>{let e=t.get(Un);if(n!==e.components[0])return;let i=t.get(Ti),r=t.get(Aw);t.get(Pf)===1&&i.initialNavigation(),t.get(Nw,null,G.Optional)?.setUpPreloading(),t.get(Tw,null,G.Optional)?.init(),i.resetRootComponentType(e.componentTypes[0]),r.closed||(r.next(),r.complete(),r.unsubscribe())}}var Aw=new N("",{factory:()=>new Ee}),Pf=new N("",{providedIn:"root",factory:()=>1});function kA(){return Xs(2,[{provide:Pf,useValue:0},{provide:ul,multi:!0,deps:[bt],useFactory:n=>{let e=n.get(vb,Promise.resolve());return()=>e.then(()=>new Promise(i=>{let r=n.get(Ti),s=n.get(Aw);Ow(r,()=>{i(!0)}),n.get(kf).afterPreactivation=()=>(i(!0),s.closed?k(void 0):s),r.initialNavigation()}))}}])}function PA(){return Xs(3,[{provide:ul,multi:!0,useFactory:()=>{let n=E(Ti);return()=>{n.setUpLocationChangeListener()}}},{provide:Pf,useValue:2}])}var Nw=new N("");function LA(t){return Xs(0,[{provide:Nw,useExisting:TA},{provide:zl,useExisting:t}])}function FA(){return Xs(8,[qb,{provide:Wl,useExisting:qb}])}function VA(t){let n=[{provide:Mw,useValue:yA},{provide:Sw,useValue:S({skipNextTransition:!!t?.skipInitialTransition},t)}];return Xs(9,n)}var Kb=new N("ROUTER_FORROOT_GUARD"),jA=[Cr,{provide:qs,useClass:kr},Ti,Zs,{provide:Fr,useFactory:NA,deps:[Ti]},Nf,[]],Lf=(()=>{class t{constructor(e){}static forRoot(e,i){return{ngModule:t,providers:[jA,[],{provide:$l,multi:!0,useValue:e},{provide:Kb,useFactory:$A,deps:[[Ti,new ys,new Fa]]},{provide:Ks,useValue:i||{}},i?.useHash?BA():UA(),HA(),i?.preloadingStrategy?LA(i.preloadingStrategy).\u0275providers:[],i?.initialNavigation?zA(i):[],i?.bindToComponentInputs?FA().\u0275providers:[],i?.enableViewTransitions?VA().\u0275providers:[],WA()]}}static forChild(e){return{ngModule:t,providers:[{provide:$l,multi:!0,useValue:e}]}}static{this.\u0275fac=function(i){return new(i||t)(R(Kb,8))}}static{this.\u0275mod=ut({type:t})}static{this.\u0275inj=ct({})}}return t})();function HA(){return{provide:Tw,useFactory:()=>{let t=E(Mb),n=E(ue),e=E(Ks),i=E(kf),r=E(qs);return e.scrollOffset&&t.setOffset(e.scrollOffset),new AA(r,i,t,n,e)}}}function BA(){return{provide:Si,useClass:bb}}function UA(){return{provide:Si,useClass:Fh}}function $A(t){return"guarded"}function zA(t){return[t.initialNavigation==="disabled"?PA().\u0275providers:[],t.initialNavigation==="enabledBlocking"?kA().\u0275providers:[]]}var Xb=new N("");function WA(){return[{provide:Xb,useFactory:RA},{provide:Ch,multi:!0,useExisting:Xb}]}var GA=[],ql=class t{static \u0275fac=function(e){return new(e||t)};static \u0275mod=ut({type:t});static \u0275inj=ct({imports:[Lf.forRoot(GA),Lf]})};var Yl=[{name:"refrigerator","daily-kWh":1.5167},{name:"washer","daily-kWh":.1722},{name:"dryer","daily-kWh":2.1361},{name:"ac","daily-kWh":7.7},{name:"oven","daily-kWh":.9359},{name:"light","daily-kWh":1.9389},{name:"tv","daily-kWh":.575},{name:"ceiling-fan","daily-kWh":.0889},{name:"porch-light","daily-kWh":.6083},{name:"solar-panel","daily-kWh":-1.75}];var YA=["energy_value_span"],Zl=class t{constructor(n,e){this.renderer=n;this.elRef=e;this.itemsMap=new Map}set itemToggled(n){n&&n.pipe().subscribe(e=>{this.onItemToggled(e)})}timeOfDay=2;rate=0;energyValue=0;energyValueString=this.energyValue.toString().padStart(6,"0")+" ";energyCost=0;energyCostString="0.0\xA2 ";delay=-1;duration=4e3;circleRadius=8;svg;path;pathLength;itemsMap;lastTimestamp=0;lastDirection=1;max_kWh=Yl.reduce((n,e)=>e["daily-kWh"]>0?n+e["daily-kWh"]:n,0);energyValueSpan;turnOffAll=new re;isCloseToZero(n,e=1e-4){return Math.abs(n)=15.67){this.turnEverythingOff();return}this.energyValueString=(this.energyValue<0?"-":" ")+Math.abs(this.energyValue).toFixed(4).toString().padStart(7,"0"),this.energyCost=this.energyValue*this.rate,this.energyCostString=this.formatCost(this.energyCost)}formatCost(n){if(Math.abs(n)<.01?n=0:n=Math.ceil(n),n>=100){let e=Math.floor(n/100),i=n%100;return`$${e}.${i.toString().padStart(2,"0")}`}else return n<0?"0\xA2":`${n}\xA2`}onTimeOfDayChange(n){this.timeOfDay=n,this.timeOfDay==0&&(this.rate=41.3998),this.timeOfDay==1&&(this.rate=62.0997),this.timeOfDay==2&&(this.rate=20.6999),this.energyCost=this.energyValue*this.rate,this.energyCostString=this.formatCost(this.energyCost)}onItemToggled(n){if(typeof n=="string"){let e=n.slice(0,-4);this.itemsMap.has(e)&&(this.energyValue-=this.itemsMap.get(e)??0,this.itemsMap.delete(n))}typeof n=="object"&&(this.itemsMap.set(n.name,n["daily-kWh"]),this.energyValue+=n["daily-kWh"]),this.renderEnergyValue()}ngOnChanges(n){n.itemToggled&&this.onItemToggled(this.itemToggled),n.timeOfDay&&this.onTimeOfDayChange(this.timeOfDay)}ngAfterViewInit(){this.svg=this.elRef.nativeElement.querySelector("svg"),this.path=this.elRef.nativeElement.querySelector("#house-to-grid"),this.pathLength=this.path.getTotalLength(),requestAnimationFrame(()=>this.startAnimationFlow(performance.now()))}createCircle(){let n=document.createElementNS("http://www.w3.org/2000/svg","circle");n.setAttribute("r",this.circleRadius.toString()),n.setAttribute("fill","transparent"),this.svg.appendChild(n),this.animateCircle(n)}animateCircle(n){let e=performance.now(),i=()=>{let s=(performance.now()-e)/this.duration;if(s<.98){let o=this.path.getPointAtLength(this.pathLength-s*this.pathLength);this.energyValue<0||this.energyValue==0&&this.lastDirection==-1?(this.lastDirection=-1,o=this.path.getPointAtLength(s*this.pathLength)):this.lastDirection=1,n.setAttribute("cx",o.x.toString()),n.setAttribute("cy",o.y.toString()),n.setAttribute("fill","#ff0"),requestAnimationFrame(i)}else this.svg.removeChild(n)};requestAnimationFrame(i)}startAnimationFlow(n){this.delay!=-1&&n-this.lastTimestamp>=this.delay&&this.energyValue!==0&&(this.createCircle(),this.lastTimestamp=n),requestAnimationFrame(()=>this.startAnimationFlow(performance.now()))}turnEverythingOff(){this.turnOffAll.emit(),this.energyValue=0,this.itemsMap=new Map,this.renderEnergyValue()}static \u0275fac=function(e){return new(e||t)(Q(_t),Q(We))};static \u0275cmp=Fe({type:t,selectors:[["app-energy-meter"]],viewQuery:function(e,i){if(e&1&&Qe(YA,5),e&2){let r;Ve(r=je())&&(i.energyValueSpan=r.first)}},inputs:{itemToggled:"itemToggled",timeOfDay:"timeOfDay"},outputs:{turnOffAll:"turnOffAll"},features:[Rt],decls:28,vars:6,consts:[["energy_cost_span",""],["energy_value_span",""],["id","energy-meter"],["id","svg-path","width","800px","height","350px","viewBox","0 10 350 50","preserveAspectRatio","xMidYMid meet",1,"path"],["id","gradient","cx","50%","cy","50%","r","50%","fx","50%","fy","50%"],["offset","0%",2,"stop-color","#909090","stop-opacity","1"],["offset","30%",2,"stop-color","#595959","stop-opacity","1"],["offset","60%",2,"stop-color","#595959","stop-opacity","1"],["offset","100%",2,"stop-color","#909090","stop-opacity","1"],["id","shadow","x","-50%","y","-50%","width","200%","height","200%"],["dx","2","dy","4","stdDeviation","3","flood-color","black","flood-opacity","0.5"],["id","house-to-grid","d","M 0 10 L 90 10 Q 100 10 100 20 L 100 40 Q 100 50 110 50 L 280 50","stroke","url(#gradient)","fill","none","stroke-width","20px","filter","url(#shadow)"],["id","heco-meter"],["id","heco-meter-cost"],["id","energy-cost",3,"innerText"],["id","heco-rate"],["id","energy-rate"],["id","energy-rate-unit"],["id","heco-meter-text"],["id","energy-value",3,"innerText"],["id","energy-unit"],["id","grid"],["src","assets/images/energy-meter/grid.png","alt","grid","id","grid-img"]],template:function(e,i){e&1&&(L(0,"div",2),_v(),L(1,"svg",3)(2,"defs")(3,"linearGradient",4),le(4,"stop",5)(5,"stop",6)(6,"stop",7)(7,"stop",8),j(),L(8,"filter",9),le(9,"feDropShadow",10),j()(),le(10,"path",11),j(),Cv(),L(11,"div",12)(12,"div",13),le(13,"span",14,0),j(),L(15,"div",15)(16,"span",16),Bn(17),Qy(18,"number"),j(),L(19,"span",17),Bn(20,"\xA2/kWh"),j()(),L(21,"div",18),le(22,"span",19,1),L(24,"span",20),Bn(25,"kWh"),j()()(),L(26,"div",21),le(27,"img",22),j()()),e&2&&(q(13),Y("innerText",i.energyCostString),q(4),xs(Ky(18,3,i.rate,"1.2-2")),q(5),Y("innerText",i.energyValueString))},dependencies:[Eb],styles:['@font-face{font-family:digital;src:url("./media/digital-7-CXYRQQZV.ttf") format("truetype");font-weight:400;font-style:normal}#energy-meter[_ngcontent-%COMP%]{position:absolute;display:flex;flex-direction:row;left:calc(12% + 300px);bottom:-30px}#svg-path[_ngcontent-%COMP%]{overflow:visible}#heco-meter[_ngcontent-%COMP%]{position:relative;top:110px;left:-500px;display:flex;flex-direction:column;justify-content:flex-start;align-items:center;background-image:url("./media/meter-ARYQV2XQ.png");background-size:cover;width:200px;height:200px;border-radius:50%}#heco-meter-text[_ngcontent-%COMP%]{font-size:21px;font-family:digital;color:#000;margin:0;top:78px;left:55px;position:absolute}#heco-meter-cost[_ngcontent-%COMP%]{font-size:24px;color:#000;margin:20px 0 0}#heco-rate[_ngcontent-%COMP%]{font-size:14px;color:#000;margin:0}#energy-unit[_ngcontent-%COMP%]{font-family:Courier New,Courier,monospace;font-size:10px;text-align:right}#grid[_ngcontent-%COMP%]{position:absolute;bottom:70px;left:610px}#grid-img[_ngcontent-%COMP%]{height:200px}#energy-rate[_ngcontent-%COMP%]{font-family:digital}#energy-rate-unit[_ngcontent-%COMP%]{font-family:Courier New,Courier,monospace}#energy-cost[_ngcontent-%COMP%]{font-family:digital}.blink[_ngcontent-%COMP%]{animation:_ngcontent-%COMP%_blink-animation 1s steps(1) infinite}@keyframes _ngcontent-%COMP%_blink-animation{50%{visibility:hidden}}']})};var Xt=t=>({active:t}),Ql=class t{itemToggled=new re;solarPanelToggled=new re;isRefrigeratorOn=!1;isWasherOn=!1;isDryerOn=!1;isACOn=!1;isOvenOn=!1;isLightOn=!1;isTVOn=!1;isCeilingFanOn=!1;isPorchLightOn=!1;isSolarPanelOn=!1;refrigeratorOnElement;refrigeratorOffElement;washerOnElement;washerOffElement;dryerOnElement;dryerOffElement;acOnElement;acOffElement;ovenOnElement;ovenOffElement;lightOnElement;lightOffElement;tvOnElement;tvOffElement;ceilingfanOnElement;ceilingfanOffElement;porchlightOnElement;porchlightOffElement;applianceEnergy=Yl;ngOnInit(){this.preloadImages(),this.preloadAudio()}preloadImages(){["assets/images/house/refrigerator.png","assets/images/house/refrigerator_glow.png","assets/images/house/washer.png","assets/images/house/washer_glow.png","assets/images/house/dryer.png","assets/images/house/dryer_glow.png","assets/images/house/ac.png","assets/images/house/ac_glow.png","assets/images/house/oven.png","assets/images/house/oven_glow.png","assets/images/house/light.png","assets/images/house/light_glow.png","assets/images/house/tv.png","assets/images/house/tv_glow.png","assets/images/house/ceilingfan.png","assets/images/house/ceilingfan_glow.png","assets/images/house/porchlight.png","assets/images/house/porchlight_glow.png","assets/images/house/solarpanel.png","assets/images/house/solarpanel_glow.png"].forEach(e=>{let i=new Image;i.src=e})}preloadAudio(){this.refrigeratorOnElement=new Audio("assets/sounds/refrigerator-on.wav"),this.refrigeratorOffElement=new Audio("assets/sounds/refrigerator-off.wav"),this.washerOnElement=new Audio("assets/sounds/washer-on.wav"),this.washerOffElement=new Audio("assets/sounds/washer-off.wav"),this.dryerOnElement=new Audio("assets/sounds/dryer-on.wav"),this.dryerOffElement=new Audio("assets/sounds/dryer-off.wav"),this.acOnElement=new Audio("assets/sounds/ac-on.wav"),this.acOffElement=new Audio("assets/sounds/ac-off.wav"),this.ovenOnElement=new Audio("assets/sounds/oven-on.wav"),this.ovenOffElement=new Audio("assets/sounds/oven-off.wav"),this.lightOnElement=new Audio("assets/sounds/light-on.wav"),this.lightOffElement=new Audio("assets/sounds/light-off.wav"),this.tvOnElement=new Audio("assets/sounds/tv-on.wav"),this.tvOffElement=new Audio("assets/sounds/tv-off.wav"),this.ceilingfanOnElement=new Audio("assets/sounds/ceilingfan-on.wav"),this.ceilingfanOffElement=new Audio("assets/sounds/ceilingfan-off.wav"),this.porchlightOnElement=new Audio("assets/sounds/porchlight-on.wav"),this.porchlightOffElement=new Audio("assets/sounds/porchlight-off.wav")}toggleAppliance(n){let e=n.target,i=this.getApplianceState(e.id);if(e.id!=="solar-panel"&&this.playAudio(e.id),i){let r=this.getEnergyConsumption(e.id);this.itemToggled.emit(r)}else{let r=this.getEnergyConsumption(e.id);this.itemToggled.emit(r.name.concat("-off"))}}getApplianceState(n){switch(n){case"refrigerator":return this.isRefrigeratorOn=!this.isRefrigeratorOn,this.isRefrigeratorOn;case"washer":return this.isWasherOn=!this.isWasherOn,this.isWasherOn;case"dryer":return this.isDryerOn=!this.isDryerOn,this.isDryerOn;case"ac":return this.isACOn=!this.isACOn,this.isACOn;case"oven":return this.isOvenOn=!this.isOvenOn,this.isOvenOn;case"light":return this.isLightOn=!this.isLightOn,this.isLightOn;case"tv":return this.isTVOn=!this.isTVOn,this.isTVOn;case"ceiling-fan":return this.isCeilingFanOn=!this.isCeilingFanOn,this.isCeilingFanOn;case"porch-light":return this.isPorchLightOn=!this.isPorchLightOn,this.isPorchLightOn;case"solar-panel":return this.isSolarPanelOn=!this.isSolarPanelOn,this.isSolarPanelOn;default:return!1}}playAudio(n){switch(n){case"refrigerator":this.isRefrigeratorOn?(this.refrigeratorOffElement?.pause(),this.refrigeratorOnElement?.play(),this.refrigeratorOnElement.currentTime=0):(this.refrigeratorOnElement?.pause(),this.refrigeratorOffElement?.play(),this.refrigeratorOffElement.currentTime=0);break;case"washer":this.isWasherOn?(this.washerOffElement?.pause(),this.washerOnElement?.play(),this.washerOnElement.currentTime=0):(this.washerOnElement?.pause(),this.washerOffElement?.play(),this.washerOffElement.currentTime=0);break;case"dryer":this.isDryerOn?(this.dryerOffElement?.pause,this.dryerOnElement?.play(),this.dryerOnElement.currentTime=0):(this.dryerOnElement?.pause(),this.dryerOffElement?.play(),this.dryerOffElement.currentTime=0);break;case"ac":this.isACOn?(this.acOffElement?.pause(),this.acOnElement?.play(),this.acOnElement.currentTime=0):(this.acOnElement?.pause(),this.acOffElement?.play(),this.acOffElement.currentTime=0);break;case"oven":this.isOvenOn?(this.ovenOffElement?.pause,this.ovenOnElement?.play(),this.ovenOnElement.currentTime=0):(this.ovenOnElement?.pause(),this.ovenOffElement?.play(),this.ovenOffElement.currentTime=0);break;case"light":this.isLightOn?(this.lightOffElement?.pause(),this.lightOnElement?.play(),this.lightOnElement.currentTime=0):(this.lightOnElement?.pause(),this.lightOffElement?.play(),this.lightOffElement.currentTime=0);break;case"tv":this.isTVOn?(this.tvOffElement?.pause(),this.tvOnElement?.play(),this.tvOnElement.currentTime=0):(this.tvOnElement?.pause(),this.tvOffElement?.play(),this.tvOffElement.currentTime=0);break;case"ceiling-fan":this.isCeilingFanOn?(this.ceilingfanOffElement?.pause(),this.ceilingfanOnElement?.play(),this.ceilingfanOnElement.currentTime=0):(this.ceilingfanOnElement?.pause(),this.ceilingfanOffElement?.play(),this.ceilingfanOffElement.currentTime=0);break;case"porch-light":this.isPorchLightOn?(this.porchlightOffElement?.pause(),this.porchlightOnElement?.play(),this.porchlightOnElement.currentTime=0):(this.porchlightOnElement?.pause(),this.porchlightOffElement?.play(),this.porchlightOffElement.currentTime=0);break;default:break}}getEnergyConsumption(n){return this.applianceEnergy.find(e=>e.name===n)}turnOffAllAppliances(){this.isRefrigeratorOn=!1,this.isWasherOn=!1,this.isDryerOn=!1,this.isACOn=!1,this.isOvenOn=!1,this.isLightOn=!1,this.isTVOn=!1,this.isCeilingFanOn=!1,this.isPorchLightOn=!1,this.isSolarPanelOn=!1}static \u0275fac=function(e){return new(e||t)};static \u0275cmp=Fe({type:t,selectors:[["app-house"]],outputs:{itemToggled:"itemToggled",solarPanelToggled:"solarPanelToggled"},decls:24,vars:40,consts:[[1,"house-wrapper"],[1,"house-layout"],["src","assets/images/house/house.png","alt","House",1,"house-image"],[1,"solar-panel-wrapper"],["alt","Solar Panel","id","solar-panel",3,"click","src","ngClass"],[1,"house-controls"],[1,"house-appliance-wrapper"],["alt","Refrigerator","id","refrigerator",1,"house-appliance",3,"click","src","ngClass"],["alt","Washer","id","washer",1,"house-appliance",3,"click","src","ngClass"],["alt","Dryer","id","dryer",1,"house-appliance",3,"click","src","ngClass"],["alt","AC","id","ac",1,"house-appliance",3,"click","src","ngClass"],["alt","Oven","id","oven",1,"house-appliance",3,"click","src","ngClass"],["alt","Light","id","light",1,"house-appliance",3,"click","src","ngClass"],["alt","TV","id","tv",1,"house-appliance",3,"click","src","ngClass"],["alt","Ceiling Fan","id","ceiling-fan",1,"house-appliance",3,"click","src","ngClass"],["alt","Porch Light","id","porch-light",1,"house-appliance",3,"click","src","ngClass"]],template:function(e,i){e&1&&(L(0,"div",0)(1,"div",1),le(2,"img",2),L(3,"div",3)(4,"img",4),xe("click",function(s){return i.toggleAppliance(s)}),j()(),L(5,"div",5)(6,"div",6)(7,"img",7),xe("click",function(s){return i.toggleAppliance(s)}),j()(),L(8,"div",6)(9,"img",8),xe("click",function(s){return i.toggleAppliance(s)}),j()(),L(10,"div",6)(11,"img",9),xe("click",function(s){return i.toggleAppliance(s)}),j()(),L(12,"div",6)(13,"img",10),xe("click",function(s){return i.toggleAppliance(s)}),j()(),L(14,"div",6)(15,"img",11),xe("click",function(s){return i.toggleAppliance(s)}),j()(),L(16,"div",6)(17,"img",12),xe("click",function(s){return i.toggleAppliance(s)}),j()(),L(18,"div",6)(19,"img",13),xe("click",function(s){return i.toggleAppliance(s)}),j()(),L(20,"div",6)(21,"img",14),xe("click",function(s){return i.toggleAppliance(s)}),j()(),L(22,"div",6)(23,"img",15),xe("click",function(s){return i.toggleAppliance(s)}),j()()()()()),e&2&&(q(4),Y("src",i.isSolarPanelOn?"assets/images/house/solarpanel_glow.png":"assets/images/house/solarpanel.png",kt)("ngClass",dt(20,Xt,i.isSolarPanelOn)),q(3),Y("src",i.isRefrigeratorOn?"assets/images/house/refrigerator_glow.png":"assets/images/house/refrigerator.png",kt)("ngClass",dt(22,Xt,i.isRefrigeratorOn)),q(2),Y("src",i.isWasherOn?"assets/images/house/washer_glow.png":"assets/images/house/washer.png",kt)("ngClass",dt(24,Xt,i.isWasherOn)),q(2),Y("src",i.isDryerOn?"assets/images/house/dryer_glow.png":"assets/images/house/dryer.png",kt)("ngClass",dt(26,Xt,i.isDryerOn)),q(2),Y("src",i.isACOn?"assets/images/house/ac_glow.png":"assets/images/house/ac.png",kt)("ngClass",dt(28,Xt,i.isACOn)),q(2),Y("src",i.isOvenOn?"assets/images/house/oven_glow.png":"assets/images/house/oven.png",kt)("ngClass",dt(30,Xt,i.isOvenOn)),q(2),Y("src",i.isLightOn?"assets/images/house/light_glow.png":"assets/images/house/light.png",kt)("ngClass",dt(32,Xt,i.isLightOn)),q(2),Y("src",i.isTVOn?"assets/images/house/tv_glow.png":"assets/images/house/tv.png",kt)("ngClass",dt(34,Xt,i.isTVOn)),q(2),Y("src",i.isCeilingFanOn?"assets/images/house/ceilingfan_glow.png":"assets/images/house/ceilingfan.png",kt)("ngClass",dt(36,Xt,i.isCeilingFanOn)),q(2),Y("src",i.isPorchLightOn?"assets/images/house/porchlight_glow.png":"assets/images/house/porchlight.png",kt)("ngClass",dt(38,Xt,i.isPorchLightOn)))},dependencies:[ml],styles:[".house-wrapper[_ngcontent-%COMP%]{position:absolute;bottom:calc(2% + 471px);left:12%}.house-image[_ngcontent-%COMP%]{position:absolute}.house-controls[_ngcontent-%COMP%]{position:relative}.house-appliance[_ngcontent-%COMP%]{position:absolute;cursor:pointer}#solar-panel[_ngcontent-%COMP%]{position:absolute;cursor:pointer;width:170px;top:-24px;left:305px}.house-controls[_ngcontent-%COMP%] #refrigerator[_ngcontent-%COMP%]{top:353px;left:146px;width:70px}.house-controls[_ngcontent-%COMP%] #oven[_ngcontent-%COMP%]{top:382px;left:101px;width:60px}.house-controls[_ngcontent-%COMP%] #washer[_ngcontent-%COMP%]{top:233px;left:268px;width:52px}.house-controls[_ngcontent-%COMP%] #dryer[_ngcontent-%COMP%]{top:233px;left:308px;width:52px}.house-controls[_ngcontent-%COMP%] #ac[_ngcontent-%COMP%]{top:150px;left:152px;width:100px}.house-controls[_ngcontent-%COMP%] #tv[_ngcontent-%COMP%]{top:342px;left:215px;width:113px}.house-controls[_ngcontent-%COMP%] #light[_ngcontent-%COMP%]{width:42px;top:139px;left:77px}.house-controls[_ngcontent-%COMP%] #porch-light[_ngcontent-%COMP%]{top:295px;left:-30px;width:45px}.house-controls[_ngcontent-%COMP%] #ceiling-fan[_ngcontent-%COMP%]{top:297px;left:335px;width:85px}@keyframes _ngcontent-%COMP%_wiggle{25%{transform:rotate(3deg)}75%{transform:rotate(-3deg)}}"]})};var Kl=class t{timeValue=new re;timeOfDay=2;ngAfterViewInit(){this.timeValue.emit(this.timeOfDay)}daytimeSlider={value:this.timeOfDay,options:{floor:0,ceil:2,vertical:!0,showTicksValues:!1,showTicks:!0,stepsArray:[{value:0,legend:'Night MoonOvernight
(9pm - 9am)'},{value:1,legend:'Evening SunEvening
Peak
(5pm - 9pm)'},{value:2,legend:'Morning SunDaytime
(9am - 5pm)'}],hideLimitLabels:!0,hidePointerLabels:!0,animateOnMove:!0}};onValueChange(n){this.timeOfDay=n,this.timeValue.emit(n)}static \u0275fac=function(e){return new(e||t)};static \u0275cmp=Fe({type:t,selectors:[["app-day-night-slider"]],outputs:{timeValue:"timeValue"},decls:5,vars:2,consts:[["slider",""],[1,"slider-wrapper"],[1,"slider-layout",2,"height","70vh"],[1,"slider-container",2,"height","100%","display","flex","align-items","center"],[3,"valueChange","value","options"]],template:function(e,i){if(e&1){let r=sl();L(0,"div",1)(1,"div",2)(2,"div",3)(3,"ngx-slider",4,0),bh("valueChange",function(o){return Di(r),Wy(i.daytimeSlider.value,o)||(i.daytimeSlider.value=o),_i(o)}),xe("valueChange",function(o){return Di(r),_i(i.onValueChange(o))}),j()()()()}e&2&&(q(3),yh("value",i.daytimeSlider.value),Y("options",i.daytimeSlider.options))},dependencies:[Xh],styles:[".slider-wrapper[_ngcontent-%COMP%]{position:absolute;display:flex;flex-direction:row;justify-content:flex-start;align-items:center;margin-left:95px;height:100%;top:0}.slider-container[_ngcontent-%COMP%]{display:flex;align-items:center;position:relative}"]})};function no(t){return t+.5|0}var Gn=(t,n,e)=>Math.max(Math.min(t,e),n);function eo(t){return Gn(no(t*2.55),0,255)}function qn(t){return Gn(no(t*255),0,255)}function Dn(t){return Gn(no(t/2.55)/100,0,1)}function kw(t){return Gn(no(t*100),0,100)}var Et={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,a:10,b:11,c:12,d:13,e:14,f:15},Vf=[..."0123456789ABCDEF"],XA=t=>Vf[t&15],JA=t=>Vf[(t&240)>>4]+Vf[t&15],Xl=t=>(t&240)>>4===(t&15),eN=t=>Xl(t.r)&&Xl(t.g)&&Xl(t.b)&&Xl(t.a);function tN(t){var n=t.length,e;return t[0]==="#"&&(n===4||n===5?e={r:255&Et[t[1]]*17,g:255&Et[t[2]]*17,b:255&Et[t[3]]*17,a:n===5?Et[t[4]]*17:255}:(n===7||n===9)&&(e={r:Et[t[1]]<<4|Et[t[2]],g:Et[t[3]]<<4|Et[t[4]],b:Et[t[5]]<<4|Et[t[6]],a:n===9?Et[t[7]]<<4|Et[t[8]]:255})),e}var nN=(t,n)=>t<255?n(t):"";function iN(t){var n=eN(t)?XA:JA;return t?"#"+n(t.r)+n(t.g)+n(t.b)+nN(t.a,n):void 0}var rN=/^(hsla?|hwb|hsv)\(\s*([-+.e\d]+)(?:deg)?[\s,]+([-+.e\d]+)%[\s,]+([-+.e\d]+)%(?:[\s,]+([-+.e\d]+)(%)?)?\s*\)$/;function Vw(t,n,e){let i=n*Math.min(e,1-e),r=(s,o=(s+t/30)%12)=>e-i*Math.max(Math.min(o-3,9-o,1),-1);return[r(0),r(8),r(4)]}function sN(t,n,e){let i=(r,s=(r+t/60)%6)=>e-e*n*Math.max(Math.min(s,4-s,1),0);return[i(5),i(3),i(1)]}function oN(t,n,e){let i=Vw(t,1,.5),r;for(n+e>1&&(r=1/(n+e),n*=r,e*=r),r=0;r<3;r++)i[r]*=1-n-e,i[r]+=n;return i}function aN(t,n,e,i,r){return t===r?(n-e)/i+(n.5?u/(2-s-o):u/(s+o),l=aN(e,i,r,u,s),l=l*60+.5),[l|0,c||0,a]}function Hf(t,n,e,i){return(Array.isArray(n)?t(n[0],n[1],n[2]):t(n,e,i)).map(qn)}function Bf(t,n,e){return Hf(Vw,t,n,e)}function lN(t,n,e){return Hf(oN,t,n,e)}function cN(t,n,e){return Hf(sN,t,n,e)}function jw(t){return(t%360+360)%360}function uN(t){let n=rN.exec(t),e=255,i;if(!n)return;n[5]!==i&&(e=n[6]?eo(+n[5]):qn(+n[5]));let r=jw(+n[2]),s=+n[3]/100,o=+n[4]/100;return n[1]==="hwb"?i=lN(r,s,o):n[1]==="hsv"?i=cN(r,s,o):i=Bf(r,s,o),{r:i[0],g:i[1],b:i[2],a:e}}function dN(t,n){var e=jf(t);e[0]=jw(e[0]+n),e=Bf(e),t.r=e[0],t.g=e[1],t.b=e[2]}function hN(t){if(!t)return;let n=jf(t),e=n[0],i=kw(n[1]),r=kw(n[2]);return t.a<255?`hsla(${e}, ${i}%, ${r}%, ${Dn(t.a)})`:`hsl(${e}, ${i}%, ${r}%)`}var Pw={x:"dark",Z:"light",Y:"re",X:"blu",W:"gr",V:"medium",U:"slate",A:"ee",T:"ol",S:"or",B:"ra",C:"lateg",D:"ights",R:"in",Q:"turquois",E:"hi",P:"ro",O:"al",N:"le",M:"de",L:"yello",F:"en",K:"ch",G:"arks",H:"ea",I:"ightg",J:"wh"},Lw={OiceXe:"f0f8ff",antiquewEte:"faebd7",aqua:"ffff",aquamarRe:"7fffd4",azuY:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"0",blanKedOmond:"ffebcd",Xe:"ff",XeviTet:"8a2be2",bPwn:"a52a2a",burlywood:"deb887",caMtXe:"5f9ea0",KartYuse:"7fff00",KocTate:"d2691e",cSO:"ff7f50",cSnflowerXe:"6495ed",cSnsilk:"fff8dc",crimson:"dc143c",cyan:"ffff",xXe:"8b",xcyan:"8b8b",xgTMnPd:"b8860b",xWay:"a9a9a9",xgYF:"6400",xgYy:"a9a9a9",xkhaki:"bdb76b",xmagFta:"8b008b",xTivegYF:"556b2f",xSange:"ff8c00",xScEd:"9932cc",xYd:"8b0000",xsOmon:"e9967a",xsHgYF:"8fbc8f",xUXe:"483d8b",xUWay:"2f4f4f",xUgYy:"2f4f4f",xQe:"ced1",xviTet:"9400d3",dAppRk:"ff1493",dApskyXe:"bfff",dimWay:"696969",dimgYy:"696969",dodgerXe:"1e90ff",fiYbrick:"b22222",flSOwEte:"fffaf0",foYstWAn:"228b22",fuKsia:"ff00ff",gaRsbSo:"dcdcdc",ghostwEte:"f8f8ff",gTd:"ffd700",gTMnPd:"daa520",Way:"808080",gYF:"8000",gYFLw:"adff2f",gYy:"808080",honeyMw:"f0fff0",hotpRk:"ff69b4",RdianYd:"cd5c5c",Rdigo:"4b0082",ivSy:"fffff0",khaki:"f0e68c",lavFMr:"e6e6fa",lavFMrXsh:"fff0f5",lawngYF:"7cfc00",NmoncEffon:"fffacd",ZXe:"add8e6",ZcSO:"f08080",Zcyan:"e0ffff",ZgTMnPdLw:"fafad2",ZWay:"d3d3d3",ZgYF:"90ee90",ZgYy:"d3d3d3",ZpRk:"ffb6c1",ZsOmon:"ffa07a",ZsHgYF:"20b2aa",ZskyXe:"87cefa",ZUWay:"778899",ZUgYy:"778899",ZstAlXe:"b0c4de",ZLw:"ffffe0",lime:"ff00",limegYF:"32cd32",lRF:"faf0e6",magFta:"ff00ff",maPon:"800000",VaquamarRe:"66cdaa",VXe:"cd",VScEd:"ba55d3",VpurpN:"9370db",VsHgYF:"3cb371",VUXe:"7b68ee",VsprRggYF:"fa9a",VQe:"48d1cc",VviTetYd:"c71585",midnightXe:"191970",mRtcYam:"f5fffa",mistyPse:"ffe4e1",moccasR:"ffe4b5",navajowEte:"ffdead",navy:"80",Tdlace:"fdf5e6",Tive:"808000",TivedBb:"6b8e23",Sange:"ffa500",SangeYd:"ff4500",ScEd:"da70d6",pOegTMnPd:"eee8aa",pOegYF:"98fb98",pOeQe:"afeeee",pOeviTetYd:"db7093",papayawEp:"ffefd5",pHKpuff:"ffdab9",peru:"cd853f",pRk:"ffc0cb",plum:"dda0dd",powMrXe:"b0e0e6",purpN:"800080",YbeccapurpN:"663399",Yd:"ff0000",Psybrown:"bc8f8f",PyOXe:"4169e1",saddNbPwn:"8b4513",sOmon:"fa8072",sandybPwn:"f4a460",sHgYF:"2e8b57",sHshell:"fff5ee",siFna:"a0522d",silver:"c0c0c0",skyXe:"87ceeb",UXe:"6a5acd",UWay:"708090",UgYy:"708090",snow:"fffafa",sprRggYF:"ff7f",stAlXe:"4682b4",tan:"d2b48c",teO:"8080",tEstN:"d8bfd8",tomato:"ff6347",Qe:"40e0d0",viTet:"ee82ee",JHt:"f5deb3",wEte:"ffffff",wEtesmoke:"f5f5f5",Lw:"ffff00",LwgYF:"9acd32"};function fN(){let t={},n=Object.keys(Lw),e=Object.keys(Pw),i,r,s,o,a;for(i=0;i>16&255,s>>8&255,s&255]}return t}var Jl;function pN(t){Jl||(Jl=fN(),Jl.transparent=[0,0,0,0]);let n=Jl[t.toLowerCase()];return n&&{r:n[0],g:n[1],b:n[2],a:n.length===4?n[3]:255}}var gN=/^rgba?\(\s*([-+.\d]+)(%)?[\s,]+([-+.e\d]+)(%)?[\s,]+([-+.e\d]+)(%)?(?:[\s,/]+([-+.e\d]+)(%)?)?\s*\)$/;function mN(t){let n=gN.exec(t),e=255,i,r,s;if(n){if(n[7]!==i){let o=+n[7];e=n[8]?eo(o):Gn(o*255,0,255)}return i=+n[1],r=+n[3],s=+n[5],i=255&(n[2]?eo(i):Gn(i,0,255)),r=255&(n[4]?eo(r):Gn(r,0,255)),s=255&(n[6]?eo(s):Gn(s,0,255)),{r:i,g:r,b:s,a:e}}}function vN(t){return t&&(t.a<255?`rgba(${t.r}, ${t.g}, ${t.b}, ${Dn(t.a)})`:`rgb(${t.r}, ${t.g}, ${t.b})`)}var Ff=t=>t<=.0031308?t*12.92:Math.pow(t,1/2.4)*1.055-.055,Hr=t=>t<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4);function yN(t,n,e){let i=Hr(Dn(t.r)),r=Hr(Dn(t.g)),s=Hr(Dn(t.b));return{r:qn(Ff(i+e*(Hr(Dn(n.r))-i))),g:qn(Ff(r+e*(Hr(Dn(n.g))-r))),b:qn(Ff(s+e*(Hr(Dn(n.b))-s))),a:t.a+e*(n.a-t.a)}}function ec(t,n,e){if(t){let i=jf(t);i[n]=Math.max(0,Math.min(i[n]+i[n]*e,n===0?360:1)),i=Bf(i),t.r=i[0],t.g=i[1],t.b=i[2]}}function Hw(t,n){return t&&Object.assign(n||{},t)}function Fw(t){var n={r:0,g:0,b:0,a:255};return Array.isArray(t)?t.length>=3&&(n={r:t[0],g:t[1],b:t[2],a:255},t.length>3&&(n.a=qn(t[3]))):(n=Hw(t,{r:0,g:0,b:0,a:1}),n.a=qn(n.a)),n}function bN(t){return t.charAt(0)==="r"?mN(t):uN(t)}var to=class t{constructor(n){if(n instanceof t)return n;let e=typeof n,i;e==="object"?i=Fw(n):e==="string"&&(i=tN(n)||pN(n)||bN(n)),this._rgb=i,this._valid=!!i}get valid(){return this._valid}get rgb(){var n=Hw(this._rgb);return n&&(n.a=Dn(n.a)),n}set rgb(n){this._rgb=Fw(n)}rgbString(){return this._valid?vN(this._rgb):void 0}hexString(){return this._valid?iN(this._rgb):void 0}hslString(){return this._valid?hN(this._rgb):void 0}mix(n,e){if(n){let i=this.rgb,r=n.rgb,s,o=e===s?.5:e,a=2*o-1,l=i.a-r.a,c=((a*l===-1?a:(a+l)/(1+a*l))+1)/2;s=1-c,i.r=255&c*i.r+s*r.r+.5,i.g=255&c*i.g+s*r.g+.5,i.b=255&c*i.b+s*r.b+.5,i.a=o*i.a+(1-o)*r.a,this.rgb=i}return this}interpolate(n,e){return n&&(this._rgb=yN(this._rgb,n._rgb,e)),this}clone(){return new t(this.rgb)}alpha(n){return this._rgb.a=qn(n),this}clearer(n){let e=this._rgb;return e.a*=1-n,this}greyscale(){let n=this._rgb,e=no(n.r*.3+n.g*.59+n.b*.11);return n.r=n.g=n.b=e,this}opaquer(n){let e=this._rgb;return e.a*=1+n,this}negate(){let n=this._rgb;return n.r=255-n.r,n.g=255-n.g,n.b=255-n.b,this}lighten(n){return ec(this._rgb,2,n),this}darken(n){return ec(this._rgb,2,-n),this}saturate(n){return ec(this._rgb,1,n),this}desaturate(n){return ec(this._rgb,1,-n),this}rotate(n){return dN(this._rgb,n),this}};function tn(){}var Kw=(()=>{let t=0;return()=>t++})();function te(t){return t===null||typeof t>"u"}function fe(t){if(Array.isArray&&Array.isArray(t))return!0;let n=Object.prototype.toString.call(t);return n.slice(0,7)==="[object"&&n.slice(-6)==="Array]"}function K(t){return t!==null&&Object.prototype.toString.call(t)==="[object Object]"}function be(t){return(typeof t=="number"||t instanceof Number)&&isFinite(+t)}function nt(t,n){return be(t)?t:n}function V(t,n){return typeof t>"u"?n:t}var Xw=(t,n)=>typeof t=="string"&&t.endsWith("%")?parseFloat(t)/100:+t/n,Wf=(t,n)=>typeof t=="string"&&t.endsWith("%")?parseFloat(t)/100*n:+t;function he(t,n,e){if(t&&typeof t.call=="function")return t.apply(e,n)}function oe(t,n,e,i){let r,s,o;if(fe(t))if(s=t.length,i)for(r=s-1;r>=0;r--)n.call(e,t[r],r);else for(r=0;rt,x:t=>t.x,y:t=>t.y};function _N(t){let n=t.split("."),e=[],i="";for(let r of n)i+=r,i.endsWith("\\")?i=i.slice(0,-1)+".":(e.push(i),i="");return e}function CN(t){let n=_N(t);return e=>{for(let i of n){if(i==="")break;e=e&&e[i]}return e}}function xn(t,n){return(Bw[n]||(Bw[n]=CN(n)))(t)}function lc(t){return t.charAt(0).toUpperCase()+t.slice(1)}var Wr=t=>typeof t<"u",_n=t=>typeof t=="function",Gf=(t,n)=>{if(t.size!==n.size)return!1;for(let e of t)if(!n.has(e))return!1;return!0};function e0(t){return t.type==="mouseup"||t.type==="click"||t.type==="contextmenu"}var pe=Math.PI,ge=2*pe,xN=ge+pe,sc=Number.POSITIVE_INFINITY,EN=pe/180,De=pe/2,Ai=pe/4,Uw=pe*2/3,Cn=Math.log10,Ft=Math.sign;function Gr(t,n,e){return Math.abs(t-n)r-s).pop(),n}function ki(t){return!isNaN(parseFloat(t))&&isFinite(t)}function n0(t,n){let e=Math.round(t);return e-n<=t&&e+n>=t}function Yf(t,n,e){let i,r,s;for(i=0,r=t.length;il&&c=Math.min(n,e)-i&&t<=Math.max(n,e)+i}function uc(t,n,e){e=e||(o=>t[o]1;)s=r+i>>1,e(s)?r=s:i=s;return{lo:r,hi:i}}var Jt=(t,n,e,i)=>uc(t,e,i?r=>{let s=t[r][n];return st[r][n]uc(t,e,i=>t[i][n]>=e);function s0(t,n,e){let i=0,r=t.length;for(;ii&&t[r-1]>e;)r--;return i>0||r{let i="_onData"+lc(e),r=t[e];Object.defineProperty(t,e,{configurable:!0,enumerable:!1,value(...s){let o=r.apply(this,s);return t._chartjs.listeners.forEach(a=>{typeof a[i]=="function"&&a[i](...s)}),o}})})}function Kf(t,n){let e=t._chartjs;if(!e)return;let i=e.listeners,r=i.indexOf(n);r!==-1&&i.splice(r,1),!(i.length>0)&&(o0.forEach(s=>{delete t[s]}),delete t._chartjs)}function Xf(t){let n=new Set(t);return n.size===t.length?t:Array.from(n)}var Jf=function(){return typeof window>"u"?function(t){return t()}:window.requestAnimationFrame}();function ep(t,n){let e=[],i=!1;return function(...r){e=r,i||(i=!0,Jf.call(window,()=>{i=!1,t.apply(n,e)}))}}function l0(t,n){let e;return function(...i){return n?(clearTimeout(e),e=setTimeout(t,n,i)):t.apply(this,i),n}}var dc=t=>t==="start"?"left":t==="end"?"right":"center",He=(t,n,e)=>t==="start"?n:t==="end"?e:(n+e)/2,c0=(t,n,e,i)=>t===(i?"left":"right")?e:t==="center"?(n+e)/2:n;function tp(t,n,e){let i=n.length,r=0,s=i;if(t._sorted){let{iScale:o,_parsed:a}=t,l=o.axis,{min:c,max:u,minDefined:d,maxDefined:h}=o.getUserBounds();d&&(r=Ne(Math.min(Jt(a,l,c).lo,e?i:Jt(n,l,o.getPixelForValue(c)).lo),0,i-1)),h?s=Ne(Math.max(Jt(a,o.axis,u,!0).hi+1,e?0:Jt(n,l,o.getPixelForValue(u),!0).hi+1),r,i)-r:s=i-r}return{start:r,count:s}}function np(t){let{xScale:n,yScale:e,_scaleRanges:i}=t,r={xmin:n.min,xmax:n.max,ymin:e.min,ymax:e.max};if(!i)return t._scaleRanges=r,!0;let s=i.xmin!==n.min||i.xmax!==n.max||i.ymin!==e.min||i.ymax!==e.max;return Object.assign(i,r),s}var tc=t=>t===0||t===1,$w=(t,n,e)=>-(Math.pow(2,10*(t-=1))*Math.sin((t-n)*ge/e)),zw=(t,n,e)=>Math.pow(2,-10*t)*Math.sin((t-n)*ge/e)+1,Br={linear:t=>t,easeInQuad:t=>t*t,easeOutQuad:t=>-t*(t-2),easeInOutQuad:t=>(t/=.5)<1?.5*t*t:-.5*(--t*(t-2)-1),easeInCubic:t=>t*t*t,easeOutCubic:t=>(t-=1)*t*t+1,easeInOutCubic:t=>(t/=.5)<1?.5*t*t*t:.5*((t-=2)*t*t+2),easeInQuart:t=>t*t*t*t,easeOutQuart:t=>-((t-=1)*t*t*t-1),easeInOutQuart:t=>(t/=.5)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2),easeInQuint:t=>t*t*t*t*t,easeOutQuint:t=>(t-=1)*t*t*t*t+1,easeInOutQuint:t=>(t/=.5)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2),easeInSine:t=>-Math.cos(t*De)+1,easeOutSine:t=>Math.sin(t*De),easeInOutSine:t=>-.5*(Math.cos(pe*t)-1),easeInExpo:t=>t===0?0:Math.pow(2,10*(t-1)),easeOutExpo:t=>t===1?1:-Math.pow(2,-10*t)+1,easeInOutExpo:t=>tc(t)?t:t<.5?.5*Math.pow(2,10*(t*2-1)):.5*(-Math.pow(2,-10*(t*2-1))+2),easeInCirc:t=>t>=1?t:-(Math.sqrt(1-t*t)-1),easeOutCirc:t=>Math.sqrt(1-(t-=1)*t),easeInOutCirc:t=>(t/=.5)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1),easeInElastic:t=>tc(t)?t:$w(t,.075,.3),easeOutElastic:t=>tc(t)?t:zw(t,.075,.3),easeInOutElastic(t){return tc(t)?t:t<.5?.5*$w(t*2,.1125,.45):.5+.5*zw(t*2-1,.1125,.45)},easeInBack(t){return t*t*((1.70158+1)*t-1.70158)},easeOutBack(t){return(t-=1)*t*((1.70158+1)*t+1.70158)+1},easeInOutBack(t){let n=1.70158;return(t/=.5)<1?.5*(t*t*(((n*=1.525)+1)*t-n)):.5*((t-=2)*t*(((n*=1.525)+1)*t+n)+2)},easeInBounce:t=>1-Br.easeOutBounce(1-t),easeOutBounce(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},easeInOutBounce:t=>t<.5?Br.easeInBounce(t*2)*.5:Br.easeOutBounce(t*2-1)*.5+.5};function ip(t){if(t&&typeof t=="object"){let n=t.toString();return n==="[object CanvasPattern]"||n==="[object CanvasGradient]"}return!1}function rp(t){return ip(t)?t:new to(t)}function Uf(t){return ip(t)?t:new to(t).saturate(.5).darken(.1).hexString()}var SN=["x","y","borderWidth","radius","tension"],IN=["color","borderColor","backgroundColor"];function ON(t){t.set("animation",{delay:void 0,duration:1e3,easing:"easeOutQuart",fn:void 0,from:void 0,loop:void 0,to:void 0,type:void 0}),t.describe("animation",{_fallback:!1,_indexable:!1,_scriptable:n=>n!=="onProgress"&&n!=="onComplete"&&n!=="fn"}),t.set("animations",{colors:{type:"color",properties:IN},numbers:{type:"number",properties:SN}}),t.describe("animations",{_fallback:"animation"}),t.set("transitions",{active:{animation:{duration:400}},resize:{animation:{duration:0}},show:{animations:{colors:{from:"transparent"},visible:{type:"boolean",duration:0}}},hide:{animations:{colors:{to:"transparent"},visible:{type:"boolean",easing:"linear",fn:n=>n|0}}}})}function TN(t){t.set("layout",{autoPadding:!0,padding:{top:0,right:0,bottom:0,left:0}})}var Ww=new Map;function AN(t,n){n=n||{};let e=t+JSON.stringify(n),i=Ww.get(e);return i||(i=new Intl.NumberFormat(t,n),Ww.set(e,i)),i}function Yr(t,n,e){return AN(n,e).format(t)}var u0={values(t){return fe(t)?t:""+t},numeric(t,n,e){if(t===0)return"0";let i=this.chart.options.locale,r,s=t;if(e.length>1){let c=Math.max(Math.abs(e[0].value),Math.abs(e[e.length-1].value));(c<1e-4||c>1e15)&&(r="scientific"),s=NN(t,e)}let o=Cn(Math.abs(s)),a=isNaN(o)?1:Math.max(Math.min(-1*Math.floor(o),20),0),l={notation:r,minimumFractionDigits:a,maximumFractionDigits:a};return Object.assign(l,this.options.ticks.format),Yr(t,i,l)},logarithmic(t,n,e){if(t===0)return"0";let i=e[n].significand||t/Math.pow(10,Math.floor(Cn(t)));return[1,2,3,5,10,15].includes(i)||n>.8*e.length?u0.numeric.call(this,t,n,e):""}};function NN(t,n){let e=n.length>3?n[2].value-n[1].value:n[1].value-n[0].value;return Math.abs(e)>=1&&t!==Math.floor(t)&&(e=t-Math.floor(t)),e}var oo={formatters:u0};function RN(t){t.set("scale",{display:!0,offset:!1,reverse:!1,beginAtZero:!1,bounds:"ticks",clip:!0,grace:0,grid:{display:!0,lineWidth:1,drawOnChartArea:!0,drawTicks:!0,tickLength:8,tickWidth:(n,e)=>e.lineWidth,tickColor:(n,e)=>e.color,offset:!1},border:{display:!0,dash:[],dashOffset:0,width:1},title:{display:!1,text:"",padding:{top:4,bottom:4}},ticks:{minRotation:0,maxRotation:50,mirror:!1,textStrokeWidth:0,textStrokeColor:"",padding:3,display:!0,autoSkip:!0,autoSkipPadding:3,labelOffset:0,callback:oo.formatters.values,minor:{},major:{},align:"center",crossAlign:"near",showLabelBackdrop:!1,backdropColor:"rgba(255, 255, 255, 0.75)",backdropPadding:2}}),t.route("scale.ticks","color","","color"),t.route("scale.grid","color","","borderColor"),t.route("scale.border","color","","borderColor"),t.route("scale.title","color","","color"),t.describe("scale",{_fallback:!1,_scriptable:n=>!n.startsWith("before")&&!n.startsWith("after")&&n!=="callback"&&n!=="parser",_indexable:n=>n!=="borderDash"&&n!=="tickBorderDash"&&n!=="dash"}),t.describe("scales",{_fallback:"scale"}),t.describe("scale.ticks",{_scriptable:n=>n!=="backdropPadding"&&n!=="callback",_indexable:n=>n!=="backdropPadding"})}var Zn=Object.create(null),hc=Object.create(null);function io(t,n){if(!n)return t;let e=n.split(".");for(let i=0,r=e.length;ii.chart.platform.getDevicePixelRatio(),this.elements={},this.events=["mousemove","mouseout","click","touchstart","touchmove"],this.font={family:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",size:12,style:"normal",lineHeight:1.2,weight:null},this.hover={},this.hoverBackgroundColor=(i,r)=>Uf(r.backgroundColor),this.hoverBorderColor=(i,r)=>Uf(r.borderColor),this.hoverColor=(i,r)=>Uf(r.color),this.indexAxis="x",this.interaction={mode:"nearest",intersect:!0,includeInvisible:!1},this.maintainAspectRatio=!0,this.onHover=null,this.onClick=null,this.parsing=!0,this.plugins={},this.responsive=!0,this.scale=void 0,this.scales={},this.showLine=!0,this.drawActiveElementsOnTop=!0,this.describe(n),this.apply(e)}set(n,e){return $f(this,n,e)}get(n){return io(this,n)}describe(n,e){return $f(hc,n,e)}override(n,e){return $f(Zn,n,e)}route(n,e,i,r){let s=io(this,n),o=io(this,i),a="_"+e;Object.defineProperties(s,{[a]:{value:s[e],writable:!0},[e]:{enumerable:!0,get(){let l=this[a],c=o[r];return K(l)?Object.assign({},c,l):V(l,c)},set(l){this[a]=l}}})}apply(n){n.forEach(e=>e(this))}},me=new zf({_scriptable:t=>!t.startsWith("on"),_indexable:t=>t!=="events",hover:{_fallback:"interaction"},interaction:{_scriptable:!1,_indexable:!1}},[ON,TN,RN]);function kN(t){return!t||te(t.size)||te(t.family)?null:(t.style?t.style+" ":"")+(t.weight?t.weight+" ":"")+t.size+"px "+t.family}function ro(t,n,e,i,r){let s=n[r];return s||(s=n[r]=t.measureText(r).width,e.push(r)),s>i&&(i=s),i}function d0(t,n,e,i){i=i||{};let r=i.data=i.data||{},s=i.garbageCollect=i.garbageCollect||[];i.font!==n&&(r=i.data={},s=i.garbageCollect=[],i.font=n),t.save(),t.font=n;let o=0,a=e.length,l,c,u,d,h;for(l=0;le.length){for(l=0;l0&&t.stroke()}}function en(t,n,e){return e=e||.5,!n||t&&t.x>n.left-e&&t.xn.top-e&&t.y0&&s.strokeColor!=="",l,c;for(t.save(),t.font=r.string,PN(t,s),l=0;l+t||0;function pc(t,n){let e={},i=K(n),r=i?Object.keys(n):n,s=K(t)?i?o=>V(t[o],t[n[o]]):o=>t[o]:()=>t;for(let o of r)e[o]=BN(s(o));return e}function ap(t){return pc(t,{top:"y",right:"x",bottom:"y",left:"x"})}function Xn(t){return pc(t,["topLeft","topRight","bottomLeft","bottomRight"])}function Be(t){let n=ap(t);return n.width=n.left+n.right,n.height=n.top+n.bottom,n}function Te(t,n){t=t||{},n=n||me.font;let e=V(t.size,n.size);typeof e=="string"&&(e=parseInt(e,10));let i=V(t.style,n.style);i&&!(""+i).match(jN)&&(console.warn('Invalid font style specified: "'+i+'"'),i=void 0);let r={family:V(t.family,n.family),lineHeight:HN(V(t.lineHeight,n.lineHeight),e),size:e,style:i,weight:V(t.weight,n.weight),string:""};return r.string=kN(r),r}function Qr(t,n,e,i){let r=!0,s,o,a;for(s=0,o=t.length;se&&a===0?0:a+l;return{min:o(i,-Math.abs(s)),max:o(r,s)}}function En(t,n){return Object.assign(Object.create(t),n)}function gc(t,n=[""],e,i,r=()=>t[0]){let s=e||t;typeof i>"u"&&(i=v0("_fallback",t));let o={[Symbol.toStringTag]:"Object",_cacheable:!0,_scopes:t,_rootScopes:s,_fallback:i,_getTarget:r,override:a=>gc([a,...t],n,s,i)};return new Proxy(o,{deleteProperty(a,l){return delete a[l],delete a._keys,delete t[0][l],!0},get(a,l){return g0(a,l,()=>ZN(l,n,t,a))},getOwnPropertyDescriptor(a,l){return Reflect.getOwnPropertyDescriptor(a._scopes[0],l)},getPrototypeOf(){return Reflect.getPrototypeOf(t[0])},has(a,l){return qw(a).includes(l)},ownKeys(a){return qw(a)},set(a,l,c){let u=a._storage||(a._storage=r());return a[l]=u[l]=c,delete a._keys,!0}})}function Ri(t,n,e,i){let r={_cacheable:!1,_proxy:t,_context:n,_subProxy:e,_stack:new Set,_descriptors:lp(t,i),setContext:s=>Ri(t,s,e,i),override:s=>Ri(t.override(s),n,e,i)};return new Proxy(r,{deleteProperty(s,o){return delete s[o],delete t[o],!0},get(s,o,a){return g0(s,o,()=>$N(s,o,a))},getOwnPropertyDescriptor(s,o){return s._descriptors.allKeys?Reflect.has(t,o)?{enumerable:!0,configurable:!0}:void 0:Reflect.getOwnPropertyDescriptor(t,o)},getPrototypeOf(){return Reflect.getPrototypeOf(t)},has(s,o){return Reflect.has(t,o)},ownKeys(){return Reflect.ownKeys(t)},set(s,o,a){return t[o]=a,delete s[o],!0}})}function lp(t,n={scriptable:!0,indexable:!0}){let{_scriptable:e=n.scriptable,_indexable:i=n.indexable,_allKeys:r=n.allKeys}=t;return{allKeys:r,scriptable:e,indexable:i,isScriptable:_n(e)?e:()=>e,isIndexable:_n(i)?i:()=>i}}var UN=(t,n)=>t?t+lc(n):n,cp=(t,n)=>K(n)&&t!=="adapters"&&(Object.getPrototypeOf(n)===null||n.constructor===Object);function g0(t,n,e){if(Object.prototype.hasOwnProperty.call(t,n)||n==="constructor")return t[n];let i=e();return t[n]=i,i}function $N(t,n,e){let{_proxy:i,_context:r,_subProxy:s,_descriptors:o}=t,a=i[n];return _n(a)&&o.isScriptable(n)&&(a=zN(n,a,t,e)),fe(a)&&a.length&&(a=WN(n,a,t,o.isIndexable)),cp(n,a)&&(a=Ri(a,r,s&&s[n],o)),a}function zN(t,n,e,i){let{_proxy:r,_context:s,_subProxy:o,_stack:a}=e;if(a.has(t))throw new Error("Recursion detected: "+Array.from(a).join("->")+"->"+t);a.add(t);let l=n(s,o||i);return a.delete(t),cp(t,l)&&(l=up(r._scopes,r,t,l)),l}function WN(t,n,e,i){let{_proxy:r,_context:s,_subProxy:o,_descriptors:a}=e;if(typeof s.index<"u"&&i(t))return n[s.index%n.length];if(K(n[0])){let l=n,c=r._scopes.filter(u=>u!==l);n=[];for(let u of l){let d=up(c,r,t,u);n.push(Ri(d,s,o&&o[t],a))}}return n}function m0(t,n,e){return _n(t)?t(n,e):t}var GN=(t,n)=>t===!0?n:typeof t=="string"?xn(n,t):void 0;function qN(t,n,e,i,r){for(let s of n){let o=GN(e,s);if(o){t.add(o);let a=m0(o._fallback,e,r);if(typeof a<"u"&&a!==e&&a!==i)return a}else if(o===!1&&typeof i<"u"&&e!==i)return null}return!1}function up(t,n,e,i){let r=n._rootScopes,s=m0(n._fallback,e,i),o=[...t,...r],a=new Set;a.add(i);let l=Gw(a,o,e,s||e,i);return l===null||typeof s<"u"&&s!==e&&(l=Gw(a,o,s,l,i),l===null)?!1:gc(Array.from(a),[""],r,s,()=>YN(n,e,i))}function Gw(t,n,e,i,r){for(;e;)e=qN(t,n,e,i,r);return e}function YN(t,n,e){let i=t._getTarget();n in i||(i[n]={});let r=i[n];return fe(r)&&K(e)?e:r||{}}function ZN(t,n,e,i){let r;for(let s of n)if(r=v0(UN(s,t),e),typeof r<"u")return cp(t,r)?up(e,i,t,r):r}function v0(t,n){for(let e of n){if(!e)continue;let i=e[t];if(typeof i<"u")return i}}function qw(t){let n=t._keys;return n||(n=t._keys=QN(t._scopes)),n}function QN(t){let n=new Set;for(let e of t)for(let i of Object.keys(e).filter(r=>!r.startsWith("_")))n.add(i);return Array.from(n)}function dp(t,n,e,i){let{iScale:r}=t,{key:s="r"}=this._parsing,o=new Array(i),a,l,c,u;for(a=0,l=i;ant==="x"?"y":"x";function XN(t,n,e,i){let r=t.skip?n:t,s=n,o=e.skip?n:e,a=oc(s,r),l=oc(o,s),c=a/(a+l),u=l/(a+l);c=isNaN(c)?0:c,u=isNaN(u)?0:u;let d=i*c,h=i*u;return{previous:{x:s.x-d*(o.x-r.x),y:s.y-d*(o.y-r.y)},next:{x:s.x+h*(o.x-r.x),y:s.y+h*(o.y-r.y)}}}function JN(t,n,e){let i=t.length,r,s,o,a,l,c=$r(t,0);for(let u=0;u!c.skip)),n.cubicInterpolationMode==="monotone")tR(t,r);else{let c=i?t[t.length-1]:t[0];for(s=0,o=t.length;st.ownerDocument.defaultView.getComputedStyle(t,null);function iR(t,n){return yc(t).getPropertyValue(n)}var rR=["top","right","bottom","left"];function Ni(t,n,e){let i={};e=e?"-"+e:"";for(let r=0;r<4;r++){let s=rR[r];i[s]=parseFloat(t[n+"-"+s+e])||0}return i.width=i.left+i.right,i.height=i.top+i.bottom,i}var sR=(t,n,e)=>(t>0||n>0)&&(!e||!e.shadowRoot);function oR(t,n){let e=t.touches,i=e&&e.length?e[0]:t,{offsetX:r,offsetY:s}=i,o=!1,a,l;if(sR(r,s,t.target))a=r,l=s;else{let c=n.getBoundingClientRect();a=i.clientX-c.left,l=i.clientY-c.top,o=!0}return{x:a,y:l,box:o}}function Jn(t,n){if("native"in t)return t;let{canvas:e,currentDevicePixelRatio:i}=n,r=yc(e),s=r.boxSizing==="border-box",o=Ni(r,"padding"),a=Ni(r,"border","width"),{x:l,y:c,box:u}=oR(t,e),d=o.left+(u&&a.left),h=o.top+(u&&a.top),{width:f,height:p}=n;return s&&(f-=o.width+a.width,p-=o.height+a.height),{x:Math.round((l-d)/f*e.width/i),y:Math.round((c-h)/p*e.height/i)}}function aR(t,n,e){let i,r;if(n===void 0||e===void 0){let s=t&&vc(t);if(!s)n=t.clientWidth,e=t.clientHeight;else{let o=s.getBoundingClientRect(),a=yc(s),l=Ni(a,"border","width"),c=Ni(a,"padding");n=o.width-c.width-l.width,e=o.height-c.height-l.height,i=ac(a.maxWidth,s,"clientWidth"),r=ac(a.maxHeight,s,"clientHeight")}}return{width:n,height:e,maxWidth:i||sc,maxHeight:r||sc}}var ic=t=>Math.round(t*10)/10;function w0(t,n,e,i){let r=yc(t),s=Ni(r,"margin"),o=ac(r.maxWidth,t,"clientWidth")||sc,a=ac(r.maxHeight,t,"clientHeight")||sc,l=aR(t,n,e),{width:c,height:u}=l;if(r.boxSizing==="content-box"){let h=Ni(r,"border","width"),f=Ni(r,"padding");c-=f.width+h.width,u-=f.height+h.height}return c=Math.max(0,c-s.width),u=Math.max(0,i?c/i:u-s.height),c=ic(Math.min(c,o,l.maxWidth)),u=ic(Math.min(u,a,l.maxHeight)),c&&!u&&(u=ic(c/2)),(n!==void 0||e!==void 0)&&i&&l.height&&u>l.height&&(u=l.height,c=ic(Math.floor(u*i))),{width:c,height:u}}function hp(t,n,e){let i=n||1,r=Math.floor(t.height*i),s=Math.floor(t.width*i);t.height=Math.floor(t.height),t.width=Math.floor(t.width);let o=t.canvas;return o.style&&(e||!o.style.height&&!o.style.width)&&(o.style.height=`${t.height}px`,o.style.width=`${t.width}px`),t.currentDevicePixelRatio!==i||o.height!==r||o.width!==s?(t.currentDevicePixelRatio=i,o.height=r,o.width=s,t.ctx.setTransform(i,0,0,i,0,0),!0):!1}var D0=function(){let t=!1;try{let n={get passive(){return t=!0,!1}};mc()&&(window.addEventListener("test",null,n),window.removeEventListener("test",null,n))}catch{}return t}();function fp(t,n){let e=iR(t,n),i=e&&e.match(/^(\d+)(\.\d+)?px$/);return i?+i[1]:void 0}function Yn(t,n,e,i){return{x:t.x+e*(n.x-t.x),y:t.y+e*(n.y-t.y)}}function _0(t,n,e,i){return{x:t.x+e*(n.x-t.x),y:i==="middle"?e<.5?t.y:n.y:i==="after"?e<1?t.y:n.y:e>0?n.y:t.y}}function C0(t,n,e,i){let r={x:t.cp2x,y:t.cp2y},s={x:n.cp1x,y:n.cp1y},o=Yn(t,r,e),a=Yn(r,s,e),l=Yn(s,n,e),c=Yn(o,a,e),u=Yn(a,l,e);return Yn(c,u,e)}var lR=function(t,n){return{x(e){return t+t+n-e},setWidth(e){n=e},textAlign(e){return e==="center"?e:e==="right"?"left":"right"},xPlus(e,i){return e-i},leftForLtr(e,i){return e-i}}},cR=function(){return{x(t){return t},setWidth(t){},textAlign(t){return t},xPlus(t,n){return t+n},leftForLtr(t,n){return t}}};function Pi(t,n,e){return t?lR(n,e):cR()}function pp(t,n){let e,i;(n==="ltr"||n==="rtl")&&(e=t.canvas.style,i=[e.getPropertyValue("direction"),e.getPropertyPriority("direction")],e.setProperty("direction",n,"important"),t.prevTextDirection=i)}function gp(t,n){n!==void 0&&(delete t.prevTextDirection,t.canvas.style.setProperty("direction",n[0],n[1]))}function x0(t){return t==="angle"?{between:qr,compare:MN,normalize:tt}:{between:nn,compare:(n,e)=>n-e,normalize:n=>n}}function Yw({start:t,end:n,count:e,loop:i,style:r}){return{start:t%e,end:n%e,loop:i&&(n-t+1)%e===0,style:r}}function uR(t,n,e){let{property:i,start:r,end:s}=e,{between:o,normalize:a}=x0(i),l=n.length,{start:c,end:u,loop:d}=t,h,f;if(d){for(c+=l,u+=l,h=0,f=l;hl(r,w,v)&&a(r,w)!==0,b=()=>a(s,v)===0||l(s,w,v),D=()=>g||C(),M=()=>!g||b();for(let x=u,O=u;x<=d;++x)y=n[x%o],!y.skip&&(v=c(y[i]),v!==w&&(g=l(v,r,s),m===null&&D()&&(m=a(v,r)===0?x:O),m!==null&&M()&&(p.push(Yw({start:m,end:x,loop:h,count:o,style:f})),m=null),O=x,w=v));return m!==null&&p.push(Yw({start:m,end:d,loop:h,count:o,style:f})),p}function vp(t,n){let e=[],i=t.segments;for(let r=0;rr&&t[s%n].skip;)s--;return s%=n,{start:r,end:s}}function hR(t,n,e,i){let r=t.length,s=[],o=n,a=t[n],l;for(l=n+1;l<=e;++l){let c=t[l%r];c.skip||c.stop?a.skip||(i=!1,s.push({start:n%r,end:(l-1)%r,loop:i}),n=o=c.stop?l:null):(o=l,a.skip&&(n=l)),a=c}return o!==null&&s.push({start:n%r,end:o%r,loop:i}),s}function E0(t,n){let e=t.points,i=t.options.spanGaps,r=e.length;if(!r)return[];let s=!!t._loop,{start:o,end:a}=dR(e,r,s,i);if(i===!0)return Zw(t,[{start:o,end:a,loop:s}],e,n);let l=aa({chart:n,initial:e.initial,numSteps:o,currentStep:Math.min(i-e.start,o)}))}_refresh(){this._request||(this._running=!0,this._request=Jf.call(window,()=>{this._update(),this._request=null,this._running&&this._refresh()}))}_update(n=Date.now()){let e=0;this._charts.forEach((i,r)=>{if(!i.running||!i.items.length)return;let s=i.items,o=s.length-1,a=!1,l;for(;o>=0;--o)l=s[o],l._active?(l._total>i.duration&&(i.duration=l._total),l.tick(n),a=!0):(s[o]=s[s.length-1],s.pop());a&&(r.draw(),this._notify(r,i,n,"progress")),s.length||(i.running=!1,this._notify(r,i,n,"complete"),i.initial=!1),e+=s.length}),this._lastDate=n,e===0&&(this._running=!1)}_getAnims(n){let e=this._charts,i=e.get(n);return i||(i={running:!1,initial:!0,items:[],listeners:{complete:[],progress:[]}},e.set(n,i)),i}listen(n,e,i){this._getAnims(n).listeners[e].push(i)}add(n,e){!e||!e.length||this._getAnims(n).items.push(...e)}has(n){return this._getAnims(n).items.length>0}start(n){let e=this._charts.get(n);e&&(e.running=!0,e.start=Date.now(),e.duration=e.items.reduce((i,r)=>Math.max(i,r._duration),0),this._refresh())}running(n){if(!this._running)return!1;let e=this._charts.get(n);return!(!e||!e.running||!e.items.length)}stop(n){let e=this._charts.get(n);if(!e||!e.items.length)return;let i=e.items,r=i.length-1;for(;r>=0;--r)i[r].cancel();e.items=[],this._notify(n,e,Date.now(),"complete")}remove(n){return this._charts.delete(n)}},Mn=new Ip,M0="transparent",gR={boolean(t,n,e){return e>.5?n:t},color(t,n,e){let i=rp(t||M0),r=i.valid&&rp(n||M0);return r&&r.valid?r.mix(i,e).hexString():n},number(t,n,e){return t+(n-t)*e}},Op=class{constructor(n,e,i,r){let s=e[i];r=Qr([n.to,r,s,n.from]);let o=Qr([n.from,s,r]);this._active=!0,this._fn=n.fn||gR[n.type||typeof o],this._easing=Br[n.easing]||Br.linear,this._start=Math.floor(Date.now()+(n.delay||0)),this._duration=this._total=Math.floor(n.duration),this._loop=!!n.loop,this._target=e,this._prop=i,this._from=o,this._to=r,this._promises=void 0}active(){return this._active}update(n,e,i){if(this._active){this._notify(!1);let r=this._target[this._prop],s=i-this._start,o=this._duration-s;this._start=i,this._duration=Math.floor(Math.max(o,n.duration)),this._total+=s,this._loop=!!n.loop,this._to=Qr([n.to,e,r,n.from]),this._from=Qr([n.from,r,e])}}cancel(){this._active&&(this.tick(Date.now()),this._active=!1,this._notify(!1))}tick(n){let e=n-this._start,i=this._duration,r=this._prop,s=this._from,o=this._loop,a=this._to,l;if(this._active=s!==a&&(o||e1?2-l:l,l=this._easing(Math.min(1,Math.max(0,l))),this._target[r]=this._fn(s,a,l)}wait(){let n=this._promises||(this._promises=[]);return new Promise((e,i)=>{n.push({res:e,rej:i})})}_notify(n){let e=n?"res":"rej",i=this._promises||[];for(let r=0;r{let s=n[r];if(!K(s))return;let o={};for(let a of e)o[a]=s[a];(fe(s.properties)&&s.properties||[r]).forEach(a=>{(a===r||!i.has(a))&&i.set(a,o)})})}_animateOptions(n,e){let i=e.options,r=vR(n,i);if(!r)return[];let s=this._createAnimations(r,i);return i.$shared&&mR(n.options.$animations,i).then(()=>{n.options=i},()=>{}),s}_createAnimations(n,e){let i=this._properties,r=[],s=n.$animations||(n.$animations={}),o=Object.keys(e),a=Date.now(),l;for(l=o.length-1;l>=0;--l){let c=o[l];if(c.charAt(0)==="$")continue;if(c==="options"){r.push(...this._animateOptions(n,e));continue}let u=e[c],d=s[c],h=i.get(c);if(d)if(h&&d.active()){d.update(h,u,a);continue}else d.cancel();if(!h||!h.duration){n[c]=u;continue}s[c]=d=new Op(h,n,c,u),r.push(d)}return r}update(n,e){if(this._properties.size===0){Object.assign(n,e);return}let i=this._createAnimations(n,e);if(i.length)return Mn.add(this._chart,i),!0}};function mR(t,n){let e=[],i=Object.keys(n);for(let r=0;r0||!e&&s<0)return r.index}return null}function T0(t,n){let{chart:e,_cachedMeta:i}=t,r=e._stacks||(e._stacks={}),{iScale:s,vScale:o,index:a}=i,l=s.axis,c=o.axis,u=DR(s,o,i),d=n.length,h;for(let f=0;fe[i].axis===n).shift()}function xR(t,n){return En(t,{active:!1,dataset:void 0,datasetIndex:n,index:n,mode:"default",type:"dataset"})}function ER(t,n,e){return En(t,{active:!1,dataIndex:n,parsed:void 0,raw:void 0,element:e,index:n,mode:"default",type:"data"})}function co(t,n){let e=t.controller.index,i=t.vScale&&t.vScale.axis;if(i){n=n||t._parsed;for(let r of n){let s=r._stacks;if(!s||s[i]===void 0||s[i][e]===void 0)return;delete s[i][e],s[i]._visualValues!==void 0&&s[i]._visualValues[e]!==void 0&&delete s[i]._visualValues[e]}}}var wp=t=>t==="reset"||t==="none",A0=(t,n)=>n?t:Object.assign({},t),MR=(t,n,e)=>t&&!n.hidden&&n._stacked&&{keys:MD(e,!0),values:null},ti=(()=>{class t{static defaults={};static datasetElementType=null;static dataElementType=null;constructor(e,i){this.chart=e,this._ctx=e.ctx,this.index=i,this._cachedDataOpts={},this._cachedMeta=this.getMeta(),this._type=this._cachedMeta.type,this.options=void 0,this._parsing=!1,this._data=void 0,this._objectData=void 0,this._sharedOptions=void 0,this._drawStart=void 0,this._drawCount=void 0,this.enableOptionSharing=!1,this.supportsDecimation=!1,this.$context=void 0,this._syncList=[],this.datasetElementType=new.target.datasetElementType,this.dataElementType=new.target.dataElementType,this.initialize()}initialize(){let e=this._cachedMeta;this.configure(),this.linkScales(),e._stacked=yp(e.vScale,e),this.addElements(),this.options.fill&&!this.chart.isPluginEnabled("filler")&&console.warn("Tried to use the 'fill' option without the 'Filler' plugin enabled. Please import and register the 'Filler' plugin and make sure it is not disabled in the options")}updateIndex(e){this.index!==e&&co(this._cachedMeta),this.index=e}linkScales(){let e=this.chart,i=this._cachedMeta,r=this.getDataset(),s=(h,f,p,g)=>h==="x"?f:h==="r"?g:p,o=i.xAxisID=V(r.xAxisID,bp(e,"x")),a=i.yAxisID=V(r.yAxisID,bp(e,"y")),l=i.rAxisID=V(r.rAxisID,bp(e,"r")),c=i.indexAxis,u=i.iAxisID=s(c,o,a,l),d=i.vAxisID=s(c,a,o,l);i.xScale=this.getScaleForId(o),i.yScale=this.getScaleForId(a),i.rScale=this.getScaleForId(l),i.iScale=this.getScaleForId(u),i.vScale=this.getScaleForId(d)}getDataset(){return this.chart.data.datasets[this.index]}getMeta(){return this.chart.getDatasetMeta(this.index)}getScaleForId(e){return this.chart.scales[e]}_getOtherScale(e){let i=this._cachedMeta;return e===i.iScale?i.vScale:i.iScale}reset(){this._update("reset")}_destroy(){let e=this._cachedMeta;this._data&&Kf(this._data,this),e._stacked&&co(e)}_dataCheck(){let e=this.getDataset(),i=e.data||(e.data=[]),r=this._data;if(K(i)){let s=this._cachedMeta;this._data=wR(i,s)}else if(r!==i){if(r){Kf(r,this);let s=this._cachedMeta;co(s),s._parsed=[]}i&&Object.isExtensible(i)&&a0(i,this),this._syncList=[],this._data=i}}addElements(){let e=this._cachedMeta;this._dataCheck(),this.datasetElementType&&(e.dataset=new this.datasetElementType)}buildOrUpdateElements(e){let i=this._cachedMeta,r=this.getDataset(),s=!1;this._dataCheck();let o=i._stacked;i._stacked=yp(i.vScale,i),i.stack!==r.stack&&(s=!0,co(i),i.stack=r.stack),this._resyncElements(e),(s||o!==i._stacked)&&(T0(this,i._parsed),i._stacked=yp(i.vScale,i))}configure(){let e=this.chart.config,i=e.datasetScopeKeys(this._type),r=e.getOptionScopes(this.getDataset(),i,!0);this.options=e.createResolver(r,this.getContext()),this._parsing=this.options.parsing,this._cachedDataOpts={}}parse(e,i){let{_cachedMeta:r,_data:s}=this,{iScale:o,_stacked:a}=r,l=o.axis,c=e===0&&i===s.length?!0:r._sorted,u=e>0&&r._parsed[e-1],d,h,f;if(this._parsing===!1)r._parsed=s,r._sorted=!0,f=s;else{fe(s[e])?f=this.parseArrayData(r,s,e,i):K(s[e])?f=this.parseObjectData(r,s,e,i):f=this.parsePrimitiveData(r,s,e,i);let p=()=>h[l]===null||u&&h[l]m||h=0;--f)if(!g()){this.updateRangeFromParsed(u,e,p,c);break}}return u}getAllParsedValues(e){let i=this._cachedMeta._parsed,r=[],s,o,a;for(s=0,o=i.length;s=0&&ethis.getContext(r,s,i),m=u.resolveNamedOptions(f,p,g,h);return m.$shared&&(m.$shared=c,o[a]=Object.freeze(A0(m,c))),m}_resolveAnimations(e,i,r){let s=this.chart,o=this._cachedDataOpts,a=`animation-${i}`,l=o[a];if(l)return l;let c;if(s.options.animation!==!1){let d=this.chart.config,h=d.datasetAnimationScopeKeys(this._type,i),f=d.getOptionScopes(this.getDataset(),h);c=d.createResolver(f,this.getContext(e,r,i))}let u=new Ic(s,c&&c.animations);return c&&c._cacheable&&(o[a]=Object.freeze(u)),u}getSharedOptions(e){if(e.$shared)return this._sharedOptions||(this._sharedOptions=Object.assign({},e))}includeOptions(e,i){return!i||wp(e)||this.chart._animationsDisabled}_getSharedOptions(e,i){let r=this.resolveDataElementOptions(e,i),s=this._sharedOptions,o=this.getSharedOptions(r),a=this.includeOptions(i,o)||o!==s;return this.updateSharedOptions(o,i,r),{sharedOptions:o,includeOptions:a}}updateElement(e,i,r,s){wp(s)?Object.assign(e,r):this._resolveAnimations(i,s).update(e,r)}updateSharedOptions(e,i,r){e&&!wp(i)&&this._resolveAnimations(void 0,i).update(e,r)}_setStyle(e,i,r,s){e.active=s;let o=this.getStyle(i,s);this._resolveAnimations(i,r,s).update(e,{options:!s&&this.getSharedOptions(o)||o})}removeHoverStyle(e,i,r){this._setStyle(e,r,"active",!1)}setHoverStyle(e,i,r){this._setStyle(e,r,"active",!0)}_removeDatasetHoverStyle(){let e=this._cachedMeta.dataset;e&&this._setStyle(e,void 0,"active",!1)}_setDatasetHoverStyle(){let e=this._cachedMeta.dataset;e&&this._setStyle(e,void 0,"active",!0)}_resyncElements(e){let i=this._data,r=this._cachedMeta.data;for(let[l,c,u]of this._syncList)this[l](c,u);this._syncList=[];let s=r.length,o=i.length,a=Math.min(o,s);a&&this.parse(0,a),o>s?this._insertElements(s,o-s,e):o{for(u.length+=i,l=u.length-1;l>=a;l--)u[l]=u[l-i]};for(c(o),l=e;lr-s))}return t._cache.$bar}function IR(t){let n=t.iScale,e=SR(n,t.type),i=n._length,r,s,o,a,l=()=>{o===32767||o===-32768||(Wr(a)&&(i=Math.min(i,Math.abs(o-a)||i)),a=o)};for(r=0,s=e.length;r0?r[t-1]:null,a=tMath.abs(a)&&(l=a,c=o),n[e.axis]=c,n._custom={barStart:l,barEnd:c,start:r,end:s,min:o,max:a}}function SD(t,n,e,i){return fe(t)?AR(t,n,e,i):n[e.axis]=e.parse(t,i),n}function N0(t,n,e,i){let r=t.iScale,s=t.vScale,o=r.getLabels(),a=r===s,l=[],c,u,d,h;for(c=e,u=e+i;c=e?1:-1)}function RR(t){let n,e,i,r,s;return t.horizontal?(n=t.base>t.x,e="left",i="right"):(n=t.base{class t extends ti{static id="bar";static defaults={datasetElementType:!1,dataElementType:"bar",categoryPercentage:.8,barPercentage:.9,grouped:!0,animations:{numbers:{type:"number",properties:["x","y","base","width","height"]}}};static overrides={scales:{_index_:{type:"category",offset:!0,grid:{offset:!0}},_value_:{type:"linear",beginAtZero:!0}}};parsePrimitiveData(e,i,r,s){return N0(e,i,r,s)}parseArrayData(e,i,r,s){return N0(e,i,r,s)}parseObjectData(e,i,r,s){let{iScale:o,vScale:a}=e,{xAxisKey:l="x",yAxisKey:c="y"}=this._parsing,u=o.axis==="x"?l:c,d=a.axis==="x"?l:c,h=[],f,p,g,m;for(f=r,p=r+s;fd.controller.options.grouped),o=r.options.stacked,a=[],l=this._cachedMeta.controller.getParsed(i),c=l&&l[r.axis],u=d=>{let h=d._parsed.find(p=>p[r.axis]===c),f=h&&h[d.vScale.axis];if(te(f)||isNaN(f))return!0};for(let d of s)if(!(i!==void 0&&u(d))&&((o===!1||a.indexOf(d.stack)===-1||o===void 0&&d.stack===void 0)&&a.push(d.stack),d.index===e))break;return a.length||a.push(void 0),a}_getStackCount(e){return this._getStacks(void 0,e).length}_getStackIndex(e,i,r){let s=this._getStacks(e,r),o=i!==void 0?s.indexOf(i):-1;return o===-1?s.length-1:o}_getRuler(){let e=this.options,i=this._cachedMeta,r=i.iScale,s=[],o,a;for(o=0,a=i.data.length;o{class t extends ti{static id="bubble";static defaults={datasetElementType:!1,dataElementType:"point",animations:{numbers:{type:"number",properties:["x","y","borderWidth","radius"]}}};static overrides={scales:{x:{type:"linear"},y:{type:"linear"}}};initialize(){this.enableOptionSharing=!0,super.initialize()}parsePrimitiveData(e,i,r,s){let o=super.parsePrimitiveData(e,i,r,s);for(let a=0;a=0;--r)i=Math.max(i,e[r].size(this.resolveDataElementOptions(r))/2);return i>0&&i}getLabelAndValue(e){let i=this._cachedMeta,r=this.chart.data.labels||[],{xScale:s,yScale:o}=i,a=this.getParsed(e),l=s.getLabelForValue(a.x),c=o.getLabelForValue(a.y),u=a._custom;return{label:r[e]||"",value:"("+l+", "+c+(u?", "+u:"")+")"}}update(e){let i=this._cachedMeta.data;this.updateElements(i,0,i.length,e)}updateElements(e,i,r,s){let o=s==="reset",{iScale:a,vScale:l}=this._cachedMeta,{sharedOptions:c,includeOptions:u}=this._getSharedOptions(i,s),d=a.axis,h=l.axis;for(let f=i;fqr(w,a,l,!0)?1:Math.max(C,C*e,b,b*e),p=(w,C,b)=>qr(w,a,l,!0)?-1:Math.min(C,C*e,b,b*e),g=f(0,c,d),m=f(De,u,h),v=p(pe,c,d),y=p(pe+De,u,h);i=(g-v)/2,r=(m-y)/2,s=-(g+v)/2,o=-(m+y)/2}return{ratioX:i,ratioY:r,offsetX:s,offsetY:o}}var Zp=(()=>{class t extends ti{static id="doughnut";static defaults={datasetElementType:!1,dataElementType:"arc",animation:{animateRotate:!0,animateScale:!1},animations:{numbers:{type:"number",properties:["circumference","endAngle","innerRadius","outerRadius","startAngle","x","y","offset","borderWidth","spacing"]}},cutout:"50%",rotation:0,circumference:360,radius:"100%",spacing:0,indexAxis:"r"};static descriptors={_scriptable:e=>e!=="spacing",_indexable:e=>e!=="spacing"&&!e.startsWith("borderDash")&&!e.startsWith("hoverBorderDash")};static overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(e){let i=e.data;if(i.labels.length&&i.datasets.length){let{labels:{pointStyle:r,color:s}}=e.legend.options;return i.labels.map((o,a)=>{let c=e.getDatasetMeta(0).controller.getStyle(a);return{text:o,fillStyle:c.backgroundColor,strokeStyle:c.borderColor,fontColor:s,lineWidth:c.borderWidth,pointStyle:r,hidden:!e.getDataVisibility(a),index:a}})}return[]}},onClick(e,i,r){r.chart.toggleDataVisibility(i.index),r.chart.update()}}}};constructor(e,i){super(e,i),this.enableOptionSharing=!0,this.innerRadius=void 0,this.outerRadius=void 0,this.offsetX=void 0,this.offsetY=void 0}linkScales(){}parse(e,i){let r=this.getDataset().data,s=this._cachedMeta;if(this._parsing===!1)s._parsed=r;else{let o=c=>+r[c];if(K(r[e])){let{key:c="value"}=this._parsing;o=u=>+xn(r[u],c)}let a,l;for(a=e,l=e+i;a0&&!isNaN(e)?ge*(Math.abs(e)/i):0}getLabelAndValue(e){let i=this._cachedMeta,r=this.chart,s=r.data.labels||[],o=Yr(i._parsed[e],r.options.locale);return{label:s[e]||"",value:o}}getMaxBorderWidth(e){let i=0,r=this.chart,s,o,a,l,c;if(!e){for(s=0,o=r.data.datasets.length;s{class t extends ti{static id="line";static defaults={datasetElementType:"line",dataElementType:"point",showLine:!0,spanGaps:!1};static overrides={scales:{_index_:{type:"category"},_value_:{type:"linear"}}};initialize(){this.enableOptionSharing=!0,this.supportsDecimation=!0,super.initialize()}update(e){let i=this._cachedMeta,{dataset:r,data:s=[],_dataset:o}=i,a=this.chart._animationsDisabled,{start:l,count:c}=tp(i,s,a);this._drawStart=l,this._drawCount=c,np(i)&&(l=0,c=s.length),r._chart=this.chart,r._datasetIndex=this.index,r._decimated=!!o._decimated,r.points=s;let u=this.resolveDatasetElementOptions(e);this.options.showLine||(u.borderWidth=0),u.segment=this.options.segment,this.updateElement(r,void 0,{animated:!a,options:u},e),this.updateElements(s,l,c,e)}updateElements(e,i,r,s){let o=s==="reset",{iScale:a,vScale:l,_stacked:c,_dataset:u}=this._cachedMeta,{sharedOptions:d,includeOptions:h}=this._getSharedOptions(i,s),f=a.axis,p=l.axis,{spanGaps:g,segment:m}=this.options,v=ki(g)?g:Number.POSITIVE_INFINITY,y=this.chart._animationsDisabled||o||s==="none",w=i+r,C=e.length,b=i>0&&this.getParsed(i-1);for(let D=0;D=w){x.skip=!0;continue}let O=this.getParsed(D),z=te(O[p]),H=x[f]=a.getPixelForValue(O[f],D),X=x[p]=o||z?l.getBasePixel():l.getPixelForValue(c?this.applyStack(l,O,c):O[p],D);x.skip=isNaN(H)||isNaN(X)||z,x.stop=D>0&&Math.abs(O[f]-b[f])>v,m&&(x.parsed=O,x.raw=u.data[D]),h&&(x.options=d||this.resolveDataElementOptions(D,M.active?"active":s)),y||this.updateElement(M,D,x,s),b=O}}getMaxOverflow(){let e=this._cachedMeta,i=e.dataset,r=i.options&&i.options.borderWidth||0,s=e.data||[];if(!s.length)return r;let o=s[0].size(this.resolveDataElementOptions(0)),a=s[s.length-1].size(this.resolveDataElementOptions(s.length-1));return Math.max(r,o,a)/2}draw(){let e=this._cachedMeta;e.dataset.updateControlPoints(this.chart.chartArea,e.iScale.axis),super.draw()}}return t})(),ID=(()=>{class t extends ti{static id="polarArea";static defaults={dataElementType:"arc",animation:{animateRotate:!0,animateScale:!0},animations:{numbers:{type:"number",properties:["x","y","startAngle","endAngle","innerRadius","outerRadius"]}},indexAxis:"r",startAngle:0};static overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(e){let i=e.data;if(i.labels.length&&i.datasets.length){let{labels:{pointStyle:r,color:s}}=e.legend.options;return i.labels.map((o,a)=>{let c=e.getDatasetMeta(0).controller.getStyle(a);return{text:o,fillStyle:c.backgroundColor,strokeStyle:c.borderColor,fontColor:s,lineWidth:c.borderWidth,pointStyle:r,hidden:!e.getDataVisibility(a),index:a}})}return[]}},onClick(e,i,r){r.chart.toggleDataVisibility(i.index),r.chart.update()}}},scales:{r:{type:"radialLinear",angleLines:{display:!1},beginAtZero:!0,grid:{circular:!0},pointLabels:{display:!1},startAngle:0}}};constructor(e,i){super(e,i),this.innerRadius=void 0,this.outerRadius=void 0}getLabelAndValue(e){let i=this._cachedMeta,r=this.chart,s=r.data.labels||[],o=Yr(i._parsed[e].r,r.options.locale);return{label:s[e]||"",value:o}}parseObjectData(e,i,r,s){return dp.bind(this)(e,i,r,s)}update(e){let i=this._cachedMeta.data;this._updateRadius(),this.updateElements(i,0,i.length,e)}getMinMax(){let e=this._cachedMeta,i={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY};return e.data.forEach((r,s)=>{let o=this.getParsed(s).r;!isNaN(o)&&this.chart.getDataVisibility(s)&&(oi.max&&(i.max=o))}),i}_updateRadius(){let e=this.chart,i=e.chartArea,r=e.options,s=Math.min(i.right-i.left,i.bottom-i.top),o=Math.max(s/2,0),a=Math.max(r.cutoutPercentage?o/100*r.cutoutPercentage:1,0),l=(o-a)/e.getVisibleDatasetCount();this.outerRadius=o-l*this.index,this.innerRadius=this.outerRadius-l}updateElements(e,i,r,s){let o=s==="reset",a=this.chart,c=a.options.animation,u=this._cachedMeta.rScale,d=u.xCenter,h=u.yCenter,f=u.getIndexAngle(0)-.5*pe,p=f,g,m=360/this.countVisibleElements();for(g=0;g{!isNaN(this.getParsed(s).r)&&this.chart.getDataVisibility(s)&&i++}),i}_computeAngle(e,i,r){return this.chart.getDataVisibility(e)?Mt(this.resolveDataElementOptions(e,i).angle||r):0}}return t})(),BR=(()=>{class t extends Zp{static id="pie";static defaults={cutout:0,rotation:0,circumference:360,radius:"100%"}}return t})(),UR=(()=>{class t extends ti{static id="radar";static defaults={datasetElementType:"line",dataElementType:"point",indexAxis:"r",showLine:!0,elements:{line:{fill:"start"}}};static overrides={aspectRatio:1,scales:{r:{type:"radialLinear"}}};getLabelAndValue(e){let i=this._cachedMeta.vScale,r=this.getParsed(e);return{label:i.getLabels()[e],value:""+i.getLabelForValue(r[i.axis])}}parseObjectData(e,i,r,s){return dp.bind(this)(e,i,r,s)}update(e){let i=this._cachedMeta,r=i.dataset,s=i.data||[],o=i.iScale.getLabels();if(r.points=s,e!=="resize"){let a=this.resolveDatasetElementOptions(e);this.options.showLine||(a.borderWidth=0);let l={_loop:!0,_fullLoop:o.length===s.length,options:a};this.updateElement(r,void 0,l,e)}this.updateElements(s,0,s.length,e)}updateElements(e,i,r,s){let o=this._cachedMeta.rScale,a=s==="reset";for(let l=i;l{class t extends ti{static id="scatter";static defaults={datasetElementType:!1,dataElementType:"point",showLine:!1,fill:!1};static overrides={interaction:{mode:"point"},scales:{x:{type:"linear"},y:{type:"linear"}}};getLabelAndValue(e){let i=this._cachedMeta,r=this.chart.data.labels||[],{xScale:s,yScale:o}=i,a=this.getParsed(e),l=s.getLabelForValue(a.x),c=o.getLabelForValue(a.y);return{label:r[e]||"",value:"("+l+", "+c+")"}}update(e){let i=this._cachedMeta,{data:r=[]}=i,s=this.chart._animationsDisabled,{start:o,count:a}=tp(i,r,s);if(this._drawStart=o,this._drawCount=a,np(i)&&(o=0,a=r.length),this.options.showLine){this.datasetElementType||this.addElements();let{dataset:l,_dataset:c}=i;l._chart=this.chart,l._datasetIndex=this.index,l._decimated=!!c._decimated,l.points=r;let u=this.resolveDatasetElementOptions(e);u.segment=this.options.segment,this.updateElement(l,void 0,{animated:!s,options:u},e)}else this.datasetElementType&&(delete i.dataset,this.datasetElementType=!1);this.updateElements(r,o,a,e)}addElements(){let{showLine:e}=this.options;!this.datasetElementType&&e&&(this.datasetElementType=this.chart.registry.getElement("line")),super.addElements()}updateElements(e,i,r,s){let o=s==="reset",{iScale:a,vScale:l,_stacked:c,_dataset:u}=this._cachedMeta,d=this.resolveDataElementOptions(i,s),h=this.getSharedOptions(d),f=this.includeOptions(s,h),p=a.axis,g=l.axis,{spanGaps:m,segment:v}=this.options,y=ki(m)?m:Number.POSITIVE_INFINITY,w=this.chart._animationsDisabled||o||s==="none",C=i>0&&this.getParsed(i-1);for(let b=i;b0&&Math.abs(M[p]-C[p])>y,v&&(x.parsed=M,x.raw=u.data[b]),f&&(x.options=h||this.resolveDataElementOptions(b,D.active?"active":s)),w||this.updateElement(D,b,x,s),C=M}this.updateSharedOptions(h,s,d)}getMaxOverflow(){let e=this._cachedMeta,i=e.data||[];if(!this.options.showLine){let l=0;for(let c=i.length-1;c>=0;--c)l=Math.max(l,i[c].size(this.resolveDataElementOptions(c))/2);return l>0&&l}let r=e.dataset,s=r.options&&r.options.borderWidth||0;if(!i.length)return s;let o=i[0].size(this.resolveDataElementOptions(0)),a=i[i.length-1].size(this.resolveDataElementOptions(i.length-1));return Math.max(s,o,a)/2}}return t})(),zR=Object.freeze({__proto__:null,BarController:FR,BubbleController:VR,DoughnutController:Zp,LineController:HR,PieController:BR,PolarAreaController:ID,RadarController:UR,ScatterController:$R});function Li(){throw new Error("This method is not implemented: Check that a complete date adapter is provided.")}var Tp=class t{static override(n){Object.assign(t.prototype,n)}options;constructor(n){this.options=n||{}}init(){}formats(){return Li()}parse(){return Li()}format(){return Li()}add(){return Li()}diff(){return Li()}startOf(){return Li()}endOf(){return Li()}},WR={_date:Tp};function GR(t,n,e,i){let{controller:r,data:s,_sorted:o}=t,a=r._cachedMeta.iScale;if(a&&n===a.axis&&n!=="r"&&o&&s.length){let l=a._reversePixels?r0:Jt;if(i){if(r._sharedOptions){let c=s[0],u=typeof c.getRange=="function"&&c.getRange(n);if(u){let d=l(s,n,e-u),h=l(s,n,e+u);return{lo:d.lo,hi:h.hi}}}}else return l(s,n,e)}return{lo:0,hi:s.length-1}}function wo(t,n,e,i,r){let s=t.getSortedVisibleDatasetMetas(),o=e[n];for(let a=0,l=s.length;a{l[o]&&l[o](n[e],r)&&(s.push({element:l,datasetIndex:c,index:u}),a=a||l.inRange(n.x,n.y,r))}),i&&!a?[]:s}var QR={evaluateInteractionItems:wo,modes:{index(t,n,e,i){let r=Jn(n,t),s=e.axis||"x",o=e.includeInvisible||!1,a=e.intersect?_p(t,r,s,i,o):Cp(t,r,s,!1,i,o),l=[];return a.length?(t.getSortedVisibleDatasetMetas().forEach(c=>{let u=a[0].index,d=c.data[u];d&&!d.skip&&l.push({element:d,datasetIndex:c.index,index:u})}),l):[]},dataset(t,n,e,i){let r=Jn(n,t),s=e.axis||"xy",o=e.includeInvisible||!1,a=e.intersect?_p(t,r,s,i,o):Cp(t,r,s,!1,i,o);if(a.length>0){let l=a[0].datasetIndex,c=t.getDatasetMeta(l).data;a=[];for(let u=0;ue.pos===n)}function L0(t,n){return t.filter(e=>OD.indexOf(e.pos)===-1&&e.box.axis===n)}function ho(t,n){return t.sort((e,i)=>{let r=n?i:e,s=n?e:i;return r.weight===s.weight?r.index-s.index:r.weight-s.weight})}function KR(t){let n=[],e,i,r,s,o,a;for(e=0,i=(t||[]).length;ec.box.fullSize),!0),i=ho(uo(n,"left"),!0),r=ho(uo(n,"right")),s=ho(uo(n,"top"),!0),o=ho(uo(n,"bottom")),a=L0(n,"x"),l=L0(n,"y");return{fullSize:e,leftAndTop:i.concat(s),rightAndBottom:r.concat(l).concat(o).concat(a),chartArea:uo(n,"chartArea"),vertical:i.concat(r).concat(l),horizontal:s.concat(o).concat(a)}}function F0(t,n,e,i){return Math.max(t[e],n[e])+Math.max(t[i],n[i])}function TD(t,n){t.top=Math.max(t.top,n.top),t.left=Math.max(t.left,n.left),t.bottom=Math.max(t.bottom,n.bottom),t.right=Math.max(t.right,n.right)}function tk(t,n,e,i){let{pos:r,box:s}=e,o=t.maxPadding;if(!K(r)){e.size&&(t[r]-=e.size);let d=i[e.stack]||{size:0,count:1};d.size=Math.max(d.size,e.horizontal?s.height:s.width),e.size=d.size/d.count,t[r]+=e.size}s.getPadding&&TD(o,s.getPadding());let a=Math.max(0,n.outerWidth-F0(o,t,"left","right")),l=Math.max(0,n.outerHeight-F0(o,t,"top","bottom")),c=a!==t.w,u=l!==t.h;return t.w=a,t.h=l,e.horizontal?{same:c,other:u}:{same:u,other:c}}function nk(t){let n=t.maxPadding;function e(i){let r=Math.max(n[i]-t[i],0);return t[i]+=r,r}t.y+=e("top"),t.x+=e("left"),e("right"),e("bottom")}function ik(t,n){let e=n.maxPadding;function i(r){let s={left:0,top:0,right:0,bottom:0};return r.forEach(o=>{s[o]=Math.max(n[o],e[o])}),s}return i(t?["left","right"]:["top","bottom"])}function go(t,n,e,i){let r=[],s,o,a,l,c,u;for(s=0,o=t.length,c=0;s{typeof g.beforeLayout=="function"&&g.beforeLayout()});let u=l.reduce((g,m)=>m.box.options&&m.box.options.display===!1?g:g+1,0)||1,d=Object.freeze({outerWidth:n,outerHeight:e,padding:r,availableWidth:s,availableHeight:o,vBoxMaxWidth:s/2/u,hBoxMaxHeight:o/2}),h=Object.assign({},r);TD(h,Be(i));let f=Object.assign({maxPadding:h,w:s,h:o,x:r.left,y:r.top},r),p=JR(l.concat(c),d);go(a.fullSize,f,d,p),go(l,f,d,p),go(c,f,d,p)&&go(l,f,d,p),nk(f),V0(a.leftAndTop,f,d,p),f.x+=f.w,f.y+=f.h,V0(a.rightAndBottom,f,d,p),t.chartArea={left:f.left,top:f.top,right:f.left+f.w,bottom:f.top+f.h,height:f.h,width:f.w},oe(a.chartArea,g=>{let m=g.box;Object.assign(m,t.chartArea),m.update(f.w,f.h,{left:0,top:0,right:0,bottom:0})})}},Oc=class{acquireContext(n,e){}releaseContext(n){return!1}addEventListener(n,e,i){}removeEventListener(n,e,i){}getDevicePixelRatio(){return 1}getMaximumSize(n,e,i,r){return e=Math.max(0,e||n.width),i=i||n.height,{width:e,height:Math.max(0,r?Math.floor(e/r):i)}}isAttached(n){return!0}updateConfig(n){}},Ap=class extends Oc{acquireContext(n){return n&&n.getContext&&n.getContext("2d")||null}updateConfig(n){n.options.animation=!1}},Mc="$chartjs",rk={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},j0=t=>t===null||t==="";function sk(t,n){let e=t.style,i=t.getAttribute("height"),r=t.getAttribute("width");if(t[Mc]={initial:{height:i,width:r,style:{display:e.display,height:e.height,width:e.width}}},e.display=e.display||"block",e.boxSizing=e.boxSizing||"border-box",j0(r)){let s=fp(t,"width");s!==void 0&&(t.width=s)}if(j0(i))if(t.style.height==="")t.height=t.width/(n||2);else{let s=fp(t,"height");s!==void 0&&(t.height=s)}return t}var AD=D0?{passive:!0}:!1;function ok(t,n,e){t&&t.addEventListener(n,e,AD)}function ak(t,n,e){t&&t.canvas&&t.canvas.removeEventListener(n,e,AD)}function lk(t,n){let e=rk[t.type]||t.type,{x:i,y:r}=Jn(t,n);return{type:e,chart:n,native:t,x:i!==void 0?i:null,y:r!==void 0?r:null}}function Tc(t,n){for(let e of t)if(e===n||e.contains(n))return!0}function ck(t,n,e){let i=t.canvas,r=new MutationObserver(s=>{let o=!1;for(let a of s)o=o||Tc(a.addedNodes,i),o=o&&!Tc(a.removedNodes,i);o&&e()});return r.observe(document,{childList:!0,subtree:!0}),r}function uk(t,n,e){let i=t.canvas,r=new MutationObserver(s=>{let o=!1;for(let a of s)o=o||Tc(a.removedNodes,i),o=o&&!Tc(a.addedNodes,i);o&&e()});return r.observe(document,{childList:!0,subtree:!0}),r}var vo=new Map,H0=0;function ND(){let t=window.devicePixelRatio;t!==H0&&(H0=t,vo.forEach((n,e)=>{e.currentDevicePixelRatio!==t&&n()}))}function dk(t,n){vo.size||window.addEventListener("resize",ND),vo.set(t,n)}function hk(t){vo.delete(t),vo.size||window.removeEventListener("resize",ND)}function fk(t,n,e){let i=t.canvas,r=i&&vc(i);if(!r)return;let s=ep((a,l)=>{let c=r.clientWidth;e(a,l),c{let l=a[0],c=l.contentRect.width,u=l.contentRect.height;c===0&&u===0||s(c,u)});return o.observe(r),dk(t,s),o}function xp(t,n,e){e&&e.disconnect(),n==="resize"&&hk(t)}function pk(t,n,e){let i=t.canvas,r=ep(s=>{t.ctx!==null&&e(lk(s,t))},t);return ok(i,n,r),r}var Np=class extends Oc{acquireContext(n,e){let i=n&&n.getContext&&n.getContext("2d");return i&&i.canvas===n?(sk(n,e),i):null}releaseContext(n){let e=n.canvas;if(!e[Mc])return!1;let i=e[Mc].initial;["height","width"].forEach(s=>{let o=i[s];te(o)?e.removeAttribute(s):e.setAttribute(s,o)});let r=i.style||{};return Object.keys(r).forEach(s=>{e.style[s]=r[s]}),e.width=e.width,delete e[Mc],!0}addEventListener(n,e,i){this.removeEventListener(n,e);let r=n.$proxies||(n.$proxies={}),o={attach:ck,detach:uk,resize:fk}[e]||pk;r[e]=o(n,e,i)}removeEventListener(n,e){let i=n.$proxies||(n.$proxies={}),r=i[e];if(!r)return;({attach:xp,detach:xp,resize:xp}[e]||ak)(n,e,r),i[e]=void 0}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(n,e,i,r){return w0(n,e,i,r)}isAttached(n){let e=n&&vc(n);return!!(e&&e.isConnected)}};function gk(t){return!mc()||typeof OffscreenCanvas<"u"&&t instanceof OffscreenCanvas?Ap:Np}var Vt=class{static defaults={};static defaultRoutes=void 0;x;y;active=!1;options;$animations;tooltipPosition(n){let{x:e,y:i}=this.getProps(["x","y"],n);return{x:e,y:i}}hasValue(){return ki(this.x)&&ki(this.y)}getProps(n,e){let i=this.$animations;if(!e||!i)return this;let r={};return n.forEach(s=>{r[s]=i[s]&&i[s].active()?i[s]._to:this[s]}),r}};function mk(t,n){let e=t.options.ticks,i=vk(t),r=Math.min(e.maxTicksLimit||i,i),s=e.major.enabled?bk(n):[],o=s.length,a=s[0],l=s[o-1],c=[];if(o>r)return wk(n,c,s,o/r),c;let u=yk(s,n,r);if(o>0){let d,h,f=o>1?Math.round((l-a)/(o-1)):null;for(wc(n,c,u,te(f)?0:a-f,a),d=0,h=o-1;dr)return l}return Math.max(r,1)}function bk(t){let n=[],e,i;for(e=0,i=t.length;et==="left"?"right":t==="right"?"left":t,B0=(t,n,e)=>n==="top"||n==="left"?t[n]+e:t[n]-e,U0=(t,n)=>Math.min(n||t,t);function $0(t,n){let e=[],i=t.length/n,r=t.length,s=0;for(;so+a)))return l}function xk(t,n){oe(t,e=>{let i=e.gc,r=i.length/2,s;if(r>n){for(s=0;si?i:e,i=r&&e>i?e:i,{min:nt(e,nt(i,e)),max:nt(i,nt(e,i))}}getPadding(){return{left:this.paddingLeft||0,top:this.paddingTop||0,right:this.paddingRight||0,bottom:this.paddingBottom||0}}getTicks(){return this.ticks}getLabels(){let n=this.chart.data;return this.options.labels||(this.isHorizontal()?n.xLabels:n.yLabels)||n.labels||[]}getLabelItems(n=this.chart.chartArea){return this._labelItems||(this._labelItems=this._computeLabelItems(n))}beforeLayout(){this._cache={},this._dataLimitsCached=!1}beforeUpdate(){he(this.options.beforeUpdate,[this])}update(n,e,i){let{beginAtZero:r,grace:s,ticks:o}=this.options,a=o.sampleSize;this.beforeUpdate(),this.maxWidth=n,this.maxHeight=e,this._margins=i=Object.assign({left:0,right:0,top:0,bottom:0},i),this.ticks=null,this._labelSizes=null,this._gridLineItems=null,this._labelItems=null,this.beforeSetDimensions(),this.setDimensions(),this.afterSetDimensions(),this._maxLength=this.isHorizontal()?this.width+i.left+i.right:this.height+i.top+i.bottom,this._dataLimitsCached||(this.beforeDataLimits(),this.determineDataLimits(),this.afterDataLimits(),this._range=p0(this,s,r),this._dataLimitsCached=!0),this.beforeBuildTicks(),this.ticks=this.buildTicks()||[],this.afterBuildTicks();let l=a=s||i<=1||!this.isHorizontal()){this.labelRotation=r;return}let u=this._getLabelSizes(),d=u.widest.width,h=u.highest.height,f=Ne(this.chart.width-d,0,this.maxWidth);a=n.offset?this.maxWidth/i:f/(i-1),d+6>a&&(a=f/(i-(n.offset?.5:1)),l=this.maxHeight-fo(n.grid)-e.padding-z0(n.title,this.chart.options.font),c=Math.sqrt(d*d+h*h),o=cc(Math.min(Math.asin(Ne((u.highest.height+6)/a,-1,1)),Math.asin(Ne(l/c,-1,1))-Math.asin(Ne(h/c,-1,1)))),o=Math.max(r,Math.min(s,o))),this.labelRotation=o}afterCalculateLabelRotation(){he(this.options.afterCalculateLabelRotation,[this])}afterAutoSkip(){}beforeFit(){he(this.options.beforeFit,[this])}fit(){let n={width:0,height:0},{chart:e,options:{ticks:i,title:r,grid:s}}=this,o=this._isVisible(),a=this.isHorizontal();if(o){let l=z0(r,e.options.font);if(a?(n.width=this.maxWidth,n.height=fo(s)+l):(n.height=this.maxHeight,n.width=fo(s)+l),i.display&&this.ticks.length){let{first:c,last:u,widest:d,highest:h}=this._getLabelSizes(),f=i.padding*2,p=Mt(this.labelRotation),g=Math.cos(p),m=Math.sin(p);if(a){let v=i.mirror?0:m*d.width+g*h.height;n.height=Math.min(this.maxHeight,n.height+v+f)}else{let v=i.mirror?0:g*d.width+m*h.height;n.width=Math.min(this.maxWidth,n.width+v+f)}this._calculatePadding(c,u,m,g)}}this._handleMargins(),a?(this.width=this._length=e.width-this._margins.left-this._margins.right,this.height=n.height):(this.width=n.width,this.height=this._length=e.height-this._margins.top-this._margins.bottom)}_calculatePadding(n,e,i,r){let{ticks:{align:s,padding:o},position:a}=this.options,l=this.labelRotation!==0,c=a!=="top"&&this.axis==="x";if(this.isHorizontal()){let u=this.getPixelForTick(0)-this.left,d=this.right-this.getPixelForTick(this.ticks.length-1),h=0,f=0;l?c?(h=r*n.width,f=i*e.height):(h=i*n.height,f=r*e.width):s==="start"?f=e.width:s==="end"?h=n.width:s!=="inner"&&(h=n.width/2,f=e.width/2),this.paddingLeft=Math.max((h-u+o)*this.width/(this.width-u),0),this.paddingRight=Math.max((f-d+o)*this.width/(this.width-d),0)}else{let u=e.height/2,d=n.height/2;s==="start"?(u=0,d=n.height):s==="end"&&(u=e.height,d=0),this.paddingTop=u+o,this.paddingBottom=d+o}}_handleMargins(){this._margins&&(this._margins.left=Math.max(this.paddingLeft,this._margins.left),this._margins.top=Math.max(this.paddingTop,this._margins.top),this._margins.right=Math.max(this.paddingRight,this._margins.right),this._margins.bottom=Math.max(this.paddingBottom,this._margins.bottom))}afterFit(){he(this.options.afterFit,[this])}isHorizontal(){let{axis:n,position:e}=this.options;return e==="top"||e==="bottom"||n==="x"}isFullSize(){return this.options.fullSize}_convertTicksToLabels(n){this.beforeTickToLabelConversion(),this.generateTickLabels(n);let e,i;for(e=0,i=n.length;e({width:o[O]||0,height:a[O]||0});return{first:x(0),last:x(e-1),widest:x(D),highest:x(M),widths:o,heights:a}}getLabelForValue(n){return n}getPixelForValue(n,e){return NaN}getValueForPixel(n){}getPixelForTick(n){let e=this.ticks;return n<0||n>e.length-1?null:this.getPixelForValue(e[n].value)}getPixelForDecimal(n){this._reversePixels&&(n=1-n);let e=this._startPixel+n*this._length;return i0(this._alignToPixels?Qn(this.chart,e,0):e)}getDecimalForPixel(n){let e=(n-this._startPixel)/this._length;return this._reversePixels?1-e:e}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){let{min:n,max:e}=this;return n<0&&e<0?e:n>0&&e>0?n:0}getContext(n){let e=this.ticks||[];if(n>=0&&na*r?a/i:l/r:l*r0}_computeGridLineItems(n){let e=this.axis,i=this.chart,r=this.options,{grid:s,position:o,border:a}=r,l=s.offset,c=this.isHorizontal(),d=this.ticks.length+(l?1:0),h=fo(s),f=[],p=a.setContext(this.getContext()),g=p.display?p.width:0,m=g/2,v=function(ve){return Qn(i,ve,g)},y,w,C,b,D,M,x,O,z,H,X,ke;if(o==="top")y=v(this.bottom),M=this.bottom-h,O=y-m,H=v(n.top)+m,ke=n.bottom;else if(o==="bottom")y=v(this.top),H=n.top,ke=v(n.bottom)-m,M=y+m,O=this.top+h;else if(o==="left")y=v(this.right),D=this.right-h,x=y-m,z=v(n.left)+m,X=n.right;else if(o==="right")y=v(this.left),z=n.left,X=v(n.right)-m,D=y+m,x=this.left+h;else if(e==="x"){if(o==="center")y=v((n.top+n.bottom)/2+.5);else if(K(o)){let ve=Object.keys(o)[0],_e=o[ve];y=v(this.chart.scales[ve].getPixelForValue(_e))}H=n.top,ke=n.bottom,M=y+m,O=M+h}else if(e==="y"){if(o==="center")y=v((n.left+n.right)/2);else if(K(o)){let ve=Object.keys(o)[0],_e=o[ve];y=v(this.chart.scales[ve].getPixelForValue(_e))}D=y-m,x=D-h,z=n.left,X=n.right}let st=V(r.ticks.maxTicksLimit,d),ce=Math.max(1,Math.ceil(d/st));for(w=0;w0&&(ii-=ni/2);break}Do={left:ii,top:ts,width:ni+Hi.width,height:es+Hi.height,color:ce.backdropColor}}m.push({label:C,font:O,textOffset:X,options:{rotation:g,color:_e,strokeColor:St,strokeWidth:Ue,textAlign:ji,textBaseline:ke,translation:[b,D],backdrop:Do}})}return m}_getXAxisLabelAlignment(){let{position:n,ticks:e}=this.options;if(-Mt(this.labelRotation))return n==="top"?"left":"right";let r="center";return e.align==="start"?r="left":e.align==="end"?r="right":e.align==="inner"&&(r="inner"),r}_getYAxisLabelAlignment(n){let{position:e,ticks:{crossAlign:i,mirror:r,padding:s}}=this.options,o=this._getLabelSizes(),a=n+s,l=o.widest.width,c,u;return e==="left"?r?(u=this.right+s,i==="near"?c="left":i==="center"?(c="center",u+=l/2):(c="right",u+=l)):(u=this.right-a,i==="near"?c="right":i==="center"?(c="center",u-=l/2):(c="left",u=this.left)):e==="right"?r?(u=this.left+s,i==="near"?c="right":i==="center"?(c="center",u-=l/2):(c="left",u-=l)):(u=this.left+a,i==="near"?c="left":i==="center"?(c="center",u+=l/2):(c="right",u=this.right)):c="right",{textAlign:c,x:u}}_computeLabelArea(){if(this.options.ticks.mirror)return;let n=this.chart,e=this.options.position;if(e==="left"||e==="right")return{top:0,left:this.left,bottom:n.height,right:this.right};if(e==="top"||e==="bottom")return{top:this.top,left:0,bottom:this.bottom,right:n.width}}drawBackground(){let{ctx:n,options:{backgroundColor:e},left:i,top:r,width:s,height:o}=this;e&&(n.save(),n.fillStyle=e,n.fillRect(i,r,s,o),n.restore())}getLineWidthForValue(n){let e=this.options.grid;if(!this._isVisible()||!e.display)return 0;let r=this.ticks.findIndex(s=>s.value===n);return r>=0?e.setContext(this.getContext(r)).lineWidth:0}drawGrid(n){let e=this.options.grid,i=this.ctx,r=this._gridLineItems||(this._gridLineItems=this._computeGridLineItems(n)),s,o,a=(l,c,u)=>{!u.width||!u.color||(i.save(),i.lineWidth=u.width,i.strokeStyle=u.color,i.setLineDash(u.borderDash||[]),i.lineDashOffset=u.borderDashOffset,i.beginPath(),i.moveTo(l.x,l.y),i.lineTo(c.x,c.y),i.stroke(),i.restore())};if(e.display)for(s=0,o=r.length;s{this.draw(s)}}]:[{z:i,draw:s=>{this.drawBackground(),this.drawGrid(s),this.drawTitle()}},{z:r,draw:()=>{this.drawBorder()}},{z:e,draw:s=>{this.drawLabels(s)}}]}getMatchingVisibleMetas(n){let e=this.chart.getSortedVisibleDatasetMetas(),i=this.axis+"AxisID",r=[],s,o;for(s=0,o=e.length;s{let i=e.split("."),r=i.pop(),s=[t].concat(i).join("."),o=n[e].split("."),a=o.pop(),l=o.join(".");me.route(s,r,l,a)})}function Ak(t){return"id"in t&&"defaults"in t}var Rp=class{constructor(){this.controllers=new Xr(ti,"datasets",!0),this.elements=new Xr(Vt,"elements"),this.plugins=new Xr(Object,"plugins"),this.scales=new Xr(Vi,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements]}add(...n){this._each("register",n)}remove(...n){this._each("unregister",n)}addControllers(...n){this._each("register",n,this.controllers)}addElements(...n){this._each("register",n,this.elements)}addPlugins(...n){this._each("register",n,this.plugins)}addScales(...n){this._each("register",n,this.scales)}getController(n){return this._get(n,this.controllers,"controller")}getElement(n){return this._get(n,this.elements,"element")}getPlugin(n){return this._get(n,this.plugins,"plugin")}getScale(n){return this._get(n,this.scales,"scale")}removeControllers(...n){this._each("unregister",n,this.controllers)}removeElements(...n){this._each("unregister",n,this.elements)}removePlugins(...n){this._each("unregister",n,this.plugins)}removeScales(...n){this._each("unregister",n,this.scales)}_each(n,e,i){[...e].forEach(r=>{let s=i||this._getRegistryForType(r);i||s.isForType(r)||s===this.plugins&&r.id?this._exec(n,s,r):oe(r,o=>{let a=i||this._getRegistryForType(o);this._exec(n,a,o)})})}_exec(n,e,i){let r=lc(n);he(i["before"+r],[],i),e[n](i),he(i["after"+r],[],i)}_getRegistryForType(n){for(let e=0;es.filter(a=>!o.some(l=>a.plugin.id===l.plugin.id));this._notify(r(e,i),n,"stop"),this._notify(r(i,e),n,"start")}};function Nk(t){let n={},e=[],i=Object.keys(sn.plugins.items);for(let s=0;s1&&W0(t[0].toLowerCase());if(i)return i}throw new Error(`Cannot determine type of '${t}' axis. Please provide 'axis' or 'position' option.`)}function G0(t,n,e){if(e[n+"AxisID"]===t)return{axis:n}}function jk(t,n){if(n.data&&n.data.datasets){let e=n.data.datasets.filter(i=>i.xAxisID===t||i.yAxisID===t);if(e.length)return G0(t,"x",e[0])||G0(t,"y",e[0])}return{}}function Hk(t,n){let e=Zn[t.type]||{scales:{}},i=n.scales||{},r=Pp(t.type,n),s=Object.create(null);return Object.keys(i).forEach(o=>{let a=i[o];if(!K(a))return console.error(`Invalid scale configuration for scale: ${o}`);if(a._proxy)return console.warn(`Ignoring resolver passed as options for scale: ${o}`);let l=Lp(o,a,jk(o,t),me.scales[a.type]),c=Fk(l,r),u=e.scales||{};s[o]=zr(Object.create(null),[{axis:l},a,u[l],u[c]])}),t.data.datasets.forEach(o=>{let a=o.type||t.type,l=o.indexAxis||Pp(a,n),u=(Zn[a]||{}).scales||{};Object.keys(u).forEach(d=>{let h=Lk(d,l),f=o[h+"AxisID"]||h;s[f]=s[f]||Object.create(null),zr(s[f],[{axis:h},i[f],u[d]])})}),Object.keys(s).forEach(o=>{let a=s[o];zr(a,[me.scales[a.type],me.scale])}),s}function RD(t){let n=t.options||(t.options={});n.plugins=V(n.plugins,{}),n.scales=Hk(t,n)}function kD(t){return t=t||{},t.datasets=t.datasets||[],t.labels=t.labels||[],t}function Bk(t){return t=t||{},t.data=kD(t.data),RD(t),t}var q0=new Map,PD=new Set;function Dc(t,n){let e=q0.get(t);return e||(e=n(),q0.set(t,e),PD.add(e)),e}var po=(t,n,e)=>{let i=xn(n,e);i!==void 0&&t.add(i)},Fp=class{constructor(n){this._config=Bk(n),this._scopeCache=new Map,this._resolverCache=new Map}get platform(){return this._config.platform}get type(){return this._config.type}set type(n){this._config.type=n}get data(){return this._config.data}set data(n){this._config.data=kD(n)}get options(){return this._config.options}set options(n){this._config.options=n}get plugins(){return this._config.plugins}update(){let n=this._config;this.clearCache(),RD(n)}clearCache(){this._scopeCache.clear(),this._resolverCache.clear()}datasetScopeKeys(n){return Dc(n,()=>[[`datasets.${n}`,""]])}datasetAnimationScopeKeys(n,e){return Dc(`${n}.transition.${e}`,()=>[[`datasets.${n}.transitions.${e}`,`transitions.${e}`],[`datasets.${n}`,""]])}datasetElementScopeKeys(n,e){return Dc(`${n}-${e}`,()=>[[`datasets.${n}.elements.${e}`,`datasets.${n}`,`elements.${e}`,""]])}pluginScopeKeys(n){let e=n.id,i=this.type;return Dc(`${i}-plugin-${e}`,()=>[[`plugins.${e}`,...n.additionalOptionScopes||[]]])}_cachedScopes(n,e){let i=this._scopeCache,r=i.get(n);return(!r||e)&&(r=new Map,i.set(n,r)),r}getOptionScopes(n,e,i){let{options:r,type:s}=this,o=this._cachedScopes(n,i),a=o.get(e);if(a)return a;let l=new Set;e.forEach(u=>{n&&(l.add(n),u.forEach(d=>po(l,n,d))),u.forEach(d=>po(l,r,d)),u.forEach(d=>po(l,Zn[s]||{},d)),u.forEach(d=>po(l,me,d)),u.forEach(d=>po(l,hc,d))});let c=Array.from(l);return c.length===0&&c.push(Object.create(null)),PD.has(e)&&o.set(e,c),c}chartOptionScopes(){let{options:n,type:e}=this;return[n,Zn[e]||{},me.datasets[e]||{},{type:e},me,hc]}resolveNamedOptions(n,e,i,r=[""]){let s={$shared:!0},{resolver:o,subPrefixes:a}=Y0(this._resolverCache,n,r),l=o;if($k(o,e)){s.$shared=!1,i=_n(i)?i():i;let c=this.createResolver(n,i,a);l=Ri(o,i,c)}for(let c of e)s[c]=l[c];return s}createResolver(n,e,i=[""],r){let{resolver:s}=Y0(this._resolverCache,n,i);return K(e)?Ri(s,e,void 0,r):s}};function Y0(t,n,e){let i=t.get(n);i||(i=new Map,t.set(n,i));let r=e.join(),s=i.get(r);return s||(s={resolver:gc(n,e),subPrefixes:e.filter(a=>!a.toLowerCase().includes("hover"))},i.set(r,s)),s}var Uk=t=>K(t)&&Object.getOwnPropertyNames(t).some(n=>_n(t[n]));function $k(t,n){let{isScriptable:e,isIndexable:i}=lp(t);for(let r of n){let s=e(r),o=i(r),a=(o||s)&&t[r];if(s&&(_n(a)||Uk(a))||o&&fe(a))return!0}return!1}var zk="4.4.6",Wk=["top","bottom","left","right","chartArea"];function Z0(t,n){return t==="top"||t==="bottom"||Wk.indexOf(t)===-1&&n==="x"}function Q0(t,n){return function(e,i){return e[t]===i[t]?e[n]-i[n]:e[t]-i[t]}}function K0(t){let n=t.chart,e=n.options.animation;n.notifyPlugins("afterRender"),he(e&&e.onComplete,[t],n)}function Gk(t){let n=t.chart,e=n.options.animation;he(e&&e.onProgress,[t],n)}function LD(t){return mc()&&typeof t=="string"?t=document.getElementById(t):t&&t.length&&(t=t[0]),t&&t.canvas&&(t=t.canvas),t}var Sc={},X0=t=>{let n=LD(t);return Object.values(Sc).filter(e=>e.canvas===n).pop()};function qk(t,n,e){let i=Object.keys(t);for(let r of i){let s=+r;if(s>=n){let o=t[r];delete t[r],(e>0||s>n)&&(t[s+e]=o)}}}function Yk(t,n,e,i){return!e||t.type==="mouseout"?null:i?n:t}function _c(t,n,e){return t.options.clip?t[e]:n[e]}function Zk(t,n){let{xScale:e,yScale:i}=t;return e&&i?{left:_c(e,n,"left"),right:_c(e,n,"right"),top:_c(i,n,"top"),bottom:_c(i,n,"bottom")}:n}var kc=(()=>{class t{static defaults=me;static instances=Sc;static overrides=Zn;static registry=sn;static version=zk;static getChart=X0;static register(...e){sn.add(...e),J0()}static unregister(...e){sn.remove(...e),J0()}constructor(e,i){let r=this.config=new Fp(i),s=LD(e),o=X0(s);if(o)throw new Error("Canvas is already in use. Chart with ID '"+o.id+"' must be destroyed before the canvas with ID '"+o.canvas.id+"' can be reused.");let a=r.createResolver(r.chartOptionScopes(),this.getContext());this.platform=new(r.platform||gk(s)),this.platform.updateConfig(r);let l=this.platform.acquireContext(s,a.aspectRatio),c=l&&l.canvas,u=c&&c.height,d=c&&c.width;if(this.id=Kw(),this.ctx=l,this.canvas=c,this.width=d,this.height=u,this._options=a,this._aspectRatio=this.aspectRatio,this._layers=[],this._metasets=[],this._stacks=void 0,this.boxes=[],this.currentDevicePixelRatio=void 0,this.chartArea=void 0,this._active=[],this._lastEvent=void 0,this._listeners={},this._responsiveListeners=void 0,this._sortedMetasets=[],this.scales={},this._plugins=new kp,this.$proxies={},this._hiddenIndices={},this.attached=!1,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=l0(h=>this.update(h),a.resizeDelay||0),this._dataChanges=[],Sc[this.id]=this,!l||!c){console.error("Failed to create chart: can't acquire context from the given item");return}Mn.listen(this,"complete",K0),Mn.listen(this,"progress",Gk),this._initialize(),this.attached&&this.update()}get aspectRatio(){let{options:{aspectRatio:e,maintainAspectRatio:i},width:r,height:s,_aspectRatio:o}=this;return te(e)?i&&o?o:s?r/s:null:e}get data(){return this.config.data}set data(e){this.config.data=e}get options(){return this._options}set options(e){this.config.options=e}get registry(){return sn}_initialize(){return this.notifyPlugins("beforeInit"),this.options.responsive?this.resize():hp(this,this.options.devicePixelRatio),this.bindEvents(),this.notifyPlugins("afterInit"),this}clear(){return sp(this.canvas,this.ctx),this}stop(){return Mn.stop(this),this}resize(e,i){Mn.running(this)?this._resizeBeforeDraw={width:e,height:i}:this._resize(e,i)}_resize(e,i){let r=this.options,s=this.canvas,o=r.maintainAspectRatio&&this.aspectRatio,a=this.platform.getMaximumSize(s,e,i,o),l=r.devicePixelRatio||this.platform.getDevicePixelRatio(),c=this.width?"resize":"attach";this.width=a.width,this.height=a.height,this._aspectRatio=this.aspectRatio,hp(this,l,!0)&&(this.notifyPlugins("resize",{size:a}),he(r.onResize,[this,a],this),this.attached&&this._doResize(c)&&this.render())}ensureScalesHaveIDs(){let i=this.options.scales||{};oe(i,(r,s)=>{r.id=s})}buildOrUpdateScales(){let e=this.options,i=e.scales,r=this.scales,s=Object.keys(r).reduce((a,l)=>(a[l]=!1,a),{}),o=[];i&&(o=o.concat(Object.keys(i).map(a=>{let l=i[a],c=Lp(a,l),u=c==="r",d=c==="x";return{options:l,dposition:u?"chartArea":d?"bottom":"left",dtype:u?"radialLinear":d?"category":"linear"}}))),oe(o,a=>{let l=a.options,c=l.id,u=Lp(c,l),d=V(l.type,a.dtype);(l.position===void 0||Z0(l.position,u)!==Z0(a.dposition))&&(l.position=a.dposition),s[c]=!0;let h=null;if(c in r&&r[c].type===d)h=r[c];else{let f=sn.getScale(d);h=new f({id:c,type:d,ctx:this.ctx,chart:this}),r[h.id]=h}h.init(l,e)}),oe(s,(a,l)=>{a||delete r[l]}),oe(r,a=>{Ge.configure(this,a,a.options),Ge.addBox(this,a)})}_updateMetasets(){let e=this._metasets,i=this.data.datasets.length,r=e.length;if(e.sort((s,o)=>s.index-o.index),r>i){for(let s=i;si.length&&delete this._stacks,e.forEach((r,s)=>{i.filter(o=>o===r._dataset).length===0&&this._destroyDatasetMeta(s)})}buildOrUpdateControllers(){let e=[],i=this.data.datasets,r,s;for(this._removeUnreferencedMetasets(),r=0,s=i.length;r{this.getDatasetMeta(i).controller.reset()},this)}reset(){this._resetElements(),this.notifyPlugins("reset")}update(e){let i=this.config;i.update();let r=this._options=i.createResolver(i.chartOptionScopes(),this.getContext()),s=this._animationsDisabled=!r.animation;if(this._updateScales(),this._checkEventBindings(),this._updateHiddenIndices(),this._plugins.invalidate(),this.notifyPlugins("beforeUpdate",{mode:e,cancelable:!0})===!1)return;let o=this.buildOrUpdateControllers();this.notifyPlugins("beforeElementsUpdate");let a=0;for(let u=0,d=this.data.datasets.length;u{u.reset()}),this._updateDatasets(e),this.notifyPlugins("afterUpdate",{mode:e}),this._layers.sort(Q0("z","_idx"));let{_active:l,_lastEvent:c}=this;c?this._eventHandler(c,!0):l.length&&this._updateHoverStyles(l,l,!0),this.render()}_updateScales(){oe(this.scales,e=>{Ge.removeBox(this,e)}),this.ensureScalesHaveIDs(),this.buildOrUpdateScales()}_checkEventBindings(){let e=this.options,i=new Set(Object.keys(this._listeners)),r=new Set(e.events);(!Gf(i,r)||!!this._responsiveListeners!==e.responsive)&&(this.unbindEvents(),this.bindEvents())}_updateHiddenIndices(){let{_hiddenIndices:e}=this,i=this._getUniformDataChanges()||[];for(let{method:r,start:s,count:o}of i){let a=r==="_removeElements"?-o:o;qk(e,s,a)}}_getUniformDataChanges(){let e=this._dataChanges;if(!e||!e.length)return;this._dataChanges=[];let i=this.data.datasets.length,r=o=>new Set(e.filter(a=>a[0]===o).map((a,l)=>l+","+a.splice(1).join(","))),s=r(0);for(let o=1;oo.split(",")).map(o=>({method:o[1],start:+o[2],count:+o[3]}))}_updateLayout(e){if(this.notifyPlugins("beforeLayout",{cancelable:!0})===!1)return;Ge.update(this,this.width,this.height,e);let i=this.chartArea,r=i.width<=0||i.height<=0;this._layers=[],oe(this.boxes,s=>{r&&s.position==="chartArea"||(s.configure&&s.configure(),this._layers.push(...s._layers()))},this),this._layers.forEach((s,o)=>{s._idx=o}),this.notifyPlugins("afterLayout")}_updateDatasets(e){if(this.notifyPlugins("beforeDatasetsUpdate",{mode:e,cancelable:!0})!==!1){for(let i=0,r=this.data.datasets.length;i=0;--i)this._drawDataset(e[i]);this.notifyPlugins("afterDatasetsDraw")}_drawDataset(e){let i=this.ctx,r=e._clip,s=!r.disabled,o=Zk(e,this.chartArea),a={meta:e,index:e.index,cancelable:!0};this.notifyPlugins("beforeDatasetDraw",a)!==!1&&(s&&ao(i,{left:r.left===!1?0:o.left-r.left,right:r.right===!1?this.width:o.right+r.right,top:r.top===!1?0:o.top-r.top,bottom:r.bottom===!1?this.height:o.bottom+r.bottom}),e.controller.draw(),s&&lo(i),a.cancelable=!1,this.notifyPlugins("afterDatasetDraw",a))}isPointInArea(e){return en(e,this.chartArea,this._minPadding)}getElementsAtEventForMode(e,i,r,s){let o=QR.modes[i];return typeof o=="function"?o(this,e,r,s):[]}getDatasetMeta(e){let i=this.data.datasets[e],r=this._metasets,s=r.filter(o=>o&&o._dataset===i).pop();return s||(s={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:i&&i.order||0,index:e,_dataset:i,_parsed:[],_sorted:!1},r.push(s)),s}getContext(){return this.$context||(this.$context=En(null,{chart:this,type:"chart"}))}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(e){let i=this.data.datasets[e];if(!i)return!1;let r=this.getDatasetMeta(e);return typeof r.hidden=="boolean"?!r.hidden:!i.hidden}setDatasetVisibility(e,i){let r=this.getDatasetMeta(e);r.hidden=!i}toggleDataVisibility(e){this._hiddenIndices[e]=!this._hiddenIndices[e]}getDataVisibility(e){return!this._hiddenIndices[e]}_updateVisibility(e,i,r){let s=r?"show":"hide",o=this.getDatasetMeta(e),a=o.controller._resolveAnimations(void 0,s);Wr(i)?(o.data[i].hidden=!r,this.update()):(this.setDatasetVisibility(e,r),a.update(o,{visible:r}),this.update(l=>l.datasetIndex===e?s:void 0))}hide(e,i){this._updateVisibility(e,i,!1)}show(e,i){this._updateVisibility(e,i,!0)}_destroyDatasetMeta(e){let i=this._metasets[e];i&&i.controller&&i.controller._destroy(),delete this._metasets[e]}_stop(){let e,i;for(this.stop(),Mn.remove(this),e=0,i=this.data.datasets.length;e{i.addEventListener(this,o,a),e[o]=a},s=(o,a,l)=>{o.offsetX=a,o.offsetY=l,this._eventHandler(o)};oe(this.options.events,o=>r(o,s))}bindResponsiveEvents(){this._responsiveListeners||(this._responsiveListeners={});let e=this._responsiveListeners,i=this.platform,r=(c,u)=>{i.addEventListener(this,c,u),e[c]=u},s=(c,u)=>{e[c]&&(i.removeEventListener(this,c,u),delete e[c])},o=(c,u)=>{this.canvas&&this.resize(c,u)},a,l=()=>{s("attach",l),this.attached=!0,this.resize(),r("resize",o),r("detach",a)};a=()=>{this.attached=!1,s("resize",o),this._stop(),this._resize(0,0),r("attach",l)},i.isAttached(this.canvas)?l():a()}unbindEvents(){oe(this._listeners,(e,i)=>{this.platform.removeEventListener(this,i,e)}),this._listeners={},oe(this._responsiveListeners,(e,i)=>{this.platform.removeEventListener(this,i,e)}),this._responsiveListeners=void 0}updateHoverStyle(e,i,r){let s=r?"set":"remove",o,a,l,c;for(i==="dataset"&&(o=this.getDatasetMeta(e[0].datasetIndex),o.controller["_"+s+"DatasetHoverStyle"]()),l=0,c=e.length;l{let l=this.getDatasetMeta(o);if(!l)throw new Error("No dataset found at index "+o);return{datasetIndex:o,element:l.data[a],index:a}});!so(r,i)&&(this._active=r,this._lastEvent=null,this._updateHoverStyles(r,i))}notifyPlugins(e,i,r){return this._plugins.notify(this,e,i,r)}isPluginEnabled(e){return this._plugins._cache.filter(i=>i.plugin.id===e).length===1}_updateHoverStyles(e,i,r){let s=this.options.hover,o=(c,u)=>c.filter(d=>!u.some(h=>d.datasetIndex===h.datasetIndex&&d.index===h.index)),a=o(i,e),l=r?e:o(e,i);a.length&&this.updateHoverStyle(a,s.mode,!1),l.length&&s.mode&&this.updateHoverStyle(l,s.mode,!0)}_eventHandler(e,i){let r={event:e,replay:i,cancelable:!0,inChartArea:this.isPointInArea(e)},s=a=>(a.options.events||this.options.events).includes(e.native.type);if(this.notifyPlugins("beforeEvent",r,s)===!1)return;let o=this._handleEvent(e,i,r.inChartArea);return r.cancelable=!1,this.notifyPlugins("afterEvent",r,s),(o||r.changed)&&this.render(),this}_handleEvent(e,i,r){let{_active:s=[],options:o}=this,a=i,l=this._getActiveElements(e,s,r,a),c=e0(e),u=Yk(e,this._lastEvent,r,c);r&&(this._lastEvent=null,he(o.onHover,[e,l,this],this),c&&he(o.onClick,[e,l,this],this));let d=!so(l,s);return(d||i)&&(this._active=l,this._updateHoverStyles(l,s,i)),this._lastEvent=u,d}_getActiveElements(e,i,r,s){if(e.type==="mouseout")return[];if(!r)return i;let o=this.options.hover;return this.getElementsAtEventForMode(e,o.mode,o,s)}}return t})();function J0(){return oe(kc.instances,t=>t._plugins.invalidate())}function Qk(t,n,e){let{startAngle:i,pixelMargin:r,x:s,y:o,outerRadius:a,innerRadius:l}=n,c=r/a;t.beginPath(),t.arc(s,o,a,i-c,e+c),l>r?(c=r/l,t.arc(s,o,l,e+c,i-c,!0)):t.arc(s,o,r,e+De,i-De),t.closePath(),t.clip()}function Kk(t){return pc(t,["outerStart","outerEnd","innerStart","innerEnd"])}function Xk(t,n,e,i){let r=Kk(t.options.borderRadius),s=(e-n)/2,o=Math.min(s,i*n/2),a=l=>{let c=(e-Math.min(s,l))*i/2;return Ne(l,0,Math.min(s,c))};return{outerStart:a(r.outerStart),outerEnd:a(r.outerEnd),innerStart:Ne(r.innerStart,0,o),innerEnd:Ne(r.innerEnd,0,o)}}function Kr(t,n,e,i){return{x:e+t*Math.cos(n),y:i+t*Math.sin(n)}}function Ac(t,n,e,i,r,s){let{x:o,y:a,startAngle:l,pixelMargin:c,innerRadius:u}=n,d=Math.max(n.outerRadius+i+e-c,0),h=u>0?u+i+e+c:0,f=0,p=r-l;if(i){let ce=u>0?u-i:0,ve=d>0?d-i:0,_e=(ce+ve)/2,St=_e!==0?p*_e/(_e+i):p;f=(p-St)/2}let g=Math.max(.001,p*d-e/pe)/d,m=(p-g)/2,v=l+m+f,y=r-m-f,{outerStart:w,outerEnd:C,innerStart:b,innerEnd:D}=Xk(n,h,d,y-v),M=d-w,x=d-C,O=v+w/M,z=y-C/x,H=h+b,X=h+D,ke=v+b/H,st=y-D/X;if(t.beginPath(),s){let ce=(O+z)/2;if(t.arc(o,a,d,O,ce),t.arc(o,a,d,ce,z),C>0){let Ue=Kr(x,z,o,a);t.arc(Ue.x,Ue.y,C,z,y+De)}let ve=Kr(X,y,o,a);if(t.lineTo(ve.x,ve.y),D>0){let Ue=Kr(X,st,o,a);t.arc(Ue.x,Ue.y,D,y+De,st+Math.PI)}let _e=(y-D/h+(v+b/h))/2;if(t.arc(o,a,h,y-D/h,_e,!0),t.arc(o,a,h,_e,v+b/h,!0),b>0){let Ue=Kr(H,ke,o,a);t.arc(Ue.x,Ue.y,b,ke+Math.PI,v-De)}let St=Kr(M,v,o,a);if(t.lineTo(St.x,St.y),w>0){let Ue=Kr(M,O,o,a);t.arc(Ue.x,Ue.y,w,v-De,O)}}else{t.moveTo(o,a);let ce=Math.cos(O)*d+o,ve=Math.sin(O)*d+a;t.lineTo(ce,ve);let _e=Math.cos(z)*d+o,St=Math.sin(z)*d+a;t.lineTo(_e,St)}t.closePath()}function Jk(t,n,e,i,r){let{fullCircles:s,startAngle:o,circumference:a}=n,l=n.endAngle;if(s){Ac(t,n,e,i,l,r);for(let c=0;cn!=="borderDash"};circumference;endAngle;fullCircles;innerRadius;outerRadius;pixelMargin;startAngle;constructor(n){super(),this.options=void 0,this.circumference=void 0,this.startAngle=void 0,this.endAngle=void 0,this.innerRadius=void 0,this.outerRadius=void 0,this.pixelMargin=0,this.fullCircles=0,n&&Object.assign(this,n)}inRange(n,e,i){let r=this.getProps(["x","y"],i),{angle:s,distance:o}=Qf(r,{x:n,y:e}),{startAngle:a,endAngle:l,innerRadius:c,outerRadius:u,circumference:d}=this.getProps(["startAngle","endAngle","innerRadius","outerRadius","circumference"],i),h=(this.options.spacing+this.options.borderWidth)/2,f=V(d,l-a),p=qr(s,a,l)&&a!==l,g=f>=ge||p,m=nn(o,c+h,u+h);return g&&m}getCenterPoint(n){let{x:e,y:i,startAngle:r,endAngle:s,innerRadius:o,outerRadius:a}=this.getProps(["x","y","startAngle","endAngle","innerRadius","outerRadius"],n),{offset:l,spacing:c}=this.options,u=(r+s)/2,d=(o+a+c+l)/2;return{x:e+Math.cos(u)*d,y:i+Math.sin(u)*d}}tooltipPosition(n){return this.getCenterPoint(n)}draw(n){let{options:e,circumference:i}=this,r=(e.offset||0)/4,s=(e.spacing||0)/2,o=e.circular;if(this.pixelMargin=e.borderAlign==="inner"?.33:0,this.fullCircles=i>ge?Math.floor(i/ge):0,i===0||this.innerRadius<0||this.outerRadius<0)return;n.save();let a=(this.startAngle+this.endAngle)/2;n.translate(Math.cos(a)*r,Math.sin(a)*r);let l=1-Math.sin(Math.min(pe,i||0)),c=r*l;n.fillStyle=e.backgroundColor,n.strokeStyle=e.borderColor,Jk(n,this,c,s,o),eP(n,this,c,s,o),n.restore()}};function FD(t,n,e=n){t.lineCap=V(e.borderCapStyle,n.borderCapStyle),t.setLineDash(V(e.borderDash,n.borderDash)),t.lineDashOffset=V(e.borderDashOffset,n.borderDashOffset),t.lineJoin=V(e.borderJoinStyle,n.borderJoinStyle),t.lineWidth=V(e.borderWidth,n.borderWidth),t.strokeStyle=V(e.borderColor,n.borderColor)}function tP(t,n,e){t.lineTo(e.x,e.y)}function nP(t){return t.stepped?h0:t.tension||t.cubicInterpolationMode==="monotone"?f0:tP}function VD(t,n,e={}){let i=t.length,{start:r=0,end:s=i-1}=e,{start:o,end:a}=n,l=Math.max(r,o),c=Math.min(s,a),u=ra&&s>a;return{count:i,start:l,loop:n.loop,ilen:c(o+(c?a-C:C))%s,w=()=>{g!==m&&(t.lineTo(u,m),t.lineTo(u,g),t.lineTo(u,v))};for(l&&(f=r[y(0)],t.moveTo(f.x,f.y)),h=0;h<=a;++h){if(f=r[y(h)],f.skip)continue;let C=f.x,b=f.y,D=C|0;D===p?(bm&&(m=b),u=(d*u+C)/++d):(w(),t.lineTo(C,b),p=D,d=0,g=m=b),v=b}w()}function jp(t){let n=t.options,e=n.borderDash&&n.borderDash.length;return!t._decimated&&!t._loop&&!n.tension&&n.cubicInterpolationMode!=="monotone"&&!n.stepped&&!e?rP:iP}function sP(t){return t.stepped?_0:t.tension||t.cubicInterpolationMode==="monotone"?C0:Yn}function oP(t,n,e,i){let r=n._path;r||(r=n._path=new Path2D,n.path(r,e,i)&&r.closePath()),FD(t,n.options),t.stroke(r)}function aP(t,n,e,i){let{segments:r,options:s}=n,o=jp(n);for(let a of r)FD(t,s,a.style),t.beginPath(),o(t,n,a,{start:e,end:e+i-1})&&t.closePath(),t.stroke()}var lP=typeof Path2D=="function";function cP(t,n,e,i){lP&&!n.options.segment?oP(t,n,e,i):aP(t,n,e,i)}var Pc=(()=>{class t extends Vt{static id="line";static defaults={borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderWidth:3,capBezierPoints:!0,cubicInterpolationMode:"default",fill:!1,spanGaps:!1,stepped:!1,tension:0};static defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};static descriptors={_scriptable:!0,_indexable:e=>e!=="borderDash"&&e!=="fill"};constructor(e){super(),this.animated=!0,this.options=void 0,this._chart=void 0,this._loop=void 0,this._fullLoop=void 0,this._path=void 0,this._points=void 0,this._segments=void 0,this._decimated=!1,this._pointsUpdated=!1,this._datasetIndex=void 0,e&&Object.assign(this,e)}updateControlPoints(e,i){let r=this.options;if((r.tension||r.cubicInterpolationMode==="monotone")&&!r.stepped&&!this._pointsUpdated){let s=r.spanGaps?this._loop:this._fullLoop;b0(this._points,r,e,s,i),this._pointsUpdated=!0}}set points(e){this._points=e,delete this._segments,delete this._path,this._pointsUpdated=!1}get points(){return this._points}get segments(){return this._segments||(this._segments=E0(this,this.options.segment))}first(){let e=this.segments,i=this.points;return e.length&&i[e[0].start]}last(){let e=this.segments,i=this.points,r=e.length;return r&&i[e[r-1].end]}interpolate(e,i){let r=this.options,s=e[i],o=this.points,a=vp(this,{property:i,start:s,end:s});if(!a.length)return;let l=[],c=sP(r),u,d;for(u=0,d=a.length;u{class t extends Vt{static id="point";parsed;skip;stop;static defaults={borderWidth:1,hitRadius:1,hoverBorderWidth:1,hoverRadius:4,pointStyle:"circle",radius:3,rotation:0};static defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};constructor(e){super(),this.options=void 0,this.parsed=void 0,this.skip=void 0,this.stop=void 0,e&&Object.assign(this,e)}inRange(e,i,r){let s=this.options,{x:o,y:a}=this.getProps(["x","y"],r);return Math.pow(e-o,2)+Math.pow(i-a,2)t.replace("rgb(","rgba(").replace(")",", 0.5)"));function HD(t){return Bp[t%Bp.length]}function BD(t){return tD[t%tD.length]}function vP(t,n){return t.borderColor=HD(n),t.backgroundColor=BD(n),++n}function yP(t,n){return t.backgroundColor=t.data.map(()=>HD(n++)),n}function bP(t,n){return t.backgroundColor=t.data.map(()=>BD(n++)),n}function wP(t){let n=0;return(e,i)=>{let r=t.getDatasetMeta(i).controller;r instanceof Zp?n=yP(e,n):r instanceof ID?n=bP(e,n):r&&(n=vP(e,n))}}function nD(t){let n;for(n in t)if(t[n].borderColor||t[n].backgroundColor)return!0;return!1}function DP(t){return t&&(t.borderColor||t.backgroundColor)}function _P(){return me.borderColor!=="rgba(0,0,0,0.1)"||me.backgroundColor!=="rgba(0,0,0,0.1)"}var CP={id:"colors",defaults:{enabled:!0,forceOverride:!1},beforeLayout(t,n,e){if(!e.enabled)return;let{data:{datasets:i},options:r}=t.config,{elements:s}=r,o=nD(i)||DP(r)||s&&nD(s)||_P();if(!e.forceOverride&&o)return;let a=wP(t);i.forEach(a)}};function xP(t,n,e,i,r){let s=r.samples||i;if(s>=e)return t.slice(n,n+e);let o=[],a=(e-2)/(s-2),l=0,c=n+e-1,u=n,d,h,f,p,g;for(o[l++]=t[u],d=0;df&&(f=p,h=t[y],g=y);o[l++]=h,u=g}return o[l++]=t[c],o}function EP(t,n,e,i){let r=0,s=0,o,a,l,c,u,d,h,f,p,g,m=[],v=n+e-1,y=t[n].x,C=t[v].x-y;for(o=n;og&&(g=c,h=o),r=(s*r+a.x)/++s;else{let D=o-1;if(!te(d)&&!te(h)){let M=Math.min(d,h),x=Math.max(d,h);M!==f&&M!==D&&m.push(ae(S({},t[M]),{x:r})),x!==f&&x!==D&&m.push(ae(S({},t[x]),{x:r}))}o>0&&D!==f&&m.push(t[D]),m.push(a),u=b,s=0,p=g=c,d=h=f=o}}return m}function UD(t){if(t._decimated){let n=t._data;delete t._decimated,delete t._data,Object.defineProperty(t,"data",{configurable:!0,enumerable:!0,writable:!0,value:n})}}function iD(t){t.data.datasets.forEach(n=>{UD(n)})}function MP(t,n){let e=n.length,i=0,r,{iScale:s}=t,{min:o,max:a,minDefined:l,maxDefined:c}=s.getUserBounds();return l&&(i=Ne(Jt(n,s.axis,o).lo,0,e-1)),c?r=Ne(Jt(n,s.axis,a).hi+1,i,e)-i:r=e-i,{start:i,count:r}}var SP={id:"decimation",defaults:{algorithm:"min-max",enabled:!1},beforeElementsUpdate:(t,n,e)=>{if(!e.enabled){iD(t);return}let i=t.width;t.data.datasets.forEach((r,s)=>{let{_data:o,indexAxis:a}=r,l=t.getDatasetMeta(s),c=o||r.data;if(Qr([a,t.options.indexAxis])==="y"||!l.controller.supportsDecimation)return;let u=t.scales[l.xAxisID];if(u.type!=="linear"&&u.type!=="time"||t.options.parsing)return;let{start:d,count:h}=MP(l,c),f=e.threshold||4*i;if(h<=f){UD(r);return}te(o)&&(r._data=c,delete r.data,Object.defineProperty(r,"data",{configurable:!0,enumerable:!0,get:function(){return this._decimated},set:function(g){this._data=g}}));let p;switch(e.algorithm){case"lttb":p=xP(c,d,h,i,e);break;case"min-max":p=EP(c,d,h,i);break;default:throw new Error(`Unsupported decimation algorithm '${e.algorithm}'`)}r._decimated=p})},destroy(t){iD(t)}};function IP(t,n,e){let i=t.segments,r=t.points,s=n.points,o=[];for(let a of i){let{start:l,end:c}=a;c=Qp(l,c,r);let u=Up(e,r[l],r[c],a.loop);if(!n.segments){o.push({source:a,target:u,start:r[l],end:r[c]});continue}let d=vp(n,u);for(let h of d){let f=Up(e,s[h.start],s[h.end],h.loop),p=mp(a,r,f);for(let g of p)o.push({source:g,target:h,start:{[e]:rD(u,f,"start",Math.max)},end:{[e]:rD(u,f,"end",Math.min)}})}}return o}function Up(t,n,e,i){if(i)return;let r=n[t],s=e[t];return t==="angle"&&(r=tt(r),s=tt(s)),{property:t,start:r,end:s}}function OP(t,n){let{x:e=null,y:i=null}=t||{},r=n.points,s=[];return n.segments.forEach(({start:o,end:a})=>{a=Qp(o,a,r);let l=r[o],c=r[a];i!==null?(s.push({x:l.x,y:i}),s.push({x:c.x,y:i})):e!==null&&(s.push({x:e,y:l.y}),s.push({x:e,y:c.y}))}),s}function Qp(t,n,e){for(;n>t;n--){let i=e[n];if(!isNaN(i.x)&&!isNaN(i.y))break}return n}function rD(t,n,e,i){return t&&n?i(t[e],n[e]):t?t[e]:n?n[e]:0}function $D(t,n){let e=[],i=!1;return fe(t)?(i=!0,e=t):e=OP(t,n),e.length?new Pc({points:e,options:{tension:0},_loop:i,_fullLoop:i}):null}function sD(t){return t&&t.fill!==!1}function TP(t,n,e){let r=t[n].fill,s=[n],o;if(!e)return r;for(;r!==!1&&s.indexOf(r)===-1;){if(!be(r))return r;if(o=t[r],!o)return!1;if(o.visible)return r;s.push(r),r=o.fill}return!1}function AP(t,n,e){let i=PP(t);if(K(i))return isNaN(i.value)?!1:i;let r=parseFloat(i);return be(r)&&Math.floor(r)===r?NP(i[0],n,r,e):["origin","start","end","stack","shape"].indexOf(i)>=0&&i}function NP(t,n,e,i){return(t==="-"||t==="+")&&(e=n+e),e===n||e<0||e>=i?!1:e}function RP(t,n){let e=null;return t==="start"?e=n.bottom:t==="end"?e=n.top:K(t)?e=n.getPixelForValue(t.value):n.getBasePixel&&(e=n.getBasePixel()),e}function kP(t,n,e){let i;return t==="start"?i=e:t==="end"?i=n.options.reverse?n.min:n.max:K(t)?i=t.value:i=n.getBaseValue(),i}function PP(t){let n=t.options,e=n.fill,i=V(e&&e.target,e);return i===void 0&&(i=!!n.backgroundColor),i===!1||i===null?!1:i===!0?"origin":i}function LP(t){let{scale:n,index:e,line:i}=t,r=[],s=i.segments,o=i.points,a=FP(n,e);a.push($D({x:null,y:n.bottom},i));for(let l=0;l=0;--o){let a=r[o].$filler;a&&(a.line.updateControlPoints(s,a.axis),i&&a.fill&&Sp(t.ctx,a,s))}},beforeDatasetsDraw(t,n,e){if(e.drawTime!=="beforeDatasetsDraw")return;let i=t.getSortedVisibleDatasetMetas();for(let r=i.length-1;r>=0;--r){let s=i[r].$filler;sD(s)&&Sp(t.ctx,s,t.chartArea)}},beforeDatasetDraw(t,n,e){let i=n.meta.$filler;!sD(i)||e.drawTime!=="beforeDatasetDraw"||Sp(t.ctx,i,t.chartArea)},defaults:{propagate:!0,drawTime:"beforeDatasetDraw"}},cD=(t,n)=>{let{boxHeight:e=n,boxWidth:i=n}=t;return t.usePointStyle&&(e=Math.min(e,n),i=t.pointStyleWidth||Math.min(i,n)),{boxWidth:i,boxHeight:e,itemHeight:Math.max(n,e)}},YP=(t,n)=>t!==null&&n!==null&&t.datasetIndex===n.datasetIndex&&t.index===n.index,Rc=class extends Vt{constructor(n){super(),this._added=!1,this.legendHitBoxes=[],this._hoveredItem=null,this.doughnutMode=!1,this.chart=n.chart,this.options=n.options,this.ctx=n.ctx,this.legendItems=void 0,this.columnSizes=void 0,this.lineWidths=void 0,this.maxHeight=void 0,this.maxWidth=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.height=void 0,this.width=void 0,this._margins=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(n,e,i){this.maxWidth=n,this.maxHeight=e,this._margins=i,this.setDimensions(),this.buildLabels(),this.fit()}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=this._margins.left,this.right=this.width):(this.height=this.maxHeight,this.top=this._margins.top,this.bottom=this.height)}buildLabels(){let n=this.options.labels||{},e=he(n.generateLabels,[this.chart],this)||[];n.filter&&(e=e.filter(i=>n.filter(i,this.chart.data))),n.sort&&(e=e.sort((i,r)=>n.sort(i,r,this.chart.data))),this.options.reverse&&e.reverse(),this.legendItems=e}fit(){let{options:n,ctx:e}=this;if(!n.display){this.width=this.height=0;return}let i=n.labels,r=Te(i.font),s=r.size,o=this._computeTitleHeight(),{boxWidth:a,itemHeight:l}=cD(i,s),c,u;e.font=r.string,this.isHorizontal()?(c=this.maxWidth,u=this._fitRows(o,s,a,l)+10):(u=this.maxHeight,c=this._fitCols(o,r,a,l)+10),this.width=Math.min(c,n.maxWidth||this.maxWidth),this.height=Math.min(u,n.maxHeight||this.maxHeight)}_fitRows(n,e,i,r){let{ctx:s,maxWidth:o,options:{labels:{padding:a}}}=this,l=this.legendHitBoxes=[],c=this.lineWidths=[0],u=r+a,d=n;s.textAlign="left",s.textBaseline="middle";let h=-1,f=-u;return this.legendItems.forEach((p,g)=>{let m=i+e/2+s.measureText(p.text).width;(g===0||c[c.length-1]+m+2*a>o)&&(d+=u,c[c.length-(g>0?0:1)]=0,f+=u,h++),l[g]={left:0,top:f,row:h,width:m,height:r},c[c.length-1]+=m+a}),d}_fitCols(n,e,i,r){let{ctx:s,maxHeight:o,options:{labels:{padding:a}}}=this,l=this.legendHitBoxes=[],c=this.columnSizes=[],u=o-n,d=a,h=0,f=0,p=0,g=0;return this.legendItems.forEach((m,v)=>{let{itemWidth:y,itemHeight:w}=ZP(i,e,s,m,r);v>0&&f+w+2*a>u&&(d+=h+a,c.push({width:h,height:f}),p+=h+a,g++,h=f=0),l[v]={left:p,top:f,col:g,width:y,height:w},h=Math.max(h,y),f+=w+a}),d+=h,c.push({width:h,height:f}),d}adjustHitBoxes(){if(!this.options.display)return;let n=this._computeTitleHeight(),{legendHitBoxes:e,options:{align:i,labels:{padding:r},rtl:s}}=this,o=Pi(s,this.left,this.width);if(this.isHorizontal()){let a=0,l=He(i,this.left+r,this.right-this.lineWidths[a]);for(let c of e)a!==c.row&&(a=c.row,l=He(i,this.left+r,this.right-this.lineWidths[a])),c.top+=this.top+n+r,c.left=o.leftForLtr(o.x(l),c.width),l+=c.width+r}else{let a=0,l=He(i,this.top+n+r,this.bottom-this.columnSizes[a].height);for(let c of e)c.col!==a&&(a=c.col,l=He(i,this.top+n+r,this.bottom-this.columnSizes[a].height)),c.top=l,c.left+=this.left+r,c.left=o.leftForLtr(o.x(c.left),c.width),l+=c.height+r}}isHorizontal(){return this.options.position==="top"||this.options.position==="bottom"}draw(){if(this.options.display){let n=this.ctx;ao(n,this),this._draw(),lo(n)}}_draw(){let{options:n,columnSizes:e,lineWidths:i,ctx:r}=this,{align:s,labels:o}=n,a=me.color,l=Pi(n.rtl,this.left,this.width),c=Te(o.font),{padding:u}=o,d=c.size,h=d/2,f;this.drawTitle(),r.textAlign=l.textAlign("left"),r.textBaseline="middle",r.lineWidth=.5,r.font=c.string;let{boxWidth:p,boxHeight:g,itemHeight:m}=cD(o,d),v=function(D,M,x){if(isNaN(p)||p<=0||isNaN(g)||g<0)return;r.save();let O=V(x.lineWidth,1);if(r.fillStyle=V(x.fillStyle,a),r.lineCap=V(x.lineCap,"butt"),r.lineDashOffset=V(x.lineDashOffset,0),r.lineJoin=V(x.lineJoin,"miter"),r.lineWidth=O,r.strokeStyle=V(x.strokeStyle,a),r.setLineDash(V(x.lineDash,[])),o.usePointStyle){let z={radius:g*Math.SQRT2/2,pointStyle:x.pointStyle,rotation:x.rotation,borderWidth:O},H=l.xPlus(D,p/2),X=M+h;op(r,z,H,X,o.pointStyleWidth&&p)}else{let z=M+Math.max((d-g)/2,0),H=l.leftForLtr(D,p),X=Xn(x.borderRadius);r.beginPath(),Object.values(X).some(ke=>ke!==0)?Zr(r,{x:H,y:z,w:p,h:g,radius:X}):r.rect(H,z,p,g),r.fill(),O!==0&&r.stroke()}r.restore()},y=function(D,M,x){Kn(r,x.text,D,M+m/2,c,{strikethrough:x.hidden,textAlign:l.textAlign(x.textAlign)})},w=this.isHorizontal(),C=this._computeTitleHeight();w?f={x:He(s,this.left+u,this.right-i[0]),y:this.top+u+C,line:0}:f={x:this.left+u,y:He(s,this.top+C+u,this.bottom-e[0].height),line:0},pp(this.ctx,n.textDirection);let b=m+u;this.legendItems.forEach((D,M)=>{r.strokeStyle=D.fontColor,r.fillStyle=D.fontColor;let x=r.measureText(D.text).width,O=l.textAlign(D.textAlign||(D.textAlign=o.textAlign)),z=p+h+x,H=f.x,X=f.y;l.setWidth(this.width),w?M>0&&H+z+u>this.right&&(X=f.y+=b,f.line++,H=f.x=He(s,this.left+u,this.right-i[f.line])):M>0&&X+b>this.bottom&&(H=f.x=H+e[f.line].width+u,f.line++,X=f.y=He(s,this.top+C+u,this.bottom-e[f.line].height));let ke=l.x(H);if(v(ke,X,D),H=c0(O,H+p+h,w?H+z:this.right,n.rtl),y(l.x(H),X,D),w)f.x+=z+u;else if(typeof D.text!="string"){let st=c.lineHeight;f.y+=zD(D,st)+u}else f.y+=b}),gp(this.ctx,n.textDirection)}drawTitle(){let n=this.options,e=n.title,i=Te(e.font),r=Be(e.padding);if(!e.display)return;let s=Pi(n.rtl,this.left,this.width),o=this.ctx,a=e.position,l=i.size/2,c=r.top+l,u,d=this.left,h=this.width;if(this.isHorizontal())h=Math.max(...this.lineWidths),u=this.top+c,d=He(n.align,d,this.right-h);else{let p=this.columnSizes.reduce((g,m)=>Math.max(g,m.height),0);u=c+He(n.align,this.top,this.bottom-p-n.labels.padding-this._computeTitleHeight())}let f=He(a,d,d+h);o.textAlign=s.textAlign(dc(a)),o.textBaseline="middle",o.strokeStyle=e.color,o.fillStyle=e.color,o.font=i.string,Kn(o,e.text,f,u,i)}_computeTitleHeight(){let n=this.options.title,e=Te(n.font),i=Be(n.padding);return n.display?e.lineHeight+i.height:0}_getLegendItemAt(n,e){let i,r,s;if(nn(n,this.left,this.right)&&nn(e,this.top,this.bottom)){for(s=this.legendHitBoxes,i=0;is.length>o.length?s:o)),n+e.size/2+i.measureText(r).width}function KP(t,n,e){let i=t;return typeof n.text!="string"&&(i=zD(n,e)),i}function zD(t,n){let e=t.text?t.text.length:0;return n*e}function XP(t,n){return!!((t==="mousemove"||t==="mouseout")&&(n.onHover||n.onLeave)||n.onClick&&(t==="click"||t==="mouseup"))}var JP={id:"legend",_element:Rc,start(t,n,e){let i=t.legend=new Rc({ctx:t.ctx,options:e,chart:t});Ge.configure(t,i,e),Ge.addBox(t,i)},stop(t){Ge.removeBox(t,t.legend),delete t.legend},beforeUpdate(t,n,e){let i=t.legend;Ge.configure(t,i,e),i.options=e},afterUpdate(t){let n=t.legend;n.buildLabels(),n.adjustHitBoxes()},afterEvent(t,n){n.replay||t.legend.handleEvent(n.event)},defaults:{display:!0,position:"top",align:"center",fullSize:!0,reverse:!1,weight:1e3,onClick(t,n,e){let i=n.datasetIndex,r=e.chart;r.isDatasetVisible(i)?(r.hide(i),n.hidden=!0):(r.show(i),n.hidden=!1)},onHover:null,onLeave:null,labels:{color:t=>t.chart.options.color,boxWidth:40,padding:10,generateLabels(t){let n=t.data.datasets,{labels:{usePointStyle:e,pointStyle:i,textAlign:r,color:s,useBorderRadius:o,borderRadius:a}}=t.legend.options;return t._getSortedDatasetMetas().map(l=>{let c=l.controller.getStyle(e?0:void 0),u=Be(c.borderWidth);return{text:n[l.index].label,fillStyle:c.backgroundColor,fontColor:s,hidden:!l.visible,lineCap:c.borderCapStyle,lineDash:c.borderDash,lineDashOffset:c.borderDashOffset,lineJoin:c.borderJoinStyle,lineWidth:(u.width+u.height)/4,strokeStyle:c.borderColor,pointStyle:i||c.pointStyle,rotation:c.rotation,textAlign:r||c.textAlign,borderRadius:o&&(a||c.borderRadius),datasetIndex:l.index}},this)}},title:{color:t=>t.chart.options.color,display:!1,position:"center",text:""}},descriptors:{_scriptable:t=>!t.startsWith("on"),labels:{_scriptable:t=>!["generateLabels","filter","sort"].includes(t)}}},yo=class extends Vt{constructor(n){super(),this.chart=n.chart,this.options=n.options,this.ctx=n.ctx,this._padding=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(n,e){let i=this.options;if(this.left=0,this.top=0,!i.display){this.width=this.height=this.right=this.bottom=0;return}this.width=this.right=n,this.height=this.bottom=e;let r=fe(i.text)?i.text.length:1;this._padding=Be(i.padding);let s=r*Te(i.font).lineHeight+this._padding.height;this.isHorizontal()?this.height=s:this.width=s}isHorizontal(){let n=this.options.position;return n==="top"||n==="bottom"}_drawArgs(n){let{top:e,left:i,bottom:r,right:s,options:o}=this,a=o.align,l=0,c,u,d;return this.isHorizontal()?(u=He(a,i,s),d=e+n,c=s-i):(o.position==="left"?(u=i+n,d=He(a,r,e),l=pe*-.5):(u=s-n,d=He(a,e,r),l=pe*.5),c=r-e),{titleX:u,titleY:d,maxWidth:c,rotation:l}}draw(){let n=this.ctx,e=this.options;if(!e.display)return;let i=Te(e.font),s=i.lineHeight/2+this._padding.top,{titleX:o,titleY:a,maxWidth:l,rotation:c}=this._drawArgs(s);Kn(n,e.text,0,0,i,{color:e.color,maxWidth:l,rotation:c,textAlign:dc(e.align),textBaseline:"middle",translation:[o,a]})}};function e1(t,n){let e=new yo({ctx:t.ctx,options:n,chart:t});Ge.configure(t,e,n),Ge.addBox(t,e),t.titleBlock=e}var t1={id:"title",_element:yo,start(t,n,e){e1(t,e)},stop(t){let n=t.titleBlock;Ge.removeBox(t,n),delete t.titleBlock},beforeUpdate(t,n,e){let i=t.titleBlock;Ge.configure(t,i,e),i.options=e},defaults:{align:"center",display:!1,font:{weight:"bold"},fullSize:!0,padding:10,position:"top",text:"",weight:2e3},defaultRoutes:{color:"color"},descriptors:{_scriptable:!0,_indexable:!1}},Cc=new WeakMap,n1={id:"subtitle",start(t,n,e){let i=new yo({ctx:t.ctx,options:e,chart:t});Ge.configure(t,i,e),Ge.addBox(t,i),Cc.set(t,i)},stop(t){Ge.removeBox(t,Cc.get(t)),Cc.delete(t)},beforeUpdate(t,n,e){let i=Cc.get(t);Ge.configure(t,i,e),i.options=e},defaults:{align:"center",display:!1,font:{weight:"normal"},fullSize:!0,padding:0,position:"top",text:"",weight:1500},defaultRoutes:{color:"color"},descriptors:{_scriptable:!0,_indexable:!1}},mo={average(t){if(!t.length)return!1;let n,e,i=new Set,r=0,s=0;for(n=0,e=t.length;na+l)/i.size,y:r/s}},nearest(t,n){if(!t.length)return!1;let e=n.x,i=n.y,r=Number.POSITIVE_INFINITY,s,o,a;for(s=0,o=t.length;s-1?t.split(` +`):t}function i1(t,n){let{element:e,datasetIndex:i,index:r}=n,s=t.getDatasetMeta(i).controller,{label:o,value:a}=s.getLabelAndValue(r);return{chart:t,label:o,parsed:s.getParsed(r),raw:t.data.datasets[i].data[r],formattedValue:a,dataset:s.getDataset(),dataIndex:r,datasetIndex:i,element:e}}function uD(t,n){let e=t.chart.ctx,{body:i,footer:r,title:s}=t,{boxWidth:o,boxHeight:a}=n,l=Te(n.bodyFont),c=Te(n.titleFont),u=Te(n.footerFont),d=s.length,h=r.length,f=i.length,p=Be(n.padding),g=p.height,m=0,v=i.reduce((C,b)=>C+b.before.length+b.lines.length+b.after.length,0);if(v+=t.beforeBody.length+t.afterBody.length,d&&(g+=d*c.lineHeight+(d-1)*n.titleSpacing+n.titleMarginBottom),v){let C=n.displayColors?Math.max(a,l.lineHeight):l.lineHeight;g+=f*C+(v-f)*l.lineHeight+(v-1)*n.bodySpacing}h&&(g+=n.footerMarginTop+h*u.lineHeight+(h-1)*n.footerSpacing);let y=0,w=function(C){m=Math.max(m,e.measureText(C).width+y)};return e.save(),e.font=c.string,oe(t.title,w),e.font=l.string,oe(t.beforeBody.concat(t.afterBody),w),y=n.displayColors?o+2+n.boxPadding:0,oe(i,C=>{oe(C.before,w),oe(C.lines,w),oe(C.after,w)}),y=0,e.font=u.string,oe(t.footer,w),e.restore(),m+=p.width,{width:m,height:g}}function r1(t,n){let{y:e,height:i}=n;return et.height-i/2?"bottom":"center"}function s1(t,n,e,i){let{x:r,width:s}=i,o=e.caretSize+e.caretPadding;if(t==="left"&&r+s+o>n.width||t==="right"&&r-s-o<0)return!0}function o1(t,n,e,i){let{x:r,width:s}=e,{width:o,chartArea:{left:a,right:l}}=t,c="center";return i==="center"?c=r<=(a+l)/2?"left":"right":r<=s/2?c="left":r>=o-s/2&&(c="right"),s1(c,t,n,e)&&(c="center"),c}function dD(t,n,e){let i=e.yAlign||n.yAlign||r1(t,e);return{xAlign:e.xAlign||n.xAlign||o1(t,n,e,i),yAlign:i}}function a1(t,n){let{x:e,width:i}=t;return n==="right"?e-=i:n==="center"&&(e-=i/2),e}function l1(t,n,e){let{y:i,height:r}=t;return n==="top"?i+=e:n==="bottom"?i-=r+e:i-=r/2,i}function hD(t,n,e,i){let{caretSize:r,caretPadding:s,cornerRadius:o}=t,{xAlign:a,yAlign:l}=e,c=r+s,{topLeft:u,topRight:d,bottomLeft:h,bottomRight:f}=Xn(o),p=a1(n,a),g=l1(n,l,c);return l==="center"?a==="left"?p+=c:a==="right"&&(p-=c):a==="left"?p-=Math.max(u,h)+r:a==="right"&&(p+=Math.max(d,f)+r),{x:Ne(p,0,i.width-n.width),y:Ne(g,0,i.height-n.height)}}function xc(t,n,e){let i=Be(e.padding);return n==="center"?t.x+t.width/2:n==="right"?t.x+t.width-i.right:t.x+i.left}function fD(t){return rn([],Sn(t))}function c1(t,n,e){return En(t,{tooltip:n,tooltipItems:e,type:"tooltip"})}function pD(t,n){let e=n&&n.dataset&&n.dataset.tooltip&&n.dataset.tooltip.callbacks;return e?t.override(e):t}var WD={beforeTitle:tn,title(t){if(t.length>0){let n=t[0],e=n.chart.data.labels,i=e?e.length:0;if(this&&this.options&&this.options.mode==="dataset")return n.dataset.label||"";if(n.label)return n.label;if(i>0&&n.dataIndex"u"?WD[n].call(e,i):r}var gD=(()=>{class t extends Vt{static positioners=mo;constructor(e){super(),this.opacity=0,this._active=[],this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.chart=e.chart,this.options=e.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0}initialize(e){this.options=e,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){let e=this._cachedAnimations;if(e)return e;let i=this.chart,r=this.options.setContext(this.getContext()),s=r.enabled&&i.options.animation&&r.animations,o=new Ic(this.chart,s);return s._cacheable&&(this._cachedAnimations=Object.freeze(o)),o}getContext(){return this.$context||(this.$context=c1(this.chart.getContext(),this,this._tooltipItems))}getTitle(e,i){let{callbacks:r}=i,s=it(r,"beforeTitle",this,e),o=it(r,"title",this,e),a=it(r,"afterTitle",this,e),l=[];return l=rn(l,Sn(s)),l=rn(l,Sn(o)),l=rn(l,Sn(a)),l}getBeforeBody(e,i){return fD(it(i.callbacks,"beforeBody",this,e))}getBody(e,i){let{callbacks:r}=i,s=[];return oe(e,o=>{let a={before:[],lines:[],after:[]},l=pD(r,o);rn(a.before,Sn(it(l,"beforeLabel",this,o))),rn(a.lines,it(l,"label",this,o)),rn(a.after,Sn(it(l,"afterLabel",this,o))),s.push(a)}),s}getAfterBody(e,i){return fD(it(i.callbacks,"afterBody",this,e))}getFooter(e,i){let{callbacks:r}=i,s=it(r,"beforeFooter",this,e),o=it(r,"footer",this,e),a=it(r,"afterFooter",this,e),l=[];return l=rn(l,Sn(s)),l=rn(l,Sn(o)),l=rn(l,Sn(a)),l}_createItems(e){let i=this._active,r=this.chart.data,s=[],o=[],a=[],l=[],c,u;for(c=0,u=i.length;ce.filter(d,h,f,r))),e.itemSort&&(l=l.sort((d,h)=>e.itemSort(d,h,r))),oe(l,d=>{let h=pD(e.callbacks,d);s.push(it(h,"labelColor",this,d)),o.push(it(h,"labelPointStyle",this,d)),a.push(it(h,"labelTextColor",this,d))}),this.labelColors=s,this.labelPointStyles=o,this.labelTextColors=a,this.dataPoints=l,l}update(e,i){let r=this.options.setContext(this.getContext()),s=this._active,o,a=[];if(!s.length)this.opacity!==0&&(o={opacity:0});else{let l=mo[r.position].call(this,s,this._eventPosition);a=this._createItems(r),this.title=this.getTitle(a,r),this.beforeBody=this.getBeforeBody(a,r),this.body=this.getBody(a,r),this.afterBody=this.getAfterBody(a,r),this.footer=this.getFooter(a,r);let c=this._size=uD(this,r),u=Object.assign({},l,c),d=dD(this.chart,r,u),h=hD(r,u,d,this.chart);this.xAlign=d.xAlign,this.yAlign=d.yAlign,o={opacity:1,x:h.x,y:h.y,width:c.width,height:c.height,caretX:l.x,caretY:l.y}}this._tooltipItems=a,this.$context=void 0,o&&this._resolveAnimations().update(this,o),e&&r.external&&r.external.call(this,{chart:this.chart,tooltip:this,replay:i})}drawCaret(e,i,r,s){let o=this.getCaretPosition(e,r,s);i.lineTo(o.x1,o.y1),i.lineTo(o.x2,o.y2),i.lineTo(o.x3,o.y3)}getCaretPosition(e,i,r){let{xAlign:s,yAlign:o}=this,{caretSize:a,cornerRadius:l}=r,{topLeft:c,topRight:u,bottomLeft:d,bottomRight:h}=Xn(l),{x:f,y:p}=e,{width:g,height:m}=i,v,y,w,C,b,D;return o==="center"?(b=p+m/2,s==="left"?(v=f,y=v-a,C=b+a,D=b-a):(v=f+g,y=v+a,C=b-a,D=b+a),w=v):(s==="left"?y=f+Math.max(c,d)+a:s==="right"?y=f+g-Math.max(u,h)-a:y=this.caretX,o==="top"?(C=p,b=C-a,v=y-a,w=y+a):(C=p+m,b=C+a,v=y+a,w=y-a),D=C),{x1:v,x2:y,x3:w,y1:C,y2:b,y3:D}}drawTitle(e,i,r){let s=this.title,o=s.length,a,l,c;if(o){let u=Pi(r.rtl,this.x,this.width);for(e.x=xc(this,r.titleAlign,r),i.textAlign=u.textAlign(r.titleAlign),i.textBaseline="middle",a=Te(r.titleFont),l=r.titleSpacing,i.fillStyle=r.titleColor,i.font=a.string,c=0;cw!==0)?(e.beginPath(),e.fillStyle=o.multiKeyBackground,Zr(e,{x:m,y:g,w:u,h:c,radius:y}),e.fill(),e.stroke(),e.fillStyle=a.backgroundColor,e.beginPath(),Zr(e,{x:v,y:g+1,w:u-2,h:c-2,radius:y}),e.fill()):(e.fillStyle=o.multiKeyBackground,e.fillRect(m,g,u,c),e.strokeRect(m,g,u,c),e.fillStyle=a.backgroundColor,e.fillRect(v,g+1,u-2,c-2))}e.fillStyle=this.labelTextColors[r]}drawBody(e,i,r){let{body:s}=this,{bodySpacing:o,bodyAlign:a,displayColors:l,boxHeight:c,boxWidth:u,boxPadding:d}=r,h=Te(r.bodyFont),f=h.lineHeight,p=0,g=Pi(r.rtl,this.x,this.width),m=function(O){i.fillText(O,g.x(e.x+p),e.y+f/2),e.y+=f+o},v=g.textAlign(a),y,w,C,b,D,M,x;for(i.textAlign=a,i.textBaseline="middle",i.font=h.string,e.x=xc(this,v,r),i.fillStyle=r.bodyColor,oe(this.beforeBody,m),p=l&&v!=="right"?a==="center"?u/2+d:u+2+d:0,b=0,M=s.length;b0&&i.stroke()}_updateAnimationTarget(e){let i=this.chart,r=this.$animations,s=r&&r.x,o=r&&r.y;if(s||o){let a=mo[e.position].call(this,this._active,this._eventPosition);if(!a)return;let l=this._size=uD(this,e),c=Object.assign({},a,this._size),u=dD(i,e,c),d=hD(e,c,u,i);(s._to!==d.x||o._to!==d.y)&&(this.xAlign=u.xAlign,this.yAlign=u.yAlign,this.width=l.width,this.height=l.height,this.caretX=a.x,this.caretY=a.y,this._resolveAnimations().update(this,d))}}_willRender(){return!!this.opacity}draw(e){let i=this.options.setContext(this.getContext()),r=this.opacity;if(!r)return;this._updateAnimationTarget(i);let s={width:this.width,height:this.height},o={x:this.x,y:this.y};r=Math.abs(r)<.001?0:r;let a=Be(i.padding),l=this.title.length||this.beforeBody.length||this.body.length||this.afterBody.length||this.footer.length;i.enabled&&l&&(e.save(),e.globalAlpha=r,this.drawBackground(o,e,s,i),pp(e,i.textDirection),o.y+=a.top,this.drawTitle(o,e,i),this.drawBody(o,e,i),this.drawFooter(o,e,i),gp(e,i.textDirection),e.restore())}getActiveElements(){return this._active||[]}setActiveElements(e,i){let r=this._active,s=e.map(({datasetIndex:l,index:c})=>{let u=this.chart.getDatasetMeta(l);if(!u)throw new Error("Cannot find a dataset at index "+l);return{datasetIndex:l,element:u.data[c],index:c}}),o=!so(r,s),a=this._positionChanged(s,i);(o||a)&&(this._active=s,this._eventPosition=i,this._ignoreReplayEvents=!0,this.update(!0))}handleEvent(e,i,r=!0){if(i&&this._ignoreReplayEvents)return!1;this._ignoreReplayEvents=!1;let s=this.options,o=this._active||[],a=this._getActiveElements(e,o,i,r),l=this._positionChanged(a,e),c=i||!so(a,o)||l;return c&&(this._active=a,(s.enabled||s.external)&&(this._eventPosition={x:e.x,y:e.y},this.update(!0,i))),c}_getActiveElements(e,i,r,s){let o=this.options;if(e.type==="mouseout")return[];if(!s)return i.filter(l=>this.chart.data.datasets[l.datasetIndex]&&this.chart.getDatasetMeta(l.datasetIndex).controller.getParsed(l.index)!==void 0);let a=this.chart.getElementsAtEventForMode(e,o.mode,o,r);return o.reverse&&a.reverse(),a}_positionChanged(e,i){let{caretX:r,caretY:s,options:o}=this,a=mo[o.position].call(this,e,i);return a!==!1&&(r!==a.x||s!==a.y)}}return t})(),u1={id:"tooltip",_element:gD,positioners:mo,afterInit(t,n,e){e&&(t.tooltip=new gD({chart:t,options:e}))},beforeUpdate(t,n,e){t.tooltip&&t.tooltip.initialize(e)},reset(t,n,e){t.tooltip&&t.tooltip.initialize(e)},afterDraw(t){let n=t.tooltip;if(n&&n._willRender()){let e={tooltip:n};if(t.notifyPlugins("beforeTooltipDraw",ae(S({},e),{cancelable:!0}))===!1)return;n.draw(t.ctx),t.notifyPlugins("afterTooltipDraw",e)}},afterEvent(t,n){if(t.tooltip){let e=n.replay;t.tooltip.handleEvent(n.event,e,n.inChartArea)&&(n.changed=!0)}},defaults:{enabled:!0,external:null,position:"average",backgroundColor:"rgba(0,0,0,0.8)",titleColor:"#fff",titleFont:{weight:"bold"},titleSpacing:2,titleMarginBottom:6,titleAlign:"left",bodyColor:"#fff",bodySpacing:2,bodyFont:{},bodyAlign:"left",footerColor:"#fff",footerSpacing:2,footerMarginTop:6,footerFont:{weight:"bold"},footerAlign:"left",padding:6,caretPadding:2,caretSize:5,cornerRadius:6,boxHeight:(t,n)=>n.bodyFont.size,boxWidth:(t,n)=>n.bodyFont.size,multiKeyBackground:"#fff",displayColors:!0,boxPadding:0,borderColor:"rgba(0,0,0,0)",borderWidth:0,animation:{duration:400,easing:"easeOutQuart"},animations:{numbers:{type:"number",properties:["x","y","width","height","caretX","caretY"]},opacity:{easing:"linear",duration:200}},callbacks:WD},defaultRoutes:{bodyFont:"font",footerFont:"font",titleFont:"font"},descriptors:{_scriptable:t=>t!=="filter"&&t!=="itemSort"&&t!=="external",_indexable:!1,callbacks:{_scriptable:!1,_indexable:!1},animation:{_fallback:!1},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]},d1=Object.freeze({__proto__:null,Colors:CP,Decimation:SP,Filler:qP,Legend:JP,SubTitle:n1,Title:t1,Tooltip:u1}),h1=(t,n,e,i)=>(typeof n=="string"?(e=t.push(n)-1,i.unshift({index:e,label:n})):isNaN(n)&&(e=null),e);function f1(t,n,e,i){let r=t.indexOf(n);if(r===-1)return h1(t,n,e,i);let s=t.lastIndexOf(n);return r!==s?e:r}var p1=(t,n)=>t===null?null:Ne(Math.round(t),0,n);function mD(t){let n=this.getLabels();return t>=0&&t{class t extends Vi{static id="category";static defaults={ticks:{callback:mD}};constructor(e){super(e),this._startValue=void 0,this._valueRange=0,this._addedLabels=[]}init(e){let i=this._addedLabels;if(i.length){let r=this.getLabels();for(let{index:s,label:o}of i)r[s]===o&&r.splice(s,1);this._addedLabels=[]}super.init(e)}parse(e,i){if(te(e))return null;let r=this.getLabels();return i=isFinite(i)&&r[i]===e?i:f1(r,e,V(i,e),this._addedLabels),p1(i,r.length-1)}determineDataLimits(){let{minDefined:e,maxDefined:i}=this.getUserBounds(),{min:r,max:s}=this.getMinMax(!0);this.options.bounds==="ticks"&&(e||(r=0),i||(s=this.getLabels().length-1)),this.min=r,this.max=s}buildTicks(){let e=this.min,i=this.max,r=this.options.offset,s=[],o=this.getLabels();o=e===0&&i===o.length-1?o:o.slice(e,i+1),this._valueRange=Math.max(o.length-(r?0:1),1),this._startValue=this.min-(r?.5:0);for(let a=e;a<=i;a++)s.push({value:a});return s}getLabelForValue(e){return mD.call(this,e)}configure(){super.configure(),this.isHorizontal()||(this._reversePixels=!this._reversePixels)}getPixelForValue(e){return typeof e!="number"&&(e=this.parse(e)),e===null?NaN:this.getPixelForDecimal((e-this._startValue)/this._valueRange)}getPixelForTick(e){let i=this.ticks;return e<0||e>i.length-1?null:this.getPixelForValue(i[e].value)}getValueForPixel(e){return Math.round(this._startValue+this.getDecimalForPixel(e)*this._valueRange)}getBasePixel(){return this.bottom}}return t})();function m1(t,n){let e=[],{bounds:r,step:s,min:o,max:a,precision:l,count:c,maxTicks:u,maxDigits:d,includeBounds:h}=t,f=s||1,p=u-1,{min:g,max:m}=n,v=!te(o),y=!te(a),w=!te(c),C=(m-g)/(d+1),b=qf((m-g)/p/f)*f,D,M,x,O;if(b<1e-14&&!v&&!y)return[{value:g},{value:m}];O=Math.ceil(m/b)-Math.floor(g/b),O>p&&(b=qf(O*b/p/f)*f),te(l)||(D=Math.pow(10,l),b=Math.ceil(b*D)/D),r==="ticks"?(M=Math.floor(g/b)*b,x=Math.ceil(m/b)*b):(M=g,x=m),v&&y&&s&&n0((a-o)/s,b/1e3)?(O=Math.round(Math.min((a-o)/b,u)),b=(a-o)/O,M=o,x=a):w?(M=v?o:M,x=y?a:x,O=c-1,b=(x-M)/O):(O=(x-M)/b,Gr(O,Math.round(O),b/1e3)?O=Math.round(O):O=Math.ceil(O));let z=Math.max(Zf(b),Zf(M));D=Math.pow(10,te(l)?z:l),M=Math.round(M*D)/D,x=Math.round(x*D)/D;let H=0;for(v&&(h&&M!==o?(e.push({value:o}),Ma)break;e.push({value:X})}return y&&h&&x!==a?e.length&&Gr(e[e.length-1].value,a,vD(a,C,t))?e[e.length-1].value=a:e.push({value:a}):(!y||x===a)&&e.push({value:x}),e}function vD(t,n,{horizontal:e,minRotation:i}){let r=Mt(i),s=(e?Math.sin(r):Math.cos(r))||.001,o=.75*n*(""+t).length;return Math.min(n/s,o)}var Jr=class extends Vi{constructor(n){super(n),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(n,e){return te(n)||(typeof n=="number"||n instanceof Number)&&!isFinite(+n)?null:+n}handleTickRangeOptions(){let{beginAtZero:n}=this.options,{minDefined:e,maxDefined:i}=this.getUserBounds(),{min:r,max:s}=this,o=l=>r=e?r:l,a=l=>s=i?s:l;if(n){let l=Ft(r),c=Ft(s);l<0&&c<0?a(0):l>0&&c>0&&o(0)}if(r===s){let l=s===0?1:Math.abs(s*.05);a(s+l),n||o(r-l)}this.min=r,this.max=s}getTickLimit(){let n=this.options.ticks,{maxTicksLimit:e,stepSize:i}=n,r;return i?(r=Math.ceil(this.max/i)-Math.floor(this.min/i)+1,r>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${i} would result generating up to ${r} ticks. Limiting to 1000.`),r=1e3)):(r=this.computeTickLimit(),e=e||11),e&&(r=Math.min(e,r)),r}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){let n=this.options,e=n.ticks,i=this.getTickLimit();i=Math.max(2,i);let r={maxTicks:i,bounds:n.bounds,min:n.min,max:n.max,precision:e.precision,step:e.stepSize,count:e.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:e.minRotation||0,includeBounds:e.includeBounds!==!1},s=this._range||this,o=m1(r,s);return n.bounds==="ticks"&&Yf(o,this,"value"),n.reverse?(o.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),o}configure(){let n=this.ticks,e=this.min,i=this.max;if(super.configure(),this.options.offset&&n.length){let r=(i-e)/Math.max(n.length-1,1)/2;e-=r,i+=r}this._startValue=e,this._endValue=i,this._valueRange=i-e}getLabelForValue(n){return Yr(n,this.chart.options.locale,this.options.ticks.format)}},$p=class extends Jr{static id="linear";static defaults={ticks:{callback:oo.formatters.numeric}};determineDataLimits(){let{min:n,max:e}=this.getMinMax(!0);this.min=be(n)?n:0,this.max=be(e)?e:1,this.handleTickRangeOptions()}computeTickLimit(){let n=this.isHorizontal(),e=n?this.width:this.height,i=Mt(this.options.ticks.minRotation),r=(n?Math.sin(i):Math.cos(i))||.001,s=this._resolveTickFontOptions(0);return Math.ceil(e/Math.min(40,s.lineHeight/r))}getPixelForValue(n){return n===null?NaN:this.getPixelForDecimal((n-this._startValue)/this._valueRange)}getValueForPixel(n){return this._startValue+this.getDecimalForPixel(n)*this._valueRange}},bo=t=>Math.floor(Cn(t)),Fi=(t,n)=>Math.pow(10,bo(t)+n);function yD(t){return t/Math.pow(10,bo(t))===1}function bD(t,n,e){let i=Math.pow(10,e),r=Math.floor(t/i);return Math.ceil(n/i)-r}function v1(t,n){let e=n-t,i=bo(e);for(;bD(t,n,i)>10;)i++;for(;bD(t,n,i)<10;)i--;return Math.min(i,bo(t))}function y1(t,{min:n,max:e}){n=nt(t.min,n);let i=[],r=bo(n),s=v1(n,e),o=s<0?Math.pow(10,Math.abs(s)):1,a=Math.pow(10,s),l=r>s?Math.pow(10,r):0,c=Math.round((n-l)*o)/o,u=Math.floor((n-l)/a/10)*a*10,d=Math.floor((c-u)/Math.pow(10,s)),h=nt(t.min,Math.round((l+u+d*Math.pow(10,s))*o)/o);for(;h=10?d=d<15?15:20:d++,d>=20&&(s++,d=2,o=s>=0?1:o),h=Math.round((l+u+d*Math.pow(10,s))*o)/o;let f=nt(t.max,h);return i.push({value:f,major:yD(f),significand:d}),i}var zp=class extends Vi{static id="logarithmic";static defaults={ticks:{callback:oo.formatters.logarithmic,major:{enabled:!0}}};constructor(n){super(n),this.start=void 0,this.end=void 0,this._startValue=void 0,this._valueRange=0}parse(n,e){let i=Jr.prototype.parse.apply(this,[n,e]);if(i===0){this._zero=!0;return}return be(i)&&i>0?i:null}determineDataLimits(){let{min:n,max:e}=this.getMinMax(!0);this.min=be(n)?Math.max(0,n):null,this.max=be(e)?Math.max(0,e):null,this.options.beginAtZero&&(this._zero=!0),this._zero&&this.min!==this._suggestedMin&&!be(this._userMin)&&(this.min=n===Fi(this.min,0)?Fi(this.min,-1):Fi(this.min,0)),this.handleTickRangeOptions()}handleTickRangeOptions(){let{minDefined:n,maxDefined:e}=this.getUserBounds(),i=this.min,r=this.max,s=a=>i=n?i:a,o=a=>r=e?r:a;i===r&&(i<=0?(s(1),o(10)):(s(Fi(i,-1)),o(Fi(r,1)))),i<=0&&s(Fi(r,-1)),r<=0&&o(Fi(i,1)),this.min=i,this.max=r}buildTicks(){let n=this.options,e={min:this._userMin,max:this._userMax},i=y1(e,this);return n.bounds==="ticks"&&Yf(i,this,"value"),n.reverse?(i.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),i}getLabelForValue(n){return n===void 0?"0":Yr(n,this.chart.options.locale,this.options.ticks.format)}configure(){let n=this.min;super.configure(),this._startValue=Cn(n),this._valueRange=Cn(this.max)-Cn(n)}getPixelForValue(n){return(n===void 0||n===0)&&(n=this.min),n===null||isNaN(n)?NaN:this.getPixelForDecimal(n===this.min?0:(Cn(n)-this._startValue)/this._valueRange)}getValueForPixel(n){let e=this.getDecimalForPixel(n);return Math.pow(10,this._startValue+e*this._valueRange)}};function Wp(t){let n=t.ticks;if(n.display&&t.display){let e=Be(n.backdropPadding);return V(n.font&&n.font.size,me.font.size)+e.height}return 0}function b1(t,n,e){return e=fe(e)?e:[e],{w:d0(t,n.string,e),h:e.length*n.lineHeight}}function wD(t,n,e,i,r){return t===i||t===r?{start:n-e/2,end:n+e/2}:tr?{start:n-e,end:n}:{start:n,end:n+e}}function w1(t){let n={l:t.left+t._padding.left,r:t.right-t._padding.right,t:t.top+t._padding.top,b:t.bottom-t._padding.bottom},e=Object.assign({},n),i=[],r=[],s=t._pointLabels.length,o=t.options.pointLabels,a=o.centerPointLabels?pe/s:0;for(let l=0;ln.r&&(a=(i.end-n.r)/s,t.r=Math.max(t.r,n.r+a)),r.startn.b&&(l=(r.end-n.b)/o,t.b=Math.max(t.b,n.b+l))}function _1(t,n,e){let i=t.drawingArea,{extra:r,additionalAngle:s,padding:o,size:a}=e,l=t.getPointPosition(n,i+r+o,s),c=Math.round(cc(tt(l.angle+De))),u=S1(l.y,a.h,c),d=E1(c),h=M1(l.x,a.w,d);return{visible:!0,x:l.x,y:u,textAlign:d,left:h,top:u,right:h+a.w,bottom:u+a.h}}function C1(t,n){if(!n)return!0;let{left:e,top:i,right:r,bottom:s}=t;return!(en({x:e,y:i},n)||en({x:e,y:s},n)||en({x:r,y:i},n)||en({x:r,y:s},n))}function x1(t,n,e){let i=[],r=t._pointLabels.length,s=t.options,{centerPointLabels:o,display:a}=s.pointLabels,l={extra:Wp(s)/2,additionalAngle:o?pe/r:0},c;for(let u=0;u270||e<90)&&(t-=n),t}function I1(t,n,e){let{left:i,top:r,right:s,bottom:o}=e,{backdropColor:a}=n;if(!te(a)){let l=Xn(n.borderRadius),c=Be(n.backdropPadding);t.fillStyle=a;let u=i-c.left,d=r-c.top,h=s-i+c.width,f=o-r+c.height;Object.values(l).some(p=>p!==0)?(t.beginPath(),Zr(t,{x:u,y:d,w:h,h:f,radius:l}),t.fill()):t.fillRect(u,d,h,f)}}function O1(t,n){let{ctx:e,options:{pointLabels:i}}=t;for(let r=n-1;r>=0;r--){let s=t._pointLabelItems[r];if(!s.visible)continue;let o=i.setContext(t.getPointLabelContext(r));I1(e,o,s);let a=Te(o.font),{x:l,y:c,textAlign:u}=s;Kn(e,t._pointLabels[r],l,c+a.lineHeight/2,a,{color:o.color,textAlign:u,textBaseline:"middle"})}}function GD(t,n,e,i){let{ctx:r}=t;if(e)r.arc(t.xCenter,t.yCenter,n,0,ge);else{let s=t.getPointPosition(0,n);r.moveTo(s.x,s.y);for(let o=1;o{let r=he(this.options.pointLabels.callback,[e,i],this);return r||r===0?r:""}).filter((e,i)=>this.chart.getDataVisibility(i))}fit(){let n=this.options;n.display&&n.pointLabels.display?w1(this):this.setCenterPoint(0,0,0,0)}setCenterPoint(n,e,i,r){this.xCenter+=Math.floor((n-e)/2),this.yCenter+=Math.floor((i-r)/2),this.drawingArea-=Math.min(this.drawingArea/2,Math.max(n,e,i,r))}getIndexAngle(n){let e=ge/(this._pointLabels.length||1),i=this.options.startAngle||0;return tt(n*e+Mt(i))}getDistanceFromCenterForValue(n){if(te(n))return NaN;let e=this.drawingArea/(this.max-this.min);return this.options.reverse?(this.max-n)*e:(n-this.min)*e}getValueForDistanceFromCenter(n){if(te(n))return NaN;let e=n/(this.drawingArea/(this.max-this.min));return this.options.reverse?this.max-e:this.min+e}getPointLabelContext(n){let e=this._pointLabels||[];if(n>=0&&n{if(d!==0||d===0&&this.min<0){l=this.getDistanceFromCenterForValue(u.value);let h=this.getContext(d),f=r.setContext(h),p=s.setContext(h);T1(this,f,l,o,p)}}),i.display){for(n.save(),a=o-1;a>=0;a--){let u=i.setContext(this.getPointLabelContext(a)),{color:d,lineWidth:h}=u;!h||!d||(n.lineWidth=h,n.strokeStyle=d,n.setLineDash(u.borderDash),n.lineDashOffset=u.borderDashOffset,l=this.getDistanceFromCenterForValue(e.reverse?this.min:this.max),c=this.getPointPosition(a,l),n.beginPath(),n.moveTo(this.xCenter,this.yCenter),n.lineTo(c.x,c.y),n.stroke())}n.restore()}}drawBorder(){}drawLabels(){let n=this.ctx,e=this.options,i=e.ticks;if(!i.display)return;let r=this.getIndexAngle(0),s,o;n.save(),n.translate(this.xCenter,this.yCenter),n.rotate(r),n.textAlign="center",n.textBaseline="middle",this.ticks.forEach((a,l)=>{if(l===0&&this.min>=0&&!e.reverse)return;let c=i.setContext(this.getContext(l)),u=Te(c.font);if(s=this.getDistanceFromCenterForValue(this.ticks[l].value),c.showLabelBackdrop){n.font=u.string,o=n.measureText(a.label).width,n.fillStyle=c.backdropColor;let d=Be(c.backdropPadding);n.fillRect(-o/2-d.left,-s-u.size/2-d.top,o+d.width,u.size+d.height)}Kn(n,a.label,0,-s,u,{color:c.color,strokeColor:c.textStrokeColor,strokeWidth:c.textStrokeWidth})}),n.restore()}drawTitle(){}},Lc={millisecond:{common:!0,size:1,steps:1e3},second:{common:!0,size:1e3,steps:60},minute:{common:!0,size:6e4,steps:60},hour:{common:!0,size:36e5,steps:24},day:{common:!0,size:864e5,steps:30},week:{common:!1,size:6048e5,steps:4},month:{common:!0,size:2628e6,steps:12},quarter:{common:!1,size:7884e6,steps:4},year:{common:!0,size:3154e7}},rt=Object.keys(Lc);function DD(t,n){return t-n}function _D(t,n){if(te(n))return null;let e=t._adapter,{parser:i,round:r,isoWeekday:s}=t._parseOpts,o=n;return typeof i=="function"&&(o=i(o)),be(o)||(o=typeof i=="string"?e.parse(o,i):e.parse(o)),o===null?null:(r&&(o=r==="week"&&(ki(s)||s===!0)?e.startOf(o,"isoWeek",s):e.startOf(o,r)),+o)}function CD(t,n,e,i){let r=rt.length;for(let s=rt.indexOf(t);s=rt.indexOf(e);s--){let o=rt[s];if(Lc[o].common&&t._adapter.diff(r,i,o)>=n-1)return o}return rt[e?rt.indexOf(e):0]}function R1(t){for(let n=rt.indexOf(t)+1,e=rt.length;n=n?e[i]:e[r];t[s]=!0}}function k1(t,n,e,i){let r=t._adapter,s=+r.startOf(n[0].value,i),o=n[n.length-1].value,a,l;for(a=s;a<=o;a=+r.add(a,1,i))l=e[a],l>=0&&(n[l].major=!0);return n}function ED(t,n,e){let i=[],r={},s=n.length,o,a;for(o=0;o{class t extends Vi{static id="time";static defaults={bounds:"data",adapters:{},time:{parser:!1,unit:!1,round:!1,isoWeekday:!1,minUnit:"millisecond",displayFormats:{}},ticks:{source:"auto",callback:!1,major:{enabled:!1}}};constructor(e){super(e),this._cache={data:[],labels:[],all:[]},this._unit="day",this._majorUnit=void 0,this._offsets={},this._normalized=!1,this._parseOpts=void 0}init(e,i={}){let r=e.time||(e.time={}),s=this._adapter=new WR._date(e.adapters.date);s.init(i),zr(r.displayFormats,s.formats()),this._parseOpts={parser:r.parser,round:r.round,isoWeekday:r.isoWeekday},super.init(e),this._normalized=i.normalized}parse(e,i){return e===void 0?null:_D(this,e)}beforeLayout(){super.beforeLayout(),this._cache={data:[],labels:[],all:[]}}determineDataLimits(){let e=this.options,i=this._adapter,r=e.time.unit||"day",{min:s,max:o,minDefined:a,maxDefined:l}=this.getUserBounds();function c(u){!a&&!isNaN(u.min)&&(s=Math.min(s,u.min)),!l&&!isNaN(u.max)&&(o=Math.max(o,u.max))}(!a||!l)&&(c(this._getLabelBounds()),(e.bounds!=="ticks"||e.ticks.source!=="labels")&&c(this.getMinMax(!1))),s=be(s)&&!isNaN(s)?s:+i.startOf(Date.now(),r),o=be(o)&&!isNaN(o)?o:+i.endOf(Date.now(),r)+1,this.min=Math.min(s,o-1),this.max=Math.max(s+1,o)}_getLabelBounds(){let e=this.getLabelTimestamps(),i=Number.POSITIVE_INFINITY,r=Number.NEGATIVE_INFINITY;return e.length&&(i=e[0],r=e[e.length-1]),{min:i,max:r}}buildTicks(){let e=this.options,i=e.time,r=e.ticks,s=r.source==="labels"?this.getLabelTimestamps():this._generate();e.bounds==="ticks"&&s.length&&(this.min=this._userMin||s[0],this.max=this._userMax||s[s.length-1]);let o=this.min,a=this.max,l=s0(s,o,a);return this._unit=i.unit||(r.autoSkip?CD(i.minUnit,this.min,this.max,this._getLabelCapacity(o)):N1(this,l.length,i.minUnit,this.min,this.max)),this._majorUnit=!r.major.enabled||this._unit==="year"?void 0:R1(this._unit),this.initOffsets(s),e.reverse&&l.reverse(),ED(this,l,this._majorUnit)}afterAutoSkip(){this.options.offsetAfterAutoskip&&this.initOffsets(this.ticks.map(e=>+e.value))}initOffsets(e=[]){let i=0,r=0,s,o;this.options.offset&&e.length&&(s=this.getDecimalForValue(e[0]),e.length===1?i=1-s:i=(this.getDecimalForValue(e[1])-s)/2,o=this.getDecimalForValue(e[e.length-1]),e.length===1?r=o:r=(o-this.getDecimalForValue(e[e.length-2]))/2);let a=e.length<3?.5:.25;i=Ne(i,0,a),r=Ne(r,0,a),this._offsets={start:i,end:r,factor:1/(i+1+r)}}_generate(){let e=this._adapter,i=this.min,r=this.max,s=this.options,o=s.time,a=o.unit||CD(o.minUnit,i,r,this._getLabelCapacity(i)),l=V(s.ticks.stepSize,1),c=a==="week"?o.isoWeekday:!1,u=ki(c)||c===!0,d={},h=i,f,p;if(u&&(h=+e.startOf(h,"isoWeek",c)),h=+e.startOf(h,u?"day":a),e.diff(r,i,a)>1e5*l)throw new Error(i+" and "+r+" are too far apart with stepSize of "+l+" "+a);let g=s.ticks.source==="data"&&this.getDataTimestamps();for(f=h,p=0;f+m)}getLabelForValue(e){let i=this._adapter,r=this.options.time;return r.tooltipFormat?i.format(e,r.tooltipFormat):i.format(e,r.displayFormats.datetime)}format(e,i){let s=this.options.time.displayFormats,o=this._unit,a=i||s[o];return this._adapter.format(e,a)}_tickFormatFunction(e,i,r,s){let o=this.options,a=o.ticks.callback;if(a)return he(a,[e,i,r],this);let l=o.time.displayFormats,c=this._unit,u=this._majorUnit,d=c&&l[c],h=u&&l[u],f=r[i],p=u&&h&&f&&f.major;return this._adapter.format(e,s||(p?h:d))}generateTickLabels(e){let i,r,s;for(i=0,r=e.length;i0?l:1}getDataTimestamps(){let e=this._cache.data||[],i,r;if(e.length)return e;let s=this.getMatchingVisibleMetas();if(this._normalized&&s.length)return this._cache.data=s[0].controller.getAllParsedValues(this);for(i=0,r=s.length;i=t[i].pos&&n<=t[r].pos&&({lo:i,hi:r}=Jt(t,"pos",n)),{pos:s,time:a}=t[i],{pos:o,time:l}=t[r]):(n>=t[i].time&&n<=t[r].time&&({lo:i,hi:r}=Jt(t,"time",n)),{time:s,pos:a}=t[i],{time:o,pos:l}=t[r]);let c=o-s;return c?a+(l-a)*(n-s)/c:a}var Yp=class extends qp{static id="timeseries";static defaults=qp.defaults;constructor(n){super(n),this._table=[],this._minPos=void 0,this._tableRange=void 0}initOffsets(){let n=this._getTimestampsForTable(),e=this._table=this.buildLookupTable(n);this._minPos=Ec(e,this.min),this._tableRange=Ec(e,this.max)-this._minPos,super.initOffsets(n)}buildLookupTable(n){let{min:e,max:i}=this,r=[],s=[],o,a,l,c,u;for(o=0,a=n.length;o=e&&c<=i&&r.push(c);if(r.length<2)return[{time:e,pos:0},{time:i,pos:1}];for(o=0,a=r.length;or-s)}_getTimestampsForTable(){let n=this._cache.all||[];if(n.length)return n;let e=this.getDataTimestamps(),i=this.getLabelTimestamps();return e.length&&i.length?n=this.normalize(e.concat(i)):n=e.length?e:i,n=this._cache.all=n,n}getDecimalForValue(n){return(Ec(this._table,n)-this._minPos)/this._tableRange}getValueForPixel(n){let e=this._offsets,i=this.getDecimalForPixel(n)/e.factor-e.end;return Ec(this._table,i*this._tableRange+this._minPos,!0)}},P1=Object.freeze({__proto__:null,CategoryScale:g1,LinearScale:$p,LogarithmicScale:zp,RadialLinearScale:Gp,TimeScale:qp,TimeSeriesScale:Yp}),qD=[zR,mP,d1,P1];kc.register(...qD);var YD=kc;var Fc=[{name:"refrigerator","daily-kWh":1.5167,imageUrl:"assets/images/house/refrigerator.png"},{name:"washer","daily-kWh":.1722,imageUrl:"assets/images/house/washer.png"},{name:"dryer","daily-kWh":2.1361,imageUrl:"assets/images/house/dryer.png"},{name:"ac","daily-kWh":7.7,imageUrl:"assets/images/house/ac.png"},{name:"oven","daily-kWh":.9359,imageUrl:"assets/images/house/oven.png"},{name:"light","daily-kWh":1.9389,imageUrl:"assets/images/house/light.png"},{name:"tv","daily-kWh":.575,imageUrl:"assets/images/house/tv.png"},{name:"ceiling-fan","daily-kWh":.0889,imageUrl:"assets/images/house/ceilingfan.png"},{name:"porch-light","daily-kWh":.6083,imageUrl:"assets/images/house/porchlight.png"}];var Vc=class t{chart;labels=Fc.map(n=>this.toTitleCase(n.name));toTitleCase(n){return n.length===2?n.toUpperCase():n.replace(/-/g," ").replace(/\b\w/g,e=>e.toUpperCase())}data=Fc.map(n=>n["daily-kWh"]);images=Fc.map(n=>{let e=new Image;return e.src=n.imageUrl,e});ngAfterViewInit(){setTimeout(()=>{this.createChart()},0)}createChart(){let n={id:"imagePlugin",afterDraw:e=>{let i=e.ctx,r=e.scales.x;this.images.forEach((s,o)=>{let a=r.getPixelForValue(o),l=e.height-40;s.src.includes("tv")?i.drawImage(s,r.getPixelForValue(o)-40,l-40,80,50):s.src.includes("ac")?i.drawImage(s,r.getPixelForValue(o)-45,l-40,90,60):s.src.includes("refrigerator")?i.drawImage(s,r.getPixelForValue(o)-30,l-40,60,80):i.drawImage(s,r.getPixelForValue(o)-30,l-40,60,60)})}};this.chart=new YD("MyChart",{type:"bar",data:{labels:this.labels,datasets:[{data:this.data,backgroundColor:["blue","lightgrey","red","purple","orange","cyan","magenta","yellow","pink"]}]},options:{responsive:!0,maintainAspectRatio:!1,layout:{padding:{bottom:80}},scales:{x:{beginAtZero:!0,title:{display:!1,color:"#c4c4c4"},ticks:{display:!1,color:"#c4c4c4"},grid:{display:!1,color:"#c4c4c4",tickColor:"#c4c4c4"},border:{display:!1}},y:{beginAtZero:!0,title:{display:!1},grid:{display:!1,color:"#c4c4c4",tickColor:"#c4c4c4"},ticks:{display:!1,color:"#c4c4c4"},border:{display:!1}}},plugins:{legend:{display:!1}}},plugins:[n]})}static \u0275fac=function(e){return new(e||t)};static \u0275cmp=Fe({type:t,selectors:[["app-appliance-chart"]],decls:2,vars:0,consts:[[1,"chart-container"],["id","MyChart"]],template:function(e,i){e&1&&(L(0,"div",0),le(1,"canvas",1),j())},styles:[".chart-container[_ngcontent-%COMP%]{width:50%;height:40vh;padding-bottom:10px;padding-right:12px;padding-top:.2vh;color:#fff;position:absolute;top:2%;right:1%;background-color:#4d4d4db3;border-radius:20px;box-shadow:5px 5px 10px 5px #00000080}canvas[_ngcontent-%COMP%]{width:100%!important;height:100%!important;color:#fff}"]})};var Kp={ac:[{msg:"ACs use a lot of energy!",file:"ac-0.m4a"},{msg:"Make sure to close all windows if the AC is on!",file:"ac-1.m4a"},{msg:"Make sure to turn off the AC when you leave the house!",file:"ac-2.m4a"},{msg:"Using fans with the AC can help cool the house better!",file:"ac-3.m4a"}],"ceiling-fan":[{msg:"Fans use much less electricity than AC.",file:"ceiling-fan-0.m4a"},{msg:"It is better to open the windows when you are using fans.",file:"ceiling-fan-1.m4a"}],dryer:[{msg:"Drying machines use a lot of energy!",file:"dryer-0.m4a"},{msg:"Using low heat will use less energy.",file:"dryer-1.m4a"},{msg:"Drying your clothes out in the sun does not use any electricity!",file:"dryer-2.m4a"}],idle:[{msg:"Turn on an appliance to see how much electricity it uses!",file:"idle-0.m4a"},{msg:"You can tap the screen or use the switch!",file:"idle-1.m4a"}],light:[{msg:"LED lights use less energy.",file:"light-0.m4a"},{msg:"LED lights can last for a long time.",file:"light-1.m4a"},{msg:"Turn off the light when you leave the room to save energy!",file:"light-2.m4a"}],oven:[{msg:"Electric ovens need a lot of energy.",file:"oven-0.m4a"},{msg:"Ovens can be HOT. Do not use the oven without an adult around!",file:"oven-1.m4a"},{msg:"Cooking on the stove uses less energy than cooking in the oven.",file:"oven-2.m4a"}],"porch-light":[{msg:"Motion-activated porch lights can save energy.",file:"porch-light-0.m4a"},{msg:"Solar-powered porch lights are a great option to save energy!",file:"porch-light-1.m4a"}],refrigerator:[{msg:"Refrigerators are always on to keep your food cold.",file:"refrigerator-0.m4a"},{msg:"Try not to leave the refrigerator open for long.",file:"refrigerator-1.m4a"}],"solar-panel":[{msg:"Solar panels turn sunlight into energy.",file:"solar-panel-0.m4a"},{msg:"Solar panels work the best when it is sunny!",file:"solar-panel-1.m4a"},{msg:"Solar energy is renewable energy.",file:"solar-panel-2.m4a"}],tv:[{msg:"Old CRT TVs use more energy than new LED TVs.",file:"tv-0.m4a"},{msg:"Turn off the TV when you are not watching to save energy!",file:"tv-1.m4a"}],washer:[{msg:"Washing machines need electricity too!",file:"washer-0.m4a"},{msg:"Washing clothes with hot water uses more energy.",file:"washer-1.m4a"},{msg:"Many washers have eco-friendly settings!",file:"washer-2.m4a"}]};function j1(t,n){if(t&1&&(L(0,"div",4),le(1,"img",5),L(2,"p",6),Bn(3),j()()),t&2){let e=Yt();q(3),xs(e.msg)}}var jc=class t{itemToggled;showMsg=!1;lightbulbMessageAudio=Kp;msg="";ngOnChanges(){this.lightbulbMessageAudio[this.itemToggled.name]&&this.showApplianceMsg()}ngOnInit(){this.preloadSpeechBubble(),this.preloadAudio(),this.cycleIdleMsg()}preloadSpeechBubble(){let n=new Image;n.src="assets/images/lightbulb/speech-bubble.png"}preloadAudio(){for(let n in Kp)for(let e in this.lightbulbMessageAudio[n]){let i=new Audio;i.src=`assets/audio/lightbulb/${this.lightbulbMessageAudio[n][e].file}`,i.preload="auto",this.lightbulbMessageAudio[n][e].audio=i}}showApplianceMsg(){let n=this.lightbulbMessageAudio[this.itemToggled.name],e=10*1e3;if(!this.showMsg){let i=Math.floor(Math.random()*n.length);this.msg=n[i].msg,this.showMsg=!0,n[i].audio?.play(),setTimeout(()=>{this.showMsg=!1},e)}}showIdleMsg(){let e=this.lightbulbMessageAudio.idle,i=Math.floor(Math.random()*e.length);this.showMsg||(this.msg=e[i].msg,this.showMsg=!0,e[i].audio?.play(),setTimeout(()=>{this.showMsg=!1},1e4))}cycleIdleMsg(){var i=0;setInterval(()=>{this.showMsg?i=0:i++,i>=30&&this.showIdleMsg()},1e3)}static \u0275fac=function(e){return new(e||t)};static \u0275cmp=Fe({type:t,selectors:[["app-lightbulb"]],inputs:{itemToggled:"itemToggled"},features:[Rt],decls:4,vars:1,consts:[[1,"lightbulb-wrapper"],[1,"lightbulb"],["src","assets/images/lightbulb/lightbulb.png","alt","Lightbulb Friend","id","lightbulb"],["class","speech-bubble",4,"ngIf"],[1,"speech-bubble"],["src","assets/images/lightbulb/speech-bubble.png","alt","Speech Bubble","id","speech"],[1,"message"]],template:function(e,i){e&1&&(L(0,"div",0)(1,"div",1),le(2,"img",2),j()(),gn(3,j1,4,1,"div",3)),e&2&&(q(3),Y("ngIf",i.showMsg))},dependencies:[Is],styles:[".lightbulb-wrapper[_ngcontent-%COMP%]{position:absolute;bottom:calc(2% + 371px);left:12%}.lightbulb-wrapper[_ngcontent-%COMP%] #lightbulb[_ngcontent-%COMP%]{display:inline-block;height:255px}.speech-bubble[_ngcontent-%COMP%]{position:absolute;bottom:calc(2% + 550px);left:calc(12% + 130px);text-align:center;vertical-align:middle;align-items:center;display:inline-flex;width:fit-content}.speech-bubble[_ngcontent-%COMP%] .message[_ngcontent-%COMP%]{position:absolute;left:14%;width:75%;transform:translateY(-50%)}"]})};var Hc=class t{title="watt-patrol";itemToggled="";time=2;onItemToggled(n){this.itemToggled=n}onTimeChange(n){this.time=n,this.updateBodyBackground()}updateBodyBackground(){let n=this.getBackgroundColor();document.body.style.backgroundColor=n}getBackgroundColor(){switch(this.time){case 0:return"#2c3e50";case 1:return"#ffcc66";case 2:return"#9ed5eb";default:return"#9ed5eb"}}constructor(){}static \u0275fac=function(e){return new(e||t)};static \u0275cmp=Fe({type:t,selectors:[["app-root"]],decls:7,vars:3,consts:[["houseComponent",""],[3,"turnOffAll","itemToggled","timeOfDay"],[3,"itemToggled"],[3,"timeValue"]],template:function(e,i){if(e&1){let r=sl();L(0,"div")(1,"app-energy-meter",1),xe("turnOffAll",function(){Di(r);let o=vh(3);return _i(o.turnOffAllAppliances())}),j(),L(2,"app-house",2,0),xe("itemToggled",function(o){return Di(r),_i(i.onItemToggled(o))}),j(),L(4,"app-day-night-slider",3),xe("timeValue",function(o){return Di(r),_i(i.onTimeChange(o))}),j(),le(5,"app-appliance-chart")(6,"app-lightbulb",2),j()}if(e&2){let r=vh(3);q(),Y("itemToggled",r.itemToggled)("timeOfDay",i.time),q(5),Y("itemToggled",i.itemToggled)}},dependencies:[Zl,Ql,Kl,Vc,jc]})};var Bc=class t{static \u0275fac=function(e){return new(e||t)};static \u0275mod=ut({type:t,bootstrap:[Hc]});static \u0275inj=ct({providers:[{provide:Ml,useValue:!0}],imports:[Pb,Ub,ql]})};kb().bootstrapModule(Bc,{ngZoneEventCoalescing:!0}).catch(t=>console.error(t)); diff --git a/media/background-T5NTGB4M.png b/media/background-T5NTGB4M.png new file mode 100644 index 0000000..ced2117 Binary files /dev/null and b/media/background-T5NTGB4M.png differ diff --git a/media/comic-GJAHG5XG.ttf b/media/comic-GJAHG5XG.ttf new file mode 100644 index 0000000..d17e1be Binary files /dev/null and b/media/comic-GJAHG5XG.ttf differ diff --git a/media/digital-7-CXYRQQZV.ttf b/media/digital-7-CXYRQQZV.ttf new file mode 100644 index 0000000..74209e6 Binary files /dev/null and b/media/digital-7-CXYRQQZV.ttf differ diff --git a/media/meter-ARYQV2XQ.png b/media/meter-ARYQV2XQ.png new file mode 100644 index 0000000..6d5cfbd Binary files /dev/null and b/media/meter-ARYQV2XQ.png differ diff --git a/polyfills-FFHMD2TL.js b/polyfills-FFHMD2TL.js new file mode 100644 index 0000000..b01b791 --- /dev/null +++ b/polyfills-FFHMD2TL.js @@ -0,0 +1,2 @@ +var ce=globalThis;function te(e){return(ce.__Zone_symbol_prefix||"__zone_symbol__")+e}function dt(){let e=ce.performance;function n(M){e&&e.mark&&e.mark(M)}function a(M,s){e&&e.measure&&e.measure(M,s)}n("Zone");class t{static{this.__symbol__=te}static assertZonePatched(){if(ce.Promise!==S.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let s=t.current;for(;s.parent;)s=s.parent;return s}static get current(){return b.zone}static get currentTask(){return D}static __load_patch(s,i,o=!1){if(S.hasOwnProperty(s)){let g=ce[te("forceDuplicateZoneCheck")]===!0;if(!o&&g)throw Error("Already loaded patch: "+s)}else if(!ce["__Zone_disable_"+s]){let g="Zone:"+s;n(g),S[s]=i(ce,t,w),a(g,g)}}get parent(){return this._parent}get name(){return this._name}constructor(s,i){this._parent=s,this._name=i?i.name||"unnamed":"",this._properties=i&&i.properties||{},this._zoneDelegate=new f(this,this._parent&&this._parent._zoneDelegate,i)}get(s){let i=this.getZoneWith(s);if(i)return i._properties[s]}getZoneWith(s){let i=this;for(;i;){if(i._properties.hasOwnProperty(s))return i;i=i._parent}return null}fork(s){if(!s)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,s)}wrap(s,i){if(typeof s!="function")throw new Error("Expecting function got: "+s);let o=this._zoneDelegate.intercept(this,s,i),g=this;return function(){return g.runGuarded(o,this,arguments,i)}}run(s,i,o,g){b={parent:b,zone:this};try{return this._zoneDelegate.invoke(this,s,i,o,g)}finally{b=b.parent}}runGuarded(s,i=null,o,g){b={parent:b,zone:this};try{try{return this._zoneDelegate.invoke(this,s,i,o,g)}catch(V){if(this._zoneDelegate.handleError(this,V))throw V}}finally{b=b.parent}}runTask(s,i,o){if(s.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(s.zone||J).name+"; Execution: "+this.name+")");let g=s,{type:V,data:{isPeriodic:ee=!1,isRefreshable:Z=!1}={}}=s;if(s.state===q&&(V===z||V===y))return;let he=s.state!=A;he&&g._transitionTo(A,d);let _e=D;D=g,b={parent:b,zone:this};try{V==y&&s.data&&!ee&&!Z&&(s.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,g,i,o)}catch(Q){if(this._zoneDelegate.handleError(this,Q))throw Q}}finally{let Q=s.state;if(Q!==q&&Q!==X)if(V==z||ee||Z&&Q===k)he&&g._transitionTo(d,A,k);else{let Ee=g._zoneDelegates;this._updateTaskCount(g,-1),he&&g._transitionTo(q,A,q),Z&&(g._zoneDelegates=Ee)}b=b.parent,D=_e}}scheduleTask(s){if(s.zone&&s.zone!==this){let o=this;for(;o;){if(o===s.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${s.zone.name}`);o=o.parent}}s._transitionTo(k,q);let i=[];s._zoneDelegates=i,s._zone=this;try{s=this._zoneDelegate.scheduleTask(this,s)}catch(o){throw s._transitionTo(X,k,q),this._zoneDelegate.handleError(this,o),o}return s._zoneDelegates===i&&this._updateTaskCount(s,1),s.state==k&&s._transitionTo(d,k),s}scheduleMicroTask(s,i,o,g){return this.scheduleTask(new E(G,s,i,o,g,void 0))}scheduleMacroTask(s,i,o,g,V){return this.scheduleTask(new E(y,s,i,o,g,V))}scheduleEventTask(s,i,o,g,V){return this.scheduleTask(new E(z,s,i,o,g,V))}cancelTask(s){if(s.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(s.zone||J).name+"; Execution: "+this.name+")");if(!(s.state!==d&&s.state!==A)){s._transitionTo(x,d,A);try{this._zoneDelegate.cancelTask(this,s)}catch(i){throw s._transitionTo(X,x),this._zoneDelegate.handleError(this,i),i}return this._updateTaskCount(s,-1),s._transitionTo(q,x),s.runCount=-1,s}}_updateTaskCount(s,i){let o=s._zoneDelegates;i==-1&&(s._zoneDelegates=null);for(let g=0;gM.hasTask(i,o),onScheduleTask:(M,s,i,o)=>M.scheduleTask(i,o),onInvokeTask:(M,s,i,o,g,V)=>M.invokeTask(i,o,g,V),onCancelTask:(M,s,i,o)=>M.cancelTask(i,o)};class f{get zone(){return this._zone}constructor(s,i,o){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this._zone=s,this._parentDelegate=i,this._forkZS=o&&(o&&o.onFork?o:i._forkZS),this._forkDlgt=o&&(o.onFork?i:i._forkDlgt),this._forkCurrZone=o&&(o.onFork?this._zone:i._forkCurrZone),this._interceptZS=o&&(o.onIntercept?o:i._interceptZS),this._interceptDlgt=o&&(o.onIntercept?i:i._interceptDlgt),this._interceptCurrZone=o&&(o.onIntercept?this._zone:i._interceptCurrZone),this._invokeZS=o&&(o.onInvoke?o:i._invokeZS),this._invokeDlgt=o&&(o.onInvoke?i:i._invokeDlgt),this._invokeCurrZone=o&&(o.onInvoke?this._zone:i._invokeCurrZone),this._handleErrorZS=o&&(o.onHandleError?o:i._handleErrorZS),this._handleErrorDlgt=o&&(o.onHandleError?i:i._handleErrorDlgt),this._handleErrorCurrZone=o&&(o.onHandleError?this._zone:i._handleErrorCurrZone),this._scheduleTaskZS=o&&(o.onScheduleTask?o:i._scheduleTaskZS),this._scheduleTaskDlgt=o&&(o.onScheduleTask?i:i._scheduleTaskDlgt),this._scheduleTaskCurrZone=o&&(o.onScheduleTask?this._zone:i._scheduleTaskCurrZone),this._invokeTaskZS=o&&(o.onInvokeTask?o:i._invokeTaskZS),this._invokeTaskDlgt=o&&(o.onInvokeTask?i:i._invokeTaskDlgt),this._invokeTaskCurrZone=o&&(o.onInvokeTask?this._zone:i._invokeTaskCurrZone),this._cancelTaskZS=o&&(o.onCancelTask?o:i._cancelTaskZS),this._cancelTaskDlgt=o&&(o.onCancelTask?i:i._cancelTaskDlgt),this._cancelTaskCurrZone=o&&(o.onCancelTask?this._zone:i._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;let g=o&&o.onHasTask,V=i&&i._hasTaskZS;(g||V)&&(this._hasTaskZS=g?o:c,this._hasTaskDlgt=i,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=this._zone,o.onScheduleTask||(this._scheduleTaskZS=c,this._scheduleTaskDlgt=i,this._scheduleTaskCurrZone=this._zone),o.onInvokeTask||(this._invokeTaskZS=c,this._invokeTaskDlgt=i,this._invokeTaskCurrZone=this._zone),o.onCancelTask||(this._cancelTaskZS=c,this._cancelTaskDlgt=i,this._cancelTaskCurrZone=this._zone))}fork(s,i){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,s,i):new t(s,i)}intercept(s,i,o){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,s,i,o):i}invoke(s,i,o,g,V){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,s,i,o,g,V):i.apply(o,g)}handleError(s,i){return this._handleErrorZS?this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,s,i):!0}scheduleTask(s,i){let o=i;if(this._scheduleTaskZS)this._hasTaskZS&&o._zoneDelegates.push(this._hasTaskDlgtOwner),o=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,s,i),o||(o=i);else if(i.scheduleFn)i.scheduleFn(i);else if(i.type==G)U(i);else throw new Error("Task is missing scheduleFn.");return o}invokeTask(s,i,o,g){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,s,i,o,g):i.callback.apply(o,g)}cancelTask(s,i){let o;if(this._cancelTaskZS)o=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,s,i);else{if(!i.cancelFn)throw Error("Task is not cancelable");o=i.cancelFn(i)}return o}hasTask(s,i){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,s,i)}catch(o){this.handleError(s,o)}}_updateTaskCount(s,i){let o=this._taskCounts,g=o[s],V=o[s]=g+i;if(V<0)throw new Error("More tasks executed then were scheduled.");if(g==0||V==0){let ee={microTask:o.microTask>0,macroTask:o.macroTask>0,eventTask:o.eventTask>0,change:s};this.hasTask(this._zone,ee)}}}class E{constructor(s,i,o,g,V,ee){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=s,this.source=i,this.data=g,this.scheduleFn=V,this.cancelFn=ee,!o)throw new Error("callback is not defined");this.callback=o;let Z=this;s===z&&g&&g.useG?this.invoke=E.invokeTask:this.invoke=function(){return E.invokeTask.call(ce,Z,this,arguments)}}static invokeTask(s,i,o){s||(s=this),K++;try{return s.runCount++,s.zone.runTask(s,i,o)}finally{K==1&&$(),K--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(q,k)}_transitionTo(s,i,o){if(this._state===i||this._state===o)this._state=s,s==q&&(this._zoneDelegates=null);else throw new Error(`${this.type} '${this.source}': can not transition to '${s}', expecting state '${i}'${o?" or '"+o+"'":""}, was '${this._state}'.`)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}let T=te("setTimeout"),p=te("Promise"),C=te("then"),_=[],P=!1,I;function H(M){if(I||ce[p]&&(I=ce[p].resolve(0)),I){let s=I[C];s||(s=I.then),s.call(I,M)}else ce[T](M,0)}function U(M){K===0&&_.length===0&&H($),M&&_.push(M)}function $(){if(!P){for(P=!0;_.length;){let M=_;_=[];for(let s=0;sb,onUnhandledError:W,microtaskDrainDone:W,scheduleMicroTask:U,showUncaughtError:()=>!t[te("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:W,patchMethod:()=>W,bindArguments:()=>[],patchThen:()=>W,patchMacroTask:()=>W,patchEventPrototype:()=>W,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>W,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>W,wrapWithCurrentZone:()=>W,filterProperties:()=>[],attachOriginToPatched:()=>W,_redefineProperty:()=>W,patchCallbacks:()=>W,nativeScheduleMicroTask:H},b={parent:null,zone:new t(null,null)},D=null,K=0;function W(){}return a("Zone","Zone"),t}function _t(){let e=globalThis,n=e[te("forceDuplicateZoneCheck")]===!0;if(e.Zone&&(n||typeof e.Zone.__symbol__!="function"))throw new Error("Zone already loaded.");return e.Zone??=dt(),e.Zone}var be=Object.getOwnPropertyDescriptor,Ae=Object.defineProperty,je=Object.getPrototypeOf,Et=Object.create,Tt=Array.prototype.slice,He="addEventListener",xe="removeEventListener",Le=te(He),Ie=te(xe),ae="true",le="false",Pe=te("");function Ve(e,n){return Zone.current.wrap(e,n)}function Ge(e,n,a,t,c){return Zone.current.scheduleMacroTask(e,n,a,t,c)}var j=te,De=typeof window<"u",pe=De?window:void 0,Y=De&&pe||globalThis,gt="removeAttribute";function Fe(e,n){for(let a=e.length-1;a>=0;a--)typeof e[a]=="function"&&(e[a]=Ve(e[a],n+"_"+a));return e}function yt(e,n){let a=e.constructor.name;for(let t=0;t{let p=function(){return T.apply(this,Fe(arguments,a+"."+c))};return fe(p,T),p})(f)}}}function tt(e){return e?e.writable===!1?!1:!(typeof e.get=="function"&&typeof e.set>"u"):!0}var nt=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,Se=!("nw"in Y)&&typeof Y.process<"u"&&Y.process.toString()==="[object process]",Be=!Se&&!nt&&!!(De&&pe.HTMLElement),rt=typeof Y.process<"u"&&Y.process.toString()==="[object process]"&&!nt&&!!(De&&pe.HTMLElement),Ce={},mt=j("enable_beforeunload"),Ye=function(e){if(e=e||Y.event,!e)return;let n=Ce[e.type];n||(n=Ce[e.type]=j("ON_PROPERTY"+e.type));let a=this||e.target||Y,t=a[n],c;if(Be&&a===pe&&e.type==="error"){let f=e;c=t&&t.call(this,f.message,f.filename,f.lineno,f.colno,f.error),c===!0&&e.preventDefault()}else c=t&&t.apply(this,arguments),e.type==="beforeunload"&&Y[mt]&&typeof c=="string"?e.returnValue=c:c!=null&&!c&&e.preventDefault();return c};function $e(e,n,a){let t=be(e,n);if(!t&&a&&be(a,n)&&(t={enumerable:!0,configurable:!0}),!t||!t.configurable)return;let c=j("on"+n+"patched");if(e.hasOwnProperty(c)&&e[c])return;delete t.writable,delete t.value;let f=t.get,E=t.set,T=n.slice(2),p=Ce[T];p||(p=Ce[T]=j("ON_PROPERTY"+T)),t.set=function(C){let _=this;if(!_&&e===Y&&(_=Y),!_)return;typeof _[p]=="function"&&_.removeEventListener(T,Ye),E&&E.call(_,null),_[p]=C,typeof C=="function"&&_.addEventListener(T,Ye,!1)},t.get=function(){let C=this;if(!C&&e===Y&&(C=Y),!C)return null;let _=C[p];if(_)return _;if(f){let P=f.call(this);if(P)return t.set.call(this,P),typeof C[gt]=="function"&&C.removeAttribute(n),P}return null},Ae(e,n,t),e[c]=!0}function ot(e,n,a){if(n)for(let t=0;tfunction(E,T){let p=a(E,T);return p.cbIdx>=0&&typeof T[p.cbIdx]=="function"?Ge(p.name,T[p.cbIdx],p,c):f.apply(E,T)})}function fe(e,n){e[j("OriginalDelegate")]=n}var Je=!1,Me=!1;function kt(){try{let e=pe.navigator.userAgent;if(e.indexOf("MSIE ")!==-1||e.indexOf("Trident/")!==-1)return!0}catch{}return!1}function vt(){if(Je)return Me;Je=!0;try{let e=pe.navigator.userAgent;(e.indexOf("MSIE ")!==-1||e.indexOf("Trident/")!==-1||e.indexOf("Edge/")!==-1)&&(Me=!0)}catch{}return Me}function Ke(e){return typeof e=="function"}function Qe(e){return typeof e=="number"}var me=!1;if(typeof window<"u")try{let e=Object.defineProperty({},"passive",{get:function(){me=!0}});window.addEventListener("test",e,e),window.removeEventListener("test",e,e)}catch{me=!1}var bt={useG:!0},ne={},st={},it=new RegExp("^"+Pe+"(\\w+)(true|false)$"),ct=j("propagationStopped");function at(e,n){let a=(n?n(e):e)+le,t=(n?n(e):e)+ae,c=Pe+a,f=Pe+t;ne[e]={},ne[e][le]=c,ne[e][ae]=f}function Pt(e,n,a,t){let c=t&&t.add||He,f=t&&t.rm||xe,E=t&&t.listeners||"eventListeners",T=t&&t.rmAll||"removeAllListeners",p=j(c),C="."+c+":",_="prependListener",P="."+_+":",I=function(k,d,A){if(k.isRemoved)return;let x=k.callback;typeof x=="object"&&x.handleEvent&&(k.callback=y=>x.handleEvent(y),k.originalDelegate=x);let X;try{k.invoke(k,d,[A])}catch(y){X=y}let G=k.options;if(G&&typeof G=="object"&&G.once){let y=k.originalDelegate?k.originalDelegate:k.callback;d[f].call(d,A.type,y,G)}return X};function H(k,d,A){if(d=d||e.event,!d)return;let x=k||d.target||e,X=x[ne[d.type][A?ae:le]];if(X){let G=[];if(X.length===1){let y=I(X[0],x,d);y&&G.push(y)}else{let y=X.slice();for(let z=0;z{throw z})}}}let U=function(k){return H(this,k,!1)},$=function(k){return H(this,k,!0)};function J(k,d){if(!k)return!1;let A=!0;d&&d.useG!==void 0&&(A=d.useG);let x=d&&d.vh,X=!0;d&&d.chkDup!==void 0&&(X=d.chkDup);let G=!1;d&&d.rt!==void 0&&(G=d.rt);let y=k;for(;y&&!y.hasOwnProperty(c);)y=je(y);if(!y&&k[c]&&(y=k),!y||y[p])return!1;let z=d&&d.eventNameToString,S={},w=y[p]=y[c],b=y[j(f)]=y[f],D=y[j(E)]=y[E],K=y[j(T)]=y[T],W;d&&d.prepend&&(W=y[j(d.prepend)]=y[d.prepend]);function M(r,u){return!me&&typeof r=="object"&&r?!!r.capture:!me||!u?r:typeof r=="boolean"?{capture:r,passive:!0}:r?typeof r=="object"&&r.passive!==!1?{...r,passive:!0}:r:{passive:!0}}let s=function(r){if(!S.isExisting)return w.call(S.target,S.eventName,S.capture?$:U,S.options)},i=function(r){if(!r.isRemoved){let u=ne[r.eventName],v;u&&(v=u[r.capture?ae:le]);let R=v&&r.target[v];if(R){for(let m=0;mre.zone.cancelTask(re);r.call(Te,"abort",ie,{once:!0}),re.removeAbortListener=()=>Te.removeEventListener("abort",ie)}if(S.target=null,ke&&(ke.taskData=null),Ue&&(S.options.once=!0),!me&&typeof re.options=="boolean"||(re.options=se),re.target=N,re.capture=Oe,re.eventName=L,B&&(re.originalDelegate=F),O?ge.unshift(re):ge.push(re),m)return N}};return y[c]=l(w,C,ee,Z,G),W&&(y[_]=l(W,P,g,Z,G,!0)),y[f]=function(){let r=this||e,u=arguments[0];d&&d.transferEventName&&(u=d.transferEventName(u));let v=arguments[2],R=v?typeof v=="boolean"?!0:v.capture:!1,m=arguments[1];if(!m)return b.apply(this,arguments);if(x&&!x(b,m,r,arguments))return;let O=ne[u],N;O&&(N=O[R?ae:le]);let L=N&&r[N];if(L)for(let F=0;Ffunction(c,f){c[ct]=!0,t&&t.apply(c,f)})}function Rt(e,n){n.patchMethod(e,"queueMicrotask",a=>function(t,c){Zone.current.scheduleMicroTask("queueMicrotask",c[0])})}var Re=j("zoneTask");function ye(e,n,a,t){let c=null,f=null;n+=t,a+=t;let E={};function T(C){let _=C.data;_.args[0]=function(){return C.invoke.apply(this,arguments)};let P=c.apply(e,_.args);return Qe(P)?_.handleId=P:(_.handle=P,_.isRefreshable=Ke(P.refresh)),C}function p(C){let{handle:_,handleId:P}=C.data;return f.call(e,_??P)}c=ue(e,n,C=>function(_,P){if(Ke(P[0])){let I={isRefreshable:!1,isPeriodic:t==="Interval",delay:t==="Timeout"||t==="Interval"?P[1]||0:void 0,args:P},H=P[0];P[0]=function(){try{return H.apply(this,arguments)}finally{let{handle:A,handleId:x,isPeriodic:X,isRefreshable:G}=I;!X&&!G&&(x?delete E[x]:A&&(A[Re]=null))}};let U=Ge(n,P[0],I,T,p);if(!U)return U;let{handleId:$,handle:J,isRefreshable:q,isPeriodic:k}=U.data;if($)E[$]=U;else if(J&&(J[Re]=U,q&&!k)){let d=J.refresh;J.refresh=function(){let{zone:A,state:x}=U;return x==="notScheduled"?(U._state="scheduled",A._updateTaskCount(U,1)):x==="running"&&(U._state="scheduling"),d.call(this)}}return J??$??U}else return C.apply(e,P)}),f=ue(e,a,C=>function(_,P){let I=P[0],H;Qe(I)?(H=E[I],delete E[I]):(H=I?.[Re],H?I[Re]=null:H=I),H?.type?H.cancelFn&&H.zone.cancelTask(H):C.apply(e,P)})}function Ct(e,n){let{isBrowser:a,isMix:t}=n.getGlobalObjects();if(!a&&!t||!e.customElements||!("customElements"in e))return;let c=["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback","formAssociatedCallback","formDisabledCallback","formResetCallback","formStateRestoreCallback"];n.patchCallbacks(n,e.customElements,"customElements","define",c)}function Dt(e,n){if(Zone[n.symbol("patchEventTarget")])return;let{eventNames:a,zoneSymbolEventNames:t,TRUE_STR:c,FALSE_STR:f,ZONE_SYMBOL_PREFIX:E}=n.getGlobalObjects();for(let p=0;pf.target===e);if(!t||t.length===0)return n;let c=t[0].ignoreProperties;return n.filter(f=>c.indexOf(f)===-1)}function et(e,n,a,t){if(!e)return;let c=ut(e,n,a);ot(e,c,t)}function Ze(e){return Object.getOwnPropertyNames(e).filter(n=>n.startsWith("on")&&n.length>2).map(n=>n.substring(2))}function Ot(e,n){if(Se&&!rt||Zone[e.symbol("patchEvents")])return;let a=n.__Zone_ignore_on_properties,t=[];if(Be){let c=window;t=t.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);let f=kt()?[{target:c,ignoreProperties:["error"]}]:[];et(c,Ze(c),a&&a.concat(f),je(c))}t=t.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let c=0;c{let a=n[e.__symbol__("legacyPatch")];a&&a()}),e.__load_patch("timers",n=>{let a="set",t="clear";ye(n,a,t,"Timeout"),ye(n,a,t,"Interval"),ye(n,a,t,"Immediate")}),e.__load_patch("requestAnimationFrame",n=>{ye(n,"request","cancel","AnimationFrame"),ye(n,"mozRequest","mozCancel","AnimationFrame"),ye(n,"webkitRequest","webkitCancel","AnimationFrame")}),e.__load_patch("blocking",(n,a)=>{let t=["alert","prompt","confirm"];for(let c=0;cfunction(C,_){return a.current.run(E,n,_,p)})}}),e.__load_patch("EventTarget",(n,a,t)=>{St(n,t),Dt(n,t);let c=n.XMLHttpRequestEventTarget;c&&c.prototype&&t.patchEventTarget(n,t,[c.prototype])}),e.__load_patch("MutationObserver",(n,a,t)=>{ve("MutationObserver"),ve("WebKitMutationObserver")}),e.__load_patch("IntersectionObserver",(n,a,t)=>{ve("IntersectionObserver")}),e.__load_patch("FileReader",(n,a,t)=>{ve("FileReader")}),e.__load_patch("on_property",(n,a,t)=>{Ot(t,n)}),e.__load_patch("customElements",(n,a,t)=>{Ct(n,t)}),e.__load_patch("XHR",(n,a)=>{C(n);let t=j("xhrTask"),c=j("xhrSync"),f=j("xhrListener"),E=j("xhrScheduled"),T=j("xhrURL"),p=j("xhrErrorBeforeScheduled");function C(_){let P=_.XMLHttpRequest;if(!P)return;let I=P.prototype;function H(w){return w[t]}let U=I[Le],$=I[Ie];if(!U){let w=_.XMLHttpRequestEventTarget;if(w){let b=w.prototype;U=b[Le],$=b[Ie]}}let J="readystatechange",q="scheduled";function k(w){let b=w.data,D=b.target;D[E]=!1,D[p]=!1;let K=D[f];U||(U=D[Le],$=D[Ie]),K&&$.call(D,J,K);let W=D[f]=()=>{if(D.readyState===D.DONE)if(!b.aborted&&D[E]&&w.state===q){let s=D[a.__symbol__("loadfalse")];if(D.status!==0&&s&&s.length>0){let i=w.invoke;w.invoke=function(){let o=D[a.__symbol__("loadfalse")];for(let g=0;gfunction(w,b){return w[c]=b[2]==!1,w[T]=b[1],x.apply(w,b)}),X="XMLHttpRequest.send",G=j("fetchTaskAborting"),y=j("fetchTaskScheduling"),z=ue(I,"send",()=>function(w,b){if(a.current[y]===!0||w[c])return z.apply(w,b);{let D={target:w,url:w[T],isPeriodic:!1,args:b,aborted:!1},K=Ge(X,d,D,k,A);w&&w[p]===!0&&!D.aborted&&K.state===q&&K.invoke()}}),S=ue(I,"abort",()=>function(w,b){let D=H(w);if(D&&typeof D.type=="string"){if(D.cancelFn==null||D.data&&D.data.aborted)return;D.zone.cancelTask(D)}else if(a.current[G]===!0)return S.apply(w,b)})}}),e.__load_patch("geolocation",n=>{n.navigator&&n.navigator.geolocation&&yt(n.navigator.geolocation,["getCurrentPosition","watchPosition"])}),e.__load_patch("PromiseRejectionEvent",(n,a)=>{function t(c){return function(f){lt(n,c).forEach(T=>{let p=n.PromiseRejectionEvent;if(p){let C=new p(c,{promise:f.promise,reason:f.rejection});T.invoke(C)}})}}n.PromiseRejectionEvent&&(a[j("unhandledPromiseRejectionHandler")]=t("unhandledrejection"),a[j("rejectionHandledHandler")]=t("rejectionhandled"))}),e.__load_patch("queueMicrotask",(n,a,t)=>{Rt(n,t)})}function Lt(e){e.__load_patch("ZoneAwarePromise",(n,a,t)=>{let c=Object.getOwnPropertyDescriptor,f=Object.defineProperty;function E(h){if(h&&h.toString===Object.prototype.toString){let l=h.constructor&&h.constructor.name;return(l||"")+": "+JSON.stringify(h)}return h?h.toString():Object.prototype.toString.call(h)}let T=t.symbol,p=[],C=n[T("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")]!==!1,_=T("Promise"),P=T("then"),I="__creationTrace__";t.onUnhandledError=h=>{if(t.showUncaughtError()){let l=h&&h.rejection;l?console.error("Unhandled Promise rejection:",l instanceof Error?l.message:l,"; Zone:",h.zone.name,"; Task:",h.task&&h.task.source,"; Value:",l,l instanceof Error?l.stack:void 0):console.error(h)}},t.microtaskDrainDone=()=>{for(;p.length;){let h=p.shift();try{h.zone.runGuarded(()=>{throw h.throwOriginal?h.rejection:h})}catch(l){U(l)}}};let H=T("unhandledPromiseRejectionHandler");function U(h){t.onUnhandledError(h);try{let l=a[H];typeof l=="function"&&l.call(this,h)}catch{}}function $(h){return h&&h.then}function J(h){return h}function q(h){return Z.reject(h)}let k=T("state"),d=T("value"),A=T("finally"),x=T("parentPromiseValue"),X=T("parentPromiseState"),G="Promise.then",y=null,z=!0,S=!1,w=0;function b(h,l){return r=>{try{M(h,l,r)}catch(u){M(h,!1,u)}}}let D=function(){let h=!1;return function(r){return function(){h||(h=!0,r.apply(null,arguments))}}},K="Promise resolved with itself",W=T("currentTaskTrace");function M(h,l,r){let u=D();if(h===r)throw new TypeError(K);if(h[k]===y){let v=null;try{(typeof r=="object"||typeof r=="function")&&(v=r&&r.then)}catch(R){return u(()=>{M(h,!1,R)})(),h}if(l!==S&&r instanceof Z&&r.hasOwnProperty(k)&&r.hasOwnProperty(d)&&r[k]!==y)i(r),M(h,r[k],r[d]);else if(l!==S&&typeof v=="function")try{v.call(r,u(b(h,l)),u(b(h,!1)))}catch(R){u(()=>{M(h,!1,R)})()}else{h[k]=l;let R=h[d];if(h[d]=r,h[A]===A&&l===z&&(h[k]=h[X],h[d]=h[x]),l===S&&r instanceof Error){let m=a.currentTask&&a.currentTask.data&&a.currentTask.data[I];m&&f(r,W,{configurable:!0,enumerable:!1,writable:!0,value:m})}for(let m=0;m{try{let O=h[d],N=!!r&&A===r[A];N&&(r[x]=O,r[X]=R);let L=l.run(m,void 0,N&&m!==q&&m!==J?[]:[O]);M(r,!0,L)}catch(O){M(r,!1,O)}},r)}let g="function ZoneAwarePromise() { [native code] }",V=function(){},ee=n.AggregateError;class Z{static toString(){return g}static resolve(l){return l instanceof Z?l:M(new this(null),z,l)}static reject(l){return M(new this(null),S,l)}static withResolvers(){let l={};return l.promise=new Z((r,u)=>{l.resolve=r,l.reject=u}),l}static any(l){if(!l||typeof l[Symbol.iterator]!="function")return Promise.reject(new ee([],"All promises were rejected"));let r=[],u=0;try{for(let m of l)u++,r.push(Z.resolve(m))}catch{return Promise.reject(new ee([],"All promises were rejected"))}if(u===0)return Promise.reject(new ee([],"All promises were rejected"));let v=!1,R=[];return new Z((m,O)=>{for(let N=0;N{v||(v=!0,m(L))},L=>{R.push(L),u--,u===0&&(v=!0,O(new ee(R,"All promises were rejected")))})})}static race(l){let r,u,v=new this((O,N)=>{r=O,u=N});function R(O){r(O)}function m(O){u(O)}for(let O of l)$(O)||(O=this.resolve(O)),O.then(R,m);return v}static all(l){return Z.allWithCallback(l)}static allSettled(l){return(this&&this.prototype instanceof Z?this:Z).allWithCallback(l,{thenCallback:u=>({status:"fulfilled",value:u}),errorCallback:u=>({status:"rejected",reason:u})})}static allWithCallback(l,r){let u,v,R=new this((L,F)=>{u=L,v=F}),m=2,O=0,N=[];for(let L of l){$(L)||(L=this.resolve(L));let F=O;try{L.then(B=>{N[F]=r?r.thenCallback(B):B,m--,m===0&&u(N)},B=>{r?(N[F]=r.errorCallback(B),m--,m===0&&u(N)):v(B)})}catch(B){v(B)}m++,O++}return m-=2,m===0&&u(N),R}constructor(l){let r=this;if(!(r instanceof Z))throw new Error("Must be an instanceof Promise.");r[k]=y,r[d]=[];try{let u=D();l&&l(u(b(r,z)),u(b(r,S)))}catch(u){M(r,!1,u)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return Z}then(l,r){let u=this.constructor?.[Symbol.species];(!u||typeof u!="function")&&(u=this.constructor||Z);let v=new u(V),R=a.current;return this[k]==y?this[d].push(R,v,l,r):o(this,R,v,l,r),v}catch(l){return this.then(null,l)}finally(l){let r=this.constructor?.[Symbol.species];(!r||typeof r!="function")&&(r=Z);let u=new r(V);u[A]=A;let v=a.current;return this[k]==y?this[d].push(v,u,l,l):o(this,v,u,l,l),u}}Z.resolve=Z.resolve,Z.reject=Z.reject,Z.race=Z.race,Z.all=Z.all;let he=n[_]=n.Promise;n.Promise=Z;let _e=T("thenPatched");function Q(h){let l=h.prototype,r=c(l,"then");if(r&&(r.writable===!1||!r.configurable))return;let u=l.then;l[P]=u,h.prototype.then=function(v,R){return new Z((O,N)=>{u.call(this,O,N)}).then(v,R)},h[_e]=!0}t.patchThen=Q;function Ee(h){return function(l,r){let u=h.apply(l,r);if(u instanceof Z)return u;let v=u.constructor;return v[_e]||Q(v),u}}return he&&(Q(he),ue(n,"fetch",h=>Ee(h))),Promise[a.__symbol__("uncaughtPromiseErrors")]=p,Z})}function It(e){e.__load_patch("toString",n=>{let a=Function.prototype.toString,t=j("OriginalDelegate"),c=j("Promise"),f=j("Error"),E=function(){if(typeof this=="function"){let _=this[t];if(_)return typeof _=="function"?a.call(_):Object.prototype.toString.call(_);if(this===Promise){let P=n[c];if(P)return a.call(P)}if(this===Error){let P=n[f];if(P)return a.call(P)}}return a.call(this)};E[t]=a,Function.prototype.toString=E;let T=Object.prototype.toString,p="[object Promise]";Object.prototype.toString=function(){return typeof Promise=="function"&&this instanceof Promise?p:T.call(this)}})}function Mt(e,n,a,t,c){let f=Zone.__symbol__(t);if(n[f])return;let E=n[f]=n[t];n[t]=function(T,p,C){return p&&p.prototype&&c.forEach(function(_){let P=`${a}.${t}::`+_,I=p.prototype;try{if(I.hasOwnProperty(_)){let H=e.ObjectGetOwnPropertyDescriptor(I,_);H&&H.value?(H.value=e.wrapWithCurrentZone(H.value,P),e._redefineProperty(p.prototype,_,H)):I[_]&&(I[_]=e.wrapWithCurrentZone(I[_],P))}else I[_]&&(I[_]=e.wrapWithCurrentZone(I[_],P))}catch{}}),E.call(n,T,p,C)},e.attachOriginToPatched(n[t],E)}function Zt(e){e.__load_patch("util",(n,a,t)=>{let c=Ze(n);t.patchOnProperties=ot,t.patchMethod=ue,t.bindArguments=Fe,t.patchMacroTask=pt;let f=a.__symbol__("BLACK_LISTED_EVENTS"),E=a.__symbol__("UNPATCHED_EVENTS");n[E]&&(n[f]=n[E]),n[f]&&(a[f]=a[E]=n[f]),t.patchEventPrototype=wt,t.patchEventTarget=Pt,t.isIEOrEdge=vt,t.ObjectDefineProperty=Ae,t.ObjectGetOwnPropertyDescriptor=be,t.ObjectCreate=Et,t.ArraySlice=Tt,t.patchClass=ve,t.wrapWithCurrentZone=Ve,t.filterProperties=ut,t.attachOriginToPatched=fe,t._redefineProperty=Object.defineProperty,t.patchCallbacks=Mt,t.getGlobalObjects=()=>({globalSources:st,zoneSymbolEventNames:ne,eventNames:c,isBrowser:Be,isMix:rt,isNode:Se,TRUE_STR:ae,FALSE_STR:le,ZONE_SYMBOL_PREFIX:Pe,ADD_EVENT_LISTENER_STR:He,REMOVE_EVENT_LISTENER_STR:xe})})}function At(e){Lt(e),It(e),Zt(e)}var ft=_t();At(ft);Nt(ft); diff --git a/styles-WHZE4NFH.css b/styles-WHZE4NFH.css new file mode 100644 index 0000000..4ce2824 --- /dev/null +++ b/styles-WHZE4NFH.css @@ -0,0 +1 @@ +@font-face{font-family:Comic Sans MS;src:url("./media/comic-GJAHG5XG.ttf") format("truetype");font-weight:400;font-style:normal}html,body{margin:0;position:absolute;height:100%;width:100%}body{display:inline-block;overflow:hidden;background-color:#9ed5eb;background-image:url("./media/background-T5NTGB4M.png");background-size:cover;background-repeat:no-repeat;transition:background-color 1s ease}img{-webkit-user-drag:none}.time-images{margin:-15px -18px -10px 0;width:11vh;height:auto}.time-title{display:flex;flex-direction:column;justify-content:center;margin-right:-10px;font-family:Comic Sans MS,sans-serif;text-wrap:wrap;font-size:1.2rem}.time-range{display:flex;flex-direction:column;justify-content:center;margin-right:-10px;font-family:Comic Sans MS,sans-serif;font-size:1.1rem} diff --git a/wattpatrol.ico b/wattpatrol.ico new file mode 100644 index 0000000..0bcbace Binary files /dev/null and b/wattpatrol.ico differ