1mpacto-react-ui 2.0.26 → 2.0.28
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/assets/_mixins.scss +6 -1
- package/dist/assets/_typography.scss +19 -15
- package/dist/assets/core.css +1 -1
- package/dist/assets/style.css +1 -1
- package/dist/components/Alert/index.cjs +1 -1
- package/dist/components/Alert/index.mjs +55 -51
- package/dist/components/Alert/style.module.scss.cjs +1 -1
- package/dist/components/Alert/style.module.scss.mjs +12 -11
- package/dist/components/Badges/Badges.config.cjs +1 -1
- package/dist/components/Badges/Badges.config.mjs +18 -3
- package/dist/components/Badges/style.module.scss.cjs +1 -1
- package/dist/components/Badges/style.module.scss.mjs +46 -35
- package/dist/components/Breadcrumbs/Breadcrumbs.cjs +3 -3
- package/dist/components/Breadcrumbs/Breadcrumbs.config.cjs +1 -1
- package/dist/components/Breadcrumbs/Breadcrumbs.config.mjs +4 -3
- package/dist/components/Breadcrumbs/Breadcrumbs.mjs +45 -43
- package/dist/components/Breadcrumbs/style.module.scss.cjs +1 -1
- package/dist/components/Breadcrumbs/style.module.scss.mjs +12 -9
- package/dist/components/Button/Button.config.cjs +1 -1
- package/dist/components/Button/Button.config.mjs +10 -2
- package/dist/components/Button/style.module.scss.cjs +1 -1
- package/dist/components/Button/style.module.scss.mjs +64 -60
- package/dist/components/ButtonIcon/ButtonIcon.config.cjs +1 -1
- package/dist/components/ButtonIcon/ButtonIcon.config.mjs +58 -47
- package/dist/components/ButtonIcon/style.module.scss.cjs +1 -1
- package/dist/components/ButtonIcon/style.module.scss.mjs +55 -48
- package/dist/components/Input/InputInnerLabel.module.scss.cjs +1 -1
- package/dist/components/Input/InputInnerLabel.module.scss.mjs +19 -19
- package/dist/components/Modal/ModalDialog.cjs +11 -1
- package/dist/components/Modal/ModalDialog.config.cjs +1 -1
- package/dist/components/Modal/ModalDialog.config.mjs +18 -7
- package/dist/components/Modal/ModalDialog.mjs +59 -32
- package/dist/components/Modal/style.module.scss.cjs +1 -1
- package/dist/components/Modal/style.module.scss.mjs +17 -11
- package/dist/components/Pagination/Pagination.cjs +2 -2
- package/dist/components/Pagination/Pagination.config.cjs +1 -1
- package/dist/components/Pagination/Pagination.config.mjs +4 -3
- package/dist/components/Pagination/Pagination.mjs +90 -90
- package/dist/components/Pagination/style.module.scss.cjs +1 -1
- package/dist/components/Pagination/style.module.scss.mjs +18 -16
- package/dist/components/Popover/Popover.cjs +1 -1
- package/dist/components/Popover/Popover.config.cjs +1 -0
- package/dist/components/Popover/Popover.config.mjs +11 -0
- package/dist/components/Popover/Popover.mjs +42 -40
- package/dist/components/Popover/style.module.scss.cjs +1 -1
- package/dist/components/Popover/style.module.scss.mjs +8 -4
- package/dist/components/RadioCheckbox/RadioCheckbox.config.cjs +1 -1
- package/dist/components/RadioCheckbox/RadioCheckbox.config.mjs +24 -22
- package/dist/components/RadioCheckbox/RadioCheckbox.module.scss.cjs +1 -1
- package/dist/components/RadioCheckbox/RadioCheckbox.module.scss.mjs +25 -23
- package/dist/components/RadioCheckbox/RadioCheckboxLabel.config.cjs +1 -1
- package/dist/components/RadioCheckbox/RadioCheckboxLabel.config.mjs +5 -4
- package/dist/components/RadioCheckbox/RadioCheckboxLabel.module.scss.cjs +1 -1
- package/dist/components/RadioCheckbox/RadioCheckboxLabel.module.scss.mjs +8 -7
- package/dist/components/SelectDropdownContainer/SelectDropdownContainer.cjs +1 -1
- package/dist/components/SelectDropdownContainer/SelectDropdownContainer.config.cjs +1 -1
- package/dist/components/SelectDropdownContainer/SelectDropdownContainer.config.mjs +19 -10
- package/dist/components/SelectDropdownContainer/SelectDropdownContainer.mjs +95 -80
- package/dist/components/SelectDropdownContainer/styleConfig.cjs +1 -1
- package/dist/components/SelectDropdownContainer/styleConfig.mjs +151 -11
- package/dist/components/Sidebar/Sidebar.module.scss.cjs +1 -1
- package/dist/components/Sidebar/Sidebar.module.scss.mjs +22 -22
- package/dist/components/Sidebar/itemSidebar.module.scss.cjs +1 -1
- package/dist/components/Sidebar/itemSidebar.module.scss.mjs +25 -25
- package/dist/components/Step/StepIndicator.cjs +6 -4
- package/dist/components/Step/StepIndicator.config.cjs +1 -0
- package/dist/components/Step/StepIndicator.config.mjs +12 -0
- package/dist/components/Step/StepIndicator.mjs +31 -26
- package/dist/components/Step/StepIndicator.module.scss.cjs +1 -1
- package/dist/components/Step/StepIndicator.module.scss.mjs +12 -11
- package/dist/components/Switch/Switch.config.cjs +1 -1
- package/dist/components/Switch/Switch.config.mjs +6 -3
- package/dist/components/Switch/style.module.scss.cjs +1 -1
- package/dist/components/Switch/style.module.scss.mjs +18 -15
- package/dist/components/Tabs/Tabs.config.cjs +1 -1
- package/dist/components/Tabs/Tabs.config.mjs +13 -6
- package/dist/components/Tabs/style.module.scss.cjs +1 -1
- package/dist/components/Tabs/style.module.scss.mjs +29 -23
- package/dist/components/Textarea/TextareaFloatingInner.cjs +6 -5
- package/dist/components/Textarea/TextareaFloatingInner.config.cjs +1 -1
- package/dist/components/Textarea/TextareaFloatingInner.config.mjs +6 -2
- package/dist/components/Textarea/TextareaFloatingInner.mjs +38 -36
- package/dist/components/Textarea/TextareaFloatingInner.module.scss.cjs +1 -1
- package/dist/components/Textarea/TextareaFloatingInner.module.scss.mjs +11 -9
- package/dist/components/fin/Chat/BubbleChat.cjs +1 -0
- package/dist/components/fin/Chat/BubbleChat.mjs +20 -0
- package/dist/components/fin/Chat/BubbleChatOption.cjs +1 -0
- package/dist/components/fin/Chat/BubbleChatOption.mjs +70 -0
- package/dist/components/fin/Chat/BubbleChatUser.cjs +1 -0
- package/dist/components/fin/Chat/BubbleChatUser.mjs +15 -0
- package/dist/components/fin/Chat/Icons.cjs +1 -0
- package/dist/components/fin/Chat/Icons.mjs +44 -0
- package/dist/components/fin/Chat/style.module.scss.cjs +1 -0
- package/dist/components/fin/Chat/style.module.scss.mjs +27 -0
- package/dist/config/components/typography.cjs +1 -1
- package/dist/config/components/typography.mjs +40 -6
- package/dist/config/tailwind/typography.cjs +1 -1
- package/dist/config/tailwind/typography.mjs +23 -15
- package/dist/index.cjs +1 -1
- package/dist/index.mjs +86 -80
- package/dist/package.json.cjs +1 -1
- package/dist/package.json.d.ts +1 -1
- package/dist/package.json.mjs +1 -1
- package/dist/src/components/Badges/Badges.config.d.ts +15 -0
- package/dist/src/components/Breadcrumbs/Breadcrumbs.config.d.ts +1 -0
- package/dist/src/components/Button/Button.config.d.ts +8 -0
- package/dist/src/components/ButtonIcon/ButtonIcon.config.d.ts +11 -0
- package/dist/src/components/Modal/ModalDialog.config.d.ts +12 -0
- package/dist/src/components/Modal/ModalDialog.d.ts +1 -1
- package/dist/src/components/Modal/ModalDialog.stories.d.ts +17 -1
- package/dist/src/components/Pagination/Pagination.config.d.ts +1 -0
- package/dist/src/components/Pagination/Pagination.d.ts +1 -1
- package/dist/src/components/Pagination/Pagination.stories.d.ts +14 -1
- package/dist/src/components/Popover/Popover.config.d.ts +8 -0
- package/dist/src/components/RadioCheckbox/RadioCheckbox.config.d.ts +2 -0
- package/dist/src/components/RadioCheckbox/RadioCheckboxLabel.config.d.ts +1 -0
- package/dist/src/components/SelectDropdownContainer/SelectDropdownContainer.config.d.ts +10 -0
- package/dist/src/components/SelectDropdownContainer/styleConfig.d.ts +2 -0
- package/dist/src/components/Step/StepIndicator.config.d.ts +18 -0
- package/dist/src/components/Step/StepIndicator.d.ts +1 -1
- package/dist/src/components/Step/StepIndicator.stories.d.ts +30 -1
- package/dist/src/components/Switch/Switch.config.d.ts +3 -0
- package/dist/src/components/Tabs/Tabs.config.d.ts +7 -1
- package/dist/src/components/Textarea/TextareaFloatingInner.config.d.ts +5 -0
- package/dist/src/components/fin/Chat/BubbleChat.d.ts +3 -0
- package/dist/src/components/fin/Chat/BubbleChatOption.d.ts +3 -0
- package/dist/src/components/fin/Chat/BubbleChatUser.d.ts +3 -0
- package/dist/src/components/fin/Chat/Icons.d.ts +5 -0
- package/dist/src/components/fin/index.d.ts +4 -0
- package/dist/src/components/index.d.ts +2 -1
- package/dist/src/config/components/typography.d.ts +1 -1
- package/dist/src/interfaces/components/Badges/index.d.ts +6 -1
- package/dist/src/interfaces/components/Breadcrumbs/index.d.ts +1 -1
- package/dist/src/interfaces/components/Button/index.d.ts +1 -1
- package/dist/src/interfaces/components/ButtonIcon/index.d.ts +2 -2
- package/dist/src/interfaces/components/Modal/index.d.ts +10 -0
- package/dist/src/interfaces/components/Pagination/index.d.ts +6 -1
- package/dist/src/interfaces/components/Popover/index.d.ts +5 -0
- package/dist/src/interfaces/components/RadioCheckbox/RadioCheckbox.d.ts +1 -1
- package/dist/src/interfaces/components/RadioCheckbox/RadioCheckboxLabel.d.ts +1 -1
- package/dist/src/interfaces/components/SelectDropdownContainer/index.d.ts +7 -1
- package/dist/src/interfaces/components/Step/index.d.ts +13 -2
- package/dist/src/interfaces/components/Switch/index.d.ts +1 -1
- package/dist/src/interfaces/components/Tabs/index.d.ts +2 -2
- package/dist/src/interfaces/components/Textarea/index.d.ts +5 -0
- package/dist/src/interfaces/components/fin/Chat/index.d.ts +39 -0
- package/package.json +1 -1
|
@@ -1,15 +1,14 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
1
|
+
import { jsxs as p, Fragment as z, jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import M, { useMemo as D, isValidElement as N } from "react";
|
|
3
|
+
import o from "./style.module.scss.mjs";
|
|
4
4
|
import { formatNumber as u } from "../../utils/common.mjs";
|
|
5
|
-
import { ChevronDownIcon as
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
|
|
9
|
-
const
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
}, L = {
|
|
5
|
+
import { ChevronDownIcon as B } from "../Calendar/CalendarYear.mjs";
|
|
6
|
+
import nn from "../Popover/Popover.mjs";
|
|
7
|
+
import { configPagination as L } from "./Pagination.config.mjs";
|
|
8
|
+
const $ = (t, e) => {
|
|
9
|
+
const a = e - t + 1;
|
|
10
|
+
return Array.from({ length: a }, (s, x) => x + t);
|
|
11
|
+
}, S = {
|
|
13
12
|
"en-US": {
|
|
14
13
|
"Rows per page:": "Rows per page:",
|
|
15
14
|
of: "of",
|
|
@@ -30,130 +29,131 @@ const $ = (t, o) => {
|
|
|
30
29
|
of: "van",
|
|
31
30
|
"Go to:": "Ga naar:"
|
|
32
31
|
}
|
|
33
|
-
},
|
|
32
|
+
}, mn = ({
|
|
34
33
|
totalData: t,
|
|
35
|
-
totalPage:
|
|
34
|
+
totalPage: e,
|
|
36
35
|
pageNumber: a,
|
|
37
36
|
pageSize: s,
|
|
38
|
-
className:
|
|
37
|
+
className: x,
|
|
39
38
|
id: m = "1ru-pagination",
|
|
40
|
-
kind:
|
|
39
|
+
kind: O = "box",
|
|
41
40
|
prevIcon: f,
|
|
42
41
|
nextIcon: g,
|
|
43
|
-
onChange:
|
|
44
|
-
optionPageSize:
|
|
45
|
-
offset:
|
|
42
|
+
onChange: w,
|
|
43
|
+
optionPageSize: U = [25, 50, 75, 100],
|
|
44
|
+
offset: _ = 1.5,
|
|
46
45
|
zIndex: q,
|
|
47
|
-
withGotoPage:
|
|
48
|
-
withMorePage:
|
|
49
|
-
withOptionPageSize:
|
|
50
|
-
|
|
51
|
-
|
|
46
|
+
withGotoPage: H = !1,
|
|
47
|
+
withMorePage: j = !0,
|
|
48
|
+
withOptionPageSize: J = !1,
|
|
49
|
+
withPageSize: K = !0,
|
|
50
|
+
locale: C = "id-ID",
|
|
51
|
+
fonts: V = "inter"
|
|
52
52
|
}) => {
|
|
53
|
-
const
|
|
53
|
+
const R = M.useRef(null), [i, y] = M.useState(a), [Q, G] = M.useState(a.toString()), l = 1, T = (i - 1) * s + 1, A = s * i, W = t ? `${u(T, "decimal")}-${A >= t ? u(t, "decimal") : u(A, "decimal")}` : 0, X = D(() => {
|
|
54
54
|
const n = Math.ceil(t / s);
|
|
55
|
-
if (
|
|
55
|
+
if (l + 5 >= n)
|
|
56
56
|
return $(1, n);
|
|
57
|
-
const d = Math.max(i -
|
|
57
|
+
const d = Math.max(i - l, 1), E = Math.min(i + l, n), k = d > 2, P = E < n - 2, F = 1, v = n;
|
|
58
58
|
if (!k && P) {
|
|
59
|
-
const b = 3 + 2 *
|
|
59
|
+
const b = 3 + 2 * l;
|
|
60
60
|
return [...$(1, b), "mr", n];
|
|
61
61
|
}
|
|
62
62
|
if (k && !P) {
|
|
63
|
-
const b = 3 + 2 *
|
|
64
|
-
return [
|
|
63
|
+
const b = 3 + 2 * l, I = $(n - b + 1, n);
|
|
64
|
+
return [F, "ml", ...I];
|
|
65
65
|
}
|
|
66
66
|
if (k && P) {
|
|
67
|
-
const b = $(d,
|
|
68
|
-
return [
|
|
67
|
+
const b = $(d, E);
|
|
68
|
+
return [F, "ml", ...b, "mr", v];
|
|
69
69
|
}
|
|
70
|
-
}, [t, s,
|
|
71
|
-
typeof
|
|
72
|
-
},
|
|
73
|
-
if (typeof
|
|
70
|
+
}, [t, s, l, i]), h = (n) => {
|
|
71
|
+
typeof w == "function" && (w(n), y(n.pageNumber), G(n.pageNumber.toString()));
|
|
72
|
+
}, Y = (n) => {
|
|
73
|
+
if (typeof w == "function" && j) {
|
|
74
74
|
if (n === "ml") {
|
|
75
75
|
const d = i - 5;
|
|
76
|
-
|
|
76
|
+
y(d < 1 ? 1 : i - 5);
|
|
77
77
|
} else if (n === "mr") {
|
|
78
78
|
const d = i + 5;
|
|
79
|
-
|
|
79
|
+
y(d > e ? e : i + 5);
|
|
80
80
|
}
|
|
81
81
|
}
|
|
82
|
-
},
|
|
82
|
+
}, Z = (n) => {
|
|
83
83
|
G(n);
|
|
84
84
|
const c = Number(n);
|
|
85
|
-
c > 0 && c <=
|
|
85
|
+
c > 0 && c <= e && h({
|
|
86
86
|
pageSize: s,
|
|
87
87
|
totalData: t,
|
|
88
|
-
totalPage:
|
|
88
|
+
totalPage: e,
|
|
89
89
|
pageNumber: c
|
|
90
90
|
});
|
|
91
91
|
};
|
|
92
|
-
return /* @__PURE__ */
|
|
93
|
-
/* @__PURE__ */
|
|
94
|
-
/* @__PURE__ */
|
|
95
|
-
/* @__PURE__ */
|
|
96
|
-
|
|
97
|
-
|
|
92
|
+
return /* @__PURE__ */ p(z, { children: [
|
|
93
|
+
/* @__PURE__ */ p("div", { id: m, className: `${L.kind[O]} ${L.fonts[V].value} ${x}`, children: [
|
|
94
|
+
/* @__PURE__ */ p("div", { className: o["pagination-size"], children: [
|
|
95
|
+
/* @__PURE__ */ r("span", { children: S[C]["Rows per page:"] }),
|
|
96
|
+
J && /* @__PURE__ */ p(
|
|
97
|
+
"button",
|
|
98
98
|
{
|
|
99
99
|
id: `${m}-option-size`,
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
100
|
+
className: o["button-option"],
|
|
101
|
+
onClick: (n) => R.current?.handlerShow(n),
|
|
102
|
+
children: [
|
|
103
|
+
u(s, "decimal"),
|
|
104
|
+
/* @__PURE__ */ r(B, { className: "!iru-text-gray-500 !iru-w-[14px] !iru-h-[14px] iru-mx-0.5" })
|
|
105
|
+
]
|
|
106
106
|
}
|
|
107
107
|
),
|
|
108
|
-
/* @__PURE__ */
|
|
109
|
-
|
|
108
|
+
K && /* @__PURE__ */ p("span", { children: [
|
|
109
|
+
W,
|
|
110
110
|
" ",
|
|
111
|
-
|
|
111
|
+
S[C].of,
|
|
112
112
|
" ",
|
|
113
113
|
u(t, "decimal")
|
|
114
114
|
] })
|
|
115
115
|
] }),
|
|
116
|
-
/* @__PURE__ */
|
|
117
|
-
/* @__PURE__ */
|
|
116
|
+
/* @__PURE__ */ p("div", { className: o["navigation-container"], children: [
|
|
117
|
+
/* @__PURE__ */ r(
|
|
118
118
|
"button",
|
|
119
119
|
{
|
|
120
120
|
id: `${m}-button-prev`,
|
|
121
|
-
className: `${
|
|
121
|
+
className: `${o["button-prev"]}`,
|
|
122
122
|
disabled: i === 1,
|
|
123
123
|
onClick: () => h({
|
|
124
124
|
pageSize: s,
|
|
125
125
|
totalData: t,
|
|
126
|
-
totalPage:
|
|
126
|
+
totalPage: e,
|
|
127
127
|
pageNumber: a - 1
|
|
128
128
|
}),
|
|
129
|
-
children: typeof f == "function" || N(f) ? N(f) ? f : f() : /* @__PURE__ */
|
|
129
|
+
children: typeof f == "function" || N(f) ? N(f) ? f : f() : /* @__PURE__ */ r(B, { className: "iru-rotate-90 !iru-text-gray-500 !iru-w-[14px] !iru-h-[14px]" })
|
|
130
130
|
}
|
|
131
131
|
),
|
|
132
|
-
(
|
|
132
|
+
(X ?? []).map((n, c) => {
|
|
133
133
|
if (typeof n != "number") {
|
|
134
134
|
const d = ["ml", "mr"].includes(n);
|
|
135
|
-
return /* @__PURE__ */
|
|
135
|
+
return /* @__PURE__ */ r(
|
|
136
136
|
"button",
|
|
137
137
|
{
|
|
138
|
-
className:
|
|
139
|
-
disabled: !
|
|
140
|
-
onClick: () =>
|
|
138
|
+
className: o["button-container"],
|
|
139
|
+
disabled: !j,
|
|
140
|
+
onClick: () => Y(n),
|
|
141
141
|
children: d ? "..." : n
|
|
142
142
|
},
|
|
143
143
|
c
|
|
144
144
|
);
|
|
145
145
|
}
|
|
146
|
-
return /* @__PURE__ */
|
|
146
|
+
return /* @__PURE__ */ r(
|
|
147
147
|
"button",
|
|
148
148
|
{
|
|
149
149
|
id: `${m}-button-${n}`,
|
|
150
|
-
className: `${n === a ?
|
|
151
|
-
${
|
|
150
|
+
className: `${n === a ? o["pagination-active"] : ""} ${o["button-container"]}
|
|
151
|
+
${L.fonts[V].typographyButtonLabel}`,
|
|
152
152
|
disabled: n === a,
|
|
153
153
|
onClick: () => h({
|
|
154
154
|
pageSize: s,
|
|
155
155
|
totalData: t,
|
|
156
|
-
totalPage:
|
|
156
|
+
totalPage: e,
|
|
157
157
|
pageNumber: n
|
|
158
158
|
}),
|
|
159
159
|
children: u(n, "decimal")
|
|
@@ -161,58 +161,58 @@ const $ = (t, o) => {
|
|
|
161
161
|
c
|
|
162
162
|
);
|
|
163
163
|
}),
|
|
164
|
-
/* @__PURE__ */
|
|
164
|
+
/* @__PURE__ */ r(
|
|
165
165
|
"button",
|
|
166
166
|
{
|
|
167
167
|
id: `${m}-button-next`,
|
|
168
|
-
className: `${
|
|
169
|
-
disabled: i ===
|
|
168
|
+
className: `${o["button-next"]}`,
|
|
169
|
+
disabled: i === e || !e,
|
|
170
170
|
onClick: () => h({
|
|
171
171
|
pageSize: s,
|
|
172
172
|
totalData: t,
|
|
173
|
-
totalPage:
|
|
173
|
+
totalPage: e,
|
|
174
174
|
pageNumber: a + 1
|
|
175
175
|
}),
|
|
176
|
-
children: typeof g == "function" || N(g) ? N(g) ? g : g() : /* @__PURE__ */
|
|
176
|
+
children: typeof g == "function" || N(g) ? N(g) ? g : g() : /* @__PURE__ */ r(B, { className: "-iru-rotate-90 !iru-text-gray-500 !iru-w-[14px] !iru-h-[14px]" })
|
|
177
177
|
}
|
|
178
178
|
),
|
|
179
|
-
|
|
180
|
-
/* @__PURE__ */
|
|
181
|
-
/* @__PURE__ */
|
|
179
|
+
H && /* @__PURE__ */ p("div", { className: o["goto-page"], children: [
|
|
180
|
+
/* @__PURE__ */ r("span", { children: S[C]["Go to:"] }),
|
|
181
|
+
/* @__PURE__ */ r(
|
|
182
182
|
"input",
|
|
183
183
|
{
|
|
184
184
|
id: `${m}-goto-page`,
|
|
185
185
|
type: "number",
|
|
186
|
-
className:
|
|
187
|
-
value:
|
|
188
|
-
onChange: (n) =>
|
|
186
|
+
className: o["goto-page-input"],
|
|
187
|
+
value: Q,
|
|
188
|
+
onChange: (n) => Z(n.target.value),
|
|
189
189
|
onBlur: () => G(i.toString())
|
|
190
190
|
}
|
|
191
191
|
)
|
|
192
192
|
] })
|
|
193
193
|
] })
|
|
194
194
|
] }),
|
|
195
|
-
/* @__PURE__ */
|
|
196
|
-
|
|
195
|
+
/* @__PURE__ */ r(
|
|
196
|
+
nn,
|
|
197
197
|
{
|
|
198
198
|
floatingOptions: { placement: "bottom-end" },
|
|
199
|
-
ref:
|
|
200
|
-
className:
|
|
201
|
-
offset:
|
|
199
|
+
ref: R,
|
|
200
|
+
className: o["options-size"],
|
|
201
|
+
offset: _,
|
|
202
202
|
zIndex: q,
|
|
203
203
|
id: `${m}-popover-options-size`,
|
|
204
|
-
children:
|
|
204
|
+
children: U.map((n, c) => /* @__PURE__ */ r(
|
|
205
205
|
"p",
|
|
206
206
|
{
|
|
207
207
|
id: `${m}-option-size-${n}`,
|
|
208
|
-
className: `${
|
|
208
|
+
className: `${o.option} ${n === s ? o.active : ""}`,
|
|
209
209
|
onClick: () => {
|
|
210
210
|
h({
|
|
211
211
|
totalData: t,
|
|
212
|
-
totalPage:
|
|
212
|
+
totalPage: e,
|
|
213
213
|
pageSize: n,
|
|
214
214
|
pageNumber: 1
|
|
215
|
-
}),
|
|
215
|
+
}), R.current?.setShow(!1);
|
|
216
216
|
},
|
|
217
217
|
children: u(n, "decimal")
|
|
218
218
|
},
|
|
@@ -223,5 +223,5 @@ const $ = (t, o) => {
|
|
|
223
223
|
] });
|
|
224
224
|
};
|
|
225
225
|
export {
|
|
226
|
-
|
|
226
|
+
mn as default
|
|
227
227
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t="
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t="_option_169sb_83",n="_active_169sb_105",o={"pagination-box-fin":"_pagination-box-fin_169sb_1","pagination-box":"_pagination-box_169sb_1","pagination-nude":"_pagination-nude_169sb_1","navigation-container":"_navigation-container_169sb_18","button-container":"_button-container_169sb_22","button-next":"_button-next_169sb_22","button-prev":"_button-prev_169sb_22","pagination-active":"_pagination-active_169sb_52","goto-page":"_goto-page_169sb_56","goto-page-input":"_goto-page-input_169sb_62","options-size":"_options-size_169sb_83",option:t,active:n,"pagination-size":"_pagination-size_169sb_117","button-option":"_button-option_169sb_186"};exports.active=n;exports.default=o;exports.option=t;
|
|
@@ -1,20 +1,22 @@
|
|
|
1
|
-
const
|
|
2
|
-
"pagination-
|
|
3
|
-
"pagination-box": "_pagination-
|
|
4
|
-
"pagination-
|
|
5
|
-
"navigation-container": "_navigation-
|
|
6
|
-
"button-container": "_button-
|
|
7
|
-
"button-next": "_button-
|
|
8
|
-
"button-prev": "_button-
|
|
9
|
-
"pagination-active": "_pagination-
|
|
10
|
-
"goto-page": "_goto-
|
|
11
|
-
"goto-page-input": "_goto-page-
|
|
12
|
-
"options-size": "_options-
|
|
13
|
-
option:
|
|
14
|
-
active:
|
|
1
|
+
const n = "_option_169sb_83", t = "_active_169sb_105", o = {
|
|
2
|
+
"pagination-box-fin": "_pagination-box-fin_169sb_1",
|
|
3
|
+
"pagination-box": "_pagination-box_169sb_1",
|
|
4
|
+
"pagination-nude": "_pagination-nude_169sb_1",
|
|
5
|
+
"navigation-container": "_navigation-container_169sb_18",
|
|
6
|
+
"button-container": "_button-container_169sb_22",
|
|
7
|
+
"button-next": "_button-next_169sb_22",
|
|
8
|
+
"button-prev": "_button-prev_169sb_22",
|
|
9
|
+
"pagination-active": "_pagination-active_169sb_52",
|
|
10
|
+
"goto-page": "_goto-page_169sb_56",
|
|
11
|
+
"goto-page-input": "_goto-page-input_169sb_62",
|
|
12
|
+
"options-size": "_options-size_169sb_83",
|
|
13
|
+
option: n,
|
|
14
|
+
active: t,
|
|
15
|
+
"pagination-size": "_pagination-size_169sb_117",
|
|
16
|
+
"button-option": "_button-option_169sb_186"
|
|
15
17
|
};
|
|
16
18
|
export {
|
|
17
|
-
|
|
19
|
+
t as active,
|
|
18
20
|
o as default,
|
|
19
|
-
|
|
21
|
+
n as option
|
|
20
22
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const o=require("react/jsx-runtime"),e=require("@floating-ui/react"),r=require("react"),
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const o=require("react/jsx-runtime"),e=require("@floating-ui/react"),r=require("react"),U=require("./style.module.scss.cjs"),B=require("./Popover.config.cjs"),g=r.forwardRef((m,h)=>{const{children:w,className:P,offset:v=10,isShow:l,anchorEl:a,useAutoPlacement:y=!1,flipOptions:F,autoPlacementOptions:S,zIndex:x=10,width:c,styleInnerPopover:R={},floatingOptions:j={},onClose:u=()=>{},withArrow:M,propsArrow:q={},floatingFocusManagerProps:O,useDismissProps:A,variant:C="white",...I}=m,f=r.useRef(null),[n,i]=r.useState(!1),{refs:d,floatingStyles:T,context:s}=e.useFloating({open:n,onOpenChange:t=>{i(t),t||u()},middleware:[e.offset(v),y?e.autoPlacement(S):e.flip(F),e.shift(),e.arrow({element:f})],whileElementsMounted:e.autoUpdate,...j}),_=e.useClick(s),E=e.useDismiss(s,A),N=e.useRole(s),{getReferenceProps:$,getFloatingProps:b}=e.useInteractions([_,E,N]),{styles:k,isMounted:D}=e.useTransitionStyles(s),p=t=>{d.setReference(t.currentTarget),i(H=>!H),n&&u()};r.useEffect(()=>{l&&a?p({currentTarget:a}):l||i(!1)},[l,a]),r.useImperativeHandle(h,()=>({show:n,setShow:i,handlerShow:p,getReferenceProps:$}),[n]);const z=()=>{let t={...T,...k,...R,zIndex:x};return c&&(t={...t,width:c}),t};return o.jsx(o.Fragment,{children:D&&n&&o.jsx(e.FloatingPortal,{children:o.jsx(e.FloatingFocusManager,{context:s,modal:!1,...O,children:o.jsxs("div",{ref:d.setFloating,style:z(),...b(),className:`${U.default.popover} ${B.configPopover.variant[C]} ${P??""}`,...I,children:[w,M&&o.jsx(e.FloatingArrow,{ref:f,context:s,...q})]})})})})});g.displayName="Popover";exports.default=g;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./style.module.scss.cjs"),t={variant:{white:e.default.white,"white-fin":e.default["white-fin"],"blue-gray-50":e.default["blue-gray-50"]}};exports.configPopover=t;
|
|
@@ -1,78 +1,80 @@
|
|
|
1
|
-
import { jsx as r, Fragment as
|
|
2
|
-
import { useFloating as
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
|
|
1
|
+
import { jsx as r, Fragment as U, jsxs as b } from "react/jsx-runtime";
|
|
2
|
+
import { useFloating as q, autoUpdate as B, offset as G, autoPlacement as J, flip as K, shift as L, arrow as Q, useClick as V, useDismiss as W, useRole as X, useInteractions as Y, useTransitionStyles as Z, FloatingPortal as _, FloatingFocusManager as ee, FloatingArrow as te } from "@floating-ui/react";
|
|
3
|
+
import oe, { forwardRef as se, useState as re, useEffect as ne, useImperativeHandle as ie } from "react";
|
|
4
|
+
import ae from "./style.module.scss.mjs";
|
|
5
|
+
import { configPopover as le } from "./Popover.config.mjs";
|
|
6
|
+
const fe = se((u, m) => {
|
|
6
7
|
const {
|
|
7
8
|
children: d,
|
|
8
9
|
className: g,
|
|
9
10
|
offset: h = 10,
|
|
10
11
|
isShow: n,
|
|
11
|
-
anchorEl:
|
|
12
|
+
anchorEl: i,
|
|
12
13
|
useAutoPlacement: w = !1,
|
|
13
14
|
flipOptions: P,
|
|
14
|
-
autoPlacementOptions:
|
|
15
|
-
zIndex:
|
|
16
|
-
width:
|
|
17
|
-
styleInnerPopover:
|
|
15
|
+
autoPlacementOptions: v,
|
|
16
|
+
zIndex: y = 10,
|
|
17
|
+
width: a,
|
|
18
|
+
styleInnerPopover: F = {},
|
|
18
19
|
floatingOptions: R = {},
|
|
19
|
-
onClose:
|
|
20
|
+
onClose: l = () => {
|
|
20
21
|
},
|
|
21
22
|
withArrow: S,
|
|
22
23
|
propsArrow: x = {},
|
|
23
24
|
floatingFocusManagerProps: A,
|
|
24
25
|
useDismissProps: C,
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
26
|
+
variant: I = "white",
|
|
27
|
+
...M
|
|
28
|
+
} = u, f = oe.useRef(null), [o, s] = re(!1), { refs: c, floatingStyles: O, context: t } = q({
|
|
29
|
+
open: o,
|
|
28
30
|
onOpenChange: (e) => {
|
|
29
|
-
|
|
31
|
+
s(e), e || l();
|
|
30
32
|
},
|
|
31
33
|
middleware: [
|
|
32
|
-
|
|
33
|
-
w ?
|
|
34
|
-
|
|
35
|
-
|
|
34
|
+
G(h),
|
|
35
|
+
w ? J(v) : K(P),
|
|
36
|
+
L(),
|
|
37
|
+
Q({
|
|
36
38
|
element: f
|
|
37
39
|
})
|
|
38
40
|
],
|
|
39
|
-
whileElementsMounted:
|
|
41
|
+
whileElementsMounted: B,
|
|
40
42
|
...R
|
|
41
|
-
}),
|
|
42
|
-
c.setReference(e.currentTarget),
|
|
43
|
+
}), $ = V(t), E = W(t, C), N = X(t), { getReferenceProps: T, getFloatingProps: j } = Y([$, E, N]), { styles: k, isMounted: D } = Z(t), p = (e) => {
|
|
44
|
+
c.setReference(e.currentTarget), s((H) => !H), o && l();
|
|
43
45
|
};
|
|
44
|
-
|
|
45
|
-
n &&
|
|
46
|
-
}, [n,
|
|
46
|
+
ne(() => {
|
|
47
|
+
n && i ? p({ currentTarget: i }) : n || s(!1);
|
|
48
|
+
}, [n, i]), ie(
|
|
47
49
|
m,
|
|
48
50
|
() => ({
|
|
49
|
-
show:
|
|
50
|
-
setShow:
|
|
51
|
-
handlerShow:
|
|
51
|
+
show: o,
|
|
52
|
+
setShow: s,
|
|
53
|
+
handlerShow: p,
|
|
52
54
|
getReferenceProps: T
|
|
53
55
|
}),
|
|
54
|
-
[
|
|
56
|
+
[o]
|
|
55
57
|
);
|
|
56
|
-
const
|
|
57
|
-
let e = { ...
|
|
58
|
-
return
|
|
58
|
+
const z = () => {
|
|
59
|
+
let e = { ...O, ...k, ...F, zIndex: y };
|
|
60
|
+
return a && (e = { ...e, width: a }), e;
|
|
59
61
|
};
|
|
60
|
-
return /* @__PURE__ */ r(
|
|
62
|
+
return /* @__PURE__ */ r(U, { children: D && o && /* @__PURE__ */ r(_, { children: /* @__PURE__ */ r(ee, { context: t, modal: !1, ...A, children: /* @__PURE__ */ b(
|
|
61
63
|
"div",
|
|
62
64
|
{
|
|
63
65
|
ref: c.setFloating,
|
|
64
|
-
style:
|
|
65
|
-
|
|
66
|
-
className: `${
|
|
67
|
-
...
|
|
66
|
+
style: z(),
|
|
67
|
+
...j(),
|
|
68
|
+
className: `${ae.popover} ${le.variant[I]} ${g ?? ""}`,
|
|
69
|
+
...M,
|
|
68
70
|
children: [
|
|
69
71
|
d,
|
|
70
|
-
S && /* @__PURE__ */ r(
|
|
72
|
+
S && /* @__PURE__ */ r(te, { ref: f, context: t, ...x })
|
|
71
73
|
]
|
|
72
74
|
}
|
|
73
75
|
) }) }) });
|
|
74
76
|
});
|
|
75
|
-
|
|
77
|
+
fe.displayName = "Popover";
|
|
76
78
|
export {
|
|
77
|
-
|
|
79
|
+
fe as default
|
|
78
80
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e="
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e="_white_1sas3_1",t="_popover_1sas3_1",o={white:e,popover:t,"white-fin":"_white-fin_1sas3_14","blue-gray-50":"_blue-gray-50_1sas3_30"};exports.default=o;exports.popover=t;exports.white=e;
|
|
@@ -1,7 +1,11 @@
|
|
|
1
|
-
const
|
|
2
|
-
|
|
1
|
+
const e = "_white_1sas3_1", s = "_popover_1sas3_1", _ = {
|
|
2
|
+
white: e,
|
|
3
|
+
popover: s,
|
|
4
|
+
"white-fin": "_white-fin_1sas3_14",
|
|
5
|
+
"blue-gray-50": "_blue-gray-50_1sas3_30"
|
|
3
6
|
};
|
|
4
7
|
export {
|
|
5
|
-
|
|
6
|
-
|
|
8
|
+
_ as default,
|
|
9
|
+
s as popover,
|
|
10
|
+
e as white
|
|
7
11
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../config/components/borderRadius.cjs"),r=require("../../config/components/font.cjs"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../config/components/borderRadius.cjs"),r=require("../../config/components/font.cjs"),t=require("../../config/components/typography.cjs"),a=require("./RadioCheckbox.module.scss.cjs"),l={size:{reguler:a.default["input-radio-checkbox-reguler"],small:a.default["input-radio-checkbox-small"],m:a.default["input-radio-checkbox-m"],s:a.default["input-radio-checkbox-s"]},variants:{"laba-blue-10":a.default["laba-blue-10"],"laba-blue-10-hv_bg_transparent":a.default["laba-blue-10-hv_bg_transparent"],"blue-700":a.default["blue-700"],"blue-700-hv_bg_transparent":a.default["blue-700-hv_bg_transparent"],"bill-primary-500":a.default["bill-primary-500"],"bill-primary-600-hv_bg_transparent":a.default["bill-primary-600-hv_bg_transparent"],"bill-secondary-800-hv_bg_transparent":a.default["bill-secondary-800-hv_bg_transparent"],"fin-primary-500-hv_bg_transparent":a.default["fin-primary-500-hv_bg_transparent"],"fin-primary-500":a.default["fin-primary-500"]},variantDisableds:{"default-disabled-checkbox":a.default["default-disabled-checkbox"],"default-disabled-radio":a.default["default-disabled-radio"]},borderRadius:e.configBorderRadius,typography:t.configtypography,fonts:r.configFont};exports.configRadioCheckbox=l;
|
|
@@ -1,31 +1,33 @@
|
|
|
1
|
-
import { configBorderRadius as
|
|
2
|
-
import { configFont as
|
|
3
|
-
import { configtypography as
|
|
4
|
-
import
|
|
5
|
-
const
|
|
1
|
+
import { configBorderRadius as a } from "../../config/components/borderRadius.mjs";
|
|
2
|
+
import { configFont as i } from "../../config/components/font.mjs";
|
|
3
|
+
import { configtypography as e } from "../../config/components/typography.mjs";
|
|
4
|
+
import r from "./RadioCheckbox.module.scss.mjs";
|
|
5
|
+
const o = {
|
|
6
6
|
size: {
|
|
7
|
-
reguler:
|
|
8
|
-
small:
|
|
9
|
-
m:
|
|
10
|
-
s:
|
|
7
|
+
reguler: r["input-radio-checkbox-reguler"],
|
|
8
|
+
small: r["input-radio-checkbox-small"],
|
|
9
|
+
m: r["input-radio-checkbox-m"],
|
|
10
|
+
s: r["input-radio-checkbox-s"]
|
|
11
11
|
},
|
|
12
12
|
variants: {
|
|
13
|
-
"laba-blue-10":
|
|
14
|
-
"laba-blue-10-hv_bg_transparent":
|
|
15
|
-
"blue-700":
|
|
16
|
-
"blue-700-hv_bg_transparent":
|
|
17
|
-
"bill-primary-500":
|
|
18
|
-
"bill-primary-600-hv_bg_transparent":
|
|
19
|
-
"bill-secondary-800-hv_bg_transparent":
|
|
13
|
+
"laba-blue-10": r["laba-blue-10"],
|
|
14
|
+
"laba-blue-10-hv_bg_transparent": r["laba-blue-10-hv_bg_transparent"],
|
|
15
|
+
"blue-700": r["blue-700"],
|
|
16
|
+
"blue-700-hv_bg_transparent": r["blue-700-hv_bg_transparent"],
|
|
17
|
+
"bill-primary-500": r["bill-primary-500"],
|
|
18
|
+
"bill-primary-600-hv_bg_transparent": r["bill-primary-600-hv_bg_transparent"],
|
|
19
|
+
"bill-secondary-800-hv_bg_transparent": r["bill-secondary-800-hv_bg_transparent"],
|
|
20
|
+
"fin-primary-500-hv_bg_transparent": r["fin-primary-500-hv_bg_transparent"],
|
|
21
|
+
"fin-primary-500": r["fin-primary-500"]
|
|
20
22
|
},
|
|
21
23
|
variantDisableds: {
|
|
22
|
-
"default-disabled-checkbox":
|
|
23
|
-
"default-disabled-radio":
|
|
24
|
+
"default-disabled-checkbox": r["default-disabled-checkbox"],
|
|
25
|
+
"default-disabled-radio": r["default-disabled-radio"]
|
|
24
26
|
},
|
|
25
|
-
borderRadius:
|
|
26
|
-
typography:
|
|
27
|
-
fonts:
|
|
27
|
+
borderRadius: a,
|
|
28
|
+
typography: e,
|
|
29
|
+
fonts: i
|
|
28
30
|
};
|
|
29
31
|
export {
|
|
30
|
-
|
|
32
|
+
o as configRadioCheckbox
|
|
31
33
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const _="_container_8svpp_1",a="_label_8svpp_239",e="_disabled_8svpp_243",p={container:_,"container-input":"_container-input_8svpp_1","input-radio-checkbox-s":"_input-radio-checkbox-s_8svpp_1","input-radio-checkbox-m":"_input-radio-checkbox-m_8svpp_1","input-radio-checkbox-small":"_input-radio-checkbox-small_8svpp_1","input-radio-checkbox-reguler":"_input-radio-checkbox-reguler_8svpp_1","checked-icon":"_checked-icon_8svpp_11","default-disabled-radio":"_default-disabled-radio_8svpp_48","default-disabled-checkbox":"_default-disabled-checkbox_8svpp_58","laba-blue-10":"_laba-blue-10_8svpp_66","laba-blue-10-hv_bg_transparent":"_laba-blue-10-hv_bg_transparent_8svpp_78","blue-700":"_blue-700_8svpp_90","blue-700-hv_bg_transparent":"_blue-700-hv_bg_transparent_8svpp_102","bill-primary-500":"_bill-primary-500_8svpp_114","bill-primary-600-hv_bg_transparent":"_bill-primary-600-hv_bg_transparent_8svpp_126","bill-secondary-800-hv_bg_transparent":"_bill-secondary-800-hv_bg_transparent_8svpp_138","fin-primary-500":"_fin-primary-500_8svpp_150","fin-primary-500-hv_bg_transparent":"_fin-primary-500-hv_bg_transparent_8svpp_188",label:a,disabled:e};exports.container=_;exports.default=p;exports.disabled=e;exports.label=a;
|