diff options
author | 2024-02-11 12:07:30 +0530 | |
---|---|---|
committer | 2024-02-11 17:43:49 +0000 | |
commit | 226257cd862451abccc28894e2b0a3270c6790e9 (patch) | |
tree | 3c6516bfe1bcc258ce40afa6af6cbd9582961ad9 | |
parent | Update dependabot.yml to handle both app and GHA dependencies (diff) | |
download | ferdium-app-226257cd862451abccc28894e2b0a3270c6790e9.tar.gz ferdium-app-226257cd862451abccc28894e2b0a3270c6790e9.tar.zst ferdium-app-226257cd862451abccc28894e2b0a3270c6790e9.zip |
rename features to better convey type
(without migration)
-rw-r--r-- | src/components/layout/Sidebar.tsx | 2 | ||||
-rw-r--r-- | src/components/settings/settings/EditSettingsForm.tsx | 8 | ||||
-rw-r--r-- | src/config.ts | 4 | ||||
-rw-r--r-- | src/containers/settings/EditServiceScreen.tsx | 4 | ||||
-rw-r--r-- | src/containers/settings/EditSettingsScreen.tsx | 14 | ||||
-rw-r--r-- | src/lib/Menu.ts | 4 | ||||
-rw-r--r-- | src/stores/AppStore.ts | 4 | ||||
-rw-r--r-- | src/stores/SettingsStore.ts | 4 |
8 files changed, 22 insertions, 22 deletions
diff --git a/src/components/layout/Sidebar.tsx b/src/components/layout/Sidebar.tsx index e423e408b..1106113f0 100644 --- a/src/components/layout/Sidebar.tsx +++ b/src/components/layout/Sidebar.tsx | |||
@@ -318,7 +318,7 @@ class Sidebar extends Component<IProps, IState> { | |||
318 | <Icon icon={mdiCheckAll} size={1.5} /> | 318 | <Icon icon={mdiCheckAll} size={1.5} /> |
319 | </button> | 319 | </button> |
320 | ) : null} | 320 | ) : null} |
321 | {stores!.settings.all.app.lockingFeatureEnabled ? ( | 321 | {stores!.settings.all.app.isLockingFeatureEnabled ? ( |
322 | <button | 322 | <button |
323 | type="button" | 323 | type="button" |
324 | className="sidebar__button" | 324 | className="sidebar__button" |
diff --git a/src/components/settings/settings/EditSettingsForm.tsx b/src/components/settings/settings/EditSettingsForm.tsx index 226dbac76..6a79fcc8f 100644 --- a/src/components/settings/settings/EditSettingsForm.tsx +++ b/src/components/settings/settings/EditSettingsForm.tsx | |||
@@ -306,7 +306,7 @@ interface IProps extends WrappedComponentProps { | |||
306 | isDarkmodeEnabled: boolean; | 306 | isDarkmodeEnabled: boolean; |
307 | isAdaptableDarkModeEnabled: boolean; | 307 | isAdaptableDarkModeEnabled: boolean; |
308 | isUseGrayscaleServicesEnabled: boolean; | 308 | isUseGrayscaleServicesEnabled: boolean; |
309 | lockingFeatureEnabled: boolean; | 309 | isLockingFeatureEnabled: boolean; |
310 | isSplitModeEnabled: boolean; | 310 | isSplitModeEnabled: boolean; |
311 | isOnline: boolean; | 311 | isOnline: boolean; |
312 | showServicesUpdatedInfoBar: boolean; | 312 | showServicesUpdatedInfoBar: boolean; |
@@ -403,7 +403,7 @@ class EditSettingsForm extends Component<IProps, IState> { | |||
403 | } | 403 | } |
404 | 404 | ||
405 | const { | 405 | const { |
406 | lockingFeatureEnabled, | 406 | isLockingFeatureEnabled, |
407 | scheduledDNDEnabled, | 407 | scheduledDNDEnabled, |
408 | reloadAfterResume, | 408 | reloadAfterResume, |
409 | useSelfSignedCertificates, | 409 | useSelfSignedCertificates, |
@@ -860,8 +860,8 @@ class EditSettingsForm extends Component<IProps, IState> { | |||
860 | 860 | ||
861 | <Hr /> | 861 | <Hr /> |
862 | 862 | ||
863 | <Toggle {...form.$('lockingFeatureEnabled').bind()} /> | 863 | <Toggle {...form.$('isLockingFeatureEnabled').bind()} /> |
864 | {lockingFeatureEnabled && ( | 864 | {isLockingFeatureEnabled && ( |
865 | <> | 865 | <> |
866 | {isMac && systemPreferences.canPromptTouchID() && ( | 866 | {isMac && systemPreferences.canPromptTouchID() && ( |
867 | <Toggle {...form.$('useTouchIdToUnlock').bind()} /> | 867 | <Toggle {...form.$('useTouchIdToUnlock').bind()} /> |
diff --git a/src/config.ts b/src/config.ts index 6e89cb9d1..055fc9ad1 100644 --- a/src/config.ts +++ b/src/config.ts | |||
@@ -380,7 +380,7 @@ export const DEFAULT_APP_SETTINGS = { | |||
380 | server: LIVE_FERDIUM_API, | 380 | server: LIVE_FERDIUM_API, |
381 | predefinedTodoServer: TODO_TODOIST_URL, | 381 | predefinedTodoServer: TODO_TODOIST_URL, |
382 | autohideMenuBar: false, | 382 | autohideMenuBar: false, |
383 | lockingFeatureEnabled: false, | 383 | isLockingFeatureEnabled: false, |
384 | locked: false, | 384 | locked: false, |
385 | lockedPassword: '', | 385 | lockedPassword: '', |
386 | useTouchIdToUnlock: true, | 386 | useTouchIdToUnlock: true, |
@@ -452,7 +452,7 @@ export const DEFAULT_SERVICE_SETTINGS = { | |||
452 | disablewebsecurity: false, | 452 | disablewebsecurity: false, |
453 | spellcheckerLanguage: false, | 453 | spellcheckerLanguage: false, |
454 | onlyShowFavoritesInUnreadCount: false, | 454 | onlyShowFavoritesInUnreadCount: false, |
455 | proxyFeatureEnabled: false, | 455 | isProxyFeatureEnabled: false, |
456 | proxyHost: '', | 456 | proxyHost: '', |
457 | proxyPort: 0, | 457 | proxyPort: 0, |
458 | proxyUser: '', | 458 | proxyUser: '', |
diff --git a/src/containers/settings/EditServiceScreen.tsx b/src/containers/settings/EditServiceScreen.tsx index 946ec09d3..3c65877c8 100644 --- a/src/containers/settings/EditServiceScreen.tsx +++ b/src/containers/settings/EditServiceScreen.tsx | |||
@@ -409,9 +409,9 @@ class EditServiceScreen extends Component<IProps> { | |||
409 | label: intl.formatMessage(messages.enableProxy), | 409 | label: intl.formatMessage(messages.enableProxy), |
410 | value: ifUndefined<boolean>( | 410 | value: ifUndefined<boolean>( |
411 | serviceProxyConfig.isEnabled, | 411 | serviceProxyConfig.isEnabled, |
412 | DEFAULT_SERVICE_SETTINGS.proxyFeatureEnabled, | 412 | DEFAULT_SERVICE_SETTINGS.isProxyFeatureEnabled, |
413 | ), | 413 | ), |
414 | default: DEFAULT_SERVICE_SETTINGS.proxyFeatureEnabled, | 414 | default: DEFAULT_SERVICE_SETTINGS.isProxyFeatureEnabled, |
415 | type: 'checkbox', | 415 | type: 'checkbox', |
416 | }, | 416 | }, |
417 | host: { | 417 | host: { |
diff --git a/src/containers/settings/EditSettingsScreen.tsx b/src/containers/settings/EditSettingsScreen.tsx index 528b1410b..272297700 100644 --- a/src/containers/settings/EditSettingsScreen.tsx +++ b/src/containers/settings/EditSettingsScreen.tsx | |||
@@ -398,7 +398,7 @@ class EditSettingsScreen extends Component< | |||
398 | wakeUpHibernationSplay: Boolean(settingsData.wakeUpHibernationSplay), | 398 | wakeUpHibernationSplay: Boolean(settingsData.wakeUpHibernationSplay), |
399 | predefinedTodoServer: settingsData.predefinedTodoServer, | 399 | predefinedTodoServer: settingsData.predefinedTodoServer, |
400 | customTodoServer: settingsData.customTodoServer, | 400 | customTodoServer: settingsData.customTodoServer, |
401 | lockingFeatureEnabled: Boolean(settingsData.lockingFeatureEnabled), | 401 | isLockingFeatureEnabled: Boolean(settingsData.isLockingFeatureEnabled), |
402 | lockedPassword: useOriginalPassword | 402 | lockedPassword: useOriginalPassword |
403 | ? this.props.stores.settings.all.app.lockedPassword | 403 | ? this.props.stores.settings.all.app.lockedPassword |
404 | : hash(String(settingsData.lockedPassword)), | 404 | : hash(String(settingsData.lockedPassword)), |
@@ -796,13 +796,13 @@ class EditSettingsScreen extends Component< | |||
796 | ), | 796 | ), |
797 | default: DEFAULT_APP_SETTINGS.customTodoServer, | 797 | default: DEFAULT_APP_SETTINGS.customTodoServer, |
798 | }, | 798 | }, |
799 | lockingFeatureEnabled: { | 799 | isLockingFeatureEnabled: { |
800 | label: intl.formatMessage(messages.enableLock), | 800 | label: intl.formatMessage(messages.enableLock), |
801 | value: ifUndefined<boolean>( | 801 | value: ifUndefined<boolean>( |
802 | settings.all.app.lockingFeatureEnabled, | 802 | settings.all.app.isLockingFeatureEnabled, |
803 | DEFAULT_APP_SETTINGS.lockingFeatureEnabled, | 803 | DEFAULT_APP_SETTINGS.isLockingFeatureEnabled, |
804 | ), | 804 | ), |
805 | default: DEFAULT_APP_SETTINGS.lockingFeatureEnabled, | 805 | default: DEFAULT_APP_SETTINGS.isLockingFeatureEnabled, |
806 | type: 'checkbox', | 806 | type: 'checkbox', |
807 | }, | 807 | }, |
808 | lockedPassword: { | 808 | lockedPassword: { |
@@ -1223,7 +1223,7 @@ class EditSettingsScreen extends Component< | |||
1223 | updateVersion, | 1223 | updateVersion, |
1224 | updateStatusTypes, | 1224 | updateStatusTypes, |
1225 | isClearingAllCache, | 1225 | isClearingAllCache, |
1226 | lockingFeatureEnabled, | 1226 | isLockingFeatureEnabled, |
1227 | } = app; | 1227 | } = app; |
1228 | const { checkForUpdates, installUpdate, clearAllCache } = | 1228 | const { checkForUpdates, installUpdate, clearAllCache } = |
1229 | this.props.actions.app; | 1229 | this.props.actions.app; |
@@ -1247,7 +1247,7 @@ class EditSettingsScreen extends Component< | |||
1247 | getCacheSize={() => app.cacheSize} | 1247 | getCacheSize={() => app.cacheSize} |
1248 | isClearingAllCache={isClearingAllCache} | 1248 | isClearingAllCache={isClearingAllCache} |
1249 | onClearAllCache={clearAllCache} | 1249 | onClearAllCache={clearAllCache} |
1250 | lockingFeatureEnabled={lockingFeatureEnabled} | 1250 | isLockingFeatureEnabled={isLockingFeatureEnabled} |
1251 | automaticUpdates={this.props.stores.settings.app.automaticUpdates} | 1251 | automaticUpdates={this.props.stores.settings.app.automaticUpdates} |
1252 | isDarkmodeEnabled={this.props.stores.settings.app.darkMode} | 1252 | isDarkmodeEnabled={this.props.stores.settings.app.darkMode} |
1253 | isAdaptableDarkModeEnabled={ | 1253 | isAdaptableDarkModeEnabled={ |
diff --git a/src/lib/Menu.ts b/src/lib/Menu.ts index 8ad4441d2..12dc1e42c 100644 --- a/src/lib/Menu.ts +++ b/src/lib/Menu.ts | |||
@@ -709,7 +709,7 @@ class FranzMenu implements StoresProps { | |||
709 | const { intl } = window['ferdium']; | 709 | const { intl } = window['ferdium']; |
710 | const locked = | 710 | const locked = |
711 | this.stores.settings.app.locked && | 711 | this.stores.settings.app.locked && |
712 | this.stores.settings.app.lockingFeatureEnabled && | 712 | this.stores.settings.app.isLockingFeatureEnabled && |
713 | this.stores.user.isLoggedIn; | 713 | this.stores.user.isLoggedIn; |
714 | const { actions } = this; | 714 | const { actions } = this; |
715 | const tpl = titleBarTemplateFactory(intl, locked); | 715 | const tpl = titleBarTemplateFactory(intl, locked); |
@@ -847,7 +847,7 @@ class FranzMenu implements StoresProps { | |||
847 | accelerator: `${lockFerdiumShortcutKey()}`, | 847 | accelerator: `${lockFerdiumShortcutKey()}`, |
848 | enabled: | 848 | enabled: |
849 | this.stores.user.isLoggedIn && | 849 | this.stores.user.isLoggedIn && |
850 | this.stores.settings.app.lockingFeatureEnabled, | 850 | this.stores.settings.app.isLockingFeatureEnabled, |
851 | click() { | 851 | click() { |
852 | actions.settings.update({ | 852 | actions.settings.update({ |
853 | type: 'app', | 853 | type: 'app', |
diff --git a/src/stores/AppStore.ts b/src/stores/AppStore.ts index b8c980dea..b8356bd56 100644 --- a/src/stores/AppStore.ts +++ b/src/stores/AppStore.ts | |||
@@ -121,8 +121,8 @@ export default class AppStore extends TypedStore { | |||
121 | 121 | ||
122 | @observable isFocused = true; | 122 | @observable isFocused = true; |
123 | 123 | ||
124 | @observable lockingFeatureEnabled = | 124 | @observable isLockingFeatureEnabled = |
125 | DEFAULT_APP_SETTINGS.lockingFeatureEnabled; | 125 | DEFAULT_APP_SETTINGS.isLockingFeatureEnabled; |
126 | 126 | ||
127 | @observable launchInBackground = DEFAULT_APP_SETTINGS.autoLaunchInBackground; | 127 | @observable launchInBackground = DEFAULT_APP_SETTINGS.autoLaunchInBackground; |
128 | 128 | ||
diff --git a/src/stores/SettingsStore.ts b/src/stores/SettingsStore.ts index 2e8568134..010290a4a 100644 --- a/src/stores/SettingsStore.ts +++ b/src/stores/SettingsStore.ts | |||
@@ -61,7 +61,7 @@ export default class SettingsStore extends TypedStore { | |||
61 | let inactivityTimer; | 61 | let inactivityTimer; |
62 | getCurrentWindow().on('blur', () => { | 62 | getCurrentWindow().on('blur', () => { |
63 | if ( | 63 | if ( |
64 | this.all.app.lockingFeatureEnabled && | 64 | this.all.app.isLockingFeatureEnabled && |
65 | this.all.app.inactivityLock !== 0 | 65 | this.all.app.inactivityLock !== 0 |
66 | ) { | 66 | ) { |
67 | inactivityTimer = setTimeout( | 67 | inactivityTimer = setTimeout( |
@@ -88,7 +88,7 @@ export default class SettingsStore extends TypedStore { | |||
88 | if ( | 88 | if ( |
89 | !this.loaded && | 89 | !this.loaded && |
90 | resp.type === 'app' && | 90 | resp.type === 'app' && |
91 | resp.data.lockingFeatureEnabled | 91 | resp.data.isLockingFeatureEnabled |
92 | ) { | 92 | ) { |
93 | process.nextTick(() => { | 93 | process.nextTick(() => { |
94 | if (!this.all.app.locked) { | 94 | if (!this.all.app.locked) { |