Custom component handlers #85
-
Hi 👋 I'm trying to implement a custom component to render inside the cells. basically, it's to render an array of images. That's working and everything works as expected, copy-past, drag to copy, all of that. But I would like to override a couple of commands. e.g.: be able to select some images (I'm doing that with a local state) and then do Of course, this doesn't work because we have the default cell behavior, of clearing the cell or copying the entire cell. Is there a way that I can achieve this? Already tried with a couple of solutions, passing a custom component to the column and passing a custom function to the |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
Hi @danisal ,
When a cell is not focused, doing a When a cell is focused, it is up to the component to control what happens when you copy or delete something. For instance, in a text input cell, you can select and copy just part of the text. |
Beta Was this translation helpful? Give feedback.
Hi @danisal ,
Note that there are two different states for a cell:
When a cell is not focused, doing a
CMD+C
will copy the cell's content, you can control what is copied exactly. You can also control what is deleted exactly when you cut or clear a cell.When a cell is focused, it is up to the component to control what happens when you copy or delete something. For instance, in a text input cell, you can select and copy just part of the text.