/** * @license * Copyright 2023 Nuraly, Laabidi Aymen * SPDX-License-Identifier: MIT */ import { LitElement } from 'lit'; import { ThemeAware } from './theme-mixin.js'; import { DependencyAware } from './dependency-mixin.js'; import { EventHandlerCapable } from './event-handler-mixin.js'; /** * Interface for Light DOM content projection (replacement for Shadow DOM ) */ export interface LightDomContent { /** Default-slot children (nodes without a `slot` attribute) */ readonly lightChildren: Node[]; /** Named-slot children (elements with `slot="name"`) */ lightChildrenNamed(name: string): Element[]; } /** * Base interface combining theme awareness, dependency validation, event handling, and Light DOM content */ export interface NuralyUIBaseElement extends ThemeAware, DependencyAware, EventHandlerCapable, LightDomContent { } type Constructor = new (...args: any[]) => T; /** * Global base mixin that combines Light DOM, style injection, ThemeAwareMixin, * DependencyValidationMixin, and EventHandlerMixin. * * Uses **Light DOM** rendering so external CSS can reach component internals. * Component styles are injected once per tag into `document.adoptedStyleSheets`. * * Instead of ``, use: * - `this.lightChildren` for default slot content * - `this.lightChildrenNamed('name')` for named slot content * * @param superClass - The base class to extend (typically LitElement) */ export declare const NuralyUIBaseMixin: >(superClass: T) => (new (...args: any[]) => DependencyAware) & (new (...args: any[]) => ThemeAware) & (new (...args: any[]) => EventHandlerCapable) & Constructor & T; /** * Alternative shorter name for convenience */ export declare const BaseMixin: >(superClass: T) => (new (...args: any[]) => DependencyAware) & (new (...args: any[]) => ThemeAware) & (new (...args: any[]) => EventHandlerCapable) & Constructor & T; export {}; //# sourceMappingURL=base-mixin.d.ts.map