// #region Imports
// #endregion
/**
 * Decorator to create a getter for the specified selector
 * @param selector selector to find the element
 */
export function QueryChild(selector) {
    return (prototype, propertyName) => {
        Object.defineProperty(prototype, propertyName, {
            get() {
                const element = this;
                return element.shadowRoot?.querySelector(selector);
            },
            enumerable: true,
            configurable: true
        });
    };
}
/**
 * Decorator to create a getter for the specified selector
 * @param selector selector to find the element
 */
export function QueryChildren(selector) {
    return (prototype, propertyName) => {
        Object.defineProperty(prototype, propertyName, {
            get() {
                const element = this;
                const elements = element.shadowRoot?.querySelectorAll(selector);
                return elements
                    ? Array.from(elements)
                    : elements;
            },
            enumerable: true,
            configurable: true
        });
    };
}
//# sourceMappingURL=QueryChildDecorator.js.map