Skip to content

Commit 1c9a23f

Browse files
release v3.2.2
1 parent ed79eb8 commit 1c9a23f

File tree

13 files changed

+460
-378
lines changed

13 files changed

+460
-378
lines changed

assets/images/drawer/blog.png

214 Bytes
Loading

assets/images/pages/blog.png

408 Bytes
Loading

assets/images/pages/login.png

449 Bytes
Loading

changelog.md

+11
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,16 @@
11
# Changelog
22

3+
## [3.2.2]
4+
5+
### Features
6+
- Add blog link to the drawer.
7+
- Add Blog/Login images to Pages.
8+
9+
### Fixed
10+
- Fixed indents of Components page.
11+
- Fixed bottom nav bar on IOS devices.
12+
- Fixed touchable spacing of top nav Arrow/Burger button.
13+
314
## [3.2.1]
415

516
Update some libs

src/modules/calendar/CalendarState.js

-2
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,6 @@ export function loadItems(day) {
4040
newItems[key] = items[key];
4141
});
4242

43-
console.log(newItems);
44-
4543
dispatch(itemsLoaded(newItems));
4644
};
4745
}

src/modules/components/ComponentsView.js

+17-13
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,14 @@
11
import React from 'react';
22
import { StyleSheet, View, Text, ScrollView } from 'react-native';
3+
import { useRoute } from '@react-navigation/native';
34

45
import Icon from 'react-native-vector-icons/Entypo';
56
import { colors, fonts } from '../../styles';
67

78
import { Button, RadioGroup, Dropdown } from '../../components';
89

