Files
Web-Frontend/client/src/components/layout/Canvas/Widget.jsx
T

19 lines
491 B
React
Raw Normal View History

2025-07-22 11:58:10 -07:00
import { useSlotRecipe, chakra } from "@chakra-ui/react"
export default function Widget({ title }) {
2025-07-22 11:58:10 -07:00
const recipe = useSlotRecipe({ key: "widget" });
const styles = recipe();
return (
2025-07-22 14:55:28 -07:00
<chakra.div className="react-resizable-handle-se">
<chakra.div css={styles.header} className="widget-handle" >
2025-07-22 11:58:10 -07:00
{title}
</chakra.div>
2025-07-22 14:55:28 -07:00
<chakra.div css={styles.canvas} >
2025-07-22 11:58:10 -07:00
This is the widget content - drag or resize me!
</chakra.div>
</chakra.div>
);
}