import { SvelteComponentTyped } from "svelte"; import type { HTMLAttributes } from "svelte/elements"; export type LayerLevel = 0 | 1 | 2; export type CarbonLayerContext = import("svelte/store").Readable; type $RestProps = HTMLAttributes; type $Props = { /** * Set the layer level: `0` is the page surface, `2` the highest. By * default a layer sits one level above its parent `Layer`, so a * top-level layer is level 1. */ level?: LayerLevel | undefined; /** * Set to `true` to paint the layer's background * @default false */ withBackground?: boolean; /** * Specify the tag name. * @default "div" */ tag?: keyof HTMLElementTagNameMap; children?: (this: void, ...args: [{ level: LayerLevel }]) => void; [key: `data-${string}`]: unknown; }; export type LayerProps = Omit<$RestProps, keyof $Props> & $Props; export default class Layer extends SvelteComponentTyped< LayerProps, Record, { default: { level: LayerLevel } } > {}