Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Work in progress on AmountStep and InfoStep #934

Draft
wants to merge 26 commits into
base: feature/donate-wizard-react
Choose a base branch
from
Draft
Changes from 1 commit
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
d2320b7
Using useIntl hook to fetch translations
Dec 1, 2021
140049a
Basic work and fixes to add the wizard to Storybook
Dec 1, 2021
170b66c
Includes assets to new wizard
Dec 3, 2021
3b1c3ce
Adds relative paths to a bunch of imports on stylesheet files
Dec 3, 2021
3c90d23
Imports more stylesheets on wizard component
Dec 3, 2021
cb56e02
Correctly evaluating when the steps are done and displaying steps bodies
Dec 6, 2021
a2edb83
Styles fixes
Dec 6, 2021
5963119
Fixes gradient on wizard index
Dec 6, 2021
965a83c
Prevents moving to next step using index
Dec 6, 2021
dd6fac9
wip for adding next behavior
Dec 6, 2021
6fba961
Eric does helpy-help
wwahammy Dec 6, 2021
c4bf911
Dispatches action whenever submitting on AmountStep
Dec 7, 2021
382e7ba
Adds custom amount and recurring components to AmountStep
Dec 13, 2021
b0ad970
Adds SingleAmount component and fixes recurring
Dec 15, 2021
66f9f54
Initial work for InfoStep
Dec 15, 2021
902f76e
Transmits amount and recurring information from AmountStep to InfoStep
Dec 16, 2021
38fa8e1
Sets supporter and address fields
Dec 17, 2021
e8cf2db
Add Payment buttons (sepa and card)
Dec 17, 2021
498713d
Using supporter info from state instead of props
Dec 17, 2021
1496b6a
Fix preset recurring
Dec 20, 2021
20a6b3e
Fix eslint errors
Dec 21, 2021
3809942
Use form value to tell whether a button amount was selected instead o…
Dec 21, 2021
7ad1af6
Properly using Formik on fields
Dec 23, 2021
b6a6d3e
Use loading from Formik's isSubmitting state
Dec 23, 2021
1092896
Type fixes and avoid reinitializing AmountStep's Formik
Dec 23, 2021
cd94eb6
wip
Dec 29, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Using supporter info from state instead of props
Clarissa Borges committed Dec 19, 2021
commit 498713d2dfeb438afb63aea8cf1bc94dfa60ca6a
Original file line number Diff line number Diff line change
@@ -128,7 +128,7 @@ function SupporterFields(props: SupporterFieldsProps): JSX.Element {
name="email"
title={emailTitle}
required={props.required.email}
value={props.supporter?.email}
value={supporter?.email}
placeholder={emailTitle}
onChange={
(e) => {
@@ -143,7 +143,7 @@ function SupporterFields(props: SupporterFieldsProps): JSX.Element {
placeholder={firstNameTitle}
required={props.required.firstName}
title={firstNameTitle}
value={props.supporter?.firstName}
value={supporter?.firstName}
onChange={
(e) => {
setSupporterFields('firstName', e.target.value);
@@ -157,7 +157,7 @@ function SupporterFields(props: SupporterFieldsProps): JSX.Element {
placeholder={lastNameTitle}
required={props.required.lastName}
title={lastNameTitle}
value={props.supporter?.lastName}
value={supporter?.lastName}
onChange={
(e) => {
setSupporterFields('lastName', e.target.value);
@@ -171,7 +171,7 @@ function SupporterFields(props: SupporterFieldsProps): JSX.Element {
placeholder={phoneTitle}
required={props.required.phone}
title={phoneTitle}
value={props.supporter?.phone}
value={supporter?.phone}
onChange={
(e) => {
setSupporterFields('phone', e.target.value);
Original file line number Diff line number Diff line change
@@ -92,7 +92,6 @@ function useDonateWizardState(initialState: DonateWizardOutputState): [DonateWiz
const [donateWizardState, stateDispatch] = useReducer(wizardOutputReducer, initialState);

const reducerAction = (action: ActionType) => {
console.log(action);
switch (action.type) {
case 'setAmount': {
stateDispatch(action);