@esri/solutions-components 0.10.6 → 0.10.8

Sign up to get free protection for your applications and to get access to all the features.
Files changed (157) hide show
  1. package/dist/cjs/basemap-gallery_7.cjs.entry.js +24 -8
  2. package/dist/cjs/buffer-tools_3.cjs.entry.js +1 -1
  3. package/dist/cjs/calcite-combobox_3.cjs.entry.js +354 -967
  4. package/dist/cjs/calcite-graph_2.cjs.entry.js +1082 -0
  5. package/dist/cjs/calcite-shell-panel_14.cjs.entry.js +6 -6
  6. package/dist/cjs/calcite-tree_3.cjs.entry.js +1 -1
  7. package/dist/cjs/card-manager_3.cjs.entry.js +246 -18
  8. package/dist/cjs/crowdsource-manager.cjs.entry.js +169 -49
  9. package/dist/cjs/instant-apps-control-panel.cjs.entry.js +2 -1
  10. package/dist/cjs/instant-apps-time-filter.cjs.entry.js +40 -21
  11. package/dist/cjs/loader.cjs.js +1 -1
  12. package/dist/cjs/map-select-tools_3.cjs.entry.js +3 -3
  13. package/dist/cjs/pci-calculator.cjs.entry.js +1 -1
  14. package/dist/cjs/public-notification.cjs.entry.js +1 -1
  15. package/dist/cjs/refine-results-flow-item.cjs.entry.js +1 -1
  16. package/dist/cjs/share-item.cjs.entry.js +1 -1
  17. package/dist/cjs/solution-configuration.cjs.entry.js +3 -3
  18. package/dist/cjs/solution-contents_3.cjs.entry.js +3 -3
  19. package/dist/cjs/solutions-components.cjs.js +1 -1
  20. package/dist/cjs/spatial-ref.cjs.entry.js +1 -1
  21. package/dist/collection/assets/t9n/crowdsource-manager/resources.json +5 -1
  22. package/dist/collection/assets/t9n/crowdsource-manager/resources_en.json +5 -1
  23. package/dist/collection/assets/t9n/layer-table/resources.json +1 -0
  24. package/dist/collection/assets/t9n/layer-table/resources_en.json +1 -0
  25. package/dist/collection/assets/t9n/map-card/resources.json +6 -1
  26. package/dist/collection/assets/t9n/map-card/resources_en.json +6 -1
  27. package/dist/collection/components/card-manager/card-manager.js +34 -8
  28. package/dist/collection/components/crowdsource-manager/crowdsource-manager.js +173 -65
  29. package/dist/collection/components/layer-table/layer-table.js +175 -8
  30. package/dist/collection/components/map-card/map-card.css +4 -0
  31. package/dist/collection/components/map-card/map-card.js +368 -3
  32. package/dist/collection/components/map-draw-tools/map-draw-tools.js +1 -1
  33. package/dist/collection/components/map-fullscreen/map-fullscreen.js +1 -1
  34. package/dist/collection/components/map-layer-picker/map-layer-picker.js +9 -3
  35. package/dist/collection/components/map-legend/map-legend.js +1 -1
  36. package/dist/collection/components/map-picker/map-picker.css +8 -0
  37. package/dist/collection/components/map-picker/map-picker.js +74 -3
  38. package/dist/collection/components/map-search/map-search.js +1 -1
  39. package/dist/collection/components/map-select-tools/map-select-tools.js +1 -1
  40. package/dist/collection/components/map-tools/map-tools.js +1 -1
  41. package/dist/collection/components/pci-calculator/pci-calculator.js +1 -1
  42. package/dist/collection/components/pdf-download/pdf-download.js +1 -1
  43. package/dist/collection/components/public-notification/public-notification.js +1 -1
  44. package/dist/collection/components/refine-results-flow-item/refine-results-flow-item.js +1 -1
  45. package/dist/collection/components/refine-selection/refine-selection.js +1 -1
  46. package/dist/collection/components/share-item/share-item.js +1 -1
  47. package/dist/collection/components/solution-configuration/solution-configuration.js +3 -3
  48. package/dist/collection/components/solution-contents/solution-contents.js +1 -1
  49. package/dist/collection/components/solution-item/solution-item.js +1 -1
  50. package/dist/collection/components/solution-item-details/solution-item-details.js +1 -1
  51. package/dist/collection/components/solution-item-icon/solution-item-icon.js +1 -1
  52. package/dist/collection/components/solution-item-sharing/solution-item-sharing.js +1 -1
  53. package/dist/collection/components/solution-organization-variables/solution-organization-variables.js +1 -1
  54. package/dist/collection/components/solution-resource-item/solution-resource-item.js +1 -1
  55. package/dist/collection/components/solution-spatial-ref/solution-spatial-ref.js +1 -1
  56. package/dist/collection/components/solution-template-data/solution-template-data.js +1 -1
  57. package/dist/collection/components/solution-variables/solution-variables.js +1 -1
  58. package/dist/collection/components/spatial-ref/spatial-ref.js +1 -1
  59. package/dist/collection/demos/crowdsource-manager.html +1 -0
  60. package/dist/components/card-manager2.js +20 -8
  61. package/dist/components/crowdsource-manager.js +172 -53
  62. package/dist/components/instant-apps-control-panel.js +2 -1
  63. package/dist/components/instant-apps-time-filter.js +46 -23
  64. package/dist/components/layer-table2.js +72 -10
  65. package/dist/components/map-card2.js +288 -47
  66. package/dist/components/map-draw-tools2.js +1 -1
  67. package/dist/components/map-fullscreen2.js +1 -1
  68. package/dist/components/map-layer-picker2.js +9 -3
  69. package/dist/components/map-legend2.js +1 -1
  70. package/dist/components/map-picker2.js +24 -5
  71. package/dist/components/map-search2.js +1 -1
  72. package/dist/components/map-select-tools2.js +1 -1
  73. package/dist/components/map-tools2.js +1 -1
  74. package/dist/components/pci-calculator.js +1 -1
  75. package/dist/components/pdf-download2.js +1 -1
  76. package/dist/components/public-notification.js +1 -1
  77. package/dist/components/refine-results-flow-item.js +1 -1
  78. package/dist/components/refine-selection2.js +1 -1
  79. package/dist/components/share-item.js +1 -1
  80. package/dist/components/solution-configuration.js +3 -3
  81. package/dist/components/solution-contents2.js +1 -1
  82. package/dist/components/solution-item-details2.js +1 -1
  83. package/dist/components/solution-item-icon2.js +1 -1
  84. package/dist/components/solution-item-sharing2.js +1 -1
  85. package/dist/components/solution-item2.js +1 -1
  86. package/dist/components/solution-organization-variables2.js +1 -1
  87. package/dist/components/solution-resource-item2.js +1 -1
  88. package/dist/components/solution-spatial-ref2.js +1 -1
  89. package/dist/components/solution-template-data2.js +1 -1
  90. package/dist/components/solution-variables2.js +1 -1
  91. package/dist/components/spatial-ref.js +1 -1
  92. package/dist/esm/basemap-gallery_7.entry.js +24 -8
  93. package/dist/esm/buffer-tools_3.entry.js +1 -1
  94. package/dist/esm/calcite-combobox_3.entry.js +369 -982
  95. package/dist/esm/calcite-graph_2.entry.js +1077 -0
  96. package/dist/esm/calcite-shell-panel_14.entry.js +6 -6
  97. package/dist/esm/calcite-tree_3.entry.js +1 -1
  98. package/dist/esm/card-manager_3.entry.js +248 -20
  99. package/dist/esm/crowdsource-manager.entry.js +170 -50
  100. package/dist/esm/instant-apps-control-panel.entry.js +2 -1
  101. package/dist/esm/instant-apps-time-filter.entry.js +41 -22
  102. package/dist/esm/loader.js +1 -1
  103. package/dist/esm/map-select-tools_3.entry.js +3 -3
  104. package/dist/esm/pci-calculator.entry.js +1 -1
  105. package/dist/esm/public-notification.entry.js +1 -1
  106. package/dist/esm/refine-results-flow-item.entry.js +1 -1
  107. package/dist/esm/share-item.entry.js +1 -1
  108. package/dist/esm/solution-configuration.entry.js +3 -3
  109. package/dist/esm/solution-contents_3.entry.js +3 -3
  110. package/dist/esm/solutions-components.js +1 -1
  111. package/dist/esm/spatial-ref.entry.js +1 -1
  112. package/dist/solutions-components/assets/t9n/crowdsource-manager/resources.json +5 -1
  113. package/dist/solutions-components/assets/t9n/crowdsource-manager/resources_en.json +5 -1
  114. package/dist/solutions-components/assets/t9n/layer-table/resources.json +1 -0
  115. package/dist/solutions-components/assets/t9n/layer-table/resources_en.json +1 -0
  116. package/dist/solutions-components/assets/t9n/map-card/resources.json +6 -1
  117. package/dist/solutions-components/assets/t9n/map-card/resources_en.json +6 -1
  118. package/dist/solutions-components/demos/crowdsource-manager.html +1 -0
  119. package/dist/solutions-components/p-0abc1354.entry.js +6 -0
  120. package/dist/solutions-components/p-0f7b5d36.entry.js +6 -0
  121. package/dist/solutions-components/p-1867168b.entry.js +6 -0
  122. package/dist/solutions-components/{p-a9818be2.entry.js → p-20c465e9.entry.js} +1 -1
  123. package/dist/solutions-components/{p-db18bce8.entry.js → p-36b50b5b.entry.js} +1 -1
  124. package/dist/solutions-components/{p-85512ae3.entry.js → p-445213cf.entry.js} +1 -1
  125. package/dist/solutions-components/{p-d49f895d.entry.js → p-4a5f0a97.entry.js} +1 -1
  126. package/dist/solutions-components/{p-002c97df.entry.js → p-5d201016.entry.js} +1 -1
  127. package/dist/solutions-components/{p-b7cec3bd.entry.js → p-618bafec.entry.js} +1 -1
  128. package/dist/solutions-components/p-6a66d5a9.entry.js +6 -0
  129. package/dist/solutions-components/p-71a2d5b8.entry.js +6 -0
  130. package/dist/solutions-components/p-7a64b026.entry.js +17 -0
  131. package/dist/solutions-components/p-85c25564.entry.js +6 -0
  132. package/dist/solutions-components/{p-235bf02e.entry.js → p-913413c3.entry.js} +1 -1
  133. package/dist/solutions-components/p-9af1cb14.entry.js +6 -0
  134. package/dist/solutions-components/{p-49aa2929.entry.js → p-bebd4646.entry.js} +1 -1
  135. package/dist/solutions-components/{p-ab2adcaf.entry.js → p-cc092b22.entry.js} +1 -1
  136. package/dist/solutions-components/p-ce454f5a.entry.js +11 -0
  137. package/dist/solutions-components/solutions-components.esm.js +1 -1
  138. package/dist/types/components/card-manager/card-manager.d.ts +11 -0
  139. package/dist/types/components/crowdsource-manager/crowdsource-manager.d.ts +86 -20
  140. package/dist/types/components/layer-table/layer-table.d.ts +30 -0
  141. package/dist/types/components/map-card/map-card.d.ts +124 -0
  142. package/dist/types/components/map-layer-picker/map-layer-picker.d.ts +4 -0
  143. package/dist/types/components/map-picker/map-picker.d.ts +12 -0
  144. package/dist/types/components.d.ts +130 -0
  145. package/dist/types/preact.d.ts +4 -2
  146. package/package.json +2 -2
  147. package/dist/cjs/calcite-dropdown-group_2.cjs.entry.js +0 -453
  148. package/dist/esm/calcite-dropdown-group_2.entry.js +0 -448
  149. package/dist/solutions-components/p-129fd80e.entry.js +0 -6
  150. package/dist/solutions-components/p-3b426576.entry.js +0 -6
  151. package/dist/solutions-components/p-72b217f2.entry.js +0 -6
  152. package/dist/solutions-components/p-72f01088.entry.js +0 -6
  153. package/dist/solutions-components/p-8b999a2b.entry.js +0 -6
  154. package/dist/solutions-components/p-973ff7b2.entry.js +0 -23
  155. package/dist/solutions-components/p-a001f9c9.entry.js +0 -6
  156. package/dist/solutions-components/p-c683b3fe.entry.js +0 -6
  157. package/dist/solutions-components/p-e9d049bd.entry.js +0 -6
