Extend Foundry's MultiSelectElement so that I can provide a label to it

This commit is contained in:
Oliver-Akins 2025-04-27 20:46:55 -06:00
parent 5e9b91b199
commit d858aa5b66
5 changed files with 53 additions and 0 deletions

View file

@ -0,0 +1,19 @@
import { CustomMultiSelect } from "./CustomMultiSelect.mjs";
import { Logger } from "../../utils/Logger.mjs";
const components = [
CustomMultiSelect,
];
export function registerCustomComponents() {
(CONFIG.CACHE ??= {}).componentListeners ??= [];
for (const component of components) {
if (!window.customElements.get(component.tagName)) {
Logger.debug(`Registering component "${component.tagName}"`);
window.customElements.define(
component.tagName,
component,
);
};
}
};