@ledgerhq/lumen-ui-react 0.1.24 → 0.1.25

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.js CHANGED
@@ -3,11 +3,11 @@ import { AddressInput as a } from "./lib/Components/AddressInput/AddressInput.js
3
3
  import { AmountInput as i } from "./lib/Components/AmountInput/AmountInput.js";
4
4
  import { AmountDisplay as l } from "./lib/Components/AmountDisplay/AmountDisplay.js";
5
5
  import { Avatar as d } from "./lib/Components/Avatar/Avatar.js";
6
- import { Banner as x } from "./lib/Components/Banner/Banner.js";
7
- import { BaseInput as S } from "./lib/Components/BaseInput/BaseInput.js";
6
+ import { Banner as T } from "./lib/Components/Banner/Banner.js";
7
+ import { BaseInput as u } from "./lib/Components/BaseInput/BaseInput.js";
8
8
  import { Button as C } from "./lib/Components/Button/Button.js";
9
9
  import { BaseButton as g } from "./lib/Components/Button/BaseButton.js";
10
- import { Card as b, CardContent as I, CardContentDescription as s, CardContentRow as M, CardContentTitle as D, CardFooter as L, CardFooterActions as h, CardHeader as v, CardLeading as R, CardTrailing as w } from "./lib/Components/Card/Card.js";
10
+ import { Card as I, CardContent as b, CardContentDescription as s, CardContentRow as D, CardContentTitle as M, CardFooter as L, CardFooterActions as h, CardHeader as v, CardLeading as R, CardTrailing as w } from "./lib/Components/Card/Card.js";
11
11
  import { CardButton as y } from "./lib/Components/CardButton/CardButton.js";
12
12
  import { ContentBanner as P, ContentBannerContent as k, ContentBannerDescription as z, ContentBannerTitle as N } from "./lib/Components/ContentBanner/ContentBanner.js";
13
13
  import { Checkbox as E } from "./lib/Components/Checkbox/Checkbox.js";
@@ -17,54 +17,56 @@ import { DialogClose as Q } from "./lib/Components/Dialog/DialogClose/DialogClos
17
17
  import { Dialog as V, DialogBody as W, DialogBodyStickyContent as X, DialogContent as Y, DialogFooter as Z, DialogTrigger as $ } from "./lib/Components/Dialog/Dialog.js";
18
18
  import { DialogHeader as oe } from "./lib/Components/Dialog/DialogHeader/DialogHeader.js";
19
19
  import { Divider as re } from "./lib/Components/Divider/Divider.js";
