@gitlab/ui
Version:
GitLab UI Components
33 lines (28 loc) • 724 B
JavaScript
import { withKnobs, number } from '@storybook/addon-knobs';
import { documentedStoriesOf } from '../../../../documentation/documented_stories';
import readme from './skeleton_loading.md';
import { GlSkeletonLoading } from '../../../../index';
const components = {
GlSkeletonLoading,
};
const template = '<gl-skeleton-loading :lines="lines" />';
function generateProps() {
return {
lines: {
type: Number,
default: number('lines', 3, {
range: true,
min: 1,
max: 3,
step: 1,
}),
},
};
}
documentedStoriesOf('base|skeleton-loading', readme)
.addDecorator(withKnobs)
.add('default', () => ({
props: generateProps(),
components,
template,
}));