UNPKG

@senx/discovery-widgets

Version:

Discovery Widgets Elements

88 lines (87 loc) 3.22 kB
/* * Copyright 2022-2025 SenX S.A.S. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ import { h, Host } from "@stencil/core"; export class DiscoverySpinner { constructor() { this.message = 'Loading...'; this.backdrop = false; } // noinspection JSUnusedGlobalSymbols componentDidLoad() { this.message = this.el.innerText || this.message; } render() { return (h(Host, { key: '91a3d7d01a085c11915e80ac04b4c8e849462e63' }, h("div", { key: '19e9d3ffec94ad3621ab64bea190ac9ea46f9f82', class: { 'discovery-back-drop': this.backdrop } }, h("div", { key: '455c76f51ec6fbf7e3c89221e0b2522bbb767df5', class: "loader" }), h("span", { key: 'eb75f7e55317f4fc2196e585d0660263e26d081a', class: "message" }, this.message), h("span", { key: '278780b6af15a0be7d56867540a6a403b6db2de8', class: "hidden" }, h("slot", { key: '254bc50acb3c3f4418ed20c29755922f9bdf1692' }))))); } static get is() { return "discovery-spinner"; } static get encapsulation() { return "shadow"; } static get originalStyleUrls() { return { "$": ["discovery-spinner.scss"] }; } static get styleUrls() { return { "$": ["discovery-spinner.css"] }; } static get properties() { return { "message": { "type": "string", "mutable": true, "complexType": { "original": "string", "resolved": "string", "references": {} }, "required": false, "optional": false, "docs": { "tags": [], "text": "" }, "getter": false, "setter": false, "attribute": "message", "reflect": false, "defaultValue": "'Loading...'" }, "backdrop": { "type": "boolean", "mutable": true, "complexType": { "original": "boolean", "resolved": "boolean", "references": {} }, "required": false, "optional": false, "docs": { "tags": [], "text": "" }, "getter": false, "setter": false, "attribute": "backdrop", "reflect": false, "defaultValue": "false" } }; } static get elementRef() { return "el"; } } //# sourceMappingURL=discovery-spinner.js.map