Skip to content

Commit 80e5695

Browse files
authored
Merge pull request #108 from mendix/develop
Merge develop in to release
2 parents fa4aff2 + c6aa9c5 commit 80e5695

27 files changed

+379
-150
lines changed

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "atlas-ui-framework",
3-
"version": "2.6.3",
3+
"version": "2.6.4",
44
"description": "Mendix Atlas UI is the foundation of making beautiful apps with Mendix. For more information about the framework go to https://atlas.mendix.com.",
55
"main": "",
66
"scripts": {
@@ -23,4 +23,4 @@
2323
"react-native-device-info": "^5.5.3"
2424
},
2525
"dependencies": {}
26-
}
26+
}

styles/native/js/app/custom-variables.js

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,14 @@ export const brand = {
2323
dangerLight: `rgba(${anyColorToRgbString("#ed1c24")}, 0.14)`,
2424
};
2525
//
26+
// Safely check if Appearance API is available in this version of React Native
27+
const Appearance = require("react-native").Appearance;
2628
// Dark Mode - Inherits OS theme if possible
2729
export const darkMode = NativeModules && NativeModules.RNDarkMode && NativeModules.RNDarkMode.initialMode
2830
? NativeModules.RNDarkMode.initialMode === "dark"
29-
: false;
31+
: Appearance
32+
? Appearance.getColorScheme() === "dark"
33+
: false;
3034
//
3135
// Background Colors
3236
const backgroundColor = darkMode ? "#000" : "#FFF";
@@ -151,6 +155,7 @@ export const input = {
151155
labelColor: font.color,
152156
labelColorDisabled: font.labelColorDisabled,
153157
borderColor: contrast.lower,
158+
borderColorFocused: "",
154159
backgroundColor: background.primary,
155160
backgroundColorDisabled: contrast.lowest,
156161
selectionColor: contrast.lower,
@@ -255,13 +260,13 @@ export const tabContainer = {
255260
backgroundColor: badge.default.backgroundColor,
256261
paddingVertical: badge.paddingVertical,
257262
paddingHorizontal: badge.paddingHorizontal,
258-
marginLeft: 8
263+
marginLeft: 8,
259264
},
260265
badgeCaption: {
261266
fontSize: font.size,
262267
color: badge.default.color,
263268
fontWeight: badge.fontWeight,
264-
}
269+
},
265270
};
266271
//
267272
// ListView Styles
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
22
"name": "Atlas-UI-Framework",
3-
"version": "2.6.3"
3+
"version": "2.6.4"
44
}

