import*as e from"lit";import*as t from"lit/directives/if-defined.js";import*as r from"lit/directives/class-map.js";import*as i from"lit/decorators.js";var s,o,a={2927(t,r,i){var s,o;t.exports=(s={LitElement:()=>e.LitElement,css:()=>e.css,html:()=>e.html,nothing:()=>e.nothing},o={},i.d(o,s),o)},3517(e,r,i){var s,o;e.exports=(s={ifDefined:()=>t.ifDefined},o={},i.d(o,s),o)},3949(e,t,r){r.d(t,{s:()=>i});var i,s=r(7704),o=r(9609),a=r(4084),l=r(2927),p=r(8899),d=r(4955),n=r(3517),m=r(7231),c=function(e,t,r,i){var s,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,r):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,r,i);else for(var l=e.length-1;l>=0;l--)(s=e[l])&&(a=(o<3?s(a):o>3?s(t,r,a):s(t,r))||a);return o>3&&a&&Object.defineProperty(t,r,a),a};!function(e){let t=class extends((0,s.yC)(l.LitElement)){constructor(){super(...arguments),this.tabIndex=-1,this.label="",this.value="",this.message="",this.hideMessage=!1,this.ariaLabel="",this.autofocus=!1,this._disabled=!1,this.checked=!1}get disabled(){return this._disabled}set disabled(e){const t=this._disabled;this._disabled=e,this.tabIndex=e?-1:0,this.requestUpdate("disabled",t)}get inputAriaLabel(){var e,t,r,i;const s=(null===(e=this.message)||void 0===e?void 0:e.length)?` - ${this.message}`:"";if(null===(t=this.ariaLabel)||void 0===t?void 0:t.length)return this.ariaLabel;if(null===(r=this.label)||void 0===r?void 0:r.length)return this.label+s;const o=null===(i=this.textContent)||void 0===i?void 0:i.trim();return(null==o?void 0:o.length)?o+s:s}static get styles(){return[a.A,m.A]}get helpTextClassMap(){return{"md-radio-help-text--hide":this.hideMessage}}messagesTemplate(){var e;return(null===(e=this.message)||void 0===e?void 0:e.length)?l.html`
            <div class="${(0,d.classMap)(this.helpTextClassMap)}">
              <md-help-text class="help-text-radio" newMomentum role="alert" aria-live="assertive">
                ${this.message}
              </md-help-text>
            </div>
          `:l.nothing}render(){return l.html`
        <div>
          <slot name="image"></slot>
          <div class="md-radio-wrapper" part="radio-wrapper">
            <div class="md-radio-icon"></div>
            <input
              class="md-radio-input"
              part="radio-input"
              type="radio"
              role="radio"
              aria-label=${(0,n.ifDefined)(this.inputAriaLabel)}
              aria-checked=${this.checked?"true":"false"}
              .value=${this.value}
              ?checked=${this.checked}
              ?autofocus=${this.autofocus}
              ?disabled=${this.disabled}
              tabindex="-1"
              id="radio-label"
            />
            <label
              for="radio-label"
              class="md-radio-label"
              part="radio-label"
              @click=${e=>e.preventDefault()}
            >
              <slot></slot>
            </label>
          </div>
        </div>
        ${this.messagesTemplate()}
      `}};c([(0,p.property)({type:Number,reflect:!0})],t.prototype,"tabIndex",void 0),c([(0,p.property)({type:String})],t.prototype,"label",void 0),c([(0,p.property)({type:String})],t.prototype,"value",void 0),c([(0,p.property)({type:String})],t.prototype,"message",void 0),c([(0,p.property)({type:Boolean})],t.prototype,"hideMessage",void 0),c([(0,p.property)({type:String})],t.prototype,"ariaLabel",void 0),c([(0,p.property)({type:Boolean,reflect:!0})],t.prototype,"autofocus",void 0),c([(0,p.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",null),c([(0,p.property)({type:Boolean,reflect:!0})],t.prototype,"checked",void 0),t=c([(0,o.w)("md-radio")],t),e.ELEMENT=t}(i||(i={}))},4955(e,t,i){var s,o;e.exports=(s={classMap:()=>r.classMap},o={},i.d(o,s),o)},8899(e,t,r){var s,o;e.exports=(s={property:()=>i.property},o={},r.d(o,s),o)}},l={};function p(e){var t=l[e];if(void 0!==t)return t.exports;var r=l[e]={exports:{}};return a[e](r,r.exports,p),r.exports}p.m=a,s=[],p.O=(e,t,r,i)=>{if(!t){var o=1/0;for(n=0;n<s.length;n++){for(var[t,r,i]=s[n],a=!0,l=0;l<t.length;l++)(!1&i||o>=i)&&Object.keys(p.O).every(e=>p.O[e](t[l]))?t.splice(l--,1):(a=!1,i<o&&(o=i));if(a){s.splice(n--,1);var d=r();void 0!==d&&(e=d)}}return e}i=i||0;for(var n=s.length;n>0&&s[n-1][2]>i;n--)s[n]=s[n-1];s[n]=[t,r,i]},p.d=(e,t)=>{for(var r in t)p.o(t,r)&&!p.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},p.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);export{p as __webpack_require__};o={502:0,1745:0,4928:0,5369:0,6060:0,6587:0,8111:0,8442:0},p.C=e=>{var t,r,{__webpack_esm_ids__:i,__webpack_esm_modules__:s,__webpack_esm_runtime__:a}=e,l=0;for(t in s)p.o(s,t)&&(p.m[t]=s[t]);for(a&&a(p);l<i.length;l++)r=i[l],p.o(o,r)&&o[r]&&o[r][0](),o[i[l]]=0;p.O()},p.O.j=e=>0===o[e];import*as d from"../9609.js";p.C(d);import*as n from"../4084.js";p.C(n);import*as m from"../2364.js";p.C(m);import*as c from"../9938.js";p.C(c);import*as h from"../4781.js";p.C(h);import*as v from"../5201.js";p.C(v);import*as f from"../5584.js";p.C(f);import*as u from"../8227.js";p.C(u);import*as b from"../7704.js";p.C(b);import*as y from"../5757.js";p.C(y);import*as g from"../7231.js";p.C(g);var x=p.O(void 0,[9609,4084,2364,9938,4781,5201,5584,8227,7704,5757,7231],()=>p(3949));const _=(x=p.O(x)).s;export{_ as Radio};