import * as i0 from '@angular/core'; import { InjectionToken, Provider, WritableSignal } from '@angular/core'; type Brand = "qualcomm" | "snapdragon" | "dragonwing"; type Theme = "light" | "dark"; interface QdsThemeProviderOptions { /** * The forced QDS Brand for the application. This setting, if supplied, overrides * the value from the cookie. */ brandOverride?: Brand; /** * The default QDS brand for the application, applied on first visit if no cookie * is set. * * @default 'qualcomm' */ defaultBrand?: Brand; /** * The default QDS theme for the application, applied on first visit if no cookie * is set. * * @default 'light' */ defaultTheme?: Theme; /** * A root node to apply the theme/brand attributes to. Used for CSS scoping. * * @default `document.documentElement` */ rootElement?: HTMLElement | (() => HTMLElement); /** * If `true`, skip writing the theme and brand attributes to data attributes on * the {@link rootElement}. This will not prevent the value of the brand/theme * from being updated in storage. Useful if you want to scope a subsection of your * application to a specific brand/theme without changing the global attributes. * * @default false */ skipAttributes?: boolean | { brand?: boolean | undefined; theme?: boolean | undefined; }; /** * If `true`, skip writing the color scheme style to the {@link rootElement}. */ skipColorSchemeStyle?: boolean; /** * The forced QDS theme for the application. This setting, if supplied, overrides * the value from the cookie. */ themeOverride?: Theme; } declare const THEME_COOKIE_NAME = "app-qds-theme"; declare const BRAND_COOKIE_NAME = "app-qds-brand"; /** * Concrete values are provided at bootstrap, but we attach a * factory so injection works even if the caller forgets to register them, * falling back to the light theme / first brand. */ declare const THEME_COOKIE: InjectionToken; declare const BRAND_COOKIE: InjectionToken; declare const QDS_THEME_OPTIONS: InjectionToken>; declare function provideQdsTheme(opts?: QdsThemeProviderOptions): Provider[]; declare function readCookie(name: string): string | undefined; /** * A service that provides access to the current theme and brand, and ensures that * the application's root element is in sync with the selected brand/theme. */ declare class QdsThemeService { private readonly document; private readonly response; private readonly renderer; protected readonly isCsr: () => boolean; readonly theme: WritableSignal; readonly brand: WritableSignal; private readonly themeOpts; get themeOptions(): Required>; get rootElement(): HTMLElement; get skipBrandAttribute(): boolean; get skipThemeAttribute(): boolean; constructor(); toggleTheme(): void; private syncAttributes; private syncCookie; private updateAttribute; private updateColorScheme; private appendSetCookieHeader; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } export { BRAND_COOKIE, BRAND_COOKIE_NAME, QDS_THEME_OPTIONS, QdsThemeService, THEME_COOKIE, THEME_COOKIE_NAME, provideQdsTheme, readCookie }; export type { Brand, QdsThemeProviderOptions, Theme }; //# sourceMappingURL=qualcomm-ui-angular-theme.d.ts.map