@trackunit/react-components 1.22.3 → 1.22.5

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.
Files changed (74) hide show
  1. package/index.cjs.js +166 -132
  2. package/index.esm.js +167 -133
  3. package/package.json +1 -1
  4. package/src/common/Styleable.d.ts +5 -1
  5. package/src/components/Alert/Alert.d.ts +3 -2
  6. package/src/components/Badge/Badge.d.ts +3 -2
  7. package/src/components/Breadcrumb/Breadcrumb.d.ts +1 -1
  8. package/src/components/Breadcrumb/BreadcrumbForLargeScreen.d.ts +1 -1
  9. package/src/components/Breadcrumb/BreadcrumbForMediumScreen.d.ts +1 -1
  10. package/src/components/Breadcrumb/BreadcrumbForSmallScreen.d.ts +1 -1
  11. package/src/components/Breadcrumb/BreadcrumbItem.d.ts +1 -1
  12. package/src/components/Breadcrumb/utils/types.d.ts +4 -3
  13. package/src/components/Card/Card.d.ts +2 -1
  14. package/src/components/Card/CardBody.d.ts +3 -2
  15. package/src/components/Card/CardFooter.d.ts +3 -2
  16. package/src/components/Card/CardHeader.d.ts +3 -2
  17. package/src/components/Collapse/Collapse.d.ts +3 -2
  18. package/src/components/CompletionStatusIndicator/CompletionStatusIndicator.d.ts +2 -1
  19. package/src/components/CopyableText/CopyableText.d.ts +3 -2
  20. package/src/components/DetailsList/DetailsList.d.ts +4 -3
  21. package/src/components/EmptyState/EmptyState.d.ts +3 -2
  22. package/src/components/EmptyValue/EmptyValue.d.ts +3 -2
  23. package/src/components/ExternalLink/ExternalLink.d.ts +3 -2
  24. package/src/components/GridAreas/GridAreas.d.ts +3 -2
  25. package/src/components/Heading/Heading.d.ts +2 -1
  26. package/src/components/Highlight/Highlight.d.ts +3 -2
  27. package/src/components/HorizontalOverflowScroller/HorizontalOverflowScroller.d.ts +2 -2
  28. package/src/components/HorizontalOverflowScroller/OverflowIndicator.d.ts +3 -2
  29. package/src/components/Icon/Icon.d.ts +3 -8
  30. package/src/components/Indicator/Indicator.d.ts +2 -1
  31. package/src/components/KPI/KPI.d.ts +1 -1
  32. package/src/components/KPI/KPISkeleton.d.ts +1 -1
  33. package/src/components/KPICard/KPICardSkeleton.d.ts +1 -1
  34. package/src/components/KPICard/components/TrendIndicator/TrendIndicator.d.ts +3 -2
  35. package/src/components/KPICard/components/TrendIndicators.d.ts +3 -2
  36. package/src/components/List/List.d.ts +3 -2
  37. package/src/components/List/ListLoadingIndicator.d.ts +3 -2
  38. package/src/components/List/useList.d.ts +2 -1
  39. package/src/components/ListItem/ListItem.d.ts +2 -1
  40. package/src/components/ListItem/ListItemSkeleton.d.ts +4 -2
  41. package/src/components/Menu/MenuDivider/MenuDivider.d.ts +3 -1
  42. package/src/components/Menu/MenuItem/MenuItem.d.ts +3 -2
  43. package/src/components/Menu/MenuList/MenuList.d.ts +3 -2
  44. package/src/components/Menu/MoreMenu/MoreMenu.d.ts +3 -2
  45. package/src/components/Notice/Notice.d.ts +2 -1
  46. package/src/components/Page/Page.d.ts +3 -2
  47. package/src/components/Page/PageContent.d.ts +3 -2
  48. package/src/components/PageHeader/PageHeader.d.ts +1 -1
  49. package/src/components/PageHeader/components/PageHeaderKpiMetrics.d.ts +7 -2
  50. package/src/components/PageHeader/components/PageHeaderTitle.d.ts +4 -2
  51. package/src/components/PageHeader/types.d.ts +3 -2
  52. package/src/components/Pagination/Pagination.d.ts +4 -10
  53. package/src/components/Polygon/Polygon.d.ts +3 -2
  54. package/src/components/Popover/PopoverTitle.d.ts +3 -2
  55. package/src/components/PreferenceCard/PreferenceCard.d.ts +3 -2
  56. package/src/components/PreferenceCard/PreferenceCardSkeleton.d.ts +4 -2
  57. package/src/components/SectionHeader/SectionHeader.d.ts +3 -2
  58. package/src/components/Sheet/Sheet.d.ts +1 -1
  59. package/src/components/Sheet/sheet-types.d.ts +2 -1
  60. package/src/components/Sidebar/Sidebar.d.ts +4 -3
  61. package/src/components/Skeleton/SkeletonBlock/SkeletonBlock.d.ts +2 -1
  62. package/src/components/Skeleton/SkeletonLabel/SkeletonLabel.d.ts +2 -1
  63. package/src/components/SkeletonLines/SkeletonLines.d.ts +4 -3
  64. package/src/components/Spacer/Spacer.d.ts +3 -2
  65. package/src/components/Spinner/Spinner.d.ts +3 -2
  66. package/src/components/Tag/Tag.d.ts +3 -2
  67. package/src/components/Text/Text.d.ts +2 -1
  68. package/src/components/ToggleGroup/ToggleGroup.d.ts +5 -4
  69. package/src/components/Tooltip/Tooltip.d.ts +1 -1
  70. package/src/components/ValueBar/SegmentedValueBar.d.ts +3 -2
  71. package/src/components/ValueBar/ValueBar.d.ts +3 -2
  72. package/src/components/ZStack/ZStack.d.ts +3 -2
  73. package/src/components/buttons/shared/ButtonProps.d.ts +2 -1
  74. package/src/index.d.ts +1 -1
@@ -1,4 +1,6 @@
1
1
  import { ReactElement } from "react";
