mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
Fixed(IOS): Setting placeholder color on text filed crashes if no hint is set
This commit is contained in:
@@ -575,4 +575,14 @@ export function test_set_placeholder_color() {
|
||||
let actualColorHex = textFieldTestsNative.getNativePlaceholderColor(view).hex;
|
||||
TKUnit.assertEqual(actualColorHex, expectedColorHex);
|
||||
});
|
||||
}
|
||||
|
||||
export function test_set_placeholder_color_when_hint_is_not_set() {
|
||||
let view = new textFieldModule.TextField();
|
||||
let expectedColorHex = "#ffff0000";
|
||||
helper.buildUIAndRunTest(view, function (views: Array<viewModule.View>) {
|
||||
view.setInlineStyle("placeholder-color: " + expectedColorHex + ";");
|
||||
let actualColorHex = textFieldTestsNative.getNativePlaceholderColor(view).hex;
|
||||
TKUnit.assertEqual(actualColorHex, expectedColorHex);
|
||||
});
|
||||
}
|
||||
Reference in New Issue
Block a user