@hyperbridge/ui 0.0.21 → 0.0.22
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.mjs +25 -12
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -4190,24 +4190,37 @@ var WalletHeaderContentBlur = React14.forwardRef((_a, ref) => {
|
|
|
4190
4190
|
var _b = _a, { className, children, asChild = false } = _b, props = __objRest(_b, ["className", "children", "asChild"]);
|
|
4191
4191
|
const { show: open, setShow } = useWalletHeader();
|
|
4192
4192
|
const Comp = asChild ? Slot10 : "div";
|
|
4193
|
-
|
|
4193
|
+
const handleClose = (e) => {
|
|
4194
|
+
e == null ? void 0 : e.stopPropagation();
|
|
4195
|
+
setShow(false);
|
|
4196
|
+
};
|
|
4197
|
+
const handleKeyDown = (e) => {
|
|
4198
|
+
if (["Enter", " "].includes(e.key)) handleClose(e);
|
|
4199
|
+
};
|
|
4200
|
+
return /* @__PURE__ */ jsxs29(
|
|
4194
4201
|
Comp,
|
|
4195
4202
|
__spreadProps(__spreadValues({
|
|
4196
4203
|
ref,
|
|
4197
4204
|
className: cn(
|
|
4198
|
-
"
|
|
4199
|
-
|
|
4200
|
-
"opacity-15 filter blur-[2px]": open
|
|
4201
|
-
},
|
|
4205
|
+
"relative pt-[1rem] transition-all",
|
|
4206
|
+
open && "opacity-15 blur-[2px]",
|
|
4202
4207
|
className
|
|
4203
|
-
)
|
|
4204
|
-
onClick: (e) => {
|
|
4205
|
-
var _a2;
|
|
4206
|
-
if (open) setShow(false);
|
|
4207
|
-
(_a2 = props.onClick) == null ? void 0 : _a2.call(props, e);
|
|
4208
|
-
}
|
|
4208
|
+
)
|
|
4209
4209
|
}, props), {
|
|
4210
|
-
children
|
|
4210
|
+
children: [
|
|
4211
|
+
open && /* @__PURE__ */ jsx41(
|
|
4212
|
+
"div",
|
|
4213
|
+
{
|
|
4214
|
+
className: "absolute inset-0 z-10",
|
|
4215
|
+
onClick: handleClose,
|
|
4216
|
+
onKeyDown: handleKeyDown,
|
|
4217
|
+
tabIndex: 0,
|
|
4218
|
+
role: "button",
|
|
4219
|
+
"aria-label": "Close wallet header"
|
|
4220
|
+
}
|
|
4221
|
+
),
|
|
4222
|
+
children
|
|
4223
|
+
]
|
|
4211
4224
|
})
|
|
4212
4225
|
);
|
|
4213
4226
|
});
|