@arcgis/common-components 5.1.0-next.44 → 5.1.0-next.46
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cdn/{ZHUCZTR2.js → 5EKB3CUO.js} +1 -1
- package/dist/cdn/{KRJ6PIL6.js → 6UGM5LNE.js} +1 -1
- package/dist/cdn/{357YPDTQ.js → 6XD2GTPZ.js} +1 -1
- package/dist/cdn/{3HKYWLJY.js → 7AMLQYVM.js} +2 -2
- package/dist/cdn/{CADM67RN.js → 7JIHCVH3.js} +1 -1
- package/dist/cdn/{UK3JIV7H.js → ALWVIWUC.js} +1 -1
- package/dist/cdn/{N5FBDEZK.js → DLNJ7OOB.js} +1 -1
- package/dist/cdn/{7CI55VCH.js → DWXXQFPQ.js} +1 -1
- package/dist/cdn/{ANGNTSLN.js → E33LXBTL.js} +1 -1
- package/dist/cdn/{TICCVQ7N.js → E4EVLDYS.js} +1 -1
- package/dist/cdn/{UCXHK4PA.js → ELRD345Q.js} +1 -1
- package/dist/cdn/{5PG2K3KH.js → HEQCNDQR.js} +1 -1
- package/dist/cdn/{45CNSLKA.js → HVUNL3EO.js} +1 -1
- package/dist/cdn/{2TZIP7OF.js → IYJJN26J.js} +1 -1
- package/dist/cdn/{736PTIHC.js → LGOSLS6K.js} +1 -1
- package/dist/cdn/{KAHX5ZGA.js → LPG2EDKA.js} +1 -1
- package/dist/cdn/{HVU4IDVW.js → N4R5SMWN.js} +1 -1
- package/dist/cdn/{5GJ4DXIW.js → SF2NJOD3.js} +1 -1
- package/dist/cdn/{ESI3PVIT.js → YOEHJTF2.js} +1 -1
- package/dist/cdn/{UKIOB6Y2.js → ZCGHCFFN.js} +1 -1
- package/dist/cdn/index.js +1 -1
- package/dist/components/arcgis-unique-values-list/customElement.d.ts +3 -2
- package/dist/components/arcgis-unique-values-list/customElement.js +7 -3
- package/dist/docs/api.json +1 -1
- package/dist/docs/docs.json +1 -1
- package/dist/docs/vscode.html-custom-data.json +1 -1
- package/dist/docs/web-types.json +1 -1
- package/package.json +3 -3
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
|
|
2
|
-
import{B as $,C as h,D as m,E as f,H as M,g as y,i as c,q as w}from"./
|
|
2
|
+
import{B as $,C as h,D as m,E as f,H as M,g as y,i as c,q as w}from"./7AMLQYVM.js";export default $arcgis.t(([{formatNumber:A}])=>{var l={container:"container",ticksContainer:"ticks-container",labelsContainer:"labels-container",tick:"tick",tickMin:"tick--min",tickMax:"tick--max",tickLabel:"tick-label",baseline:"baseline"},L=y`:host{display:flex;--arcgis-ticks-tick-length: .5rem;--arcgis-ticks-tick-color: var(--calcite-color-border-input);--arcgis-ticks-gap: 1em;--arcgis-ticks-font-size: var(--calcite-font-size--2)}.container{align-items:stretch;display:flex;color:var(--calcite-color-text-2);flex:1;font-weight:var(--calcite-font-weight-medium);font-size:var(--arcgis-ticks-font-size);line-height:1em;position:relative;user-select:none;word-wrap:normal;word-break:normal}.baseline{background-color:var(--arcgis-ticks-tick-color, var(--calcite-color-border-input))}.tick{position:absolute;background-color:var(--arcgis-ticks-tick-color, var(--calcite-color-border-input))}.tick-label{position:absolute;text-align:var(--arcgis-ticks-label-text-align, center);width:var(--arcgis-ticks-label-width, var(--labels-container-width, "auto"))}:host([layout="horizontal"]){.ticks-container{height:var(--arcgis-ticks-tick-length)}.labels-container{height:var(--labels-container-height, "auto")}.tick{width:.125rem;height:var(--arcgis-ticks-tick-length);transform:translate(-50%)}.tick-label{transform:translate(-50%)}.tick--min{transform:unset}.tick--max{transform:translate(-100%)}}:host([layout="vertical"]){.ticks-container{width:var(--arcgis-ticks-tick-length)}.labels-container{width:var(--labels-container-width)}.tick{width:var(--arcgis-ticks-tick-length);height:.125rem;transform:translateY(50%)}.tick-label{text-align:right;transform:translateY(50%)}.tick--min{transform:unset}.tick--max{transform:translateY(100%)}}:host([layout="horizontal"][mirrored]){.tick,.tick-label{transform:translate(50%)}.tick--min{transform:unset}.tick--max{transform:translate(100%)}}:host([layout="vertical"][mirrored]){.tick,.tick-label{transform:translateY(-50%)}.tick--min{transform:unset}.tick--max{transform:translateY(-100%)}}:host([layout="horizontal"][label-placement="start"]){.container{flex-direction:column;justify-content:flex-end}.labels-container{margin-bottom:var(--arcgis-ticks-gap)}}:host([layout="horizontal"][label-placement="end"]){.container{flex-direction:column-reverse;justify-content:flex-end}.labels-container{margin-top:var(--arcgis-ticks-gap)}}:host([layout="vertical"][label-placement="start"]){.container{flex-direction:row;justify-content:flex-end}:dir(ltr){.labels-container{margin-right:var(--arcgis-ticks-gap)}.tick-label{text-align:right}}:dir(rtl){.labels-container{margin-left:var(--arcgis-ticks-gap)}.tick-label{text-align:left;unicode-bidi:plaintext}}}:host([layout="vertical"][label-placement="end"]){.container{flex-direction:row-reverse;justify-content:flex-end}:dir(ltr){.labels-container{margin-left:var(--arcgis-ticks-gap)}.tick-label{text-align:left}}:dir(rtl){.labels-container{margin-right:var(--arcgis-ticks-gap)}.tick-label{text-align:right;unicode-bidi:plaintext}}}:host([interactive]){pointer-events:none;.tick,.tick-label{pointer-events:auto;cursor:pointer}.tick-label:hover{text-decoration:underline}}`,g=class extends ${constructor(){super(...arguments),this._formatValue=e=>A(e,this._formatOptions),this._formatOptions={style:"decimal",useGrouping:!0,minimumFractionDigits:0,maximumFractionDigits:2},this.interactive=!1,this.interpolationExponent=0,this.labelPlacement="end",this.layout="horizontal",this.max=100,this.min=0,this.mirrored=!1,this.mode="count",this.showLabels=!1,this.showBaseline=!1,this.values=[],this.arcgisTickClick=w({cancelable:!1})}static{this.properties={_formatOptions:16,interactive:7,interpolationExponent:9,labelFormatter:0,labelPlacement:3,layout:3,max:9,min:9,mirrored:7,mode:1,showLabels:5,showBaseline:5,values:[9,{converter:{fromAttribute(e){if(e.includes(","))return e.split(",").filter(t=>t.trim()!=="").map(parseFloat).filter(t=>Number.isFinite(t));{let t=parseFloat(e);return Number.isFinite(t)?[t]:[]}}}}]}}static{this.styles=L}updated(){let e=this.renderRoot.querySelector(`.${l.labelsContainer}`);if(e){let t=0,i=0;for(let a of this.renderRoot.querySelectorAll(`.${l.tickLabel}`)){let r=a.getBoundingClientRect();t=Math.max(t,r.width),i=Math.max(i,r.height)}t=Math.ceil(t),i=Math.ceil(i),!t||!i?(e.style.removeProperty("--labels-container-width"),e.style.removeProperty("--labels-container-height")):(e.style.setProperty("--labels-container-width",`${t}px`),e.style.setProperty("--labels-container-height",`${i}px`))}}_handleClick(e){if(!this.interactive)return;let t=e.target.dataset.value;t&&this.arcgisTickClick.emit({value:Number(t)})}_internalLabelFormatter(e){let t=this.labelFormatter;return t?t(e,this._formatValue)??this._formatValue(e):this._formatValue(e)}render(){return c`<div class=${h(l.container)} touch-action=none @click=${this._handleClick}>${this._renderContent()}${this._renderBaseline()}</div>`}_renderContent(){let{interpolationExponent:e,max:t,min:i,mode:a,values:r,layout:s,mirrored:o,showLabels:C}=this,p=[],v=[];for(let[d,k]of F(a,i,t,e,r)){let x={[s==="horizontal"?o?"right":"left":o?"top":"bottom"]:`${d}%`},z={[l.tick]:!0,[l.tickMin]:d===0,[l.tickMax]:d===100};p.push(c`<div class=${h(z)} style=${m(x)} data-value=${k??f}></div>`),C&&v.push(c`<div class=${h(l.tickLabel)} style=${m(x)} data-value=${k??f}>${this._internalLabelFormatter(k)}</div>`)}return[c`<div class=${h(l.labelsContainer)}>${v}</div>`,c`<div class=${h(l.ticksContainer)}>${p}</div>`]}_renderBaseline(){let{showBaseline:e,layout:t}=this;return e&&c`<div class=${h(l.baseline)} style=${m({[t==="horizontal"?"width":"height"]:"100%",[t==="horizontal"?"height":"width"]:"0.125rem"})}></div>`||""}};function*F(n,e,t,i,a){switch(n){case"value":{let r=Array.isArray(a)?a:[a];for(let s of r){let o=P(e,t,s,i)*100;o>=0&&o<=100&&(yield[o,s])}break}case"percent":{if(Array.isArray(a))for(let r of a)r>=0&&r<=100&&(yield[r,u(e,t,r/100,i)]);else if(a>0)for(let r=0;r<=100;r+=a)yield[r,u(e,t,r/100,i)];break}case"count":{let r=Array.isArray(a)?a[0]:a;if(r<=1)yield[50,u(e,t,.5,i)];else for(let s=0;s<r;s++){let o=s*100/(r-1);yield[o,u(e,t,o/100,i)]}break}}}function b(n,e,t){return t<n?n:t>e?e:t}function _(n,e,t){return n+(e-n)*t}function P(n,e,t,i=0){let a=(t-n)/(e-n);if(a=b(0,1,a),Math.abs(i)<1e-9)return a;let r=1+Math.expm1(i)*a;return a=Math.log(r)/i,b(0,1,a)}function u(n,e,t,i=0){if(t=b(0,1,t),Math.abs(i)<1e-9)return _(n,e,t);let a=Math.expm1(i*t)/Math.expm1(i);return _(n,e,a)}M("arcgis-ticks",g);return g},"intl")
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
|
|
2
|
-
import{a as b}from"./MP6Z45SA.js";import{B as m,H as o,g as h,i as d,q as r}from"./
|
|
2
|
+
import{a as b}from"./MP6Z45SA.js";import{B as m,H as o,g as h,i as d,q as r}from"./7AMLQYVM.js";var $=h`.container{display:flex;align-items:center;justify-content:space-between;position:relative}.slider{width:50%}.input{width:45%}`,p=class extends m{constructor(){super(...arguments),this.debouncedApplyValueOnChange=b(e=>this.applyValueOnChange(e),800),this.disabled=!1,this.flipLabels=!1,this.min=0,this.max=100,this.value=50,this.step=1,this.withSteppers=!1,this.arcgisSliderInputValueChange=r(),this.arcgisValueChange=r()}static{this.properties={disabled:5,label:1,flipLabels:5,min:9,max:9,value:9,step:9,unitsLabel:1,withSteppers:5}}static{this.styles=$}applyValueOnChange(e){let{min:i,max:a,value:n}=this,s=Number(e.value),t=i!==void 0&&a!==void 0?Math.min(a,Math.max(i,s)):s;s!==n&&(e.value=`${t}`,this.arcgisValueChange.emit(t),this.arcgisSliderInputValueChange.emit(t),this.value=t)}render(){let{disabled:e,min:i,max:a,value:n,step:s,withSteppers:t,flipLabels:c,unitsLabel:u,label:g}=this;return d`<div class="container"><calcite-slider class="slider" .disabled=${e} .min=${i} .max=${a} .value=${n} .step=${s} @calciteSliderInput=${l=>this.debouncedApplyValueOnChange(l.currentTarget)}></calcite-slider><calcite-input class="input" .disabled=${e} .min=${i} .max=${a} .numberButtonType=${t?"vertical":"none"} .prefixText=${c?u:""} @calciteInputInput=${l=>this.debouncedApplyValueOnChange(l.target)} @click=${l=>l.stopPropagation()} scale=s step=any .suffixText=${c?"":u} type=number .value=${`${n}`} .label=${g}></calcite-input></div>`}};o("arcgis-slider-input",p);export{p as ArcgisSliderInput};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
|
|
2
|
-
import{k as r,w as s,x as i,y as o}from"./
|
|
2
|
+
import{k as r,w as s,x as i,y as o}from"./7AMLQYVM.js";var u=s(class extends i{constructor(){super(...arguments),this.key=r}render(t,e){return this.key=t,e}update(t,[e,m]){return e!==this.key&&(o(t),this.key=e),m}});export{u as a};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
|
|
2
|
-
import{h as o}from"./
|
|
2
|
+
import{h as o}from"./7AMLQYVM.js";var n=Symbol(),e=class{get taskComplete(){return this.t||(this.i===1?this.t=new Promise(((t,s)=>{this.o=t,this.h=s})):this.i===3?this.t=Promise.reject(this.l):this.t=Promise.resolve(this.u)),this.t}constructor(t,s,r){this.p=0,this.i=0,(this._=t).addController(this);let i=typeof s=="object"?s:{task:s,args:r};this.v=i.task,this.j=i.args,this.m=i.argsEqual??u,this.k=i.onComplete,this.A=i.onError,this.autoRun=i.autoRun??!0,"initialValue"in i&&(this.u=i.initialValue,this.i=2,this.O=this.T?.())}hostUpdate(){this.autoRun===!0&&this.S()}hostUpdated(){this.autoRun==="afterUpdate"&&this.S()}T(){if(this.j===void 0)return;let t=this.j();if(!Array.isArray(t))throw Error("The args function must return an array");return t}async S(){let t=this.T(),s=this.O;this.O=t,t===s||t===void 0||s!==void 0&&this.m(s,t)||await this.run(t)}async run(t){let s,r;t??=this.T(),this.O=t,this.i===1?this.q?.abort():(this.t=void 0,this.o=void 0,this.h=void 0),this.i=1,this.autoRun==="afterUpdate"?queueMicrotask((()=>this._.requestUpdate())):this._.requestUpdate();let i=++this.p;this.q=new AbortController;let a=!1;try{s=await this.v(t,{signal:this.q.signal})}catch(l){a=!0,r=l}if(this.p===i){if(s===n)this.i=0;else{if(a===!1){try{this.k?.(s)}catch{}this.i=2,this.o?.(s)}else{try{this.A?.(r)}catch{}this.i=3,this.h?.(r)}this.u=s,this.l=r}this._.requestUpdate()}}abort(t){this.i===1&&this.q?.abort(t)}get value(){return this.u}get error(){return this.l}get status(){return this.i}render(t){switch(this.i){case 0:return t.initial?.();case 1:return t.pending?.();case 2:return t.complete?.(this.value);case 3:return t.error?.(this.error);default:throw Error("Unexpected status: "+this.i)}}},u=(h,t)=>h===t||h.length===t.length&&h.every(((s,r)=>!o(s,t[r])));export{e as a};
|
package/dist/cdn/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/* COPYRIGHT Esri - https://js.arcgis.com/5.1/LICENSE.txt */
|
|
2
|
-
import{G as i,v as e}from"./
|
|
2
|
+
import{G as i,v as e}from"./7AMLQYVM.js";var s=e(i,{"arcgis-ckeditor5":[()=>import("./DLNJ7OOB.js"),"canResizeVertically,currentLanguage,customConfig,customExpressionCheck:,editorType,groupFieldsAndExpressions,intlExpressionsGroupHeading,intlFieldsGroupHeading,intlTextPlaceHolder,mentionFields:,readOnly,textData;getData,setFocus"],"arcgis-ckeditor5-popover":[()=>import("./5EKB3CUO.js"),"guid,intlCancel,intlLabel,intlOk,refElement:;reposition"],"arcgis-color-input":[()=>import("./ELRD345Q.js"),"_messages:,clearable,color,compact,disabled,hideRecentColors,messageOverrides:,placement,popoverProps:,showTransparency,storageId;close,setFocus"],"arcgis-field-info":[()=>import("./E33LXBTL.js"),"_messages:,fieldName,hideAlias,hideNumericFormat,hideStatistics,layer:,view:;refresh"],"arcgis-field-pick-list":[()=>import("./LGOSLS6K.js"),"_messages:,customExpressionCheck:,expressionsGroupHeading,fields:,fieldsGroupHeading,filterNoResultsText,filterPlaceholderText,groupFieldsAndExpressions,heading,hideCancel,hideSort,layer:,listOnly,mapView:,multiple,okBtnText,popoverProps:,selectedFields:,showCancel,showDescription,showFieldInfo,showFieldName,showFieldTypeIcon,showFilterLength,showSelectionAll,showSort,sortBy,view:;reposition,setDisabled,setFocus"],"arcgis-histogram":[()=>import("./LPG2EDKA.js"),"_messages:,average,bins:,colorBlendingEnabled,colorStops:,dataLines:,icon,label,layout,max,messageOverrides:,min,standardDeviation"],"arcgis-label-input":[()=>import("./7JIHCVH3.js"),"alignment,editing,labelFormatter:,readOnly,value;edit;getLabelBoundingClientRect"],"arcgis-picker-input":[()=>import("./6UGM5LNE.js"),"disabled,heading,iconEnd,intlDone,label,popoverProps:;close,setFocus"],"arcgis-ramp-color":[()=>import("./ALWVIWUC.js"),"layout,max,min,stops:"],"arcgis-ramp-color-break":[()=>import("./E4EVLDYS.js"),"layout,max,min,stops:"],"arcgis-ramp-opacity":[()=>import("./HEQCNDQR.js"),"fillColor,layout,max,min,stops:"],"arcgis-slider":[()=>import("./HVUNL3EO.js"),"activeValue:,allowValuesOverlap,autoDestroyDisabled,disabled,fillPlacement,fullRangeMax,fullRangeMin,keyboardLargeStep,labelFormatter:,layout,max,messageOverrides:,messages:,min,mirrored,popoverLabel,popoverPlacement,precision,rangeLabelsEditingEnabled,rangeLabelsPlacement,segmentsDraggingDisabled,showRangeLabels,steps,valueLabelsDisplay,valueLabelsEditingEnabled,valueLabelsPlacement,values;destroy"],"arcgis-slider-input":[()=>import("./SF2NJOD3.js"),"disabled,flipLabels,label,max,min,step,unitsLabel,value,withSteppers"],"arcgis-ticks":[()=>import("./N4R5SMWN.js"),"interactive,interpolationExponent,labelFormatter:,labelPlacement,layout,max,min,mirrored,mode,showBaseline,showLabels,values"],"arcgis-unique-values-list":[()=>import("./IYJJN26J.js"),"_messages:,fieldName,layer:,maxHeight,multiple,numberFormatOptions:,partialUniqueValues,selectedValues:,showFilterLength,sortBy,uniqueValues:,view:,visualizationSource;getUniqueValues,setFocus"]});s({resourcesUrl:import.meta.url});var a=new CSSStyleSheet;a.replaceSync("@layer{:not([hydrated]):is(arcgis-ckeditor5,arcgis-ckeditor5-popover,arcgis-color-input,arcgis-field-info,arcgis-field-pick-list,arcgis-histogram,arcgis-label-input,arcgis-picker-input,arcgis-ramp-color,arcgis-ramp-color-break,arcgis-ramp-opacity,arcgis-slider,arcgis-slider-input,arcgis-ticks,arcgis-unique-values-list){visibility:hidden}:root{--arcgis-ckeditor5-initial-height: 30vh;--arcgis-ckeditor5-max-width: 35vw;--arcgis-ckeditor5-mentions-max-width: 33vw;--arcgis-common-ckeditor5-initial-height: 30vh;--arcgis-common-ckeditor5-max-width: 35vw;--arcgis-common-ckeditor5-mentions-max-width: 33vw}}");document.adoptedStyleSheets=[...document.adoptedStyleSheets,a];window.$arcgis||Object.defineProperty(window,"$arcgis",{configurable:!1,enumerable:!0,writable:!1,value:{}}),((a,r)=>{a.t=(c,...x)=>Promise.all(x.map(x=>x.then?x:(!a?.forceESM&&a?.import||(x=>import(x+".js").then(m=>m.default??m)))("@arcgis/core/"+x))).then(c);r.p=a.t(([m])=>{r.t=m.trackAccess;r.o=m.createObservable;r.c=m.createTrackingTarget;r.r=m.runTracked},"applications/Components/reactiveUtils")})($arcgis,i)
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/// <reference path="../../index.d.ts" />
|
|
2
2
|
/// <reference types="@arcgis/core/interfaces.d.ts" />
|
|
3
3
|
import type { PublicLitElement as LitElement } from "@arcgis/lumina";
|
|
4
|
+
import type { UniqueValueCountInfo } from "@arcgis/core/smartMapping/statistics/types.js";
|
|
4
5
|
import type { SupportedLayer } from "./utils/basic.js";
|
|
5
6
|
import type { VisualizationSource } from "../../utils/types.js";
|
|
6
7
|
import type { T9nMeta } from "@arcgis/lumina/controllers";
|
|
@@ -86,7 +87,7 @@ export abstract class ArcgisUniqueValuesList extends LitElement {
|
|
|
86
87
|
* List of all unique values. If not provided component will get the unique values from the layer.
|
|
87
88
|
* An empty list would mean that there are no unique values for this field on the layer. The component renders nothing then.
|
|
88
89
|
*/
|
|
89
|
-
accessor uniqueValues:
|
|
90
|
+
accessor uniqueValues: UniqueValueCountInfo[] | undefined;
|
|
90
91
|
/** MapView instance, required if uniqueValues is not provided and/or to display dates in the correct timezone */
|
|
91
92
|
accessor view: __esri.MapView | __esri.SceneView | undefined;
|
|
92
93
|
/** Optional, specify visualization source other than the layer itself. */
|
|
@@ -96,7 +97,7 @@ export abstract class ArcgisUniqueValuesList extends LitElement {
|
|
|
96
97
|
* E.g. to be used to limit how often these unique values need to be requested from the layer.
|
|
97
98
|
*/
|
|
98
99
|
getUniqueValues(): Promise<{
|
|
99
|
-
uniqueValues:
|
|
100
|
+
uniqueValues: UniqueValueCountInfo[];
|
|
100
101
|
partialUniqueValues: boolean;
|
|
101
102
|
} | undefined>;
|
|
102
103
|
/** Sets focus on component */
|
|
@@ -157,7 +157,11 @@ class oe extends W {
|
|
|
157
157
|
throw new Error();
|
|
158
158
|
await this.processProps();
|
|
159
159
|
},
|
|
160
|
-
args: () => [
|
|
160
|
+
args: () => [
|
|
161
|
+
this.layer,
|
|
162
|
+
this.fieldName,
|
|
163
|
+
this.uniqueValues
|
|
164
|
+
]
|
|
161
165
|
}), this.initialRender = !0, this.multiple = !1, this.partialUniqueValues = !1, this.showFilterLength = 10, this.arcgisChange = F(), this.arcgisSortByChange = F(), this.arcgisLoad = F();
|
|
162
166
|
}
|
|
163
167
|
static {
|
|
@@ -262,7 +266,7 @@ class oe extends W {
|
|
|
262
266
|
if (!$ && g)
|
|
263
267
|
return (typeof m.value == "string" ? Number.parseFloat(m.value) : m.value) - (typeof f.value == "string" ? Number.parseFloat(f.value) : f.value);
|
|
264
268
|
{
|
|
265
|
-
const q = $ ? O(m.value, c) : m.value, V = $ ? O(f.value, c) : f.value;
|
|
269
|
+
const q = $ ? O(m.value, c) : m.label ?? m.value, V = $ ? O(f.value, c) : f.label ?? f.value;
|
|
266
270
|
return `${q}`.startsWith("_") ? 1 : `${V}`.startsWith("_") ? -1 : `${q}`.localeCompare(`${V}`);
|
|
267
271
|
}
|
|
268
272
|
});
|
|
@@ -290,7 +294,7 @@ class oe extends W {
|
|
|
290
294
|
return S`<calcite-dropdown slot=filter-actions-end placement=bottom-end overlay-positioning=fixed @calciteDropdownSelect=${this.onSortMenuSelect} ${T(this.dropdownNode)}><calcite-action slot=trigger .label=${u.sortValues} text><calcite-icon scale=s icon=sortDescending flip-rtl></calcite-icon></calcite-action><calcite-dropdown-group><calcite-dropdown-item .selected=${t === "count" || !h(t)} data-value=count>${u.sortByCount}</calcite-dropdown-item><calcite-dropdown-item .selected=${t === "name"} data-value=name>${e || s ? u.sortAscending : u.sortAlphabetical}</calcite-dropdown-item><calcite-dropdown-item .selected=${t === "selected"} data-value=selected>${u.sortSelected}</calcite-dropdown-item></calcite-dropdown-group></calcite-dropdown>`;
|
|
291
295
|
}
|
|
292
296
|
renderUniqueValue(e) {
|
|
293
|
-
const { selectedValues: s, initialRender: t, view: u, fieldInfo: p, numberFormatOptions: a } = this, { fieldDomains: r, uniqueValueInfos: c, simpleType: l } = p, d = u && "timeZone" in u && u.timeZone || "system", o = r?.length ? O(e.value, r) : l === "date" ? ee(e.value, d) : l === "date-only" ? te(e.value) : l === "time-only" ? ie(e.value) : l === "timestamp-offset" ? se(e.value, u) : typeof e.value == "number" ? Q(e.value, a) : e.value, n = s ? l === "date-only" ? s.includes(r?.length ? e.value : L(e.value)) : l === "time-only" ? s.includes(r?.length ? e.value : U(e.value)) : s.includes(e.value) : !1;
|
|
297
|
+
const { selectedValues: s, initialRender: t, view: u, fieldInfo: p, numberFormatOptions: a } = this, { fieldDomains: r, uniqueValueInfos: c, simpleType: l } = p, d = u && "timeZone" in u && u.timeZone || "system", o = r?.length ? O(e.value, r) : l === "date" ? ee(e.value, d) : l === "date-only" ? te(e.value) : l === "time-only" ? ie(e.value) : l === "timestamp-offset" ? se(e.value, u) : typeof e.value == "number" ? Q(e.value, a) : e.label ?? e.value, n = s ? l === "date-only" ? s.includes(r?.length ? e.value : L(e.value)) : l === "time-only" ? s.includes(r?.length ? e.value : U(e.value)) : s.includes(e.value) : !1;
|
|
294
298
|
return P(`list-item_${e.value}`, S`<calcite-list-item .label=${`${o}`} .value=${`${e.value}`} .selected=${n}>${h(e.count) && (c.length > 200 && !t || c.length <= 200) ? S`<div class="count" slot=actions-end>${`${e.count}`}</div>` : null}</calcite-list-item>`);
|
|
295
299
|
}
|
|
296
300
|
}
|