This is a migrated thread and some comments may be shown as answers.

KendoReact Editor ForeColor Swatch

2 Answers 119 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Dennis
Top achievements
Rank 2
Dennis asked on 20 Jul 2020, 12:53 PM

 The new ForeColor EditorTool is a great addition to the Editor. How can we set the swatch colors? I tried passing ForeColorProps {} to the component that contained colorPickerProps {}, but just couldn't figure out how to make it work.

Can you please provide an example? I am trying to get a red swatch cell into the swatch. Or, choose another swatch, maybe?

 

2 Answers, 1 is accepted

Sort by
0
Accepted
Nikolay
Telerik team
answered on 21 Jul 2020, 07:16 AM

Hi,

You need to wrap the ForeColor/BackColor tool into another component and pass the new props along with the default props.

Here is an example - https://stackblitz.com/edit/react-bqrpxv?file=app/main.jsx.

Regards,
Nikolay
Progress Telerik

0
Dennis
Top achievements
Rank 2
answered on 21 Jul 2020, 12:27 PM
Perfect, Nikolay! Your example makes so much sense! Thanks!!
Tags
General Discussions
Asked by
Dennis
Top achievements
Rank 2
Answers by
Nikolay
Telerik team
Dennis
Top achievements
Rank 2
Share this question
or