@edux-design/popovers 0.0.1 → 0.0.2
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/CHANGELOG.md +6 -0
- package/package.json +1 -1
- package/src/elements/Popover.jsx +9 -6
package/CHANGELOG.md
CHANGED
package/package.json
CHANGED
package/src/elements/Popover.jsx
CHANGED
|
@@ -109,6 +109,7 @@ export const PopoverContent = forwardRef(
|
|
|
109
109
|
alignOffset = 0,
|
|
110
110
|
avoidCollisions = true,
|
|
111
111
|
forceMount = false,
|
|
112
|
+
showArrow = false,
|
|
112
113
|
contentProps = {},
|
|
113
114
|
...restProps
|
|
114
115
|
},
|
|
@@ -135,17 +136,19 @@ export const PopoverContent = forwardRef(
|
|
|
135
136
|
alignOffset={alignOffset}
|
|
136
137
|
avoidCollisions={avoidCollisions}
|
|
137
138
|
forceMount={forceMount}
|
|
138
|
-
className={cx(
|
|
139
|
+
className={cx(positioning, className, "relative")}
|
|
139
140
|
style={style}
|
|
140
141
|
{...contentProps}
|
|
141
142
|
{...restProps}
|
|
142
143
|
>
|
|
143
144
|
{children}
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
145
|
+
{showArrow && (
|
|
146
|
+
<PopoverPrimitive.Arrow
|
|
147
|
+
className="fill-fg-base"
|
|
148
|
+
width={12}
|
|
149
|
+
height={8}
|
|
150
|
+
/>
|
|
151
|
+
)}
|
|
149
152
|
</PopoverPrimitive.Content>
|
|
150
153
|
</PopoverPortal>
|
|
151
154
|
);
|