react-better-html 1.1.256 → 1.1.258
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.d.mts +3 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.js +12 -5
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +12 -5
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1479,6 +1479,7 @@ Image.profileImage = forwardRef3(function ProfileImage({ size = 40, letters, let
|
|
|
1479
1479
|
borderRadius: 999,
|
|
1480
1480
|
alignItems: "center",
|
|
1481
1481
|
justifyContent: "center",
|
|
1482
|
+
userSelect: "none",
|
|
1482
1483
|
ref,
|
|
1483
1484
|
...props,
|
|
1484
1485
|
width: size,
|
|
@@ -7453,7 +7454,7 @@ import { jsx as jsx25, jsxs as jsxs22 } from "react/jsx-runtime";
|
|
|
7453
7454
|
var tabBottomLineWidth = 2;
|
|
7454
7455
|
var tabDotSize = 6;
|
|
7455
7456
|
var defaultTabName = "tab";
|
|
7456
|
-
var TabsComponent = forwardRef17(function Tabs({ tabs, name, accentColor, style = "default", onChange, children, ...props }, ref) {
|
|
7457
|
+
var TabsComponent = forwardRef17(function Tabs({ tabs, name, accentColor, style = "default", gap, onChange, children, ...props }, ref) {
|
|
7457
7458
|
const reactRouterDomPlugin2 = usePlugin("react-router-dom");
|
|
7458
7459
|
const theme2 = useTheme27();
|
|
7459
7460
|
const urlQuery = reactRouterDomPlugin2 ? useUrlQuery() : void 0;
|
|
@@ -7461,6 +7462,7 @@ var TabsComponent = forwardRef17(function Tabs({ tabs, name, accentColor, style
|
|
|
7461
7462
|
const { colorTheme } = useBetterCoreContext10();
|
|
7462
7463
|
const firstRenderPassedRef = useRef8(false);
|
|
7463
7464
|
const tabsRef = useRef8({});
|
|
7465
|
+
const tabsGap = gap ?? (style === "box" ? theme2.styles.gap / 2 : 0);
|
|
7464
7466
|
const [selectedTab, setSelectedTab] = useState13(() => {
|
|
7465
7467
|
const selectedTabId = tabs[0];
|
|
7466
7468
|
if (urlQuery) {
|
|
@@ -7472,7 +7474,6 @@ var TabsComponent = forwardRef17(function Tabs({ tabs, name, accentColor, style
|
|
|
7472
7474
|
return selectedTabId;
|
|
7473
7475
|
});
|
|
7474
7476
|
const [rerenderState, setRerenderState] = useState13(0);
|
|
7475
|
-
const tabsGap = style === "box" ? theme2.styles.gap / 2 : 0;
|
|
7476
7477
|
const onClickTab = useCallback16(
|
|
7477
7478
|
(tab) => {
|
|
7478
7479
|
setSelectedTab(tab);
|
|
@@ -7556,6 +7557,7 @@ var TabsComponent = forwardRef17(function Tabs({ tabs, name, accentColor, style
|
|
|
7556
7557
|
return /* @__PURE__ */ jsxs22(
|
|
7557
7558
|
Div_default,
|
|
7558
7559
|
{
|
|
7560
|
+
className: "react-better-html-tabs-tab",
|
|
7559
7561
|
position: "relative",
|
|
7560
7562
|
width: "fit-content",
|
|
7561
7563
|
backgroundColor: style === "box" ? selected ? theme2.colors.primary : theme2.colors.backgroundContent : theme2.colors.backgroundBase,
|
|
@@ -8251,7 +8253,11 @@ var SideMenuComponent = function SideMenu({
|
|
|
8251
8253
|
}
|
|
8252
8254
|
) });
|
|
8253
8255
|
};
|
|
8254
|
-
SideMenuComponent.pageHolder = function SideMenuPageHolder({
|
|
8256
|
+
SideMenuComponent.pageHolder = function SideMenuPageHolder({
|
|
8257
|
+
additionalTopComponent,
|
|
8258
|
+
additionalBottomComponent,
|
|
8259
|
+
...props
|
|
8260
|
+
}) {
|
|
8255
8261
|
const theme2 = useTheme29();
|
|
8256
8262
|
const mediaQuery = useMediaQuery();
|
|
8257
8263
|
const { components, sideMenuIsCollapsed } = useBetterHtmlContextInternal();
|
|
@@ -8265,8 +8271,9 @@ SideMenuComponent.pageHolder = function SideMenuPageHolder({ outsideComponent, .
|
|
|
8265
8271
|
paddingLeft: !mediaQuery.size1000 ? !sideMenuIsCollapsed ? sideMenuWidth : sideMenuCollapsedWidth : void 0,
|
|
8266
8272
|
transition: theme2.styles.transition,
|
|
8267
8273
|
children: [
|
|
8268
|
-
|
|
8269
|
-
/* @__PURE__ */ jsx27(PageHolder_default, { ...props })
|
|
8274
|
+
additionalTopComponent,
|
|
8275
|
+
/* @__PURE__ */ jsx27(PageHolder_default, { ...props }),
|
|
8276
|
+
additionalBottomComponent
|
|
8270
8277
|
]
|
|
8271
8278
|
}
|
|
8272
8279
|
);
|