@oicl/openbridge-webcomponents-svelte 2.0.0-next.81 → 2.0.0-next.83
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/dist/ar/poi/ObcPoiAton.svelte +31 -2
- package/dist/ar/poi/ObcPoiAton.svelte.d.ts +33 -0
- package/dist/ar/poi/ObcPoiData.svelte +31 -2
- package/dist/ar/poi/ObcPoiData.svelte.d.ts +33 -0
- package/dist/ar/poi/ObcPoiVessel.svelte +31 -2
- package/dist/ar/poi/ObcPoiVessel.svelte.d.ts +33 -0
- package/dist/ar/poi-button/ObcPoiButtonAton.svelte +16 -2
- package/dist/ar/poi-button/ObcPoiButtonAton.svelte.d.ts +18 -0
- package/dist/ar/poi-button/ObcPoiButtonData.svelte +16 -2
- package/dist/ar/poi-button/ObcPoiButtonData.svelte.d.ts +18 -0
- package/dist/ar/poi-button/ObcPoiButtonVessel.svelte +16 -2
- package/dist/ar/poi-button/ObcPoiButtonVessel.svelte.d.ts +18 -0
- package/dist/ar/poi-object/ObcPoiObjectAton.svelte +8 -4
- package/dist/ar/poi-object/ObcPoiObjectAton.svelte.d.ts +7 -3
- package/dist/ar/poi-object/ObcPoiObjectData.svelte +5 -2
- package/dist/ar/poi-object/ObcPoiObjectData.svelte.d.ts +6 -1
- package/dist/ar/poi-object/ObcPoiObjectVessel.svelte +7 -2
- package/dist/ar/poi-object/ObcPoiObjectVessel.svelte.d.ts +6 -0
- package/dist/automation/analog-valve/ObcAnalogValve.svelte +32 -2
- package/dist/automation/analog-valve/ObcAnalogValve.svelte.d.ts +38 -1
- package/dist/automation/automation-button/ObcAbstractAutomationButtonMotorized.svelte +32 -2
- package/dist/automation/automation-button/ObcAbstractAutomationButtonMotorized.svelte.d.ts +38 -1
- package/dist/automation/automation-button/ObcAbstractAutomationButtonSquared.svelte +34 -4
- package/dist/automation/automation-button/ObcAbstractAutomationButtonSquared.svelte.d.ts +39 -2
- package/dist/automation/bipolar-transistor/ObcBipolarTransistor.svelte +39 -2
- package/dist/automation/bipolar-transistor/ObcBipolarTransistor.svelte.d.ts +44 -0
- package/dist/automation/capacitor/ObcCapacitor.svelte +39 -2
- package/dist/automation/capacitor/ObcCapacitor.svelte.d.ts +44 -0
- package/dist/automation/converter/ObcConverter.svelte +39 -2
- package/dist/automation/converter/ObcConverter.svelte.d.ts +44 -0
- package/dist/automation/damper/ObcDamper.svelte +37 -3
- package/dist/automation/damper/ObcDamper.svelte.d.ts +46 -1
- package/dist/automation/digital-valve/ObcDigitalValve.svelte +34 -2
- package/dist/automation/digital-valve/ObcDigitalValve.svelte.d.ts +38 -0
- package/dist/automation/diodes/ObcDiodes.svelte +39 -2
- package/dist/automation/diodes/ObcDiodes.svelte.d.ts +44 -0
- package/dist/automation/fan/ObcFan.svelte +42 -3
- package/dist/automation/fan/ObcFan.svelte.d.ts +52 -1
- package/dist/automation/filter/ObcFilter.svelte +39 -2
- package/dist/automation/filter/ObcFilter.svelte.d.ts +44 -0
- package/dist/automation/ground/ObcGround.svelte +39 -2
- package/dist/automation/ground/ObcGround.svelte.d.ts +44 -0
- package/dist/automation/logic/ObcLogic.svelte +39 -2
- package/dist/automation/logic/ObcLogic.svelte.d.ts +44 -0
- package/dist/automation/mosfet/ObcMosfet.svelte +39 -2
- package/dist/automation/mosfet/ObcMosfet.svelte.d.ts +44 -0
- package/dist/automation/motor/ObcMotor.svelte +42 -2
- package/dist/automation/motor/ObcMotor.svelte.d.ts +52 -1
- package/dist/automation/pump/ObcPump.svelte +42 -2
- package/dist/automation/pump/ObcPump.svelte.d.ts +52 -1
- package/dist/automation/resistor/ObcResistor.svelte +39 -2
- package/dist/automation/resistor/ObcResistor.svelte.d.ts +44 -0
- package/dist/automation/router/ObcRouter.svelte +39 -2
- package/dist/automation/router/ObcRouter.svelte.d.ts +44 -0
- package/dist/automation/source/ObcSource.svelte +39 -2
- package/dist/automation/source/ObcSource.svelte.d.ts +44 -0
- package/dist/automation/switch/ObcSwitch.svelte +39 -2
- package/dist/automation/switch/ObcSwitch.svelte.d.ts +44 -0
- package/dist/automation/transformer/ObcTransformer.svelte +39 -2
- package/dist/automation/transformer/ObcTransformer.svelte.d.ts +44 -0
- package/dist/bars-graphs/area-graph/ObcAreaGraph.svelte +99 -2
- package/dist/bars-graphs/area-graph/ObcAreaGraph.svelte.d.ts +108 -0
- package/dist/bars-graphs/line-graph/ObcLineGraph.svelte +97 -3
- package/dist/bars-graphs/line-graph/ObcLineGraph.svelte.d.ts +110 -1
- package/dist/building-blocks/bar-horizontal/ObcBarHorizontal.svelte +21 -0
- package/dist/building-blocks/bar-horizontal/ObcBarHorizontal.svelte.d.ts +21 -0
- package/dist/building-blocks/bar-vertical/ObcBarVertical.svelte +21 -0
- package/dist/building-blocks/bar-vertical/ObcBarVertical.svelte.d.ts +21 -0
- package/dist/building-blocks/instrument-radial/ObcInstrumentRadial.svelte +21 -0
- package/dist/building-blocks/instrument-radial/ObcInstrumentRadial.svelte.d.ts +21 -0
- package/dist/components/progress-bar/ObcProgressBar.svelte +34 -16
- package/dist/components/progress-bar/ObcProgressBar.svelte.d.ts +17 -1
- package/dist/components/progress-button/ObcProgressButton.svelte +49 -21
- package/dist/components/progress-button/ObcProgressButton.svelte.d.ts +18 -2
- package/dist/navigation-instruments/gauge-horizontal/ObcGaugeHorizontal.svelte +21 -0
- package/dist/navigation-instruments/gauge-horizontal/ObcGaugeHorizontal.svelte.d.ts +21 -0
- package/dist/navigation-instruments/gauge-radial/ObcGaugeRadial.svelte +21 -0
- package/dist/navigation-instruments/gauge-radial/ObcGaugeRadial.svelte.d.ts +21 -0
- package/dist/navigation-instruments/gauge-trend/ObcGaugeTrend.svelte +120 -2
- package/dist/navigation-instruments/gauge-trend/ObcGaugeTrend.svelte.d.ts +129 -0
- package/dist/navigation-instruments/gauge-vertical/ObcGaugeVertical.svelte +21 -0
- package/dist/navigation-instruments/gauge-vertical/ObcGaugeVertical.svelte.d.ts +21 -0
- package/dist/navigation-instruments/pitch/ObcPitch.svelte +21 -2
- package/dist/navigation-instruments/pitch/ObcPitch.svelte.d.ts +19 -0
- package/dist/navigation-instruments/roll/ObcRoll.svelte +21 -2
- package/dist/navigation-instruments/roll/ObcRoll.svelte.d.ts +19 -0
- package/dist/navigation-instruments/rot-sector/ObcRotSector.svelte +21 -0
- package/dist/navigation-instruments/rot-sector/ObcRotSector.svelte.d.ts +21 -0
- package/dist/navigation-instruments/rudder/ObcRudder.svelte +21 -0
- package/dist/navigation-instruments/rudder/ObcRudder.svelte.d.ts +21 -0
- package/dist/navigation-instruments/speed-gauge/ObcSpeedGauge.svelte +21 -0
- package/dist/navigation-instruments/speed-gauge/ObcSpeedGauge.svelte.d.ts +21 -0
- package/dist/navigation-instruments/thruster/ObcThruster.svelte +21 -0
- package/dist/navigation-instruments/thruster/ObcThruster.svelte.d.ts +21 -0
- package/package.json +2 -2
|
@@ -13,6 +13,27 @@ import type {TickmarkStyle} from '@oicl/openbridge-webcomponents/dist/navigation
|
|
|
13
13
|
export interface Props {
|
|
14
14
|
class?: string;
|
|
15
15
|
style?: string;
|
|
16
|
+
/** Target setpoint value. `undefined` = no setpoint marker shown. */
|
|
17
|
+
setpoint?: number | undefined;
|
|
18
|
+
/** Adjustment preview for 2-step interface.
|
|
19
|
+
When defined, two markers are shown: original (dimmed) + new (focus). */
|
|
20
|
+
newSetpoint?: number | undefined;
|
|
21
|
+
/** Manual at-setpoint override (used when `autoAtSetpoint` is false). */
|
|
22
|
+
atSetpoint?: boolean;
|
|
23
|
+
/** User is physically interacting with the control.
|
|
24
|
+
Suppresses at-setpoint calculation and triggers focus visual. */
|
|
25
|
+
touching?: boolean;
|
|
26
|
+
/** When false, uses manual `atSetpoint` boolean instead of auto-calculation. */
|
|
27
|
+
autoAtSetpoint?: boolean;
|
|
28
|
+
/** Tolerance for auto at-setpoint detection. */
|
|
29
|
+
autoAtSetpointDeadband?: number;
|
|
30
|
+
/** Tolerance for zero-snap visual state. */
|
|
31
|
+
setpointAtZeroDeadband?: number;
|
|
32
|
+
/** Override to derive the setpoint color from the instrument's `priority`
|
|
33
|
+
regardless of instrument state. */
|
|
34
|
+
setpointOverride?: boolean;
|
|
35
|
+
/** Enable CSS-animated confirm transition. */
|
|
36
|
+
animateSetpoint?: boolean;
|
|
16
37
|
state?: InstrumentState;
|
|
17
38
|
priority?: Priority;
|
|
18
39
|
value?: number;
|
|
@@ -6,6 +6,27 @@ import type { Snippet } from 'svelte';
|
|
|
6
6
|
export interface Props {
|
|
7
7
|
class?: string;
|
|
8
8
|
style?: string;
|
|
9
|
+
/** Target setpoint value. `undefined` = no setpoint marker shown. */
|
|
10
|
+
setpoint?: number | undefined;
|
|
11
|
+
/** Adjustment preview for 2-step interface.
|
|
12
|
+
When defined, two markers are shown: original (dimmed) + new (focus). */
|
|
13
|
+
newSetpoint?: number | undefined;
|
|
14
|
+
/** Manual at-setpoint override (used when `autoAtSetpoint` is false). */
|
|
15
|
+
atSetpoint?: boolean;
|
|
16
|
+
/** User is physically interacting with the control.
|
|
17
|
+
Suppresses at-setpoint calculation and triggers focus visual. */
|
|
18
|
+
touching?: boolean;
|
|
19
|
+
/** When false, uses manual `atSetpoint` boolean instead of auto-calculation. */
|
|
20
|
+
autoAtSetpoint?: boolean;
|
|
21
|
+
/** Tolerance for auto at-setpoint detection. */
|
|
22
|
+
autoAtSetpointDeadband?: number;
|
|
23
|
+
/** Tolerance for zero-snap visual state. */
|
|
24
|
+
setpointAtZeroDeadband?: number;
|
|
25
|
+
/** Override to derive the setpoint color from the instrument's `priority`
|
|
26
|
+
regardless of instrument state. */
|
|
27
|
+
setpointOverride?: boolean;
|
|
28
|
+
/** Enable CSS-animated confirm transition. */
|
|
29
|
+
animateSetpoint?: boolean;
|
|
9
30
|
state?: InstrumentState;
|
|
10
31
|
priority?: Priority;
|
|
11
32
|
value?: number;
|
|
@@ -9,25 +9,41 @@
|
|
|
9
9
|
export interface Props {
|
|
10
10
|
class?: string;
|
|
11
11
|
style?: string;
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
12
|
+
/** Layout type: `linear` (horizontal bar) or `circular` (ring). */
|
|
13
|
+
type?: ProgressBarType;
|
|
14
|
+
/** Progress mode: `determinate` tracks `value`, `indeterminate` loops indefinitely. */
|
|
15
|
+
mode?: ProgressBarMode;
|
|
16
|
+
/** Circular display state: `determinate` (numeric ring), `indeterminate` (animated ring with
|
|
17
|
+
icon), or `icon` (ring framing the icon slot). */
|
|
18
|
+
circularState?: CircularProgressState;
|
|
19
|
+
/** Progress percentage (0–100); clamped when rendered. */
|
|
20
|
+
value?: number;
|
|
21
|
+
/** Shows the value label above the bar (percentage when determinate, "Loading" when indeterminate). */
|
|
22
|
+
showValue?: boolean;
|
|
23
|
+
/** Appends a `%` unit next to the centered value. */
|
|
24
|
+
showUnit?: boolean;
|
|
25
|
+
/** Shows the `description` text below the bar. */
|
|
26
|
+
hasDescription?: boolean;
|
|
27
|
+
/** Description text rendered below the bar. */
|
|
28
|
+
description?: string;
|
|
29
|
+
/** Shows the `stateLabel` next to the value.
|
|
30
|
+
|
|
31
|
+
**TODO(designer):** Confirm the intended purpose of the state indicator — the story labels
|
|
32
|
+
this a "future feature". */
|
|
33
|
+
showState?: boolean;
|
|
34
|
+
/** Text shown alongside the value when `showState` is enabled. */
|
|
35
|
+
stateLabel?: string;
|
|
36
|
+
/** Uses a progressive indeterminate ring (spinning arc that grows with `value`); takes
|
|
37
|
+
precedence over `circularState`. */
|
|
38
|
+
progressiveIndeterminate?: boolean
|
|
23
39
|
}
|
|
24
40
|
export interface Events {
|
|
25
41
|
|
|
26
42
|
}
|
|
27
43
|
export interface Slots {
|
|
28
|
-
|
|
44
|
+
icon?: Snippet
|
|
29
45
|
}
|
|
30
|
-
const { class: className, style,
|
|
46
|
+
const { class: className, style, icon, ...props} = $props<Props & Events & Slots>();
|
|
31
47
|
|
|
32
48
|
</script>
|
|
33
49
|
<obc-progress-bar
|
|
@@ -36,7 +52,9 @@
|
|
|
36
52
|
style={style}
|
|
37
53
|
>
|
|
38
54
|
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
55
|
+
{#if icon}
|
|
56
|
+
<div slot="icon">
|
|
57
|
+
{@render icon()}
|
|
58
|
+
</div>
|
|
59
|
+
{/if}
|
|
42
60
|
</obc-progress-bar>
|
|
@@ -4,22 +4,38 @@ import type { Snippet } from 'svelte';
|
|
|
4
4
|
export interface Props {
|
|
5
5
|
class?: string;
|
|
6
6
|
style?: string;
|
|
7
|
+
/** Layout type: `linear` (horizontal bar) or `circular` (ring). */
|
|
7
8
|
type?: ProgressBarType;
|
|
9
|
+
/** Progress mode: `determinate` tracks `value`, `indeterminate` loops indefinitely. */
|
|
8
10
|
mode?: ProgressBarMode;
|
|
11
|
+
/** Circular display state: `determinate` (numeric ring), `indeterminate` (animated ring with
|
|
12
|
+
icon), or `icon` (ring framing the icon slot). */
|
|
9
13
|
circularState?: CircularProgressState;
|
|
14
|
+
/** Progress percentage (0–100); clamped when rendered. */
|
|
10
15
|
value?: number;
|
|
16
|
+
/** Shows the value label above the bar (percentage when determinate, "Loading" when indeterminate). */
|
|
11
17
|
showValue?: boolean;
|
|
18
|
+
/** Appends a `%` unit next to the centered value. */
|
|
12
19
|
showUnit?: boolean;
|
|
20
|
+
/** Shows the `description` text below the bar. */
|
|
13
21
|
hasDescription?: boolean;
|
|
22
|
+
/** Description text rendered below the bar. */
|
|
14
23
|
description?: string;
|
|
24
|
+
/** Shows the `stateLabel` next to the value.
|
|
25
|
+
|
|
26
|
+
**TODO(designer):** Confirm the intended purpose of the state indicator — the story labels
|
|
27
|
+
this a "future feature". */
|
|
15
28
|
showState?: boolean;
|
|
29
|
+
/** Text shown alongside the value when `showState` is enabled. */
|
|
16
30
|
stateLabel?: string;
|
|
31
|
+
/** Uses a progressive indeterminate ring (spinning arc that grows with `value`); takes
|
|
32
|
+
precedence over `circularState`. */
|
|
17
33
|
progressiveIndeterminate?: boolean;
|
|
18
34
|
}
|
|
19
35
|
export interface Events {
|
|
20
36
|
}
|
|
21
37
|
export interface Slots {
|
|
22
|
-
|
|
38
|
+
icon?: Snippet;
|
|
23
39
|
}
|
|
24
40
|
type $$ComponentProps = Props & Events & Slots;
|
|
25
41
|
declare const ObcProgressBar: import("svelte").Component<$$ComponentProps, {
|
|
@@ -1,43 +1,71 @@
|
|
|
1
1
|
|
|
2
2
|
<script lang="ts">
|
|
3
|
-
export type {ProgressButtonType, ButtonStyle, ProgressMode} from '@oicl/openbridge-webcomponents/dist/components/progress-button/progress-button.js';
|
|
3
|
+
export type {ProgressButtonClickEvent, ProgressButtonType, ButtonStyle, ProgressMode} from '@oicl/openbridge-webcomponents/dist/components/progress-button/progress-button.js';
|
|
4
4
|
import '@oicl/openbridge-webcomponents/dist/components/progress-button/progress-button.js';
|
|
5
5
|
import { setProperties } from "../../util.js";
|
|
6
|
-
import type {ProgressButtonType, ButtonStyle, ProgressMode} from '@oicl/openbridge-webcomponents/dist/components/progress-button/progress-button.js';
|
|
6
|
+
import type {ProgressButtonClickEvent, ProgressButtonType, ButtonStyle, ProgressMode} from '@oicl/openbridge-webcomponents/dist/components/progress-button/progress-button.js';
|
|
7
7
|
import type { Snippet } from 'svelte';
|
|
8
8
|
|
|
9
9
|
export interface Props {
|
|
10
10
|
class?: string;
|
|
11
11
|
style?: string;
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
12
|
+
/** Layout type of the button: `linear` (label + bar) or `circular` (icon + ring). */
|
|
13
|
+
type?: ProgressButtonType;
|
|
14
|
+
/** Elevation style of the button surface. */
|
|
15
|
+
buttonStyle?: ButtonStyle;
|
|
16
|
+
/** Progress mode: `determinate` tracks `value`, `indeterminate` loops indefinitely. */
|
|
17
|
+
mode?: ProgressMode;
|
|
18
|
+
/** Progress percentage (0–100); clamped when rendered. */
|
|
19
|
+
value?: number;
|
|
20
|
+
/** Text shown in the button (linear) or below it (circular, when `showLabel`). */
|
|
21
|
+
label?: string;
|
|
22
|
+
/** Blocks interaction and suppresses the `obc-click` event. */
|
|
23
|
+
disabled?: boolean;
|
|
24
|
+
/** Reveals the progress bar/ring. */
|
|
25
|
+
showProgress?: boolean;
|
|
26
|
+
/** Renders the `leading-icon` slot. */
|
|
27
|
+
hasLeadingIcon?: boolean;
|
|
28
|
+
/** Renders the `trailing-icon` slot. */
|
|
29
|
+
hasTrailingIcon?: boolean;
|
|
30
|
+
/** Shows an alert (error) ring/border around the button. */
|
|
31
|
+
hasAlert?: boolean;
|
|
32
|
+
/** Uses a progressive indeterminate ring that animates while advancing toward `value`. */
|
|
33
|
+
progressiveIndeterminate?: boolean;
|
|
34
|
+
/** Shows the `label` below the circular button. */
|
|
35
|
+
showLabel?: boolean
|
|
24
36
|
}
|
|
25
37
|
export interface Events {
|
|
26
|
-
|
|
38
|
+
onObcClick?: (event: CustomEvent<ProgressButtonClickEvent>) => void
|
|
27
39
|
}
|
|
28
40
|
export interface Slots {
|
|
29
|
-
|
|
41
|
+
leadingIcon?: Snippet;
|
|
42
|
+
trailingIcon?: Snippet;
|
|
43
|
+
icon?: Snippet
|
|
30
44
|
}
|
|
31
|
-
const { class: className, style,
|
|
45
|
+
const {onObcClick, class: className, style, leadingIcon, trailingIcon, icon, ...props} = $props<Props & Events & Slots>();
|
|
32
46
|
|
|
33
47
|
</script>
|
|
34
48
|
<obc-progress-button
|
|
35
49
|
use:setProperties={props}
|
|
36
50
|
class={className}
|
|
37
51
|
style={style}
|
|
38
|
-
|
|
52
|
+
onobc-click={onObcClick} >
|
|
39
53
|
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
54
|
+
{#if leadingIcon}
|
|
55
|
+
<div slot="leading-icon">
|
|
56
|
+
{@render leadingIcon()}
|
|
57
|
+
</div>
|
|
58
|
+
{/if}
|
|
59
|
+
|
|
60
|
+
{#if trailingIcon}
|
|
61
|
+
<div slot="trailing-icon">
|
|
62
|
+
{@render trailingIcon()}
|
|
63
|
+
</div>
|
|
64
|
+
{/if}
|
|
65
|
+
|
|
66
|
+
{#if icon}
|
|
67
|
+
<div slot="icon">
|
|
68
|
+
{@render icon()}
|
|
69
|
+
</div>
|
|
70
|
+
{/if}
|
|
43
71
|
</obc-progress-button>
|
|
@@ -1,29 +1,45 @@
|
|
|
1
1
|
import '@oicl/openbridge-webcomponents/dist/components/progress-button/progress-button.js';
|
|
2
|
-
import type { ProgressButtonType, ButtonStyle, ProgressMode } from '@oicl/openbridge-webcomponents/dist/components/progress-button/progress-button.js';
|
|
2
|
+
import type { ProgressButtonClickEvent, ProgressButtonType, ButtonStyle, ProgressMode } from '@oicl/openbridge-webcomponents/dist/components/progress-button/progress-button.js';
|
|
3
3
|
import type { Snippet } from 'svelte';
|
|
4
4
|
export interface Props {
|
|
5
5
|
class?: string;
|
|
6
6
|
style?: string;
|
|
7
|
+
/** Layout type of the button: `linear` (label + bar) or `circular` (icon + ring). */
|
|
7
8
|
type?: ProgressButtonType;
|
|
9
|
+
/** Elevation style of the button surface. */
|
|
8
10
|
buttonStyle?: ButtonStyle;
|
|
11
|
+
/** Progress mode: `determinate` tracks `value`, `indeterminate` loops indefinitely. */
|
|
9
12
|
mode?: ProgressMode;
|
|
13
|
+
/** Progress percentage (0–100); clamped when rendered. */
|
|
10
14
|
value?: number;
|
|
15
|
+
/** Text shown in the button (linear) or below it (circular, when `showLabel`). */
|
|
11
16
|
label?: string;
|
|
17
|
+
/** Blocks interaction and suppresses the `obc-click` event. */
|
|
12
18
|
disabled?: boolean;
|
|
19
|
+
/** Reveals the progress bar/ring. */
|
|
13
20
|
showProgress?: boolean;
|
|
21
|
+
/** Renders the `leading-icon` slot. */
|
|
14
22
|
hasLeadingIcon?: boolean;
|
|
23
|
+
/** Renders the `trailing-icon` slot. */
|
|
15
24
|
hasTrailingIcon?: boolean;
|
|
25
|
+
/** Shows an alert (error) ring/border around the button. */
|
|
16
26
|
hasAlert?: boolean;
|
|
27
|
+
/** Uses a progressive indeterminate ring that animates while advancing toward `value`. */
|
|
17
28
|
progressiveIndeterminate?: boolean;
|
|
29
|
+
/** Shows the `label` below the circular button. */
|
|
18
30
|
showLabel?: boolean;
|
|
19
31
|
}
|
|
20
32
|
export interface Events {
|
|
33
|
+
onObcClick?: (event: CustomEvent<ProgressButtonClickEvent>) => void;
|
|
21
34
|
}
|
|
22
35
|
export interface Slots {
|
|
23
|
-
|
|
36
|
+
leadingIcon?: Snippet;
|
|
37
|
+
trailingIcon?: Snippet;
|
|
38
|
+
icon?: Snippet;
|
|
24
39
|
}
|
|
25
40
|
type $$ComponentProps = Props & Events & Slots;
|
|
26
41
|
declare const ObcProgressButton: import("svelte").Component<$$ComponentProps, {
|
|
42
|
+
ProgressButtonClickEvent: typeof ProgressButtonClickEvent;
|
|
27
43
|
ProgressButtonType: typeof ProgressButtonType;
|
|
28
44
|
ButtonStyle: typeof ButtonStyle;
|
|
29
45
|
ProgressMode: typeof ProgressMode;
|
|
@@ -13,6 +13,27 @@ import type {LinearAdvice} from '@oicl/openbridge-webcomponents/dist/building-bl
|
|
|
13
13
|
export interface Props {
|
|
14
14
|
class?: string;
|
|
15
15
|
style?: string;
|
|
16
|
+
/** Target setpoint value. `undefined` = no setpoint marker shown. */
|
|
17
|
+
setpoint?: number | undefined;
|
|
18
|
+
/** Adjustment preview for 2-step interface.
|
|
19
|
+
When defined, two markers are shown: original (dimmed) + new (focus). */
|
|
20
|
+
newSetpoint?: number | undefined;
|
|
21
|
+
/** Manual at-setpoint override (used when `autoAtSetpoint` is false). */
|
|
22
|
+
atSetpoint?: boolean;
|
|
23
|
+
/** User is physically interacting with the control.
|
|
24
|
+
Suppresses at-setpoint calculation and triggers focus visual. */
|
|
25
|
+
touching?: boolean;
|
|
26
|
+
/** When false, uses manual `atSetpoint` boolean instead of auto-calculation. */
|
|
27
|
+
autoAtSetpoint?: boolean;
|
|
28
|
+
/** Tolerance for auto at-setpoint detection. */
|
|
29
|
+
autoAtSetpointDeadband?: number;
|
|
30
|
+
/** Tolerance for zero-snap visual state. */
|
|
31
|
+
setpointAtZeroDeadband?: number;
|
|
32
|
+
/** Override to derive the setpoint color from the instrument's `priority`
|
|
33
|
+
regardless of instrument state. */
|
|
34
|
+
setpointOverride?: boolean;
|
|
35
|
+
/** Enable CSS-animated confirm transition. */
|
|
36
|
+
animateSetpoint?: boolean;
|
|
16
37
|
/** Minimum scale value */
|
|
17
38
|
minValue?: number;
|
|
18
39
|
/** Maximum scale value */
|
|
@@ -6,6 +6,27 @@ import type { Snippet } from 'svelte';
|
|
|
6
6
|
export interface Props {
|
|
7
7
|
class?: string;
|
|
8
8
|
style?: string;
|
|
9
|
+
/** Target setpoint value. `undefined` = no setpoint marker shown. */
|
|
10
|
+
setpoint?: number | undefined;
|
|
11
|
+
/** Adjustment preview for 2-step interface.
|
|
12
|
+
When defined, two markers are shown: original (dimmed) + new (focus). */
|
|
13
|
+
newSetpoint?: number | undefined;
|
|
14
|
+
/** Manual at-setpoint override (used when `autoAtSetpoint` is false). */
|
|
15
|
+
atSetpoint?: boolean;
|
|
16
|
+
/** User is physically interacting with the control.
|
|
17
|
+
Suppresses at-setpoint calculation and triggers focus visual. */
|
|
18
|
+
touching?: boolean;
|
|
19
|
+
/** When false, uses manual `atSetpoint` boolean instead of auto-calculation. */
|
|
20
|
+
autoAtSetpoint?: boolean;
|
|
21
|
+
/** Tolerance for auto at-setpoint detection. */
|
|
22
|
+
autoAtSetpointDeadband?: number;
|
|
23
|
+
/** Tolerance for zero-snap visual state. */
|
|
24
|
+
setpointAtZeroDeadband?: number;
|
|
25
|
+
/** Override to derive the setpoint color from the instrument's `priority`
|
|
26
|
+
regardless of instrument state. */
|
|
27
|
+
setpointOverride?: boolean;
|
|
28
|
+
/** Enable CSS-animated confirm transition. */
|
|
29
|
+
animateSetpoint?: boolean;
|
|
9
30
|
/** Minimum scale value */
|
|
10
31
|
minValue?: number;
|
|
11
32
|
/** Maximum scale value */
|
|
@@ -13,6 +13,27 @@ import type {TickmarkStyle} from '@oicl/openbridge-webcomponents/dist/navigation
|
|
|
13
13
|
export interface Props {
|
|
14
14
|
class?: string;
|
|
15
15
|
style?: string;
|
|
16
|
+
/** Target setpoint value. `undefined` = no setpoint marker shown. */
|
|
17
|
+
setpoint?: number | undefined;
|
|
18
|
+
/** Adjustment preview for 2-step interface.
|
|
19
|
+
When defined, two markers are shown: original (dimmed) + new (focus). */
|
|
20
|
+
newSetpoint?: number | undefined;
|
|
21
|
+
/** Manual at-setpoint override (used when `autoAtSetpoint` is false). */
|
|
22
|
+
atSetpoint?: boolean;
|
|
23
|
+
/** User is physically interacting with the control.
|
|
24
|
+
Suppresses at-setpoint calculation and triggers focus visual. */
|
|
25
|
+
touching?: boolean;
|
|
26
|
+
/** When false, uses manual `atSetpoint` boolean instead of auto-calculation. */
|
|
27
|
+
autoAtSetpoint?: boolean;
|
|
28
|
+
/** Tolerance for auto at-setpoint detection. */
|
|
29
|
+
autoAtSetpointDeadband?: number;
|
|
30
|
+
/** Tolerance for zero-snap visual state. */
|
|
31
|
+
setpointAtZeroDeadband?: number;
|
|
32
|
+
/** Override to derive the setpoint color from the instrument's `priority`
|
|
33
|
+
regardless of instrument state. */
|
|
34
|
+
setpointOverride?: boolean;
|
|
35
|
+
/** Enable CSS-animated confirm transition. */
|
|
36
|
+
animateSetpoint?: boolean;
|
|
16
37
|
value?: number;
|
|
17
38
|
maxValue?: number;
|
|
18
39
|
minValue?: number;
|
|
@@ -6,6 +6,27 @@ import type { Snippet } from 'svelte';
|
|
|
6
6
|
export interface Props {
|
|
7
7
|
class?: string;
|
|
8
8
|
style?: string;
|
|
9
|
+
/** Target setpoint value. `undefined` = no setpoint marker shown. */
|
|
10
|
+
setpoint?: number | undefined;
|
|
11
|
+
/** Adjustment preview for 2-step interface.
|
|
12
|
+
When defined, two markers are shown: original (dimmed) + new (focus). */
|
|
13
|
+
newSetpoint?: number | undefined;
|
|
14
|
+
/** Manual at-setpoint override (used when `autoAtSetpoint` is false). */
|
|
15
|
+
atSetpoint?: boolean;
|
|
16
|
+
/** User is physically interacting with the control.
|
|
17
|
+
Suppresses at-setpoint calculation and triggers focus visual. */
|
|
18
|
+
touching?: boolean;
|
|
19
|
+
/** When false, uses manual `atSetpoint` boolean instead of auto-calculation. */
|
|
20
|
+
autoAtSetpoint?: boolean;
|
|
21
|
+
/** Tolerance for auto at-setpoint detection. */
|
|
22
|
+
autoAtSetpointDeadband?: number;
|
|
23
|
+
/** Tolerance for zero-snap visual state. */
|
|
24
|
+
setpointAtZeroDeadband?: number;
|
|
25
|
+
/** Override to derive the setpoint color from the instrument's `priority`
|
|
26
|
+
regardless of instrument state. */
|
|
27
|
+
setpointOverride?: boolean;
|
|
28
|
+
/** Enable CSS-animated confirm transition. */
|
|
29
|
+
animateSetpoint?: boolean;
|
|
9
30
|
value?: number;
|
|
10
31
|
maxValue?: number;
|
|
11
32
|
minValue?: number;
|
|
@@ -1,16 +1,134 @@
|
|
|
1
1
|
|
|
2
2
|
<script lang="ts">
|
|
3
|
-
export type {
|
|
3
|
+
export type {ChartLineDataItem, XAxisType, YAxisPosition, ChartLineYAxisConfig, LineMode, TimeDisplay} from '@oicl/openbridge-webcomponents/dist/building-blocks/chart-line/chart-line-base.js';
|
|
4
|
+
export type {ChartDataset} from 'chart.js';
|
|
5
|
+
export type {InstrumentState, Priority, FrameStyle, BorderRadiusPosition} from '@oicl/openbridge-webcomponents/dist/navigation-instruments/types.js';
|
|
6
|
+
export type {ScaleType, FillMode} from '@oicl/openbridge-webcomponents/dist/building-blocks/bar-vertical/bar-vertical.js';
|
|
4
7
|
export type {LinearAdvice} from '@oicl/openbridge-webcomponents/dist/building-blocks/instrument-linear/advice.js';
|
|
5
8
|
import '@oicl/openbridge-webcomponents/dist/navigation-instruments/gauge-trend/gauge-trend.js';
|
|
6
9
|
import { setProperties } from "../../util.js";
|
|
7
|
-
import type {
|
|
10
|
+
import type {ChartLineDataItem, XAxisType, YAxisPosition, ChartLineYAxisConfig, LineMode, TimeDisplay} from '@oicl/openbridge-webcomponents/dist/building-blocks/chart-line/chart-line-base.js';
|
|
11
|
+
import type {ChartDataset} from 'chart.js';
|
|
12
|
+
import type {InstrumentState, Priority, FrameStyle, BorderRadiusPosition} from '@oicl/openbridge-webcomponents/dist/navigation-instruments/types.js';
|
|
13
|
+
import type {ScaleType, FillMode} from '@oicl/openbridge-webcomponents/dist/building-blocks/bar-vertical/bar-vertical.js';
|
|
8
14
|
import type {LinearAdvice} from '@oicl/openbridge-webcomponents/dist/building-blocks/instrument-linear/advice.js';
|
|
9
15
|
import type { Snippet } from 'svelte';
|
|
10
16
|
|
|
11
17
|
export interface Props {
|
|
12
18
|
class?: string;
|
|
13
19
|
style?: string;
|
|
20
|
+
/** Target setpoint value. `undefined` = no setpoint marker shown. */
|
|
21
|
+
setpoint?: number | undefined;
|
|
22
|
+
/** Adjustment preview for 2-step interface.
|
|
23
|
+
When defined, two markers are shown: original (dimmed) + new (focus). */
|
|
24
|
+
newSetpoint?: number | undefined;
|
|
25
|
+
/** Manual at-setpoint override (used when `autoAtSetpoint` is false). */
|
|
26
|
+
atSetpoint?: boolean;
|
|
27
|
+
/** User is physically interacting with the control.
|
|
28
|
+
Suppresses at-setpoint calculation and triggers focus visual. */
|
|
29
|
+
touching?: boolean;
|
|
30
|
+
/** When false, uses manual `atSetpoint` boolean instead of auto-calculation. */
|
|
31
|
+
autoAtSetpoint?: boolean;
|
|
32
|
+
/** Tolerance for auto at-setpoint detection. */
|
|
33
|
+
autoAtSetpointDeadband?: number;
|
|
34
|
+
/** Tolerance for zero-snap visual state. */
|
|
35
|
+
setpointAtZeroDeadband?: number;
|
|
36
|
+
/** Override to derive the setpoint color from the instrument's `priority`
|
|
37
|
+
regardless of instrument state. */
|
|
38
|
+
setpointOverride?: boolean;
|
|
39
|
+
/** Enable CSS-animated confirm transition. */
|
|
40
|
+
animateSetpoint?: boolean;
|
|
41
|
+
/** Simple single-series data (array of {label, value}). */
|
|
42
|
+
data?: ChartLineDataItem[];
|
|
43
|
+
/** Chart.js-style datasets for multi-series use. If provided, takes precedence over `data`. */
|
|
44
|
+
datasets?: ChartDataset<"line", (number | { x: string | number | Date; y: number; })[]>[] | undefined;
|
|
45
|
+
/** Optional explicit labels for the x-axis (category mode). If omitted labels are derived from `data` */
|
|
46
|
+
labels?: (string | number)[] | undefined;
|
|
47
|
+
/** Custom color palette (CSS variable names or color strings). */
|
|
48
|
+
colors?: string[];
|
|
49
|
+
/** Show HTML legend below chart with series labels and colors. */
|
|
50
|
+
legend?: boolean;
|
|
51
|
+
/** Development mode: show visual debug overlay with dimension guides. */
|
|
52
|
+
showDebugOverlay?: boolean;
|
|
53
|
+
/** Width of the chart in pixels. Default: 480. */
|
|
54
|
+
width?: number;
|
|
55
|
+
/** Height of the chart in pixels. Default: 320. */
|
|
56
|
+
height?: number;
|
|
57
|
+
/** Enable fixed aspect ratio scaling mode.
|
|
58
|
+
When true, width/height properties define the aspect ratio (not actual pixels).
|
|
59
|
+
The component fills 100% of parent width and calculates height from aspect ratio.
|
|
60
|
+
When false (default), width/height are used as actual pixel dimensions. */
|
|
61
|
+
fixedAspectRatioScaling?: boolean;
|
|
62
|
+
/** Reference size for external scales when using fixedAspectRatioScaling.
|
|
63
|
+
This value is passed down to external scales to determine their 1:1 Figma design size.
|
|
64
|
+
At this reference size, scales render at native size; above/below they scale proportionally.
|
|
65
|
+
Default: 384 (matches Figma design baseline). */
|
|
66
|
+
scaleReferenceSize?: number;
|
|
67
|
+
/** X-axis mode: 'category' for labeled data points, 'time' for time-based data. */
|
|
68
|
+
xAxisType?: XAxisType;
|
|
69
|
+
/** Single y-axis position ('left' or 'right'). For multiple y-axes, use yAxes instead. */
|
|
70
|
+
yAxisPosition?: YAxisPosition;
|
|
71
|
+
/** Multiple y-axis definitions for complex multi-axis charts. */
|
|
72
|
+
yAxes?: ChartLineYAxisConfig[] | undefined;
|
|
73
|
+
/** Show grid lines. */
|
|
74
|
+
showGrid?: boolean;
|
|
75
|
+
/** Show vertical grid lines (x-axis). Default: false. */
|
|
76
|
+
showGridX?: boolean;
|
|
77
|
+
/** Show horizontal grid lines (y-axis). Default: false. */
|
|
78
|
+
showGridY?: boolean;
|
|
79
|
+
/** Show axis tick marks and labels. */
|
|
80
|
+
showTickMarks?: boolean;
|
|
81
|
+
/** Reserve canvas padding for axis tick labels on sides without an external scale.
|
|
82
|
+
|
|
83
|
+
When `true` (default), the chart leaves room for tick labels and renders them
|
|
84
|
+
(subject to `showTickMarks` and the 192px auto-compact threshold).
|
|
85
|
+
|
|
86
|
+
When `false`, the chart renders edge-to-edge on sides without a slotted external
|
|
87
|
+
scale AND axis tick labels are force-hidden so they cannot be clipped. This also
|
|
88
|
+
suppresses the automatic edge-to-edge switch that normally happens below the
|
|
89
|
+
192px threshold, eliminating the visible padding "jump" when crossing it.
|
|
90
|
+
|
|
91
|
+
Useful when embedding the chart inside another component that owns framing
|
|
92
|
+
and never wants to show axis labels (e.g. `obc-automation-tank`).
|
|
93
|
+
|
|
94
|
+
Defaults to `true` to preserve existing behavior. Declared with `attribute: false`
|
|
95
|
+
because a `true`-default boolean cannot work as an HTML boolean attribute. */
|
|
96
|
+
hasLabelPadding?: boolean;
|
|
97
|
+
/** Show point markers on data points. Default: false. */
|
|
98
|
+
showPoints?: boolean;
|
|
99
|
+
/** Line drawing style: 'smooth' (curved), 'straight', or 'stepped'. */
|
|
100
|
+
lineMode?: LineMode;
|
|
101
|
+
/** Unit label displayed in tooltips (e.g., 'kW', 'kg', '%'). */
|
|
102
|
+
unit?: string;
|
|
103
|
+
/** Time axis label format: 'date' (full date/time) or 'minutes' (relative). */
|
|
104
|
+
timeDisplay?: TimeDisplay;
|
|
105
|
+
/** Max number of x-axis ticks/grid lines. Useful for matching external axes. */
|
|
106
|
+
xTicksLimit?: number | undefined;
|
|
107
|
+
/** Force x-axis tick interval. Useful for matching external axes. */
|
|
108
|
+
xStepSize?: number | undefined;
|
|
109
|
+
/** Max number of y-axis ticks/grid lines. Useful for matching external axes. */
|
|
110
|
+
yTicksLimit?: number | undefined;
|
|
111
|
+
/** Force y-axis tick interval. Useful for matching external axes. */
|
|
112
|
+
yStepSize?: number | undefined;
|
|
113
|
+
/** Instrument state affecting colors of external scales. */
|
|
114
|
+
state?: InstrumentState;
|
|
115
|
+
/** Color priority: enhanced uses blue palette instead of default gray. */
|
|
116
|
+
priority?: Priority;
|
|
117
|
+
/** Frame style for chart and external scales. */
|
|
118
|
+
frameStyle?: FrameStyle;
|
|
119
|
+
/** Border radius position for the chart's own border. */
|
|
120
|
+
borderRadiusPosition?: BorderRadiusPosition | undefined;
|
|
121
|
+
/** Border radius position for external scales based on layout. */
|
|
122
|
+
borderRadiusPositionExternalScales?: BorderRadiusPosition | undefined;
|
|
123
|
+
/** When true, the chart is used inside an instrument (e.g., gauge-trend).
|
|
124
|
+
In this mode, only label font size responds to .obc-component-size-* CSS classes.
|
|
125
|
+
Border radius uses the explicit `borderRadius` property value (or defaults to 8px),
|
|
126
|
+
rather than reading from CSS variables. */
|
|
127
|
+
instrumentMode?: boolean;
|
|
128
|
+
/** Explicit border radius value in pixels.
|
|
129
|
+
When instrumentMode=true, this value is used directly (defaults to 8px).
|
|
130
|
+
When instrumentMode=false, this is ignored and border radius is read from CSS variable. */
|
|
131
|
+
borderRadius?: number | undefined;
|
|
14
132
|
/** Scale type for the vertical scale.
|
|
15
133
|
- `'regular'`: Standard tick lengths (default)
|
|
16
134
|
- `'condensed'`: Shorter tick lengths for compact display
|