20
- import { DotIcon as ne, dotIconSizeMap as ie, mediaImageDotIconSizeMap as pe, spotDotIconSizeMap as le } from "./lib/Components/DotIcon/DotIcon.js";
21
- import { DotSymbol as de, mediaImageDotSizeMap as Te, spotDotSizeMap as xe } from "./lib/Components/DotSymbol/DotSymbol.js";
22
- import { IconButton as Se } from "./lib/Components/IconButton/IconButton.js";
23
- import { InteractiveIcon as Ce } from "./lib/Components/InteractiveIcon/InteractiveIcon.js";
24
- import { Link as ge } from "./lib/Components/Link/Link.js";
25
- import { ListItem as be, ListItemContent as Ie, ListItemContentRow as se, ListItemDescription as Me, ListItemLeading as De, ListItemTitle as Le, ListItemTrailing as he } from "./lib/Components/ListItem/ListItem.js";
26
- import { MediaBanner as Re, MediaBannerDescription as we, MediaBannerTitle as Ae } from "./lib/Components/MediaBanner/MediaBanner.js";
27
- import { MediaButton as He } from "./lib/Components/MediaButton/MediaButton.js";
28
- import { MediaCard as ke, MediaCardTitle as ze } from "./lib/Components/MediaCard/MediaCard.js";
29
- import { MediaImage as Ge } from "./lib/Components/MediaImage/MediaImage.js";
30
- import { Menu as Fe, MenuCheckboxItem as Oe, MenuContent as _e, MenuGroup as je, MenuItem as qe, MenuLabel as Je, MenuPortal as Ke, MenuRadioGroup as Qe, MenuRadioItem as Ue, MenuSeparator as Ve, MenuSub as We, MenuSubContent as Xe, MenuSubTrigger as Ye, MenuTrigger as Ze } from "./lib/Components/Menu/Menu.js";
31
- import { NavBar as eo, NavBarBackButton as oo, NavBarCoinCapsule as to, NavBarTitle as ro, NavBarTrailing as ao } from "./lib/Components/NavBar/NavBar.js";
32
- import { Popover as io, PopoverContent as po, PopoverTrigger as lo, createPopoverHandle as mo } from "./lib/Components/Popover/Popover.js";
33
- import { PageIndicator as xo } from "./lib/Components/PageIndicator/PageIndicator.js";
34
- import { SearchInput as So } from "./lib/Components/SearchInput/SearchInput.js";
35
- import { SegmentedControl as Co, SegmentedControlButton as co } from "./lib/Components/SegmentedControl/SegmentedControl.js";
36
- import { Select as Bo, SelectContent as bo, SelectEmptyState as Io, SelectItem as so, SelectItemContent as Mo, SelectItemDescription as Do, SelectItemText as Lo, SelectList as ho, SelectSearch as vo, SelectSeparator as Ro, SelectTrigger as wo } from "./lib/Components/Select/Select.js";
37
- import { SideBar as yo, SideBarCollapseToggle as Ho, SideBarItem as Po, SideBarLeading as ko, SideBarTrailing as zo } from "./lib/Components/SideBar/SideBar.js";
38
- import { Skeleton as Go } from "./lib/Components/Skeleton/Skeleton.js";
39
- import { Spinner as Fo } from "./lib/Components/Spinner/Spinner.js";
40
- import { Spot as _o } from "./lib/Components/Spot/Spot.js";
41
- import { Stepper as qo } from "./lib/Components/Stepper/Stepper.js";
42
- import { Subheader as Ko, SubheaderCount as Qo, SubheaderDescription as Uo, SubheaderInfo as Vo, SubheaderRow as Wo, SubheaderShowMore as Xo, SubheaderTitle as Yo } from "./lib/Components/Subheader/Subheader.js";
43
- import { Switch as $o } from "./lib/Components/Switch/Switch.js";
44
- import { Table as ot, TableActionBar as tt, TableActionBarLeading as rt, TableActionBarTrailing as at, TableBody as nt, TableCell as it, TableCellContent as pt, TableGroupHeaderRow as lt, TableHeader as mt, TableHeaderCell as dt, TableHeaderRow as Tt, TableInfoIcon as xt, TableLoadingRow as ft, TableRoot as St, TableRow as ut, TableSortButton as Ct } from "./lib/Components/Table/Table.js";
45
- import { Tag as gt } from "./lib/Components/Tag/Tag.js";
46
- import { TextInput as bt } from "./lib/Components/TextInput/TextInput.js";
47
- import { Tile as st, TileContent as Mt, TileDescription as Dt, TileSecondaryAction as Lt, TileTitle as ht, TileTrailingContent as vt } from "./lib/Components/Tile/Tile.js";
48
- import { TileButton as wt } from "./lib/Components/TileButton/TileButton.js";
49
- import { Tooltip as yt, TooltipContent as Ht, TooltipProvider as Pt, TooltipTrigger as kt } from "./lib/Components/Tooltip/Tooltip.js";
50
- import { ThemeProvider as Nt, useTheme as Gt } from "./lib/Components/ThemeProvider/ThemeProvider.js";
51
- import { COLOR_SCHEMES as Ft } from "./lib/Components/ThemeProvider/ThemeProvider.types.js";
20
+ import { DotCount as ne } from "./lib/Components/DotCount/DotCount.js";
21
+ import { DotIcon as pe, dotIconSizeMap as le, mediaImageDotIconSizeMap as me, spotDotIconSizeMap as de } from "./lib/Components/DotIcon/DotIcon.js";
22
+ import { DotIndicator as Te } from "./lib/Components/DotIndicator/DotIndicator.js";
23
+ import { DotSymbol as ue, mediaImageDotSizeMap as Se, spotDotSizeMap as Ce } from "./lib/Components/DotSymbol/DotSymbol.js";
24
+ import { IconButton as ge } from "./lib/Components/IconButton/IconButton.js";
25
+ import { InteractiveIcon as Ie } from "./lib/Components/InteractiveIcon/InteractiveIcon.js";
26
+ import { Link as se } from "./lib/Components/Link/Link.js";
27
+ import { ListItem as Me, ListItemContent as Le, ListItemContentRow as he, ListItemDescription as ve, ListItemLeading as Re, ListItemTitle as we, ListItemTrailing as Ae } from "./lib/Components/ListItem/ListItem.js";
28
+ import { MediaBanner as He, MediaBannerDescription as Pe, MediaBannerTitle as ke } from "./lib/Components/MediaBanner/MediaBanner.js";
29
+ import { MediaButton as Ne } from "./lib/Components/MediaButton/MediaButton.js";
30
+ import { MediaCard as Ee, MediaCardTitle as Fe } from "./lib/Components/MediaCard/MediaCard.js";
31
+ import { MediaImage as _e } from "./lib/Components/MediaImage/MediaImage.js";
32
+ import { Menu as qe, MenuCheckboxItem as Je, MenuContent as Ke, MenuGroup as Qe, MenuItem as Ue, MenuLabel as Ve, MenuPortal as We, MenuRadioGroup as Xe, MenuRadioItem as Ye, MenuSeparator as Ze, MenuSub as $e, MenuSubContent as eo, MenuSubTrigger as oo, MenuTrigger as to } from "./lib/Components/Menu/Menu.js";
33
+ import { NavBar as ao, NavBarBackButton as no, NavBarCoinCapsule as io, NavBarTitle as po, NavBarTrailing as lo } from "./lib/Components/NavBar/NavBar.js";
34
+ import { Popover as xo, PopoverContent as To, PopoverTrigger as fo, createPopoverHandle as uo } from "./lib/Components/Popover/Popover.js";
35
+ import { PageIndicator as Co } from "./lib/Components/PageIndicator/PageIndicator.js";
36
+ import { SearchInput as go } from "./lib/Components/SearchInput/SearchInput.js";
37
+ import { SegmentedControl as Io, SegmentedControlButton as bo } from "./lib/Components/SegmentedControl/SegmentedControl.js";
38
+ import { Select as Do, SelectContent as Mo, SelectEmptyState as Lo, SelectItem as ho, SelectItemContent as vo, SelectItemDescription as Ro, SelectItemText as wo, SelectList as Ao, SelectSearch as yo, SelectSeparator as Ho, SelectTrigger as Po } from "./lib/Components/Select/Select.js";
39
+ import { SideBar as zo, SideBarCollapseToggle as No, SideBarItem as Go, SideBarLeading as Eo, SideBarTrailing as Fo } from "./lib/Components/SideBar/SideBar.js";
40
+ import { Skeleton as _o } from "./lib/Components/Skeleton/Skeleton.js";
41
+ import { Spinner as qo } from "./lib/Components/Spinner/Spinner.js";
42
+ import { Spot as Ko } from "./lib/Components/Spot/Spot.js";
43
+ import { Stepper as Uo } from "./lib/Components/Stepper/Stepper.js";
44
+ import { Subheader as Wo, SubheaderCount as Xo, SubheaderDescription as Yo, SubheaderInfo as Zo, SubheaderRow as $o, SubheaderShowMore as et, SubheaderTitle as ot } from "./lib/Components/Subheader/Subheader.js";
45
+ import { Switch as rt } from "./lib/Components/Switch/Switch.js";
46
+ import { Table as nt, TableActionBar as it, TableActionBarLeading as pt, TableActionBarTrailing as lt, TableBody as mt, TableCell as dt, TableCellContent as xt, TableGroupHeaderRow as Tt, TableHeader as ft, TableHeaderCell as ut, TableHeaderRow as St, TableInfoIcon as Ct, TableLoadingRow as ct, TableRoot as gt, TableRow as Bt, TableSortButton as It } from "./lib/Components/Table/Table.js";
47
+ import { Tag as st } from "./lib/Components/Tag/Tag.js";
48
+ import { TextInput as Mt } from "./lib/Components/TextInput/TextInput.js";
49
+ import { Tile as ht, TileContent as vt, TileDescription as Rt, TileSecondaryAction as wt, TileTitle as At, TileTrailingContent as yt } from "./lib/Components/Tile/Tile.js";
50
+ import { TileButton as Pt } from "./lib/Components/TileButton/TileButton.js";
51
+ import { Tooltip as zt, TooltipContent as Nt, TooltipProvider as Gt, TooltipTrigger as Et } from "./lib/Components/Tooltip/Tooltip.js";
52
+ import { ThemeProvider as Ot, useTheme as _t } from "./lib/Components/ThemeProvider/ThemeProvider.js";
53
+ import { COLOR_SCHEMES as qt } from "./lib/Components/ThemeProvider/ThemeProvider.types.js";
52
54
  export {
53
55
  a as AddressInput,
54
56
  l as AmountDisplay,
55
57
  i as AmountInput,
56
58
  d as Avatar,
57
- x as Banner,
59
+ T as Banner,
58
60
  g as BaseButton,
59
- S as BaseInput,
61
+ u as BaseInput,
60
62
  C as Button,
61
- Ft as COLOR_SCHEMES,
62
- b as Card,
63
+ qt as COLOR_SCHEMES,
64
+ I as Card,
63
65
  y as CardButton,
64
- I as CardContent,
66
+ b as CardContent,
65
67
  s as CardContentDescription,
66
- M as CardContentRow,
67
- D as CardContentTitle,
68
+ D as CardContentRow,
69
+ M as CardContentTitle,
68
70
  L as CardFooter,
69
71
  h as CardFooterActions,
70
72
  v as CardHeader,
@@ -87,116 +89,118 @@ export {
87
89
  oe as DialogHeader,
88
90
  $ as DialogTrigger,
89
91
  re as Divider,
90
- ne as DotIcon,
91
- de as DotSymbol,
92
- Se as IconButton,
93
- Ce as InteractiveIcon,
92
+ ne as DotCount,
93
+ pe as DotIcon,
94
+ Te as DotIndicator,
95
+ ue as DotSymbol,
96
+ ge as IconButton,
97
+ Ie as InteractiveIcon,
94
98
  t as Languages,
95
- ge as Link,
96
- be as ListItem,
97
- Ie as ListItemContent,
98
- se as ListItemContentRow,
99
- Me as ListItemDescription,
100
- De as ListItemLeading,
101
- Le as ListItemTitle,
102
- he as ListItemTrailing,
103
- Re as MediaBanner,
104
- we as MediaBannerDescription,
105
- Ae as MediaBannerTitle,
106
- He as MediaButton,
107
- ke as MediaCard,
108
- ze as MediaCardTitle,
109
- Ge as MediaImage,
110
- Fe as Menu,
111
- Oe as MenuCheckboxItem,
112
- _e as MenuContent,
113
- je as MenuGroup,
114
- qe as MenuItem,
115
- Je as MenuLabel,
116
- Ke as MenuPortal,
117
- Qe as MenuRadioGroup,
118
- Ue as MenuRadioItem,
119
- Ve as MenuSeparator,
120
- We as MenuSub,
121
- Xe as MenuSubContent,
122
- Ye as MenuSubTrigger,
123
- Ze as MenuTrigger,
124
- eo as NavBar,
125
- oo as NavBarBackButton,
126
- to as NavBarCoinCapsule,
127
- ro as NavBarTitle,
128
- ao as NavBarTrailing,
129
- xo as PageIndicator,
130
- io as Popover,
131
- po as PopoverContent,
132
- lo as PopoverTrigger,
133
- So as SearchInput,
134
- Co as SegmentedControl,
135
- co as SegmentedControlButton,
136
- Bo as Select,
137
- bo as SelectContent,
138
- Io as SelectEmptyState,
139
- so as SelectItem,
140
- Mo as SelectItemContent,
141
- Do as SelectItemDescription,
142
- Lo as SelectItemText,
143
- ho as SelectList,
144
- vo as SelectSearch,
145
- Ro as SelectSeparator,
146
- wo as SelectTrigger,
147
- yo as SideBar,
148
- Ho as SideBarCollapseToggle,
149
- Po as SideBarItem,
150
- ko as SideBarLeading,
151
- zo as SideBarTrailing,
152
- Go as Skeleton,
153
- Fo as Spinner,
154
- _o as Spot,
155
- qo as Stepper,
156
- Ko as Subheader,
157
- Qo as SubheaderCount,
158
- Uo as SubheaderDescription,
159
- Vo as SubheaderInfo,
160
- Wo as SubheaderRow,
161
- Xo as SubheaderShowMore,
162
- Yo as SubheaderTitle,
163
- $o as Switch,
164
- ot as Table,
165
- tt as TableActionBar,
166
- rt as TableActionBarLeading,
167
- at as TableActionBarTrailing,
168
- nt as TableBody,
169
- it as TableCell,
170
- pt as TableCellContent,
171
- lt as TableGroupHeaderRow,
172
- mt as TableHeader,
173
- dt as TableHeaderCell,
174
- Tt as TableHeaderRow,
175
- xt as TableInfoIcon,
176
- ft as TableLoadingRow,
177
- St as TableRoot,
178
- ut as TableRow,
179
- Ct as TableSortButton,
180
- gt as Tag,
181
- bt as TextInput,
182
- Nt as ThemeProvider,
183
- st as Tile,
184
- wt as TileButton,
185
- Mt as TileContent,
186
- Dt as TileDescription,
187
- Lt as TileSecondaryAction,
188
- ht as TileTitle,
189
- vt as TileTrailingContent,
190
- yt as Tooltip,
191
- Ht as TooltipContent,
192
- Pt as TooltipProvider,
193
- kt as TooltipTrigger,
194
- mo as createPopoverHandle,
195
- ie as dotIconSizeMap,
196
- pe as mediaImageDotIconSizeMap,
197
- Te as mediaImageDotSizeMap,
198
- le as spotDotIconSizeMap,
199
- xe as spotDotSizeMap,
99
+ se as Link,
100
+ Me as ListItem,
101
+ Le as ListItemContent,
102
+ he as ListItemContentRow,
103
+ ve as ListItemDescription,
104
+ Re as ListItemLeading,
105
+ we as ListItemTitle,
106
+ Ae as ListItemTrailing,
107
+ He as MediaBanner,
108
+ Pe as MediaBannerDescription,
109
+ ke as MediaBannerTitle,
110
+ Ne as MediaButton,
111
+ Ee as MediaCard,
112
+ Fe as MediaCardTitle,
113
+ _e as MediaImage,
114
+ qe as Menu,
115
+ Je as MenuCheckboxItem,
116
+ Ke as MenuContent,
117
+ Qe as MenuGroup,
118
+ Ue as MenuItem,
119
+ Ve as MenuLabel,
120
+ We as MenuPortal,
121
+ Xe as MenuRadioGroup,
122
+ Ye as MenuRadioItem,
123
+ Ze as MenuSeparator,
124
+ $e as MenuSub,
125
+ eo as MenuSubContent,
126
+ oo as MenuSubTrigger,
127
+ to as MenuTrigger,
128
+ ao as NavBar,
129
+ no as NavBarBackButton,
130
+ io as NavBarCoinCapsule,
131
+ po as NavBarTitle,
132
+ lo as NavBarTrailing,
133
+ Co as PageIndicator,
134
+ xo as Popover,
135
+ To as PopoverContent,
136
+ fo as PopoverTrigger,
137
+ go as SearchInput,
138
+ Io as SegmentedControl,
139
+ bo as SegmentedControlButton,
140
+ Do as Select,
141
+ Mo as SelectContent,
142
+ Lo as SelectEmptyState,
143
+ ho as SelectItem,
144
+ vo as SelectItemContent,
145
+ Ro as SelectItemDescription,
146
+ wo as SelectItemText,
147
+ Ao as SelectList,
148
+ yo as SelectSearch,
149
+ Ho as SelectSeparator,
150
+ Po as SelectTrigger,
151
+ zo as SideBar,
152
+ No as SideBarCollapseToggle,
153
+ Go as SideBarItem,
154
+ Eo as SideBarLeading,
155
+ Fo as SideBarTrailing,
156
+ _o as Skeleton,
157
+ qo as Spinner,
158
+ Ko as Spot,
159
+ Uo as Stepper,
160
+ Wo as Subheader,
161
+ Xo as SubheaderCount,
162
+ Yo as SubheaderDescription,
163
+ Zo as SubheaderInfo,
164
+ $o as SubheaderRow,
165
+ et as SubheaderShowMore,
166
+ ot as SubheaderTitle,
167
+ rt as Switch,
168
+ nt as Table,
169
+ it as TableActionBar,
170
+ pt as TableActionBarLeading,
171
+ lt as TableActionBarTrailing,
172
+ mt as TableBody,
173
+ dt as TableCell,
174
+ xt as TableCellContent,
175
+ Tt as TableGroupHeaderRow,
176
+ ft as TableHeader,
177
+ ut as TableHeaderCell,
178
+ St as TableHeaderRow,
179
+ Ct as TableInfoIcon,
180
+ ct as TableLoadingRow,
181
+ gt as TableRoot,
182
+ Bt as TableRow,
183
+ It as TableSortButton,
184
+ st as Tag,
185
+ Mt as TextInput,
186
+ Ot as ThemeProvider,
187
+ ht as Tile,
188
+ Pt as TileButton,
189
+ vt as TileContent,
190
+ Rt as TileDescription,
191
+ wt as TileSecondaryAction,
192
+ At as TileTitle,
193
+ yt as TileTrailingContent,
194
+ zt as Tooltip,
195
+ Nt as TooltipContent,
196
+ Gt as TooltipProvider,
197
+ Et as TooltipTrigger,
198
+ uo as createPopoverHandle,
199
+ le as dotIconSizeMap,
200
+ me as mediaImageDotIconSizeMap,
201
+ Se as mediaImageDotSizeMap,
202
+ de as spotDotIconSizeMap,
203
+ Ce as spotDotSizeMap,
200
204
  J as useLumenDataTable,
201
- Gt as useTheme
205
+ _t as useTheme
202
206
  };
@@ -0,0 +1,6 @@
1
+ import { DotCountProps } from './types';
2
+ export declare function DotCount({ value, size, max, appearance, disabled: disabledProp, children, className, 'aria-label': ariaLabel, ref, ...props }: DotCountProps): import("react/jsx-runtime").JSX.Element;
3
+ export declare namespace DotCount {
4
+ var displayName: string;
5
+ }
6
+ //# sourceMappingURL=DotCount.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DotCount.d.ts","sourceRoot":"","sources":["../../../../src/lib/Components/DotCount/DotCount.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAiD7C,wBAAgB,QAAQ,CAAC,EACvB,KAAK,EACL,IAAW,EACX,GAAQ,EACR,UAAmB,EACnB,QAAQ,EAAE,YAAoB,EAC9B,QAAQ,EACR,SAAS,EACT,YAAY,EAAE,SAAS,EACvB,GAAG,EACH,GAAG,KAAK,EACT,EAAE,aAAa,2CAiCf;yBA5Ce,QAAQ"}
@@ -0,0 +1,92 @@
1
+ import { jsxs as x, jsx as l } from "react/jsx-runtime";
2
+ import { useDisabledContext as g, cn as a } from "../../../libs/utils-shared/dist/index.js";
3
+ import { cva as m } from "class-variance-authority";
4
+ const h = m(
5
+ "pointer-events-none flex items-center justify-center rounded-full",
6
+ {
7
+ variants: {
8
+ size: {
9
+ lg: "min-h-24 min-w-24 px-8 py-2",
10
+ md: "min-h-16 min-w-16 px-4"
11
+ },
12
+ appearance: {
13
+ base: "bg-interactive",
14
+ red: "bg-error-strong"
15
+ },
16
+ disabled: {
17
+ true: "bg-disabled",
18
+ false: ""
19
+ }
20
+ },
21
+ defaultVariants: {
22
+ size: "md",
23
+ appearance: "base",
24
+ disabled: !1
25
+ }
26
+ }
27
+ ), v = m("", {
28
+ variants: {
29
+ size: {
30
+ lg: "body-2-semi-bold",
31
+ md: "body-4-semi-bold"
32
+ },
33
+ appearance: {
34
+ base: "text-on-interactive",
35
+ red: "text-on-error-strong"
36
+ },
37
+ disabled: {
38
+ true: "text-disabled",
39
+ false: ""
40
+ }
41
+ },
42
+ defaultVariants: {
43
+ size: "md",
44
+ appearance: "base",
45
+ disabled: !1
46
+ }
47
+ });
48
+ function y({
49
+ value: e,
50
+ size: t = "md",
51
+ max: b = 99,
52
+ appearance: s = "base",
53
+ disabled: c = !1,
54
+ children: i,
55
+ className: p,
56
+ "aria-label": n,
57
+ ref: f,
58
+ ...u
59
+ }) {
60
+ const d = g({
61
+ consumerName: "DotCount",
62
+ mergeWith: { disabled: c }
63
+ }), r = Math.max(1, Math.min(b, 99)), o = !!i;
64
+ return /* @__PURE__ */ x(
65
+ "div",
66
+ {
67
+ ref: f,
68
+ className: a(o && "relative inline-flex w-fit", p),
69
+ ...u,
70
+ children: [
71
+ /* @__PURE__ */ l(
72
+ "div",
73
+ {
74
+ role: "img",
75
+ "aria-label": n,
76
+ "aria-hidden": !n || void 0,
77
+ className: a(
78
+ h({ size: t, appearance: s, disabled: d }),
79
+ o && "absolute top-0 right-0 z-1"
80
+ ),
81
+ children: e > 0 && /* @__PURE__ */ l("span", { className: a(v({ size: t, appearance: s, disabled: d })), children: e <= r ? e : `${r}+` })
82
+ }
83
+ ),
84
+ i
85
+ ]
86
+ }
87
+ );
88
+ }
89
+ y.displayName = "DotCount";
90
+ export {
91
+ y as DotCount
92
+ };
@@ -0,0 +1,3 @@
1
+ export * from './DotCount';
2
+ export * from './types';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/Components/DotCount/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC;AAC3B,cAAc,SAAS,CAAC"}
@@ -0,0 +1,39 @@
1
+ import { ComponentPropsWithRef, ReactNode } from 'react';
2
+ export type DotCountProps = {
3
+ /**
4
+ * The size of the dot count.
5
+ * @default 'md'
6
+ */
7
+ size?: 'lg' | 'md';
8
+ /**
9
+ * The amount to be displayed.
10
+ *
11
+ * If higher than `max`, the displayed value will be "[max]+".
12
+ */
13
+ value: number;
14
+ /**
15
+ * The max value shown.
16
+ *
17
+ * If `value` is higher than `max`, the displayed value will be "[max]+".
18
+ *
19
+ * By design, it will ignore values higher than 99.
20
+ * @default 99
21
+ */
22
+ max?: number;
23
+ /**
24
+ * The appearance of the dot count.
25
+ * @default 'base'
26
+ */
27
+ appearance?: 'base' | 'red';
28
+ /**
29
+ * Whether the dot count should show a disabled appearance.
30
+ * @default false
31
+ */
32
+ disabled?: boolean;
33
+ /**
34
+ * Can be used as a wrapper to any component in case you wish to overlay a dot count on top of it.
35
+ * If provided, it'll pin the dot count to the top-right of the child component passed.
36
+ */
37
+ children?: ReactNode;
38
+ } & Omit<ComponentPropsWithRef<'div'>, 'children'>;
39
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/lib/Components/DotCount/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAE9D,MAAM,MAAM,aAAa,GAAG;IAC1B;;;OAGG;IACH,IAAI,CAAC,EAAE,IAAI,GAAG,IAAI,CAAC;IACnB;;;;OAIG;IACH,KAAK,EAAE,MAAM,CAAC;IACd;;;;;;;OAOG;IACH,GAAG,CAAC,EAAE,MAAM,CAAC;IACb;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,GAAG,KAAK,CAAC;IAC5B;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB;;;OAGG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;CACtB,GAAG,IAAI,CAAC,qBAAqB,CAAC,KAAK,CAAC,EAAE,UAAU,CAAC,CAAC"}
@@ -0,0 +1,6 @@
1
+ import { DotIndicatorProps } from './types';
2
+ export declare function DotIndicator({ size, appearance, disabled: disabledProp, children, className, 'aria-label': ariaLabel, ref, ...props }: DotIndicatorProps): import("react/jsx-runtime").JSX.Element;
3
+ export declare namespace DotIndicator {
4
+ var displayName: string;
5
+ }
6
+ //# sourceMappingURL=DotIndicator.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DotIndicator.d.ts","sourceRoot":"","sources":["../../../../src/lib/Components/DotIndicator/DotIndicator.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAyBjD,wBAAgB,YAAY,CAAC,EAC3B,IAAW,EACX,UAAmB,EACnB,QAAQ,EAAE,YAAoB,EAC9B,QAAQ,EACR,SAAS,EACT,YAAY,EAAE,SAAS,EACvB,GAAG,EACH,GAAG,KAAK,EACT,EAAE,iBAAiB,2CAyBnB;yBAlCe,YAAY"}
@@ -0,0 +1,66 @@
1
+ import { jsxs as m, jsx as b } from "react/jsx-runtime";
2
+ import { useDisabledContext as p, cn as i } from "../../../libs/utils-shared/dist/index.js";
3
+ import { cva as f } from "class-variance-authority";
4
+ const u = f("pointer-events-none rounded-full", {
5
+ variants: {
6
+ size: {
7
+ xs: "size-10",
8
+ sm: "size-12",
9
+ md: "size-16"
10
+ },
11
+ appearance: {
12
+ base: "bg-interactive",
13
+ red: "bg-error-strong"
14
+ },
15
+ disabled: {
16
+ true: "bg-disabled",
17
+ false: ""
18
+ }
19
+ },
20
+ defaultVariants: {
21
+ size: "sm",
22
+ appearance: "base",
23
+ disabled: !1
24
+ }
25
+ });
26
+ function v({
27
+ size: t = "sm",
28
+ appearance: r = "base",
29
+ disabled: n = !1,
30
+ children: e,
31
+ className: d,
32
+ "aria-label": a,
33
+ ref: o,
34
+ ...l
35
+ }) {
36
+ const c = p({
37
+ consumerName: "DotIndicator",
38
+ mergeWith: { disabled: n }
39
+ }), s = !!e;
40
+ return /* @__PURE__ */ m(
41
+ "div",
42
+ {
43
+ ref: o,
44
+ className: i(s && "relative inline-flex w-fit", d),
45
+ ...l,
46
+ children: [
47
+ /* @__PURE__ */ b(
48
+ "div",
49
+ {
50
+ "aria-label": a,
51
+ "aria-hidden": !a || void 0,
52
+ className: i(
53
+ u({ size: t, appearance: r, disabled: c }),
54
+ s && "absolute top-0 right-0 z-1"
55
+ )
56
+ }
57
+ ),
58
+ e
59
+ ]
60
+ }
61
+ );
62
+ }
63
+ v.displayName = "DotIndicator";
64
+ export {
65
+ v as DotIndicator
66
+ };
@@ -0,0 +1,3 @@
1
+ export * from './DotIndicator';
2
+ export * from './types';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/Components/DotIndicator/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,SAAS,CAAC"}
@@ -0,0 +1,24 @@
1
+ import { ComponentPropsWithRef, ReactNode } from 'react';
2
+ export type DotIndicatorProps = {
3
+ /**
4
+ * The size of the dot indicator.
5
+ * @default 'sm'
6
+ */
7
+ size?: 'xs' | 'sm' | 'md';
8
+ /**
9
+ * The appearance of the dot indicator.
10
+ * @default 'base'
11
+ */
12
+ appearance?: 'base' | 'red';
13
+ /**
14
+ * Whether the dot indicator should show a disabled appearance.
15
+ * @default false
16
+ */
17
+ disabled?: boolean;
18
+ /**
19
+ * Can be used as a wrapper to any component in case you wish to overlay a dot indicator on top of it.
20
+ * If provided, it'll pin the dot indicator to the top-right of the child component passed.
21
+ */
22
+ children?: ReactNode;
23
+ } & Omit<ComponentPropsWithRef<'div'>, 'children'>;
24
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/lib/Components/DotIndicator/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAE9D,MAAM,MAAM,iBAAiB,GAAG;IAC9B;;;OAGG;IACH,IAAI,CAAC,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;IAC1B;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,GAAG,KAAK,CAAC;IAC5B;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB;;;OAGG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;CACtB,GAAG,IAAI,CAAC,qBAAqB,CAAC,KAAK,CAAC,EAAE,UAAU,CAAC,CAAC"}
@@ -12,7 +12,9 @@ export * from './Checkbox';
12
12
  export * from './DataTable';
13
13
  export * from './Dialog';
14
14
  export * from './Divider';
15
+ export * from './DotCount';
15
16
  export * from './DotIcon';
17
+ export * from './DotIndicator';
16
18
  export * from './DotSymbol';
17
19
  export * from './IconButton';
18
20
  export * from './InteractiveIcon';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/lib/Components/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,eAAe,CAAC;AAC9B,cAAc,iBAAiB,CAAC;AAChC,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,UAAU,CAAC;AACzB,cAAc,QAAQ,CAAC;AACvB,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,QAAQ,CAAC;AACvB,cAAc,YAAY,CAAC;AAC3B,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC;AAC9B,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAC9B,cAAc,oBAAoB,CAAC;AACnC,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,YAAY,CAAC;AAC3B,cAAc,WAAW,CAAC;AAC1B,cAAc,QAAQ,CAAC;AACvB,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,UAAU,CAAC;AACzB,cAAc,SAAS,CAAC;AACxB,cAAc,OAAO,CAAC;AACtB,cAAc,aAAa,CAAC;AAC5B,cAAc,QAAQ,CAAC;AACvB,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/lib/Components/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,eAAe,CAAC;AAC9B,cAAc,iBAAiB,CAAC;AAChC,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,UAAU,CAAC;AACzB,cAAc,QAAQ,CAAC;AACvB,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,cAAc,YAAY,CAAC;AAC3B,cAAc,aAAa,CAAC;AAC5B,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,YAAY,CAAC;AAC3B,cAAc,WAAW,CAAC;AAC1B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,QAAQ,CAAC;AACvB,cAAc,YAAY,CAAC;AAC3B,cAAc,eAAe,CAAC;AAC9B,cAAc,eAAe,CAAC;AAC9B,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAC9B,cAAc,oBAAoB,CAAC;AACnC,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,YAAY,CAAC;AAC3B,cAAc,WAAW,CAAC;AAC1B,cAAc,QAAQ,CAAC;AACvB,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,UAAU,CAAC;AACzB,cAAc,SAAS,CAAC;AACxB,cAAc,OAAO,CAAC;AACtB,cAAc,aAAa,CAAC;AAC5B,cAAc,QAAQ,CAAC;AACvB,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,iBAAiB,CAAC"}
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ledgerhq/lumen-ui-react",
3
- "version": "0.1.23",
3
+ "version": "0.1.24",
4
4
  "license": "Apache-2.0",
5
5
  "sideEffects": false,
6
6
  "keywords": [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ledgerhq/lumen-ui-react",
3
- "version": "0.1.24",
3
+ "version": "0.1.25",
4
4
  "license": "Apache-2.0",
5
5
  "sideEffects": false,
6
6
  "keywords": [