import { Meta, Story } from '@storybook/react';
import React from 'react';
import {
  DraggableContainer,
  IDraggableContainerProps,
} from '../../../components/DraggableContainer';
import { RPGUIRoot } from '../../../components/RPGUI/RPGUIRoot';

const meta: Meta = {
  title: 'UI/Containers/Draggable Container',
  component: DraggableContainer,
};

export default meta;

const Template: Story<IDraggableContainerProps> = args => (
  <RPGUIRoot>
    <DraggableContainer {...args} />
  </RPGUIRoot>
);

export const Default = Template.bind({});

Default.args = {
  title: 'Example',
  onCloseButton: () => console.log('closing'),
  children: <p>This is a draggable container!</p>,
};
