Skip to content

Commit 3d05e34

Browse files
authored
Merge pull request #119 from mendix/nc/fix/NC-312_drop-down-max-width
[NC-312] Dropdown width
2 parents da713dc + bf01d69 commit 3d05e34

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

styles/native/ts/core/widgets/dropdown.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,8 @@ export const DropDown: DropDownType = {
7979
},
8080
itemContainer: {
8181
// All ViewStyle properties & rippleColor & activeOpacity & underlayColor are allowed
82-
maxWidth: 500,
82+
width: "100%",
83+
maxWidth: undefined, // unset core widget's default maxWidth value (prior to 8.18.7)
8384
paddingVertical: 6,
8485
paddingHorizontal: 16,
8586
backgroundColor: input.backgroundColor,
@@ -99,6 +100,8 @@ export const DropDown: DropDownType = {
99100
},
100101
selectedItemContainer: {
101102
// All ViewStyle properties are allowed
103+
width: "100%",
104+
maxWidth: undefined, // unset core widget's default maxWidth value (prior to 8.18.7)
102105
backgroundColor: contrast.lowest,
103106
},
104107
/* New dropdown styles end */

styles/native/ts/core/widgets/referenceselector.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,8 @@ export const ReferenceSelector: DropDownType = {
8181
},
8282
itemContainer: {
8383
// All ViewStyle properties & rippleColor & activeOpacity & underlayColor are allowed
84-
maxWidth: 500,
84+
width: "100%",
85+
maxWidth: undefined, // unset core widget's default maxWidth value (prior to 8.18.7)
8586
paddingVertical: 6,
8687
paddingHorizontal: 16,
8788
backgroundColor: input.backgroundColor,
@@ -101,6 +102,8 @@ export const ReferenceSelector: DropDownType = {
101102
},
102103
selectedItemContainer: {
103104
// All ViewStyle properties are allowed
105+
width: "100%",
106+
maxWidth: undefined, // unset core widget's default maxWidth value (prior to 8.18.7)
104107
backgroundColor: contrast.lowest,
105108
},
106109
/* New dropdown styles end */

0 commit comments

Comments
 (0)