Skip to content

Commit e0b4a22

Browse files
committed
nit
1 parent 9545569 commit e0b4a22

2 files changed

Lines changed: 21 additions & 29 deletions

File tree

app/components/Button/Base.stories.ts

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
import type { Meta, StoryObj } from '@nuxtjs/storybook'
2-
import ButtonBase from './Base.vue'
2+
import Component from './Base.vue'
33

44
const meta = {
5-
component: ButtonBase,
5+
component: Component,
66
tags: ['autodocs'],
7-
} satisfies Meta<typeof ButtonBase>
7+
} satisfies Meta<typeof Component>
88

99
export default meta
1010
type Story = StoryObj<typeof meta>
@@ -15,11 +15,11 @@ export const Primary: Story = {
1515
size: 'medium',
1616
},
1717
render: args => ({
18-
components: { ButtonBase },
18+
components: { Component },
1919
setup() {
2020
return { args }
2121
},
22-
template: '<ButtonBase v-bind="args">Primary Button</ButtonBase>',
22+
template: '<Component v-bind="args">Primary Button</Component>',
2323
}),
2424
}
2525

@@ -29,11 +29,11 @@ export const Secondary: Story = {
2929
size: 'medium',
3030
},
3131
render: args => ({
32-
components: { ButtonBase },
32+
components: { Component },
3333
setup() {
3434
return { args }
3535
},
36-
template: '<ButtonBase v-bind="args">Secondary Button</ButtonBase>',
36+
template: '<Component v-bind="args">Secondary Button</Component>',
3737
}),
3838
}
3939

@@ -43,11 +43,11 @@ export const Small: Story = {
4343
size: 'small',
4444
},
4545
render: args => ({
46-
components: { ButtonBase },
46+
components: { Component },
4747
setup() {
4848
return { args }
4949
},
50-
template: '<ButtonBase v-bind="args">Small Button</ButtonBase>',
50+
template: '<Component v-bind="args">Small Button</Component>',
5151
}),
5252
}
5353

@@ -58,11 +58,11 @@ export const Disabled: Story = {
5858
disabled: true,
5959
},
6060
render: args => ({
61-
components: { ButtonBase },
61+
components: { Component },
6262
setup() {
6363
return { args }
6464
},
65-
template: '<ButtonBase v-bind="args">Disabled Button</ButtonBase>',
65+
template: '<Component v-bind="args">Disabled Button</Component>',
6666
}),
6767
}
6868

@@ -73,11 +73,11 @@ export const WithIcon: Story = {
7373
classicon: 'i-carbon:search',
7474
},
7575
render: args => ({
76-
components: { ButtonBase },
76+
components: { Component },
7777
setup() {
7878
return { args }
7979
},
80-
template: '<ButtonBase v-bind="args">Search</ButtonBase>',
80+
template: '<Component v-bind="args">Search</Component>',
8181
}),
8282
}
8383

@@ -88,11 +88,11 @@ export const WithKeyboardShortcut: Story = {
8888
ariaKeyshortcuts: '/',
8989
},
9090
render: args => ({
91-
components: { ButtonBase },
91+
components: { Component },
9292
setup() {
9393
return { args }
9494
},
95-
template: '<ButtonBase v-bind="args">Search</ButtonBase>',
95+
template: '<Component v-bind="args">Search</Component>',
9696
}),
9797
}
9898

@@ -103,10 +103,10 @@ export const Block: Story = {
103103
block: true,
104104
},
105105
render: args => ({
106-
components: { ButtonBase },
106+
components: { Component },
107107
setup() {
108108
return { args }
109109
},
110-
template: '<ButtonBase v-bind="args">Full Width Button</ButtonBase>',
110+
template: '<Component v-bind="args">Full Width Button</Component>',
111111
}),
112112
}

app/components/Button/Base.vue

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
<script setup lang="ts">
22
const props = withDefaults(
33
defineProps<{
4-
/**
5-
* Whether the button is disabled
6-
*/
4+
/** Whether the button is disabled */
75
disabled?: boolean
86
/**
97
* HTML button type attribute
@@ -20,17 +18,11 @@ const props = withDefaults(
2018
* @default "medium"
2119
*/
2220
size?: 'small' | 'medium'
23-
/**
24-
* Keyboard shortcut hint
25-
*/
21+
/** Keyboard shortcut hint */
2622
ariaKeyshortcuts?: string
27-
/**
28-
* Whether the button should take full width
29-
*/
23+
/** Whether the button should take full width */
3024
block?: boolean
31-
/**
32-
* Icon class (e.g., i-carbon-add)
33-
*/
25+
/** Icon class (e.g., i-carbon-add) */
3426
classicon?: string
3527
}>(),
3628
{

0 commit comments

Comments
 (0)