@kommo-crm/crm-react-ui-kit 1.1.1-beta.13 → 1.1.1-beta.15
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/components/ContextMenu/ContextMenu.js +1 -1
- package/dist/components/ContextMenu/components/CheckboxItem/CheckboxItem.js +1 -1
- package/dist/components/ContextMenu/components/Content/Content.d.ts +1 -1
- package/dist/components/ContextMenu/components/Content/Content.d.ts.map +1 -1
- package/dist/components/ContextMenu/components/Content/Content.js +1 -1
- package/dist/components/ContextMenu/components/Content/Content.props.d.ts +5 -1
- package/dist/components/ContextMenu/components/Content/Content.props.d.ts.map +1 -1
- package/dist/components/ContextMenu/components/Content/index.js +1 -1
- package/dist/components/ContextMenu/components/FocusBlocker/FocusBlocker.js +1 -1
- package/dist/components/ContextMenu/components/FocusBlocker/index.js +1 -1
- package/dist/components/ContextMenu/components/Item/Item.js +1 -1
- package/dist/components/ContextMenu/components/ItemRightSlot/ItemRightSlot.js +1 -1
- package/dist/components/ContextMenu/components/Label/Label.js +1 -1
- package/dist/components/ContextMenu/components/RadioItem/RadioItem.js +1 -1
- package/dist/components/ContextMenu/components/Sub/Sub.js +1 -1
- package/dist/components/ContextMenu/components/SubContent/SubContent.d.ts +1 -0
- package/dist/components/ContextMenu/components/SubContent/SubContent.d.ts.map +1 -1
- package/dist/components/ContextMenu/components/SubContent/SubContent.js +60 -58
- package/dist/components/ContextMenu/components/SubContent/SubContent.props.d.ts +4 -0
- package/dist/components/ContextMenu/components/SubContent/SubContent.props.d.ts.map +1 -1
- package/dist/components/ContextMenu/components/SubRoot/SubRoot.js +1 -1
- package/dist/components/ContextMenu/components/SubRoot/components/Content/Content.d.ts +1 -1
- package/dist/components/ContextMenu/components/SubRoot/components/Content/Content.d.ts.map +1 -1
- package/dist/components/ContextMenu/components/SubRoot/components/Content/Content.js +59 -57
- package/dist/components/ContextMenu/components/SubRoot/components/Trigger/Trigger.js +1 -1
- package/dist/components/ContextMenu/components/SubTrigger/SubTrigger.js +1 -1
- package/dist/components/ContextMenu/hooks/index.d.ts +1 -0
- package/dist/components/ContextMenu/hooks/index.d.ts.map +1 -1
- package/dist/components/ContextMenu/hooks/index.js +9 -7
- package/dist/components/ContextMenu/hooks/useChildrenWithBlocker/useChildrenWithBlocker.js +1 -1
- package/dist/components/ContextMenu/hooks/useContentPositioning/useContentPositioning.d.ts +1 -1
- package/dist/components/ContextMenu/hooks/useContentPositioning/useContentPositioning.d.ts.map +1 -1
- package/dist/components/ContextMenu/hooks/useContentPositioning/useContentPositioning.js +2 -1
- package/dist/components/ContextMenu/hooks/useContentPositioning/useContentPositioning.types.d.ts +4 -0
- package/dist/components/ContextMenu/hooks/useContentPositioning/useContentPositioning.types.d.ts.map +1 -1
- package/dist/components/ContextMenu/hooks/useContextMenu/useContextMenu.js +1 -1
- package/dist/components/ContextMenu/hooks/useContextMenuSub/useContextMenuSub.js +1 -1
- package/dist/components/ContextMenu/hooks/useContextMenuSubMenu/useContextMenuSubMenu.js +1 -1
- package/dist/components/ContextMenu/hooks/useInheritedArrowColor/useInheritedArrowColor.d.ts.map +1 -1
- package/dist/components/ContextMenu/hooks/useInheritedArrowColor/useInheritedArrowColor.js +12 -12
- package/dist/components/ContextMenu/hooks/useItemInnerFocus/useItemInnerFocus.js +1 -1
- package/dist/components/ContextMenu/hooks/usePrevious/usePrevious.d.ts +2 -0
- package/dist/components/ContextMenu/hooks/usePrevious/usePrevious.d.ts.map +1 -0
- package/dist/components/ContextMenu/hooks/usePrevious/usePrevious.js +10 -0
- package/dist/components/ContextMenu/index.js +1 -1
- package/dist/useContentPositioning-CLU2E_Oz.mjs +2433 -0
- package/package.json +1 -1
- package/dist/useContentPositioning-BokVuzge.mjs +0 -2425
|
@@ -1,19 +1,20 @@
|
|
|
1
1
|
import { useContextMenu as r } from "./useContextMenu/useContextMenu.js";
|
|
2
2
|
import { useContextMenuSubMenu as u } from "./useContextMenuSubMenu/useContextMenuSubMenu.js";
|
|
3
3
|
import { useInheritedArrowColor as n } from "./useInheritedArrowColor/useInheritedArrowColor.js";
|
|
4
|
-
import { u as m } from "../../../useContentPositioning-
|
|
4
|
+
import { u as m } from "../../../useContentPositioning-CLU2E_Oz.mjs";
|
|
5
5
|
import { useContextMenuSub as f } from "./useContextMenuSub/useContextMenuSub.js";
|
|
6
6
|
import { useContextMenuItemFocus as C } from "./useContextMenuItemFocus/useContextMenuItemFocus.js";
|
|
7
7
|
import { useIsTouchDevice as c } from "./useIsTouchDevice/useIsTouchDevice.js";
|
|
8
8
|
import { useClickOutside as d } from "./useClickOutside/useClickOutside.js";
|
|
9
9
|
import { useStopContextMenuEvents as l } from "./useStopContextMenuEvents/useStopContextMenuEvents.js";
|
|
10
|
-
import { useSubMenu as
|
|
10
|
+
import { useSubMenu as S } from "./useSubMenu/useSubMenu.js";
|
|
11
11
|
import { useInnerInputsFocus as F } from "./useInnerInputsFocus/useInnerInputsFocus.js";
|
|
12
12
|
import { useItemInnerFocus as O } from "./useItemInnerFocus/useItemInnerFocus.js";
|
|
13
|
-
import { useChildrenWithBlocker as
|
|
14
|
-
import { useMouseMoveOutside as
|
|
13
|
+
import { useChildrenWithBlocker as a } from "./useChildrenWithBlocker/useChildrenWithBlocker.js";
|
|
14
|
+
import { useMouseMoveOutside as w } from "./useMouseMoveOutside/useMouseMoveOutside.js";
|
|
15
|
+
import { usePrevious as B } from "./usePrevious/usePrevious.js";
|
|
15
16
|
export {
|
|
16
|
-
|
|
17
|
+
a as useChildrenWithBlocker,
|
|
17
18
|
d as useClickOutside,
|
|
18
19
|
m as useContentPositioning,
|
|
19
20
|
r as useContextMenu,
|
|
@@ -24,7 +25,8 @@ export {
|
|
|
24
25
|
F as useInnerInputsFocus,
|
|
25
26
|
c as useIsTouchDevice,
|
|
26
27
|
O as useItemInnerFocus,
|
|
27
|
-
|
|
28
|
+
w as useMouseMoveOutside,
|
|
29
|
+
B as usePrevious,
|
|
28
30
|
l as useStopContextMenuEvents,
|
|
29
|
-
|
|
31
|
+
S as useSubMenu
|
|
30
32
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs as r, Fragment as s, jsx as i } from "react/jsx-runtime";
|
|
2
2
|
import o, { useMemo as x } from "react";
|
|
3
|
-
import { F as f } from "../../../../useContentPositioning-
|
|
3
|
+
import { F as f } from "../../../../useContentPositioning-CLU2E_Oz.mjs";
|
|
4
4
|
import { useContextMenuRootContext as F } from "../../ContextMenu.context.js";
|
|
5
5
|
function b({
|
|
6
6
|
displayName: p,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { UseContentPositioningOptions } from './useContentPositioning.types';
|
|
2
|
-
export declare function useContentPositioning({ direction, alignOffset, disableAutoPositioning, triggerRef, contentRef, collisionBoundary, children, }: UseContentPositioningOptions): {
|
|
2
|
+
export declare function useContentPositioning({ direction, alignOffset, disableAutoPositioning, triggerRef, contentRef, collisionBoundary, disableRepositioning, children, }: UseContentPositioningOptions): {
|
|
3
3
|
align: "end" | "start";
|
|
4
4
|
offset: number;
|
|
5
5
|
isPositioned: boolean;
|
package/dist/components/ContextMenu/hooks/useContentPositioning/useContentPositioning.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useContentPositioning.d.ts","sourceRoot":"","sources":["../../../../../src/components/ContextMenu/hooks/useContentPositioning/useContentPositioning.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"useContentPositioning.d.ts","sourceRoot":"","sources":["../../../../../src/components/ContextMenu/hooks/useContentPositioning/useContentPositioning.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,4BAA4B,EAAE,MAAM,+BAA+B,CAAC;AAE7E,wBAAgB,qBAAqB,CAAC,EACpC,SAAS,EACT,WAAe,EACf,sBAAsB,EACtB,UAAU,EACV,UAAU,EACV,iBAAiB,EACjB,oBAAoB,EACpB,QAAQ,GACT,EAAE,4BAA4B;;;;EAwP9B"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import "react";
|
|
2
|
-
import { u as n } from "../../../../useContentPositioning-
|
|
2
|
+
import { u as n } from "../../../../useContentPositioning-CLU2E_Oz.mjs";
|
|
3
3
|
import "../../components/Content/Content.enums.js";
|
|
4
4
|
import "../../components/Content/Content.utils.js";
|
|
5
|
+
import "../usePrevious/usePrevious.js";
|
|
5
6
|
export {
|
|
6
7
|
n as useContentPositioning
|
|
7
8
|
};
|
package/dist/components/ContextMenu/hooks/useContentPositioning/useContentPositioning.types.d.ts
CHANGED
|
@@ -28,5 +28,9 @@ export interface UseContentPositioningOptions {
|
|
|
28
28
|
* The children of the content.
|
|
29
29
|
*/
|
|
30
30
|
children: React.ReactNode;
|
|
31
|
+
/**
|
|
32
|
+
* Whether to disable repositioning.
|
|
33
|
+
*/
|
|
34
|
+
disableRepositioning: boolean;
|
|
31
35
|
}
|
|
32
36
|
//# sourceMappingURL=useContentPositioning.types.d.ts.map
|
package/dist/components/ContextMenu/hooks/useContentPositioning/useContentPositioning.types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useContentPositioning.types.d.ts","sourceRoot":"","sources":["../../../../../src/components/ContextMenu/hooks/useContentPositioning/useContentPositioning.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAC;AAEzD,MAAM,WAAW,4BAA4B;IAC3C;;OAEG;IACH,SAAS,CAAC,EAAE,aAAa,CAAC;IAC1B;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;OAEG;IACH,sBAAsB,EAAE,OAAO,CAAC;IAChC;;OAEG;IACH,UAAU,EAAE,KAAK,CAAC,SAAS,CAAC,WAAW,CAAC,CAAC;IACzC;;OAEG;IACH,UAAU,EAAE,KAAK,CAAC,SAAS,CAAC,WAAW,CAAC,CAAC;IACzC;;OAEG;IACH,iBAAiB,CAAC,EAAE,OAAO,GAAG,IAAI,CAAC;IACnC;;OAEG;IACH,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"useContentPositioning.types.d.ts","sourceRoot":"","sources":["../../../../../src/components/ContextMenu/hooks/useContentPositioning/useContentPositioning.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAC;AAEzD,MAAM,WAAW,4BAA4B;IAC3C;;OAEG;IACH,SAAS,CAAC,EAAE,aAAa,CAAC;IAC1B;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;OAEG;IACH,sBAAsB,EAAE,OAAO,CAAC;IAChC;;OAEG;IACH,UAAU,EAAE,KAAK,CAAC,SAAS,CAAC,WAAW,CAAC,CAAC;IACzC;;OAEG;IACH,UAAU,EAAE,KAAK,CAAC,SAAS,CAAC,WAAW,CAAC,CAAC;IACzC;;OAEG;IACH,iBAAiB,CAAC,EAAE,OAAO,GAAG,IAAI,CAAC;IACnC;;OAEG;IACH,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B;;OAEG;IACH,oBAAoB,EAAE,OAAO,CAAC;CAC/B"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as se } from "react/jsx-runtime";
|
|
2
2
|
import { useId as ue, useState as u, useRef as E, useEffect as B, useLayoutEffect as oe } from "react";
|
|
3
|
-
import { c as ne, F as ce } from "../../../../useContentPositioning-
|
|
3
|
+
import { c as ne, F as ce } from "../../../../useContentPositioning-CLU2E_Oz.mjs";
|
|
4
4
|
import { ContextMenuMode as n } from "../../ContextMenu.enums.js";
|
|
5
5
|
import "../../providers/LevelProvider/LevelProvider.js";
|
|
6
6
|
import "../../providers/SubMenuProvider/SubMenuProvider.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useId as Y, useState as f, useRef as T, useEffect as b } from "react";
|
|
2
2
|
import "react/jsx-runtime";
|
|
3
|
-
import "../../../../useContentPositioning-
|
|
3
|
+
import "../../../../useContentPositioning-CLU2E_Oz.mjs";
|
|
4
4
|
import { ContextMenuMode as i } from "../../ContextMenu.enums.js";
|
|
5
5
|
import { useLevelContext as Z } from "../../providers/LevelProvider/LevelProvider.js";
|
|
6
6
|
import "../../providers/SubMenuProvider/SubMenuProvider.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useId as rr, useState as a, useRef as I, useLayoutEffect as tr, useEffect as v } from "react";
|
|
2
2
|
import "react/jsx-runtime";
|
|
3
|
-
import "../../../../useContentPositioning-
|
|
3
|
+
import "../../../../useContentPositioning-CLU2E_Oz.mjs";
|
|
4
4
|
import { ContextMenuMode as l } from "../../ContextMenu.enums.js";
|
|
5
5
|
import { useInheritedArrowColor as er } from "../useInheritedArrowColor/useInheritedArrowColor.js";
|
|
6
6
|
import "../../components/Content/Content.utils.js";
|
package/dist/components/ContextMenu/hooks/useInheritedArrowColor/useInheritedArrowColor.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useInheritedArrowColor.d.ts","sourceRoot":"","sources":["../../../../../src/components/ContextMenu/hooks/useInheritedArrowColor/useInheritedArrowColor.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,sBAAsB,SAC3B,OAAO,cACD,KAAK,CAAC,SAAS,CAAC,cAAc,CAAC,
|
|
1
|
+
{"version":3,"file":"useInheritedArrowColor.d.ts","sourceRoot":"","sources":["../../../../../src/components/ContextMenu/hooks/useInheritedArrowColor/useInheritedArrowColor.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,sBAAsB,SAC3B,OAAO,cACD,KAAK,CAAC,SAAS,CAAC,cAAc,CAAC,kBA2J5C,CAAC"}
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { useState as C, useLayoutEffect as v } from "react";
|
|
2
2
|
const y = (d, a) => {
|
|
3
|
-
const [
|
|
3
|
+
const [f, A] = C(
|
|
4
4
|
null
|
|
5
5
|
);
|
|
6
6
|
return v(() => {
|
|
7
7
|
if (!d)
|
|
8
8
|
return;
|
|
9
|
-
const
|
|
9
|
+
const p = requestAnimationFrame(() => {
|
|
10
10
|
const l = (t) => {
|
|
11
|
-
|
|
12
|
-
},
|
|
13
|
-
var
|
|
11
|
+
A(getComputedStyle(t).backgroundColor);
|
|
12
|
+
}, w = () => {
|
|
13
|
+
var g, h;
|
|
14
14
|
if (!a.current)
|
|
15
15
|
return;
|
|
16
|
-
const t = (
|
|
16
|
+
const t = (g = a.current) == null ? void 0 : g.dataset.side, r = (h = a.current) == null ? void 0 : h.dataset.align;
|
|
17
17
|
if (!t || !r)
|
|
18
18
|
return;
|
|
19
19
|
const u = Array.from(a.current.children);
|
|
@@ -30,7 +30,7 @@ const y = (d, a) => {
|
|
|
30
30
|
};
|
|
31
31
|
let n = null, s = null;
|
|
32
32
|
const c = () => {
|
|
33
|
-
const t =
|
|
33
|
+
const t = w();
|
|
34
34
|
if (!t)
|
|
35
35
|
return;
|
|
36
36
|
l(t), n && n.disconnect(), n = new MutationObserver(() => l(t)), n.observe(t, {
|
|
@@ -44,16 +44,16 @@ const y = (d, a) => {
|
|
|
44
44
|
});
|
|
45
45
|
};
|
|
46
46
|
c();
|
|
47
|
-
const
|
|
48
|
-
return b.observe(
|
|
47
|
+
const b = a.current, m = new MutationObserver(c);
|
|
48
|
+
return b && m.observe(b, {
|
|
49
49
|
attributes: !0,
|
|
50
50
|
attributeFilter: ["data-side", "data-align"]
|
|
51
51
|
}), () => {
|
|
52
|
-
n == null || n.disconnect(), s == null || s.disconnect(),
|
|
52
|
+
n == null || n.disconnect(), s == null || s.disconnect(), m.disconnect();
|
|
53
53
|
};
|
|
54
54
|
});
|
|
55
|
-
return () => cancelAnimationFrame(
|
|
56
|
-
}, [d]),
|
|
55
|
+
return () => cancelAnimationFrame(p);
|
|
56
|
+
}, [d]), f;
|
|
57
57
|
};
|
|
58
58
|
export {
|
|
59
59
|
y as useInheritedArrowColor
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { useState as d, useLayoutEffect as c } from "react";
|
|
2
2
|
import { useContextMenuRootContext as a } from "../../ContextMenu.context.js";
|
|
3
3
|
import "react/jsx-runtime";
|
|
4
|
-
import "../../../../useContentPositioning-
|
|
4
|
+
import "../../../../useContentPositioning-CLU2E_Oz.mjs";
|
|
5
5
|
import "../../providers/LevelProvider/LevelProvider.js";
|
|
6
6
|
import "../../providers/SubMenuProvider/SubMenuProvider.js";
|
|
7
7
|
import "../../components/Content/Content.utils.js";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"usePrevious.d.ts","sourceRoot":"","sources":["../../../../../src/components/ContextMenu/hooks/usePrevious/usePrevious.ts"],"names":[],"mappings":"AAEA,wBAAgB,WAAW,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,GAAG,CAAC,GAAG,SAAS,CAQtD"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ContextMenu as n } from "./ContextMenu.js";
|
|
2
2
|
import { ContextMenuMode as x } from "./ContextMenu.enums.js";
|
|
3
|
-
import "../../useContentPositioning-
|
|
3
|
+
import "../../useContentPositioning-CLU2E_Oz.mjs";
|
|
4
4
|
import { Direction as p } from "./components/Content/Content.enums.js";
|
|
5
5
|
import "./components/Content/Content.utils.js";
|
|
6
6
|
export {
|