@edu-tosel/design 1.0.34 → 1.0.36
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/board/{widget → design}/Board.design.js +2 -2
- package/board/template/CanvasBoard.js +1 -1
- package/board/template/ManageBoard.js +4 -4
- package/board/template/PaperBoard.js +3 -3
- package/card/{widget → design}/Card.design.js +4 -3
- package/card/{widget → design}/InfoCard.design.d.ts +1 -1
- package/card/design/InfoCard.design.js +24 -0
- package/card/design/TableCard.design.d.ts +2 -0
- package/card/{widget → design}/TableCard.design.js +4 -4
- package/card/template/AddCard.js +2 -2
- package/card/template/ChartCard.js +2 -2
- package/card/template/InfoCard/Exam.d.ts +2 -0
- package/card/template/InfoCard/Exam.js +18 -0
- package/card/template/InfoCard/ExamData.d.ts +8 -0
- package/card/template/InfoCard/ExamData.js +57 -0
- package/card/template/InfoCard/Finance.d.ts +24 -0
- package/card/template/InfoCard/Finance.js +53 -0
- package/card/template/InfoCard/Grade.d.ts +2 -0
- package/card/template/InfoCard/Grade.js +29 -0
- package/card/template/InfoCard/Item.d.ts +2 -0
- package/card/template/InfoCard/Item.js +10 -0
- package/card/template/InfoCard/PersonalInformation.d.ts +2 -0
- package/card/template/InfoCard/PersonalInformation.js +29 -0
- package/card/template/InfoCard/Product.d.ts +2 -0
- package/card/template/InfoCard/Product.js +24 -0
- package/card/template/InfoCard/index.d.ts +19 -0
- package/card/template/InfoCard/index.js +17 -0
- package/card/template/InfoCard/static/label.d.ts +3 -0
- package/card/template/InfoCard/static/label.js +3 -0
- package/card/template/NavCard.js +1 -1
- package/card/template/TableCard.d.ts +2 -4
- package/card/template/TableCard.js +1 -1
- package/globals.css +17 -5
- package/hook/useFlag.d.ts +4 -1
- package/hook/useFlag.js +5 -2
- package/html/{widget → design}/Label.design.js +1 -1
- package/html/{widget → design}/Select.design.js +17 -19
- package/html/template/Label.js +1 -1
- package/html/template/Select.js +1 -1
- package/html/widget/CheckBox.d.ts +2 -0
- package/html/widget/CheckBox.js +20 -0
- package/html/widget/Toggle.js +1 -1
- package/interface/Board.d.ts +4 -11
- package/interface/Card.d.ts +5 -11
- package/interface/HTMLElement.d.ts +6 -0
- package/interface/Layout.d.ts +1 -0
- package/interface/Modal.d.ts +1 -1
- package/interface/Property.d.ts +19 -2
- package/interface/Shelf.d.ts +2 -3
- package/interface/Widget.d.ts +3 -6
- package/layout/design/Row.design.d.ts +2 -0
- package/layout/{widget → design}/Row.design.js +6 -2
- package/layout/{widget → design}/Shelf.design.d.ts +1 -1
- package/layout/{widget → design}/Shelf.design.js +8 -6
- package/layout/template/DataField.js +1 -1
- package/layout/template/Gallery.js +1 -1
- package/layout/template/Row.d.ts +9 -10
- package/layout/template/Row.js +12 -6
- package/layout/template/Shelf.d.ts +1 -1
- package/layout/template/Shelf.js +15 -8
- package/layout/widget/dashboard/Header.js +3 -3
- package/modal/template/Alert.js +2 -2
- package/modal/template/Input.js +2 -2
- package/overlay/widget/Overlay.design.js +1 -1
- package/package.json +1 -1
- package/store/index.d.ts +4 -2
- package/store/index.js +2 -0
- package/tailwind.config.ts +5 -0
- package/util/sortByOrder.d.ts +4 -3
- package/util/sortByOrder.js +6 -6
- package/version.txt +1 -1
- package/card/template/InfoCard.d.ts +0 -20
- package/card/template/InfoCard.js +0 -155
- package/card/widget/InfoCard.design.js +0 -23
- package/card/widget/TableCard.design.d.ts +0 -4
- package/layout/widget/Row.design.d.ts +0 -2
- /package/board/{widget → design}/Board.design.d.ts +0 -0
- /package/card/{widget → design}/Card.design.d.ts +0 -0
- /package/card/{widget → design}/NavCard.design.d.ts +0 -0
- /package/card/{widget → design}/NavCard.design.js +0 -0
- /package/html/{widget → design}/Label.design.d.ts +0 -0
- /package/html/{widget → design}/Select.design.d.ts +0 -0
- /package/layout/{widget → design}/DataField.design.d.ts +0 -0
- /package/layout/{widget → design}/DataField.design.js +0 -0
- /package/layout/{widget → design}/Tab.design.d.ts +0 -0
- /package/layout/{widget → design}/Tab.design.js +0 -0
- /package/modal/{widget → design}/Modal.design.d.ts +0 -0
- /package/modal/{widget → design}/Modal.design.js +0 -0
package/hook/useFlag.js
CHANGED
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
import { useEffect } from "react";
|
|
2
2
|
import { useWidgetStore } from "../store";
|
|
3
|
-
export default function useFlag(state) {
|
|
3
|
+
export default function useFlag({ safe, state, }) {
|
|
4
4
|
const [value, action] = state;
|
|
5
5
|
const { flag, isOwn, setIsOwn } = useWidgetStore();
|
|
6
|
+
safe;
|
|
6
7
|
useEffect(() => {
|
|
7
8
|
if (isOwn) {
|
|
8
9
|
return setIsOwn(false);
|
|
9
10
|
}
|
|
10
|
-
|
|
11
|
+
else {
|
|
12
|
+
return action(value);
|
|
13
|
+
}
|
|
11
14
|
}, [flag]);
|
|
12
15
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { useState } from "react";
|
|
3
3
|
import { cn } from "../../util";
|
|
4
|
-
import Obstacle from "
|
|
4
|
+
import Obstacle from "../widget/Obstacle";
|
|
5
5
|
const widthSize = {
|
|
6
6
|
xs: "w-10",
|
|
7
7
|
sm: "w-22.5",
|
|
@@ -14,14 +14,15 @@ const heightSize = {
|
|
|
14
14
|
};
|
|
15
15
|
export default function SelectDesign({ state, selectOptions, placeholder, options, }) {
|
|
16
16
|
const id = useId();
|
|
17
|
-
const { setIsOwn } = useWidgetStore();
|
|
17
|
+
const { setIsOwn, setIsOwnId } = useWidgetStore();
|
|
18
18
|
const [value, setValue] = state;
|
|
19
19
|
const [text, setText] = useState("");
|
|
20
20
|
const [search, setSearch] = useState("");
|
|
21
21
|
const [isOpen, setIsOpen] = useState(false);
|
|
22
|
+
const [isHover, setIsHover] = useState(false);
|
|
22
23
|
const [filteredOptions, setFilterdOptions] = useState([]);
|
|
23
24
|
const [index, setIndex] = useState();
|
|
24
|
-
useFlag([false, setIsOpen]);
|
|
25
|
+
useFlag({ state: [false, setIsOpen], safe: "overlay" });
|
|
25
26
|
const onKeyDown = (e) => {
|
|
26
27
|
if (!filteredOptions)
|
|
27
28
|
return;
|
|
@@ -47,7 +48,8 @@ export default function SelectDesign({ state, selectOptions, placeholder, option
|
|
|
47
48
|
const button = {
|
|
48
49
|
displays: "flex items-center",
|
|
49
50
|
sizes: `${widthSize[options?.width ?? "md"]} ${heightSize[options?.height ?? "xs"]}`,
|
|
50
|
-
styles: "pl-1 rounded-md
|
|
51
|
+
styles: "pl-1 rounded-md focus:outline-none duration-100 text-gray-400",
|
|
52
|
+
shadow: isOpen || isHover ? "box-shadow" : "shadow-none",
|
|
51
53
|
};
|
|
52
54
|
const input = {
|
|
53
55
|
positions: "absolute",
|
|
@@ -55,7 +57,7 @@ export default function SelectDesign({ state, selectOptions, placeholder, option
|
|
|
55
57
|
styles: "focus:outline-none text-xs pl-1.5",
|
|
56
58
|
};
|
|
57
59
|
const body = {
|
|
58
|
-
positions: "absolute",
|
|
60
|
+
positions: "absolute z-40",
|
|
59
61
|
displays: "flex flex-col gap-1",
|
|
60
62
|
sizes: `${widthSize[options?.width ?? "md"]} min-h-6.5 max-h-23.75`,
|
|
61
63
|
paddings: "pl-1 py-1",
|
|
@@ -70,37 +72,33 @@ export default function SelectDesign({ state, selectOptions, placeholder, option
|
|
|
70
72
|
};
|
|
71
73
|
const inputTransition = useTransition(isOpen, {
|
|
72
74
|
from: {
|
|
73
|
-
|
|
74
|
-
top: 0,
|
|
75
|
+
top: 32,
|
|
75
76
|
},
|
|
76
77
|
enter: {
|
|
77
|
-
opacity: 1,
|
|
78
78
|
top: 32,
|
|
79
|
-
config: { duration: 150 },
|
|
80
79
|
},
|
|
81
80
|
leave: {
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
81
|
+
top: 32,
|
|
82
|
+
},
|
|
83
|
+
config: {
|
|
84
|
+
duration: 0,
|
|
85
85
|
},
|
|
86
86
|
});
|
|
87
87
|
const bodyTransitions = useTransition(isOpen, {
|
|
88
88
|
from: {
|
|
89
|
-
|
|
90
|
-
top: 0,
|
|
89
|
+
top: isLong ? 64 : 32,
|
|
91
90
|
},
|
|
92
91
|
enter: {
|
|
93
|
-
opacity: 1,
|
|
94
92
|
top: isLong ? 64 : 32,
|
|
95
|
-
config: { duration: 150 },
|
|
96
93
|
},
|
|
97
94
|
leave: {
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
95
|
+
top: isLong ? 64 : 32,
|
|
96
|
+
},
|
|
97
|
+
config: {
|
|
98
|
+
duration: 0,
|
|
101
99
|
},
|
|
102
100
|
});
|
|
103
|
-
return (_jsxs("div", { className: cn(container), onKeyDown: onKeyDown, onClick: () => setIsOwn(true), children: [_jsx("button", { onClick: () => setIsOpen(!isOpen), className: cn(button), children: value ? (_jsx("div", { className: cn(label), children: selectOptions?.find((option) => value === option[0])?.[1] })) : (_jsx("div", { className: "text-xs pl-1", children: placeholder ?? "선택해주세요" })) }), inputTransition((styles, item) => isLong &&
|
|
101
|
+
return (_jsxs("div", { className: cn(container), onKeyDown: onKeyDown, onClick: () => setIsOwn(true), children: [_jsx("button", { onClick: () => setIsOpen(!isOpen), className: cn(button), onMouseEnter: () => setIsHover(true), onMouseLeave: () => setIsHover(false), children: value ? (_jsx("div", { className: cn(label), children: selectOptions?.find((option) => value === option[0])?.[1] })) : (_jsx("div", { className: "text-xs pl-1", children: placeholder ?? "선택해주세요" })) }), inputTransition((styles, item) => isLong &&
|
|
104
102
|
item && (_jsx(animated.input, { style: styles, placeholder: "\uAC80\uC0C9\uC5B4\uB97C \uC785\uB825\uD558\uC138\uC694", className: cn(input), onChange: (e) => setSearch(e.target.value) }))), bodyTransitions((styles, item) => {
|
|
105
103
|
return (item && (_jsx(animated.div, { style: styles, className: cn(body), children: filteredOptions?.map(([value, text], order) => (_jsx("section", { children: _jsx("button", { onClick: () => {
|
|
106
104
|
setValue(value);
|
package/html/template/Label.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import LabelDesign from "
|
|
2
|
+
import LabelDesign from "../design/Label.design";
|
|
3
3
|
function Label({ title, options }) {
|
|
4
4
|
return (_jsx(LabelDesign, { title: title, options: { ...options, width: "sm", height: "xs" } }));
|
|
5
5
|
}
|
package/html/template/Select.js
CHANGED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
const widthSize = {
|
|
3
|
+
xs: "w-32",
|
|
4
|
+
sm: "w-48",
|
|
5
|
+
md: "w-64",
|
|
6
|
+
lg: "w-96",
|
|
7
|
+
xl: "w-128",
|
|
8
|
+
"2xl": "w-144",
|
|
9
|
+
full: "w-full",
|
|
10
|
+
};
|
|
11
|
+
export default function Checkbox({ state: [checked, setChecked], labels, options, color, }) {
|
|
12
|
+
const checkBoxColor = {
|
|
13
|
+
red: "checked:bg-[#910023]",
|
|
14
|
+
blue: "checked:bg-[#173A8B]",
|
|
15
|
+
green: "checked:bg-[#DFE6E5]",
|
|
16
|
+
};
|
|
17
|
+
const { disabled } = options ?? {};
|
|
18
|
+
console.log(checked);
|
|
19
|
+
return (_jsxs("div", { className: "w-auto h-6 flex items-center ", children: [_jsx("input", { type: "checkbox", className: `check-box mr-2 appearance-none w-6 h-6 border-2 border-[#E8EBF3] rounded-md ${checkBoxColor[color]} hover:box-shadow`, disabled: typeof disabled === "boolean" && disabled, checked: checked, onChange: (e) => setChecked(e.target.checked) }), _jsx("label", { htmlFor: "checkbox1", children: labels })] }));
|
|
20
|
+
}
|
package/html/widget/Toggle.js
CHANGED
|
@@ -10,5 +10,5 @@ const widthSize = {
|
|
|
10
10
|
};
|
|
11
11
|
export default function Toggle({ state: [chekced, setChecked], labels, options, }) {
|
|
12
12
|
const { disabled } = options ?? {};
|
|
13
|
-
return (_jsxs("div", { className: "w-24 h-6 flex", children: [_jsx("label", { htmlFor: "", className: "inline-flex items-center gap-2 ", children: _jsx("input", { disabled: typeof disabled === "boolean" && disabled, type: "checkbox", className: "bg-red-crimson appearance-none relative rounded-full w-10 h-5 cursor-pointer", checked: chekced, onChange: (e) => setChecked(e.target.checked) }) }), _jsx("div", { className: "ml-2 transition-all", children: labels.map(([status, label]) => (status === chekced ? label : "")) })] }));
|
|
13
|
+
return (_jsxs("div", { className: "w-24 h-6 flex", children: [_jsx("label", { htmlFor: "", className: "inline-flex items-center gap-2 ", children: _jsx("input", { disabled: typeof disabled === "boolean" && disabled, type: "checkbox", className: "toggle bg-red-crimson appearance-none relative rounded-full w-10 h-5 cursor-pointer", checked: chekced, onChange: (e) => setChecked(e.target.checked) }) }), _jsx("div", { className: "ml-2 transition-all", children: labels.map(([status, label]) => (status === chekced ? label : "")) })] }));
|
|
14
14
|
}
|
package/interface/Board.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { DataField, Size, Titles } from "./Property";
|
|
1
|
+
import { DataField, DataSet, Size, Titles } from "./Property";
|
|
2
2
|
import { EventsProps } from "./Widget";
|
|
3
3
|
import { HTMLInputElement, HTMLLabelElement, HTMLSelectElement } from "./HTMLElement";
|
|
4
4
|
interface OptionsProps {
|
|
5
|
-
|
|
5
|
+
className?: string;
|
|
6
6
|
width?: Size;
|
|
7
7
|
height?: Size;
|
|
8
8
|
color?: string;
|
|
@@ -37,15 +37,8 @@ export interface CanvasBoardProps<B> extends BoardProps<B> {
|
|
|
37
37
|
export interface ManageBoardProps<B, K extends string, T extends {
|
|
38
38
|
[p in K]: any;
|
|
39
39
|
}> extends BoardProps<B> {
|
|
40
|
-
dataSets:
|
|
41
|
-
|
|
42
|
-
renderItem: (item: T) => React.ReactNode;
|
|
43
|
-
titles?: Titles;
|
|
44
|
-
interaction?: React.ReactNode;
|
|
45
|
-
}[];
|
|
46
|
-
dataField?: {
|
|
47
|
-
[p in keyof T]?: Partial<DataField>;
|
|
48
|
-
};
|
|
40
|
+
dataSets: DataSet<T>[];
|
|
41
|
+
dataField?: DataField<T>;
|
|
49
42
|
}
|
|
50
43
|
export interface PaperBoardProps<B> extends BoardProps<B> {
|
|
51
44
|
}
|
package/interface/Card.d.ts
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import { Button, DataField, Disabled, ImageSize, OnClick, Size, Titles } from "./Property";
|
|
2
|
-
import { Replace } from "./Widget";
|
|
1
|
+
import { Button, DataField, DataSet, Disabled, ImageSize, OnClick, Size, Titles } from "./Property";
|
|
3
2
|
interface CardOptions {
|
|
4
|
-
|
|
3
|
+
className?: string;
|
|
5
4
|
boundary?: string;
|
|
6
5
|
rounded?: string;
|
|
7
6
|
height?: Size;
|
|
@@ -71,6 +70,7 @@ export interface NavCardButtonInLayProps extends NavCardProps {
|
|
|
71
70
|
}
|
|
72
71
|
export interface InfoCardProps extends CardProps {
|
|
73
72
|
titles: Titles;
|
|
73
|
+
topRight?: React.ReactNode;
|
|
74
74
|
button?: Button;
|
|
75
75
|
options?: {
|
|
76
76
|
titleBorder?: string;
|
|
@@ -136,14 +136,8 @@ export interface AddCardProps extends Omit<CardProps, "children"> {
|
|
|
136
136
|
onClick: OnClick;
|
|
137
137
|
}
|
|
138
138
|
export interface TableCardProps<T> extends Omit<CardProps, "children"> {
|
|
139
|
-
dataSet:
|
|
140
|
-
|
|
141
|
-
onClick?: OnClick<T>;
|
|
142
|
-
replaces?: Replace[];
|
|
143
|
-
};
|
|
144
|
-
dataField: {
|
|
145
|
-
[p in keyof T]?: Partial<DataField>;
|
|
146
|
-
};
|
|
139
|
+
dataSet: Omit<DataSet<T>, "renderItem">;
|
|
140
|
+
dataField?: DataField<T>;
|
|
147
141
|
options?: CardOptions & {
|
|
148
142
|
className?: string;
|
|
149
143
|
limit?: number;
|
|
@@ -36,6 +36,12 @@ export interface HTMLToggleElement extends HTMLElement {
|
|
|
36
36
|
state: State<boolean>;
|
|
37
37
|
labels: [[true, string], [false, string]];
|
|
38
38
|
}
|
|
39
|
+
export type ColorType = "red" | "blue" | "green";
|
|
40
|
+
export interface HTMLCheckBoxElement extends HTMLElement {
|
|
41
|
+
state: State<boolean>;
|
|
42
|
+
labels: string;
|
|
43
|
+
color: ColorType;
|
|
44
|
+
}
|
|
39
45
|
export interface HTMLElementFrame {
|
|
40
46
|
title: string;
|
|
41
47
|
type: HTMLElementType;
|
package/interface/Layout.d.ts
CHANGED
package/interface/Modal.d.ts
CHANGED
package/interface/Property.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Dispatch, SetStateAction } from "react";
|
|
2
|
+
import { Replace } from "./Widget";
|
|
2
3
|
/**
|
|
3
4
|
* State type for the React component
|
|
4
5
|
* @template T
|
|
@@ -25,7 +26,7 @@ export type State<T> = [T, StateAction<T>];
|
|
|
25
26
|
* @property {"full"} full - Full size
|
|
26
27
|
*/
|
|
27
28
|
export type ImageSize = "sub" | "full";
|
|
28
|
-
export type Size = "xs" | "sm" | "md" | "lg" | "xl" | "2xl" | "full" | "auto";
|
|
29
|
+
export type Size = "2xs" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl" | "full" | "auto";
|
|
29
30
|
/**
|
|
30
31
|
* Image size type
|
|
31
32
|
* @enum {string}
|
|
@@ -49,11 +50,26 @@ export type Titles = {
|
|
|
49
50
|
titleColor?: string;
|
|
50
51
|
subtitleColor?: string;
|
|
51
52
|
};
|
|
52
|
-
export type
|
|
53
|
+
export type DataSet<T = any> = {
|
|
54
|
+
items?: T[];
|
|
55
|
+
renderItem: (item: T) => React.ReactNode;
|
|
56
|
+
titles?: Titles;
|
|
57
|
+
interaction?: React.ReactNode;
|
|
58
|
+
onClick?: OnClick<T>;
|
|
59
|
+
replaces?: Replace[];
|
|
60
|
+
};
|
|
61
|
+
type DataFieldType = {
|
|
53
62
|
title: string | number;
|
|
54
63
|
type: string;
|
|
55
64
|
size: string | number;
|
|
56
65
|
};
|
|
66
|
+
export type DataField<T = any> = Partial<{
|
|
67
|
+
[p in keyof T]: Partial<DataFieldType>;
|
|
68
|
+
}>;
|
|
69
|
+
export interface DataPackage<T> {
|
|
70
|
+
dataField: DataField<T>;
|
|
71
|
+
dataSet: Omit<DataSet<T>, "renderItem">;
|
|
72
|
+
}
|
|
57
73
|
export interface Log<K extends string, T extends string | number> {
|
|
58
74
|
prints: K[];
|
|
59
75
|
logs: {
|
|
@@ -64,3 +80,4 @@ export interface Order {
|
|
|
64
80
|
orderBy: string;
|
|
65
81
|
orderHow: "asc" | "desc" | "";
|
|
66
82
|
}
|
|
83
|
+
export {};
|
package/interface/Shelf.d.ts
CHANGED
|
@@ -6,8 +6,7 @@ interface Options<T> {
|
|
|
6
6
|
overflowScroll?: boolean;
|
|
7
7
|
width?: T;
|
|
8
8
|
height?: number;
|
|
9
|
-
|
|
10
|
-
gapY?: number;
|
|
9
|
+
gap?: "xy" | "x" | "y" | "none";
|
|
11
10
|
}
|
|
12
11
|
export interface ShelfProps<T> {
|
|
13
12
|
children: React.ReactNode;
|
|
@@ -16,7 +15,7 @@ export interface ShelfProps<T> {
|
|
|
16
15
|
};
|
|
17
16
|
titles?: Titles;
|
|
18
17
|
debug?: string;
|
|
19
|
-
|
|
18
|
+
className?: string;
|
|
20
19
|
options?: Options<T>;
|
|
21
20
|
}
|
|
22
21
|
export {};
|
package/interface/Widget.d.ts
CHANGED
|
@@ -24,9 +24,7 @@ export interface EventsProps {
|
|
|
24
24
|
}
|
|
25
25
|
export interface DataFieldProps<T> {
|
|
26
26
|
id: string;
|
|
27
|
-
dataField
|
|
28
|
-
[p in keyof T]?: Partial<DataField>;
|
|
29
|
-
};
|
|
27
|
+
dataField?: DataField<T>;
|
|
30
28
|
options?: {
|
|
31
29
|
position?: string;
|
|
32
30
|
padding?: string;
|
|
@@ -34,9 +32,7 @@ export interface DataFieldProps<T> {
|
|
|
34
32
|
}
|
|
35
33
|
export interface RowProps<T> {
|
|
36
34
|
item: T;
|
|
37
|
-
dataField?:
|
|
38
|
-
[p in keyof T]?: Partial<DataField>;
|
|
39
|
-
};
|
|
35
|
+
dataField?: DataField<T>;
|
|
40
36
|
onClick?: OnClick<T>;
|
|
41
37
|
buttons?: HTMLLabelElement[];
|
|
42
38
|
options?: {
|
|
@@ -45,6 +41,7 @@ export interface RowProps<T> {
|
|
|
45
41
|
padding?: string;
|
|
46
42
|
text?: string;
|
|
47
43
|
noHover?: boolean;
|
|
44
|
+
className?: string;
|
|
48
45
|
};
|
|
49
46
|
}
|
|
50
47
|
export {};
|
|
@@ -3,7 +3,7 @@ import { useId } from "react";
|
|
|
3
3
|
import { cn } from "../../util";
|
|
4
4
|
import { Label } from "../../html";
|
|
5
5
|
export default function RowDesign({ item, dataField, options, onClick, buttons, }) {
|
|
6
|
-
const { size, padding, text, noHover } = options ?? {};
|
|
6
|
+
const { size, padding, text, noHover, className } = options ?? {};
|
|
7
7
|
const id = useId();
|
|
8
8
|
const container = {
|
|
9
9
|
positions: "relative",
|
|
@@ -13,8 +13,12 @@ export default function RowDesign({ item, dataField, options, onClick, buttons,
|
|
|
13
13
|
text: text,
|
|
14
14
|
styles: !noHover && "hover:bg-gray-100 duration-100",
|
|
15
15
|
};
|
|
16
|
+
const itemBox = {
|
|
17
|
+
styles: "truncate",
|
|
18
|
+
className,
|
|
19
|
+
};
|
|
16
20
|
return (_jsxs("div", { className: cn(container), onClick: () => onClick?.(), children: [dataField &&
|
|
17
|
-
Object.keys(dataField).map((key) => (_jsx("div", { className: `w-${dataField[key]?.size}/100
|
|
21
|
+
Object.keys(dataField).map((key) => (_jsx("div", { className: cn(`w-${dataField[key]?.size}/100`, itemBox), children: String(item[key]) }, id + key))), _jsx("div", { className: "absolute right-4 xl:right-8 flex gap-4", children: buttons?.map(({ title, onClick, options }) => (_jsx(Label.Button, { title: title, onClick: onClick, options: {
|
|
18
22
|
background: options?.background ?? "bg-crimson-dark",
|
|
19
23
|
text: options?.text ?? "text-white",
|
|
20
24
|
width: "xs",
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { ShelfProps } from "../../interface";
|
|
2
|
-
export default function Shelf<T extends string | number>({ children,
|
|
2
|
+
export default function Shelf<T extends string | number>({ children, className, options, titles, debug, }: ShelfProps<T>): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,17 +1,19 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { LineBreaks } from "../../text";
|
|
3
3
|
import { cn, isDebug } from "../../util";
|
|
4
|
-
export default function Shelf({ children,
|
|
4
|
+
export default function Shelf({ children, className, options, titles, debug, }) {
|
|
5
|
+
const { title, titleColor } = titles ?? {};
|
|
5
6
|
const { titleSize, subtitleSize } = options ?? {};
|
|
6
7
|
const container = {
|
|
7
|
-
displays: "flex flex-col gap-
|
|
8
|
+
displays: "flex flex-col gap-6",
|
|
8
9
|
debug: debug && isDebug(`border-2 border-${debug}`),
|
|
9
10
|
};
|
|
10
11
|
const titleBox = {
|
|
11
|
-
container: "flex flex-col
|
|
12
|
+
container: "flex flex-col h-6 leading-none",
|
|
12
13
|
title: {
|
|
13
|
-
text: titleSize ?? "text-xl xl:text-
|
|
14
|
+
text: titleSize ?? "text-xl xl:text-xl",
|
|
14
15
|
font: "font-pretendard-bold",
|
|
16
|
+
titleColor: titleColor ?? "text-gray-dim",
|
|
15
17
|
},
|
|
16
18
|
subtitle: {
|
|
17
19
|
text: subtitleSize ?? "text-base xl:text-lg",
|
|
@@ -19,7 +21,7 @@ export default function Shelf({ children, classNames, options, titles, debug, })
|
|
|
19
21
|
};
|
|
20
22
|
const childrenBox = {
|
|
21
23
|
sizes: "w-full",
|
|
22
|
-
|
|
24
|
+
className,
|
|
23
25
|
};
|
|
24
|
-
return (_jsxs("div", { className: cn(container), children: [titles && (_jsxs("div", { className: cn(titleBox.container), children: [_jsx("div", { className: cn(titleBox.title), children:
|
|
26
|
+
return (_jsxs("div", { className: cn(container), children: [titles && (_jsxs("div", { className: cn(titleBox.container), children: [_jsx("div", { className: cn(titleBox.title), children: title }), _jsx(LineBreaks, { className: cn(titleBox.subtitle), texts: titles?.subtitle })] })), _jsx("div", { className: cn(childrenBox), children: children })] }));
|
|
25
27
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import DataFieldDesign from "../
|
|
2
|
+
import DataFieldDesign from "../design/DataField.design";
|
|
3
3
|
function Board({ id, dataField }) {
|
|
4
4
|
return (_jsx(DataFieldDesign, { id: id, dataField: dataField, options: {
|
|
5
5
|
position: "fixed top-34 xl:top-0 left-0 xl:relative z-20",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import Events from "./Events";
|
|
3
|
-
import Tab from "../
|
|
3
|
+
import Tab from "../design/Tab.design";
|
|
4
4
|
export default function Gallery({ widgets, children, }) {
|
|
5
5
|
return (_jsxs("div", { className: "relative w-full flex", children: [_jsx(Events.Replace, { widgets: widgets?.replaces, children: _jsx(Events.Show, { widgets: widgets?.shows, children: children }) }), widgets?.tabs && _jsx(Tab, { tabs: widgets?.tabs })] }));
|
|
6
6
|
}
|
package/layout/template/Row.d.ts
CHANGED
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import { RowProps } from "../../interface";
|
|
2
|
-
declare function
|
|
3
|
-
declare
|
|
4
|
-
height
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
Board:
|
|
10
|
-
|
|
11
|
-
};
|
|
2
|
+
declare function Row<T>({ item, dataField, onClick, buttons }: RowProps<T>): import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
declare namespace Row {
|
|
4
|
+
var Card: <T>({ item, dataField, onClick, buttons, height, noPadding, noHover, }: Omit<RowProps<T>, "options"> & {
|
|
5
|
+
height?: string | undefined;
|
|
6
|
+
noPadding?: boolean | undefined;
|
|
7
|
+
noHover?: boolean | undefined;
|
|
8
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
var Board: <T>({ item, dataField, onClick, buttons }: RowProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
}
|
|
12
11
|
export default Row;
|
package/layout/template/Row.js
CHANGED
|
@@ -1,7 +1,15 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { useId } from "react";
|
|
3
|
-
import RowDesign from "../
|
|
4
|
-
function
|
|
3
|
+
import RowDesign from "../design/Row.design";
|
|
4
|
+
function Row({ item, dataField, onClick, buttons }) {
|
|
5
|
+
return (_jsx(RowDesign, { onClick: onClick, item: item, dataField: dataField, buttons: buttons, options: {
|
|
6
|
+
size: "w-full h-12",
|
|
7
|
+
noHover: true,
|
|
8
|
+
text: "text-xs",
|
|
9
|
+
className: "text-center",
|
|
10
|
+
} }));
|
|
11
|
+
}
|
|
12
|
+
function Board({ item, dataField, onClick, buttons }) {
|
|
5
13
|
const id = useId();
|
|
6
14
|
return (_jsx(RowDesign, { onClick: onClick, item: item, dataField: dataField, buttons: buttons, options: {
|
|
7
15
|
size: "w-full h-12",
|
|
@@ -18,8 +26,6 @@ function Card({ item, dataField, onClick, buttons, height, noPadding, noHover, }
|
|
|
18
26
|
noHover,
|
|
19
27
|
} }, id));
|
|
20
28
|
}
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
Card,
|
|
24
|
-
};
|
|
29
|
+
Row.Card = Card;
|
|
30
|
+
Row.Board = Board;
|
|
25
31
|
export default Row;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ShelfProps } from "../../interface/Shelf";
|
|
2
2
|
declare function Shelf({ titles, debug, children }: ShelfProps<string | number>): import("react/jsx-runtime").JSX.Element;
|
|
3
3
|
declare namespace Shelf {
|
|
4
|
-
var Wrap: ({
|
|
4
|
+
var Wrap: ({ className, titles, children, debug, options, }: ShelfProps<string | number>) => import("react/jsx-runtime").JSX.Element;
|
|
5
5
|
var Row: ({ titles, children, debug }: ShelfProps<string | number>) => import("react/jsx-runtime").JSX.Element;
|
|
6
6
|
var Col: ({ titles, children, debug }: ShelfProps<string | number>) => import("react/jsx-runtime").JSX.Element;
|
|
7
7
|
}
|
package/layout/template/Shelf.js
CHANGED
|
@@ -1,18 +1,25 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { cn } from "../../util";
|
|
3
|
-
import ShelfDesign from "../
|
|
3
|
+
import ShelfDesign from "../design/Shelf.design";
|
|
4
|
+
const gap = {
|
|
5
|
+
xy: "gap-7.5",
|
|
6
|
+
x: "gap-x-7.5",
|
|
7
|
+
y: "gap-y-7.5",
|
|
8
|
+
none: "gap-0",
|
|
9
|
+
};
|
|
4
10
|
function Shelf({ titles, debug, children }) {
|
|
5
11
|
const container = {
|
|
6
12
|
displays: "inline-flex flex-col gap-12 w-full",
|
|
7
13
|
};
|
|
8
|
-
return (_jsx(ShelfDesign, { titles: titles,
|
|
14
|
+
return (_jsx(ShelfDesign, { titles: titles, className: cn(container), debug: debug, children: children }));
|
|
9
15
|
}
|
|
10
|
-
function Wrap({
|
|
16
|
+
function Wrap({ className, titles, children, debug, options, }) {
|
|
11
17
|
const container = {
|
|
12
|
-
displays: "flex flex-row flex-wrap
|
|
13
|
-
|
|
18
|
+
displays: "flex flex-row flex-wrap",
|
|
19
|
+
gaps: gap[options?.gap ?? "xy"],
|
|
20
|
+
className,
|
|
14
21
|
};
|
|
15
|
-
return (_jsx(ShelfDesign, { titles: titles,
|
|
22
|
+
return (_jsx(ShelfDesign, { titles: titles, className: cn(container), options: {
|
|
16
23
|
titleSize: "text-lg xl:text-2xl",
|
|
17
24
|
subtitleSize: "text-sm",
|
|
18
25
|
}, debug: debug, children: children }));
|
|
@@ -21,7 +28,7 @@ function Row({ titles, children, debug }) {
|
|
|
21
28
|
const container = {
|
|
22
29
|
displays: "flex flex-row gap-7.5",
|
|
23
30
|
};
|
|
24
|
-
return (_jsx(ShelfDesign, { titles: titles,
|
|
31
|
+
return (_jsx(ShelfDesign, { titles: titles, className: cn(container), options: {
|
|
25
32
|
titleSize: "text-lg xl:text-2xl",
|
|
26
33
|
subtitleSize: "text-sm",
|
|
27
34
|
}, debug: debug, children: children }));
|
|
@@ -30,7 +37,7 @@ function Col({ titles, children, debug }) {
|
|
|
30
37
|
const container = {
|
|
31
38
|
displays: "flex flex-col flex-wrap gap-y-5",
|
|
32
39
|
};
|
|
33
|
-
return (_jsx(ShelfDesign, { titles: titles,
|
|
40
|
+
return (_jsx(ShelfDesign, { titles: titles, className: cn(container), options: {
|
|
34
41
|
titleSize: "text-lg xl:text-2xl",
|
|
35
42
|
subtitleSize: "text-sm",
|
|
36
43
|
}, debug: debug, children: children }));
|
|
@@ -6,7 +6,7 @@ import { Events } from "../..";
|
|
|
6
6
|
import Notification from "./Notification";
|
|
7
7
|
export function Header({ title, logo, notification, options, }) {
|
|
8
8
|
const { setView, setIsOwn } = useWidgetStore();
|
|
9
|
-
const { notifications, flag, onClick } = notification;
|
|
9
|
+
const { notifications, flag, onClick, bgColor } = notification;
|
|
10
10
|
const { text, background, className } = options ?? {};
|
|
11
11
|
const container = {
|
|
12
12
|
positions: "fixed xl:static top-0 left-0 z-40",
|
|
@@ -24,8 +24,8 @@ export function Header({ title, logo, notification, options, }) {
|
|
|
24
24
|
setIsOwn(true);
|
|
25
25
|
onClick && onClick();
|
|
26
26
|
return setView("notification");
|
|
27
|
-
}, children: [_jsx("svg", { xmlns: "http://www.w3.org/2000/svg", width: "25", height: "25", viewBox: "0 0 25 25", fill: "none", children: _jsx("path", { d: "M15.4759 17.7938C17.4168 17.564 19.3237 17.1059 21.1572 16.4292C19.6044 14.7092 18.7465 12.4734 18.7499 10.1562V9.375C18.7499 7.7174 18.0914 6.12769 16.9193 4.95558C15.7472 3.78348 14.1575 3.125 12.4999 3.125C10.8423 3.125 9.25257 3.78348 8.08047 4.95558C6.90837 6.12769 6.24989 7.7174 6.24989 9.375V10.1562C6.25303 12.4736 5.39466 14.7093 3.84155 16.4292C5.64676 17.0958 7.54989 17.5594 9.52384 17.7938M15.4759 17.7938C13.4988 18.0283 11.5009 18.0283 9.52384 17.7938M15.4759 17.7938C15.626 18.2624 15.6634 18.7598 15.5849 19.2455C15.5064 19.7313 15.3143 20.1917 15.0242 20.5891C14.7342 20.9866 14.3544 21.31 13.9157 21.5329C13.4771 21.7559 12.9919 21.8721 12.4999 21.8721C12.0078 21.8721 11.5227 21.7559 11.0841 21.5329C10.6454 21.31 10.2656 20.9866 9.97553 20.5891C9.68548 20.1917 9.49339 19.7313 9.4149 19.2455C9.33641 18.7598 9.37374 18.2624 9.52384 17.7938", stroke: "#910023", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) }), flag && (_jsxs("div", { className: "absolute top-0 right-0", children: [_jsx("div", { className: "absolute w-2 h-2 rounded-full bg-red-500" }), _jsx("div", { className: " w-2 h-2 rounded-full bg-red-400 animate-ping duration-1000" })] }))] }), _jsx("svg", { className: "cursor-pointer", onClick: () => {
|
|
27
|
+
}, children: [_jsx("svg", { xmlns: "http://www.w3.org/2000/svg", width: "25", height: "25", viewBox: "0 0 25 25", fill: "none", children: _jsx("path", { d: "M15.4759 17.7938C17.4168 17.564 19.3237 17.1059 21.1572 16.4292C19.6044 14.7092 18.7465 12.4734 18.7499 10.1562V9.375C18.7499 7.7174 18.0914 6.12769 16.9193 4.95558C15.7472 3.78348 14.1575 3.125 12.4999 3.125C10.8423 3.125 9.25257 3.78348 8.08047 4.95558C6.90837 6.12769 6.24989 7.7174 6.24989 9.375V10.1562C6.25303 12.4736 5.39466 14.7093 3.84155 16.4292C5.64676 17.0958 7.54989 17.5594 9.52384 17.7938M15.4759 17.7938C13.4988 18.0283 11.5009 18.0283 9.52384 17.7938M15.4759 17.7938C15.626 18.2624 15.6634 18.7598 15.5849 19.2455C15.5064 19.7313 15.3143 20.1917 15.0242 20.5891C14.7342 20.9866 14.3544 21.31 13.9157 21.5329C13.4771 21.7559 12.9919 21.8721 12.4999 21.8721C12.0078 21.8721 11.5227 21.7559 11.0841 21.5329C10.6454 21.31 10.2656 20.9866 9.97553 20.5891C9.68548 20.1917 9.49339 19.7313 9.4149 19.2455C9.33641 18.7598 9.37374 18.2624 9.52384 17.7938", stroke: bgColor ?? "#910023", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) }), flag && (_jsxs("div", { className: "absolute top-0 right-0", children: [_jsx("div", { className: "absolute w-2 h-2 rounded-full bg-red-500" }), _jsx("div", { className: " w-2 h-2 rounded-full bg-red-400 animate-ping duration-1000" })] }))] }), _jsx("svg", { className: "cursor-pointer", onClick: () => {
|
|
28
28
|
setIsOwn(true);
|
|
29
29
|
return setView("menu");
|
|
30
|
-
}, xmlns: "http://www.w3.org/2000/svg", width: "25", height: "25", viewBox: "0 0 25 25", fill: "none", children: _jsx("path", { d: "M18.7313 19.5053C18.0034 18.5416 17.0618 17.7601 15.9804 17.2223C14.8991 16.6846 13.7077 16.4052 12.5 16.4063C11.2924 16.4052 10.101 16.6846 9.01964 17.2223C7.93832 17.7601 6.99664 18.5416 6.26878 19.5053M18.7313 19.5053C20.1516 18.2419 21.1533 16.5767 21.6054 14.7304C22.0576 12.884 21.9378 10.9439 21.262 9.16722C20.5862 7.39055 19.3862 5.86128 17.8213 4.78224C16.2564 3.7032 14.4004 3.12537 12.4995 3.12537C10.5986 3.12537 8.74267 3.7032 7.17775 4.78224C5.61282 5.86128 4.41288 7.39055 3.73705 9.16722C3.06122 10.9439 2.94144 12.884 3.3936 14.7304C3.84575 16.5767 4.84847 18.2419 6.26878 19.5053M18.7313 19.5053C17.0167 21.0346 14.7976 21.8783 12.5 21.8751C10.2021 21.8786 7.98361 21.0349 6.26878 19.5053M15.625 10.1563C15.625 10.9851 15.2958 11.78 14.7097 12.366C14.1237 12.9521 13.3288 13.2813 12.5 13.2813C11.6712 13.2813 10.8764 12.9521 10.2903 12.366C9.70427 11.78 9.37503 10.9851 9.37503 10.1563C9.37503 9.32751 9.70427 8.53265 10.2903 7.9466C10.8764 7.36055 11.6712 7.03131 12.5 7.03131C13.3288 7.03131 14.1237 7.36055 14.7097 7.9466C15.2958 8.53265 15.625 9.32751 15.625 10.1563Z", stroke: "#910023", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) })] }) })] }));
|
|
30
|
+
}, xmlns: "http://www.w3.org/2000/svg", width: "25", height: "25", viewBox: "0 0 25 25", fill: "none", children: _jsx("path", { d: "M18.7313 19.5053C18.0034 18.5416 17.0618 17.7601 15.9804 17.2223C14.8991 16.6846 13.7077 16.4052 12.5 16.4063C11.2924 16.4052 10.101 16.6846 9.01964 17.2223C7.93832 17.7601 6.99664 18.5416 6.26878 19.5053M18.7313 19.5053C20.1516 18.2419 21.1533 16.5767 21.6054 14.7304C22.0576 12.884 21.9378 10.9439 21.262 9.16722C20.5862 7.39055 19.3862 5.86128 17.8213 4.78224C16.2564 3.7032 14.4004 3.12537 12.4995 3.12537C10.5986 3.12537 8.74267 3.7032 7.17775 4.78224C5.61282 5.86128 4.41288 7.39055 3.73705 9.16722C3.06122 10.9439 2.94144 12.884 3.3936 14.7304C3.84575 16.5767 4.84847 18.2419 6.26878 19.5053M18.7313 19.5053C17.0167 21.0346 14.7976 21.8783 12.5 21.8751C10.2021 21.8786 7.98361 21.0349 6.26878 19.5053M15.625 10.1563C15.625 10.9851 15.2958 11.78 14.7097 12.366C14.1237 12.9521 13.3288 13.2813 12.5 13.2813C11.6712 13.2813 10.8764 12.9521 10.2903 12.366C9.70427 11.78 9.37503 10.9851 9.37503 10.1563C9.37503 9.32751 9.70427 8.53265 10.2903 7.9466C10.8764 7.36055 11.6712 7.03131 12.5 7.03131C13.3288 7.03131 14.1237 7.36055 14.7097 7.9466C15.2958 8.53265 15.625 9.32751 15.625 10.1563Z", stroke: bgColor ?? "#910023", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) })] }) })] }));
|
|
31
31
|
}
|
package/modal/template/Alert.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import ModalDesign from "../
|
|
2
|
+
import ModalDesign from "../design/Modal.design";
|
|
3
3
|
export default function Alert({ isVisible, title, scripts, options, }) {
|
|
4
4
|
const { script, subScript } = scripts ?? {};
|
|
5
5
|
const { buttons } = options ?? {};
|
|
6
|
-
return (_jsx(ModalDesign, { isVisible: isVisible,
|
|
6
|
+
return (_jsx(ModalDesign, { isVisible: isVisible, className: "pt-18 px-25", options: { buttons, isCloseButton: true }, children: _jsx("div", { className: "flex flex-col gap-3", children: _jsxs("div", { className: "flex flex-col gap-6", children: [_jsx("div", { className: "text-3xl font-pretendard-bold", children: title }), _jsx("div", { className: "h-2 w-14 rounded-full bg-pale-lavender" }), _jsx("div", { className: "text-xl font-pretendard-bold", children: script })] }) }) }));
|
|
7
7
|
}
|
package/modal/template/Input.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import ModalDesign from "../
|
|
2
|
+
import ModalDesign from "../design/Modal.design";
|
|
3
3
|
export default function Input({ isVisible, event, title, options, state, }) {
|
|
4
4
|
const { buttons } = options ?? {};
|
|
5
|
-
return (_jsxs(ModalDesign, { isVisible: isVisible, event: event,
|
|
5
|
+
return (_jsxs(ModalDesign, { isVisible: isVisible, event: event, className: "pt-18 px-25", options: { buttons, isCloseButton: true }, children: [_jsx("div", { className: "text-xl font-pretendard-bold", children: title }), _jsx("input", { className: "border-2 border-black w-80 h-8", value: state[0], onChange: (e) => state[1](e.target.value) })] }));
|
|
6
6
|
}
|
|
@@ -27,5 +27,5 @@ export default function OverlayDesign({ titles, children, event, isVisible, }) {
|
|
|
27
27
|
leave: { width: "10%", opacity: 0 },
|
|
28
28
|
config: { duration: 300 },
|
|
29
29
|
});
|
|
30
|
-
return transitions((styles, item) => item && (_jsxs(animated.div, { style: styles, className: cn(container), onClick: () => setIsOwn(
|
|
30
|
+
return transitions((styles, item) => item && (_jsxs(animated.div, { style: styles, className: cn(container), onClick: () => setIsOwn("overlay"), children: [_jsxs("div", { className: cn(body), children: [_jsx("div", { className: "font-pretendard-bold text-2xl", children: title }), _jsx("div", { className: "flex flex-col gap-3", children: children })] }), event && (_jsx("button", { onClick: () => removeView(event), className: cn(button), children: _jsx("svg", { xmlns: "http://www.w3.org/2000/svg", width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", children: _jsx("path", { d: "M6.28003 5.22C6.13786 5.08752 5.94981 5.0154 5.75551 5.01882C5.56121 5.02225 5.37582 5.10096 5.23841 5.23838C5.101 5.37579 5.02228 5.56118 5.01886 5.75548C5.01543 5.94978 5.08755 6.13782 5.22003 6.28L8.94003 10L5.22003 13.72C5.14634 13.7887 5.08724 13.8715 5.04625 13.9635C5.00526 14.0555 4.98322 14.1548 4.98144 14.2555C4.97966 14.3562 4.99819 14.4562 5.03591 14.5496C5.07363 14.643 5.12977 14.7278 5.20099 14.799C5.27221 14.8703 5.35705 14.9264 5.45043 14.9641C5.54382 15.0018 5.64385 15.0204 5.74455 15.0186C5.84526 15.0168 5.94457 14.9948 6.03657 14.9538C6.12857 14.9128 6.21137 14.8537 6.28003 14.78L10 11.06L13.72 14.78C13.7887 14.8537 13.8715 14.9128 13.9635 14.9538C14.0555 14.9948 14.1548 15.0168 14.2555 15.0186C14.3562 15.0204 14.4562 15.0018 14.5496 14.9641C14.643 14.9264 14.7279 14.8703 14.7991 14.799C14.8703 14.7278 14.9264 14.643 14.9642 14.5496C15.0019 14.4562 15.0204 14.3562 15.0186 14.2555C15.0168 14.1548 14.9948 14.0555 14.9538 13.9635C14.9128 13.8715 14.8537 13.7887 14.78 13.72L11.06 10L14.78 6.28C14.9125 6.13782 14.9846 5.94978 14.9812 5.75548C14.9778 5.56118 14.8991 5.37579 14.7617 5.23838C14.6242 5.10096 14.4389 5.02225 14.2446 5.01882C14.0503 5.0154 13.8622 5.08752 13.72 5.22L10 8.94L6.28003 5.22Z", fill: "#7F7F7F" }) }) }))] })));
|
|
31
31
|
}
|