@hexure/ui 1.13.48 → 1.13.49

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5,6 +5,7 @@ interface ButtonProps {
5
5
  onClick: (e?: any) => void;
6
6
  format?: 'primary' | 'secondary';
7
7
  icon?: string;
8
+ type?: 'button' | 'submit' | 'reset' | null;
8
9
  }
9
10
  export interface BulkActionBarProps extends AccessibleProps {
10
11
  actions?: ButtonProps[];
@@ -6,6 +6,7 @@ export interface PaginationProps extends AccessibleProps {
6
6
  pageCount: number;
7
7
  /** Optional ID for automation purposes */
8
8
  dataItemid?: string;
9
+ type?: 'button' | 'submit' | 'reset' | null;
9
10
  }
10
11
  declare const Pagination: FC<PaginationProps>;
11
12
  export default Pagination;
package/dist/esm/index.js CHANGED
@@ -2356,7 +2356,7 @@ const Wrapper$3 = styled.nav `
2356
2356
  column-gap: 10px;
2357
2357
  `;
2358
2358
  const Pagination = (_a) => {
2359
- var { currentPage = 1, onClick, pageCount = 0, dataItemid } = _a, accessibleProps = __rest(_a, ["currentPage", "onClick", "pageCount", "dataItemid"]);
2359
+ var { currentPage = 1, onClick, pageCount = 0, dataItemid, type = null } = _a, accessibleProps = __rest(_a, ["currentPage", "onClick", "pageCount", "dataItemid", "type"]);
2360
2360
  const is_first_page = currentPage === 1;
2361
2361
  const is_last_page = currentPage === pageCount;
2362
2362
  const handlePrevClick = () => {
@@ -2377,12 +2377,12 @@ const Pagination = (_a) => {
2377
2377
  };
2378
2378
  const baseId = dataItemid || 'pagination';
2379
2379
  return (React.createElement(Wrapper$3, Object.assign({}, accessibleProps, { "data-itemid": `${baseId}-wrapper` }),
2380
- React.createElement(Button, { "data-itemid": `${baseId}-prev-button`, disabled: is_first_page, icon: mdiChevronLeft, onClick: handlePrevClick, small: true }),
2380
+ React.createElement(Button, { "data-itemid": `${baseId}-prev-button`, disabled: is_first_page, icon: mdiChevronLeft, onClick: handlePrevClick, small: true, type: type }),
2381
2381
  React.createElement(Select, { "data-itemid": `${baseId}-select`, onChange: handlePageChange, options: Array.from(Array(pageCount).keys(), p => p + 1).map(p => ({
2382
2382
  label: `Page ${p}`,
2383
2383
  value: `${p}`,
2384
2384
  })), value: `${currentPage}` }),
2385
- React.createElement(Button, { "data-itemid": `${baseId}-next-button`, disabled: is_last_page, icon: mdiChevronRight, onClick: handleNextClick, small: true })));
2385
+ React.createElement(Button, { "data-itemid": `${baseId}-next-button`, disabled: is_last_page, icon: mdiChevronRight, onClick: handleNextClick, small: true, type: type })));
2386
2386
  };
2387
2387
 
2388
2388
  const Wrapper$2 = styled.label `