import { KbqProgressSpinnerModule } from '@koobiq/components/progress-spinner';

KbqProgressSpinner

componentСкопировать ссылку на KbqProgressSpinner

Component that reports the progress of an ongoing operation.

@Component({ selector: 'kbq-progress-spinner' })
class KbqProgressSpinner extends KbqColorDirective {
readonly id = input<string>(
inject(_IdGenerator).getId('kbq-progress-spinner-')
);
readonly value = input<number>(0);
readonly mode = input<ProgressSpinnerMode>('determinate');
readonly size = input<ProgressSpinnerSize>('compact');
readonly color = input<T | null | undefined>();
get colorClassName(): string;
setDefaultColor(color: T): void;
}
idinputСкопировать ссылку на idstring

Unique id of the spinner.

valueinputСкопировать ссылку на valuenumber

Progress of the operation, in percent. Clamped to [0, 100] and only rendered in determinate mode.

Anything that is not a number reads as 0: the value feeds a stroke-dashoffset percentage, and a bare numberAttribute would turn a null binding into NaN%, which is not a length at all. The transform is typed rather than taking unknown, so [value]="progress$ | async" and value="40" keep type-checking while an object or an array stays a template type error.

modeinputСкопировать ссылку на modeProgressSpinnerMode

Whether the spinner reports value or spins indefinitely.

colorinputСкопировать ссылку на colorT | null | undefined

Color of the component. A value set in code holds until the input changes, and the default color is used while both are unset or falsy.

colorClassNameСкопировать ссылку на colorClassNamestring

current class name of color

setDefaultColor()Скопировать ссылку на setDefaultColor()void

this color will be used as a default value. For example [color]="'' | false | undefined | null".

KbqProgressSpinnerCaption

directiveСкопировать ссылку на KbqProgressSpinnerCaption

Directive that marks the caption of a progress spinner.

@Directive({ selector: '[kbq-progress-spinner-caption]' })
class KbqProgressSpinnerCaption {}

KbqProgressSpinnerText

directiveСкопировать ссылку на KbqProgressSpinnerText

Directive that marks the text of a progress spinner.

@Directive({ selector: '[kbq-progress-spinner-text]' })
class KbqProgressSpinnerText {}

ProgressSpinnerMode

typeСкопировать ссылку на ProgressSpinnerMode

Whether the spinner reports a known progress value or spins indefinitely.

type ProgressSpinnerMode = 'determinate' | 'indeterminate';

ProgressSpinnerSize

typeСкопировать ссылку на ProgressSpinnerSize

Sizes supported by the progress spinner.

type ProgressSpinnerSize = Exclude<KbqDefaultSizes, 'normal'>;
Предложения по улучшению
Если вы нашли ошибку или хотите доработать статью, создайте запрос на GitHub.