@colisweb/rescript-toolkit 5.49.1 → 5.49.2

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@colisweb/rescript-toolkit",
3
- "version": "5.49.1",
3
+ "version": "5.49.2",
4
4
  "type": "module",
5
5
  "scripts": {
6
6
  "clean": "rescript clean",
@@ -49,6 +49,7 @@ type contentParams = {index: int}
49
49
  type timelinePointExtras = {
50
50
  className?: string,
51
51
  content?: contentParams => React.element,
52
+ onClick?: unit => unit,
52
53
  popoverContent?: React.element,
53
54
  popoverContentOptions?: Radix.Popover.Content.options,
54
55
  }
@@ -301,6 +302,7 @@ module Timeline = {
301
302
  | None =>
302
303
  <div
303
304
  className={"w-full h-[--markerHeight] text-center font-semibold text-sm"}
305
+ onClick={_ => extras.onClick->Option.forEach(fn => fn())}
304
306
  style={{
305
307
  "--markerHeight": switch marker {
306
308
  | Cluster(_) => markerWidth +. 10.
@@ -313,6 +315,7 @@ module Timeline = {
313
315
  <Toolkit__Ui_Popover
314
316
  triggerAsChild={true}
315
317
  trigger={<div
318
+ onClick={_ => extras.onClick->Option.forEach(fn => fn())}
316
319
  className={"w-full h-[--markerHeight] cursor-pointer text-center font-semibold text-sm"}
317
320
  style={{
318
321
  "--markerHeight": switch marker {