2023-03-01 14:12:19 +00:00
|
|
|
/**
|
|
|
|
*
|
|
|
|
* ProgressBar is a process status indicator.
|
|
|
|
*
|
|
|
|
* [Live Demo](https://www.primevue.org/progressbar)
|
|
|
|
*
|
|
|
|
* @module progressbar
|
|
|
|
*
|
|
|
|
*/
|
2022-09-06 12:03:37 +00:00
|
|
|
import { VNode } from 'vue';
|
2023-07-06 11:17:08 +00:00
|
|
|
import { ComponentHooks } from '../basecomponent';
|
2023-09-05 08:50:46 +00:00
|
|
|
import { PassThroughOptions } from '../passthrough';
|
2024-05-16 10:50:43 +00:00
|
|
|
import { DefineComponent, DesignToken, EmitFn, GlobalComponentConstructor, PassThrough } from '../ts-helpers';
|
2022-09-06 12:03:37 +00:00
|
|
|
|
2023-12-05 07:06:55 +00:00
|
|
|
export declare type ProgressBarPassThroughOptionType<T = any> = ProgressBarPassThroughAttributes | ((options: ProgressBarPassThroughMethodOptions<T>) => ProgressBarPassThroughAttributes | string) | string | null | undefined;
|
2023-04-21 13:34:40 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Custom passthrough(pt) option method.
|
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
export interface ProgressBarPassThroughMethodOptions<T> {
|
2023-09-05 06:50:04 +00:00
|
|
|
/**
|
|
|
|
* Defines instance.
|
|
|
|
*/
|
2023-07-06 12:01:33 +00:00
|
|
|
instance: any;
|
2023-09-05 06:50:04 +00:00
|
|
|
/**
|
|
|
|
* Defines valid properties.
|
|
|
|
*/
|
2023-04-21 13:34:40 +00:00
|
|
|
props: ProgressBarProps;
|
2023-09-05 08:50:46 +00:00
|
|
|
/**
|
|
|
|
* Defines passthrough(pt) options in global config.
|
|
|
|
*/
|
|
|
|
global: object | undefined;
|
2023-12-05 07:06:55 +00:00
|
|
|
/**
|
|
|
|
* Defines parent instance.
|
|
|
|
*/
|
|
|
|
parent: T;
|
2023-04-21 13:34:40 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Custom passthrough(pt) options.
|
|
|
|
* @see {@link ProgressBarProps.pt}
|
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
export interface ProgressBarPassThroughOptions<T = any> {
|
2023-04-21 13:34:40 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the root's DOM element.
|
2023-04-21 13:34:40 +00:00
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
root?: ProgressBarPassThroughOptionType<T>;
|
2023-04-21 13:34:40 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the value's DOM element.
|
2023-04-21 13:34:40 +00:00
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
value?: ProgressBarPassThroughOptionType<T>;
|
2023-04-21 13:34:40 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the label's DOM element.
|
2023-04-21 13:34:40 +00:00
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
label?: ProgressBarPassThroughOptionType<T>;
|
2023-07-06 11:09:01 +00:00
|
|
|
/**
|
2023-11-07 06:16:39 +00:00
|
|
|
* Used to manage all lifecycle hooks.
|
2023-07-06 11:09:01 +00:00
|
|
|
* @see {@link BaseComponent.ComponentHooks}
|
|
|
|
*/
|
|
|
|
hooks?: ComponentHooks;
|
2023-04-21 13:34:40 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Custom passthrough attributes for each DOM elements
|
|
|
|
*/
|
|
|
|
export interface ProgressBarPassThroughAttributes {
|
|
|
|
[key: string]: any;
|
|
|
|
}
|
|
|
|
|
2023-03-01 14:12:19 +00:00
|
|
|
/**
|
|
|
|
* Defines valid properties in ProgressBar component.
|
|
|
|
*/
|
2022-09-06 12:03:37 +00:00
|
|
|
export interface ProgressBarProps {
|
|
|
|
/**
|
|
|
|
* Current value of the progress.
|
|
|
|
*/
|
|
|
|
value?: number | undefined;
|
|
|
|
/**
|
|
|
|
* Defines the mode of the progress
|
2023-03-08 10:51:52 +00:00
|
|
|
* @defaultValue determinate
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
2023-03-01 14:12:19 +00:00
|
|
|
mode?: 'determinate' | 'indeterminate' | undefined;
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Whether to display the progress bar value.
|
2023-03-01 14:12:19 +00:00
|
|
|
* @defaultValue true
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
showValue?: boolean | undefined;
|
2024-04-02 08:24:31 +00:00
|
|
|
/**
|
|
|
|
* It generates scoped CSS variables using design tokens for the component.
|
|
|
|
*/
|
|
|
|
dt?: DesignToken<any>;
|
2023-04-21 13:34:40 +00:00
|
|
|
/**
|
2023-08-01 14:01:12 +00:00
|
|
|
* Used to pass attributes to DOM elements inside the component.
|
2023-04-21 13:34:40 +00:00
|
|
|
* @type {ProgressBarPassThroughOptions}
|
|
|
|
*/
|
2023-09-05 11:28:04 +00:00
|
|
|
pt?: PassThrough<ProgressBarPassThroughOptions>;
|
2023-09-05 08:50:46 +00:00
|
|
|
/**
|
|
|
|
* Used to configure passthrough(pt) options of the component.
|
|
|
|
* @type {PassThroughOptions}
|
|
|
|
*/
|
|
|
|
ptOptions?: PassThroughOptions;
|
2023-05-25 16:32:25 +00:00
|
|
|
/**
|
|
|
|
* When enabled, it removes component related styles in the core.
|
|
|
|
* @defaultValue false
|
|
|
|
*/
|
|
|
|
unstyled?: boolean;
|
2022-09-06 12:03:37 +00:00
|
|
|
}
|
|
|
|
|
2023-03-01 14:12:19 +00:00
|
|
|
/**
|
|
|
|
* Defines valid slots in ProgressBar component.
|
|
|
|
*/
|
2022-09-06 12:03:37 +00:00
|
|
|
export interface ProgressBarSlots {
|
|
|
|
/**
|
|
|
|
* Custom content slot.
|
|
|
|
*/
|
2023-03-01 14:12:19 +00:00
|
|
|
default(): VNode[];
|
2022-09-06 12:03:37 +00:00
|
|
|
}
|
|
|
|
|
2023-03-01 14:12:19 +00:00
|
|
|
/**
|
|
|
|
* Defines valid emits in ProgressBar component.
|
|
|
|
*/
|
2024-05-16 14:05:43 +00:00
|
|
|
export interface ProgressBarEmitsOptions {}
|
2024-05-16 10:50:43 +00:00
|
|
|
|
|
|
|
export declare type ProgressBarEmits = EmitFn<ProgressBarEmitsOptions>;
|
2022-09-06 12:03:37 +00:00
|
|
|
|
2023-03-01 14:12:19 +00:00
|
|
|
/**
|
|
|
|
* **PrimeVue - ProgressBar**
|
|
|
|
*
|
|
|
|
* ProgressBar is a process status indicator._
|
|
|
|
*
|
|
|
|
* [Live Demo](https://www.primevue.org/progressbar/)
|
|
|
|
* --- ---
|
|
|
|
* ![PrimeVue](https://primefaces.org/cdn/primevue/images/logo-100.png)
|
|
|
|
*
|
|
|
|
* @group Component
|
2024-05-16 10:50:43 +00:00
|
|
|
*
|
2023-03-01 14:12:19 +00:00
|
|
|
*/
|
2024-05-16 10:50:43 +00:00
|
|
|
declare const ProgressBar: DefineComponent<ProgressBarProps, ProgressBarSlots, ProgressBarEmits>;
|
2022-09-06 12:03:37 +00:00
|
|
|
|
2024-03-14 22:58:11 +00:00
|
|
|
declare module 'vue' {
|
|
|
|
export interface GlobalComponents {
|
2024-05-16 10:50:43 +00:00
|
|
|
ProgressBar: GlobalComponentConstructor<ProgressBarProps, ProgressBarSlots, ProgressBarEmits>;
|
2022-09-06 12:03:37 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
export default ProgressBar;
|