@yenio-pld/blocks 1.2.0-rc.10 → 1.2.0-rc.12
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 +42 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +9 -1
- package/dist/index.d.ts +9 -1
- package/dist/index.js +43 -6
- package/dist/index.js.map +1 -1
- package/dist/ui/dialog.d.ts +3 -1
- package/dist/ui/dialog.js +22 -4
- package/dist/ui/dialog.js.map +1 -1
- package/dist/ui/select.js +14 -5
- package/dist/ui/select.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -21,11 +21,11 @@ var classVarianceAuthority = require('class-variance-authority');
|
|
|
21
21
|
var alertDialog_js = require('./ui/alert-dialog.js');
|
|
22
22
|
var nextThemes = require('next-themes');
|
|
23
23
|
var combobox_js = require('./ui/combobox.js');
|
|
24
|
+
var dialog_js = require('./ui/dialog.js');
|
|
24
25
|
var drawer_js = require('./ui/drawer.js');
|
|
25
26
|
var input_js = require('./ui/input.js');
|
|
26
27
|
var slider_js = require('./ui/slider.js');
|
|
27
28
|
var toggle_js = require('./ui/toggle.js');
|
|
28
|
-
var dialog_js = require('./ui/dialog.js');
|
|
29
29
|
var framerMotion = require('framer-motion');
|
|
30
30
|
var badge_js = require('./ui/badge.js');
|
|
31
31
|
|
|
@@ -3087,6 +3087,7 @@ function CountryPicker({
|
|
|
3087
3087
|
const labels = { ...defaultLabels2(purpose, locale), ...labelsProp };
|
|
3088
3088
|
const items = React3__namespace.useMemo(() => countryPickerItems(locale), [locale]);
|
|
3089
3089
|
const selected = React3__namespace.useMemo(() => findItem(items, value), [items, value]);
|
|
3090
|
+
const dialogPortalContainer = dialog_js.useDialogPortalContainer();
|
|
3090
3091
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
3091
3092
|
name ? /* @__PURE__ */ jsxRuntime.jsx("input", { type: "hidden", name, value: value.trim().toUpperCase() }) : null,
|
|
3092
3093
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -3139,7 +3140,7 @@ function CountryPicker({
|
|
|
3139
3140
|
]
|
|
3140
3141
|
}
|
|
3141
3142
|
),
|
|
3142
|
-
/* @__PURE__ */ jsxRuntime.jsx(combobox_js.Combobox.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3143
|
+
/* @__PURE__ */ jsxRuntime.jsx(combobox_js.Combobox.Portal, { container: dialogPortalContainer ?? void 0, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3143
3144
|
combobox_js.Combobox.Positioner,
|
|
3144
3145
|
{
|
|
3145
3146
|
className: "pointer-events-auto isolate z-[60] outline-none",
|
|
@@ -3238,6 +3239,7 @@ function SearchablePicker({
|
|
|
3238
3239
|
onOpenChange
|
|
3239
3240
|
}) {
|
|
3240
3241
|
const isMdUp = useMediaQuery(MD_UP);
|
|
3242
|
+
const dialogPortalContainer = dialog_js.useDialogPortalContainer();
|
|
3241
3243
|
const [open, setOpen] = React3__namespace.useState(false);
|
|
3242
3244
|
const searchRef = React3__namespace.useRef(null);
|
|
3243
3245
|
function setOpenState(next) {
|
|
@@ -3345,7 +3347,7 @@ function SearchablePicker({
|
|
|
3345
3347
|
}
|
|
3346
3348
|
) : null
|
|
3347
3349
|
] }),
|
|
3348
|
-
/* @__PURE__ */ jsxRuntime.jsx(combobox_js.Combobox.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3350
|
+
/* @__PURE__ */ jsxRuntime.jsx(combobox_js.Combobox.Portal, { container: dialogPortalContainer ?? void 0, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3349
3351
|
combobox_js.Combobox.Positioner,
|
|
3350
3352
|
{
|
|
3351
3353
|
className: "pointer-events-auto isolate z-[60] outline-none",
|
|
@@ -3547,6 +3549,7 @@ function PaginatedCombobox({
|
|
|
3547
3549
|
"aria-invalid": ariaInvalid
|
|
3548
3550
|
}) {
|
|
3549
3551
|
const labels = { ...DEFAULT_LABELS, ...labelsProp };
|
|
3552
|
+
const dialogPortalContainer = dialog_js.useDialogPortalContainer();
|
|
3550
3553
|
const selected = React3__namespace.useMemo(
|
|
3551
3554
|
() => resolveSelected(value, items, selectedItem),
|
|
3552
3555
|
[value, items, selectedItem]
|
|
@@ -3639,7 +3642,7 @@ function PaginatedCombobox({
|
|
|
3639
3642
|
]
|
|
3640
3643
|
}
|
|
3641
3644
|
),
|
|
3642
|
-
/* @__PURE__ */ jsxRuntime.jsx(combobox_js.Combobox.Portal, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3645
|
+
/* @__PURE__ */ jsxRuntime.jsx(combobox_js.Combobox.Portal, { container: dialogPortalContainer ?? void 0, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3643
3646
|
combobox_js.Combobox.Positioner,
|
|
3644
3647
|
{
|
|
3645
3648
|
className: "pointer-events-auto isolate z-[60] outline-none",
|
|
@@ -3824,6 +3827,40 @@ function CurpInput({
|
|
|
3824
3827
|
}
|
|
3825
3828
|
);
|
|
3826
3829
|
}
|
|
3830
|
+
function PasswordInput({
|
|
3831
|
+
className,
|
|
3832
|
+
disabled,
|
|
3833
|
+
showLabel = "Show password",
|
|
3834
|
+
hideLabel = "Hide password",
|
|
3835
|
+
...props
|
|
3836
|
+
}) {
|
|
3837
|
+
const [visible, setVisible] = React3__namespace.useState(false);
|
|
3838
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "relative w-full", children: [
|
|
3839
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3840
|
+
input_js.Input,
|
|
3841
|
+
{
|
|
3842
|
+
...props,
|
|
3843
|
+
type: visible ? "text" : "password",
|
|
3844
|
+
disabled,
|
|
3845
|
+
className: cn("pr-9", className)
|
|
3846
|
+
}
|
|
3847
|
+
),
|
|
3848
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3849
|
+
button_js.Button,
|
|
3850
|
+
{
|
|
3851
|
+
type: "button",
|
|
3852
|
+
variant: "ghost",
|
|
3853
|
+
size: "icon-xs",
|
|
3854
|
+
disabled,
|
|
3855
|
+
className: "absolute inset-y-0 right-1 my-auto text-muted-foreground hover:text-foreground",
|
|
3856
|
+
"aria-label": visible ? hideLabel : showLabel,
|
|
3857
|
+
"aria-pressed": visible,
|
|
3858
|
+
onClick: () => setVisible((value) => !value),
|
|
3859
|
+
children: visible ? /* @__PURE__ */ jsxRuntime.jsx(lucideReact.EyeOff, { className: "size-4", "aria-hidden": true }) : /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Eye, { className: "size-4", "aria-hidden": true })
|
|
3860
|
+
}
|
|
3861
|
+
)
|
|
3862
|
+
] });
|
|
3863
|
+
}
|
|
3827
3864
|
var DEFAULT_LABELS2 = {
|
|
3828
3865
|
uploadAria: "Upload image",
|
|
3829
3866
|
uploadHint: "Click to upload",
|
|
@@ -6952,6 +6989,7 @@ exports.PageContainer = PageContainer;
|
|
|
6952
6989
|
exports.PageTitle = PageTitle;
|
|
6953
6990
|
exports.PageTitleSkeleton = PageTitleSkeleton;
|
|
6954
6991
|
exports.PaginatedCombobox = PaginatedCombobox;
|
|
6992
|
+
exports.PasswordInput = PasswordInput;
|
|
6955
6993
|
exports.QueueLayout = QueueLayout;
|
|
6956
6994
|
exports.RfcInput = RfcInput;
|
|
6957
6995
|
exports.RiskBadge = RiskBadge;
|