@oicl/openbridge-webcomponents-full-bundle 2.0.0-next.48 → 2.0.0-next.50

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.
Files changed (56) hide show
  1. package/.storybook/ComponentPreview.tsx +26 -0
  2. package/.storybook/PreviewTemplate.tsx +99 -0
  3. package/.storybook/action-handler.ts +81 -0
  4. package/.storybook/channels.ts +44 -0
  5. package/.storybook/main.ts +313 -0
  6. package/.storybook/manager.ts +71 -0
  7. package/.storybook/openbridgeTheme.ts +197 -0
  8. package/.storybook/preview-head.html +15 -0
  9. package/.storybook/preview.tsx +129 -0
  10. package/.storybook/vitest.setup.ts +23 -0
  11. package/bundle/openbridge-webcomponents.bundle.js +196 -38
  12. package/bundle/openbridge-webcomponents.bundle.js.map +1 -1
  13. package/custom-elements.json +16 -1
  14. package/dist/automation/automation-tank/automation-tank.css.js +166 -28
  15. package/dist/automation/automation-tank/automation-tank.css.js.map +1 -1
  16. package/dist/automation/automation-tank/automation-tank.d.ts +32 -0
  17. package/dist/automation/automation-tank/automation-tank.d.ts.map +1 -1
  18. package/dist/automation/automation-tank/automation-tank.js +28 -0
  19. package/dist/automation/automation-tank/automation-tank.js.map +1 -1
  20. package/dist/components/icon-button/icon-button.d.ts +4 -0
  21. package/dist/components/icon-button/icon-button.d.ts.map +1 -1
  22. package/dist/components/icon-button/icon-button.js.map +1 -1
  23. package/dist/components/message-menu-item/message-menu-item.css.js +2 -10
  24. package/dist/components/message-menu-item/message-menu-item.css.js.map +1 -1
  25. package/eslint.config.mjs +589 -0
  26. package/fix-imports.mjs +185 -0
  27. package/fix-js-extensions.mjs +44 -0
  28. package/lit-localize.json +15 -0
  29. package/new-component.ts +148 -0
  30. package/package.json +55 -3
  31. package/postcss.config.mjs +195 -0
  32. package/script/check-css-mixins.ts +191 -0
  33. package/script/check-css-variables.ts +280 -0
  34. package/script/convert-icons.ts +202 -0
  35. package/script/convert-vessel-svg-to-ts.ts +110 -0
  36. package/script/docgen/README.md +95 -0
  37. package/script/docgen/docs-gen.ts +225 -0
  38. package/script/docgen/prompt-system.txt +187 -0
  39. package/script/download-alert-icons.ts +193 -0
  40. package/script/download-icons.ts +314 -0
  41. package/script/figmavariables.json +139 -0
  42. package/script/generate-bundle-entry.ts +77 -0
  43. package/script/prepare-full-bundle.ts +105 -0
  44. package/script/sort-custom-element-manifest.ts +67 -0
  45. package/src/automation/automation-tank/automation-tank.css +119 -21
  46. package/src/automation/automation-tank/automation-tank.stories.ts +38 -0
  47. package/src/automation/automation-tank/automation-tank.ts +64 -0
  48. package/src/components/icon-button/icon-button.ts +4 -0
  49. package/src/components/message-menu-item/message-menu-item.css +2 -5
  50. package/vite.config.ts +107 -0
  51. package/vitest.browser.config.ts +14 -0
  52. package/vitest.config.ts +51 -0
  53. package/xliff/es-419.xlf +111 -0
  54. package/xliff/fi-FI.xlf +139 -0
  55. package/dist/NotoSans.ttf +0 -0
  56. package/dist/oicl.svg +0 -4
@@ -15289,6 +15289,15 @@
15289
15289
  "description": "Number of fraction digits used to format the percent readout in the\nnon-compact (regular) layout. Defaults to `0` (integer percent). The\ncompact layout always renders integer percent to keep its fixed-width\nfootprint stable. The static layout renders capacity (`max` + `unit`)\nrather than percent, so this property has no effect there — pass a\npre-formatted value through the `max-value` slot if fractional\nprecision is needed (see the `WithFractionDigits` story).",
