import React from 'react'; import Button from '../../Button'; import { createSandboxStory, globalScope, } from '../../../.storybook/components/sandbox/SandboxEditor'; import SlidingPanel, { type SlidingPanelProps } from '..'; export default { component: SlidingPanel, title: 'Dialogs/SlidingPanel', argTypes: { position: { control: 'select', options: ['left', 'right', 'top', 'bottom'], }, }, parameters: { docs: { source: { type: 'code' }, }, }, decorators: [ (Story: any) => (
), ], }; export const Sandbox = createSandboxStory({ code: `const App = () => { const [open, setOpen] = React.useState(false); return (
Panel content slides in from the chosen position.
); };`, scope: globalScope, }); export const Basic = function Render(args: SlidingPanelProps) { const [open, setOpen] = React.useState(false); return (
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to
); }; Basic.args = { position: 'top', };