@foodpilot/foods 0.3.17 → 0.3.18
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/main.js
CHANGED
|
@@ -63452,21 +63452,21 @@ const Ise = (e) => {
|
|
|
63452
63452
|
})
|
|
63453
63453
|
] });
|
|
63454
63454
|
}, iae = (e, t, n, o, r) => e.length === 0 ? t : n === null ? r : o(n), sae = (e) => {
|
|
63455
|
-
const { textOptions: t, disabled: n, closeOnSelect: o, setSearch: r } = uc(),
|
|
63455
|
+
const { textOptions: t, disabled: n, closeOnSelect: o, setSearch: r, disableOnEmpty: s } = uc(), a = et(), [l, c] = ft(null), u = () => c(null), d = l !== null, { selectedOption: f } = e, h = d ? /* @__PURE__ */ p.jsx(f1, {}) : /* @__PURE__ */ p.jsx(p1, {}), g = d ? { border: `2px solid ${a.custom.grey[2800]}` } : {}, b = iae(
|
|
63456
63456
|
e.options,
|
|
63457
63457
|
t.emptyOptionsText,
|
|
63458
|
-
|
|
63458
|
+
f,
|
|
63459
63459
|
e.getName,
|
|
63460
63460
|
t.placeholder
|
|
63461
|
-
);
|
|
63461
|
+
), m = s && e.options.length === 0;
|
|
63462
63462
|
return /* @__PURE__ */ p.jsxs(rr, { children: [
|
|
63463
63463
|
/* @__PURE__ */ p.jsxs(
|
|
63464
63464
|
Ot,
|
|
63465
63465
|
{
|
|
63466
63466
|
variant: "select",
|
|
63467
|
-
onClick: (
|
|
63467
|
+
onClick: (v) => d ? u() : c(v.currentTarget),
|
|
63468
63468
|
sx: {
|
|
63469
|
-
...
|
|
63469
|
+
...g,
|
|
63470
63470
|
width: "100%",
|
|
63471
63471
|
height: "40px",
|
|
63472
63472
|
display: "flex",
|
|
@@ -63474,9 +63474,9 @@ const Ise = (e) => {
|
|
|
63474
63474
|
justifyContent: "space-between",
|
|
63475
63475
|
padding: "0px 12px 0px 12px"
|
|
63476
63476
|
},
|
|
63477
|
-
disabled: n ||
|
|
63477
|
+
disabled: n || m,
|
|
63478
63478
|
children: [
|
|
63479
|
-
e.getIcon &&
|
|
63479
|
+
e.getIcon && f && e.getIcon(f),
|
|
63480
63480
|
/* @__PURE__ */ p.jsx(
|
|
63481
63481
|
Ve,
|
|
63482
63482
|
{
|
|
@@ -63489,10 +63489,10 @@ const Ise = (e) => {
|
|
|
63489
63489
|
whiteSpace: "nowrap",
|
|
63490
63490
|
textOverflow: "ellipsis"
|
|
63491
63491
|
},
|
|
63492
|
-
children:
|
|
63492
|
+
children: b
|
|
63493
63493
|
}
|
|
63494
63494
|
),
|
|
63495
|
-
|
|
63495
|
+
h
|
|
63496
63496
|
]
|
|
63497
63497
|
}
|
|
63498
63498
|
),
|
|
@@ -63503,16 +63503,16 @@ const Ise = (e) => {
|
|
|
63503
63503
|
paperProps: {
|
|
63504
63504
|
width: "280px",
|
|
63505
63505
|
maxHeight: "300px",
|
|
63506
|
-
border: `1px solid ${
|
|
63506
|
+
border: `1px solid ${a.custom.grey[500]}`,
|
|
63507
63507
|
borderRadius: "12px",
|
|
63508
63508
|
boxShadow: "0px 4px 20px 0px #514E4E1F",
|
|
63509
63509
|
...e.BoxOptionsProps
|
|
63510
63510
|
},
|
|
63511
63511
|
variant: "headless",
|
|
63512
|
-
anchor:
|
|
63513
|
-
open:
|
|
63512
|
+
anchor: l,
|
|
63513
|
+
open: d,
|
|
63514
63514
|
onClose: () => {
|
|
63515
|
-
|
|
63515
|
+
u(), r("");
|
|
63516
63516
|
},
|
|
63517
63517
|
anchorPosition: "rightside",
|
|
63518
63518
|
children: /* @__PURE__ */ p.jsx(
|
|
@@ -63523,8 +63523,8 @@ const Ise = (e) => {
|
|
|
63523
63523
|
getId: e.getId,
|
|
63524
63524
|
getName: e.getName,
|
|
63525
63525
|
getIcon: e.getIcon,
|
|
63526
|
-
onChange: (
|
|
63527
|
-
e.onChange(
|
|
63526
|
+
onChange: (v) => {
|
|
63527
|
+
e.onChange(v), r(""), o === !0 && u();
|
|
63528
63528
|
}
|
|
63529
63529
|
}
|
|
63530
63530
|
)
|
|
@@ -63574,8 +63574,9 @@ const Ise = (e) => {
|
|
|
63574
63574
|
disabled: o,
|
|
63575
63575
|
closeOnSelect: r,
|
|
63576
63576
|
disableSearch: s,
|
|
63577
|
-
|
|
63578
|
-
|
|
63577
|
+
disableOnEmpty: a = !1,
|
|
63578
|
+
...l
|
|
63579
|
+
} = e, [c, u] = ft(""), d = (f) => c === "" ? !0 : f.toLowerCase().includes(c.toLowerCase());
|
|
63579
63580
|
return /* @__PURE__ */ p.jsx(
|
|
63580
63581
|
rC,
|
|
63581
63582
|
{
|
|
@@ -63584,10 +63585,11 @@ const Ise = (e) => {
|
|
|
63584
63585
|
disabled: o,
|
|
63585
63586
|
closeOnSelect: r,
|
|
63586
63587
|
disableSearch: s,
|
|
63587
|
-
search:
|
|
63588
|
-
setSearch:
|
|
63589
|
-
isSearchFound:
|
|
63590
|
-
|
|
63588
|
+
search: c,
|
|
63589
|
+
setSearch: u,
|
|
63590
|
+
isSearchFound: d,
|
|
63591
|
+
disableOnEmpty: a,
|
|
63592
|
+
children: /* @__PURE__ */ p.jsx(sC, { ...l })
|
|
63591
63593
|
}
|
|
63592
63594
|
);
|
|
63593
63595
|
}, Ple = (e) => {
|
|
@@ -63600,7 +63602,8 @@ const Ise = (e) => {
|
|
|
63600
63602
|
search: s,
|
|
63601
63603
|
setSearch: a,
|
|
63602
63604
|
isSearchFound: l,
|
|
63603
|
-
|
|
63605
|
+
disableOnEmpty: c = !1,
|
|
63606
|
+
...u
|
|
63604
63607
|
} = e;
|
|
63605
63608
|
return /* @__PURE__ */ p.jsx(
|
|
63606
63609
|
rC,
|
|
@@ -63612,7 +63615,8 @@ const Ise = (e) => {
|
|
|
63612
63615
|
search: s,
|
|
63613
63616
|
setSearch: a,
|
|
63614
63617
|
isSearchFound: l,
|
|
63615
|
-
|
|
63618
|
+
disableOnEmpty: c,
|
|
63619
|
+
children: /* @__PURE__ */ p.jsx(sC, { ...u })
|
|
63616
63620
|
}
|
|
63617
63621
|
);
|
|
63618
63622
|
};
|