{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "resizable-story",
  "title": "Resizable Story",
  "author": "Lloyd Richards <lloyd.d.richards@gmail.com>",
  "description": "Interactive Storybook stories demonstrating resizable component usage and variants",
  "dependencies": [
    "react-aria-components"
  ],
  "registryDependencies": [
    "resizable"
  ],
  "files": [
    {
      "path": "registry/ui/resizable-story/resizable-aria.stories.tsx",
      "content": "import type { Meta, StoryObj } from \"@storybook/nextjs-vite\";\n\nimport {\n  ResizableHandle,\n  ResizablePanel,\n  ResizablePanelGroup,\n} from \"@/components/ui/resizable\";\nimport { expect, fn, userEvent, waitFor } from \"storybook/test\";\n/**\n * Accessible resizable panel groups and layouts with keyboard support.\n */\nconst meta: Meta<typeof ResizablePanelGroup> = {\n  id: \"ui-aria-resizablepanelgroup\",\n  title: \"ui/ResizablePanelGroup\",\n  component: ResizablePanelGroup,\n  tags: [\"autodocs\"],\n  argTypes: {\n    onLayoutChange: {\n      control: false,\n    },\n  },\n  args: {\n    onLayoutChange: fn(),\n    className: \"max-w-96 rounded-lg border\",\n    orientation: \"horizontal\",\n  },\n  render: (args) => (\n    <ResizablePanelGroup {...args}>\n      <ResizablePanel defaultSize=\"50%\">\n        <div className=\"flex h-[200px] items-center justify-center p-6\">\n          <span className=\"font-semibold\">One</span>\n        </div>\n      </ResizablePanel>\n      <ResizableHandle />\n      <ResizablePanel defaultSize=\"50%\">\n        <ResizablePanelGroup orientation=\"vertical\">\n          <ResizablePanel defaultSize=\"25%\">\n            <div className=\"flex h-full items-center justify-center p-6\">\n              <span className=\"font-semibold\">Two</span>\n            </div>\n          </ResizablePanel>\n          <ResizableHandle />\n          <ResizablePanel defaultSize=\"75%\">\n            <div className=\"flex h-full items-center justify-center p-6\">\n              <span className=\"font-semibold\">Three</span>\n            </div>\n          </ResizablePanel>\n        </ResizablePanelGroup>\n      </ResizablePanel>\n    </ResizablePanelGroup>\n  ),\n} satisfies Meta<typeof ResizablePanelGroup>;\n\nexport default meta;\n\ntype Story = StoryObj<typeof meta>;\n\n/**\n * The default form of the resizable panel group.\n */\nexport const Default: Story = {};\n\n/** Resize the first panel with the keyboard. */\nexport const KeyboardResize: Story = {\n  tags: [\"!dev\", \"!autodocs\"],\n  play: async ({ canvas }) => {\n    const [handle] = canvas.getAllByRole(\"separator\");\n    const initial = Number(handle.getAttribute(\"aria-valuenow\"));\n    handle.focus();\n    await userEvent.keyboard(\"{ArrowRight}\");\n    await waitFor(() =>\n      expect(Number(handle.getAttribute(\"aria-valuenow\"))).toBeGreaterThan(\n        initial,\n      ),\n    );\n  },\n};\n",
      "type": "registry:component",
      "target": "@ui/resizable.stories.tsx"
    }
  ],
  "categories": [
    "ui",
    "storybook",
    "resizable",
    "layout"
  ],
  "type": "registry:component"
}