"use strict";(self.webpackChunkhome_assistant_frontend=self.webpackChunkhome_assistant_frontend||[]).push([["38545"],{36872:function(t,e,i){i.a(t,async function(t,s){try{i.r(e);i(18111),i(61701);var a=i(40445),n=i(96196),r=i(77845),o=i(82286),c=i(606),h=t([c]);c=(h.then?(await h)():h)[0];let l,u,d,v=t=>t;class y extends n.WF{render(){var t;if(!this.hass||!this.stateObj)return n.s6;const e=this.stateObj;return(0,n.qy)(l||(l=v` ${0} `),(0,o.$)(e,4)?(0,n.qy)(u||(u=v` <ha-select .label="${0}" .value="${0}" @selected="${0}" .options="${0}"> </ha-select> `),this.hass.localize("ui.dialogs.more_info_control.remote.activity"),e.attributes.current_activity||"",this._handleActivityChanged,null===(t=e.attributes.activity_list)||void 0===t?void 0:t.map(t=>({value:t,label:this.hass.formatEntityAttributeValue(e,"activity",t)}))):n.s6)}_handleActivityChanged(t){const e=this.stateObj.attributes.current_activity,i=t.detail.value;i&&e!==i&&this.hass.callService("remote","turn_on",{entity_id:this.stateObj.entity_id,activity:i})}}y.styles=(0,n.AH)(d||(d=v`ha-select{width:100%}`)),(0,a.Cg)([(0,r.MZ)({attribute:!1})],y.prototype,"hass",void 0),(0,a.Cg)([(0,r.MZ)({attribute:!1})],y.prototype,"stateObj",void 0),y=(0,a.Cg)([(0,r.EM)("more-info-remote")],y),s()}catch(l){s(l)}})}}]);
//# sourceMappingURL=38545.a152d0cc58376d85.js.map