A fully open source & end-to-end encrypted note taking alternative to Evernote.
TypeScript asp-net-coredotnet-coreelectronfosshacktoberfestnote-managmentnote-takingnote-taking-appnotebooknotesnotes-appopen-sourceopensourceprivacyproductivityreactreact-nativereactjsself-hosted
minor fixes
ammarahm-ed2e59886d264e
diff --git a/apps/mobile/src/components/Menu/index.js b/apps/mobile/src/components/Menu/index.jsindex 59cc5a17a..a6078cf65 100644--- a/apps/mobile/src/components/Menu/index.js+++ b/apps/mobile/src/components/Menu/index.js@@ -40,8 +40,7 @@ export const Menu = ({noTextMode = false,}) => {const [state, dispatch] = useTracked();- const {colors} = state;- const [tags, setTags] = useState([]);+ const {colors, tags} = state;// todolet overlayRef;@@ -53,15 +52,14 @@ export const Menu = ({dispatch({type: ACTIONS.THEME, colors: newColors});}- useEffect(() => {- let allTags = db.getTags();- let tagsToAdd = [];+ /* useEffect(() => {+ let allTags = tags;allTags.sort((a, b) => {return a.count > b.count;});setTags([...allTags]);- }, []);+ }, []); */const listItems = [{diff --git a/apps/mobile/src/views/Tags/index.js b/apps/mobile/src/views/Tags/index.jsindex 166de8fa3..0afd6024e 100644--- a/apps/mobile/src/views/Tags/index.js+++ b/apps/mobile/src/views/Tags/index.js@@ -7,6 +7,7 @@ import {View,TouchableOpacity,RefreshControl,+ Platform,} from 'react-native';import {pv, SIZE, WEIGHT} from '../../common/common';import {Header} from '../../components/header';@@ -15,25 +16,26 @@ import {useTracked} from '../../provider';import {ACTIONS} from '../../provider/actions';import {db} from '../../../App';import NavigationService from '../../services/NavigationService';+import Container from '../../components/Container';const w = Dimensions.get('window').width;const h = Dimensions.get('window').height;export const Tags = ({navigation}) => {const [state, dispatch] = useTracked();- const {colors, tags} = state;+ const {colors, tags, selectionMode} = state;const [refreshing, setRefreshing] = useState(false);useEffect(() => {dispatch({type: ACTIONS.TAGS});}, []);return (- <SafeAreaView- style={{- height: '100%',- backgroundColor: colors.bg,- }}>- <Header canGoBack={false} heading="Tags" menu={true} />-+ <Container+ canGoBack={false}+ heading="Tags"+ noBottomButton={true}+ placeholder="Search for #tags"+ data={tags}+ menu><Viewstyle={{width: '100%',@@ -45,6 +47,20 @@ export const Tags = ({navigation}) => {style={{height: '100%',}}+ ListHeaderComponent={+ <View+ style={{+ marginTop:+ Platform.OS == 'ios'+ ? tags[0] && !selectionMode+ ? 135+ : 135 - 60+ : tags[0] && !selectionMode+ ? 155+ : 155 - 60,+ }}+ />+ }refreshControl={<RefreshControltintColor={colors.accent}@@ -129,14 +145,18 @@ export const Tags = ({navigation}) => {fontSize: SIZE.xs,color: colors.icon,}}>- {item.count} note+ {item && item.count && item.count > 1+ ? item.count + ' notes'+ : item.count === 1+ ? item.count + ' note'+ : null}</Text></Text></TouchableOpacity>)}/></View>- </SafeAreaView>+ </Container>);};