"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),i=require("react"),t=require("../index-DEZRGktf.js"),d=require("lucide-react");require("react-router-dom");require("react-dom");const p=()=>{const[r,s]=i.useState(!1),[o,n]=i.useState(!1),[,a]=i.useState("sidebar");return e.jsxs(e.Fragment,{children:[e.jsx(t.HeroCard,{title:"Drawer",description:`A drawer component that slides in from the side, supporting both
          simple sidebar and sidebar-menu variants.`,icon:e.jsx("div",{className:"w-16 h-16 sm:w-20 sm:h-20 md:w-24 md:h-24 bg-linear-to-br from-amber-600 to-orange-500 rounded-full flex items-center justify-center shadow-lg",children:e.jsx(d.PanelRightOpen,{className:"w-8 h-8 sm:w-10 sm:h-10 md:w-12 md:h-12 text-white filter drop-shadow-lg"})})}),e.jsx(t.CardContainer,{className:"overflow-hidden",children:e.jsx(t.CardTitle,{title:"Basic Examples",className:"mt-2 mb-2",children:e.jsx("div",{className:"w-full p-4 sm:p-6",children:e.jsxs("div",{className:"space-y-4",children:[e.jsxs(t.CardContainer,{className:"p-4",children:[e.jsx(t.Typography,{tag:"h5",className:"mb-3",children:"Left Position"}),e.jsx(t.Button,{onClick:()=>{a("sidebar"),s(!0)},children:"Open Left Drawer"}),e.jsx(t.Drawer,{isOpen:r,setIsOpen:s,type:"sidebar",title:"Sidebar Title",position:"left",children:e.jsx(t.Typography,{tag:"p",children:"Sidebar content goes here"})})]}),e.jsxs(t.CardContainer,{className:"p-4",children:[e.jsx(t.Typography,{tag:"h5",className:"mb-3",children:"Right Position"}),e.jsx(t.Button,{onClick:()=>{a("sidebar"),n(!0)},children:"Open Right Drawer"}),e.jsx(t.Drawer,{isOpen:o,setIsOpen:n,type:"sidebar",position:"right",title:"Right Drawer",children:e.jsx(t.Typography,{tag:"p",children:"Content on the right"})})]})]})})})}),e.jsx(t.PropPlayground,{componentName:"Drawer",defaultValues:{isOpen:r,setIsOpen:s,position:"left",backdrop:!0},excludeProps:["setIsOpen","onClose","actionContent","logo","menuItems","type"],children:l=>e.jsx("div",{style:{position:"relative",height:300,overflow:"hidden"},children:e.jsx(t.Drawer,{...l,setIsOpen:s,isOpen:r,title:"Drawer Preview",children:e.jsx("p",{className:"text-sm p-4",children:"Drawer content"})})})}),e.jsx(t.AutoPropsTable,{componentName:"Drawer"}),e.jsx(t.CardContainer,{className:"overflow-hidden",children:e.jsx(t.CardTitle,{title:"Code Example",className:"mt-2 mb-2",children:e.jsx("div",{className:"w-full p-4 sm:p-6",children:e.jsx(t.CodeBlock,{language:"tsx",code:`import { Drawer, Button } from '@e-burgos/tucu-ui';
import { useState } from 'react';

function MyComponent() {
  const [isOpen, setIsOpen] = useState(false);

  return (
    <>
      <Button onClick={() => setIsOpen(true)}>Open Drawer</Button>
      <Drawer
        isOpen={isOpen}
        setIsOpen={setIsOpen}
        type="sidebar"
        title="Drawer Title"
      >
        <div>Drawer content</div>
      </Drawer>
    </>
  );
}

// Right position
<Drawer
  isOpen={isOpen}
  setIsOpen={setIsOpen}
  type="sidebar"
  position="right"
  title="Right Drawer"
>
  <div>Content</div>
</Drawer>

// Without backdrop
<Drawer
  isOpen={isOpen}
  setIsOpen={setIsOpen}
  type="sidebar"
  backdrop={false}
>
  <div>Content</div>
</Drawer>`})})})})]})};exports.default=p;
