import type{PropertyValues}from'lit';import{type TemplateResult}from'lit';import{LyraElement}from'../../../internal/lyra-element.js';import{type LyraSize}from'../../../internal/variants.js';import type{LyraProgressVariant}from'../../overlays/progress/progress-bar.class.js'; /** The rendered geometry of a gauge. */ export type GaugeShape='radial'|'ring'|'linear'; /** * One value-to-variant mapping entry for {@linkcode LyraGauge.thresholds}. The LAST entry (after * sorting by `at`) whose `at` is `<=` the current `value` wins, which is deliberately the one rule * that serves both a higher-is-worse domain (CPU load: `[{at:0,variant:'success'}, * {at:70,variant:'warning'},{at:90,variant:'danger'}]`) and a higher-is-better one (battery charge: * `[{at:0,variant:'danger'},{at:20,variant:'warning'},{at:50,variant:'success'}]`) -- only the * authored `at`/`variant` pairs differ between the two, never the resolution rule itself. */ export interface LyraGaugeThreshold{readonly at:number;readonly variant:LyraProgressVariant;} /** * `` — a radial, full-circle ring, or linear meter. First-party invention; no * generic gauge widget exists in Web Awesome. * The host defaults to `role="meter"` (or `img` when no finite range can be announced), while an * author-supplied role remains authoritative. Visually abbreviated SVG captions retain their full * caller-owned text in a nested `` tooltip. * `variant` picks the fill's semantic palette directly; `thresholds` instead derives it from the * current `value`, falling back to `variant` while empty or while `value` matches no entry. * * @customElement lr-gauge * @csspart base - The root `<svg>`. * @csspart track - The background track arc/line. * @csspart fill - The animated fill arc/line. * @csspart value - The value text. Rendered only while `showValue` is true. * @csspart label - The label text. Rendered only while `label` is non-empty. * @cssprop [--lr-gauge-fill=var(--lr-color-brand)] - Fill stroke for radial, ring, and linear * gauges. The token default follows the effective variant -- `variant`, or the matching * `thresholds` entry -- rather than always `brand`. * @status stable * @since 4.0.0 */ export declare class LyraGauge extends LyraElement{static styles:import("lit").CSSResultGroup[];static get observedAttributes():string[];value:number;min:number;max:number; /** Visual geometry. Named `shape` because this Lyra-original component is not a native input. */ shape:GaugeShape;private _size?; /** Density tier on the library's one size ladder, in either spelling — `2xs`/`xs`/`s`/`m`/`l`/ * `xl`, or Web Awesome's and Shoelace's `small`/`medium`/`large`. Opt-in: with no size the * gauge keeps the ambient text size it inherits and the em-based frame it has always drawn, so * existing markup renders unchanged. A tier scales the frame, stroke geometry and both captions * together, because the whole box is expressed in em and the tier sets the host font size. * Unsupported values normalize to the omitted state and remove the attribute. */ get size():LyraSize|undefined;set size(next:LyraSize|undefined); /** Optional visible label. Attribute removal omits the SVG label and restores the localized * gauge name unless an author supplied aria-label; the property retains null readback. */ label:string; /** Displayed/announced value text, e.g. `'72°F'` for a raw `value` of `72`. * An empty string is treated the same as unset and falls back to the numeric `value`. */ valueText?:string; /** Whether the decorative `part="value"` caption renders at all. The accessible value -- * `aria-valuenow`/`aria-valuetext` and the host's computed accessible name -- comes from * `value`/`valueText` directly and stays correct either way, since the caption itself is * always `aria-hidden`. Mirrors `<lr-progress-bar>`'s and `<lr-progress-ring>`'s own * `showValue` name and meaning; the default differs (`true` here, `false` there) because * unlike a progress indicator, a gauge's whole purpose is showing the reading it announces, so * hiding the caption is the opt-out rather than the opt-in -- leaving it unset renders exactly * as before this property existed. Uses the shared parse-only `trueDefaultBooleanConverter` * rather than Lit's default presence-based `type: Boolean` handling, so a plain-HTML consumer * with no way to write a `.showValue` property binding can still turn this off with * `show-value="false"`. Deliberately not reflected: nothing styles or queries * `[show-value]`. */ showValue:boolean; /** Semantic palette for the fill, read from the library's shared semantic-tone vocabulary * (the same one `<lr-progress-bar>` uses). This is the fallback color: whenever `thresholds` * is non-empty and `value` matches at least one entry, the matching entry's variant wins * instead. */ variant:LyraProgressVariant; /** Value-to-variant color mapping. The LAST entry (after sorting by `at`, regardless of * authored order) whose `at` is `<=` the current `value` wins; an entry whose `at` is not a * finite number never matches. Leaving this at its default empty array, or leaving `value` * below every entry's `at`, renders with `variant` instead. See {@linkcode LyraGaugeThreshold} * for the higher-is-worse/higher-is-better example pair this single rule supports. */ thresholds:readonly LyraGaugeThreshold[];private appliedAriaLabel;private explicitAriaLabel;private authorRole;private syncingGeneratedRole;attributeChangedCallback(name:string,oldValue:string|null,value:string|null):void;private get domain();private get ratio();private get effectiveVariant(); /** The text rendered/announced for the current value: `valueText` when set, * else the numeric `value`, blanked (like the ARIA attributes and fill) when * `value` is non-finite (NaN/undefined/Infinity/-Infinity). */ private get displayText();private truncatedTooltip;protected willUpdate(changed:PropertyValues):void;private renderRadial;private renderLinear;private renderRing;render():TemplateResult;}declare global{interface HTMLElementTagNameMap{'lr-gauge':LyraGauge;}}