Skip to content

A fully open source & end-to-end encrypted note taking alternative to Evernote.

bug fixes...

ammarahm-ed69813816eedf
diff --git a/apps/mobile/App.js b/apps/mobile/App.js
index 34b69a991..63fad2fe0 100644
--- a/apps/mobile/App.js
+++ b/apps/mobile/App.js
@@ -7,7 +7,7 @@ import {useTracked} from './src/provider';
import {ACTIONS} from './src/provider/actions';
import {defaultState} from './src/provider/defaultState';
import {eSubscribeEvent, eUnSubscribeEvent} from './src/services/eventManager';
-import {eDispatchAction, eStartSyncer} from './src/services/events';
+import {eDispatchAction, eStartSyncer, eResetApp} from './src/services/events';
import {db, DDS, ToastEvent} from './src/utils/utils';
import {useNetInfo} from '@react-native-community/netinfo';
@@ -29,16 +29,15 @@ const App = () => {
if (!netInfo.isConnected || !netInfo.isInternetReachable) {
db.user?.get().then(user => {
if (user) {
- ToastEvent.show('No internet connection','error');
+ ToastEvent.show('No internet connection', 'error');
} else {
}
});
} else {
db.user?.get().then(user => {
if (user) {
- ToastEvent.show('Internet connection restored','success');
+ ToastEvent.show('Internet connection restored', 'success');
} else {
-
}
});
}
@@ -80,12 +79,20 @@ const App = () => {
dispatch({type: ACTIONS.SYNCING, syncing: false});
};
+ const resetApp = () => {
+ setInit(false);
+ Initialize().then(() => {
+ setInit(true);
+ });
+ };
+
useEffect(() => {
eSubscribeEvent(eStartSyncer, startSyncer);
-
+ eSubscribeEvent(eResetApp, resetApp);
return () => {
db.ev.unsubscribe('sync', _syncFunc);
eUnSubscribeEvent(eStartSyncer, startSyncer);
+ eUnSubscribeEvent(eResetApp, resetApp);
};
}, []);
diff --git a/apps/mobile/android/app/src/main/assets/texteditor.html b/apps/mobile/android/app/src/main/assets/texteditor.html
index 35cec8c89..49ce64a10 100644
--- a/apps/mobile/android/app/src/main/assets/texteditor.html
+++ b/apps/mobile/android/app/src/main/assets/texteditor.html
@@ -6,7 +6,7 @@
<style>
.app-body {
margin: 0px;
- overflow: hidden;
+ overflow:auto;
}
@@ -63,9 +63,9 @@
.ql-editor {
box-sizing: border-box;
line-height: 1.42;
- height: 100%;
+ height: auto;
outline: none;
- overflow-y: auto;
+ overflow-y: hidden;
padding: 12px 12px;
tab-size: 4;
-moz-tab-size: 4;
@@ -735,10 +735,11 @@
.ql-snow .ql-icon-picker .ql-picker-label svg {
right: 4px;
}
- #mdi-format-textdirection-l-to-r,
+
+ #mdi-format-textdirection-l-to-r,
#mdi-format-textdirection-r-to-l {
- width:20px !important;
- height:20px !important;
+ width: 20px !important;
+ height: 20px !important;
margin-top: 3px;
}
@@ -765,12 +766,13 @@
padding: 0px;
width: 20px;
}
+
#mdi-format-align-left,
#mdi-format-align-center,
#mdi-format-align-justify,
#mdi-format-align-right {
width: 20px !important;
- height:20px !important;
+ height: 20px !important;
margin-top: -1px;
}
@@ -993,6 +995,7 @@
height: 50px;
bottom: 0px;
left: 0px;
+ z-index: 999;
}
@@ -1026,7 +1029,7 @@
border-color: #f0f0f0;
}
-
+
.ql-toolbar.ql-snow .ql-picker.ql-expanded .ql-picker-options {
border-color: #f0f0f0;
@@ -1079,7 +1082,6 @@
height: 50;
width: 100%;
outline: none;
- z-index: 10;
}
#titlebar {
@@ -1098,9 +1100,6 @@
#titlebar input:focus {
outline: none;
}
-
-
-
#infowords {
margin-right: 5px;
margin-left: 5px;
@@ -1119,6 +1118,7 @@
</head>
<body class="app-body">
+
<div id="titlebar">
<input id="titleInput" placeholder="Title here" />
<div class="info-bar">
@@ -1130,6 +1130,7 @@
</div>
</div>
+
<div id="editor"></div>
<div id="toolbar"></div>
@@ -1141,7 +1142,14 @@
<script inline>
- function loadAction(premium) {
+ function loadAction(premium, noMenu) {
+
+ let titleIn = document.getElementById('titlebar');
+
+ //titleIn.style.width = width;
+ titleIn.style['padding-left'] = 12;
+ titleIn.style['padding-right'] = 60;
+
(function () { function r(e, n, t) { function o(i, f) { if (!n[i]) { if (!e[i]) { var c = "function" == typeof require && require; if (!f && c) return c(i, !0); if (u) return u(i, !0); var a = new Error("Cannot find module '" + i + "'"); throw a.code = "MODULE_NOT_FOUND", a } var p = n[i] = { exports: {} }; e[i][0].call(p.exports, function (r) { var n = e[i][1][r]; return o(n || r) }, p, p.exports, r, e, n, t) } return n[i].exports } for (var u = "function" == typeof require && require, i = 0; i < t.length; i++)o(t[i]); return o } return r })()({
@@ -1222,7 +1230,7 @@
];
let simpleToolbar = [
[{ header: 1 }, { header: 2 }],
- ['bold', 'italic','underline','strike'], // toggled buttons
+ ['bold', 'italic', 'underline', 'strike'], // toggled buttons
[{ align: [] }],
[{ direction: 'rtl' }], // text direction
@@ -1298,7 +1306,7 @@
value: document.getElementById('titleInput').value
}
- window.ReactNativeWebView.postMessage(JSON.stringify(titleMessage));
+ window.ReactNativeWebView.postMessage(JSON.stringify(titleMessage));
}
function onChangetitle() {
editor.focus();
@@ -1307,7 +1315,7 @@
type: 'title',
value: document.getElementById('titleInput').value
}
- window.ReactNativeWebView.postMessage(JSON.stringify(titleMessage));
+ window.ReactNativeWebView.postMessage(JSON.stringify(titleMessage));
}
const setTheme = function () {
@@ -1546,12 +1554,13 @@
overflow-x: auto;
width: 100vw;
white-space: nowrap;
- position: absolute;
+ position: fixed;
zIndex:999;
bottom: 0px;
height: 50px;
left: 0px;
border-top: 1px solid ${pageTheme.colors.nav};
+ background-color:${pageTheme.colors.bg};
}
.ql-editor.ql-blank::before {
@@ -16641,6 +16650,7 @@
}
+
</script>
diff --git a/apps/mobile/index.mobile.js b/apps/mobile/index.mobile.js
index 29cd06dba..a3ee3c345 100644
--- a/apps/mobile/index.mobile.js
+++ b/apps/mobile/index.mobile.js
@@ -68,6 +68,7 @@ export const Initialize = () => {
opacity: 0,
backgroundColor: colors.bg,
}}
+
keyboardDismissMode="ondrag"
drawerWidth={300}
drawerLockMode={locked ? 'locked-closed' : 'unlocked'}
diff --git a/apps/mobile/src/components/ActionIcon/index.js b/apps/mobile/src/components/ActionIcon/index.js
new file mode 100644
index 000000000..35c0fcdf6
--- /dev/null
+++ b/apps/mobile/src/components/ActionIcon/index.js
@@ -0,0 +1,21 @@
+import React from 'react';
+import {TouchableOpacity} from 'react-native';
+import Icon from 'react-native-vector-icons/MaterialCommunityIcons';
+import {SIZE} from '../../common/common';
+
+export const ActionIcon = ({onPress, name, color,customStyle}) => {
+ return (
+ <TouchableOpacity
+ onPress={onPress}
+ style={[{
+ width: 60,
+ height: 50,
+ justifyContent: 'center',
+ alignItems: 'flex-end',
+ paddingRight: 12,
+ zIndex: 800,
+ },customStyle]}>
+ <Icon name={name} color={color} size={SIZE.xxxl} />
+ </TouchableOpacity>
+ );
+};
diff --git a/apps/mobile/src/components/SelectionHeader/index.js b/apps/mobile/src/components/SelectionHeader/index.js
index f8967fb5e..c68450619 100644
--- a/apps/mobile/src/components/SelectionHeader/index.js
+++ b/apps/mobile/src/components/SelectionHeader/index.js
@@ -6,14 +6,14 @@ import {SIZE, WEIGHT} from '../../common/common';
import {useTracked} from '../../provider';
import {ACTIONS} from '../../provider/actions';
import {eSendEvent} from '../../services/eventManager';
-import {eOpenMoveNoteDialog, eOpenSimpleDialog} from '../../services/events';
+import {eOpenMoveNoteDialog, eOpenSimpleDialog, eOpenPremiumDialog} from '../../services/events';
import {db, selection, ToastEvent} from '../../utils/utils';
import {TEMPLATE_DELETE} from '../DialogManager/templates';
export const SelectionHeader = () => {
// State
const [state, dispatch] = useTracked();
- const {colors, selectionMode, selectedItemsList, currentScreen,containerState} = state;
+ const {colors, selectionMode, selectedItemsList, currentScreen,containerState, premiumUser} = state;
const [selectAll, setSelectAll] = useState(false);
@@ -25,10 +25,11 @@ export const SelectionHeader = () => {
style={{
width: '100%',
position: 'absolute',
- height: Platform.OS === 'android' ? 80 + StatusBar.currentHeight : 80,
+ height: Platform.OS === 'android' ? 100 + StatusBar.currentHeight : 80,
backgroundColor: colors.bg,
paddingTop: Platform.OS === 'ios' ? 0 : StatusBar.currentHeight,
justifyContent: 'flex-end',
+
zIndex: 999,
paddingHorizontal: 12,
transform: [
@@ -101,7 +102,7 @@ export const SelectionHeader = () => {
style={{
paddingLeft: 25,
}}
- color={colors.accent}
+ color={colors.icon}
name={'plus'}
size={SIZE.xl}
/>
@@ -110,6 +111,10 @@ export const SelectionHeader = () => {
{currentScreen === 'trash' || currentScreen === 'notebooks' ? null : (
<TouchableOpacity
onPress={async () => {
+ if (!premiumUser) {
+ eSendEvent(eOpenPremiumDialog);
+ return;
+ }
let favCount = 0;
let unFavCount = 0;
if (selectedItemsList.length > 0) {
@@ -138,7 +143,7 @@ export const SelectionHeader = () => {
style={{
paddingLeft: 25,
}}
- color={colors.accent}
+ color={colors.icon}
name={'star'}
size={SIZE.xl - 3}
/>
@@ -155,7 +160,7 @@ export const SelectionHeader = () => {
style={{
paddingLeft: 25,
}}
- color={colors.errorText}
+ color={colors.icon}
name={'delete'}
size={SIZE.xl - 3}
/>
@@ -183,7 +188,7 @@ export const SelectionHeader = () => {
style={{
paddingLeft: 25,
}}
- color={colors.errorText}
+ color={colors.icon}
name="delete-restore"
size={SIZE.xl - 3}
/>
@@ -213,6 +218,8 @@ export const SelectionHeader = () => {
height: 40,
flexDirection: 'row',
alignSelf: 'flex-start',
+ marginLeft:5,
+ marginBottom:5
}}>
<Icon
style={{}}
diff --git a/apps/mobile/src/components/SimpleList/index.js b/apps/mobile/src/components/SimpleList/index.js
index 9916ee4f6..5f455cd3f 100644
--- a/apps/mobile/src/components/SimpleList/index.js
+++ b/apps/mobile/src/components/SimpleList/index.js
@@ -13,13 +13,17 @@ import {SIZE, WEIGHT, opacity, pv} from '../../common/common';
import {useTracked} from '../../provider';
import {ACTIONS} from '../../provider/actions';
import {eSendEvent} from '../../services/eventManager';
-import {eClearSearch, eScrollEvent, eOpenLoginDialog} from '../../services/events';
+import {
+ eClearSearch,
+ eScrollEvent,
+ eOpenLoginDialog,
+} from '../../services/events';
import {db, ToastEvent, DDS} from '../../utils/utils';
import * as Animatable from 'react-native-animatable';
import {PinnedItemList} from './PinnedItemList';
import Icon from 'react-native-vector-icons/MaterialCommunityIcons';
import NavigationService from '../../services/NavigationService';
-import { Placeholder } from '../ListPlaceholders';
+import {Placeholder} from '../ListPlaceholders';
const sectionListRef = createRef();
const AnimatedFlatlist = Animatable.createAnimatableComponent(FlatList);
@@ -169,7 +173,7 @@ const SimpleList = ({
? 155 - insets.top
: 155 - 60 - insets.top,
}}>
- {user || !data[0] ? null : (
+ {user || !data[0] || selectionMode ? null : (
<TouchableOpacity
onPress={() => {
DDS.isTab
@@ -178,17 +182,16 @@ const SimpleList = ({
root: true,
});
}}
- activeOpacity={opacity }
+ activeOpacity={opacity}
style={{
- paddingVertical:6,
+ paddingVertical: 6,
width: '100%',
flexDirection: 'row',
alignItems: 'center',
justifyContent: 'flex-start',
backgroundColor: colors.shade,
paddingHorizontal: 12,
- alignSelf:'center',
-
+ alignSelf: 'center',
}}>
<View
style={{
@@ -245,9 +248,7 @@ const SimpleList = ({
justifyContent: 'center',
opacity: 1,
}}>
- <>
- {placeholder}
- </>
+ <>{placeholder}</>
</View>
);
diff --git a/apps/mobile/src/components/header/index.js b/apps/mobile/src/components/header/index.js
index fe9da4d4e..e08c0436e 100644
--- a/apps/mobile/src/components/header/index.js
+++ b/apps/mobile/src/components/header/index.js
@@ -175,7 +175,7 @@ export const Header = ({showSearch, root}) => {
marginLeft: -5,
}}
color={colors.pri}
- name={'chevron-left'}
+ name={'arrow-left'}
size={SIZE.xxxl - 3}
/>
</TouchableOpacity>
diff --git a/apps/mobile/src/services/NavigationService.js b/apps/mobile/src/services/NavigationService.js
index eb59c520b..c0e4deb54 100755
--- a/apps/mobile/src/services/NavigationService.js
+++ b/apps/mobile/src/services/NavigationService.js
@@ -2,7 +2,9 @@ import { StackActions } from '@react-navigation/native';
import { rootNavigatorRef } from '../utils/refs';
function navigate(name, params) {
+
rootNavigatorRef.current?.navigate(name, params);
+
}
function goBack() {
rootNavigatorRef.current?.goBack();
diff --git a/apps/mobile/src/services/events.js b/apps/mobile/src/services/events.js
index 6650e2742..b4dbb9327 100644
--- a/apps/mobile/src/services/events.js
+++ b/apps/mobile/src/services/events.js
@@ -80,4 +80,6 @@ export const eSetModalNavigator = '539'
export const eOpenPremiumDialog = '540'
-export const eClosePremiumDialog = '541'
\ No newline at end of file
+export const eClosePremiumDialog = '541'
+
+export const eResetApp = '542'
\ No newline at end of file
diff --git a/apps/mobile/src/utils/animations.js b/apps/mobile/src/utils/animations.js
index ad727aa48..396f741a2 100644
--- a/apps/mobile/src/utils/animations.js
+++ b/apps/mobile/src/utils/animations.js
@@ -7,35 +7,34 @@ const {color, Value, timing} = Animated;
export const EditorPosition = new Value(Dimensions.get('window').width * 1.5);
export const EditorScale = new Value(0.99);
export const EditorOpacity = new Value(0);
-export const EditorTranslateY = new Value(10);
+export const EditorTranslateY = new Value(150);
export function openEditorAnimation() {
EditorPosition.setValue(Dimensions.get('window').width * 1.5);
- EditorTranslateY.setValue(10);
+ EditorTranslateY.setValue(150);
EditorOpacity.setValue(0);
+
editing.currentlyEditing = true;
- let openConfigH = {
- duration: 1,
- toValue: 0,
- easing: Easing.in(Easing.linear),
- };
-
- timing(EditorScale, {
- duration:300,
- toValue:1,
- easing: Easing.in(Easing.linear),
- }).start();
- timing(EditorTranslateY, {
- duration:300,
- toValue:0,
- easing: Easing.in(Easing.linear),
- }).start();
- timing(EditorOpacity, {
- duration:50,
- toValue:1,
- easing: Easing.in(Easing.linear),
- }).start();
- timing(EditorPosition, openConfigH).start();
+
+ EditorPosition.setValue(0);
+
+ setTimeout(() => {
+ timing(EditorScale, {
+ duration: 150,
+ toValue: 1,
+ easing: Easing.in(Easing.linear),
+ }).start();
+ timing(EditorTranslateY, {
+ duration: 150,
+ toValue: 0,
+ easing: Easing.in(Easing.linear),
+ }).start();
+ timing(EditorOpacity, {
+ duration: 150,
+ toValue: 1,
+ easing: Easing.in(Easing.linear),
+ }).start();
+ }, 10);
}
export function exitEditorAnimation() {
@@ -43,27 +42,31 @@ export function exitEditorAnimation() {
EditorOpacity.setValue(1);
EditorTranslateY.setValue(0);
editing.currentlyEditing = false;
- let openConfigH = {
- duration: 1,
- toValue: Dimensions.get('window').width * 1.5,
- easing: Easing.in(Easing.linear),
- };
- timing(EditorOpacity, {
- duration:150,
- toValue:0,
- easing: Easing.in(Easing.linear),
- }).start();
- timing(EditorTranslateY, {
- duration:150,
- toValue:40,
- easing: Easing.in(Easing.linear),
- }).start();
- timing(EditorScale, {
- duration:150,
- toValue:0.99,
- easing: Easing.in(Easing.linear),
- }).start();
- timing(EditorPosition, openConfigH).start();
+ setTimeout(() => {
+
+ setTimeout(() => {
+ EditorPosition.setValue(Dimensions.get('window').width * 1.5);
+ }, 250);
+ timing(EditorOpacity, {
+ duration: 150,
+ toValue: 0,
+ easing: Easing.in(Easing.linear),
+ }).start();
+ timing(EditorTranslateY, {
+ duration: 150,
+ toValue: 150,
+ easing: Easing.in(Easing.linear),
+ }).start();
+ timing(EditorScale, {
+ duration: 150,
+ toValue: 0.99,
+ easing: Easing.in(Easing.linear),
+ }).start();
+
+ },20)
+
+
+
}
export const slideRight = {
diff --git a/apps/mobile/src/views/Editor/func.js b/apps/mobile/src/views/Editor/func.js
index 39736308b..695b1469e 100644
--- a/apps/mobile/src/views/Editor/func.js
+++ b/apps/mobile/src/views/Editor/func.js
@@ -1,12 +1,11 @@
-import { createRef } from 'react';
-import { Linking, Platform } from 'react-native';
-import { normalize } from '../../common/common';
-import { updateEvent } from '../../components/DialogManager/recievers';
-import { ACTIONS } from '../../provider/actions';
-import { eSendEvent } from '../../services/eventManager';
-import { refreshNotesPage } from '../../services/events';
-import { db, editing, timeConverter } from '../../utils/utils';
-
+import {createRef} from 'react';
+import {Linking, Platform} from 'react-native';
+import {normalize} from '../../common/common';
+import {updateEvent} from '../../components/DialogManager/recievers';
+import {ACTIONS} from '../../provider/actions';
+import {eSendEvent} from '../../services/eventManager';
+import {refreshNotesPage} from '../../services/events';
+import {db, editing, timeConverter} from '../../utils/utils';
export const EditorWebView = createRef();
@@ -21,9 +20,9 @@ export const injectedJS = `if (!window.location.search) {
}
`;
-export const INJECTED_JAVASCRIPT = premium => `(function() {
+export const INJECTED_JAVASCRIPT = (premium, noMenu) => `(function() {
setTimeout(() => {
- loadAction(${premium});
+ loadAction(${(premium, noMenu)});
},100)
})();`;
@@ -43,21 +42,20 @@ export function post(type, value = null) {
EditorWebView.current?.postMessage(JSON.stringify(message));
}
-export const _onShouldStartLoadWithRequest = (request) => {
+export const _onShouldStartLoadWithRequest = request => {
if (request.url.includes('https')) {
Linking.openURL(request.url);
return false;
} else {
return true;
}
-}
+};
export function checkNote() {
return note && note.id;
}
export async function loadNote(item) {
- //EditorWebView.current?.requestFocus();
editing.currentlyEditing = true;
updateEvent({type: ACTIONS.NOTES});
@@ -91,7 +89,6 @@ const onChange = data => {
export const _onMessage = evt => {
if (evt.nativeEvent.data === 'loaded') {
} else if (evt.nativeEvent.data !== '' && evt.nativeEvent.data !== 'loaded') {
-
clearTimeout(timer);
timer = null;
@@ -239,15 +236,10 @@ export async function saveNote(lockNote = true) {
post('saving', 'Saved');
}
-export function onWebViewLoad(noMenu,premium,colors) {
- EditorWebView.current?.injectJavaScript(INJECTED_JAVASCRIPT(premium));
-
- if (noMenu) {
- post('nomenu', true);
- } else {
- post('nomenu', false);
- }
-
+export function onWebViewLoad(noMenu, premium, colors) {
+ EditorWebView.current?.injectJavaScript(
+ INJECTED_JAVASCRIPT(premium, false),
+ );
if (note && note.id) {
updateEditor();
} else {
@@ -256,6 +248,16 @@ export function onWebViewLoad(noMenu,premium,colors) {
let c = {...colors};
c.factor = normalize(1);
post('theme', c);
+
+ /* setTimeout(() => {
+
+ if (noMenu) {
+ post('nomenu', true);
+ } else {
+ post('nomenu', false);
+ }
+
+ },1000) */
}
const updateEditor = async () => {
diff --git a/apps/mobile/src/views/Editor/index.js b/apps/mobile/src/views/Editor/index.js
index adff6a07b..cb3e492d4 100755
--- a/apps/mobile/src/views/Editor/index.js
+++ b/apps/mobile/src/views/Editor/index.js
@@ -42,6 +42,7 @@ import {
_onShouldStartLoadWithRequest,
checkNote,
} from './func';
+import {ActionIcon} from '../../components/ActionIcon';
var handleBack;
var tapCount = 0;
@@ -61,9 +62,9 @@ const Editor = ({noMenu}) => {
useEffect(() => {
if (noMenu) {
- post('nomenu', true);
+ //post('nomenu', true);
} else {
- post('nomenu', false);
+ //post('nomenu', false);
}
}, [noMenu]);
@@ -172,91 +173,60 @@ const Editor = ({noMenu}) => {
<View
style={{
marginTop: Platform.OS === 'ios' ? 0 : StatusBar.currentHeight,
- }}
- />
+ flexDirection: 'row',
+ width: '100%',
+ height: 50,
+ justifyContent: 'space-between',
+ }}>
+ {noMenu ? null : (
+ <ActionIcon
+ name="arrow-left"
+ color={colors.icon}
+ onPress={_onBackPress}
+ customStyle={{
+ marginLeft:-5
+ }}
+ />
+ )}
- {noMenu ? null : (
- <TouchableOpacity
- onPress={_onBackPress}
+ <View
style={{
- width: 60,
- height: 50,
- justifyContent: 'center',
- alignItems: 'flex-start',
- position: 'absolute',
- left: 0,
- top: 0,
- marginTop: Platform.OS === 'ios' ? 0 : StatusBar.currentHeight,
- paddingLeft: 12,
- zIndex: 800,
+ flexDirection: 'row',
}}>
- <Icon
- style={{
- marginLeft: -7,
- marginTop: -1.5,
- }}
- name="chevron-left"
- color={colors.icon}
- size={SIZE.xxxl - 3}
- />
- </TouchableOpacity>
- )}
+ {DDS.isTab && !fullscreen ? (
+ <ActionIcon
+ name="fullscreen"
+ color={colors.icon}
+ onPress={() => {
+ eSendEvent(eOpenFullscreenEditor);
+ setFullscreen(true);
+ editing.isFullscreen = true;
+ post(
+ JSON.stringify({
+ type: 'nomenu',
+ value: false,
+ }),
+ );
+ }}
+ />
+ ) : null}
- <View
- style={{
- flexDirection: 'row',
- marginRight: 0,
- position: 'absolute',
- marginTop: Platform.OS === 'ios' ? 0 : StatusBar.currentHeight,
- zIndex: 800,
- right: 0,
- top: 0,
- }}>
- {DDS.isTab && !fullscreen ? (
- <TouchableOpacity
+ <ActionIcon
+ name="dots-horizontal"
+ color={colors.icon}
onPress={() => {
- eSendEvent(eOpenFullscreenEditor);
- setFullscreen(true);
- editing.isFullscreen = true;
- post(
- JSON.stringify({
- type: 'nomenu',
- value: false,
- }),
+ ActionSheetEvent(
+ note,
+ true,
+ true,
+ ['Add to', 'Share', 'Export', 'Delete'],
+ ['Dark Mode', 'Add to Vault', 'Pin', 'Favorite'],
);
}}
- style={{
- width: 60,
- height: 50,
- justifyContent: 'center',
- alignItems: 'flex-end',
- paddingRight: 12,
- zIndex: 800,
- }}>
- <Icon name="fullscreen" color={colors.icon} size={SIZE.xxxl} />
- </TouchableOpacity>
- ) : null}
- <TouchableOpacity
- onPress={() => {
- ActionSheetEvent(
- note,
- true,
- true,
- ['Add to', 'Share', 'Export', 'Delete'],
- ['Dark Mode', 'Add to Vault', 'Pin', 'Favorite'],
- );
- }}
- style={{
- width: 60,
- height: 50,
- justifyContent: 'center',
- alignItems: 'flex-end',
- paddingRight: 12,
- zIndex: 800,
- }}>
- <Icon name="dots-horizontal" color={colors.icon} size={SIZE.xxxl} />
- </TouchableOpacity>
+ />
+ </View>
</View>
+
<WebView
ref={EditorWebView}
onError={error => console.log(error)}
diff --git a/apps/mobile/src/views/Login/index.js b/apps/mobile/src/views/Login/index.js
index 5cfb1eff6..1f10914c7 100644
--- a/apps/mobile/src/views/Login/index.js
+++ b/apps/mobile/src/views/Login/index.js
@@ -138,7 +138,7 @@ export const Login = ({route, navigation}) => {
dispatch({
type: ACTIONS.CONTAINER_STATE,
state: {
- noSelectionHeader: true,
+ noSelectionHeader: false,
},
});
dispatch({
diff --git a/apps/mobile/src/views/Settings/index.js b/apps/mobile/src/views/Settings/index.js
index a45bdfd5b..fb86fcd86 100644
--- a/apps/mobile/src/views/Settings/index.js
+++ b/apps/mobile/src/views/Settings/index.js
@@ -1,40 +1,18 @@
-import React, {useState, useEffect} from 'react';
-import {
- Platform,
- ScrollView,
- StatusBar,
- Text,
- TouchableOpacity,
- View,
- Modal,
- Clipboard,
- Linking,
-} from 'react-native';
+import { useIsFocused } from '@react-navigation/native';
+import React, { useEffect, useState } from 'react';
+import { Clipboard, Linking, Modal, Platform, ScrollView, StatusBar, Text, TouchableOpacity, View } from 'react-native';
+import * as Animatable from 'react-native-animatable';
import MMKV from 'react-native-mmkv-storage';
-import Icon from 'react-native-vector-icons/MaterialCommunityIcons';
import QRCode from 'react-native-qrcode-generator';
-import {
- ACCENT,
- COLOR_SCHEME,
- COLOR_SCHEME_DARK,
- COLOR_SCHEME_LIGHT,
- opacity,
- pv,
- setColorScheme,
- SIZE,
- WEIGHT,
- ph,
-} from '../../common/common';
-import Container from '../../components/Container';
-import {useTracked} from '../../provider';
-import {ACTIONS} from '../../provider/actions';
-import {eSendEvent} from '../../services/eventManager';
-import {eOpenLoginDialog} from '../../services/events';
+import Icon from 'react-native-vector-icons/MaterialCommunityIcons';
+import { ACCENT, COLOR_SCHEME, COLOR_SCHEME_DARK, COLOR_SCHEME_LIGHT, opacity, ph, pv, setColorScheme, SIZE, WEIGHT } from '../../common/common';
+import { Toast } from '../../components/Toast';
+import { useTracked } from '../../provider';
+import { ACTIONS } from '../../provider/actions';
+import { eSendEvent } from '../../services/eventManager';
+import { eOpenLoginDialog, eResetApp } from '../../services/events';
import NavigationService from '../../services/NavigationService';
-import {hexToRGBA, w, DDS, setSetting, db, ToastEvent} from '../../utils/utils';
-import {Toast} from '../../components/Toast';
-import {useIsFocused} from '@react-navigation/native';
-import * as Animatable from 'react-native-animatable';
+import { db, DDS, setSetting, ToastEvent, w } from '../../utils/utils';
export const Settings = ({route, navigation}) => {
const [state, dispatch] = useTracked();
@@ -384,7 +362,9 @@ export const Settings = ({route, navigation}) => {
onPress={() => {
DDS.isTab
? eSendEvent(eOpenLoginDialog)
- : NavigationService.navigate('Login');
+ : NavigationService.navigate('Login', {
+ root: true,
+ });
}}
activeOpacity={opacity / 2}
style={{
@@ -586,6 +566,8 @@ export const Settings = ({route, navigation}) => {
: (scale = 0.9 ? (scale = 1) : (scale = 1));
await setSetting(settings, 'fontScale', scale);
+
+ eSendEvent(eResetApp);
}}
activeOpacity={opacity}
style={{
diff --git a/apps/mobile/src/views/Signup/index.js b/apps/mobile/src/views/Signup/index.js
index bfcb9c442..44f321945 100644
--- a/apps/mobile/src/views/Signup/index.js
+++ b/apps/mobile/src/views/Signup/index.js
@@ -155,7 +155,7 @@ export const Signup = ({route, navigation}) => {
dispatch({
type: ACTIONS.CONTAINER_STATE,
state: {
- noSelectionHeader: true,
+ noSelectionHeader: false,
},
});
dispatch({