Skip to content

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

minor cleanup

ammarahm-edcce89c091d49
diff --git a/apps/mobile/src/components/Header/index.js b/apps/mobile/src/components/Header/index.js
index 0c244db82..6341a679b 100644
--- a/apps/mobile/src/components/Header/index.js
+++ b/apps/mobile/src/components/Header/index.js
@@ -1,18 +1,19 @@
-import React, { useEffect, useState } from 'react';
-import { Platform, StyleSheet, View } from 'react-native';
-import { useSafeAreaInsets } from 'react-native-safe-area-context';
-import { useTracked } from '../../provider';
-import { eSubscribeEvent, eUnSubscribeEvent } from '../../services/EventManager';
+import React, {useEffect, useState} from 'react';
+import {Platform, StyleSheet, View} from 'react-native';
+import Animated from 'react-native-reanimated';
+import {useSafeAreaInsets} from 'react-native-safe-area-context';
+import {useTracked} from '../../provider';
+import {eSubscribeEvent, eUnSubscribeEvent} from '../../services/EventManager';
import Navigation from '../../services/Navigation';
-import { dWidth } from '../../utils';
-import { eScrollEvent } from '../../utils/Events';
-import { SIZE } from '../../utils/SizeUtils';
-import { ActionIcon } from '../ActionIcon';
-import { SearchInput } from '../SearchInput';
-import { HeaderLeftMenu } from './HeaderLeftMenu';
-import { HeaderRightMenu } from './HeaderRightMenu';
-import { HeaderTitle } from './HeaderTitle';
+import {dWidth} from '../../utils';
+import {eScrollEvent} from '../../utils/Events';
+import {SIZE} from '../../utils/SizeUtils';
+import {ActionIcon} from '../ActionIcon';
+import {SearchInput} from '../SearchInput';
+import {HeaderLeftMenu} from './HeaderLeftMenu';
+import {HeaderRightMenu} from './HeaderRightMenu';
+import {HeaderTitle} from './HeaderTitle';
export const Header = ({root}) => {
const [state] = useTracked();
@@ -51,11 +52,14 @@ export const Header = ({root}) => {
<View style={styles.leftBtnContainer}>
<HeaderLeftMenu />
- {Platform.OS === 'android' && currentScreen !== 'search' || Platform.isPad ? (
+ {(Platform.OS === 'android' && currentScreen !== 'search') ||
+ Platform.isPad ? (
<HeaderTitle root={root} />
) : null}
</View>
- {Platform.OS !== 'android' && !Platform.isPad && currentScreen !== 'search' ? (
+ {Platform.OS !== 'android' &&
+ !Platform.isPad &&
+ currentScreen !== 'search' ? (
<HeaderTitle root={root} />
) : null}
@@ -69,11 +73,11 @@ export const Header = ({root}) => {
) : null}
{currentScreen === 'search' ? (
- <View style={[styles.rightBtnContainer,{right:6}]}>
+ <View style={[styles.rightBtnContainer, {right: 6}]}>
<ActionIcon
onPress={async () => {
- Navigation.navigate('Search',{
- menu:false
+ Navigation.navigate('Search', {
+ menu: false,
});
}}
name="tune"
@@ -83,7 +87,7 @@ export const Header = ({root}) => {
/>
</View>
) : (
- <HeaderRightMenu/>
+ <HeaderRightMenu />
)}
</View>
);
diff --git a/apps/mobile/src/services/SearchService.js b/apps/mobile/src/services/SearchService.js
index 7d2154ea7..f194bbc4c 100644
--- a/apps/mobile/src/services/SearchService.js
+++ b/apps/mobile/src/services/SearchService.js
@@ -14,7 +14,6 @@ function update(data) {
}
async function search(term) {
- console.log(term, term.length);
if (!term || term.length === 0) {
updateEvent({
type: Actions.SEARCH_RESULTS,
@@ -28,7 +27,6 @@ async function search(term) {
searchInformation.data,
term,
);
- console.log(results.length);
if (!results || results.length === 0) {
ToastEvent.show('No search results found for ' + term, 'error');
return;