@thecb/components 7.8.2-beta.5 → 7.8.2-beta.7

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/dist/index.cjs.js CHANGED
@@ -46667,7 +46667,7 @@ var Pagination = function Pagination(_ref3) {
46667
46667
  isMobile = _useContext.isMobile;
46668
46668
 
46669
46669
  var extraStyles = "\n min-width: ".concat(buttonWidth, "; min-height: 100%; padding: 0;\n border-radius: ").concat(borderRadius, ";\n &:hover, &:focus {\n text-decoration: none;\n > * > span {\n text-decoration: none;\n }\n }\n > * > span {\n color: ").concat(numberColor !== null && numberColor !== void 0 ? numberColor : themeValues.numberColor, "\n }\n margin: 0;\n &:hover {\n background-color: ").concat(themeValues.hoverBackgroundColor, "\n }\n ");
46670
- var extraDisabledStyles = "\n border: ".concat(activeBorderWidth, " solid ").concat(numberColor !== null && numberColor !== void 0 ? numberColor : themeValues.numberColor, ";\n color: ").concat(numberColor !== null && numberColor !== void 0 ? numberColor : themeValues.activeColor, ";\n background-color: ").concat(themeValues.activeBackgroundColor, ";\n &:focus {\n box-shadow: none;\n }\n &:hover {\n background-color: initial;\n }\n ");
46670
+ var currentPageStyles = "\n border: ".concat(activeBorderWidth, " solid ").concat(numberColor !== null && numberColor !== void 0 ? numberColor : themeValues.numberColor, ";\n color: ").concat(numberColor !== null && numberColor !== void 0 ? numberColor : themeValues.activeColor, ";\n background-color: ").concat(themeValues.activeBackgroundColor, ";\n &:focus {\n box-shadow: none;\n }\n &:hover {\n background-color: initial;\n border: ").concat(activeBorderWidth, " solid ").concat(numberColor !== null && numberColor !== void 0 ? numberColor : themeValues.numberColor, ";\n background-color: ").concat(themeValues.activeBackgroundColor, ";\n }\n ");
46671
46671
  return /*#__PURE__*/React__default.createElement(Cluster, {
46672
46672
  justify: "center",
46673
46673
  childGap: childGap,
@@ -46679,7 +46679,7 @@ var Pagination = function Pagination(_ref3) {
46679
46679
  extraStyles: "> ul { padding: 0px; > li { list-style-type: none; } };"
46680
46680
  }, currentPage > 1 ? /*#__PURE__*/React__default.createElement(PrevNextButton, {
46681
46681
  action: pagePrevious,
46682
- ariaLabel: "Previous Page Button",
46682
+ ariaLabel: "Previous Page",
46683
46683
  arrowColor: arrowColor !== null && arrowColor !== void 0 ? arrowColor : themeValues.arrowColor,
46684
46684
  borderRadius: borderRadius,
46685
46685
  buttonHeight: buttonHeight,
@@ -46707,17 +46707,15 @@ var Pagination = function Pagination(_ref3) {
46707
46707
  }, /*#__PURE__*/React__default.createElement(ButtonWithAction, {
46708
46708
  variant: "ghost",
46709
46709
  text: item.index,
46710
- disabled: item.active,
46711
- extraDisabledStyles: extraDisabledStyles,
46712
46710
  "aria-current": item.active ? "page" : undefined,
46713
- "aria-label": "".concat(item.active ? "Current " : "", "Page ").concat(item.index, " Button"),
46711
+ "aria-label": "".concat(item.index == pageCount ? "Last Page, " : "", "page ").concat(item.index),
46714
46712
  action: !item.active ? function () {
46715
46713
  return setCurrentPage({
46716
46714
  pageNumber: item.index
46717
46715
  });
46718
46716
  } : noop,
46719
46717
  textExtraStyles: "font-size: ".concat(fontSize, "; font-weight: ").concat(fontWeight, ";"),
46720
- extraStyles: extraStyles,
46718
+ extraStyles: "".concat(extraStyles).concat(item.active ? currentPageStyles : ""),
46721
46719
  dataQa: index
46722
46720
  }, item.index)) : /*#__PURE__*/React__default.createElement(Box, {
46723
46721
  padding: "0 10px",
@@ -46728,11 +46726,12 @@ var Pagination = function Pagination(_ref3) {
46728
46726
  }, /*#__PURE__*/React__default.createElement(Text$1, {
46729
46727
  variant: "pXL",
46730
46728
  weight: fontWeight,
46731
- color: numberColor !== null && numberColor !== void 0 ? numberColor : themeValues.numberColor
46732
- }, "...")));
46729
+ color: numberColor !== null && numberColor !== void 0 ? numberColor : themeValues.numberColor,
46730
+ role: "presentation"
46731
+ }, "…")));
46733
46732
  }), currentPage < pageCount ? /*#__PURE__*/React__default.createElement(PrevNextButton, {
46734
46733
  action: pageNext,
46735
- ariaLabel: "Next Page Button",
46734
+ ariaLabel: "Next Page",
46736
46735
  arrowColor: arrowColor !== null && arrowColor !== void 0 ? arrowColor : themeValues.arrowColor,
46737
46736
  borderRadius: borderRadius,
46738
46737
  buttonHeight: buttonHeight,