@@ -1,6 +0,0 @@
1
- /*!
2
- * Copyright 2022 Esri
3
- * Licensed under the Apache License, Version 2.0
4
- * http://www.apache.org/licenses/LICENSE-2.0
5
- */
6
- import{r as t,h as e,H as n,F as r,g as i}from"./p-f4c4a2b7.js";import{c as o}from"./p-dcc35070.js";import{l as a}from"./p-4cd4cb85.js";import{g as s}from"./p-7bfecd07.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";import"./p-ac122d9e.js";const{state:u,onChange:l}=o({timeInfoConfigItems:[],filterMode:{type:"filter"},view:null,timeSlider:null,timeInfoItems:[],selectedTimeInfoItem:null,loading:!0});let c;function f(t){return"function"==typeof c[t]?c[t]=c[t](globalThis):c[t]}function h(t){if(!t||"object"!=typeof t||"function"==typeof t)return t;const e=function(t){if(function(t){return"Int8Array"===t?.constructor?.name}(t)||function(t){return"Uint8Array"===t?.constructor?.name}(t)||function(t){return"Uint8ClampedArray"===t?.constructor?.name}(t)||function(t){return"Int16Array"===t?.constructor?.name}(t)||function(t){return"Uint16Array"===t?.constructor?.name}(t)||function(t){return"Int32Array"===t?.constructor?.name}(t)||function(t){return"Uint32Array"===t?.constructor?.name}(t)||function(t){return"Float32Array"===t?.constructor?.name}(t)||function(t){return"Float64Array"===t?.constructor?.name}(t))return t.slice();if(t instanceof Date)return new Date(t.getTime());if(t instanceof ArrayBuffer)return t.slice(0,t.byteLength);if(t instanceof Map){const e=new Map;for(const[n,r]of t)e.set(n,h(r));return e}if(t instanceof Set){const e=new Set;for(const n of t)e.add(h(n));return e}return null}(t);if(null!=e)return e;if(function(t){return"function"==typeof t.clone}(t))return t.clone();if(function(t){return"function"==typeof t.map&&"function"==typeof t.forEach}(t))return t.map(h);if(function(t){return"function"==typeof t.notifyChange&&"function"==typeof t.watch}(t))return t.clone();const n={};for(const e of Object.getOwnPropertyNames(t))n[e]=h(t[e]);return n}function d(t,e,n){return e?Object.keys(e).reduce(((t,r)=>{let i=t[r],o=e[r];return i===o?t:void 0===i?(t[r]=h(o),t):(Array.isArray(o)||Array.isArray(t)?(i=t[r]=i?Array.isArray(i)?i.slice():[i]:[],o&&(Array.isArray(o)||(o=[o]),n?o.forEach((t=>{i.includes(t)||i.push(t)})):t[r]=o.slice())):o&&"object"==typeof o?t[r]=d(i,o,n):t.hasOwnProperty(r)&&!e.hasOwnProperty(r)||(t[r]=o),t)}),t||{}):t}c=globalThis.dojoConfig?.has||globalThis.esriConfig?.has?{...globalThis.dojoConfig?.has,...globalThis.esriConfig?.has}:{},f.add=(t,e,n,r)=>((r||void 0===c[t])&&(c[t]=e),n&&f(t)),f.cache=c,f.add("big-integer-warning-enabled",!0),f.add("esri-deprecation-warnings",!0),f.add("esri-tests-disable-screenshots",!1),f.add("esri-tests-use-full-window",!1),f.add("esri-tests-post-to-influx",!0),f.add("esri-cim-animations-enable-status","enabled"),f.add("esri-cim-animations-spotlight",!1),f.add("esri-cim-animations-freeze-time",!1),(()=>{f.add("host-webworker",void 0!==globalThis.WorkerGlobalScope&&self instanceof globalThis.WorkerGlobalScope);const t="undefined"!=typeof window&&"undefined"!=typeof location&&"undefined"!=typeof document&&window.location===location&&window.document===document;if(f.add("host-browser",t),f.add("host-node","object"==typeof globalThis.process&&globalThis.process.versions?.node&&globalThis.process.versions.v8),f.add("dom",t),f("host-browser")){const t=navigator,e=t.userAgent,n=t.appVersion,r=parseFloat(n);if(f.add("wp",parseFloat(e.split("Windows Phone")[1])||void 0),f.add("msapp",parseFloat(e.split("MSAppHost/")[1])||void 0),f.add("khtml",n.includes("Konqueror")?r:void 0),f.add("edge",parseFloat(e.split("Edge/")[1])||void 0),f.add("opr",parseFloat(e.split("OPR/")[1])||void 0),f.add("webkit",!f("wp")&&!f("edge")&&parseFloat(e.split("WebKit/")[1])||void 0),f.add("chrome",!f("edge")&&!f("opr")&&parseFloat(e.split("Chrome/")[1])||void 0),f.add("android",!f("wp")&&parseFloat(e.split("Android ")[1])||void 0),f.add("safari",!n.includes("Safari")||f("wp")||f("chrome")||f("android")||f("edge")||f("opr")?void 0:parseFloat(n.split("Version/")[1])),f.add("mac",n.includes("Macintosh")),!f("wp")&&/(iPhone|iPod|iPad)/.test(e)){const t=RegExp.$1.replace(/P/,"p"),n=/OS ([\d_]+)/.test(e)?RegExp.$1:"1",r=parseFloat(n.replace(/_/,".").replaceAll("_",""));f.add(t,r),f.add("ios",r)}f("webkit")||(!e.includes("Gecko")||f("wp")||f("khtml")||f("edge")||f.add("mozilla",r),f("mozilla")&&f.add("ff",parseFloat(e.split("Firefox/")[1]||e.split("Minefield/")[1])||void 0))}})(),(()=>{if(globalThis.navigator){const t=navigator.userAgent,e=/Android|webOS|iPhone|iPad|iPod|BlackBerry|Opera Mini|IEMobile/i.test(t),n=/iPhone/i.test(t);e&&f.add("esri-mobile",e),n&&f.add("esri-iPhone",n),f.add("esri-geolocation",!!navigator.geolocation)}f.add("esri-wasm","WebAssembly"in globalThis),f.add("esri-performance-mode-frames-between-render",20),f.add("esri-force-performance-mode",!1),f.add("esri-shared-array-buffer",(()=>{const t="SharedArrayBuffer"in globalThis,e=!1===globalThis.crossOriginIsolated;return t&&!e})),f.add("wasm-simd",(()=>WebAssembly.validate(new Uint8Array([0,97,115,109,1,0,0,0,1,5,1,96,0,1,123,3,2,1,0,10,10,1,8,0,65,0,253,15,253,98,11])))),f.add("esri-atomics","Atomics"in globalThis),f.add("esri-workers","Worker"in globalThis),f.add("web-feat:cache","caches"in globalThis),f.add("esri-workers-arraybuffer-transfer",!f("safari")||Number(f("safari"))>=12),f.add("workers-pool-size",8),f.add("featurelayer-simplify-thresholds",[.5,.5,.5,.5]),f.add("featurelayer-simplify-payload-size-factors",[1,1,4]),f.add("featurelayer-fast-triangulation-enabled",!0),f.add("featurelayer-animation-enabled",!0),f.add("featurelayer-snapshot-enabled",!0),f.add("featurelayer-snapshot-point-min-threshold",8e4),f.add("featurelayer-snapshot-point-max-threshold",4e5),f.add("featurelayer-snapshot-point-coverage",.1),f.add("featurelayer-query-max-depth",4),f.add("featurelayer-query-pausing-enabled",!1),f.add("featurelayer-advanced-symbols",!1),f.add("featurelayer-pbf",!0),f.add("featurelayer-pbf-statistics",!1),f.add("feature-layers-workers",!0),f.add("feature-polyline-generalization-factor",1),f.add("mapview-transitions-duration",200),f.add("mapview-essential-goto-duration",200),f.add("mapview-srswitch-adjust-rotation-scale-threshold",24e6),f.add("mapserver-pbf-version-support",10.81),f.add("mapservice-popup-identify-max-tolerance",20),f("host-webworker")||f("host-browser")&&(f.add("esri-csp-restrictions",(()=>{try{new Function}catch{return!0}return!1})),f.add("esri-image-decode",(()=>{if("decode"in new Image){const t=new Image;return t.src='data:image/svg+xml;charset=UTF-8,<svg version="1.1" xmlns="http://www.w3.org/2000/svg"></svg>',void t.decode().then((()=>{f.add("esri-image-decode",!0,!0,!0)})).catch((()=>{f.add("esri-image-decode",!1,!0,!0)}))}return!1})),f.add("esri-url-encodes-apostrophe",(()=>{const t=window.document.createElement("a");return t.href="?'",t.href.includes("?%27")})))})();const p={apiKey:void 0,applicationName:"",applicationUrl:globalThis.location?.href,assetsPath:"",fontsUrl:"https://static.arcgis.com/fonts",geometryServiceUrl:"https://utility.arcgisonline.com/arcgis/rest/services/Geometry/GeometryServer",geoRSSServiceUrl:"https://utility.arcgis.com/sharing/rss",kmlServiceUrl:"https://utility.arcgis.com/sharing/kml",userPrivilegesApplied:!0,portalUrl:"https://www.arcgis.com",respectPrefersReducedMotion:!0,routeServiceUrl:"https://route-api.arcgis.com/arcgis/rest/services/World/Route/NAServer/Route_World",workers:{loaderConfig:{has:{},paths:{},map:{},packages:[]}},request:{crossOriginNoCorsDomains:null,httpsDomains:["arcgis.com","arcgisonline.com","esrikr.com","premiumservices.blackbridge.com","esripremium.accuweather.com","gbm.digitalglobe.com","firstlook.digitalglobe.com","msi.digitalglobe.com"],interceptors:[],internalInterceptors:[],maxUrlLength:2e3,priority:"high",proxyRules:[],proxyUrl:null,timeout:6e4,trustedServers:[],useIdentity:!0},log:{interceptors:[],level:null}};globalThis.esriConfig&&(function(t,e,n=!1){d(p,e,n)}(0,globalThis.esriConfig,!0),delete p.has),p.assetsPath||(p.assetsPath="https://cdn.jsdelivr.net/npm/@arcgis/core@4.31.0-next.20240821/assets",p.defaultAssetsPath=p.assetsPath);const m={info:0,warn:1,error:2,none:3};class g{constructor(t){this.level=null,this._module="",this._parent=null,this.writer=null,this._loggedMessages={error:new Map,warn:new Map,info:new Map},null!=t.level&&(this.level=t.level),null!=t.writer&&(this.writer=t.writer),this._module=t.module,g._loggers.set(this.module,this);const e=this.module.lastIndexOf(".");-1!==e&&(this._parent=g.getLogger(this.module.slice(0,e)))}get module(){return this._module}get parent(){return this._parent}error(...t){this._log("error","always",...t)}warn(...t){this._log("warn","always",...t)}info(...t){this._log("info","always",...t)}errorOnce(...t){this._log("error","once",...t)}warnOnce(...t){this._log("warn","once",...t)}infoOnce(...t){this._log("info","once",...t)}errorOncePerTick(...t){this._log("error","oncePerTick",...t)}warnOncePerTick(...t){this._log("warn","oncePerTick",...t)}infoOncePerTick(...t){this._log("info","oncePerTick",...t)}get test(){}static get test(){}static getLogger(t){return g._loggers.get(t="string"!=typeof t?t.declaredClass:t)||new g({module:t})}_log(t,e,...n){if(this._matchLevel(t)){if("always"!==e&&!g._throttlingDisabled){const r=function(...t){return function(t){let e=0;for(let n=0;n<t.length;n++)e=(e<<5)-e+t.charCodeAt(n),e|=0;return e}(JSON.stringify(t,((t,e)=>"object"!=typeof e||Array.isArray(e)?e:"[Object]")))}(n),i=this._loggedMessages[t].get(r);if("once"===e&&null!=i||"oncePerTick"===e&&i&&i>=g._tickCounter)return;this._loggedMessages[t].set(r,g._tickCounter),g._scheduleTickCounterIncrement()}for(const e of p.log.interceptors)if(e(t,this.module,...n))return;this._inheritedWriter()(t,this.module,...n)}}_parentWithMember(t,e){let n=this;for(;null!=n;){const e=n[t];if(null!=e)return e;n=n.parent}return e}_inheritedWriter(){return this._parentWithMember("writer",v)}_matchLevel(t){return m[this._parentWithMember("level",p.log.level||"warn")]<=m[t]}static _scheduleTickCounterIncrement(){g._tickCounterScheduled||(g._tickCounterScheduled=!0,Promise.resolve().then((()=>{g._tickCounter++,g._tickCounterScheduled=!1})))}}function v(t,e,...n){console[t](`[${e}]`,...n)}g._loggers=new Map,g._tickCounter=0,g._tickCounterScheduled=!1,g._throttlingDisabled=!1;class w{constructor(t,e,n){this.name=t,this.details=n,this.message=(e&&function(t,e){return t.replaceAll(/\$\{([^\s:}]*)(?::([^\s:}]+))?\}/g,((t,n)=>{if(""===n)return"$";const r=function(t,e){if(null!=e)return e[t]||function(t,e,n){let r=n;for(const e of t){if(null==r)return;if(!(e in r))return void 0;r=r[e]}return r}(t.split("."),0,e)}(n,e);return(r??"").toString()}))}(e,n))??""}toString(){return"["+this.name+"]: "+this.message}}class y extends w{constructor(t,e,n){super(t,e,n)}toJSON(){if(null!=this.details)try{return{name:this.name,message:this.message,details:JSON.parse(JSON.stringify(this.details,((t,e)=>{if(e&&"object"==typeof e&&"function"==typeof e.toJSON)return e;try{return h(e)}catch(t){return"[object]"}})))}}catch(t){throw g.getLogger("esri.core.Error").error(t),t}return{name:this.name,message:this.message,details:this.details}}static fromJSON(t){return new y(t.name,t.message,t.details)}}y.prototype.type="error";const b={transparent:[0,0,0,0],black:[0,0,0,1],silver:[192,192,192,1],gray:[128,128,128,1],white:[255,255,255,1],maroon:[128,0,0,1],red:[255,0,0,1],purple:[128,0,128,1],fuchsia:[255,0,255,1],green:[0,128,0,1],lime:[0,255,0,1],olive:[128,128,0,1],yellow:[255,255,0,1],navy:[0,0,128,1],blue:[0,0,255,1],teal:[0,128,128,1],aqua:[0,255,255,1],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],blanchedalmond:[255,235,205,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],oldlace:[253,245,230,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],rebeccapurple:[102,51,153,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],whitesmoke:[245,245,245,1],yellowgreen:[154,205,50,1]};function M(t){return b[t]??b[t.toLowerCase()]}function x(t,e,n){n<0&&++n,n>1&&--n;const r=6*n;return r<1?t+(e-t)*r:2*n<1?e:3*n<2?t+(e-t)*(2/3-n)*6:t}function k(){const t=new Float32Array(16);return t[0]=1,t[5]=1,t[10]=1,t[15]=1,t}const T=k();function E(t,e,n){return[t,e,n]}function _(){return E(1,1,1)}function S(){return E(1,0,0)}function F(){return E(0,1,0)}function A(){return E(0,0,1)}Object.freeze(Object.defineProperty({__proto__:null,IDENTITY:T,clone:function(t){const e=new Float32Array(16);return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e},create:k,createView:function(t,e){return new Float32Array(t,e,16)},fromValues:function(t,e,n,r,i,o,a,s,u,l,c,f,h,d,p,m){const g=new Float32Array(16);return g[0]=t,g[1]=e,g[2]=n,g[3]=r,g[4]=i,g[5]=o,g[6]=a,g[7]=s,g[8]=u,g[9]=l,g[10]=c,g[11]=f,g[12]=h,g[13]=d,g[14]=p,g[15]=m,g}},Symbol.toStringTag,{value:"Module"}));const I=_(),O=S(),j=F(),$=A();Object.freeze(Object.defineProperty({__proto__:null,ONES:I,UNIT_X:O,UNIT_Y:j,UNIT_Z:$,ZEROS:[0,0,0],clone:function(t){return[t[0],t[1],t[2]]},create:function(){return[0,0,0]},createView:function(t,e){return new Float64Array(t,e,3)},fromArray:function(t,e=[0,0,0]){const n=Math.min(3,t.length);for(let r=0;r<n;++r)e[r]=t[r];return e},fromValues:E,ones:_,unitX:S,unitY:F,unitZ:A,zeros:function(){return[0,0,0]}},Symbol.toStringTag,{value:"Module"}));let N=1e-6;function P(){return N}const R=Math.random,q=Math.PI/180,U=180/Math.PI;function C(t,e,n,r,i,o,a,s,u,l,c,f,h,d,p,m,g){return t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=o,t[5]=a,t[6]=s,t[7]=u,t[8]=l,t[9]=c,t[10]=f,t[11]=h,t[12]=d,t[13]=p,t[14]=m,t[15]=g,t}function D(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}function z(t,e){if(t===e){const n=e[1],r=e[2],i=e[3],o=e[6],a=e[7],s=e[11];t[1]=e[4],t[2]=e[8],t[3]=e[12],t[4]=n,t[6]=e[9],t[7]=e[13],t[8]=r,t[9]=o,t[11]=e[14],t[12]=i,t[13]=a,t[14]=s}else t[0]=e[0],t[1]=e[4],t[2]=e[8],t[3]=e[12],t[4]=e[1],t[5]=e[5],t[6]=e[9],t[7]=e[13],t[8]=e[2],t[9]=e[6],t[10]=e[10],t[11]=e[14],t[12]=e[3],t[13]=e[7],t[14]=e[11],t[15]=e[15];return t}function W(t,e){const n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],l=e[7],c=e[8],f=e[9],h=e[10],d=e[11],p=e[12],m=e[13],g=e[14],v=e[15],w=n*s-r*a,y=n*u-i*a,b=n*l-o*a,M=r*u-i*s,x=r*l-o*s,k=i*l-o*u,T=c*m-f*p,E=c*g-h*p,_=c*v-d*p,S=f*g-h*m,F=f*v-d*m,A=h*v-d*g;let I=w*A-y*F+b*S+M*_-x*E+k*T;return I?(I=1/I,t[0]=(s*A-u*F+l*S)*I,t[1]=(i*F-r*A-o*S)*I,t[2]=(m*k-g*x+v*M)*I,t[3]=(h*x-f*k-d*M)*I,t[4]=(u*_-a*A-l*E)*I,t[5]=(n*A-i*_+o*E)*I,t[6]=(g*b-p*k-v*y)*I,t[7]=(c*k-h*b+d*y)*I,t[8]=(a*F-s*_+l*T)*I,t[9]=(r*_-n*F-o*T)*I,t[10]=(p*x-m*b+v*w)*I,t[11]=(f*b-c*x-d*w)*I,t[12]=(s*E-a*S-u*T)*I,t[13]=(n*S-r*E+i*T)*I,t[14]=(m*y-p*M-g*w)*I,t[15]=(c*M-f*y+h*w)*I,t):null}function J(t,e,n){const r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],l=e[6],c=e[7],f=e[8],h=e[9],d=e[10],p=e[11],m=e[12],g=e[13],v=e[14],w=e[15];let y=n[0],b=n[1],M=n[2],x=n[3];return t[0]=y*r+b*s+M*f+x*m,t[1]=y*i+b*u+M*h+x*g,t[2]=y*o+b*l+M*d+x*v,t[3]=y*a+b*c+M*p+x*w,y=n[4],b=n[5],M=n[6],x=n[7],t[4]=y*r+b*s+M*f+x*m,t[5]=y*i+b*u+M*h+x*g,t[6]=y*o+b*l+M*d+x*v,t[7]=y*a+b*c+M*p+x*w,y=n[8],b=n[9],M=n[10],x=n[11],t[8]=y*r+b*s+M*f+x*m,t[9]=y*i+b*u+M*h+x*g,t[10]=y*o+b*l+M*d+x*v,t[11]=y*a+b*c+M*p+x*w,y=n[12],b=n[13],M=n[14],x=n[15],t[12]=y*r+b*s+M*f+x*m,t[13]=y*i+b*u+M*h+x*g,t[14]=y*o+b*l+M*d+x*v,t[15]=y*a+b*c+M*p+x*w,t}function L(t,e,n){const r=e[0],i=e[1],o=e[2],a=e[3],s=r+r,u=i+i,l=o+o,c=r*s,f=r*u,h=r*l,d=i*u,p=i*l,m=o*l,g=a*s,v=a*u,w=a*l;return t[0]=1-(d+m),t[1]=f+w,t[2]=h-v,t[3]=0,t[4]=f-w,t[5]=1-(c+m),t[6]=p+g,t[7]=0,t[8]=h+v,t[9]=p-g,t[10]=1-(c+d),t[11]=0,t[12]=n[0],t[13]=n[1],t[14]=n[2],t[15]=1,t}Object.freeze(Object.defineProperty({__proto__:null,RANDOM:R,equals:function(t,e){return Math.abs(t-e)<=N*Math.max(1,Math.abs(t),Math.abs(e))},getEpsilon:P,setEpsilon:function(t){N=t},toDegree:function(t){return t*U},toRadian:function(t){return t*q}},Symbol.toStringTag,{value:"Module"}));const V=[0,0,0];function B(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t[2]=e[2]-n[2],t[3]=e[3]-n[3],t[4]=e[4]-n[4],t[5]=e[5]-n[5],t[6]=e[6]-n[6],t[7]=e[7]-n[7],t[8]=e[8]-n[8],t[9]=e[9]-n[9],t[10]=e[10]-n[10],t[11]=e[11]-n[11],t[12]=e[12]-n[12],t[13]=e[13]-n[13],t[14]=e[14]-n[14],t[15]=e[15]-n[15],t}Object.freeze(Object.defineProperty({__proto__:null,add:function(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t[2]=e[2]+n[2],t[3]=e[3]+n[3],t[4]=e[4]+n[4],t[5]=e[5]+n[5],t[6]=e[6]+n[6],t[7]=e[7]+n[7],t[8]=e[8]+n[8],t[9]=e[9]+n[9],t[10]=e[10]+n[10],t[11]=e[11]+n[11],t[12]=e[12]+n[12],t[13]=e[13]+n[13],t[14]=e[14]+n[14],t[15]=e[15]+n[15],t},adjoint:function(t,e){const n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],l=e[7],c=e[8],f=e[9],h=e[10],d=e[11],p=e[12],m=e[13],g=e[14],v=e[15];return t[0]=s*(h*v-d*g)-f*(u*v-l*g)+m*(u*d-l*h),t[1]=-(r*(h*v-d*g)-f*(i*v-o*g)+m*(i*d-o*h)),t[2]=r*(u*v-l*g)-s*(i*v-o*g)+m*(i*l-o*u),t[3]=-(r*(u*d-l*h)-s*(i*d-o*h)+f*(i*l-o*u)),t[4]=-(a*(h*v-d*g)-c*(u*v-l*g)+p*(u*d-l*h)),t[5]=n*(h*v-d*g)-c*(i*v-o*g)+p*(i*d-o*h),t[6]=-(n*(u*v-l*g)-a*(i*v-o*g)+p*(i*l-o*u)),t[7]=n*(u*d-l*h)-a*(i*d-o*h)+c*(i*l-o*u),t[8]=a*(f*v-d*m)-c*(s*v-l*m)+p*(s*d-l*f),t[9]=-(n*(f*v-d*m)-c*(r*v-o*m)+p*(r*d-o*f)),t[10]=n*(s*v-l*m)-a*(r*v-o*m)+p*(r*l-o*s),t[11]=-(n*(s*d-l*f)-a*(r*d-o*f)+c*(r*l-o*s)),t[12]=-(a*(f*g-h*m)-c*(s*g-u*m)+p*(s*h-u*f)),t[13]=n*(f*g-h*m)-c*(r*g-i*m)+p*(r*h-i*f),t[14]=-(n*(s*g-u*m)-a*(r*g-i*m)+p*(r*u-i*s)),t[15]=n*(s*h-u*f)-a*(r*h-i*f)+c*(r*u-i*s),t},copy:function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t},determinant:function(t){const e=t[0],n=t[1],r=t[2],i=t[3],o=t[4],a=t[5],s=t[6],u=t[7],l=t[8],c=t[9],f=t[10],h=t[11],d=t[12],p=t[13],m=t[14],g=t[15];return(e*a-n*o)*(f*g-h*m)-(e*s-r*o)*(c*g-h*p)+(e*u-i*o)*(c*m-f*p)+(n*s-r*a)*(l*g-h*d)-(n*u-i*a)*(l*m-f*d)+(r*u-i*s)*(l*p-c*d)},equals:function(t,e){if(t===e)return!0;const n=t[0],r=t[1],i=t[2],o=t[3],a=t[4],s=t[5],u=t[6],l=t[7],c=t[8],f=t[9],h=t[10],d=t[11],p=t[12],m=t[13],g=t[14],v=t[15],w=e[0],y=e[1],b=e[2],M=e[3],x=e[4],k=e[5],T=e[6],E=e[7],_=e[8],S=e[9],F=e[10],A=e[11],I=e[12],O=e[13],j=e[14],$=e[15],N=P();return Math.abs(n-w)<=N*Math.max(1,Math.abs(n),Math.abs(w))&&Math.abs(r-y)<=N*Math.max(1,Math.abs(r),Math.abs(y))&&Math.abs(i-b)<=N*Math.max(1,Math.abs(i),Math.abs(b))&&Math.abs(o-M)<=N*Math.max(1,Math.abs(o),Math.abs(M))&&Math.abs(a-x)<=N*Math.max(1,Math.abs(a),Math.abs(x))&&Math.abs(s-k)<=N*Math.max(1,Math.abs(s),Math.abs(k))&&Math.abs(u-T)<=N*Math.max(1,Math.abs(u),Math.abs(T))&&Math.abs(l-E)<=N*Math.max(1,Math.abs(l),Math.abs(E))&&Math.abs(c-_)<=N*Math.max(1,Math.abs(c),Math.abs(_))&&Math.abs(f-S)<=N*Math.max(1,Math.abs(f),Math.abs(S))&&Math.abs(h-F)<=N*Math.max(1,Math.abs(h),Math.abs(F))&&Math.abs(d-A)<=N*Math.max(1,Math.abs(d),Math.abs(A))&&Math.abs(p-I)<=N*Math.max(1,Math.abs(p),Math.abs(I))&&Math.abs(m-O)<=N*Math.max(1,Math.abs(m),Math.abs(O))&&Math.abs(g-j)<=N*Math.max(1,Math.abs(g),Math.abs(j))&&Math.abs(v-$)<=N*Math.max(1,Math.abs(v),Math.abs($))},exactEquals:function(t,e){return t[0]===e[0]&&t[1]===e[1]&&t[2]===e[2]&&t[3]===e[3]&&t[4]===e[4]&&t[5]===e[5]&&t[6]===e[6]&&t[7]===e[7]&&t[8]===e[8]&&t[9]===e[9]&&t[10]===e[10]&&t[11]===e[11]&&t[12]===e[12]&&t[13]===e[13]&&t[14]===e[14]&&t[15]===e[15]},frob:function(t){return Math.sqrt(t[0]**2+t[1]**2+t[2]**2+t[3]**2+t[4]**2+t[5]**2+t[6]**2+t[7]**2+t[8]**2+t[9]**2+t[10]**2+t[11]**2+t[12]**2+t[13]**2+t[14]**2+t[15]**2)},fromQuat:function(t,e){const n=e[0],r=e[1],i=e[2],o=e[3],a=n+n,s=r+r,u=i+i,l=n*a,c=r*a,f=r*s,h=i*a,d=i*s,p=i*u,m=o*a,g=o*s,v=o*u;return t[0]=1-f-p,t[1]=c+v,t[2]=h-g,t[3]=0,t[4]=c-v,t[5]=1-l-p,t[6]=d+m,t[7]=0,t[8]=h+g,t[9]=d-m,t[10]=1-l-f,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t},fromQuat2:function(t,e){const n=V,r=-e[0],i=-e[1],o=-e[2],a=e[3],s=e[4],u=e[5],l=e[6],c=e[7],f=r*r+i*i+o*o+a*a;return f>0?(n[0]=2*(s*a+c*r+u*o-l*i)/f,n[1]=2*(u*a+c*i+l*r-s*o)/f,n[2]=2*(l*a+c*o+s*i-u*r)/f):(n[0]=2*(s*a+c*r+u*o-l*i),n[1]=2*(u*a+c*i+l*r-s*o),n[2]=2*(l*a+c*o+s*i-u*r)),L(t,e,n),t},fromRotation:function(t,e,n){if(0===e)return D(t);let r,i,o,a=n[0],s=n[1],u=n[2],l=Math.sqrt(a*a+s*s+u*u);return l<P()?null:(l=1/l,a*=l,s*=l,u*=l,r=Math.sin(e),i=Math.cos(e),o=1-i,t[0]=a*a*o+i,t[1]=s*a*o+u*r,t[2]=u*a*o-s*r,t[3]=0,t[4]=a*s*o-u*r,t[5]=s*s*o+i,t[6]=u*s*o+a*r,t[7]=0,t[8]=a*u*o+s*r,t[9]=s*u*o-a*r,t[10]=u*u*o+i,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t)},fromRotationTranslation:L,fromRotationTranslationScale:function(t,e,n,r){const i=e[0],o=e[1],a=e[2],s=e[3],u=i+i,l=o+o,c=a+a,f=i*u,h=i*l,d=i*c,p=o*l,m=o*c,g=a*c,v=s*u,w=s*l,y=s*c,b=r[0],M=r[1],x=r[2];return t[0]=(1-(p+g))*b,t[1]=(h+y)*b,t[2]=(d-w)*b,t[3]=0,t[4]=(h-y)*M,t[5]=(1-(f+g))*M,t[6]=(m+v)*M,t[7]=0,t[8]=(d+w)*x,t[9]=(m-v)*x,t[10]=(1-(f+p))*x,t[11]=0,t[12]=n[0],t[13]=n[1],t[14]=n[2],t[15]=1,t},fromRotationTranslationScaleOrigin:function(t,e,n,r,i){const o=e[0],a=e[1],s=e[2],u=e[3],l=o+o,c=a+a,f=s+s,h=o*l,d=o*c,p=o*f,m=a*c,g=a*f,v=s*f,w=u*l,y=u*c,b=u*f,M=r[0],x=r[1],k=r[2],T=i[0],E=i[1],_=i[2],S=(1-(m+v))*M,F=(d+b)*M,A=(p-y)*M,I=(d-b)*x,O=(1-(h+v))*x,j=(g+w)*x,$=(p+y)*k,N=(g-w)*k,P=(1-(h+m))*k;return t[0]=S,t[1]=F,t[2]=A,t[3]=0,t[4]=I,t[5]=O,t[6]=j,t[7]=0,t[8]=$,t[9]=N,t[10]=P,t[11]=0,t[12]=n[0]+T-(S*T+I*E+$*_),t[13]=n[1]+E-(F*T+O*E+N*_),t[14]=n[2]+_-(A*T+j*E+P*_),t[15]=1,t},fromScaling:function(t,e){return t[0]=e[0],t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=e[1],t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=e[2],t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t},fromTranslation:function(t,e){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=e[0],t[13]=e[1],t[14]=e[2],t[15]=1,t},fromXRotation:function(t,e){const n=Math.sin(e),r=Math.cos(e);return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=r,t[6]=n,t[7]=0,t[8]=0,t[9]=-n,t[10]=r,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t},fromYRotation:function(t,e){const n=Math.sin(e),r=Math.cos(e);return t[0]=r,t[1]=0,t[2]=-n,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=n,t[9]=0,t[10]=r,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t},fromZRotation:function(t,e){const n=Math.sin(e),r=Math.cos(e);return t[0]=r,t[1]=n,t[2]=0,t[3]=0,t[4]=-n,t[5]=r,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t},frustum:function(t,e,n,r,i,o,a){const s=1/(n-e),u=1/(i-r),l=1/(o-a);return t[0]=2*o*s,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=2*o*u,t[6]=0,t[7]=0,t[8]=(n+e)*s,t[9]=(i+r)*u,t[10]=(a+o)*l,t[11]=-1,t[12]=0,t[13]=0,t[14]=a*o*2*l,t[15]=0,t},getRotation:function(t,e){const n=e[0]+e[5]+e[10];let r=0;return n>0?(r=2*Math.sqrt(n+1),t[3]=.25*r,t[0]=(e[6]-e[9])/r,t[1]=(e[8]-e[2])/r,t[2]=(e[1]-e[4])/r):e[0]>e[5]&&e[0]>e[10]?(r=2*Math.sqrt(1+e[0]-e[5]-e[10]),t[3]=(e[6]-e[9])/r,t[0]=.25*r,t[1]=(e[1]+e[4])/r,t[2]=(e[8]+e[2])/r):e[5]>e[10]?(r=2*Math.sqrt(1+e[5]-e[0]-e[10]),t[3]=(e[8]-e[2])/r,t[0]=(e[1]+e[4])/r,t[1]=.25*r,t[2]=(e[6]+e[9])/r):(r=2*Math.sqrt(1+e[10]-e[0]-e[5]),t[3]=(e[1]-e[4])/r,t[0]=(e[8]+e[2])/r,t[1]=(e[6]+e[9])/r,t[2]=.25*r),t},getScaling:function(t,e){const n=e[0],r=e[1],i=e[2],o=e[4],a=e[5],s=e[6],u=e[8],l=e[9],c=e[10];return t[0]=Math.sqrt(n*n+r*r+i*i),t[1]=Math.sqrt(o*o+a*a+s*s),t[2]=Math.sqrt(u*u+l*l+c*c),t},getTranslation:function(t,e){return t[0]=e[12],t[1]=e[13],t[2]=e[14],t},hasIdentityRotation:function(t){return 1===t[0]&&0===t[1]&&0===t[2]&&0===t[4]&&1===t[5]&&0===t[6]&&0===t[8]&&0===t[9]&&1===t[10]},identity:D,invert:W,invertOrIdentity:function(t,e){return W(t,e)||D(t),t},isOrthoNormal:function(t){const e=P(),n=t[0],r=t[1],i=t[2],o=t[4],a=t[5],s=t[6],u=t[8],l=t[9],c=t[10];return Math.abs(1-(n*n+o*o+u*u))<=e&&Math.abs(1-(r*r+a*a+l*l))<=e&&Math.abs(1-(i*i+s*s+c*c))<=e},lookAt:function(t,e,n,r){const i=e[0],o=e[1],a=e[2];let s=i-n[0],u=o-n[1],l=a-n[2];const c=P();if(Math.abs(s)<c&&Math.abs(u)<c&&Math.abs(l)<c)return void D(t);let f=1/Math.sqrt(s*s+u*u+l*l);s*=f,u*=f,l*=f;const h=r[0],d=r[1],p=r[2];let m=d*l-p*u,g=p*s-h*l,v=h*u-d*s;f=Math.sqrt(m*m+g*g+v*v),f?(f=1/f,m*=f,g*=f,v*=f):(m=0,g=0,v=0);let w=u*v-l*g,y=l*m-s*v,b=s*g-u*m;f=Math.sqrt(w*w+y*y+b*b),f?(f=1/f,w*=f,y*=f,b*=f):(w=0,y=0,b=0),t[0]=m,t[1]=w,t[2]=s,t[3]=0,t[4]=g,t[5]=y,t[6]=u,t[7]=0,t[8]=v,t[9]=b,t[10]=l,t[11]=0,t[12]=-(m*i+g*o+v*a),t[13]=-(w*i+y*o+b*a),t[14]=-(s*i+u*o+l*a),t[15]=1},mul:J,multiply:J,multiplyScalar:function(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n,t[3]=e[3]*n,t[4]=e[4]*n,t[5]=e[5]*n,t[6]=e[6]*n,t[7]=e[7]*n,t[8]=e[8]*n,t[9]=e[9]*n,t[10]=e[10]*n,t[11]=e[11]*n,t[12]=e[12]*n,t[13]=e[13]*n,t[14]=e[14]*n,t[15]=e[15]*n,t},multiplyScalarAndAdd:function(t,e,n,r){return t[0]=e[0]+n[0]*r,t[1]=e[1]+n[1]*r,t[2]=e[2]+n[2]*r,t[3]=e[3]+n[3]*r,t[4]=e[4]+n[4]*r,t[5]=e[5]+n[5]*r,t[6]=e[6]+n[6]*r,t[7]=e[7]+n[7]*r,t[8]=e[8]+n[8]*r,t[9]=e[9]+n[9]*r,t[10]=e[10]+n[10]*r,t[11]=e[11]+n[11]*r,t[12]=e[12]+n[12]*r,t[13]=e[13]+n[13]*r,t[14]=e[14]+n[14]*r,t[15]=e[15]+n[15]*r,t},ortho:function(t,e,n,r,i,o,a){const s=1/(e-n),u=1/(r-i),l=1/(o-a);return t[0]=-2*s,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=-2*u,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=2*l,t[11]=0,t[12]=(e+n)*s,t[13]=(i+r)*u,t[14]=(a+o)*l,t[15]=1,t},perspective:function(t,e,n,r,i){const o=1/Math.tan(e/2);let a;return t[0]=o/n,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=o,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[11]=-1,t[12]=0,t[13]=0,t[15]=0,null!=i&&i!==1/0?(a=1/(r-i),t[10]=(i+r)*a,t[14]=2*i*r*a):(t[10]=-1,t[14]=-2*r),t},perspectiveFromFieldOfView:function(t,e,n,r){const i=Math.tan(e.upDegrees*Math.PI/180),o=Math.tan(e.downDegrees*Math.PI/180),a=Math.tan(e.leftDegrees*Math.PI/180),s=Math.tan(e.rightDegrees*Math.PI/180),u=2/(a+s),l=2/(i+o);return t[0]=u,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=l,t[6]=0,t[7]=0,t[8]=-(a-s)*u*.5,t[9]=(i-o)*l*.5,t[10]=r/(n-r),t[11]=-1,t[12]=0,t[13]=0,t[14]=r*n/(n-r),t[15]=0,t},rotate:function(t,e,n,r){let i,o,a,s,u,l,c,f,h,d,p,m,g,v,w,y,b,M,x,k,T,E,_,S,F=r[0],A=r[1],I=r[2],O=Math.sqrt(F*F+A*A+I*I);return O<P()?null:(O=1/O,F*=O,A*=O,I*=O,i=Math.sin(n),o=Math.cos(n),a=1-o,s=e[0],u=e[1],l=e[2],c=e[3],f=e[4],h=e[5],d=e[6],p=e[7],m=e[8],g=e[9],v=e[10],w=e[11],y=F*F*a+o,b=A*F*a+I*i,M=I*F*a-A*i,x=F*A*a-I*i,k=A*A*a+o,T=I*A*a+F*i,E=F*I*a+A*i,_=A*I*a-F*i,S=I*I*a+o,t[0]=s*y+f*b+m*M,t[1]=u*y+h*b+g*M,t[2]=l*y+d*b+v*M,t[3]=c*y+p*b+w*M,t[4]=s*x+f*k+m*T,t[5]=u*x+h*k+g*T,t[6]=l*x+d*k+v*T,t[7]=c*x+p*k+w*T,t[8]=s*E+f*_+m*S,t[9]=u*E+h*_+g*S,t[10]=l*E+d*_+v*S,t[11]=c*E+p*_+w*S,e!==t&&(t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t)},rotateX:function(t,e,n){const r=Math.sin(n),i=Math.cos(n),o=e[4],a=e[5],s=e[6],u=e[7],l=e[8],c=e[9],f=e[10],h=e[11];return e!==t&&(t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[4]=o*i+l*r,t[5]=a*i+c*r,t[6]=s*i+f*r,t[7]=u*i+h*r,t[8]=l*i-o*r,t[9]=c*i-a*r,t[10]=f*i-s*r,t[11]=h*i-u*r,t},rotateY:function(t,e,n){const r=Math.sin(n),i=Math.cos(n),o=e[0],a=e[1],s=e[2],u=e[3],l=e[8],c=e[9],f=e[10],h=e[11];return e!==t&&(t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[0]=o*i-l*r,t[1]=a*i-c*r,t[2]=s*i-f*r,t[3]=u*i-h*r,t[8]=o*r+l*i,t[9]=a*r+c*i,t[10]=s*r+f*i,t[11]=u*r+h*i,t},rotateZ:function(t,e,n){const r=Math.sin(n),i=Math.cos(n),o=e[0],a=e[1],s=e[2],u=e[3],l=e[4],c=e[5],f=e[6],h=e[7];return e!==t&&(t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15]),t[0]=o*i+l*r,t[1]=a*i+c*r,t[2]=s*i+f*r,t[3]=u*i+h*r,t[4]=l*i-o*r,t[5]=c*i-a*r,t[6]=f*i-s*r,t[7]=h*i-u*r,t},scale:function(t,e,n){const r=n[0],i=n[1],o=n[2];return t[0]=e[0]*r,t[1]=e[1]*r,t[2]=e[2]*r,t[3]=e[3]*r,t[4]=e[4]*i,t[5]=e[5]*i,t[6]=e[6]*i,t[7]=e[7]*i,t[8]=e[8]*o,t[9]=e[9]*o,t[10]=e[10]*o,t[11]=e[11]*o,t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t},set:C,str:function(t){return"mat4("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+", "+t[4]+", "+t[5]+", "+t[6]+", "+t[7]+", "+t[8]+", "+t[9]+", "+t[10]+", "+t[11]+", "+t[12]+", "+t[13]+", "+t[14]+", "+t[15]+")"},sub:B,subtract:B,targetTo:function(t,e,n,r){const i=e[0],o=e[1],a=e[2],s=r[0],u=r[1],l=r[2];let c=i-n[0],f=o-n[1],h=a-n[2],d=c*c+f*f+h*h;d>0&&(d=1/Math.sqrt(d),c*=d,f*=d,h*=d);let p=u*h-l*f,m=l*c-s*h,g=s*f-u*c;return d=p*p+m*m+g*g,d>0&&(d=1/Math.sqrt(d),p*=d,m*=d,g*=d),t[0]=p,t[1]=m,t[2]=g,t[3]=0,t[4]=f*g-h*m,t[5]=h*p-c*g,t[6]=c*m-f*p,t[7]=0,t[8]=c,t[9]=f,t[10]=h,t[11]=0,t[12]=i,t[13]=o,t[14]=a,t[15]=1,t},translate:function(t,e,n){const r=n[0],i=n[1],o=n[2];if(e===t)t[12]=e[0]*r+e[4]*i+e[8]*o+e[12],t[13]=e[1]*r+e[5]*i+e[9]*o+e[13],t[14]=e[2]*r+e[6]*i+e[10]*o+e[14],t[15]=e[3]*r+e[7]*i+e[11]*o+e[15];else{const n=e[0],a=e[1],s=e[2],u=e[3],l=e[4],c=e[5],f=e[6],h=e[7],d=e[8],p=e[9],m=e[10],g=e[11];t[0]=n,t[1]=a,t[2]=s,t[3]=u,t[4]=l,t[5]=c,t[6]=f,t[7]=h,t[8]=d,t[9]=p,t[10]=m,t[11]=g,t[12]=n*r+l*i+d*o+e[12],t[13]=a*r+c*i+p*o+e[13],t[14]=s*r+f*i+m*o+e[14],t[15]=u*r+h*i+g*o+e[15]}return t},transpose:z},Symbol.toStringTag,{value:"Module"}));class Y{constructor(t,e,n){this.strength=t,this.radius=e,this.threshold=n,this.type="bloom"}interpolate(t,e,n){this.strength=Q(t.strength,e.strength,n),this.radius=Q(t.radius,e.radius,n),this.threshold=Q(t.threshold,e.threshold,n)}clone(){return new Y(this.strength,this.radius,this.threshold)}toJSON(){return{type:"bloom",radius:tt(this.radius),strength:this.strength,threshold:this.threshold}}}class Z{constructor(t){this.radius=t,this.type="blur"}interpolate(t,e,n){this.radius=Math.round(Q(t.radius,e.radius,n))}clone(){return new Z(this.radius)}toJSON(){return{type:"blur",radius:tt(this.radius)}}}class X{constructor(t,e){this.type=t,this.amount=e,"invert"!==this.type&&"grayscale"!==this.type&&"sepia"!==this.type||(this.amount=Math.min(this.amount,1))}get colorMatrix(){return this._colorMatrix||this._updateMatrix(),this._colorMatrix}interpolate(t,e,n){this.amount=Q(t.amount,e.amount,n),this._updateMatrix()}clone(){return new X(this.type,this.amount)}toJSON(){return{type:this.type,amount:this.amount}}_updateMatrix(){const t=this._colorMatrix||k();switch(this.type){case"brightness":this._colorMatrix=((t,e)=>{const n=C(t,e,0,0,0,0,e,0,0,0,0,e,0,0,0,0,1);return z(n,n)})(t,this.amount);break;case"contrast":this._colorMatrix=((t,e)=>{const n=C(t,e,0,0,.5-.5*e,0,e,0,.5-.5*e,0,0,e,.5-.5*e,0,0,0,1);return z(n,n)})(t,this.amount);break;case"grayscale":this._colorMatrix=(t=>{const e=1-this.amount,n=C(t,.2126+.7874*e,.7152-.7152*e,.0722-.0722*e,0,.2126-.2126*e,.7152+.2848*e,.0722-.0722*e,0,.2126-.2126*e,.7152-.7152*e,.0722+.9278*e,0,0,0,0,1);return z(n,n)})(t);break;case"invert":this._colorMatrix=((t,e)=>{const n=1-2*e,r=C(t,n,0,0,e,0,n,0,e,0,0,n,e,0,0,0,1);return z(r,r)})(t,this.amount);break;case"saturate":this._colorMatrix=((t,e)=>{const n=C(t,.213+.787*e,.715-.715*e,.072-.072*e,0,.213-.213*e,.715+.285*e,.072-.072*e,0,.213-.213*e,.715-.715*e,.072+.928*e,0,0,0,0,1);return z(n,n)})(t,this.amount);break;case"sepia":this._colorMatrix=(t=>{const e=1-this.amount,n=C(t,.393+.607*e,.769-.769*e,.189-.189*e,0,.349-.349*e,.686+.314*e,.168-.168*e,0,.272-.272*e,.534-.534*e,.131+.869*e,0,0,0,0,1);return z(n,n)})(t)}}}class G{constructor(t,e,n,r){this.offsetX=t,this.offsetY=e,this.blurRadius=n,this.color=r,this.type="drop-shadow"}interpolate(t,e,n){this.offsetX=Q(t.offsetX,e.offsetX,n),this.offsetY=Q(t.offsetY,e.offsetY,n),this.blurRadius=Q(t.blurRadius,e.blurRadius,n),this.color[0]=Math.round(Q(t.color[0],e.color[0],n)),this.color[1]=Math.round(Q(t.color[1],e.color[1],n)),this.color[2]=Math.round(Q(t.color[2],e.color[2],n)),this.color[3]=Q(t.color[3],e.color[3],n)}clone(){return new G(this.offsetX,this.offsetY,this.blurRadius,[...this.color])}toJSON(){const t=[...this.color];return t[3]*=255,{type:"drop-shadow",xoffset:tt(this.offsetX),yoffset:tt(this.offsetY),blurRadius:tt(this.blurRadius),color:t}}}class H{constructor(t){this.angle=t,this.type="hue-rotate"}get colorMatrix(){return this._colorMatrix||this._updateMatrix(),this._colorMatrix}interpolate(t,e,n){this.angle=Q(t.angle,e.angle,n),this._updateMatrix()}clone(){return new H(this.angle)}toJSON(){return{type:"hue-rotate",angle:this.angle}}_updateMatrix(){const t=this._colorMatrix||k();this._colorMatrix=((t,e)=>{const n=Math.sin(e*Math.PI/180),r=Math.cos(e*Math.PI/180),i=C(t,.213+.787*r-.213*n,.715-.715*r-.715*n,.072-.072*r+.928*n,0,.213-.213*r+.143*n,.715+.285*r+.14*n,.072-.072*r-.283*n,0,.213-.213*r-.787*n,.715-.715*r+.715*n,.072+.928*r+.072*n,0,0,0,0,1);return z(i,i)})(t,this.angle)}}class K{constructor(t){this.amount=t,this.type="opacity",this.amount=Math.min(this.amount,1)}interpolate(t,e,n){this.amount=Q(t.amount,e.amount,n)}clone(){return new K(this.amount)}toJSON(){return{type:"opacity",amount:this.amount}}}function Q(t,e,n){return t+(e-t)*n}function tt(t){return Math.round(1e3*((e=t)?72*e/96:0))/1e3;var e}function et(t){switch(t.type){case"grayscale":case"sepia":case"invert":return new X(t.type,0);case"saturate":case"brightness":case"contrast":return new X(t.type,1);case"opacity":return new K(1);case"hue-rotate":return new H(0);case"blur":return new Z(0);case"drop-shadow":return new G(0,0,0,[...M("transparent")]);case"bloom":return new Y(0,0,1)}}function nt(t,e){const n=t.length>e.length?t:e;return(t.length>e.length?e:t).every(((t,e)=>t.type===n[e].type))}function rt(t,e){const n=t.length>e.length?t:e,r=t.length>e.length?e:t;for(let t=r.length;t<n.length;t++)r.push(et(n[t]))}function it(t,e,n,r){var i=Error.call(this,t);return Object.setPrototypeOf&&Object.setPrototypeOf(i,it.prototype),i.expected=e,i.found=n,i.location=r,i.name="SyntaxError",i}function ot(t,e,n){return n=n||" ",t.length>e?t:t+(n+=n.repeat(e-=t.length)).slice(0,e)}function at(t){if(!t||0===t.length)return null;if("string"==typeof t){const e=st(t);return e&&0!==e.length?e:null}const e=t.map((t=>{if(!Number.isFinite(t.scale)||t.scale<=0)throw new y("effect:invalid-scale","scale must be finite and greater than 0",{stop:t});return{scale:t.scale,effects:st(t.value)}}));e.sort(((t,e)=>e.effects.length-t.effects.length));for(let t=0;t<e.length-1;t++){if(!nt(e[t].effects,e[t+1].effects))throw new y("effect:interpolation-impossible","Cannot interpolate by scale between 2 lists of mixed effects",{a:e[t].effects,b:e[t+1].effects});rt(e[t].effects,e[t+1].effects)}return e.sort(((t,e)=>e.scale-t.scale)),e}function st(t){let e;if(!t)return[];try{e=function(t,e){var n,r={},i=(e=void 0!==e?e:{}).grammarSource,o={start:Lt},a=Lt,s="none",u=")",l=",",c="(",f="%",h="px",d="cm",p="mm",m="in",g="pt",v="pc",w="deg",y="rad",b="grad",M="turn",x="#",k=".",T="e",E=/^[ \t\n\r]/,_=/^[a-z\-]/,S=/^[0-9a-fA-F]/,F=/^[+\-]/,A=/^[0-9]/,I=zt("none"),O=Ct("none",!1),j=Ct(")",!1),$=Ct(",",!1),N=zt("whitespace"),P=Dt([" ","\t","\n","\r"],!1,!1),R=zt("function"),q=Ct("(",!1),U=zt("identifier"),C=Dt([["a","z"],"-"],!1,!1),D=zt("percentage"),z=Ct("%",!1),W=zt("length"),J=Ct("px",!1),L=Ct("cm",!1),V=Ct("mm",!1),B=Ct("in",!1),Y=Ct("pt",!1),Z=Ct("pc",!1),X=zt("angle"),G=Ct("deg",!1),H=Ct("rad",!1),K=Ct("grad",!1),Q=Ct("turn",!1),tt=zt("number"),et=zt("color"),nt=Ct("#",!1),rt=Dt([["0","9"],["a","f"],["A","F"]],!1,!1),ot=Dt(["+","-"],!1,!1),at=Dt([["0","9"]],!1,!1),st=Ct(".",!1),ut=Ct("e",!1),lt=function(){return[]},ct=function(t,e){return{type:"function",name:t,parameters:e||[]}},ft=function(t,e){return e.length>0?function(t,e){return[t].concat(function(t){return t.map((function(t){return t[3]}))}(e))}(t,e):[t]},ht=function(t){return{type:"quantity",value:t.value,unit:t.unit}},dt=function(t){return{type:"color",colorType:t.type,value:t.value}},pt=function(t){return t},mt=function(){return Ut()},gt=function(t){return{value:t,unit:"%"}},vt=function(t){return{value:t,unit:"px"}},wt=function(t){return{value:t,unit:"cm"}},yt=function(t){return{value:t,unit:"mm"}},bt=function(t){return{value:t,unit:"in"}},Mt=function(t){return{value:t,unit:"pt"}},xt=function(t){return{value:t,unit:"pc"}},kt=function(t){return{value:t,unit:"deg"}},Tt=function(t){return{value:t,unit:"rad"}},Et=function(t){return{value:t,unit:"grad"}},_t=function(t){return{value:t,unit:"turn"}},St=function(t){return{value:t,unit:null}},Ft=function(){return{type:"hex",value:Ut()}},At=function(t){return{type:"function",value:t}},It=function(){return{type:"named",value:Ut()}},Ot=function(){return parseFloat(Ut())},jt=0|e.peg$currPos,$t=jt,Nt=[{line:1,column:1}],Pt=jt,Rt=e.peg$maxFailExpected||[],qt=0|e.peg$silentFails;if(e.startRule){if(!(e.startRule in o))throw new Error("Can't start parsing from rule \""+e.startRule+'".');a=o[e.startRule]}function Ut(){return t.substring($t,jt)}function Ct(t,e){return{type:"literal",text:t,ignoreCase:e}}function Dt(t,e,n){return{type:"class",parts:t,inverted:e,ignoreCase:n}}function zt(t){return{type:"other",description:t}}function Wt(e){var n,r=Nt[e];if(r)return r;if(e>=Nt.length)n=Nt.length-1;else for(n=e;!Nt[--n];);for(r={line:(r=Nt[n]).line,column:r.column};n<e;)10===t.charCodeAt(n)?(r.line++,r.column=1):r.column++,n++;return Nt[e]=r,r}function Jt(t){jt<Pt||(jt>Pt&&(Pt=jt,Rt=[]),Rt.push(t))}function Lt(){var t;return(t=Vt())===r&&(t=function(){var t,e;if(t=[],(e=Bt())!==r)for(;e!==r;)t.push(e),e=Bt();else t=r;return t}()),t}function Vt(){var e,n;return qt++,e=jt,Zt(),t.substr(jt,4)===s?(n=s,jt+=4):(n=r,0===qt&&Jt(O)),n!==r?(Zt(),$t=e,e=lt()):(jt=e,e=r),qt--,e===r&&0===qt&&Jt(I),e}function Bt(){var e,n,i,o;return e=jt,Zt(),(n=function(){var e,n,i;return qt++,e=jt,(n=Xt())!==r?(40===t.charCodeAt(jt)?(i=c,jt++):(i=r,0===qt&&Jt(q)),i!==r?($t=e,e=pt(n)):(jt=e,e=r)):(jt=e,e=r),qt--,e===r&&(n=r,0===qt&&Jt(R)),e}())!==r?(Zt(),(i=function(){var e,n,i,o,a,s,u,c;if(e=jt,(n=Yt())!==r){for(i=[],o=jt,a=Zt(),44===t.charCodeAt(jt)?(s=l,jt++):(s=r,0===qt&&Jt($)),s===r&&(s=null),u=Zt(),(c=Yt())!==r?o=a=[a,s,u,c]:(jt=o,o=r);o!==r;)i.push(o),o=jt,a=Zt(),44===t.charCodeAt(jt)?(s=l,jt++):(s=r,0===qt&&Jt($)),s===r&&(s=null),u=Zt(),(c=Yt())!==r?o=a=[a,s,u,c]:(jt=o,o=r);$t=e,e=ft(n,i)}else jt=e,e=r;return e}())===r&&(i=null),Zt(),41===t.charCodeAt(jt)?(o=u,jt++):(o=r,0===qt&&Jt(j)),o!==r?(Zt(),$t=e,e=ct(n,i)):(jt=e,e=r)):(jt=e,e=r),e}function Yt(){var t,e;return t=jt,(e=Gt())===r&&(e=Ht())===r&&(e=Kt())===r&&(e=function(){var t,e;return qt++,t=jt,Zt(),(e=te())!==r?($t=t,t=St(e)):(jt=t,t=r),qt--,t===r&&0===qt&&Jt(tt),t}()),e!==r&&($t=t,e=ht(e)),(t=e)===r&&(t=jt,(e=Qt())!==r&&($t=t,e=dt(e)),t=e),t}function Zt(){var e,n;for(qt++,e=[],n=t.charAt(jt),E.test(n)?jt++:(n=r,0===qt&&Jt(P));n!==r;)e.push(n),n=t.charAt(jt),E.test(n)?jt++:(n=r,0===qt&&Jt(P));return qt--,n=r,0===qt&&Jt(N),e}function Xt(){var e,n,i;if(qt++,e=jt,n=[],i=t.charAt(jt),_.test(i)?jt++:(i=r,0===qt&&Jt(C)),i!==r)for(;i!==r;)n.push(i),i=t.charAt(jt),_.test(i)?jt++:(i=r,0===qt&&Jt(C));else n=r;return n!==r&&($t=e,n=mt()),qt--,(e=n)===r&&(n=r,0===qt&&Jt(U)),e}function Gt(){var e,n,i;return qt++,e=jt,Zt(),(n=te())!==r?(37===t.charCodeAt(jt)?(i=f,jt++):(i=r,0===qt&&Jt(z)),i!==r?($t=e,e=gt(n)):(jt=e,e=r)):(jt=e,e=r),qt--,e===r&&0===qt&&Jt(D),e}function Ht(){var e,n,i;return qt++,e=jt,Zt(),(n=te())!==r?(t.substr(jt,2)===h?(i=h,jt+=2):(i=r,0===qt&&Jt(J)),i!==r?($t=e,e=vt(n)):(jt=e,e=r)):(jt=e,e=r),e===r&&(e=jt,Zt(),(n=te())!==r?(t.substr(jt,2)===d?(i=d,jt+=2):(i=r,0===qt&&Jt(L)),i!==r?($t=e,e=wt(n)):(jt=e,e=r)):(jt=e,e=r),e===r&&(e=jt,Zt(),(n=te())!==r?(t.substr(jt,2)===p?(i=p,jt+=2):(i=r,0===qt&&Jt(V)),i!==r?($t=e,e=yt(n)):(jt=e,e=r)):(jt=e,e=r),e===r&&(e=jt,Zt(),(n=te())!==r?(t.substr(jt,2)===m?(i=m,jt+=2):(i=r,0===qt&&Jt(B)),i!==r?($t=e,e=bt(n)):(jt=e,e=r)):(jt=e,e=r),e===r&&(e=jt,Zt(),(n=te())!==r?(t.substr(jt,2)===g?(i=g,jt+=2):(i=r,0===qt&&Jt(Y)),i!==r?($t=e,e=Mt(n)):(jt=e,e=r)):(jt=e,e=r),e===r&&(e=jt,Zt(),(n=te())!==r?(t.substr(jt,2)===v?(i=v,jt+=2):(i=r,0===qt&&Jt(Z)),i!==r?($t=e,e=xt(n)):(jt=e,e=r)):(jt=e,e=r)))))),qt--,e===r&&0===qt&&Jt(W),e}function Kt(){var e,n,i;return qt++,e=jt,(n=te())!==r?(t.substr(jt,3)===w?(i=w,jt+=3):(i=r,0===qt&&Jt(G)),i!==r?($t=e,e=kt(n)):(jt=e,e=r)):(jt=e,e=r),e===r&&(e=jt,(n=te())!==r?(t.substr(jt,3)===y?(i=y,jt+=3):(i=r,0===qt&&Jt(H)),i!==r?($t=e,e=Tt(n)):(jt=e,e=r)):(jt=e,e=r),e===r&&(e=jt,(n=te())!==r?(t.substr(jt,4)===b?(i=b,jt+=4):(i=r,0===qt&&Jt(K)),i!==r?($t=e,e=Et(n)):(jt=e,e=r)):(jt=e,e=r),e===r&&(e=jt,(n=te())!==r?(t.substr(jt,4)===M?(i=M,jt+=4):(i=r,0===qt&&Jt(Q)),i!==r?($t=e,e=_t(n)):(jt=e,e=r)):(jt=e,e=r)))),qt--,e===r&&(n=r,0===qt&&Jt(X)),e}function Qt(){var e,n,i,o;if(qt++,e=jt,35===t.charCodeAt(jt)?(n=x,jt++):(n=r,0===qt&&Jt(nt)),n!==r){if(i=[],o=t.charAt(jt),S.test(o)?jt++:(o=r,0===qt&&Jt(rt)),o!==r)for(;o!==r;)i.push(o),o=t.charAt(jt),S.test(o)?jt++:(o=r,0===qt&&Jt(rt));else i=r;i!==r?($t=e,e=Ft()):(jt=e,e=r)}else jt=e,e=r;return e===r&&(e=jt,(n=Bt())!==r&&($t=e,n=At(n)),(e=n)===r&&(e=jt,(n=Xt())!==r&&($t=e,n=It()),e=n)),qt--,e===r&&(n=r,0===qt&&Jt(et)),e}function te(){var e,n,i,o,a,s,u,l;for(e=jt,n=t.charAt(jt),F.test(n)?jt++:(n=r,0===qt&&Jt(ot)),n===r&&(n=null),i=jt,o=[],a=t.charAt(jt),A.test(a)?jt++:(a=r,0===qt&&Jt(at));a!==r;)o.push(a),a=t.charAt(jt),A.test(a)?jt++:(a=r,0===qt&&Jt(at));if(46===t.charCodeAt(jt)?(a=k,jt++):(a=r,0===qt&&Jt(st)),a!==r){if(s=[],u=t.charAt(jt),A.test(u)?jt++:(u=r,0===qt&&Jt(at)),u!==r)for(;u!==r;)s.push(u),u=t.charAt(jt),A.test(u)?jt++:(u=r,0===qt&&Jt(at));else s=r;s!==r?i=o=[o,a,s]:(jt=i,i=r)}else jt=i,i=r;if(i===r)if(i=[],o=t.charAt(jt),A.test(o)?jt++:(o=r,0===qt&&Jt(at)),o!==r)for(;o!==r;)i.push(o),o=t.charAt(jt),A.test(o)?jt++:(o=r,0===qt&&Jt(at));else i=r;if(i!==r){if(o=jt,101===t.charCodeAt(jt)?(a=T,jt++):(a=r,0===qt&&Jt(ut)),a!==r){if(s=t.charAt(jt),F.test(s)?jt++:(s=r,0===qt&&Jt(ot)),s===r&&(s=null),u=[],l=t.charAt(jt),A.test(l)?jt++:(l=r,0===qt&&Jt(at)),l!==r)for(;l!==r;)u.push(l),l=t.charAt(jt),A.test(l)?jt++:(l=r,0===qt&&Jt(at));else u=r;u!==r?o=a=[a,s,u]:(jt=o,o=r)}else jt=o,o=r;o===r&&(o=null),$t=e,e=Ot()}else jt=e,e=r;return e}if(n=a(),e.peg$library)return{peg$result:n,peg$currPos:jt,peg$FAILED:r,peg$maxFailExpected:Rt,peg$maxFailPos:Pt};if(n!==r&&jt===t.length)return n;throw n!==r&&jt<t.length&&Jt({type:"end"}),function(t,e,n){return new it(it.buildMessage(t,e),t,e,n)}(Rt,Pt<t.length?t.charAt(Pt):null,function(t,e){var n=Wt(t),r=Wt(e);return{source:i,start:{offset:t,line:n.line,column:n.column},end:{offset:e,line:r.line,column:r.column}}}(Pt,Pt<t.length?Pt+1:Pt))}(t)}catch(e){throw new y("effect:invalid-syntax","Invalid effect syntax",{value:t,error:e})}return e.map((t=>function(t){try{switch(t.name){case"grayscale":case"sepia":case"saturate":case"invert":case"brightness":case"contrast":return function(t){let e=1;return ut(t.parameters,1),1===t.parameters.length&&(e=dt(t.parameters[0])),new X(t.name,e)}(t);case"opacity":return function(t){let e=1;return ut(t.parameters,1),1===t.parameters.length&&(e=dt(t.parameters[0])),new K(e)}(t);case"hue-rotate":return function(t){let e=0;return ut(t.parameters,1),1===t.parameters.length&&(e=function(t){return function(t){if("quantity"!==t.type||!(0===t.value&&null===t.unit||t.unit&&null!=ft[t.unit]))throw new y("effect:type-error",`Expected <angle>, Actual: ${lt(t)}`,{term:t})}(t),t.value*ft[t.unit]||0}(t.parameters[0])),new H(e)}(t);case"blur":return function(t){let e=0;return ut(t.parameters,1),1===t.parameters.length&&(e=pt(t.parameters[0]),ct(e,t.parameters[0])),new Z(e)}(t);case"drop-shadow":return function(t){const e=[];let n=null;for(const r of t.parameters)if("color"===r.type){if(e.length&&Object.freeze(e),n)throw new y("effect:type-error","Accepts only one color",{});n=mt(r)}else{const t=pt(r);if(Object.isFrozen(e))throw new y("effect:type-error","<length> parameters not consecutive",{lengths:e});e.push(t),3===e.length&&ct(t,r)}if(e.length<2||e.length>3)throw new y("effect:type-error",`Expected <length>{2,3}, Actual: <length>{${e.length}}`,{lengths:e});return new G(e[0],e[1],e[2]||0,n||gt("black"))}(t);case"bloom":return function(t){let e=1,n=0,r=0;return ut(t.parameters,3),t.parameters[0]&&(e=dt(t.parameters[0])),t.parameters[1]&&(n=pt(t.parameters[1]),ct(n,t.parameters[1])),t.parameters[2]&&(r=dt(t.parameters[2])),new Y(e,n,r)}(t)}}catch(e){throw e.details.filter=t,e}throw new y("effect:unknown-effect",`Effect '${t.name}' is not supported`,{effect:t})}(t)))}function ut(t,e){if(t.length>e)throw new y("effect:type-error",`Function supports up to ${e} parameters, Actual: ${t.length}`,{parameters:t})}function lt(t){if("color"===t.type)return"<color>";if(t.unit){if(t.unit in ht)return"<length>";if(t.unit in ft)return"<angle>";if("%"===t.unit)return"<percentage>"}return"<double>"}function ct(t,e){if(t<0)throw new y("effect:type-error",`Negative values are not allowed, Actual: ${t}`,{term:e})}(function(t,e){function n(){this.constructor=t}n.prototype=e.prototype,t.prototype=new n})(it,Error),it.prototype.format=function(t){var e="Error: "+this.message;if(this.location){var n,r=null;for(n=0;n<t.length;n++)if(t[n].source===this.location.source){r=t[n].text.split(/\r\n|\n|\r/g);break}var i=this.location.start,o=this.location.source&&"function"==typeof this.location.source.offset?this.location.source.offset(i):i,a=this.location.source+":"+o.line+":"+o.column;if(r){var s=this.location.end,u=ot("",o.line.toString().length," "),l=r[i.line-1],c=(i.line===s.line?s.column:l.length+1)-i.column||1;e+="\n --\x3e "+a+"\n"+u+" |\n"+o.line+" | "+l+"\n"+u+" | "+ot("",i.column-1," ")+ot("",c,"^")}else e+="\n at "+a}return e},it.buildMessage=function(t,e){var n={literal:function(t){return'"'+i(t.text)+'"'},class:function(t){var e=t.parts.map((function(t){return Array.isArray(t)?o(t[0])+"-"+o(t[1]):o(t)}));return"["+(t.inverted?"^":"")+e.join("")+"]"},any:function(){return"any character"},end:function(){return"end of input"},other:function(t){return t.description}};function r(t){return t.charCodeAt(0).toString(16).toUpperCase()}function i(t){return t.replace(/\\/g,"\\\\").replace(/"/g,'\\"').replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,(function(t){return"\\x0"+r(t)})).replace(/[\x10-\x1F\x7F-\x9F]/g,(function(t){return"\\x"+r(t)}))}function o(t){return t.replace(/\\/g,"\\\\").replace(/\]/g,"\\]").replace(/\^/g,"\\^").replace(/-/g,"\\-").replace(/\0/g,"\\0").replace(/\t/g,"\\t").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/[\x00-\x0F]/g,(function(t){return"\\x0"+r(t)})).replace(/[\x10-\x1F\x7F-\x9F]/g,(function(t){return"\\x"+r(t)}))}function a(t){return n[t.type](t)}return"Expected "+function(t){var e,n,r=t.map(a);if(r.sort(),r.length>0){for(e=1,n=1;e<r.length;e++)r[e-1]!==r[e]&&(r[n]=r[e],n++);r.length=n}switch(r.length){case 1:return r[0];case 2:return r[0]+" or "+r[1];default:return r.slice(0,-1).join(", ")+", or "+r[r.length-1]}}(t)+" but "+function(t){return t?'"'+i(t)+'"':"end of input"}(e)+" found."};const ft={deg:1,grad:.9,rad:180/Math.PI,turn:360},ht={px:1,cm:96/2.54,mm:96/2.54/10,in:96,pc:16,pt:96/72};function dt(t){!function(t){if("quantity"!==t.type||null!==t.unit&&"%"!==t.unit)throw new y("effect:type-error",`Expected <double> or <percentage>, Actual: ${lt(t)}`,{term:t})}(t);const e=t.value;return ct(e,t),"%"===t.unit?.01*e:e}function pt(t){return function(t){if("quantity"!==t.type||!(0===t.value&&null===t.unit||t.unit&&null!=ht[t.unit]))throw new y("effect:type-error",`Expected <length>, Actual: ${lt(t)}`,{term:t})}(t),t.value*ht[t.unit]||0}function mt(t){switch(t.colorType){case"hex":return function(t){const e=t.length>5,n=e?8:4,r=(1<<n)-1,i=e?1:17,o=e?9===t.length:5===t.length;let a=Number("0x"+t.slice(1));if(isNaN(a))return null;const s=[0,0,0,1];let u;return o&&(u=a&r,a>>=n,s[3]=i*u/255),u=a&r,a>>=n,s[2]=i*u,u=a&r,a>>=n,s[1]=i*u,u=a&r,a>>=n,s[0]=i*u,s}(t.value);case"named":return gt(t.value);case"function":return function(t){if(ut(t.parameters,4),vt.test(t.name))return[dt(t.parameters[0]),dt(t.parameters[1]),dt(t.parameters[2]),t.parameters[3]?dt(t.parameters[3]):1];if(wt.test(t.name))return function(t,e,n,r=1){const i=(t%360+360)%360/360,o=n<=.5?n*(e+1):n+e-n*e,a=2*n-o;return[Math.round(255*x(a,o,i+1/3)),Math.round(255*x(a,o,i)),Math.round(255*x(a,o,i-1/3)),r]}(function(t){return function(t){if("quantity"!==t.type||null!==t.unit)throw new y("effect:type-error",`Expected <double>, Actual: ${lt(t)}`,{term:t})}(t),ct(t.value,t),t.value}(t.parameters[0]),dt(t.parameters[1]),dt(t.parameters[2]),t.parameters[3]?dt(t.parameters[3]):1);throw new y("effect:syntax-error",`Invalid color function '${t.name}'`,{colorFunction:t})}(t.value)}}function gt(t){if(!function(t){return!!b[t]||!!b[t.toLowerCase()]}(t))throw new y("effect:unknown-color",`color '${t}' isn't valid`,{namedColor:t});return function(t){return[...M(t)]}(t)}const vt=/^rgba?/i,wt=/^hsla?/i;function yt(t){const e=at(t);return e?function(t){const e=t[0];return!!e&&"type"in e}(e)?e.map((t=>t.toJSON())):e.map((({scale:t,effects:e})=>({scale:t,value:e.map((t=>t.toJSON()))}))):null}function bt(t){if(!t||0===t.length)return null;if(function(t){const e=t[0];return!!e&&"scale"in e}(t)){const e=[];for(const n of t)e.push({scale:n.scale,value:Mt(n.value)});return e}return Mt(t)}function Mt(t){if(!t?.length)return"";const e=[];for(const n of t){let t=[];switch(n.type){case"grayscale":case"sepia":case"saturate":case"invert":case"brightness":case"contrast":case"opacity":t=[xt(n,"amount")];break;case"blur":t=[xt(n,"radius","pt")];break;case"hue-rotate":t=[xt(n,"angle","deg")];break;case"drop-shadow":t=[xt(n,"xoffset","pt"),xt(n,"yoffset","pt"),xt(n,"blurRadius","pt"),kt(n,"color")];break;case"bloom":t=[xt(n,"strength"),xt(n,"radius","pt"),xt(n,"threshold")]}const r=`${n.type}(${t.filter(Boolean).join(" ")})`;at(r),e.push(r)}return e.join(" ")}function xt(t,e,n){if(null==t[e])throw new y("effect:missing-parameter",`Missing parameter '${e}' in ${t.type} effect`,{effect:t});return n?t[e]+n:""+t[e]}function kt(t,e){if(null==t[e])throw new y("effect:missing-parameter",`Missing parameter '${e}' in ${t.type} effect`,{effect:t});const n=t[e];return`rgba(${n[0]||0}, ${n[1]||0}, ${n[2]||0}, ${n[3]/255||0})`}function Tt(t,e,n){const r=e?.layer;if(!t)return r?.effect?r.effect:r?.featureEffect?"includedEffect"===n?r.featureEffect.includedEffect:r.featureEffect.excludedEffect:null;const i=yt(t);let o=null;o=r.featureEffect?"includedEffect"===n?r.featureEffect.includedEffect:r.featureEffect.excludedEffect:r.effect;const a=o?yt(o):null;if(!a)return bt(i);let s=[...a];return i&&i.forEach((t=>{s.forEach((e=>{const{value:n}=e;if(n)n.forEach(((r,o)=>{r.type===t.type?n[o]=t:!e.value.find((t=>t.type===i[0].type))&&(e.value=[...e.value,...i])}));else{const n=!s.find((t=>t.type===e.type));!s.find((e=>e.type===t.type))&&(s=[...s,t]),n&&(s=[...s,e])}}))})),bt(s)}const Et="time-slider-watch",_t=new class{constructor(){this.initializeModules()}async initializeModules(){try{const[t,e,n,r,i,o,s]=await a(["esri/core/Handles","esri/core/reactiveUtils","esri/widgets/TimeSlider","esri/TimeExtent","esri/TimeInterval","esri/layers/support/FeatureFilter","esri/layers/support/FeatureEffect"]);this.reactiveUtils=e,this.handles=new t,this.TimeSlider=n,this.TimeExtent=r,this.TimeInterval=i,this.FeatureFilter=o,this.FeatureEffect=s}catch(t){}}async init(t){t&&(t.innerHTML="");const{view:e,timeInfoConfigItems:n}=u;if(e)try{await e.when();const r=await this.getTimeLayerViews(e,n);return u.timeInfoItems=this.generateTimeInfoItems(r,n),this.initTimeSlider(t),this.setupFilterModeWatcher(),Promise.resolve()}catch(t){}}destroy(){var t,e;null===(t=this.handles)||void 0===t||t.removeAll(),this.handles=null,null===(e=u.timeSlider)||void 0===e||e.destroy()}async getTimeLayerViews(t,e){const{allLayers:n}=t.map,r=e.map((({id:t})=>{return e=t,n.find((({id:t})=>e===t));var e})).map((e=>t.whenLayerView(e)));return await Promise.all(r)}generateTimeInfoItems(t,e){return[...e].map((e=>{const n=t.find((({layer:t})=>t.id===e.id));return this.generateTimeInfoItem(n,e)}))}generateTimeInfoItem(t,{increments:e,rangeStart:n,rangeEnd:r}){var i;const o=null==t?void 0:t.layer,a=null===(i=null==o?void 0:o.timeInfo)||void 0===i?void 0:i.fullTimeExtent;return{layerView:t,unit:e,rangeStart:new Date(n),rangeEnd:new Date(r),timeExtent:a,previousTimeExtent:null}}initTimeSlider(t){var e,n;const r=null===(e=null==u?void 0:u.timeInfoItems)||void 0===e?void 0:e[0];if(!r)return;const{TimeSlider:i}=this;u.selectedTimeInfoItem=r;const o=this.getTimeSliderConfig(t);u.timeSlider=new i(o),"2d"===(null===(n=u.view)||void 0===n?void 0:n.type)&&this.initialize2DView()}setupFilterModeWatcher(){l("filterMode",(t=>u.timeInfoItems.forEach((e=>{var n,r,i;const o=e.layerView;this.applyTimeExtent(o,(null===(r=null===(n=null==o?void 0:o.featureEffect)||void 0===n?void 0:n.filter)||void 0===r?void 0:r.timeExtent)||(null===(i=o.filter)||void 0===i?void 0:i.timeExtent),t)}))))}getTimeSliderConfig(t){var e;const[{timeExtent:n,rangeStart:r,rangeEnd:i,unit:o}]=u.timeInfoItems,{TimeExtent:a,TimeInterval:s}=this;return{container:t,fullTimeExtent:n,timeExtent:new a({start:r,end:i}),mode:"time-window",loop:!0,stops:{interval:new s({unit:o,value:1})},view:"3d"===(null===(e=u.view)||void 0===e?void 0:e.type)?u.view:null}}initialize2DView(){u.timeInfoItems.forEach((t=>this.applyTimeExtent(t.layerView,new this.TimeExtent({start:t.rangeStart,end:t.rangeEnd})))),this.setupTimeExtentWatcher()}applyTimeExtent(t,e,n){var r;"effect"===(null===(r=u.filterMode)||void 0===r?void 0:r.type)?this.applyFeatureEffect(t,e,n):this.applyFeatureFilter(t,e)}applyFeatureEffect(t,e,n){t&&(t.filter&&t.set("filter",null),t.featureEffect&&!n?t.featureEffect.filter.timeExtent=e:this.handleUpdatedFeatureEffect(t,e))}handleUpdatedFeatureEffect(t,e){var n,r,i,o;const{FeatureEffect:a}=this;t.featureEffect=new a({filter:{timeExtent:e},includedEffect:Tt(null===(r=null===(n=u.filterMode)||void 0===n?void 0:n.effect)||void 0===r?void 0:r.includedEffect,t,"includedEffect"),excludedEffect:Tt(null===(o=null===(i=u.filterMode)||void 0===i?void 0:i.effect)||void 0===o?void 0:o.excludedEffect,t,"excludedEffect")})}applyFeatureFilter(t,e){t.featureEffect&&t.set("featureEffect",null),t.filter?t.filter.timeExtent=e:t.filter=new this.FeatureFilter({timeExtent:e})}setupTimeExtentWatcher(){var t,e,n,r;(null===(t=this.handles)||void 0===t?void 0:t.has(Et))&&(null===(e=this.handles)||void 0===e||e.remove(Et)),null===(n=this.handles)||void 0===n||n.add(null===(r=null==u?void 0:u.timeSlider)||void 0===r?void 0:r.watch("timeExtent",(t=>{var e;return this.applyTimeExtent(null===(e=u.selectedTimeInfoItem)||void 0===e?void 0:e.layerView,t)})),Et)}updateSelectedTimeInfoItem(t){u.timeSlider&&(u.selectedTimeInfoItem&&(u.selectedTimeInfoItem.previousTimeExtent=u.timeSlider.timeExtent),u.selectedTimeInfoItem=t,this.reconfigureTimeSlider(t),this.applyTimeExtent(t.layerView,u.timeSlider.timeExtent),this.setupTimeExtentWatcher())}reconfigureTimeSlider(t){u.timeSlider&&(u.timeSlider.fullTimeExtent=t.timeExtent,u.timeSlider.timeExtent=this.getTimeExtent(t),u.timeSlider.stops={interval:this.getTimeInterval(t)})}getTimeExtent({rangeStart:t,rangeEnd:e,previousTimeExtent:n}){const{TimeExtent:r}=this;return null!=n?n:new r({start:t,end:e})}getTimeInterval(t){var e,n,r,i,o;const{TimeInterval:a}=this;return new a({unit:null!==(e=t.unit)&&void 0!==e?e:null===(o=null===(i=null===(r=null===(n=t.layerView)||void 0===n?void 0:n.layer)||void 0===r?void 0:r.timeInfo)||void 0===i?void 0:i.interval)||void 0===o?void 0:o.unit,value:1})}getLabel(t){var e,n;return(null===(n=null===(e=null==t?void 0:t.layerView)||void 0===e?void 0:e.layer)||void 0===n?void 0:n.title)||""}},St=class{constructor(e){t(this,e),this.timeSliderRef=void 0,this.timeInfoConfigItems=[],this.filterMode=void 0,this.view=void 0}async updateTimeInfoConfigItems(){u.timeInfoConfigItems=this.timeInfoConfigItems,await _t.init(this.timeSliderRef)}async updateFilterMode(){u.filterMode=this.filterMode}async componentWillLoad(){try{u.view=this.view,u.timeInfoConfigItems=this.timeInfoConfigItems,this.filterMode&&(u.filterMode=this.filterMode),await s(this)}catch(t){}}async componentDidLoad(){try{await _t.init(this.timeSliderRef)}catch(t){}finally{u.loading=!1}}disconnectedcallback(){_t.destroy()}render(){return e(n,{key:"bf0887f83b19239ce1b81efad5c356c7edc05ba1"},this._renderBase())}_renderBase(){return e("div",{class:"instant-apps-time-filter"+("2d"!==this.view.type?" instant-apps-time-filter--3d":"")},this._renderLoader(),this._renderMain())}_renderMain(){return e(r,null,"2d"===this.view.type&&this._renderTopEl(),e("div",{ref:t=>this.timeSliderRef=t}))}_renderLoader(){var t,n;return u.loading&&e(r,null,e("div",{class:"instant-apps-time-filter__background"}),e("div",{class:"instant-apps-time-filter__loading-container"},e("calcite-loader",{scale:"m",label:null===(t=this.messages)||void 0===t?void 0:t.loading,text:null===(n=this.messages)||void 0===n?void 0:n.loading})))}_renderTopEl(){return this.timeInfoConfigItems.length>1?this._renderDropdown():this._renderLayerTitle()}_renderLayerTitle(){var t,n,r;const i=null===(r=null===(n=null===(t=u.selectedTimeInfoItem)||void 0===t?void 0:t.layerView)||void 0===n?void 0:n.layer)||void 0===r?void 0:r.title;return e("span",{class:"instant-apps-time-filter__layer-title"},i)}_renderDropdown(){return u.selectedTimeInfoItem&&e("calcite-dropdown",null,this._renderDropdownButton(),this._renderDropdownItems())}_renderDropdownButton(){return e("calcite-button",{slot:"trigger",appearance:"transparent",iconEnd:"chevron-down",width:"full",alignment:"space-between"},_t.getLabel(u.selectedTimeInfoItem))}_renderDropdownItems(){return u.timeInfoItems.map((t=>this._renderDropdownItem(t)))}_renderDropdownItem(t){var n,r,i,o,a;const s=null===(i=null===(r=null===(n=u.selectedTimeInfoItem)||void 0===n?void 0:n.layerView)||void 0===r?void 0:r.layer)||void 0===i?void 0:i.id,l=null===(a=null===(o=null==t?void 0:t.layerView)||void 0===o?void 0:o.layer)||void 0===a?void 0:a.id;return e("calcite-dropdown-item",{onCalciteDropdownItemSelect:()=>_t.updateSelectedTimeInfoItem(t),selected:s===l},_t.getLabel(t))}get el(){return i(this)}static get watchers(){return{timeInfoConfigItems:["updateTimeInfoConfigItems"],filterMode:["updateFilterMode"]}}};St.style=".instant-apps-time-filter{position:relative;display:block;min-width:375px;min-height:200px}.instant-apps-time-filter__background{background-color:var(--calcite-ui-background);position:absolute;top:0;left:0;width:100%;height:100%;z-index:0}.instant-apps-time-filter calcite-dropdown{width:100%}.instant-apps-time-filter calcite-dropdown calcite-button{--calcite-color-brand:var(--calcite-ui-text-1);--calcite-ui-brand:var(--calcite-ui-text-1)}.instant-apps-time-filter__layer-title{font-weight:550;display:inline-block;padding:10px}.instant-apps-time-filter__loading-container{display:flex;justify-content:center;align-items:center;position:absolute;top:0;left:0;width:100%;height:100%;z-index:1}.instant-apps-time-filter--3d{min-height:160px}";export{St as instant_apps_time_filter}
@@ -1,6 +0,0 @@
1
- /*!
2
- * Copyright 2022 Esri
3
- * Licensed under the Apache License, Version 2.0
4
- * http://www.apache.org/licenses/LICENSE-2.0
5
- */
6
- import{r as t,g as i,h as s,H as e,c as a}from"./p-f4c4a2b7.js";import{l as h,g as n}from"./p-d7868dd4.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";const o=class{constructor(i){t(this,i),this.mapView=void 0,this.basemapConfig=void 0,this.basemapWidget=void 0}get el(){return i(this)}BasemapGallery;PortalBasemapsSource;_basemapElement;async mapViewWatchHandler(){await this.mapView.when((()=>{this._initBaseMapGallery(this.mapView)}))}async componentWillLoad(){return this._initModules()}render(){return s(e,{key:"7fe5ef48d77de087f17498e2e1f3370a069e8629"},s("div",{key:"aca555c687352046a138343cab6f656234069644",ref:t=>{this._basemapElement=t}}))}async componentDidLoad(){this.mapView&&await this.mapViewWatchHandler()}async _initModules(){const[t,i]=await h(["esri/widgets/BasemapGallery","esri/widgets/BasemapGallery/support/PortalBasemapsSource"]);this.BasemapGallery=t,this.PortalBasemapsSource=i}async _initBaseMapGallery(t){if(this.BasemapGallery){this.basemapWidget&&this.basemapWidget.destroy();const i=new this.PortalBasemapsSource({query:this.basemapConfig?.basemapGroupId?`id:${this.basemapConfig.basemapGroupId}`:null,filterFunction:this.basemapConfig?t=>!this.basemapConfig.basemapIdsToFilter.includes(t.portalItem.id):()=>!0});await i.refresh(),this.basemapWidget=new this.BasemapGallery({container:this._basemapElement,view:t,source:i})}}static get watchers(){return{mapView:["mapViewWatchHandler"]}}};o.style=":host{display:block}";const c=class{constructor(i){t(this,i),this.facilityChanged=a(this,"facilityChanged",7),this.levelChanged=a(this,"levelChanged",7),this.siteChanged=a(this,"siteChanged",7),this.enabled=void 0,this.floorFilterWidget=void 0,this.mapView=void 0}get el(){return i(this)}FloorFilter;_floorFilterElement;reactiveUtils;_facilityHandle;_levelHandle;_siteHandle;async mapViewWatchHandler(){await this._initFloorFilter(this.mapView)}async enabledWatchHandler(){this.enabled?await this._initFloorFilter(this.mapView):this.enabled||this._destroyWidget()}facilityChanged;levelChanged;siteChanged;async componentWillLoad(){return this._initModules()}render(){return s(e,{key:"c80a8d46fb48f3789d9fa09c2400faad49e2e236"},s("div",{key:"82919a3ba061a17c8aeaa0d2f6f4f13bc428b519",ref:t=>{this._floorFilterElement=t}}))}async componentDidLoad(){this.mapView&&!this.floorFilterWidget&&await this._initFloorFilter(this.mapView)}async _initModules(){const[t,i]=await h(["esri/widgets/FloorFilter","esri/core/reactiveUtils"]);this.FloorFilter=t,this.reactiveUtils=i}_destroyWidget(){this.floorFilterWidget&&(this.floorFilterWidget.destroy(),this.floorFilterWidget=void 0),this._floorFilterElement&&this._floorFilterElement.remove()}_initContainer(){this._destroyWidget(),this._floorFilterElement=document.createElement("div")}async _initFloorFilter(t){const i=t?.map;await i.when((()=>{t&&this.enabled&&this.FloorFilter&&i?.floorInfo&&(this._initContainer(),this.floorFilterWidget=new this.FloorFilter({container:this._floorFilterElement,view:t}),this._facilityHandle?.remove(),this._facilityHandle=this.reactiveUtils.watch((()=>this.floorFilterWidget.facility),(t=>{this.facilityChanged.emit(t)})),this._levelHandle?.remove(),this._levelHandle=this.reactiveUtils.watch((()=>this.floorFilterWidget.level),(t=>{this.levelChanged.emit(t)})),this._siteHandle?.remove(),this._siteHandle=this.reactiveUtils.watch((()=>this.floorFilterWidget.site),(t=>{this.siteChanged.emit(t)})))}))}static get watchers(){return{mapView:["mapViewWatchHandler"],enabled:["enabledWatchHandler"]}}};c.style=":host{display:block}";const r=class{constructor(i){t(this,i),this.fullscreenStateChange=a(this,"fullscreenStateChange",7),this.mapView=void 0,this.fullscreenWidget=void 0}Fullscreen;_fullscreenElement;_fullscreenStateChangeHandle;reactiveUtils;async mapViewWatchHandler(){await this.mapView.when((async()=>{await this._initFullscreenWidget()}))}fullscreenStateChange;async componentWillLoad(){await this._initModules()}render(){return s(e,{key:"943217d26f3cf5861c165c3300ba24736ce8f7dc"},s("div",{key:"6c76ebf6e63dab19f24d776cd27cd86b74ea93d0",class:"fullscreen-widget",ref:t=>{this._fullscreenElement=t}}))}async componentDidUpdate(){await this._initFullscreenWidget()}async componentDidLoad(){await this._initFullscreenWidget()}async _initModules(){const[t,i]=await h(["esri/widgets/Fullscreen","esri/core/reactiveUtils"]);this.Fullscreen=t,this.reactiveUtils=i}async _initFullscreenWidget(){this.mapView&&this._fullscreenElement&&!this.fullscreenWidget?(this.fullscreenWidget=new this.Fullscreen({view:this.mapView}),await this.fullscreenWidget.when((()=>{this._fullscreenStateChangeHandle&&this._fullscreenStateChangeHandle.remove(),this._fullscreenStateChangeHandle=this.reactiveUtils.watch((()=>this.fullscreenWidget.viewModel.state),(t=>this.fullscreenStateChange.emit(t)))}))):this.fullscreenWidget&&(this.fullscreenWidget.view=this.mapView)}static get watchers(){return{mapView:["mapViewWatchHandler"]}}};r.style=":host{display:block}";const l=class{constructor(i){t(this,i),this.mapView=void 0,this.legendWidget=void 0}get el(){return i(this)}Legend;_legendElement;async mapViewWatchHandler(){await this.mapView.when((()=>{this._initLegend(this.mapView)}))}async componentWillLoad(){return this._initModules()}render(){return s(e,{key:"bdd3b848bec1aec6f8c7676f8bab5e9463b16064"},s("div",{key:"d7bb217db6971758ef8774d19d6ac5cfa94a0ddc",ref:t=>{this._legendElement=t}}))}async componentDidLoad(){this.mapView&&await this.mapViewWatchHandler()}async _initModules(){const[t]=await h(["esri/widgets/Legend"]);this.Legend=t}_initLegend(t){t&&this.Legend&&(this.legendWidget?this.legendWidget.view=t:this.legendWidget=new this.Legend({container:this._legendElement,view:t}))}static get watchers(){return{mapView:["mapViewWatchHandler"]}}};l.style=":host{display:block}";const d=class{constructor(i){t(this,i),this.mapInfoChange=a(this,"mapInfoChange",7),this.mapInfos=[],this._mapListExpanded=!1,this._translations=void 0,this._webMapInfo=void 0}get el(){return i(this)}_list;_loadedId="";_webMapInfoWatchHandler(t,i){t&&JSON.stringify(t)!==JSON.stringify(i)&&(this._loadedId=t?.id,this.mapInfoChange.emit(t))}async mapInfosWatchHandler(t,i){t&&JSON.stringify(t)!==JSON.stringify(i)&&this._webMapSelected(t[0])}async setMapByID(t){const i=this.mapInfos?.filter((i=>i.id===t));t&&i?.length>0&&this._webMapSelected(i[0])}mapInfoChange;async componentWillLoad(){await this._getTranslations()}render(){return s(e,{key:"86994e2c4d87809c1508b073c3af1c0975c2d81d"},this._getToolbar(),this._getMapNameList(this._mapListExpanded))}async componentDidLoad(){const t=this.mapInfos&&this.mapInfos.length>0?this.mapInfos[0]:void 0;t&&this._webMapSelected(t)}_getMapPicker(){const t="map-picker-expand-toggle";return s("div",{class:"width-full"},s("calcite-button",{alignment:"icon-end-space-between",appearance:"transparent",class:"width-full height-full",iconEnd:this._mapListExpanded?"chevron-up":"chevron-down",id:t,kind:"neutral",onClick:()=>this._chooseMap(),width:"full"},this._webMapInfo?.name),s("calcite-tooltip",{label:"",placement:"bottom","reference-element":t},s("span",null,this._translations.switchMap)))}_getToolbar(){return s("div",{class:"display-flex"},s("calcite-action-bar",{class:"border-bottom-1 action-bar-size","expand-disabled":!0,layout:"horizontal",slot:"header"},this._getMapPicker()))}_getMapNameList(t){return s("div",{class:t?"map-list border-bottom-1":"display-none"},s("calcite-list",{id:"mapList",ref:t=>this._list=t,selectionAppearance:"border",selectionMode:"single"},this.mapInfos.map((t=>s("calcite-list-item",{label:t.name,onClick:()=>this._webMapSelected(t),selected:t.id===this._loadedId,value:t.id})))))}_webMapSelected(t){this._mapListExpanded=!1,this._webMapInfo=t}_chooseMap(){this._mapListExpanded=!this._mapListExpanded}async _getTranslations(){const t=await n(this.el);this._translations=t[0]}static get watchers(){return{_webMapInfo:["_webMapInfoWatchHandler"],mapInfos:["mapInfosWatchHandler"]}}};d.style=":host{display:block;--solutions-theme-foreground-color:var(--calcite-color-foreground-1)}.width-full{width:100%}.height-full{height:100%}.display-flex{display:flex}.border-bottom-1{border-width:0px;border-bottom-width:1px;border-style:solid;border-color:var(--calcite-color-border-3)}.action-bar-size{height:51px;width:100%}.map-list{position:absolute;display:flex;flex-direction:column;overflow:hidden;animation:calcite-scrim-fade-in var(--calcite-internal-animation-timing-medium) ease-in-out;background-color:var(--calcite-color-background);z-index:1000;width:100%;height:-moz-fit-content;height:fit-content}.display-none{display:none}.align-center{align-items:center}";const p=class{constructor(i){t(this,i),this.mapView=void 0,this.popupEnabled=!1,this.resultGraphicEnabled=!1,this.searchConfiguration=void 0,this.searchTerm=void 0,this.searchWidget=void 0}FeatureLayer;Search;_searchElement;_searchResult;async watchSearchConfigurationHandler(){this._initSearchWidget()}async mapViewWatchHandler(){await this.mapView.when((()=>{this._initSearchWidget()}))}async componentWillLoad(){await this._initModules()}async componentDidLoad(){return this._initSearchWidget()}render(){return s(e,{key:"5036a89c6a686b2486ff88dffd06f0bed1ea510e"},s("div",{key:"4c5ede4d9877ff0ca0f16706c99aba354df21fd1",class:"search-widget",ref:t=>{this._searchElement=t}}))}async _initModules(){const[t,i]=await h(["esri/widgets/Search","esri/layers/FeatureLayer"]);this.Search=t,this.FeatureLayer=i}_initSearchWidget(){if(this.mapView&&this._searchElement&&!this.searchWidget){let t={view:this.mapView,container:this._searchElement,searchTerm:this.searchTerm};this.searchConfiguration&&(t={...this._getSearchConfig(this.searchConfiguration,this.mapView)}),this.searchWidget=new this.Search(t),this.searchWidget.popupEnabled=this.popupEnabled,this.searchWidget.resultGraphicEnabled=this.resultGraphicEnabled}else this.searchWidget&&(this.searchWidget.view=this.mapView)}_getSearchConfig(t,i){const s=t.sources;return s?.length>0?(t.includeDefaultSources=!1,s.forEach((t=>{if(t.hasOwnProperty("layer")){const s=t,e=s.layer?.id,a=e?i.map.findLayerById(e):null,h=s?.layer?.url;a?s.layer=a:h&&(s.layer=new this.FeatureLayer(h))}})),s?.forEach((t=>{if(t.hasOwnProperty("locator")){const i=t;"ArcGIS World Geocoding Service"===i?.name&&(i.outFields=i.outFields||["Addr_type","Match_addr","StAddr","City"],i.singleLineFieldName="SingleLine"),i.url=i.url,delete i.url}}))):t={...t,includeDefaultSources:!0},t}static get watchers(){return{searchConfiguration:["watchSearchConfigurationHandler"],mapView:["mapViewWatchHandler"]}}};p.style=":host{display:block}.search-widget{width:100% !important;border:1px solid var(--calcite-color-border-input)}";const m=class{constructor(i){t(this,i),this.basemapConfig=void 0,this.enableLegend=void 0,this.enableFloorFilter=void 0,this.enableFullscreen=void 0,this.enableSearch=void 0,this.enableBasemap=void 0,this.enableHome=void 0,this.enableSingleExpand=void 0,this.homeZoomToolsSize="m",this.layout="vertical",this.mapView=void 0,this.mapWidgetsSize="m",this.position="top-right",this.searchConfiguration=void 0,this.stackTools=!0,this.toolOrder=void 0,this._hasFloorInfo=!1,this._translations=void 0,this._showTools=!0,this._showBasemapWidget=!1,this._showFloorFilter=!1,this._showFullscreen=!1,this._showLegendWidget=!1,this._showSearchWidget=!1}get el(){return i(this)}Expand;_basemapElement;_floorFilterElement;_fullscreenElement;_legendElement;_searchElement;_widgets=[];async mapViewWatchHandler(){await this.mapView.when((()=>{this._hasFloorInfo=this.mapView?.map?.floorInfo}))}async _showBasemapWidgetWatchHandler(t){t?this.mapView.ui.add(this._basemapElement.basemapWidget,{position:this.position,index:1}):this.mapView.ui.remove(this._basemapElement.basemapWidget)}async _showFloorFilterWatchHandler(t){const i=this._floorFilterElement.floorFilterWidget;t?this.mapView.ui.add(i,{position:this.position,index:1}):this.mapView.ui.remove(i)}async _showFullscreenWatchHandler(t){const i=this._fullscreenElement.fullscreenWidget;t?"ready"===i.viewModel.state&&i.viewModel.enter():"active"===i.viewModel.state&&i.viewModel.exit()}async _showLegendWidgetWatchHandler(t){t?this.mapView.ui.add(this._legendElement.legendWidget,{position:this.position,index:1}):this.mapView.ui.remove(this._legendElement.legendWidget)}async _showSearchWidgetWatchHandler(t){t?this.mapView.ui.add(this._searchElement.searchWidget,{position:this.position,index:1}):this.mapView.ui.remove(this._searchElement.searchWidget)}async componentWillLoad(){await this._getTranslations(),await this._initModules()}render(){this._setZoomToolsSize();const t=this._showTools?"":"display-none",i=this._showSearchWidget?"":"display-none",a=this._showBasemapWidget?"":"display-none",h=this._showLegendWidget?"":"display-none",n=this._showFloorFilter?"":"display-none",o=this._showFullscreen?"":"display-none",c=this.enableSingleExpand?"margin-top-1-2":"",r=this.toolOrder?this.toolOrder:["legend","search","fullscreen","floorfilter"],l=this.stackTools?"box-shadow":"";return s(e,{key:"a1557491ffd833bed11843dbe1bd040a9d2d6b15"},s("div",{key:"8866b3bc6e05fa75605b078e1a3deecaf6392024",class:this.enableBasemap||this.enableFullscreen||this.enableLegend||this.enableSearch?"":"display-none"},this.enableSingleExpand?s("div",{class:"box-shadow"},this._getActionGroup(this._showTools?"chevrons-up":"chevrons-down",!1,this._showTools?this._translations.collapse:this._translations.expand,(()=>this._toggleTools()))):void 0,s("div",{key:"6a4e62ad1afcca39365aa965ffabedf8933051d4",class:`${c} ${l} ${t}`},this._getMapWidgets(r))),s("basemap-gallery",{key:"4edade9536c0912a89f6a9335ae05ae46669e14d",basemapConfig:this.basemapConfig,class:a,mapView:this.mapView,ref:t=>{this._basemapElement=t}}),s("map-search",{key:"046d02c1927def025294645c6e855906fabd30aa",class:i,mapView:this.mapView,ref:t=>{this._searchElement=t},resultGraphicEnabled:!0,searchConfiguration:this.searchConfiguration}),s("map-legend",{key:"54575e31073bdc68b611939eb0e619e4479b26f3",class:h,mapView:this.mapView,ref:t=>{this._legendElement=t}}),s("map-fullscreen",{key:"9a54a22e12c372dd85717f83cf31b4ace80489eb",class:o,mapView:this.mapView,onFullscreenStateChange:t=>this._fullscreenStateChange(t.detail),ref:t=>{this._fullscreenElement=t}}),s("floor-filter",{key:"ffadf501a03186ed6f2fec8754cd758faea5b4dd",class:n,enabled:this.enableFloorFilter,mapView:this.mapView,ref:t=>{this._floorFilterElement=t}}))}async _initModules(){const[t]=await h(["esri/widgets/Expand"]);this.Expand=t}_setZoomToolsSize(){const t=document.getElementsByClassName("esri-zoom")[0]?.children[0],i=document.getElementsByClassName("esri-zoom")[0]?.children[1];if(t&&i){const s="s"===this.homeZoomToolsSize?"32px":"m"===this.homeZoomToolsSize?"40px":"48px";t.style.width=s,t.style.height=s,i.style.width=s,i.style.height=s}}_getMapWidgets(t){const i=this._showFullscreen?"full-screen-exit":"full-screen",s=this._showFullscreen?this._translations.exitFullscreen:this._translations.enterFullscreen;return t.map((t=>{switch(t){case"legend":return this.enableLegend&&this.enableSingleExpand?this._getActionGroup("legend",!1,this._translations.legend,(()=>this._showLegend())):this.enableLegend?this._getWidget(t,this._legendElement?.legendWidget,!0):void 0;case"search":return this.enableSearch&&this.enableSingleExpand?this._getActionGroup("magnifying-glass",!1,this._translations.search,(()=>this._search())):this.enableSearch?this._getWidget(t,this._searchElement?.searchWidget,!0):void 0;case"fullscreen":return this.enableFullscreen&&this.enableSingleExpand?this._getActionGroup(i,!1,s,(()=>this._expand())):this.enableFullscreen?this._getWidget(t,this._fullscreenElement?.fullscreenWidget,!1):void 0;case"basemap":return this.enableBasemap&&this.enableSingleExpand?this._getActionGroup("basemap",!1,this._translations.basemap,(()=>this._toggleBasemapPicker())):this.enableBasemap?this._getWidget(t,this._basemapElement?.basemapWidget,!0):void 0;case"floorfilter":return this.enableFloorFilter&&this._hasFloorInfo&&this.enableSingleExpand?this._getActionGroup("urban-model",!1,this._translations.floorFilter,(()=>this._toggleFloorFilter())):this.enableFloorFilter&&this._hasFloorInfo?this._getWidget(t,this._floorFilterElement?.floorFilterWidget,!0):void 0}}))}_fullscreenStateChange(t){"ready"===t&&this._showFullscreen?this._showFullscreen=!1:"active"!==t||this._showFullscreen||(this._showFullscreen=!0)}_getActionGroup(t,i,e,a){return s("div",null,s("calcite-action",{alignment:"center",class:`${"s"===this.mapWidgetsSize?"square-32":"m"===this.mapWidgetsSize?"square-40":"square-48"} ${this.stackTools?"":"margin-bottom-1-2"} border-bottom ${this.stackTools?"":"box-shadow"}`,compact:!1,disabled:i,icon:t,id:t,onClick:a,scale:"s",text:""},s("calcite-icon",{icon:"cheveron-up",scale:"s",slot:"icon"})),s("calcite-tooltip",{label:"",placement:"trailing","reference-element":t},s("span",null,e)))}_getWidget(t,i,s){if(this._widgets.indexOf(t)<0&&this.mapView&&i){const e=this.toolOrder.indexOf(t),a=new this.Expand({view:this.mapView,content:i});this.mapView.ui.add(s?a:i,{position:this.position,index:e>-1?e+(this.enableHome?2:1):1}),this._widgets.push(t)}}_showLegend(){this._showLegendWidget=!this._showLegendWidget,this._showTools=!1}_search(){this._showSearchWidget=!this._showSearchWidget,this._showTools=!1}_toggleBasemapPicker(){this._showBasemapWidget=!this._showBasemapWidget,this._showTools=!1}_toggleFloorFilter(){this._showFloorFilter=!this._showFloorFilter,this._showTools=!1}_expand(){this._showFullscreen=!this._showFullscreen}_toggleTools(){this._showTools||(this._showBasemapWidget=!1,this._showSearchWidget=!1,this._showLegendWidget=!1,this._showFloorFilter=!1),this._showTools=!this._showTools}async _getTranslations(){const t=await n(this.el);this._translations=t[0]}static get watchers(){return{mapView:["mapViewWatchHandler"],_showBasemapWidget:["_showBasemapWidgetWatchHandler"],_showFloorFilter:["_showFloorFilterWatchHandler"],_showFullscreen:["_showFullscreenWatchHandler"],_showLegendWidget:["_showLegendWidgetWatchHandler"],_showSearchWidget:["_showSearchWidgetWatchHandler"]}}};m.style=":host{display:block}.display-none{display:none}.margin-top-1-2{margin-top:0.5rem}.square-32{width:32px;height:32px}.square-40{width:40px;height:40px}.square-48{width:48px;height:48px}.width-40{width:40px}.square-40-41{width:40px;height:41px}.border-bottom{border-bottom:1px solid var(--calcite-color-border-3)}.box-shadow{box-shadow:0 1px 2px rgba(0, 0, 0, 0.3)}.margin-bottom-1-2{margin-bottom:0.5rem}";export{o as basemap_gallery,c as floor_filter,r as map_fullscreen,l as map_legend,d as map_picker,p as map_search,m as map_tools}
@@ -1,23 +0,0 @@
1
- /*!
2
- * Copyright 2022 Esri
3
- * Licensed under the Apache License, Version 2.0
4
- * http://www.apache.org/licenses/LICENSE-2.0
5
- */
6
- import{h as t,r as i,c as e,H as s,g as a,f as n}from"./p-f4c4a2b7.js";import{d as l}from"./p-e3196917.js";import{f as o,e as h}from"./p-262e91ea.js";import{D as r,E as c,t as d,i as p,v as m}from"./p-8448b98b.js";import{d as u,f as b,c as f,r as g,a as v,F as x}from"./p-583ecbf6.js";import{s as k,c as y,a as w,d as $,H as C}from"./p-7c585a72.js";import{g as _}from"./p-0ae5f8fe.js";import{c as z,u as I,d as M,I as V}from"./p-ec561560.js";import{c as H,d as S,g as L}from"./p-d7ee860a.js";import{b as D,c as A,s as E,a as j}from"./p-f83c0ef6.js";import{c as P,d as T,n as F}from"./p-16d69510.js";import{c as O}from"./p-2327029a.js";import{o as X}from"./p-cd4d69c1.js";import{D as R}from"./p-a8e556aa.js";import{c as W,s as B,d as G,u as U}from"./p-d4e3e979.js";import{g as N,c as Z}from"./p-bb3ce613.js";import{V as K}from"./p-cfca5772.js";import{i as Y,h as q,C as J,b as Q,c as tt,d as it,e as et,f as st,j as at}from"./p-ee056d26.js";import{d as nt}from"./p-c8d3207e.js";import{i as lt}from"./p-4250bde1.js";import{d as ot,c as ht}from"./p-33447b6f.js";import"./p-73ae4b9b.js";
7
- /*!
8
- * All material copyright ESRI, All Rights Reserved, unless otherwise specified.
9
- * See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
10
- * v2.11.1
11
- */const rt="x-button";function ct({disabled:i,key:e,label:s,onClick:a,ref:n,scale:l}){return t("button",{"aria-label":s,class:rt,disabled:i,key:e,onClick:a,ref:n,tabIndex:-1,type:"button"},t("calcite-icon",{icon:"x",scale:N(l)}))}const dt="combobox-item-",pt="combobox-chip-",mt="combobox-label-",ut="combobox-listbox-",bt="combobox-input-",ft=class{constructor(t){i(this,t),this.calciteComboboxChange=e(this,"calciteComboboxChange",6),this.calciteComboboxFilterChange=e(this,"calciteComboboxFilterChange",6),this.calciteComboboxChipClose=e(this,"calciteComboboxChipClose",6),this.calciteComboboxBeforeClose=e(this,"calciteComboboxBeforeClose",6),this.calciteComboboxClose=e(this,"calciteComboboxClose",6),this.calciteComboboxBeforeOpen=e(this,"calciteComboboxBeforeOpen",6),this.calciteComboboxOpen=e(this,"calciteComboboxOpen",6),this.placement=u,this.internalValueChangeFlag=!1,this.textInput=null,this.mutationObserver=O("mutation",(()=>this.updateItems())),this.resizeObserver=O("resize",(()=>{this.setMaxScrollerHeight(),this.refreshSelectionDisplay()})),this.guid=_(),this.inputHeight=0,this.ignoreSelectedEventsFlag=!1,this.openTransitionProp="opacity",this.setFilteredPlacements=()=>{const{el:t,flipPlacements:i}=this;this.filteredFlipPlacements=i?b(i,t):null},this.getValue=()=>{const t=this.selectedItems.map((t=>t?.value?.toString()));return t?.length?t.length>1?t:t[0]:""},this.onLabelClick=()=>{this.setFocus()},this.keyDownHandler=t=>{if(this.readOnly)return;const{key:i}=t;switch(i){case"Tab":this.activeChipIndex=-1,this.activeItemIndex=-1,this.allowCustomValues&&this.filterText?(this.addCustomChip(this.filterText,!0),t.preventDefault()):this.open?(this.open=!1,t.preventDefault()):!this.allowCustomValues&&this.filterText&&(this.clearInputValue(),this.filterItems(""),this.updateActiveItemIndex(-1));break;case"ArrowLeft":-1===this.activeChipIndex&&0!==this.textInput.selectionStart||(this.previousChip(),t.preventDefault());break;case"ArrowRight":-1!==this.activeChipIndex&&(this.nextChip(),t.preventDefault());break;case"ArrowUp":this.filteredItems.length&&(t.preventDefault(),this.open&&this.shiftActiveItemIndex(-1),this.comboboxInViewport()||this.el.scrollIntoView());break;case"ArrowDown":this.filteredItems.length&&(t.preventDefault(),this.open?this.shiftActiveItemIndex(1):(this.open=!0,this.ensureRecentSelectedItemIsActive()),this.comboboxInViewport()||this.el.scrollIntoView());break;case" ":this.textInput.value||t.defaultPrevented||(this.open||(this.open=!0,this.shiftActiveItemIndex(1)),t.preventDefault());break;case"Home":if(!this.open)return;t.preventDefault(),this.updateActiveItemIndex(0),this.scrollToActiveItem(),this.comboboxInViewport()||this.el.scrollIntoView();break;case"End":if(!this.open)return;t.preventDefault(),this.updateActiveItemIndex(this.filteredItems.length-1),this.scrollToActiveItem(),this.comboboxInViewport()||this.el.scrollIntoView();break;case"Escape":this.clearDisabled||this.open||this.clearValue(),this.open=!1,t.preventDefault();break;case"Enter":this.open&&this.activeItemIndex>-1?(this.toggleSelection(this.filteredItems[this.activeItemIndex]),t.preventDefault()):this.activeChipIndex>-1?(this.removeActiveChip(),t.preventDefault()):this.allowCustomValues&&this.filterText?(this.addCustomChip(this.filterText,!0),t.preventDefault()):t.defaultPrevented||k(this)&&t.preventDefault();break;case"Delete":case"Backspace":if("single"===this.selectionDisplay||"fit"===this.selectionDisplay&&this.selectedHiddenChipsCount>0)return;this.activeChipIndex>-1?(t.preventDefault(),this.removeActiveChip()):!this.filterText&&this.isMulti()&&(t.preventDefault(),this.removeLastChip())}},this.toggleCloseEnd=()=>{this.open=!1,this.el.removeEventListener("calciteComboboxClose",this.toggleCloseEnd)},this.toggleOpenEnd=()=>{this.open=!1,this.el.removeEventListener("calciteComboboxOpen",this.toggleOpenEnd)},this.setMaxScrollerHeight=async()=>{const{listContainerEl:t,open:i,referenceEl:e}=this;if(!t||!i)return;await this.reposition(!0);const s=this.getMaxScrollerHeight();t.style.maxHeight=s>0?`${s}px`:"",t.style.minWidth=`${e.clientWidth}px`,await this.reposition(!0)},this.calciteChipCloseHandler=t=>{this.open=!1;const i=this.items.find((i=>i===t));i&&this.toggleSelection(i,!1),this.calciteComboboxChipClose.emit()},this.clickHandler=t=>{if(this.readOnly)return;const i=t.composedPath();return i.some((t=>"CALCITE-CHIP"===t.tagName))?(this.open=!1,void t.preventDefault()):i.some((t=>t.classList?.contains(rt)))?(this.clearValue(),void t.preventDefault()):(this.open=!this.open,void this.ensureRecentSelectedItemIsActive())},this.refreshSelectionDisplay=async()=>{if(await D(this),Y(this.selectionMode))return;if(!this.textInput)return;const{allSelectedIndicatorChipEl:t,chipContainerEl:i,selectionDisplay:e,placeholder:s,selectedIndicatorChipEl:a,textInput:n}=this,o=parseInt(getComputedStyle(i).gap.replace("px","")),h=r(i),{fontSize:d,fontFamily:p}=getComputedStyle(n),m=(c(s,`${d} ${p}`)||parseInt(l))+o,u=r(t),b=r(a),f=Math.max(u,b);if(this.setCompactSelectionDisplay({chipContainerElGap:o,chipContainerElWidth:h,inputWidth:m,largestSelectedIndicatorChipWidth:f}),"fit"===e){const t=Array.from(this.el.shadowRoot.querySelectorAll("calcite-chip")).filter((t=>t.closable)),i=Math.round(h-((this.selectedHiddenChipsCount>0?b:0)+o+m+o));this.refreshChipDisplay({availableHorizontalChipElSpace:i,chipContainerElGap:o,chipEls:t}),this.setVisibleAndHiddenChips(t)}},this.setFloatingEl=t=>{this.floatingEl=t,f(this,this.referenceEl,this.floatingEl)},this.setContainerEl=t=>{this.resizeObserver.observe(t),this.listContainerEl=t,this.transitionEl=t},this.setChipContainerEl=t=>{this.resizeObserver.observe(t),this.chipContainerEl=t},this.setReferenceEl=t=>{this.referenceEl=t,f(this,this.referenceEl,this.floatingEl)},this.setAllSelectedIndicatorChipEl=t=>{this.allSelectedIndicatorChipEl=t},this.setSelectedIndicatorChipEl=t=>{this.selectedIndicatorChipEl=t},this.inputHandler=t=>{this.filterText=t.target.value},this.filterItems=(()=>{const t=(t,i)=>t&&i.some((({label:i,value:e})=>t.tagName===at?i===t.label:e===t.value&&i===t.textLabel));return nt(((i,e=!1,s=!0)=>{const a=o(this.data,i),n=this.getItemsAndGroups(),l=""===i;n.forEach((i=>{if(l)return void(i.hidden=!1);const e=!t(i,a);i.hidden=e;const[s,n]=i.ancestors;(t(s,a)||t(n,a))&&(i.hidden=!1),e||i.ancestors.forEach((t=>t.hidden=!1))})),this.filterTextMatchPattern=this.filterText&&new RegExp(`(${h(this.filterText)})`,"i"),this.filteredItems=this.getFilteredItems(),this.filteredItems.forEach((t=>{t.filterTextMatchPattern=this.filterTextMatchPattern})),e&&(this.open=this.filterText.trim().length>0&&this.filteredItems.length>0),s&&this.calciteComboboxFilterChange.emit()}),R.filter)})(),this.internalComboboxChangeEvent=()=>{this.calciteComboboxChange.emit()},this.emitComboboxChange=nt(this.internalComboboxChangeEvent,0),this.getSelectedItems=()=>{if(!this.isMulti()){const t=this.items.find((({selected:t})=>t));return t?[t]:[]}return this.items.filter((t=>t.selected&&("ancestors"!==this.selectionMode||!q(t)))).sort(((t,i)=>{const e=this.selectedItems.indexOf(t),s=this.selectedItems.indexOf(i);return e>-1&&s>-1?e-s:s-e}))},this.updateItems=()=>{this.items=this.getItems(),this.groupItems=this.getGroupItems(),this.data=this.getData(),this.selectedItems=this.getSelectedItems(),this.filteredItems=this.getFilteredItems(),this.needsIcon=this.getNeedsIcon(),this.items.forEach((t=>{t.selectionMode=this.selectionMode,t.scale=this.scale})),this.allowCustomValues||this.setMaxScrollerHeight(),this.groupItems.forEach(((t,i,e)=>{0===i&&(t.afterEmptyGroup=!1);const s=e[i+1];s&&(s.afterEmptyGroup=0===t.children.length)}))},this.scrollToActiveItem=()=>{const t=this.filteredItems[this.activeItemIndex];if(!t)return;const i=this.calculateScrollerHeight(t),{offsetHeight:e,scrollTop:s}=this.listContainerEl;e+s<t.offsetTop+i?this.listContainerEl.scrollTop=t.offsetTop-e+i:t.offsetTop<s&&(this.listContainerEl.scrollTop=t.offsetTop)},this.comboboxFocusHandler=()=>{this.disabled||this.textInput?.focus()},this.clearDisabled=!1,this.filterText="",this.selectionDisplay="all",this.open=!1,this.disabled=!1,this.form=void 0,this.label=void 0,this.placeholder=void 0,this.placeholderIcon=void 0,this.placeholderIconFlipRtl=!1,this.maxItems=0,this.validationMessage=void 0,this.validationIcon=void 0,this.validity={valid:!1,badInput:!1,customError:!1,patternMismatch:!1,rangeOverflow:!1,rangeUnderflow:!1,stepMismatch:!1,tooLong:!1,tooShort:!1,typeMismatch:!1,valueMissing:!1},this.name=void 0,this.allowCustomValues=void 0,this.overlayPositioning="absolute",this.required=!1,this.selectionMode="multiple",this.scale="m",this.status="idle",this.value=null,this.flipPlacements=void 0,this.messages=void 0,this.messageOverrides=void 0,this.selectedItems=[],this.filteredItems=[],this.readOnly=!1,this.items=[],this.groupItems=[],this.needsIcon=void 0,this.activeItemIndex=-1,this.activeChipIndex=-1,this.activeDescendant="",this.compactSelectionDisplay=!1,this.selectedHiddenChipsCount=0,this.selectedVisibleChipsCount=0,this.effectiveLocale=void 0,this.defaultMessages=void 0}filterTextChange(t){this.updateActiveItemIndex(-1),this.filterItems(t,!0)}openHandler(){X(this),this.disabled?this.open=!1:this.setMaxScrollerHeight()}handleDisabledChange(t){t||(this.open=!1)}maxItemsHandler(){this.setMaxScrollerHeight()}overlayPositioningHandler(){this.reposition(!0)}handlePropsChange(){this.updateItems()}valueHandler(t){if(!this.internalValueChangeFlag){const i=this.getItems();Array.isArray(t)?i.forEach((i=>i.selected=t.includes(i.value))):i.forEach(t?i=>i.selected=t===i.value:t=>t.selected=!1),this.updateItems()}}onMessagesChange(){}flipPlacementsHandler(){this.setFilteredPlacements(),this.reposition(!0)}selectedItemsHandler(){this.internalValueChangeFlag=!0,this.value=this.getValue(),this.internalValueChangeFlag=!1}async documentClickHandler(t){this.disabled||t.composedPath().includes(this.el)||(await Z(this.el),!this.allowCustomValues&&this.filterText&&(this.clearInputValue(),this.filterItems(""),this.updateActiveItemIndex(-1)),this.allowCustomValues&&this.filterText.trim().length&&this.addCustomChip(this.filterText),this.open=!1)}calciteComboboxItemChangeHandler(t){if(this.ignoreSelectedEventsFlag)return;const i=t.target,e=this.filteredItems.indexOf(i);this.updateActiveItemIndex(e),this.toggleSelection(i,i.selected)}async reposition(t=!1){const{floatingEl:i,referenceEl:e,placement:s,overlayPositioning:a,filteredFlipPlacements:n}=this;return g(this,{floatingEl:i,referenceEl:e,overlayPositioning:a,placement:s,flipPlacements:n,type:"menu"},t)}async setFocus(){await A(this),this.textInput?.focus(),this.activeChipIndex=-1,this.activeItemIndex=-1}connectedCallback(){z(this),P(this),W(this),H(this),y(this),this.internalValueChangeFlag=!0,this.value=this.getValue(),this.internalValueChangeFlag=!1,this.mutationObserver?.observe(this.el,{childList:!0,subtree:!0}),this.updateItems(),this.setFilteredPlacements(),this.open&&(this.openHandler(),X(this)),f(this,this.referenceEl,this.floatingEl)}async componentWillLoad(){E(this),this.updateItems(),await B(this),this.filterItems(this.filterText,!1,!1)}componentDidLoad(){w(this,this.getValue()),f(this,this.referenceEl,this.floatingEl),j(this)}componentDidRender(){this.el.offsetHeight!==this.inputHeight&&(this.reposition(!0),this.inputHeight=this.el.offsetHeight),I(this)}componentDidUpdate(){this.refreshSelectionDisplay()}disconnectedCallback(){this.mutationObserver?.disconnect(),this.resizeObserver?.disconnect(),M(this),S(this),$(this),v(this,this.referenceEl,this.floatingEl),T(this),G(this)}effectiveLocaleChange(){U(this,this.effectiveLocale)}clearValue(){this.ignoreSelectedEventsFlag=!0,this.items.forEach((t=>t.selected=!1)),this.ignoreSelectedEventsFlag=!1,this.selectedItems=[],this.emitComboboxChange(),this.open=!1,this.updateActiveItemIndex(-1),this.resetText(),this.filterItems(""),this.setFocus()}clearInputValue(){this.textInput.value="",this.filterText=""}comboboxInViewport(){const t=this.el.getBoundingClientRect();return t.top>=0&&t.left>=0&&t.right<=(window.innerWidth||document.documentElement.clientWidth)&&t.bottom<=(window.innerHeight||document.documentElement.clientHeight)}onBeforeOpen(){this.scrollToActiveItem(),this.calciteComboboxBeforeOpen.emit()}onOpen(){this.calciteComboboxOpen.emit()}onBeforeClose(){this.calciteComboboxBeforeClose.emit()}onClose(){this.calciteComboboxClose.emit()}ensureRecentSelectedItemIsActive(){const{selectedItems:t}=this,i=0===t.length?0:this.items.indexOf(t[t.length-1]);this.updateActiveItemIndex(i)}hideChip(t){t.classList.add(J.chipInvisible)}showChip(t){t.classList.remove(J.chipInvisible)}refreshChipDisplay({chipEls:t,availableHorizontalChipElSpace:i,chipContainerElGap:e}){t.forEach((t=>{if(t.selected){const s=r(t);if(s&&s<i)return i-=s+e,void this.showChip(t)}else this.hideChip(t);this.hideChip(t)}))}setCompactSelectionDisplay({chipContainerElGap:t,chipContainerElWidth:i,inputWidth:e,largestSelectedIndicatorChipWidth:s}){const a=Math.round(s+t+e);(!this.maxCompactBreakpoint||this.maxCompactBreakpoint<a)&&(this.maxCompactBreakpoint=a),this.compactSelectionDisplay=i<this.maxCompactBreakpoint}setVisibleAndHiddenChips(t){let i=0;t.forEach((t=>{t.selected&&!t.classList.contains(J.chipInvisible)&&i++})),i!==this.selectedVisibleChipsCount&&(this.selectedVisibleChipsCount=i);const e=this.getSelectedItems().length-i;e!==this.selectedHiddenChipsCount&&(this.selectedHiddenChipsCount=e)}getMaxScrollerHeight(){const t=this.getItemsAndGroups().filter((t=>!t.hidden)),{maxItems:i}=this;let e=0,s=0;return t.length>i&&t.forEach((t=>{if(e<i){const i=this.calculateScrollerHeight(t);i>0&&(s+=i,e++)}})),s}calculateScrollerHeight(t){if(t)return t.getBoundingClientRect().height-Array.from(t.querySelectorAll(Q)).reduce(((t,i)=>t+i.getBoundingClientRect().height),0)}getItemsAndGroups(){return[...this.groupItems,...this.items]}toggleSelection(t,i=!t.selected){!t||"single-persist"===this.selectionMode&&t.selected&&t.value===this.value||(this.isMulti()?(t.selected=i,this.updateAncestors(t),this.selectedItems=this.getSelectedItems(),this.emitComboboxChange(),this.resetText(),this.filterItems("")):(this.ignoreSelectedEventsFlag=!0,this.items.forEach((e=>e.selected=e===t&&i)),this.ignoreSelectedEventsFlag=!1,this.selectedItems=this.getSelectedItems(),this.emitComboboxChange(),this.textInput&&(this.textInput.value=tt(t)),this.open=!1,this.updateActiveItemIndex(-1),this.resetText(),this.filterItems("")))}updateAncestors(t){if("ancestors"!==this.selectionMode)return;const i=it(t),e=et(t);t.selected?i.forEach((t=>{t.selected=!0})):(e.forEach((t=>t.selected=!1)),[...i].forEach((t=>{q(t)||(t.selected=!1)})))}getFilteredItems(){return""===this.filterText?this.items:this.items.filter((t=>!t.hidden))}getData(){return this.items.map((t=>({description:t.description,filterDisabled:t.filterDisabled,label:t.textLabel,metadata:t.metadata,shortHeading:t.shortHeading,value:t.value})))}getNeedsIcon(){return Y(this.selectionMode)&&this.items.some((t=>t.icon))}resetText(){this.textInput&&(this.textInput.value=""),this.filterText=""}getItems(){return Array.from(this.el.querySelectorAll(st)).filter((t=>!t.disabled))}getGroupItems(){return Array.from(this.el.querySelectorAll(at))}addCustomChip(t,i){const e=this.items.find((i=>i.textLabel===t));if(e)this.toggleSelection(e,!0);else{this.isMulti()||this.toggleSelection(this.selectedItems[this.selectedItems.length-1],!1);const e=document.createElement("calcite-combobox-item");e.value=t,e.textLabel=t,e.selected=!0,this.el.prepend(e),this.resetText(),i&&this.setFocus(),this.updateItems(),this.filterItems(""),this.open=!0,this.emitComboboxChange()}}removeActiveChip(){this.toggleSelection(this.selectedItems[this.activeChipIndex],!1),this.setFocus()}removeLastChip(){this.toggleSelection(this.selectedItems[this.selectedItems.length-1],!1),this.setFocus()}previousChip(){const t=this.activeChipIndex;this.activeChipIndex=-1===t?this.selectedItems.length-1:Math.max(t-1,0),this.updateActiveItemIndex(-1),this.focusChip()}nextChip(){const t=this.activeChipIndex+1;t>this.selectedItems.length-1?(this.activeChipIndex=-1,this.setFocus()):(this.activeChipIndex=t,this.focusChip()),this.updateActiveItemIndex(-1)}focusChip(){const t=this.selectedItems[this.activeChipIndex]?.guid,i=t?this.referenceEl.querySelector(`#${pt}${t}`):null;i?.setFocus()}shiftActiveItemIndex(t){const{length:i}=this.filteredItems;this.updateActiveItemIndex((this.activeItemIndex+i+t)%i),this.scrollToActiveItem()}updateActiveItemIndex(t){this.activeItemIndex=t;let i=null;this.filteredItems.forEach(((e,s)=>{s===t?(e.active=!0,i=`${dt}${e.guid}`):e.active=!1})),this.activeDescendant=i,this.activeItemIndex>-1&&(this.activeChipIndex=-1)}isAllSelected(){return this.getItems().length===this.getSelectedItems().length}isMulti(){return!Y(this.selectionMode)}renderChips(){const{activeChipIndex:i,readOnly:e,scale:s,selectionMode:a,messages:n}=this;return this.selectedItems.map(((l,o)=>{const h={chip:!0,"chip--active":i===o},r=[...it(l)].reverse(),c=tt(l),d=[...r,l].map((t=>tt(t))),p="ancestors"!==a?c:d.join(" / ");return t("calcite-chip",{appearance:e?"outline":"solid",class:h,closable:!e,"data-test-id":`chip-${o}`,icon:l.icon,iconFlipRtl:l.iconFlipRtl,id:l.guid?`${pt}${l.guid}`:null,key:c,messageOverrides:{dismissLabel:n.removeTag},onCalciteChipClose:()=>this.calciteChipCloseHandler(l),onFocusin:()=>this.activeChipIndex=o,scale:s,selected:l.selected,tabindex:i===o?0:-1,title:p,value:l.value},p)}))}renderAllSelectedIndicatorChip(){const{compactSelectionDisplay:i,scale:e,selectedVisibleChipsCount:s,setAllSelectedIndicatorChipEl:a}=this,n=this.messages.allSelected;return t("calcite-chip",{class:{chip:!0,[J.chipInvisible]:!(this.isAllSelected()&&!s&&!i)},ref:a,scale:e,title:n,value:""},n)}renderAllSelectedIndicatorChipCompact(){const{compactSelectionDisplay:i,scale:e,selectedVisibleChipsCount:s}=this,a=this.messages.all||"All";return t("calcite-chip",{class:{chip:!0,[J.chipInvisible]:!(this.isAllSelected()&&!s&&i)},scale:e,title:a,value:""},a)}renderSelectedIndicatorChip(){const{compactSelectionDisplay:i,selectionDisplay:e,getSelectedItems:s,scale:a,selectedHiddenChipsCount:n,selectedVisibleChipsCount:l,setSelectedIndicatorChipEl:o}=this;let h,r;if(i)h=!0;else if("single"===e){const t=s().length;h=!(!this.isAllSelected()&&t>0),r=`${t} ${this.messages.selected}`}else"fit"===e&&(h=!!(this.isAllSelected()&&0===l||0===n),r=l>0?`+${n}`:`${n} ${this.messages.selected}`);return t("calcite-chip",{class:{chip:!0,[J.chipInvisible]:h},ref:o,scale:a,title:r,value:""},r)}renderSelectedIndicatorChipCompact(){const{compactSelectionDisplay:i,selectionDisplay:e,getSelectedItems:s,scale:a,selectedHiddenChipsCount:n}=this;let l,o;if(i){const t=s().length;this.isAllSelected()?l=!0:"fit"===e?(l=!(n>0),o=`${n||0}`):"single"===e&&(l=!(t>0),o=`${t}`)}else l=!0;return t("calcite-chip",{class:{chip:!0,[J.chipInvisible]:l},scale:a,title:o,value:""},o)}get showingInlineIcon(){const{placeholderIcon:t,selectionMode:i,selectedItems:e,open:s}=this,a=e[0],n=a?.icon,l=Y(i);return!s&&a?!!n&&l:!!t&&(!a||l)}renderInput(){const{guid:i,disabled:e,placeholder:s,selectionMode:a,selectedItems:n,open:l}=this,o=Y(a),h=n[0],r=!l&&o&&!!h;return t("span",{class:{"input-wrap":!0,"input-wrap--single":o}},r&&t("span",{class:{label:!0,"label--icon":!!h?.icon},key:"label"},tt(h)),t("input",{"aria-activedescendant":this.activeDescendant,"aria-autocomplete":"list","aria-controls":`${ut}${i}`,"aria-expanded":d(l),"aria-haspopup":"listbox","aria-label":L(this),"aria-owns":`${ut}${i}`,class:{[J.input]:!0,"input--single":!0,"input--hidden":r,"input--icon":this.showingInlineIcon&&!!this.placeholderIcon},"data-test-id":"input",disabled:e,id:`${bt}${i}`,key:"input",onFocus:this.comboboxFocusHandler,onInput:this.inputHandler,placeholder:s,readOnly:this.readOnly,ref:t=>this.textInput=t,role:"combobox",tabindex:-1===this.activeChipIndex?0:-1,type:"text",value:this.filterText}))}renderListBoxOptions(){return this.filteredItems.map((i=>t("li",{"aria-selected":d(i.selected),id:i.guid?`${dt}${i.guid}`:null,role:"option",tabindex:"-1"},i.textLabel)))}renderFloatingUIContainer(){const{setFloatingEl:i,setContainerEl:e,open:s}=this;return t("div",{"aria-hidden":"true",class:{"floating-ui-container":!0,"floating-ui-container--active":s},ref:i},t("div",{class:{[J.listContainer]:!0,[x.animation]:!0,[x.animationActive]:s},ref:e},t("ul",{class:{list:!0,"list--hide":!s}},t("slot",null))))}renderSelectedOrPlaceholderIcon(){const{selectedItems:i,placeholderIcon:e,placeholderIconFlipRtl:s}=this,a=i[0],n=a?.icon;return this.showingInlineIcon&&t("span",{class:"icon-start",key:"selected-placeholder-icon"},t("calcite-icon",{class:"selected-icon",flipRtl:this.open&&a?a.iconFlipRtl:s,icon:!this.open&&a?n:e,scale:N(this.scale)}))}renderChevronIcon(){const{open:i}=this;return t("span",{class:"icon-end",key:"chevron"},t("calcite-icon",{class:J.icon,icon:i?"chevron-up":"chevron-down",scale:N(this.scale)}))}render(){const{selectionDisplay:i,guid:e,label:a,open:n,readOnly:l}=this,o=Y(this.selectionMode),h="all"===i,r="single"===i,c=!o&&"fit"===i,d=!this.clearDisabled&&this.value?.length>0;return t(s,{key:"c51466b3ff7d6aaf29578ba9a017cab02b49d704",onClick:this.comboboxFocusHandler},t(V,{key:"5c1e3383be919a3348677607b46f79a8baefeee7",disabled:this.disabled},t("div",{key:"ffb0ee17748ed4827cfca2c8aea8f39fc82a05cc","aria-live":"polite",class:{wrapper:!0,"wrapper--single":o||!this.selectedItems.length,"wrapper--active":n},onClick:this.clickHandler,onKeyDown:this.keyDownHandler,ref:this.setReferenceEl},this.renderSelectedOrPlaceholderIcon(),t("div",{class:{"grid-input":!0,[J.selectionDisplayFit]:c,[J.selectionDisplaySingle]:r},key:"grid",ref:this.setChipContainerEl},!o&&!r&&this.renderChips(),!o&&!h&&[this.renderSelectedIndicatorChip(),this.renderSelectedIndicatorChipCompact(),this.renderAllSelectedIndicatorChip(),this.renderAllSelectedIndicatorChipCompact()],t("label",{key:"d60ddc1697b80245c56fd7b553408beb21296b3d",class:"screen-readers-only",htmlFor:`${bt}${e}`,id:`${mt}${e}`},a),this.renderInput()),!l&&d?t(ct,{disabled:this.disabled,key:"close-button",label:this.messages.clear,scale:this.scale}):null,!l&&this.renderChevronIcon()),t("ul",{key:"856e6f4bd4fcf6db32fb6e8d984fcdb7c4776448","aria-labelledby":`${mt}${e}`,"aria-multiselectable":"true",class:"screen-readers-only",id:`${ut}${e}`,role:"listbox",tabIndex:-1},this.renderListBoxOptions()),this.renderFloatingUIContainer(),t(C,{key:"eca6c0108b0fbb8e6851c6cc86d15dc70318a4a3",component:this}),this.validationMessage&&"invalid"===this.status?t(K,{icon:this.validationIcon,message:this.validationMessage,scale:this.scale,status:this.status}):null))}static get assetsDirs(){return["assets"]}get el(){return a(this)}static get watchers(){return{filterText:["filterTextChange"],open:["openHandler"],disabled:["handleDisabledChange"],maxItems:["maxItemsHandler"],overlayPositioning:["overlayPositioningHandler"],selectionMode:["handlePropsChange"],scale:["handlePropsChange"],value:["valueHandler"],messageOverrides:["onMessagesChange"],flipPlacements:["flipPlacementsHandler"],selectedItems:["selectedItemsHandler"],effectiveLocale:["effectiveLocaleChange"]}}};function gt(t,i,e){const s=i[0]-t[0];return s?(3*(i[1]-t[1])/s-e)/2:e}function vt(t,i,e,s,a){const[n,l]=t,[o,h]=i,r=(o-n)/3;return`C ${a([n+r,l+r*e]).join(",")} ${a([o-r,h-r*s]).join(",")} ${a([o,h]).join(",")}`}ft.style=":host([disabled]){cursor:default;-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:var(--calcite-opacity-disabled)}:host([disabled]) *,:host([disabled]) ::slotted(*){pointer-events:none}:host{position:relative;display:block}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}.interaction-container{display:contents}:host([scale=s]) .x-button{inline-size:1rem;block-size:1rem}:host([scale=m]) .x-button{inline-size:1.5rem;block-size:1.5rem}:host([scale=l]) .x-button{inline-size:2rem;block-size:2rem}.x-button{margin:0px;display:flex;cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;align-content:center;align-items:center;justify-content:center;align-self:center;border-width:2px;background-color:transparent;color:var(--calcite-color-text-3);outline-color:transparent;transition:background-color, block-size, border-color, box-shadow, color, inset-block-end, inset-block-start, inset-inline-end, inset-inline-start inset-size, opacity, outline-color, transform var(--calcite-animation-timing) ease-in-out 0s, outline 0s, outline-offset 0s;border-radius:50%;border-color:transparent;background-color:var(--calcite-color-foreground-2)}.x-button:active,.x-button:hover{color:var(--calcite-color-text-1);background-color:var(--calcite-color-foreground-3)}.x-button:active{border-style:solid;border-color:var(--calcite-color-brand)}.x-button calcite-icon{color:inherit}:host([scale=s]){font-size:var(--calcite-font-size--2);--calcite-combobox-item-spacing-unit-l:0.5rem;--calcite-combobox-item-spacing-unit-s:0.25rem;--calcite-combobox-input-height:1rem;--calcite-internal-combobox-input-margin-block:calc(0.25rem - 1px)}:host([scale=s]) .x-button{margin-inline:0.5rem}:host([scale=m]){font-size:var(--calcite-font-size--1);--calcite-combobox-item-spacing-unit-l:0.75rem;--calcite-combobox-item-spacing-unit-s:0.5rem;--calcite-combobox-input-height:1rem;--calcite-internal-combobox-input-margin-block:calc(0.5rem - 1px)}:host([scale=m]) .x-button{margin-inline-end:0.75rem}:host([scale=l]){font-size:var(--calcite-font-size-0);--calcite-combobox-item-spacing-unit-l:1rem;--calcite-combobox-item-spacing-unit-s:0.75rem;--calcite-combobox-input-height:1.5rem;--calcite-internal-combobox-input-margin-block:calc(0.625rem - 1px)}:host([scale=l]) .x-button{margin-inline-end:1rem}.wrapper{display:flex;border-width:1px;border-style:solid;border-color:var(--calcite-color-border-input);background-color:var(--calcite-color-foreground-1);color:var(--calcite-color-text-1);outline-color:transparent;padding-block:calc(var(--calcite-combobox-item-spacing-unit-s) / 4);padding-inline:var(--calcite-combobox-item-spacing-unit-l)}.wrapper:hover .icon{color:var(--calcite-color-text-1)}:host(:focus-within) .wrapper,.wrapper--active{outline:2px solid var(--calcite-ui-focus-color, var(--calcite-color-brand));outline-offset:calc(\n -2px *\n calc(\n 1 -\n 2 * clamp(\n 0,\n var(--calcite-offset-invert-focus),\n 1\n )\n )\n )}:host([read-only]) .wrapper{background-color:var(--calcite-color-background)}:host([read-only]) .label{font-weight:var(--calcite-font-weight-medium)}:host([status=invalid]) .wrapper{border-color:var(--calcite-color-status-danger)}:host([status=invalid]:focus-within) .wrapper{outline:2px solid var(--calcite-color-status-danger);outline-offset:calc(\n -2px *\n calc(\n 1 -\n 2 * clamp(\n 0,\n var(--calcite-offset-invert-focus),\n 1\n )\n )\n )}.wrapper--single{padding-block:0;padding-inline:var(--calcite-combobox-item-spacing-unit-l);cursor:pointer;flex-wrap:nowrap}.grid-input{position:relative;display:flex;flex-grow:1;flex-wrap:wrap;align-items:center;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:0px;gap:var(--calcite-combobox-item-spacing-unit-s);margin-inline-end:var(--calcite-combobox-item-spacing-unit-s)}.grid-input.selection-display-fit,.grid-input.selection-display-single{flex-wrap:nowrap;overflow:hidden}.input{flex-grow:1;-webkit-appearance:none;-moz-appearance:none;appearance:none;overflow:hidden;text-overflow:ellipsis;border-style:none;background-color:transparent;padding:0px;font-family:inherit;color:var(--calcite-color-text-1);font-size:inherit;block-size:var(--calcite-combobox-input-height);line-height:var(--calcite-combobox-input-height);inline-size:100%;margin-block-end:var(--calcite-combobox-item-spacing-unit-s);min-inline-size:4.8125rem}.input:focus{outline:2px solid transparent;outline-offset:2px}.input:-moz-placeholder-shown{text-overflow:ellipsis}.input:placeholder-shown{text-overflow:ellipsis}.input--single{padding:0px;margin-block:var(--calcite-internal-combobox-input-margin-block)}.wrapper--active .input-single{cursor:text}.input--hidden{pointer-events:none;inline-size:0px;min-inline-size:0px;opacity:0}.input--icon{padding-block:0;padding-inline:var(--calcite-combobox-item-spacing-unit-l)}.input-wrap{display:flex;flex-grow:1;align-items:center}.input-wrap--single{flex:1 1 0%;overflow:hidden}.label{pointer-events:none;max-inline-size:100%;flex:1 1 auto;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:0px;font-weight:var(--calcite-font-weight-normal);block-size:var(--calcite-combobox-input-height);line-height:var(--calcite-combobox-input-height)}.label--icon{padding-inline:var(--calcite-combobox-item-spacing-unit-l)}.icon-end,.icon-start{display:flex;cursor:pointer;align-items:center}.icon-end{flex:none}.icon-end .icon{color:var(--calcite-color-text-3)}.floating-ui-container{--calcite-floating-ui-z-index:var(--calcite-z-index-dropdown);display:block;position:absolute;z-index:var(--calcite-floating-ui-z-index);visibility:hidden}.floating-ui-container .calcite-floating-ui-anim{position:relative;transition:var(--calcite-floating-ui-transition);transition-property:transform, visibility, opacity;opacity:0;box-shadow:0 0 16px 0 rgba(0, 0, 0, 0.16);z-index:var(--calcite-z-index);border-radius:0.25rem}.floating-ui-container[data-placement^=bottom] .calcite-floating-ui-anim{transform:translateY(-5px)}.floating-ui-container[data-placement^=top] .calcite-floating-ui-anim{transform:translateY(5px)}.floating-ui-container[data-placement^=left] .calcite-floating-ui-anim{transform:translateX(5px)}.floating-ui-container[data-placement^=right] .calcite-floating-ui-anim{transform:translateX(-5px)}.floating-ui-container[data-placement] .calcite-floating-ui-anim--active{opacity:1;transform:translate(0)}.floating-ui-container--active{visibility:visible}@media (forced-colors: active){.wrapper,.floating-ui-container--active{border:1px solid canvasText}}.screen-readers-only{position:absolute;inline-size:1px;block-size:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);white-space:nowrap;border-width:0}.list-container{max-block-size:45vh;overflow-y:auto;background-color:var(--calcite-color-foreground-1);inline-size:var(--calcite-dropdown-width)}.list{margin:0px;display:block;padding:0px}.list--hide{block-size:0px;overflow:hidden}calcite-chip{--calcite-animation-timing:0}.chip{margin-block:calc(var(--calcite-combobox-item-spacing-unit-s) / 4);max-inline-size:100%}.chip--active{background-color:var(--calcite-color-foreground-3)}.chip--invisible{visibility:hidden;position:absolute}.item{display:block}.validation-container{display:flex;flex-direction:column;align-items:flex-start;align-self:stretch}:host([scale=m]) .validation-container,:host([scale=l]) .validation-container{padding-block-start:0.5rem}:host([scale=s]) .validation-container{padding-block-start:0.25rem}::slotted(input[slot=hidden-form-input]){margin:0 !important;opacity:0 !important;outline:none !important;padding:0 !important;position:absolute !important;inset:0 !important;transform:none !important;-webkit-appearance:none !important;z-index:-1 !important}:host([hidden]){display:none}[hidden]{display:none}::slotted(calcite-combobox-item-group:not(:first-child)){padding-block-start:var(--calcite-combobox-item-spacing-unit-l)}";const xt=class{constructor(t){i(this,t),this.graphId=`calcite-graph-${_()}`,this.resizeObserver=O("resize",(()=>n(this))),this.data=[],this.colorStops=void 0,this.highlightMin=void 0,this.highlightMax=void 0,this.min=void 0,this.max=void 0}connectedCallback(){this.resizeObserver?.observe(this.el)}disconnectedCallback(){this.resizeObserver?.disconnect()}render(){const{data:i,colorStops:e,el:s,highlightMax:a,highlightMin:n,min:l,max:o}=this,h=this.graphId,{clientHeight:r,clientWidth:c}=s;if(!i||0===i.length)return t("svg",{"aria-hidden":"true",class:"svg",height:r,preserveAspectRatio:"none",viewBox:`0 0 ${c} ${r}`,width:c});const{min:d,max:p}=function(t){const[i,e]=t[0];return t.reduce((({min:t,max:i},[e,s])=>({min:[Math.min(t[0],e),Math.min(t[1],s)],max:[Math.max(i[0],e),Math.max(i[1],s)]})),{min:[i,e],max:[i,e]})}(i);let m=d,u=p;(l<d[0]||l>d[0])&&(m=[l,0]),(o>p[0]||o<p[0])&&(u=[o,p[1]]);const b=function({width:t,height:i,min:e,max:s}){const a=s[0]-e[0],n=s[1]-e[1];return s=>[(s[0]-e[0])/a*t,i-s[1]/n*i]}({min:m,max:u,width:c,height:r}),[f]=b([n,u[1]]),[g]=b([a,u[1]]),v=function({data:t,min:i,max:e,t:s}){if(0===t.length)return"";const[a,n]=s(t[0]),[l,o]=s(i),[h]=s(e);let r,c,d;const p=t.reduce(((i,e,a)=>{if(c=t[a-2],d=t[a-1],a>1){const t=
12
- /*!
13
- * All material copyright ESRI, All Rights Reserved, unless otherwise specified.
14
- * See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
15
- * v2.11.1
16
- */
17
- function(t,i,e){const s=i[0]-t[0],a=e[0]-i[0],n=(i[1]-t[1])/(s||a<0&&0),l=(e[1]-i[1])/(a||s<0&&0),o=(n*a+l*s)/(s+a);return(Math.sign(n)+Math.sign(l))*Math.min(Math.abs(n),Math.abs(l),.5*Math.abs(o))||0}(c,d,e),a=void 0===r?gt(c,d,t):r,n=vt(c,d,a,t,s);return r=t,`${i} ${n}`}return i}),`M ${l},${o} L ${l},${n} L ${a},${n}`),m=t[t.length-1];return`${p} ${vt(d,m,r,gt(d,m,r),s)} L ${h},${o} Z`}({data:i,min:d,max:p,t:b}),x=e?`url(#linear-gradient-${h})`:void 0;return t("svg",{"aria-hidden":"true",class:"svg",height:r,preserveAspectRatio:"none",viewBox:`0 0 ${c} ${r}`,width:c},e?t("defs",null,t("linearGradient",{id:`linear-gradient-${h}`,x1:"0",x2:"1",y1:"0",y2:"0"},e.map((({offset:i,color:e,opacity:s})=>t("stop",{offset:100*i+"%","stop-color":e,"stop-opacity":s}))))):null,void 0!==n?[t("mask",{height:"100%",id:`${h}1`,width:"100%",x:"0%",y:"0%"},t("path",{d:`\n M 0,0\n L ${f-1},0\n L ${f-1},${r}\n L 0,${r}\n Z\n `,fill:"white"})),t("mask",{height:"100%",id:`${h}2`,width:"100%",x:"0%",y:"0%"},t("path",{d:`\n M ${f+1},0\n L ${g-1},0\n L ${g-1},${r}\n L ${f+1}, ${r}\n Z\n `,fill:"white"})),t("mask",{height:"100%",id:`${h}3`,width:"100%",x:"0%",y:"0%"},t("path",{d:`\n M ${g+1},0\n L ${c},0\n L ${c},${r}\n L ${g+1}, ${r}\n Z\n `,fill:"white"})),t("path",{class:"graph-path",d:v,fill:x,mask:`url(#${h}1)`}),t("path",{class:"graph-path--highlight",d:v,fill:x,mask:`url(#${h}2)`}),t("path",{class:"graph-path",d:v,fill:x,mask:`url(#${h}3)`})]:t("path",{class:"graph-path",d:v,fill:x}))}get el(){return a(this)}};xt.style=":host{display:block;block-size:100%}.svg{fill:currentColor;stroke:transparent;margin:0px;display:block;block-size:100%;inline-size:100%;padding:0px}.svg .graph-path--highlight{fill:var(--calcite-color-brand);opacity:0.5}:host([hidden]){display:none}[hidden]{display:none}";
18
- /*!
19
- * All material copyright ESRI, All Rights Reserved, unless otherwise specified.
20
- * See https://github.com/Esri/calcite-design-system/blob/dev/LICENSE.md for details.
21
- * v2.11.1
22
- */
23
- const kt="container",yt="container--range",wt="hyphen",$t="hyphen--wrap",Ct="thumb",_t="thumb--active",zt="thumb--minValue",It="thumb--precise",Mt="thumb--value",Vt="tick",Ht="tick--active",St="tick__label",Lt="tick__label--max",Dt="tick__label--min";function At(t){return Array.isArray(t)}const Et=class{constructor(t){i(this,t),this.calciteSliderInput=e(this,"calciteSliderInput",6),this.calciteSliderChange=e(this,"calciteSliderChange",6),this.handleKeyDown=t=>{const i=this.shouldMirror(),{activeProp:e,max:s,min:a,pageStep:n,step:l}=this,o=this[e],{key:h}=t;if(lt(h))return void t.preventDefault();let r;if("ArrowUp"===h||"ArrowRight"===h?r=o+l*(i&&"ArrowRight"===h?-1:1):"ArrowDown"===h||"ArrowLeft"===h?r=o-l*(i&&"ArrowLeft"===h?-1:1):"PageUp"===h?n&&(r=o+n):"PageDown"===h?n&&(r=o-n):"Home"===h?r=a:"End"===h&&(r=s),isNaN(r))return;t.preventDefault();const c=Number(r.toFixed(ot(l)));this.setValue({[e]:this.clamp(c,e)})},this.activeProp="value",this.guid=`calcite-slider-${_()}`,this.onThumbBlur=()=>{this.activeProp=null},this.onThumbFocus=t=>{this.activeProp=t.currentTarget.getAttribute("data-value-prop")},this.onThumbPointerDown=t=>{this.pointerDownDragStart(t,t.currentTarget.getAttribute("data-value-prop"))},this.onTrackPointerDown=t=>{this.pointerDownDragStart(t,"minMaxValue")},this.dragUpdate=t=>{if(!this.disabled&&(t.preventDefault(),this.dragProp)){const i=this.translate(t.clientX||t.pageX);if(At(this.value)&&"minMaxValue"===this.dragProp)if(this.minValueDragRange&&this.maxValueDragRange&&this.minMaxValueRange){const t=i-this.minValueDragRange,e=i+this.maxValueDragRange;e<=this.max&&t>=this.min&&e-t===this.minMaxValueRange&&this.setValue({minValue:this.clamp(t,"minValue"),maxValue:this.clamp(e,"maxValue")})}else this.minValueDragRange=i-this.minValue,this.maxValueDragRange=this.maxValue-i,this.minMaxValueRange=this.maxValue-this.minValue;else this.setValue({[this.dragProp]:this.clamp(i,this.dragProp)})}},this.pointerUpDragEnd=t=>{!this.disabled&&p(t)&&this.dragEnd(t)},this.dragEnd=t=>{this.disabled||(this.removeDragListeners(),this.focusActiveHandle(t.clientX),this.lastDragPropValue!=this[this.dragProp]&&this.emitChange(),this.dragProp=null,this.lastDragPropValue=null,this.minValueDragRange=null,this.maxValueDragRange=null,this.minMaxValueRange=null)},this.storeTrackRef=t=>{this.trackEl=t},this.storeThumbRef=t=>{t&&("minValue"===t.getAttribute("data-value-prop")?this.minHandle=t:this.maxHandle=t)},this.formatValue=t=>(F.numberFormatOptions={locale:this.effectiveLocale,numberingSystem:this.numberingSystem,useGrouping:this.groupSeparator},F.localize(t.toString())),this.disabled=!1,this.fillPlacement="start",this.form=void 0,this.groupSeparator=!1,this.hasHistogram=!1,this.histogram=void 0,this.histogramStops=void 0,this.labelHandles=!1,this.labelFormatter=void 0,this.labelTicks=!1,this.max=100,this.maxLabel=void 0,this.maxValue=void 0,this.min=0,this.minLabel=void 0,this.minValue=void 0,this.mirrored=!1,this.name=void 0,this.numberingSystem=void 0,this.pageStep=void 0,this.precise=!1,this.required=!1,this.snap=!1,this.step=1,this.ticks=void 0,this.value=0,this.scale="m",this.effectiveLocale="",this.minMaxValueRange=null,this.minValueDragRange=null,this.maxValueDragRange=null,this.tickValues=[]}histogramWatcher(t){this.hasHistogram=!!t}ticksWatcher(){this.tickValues=this.generateTickValues()}valueHandler(){this.setMinMaxFromValue()}minMaxValueHandler(){this.setValueFromMinMax()}connectedCallback(){z(this),P(this),this.setMinMaxFromValue(),this.setValueFromMinMax(),H(this),y(this)}disconnectedCallback(){M(this),S(this),$(this),T(this),this.removeDragListeners()}componentWillLoad(){E(this),At(this.value)||(this.value=this.snap?this.getClosestStep(this.value):this.clamp(this.value)),this.ticksWatcher(),this.histogramWatcher(this.histogram),w(this,this.value)}componentDidLoad(){j(this)}componentDidRender(){this.labelHandles&&(this.adjustHostObscuredHandleLabel("value"),At(this.value)&&(this.adjustHostObscuredHandleLabel("minValue"),this.precise&&!this.hasHistogram||this.hyphenateCollidingRangeHandleLabels())),this.hideObscuredBoundingTickLabels(),I(this)}render(){const i=this.el.id||this.guid,e=At(this.value)?this.maxValue:this.value,a=this.minValue||this.min,n=this.shouldUseMinValue(),l=100*this.getUnitInterval(n?this.minValue:a),o=100*this.getUnitInterval(e),h=this.shouldMirror(),r=At(this.value),c=this.buildThumbType("max"),d=this.renderThumb({type:c,thumbPlacement:c.includes("histogram")?"below":"above",maxInterval:o,minInterval:l,mirror:h}),p=this.buildThumbType("min"),m=r&&this.renderThumb({type:p,thumbPlacement:p.includes("histogram")||p.includes("precise")?"below":"above",maxInterval:o,minInterval:l,mirror:h}),u=r?"start":this.fillPlacement,b="none"===u?{left:"unset",right:"unset"}:"end"===u?{left:`${h?l:o}%`,right:`${h?o:l}%`}:{left:`${h?100-o:l}%`,right:`${h?l:100-o}%`};return t(s,{key:"345553b84f2336fe5a98bb2b3050d137130c41ef",id:i,onKeyDown:this.handleKeyDown,onTouchStart:this.handleTouchStart},t(V,{key:"0d9db31db94152095071d9ff40dbf3cf8ba685d6",disabled:this.disabled},t("div",{key:"767ab1401000b02717013231c935fe1747def1b3","aria-label":L(this),class:{[kt]:!0,[yt]:r,[`scale--${this.scale}`]:!0}},this.renderGraph(),t("div",{key:"1a104ad97079f71d37efea9d933f364520d49397",class:"track",ref:this.storeTrackRef},t("div",{key:"84f8033505dc0f373a0d19a641886e49ca4fe732",class:"track__range",onPointerDown:this.onTrackPointerDown,style:b}),t("div",{key:"79f89b93a6acbb05ffce09bd2aa34ef134b3e219",class:"ticks"},this.tickValues.map((i=>{const s=100*this.getUnitInterval(i)+"%";let l=!1;return"start"!==u&&"end"!==u||(l=n?i>=this.minValue&&i<=this.maxValue:i>=("start"===u?a:e)&&i<=("start"===u?e:this.max)),t("span",{class:{[Vt]:!0,[Ht]:l},style:{left:h?"":s,right:h?s:""}},this.renderTickLabel(i))})))),t("div",{key:"9bc6ea406e2036adb87da4a6053533283434864d",class:"thumb-container"},m,d,t(C,{key:"c13236898b527a1ffc058914fe87e6004b93aaf5",component:this})))))}renderThumb({type:i,mirror:e,thumbPlacement:s,minInterval:a,maxInterval:n}){const l=i.includes("labeled"),o=i.includes("precise"),h=i.includes("min"),r=At(this.value),c=h?this.minValue:r?this.maxValue:this.value,d=h?"minValue":r?"maxValue":"value",p=h?this.minLabel:r?this.maxLabel:this.minLabel,m=h?this.minValue:c,u="minValue"===d?this.internalLabelFormatter(this.minValue,"min"):"maxValue"===d?this.internalLabelFormatter(this.maxValue,"max"):this.internalLabelFormatter(c,"value"),b=h?{left:`${e?100-a:a}%`}:{right:`${e?n:100-n}%`},f="handle__label "+(h?"handle__label--minValue":"handle__label--value"),g=[...l?[t("span",{"aria-hidden":"true",class:f},u),t("span",{"aria-hidden":"true",class:`${f} static`},u),t("span",{"aria-hidden":"true",class:`${f} transformed`},u)]:[],t("div",{class:"handle"}),o&&t("div",{class:"handle-extension"})];return"below"===s&&g.reverse(),t("div",{"aria-disabled":this.disabled,"aria-label":p,"aria-orientation":"horizontal","aria-valuemax":this.max,"aria-valuemin":this.min,"aria-valuenow":m,class:{[Ct]:!0,[Mt]:!h,[_t]:"minMaxValue"!==this.lastDragProp&&this.dragProp===d,[It]:o,[zt]:h},"data-value-prop":d,key:i,onBlur:this.onThumbBlur,onFocus:this.onThumbFocus,onPointerDown:this.onThumbPointerDown,ref:this.storeThumbRef,role:"slider",style:b,tabIndex:0},g)}renderGraph(){return this.histogram?t("calcite-graph",{class:"graph",colorStops:this.histogramStops,data:this.histogram,highlightMax:At(this.value)?this.maxValue:this.value,highlightMin:At(this.value)?this.minValue:this.min,max:this.max,min:this.min}):null}renderTickLabel(i){const{hasHistogram:e,labelHandles:s,labelTicks:a,max:n,min:l,precise:o,value:h}=this,r=At(h),c=i===l,d=i===n,p=c||d;return!a||(e||!p&&o&&r)&&(!e||!p&&(o||s))?null:t("span",{class:{[St]:!0,[Dt]:c,[Lt]:d}},this.internalLabelFormatter(i,"tick"))}pointerDownHandler(t){if(this.disabled||!p(t))return;const i=t.clientX||t.pageX,e=this.translate(i);let s="value";At(this.value)&&(s=e>=this.minValue&&e<=this.maxValue&&"minMaxValue"===this.lastDragProp?"minMaxValue":Math.abs(this.maxValue-e)<Math.abs(this.minValue-e)||e>=this.maxValue?"maxValue":"minValue"),this.lastDragPropValue=this[s],this.dragStart(s),this.el.shadowRoot.querySelector(`.${Ct}:active`)||this.setValue({[s]:this.clamp(e,s)}),this.focusActiveHandle(i)}handleTouchStart(t){t.preventDefault()}async setFocus(){await A(this);const t=this.minHandle?this.minHandle:this.maxHandle;t?.focus()}buildThumbType(t){const i=[t];return this.labelHandles&&i.push("labeled"),this.precise&&i.push("precise"),this.hasHistogram&&i.push("histogram"),i.join("-")}setValueFromMinMax(){const{minValue:t,maxValue:i}=this;"number"==typeof t&&"number"==typeof i&&(this.value=[t,i])}setMinMaxFromValue(){const{value:t}=this;At(t)&&(this.minValue=t[0],this.maxValue=t[1])}onLabelClick(){this.setFocus()}shouldMirror(){return this.mirrored&&!this.hasHistogram}shouldUseMinValue(){return!!At(this.value)&&(this.hasHistogram&&0===this.maxValue||!this.hasHistogram&&0===this.minValue)}getTickDensity(){const t=(this.max-this.min)/this.ticks/250;return t<1?1:t}generateTickValues(){const t=this.ticks??0;if(t<=0)return[];const i=[this.min],e=t*this.getTickDensity();let s=this.min;for(;s<this.max;)s+=e,i.push(Math.min(s,this.max));return i.includes(this.max)||i.push(this.max),i}pointerDownDragStart(t,i){p(t)&&this.dragStart(i)}dragStart(t){this.dragProp=t,this.lastDragProp=this.dragProp,this.activeProp=t,window.addEventListener("pointermove",this.dragUpdate),window.addEventListener("pointerup",this.pointerUpDragEnd),window.addEventListener("pointercancel",this.dragEnd)}focusActiveHandle(t){"minValue"===this.dragProp?this.minHandle.focus():"maxValue"===this.dragProp||"value"===this.dragProp?this.maxHandle.focus():"minMaxValue"===this.dragProp&&this.getClosestHandle(t).focus()}emitInput(){this.calciteSliderInput.emit()}emitChange(){this.calciteSliderChange.emit()}removeDragListeners(){window.removeEventListener("pointermove",this.dragUpdate),window.removeEventListener("pointerup",this.pointerUpDragEnd),window.removeEventListener("pointercancel",this.dragEnd)}setValue(t){let i;Object.keys(t).forEach((e=>{const s=t[e];i||(i=this[e]!==s),this[e]=s})),i&&(this.dragProp||this.emitChange(),this.emitInput())}clamp(t,i){return t=ht(t,this.min,this.max),"maxValue"===i&&(t=Math.max(t,this.minValue)),"minValue"===i&&(t=Math.min(t,this.maxValue)),t}translate(t){const i=this.max-this.min,{left:e,width:s}=this.trackEl.getBoundingClientRect(),a=(t-e)/s,n=this.shouldMirror(),l=this.clamp(this.min+i*(n?1-a:a)),o=Number(l.toFixed(ot(this.step)));return this.snap&&this.step?this.getClosestStep(o):o}getClosestStep(t){const{max:i,min:e,step:s}=this;let a=Math.floor((t-e)/s)*s+e;return a=Math.min(Math.max(a,e),i),a>i&&(a-=s),a}getClosestHandle(t){return this.getDistanceX(this.maxHandle,t)>this.getDistanceX(this.minHandle,t)?this.minHandle:this.maxHandle}getDistanceX(t,i){return Math.abs(t.getBoundingClientRect().left-i)}getFontSizeForElement(t){return Number(window.getComputedStyle(t).getPropertyValue("font-size").match(/\d+/)[0])}getUnitInterval(t){return((t=this.clamp(t))-this.min)/(this.max-this.min)}adjustHostObscuredHandleLabel(t){const i=this.el.shadowRoot.querySelector(`.handle__label--${t}`),e=this.el.shadowRoot.querySelector(`.handle__label--${t}.static`),s=this.el.shadowRoot.querySelector(`.handle__label--${t}.transformed`),a=e.getBoundingClientRect(),n=this.getHostOffset(a.left,a.right);i.style.transform=`translateX(${n}px)`,s.style.transform=`translateX(${n}px)`}hyphenateCollidingRangeHandleLabels(){const{shadowRoot:t}=this.el,i=this.shouldMirror(),e=i?"value":"minValue",s=i?"minValue":"value",a=t.querySelector(`.handle__label--${e}`),n=t.querySelector(`.handle__label--${e}.static`),l=t.querySelector(`.handle__label--${e}.transformed`),o=this.getHostOffset(n.getBoundingClientRect().left,n.getBoundingClientRect().right),h=t.querySelector(`.handle__label--${s}`),r=t.querySelector(`.handle__label--${s}.static`),c=t.querySelector(`.handle__label--${s}.transformed`),d=this.getHostOffset(r.getBoundingClientRect().left,r.getBoundingClientRect().right),p=this.getFontSizeForElement(a),m=this.getRangeLabelOverlap(l,c),u=a,b=p/2;if(m>0){if(u.classList.add(wt,$t),0===d&&0===o){let t=m/2-b;t=-1===Math.sign(t)?Math.abs(t):-t;const i=this.getHostOffset(l.getBoundingClientRect().left+t-b,l.getBoundingClientRect().right+t-b);let e=m/2;const s=this.getHostOffset(c.getBoundingClientRect().left+e,c.getBoundingClientRect().right+e);0!==i&&(t+=i,e+=i),0!==s&&(t+=s,e+=s),a.style.transform=`translateX(${t}px)`,l.style.transform=`translateX(${t-b}px)`,h.style.transform=`translateX(${e}px)`,c.style.transform=`translateX(${e}px)`}else if(o>0||d>0)a.style.transform=`translateX(${o+b}px)`,h.style.transform=`translateX(${m+d}px)`,c.style.transform=`translateX(${m+d}px)`;else if(o<0||d<0){let t=Math.abs(o)+m-b;t=-1===Math.sign(t)?Math.abs(t):-t,a.style.transform=`translateX(${t}px)`,l.style.transform=`translateX(${t-b}px)`}}else u.classList.remove(wt,$t),a.style.transform=`translateX(${o}px)`,l.style.transform=`translateX(${o}px)`,h.style.transform=`translateX(${d}px)`,c.style.transform=`translateX(${d}px)`}hideObscuredBoundingTickLabels(){const t=At(this.value);if(!(this.hasHistogram||t||this.labelHandles||this.precise))return;if(!this.hasHistogram&&!t&&this.labelHandles&&!this.precise)return;if(!this.hasHistogram&&!t&&!this.labelHandles&&this.precise)return;if(!this.hasHistogram&&!t&&this.labelHandles&&this.precise)return;if(!this.hasHistogram&&t&&!this.precise)return;if(this.hasHistogram&&!this.precise&&!this.labelHandles)return;const i=this.el.shadowRoot.querySelector(`.${zt}`),e=this.el.shadowRoot.querySelector(`.${Mt}`),s=this.el.shadowRoot.querySelector(`.${Dt}`),a=this.el.shadowRoot.querySelector(`.${Lt}`);!i&&e&&s&&a&&(s.style.opacity=this.isMinTickLabelObscured(s,e)?"0":"1",a.style.opacity=this.isMaxTickLabelObscured(a,e)?"0":"1"),i&&e&&s&&a&&(s.style.opacity=this.isMinTickLabelObscured(s,i)||this.isMinTickLabelObscured(s,e)?"0":"1",a.style.opacity=this.isMaxTickLabelObscured(a,i)||this.isMaxTickLabelObscured(a,e)&&this.hasHistogram?"0":"1")}getHostOffset(t,i){const e=this.el.getBoundingClientRect();return t+7<e.left?e.left-t-7:i-7>e.right?7-(i-e.right):0}getRangeLabelOverlap(t,i){const e=t.getBoundingClientRect(),s=i.getBoundingClientRect(),a=this.getFontSizeForElement(t);return Math.max(e.right+a-s.left,0)}isMinTickLabelObscured(t,i){const e=t.getBoundingClientRect(),s=i.getBoundingClientRect();return m(e,s)}isMaxTickLabelObscured(t,i){const e=t.getBoundingClientRect(),s=i.getBoundingClientRect();return m(e,s)}internalLabelFormatter(t,i){const e=this.labelFormatter;if(!e)return this.formatValue(t);const s=e(t,i,this.formatValue);return null==s?this.formatValue(t):s}static get delegatesFocus(){return!0}get el(){return a(this)}static get watchers(){return{histogram:["histogramWatcher"],ticks:["ticksWatcher"],value:["valueHandler"],minValue:["minMaxValueHandler"],maxValue:["minMaxValueHandler"]}}};Et.style='@charset "UTF-8";:host([disabled]){cursor:default;-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:var(--calcite-opacity-disabled)}:host([disabled]) *,:host([disabled]) ::slotted(*){pointer-events:none}.scale--s{--calcite-slider-handle-size:0.625rem;--calcite-slider-handle-extension-height:0.4rem;--calcite-slider-container-font-size:var(--calcite-font-size--3)}.scale--s .handle__label,.scale--s .tick__label{line-height:.75rem}.scale--m{--calcite-slider-handle-size:0.875rem;--calcite-slider-handle-extension-height:0.5rem;--calcite-slider-container-font-size:var(--calcite-font-size--2)}.scale--m .handle__label,.scale--m .tick__label{line-height:1rem}.scale--l{--calcite-slider-handle-size:1rem;--calcite-slider-handle-extension-height:0.65rem;--calcite-slider-container-font-size:var(--calcite-font-size--1)}.scale--l .handle__label,.scale--l .tick__label{line-height:1rem}.handle__label,.tick__label{font-weight:var(--calcite-font-weight-medium);color:var(--calcite-color-text-2);font-size:var(--calcite-slider-container-font-size)}:host{display:block}.container{position:relative;display:block;overflow-wrap:normal;word-break:normal;padding-inline:calc(var(--calcite-slider-handle-size) * 0.5);padding-block:calc(var(--calcite-slider-handle-size) * 0.5);margin-block:calc(var(--calcite-slider-handle-size) * 0.5);margin-inline:0;--calcite-slider-full-handle-height:calc(\n var(--calcite-slider-handle-size) + var(--calcite-slider-handle-extension-height)\n );touch-action:none}:host([disabled]) .track__range,:host([disabled]) .tick--active{background-color:var(--calcite-color-text-3)}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}.interaction-container{display:contents}.scale--s .thumb:not(.thumb--precise){--calcite-slider-thumb-y-offset:-0.375rem}.scale--m .thumb:not(.thumb--precise){--calcite-slider-thumb-y-offset:-0.5rem}.scale--l .thumb:not(.thumb--precise){--calcite-slider-thumb-y-offset:-0.55rem}:host([precise]:not([has-histogram])) .container .thumb--value{--calcite-slider-thumb-y-offset:calc(var(--calcite-slider-full-handle-height) * -1)}.thumb-container{position:relative;max-inline-size:100%}.thumb{--calcite-slider-thumb-x-offset:calc(var(--calcite-slider-handle-size) * 0.5);position:absolute;margin:0px;display:flex;cursor:pointer;flex-direction:column;align-items:center;border-style:none;background-color:transparent;padding:0px;font-family:inherit;outline:2px solid transparent;outline-offset:2px;transform:translate(var(--calcite-slider-thumb-x-offset), var(--calcite-slider-thumb-y-offset))}.thumb .handle__label.static,.thumb .handle__label.transformed{position:absolute;inset-block:0px;opacity:0}.thumb .handle__label.hyphen::after{content:"—";display:inline-block;inline-size:1em}.thumb .handle__label.hyphen--wrap{display:flex}.thumb .handle{box-sizing:border-box;border-radius:9999px;background-color:var(--calcite-color-foreground-1);outline-color:transparent;block-size:var(--calcite-slider-handle-size);inline-size:var(--calcite-slider-handle-size);box-shadow:0 0 0 2px var(--calcite-color-text-3) inset;transition:border var(--calcite-internal-animation-timing-medium) ease, background-color var(--calcite-internal-animation-timing-medium) ease, box-shadow var(--calcite-animation-timing) ease}.thumb .handle-extension{inline-size:0.125rem;block-size:var(--calcite-slider-handle-extension-height);background-color:var(--calcite-color-text-3)}.thumb:hover .handle{box-shadow:0 0 0 3px var(--calcite-color-brand) inset}.thumb:hover .handle-extension{background-color:var(--calcite-color-brand)}.thumb:focus .handle{outline:2px solid var(--calcite-ui-focus-color, var(--calcite-color-brand));outline-offset:calc(\n 2px *\n calc(\n 1 -\n 2 * clamp(\n 0,\n var(--calcite-offset-invert-focus),\n 1\n )\n )\n )}.thumb:focus .handle-extension{background-color:var(--calcite-color-brand)}.thumb.thumb--minValue{transform:translate(calc(var(--calcite-slider-thumb-x-offset) * -1), var(--calcite-slider-thumb-y-offset))}.thumb.thumb--precise{--calcite-slider-thumb-y-offset:-0.125rem}:host([label-handles]) .thumb{--calcite-slider-thumb-x-offset:50%}:host([label-handles]):host(:not([has-histogram])) .scale--s .thumb:not(.thumb--precise){--calcite-slider-thumb-y-offset:-1.4375rem}:host([label-handles]):host(:not([has-histogram])) .scale--m .thumb:not(.thumb--precise){--calcite-slider-thumb-y-offset:-1.875rem}:host([label-handles]):host(:not([has-histogram])) .scale--l .thumb:not(.thumb--precise){--calcite-slider-thumb-y-offset:-2rem}:host([has-histogram][label-handles]) .handle__label,:host([label-handles]:not([has-histogram])) .thumb--minValue.thumb--precise .handle__label{margin-block-start:0.5em}:host(:not([has-histogram]):not([precise])) .handle__label,:host([label-handles]:not([has-histogram])) .thumb--value .handle__label{margin-block-end:0.5em}:host([label-handles][precise]):host(:not([has-histogram])) .scale--s .thumb--value{--calcite-slider-thumb-y-offset:-2.075rem}:host([label-handles][precise]):host(:not([has-histogram])) .scale--m .thumb--value{--calcite-slider-thumb-y-offset:-2.75rem}:host([label-handles][precise]):host(:not([has-histogram])) .scale--l .thumb--value{--calcite-slider-thumb-y-offset:-3.0625rem}.thumb:focus .handle,.thumb--active .handle{background-color:var(--calcite-color-brand);box-shadow:0 0 8px 0 rgba(0, 0, 0, 0.16)}.thumb:hover.thumb--precise::after,.thumb:focus.thumb--precise::after,.thumb--active.thumb--precise::after{background-color:var(--calcite-color-brand)}.track{position:relative;block-size:0.125rem;border-radius:0px;background-color:var(--calcite-color-border-2);transition:all var(--calcite-internal-animation-timing-medium) ease-in}.track__range{position:absolute;inset-block-start:0px;block-size:0.125rem;background-color:var(--calcite-color-brand)}.container--range .track__range:hover{cursor:ew-resize}.container--range .track__range::after{position:absolute;inline-size:100%;content:"";inset-block-start:calc(var(--calcite-slider-full-handle-height) * 0.5 * -1);block-size:calc(var(--calcite-slider-handle-size) + var(--calcite-slider-handle-extension-height))}@media (forced-colors: active){.thumb{outline-width:0;outline-offset:0}.handle{outline:2px solid transparent;outline-offset:2px}.thumb:focus .handle,.thumb .handle-extension,.thumb:hover .handle-extension,.thumb:focus .handle-extension,.thumb:active .handle-extension{background-color:canvasText}.track{background-color:canvasText}.track__range{background-color:highlight}}.tick{position:absolute;block-size:0.25rem;inline-size:0.125rem;border-width:1px;border-style:solid;background-color:var(--calcite-color-border-input);border-color:var(--calcite-color-foreground-1);inset-block-start:-2px;pointer-events:none;margin-inline-start:calc(-1 * 0.125rem)}.tick--active{background-color:var(--calcite-color-brand)}.tick__label{pointer-events:none;margin-block-start:0.875rem;display:flex;justify-content:center}.tick__label--min{transition:opacity var(--calcite-animation-timing)}.tick__label--max{transition:opacity var(--calcite-internal-animation-timing-fast)}:host([has-histogram][label-handles]) .tick__label--min,:host([has-histogram][label-handles]) .tick__label--max,:host([has-histogram][precise]) .tick__label--min,:host([has-histogram][precise]) .tick__label--max{font-weight:var(--calcite-font-weight-normal);color:var(--calcite-color-text-3)}.graph{color:var(--calcite-color-foreground-3);block-size:48px}:host([label-ticks][ticks]) .container{padding-block-end:calc(0.875rem + var(--calcite-slider-container-font-size))}:host([has-histogram]):host([precise][label-handles]) .container{padding-block-end:calc(var(--calcite-slider-full-handle-height) + 1em)}:host([has-histogram]):host([label-handles]:not([precise])) .container{padding-block-end:calc(var(--calcite-slider-handle-size) * 0.5 + 1em)}:host([has-histogram]):host([precise]:not([label-handles])) .container{padding-block-end:var(--calcite-slider-full-handle-height)}:host(:not([has-histogram])):host([precise]:not([label-handles])) .container{padding-block-start:var(--calcite-slider-full-handle-height)}:host(:not([has-histogram])):host([precise]:not([label-handles])) .container--range{padding-block-end:var(--calcite-slider-full-handle-height)}:host(:not([has-histogram])):host([label-handles]:not([precise])) .container{padding-block-start:calc(var(--calcite-slider-full-handle-height) + 4px)}:host(:not([has-histogram])):host([label-handles][precise]) .container{padding-block-start:calc(var(--calcite-slider-full-handle-height) + var(--calcite-slider-container-font-size) + 4px)}:host(:not([has-histogram])):host([label-handles][precise]) .container--range{padding-block-end:calc(var(--calcite-slider-full-handle-height) + var(--calcite-slider-container-font-size) + 4px)}::slotted(input[slot=hidden-form-input]){margin:0 !important;opacity:0 !important;outline:none !important;padding:0 !important;position:absolute !important;inset:0 !important;transform:none !important;-webkit-appearance:none !important;z-index:-1 !important}:host([hidden]){display:none}[hidden]{display:none}';export{ft as calcite_combobox,xt as calcite_graph,Et as calcite_slider}
@@ -1,6 +0,0 @@
1
- /*!
2
- * Copyright 2022 Esri
3
- * Licensed under the Apache License, Version 2.0
4
- * http://www.apache.org/licenses/LICENSE-2.0
5
- */
6
- import{r as t,c as e,h as i,H as s,g as a}from"./p-f4c4a2b7.js";import{c as o}from"./p-2327029a.js";import{C as r}from"./p-c5897e36.js";import{g as h}from"./p-d7868dd4.js";import{d as l,p as n}from"./p-eb483242.js";import{s as c}from"./p-122a81b5.js";import"./p-73ae4b9b.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";import"./p-80cb7c73.js";import"./p-dcc35070.js";const d=class{constructor(i){t(this,i),this.calciteInternalDropdownItemChange=e(this,"calciteInternalDropdownItemChange",6),this.updateItems=()=>{Array.from(this.el.querySelectorAll("calcite-dropdown-item")).forEach((t=>t.selectionMode=this.selectionMode))},this.mutationObserver=o("mutation",(()=>this.updateItems())),this.groupTitle=void 0,this.scale="m",this.selectionMode="single"}handlePropsChange(){this.updateItems()}connectedCallback(){this.updateItems(),this.mutationObserver?.observe(this.el,{childList:!0})}componentWillLoad(){this.groupPosition=this.getGroupPosition()}disconnectedCallback(){this.mutationObserver?.disconnect()}render(){const t=this.groupTitle?i("span",{"aria-hidden":"true",class:"dropdown-title"},this.groupTitle):null,e=this.groupPosition>0?i("div",{class:"dropdown-separator",role:"separator"}):null;return i(s,{key:"1c189e8ff87a118d296781b729c889307c2b4a5b","aria-label":this.groupTitle,role:"group"},i("div",{key:"2afc3aee9c68b26af882168ce24cb2937a17c9e8",class:{[r.container]:!0}},e,t,i("slot",{key:"3fdcfab750b0541a4a24764f1a1875c867db06e8"})))}updateActiveItemOnChange(t){this.requestedDropdownGroup=t.detail.requestedDropdownGroup,this.requestedDropdownItem=t.detail.requestedDropdownItem,this.calciteInternalDropdownItemChange.emit({requestedDropdownGroup:this.requestedDropdownGroup,requestedDropdownItem:this.requestedDropdownItem})}getGroupPosition(){return Array.prototype.indexOf.call(this.el.parentElement.querySelectorAll("calcite-dropdown-group"),this.el)}static get delegatesFocus(){return!0}get el(){return a(this)}static get watchers(){return{selectionMode:["handlePropsChange"]}}};d.style=":host{position:relative;display:block}.container{text-align:start}.dropdown-title{margin-block-end:-1px;display:block;cursor:default;overflow-wrap:break-word;border-width:0px;border-block-end-width:1px;border-style:solid;border-color:var(--calcite-color-border-3);font-weight:var(--calcite-font-weight-bold);color:var(--calcite-color-text-2)}.dropdown-separator{display:block;block-size:1px;background-color:var(--calcite-color-border-3)}:host([scale=s]){font-size:var(--calcite-font-size--2);line-height:1rem}:host([scale=s]) .dropdown-title{padding:0.5rem}:host([scale=m]){font-size:var(--calcite-font-size--1);line-height:1rem}:host([scale=m]) .dropdown-title{padding:0.75rem}:host([scale=l]){font-size:var(--calcite-font-size-0);line-height:1.25rem}:host([scale=l]) .dropdown-title{padding:1rem}:host([hidden]){display:none}[hidden]{display:none}";const p=class{constructor(i){t(this,i),this.idsFound=e(this,"idsFound",7),this.noLayersFound=e(this,"noLayersFound",7),this.layerSelectionChange=e(this,"layerSelectionChange",7),this.appearance="transparent",this.defaultLayerId="",this.display="inline-block",this.enabledLayerIds=[],this.enabledTableIds=[],this.height=void 0,this.isMobile=void 0,this.mapView=void 0,this.onlyShowUpdatableLayers=void 0,this.placeholderIcon="",this.selectedIds=[],this.scale="m",this.showTables=void 0,this.showSingleLayerAsLabel=!1,this.type="select",this._hasMultipleLayers=!0,this._hasValidLayers=!0,this._isDropdownOpen=void 0,this.ids=[],this.selectedName="",this._translations=void 0}get el(){return a(this)}defaultLayerHonored=!1;_layerElement;_layerNameHash;_tableNameHash;async mapViewWatchHandler(){await this._setLayers(),this.ids.length>0?(this._hasValidLayers=!0,this._hasMultipleLayers=this.ids.length>1,this._setSelectedLayer(this.ids[0])):(this._hasValidLayers=!1,this.noLayersFound.emit())}idsFound;noLayersFound;layerSelectionChange;async componentWillLoad(){await this._getTranslations(),await this._setLayers(),(this.ids.length>0||1===this.selectedIds.length)&&this.layerSelectionChange.emit(1===this.selectedIds.length?[this.selectedIds[0]]:[this.ids[0]])}render(){const t="map-layer-picker";let e=this.height>0?{height:`${this.height.toString()}px`}:{};return e={...e,display:this.display},i(s,{key:"a96e93924530d926c5e10dd2f7212f3f8c1cbe3c"},i("div",{key:"4b96a73e43e86c31291e4ac60eb15976b01de6a2",class:"map-layer-picker-container",style:e},i("div",{key:"e75c61d8ce0853814dd3903b9e1952cc613b6fbb",class:"map-layer-picker",style:e},this._hasValidLayers?!this._hasMultipleLayers&&this.showSingleLayerAsLabel?this._getSingleLayerPlaceholder():"combobox"===this.type?this._getCombobox(t):"select"===this.type?this._getSelect(t):this._getDropdown(t):this._getInvalidPlaceholder())))}async componentDidLoad(){if(this.ids.length>0||1===this.selectedIds.length){const t=1===this.selectedIds.length?this.selectedIds[0]:this.ids[0];"select"===this.type?this._layerElement.value=t:"dropdown"===this.type&&(this.selectedName=Object.keys(this._layerNameHash).indexOf(t)>-1?this._layerNameHash[t].name:Object.keys(this._tableNameHash).indexOf(t)>-1?this._tableNameHash[t].name:"")}}_getInvalidPlaceholder(){return i("div",null,i("calcite-notice",{class:"height-100",icon:"exclamation-mark-triangle",id:"no-valid-layers",kind:"danger",open:!0},i("div",{slot:"message"},this._translations.noLayersFound)),i("calcite-tooltip",{label:this._translations.enableEditUpdate,placement:"bottom","reference-element":"no-valid-layers"},i("span",null,this._translations.enableEditUpdate)))}_getSingleLayerPlaceholder(){return i("div",{class:"layer-picker-label-container cursor-default"},i("calcite-icon",{icon:"layers",scale:"s"}),i("calcite-label",{class:"no-bottom-margin padding-start-1"},this.selectedName))}_getSelect(t){return i("calcite-select",{id:t,label:"",onCalciteSelectChange:()=>this._layerSelectionChange(),ref:t=>{this._layerElement=t},scale:this.scale},this._getMapLayerOptions())}_getCombobox(t){return i("calcite-combobox",{clearDisabled:!0,id:t,label:"",onCalciteComboboxChange:()=>this._layerSelectionChange(),"placeholder-icon":this.placeholderIcon,ref:t=>{this._layerElement=t},scale:this.scale,"selection-mode":"single"},this._getMapLayerOptions())}_getDropdown(t){return i("calcite-dropdown",{class:"layer-picker-dropdown",onCalciteDropdownBeforeClose:()=>this._isDropdownOpen=!1,onCalciteDropdownBeforeOpen:()=>this._isDropdownOpen=!0},this.isMobile?this._getDropdownButton():this._getActionDropdownButton(t),i("calcite-dropdown-group",{"selection-mode":"single"},this._getMapLayerOptions()))}_getActionDropdownButton(t){return i("calcite-action",{id:t,slot:"trigger",text:""},this._getDropdownButton())}_getDropdownButton(){return i("calcite-button",{alignment:"icon-end-space-between",appearance:this.appearance,class:this.isMobile?"":"max-width-350",iconEnd:this._isDropdownOpen?"chevron-up":"chevron-down",iconStart:"layers",kind:"neutral",slot:this.isMobile?"trigger":"",width:"full"},i("div",null,this.selectedName))}_getMapLayerOptions(){return this.ids.reduce(((t,e)=>(this._validLayer(e)?t.push(this._getItem(e,"layer")):this._validTable(e)&&t.push(this._getItem(e,"table")),t)),[])}_getItem(t,e){const s="layer"===e?this._layerNameHash[t]:this._tableNameHash[t],a=!!this.onlyShowUpdatableLayers&&!s.supportsUpdate,o=s.name,r=this.selectedIds.indexOf(t)>-1;return"combobox"===this.type?i("calcite-combobox-item",{disabled:a,selected:r,textLabel:o,value:t}):"select"===this.type?i("calcite-option",{disabled:a,label:o,selected:r,value:t}):i("calcite-dropdown-group",{class:a?"disabled":"",selectionMode:a?"none":"single"},i("calcite-dropdown-item",{onClick:a?void 0:()=>{this._setSelectedLayer(t)},selected:r},o))}_setSelectedLayer(t){let e;this.defaultLayerId&&!this.defaultLayerHonored&&(e=this._getLayerFromHash(this.defaultLayerId),this.defaultLayerHonored=void 0!==e,t=this.defaultLayerHonored?this.defaultLayerId:t),e=e||this._getLayerFromHash(t),this.selectedName=e?.name,this.selectedIds=[t],this.layerSelectionChange.emit(this.selectedIds)}_getLayerFromHash(t){return Object.keys(this._layerNameHash).indexOf(t)>-1?this._layerNameHash[t]:Object.keys(this._tableNameHash).indexOf(t)>-1?this._tableNameHash[t]:void 0}async _setLayers(){if(this.mapView){await this._initLayerTableHash();const t=this.onlyShowUpdatableLayers?this._getEditableIds(this._layerNameHash):Object.keys(this._layerNameHash),e=this.showTables?this.onlyShowUpdatableLayers?this._getEditableIds(this._tableNameHash):Object.keys(this._tableNameHash):[];this.ids=[...t.reverse().filter((t=>!(this.enabledLayerIds?.length>0)||this.enabledLayerIds.reverse().indexOf(t)>-1)),...e.reverse().filter((t=>!(this.enabledTableIds?.length>0)||this.enabledTableIds.reverse().indexOf(t)>-1))],this.idsFound.emit({layerIds:t,tableIds:e})}}_getEditableIds(t){return Object.keys(t).reduce(((e,i)=>(t[i].supportsUpdate&&e.push(i),e)),[])}async _initLayerTableHash(){this._layerNameHash=await l(this.mapView,this.onlyShowUpdatableLayers),this._tableNameHash=this.showTables?await n(this.mapView,this.onlyShowUpdatableLayers):{}}_validLayer(t){const e=this._layerNameHash[t]?.name;return e&&Object.keys(c.managedLayers).indexOf(e)<0&&(!(this.enabledLayerIds.length>0)||this.enabledLayerIds.indexOf(t)>-1)}_validTable(t){const e=this._tableNameHash[t]?.name,i=e&&this.showTables;return i?c.managedTables.indexOf(e)<0&&(!(this.enabledTableIds.length>0)||this.enabledTableIds.indexOf(t)>-1):i}_layerSelectionChange(){const t=Array.isArray(this._layerElement.value)?this._layerElement.value:[this._layerElement.value];JSON.stringify(t)!==JSON.stringify([""])&&(this.selectedIds=t,this.layerSelectionChange.emit(this.selectedIds))}async _getTranslations(){const t=await h(this.el);this._translations=t[0]}static get watchers(){return{mapView:["mapViewWatchHandler"]}}};p.style=":host{display:block}.map-layer-picker-container{width:100%;align-items:center}.map-layer-picker{position:relative;width:100%;display:inline-block}.padding-bottom-1{padding-bottom:1rem}.layer-picker-dropdown{height:100%;width:100%}.max-width-350{max-width:350px}.height-100{height:100%}.disabled{cursor:default !important;-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:var(--calcite-opacity-disabled);pointer-events:none}.no-bottom-margin{--calcite-label-margin-bottom:0px}.layer-picker-label-container{align-items:center;display:inline-flex;height:100%;padding-inline-start:1rem;padding-inline-end:1rem}.padding-start-1{padding-inline-start:1rem}.cursor-default{cursor:default}";export{d as calcite_dropdown_group,p as map_layer_picker}
@@ -1,6 +0,0 @@
1
- /*!
2
- * Copyright 2022 Esri
3
- * Licensed under the Apache License, Version 2.0
4
- * http://www.apache.org/licenses/LICENSE-2.0
5
- */
6
- import{r as t,c as i,g as e,h as s,H as h}from"./p-f4c4a2b7.js";import{g as o}from"./p-d7868dd4.js";import{E as a}from"./p-80cb7c73.js";import{g as l}from"./p-eb483242.js";import"./p-0a24ad5f.js";import"./p-d4056c1c.js";const n=class{constructor(e){t(this,e),this.showIntroductionWindow=i(this,"showIntroductionWindow",7),this.showCoverPage=i(this,"showCoverPage",7),this.appLayout=void 0,this.appProxies=void 0,this.basemapConfig=void 0,this.coverPageEnabled=void 0,this.defaultCenter="",this.defaultGlobalId="",this.defaultLayer="",this.defaultLevel="",this.defaultOid="",this.defaultWebmap="",this.introductionWindowEnabled=!1,this.enableAutoRefresh=!1,this.enableBasemap=!0,this.enableColumnReorder=!0,this.enableCreateFeatures=!0,this.enableCSV=!0,this.enableFloorFilter=!0,this.enableFullscreen=!0,this.enableHome=!0,this.enableLegend=!0,this.enableSearch=!0,this.enableShare=!1,this.enableZoom=!0,this.hideMapOnLoad=!1,this.mapInfos=[],this.onlyShowUpdatableLayers=!0,this.popupHeaderColor=void 0,this.popupHeaderHoverColor=void 0,this.popupHeaderHoverTextColor=void 0,this.popupHeaderTextColor=void 0,this.searchConfiguration=void 0,this.shareIncludeEmbed=void 0,this.shareIncludeSocial=void 0,this.showNewestFirst=!0,this.theme="light",this.zoomAndScrollToSelected=!1,this.zoomToScale=void 0,this._expandPopup=!1,this._hideFooter=!1,this._hideTable=!1,this._isMobile=!1,this._translations=void 0,this._layer=void 0,this._layoutMode=a.GRID,this._mapInfo=void 0,this._mapView=void 0,this._panelOpen=!0,this._numSelected=0,this._tableOnly=!1}get el(){return e(this)}_defaultCenterHonored=!1;_defaultLevelHonored=!1;_hideMapOnLoadHonored=!1;_layerTable;_mapChange;_resizeObserver;_shouldSetMapView=!1;enableZoomWatchHandler(){this._initMapZoom()}hideMapOnLoadWatchHandler(){this.showHideMapPopupAndTable(this.hideMapOnLoad&&!this._isMobile),this._expandPopup=this.hideMapOnLoad&&!this._isMobile}showIntroductionWindow;showCoverPage;async featureSelectionChange(t){this._numSelected=t.detail?.length}async popupClosed(){this._isMobile&&this.showHideMapPopupAndTable(!1)}async idsFound(t){const i=t.detail;this._tableOnly=i.tableIds.length>0&&0===i.layerIds.length,this._tableOnly&&(this._expandPopup=!0)}async layoutChanged(t){this._layoutMode=t.detail}async mapChanged(t){this._mapChange=t.detail,await this._mapChange.mapView.when((async()=>{await this._setMapView()}))}async beforeMapChanged(){this._expandPopup&&(this._shouldSetMapView=!0)}async layerSelectionChange(t){const i=t.detail[0],e=await l(this._mapView,i);await e.when((()=>{this._layer=e}))}async mapInfoChange(){this._expandPopup=this.hideMapOnLoad&&!this._isMobile,this._hideMapOnLoadHonored=!1}async componentWillLoad(){await this._getTranslations(),this._resizeObserver=new ResizeObserver((()=>this._onResize()))}render(){return s(h,{key:"f434a8e24b111a32774e9d5683c2446ba35b504b"},s("calcite-shell",{key:"017843c77fa2c52f0d957760ac3f57808d11d59f",class:"position-relative"},s("calcite-panel",{key:"bd8eeec3a013583789b9e1b251fed34e5896171e",class:"width-full height-full "+(this.popupHeaderColor&&"#FFFFFF"!==this.popupHeaderColor?"border-width-0":"")},this._getBody(this._layoutMode,this._panelOpen,this._hideTable)),this._getFooter()))}async componentDidRender(){this._shouldSetMapView&&(this._shouldSetMapView=!1,this._mapChange&&await this._setMapView())}async componentDidLoad(){this._resizeObserver.observe(this.el)}_getFooter(){const t=this._numSelected>0,i=this._layer?.editingEnabled&&this._layer?.capabilities?.operations?.supportsDelete;return this._isMobile&&t&&!this._hideFooter?s("div",{class:"width-100",slot:"footer"},s("div",{class:"display-flex padding-1-2"},s("calcite-button",{appearance:"solid",id:"solutions-show",onClick:()=>this.showHideMapPopupAndTable(!0),width:"full"},this._translations.view.replace("{{n}}",this._numSelected.toString())),i?s("delete-button",{class:"padding-inline-start-1 width-full",id:"solutions-delete",ids:this._layerTable.selectedIds,layer:this._layer}):void 0)):void 0}_getDividerIcon(t,i){let e="";switch(t){case a.HORIZONTAL:e=i?"chevrons-up":"chevrons-down";break;case a.VERTICAL:case a.GRID:e=i?"chevrons-left":"chevrons-right"}return e}_getMapSizeClass(t,i,e){let s="";switch(t){case a.HORIZONTAL:s=(i&&!e?"height-1-2 display-grid":i&&e?"height-full":"height-0")+" width-full position-relative";break;case a.GRID:s="height-full position-relative "+(i?"width-1-3":"width-0");break;case a.VERTICAL:s="height-full position-relative "+(i?"width-1-2":"width-0")}return s}_getTableSizeClass(t,i){let e="";switch(t){case a.HORIZONTAL:e=(i?"height-1-2":"height-full")+" width-full display-flex flex-column";break;case a.GRID:e=(i?"width-2-3":"width-full")+" height-full display-flex";break;case a.VERTICAL:e=(i?"width-1-2":"width-full")+" height-full display-flex"}return e}_getBody(t,i,e){const h="dark"===this.theme?"calcite-mode-dark":"calcite-mode-light";return s("calcite-panel",{class:"width-full height-full"},s("div",{class:"width-full height-full overflow-hidden "+(t===a.HORIZONTAL?"":"display-flex")},this._getMapAndCard(t,i,e),this._getTable(t,i,e)),this.coverPageEnabled&&s("div",{class:"floating-container",onClick:this.coverPageButtonClick.bind(this)},s("calcite-button",{appearance:"solid",class:`floating-button ${h}`,"icon-start":"content-minimal",kind:"neutral",label:"",round:!0,scale:"l","split-child":"primary",width:"auto"})),this.introductionWindowEnabled&&s("div",{class:"floating-container",onClick:this.infoButtonClick.bind(this)},s("calcite-button",{appearance:"solid",class:`floating-button ${h}`,"icon-start":"information-letter",kind:"neutral",label:"",round:!0,scale:"l","split-child":"primary",width:"auto"})))}infoButtonClick(){this.showIntroductionWindow.emit()}coverPageButtonClick(){this.showCoverPage.emit()}_getMapAndCard(t,i,e){const h=this._getMapSizeClass(t,i,e);return s("div",{class:`${h} overflow-hidden`},this._getMapNode(i),this._getPopupExpandNode())}_getMapNode(t){return s("div",{class:(this._layoutMode!==a.HORIZONTAL||this._isMobile&&!t?"adjusted-height-50":"")+" overflow-hidden"},s("map-card",{appProxies:this.appProxies,basemapConfig:this.basemapConfig,class:"width-full",defaultWebmapId:this.defaultWebmap,enableBasemap:this.enableBasemap,enableFloorFilter:this.enableFloorFilter,enableFullscreen:this.enableFullscreen,enableHome:this.enableHome,enableLegend:this.enableLegend,enableSearch:this.enableSearch,enableSingleExpand:!0,hidden:this._expandPopup&&!this._isMobile,homeZoomIndex:3,homeZoomPosition:"top-left",homeZoomToolsSize:"s",mapInfos:this.mapInfos?.filter((t=>!1!==t.visible)),mapWidgetsIndex:0,mapWidgetsPosition:"top-right",mapWidgetsSize:"m",stackTools:!0,theme:this.theme,toolOrder:["legend","search","fullscreen","basemap","floorfilter"]}))}_getPopupExpandNode(){const t=this._expandPopup?"chevrons-down":"chevrons-up",i="expand-popup",e=this._expandPopup?this._translations.collapsePopup:this._translations.expandPopup,h="dark"===this.theme?"calcite-mode-dark":"calcite-mode-light",o=this._isMobile?"display-none height-0":"";return s("div",{class:`${this.popupHeaderColor?"":this._isMobile?"calcite-mode-light":"calcite-mode-dark"} ${this._expandPopup?1===this.mapInfos?.length||this._isMobile?"position-absolute-0":"position-absolute-50":"height-full"} ${this._isMobile&&this._hideTable?"position-absolute-0 width-full height-full":this._isMobile?"display-none height-0":""}`,style:{"--calcite-color-foreground-1":this.popupHeaderColor,"--calcite-color-foreground-2":this.popupHeaderHoverColor,"--calcite-color-text-3":this.popupHeaderTextColor,"--calcite-color-text-2":this.popupHeaderTextColor}},s("calcite-panel",null,this._isMobile?void 0:s("div",{class:`display-flex align-items-center ${o}`,slot:"header-content"},s("calcite-icon",{icon:"information",scale:"s"}),s("div",{class:"padding-inline-start-75"},this._translations.information)),s("calcite-action",{class:o,disabled:this._tableOnly,icon:t,id:i,onClick:()=>this._togglePopup(),slot:"header-actions-end",text:""}),this._tableOnly?void 0:s("calcite-tooltip",{class:h,label:"",placement:"bottom","reference-element":i},s("span",null,e)),this._getCardNode()))}_togglePopup(){this._expandPopup=!this._expandPopup,this._hideMapOnLoadHonored=!0}_getCardNode(){return s("div",{class:"width-50 height-full "+("dark"===this.theme?"calcite-mode-dark":"calcite-mode-light")},s("card-manager",{class:(this._expandPopup||this._isMobile?"height-full":"height-50")+" width-full",enableEditGeometry:this?._mapInfo?.enableEditGeometry,isMobile:this._isMobile,mapView:this?._mapView,zoomAndScrollToSelected:this.zoomAndScrollToSelected}))}_getTable(t,i,e){const h=e&&this._isMobile?"visibility-hidden":"",o=this._getTableSizeClass(t,i),l=this._getDividerIcon(t,i),n=i?this._translations.close:this._translations.open,d="toggle-layout",r=t===a.HORIZONTAL?"horizontal":"vertical",c=t===a.HORIZONTAL?"header":"panel-start",p=this.defaultWebmap&&this.defaultLayer,g=this.defaultGlobalId?this.defaultGlobalId?.indexOf(",")>-1?this.defaultGlobalId.split(","):[this.defaultGlobalId]:void 0,u=this.defaultOid?this.defaultOid?.indexOf(",")>-1?this.defaultOid.split(",").map((t=>parseInt(t,10))):[parseInt(this.defaultOid,10)]:void 0;return s("calcite-shell",{class:`${o} ${h} border-bottom`},this._isMobile?void 0:s("calcite-action-bar",{class:"border-sides",expandDisabled:!0,layout:r,slot:c},s("calcite-action",{class:"toggle-node",icon:l,id:d,onClick:()=>this._toggleLayout(),text:""}),s("calcite-tooltip",{label:n,placement:"bottom","reference-element":d},s("span",null,n))),s("div",{class:"width-full height-full position-relative"},s("layer-table",{defaultGlobalId:p?g:void 0,defaultLayerId:p?this.defaultLayer:"",defaultOid:p&&!g?u:void 0,enableAutoRefresh:this.enableAutoRefresh,enableCSV:this.enableCSV,enableColumnReorder:this.enableColumnReorder,enableInlineEdit:this?._mapInfo?.enableInlineEdit,enableShare:this.enableShare,isMobile:this._isMobile,mapHidden:this._expandPopup,mapInfo:this._mapInfo,mapView:this?._mapView,onlyShowUpdatableLayers:this.onlyShowUpdatableLayers,ref:t=>this._layerTable=t,shareIncludeEmbed:this.shareIncludeEmbed,shareIncludeSocial:this.shareIncludeSocial,showNewestFirst:this.showNewestFirst,zoomAndScrollToSelected:this.zoomAndScrollToSelected,zoomToScale:this.zoomToScale})))}_onResize(){const t=this.el.offsetWidth<1024,i=!this._isMobile&&t;this._isMobile=t,this._layoutMode=this._isMobile?a.HORIZONTAL:a.GRID,i&&(this._panelOpen=!0),(this.hideMapOnLoad&&!this._hideMapOnLoadHonored||this._isMobile)&&this.hideMapOnLoadWatchHandler()}_toggleLayout(){this._panelOpen=!this._panelOpen}showHideMapPopupAndTable(t){this._expandPopup=!1,this._hideTable=t,this._hideFooter=t}_getMapInfo(t){let i;return this.mapInfos.some((e=>{if(e.id===t)return i=e,!0})),{...i}}async _setMapView(){this._mapInfo=this._getMapInfo(this._mapChange.id),this._mapView=this._mapChange.mapView,this._initMapZoom(),this._mapView.popupEnabled=!1;const t=!this.defaultCenter||this._defaultCenterHonored?void 0:this.defaultCenter?.split(";").map((t=>parseFloat(t))),i=!this.defaultLevel||this._defaultLevelHonored?void 0:parseInt(this.defaultLevel,10);t&&i&&(await this._mapView.goTo({center:t,zoom:i}),this._defaultCenterHonored=!0,this._defaultLevelHonored=!0)}_initMapZoom(){this.enableZoom?this.enableZoom&&this._mapView.ui.add({component:"zoom",position:"top-left",index:0}):this._mapView.ui.remove("zoom")}async _getTranslations(){const t=await o(this.el);this._translations=t[0]}static get watchers(){return{enableZoom:["enableZoomWatchHandler"],hideMapOnLoad:["hideMapOnLoadWatchHandler"]}}};n.style=":host{display:block;--calcite-label-margin-bottom:0px;--solutions-theme-foreground-color:var(--calcite-color-foreground-1)}.padding-1-2{padding:0.5rem}.display-flex{display:flex}.width-full{width:100%}.width-1-2{position:relative;width:50%}.width-1-3{position:relative;width:33.33%}.width-2-3{position:relative;width:66.66%}.width-0{width:0}.height-full{height:100%}.height-1-2{position:relative;height:50%}.height-0{height:0}.toggle-node{width:51px;height:51px}.overflow-hidden{overflow:hidden}.flex-column{flex-direction:column}.border{border:1px solid var(--calcite-color-border-3)}.border-bottom{border-bottom:1px solid var(--calcite-color-border-3)}.border-sides{border-left:1px solid var(--calcite-color-border-3);border-right:1px solid var(--calcite-color-border-3)}.position-relative{position:relative}.height-50{height:50%}.adjusted-height-50{height:calc(50% - 25px)}.adjusted-height-100{height:calc(100% - 50px)}.adjusted-height-100-50{height:calc(100% - 50px)}.display-none{display:none}.height-53{height:53px}.position-absolute-53{position:absolute;top:53px}.display-grid{display:grid}.height-50-px{height:50px}.padding-inline-start-75{padding-inline-start:0.75rem}.align-items-center{align-items:center}.esri-floor-filter__close-levels-button{width:40px !important;height:40px !important}.esri-floor-filter__level-button{width:40px !important;height:40px !important}.esri-floor-filter__browse-button{width:40px !important;height:40px !important}.position-absolute-50{position:absolute;top:50px;bottom:0px;left:0px;right:0px}.position-absolute-0{position:absolute;top:0px;bottom:0px;left:0px;right:0px}.visibility-hidden{visibility:hidden;height:0px}.position-fixed{position:fixed}.border-width-0{border-width:0px}.border-bottom-width-0{border-bottom-width:0px}.floating-container{position:fixed;width:100px;height:10px;bottom:0;right:0;margin:100px 0px}.floating-container .floating-button{box-shadow:0 10px 25px rgb(92 93 94 / 60%);transform:translatey(5px);transition:all 0.3s}";export{n as crowdsource_manager}
@@ -1,6 +0,0 @@
1
- /*!
2
- * Copyright 2022 Esri
3
- * Licensed under the Apache License, Version 2.0
4
- * http://www.apache.org/licenses/LICENSE-2.0
5
- */
6
- import{r as s,g as a,h as e,H as r}from"./p-f4c4a2b7.js";const t=class{constructor(a){s(this,a)}get el(){return a(this)}render(){return e(r,{key:"104457a5adda26509038d324510d96303fc116ec"},e("slot",{key:"b20c4a07d8a74354ce7c1dc6aa56dda863b041c9"}))}};t.style=":host{display:block}";export{t as refine_results_flow_item}