import * as _angular_core from '@angular/core'; import { InjectionToken, Signal } from '@angular/core'; import * as forty_cdk_meter from 'forty-cdk/meter'; /** * Quality bucket reflected on `data-quality`. Mirrors the HTML5 `` * algorithm: * - `optimum`: the value sits in the optimal region. * - `sub-optimum`: less than ideal but still acceptable. * - `even-less-good`: opposite side of optimum, the worst region. */ type ForMeterQuality = 'optimum' | 'sub-optimum' | 'even-less-good'; /** Read surface `[forMeter]` publishes through {@link FOR_METER_CONTEXT}. */ interface ForMeterContext { /** Clamped to `[min, max]`. Use this for any visual / ARIA reflection. */ readonly clampedValue: Signal; /** * Sanitized lower bound (`min <= max`). Use this for any ARIA / visual * reflection instead of the raw `min` input. */ readonly sanitizedMin: Signal; /** * Sanitized upper bound (`min <= max`). Use this for any ARIA / visual * reflection instead of the raw `max` input. */ readonly sanitizedMax: Signal; /** `0..100`. */ readonly percentage: Signal; /** * {@link percentage} rounded to two decimals for the `data-percentage` * reflection. Owned by the root so the indicator mirrors it instead of * re-implementing the rounding. */ readonly percentageAttr: Signal; readonly quality: Signal; } declare const FOR_METER_CONTEXT: InjectionToken; /** * Headless implementation of the * [WAI-ARIA Meter pattern](https://www.w3.org/WAI/ARIA/apg/patterns/meter/), * mirroring the HTML5 `` element semantics. * * A meter represents a known scalar measurement within a range — disk usage, * battery level, score, queue depth — **not** a task in progress. Use * `[forProgress]` for the latter. * * The optional `low`, `high`, and `optimum` inputs let you shape the "quality * bucket" reflected on `data-quality` (`optimum` / `sub-optimum` / * `even-less-good`) for CSS styling. * * @example * ```html *
*
*
* ``` */ declare class ForMeter implements ForMeterContext { #private; /** * Current measurement. One-way `[value]` input: a meter is a display-only * readout with no interactive value, so it exposes no two-way binding. * Clamped to `[min, max]` for everything reflected on the host; the input * retains the raw value so a consumer reading it back is not surprised. */ readonly value: _angular_core.InputSignal; /** Lower bound. Defaults to `0`. */ readonly min: _angular_core.InputSignal; /** Upper bound. Defaults to `100`. */ readonly max: _angular_core.InputSignal; /** * Optional lower boundary of the "OK" range. Values below `low` are * treated as below the comfortable region. `null` means no lower band. */ readonly low: _angular_core.InputSignal; /** * Optional upper boundary of the "OK" range. Values above `high` are * treated as above the comfortable region. `null` means no upper band. */ readonly high: _angular_core.InputSignal; /** * Optional point at which the value is considered ideal. Falls back to * the midpoint of `[min, max]`. Determines which region is `optimum`, * which is `sub-optimum`, and which is `even-less-good` (see HTML5 spec). */ readonly optimum: _angular_core.InputSignal; /** * Optional override for `aria-valuetext`. Receives the clamped value, * `min`, and `max`. */ readonly getValueLabel: _angular_core.InputSignal<((value: number, min: number, max: number) => string) | null>; /** * Accessible name for the meter. Defaults to `null`, emitting no * `aria-label`; prefer a visible label referenced via `aria-labelledby` when * one exists. */ readonly ariaLabel: _angular_core.InputSignal; protected readonly resolvedAriaLabel: _angular_core.Signal; /** Sanitized lower bound (`min <= max`), reflected to ARIA / data-\*. */ readonly sanitizedMin: _angular_core.Signal; /** Sanitized upper bound (`min <= max`), reflected to ARIA / data-\*. */ readonly sanitizedMax: _angular_core.Signal; readonly clampedValue: _angular_core.Signal; readonly percentage: _angular_core.Signal; readonly quality: _angular_core.Signal; readonly ariaValueText: _angular_core.Signal; readonly percentageAttr: _angular_core.Signal; static ɵfac: _angular_core.ɵɵFactoryDeclaration; static ɵdir: _angular_core.ɵɵDirectiveDeclaration; } /** * Visual fill paired with `[forMeter]`. Reflects `data-quality`, * `data-percentage`, and the CSS custom property `--for-meter-percentage` * so the consumer can drive width / transform from CSS. */ declare class ForMeterIndicator { protected readonly context: forty_cdk_meter.ForMeterContext; protected percentageStyle(): string; static ɵfac: _angular_core.ɵɵFactoryDeclaration; static ɵdir: _angular_core.ɵɵDirectiveDeclaration; } export { FOR_METER_CONTEXT, ForMeter, ForMeterIndicator }; export type { ForMeterContext, ForMeterQuality };