export const __rspack_esm_id=54957;export const __rspack_esm_ids=[54957];export const __webpack_modules__={2467(t,e,s){var a=s(56245);let i;s.d(e,{},{G5:(t,e,s)=>t.callWS({type:"zone/update",zone_id:e,...s}),Rz:t=>{i=t,(0,a.oo)("/config/zone/new")},TW:(t,e)=>t.callWS({type:"zone/create",...e}),YC:t=>t.callWS({type:"zone/list"}),Yx:(t,e)=>t.callWS({type:"zone/delete",zone_id:e}),kg:()=>{const t=i;return i=void 0,t}})},28252(t,e,s){s.a(t,async function(t,a){try{s.r(e);var i=s(15697),o=s(358),n=s(57527),r=s(79224),c=s(90789),l=s(49938),p=s(67259),u=s(148),_=s(24034),d=s(98747),h=s(68014),b=s(80189),y=s(2467),g=t([d,h]);[d,h]=g.then?(await g)():g;class m extends n.WF{render(){if(!this._localize||!this.stateObj)return n.s6;const t=(0,_.H)(this.stateObj,this._states),e="number"==typeof this.stateObj.attributes.latitude&&"number"==typeof this.stateObj.attributes.longitude;return n.qy` ${t?n.qy` <ha-map .entities=${this._entityArray(this.stateObj.entity_id)} auto-fit></ha-map> `:""} ${this._user?.is_admin&&e?n.qy` <div class="actions"> <ha-button appearance="plain" size="s" @click=${this._handleAction}> ${this._localize("ui.dialogs.more_info_control.person.create_zone")} </ha-button> </div> `:""} `}_handleAction(){(0,y.Rz)({latitude:this.stateObj.attributes.latitude,longitude:this.stateObj.attributes.longitude}),(0,u.r)(this,"hass-more-info",{entityId:null})}constructor(...t){super(...t),this._entityArray=(0,c.A)(t=>[t])}}m.styles=n.AH`.flex{justify-content:space-between;display:flex}.actions{margin:var(--ha-space-2) 0;text-align:right}ha-map{margin-top:var(--ha-space-4);margin-bottom:var(--ha-space-4)}`,(0,i.Cg)([(0,r.MZ)({attribute:!1})],m.prototype,"stateObj",void 0),(0,i.Cg)([(0,r.wk)(),(0,l.IW)()],m.prototype,"_localize",void 0),(0,i.Cg)([(0,r.wk)(),(0,o.Fg)({context:b.iN,subscribe:!0})],m.prototype,"_states",void 0),(0,i.Cg)([(0,r.wk)(),(0,o.Fg)({context:b.WF,subscribe:!0}),(0,p.p)({transformer:({user:t})=>t})],m.prototype,"_user",void 0),m=(0,i.Cg)([(0,r.EM)("more-info-person")],m),a()}catch(t){a(t)}})}};
//# sourceMappingURL=54957.0f3caa6e78395e87.js.map