@patternfly/react-core 4.171.0 → 4.174.1

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.
Files changed (68) hide show
  1. package/CHANGELOG.md +41 -0
  2. package/dist/esm/components/ContextSelector/ContextSelectorItem.d.ts +3 -1
  3. package/dist/esm/components/ContextSelector/ContextSelectorItem.d.ts.map +1 -1
  4. package/dist/esm/components/ContextSelector/ContextSelectorItem.js +7 -4
  5. package/dist/esm/components/ContextSelector/ContextSelectorItem.js.map +1 -1
  6. package/dist/esm/components/Menu/MenuItem.d.ts.map +1 -1
  7. package/dist/esm/components/Menu/MenuItem.js +3 -1
  8. package/dist/esm/components/Menu/MenuItem.js.map +1 -1
  9. package/dist/esm/components/Pagination/Navigation.d.ts +2 -0
  10. package/dist/esm/components/Pagination/Navigation.d.ts.map +1 -1
  11. package/dist/esm/components/Pagination/Navigation.js +4 -4
  12. package/dist/esm/components/Pagination/Navigation.js.map +1 -1
  13. package/dist/esm/components/Pagination/OptionsToggle.js +3 -3
  14. package/dist/esm/components/Pagination/OptionsToggle.js.map +1 -1
  15. package/dist/esm/components/Pagination/Pagination.d.ts +1 -1
  16. package/dist/esm/components/Pagination/Pagination.d.ts.map +1 -1
  17. package/dist/esm/components/Pagination/Pagination.js +27 -18
  18. package/dist/esm/components/Pagination/Pagination.js.map +1 -1
  19. package/dist/esm/components/Pagination/PaginationOptionsMenu.d.ts +1 -1
  20. package/dist/esm/components/Pagination/PaginationOptionsMenu.d.ts.map +1 -1
  21. package/dist/esm/components/Pagination/PaginationOptionsMenu.js +3 -14
  22. package/dist/esm/components/Pagination/PaginationOptionsMenu.js.map +1 -1
  23. package/dist/js/components/ContextSelector/ContextSelectorItem.d.ts +3 -1
  24. package/dist/js/components/ContextSelector/ContextSelectorItem.d.ts.map +1 -1
  25. package/dist/js/components/ContextSelector/ContextSelectorItem.js +7 -4
  26. package/dist/js/components/ContextSelector/ContextSelectorItem.js.map +1 -1
  27. package/dist/js/components/Menu/MenuItem.d.ts.map +1 -1
  28. package/dist/js/components/Menu/MenuItem.js +3 -1
  29. package/dist/js/components/Menu/MenuItem.js.map +1 -1
  30. package/dist/js/components/Pagination/Navigation.d.ts +2 -0
  31. package/dist/js/components/Pagination/Navigation.d.ts.map +1 -1
  32. package/dist/js/components/Pagination/Navigation.js +4 -4
  33. package/dist/js/components/Pagination/Navigation.js.map +1 -1
  34. package/dist/js/components/Pagination/OptionsToggle.js +3 -3
  35. package/dist/js/components/Pagination/OptionsToggle.js.map +1 -1
  36. package/dist/js/components/Pagination/Pagination.d.ts +1 -1
  37. package/dist/js/components/Pagination/Pagination.d.ts.map +1 -1
  38. package/dist/js/components/Pagination/Pagination.js +30 -21
  39. package/dist/js/components/Pagination/Pagination.js.map +1 -1
  40. package/dist/js/components/Pagination/PaginationOptionsMenu.d.ts +1 -1
  41. package/dist/js/components/Pagination/PaginationOptionsMenu.d.ts.map +1 -1
  42. package/dist/js/components/Pagination/PaginationOptionsMenu.js +3 -14
  43. package/dist/js/components/Pagination/PaginationOptionsMenu.js.map +1 -1
  44. package/dist/umd/react-core.css +343 -87
  45. package/dist/umd/react-core.js +55 -51
  46. package/dist/umd/react-core.min.css +343 -87
  47. package/dist/umd/react-core.min.js +4 -4
  48. package/package.json +6 -6
  49. package/src/components/ContextSelector/ContextSelectorItem.tsx +18 -7
  50. package/src/components/ContextSelector/__tests__/__snapshots__/ContextSelector.test.tsx.snap +5 -0
  51. package/src/components/ContextSelector/__tests__/__snapshots__/ContextSelectorMenuList.test.tsx.snap +10 -0
  52. package/src/components/ContextSelector/examples/ContextSelector.md +80 -15
  53. package/src/components/Menu/MenuItem.tsx +3 -1
  54. package/src/components/Nav/examples/Nav.md +98 -0
  55. package/src/components/Nav/examples/nav.css +1 -0
  56. package/src/components/Pagination/Navigation.tsx +11 -4
  57. package/src/components/Pagination/OptionsToggle.tsx +3 -3
  58. package/src/components/Pagination/Pagination.tsx +40 -23
  59. package/src/components/Pagination/PaginationOptionsMenu.tsx +4 -15
  60. package/src/components/Pagination/__tests__/Generated/__snapshots__/Navigation.test.tsx.snap +0 -7
  61. package/src/components/Pagination/__tests__/Generated/__snapshots__/OptionsToggle.test.tsx.snap +1 -1
  62. package/src/components/Pagination/__tests__/Generated/__snapshots__/Pagination.test.tsx.snap +3 -8
  63. package/src/components/Pagination/__tests__/Pagination.test.tsx +24 -0
  64. package/src/components/Pagination/__tests__/__snapshots__/Pagination.test.tsx.snap +187 -157
  65. package/src/components/Pagination/examples/Pagination.md +35 -0
  66. package/src/components/TextInputGroup/examples/TextInputGroup.md +4 -4
  67. package/src/demos/ComposableMenu.md +27 -6
  68. package/src/demos/TextInputGroupDemo.md +278 -0
