@thecb/components 7.0.2-beta.1 → 7.0.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.cjs.js +15 -4
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.esm.js +15 -4
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/atoms/nav-tabs/NavTab.js +1 -1
package/dist/index.cjs.js
CHANGED
|
@@ -35281,7 +35281,8 @@ var fallbackValues$y = {
|
|
|
35281
35281
|
var NavTab = function NavTab(_ref) {
|
|
35282
35282
|
var path = _ref.path,
|
|
35283
35283
|
label = _ref.label,
|
|
35284
|
-
themeValues = _ref.themeValues
|
|
35284
|
+
themeValues = _ref.themeValues,
|
|
35285
|
+
minWidth = _ref.minWidth;
|
|
35285
35286
|
|
|
35286
35287
|
var _useContext = React.useContext(styled.ThemeContext),
|
|
35287
35288
|
isMobile = _useContext.isMobile;
|
|
@@ -35301,7 +35302,7 @@ var NavTab = function NavTab(_ref) {
|
|
|
35301
35302
|
}, /*#__PURE__*/React__default.createElement(InternalLink, {
|
|
35302
35303
|
color: isActive ? themeValues.activeColor : themeValues.linkColor,
|
|
35303
35304
|
to: path,
|
|
35304
|
-
extraStyles: "\n border-bottom: 3px solid transparent;\n font-family: ".concat(themeValues.fontFamily, ";\n text-decoration: none;\n ").concat(isActive && !isMobile ? border : "none", ";\n &:hover {\n text-decoration: none;\n color: ").concat(themeValues.activeColor, ";\n ").concat(isMobile ? "" : "".concat(border), "\n };\n padding: 1.25rem 0
|
|
35305
|
+
extraStyles: "\n border-bottom: 3px solid transparent;\n font-family: ".concat(themeValues.fontFamily, ";\n text-decoration: none;\n ").concat(isActive && !isMobile ? border : "none", ";\n &:hover {\n text-decoration: none;\n color: ").concat(themeValues.activeColor, ";\n ").concat(isMobile ? "" : "".concat(border), "\n };\n padding: 1.25rem 0;\n ")
|
|
35305
35306
|
}, label));
|
|
35306
35307
|
};
|
|
35307
35308
|
|
|
@@ -35309,13 +35310,16 @@ var NavTab$1 = themeComponent(NavTab, "NavTab", fallbackValues$y);
|
|
|
35309
35310
|
|
|
35310
35311
|
var NavTabs = function NavTabs(_ref) {
|
|
35311
35312
|
var tabsConfig = _ref.tabsConfig,
|
|
35312
|
-
tabGap = _ref.tabGap
|
|
35313
|
+
tabGap = _ref.tabGap,
|
|
35314
|
+
_ref$tabMinWidth = _ref.tabMinWidth,
|
|
35315
|
+
tabMinWidth = _ref$tabMinWidth === void 0 ? "100px" : _ref$tabMinWidth;
|
|
35313
35316
|
|
|
35314
35317
|
var _useContext = React.useContext(styled.ThemeContext),
|
|
35315
35318
|
isMobile = _useContext.isMobile;
|
|
35316
35319
|
|
|
35317
35320
|
var tabs = tabsConfig.map(function (tabConfig) {
|
|
35318
35321
|
return /*#__PURE__*/React__default.createElement(NavTab$1, _extends({
|
|
35322
|
+
minWidth: tabMinWidth,
|
|
35319
35323
|
key: tabConfig.path
|
|
35320
35324
|
}, tabConfig));
|
|
35321
35325
|
});
|
|
@@ -43466,7 +43470,14 @@ var Modal$1 = function Modal(_ref) {
|
|
|
43466
43470
|
var _useContext = React.useContext(styled.ThemeContext),
|
|
43467
43471
|
isMobile = _useContext.isMobile;
|
|
43468
43472
|
|
|
43469
|
-
|
|
43473
|
+
var modalContainerRef = React.useRef(null);
|
|
43474
|
+
return /*#__PURE__*/React__default.createElement("div", {
|
|
43475
|
+
ref: modalContainerRef
|
|
43476
|
+
}, 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
|
|
43477
|
+
, {
|
|
43478
|
+
focusTrapOptions: {
|
|
43479
|
+
fallbackFocus: modalContainerRef === null || modalContainerRef === void 0 ? void 0 : modalContainerRef.current
|
|
43480
|
+
},
|
|
43470
43481
|
onExit: onExit,
|
|
43471
43482
|
getApplicationNode: getApplicationNode,
|
|
43472
43483
|
titleText: modalHeaderText,
|