910
export default function ComponentsScreen(props) {
11+
const route = useRoute();
1012
return (
1113
<ScrollView
1214
style={styles.container}
@@ -48,55 +50,55 @@ export default function ComponentsScreen(props) {
4850

4951
<View style={styles.demoButtonsContainer}>
5052
<Button
51-
style={styles.demoButton}
53+
style={[styles.demoButton, {flexBasis: '47%'}]}
5254
primary
5355
caption="Button"
5456
onPress={() => {}}
5557
/>
5658
<Button
57-
style={styles.demoButton}
59+
style={[styles.demoButton, {flexBasis: '47%'}]}
5860
secondary
5961
caption="Button"
6062
onPress={() => {}}
6163
/>
6264
<Button
63-
style={styles.demoButton}
65+
style={[styles.demoButton, {flexBasis: '47%'}]}
6466
primary
6567
rounded
6668
caption="Button"
6769
onPress={() => {}}
6870
/>
6971
<Button
70-
style={styles.demoButton}
72+
style={[styles.demoButton, {flexBasis: '47%'}]}
7173
secondary
7274
rounded
7375
caption="Button"
7476
onPress={() => {}}
7577
/>
7678
<Button
77-
style={styles.demoButton}
79+
style={[styles.demoButton, {flexBasis: '47%'}]}
7880
primary
7981
bordered
8082
caption="Button"
8183
onPress={() => {}}
8284
/>
8385
<Button
84-
style={styles.demoButton}
86+
style={[styles.demoButton, {flexBasis: '47%'}]}
8587
secondary
8688
bordered
8789
caption="Button"
8890
onPress={() => {}}
8991
/>
9092
<Button
91-
style={styles.demoButton}
93+
style={[styles.demoButton, {flexBasis: '47%'}]}
9294
primary
9395
bordered
9496
rounded
9597
caption="Button"
9698
onPress={() => {}}
9799
/>
98100
<Button
99-
style={styles.demoButton}
101+
style={[styles.demoButton, {flexBasis: '47%'}]}
100102
secondary
101103
bordered
102104
rounded
@@ -325,7 +327,7 @@ export default function ComponentsScreen(props) {
325327
</View>
326328

327329
<Button
328-
style={[styles.demoButton, { width: 200, alignSelf: 'center' }]}
330+
style={[styles.demoButton, { flex: 1 }]}
329331
primary
330332
bordered
331333
caption="More Icons"
@@ -336,7 +338,7 @@ export default function ComponentsScreen(props) {
336338
<Text style={styles.componentSectionHeader}>Dropdown</Text>
337339

338340
<Dropdown
339-
style={{ width: 200, alignSelf: 'center' }}
341+
style={{ width: '100%', alignSelf: 'center' }}
340342
onSelect={() => {}}
341343
items={['option 1', 'option 2']}
342344
/>
@@ -354,14 +356,15 @@ const styles = StyleSheet.create({
354356
},
355357
componentsSection: {
356358
backgroundColor: colors.white,
357-
padding: 15,
359+
paddingHorizontal: 16,
360+
paddingVertical: 24,
358361
marginBottom: 20,
359362
borderRadius: 5,
360363
},
361364
componentSectionHeader: {
362365
fontFamily: fonts.primaryRegular,
363366
color: '#686868',
364-
fontSize: 20,
367+
fontSize: 24,
365368
marginBottom: 20,
366369
},
367370
demoButtonsContainer: {
@@ -376,7 +379,8 @@ const styles = StyleSheet.create({
376379
flexWrap: 'wrap',
377380
flex: 1,
378381
alignItems: 'center',
379-
justifyContent: 'space-around',
382+
justifyContent: 'space-between',
383+
paddingHorizontal: 3,
380384
marginBottom: 20,
381385
},
382386
demoButton: {

src/modules/home/HomeView.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ export default function HomeScreen({ isExtended, setIsExtended }) {
5050
<View style={styles.priceContainer}>
5151
<View style={{ flexDirection: 'row' }}>
5252
<Text white bold size={50} style={styles.price}>
53-
{isExtended ? '$199.95' : '$49.95'}
53+
{isExtended ? '$499' : '$99'}
5454
</Text>
5555
</View>
5656
<TouchableOpacity

src/modules/navigation/MainTabNavigator.js

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import * as React from 'react';
2-
import { Text, View, Image, StyleSheet } from 'react-native';
2+
import { Text, View, Image, StyleSheet, Platform } from 'react-native';
33
import { createBottomTabNavigator } from '@react-navigation/bottom-tabs';
44
import { colors } from '../../styles';
55

@@ -9,7 +9,7 @@ const Tab = createBottomTabNavigator();
99

1010
export default function BottomTabs() {
1111
return (
12-
<Tab.Navigator>
12+
<Tab.Navigator tabBarOptions={{style: {height: Platform.OS === 'ios' ? 90 : 50}}}>
1313
{tabNavigationData.map((item, idx) => (
1414
<Tab.Screen
1515
key={`tab_item${idx+1}`}
@@ -25,8 +25,8 @@ export default function BottomTabs() {
2525
/>
2626
</View>
2727
),
28-
tabBarLabel: ({ focused }) => <Text style={{ fontSize: 12, color: focused ? colors.primary : colors.gray }}>{item.name}</Text>
29-
}}
28+
tabBarLabel: ({ focused }) => <Text style={{ fontSize: 12, color: focused ? colors.primary : colors.gray }}>{item.name}</Text>,
29+
}}
3030
/>
3131
))}
3232
</Tab.Navigator>
@@ -35,12 +35,12 @@ export default function BottomTabs() {
3535

3636
const styles = StyleSheet.create({
3737
tabBarItemContainer: {
38-
flex: 1,
3938
alignItems: 'center',
4039
justifyContent: 'center',
4140
borderBottomWidth: 2,
4241
borderBottomColor: colors.white,
4342
paddingHorizontal: 10,
43+
bottom: Platform.OS === 'ios' ? -5 : 0,
4444
},
4545
tabBarIcon: {
4646
width: 23,
@@ -49,4 +49,4 @@ const styles = StyleSheet.create({
4949
tabBarIconFocused: {
5050
tintColor: colors.primary,
5151
},
52-
});
52+
});

src/modules/navigation/Navigator.js

+17-2
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ const iconGrids = require('../../../assets/images/drawer/grids.png');
1515
const iconPages = require('../../../assets/images/drawer/pages.png');
1616
const iconComponents = require('../../../assets/images/drawer/components.png');
1717
const iconSettings = require('../../../assets/images/drawer/settings.png');
18+
const iconBlog = require('../../../assets/images/drawer/blog.png')
1819

1920
const drawerData = [
2021
{
@@ -63,15 +64,28 @@ function CustomDrawerContent(props) {
6364
style={styles.menuLabelFlex}>
6465
<Image
6566
style={{ width: 20, height: 20}}
66-
source={iconHome}
67+
source={item.icon}
6768
/>
6869
<Text style={styles.menuTitle}>{item.name}</Text>
6970
</View>
7071
)}
7172
onPress={() => props.navigation.navigate(item.name)}
72-
/>
73+
/>
7374
))}
7475
<View style={styles.divider} />
76+
<DrawerItem
77+
label={() => (
78+
<View style={styles.menuLabelFlex}>
79+
<Image
80+
style={{ width: 20, height: 20}}
81+
source={iconBlog}
82+
/>
83+
<Text style={styles.menuTitle}>Blog</Text>
84+
</View>
85+
)}
86+
onPress={() => props.navigation.navigate('Blog')}
87+
/>
88+
<View style={styles.divider} />
7589
<DrawerItem
7690
label={() => (
7791
<View style={styles.menuLabelFlex}>
@@ -89,6 +103,7 @@ function CustomDrawerContent(props) {
89103
}
90104

91105
export default function App() {
106+
92107
return (
93108
<Drawer.Navigator
94109
drawerStyle={{

src/modules/navigation/RootNavigation.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@ export default function NavigatorView(props) {
1818
<TouchableOpacity
1919
onPress={() => props.navigation.toggleDrawer()}
2020
style={{
21-
paddingLeft: 10,
21+
paddingHorizontal: 16,
22+
paddingVertical: 12,
2223
}}
2324
>
2425
<Image
@@ -62,4 +63,4 @@ const styles = StyleSheet.create({
6263
width: 100 + '%',
6364
height: Header.height,
6465
},
65-
});
66+
});

src/modules/navigation/stackNavigationData.js

+14-2
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,8 @@ const headerLeftComponent = (props) => {
1919
<TouchableOpacity
2020
onPress={props.onPress}
2121
style={{
22-
paddingLeft: 10,
22+
paddingHorizontal: 16,
23+
paddingVertical: 12,
2324
}}
2425
>
2526
<Image
@@ -58,6 +59,17 @@ const StackNavigationData = [
5859
fontSize: 18,
5960
},
6061
},
62+
{
63+
name: 'Blog',
64+
component: AvailableInFullVersion,
65+
headerLeft: headerLeftComponent,
66+
headerBackground: { source: headerBackground },
67+
headerTitleStyle: {
68+
fontFamily: fonts.primaryRegular,
69+
color: colors.white,
70+
fontSize: 18,
71+
},
72+
},
6173
{
6274
name: 'Gallery',
6375
component: GalleryScreen,
@@ -126,4 +138,4 @@ const StackNavigationData = [
126138
},
127139
]
128140

129-
export default StackNavigationData;
141+
export default StackNavigationData;

src/modules/pages/PagesView.js

+33-2
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ const calendarIcon = require('../../../assets/images/pages/calendar.png');
88
const chatIcon = require('../../../assets/images/pages/chat.png');
99
const galleryIcon = require('../../../assets/images/pages/gallery.png');
1010
const profileIcon = require('../../../assets/images/pages/profile.png');
11+
const loginIcon = require('../../../assets/images/pages/login.png');
12+
const blogIcon = require('../../../assets/images/pages/blog.png');
1113

1214
export default function PagesScreen(props) {
1315
return (
@@ -70,15 +72,33 @@ export default function PagesScreen(props) {
7072
/>
7173
<Text style={styles.itemText}>Calendar</Text>
7274
</TouchableOpacity>
73-
<TouchableOpacity onPress={() => {}} style={styles.item}>
75+
<TouchableOpacity
76+
onPress={() => props.navigation.navigate('Auth')}
77+
style={styles.item}
78+
>
7479
<Image
7580
resizeMode="contain"
76-
source={profileIcon}
81+
source={loginIcon}
82+
tintColor={colors.primary}
7783
style={styles.itemImage}
7884
/>
7985
<Text style={styles.itemText}>Login</Text>
8086
</TouchableOpacity>
8187
</View>
88+
<View style={styles.row}>
89+
<TouchableOpacity
90+
onPress={() => props.navigation.navigate('Blog')}
91+
style={styles.blogItem}
92+
>
93+
<Image
94+
resizeMode="contain"
95+
source={blogIcon}
96+
tintColor={colors.primary}
97+
style={styles.itemImage}
98+
/>
99+
<Text style={styles.itemText}>Blog</Text>
100+
</TouchableOpacity>
101+
</View>
82102
</View>
83103
);
84104
}
@@ -105,6 +125,17 @@ const styles = StyleSheet.create({
105125
justifyContent: 'space-around',
106126
marginHorizontal: 5,
107127
},
128+
blogItem: {
129+
width: '31%',
130+
height: 120,
131+
paddingVertical: 20,
132+
borderColor: colors.primaryLight,
133+
borderWidth: 1,
134+
borderRadius: 5,
135+
alignItems: 'center',
136+
justifyContent: 'space-around',
137+
marginHorizontal: 5,
138+
},
108139
itemText: {
109140
color: colors.primary,
110141
fontFamily: fonts.primary,

0 commit comments

Comments
 (0)