@@ -4477,13 +4477,14 @@
4477
4477
  "menu": "pf-c-menu",
4478
4478
  "modifiers": {
4479
4479
  "fullHeight": "pf-m-full-height",
4480
+ "expanded": "pf-m-expanded",
4480
4481
  "action": "pf-m-action",
4481
4482
  "disabled": "pf-m-disabled",
4482
4483
  "plain": "pf-m-plain",
4483
4484
  "splitButton": "pf-m-split-button",
4484
- "active": "pf-m-active",
4485
- "expanded": "pf-m-expanded",
4486
4485
  "primary": "pf-m-primary",
4486
+ "active": "pf-m-active",
4487
+ "secondary": "pf-m-secondary",
4487
4488
  "top": "pf-m-top",
4488
4489
  "alignRight": "pf-m-align-right",
4489
4490
  "alignLeft": "pf-m-align-left",
@@ -8308,14 +8309,16 @@
8308
8309
  }
8309
8310
  render() {
8310
8311
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
8311
- const _a = this.props, { className, children, onClick, isDisabled, index, sendRef } = _a, props = __rest$1(_a, ["className", "children", "onClick", "isDisabled", "index", "sendRef"]);
8312
+ const _a = this.props, { className, children, onClick, isDisabled, index, sendRef, href } = _a, props = __rest$1(_a, ["className", "children", "onClick", "isDisabled", "index", "sendRef", "href"]);
8313
+ const Component = href ? 'a' : 'button';
8314
+ const isDisabledLink = href && isDisabled;
8312
8315
  return (React__namespace.createElement(ContextSelectorContext.Consumer, null, ({ onSelect }) => (React__namespace.createElement("li", { role: "none" },
8313
- React__namespace.createElement("button", Object.assign({ className: css(_default$V.contextSelectorMenuListItem, className), ref: this.ref, onClick: event => {
8316
+ React__namespace.createElement(Component, Object.assign({ className: css(_default$V.contextSelectorMenuListItem, isDisabledLink && _default$V.modifiers.disabled, className), ref: this.ref, onClick: event => {
8314
8317
  if (!isDisabled) {
8315
8318
  onClick(event);
8316
8319
  onSelect(event, children);
8317
8320
  }
8318
- }, disabled: isDisabled }, props), children)))));
8321
+ }, disabled: isDisabled && !href, href: href }, (isDisabledLink && { 'aria-disabled': true, tabIndex: -1 }), props), children)))));
8319
8322
  }
