iobroker.lovelace
Version:
With this adapter you can build visualization for ioBroker with Home Assistant Lovelace UI
2 lines • 24.8 kB
JavaScript
/*! For license information please see 62756.015f64598833fdec.js.LICENSE.txt */
export const __rspack_esm_id=62756;export const __rspack_esm_ids=[62756];export const __webpack_modules__={93905(t,e,a){a.d(e,{I:()=>r});a(44114),a(18111),a(7588),a(69112),a(33110);class s{addFromStorage(t){if(!this._storage[t]){const e=this.storage.getItem(t);e&&(this._storage[t]=JSON.parse(e))}}subscribeChanges(t,e){return this._listeners[t]?this._listeners[t].push(e):this._listeners[t]=[e],()=>{this.unsubscribeChanges(t,e)}}unsubscribeChanges(t,e){if(!(t in this._listeners))return;const a=this._listeners[t].indexOf(e);-1!==a&&this._listeners[t].splice(a,1)}hasKey(t){return t in this._storage}getValue(t){return this._storage[t]}setValue(t,e){const a=this._storage[t];this._storage[t]=e;try{void 0===e?this.storage.removeItem(t):this.storage.setItem(t,JSON.stringify(e))}catch(t){}finally{this._listeners[t]&&this._listeners[t].forEach(t=>t(a,e))}}constructor(t=window.localStorage){this._storage={},this._listeners={},this.storage=t,this.storage===window.localStorage&&window.addEventListener("storage",t=>{t.key&&this.hasKey(t.key)&&(this._storage[t.key]=t.newValue?JSON.parse(t.newValue):t.newValue,this._listeners[t.key]&&this._listeners[t.key].forEach(e=>e(t.oldValue?JSON.parse(t.oldValue):t.oldValue,this._storage[t.key])))})}}const i={};function r(t){return(e,a)=>{if("object"==typeof a)throw new Error("This decorator does not support this compilation type.");const r=t.storage||"localStorage";let o;r&&r in i?o=i[r]:(o=new s(window[r]),i[r]=o);const l=t.key||String(a);o.addFromStorage(l);const n=!1!==t.subscribe?t=>o.subscribeChanges(l,(e,s)=>{t.requestUpdate(a,e)}):void 0,h=()=>o.hasKey(l)?t.deserializer?t.deserializer(o.getValue(l)):o.getValue(l):void 0,c=(e,s)=>{let i;t.state&&(i=h()),o.setValue(l,t.serializer?t.serializer(s):s),t.state&&e.requestUpdate(a,i)},d=e.performUpdate;if(e.performUpdate=function(){this.__initialized=!0,d.call(this)},t.subscribe){const t=e.connectedCallback,a=e.disconnectedCallback;e.connectedCallback=function(){t.call(this);const e=this;e.__unbsubLocalStorage||(e.__unbsubLocalStorage=n?.(this))},e.disconnectedCallback=function(){a.call(this);this.__unbsubLocalStorage?.(),this.__unbsubLocalStorage=void 0}}const u=Object.getOwnPropertyDescriptor(e,a);let p;if(void 0===u)p={get:()=>h(),set(t){(this.__initialized||void 0===h())&&c(this,t)},configurable:!0,enumerable:!0};else{const t=u.set;p={...u,get:()=>h(),set(e){(this.__initialized||void 0===h())&&c(this,e),t?.call(this,e)}}}Object.defineProperty(e,a,p)}}},89300(t,e,a){a.a(t,async function(t,e){try{var s=a(62826),i=a(5124),r=a(22441),o=a(6412),l=a(18350),n=a(65829),h=(a(67094),t([l,n]));[l,n]=h.then?(await h)():h;const c="M2.2,16.06L3.88,12L2.2,7.94L6.26,6.26L7.94,2.2L12,3.88L16.06,2.2L17.74,6.26L21.8,7.94L20.12,12L21.8,16.06L17.74,17.74L16.06,21.8L12,20.12L7.94,21.8L6.26,17.74L2.2,16.06M13,17V15H11V17H13M13,13V7H11V13H13Z",d="M9,20.42L2.79,14.21L5.62,11.38L9,14.77L18.88,4.88L21.71,7.71L9,20.42Z";class u extends i.WF{render(){const t=this.progress||this._result?"accent":this.appearance;return i.qy` <ha-button .appearance="${t}" .disabled="${this.disabled}" .loading="${this.progress}" .variant="${"success"===this._result?"success":"error"===this._result?"danger":this.variant}" class="${(0,o.H)({result:!!this._result,success:"success"===this._result,error:"error"===this._result})}"> ${this.iconPath?i.qy`<ha-svg-icon .path="${this.iconPath}" slot="start"></ha-svg-icon>`:i.s6} <slot>${this.label}</slot> </ha-button> ${this._result?i.qy` <div class="progress"> ${"success"===this._result?i.qy`<ha-svg-icon .path="${d}"></ha-svg-icon>`:"error"===this._result?i.qy`<ha-svg-icon .path="${c}"></ha-svg-icon>`:i.s6} </div> `:i.s6} `}actionSuccess(){this._setResult("success")}actionError(){this._setResult("error")}_setResult(t){this._result=t,setTimeout(()=>{this._result=void 0},2e3)}constructor(...t){super(...t),this.disabled=!1,this.progress=!1,this.appearance="accent",this.variant="brand"}}u.styles=i.AH`:host{outline:0;display:inline-block;position:relative}:host([progress]){pointer-events:none}.progress{bottom:0;display:flex;justify-content:center;align-items:center;position:absolute;top:0;width:100%}ha-button{width:100%}ha-button.result::part(caret),ha-button.result::part(end),ha-button.result::part(label),ha-button.result::part(spinner),ha-button.result::part(start){visibility:hidden}:host([appearance=brand]) ha-svg-icon{color:var(--white-color)}`,(0,s.Cg)([(0,r.MZ)()],u.prototype,"label",void 0),(0,s.Cg)([(0,r.MZ)({type:Boolean})],u.prototype,"disabled",void 0),(0,s.Cg)([(0,r.MZ)({type:Boolean,reflect:!0})],u.prototype,"progress",void 0),(0,s.Cg)([(0,r.MZ)()],u.prototype,"appearance",void 0),(0,s.Cg)([(0,r.MZ)({attribute:!1})],u.prototype,"iconPath",void 0),(0,s.Cg)([(0,r.MZ)()],u.prototype,"variant",void 0),(0,s.Cg)([(0,r.wk)()],u.prototype,"_result",void 0),u=(0,s.Cg)([(0,r.EM)("ha-progress-button")],u),e()}catch(t){e(t)}})},56304(t,e,a){a.a(t,async function(t,e){try{var s=a(62826),i=a(99324),r=a(92070),o=a(5124),l=a(22441),n=a(6412),h=a(63672),c=a(57237),d=a(53305),u=t([i]);i=(u.then?(await u)():u)[0];class p extends((0,d.w)(o.WF)){get _formControl(){return this._textarea}setFocused(t){t?this.toggleAttribute("focused",!0):this.removeAttribute("focused")}connectedCallback(){super.connectedCallback(),this.addEventListener("keydown",c.d)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("keydown",c.d)}async firstUpdated(t){super.firstUpdated(t),this.autofocus&&(await(this._textarea?.updateComplete),this._textarea?.focus())}focus(t){this._textarea?.focus(t)}render(){const t=!this.label&&this._hasSlotController.test("label"),e=!this.hint&&this._hasSlotController.test("hint");return o.qy` <wa-textarea .value="${this.value??null}" .placeholder="${this.placeholder}" .readonly="${this.readonly}" .required="${this.required}" .rows="${this.rows??4}" .resize="${this.resize}" .disabled="${this.disabled}" name="${(0,h.J)(this.name)}" autocapitalize="${(0,h.J)(this.autocapitalize||void 0)}" autocomplete="${(0,h.J)(this.autocomplete)}" .autofocus="${this.autofocus}" .spellcheck="${this.spellcheck}" inputmode="${(0,h.J)(this.inputmode||void 0)}" enterkeyhint="${(0,h.J)(this.enterkeyhint||void 0)}" minlength="${(0,h.J)(this.minlength)}" maxlength="${(0,h.J)(this.maxlength)}" class="${(0,n.H)({input:!0,invalid:this.invalid||this._invalid,"label-raised":void 0!==this.value&&""!==this.value||this.label&&this.placeholder,"no-label":!this.label,"hint-hidden":!(this.hint||e||this.required||this._invalid||this.invalid)})}" ="${this._handleInput}" ="${this._handleChange}" ="${this._handleBlur}" -invalid="${this._handleInvalid}" exportparts="base:wa-base, hint:wa-hint, textarea:wa-textarea"> ${this.label||t?o.qy`<slot name="label" slot="label">${this.label?this._renderLabel(this.label,this.required):o.s6}</slot>`:o.s6} <div slot="hint" class="${(0,n.H)({error:this.invalid||this._invalid})}" role="${(0,h.J)(this.invalid||this._invalid?"alert":void 0)}" aria-live="polite"> ${this._invalid||this.invalid?this.validationMessage||this._textarea?.validationMessage:this.hint||(e?o.qy`<slot name="hint"></slot>`:o.s6)} </div> </wa-textarea> `}constructor(...t){super(...t),this.resize="none",this._hasSlotController=new r.X(this,"label","hint"),this._requiredMarkerCSSVar="--ha-textarea-required-marker"}}p.styles=[d.N,o.AH`:host{display:flex;align-items:flex-start;padding-bottom:var(--ha-textarea-padding-bottom)}wa-textarea::part(label){width:calc(100% - var(--ha-space-2));background-color:var(--ha-color-form-background);transition:all var(--wa-transition-normal) ease-in-out,background-color var(--wa-transition-normal) ease-in-out;padding-inline-start:var(--ha-space-3);padding-inline-end:var(--ha-space-3);margin:var(--ha-space-1) var(--ha-space-1) 0;padding-top:var(--ha-space-4);white-space:nowrap;overflow:hidden}:host(:focus-within) wa-textarea::part(label),:host([focused]) wa-textarea::part(label){color:var(--primary-color)}:host(:focus-within) wa-textarea::part(label),:host([focused]) wa-textarea::part(label),wa-textarea.label-raised::part(label){padding-top:var(--ha-space-2);font-size:var(--ha-font-size-xs)}wa-textarea.no-label::part(label){height:0;padding:0}wa-textarea::part(base){min-height:56px;padding-top:var(--ha-space-6);padding-bottom:var(--ha-space-2)}wa-textarea.no-label::part(base){padding-top:var(--ha-space-3)}wa-textarea::part(base)::after{content:"";position:absolute;bottom:0;left:0;right:0;height:1px;background-color:var(--ha-color-border-neutral-loud);transition:height var(--wa-transition-normal) ease-in-out,background-color var(--wa-transition-normal) ease-in-out}:host(:focus-within) wa-textarea::part(base)::after,:host([focused]) wa-textarea::part(base)::after{height:2px;background-color:var(--primary-color)}:host(:focus-within) wa-textarea.invalid::part(base)::after,wa-textarea.invalid:not([disabled])::part(base)::after{background-color:var(--ha-color-border-danger-normal)}wa-textarea::part(textarea){padding:0 var(--ha-space-4);font-family:var(--ha-font-family-body);font-size:var(--ha-font-size-m)}:host([resize=auto]) wa-textarea::part(textarea){max-height:var(--ha-textarea-max-height,200px);overflow-y:auto}wa-textarea:hover::part(base),wa-textarea:hover::part(label){background-color:var(--ha-color-form-background-hover)}wa-textarea[disabled]::part(textarea){cursor:not-allowed}wa-textarea[disabled]::part(base),wa-textarea[disabled]::part(label){background-color:var(--ha-color-form-background-disabled)}`],(0,s.Cg)([(0,l.MZ)({type:Number})],p.prototype,"rows",void 0),(0,s.Cg)([(0,l.MZ)()],p.prototype,"resize",void 0),(0,s.Cg)([(0,l.P)("wa-textarea")],p.prototype,"_textarea",void 0),p=(0,s.Cg)([(0,l.EM)("ha-textarea")],p),e()}catch(t){e(t)}})},52069(t,e,a){a.d(e,{EF:()=>o,S_:()=>s,Xv:()=>l,ni:()=>r,u1:()=>n,z3:()=>h});const s=(t,e)=>t.callApi("POST","tts_get_url",e),i="media-source://tts/",r=t=>t.startsWith(i),o=t=>t.substring(19),l=(t,e,a)=>t.callWS({type:"tts/engine/list",language:e,country:a}),n=(t,e)=>t.callWS({type:"tts/engine/get",engine_id:e}),h=(t,e,a)=>t.callWS({type:"tts/engine/voices",engine_id:e,language:a})},12911(t,e,a){a.a(t,async function(t,s){try{a.r(e),a.d(e,{TTSTryDialog:()=>m});var i=a(62826),r=a(5124),o=a(22441),l=a(93905),n=a(1087),h=a(89300),c=(a(93444),a(56304)),d=a(72554),u=a(52069),p=a(14503),g=a(65063),b=t([h,c,d]);[h,c,d]=b.then?(await b)():b;const v="M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20,12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M10,16.5L16,12L10,7.5V16.5Z";class m extends r.WF{showDialog(t){this._params=t,this._valid=Boolean(this._defaultMessage),this._open=!0}closeDialog(){this._open=!1}_dialogClosed(){this._params=void 0,(0,n.r)(this,"dialog-closed",{dialog:this.localName})}get _defaultMessage(){const t=this._params.language?.substring(0,2),e=this.hass.locale.language.substring(0,2);return t&&this._messages?.[t]?this._messages[t]:t===e?this.hass.localize("ui.dialogs.tts-try.message_example"):""}render(){return this._params?r.qy` <ha-dialog .open="${this._open}" header-title="${this.hass.localize("ui.dialogs.tts-try.header")}" ="${this._dialogClosed}"> <ha-textarea resize="auto" id="message" .label="${this.hass.localize("ui.dialogs.tts-try.message")}" .placeholder="${this.hass.localize("ui.dialogs.tts-try.message_placeholder")}" .value="${this._defaultMessage}" ="${this._inputChanged}" ?autofocus="${!this._defaultMessage}"> </ha-textarea> <ha-dialog-footer slot="footer"> <ha-progress-button slot="primaryAction" .progress="${this._loadingExample}" ?autofocus="${Boolean(this._defaultMessage)}" ="${this._playExample}" .disabled="${!this._valid}" .iconPath="${v}"> ${this.hass.localize("ui.dialogs.tts-try.play")} </ha-progress-button> </ha-dialog-footer> </ha-dialog> `:r.s6}async _inputChanged(){this._valid=Boolean(this._messageInput?.value)}async _playExample(){const t=this._messageInput?.value;if(!t)return;const e=this._params.engine,a=this._params.language,s=this._params.voice;a&&(this._messages={...this._messages,[a.substring(0,2)]:t}),this._loadingExample=!0;const i=new Audio;let r;i.play();try{r=(await(0,u.S_)(this.hass,{platform:e,message:t,language:a,options:{voice:s}})).path}catch(t){return this._loadingExample=!1,void(0,g.showAlertDialog)(this,{text:`Unable to load example. ${t.error||t.body||t}`,warning:!0})}i.src=r,i.addEventListener("canplaythrough",()=>i.play()),i.addEventListener("playing",()=>{this._loadingExample=!1}),i.addEventListener("error",()=>{(0,g.showAlertDialog)(this,{title:"Error playing audio."}),this._loadingExample=!1})}constructor(...t){super(...t),this._loadingExample=!1,this._open=!1,this._valid=!1}}m.styles=[p.nA,r.AH`ha-select,ha-textarea{width:100%}ha-select{margin-top:8px}.loading{height:36px}`],(0,i.Cg)([(0,o.MZ)({attribute:!1})],m.prototype,"hass",void 0),(0,i.Cg)([(0,o.wk)()],m.prototype,"_loadingExample",void 0),(0,i.Cg)([(0,o.wk)()],m.prototype,"_open",void 0),(0,i.Cg)([(0,o.wk)()],m.prototype,"_params",void 0),(0,i.Cg)([(0,o.wk)()],m.prototype,"_valid",void 0),(0,i.Cg)([(0,o.P)("#message")],m.prototype,"_messageInput",void 0),(0,i.Cg)([(0,l.I)({key:"ttsTryMessages",state:!1,subscribe:!1})],m.prototype,"_messages",void 0),m=(0,i.Cg)([(0,o.EM)("dialog-tts-try")],m),s()}catch(t){s(t)}})},99324(t,e,a){a.a(t,async function(t,e){try{var s=a(5124),i=a(22441),r=a(6412),o=a(63672),l=a(34514),n=a(40991),h=a(92070),c=a(41268),d=a(9395),u=a(62676),p=a(15477),g=a(31896),b=a(32565),v=a(17060),m=a(9054),y=t([v]);v=(y.then?(await y)():y)[0];var w=Object.defineProperty,f=Object.getOwnPropertyDescriptor,x=(t,e,a,s)=>{for(var i,r=s>1?void 0:s?f(e,a):e,o=t.length-1;o>=0;o--)(i=t[o])&&(r=(s?i(e,a,r):i(r))||r);return s&&r&&w(e,a,r),r};let _=class extends u.q{static get validators(){return[...super.validators,(0,c.i)()]}get value(){return this.valueHasChanged?this._value:this._value??this.defaultValue}set value(t){this._value!==t&&(this.valueHasChanged=!0,this._value=t)}handleSizeChange(){(0,n.b)(this.localName,this.size)}connectedCallback(){super.connectedCallback(),this.updateComplete.then(()=>{if(this.setTextareaDimensions(),this.updateResizeObserver(),this.didSSR&&this.input&&this.value!==this.input.value){const t=this.input.value;this.value=t}})}disconnectedCallback(){super.disconnectedCallback(),clearTimeout(this.countAnnounceTimeout),this.resizeObserver?.disconnect(),this.resizeObserver=void 0}updateResizeObserver(){const t="none"!==this.resize;this.resizeObserver&&(this.resizeObserver.disconnect(),this.resizeObserver=void 0),t&&this.input&&("auto"===this.resize?(this.resizeObserver=new ResizeObserver(t=>{const e=t[0]?.contentRect.width??0;e!==this.lastObservedWidth&&(this.lastObservedWidth=e,requestAnimationFrame(()=>this.setTextareaDimensions()))}),this.resizeObserver.observe(this)):(this.resizeObserver=new ResizeObserver(()=>this.setTextareaDimensions()),this.resizeObserver.observe(this.input)))}handleBlur(){this.checkValidity()}handleChange(t){this.valueHasChanged=!0,this.value=this.input.value,this.setTextareaDimensions(),this.checkValidity(),this.relayNativeEvent(t,{bubbles:!0,composed:!0})}handleInput(t){this.valueHasChanged=!0,this.value=this.input.value,this.relayNativeEvent(t,{bubbles:!0,composed:!0}),this.scheduleCountAnnouncement()}scheduleCountAnnouncement(){clearTimeout(this.countAnnounceTimeout),this.countAnnounceTimeout=setTimeout(()=>{const t=(this.value??"").length;this.announcedCountText=null!=this.maxlength?this.localize.term("numCharactersRemaining",this.maxlength-t):this.localize.term("numCharacters",t)},1e3)}setTextareaDimensions(){if("none"===this.resize)return this.base.style.width="",void(this.base.style.height="");if("auto"===this.resize){this.sizeAdjuster.style.height=`${this.input.clientHeight}px`,this.input.style.height="auto";const t=this.input.scrollHeight;return this.input.style.height=`${t}px`,this.sizeAdjuster.style.height=`${t}px`,this.base.style.width="",void(this.base.style.height="")}if(this.input.style.width){const t=Number(this.input.style.width.split(/px/)[0])+2;this.base.style.width=`${t}px`}if(this.input.style.height){const t=Number(this.input.style.height.split(/px/)[0])+2;this.base.style.height=`${t}px`}}handleRowsChange(){this.setTextareaDimensions()}async handleValueChange(){await this.updateComplete,this.checkValidity(),this.setTextareaDimensions()}updated(t){t.has("resize")&&(this.setTextareaDimensions(),this.updateResizeObserver()),super.updated(t),t.has("value")&&this.customStates.set("blank",!this.value)}focus(t){this.input.focus(t)}blur(){this.input.blur()}select(){this.input.select()}scrollPosition(t){return t?("number"==typeof t.top&&(this.input.scrollTop=t.top),void("number"==typeof t.left&&(this.input.scrollLeft=t.left))):{top:this.input.scrollTop,left:this.input.scrollTop}}setSelectionRange(t,e,a="none"){this.input.setSelectionRange(t,e,a)}setRangeText(t,e,a,s="preserve"){const i=e??this.input.selectionStart,r=a??this.input.selectionEnd;this.input.setRangeText(t,i,r,s),this.value!==this.input.value&&(this.value=this.input.value,this.setTextareaDimensions())}formResetCallback(){this._value=null,this.input&&(this.input.value=this.value||""),super.formResetCallback()}render(){const t=this.hasUpdated?this.hasSlotController.test("label"):this.withLabel,e=this.hasUpdated?this.hasSlotController.test("hint"):this.withHint,a=!!this.label||!!t,i=!!this.hint||!!e,n=(this.value??"").length,h=null!=this.maxlength?this.localize.term("numCharactersRemaining",this.maxlength-n):this.localize.term("numCharacters",n);return s.qy` <label part="form-control-label label" class="${(0,r.H)({label:!0,"has-label":a})}" for="input" aria-hidden="${a?"false":"true"}"> <slot name="label">${this.label}</slot> </label> <div part="base" class="textarea"> <textarea part="textarea" id="input" class="control" title="${this.title}" name="${(0,o.J)(this.name)}" .value="${(0,l.V)(this.value)}" ?disabled="${this.disabled}" ?readonly="${this.readonly}" ?required="${this.required}" placeholder="${(0,o.J)(this.placeholder)}" rows="${(0,o.J)(this.rows)}" minlength="${(0,o.J)(this.minlength)}" maxlength="${(0,o.J)(this.maxlength)}" autocapitalize="${(0,o.J)(this.autocapitalize)}" autocorrect="${(0,o.J)(this.autocorrect)}" ?autofocus="${this.autofocus}" spellcheck="${(0,o.J)(this.spellcheck)}" enterkeyhint="${(0,o.J)(this.enterkeyhint)}" inputmode="${(0,o.J)(this.inputmode)}" aria-describedby="hint" ="${this.handleChange}" ="${this.handleInput}" ="${this.handleBlur}"></textarea> <div part="textarea-adjuster" class="size-adjuster" ?hidden="${"auto"!==this.resize}"></div> </div> <div class="${(0,r.H)({footer:!0,"has-count":this.withCount})}"> <slot id="hint" name="hint" part="hint" aria-hidden="${i?"false":"true"}" class="${(0,r.H)({"has-slotted":i})}">${this.hint}</slot> ${this.withCount?s.qy` <div part="count" class="count" aria-hidden="true">${h}</div> <div class="wa-visually-hidden-force" aria-live="polite">${this.announcedCountText}</div> `:""} </div> `}constructor(){super(...arguments),this.assumeInteractionOn=["blur","input"],this.hasSlotController=new h.X(this,"hint","label"),this.localize=new v.c(this),this.announcedCountText="",this.title="",this.name=null,this._value=null,this.defaultValue=this.getAttribute("value")??"",this.size="m",this.appearance="outlined",this.label="",this.hint="",this.placeholder="",this.rows=4,this.resize="vertical",this.disabled=!1,this.readonly=!1,this.required=!1,this.spellcheck=!0,this.withLabel=!1,this.withHint=!1,this.withCount=!1,this.lastObservedWidth=0}};_.css=[m.A,p.A,g.A,b.A],x([(0,i.wk)()],_.prototype,"announcedCountText",2),x([(0,i.P)(".control")],_.prototype,"input",2),x([(0,i.P)('[part~="base"]')],_.prototype,"base",2),x([(0,i.P)(".size-adjuster")],_.prototype,"sizeAdjuster",2),x([(0,i.MZ)()],_.prototype,"title",2),x([(0,i.MZ)({reflect:!0})],_.prototype,"name",2),x([(0,i.wk)()],_.prototype,"value",1),x([(0,i.MZ)({attribute:"value",reflect:!0})],_.prototype,"defaultValue",2),x([(0,i.MZ)({reflect:!0})],_.prototype,"size",2),x([(0,d.w)("size")],_.prototype,"handleSizeChange",1),x([(0,i.MZ)({reflect:!0})],_.prototype,"appearance",2),x([(0,i.MZ)()],_.prototype,"label",2),x([(0,i.MZ)({attribute:"hint"})],_.prototype,"hint",2),x([(0,i.MZ)()],_.prototype,"placeholder",2),x([(0,i.MZ)({type:Number})],_.prototype,"rows",2),x([(0,i.MZ)({reflect:!0})],_.prototype,"resize",2),x([(0,i.MZ)({type:Boolean})],_.prototype,"disabled",2),x([(0,i.MZ)({type:Boolean,reflect:!0})],_.prototype,"readonly",2),x([(0,i.MZ)({type:Boolean,reflect:!0})],_.prototype,"required",2),x([(0,i.MZ)({type:Number})],_.prototype,"minlength",2),x([(0,i.MZ)({type:Number})],_.prototype,"maxlength",2),x([(0,i.MZ)()],_.prototype,"autocapitalize",2),x([(0,i.MZ)({type:Boolean,converter:{fromAttribute:t=>!(!t||"off"===t),toAttribute:t=>t?"on":"off"}})],_.prototype,"autocorrect",2),x([(0,i.MZ)()],_.prototype,"autocomplete",2),x([(0,i.MZ)({type:Boolean})],_.prototype,"autofocus",2),x([(0,i.MZ)()],_.prototype,"enterkeyhint",2),x([(0,i.MZ)({type:Boolean,converter:{fromAttribute:t=>!(!t||"false"===t),toAttribute:t=>t?"true":"false"}})],_.prototype,"spellcheck",2),x([(0,i.MZ)()],_.prototype,"inputmode",2),x([(0,i.MZ)({attribute:"with-label",type:Boolean})],_.prototype,"withLabel",2),x([(0,i.MZ)({attribute:"with-hint",type:Boolean})],_.prototype,"withHint",2),x([(0,i.MZ)({attribute:"with-count",type:Boolean,reflect:!0})],_.prototype,"withCount",2),x([(0,d.w)("rows",{waitUntilFirstUpdate:!0})],_.prototype,"handleRowsChange",1),x([(0,d.w)("value",{waitUntilFirstUpdate:!0})],_.prototype,"handleValueChange",1),_=x([(0,i.EM)("wa-textarea")],_),_.disableWarning?.("change-in-update"),e()}catch(t){e(t)}})},9054(t,e,a){a.d(e,{A:()=>s});var s=a(5124).AH`:host{border-width:0}.textarea{display:grid;align-items:center;margin:0;border:none;outline:0;cursor:inherit;font:inherit;background-color:var(--wa-form-control-background-color);border-color:var(--wa-form-control-border-color);border-radius:var(--wa-form-control-border-radius);border-style:var(--wa-form-control-border-style);border-width:var(--wa-form-control-border-width);-webkit-appearance:none;outline:var(--wa-focus-ring-style) var(--wa-focus-ring-width) transparent;outline-offset:var(--wa-focus-ring-offset)}.textarea:focus-within{outline-color:var(--wa-color-focus)}:host([appearance=outlined]) .textarea{background-color:var(--wa-form-control-background-color);border-color:var(--wa-form-control-border-color)}:host([appearance=filled]) .textarea{background-color:var(--wa-color-neutral-fill-quiet);border-color:var(--wa-color-neutral-fill-quiet)}:host([appearance=filled-outlined]) .textarea{background-color:var(--wa-color-neutral-fill-quiet);border-color:var(--wa-form-control-border-color)}textarea{display:block;width:100%;border:none;background:0 0;font:inherit;color:inherit;padding:calc(var(--wa-form-control-padding-block) - ((1lh - 1em)/ 2)) var(--wa-form-control-padding-inline);min-height:calc(var(--wa-form-control-height) - var(--border-width) * 2);box-shadow:none;margin:0}textarea::placeholder{color:var(--wa-form-control-placeholder-color);user-select:none;-webkit-user-select:none}textarea:autofill,textarea:autofill:active,textarea:autofill:focus,textarea:autofill:hover{box-shadow:none;caret-color:var(--wa-form-control-value-color)}textarea:focus{outline:0}.control,.size-adjuster{grid-area:1/1/2/2}.size-adjuster{visibility:hidden;pointer-events:none;opacity:0;padding:0}textarea::-webkit-search-cancel-button,textarea::-webkit-search-decoration,textarea::-webkit-search-results-button,textarea::-webkit-search-results-decoration{-webkit-appearance:none}:host([resize=none]) textarea{resize:none}:host([resize=vertical]) textarea,textarea{resize:vertical}:host([resize=horizontal]) textarea{resize:horizontal}:host([resize=both]) textarea{resize:both}:host([resize=auto]) textarea{height:auto;resize:none;overflow-y:hidden}.footer{display:flex;align-items:baseline;gap:1em}.footer.has-count [part=hint]{flex:1 1 auto;min-width:0}.count{flex:0 0 auto;color:var(--wa-form-control-hint-color);font-weight:var(--wa-form-control-hint-font-weight);line-height:var(--wa-form-control-hint-line-height);margin-block-start:0.5em;font-size:var(--wa-font-size-smaller);margin-inline-start:auto}`},32565(t,e,a){a.d(e,{A:()=>s});var s=a(5124).AH`.wa-visually-hidden-force,.wa-visually-hidden-hint::part(hint),.wa-visually-hidden-label::part(form-control-label),.wa-visually-hidden-label::part(label),.wa-visually-hidden:not(:focus-within){position:absolute!important;width:1px!important;height:1px!important;clip:rect(0 0 0 0)!important;clip-path:inset(50%)!important;border:none!important;overflow:hidden!important;white-space:nowrap!important;padding:0!important}`}};