UNPKG

@hashicorp/design-system-components

Version:
56 lines (55 loc) 1.64 kB
/** * Copyright (c) HashiCorp, Inc. * SPDX-License-Identifier: MPL-2.0 */ import Component from '@glimmer/component'; import type Owner from '@ember/owner'; import type { NavigationNarratorSignature } from 'ember-a11y-refocus/components/navigation-narrator'; export interface HdsAppHeaderSignature { Args: { breakpoint?: string; hasA11yRefocus?: boolean; a11yRefocusSkipTo?: string; a11yRefocusSkipText?: string; a11yRefocusNavigationText?: string; a11yRefocusRouteChangeValidator?: NavigationNarratorSignature['Args']['routeChangeValidator']; a11yRefocusExcludeAllQueryParams?: boolean; }; Blocks: { logo?: [ { close: () => void; } ]; globalActions?: [ { close: () => void; } ]; utilityActions?: [ { close: () => void; } ]; }; Element: HTMLDivElement; } export default class HdsAppHeader extends Component<HdsAppHeaderSignature> { private _isOpen; private _isDesktop; private _hasOverflowContent; private _desktopMQ; hasA11yRefocus: boolean; a11yRefocusSkipTo: string; private _menuContentId; private _desktopMQVal; constructor(owner: Owner, args: Record<string, never>); addEventListeners(): void; removeEventListeners(): void; get shouldTrapFocus(): boolean; get classNames(): string; escapePress(event: KeyboardEvent): void; onClickToggle(): void; close(): void; updateDesktopVariable(event: MediaQueryListEvent): void; }