import { Platform } from '@angular/cdk/platform'; import { ElementRef, InjectionToken } from '@angular/core'; /** Possible mode for a progress spinner. */ export declare type ProgressSpinnerMode = 'determinate' | 'indeterminate'; /** @internal */ export declare class ProgressSpinnerBase { _elementRef: ElementRef; constructor(_elementRef: ElementRef); } /** Default `uex-spinner` options that can be overridden. */ /** @internal */ export interface ProgressSpinnerDefaultOptions { /** Diameter of the spinner. */ diameter?: number; /** Width of the spinner's stroke. */ strokeWidth?: number; /** * Whether the animations should be force to be enabled, ignoring if the current environment is * using NoopAnimationsModule. */ _forceAnimations?: boolean; } /** Injection token to be used to override the default options for `uex-spinner`. */ /** @internal */ export declare const UEX_PROGRESS_SPINNER_DEFAULT_OPTIONS: InjectionToken; /** @internal */ export declare function UEX_PROGRESS_SPINNER_DEFAULT_OPTIONS_FACTORY(): ProgressSpinnerDefaultOptions; /** * `` component. */ export declare class Spinner { _elementRef: ElementRef; private _document; private animationMode?; private defaults?; /** The diameter of the progress spinner (will set width and height of svg). */ diameter: number; /** Stroke width of the progress spinner. */ strokeWidth: number; /** Mode of the progress circle */ mode: ProgressSpinnerMode; /** Value of the progress circle. */ value: number; /** Color of the progress circle. */ color: string; constructor(_elementRef: ElementRef, platform: Platform, _document: any, animationMode?: string, defaults?: ProgressSpinnerDefaultOptions); /** The radius of the spinner, adjusted for stroke width. */ readonly _circleRadius: number; /** The view box of the spinner's svg element. */ readonly _viewBox: string; /** The stroke circumference of the svg circle. */ readonly _strokeCircumference: number; /** The dash offset of the svg circle. */ readonly _strokeDashOffset: number; /** Stroke width of the circle in percent. */ readonly _circleStrokeWidth: number; /** Tracks diameters of existing instances to de-dupe generated styles (default d = 100) */ private static diameters; /** * Used for storing all of the generated keyframe animations. * @dynamic */ private static styleTag; private _value; private _color; private _oldColor; private _mode; private _oldMode; private _strokeWidth; private _fallbackAnimation; /** Whether the _uex-animation-noopable class should be applied, disabling animations. */ _noopAnimations: boolean; private _diameter; /** Dynamically generates a style tag containing the correct animation for this diameter. */ private _attachStyleNode; /** Generates animation styles adjusted for the spinner's diameter. */ private _getAnimationText; /** Set the color class of spinner */ private _updateColor; }