import * as _angular_core from '@angular/core'; import { TemplateRef } from '@angular/core'; /** * @license * * Use of this source code is governed by an MIT-style license that can be * found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE */ /** Side of the viewport the drawer slides in from. */ type WrDrawerPosition = 'left' | 'right' | 'top' | 'bottom'; /** * Side panel that slides in from an edge of the viewport. Two-way binds * `open` and renders into a CDK overlay so it sits above page content. * * Compose the body with ``, ``, and * `` directives. * * @example * ```html * *

Settings

*
...
*
* Close *
*
* ``` * * @see https://ngwr.dev/components/drawer */ declare class WrDrawer { /** Two-way bindable open state. */ readonly open: _angular_core.ModelSignal; /** Side the drawer slides in from. @default 'right' */ readonly position: _angular_core.InputSignal; /** Width when position is left/right. Any CSS length. @default '20rem' */ readonly width: _angular_core.InputSignal; /** Height when position is top/bottom. Any CSS length. @default '16rem' */ readonly height: _angular_core.InputSignal; /** * Upper cap on height (top/bottom positions). Useful for bottom sheets * that should grow with content up to a viewport-relative max. * Any CSS length. @default null (no cap) */ readonly maxHeight: _angular_core.InputSignal; /** * Round the leading corners — the edge facing the viewport interior. * Common bottom-sheet styling. @default false */ readonly rounded: _angular_core.InputSignalWithTransform; /** * Render a grab handle at the leading edge and enable swipe-to-dismiss: * drag the handle toward the drawer's edge (down for `bottom`, left for * `left`, …) and release past ~30% of the panel to close. @default false */ readonly showHandle: _angular_core.InputSignalWithTransform; /** * Pad the trailing edge with `env(safe-area-inset-*)` so content * doesn't sit under the iOS home indicator. @default false */ readonly safeArea: _angular_core.InputSignalWithTransform; /** Show the dimming backdrop. @default true */ readonly hasBackdrop: _angular_core.InputSignalWithTransform; /** Close when the backdrop is clicked. @default true */ readonly closeOnBackdropClick: _angular_core.InputSignalWithTransform; /** Close on Escape. @default true */ readonly closeOnEscape: _angular_core.InputSignalWithTransform; protected readonly panelTpl: _angular_core.Signal>; protected panelClass(): string; private swipeStartX; private swipeStartY; private swiping; protected onSwipeStart(event: TouchEvent): void; protected onSwipeMove(event: TouchEvent, panel: HTMLElement): void; protected onSwipeEnd(event: TouchEvent, panel: HTMLElement): void; /** Axis + sign of the closing direction for the current position. */ private closeAxis; private readonly overlay; private readonly vcr; private readonly destroyRef; private readonly focusTrapFactory; private readonly isBrowser; private overlayRef; private focusTrap; private previouslyFocused; constructor(); private openOverlay; private closeOverlay; static ɵfac: _angular_core.ɵɵFactoryDeclaration; static ɵcmp: _angular_core.ɵɵComponentDeclaration; } /** * Marks an element as the drawer's title row. Applies the `wr-drawer__title` * class so the drawer's stylesheet can lay it out alongside content and * footer slots. Auto-assigns an `id` so the drawer panel references it via * `aria-labelledby`. * * @example * ```html * *

Settings

*
*
* ``` */ declare class WrDrawerTitle { /** Generated id used by the drawer panel for `aria-labelledby`. */ readonly id: string; static ɵfac: _angular_core.ɵɵFactoryDeclaration; static ɵdir: _angular_core.ɵɵDirectiveDeclaration; } /** * Marks the scrollable body of the drawer. Applies the `wr-drawer__content` * class so the panel's flex layout can stretch it between the title and the * footer. */ declare class WrDrawerContent { static ɵfac: _angular_core.ɵɵFactoryDeclaration; static ɵdir: _angular_core.ɵɵDirectiveDeclaration; } /** * Marks the action row pinned to the bottom of the drawer. Adds the * `wr-drawer__footer` class plus an alignment modifier so action buttons * can sit at the start, center, or end of the row. * * @example * ```html *
* Cancel * Save *
* ``` */ declare class WrDrawerFooter { /** Horizontal alignment of footer content. @default 'end' */ readonly align: _angular_core.InputSignal<"center" | "start" | "end">; protected readonly classes: _angular_core.Signal; static ɵfac: _angular_core.ɵɵFactoryDeclaration; static ɵdir: _angular_core.ɵɵDirectiveDeclaration; } /** * Closes the parent drawer on click. Attach to any clickable element. * * @example * ```html * Close * ``` */ declare class WrDrawerClose { private readonly drawer; protected close(): void; static ɵfac: _angular_core.ɵɵFactoryDeclaration; static ɵdir: _angular_core.ɵɵDirectiveDeclaration; } export { WrDrawer, WrDrawerClose, WrDrawerContent, WrDrawerFooter, WrDrawerTitle }; export type { WrDrawerPosition };