@ledgerhq/lumen-ui-react 0.1.63 → 0.1.64
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/ai-rules/RULES.md +1 -1
- package/dist/index.js +79 -77
- package/dist/lib/Components/core/ContentBanner/ContentBanner.d.ts +1 -1
- package/dist/lib/Components/core/ListItem/ListItem.d.ts +1 -1
- package/dist/lib/Components/core/Spot/Spot.d.ts +7 -25
- package/dist/lib/Components/core/Spot/Spot.d.ts.map +1 -1
- package/dist/lib/Components/core/Spot/Spot.js +33 -102
- package/dist/lib/Components/core/Spot/SpotNumber.d.ts +16 -0
- package/dist/lib/Components/core/Spot/SpotNumber.d.ts.map +1 -0
- package/dist/lib/Components/core/Spot/SpotNumber.js +46 -0
- package/dist/lib/Components/core/Spot/index.d.ts +1 -0
- package/dist/lib/Components/core/Spot/index.d.ts.map +1 -1
- package/dist/lib/Components/core/Spot/styles.d.ts +14 -0
- package/dist/lib/Components/core/Spot/styles.d.ts.map +1 -0
- package/dist/lib/Components/core/Spot/styles.js +275 -0
- package/dist/lib/Components/core/Spot/types.d.ts +27 -38
- package/dist/lib/Components/core/Spot/types.d.ts.map +1 -1
- package/dist/lib/Components/core/Table/Table.d.ts.map +1 -1
- package/dist/lib/Components/core/Table/Table.js +64 -63
- package/dist/lib/Components/core/Tile/Tile.d.ts +2 -2
- package/dist/lib/Components/symbols/icons/AiBubble.d.ts +29 -0
- package/dist/lib/Components/symbols/icons/AiBubble.d.ts.map +1 -0
- package/dist/lib/Components/symbols/icons/AiBubble.js +30 -0
- package/dist/lib/Components/symbols/icons/ArrowBottomLeft.d.ts +29 -0
- package/dist/lib/Components/symbols/icons/ArrowBottomLeft.d.ts.map +1 -0
- package/dist/lib/Components/symbols/icons/ArrowBottomLeft.js +27 -0
- package/dist/lib/Components/symbols/icons/Bug.js +3 -3
- package/dist/lib/Components/symbols/icons/Hourglass.d.ts +29 -0
- package/dist/lib/Components/symbols/icons/Hourglass.d.ts.map +1 -0
- package/dist/lib/Components/symbols/icons/Hourglass.js +27 -0
- package/dist/lib/Components/symbols/icons/Repeat.d.ts +29 -0
- package/dist/lib/Components/symbols/icons/Repeat.d.ts.map +1 -0
- package/dist/lib/Components/symbols/icons/Repeat.js +27 -0
- package/dist/lib/Components/symbols/icons/Robot.d.ts +29 -0
- package/dist/lib/Components/symbols/icons/Robot.d.ts.map +1 -0
- package/dist/lib/Components/symbols/icons/Robot.js +29 -0
- package/dist/lib/Components/symbols/icons/Switch.d.ts.map +1 -1
- package/dist/lib/Components/symbols/icons/Switch.js +24 -12
- package/dist/lib/Components/symbols/icons/Wifi.d.ts +29 -0
- package/dist/lib/Components/symbols/icons/Wifi.d.ts.map +1 -0
- package/dist/lib/Components/symbols/icons/Wifi.js +36 -0
- package/dist/lib/Components/symbols/index.d.ts +6 -0
- package/dist/lib/Components/symbols/index.d.ts.map +1 -1
- package/dist/lib/Components/symbols/index.js +610 -598
- package/dist/package.json +2 -2
- package/package.json +2 -2
package/ai-rules/RULES.md
CHANGED
|
@@ -224,7 +224,7 @@ const InteractiveList = () => (
|
|
|
224
224
|
{items.map((item) => (
|
|
225
225
|
<ListItem>
|
|
226
226
|
<ListItemLeading>
|
|
227
|
-
<Spot
|
|
227
|
+
<Spot icon={Settings} />
|
|
228
228
|
<ListItemContent>
|
|
229
229
|
<ListItemTitle>Simple composition</ListItemTitle>
|
|
230
230
|
<ListItemDescription>With description</ListItemDescription>
|
package/dist/index.js
CHANGED
|
@@ -48,22 +48,23 @@ import { SideBar as nt, SideBarCollapseToggle as at, SideBarItem as it, SideBarL
|
|
|
48
48
|
import { Skeleton as dt } from "./lib/Components/core/Skeleton/Skeleton.js";
|
|
49
49
|
import { Spinner as ft } from "./lib/Components/core/Spinner/Spinner.js";
|
|
50
50
|
import { Spot as ct } from "./lib/Components/core/Spot/Spot.js";
|
|
51
|
-
import {
|
|
52
|
-
import {
|
|
53
|
-
import {
|
|
54
|
-
import {
|
|
55
|
-
import {
|
|
56
|
-
import {
|
|
57
|
-
import {
|
|
58
|
-
import {
|
|
59
|
-
import {
|
|
60
|
-
import {
|
|
61
|
-
import {
|
|
62
|
-
import {
|
|
63
|
-
import {
|
|
64
|
-
import {
|
|
65
|
-
import {
|
|
66
|
-
import {
|
|
51
|
+
import { SpotNumber as ut } from "./lib/Components/core/Spot/SpotNumber.js";
|
|
52
|
+
import { Stepper as It } from "./lib/Components/core/Stepper/Stepper.js";
|
|
53
|
+
import { Subheader as st, SubheaderCount as Bt, SubheaderDescription as Dt, SubheaderInfo as Mt, SubheaderRow as Lt, SubheaderShowMore as vt, SubheaderTitle as ht } from "./lib/Components/core/Subheader/Subheader.js";
|
|
54
|
+
import { Switch as wt } from "./lib/Components/core/Switch/Switch.js";
|
|
55
|
+
import { Table as At, TableActionBar as Pt, TableActionBarLeading as yt, TableActionBarTrailing as Nt, TableBody as kt, TableCell as Gt, TableCellContent as Et, TableCellContentDescription as Ft, TableCellContentRow as Ot, TableCellContentTitle as zt, TableCellItem as Vt, TableCol as _t, TableColGroup as jt, TableGroupHeaderRow as qt, TableHeader as Jt, TableHeaderCell as Kt, TableHeaderRow as Qt, TableInfoIcon as Ut, TableLoadingRow as Wt, TableRoot as Xt, TableRow as Yt, TableSortButton as Zt } from "./lib/Components/core/Table/Table.js";
|
|
56
|
+
import { Tag as er } from "./lib/Components/core/Tag/Tag.js";
|
|
57
|
+
import { TextInput as tr } from "./lib/Components/core/TextInput/TextInput.js";
|
|
58
|
+
import { Tile as nr, TileContent as ar, TileDescription as ir, TileSecondaryAction as lr, TileTitle as mr, TileTrailingContent as pr } from "./lib/Components/core/Tile/Tile.js";
|
|
59
|
+
import { TileButton as dr } from "./lib/Components/core/TileButton/TileButton.js";
|
|
60
|
+
import { Timeline as fr, TimelineItem as Cr, TimelineItemBody as cr, TimelineItemCaption as Sr, TimelineItemDescription as ur, TimelineItemHeader as gr, TimelineItemLeading as Ir, TimelineItemLeadingRow as br, TimelineItemTitle as sr, TimelineItemTrailing as Br } from "./lib/Components/core/Timeline/Timeline.js";
|
|
61
|
+
import { toast as Mr } from "./libs/utils-shared/dist/index.js";
|
|
62
|
+
import { Toast as vr } from "./lib/Components/core/Toast/Toast.js";
|
|
63
|
+
import { Toaster as Rr } from "./lib/Components/core/Toast/Toaster.js";
|
|
64
|
+
import { Tooltip as Hr, TooltipContent as Ar, TooltipProvider as Pr, TooltipTrigger as yr } from "./lib/Components/core/Tooltip/Tooltip.js";
|
|
65
|
+
import { Trend as kr } from "./lib/Components/core/Trend/Trend.js";
|
|
66
|
+
import { ThemeProvider as Er, useTheme as Fr } from "./lib/Components/core/ThemeProvider/ThemeProvider.js";
|
|
67
|
+
import { COLOR_SCHEMES as zr } from "./lib/Components/core/ThemeProvider/ThemeProvider.types.js";
|
|
67
68
|
export {
|
|
68
69
|
i as AddressInput,
|
|
69
70
|
T as AmountDisplay,
|
|
@@ -72,7 +73,7 @@ export {
|
|
|
72
73
|
S as AvatarButton,
|
|
73
74
|
g as Banner,
|
|
74
75
|
b as Button,
|
|
75
|
-
|
|
76
|
+
zr as COLOR_SCHEMES,
|
|
76
77
|
B as Card,
|
|
77
78
|
y as CardButton,
|
|
78
79
|
D as CardContent,
|
|
@@ -180,64 +181,65 @@ export {
|
|
|
180
181
|
dt as Skeleton,
|
|
181
182
|
ft as Spinner,
|
|
182
183
|
ct as Spot,
|
|
183
|
-
ut as
|
|
184
|
-
It as
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
ht as
|
|
192
|
-
wt as
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
Zt as
|
|
215
|
-
er as
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
vr as
|
|
236
|
-
Rr as
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
yr as
|
|
184
|
+
ut as SpotNumber,
|
|
185
|
+
It as Stepper,
|
|
186
|
+
st as Subheader,
|
|
187
|
+
Bt as SubheaderCount,
|
|
188
|
+
Dt as SubheaderDescription,
|
|
189
|
+
Mt as SubheaderInfo,
|
|
190
|
+
Lt as SubheaderRow,
|
|
191
|
+
vt as SubheaderShowMore,
|
|
192
|
+
ht as SubheaderTitle,
|
|
193
|
+
wt as Switch,
|
|
194
|
+
At as Table,
|
|
195
|
+
Pt as TableActionBar,
|
|
196
|
+
yt as TableActionBarLeading,
|
|
197
|
+
Nt as TableActionBarTrailing,
|
|
198
|
+
kt as TableBody,
|
|
199
|
+
Gt as TableCell,
|
|
200
|
+
Et as TableCellContent,
|
|
201
|
+
Ft as TableCellContentDescription,
|
|
202
|
+
Ot as TableCellContentRow,
|
|
203
|
+
zt as TableCellContentTitle,
|
|
204
|
+
Vt as TableCellItem,
|
|
205
|
+
_t as TableCol,
|
|
206
|
+
jt as TableColGroup,
|
|
207
|
+
qt as TableGroupHeaderRow,
|
|
208
|
+
Jt as TableHeader,
|
|
209
|
+
Kt as TableHeaderCell,
|
|
210
|
+
Qt as TableHeaderRow,
|
|
211
|
+
Ut as TableInfoIcon,
|
|
212
|
+
Wt as TableLoadingRow,
|
|
213
|
+
Xt as TableRoot,
|
|
214
|
+
Yt as TableRow,
|
|
215
|
+
Zt as TableSortButton,
|
|
216
|
+
er as Tag,
|
|
217
|
+
tr as TextInput,
|
|
218
|
+
Er as ThemeProvider,
|
|
219
|
+
nr as Tile,
|
|
220
|
+
dr as TileButton,
|
|
221
|
+
ar as TileContent,
|
|
222
|
+
ir as TileDescription,
|
|
223
|
+
lr as TileSecondaryAction,
|
|
224
|
+
mr as TileTitle,
|
|
225
|
+
pr as TileTrailingContent,
|
|
226
|
+
fr as Timeline,
|
|
227
|
+
Cr as TimelineItem,
|
|
228
|
+
cr as TimelineItemBody,
|
|
229
|
+
Sr as TimelineItemCaption,
|
|
230
|
+
ur as TimelineItemDescription,
|
|
231
|
+
gr as TimelineItemHeader,
|
|
232
|
+
Ir as TimelineItemLeading,
|
|
233
|
+
br as TimelineItemLeadingRow,
|
|
234
|
+
sr as TimelineItemTitle,
|
|
235
|
+
Br as TimelineItemTrailing,
|
|
236
|
+
vr as Toast,
|
|
237
|
+
Rr as Toaster,
|
|
238
|
+
Hr as Tooltip,
|
|
239
|
+
Ar as TooltipContent,
|
|
240
|
+
Pr as TooltipProvider,
|
|
241
|
+
yr as TooltipTrigger,
|
|
242
|
+
kr as Trend,
|
|
241
243
|
So as createMenuRadioGroup,
|
|
242
244
|
wo as createPopoverHandle,
|
|
243
245
|
jo as createSegmentedControl,
|
|
@@ -248,8 +250,8 @@ export {
|
|
|
248
250
|
Be as getDotIndicatorProps,
|
|
249
251
|
ve as getDotSymbolProps,
|
|
250
252
|
C as resolveAvatarColor,
|
|
251
|
-
|
|
253
|
+
Mr as toast,
|
|
252
254
|
n as useControllableState,
|
|
253
255
|
K as useLumenDataTable,
|
|
254
|
-
|
|
256
|
+
Fr as useTheme
|
|
255
257
|
};
|
|
@@ -19,7 +19,7 @@ export declare const ContentBannerDescription: ({ ref, children, className, ...p
|
|
|
19
19
|
* import { ContentBanner, ContentBannerContent, ContentBannerTitle, ContentBannerDescription } from '@ledgerhq/lumen-ui-react';
|
|
20
20
|
*
|
|
21
21
|
* <ContentBanner onClose={() => {}}>
|
|
22
|
-
* <Spot
|
|
22
|
+
* <Spot icon={Wallet} size={48} />
|
|
23
23
|
* <ContentBannerContent>
|
|
24
24
|
* <ContentBannerTitle>Title</ContentBannerTitle>
|
|
25
25
|
* <ContentBannerDescription>Description text</ContentBannerDescription>
|
|
@@ -9,7 +9,7 @@ import { ListItemContentProps, ListItemDescriptionProps, ListItemLeadingProps, L
|
|
|
9
9
|
*
|
|
10
10
|
* <ListItem onClick={() => console.log('Clicked!')}>
|
|
11
11
|
* <ListItemLeading>
|
|
12
|
-
* <Spot size={48}
|
|
12
|
+
* <Spot size={48} icon={Wallet} />
|
|
13
13
|
* <ListItemContent>
|
|
14
14
|
* <ListItemTitle>Balance</ListItemTitle>
|
|
15
15
|
* <ListItemDescription>Optional description</ListItemDescription>
|
|
@@ -1,37 +1,19 @@
|
|
|
1
1
|
import { SpotProps } from './types';
|
|
2
2
|
/**
|
|
3
|
-
* A circular
|
|
4
|
-
*
|
|
5
|
-
* Uses a discriminated union type system where the required props depend on the `appearance` value:
|
|
6
|
-
* - `'icon'` appearance requires an `icon` prop
|
|
7
|
-
* - `'number'` appearance requires a `number` prop
|
|
8
|
-
* - All other appearances are self-contained
|
|
3
|
+
* A circular icon container. `appearance` selects the color palette and `fill` selects whether that palette paints only the icon or the circle as well.
|
|
9
4
|
*
|
|
10
5
|
* @see {@link https://ldls.vercel.app/?path=/docs/react-spot--docs Storybook}
|
|
11
6
|
*
|
|
12
7
|
* @warning The `className` prop should only be used for layout adjustments like margins or positioning.
|
|
13
|
-
* Do not use it to modify the spot's core appearance (colors, size, etc). Use the `appearance`
|
|
8
|
+
* Do not use it to modify the spot's core appearance (colors, size, etc). Use the `appearance` and `fill` props instead.
|
|
14
9
|
*
|
|
15
10
|
* @example
|
|
16
11
|
* import { Spot } from '@ledgerhq/lumen-ui-react';
|
|
12
|
+
* import { Settings, CheckmarkCircleFill } from '@ledgerhq/lumen-ui-react/symbols';
|
|
17
13
|
*
|
|
18
|
-
*
|
|
19
|
-
*
|
|
20
|
-
*
|
|
21
|
-
* <Spot appearance="icon" icon={Settings} />
|
|
22
|
-
*
|
|
23
|
-
* // Number spot
|
|
24
|
-
* <Spot appearance="number" number={5} />
|
|
25
|
-
*
|
|
26
|
-
* // Status indicators (no additional props needed)
|
|
27
|
-
* <Spot appearance="check" />
|
|
28
|
-
* <Spot appearance="error" />
|
|
29
|
-
* <Spot appearance="warning" />
|
|
30
|
-
* <Spot appearance="loader" />
|
|
31
|
-
*
|
|
32
|
-
* // Bluetooth states
|
|
33
|
-
* <Spot appearance="bluetooth" />
|
|
34
|
-
* <Spot appearance="bluetooth" disabled />
|
|
14
|
+
* <Spot icon={Settings} />
|
|
15
|
+
* <Spot appearance="success" icon={CheckmarkCircleFill} />
|
|
16
|
+
* <Spot appearance="success" fill="plain" icon={Settings} />
|
|
35
17
|
*/
|
|
36
|
-
export declare const Spot: (
|
|
18
|
+
export declare const Spot: ({ appearance, fill, icon: Icon, disabled: disabledProp, size, className, ref, ...rest }: SpotProps) => import("react/jsx-runtime").JSX.Element;
|
|
37
19
|
//# sourceMappingURL=Spot.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Spot.d.ts","sourceRoot":"","sources":["../../../../../src/lib/Components/core/Spot/Spot.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Spot.d.ts","sourceRoot":"","sources":["../../../../../src/lib/Components/core/Spot/Spot.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,SAAS,EAAY,MAAM,SAAS,CAAC;AAUnD;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,IAAI,GAAI,yFASlB,SAAS,4CAuBX,CAAC"}
|
|
@@ -1,112 +1,43 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { useDisabledContext as
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
info: "text-muted",
|
|
22
|
-
loader: "",
|
|
23
|
-
number: "heading-5 text-base"
|
|
24
|
-
},
|
|
25
|
-
disabled: {
|
|
26
|
-
true: "text-disabled"
|
|
27
|
-
},
|
|
28
|
-
size: {
|
|
29
|
-
32: "spot-h-32 spot-w-32",
|
|
30
|
-
40: "spot-h-40 spot-w-40",
|
|
31
|
-
48: "spot-h-48 spot-w-48",
|
|
32
|
-
56: "spot-h-56 spot-w-56",
|
|
33
|
-
72: "spot-h-72 spot-w-72"
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
), G = (t) => {
|
|
38
|
-
const s = t.size ?? 48, i = {
|
|
39
|
-
32: 12,
|
|
40
|
-
40: 16,
|
|
41
|
-
48: 20,
|
|
42
|
-
56: 24,
|
|
43
|
-
72: 40
|
|
44
|
-
}, c = {
|
|
45
|
-
32: "body-2-semi-bold",
|
|
46
|
-
40: "body-1-semi-bold",
|
|
47
|
-
48: "heading-5",
|
|
48
|
-
56: "heading-4",
|
|
49
|
-
72: "heading-2"
|
|
50
|
-
}, o = i[s] ?? 20, a = c[s] ?? "heading-5", { componentProps: m, content: p } = F(() => {
|
|
51
|
-
if (t.appearance === "icon") {
|
|
52
|
-
const { icon: n, ...r } = t;
|
|
53
|
-
return {
|
|
54
|
-
componentProps: r,
|
|
55
|
-
content: /* @__PURE__ */ e(n, { size: o })
|
|
56
|
-
};
|
|
57
|
-
}
|
|
58
|
-
if (t.appearance === "number") {
|
|
59
|
-
const { number: n, ...r } = t;
|
|
60
|
-
return {
|
|
61
|
-
componentProps: r,
|
|
62
|
-
content: /* @__PURE__ */ e("span", { className: a, children: n })
|
|
63
|
-
};
|
|
64
|
-
}
|
|
65
|
-
const z = (() => {
|
|
66
|
-
switch (t.appearance) {
|
|
67
|
-
case "bluetooth":
|
|
68
|
-
return /* @__PURE__ */ e(v, { size: o });
|
|
69
|
-
case "check":
|
|
70
|
-
return /* @__PURE__ */ e(S, { size: o });
|
|
71
|
-
case "error":
|
|
72
|
-
return /* @__PURE__ */ e(k, { size: o });
|
|
73
|
-
case "warning":
|
|
74
|
-
return /* @__PURE__ */ e(N, { size: o });
|
|
75
|
-
case "info":
|
|
76
|
-
return /* @__PURE__ */ e(C, { size: o });
|
|
77
|
-
case "loader":
|
|
78
|
-
return /* @__PURE__ */ e(P, { size: o });
|
|
79
|
-
}
|
|
80
|
-
})();
|
|
81
|
-
return { componentProps: t, content: z };
|
|
82
|
-
}, [t, o, a]), {
|
|
83
|
-
appearance: l,
|
|
84
|
-
className: d,
|
|
85
|
-
disabled: u = !1,
|
|
86
|
-
size: h = 48,
|
|
87
|
-
ref: b,
|
|
88
|
-
...f
|
|
89
|
-
} = m, g = x({
|
|
1
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { useDisabledContext as l, cn as p } from "../../../../libs/utils-shared/dist/index.js";
|
|
3
|
+
import { contentVariants as b, spotVariants as N } from "./styles.js";
|
|
4
|
+
const f = {
|
|
5
|
+
32: 12,
|
|
6
|
+
40: 16,
|
|
7
|
+
48: 20,
|
|
8
|
+
56: 24,
|
|
9
|
+
72: 40
|
|
10
|
+
}, h = ({
|
|
11
|
+
appearance: s = "base",
|
|
12
|
+
fill: t = "transparent",
|
|
13
|
+
icon: a,
|
|
14
|
+
disabled: n = !1,
|
|
15
|
+
size: e = 48,
|
|
16
|
+
className: r,
|
|
17
|
+
ref: i,
|
|
18
|
+
...c
|
|
19
|
+
}) => {
|
|
20
|
+
const m = l({
|
|
90
21
|
consumerName: "Spot",
|
|
91
|
-
mergeWith: { disabled:
|
|
92
|
-
});
|
|
93
|
-
return /* @__PURE__ */
|
|
22
|
+
mergeWith: { disabled: n }
|
|
23
|
+
}), d = b({ appearance: s, fill: t, disabled: m });
|
|
24
|
+
return /* @__PURE__ */ o(
|
|
94
25
|
"div",
|
|
95
26
|
{
|
|
96
|
-
ref:
|
|
97
|
-
className:
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
size:
|
|
27
|
+
ref: i,
|
|
28
|
+
className: p(
|
|
29
|
+
N({
|
|
30
|
+
appearance: s,
|
|
31
|
+
fill: t,
|
|
32
|
+
size: e
|
|
102
33
|
}),
|
|
103
|
-
|
|
34
|
+
r
|
|
104
35
|
),
|
|
105
|
-
...
|
|
106
|
-
children:
|
|
36
|
+
...c,
|
|
37
|
+
children: /* @__PURE__ */ o(a, { size: f[e], className: d })
|
|
107
38
|
}
|
|
108
39
|
);
|
|
109
40
|
};
|
|
110
41
|
export {
|
|
111
|
-
|
|
42
|
+
h as Spot
|
|
112
43
|
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { SpotNumberProps } from './types';
|
|
2
|
+
/**
|
|
3
|
+
* A circular digit. Uses the same palette, fill, and size as `Spot`.
|
|
4
|
+
*
|
|
5
|
+
* @see {@link https://ldls.vercel.app/?path=/docs/react-spot--docs Storybook}
|
|
6
|
+
*
|
|
7
|
+
* @warning The `className` prop should only be used for layout adjustments like margins or positioning.
|
|
8
|
+
* Do not use it to modify the circle's core appearance (colors, size, etc). Use the `appearance` and `fill` props instead.
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* import { SpotNumber } from '@ledgerhq/lumen-ui-react';
|
|
12
|
+
*
|
|
13
|
+
* <SpotNumber value={9} />
|
|
14
|
+
*/
|
|
15
|
+
export declare const SpotNumber: ({ appearance, fill, value, disabled: disabledProp, size, className, ref, ...rest }: SpotNumberProps) => import("react/jsx-runtime").JSX.Element;
|
|
16
|
+
//# sourceMappingURL=SpotNumber.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SpotNumber.d.ts","sourceRoot":"","sources":["../../../../../src/lib/Components/core/Spot/SpotNumber.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AAE/C;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,UAAU,GAAI,oFASxB,eAAe,4CA6BjB,CAAC"}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import { useDisabledContext as c, cn as a } from "../../../../libs/utils-shared/dist/index.js";
|
|
3
|
+
import { contentVariants as l, numberVariants as p, spotVariants as u } from "./styles.js";
|
|
4
|
+
const x = ({
|
|
5
|
+
appearance: s = "base",
|
|
6
|
+
fill: t = "transparent",
|
|
7
|
+
value: n,
|
|
8
|
+
disabled: o = !1,
|
|
9
|
+
size: e = 48,
|
|
10
|
+
className: m,
|
|
11
|
+
ref: i,
|
|
12
|
+
...d
|
|
13
|
+
}) => {
|
|
14
|
+
const b = c({
|
|
15
|
+
consumerName: "SpotNumber",
|
|
16
|
+
mergeWith: { disabled: o }
|
|
17
|
+
});
|
|
18
|
+
return /* @__PURE__ */ r(
|
|
19
|
+
"div",
|
|
20
|
+
{
|
|
21
|
+
ref: i,
|
|
22
|
+
className: a(
|
|
23
|
+
u({
|
|
24
|
+
appearance: s,
|
|
25
|
+
fill: t,
|
|
26
|
+
size: e
|
|
27
|
+
}),
|
|
28
|
+
m
|
|
29
|
+
),
|
|
30
|
+
...d,
|
|
31
|
+
children: /* @__PURE__ */ r(
|
|
32
|
+
"span",
|
|
33
|
+
{
|
|
34
|
+
className: a(
|
|
35
|
+
p({ size: e }),
|
|
36
|
+
l({ appearance: s, fill: t, disabled: b })
|
|
37
|
+
),
|
|
38
|
+
children: n
|
|
39
|
+
}
|
|
40
|
+
)
|
|
41
|
+
}
|
|
42
|
+
);
|
|
43
|
+
};
|
|
44
|
+
export {
|
|
45
|
+
x as SpotNumber
|
|
46
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/lib/Components/core/Spot/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,cAAc,SAAS,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/lib/Components/core/Spot/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,cAAc,SAAS,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export declare const spotVariants: (props?: ({
|
|
2
|
+
fill?: "transparent" | "plain" | null | undefined;
|
|
3
|
+
appearance?: "base" | "muted" | "error" | "success" | "warning" | "decorative-blue" | "decorative-pink" | "decorative-purple" | "decorative-green" | "decorative-turquoise" | "decorative-yellow" | "decorative-orange" | "decorative-red" | null | undefined;
|
|
4
|
+
size?: 32 | 40 | 48 | 56 | 72 | null | undefined;
|
|
5
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
6
|
+
export declare const contentVariants: (props?: ({
|
|
7
|
+
fill?: "transparent" | "plain" | null | undefined;
|
|
8
|
+
appearance?: "base" | "muted" | "error" | "success" | "warning" | "decorative-blue" | "decorative-pink" | "decorative-purple" | "decorative-green" | "decorative-turquoise" | "decorative-yellow" | "decorative-orange" | "decorative-red" | null | undefined;
|
|
9
|
+
disabled?: boolean | null | undefined;
|
|
10
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
11
|
+
export declare const numberVariants: (props?: ({
|
|
12
|
+
size?: 32 | 40 | 48 | 56 | 72 | null | undefined;
|
|
13
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
14
|
+
//# sourceMappingURL=styles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../../../src/lib/Components/core/Spot/styles.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,YAAY;;;;8EA+ExB,CAAC;AAEF,eAAO,MAAM,eAAe;;;;8EAmL1B,CAAC;AAEH,eAAO,MAAM,cAAc;;8EAUzB,CAAC"}
|