@crispy-seed/data-table 0.1.2 → 0.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -4312,6 +4312,13 @@ function DataTableInner(props, ref) {
4312
4312
  onClick: onRowClick ? ()=>onRowClick(row) : undefined,
4313
4313
  children: [
4314
4314
  selectable && /*#__PURE__*/ jsxRuntime.jsx(DataTableSelectionCell, {
4315
+ // The row itself carries `onClick={onRowClick}` above, and a
4316
+ // native click on this cell's checkbox bubbles up through it
4317
+ // (React attaches DataTableRow's handler on the <tr>, which
4318
+ // sits between the checkbox and anything a consumer could stop
4319
+ // it from at -- so this has to live here, not in the consumer).
4320
+ // Without this, checking a row's box also fires `onRowClick`.
4321
+ onClick: (event)=>event.stopPropagation(),
4315
4322
  ...stickyProps({
4316
4323
  selectable,
4317
4324
  stickyFirst,
package/dist/index.js CHANGED
@@ -4293,6 +4293,13 @@ function DataTableInner(props, ref) {
4293
4293
  onClick: onRowClick ? ()=>onRowClick(row) : undefined,
4294
4294
  children: [
4295
4295
  selectable && /*#__PURE__*/ jsx(DataTableSelectionCell, {
4296
+ // The row itself carries `onClick={onRowClick}` above, and a
4297
+ // native click on this cell's checkbox bubbles up through it
4298
+ // (React attaches DataTableRow's handler on the <tr>, which
4299
+ // sits between the checkbox and anything a consumer could stop
4300
+ // it from at -- so this has to live here, not in the consumer).
4301
+ // Without this, checking a row's box also fires `onRowClick`.
4302
+ onClick: (event)=>event.stopPropagation(),
4296
4303
  ...stickyProps({
4297
4304
  selectable,
4298
4305
  stickyFirst,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@crispy-seed/data-table",
3
- "version": "0.1.2",
3
+ "version": "0.1.3",
4
4
  "description": "Self-contained, publishable build of seed-design's Attio-measured DataTable — one install, one CSS import.",
5
5
  "repository": {
6
6
  "type": "git",