@luscii-healthtech/web-ui 54.7.2 → 55.0.0
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.development.js +22 -30
- package/dist/index.development.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/src/components/PageHeader/PageHeader.types.d.ts +24 -3
- package/dist/src/generated/components/PageHeader/PageHeader.types.d.ts +24 -3
- package/dist/src/generated/index.d.ts +0 -1
- package/dist/src/index.d.ts +0 -1
- package/dist/stories/Tabs.stories.d.ts +14 -22
- package/dist/web-ui-tailwind.css +0 -6
- package/dist/web-ui.esm.js +1 -1
- package/dist/web-ui.esm.js.map +1 -1
- package/package.json +1 -1
- package/dist/src/components/Tabbar/Tabbar.d.ts +0 -38
- package/dist/src/components/Tabbar/TabbarItem.d.ts +0 -22
- package/dist/src/generated/components/Tabbar/Tabbar.d.ts +0 -38
- package/dist/src/generated/components/Tabbar/TabbarItem.d.ts +0 -22
- package/dist/stories/Tabbar.stories.d.ts +0 -16
|
@@ -1,9 +1,30 @@
|
|
|
1
1
|
import type { FC, ReactNode } from "react";
|
|
2
2
|
import type { BreadcrumbProps } from "../Breadcrumbs";
|
|
3
3
|
import { type NotificationBannerColor } from "../NotificationBanner/NotificationBanner";
|
|
4
|
-
import type { TabbarProps } from "../Tabbar/Tabbar";
|
|
5
4
|
import { type IconProps } from "../Icons/types/IconProps.type";
|
|
6
5
|
type Nil = null | undefined;
|
|
6
|
+
/**
|
|
7
|
+
* A single tab in the page header's navigation bar.
|
|
8
|
+
*/
|
|
9
|
+
export interface PageHeaderNavigationTab<T extends object = Record<string, unknown>> {
|
|
10
|
+
title: string | JSX.Element;
|
|
11
|
+
badgeCount?: number;
|
|
12
|
+
isLoading?: boolean;
|
|
13
|
+
dataTestId?: string;
|
|
14
|
+
extra?: T;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Tabbed navigation rendered at the bottom of the page header.
|
|
18
|
+
*/
|
|
19
|
+
export interface PageHeaderNavigation<T extends object = Record<string, unknown>> {
|
|
20
|
+
tabs?: PageHeaderNavigationTab<T>[];
|
|
21
|
+
selectedIndex?: number;
|
|
22
|
+
onSelect?: (params: {
|
|
23
|
+
index: number;
|
|
24
|
+
selectedTab: PageHeaderNavigationTab<T>;
|
|
25
|
+
}) => void;
|
|
26
|
+
className?: string;
|
|
27
|
+
}
|
|
7
28
|
type WithPageHeaderBanner = {
|
|
8
29
|
banner?: Nil | {
|
|
9
30
|
title?: string;
|
|
@@ -32,10 +53,10 @@ type WithBreadcrumbProps = {
|
|
|
32
53
|
}>;
|
|
33
54
|
export type PageHeaderProps = {
|
|
34
55
|
/**
|
|
35
|
-
*
|
|
56
|
+
* Tabbed navigation rendered at the bottom of the page header. The name
|
|
36
57
|
* `navigation` does not convey this well.
|
|
37
58
|
*/
|
|
38
|
-
navigation?:
|
|
59
|
+
navigation?: PageHeaderNavigation;
|
|
39
60
|
dataTestId?: string;
|
|
40
61
|
title: string | ReactNode;
|
|
41
62
|
isPolling?: boolean;
|
|
@@ -1,9 +1,30 @@
|
|
|
1
1
|
import type { FC, ReactNode } from "react";
|
|
2
2
|
import type { BreadcrumbProps } from "../Breadcrumbs";
|
|
3
3
|
import { type NotificationBannerColor } from "../NotificationBanner/NotificationBanner";
|
|
4
|
-
import type { TabbarProps } from "../Tabbar/Tabbar";
|
|
5
4
|
import { type IconProps } from "../Icons/types/IconProps.type";
|
|
6
5
|
type Nil = null | undefined;
|
|
6
|
+
/**
|
|
7
|
+
* A single tab in the page header's navigation bar.
|
|
8
|
+
*/
|
|
9
|
+
export interface PageHeaderNavigationTab<T extends object = Record<string, unknown>> {
|
|
10
|
+
title: string | JSX.Element;
|
|
11
|
+
badgeCount?: number;
|
|
12
|
+
isLoading?: boolean;
|
|
13
|
+
dataTestId?: string;
|
|
14
|
+
extra?: T;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Tabbed navigation rendered at the bottom of the page header.
|
|
18
|
+
*/
|
|
19
|
+
export interface PageHeaderNavigation<T extends object = Record<string, unknown>> {
|
|
20
|
+
tabs?: PageHeaderNavigationTab<T>[];
|
|
21
|
+
selectedIndex?: number;
|
|
22
|
+
onSelect?: (params: {
|
|
23
|
+
index: number;
|
|
24
|
+
selectedTab: PageHeaderNavigationTab<T>;
|
|
25
|
+
}) => void;
|
|
26
|
+
className?: string;
|
|
27
|
+
}
|
|
7
28
|
type WithPageHeaderBanner = {
|
|
8
29
|
banner?: Nil | {
|
|
9
30
|
title?: string;
|
|
@@ -32,10 +53,10 @@ type WithBreadcrumbProps = {
|
|
|
32
53
|
}>;
|
|
33
54
|
export type PageHeaderProps = {
|
|
34
55
|
/**
|
|
35
|
-
*
|
|
56
|
+
* Tabbed navigation rendered at the bottom of the page header. The name
|
|
36
57
|
* `navigation` does not convey this well.
|
|
37
58
|
*/
|
|
38
|
-
navigation?:
|
|
59
|
+
navigation?: PageHeaderNavigation;
|
|
39
60
|
dataTestId?: string;
|
|
40
61
|
title: string | ReactNode;
|
|
41
62
|
isPolling?: boolean;
|
|
@@ -90,7 +90,6 @@ export { default as Image } from "./components/Image/Image";
|
|
|
90
90
|
export { MediaPicker, type TargetProps, } from "./components/MediaPicker/MediaPicker";
|
|
91
91
|
export { Stack } from "./components/Stack/Stack";
|
|
92
92
|
export { Box } from "./components/Box/Box";
|
|
93
|
-
export { default as Tabbar, type TabbarProps, type TabItemDetails, } from "./components/Tabbar/Tabbar";
|
|
94
93
|
export { Breadcrumbs, type BreadcrumbProps } from "./components/Breadcrumbs";
|
|
95
94
|
export { PageHeader, type PageHeaderProps } from "./components/PageHeader";
|
|
96
95
|
export { Tag } from "./components/Tag/Tag";
|
package/dist/src/index.d.ts
CHANGED
|
@@ -90,7 +90,6 @@ export { default as Image } from "./components/Image/Image";
|
|
|
90
90
|
export { MediaPicker, type TargetProps, } from "./components/MediaPicker/MediaPicker";
|
|
91
91
|
export { Stack } from "./components/Stack/Stack";
|
|
92
92
|
export { Box } from "./components/Box/Box";
|
|
93
|
-
export { default as Tabbar, type TabbarProps, type TabItemDetails, } from "./components/Tabbar/Tabbar";
|
|
94
93
|
export { Breadcrumbs, type BreadcrumbProps } from "./components/Breadcrumbs";
|
|
95
94
|
export { PageHeader, type PageHeaderProps } from "./components/PageHeader";
|
|
96
95
|
export { Tag } from "./components/Tag/Tag";
|
|
@@ -45,42 +45,34 @@ export declare const Base: Story;
|
|
|
45
45
|
export declare const WithDisabledTab: Story;
|
|
46
46
|
export declare const Controlled: Story;
|
|
47
47
|
/**
|
|
48
|
-
*
|
|
49
|
-
*
|
|
50
|
-
* the consumer composes a `<Badge>` inside `Tabs.Trigger`.
|
|
48
|
+
* Compose a counter `<Badge>` inside `Tabs.Trigger`. Render the badge
|
|
49
|
+
* only when there is a value to show.
|
|
51
50
|
*/
|
|
52
51
|
export declare const WithBadge: Story;
|
|
53
52
|
/**
|
|
54
|
-
*
|
|
55
|
-
* spinner next to the label
|
|
56
|
-
* consumer composes a `<LoadingIndicator>` inside `Tabs.Trigger`.
|
|
53
|
+
* Compose a `<LoadingIndicator>` inside `Tabs.Trigger` to show a small
|
|
54
|
+
* inline spinner next to the label while that tab's data loads.
|
|
57
55
|
*/
|
|
58
56
|
export declare const WithLoadingIndicator: Story;
|
|
59
57
|
/**
|
|
60
|
-
*
|
|
61
|
-
*
|
|
62
|
-
*
|
|
63
|
-
* children — `Tabs.LabelText` is optional.
|
|
58
|
+
* `Tabs.Trigger` accepts any ReactNode as children, so a trigger can
|
|
59
|
+
* render rich content — an icon, a colored indicator, etc. —
|
|
60
|
+
* alongside or instead of `Tabs.LabelText`.
|
|
64
61
|
*/
|
|
65
62
|
export declare const TitleAsJsxElement: Story;
|
|
66
63
|
/**
|
|
67
|
-
*
|
|
68
|
-
* `data-test-id`
|
|
69
|
-
* same attribute can be passed directly — Radix forwards unknown props
|
|
70
|
-
* to the underlying button.
|
|
64
|
+
* `Tabs.Trigger` forwards unknown props to the underlying `<button>`,
|
|
65
|
+
* so attributes such as `data-test-id` can be passed directly.
|
|
71
66
|
*/
|
|
72
67
|
export declare const WithDataTestId: Story;
|
|
73
68
|
/**
|
|
74
|
-
*
|
|
75
|
-
*
|
|
76
|
-
*
|
|
77
|
-
* the tab `value` and resolves it on `onValueChange`.
|
|
69
|
+
* `Tabs` does not carry arbitrary metadata on the component itself.
|
|
70
|
+
* Keep your own mapping keyed by the tab `value` and resolve it on
|
|
71
|
+
* `onValueChange`.
|
|
78
72
|
*/
|
|
79
73
|
export declare const WithExtraMetadata: Story;
|
|
80
74
|
/**
|
|
81
|
-
*
|
|
82
|
-
* tab
|
|
83
|
-
* active on mount. `Tabs` matches that behavior when `defaultValue` /
|
|
84
|
-
* `value` does not match any trigger.
|
|
75
|
+
* When `defaultValue` (or `value`) does not match any `Tabs.Trigger`,
|
|
76
|
+
* no tab is active on mount.
|
|
85
77
|
*/
|
|
86
78
|
export declare const NoDefaultSelected: Story;
|
package/dist/web-ui-tailwind.css
CHANGED
|
@@ -2803,18 +2803,12 @@ button, input:where([type='button'], [type='reset'], [type='submit']), ::file-se
|
|
|
2803
2803
|
.ui\:border-b-border-neutral-secondary-default {
|
|
2804
2804
|
border-bottom-color: var(--ui-primitive-color-grey-500);
|
|
2805
2805
|
}
|
|
2806
|
-
.ui\:border-b-primary {
|
|
2807
|
-
border-bottom-color: var(--ui-color-blue-800);
|
|
2808
|
-
}
|
|
2809
2806
|
.ui\:border-b-slate-100 {
|
|
2810
2807
|
border-bottom-color: var(--ui-color-slate-100);
|
|
2811
2808
|
}
|
|
2812
2809
|
.ui\:border-b-slate-200 {
|
|
2813
2810
|
border-bottom-color: var(--ui-color-slate-200);
|
|
2814
2811
|
}
|
|
2815
|
-
.ui\:border-b-transparent {
|
|
2816
|
-
border-bottom-color: transparent;
|
|
2817
|
-
}
|
|
2818
2812
|
.ui\:bg-amber-50 {
|
|
2819
2813
|
background-color: var(--ui-color-amber-50);
|
|
2820
2814
|
}
|