@oicl/openbridge-webcomponents-full-bundle 2.0.0-next.57 → 2.0.0-next.59

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 (185) hide show
  1. package/bundle/openbridge-webcomponents.bundle.js +6585 -4581
  2. package/bundle/openbridge-webcomponents.bundle.js.map +1 -1
  3. package/custom-elements.json +1047 -83
  4. package/dist/alert-severity.d.ts +38 -0
  5. package/dist/alert-severity.d.ts.map +1 -0
  6. package/dist/alert-severity.js +176 -0
  7. package/dist/alert-severity.js.map +1 -0
  8. package/dist/ar/building-blocks/poi-header/poi-header.css.js +38 -7
  9. package/dist/ar/building-blocks/poi-header/poi-header.css.js.map +1 -1
  10. package/dist/ar/building-blocks/poi-header/poi-header.d.ts +7 -2
  11. package/dist/ar/building-blocks/poi-header/poi-header.d.ts.map +1 -1
  12. package/dist/ar/building-blocks/poi-header/poi-header.js +5 -0
  13. package/dist/ar/building-blocks/poi-header/poi-header.js.map +1 -1
  14. package/dist/ar/poi-button/poi-button.css.js +110 -32
  15. package/dist/ar/poi-button/poi-button.css.js.map +1 -1
  16. package/dist/ar/poi-button/poi-button.d.ts +7 -2
  17. package/dist/ar/poi-button/poi-button.d.ts.map +1 -1
  18. package/dist/ar/poi-button/poi-button.js +15 -0
  19. package/dist/ar/poi-button/poi-button.js.map +1 -1
  20. package/dist/ar/types.d.ts +6 -1
  21. package/dist/ar/types.d.ts.map +1 -1
  22. package/dist/ar/types.js +5 -0
  23. package/dist/ar/types.js.map +1 -1
  24. package/dist/automation/automation-badge/automation-badge.d.ts +9 -1
  25. package/dist/automation/automation-badge/automation-badge.d.ts.map +1 -1
  26. package/dist/automation/automation-badge/automation-badge.js +119 -12
  27. package/dist/automation/automation-badge/automation-badge.js.map +1 -1
  28. package/dist/automation/automation-button/abstract-automation-button-storybook-helpers.d.ts +25 -1
  29. package/dist/automation/automation-button/abstract-automation-button-storybook-helpers.d.ts.map +1 -1
  30. package/dist/automation/automation-button/abstract-automation-button-storybook-helpers.js +7 -2
  31. package/dist/automation/automation-button/abstract-automation-button-storybook-helpers.js.map +1 -1
  32. package/dist/automation/automation-button/abstract-automation-button.d.ts +10 -3
  33. package/dist/automation/automation-button/abstract-automation-button.d.ts.map +1 -1
  34. package/dist/automation/automation-button/abstract-automation-button.js +23 -2
  35. package/dist/automation/automation-button/abstract-automation-button.js.map +1 -1
  36. package/dist/automation/automation-button/automation-button.css.js +9 -4
  37. package/dist/automation/automation-button/automation-button.css.js.map +1 -1
  38. package/dist/automation/automation-button/automation-button.d.ts +4 -2
  39. package/dist/automation/automation-button/automation-button.d.ts.map +1 -1
  40. package/dist/automation/automation-button/automation-button.js +24 -6
  41. package/dist/automation/automation-button/automation-button.js.map +1 -1
  42. package/dist/automation/automation-tank/automation-tank.d.ts +3 -2
  43. package/dist/automation/automation-tank/automation-tank.d.ts.map +1 -1
  44. package/dist/automation/automation-tank/automation-tank.js +13 -2
  45. package/dist/automation/automation-tank/automation-tank.js.map +1 -1
  46. package/dist/building-blocks/instrument-radial/instrument-radial.d.ts +10 -0
  47. package/dist/building-blocks/instrument-radial/instrument-radial.d.ts.map +1 -1
  48. package/dist/building-blocks/instrument-radial/instrument-radial.js +86 -21
  49. package/dist/building-blocks/instrument-radial/instrument-radial.js.map +1 -1
  50. package/dist/components/accordion-card/accordion-card.css.js +34 -0
  51. package/dist/components/accordion-card/accordion-card.css.js.map +1 -1
  52. package/dist/components/accordion-card/accordion-card.d.ts +3 -2
  53. package/dist/components/accordion-card/accordion-card.d.ts.map +1 -1
  54. package/dist/components/accordion-card/accordion-card.js +4 -3
  55. package/dist/components/accordion-card/accordion-card.js.map +1 -1
  56. package/dist/components/alert-button/alert-button.css.js +744 -7
  57. package/dist/components/alert-button/alert-button.css.js.map +1 -1
  58. package/dist/components/alert-button/alert-button.d.ts +3 -1
  59. package/dist/components/alert-button/alert-button.d.ts.map +1 -1
  60. package/dist/components/alert-button/alert-button.js +33 -31
  61. package/dist/components/alert-button/alert-button.js.map +1 -1
  62. package/dist/components/alert-frame/alert-frame.css.js +116 -29
  63. package/dist/components/alert-frame/alert-frame.css.js.map +1 -1
  64. package/dist/components/alert-frame/alert-frame.d.ts +42 -15
  65. package/dist/components/alert-frame/alert-frame.d.ts.map +1 -1
  66. package/dist/components/alert-frame/alert-frame.js +68 -17
  67. package/dist/components/alert-frame/alert-frame.js.map +1 -1
  68. package/dist/components/alert-frame/critical-badge.d.ts +12 -0
  69. package/dist/components/alert-frame/critical-badge.d.ts.map +1 -0
  70. package/dist/components/alert-frame/critical-badge.js +47 -0
  71. package/dist/components/alert-frame/critical-badge.js.map +1 -0
  72. package/dist/components/alert-frame/diagnostic-badge.d.ts +12 -0
  73. package/dist/components/alert-frame/diagnostic-badge.d.ts.map +1 -0
  74. package/dist/components/alert-frame/diagnostic-badge.js +60 -0
  75. package/dist/components/alert-frame/diagnostic-badge.js.map +1 -0
  76. package/dist/components/alert-icon/alert-icon.d.ts +6 -1
  77. package/dist/components/alert-icon/alert-icon.d.ts.map +1 -1
  78. package/dist/components/alert-icon/alert-icon.js +96 -38
  79. package/dist/components/alert-icon/alert-icon.js.map +1 -1
  80. package/dist/components/alert-icon/icons/icon-critical.d.ts +3 -0
  81. package/dist/components/alert-icon/icons/icon-critical.d.ts.map +1 -0
  82. package/dist/components/alert-icon/icons/icon-critical.js +26 -0
  83. package/dist/components/alert-icon/icons/icon-critical.js.map +1 -0
  84. package/dist/components/alert-list-details/alert-list-details.d.ts.map +1 -1
  85. package/dist/components/alert-list-details/alert-list-details.js +6 -7
  86. package/dist/components/alert-list-details/alert-list-details.js.map +1 -1
  87. package/dist/components/badge/badge.css.js +50 -2
  88. package/dist/components/badge/badge.css.js.map +1 -1
  89. package/dist/components/badge/badge.d.ts +13 -2
  90. package/dist/components/badge/badge.d.ts.map +1 -1
  91. package/dist/components/badge/badge.js +54 -0
  92. package/dist/components/badge/badge.js.map +1 -1
  93. package/dist/index.js +2 -1
  94. package/dist/manual-icon/icon-alerts-critical-twotone.d.ts +30 -0
  95. package/dist/manual-icon/icon-alerts-critical-twotone.d.ts.map +1 -0
  96. package/dist/manual-icon/icon-alerts-critical-twotone.js +55 -0
  97. package/dist/manual-icon/icon-alerts-critical-twotone.js.map +1 -0
  98. package/dist/manual-icon/icon-alerts-diagnostic-twotone.d.ts +30 -0
  99. package/dist/manual-icon/icon-alerts-diagnostic-twotone.d.ts.map +1 -0
  100. package/dist/manual-icon/icon-alerts-diagnostic-twotone.js +55 -0
  101. package/dist/manual-icon/icon-alerts-diagnostic-twotone.js.map +1 -0
  102. package/dist/navigation-instruments/gauge-radial/gauge-radial.css.js +99 -0
  103. package/dist/navigation-instruments/gauge-radial/gauge-radial.css.js.map +1 -0
  104. package/dist/navigation-instruments/gauge-radial/gauge-radial.d.ts +42 -7
  105. package/dist/navigation-instruments/gauge-radial/gauge-radial.d.ts.map +1 -1
  106. package/dist/navigation-instruments/gauge-radial/gauge-radial.js +178 -31
  107. package/dist/navigation-instruments/gauge-radial/gauge-radial.js.map +1 -1
  108. package/dist/navigation-instruments/readout/readout.css.js +7 -18
  109. package/dist/navigation-instruments/readout/readout.css.js.map +1 -1
  110. package/dist/navigation-instruments/readout/readout.d.ts +6 -7
  111. package/dist/navigation-instruments/readout/readout.d.ts.map +1 -1
  112. package/dist/navigation-instruments/readout/readout.js +54 -52
  113. package/dist/navigation-instruments/readout/readout.js.map +1 -1
  114. package/dist/navigation-instruments/readout-list-item/readout-list-item.css.js +9 -36
  115. package/dist/navigation-instruments/readout-list-item/readout-list-item.css.js.map +1 -1
  116. package/dist/navigation-instruments/readout-list-item/readout-list-item.d.ts +8 -8
  117. package/dist/navigation-instruments/readout-list-item/readout-list-item.d.ts.map +1 -1
  118. package/dist/navigation-instruments/readout-list-item/readout-list-item.js +49 -42
  119. package/dist/navigation-instruments/readout-list-item/readout-list-item.js.map +1 -1
  120. package/dist/navigation-instruments/watch/tickmark.d.ts +2 -1
  121. package/dist/navigation-instruments/watch/tickmark.d.ts.map +1 -1
  122. package/dist/navigation-instruments/watch/tickmark.js +24 -4
  123. package/dist/navigation-instruments/watch/tickmark.js.map +1 -1
  124. package/dist/navigation-instruments/watch/watch.d.ts +23 -1
  125. package/dist/navigation-instruments/watch/watch.d.ts.map +1 -1
  126. package/dist/navigation-instruments/watch/watch.js +48 -20
  127. package/dist/navigation-instruments/watch/watch.js.map +1 -1
  128. package/dist/openbridge.css +155 -0
  129. package/dist/types.d.ts +7 -1
  130. package/dist/types.d.ts.map +1 -1
  131. package/dist/types.js +18 -7
  132. package/dist/types.js.map +1 -1
  133. package/package.json +1 -1
  134. package/src/alert-severity.ts +225 -0
  135. package/src/ar/building-blocks/poi-header/poi-header.css +38 -7
  136. package/src/ar/building-blocks/poi-header/poi-header.ts +6 -1
  137. package/src/ar/poi-button/poi-button.css +126 -32
  138. package/src/ar/poi-button/poi-button.ts +16 -1
  139. package/src/ar/types.ts +5 -0
  140. package/src/automation/automation-badge/automation-badge.ts +124 -17
  141. package/src/automation/automation-button/abstract-automation-button-storybook-helpers.ts +5 -0
  142. package/src/automation/automation-button/abstract-automation-button.ts +21 -3
  143. package/src/automation/automation-button/automation-button.css +9 -4
  144. package/src/automation/automation-button/automation-button.ts +25 -7
  145. package/src/automation/automation-tank/automation-tank.stories.ts +22 -0
  146. package/src/automation/automation-tank/automation-tank.ts +12 -3
  147. package/src/building-blocks/instrument-radial/instrument-radial.stories.ts +21 -0
  148. package/src/building-blocks/instrument-radial/instrument-radial.ts +118 -21
  149. package/src/components/accordion-card/accordion-card.css +33 -0
  150. package/src/components/accordion-card/accordion-card.stories.ts +2 -1
  151. package/src/components/accordion-card/accordion-card.ts +3 -4
  152. package/src/components/alert-button/alert-button.css +89 -5
  153. package/src/components/alert-button/alert-button.stories.ts +43 -0
  154. package/src/components/alert-button/alert-button.ts +43 -32
  155. package/src/components/alert-frame/alert-frame.css +116 -29
  156. package/src/components/alert-frame/alert-frame.stories.ts +63 -3
  157. package/src/components/alert-frame/alert-frame.ts +114 -23
  158. package/src/components/alert-frame/critical-badge.ts +39 -0
  159. package/src/components/alert-frame/diagnostic-badge.ts +52 -0
  160. package/src/components/alert-icon/alert-icon.stories.ts +41 -0
  161. package/src/components/alert-icon/alert-icon.ts +101 -38
  162. package/src/components/alert-icon/icons/icon-critical.ts +23 -0
  163. package/src/components/alert-list-details/alert-list-details.stories.ts +67 -0
  164. package/src/components/alert-list-details/alert-list-details.ts +11 -10
  165. package/src/components/badge/badge.css +52 -2
  166. package/src/components/badge/badge.stories.ts +75 -0
  167. package/src/components/badge/badge.ts +70 -2
  168. package/src/main.css +1 -0
  169. package/src/manual-icon/icon-alerts-critical-twotone.ts +60 -0
  170. package/src/manual-icon/icon-alerts-diagnostic-twotone.ts +60 -0
  171. package/src/mixins/alert.css +29 -0
  172. package/src/navigation-instruments/gauge-radial/gauge-radial.css +85 -0
  173. package/src/navigation-instruments/gauge-radial/gauge-radial.stories.ts +149 -7
  174. package/src/navigation-instruments/gauge-radial/gauge-radial.ts +212 -33
  175. package/src/navigation-instruments/readout/readout.css +7 -24
  176. package/src/navigation-instruments/readout/readout.stories.ts +57 -4
  177. package/src/navigation-instruments/readout/readout.ts +69 -63
  178. package/src/navigation-instruments/readout-list-item/readout-list-item.css +9 -42
  179. package/src/navigation-instruments/readout-list-item/readout-list-item.stories.ts +57 -14
  180. package/src/navigation-instruments/readout-list-item/readout-list-item.ts +54 -44
  181. package/src/navigation-instruments/watch/tickmark.ts +33 -6
  182. package/src/navigation-instruments/watch/watch.ts +60 -25
  183. package/src/palettes/critical.md +95 -0
  184. package/src/palettes/manual.css +165 -0
  185. package/src/types.ts +20 -3
