import { type PropertyValues } from 'lit'; import { UiElement } from '../shared/element.js'; /** * Carbon `Layer` (`cds-layer`): a zone at one level of the layering model. Fields, menus, borders and * hover/selected fills inside it use that level's layer set of the current theme (white: level 0 #f4f4f4, the page's * own; level 1 #ffffff; level 2 #f4f4f4), so a field on a tile stays distinguishable from the tile: on a tile, use level 1. * * `level` 0 = the page's own set (same as outside any layer), 1 and 2 go deeper. As Carbon's `cds-layer`, a layer * outside any other is level 0 and one nested in another gets the parent's level + 1 (capped at 2); set `level` * to override; a later change of a layer's level reaches the automatic levels inside (as Carbon React's context and * `cds-layer`'s `updated`). (Carbon React's ``, and the React `Layer` here, start at 1.) * The shift is part of this element's own styles, so a layer works inside any shadow root. Theme zones * (`data-theme`) are document-level rules in tokens.css: inside a shadow root of your own, adopt tokens.css there too. * * @slot - Content * @csspart base - The wrapper * @cssprop --ui-layer-border / --ui-layer-radius - With `with-background`: its border and corner radius (default none, 0: Carbon's square, unbordered zone, Kanok too) */ export declare class UiLayer extends UiElement { static readonly styles: import("lit").CSSResult[]; /** 0, 1 or 2. Computed from the nearest ancestor layer when not set. */ get level(): number; set level(value: number); private ownLevel; private levelSet; /** Paint the layer with Carbon's `layer-background` (`withBackground`): the colour its content sits on (white theme, level 1: #f4f4f4 under #ffffff fields). */ withBackground: boolean; /** An automatic level follows the layer around it (also called by a layer whose level changed); a set one stays. */ syncLevel(): void; connectedCallback(): void; protected updated(changed: PropertyValues): void; render(): import("lit-html").TemplateResult<1>; } /** Level of the closest `` above `el` (through shadow roots), or -1 at the page root. */ export declare function parentLevel(el: Element): number; declare global { interface HTMLElementTagNameMap { 'ui-layer': UiLayer; } }