iobroker.lovelace
Version:
With this adapter you can build visualization for ioBroker with Home Assistant Lovelace UI
1 lines • 1.88 kB
JavaScript
export const __rspack_esm_id=21833;export const __rspack_esm_ids=[21833];export const __webpack_modules__={976(e,a,t){t.a(e,async function(e,i){try{t.r(a),t.d(a,{HuiIframeCardEditor:()=>u});var o=t(62826),r=t(5124),s=t(22441),c=t(63533),l=t(1087),n=t(52763),d=t(84698),h=e([n]);n=(h.then?(await h)():h)[0];const _=(0,c.kp)(d.H,(0,c.Ik)({title:(0,c.lq)((0,c.Yj)()),url:(0,c.lq)((0,c.Yj)()),aspect_ratio:(0,c.lq)((0,c.Yj)()),allow_open_top_navigation:(0,c.lq)((0,c.zM)()),hide_background:(0,c.lq)((0,c.zM)())})),p=[{name:"title",selector:{text:{}}},{name:"",type:"grid",schema:[{name:"url",required:!0,selector:{text:{}}},{name:"aspect_ratio",selector:{text:{}}}]},{name:"hide_background",selector:{boolean:{}}}];class u extends r.WF{setConfig(e){(0,c.vA)(e,_),this._config=e}render(){return this.hass&&this._config?r.qy` <ha-form .hass="${this.hass}" .data="${this._config}" .schema="${p}" .computeLabel="${this._computeLabelCallback}" .computeHelper="${this._computeHelperCallback}" @value-changed="${this._valueChanged}"></ha-form> `:r.s6}_valueChanged(e){(0,l.r)(this,"config-changed",{config:e.detail.value})}constructor(...e){super(...e),this._computeLabelCallback=e=>"hide_background"===e.name?this.hass.localize("ui.panel.lovelace.editor.card.iframe.hide_background"):this.hass.localize(`ui.panel.lovelace.editor.card.generic.${e.name}`),this._computeHelperCallback=e=>"hide_background"===e.name?this.hass.localize("ui.panel.lovelace.editor.card.iframe.hide_background_helper"):""}}(0,o.Cg)([(0,s.MZ)({attribute:!1})],u.prototype,"hass",void 0),(0,o.Cg)([(0,s.wk)()],u.prototype,"_config",void 0),u=(0,o.Cg)([(0,s.EM)("hui-iframe-card-editor")],u),i()}catch(e){i(e)}})},84698(e,a,t){t.d(a,{H:()=>o});var i=t(63533);const o=(0,i.Ik)({type:(0,i.Yj)(),view_layout:(0,i.bz)(),layout_options:(0,i.bz)(),grid_options:(0,i.bz)(),visibility:(0,i.bz)(),disabled:(0,i.lq)((0,i.zM)())})}};