silphius/stories/slot.stories.js

67 lines
935 B
JavaScript
Raw Normal View History

2024-06-24 05:00:24 -05:00
import Slot from '@/react-components/slot.jsx';
2024-06-10 22:42:30 -05:00
import DomDecorator from './dom-decorator.jsx';
export default {
title: 'Dom/Inventory/Slot',
component: Slot,
decorators: [
DomDecorator({
style: {
border: '2px solid #999',
lineHeight: 0,
position: 'absolute',
left: '50%',
top: '50%',
transform: 'translate(-50%, -50%)',
},
}),
],
tags: ['autodocs'],
argTypes: {
image: {
control: 'text',
},
qty: {
control: {
type: 'number',
min: 1,
max: 9999,
}
},
},
args: {
2024-06-24 05:00:24 -05:00
source: '/assets/potion',
2024-06-10 22:42:30 -05:00
},
};
export const Single = {
args: {
qty: 1,
},
};
export const OneDigit = {
args: {
qty: 9,
},
};
export const TwoDigit = {
args: {
qty: 99,
},
};
export const ThreeDigit = {
args: {
qty: 999,
},
};
export const FourDigit = {
args: {
qty: 9999,
},
};