oswilno/crates/web-assets/assets/build.js

3 lines
438 B
JavaScript
Raw Normal View History

2023-08-01 16:29:03 +02:00
(()=>{customElements.define(class extends HTMLElement{constructor(){let o=this.createShadowRoot({open:!0})}connectedCallback(){let o=this.shadowRoot,t=parseInt(this.getAttribute("price"));isNaN(t)&&(t=0);let i=parseInt(this.getAttribute("multiplier")),s=t,e=0;isNaN(i)||(s=Math.floor(t/i),e=t%i),o.innerHTML=`<style>:host{display:block;}</style><div>${s}.${e>=10?e:e+"0"}</div>`}},"oswilno-price");})();
//# sourceMappingURL=build.js.map