styles/native/js/core/variables.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,7 @@ let input = {
151151
labelColor: font.color,
152152
labelColorDisabled: font.labelColorDisabled,
153153
borderColor: contrast.lower,
154+
borderColorFocused: brand.primary,
154155
backgroundColor: background.primary,
155156
backgroundColorDisabled: background.secondary,
156157
selectionColor: contrast.lower,

styles/native/js/core/widgets/dropdown.js

Lines changed: 29 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -32,27 +32,37 @@ export const DropDown = {
3232
value: {
3333
// All TextStyle properties & placeholderTextColor are allowed
3434
color: input.color,
35-
borderColor: input.borderColor,
36-
backgroundColor: input.backgroundColor,
3735
fontSize: input.fontSize,
3836
fontFamily: input.fontFamily,
39-
borderWidth: input.borderWidth,
40-
borderRadius: input.borderRadius,
41-
paddingHorizontal: input.paddingHorizontal,
42-
paddingVertical: input.paddingVertical,
4337
placeholderTextColor: input.placeholderTextColor,
4438
},
45-
valueDisabled: {
46-
// All TextStyle properties are allowed
47-
...TextBox.inputDisabled
48-
},
4939
validationMessage: {
5040
// All TextStyle properties are allowed
5141
...TextBox.validationMessage,
5242
},
5343
/* New dropdown styles start */
44+
valueFocused: {
45+
// All TextStyle properties are allowed
46+
},
47+
valueDisabled: {
48+
// All TextStyle properties are allowed
49+
...TextBox.inputDisabled
50+
},
5451
valueContainer: {
55-
// All ViewStyle properties & rippleColor & activeOpacity & underlayColor are allowed
52+
// All ViewStyle properties & rippleColor are allowed
53+
flexDirection: "row",
54+
justifyContent: "space-between",
55+
alignItems: "center",
56+
borderWidth: input.borderWidth,
57+
borderRadius: input.borderRadius,
58+
borderColor: input.borderColor,
59+
paddingHorizontal: input.paddingHorizontal,
60+
paddingVertical: input.paddingVertical,
61+
backgroundColor: input.backgroundColor,
62+
},
63+
valueContainerFocused: {
64+
// All ViewStyle properties are allowed
65+
...TextBox.inputFocused
5666
},
5767
valueContainerDisabled: {
5868
// All ViewStyle properties are allowed
@@ -74,6 +84,10 @@ export const DropDown = {
7484
backgroundColor: input.backgroundColor,
7585
underlayColor: input.inputContainerUnderlayColor,
7686
},
87+
iconStyle: {
88+
// All TextStyle properties are allowed
89+
color: input.color
90+
},
7791
item: {
7892
// All TextStlye properties are allowed
7993
color: input.color,
@@ -110,12 +124,15 @@ export const DropDownVertical = {
110124
label: TextBoxVertical.label,
111125
labelDisabled: TextBoxVertical.labelDisabled,
112126
value: DropDown.value,
127+
valueFocused: DropDown.valueFocused,
128+
validationMessage: TextBoxVertical.validationMessage,
113129
valueContainer: DropDown.valueContainer,
130+
valueContainerFocused: DropDown.valueContainerFocused,
114131
valueContainerDisabled: DropDown.valueContainerDisabled,
115-
validationMessage: TextBoxVertical.validationMessage,
116132
menuWrapper: DropDown.menuWrapper,
117133
itemContainer: DropDown.itemContainer,
118134
item: DropDown.item,
135+
iconStyle: DropDown.iconStyle,
119136
useUniformDesign: DropDown.useUniformDesign,
120137
pickerIOS: DropDown.pickerIOS,
121138
pickerItemIOS: DropDown.pickerItemIOS,

styles/native/js/core/widgets/floatingactionbutton.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ export const com_mendix_widget_native_floatingactionbutton_FloatingActionButton
6060
// All TextStyle properties are allowed
6161
color: font.color,
6262
fontSize: font.size,
63+
lineHeight: font.size,
6364
fontFamily: font.family,
6465
},
6566
secondaryButtonCaptionContainer: {

styles/native/js/core/widgets/navigation.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ Customizing core files will make updating Atlas much more difficult in the futur
77
To customize any core styling, copy the part you want to customize to styles/native/app/ so the core styling is overwritten.
88
99
==========================================================================
10-
TopBar / BottomBar / ProgressOverlay
10+
BottomBar / ProgressOverlay
1111
12-
Default Class For Mendix TopBar, BottomBar and ProgressOverlay
12+
Default Class For Mendix BottomBar and ProgressOverlay
1313
========================================================================== */
1414
export const navigationStyle = {
1515
bottomBar: {

styles/native/js/core/widgets/referenceselector.js

Lines changed: 41 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { border, contrast, font, input } from "../variables";
2-
import { DropDown } from "./dropdown";
2+
import { DropDownVertical } from "./dropdown";
33
import { TextBox, TextBoxVertical } from "./textbox";
44
/*
55
@@ -33,28 +33,38 @@ export const ReferenceSelector = {
3333
value: {
3434
// All TextStyle properties & placeholderTextColor are allowed
3535
color: input.color,
36-
borderColor: input.borderColor,
37-
backgroundColor: input.backgroundColor,
3836
fontSize: input.fontSize,
3937
fontFamily: input.fontFamily,
40-
borderWidth: input.borderWidth,
41-
borderRadius: input.borderRadius,
4238
overflow: "hidden",
43-
paddingHorizontal: input.paddingHorizontal,
44-
paddingVertical: input.paddingVertical,
4539
placeholderTextColor: input.placeholderTextColor,
4640
},
47-
valueDisabled: {
48-
// All TextStyle properties are allowed
49-
...TextBox.inputDisabled
50-
},
5141
validationMessage: {
5242
// All TextStyle properties are allowed
5343
...TextBox.validationMessage,
5444
},
5545
/* New dropdown styles start */
46+
valueFocused: {
47+
// All TextStyle properties are allowed
48+
},
49+
valueDisabled: {
50+
// All TextStyle properties are allowed
51+
...TextBox.inputDisabled,
52+
},
5653
valueContainer: {
57-
// All ViewStyle properties & rippleColor & activeOpacity & underlayColor are allowed
54+
// All ViewStyle properties & rippleColor are allowed
55+
flexDirection: "row",
56+
justifyContent: "space-between",
57+
alignItems: "center",
58+
borderWidth: input.borderWidth,
59+
borderRadius: input.borderRadius,
60+
borderColor: input.borderColor,
61+
paddingHorizontal: input.paddingHorizontal,
62+
paddingVertical: input.paddingVertical,
63+
backgroundColor: input.backgroundColor,
64+
},
65+
valueContainerFocused: {
66+
// All ViewStyle properties are allowed
67+
...TextBox.inputFocused,
5868
},
5969
valueContainerDisabled: {
6070
// All ViewStyle properties are allowed
@@ -66,7 +76,7 @@ export const ReferenceSelector = {
6676
shadowOpacity: 0.2,
6777
shadowRadius: 10,
6878
elevation: 16,
69-
backgroundColor: input.backgroundColor
79+
backgroundColor: input.backgroundColor,
7080
},
7181
itemContainer: {
7282
// All ViewStyle properties & rippleColor & activeOpacity & underlayColor are allowed
@@ -76,6 +86,10 @@ export const ReferenceSelector = {
7686
backgroundColor: input.backgroundColor,
7787
underlayColor: input.inputContainerUnderlayColor,
7888
},
89+
iconStyle: {
90+
// All TextStyle properties are allowed
91+
color: input.color,
92+
},
7993
item: {
8094
// All TextStyle properties are allowed
8195
color: input.color,
@@ -111,16 +125,19 @@ export const ReferenceSelectorVertical = {
111125
containerDisabled: TextBoxVertical.containerDisabled,
112126
label: TextBoxVertical.label,
113127
labelDisabled: TextBoxVertical.labelDisabled,
114-
value: DropDown.value,
115-
valueContainer: DropDown.valueContainer,
116-
valueContainerDisabled: DropDown.valueContainerDisabled,
128+
value: DropDownVertical.value,
129+
valueFocused: DropDownVertical.valueFocused,
117130
validationMessage: TextBoxVertical.validationMessage,
118-
menuWrapper: DropDown.menuWrapper,
119-
itemContainer: DropDown.itemContainer,
120-
item: DropDown.item,
121-
useUniformDesign: DropDown.useUniformDesign,
122-
pickerIOS: DropDown.pickerIOS,
123-
pickerItemIOS: DropDown.pickerItemIOS,
124-
pickerBackdropIOS: DropDown.pickerBackdropIOS,
125-
pickerTopIOS: DropDown.pickerTopIOS,
131+
valueContainer: DropDownVertical.valueContainer,
132+
valueContainerFocused: DropDownVertical.valueContainerFocused,
133+
valueContainerDisabled: DropDownVertical.valueContainerDisabled,
134+
menuWrapper: DropDownVertical.menuWrapper,
135+
itemContainer: DropDownVertical.itemContainer,
136+
item: DropDownVertical.item,
137+
iconStyle: DropDownVertical.iconStyle,
138+
useUniformDesign: DropDownVertical.useUniformDesign,
139+
pickerIOS: DropDownVertical.pickerIOS,
140+
pickerItemIOS: DropDownVertical.pickerItemIOS,
141+
pickerBackdropIOS: DropDownVertical.pickerBackdropIOS,
142+
pickerTopIOS: DropDownVertical.pickerTopIOS,
126143
};

styles/native/js/core/widgets/textarea.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,10 @@ export const TextArea = {
4646
// autoCapitalize, placeholderTextColor, selectionColor, underlineColorAndroid and all TextStyle properties are allowed
4747
...TextBox.inputError,
4848
},
49+
inputFocused: {
50+
// autoCapitalize, placeholderTextColor, selectionColor, underlineColorAndroid and all TextStyle properties are allowed
51+
...TextBox.inputFocused,
52+
},
4953
validationMessage: {
5054
// All TextStyle properties are allowed
5155
...TextBox.validationMessage,
@@ -64,5 +68,6 @@ export const TextAreaVertical = {
6468
input: TextBoxVertical.input,
6569
inputDisabled: TextBoxVertical.inputDisabled,
6670
inputError: TextBoxVertical.inputError,
71+
inputFocused: TextBoxVertical.inputFocused,
6772
validationMessage: TextBoxVertical.validationMessage,
6873
};

styles/native/js/core/widgets/textbox.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,10 @@ export const TextBox = {
5757
placeholderTextColor: input.errorColor,
5858
underlineColorAndroid: input.underlineColorAndroid,
5959
},
60+
inputFocused: {
61+
// autoCapitalize, placeholderTextColor, selectionColor, underlineColorAndroid and all TextStyle properties are allowed
62+
borderColor: input.borderColorFocused
63+
},
6064
validationMessage: {
6165
// All TextStyle properties are allowed
6266
color: input.errorColor,
@@ -89,6 +93,7 @@ export const TextBoxVertical = {
8993
paddingHorizontal: input.paddingHorizontal,
9094
paddingVertical: input.paddingVertical,
9195
},
96+
inputFocused: TextBox.inputFocused,
9297
inputDisabled: TextBox.inputDisabled,
9398
inputError: TextBox.inputError,
9499
validationMessage: TextBox.validationMessage,

0 commit comments

Comments
 (0)