import type { StoryObj } from "@storybook/vue3"; import { action } from "@storybook/addon-actions"; import { fn } from "@storybook/test"; import MtButton from "./mt-button.vue"; import MtIcon from "@/components/icons-media/mt-icon/mt-icon.vue"; import type { SlottedMeta } from "@/_internal/story-helper"; export type MtButtonMeta = SlottedMeta; export default { title: "Components/Form/mt-button", component: MtButton, args: { default: "Button", variant: "primary", size: "small", disabled: false, square: false, block: false, isLoading: false, ghost: false, link: undefined, click: fn(action("click")), }, argTypes: { showFrontIcon: { control: "boolean", description: "Show/hide front icon", defaultValue: false, }, showBackIcon: { control: "boolean", description: "Show/hide back icon", defaultValue: false, }, }, render: (args) => ({ components: { MtButton, MtIcon }, setup() { return { args, }; }, template: ` {{ args.default}} `, }), } as MtButtonMeta; export type MtButtonStory = StoryObj; export const DefaultStory: MtButtonStory = { name: "mt-button", };