@oicl/openbridge-webcomponents 0.0.15-dev-20241203183951 → 0.0.15-dev-20241203184948
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/__snapshots__/building-blocks-poi-line--primary.png +0 -0
- package/__snapshots__/button-poi-target-button--primary.png +0 -0
- package/__snapshots__/navigation-instruments-poi-target--primary.png +0 -0
- package/custom-elements.json +76 -43
- package/dist/components/poi-target-button/poi-target-button.css.js +65 -77
- package/dist/components/poi-target-button/poi-target-button.css.js.map +1 -1
- package/dist/components/poi-target-button/poi-target-button.d.ts +2 -1
- package/dist/components/poi-target-button/poi-target-button.d.ts.map +1 -1
- package/dist/components/poi-target-button/poi-target-button.js +7 -4
- package/dist/components/poi-target-button/poi-target-button.js.map +1 -1
- package/dist/navigation-instruments/poi-graphic-line/poi-config.d.ts +14 -11
- package/dist/navigation-instruments/poi-graphic-line/poi-config.d.ts.map +1 -1
- package/dist/navigation-instruments/poi-graphic-line/poi-config.js +18 -42
- package/dist/navigation-instruments/poi-graphic-line/poi-config.js.map +1 -1
- package/dist/navigation-instruments/poi-graphic-line/poi-graphic-line.d.ts +9 -3
- package/dist/navigation-instruments/poi-graphic-line/poi-graphic-line.d.ts.map +1 -1
- package/dist/navigation-instruments/poi-graphic-line/poi-graphic-line.js +147 -42
- package/dist/navigation-instruments/poi-graphic-line/poi-graphic-line.js.map +1 -1
- package/dist/navigation-instruments/poi-line/poi-line.css.js +8 -7
- package/dist/navigation-instruments/poi-line/poi-line.css.js.map +1 -1
- package/dist/navigation-instruments/poi-line/poi-line.d.ts +1 -1
- package/dist/navigation-instruments/poi-line/poi-line.d.ts.map +1 -1
- package/dist/navigation-instruments/poi-line/poi-line.js +28 -10
- package/dist/navigation-instruments/poi-line/poi-line.js.map +1 -1
- package/dist/navigation-instruments/poi-line/pointerDot.d.ts +7 -1
- package/dist/navigation-instruments/poi-line/pointerDot.d.ts.map +1 -1
- package/dist/navigation-instruments/poi-line/pointerDot.js +96 -99
- package/dist/navigation-instruments/poi-line/pointerDot.js.map +1 -1
- package/dist/navigation-instruments/poi-target/arrow.d.ts.map +1 -1
- package/dist/navigation-instruments/poi-target/arrow.js +1 -0
- package/dist/navigation-instruments/poi-target/arrow.js.map +1 -1
- package/dist/navigation-instruments/poi-target/poi-target.css.js +9 -11
- package/dist/navigation-instruments/poi-target/poi-target.css.js.map +1 -1
- package/dist/navigation-instruments/poi-target/poi-target.d.ts +4 -0
- package/dist/navigation-instruments/poi-target/poi-target.d.ts.map +1 -1
- package/dist/navigation-instruments/poi-target/poi-target.js +21 -20
- package/dist/navigation-instruments/poi-target/poi-target.js.map +1 -1
- package/package.json +1 -1
- package/src/components/poi-target-button/poi-target-button.css +20 -10
- package/src/components/poi-target-button/poi-target-button.stories.ts +6 -0
- package/src/components/poi-target-button/poi-target-button.ts +7 -2
- package/src/navigation-instruments/poi-graphic-line/poi-config.ts +24 -27
- package/src/navigation-instruments/poi-graphic-line/poi-graphic-line.stories.ts +3 -4
- package/src/navigation-instruments/poi-graphic-line/poi-graphic-line.ts +145 -38
- package/src/navigation-instruments/poi-line/poi-line.css +8 -7
- package/src/navigation-instruments/poi-line/poi-line.stories.ts +5 -5
- package/src/navigation-instruments/poi-line/poi-line.ts +29 -8
- package/src/navigation-instruments/poi-line/pointerDot.ts +115 -99
- package/src/navigation-instruments/poi-target/arrow.ts +1 -0
- package/src/navigation-instruments/poi-target/poi-target.css +9 -13
- package/src/navigation-instruments/poi-target/poi-target.stories.ts +5 -5
- package/src/navigation-instruments/poi-target/poi-target.ts +31 -23
@@ -5,7 +5,7 @@ import {classMap} from 'lit/directives/class-map.js';
|
|
5
5
|
import '../poi-line/poi-line';
|
6
6
|
import '../../components/poi-target-button/poi-target-button';
|
7
7
|
import {POIStyle} from '../poi-graphic-line/poi-config';
|
8
|
-
|
8
|
+
|
9
9
|
import {PoiTargetButtonValue} from '../../components/poi-target-button/poi-target-button';
|
10
10
|
|
11
11
|
export enum TargetValue {
|
@@ -46,30 +46,35 @@ export enum Pointer {
|
|
46
46
|
None = 'null',
|
47
47
|
}
|
48
48
|
|
49
|
+
/**
|
50
|
+
*
|
51
|
+
* @prop {number} height - y-coordinate of pointer (centre) if pointerType 'line' is selected.
|
52
|
+
*/
|
53
|
+
|
49
54
|
@customElement('obc-poi-target')
|
50
55
|
export class ObcPoiTarget extends LitElement {
|
51
|
-
@property({type: Number}) height: number =
|
56
|
+
@property({type: Number}) height: number = 192;
|
52
57
|
@property({type: String}) value: TargetValue = TargetValue.enabled;
|
53
58
|
@property({type: String}) pointerType: Pointer = Pointer.Line;
|
54
59
|
@property({type: Number}) relativeDirection = 0;
|
55
60
|
|
56
61
|
override render() {
|
57
62
|
let pointer = null;
|
58
|
-
|
63
|
+
|
59
64
|
switch (this.pointerType) {
|
60
65
|
case Pointer.Line:
|
61
|
-
pointer = html
|
62
|
-
|
63
|
-
|
64
|
-
|
66
|
+
pointer = html`
|
67
|
+
<obc-poi-line
|
68
|
+
height=${this.height}
|
69
|
+
poiStyle=${valueToPointerStyle(this.value)}
|
70
|
+
></obc-poi-line>
|
71
|
+
`;
|
65
72
|
break;
|
66
73
|
case Pointer.ArrowLeft:
|
67
|
-
pointer =
|
68
|
-
hasArrowPointer = true;
|
74
|
+
pointer = Pointer.ArrowLeft;
|
69
75
|
break;
|
70
76
|
case Pointer.ArrowRight:
|
71
|
-
pointer =
|
72
|
-
hasArrowPointer = true;
|
77
|
+
pointer = Pointer.ArrowRight;
|
73
78
|
break;
|
74
79
|
case Pointer.None:
|
75
80
|
pointer = null;
|
@@ -79,18 +84,21 @@ export class ObcPoiTarget extends LitElement {
|
|
79
84
|
}
|
80
85
|
|
81
86
|
return html`
|
82
|
-
<div
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
87
|
+
<div class="wrapper">
|
88
|
+
<div
|
89
|
+
class=${classMap({
|
90
|
+
wrapper: true,
|
91
|
+
['type-' + this.pointerType]: true,
|
92
|
+
})}
|
93
|
+
>
|
94
|
+
<obc-poi-target-button
|
95
|
+
.value=${valueToButtonStyle(this.value)}
|
96
|
+
.pointer=${this.pointerType}
|
97
|
+
.relativeDirection=${this.relativeDirection}
|
98
|
+
></obc-poi-target-button>
|
99
|
+
|
100
|
+
${this.pointerType === Pointer.Line ? pointer : null}
|
101
|
+
</div>
|
94
102
|
</div>
|
95
103
|
`;
|
96
104
|
}
|