@digital-ai/dot-components 2.11.3 → 2.12.0

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.
package/CHANGE_LOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Changelog
2
2
 
3
+ ## [2.12.0](https://www.npmjs.com/package/@digital-ai/dot-components) (07/27/2023)
4
+
5
+ [Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/2.11.3...2.12.0)
6
+
7
+ **Features:**
8
+
9
+ - S-94595: `DotTablePagination` improvements [\#1570](https://github.com/digital-ai/dot-components/pull/1570) ([dmiletic85](https://github.com/dmiletic85))
10
+
3
11
  ## [2.11.3](https://www.npmjs.com/package/@digital-ai/dot-components) (07/24/2023)
4
12
 
5
13
  [Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/2.11.2...2.11.3)
@@ -370,6 +378,10 @@
370
378
 
371
379
  [Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/2.3.0...2.3.1)
372
380
 
381
+ **Features:**
382
+
383
+ - S-90007 Expose ListboxComponent [\#1358](https://github.com/digital-ai/dot-components/pull/1358) ([angel-git](https://github.com/angel-git))
384
+
373
385
  **Fixed bugs:**
374
386
 
375
387
  - S-89896: Remove 'identity.' from host when constructing platform url [\#1379](https://github.com/digital-ai/dot-components/pull/1379) ([jmcnally](https://github.com/jmcnally))
@@ -387,15 +399,12 @@
387
399
 
388
400
  - CI: bumps version to 2.2.1 \[skip ci\] \(\#1371\) [\#1372](https://github.com/digital-ai/dot-components/pull/1372) ([CWSites](https://github.com/CWSites))
389
401
  - resolving more warnings [\#1369](https://github.com/digital-ai/dot-components/pull/1369) ([CWSites](https://github.com/CWSites))
402
+ - Upload drip echo icon [\#1366](https://github.com/digital-ai/dot-components/pull/1366) ([pauldigitalai](https://github.com/pauldigitalai))
390
403
 
391
404
  ## [2.2.1](https://www.npmjs.com/package/@digital-ai/dot-components) (02/08/2023)
392
405
 
393
406
  [Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/1.21.8...2.2.1)
394
407
 
395
- **Features:**
396
-
397
- - S-90007 Expose ListboxComponent [\#1358](https://github.com/digital-ai/dot-components/pull/1358) ([angel-git](https://github.com/angel-git))
398
-
399
408
  **Fixed bugs:**
400
409
 
401
410
  - S-90105 `DotAutoComplete`: fix `readOnly` input attribute [\#1357](https://github.com/digital-ai/dot-components/pull/1357) ([angel-git](https://github.com/angel-git))
@@ -407,7 +416,6 @@
407
416
  **Misc:**
408
417
 
409
418
  - GitHub Action Troubleshooting [\#1368](https://github.com/digital-ai/dot-components/pull/1368) ([CWSites](https://github.com/CWSites))
410
- - Upload drip echo icon [\#1366](https://github.com/digital-ai/dot-components/pull/1366) ([pauldigitalai](https://github.com/pauldigitalai))
411
419
  - S-90007 Add missing test [\#1362](https://github.com/digital-ai/dot-components/pull/1362) ([angel-git](https://github.com/angel-git))
412
420
  - icons-pin-update-Jan-27th [\#1354](https://github.com/digital-ai/dot-components/pull/1354) ([pauldigitalai](https://github.com/pauldigitalai))
413
421
 
@@ -549,6 +557,7 @@
549
557
  **Features:**
550
558
 
551
559
  - S-87871 Expose callback when sidebar collapses/expands [\#1274](https://github.com/digital-ai/dot-components/pull/1274) ([angel-git](https://github.com/angel-git))
560
+ - S-87316 Add focus state for Inline Edit [\#1255](https://github.com/digital-ai/dot-components/pull/1255) ([nikolinadapic](https://github.com/nikolinadapic))
552
561
 
553
562
  **Fixed bugs:**
554
563
 
@@ -577,10 +586,6 @@
577
586
 
578
587
  [Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/2.0.0-rc.1...1.21.2)
579
588
 
580
- **Features:**
581
-
582
- - S-87316 Add focus state for Inline Edit [\#1255](https://github.com/digital-ai/dot-components/pull/1255) ([nikolinadapic](https://github.com/nikolinadapic))
583
-
584
589
  **Fixed bugs:**
585
590
 
586
591
  - D-22241: `DotFileListItem`: fix focus states and expose `onKeyPress` [\#1254](https://github.com/digital-ai/dot-components/pull/1254) ([dmiletic85](https://github.com/dmiletic85))
@@ -952,7 +957,6 @@
952
957
 
953
958
  - D-19722: `Table`: Fix Storybook issues by refactoring Table's story. [\#974](https://github.com/digital-ai/dot-components/pull/974) ([dmiletic85](https://github.com/dmiletic85))
954
959
  - D-19713: Do not show alert banner close button if onClose not provided [\#973](https://github.com/digital-ai/dot-components/pull/973) ([selsemore](https://github.com/selsemore))
955
- - D-19474: DotDrawer fixes [\#939](https://github.com/digital-ai/dot-components/pull/939) ([selsemore](https://github.com/selsemore))
956
960
 
957
961
  **Misc:**
958
962
 
@@ -997,6 +1001,7 @@
997
1001
  **Fixed bugs:**
998
1002
 
999
1003
  - D-19520: `AppToolbar`: Unnecessary scrollbar on the menu [\#941](https://github.com/digital-ai/dot-components/pull/941) ([dmiletic85](https://github.com/dmiletic85))
1004
+ - D-19474: DotDrawer fixes [\#939](https://github.com/digital-ai/dot-components/pull/939) ([selsemore](https://github.com/selsemore))
1000
1005
 
1001
1006
  **Misc:**
1002
1007
 
@@ -1021,6 +1026,7 @@
1021
1026
 
1022
1027
  **Features:**
1023
1028
 
1029
+ - S-80939: `Menu`: Add option to customize item's height [\#902](https://github.com/digital-ai/dot-components/pull/902) ([dmiletic85](https://github.com/dmiletic85))
1024
1030
  - S-77210: Component - Drawer [\#893](https://github.com/digital-ai/dot-components/pull/893) ([monapatel91](https://github.com/monapatel91))
1025
1031
 
1026
1032
  **Fixed bugs:**
@@ -1040,7 +1046,6 @@
1040
1046
 
1041
1047
  **Features:**
1042
1048
 
1043
- - S-80939: `Menu`: Add option to customize item's height [\#902](https://github.com/digital-ai/dot-components/pull/902) ([dmiletic85](https://github.com/dmiletic85))
1044
1049
  - S-80871: `Sidebar` Changes on back arrow [\#896](https://github.com/digital-ai/dot-components/pull/896) ([dmiletic85](https://github.com/dmiletic85))
1045
1050
  - S-80855: Display tooltip on last breadcrumb item \(on hover\) when it is clipped with ellipsis [\#883](https://github.com/digital-ai/dot-components/pull/883) ([dmiletic85](https://github.com/dmiletic85))
1046
1051
 
@@ -1364,10 +1369,6 @@
1364
1369
 
1365
1370
  [Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/1.0.9...1.0.10)
1366
1371
 
1367
- **Features:**
1368
-
1369
- - S-78487: Add agility colors for Accordion, Pill and Tabs [\#661](https://github.com/digital-ai/dot-components/pull/661) ([angel-git](https://github.com/angel-git))
1370
-
1371
1372
  **Fixed bugs:**
1372
1373
 
1373
1374
  - D-18424: include breadcrumb wrapper with breadcrumb component [\#675](https://github.com/digital-ai/dot-components/pull/675) ([CWSites](https://github.com/CWSites))
@@ -1381,6 +1382,10 @@
1381
1382
 
1382
1383
  [Full Changelog](https://digital-ai.github.io/dot-components/?path=/story/introduction--page/digital-ai/dot-components/compare/1.0.8...1.0.9)
1383
1384
 
1385
+ **Features:**
1386
+
1387
+ - S-78487: Add agility colors for Accordion, Pill and Tabs [\#661](https://github.com/digital-ai/dot-components/pull/661) ([angel-git](https://github.com/angel-git))
1388
+
1384
1389
  **Fixed bugs:**
1385
1390
 
1386
1391
  - D-18730: action toolbar support [\#671](https://github.com/digital-ai/dot-components/pull/671) ([CWSites](https://github.com/CWSites))
package/index.esm.js CHANGED
@@ -8139,10 +8139,12 @@ const DotTablePagination = ({
8139
8139
  className,
8140
8140
  count,
8141
8141
  'data-testid': dataTestId,
8142
+ labelRowsPerPage,
8142
8143
  onPageChange,
8143
8144
  onRowsPerPageChange,
8144
8145
  page: _page = 0,
8145
8146
  rowsPerPage: _rowsPerPage = 10,
8147
+ rowsPerPageOptions: _rowsPerPageOptions = [...ROWS_PER_PAGE_OPTIONS],
8146
8148
  typography: _typography = 'subtitle2'
8147
8149
  }) => {
8148
8150
  const rootClasses = useStylesWithRootClass(rootClassName$h, className);
@@ -8170,11 +8172,12 @@ const DotTablePagination = ({
8170
8172
  component: "div",
8171
8173
  count: count,
8172
8174
  "data-testid": dataTestId,
8175
+ labelRowsPerPage: labelRowsPerPage,
8173
8176
  onPageChange: handlePageChange,
8174
8177
  onRowsPerPageChange: handleChangeRowsPerPage,
8175
8178
  page: _page,
8176
8179
  rowsPerPage: _rowsPerPage,
8177
- rowsPerPageOptions: [...ROWS_PER_PAGE_OPTIONS]
8180
+ rowsPerPageOptions: _rowsPerPageOptions
8178
8181
  }, void 0)
8179
8182
  }), void 0)
8180
8183
  );
package/index.umd.js CHANGED
@@ -8854,14 +8854,17 @@
8854
8854
  className = _a.className,
8855
8855
  count = _a.count,
8856
8856
  dataTestId = _a["data-testid"],
8857
+ labelRowsPerPage = _a.labelRowsPerPage,
8857
8858
  onPageChange = _a.onPageChange,
8858
8859
  onRowsPerPageChange = _a.onRowsPerPageChange,
8859
8860
  _b = _a.page,
8860
8861
  page = _b === void 0 ? 0 : _b,
8861
8862
  _c = _a.rowsPerPage,
8862
8863
  rowsPerPage = _c === void 0 ? 10 : _c,
8863
- _d = _a.typography,
8864
- typography = _d === void 0 ? 'subtitle2' : _d;
8864
+ _d = _a.rowsPerPageOptions,
8865
+ rowsPerPageOptions = _d === void 0 ? __spreadArray([], ROWS_PER_PAGE_OPTIONS) : _d,
8866
+ _e = _a.typography,
8867
+ typography = _e === void 0 ? 'subtitle2' : _e;
8865
8868
  var rootClasses = useStylesWithRootClass(rootClassName$h, className);
8866
8869
  var handlePageChange = function handlePageChange(event, newPage) {
8867
8870
  onPageChange && onPageChange(newPage);
@@ -8887,11 +8890,12 @@
8887
8890
  component: "div",
8888
8891
  count: count,
8889
8892
  "data-testid": dataTestId,
8893
+ labelRowsPerPage: labelRowsPerPage,
8890
8894
  onPageChange: handlePageChange,
8891
8895
  onRowsPerPageChange: handleChangeRowsPerPage,
8892
8896
  page: page,
8893
8897
  rowsPerPage: rowsPerPage,
8894
- rowsPerPageOptions: __spreadArray([], ROWS_PER_PAGE_OPTIONS)
8898
+ rowsPerPageOptions: rowsPerPageOptions
8895
8899
  }, void 0)
8896
8900
  }), void 0)
8897
8901
  );
@@ -1,4 +1,4 @@
1
- import { ChangeEvent } from 'react';
1
+ import { ChangeEvent, ReactNode } from 'react';
2
2
  import { CommonProps } from '../CommonProps';
3
3
  import { TypographyVariant } from '../typography/Typography';
4
4
  export declare const ROWS_PER_PAGE_OPTIONS: readonly [10, 25, 50, 100, 150, 200];
@@ -6,6 +6,8 @@ export declare type RowsPerPageOption = typeof ROWS_PER_PAGE_OPTIONS[number];
6
6
  export interface TablePaginationProps extends CommonProps {
7
7
  /** Total number of rows (-1 if unknown) */
8
8
  count: number;
9
+ /** Customize the rows per page label. Default is 'Rows per page:' */
10
+ labelRowsPerPage?: ReactNode;
9
11
  /** Callback fired when the page is changed */
10
12
  onPageChange: (newPage: number) => void;
11
13
  /** Callback fired when the number of rows per page is changed */
@@ -13,9 +15,11 @@ export interface TablePaginationProps extends CommonProps {
13
15
  /** The zero-based index of the current page */
14
16
  page?: number;
15
17
  /** The number of rows per page */
16
- rowsPerPage?: RowsPerPageOption;
18
+ rowsPerPage?: number;
19
+ /** Customizes the options of the rows per page select field. Default: [10, 25, 50, 100, 150, 200] */
20
+ rowsPerPageOptions?: number[];
17
21
  /** Typography variant which will be used for pagination text */
18
22
  typography: TypographyVariant;
19
23
  }
20
24
  /** This component wraps the TablePagination component from @material-ui. */
21
- export declare const DotTablePagination: ({ ariaLabel, className, count, "data-testid": dataTestId, onPageChange, onRowsPerPageChange, page, rowsPerPage, typography, }: TablePaginationProps) => JSX.Element;
25
+ export declare const DotTablePagination: ({ ariaLabel, className, count, "data-testid": dataTestId, labelRowsPerPage, onPageChange, onRowsPerPageChange, page, rowsPerPage, rowsPerPageOptions, typography, }: TablePaginationProps) => JSX.Element;
@@ -1,5 +1,7 @@
1
1
  import { ComponentMeta, Story } from '@storybook/react';
2
2
  import { TablePaginationProps } from './TablePagination';
3
- declare const _default: ComponentMeta<({ ariaLabel, className, count, "data-testid": dataTestId, onPageChange, onRowsPerPageChange, page, rowsPerPage, typography, }: TablePaginationProps) => JSX.Element>;
3
+ declare const _default: ComponentMeta<({ ariaLabel, className, count, "data-testid": dataTestId, labelRowsPerPage, onPageChange, onRowsPerPageChange, page, rowsPerPage, rowsPerPageOptions, typography, }: TablePaginationProps) => JSX.Element>;
4
4
  export default _default;
5
5
  export declare const Default: Story<TablePaginationProps>;
6
+ export declare const WithCustomRowsPerPageOptions: any;
7
+ export declare const WithCustomRowsPerPageLabel: any;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@digital-ai/dot-components",
3
- "version": "2.11.3",
3
+ "version": "2.12.0",
4
4
  "private": false,
5
5
  "license": "SEE LICENSE IN <LICENSE.md>",
6
6
  "contributors": [