1var __defProp = Object.defineProperty; 2var __name = (target, value) => __defProp(target, "name", { value, configurable: !0 }); 3import { u as uuidv4 } from "../chunks/chunk.dcf-utility.js?v=6.1.6"; 4class UNLRandomizer { 5 static { 6 __name(this, "UNLRandomizer"); 7 } 8 uuid = uuidv4(); 9 randomizerContainer = null; 10 constructor(randomizerContainer) { 11 this.randomizerContainer = randomizerContainer, (this.randomizerContainer.getAttribute("id") === "" || this.randomizerContainer.getAttribute("id") === null) && this.randomizerContainer.setAttribute("id", this.uuid.concat("-randomizer")); 12 const randomChild = Math.floor(Math.random() * this.randomizerContainer.children.length); 13 Array.from(this.randomizerContainer.children).forEach((singleChild, index) => { 14 singleChild.classList.add("dcf-d-none!"), index === randomChild && singleChild.classList.remove("dcf-d-none!"); 15 }), this.randomizerContainer.classList.add("unl-randomizer-initialized"), this.randomizerContainer.removeAttribute("hidden"), this.randomizerContainer.dispatchEvent(new CustomEvent(UNLRandomizer.events("randomizerReady"), { 16 detail: { 17 classInstance: this 18 } 19 })), window.UNL = window.UNL || {}, window.UNL.classes = window.UNL.classes || {}, window.UNL.classes[this.randomizerContainer.getAttribute("id")] = this, this.randomizerContainer.dispatchEvent(new Event("UNLClassReady")); 20 } 21 // The names of the events to be used easily 22 static events(name) { 23 const events = { 24 dialogReady: "randomizerReady" 25 }; 26 return Object.freeze(events), name in events ? events[name] : void 0; 27 } 28} 29export { 30 UNLRandomizer as default 31}; 32//# sourceMappingURL=component.randomizer.js.map
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.