mx-ui-components
Version:
mobius ui library
76 lines (75 loc) • 2 kB
TypeScript
import BaseComponent from "../Counter/BaseComponent";
export default class ProgressBar extends BaseComponent {
private _progress;
private progressElement;
private progressBarElement;
private progressLabelElement;
private pollingInterval;
private _progressObj;
private props;
private _progressStyles;
private _progressBarStyles;
private defInsideLabelStyle;
private defColorStyle;
private defOutsideLabelStyle;
private defOutsideLeftLabelStyle;
private defOutsideRightLabelStyle;
constructor();
set progress(value: any);
get progress(): any;
static get observedAttributes(): string[];
initObj(): void;
connectedCallback(): void;
attributeChangedCallback(name: string, oldValue: string | null, newValue: string): void;
createProgressElement(): void;
createProgressBarElement(): void;
createLabels(): void;
getSize(size: Size): "4" | "1.5" | "2.5" | "6";
handleProgress(): void;
fetchProgressData(): Promise<number>;
updateProgressStyles(): void;
disconnectedCallback(): void;
}
export { ProgressBar };
export declare enum Direction {
HORIZONTAL = "horizontal",
VERTICAL = "vertical"
}
export declare enum Size {
SMALL = "small",
DEFAULT = "default",
LARGE = " large",
EXTRAlARGE = "extraLarge"
}
export declare enum LabelAlignment {
LEFT = "left",
CENTER = "center",
RIGHT = "right"
}
export declare enum EVariant {
LINEAR = "linear",
CIRCULAR = "circular"
}
export declare enum LabelPositions {
INSIDE = "inside",
OUTSIDE = "outside"
}
export interface Variant {
type: EVariant;
direction?: Direction;
}
export interface IProgressBar {
variant: Variant;
size: Size;
color: string;
labels?: ILabel[];
progressStyles?: string;
defaultPoll?: boolean;
}
export interface ILabel {
type: LabelPositions;
isProgress?: boolean;
value?: string;
alignment: LabelAlignment;
styles?: string;
}