@herca/r-kit 0.0.83 → 0.0.84
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/clients.cjs +110 -83
- package/dist/clients.cjs.map +1 -1
- package/dist/clients.d.cts +5 -2
- package/dist/clients.d.ts +5 -2
- package/dist/clients.js +110 -83
- package/dist/clients.js.map +1 -1
- package/package.json +1 -1
package/dist/clients.js
CHANGED
|
@@ -13126,6 +13126,7 @@ var PreviewItem = ({
|
|
|
13126
13126
|
};
|
|
13127
13127
|
|
|
13128
13128
|
// src/components/input-file/input-file.tsx
|
|
13129
|
+
import clsx5 from "clsx";
|
|
13129
13130
|
import { jsx as jsx415, jsxs as jsxs79 } from "react/jsx-runtime";
|
|
13130
13131
|
var defaultExtractUrl = (res) => {
|
|
13131
13132
|
if (res !== null && typeof res === "object" && "url" in res && typeof res.url === "string") {
|
|
@@ -13158,7 +13159,8 @@ var InputFile = forwardRef2(
|
|
|
13158
13159
|
uploadConfig,
|
|
13159
13160
|
onUploadSuccess,
|
|
13160
13161
|
onRemoveFile,
|
|
13161
|
-
onClear
|
|
13162
|
+
onClear,
|
|
13163
|
+
selectedFilesClassName
|
|
13162
13164
|
}, ref) => {
|
|
13163
13165
|
const inputRef = useRef4(null);
|
|
13164
13166
|
const replaceInputRef = useRef4(null);
|
|
@@ -13569,7 +13571,7 @@ var InputFile = forwardRef2(
|
|
|
13569
13571
|
className: "hidden"
|
|
13570
13572
|
}
|
|
13571
13573
|
),
|
|
13572
|
-
files.length > 0 && /* @__PURE__ */ jsxs79("div", { className: "flex flex-col gap-3", children: [
|
|
13574
|
+
files.length > 0 && /* @__PURE__ */ jsxs79("div", { className: clsx5("flex flex-col gap-3", selectedFilesClassName), children: [
|
|
13573
13575
|
/* @__PURE__ */ jsxs79("div", { className: "flex items-center justify-between", children: [
|
|
13574
13576
|
/* @__PURE__ */ jsx415(
|
|
13575
13577
|
Text,
|
|
@@ -13892,11 +13894,11 @@ var InputOTP = ({
|
|
|
13892
13894
|
const fullPattern = FULL_PATTERNS[type];
|
|
13893
13895
|
const hasError = Array.isArray(errorMessages) ? errorMessages.length > 0 : typeof errorMessages === "string" && errorMessages.length > 0;
|
|
13894
13896
|
const values = React402.useMemo(() => {
|
|
13895
|
-
const chars = value
|
|
13896
|
-
return Array.from({ length }, (_2, i) => chars[i] ?? "");
|
|
13897
|
+
const chars = value?.split("");
|
|
13898
|
+
return Array.from({ length }, (_2, i) => chars?.[i] ?? "");
|
|
13897
13899
|
}, [value, length]);
|
|
13898
13900
|
React402.useEffect(() => {
|
|
13899
|
-
if (value
|
|
13901
|
+
if (value?.length === length && previousValueRef.current != void 0 && previousValueRef.current.length !== length) {
|
|
13900
13902
|
onComplete?.(value);
|
|
13901
13903
|
}
|
|
13902
13904
|
previousValueRef.current = value;
|
|
@@ -14021,6 +14023,7 @@ var InputOTP = ({
|
|
|
14021
14023
|
name !== void 0 && name.length > 0 && /* @__PURE__ */ jsx417("input", { type: "hidden", name, value, required }),
|
|
14022
14024
|
values.map((char, i) => {
|
|
14023
14025
|
const displayValue = mask && char.length > 0 ? "\u2022" : char;
|
|
14026
|
+
console.log(displayValue);
|
|
14024
14027
|
const inputId = i === 0 ? fieldId : `${fieldId}-${i}`;
|
|
14025
14028
|
const computedAriaLabel = ariaLabel !== void 0 ? ariaLabel(i, length) : `Digit ${i + 1} of ${length}`;
|
|
14026
14029
|
return /* @__PURE__ */ jsxs81(React402.Fragment, { children: [
|
|
@@ -14031,7 +14034,7 @@ var InputOTP = ({
|
|
|
14031
14034
|
inputsRef.current[i] = el;
|
|
14032
14035
|
},
|
|
14033
14036
|
id: inputId,
|
|
14034
|
-
value:
|
|
14037
|
+
value: char,
|
|
14035
14038
|
disabled,
|
|
14036
14039
|
readOnly,
|
|
14037
14040
|
required: required && i === 0,
|
|
@@ -14139,7 +14142,7 @@ function useCopy() {
|
|
|
14139
14142
|
}
|
|
14140
14143
|
|
|
14141
14144
|
// src/components/table/table.tsx
|
|
14142
|
-
import
|
|
14145
|
+
import clsx6 from "clsx";
|
|
14143
14146
|
import { createContext as createContext3, useContext as useContext3, useState as useState9 } from "react";
|
|
14144
14147
|
|
|
14145
14148
|
// src/components/table/table-variants.ts
|
|
@@ -14196,7 +14199,7 @@ function Table({
|
|
|
14196
14199
|
return /* @__PURE__ */ jsx419(TableContext.Provider, { value: { variant }, children: /* @__PURE__ */ jsx419(
|
|
14197
14200
|
"table",
|
|
14198
14201
|
{
|
|
14199
|
-
className:
|
|
14202
|
+
className: clsx6(
|
|
14200
14203
|
className,
|
|
14201
14204
|
"overflow-hidden",
|
|
14202
14205
|
(variant === "bordered" || variant == "stripped" || variant == "hovered" || variant === "wrapped-row-bordered") && "border-separate border-spacing-0",
|
|
@@ -14218,7 +14221,7 @@ function TableBody({ children, className }) {
|
|
|
14218
14221
|
return /* @__PURE__ */ jsx419(
|
|
14219
14222
|
"tbody",
|
|
14220
14223
|
{
|
|
14221
|
-
className:
|
|
14224
|
+
className: clsx6(
|
|
14222
14225
|
(isBordered || isStripped || isHovered) && "[&>tr:last-child>td:first-child]:rounded-bl-lg [&>tr:last-child>td:last-child]:rounded-br-lg",
|
|
14223
14226
|
isWrapped && "[&>tr>td:first-child]:border-l-0!",
|
|
14224
14227
|
className
|
|
@@ -14242,7 +14245,7 @@ function TableRow({
|
|
|
14242
14245
|
return /* @__PURE__ */ jsx419(TableRowContext.Provider, { value: { isLast }, children: /* @__PURE__ */ jsx419(
|
|
14243
14246
|
"tr",
|
|
14244
14247
|
{
|
|
14245
|
-
className:
|
|
14248
|
+
className: clsx6(
|
|
14246
14249
|
TableVariants({ tableRow: variant }),
|
|
14247
14250
|
"[&>th:first-child]:rounded-tl-lg [&>th:last-child]:rounded-tr-lg",
|
|
14248
14251
|
Boolean(isLast) && "border-b-0!",
|
|
@@ -14267,7 +14270,7 @@ function TableCellHead({
|
|
|
14267
14270
|
return /* @__PURE__ */ jsx419("th", { className: cn(className, "px-4 py-3"), children: value !== void 0 ? /* @__PURE__ */ jsxs82(
|
|
14268
14271
|
"button",
|
|
14269
14272
|
{
|
|
14270
|
-
className:
|
|
14273
|
+
className: clsx6(
|
|
14271
14274
|
"flex items-center gap-2.5",
|
|
14272
14275
|
!!onClick && "cursor-pointer"
|
|
14273
14276
|
),
|
|
@@ -14347,7 +14350,7 @@ function TablePagination({
|
|
|
14347
14350
|
return /* @__PURE__ */ jsxs82(
|
|
14348
14351
|
"div",
|
|
14349
14352
|
{
|
|
14350
|
-
className:
|
|
14353
|
+
className: clsx6(
|
|
14351
14354
|
"flex w-full items-center justify-between md:flex-nowrap",
|
|
14352
14355
|
wrapperClassName
|
|
14353
14356
|
),
|
|
@@ -14367,7 +14370,7 @@ function TablePagination({
|
|
|
14367
14370
|
/* @__PURE__ */ jsx419(
|
|
14368
14371
|
DropdownTrigger,
|
|
14369
14372
|
{
|
|
14370
|
-
className:
|
|
14373
|
+
className: clsx6("outline-none", dropdownTriggerClassName),
|
|
14371
14374
|
children: /* @__PURE__ */ jsx419(
|
|
14372
14375
|
Input,
|
|
14373
14376
|
{
|
|
@@ -14391,7 +14394,7 @@ function TablePagination({
|
|
|
14391
14394
|
/* @__PURE__ */ jsx419(
|
|
14392
14395
|
DropdownContent,
|
|
14393
14396
|
{
|
|
14394
|
-
className:
|
|
14397
|
+
className: clsx6(
|
|
14395
14398
|
"w-19 gap-0 rounded-lg p-1 shadow-sm",
|
|
14396
14399
|
dropdownContentClassName
|
|
14397
14400
|
),
|
|
@@ -14399,7 +14402,7 @@ function TablePagination({
|
|
|
14399
14402
|
children: perPages.map((item) => /* @__PURE__ */ jsx419(
|
|
14400
14403
|
DropdownItem,
|
|
14401
14404
|
{
|
|
14402
|
-
className:
|
|
14405
|
+
className: clsx6(
|
|
14403
14406
|
value === item && "bg-primary-50 border-primary-300",
|
|
14404
14407
|
"justify-center rounded-sm! border-0",
|
|
14405
14408
|
dropdownItemClassName
|
|
@@ -14453,7 +14456,7 @@ function TablePagination({
|
|
|
14453
14456
|
e.preventDefault();
|
|
14454
14457
|
numberOnClick?.(item);
|
|
14455
14458
|
},
|
|
14456
|
-
className:
|
|
14459
|
+
className: clsx6(
|
|
14457
14460
|
"grid size-9 cursor-pointer place-items-center rounded-lg",
|
|
14458
14461
|
active ? "bg-primary-1000 hover:bg-primary-1000 *:text-white" : "hover:bg-primary-50 *:text-gray-700"
|
|
14459
14462
|
),
|
|
@@ -14669,7 +14672,7 @@ var ButtonNavigator = ({
|
|
|
14669
14672
|
};
|
|
14670
14673
|
|
|
14671
14674
|
// src/components/calendar/partials/calendar-grid.tsx
|
|
14672
|
-
import
|
|
14675
|
+
import clsx9 from "clsx";
|
|
14673
14676
|
|
|
14674
14677
|
// src/components/calendar/partials/button-more.tsx
|
|
14675
14678
|
import { jsx as jsx421, jsxs as jsxs83 } from "react/jsx-runtime";
|
|
@@ -14691,7 +14694,7 @@ function ButtonMore({ count, onClick }) {
|
|
|
14691
14694
|
}
|
|
14692
14695
|
|
|
14693
14696
|
// src/components/calendar/partials/calendar-day-item.tsx
|
|
14694
|
-
import
|
|
14697
|
+
import clsx7 from "clsx";
|
|
14695
14698
|
|
|
14696
14699
|
// src/components/calendar/helpers/create-date-style-helpers.ts
|
|
14697
14700
|
function createDateStyleHelpers({
|
|
@@ -14814,7 +14817,7 @@ function CalendarDayItem({
|
|
|
14814
14817
|
style: styleHelpers.getDayStyle(),
|
|
14815
14818
|
onClick: () => onClick(day),
|
|
14816
14819
|
disabled: isDisabled && isCurrentMonth,
|
|
14817
|
-
className:
|
|
14820
|
+
className: clsx7(
|
|
14818
14821
|
date_size_map[size ?? "md"],
|
|
14819
14822
|
styleHelpers.getCursorClass(),
|
|
14820
14823
|
styleHelpers.getTextColorClass(),
|
|
@@ -14837,7 +14840,7 @@ function CalendarDayItem({
|
|
|
14837
14840
|
/* @__PURE__ */ jsx422(
|
|
14838
14841
|
"h5",
|
|
14839
14842
|
{
|
|
14840
|
-
className:
|
|
14843
|
+
className: clsx7(
|
|
14841
14844
|
"font-metropolis text-xs transition-colors",
|
|
14842
14845
|
variant === "default" && "grid size-8 place-items-center justify-center rounded-full",
|
|
14843
14846
|
//prettier-ignore
|
|
@@ -14875,7 +14878,7 @@ function CalendarDayItem({
|
|
|
14875
14878
|
|
|
14876
14879
|
// src/components/calendar/partials/event-bar.tsx
|
|
14877
14880
|
import { useState as useState10 } from "react";
|
|
14878
|
-
import
|
|
14881
|
+
import clsx8 from "clsx";
|
|
14879
14882
|
import { Fragment as Fragment7, jsx as jsx423, jsxs as jsxs85 } from "react/jsx-runtime";
|
|
14880
14883
|
function EventBar({
|
|
14881
14884
|
segment,
|
|
@@ -14921,7 +14924,7 @@ function EventBar({
|
|
|
14921
14924
|
onMouseEnter: () => setHovered(true),
|
|
14922
14925
|
onMouseLeave: () => setHovered(false),
|
|
14923
14926
|
onMouseMove: (e) => handleMouseMove(e, isMouseEventOnChildren),
|
|
14924
|
-
className:
|
|
14927
|
+
className: clsx8(
|
|
14925
14928
|
"relative mx-0.5 mt-1 flex items-center justify-between gap-3 overflow-hidden rounded p-1 text-[11px] leading-5 font-medium md:p-1.5",
|
|
14926
14929
|
onClick && "cursor-pointer"
|
|
14927
14930
|
),
|
|
@@ -14978,7 +14981,7 @@ function EventBar({
|
|
|
14978
14981
|
}
|
|
14979
14982
|
}
|
|
14980
14983
|
),
|
|
14981
|
-
/* @__PURE__ */ jsx423(Text, { variant: "t3", className:
|
|
14984
|
+
/* @__PURE__ */ jsx423(Text, { variant: "t3", className: clsx8("text-gray-800"), children: segment?.event?.tooltip?.label ?? segment.event.label })
|
|
14982
14985
|
] })
|
|
14983
14986
|
] })
|
|
14984
14987
|
}
|
|
@@ -15014,7 +15017,7 @@ function CalendarGrid({
|
|
|
15014
15017
|
return /* @__PURE__ */ jsx424(
|
|
15015
15018
|
"div",
|
|
15016
15019
|
{
|
|
15017
|
-
className:
|
|
15020
|
+
className: clsx9(
|
|
15018
15021
|
"relative",
|
|
15019
15022
|
variant === "compact" && size === "sm" && "space-y-1"
|
|
15020
15023
|
),
|
|
@@ -15105,7 +15108,7 @@ function CalendarGrid({
|
|
|
15105
15108
|
return /* @__PURE__ */ jsxs86(
|
|
15106
15109
|
"div",
|
|
15107
15110
|
{
|
|
15108
|
-
className:
|
|
15111
|
+
className: clsx9(
|
|
15109
15112
|
"relative",
|
|
15110
15113
|
variant === "default" && "border-b border-gray-300 last:border-b-0!",
|
|
15111
15114
|
//prettier-ignore
|
|
@@ -15115,7 +15118,7 @@ function CalendarGrid({
|
|
|
15115
15118
|
/* @__PURE__ */ jsx424(
|
|
15116
15119
|
"div",
|
|
15117
15120
|
{
|
|
15118
|
-
className:
|
|
15121
|
+
className: clsx9(
|
|
15119
15122
|
"grid w-full grid-cols-7",
|
|
15120
15123
|
variant === "default" && "*:border-r *:border-gray-300 [&>*:nth-last-child(1)]:border-r-0",
|
|
15121
15124
|
//prettier-ignore
|
|
@@ -15403,7 +15406,7 @@ function NavigatorButton({
|
|
|
15403
15406
|
}
|
|
15404
15407
|
|
|
15405
15408
|
// src/components/calendar/partials/days-of-week.tsx
|
|
15406
|
-
import
|
|
15409
|
+
import clsx10 from "clsx";
|
|
15407
15410
|
import { Fragment as Fragment8, jsx as jsx427, jsxs as jsxs88 } from "react/jsx-runtime";
|
|
15408
15411
|
var day_of_week_size = {
|
|
15409
15412
|
sm: "t2",
|
|
@@ -15421,7 +15424,7 @@ function DaysOfWeek({
|
|
|
15421
15424
|
return /* @__PURE__ */ jsxs88(
|
|
15422
15425
|
"div",
|
|
15423
15426
|
{
|
|
15424
|
-
className:
|
|
15427
|
+
className: clsx10(
|
|
15425
15428
|
"grid justify-items-center",
|
|
15426
15429
|
variant === "compact" && "calendar-cols mb-3 gap-x-1 *:text-center!",
|
|
15427
15430
|
variant === "default" && "w-full bg-gray-100 *:p-3 *:w-full *:text-start! *:border-r *:border-gray-300 *:last:border-r-0",
|
|
@@ -15442,7 +15445,7 @@ function DaysOfWeek({
|
|
|
15442
15445
|
as: "h5",
|
|
15443
15446
|
weight: variant === "compact" ? "medium" : "semibold",
|
|
15444
15447
|
value: day,
|
|
15445
|
-
className:
|
|
15448
|
+
className: clsx10(
|
|
15446
15449
|
variant === "compact" && "text-gray-600!",
|
|
15447
15450
|
variant === "default" && "text-gray-900! uppercase"
|
|
15448
15451
|
),
|
|
@@ -15456,7 +15459,7 @@ function DaysOfWeek({
|
|
|
15456
15459
|
}
|
|
15457
15460
|
|
|
15458
15461
|
// src/components/calendar/calendar.tsx
|
|
15459
|
-
import
|
|
15462
|
+
import clsx11 from "clsx";
|
|
15460
15463
|
|
|
15461
15464
|
// src/components/calendar/constants.tsx
|
|
15462
15465
|
var typeOptions = [
|
|
@@ -15643,7 +15646,7 @@ var Calendar2 = ({
|
|
|
15643
15646
|
setSelectedType(type);
|
|
15644
15647
|
}
|
|
15645
15648
|
}, [type]);
|
|
15646
|
-
return /* @__PURE__ */ jsx428(Fragment9, { children: /* @__PURE__ */ jsxs89("div", { className:
|
|
15649
|
+
return /* @__PURE__ */ jsx428(Fragment9, { children: /* @__PURE__ */ jsxs89("div", { className: clsx11(variant === "default" && "flex flex-col gap-2"), children: [
|
|
15647
15650
|
variant === "default" && /* @__PURE__ */ jsxs89("div", { className: "flex items-center justify-between", children: [
|
|
15648
15651
|
/* @__PURE__ */ jsxs89("div", { className: "flex items-center gap-6", children: [
|
|
15649
15652
|
/* @__PURE__ */ jsxs89("div", { className: "*:cursor-pointer", children: [
|
|
@@ -15716,7 +15719,7 @@ var Calendar2 = ({
|
|
|
15716
15719
|
setSelectedType(option.value);
|
|
15717
15720
|
onTypeChange?.(option.value);
|
|
15718
15721
|
},
|
|
15719
|
-
className:
|
|
15722
|
+
className: clsx11(
|
|
15720
15723
|
(selectedType === option.value || index === selectedTypeIndex) && "bg-primary-50!"
|
|
15721
15724
|
),
|
|
15722
15725
|
children: /* @__PURE__ */ jsx428(Text, { className: "text-gray-900", children: option.label })
|
|
@@ -15920,7 +15923,7 @@ var parseMonthName = (monthStr) => {
|
|
|
15920
15923
|
};
|
|
15921
15924
|
|
|
15922
15925
|
// src/components/date-picker/date-picker.tsx
|
|
15923
|
-
import
|
|
15926
|
+
import clsx12 from "clsx";
|
|
15924
15927
|
import { jsx as jsx429, jsxs as jsxs90 } from "react/jsx-runtime";
|
|
15925
15928
|
var DatePicker = ({
|
|
15926
15929
|
format = "DD-MM-YYYY",
|
|
@@ -15942,7 +15945,9 @@ var DatePicker = ({
|
|
|
15942
15945
|
size = "md",
|
|
15943
15946
|
showController = true,
|
|
15944
15947
|
align = "start",
|
|
15945
|
-
containerClassName
|
|
15948
|
+
containerClassName,
|
|
15949
|
+
placeholder,
|
|
15950
|
+
isClearable = false
|
|
15946
15951
|
}) => {
|
|
15947
15952
|
const [selectedDate, setSelectedDate] = useState12(
|
|
15948
15953
|
controlledValue || null
|
|
@@ -16172,7 +16177,7 @@ var DatePicker = ({
|
|
|
16172
16177
|
"div",
|
|
16173
16178
|
{
|
|
16174
16179
|
ref: containerRef,
|
|
16175
|
-
className:
|
|
16180
|
+
className: clsx12("relative flex max-w-sm flex-col", containerClassName),
|
|
16176
16181
|
children: /* @__PURE__ */ jsxs90(
|
|
16177
16182
|
Dropdown,
|
|
16178
16183
|
{
|
|
@@ -16185,18 +16190,40 @@ var DatePicker = ({
|
|
|
16185
16190
|
}
|
|
16186
16191
|
},
|
|
16187
16192
|
children: [
|
|
16188
|
-
/* @__PURE__ */ jsx429(DropdownTrigger, { asChild:
|
|
16193
|
+
/* @__PURE__ */ jsx429(DropdownTrigger, { asChild: true, children: Boolean(trigger) === false ? /* @__PURE__ */ jsx429(
|
|
16189
16194
|
Input,
|
|
16190
16195
|
{
|
|
16191
|
-
type: "text",
|
|
16192
16196
|
mergedAddon: true,
|
|
16197
|
+
type: "text",
|
|
16193
16198
|
className: "pl-0",
|
|
16194
|
-
leftAddonClassName: "pr-1!",
|
|
16195
|
-
leftAddon: /* @__PURE__ */ jsx429(Icon_default, { name: "calendar", className: "text-gray-900" }),
|
|
16196
|
-
placeholder: mode === "range" ? `${formatConfig.placeholder} - ${formatConfig.placeholder}` : formatConfig.placeholder,
|
|
16199
|
+
leftAddonClassName: "pr-1! shrink-0",
|
|
16197
16200
|
onChange: handleInputChange2,
|
|
16198
16201
|
value: inputValue,
|
|
16199
|
-
readOnly: mode === "range"
|
|
16202
|
+
readOnly: mode === "range",
|
|
16203
|
+
leftAddon: /* @__PURE__ */ jsx429(Icon_default, { name: "calendar", className: "text-gray-900", size: 24 }),
|
|
16204
|
+
rightAddonClassName: "shrink-0",
|
|
16205
|
+
rightAddon: isClearable && inputValue && /* @__PURE__ */ jsx429(
|
|
16206
|
+
"button",
|
|
16207
|
+
{
|
|
16208
|
+
className: "shrink-0 cursor-pointer",
|
|
16209
|
+
onClick: (e) => {
|
|
16210
|
+
e.preventDefault();
|
|
16211
|
+
e.stopPropagation();
|
|
16212
|
+
setInputValue("");
|
|
16213
|
+
controlledOnRangeChange?.({ start: null, end: null });
|
|
16214
|
+
controlledOnChange?.(null);
|
|
16215
|
+
},
|
|
16216
|
+
children: /* @__PURE__ */ jsx429(
|
|
16217
|
+
Icon_default,
|
|
16218
|
+
{
|
|
16219
|
+
name: "times-circle",
|
|
16220
|
+
size: 20,
|
|
16221
|
+
className: "shrink-0 text-gray-900"
|
|
16222
|
+
}
|
|
16223
|
+
)
|
|
16224
|
+
}
|
|
16225
|
+
),
|
|
16226
|
+
placeholder: placeholder !== void 0 ? placeholder : mode === "range" ? `${formatConfig.placeholder} - ${formatConfig.placeholder}` : formatConfig.placeholder
|
|
16200
16227
|
}
|
|
16201
16228
|
) : trigger }),
|
|
16202
16229
|
/* @__PURE__ */ jsx429(
|
|
@@ -16204,7 +16231,7 @@ var DatePicker = ({
|
|
|
16204
16231
|
{
|
|
16205
16232
|
align,
|
|
16206
16233
|
sideOffset: 5,
|
|
16207
|
-
className:
|
|
16234
|
+
className: clsx12("z-10 overflow-hidden p-0", wrapperClassName),
|
|
16208
16235
|
children: /* @__PURE__ */ jsx429("div", { className: "top-full z-10", children: mode === "single" ? /* @__PURE__ */ jsx429(
|
|
16209
16236
|
Calendar2,
|
|
16210
16237
|
{
|
|
@@ -16630,7 +16657,7 @@ var Switch = ({
|
|
|
16630
16657
|
};
|
|
16631
16658
|
|
|
16632
16659
|
// src/components/toast/toast-card.tsx
|
|
16633
|
-
import
|
|
16660
|
+
import clsx13 from "clsx";
|
|
16634
16661
|
|
|
16635
16662
|
// src/components/toast/toast-variants.ts
|
|
16636
16663
|
import { cva as cva11 } from "class-variance-authority";
|
|
@@ -16684,7 +16711,7 @@ function ToastCard({
|
|
|
16684
16711
|
return /* @__PURE__ */ jsxs92(
|
|
16685
16712
|
"div",
|
|
16686
16713
|
{
|
|
16687
|
-
className:
|
|
16714
|
+
className: clsx13(
|
|
16688
16715
|
"flex max-w-81.75 min-w-81.75 items-center justify-between rounded-lg px-3 py-2 shadow-[0px_2px_10px_0px_#6B728033]",
|
|
16689
16716
|
variant === "outline" && "border border-gray-500",
|
|
16690
16717
|
variant === "outline" && color !== "primary" && color !== "secondary" && "bg-white!",
|
|
@@ -16699,7 +16726,7 @@ function ToastCard({
|
|
|
16699
16726
|
{
|
|
16700
16727
|
name: icon,
|
|
16701
16728
|
size: iconSize,
|
|
16702
|
-
className:
|
|
16729
|
+
className: clsx13(
|
|
16703
16730
|
variant === "outline" && color === "primary" && "text-primary-1000!",
|
|
16704
16731
|
variant === "outline" && color === "secondary" && "text-white!",
|
|
16705
16732
|
ToastVariants({ text: color })
|
|
@@ -16709,7 +16736,7 @@ function ToastCard({
|
|
|
16709
16736
|
/* @__PURE__ */ jsxs92(
|
|
16710
16737
|
"div",
|
|
16711
16738
|
{
|
|
16712
|
-
className:
|
|
16739
|
+
className: clsx13(
|
|
16713
16740
|
"flex flex-col",
|
|
16714
16741
|
variant === "outline" && color === "primary" && "text-primary-1000!",
|
|
16715
16742
|
variant === "outline" && color === "secondary" && "text-white!",
|
|
@@ -16737,7 +16764,7 @@ function ToastCard({
|
|
|
16737
16764
|
{
|
|
16738
16765
|
name: "times",
|
|
16739
16766
|
size: 20,
|
|
16740
|
-
className:
|
|
16767
|
+
className: clsx13(
|
|
16741
16768
|
ToastVariants({ text: color }),
|
|
16742
16769
|
variant === "outline" && color === "primary" && "text-primary-1000!",
|
|
16743
16770
|
variant === "outline" && color === "secondary" && "text-white!"
|
|
@@ -16752,7 +16779,7 @@ function ToastCard({
|
|
|
16752
16779
|
|
|
16753
16780
|
// src/components/toast/toast-provider.tsx
|
|
16754
16781
|
import { useState as useState14, useCallback as useCallback2 } from "react";
|
|
16755
|
-
import
|
|
16782
|
+
import clsx14 from "clsx";
|
|
16756
16783
|
|
|
16757
16784
|
// src/components/toast/toast-context.ts
|
|
16758
16785
|
import { createContext as createContext4 } from "react";
|
|
@@ -16804,7 +16831,7 @@ function ToastProvider({
|
|
|
16804
16831
|
/* @__PURE__ */ jsx434(
|
|
16805
16832
|
"div",
|
|
16806
16833
|
{
|
|
16807
|
-
className:
|
|
16834
|
+
className: clsx14(
|
|
16808
16835
|
"fixed z-50 flex flex-col gap-3 duration-300",
|
|
16809
16836
|
position === "top-right" && "top-4 right-4",
|
|
16810
16837
|
position === "top-left" && "top-4 left-4",
|
|
@@ -16921,7 +16948,7 @@ function RoundedSpinner({
|
|
|
16921
16948
|
}
|
|
16922
16949
|
|
|
16923
16950
|
// src/components/select/select.tsx
|
|
16924
|
-
import
|
|
16951
|
+
import clsx15 from "clsx";
|
|
16925
16952
|
|
|
16926
16953
|
// src/components/select/selectSize.ts
|
|
16927
16954
|
import { cva as cva12 } from "class-variance-authority";
|
|
@@ -17342,7 +17369,7 @@ function Select({
|
|
|
17342
17369
|
onLoadMore !== void 0 && /* @__PURE__ */ jsx436(
|
|
17343
17370
|
"div",
|
|
17344
17371
|
{
|
|
17345
|
-
className:
|
|
17372
|
+
className: clsx15(
|
|
17346
17373
|
"flex h-5 items-center justify-center py-2 duration-300"
|
|
17347
17374
|
),
|
|
17348
17375
|
children: isLoadingMore === true && /* @__PURE__ */ jsx436(RoundedSpinner, { size: 20, color: "primary" })
|
|
@@ -17903,7 +17930,7 @@ TabsContent.displayName = "TabsContent";
|
|
|
17903
17930
|
|
|
17904
17931
|
// src/components/button-group/button-group.tsx
|
|
17905
17932
|
import { createContext as createContext6, useContext as useContext6 } from "react";
|
|
17906
|
-
import
|
|
17933
|
+
import clsx16 from "clsx";
|
|
17907
17934
|
import { jsx as jsx439 } from "react/jsx-runtime";
|
|
17908
17935
|
var ButtonGroupContext = createContext6(null);
|
|
17909
17936
|
var ButtonGroup = ({
|
|
@@ -17916,7 +17943,7 @@ var ButtonGroup = ({
|
|
|
17916
17943
|
return /* @__PURE__ */ jsx439(ButtonGroupContext.Provider, { value: { size, color, variant, direction }, children: /* @__PURE__ */ jsx439(
|
|
17917
17944
|
"div",
|
|
17918
17945
|
{
|
|
17919
|
-
className:
|
|
17946
|
+
className: clsx16(
|
|
17920
17947
|
"flex *:rounded-none",
|
|
17921
17948
|
direction === "horizontal" ? "flex-row items-center *:first:rounded-tl-lg *:first:rounded-bl-lg *:last:rounded-tr-lg *:last:rounded-br-lg" : "flex-col items-stretch *:first:rounded-tl-lg *:first:rounded-tr-lg *:last:rounded-br-lg *:last:rounded-bl-lg"
|
|
17922
17949
|
),
|
|
@@ -17937,7 +17964,7 @@ var ButtonGroupItem = ({
|
|
|
17937
17964
|
const isTertiary = variant === "tertiary";
|
|
17938
17965
|
const isVertical = direction === "vertical";
|
|
17939
17966
|
const isHorizontal = direction === "horizontal";
|
|
17940
|
-
const borderDirectionClass =
|
|
17967
|
+
const borderDirectionClass = clsx16(
|
|
17941
17968
|
isHorizontal && "border-l-0 first:border-l",
|
|
17942
17969
|
isVertical && "border-t-0 first:border-t"
|
|
17943
17970
|
);
|
|
@@ -17958,8 +17985,8 @@ var ButtonGroupItem = ({
|
|
|
17958
17985
|
size: context?.size,
|
|
17959
17986
|
color: color ?? context?.color,
|
|
17960
17987
|
variant: context?.variant,
|
|
17961
|
-
className:
|
|
17962
|
-
isDefault &&
|
|
17988
|
+
className: clsx16(
|
|
17989
|
+
isDefault && clsx16(
|
|
17963
17990
|
isHorizontal && "border-r border-white last:border-r-0",
|
|
17964
17991
|
isVertical && "border-b border-white last:border-b-0"
|
|
17965
17992
|
),
|
|
@@ -17992,7 +18019,7 @@ import { EditorContent, useEditor } from "@tiptap/react";
|
|
|
17992
18019
|
import StarterKit from "@tiptap/starter-kit";
|
|
17993
18020
|
import { dracula } from "@uiw/codemirror-theme-dracula";
|
|
17994
18021
|
import CodeMirror from "@uiw/react-codemirror";
|
|
17995
|
-
import
|
|
18022
|
+
import clsx22 from "clsx";
|
|
17996
18023
|
import { useEffect as useEffect21, useState as useState24 } from "react";
|
|
17997
18024
|
|
|
17998
18025
|
// node_modules/orderedmap/dist/index.js
|
|
@@ -34961,7 +34988,7 @@ function AdvanceGroup({
|
|
|
34961
34988
|
|
|
34962
34989
|
// src/components/text-editor/partials/alignment-group.tsx
|
|
34963
34990
|
import { useEditorState } from "@tiptap/react";
|
|
34964
|
-
import
|
|
34991
|
+
import clsx17 from "clsx";
|
|
34965
34992
|
import { Fragment as Fragment12, jsx as jsx443, jsxs as jsxs97 } from "react/jsx-runtime";
|
|
34966
34993
|
function AlignmentGroup({
|
|
34967
34994
|
editor,
|
|
@@ -35019,7 +35046,7 @@ function AlignmentGroup({
|
|
|
35019
35046
|
DropdownItem,
|
|
35020
35047
|
{
|
|
35021
35048
|
onClick: () => editor.chain().focus().setTextAlign(align.align).run(),
|
|
35022
|
-
className:
|
|
35049
|
+
className: clsx17(
|
|
35023
35050
|
"rounded-md border-transparent py-1",
|
|
35024
35051
|
activeState[align.align] && "bg-primary-50 border-primary-300"
|
|
35025
35052
|
),
|
|
@@ -35058,11 +35085,11 @@ function AlignmentGroup({
|
|
|
35058
35085
|
|
|
35059
35086
|
// src/components/text-editor/partials/formatting-group.tsx
|
|
35060
35087
|
import { useEditorState as useEditorState2 } from "@tiptap/react";
|
|
35061
|
-
import
|
|
35088
|
+
import clsx19 from "clsx";
|
|
35062
35089
|
import { useEffect as useEffect17, useState as useState19 } from "react";
|
|
35063
35090
|
|
|
35064
35091
|
// src/components/text-editor/partials/color-picker-button.tsx
|
|
35065
|
-
import
|
|
35092
|
+
import clsx18 from "clsx";
|
|
35066
35093
|
import { jsx as jsx444, jsxs as jsxs98 } from "react/jsx-runtime";
|
|
35067
35094
|
function ColorPickerButton({
|
|
35068
35095
|
id,
|
|
@@ -35075,7 +35102,7 @@ function ColorPickerButton({
|
|
|
35075
35102
|
/* @__PURE__ */ jsx444(
|
|
35076
35103
|
"div",
|
|
35077
35104
|
{
|
|
35078
|
-
className:
|
|
35105
|
+
className: clsx18(
|
|
35079
35106
|
"flex items-center gap-1 rounded-lg border border-gray-300 p-2",
|
|
35080
35107
|
disabled && "opacity-50"
|
|
35081
35108
|
),
|
|
@@ -35202,7 +35229,7 @@ function FormattingGroup({
|
|
|
35202
35229
|
fontSizes.map((size, index) => /* @__PURE__ */ jsx445(
|
|
35203
35230
|
DropdownItem,
|
|
35204
35231
|
{
|
|
35205
|
-
className:
|
|
35232
|
+
className: clsx19(
|
|
35206
35233
|
"flex justify-start rounded-md border-transparent py-1",
|
|
35207
35234
|
displayFontSize === size && "bg-primary-50 border-primary-300"
|
|
35208
35235
|
),
|
|
@@ -35228,7 +35255,7 @@ function FormattingGroup({
|
|
|
35228
35255
|
"div",
|
|
35229
35256
|
{
|
|
35230
35257
|
title: "Heading",
|
|
35231
|
-
className:
|
|
35258
|
+
className: clsx19(
|
|
35232
35259
|
"flex items-center gap-1 rounded-lg border border-gray-300 p-2",
|
|
35233
35260
|
(disabled || activeState.isInYoutube || activeState.isInImage) && "opacity-50"
|
|
35234
35261
|
),
|
|
@@ -35247,7 +35274,7 @@ function FormattingGroup({
|
|
|
35247
35274
|
{
|
|
35248
35275
|
name: "angle-down-small",
|
|
35249
35276
|
size: 18,
|
|
35250
|
-
className:
|
|
35277
|
+
className: clsx19(activeState.activeHeading && "ml-1")
|
|
35251
35278
|
}
|
|
35252
35279
|
)
|
|
35253
35280
|
]
|
|
@@ -35259,7 +35286,7 @@ function FormattingGroup({
|
|
|
35259
35286
|
/* @__PURE__ */ jsx445(
|
|
35260
35287
|
DropdownItem,
|
|
35261
35288
|
{
|
|
35262
|
-
className:
|
|
35289
|
+
className: clsx19(
|
|
35263
35290
|
"rounded-md border-transparent py-1",
|
|
35264
35291
|
activeState.activeParagraph && "bg-primary-50 border-primary-300"
|
|
35265
35292
|
),
|
|
@@ -35272,7 +35299,7 @@ function FormattingGroup({
|
|
|
35272
35299
|
headings.map((head, index) => /* @__PURE__ */ jsx445(
|
|
35273
35300
|
DropdownItem,
|
|
35274
35301
|
{
|
|
35275
|
-
className:
|
|
35302
|
+
className: clsx19(
|
|
35276
35303
|
"rounded-md border-transparent py-1",
|
|
35277
35304
|
activeState.activeHeading === head.level && "bg-primary-50 border-primary-300"
|
|
35278
35305
|
),
|
|
@@ -35328,7 +35355,7 @@ function FormattingGroup({
|
|
|
35328
35355
|
"div",
|
|
35329
35356
|
{
|
|
35330
35357
|
title: "Line Height",
|
|
35331
|
-
className:
|
|
35358
|
+
className: clsx19(
|
|
35332
35359
|
"flex items-center gap-1 rounded-lg border border-gray-300 p-2",
|
|
35333
35360
|
(disabled || activeState.isInYoutube || activeState.isInImage) && "opacity-50"
|
|
35334
35361
|
),
|
|
@@ -35384,7 +35411,7 @@ function FormattingGroup({
|
|
|
35384
35411
|
lineHeights.map((size, index) => /* @__PURE__ */ jsx445(
|
|
35385
35412
|
DropdownItem,
|
|
35386
35413
|
{
|
|
35387
|
-
className:
|
|
35414
|
+
className: clsx19(
|
|
35388
35415
|
"flex justify-center rounded-md border-transparent py-1",
|
|
35389
35416
|
displayLineHeight === size && "bg-primary-50 border-primary-300"
|
|
35390
35417
|
),
|
|
@@ -35546,7 +35573,7 @@ import { useState as useState23 } from "react";
|
|
|
35546
35573
|
|
|
35547
35574
|
// src/components/kbd/kbd.tsx
|
|
35548
35575
|
import "react";
|
|
35549
|
-
import
|
|
35576
|
+
import clsx20 from "clsx";
|
|
35550
35577
|
|
|
35551
35578
|
// src/components/kbd/kbd-variants.ts
|
|
35552
35579
|
import { cva as cva13 } from "class-variance-authority";
|
|
@@ -35682,7 +35709,7 @@ function Kbd({ size, variant, color, className, ...props }) {
|
|
|
35682
35709
|
return /* @__PURE__ */ jsx447(
|
|
35683
35710
|
"kbd",
|
|
35684
35711
|
{
|
|
35685
|
-
className:
|
|
35712
|
+
className: clsx20(kbdVariants({ size, variant, color }), className),
|
|
35686
35713
|
...props
|
|
35687
35714
|
}
|
|
35688
35715
|
);
|
|
@@ -36478,7 +36505,7 @@ function InsertGroup({
|
|
|
36478
36505
|
|
|
36479
36506
|
// src/components/text-editor/partials/table-group.tsx
|
|
36480
36507
|
import { useEditorState as useEditorState5 } from "@tiptap/react";
|
|
36481
|
-
import
|
|
36508
|
+
import clsx21 from "clsx";
|
|
36482
36509
|
import { jsx as jsx451, jsxs as jsxs104 } from "react/jsx-runtime";
|
|
36483
36510
|
function TableGroup({
|
|
36484
36511
|
editor,
|
|
@@ -36583,7 +36610,7 @@ function TableGroup({
|
|
|
36583
36610
|
"div",
|
|
36584
36611
|
{
|
|
36585
36612
|
title: "Heading",
|
|
36586
|
-
className:
|
|
36613
|
+
className: clsx21(
|
|
36587
36614
|
"flex items-center gap-1 rounded-lg border border-gray-300 p-2",
|
|
36588
36615
|
activeState.isInTable && "bg-primary-1000",
|
|
36589
36616
|
(disabled || activeState.isInYoutube || activeState.isInImage) && "opacity-50"
|
|
@@ -36594,7 +36621,7 @@ function TableGroup({
|
|
|
36594
36621
|
{
|
|
36595
36622
|
name: "table",
|
|
36596
36623
|
size: 18,
|
|
36597
|
-
className:
|
|
36624
|
+
className: clsx21(
|
|
36598
36625
|
activeState.isInTable ? "text-white" : "text-gray-900"
|
|
36599
36626
|
)
|
|
36600
36627
|
}
|
|
@@ -36604,7 +36631,7 @@ function TableGroup({
|
|
|
36604
36631
|
{
|
|
36605
36632
|
name: "angle-down-small",
|
|
36606
36633
|
size: 17,
|
|
36607
|
-
className:
|
|
36634
|
+
className: clsx21(
|
|
36608
36635
|
activeState.isInTable ? "text-white" : "text-gray-900"
|
|
36609
36636
|
)
|
|
36610
36637
|
}
|
|
@@ -36626,7 +36653,7 @@ function TableGroup({
|
|
|
36626
36653
|
{
|
|
36627
36654
|
onClick: () => action.onClick(),
|
|
36628
36655
|
disabled: Boolean(action.disabled) || action.requiresTable && !activeState.isInTable,
|
|
36629
|
-
className:
|
|
36656
|
+
className: clsx21(
|
|
36630
36657
|
"rounded-md border-transparent py-1 disabled:opacity-50",
|
|
36631
36658
|
Boolean(action.active) && "bg-primary-50 border-primary-300"
|
|
36632
36659
|
),
|
|
@@ -36643,7 +36670,7 @@ function TableGroup({
|
|
|
36643
36670
|
{
|
|
36644
36671
|
onClick: () => action.onClick(),
|
|
36645
36672
|
disabled: Boolean(action.disabled) || action.requiresTable && !activeState.isInTable,
|
|
36646
|
-
className:
|
|
36673
|
+
className: clsx21(
|
|
36647
36674
|
"rounded-md border-transparent py-1 disabled:opacity-50",
|
|
36648
36675
|
Boolean(action.active) && "bg-primary-50 border-primary-300"
|
|
36649
36676
|
),
|
|
@@ -36660,7 +36687,7 @@ function TableGroup({
|
|
|
36660
36687
|
{
|
|
36661
36688
|
onClick: () => action.onClick(),
|
|
36662
36689
|
disabled: Boolean(action.disabled) || action.requiresTable && !activeState.isInTable,
|
|
36663
|
-
className:
|
|
36690
|
+
className: clsx21(
|
|
36664
36691
|
"rounded-md border-transparent py-1 disabled:opacity-50",
|
|
36665
36692
|
Boolean(action.active) && "bg-primary-50 border-primary-300"
|
|
36666
36693
|
),
|
|
@@ -36794,7 +36821,7 @@ function TextEditor({
|
|
|
36794
36821
|
children: /* @__PURE__ */ jsxs105(
|
|
36795
36822
|
"div",
|
|
36796
36823
|
{
|
|
36797
|
-
className:
|
|
36824
|
+
className: clsx22(
|
|
36798
36825
|
"relative flex w-full flex-col rounded-xl border",
|
|
36799
36826
|
errorMessages !== void 0 ? "border-danger-500" : "border-gray-300"
|
|
36800
36827
|
),
|
|
@@ -36802,7 +36829,7 @@ function TextEditor({
|
|
|
36802
36829
|
/* @__PURE__ */ jsx452(
|
|
36803
36830
|
"div",
|
|
36804
36831
|
{
|
|
36805
|
-
className:
|
|
36832
|
+
className: clsx22(
|
|
36806
36833
|
"sticky top-0 z-10 rounded-t-xl bg-white",
|
|
36807
36834
|
toolbarClassName
|
|
36808
36835
|
),
|
|
@@ -36848,7 +36875,7 @@ function TextEditor({
|
|
|
36848
36875
|
DragHandleComponent,
|
|
36849
36876
|
{
|
|
36850
36877
|
editor,
|
|
36851
|
-
className:
|
|
36878
|
+
className: clsx22("relative z-20", dragHandleClassName),
|
|
36852
36879
|
...dragHandleProps,
|
|
36853
36880
|
children: /* @__PURE__ */ jsx452("div", { className: "custom-drag-handle absolute left-0" })
|
|
36854
36881
|
}
|
|
@@ -36860,7 +36887,7 @@ function TextEditor({
|
|
|
36860
36887
|
extensions: [html()],
|
|
36861
36888
|
onChange: (value2) => setHtmlValue(value2),
|
|
36862
36889
|
theme: dracula,
|
|
36863
|
-
className:
|
|
36890
|
+
className: clsx22(isHtmlMode ? "block" : "hidden")
|
|
36864
36891
|
}
|
|
36865
36892
|
),
|
|
36866
36893
|
/* @__PURE__ */ jsx452(
|
|
@@ -36869,7 +36896,7 @@ function TextEditor({
|
|
|
36869
36896
|
placeholder,
|
|
36870
36897
|
disabled,
|
|
36871
36898
|
editor,
|
|
36872
|
-
className:
|
|
36899
|
+
className: clsx22(
|
|
36873
36900
|
"*:min-h-100 *:translate-y-1 *:px-5 *:py-2 *:outline-none",
|
|
36874
36901
|
textEditorClassName,
|
|
36875
36902
|
isHtmlMode && "hidden"
|