import React from "react";
import { StoryFn, Meta } from "@storybook/react";
import { Content, Root, Tabs } from "./index";
import { ScoreCategories, scoreCategories } from "../../main";

export default {
  title: "Unofficial/ScoreCategoryTabs",
  component: Root,
  argTypes: {
    currentTab: {
      options: ["education", "nature"],
      control: { type: "radio" },
    },
  },
} as Meta<typeof Root>;

const Template: StoryFn<typeof Root> = (args) => (
  <Root {...args}>
    <Tabs category={scoreCategories} />
    <Content options={{ value: "nature" }} />
  </Root>
);

export const Default = Template.bind({});
Default.args = {
  options: {
    defaultTab: "commute",
  },
};
