diff --git a/src/lib/components/examples/Recipies.svelte b/src/lib/components/examples/Recipies.svelte index 7383344..0f49c14 100644 --- a/src/lib/components/examples/Recipies.svelte +++ b/src/lib/components/examples/Recipies.svelte @@ -43,32 +43,35 @@ start: { meta: { title: 'Welcome!', - description: 'Start your registration process by clicking next.' + description: 'Start your registration process by clicking next.', + buttonLabel: 'Start' }, - on: { NEXT: 'nameInput' } + on: { NEXT: 'name' } }, - nameInput: { + name: { meta: { title: 'Name Input', description: 'Please enter your name.', - fieldLabel: 'Name' + fieldLabel: 'Name', + buttonLabel: 'Next' }, entry: assign({ constraints: (context) => constraints.name || {} }), on: { NEXT: { - target: 'emailInput', + target: 'email', actions: ['setName'] }, BACK: 'start' } }, - emailInput: { + email: { meta: { title: 'Email Input', description: 'Please enter your email address.', - fieldLabel: 'Email' + fieldLabel: 'Email', + buttonLabel: 'Next' }, entry: assign({ constraints: (context) => constraints.email || {} @@ -78,13 +81,14 @@ target: 'summary', actions: ['setEmail'] }, - BACK: 'nameInput' + BACK: 'name' } }, summary: { meta: { title: 'Summary', - description: 'Review your details before submission.' + description: 'Review your details before submission.', + buttonLabel: 'test' }, on: { SUBMIT: 'submitting' @@ -107,7 +111,8 @@ }, success: { meta: { - title: 'Success' + title: 'Success', + buttonLabel: 'Start again' }, on: { RESTART: 'start' @@ -115,7 +120,8 @@ }, failure: { meta: { - title: 'Submission Failed' + title: 'Submission Failed', + buttonLabel: 'Restart' }, on: { RESTART: 'start' @@ -163,7 +169,7 @@ - {:else if $state.value === 'nameInput'} + {:else if $state.value === 'name'}