2
+ import type { Styleable } from "../../../common/Styleable";
3
+ export type MenuDividerProps = Styleable;
2
4
  /**
3
5
  * MenuDivider renders a horizontal line to visually separate groups of items within a MenuList.
4
6
  *
@@ -23,4 +25,4 @@ import { ReactElement } from "react";
23
25
  * ```
24
26
  * @returns {ReactElement} MenuDivider component
25
27
  */
26
- export declare const MenuDivider: () => ReactElement;
28
+ export declare const MenuDivider: ({ style }: MenuDividerProps) => ReactElement;
@@ -1,10 +1,11 @@
1
1
  import { VariantProps } from "@trackunit/css-class-variance-utilities";
2
2
  import { MouseEventHandler, ReactElement, ReactNode } from "react";
3
3
  import { CommonProps } from "../../../common/CommonProps";
4
+ import type { Styleable } from "../../../common/Styleable";
4
5
  import { Refable } from "../../../common/Refable";
5
6
  import { cvaMenuItemStyle } from "./MenuItem.variants";
6
7
  export type MenuItemVariant = "primary" | "danger";
7
- export interface MenuItemProps extends CommonProps, Refable<HTMLDivElement> {
8
+ export interface MenuItemProps extends CommonProps, Styleable, Refable<HTMLDivElement> {
8
9
  /**
9
10
  * The unique id for the menu item
10
11
  */
@@ -120,4 +121,4 @@ export interface MenuItemProps extends CommonProps, Refable<HTMLDivElement> {
120
121
  * @param {MenuItemProps} props - The props for the MenuItem component
121
122
  * @returns {ReactElement} MenuItem component
122
123
  */
123
- export declare const MenuItem: ({ className, "data-testid": dataTestId, label, children, selected, focused, prefix, suffix, disabled, onClick, stopPropagation, id, tabIndex, optionLabelDescription, optionPrefix, fieldSize, variant, ref, }: MenuItemProps) => ReactElement;
124
+ export declare const MenuItem: ({ className, "data-testid": dataTestId, label, children, selected, focused, prefix, suffix, disabled, onClick, stopPropagation, id, tabIndex, optionLabelDescription, optionPrefix, fieldSize, variant, style, ref, }: MenuItemProps) => ReactElement;
@@ -1,7 +1,8 @@
1
1
  import { MouseEventHandler, ReactElement, ReactNode } from "react";
2
2
  import { CommonProps } from "../../../common/CommonProps";
3
+ import type { Styleable } from "../../../common/Styleable";
3
4
  import { Refable } from "../../../common/Refable";
4
- export interface MenuListProps extends CommonProps, Refable<HTMLDivElement> {
5
+ export interface MenuListProps extends CommonProps, Styleable, Refable<HTMLDivElement> {
5
6
  /**
6
7
  * List of menu items to be rendered.
7
8
  */
@@ -79,4 +80,4 @@ export interface MenuListProps extends CommonProps, Refable<HTMLDivElement> {
79
80
  * @param {MenuListProps} props - The props for the MenuList component
80
81
  * @returns {ReactElement} MenuList component
81
82
  */
82
- export declare const MenuList: ({ "data-testid": dataTestId, className, children, isMulti, selectedItems: controlledSelectedItems, onSelectionChange, ref, ...args }: MenuListProps) => ReactElement;
83
+ export declare const MenuList: ({ "data-testid": dataTestId, className, children, isMulti, selectedItems: controlledSelectedItems, onSelectionChange, style, ref, ...args }: MenuListProps) => ReactElement;
@@ -1,6 +1,7 @@
1
1
  import { MakePropertyOptional, MappedOmit } from "@trackunit/shared-utils";
2
2
  import { ReactElement, ReactNode } from "react";
3
3
  import { CommonProps } from "../../../common/CommonProps";
4
+ import type { Styleable } from "../../../common/Styleable";
4
5
  import { Refable } from "../../../common/Refable";
5
6
  import { IconProps } from "../../Icon/Icon";
6
7
  import { PopoverContentChildren } from "../../Popover/PopoverContent";
@@ -9,7 +10,7 @@ import { IconButtonProps } from "../../buttons/IconButton/IconButton";
9
10
  export type MenuPlacement = "above" | "below";
10
11
  type FilteredIconProps = MakePropertyOptional<MappedOmit<IconProps, "onClick">, "name">;
11
12
  type FilteredIconButtonProps = Omit<IconButtonProps, "icon" | "onClick">;
12
- export interface MoreMenuProps extends CommonProps, Refable<HTMLDivElement> {
13
+ export interface MoreMenuProps extends CommonProps, Styleable, Refable<HTMLDivElement> {
13
14
  /**
14
15
  * Content to render inside the popover. Receives a `close` callback as a render prop, or accepts static ReactNode children.
15
16
  */
@@ -78,5 +79,5 @@ export interface MoreMenuProps extends CommonProps, Refable<HTMLDivElement> {
78
79
  * @param {MoreMenuProps} props - The props for the MoreMenu component
79
80
  * @returns {ReactElement} MoreMenu component
80
81
  */
81
- export declare const MoreMenu: ({ className, "data-testid": dataTestId, popoverProps, iconProps, iconButtonProps, customButton, customPortalId, children, ref, }: MoreMenuProps) => ReactElement;
82
+ export declare const MoreMenu: ({ className, "data-testid": dataTestId, popoverProps, iconProps, iconButtonProps, customButton, customPortalId, children, style, ref, }: MoreMenuProps) => ReactElement;
82
83
  export {};
@@ -2,9 +2,10 @@ import { GeneralColors, IntentColors } from "@trackunit/ui-design-tokens";
2
2
  import { IconName } from "@trackunit/ui-icons";
3
3
  import { ReactElement } from "react";
4
4
  import { CommonProps } from "../../common/CommonProps";
5
+ import type { Styleable } from "../../common/Styleable";
5
6
  import { Refable } from "../../common/Refable";
6
7
  import { Size } from "../../common/Size";
7
- export interface NoticeProps extends CommonProps, Refable<HTMLDivElement> {
8
+ export interface NoticeProps extends CommonProps, Styleable, Refable<HTMLDivElement> {
8
9
  /**
9
10
  * The name of the icon
10
11
  */
@@ -1,6 +1,7 @@
1
1
  import { VariantProps } from "@trackunit/css-class-variance-utilities";
2
2
  import { ReactElement, ReactNode } from "react";
3
3
  import { CommonProps } from "../../common/CommonProps";
4
+ import type { Styleable } from "../../common/Styleable";
4
5
  import { Refable } from "../../common/Refable";
5
6
  import { cvaPage } from "./Page.variants";
6
7
  /**
@@ -10,7 +11,7 @@ export type Layout = VariantProps<typeof cvaPage>["layout"];
10
11
  /**
11
12
  * The props for the Page component.
12
13
  */
13
- export interface PageProps extends CommonProps, Refable<HTMLDivElement> {
14
+ export interface PageProps extends CommonProps, Styleable, Refable<HTMLDivElement> {
14
15
  /**
15
16
  * The layout mode of the page. Controls how content is arranged within the page container.
16
17
  */
@@ -54,4 +55,4 @@ export interface PageProps extends CommonProps, Refable<HTMLDivElement> {
54
55
  * @param {PageProps} props - The props for the Page component
55
56
  * @returns {ReactElement} Page component
56
57
  */
57
- export declare const Page: ({ layout, className, children, "data-testid": dataTestId, ref }: PageProps) => ReactElement;
58
+ export declare const Page: ({ layout, className, children, "data-testid": dataTestId, style, ref, }: PageProps) => ReactElement;
@@ -1,6 +1,7 @@
1
1
  import { VariantProps } from "@trackunit/css-class-variance-utilities";
2
2
  import { ReactElement, ReactNode } from "react";
3
3
  import { CommonProps } from "../../common/CommonProps";
4
+ import type { Styleable } from "../../common/Styleable";
4
5
  import { Refable } from "../../common/Refable";
5
6
  import { cvaPageContent } from "./Page.variants";
6
7
  /**
@@ -10,7 +11,7 @@ export type PageContentLayout = VariantProps<typeof cvaPageContent>["layout"];
10
11
  /**
11
12
  * The props for the PageContent component.
12
13
  */
13
- interface PageContentProps extends CommonProps, Refable<HTMLDivElement> {
14
+ interface PageContentProps extends CommonProps, Styleable, Refable<HTMLDivElement> {
14
15
  /**
15
16
  * The layout mode for the page content area. Controls content arrangement and spacing.
16
17
  */
@@ -50,5 +51,5 @@ interface PageContentProps extends CommonProps, Refable<HTMLDivElement> {
50
51
  * @param {PageContentProps} props - The props for the PageContent component
51
52
  * @returns {ReactElement} PageContent component
52
53
  */
53
- export declare const PageContent: ({ className, children, "data-testid": dataTestId, layout, ref, }: PageContentProps) => ReactElement;
54
+ export declare const PageContent: ({ className, children, "data-testid": dataTestId, layout, style, ref, }: PageContentProps) => ReactElement;
54
55
  export {};
@@ -53,4 +53,4 @@ import { PageHeaderProps } from "./types";
53
53
  * @param {PageHeaderProps} props - The props for the PageHeader component
54
54
  * @returns {ReactElement} PageHeader component
55
55
  */
56
- export declare const PageHeader: ({ className, "data-testid": dataTestId, showLoading, description, title, tagLabel, backTo, tagColor, tabsList, descriptionIcon, tagTooltipLabel, ref, ...discriminatedProps }: PageHeaderProps) => ReactElement;
56
+ export declare const PageHeader: ({ className, "data-testid": dataTestId, showLoading, description, title, tagLabel, backTo, tagColor, tabsList, descriptionIcon, tagTooltipLabel, style, ref, ...discriminatedProps }: PageHeaderProps) => ReactElement;
@@ -1,14 +1,19 @@
1
1
  import { ReactElement } from "react";
2
+ import { CommonProps } from "../../../common/CommonProps";
2
3
  import { Refable } from "../../../common/Refable";
4
+ import type { Styleable } from "../../../common/Styleable";
3
5
  import { PageHeaderKpiMetricsType } from "../types";
4
6
  /**
5
7
  * Renders KPI metrics in the PageHeader component.
6
8
  *
7
9
  * @param {object} props - The props for the PageHeaderKpiMetrics component
8
10
  * @param {Array<PageHeaderKpiMetricsType>} props.kpiMetrics - The KPI metrics to render
11
+ * @param {string} [props.className] - Additional class names for the metrics row
12
+ * @param {string} [props."data-testid"] - Test id for the metrics row
13
+ * @param {import("react").CSSProperties} [props.style] - Inline styles for the metrics row
9
14
  * @param [props.ref] - Ref forwarded to the root element
10
15
  * @returns {ReactElement} PageHeaderKpiMetrics component
11
16
  */
12
- export declare const PageHeaderKpiMetrics: ({ kpiMetrics, ref, }: {
17
+ export declare const PageHeaderKpiMetrics: ({ kpiMetrics, className, "data-testid": dataTestId, style, ref, }: {
13
18
  kpiMetrics: Array<PageHeaderKpiMetricsType>;
14
- } & Refable<HTMLDivElement>) => ReactElement;
19
+ } & CommonProps & Styleable & Refable<HTMLDivElement>) => ReactElement;
@@ -1,7 +1,8 @@
1
1
  import { ReactElement } from "react";
2
2
  import { CommonProps } from "../../../common/CommonProps";
3
3
  import { Refable } from "../../../common/Refable";
4
- interface PageHeaderTitleProps extends CommonProps, Refable<HTMLDivElement> {
4
+ import type { Styleable } from "../../../common/Styleable";
5
+ interface PageHeaderTitleProps extends CommonProps, Styleable, Refable<HTMLDivElement> {
5
6
  /**
6
7
  * The title of the page header
7
8
  */
@@ -14,8 +15,9 @@ interface PageHeaderTitleProps extends CommonProps, Refable<HTMLDivElement> {
14
15
  * @param {string} props.title - The title of the page header
15
16
  * @param {string} props.className - The class name of the page header title
16
17
  * @param {string} [props."data-testid"] - The data test id of the page header title
18
+ * @param {import("react").CSSProperties} [props.style] - Inline styles for the title wrapper
17
19
  * @param [props.ref] - Ref forwarded to the root element
18
20
  * @returns {ReactElement} PageHeaderTitle component
19
21
  */
20
- export declare const PageHeaderTitle: ({ title, "data-testid": dataTestId, className, ref: forwardedRef, }: PageHeaderTitleProps) => ReactElement;
22
+ export declare const PageHeaderTitle: ({ title, "data-testid": dataTestId, className, style, ref: forwardedRef, }: PageHeaderTitleProps) => ReactElement;
21
23
  export {};
@@ -2,6 +2,7 @@ import { IconName } from "@trackunit/ui-icons";
2
2
  import { MouseEvent, ReactElement, ReactNode } from "react";
3
3
  import { CommonProps } from "../../common/CommonProps";
4
4
  import { Refable } from "../../common/Refable";
5
+ import type { Styleable } from "../../common/Styleable";
5
6
  import { ButtonVariant } from "../buttons/shared/ButtonProps";
6
7
  import { TabListProps } from "../Tabs/TabList";
7
8
  import { TagColors } from "../Tag/Tag";
@@ -12,7 +13,7 @@ export type PageHeaderKpiMetricsType = {
12
13
  loading?: boolean;
13
14
  hidden?: boolean;
14
15
  };
15
- export type PageHeaderActionType = CommonProps & {
16
+ export type PageHeaderActionType = CommonProps & Styleable & {
16
17
  actionCallback?: (e?: MouseEvent) => void;
17
18
  actionText: string;
18
19
  prefixIconName?: IconName;
@@ -29,7 +30,7 @@ export type PageHeaderSecondaryActionType = PageHeaderActionType & {
29
30
  export type PageHeaderPrimaryActionType = PageHeaderActionType & {
30
31
  variant: Extract<ButtonVariant, "primary" | "primary-danger" | "secondary">;
31
32
  };
32
- interface BasePageHeaderProps extends CommonProps, Refable<HTMLDivElement> {
33
+ interface BasePageHeaderProps extends CommonProps, Styleable, Refable<HTMLDivElement> {
33
34
  /**
34
35
  * Main title of the page.
35
36
  */
@@ -1,6 +1,8 @@
1
1
  import { ReactElement } from "react";
2
+ import { CommonProps } from "../../common/CommonProps";
3
+ import type { Styleable } from "../../common/Styleable";
2
4
  import { Refable } from "../../common/Refable";
3
- export interface PaginationProps extends Refable<HTMLDivElement> {
5
+ export interface PaginationProps extends CommonProps, Styleable, Refable<HTMLDivElement> {
4
6
  /**
5
7
  * A go to previous page handler
6
8
  */
@@ -29,14 +31,6 @@ export interface PaginationProps extends Refable<HTMLDivElement> {
29
31
  * A flag indicating loading state
30
32
  */
31
33
  loading?: boolean;
32
- /**
33
- * A custom class to override styles
34
- */
35
- className?: string;
36
- /**
37
- * A data test id
38
- */
39
- "data-testid"?: string;
40
34
  /**
41
35
  * An helper to get translation for count.
42
36
  */
@@ -89,4 +83,4 @@ export interface PaginationProps extends Refable<HTMLDivElement> {
89
83
  * @param {PaginationProps} props - The props for the Pagination component
90
84
  * @returns {ReactElement} Pagination component
91
85
  */
92
- export declare const Pagination: ({ previousPage, nextPage, canPreviousPage, canNextPage, pageCount, pageIndex, loading, className, "data-testid": dataTestId, getTranslatedCount, onPageChange, cursorBase, ref, }: PaginationProps) => ReactElement;
86
+ export declare const Pagination: ({ previousPage, nextPage, canPreviousPage, canNextPage, pageCount, pageIndex, loading, className, "data-testid": dataTestId, style, getTranslatedCount, onPageChange, cursorBase, ref, }: PaginationProps) => ReactElement;
@@ -1,8 +1,9 @@
1
1
  import { ReactElement } from "react";
2
2
  import { CommonProps } from "../../common/CommonProps";
3
3
  import { Refable } from "../../common/Refable";
4
+ import { type Styleable } from "../../common/Styleable";
4
5
  type Point = [number, number];
5
- export interface PolygonProps extends CommonProps, Refable<SVGSVGElement> {
6
+ export interface PolygonProps extends CommonProps, Styleable, Refable<SVGSVGElement> {
6
7
  /**
7
8
  * Array of [x, y] coordinate pairs defining the polygon's vertices. Points are normalized to fit within the given size.
8
9
  */
@@ -49,5 +50,5 @@ export interface PolygonProps extends CommonProps, Refable<SVGSVGElement> {
49
50
  * @param {PolygonProps} props - The props for the Polygon component
50
51
  * @returns {ReactElement} Polygon component
51
52
  */
52
- export declare const Polygon: ({ points, size, color, opaque, className, "data-testid": dataTestId, ref, }: PolygonProps) => ReactElement;
53
+ export declare const Polygon: ({ points, size, color, opaque, className, "data-testid": dataTestId, style, ref, }: PolygonProps) => ReactElement;
53
54
  export {};
@@ -1,7 +1,8 @@
1
1
  import { ReactElement, ReactNode } from "react";
2
2
  import { CommonProps } from "../../common/CommonProps";
3
3
  import { Refable } from "../../common/Refable";
4
- export interface PopoverTitleProps extends CommonProps, Refable<HTMLDivElement> {
4
+ import type { Styleable } from "../../common/Styleable";
5
+ export interface PopoverTitleProps extends CommonProps, Styleable, Refable<HTMLDivElement> {
5
6
  /**
6
7
  * An optional action element (e.g., a close button or link) rendered to the right of the title.
7
8
  */
@@ -52,4 +53,4 @@ export interface PopoverTitleProps extends CommonProps, Refable<HTMLDivElement>
52
53
  * @param {PopoverTitleProps} props - The props for the PopoverTitle component
53
54
  * @returns {ReactElement} PopoverTitle component
54
55
  */
55
- export declare const PopoverTitle: ({ children, action, divider, className, "data-testid": dataTestId, ref, }: PopoverTitleProps) => ReactElement;
56
+ export declare const PopoverTitle: ({ children, action, divider, className, "data-testid": dataTestId, style, ref, }: PopoverTitleProps) => ReactElement;
@@ -4,6 +4,7 @@ import { IconName } from "@trackunit/ui-icons";
4
4
  import { ReactElement, ReactNode } from "react";
5
5
  import { CommonProps } from "../../common/CommonProps";
6
6
  import { Refable } from "../../common/Refable";
7
+ import type { Styleable } from "../../common/Styleable";
7
8
  import { TagProps } from "../Tag/Tag";
8
9
  import { cvaPreferenceCard } from "./PreferenceCard.variants";
9
10
  /**
@@ -22,7 +23,7 @@ type ImageDetails = {
22
23
  alt: string;
23
24
  containerClassName?: string;
24
25
  };
25
- export interface PreferenceCardProps extends CommonProps, Refable<HTMLDivElement>, MappedOmit<VariantProps<typeof cvaPreferenceCard>, "className"> {
26
+ export interface PreferenceCardProps extends CommonProps, Styleable, Refable<HTMLDivElement>, MappedOmit<VariantProps<typeof cvaPreferenceCard>, "className"> {
26
27
  /**
27
28
  * The title of the preference card
28
29
  */
@@ -89,5 +90,5 @@ export interface PreferenceCardProps extends CommonProps, Refable<HTMLDivElement
89
90
  * @param {PreferenceCardProps} props - The props for the PreferenceCard component
90
91
  * @returns {ReactNode} PreferenceCard component
91
92
  */
92
- export declare const PreferenceCard: ({ title, description, icon, input, titleTag, cardTag, disabled, className, "data-testid": dataTestId, children, ref: forwardedRef, }: PreferenceCardProps) => ReactNode;
93
+ export declare const PreferenceCard: ({ title, description, icon, input, titleTag, cardTag, disabled, className, "data-testid": dataTestId, style, children, ref: forwardedRef, }: PreferenceCardProps) => ReactNode;
93
94
  export {};
@@ -1,4 +1,6 @@
1
1
  import { ReactElement } from "react";
2
+ import { CommonProps } from "../../common/CommonProps";
3
+ import type { Styleable } from "../../common/Styleable";
2
4
  import { Refable } from "../../common/Refable";
3
5
  /**
4
6
  * Default property values for PreferenceCardSkeleton component.
@@ -9,7 +11,7 @@ export declare const DEFAULT_SKELETON_PREFERENCE_CARD_PROPS: {
9
11
  readonly hasCardTag: false;
10
12
  readonly hasInput: false;
11
13
  };
12
- export interface PreferenceCardSkeletonProps extends Refable<HTMLDivElement> {
14
+ export interface PreferenceCardSkeletonProps extends CommonProps, Styleable, Refable<HTMLDivElement> {
13
15
  /** Whether to show an icon skeleton */
14
16
  hasIcon?: boolean;
15
17
  /** Whether to show a title tag skeleton (inline with title) */
@@ -44,4 +46,4 @@ export interface PreferenceCardSkeletonProps extends Refable<HTMLDivElement> {
44
46
  * @param {PreferenceCardSkeletonProps} props - The props for the PreferenceCardSkeleton component
45
47
  * @returns {ReactElement} PreferenceCardSkeleton component
46
48
  */
47
- export declare const PreferenceCardSkeleton: ({ hasIcon, hasTitleTag, hasCardTag, hasInput, ref, }: PreferenceCardSkeletonProps) => ReactElement;
49
+ export declare const PreferenceCardSkeleton: ({ hasIcon, hasTitleTag, hasCardTag, hasInput, className, "data-testid": dataTestId, style, ref, }: PreferenceCardSkeletonProps) => ReactElement;
@@ -1,7 +1,8 @@
1
1
  import { ReactElement, ReactNode } from "react";
2
2
  import { CommonProps } from "../../common/CommonProps";
3
+ import type { Styleable } from "../../common/Styleable";
3
4
  import { Refable } from "../../common/Refable";
4
- export interface SectionHeaderProps extends CommonProps, Refable<HTMLDivElement> {
5
+ export interface SectionHeaderProps extends CommonProps, Styleable, Refable<HTMLDivElement> {
5
6
  /**
6
7
  * The title of the section.
7
8
  */
@@ -41,4 +42,4 @@ export interface SectionHeaderProps extends CommonProps, Refable<HTMLDivElement>
41
42
  * @param {SectionHeaderProps} props - The props for the SectionHeader component
42
43
  * @returns {ReactElement} SectionHeader component
43
44
  */
44
- export declare const SectionHeader: ({ title, subtitle, "data-testid": dataTestId, addons, ref, }: SectionHeaderProps) => ReactElement;
45
+ export declare const SectionHeader: ({ title, subtitle, "data-testid": dataTestId, addons, style, ref, }: SectionHeaderProps) => ReactElement;
@@ -26,4 +26,4 @@ import type { SheetProps } from "./sheet-types";
26
26
  * CSS transitions on transform; the component stays mounted during the
27
27
  * close animation and unmounts after the transition completes.
28
28
  */
29
- export declare const Sheet: ({ isOpen, state, snap, onGeometryChange, onSnap, onClickHandle, onCloseGesture, floatingUi, ref, anchor, snapping, resizable, variant, trapFocus, container, dockedContent, persistentContent, className, "data-testid": dataTestId, onCloseComplete, entryAnimation, children, }: SheetProps) => ReactElement | null;
29
+ export declare const Sheet: ({ isOpen, state, snap, onGeometryChange, onSnap, onClickHandle, onCloseGesture, floatingUi, ref, anchor, snapping, resizable, variant, trapFocus, container, dockedContent, persistentContent, className, style, "data-testid": dataTestId, onCloseComplete, entryAnimation, children, }: SheetProps) => ReactElement | null;
@@ -1,5 +1,6 @@
1
1
  import type { UseFloatingReturn } from "@floating-ui/react";
2
2
  import type { ReactNode, Ref, RefObject } from "react";
3
+ import type { Styleable } from "../../common/Styleable";
3
4
  import type { UseOverlayDismissibleProps } from "../../overlay-dismissible/types";
4
5
  /**
5
6
  * Horizontal positioning of the bottom sheet.
@@ -145,7 +146,7 @@ export type UseSheetSnapReturn = {
145
146
  * actually reads. Consumers spread the hook return (`{...sheet}`) and
146
147
  * TypeScript allows extra properties on spread expressions.
147
148
  */
148
- export type SheetProps = {
149
+ export type SheetProps = Styleable & {
149
150
  readonly isOpen: boolean;
150
151
  /** Unified sheet state from useSheetSnap. */
151
152
  readonly state: SheetState;
@@ -1,9 +1,10 @@
1
1
  import { ComponentProps, MouseEventHandler, ReactElement } from "react";
2
2
  import { CommonProps } from "../../common/CommonProps";
3
+ import type { Styleable } from "../../common/Styleable";
3
4
  import { Refable } from "../../common/Refable";
4
5
  import { MenuList } from "../Menu/MenuList/MenuList";
5
6
  import { MoreMenu } from "../Menu/MoreMenu/MoreMenu";
6
- export interface SidebarItemProps extends CommonProps {
7
+ export interface SidebarItemProps extends CommonProps, Styleable {
7
8
  /**
8
9
  * The id prop is used to identify the sidebar item in the dom.
9
10
  * This is needed as it is used for the intersection observer to determine which items are visible and which are not.
@@ -13,7 +14,7 @@ export interface SidebarItemProps extends CommonProps {
13
14
  onClick?: MouseEventHandler<HTMLElement>;
14
15
  }
15
16
  export type Breakpoints = "xs" | "sm" | "md" | "lg" | "xl" | "2xl" | "3xl";
16
- export interface SidebarProps extends CommonProps, Refable<HTMLDivElement> {
17
+ export interface SidebarProps extends CommonProps, Styleable, Refable<HTMLDivElement> {
17
18
  /**
18
19
  * The breakpoint at which the menu will go from Horizontal to vertical stacked
19
20
  *
@@ -84,4 +85,4 @@ export interface SidebarProps extends CommonProps, Refable<HTMLDivElement> {
84
85
  * @param {SidebarProps} props - The props for the Sidebar component
85
86
  * @returns {ReactElement} Sidebar component
86
87
  */
87
- export declare const Sidebar: ({ childContainerClassName, children, breakpoint, className, "data-testid": dataTestId, moreMenuProps, menuListProps, overflowThreshold, ref, }: SidebarProps) => ReactElement;
88
+ export declare const Sidebar: ({ childContainerClassName, children, breakpoint, className, "data-testid": dataTestId, moreMenuProps, menuListProps, overflowThreshold, style, ref, }: SidebarProps) => ReactElement;
@@ -2,8 +2,9 @@ import { StringWithAutocompleteOptions } from "@trackunit/shared-utils";
2
2
  import { ReactNode } from "react";
3
3
  import { CommonProps } from "../../../common/CommonProps";
4
4
  import { Refable } from "../../../common/Refable";
5
+ import { type Styleable } from "../../../common/Styleable";
5
6
  import { CSSLength } from "../Skeleton.helpers";
6
- export type SkeletonBlockProps = CommonProps & Refable<HTMLDivElement> & {
7
+ export type SkeletonBlockProps = CommonProps & Styleable & Refable<HTMLDivElement> & {
7
8
  /**
8
9
  * The height of the skeleton.
9
10
  *
@@ -2,8 +2,9 @@ import { StringWithAutocompleteOptions } from "@trackunit/shared-utils";
2
2
  import { ReactNode } from "react";
3
3
  import { CommonProps } from "../../../common/CommonProps";
4
4
  import { Refable } from "../../../common/Refable";
5
+ import { type Styleable } from "../../../common/Styleable";
5
6
  import { CSSLength, TextSizeKey } from "../Skeleton.helpers";
6
- export type SkeletonLabelProps = CommonProps & Refable<HTMLDivElement> & {
7
+ export type SkeletonLabelProps = CommonProps & Styleable & Refable<HTMLDivElement> & {
7
8
  /**
8
9
  * The text size to match, using text size keys.
9
10
  *
@@ -1,6 +1,7 @@
1
1
  import { StringWithAutocompleteOptions } from "@trackunit/shared-utils";
2
2
  import { CommonProps } from "../../common/CommonProps";
3
3
  import { Refable } from "../../common/Refable";
4
+ import type { Styleable } from "../../common/Styleable";
4
5
  import { CSSLength, TextSizeKey } from "../Skeleton/Skeleton.helpers";
5
6
  /**
6
7
  * Preset configurations for common skeleton patterns.
@@ -51,7 +52,7 @@ export type SkeletonLineConfig = BaseSkeletonLineConfig & {
51
52
  *
52
53
  * Use this for displaying multiple identical skeleton lines.
53
54
  */
54
- export type UniformSkeletonLinesProps = CommonProps & Refable<HTMLDivElement> & BaseSkeletonLineConfig & {
55
+ export type UniformSkeletonLinesProps = CommonProps & Styleable & Refable<HTMLDivElement> & BaseSkeletonLineConfig & {
55
56
  /**
56
57
  * Visual variant: "uniform" (default)
57
58
  *
@@ -74,7 +75,7 @@ export type UniformSkeletonLinesProps = CommonProps & Refable<HTMLDivElement> &
74
75
  *
75
76
  * Use this for displaying skeleton lines with per-line configuration (varying widths, textSize (height), etc.).
76
77
  */
77
- type CustomSkeletonLinesProps = CommonProps & Refable<HTMLDivElement> & {
78
+ type CustomSkeletonLinesProps = CommonProps & Styleable & Refable<HTMLDivElement> & {
78
79
  /**
79
80
  * Visual variant: "custom"
80
81
  *
@@ -93,7 +94,7 @@ type CustomSkeletonLinesProps = CommonProps & Refable<HTMLDivElement> & {
93
94
  *
94
95
  * Use this for common skeleton patterns with predefined configurations.
95
96
  */
96
- type PresetSkeletonLinesProps = CommonProps & Refable<HTMLDivElement> & {
97
+ type PresetSkeletonLinesProps = CommonProps & Styleable & Refable<HTMLDivElement> & {
97
98
  /**
98
99
  * Visual variant: "preset"
99
100
  *
@@ -1,8 +1,9 @@
1
1
  import { ReactElement } from "react";
2
2
  import { CommonProps } from "../../common/CommonProps";
3
+ import type { Styleable } from "../../common/Styleable";
3
4
  import { Refable } from "../../common/Refable";
4
5
  import { Size } from "../../common/Size";
5
- export interface SpacerProps extends CommonProps, Refable<HTMLDivElement> {
6
+ export interface SpacerProps extends CommonProps, Styleable, Refable<HTMLDivElement> {
6
7
  /**
7
8
  * The minimum height of the spacer. Defaults to 1px.
8
9
  * Possible values are "normal"(8px), and "large" (32px).
@@ -37,4 +38,4 @@ export interface SpacerProps extends CommonProps, Refable<HTMLDivElement> {
37
38
  * @param {SpacerProps} props - The props for the Spacer component
38
39
  * @returns {ReactElement} Spacer component
39
40
  */
40
- export declare const Spacer: ({ size, border, "data-testid": dataTestId, className, ref, }: SpacerProps) => ReactElement;
41
+ export declare const Spacer: ({ size, border, "data-testid": dataTestId, className, style, ref, }: SpacerProps) => ReactElement;
@@ -1,9 +1,10 @@
1
1
  import { ReactElement } from "react";
2
2
  import { CommonProps } from "../../common/CommonProps";
3
+ import type { Styleable } from "../../common/Styleable";
3
4
  import { Refable } from "../../common/Refable";
4
5
  import { Size } from "../../common/Size";
5
6
  type Centering = "horizontally" | "vertically" | "centered";
6
- export interface SpinnerProps extends CommonProps, Refable<HTMLDivElement> {
7
+ export interface SpinnerProps extends CommonProps, Styleable, Refable<HTMLDivElement> {
7
8
  /**
8
9
  * Defines the size of the spinner.
9
10
  */
@@ -62,5 +63,5 @@ export interface SpinnerProps extends CommonProps, Refable<HTMLDivElement> {
62
63
  * @param {SpinnerProps} props - The props for the Spinner component
63
64
  * @returns {ReactElement} Spinner component
64
65
  */
65
- export declare const Spinner: ({ mode, size, centering, className, containerClassName, "data-testid": dataTestId, label, ref, }: SpinnerProps) => ReactElement;
66
+ export declare const Spinner: ({ mode, size, centering, className, containerClassName, "data-testid": dataTestId, label, style, ref, }: SpinnerProps) => ReactElement;
66
67
  export {};
@@ -1,10 +1,11 @@
1
1
  import { ActivityColors, CriticalityColors, GeneralColors, IntentColors } from "@trackunit/ui-design-tokens";
2
2
  import { MouseEventHandler, ReactElement, ReactNode, Ref } from "react";
3
3
  import { CommonProps } from "../../common/CommonProps";
4
+ import type { Styleable } from "../../common/Styleable";
4
5
  import { Size } from "../../common/Size";
5
6
  export type TagSize = Extract<Size, "small" | "medium">;
6
7
  export type TagColors = IntentColors | GeneralColors | CriticalityColors | ActivityColors;
7
- export interface TagProps extends CommonProps {
8
+ export interface TagProps extends CommonProps, Styleable {
8
9
  /**
9
10
  * The color of the tag.
10
11
  *
@@ -92,4 +93,4 @@ export interface TagProps extends CommonProps {
92
93
  * @param {TagProps} props - The props for the Tag component.
93
94
  * @returns {ReactElement} The rendered Tag component.
94
95
  */
95
- export declare const Tag: ({ className, "data-testid": dataTestId, children, size, onClickClose, color, disabled, ref, icon, onMouseEnter, }: TagProps) => ReactElement;
96
+ export declare const Tag: ({ className, "data-testid": dataTestId, children, size, onClickClose, color, disabled, ref, icon, onMouseEnter, style, }: TagProps) => ReactElement;
@@ -1,10 +1,11 @@
1
1
  import { ReactElement, ReactNode, Ref } from "react";
2
2
  import { CommonProps } from "../../common/CommonProps";
3
+ import type { Styleable } from "../../common/Styleable";
3
4
  import { Size } from "../../common/Size";
4
5
  export type TextType = "p" | "span" | "div";
5
6
  export type TextAlign = "left" | "center" | "right";
6
7
  export type TextWeight = "normal" | "thick" | "bold";
7
- export interface TextProps extends CommonProps {
8
+ export interface TextProps extends CommonProps, Styleable {
8
9
  /**
9
10
  * Child nodes.
10
11
  */
@@ -4,9 +4,10 @@ import { IconName } from "@trackunit/ui-icons";
4
4
  import { Dispatch, MouseEventHandler, ReactElement, SetStateAction } from "react";
5
5
  import { CommonProps } from "../../common/CommonProps";
6
6
  import { Refable } from "../../common/Refable";
7
+ import { type Styleable } from "../../common/Styleable";
7
8
  import { TooltipPlacement } from "../Tooltip/Tooltip";
8
9
  import { cvaToggleGroup } from "./ToggleGroup.variants";
9
- export interface BasicToggleGroupListProps<TSelectedId extends string = string> extends CommonProps {
10
+ export interface BasicToggleGroupListProps<TSelectedId extends string = string> extends CommonProps, Styleable {
10
11
  /**
11
12
  * Used to identify an individual button to be able to highlight the selected one.
12
13
  */
@@ -39,7 +40,7 @@ export interface BasicToggleGroupListProps<TSelectedId extends string = string>
39
40
  placement?: TooltipPlacement;
40
41
  };
41
42
  }
42
- export type ToggleGroupProps<TSelectedId extends string = string> = CommonProps & Refable<HTMLDivElement> & MappedOmit<VariantProps<typeof cvaToggleGroup>, "className"> & {
43
+ export type ToggleGroupProps<TSelectedId extends string = string> = CommonProps & Styleable & Refable<HTMLDivElement> & MappedOmit<VariantProps<typeof cvaToggleGroup>, "className"> & {
43
44
  list: ReadonlyArray<BasicToggleGroupListProps<TSelectedId>>;
44
45
  /**
45
46
  * Instead of onClick, we now use onChange to return the selected value
@@ -92,8 +93,8 @@ export type ToggleGroupProps<TSelectedId extends string = string> = CommonProps
92
93
  * @param {ToggleGroupProps} props - The props for the ToggleGroup component
93
94
  * @returns {ReactElement} ToggleGroup component
94
95
  */
95
- export declare const ToggleGroup: <TSelectedId extends string = string>({ list, selected, setSelected, onChange, disabled, size, isIconOnly, className, "data-testid": dataTestId, ref, }: ToggleGroupProps<TSelectedId>) => ReactElement;
96
- export interface ToggleItemProps extends CommonProps, MappedOmit<BasicToggleGroupListProps<string>, "id"> {
96
+ export declare const ToggleGroup: <TSelectedId extends string = string>({ list, selected, setSelected, onChange, disabled, size, isIconOnly, className, "data-testid": dataTestId, style, ref, }: ToggleGroupProps<TSelectedId>) => ReactElement;
97
+ export interface ToggleItemProps extends CommonProps, Styleable, MappedOmit<BasicToggleGroupListProps<string>, "id"> {
97
98
  title: string;
98
99
  text?: {
99
100
  truncate: boolean;
@@ -2,7 +2,7 @@ import { Placement } from "@floating-ui/react";
2
2
  import { ReactElement, ReactNode } from "react";
3
3
  import { CommonProps } from "../../common/CommonProps";
4
4
  import { Refable } from "../../common/Refable";
5
- import { Styleable } from "../../common/Styleable";
5
+ import type { Styleable } from "../../common/Styleable";
6
6
  import { IconProps } from "../Icon/Icon";
7
7
  import { PopoverHoverOptions } from "../Popover/PopoverTypes";
8
8
  export type TooltipPlacement = Placement | "auto";
@@ -1,7 +1,8 @@
1
1
  import { ReactElement } from "react";
2
2
  import { CommonProps } from "../../common/CommonProps";
3
+ import type { Styleable } from "../../common/Styleable";
3
4
  import type { SegmentedValueBarSize, ValueBarSegment } from "./SegmentedValueBarTypes";
4
- export interface SegmentedValueBarProps extends CommonProps {
5
+ export interface SegmentedValueBarProps extends CommonProps, Styleable {
5
6
  /**
6
7
  * Array of segments to display. Each segment has a numeric value and a color and optionally a label.
7
8
  * Segments render in the order they are provided; the component does not sort or reorder them.
@@ -49,4 +50,4 @@ export interface SegmentedValueBarProps extends CommonProps {
49
50
  * SegmentedValueBar displays multiple colored segments on a bar to visualize values relative to a total.
50
51
  * Supports optional tooltips per segment, showing value and optionally a label.
51
52
  */
52
- export declare const SegmentedValueBar: ({ segments, total, size, showValue, displayValue, unit, valueColor, showTooltip, tooltipUnit, valueWidth, className, "data-testid": dataTestId, }: SegmentedValueBarProps) => ReactElement;
53
+ export declare const SegmentedValueBar: ({ segments, total, size, showValue, displayValue, unit, valueColor, showTooltip, tooltipUnit, valueWidth, className, "data-testid": dataTestId, style, }: SegmentedValueBarProps) => ReactElement;
@@ -1,10 +1,11 @@
1
1
  import { ReactElement } from "react";
2
2
  import { CommonProps } from "../../common/CommonProps";
3
+ import type { Styleable } from "../../common/Styleable";
3
4
  import { Refable } from "../../common/Refable";
4
5
  import { Size } from "../../common/Size";
5
6
  import { LevelColors } from "./ValueBarTypes";
6
7
  type ValueBarSize = Extract<Size, "small" | "large"> | "extraSmall";
7
- export interface ValueBarProps extends CommonProps, Refable<HTMLSpanElement> {
8
+ export interface ValueBarProps extends CommonProps, Styleable, Refable<HTMLSpanElement> {
8
9
  /**
9
10
  * Value to display.
10
11
  */
@@ -86,5 +87,5 @@ export interface ValueBarProps extends CommonProps, Refable<HTMLSpanElement> {
86
87
  * @param {ValueBarProps} props - The props for the ValueBar component
87
88
  * @returns {ReactElement} ValueBar component
88
89
  */
89
- export declare const ValueBar: ({ value, min, max, unit, size, levelColors, valueColor, showValue, className, "data-testid": dataTestId, zeroScoreAllowed, ref, }: ValueBarProps) => ReactElement;
90
+ export declare const ValueBar: ({ value, min, max, unit, size, levelColors, valueColor, showValue, className, "data-testid": dataTestId, zeroScoreAllowed, style, ref, }: ValueBarProps) => ReactElement;
90
91
  export {};