@liner-fe/design-library 1.2.8 → 1.2.10
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/lib/index.d.ts +1 -25
- package/lib/index.js +5 -90
- package/package.json +4 -4
package/lib/index.d.ts
CHANGED
|
@@ -2,7 +2,6 @@ import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
|
2
2
|
import { ButtonProps, TextButtonProps } from '@liner-fe/prism';
|
|
3
3
|
import { ClassValue } from 'clsx';
|
|
4
4
|
import { ReactNode } from 'react';
|
|
5
|
-
import { Popover } from 'radix-ui';
|
|
6
5
|
|
|
7
6
|
declare const TemplateDialog: {
|
|
8
7
|
({ open, preventEscape, onOpenChange, children, }: {
|
|
@@ -59,27 +58,4 @@ declare const TemplateIllustDialog: {
|
|
|
59
58
|
TextButton({ children, className, ...props }: TextButtonProps): react_jsx_runtime.JSX.Element;
|
|
60
59
|
};
|
|
61
60
|
|
|
62
|
-
|
|
63
|
-
title: string;
|
|
64
|
-
description: string;
|
|
65
|
-
leftSlot?: ReactNode;
|
|
66
|
-
footer?: {
|
|
67
|
-
currentStep: number;
|
|
68
|
-
totalStep: number;
|
|
69
|
-
buttonText: string;
|
|
70
|
-
onButtonClick: () => void;
|
|
71
|
-
};
|
|
72
|
-
}
|
|
73
|
-
declare const TemplateTutorialGuide: ({ position, isOpen, children, onClose, className, content, }: {
|
|
74
|
-
position: "top" | "right" | "bottom" | "left";
|
|
75
|
-
isOpen: boolean;
|
|
76
|
-
children: ReactNode;
|
|
77
|
-
onClose: () => void;
|
|
78
|
-
className?: {
|
|
79
|
-
trigger?: ClassValue;
|
|
80
|
-
content?: ClassValue;
|
|
81
|
-
};
|
|
82
|
-
content: ContentProps;
|
|
83
|
-
}) => react_jsx_runtime.JSX.Element;
|
|
84
|
-
|
|
85
|
-
export { TemplateDialog, TemplateIllustDialog, TemplateTutorialGuide };
|
|
61
|
+
export { TemplateDialog, TemplateIllustDialog };
|
package/lib/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { IconClose } from '@liner-fe/icon';
|
|
2
|
-
import { IconButton, Title, Paragraph, Button, TextButton
|
|
3
|
-
import { Dialog
|
|
2
|
+
import { IconButton, Title, Paragraph, Button, TextButton } from '@liner-fe/prism';
|
|
3
|
+
import { Dialog } from 'radix-ui';
|
|
4
4
|
import clsx from 'clsx';
|
|
5
5
|
import { twMerge } from 'tailwind-merge';
|
|
6
6
|
import { jsx, Fragment, jsxs } from 'react/jsx-runtime';
|
|
@@ -58,7 +58,7 @@ TemplateDialog.Close = ({ onClose }) => /* @__PURE__ */ jsx(
|
|
|
58
58
|
TemplateDialog.Title = ({
|
|
59
59
|
children,
|
|
60
60
|
className
|
|
61
|
-
}) => /* @__PURE__ */ jsx(Dialog.Title, { asChild: true, children: /* @__PURE__ */ jsx(Title, { type: "accent", weight: "bold", size: 4, className: tw(className), children }) });
|
|
61
|
+
}) => /* @__PURE__ */ jsx(Dialog.Title, { asChild: true, children: /* @__PURE__ */ jsx(Title, { type: "accent", weight: "bold", size: 4, className: tw("max-s:text-center", className), children }) });
|
|
62
62
|
TemplateDialog.Description = ({
|
|
63
63
|
children,
|
|
64
64
|
className
|
|
@@ -68,7 +68,7 @@ TemplateDialog.Description = ({
|
|
|
68
68
|
type: "normal",
|
|
69
69
|
weight: "regular",
|
|
70
70
|
size: 4,
|
|
71
|
-
className: tw("mt-component-200 text-neutral-label-primary/90!", className),
|
|
71
|
+
className: tw("mt-component-200 text-neutral-label-primary/90! max-s:text-center", className),
|
|
72
72
|
children
|
|
73
73
|
}
|
|
74
74
|
) });
|
|
@@ -181,90 +181,5 @@ TemplateIllustDialog.Buttons = ({
|
|
|
181
181
|
);
|
|
182
182
|
TemplateIllustDialog.Button = ({ children, className, ...props }) => /* @__PURE__ */ jsx(Button, { ...props, className: tw("w-full!", className), children });
|
|
183
183
|
TemplateIllustDialog.TextButton = ({ children, className, ...props }) => /* @__PURE__ */ jsx(TextButton, { ...props, className: tw(className), children });
|
|
184
|
-
var TemplateTutorialGuide = ({
|
|
185
|
-
position,
|
|
186
|
-
isOpen,
|
|
187
|
-
children,
|
|
188
|
-
onClose,
|
|
189
|
-
className,
|
|
190
|
-
content
|
|
191
|
-
}) => {
|
|
192
|
-
const { title, description, leftSlot, sideOffset = -5, footer, ...rest } = content;
|
|
193
|
-
return /* @__PURE__ */ jsxs(Popover.Root, { open: isOpen, children: [
|
|
194
|
-
/* @__PURE__ */ jsx(Popover.Trigger, { className: tw(className?.trigger), children }),
|
|
195
|
-
/* @__PURE__ */ jsx(
|
|
196
|
-
Popover.Content,
|
|
197
|
-
{
|
|
198
|
-
side: position,
|
|
199
|
-
className: tw(className?.content),
|
|
200
|
-
sideOffset,
|
|
201
|
-
asChild: true,
|
|
202
|
-
...rest,
|
|
203
|
-
children: /* @__PURE__ */ jsxs("div", { children: [
|
|
204
|
-
/* @__PURE__ */ jsxs(
|
|
205
|
-
"div",
|
|
206
|
-
{
|
|
207
|
-
className: tw(
|
|
208
|
-
"min-w-[250px] max-w-[350px] bg-neutral-container-lowest gap-positive-150 border-brand-border-opaque-strong py-component-300 px-component-400 relative flex flex-col rounded-xl border shadow-[0_0_4px_0_rgba(12,137,59,0.08),0_0_12px_0_rgba(12,137,59,0.12),0_0_12px_0_rgba(255,255,255,0.50)]",
|
|
209
|
-
leftSlot && "pl-component-300"
|
|
210
|
-
),
|
|
211
|
-
children: [
|
|
212
|
-
/* @__PURE__ */ jsx("button", { className: "absolute top-[8px] right-[8px]", onClick: onClose, children: /* @__PURE__ */ jsx(IconClose, { type: "neutral-label-secondary", size: "xs" }) }),
|
|
213
|
-
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-[12px]", children: [
|
|
214
|
-
leftSlot,
|
|
215
|
-
/* @__PURE__ */ jsxs("div", { className: "gap-positive-200 flex flex-col", children: [
|
|
216
|
-
/* @__PURE__ */ jsx(Caption, { type: "normal", weight: "medium", size: 1, children: title }),
|
|
217
|
-
/* @__PURE__ */ jsx(
|
|
218
|
-
Caption,
|
|
219
|
-
{
|
|
220
|
-
type: "normal",
|
|
221
|
-
weight: "regular",
|
|
222
|
-
size: 2,
|
|
223
|
-
className: "whitespace-pre-wrap opacity-70",
|
|
224
|
-
children: description
|
|
225
|
-
}
|
|
226
|
-
)
|
|
227
|
-
] })
|
|
228
|
-
] }),
|
|
229
|
-
footer && /* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between", children: [
|
|
230
|
-
/* @__PURE__ */ jsxs(
|
|
231
|
-
Caption,
|
|
232
|
-
{
|
|
233
|
-
type: "normal",
|
|
234
|
-
weight: "medium",
|
|
235
|
-
size: 2,
|
|
236
|
-
className: "pl-component-100",
|
|
237
|
-
color: "neutral-label-secondary",
|
|
238
|
-
children: [
|
|
239
|
-
footer.currentStep,
|
|
240
|
-
" / ",
|
|
241
|
-
footer.totalStep
|
|
242
|
-
]
|
|
243
|
-
}
|
|
244
|
-
),
|
|
245
|
-
/* @__PURE__ */ jsx(Button, { size: "s", level: "quaternary", onClick: footer.onButtonClick, children: footer.buttonText })
|
|
246
|
-
] })
|
|
247
|
-
]
|
|
248
|
-
}
|
|
249
|
-
),
|
|
250
|
-
/* @__PURE__ */ jsx(Popover.Arrow, { asChild: true, width: 8, height: 35, children: /* @__PURE__ */ jsxs(
|
|
251
|
-
"svg",
|
|
252
|
-
{
|
|
253
|
-
width: "8",
|
|
254
|
-
height: "35",
|
|
255
|
-
viewBox: "0 0 8 35",
|
|
256
|
-
fill: "none",
|
|
257
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
258
|
-
children: [
|
|
259
|
-
/* @__PURE__ */ jsx("rect", { width: "1", height: "28", transform: "translate(3.5)", fill: "#0C893B" }),
|
|
260
|
-
/* @__PURE__ */ jsx("circle", { cx: "4", cy: "31", r: "4", fill: "#0C893B" })
|
|
261
|
-
]
|
|
262
|
-
}
|
|
263
|
-
) })
|
|
264
|
-
] })
|
|
265
|
-
}
|
|
266
|
-
)
|
|
267
|
-
] });
|
|
268
|
-
};
|
|
269
184
|
|
|
270
|
-
export { TemplateDialog, TemplateIllustDialog
|
|
185
|
+
export { TemplateDialog, TemplateIllustDialog };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@liner-fe/design-library",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.10",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"dependencies": {
|
|
6
6
|
"@tailwindcss/vite": "^4.1.14",
|
|
@@ -10,9 +10,9 @@
|
|
|
10
10
|
"react-dom": "18.2.0",
|
|
11
11
|
"tailwind-merge": "^3.3.1",
|
|
12
12
|
"tailwindcss": "^4.1.14",
|
|
13
|
-
"@liner-fe/design-token": "^2.5.
|
|
14
|
-
"@liner-fe/icon": "^0.2.
|
|
15
|
-
"@liner-fe/prism": "^2.11.
|
|
13
|
+
"@liner-fe/design-token": "^2.5.36",
|
|
14
|
+
"@liner-fe/icon": "^0.2.57",
|
|
15
|
+
"@liner-fe/prism": "^2.11.6"
|
|
16
16
|
},
|
|
17
17
|
"devDependencies": {
|
|
18
18
|
"@chromatic-com/storybook": "^4.1.1",
|