@flytedan/flytebot-design-system 0.36.0 → 0.37.0
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 +18 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +18 -3
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -3733,6 +3733,7 @@ function MultiSelectPanel({
|
|
|
3733
3733
|
}, [mode2]);
|
|
3734
3734
|
const doResolve = () => {
|
|
3735
3735
|
if (!field.resolve) return;
|
|
3736
|
+
if (pasteLoading) return;
|
|
3736
3737
|
const tokens = Array.from(new Set(pasteText.split(/[\n,]/).map((t) => t.trim()).filter(Boolean)));
|
|
3737
3738
|
if (!tokens.length) return;
|
|
3738
3739
|
setPasteLoading(true);
|
|
@@ -3815,7 +3816,8 @@ function MultiSelectPanel({
|
|
|
3815
3816
|
rows: 4,
|
|
3816
3817
|
placeholder: field.pastePlaceholder || field.placeholder || "Paste names, one per line or comma-separated",
|
|
3817
3818
|
value: pasteText,
|
|
3818
|
-
|
|
3819
|
+
readOnly: pasteLoading,
|
|
3820
|
+
"aria-busy": pasteLoading || void 0,
|
|
3819
3821
|
onChange: (e) => setPasteText(e.target.value),
|
|
3820
3822
|
onKeyDown: (e) => {
|
|
3821
3823
|
if (e.key === "Enter" && (e.metaKey || e.ctrlKey)) {
|
|
@@ -4026,6 +4028,16 @@ function RangePanel({
|
|
|
4026
4028
|
setDraft(next);
|
|
4027
4029
|
publish();
|
|
4028
4030
|
};
|
|
4031
|
+
const doneClick = (e) => {
|
|
4032
|
+
if (doneDisabled) {
|
|
4033
|
+
e.preventDefault();
|
|
4034
|
+
return;
|
|
4035
|
+
}
|
|
4036
|
+
onClose();
|
|
4037
|
+
};
|
|
4038
|
+
const doneKeyDown = (e) => {
|
|
4039
|
+
if (doneDisabled && (e.key === "Enter" || e.key === " ")) e.preventDefault();
|
|
4040
|
+
};
|
|
4029
4041
|
return /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
4030
4042
|
Popover,
|
|
4031
4043
|
{
|
|
@@ -4036,7 +4048,7 @@ function RangePanel({
|
|
|
4036
4048
|
offset: 6,
|
|
4037
4049
|
width: PANEL_WIDTH.range,
|
|
4038
4050
|
label: field.label,
|
|
4039
|
-
footer: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(Button, { size: "sm", variant: "secondary", onClick:
|
|
4051
|
+
footer: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(Button, { size: "sm", variant: "secondary", "aria-disabled": doneDisabled, onClick: doneClick, onKeyDown: doneKeyDown, children: "Done" }),
|
|
4040
4052
|
children: /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("span", { className: "fd-stack fd-gap-sm", children: [
|
|
4041
4053
|
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { ref: minWrapRef, children: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
4042
4054
|
NumberInput,
|
|
@@ -4158,6 +4170,9 @@ function DatePanel({
|
|
|
4158
4170
|
}
|
|
4159
4171
|
onClose();
|
|
4160
4172
|
};
|
|
4173
|
+
const doneKeyDown = (e) => {
|
|
4174
|
+
if (doneDisabled && (e.key === "Enter" || e.key === " ")) e.preventDefault();
|
|
4175
|
+
};
|
|
4161
4176
|
return /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
4162
4177
|
Popover,
|
|
4163
4178
|
{
|
|
@@ -4168,7 +4183,7 @@ function DatePanel({
|
|
|
4168
4183
|
offset: 6,
|
|
4169
4184
|
width: PANEL_WIDTH.date,
|
|
4170
4185
|
label: field.label,
|
|
4171
|
-
footer: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(Button, { size: "sm", variant: "secondary", onClick: confirm,
|
|
4186
|
+
footer: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(Button, { size: "sm", variant: "secondary", "aria-disabled": doneDisabled, onClick: confirm, onKeyDown: doneKeyDown, children: "Done" }),
|
|
4172
4187
|
children: /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("span", { className: "fd-stack fd-gap-sm", children: [
|
|
4173
4188
|
/* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
|
|
4174
4189
|
SegmentedControl,
|