Grid: Cell with drag selection and custom cell rendering

3 Answers 414 Views
Grid
Carlos
Top achievements
Rank 2
Iron
Iron
Iron
Carlos asked on 24 May 2021, 09:16 AM | edited on 27 May 2021, 01:00 PM

Hello,

Im trying to create a custom cell with drag and cell selection and its look it is not possible because I dont have the original `<td/>` in the `GridCellProps`.

Here you have an example:

https://stackblitz.com/edit/react-xwdgxd?file=app/main.jsx

I found a "workaround" but I dont know if this is the correct way to do that:

https://stackblitz.com/edit/react-xwdgxd-tfwi7j?file=app/main.jsx

In Grid the prop cellRender do you have the original td allowing to override some props but without the need to know all internal props. Would be great if you can do that in the `GridColumn`.

I dont want to override the cellRender in the Grid and i dont want to know about data-grid-col-index.

Any suggestions?

Thanks!

3 Answers, 1 is accepted

Sort by
0
Accepted
Krissy
Telerik team
answered on 26 May 2021, 06:21 AM

Hi Carlos,

I spoke with the lead developer and we will implement the feature of the grid column index attribute to get exported by default in the upcoming weeks. In the meantime, you can use the following approach as a workaround: 
https://stackblitz.com/edit/react-xwdgxd-uc2cup?file=app/main.jsx  

The example above is based on the one you sent in your previous ticket, the only thing I've changed is the usage of props.columnIndex instead of props.ariaColumnIndex.

Hope this is helpful.

Regards,
Krissy
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

0
Stefan
Telerik team
answered on 24 May 2021, 11:14 AM

Hello, Carlos,

Thank you for reporting this case.

By design, we have to pass all needed attributes to the custom cell in order for the developer to achieve all built-in cases. I see that there is a prop missing and I will check with the lead developer of this feature and follow up by the end of the week.

We will update the example or log a task to fix this case and extend the provided props.

Apologies for the inconvenience this may have caused you.

Regards,
Stefan
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Carlos
Top achievements
Rank 2
Iron
Iron
Iron
commented on 25 May 2021, 08:01 AM

ok!, Thanks for the quick reply
0
Carlos
Top achievements
Rank 2
Iron
Iron
Iron
answered on 27 May 2021, 12:59 PM

Hi Krissy & Stefan,

Thanks for the support, I will use your approach and wait for the next version!

Tags
Grid
Asked by
Carlos
Top achievements
Rank 2
Iron
Iron
Iron
Answers by
Krissy
Telerik team
Stefan
Telerik team
Carlos
Top achievements
Rank 2
Iron
Iron
Iron
Share this question
or