import{proxyCustomElement as e,HTMLElement as t,createEvent as i,h as o,transformTag as r}from"@stencil/core/internal/client";const l=e(class extends t{constructor(e){super(),!1!==e&&this.__registerHost(),this.__attachShadow(),this.change=i(this,"change",7),this.getOptionValue=e=>e.value||void 0,this.handleChangeOptions=(e,t=e=>e)=>i=>{i.stopPropagation(),this.change.emit(Object.assign(Object.assign({},this.value),{options:Object.assign(Object.assign({},this.value.options),{[e]:t(i.detail)||void 0})}))}}render(){return[this.renderStyle(),this.renderNumeric()]}renderStyle(){const e=[{value:"long",text:"Long"},{value:"narrow",text:"Narrow"},{value:"short",text:"Short"}],t=e.find((e=>{var t;return e.value&&e.value===(null===(t=this.value.options)||void 0===t?void 0:t.style)}));return o("limel-select",{label:"Style",helperText:"The style of the formatted relative time",options:e,value:t,onChange:this.handleChangeOptions("style",this.getOptionValue)})}renderNumeric(){const e=[{value:"always",text:"Always",secondaryText:'E.g. "in 1 day"'},{value:"auto",text:"Auto",secondaryText:'E.g. "tomorrow"'}],t=e.find((e=>{var t;return e.value&&e.value===(null===(t=this.value.options)||void 0===t?void 0:t.numeric)}));return o("limel-select",{label:"Numeric",helperText:"Whether to use numeric values in the output",options:e,value:t,onChange:this.handleChangeOptions("numeric",this.getOptionValue)})}},[1,"limebb-info-tile-relative-date-format",{value:[16]}]),n=l,s=function(){"undefined"!=typeof customElements&&["limebb-info-tile-relative-date-format"].forEach((e=>{"limebb-info-tile-relative-date-format"===e&&(customElements.get(r(e))||customElements.define(r(e),l))}))};export{n as LimebbInfoTileRelativeDateFormat,s as defineCustomElement}