mayak-common-library 0.0.41 → 0.0.43
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.d.mts +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +6 -3
- package/dist/index.mjs +6 -3
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -302,11 +302,13 @@ var SelectPro = ({
|
|
|
302
302
|
overButton = false,
|
|
303
303
|
small = false,
|
|
304
304
|
fullWidth = false,
|
|
305
|
-
freeChildWidth = false
|
|
305
|
+
freeChildWidth = false,
|
|
306
|
+
isOpen
|
|
306
307
|
}) => {
|
|
307
308
|
const [btn, setAnchorEl] = (0, import_react2.useState)(null);
|
|
308
309
|
const [open, setOpen] = (0, import_react2.useState)(false);
|
|
309
310
|
const handleClick = (event) => {
|
|
311
|
+
if (isOpen) return;
|
|
310
312
|
event.persist();
|
|
311
313
|
if (open)
|
|
312
314
|
setTimeout(() => {
|
|
@@ -316,6 +318,7 @@ var SelectPro = ({
|
|
|
316
318
|
setOpen(!open);
|
|
317
319
|
};
|
|
318
320
|
const handleClose = () => {
|
|
321
|
+
if (isOpen) return;
|
|
319
322
|
setOpen(false);
|
|
320
323
|
setTimeout(() => {
|
|
321
324
|
setAnchorEl(null);
|
|
@@ -654,6 +657,7 @@ var import_jsx_runtime21 = require("react/jsx-runtime");
|
|
|
654
657
|
var SearchInput = (props) => {
|
|
655
658
|
const { collapse } = props;
|
|
656
659
|
const { field } = (0, import_react_hook_form.useController)(props);
|
|
660
|
+
console.log(collapse);
|
|
657
661
|
const handleSearchInputClick = (event) => {
|
|
658
662
|
if (props.onClick) {
|
|
659
663
|
props.onClick(event);
|
|
@@ -668,8 +672,7 @@ var SearchInput = (props) => {
|
|
|
668
672
|
startAdornment: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_material12.Stack, { direction: "row", alignItems: "center", children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_material12.InputAdornment, { position: "start", children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(search_default, {}) }) }),
|
|
669
673
|
disableUnderline: true,
|
|
670
674
|
placeholder: "\u041F\u043E\u0448\u0443\u043A \u043F\u043E \u0440\u0430\u0439\u043E\u043D\u0443, \u0432\u0443\u043B\u0438\u0446\u0456, \u0416\u041A",
|
|
671
|
-
className: `w-full border rounded-none border-solid normal-case text-accent-dark
|
|
672
|
-
${collapse ? "bg-white border-transparent" : " border-accent-beige"} `
|
|
675
|
+
className: `w-full border rounded-none border-solid normal-case text-accent-dark gap-x-2 px-5 h-[38px] ${collapse ? "bg-white border-transparent" : "border-accent-beige"} hover:bg-white`
|
|
673
676
|
})
|
|
674
677
|
);
|
|
675
678
|
};
|
package/dist/index.mjs
CHANGED
|
@@ -242,11 +242,13 @@ var SelectPro = ({
|
|
|
242
242
|
overButton = false,
|
|
243
243
|
small = false,
|
|
244
244
|
fullWidth = false,
|
|
245
|
-
freeChildWidth = false
|
|
245
|
+
freeChildWidth = false,
|
|
246
|
+
isOpen
|
|
246
247
|
}) => {
|
|
247
248
|
const [btn, setAnchorEl] = useState2(null);
|
|
248
249
|
const [open, setOpen] = useState2(false);
|
|
249
250
|
const handleClick = (event) => {
|
|
251
|
+
if (isOpen) return;
|
|
250
252
|
event.persist();
|
|
251
253
|
if (open)
|
|
252
254
|
setTimeout(() => {
|
|
@@ -256,6 +258,7 @@ var SelectPro = ({
|
|
|
256
258
|
setOpen(!open);
|
|
257
259
|
};
|
|
258
260
|
const handleClose = () => {
|
|
261
|
+
if (isOpen) return;
|
|
259
262
|
setOpen(false);
|
|
260
263
|
setTimeout(() => {
|
|
261
264
|
setAnchorEl(null);
|
|
@@ -594,6 +597,7 @@ import { jsx as jsx20 } from "react/jsx-runtime";
|
|
|
594
597
|
var SearchInput = (props) => {
|
|
595
598
|
const { collapse } = props;
|
|
596
599
|
const { field } = useController(props);
|
|
600
|
+
console.log(collapse);
|
|
597
601
|
const handleSearchInputClick = (event) => {
|
|
598
602
|
if (props.onClick) {
|
|
599
603
|
props.onClick(event);
|
|
@@ -608,8 +612,7 @@ var SearchInput = (props) => {
|
|
|
608
612
|
startAdornment: /* @__PURE__ */ jsx20(Stack3, { direction: "row", alignItems: "center", children: /* @__PURE__ */ jsx20(InputAdornment2, { position: "start", children: /* @__PURE__ */ jsx20(search_default, {}) }) }),
|
|
609
613
|
disableUnderline: true,
|
|
610
614
|
placeholder: "\u041F\u043E\u0448\u0443\u043A \u043F\u043E \u0440\u0430\u0439\u043E\u043D\u0443, \u0432\u0443\u043B\u0438\u0446\u0456, \u0416\u041A",
|
|
611
|
-
className: `w-full border rounded-none border-solid normal-case text-accent-dark
|
|
612
|
-
${collapse ? "bg-white border-transparent" : " border-accent-beige"} `
|
|
615
|
+
className: `w-full border rounded-none border-solid normal-case text-accent-dark gap-x-2 px-5 h-[38px] ${collapse ? "bg-white border-transparent" : "border-accent-beige"} hover:bg-white`
|
|
613
616
|
})
|
|
614
617
|
);
|
|
615
618
|
};
|