<script>
  import { Meta, Template, Story } from '@storybook/addon-svelte-csf';
  import ProsemirrorEditor from 'prosemirror-svelte';
</script>

<Meta
  title="Example/Editor"
  component={ProsemirrorEditor}
  argTypes={{
    label: { control: 'text' },
    primary: { control: 'boolean' },
    backgroundColor: { control: 'color' },
    size: {
      control: { type: 'select', options: ['xs', 'sm', 'md', 'lg'] }
    },
    onClick: { action: 'onClick' }
  }}
/>

<Template let:args>
  <ProsemirrorEditor {...args} on:click={args.onClick} />
</Template>

<Story
  name="Base Editor"
  args={{
    primary: true,
    label: 'Editor'
  }}
/>
