@thecb/components 9.1.2-beta.1 → 9.1.2-beta.2
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.esm.js
CHANGED
|
@@ -6356,6 +6356,9 @@ var titleCaseString = function titleCaseString(string) {
|
|
|
6356
6356
|
return index === 0 || index === string.length - 1 || word.length > 3 ? titleCaseWord(word.toLowerCase()) : word;
|
|
6357
6357
|
}).join(" ");
|
|
6358
6358
|
};
|
|
6359
|
+
var kebabCaseString = function kebabCaseString(string) {
|
|
6360
|
+
return string === null || string === void 0 ? void 0 : string.replaceAll(" ", "-").toLowerCase();
|
|
6361
|
+
};
|
|
6359
6362
|
|
|
6360
6363
|
var general = /*#__PURE__*/Object.freeze({
|
|
6361
6364
|
__proto__: null,
|
|
@@ -6375,7 +6378,8 @@ var general = /*#__PURE__*/Object.freeze({
|
|
|
6375
6378
|
MOBILE_WIDTH: MOBILE_WIDTH,
|
|
6376
6379
|
throttle: throttle,
|
|
6377
6380
|
titleCaseWord: titleCaseWord,
|
|
6378
|
-
titleCaseString: titleCaseString
|
|
6381
|
+
titleCaseString: titleCaseString,
|
|
6382
|
+
kebabCaseString: kebabCaseString
|
|
6379
6383
|
});
|
|
6380
6384
|
|
|
6381
6385
|
var _excluded$1 = ["themeValues", "weight", "color", "textWrap", "extraStyles", "hoverStyles", "onClick", "onKeyPress", "as", "dataQa", "children", "variant"];
|
|
@@ -47084,6 +47088,7 @@ var PaymentButtonBar = function PaymentButtonBar(_ref) {
|
|
|
47084
47088
|
variant: backButtonVariant,
|
|
47085
47089
|
extraStyles: isMobile && "flex-grow: 1",
|
|
47086
47090
|
dataQa: cancelText,
|
|
47091
|
+
"aria-labelledby": "".concat(kebabCaseString(cancelText), "-button"),
|
|
47087
47092
|
role: "link"
|
|
47088
47093
|
}) : backButtonAction && /*#__PURE__*/React.createElement(ButtonWithAction, {
|
|
47089
47094
|
text: "Back",
|
|
@@ -47091,6 +47096,7 @@ var PaymentButtonBar = function PaymentButtonBar(_ref) {
|
|
|
47091
47096
|
action: backButtonAction,
|
|
47092
47097
|
extraStyles: isMobile && "flex-grow: 1",
|
|
47093
47098
|
dataQa: "Back",
|
|
47099
|
+
"aria-labelledby": "back-button",
|
|
47094
47100
|
role: "link"
|
|
47095
47101
|
});
|
|
47096
47102
|
var forwardButton = !!redirectURL ? /*#__PURE__*/React.createElement(ButtonWithLink, {
|
|
@@ -47100,6 +47106,7 @@ var PaymentButtonBar = function PaymentButtonBar(_ref) {
|
|
|
47100
47106
|
extraStyles: isMobile && "flex-grow: 1",
|
|
47101
47107
|
dataQa: redirectText,
|
|
47102
47108
|
disabled: isForwardButtonDisabled,
|
|
47109
|
+
"aria-labelledby": "".concat(kebabCaseString(redirectText), "-button"),
|
|
47103
47110
|
role: forwardButtonAriaRole
|
|
47104
47111
|
}) : forwardButtonAction && /*#__PURE__*/React.createElement(ButtonWithAction, {
|
|
47105
47112
|
text: forwardButtonText,
|
|
@@ -47109,6 +47116,7 @@ var PaymentButtonBar = function PaymentButtonBar(_ref) {
|
|
|
47109
47116
|
extraStyles: isMobile && "flex-grow: 1",
|
|
47110
47117
|
dataQa: forwardButtonText,
|
|
47111
47118
|
disabled: isForwardButtonDisabled,
|
|
47119
|
+
"aria-labelledby": "".concat(kebabCaseString(forwardButtonText), "-button"),
|
|
47112
47120
|
role: forwardButtonAriaRole
|
|
47113
47121
|
});
|
|
47114
47122
|
return /*#__PURE__*/React.createElement(Fragment$1, null, /*#__PURE__*/React.createElement(Box, {
|