15290
15290
  "attribute": "percentFractionDigits"
15291
15291
  },
15292
+ {
15293
+ "kind": "field",
15294
+ "name": "readout",
15295
+ "type": {
15296
+ "text": "TankReadoutItem[]"
15297
+ },
15298
+ "default": "[]",
15299
+ "description": "Rich detail rows shown below the main percent/value block in the regular\n(non-compact, non-static) layout, separated by a divider. When empty (the\ndefault), nothing is rendered — neither the divider nor the list. In\nvertical orientation the chart cell shrinks to make room; in horizontal\norientation the readout column already has reserved whitespace so the\nchart is unaffected.\n\nValues are formatted using `percentFractionDigits`. Consumers that need\nfull control over the markup can replace the entire fallback by slotting\narbitrary content into `slot=\"rich\"` (note: this is a different name from\nthe existing `slot=\"readout\"` which replaces the whole readout block)."
15300
+ },
15292
15301
  {
15293
15302
  "kind": "field",
15294
15303
  "name": "badgeControl",
@@ -47352,7 +47361,7 @@
47352
47361
  "declarations": [
47353
47362
  {
47354
47363
  "kind": "class",
47355
- "description": "`<obc-icon-button>` – An icon-only or icon-with-label button for quick actions.\n\nProvides a compact, visually prominent button that displays an icon (and optionally a label) for triggering actions. Commonly used for toolbars, navigation, or contextual actions where space is limited and a recognizable icon can represent the function.\n\nAppears as a circular or rounded button with configurable visual styles, supporting progress indication and various layout adaptations.\n\n## Features\n- **Variants:**\n - `normal` (default): Standard appearance for most use cases.\n - `raised`: Adds elevation/shadow for prominence.\n - `flat`: Minimal, backgroundless style for subtle actions.\n- **Progress Indicator:**\n - Shows a circular progress spinner overlay when the `progress` property is set (0–100). Useful for indicating loading or ongoing actions.\n- **Label Support:**\n - Optionally displays a text label below the icon when `hasLabel` is true and content is provided in the `label` slot.\n- **Corner Alignment:**\n - `cornerLeft` and `cornerRight` adjust the button's border radius and alignment for seamless placement at the start or end of a container.\n- **Active State:**\n - `activated` visually highlights the button as selected or toggled.\n - `activeColor` applies an accent color for emphasis.\n- **Wide Mode:**\n - `wide` increases the button's width for easier touch targets or visual balance.\n- **Disabled State:**\n - `disabled` prevents interaction and visually dims the button.\n\n## Usage Guidelines\n- Use `obc-icon-button` for actions represented by icons, such as toolbars, navigation, or quick-access commands.\n- Add a label (with `hasLabel` and the `label` slot) when clarity is needed or when icons alone may not be universally understood.\n- Use the progress indicator for actions that take time, such as uploads or background processes.\n- Prefer the `normal` variant for most cases; use `raised` to draw attention, and `flat` for less prominent or inline actions.\n- For grouped or edge-aligned layouts, use `cornerLeft` or `cornerRight` to visually merge with container edges.\n- Avoid using icon buttons for destructive or critical actions unless paired with clear feedback.\n- **TODO(designer):** Clarify recommended icon sizes and when to use label vs. icon-only.\n\n## Slots\n| Slot Name | Renders When... | Purpose |\n|-----------|---------------------|----------------------------------------------|\n| (default) | Always | The icon to display (e.g., `<obi-search>`) |\n| label | If `hasLabel` is set | Optional label text below the icon |\n\n## Best Practices\n- Ensure icons are clear and universally recognizable.\n- For accessibility, provide an `aria-label` or descriptive label for the button's action.\n- When using the progress indicator, avoid showing it for very short actions to prevent visual flicker.\n\n## Example:\n```\n<obc-icon-button variant=\"normal\">\n <obi-search></obi-search>\n</obc-icon-button>\n\n<obc-icon-button variant=\"normal\" hasLabel>\n <obi-arrow></obi-arrow>\n <span slot=\"label\">Next</span>\n</obc-icon-button>\n```",
47364
+ "description": "`<obc-icon-button>` – An icon-only or icon-with-label button for quick actions.\n\nProvides a compact, visually prominent button that displays an icon (and optionally a label) for triggering actions. Commonly used for toolbars, navigation, or contextual actions where space is limited and a recognizable icon can represent the function.\n\nAppears as a circular or rounded button with configurable visual styles, supporting progress indication and various layout adaptations.\n\n## Features\n- **Variants:**\n - `normal` (default): Standard appearance for most use cases.\n - `raised`: Adds elevation/shadow for prominence.\n - `flat`: Minimal, backgroundless style for subtle actions.\n- **Progress Indicator:**\n - Shows a circular progress spinner overlay when the `progress` property is set (0–100). Useful for indicating loading or ongoing actions.\n- **Label Support:**\n - Optionally displays a text label below the icon when `hasLabel` is true and content is provided in the `label` slot.\n- **Corner Alignment:**\n - `cornerLeft` and `cornerRight` adjust the button's border radius and alignment for seamless placement at the start or end of a container.\n- **Active State:**\n - `activated` visually highlights the button as selected or toggled.\n - `activeColor` applies an accent color for emphasis.\n- **Wide Mode:**\n - `wide` increases the button's width for easier touch targets or visual balance.\n- **Disabled State:**\n - `disabled` prevents interaction and visually dims the button.\n\n## Usage Guidelines\n- Use `obc-icon-button` for actions represented by icons, such as toolbars, navigation, or quick-access commands.\n- Add a label (with `hasLabel` and the `label` slot) when clarity is needed or when icons alone may not be universally understood.\n- Use the progress indicator for actions that take time, such as uploads or background processes.\n- Prefer the `normal` variant for most cases; use `raised` to draw attention, and `flat` for less prominent or inline actions.\n- For grouped or edge-aligned layouts, use `cornerLeft` or `cornerRight` to visually merge with container edges.\n- Avoid using icon buttons for destructive or critical actions unless paired with clear feedback.\n- **TODO(designer):** Clarify recommended icon sizes and when to use label vs. icon-only.\n\n## Slots\n| Slot Name | Renders When... | Purpose |\n|-----------|---------------------|----------------------------------------------|\n| (default) | Always | The icon to display (e.g., `<obi-search>`) |\n| label | If `hasLabel` is set | Optional label text below the icon |\n\n## Events\n- Emits a standard `click` event (`onClick` handler in framework wrappers) when activated.\n\n## Best Practices\n- Ensure icons are clear and universally recognizable.\n- For accessibility, provide an `aria-label` or descriptive label for the button's action.\n- When using the progress indicator, avoid showing it for very short actions to prevent visual flicker.\n\n## Example:\n```\n<obc-icon-button variant=\"normal\">\n <obi-search></obi-search>\n</obc-icon-button>\n\n<obc-icon-button variant=\"normal\" hasLabel>\n <obi-arrow></obi-arrow>\n <span slot=\"label\">Next</span>\n</obc-icon-button>\n```",
47356
47365
  "name": "ObcIconButton",
47357
47366
  "slots": [
47358
47367
  {
@@ -47469,6 +47478,12 @@
47469
47478
  "readonly": true
47470
47479
  }
47471
47480
  ],
47481
+ "events": [
47482
+ {
47483
+ "description": "Fired when the button is clicked (if not disabled).",
47484
+ "name": "click"
47485
+ }
47486
+ ],
47472
47487
  "attributes": [
47473
47488
  {
47474
47489
  "name": "variant",
@@ -307,16 +307,6 @@ const compentStyle = css`
307
307
  flex: 0 0 auto;
308
308
  }
309
309
 
310
- /* Override the global \`min-height: 24px\` on \`.badges\` so empty badge rows
311
- * don't reserve space in compact/static — the spec says "if there are no
312
- * badges it would grow upward". The slot-driven \`?hidden\` attribute on
313
- * empty cells makes them \`display: none\` (see below). */
314
-
315
- :host([compact]) .halo > .badges,
316
- :host([static]) .halo > .badges {
317
- min-height: 0;
318
- }
319
-
320
310
  /* \`hidden\` attribute support: needed because the cells set an explicit
321
311
  * display value (\`flex\` / \`block\`), which would otherwise override
322
312
  * \`hidden\`'s default \`display: none\`. Removing the cell from the flex
@@ -440,7 +430,7 @@ const compentStyle = css`
440
430
  grid-row: 1;
441
431
  grid-column: 2;
442
432
  justify-self: end;
443
- align-self: center;
433
+ align-self: start;
444
434
  }
445
435
 
446
436
  .tank-frame:not(.orientation-horizontal) .grid > .readout {
@@ -470,7 +460,7 @@ const compentStyle = css`
470
460
  grid-row: 1;
471
461
  grid-column: 2;
472
462
  justify-self: end;
473
- align-self: center;
463
+ align-self: start;
474
464
  }
475
465
 
476
466
  .tank-frame.orientation-horizontal .grid > .bar-container {
@@ -482,7 +472,6 @@ const compentStyle = css`
482
472
  grid-row: 2;
483
473
  grid-column: 2;
484
474
  align-self: stretch;
485
- padding-left: 8px;
486
475
  min-width: 96px;
487
476
  }
488
477
 
@@ -491,7 +480,7 @@ const compentStyle = css`
491
480
  .badges {
492
481
  display: flex;
493
482
  justify-content: end;
494
- min-height: 24px;
483
+ gap: 4px;
495
484
  pointer-events: auto;
496
485
  }
497
486
 
@@ -505,7 +494,7 @@ const compentStyle = css`
505
494
  "liga" off,
506
495
  "clig" off,
507
496
  "ss04" on;
508
- color: var(--instrument-regular-secondary-color);
497
+ color: var(--element-neutral-color);
509
498
  /* Tag text must never break across lines — it is a fixed identifier
510
499
  * (e.g. \`FUEL\`, \`#0000\`) that loses meaning if hyphenated or wrapped. */
511
500
  white-space: nowrap;
@@ -526,28 +515,63 @@ const compentStyle = css`
526
515
  /* Keep \`90%\` together — the parent flex prevents flex-item wrapping but
527
516
  * not text wrapping inside \`.percent\` (number + \`<span>%</span>\`). */
528
517
  white-space: nowrap;
529
- font-family: var(--global-typography-font-family);
530
- font-size: var(--global-typography-instrument-label-font-size);
531
- line-height: var(--global-typography-instrument-label-line-height);
532
- font-feature-settings:
518
+ color: var(--element-neutral-color);
519
+ }
520
+
521
+ .readout-compact .percent {
522
+ font-family: var(--global-typography-font-family);
523
+ font-size: var(--global-typography-instrument-value-regular-font-size);
524
+ line-height: var(--global-typography-instrument-value-regular-line-height);
525
+ font-feature-settings:
533
526
  "liga" off,
534
527
  "clig" off,
535
528
  "ss04" on;
536
- color: var(--instrument-regular-secondary-color);
537
- }
529
+ }
538
530
 
539
531
  .readout-compact .percent-symbol {
540
- margin-left: 1px;
532
+ font-family: var(--global-typography-font-family);
533
+ font-size: var(--global-typography-instrument-unit-font-size);
534
+ line-height: var(--global-typography-instrument-unit-line-height);
535
+ font-feature-settings:
536
+ "liga" off,
537
+ "clig" off,
538
+ "ss04" on;
539
+ margin-left: 1px;
540
+ }
541
+
542
+ /* Static readout: max-value + unit (no percent, no trend icon). Tighter
543
+ * 2px gap and small-neutral value sizing per design spec. Color is
544
+ * inherited from \`.readout-compact\`. */
545
+
546
+ .readout-static {
547
+ gap: 2px;
541
548
  }
542
549
 
550
+ .readout-static slot[name="max-value"] {
551
+ font-family: var(--global-typography-font-family);
552
+ font-size: var(--global-typography-instrument-value-small-font-size);
553
+ line-height: var(--global-typography-instrument-value-small-line-height);
554
+ font-feature-settings:
555
+ "liga" off,
556
+ "clig" off,
557
+ "ss04" on;
558
+ }
559
+
560
+ .readout-static slot[name="unit"] {
561
+ font-family: var(--global-typography-font-family);
562
+ font-size: var(--global-typography-instrument-unit-font-size);
563
+ line-height: var(--global-typography-instrument-unit-line-height);
564
+ font-feature-settings:
565
+ "liga" off,
566
+ "clig" off,
567
+ "ss04" on;
568
+ }
569
+
543
570
  .header {
544
571
  display: flex;
545
572
  align-items: center;
546
573
  justify-content: flex-end;
547
574
  gap: 4px;
548
- /* TODO: we will need such divider in the future for the 'rich' option */
549
- /* border-bottom: 1px solid var(--border-outline-color); */
550
- padding-bottom: 2px;
551
575
  }
552
576
 
553
577
  .header .percent {
@@ -561,18 +585,26 @@ const compentStyle = css`
561
585
  "liga" off,
562
586
  "clig" off,
563
587
  "ss04" on;
588
+ color: var(--element-neutral-color);
589
+ padding-bottom: var(
590
+ --global-typography-instrument-value-large-padding-bottom
591
+ );
564
592
  /* Keep the number and the trailing \`%\` symbol on one line. */
565
593
  white-space: nowrap;
566
594
  }
567
595
 
568
596
  .header .percent-symbol {
569
- font-family: var(--font-family-main);
570
- font-size: var(--global-typography-ui-body-font-size);
571
- line-height: var(--global-typography-ui-body-line-height);
597
+ font-family: var(--global-typography-font-family);
598
+ font-size: var(--global-typography-instrument-unit-font-size);
599
+ line-height: var(--global-typography-instrument-unit-line-height);
572
600
  font-feature-settings:
573
601
  "liga" off,
574
602
  "clig" off,
575
603
  "ss04" on;
604
+ /* \`inline-block\` so \`padding-bottom\` actually applies (ignored on
605
+ * plain inline text). */
606
+ display: inline-block;
607
+ padding-bottom: var(--global-typography-instrument-unit-padding-bottom);
576
608
  }
577
609
 
578
610
  .value {
@@ -605,11 +637,15 @@ const compentStyle = css`
605
637
  "liga" off,
606
638
  "clig" off,
607
639
  "ss04" on;
640
+ padding-bottom: var(
641
+ --global-typography-instrument-value-regular-padding-bottom
642
+ );
608
643
  }
609
644
 
610
645
  .value .divider {
611
646
  padding-left: 4px;
612
647
  padding-right: 4px;
648
+ padding-bottom: var(--global-typography-instrument-unit-padding-bottom);
613
649
  }
614
650
 
615
651
  .value .max-value {
@@ -620,8 +656,110 @@ const compentStyle = css`
620
656
  "liga" off,
621
657
  "clig" off,
622
658
  "ss04" on;
659
+ padding-bottom: var(
660
+ --global-typography-instrument-value-regular-padding-bottom
661
+ );
662
+ }
663
+
664
+ .value .unit {
665
+ padding-bottom: var(--global-typography-instrument-unit-padding-bottom);
623
666
  }
624
667
 
668
+ .rich-divider {
669
+ border-top: 1px solid var(--border-divider-color);
670
+ margin-top: 8px;
671
+ }
672
+
673
+ .rich {
674
+ display: grid;
675
+ /* label takes remaining space; value (right-aligned) and suffix
676
+ * (left-aligned) form fixed content columns so digit right edges and
677
+ * suffix left edges align vertically across all rows. */
678
+ grid-template-columns: 1fr auto auto;
679
+ align-items: baseline;
680
+ row-gap: 4px;
681
+ padding-top: 8px;
682
+ white-space: nowrap;
683
+ font-family: var(--global-typography-font-family);
684
+ font-size: var(--global-typography-instrument-unit-font-size);
685
+ line-height: var(--global-typography-instrument-unit-line-height);
686
+ font-feature-settings:
687
+ "liga" off,
688
+ "clig" off,
689
+ "ss04" on;
690
+ }
691
+
692
+ .rich-row {
693
+ display: grid;
694
+ grid-template-columns: subgrid;
695
+ grid-column: 1 / -1;
696
+ align-items: baseline;
697
+ padding-left: var(
698
+ --instrument-components-readout-new-list-item-regular-container-padding-horizontal
699
+ );
700
+ padding-right: var(
701
+ --instrument-components-readout-new-list-item-regular-container-padding-horizontal
702
+ );
703
+ }
704
+
705
+ .rich-label {
706
+ font-family: var(--global-typography-font-family);
707
+ font-size: var(--global-typography-instrument-label-font-size);
708
+ line-height: var(--global-typography-instrument-label-line-height);
709
+ font-feature-settings:
710
+ "liga" off,
711
+ "clig" off,
712
+ "ss04" on;
713
+ color: var(--element-inactive-color);
714
+ padding-right: 8px;
715
+ text-align: left;
716
+ }
717
+
718
+ .rich-value {
719
+ font-family: var(--global-typography-font-family);
720
+ font-size: var(--global-typography-instrument-value-regular-font-size);
721
+ line-height: var(--global-typography-instrument-value-regular-line-height);
722
+ font-feature-settings:
723
+ "liga" off,
724
+ "clig" off,
725
+ "ss04" on;
726
+ color: var(--element-neutral-color);
727
+ font-variant-numeric: tabular-nums;
728
+ text-align: right;
729
+ }
730
+
731
+ .rich-suffix {
732
+ display: inline-flex;
733
+ align-items: baseline;
734
+ /* Default 2px gap between value and unit when there is no degree/percent
735
+ * glyph. When a glyph is present it sits flush against the value and the
736
+ * unit follows flush after the glyph (see \`.rich-glyph + .rich-unit\`). */
737
+ padding-left: 2px;
738
+ }
739
+
740
+ .rich-suffix:has(.rich-glyph) {
741
+ padding-left: 0;
742
+ }
743
+
744
+ .rich-glyph {
745
+ font-family: var(--global-typography-font-family);
746
+ font-size: var(--global-typography-instrument-value-regular-font-size);
747
+ line-height: var(--global-typography-instrument-value-regular-line-height);
748
+ font-feature-settings:
749
+ "liga" off,
750
+ "clig" off,
751
+ "ss04" on;
752
+ color: var(--element-neutral-color);
753
+ }
754
+
755
+ .rich-unit {
756
+ color: var(--element-inactive-color);
757
+ }
758
+
759
+ .rich-glyph + .rich-unit {
760
+ padding-left: 0;
761
+ }
762
+
625
763
  /* The chart cell is a plain sizing/clipping box. Both child renderers —
626
764
  * \`obc-gauge-trend\` (graph / graph-and-bar modes) and \`obc-bar-vertical\`
627
765
  * (bar mode) — paint their own background, border and border-radius. */
@@ -1 +1 @@
1
- {"version":3,"file":"automation-tank.css.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -61,6 +61,24 @@ export declare enum TankChartMode {
61
61
  /** Embedded `obc-gauge-trend` line/area chart with a side bar. */
62
62
  graphAndBar = "graph-and-bar"
63
63
  }
64
+ /**
65
+ * A single detail row rendered in the tank's `readout` rich list (below the
66
+ * main percent / value block, separated by a divider). Each row is rendered
67
+ * as `<label>` on the left and `<value><degree?><percent?><unit>` on the
68
+ * right, all on a single line.
69
+ */
70
+ export interface TankReadoutItem {
71
+ /** Left-aligned label text (e.g. `Temperature`). */
72
+ label: string;
73
+ /** Numeric value, formatted with the tank's `percentFractionDigits`. */
74
+ value: number;
75
+ /** Append a `°` glyph directly after the value with no gap. */
76
+ hasDegree?: boolean;
77
+ /** Append a `%` glyph directly after the value with no gap. */
78
+ hasPercentage?: boolean;
79
+ /** Unit text (e.g. `C`, `Pa`, `m/s`). Rendered after the value/glyph. */
80
+ unit: string;
81
+ }
64
82
  /**
65
83
  *
66
84
  *
@@ -168,6 +186,20 @@ export declare class ObcAutomationTank extends LitElement {
168
186
  * precision is needed (see the `WithFractionDigits` story).
169
187
  */
170
188
  percentFractionDigits: number;
189
+ /**
190
+ * Rich detail rows shown below the main percent/value block in the regular
191
+ * (non-compact, non-static) layout, separated by a divider. When empty (the
192
+ * default), nothing is rendered — neither the divider nor the list. In
193
+ * vertical orientation the chart cell shrinks to make room; in horizontal
194
+ * orientation the readout column already has reserved whitespace so the
195
+ * chart is unaffected.
196
+ *
197
+ * Values are formatted using `percentFractionDigits`. Consumers that need
198
+ * full control over the markup can replace the entire fallback by slotting
199
+ * arbitrary content into `slot="rich"` (note: this is a different name from
200
+ * the existing `slot="readout"` which replaces the whole readout block).
201
+ */
202
+ readout: TankReadoutItem[];
171
203
  /**
172
204
  * Enum-driven badges rendered inside the `badges` cell. Mirrors the API
173
205
  * introduced for `ObcAbstractAutomationButton` in PR #839 (#829). When set
@@ -1 +1 @@
1
- {"version":3,"file":"automation-tank.d.ts","sourceRoot":"","sources":["../../../src/automation/automation-tank/automation-tank.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,kBAAkB,EAClB,UAAU,EAEV,OAAO,EAGR,MAAM,KAAK,CAAC;AAGb,OAAO,EAAC,UAAU,EAAC,MAAM,aAAa,CAAC;AACvC,OAAO,yCAAyC,CAAC;AAEjD,OAAO,EACL,0BAA0B,EAC1B,kCAAkC,EAClC,4BAA4B,EAC5B,8BAA8B,EAC/B,MAAM,oDAAoD,CAAC;AAE5D,OAAO,8CAA8C,CAAC;AACtD,OAAO,uCAAuC,CAAC;AAC/C,OAAO,gDAAgD,CAAC;AACxD,OAAO,yCAAyC,CAAC;AACjD,OAAO,yBAAyB,CAAC;AACjC,OAAO,0BAA0B,CAAC;AAClC,OAAO,oCAAoC,CAAC;AAC5C,OAAO,yDAAyD,CAAC;AACjE,OAAO,oDAAoD,CAAC;AAC5D,OAAO,6CAA6C,CAAC;AACrD,OAAO,EAAC,QAAQ,EAAC,MAAM,uCAAuC,CAAC;AAC/D,OAAO,EACL,mBAAmB,EACnB,sBAAsB,EACtB,iBAAiB,EAClB,MAAM,6CAA6C,CAAC;AACrD,OAAO,KAAK,EAAC,iBAAiB,EAAC,MAAM,qDAAqD,CAAC;AAC3F,OAAO,KAAK,EAAC,YAAY,EAAC,MAAM,mDAAmD,CAAC;AASpF,oBAAY,SAAS;IACnB,UAAU,gBAAgB;IAC1B,MAAM,WAAW;IACjB,MAAM,WAAW;IACjB,OAAO,YAAY;IACnB,WAAW,iBAAiB;IAC5B,MAAM,WAAW;CAClB;AAED,oBAAY,QAAQ;IAClB,OAAO,YAAY;IACnB,WAAW,gBAAgB;IAC3B,WAAW,gBAAgB;IAC3B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E,OAAO,CAAQ;IAE7E;;;;;;;;OAQG;IACuB,qBAAqB,EAAE,MAAM,CAAK;IAE5D;;;;;;;;;;;OAWG;IACuB,YAAY,EAAE,4BAA4B,CAChC;IACV,UAAU,EAAE,0BAA0B,CAC9B;IACR,cAAc,EAAE,8BAA8B,CAClC;IAEtC,kBAAkB,EAAE,kCAAkC,CACZ;IAEjC,OAAO,CAAC,UAAU,CAAK;IACvB,OAAO,CAAC,WAAW,CAAK;IACjC;;;;;;OAMG;IACM,OAAO,CAAC,UAAU,CAAS;IAC3B,OAAO,CAAC,WAAW,CAAS;IACrC,OAAO,CAAC,oBAAoB,CAAC,CAAiB;IAC9C,OAAO,CAAC,aAAa,CAAC,CAAU;IAEhC,OAAO,KAAK,SAAS,GAEpB;IAED,OAAO,CAAC,eAAe;IAevB,OAAO,CAAC,iBAAiB;IAiBzB,OAAO,CAAC,mBAAmB;IAW3B,OAAO,CAAC,uBAAuB;IAU/B,OAAO,KAAK,eAAe,GAK1B;IAED,OAAO,CAAC,mBAAmB;IAW3B,OAAO,CAAC,gBAAgB;IAWf,oBAAoB,IAAI,IAAI;cAOlB,OAAO,CACxB,OAAO,EAAE,GAAG,CAAC,MAAM,GAAG,MAAM,GAAG,MAAM,EAAE,OAAO,CAAC,GAC9C,IAAI;IAaP,OAAO,CAAC,wBAAwB;IA8BhC,SAAS,IAAI,kBAAkB,GAAG,OAAO,OAAO;IAyBhD;;;;;;;;;;;;;OAaG;IACH,OAAO,CAAC,oBAAoB;IAmJ5B,OAAO,CAAC,SAAS;IAaR,MAAM;IA6Vf,OAAgB,MAAM,0BAA2B;CAClD;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,qBAAqB,EAAE,iBAAiB,CAAC;KAC1C;CACF"}
1
+ {"version":3,"file":"automation-tank.d.ts","sourceRoot":"","sources":["../../../src/automation/automation-tank/automation-tank.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,kBAAkB,EAClB,UAAU,EAEV,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this.showTrendSymbol = true;
89
89
  this.percentFractionDigits = 0;
90
+ this.readout = [];
90
91
  this.badgeControl = AutomationButtonBadgeControl.None;
91
92
  this.badgeAlert = AutomationButtonBadgeAlert.None;
92
93
  this.badgeInterlock = AutomationButtonBadgeInterlock.None;
@@ -435,6 +436,30 @@ let ObcAutomationTank = class extends LitElement {
435
436
  <slot class="unit" name="unit">m<sup>3</sup></slot>
436
437
  </div>
437
438
  </div>
439
+ <slot name="rich">
440
+ ${this.readout.length > 0 ? html`
441
+ <div class="rich-divider"></div>
442
+ <div class="rich">
443
+ ${this.readout.map(
444
+ (row) => html`
445
+ <div class="rich-row">
446
+ <span class="rich-label">${row.label}</span>
447
+ <span class="rich-value"
448
+ >${row.value.toFixed(
449
+ this.percentFractionDigits
450
+ )}</span
451
+ >
452
+ <span class="rich-suffix"
453
+ >${row.hasDegree ? html`<span class="rich-glyph">°</span>` : nothing}${row.hasPercentage ? html`<span class="rich-glyph">%</span>` : nothing}<span class="rich-unit"
454
+ >${row.unit}</span
455
+ ></span
456
+ >
457
+ </div>
458
+ `
459
+ )}
460
+ </div>
461
+ ` : nothing}
462
+ </slot>
438
463
  </slot>
439
464
  </div>
440
465
  `;
@@ -657,6 +682,9 @@ __decorateClass([
657
682
  __decorateClass([
658
683
  property({ type: Number })
659
684
  ], ObcAutomationTank.prototype, "percentFractionDigits", 2);
685
+ __decorateClass([
686
+ property({ type: Array, attribute: false })
687
+ ], ObcAutomationTank.prototype, "readout", 2);
660
688
  __decorateClass([
661
689
  property({ type: String })
662
690
  ], ObcAutomationTank.prototype, "badgeControl", 2);