@namuna-nur/ui-kit 1.10.6 → 1.10.7
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/atoms/index.js +549 -1734
- package/lib/index.js +29 -27
- package/lib/molecules/index.js +644 -644
- package/lib/src/atoms/ReplyMessage/ReplyMessage.data.d.ts +1 -0
- package/lib/src/atoms/ReplyMessage/ReplyMessage.stories.d.ts +2 -3
- package/lib/src/atoms/ReplyMessage/ReplyMessage.types.d.ts +3 -0
- package/lib/src/atoms/ReplyMessage/ReplyMessage.utils.d.ts +1 -0
- package/lib/src/molecules/CardFiles/CardFiles.types.d.ts +2 -2
- package/lib/src/molecules/DocumentMessage/DocumentMessage.d.ts +1 -1
- package/lib/src/molecules/DocumentMessage/DocumentMessage.data.d.ts +3 -3
- package/lib/src/molecules/DocumentMessage/DocumentMessage.types.d.ts +2 -2
- package/lib/src/molecules/FileCard/FileCard.d.ts +1 -1
- package/lib/src/molecules/FileCard/FileCard.types.d.ts +1 -1
- package/lib/src/molecules/PaymentCard/PaymentCard.d.ts +1 -1
- package/lib/src/molecules/PaymentCard/PaymentCard.types.d.ts +1 -1
- package/lib/src/utils/date.d.ts +2 -0
- package/lib/utils/index.js +37 -29
- package/package.json +1 -1
package/lib/atoms/index.js
CHANGED
|
@@ -1,33 +1,18 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
import "
|
|
5
|
-
import "
|
|
6
|
-
import
|
|
7
|
-
import "
|
|
8
|
-
import "@radix-ui/react-
|
|
9
|
-
import "
|
|
10
|
-
import "
|
|
11
|
-
import "
|
|
12
|
-
import "
|
|
13
|
-
import {
|
|
14
|
-
import
|
|
15
|
-
|
|
16
|
-
import { T as Ee, a as je, P as Ae, b as We, c as Re } from "../shared/shared.js";
|
|
17
|
-
import * as X from "@radix-ui/react-switch";
|
|
18
|
-
import { S as Le, a as De } from "../shared/assets-icons-3.js";
|
|
19
|
-
import * as He from "@radix-ui/react-tooltip";
|
|
20
|
-
import { S as Me, a as Oe } from "../shared/assets-icons-2.js";
|
|
21
|
-
import { useOption as qe } from "../hooks/index.js";
|
|
22
|
-
import { Avatar as ge, AvatarImage as fe, AvatarFallback as me } from "@radix-ui/react-avatar";
|
|
23
|
-
import { format as Ie } from "date-fns";
|
|
24
|
-
import { clsx as Pe } from "clsx";
|
|
25
|
-
import { extendTailwindMerge as _e } from "tailwind-merge";
|
|
26
|
-
import { PieChart as Ve, LineChart as Ge } from "echarts/charts";
|
|
27
|
-
import { GridComponent as Ne, TitleComponent as Ue, TooltipComponent as Je, LegendComponent as Ke } from "echarts/components";
|
|
28
|
-
import * as Qe from "echarts/core";
|
|
29
|
-
import { CanvasRenderer as Xe } from "echarts/renderers";
|
|
30
|
-
const P = {
|
|
1
|
+
import { jsxs as c, jsx as i } from "react/jsx-runtime";
|
|
2
|
+
import * as W from "react";
|
|
3
|
+
import { forwardRef as F, useState as te, useRef as G } from "react";
|
|
4
|
+
import { cn as n } from "../utils/index.js";
|
|
5
|
+
import { S as X, a as H, b as oe } from "../shared/assets-icons-4.js";
|
|
6
|
+
import { S as U, a as ie, b as ae, c as ne, d as de } from "../shared/assets-icons-0.js";
|
|
7
|
+
import { T as le, a as se, P as be, b as ce, c as ue } from "../shared/shared.js";
|
|
8
|
+
import * as Y from "@radix-ui/react-switch";
|
|
9
|
+
import { S as pe, a as fe } from "../shared/assets-icons-3.js";
|
|
10
|
+
import * as ge from "@radix-ui/react-tooltip";
|
|
11
|
+
import { S as he, a as xe } from "../shared/assets-icons-2.js";
|
|
12
|
+
import { useOption as ve } from "../hooks/index.js";
|
|
13
|
+
import { Avatar as ye, AvatarImage as me, AvatarFallback as ke } from "@radix-ui/react-avatar";
|
|
14
|
+
import * as V from "@radix-ui/react-tabs";
|
|
15
|
+
const L = {
|
|
31
16
|
base: "group inline-flex items-center justify-center transition-colors rounded-[10px] border outline-none",
|
|
32
17
|
icon: {
|
|
33
18
|
disabled: {
|
|
@@ -78,135 +63,135 @@ const P = {
|
|
|
78
63
|
hover: "hover:bg-transparent hover:text-primary-20 hover:border-transparent"
|
|
79
64
|
}
|
|
80
65
|
}
|
|
81
|
-
},
|
|
66
|
+
}, Xe = F(
|
|
82
67
|
({
|
|
83
68
|
children: e,
|
|
84
69
|
classNames: r,
|
|
85
|
-
disabled:
|
|
86
|
-
icon:
|
|
87
|
-
iconDimensions:
|
|
88
|
-
iconPosition:
|
|
89
|
-
size:
|
|
90
|
-
variant:
|
|
91
|
-
isShadow:
|
|
70
|
+
disabled: a = !1,
|
|
71
|
+
icon: o,
|
|
72
|
+
iconDimensions: d = { height: 15, width: 15 },
|
|
73
|
+
iconPosition: s = "right",
|
|
74
|
+
size: l = "medium",
|
|
75
|
+
variant: t = "primary",
|
|
76
|
+
isShadow: b = !1,
|
|
92
77
|
...u
|
|
93
|
-
},
|
|
94
|
-
const
|
|
95
|
-
return /* @__PURE__ */
|
|
78
|
+
}, p) => {
|
|
79
|
+
const f = L.icon, g = L.sizes[l], h = L.variants[t] || L.variants.primary, y = f.variants[t], x = f.disabled[t];
|
|
80
|
+
return /* @__PURE__ */ c(
|
|
96
81
|
"button",
|
|
97
82
|
{
|
|
98
83
|
role: "button",
|
|
99
84
|
...u,
|
|
100
85
|
type: u.type || "button",
|
|
101
|
-
ref:
|
|
102
|
-
disabled:
|
|
103
|
-
className:
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
!
|
|
110
|
-
!
|
|
111
|
-
|
|
112
|
-
!!
|
|
113
|
-
!!
|
|
114
|
-
|
|
86
|
+
ref: p,
|
|
87
|
+
disabled: a,
|
|
88
|
+
className: n(
|
|
89
|
+
L.base,
|
|
90
|
+
g.padding,
|
|
91
|
+
g.fontSize,
|
|
92
|
+
h.base,
|
|
93
|
+
h.focus,
|
|
94
|
+
!a && h.hover,
|
|
95
|
+
!a && h.active,
|
|
96
|
+
a && h.disabled,
|
|
97
|
+
!!o && f.parent,
|
|
98
|
+
!!o && !e && "min-w-0",
|
|
99
|
+
t === "primary" && b && "shadow-3xl",
|
|
115
100
|
r == null ? void 0 : r.base
|
|
116
101
|
),
|
|
117
102
|
children: [
|
|
118
|
-
!!
|
|
119
|
-
|
|
103
|
+
!!o && s === "left" && /* @__PURE__ */ i(
|
|
104
|
+
o,
|
|
120
105
|
{
|
|
121
106
|
"aria-label": "icon",
|
|
122
107
|
"aria-hidden": !0,
|
|
123
|
-
className:
|
|
124
|
-
!
|
|
125
|
-
|
|
108
|
+
className: n(
|
|
109
|
+
!a && y,
|
|
110
|
+
a && x,
|
|
126
111
|
r == null ? void 0 : r.icon
|
|
127
112
|
),
|
|
128
|
-
height:
|
|
129
|
-
width:
|
|
130
|
-
viewBox:
|
|
113
|
+
height: d.height,
|
|
114
|
+
width: d.width,
|
|
115
|
+
viewBox: d.viewBox
|
|
131
116
|
}
|
|
132
117
|
),
|
|
133
118
|
e,
|
|
134
|
-
!!
|
|
135
|
-
|
|
119
|
+
!!o && s === "right" && /* @__PURE__ */ i(
|
|
120
|
+
o,
|
|
136
121
|
{
|
|
137
122
|
"aria-label": "icon",
|
|
138
123
|
"aria-hidden": !0,
|
|
139
|
-
className:
|
|
140
|
-
!
|
|
141
|
-
|
|
124
|
+
className: n(
|
|
125
|
+
!a && y,
|
|
126
|
+
a && x,
|
|
142
127
|
r == null ? void 0 : r.icon
|
|
143
128
|
),
|
|
144
|
-
height:
|
|
145
|
-
width:
|
|
146
|
-
viewBox:
|
|
129
|
+
height: d.height,
|
|
130
|
+
width: d.width,
|
|
131
|
+
viewBox: d.viewBox
|
|
147
132
|
}
|
|
148
133
|
)
|
|
149
134
|
]
|
|
150
135
|
}
|
|
151
136
|
);
|
|
152
137
|
}
|
|
153
|
-
),
|
|
138
|
+
), we = F(
|
|
154
139
|
({
|
|
155
140
|
classNames: e,
|
|
156
141
|
disabled: r = !1,
|
|
157
|
-
icon:
|
|
158
|
-
variant:
|
|
159
|
-
shape:
|
|
160
|
-
badge:
|
|
161
|
-
iconSizes:
|
|
162
|
-
text:
|
|
163
|
-
...
|
|
142
|
+
icon: a,
|
|
143
|
+
variant: o = "default",
|
|
144
|
+
shape: d,
|
|
145
|
+
badge: s,
|
|
146
|
+
iconSizes: l,
|
|
147
|
+
text: t,
|
|
148
|
+
...b
|
|
164
149
|
}, u) => {
|
|
165
|
-
var
|
|
166
|
-
const
|
|
167
|
-
return /* @__PURE__ */
|
|
150
|
+
var x;
|
|
151
|
+
const p = R.icon, f = R.variants[o], g = p.variants[o], h = (x = R.shape) == null ? void 0 : x[d], y = p.disabled[o];
|
|
152
|
+
return /* @__PURE__ */ c(
|
|
168
153
|
"button",
|
|
169
154
|
{
|
|
170
|
-
...
|
|
155
|
+
...b,
|
|
171
156
|
role: "button",
|
|
172
|
-
type:
|
|
157
|
+
type: b.type || "button",
|
|
173
158
|
ref: u,
|
|
174
159
|
disabled: r,
|
|
175
|
-
className:
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
!r &&
|
|
182
|
-
!r &&
|
|
183
|
-
r &&
|
|
160
|
+
className: n(
|
|
161
|
+
R.base,
|
|
162
|
+
f.base,
|
|
163
|
+
f.focus,
|
|
164
|
+
h,
|
|
165
|
+
s && R.badgeStyles.base,
|
|
166
|
+
!r && f.hover,
|
|
167
|
+
!r && f.active,
|
|
168
|
+
r && f.disabled,
|
|
184
169
|
e == null ? void 0 : e.button
|
|
185
170
|
),
|
|
186
171
|
children: [
|
|
187
|
-
|
|
188
|
-
!!
|
|
189
|
-
|
|
172
|
+
s && /* @__PURE__ */ i("span", { className: R.badgeStyles.badgeStyles, children: s }),
|
|
173
|
+
!!a && /* @__PURE__ */ i(
|
|
174
|
+
a,
|
|
190
175
|
{
|
|
191
176
|
"aria-label": "icon",
|
|
192
177
|
"aria-hidden": !0,
|
|
193
|
-
className:
|
|
194
|
-
|
|
195
|
-
!r &&
|
|
196
|
-
r &&
|
|
178
|
+
className: n(
|
|
179
|
+
p.base,
|
|
180
|
+
!r && g,
|
|
181
|
+
r && y,
|
|
197
182
|
e == null ? void 0 : e.icon
|
|
198
183
|
),
|
|
199
|
-
height:
|
|
200
|
-
width:
|
|
201
|
-
viewBox:
|
|
184
|
+
height: l == null ? void 0 : l.height,
|
|
185
|
+
width: l == null ? void 0 : l.width,
|
|
186
|
+
viewBox: l == null ? void 0 : l.viewBox
|
|
202
187
|
}
|
|
203
188
|
),
|
|
204
|
-
!!
|
|
189
|
+
!!t && /* @__PURE__ */ i(w, { className: e == null ? void 0 : e.text, children: t })
|
|
205
190
|
]
|
|
206
191
|
}
|
|
207
192
|
);
|
|
208
193
|
}
|
|
209
|
-
),
|
|
194
|
+
), R = {
|
|
210
195
|
base: "group inline-flex items-center justify-center rounded-[10px] outline-none border",
|
|
211
196
|
icon: {
|
|
212
197
|
base: "text-inherit",
|
|
@@ -252,7 +237,7 @@ const P = {
|
|
|
252
237
|
disabled: "disabled:border-transparent disabled:cursor-default"
|
|
253
238
|
}
|
|
254
239
|
}
|
|
255
|
-
},
|
|
240
|
+
}, B = {
|
|
256
241
|
active: "active:bg-tertiary-10 active:border-tertiary-10 outline-none",
|
|
257
242
|
base: "border border-secondary-10/[.25] hover:border-primary-10 flex items-center justify-center rounded-[6px] cursor-pointer",
|
|
258
243
|
checked: "bg-primary-10 border-primary-10",
|
|
@@ -269,134 +254,134 @@ const P = {
|
|
|
269
254
|
label: "size-2.5"
|
|
270
255
|
}
|
|
271
256
|
}
|
|
272
|
-
},
|
|
257
|
+
}, Ye = F(
|
|
273
258
|
({
|
|
274
259
|
checked: e = !1,
|
|
275
260
|
className: r = "",
|
|
276
|
-
disabled:
|
|
277
|
-
id:
|
|
278
|
-
onChange:
|
|
279
|
-
size:
|
|
280
|
-
...
|
|
281
|
-
},
|
|
282
|
-
const
|
|
283
|
-
return /* @__PURE__ */
|
|
261
|
+
disabled: a,
|
|
262
|
+
id: o,
|
|
263
|
+
onChange: d,
|
|
264
|
+
size: s = "large",
|
|
265
|
+
...l
|
|
266
|
+
}, t) => {
|
|
267
|
+
const b = B.base, u = B.sizes[s];
|
|
268
|
+
return /* @__PURE__ */ c(
|
|
284
269
|
"label",
|
|
285
270
|
{
|
|
286
271
|
"aria-label": "checkbox-label",
|
|
287
|
-
htmlFor:
|
|
272
|
+
htmlFor: o,
|
|
288
273
|
tabIndex: 0,
|
|
289
|
-
className:
|
|
274
|
+
className: n(
|
|
290
275
|
u.label,
|
|
291
|
-
|
|
292
|
-
e &&
|
|
293
|
-
!
|
|
294
|
-
!
|
|
295
|
-
|
|
276
|
+
b,
|
|
277
|
+
e && B.checked,
|
|
278
|
+
!a && B.active,
|
|
279
|
+
!a && e && B.hover,
|
|
280
|
+
a && B.disabled,
|
|
296
281
|
r
|
|
297
282
|
),
|
|
298
283
|
children: [
|
|
299
|
-
/* @__PURE__ */
|
|
284
|
+
/* @__PURE__ */ i(
|
|
300
285
|
"input",
|
|
301
286
|
{
|
|
302
|
-
...
|
|
287
|
+
...l,
|
|
303
288
|
role: "checkbox",
|
|
304
|
-
id:
|
|
305
|
-
disabled:
|
|
289
|
+
id: o,
|
|
290
|
+
disabled: a,
|
|
306
291
|
checked: !!e,
|
|
307
|
-
onChange:
|
|
308
|
-
ref:
|
|
292
|
+
onChange: d,
|
|
293
|
+
ref: t,
|
|
309
294
|
type: "checkbox",
|
|
310
295
|
className: "hidden peer"
|
|
311
296
|
}
|
|
312
297
|
),
|
|
313
|
-
/* @__PURE__ */
|
|
314
|
-
|
|
298
|
+
/* @__PURE__ */ i(
|
|
299
|
+
X,
|
|
315
300
|
{
|
|
316
301
|
width: 20,
|
|
317
302
|
height: 18,
|
|
318
303
|
viewBox: "0 0 20 20",
|
|
319
|
-
className:
|
|
304
|
+
className: n("opacity-0 fill-sidebar-10", e && "!opacity-100")
|
|
320
305
|
}
|
|
321
306
|
)
|
|
322
307
|
]
|
|
323
308
|
}
|
|
324
309
|
);
|
|
325
310
|
}
|
|
326
|
-
),
|
|
311
|
+
), Se = {
|
|
327
312
|
h1: "text-h1",
|
|
328
313
|
h2: "text-h2",
|
|
329
314
|
h3: "text-h3",
|
|
330
315
|
h4: "text-h4",
|
|
331
316
|
h5: "text-h5",
|
|
332
317
|
h6: "text-h6"
|
|
333
|
-
},
|
|
318
|
+
}, Ze = ({
|
|
334
319
|
children: e,
|
|
335
320
|
className: r = "",
|
|
336
|
-
variant:
|
|
337
|
-
weight:
|
|
338
|
-
...
|
|
339
|
-
}) => /* @__PURE__ */
|
|
340
|
-
|
|
321
|
+
variant: a = "h1",
|
|
322
|
+
weight: o = "font-regular",
|
|
323
|
+
...d
|
|
324
|
+
}) => /* @__PURE__ */ i(
|
|
325
|
+
a,
|
|
341
326
|
{
|
|
342
|
-
...
|
|
343
|
-
className:
|
|
327
|
+
...d,
|
|
328
|
+
className: n(Se[a], o, r),
|
|
344
329
|
children: e
|
|
345
330
|
}
|
|
346
|
-
),
|
|
331
|
+
), Ne = F(
|
|
347
332
|
({
|
|
348
333
|
disabled: e,
|
|
349
334
|
onChange: r,
|
|
350
|
-
placeholder:
|
|
351
|
-
autoFocus:
|
|
352
|
-
status:
|
|
353
|
-
maxLength:
|
|
354
|
-
id:
|
|
355
|
-
classNames:
|
|
356
|
-
...
|
|
335
|
+
placeholder: a,
|
|
336
|
+
autoFocus: o = !1,
|
|
337
|
+
status: d,
|
|
338
|
+
maxLength: s,
|
|
339
|
+
id: l,
|
|
340
|
+
classNames: t,
|
|
341
|
+
...b
|
|
357
342
|
}, u) => {
|
|
358
|
-
const
|
|
359
|
-
return /* @__PURE__ */
|
|
360
|
-
/* @__PURE__ */
|
|
343
|
+
const p = z.parent, f = z.base, g = z.state, h = z.disabled, y = z.styles, x = z.maxLength;
|
|
344
|
+
return /* @__PURE__ */ c("div", { className: n(p, t == null ? void 0 : t.parent), children: [
|
|
345
|
+
/* @__PURE__ */ i(
|
|
361
346
|
"input",
|
|
362
347
|
{
|
|
363
|
-
...
|
|
348
|
+
...b,
|
|
364
349
|
role: "textbox",
|
|
365
350
|
ref: u,
|
|
366
|
-
id:
|
|
351
|
+
id: l,
|
|
367
352
|
disabled: e,
|
|
368
|
-
autoFocus:
|
|
353
|
+
autoFocus: o,
|
|
369
354
|
onChange: r,
|
|
370
|
-
maxLength:
|
|
371
|
-
className:
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
!e &&
|
|
375
|
-
|
|
376
|
-
e &&
|
|
377
|
-
|
|
355
|
+
maxLength: s,
|
|
356
|
+
className: n(
|
|
357
|
+
f,
|
|
358
|
+
g.focus,
|
|
359
|
+
!e && g.hover,
|
|
360
|
+
d && (y == null ? void 0 : y[d]),
|
|
361
|
+
e && h,
|
|
362
|
+
t == null ? void 0 : t.target
|
|
378
363
|
),
|
|
379
|
-
placeholder:
|
|
364
|
+
placeholder: a
|
|
380
365
|
}
|
|
381
366
|
),
|
|
382
|
-
|
|
383
|
-
|
|
367
|
+
s && /* @__PURE__ */ c(
|
|
368
|
+
w,
|
|
384
369
|
{
|
|
385
370
|
variant: "span",
|
|
386
|
-
className:
|
|
387
|
-
|
|
388
|
-
String(
|
|
371
|
+
className: n(
|
|
372
|
+
x,
|
|
373
|
+
String(b.value).length === s ? "bg-danger-10" : "bg-success-10"
|
|
389
374
|
),
|
|
390
375
|
children: [
|
|
391
|
-
(
|
|
376
|
+
(b.value || "").toString().length,
|
|
392
377
|
"/",
|
|
393
|
-
|
|
378
|
+
s
|
|
394
379
|
]
|
|
395
380
|
}
|
|
396
381
|
)
|
|
397
382
|
] });
|
|
398
383
|
}
|
|
399
|
-
),
|
|
384
|
+
), z = {
|
|
400
385
|
parent: "relative flex flex-col items-start w-full",
|
|
401
386
|
base: "text-dark-10 text-sm leading-none w-full rounded-[10px] bg-gray-50 border border-gray-50 p-[12.5px] placeholder:text-dark-10/[.40]",
|
|
402
387
|
disabled: "bg-secondary-10/[.08] text-gray-30 cursor-not-allowed",
|
|
@@ -411,91 +396,91 @@ const P = {
|
|
|
411
396
|
success: "bg-white border-success-10 ring-2 ring-success-10/[.20] hover:border-success-10"
|
|
412
397
|
},
|
|
413
398
|
maxLength: "ml-auto px-1 mt-1 text-body-10 text-white rounded"
|
|
414
|
-
},
|
|
415
|
-
({ htmlFor: e, className: r, children:
|
|
416
|
-
const
|
|
417
|
-
return /* @__PURE__ */
|
|
399
|
+
}, er = W.forwardRef(
|
|
400
|
+
({ htmlFor: e, className: r, children: a, disabled: o, ...d }, s) => {
|
|
401
|
+
const l = J.base, t = J.disabled;
|
|
402
|
+
return /* @__PURE__ */ i(
|
|
418
403
|
"label",
|
|
419
404
|
{
|
|
420
|
-
...
|
|
405
|
+
...d,
|
|
421
406
|
role: "presentation",
|
|
422
407
|
"aria-label": "input-label",
|
|
423
|
-
ref:
|
|
408
|
+
ref: s,
|
|
424
409
|
htmlFor: e,
|
|
425
|
-
className:
|
|
426
|
-
children:
|
|
410
|
+
className: n(l, o && t, r),
|
|
411
|
+
children: a
|
|
427
412
|
}
|
|
428
413
|
);
|
|
429
414
|
}
|
|
430
|
-
),
|
|
415
|
+
), J = {
|
|
431
416
|
base: "text-secondary-10 text-sm font-sans font-semibold leading-none",
|
|
432
417
|
disabled: "text-dark-30/25 cursor-not-allowed"
|
|
433
|
-
},
|
|
434
|
-
success: /* @__PURE__ */
|
|
435
|
-
danger: /* @__PURE__ */
|
|
436
|
-
info: /* @__PURE__ */
|
|
437
|
-
warning: /* @__PURE__ */
|
|
438
|
-
default: /* @__PURE__ */
|
|
439
|
-
},
|
|
418
|
+
}, Te = {
|
|
419
|
+
success: /* @__PURE__ */ i(U, { className: "text-sidebar-10 fill-sidebar-10" }),
|
|
420
|
+
danger: /* @__PURE__ */ i(ne, { className: "text-sidebar-10 fill-sidebar-10" }),
|
|
421
|
+
info: /* @__PURE__ */ i(ae, { className: "text-sidebar-10 fill-sidebar-10" }),
|
|
422
|
+
warning: /* @__PURE__ */ i(ie, { className: "text-sidebar-10 fill-sidebar-10" }),
|
|
423
|
+
default: /* @__PURE__ */ i(U, { className: "text-sidebar-10 fill-sidebar-10" })
|
|
424
|
+
}, rr = ({
|
|
440
425
|
type: e = "info",
|
|
441
426
|
title: r,
|
|
442
|
-
description:
|
|
443
|
-
withIcon:
|
|
444
|
-
}) => /* @__PURE__ */
|
|
427
|
+
description: a,
|
|
428
|
+
withIcon: o = !0
|
|
429
|
+
}) => /* @__PURE__ */ c(
|
|
445
430
|
"div",
|
|
446
431
|
{
|
|
447
|
-
className:
|
|
448
|
-
|
|
432
|
+
className: n(
|
|
433
|
+
o ? "items-start" : "justify-center",
|
|
449
434
|
"flex items-center gap-1.5"
|
|
450
435
|
),
|
|
451
436
|
children: [
|
|
452
|
-
|
|
453
|
-
/* @__PURE__ */
|
|
454
|
-
/* @__PURE__ */
|
|
455
|
-
/* @__PURE__ */
|
|
437
|
+
o && /* @__PURE__ */ i("div", { "data-testid": "notification-icon", children: e && Te[e] }),
|
|
438
|
+
/* @__PURE__ */ c("div", { className: "flex flex-col", children: [
|
|
439
|
+
/* @__PURE__ */ i(le, { className: o ? "text-left" : "text-center", children: r }),
|
|
440
|
+
/* @__PURE__ */ i(se, { className: o ? "text-left" : "text-center", children: a })
|
|
456
441
|
] })
|
|
457
442
|
]
|
|
458
443
|
}
|
|
459
|
-
),
|
|
460
|
-
({ checked: e, disabled: r, id:
|
|
461
|
-
const
|
|
462
|
-
return /* @__PURE__ */
|
|
444
|
+
), je = F(
|
|
445
|
+
({ checked: e, disabled: r, id: a, onChange: o, size: d = "large", className: s, ...l }, t) => {
|
|
446
|
+
const b = S.sizes[d];
|
|
447
|
+
return /* @__PURE__ */ c(
|
|
463
448
|
"label",
|
|
464
449
|
{
|
|
465
|
-
htmlFor:
|
|
450
|
+
htmlFor: a,
|
|
466
451
|
"aria-label": "radio-label",
|
|
467
|
-
className:
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
r &&
|
|
471
|
-
!r &&
|
|
472
|
-
!e && !r &&
|
|
473
|
-
!r && e &&
|
|
474
|
-
|
|
452
|
+
className: n(
|
|
453
|
+
S.base,
|
|
454
|
+
b.label,
|
|
455
|
+
r && S.disabled,
|
|
456
|
+
!r && S.active,
|
|
457
|
+
!e && !r && S.hover,
|
|
458
|
+
!r && e && S.checked,
|
|
459
|
+
s
|
|
475
460
|
),
|
|
476
461
|
children: [
|
|
477
|
-
/* @__PURE__ */
|
|
462
|
+
/* @__PURE__ */ i(
|
|
478
463
|
"input",
|
|
479
464
|
{
|
|
480
|
-
...
|
|
481
|
-
id:
|
|
482
|
-
ref:
|
|
465
|
+
...l,
|
|
466
|
+
id: a,
|
|
467
|
+
ref: t,
|
|
483
468
|
type: "radio",
|
|
484
469
|
role: "radio",
|
|
485
470
|
checked: e,
|
|
486
471
|
disabled: r,
|
|
487
|
-
onChange:
|
|
472
|
+
onChange: o,
|
|
488
473
|
className: "hidden peer",
|
|
489
474
|
"aria-checked": e,
|
|
490
|
-
readOnly: !
|
|
475
|
+
readOnly: !o
|
|
491
476
|
}
|
|
492
477
|
),
|
|
493
|
-
/* @__PURE__ */
|
|
478
|
+
/* @__PURE__ */ i(
|
|
494
479
|
"span",
|
|
495
480
|
{
|
|
496
481
|
"aria-hidden": "true",
|
|
497
|
-
className:
|
|
498
|
-
e ? [
|
|
482
|
+
className: n(
|
|
483
|
+
e ? [S.radio.base, S.radio[d]] : "opacity-0",
|
|
499
484
|
r && "bg-primary-30"
|
|
500
485
|
)
|
|
501
486
|
}
|
|
@@ -505,8 +490,8 @@ const P = {
|
|
|
505
490
|
);
|
|
506
491
|
}
|
|
507
492
|
);
|
|
508
|
-
|
|
509
|
-
const
|
|
493
|
+
je.displayName = "Radio";
|
|
494
|
+
const S = {
|
|
510
495
|
base: "border-2 border-dark-30/[.15] flex items-center justify-center rounded-full cursor-pointer outline-none bg-sidebar-10/[.08]",
|
|
511
496
|
active: "active:border-primary-10",
|
|
512
497
|
hover: "hover:border-primary-20/[.30]",
|
|
@@ -525,18 +510,18 @@ const z = {
|
|
|
525
510
|
label: "size-5 min-w-5"
|
|
526
511
|
}
|
|
527
512
|
}
|
|
528
|
-
},
|
|
513
|
+
}, tr = ({
|
|
529
514
|
text: e,
|
|
530
515
|
variant: r = "default",
|
|
531
|
-
className:
|
|
532
|
-
}) => /* @__PURE__ */
|
|
533
|
-
|
|
516
|
+
className: a
|
|
517
|
+
}) => /* @__PURE__ */ i(
|
|
518
|
+
w,
|
|
534
519
|
{
|
|
535
|
-
className:
|
|
520
|
+
className: n(K.base, K.status[r], a),
|
|
536
521
|
"data-testid": "status",
|
|
537
522
|
children: e
|
|
538
523
|
}
|
|
539
|
-
),
|
|
524
|
+
), K = {
|
|
540
525
|
base: "inline-flex rounded-[50px] cursor-pointer px-2.5 py-1.5 text-dark-40/[.80] text-xs font-medium leading-none",
|
|
541
526
|
status: {
|
|
542
527
|
success: "bg-success-30",
|
|
@@ -545,47 +530,47 @@ const z = {
|
|
|
545
530
|
warning: "bg-status-30",
|
|
546
531
|
default: "bg-dark-30/[.15]"
|
|
547
532
|
}
|
|
548
|
-
}, { Root:
|
|
549
|
-
const
|
|
550
|
-
return /* @__PURE__ */
|
|
551
|
-
/* @__PURE__ */
|
|
533
|
+
}, { Root: Ce, Thumb: Ae } = Y, or = W.forwardRef(({ classNames: e, ...r }, a) => {
|
|
534
|
+
const o = r.checked ?? !1;
|
|
535
|
+
return /* @__PURE__ */ c(Ce, { ref: a, className: n(C.base, e == null ? void 0 : e.root), ...r, children: [
|
|
536
|
+
/* @__PURE__ */ i(
|
|
552
537
|
"div",
|
|
553
538
|
{
|
|
554
|
-
className:
|
|
555
|
-
|
|
539
|
+
className: n(
|
|
540
|
+
C.iconWrapper.base,
|
|
556
541
|
"left-0",
|
|
557
|
-
!
|
|
542
|
+
!o && C.iconWrapper.checked
|
|
558
543
|
),
|
|
559
|
-
children: /* @__PURE__ */
|
|
560
|
-
|
|
544
|
+
children: /* @__PURE__ */ i(
|
|
545
|
+
pe,
|
|
561
546
|
{
|
|
562
547
|
"data-testid": "list-icon",
|
|
563
|
-
className:
|
|
548
|
+
className: n(o ? "fill-dark-30/25" : "fill-dark-30/[.80]")
|
|
564
549
|
}
|
|
565
550
|
)
|
|
566
551
|
}
|
|
567
552
|
),
|
|
568
|
-
/* @__PURE__ */
|
|
553
|
+
/* @__PURE__ */ i(
|
|
569
554
|
"div",
|
|
570
555
|
{
|
|
571
|
-
className:
|
|
572
|
-
|
|
556
|
+
className: n(
|
|
557
|
+
C.iconWrapper.base,
|
|
573
558
|
"right-0",
|
|
574
|
-
|
|
559
|
+
o && C.iconWrapper.checked
|
|
575
560
|
),
|
|
576
|
-
children: /* @__PURE__ */
|
|
577
|
-
|
|
561
|
+
children: /* @__PURE__ */ i(
|
|
562
|
+
fe,
|
|
578
563
|
{
|
|
579
564
|
"data-testid": "grid-icon",
|
|
580
|
-
className:
|
|
565
|
+
className: n(o ? "fill-dark-30/[.80]" : "fill-dark-30/25")
|
|
581
566
|
}
|
|
582
567
|
)
|
|
583
568
|
}
|
|
584
569
|
),
|
|
585
|
-
/* @__PURE__ */
|
|
586
|
-
/* @__PURE__ */
|
|
570
|
+
/* @__PURE__ */ i("div", { className: n(C.borderLine) }),
|
|
571
|
+
/* @__PURE__ */ i(Ae, { tabIndex: 1, className: n(C.thumb, e == null ? void 0 : e.thumb) })
|
|
587
572
|
] });
|
|
588
|
-
}),
|
|
573
|
+
}), C = {
|
|
589
574
|
base: "group relative inline-flex w-20 h-[38px] shrink-0 cursor-pointer items-center bg-gray-50 rounded-[10px] transition-colors duration-200 transition-colors",
|
|
590
575
|
thumb: "pointer-events-none block z-50 size-10 bg-transparent border border-secondary-10/[.15] transition-transform rounded-[10px] ring-0 data-[state=checked]:translate-x-full data-[state=unchecked]:translate-x-0",
|
|
591
576
|
iconWrapper: {
|
|
@@ -593,7 +578,7 @@ const z = {
|
|
|
593
578
|
checked: "bg-sidebar-10 rounded-[10px] overflow-hidden"
|
|
594
579
|
},
|
|
595
580
|
borderLine: "pointer-events-none absolute z-0 left-0 top-0 w-full h-full group-hover:border group-hover:border-primary-20/[.30] rounded-[10px] transition-colors duration-200"
|
|
596
|
-
},
|
|
581
|
+
}, O = {
|
|
597
582
|
sizes: {
|
|
598
583
|
small: {
|
|
599
584
|
base: "flex items-center justify-center min-w-32 bg-sidebar-10 text-xs font-medium leading-none border-[1px] rounded-md py-[7px] px-5",
|
|
@@ -623,111 +608,111 @@ const z = {
|
|
|
623
608
|
active: "fill-white",
|
|
624
609
|
disabled: "fill-dark-30/25"
|
|
625
610
|
}
|
|
626
|
-
},
|
|
611
|
+
}, ir = F(
|
|
627
612
|
({
|
|
628
613
|
variant: e = "small",
|
|
629
614
|
active: r,
|
|
630
|
-
icon:
|
|
631
|
-
disabled:
|
|
632
|
-
children:
|
|
633
|
-
className:
|
|
634
|
-
iconDimensions:
|
|
635
|
-
...
|
|
636
|
-
},
|
|
637
|
-
const u =
|
|
638
|
-
return /* @__PURE__ */
|
|
615
|
+
icon: a,
|
|
616
|
+
disabled: o,
|
|
617
|
+
children: d,
|
|
618
|
+
className: s,
|
|
619
|
+
iconDimensions: l,
|
|
620
|
+
...t
|
|
621
|
+
}, b) => {
|
|
622
|
+
const u = O.sizes[e];
|
|
623
|
+
return /* @__PURE__ */ c(
|
|
639
624
|
"button",
|
|
640
625
|
{
|
|
641
626
|
role: "tab",
|
|
642
627
|
"aria-selected": r,
|
|
643
|
-
ref:
|
|
644
|
-
className:
|
|
628
|
+
ref: b,
|
|
629
|
+
className: n(
|
|
645
630
|
u.base,
|
|
646
631
|
u.default,
|
|
647
|
-
!
|
|
648
|
-
r && !
|
|
649
|
-
r && !
|
|
650
|
-
|
|
651
|
-
|
|
632
|
+
!o && !r && u.hover,
|
|
633
|
+
r && !o && u.active,
|
|
634
|
+
r && !o && O.focus,
|
|
635
|
+
o && u.disabled,
|
|
636
|
+
s
|
|
652
637
|
),
|
|
653
|
-
...
|
|
638
|
+
...t,
|
|
654
639
|
children: [
|
|
655
|
-
!!
|
|
656
|
-
|
|
640
|
+
!!a && /* @__PURE__ */ i(
|
|
641
|
+
a,
|
|
657
642
|
{
|
|
658
643
|
"aria-label": "icon",
|
|
659
644
|
"aria-hidden": !0,
|
|
660
|
-
className:
|
|
661
|
-
|
|
662
|
-
r &&
|
|
663
|
-
|
|
645
|
+
className: n(
|
|
646
|
+
O.icon.default,
|
|
647
|
+
r && O.icon.active,
|
|
648
|
+
o && O.icon.disabled
|
|
664
649
|
),
|
|
665
|
-
...
|
|
650
|
+
...l
|
|
666
651
|
}
|
|
667
652
|
),
|
|
668
|
-
|
|
653
|
+
d
|
|
669
654
|
]
|
|
670
655
|
}
|
|
671
656
|
);
|
|
672
657
|
}
|
|
673
|
-
),
|
|
658
|
+
), w = ({
|
|
674
659
|
children: e,
|
|
675
660
|
className: r = "",
|
|
676
|
-
variant:
|
|
677
|
-
...
|
|
678
|
-
}) => /* @__PURE__ */
|
|
661
|
+
variant: a = "p",
|
|
662
|
+
...o
|
|
663
|
+
}) => /* @__PURE__ */ i(a, { ...o, className: n(r), children: e }), ar = W.forwardRef(
|
|
679
664
|
({
|
|
680
665
|
className: e = "",
|
|
681
666
|
disabled: r,
|
|
682
|
-
onChange:
|
|
683
|
-
placeholder:
|
|
684
|
-
autoFocus:
|
|
685
|
-
status:
|
|
686
|
-
maxLength:
|
|
687
|
-
...
|
|
688
|
-
},
|
|
689
|
-
var
|
|
690
|
-
const u =
|
|
691
|
-
return /* @__PURE__ */
|
|
692
|
-
/* @__PURE__ */
|
|
667
|
+
onChange: a,
|
|
668
|
+
placeholder: o = "Введите текст",
|
|
669
|
+
autoFocus: d = !1,
|
|
670
|
+
status: s,
|
|
671
|
+
maxLength: l,
|
|
672
|
+
...t
|
|
673
|
+
}, b) => {
|
|
674
|
+
var x, v;
|
|
675
|
+
const u = A.base, p = A.state, f = A.disabled, g = A.styles, h = A.maxLength;
|
|
676
|
+
return /* @__PURE__ */ c("div", { className: A.root, children: [
|
|
677
|
+
/* @__PURE__ */ i(
|
|
693
678
|
"textarea",
|
|
694
679
|
{
|
|
695
|
-
...
|
|
680
|
+
...t,
|
|
696
681
|
role: "textbox",
|
|
697
|
-
ref:
|
|
698
|
-
maxLength:
|
|
682
|
+
ref: b,
|
|
683
|
+
maxLength: l,
|
|
699
684
|
disabled: r,
|
|
700
|
-
autoFocus:
|
|
701
|
-
placeholder:
|
|
702
|
-
onChange:
|
|
703
|
-
className:
|
|
685
|
+
autoFocus: d,
|
|
686
|
+
placeholder: o,
|
|
687
|
+
onChange: a,
|
|
688
|
+
className: n(
|
|
704
689
|
u,
|
|
705
|
-
|
|
706
|
-
!r &&
|
|
707
|
-
|
|
708
|
-
r &&
|
|
690
|
+
p.focus,
|
|
691
|
+
!r && p.hover,
|
|
692
|
+
s && (g == null ? void 0 : g[s]),
|
|
693
|
+
r && f,
|
|
709
694
|
e
|
|
710
695
|
)
|
|
711
696
|
}
|
|
712
697
|
),
|
|
713
|
-
/* @__PURE__ */
|
|
714
|
-
|
|
698
|
+
/* @__PURE__ */ i("div", { className: A.messageContainer, children: l && /* @__PURE__ */ c(
|
|
699
|
+
w,
|
|
715
700
|
{
|
|
716
701
|
variant: "span",
|
|
717
|
-
className:
|
|
718
|
-
|
|
719
|
-
String(
|
|
702
|
+
className: n(
|
|
703
|
+
h,
|
|
704
|
+
String(t.value).length === l ? "bg-danger-10 text-sidebar-10" : "bg-transparent"
|
|
720
705
|
),
|
|
721
706
|
children: [
|
|
722
|
-
(
|
|
707
|
+
(v = (x = t.value || "") == null ? void 0 : x.toString()) == null ? void 0 : v.length,
|
|
723
708
|
"/",
|
|
724
|
-
|
|
709
|
+
l
|
|
725
710
|
]
|
|
726
711
|
}
|
|
727
712
|
) })
|
|
728
713
|
] });
|
|
729
714
|
}
|
|
730
|
-
),
|
|
715
|
+
), A = {
|
|
731
716
|
root: "flex flex-col gap-1 w-full",
|
|
732
717
|
base: "w-full min-h-[60px] bg-gray-50 text-sm text-dark-10 font-sans font-medium leading-none px-3.5 py-3 border border-gray-50 rounded-[10px] placeholder:text-sm placeholder:text-dark-40/50 transition-colors duration-200",
|
|
733
718
|
disabled: "text-dark-40/25 bg-dark-30/[.08] cursor-not-allowed",
|
|
@@ -747,39 +732,39 @@ const z = {
|
|
|
747
732
|
},
|
|
748
733
|
messageContainer: "flex items-center leading-none",
|
|
749
734
|
maxLength: "ml-auto p-1 text-dark-40/50 text-sm font-regular leading-none rounded"
|
|
750
|
-
}, { Root:
|
|
751
|
-
({ label: e = "", labelPosition: r = "right", disabled:
|
|
735
|
+
}, { Root: Re, Thumb: Be } = Y, nr = W.forwardRef(
|
|
736
|
+
({ label: e = "", labelPosition: r = "right", disabled: a, classNames: o, ...d }, s) => /* @__PURE__ */ c(
|
|
752
737
|
"div",
|
|
753
738
|
{
|
|
754
|
-
className:
|
|
739
|
+
className: n(
|
|
755
740
|
"flex items-center w-fit",
|
|
756
741
|
r === "right" && "flex-row-reverse"
|
|
757
742
|
),
|
|
758
743
|
children: [
|
|
759
|
-
!!e && /* @__PURE__ */
|
|
744
|
+
!!e && /* @__PURE__ */ i(
|
|
760
745
|
"span",
|
|
761
746
|
{
|
|
762
|
-
className:
|
|
763
|
-
|
|
747
|
+
className: n(
|
|
748
|
+
_.label,
|
|
764
749
|
r === "right" && "ml-2",
|
|
765
|
-
|
|
766
|
-
|
|
750
|
+
a && "cursor-not-allowed text-dark-30/[.20]",
|
|
751
|
+
o == null ? void 0 : o.label
|
|
767
752
|
),
|
|
768
753
|
children: e
|
|
769
754
|
}
|
|
770
755
|
),
|
|
771
|
-
/* @__PURE__ */
|
|
772
|
-
|
|
756
|
+
/* @__PURE__ */ i(
|
|
757
|
+
Re,
|
|
773
758
|
{
|
|
774
|
-
ref:
|
|
775
|
-
disabled:
|
|
776
|
-
className:
|
|
777
|
-
...
|
|
778
|
-
children: /* @__PURE__ */
|
|
779
|
-
|
|
759
|
+
ref: s,
|
|
760
|
+
disabled: a,
|
|
761
|
+
className: n(_.base, o == null ? void 0 : o.base),
|
|
762
|
+
...d,
|
|
763
|
+
children: /* @__PURE__ */ i(
|
|
764
|
+
Be,
|
|
780
765
|
{
|
|
781
766
|
tabIndex: 1,
|
|
782
|
-
className:
|
|
767
|
+
className: n(_.thumb, o == null ? void 0 : o.thumb)
|
|
783
768
|
}
|
|
784
769
|
)
|
|
785
770
|
}
|
|
@@ -787,34 +772,34 @@ const z = {
|
|
|
787
772
|
]
|
|
788
773
|
}
|
|
789
774
|
)
|
|
790
|
-
),
|
|
775
|
+
), _ = {
|
|
791
776
|
base: "inline-flex h-8 w-[52px] shrink-0 p-1 cursor-pointer items-center rounded-full border border-success-20 transition-colors focus:outline-none disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-success-20 data-[state=unchecked]:bg-secondary-10/[.08] data-[state=unchecked]:border-secondary-10/[.30] disabled:data-[state=unchecked]:bg-secondary-10/[.15] disabled:data-[state=unchecked]:border-transparent",
|
|
792
777
|
label: "mr-2 text-dark-30 text-sm",
|
|
793
778
|
thumb: "pointer-events-none block size-6 transition-transform rounded-full ring-0 data-[state=checked]:translate-x-3/4 data-[state=unchecked]:translate-x-0 data-[state=checked]:bg-white data-[state=unchecked]:bg-secondary-10/[.30]"
|
|
794
|
-
}, { Provider:
|
|
779
|
+
}, { Provider: ze, Root: De, Trigger: Fe, Portal: Le, Content: Oe, Arrow: We } = ge, dr = ({
|
|
795
780
|
children: e,
|
|
796
781
|
className: r,
|
|
797
|
-
defaultOpen:
|
|
798
|
-
side:
|
|
799
|
-
content:
|
|
800
|
-
delayDuration:
|
|
801
|
-
isDisabled:
|
|
802
|
-
}) => /* @__PURE__ */
|
|
803
|
-
/* @__PURE__ */
|
|
804
|
-
!
|
|
805
|
-
|
|
782
|
+
defaultOpen: a,
|
|
783
|
+
side: o,
|
|
784
|
+
content: d,
|
|
785
|
+
delayDuration: s = 0,
|
|
786
|
+
isDisabled: l = !1
|
|
787
|
+
}) => /* @__PURE__ */ i(ze, { children: /* @__PURE__ */ c(De, { defaultOpen: a, delayDuration: s, children: [
|
|
788
|
+
/* @__PURE__ */ i(Fe, { asChild: !0, children: /* @__PURE__ */ i("div", { children: e }) }),
|
|
789
|
+
!l && /* @__PURE__ */ i(Le, { children: /* @__PURE__ */ c(
|
|
790
|
+
Oe,
|
|
806
791
|
{
|
|
807
|
-
side:
|
|
792
|
+
side: o,
|
|
808
793
|
sideOffset: 5,
|
|
809
|
-
className:
|
|
794
|
+
className: n(Q.content, r),
|
|
810
795
|
children: [
|
|
811
|
-
|
|
812
|
-
/* @__PURE__ */
|
|
796
|
+
d,
|
|
797
|
+
/* @__PURE__ */ i(We, { className: Q.arrow })
|
|
813
798
|
]
|
|
814
799
|
}
|
|
815
800
|
) })
|
|
816
|
-
] }) }),
|
|
817
|
-
content:
|
|
801
|
+
] }) }), Q = {
|
|
802
|
+
content: n(
|
|
818
803
|
"font-mono select-none w-auto h-auto max-size-32 rounded-[5px] bg-dark-30 px-4 py-2 text-[10px] text-start leading-none text-sidebar-10 z-50",
|
|
819
804
|
"animate-tooltipFade data-[state=delayed-open]:data-[side=bottom]:animate-slideUpAndFade",
|
|
820
805
|
"data-[state=delayed-open]:data-[side=left]:animate-slideRightAndFade",
|
|
@@ -822,88 +807,88 @@ const z = {
|
|
|
822
807
|
"data-[state=delayed-open]:data-[side=top]:animate-slideDownAndFade"
|
|
823
808
|
),
|
|
824
809
|
arrow: "fill-dark-30"
|
|
825
|
-
},
|
|
810
|
+
}, lr = ({
|
|
826
811
|
classNames: e,
|
|
827
812
|
disabled: r,
|
|
828
|
-
status:
|
|
829
|
-
onChange:
|
|
830
|
-
options:
|
|
831
|
-
placeholder:
|
|
832
|
-
value:
|
|
833
|
-
isDotable:
|
|
834
|
-
isLoading:
|
|
813
|
+
status: a,
|
|
814
|
+
onChange: o,
|
|
815
|
+
options: d,
|
|
816
|
+
placeholder: s = "Choose",
|
|
817
|
+
value: l,
|
|
818
|
+
isDotable: t,
|
|
819
|
+
isLoading: b,
|
|
835
820
|
autoFocusValue: u
|
|
836
821
|
}) => {
|
|
837
|
-
const [
|
|
838
|
-
className:
|
|
839
|
-
text:
|
|
840
|
-
}) => /* @__PURE__ */
|
|
841
|
-
|
|
822
|
+
const [p, f] = te(!1), h = ve(d)(l), y = G(null), x = G(null), v = D.base, T = D.options, Z = D.status.styles, N = D.disabled.trigger, ee = D.disabled.triggerText, M = ({
|
|
823
|
+
className: m,
|
|
824
|
+
text: j = ""
|
|
825
|
+
}) => /* @__PURE__ */ i(
|
|
826
|
+
w,
|
|
842
827
|
{
|
|
843
|
-
className:
|
|
844
|
-
|
|
845
|
-
r &&
|
|
828
|
+
className: n(
|
|
829
|
+
v.placeholder,
|
|
830
|
+
r && ee,
|
|
846
831
|
"truncate min-w-0 flex-1",
|
|
847
|
-
|
|
832
|
+
m
|
|
848
833
|
),
|
|
849
|
-
children:
|
|
834
|
+
children: j
|
|
850
835
|
}
|
|
851
|
-
),
|
|
852
|
-
if (
|
|
853
|
-
const
|
|
854
|
-
if (
|
|
855
|
-
const
|
|
856
|
-
`[data-value="${
|
|
836
|
+
), re = (m) => {
|
|
837
|
+
if (m.preventDefault(), x.current) {
|
|
838
|
+
const j = l || u;
|
|
839
|
+
if (j) {
|
|
840
|
+
const q = x.current.querySelector(
|
|
841
|
+
`[data-value="${j}"]`
|
|
857
842
|
);
|
|
858
|
-
|
|
843
|
+
q && q.scrollIntoView({
|
|
859
844
|
block: "center",
|
|
860
845
|
behavior: "auto"
|
|
861
846
|
});
|
|
862
847
|
}
|
|
863
848
|
}
|
|
864
849
|
};
|
|
865
|
-
return /* @__PURE__ */
|
|
866
|
-
/* @__PURE__ */
|
|
867
|
-
|
|
850
|
+
return /* @__PURE__ */ i("div", { className: n("w-full", e == null ? void 0 : e.parent), children: /* @__PURE__ */ c(be, { open: p, onOpenChange: f, children: [
|
|
851
|
+
/* @__PURE__ */ c(
|
|
852
|
+
ce,
|
|
868
853
|
{
|
|
869
854
|
role: "listbox",
|
|
870
855
|
disabled: r,
|
|
871
|
-
className:
|
|
872
|
-
|
|
873
|
-
r &&
|
|
874
|
-
|
|
875
|
-
!
|
|
876
|
-
!
|
|
856
|
+
className: n(
|
|
857
|
+
v.trigger,
|
|
858
|
+
r && N,
|
|
859
|
+
p && v.focus,
|
|
860
|
+
!p && !r && v.hover,
|
|
861
|
+
!p && a && Z[a],
|
|
877
862
|
e == null ? void 0 : e.trigger
|
|
878
863
|
),
|
|
879
864
|
children: [
|
|
880
|
-
/* @__PURE__ */
|
|
881
|
-
|
|
865
|
+
/* @__PURE__ */ i("div", { className: v == null ? void 0 : v.textWrapper, children: l ? /* @__PURE__ */ i(
|
|
866
|
+
M,
|
|
882
867
|
{
|
|
883
|
-
text:
|
|
884
|
-
className:
|
|
885
|
-
|
|
886
|
-
r &&
|
|
868
|
+
text: h == null ? void 0 : h.label,
|
|
869
|
+
className: n(
|
|
870
|
+
v.selected,
|
|
871
|
+
r && D.disabled.selectedDisabled,
|
|
887
872
|
e == null ? void 0 : e.selected
|
|
888
873
|
)
|
|
889
874
|
}
|
|
890
|
-
) : /* @__PURE__ */
|
|
891
|
-
|
|
875
|
+
) : /* @__PURE__ */ i(
|
|
876
|
+
M,
|
|
892
877
|
{
|
|
893
|
-
text:
|
|
878
|
+
text: s,
|
|
894
879
|
className: e == null ? void 0 : e.placeholder
|
|
895
880
|
}
|
|
896
881
|
) }),
|
|
897
|
-
/* @__PURE__ */
|
|
898
|
-
|
|
882
|
+
/* @__PURE__ */ i(
|
|
883
|
+
he,
|
|
899
884
|
{
|
|
900
885
|
width: 20,
|
|
901
886
|
height: 20,
|
|
902
887
|
viewBox: "0 0 20 20",
|
|
903
|
-
className:
|
|
904
|
-
|
|
905
|
-
r &&
|
|
906
|
-
|
|
888
|
+
className: n(
|
|
889
|
+
v.icon,
|
|
890
|
+
r && v.iconDisabled,
|
|
891
|
+
p && "-rotate-180",
|
|
907
892
|
"flex-shrink-0"
|
|
908
893
|
)
|
|
909
894
|
}
|
|
@@ -911,44 +896,44 @@ const z = {
|
|
|
911
896
|
]
|
|
912
897
|
}
|
|
913
898
|
),
|
|
914
|
-
/* @__PURE__ */
|
|
915
|
-
|
|
899
|
+
/* @__PURE__ */ i("div", { ref: y, children: /* @__PURE__ */ c(
|
|
900
|
+
ue,
|
|
916
901
|
{
|
|
917
|
-
container:
|
|
918
|
-
className:
|
|
902
|
+
container: y.current,
|
|
903
|
+
className: n(T.content, e == null ? void 0 : e.content),
|
|
919
904
|
style: { minWidth: "var(--radix-popper-anchor-width)" },
|
|
920
|
-
onOpenAutoFocus:
|
|
921
|
-
ref:
|
|
905
|
+
onOpenAutoFocus: re,
|
|
906
|
+
ref: x,
|
|
922
907
|
children: [
|
|
923
|
-
|
|
924
|
-
!
|
|
908
|
+
b && /* @__PURE__ */ i(Ve, { width: 30, height: 30 }),
|
|
909
|
+
!b && (d != null && d.length) ? d.map((m) => /* @__PURE__ */ i(
|
|
925
910
|
"div",
|
|
926
911
|
{
|
|
927
|
-
"data-value":
|
|
928
|
-
className:
|
|
929
|
-
onClick: (
|
|
930
|
-
|
|
912
|
+
"data-value": m.value,
|
|
913
|
+
className: T.items,
|
|
914
|
+
onClick: (j) => {
|
|
915
|
+
j.preventDefault(), j.stopPropagation(), o(m.value), f(!1);
|
|
931
916
|
},
|
|
932
|
-
children: /* @__PURE__ */
|
|
933
|
-
|
|
917
|
+
children: /* @__PURE__ */ i(
|
|
918
|
+
w,
|
|
934
919
|
{
|
|
935
|
-
className:
|
|
936
|
-
|
|
937
|
-
!
|
|
938
|
-
|
|
939
|
-
|
|
920
|
+
className: n(
|
|
921
|
+
T.itemsText,
|
|
922
|
+
!t && l === m.value && T.active,
|
|
923
|
+
t && T.dot,
|
|
924
|
+
t && l === m.value && "before:bg-dark-10 !font-bold"
|
|
940
925
|
),
|
|
941
|
-
children:
|
|
926
|
+
children: m.label
|
|
942
927
|
}
|
|
943
928
|
)
|
|
944
929
|
},
|
|
945
|
-
|
|
946
|
-
)) : !
|
|
930
|
+
m.value
|
|
931
|
+
)) : !b && /* @__PURE__ */ i("div", { className: n(T.items, "cursor-default"), children: /* @__PURE__ */ i(w, { className: n(T.itemsText), children: "Нет данных" }) })
|
|
947
932
|
]
|
|
948
933
|
}
|
|
949
934
|
) })
|
|
950
935
|
] }) });
|
|
951
|
-
},
|
|
936
|
+
}, D = {
|
|
952
937
|
container: "w-full flex items-start flex-col gap-1.5",
|
|
953
938
|
base: {
|
|
954
939
|
icon: "ml-auto fill-sidebar-30/[.70] rounded hover:cursor-pointer transition-transform durantion-300",
|
|
@@ -981,95 +966,95 @@ const z = {
|
|
|
981
966
|
success: "border-success-20 ring-2 ring-success-10/[.20] hover:border-success-20"
|
|
982
967
|
}
|
|
983
968
|
}
|
|
984
|
-
},
|
|
969
|
+
}, Ie = W.forwardRef(
|
|
985
970
|
({
|
|
986
971
|
imageSrc: e,
|
|
987
972
|
alt: r,
|
|
988
|
-
hasBadge:
|
|
989
|
-
iconSize:
|
|
990
|
-
isActive:
|
|
991
|
-
isHasCamera:
|
|
992
|
-
onAvatarChange:
|
|
993
|
-
classNames:
|
|
994
|
-
},
|
|
995
|
-
const u =
|
|
996
|
-
return /* @__PURE__ */
|
|
997
|
-
|
|
973
|
+
hasBadge: a = !1,
|
|
974
|
+
iconSize: o,
|
|
975
|
+
isActive: d,
|
|
976
|
+
isHasCamera: s = !1,
|
|
977
|
+
onAvatarChange: l,
|
|
978
|
+
classNames: t
|
|
979
|
+
}, b) => {
|
|
980
|
+
const u = I.root, p = I.image, f = I.badge;
|
|
981
|
+
return /* @__PURE__ */ c(
|
|
982
|
+
ye,
|
|
998
983
|
{
|
|
999
984
|
role: "group",
|
|
1000
985
|
"data-testid": "avatar-root",
|
|
1001
986
|
onClick: () => {
|
|
1002
|
-
var
|
|
1003
|
-
return (
|
|
987
|
+
var g;
|
|
988
|
+
return (g = b == null ? void 0 : b.current) == null ? void 0 : g.click();
|
|
1004
989
|
},
|
|
1005
|
-
className:
|
|
990
|
+
className: n(
|
|
1006
991
|
u,
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
992
|
+
a && "bg-dark-30/[.10]",
|
|
993
|
+
d && I.active,
|
|
994
|
+
t == null ? void 0 : t.wrapper
|
|
1010
995
|
),
|
|
1011
996
|
children: [
|
|
1012
|
-
!!
|
|
997
|
+
!!b && /* @__PURE__ */ i(
|
|
1013
998
|
"input",
|
|
1014
999
|
{
|
|
1015
|
-
ref:
|
|
1000
|
+
ref: b,
|
|
1016
1001
|
type: "file",
|
|
1017
1002
|
accept: ".png,.jpg,.jpeg,image/png,image/jpeg",
|
|
1018
1003
|
className: "hidden",
|
|
1019
|
-
onChange:
|
|
1004
|
+
onChange: l
|
|
1020
1005
|
}
|
|
1021
1006
|
),
|
|
1022
|
-
e ? /* @__PURE__ */
|
|
1023
|
-
|
|
1007
|
+
e ? /* @__PURE__ */ i(
|
|
1008
|
+
me,
|
|
1024
1009
|
{
|
|
1025
1010
|
role: "img",
|
|
1026
1011
|
"data-testid": "avatar-img",
|
|
1027
1012
|
src: e,
|
|
1028
1013
|
alt: r ?? "empty-avatar",
|
|
1029
|
-
className:
|
|
1014
|
+
className: n(p, t == null ? void 0 : t.img)
|
|
1030
1015
|
}
|
|
1031
|
-
) : /* @__PURE__ */
|
|
1032
|
-
|
|
1016
|
+
) : /* @__PURE__ */ i(ke, { children: s ? /* @__PURE__ */ i(
|
|
1017
|
+
H,
|
|
1033
1018
|
{
|
|
1034
1019
|
width: 38,
|
|
1035
1020
|
height: 30,
|
|
1036
|
-
className:
|
|
1021
|
+
className: n("fill-dark-30/[.20]", t == null ? void 0 : t.badgeIcon),
|
|
1037
1022
|
viewBox: "0 0 38 30"
|
|
1038
1023
|
}
|
|
1039
|
-
) : /* @__PURE__ */
|
|
1040
|
-
|
|
1024
|
+
) : /* @__PURE__ */ i(
|
|
1025
|
+
xe,
|
|
1041
1026
|
{
|
|
1042
1027
|
"data-testid": "icon-avatar",
|
|
1043
1028
|
"aria-label": "icon-avatar",
|
|
1044
|
-
height: (
|
|
1045
|
-
width: (
|
|
1046
|
-
className:
|
|
1029
|
+
height: (o == null ? void 0 : o.height) ?? 17,
|
|
1030
|
+
width: (o == null ? void 0 : o.width) ?? 17,
|
|
1031
|
+
className: n(
|
|
1047
1032
|
"fill-sidebar-10",
|
|
1048
|
-
|
|
1049
|
-
|
|
1033
|
+
a && "fill-dark-30/[.15]",
|
|
1034
|
+
t == null ? void 0 : t.fallbackIcon
|
|
1050
1035
|
)
|
|
1051
1036
|
}
|
|
1052
1037
|
) }),
|
|
1053
|
-
|
|
1038
|
+
a && /* @__PURE__ */ i(
|
|
1054
1039
|
"div",
|
|
1055
1040
|
{
|
|
1056
1041
|
"data-testid": "avatar-badge",
|
|
1057
|
-
className:
|
|
1058
|
-
children:
|
|
1059
|
-
|
|
1042
|
+
className: n(f.wrapper, t == null ? void 0 : t.badge),
|
|
1043
|
+
children: d ? /* @__PURE__ */ i(
|
|
1044
|
+
X,
|
|
1060
1045
|
{
|
|
1061
1046
|
width: 14,
|
|
1062
1047
|
height: 14,
|
|
1063
1048
|
viewBox: "0 0 20 20",
|
|
1064
1049
|
className: "fill-sidebar-10"
|
|
1065
1050
|
}
|
|
1066
|
-
) : /* @__PURE__ */
|
|
1067
|
-
|
|
1051
|
+
) : /* @__PURE__ */ i(
|
|
1052
|
+
H,
|
|
1068
1053
|
{
|
|
1069
1054
|
width: 16,
|
|
1070
1055
|
height: 13,
|
|
1071
1056
|
viewBox: "0 0 38 30",
|
|
1072
|
-
className:
|
|
1057
|
+
className: n("fill-sidebar-10", t == null ? void 0 : t.badgeIcon)
|
|
1073
1058
|
}
|
|
1074
1059
|
)
|
|
1075
1060
|
}
|
|
@@ -1079,1316 +1064,146 @@ const z = {
|
|
|
1079
1064
|
);
|
|
1080
1065
|
}
|
|
1081
1066
|
);
|
|
1082
|
-
|
|
1083
|
-
const
|
|
1067
|
+
Ie.displayName = "Avatar";
|
|
1068
|
+
const I = {
|
|
1084
1069
|
root: "size-9 relative flex items-center justify-center bg-dark-30/[.10] rounded-full",
|
|
1085
1070
|
image: "size-full object-center object-cover rounded-full",
|
|
1086
1071
|
badge: {
|
|
1087
1072
|
wrapper: "absolute bottom-2 right-2 transform translate-x-1/4 translate-y-1/4 flex items-center justify-center bg-primary-10 px-2.5 py-3 border-2 border-sidebar-10 rounded-full"
|
|
1088
1073
|
},
|
|
1089
1074
|
active: "ring ring-2 ring-offset-1 ring-primary-10"
|
|
1090
|
-
},
|
|
1075
|
+
}, sr = ({
|
|
1091
1076
|
value: e,
|
|
1092
1077
|
onValueChange: r,
|
|
1093
|
-
classNames:
|
|
1094
|
-
count:
|
|
1095
|
-
...
|
|
1096
|
-
}) => /* @__PURE__ */
|
|
1097
|
-
|
|
1078
|
+
classNames: a = {},
|
|
1079
|
+
count: o = 3,
|
|
1080
|
+
...d
|
|
1081
|
+
}) => /* @__PURE__ */ i(V.Root, { value: e, onValueChange: r, children: /* @__PURE__ */ i(
|
|
1082
|
+
V.List,
|
|
1098
1083
|
{
|
|
1099
|
-
className:
|
|
1100
|
-
...
|
|
1101
|
-
children: Array.from({ length:
|
|
1102
|
-
|
|
1084
|
+
className: n($.container, a.container),
|
|
1085
|
+
...d,
|
|
1086
|
+
children: Array.from({ length: o }).map((s, l) => /* @__PURE__ */ i(
|
|
1087
|
+
V.Trigger,
|
|
1103
1088
|
{
|
|
1104
|
-
value: String(
|
|
1105
|
-
className:
|
|
1089
|
+
value: String(l),
|
|
1090
|
+
className: n(
|
|
1106
1091
|
$.dot,
|
|
1107
|
-
|
|
1108
|
-
|
|
1092
|
+
l <= Number(e) && $.dotActive,
|
|
1093
|
+
a.trigger
|
|
1109
1094
|
)
|
|
1110
1095
|
},
|
|
1111
|
-
|
|
1096
|
+
l
|
|
1112
1097
|
))
|
|
1113
1098
|
}
|
|
1114
1099
|
) }), $ = {
|
|
1115
1100
|
container: "flex items-center gap-1",
|
|
1116
1101
|
dot: "size-2 rounded-full bg-dark-30/[.20] transition-colors focus:outline-none focus:ring-offset-0 focus:ring-primary-10",
|
|
1117
1102
|
dotActive: "bg-primary-10"
|
|
1118
|
-
},
|
|
1103
|
+
}, br = ({ className: e, children: r, ...a }) => /* @__PURE__ */ i("div", { ...a, "data-slot": "skeleton", className: n(Pe.base, e), children: r }), Pe = {
|
|
1119
1104
|
base: "bg-gray-200 animate-pulse rounded-md"
|
|
1120
|
-
},
|
|
1105
|
+
}, Ve = ({
|
|
1121
1106
|
classNames: e,
|
|
1122
1107
|
width: r = 73,
|
|
1123
|
-
height:
|
|
1124
|
-
isBlur:
|
|
1125
|
-
}) => /* @__PURE__ */
|
|
1108
|
+
height: a = 73,
|
|
1109
|
+
isBlur: o = !1
|
|
1110
|
+
}) => /* @__PURE__ */ i(
|
|
1126
1111
|
"div",
|
|
1127
1112
|
{
|
|
1128
1113
|
"data-testid": "spinner",
|
|
1129
|
-
className:
|
|
1130
|
-
children: /* @__PURE__ */
|
|
1131
|
-
|
|
1114
|
+
className: n(o ? E.blur : E.wrapper, e == null ? void 0 : e.wrapper),
|
|
1115
|
+
children: /* @__PURE__ */ i(
|
|
1116
|
+
de,
|
|
1132
1117
|
{
|
|
1133
1118
|
"data-testid": "spinner-icon",
|
|
1134
|
-
height:
|
|
1119
|
+
height: a,
|
|
1135
1120
|
width: r,
|
|
1136
|
-
className:
|
|
1121
|
+
className: n(E.icon, e == null ? void 0 : e.icon)
|
|
1137
1122
|
}
|
|
1138
1123
|
)
|
|
1139
1124
|
}
|
|
1140
|
-
),
|
|
1125
|
+
), E = {
|
|
1141
1126
|
wrapper: "flex flex-col gap-1 absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 items-center justify-center",
|
|
1142
1127
|
blur: "absolute inset-0 z-51 flex items-center justify-center bg-background/60 backdrop-blur-sm rounded-[20px]",
|
|
1143
1128
|
icon: "fill-primary-10"
|
|
1144
|
-
},
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
|
|
1160
|
-
|
|
1161
|
-
// Чекбокс stroke
|
|
1162
|
-
30: "#D1D1D1",
|
|
1163
|
-
// Неактивный текст
|
|
1164
|
-
40: "#F2F2F2",
|
|
1165
|
-
// Цвет полей
|
|
1166
|
-
50: "#F3F6F8"
|
|
1167
|
-
// Цвет заполнения
|
|
1168
|
-
},
|
|
1169
|
-
primary: {
|
|
1170
|
-
10: "#F9B800",
|
|
1171
|
-
// Основной / Акцент
|
|
1172
|
-
20: "#FF9900",
|
|
1173
|
-
// Hover
|
|
1174
|
-
30: "#FB7100",
|
|
1175
|
-
// Pressed
|
|
1176
|
-
40: "#FEEAB3",
|
|
1177
|
-
// Stroke
|
|
1178
|
-
50: "#FFF8E6"
|
|
1179
|
-
// Выделение
|
|
1180
|
-
},
|
|
1181
|
-
secondary: {
|
|
1182
|
-
10: "#606061",
|
|
1183
|
-
// default text
|
|
1184
|
-
20: "#D9D9DF",
|
|
1185
|
-
// disabled bg
|
|
1186
|
-
30: "#FEEAB3",
|
|
1187
|
-
// focus stroke
|
|
1188
|
-
40: "#FFDFB0",
|
|
1189
|
-
// hover stroke
|
|
1190
|
-
50: "#FED3B0"
|
|
1191
|
-
// pressed stroke
|
|
1192
|
-
},
|
|
1193
|
-
success: {
|
|
1194
|
-
10: "#2EBF42",
|
|
1195
|
-
// Успешно
|
|
1196
|
-
20: "#76BF97",
|
|
1197
|
-
// bg success
|
|
1198
|
-
30: "#CCFBE0",
|
|
1199
|
-
// Active status
|
|
1200
|
-
40: "#16A52A",
|
|
1201
|
-
// Hover
|
|
1202
|
-
50: "#F0F9E3"
|
|
1203
|
-
// Pressed bg
|
|
1204
|
-
},
|
|
1205
|
-
danger: {
|
|
1206
|
-
10: "#F42929",
|
|
1207
|
-
// Ошибка
|
|
1208
|
-
20: "#EB2428",
|
|
1209
|
-
// bg ошибка
|
|
1210
|
-
30: "#D61B1E",
|
|
1211
|
-
// hover
|
|
1212
|
-
40: "#E69494",
|
|
1213
|
-
// pressed
|
|
1214
|
-
50: "#FFCCCE"
|
|
1215
|
-
// Status
|
|
1216
|
-
},
|
|
1217
|
-
info: {
|
|
1218
|
-
10: "#1B9BE4",
|
|
1219
|
-
// Инфо
|
|
1220
|
-
20: "#DFF8FF",
|
|
1221
|
-
// bg info
|
|
1222
|
-
30: "#D9EDFF",
|
|
1223
|
-
// Категории
|
|
1224
|
-
40: "#B8DBF6",
|
|
1225
|
-
// hover
|
|
1226
|
-
50: "#99C5EC"
|
|
1227
|
-
// pressed
|
|
1228
|
-
},
|
|
1229
|
-
status: {
|
|
1230
|
-
10: "#CCF8E0",
|
|
1231
|
-
// success
|
|
1232
|
-
20: "#E8EAEE",
|
|
1233
|
-
// inactive
|
|
1234
|
-
30: "#FFF2CE",
|
|
1235
|
-
// process
|
|
1236
|
-
40: "#FFDDCC",
|
|
1237
|
-
// pending
|
|
1238
|
-
50: "#FFC2C2",
|
|
1239
|
-
// blocked
|
|
1240
|
-
default: "#EFE5FF"
|
|
1241
|
-
// done
|
|
1242
|
-
},
|
|
1243
|
-
sidebar: {
|
|
1244
|
-
10: "#FFFFFF",
|
|
1245
|
-
// default text
|
|
1246
|
-
20: "#F9B800",
|
|
1247
|
-
// active text
|
|
1248
|
-
30: "#585858",
|
|
1249
|
-
// disabled text
|
|
1250
|
-
40: "#434343",
|
|
1251
|
-
// hover bg
|
|
1252
|
-
50: "#323234"
|
|
1253
|
-
// bg
|
|
1254
|
-
},
|
|
1255
|
-
tertiary: {
|
|
1256
|
-
10: "#B6B7BA",
|
|
1257
|
-
// statusCategory.main
|
|
1258
|
-
20: "#242424",
|
|
1259
|
-
// hover
|
|
1260
|
-
30: "#95C5EC",
|
|
1261
|
-
// pressed
|
|
1262
|
-
40: "#E8F4FF",
|
|
1263
|
-
50: "#F6FAFF"
|
|
1264
|
-
}
|
|
1265
|
-
}, re = {
|
|
1266
|
-
textStyles: {
|
|
1267
|
-
body: {
|
|
1268
|
-
"body-8": {
|
|
1269
|
-
fontSize: "8px",
|
|
1270
|
-
fontWeight: 500,
|
|
1271
|
-
lineHeight: "1"
|
|
1272
|
-
},
|
|
1273
|
-
"body-10": {
|
|
1274
|
-
fontSize: "10px",
|
|
1275
|
-
fontWeight: 500,
|
|
1276
|
-
lineHeight: "1.5"
|
|
1277
|
-
},
|
|
1278
|
-
"body-12": {
|
|
1279
|
-
fontSize: "12px",
|
|
1280
|
-
fontWeight: 500,
|
|
1281
|
-
lineHeight: "1.5"
|
|
1282
|
-
},
|
|
1283
|
-
"body-14": {
|
|
1284
|
-
fontSize: "14px",
|
|
1285
|
-
fontWeight: 500,
|
|
1286
|
-
lineHeight: "2"
|
|
1287
|
-
},
|
|
1288
|
-
"body-16": {
|
|
1289
|
-
fontSize: "16px",
|
|
1290
|
-
fontWeight: 500,
|
|
1291
|
-
lineHeight: "2"
|
|
1292
|
-
},
|
|
1293
|
-
"body-18": {
|
|
1294
|
-
fontSize: "18px",
|
|
1295
|
-
fontWeight: 500,
|
|
1296
|
-
lineHeight: "2"
|
|
1297
|
-
}
|
|
1298
|
-
},
|
|
1299
|
-
headings: {
|
|
1300
|
-
h1: {
|
|
1301
|
-
fontSize: "40px",
|
|
1302
|
-
fontWeight: 500,
|
|
1303
|
-
lineHeight: "normal"
|
|
1304
|
-
},
|
|
1305
|
-
h2: {
|
|
1306
|
-
fontSize: "32px",
|
|
1307
|
-
fontWeight: 500,
|
|
1308
|
-
lineHeight: "normal"
|
|
1309
|
-
},
|
|
1310
|
-
h3: {
|
|
1311
|
-
fontSize: "28px",
|
|
1312
|
-
fontWeight: 500,
|
|
1313
|
-
lineHeight: "normal"
|
|
1314
|
-
},
|
|
1315
|
-
h4: {
|
|
1316
|
-
fontSize: "24px",
|
|
1317
|
-
fontWeight: 500,
|
|
1318
|
-
lineHeight: "normal"
|
|
1319
|
-
},
|
|
1320
|
-
h5: {
|
|
1321
|
-
fontSize: "20px",
|
|
1322
|
-
fontWeight: 500,
|
|
1323
|
-
lineHeight: "normal"
|
|
1324
|
-
},
|
|
1325
|
-
h6: {
|
|
1326
|
-
fontSize: "16px",
|
|
1327
|
-
fontWeight: 500,
|
|
1328
|
-
lineHeight: "normal"
|
|
1329
|
-
}
|
|
1330
|
-
},
|
|
1331
|
-
link: {
|
|
1332
|
-
8: {
|
|
1333
|
-
fontSize: "8px",
|
|
1334
|
-
fontWeight: 500,
|
|
1335
|
-
lineHeight: "1"
|
|
1336
|
-
},
|
|
1337
|
-
10: {
|
|
1338
|
-
fontSize: "10px",
|
|
1339
|
-
fontWeight: 500,
|
|
1340
|
-
lineHeight: "1.5"
|
|
1341
|
-
},
|
|
1342
|
-
12: {
|
|
1343
|
-
fontSize: "12px",
|
|
1344
|
-
fontWeight: 500,
|
|
1345
|
-
lineHeight: "1.5"
|
|
1346
|
-
},
|
|
1347
|
-
14: {
|
|
1348
|
-
fontSize: "14px",
|
|
1349
|
-
fontWeight: 500,
|
|
1350
|
-
lineHeight: "2"
|
|
1351
|
-
},
|
|
1352
|
-
16: {
|
|
1353
|
-
fontSize: "16px",
|
|
1354
|
-
fontWeight: 500,
|
|
1355
|
-
lineHeight: "2"
|
|
1356
|
-
},
|
|
1357
|
-
18: {
|
|
1358
|
-
fontSize: "18px",
|
|
1359
|
-
fontWeight: 500,
|
|
1360
|
-
lineHeight: "2"
|
|
1361
|
-
}
|
|
1362
|
-
}
|
|
1363
|
-
}
|
|
1364
|
-
}, te = (e, { splitClassName: r } = { splitClassName: !0 }) => {
|
|
1365
|
-
const i = {};
|
|
1366
|
-
return Object.keys(e).forEach((t) => {
|
|
1367
|
-
const [n, l] = r ? t.split("-") : ["", t], d = `text-${r ? n : t}`;
|
|
1368
|
-
i[d] || (i[d] = []), i[d].push(l);
|
|
1369
|
-
}), i;
|
|
1370
|
-
}, hr = (e) => {
|
|
1371
|
-
const r = {};
|
|
1372
|
-
return Object.entries(e).forEach(([i, t]) => {
|
|
1373
|
-
const n = `text-${i}`;
|
|
1374
|
-
r[n] = Object.keys(t).filter(
|
|
1375
|
-
(l) => !isNaN(Number(l))
|
|
1376
|
-
);
|
|
1377
|
-
}), r;
|
|
1378
|
-
}, gr = _e({
|
|
1379
|
-
extend: {
|
|
1380
|
-
classGroups: {
|
|
1381
|
-
"font-size": [
|
|
1382
|
-
te(re.textStyles.body),
|
|
1383
|
-
te(re.textStyles.headings, {
|
|
1384
|
-
splitClassName: !1
|
|
1385
|
-
}),
|
|
1386
|
-
te(re.textStyles.link, {
|
|
1387
|
-
splitClassName: !1
|
|
1388
|
-
})
|
|
1389
|
-
],
|
|
1390
|
-
"text-color": [hr(pr)]
|
|
1391
|
-
}
|
|
1392
|
-
}
|
|
1393
|
-
}), b = (...e) => gr(Pe(e));
|
|
1394
|
-
Qe.use([
|
|
1395
|
-
Xe,
|
|
1396
|
-
Ve,
|
|
1397
|
-
Ge,
|
|
1398
|
-
Ne,
|
|
1399
|
-
Ue,
|
|
1400
|
-
Je,
|
|
1401
|
-
Ke
|
|
1402
|
-
]);
|
|
1403
|
-
const ue = (e) => /* @__PURE__ */ m.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 38, height: 30, fill: "none", ...e }, /* @__PURE__ */ m.createElement("path", { fill: "currentFill", d: "M32.3 3.75h-3.01l-1.9-1.87A7.2 7.2 0 0 0 22.8 0h-7.6c-1.56 0-3.49.79-4.59 1.88l-1.9 1.87H5.7A5.67 5.67 0 0 0 0 9.38v15C0 27.48 2.56 30 5.7 30h26.6c3.14 0 5.7-2.52 5.7-5.62v-15c0-3.1-2.56-5.63-5.7-5.63M19 22.5a6.7 6.7 0 0 1-4.7-1.92 6.5 6.5 0 0 1 0-9.29 6.7 6.7 0 0 1 9.4 0 6.5 6.5 0 0 1 0 9.29A6.7 6.7 0 0 1 19 22.5m11.4-8.81a2.5 2.5 0 0 1-2.28-1.5 2.4 2.4 0 0 1 1.33-3.2 2.5 2.5 0 0 1 2.7.53 2.4 2.4 0 0 1 0 3.45c-.47.46-1.1.72-1.75.72" })), fr = (e) => /* @__PURE__ */ m.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 16, height: 16, fill: "currentFill", ...e }, /* @__PURE__ */ m.createElement("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 1.5, d: "m5.67 7.5 3.1 3.5L15 4M2 7.5 5.11 11m6.22-7L8.97 6.69" })), mr = (e) => /* @__PURE__ */ m.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 24, height: 24, fill: "none", ...e }, /* @__PURE__ */ m.createElement("path", { fill: "currentFill", d: "m9.55 15.15 8.48-8.48a.96.96 0 0 1 1.4 0q.3.3.3.72 0 .4-.3.71l-9.18 9.2a.96.96 0 0 1-1.4 0L4.55 13a1 1 0 0 1-.29-.71q.01-.41.32-.71.3-.3.7-.3.42 0 .72.3z" })), ve = (e) => /* @__PURE__ */ m.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 20, height: 20, fill: "none", ...e }, /* @__PURE__ */ m.createElement("g", { mask: "url(#mask0_770_8096)" }, /* @__PURE__ */ m.createElement("path", { fill: "currentFill", d: "m7.96 12.63 7.06-7.07a.8.8 0 0 1 1.17 0q.24.25.25.6 0 .34-.25.59l-7.65 7.67a.8.8 0 0 1-1.16 0l-3.59-3.59a.8.8 0 0 1-.24-.59q.01-.34.26-.6a.8.8 0 0 1 .6-.24q.34 0 .59.25z" }))), vr = (e) => /* @__PURE__ */ m.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "currentFill", viewBox: "0 0 19 19", ...e }, /* @__PURE__ */ m.createElement("g", { clipPath: "url(#a)" }, /* @__PURE__ */ m.createElement("path", { d: "M4.95 5.54a4.55 4.55 0 1 1 9.1 0 4.55 4.55 0 0 1-9.1 0m4.39 5.75h.32l5.77 1.02h.03c1.07.25 2.21.92 2.43 2.24v.02l.1.7c.2 1.58-1.05 2.74-2.54 2.74H3.55c-1.49 0-2.75-1.16-2.54-2.76l.1-.68v-.03c.22-1.29 1.37-2 2.43-2.23h.02z" })), /* @__PURE__ */ m.createElement("defs", null, /* @__PURE__ */ m.createElement("clipPath", { id: "a" }, /* @__PURE__ */ m.createElement("path", { d: "M0 0h19v19H0z" })))), xr = (e) => /* @__PURE__ */ m.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 19, height: 19, fill: "currentFill", ...e }, /* @__PURE__ */ m.createElement("path", { fillOpacity: 0.8, d: "M1.6 8a.75.75 0 0 1-.75-.75v-6A.75.75 0 0 1 1.6.5h6a.75.75 0 0 1 .75.75v6A.75.75 0 0 1 7.6 8zm10.5 0a.75.75 0 0 1-.75-.75v-6A.75.75 0 0 1 12.1.5h6a.75.75 0 0 1 .75.75v6a.75.75 0 0 1-.75.75zM1.6 18.5a.75.75 0 0 1-.75-.75v-6A.75.75 0 0 1 1.6 11h6a.75.75 0 0 1 .75.75v6a.75.75 0 0 1-.75.75zm10.5 0a.75.75 0 0 1-.75-.75v-6a.75.75 0 0 1 .75-.75h6a.75.75 0 0 1 .75.75v6a.75.75 0 0 1-.75.75z" })), yr = (e) => /* @__PURE__ */ m.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 19, height: 13, fill: "currentFill", ...e }, /* @__PURE__ */ m.createElement("path", { fillOpacity: 0.8, d: "M1.45 12.45a1 1 0 0 1-.72-.28 1 1 0 0 1-.28-.72q0-.43.28-.7.3-.3.72-.3h16q.43 0 .7.3.3.27.3.7a1 1 0 0 1-1 1zm0-5a1 1 0 0 1-.72-.28 1 1 0 0 1-.28-.72q0-.42.28-.7.3-.3.72-.3h16q.43 0 .7.3.3.27.3.7a1 1 0 0 1-1 1zm0-5a1 1 0 0 1-.72-.28 1 1 0 0 1-.28-.72q0-.43.28-.7.3-.3.72-.3h16q.43 0 .7.3.3.28.3.7a1 1 0 0 1-1 1z" })), V = {
|
|
1404
|
-
base: "group inline-flex items-center justify-center transition-colors rounded-[10px] border outline-none",
|
|
1405
|
-
icon: {
|
|
1406
|
-
disabled: {
|
|
1407
|
-
primary: "fill-white",
|
|
1408
|
-
secondary: "fill-secondary-10/[.50]",
|
|
1409
|
-
text: "fill-secondary-10/[.60]"
|
|
1410
|
-
},
|
|
1411
|
-
parent: "justify-between gap-[9px] w-auto",
|
|
1412
|
-
variants: {
|
|
1413
|
-
primary: "fill-white",
|
|
1414
|
-
secondary: "fill-dark-30 group-hover:fill-primary-20 group-focus-visible:fill-sidebar-20 group-active:fill-primary-30",
|
|
1415
|
-
text: "fill-primary-10 group-hover:fill-primary-20 group-active:fill-primary-30"
|
|
1416
|
-
}
|
|
1417
|
-
},
|
|
1418
|
-
sizes: {
|
|
1419
|
-
medium: {
|
|
1420
|
-
fontSize: "text-sm font-medium font-mono",
|
|
1421
|
-
padding: "px-[20px] py-[9px]"
|
|
1422
|
-
}
|
|
1423
|
-
},
|
|
1424
|
-
variants: {
|
|
1425
|
-
primary: {
|
|
1426
|
-
active: "active:bg-primary-30",
|
|
1427
|
-
base: "bg-primary-10 text-white",
|
|
1428
|
-
disabled: "disabled:bg-secondary-10/[.25] disabled:border-gray-30 disabled:shadow-none",
|
|
1429
|
-
focus: "focus-visible:bg-primary-10 focus-visible:outline-[4px] focus-visible:outline-primary-10/[.20] focus-visible:outline-offset-0",
|
|
1430
|
-
hover: "hover:bg-primary-20 hover:border-primary-2 hover:shadow-[0px_5px_10.6px_0px_#F9B8004D]"
|
|
1431
|
-
},
|
|
1432
|
-
secondary: {
|
|
1433
|
-
active: "active:bg-transparent active:text-primary-30 active:border active:border-secondary-50",
|
|
1434
|
-
base: "bg-transparent text-dark-30 font-semibold outline-none border-dark-30/[.20]",
|
|
1435
|
-
disabled: "disabled:bg-secondary-10/[.08] disabled:text-dark-30/[.25] disabled:border-secondary-10/[.25]",
|
|
1436
|
-
focus: "focus-visible:text-sidebar-20 focus-visible:bg-transparent focus-visible:outline-[4px] focus-visible:outline-primary-10/[.20] focus-visible:border-primary-10 focus-visible:outline-offset-0",
|
|
1437
|
-
hover: "hover:bg-transparent hover:text-primary-20 hover:border-secondary-40"
|
|
1438
|
-
},
|
|
1439
|
-
text: {
|
|
1440
|
-
active: "active:bg-transparent active:text-primary-30 active:border-transparent",
|
|
1441
|
-
base: "group bg-transparent text-primary-10 outline-none border-transparent",
|
|
1442
|
-
disabled: "disabled:bg-transparent disabled:border-transparent disabled:text-dark-30/[.30]",
|
|
1443
|
-
focus: "focus-visible:transparent focus-visible:outline-[2px] focus-visible:outline-primary-10/[.20] focus-visible:outline-offset-0",
|
|
1444
|
-
hover: "hover:bg-transparent hover:text-primary-20 hover:border-transparent"
|
|
1445
|
-
}
|
|
1446
|
-
}
|
|
1447
|
-
};
|
|
1448
|
-
F(
|
|
1449
|
-
({
|
|
1450
|
-
children: e,
|
|
1451
|
-
classNames: r,
|
|
1452
|
-
disabled: i = !1,
|
|
1453
|
-
icon: t,
|
|
1454
|
-
iconDimensions: n = { height: 15, width: 15 },
|
|
1455
|
-
iconPosition: l = "right",
|
|
1456
|
-
size: d = "medium",
|
|
1457
|
-
variant: a = "primary",
|
|
1458
|
-
isShadow: s = !1,
|
|
1459
|
-
...u
|
|
1460
|
-
}, f) => {
|
|
1461
|
-
const g = V.icon, h = V.sizes[d], v = V.variants[a] || V.variants.primary, x = g.variants[a], y = g.disabled[a];
|
|
1462
|
-
return /* @__PURE__ */ p(
|
|
1463
|
-
"button",
|
|
1464
|
-
{
|
|
1465
|
-
role: "button",
|
|
1466
|
-
...u,
|
|
1467
|
-
type: u.type || "button",
|
|
1468
|
-
ref: f,
|
|
1469
|
-
disabled: i,
|
|
1470
|
-
className: b(
|
|
1471
|
-
V.base,
|
|
1472
|
-
h.padding,
|
|
1473
|
-
h.fontSize,
|
|
1474
|
-
v.base,
|
|
1475
|
-
v.focus,
|
|
1476
|
-
!i && v.hover,
|
|
1477
|
-
!i && v.active,
|
|
1478
|
-
i && v.disabled,
|
|
1479
|
-
!!t && g.parent,
|
|
1480
|
-
!!t && !e && "min-w-0",
|
|
1481
|
-
a === "primary" && s && "shadow-3xl",
|
|
1482
|
-
r == null ? void 0 : r.base
|
|
1483
|
-
),
|
|
1484
|
-
children: [
|
|
1485
|
-
!!t && l === "left" && /* @__PURE__ */ o(
|
|
1486
|
-
t,
|
|
1487
|
-
{
|
|
1488
|
-
"aria-label": "icon",
|
|
1489
|
-
"aria-hidden": !0,
|
|
1490
|
-
className: b(
|
|
1491
|
-
!i && x,
|
|
1492
|
-
i && y,
|
|
1493
|
-
r == null ? void 0 : r.icon
|
|
1494
|
-
),
|
|
1495
|
-
height: n.height,
|
|
1496
|
-
width: n.width,
|
|
1497
|
-
viewBox: n.viewBox
|
|
1498
|
-
}
|
|
1499
|
-
),
|
|
1500
|
-
e,
|
|
1501
|
-
!!t && l === "right" && /* @__PURE__ */ o(
|
|
1502
|
-
t,
|
|
1503
|
-
{
|
|
1504
|
-
"aria-label": "icon",
|
|
1505
|
-
"aria-hidden": !0,
|
|
1506
|
-
className: b(
|
|
1507
|
-
!i && x,
|
|
1508
|
-
i && y,
|
|
1509
|
-
r == null ? void 0 : r.icon
|
|
1510
|
-
),
|
|
1511
|
-
height: n.height,
|
|
1512
|
-
width: n.width,
|
|
1513
|
-
viewBox: n.viewBox
|
|
1514
|
-
}
|
|
1515
|
-
)
|
|
1516
|
-
]
|
|
1517
|
-
}
|
|
1518
|
-
);
|
|
1519
|
-
}
|
|
1520
|
-
);
|
|
1521
|
-
const wr = F(
|
|
1522
|
-
({
|
|
1523
|
-
classNames: e,
|
|
1524
|
-
disabled: r = !1,
|
|
1525
|
-
icon: i,
|
|
1526
|
-
variant: t = "default",
|
|
1527
|
-
shape: n,
|
|
1528
|
-
badge: l,
|
|
1529
|
-
iconSizes: d,
|
|
1530
|
-
text: a,
|
|
1531
|
-
...s
|
|
1532
|
-
}, u) => {
|
|
1533
|
-
var f;
|
|
1534
|
-
const g = O.icon, h = O.variants[t], v = g.variants[t], x = (f = O.shape) == null ? void 0 : f[n], y = g.disabled[t];
|
|
1535
|
-
return /* @__PURE__ */ p(
|
|
1536
|
-
"button",
|
|
1537
|
-
{
|
|
1538
|
-
...s,
|
|
1539
|
-
role: "button",
|
|
1540
|
-
type: s.type || "button",
|
|
1541
|
-
ref: u,
|
|
1542
|
-
disabled: r,
|
|
1543
|
-
className: b(
|
|
1544
|
-
O.base,
|
|
1545
|
-
h.base,
|
|
1546
|
-
h.focus,
|
|
1547
|
-
x,
|
|
1548
|
-
l && O.badgeStyles.base,
|
|
1549
|
-
!r && h.hover,
|
|
1550
|
-
!r && h.active,
|
|
1551
|
-
r && h.disabled,
|
|
1552
|
-
e == null ? void 0 : e.button
|
|
1553
|
-
),
|
|
1554
|
-
children: [
|
|
1555
|
-
l && /* @__PURE__ */ o("span", { className: O.badgeStyles.badgeStyles, children: l }),
|
|
1556
|
-
!!i && /* @__PURE__ */ o(
|
|
1557
|
-
i,
|
|
1558
|
-
{
|
|
1559
|
-
"aria-label": "icon",
|
|
1560
|
-
"aria-hidden": !0,
|
|
1561
|
-
className: b(
|
|
1562
|
-
g.base,
|
|
1563
|
-
!r && v,
|
|
1564
|
-
r && y,
|
|
1565
|
-
e == null ? void 0 : e.icon
|
|
1566
|
-
),
|
|
1567
|
-
height: d == null ? void 0 : d.height,
|
|
1568
|
-
width: d == null ? void 0 : d.width,
|
|
1569
|
-
viewBox: d == null ? void 0 : d.viewBox
|
|
1570
|
-
}
|
|
1571
|
-
),
|
|
1572
|
-
!!a && /* @__PURE__ */ o(U, { className: e == null ? void 0 : e.text, children: a })
|
|
1573
|
-
]
|
|
1574
|
-
}
|
|
1575
|
-
);
|
|
1576
|
-
}
|
|
1577
|
-
), O = {
|
|
1578
|
-
base: "group inline-flex items-center justify-center rounded-[10px] outline-none border",
|
|
1579
|
-
icon: {
|
|
1580
|
-
base: "text-inherit",
|
|
1581
|
-
disabled: {
|
|
1582
|
-
default: "fill-secondary-10/50",
|
|
1583
|
-
primary: "fill-secondary-10/50",
|
|
1584
|
-
text: "text-dark-30/50"
|
|
1585
|
-
},
|
|
1586
|
-
variants: {
|
|
1587
|
-
default: "fill-sidebar-30 group-hover:fill-primary-20 group-active:fill-primary-30 group-focus-visible:fill-primary-10",
|
|
1588
|
-
primary: "fill-sidebar-30 group-hover:fill-primary-20 group-focus-visible:fill-primary-10 group-active:fill-primary-30",
|
|
1589
|
-
text: "text-sidebar-30 group-hover:text-primary-20 group-focus-visible:text-sidebar-20 group-active:text-primary-30"
|
|
1590
|
-
}
|
|
1591
|
-
},
|
|
1592
|
-
badgeStyles: {
|
|
1593
|
-
base: "relative overflow-visible",
|
|
1594
|
-
badgeStyles: "absolute text-[10px] font-normal top-[-5px] right-[-6px] z-10 bg-primary-10 text-primary-10 text-white w-5 h-4 rounded-full flex items-center justify-center"
|
|
1595
|
-
},
|
|
1596
|
-
shape: {
|
|
1597
|
-
circle: "rounded-full px-1.5 py-1.5",
|
|
1598
|
-
square: "px-1.5 py-1.5"
|
|
1599
|
-
},
|
|
1600
|
-
variants: {
|
|
1601
|
-
default: {
|
|
1602
|
-
active: "active:border-[1.5px] active:bg-transparent active:border-primary-30 active:shadow-primary-40",
|
|
1603
|
-
base: "px-1.5 py-1.5 bg-transparent border-gray-30 shadow",
|
|
1604
|
-
disabled: "disabled:bg-gray-40 disabled:border-secondary-10/[.25] shadow-none",
|
|
1605
|
-
focus: "focus:border-[1.5px] focus-visible:bg-transparent focus-visible:outline-[4px] focus-visible:outline-primary-10/[.20] focus-visible:outline-offset-0 focus-visible:border-primary-10",
|
|
1606
|
-
hover: "hover:bg-transparent hover:border-primary-20 hover:shadow-primary-40"
|
|
1607
|
-
},
|
|
1608
|
-
primary: {
|
|
1609
|
-
active: "active:bg-gray-40 active:border-transparent",
|
|
1610
|
-
base: "px-1.5 py-1.5 bg-gray-40 outline-none rounded-full border-transparent",
|
|
1611
|
-
disabled: "disabled:bg-gray-40",
|
|
1612
|
-
focus: "focus:border-transparent focus-visible:bg-gray-40 focus-visible:outline-[4px] focus-visible:outline-primary-10/[.20] focus-visible:outline-offset-0",
|
|
1613
|
-
hover: "hover:bg-gray-40 hover:border-transparent"
|
|
1614
|
-
},
|
|
1615
|
-
text: {
|
|
1616
|
-
base: "border-none hover:border-none hover:bg-transparent bg-transparent",
|
|
1617
|
-
hover: "",
|
|
1618
|
-
focus: "",
|
|
1619
|
-
active: "",
|
|
1620
|
-
disabled: "disabled:border-transparent disabled:cursor-default"
|
|
1621
|
-
}
|
|
1622
|
-
}
|
|
1623
|
-
}, q = {
|
|
1624
|
-
active: "active:bg-tertiary-10 active:border-tertiary-10 outline-none",
|
|
1625
|
-
base: "border border-secondary-10/[.25] hover:border-primary-10 flex items-center justify-center rounded-[6px] cursor-pointer",
|
|
1626
|
-
checked: "bg-primary-10 border-primary-10",
|
|
1627
|
-
disabled: "cursor-not-allowed bg-secondary-10/[.08] border border--secondary-10/[.25] hover:border--secondary-10/[.25]",
|
|
1628
|
-
hover: "hover:ring-2 hover:ring-primary-20/[.20] hover:ring-offset-0",
|
|
1629
|
-
sizes: {
|
|
1630
|
-
large: {
|
|
1631
|
-
label: "size-5"
|
|
1632
|
-
},
|
|
1633
|
-
medium: {
|
|
1634
|
-
label: "size-4"
|
|
1635
|
-
},
|
|
1636
|
-
small: {
|
|
1637
|
-
label: "size-2.5"
|
|
1638
|
-
}
|
|
1639
|
-
}
|
|
1640
|
-
};
|
|
1641
|
-
F(
|
|
1642
|
-
({
|
|
1643
|
-
checked: e = !1,
|
|
1644
|
-
className: r = "",
|
|
1645
|
-
disabled: i,
|
|
1646
|
-
id: t,
|
|
1647
|
-
onChange: n,
|
|
1648
|
-
size: l = "large",
|
|
1649
|
-
...d
|
|
1650
|
-
}, a) => {
|
|
1651
|
-
const s = q.base, u = q.sizes[l];
|
|
1652
|
-
return /* @__PURE__ */ p(
|
|
1653
|
-
"label",
|
|
1654
|
-
{
|
|
1655
|
-
"aria-label": "checkbox-label",
|
|
1656
|
-
htmlFor: t,
|
|
1657
|
-
tabIndex: 0,
|
|
1658
|
-
className: b(
|
|
1659
|
-
u.label,
|
|
1660
|
-
s,
|
|
1661
|
-
e && q.checked,
|
|
1662
|
-
!i && q.active,
|
|
1663
|
-
!i && e && q.hover,
|
|
1664
|
-
i && q.disabled,
|
|
1665
|
-
r
|
|
1666
|
-
),
|
|
1667
|
-
children: [
|
|
1668
|
-
/* @__PURE__ */ o(
|
|
1669
|
-
"input",
|
|
1670
|
-
{
|
|
1671
|
-
...d,
|
|
1672
|
-
role: "checkbox",
|
|
1673
|
-
id: t,
|
|
1674
|
-
disabled: i,
|
|
1675
|
-
checked: !!e,
|
|
1676
|
-
onChange: n,
|
|
1677
|
-
ref: a,
|
|
1678
|
-
type: "checkbox",
|
|
1679
|
-
className: "hidden peer"
|
|
1680
|
-
}
|
|
1681
|
-
),
|
|
1682
|
-
/* @__PURE__ */ o(
|
|
1683
|
-
ve,
|
|
1684
|
-
{
|
|
1685
|
-
width: 20,
|
|
1686
|
-
height: 18,
|
|
1687
|
-
viewBox: "0 0 20 20",
|
|
1688
|
-
className: b("opacity-0 fill-sidebar-10", e && "!opacity-100")
|
|
1689
|
-
}
|
|
1690
|
-
)
|
|
1691
|
-
]
|
|
1692
|
-
}
|
|
1693
|
-
);
|
|
1129
|
+
}, P = {
|
|
1130
|
+
image: "Photo",
|
|
1131
|
+
video: "Video",
|
|
1132
|
+
audio: "Voice message",
|
|
1133
|
+
file: "Файл"
|
|
1134
|
+
}, _e = (e, r, a) => {
|
|
1135
|
+
switch (e) {
|
|
1136
|
+
case "image":
|
|
1137
|
+
return P.image;
|
|
1138
|
+
case "video":
|
|
1139
|
+
return P.video;
|
|
1140
|
+
case "audio":
|
|
1141
|
+
return P.audio;
|
|
1142
|
+
case "file":
|
|
1143
|
+
return r || P.file;
|
|
1144
|
+
default:
|
|
1145
|
+
return a || null;
|
|
1694
1146
|
}
|
|
1695
|
-
|
|
1696
|
-
F(
|
|
1697
|
-
({
|
|
1698
|
-
disabled: e,
|
|
1699
|
-
onChange: r,
|
|
1700
|
-
placeholder: i,
|
|
1701
|
-
autoFocus: t = !1,
|
|
1702
|
-
status: n,
|
|
1703
|
-
maxLength: l,
|
|
1704
|
-
id: d,
|
|
1705
|
-
classNames: a,
|
|
1706
|
-
...s
|
|
1707
|
-
}, u) => {
|
|
1708
|
-
const f = I.parent, g = I.base, h = I.state, v = I.disabled, x = I.styles, y = I.maxLength;
|
|
1709
|
-
return /* @__PURE__ */ p("div", { className: b(f, a == null ? void 0 : a.parent), children: [
|
|
1710
|
-
/* @__PURE__ */ o(
|
|
1711
|
-
"input",
|
|
1712
|
-
{
|
|
1713
|
-
...s,
|
|
1714
|
-
role: "textbox",
|
|
1715
|
-
ref: u,
|
|
1716
|
-
id: d,
|
|
1717
|
-
disabled: e,
|
|
1718
|
-
autoFocus: t,
|
|
1719
|
-
onChange: r,
|
|
1720
|
-
maxLength: l,
|
|
1721
|
-
className: b(
|
|
1722
|
-
g,
|
|
1723
|
-
h.focus,
|
|
1724
|
-
!e && h.hover,
|
|
1725
|
-
n && (x == null ? void 0 : x[n]),
|
|
1726
|
-
e && v,
|
|
1727
|
-
a == null ? void 0 : a.target
|
|
1728
|
-
),
|
|
1729
|
-
placeholder: i
|
|
1730
|
-
}
|
|
1731
|
-
),
|
|
1732
|
-
l && /* @__PURE__ */ p(
|
|
1733
|
-
U,
|
|
1734
|
-
{
|
|
1735
|
-
variant: "span",
|
|
1736
|
-
className: b(
|
|
1737
|
-
y,
|
|
1738
|
-
String(s.value).length === l ? "bg-danger-10" : "bg-success-10"
|
|
1739
|
-
),
|
|
1740
|
-
children: [
|
|
1741
|
-
(s.value || "").toString().length,
|
|
1742
|
-
"/",
|
|
1743
|
-
l
|
|
1744
|
-
]
|
|
1745
|
-
}
|
|
1746
|
-
)
|
|
1747
|
-
] });
|
|
1748
|
-
}
|
|
1749
|
-
);
|
|
1750
|
-
const I = {
|
|
1751
|
-
parent: "relative flex flex-col items-start w-full",
|
|
1752
|
-
base: "text-dark-10 text-sm leading-none w-full rounded-[10px] bg-gray-50 border border-gray-50 p-[12.5px] placeholder:text-dark-10/[.40]",
|
|
1753
|
-
disabled: "bg-secondary-10/[.08] text-gray-30 cursor-not-allowed",
|
|
1754
|
-
state: {
|
|
1755
|
-
focus: "focus:outline-none focus:bg-white focus:border focus:border-primary-10 focus:ring-2 focus:ring-primary-10/[.20]",
|
|
1756
|
-
hover: "hover:bg-white hover:border-primary-10/[.31] hover:cursor-pointer transition-colors duration-200"
|
|
1757
|
-
},
|
|
1758
|
-
styles: {
|
|
1759
|
-
danger: "bg-white border-danger-10 ring-2 ring-danger-10/[.20] hover:border-danger-10",
|
|
1760
|
-
info: "bg-white border-info-10 ring ring-info-10/[.20] hover:border-info-10",
|
|
1761
|
-
success: "bg-white border-success-10 ring-2 ring-success-10/[.20] hover:border-success-10"
|
|
1762
|
-
},
|
|
1763
|
-
maxLength: "ml-auto px-1 mt-1 text-body-10 text-white rounded"
|
|
1764
|
-
};
|
|
1765
|
-
m.forwardRef(
|
|
1766
|
-
({ htmlFor: e, className: r, children: i, disabled: t, ...n }, l) => {
|
|
1767
|
-
const d = pe.base, a = pe.disabled;
|
|
1768
|
-
return /* @__PURE__ */ o(
|
|
1769
|
-
"label",
|
|
1770
|
-
{
|
|
1771
|
-
...n,
|
|
1772
|
-
role: "presentation",
|
|
1773
|
-
"aria-label": "input-label",
|
|
1774
|
-
ref: l,
|
|
1775
|
-
htmlFor: e,
|
|
1776
|
-
className: b(d, t && a, r),
|
|
1777
|
-
children: i
|
|
1778
|
-
}
|
|
1779
|
-
);
|
|
1780
|
-
}
|
|
1781
|
-
);
|
|
1782
|
-
const pe = {
|
|
1783
|
-
base: "text-secondary-10 text-sm font-sans font-semibold leading-none",
|
|
1784
|
-
disabled: "text-dark-30/25 cursor-not-allowed"
|
|
1785
|
-
}, kr = m.forwardRef(
|
|
1786
|
-
({
|
|
1787
|
-
id: e,
|
|
1788
|
-
text: r,
|
|
1789
|
-
timestamp: i,
|
|
1790
|
-
senderName: t,
|
|
1791
|
-
status: n,
|
|
1792
|
-
isMine: l = !1,
|
|
1793
|
-
selected: d = !1,
|
|
1794
|
-
firstMessage: a = !1,
|
|
1795
|
-
classNames: s,
|
|
1796
|
-
...u
|
|
1797
|
-
}, f) => {
|
|
1798
|
-
const g = G.base, h = G.wrapper, v = G.sender, x = G.message, y = G.timestamp;
|
|
1799
|
-
return /* @__PURE__ */ p(
|
|
1800
|
-
"div",
|
|
1801
|
-
{
|
|
1802
|
-
ref: f,
|
|
1803
|
-
id: e,
|
|
1804
|
-
"data-testid": "message",
|
|
1805
|
-
className: b(
|
|
1806
|
-
g,
|
|
1807
|
-
l && "bg-primary-10/[.15] border-dark-40/[.25]",
|
|
1808
|
-
d && !l && "bg-dark-40/[.25]",
|
|
1809
|
-
d && l && "bg-primary-10/[.55]",
|
|
1810
|
-
s == null ? void 0 : s.base
|
|
1811
|
-
),
|
|
1812
|
-
...u,
|
|
1813
|
-
children: [
|
|
1814
|
-
/* @__PURE__ */ p("div", { className: b(h.above), children: [
|
|
1815
|
-
!l && a && !!t && /* @__PURE__ */ o(
|
|
1816
|
-
"span",
|
|
1817
|
-
{
|
|
1818
|
-
"data-testid": "sender-name",
|
|
1819
|
-
className: b(v, s == null ? void 0 : s.sender),
|
|
1820
|
-
children: t
|
|
1821
|
-
}
|
|
1822
|
-
),
|
|
1823
|
-
!!r && /* @__PURE__ */ o(
|
|
1824
|
-
"span",
|
|
1825
|
-
{
|
|
1826
|
-
"data-testid": "message-text",
|
|
1827
|
-
className: b(x, s == null ? void 0 : s.message),
|
|
1828
|
-
children: r
|
|
1829
|
-
}
|
|
1830
|
-
)
|
|
1831
|
-
] }),
|
|
1832
|
-
/* @__PURE__ */ p("div", { className: h.below, children: [
|
|
1833
|
-
!!i && /* @__PURE__ */ o(
|
|
1834
|
-
"span",
|
|
1835
|
-
{
|
|
1836
|
-
"data-testid": "message-timestamp",
|
|
1837
|
-
className: b(
|
|
1838
|
-
y,
|
|
1839
|
-
s == null ? void 0 : s.timestamp,
|
|
1840
|
-
l ? "text-primary-10" : "text-dark-40/50",
|
|
1841
|
-
d && "text-dark-30"
|
|
1842
|
-
),
|
|
1843
|
-
children: Ie(i, "HH:mm")
|
|
1844
|
-
}
|
|
1845
|
-
),
|
|
1846
|
-
l && !!n && /* @__PURE__ */ p("div", { "data-testid": "message-status", className: "translate-y-0.5", children: [
|
|
1847
|
-
n === "delivered" && /* @__PURE__ */ o(
|
|
1848
|
-
mr,
|
|
1849
|
-
{
|
|
1850
|
-
className: "fill-primary-10",
|
|
1851
|
-
width: 16,
|
|
1852
|
-
height: 16,
|
|
1853
|
-
viewBox: "0 0 24 24"
|
|
1854
|
-
}
|
|
1855
|
-
),
|
|
1856
|
-
n === "read" && /* @__PURE__ */ o(
|
|
1857
|
-
fr,
|
|
1858
|
-
{
|
|
1859
|
-
className: "fill-transparent text-primary-10",
|
|
1860
|
-
width: 16,
|
|
1861
|
-
height: 16,
|
|
1862
|
-
viewBox: "0 0 16 16"
|
|
1863
|
-
}
|
|
1864
|
-
)
|
|
1865
|
-
] })
|
|
1866
|
-
] })
|
|
1867
|
-
]
|
|
1868
|
-
}
|
|
1869
|
-
);
|
|
1870
|
-
}
|
|
1871
|
-
);
|
|
1872
|
-
kr.displayName = "Message";
|
|
1873
|
-
const G = {
|
|
1874
|
-
base: "relative flex gap-3 bg-sidebar-10 border border-dark-40/[.25] rounded-[10px] px-2.5 py-2 min-h-10 w-max",
|
|
1875
|
-
wrapper: {
|
|
1876
|
-
above: "flex flex-col justify-center gap-0.5",
|
|
1877
|
-
below: "flex items-end justify-end gap-px"
|
|
1878
|
-
},
|
|
1879
|
-
sender: "text-primary-10 text-sm font-sans font-medium",
|
|
1880
|
-
message: "text-dark-30 text-sm font-sans font-medium",
|
|
1881
|
-
timestamp: "text-xs leading-none"
|
|
1882
|
-
}, Fr = F(
|
|
1883
|
-
({ checked: e, disabled: r, id: i, onChange: t, size: n = "large", className: l, ...d }, a) => {
|
|
1884
|
-
const s = C.sizes[n];
|
|
1885
|
-
return /* @__PURE__ */ p(
|
|
1886
|
-
"label",
|
|
1887
|
-
{
|
|
1888
|
-
htmlFor: i,
|
|
1889
|
-
"aria-label": "radio-label",
|
|
1890
|
-
className: b(
|
|
1891
|
-
C.base,
|
|
1892
|
-
s.label,
|
|
1893
|
-
r && C.disabled,
|
|
1894
|
-
!r && C.active,
|
|
1895
|
-
!e && !r && C.hover,
|
|
1896
|
-
!r && e && C.checked,
|
|
1897
|
-
l
|
|
1898
|
-
),
|
|
1899
|
-
children: [
|
|
1900
|
-
/* @__PURE__ */ o(
|
|
1901
|
-
"input",
|
|
1902
|
-
{
|
|
1903
|
-
...d,
|
|
1904
|
-
id: i,
|
|
1905
|
-
ref: a,
|
|
1906
|
-
type: "radio",
|
|
1907
|
-
role: "radio",
|
|
1908
|
-
checked: e,
|
|
1909
|
-
disabled: r,
|
|
1910
|
-
onChange: t,
|
|
1911
|
-
className: "hidden peer",
|
|
1912
|
-
"aria-checked": e,
|
|
1913
|
-
readOnly: !t
|
|
1914
|
-
}
|
|
1915
|
-
),
|
|
1916
|
-
/* @__PURE__ */ o(
|
|
1917
|
-
"span",
|
|
1918
|
-
{
|
|
1919
|
-
"aria-hidden": "true",
|
|
1920
|
-
className: b(
|
|
1921
|
-
e ? [C.radio.base, C.radio[n]] : "opacity-0",
|
|
1922
|
-
r && "bg-primary-30"
|
|
1923
|
-
)
|
|
1924
|
-
}
|
|
1925
|
-
)
|
|
1926
|
-
]
|
|
1927
|
-
}
|
|
1928
|
-
);
|
|
1929
|
-
}
|
|
1930
|
-
);
|
|
1931
|
-
Fr.displayName = "Radio";
|
|
1932
|
-
const C = {
|
|
1933
|
-
base: "border-2 border-dark-30/[.15] flex items-center justify-center rounded-full cursor-pointer outline-none bg-sidebar-10/[.08]",
|
|
1934
|
-
active: "active:border-primary-10",
|
|
1935
|
-
hover: "hover:border-primary-20/[.30]",
|
|
1936
|
-
checked: "border-dark-30/[.15]",
|
|
1937
|
-
disabled: "cursor-not-allowed bg-dark-30/[.08] border-2 border-dark-30/[.15] outline-none",
|
|
1938
|
-
radio: {
|
|
1939
|
-
base: "bg-primary-10 rounded-full opacity-100 peer-active:bg-primary-10 peer-hover:bg-primary-20 peer-disabled:border-sidebar-10/[.08] peer-disabled:bg-sidebar-10/[.08]",
|
|
1940
|
-
large: "size-3.5",
|
|
1941
|
-
medium: "size-2.5"
|
|
1942
|
-
},
|
|
1943
|
-
sizes: {
|
|
1944
|
-
large: {
|
|
1945
|
-
label: "size-6 min-w-6"
|
|
1946
|
-
},
|
|
1947
|
-
medium: {
|
|
1948
|
-
label: "size-5 min-w-5"
|
|
1949
|
-
}
|
|
1950
|
-
}
|
|
1951
|
-
}, { Root: Sr, Thumb: zr } = X;
|
|
1952
|
-
m.forwardRef(({ classNames: e, ...r }, i) => {
|
|
1953
|
-
const t = r.checked ?? !1;
|
|
1954
|
-
return /* @__PURE__ */ p(Sr, { ref: i, className: b(A.base, e == null ? void 0 : e.root), ...r, children: [
|
|
1955
|
-
/* @__PURE__ */ o(
|
|
1956
|
-
"div",
|
|
1957
|
-
{
|
|
1958
|
-
className: b(
|
|
1959
|
-
A.iconWrapper.base,
|
|
1960
|
-
"left-0",
|
|
1961
|
-
!t && A.iconWrapper.checked
|
|
1962
|
-
),
|
|
1963
|
-
children: /* @__PURE__ */ o(
|
|
1964
|
-
yr,
|
|
1965
|
-
{
|
|
1966
|
-
"data-testid": "list-icon",
|
|
1967
|
-
className: b(t ? "fill-dark-30/25" : "fill-dark-30/[.80]")
|
|
1968
|
-
}
|
|
1969
|
-
)
|
|
1970
|
-
}
|
|
1971
|
-
),
|
|
1972
|
-
/* @__PURE__ */ o(
|
|
1973
|
-
"div",
|
|
1974
|
-
{
|
|
1975
|
-
className: b(
|
|
1976
|
-
A.iconWrapper.base,
|
|
1977
|
-
"right-0",
|
|
1978
|
-
t && A.iconWrapper.checked
|
|
1979
|
-
),
|
|
1980
|
-
children: /* @__PURE__ */ o(
|
|
1981
|
-
xr,
|
|
1982
|
-
{
|
|
1983
|
-
"data-testid": "grid-icon",
|
|
1984
|
-
className: b(t ? "fill-dark-30/[.80]" : "fill-dark-30/25")
|
|
1985
|
-
}
|
|
1986
|
-
)
|
|
1987
|
-
}
|
|
1988
|
-
),
|
|
1989
|
-
/* @__PURE__ */ o("div", { className: b(A.borderLine) }),
|
|
1990
|
-
/* @__PURE__ */ o(zr, { tabIndex: 1, className: b(A.thumb, e == null ? void 0 : e.thumb) })
|
|
1991
|
-
] });
|
|
1992
|
-
});
|
|
1993
|
-
const A = {
|
|
1994
|
-
base: "group relative inline-flex w-20 h-[38px] shrink-0 cursor-pointer items-center bg-gray-50 rounded-[10px] transition-colors duration-200 transition-colors",
|
|
1995
|
-
thumb: "pointer-events-none block z-50 size-10 bg-transparent border border-secondary-10/[.15] transition-transform rounded-[10px] ring-0 data-[state=checked]:translate-x-full data-[state=unchecked]:translate-x-0",
|
|
1996
|
-
iconWrapper: {
|
|
1997
|
-
base: "absolute z-20 w-1/2 h-full flex items-center justify-center",
|
|
1998
|
-
checked: "bg-sidebar-10 rounded-[10px] overflow-hidden"
|
|
1999
|
-
},
|
|
2000
|
-
borderLine: "pointer-events-none absolute z-0 left-0 top-0 w-full h-full group-hover:border group-hover:border-primary-20/[.30] rounded-[10px] transition-colors duration-200"
|
|
2001
|
-
}, N = {
|
|
2002
|
-
sizes: {
|
|
2003
|
-
small: {
|
|
2004
|
-
base: "flex items-center justify-center min-w-32 bg-sidebar-10 text-xs font-medium leading-none border-[1px] rounded-md py-[7px] px-5",
|
|
2005
|
-
default: "text-dark-30/25 border-dark-30/25",
|
|
2006
|
-
active: "bg-gray-50 text-dark-30 border-dark-30/[.40]",
|
|
2007
|
-
hover: "hover:text-dark-30/[.40] hover:border-dark-30/[.40]",
|
|
2008
|
-
disabled: "bg-dark-30/[.08] text-dark-30/25 border-dark-30/25 cursor-not-allowed"
|
|
2009
|
-
},
|
|
2010
|
-
medium: {
|
|
2011
|
-
base: "flex items-center gap-1 pl-4 pr-5 py-2.5 bg-gray-50 text-sm font-semibold leading-none rounded-[10px] border",
|
|
2012
|
-
default: "border-gray-50 text-dark-30",
|
|
2013
|
-
active: "bg-primary-10 border-primary-10 text-white",
|
|
2014
|
-
hover: "hover:border-primary-10/[.30]",
|
|
2015
|
-
disabled: "bg-dark-30/[.08] text-dark-30/25 cursor-not-allowed"
|
|
2016
|
-
},
|
|
2017
|
-
large: {
|
|
2018
|
-
base: "flex items-center bg-gray-50 px-8 py-3.5 text-sm font-regular leading-none border rounded-[10px] focus:outline-none focus:ring focus:ring-transparent",
|
|
2019
|
-
default: "text-dark-40/50 border-dark-30/[.15]",
|
|
2020
|
-
active: "bg-primary-10/[.10] text-dark-30 font-semibold border border-primary-10/[.20]",
|
|
2021
|
-
hover: "hover:border-primary-20/[.20]",
|
|
2022
|
-
disabled: "bg-dark-30/[.08] text-dark-30/25 border-dark-30/25 cursor-not-allowed"
|
|
2023
|
-
}
|
|
2024
|
-
},
|
|
2025
|
-
focus: "focus:outline-none focus:ring focus:ring-primary-10/[.20]",
|
|
2026
|
-
icon: {
|
|
2027
|
-
default: "fill-dark-30",
|
|
2028
|
-
active: "fill-white",
|
|
2029
|
-
disabled: "fill-dark-30/25"
|
|
2030
|
-
}
|
|
2031
|
-
};
|
|
2032
|
-
F(
|
|
2033
|
-
({
|
|
2034
|
-
variant: e = "small",
|
|
2035
|
-
active: r,
|
|
2036
|
-
icon: i,
|
|
2037
|
-
disabled: t,
|
|
2038
|
-
children: n,
|
|
2039
|
-
className: l,
|
|
2040
|
-
iconDimensions: d,
|
|
2041
|
-
...a
|
|
2042
|
-
}, s) => {
|
|
2043
|
-
const u = N.sizes[e];
|
|
2044
|
-
return /* @__PURE__ */ p(
|
|
2045
|
-
"button",
|
|
2046
|
-
{
|
|
2047
|
-
role: "tab",
|
|
2048
|
-
"aria-selected": r,
|
|
2049
|
-
ref: s,
|
|
2050
|
-
className: b(
|
|
2051
|
-
u.base,
|
|
2052
|
-
u.default,
|
|
2053
|
-
!t && !r && u.hover,
|
|
2054
|
-
r && !t && u.active,
|
|
2055
|
-
r && !t && N.focus,
|
|
2056
|
-
t && u.disabled,
|
|
2057
|
-
l
|
|
2058
|
-
),
|
|
2059
|
-
...a,
|
|
2060
|
-
children: [
|
|
2061
|
-
!!i && /* @__PURE__ */ o(
|
|
2062
|
-
i,
|
|
2063
|
-
{
|
|
2064
|
-
"aria-label": "icon",
|
|
2065
|
-
"aria-hidden": !0,
|
|
2066
|
-
className: b(
|
|
2067
|
-
N.icon.default,
|
|
2068
|
-
r && N.icon.active,
|
|
2069
|
-
t && N.icon.disabled
|
|
2070
|
-
),
|
|
2071
|
-
...d
|
|
2072
|
-
}
|
|
2073
|
-
),
|
|
2074
|
-
n
|
|
2075
|
-
]
|
|
2076
|
-
}
|
|
2077
|
-
);
|
|
2078
|
-
}
|
|
2079
|
-
);
|
|
2080
|
-
const U = ({
|
|
2081
|
-
children: e,
|
|
2082
|
-
className: r = "",
|
|
2083
|
-
variant: i = "p",
|
|
2084
|
-
...t
|
|
2085
|
-
}) => /* @__PURE__ */ o(i, { ...t, className: b(r), children: e });
|
|
2086
|
-
m.forwardRef(
|
|
2087
|
-
({
|
|
2088
|
-
className: e = "",
|
|
2089
|
-
disabled: r,
|
|
2090
|
-
onChange: i,
|
|
2091
|
-
placeholder: t = "Введите текст",
|
|
2092
|
-
autoFocus: n = !1,
|
|
2093
|
-
status: l,
|
|
2094
|
-
maxLength: d,
|
|
2095
|
-
...a
|
|
2096
|
-
}, s) => {
|
|
2097
|
-
var u, f;
|
|
2098
|
-
const g = W.base, h = W.state, v = W.disabled, x = W.styles, y = W.maxLength;
|
|
2099
|
-
return /* @__PURE__ */ p("div", { className: W.root, children: [
|
|
2100
|
-
/* @__PURE__ */ o(
|
|
2101
|
-
"textarea",
|
|
2102
|
-
{
|
|
2103
|
-
...a,
|
|
2104
|
-
role: "textbox",
|
|
2105
|
-
ref: s,
|
|
2106
|
-
maxLength: d,
|
|
2107
|
-
disabled: r,
|
|
2108
|
-
autoFocus: n,
|
|
2109
|
-
placeholder: t,
|
|
2110
|
-
onChange: i,
|
|
2111
|
-
className: b(
|
|
2112
|
-
g,
|
|
2113
|
-
h.focus,
|
|
2114
|
-
!r && h.hover,
|
|
2115
|
-
l && (x == null ? void 0 : x[l]),
|
|
2116
|
-
r && v,
|
|
2117
|
-
e
|
|
2118
|
-
)
|
|
2119
|
-
}
|
|
2120
|
-
),
|
|
2121
|
-
/* @__PURE__ */ o("div", { className: W.messageContainer, children: d && /* @__PURE__ */ p(
|
|
2122
|
-
U,
|
|
2123
|
-
{
|
|
2124
|
-
variant: "span",
|
|
2125
|
-
className: b(
|
|
2126
|
-
y,
|
|
2127
|
-
String(a.value).length === d ? "bg-danger-10 text-sidebar-10" : "bg-transparent"
|
|
2128
|
-
),
|
|
2129
|
-
children: [
|
|
2130
|
-
(f = (u = a.value || "") == null ? void 0 : u.toString()) == null ? void 0 : f.length,
|
|
2131
|
-
"/",
|
|
2132
|
-
d
|
|
2133
|
-
]
|
|
2134
|
-
}
|
|
2135
|
-
) })
|
|
2136
|
-
] });
|
|
2137
|
-
}
|
|
2138
|
-
);
|
|
2139
|
-
const W = {
|
|
2140
|
-
root: "flex flex-col gap-1 w-full",
|
|
2141
|
-
base: "w-full min-h-[60px] bg-gray-50 text-sm text-dark-10 font-sans font-medium leading-none px-3.5 py-3 border border-gray-50 rounded-[10px] placeholder:text-sm placeholder:text-dark-40/50 transition-colors duration-200",
|
|
2142
|
-
disabled: "text-dark-40/25 bg-dark-30/[.08] cursor-not-allowed",
|
|
2143
|
-
state: {
|
|
2144
|
-
focus: "focus:outline-none focus:bg-white focus:border focus:border-primary-10 focus:ring-2 focus:ring-primary-10/[.20]",
|
|
2145
|
-
hover: "hover:border-primary-10/[.31]"
|
|
2146
|
-
},
|
|
2147
|
-
styles: {
|
|
2148
|
-
danger: "bg-white border-danger-10 ring-2 ring-danger-10/[.20] hover:border-danger-10",
|
|
2149
|
-
info: "bg-white border-info-10 ring ring-info-10/[.20] hover:border-info-10",
|
|
2150
|
-
success: "bg-white border-success-10 ring-2 ring-success-10/[.20] hover:border-success-10"
|
|
2151
|
-
},
|
|
2152
|
-
messageContainer: "flex items-center leading-none",
|
|
2153
|
-
maxLength: "ml-auto p-1 text-dark-40/50 text-sm font-regular leading-none rounded"
|
|
2154
|
-
}, { Root: Cr, Thumb: Br } = X;
|
|
2155
|
-
m.forwardRef(
|
|
2156
|
-
({ label: e = "", labelPosition: r = "right", disabled: i, classNames: t, ...n }, l) => /* @__PURE__ */ p(
|
|
2157
|
-
"div",
|
|
2158
|
-
{
|
|
2159
|
-
className: b(
|
|
2160
|
-
"flex items-center w-fit",
|
|
2161
|
-
r === "right" && "flex-row-reverse"
|
|
2162
|
-
),
|
|
2163
|
-
children: [
|
|
2164
|
-
!!e && /* @__PURE__ */ o(
|
|
2165
|
-
"span",
|
|
2166
|
-
{
|
|
2167
|
-
className: b(
|
|
2168
|
-
ae.label,
|
|
2169
|
-
r === "right" && "ml-2",
|
|
2170
|
-
i && "cursor-not-allowed text-dark-30/[.20]",
|
|
2171
|
-
t == null ? void 0 : t.label
|
|
2172
|
-
),
|
|
2173
|
-
children: e
|
|
2174
|
-
}
|
|
2175
|
-
),
|
|
2176
|
-
/* @__PURE__ */ o(
|
|
2177
|
-
Cr,
|
|
2178
|
-
{
|
|
2179
|
-
ref: l,
|
|
2180
|
-
disabled: i,
|
|
2181
|
-
className: b(ae.base, t == null ? void 0 : t.base),
|
|
2182
|
-
...n,
|
|
2183
|
-
children: /* @__PURE__ */ o(
|
|
2184
|
-
Br,
|
|
2185
|
-
{
|
|
2186
|
-
tabIndex: 1,
|
|
2187
|
-
className: b(ae.thumb, t == null ? void 0 : t.thumb)
|
|
2188
|
-
}
|
|
2189
|
-
)
|
|
2190
|
-
}
|
|
2191
|
-
)
|
|
2192
|
-
]
|
|
2193
|
-
}
|
|
2194
|
-
)
|
|
2195
|
-
);
|
|
2196
|
-
const ae = {
|
|
2197
|
-
base: "inline-flex h-8 w-[52px] shrink-0 p-1 cursor-pointer items-center rounded-full border border-success-20 transition-colors focus:outline-none disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-success-20 data-[state=unchecked]:bg-secondary-10/[.08] data-[state=unchecked]:border-secondary-10/[.30] disabled:data-[state=unchecked]:bg-secondary-10/[.15] disabled:data-[state=unchecked]:border-transparent",
|
|
2198
|
-
label: "mr-2 text-dark-30 text-sm",
|
|
2199
|
-
thumb: "pointer-events-none block size-6 transition-transform rounded-full ring-0 data-[state=checked]:translate-x-3/4 data-[state=unchecked]:translate-x-0 data-[state=checked]:bg-white data-[state=unchecked]:bg-secondary-10/[.30]"
|
|
2200
|
-
};
|
|
2201
|
-
b(
|
|
2202
|
-
"font-mono select-none w-auto h-auto max-size-32 rounded-[5px] bg-dark-30 px-4 py-2 text-[10px] text-start leading-none text-sidebar-10 z-50",
|
|
2203
|
-
"animate-tooltipFade data-[state=delayed-open]:data-[side=bottom]:animate-slideUpAndFade",
|
|
2204
|
-
"data-[state=delayed-open]:data-[side=left]:animate-slideRightAndFade",
|
|
2205
|
-
"data-[state=delayed-open]:data-[side=right]:animate-slideLeftAndFade",
|
|
2206
|
-
"data-[state=delayed-open]:data-[side=top]:animate-slideDownAndFade"
|
|
2207
|
-
);
|
|
2208
|
-
const Tr = m.forwardRef(
|
|
2209
|
-
({
|
|
2210
|
-
imageSrc: e,
|
|
2211
|
-
alt: r,
|
|
2212
|
-
hasBadge: i = !1,
|
|
2213
|
-
iconSize: t,
|
|
2214
|
-
isActive: n,
|
|
2215
|
-
isHasCamera: l = !1,
|
|
2216
|
-
onAvatarChange: d,
|
|
2217
|
-
classNames: a
|
|
2218
|
-
}, s) => {
|
|
2219
|
-
const u = K.root, f = K.image, g = K.badge;
|
|
2220
|
-
return /* @__PURE__ */ p(
|
|
2221
|
-
ge,
|
|
2222
|
-
{
|
|
2223
|
-
role: "group",
|
|
2224
|
-
"data-testid": "avatar-root",
|
|
2225
|
-
onClick: () => {
|
|
2226
|
-
var h;
|
|
2227
|
-
return (h = s == null ? void 0 : s.current) == null ? void 0 : h.click();
|
|
2228
|
-
},
|
|
2229
|
-
className: b(
|
|
2230
|
-
u,
|
|
2231
|
-
i && "bg-dark-30/[.10]",
|
|
2232
|
-
n && K.active,
|
|
2233
|
-
a == null ? void 0 : a.wrapper
|
|
2234
|
-
),
|
|
2235
|
-
children: [
|
|
2236
|
-
!!s && /* @__PURE__ */ o(
|
|
2237
|
-
"input",
|
|
2238
|
-
{
|
|
2239
|
-
ref: s,
|
|
2240
|
-
type: "file",
|
|
2241
|
-
accept: ".png,.jpg,.jpeg,image/png,image/jpeg",
|
|
2242
|
-
className: "hidden",
|
|
2243
|
-
onChange: d
|
|
2244
|
-
}
|
|
2245
|
-
),
|
|
2246
|
-
e ? /* @__PURE__ */ o(
|
|
2247
|
-
fe,
|
|
2248
|
-
{
|
|
2249
|
-
role: "img",
|
|
2250
|
-
"data-testid": "avatar-img",
|
|
2251
|
-
src: e,
|
|
2252
|
-
alt: r ?? "empty-avatar",
|
|
2253
|
-
className: b(f, a == null ? void 0 : a.img)
|
|
2254
|
-
}
|
|
2255
|
-
) : /* @__PURE__ */ o(me, { children: l ? /* @__PURE__ */ o(
|
|
2256
|
-
ue,
|
|
2257
|
-
{
|
|
2258
|
-
width: 38,
|
|
2259
|
-
height: 30,
|
|
2260
|
-
className: b("fill-dark-30/[.20]", a == null ? void 0 : a.badgeIcon),
|
|
2261
|
-
viewBox: "0 0 38 30"
|
|
2262
|
-
}
|
|
2263
|
-
) : /* @__PURE__ */ o(
|
|
2264
|
-
vr,
|
|
2265
|
-
{
|
|
2266
|
-
"data-testid": "icon-avatar",
|
|
2267
|
-
"aria-label": "icon-avatar",
|
|
2268
|
-
height: (t == null ? void 0 : t.height) ?? 17,
|
|
2269
|
-
width: (t == null ? void 0 : t.width) ?? 17,
|
|
2270
|
-
className: b(
|
|
2271
|
-
"fill-sidebar-10",
|
|
2272
|
-
i && "fill-dark-30/[.15]",
|
|
2273
|
-
a == null ? void 0 : a.fallbackIcon
|
|
2274
|
-
)
|
|
2275
|
-
}
|
|
2276
|
-
) }),
|
|
2277
|
-
i && /* @__PURE__ */ o(
|
|
2278
|
-
"div",
|
|
2279
|
-
{
|
|
2280
|
-
"data-testid": "avatar-badge",
|
|
2281
|
-
className: b(g.wrapper, a == null ? void 0 : a.badge),
|
|
2282
|
-
children: n ? /* @__PURE__ */ o(
|
|
2283
|
-
ve,
|
|
2284
|
-
{
|
|
2285
|
-
width: 14,
|
|
2286
|
-
height: 14,
|
|
2287
|
-
viewBox: "0 0 20 20",
|
|
2288
|
-
className: "fill-sidebar-10"
|
|
2289
|
-
}
|
|
2290
|
-
) : /* @__PURE__ */ o(
|
|
2291
|
-
ue,
|
|
2292
|
-
{
|
|
2293
|
-
width: 16,
|
|
2294
|
-
height: 13,
|
|
2295
|
-
viewBox: "0 0 38 30",
|
|
2296
|
-
className: b("fill-sidebar-10", a == null ? void 0 : a.badgeIcon)
|
|
2297
|
-
}
|
|
2298
|
-
)
|
|
2299
|
-
}
|
|
2300
|
-
)
|
|
2301
|
-
]
|
|
2302
|
-
}
|
|
2303
|
-
);
|
|
2304
|
-
}
|
|
2305
|
-
);
|
|
2306
|
-
Tr.displayName = "Avatar";
|
|
2307
|
-
const K = {
|
|
2308
|
-
root: "size-9 relative flex items-center justify-center bg-dark-30/[.10] rounded-full",
|
|
2309
|
-
image: "size-full object-center object-cover rounded-full",
|
|
2310
|
-
badge: {
|
|
2311
|
-
wrapper: "absolute bottom-2 right-2 transform translate-x-1/4 translate-y-1/4 flex items-center justify-center bg-primary-10 px-2.5 py-3 border-2 border-sidebar-10 rounded-full"
|
|
2312
|
-
},
|
|
2313
|
-
active: "ring ring-2 ring-offset-1 ring-primary-10"
|
|
2314
|
-
}, Q = {
|
|
2315
|
-
image: "Photo",
|
|
2316
|
-
video: "Video",
|
|
2317
|
-
audio: "Voice message",
|
|
2318
|
-
file: "Файл"
|
|
2319
|
-
}, gt = ({
|
|
1147
|
+
}, cr = ({
|
|
2320
1148
|
senderName: e,
|
|
2321
1149
|
messageText: r,
|
|
2322
|
-
contentType:
|
|
2323
|
-
fileUrl:
|
|
2324
|
-
fileName:
|
|
2325
|
-
onClose:
|
|
2326
|
-
showCloseButton:
|
|
2327
|
-
classNames:
|
|
1150
|
+
contentType: a = "text",
|
|
1151
|
+
fileUrl: o,
|
|
1152
|
+
fileName: d,
|
|
1153
|
+
onClose: s,
|
|
1154
|
+
showCloseButton: l = !0,
|
|
1155
|
+
classNames: t
|
|
2328
1156
|
}) => {
|
|
2329
|
-
const
|
|
2330
|
-
|
|
2331
|
-
case "image":
|
|
2332
|
-
return /* @__PURE__ */ o("span", { className: k.mediaLabel, children: Q.image });
|
|
2333
|
-
case "video":
|
|
2334
|
-
return /* @__PURE__ */ o("span", { className: k.mediaLabel, children: Q.video });
|
|
2335
|
-
case "audio":
|
|
2336
|
-
return /* @__PURE__ */ o("span", { className: k.mediaLabel, children: Q.audio });
|
|
2337
|
-
case "file":
|
|
2338
|
-
return /* @__PURE__ */ o("span", { className: k.mediaLabel, children: n || Q.file });
|
|
2339
|
-
default:
|
|
2340
|
-
return r || null;
|
|
2341
|
-
}
|
|
2342
|
-
};
|
|
2343
|
-
return /* @__PURE__ */ p(
|
|
1157
|
+
const b = _e(a, d, r);
|
|
1158
|
+
return /* @__PURE__ */ c(
|
|
2344
1159
|
"div",
|
|
2345
1160
|
{
|
|
2346
|
-
className:
|
|
1161
|
+
className: n(k.wrapper, t == null ? void 0 : t.wrapper),
|
|
2347
1162
|
"data-testid": "chat-edit-row",
|
|
2348
1163
|
children: [
|
|
2349
|
-
/* @__PURE__ */
|
|
2350
|
-
(
|
|
1164
|
+
/* @__PURE__ */ c("div", { className: n(k.message, t == null ? void 0 : t.message), children: [
|
|
1165
|
+
(a === "image" || a === "video") && o && /* @__PURE__ */ i(
|
|
2351
1166
|
"img",
|
|
2352
1167
|
{
|
|
2353
|
-
src:
|
|
2354
|
-
alt:
|
|
1168
|
+
src: o,
|
|
1169
|
+
alt: d || "thumbnail",
|
|
2355
1170
|
"data-testid": "reply-thumbnail",
|
|
2356
|
-
className:
|
|
1171
|
+
className: n(k.thumbnail, t == null ? void 0 : t.thumbnail)
|
|
2357
1172
|
}
|
|
2358
1173
|
),
|
|
2359
|
-
/* @__PURE__ */
|
|
2360
|
-
/* @__PURE__ */
|
|
2361
|
-
|
|
1174
|
+
/* @__PURE__ */ c("div", { className: n(k.content, t == null ? void 0 : t.content), children: [
|
|
1175
|
+
/* @__PURE__ */ i(
|
|
1176
|
+
w,
|
|
2362
1177
|
{
|
|
2363
1178
|
variant: "span",
|
|
2364
|
-
className:
|
|
1179
|
+
className: n(k.title, t == null ? void 0 : t.title),
|
|
2365
1180
|
"data-testid": "chat-edit-title",
|
|
2366
1181
|
children: e
|
|
2367
1182
|
}
|
|
2368
1183
|
),
|
|
2369
|
-
/* @__PURE__ */
|
|
2370
|
-
|
|
1184
|
+
/* @__PURE__ */ i(
|
|
1185
|
+
w,
|
|
2371
1186
|
{
|
|
2372
1187
|
variant: "span",
|
|
2373
|
-
className:
|
|
1188
|
+
className: n(k.subtitle, t == null ? void 0 : t.subtitle),
|
|
2374
1189
|
"data-testid": "chat-edit-subtitle",
|
|
2375
|
-
children:
|
|
1190
|
+
children: a !== "text" ? /* @__PURE__ */ i("span", { className: k.mediaLabel, children: b }) : b
|
|
2376
1191
|
}
|
|
2377
1192
|
)
|
|
2378
1193
|
] })
|
|
2379
1194
|
] }),
|
|
2380
|
-
|
|
2381
|
-
|
|
1195
|
+
l && /* @__PURE__ */ i(
|
|
1196
|
+
we,
|
|
2382
1197
|
{
|
|
2383
1198
|
"data-testid": "chat-close-edit",
|
|
2384
1199
|
shape: "circle",
|
|
2385
1200
|
classNames: {
|
|
2386
|
-
button:
|
|
2387
|
-
icon:
|
|
1201
|
+
button: n(k.closeButton, t == null ? void 0 : t.closeButton),
|
|
1202
|
+
icon: n(k.closeIcon, t == null ? void 0 : t.closeIcon)
|
|
2388
1203
|
},
|
|
2389
|
-
icon:
|
|
1204
|
+
icon: oe,
|
|
2390
1205
|
iconSizes: { width: 24, height: 24, viewBox: "0 0 20 20" },
|
|
2391
|
-
onClick:
|
|
1206
|
+
onClick: s
|
|
2392
1207
|
}
|
|
2393
1208
|
)
|
|
2394
1209
|
]
|
|
@@ -2406,43 +1221,43 @@ const K = {
|
|
|
2406
1221
|
mediaLabel: "inline-flex items-center gap-1 text-sm text-dark-40 font-medium"
|
|
2407
1222
|
};
|
|
2408
1223
|
export {
|
|
2409
|
-
|
|
2410
|
-
|
|
2411
|
-
|
|
2412
|
-
|
|
2413
|
-
|
|
2414
|
-
|
|
2415
|
-
|
|
2416
|
-
|
|
2417
|
-
|
|
2418
|
-
|
|
2419
|
-
|
|
2420
|
-
|
|
2421
|
-
|
|
2422
|
-
|
|
2423
|
-
|
|
2424
|
-
|
|
2425
|
-
|
|
2426
|
-
|
|
2427
|
-
|
|
2428
|
-
|
|
2429
|
-
|
|
2430
|
-
|
|
2431
|
-
|
|
2432
|
-
|
|
2433
|
-
|
|
2434
|
-
|
|
2435
|
-
|
|
2436
|
-
|
|
1224
|
+
Ie as Avatar,
|
|
1225
|
+
Xe as Button,
|
|
1226
|
+
Ye as Checkbox,
|
|
1227
|
+
Ze as Headline,
|
|
1228
|
+
we as IconButton,
|
|
1229
|
+
Ne as Input,
|
|
1230
|
+
er as Label,
|
|
1231
|
+
rr as Notification,
|
|
1232
|
+
je as Radio,
|
|
1233
|
+
cr as ReplyMessage,
|
|
1234
|
+
lr as Select,
|
|
1235
|
+
br as Skeleton,
|
|
1236
|
+
Ve as Spinner,
|
|
1237
|
+
tr as Status,
|
|
1238
|
+
or as Switch,
|
|
1239
|
+
ir as Tab,
|
|
1240
|
+
sr as TabDots,
|
|
1241
|
+
w as Text,
|
|
1242
|
+
ar as Textarea,
|
|
1243
|
+
nr as Toggle,
|
|
1244
|
+
dr as Tooltip,
|
|
1245
|
+
I as avatarIconTokens,
|
|
1246
|
+
L as buttonTokens,
|
|
1247
|
+
B as checkboxTokens,
|
|
1248
|
+
R as iconButtonTokens,
|
|
1249
|
+
z as inputTokens,
|
|
1250
|
+
J as labelTokens,
|
|
1251
|
+
S as radioTokens,
|
|
2437
1252
|
k as replyMessageTokens,
|
|
2438
|
-
|
|
2439
|
-
|
|
2440
|
-
|
|
2441
|
-
|
|
2442
|
-
|
|
1253
|
+
D as selectTokens,
|
|
1254
|
+
Pe as skeletonTokens,
|
|
1255
|
+
E as spinnerTokens,
|
|
1256
|
+
K as statusTokens,
|
|
1257
|
+
C as switchTokens,
|
|
2443
1258
|
$ as tabDotsTokens,
|
|
2444
|
-
|
|
2445
|
-
|
|
2446
|
-
|
|
2447
|
-
|
|
1259
|
+
O as tabTokens,
|
|
1260
|
+
A as textareaTokens,
|
|
1261
|
+
_ as toggleTokens,
|
|
1262
|
+
Q as tooltipTokens
|
|
2448
1263
|
};
|