From 3840256d9d87e60b3a92a4ff1cdc3fcd4f0db608 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Osadnik?= Date: Mon, 4 Mar 2019 10:48:19 +0100 Subject: [PATCH] Clarify that color node accepts only integer values (#190) I see it was written here before but it calls for clarifying a bit --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 4a8bb0f..bf22243 100644 --- a/README.md +++ b/README.md @@ -559,7 +559,7 @@ Maps an input value within a range to an output value within a range. Also suppo color(red, green, blue, alpha) ``` -Creates a color node in RGBA format, where the first three input nodes should have integer values in the range 0-255 and correspond to color components Red, Green and Blue respectively. Last input node should have a value between 0 and 1 and represents alpha channel (value `1` means fully opaque and `0` completely transparent). Alpha parameter can be ommited, then `1` (fully opaque) is used as a default. +Creates a color node in RGBA format, where the first three input nodes should have *integer* values in the range 0-255 (consider using `round` node if needed) and correspond to color components Red, Green and Blue respectively. Last input node should have a value between 0 and 1 and represents alpha channel (value `1` means fully opaque and `0` completely transparent). Alpha parameter can be ommited, then `1` (fully opaque) is used as a default. The returned node can be mapped to view properties that represents color (e.g. [`backgroundColor`](https://facebook.github.io/react-native/docs/view-style-props.html#backgroundcolor)).