@@ -32,8 +32,24 @@ export enum ObcAutomationBadgeType {
32
32
  Caution = 'caution',
33
33
  Warning = 'warning',
34
34
  Alarm = 'alarm',
35
+ IsaCritical = 'isa-critical',
36
+ IsaHigh = 'isa-high',
37
+ IsaMedium = 'isa-medium',
38
+ IsaLow = 'isa-low',
39
+ IsaDiagnostic = 'isa-diagnostic',
35
40
  }
36
41
 
42
+ const ALERT_BADGE_TYPES: ObcAutomationBadgeType[] = [
43
+ ObcAutomationBadgeType.Caution,
44
+ ObcAutomationBadgeType.Warning,
45
+ ObcAutomationBadgeType.Alarm,
46
+ ObcAutomationBadgeType.IsaCritical,
47
+ ObcAutomationBadgeType.IsaHigh,
48
+ ObcAutomationBadgeType.IsaMedium,
49
+ ObcAutomationBadgeType.IsaLow,
50
+ ObcAutomationBadgeType.IsaDiagnostic,
51
+ ];
52
+
37
53
  @customElement('obc-automation-badge')
38
54
  export class ObcAutomationBadge extends LitElement {
39
55
  @property({type: String}) mode: ObcAutomationBadgeMode =
@@ -42,20 +58,81 @@ export class ObcAutomationBadge extends LitElement {
42
58
  @property({type: String}) type?: ObcAutomationBadgeType = undefined;
43
59
 
44
60
  private get effectiveMode() {
45
- if (
46
- this.type &&
47
- [
48
- ObcAutomationBadgeType.Caution,
49
- ObcAutomationBadgeType.Warning,
50
- ObcAutomationBadgeType.Alarm,
51
- ].includes(this.type)
52
- ) {
61
+ if (this.type && ALERT_BADGE_TYPES.includes(this.type)) {
53
62
  return ObcAutomationBadgeMode.Flat;
54
63
  } else {
55
64
  return this.mode;
56
65
  }
57
66
  }
58
67
 
68
+ private isAlertType(...types: ObcAutomationBadgeType[]): boolean {
69
+ return !!this.type && types.includes(this.type);
70
+ }
71
+
72
+ private renderIsaCriticalIcon(flat: boolean) {
73
+ if (flat) {
74
+ return html`<svg
75
+ width="16"
76
+ height="16"
77
+ viewBox="0 0 16 16"
78
+ fill="none"
79
+ xmlns="http://www.w3.org/2000/svg"
80
+ >
81
+ <path
82
+ d="M14.667 8L11.3337 13.77H4.66634L1.33301 8L4.66634 2.23H11.3337L14.667 8Z"
83
+ fill="var(--critical-enabled-background-color)"
84
+ />
85
+ <path
86
+ d="M11.1543 2.72998H4.8457L2.51237 7.99998L4.8457 13.27H11.1543L13.4876 7.99998L11.1543 2.72998Z"
87
+ stroke="var(--critical-enabled-border-color)"
88
+ />
89
+ <path
90
+ d="M7.66754 10.3343V5.00098H9.00087V10.3343H7.66754Z"
91
+ fill="var(--on-critical-active-color)"
92
+ />
93
+ <path
94
+ d="M9.00087 11.6676H7.66754V13.001H9.00087V11.6676Z"
95
+ fill="var(--on-critical-active-color)"
96
+ />
97
+ </svg>`;
98
+ }
99
+ return html`<svg
100
+ width="16"
101
+ height="16"
102
+ viewBox="0 0 16 16"
103
+ fill="none"
104
+ xmlns="http://www.w3.org/2000/svg"
105
+ >
106
+ <path
107
+ d="M2 0.5H14C14.8284 0.5 15.5 1.17157 15.5 2V14C15.5 14.8284 14.8284 15.5 14 15.5H2C1.17157 15.5 0.5 14.8284 0.5 14V2C0.5 1.17157 1.17157 0.5 2 0.5Z"
108
+ fill="var(--critical-enabled-background-color)"
109
+ />
110
+ <path
111
+ d="M2 0.5H14C14.8284 0.5 15.5 1.17157 15.5 2V14C15.5 14.8284 14.8284 15.5 14 15.5H2C1.17157 15.5 0.5 14.8284 0.5 14V2C0.5 1.17157 1.17157 0.5 2 0.5Z"
112
+ stroke="var(--critical-enabled-border-color)"
113
+ />
114
+ <path
115
+ d="M14 8L10.9282 13.33H5.0718L2 8L5.0718 2.67H10.9282L14 8Z"
116
+ fill="var(--on-critical-active-color)"
117
+ />
118
+ </svg>`;
119
+ }
120
+
121
+ private renderIsaDiagnosticIcon() {
122
+ return html`<svg
123
+ width="16"
124
+ height="16"
125
+ viewBox="0 0 16 16"
126
+ fill="none"
127
+ xmlns="http://www.w3.org/2000/svg"
128
+ >
129
+ <path
130
+ d="M7 1.33301H9V7.53301L13.2147 5.13301L14.2147 6.86634L10 9.33301L14.2147 11.7997L13.2147 13.533L9 11.133V15.667H7V11.133L2.78534 13.533L1.78534 11.7997L6 9.33301L1.78534 6.86634L2.78534 5.13301L7 7.53301V1.33301Z"
131
+ fill="var(--notification-enabled-background-color)"
132
+ />
133
+ </svg>`;
134
+ }
135
+
59
136
  // TODO: replace the typo 'siluette' with 'silhouette', probably in Figma as well
60
137
  private getIcon() {
61
138
  if (this.type === ObcAutomationBadgeType.Auto) {
@@ -89,9 +166,18 @@ export class ObcAutomationBadge extends LitElement {
89
166
  class="icon siluette"
90
167
  ></obi-alert-off-filled
91
168
  ><obi-alert-off-filled class="icon"></obi-alert-off-filled>`;
169
+ } else if (this.type === ObcAutomationBadgeType.IsaCritical) {
170
+ return this.renderIsaCriticalIcon(
171
+ this.effectiveMode === ObcAutomationBadgeMode.Flat
172
+ );
173
+ } else if (this.type === ObcAutomationBadgeType.IsaDiagnostic) {
174
+ return this.renderIsaDiagnosticIcon();
92
175
  } else if (
93
- this.type === ObcAutomationBadgeType.Caution &&
94
- this.mode === ObcAutomationBadgeMode.Flat
176
+ this.isAlertType(
177
+ ObcAutomationBadgeType.Caution,
178
+ ObcAutomationBadgeType.IsaLow
179
+ ) &&
180
+ this.effectiveMode === ObcAutomationBadgeMode.Flat
95
181
  ) {
96
182
  return html`<svg
97
183
  width="16"
@@ -138,7 +224,12 @@ export class ObcAutomationBadge extends LitElement {
138
224
  fill="var(--on-caution-active-color)"
139
225
  />
140
226
  </svg>`;
141
- } else if (this.type === ObcAutomationBadgeType.Caution) {
227
+ } else if (
228
+ this.isAlertType(
229
+ ObcAutomationBadgeType.Caution,
230
+ ObcAutomationBadgeType.IsaLow
231
+ )
232
+ ) {
142
233
  return html`<svg
143
234
  width="16"
144
235
  height="16"
@@ -160,8 +251,11 @@ export class ObcAutomationBadge extends LitElement {
160
251
  />
161
252
  </svg> `;
162
253
  } else if (
163
- this.type === ObcAutomationBadgeType.Warning &&
164
- this.mode === ObcAutomationBadgeMode.Flat
254
+ this.isAlertType(
255
+ ObcAutomationBadgeType.Warning,
256
+ ObcAutomationBadgeType.IsaMedium
257
+ ) &&
258
+ this.effectiveMode === ObcAutomationBadgeMode.Flat
165
259
  ) {
166
260
  return html`
167
261
  <svg
@@ -218,7 +312,12 @@ export class ObcAutomationBadge extends LitElement {
218
312
  />
219
313
  </svg>
220
314
  `;
221
- } else if (this.type === ObcAutomationBadgeType.Warning) {
315
+ } else if (
316
+ this.isAlertType(
317
+ ObcAutomationBadgeType.Warning,
318
+ ObcAutomationBadgeType.IsaMedium
319
+ )
320
+ ) {
222
321
  return html`<svg
223
322
  width="16"
224
323
  height="16"
@@ -237,8 +336,11 @@ export class ObcAutomationBadge extends LitElement {
237
336
  <circle cx="8" cy="8" r="5" fill="var(--on-warning-active-color)" />
238
337
  </svg> `;
239
338
  } else if (
240
- this.type === ObcAutomationBadgeType.Alarm &&
241
- this.mode === ObcAutomationBadgeMode.Flat
339
+ this.isAlertType(
340
+ ObcAutomationBadgeType.Alarm,
341
+ ObcAutomationBadgeType.IsaHigh
342
+ ) &&
343
+ this.effectiveMode === ObcAutomationBadgeMode.Flat
242
344
  ) {
243
345
  return html`<svg
244
346
  width="16"
@@ -285,7 +387,12 @@ export class ObcAutomationBadge extends LitElement {
285
387
  fill="var(--on-alarm-active-color)"
286
388
  />
287
389
  </svg> `;
288
- } else if (this.type === ObcAutomationBadgeType.Alarm) {
390
+ } else if (
391
+ this.isAlertType(
392
+ ObcAutomationBadgeType.Alarm,
393
+ ObcAutomationBadgeType.IsaHigh
394
+ )
395
+ ) {
289
396
  return html`
290
397
  <svg
291
398
  width="16"
@@ -2,6 +2,7 @@ import {
2
2
  ObcAlertFrameStatus,
3
3
  ObcAlertFrameThickness,
4
4
  ObcAlertFrameType,
5
+ ObcAlertFrameMode,
5
6
  } from '../../components/alert-frame/alert-frame.js';
6
7
  import {MotorizedVariant} from './abstract-automation-button-motorized.js';
7
8
  import {
@@ -33,6 +34,10 @@ export const argTypesAbstractAutomationButton = {
33
34
  options: Object.values(ObcAlertFrameType),
34
35
  control: {type: 'radio'},
35
36
  },
37
+ alertFrameMode: {
38
+ options: Object.values(ObcAlertFrameMode),
39
+ control: {type: 'radio'},
40
+ },
36
41
  alertFrameThickness: {
37
42
  options: Object.values(ObcAlertFrameThickness),
38
43
  control: {type: 'radio'},
@@ -13,10 +13,11 @@ import {
13
13
  AutomationButtonReadoutStackSize,
14
14
  } from '../../components/automation-button-readout-stack/automation-button-readout-stack.js';
15
15
  import {
16
- ObcAlertFrameStatus,
17
16
  ObcAlertFrameThickness,
18
17
  ObcAlertFrameType,
18
+ ObcAlertFrameMode,
19
19
  } from '../../components/alert-frame/alert-frame.js';
20
+ import {AlertType} from '../../types.js';
20
21
  import '../automation-badge/automation-badge.js';
21
22
  import {ObcAutomationBadgeType} from '../automation-badge/automation-badge.js';
22
23
  import {CircularProgressMode} from '../../building-blocks/circular-progress/circular-progress.js';
@@ -27,6 +28,11 @@ export enum AutomationButtonBadgeAlert {
27
28
  Caution = 'caution',
28
29
  Warning = 'warning',
29
30
  Alarm = 'alarm',
31
+ IsaCritical = 'isa-critical',
32
+ IsaHigh = 'isa-high',
33
+ IsaMedium = 'isa-medium',
34
+ IsaLow = 'isa-low',
35
+ IsaDiagnostic = 'isa-diagnostic',
30
36
  }
31
37
 
32
38
  export enum AutomationButtonBadgeInterlock {
@@ -62,8 +68,9 @@ export class ObcAbstractAutomationButton extends LitElement {
62
68
  ObcAlertFrameType.SmallSideFlip;
63
69
  @property({type: String}) alertFrameThickness: ObcAlertFrameThickness =
64
70
  ObcAlertFrameThickness.Small;
65
- @property({type: String}) alertFrameStatus: ObcAlertFrameStatus =
66
- ObcAlertFrameStatus.Alarm;
71
+ @property({type: String}) alertFrameStatus: AlertType = AlertType.Alarm;
72
+ @property({type: String}) alertFrameMode: ObcAlertFrameMode =
73
+ ObcAlertFrameMode.ackedActive;
67
74
  @property({type: Boolean, attribute: false}) showAlertCategoryIcon: boolean =
68
75
  true;
69
76
  @property({type: Boolean}) showAlertIcon: boolean = false;
@@ -151,6 +158,16 @@ export class ObcAbstractAutomationButton extends LitElement {
151
158
  return ObcAutomationBadgeType.Warning;
152
159
  } else if (this.badgeAlert === AutomationButtonBadgeAlert.Alarm) {
153
160
  return ObcAutomationBadgeType.Alarm;
161
+ } else if (this.badgeAlert === AutomationButtonBadgeAlert.IsaCritical) {
162
+ return ObcAutomationBadgeType.IsaCritical;
163
+ } else if (this.badgeAlert === AutomationButtonBadgeAlert.IsaHigh) {
164
+ return ObcAutomationBadgeType.IsaHigh;
165
+ } else if (this.badgeAlert === AutomationButtonBadgeAlert.IsaMedium) {
166
+ return ObcAutomationBadgeType.IsaMedium;
167
+ } else if (this.badgeAlert === AutomationButtonBadgeAlert.IsaLow) {
168
+ return ObcAutomationBadgeType.IsaLow;
169
+ } else if (this.badgeAlert === AutomationButtonBadgeAlert.IsaDiagnostic) {
170
+ return ObcAutomationBadgeType.IsaDiagnostic;
154
171
  }
155
172
  return null;
156
173
  }
@@ -211,6 +228,7 @@ export class ObcAbstractAutomationButton extends LitElement {
211
228
  .alertFrameType=${this.alertFrameType}
212
229
  .alertFrameThickness=${this.alertFrameThickness}
213
230
  .alertFrameStatus=${this.alertFrameStatus}
231
+ .alertFrameMode=${this.alertFrameMode}
214
232
  .showAlertCategoryIcon=${this.showAlertCategoryIcon}
215
233
  .showAlertIcon=${this.showAlertIcon}
216
234
  ?progress=${this.progress}
@@ -7,6 +7,11 @@
7
7
  height: 0;
8
8
  }
9
9
 
10
+ .button-wrapper {
11
+ width: fit-content;
12
+ height: fit-content;
13
+ }
14
+
10
15
  .positioning-point {
11
16
  &.label-bottom {
12
17
  top: calc(var(--automation-components-button-touch-target-size) / -2);
@@ -230,8 +235,8 @@
230
235
 
231
236
  .alert-frame {
232
237
  position: absolute;
233
- top: -1px;
234
- right: -1px;
235
- left: -1px;
236
- bottom: -1px;
238
+ top: 0;
239
+ right: 0;
240
+ left: 0;
241
+ bottom: 0;
237
242
  }
@@ -15,10 +15,12 @@ import '../../icons/icon-arrow-left-google.js';
15
15
  import '../../icons/icon-arrow-right-google.js';
16
16
  import '../../components/alert-frame/alert-frame.js';
17
17
  import {
18
- ObcAlertFrameStatus,
19
18
  ObcAlertFrameThickness,
20
19
  ObcAlertFrameType,
20
+ ObcAlertFrameMode,
21
+ wrapWithAlertFrame,
21
22
  } from '../../components/alert-frame/alert-frame.js';
23
+ import {AlertType} from '../../types.js';
22
24
  import {customElement} from '../../decorator.js';
23
25
  import {
24
26
  AutomationButtonReadoutStack,
@@ -102,8 +104,9 @@ export class ObcAutomationButton extends LitElement {
102
104
  ObcAlertFrameType.SmallSideFlip;
103
105
  @property({type: String}) alertFrameThickness: ObcAlertFrameThickness =
104
106
  ObcAlertFrameThickness.Small;
105
- @property({type: String}) alertFrameStatus: ObcAlertFrameStatus =
106
- ObcAlertFrameStatus.Alarm;
107
+ @property({type: String}) alertFrameStatus: AlertType = AlertType.Alarm;
108
+ @property({type: String}) alertFrameMode: ObcAlertFrameMode =
109
+ ObcAlertFrameMode.ackedActive;
107
110
  @property({type: Boolean, attribute: false}) showAlertCategoryIcon: boolean =
108
111
  true;
109
112
  @property({type: Boolean}) showAlertIcon: boolean = false;
@@ -165,12 +168,13 @@ export class ObcAutomationButton extends LitElement {
165
168
  ></obc-automation-button-readout-stack>
166
169
  `
167
170
  : nothing}
168
- ${this.alert
171
+ ${this.alert && this.positioning === AutomationButtonPositioning.point
169
172
  ? html` <obc-alert-frame
170
173
  class="alert-frame"
171
174
  .type=${this.alertFrameType}
172
175
  .thickness=${this.alertFrameThickness}
173
176
  .status=${this.alertFrameStatus}
177
+ .mode=${this.alertFrameMode}
174
178
  .showAlertCategoryIcon=${this.showAlertCategoryIcon}
175
179
  .showIcon=${this.showAlertIcon}
176
180
  >
@@ -186,17 +190,31 @@ export class ObcAutomationButton extends LitElement {
186
190
  private wrapContent(content: HTMLTemplateResult): HTMLTemplateResult {
187
191
  if (this.positioning === AutomationButtonPositioning.point) {
188
192
  return html`<div class="point-wrapper">${content}</div>`;
189
- } else if (this.positioning === AutomationButtonPositioning.symbol) {
193
+ }
194
+ const innerContent = wrapWithAlertFrame(
195
+ this.alert
196
+ ? {
197
+ type: this.alertFrameType,
198
+ thickness: this.alertFrameThickness,
199
+ status: this.alertFrameStatus,
200
+ mode: this.alertFrameMode,
201
+ showIcon: this.showAlertIcon,
202
+ showAlertCategoryIcon: this.showAlertCategoryIcon,
203
+ }
204
+ : false,
205
+ content
206
+ );
207
+ if (this.positioning === AutomationButtonPositioning.symbol) {
190
208
  return html`<div
191
209
  class=${classMap({
192
210
  'symbol-wrapper': true,
193
211
  ['label-' + this.readoutPosition]: true,
194
212
  })}
195
213
  >
196
- ${content}
214
+ ${innerContent}
197
215
  </div> `;
198
216
  }
199
- return content;
217
+ return innerContent;
200
218
  }
201
219
 
202
220
  static override styles = unsafeCSS(compentStyle);
@@ -516,6 +516,28 @@ export const WithAlertCautionCompact: Story = {
516
516
  },
517
517
  };
518
518
 
519
+ export const WithAlertIsaCritical: Story = {
520
+ ...WithAlertAlarm,
521
+ args: {
522
+ type: TankType.atmospheric,
523
+ alert: true,
524
+ alertFrameStatus: ObcAlertFrameStatus.IsaCritical,
525
+ alertFrameType: ObcAlertFrameType.SmallSideFlip,
526
+ badgeAlert: AutomationButtonBadgeAlert.IsaCritical,
527
+ },
528
+ };
529
+
530
+ export const WithAlertIsaDiagnostic: Story = {
531
+ ...WithAlertAlarm,
532
+ args: {
533
+ type: TankType.atmospheric,
534
+ alert: true,
535
+ alertFrameStatus: ObcAlertFrameStatus.IsaDiagnostic,
536
+ alertFrameType: ObcAlertFrameType.Regular,
537
+ badgeAlert: AutomationButtonBadgeAlert.IsaDiagnostic,
538
+ },
539
+ };
540
+
519
541
  /**
520
542
  * Demonstrates `positioning="button"`: the tank host fills its parent
521
543
  * container (100% × 100%) with no P&ID anchor offset, so it behaves like a
@@ -30,10 +30,10 @@ import '../../building-blocks/bar-vertical/bar-vertical.js';
30
30
  import '../../components/alert-frame/alert-frame.js';
31
31
  import {Priority} from '../../navigation-instruments/types.js';
32
32
  import {
33
- ObcAlertFrameStatus,
34
33
  ObcAlertFrameThickness,
35
34
  ObcAlertFrameType,
36
35
  } from '../../components/alert-frame/alert-frame.js';
36
+ import {AlertType} from '../../types.js';
37
37
  import type {ChartLineDataItem} from '../../building-blocks/chart-line/chart-line-base.js';
38
38
  import type {LinearAdvice} from '../../building-blocks/instrument-linear/advice.js';
39
39
  import {
@@ -221,8 +221,7 @@ export class ObcAutomationTank extends LitElement {
221
221
  ObcAlertFrameType.SmallSideFlip;
222
222
  @property({type: String}) alertFrameThickness: ObcAlertFrameThickness =
223
223
  ObcAlertFrameThickness.Small;
224
- @property({type: String}) alertFrameStatus: ObcAlertFrameStatus =
225
- ObcAlertFrameStatus.Alarm;
224
+ @property({type: String}) alertFrameStatus: AlertType = AlertType.Alarm;
226
225
  @property({type: Boolean, attribute: false}) showAlertCategoryIcon: boolean =
227
226
  true;
228
227
  @property({type: Boolean}) showAlertIcon: boolean = false;
@@ -316,6 +315,16 @@ export class ObcAutomationTank extends LitElement {
316
315
  return ObcAutomationBadgeType.Warning;
317
316
  case AutomationButtonBadgeAlert.Alarm:
318
317
  return ObcAutomationBadgeType.Alarm;
318
+ case AutomationButtonBadgeAlert.IsaCritical:
319
+ return ObcAutomationBadgeType.IsaCritical;
320
+ case AutomationButtonBadgeAlert.IsaHigh:
321
+ return ObcAutomationBadgeType.IsaHigh;
322
+ case AutomationButtonBadgeAlert.IsaMedium:
323
+ return ObcAutomationBadgeType.IsaMedium;
324
+ case AutomationButtonBadgeAlert.IsaLow:
325
+ return ObcAutomationBadgeType.IsaLow;
326
+ case AutomationButtonBadgeAlert.IsaDiagnostic:
327
+ return ObcAutomationBadgeType.IsaDiagnostic;
319
328
  default:
320
329
  return null;
321
330
  }
@@ -21,6 +21,9 @@ const meta: Meta<typeof ObcInstrumentRadial> = {
21
21
  showLabels: {control: 'boolean'},
22
22
  minAngle: {control: false, table: {disable: true}},
23
23
  maxAngle: {control: false, table: {disable: true}},
24
+ // Only acts on labels at the horizontal ends (±90°), i.e. a 180° sweep.
25
+ // Hidden by default; the MaxMinEndLabels story re-enables it.
26
+ endLabelsMaxMin: {table: {disable: true}},
24
27
  },
25
28
  } satisfies Meta<ObcInstrumentRadial>;
26
29
 
@@ -92,6 +95,24 @@ export const WithLabels: Story = {
92
95
  },
93
96
  };
94
97
 
98
+ // `endLabelsMaxMin` only repositions labels at the horizontal ends (±90°). This
99
+ // 180° sweep puts the min/max labels there, so toggling `endLabelsMaxMin` (and
100
+ // `tickmarksInside`) visibly moves them below/centered.
101
+ export const MaxMinEndLabels: Story = {
102
+ args: {
103
+ value: 50,
104
+ maxValue: 100,
105
+ minValue: 0,
106
+ type: ObcGaugeRadialType.filled,
107
+ showLabels: true,
108
+ getAngle: (v: number) => (v / 100) * 180 - 90, // top 180° arc: 0 left, 100 right
109
+ endLabelsMaxMin: true,
110
+ },
111
+ argTypes: {
112
+ endLabelsMaxMin: {control: 'boolean', table: {disable: false}},
113
+ },
114
+ };
115
+
95
116
  export const WithAdvices: Story = {
96
117
  args: {
97
118
  value: 50,