Closed vanderhoop closed 1 year ago
@vanderhoop Is onClick
the only event handler that you have a use case for in your client project? Or are there other dynamic handlers/attributes that the tr
requires?
hey @chawes13, thanks for taking a look at this. We no longer need this functionality, as we introduced actual button
elements into the cells that need them, which is better for accessibility than clickable trs
that lack keyboard event listeners. As such, I'm going to close this, lest it do harm!
At the moment, the
SortableTable
andTable
components allow the passage of a customrowComponent
. However, there's no ability to pass additional props to this component from parent/consuming components, as this is presumed to just need thedata
.In my current project, we're building a rather involved table, and it requires the passage of event handlers to a
rowComponent
from a parent. At the moment, our workaround is to either a) create the component in a closure that has access to the event handler, or b) force us to manage the state in a grander fashion with either contexts or redux. Neither option is ideal, as we're only passing the handler down through one component, and it occurred to us that this is something that thelp-components
package could introduce at a very low complexity cost.Release Notes
Semver minor bump (new behavior without breaking existing contracts), adding
rowComponentProps
, that get passed to the row component.Author Checklist