diff options
author | 2019-09-02 11:28:39 +0200 | |
---|---|---|
committer | 2019-09-02 11:28:39 +0200 | |
commit | 88a89ea3eb88f76ff9a2b9b856db855a7e15a46c (patch) | |
tree | db1447567b31f227f28a78710e24fffaca4eb582 /src/components | |
parent | fix missing icons (diff) | |
download | ferdium-app-88a89ea3eb88f76ff9a2b9b856db855a7e15a46c.tar.gz ferdium-app-88a89ea3eb88f76ff9a2b9b856db855a7e15a46c.tar.zst ferdium-app-88a89ea3eb88f76ff9a2b9b856db855a7e15a46c.zip |
Remove user type from signup
Diffstat (limited to 'src/components')
-rw-r--r-- | src/components/auth/Signup.js | 30 | ||||
-rw-r--r-- | src/components/subscription/TrialForm.js | 19 |
2 files changed, 22 insertions, 27 deletions
diff --git a/src/components/auth/Signup.js b/src/components/auth/Signup.js index d9b83eeb8..7724bb908 100644 --- a/src/components/auth/Signup.js +++ b/src/components/auth/Signup.js | |||
@@ -31,10 +31,10 @@ const messages = defineMessages({ | |||
31 | id: 'signup.email.label', | 31 | id: 'signup.email.label', |
32 | defaultMessage: '!!!Email address', | 32 | defaultMessage: '!!!Email address', |
33 | }, | 33 | }, |
34 | companyLabel: { | 34 | // companyLabel: { |
35 | id: 'signup.company.label', | 35 | // id: 'signup.company.label', |
36 | defaultMessage: '!!!Company', | 36 | // defaultMessage: '!!!Company', |
37 | }, | 37 | // }, |
38 | passwordLabel: { | 38 | passwordLabel: { |
39 | id: 'signup.password.label', | 39 | id: 'signup.password.label', |
40 | defaultMessage: '!!!Password', | 40 | defaultMessage: '!!!Password', |
@@ -79,20 +79,6 @@ export default @observer class Signup extends Component { | |||
79 | 79 | ||
80 | form = new Form({ | 80 | form = new Form({ |
81 | fields: { | 81 | fields: { |
82 | accountType: { | ||
83 | value: 'individual', | ||
84 | validators: [required], | ||
85 | options: [{ | ||
86 | value: 'individual', | ||
87 | label: 'Individual', | ||
88 | }, { | ||
89 | value: 'non-profit', | ||
90 | label: 'Non-Profit', | ||
91 | }, { | ||
92 | value: 'company', | ||
93 | label: 'Company', | ||
94 | }], | ||
95 | }, | ||
96 | firstname: { | 82 | firstname: { |
97 | label: this.context.intl.formatMessage(messages.firstnameLabel), | 83 | label: this.context.intl.formatMessage(messages.firstnameLabel), |
98 | value: '', | 84 | value: '', |
@@ -108,10 +94,6 @@ export default @observer class Signup extends Component { | |||
108 | value: '', | 94 | value: '', |
109 | validators: [required, email], | 95 | validators: [required, email], |
110 | }, | 96 | }, |
111 | organization: { | ||
112 | label: this.context.intl.formatMessage(messages.companyLabel), | ||
113 | value: '', // TODO: make required when accountType: company | ||
114 | }, | ||
115 | password: { | 97 | password: { |
116 | label: this.context.intl.formatMessage(messages.passwordLabel), | 98 | label: this.context.intl.formatMessage(messages.passwordLabel), |
117 | value: '', | 99 | value: '', |
@@ -151,7 +133,6 @@ export default @observer class Signup extends Component { | |||
151 | In Dev Mode your data is not persistent. Please use the live app for accesing the production API. | 133 | In Dev Mode your data is not persistent. Please use the live app for accesing the production API. |
152 | </Infobox> | 134 | </Infobox> |
153 | )} | 135 | )} |
154 | <Radio field={form.$('accountType')} showLabel={false} /> | ||
155 | <div className="grid__row"> | 136 | <div className="grid__row"> |
156 | <Input field={form.$('firstname')} focus /> | 137 | <Input field={form.$('firstname')} focus /> |
157 | <Input field={form.$('lastname')} /> | 138 | <Input field={form.$('lastname')} /> |
@@ -162,9 +143,6 @@ export default @observer class Signup extends Component { | |||
162 | showPasswordToggle | 143 | showPasswordToggle |
163 | scorePassword | 144 | scorePassword |
164 | /> | 145 | /> |
165 | {form.$('accountType').value === 'company' && ( | ||
166 | <Input field={form.$('organization')} /> | ||
167 | )} | ||
168 | {error.code === 'email-duplicate' && ( | 146 | {error.code === 'email-duplicate' && ( |
169 | <p className="error-message center">{intl.formatMessage(messages.emailDuplicate)}</p> | 147 | <p className="error-message center">{intl.formatMessage(messages.emailDuplicate)}</p> |
170 | )} | 148 | )} |
diff --git a/src/components/subscription/TrialForm.js b/src/components/subscription/TrialForm.js index 81b1c713c..9fe1c93b7 100644 --- a/src/components/subscription/TrialForm.js +++ b/src/components/subscription/TrialForm.js | |||
@@ -15,6 +15,10 @@ const messages = defineMessages({ | |||
15 | id: 'subscription.cta.activateTrial', | 15 | id: 'subscription.cta.activateTrial', |
16 | defaultMessage: '!!!Yes, start the free Franz Professional trial', | 16 | defaultMessage: '!!!Yes, start the free Franz Professional trial', |
17 | }, | 17 | }, |
18 | allOptionsButton: { | ||
19 | id: 'subscription.cta.allOptions', | ||
20 | defaultMessage: '!!!See all options', | ||
21 | }, | ||
18 | teaserHeadline: { | 22 | teaserHeadline: { |
19 | id: 'settings.account.headlineTrialUpgrade', | 23 | id: 'settings.account.headlineTrialUpgrade', |
20 | defaultMessage: '!!!Get the free 14 day Franz Professional Trial', | 24 | defaultMessage: '!!!Get the free 14 day Franz Professional Trial', |
@@ -39,7 +43,12 @@ const messages = defineMessages({ | |||
39 | 43 | ||
40 | const styles = () => ({ | 44 | const styles = () => ({ |
41 | activateTrialButton: { | 45 | activateTrialButton: { |
42 | margin: [40, 0, 50], | 46 | margin: [40, 0, 10], |
47 | }, | ||
48 | allOptionsButton: { | ||
49 | margin: [0, 0, 40], | ||
50 | background: 'none', | ||
51 | border: 'none', | ||
43 | }, | 52 | }, |
44 | keyTerms: { | 53 | keyTerms: { |
45 | marginTop: 20, | 54 | marginTop: 20, |
@@ -50,6 +59,7 @@ export default @observer @injectSheet(styles) class TrialForm extends Component | |||
50 | static propTypes = { | 59 | static propTypes = { |
51 | activateTrial: PropTypes.func.isRequired, | 60 | activateTrial: PropTypes.func.isRequired, |
52 | isActivatingTrial: PropTypes.bool.isRequired, | 61 | isActivatingTrial: PropTypes.bool.isRequired, |
62 | showAllOptions: PropTypes.func.isRequired, | ||
53 | classes: PropTypes.object.isRequired, | 63 | classes: PropTypes.object.isRequired, |
54 | }; | 64 | }; |
55 | 65 | ||
@@ -61,6 +71,7 @@ export default @observer @injectSheet(styles) class TrialForm extends Component | |||
61 | const { | 71 | const { |
62 | isActivatingTrial, | 72 | isActivatingTrial, |
63 | activateTrial, | 73 | activateTrial, |
74 | showAllOptions, | ||
64 | classes, | 75 | classes, |
65 | } = this.props; | 76 | } = this.props; |
66 | const { intl } = this.context; | 77 | const { intl } = this.context; |
@@ -83,6 +94,12 @@ export default @observer @injectSheet(styles) class TrialForm extends Component | |||
83 | onClick={activateTrial} | 94 | onClick={activateTrial} |
84 | stretch | 95 | stretch |
85 | /> | 96 | /> |
97 | <Button | ||
98 | label={intl.formatMessage(messages.allOptionsButton)} | ||
99 | className={classes.allOptionsButton} | ||
100 | onClick={showAllOptions} | ||
101 | stretch | ||
102 | /> | ||
86 | <div className="subscription__premium-info"> | 103 | <div className="subscription__premium-info"> |
87 | <H3> | 104 | <H3> |
88 | {intl.formatMessage(messages.includedFeatures)} | 105 | {intl.formatMessage(messages.includedFeatures)} |