diff --git a/frontend/src/metabase/components/EntityMenu.stories.tsx b/frontend/src/metabase/components/EntityMenu.stories.tsx new file mode 100644 index 0000000000000000000000000000000000000000..6ac25efaea7decb9dccbdc6af01c016e4df6842a --- /dev/null +++ b/frontend/src/metabase/components/EntityMenu.stories.tsx @@ -0,0 +1,37 @@ +import React from "react"; +import type { ComponentStory } from "@storybook/react"; +import EntityMenu from "./EntityMenu"; + +export default { + title: "Components/Entity Menu", + component: EntityMenu, +}; + +const Template: ComponentStory<typeof EntityMenu> = args => { + return <EntityMenu {...args} />; +}; + +const items = [ + { + icon: "link", + title: "Option 1 - External link", + link: "https://google.com", + externalLink: true, + }, + { + icon: "link", + title: "Option 2 - Relative link", + link: "/", + }, + { + icon: "bolt", + title: "Option 3 - Action", + action: () => alert("Yo"), + }, +]; + +export const Default = Template.bind({}); +Default.args = { + items, + trigger: <span>Click Me</span>, +};