import { action } from "@storybook/addon-actions";
import { storiesOf } from "@storybook/react";
import { LinkEditorModal } from "../LinkEditorModal";
import React from "react";

storiesOf(`Link/${LinkEditorModal.name}`, module)
  .add("Editable", () => (
    <LinkEditorModal
      editable={true}
      text="add links to text using ⌘ + K"
      url="https://dovetailapp.com/help"
      onDismiss={action("onDismiss")}
      onSave={action("onSave")}
    />
  ))
  .add("Not editable", () => (
    <LinkEditorModal
      editable={false}
      text="add links to text using ⌘ + K"
      url="https://dovetailapp.com/help"
      onDismiss={action("onDismiss")}
      onSave={action("onSave")}
    />
  ));
