/* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
import d from"./UZ6A3XQC.js";import"./DPJE33GY.js";import{a as g}from"./QN4OORAR.js";import c from"./KFUE7LVT.js";import"./UG7LOBJE.js";import b from"./AD6GOUND.js";import"./4B3QBH5T.js";import"./FUPYXGG6.js";import"./KUVOINJC.js";import"./NKG4FLLR.js";import{A as a,F as p,g as n,h as m,m as o,x as l,y as h,z as u}from"./RPU6VCJ4.js";import"./OR4HXHSY.js";export default $arcgis.t(([,,{g:d,h:f,i:e,j:i}])=>{var r={container:"container",label:"label",numberInput:"number-input"},v=n`.hide{visibility:hidden}.am5-html-container{z-index:101!important}.am5-layer-1000{z-index:1000!important}.am5-layer-30{z-index:100!important}.show{display:block}.notifyPanel{flex:0 1 auto}.disable-interactions{pointer-events:none}.dim-text{color:var(--arcgis-charts-dim-text)}.container{width:var(--arcgis-charts-config-calcite-block-width, var(--arcgis-charts-config-calcite-block-default-width));height:var(--arcgis-charts-config-calcite-block-height, var(--arcgis-charts-config-calcite-block-default-height))}.container>.number-input{margin-bottom:.5rem;display:flex}.container>.number-input>div{width:100%}.label{display:flex;margin-bottom:.5rem}`,s=class extends u{constructor(){super(...arguments),this._messages=g(),this.characterLimitInputElement=l(),this.arcgisChartsConfigCategoryFormatChange=o()}static{this.properties={messageOverrides:0,categoryFormat:0}}static{this.styles=v}onCharacterLimitChange(){let t=this.characterLimitInputElement.value?.value,c=Math.floor(Number(t)),b=c===Number(t)&&c>=0;if(t!==void 0&&b&&d(t,this.characterLimitInputElement.value?.min,this.characterLimitInputElement.value?.max)){let y=Number.parseInt(t);this.updateCategoryFormat({type:this.categoryFormat.type,characterLimit:y}),this.arcgisChartsConfigCategoryFormatChange.emit(),this.characterLimitInputElement.value&&e({inputElement:this.characterLimitInputElement.value,status:i.IDLE})}else this.characterLimitInputElement.value&&e({inputElement:this.characterLimitInputElement.value,status:i.INVALID})}updateCategoryFormat(t){this.categoryFormat={...this.categoryFormat,...t}}render(){return m`<div class=${a(r.container)}><calcite-label class=${a(r.label)}>${this._messages.labelCharacterLmt}<calcite-input type=number class=${a(r.numberInput)} min=1 max=100 step=1 .value=${f(this.categoryFormat?.characterLimit,11)} @calciteInputInput=${this.onCharacterLimitChange} ${h(this.characterLimitInputElement)}></calcite-input></calcite-label></div>`}};p("arcgis-charts-config-category-format",s);return s},b,c,d)