aboutsummaryrefslogtreecommitdiffstats
path: root/src/containers
diff options
context:
space:
mode:
Diffstat (limited to 'src/containers')
-rw-r--r--src/containers/layout/AppLayoutContainer.js1
-rw-r--r--src/containers/settings/AccountScreen.js9
-rw-r--r--src/containers/settings/EditSettingsScreen.js40
-rw-r--r--src/containers/settings/RecipesScreen.js3
4 files changed, 45 insertions, 8 deletions
diff --git a/src/containers/layout/AppLayoutContainer.js b/src/containers/layout/AppLayoutContainer.js
index a14a98554..95fbd109f 100644
--- a/src/containers/layout/AppLayoutContainer.js
+++ b/src/containers/layout/AppLayoutContainer.js
@@ -140,6 +140,7 @@ export default @inject('stores', 'actions') @observer class AppLayoutContainer e
140 showServicesUpdatedInfoBar={ui.showServicesUpdatedInfoBar} 140 showServicesUpdatedInfoBar={ui.showServicesUpdatedInfoBar}
141 appUpdateIsDownloaded={app.updateStatus === app.updateStatusTypes.DOWNLOADED} 141 appUpdateIsDownloaded={app.updateStatus === app.updateStatusTypes.DOWNLOADED}
142 nextAppReleaseVersion={app.nextAppReleaseVersion} 142 nextAppReleaseVersion={app.nextAppReleaseVersion}
143 authRequestFailed={app.authRequestFailed}
143 sidebar={sidebar} 144 sidebar={sidebar}
144 workspacesDrawer={workspacesDrawer} 145 workspacesDrawer={workspacesDrawer}
145 services={servicesContainer} 146 services={servicesContainer}
diff --git a/src/containers/settings/AccountScreen.js b/src/containers/settings/AccountScreen.js
index 9c74cf2ab..41cdeb79a 100644
--- a/src/containers/settings/AccountScreen.js
+++ b/src/containers/settings/AccountScreen.js
@@ -26,7 +26,14 @@ export default @inject('stores', 'actions') @observer class AccountScreen extend
26 handleWebsiteLink(route) { 26 handleWebsiteLink(route) {
27 const { actions, stores } = this.props; 27 const { actions, stores } = this.props;
28 28
29 const url = stores.user.getAuthURL(`${WEBSITE}${route}?utm_source=app&utm_medium=account_dashboard`); 29 const api = stores.settings.all.app.server;
30
31 let url;
32 if (api === 'https://api.franzinfra.com') {
33 url = stores.user.getAuthURL(`${WEBSITE}${route}?utm_source=app&utm_medium=account_dashboard`);
34 } else {
35 url = `${api}${route}`;
36 }
30 37
31 actions.app.openExternalUrl({ url }); 38 actions.app.openExternalUrl({ url });
32 } 39 }
diff --git a/src/containers/settings/EditSettingsScreen.js b/src/containers/settings/EditSettingsScreen.js
index 9aba212be..09e7b43ab 100644
--- a/src/containers/settings/EditSettingsScreen.js
+++ b/src/containers/settings/EditSettingsScreen.js
@@ -17,6 +17,8 @@ import { getSelectOptions } from '../../helpers/i18n-helpers';
17import EditSettingsForm from '../../components/settings/settings/EditSettingsForm'; 17import EditSettingsForm from '../../components/settings/settings/EditSettingsForm';
18import ErrorBoundary from '../../components/util/ErrorBoundary'; 18import ErrorBoundary from '../../components/util/ErrorBoundary';
19 19
20import { API, TODOS_FRONTEND } from '../../environment';
21
20import globalMessages from '../../i18n/globalMessages'; 22import globalMessages from '../../i18n/globalMessages';
21import { DEFAULT_IS_FEATURE_ENABLED_BY_USER } from '../../features/todos'; 23import { DEFAULT_IS_FEATURE_ENABLED_BY_USER } from '../../features/todos';
22import WorkspacesStore from '../../features/workspaces/store'; 24import WorkspacesStore from '../../features/workspaces/store';
@@ -25,7 +27,7 @@ import { DEFAULT_SETTING_KEEP_ALL_WORKSPACES_LOADED } from '../../features/works
25const messages = defineMessages({ 27const messages = defineMessages({
26 autoLaunchOnStart: { 28 autoLaunchOnStart: {
27 id: 'settings.app.form.autoLaunchOnStart', 29 id: 'settings.app.form.autoLaunchOnStart',
28 defaultMessage: '!!!Launch Franz on start', 30 defaultMessage: '!!!Launch Ferdi on start',
29 }, 31 },
30 autoLaunchInBackground: { 32 autoLaunchInBackground: {
31 id: 'settings.app.form.autoLaunchInBackground', 33 id: 'settings.app.form.autoLaunchInBackground',
@@ -33,15 +35,27 @@ const messages = defineMessages({
33 }, 35 },
34 runInBackground: { 36 runInBackground: {
35 id: 'settings.app.form.runInBackground', 37 id: 'settings.app.form.runInBackground',
36 defaultMessage: '!!!Keep Franz in background when closing the window', 38 defaultMessage: '!!!Keep Ferdi in background when closing the window',
37 }, 39 },
38 enableSystemTray: { 40 enableSystemTray: {
39 id: 'settings.app.form.enableSystemTray', 41 id: 'settings.app.form.enableSystemTray',
40 defaultMessage: '!!!Show Franz in system tray', 42 defaultMessage: '!!!Show Ferdi in system tray',
41 }, 43 },
42 minimizeToSystemTray: { 44 minimizeToSystemTray: {
43 id: 'settings.app.form.minimizeToSystemTray', 45 id: 'settings.app.form.minimizeToSystemTray',
44 defaultMessage: '!!!Minimize Franz to system tray', 46 defaultMessage: '!!!Minimize Ferdi to system tray',
47 },
48 privateNotifications: {
49 id: 'settings.app.form.privateNotifications',
50 defaultMessage: '!!!Don\'t show message content in notifications',
51 },
52 server: {
53 id: 'settings.app.form.server',
54 defaultMessage: '!!!Server',
55 },
56 todoServer: {
57 id: 'settings.app.form.todoServer',
58 defaultMessage: '!!!Todo Server',
45 }, 59 },
46 language: { 60 language: {
47 id: 'settings.app.form.language', 61 id: 'settings.app.form.language',
@@ -107,6 +121,9 @@ export default @inject('stores', 'actions') @observer class EditSettingsScreen e
107 runInBackground: settingsData.runInBackground, 121 runInBackground: settingsData.runInBackground,
108 enableSystemTray: settingsData.enableSystemTray, 122 enableSystemTray: settingsData.enableSystemTray,
109 minimizeToSystemTray: settingsData.minimizeToSystemTray, 123 minimizeToSystemTray: settingsData.minimizeToSystemTray,
124 privateNotifications: settingsData.privateNotifications,
125 server: settingsData.server,
126 todoServer: settingsData.todoServer,
110 enableGPUAcceleration: settingsData.enableGPUAcceleration, 127 enableGPUAcceleration: settingsData.enableGPUAcceleration,
111 showDisabledServices: settingsData.showDisabledServices, 128 showDisabledServices: settingsData.showDisabledServices,
112 darkMode: settingsData.darkMode, 129 darkMode: settingsData.darkMode,
@@ -182,6 +199,21 @@ export default @inject('stores', 'actions') @observer class EditSettingsScreen e
182 value: settings.all.app.minimizeToSystemTray, 199 value: settings.all.app.minimizeToSystemTray,
183 default: DEFAULT_APP_SETTINGS.minimizeToSystemTray, 200 default: DEFAULT_APP_SETTINGS.minimizeToSystemTray,
184 }, 201 },
202 privateNotifications: {
203 label: intl.formatMessage(messages.privateNotifications),
204 value: settings.all.app.privateNotifications,
205 default: DEFAULT_APP_SETTINGS.privateNotifications,
206 },
207 server: {
208 label: intl.formatMessage(messages.server),
209 value: settings.all.app.server || API,
210 default: API,
211 },
212 todoServer: {
213 label: intl.formatMessage(messages.todoServer),
214 value: settings.all.app.todoServer || TODOS_FRONTEND,
215 default: TODOS_FRONTEND,
216 },
185 showDisabledServices: { 217 showDisabledServices: {
186 label: intl.formatMessage(messages.showDisabledServices), 218 label: intl.formatMessage(messages.showDisabledServices),
187 value: settings.all.app.showDisabledServices, 219 value: settings.all.app.showDisabledServices,
diff --git a/src/containers/settings/RecipesScreen.js b/src/containers/settings/RecipesScreen.js
index 132820b6f..692dc26f1 100644
--- a/src/containers/settings/RecipesScreen.js
+++ b/src/containers/settings/RecipesScreen.js
@@ -13,7 +13,6 @@ import UserStore from '../../stores/UserStore';
13import RecipesDashboard from '../../components/settings/recipes/RecipesDashboard'; 13import RecipesDashboard from '../../components/settings/recipes/RecipesDashboard';
14import ErrorBoundary from '../../components/util/ErrorBoundary'; 14import ErrorBoundary from '../../components/util/ErrorBoundary';
15import { FRANZ_DEV_DOCS } from '../../config'; 15import { FRANZ_DEV_DOCS } from '../../config';
16import { gaEvent } from '../../lib/analytics';
17import { communityRecipesStore } from '../../features/communityRecipes'; 16import { communityRecipesStore } from '../../features/communityRecipes';
18 17
19const { app } = remote; 18const { app } = remote;
@@ -122,11 +121,9 @@ export default @inject('stores', 'actions') @observer class RecipesScreen extend
122 recipeDirectory={recipeDirectory} 121 recipeDirectory={recipeDirectory}
123 openRecipeDirectory={() => { 122 openRecipeDirectory={() => {
124 shell.openItem(recipeDirectory); 123 shell.openItem(recipeDirectory);
125 gaEvent('Recipe', 'open-recipe-folder', 'Open Folder');
126 }} 124 }}
127 openDevDocs={() => { 125 openDevDocs={() => {
128 appActions.openExternalUrl({ url: FRANZ_DEV_DOCS }); 126 appActions.openExternalUrl({ url: FRANZ_DEV_DOCS });
129 gaEvent('Recipe', 'open-dev-docs', 'Developer Documentation');
130 }} 127 }}
131 isCommunityRecipesIncludedInCurrentPlan={communityRecipesStore.isCommunityRecipesIncludedInCurrentPlan} 128 isCommunityRecipesIncludedInCurrentPlan={communityRecipesStore.isCommunityRecipesIncludedInCurrentPlan}
132 isUserPremiumUser={user.isPremium} 129 isUserPremiumUser={user.isPremium}