@synergy-design-system/components
Version:
This package provides the base of the Synergy Design System as native web components. It uses [lit](https://www.lit.dev) and parts of [shoelace](https://shoelace.style/). Synergy officially supports the latest two versions of all major browsers (as define
30 lines (29 loc) • 1.37 kB
TypeScript
/**
* ---------------------------------------------------------------------
* 🔒 AUTOGENERATED BY VENDORISM
* Removing this comment will prevent it from being managed by it.
* ---------------------------------------------------------------------
*/
import type { ReactiveController, ReactiveControllerHost } from 'lit';
/** A reactive controller that determines when slots exist. */
export declare class HasSlotController implements ReactiveController {
host: ReactiveControllerHost & Element;
slotNames: string[];
constructor(host: ReactiveControllerHost & Element, ...slotNames: string[]);
private hasDefaultSlot;
private hasNamedSlot;
test(slotName: string): boolean;
hostConnected(): void;
hostDisconnected(): void;
private handleSlotChange;
}
/**
* Given a slot, this function iterates over all of its assigned element and text nodes and returns the concatenated
* HTML as a string. This is useful because we can't use slot.innerHTML as an alternative.
*/
export declare function getInnerHTML(slot: HTMLSlotElement): string;
/**
* Given a slot, this function iterates over all of its assigned text nodes and returns the concatenated text as a
* string. This is useful because we can't use slot.textContent as an alternative.
*/
export declare function getTextContent(slot: HTMLSlotElement | undefined | null): string;