@imfusion/web-ui 0.8.1-dev.48.g0dad5878 → 0.8.1-dev.50.g91c115bb

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": "@imfusion/web-ui",
3
- "version": "0.8.1-dev.48.g0dad5878",
3
+ "version": "0.8.1-dev.50.g91c115bb",
4
4
  "description": "The official Web UI component library for ImFusion web apps",
5
5
  "author": "ImFusion GmbH",
6
6
  "homepage": "https://imfusion.com",
@@ -460,7 +460,7 @@
460
460
  "required": false,
461
461
  "type": "ReactNode",
462
462
  "defaultValue": null,
463
- "description": "Trailing slot — typically an icon. When present, the label aligns left and the icon pins right."
463
+ "description": "Trailing slot, typically an icon."
464
464
  },
465
465
  {
466
466
  "name": "focusableWhenDisabled",
@@ -469,6 +469,13 @@
469
469
  "defaultValue": "false",
470
470
  "description": "Whether the button should be focusable when disabled."
471
471
  },
472
+ {
473
+ "name": "justify",
474
+ "required": false,
475
+ "type": "\"center\" | \"spread\" | null",
476
+ "defaultValue": "center",
477
+ "description": ""
478
+ },
472
479
  {
473
480
  "name": "nativeButton",
474
481
  "required": false,
@@ -509,7 +516,7 @@
509
516
  "required": false,
510
517
  "type": "ReactNode",
511
518
  "defaultValue": null,
512
- "description": "Leading slot — typically a label. When present, the label aligns right and the icon pins left."
519
+ "description": "Leading slot, typically an icon."
513
520
  },
514
521
  {
515
522
  "name": "style",
@@ -1209,7 +1216,7 @@
1209
1216
  "required": false,
1210
1217
  "type": "ReactNode",
1211
1218
  "defaultValue": null,
1212
- "description": "Trailing slot — typically an icon. When present, the label aligns left and the icon pins right."
1219
+ "description": "Trailing slot, typically an icon."
1213
1220
  },
1214
1221
  {
1215
1222
  "name": "focusableWhenDisabled",
@@ -1218,6 +1225,13 @@
1218
1225
  "defaultValue": "false",
1219
1226
  "description": "Whether the button should be focusable when disabled."
1220
1227
  },
1228
+ {
1229
+ "name": "justify",
1230
+ "required": false,
1231
+ "type": "\"center\" | \"spread\" | null",
1232
+ "defaultValue": null,
1233
+ "description": ""
1234
+ },
1221
1235
  {
1222
1236
  "name": "label",
1223
1237
  "required": false,
@@ -1265,7 +1279,7 @@
1265
1279
  "required": false,
1266
1280
  "type": "ReactNode",
1267
1281
  "defaultValue": null,
1268
- "description": "Leading slot — typically a label. When present, the label aligns right and the icon pins left."
1282
+ "description": "Leading slot, typically an icon."
1269
1283
  },
1270
1284
  {
1271
1285
  "name": "style",
@@ -2597,6 +2611,229 @@
2597
2611
  },
2598
2612
  "subComponents": []
2599
2613
  },
