fix(mobile): enable workspaces (#1139)
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
import { WorkspacesEnabled } from '@Lib/constants'
|
||||
import AsyncStorage from '@react-native-community/async-storage'
|
||||
import SNReactNative from '@standardnotes/react-native-utils'
|
||||
import {
|
||||
@@ -322,9 +321,7 @@ export class MobileDeviceInterface implements DeviceInterface {
|
||||
}
|
||||
|
||||
performSoftReset() {
|
||||
if (WorkspacesEnabled) {
|
||||
SNReactNative.exitApp()
|
||||
}
|
||||
SNReactNative.exitApp()
|
||||
}
|
||||
|
||||
// eslint-disable-next-line @typescript-eslint/no-empty-function
|
||||
|
||||
@@ -1,7 +1,3 @@
|
||||
import { IsDev } from '@Lib/Utils'
|
||||
|
||||
export enum ErrorMessage {
|
||||
GeneralText = 'An error occurred. Please try again later.',
|
||||
}
|
||||
|
||||
export const WorkspacesEnabled = IsDev
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
import { WorkspacesEnabled } from '@Lib/constants'
|
||||
import { useSignedIn } from '@Lib/SnjsHelperHooks'
|
||||
import { useNavigation } from '@react-navigation/native'
|
||||
import { ButtonCell } from '@Root/Components/ButtonCell'
|
||||
@@ -80,9 +79,7 @@ export const OptionsSection = ({ title, encryptionAvailable }: Props) => {
|
||||
let signoutText =
|
||||
'Signing out will remove all data from this device, including notes and tags. Make sure your data is synced before proceeding.'
|
||||
|
||||
if (WorkspacesEnabled) {
|
||||
signoutText += '\n\nYour app will quit after sign out completes.'
|
||||
}
|
||||
signoutText += '\n\nYour app will quit after sign out completes.'
|
||||
|
||||
if (await application.alertService.confirm(signoutText, 'Sign Out?', 'Sign Out', ButtonType.Danger)) {
|
||||
await application.user.signOut()
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
import { WorkspacesEnabled } from '@Lib/constants'
|
||||
import { useSignedIn } from '@Lib/SnjsHelperHooks'
|
||||
import { useSafeApplicationContext } from '@Root/Hooks/useSafeApplicationContext'
|
||||
import { ModalStackNavigationProp } from '@Root/ModalStack'
|
||||
@@ -56,7 +55,7 @@ export const Settings = (props: Props) => {
|
||||
<Container keyboardShouldPersistTaps={'always'} keyboardDismissMode={'interactive'}>
|
||||
<AuthSection title="Account" signedIn={signedIn} />
|
||||
<OptionsSection encryptionAvailable={!!encryptionAvailable} title="Options" />
|
||||
{WorkspacesEnabled && <WorkspacesSection />}
|
||||
<WorkspacesSection />
|
||||
<PreferencesSection />
|
||||
{application.hasAccount() && isEntitledToFiles && <FilesSection />}
|
||||
<SecuritySection
|
||||
|
||||
Reference in New Issue
Block a user