Replace styleFunction option by style