import { storiesOf } from '@storybook/vue' import { withA11y } from '@storybook/addon-a11y' import RegistrationSlider from './RegistrationSlider.vue' import helpers from '~/storybook/helpers' helpers.init() storiesOf('RegistrationSlider', module) .addDecorator(withA11y) .addDecorator(helpers.layout) .add('invite-code empty', () => ({ components: { RegistrationSlider }, store: helpers.store, data: () => ({}), template: ` `, })) .add('invite-code with data', () => ({ components: { RegistrationSlider }, store: helpers.store, data: () => ({ overwriteSliderData: { collectedInputData: { inviteCode: 'IN1T6Y', email: 'wolle.huss@pjannto.com', emailSend: true, nonce: 'NTRSCZ', name: 'Wolle', password: 'Hello', passwordConfirmation: 'Hello', about: `Hey`, termsAndConditionsAgreedVersion: null, termsAndConditionsConfirmed: true, dataPrivacy: true, minimumAge: true, noCommercial: true, noPolitical: true, locale: null, }, }, }), template: ` `, })) .add('public-registration empty', () => ({ components: { RegistrationSlider }, store: helpers.store, data: () => ({}), template: ` `, })) .add('public-registration with data', () => ({ components: { RegistrationSlider }, store: helpers.store, data: () => ({ overwriteSliderData: { collectedInputData: { inviteCode: null, email: 'wolle.huss@pjannto.com', emailSend: true, nonce: 'NTRSCZ', name: 'Wolle', password: 'Hello', passwordConfirmation: 'Hello', about: `Hey`, termsAndConditionsAgreedVersion: null, termsAndConditionsConfirmed: true, dataPrivacy: true, minimumAge: true, noCommercial: true, noPolitical: true, locale: null, }, }, }), template: ` `, })) .add('invite-mail empty', () => ({ components: { RegistrationSlider }, store: helpers.store, data: () => ({ overwriteSliderData: { collectedInputData: { inviteCode: null, email: 'wolle.huss@pjannto.com', emailSend: true, nonce: null, name: null, password: null, passwordConfirmation: null, about: null, termsAndConditionsAgreedVersion: null, termsAndConditionsConfirmed: null, dataPrivacy: null, minimumAge: null, noCommercial: null, noPolitical: null, locale: null, }, }, }), template: ` `, })) .add('invite-mail with data', () => ({ components: { RegistrationSlider }, store: helpers.store, data: () => ({ overwriteSliderData: { collectedInputData: { inviteCode: null, email: 'wolle.huss@pjannto.com', emailSend: null, nonce: 'NTRSCZ', name: 'Wolle', password: 'Hello', passwordConfirmation: 'Hello', about: `Hey`, termsAndConditionsAgreedVersion: null, termsAndConditionsConfirmed: true, dataPrivacy: true, minimumAge: true, noCommercial: true, noPolitical: true, locale: null, }, }, }), template: ` `, }))