Skip to content

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

add icons on note item

ammarahm-ed4cc7331852c7
diff --git a/apps/mobile/src/components/NoteItem/index.js b/apps/mobile/src/components/NoteItem/index.js
index b2dc1cb27..8d6c4114e 100644
--- a/apps/mobile/src/components/NoteItem/index.js
+++ b/apps/mobile/src/components/NoteItem/index.js
@@ -101,15 +101,35 @@ const NoteItem = props => {
{item.headline}
</Text>
- <Text
+ <View
style={{
- color: colors.accent,
- fontSize: SIZE.xxs + 2,
- textAlignVertical: 'center',
- fontFamily: WEIGHT.regular,
+ flexDirection: 'row',
+ justifyContent: 'flex-start',
+ alignItems: 'center',
}}>
- {timeSince(item.dateCreated) + ' '}
- </Text>
+ <Icon
+ style={{width: 30}}
+ name="lock"
+ size={SIZE.sm}
+ color={colors.icon}
+ />
+ <Icon
+ style={{width: 30}}
+ name="star"
+ size={SIZE.sm}
+ color={colors.icon}
+ />
+
+ <Text
+ style={{
+ color: colors.accent,
+ fontSize: SIZE.xxs + 2,
+ textAlignVertical: 'center',
+ fontFamily: WEIGHT.regular,
+ }}>
+ {timeSince(item.dateCreated) + ' '}
+ </Text>
+ </View>
</View>
</>
</TouchableOpacity>
@@ -138,6 +158,16 @@ const NoteItem = props => {
<Icon name="more-vertical" size={SIZE.lg} color={colors.icon} />
</TouchableOpacity>
}>
+ <MenuItem
+ textStyle={{
+ color: colors.pri,
+
+ fontFamily: WEIGHT.regular,
+ fontSize: SIZE.sm,
+ }}>
+ <Icon name="star" size={SIZE.sm} color={colors.icon} />
+ {' '}Pin
+ </MenuItem>
<MenuItem
onPress={() => {
setMenuRef[props.index].hide();
@@ -169,26 +199,6 @@ const NoteItem = props => {
{' '}Share
</MenuItem>
- <MenuItem
- onPress={() => {
- setMenuRef[props.index].hide();
- ToastEvent.show(
- 'Note copied to clipboard.',
- 'success',
- 3000,
- () => {},
- '',
- );
- }}
- textStyle={{
- color: colors.pri,
-
- fontFamily: WEIGHT.regular,
- fontSize: SIZE.sm,
- }}>
- <Icon name="copy" size={SIZE.sm} color={colors.icon} />
- {' '}Copy
- </MenuItem>
<MenuItem
onPress={() => {
setMenuRef[props.index].hide();
diff --git a/apps/mobile/src/components/NotebookItem/index.js b/apps/mobile/src/components/NotebookItem/index.js
index a5f627904..a767c86c5 100644
--- a/apps/mobile/src/components/NotebookItem/index.js
+++ b/apps/mobile/src/components/NotebookItem/index.js
@@ -96,22 +96,38 @@ export const NotebookItem = ({
</View>
)}
- <Text
- style={{
- fontFamily: WEIGHT.regular,
- fontSize: SIZE.xs,
- paddingTop: pv / 2,
- }}>
- {isTopic ? null : (
+ {isTopic ? null : (
+ <View
+ style={{
+ flexDirection: 'row',
+ justifyContent: 'flex-start',
+ alignItems: 'center',
+ marginTop: 5,
+ }}>
+ <Icon
+ style={{width: 30}}
+ name="lock"
+ size={SIZE.sm}
+ color={colors.icon}
+ />
+ <Icon
+ style={{width: 30}}
+ name="star"
+ size={SIZE.sm}
+ color={colors.icon}
+ />
+
<Text
style={{
color: colors.accent,
+ fontSize: SIZE.xxs + 2,
+ textAlignVertical: 'center',
+ fontFamily: WEIGHT.regular,
}}>
- {new Date(item.dateCreated).toDateString().substring(4)} {' '}
+ {new Date(item.dateCreated).toDateString().substring(4)}
</Text>
- )}
- 15 notes
- </Text>
+ </View>
+ )}
</View>
{hideMore ? null : (
@@ -132,6 +148,36 @@ export const NotebookItem = ({
<Icon name="more-vertical" size={SIZE.lg} color={colors.icon} />
</TouchableOpacity>
}>
+ <MenuItem
+ textStyle={{
+ color: colors.pri,
+
+ fontFamily: WEIGHT.regular,
+ fontSize: SIZE.sm,
+ }}>
+ <Icon name="star" size={SIZE.sm} color={colors.icon} />
+ {' '}Pin
+ </MenuItem>
+ <MenuItem
+ onPress={() => {
+ setMenuRef[props.index].hide();
+ ToastEvent.show(
+ 'Note added to favorites.',
+ 'success',
+ 3000,
+ () => {},
+ 'Ok',
+ );
+ }}
+ textStyle={{
+ color: colors.pri,
+
+ fontFamily: WEIGHT.regular,
+ fontSize: SIZE.sm,
+ }}>
+ <Icon name="star" size={SIZE.sm} color={colors.icon} />
+ {' '}Favorite
+ </MenuItem>
<MenuItem
onPress={() => {
setVisible(true);
diff --git a/apps/mobile/src/views/AccountSettings/index.js b/apps/mobile/src/views/AccountSettings/index.js
index 8a86fa8d7..4cf9bffe5 100644
--- a/apps/mobile/src/views/AccountSettings/index.js
+++ b/apps/mobile/src/views/AccountSettings/index.js
@@ -146,7 +146,6 @@ export const AccountSettings = ({navigation}) => {
width: '90%',
marginHorizontal: '5%',
paddingHorizontal: ph,
-
paddingVertical: pv + 5,
flexDirection: 'row',
justifyContent: 'space-between',