@oicl/openbridge-webcomponents-full-bundle 2.2.0-next.22 → 2.2.0-next.23
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/custom-elements-manifest.config.mjs +2 -1
- package/custom-elements.json +312 -17
- package/llms/components/obc-accordion-card.md +141 -0
- package/llms/components/obc-accordion-item.md +90 -0
- package/llms/components/obc-advice-button.md +87 -0
- package/llms/components/obc-advice-floating-item.md +113 -0
- package/llms/components/obc-advice-menu-item.md +87 -0
- package/llms/components/obc-advice-message-item.md +138 -0
- package/llms/components/obc-alert-button-item.md +117 -0
- package/llms/components/obc-alert-button.md +134 -0
- package/llms/components/obc-alert-counter-item.md +74 -0
- package/llms/components/obc-alert-detail-page.md +45 -0
- package/llms/components/obc-alert-floating-item.md +53 -0
- package/llms/components/obc-alert-frame.md +142 -0
- package/llms/components/obc-alert-icon.md +79 -0
- package/llms/components/obc-alert-list-details-experimental.md +89 -0
- package/llms/components/obc-alert-list-details.md +38 -0
- package/llms/components/obc-alert-list-page-small.md +39 -0
- package/llms/components/obc-alert-list.md +37 -0
- package/llms/components/obc-alert-menu-item.md +128 -0
- package/llms/components/obc-alert-menu.md +115 -0
- package/llms/components/obc-alert-subsystem-button.md +88 -0
- package/llms/components/obc-alert-subsystem-counter.md +110 -0
- package/llms/components/obc-analog-threeway-valve.md +106 -0
- package/llms/components/obc-analog-valve.md +74 -0
- package/llms/components/obc-app-button.md +83 -0
- package/llms/components/obc-app-menu.md +69 -0
- package/llms/components/obc-area-graph.md +333 -0
- package/llms/components/obc-attachment-list-item.md +49 -0
- package/llms/components/obc-audio-output.md +59 -0
- package/llms/components/obc-audio-recording-item.md +91 -0
- package/llms/components/obc-automation-badge.md +66 -0
- package/llms/components/obc-automation-button-readout-stack.md +71 -0
- package/llms/components/obc-automation-button.md +86 -0
- package/llms/components/obc-automation-input-modal.md +48 -0
- package/llms/components/obc-automation-readout.md +32 -0
- package/llms/components/obc-automation-tank.md +156 -0
- package/llms/components/obc-azimuth-thruster-labeled.md +56 -0
- package/llms/components/obc-azimuth-thruster.md +80 -0
- package/llms/components/obc-badge-command.md +26 -0
- package/llms/components/obc-badge.md +151 -0
- package/llms/components/obc-bar-horizontal.md +123 -0
- package/llms/components/obc-bar-vertical.md +125 -0
- package/llms/components/obc-battery-icon.md +38 -0
- package/llms/components/obc-bearing-indicator.md +27 -0
- package/llms/components/obc-bipolar-transistor.md +64 -0
- package/llms/components/obc-breadcrumb.md +58 -0
- package/llms/components/obc-brilliance-menu.md +115 -0
- package/llms/components/obc-bus.md +64 -0
- package/llms/components/obc-button.md +110 -0
- package/llms/components/obc-calendar.md +91 -0
- package/llms/components/obc-capacitor.md +64 -0
- package/llms/components/obc-card.md +103 -0
- package/llms/components/obc-chart-object-vessel-button.md +103 -0
- package/llms/components/obc-chat-message.md +35 -0
- package/llms/components/obc-check-button.md +104 -0
- package/llms/components/obc-checkbox-item.md +95 -0
- package/llms/components/obc-checkbox-list.md +73 -0
- package/llms/components/obc-checkbox.md +97 -0
- package/llms/components/obc-circular-progress.md +36 -0
- package/llms/components/obc-clock.md +86 -0
- package/llms/components/obc-command-button.md +56 -0
- package/llms/components/obc-command-menu.md +135 -0
- package/llms/components/obc-communication-table.md +31 -0
- package/llms/components/obc-compass-flat.md +79 -0
- package/llms/components/obc-compass-indicator.md +61 -0
- package/llms/components/obc-compass-sector.md +110 -0
- package/llms/components/obc-compass.md +157 -0
- package/llms/components/obc-context-menu-input.md +191 -0
- package/llms/components/obc-converter.md +64 -0
- package/llms/components/obc-corner-line.md +29 -0
- package/llms/components/obc-current.md +79 -0
- package/llms/components/obc-damper.md +62 -0
- package/llms/components/obc-date-item.md +66 -0
- package/llms/components/obc-depth-actual.md +69 -0
- package/llms/components/obc-depth-indicator.md +31 -0
- package/llms/components/obc-depth-top-band.md +43 -0
- package/llms/components/obc-depth.md +94 -0
- package/llms/components/obc-diagnostic-button.md +71 -0
- package/llms/components/obc-diagnostic-menu.md +88 -0
- package/llms/components/obc-digital-threeway-valve.md +112 -0
- package/llms/components/obc-digital-valve.md +78 -0
- package/llms/components/obc-diodes.md +64 -0
- package/llms/components/obc-direction-line.md +28 -0
- package/llms/components/obc-divider.md +44 -0
- package/llms/components/obc-donut-chart.md +116 -0
- package/llms/components/obc-draft-trim.md +67 -0
- package/llms/components/obc-dropdown-button.md +99 -0
- package/llms/components/obc-electricity-battery.md +83 -0
- package/llms/components/obc-elevated-card-radio-group.md +103 -0
- package/llms/components/obc-elevated-card-radio.md +104 -0
- package/llms/components/obc-elevated-card.md +146 -0
- package/llms/components/obc-end-point-line.md +29 -0
- package/llms/components/obc-event-item.md +47 -0
- package/llms/components/obc-event-list.md +37 -0
- package/llms/components/obc-fan.md +68 -0
- package/llms/components/obc-filter-chip.md +91 -0
- package/llms/components/obc-filter.md +64 -0
- package/llms/components/obc-floating-item.md +125 -0
- package/llms/components/obc-form-container.md +45 -0
- package/llms/components/obc-form-footer-container.md +34 -0
- package/llms/components/obc-form-group.md +80 -0
- package/llms/components/obc-form-item.md +95 -0
- package/llms/components/obc-gauge-bar-indicator.md +46 -0
- package/llms/components/obc-gauge-generator.md +102 -0
- package/llms/components/obc-gauge-horizontal.md +169 -0
- package/llms/components/obc-gauge-motors-and-pumps.md +110 -0
- package/llms/components/obc-gauge-proportional.md +134 -0
- package/llms/components/obc-gauge-radial-indicator.md +76 -0
- package/llms/components/obc-gauge-radial.md +163 -0
- package/llms/components/obc-gauge-trend-indicator.md +53 -0
- package/llms/components/obc-gauge-trend.md +271 -0
- package/llms/components/obc-gauge-valve.md +114 -0
- package/llms/components/obc-gauge-vertical.md +169 -0
- package/llms/components/obc-gnss-skyplot.md +80 -0
- package/llms/components/obc-graph-mini.md +28 -0
- package/llms/components/obc-ground.md +64 -0
- package/llms/components/obc-heading-indicator.md +42 -0
- package/llms/components/obc-heading.md +106 -0
- package/llms/components/obc-heat-exchanger.md +80 -0
- package/llms/components/obc-heat-pump.md +79 -0
- package/llms/components/obc-heave-indicator.md +38 -0
- package/llms/components/obc-heave.md +60 -0
- package/llms/components/obc-horizontal-line.md +29 -0
- package/llms/components/obc-hydraulic-check-valve.md +36 -0
- package/llms/components/obc-hydraulic-separator.md +80 -0
- package/llms/components/obc-hydraulic-valve-4-3.md +71 -0
- package/llms/components/obc-hydraulic-valve-x-2.md +68 -0
- package/llms/components/obc-icon-button.md +117 -0
- package/llms/components/obc-icon-check-button.md +85 -0
- package/llms/components/obc-indicator-battery.md +69 -0
- package/llms/components/obc-indicator-engine.md +39 -0
- package/llms/components/obc-indicator-generator.md +59 -0
- package/llms/components/obc-indicator-graph.md +33 -0
- package/llms/components/obc-indicator-tank-atmospheric.md +69 -0
- package/llms/components/obc-input-chip.md +96 -0
- package/llms/components/obc-instrument-field.md +172 -0
- package/llms/components/obc-instrument-radial.md +77 -0
- package/llms/components/obc-integration-app-bar.md +41 -0
- package/llms/components/obc-integration-bar-dropdown.md +71 -0
- package/llms/components/obc-integration-bar.md +72 -0
- package/llms/components/obc-integration-button.md +62 -0
- package/llms/components/obc-integration-dropdown-button.md +75 -0
- package/llms/components/obc-integration-fleet-button.md +41 -0
- package/llms/components/obc-integration-tabs.md +28 -0
- package/llms/components/obc-integration-vessel-menu.md +58 -0
- package/llms/components/obc-integration-vessel-selector.md +32 -0
- package/llms/components/obc-keyboard-full.md +175 -0
- package/llms/components/obc-keyboard-numeric.md +77 -0
- package/llms/components/obc-line-cross.md +28 -0
- package/llms/components/obc-line-graph.md +164 -0
- package/llms/components/obc-line-overlap.md +28 -0
- package/llms/components/obc-logic.md +64 -0
- package/llms/components/obc-main-engine-indicator.md +55 -0
- package/llms/components/obc-main-engine.md +54 -0
- package/llms/components/obc-menu-button.md +158 -0
- package/llms/components/obc-message-menu-item.md +165 -0
- package/llms/components/obc-modal-window.md +139 -0
- package/llms/components/obc-mosfet.md +64 -0
- package/llms/components/obc-motor.md +73 -0
- package/llms/components/obc-navigation-item-group.md +82 -0
- package/llms/components/obc-navigation-item.md +138 -0
- package/llms/components/obc-navigation-menu.md +135 -0
- package/llms/components/obc-non-return-valve.md +79 -0
- package/llms/components/obc-notification-badge-button.md +87 -0
- package/llms/components/obc-notification-button.md +92 -0
- package/llms/components/obc-notification-floating-item.md +121 -0
- package/llms/components/obc-notification-menu-item.md +87 -0
- package/llms/components/obc-notification-message-item.md +127 -0
- package/llms/components/obc-number-input-field.md +97 -0
- package/llms/components/obc-pagination.md +95 -0
- package/llms/components/obc-pie-chart.md +120 -0
- package/llms/components/obc-pitch-indicator.md +39 -0
- package/llms/components/obc-pitch-roll-heave.md +86 -0
- package/llms/components/obc-pitch-roll-yaw.md +72 -0
- package/llms/components/obc-pitch-roll.md +63 -0
- package/llms/components/obc-pitch.md +81 -0
- package/llms/components/obc-pivot-item-group.md +79 -0
- package/llms/components/obc-pivot-item.md +75 -0
- package/llms/components/obc-poi-aton.md +68 -0
- package/llms/components/obc-poi-button-aton.md +54 -0
- package/llms/components/obc-poi-button-data.md +53 -0
- package/llms/components/obc-poi-button-vessel.md +55 -0
- package/llms/components/obc-poi-button.md +94 -0
- package/llms/components/obc-poi-card-header.md +90 -0
- package/llms/components/obc-poi-card.md +110 -0
- package/llms/components/obc-poi-controller.md +151 -0
- package/llms/components/obc-poi-data.md +72 -0
- package/llms/components/obc-poi-graphic-line.md +70 -0
- package/llms/components/obc-poi-group.md +85 -0
- package/llms/components/obc-poi-header.md +71 -0
- package/llms/components/obc-poi-layer-stack.md +85 -0
- package/llms/components/obc-poi-layer.md +110 -0
- package/llms/components/obc-poi-line.md +70 -0
- package/llms/components/obc-poi-object-aton.md +45 -0
- package/llms/components/obc-poi-object-data.md +48 -0
- package/llms/components/obc-poi-object-vessel.md +95 -0
- package/llms/components/obc-poi-object.md +82 -0
- package/llms/components/obc-poi-pointer.md +70 -0
- package/llms/components/obc-poi-selection-frame.md +66 -0
- package/llms/components/obc-poi-vessel.md +70 -0
- package/llms/components/obc-poi.md +140 -0
- package/llms/components/obc-polar-chart.md +126 -0
- package/llms/components/obc-position-deviation.md +84 -0
- package/llms/components/obc-pressure-reduction-valve.md +88 -0
- package/llms/components/obc-pressure-sustain-valve.md +85 -0
- package/llms/components/obc-progress-bar.md +102 -0
- package/llms/components/obc-progress-button.md +111 -0
- package/llms/components/obc-progress-indicator-dots.md +57 -0
- package/llms/components/obc-propulsion-azimuth-indicator.md +48 -0
- package/llms/components/obc-pump.md +76 -0
- package/llms/components/obc-radial-bar-chart.md +103 -0
- package/llms/components/obc-radio.md +82 -0
- package/llms/components/obc-rate-of-turn.md +95 -0
- package/llms/components/obc-readout-block.md +137 -0
- package/llms/components/obc-readout-list-item.md +142 -0
- package/llms/components/obc-readout-list.md +85 -0
- package/llms/components/obc-readout.md +169 -0
- package/llms/components/obc-resistor.md +64 -0
- package/llms/components/obc-rich-button.md +92 -0
- package/llms/components/obc-roll-indicator.md +38 -0
- package/llms/components/obc-roll.md +56 -0
- package/llms/components/obc-rot-indicator.md +32 -0
- package/llms/components/obc-rot-linear.md +68 -0
- package/llms/components/obc-rot-sector.md +125 -0
- package/llms/components/obc-router.md +64 -0
- package/llms/components/obc-rudder-indicator.md +54 -0
- package/llms/components/obc-rudder.md +112 -0
- package/llms/components/obc-ruler-pointer.md +57 -0
- package/llms/components/obc-scrollbar.md +57 -0
- package/llms/components/obc-sequence-card.md +119 -0
- package/llms/components/obc-sequence-connector.md +70 -0
- package/llms/components/obc-sequence-item.md +64 -0
- package/llms/components/obc-sequence-loading-spinner.md +70 -0
- package/llms/components/obc-sequence-modal.md +89 -0
- package/llms/components/obc-sequence-step.md +48 -0
- package/llms/components/obc-sequence-toolbar.md +108 -0
- package/llms/components/obc-slide-button.md +111 -0
- package/llms/components/obc-slider-double.md +137 -0
- package/llms/components/obc-slider.md +143 -0
- package/llms/components/obc-source.md +64 -0
- package/llms/components/obc-speed-arrows.md +39 -0
- package/llms/components/obc-speed-directions.md +66 -0
- package/llms/components/obc-speed-gauge.md +124 -0
- package/llms/components/obc-speed-indicator.md +37 -0
- package/llms/components/obc-split-button.md +144 -0
- package/llms/components/obc-start-stop-switch.md +126 -0
- package/llms/components/obc-status-indicator.md +30 -0
- package/llms/components/obc-stepper-box.md +90 -0
- package/llms/components/obc-surge-sway-yaw.md +95 -0
- package/llms/components/obc-switch.md +69 -0
- package/llms/components/obc-system-button.md +112 -0
- package/llms/components/obc-system-menu.md +67 -0
- package/llms/components/obc-tab-item.md +161 -0
- package/llms/components/obc-tab-row.md +151 -0
- package/llms/components/obc-tabbed-card.md +148 -0
- package/llms/components/obc-table-header-item.md +42 -0
- package/llms/components/obc-table.md +124 -0
- package/llms/components/obc-tag.md +41 -0
- package/llms/components/obc-text-input-field.md +94 -0
- package/llms/components/obc-textarea-field.md +186 -0
- package/llms/components/obc-textbox.md +80 -0
- package/llms/components/obc-three-way-line.md +29 -0
- package/llms/components/obc-thruster.md +64 -0
- package/llms/components/obc-title-container.md +81 -0
- package/llms/components/obc-toggle-button-group.md +184 -0
- package/llms/components/obc-toggle-button-option.md +126 -0
- package/llms/components/obc-toggle-button-three-state.md +38 -0
- package/llms/components/obc-toggle-button-vertical-group.md +142 -0
- package/llms/components/obc-toggle-button-vertical-option.md +110 -0
- package/llms/components/obc-toggle-switch.md +126 -0
- package/llms/components/obc-toggletip.md +135 -0
- package/llms/components/obc-tooltip.md +106 -0
- package/llms/components/obc-top-bar.md +194 -0
- package/llms/components/obc-top-view-propulsion.md +84 -0
- package/llms/components/obc-topbar-message-item.md +150 -0
- package/llms/components/obc-transformer.md +64 -0
- package/llms/components/obc-transmitter-button.md +101 -0
- package/llms/components/obc-transmitter-stack.md +79 -0
- package/llms/components/obc-transmitter.md +114 -0
- package/llms/components/obc-tree-navigation-group.md +69 -0
- package/llms/components/obc-tree-navigation-item.md +110 -0
- package/llms/components/obc-tree-navigation.md +73 -0
- package/llms/components/obc-tunnel-thruster.md +59 -0
- package/llms/components/obc-user-button.md +107 -0
- package/llms/components/obc-user-menu.md +154 -0
- package/llms/components/obc-valve-analog-three-way-icon.md +69 -0
- package/llms/components/obc-valve-analog-two-way-icon.md +39 -0
- package/llms/components/obc-velocity-projection-plot.md +34 -0
- package/llms/components/obc-vendor-button.md +63 -0
- package/llms/components/obc-vertical-line.md +33 -0
- package/llms/components/obc-watch-flat.md +54 -0
- package/llms/components/obc-watch.md +206 -0
- package/llms/components/obc-wind-indicator.md +52 -0
- package/llms/components/obc-wind-propulsion.md +92 -0
- package/llms/components/obc-wind.md +46 -0
- package/llms/docs/ar-poi-projection.md +36 -0
- package/llms/docs/automation-sequence-step-diagram-playground.md +13 -0
- package/llms/docs/building-blocks-advice.md +31 -0
- package/llms/docs/building-blocks-external-scale.md +138 -0
- package/llms/docs/building-blocks-setpoint.md +119 -0
- package/llms/docs/introduction-advice-system.md +161 -0
- package/llms/docs/introduction-getting-started.md +94 -0
- package/llms/docs/introduction-introduction.md +27 -0
- package/llms/docs/introduction-join-the-project.md +11 -0
- package/llms/docs/introduction-migration-guide-2-0-to-2-1.md +126 -0
- package/llms/docs/introduction-migration-guide-2-1-to-2-2.md +106 -0
- package/llms/docs/introduction-migration-guide.md +1063 -0
- package/llms/docs/palettes-categorical-colour.md +9 -0
- package/llms/llms-full.txt +28380 -0
- package/llms/llms.txt +368 -0
- package/package.json +12 -2
- package/script/cem-plugins/lifecycle.d.mts +6 -0
- package/script/cem-plugins/lifecycle.mjs +48 -0
- package/script/cem-plugins.test.ts +52 -1
- package/script/generate-llms-txt.ts +34 -0
- package/script/llms/channel.test.ts +69 -0
- package/script/llms/channel.ts +63 -0
- package/script/llms/generate.test.ts +143 -0
- package/script/llms/generate.ts +229 -0
- package/script/llms/manifest.test.ts +160 -0
- package/script/llms/manifest.ts +109 -0
- package/script/llms/markdown.test.ts +22 -0
- package/script/llms/markdown.ts +37 -0
- package/script/llms/mdx.test.ts +172 -0
- package/script/llms/mdx.ts +171 -0
- package/script/llms/render-component.test.ts +290 -0
- package/script/llms/render-component.ts +208 -0
- package/script/llms/render-guides.test.ts +105 -0
- package/script/llms/render-guides.ts +51 -0
- package/script/llms/render-llms-txt.test.ts +222 -0
- package/script/llms/render-llms-txt.ts +185 -0
- package/script/llms/sources.test.ts +118 -0
- package/script/llms/sources.ts +89 -0
- package/script/llms/stories.test.ts +193 -0
- package/script/llms/stories.ts +256 -0
- package/script/llms/types.ts +95 -0
- package/script/prepare-full-bundle.ts +1 -0
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
# `<obc-topbar-message-item>`
|
|
2
|
+
|
|
3
|
+
A compact, horizontally-aligned message bar for displaying status updates, alerts, or actionable notifications in a top bar or summary area.
|
|
4
|
+
|
|
5
|
+
Lifecycle: stable. [Storybook](https://openbridge-next-storybook.web.app/?path=/docs/ui-components-message-and-alerts-topbar-message-item--docs) · [Source](https://raw.githubusercontent.com/Ocean-Industries-Concept-Lab/openbridge-webcomponents/develop/packages/openbridge-webcomponents/src/components/topbar-message-item/topbar-message-item.ts)
|
|
6
|
+
|
|
7
|
+
`<obc-topbar-message-item>` – A compact, horizontally-aligned message bar for displaying status updates, alerts, or actionable notifications in a top bar or summary area.
|
|
8
|
+
|
|
9
|
+
This component presents a message with optional icons, title, description, timestamps, and action buttons. It is designed for quick scanning and interaction, supporting both text and icon actions. The layout adapts for regular or tall display, and can show an inactive/empty state when no messages are present.
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
## Features
|
|
14
|
+
- **Type Variants:**
|
|
15
|
+
- `simple`: Displays only the message content (title, description, icons, timestamps) with no action button.
|
|
16
|
+
- `with-button`: Adds a text-based action button for user interaction.
|
|
17
|
+
- `with-icon-button`: Adds an icon-based action button for compact actions.
|
|
18
|
+
- `inactive`: Shows an empty/inactive state, typically used when there are no messages to display.
|
|
19
|
+
- **Size Options:**
|
|
20
|
+
- `regular`: Standard compact height.
|
|
21
|
+
- `tall`: Expanded height for more content or emphasis.
|
|
22
|
+
- **Content Structure:**
|
|
23
|
+
- Supports primary and secondary icons, title, description, and up to two timestamps.
|
|
24
|
+
- Action area can be a text button, icon button, or omitted.
|
|
25
|
+
- **State Flags:**
|
|
26
|
+
- Show/hide title, description, primary/secondary timestamps, and secondary icon via boolean properties.
|
|
27
|
+
- Inactive/empty state can be triggered via the `type="inactive"` or `empty` property.
|
|
28
|
+
- **Responsive Layout:**
|
|
29
|
+
- Adapts spacing and alignment for regular vs. tall size.
|
|
30
|
+
- Truncates long titles/descriptions to fit available space.
|
|
31
|
+
- **Interactive Elements:**
|
|
32
|
+
- Clickable message area (`message-click` event).
|
|
33
|
+
- Action button (text or icon) triggers `action-click` event.
|
|
34
|
+
|
|
35
|
+
---
|
|
36
|
+
|
|
37
|
+
## Usage Guidelines
|
|
38
|
+
Use `<obc-topbar-message-item>` to display concise status updates, alerts, or actionable notifications in a top bar, summary list, or notification center. It is ideal for presenting information that may require quick acknowledgment or action, such as system alerts, status changes, or reminders.
|
|
39
|
+
|
|
40
|
+
- Use the `with-button` or `with-icon-button` types when an immediate action is available (e.g., "Acknowledge", "Open", or a quick icon action).
|
|
41
|
+
- Use the `simple` type for informational messages that do not require user action.
|
|
42
|
+
- Use the `inactive` type (or set `empty=true`) to indicate there are no current messages.
|
|
43
|
+
- For longer messages or additional context, use the `tall` size to provide more space for content.
|
|
44
|
+
- Avoid overloading the message item with excessive text; keep titles and descriptions concise for quick scanning.
|
|
45
|
+
- For persistent or multi-line alerts, consider using a banner or dialog component instead.
|
|
46
|
+
|
|
47
|
+
---
|
|
48
|
+
|
|
49
|
+
## Slots
|
|
50
|
+
| Slot Name | Renders When... | Purpose |
|
|
51
|
+
|-------------------|------------------------------------------------|--------------------------------------------------------------|
|
|
52
|
+
| primary-icon | Always (except inactive) | Main icon representing the message type or status |
|
|
53
|
+
| secondary-icon | If `hasSecondaryIcon` is true | Additional icon for context or severity |
|
|
54
|
+
| title | If `showTitle` is true | Title or heading of the message |
|
|
55
|
+
| description | If `showDescription` is true | Detailed message text |
|
|
56
|
+
| time | If `showTimestamp` is true | Primary timestamp (e.g., time of event) |
|
|
57
|
+
| time-secondary | If `hasTimestamp2` is true | Secondary timestamp (e.g., duration, relative time) |
|
|
58
|
+
| action-text | If type is `with-button` | Label/content for the text action button |
|
|
59
|
+
| action-icon | If type is `with-icon-button` | Icon for the icon action button |
|
|
60
|
+
| empty | If type is `inactive` or `empty` is true | Content for the empty/inactive state |
|
|
61
|
+
|
|
62
|
+
---
|
|
63
|
+
|
|
64
|
+
## Events
|
|
65
|
+
- `message-click` – Fired when the main message area is clicked.
|
|
66
|
+
- `action-click` – Fired when the action button (text or icon) is clicked.
|
|
67
|
+
|
|
68
|
+
---
|
|
69
|
+
|
|
70
|
+
## Best Practices & Constraints
|
|
71
|
+
- Only one action button (text or icon) should be used at a time to keep interactions simple.
|
|
72
|
+
- Use the `inactive` type or `empty=true` to clearly indicate when there are no messages.
|
|
73
|
+
- For accessibility, give action buttons clear labels or icons.
|
|
74
|
+
- Truncation is applied to long titles and descriptions; keep content concise for best results.
|
|
75
|
+
- Deprecated properties: Prefer using `type` and `size` over `large` and `empty`.
|
|
76
|
+
|
|
77
|
+
---
|
|
78
|
+
|
|
79
|
+
**Example:**
|
|
80
|
+
```html
|
|
81
|
+
<obc-topbar-message-item type="with-button" size="regular">
|
|
82
|
+
<obi-placeholder slot="primary-icon"></obi-placeholder>
|
|
83
|
+
<obi-placeholder slot="secondary-icon"></obi-placeholder>
|
|
84
|
+
<span slot="title">System Update</span>
|
|
85
|
+
<span slot="description">Update completed successfully.</span>
|
|
86
|
+
<span slot="time">09:12:46</span>
|
|
87
|
+
<span slot="action-text">View</span>
|
|
88
|
+
</obc-topbar-message-item>
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
## Properties
|
|
92
|
+
|
|
93
|
+
| Property | Attribute | Type | Default | Description |
|
|
94
|
+
| --- | --- | --- | --- | --- |
|
|
95
|
+
| type | type | `ObcTopbarMessageItemType` | | Visual and interactive type: `simple` is message content alone, `with-button` (default) adds a text action button, `with-icon-button` an icon action button, and `inactive` shows the empty state. |
|
|
96
|
+
| size | size | `ObcTopbarMessageItemSize` | | Vertical size: `regular` (default) is the compact height, `tall` the expanded one. |
|
|
97
|
+
| showTitle | | `boolean` | `true` | Whether to show the title slot. Available when `type!=Inactive`. |
|
|
98
|
+
| showDescription | | `boolean` | `true` | Whether to show the description slot. Available when `type!=Inactive`. |
|
|
99
|
+
| showTimestamp | | `boolean` | `true` | Whether to show the primary timestamp slot. Available when `type!=Inactive`. |
|
|
100
|
+
| actionLabel | actionLabel | `string` | `''` | Accessible name of the icon action button (`with-icon-button`); the slotted icon carries none. |
|
|
101
|
+
| hasTimestamp2 | hasTimestamp2 | `boolean` | `false` | Whether to display the secondary timestamp slot. Available when `type!=Inactive`. |
|
|
102
|
+
| hasSecondaryIcon | hasSecondaryIcon | `boolean` | `false` | Whether to display the secondary icon slot. Available when `type!=Inactive`. |
|
|
103
|
+
|
|
104
|
+
## Events
|
|
105
|
+
|
|
106
|
+
| Event | Type | Description |
|
|
107
|
+
| --- | --- | --- |
|
|
108
|
+
| message-click | `CustomEvent<void>` | Fired when the main message area is clicked. |
|
|
109
|
+
| action-click | `CustomEvent<void>` | Fired when the action button (text or icon) is clicked. |
|
|
110
|
+
|
|
111
|
+
## Slots
|
|
112
|
+
|
|
113
|
+
| Slot | Description |
|
|
114
|
+
| --- | --- |
|
|
115
|
+
| primary-icon | Main icon representing the message type or status. |
|
|
116
|
+
| secondary-icon | Additional icon for context or severity (shown if `hasSecondaryIcon` is true). |
|
|
117
|
+
| title | Title or heading of the message (shown if `showTitle` is true). |
|
|
118
|
+
| description | Detailed message text (shown if `showDescription` is true). |
|
|
119
|
+
| time | Primary timestamp (shown if `showTimestamp` is true). |
|
|
120
|
+
| time-secondary | Secondary timestamp (shown if `hasTimestamp2` is true). |
|
|
121
|
+
| action-text | Content for the text action button (shown if type is `with-button`). |
|
|
122
|
+
| action-icon | Icon for the icon action button (shown if type is `with-icon-button`). |
|
|
123
|
+
| empty | Content for the empty/inactive state (shown if type is `inactive` or `empty` is true). |
|
|
124
|
+
|
|
125
|
+
## Stories
|
|
126
|
+
|
|
127
|
+
- [Text Action](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--text-action)
|
|
128
|
+
- [Short Text](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--short-text)
|
|
129
|
+
- [Very Long Title Text](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--very-long-title-text)
|
|
130
|
+
- [Icon Action](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--icon-action)
|
|
131
|
+
- [No Action](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--no-action)
|
|
132
|
+
- [Empty](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--empty)
|
|
133
|
+
- [Text Action Large](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--text-action-large)
|
|
134
|
+
- [Icon Action Large](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--icon-action-large)
|
|
135
|
+
- [Large With Long Text And Description](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--large-with-long-text-and-description)
|
|
136
|
+
- [Large With Long Text And Description And Both Timestamps](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--large-with-long-text-and-description-and-both-timestamps)
|
|
137
|
+
- [No Action Large](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--no-action-large)
|
|
138
|
+
- [Empty Large](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--empty-large)
|
|
139
|
+
- [No Title](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--no-title)
|
|
140
|
+
- [No Description](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--no-description)
|
|
141
|
+
- [No Timestamp](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--no-timestamp)
|
|
142
|
+
- [Secondary Timestamp](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--secondary-timestamp)
|
|
143
|
+
- [Both Timestamps](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--both-timestamps)
|
|
144
|
+
- [No Secondary Icon](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--no-secondary-icon)
|
|
145
|
+
- [Minimal Message](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--minimal-message)
|
|
146
|
+
- [Interactive Example](https://openbridge-next-storybook.web.app/?path=/story/ui-components-message-and-alerts-topbar-message-item--interactive-example)
|
|
147
|
+
|
|
148
|
+
## See also
|
|
149
|
+
|
|
150
|
+
- [Migration Guide](https://openbridge-next-storybook.web.app/docs/introduction-migration-guide.md)
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
# `<obc-transformer>`
|
|
2
|
+
|
|
3
|
+
No summary yet.
|
|
4
|
+
|
|
5
|
+
Lifecycle: stable. [Storybook](https://openbridge-next-storybook.web.app/?path=/docs/automation-automation-devices-transformer--docs) · [Source](https://raw.githubusercontent.com/Ocean-Industries-Concept-Lab/openbridge-webcomponents/develop/packages/openbridge-webcomponents/src/automation/transformer/transformer.ts)
|
|
6
|
+
|
|
7
|
+
## Properties
|
|
8
|
+
|
|
9
|
+
| Property | Attribute | Type | Default | Description |
|
|
10
|
+
| --- | --- | --- | --- | --- |
|
|
11
|
+
| alternativeIcon | alternativeIcon | `TransformerAlternativeIcon` | | |
|
|
12
|
+
| icon | | `TemplateResult` | | |
|
|
13
|
+
| turnedOn | turnedOn | `boolean` | `false` | Whether the device is on. Selects the on icon and the `On` state row instead of `Off`. Not named `on`, which Svelte binds as an event listener in markup (#1090). |
|
|
14
|
+
| on | on | `boolean \| undefined` | | Alias of `turnedOn` for 1.x markup: setting it sets `turnedOn`. |
|
|
15
|
+
| variant | variant | `SquaredVariant` | | |
|
|
16
|
+
| orientation | orientation | `AutomationButtonOrientation` | | |
|
|
17
|
+
| extraReadouts | | `AutomationButtonReadoutStack[]` | | |
|
|
18
|
+
| showReadoutStack | | `boolean` | `true` | |
|
|
19
|
+
| static | static | `boolean` | `false` | Draws the device as present with its state unknown: a grey button, and the static icon where the device has one. |
|
|
20
|
+
| readoutPosition | readoutPosition | `AutomationButtonReadoutPosition \| undefined` | `undefined` | Available when `showReadoutStack==true`. |
|
|
21
|
+
| showStatus | | `boolean` | `true` | Available when `showReadoutStack==true`. |
|
|
22
|
+
| showStatusIcon | | `boolean` | `false` | |
|
|
23
|
+
| readoutSize | readoutSize | `AutomationButtonReadoutStackSize` | | Available when `showReadoutStack==true`. |
|
|
24
|
+
| tag | tag | `string \| null` | `null` | Available when `showReadoutStack==true`. |
|
|
25
|
+
| positioning | positioning | `AutomationButtonPositioning` | | |
|
|
26
|
+
| activated | activated | `boolean` | `false` | Enables the activated background color, used to indicate that the button is activated/selected. |
|
|
27
|
+
| alert | alert | `boolean` | `false` | |
|
|
28
|
+
| alertFrameType | alertFrameType | `ObcAlertFrameType` | | Available when `alert==true`. |
|
|
29
|
+
| alertFrameThickness | alertFrameThickness | `ObcAlertFrameThickness` | | Available when `alert==true`. |
|
|
30
|
+
| alertFrameStatus | alertFrameStatus | `AlertType` | | Available when `alert==true`. |
|
|
31
|
+
| alertFrameMode | alertFrameMode | `ObcAlertFrameMode` | | Available when `alert==true`. |
|
|
32
|
+
| showAlertCategoryIcon | | `boolean` | `true` | Available when `alert==true && alertFrameType in [SmallSideFlip, LargeSideFlip, BottomFlip, TopFlip]`. |
|
|
33
|
+
| showAlertIcon | showAlertIcon | `boolean` | `false` | Available when `alert==true && alertFrameType in [LargeSideFlip, BottomFlip, TopFlip]`. |
|
|
34
|
+
| progress | progress | `boolean` | `false` | Shows a progress indicator, used to indicate that an user action is in progress |
|
|
35
|
+
| progressMode | progressMode | `CircularProgressMode` | | Available when `progress==true`. |
|
|
36
|
+
| progressValue | progressValue | `number` | `0` | Available when `progress==true && progressMode in [determinate, progressiveIndeterminate]`. |
|
|
37
|
+
| badgeControl | badgeControl | `AutomationButtonBadgeControl` | | |
|
|
38
|
+
| badgeCommandLocked | badgeCommandLocked | `AutomationButtonBadgeCommandLocked` | | |
|
|
39
|
+
| badgeInterlock | badgeInterlock | `AutomationButtonBadgeInterlock` | | |
|
|
40
|
+
| badgeAlert | badgeAlert | `AutomationButtonBadgeAlert` | | |
|
|
41
|
+
| badgeLayout | | `AutomationButtonBadgeLayout \| undefined` | `undefined` | Which badge kind each corner shows, on top of the app-wide layout set with `setAutomationBadgeLayout()`. A corner left out keeps the app-wide badge, `null` leaves it empty, and a badge moved here leaves the corner it came from. |
|
|
42
|
+
| badgeSymbolOverride | | `AutomationBadgeSymbolOverride \| undefined` | `undefined` | Letters that replace badge symbols on this device, per badge property and value, on top of the app-wide ones set with `setAutomationBadgeSymbolOverride()`; for example `{commandLocked: {simulation: 's'}}`. `null` brings the symbol back. |
|
|
43
|
+
| badgeTopRight | | `HTMLElement[]` | | |
|
|
44
|
+
| badgeTopLeft | | `HTMLElement[]` | | |
|
|
45
|
+
| badgeBottomLeft | | `HTMLElement[]` | | |
|
|
46
|
+
| badgeBottomRight | | `HTMLElement[]` | | |
|
|
47
|
+
|
|
48
|
+
## Events
|
|
49
|
+
|
|
50
|
+
None.
|
|
51
|
+
|
|
52
|
+
## Slots
|
|
53
|
+
|
|
54
|
+
None.
|
|
55
|
+
|
|
56
|
+
## Stories
|
|
57
|
+
|
|
58
|
+
- [On](https://openbridge-next-storybook.web.app/?path=/story/automation-automation-devices-transformer--on)
|
|
59
|
+
- [Off](https://openbridge-next-storybook.web.app/?path=/story/automation-automation-devices-transformer--off)
|
|
60
|
+
- [Static](https://openbridge-next-storybook.web.app/?path=/story/automation-automation-devices-transformer--static)
|
|
61
|
+
|
|
62
|
+
## See also
|
|
63
|
+
|
|
64
|
+
- [Migration Guide](https://openbridge-next-storybook.web.app/docs/introduction-migration-guide.md)
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
# `<obc-transmitter-button>`
|
|
2
|
+
|
|
3
|
+
The pressable readout chip at the core of a transmitter: a bordered button around one reading.
|
|
4
|
+
|
|
5
|
+
Lifecycle: experimental. [Storybook](https://openbridge-next-storybook.web.app/?path=/docs/automation-transmitter-transmitter-button--docs) · [Source](https://raw.githubusercontent.com/Ocean-Industries-Concept-Lab/openbridge-webcomponents/develop/packages/openbridge-webcomponents/src/automation/transmitter-button/transmitter-button.ts)
|
|
6
|
+
|
|
7
|
+
`<obc-transmitter-button>` – The pressable readout chip at the core of a
|
|
8
|
+
transmitter: a bordered button around one reading.
|
|
9
|
+
|
|
10
|
+
The reading is a label-less `<obc-readout-list-item>` (the Figma "automation
|
|
11
|
+
value"): leading icon, optional advice and setpoint, value, optional degree
|
|
12
|
+
and unit, all rendered by the readout family. The leading icon is slotted so
|
|
13
|
+
the consumer provides the type-specific content.
|
|
14
|
+
|
|
15
|
+
## Features / Variants
|
|
16
|
+
- **`value`** – bordered chip showing an icon, value and unit. Opt into a
|
|
17
|
+
leading advice segment with `hasAdvice`/`adviceValue`, a setpoint segment
|
|
18
|
+
with `hasSetPoint`/`setpointValue`, and a degree column before the unit
|
|
19
|
+
with `hasDegree`.
|
|
20
|
+
- **`tag`** – a static rounded pill showing a short identifier (e.g. `TT`)
|
|
21
|
+
from the `label` property, with no live value.
|
|
22
|
+
- **`size`** – `regular`, `medium` or `large`, the list item's `small`,
|
|
23
|
+
`medium` and `large` tiers: the value text, the icon and the advice/setpoint
|
|
24
|
+
segments scale, the unit stays extra small.
|
|
25
|
+
- **Formatting** – `fractionDigits` sets the decimal precision, `maxDigits`
|
|
26
|
+
reserves a number of integer digits, and `hintedZeros` renders the reserved
|
|
27
|
+
leading positions as muted zeros (e.g. `0012.3`). The sign never consumes
|
|
28
|
+
a reserved position (`-0012.3`), so a negative value is one character
|
|
29
|
+
wider than a positive one; `hasSignSpacer` reserves the sign column so
|
|
30
|
+
the width does not change across zero. All three segments share this
|
|
31
|
+
formatting — it is `obc-readout-block`'s.
|
|
32
|
+
- **Missing values** – `value`, `adviceValue` and `setpointValue` each render
|
|
33
|
+
dashes when they are `NaN`, `null` or `undefined`; with `hintedZeros` the
|
|
34
|
+
dashes fill the whole reserved width (e.g. `---.-`).
|
|
35
|
+
|
|
36
|
+
## Usage Guidelines
|
|
37
|
+
Use as a building block for `<obc-transmitter>` and `<obc-transmitter-stack>`;
|
|
38
|
+
it is the part that carries the measured value or the tag identifier. Slot in
|
|
39
|
+
the type-specific icon; the advice and setpoint segments are value-driven and
|
|
40
|
+
read-only.
|
|
41
|
+
|
|
42
|
+
**TODO(designer):** the hit area is the visible chip, 24 px high at `regular`:
|
|
43
|
+
at the WCAG 2.5.8 floor of 24 px, below the 48 px touch-target token. A
|
|
44
|
+
48 px target would overlap the id tag, the leader line and neighbouring
|
|
45
|
+
`<obc-transmitter-stack>` segments, so the size needs a design decision.
|
|
46
|
+
|
|
47
|
+
## Slots
|
|
48
|
+
| Slot Name | Conditions | Purpose |
|
|
49
|
+
|-----------|-------------------------------|--------------------------------|
|
|
50
|
+
| icon | `value` variant and `hasIcon` | Leading icon beside the value. |
|
|
51
|
+
|
|
52
|
+
## Properties
|
|
53
|
+
|
|
54
|
+
| Property | Attribute | Type | Default | Description |
|
|
55
|
+
| --- | --- | --- | --- | --- |
|
|
56
|
+
| variant | variant | `TransmitterButtonVariant` | | |
|
|
57
|
+
| size | size | `TransmitterButtonSize` | | |
|
|
58
|
+
| value | value | `number \| null \| undefined` | | |
|
|
59
|
+
| unit | unit | `string` | `''` | |
|
|
60
|
+
| fractionDigits | fractionDigits | `number` | `1` | |
|
|
61
|
+
| maxDigits | maxDigits | `number` | `0` | Integer digits to reserve / hint (independent of `fractionDigits`). |
|
|
62
|
+
| hintedZeros | hintedZeros | `boolean` | `false` | |
|
|
63
|
+
| hasSignSpacer | hasSignSpacer | `boolean` | `false` | Reserve a minus-sign column on every segment, filled by the real sign only while a value is negative, so the width does not change across zero. |
|
|
64
|
+
| hasDegree | hasDegree | `boolean` | `false` | Show a degree column between the value and the unit (e.g. `12.3°` then `C`). |
|
|
65
|
+
| hasIcon | hasIcon | `boolean` | `false` | |
|
|
66
|
+
| hasAdvice | hasAdvice | `boolean` | `false` | |
|
|
67
|
+
| adviceValue | adviceValue | `number \| null \| undefined` | | Advisory value shown in the leading advice segment when `hasAdvice`. |
|
|
68
|
+
| hasSetPoint | hasSetPoint | `boolean` | `false` | |
|
|
69
|
+
| setpointValue | setpointValue | `number \| null \| undefined` | | Target value shown in the setpoint segment when `hasSetPoint`. |
|
|
70
|
+
| label | label | `string` | `''` | Short tag identifier shown in the `tag` variant (e.g. `TT`). |
|
|
71
|
+
| idTag | idTag | `string` | `''` | Identifier appended to the button's accessible name only (e.g. `#0001`); the parent transmitter draws the visible tag outside the button, where it cannot join the name. |
|
|
72
|
+
|
|
73
|
+
## Events
|
|
74
|
+
|
|
75
|
+
None.
|
|
76
|
+
|
|
77
|
+
## Slots
|
|
78
|
+
|
|
79
|
+
| Slot | Description |
|
|
80
|
+
| --- | --- |
|
|
81
|
+
| icon | Leading icon beside the value. |
|
|
82
|
+
|
|
83
|
+
## Stories
|
|
84
|
+
|
|
85
|
+
- [Default](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-button--default)
|
|
86
|
+
- [With Icon](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-button--with-icon)
|
|
87
|
+
- [With Advice](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-button--with-advice)
|
|
88
|
+
- [With Setpoint](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-button--with-setpoint)
|
|
89
|
+
- [With Advice And Setpoint](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-button--with-advice-and-setpoint)
|
|
90
|
+
- [Regular](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-button--regular)
|
|
91
|
+
- [Medium](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-button--medium)
|
|
92
|
+
- [Large](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-button--large)
|
|
93
|
+
- [Tag](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-button--tag)
|
|
94
|
+
- [Missing Value](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-button--missing-value)
|
|
95
|
+
- [Missing Advice Value](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-button--missing-advice-value)
|
|
96
|
+
- [Missing Setpoint Value](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-button--missing-setpoint-value)
|
|
97
|
+
- [Zero Padded](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-button--zero-padded)
|
|
98
|
+
- [Zero Padded Negative Value](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-button--zero-padded-negative-value)
|
|
99
|
+
- [Zero Padded Sign Column](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-button--zero-padded-sign-column)
|
|
100
|
+
- [Zero Padded Sign Column Negative](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-button--zero-padded-sign-column-negative)
|
|
101
|
+
- [Zero Padded Missing Value](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-button--zero-padded-missing-value)
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
# `<obc-transmitter-stack>`
|
|
2
|
+
|
|
3
|
+
Several transmitter readings side by side in one joined chip, attached to a line by a single leader line.
|
|
4
|
+
|
|
5
|
+
Lifecycle: experimental. [Storybook](https://openbridge-next-storybook.web.app/?path=/docs/automation-transmitter-transmitter-stack--docs) · [Source](https://raw.githubusercontent.com/Ocean-Industries-Concept-Lab/openbridge-webcomponents/develop/packages/openbridge-webcomponents/src/automation/transmitter-stack/transmitter-stack.ts)
|
|
6
|
+
|
|
7
|
+
`<obc-transmitter-stack>` – Several transmitter readings side by side in one
|
|
8
|
+
joined chip, attached to a line by a single leader line.
|
|
9
|
+
|
|
10
|
+
Each entry of `values` renders an `<obc-transmitter-button>` segment with its
|
|
11
|
+
own icon, value, unit and id tag. The segments take equal widths, set by the
|
|
12
|
+
widest reading, and share their borders. Positioning and the leader line
|
|
13
|
+
follow `<obc-transmitter>`.
|
|
14
|
+
|
|
15
|
+
## Features / Variants
|
|
16
|
+
- **`orientation`** – `top`, `right`, `bottom`, `left`; the edge the leader
|
|
17
|
+
line attaches to. `top` places the id tags above the chip.
|
|
18
|
+
- **`showLine`** – draw the leader line (default). Set `false` when the
|
|
19
|
+
line is drawn by other tools: the stack is then a plain box with no
|
|
20
|
+
padding or anchor offset, and `orientation` only decides whether the id
|
|
21
|
+
tags sit above (`top`) or below the chip.
|
|
22
|
+
- **Values** – `value` and `unit` per segment. `idTag` adds a label row under
|
|
23
|
+
every segment once any value has one, so the chip stays aligned.
|
|
24
|
+
- **Formatting** – per value `fractionDigits` (default `1`), `maxDigits`
|
|
25
|
+
(default `0`), `hintedZeros`, `hasSignSpacer` and `hasDegree`, formatted like
|
|
26
|
+
`<obc-transmitter-button>`. An omitted key takes its default; a key set to
|
|
27
|
+
`null`, `undefined` or `NaN` renders the reading as the unavailable dash.
|
|
28
|
+
- **Icons** – `iconSlotName` projects the light-DOM element with that slot
|
|
29
|
+
name as the segment's icon; names must be unique within the stack. The
|
|
30
|
+
name is chosen per value, so it carries no `@slot` tag (the wrapper
|
|
31
|
+
generator needs literal names).
|
|
32
|
+
- **Accessible name** – each segment is a native button named by its
|
|
33
|
+
reading, unit and `idTag`; the visible tag is hidden from assistive
|
|
34
|
+
technology so it is not read twice.
|
|
35
|
+
- **Empty** – with no `values` nothing renders, leader line included.
|
|
36
|
+
|
|
37
|
+
## Usage Guidelines
|
|
38
|
+
Use when one source reports several readings that share one leader line. For
|
|
39
|
+
a single reading, a tag pill or a trend graph, use `<obc-transmitter>`. Each
|
|
40
|
+
segment's hit area is `<obc-transmitter-button>`'s chip (24 px high), below
|
|
41
|
+
the 48 px touch-target token; see its design note.
|
|
42
|
+
|
|
43
|
+
## Slots
|
|
44
|
+
| Slot Name | Conditions | Purpose |
|
|
45
|
+
|------------------|---------------------------------|-------------------------------|
|
|
46
|
+
| `<iconSlotName>` | a value declares `iconSlotName` | Icon in that value's segment. |
|
|
47
|
+
|
|
48
|
+
## Properties
|
|
49
|
+
|
|
50
|
+
| Property | Attribute | Type | Default | Description |
|
|
51
|
+
| --- | --- | --- | --- | --- |
|
|
52
|
+
| orientation | orientation | `TransmitterOrientation` | | Edge of the chip the leader line attaches to. |
|
|
53
|
+
| lineType | lineType | `LineType \| undefined` | `undefined` | Line the transmitter sits on; offsets the leader line by half its stroke. |
|
|
54
|
+
| showLine | | `boolean` | `true` | Draw the leader line. Set `false` when the line is drawn by other tools; the stack is then a plain box with no padding or anchor offset. |
|
|
55
|
+
| values | values | `TransmitterStackValue[]` | `[]` | One segment per entry, in order. |
|
|
56
|
+
|
|
57
|
+
## Events
|
|
58
|
+
|
|
59
|
+
| Event | Type | Description |
|
|
60
|
+
| --- | --- | --- |
|
|
61
|
+
| value-click | `CustomEvent<TransmitterStackValueClickDetail>` | Fired when a segment is activated, with its value and index. |
|
|
62
|
+
| click | | Fired when any segment is clicked; `value-click` tells which. |
|
|
63
|
+
|
|
64
|
+
## Slots
|
|
65
|
+
|
|
66
|
+
None.
|
|
67
|
+
|
|
68
|
+
## Stories
|
|
69
|
+
|
|
70
|
+
- [Bottom](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-stack--bottom)
|
|
71
|
+
- [Top](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-stack--top)
|
|
72
|
+
- [Left](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-stack--left)
|
|
73
|
+
- [Right](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-stack--right)
|
|
74
|
+
- [Without Line](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-stack--without-line)
|
|
75
|
+
- [Without Line Top](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-stack--without-line-top)
|
|
76
|
+
- [Without Id Tags](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-stack--without-id-tags)
|
|
77
|
+
- [Mixed Id Tags](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-stack--mixed-id-tags)
|
|
78
|
+
- [Missing Values](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-stack--missing-values)
|
|
79
|
+
- [Usage With Pipe](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter-stack--usage-with-pipe)
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
# `<obc-transmitter>`
|
|
2
|
+
|
|
3
|
+
A readout label that attaches to a line via a leader line, showing a measured value, a tag identifier, or a value paired with a trend graph.
|
|
4
|
+
|
|
5
|
+
Lifecycle: experimental. [Storybook](https://openbridge-next-storybook.web.app/?path=/docs/automation-transmitter-transmitter--docs) · [Source](https://raw.githubusercontent.com/Ocean-Industries-Concept-Lab/openbridge-webcomponents/develop/packages/openbridge-webcomponents/src/automation/transmitter/transmitter.ts)
|
|
6
|
+
|
|
7
|
+
`<obc-transmitter>` – A readout label that attaches to a line via a leader
|
|
8
|
+
line, showing a measured value, a tag identifier, or a value paired with a
|
|
9
|
+
trend graph.
|
|
10
|
+
|
|
11
|
+
Positioning (orientation + leader line) follows `<obc-automation-readout>`.
|
|
12
|
+
The value chip is an `<obc-transmitter-button>` and the trend is an
|
|
13
|
+
`<obc-indicator-graph>` with its area fill enabled.
|
|
14
|
+
|
|
15
|
+
## Features / Variants
|
|
16
|
+
- **`type`** – `indicator` (tag pill), `value` (icon/value/unit), or value
|
|
17
|
+
paired with a `horizontal-graph` (beside) or `vertical-graph` (below).
|
|
18
|
+
- **`orientation`** – `top`, `right`, `bottom`, `left`; controls which edge
|
|
19
|
+
the leader line attaches to.
|
|
20
|
+
- **`showLine`** – draw the leader line (default). Set `false` when the
|
|
21
|
+
line is drawn by other tools: the transmitter is then a plain box with no
|
|
22
|
+
padding or anchor offset, and `orientation` only sets the side of the
|
|
23
|
+
chip the id tag sits on.
|
|
24
|
+
- **Segments** – opt into a leading advice segment with `hasAdvice`/
|
|
25
|
+
`adviceValue` and a setpoint segment with `hasSetPoint`/`setpointValue`;
|
|
26
|
+
both are read-only and shown in the value chip for non-`indicator` types.
|
|
27
|
+
- **Alert frame** – `hasAlert` wraps the whole transmitter in an
|
|
28
|
+
`<obc-alert-frame>`. `alertFrameStatus`, `alertFrameType`,
|
|
29
|
+
`alertFrameThickness` and `alertFrameMode` set its severity, flap, border
|
|
30
|
+
and flashing, with the same names as on the automation devices; a flap
|
|
31
|
+
carries the status badge and the `alert-icon`, `alert-label` and
|
|
32
|
+
`alert-timer` slots.
|
|
33
|
+
- **Formatting** – `fractionDigits`, `maxDigits`, `hintedZeros` and
|
|
34
|
+
`hasSignSpacer` are forwarded to the value chip to control decimal
|
|
35
|
+
precision, muted leading-zero padding (e.g. `0012.3`) and the sign
|
|
36
|
+
column. The advice and setpoint segments reuse the same formatting.
|
|
37
|
+
`hasDegree` adds a degree column between the value and the unit.
|
|
38
|
+
`value`, `adviceValue` and `setpointValue` render dashes when they are
|
|
39
|
+
`NaN`, `null` or `undefined`.
|
|
40
|
+
|
|
41
|
+
**TODO(designer):** the Figma Transmitter set (25656:45081) draws no alert
|
|
42
|
+
state, so the frame and its flaps follow the automation devices.
|
|
43
|
+
|
|
44
|
+
## Slots
|
|
45
|
+
| Slot Name | Conditions | Purpose |
|
|
46
|
+
|-------------|----------------------------------------------------------|---------------------------------|
|
|
47
|
+
| icon | value/graph + `hasIcon` | Leading icon in the value chip. |
|
|
48
|
+
| alert-icon | `hasAlert` + `showAlertIcon`, large side/bottom/top flap | Custom icon in the alert flap. |
|
|
49
|
+
| alert-label | `hasAlert`, bottom/top flap | Label in the alert flap. |
|
|
50
|
+
| alert-timer | `hasAlert`, bottom/top flap | Timer in the alert flap. |
|
|
51
|
+
|
|
52
|
+
## Properties
|
|
53
|
+
|
|
54
|
+
| Property | Attribute | Type | Default | Description |
|
|
55
|
+
| --- | --- | --- | --- | --- |
|
|
56
|
+
| orientation | orientation | `TransmitterOrientation` | | |
|
|
57
|
+
| type | type | `TransmitterType` | | |
|
|
58
|
+
| lineType | lineType | `LineType \| undefined` | `undefined` | |
|
|
59
|
+
| showLine | | `boolean` | `true` | Draw the leader line. Set `false` when the line is drawn by other tools; the transmitter is then a plain box with no padding or anchor offset, and `orientation` only sets the side of the chip the id tag sits on. |
|
|
60
|
+
| value | value | `number \| null \| undefined` | | |
|
|
61
|
+
| unit | unit | `string` | `''` | |
|
|
62
|
+
| fractionDigits | fractionDigits | `number` | `1` | |
|
|
63
|
+
| maxDigits | maxDigits | `number` | `0` | Integer digits to reserve / hint (independent of `fractionDigits`). |
|
|
64
|
+
| hintedZeros | hintedZeros | `boolean` | `false` | |
|
|
65
|
+
| hasSignSpacer | hasSignSpacer | `boolean` | `false` | Reserve a minus-sign column on every segment, filled by the real sign only while a value is negative, so the chip's width does not change across zero. |
|
|
66
|
+
| hasDegree | hasDegree | `boolean` | `false` | Show a degree column between the value and the unit (e.g. `12.3°` then `C`). |
|
|
67
|
+
| size | size | `TransmitterButtonSize` | | |
|
|
68
|
+
| hasIcon | hasIcon | `boolean` | `false` | |
|
|
69
|
+
| hasAdvice | hasAdvice | `boolean` | `false` | |
|
|
70
|
+
| hasAlert | hasAlert | `boolean` | `false` | Wrap the transmitter in an `<obc-alert-frame>` when true. |
|
|
71
|
+
| alertFrameStatus | alertFrameStatus | `AlertType` | | Severity of the alert frame, which picks its colour and flap badge: `alarm` (default), `warning`, `caution` or one of the `level-*` severities. Available when `hasAlert==true`. |
|
|
72
|
+
| alertFrameType | alertFrameType | `ObcAlertFrameType` | | Flap of the alert frame: `regular` (default) draws the outline alone, `small-side-flip`, `large-side-flip`, `bottom-flip` and `top-flip` add a flap with the status badge. Available when `hasAlert==true`. |
|
|
73
|
+
| alertFrameThickness | alertFrameThickness | `ObcAlertFrameThickness` | | Border of the alert frame: `small` (default) or `large`. Available when `hasAlert==true`. |
|
|
74
|
+
| alertFrameMode | alertFrameMode | `ObcAlertFrameMode` | | Acknowledgement state of the alert: `acked-active` (default) is steady, `unacked-active` flashes, `unacked-rectified` flashes a dashed frame. Available when `hasAlert==true`. |
|
|
75
|
+
| showAlertCategoryIcon | | `boolean` | `true` | Show the status badge in the flap; a small side flap without it is not drawn. Available when `hasAlert==true && alertFrameType in [SmallSideFlip, LargeSideFlip, BottomFlip, TopFlip]`. |
|
|
76
|
+
| showAlertIcon | showAlertIcon | `boolean` | `false` | Show the `alert-icon` slot in a large side, bottom or top flap. Available when `hasAlert==true && alertFrameType in [LargeSideFlip, BottomFlip, TopFlip]`. |
|
|
77
|
+
| adviceValue | adviceValue | `number \| null \| undefined` | | Advisory value shown in the leading advice segment when `hasAdvice`. |
|
|
78
|
+
| hasSetPoint | hasSetPoint | `boolean` | `false` | |
|
|
79
|
+
| setpointValue | setpointValue | `number \| null \| undefined` | | Target value shown in the setpoint segment when `hasSetPoint`. |
|
|
80
|
+
| tag | tag | `string` | `''` | Tag identifier shown when `type` is `indicator` (e.g. `TT`). |
|
|
81
|
+
| idTag | idTag | `string` | `''` | Optional identifier shown below the chip (e.g. `#0000`). |
|
|
82
|
+
| data | data | `[number[], number[]]` | `[[], []]` | Trend data for the graph types: `[xValues, yValues]`. |
|
|
83
|
+
|
|
84
|
+
## Events
|
|
85
|
+
|
|
86
|
+
None.
|
|
87
|
+
|
|
88
|
+
## Slots
|
|
89
|
+
|
|
90
|
+
| Slot | Description |
|
|
91
|
+
| --- | --- |
|
|
92
|
+
| icon | Leading icon in the value chip. |
|
|
93
|
+
| alert-icon | Custom icon in the alert flap, shown when `hasAlert` and `showAlertIcon`. |
|
|
94
|
+
| alert-label | Label in a bottom or top alert flap, shown when `hasAlert`. |
|
|
95
|
+
| alert-timer | Timer in a bottom or top alert flap, shown when `hasAlert`. |
|
|
96
|
+
|
|
97
|
+
## Stories
|
|
98
|
+
|
|
99
|
+
- [Value](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter--value)
|
|
100
|
+
- [Left](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter--left)
|
|
101
|
+
- [Right](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter--right)
|
|
102
|
+
- [Without Line](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter--without-line)
|
|
103
|
+
- [Without Line Top](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter--without-line-top)
|
|
104
|
+
- [Without Line Left](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter--without-line-left)
|
|
105
|
+
- [Without Line Right](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter--without-line-right)
|
|
106
|
+
- [Indicator](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter--indicator)
|
|
107
|
+
- [Horizontal Graph](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter--horizontal-graph)
|
|
108
|
+
- [Vertical Graph](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter--vertical-graph)
|
|
109
|
+
- [With Advice And Setpoint](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter--with-advice-and-setpoint)
|
|
110
|
+
- [With Alert](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter--with-alert)
|
|
111
|
+
- [Alert Frame Types](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter--alert-frame-types): Every flap type (rows) in the three statuses (columns), with the flap slots filled.
|
|
112
|
+
- [Alert Frame Modes](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter--alert-frame-modes): The acknowledgement modes (columns) at both thicknesses (rows); flashing frames snapshot in their on phase.
|
|
113
|
+
- [Zero Padded](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter--zero-padded)
|
|
114
|
+
- [Usage With Pipe](https://openbridge-next-storybook.web.app/?path=/story/automation-transmitter-transmitter--usage-with-pipe)
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
# `<obc-tree-navigation-group>`
|
|
2
|
+
|
|
3
|
+
An expandable parent row in a tree-navigation structure: a header row with an expand/collapse chevron, plus a slot for the child rows it discloses.
|
|
4
|
+
|
|
5
|
+
Lifecycle: beta. [Source](https://raw.githubusercontent.com/Ocean-Industries-Concept-Lab/openbridge-webcomponents/develop/packages/openbridge-webcomponents/src/components/tree-navigation-group/tree-navigation-group.ts)
|
|
6
|
+
|
|
7
|
+
`<obc-tree-navigation-group>` – An expandable parent row in a tree-navigation
|
|
8
|
+
structure: a header row with an expand/collapse chevron, plus a slot for the
|
|
9
|
+
child rows it discloses.
|
|
10
|
+
|
|
11
|
+
A group renders an `<obc-tree-navigation-item>` header (carrying its own label,
|
|
12
|
+
icon, terminal type, and alert badges) followed by its slotted children. When
|
|
13
|
+
placed inside `<obc-tree-navigation>`, the container computes and assigns the
|
|
14
|
+
`branches` guide lines for every row automatically from each row's position —
|
|
15
|
+
a group does not need its depth configured by hand.
|
|
16
|
+
|
|
17
|
+
The group manages only its own open/closed state and forwards header presentation
|
|
18
|
+
to its internal header item. It does not draw guide lines itself; that is the
|
|
19
|
+
container's responsibility (see `<obc-tree-navigation>`).
|
|
20
|
+
|
|
21
|
+
## Features
|
|
22
|
+
- **Disclosure:** A chevron in the header toggles the slotted children. The open
|
|
23
|
+
state is held in `expanded` and reflected so the container and CSS can react.
|
|
24
|
+
- **Header presentation:** `label`, the `icon` slot, `terminalType`, and the
|
|
25
|
+
`alerts` count map are forwarded to the header row.
|
|
26
|
+
- **Selection:** `checked` marks the group's header as the current item.
|
|
27
|
+
- **Automatic guides:** Inside `<obc-tree-navigation>`, the header's `branches`
|
|
28
|
+
are assigned by the container; nested groups continue the guide columns down.
|
|
29
|
+
|
|
30
|
+
## Usage Guidelines
|
|
31
|
+
- Nest `<obc-tree-navigation-item>` (leaves) and further `<obc-tree-navigation-group>`
|
|
32
|
+
elements as children to build the hierarchy.
|
|
33
|
+
- Always place groups and items inside an `<obc-tree-navigation>` container so the
|
|
34
|
+
guide lines are computed; using a group standalone draws a header with no guides.
|
|
35
|
+
- Provide a header icon via the `icon` slot (forwarded to the header row).
|
|
36
|
+
|
|
37
|
+
## Slots
|
|
38
|
+
|
|
39
|
+
| Slot Name | Renders When... | Purpose |
|
|
40
|
+
|-----------|--------------------------|--------------------------------------------------------------|
|
|
41
|
+
| icon | `hasIcon` is true | Leading icon for the group header row. |
|
|
42
|
+
| (default) | Always | Child rows (`obc-tree-navigation-item` / `-group`). |
|
|
43
|
+
|
|
44
|
+
## Properties
|
|
45
|
+
|
|
46
|
+
| Property | Attribute | Type | Default | Description |
|
|
47
|
+
| --- | --- | --- | --- | --- |
|
|
48
|
+
| label | label | `string` | `'Group'` | The text label displayed for the group header row. |
|
|
49
|
+
| branches | branches | `TreeBranchType[]` | `[]` | Guide line to draw for each ancestor level of the header row. Normally set by the parent `<obc-tree-navigation>` container from the group's position; only set it manually when using a group outside the container. |
|
|
50
|
+
| expanded | expanded | `boolean` | `false` | Whether the group is expanded, disclosing its children. Rotates the chevron. |
|
|
51
|
+
| checked | checked | `boolean` | `false` | Whether the group header is the current selection. |
|
|
52
|
+
| disabled | disabled | `boolean` | `false` | Disables the group header, removing it from the tab order and dimming it. |
|
|
53
|
+
| hasIcon | | `boolean` | `true` | Whether the group header shows a leading icon (provided via the `icon` slot). |
|
|
54
|
+
| terminalType | terminalType | `string` | | Terminal type for the header row, controlling the alert-header marker shown in the terminal. One of `regular` (default), `aggregated-header`, or `group-header`. |
|
|
55
|
+
| alerts | alerts | `TreeNavigationItemAlerts \| undefined` | | Per-severity alert counts shown as trailing badges on the header row while the group is collapsed; expanding it hides them, since the rows then carry their own. A group usually sets `combine` so its header shows one badge totalling the alerts of the rows beneath it. |
|
|
56
|
+
| href | href | `string \| undefined` | | The URL to navigate to when the header is activated. If set, the header row renders as a link; otherwise it acts as a button. |
|
|
57
|
+
|
|
58
|
+
## Events
|
|
59
|
+
|
|
60
|
+
| Event | Type | Description |
|
|
61
|
+
| --- | --- | --- |
|
|
62
|
+
| expand-toggle | `CustomEvent<boolean>` | Fired when the header is activated; detail is the next `expanded` value. |
|
|
63
|
+
|
|
64
|
+
## Slots
|
|
65
|
+
|
|
66
|
+
| Slot | Description |
|
|
67
|
+
| --- | --- |
|
|
68
|
+
| icon | Leading icon for the group header (shown when `hasIcon` is true). |
|
|
69
|
+
| (default) | Child rows disclosed when the group is expanded. |
|