8320
8323
  }
8321
8324
  ContextSelectorItem.displayName = 'ContextSelectorItem';
@@ -8325,7 +8328,8 @@
8325
8328
  isDisabled: false,
8326
8329
  onClick: () => undefined,
8327
8330
  index: undefined,
8328
- sendRef: () => { }
8331
+ sendRef: () => { },
8332
+ href: null
8329
8333
  };
8330
8334
 
8331
8335
  const ContextSelectorFooter = (_a) => {
@@ -14466,7 +14470,9 @@
14466
14470
  if (Component === 'a') {
14467
14471
  additionalProps = {
14468
14472
  href: to,
14469
- 'aria-disabled': isDisabled ? true : null
14473
+ 'aria-disabled': isDisabled ? true : null,
14474
+ // prevent invalid 'disabled' attribute on <a> tags
14475
+ disabled: null
14470
14476
  };
14471
14477
  }
14472
14478
  else if (Component === 'button') {
@@ -14578,9 +14584,10 @@
14578
14584
  "menuToggleToggleIcon": "pf-c-menu-toggle__toggle-icon",
14579
14585
  "modifiers": {
14580
14586
  "primary": "pf-m-primary",
14587
+ "secondary": "pf-m-secondary",
14588
+ "expanded": "pf-m-expanded",
14581
14589
  "plain": "pf-m-plain",
14582
14590
  "text": "pf-m-text",
14583
- "expanded": "pf-m-expanded",
14584
14591
  "fullHeight": "pf-m-full-height"
14585
14592
  }
14586
14593
  };
@@ -14882,9 +14889,14 @@
14882
14889
  var _default$v = {
14883
14890
  "divider": "pf-c-divider",
14884
14891
  "menu": "pf-c-menu",
14892
+ "menuContent": "pf-c-menu__content",
14885
14893
  "menuItem": "pf-c-menu__item",
14886
14894
  "menuListItem": "pf-c-menu__list-item",
14887
14895
  "modifiers": {
14896
+ "flyout": "pf-m-flyout",
14897
+ "top": "pf-m-top",
14898
+ "left": "pf-m-left",
14899
+ "current": "pf-m-current",
14888
14900
  "horizontal": "pf-m-horizontal",
14889
14901
  "tertiary": "pf-m-tertiary",
14890
14902
  "horizontalSubnav": "pf-m-horizontal-subnav",
@@ -14893,11 +14905,7 @@
14893
14905
  "overflowHidden": "pf-m-overflow-hidden",
14894
14906
  "expandable": "pf-m-expandable",
14895
14907
  "expanded": "pf-m-expanded",
14896
- "flyout": "pf-m-flyout",
14897
- "top": "pf-m-top",
14898
- "left": "pf-m-left",
14899
14908
  "drilldown": "pf-m-drilldown",
14900
- "current": "pf-m-current",
14901
14909
  "start": "pf-m-start"
14902
14910
  },
14903
14911
  "nav": "pf-c-nav",
@@ -16220,7 +16228,7 @@
16220
16228
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
16221
16229
  perPage,
16222
16230
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
16223
- onSetPage, isDisabled, lastPage, firstPage, pagesTitle, toLastPage, toNextPage, toFirstPage, toPreviousPage, currPage, paginationTitle, ofWord, onNextClick, onPreviousClick, onFirstClick, onLastClick, onPageInput, className, isCompact } = _a, props = __rest$1(_a, ["page", "perPage", "onSetPage", "isDisabled", "lastPage", "firstPage", "pagesTitle", "toLastPage", "toNextPage", "toFirstPage", "toPreviousPage", "currPage", "paginationTitle", "ofWord", "onNextClick", "onPreviousClick", "onFirstClick", "onLastClick", "onPageInput", "className", "isCompact"]);
16231
+ onSetPage, isDisabled, itemCount, lastPage, firstPage, pagesTitle, toLastPage, toNextPage, toFirstPage, toPreviousPage, currPage, paginationTitle, ofWord, onNextClick, onPreviousClick, onFirstClick, onLastClick, onPageInput, className, isCompact } = _a, props = __rest$1(_a, ["page", "perPage", "onSetPage", "isDisabled", "itemCount", "lastPage", "firstPage", "pagesTitle", "toLastPage", "toNextPage", "toFirstPage", "toPreviousPage", "currPage", "paginationTitle", "ofWord", "onNextClick", "onPreviousClick", "onFirstClick", "onLastClick", "onPageInput", "className", "isCompact"]);
16224
16232
  const { userInputPage } = this.state;
