Fable bindings for react-colorful (NPM package) version 5.6.0+.
Installation with Femto
femto install Fable.ReactColorful
Nuget package
paket add Fable.ReactColorful -p YourProject.fsproj
NPM package
npm install react-colorful@5.6.1
Decide which of the 14 pickers/color models you want to use and simply pass in the initial value and change callback. Helpers for constructing RGB(A), HSV(A) and HSL(A) values are included.
open Fable.React
open Fable.ReactColorful
let viewPickers () = div [] [
hsvaStringPicker "hsva(295, 86%, 77%, 0.83)" (fun x -> Browser.Dom.console.log x)
hslaPicker (hsla 20 20 20 0.5) (fun x -> Browser.Dom.console.log x)
hexPicker "#ffa" (fun x -> Browser.Dom.console.log x)
]