aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/settings
diff options
context:
space:
mode:
authorLibravatar vantezzen <hello@vantezzen.io>2019-09-27 11:23:31 +0200
committerLibravatar vantezzen <hello@vantezzen.io>2019-09-27 11:23:31 +0200
commit8f60790de89ee7fd7a150a83a8ca39b4bf76509c (patch)
tree0e35a3687da220389747d8998f3c978898fb2fd7 /src/components/settings
parentBump to 5.3.4-beta.4 (diff)
downloadferdium-app-8f60790de89ee7fd7a150a83a8ca39b4bf76509c.tar.gz
ferdium-app-8f60790de89ee7fd7a150a83a8ca39b4bf76509c.tar.zst
ferdium-app-8f60790de89ee7fd7a150a83a8ca39b4bf76509c.zip
Replace "invite friends" screen with "support Ferdi" screen
Diffstat (limited to 'src/components/settings')
-rw-r--r--src/components/settings/navigation/SettingsNavigation.js10
-rw-r--r--src/components/settings/supportFerdi/SupportFerdiDashboard.js73
2 files changed, 78 insertions, 5 deletions
diff --git a/src/components/settings/navigation/SettingsNavigation.js b/src/components/settings/navigation/SettingsNavigation.js
index 201819526..2711bc107 100644
--- a/src/components/settings/navigation/SettingsNavigation.js
+++ b/src/components/settings/navigation/SettingsNavigation.js
@@ -35,9 +35,9 @@ const messages = defineMessages({
35 id: 'settings.navigation.settings', 35 id: 'settings.navigation.settings',
36 defaultMessage: '!!!Settings', 36 defaultMessage: '!!!Settings',
37 }, 37 },
38 inviteFriends: { 38 supportFerdi: {
39 id: 'settings.navigation.inviteFriends', 39 id: 'settings.navigation.supportFerdi',
40 defaultMessage: '!!!Invite Friends', 40 defaultMessage: '!!!Support Ferdi',
41 }, 41 },
42 logout: { 42 logout: {
43 id: 'settings.navigation.logout', 43 id: 'settings.navigation.logout',
@@ -129,11 +129,11 @@ export default @inject('stores') @observer class SettingsNavigation extends Comp
129 {intl.formatMessage(messages.settings)} 129 {intl.formatMessage(messages.settings)}
130 </Link> 130 </Link>
131 <Link 131 <Link
132 to="/settings/invite" 132 to="/settings/support"
133 className="settings-navigation__link" 133 className="settings-navigation__link"
134 activeClassName="is-active" 134 activeClassName="is-active"
135 > 135 >
136 {intl.formatMessage(messages.inviteFriends)} 136 {intl.formatMessage(messages.supportFerdi)}
137 </Link> 137 </Link>
138 <span className="settings-navigation__expander" /> 138 <span className="settings-navigation__expander" />
139 <Link 139 <Link
diff --git a/src/components/settings/supportFerdi/SupportFerdiDashboard.js b/src/components/settings/supportFerdi/SupportFerdiDashboard.js
new file mode 100644
index 000000000..57920a4a2
--- /dev/null
+++ b/src/components/settings/supportFerdi/SupportFerdiDashboard.js
@@ -0,0 +1,73 @@
1import React, { Component } from 'react';
2import PropTypes from 'prop-types';
3import { defineMessages, intlShape } from 'react-intl';
4
5import Button from '../../ui/Button';
6
7const messages = defineMessages({
8 headline: {
9 id: 'settings.supportFerdi.headline',
10 defaultMessage: '!!!Support Ferdi',
11 },
12 title: {
13 id: 'settings.supportFerdi.title',
14 defaultMessage: '!!!Do you like Ferdi? Spread the love!',
15 },
16 github: {
17 id: 'settings.supportFerdi.github',
18 defaultMessage: '!!!Star on GitHub',
19 },
20 share: {
21 id: 'settings.supportFerdi.share',
22 defaultMessage: '!!!Tell your Friends',
23 },
24 openCollective: {
25 id: 'settings.supportFerdi.openCollective',
26 defaultMessage: '!!!Support our Open Collective',
27 },
28});
29
30class SupportFerdiDashboard extends Component {
31 static contextTypes = {
32 intl: intlShape,
33 };
34
35 static propTypes = {
36 openLink: PropTypes.func.isRequired,
37 };
38
39 render() {
40 const { openLink } = this.props;
41 const { intl } = this.context;
42
43 return (
44 <div className="settings__main">
45 <div className="settings__header">
46 <span className="settings__header-item">
47 {intl.formatMessage(messages.headline)}
48 </span>
49 </div>
50 <div className="settings__body">
51 <h1>{intl.formatMessage(messages.title)}</h1>
52 <Button
53 label={intl.formatMessage(messages.github)}
54 className="franz-form__button--inverted franz-form__button--large"
55 onClick={() => openLink('https://github.com/getferdi/ferdi')}
56 />
57 <Button
58 label={intl.formatMessage(messages.share)}
59 className="franz-form__button--inverted franz-form__button--large"
60 onClick={() => openLink('https://twitter.com/intent/tweet?text=Ferdi%3A%20A%20messaging%20browser%20that%20allows%20you%20to%20combine%20your%20favourite%20messaging%20services%20into%20one%20application.%0A%0ACheck%20out%20Ferdi%20at%20https%3A//getferdi.com')}
61 />
62 <Button
63 label={intl.formatMessage(messages.openCollective)}
64 className="franz-form__button--inverted franz-form__button--large"
65 onClick={() => openLink('https://opencollective.com/getferdi')}
66 />
67 </div>
68 </div>
69 );
70 }
71}
72
73export default SupportFerdiDashboard;