16225
16233
  return (React__namespace.createElement("nav", Object.assign({ className: css(_default$p.paginationNav, className), "aria-label": paginationTitle }, props),
16226
16234
  !isCompact && (React__namespace.createElement("div", { className: css(_default$p.paginationNavControl, _default$p.modifiers.first) },
@@ -16239,11 +16247,11 @@
16239
16247
  }, "aria-label": toPreviousPage },
16240
16248
  React__namespace.createElement(AngleLeftIcon$1, null))),
16241
16249
  !isCompact && (React__namespace.createElement("div", { className: _default$p.paginationNavPageSelect },
16242
- React__namespace.createElement("input", { className: css(_default$p.formControl), "aria-label": currPage, type: "number", disabled: isDisabled || (page === firstPage && page === lastPage) || page === 0, min: lastPage <= 0 && firstPage <= 0 ? 0 : 1, max: lastPage, value: userInputPage, onKeyDown: event => this.onKeyDown(event, page, lastPage, onPageInput), onChange: event => this.onChange(event, lastPage) }),
16243
- React__namespace.createElement("span", { "aria-hidden": "true" },
16250
+ React__namespace.createElement("input", { className: css(_default$p.formControl), "aria-label": currPage, type: "number", disabled: isDisabled || (itemCount && page === firstPage && page === lastPage && itemCount >= 0) || page === 0, min: lastPage <= 0 && firstPage <= 0 ? 0 : 1, max: lastPage, value: userInputPage, onKeyDown: event => this.onKeyDown(event, page, lastPage, onPageInput), onChange: event => this.onChange(event, lastPage) }),
16251
+ (itemCount || itemCount === 0) && (React__namespace.createElement("span", { "aria-hidden": "true" },
16244
16252
  ofWord,
16245
16253
  " ",
16246
- pagesTitle ? pluralize(lastPage, pagesTitle) : lastPage))),
16254
+ pagesTitle ? pluralize(lastPage, pagesTitle) : lastPage)))),
16247
16255
  React__namespace.createElement("div", { className: _default$p.paginationNavControl },
16248
16256
  React__namespace.createElement(Button, { variant: exports.ButtonVariant.plain, isDisabled: isDisabled || page === lastPage, "aria-label": toNextPage, "data-action": "next", onClick: event => {
16249
16257
  const newPage = page + 1 <= lastPage ? page + 1 : lastPage;
@@ -16286,11 +16294,11 @@
16286
16294
  let toggleId = 0;
16287
16295
  const OptionsToggle = ({ itemsTitle = 'items', optionsToggle = 'Items per page',
16288
16296
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
16289
- itemsPerPageTitle = 'Items per page', ofWord = 'of', firstIndex = 0, lastIndex = 0, itemCount = 0, widgetId = '', showToggle = true,
16297
+ itemsPerPageTitle = 'Items per page', ofWord = 'of', firstIndex = 0, lastIndex = 0, itemCount, widgetId = '', showToggle = true,
16290
16298
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
16291
- onToggle = (_isOpen) => undefined, isOpen = false, isDisabled = false, parentRef = null, toggleTemplate: ToggleTemplate = '', onEnter = null }) => (React__namespace.createElement("div", { className: css(_default$r.optionsMenuToggle, isDisabled && _default$r.modifiers.disabled, _default$r.modifiers.plain, _default$r.modifiers.text) }, showToggle && (React__namespace.createElement(React__namespace.Fragment, null,
16299
+ onToggle = (_isOpen) => undefined, isOpen = false, isDisabled = false, parentRef = null, toggleTemplate: ToggleTemplate, onEnter = null }) => (React__namespace.createElement("div", { className: css(_default$r.optionsMenuToggle, isDisabled && _default$r.modifiers.disabled, _default$r.modifiers.plain, _default$r.modifiers.text) }, showToggle && (React__namespace.createElement(React__namespace.Fragment, null,
16292
16300
  React__namespace.createElement("span", { className: css(_default$r.optionsMenuToggleText) }, typeof ToggleTemplate === 'string' ? (fillTemplate(ToggleTemplate, { firstIndex, lastIndex, ofWord, itemCount, itemsTitle })) : (React__namespace.createElement(ToggleTemplate, { firstIndex: firstIndex, lastIndex: lastIndex, ofWord: ofWord, itemCount: itemCount, itemsTitle: itemsTitle }))),
16293
- React__namespace.createElement(DropdownToggle, { onEnter: onEnter, "aria-label": optionsToggle, onToggle: onToggle, isDisabled: isDisabled || itemCount <= 0, isOpen: isOpen, id: `${widgetId}-toggle-${toggleId++}`, className: _default$r.optionsMenuToggleButton, parentRef: parentRef })))));
16301
+ React__namespace.createElement(DropdownToggle, { onEnter: onEnter, "aria-label": optionsToggle, onToggle: onToggle, isDisabled: isDisabled || (itemCount && itemCount <= 0), isOpen: isOpen, id: `${widgetId}-toggle-${toggleId++}`, className: _default$r.optionsMenuToggleButton, parentRef: parentRef })))));
16294
16302
  OptionsToggle.displayName = 'OptionsToggle';
16295
16303
 
16296
16304
  class PaginationOptionsMenu extends React__namespace.Component {
@@ -16349,19 +16357,7 @@
16349
16357
  baseComponent: 'div',
16350
16358
  ouiaComponentType: PaginationOptionsMenu.displayName
16351
16359
  } },
16352
- React__namespace.createElement(DropdownWithContext, { direction: dropDirection, isOpen: isOpen, toggle: React__namespace.createElement(OptionsToggle, { optionsToggle: optionsToggle, itemsPerPageTitle: itemsPerPageTitle, showToggle: perPageOptions && perPageOptions.length > 0, onToggle: this.onToggle, isOpen: isOpen, widgetId: widgetId, firstIndex: firstIndex, lastIndex: lastIndex, itemCount: itemCount, itemsTitle: itemsTitle, ofWord: ofWord, toggleTemplate: toggleTemplate
16353
- ? toggleTemplate
16354
- : ({ firstIndex, lastIndex, itemCount, ofWord, itemsTitle }) => (React__namespace.createElement(React__namespace.Fragment, null,
16355
- React__namespace.createElement("b", null,
16356
- firstIndex,
16357
- " - ",
16358
- lastIndex),
16359
- ' ',
16360
- ofWord,
16361
- " ",
16362
- React__namespace.createElement("b", null, itemCount),
16363
- " ",
16364
- itemsTitle)), parentRef: this.parentRef.current, isDisabled: isDisabled }), dropdownItems: this.renderItems(), isPlain: true })));
16360
+ React__namespace.createElement(DropdownWithContext, { direction: dropDirection, isOpen: isOpen, toggle: React__namespace.createElement(OptionsToggle, { optionsToggle: optionsToggle, itemsPerPageTitle: itemsPerPageTitle, showToggle: perPageOptions && perPageOptions.length > 0, onToggle: this.onToggle, isOpen: isOpen, widgetId: widgetId, firstIndex: firstIndex, lastIndex: lastIndex, itemCount: itemCount, itemsTitle: itemsTitle, ofWord: ofWord, toggleTemplate: toggleTemplate, parentRef: this.parentRef.current, isDisabled: isDisabled }), dropdownItems: this.renderItems(), isPlain: true })));
16365
16361
  }
