iobroker.lovelace
Version:
With this adapter you can build visualization for ioBroker with Home Assistant Lovelace UI
1 lines • 2.27 kB
JavaScript
"use strict";(self.rspackChunkhome_assistant_frontend=self.rspackChunkhome_assistant_frontend||[]).push([[24096],{95683:function(o,t,i){i.a(o,async function(o,a){try{i.r(t),i.d(t,{DialogYamlIntegration:function(){return y}});i(62953);var n=i(40445),s=i(5124),e=i(67576),l=i(1087),r=i(36918),c=i(18350),h=(i(93444),i(67094),i(72554)),p=o([c,h]);[c,h]=p.then?(await p)():p;let g,d,u,_,f=o=>o;const m="M14,3V5H17.59L7.76,14.83L9.17,16.24L19,6.41V10H21V3M19,19H5V5H12V3H5C3.89,3 3,3.9 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V12H19V19Z";class y extends s.WF{showDialog(o){this._params=o,this._open=!0}closeDialog(){this._open=!1}_dialogClosed(){this._params=void 0,(0,l.r)(this,"dialog-closed",{dialog:this.localName})}render(){if(!this._params)return s.s6;const o=this._params.manifest,t=o.is_built_in?(0,r.o)(this.hass,`/integrations/${o.domain}`):o.documentation;return(0,s.qy)(g||(g=f` <ha-dialog .open="${0}" header-title="${0}" ="${0}"> <p> ${0} </p> <ha-dialog-footer slot="footer"> <ha-button slot="secondaryAction" appearance="plain" ="${0}"> ${0} </ha-button> ${0} </ha-dialog-footer> </ha-dialog> `),this._open,this.hass.localize("ui.panel.config.integrations.config_flow.yaml_only_title"),this._dialogClosed,this.hass.localize("ui.panel.config.integrations.config_flow.yaml_only"),this.closeDialog,this.hass.localize("ui.common.cancel"),t?(0,s.qy)(d||(d=f`<ha-button slot="primaryAction" appearance="plain" href="${0}" target="_blank" rel="noreferrer noopener" ="${0}" autofocus> <ha-svg-icon slot="end" .path="${0}"></ha-svg-icon> ${0} </ha-button>`),t,this.closeDialog,m,this.hass.localize("ui.panel.config.integrations.config_flow.open_documentation")):(0,s.qy)(u||(u=f`<ha-button slot="primaryAction" ="${0}" autofocus> ${0} </ha-button>`),this.closeDialog,this.hass.localize("ui.common.ok")))}constructor(...o){super(...o),this._open=!1}}y.styles=(0,s.AH)(_||(_=f`:host([inert]){pointer-events:initial!important;cursor:initial!important}a{text-decoration:none}ha-dialog{--dialog-z-index:104}`)),(0,n.Cg)([(0,e.MZ)({attribute:!1})],y.prototype,"hass",void 0),(0,n.Cg)([(0,e.wk)()],y.prototype,"_params",void 0),(0,n.Cg)([(0,e.wk)()],y.prototype,"_open",void 0),y=(0,n.Cg)([(0,e.EM)("dialog-yaml-integration")],y),a()}catch(g){a(g)}})}}]);