@wistia/ui 0.15.13-beta.e65c0481.a780530 → 0.15.13
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 +4 -14
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +1 -5
- package/dist/index.d.ts +1 -5
- package/dist/index.mjs +4 -14
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
2
|
/*
|
|
3
|
-
* @license @wistia/ui v0.15.13
|
|
3
|
+
* @license @wistia/ui v0.15.13
|
|
4
4
|
*
|
|
5
5
|
* Copyright (c) 2024-2025, Wistia, Inc. and its affiliates.
|
|
6
6
|
*
|
|
@@ -13039,7 +13039,6 @@ var Combobox2 = ({
|
|
|
13039
13039
|
// src/components/ContextMenu/ContextMenu.tsx
|
|
13040
13040
|
var import_type_guards43 = require("@wistia/type-guards");
|
|
13041
13041
|
var import_react61 = require("react");
|
|
13042
|
-
var import_react_dom = require("react-dom");
|
|
13043
13042
|
|
|
13044
13043
|
// src/components/Menu/Menu.tsx
|
|
13045
13044
|
var import_react_dropdown_menu = require("@radix-ui/react-dropdown-menu");
|
|
@@ -13709,8 +13708,7 @@ var ContextMenu = ({
|
|
|
13709
13708
|
triggerRef,
|
|
13710
13709
|
children,
|
|
13711
13710
|
side = "bottom",
|
|
13712
|
-
onRequestClose = () => null
|
|
13713
|
-
compact = false
|
|
13711
|
+
onRequestClose = () => null
|
|
13714
13712
|
}) => {
|
|
13715
13713
|
const [isRightClicked, setIsRightClicked] = (0, import_react61.useState)(false);
|
|
13716
13714
|
const [menuPosition, setMenuPosition] = (0, import_react61.useState)(position ?? { x: 0, y: 0 });
|
|
@@ -13730,13 +13728,9 @@ var ContextMenu = ({
|
|
|
13730
13728
|
return () => null;
|
|
13731
13729
|
}, [position, triggerRef]);
|
|
13732
13730
|
const isOpen = (0, import_type_guards43.isNotNil)(position) || isRightClicked;
|
|
13733
|
-
|
|
13734
|
-
return null;
|
|
13735
|
-
}
|
|
13736
|
-
const menu = /* @__PURE__ */ (0, import_jsx_runtime267.jsx)(
|
|
13731
|
+
return isOpen ? /* @__PURE__ */ (0, import_jsx_runtime267.jsx)(
|
|
13737
13732
|
Menu,
|
|
13738
13733
|
{
|
|
13739
|
-
compact,
|
|
13740
13734
|
isOpen,
|
|
13741
13735
|
onOpenChange: (next) => {
|
|
13742
13736
|
setIsRightClicked(next);
|
|
@@ -13762,11 +13756,7 @@ var ContextMenu = ({
|
|
|
13762
13756
|
),
|
|
13763
13757
|
children
|
|
13764
13758
|
}
|
|
13765
|
-
);
|
|
13766
|
-
if ((0, import_type_guards43.isNotNil)(triggerRef)) {
|
|
13767
|
-
return (0, import_react_dom.createPortal)(menu, document.body);
|
|
13768
|
-
}
|
|
13769
|
-
return menu;
|
|
13759
|
+
) : null;
|
|
13770
13760
|
};
|
|
13771
13761
|
|
|
13772
13762
|
// src/components/DataCards/DataCard.tsx
|