@trackunit/react-components 1.1.25 → 1.1.28
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/index.cjs.js
CHANGED
|
@@ -3799,6 +3799,28 @@ const WidgetBody = ({ density = "auto", children, dataTestId, className, disable
|
|
|
3799
3799
|
return (jsxRuntime.jsx("div", { className: cvaWidgetBodyDensityContainer({ density, disableGap, className }), "data-testid": dataTestId, children: children }));
|
|
3800
3800
|
};
|
|
3801
3801
|
|
|
3802
|
+
const cvaZStackContainer = cssClassVarianceUtilities.cvaMerge(["grid", "grid-cols-1", "grid-rows-1"]);
|
|
3803
|
+
const cvaZStackItem = cssClassVarianceUtilities.cvaMerge(["col-start-1", "col-end-1", "row-start-1", "row-end-2"]);
|
|
3804
|
+
|
|
3805
|
+
/**
|
|
3806
|
+
* ZStack is a component that stacks its children on the z-axis.
|
|
3807
|
+
* Is a good alternative to "position: absolute" that avoids some of the unfortunate side effects of absolute positioning.
|
|
3808
|
+
*
|
|
3809
|
+
* @param { ZStackProps} props - The props for the ZStack component
|
|
3810
|
+
* @returns {JSX.Element} ZStack component
|
|
3811
|
+
*/
|
|
3812
|
+
const ZStack = ({ children, className, dataTestId }) => {
|
|
3813
|
+
return (jsxRuntime.jsx("div", { className: cvaZStackContainer({ className }), "data-testid": dataTestId, children: react.Children.map(children, (child, index) => {
|
|
3814
|
+
if (!react.isValidElement(child)) {
|
|
3815
|
+
return child;
|
|
3816
|
+
}
|
|
3817
|
+
return react.cloneElement(child, {
|
|
3818
|
+
className: cvaZStackItem({ className: child.props.className }),
|
|
3819
|
+
key: index,
|
|
3820
|
+
});
|
|
3821
|
+
}) }));
|
|
3822
|
+
};
|
|
3823
|
+
|
|
3802
3824
|
const cvaClickable = cssClassVarianceUtilities.cvaMerge([
|
|
3803
3825
|
"shadow-lg",
|
|
3804
3826
|
"rounded-lg",
|
|
@@ -3883,12 +3905,15 @@ exports.Tooltip = Tooltip;
|
|
|
3883
3905
|
exports.ValueBar = ValueBar;
|
|
3884
3906
|
exports.VirtualizedList = VirtualizedList;
|
|
3885
3907
|
exports.WidgetBody = WidgetBody;
|
|
3908
|
+
exports.ZStack = ZStack;
|
|
3886
3909
|
exports.cvaButton = cvaButton;
|
|
3887
3910
|
exports.cvaButtonPrefixSuffix = cvaButtonPrefixSuffix;
|
|
3888
3911
|
exports.cvaButtonSpinner = cvaButtonSpinner;
|
|
3889
3912
|
exports.cvaButtonSpinnerContainer = cvaButtonSpinnerContainer;
|
|
3890
3913
|
exports.cvaClickable = cvaClickable;
|
|
3914
|
+
exports.cvaContainerStyles = cvaContainerStyles;
|
|
3891
3915
|
exports.cvaIconButton = cvaIconButton;
|
|
3916
|
+
exports.cvaImgStyles = cvaImgStyles;
|
|
3892
3917
|
exports.cvaIndicator = cvaIndicator;
|
|
3893
3918
|
exports.cvaIndicatorIcon = cvaIndicatorIcon;
|
|
3894
3919
|
exports.cvaIndicatorIconBackground = cvaIndicatorIconBackground;
|
|
@@ -3903,6 +3928,14 @@ exports.cvaMenuItemSuffix = cvaMenuItemSuffix;
|
|
|
3903
3928
|
exports.cvaPageHeader = cvaPageHeader;
|
|
3904
3929
|
exports.cvaPageHeaderContainer = cvaPageHeaderContainer;
|
|
3905
3930
|
exports.cvaPageHeaderHeading = cvaPageHeaderHeading;
|
|
3931
|
+
exports.cvaToggleGroup = cvaToggleGroup;
|
|
3932
|
+
exports.cvaToggleItem = cvaToggleItem;
|
|
3933
|
+
exports.cvaToggleItemText = cvaToggleItemText;
|
|
3934
|
+
exports.cvaVirtualizedList = cvaVirtualizedList;
|
|
3935
|
+
exports.cvaVirtualizedListContainer = cvaVirtualizedListContainer;
|
|
3936
|
+
exports.cvaVirtualizedListItem = cvaVirtualizedListItem;
|
|
3937
|
+
exports.cvaZStackContainer = cvaZStackContainer;
|
|
3938
|
+
exports.cvaZStackItem = cvaZStackItem;
|
|
3906
3939
|
exports.docs = docs;
|
|
3907
3940
|
exports.getDevicePixelRatio = getDevicePixelRatio;
|
|
3908
3941
|
exports.getValueBarColorByValue = getValueBarColorByValue;
|
package/index.esm.js
CHANGED
|
@@ -3797,6 +3797,28 @@ const WidgetBody = ({ density = "auto", children, dataTestId, className, disable
|
|
|
3797
3797
|
return (jsx("div", { className: cvaWidgetBodyDensityContainer({ density, disableGap, className }), "data-testid": dataTestId, children: children }));
|
|
3798
3798
|
};
|
|
3799
3799
|
|
|
3800
|
+
const cvaZStackContainer = cvaMerge(["grid", "grid-cols-1", "grid-rows-1"]);
|
|
3801
|
+
const cvaZStackItem = cvaMerge(["col-start-1", "col-end-1", "row-start-1", "row-end-2"]);
|
|
3802
|
+
|
|
3803
|
+
/**
|
|
3804
|
+
* ZStack is a component that stacks its children on the z-axis.
|
|
3805
|
+
* Is a good alternative to "position: absolute" that avoids some of the unfortunate side effects of absolute positioning.
|
|
3806
|
+
*
|
|
3807
|
+
* @param { ZStackProps} props - The props for the ZStack component
|
|
3808
|
+
* @returns {JSX.Element} ZStack component
|
|
3809
|
+
*/
|
|
3810
|
+
const ZStack = ({ children, className, dataTestId }) => {
|
|
3811
|
+
return (jsx("div", { className: cvaZStackContainer({ className }), "data-testid": dataTestId, children: Children.map(children, (child, index) => {
|
|
3812
|
+
if (!isValidElement(child)) {
|
|
3813
|
+
return child;
|
|
3814
|
+
}
|
|
3815
|
+
return cloneElement(child, {
|
|
3816
|
+
className: cvaZStackItem({ className: child.props.className }),
|
|
3817
|
+
key: index,
|
|
3818
|
+
});
|
|
3819
|
+
}) }));
|
|
3820
|
+
};
|
|
3821
|
+
|
|
3800
3822
|
const cvaClickable = cvaMerge([
|
|
3801
3823
|
"shadow-lg",
|
|
3802
3824
|
"rounded-lg",
|
|
@@ -3821,4 +3843,4 @@ const cvaClickable = cvaMerge([
|
|
|
3821
3843
|
},
|
|
3822
3844
|
});
|
|
3823
3845
|
|
|
3824
|
-
export { ActionRenderer, Alert, Badge, Breadcrumb, BreadcrumbContainer, Button, Card, CardBody, CardFooter, CardHeader, Collapse, CompletionStatusIndicator, CopyableText, EmptyState, EmptyValue, ExternalLink, Heading, Icon, IconButton, Indicator, KPICard, MenuDivider, MenuItem, MenuList, MoreMenu, Notice, PackageNameStoryComponent, Page, PageContent, PageHeader, PageHeaderKpiMetrics, PageHeaderSecondaryActions, PageHeaderTitle, Pagination, Polygon, Popover, PopoverContent, PopoverTitle, PopoverTrigger, Portal, Prompt, ROLE_CARD, SectionHeader, Sidebar, SkeletonLines, Spacer, Spinner, StarButton, Tab, TabContent, TabList, Tabs, Tag, Text, ToggleGroup, ToggleItem, Tooltip, ValueBar, VirtualizedList, WidgetBody, cvaButton, cvaButtonPrefixSuffix, cvaButtonSpinner, cvaButtonSpinnerContainer, cvaClickable, cvaIconButton, cvaIndicator, cvaIndicatorIcon, cvaIndicatorIconBackground, cvaIndicatorLabel, cvaIndicatorPing, cvaInteractableItem, cvaMenuItem, cvaMenuItemLabel, cvaMenuItemPrefix, cvaMenuItemStyle, cvaMenuItemSuffix, cvaPageHeader, cvaPageHeaderContainer, cvaPageHeaderHeading, docs, getDevicePixelRatio, getValueBarColorByValue, iconColorNames, iconPalette, useClickOutside, useContainerBreakpoints, useContinuousTimeout, useDebounce, useDevicePixelRatio, useElevatedState, useGeometry, useHover, useIsFirstRender, useIsFullscreen, useIsTextTruncated, useOverflowItems, usePopoverContext, usePrompt, useResize, useScrollDetection, useSelfUpdatingRef, useTimeout, useViewportBreakpoints, useWindowActivity };
|
|
3846
|
+
export { ActionRenderer, Alert, Badge, Breadcrumb, BreadcrumbContainer, Button, Card, CardBody, CardFooter, CardHeader, Collapse, CompletionStatusIndicator, CopyableText, EmptyState, EmptyValue, ExternalLink, Heading, Icon, IconButton, Indicator, KPICard, MenuDivider, MenuItem, MenuList, MoreMenu, Notice, PackageNameStoryComponent, Page, PageContent, PageHeader, PageHeaderKpiMetrics, PageHeaderSecondaryActions, PageHeaderTitle, Pagination, Polygon, Popover, PopoverContent, PopoverTitle, PopoverTrigger, Portal, Prompt, ROLE_CARD, SectionHeader, Sidebar, SkeletonLines, Spacer, Spinner, StarButton, Tab, TabContent, TabList, Tabs, Tag, Text, ToggleGroup, ToggleItem, Tooltip, ValueBar, VirtualizedList, WidgetBody, ZStack, cvaButton, cvaButtonPrefixSuffix, cvaButtonSpinner, cvaButtonSpinnerContainer, cvaClickable, cvaContainerStyles, cvaIconButton, cvaImgStyles, cvaIndicator, cvaIndicatorIcon, cvaIndicatorIconBackground, cvaIndicatorLabel, cvaIndicatorPing, cvaInteractableItem, cvaMenuItem, cvaMenuItemLabel, cvaMenuItemPrefix, cvaMenuItemStyle, cvaMenuItemSuffix, cvaPageHeader, cvaPageHeaderContainer, cvaPageHeaderHeading, cvaToggleGroup, cvaToggleItem, cvaToggleItemText, cvaVirtualizedList, cvaVirtualizedListContainer, cvaVirtualizedListItem, cvaZStackContainer, cvaZStackItem, docs, getDevicePixelRatio, getValueBarColorByValue, iconColorNames, iconPalette, useClickOutside, useContainerBreakpoints, useContinuousTimeout, useDebounce, useDevicePixelRatio, useElevatedState, useGeometry, useHover, useIsFirstRender, useIsFullscreen, useIsTextTruncated, useOverflowItems, usePopoverContext, usePrompt, useResize, useScrollDetection, useSelfUpdatingRef, useTimeout, useViewportBreakpoints, useWindowActivity };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@trackunit/react-components",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.28",
|
|
4
4
|
"repository": "https://github.com/Trackunit/manager",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
6
6
|
"engines": {
|
|
@@ -19,11 +19,11 @@
|
|
|
19
19
|
"@tanstack/react-router": "1.47.1",
|
|
20
20
|
"string-ts": "^2.0.0",
|
|
21
21
|
"tailwind-merge": "^2.0.0",
|
|
22
|
-
"@trackunit/ui-design-tokens": "1.0.
|
|
23
|
-
"@trackunit/css-class-variance-utilities": "1.0.
|
|
24
|
-
"@trackunit/shared-utils": "1.2.
|
|
25
|
-
"@trackunit/ui-icons": "1.0.
|
|
26
|
-
"@trackunit/react-table-pagination": "1.0.
|
|
22
|
+
"@trackunit/ui-design-tokens": "1.0.23",
|
|
23
|
+
"@trackunit/css-class-variance-utilities": "1.0.22",
|
|
24
|
+
"@trackunit/shared-utils": "1.2.19",
|
|
25
|
+
"@trackunit/ui-icons": "1.0.25",
|
|
26
|
+
"@trackunit/react-table-pagination": "1.0.23"
|
|
27
27
|
},
|
|
28
28
|
"module": "./index.esm.js",
|
|
29
29
|
"main": "./index.cjs.js",
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { ReactNode } from "react";
|
|
2
|
+
import { CommonProps } from "../../common/CommonProps";
|
|
3
|
+
export type ZStackProps = CommonProps & {
|
|
4
|
+
children: ReactNode;
|
|
5
|
+
};
|
|
6
|
+
/**
|
|
7
|
+
* ZStack is a component that stacks its children on the z-axis.
|
|
8
|
+
* Is a good alternative to "position: absolute" that avoids some of the unfortunate side effects of absolute positioning.
|
|
9
|
+
*
|
|
10
|
+
* @param { ZStackProps} props - The props for the ZStack component
|
|
11
|
+
* @returns {JSX.Element} ZStack component
|
|
12
|
+
*/
|
|
13
|
+
export declare const ZStack: ({ children, className, dataTestId }: ZStackProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -7,6 +7,7 @@ export * from "./Collapse";
|
|
|
7
7
|
export * from "./CompletionStatusIndicator/CompletionStatusIndicator";
|
|
8
8
|
export * from "./CopyableText";
|
|
9
9
|
export * from "./EmptyState/EmptyState";
|
|
10
|
+
export * from "./EmptyState/EmptyState.variants";
|
|
10
11
|
export * from "./EmptyValue/EmptyValue";
|
|
11
12
|
export * from "./ExternalLink/ExternalLink";
|
|
12
13
|
export * from "./Heading";
|
|
@@ -36,7 +37,11 @@ export * from "./Tabs/Tabs";
|
|
|
36
37
|
export * from "./Tag";
|
|
37
38
|
export * from "./Text";
|
|
38
39
|
export * from "./ToggleGroup/ToggleGroup";
|
|
40
|
+
export * from "./ToggleGroup/ToggleGroup.variants";
|
|
39
41
|
export * from "./Tooltip";
|
|
40
42
|
export * from "./ValueBar";
|
|
41
43
|
export * from "./VirtualizedList/VirtualizedList";
|
|
44
|
+
export * from "./VirtualizedList/VirtualizedList.variants";
|
|
42
45
|
export * from "./Widget";
|
|
46
|
+
export * from "./ZStack/ZStack";
|
|
47
|
+
export * from "./ZStack/ZStack.variants";
|