UNPKG

@synergy-design-system/angular

Version:
105 lines (102 loc) 5.83 kB
import * as i0 from '@angular/core'; import { ElementRef, NgZone, EventEmitter } from '@angular/core'; import SynPagination from '@synergy-design-system/components/components/pagination/pagination.component.js'; import { SynPaginationPageChangedEvent, SynPaginationPageSizeChangedEvent } from '@synergy-design-system/components'; export { SynPaginationPageChangedEvent, SynPaginationPageSizeChangedEvent } from '@synergy-design-system/components'; /** * @summary <syn-pagination /> provides page navigation, direct page input, and page-size selection for large data sets. * * @documentation https://synergy-design-system.github.io/?path=/docs/components-syn-pagination--docs * @status stable * @since 3.12.0 * * @event syn-pagination-page-changed - Emitted when the current page changes * @event syn-pagination-page-size-changed - Emitted when the page size changes * * @csspart base - The component's base wrapper. * @csspart divider - The divider element displayed at the top of the pagination component. * @csspart page-size-select-wrapper - The wrapper element containing the page size select and page item summary. * @csspart page-size-select - The page size select element. * @csspart page-item-summary - The text element displaying the current page item range and total items. * @csspart page-input-section - The section containing the page number input and total pages display. * @csspart page-input - The page number input element. * @csspart navigation - The pagination navigation element. * @csspart navigation-action - The individual navigation action buttons (first, previous, next, last). * * @accessibility * The entire component is wrapped in a semantic `<nav>` landmark with an `aria-label` for screen reader accessibility. * Use the `aria-label` attribute to provide a unique, descriptive label when multiple pagination controls exist on the page. * Example: `<syn-pagination aria-label="Search results pagination"></syn-pagination>` */ declare class SynPaginationComponent { nativeElement: SynPagination; private _ngZone; constructor(e: ElementRef, ngZone: NgZone); /** * When true, a divider is displayed at the top of the pagination component. */ set divider(v: '' | SynPagination['divider']); get divider(): SynPagination['divider']; /** * When true, the pagination controls are disabled and non-interactive. */ set disabled(v: '' | SynPagination['disabled']); get disabled(): SynPagination['disabled']; /** * The size of the pagination controls. */ set size(v: SynPagination['size']); get size(): SynPagination['size']; /** * The current page number. * The default value is 1. The component will emit a `syn-pagination-page-changed` event whenever the page changes, allowing you to respond to page changes in your application. */ set currentPage(v: SynPagination['currentPage']); get currentPage(): SynPagination['currentPage']; /** * The number of items to display per page. * The default value is 25. The component will emit a `syn-pagination-page-size-changed` event whenever the page size changes, allowing you to respond to page size changes in your application. */ set pageSize(v: SynPagination['pageSize']); get pageSize(): SynPagination['pageSize']; /** * An array of numbers representing the available options for the number of items to display per page. * The default value is [10, 25, 50, 100]. The component will use this array to populate the rows-per-page selector, allowing users to choose from the specified options. */ set pageSizeOptions(v: SynPagination['pageSizeOptions']); get pageSizeOptions(): SynPagination['pageSizeOptions']; /** * Total amount of items. * The component will use this value to calculate the total number of pages based on the selected rows per page. */ set totalItems(v: SynPagination['totalItems']); get totalItems(): SynPagination['totalItems']; /** * The pagination variant to use. * The "full" variant includes comprehensive controls for navigating between pages and adjusting the number of displayed rows, while the "compact" variant offers a streamlined interface with essential navigation controls. The default value is "full". */ set variant(v: SynPagination['variant']); get variant(): SynPagination['variant']; /** * An accessible label for the navigation landmark. * Customize for multiple paginations on a page. */ set ariaLabel(v: SynPagination['ariaLabel']); get ariaLabel(): SynPagination['ariaLabel']; /** * Emitted when the current page changes */ synPaginationPageChangedEvent: EventEmitter<SynPaginationPageChangedEvent>; /** * Emitted when the page size changes */ synPaginationPageSizeChangedEvent: EventEmitter<SynPaginationPageSizeChangedEvent>; static ɵfac: i0.ɵɵFactoryDeclaration<SynPaginationComponent, never>; static ɵcmp: i0.ɵɵComponentDeclaration<SynPaginationComponent, "syn-pagination", never, { "divider": { "alias": "divider"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "size": { "alias": "size"; "required": false; }; "currentPage": { "alias": "currentPage"; "required": false; }; "pageSize": { "alias": "pageSize"; "required": false; }; "pageSizeOptions": { "alias": "pageSizeOptions"; "required": false; }; "totalItems": { "alias": "totalItems"; "required": false; }; "variant": { "alias": "variant"; "required": false; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; }; }, { "synPaginationPageChangedEvent": "synPaginationPageChangedEvent"; "synPaginationPageSizeChangedEvent": "synPaginationPageSizeChangedEvent"; }, never, ["*"], true, never>; } export { SynPaginationComponent };