Files
nimbus/resources/js/components/base/input/AppInput.stories.ts
Mazen Touati 35b96042f0 refactor: solidify the FE codebase and improve UI consistency (#45)
* chore: add storybook

* chore: unify FE codeabse

* chore: update eslint rules

* chore: harmonize the use of "subtle" color

* chore: remove an extra sidebar rail

* refactor: make panel items more consistent

* chore: cleanups after merging new code from base

* refactor: refine composables

* fix: add lost import

* chore: make icon style consistent

* fix: don't show empty "supported" methods

* refactor: solidify select items
2026-01-25 14:30:07 +01:00

52 lines
1.1 KiB
TypeScript

import type { Meta, StoryObj } from '@storybook/vue3';
import AppInput from './AppInput.vue';
const meta: Meta<typeof AppInput> = {
title: 'Base/Input',
component: AppInput,
tags: ['autodocs'],
argTypes: {
type: {
control: 'select',
options: ['text', 'password', 'email', 'number', 'tel', 'url'],
},
},
};
export default meta;
type Story = StoryObj<typeof AppInput>;
export const Default: Story = {
args: {
modelValue: '',
placeholder: 'Type something...',
},
render: args => ({
components: { AppInput },
setup: () => ({ args }),
template: '<AppInput v-bind="args" />',
}),
};
export const Password: Story = {
args: {
type: 'password',
modelValue: 'secret',
},
};
export const Disabled: Story = {
args: {
disabled: true,
modelValue: 'Cannot edit this',
},
};
export const Toolbar: Story = {
args: {
variant: 'toolbar',
placeholder: 'Toolbar input...',
class: 'border-b',
},
};