@thecb/components 9.2.7-beta.1 → 9.2.7-beta.3
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 +14 -6
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +14 -6
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/molecules/modal/Modal.js +3 -1
- package/src/components/molecules/terms-and-conditions-modal/TermsAndConditionsModal.js +3 -1
package/dist/index.cjs.js
CHANGED
|
@@ -45751,7 +45751,9 @@ var Modal$1 = function Modal(_ref) {
|
|
|
45751
45751
|
buttonExtraStyles = _ref.buttonExtraStyles,
|
|
45752
45752
|
children = _ref.children,
|
|
45753
45753
|
_ref$dataQa = _ref.dataQa,
|
|
45754
|
-
dataQa = _ref$dataQa === void 0 ? null : _ref$dataQa
|
|
45754
|
+
dataQa = _ref$dataQa === void 0 ? null : _ref$dataQa,
|
|
45755
|
+
_ref$initialFocus = _ref.initialFocus,
|
|
45756
|
+
initialFocus = _ref$initialFocus === void 0 ? null : _ref$initialFocus;
|
|
45755
45757
|
|
|
45756
45758
|
var _useContext = React.useContext(styled.ThemeContext),
|
|
45757
45759
|
isMobile = _useContext.isMobile;
|
|
@@ -45761,7 +45763,7 @@ var Modal$1 = function Modal(_ref) {
|
|
|
45761
45763
|
ref: modalContainerRef,
|
|
45762
45764
|
"data-qa": dataQa
|
|
45763
45765
|
}, modalOpen && /*#__PURE__*/React__default.createElement(reactAriaModal // fallback to resolve Jest unit test errors when tabbable doesn't exist in jsdom https://github.com/focus-trap/focus-trap-react/issues/91
|
|
45764
|
-
, {
|
|
45766
|
+
, _extends({
|
|
45765
45767
|
focusTrapOptions: {
|
|
45766
45768
|
fallbackFocus: modalContainerRef === null || modalContainerRef === void 0 ? void 0 : modalContainerRef.current
|
|
45767
45769
|
},
|
|
@@ -45779,7 +45781,9 @@ var Modal$1 = function Modal(_ref) {
|
|
|
45779
45781
|
},
|
|
45780
45782
|
underlayClickExits: underlayClickExits,
|
|
45781
45783
|
"aria-modal": true
|
|
45782
|
-
},
|
|
45784
|
+
}, initialFocus ? {
|
|
45785
|
+
initialFocus: initialFocus
|
|
45786
|
+
} : {}), /*#__PURE__*/React__default.createElement(Box, {
|
|
45783
45787
|
padding: "0",
|
|
45784
45788
|
borderRadius: "2px",
|
|
45785
45789
|
boxShadow: "inset 0px -2px 0px 0px rgb(0, 80, 149)"
|
|
@@ -47773,8 +47777,10 @@ var TermsAndConditionsModal = function TermsAndConditionsModal(_ref) {
|
|
|
47773
47777
|
variant = _ref.variant,
|
|
47774
47778
|
_ref$linkVariant = _ref.linkVariant,
|
|
47775
47779
|
linkVariant = _ref$linkVariant === void 0 ? "p" : _ref$linkVariant,
|
|
47776
|
-
themeValues = _ref.themeValues
|
|
47777
|
-
|
|
47780
|
+
themeValues = _ref.themeValues,
|
|
47781
|
+
_ref$initialFocus = _ref.initialFocus,
|
|
47782
|
+
initialFocus = _ref$initialFocus === void 0 ? null : _ref$initialFocus;
|
|
47783
|
+
return /*#__PURE__*/React__default.createElement(Modal$1, _extends({
|
|
47778
47784
|
modalOpen: isOpen,
|
|
47779
47785
|
hideModal: function hideModal() {
|
|
47780
47786
|
return toggleOpen(false);
|
|
@@ -47800,7 +47806,9 @@ var TermsAndConditionsModal = function TermsAndConditionsModal(_ref) {
|
|
|
47800
47806
|
toggleAccepted(true);
|
|
47801
47807
|
toggleOpen(false);
|
|
47802
47808
|
}
|
|
47803
|
-
},
|
|
47809
|
+
}, initialFocus ? {
|
|
47810
|
+
initialFocus: initialFocus
|
|
47811
|
+
} : {}), /*#__PURE__*/React__default.createElement(Text$1, {
|
|
47804
47812
|
variant: linkVariant,
|
|
47805
47813
|
onClick: function onClick() {
|
|
47806
47814
|
return toggleOpen(true);
|