@imfusion/web-ui 0.11.1-dev.64.gdd82b76a → 0.11.1-dev.66.g88142bbf
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/CHANGELOG.md +14 -0
- package/dist/components/table/table.d.ts +49 -2
- package/dist/index.js +252 -164
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/src/docgen/doc.gen.json +334 -1
- package/src/llms/llms.gen.txt +1 -1
- package/src/llms/skills/imf-web-ui-components/SKILL.md +3 -1
package/package.json
CHANGED
package/src/docgen/doc.gen.json
CHANGED
|
@@ -13320,6 +13320,26 @@
|
|
|
13320
13320
|
}
|
|
13321
13321
|
]
|
|
13322
13322
|
},
|
|
13323
|
+
{
|
|
13324
|
+
"name": "Table.EmptyRow",
|
|
13325
|
+
"description": "Table.EmptyRow — a body row with one muted cell across all columns. `children` holds the message and an optional action.",
|
|
13326
|
+
"props": [
|
|
13327
|
+
{
|
|
13328
|
+
"name": "colSpan",
|
|
13329
|
+
"required": true,
|
|
13330
|
+
"type": "number",
|
|
13331
|
+
"defaultValue": null,
|
|
13332
|
+
"description": "Number of columns the message spans."
|
|
13333
|
+
},
|
|
13334
|
+
{
|
|
13335
|
+
"name": "ref",
|
|
13336
|
+
"required": false,
|
|
13337
|
+
"type": "Ref<HTMLTableElement>",
|
|
13338
|
+
"defaultValue": null,
|
|
13339
|
+
"description": "Allows getting a ref to the component instance.\nOnce the component unmounts, React will set `ref.current` to `null`\n(or call the ref with `null` if you passed a callback ref).\n@see {@link https://react.dev/learn/referencing-values-with-refs#refs-and-the-dom React Docs}"
|
|
13340
|
+
}
|
|
13341
|
+
]
|
|
13342
|
+
},
|
|
13323
13343
|
{
|
|
13324
13344
|
"name": "Table.Header",
|
|
13325
13345
|
"description": "Table.Header — the `<thead>` section.",
|
|
@@ -13370,6 +13390,13 @@
|
|
|
13370
13390
|
"name": "Table.Row",
|
|
13371
13391
|
"description": "Table.Row — a `<tr>` in header or body.",
|
|
13372
13392
|
"props": [
|
|
13393
|
+
{
|
|
13394
|
+
"name": "disabled",
|
|
13395
|
+
"required": false,
|
|
13396
|
+
"type": "boolean",
|
|
13397
|
+
"defaultValue": "false",
|
|
13398
|
+
"description": "Dims the row and takes it out of use: its select checkbox, `RowLink` and `RowButton` stop responding."
|
|
13399
|
+
},
|
|
13373
13400
|
{
|
|
13374
13401
|
"name": "ref",
|
|
13375
13402
|
"required": false,
|
|
@@ -13381,7 +13408,7 @@
|
|
|
13381
13408
|
},
|
|
13382
13409
|
{
|
|
13383
13410
|
"name": "Table.RowButton",
|
|
13384
|
-
"description": "Table.RowButton — a `<button>` that stands for its whole row, such as one that opens a drawer. Use it when the row acts\ninstead of navigating; a link that goes to a page is a `Table.RowLink`.",
|
|
13411
|
+
"description": "Table.RowButton — a `<button>` that stands for its whole row, such as one that opens a drawer. Use it when the row acts\ninstead of navigating; a link that goes to a page is a `Table.RowLink`. In a disabled row it renders `disabled`, which\nonly takes effect when it renders a button.",
|
|
13385
13412
|
"props": [
|
|
13386
13413
|
{
|
|
13387
13414
|
"name": "ref",
|
|
@@ -13419,6 +13446,312 @@
|
|
|
13419
13446
|
}
|
|
13420
13447
|
]
|
|
13421
13448
|
},
|
|
13449
|
+
{
|
|
13450
|
+
"name": "Table.SelectAllCell",
|
|
13451
|
+
"description": "Table.SelectAllCell — a `<th>` action cell with the select-all checkbox. The checkbox is named by `label` plus the\ncounter. `disabled` follows the row's `disabled` unless set.",
|
|
13452
|
+
"props": [
|
|
13453
|
+
{
|
|
13454
|
+
"name": "checked",
|
|
13455
|
+
"required": false,
|
|
13456
|
+
"type": "boolean",
|
|
13457
|
+
"defaultValue": "undefined",
|
|
13458
|
+
"description": "Whether the checkbox is currently ticked.\n\nTo render an uncontrolled checkbox, use the `defaultChecked` prop instead."
|
|
13459
|
+
},
|
|
13460
|
+
{
|
|
13461
|
+
"name": "children",
|
|
13462
|
+
"required": false,
|
|
13463
|
+
"type": "ReactNode",
|
|
13464
|
+
"defaultValue": null,
|
|
13465
|
+
"description": "The counter beside the checkbox, such as `2/4`. The app computes it."
|
|
13466
|
+
},
|
|
13467
|
+
{
|
|
13468
|
+
"name": "className",
|
|
13469
|
+
"required": false,
|
|
13470
|
+
"type": "string",
|
|
13471
|
+
"defaultValue": null,
|
|
13472
|
+
"description": "Reaches the `<th>`, not the checkbox."
|
|
13473
|
+
},
|
|
13474
|
+
{
|
|
13475
|
+
"name": "colSpan",
|
|
13476
|
+
"required": false,
|
|
13477
|
+
"type": "number",
|
|
13478
|
+
"defaultValue": null,
|
|
13479
|
+
"description": "Number of columns the cell spans, such as the select and thumbnail columns."
|
|
13480
|
+
},
|
|
13481
|
+
{
|
|
13482
|
+
"name": "defaultChecked",
|
|
13483
|
+
"required": false,
|
|
13484
|
+
"type": "boolean",
|
|
13485
|
+
"defaultValue": "false",
|
|
13486
|
+
"description": "Whether the checkbox is initially ticked.\n\nTo render a controlled checkbox, use the `checked` prop instead."
|
|
13487
|
+
},
|
|
13488
|
+
{
|
|
13489
|
+
"name": "disabled",
|
|
13490
|
+
"required": false,
|
|
13491
|
+
"type": "boolean",
|
|
13492
|
+
"defaultValue": "false",
|
|
13493
|
+
"description": "Whether the component should ignore user interaction."
|
|
13494
|
+
},
|
|
13495
|
+
{
|
|
13496
|
+
"name": "form",
|
|
13497
|
+
"required": false,
|
|
13498
|
+
"type": "string",
|
|
13499
|
+
"defaultValue": null,
|
|
13500
|
+
"description": "Identifies the form that owns the hidden input.\nUseful when the checkbox is rendered outside the form."
|
|
13501
|
+
},
|
|
13502
|
+
{
|
|
13503
|
+
"name": "id",
|
|
13504
|
+
"required": false,
|
|
13505
|
+
"type": "string",
|
|
13506
|
+
"defaultValue": null,
|
|
13507
|
+
"description": "The id of the input element."
|
|
13508
|
+
},
|
|
13509
|
+
{
|
|
13510
|
+
"name": "indeterminate",
|
|
13511
|
+
"required": false,
|
|
13512
|
+
"type": "boolean",
|
|
13513
|
+
"defaultValue": "false",
|
|
13514
|
+
"description": "Whether the checkbox is in a mixed state: neither ticked, nor unticked."
|
|
13515
|
+
},
|
|
13516
|
+
{
|
|
13517
|
+
"name": "inputRef",
|
|
13518
|
+
"required": false,
|
|
13519
|
+
"type": "Ref<HTMLInputElement>",
|
|
13520
|
+
"defaultValue": null,
|
|
13521
|
+
"description": "A ref to access the hidden `<input>` element."
|
|
13522
|
+
},
|
|
13523
|
+
{
|
|
13524
|
+
"name": "label",
|
|
13525
|
+
"required": false,
|
|
13526
|
+
"type": "string",
|
|
13527
|
+
"defaultValue": "Select all",
|
|
13528
|
+
"description": "Names the checkbox for assistive tech; the counter follows it."
|
|
13529
|
+
},
|
|
13530
|
+
{
|
|
13531
|
+
"name": "name",
|
|
13532
|
+
"required": false,
|
|
13533
|
+
"type": "string",
|
|
13534
|
+
"defaultValue": "undefined",
|
|
13535
|
+
"description": "Identifies the field when a form is submitted."
|
|
13536
|
+
},
|
|
13537
|
+
{
|
|
13538
|
+
"name": "nativeButton",
|
|
13539
|
+
"required": false,
|
|
13540
|
+
"type": "boolean",
|
|
13541
|
+
"defaultValue": "false",
|
|
13542
|
+
"description": "Whether the component renders a native `<button>` element when replacing it\nvia the `render` prop.\nSet to `true` if the rendered element is a native button."
|
|
13543
|
+
},
|
|
13544
|
+
{
|
|
13545
|
+
"name": "onCheckedChange",
|
|
13546
|
+
"required": false,
|
|
13547
|
+
"type": "(\n checked: boolean,\n eventDetails: {\n reason: \"none\";\n event: Event;\n cancel: () => void;\n allowPropagation: () => void;\n isCanceled: boolean;\n isPropagationAllowed: boolean;\n trigger: Element;\n }\n) => void",
|
|
13548
|
+
"defaultValue": null,
|
|
13549
|
+
"description": "Event handler called when the checkbox is ticked or unticked."
|
|
13550
|
+
},
|
|
13551
|
+
{
|
|
13552
|
+
"name": "parent",
|
|
13553
|
+
"required": false,
|
|
13554
|
+
"type": "boolean",
|
|
13555
|
+
"defaultValue": "false",
|
|
13556
|
+
"description": "Whether the checkbox controls a group of child checkboxes.\n\nMust be used in a [Checkbox Group](https://base-ui.com/react/components/checkbox-group)."
|
|
13557
|
+
},
|
|
13558
|
+
{
|
|
13559
|
+
"name": "readOnly",
|
|
13560
|
+
"required": false,
|
|
13561
|
+
"type": "boolean",
|
|
13562
|
+
"defaultValue": "false",
|
|
13563
|
+
"description": "Whether the user should be unable to tick or untick the checkbox."
|
|
13564
|
+
},
|
|
13565
|
+
{
|
|
13566
|
+
"name": "ref",
|
|
13567
|
+
"required": false,
|
|
13568
|
+
"type": "Ref<HTMLTableElement>",
|
|
13569
|
+
"defaultValue": null,
|
|
13570
|
+
"description": "Allows getting a ref to the component instance.\nOnce the component unmounts, React will set `ref.current` to `null`\n(or call the ref with `null` if you passed a callback ref).\n@see {@link https://react.dev/learn/referencing-values-with-refs#refs-and-the-dom React Docs}"
|
|
13571
|
+
},
|
|
13572
|
+
{
|
|
13573
|
+
"name": "render",
|
|
13574
|
+
"required": false,
|
|
13575
|
+
"type": "| ReactElement<\n unknown,\n string | JSXElementConstructor<any>\n >\n| ComponentRenderFn<HTMLProps, CheckboxRootState>",
|
|
13576
|
+
"defaultValue": null,
|
|
13577
|
+
"description": "Allows you to replace the component's HTML element\nwith a different tag, or compose it with another component.\n\nAccepts a `ReactElement` or a function that returns the element to render."
|
|
13578
|
+
},
|
|
13579
|
+
{
|
|
13580
|
+
"name": "required",
|
|
13581
|
+
"required": false,
|
|
13582
|
+
"type": "boolean",
|
|
13583
|
+
"defaultValue": "false",
|
|
13584
|
+
"description": "Whether the user must tick the checkbox before submitting a form."
|
|
13585
|
+
},
|
|
13586
|
+
{
|
|
13587
|
+
"name": "style",
|
|
13588
|
+
"required": false,
|
|
13589
|
+
"type": "| CSSProperties\n| ((state: CheckboxRootState) => CSSProperties)",
|
|
13590
|
+
"defaultValue": null,
|
|
13591
|
+
"description": "Style applied to the element, or a function that\nreturns a style object based on the component's state."
|
|
13592
|
+
},
|
|
13593
|
+
{
|
|
13594
|
+
"name": "uncheckedValue",
|
|
13595
|
+
"required": false,
|
|
13596
|
+
"type": "string",
|
|
13597
|
+
"defaultValue": null,
|
|
13598
|
+
"description": "The value submitted with the form when the checkbox is unchecked.\nBy default, unchecked checkboxes do not submit any value, matching native checkbox behavior."
|
|
13599
|
+
},
|
|
13600
|
+
{
|
|
13601
|
+
"name": "value",
|
|
13602
|
+
"required": false,
|
|
13603
|
+
"type": "string",
|
|
13604
|
+
"defaultValue": null,
|
|
13605
|
+
"description": "The value of the selected checkbox."
|
|
13606
|
+
}
|
|
13607
|
+
]
|
|
13608
|
+
},
|
|
13609
|
+
{
|
|
13610
|
+
"name": "Table.SelectCell",
|
|
13611
|
+
"description": "Table.SelectCell — a `<td>` action cell holding the row's checkbox. `checked` and `onCheckedChange` belong to the app.\n`disabled` follows the row's `disabled` unless set.",
|
|
13612
|
+
"props": [
|
|
13613
|
+
{
|
|
13614
|
+
"name": "aria-label",
|
|
13615
|
+
"required": true,
|
|
13616
|
+
"type": "string",
|
|
13617
|
+
"defaultValue": null,
|
|
13618
|
+
"description": "Names the checkbox, such as `Select brain_mr_t1_0142`."
|
|
13619
|
+
},
|
|
13620
|
+
{
|
|
13621
|
+
"name": "checked",
|
|
13622
|
+
"required": false,
|
|
13623
|
+
"type": "boolean",
|
|
13624
|
+
"defaultValue": "undefined",
|
|
13625
|
+
"description": "Whether the checkbox is currently ticked.\n\nTo render an uncontrolled checkbox, use the `defaultChecked` prop instead."
|
|
13626
|
+
},
|
|
13627
|
+
{
|
|
13628
|
+
"name": "className",
|
|
13629
|
+
"required": false,
|
|
13630
|
+
"type": "string",
|
|
13631
|
+
"defaultValue": null,
|
|
13632
|
+
"description": "Reaches the `<td>`, not the checkbox."
|
|
13633
|
+
},
|
|
13634
|
+
{
|
|
13635
|
+
"name": "defaultChecked",
|
|
13636
|
+
"required": false,
|
|
13637
|
+
"type": "boolean",
|
|
13638
|
+
"defaultValue": "false",
|
|
13639
|
+
"description": "Whether the checkbox is initially ticked.\n\nTo render a controlled checkbox, use the `checked` prop instead."
|
|
13640
|
+
},
|
|
13641
|
+
{
|
|
13642
|
+
"name": "disabled",
|
|
13643
|
+
"required": false,
|
|
13644
|
+
"type": "boolean",
|
|
13645
|
+
"defaultValue": "false",
|
|
13646
|
+
"description": "Whether the component should ignore user interaction."
|
|
13647
|
+
},
|
|
13648
|
+
{
|
|
13649
|
+
"name": "form",
|
|
13650
|
+
"required": false,
|
|
13651
|
+
"type": "string",
|
|
13652
|
+
"defaultValue": null,
|
|
13653
|
+
"description": "Identifies the form that owns the hidden input.\nUseful when the checkbox is rendered outside the form."
|
|
13654
|
+
},
|
|
13655
|
+
{
|
|
13656
|
+
"name": "id",
|
|
13657
|
+
"required": false,
|
|
13658
|
+
"type": "string",
|
|
13659
|
+
"defaultValue": null,
|
|
13660
|
+
"description": "The id of the input element."
|
|
13661
|
+
},
|
|
13662
|
+
{
|
|
13663
|
+
"name": "indeterminate",
|
|
13664
|
+
"required": false,
|
|
13665
|
+
"type": "boolean",
|
|
13666
|
+
"defaultValue": "false",
|
|
13667
|
+
"description": "Whether the checkbox is in a mixed state: neither ticked, nor unticked."
|
|
13668
|
+
},
|
|
13669
|
+
{
|
|
13670
|
+
"name": "inputRef",
|
|
13671
|
+
"required": false,
|
|
13672
|
+
"type": "Ref<HTMLInputElement>",
|
|
13673
|
+
"defaultValue": null,
|
|
13674
|
+
"description": "A ref to access the hidden `<input>` element."
|
|
13675
|
+
},
|
|
13676
|
+
{
|
|
13677
|
+
"name": "name",
|
|
13678
|
+
"required": false,
|
|
13679
|
+
"type": "string",
|
|
13680
|
+
"defaultValue": "undefined",
|
|
13681
|
+
"description": "Identifies the field when a form is submitted."
|
|
13682
|
+
},
|
|
13683
|
+
{
|
|
13684
|
+
"name": "nativeButton",
|
|
13685
|
+
"required": false,
|
|
13686
|
+
"type": "boolean",
|
|
13687
|
+
"defaultValue": "false",
|
|
13688
|
+
"description": "Whether the component renders a native `<button>` element when replacing it\nvia the `render` prop.\nSet to `true` if the rendered element is a native button."
|
|
13689
|
+
},
|
|
13690
|
+
{
|
|
13691
|
+
"name": "onCheckedChange",
|
|
13692
|
+
"required": false,
|
|
13693
|
+
"type": "(\n checked: boolean,\n eventDetails: {\n reason: \"none\";\n event: Event;\n cancel: () => void;\n allowPropagation: () => void;\n isCanceled: boolean;\n isPropagationAllowed: boolean;\n trigger: Element;\n }\n) => void",
|
|
13694
|
+
"defaultValue": null,
|
|
13695
|
+
"description": "Event handler called when the checkbox is ticked or unticked."
|
|
13696
|
+
},
|
|
13697
|
+
{
|
|
13698
|
+
"name": "parent",
|
|
13699
|
+
"required": false,
|
|
13700
|
+
"type": "boolean",
|
|
13701
|
+
"defaultValue": "false",
|
|
13702
|
+
"description": "Whether the checkbox controls a group of child checkboxes.\n\nMust be used in a [Checkbox Group](https://base-ui.com/react/components/checkbox-group)."
|
|
13703
|
+
},
|
|
13704
|
+
{
|
|
13705
|
+
"name": "readOnly",
|
|
13706
|
+
"required": false,
|
|
13707
|
+
"type": "boolean",
|
|
13708
|
+
"defaultValue": "false",
|
|
13709
|
+
"description": "Whether the user should be unable to tick or untick the checkbox."
|
|
13710
|
+
},
|
|
13711
|
+
{
|
|
13712
|
+
"name": "ref",
|
|
13713
|
+
"required": false,
|
|
13714
|
+
"type": "Ref<HTMLTableElement>",
|
|
13715
|
+
"defaultValue": null,
|
|
13716
|
+
"description": "Allows getting a ref to the component instance.\nOnce the component unmounts, React will set `ref.current` to `null`\n(or call the ref with `null` if you passed a callback ref).\n@see {@link https://react.dev/learn/referencing-values-with-refs#refs-and-the-dom React Docs}"
|
|
13717
|
+
},
|
|
13718
|
+
{
|
|
13719
|
+
"name": "render",
|
|
13720
|
+
"required": false,
|
|
13721
|
+
"type": "| ReactElement<\n unknown,\n string | JSXElementConstructor<any>\n >\n| ComponentRenderFn<HTMLProps, CheckboxRootState>",
|
|
13722
|
+
"defaultValue": null,
|
|
13723
|
+
"description": "Allows you to replace the component's HTML element\nwith a different tag, or compose it with another component.\n\nAccepts a `ReactElement` or a function that returns the element to render."
|
|
13724
|
+
},
|
|
13725
|
+
{
|
|
13726
|
+
"name": "required",
|
|
13727
|
+
"required": false,
|
|
13728
|
+
"type": "boolean",
|
|
13729
|
+
"defaultValue": "false",
|
|
13730
|
+
"description": "Whether the user must tick the checkbox before submitting a form."
|
|
13731
|
+
},
|
|
13732
|
+
{
|
|
13733
|
+
"name": "style",
|
|
13734
|
+
"required": false,
|
|
13735
|
+
"type": "| CSSProperties\n| ((state: CheckboxRootState) => CSSProperties)",
|
|
13736
|
+
"defaultValue": null,
|
|
13737
|
+
"description": "Style applied to the element, or a function that\nreturns a style object based on the component's state."
|
|
13738
|
+
},
|
|
13739
|
+
{
|
|
13740
|
+
"name": "uncheckedValue",
|
|
13741
|
+
"required": false,
|
|
13742
|
+
"type": "string",
|
|
13743
|
+
"defaultValue": null,
|
|
13744
|
+
"description": "The value submitted with the form when the checkbox is unchecked.\nBy default, unchecked checkboxes do not submit any value, matching native checkbox behavior."
|
|
13745
|
+
},
|
|
13746
|
+
{
|
|
13747
|
+
"name": "value",
|
|
13748
|
+
"required": false,
|
|
13749
|
+
"type": "string",
|
|
13750
|
+
"defaultValue": null,
|
|
13751
|
+
"description": "The value of the selected checkbox."
|
|
13752
|
+
}
|
|
13753
|
+
]
|
|
13754
|
+
},
|
|
13422
13755
|
{
|
|
13423
13756
|
"name": "Table.SortableHeaderCell",
|
|
13424
13757
|
"description": "Table.SortableHeaderCell — a header cell whose label is a sort toggle,\npre-composing HeaderCell + HeaderButton so `aria-sort` and the direction\nindicator aren't re-derived per consumer. Omit `onToggle` for a plain cell.",
|
package/src/llms/llms.gen.txt
CHANGED
|
@@ -276,7 +276,7 @@ Row of links to routes with a bar under the current one, such as the sections of
|
|
|
276
276
|
|
|
277
277
|
## Table
|
|
278
278
|
- category: Display, status: stable
|
|
279
|
-
Presentational table parts for static tabular data. Pair them with a headless table library for sorting
|
|
279
|
+
Presentational table parts for static tabular data. Pair them with a headless table library for sorting or pagination.
|
|
280
280
|
- props: node_modules/@imfusion/web-ui/src/docgen/doc.gen.json -> .table (jq: jq '.table' node_modules/@imfusion/web-ui/src/docgen/doc.gen.json)
|
|
281
281
|
|
|
282
282
|
## Tabs
|
|
@@ -99,4 +99,6 @@ import { ImageDisplayOptions } from "@imfusion/web-ui/integrations/image-display
|
|
|
99
99
|
## Data grids
|
|
100
100
|
|
|
101
101
|
`Table` supplies styled table parts, not sorting or pagination. Pair them with a headless table library installed by the
|
|
102
|
-
consumer. TanStack Table is the recommended choice. Use `Table.SortableHeaderCell` for sortable columns.
|
|
102
|
+
consumer. TanStack Table is the recommended choice. Use `Table.SortableHeaderCell` for sortable columns. For selection, put
|
|
103
|
+
`Table.SelectCell` in each row and `Table.SelectAllCell` in the header; the app owns the selected state and the counter.
|
|
104
|
+
`Table.Row` takes `disabled` to lock a row, and `Table.EmptyRow` fills an empty body.
|