16366
16362
  }
16367
16363
  PaginationOptionsMenu.displayName = 'PaginationOptionsMenu';
@@ -16379,8 +16375,8 @@
16379
16375
  firstIndex: 0,
16380
16376
  lastIndex: 0,
16381
16377
  defaultToFullPage: false,
16382
- itemCount: 0,
16383
16378
  itemsTitle: 'items',
16379
+ toggleTemplate: ToggleTemplate,
16384
16380
  onPerPageSelect: () => null
16385
16381
  };
16386
16382
 
@@ -16436,8 +16432,9 @@
16436
16432
  };
16437
16433
  }
16438
16434
  getLastPage() {
16439
- const { itemCount, perPage } = this.props;
16440
- return Math.ceil(itemCount / perPage) || 0;
16435
+ const { itemCount, perPage, page } = this.props;
16436
+ // when itemCount is not known let's set lastPage as page+1 as we don't know the total count
16437
+ return itemCount || itemCount === 0 ? Math.ceil(itemCount / perPage) || 0 : page + 1;
16441
16438
  }
16442
16439
  componentDidMount() {
16443
16440
  const node = this.paginationRef.current;
@@ -16456,26 +16453,34 @@
16456
16453
  if (!page && offset) {
16457
16454
  page = Math.ceil(offset / perPage);
16458
16455
  }
16459
- const lastPage = this.getLastPage();
16460
- if (page < firstPage && itemCount > 0) {
16461
- page = firstPage;
16462
- }
16463
- else if (page > lastPage) {
16464
- page = lastPage;
16456
+ if (page === 0 && !itemCount) {
16457
+ page = 1;
16465
16458
  }
16466
- const firstIndex = itemCount <= 0 ? 0 : (page - 1) * perPage + 1;
16467
- let lastIndex;
16468
- if (itemCount <= 0) {
16469
- lastIndex = 0;
16470
- }
16471
- else {
16472
- lastIndex = page === lastPage ? itemCount : page * perPage;
16459
+ const lastPage = this.getLastPage();
16460
+ let firstIndex = (page - 1) * perPage + 1;
16461
+ let lastIndex = page * perPage;
16462
+ if (itemCount || itemCount === 0) {
16463
+ firstIndex = itemCount <= 0 ? 0 : (page - 1) * perPage + 1;
16464
+ if (page < firstPage && itemCount > 0) {
16465
+ page = firstPage;
16466
+ }
16467
+ else if (page > lastPage) {
16468
+ page = lastPage;
16469
+ }
16470
+ if (itemCount >= 0) {
16471
+ lastIndex = page === lastPage || itemCount === 0 ? itemCount : page * perPage;
16472
+ }
16473
16473
  }
16474
+ const toggleTemplateProps = { firstIndex, lastIndex, itemCount, itemsTitle: titles.items, ofWord: titles.ofWord };
16474
16475
  return (React__namespace.createElement("div", Object.assign({ ref: this.paginationRef, className: css(_default$p.pagination, variant === exports.PaginationVariant.bottom && _default$p.modifiers.bottom, isCompact && _default$p.modifiers.compact, isStatic && _default$p.modifiers.static, isSticky && _default$p.modifiers.sticky, className), id: `${widgetId}-${paginationId++}` }, getOUIAProps(Pagination.displayName, ouiaId !== undefined ? ouiaId : this.state.ouiaStateId, ouiaSafe), props),
16475
16476
  variant === exports.PaginationVariant.top && (React__namespace.createElement("div", { className: css(_default$p.paginationTotalItems) },
16476
- React__namespace.createElement(ToggleTemplate, { firstIndex: firstIndex, lastIndex: lastIndex, itemCount: itemCount, itemsTitle: titles.items, ofWord: titles.ofWord }))),
16477
+ toggleTemplate && typeof toggleTemplate === 'string' && fillTemplate(toggleTemplate, toggleTemplateProps),
16478
+ toggleTemplate &&
16479
+ typeof toggleTemplate !== 'string' &&
16480
+ toggleTemplate(toggleTemplateProps),
16481
+ !toggleTemplate && (React__namespace.createElement(ToggleTemplate, { firstIndex: firstIndex, lastIndex: lastIndex, itemCount: itemCount, itemsTitle: titles.items, ofWord: titles.ofWord })))),
16477
16482
  React__namespace.createElement(PaginationOptionsMenu, { itemsPerPageTitle: titles.itemsPerPage, perPageSuffix: titles.perPageSuffix, itemsTitle: isCompact ? '' : titles.items, optionsToggle: titles.optionsToggle, perPageOptions: perPageOptions, firstIndex: itemsStart !== null ? itemsStart : firstIndex, lastIndex: itemsEnd !== null ? itemsEnd : lastIndex, ofWord: titles.ofWord, defaultToFullPage: defaultToFullPage, itemCount: itemCount, page: page, perPage: perPage, lastPage: lastPage, onPerPageSelect: onPerPageSelect, dropDirection: dropDirection, widgetId: widgetId, toggleTemplate: toggleTemplate, isDisabled: isDisabled }),
16478
- React__namespace.createElement(Navigation, { pagesTitle: titles.page, toLastPage: titles.toLastPage, toPreviousPage: titles.toPreviousPage, toNextPage: titles.toNextPage, toFirstPage: titles.toFirstPage, currPage: titles.currPage, paginationTitle: titles.paginationTitle, ofWord: titles.ofWord, page: itemCount <= 0 ? 0 : page, perPage: perPage, firstPage: itemsStart !== null ? itemsStart : 1, lastPage: lastPage, onSetPage: onSetPage, onFirstClick: onFirstClick, onPreviousClick: onPreviousClick, onNextClick: onNextClick, onLastClick: onLastClick, onPageInput: onPageInput, isDisabled: isDisabled, isCompact: isCompact }),
16483
+ React__namespace.createElement(Navigation, { pagesTitle: titles.page, toLastPage: titles.toLastPage, toPreviousPage: titles.toPreviousPage, toNextPage: titles.toNextPage, toFirstPage: titles.toFirstPage, currPage: titles.currPage, paginationTitle: titles.paginationTitle, ofWord: titles.ofWord, page: itemCount && itemCount <= 0 ? 0 : page, perPage: perPage, itemCount: itemCount, firstPage: itemsStart !== null ? itemsStart : 1, lastPage: lastPage, onSetPage: onSetPage, onFirstClick: onFirstClick, onPreviousClick: onPreviousClick, onNextClick: onNextClick, onLastClick: onLastClick, onPageInput: onPageInput, isDisabled: isDisabled, isCompact: isCompact }),
16479
16484
  children));
16480
16485
  }
16481
16486
  }
@@ -16510,7 +16515,6 @@
16510
16515
  itemsEnd: null,
16511
16516
  perPageOptions: defaultPerPageOptions,
16512
16517
  widgetId: 'pagination-options-menu',
16513
- toggleTemplate: ToggleTemplate,
16514
16518
  onSetPage: () => undefined,
16515
16519
  onPerPageSelect: () => undefined,
16516
16520
  onFirstClick: () => undefined,