Skip to content

Commit

Permalink
Update user interface.
Browse files Browse the repository at this point in the history
close #71
  • Loading branch information
ivgraai committed Aug 1, 2020
1 parent 435e253 commit c220d20
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 4 deletions.
1 change: 1 addition & 0 deletions app.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@

},
"description": "This app does help you with keeping track of your perishable foods by notifications, etc. Moreover you can share these goods with others if you think.",
"primaryColor": "#556b2f",
"extra": {
"init": false,
"serverUrl": "http://192.168.8.104:8080/v1/",
Expand Down
27 changes: 23 additions & 4 deletions constants/styles/DateTimePickerModal.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,22 @@ const backgroundColor = "transparent";
const fontSize = PixelRatio.getFontScale() * Layout.largerFontSize;
const buttonHeight = PixelRatio.getPixelSizeForLayoutSize(23.5);
const buttonFontWeight = "normal";
const borderRadius = 13;

export const styles: any = (isDark: boolean) => StyleSheet.create({
headerRoot: {
borderBottomColor: Layout.borderColor,
borderBottomWidth: StyleSheet.hairlineWidth,
padding: PixelRatio.getPixelSizeForLayoutSize(7),
backgroundColor
backgroundColor,
borderLeftColor: Layout.borderColor,
borderLeftWidth: Layout.borderWidth,
borderTopLeftRadius: borderRadius,
borderTopColor: Layout.borderColor,
borderTopWidth: Layout.borderWidth,
borderTopRightRadius: borderRadius,
borderRightColor: Layout.borderColor,
borderRightWidth: Layout.borderWidth
},
headerText: {
textAlign: "center",
Expand All @@ -24,7 +33,15 @@ export const styles: any = (isDark: boolean) => StyleSheet.create({
borderTopWidth: StyleSheet.hairlineWidth,
backgroundColor,
height: buttonHeight,
justifyContent: "center"
justifyContent: "center",
borderLeftColor: Layout.borderColor,
borderLeftWidth: Layout.borderWidth,
borderBottomLeftRadius: borderRadius,
borderBottomColor: Layout.borderColor,
borderBottomWidth: Layout.borderWidth,
borderBottomRightRadius: borderRadius,
borderRightColor: Layout.borderColor,
borderRightWidth: Layout.borderWidth
},
confirmText: {
textAlign: "center",
Expand All @@ -34,11 +51,13 @@ export const styles: any = (isDark: boolean) => StyleSheet.create({
backgroundColor
},
cancelButton: {
borderRadius: 13,
borderRadius: borderRadius,
height: buttonHeight,
marginBottom: 0,
justifyContent: "center",
backgroundColor: isDark ? "#0E0E0E" : "white"
backgroundColor: isDark ? "#0E0E0E" : "white",
borderColor: Layout.borderColor,
borderWidth: Layout.borderWidth
},
cancelText: {
padding: PixelRatio.getPixelSizeForLayoutSize(5),
Expand Down
6 changes: 6 additions & 0 deletions constants/styles/MainScreen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,12 @@ export const styles = (isDark: boolean) => StyleSheet.create({
width: Layout.widthPercentageAsString,
maxHeight: "40%"
},
dataExpirationDateModal: {
borderLeftColor: Layout.borderColor,
borderLeftWidth: Layout.borderWidth,
borderRightColor: Layout.borderColor,
borderRightWidth: Layout.borderWidth
},
dataLocationCheckBoxContainer: {
marginTop: PixelRatio.getPixelSizeForLayoutSize(-3),
backgroundColor: "transparent",
Expand Down
1 change: 1 addition & 0 deletions screens/MainScreen.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -287,6 +287,7 @@ class MainScreen extends React.Component<IComponentProps, IComponentState> {
customHeaderIOS={dateTimePickerHeader}
customConfirmButtonIOS={dateTimePickerConfirmButton}
customCancelButtonIOS={dateTimePickerCancelButton}
style={withStyle.dataExpirationDateModal}
/>
</View>
<CheckBox
Expand Down

0 comments on commit c220d20

Please sign in to comment.