@oicl/openbridge-webcomponents-full-bundle 2.0.0-next.133 → 2.0.0-next.134
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/bundle/openbridge-webcomponents.bundle.js +21 -3
- package/bundle/openbridge-webcomponents.bundle.js.map +1 -1
- package/custom-elements.json +3 -2
- package/dist/components/automation-button-readout-stack/automation-button-readout-stack.css.js +8 -1
- package/dist/components/automation-button-readout-stack/automation-button-readout-stack.css.js.map +1 -1
- package/dist/components/automation-button-readout-stack/automation-button-readout-stack.d.ts +6 -0
- package/dist/components/automation-button-readout-stack/automation-button-readout-stack.d.ts.map +1 -1
- package/dist/components/automation-button-readout-stack/automation-button-readout-stack.js +13 -2
- package/dist/components/automation-button-readout-stack/automation-button-readout-stack.js.map +1 -1
- package/package.json +1 -1
- package/src/components/automation-button-readout-stack/automation-button-readout-stack.css +9 -1
- package/src/components/automation-button-readout-stack/automation-button-readout-stack.ts +15 -2
|
@@ -15533,7 +15533,14 @@ const compentStyle$1d = i$7`* {
|
|
|
15533
15533
|
display: flex;
|
|
15534
15534
|
justify-content: center;
|
|
15535
15535
|
align-items: center;
|
|
15536
|
-
gap:
|
|
15536
|
+
gap: 0;
|
|
15537
|
+
}
|
|
15538
|
+
.readout-stack .value-text .hinted-zero {
|
|
15539
|
+
color: var(
|
|
15540
|
+
--obc-automation-button-readout-stack-hinted-color,
|
|
15541
|
+
var(--element-disabled-color)
|
|
15542
|
+
);
|
|
15543
|
+
font-weight: var(--global-typography-generic-l-font-weight-regular);
|
|
15537
15544
|
}
|
|
15538
15545
|
.readout-stack.small .readout-item {
|
|
15539
15546
|
font-family: var(--global-typography-font-family);
|
|
@@ -16497,10 +16504,17 @@ let ObcAutomationButtonReadoutStack = class extends i$4 {
|
|
|
16497
16504
|
renderValueText(text) {
|
|
16498
16505
|
return b`<span class="value-text">${text}</span>`;
|
|
16499
16506
|
}
|
|
16507
|
+
/**
|
|
16508
|
+
* Numeric readout with hinted zeros.
|
|
16509
|
+
*
|
|
16510
|
+
* The minus sign occupies a digit slot, so the readout stays `nDigits` wide
|
|
16511
|
+
* and the sign renders ahead of the hinted padding (`-05`, not `0-5`).
|
|
16512
|
+
*/
|
|
16500
16513
|
renderValue(readout) {
|
|
16501
16514
|
const v2 = readout.value.toFixed(0);
|
|
16515
|
+
const sign2 = v2.startsWith("-") ? "-" : "";
|
|
16516
|
+
const digits = sign2 ? v2.slice(1) : v2;
|
|
16502
16517
|
const zeroPadding = v2.length < readout.nDigits ? "0".repeat(readout.nDigits - v2.length) : "";
|
|
16503
|
-
const paddedValue = zeroPadding + v2;
|
|
16504
16518
|
let directionIcon = A;
|
|
16505
16519
|
if (readout.icon == "arrow") {
|
|
16506
16520
|
if (readout.direction == "up") {
|
|
@@ -16548,7 +16562,11 @@ let ObcAutomationButtonReadoutStack = class extends i$4 {
|
|
|
16548
16562
|
}
|
|
16549
16563
|
}
|
|
16550
16564
|
const content = b`
|
|
16551
|
-
|
|
16565
|
+
<span class="value-text"
|
|
16566
|
+
>${sign2}${zeroPadding ? b`<span class="hinted-zero" aria-hidden="true"
|
|
16567
|
+
>${zeroPadding}</span
|
|
16568
|
+
>` : A}${digits}</span
|
|
16569
|
+
>
|
|
16552
16570
|
<span class="unit">${readout.unit}</span>
|
|
16553
16571
|
`;
|
|
16554
16572
|
return this.renderValueContainer("value", directionIcon, content);
|