23 lines
516 B
JavaScript
23 lines
516 B
JavaScript
import React from "react";
|
|
import { useModalStore } from "../../../stores/modalStore.js";
|
|
import PinnedMessagesPanel from "../PinnedMessagesPanel.jsx";
|
|
|
|
export function PinnedModal() {
|
|
const { isOpen, type, onClose } = useModalStore();
|
|
|
|
if (!isOpen || type !== "pinned") return null;
|
|
|
|
return (
|
|
<div
|
|
style={{
|
|
position: "fixed",
|
|
inset: 0,
|
|
background: "rgba(0,0,0,0.3)",
|
|
zIndex: 998,
|
|
}}
|
|
onClick={onClose}
|
|
>
|
|
<PinnedMessagesPanel />
|
|
</div>
|
|
);
|
|
}
|