@chekinapp/ui 0.0.6 → 0.0.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/dist/index.cjs +192 -178
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +192 -178
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -9043,7 +9043,7 @@ var DatePicker = React30.forwardRef(
|
|
|
9043
9043
|
setIsOpen(false);
|
|
9044
9044
|
}
|
|
9045
9045
|
}, [isBlocked]);
|
|
9046
|
-
return /* @__PURE__ */ jsxs78("div", { className: cn("relative w-full max-w-[
|
|
9046
|
+
return /* @__PURE__ */ jsxs78("div", { className: cn("relative w-full max-w-[var(--max-field-width)]", className), children: [
|
|
9047
9047
|
name && /* @__PURE__ */ jsx121(
|
|
9048
9048
|
"input",
|
|
9049
9049
|
{
|
|
@@ -9307,7 +9307,7 @@ var AirbnbInput = React31.forwardRef(
|
|
|
9307
9307
|
setIsFocused(false);
|
|
9308
9308
|
onBlur?.(event);
|
|
9309
9309
|
};
|
|
9310
|
-
return /* @__PURE__ */ jsx123("div", { className: cn("w-full", wrapperClassName), children: /* @__PURE__ */ jsx123(
|
|
9310
|
+
return /* @__PURE__ */ jsx123("div", { className: cn("w-full max-w-[var(--max-field-width)]", wrapperClassName), children: /* @__PURE__ */ jsx123(
|
|
9311
9311
|
FieldTrigger,
|
|
9312
9312
|
{
|
|
9313
9313
|
as: "div",
|
|
@@ -10365,109 +10365,116 @@ var AirbnbSelect = React36.forwardRef(function AirbnbSelect2({
|
|
|
10365
10365
|
handleMobileOpenChange(false);
|
|
10366
10366
|
}
|
|
10367
10367
|
};
|
|
10368
|
-
return /* @__PURE__ */ jsxs83(
|
|
10369
|
-
|
|
10370
|
-
|
|
10371
|
-
|
|
10372
|
-
|
|
10373
|
-
|
|
10374
|
-
|
|
10375
|
-
|
|
10376
|
-
|
|
10377
|
-
|
|
10378
|
-
|
|
10379
|
-
|
|
10380
|
-
|
|
10381
|
-
|
|
10382
|
-
|
|
10383
|
-
|
|
10384
|
-
|
|
10385
|
-
|
|
10386
|
-
|
|
10387
|
-
|
|
10388
|
-
|
|
10389
|
-
|
|
10390
|
-
|
|
10391
|
-
|
|
10392
|
-
|
|
10393
|
-
|
|
10394
|
-
|
|
10395
|
-
|
|
10396
|
-
|
|
10397
|
-
|
|
10398
|
-
|
|
10399
|
-
|
|
10400
|
-
|
|
10401
|
-
|
|
10402
|
-
|
|
10403
|
-
|
|
10404
|
-
|
|
10405
|
-
|
|
10406
|
-
|
|
10407
|
-
|
|
10408
|
-
|
|
10409
|
-
|
|
10410
|
-
|
|
10411
|
-
|
|
10412
|
-
|
|
10413
|
-
|
|
10414
|
-
|
|
10415
|
-
|
|
10416
|
-
|
|
10417
|
-
|
|
10418
|
-
|
|
10419
|
-
|
|
10420
|
-
|
|
10421
|
-
|
|
10422
|
-
|
|
10423
|
-
|
|
10424
|
-
|
|
10425
|
-
|
|
10426
|
-
|
|
10427
|
-
|
|
10428
|
-
|
|
10429
|
-
|
|
10430
|
-
|
|
10431
|
-
|
|
10432
|
-
|
|
10433
|
-
|
|
10434
|
-
|
|
10435
|
-
|
|
10436
|
-
|
|
10437
|
-
|
|
10438
|
-
|
|
10439
|
-
|
|
10440
|
-
|
|
10441
|
-
|
|
10442
|
-
|
|
10443
|
-
|
|
10444
|
-
|
|
10445
|
-
|
|
10446
|
-
|
|
10447
|
-
|
|
10448
|
-
|
|
10449
|
-
|
|
10450
|
-
|
|
10451
|
-
|
|
10452
|
-
|
|
10453
|
-
|
|
10454
|
-
|
|
10455
|
-
|
|
10456
|
-
|
|
10457
|
-
|
|
10458
|
-
|
|
10459
|
-
|
|
10460
|
-
|
|
10461
|
-
|
|
10462
|
-
|
|
10463
|
-
|
|
10464
|
-
|
|
10465
|
-
|
|
10466
|
-
|
|
10467
|
-
|
|
10468
|
-
|
|
10469
|
-
|
|
10470
|
-
|
|
10368
|
+
return /* @__PURE__ */ jsxs83(
|
|
10369
|
+
"div",
|
|
10370
|
+
{
|
|
10371
|
+
ref: containerRef,
|
|
10372
|
+
className: cn("relative w-full max-w-[var(--max-field-width)]", className),
|
|
10373
|
+
children: [
|
|
10374
|
+
name && /* @__PURE__ */ jsx129("input", { type: "hidden", name, value: value ? String(value.value) : "" }),
|
|
10375
|
+
renderTrigger ? renderTrigger({
|
|
10376
|
+
id: triggerId,
|
|
10377
|
+
open: isOpen,
|
|
10378
|
+
variant,
|
|
10379
|
+
label,
|
|
10380
|
+
topLabel,
|
|
10381
|
+
helperText,
|
|
10382
|
+
value,
|
|
10383
|
+
valueLabel,
|
|
10384
|
+
disabled: isBlocked,
|
|
10385
|
+
loading,
|
|
10386
|
+
optional,
|
|
10387
|
+
tooltip,
|
|
10388
|
+
error,
|
|
10389
|
+
invalid,
|
|
10390
|
+
listboxId,
|
|
10391
|
+
describedBy,
|
|
10392
|
+
triggerRef: combinedRef,
|
|
10393
|
+
onClick: handleTriggerClick,
|
|
10394
|
+
onKeyDown: handleRootTriggerKeyDown
|
|
10395
|
+
}) : /* @__PURE__ */ jsx129(
|
|
10396
|
+
SelectTrigger2,
|
|
10397
|
+
{
|
|
10398
|
+
id: triggerId,
|
|
10399
|
+
ref: combinedRef,
|
|
10400
|
+
open: isOpen,
|
|
10401
|
+
variant,
|
|
10402
|
+
label,
|
|
10403
|
+
topLabel,
|
|
10404
|
+
helperText,
|
|
10405
|
+
valueLabel,
|
|
10406
|
+
disabled,
|
|
10407
|
+
loading,
|
|
10408
|
+
optional,
|
|
10409
|
+
tooltip,
|
|
10410
|
+
error: triggerError,
|
|
10411
|
+
hideErrorMessage,
|
|
10412
|
+
labelId,
|
|
10413
|
+
valueId,
|
|
10414
|
+
helperTextId,
|
|
10415
|
+
errorId: error ? errorId : void 0,
|
|
10416
|
+
listboxId,
|
|
10417
|
+
describedBy,
|
|
10418
|
+
onClick: handleTriggerClick,
|
|
10419
|
+
onKeyDown: handleRootTriggerKeyDown
|
|
10420
|
+
}
|
|
10421
|
+
),
|
|
10422
|
+
isMobile ? /* @__PURE__ */ jsx129(
|
|
10423
|
+
SelectMobileContent,
|
|
10424
|
+
{
|
|
10425
|
+
open: isOpen,
|
|
10426
|
+
onOpenChange: handleMobileOpenChange,
|
|
10427
|
+
onClose: () => handleMobileOpenChange(false),
|
|
10428
|
+
listboxId,
|
|
10429
|
+
labelId,
|
|
10430
|
+
label,
|
|
10431
|
+
mobileTitle,
|
|
10432
|
+
doneLabel,
|
|
10433
|
+
errorId: describedErrorId,
|
|
10434
|
+
options,
|
|
10435
|
+
disabled: isBlocked,
|
|
10436
|
+
menuClassName,
|
|
10437
|
+
scrollTop: mobileScrollTop,
|
|
10438
|
+
activeIndex: activeMobileIndex,
|
|
10439
|
+
listRef: mobileListRef,
|
|
10440
|
+
onScroll: handleScroll,
|
|
10441
|
+
onOptionClick: handleOptionClick,
|
|
10442
|
+
onKeyDown: handleMobileWheelKeyDown,
|
|
10443
|
+
onDone: handleMobileDone,
|
|
10444
|
+
getOptionId: getOptionId2,
|
|
10445
|
+
noOptionsMessage
|
|
10446
|
+
}
|
|
10447
|
+
) : /* @__PURE__ */ jsx129(
|
|
10448
|
+
SelectDesktopContent,
|
|
10449
|
+
{
|
|
10450
|
+
isOpen,
|
|
10451
|
+
listboxId,
|
|
10452
|
+
labelId,
|
|
10453
|
+
errorId: describedErrorId,
|
|
10454
|
+
options,
|
|
10455
|
+
value,
|
|
10456
|
+
highlightedIndex,
|
|
10457
|
+
onOptionClick: (option) => {
|
|
10458
|
+
handleDesktopSelect(option);
|
|
10459
|
+
setIsOpen(false);
|
|
10460
|
+
focusTrigger();
|
|
10461
|
+
},
|
|
10462
|
+
onOptionHover: setHighlightedIndex,
|
|
10463
|
+
onKeyDown: (event) => {
|
|
10464
|
+
handleMenuKeyDown(event, () => setIsOpen(false));
|
|
10465
|
+
},
|
|
10466
|
+
disabled: isBlocked,
|
|
10467
|
+
menuClassName,
|
|
10468
|
+
dropdownClassName,
|
|
10469
|
+
listRef: desktopListRef,
|
|
10470
|
+
setOptionRef,
|
|
10471
|
+
getOptionId: getOptionId2,
|
|
10472
|
+
noOptionsMessage
|
|
10473
|
+
}
|
|
10474
|
+
)
|
|
10475
|
+
]
|
|
10476
|
+
}
|
|
10477
|
+
);
|
|
10471
10478
|
});
|
|
10472
10479
|
|
|
10473
10480
|
// src/airbnb/phone-field/PhoneField.tsx
|
|
@@ -10512,7 +10519,7 @@ var PhoneField = React37.forwardRef(
|
|
|
10512
10519
|
const hasInvalidState = Boolean(error) || Boolean(invalid);
|
|
10513
10520
|
const isBlocked = Boolean(disabled) || Boolean(loading);
|
|
10514
10521
|
const isCodeBlocked = isBlocked || Boolean(codeReadOnly);
|
|
10515
|
-
return /* @__PURE__ */ jsxs84("div", { className: cn("w-full max-w-[
|
|
10522
|
+
return /* @__PURE__ */ jsxs84("div", { className: cn("w-full max-w-[var(--max-field-width)]", className), children: [
|
|
10516
10523
|
name && /* @__PURE__ */ jsx130("input", { type: "hidden", name, value: combinedValue, disabled }),
|
|
10517
10524
|
codeName && /* @__PURE__ */ jsx130(
|
|
10518
10525
|
"input",
|
|
@@ -10878,82 +10885,89 @@ var SearchableSelectInternal = ({
|
|
|
10878
10885
|
}
|
|
10879
10886
|
);
|
|
10880
10887
|
React39.useImperativeHandle(ref, () => triggerRef.current, []);
|
|
10881
|
-
return /* @__PURE__ */ jsxs86(
|
|
10882
|
-
|
|
10883
|
-
|
|
10884
|
-
|
|
10885
|
-
|
|
10886
|
-
|
|
10887
|
-
|
|
10888
|
-
|
|
10889
|
-
|
|
10890
|
-
"aria-expanded": open,
|
|
10891
|
-
"aria-controls": listboxId,
|
|
10892
|
-
label,
|
|
10893
|
-
topLabel,
|
|
10894
|
-
labelId,
|
|
10895
|
-
valueId,
|
|
10896
|
-
helperTextId,
|
|
10897
|
-
errorId: error ? errorId : void 0,
|
|
10898
|
-
labelText: topLabel ? helperText : void 0,
|
|
10899
|
-
valueText: valueLabel,
|
|
10900
|
-
placeholder: helperText,
|
|
10901
|
-
describedBy,
|
|
10902
|
-
error: triggerError,
|
|
10903
|
-
loading,
|
|
10904
|
-
optional,
|
|
10905
|
-
tooltip,
|
|
10906
|
-
forceLabelText: Boolean(optional) || Boolean(tooltip),
|
|
10907
|
-
hideErrorMessage,
|
|
10908
|
-
disabled,
|
|
10909
|
-
onClick: () => {
|
|
10910
|
-
if (open) {
|
|
10911
|
-
closeSelect();
|
|
10912
|
-
return;
|
|
10913
|
-
}
|
|
10914
|
-
openSelect();
|
|
10915
|
-
},
|
|
10916
|
-
onKeyDown: handleTriggerKeyDown,
|
|
10917
|
-
trailingAdornment: /* @__PURE__ */ jsx132(
|
|
10918
|
-
ChevronDown3,
|
|
10888
|
+
return /* @__PURE__ */ jsxs86(
|
|
10889
|
+
"div",
|
|
10890
|
+
{
|
|
10891
|
+
ref: containerRef,
|
|
10892
|
+
className: cn("relative w-full max-w-[var(--max-field-width)]", className),
|
|
10893
|
+
children: [
|
|
10894
|
+
name && /* @__PURE__ */ jsx132("input", { type: "hidden", name, value: value ? String(value.value) : "" }),
|
|
10895
|
+
/* @__PURE__ */ jsx132(
|
|
10896
|
+
FieldTrigger,
|
|
10919
10897
|
{
|
|
10920
|
-
|
|
10921
|
-
|
|
10922
|
-
|
|
10898
|
+
id: `${reactId}-trigger`,
|
|
10899
|
+
ref: triggerRef,
|
|
10900
|
+
variant,
|
|
10901
|
+
"aria-haspopup": "listbox",
|
|
10902
|
+
"aria-expanded": open,
|
|
10903
|
+
"aria-controls": listboxId,
|
|
10904
|
+
label,
|
|
10905
|
+
topLabel,
|
|
10906
|
+
labelId,
|
|
10907
|
+
valueId,
|
|
10908
|
+
helperTextId,
|
|
10909
|
+
errorId: error ? errorId : void 0,
|
|
10910
|
+
labelText: topLabel ? helperText : void 0,
|
|
10911
|
+
valueText: valueLabel,
|
|
10912
|
+
placeholder: helperText,
|
|
10913
|
+
describedBy,
|
|
10914
|
+
error: triggerError,
|
|
10915
|
+
loading,
|
|
10916
|
+
optional,
|
|
10917
|
+
tooltip,
|
|
10918
|
+
forceLabelText: Boolean(optional) || Boolean(tooltip),
|
|
10919
|
+
hideErrorMessage,
|
|
10920
|
+
disabled,
|
|
10921
|
+
onClick: () => {
|
|
10922
|
+
if (open) {
|
|
10923
|
+
closeSelect();
|
|
10924
|
+
return;
|
|
10925
|
+
}
|
|
10926
|
+
openSelect();
|
|
10927
|
+
},
|
|
10928
|
+
onKeyDown: handleTriggerKeyDown,
|
|
10929
|
+
trailingAdornment: /* @__PURE__ */ jsx132(
|
|
10930
|
+
ChevronDown3,
|
|
10931
|
+
{
|
|
10932
|
+
className: cn(
|
|
10933
|
+
"h-6 w-6 text-[#1F1F1B] transition-transform",
|
|
10934
|
+
open && "rotate-180"
|
|
10935
|
+
)
|
|
10936
|
+
}
|
|
10923
10937
|
)
|
|
10924
10938
|
}
|
|
10925
|
-
)
|
|
10926
|
-
}
|
|
10927
|
-
),
|
|
10928
|
-
isMobile ? /* @__PURE__ */ jsx132(
|
|
10929
|
-
Drawer,
|
|
10930
|
-
{
|
|
10931
|
-
open,
|
|
10932
|
-
onOpenChange: (nextOpen) => {
|
|
10933
|
-
if (isBlocked && nextOpen) return;
|
|
10934
|
-
if (nextOpen) {
|
|
10935
|
-
setSelectOpen(true);
|
|
10936
|
-
return;
|
|
10937
|
-
}
|
|
10938
|
-
closeSelect();
|
|
10939
|
-
},
|
|
10940
|
-
children: /* @__PURE__ */ jsxs86(DrawerContent, { onClose: closeSelect, lockScroll: false, children: [
|
|
10941
|
-
/* @__PURE__ */ jsx132(DrawerTitle, { className: "sr-only", children: mobileTitle ?? label }),
|
|
10942
|
-
/* @__PURE__ */ jsx132(DrawerDescription, { className: "sr-only", children: label }),
|
|
10943
|
-
/* @__PURE__ */ jsx132("div", { className: "px-5 pb-5 pt-1", children: content })
|
|
10944
|
-
] })
|
|
10945
|
-
}
|
|
10946
|
-
) : open ? /* @__PURE__ */ jsx132(
|
|
10947
|
-
"div",
|
|
10948
|
-
{
|
|
10949
|
-
className: cn(
|
|
10950
|
-
"absolute left-0 right-0 top-[calc(100%+8px)] z-20 overflow-hidden rounded-[20px] border border-[#DEDAD2] bg-white shadow-[0_14px_30px_rgba(18,18,18,0.08)]",
|
|
10951
|
-
dropdownClassName
|
|
10952
10939
|
),
|
|
10953
|
-
|
|
10954
|
-
|
|
10955
|
-
|
|
10956
|
-
|
|
10940
|
+
isMobile ? /* @__PURE__ */ jsx132(
|
|
10941
|
+
Drawer,
|
|
10942
|
+
{
|
|
10943
|
+
open,
|
|
10944
|
+
onOpenChange: (nextOpen) => {
|
|
10945
|
+
if (isBlocked && nextOpen) return;
|
|
10946
|
+
if (nextOpen) {
|
|
10947
|
+
setSelectOpen(true);
|
|
10948
|
+
return;
|
|
10949
|
+
}
|
|
10950
|
+
closeSelect();
|
|
10951
|
+
},
|
|
10952
|
+
children: /* @__PURE__ */ jsxs86(DrawerContent, { onClose: closeSelect, lockScroll: false, children: [
|
|
10953
|
+
/* @__PURE__ */ jsx132(DrawerTitle, { className: "sr-only", children: mobileTitle ?? label }),
|
|
10954
|
+
/* @__PURE__ */ jsx132(DrawerDescription, { className: "sr-only", children: label }),
|
|
10955
|
+
/* @__PURE__ */ jsx132("div", { className: "px-5 pb-5 pt-1", children: content })
|
|
10956
|
+
] })
|
|
10957
|
+
}
|
|
10958
|
+
) : open ? /* @__PURE__ */ jsx132(
|
|
10959
|
+
"div",
|
|
10960
|
+
{
|
|
10961
|
+
className: cn(
|
|
10962
|
+
"absolute left-0 right-0 top-[calc(100%+8px)] z-20 overflow-hidden rounded-[20px] border border-[#DEDAD2] bg-white shadow-[0_14px_30px_rgba(18,18,18,0.08)]",
|
|
10963
|
+
dropdownClassName
|
|
10964
|
+
),
|
|
10965
|
+
children: content
|
|
10966
|
+
}
|
|
10967
|
+
) : null
|
|
10968
|
+
]
|
|
10969
|
+
}
|
|
10970
|
+
);
|
|
10957
10971
|
};
|
|
10958
10972
|
var SearchableSelect = React39.forwardRef(
|
|
10959
10973
|
SearchableSelectInternal
|