2023-03-01 11:45:54 +00:00
|
|
|
/**
|
|
|
|
*
|
|
|
|
* Paginator is a generic component to display content in paged format.
|
|
|
|
*
|
2023-04-05 14:01:38 +00:00
|
|
|
* [Live Demo](https://primevue.org/paginator)
|
2023-03-01 11:45:54 +00:00
|
|
|
*
|
|
|
|
* @module paginator
|
|
|
|
*
|
|
|
|
*/
|
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-12-05 07:06:55 +00:00
|
|
|
import { DropdownPassThroughOptions } from '../dropdown';
|
|
|
|
import { InputNumberPassThroughOptions } from '../inputnumber';
|
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 PaginatorPassThroughOptionType<T = any> = PaginatorPassThroughAttributes | ((options: PaginatorPassThroughMethodOptions<T>) => PaginatorPassThroughAttributes | string) | string | null | undefined;
|
2023-05-08 09:35:25 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Custom passthrough(pt) option method.
|
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
export interface PaginatorPassThroughMethodOptions<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-05-08 09:35:25 +00:00
|
|
|
props: PaginatorProps;
|
2023-09-05 06:50:04 +00:00
|
|
|
/**
|
|
|
|
* Defines current inline state.
|
|
|
|
*/
|
2023-05-08 09:35:25 +00:00
|
|
|
state: PaginatorState;
|
2023-12-05 07:06:55 +00:00
|
|
|
/**
|
|
|
|
* Defines parent instance.
|
|
|
|
*/
|
|
|
|
parent: T;
|
2023-09-05 06:50:04 +00:00
|
|
|
/**
|
|
|
|
* Defines current options.
|
|
|
|
*/
|
2023-05-08 09:35:25 +00:00
|
|
|
context: PaginatorContext;
|
2023-09-05 08:50:46 +00:00
|
|
|
/**
|
|
|
|
* Defines passthrough(pt) options in global config.
|
|
|
|
*/
|
|
|
|
global: object | undefined;
|
2023-05-08 09:35:25 +00:00
|
|
|
}
|
|
|
|
|
2023-12-05 07:06:55 +00:00
|
|
|
/**
|
|
|
|
* Custom shared passthrough(pt) option method.
|
|
|
|
*/
|
|
|
|
export interface PaginatorSharedPassThroughMethodOptions {
|
|
|
|
/**
|
|
|
|
* Defines valid properties.
|
|
|
|
*/
|
|
|
|
props: PaginatorProps;
|
|
|
|
/**
|
|
|
|
* Defines current inline state.
|
|
|
|
*/
|
|
|
|
state: PaginatorState;
|
|
|
|
}
|
|
|
|
|
2023-05-08 09:35:25 +00:00
|
|
|
/**
|
|
|
|
* Custom passthrough(pt) options.
|
|
|
|
* @see {@link PaginatorProps.pt}
|
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
export interface PaginatorPassThroughOptions<T = any> {
|
2023-06-05 11:04:02 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the paginator container's DOM element.
|
2023-06-05 11:04:02 +00:00
|
|
|
*/
|
2024-05-06 15:32:04 +00:00
|
|
|
paginatorContainer?: PaginatorPassThroughOptionType<T> | any;
|
2023-05-08 09:35:25 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the root's DOM element.
|
2023-05-08 09:35:25 +00:00
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
root?: PaginatorPassThroughOptionType<T>;
|
2023-05-08 09:35:25 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the content start's DOM element.
|
2023-05-08 09:35:25 +00:00
|
|
|
*/
|
2024-05-02 06:27:51 +00:00
|
|
|
contentStart?: PaginatorPassThroughOptionType<T>;
|
2023-05-08 09:35:25 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the first page button's DOM element.
|
2023-05-08 09:35:25 +00:00
|
|
|
*/
|
2024-05-02 06:27:51 +00:00
|
|
|
first?: PaginatorPassThroughOptionType<T>;
|
2023-05-08 09:35:25 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the first icon's DOM element.
|
2023-05-08 09:35:25 +00:00
|
|
|
*/
|
2024-05-02 06:27:51 +00:00
|
|
|
firstIcon?: PaginatorPassThroughOptionType<T>;
|
2023-06-20 10:03:34 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the prev page button's DOM element.
|
2023-06-20 10:03:34 +00:00
|
|
|
*/
|
2024-05-02 06:27:51 +00:00
|
|
|
prev?: PaginatorPassThroughOptionType<T>;
|
2023-06-20 10:03:34 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the prev page icon's DOM element.
|
2023-06-20 10:03:34 +00:00
|
|
|
*/
|
2024-05-02 06:27:51 +00:00
|
|
|
prevIcon?: PaginatorPassThroughOptionType<T>;
|
2023-05-08 09:35:25 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the next page button's DOM element.
|
2023-05-08 09:35:25 +00:00
|
|
|
*/
|
2024-05-02 06:27:51 +00:00
|
|
|
next?: PaginatorPassThroughOptionType<T>;
|
2023-05-08 09:35:25 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the next page icon's DOM element.
|
2023-05-08 09:35:25 +00:00
|
|
|
*/
|
2024-05-02 06:27:51 +00:00
|
|
|
nextIcon?: PaginatorPassThroughOptionType<T>;
|
2023-05-08 09:35:25 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the last page button's DOM element.
|
2023-05-08 09:35:25 +00:00
|
|
|
*/
|
2024-05-02 06:27:51 +00:00
|
|
|
last?: PaginatorPassThroughOptionType<T>;
|
2023-05-08 09:35:25 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the last page icon's DOM element.
|
2023-05-08 09:35:25 +00:00
|
|
|
*/
|
2024-05-02 06:27:51 +00:00
|
|
|
lastIcon?: PaginatorPassThroughOptionType<T>;
|
2023-05-08 09:35:25 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the pages's DOM element.
|
2023-05-08 09:35:25 +00:00
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
pages?: PaginatorPassThroughOptionType<T>;
|
2023-05-08 09:35:25 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the page button's DOM element.
|
2023-05-08 09:35:25 +00:00
|
|
|
*/
|
2024-05-02 06:27:51 +00:00
|
|
|
page?: PaginatorPassThroughOptionType<T>;
|
2023-05-08 09:35:25 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the current's DOM element.
|
2023-05-08 09:35:25 +00:00
|
|
|
*/
|
2023-12-05 07:06:55 +00:00
|
|
|
current?: PaginatorPassThroughOptionType<T>;
|
2023-05-08 09:35:25 +00:00
|
|
|
/**
|
2023-08-01 14:01:12 +00:00
|
|
|
* Used to pass attributes to the Dropdown component.
|
2023-12-05 07:06:55 +00:00
|
|
|
* @see {@link DropdownPassThroughOptions}
|
2023-05-08 09:35:25 +00:00
|
|
|
*/
|
2024-05-06 15:23:01 +00:00
|
|
|
pcRowPerPageDropdown?: DropdownPassThroughOptions<PaginatorSharedPassThroughMethodOptions>;
|
2023-05-08 09:35:25 +00:00
|
|
|
/**
|
2023-08-01 14:01:12 +00:00
|
|
|
* Used to pass attributes to the Dropdown component.
|
2023-12-05 07:06:55 +00:00
|
|
|
* @see {@link DropdownPassThroughOptions}
|
2023-06-20 10:03:34 +00:00
|
|
|
*/
|
2024-05-06 15:23:01 +00:00
|
|
|
pcJumpToPageDropdown?: DropdownPassThroughOptions<PaginatorSharedPassThroughMethodOptions>;
|
2023-06-20 10:03:34 +00:00
|
|
|
/**
|
2023-08-01 14:01:12 +00:00
|
|
|
* Used to pass attributes to the Dropdown component.
|
2023-12-05 07:06:55 +00:00
|
|
|
* @see {@link InputNumberPassThroughOptions}
|
2023-06-20 10:03:34 +00:00
|
|
|
*/
|
2024-05-06 15:23:01 +00:00
|
|
|
pcJumpToPageInput?: InputNumberPassThroughOptions<PaginatorSharedPassThroughMethodOptions>;
|
2023-05-08 09:35:25 +00:00
|
|
|
/**
|
2024-05-15 09:24:26 +00:00
|
|
|
* Used to pass attributes to the content end's DOM element.
|
2023-05-08 09:35:25 +00:00
|
|
|
*/
|
2024-05-02 06:27:51 +00:00
|
|
|
contentEnd?: PaginatorPassThroughOptionType<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-05-08 09:35:25 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Custom passthrough attributes for each DOM elements
|
|
|
|
*/
|
|
|
|
export interface PaginatorPassThroughAttributes {
|
|
|
|
[key: string]: any;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Defines current inline state in Paginator component.
|
|
|
|
*/
|
|
|
|
export interface PaginatorState {
|
|
|
|
/**
|
|
|
|
* Current index of first record as a number.
|
|
|
|
*/
|
|
|
|
d_first: number;
|
|
|
|
/**
|
|
|
|
* Current number of rows to display in new page as a number.
|
|
|
|
*/
|
|
|
|
d_rows: number;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Defines current options in Paginator component.
|
|
|
|
*/
|
|
|
|
export interface PaginatorContext {
|
|
|
|
/**
|
|
|
|
* Current active state as a boolean.
|
|
|
|
* @defaultValue false
|
|
|
|
*/
|
|
|
|
active: boolean;
|
|
|
|
/**
|
|
|
|
* Current disabled state of the button as a boolean.
|
|
|
|
* @defaultValue false
|
|
|
|
*/
|
|
|
|
disabled: boolean;
|
|
|
|
}
|
|
|
|
|
2023-03-01 11:45:54 +00:00
|
|
|
/**
|
|
|
|
* Paginator page state metadata.
|
|
|
|
*/
|
2022-09-06 12:03:37 +00:00
|
|
|
export interface PageState {
|
|
|
|
/**
|
|
|
|
* Index of first record
|
|
|
|
*/
|
|
|
|
first: number;
|
|
|
|
/**
|
|
|
|
* Number of rows to display in new page
|
|
|
|
*/
|
|
|
|
rows: number;
|
|
|
|
/**
|
|
|
|
* New page number
|
|
|
|
*/
|
|
|
|
page: number;
|
|
|
|
/**
|
|
|
|
* Total number of pages
|
|
|
|
*/
|
|
|
|
pageCount?: number;
|
|
|
|
}
|
|
|
|
|
2023-03-01 11:45:54 +00:00
|
|
|
/**
|
|
|
|
* Defines valid properties in Paginator component.
|
|
|
|
*/
|
2022-09-06 12:03:37 +00:00
|
|
|
export interface PaginatorProps {
|
|
|
|
/**
|
|
|
|
* Number of total records.
|
2023-03-01 11:45:54 +00:00
|
|
|
* @defaultValue 0
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
totalRecords?: number | undefined;
|
|
|
|
/**
|
|
|
|
* Data count to display per page.
|
2023-03-01 11:45:54 +00:00
|
|
|
* @defaultValue 0
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
rows?: number | undefined;
|
|
|
|
/**
|
|
|
|
* Zero-relative number of the first row to be displayed.
|
2023-03-01 11:45:54 +00:00
|
|
|
* @defaultValue 0
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
first?: number | undefined;
|
|
|
|
/**
|
|
|
|
* Number of page links to display.
|
2023-03-01 11:45:54 +00:00
|
|
|
* @defaultValue 5
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
pageLinkSize?: number | undefined;
|
|
|
|
/**
|
|
|
|
* Array of integer values to display inside rows per page dropdown.
|
|
|
|
*/
|
|
|
|
rowsPerPageOptions?: number[] | undefined;
|
|
|
|
/**
|
2023-06-14 14:28:21 +00:00
|
|
|
* Template of the paginator, can either be a string or an object with key-value pairs to define templates per breakpoint. Available templates are the following;
|
2022-09-06 12:03:37 +00:00
|
|
|
*
|
|
|
|
* - FirstPageLink
|
|
|
|
* - PrevPageLink
|
|
|
|
* - PageLinks
|
|
|
|
* - NextPageLink
|
|
|
|
* - LastPageLink
|
|
|
|
* - RowsPerPageDropdown
|
|
|
|
* - JumpToPageDropdown
|
|
|
|
* - JumpToPageInput
|
|
|
|
* - CurrentPageReport
|
|
|
|
*/
|
2022-12-08 11:04:25 +00:00
|
|
|
template?: any | string;
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
2023-03-01 11:45:54 +00:00
|
|
|
* Template of the current page report element. It displays information about the pagination state. Available placeholders are the following;
|
2022-09-06 12:03:37 +00:00
|
|
|
*
|
|
|
|
* - {currentPage}
|
|
|
|
* - {totalPages}
|
|
|
|
* - {rows}
|
|
|
|
* - {first}
|
|
|
|
* - {last}
|
|
|
|
* - {totalRecords}
|
2023-03-01 11:45:54 +00:00
|
|
|
*
|
2023-03-08 11:02:08 +00:00
|
|
|
* @defaultValue '({currentPage} of {totalPages})'
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
currentPageReportTemplate?: string | undefined;
|
|
|
|
/**
|
|
|
|
* Whether to show the paginator even there is only one page.
|
2023-03-01 11:45:54 +00:00
|
|
|
* @defaultValue true
|
2022-09-06 12:03:37 +00:00
|
|
|
*/
|
|
|
|
alwaysShow?: 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-05-08 09:35:25 +00:00
|
|
|
/**
|
2023-08-01 14:01:12 +00:00
|
|
|
* Used to pass attributes to DOM elements inside the component.
|
2023-05-08 09:35:25 +00:00
|
|
|
* @type {PaginatorPassThroughOptions}
|
|
|
|
*/
|
2023-09-05 11:28:04 +00:00
|
|
|
pt?: PassThrough<PaginatorPassThroughOptions>;
|
2023-09-05 08:50:46 +00:00
|
|
|
/**
|
|
|
|
* Used to configure passthrough(pt) options of the component.
|
|
|
|
* @type {PassThroughOptions}
|
|
|
|
*/
|
|
|
|
ptOptions?: PassThroughOptions;
|
2022-09-06 12:03:37 +00:00
|
|
|
}
|
|
|
|
|
2023-03-01 11:45:54 +00:00
|
|
|
/**
|
|
|
|
* Defines valid slots in Paginator component.
|
|
|
|
*/
|
2022-09-06 12:03:37 +00:00
|
|
|
export interface PaginatorSlots {
|
|
|
|
/**
|
|
|
|
* Custom start template.
|
|
|
|
* @param {Object} scope - start slot's params.
|
|
|
|
*/
|
2023-03-01 11:45:54 +00:00
|
|
|
start(scope: {
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Current state
|
|
|
|
* @see PageState
|
|
|
|
*/
|
|
|
|
state: PageState;
|
2023-03-01 11:45:54 +00:00
|
|
|
}): VNode[];
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Custom end template.
|
|
|
|
* @param {Object} scope - end slot's params.
|
|
|
|
*/
|
2023-03-01 11:45:54 +00:00
|
|
|
end(scope: {
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Current state
|
|
|
|
* @see PageState
|
|
|
|
*/
|
|
|
|
state: PageState;
|
2023-03-01 11:45:54 +00:00
|
|
|
}): VNode[];
|
2023-04-07 06:48:00 +00:00
|
|
|
/**
|
2024-05-06 11:07:53 +00:00
|
|
|
* @deprecated since v4.0. Use 'firsticon' slot instead.
|
2023-04-07 06:48:00 +00:00
|
|
|
* Custom first page link icon template.
|
2024-05-06 11:07:53 +00:00
|
|
|
* @param {Object} scope - firstpagelinkicon's params.
|
2023-04-07 06:48:00 +00:00
|
|
|
*/
|
2024-05-06 11:07:53 +00:00
|
|
|
firstpagelinkicon(scope: {
|
|
|
|
/**
|
|
|
|
* Style class of the jumptopagedropdown icon.
|
|
|
|
*/
|
|
|
|
class: string;
|
|
|
|
}): VNode[];
|
|
|
|
/**
|
|
|
|
* Custom first page link icon template.
|
|
|
|
* @param {Object} scope - firsticon's params.
|
|
|
|
*/
|
|
|
|
firsticon(scope: {
|
|
|
|
/**
|
|
|
|
* Style class of the jumptopagedropdown icon.
|
|
|
|
*/
|
|
|
|
class: string;
|
|
|
|
}): VNode[];
|
2023-04-07 06:48:00 +00:00
|
|
|
/**
|
2024-05-06 11:07:53 +00:00
|
|
|
* @deprecated since v4.0. Use 'previcon' slot instead.
|
2023-04-07 06:48:00 +00:00
|
|
|
* Custom previous page link icon template.
|
2024-05-06 11:07:53 +00:00
|
|
|
* @param {Object} scope - prevpagelinkicon's params.
|
|
|
|
*/
|
|
|
|
prevpagelinkicon(scope: {
|
|
|
|
/**
|
|
|
|
* Style class of the jumptopagedropdown icon.
|
|
|
|
*/
|
|
|
|
class: string;
|
|
|
|
}): VNode[];
|
|
|
|
/**
|
|
|
|
* Custom previous page link icon template.
|
|
|
|
* @param {Object} scope - previcon's params.
|
|
|
|
*/
|
|
|
|
previcon(scope: {
|
|
|
|
/**
|
|
|
|
* Style class of the jumptopagedropdown icon.
|
|
|
|
*/
|
|
|
|
class: string;
|
|
|
|
}): VNode[];
|
|
|
|
/**
|
|
|
|
* @deprecated since v4.0. Use 'nexticon' slot instead.
|
|
|
|
* Custom finextrst page link icon template.
|
|
|
|
* @param {Object} scope - nextpagelinkicon's params.
|
2023-04-07 06:48:00 +00:00
|
|
|
*/
|
2024-05-06 11:07:53 +00:00
|
|
|
nextpagelinkicon(scope: {
|
|
|
|
/**
|
|
|
|
* Style class of the jumptopagedropdown icon.
|
|
|
|
*/
|
|
|
|
class: string;
|
|
|
|
}): VNode[];
|
2023-04-07 06:48:00 +00:00
|
|
|
/**
|
|
|
|
* Custom finextrst page link icon template.
|
2024-05-06 11:07:53 +00:00
|
|
|
* @param {Object} scope - nexticon's params.
|
|
|
|
*/
|
|
|
|
nexticon(scope: {
|
|
|
|
/**
|
|
|
|
* Style class of the jumptopagedropdown icon.
|
|
|
|
*/
|
|
|
|
class: string;
|
|
|
|
}): VNode[];
|
|
|
|
/**
|
|
|
|
* @deprecated since v4.0. Use 'lasticon' slot instead.
|
|
|
|
* Custom last page link icon template.
|
|
|
|
* @param {Object} scope - lastpagelinkicon's params.
|
2023-04-07 06:48:00 +00:00
|
|
|
*/
|
2024-05-06 11:07:53 +00:00
|
|
|
lastpagelinkicon(scope: {
|
|
|
|
/**
|
|
|
|
* Style class of the jumptopagedropdown icon.
|
|
|
|
*/
|
|
|
|
class: string;
|
|
|
|
}): VNode[];
|
2023-04-07 06:48:00 +00:00
|
|
|
/**
|
|
|
|
* Custom last page link icon template.
|
2024-05-06 11:07:53 +00:00
|
|
|
* @param {Object} scope - lasticon's params.
|
2023-04-07 06:48:00 +00:00
|
|
|
*/
|
2024-05-06 11:07:53 +00:00
|
|
|
lasticon(scope: {
|
|
|
|
/**
|
|
|
|
* Style class of the jumptopagedropdown icon.
|
|
|
|
*/
|
|
|
|
class: string;
|
|
|
|
}): VNode[];
|
2023-09-06 08:50:14 +00:00
|
|
|
/**
|
|
|
|
* Custom rowsperpagedropdownicon template.
|
|
|
|
* @param {Object} scope - rowsperpagedropdownicon's params.
|
|
|
|
*/
|
|
|
|
rowsperpagedropdownicon(scope: {
|
|
|
|
/**
|
|
|
|
* Style class of the rowsperpagedropdown icon.
|
|
|
|
*/
|
|
|
|
class: string;
|
|
|
|
}): VNode[];
|
|
|
|
/**
|
|
|
|
* Custom jumptopagedropdownicon template.
|
|
|
|
* @param {Object} scope - jumptopagedropdownicon's params.
|
|
|
|
*/
|
|
|
|
jumptopagedropdownicon(scope: {
|
|
|
|
/**
|
|
|
|
* Style class of the jumptopagedropdown icon.
|
|
|
|
*/
|
|
|
|
class: string;
|
|
|
|
}): VNode[];
|
2022-09-06 12:03:37 +00:00
|
|
|
}
|
|
|
|
|
2023-03-01 11:45:54 +00:00
|
|
|
/**
|
|
|
|
* Defines valid emits in Paginator component.
|
|
|
|
*/
|
2024-05-16 10:50:43 +00:00
|
|
|
interface PaginatorEmitsOptions {
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Emitted when the first changes.
|
|
|
|
* @param {number} value - New value.
|
|
|
|
*/
|
2023-03-01 11:45:54 +00:00
|
|
|
'update:first'(value: number): void;
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Emitted when the rows changes.
|
|
|
|
* @param {number} value - New value.
|
|
|
|
*/
|
2023-03-01 11:45:54 +00:00
|
|
|
'update:rows'(value: number): void;
|
2022-09-06 12:03:37 +00:00
|
|
|
/**
|
|
|
|
* Callback to invoke when page changes, the event object contains information about the new state.
|
|
|
|
* @param {PageState} event - New page state.
|
|
|
|
*/
|
2023-03-01 11:45:54 +00:00
|
|
|
page(event: PageState): void;
|
|
|
|
}
|
2022-09-06 12:03:37 +00:00
|
|
|
|
2024-05-16 10:50:43 +00:00
|
|
|
export declare type PaginatorEmits = EmitFn<PaginatorEmitsOptions>;
|
|
|
|
|
2023-03-01 11:45:54 +00:00
|
|
|
/**
|
|
|
|
* **PrimeVue - Paginator**
|
|
|
|
*
|
|
|
|
* _Paginator is a generic widget to display content in paged format._
|
|
|
|
*
|
|
|
|
* [Live Demo](https://www.primevue.org/paginator/)
|
|
|
|
* --- ---
|
|
|
|
* ![PrimeVue](https://primefaces.org/cdn/primevue/images/logo-100.png)
|
|
|
|
*
|
|
|
|
* @group Component
|
2024-05-16 10:50:43 +00:00
|
|
|
*
|
2023-03-01 11:45:54 +00:00
|
|
|
*/
|
2024-05-16 10:50:43 +00:00
|
|
|
declare const Paginator: DefineComponent<PaginatorProps, PaginatorSlots, PaginatorEmits>;
|
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
|
|
|
Paginator: GlobalComponentConstructor<PaginatorProps, PaginatorSlots, PaginatorEmits>;
|
2022-09-06 12:03:37 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
export default Paginator;
|