2614
+ "meter": {
2615
+ "root": {
2616
+ "name": "Meter.Root",
2617
+ "description": "Meter.Root — read-only measurement of a value within a known range.\n\nWithout a visible `Meter.Label`, name the meter with `aria-label`.",
2618
+ "props": [
2619
+ {
2620
+ "name": "aria-valuetext",
2621
+ "required": false,
2622
+ "type": "string",
2623
+ "defaultValue": null,
2624
+ "description": "A string value that provides a user-friendly name for `aria-valuenow`, the current value of the meter."
2625
+ },
2626
+ {
2627
+ "name": "className",
2628
+ "required": false,
2629
+ "type": "string | ((state: MeterRootState) => string)",
2630
+ "defaultValue": null,
2631
+ "description": "CSS class applied to the element, or a function that\nreturns a class based on the component's state."
2632
+ },
2633
+ {
2634
+ "name": "format",
2635
+ "required": false,
2636
+ "type": "NumberFormatOptions",
2637
+ "defaultValue": null,
2638
+ "description": "Options to format the value."
2639
+ },
2640
+ {
2641
+ "name": "getAriaValueText",
2642
+ "required": false,
2643
+ "type": "(formattedValue: string, value: number) => string",
2644
+ "defaultValue": null,
2645
+ "description": "A function that returns a string value that provides a human-readable text alternative for `aria-valuenow`, the current value of the meter."
2646
+ },
2647
+ {
2648
+ "name": "locale",
2649
+ "required": false,
2650
+ "type": "LocalesArgument",
2651
+ "defaultValue": null,
2652
+ "description": "The locale used by `Intl.NumberFormat` when formatting the value.\nDefaults to the user's runtime locale."
2653
+ },
2654
+ {
2655
+ "name": "max",
2656
+ "required": false,
2657
+ "type": "number",
2658
+ "defaultValue": "100",
2659
+ "description": "The maximum value"
2660
+ },
2661
+ {
2662
+ "name": "min",
2663
+ "required": false,
2664
+ "type": "number",
2665
+ "defaultValue": "0",
2666
+ "description": "The minimum value"
2667
+ },
2668
+ {
2669
+ "name": "ref",
2670
+ "required": false,
2671
+ "type": "Ref<HTMLDivElement>",
2672
+ "defaultValue": null,
2673
+ "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}"
2674
+ },
2675
+ {
2676
+ "name": "render",
2677
+ "required": false,
2678
+ "type": "| ReactElement<\n unknown,\n string | JSXElementConstructor<any>\n >\n| ComponentRenderFn<HTMLProps, MeterRootState>",
2679
+ "defaultValue": null,
2680
+ "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."
2681
+ },
2682
+ {
2683
+ "name": "style",
2684
+ "required": false,
2685
+ "type": "| CSSProperties\n| ((state: MeterRootState) => CSSProperties)",
2686
+ "defaultValue": null,
2687
+ "description": "Style applied to the element, or a function that\nreturns a style object based on the component's state."
2688
+ },
2689
+ {
2690
+ "name": "value",
2691
+ "required": true,
2692
+ "type": "number",
2693
+ "defaultValue": null,
2694
+ "description": "The current value."
2695
+ }
2696
+ ]
2697
+ },
2698
+ "subComponents": [
2699
+ {
2700
+ "name": "Meter.Indicator",
2701
+ "description": "Meter.Indicator — filled portion of the track up to the value.",
2702
+ "props": [
2703
+ {
2704
+ "name": "className",
2705
+ "required": false,
2706
+ "type": "string | ((state: MeterIndicatorState) => string)",
2707
+ "defaultValue": null,
2708
+ "description": "CSS class applied to the element, or a function that\nreturns a class based on the component's state."
2709
+ },
2710
+ {
2711
+ "name": "ref",
2712
+ "required": false,
2713
+ "type": "Ref<HTMLDivElement>",
2714
+ "defaultValue": null,
2715
+ "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}"
2716
+ },
2717
+ {
2718
+ "name": "render",
2719
+ "required": false,
2720
+ "type": "| ReactElement<\n unknown,\n string | JSXElementConstructor<any>\n >\n| ComponentRenderFn<HTMLProps, MeterIndicatorState>",
2721
+ "defaultValue": null,
2722
+ "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."
2723
+ },
2724
+ {
2725
+ "name": "style",
2726
+ "required": false,
2727
+ "type": "| CSSProperties\n| ((state: MeterIndicatorState) => CSSProperties)",
2728
+ "defaultValue": null,
2729
+ "description": "Style applied to the element, or a function that\nreturns a style object based on the component's state."
2730
+ }
2731
+ ]
2732
+ },
2733
+ {
2734
+ "name": "Meter.Label",
2735
+ "description": "Meter.Label — accessible label for the meter.",
2736
+ "props": [
2737
+ {
2738
+ "name": "className",
2739
+ "required": false,
2740
+ "type": "string | ((state: MeterLabelState) => string)",
2741
+ "defaultValue": null,
2742
+ "description": "CSS class applied to the element, or a function that\nreturns a class based on the component's state."
2743
+ },
2744
+ {
2745
+ "name": "ref",
2746
+ "required": false,
2747
+ "type": "Ref<HTMLDivElement>",
2748
+ "defaultValue": null,
2749
+ "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}"
2750
+ },
2751
+ {
2752
+ "name": "render",
2753
+ "required": false,
2754
+ "type": "| ReactElement<\n unknown,\n string | JSXElementConstructor<any>\n >\n| ComponentRenderFn<HTMLProps, MeterLabelState>",
2755
+ "defaultValue": null,
2756
+ "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."
2757
+ },
2758
+ {
2759
+ "name": "style",
2760
+ "required": false,
2761
+ "type": "| CSSProperties\n| ((state: MeterLabelState) => CSSProperties)",
2762
+ "defaultValue": null,
2763
+ "description": "Style applied to the element, or a function that\nreturns a style object based on the component's state."
2764
+ }
2765
+ ]
2766
+ },
2767
+ {
2768
+ "name": "Meter.Track",
2769
+ "description": "Meter.Track — the full range.",
2770
+ "props": [
2771
+ {
2772
+ "name": "className",
2773
+ "required": false,
2774
+ "type": "string | ((state: MeterTrackState) => string)",
2775
+ "defaultValue": null,
2776
+ "description": "CSS class applied to the element, or a function that\nreturns a class based on the component's state."
2777
+ },
2778
+ {
2779
+ "name": "ref",
2780
+ "required": false,
2781
+ "type": "Ref<HTMLDivElement>",
2782
+ "defaultValue": null,
2783
+ "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}"
2784
+ },
2785
+ {
2786
+ "name": "render",
2787
+ "required": false,
2788
+ "type": "| ReactElement<\n unknown,\n string | JSXElementConstructor<any>\n >\n| ComponentRenderFn<HTMLProps, MeterTrackState>",
2789
+ "defaultValue": null,
2790
+ "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."
2791
+ },
2792
+ {
2793
+ "name": "style",
2794
+ "required": false,
2795
+ "type": "| CSSProperties\n| ((state: MeterTrackState) => CSSProperties)",
2796
+ "defaultValue": null,
2797
+ "description": "Style applied to the element, or a function that\nreturns a style object based on the component's state."
2798
+ }
2799
+ ]
2800
+ },
2801
+ {
2802
+ "name": "Meter.Value",
2803
+ "description": "Meter.Value — formatted readout of the current value.",
2804
+ "props": [
2805
+ {
2806
+ "name": "className",
2807
+ "required": false,
2808
+ "type": "string | ((state: MeterValueState) => string)",
2809
+ "defaultValue": null,
2810
+ "description": "CSS class applied to the element, or a function that\nreturns a class based on the component's state."
2811
+ },
2812
+ {
2813
+ "name": "ref",
2814
+ "required": false,
2815
+ "type": "Ref<HTMLDivElement>",
2816
+ "defaultValue": null,
2817
+ "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}"
2818
+ },
2819
+ {
2820
+ "name": "render",
2821
+ "required": false,
2822
+ "type": "| ReactElement<\n unknown,\n string | JSXElementConstructor<any>\n >\n| ComponentRenderFn<HTMLProps, MeterValueState>",
2823
+ "defaultValue": null,
2824
+ "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."
2825
+ },
2826
+ {
2827
+ "name": "style",
2828
+ "required": false,
2829
+ "type": "| CSSProperties\n| ((state: MeterValueState) => CSSProperties)",
2830
+ "defaultValue": null,
2831
+ "description": "Style applied to the element, or a function that\nreturns a style object based on the component's state."
2832
+ }
2833
+ ]
2834
+ }
2835
+ ]
2836
+ },
2600
2837
  "navigation-menu": {
2601
2838
  "root": {
2602
2839
  "name": "NavigationMenu.Root",
@@ -129,6 +129,12 @@ Single-line text input for form data entry. Also called a text field; it support
129
129
  Renders a logo from a URL or inline React element with consistent sizing. Also called a wordmark or brand mark.
130
130
  - props: node_modules/@imfusion/web-ui/src/docgen/doc.gen.json -> .logo (jq: jq '.logo' node_modules/@imfusion/web-ui/src/docgen/doc.gen.json)
131
131
 
132
+ ## Meter
133
+ - category: Display, status: experimental
134
+ Read-only bar for a measured amount within a known range, such as seats in use or storage used. Also called a gauge or usage bar. Use Slider when the user sets the value.
135
+ - props: node_modules/@imfusion/web-ui/src/docgen/doc.gen.json -> .meter (jq: jq '.meter' node_modules/@imfusion/web-ui/src/docgen/doc.gen.json)
136
+ - further reading (usage/anatomy, not props): https://base-ui.com/react/components/meter.md
137
+
132
138
  ## NavigationMenu
133
139
  - category: Display, status: experimental
134
140
  Navigation menu with horizontal or vertical triggers and anchored flyout panels. Also called a menu bar or mega menu; it supports links, rich cards, and nested navigation.