@marineyachtradar/signalk-plugin 0.1.3 → 0.2.1

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.
@@ -0,0 +1,478 @@
1
+ /* ============================================
2
+ Discovery Screen Styles
3
+ ============================================ */
4
+
5
+ .myr_discovery_container {
6
+ max-width: 900px;
7
+ margin: 0 auto;
8
+ padding: 20px;
9
+ }
10
+
11
+ .myr_discovery_header {
12
+ display: flex;
13
+ align-items: center;
14
+ gap: 20px;
15
+ margin-bottom: 30px;
16
+ padding-bottom: 20px;
17
+ border-bottom: 1px solid rgba(100, 200, 180, 0.3);
18
+ }
19
+
20
+ .myr_discovery_header h1 {
21
+ margin: 0;
22
+ font-size: 28px;
23
+ color: rgb(100, 200, 180);
24
+ }
25
+
26
+ /* Animated radar icon */
27
+ .myr_radar_icon {
28
+ width: 60px;
29
+ height: 60px;
30
+ color: rgb(100, 200, 180);
31
+ }
32
+
33
+ .myr_radar_sweep {
34
+ width: 100%;
35
+ height: 100%;
36
+ }
37
+
38
+ .myr_sweep_line {
39
+ transform-origin: 50px 50px;
40
+ animation: radar-sweep 2s linear infinite;
41
+ }
42
+
43
+ @keyframes radar-sweep {
44
+ from { transform: rotate(0deg); }
45
+ to { transform: rotate(360deg); }
46
+ }
47
+
48
+ /* Discovery sections */
49
+ .myr_discovery_section {
50
+ margin-bottom: 25px;
51
+ }
52
+
53
+ .myr_section_title {
54
+ font-size: 18px;
55
+ font-weight: bold;
56
+ color: rgb(100, 200, 180);
57
+ margin-bottom: 15px;
58
+ display: flex;
59
+ align-items: center;
60
+ gap: 8px;
61
+ }
62
+
63
+ .myr_radar_count {
64
+ display: inline-flex;
65
+ align-items: center;
66
+ justify-content: center;
67
+ width: 28px;
68
+ height: 28px;
69
+ background: rgb(100, 200, 180);
70
+ color: #000;
71
+ border-radius: 50%;
72
+ font-weight: bold;
73
+ }
74
+
75
+ /* Detecting animation */
76
+ .myr_detecting {
77
+ display: flex;
78
+ align-items: center;
79
+ gap: 15px;
80
+ padding: 20px;
81
+ background: rgba(60, 50, 10, 0.5);
82
+ border: 1px solid rgba(255, 200, 100, 0.3);
83
+ border-radius: 8px;
84
+ color: rgb(255, 200, 100);
85
+ font-size: 16px;
86
+ }
87
+
88
+ .myr_pulse {
89
+ width: 12px;
90
+ height: 12px;
91
+ background: rgb(255, 200, 100);
92
+ border-radius: 50%;
93
+ animation: pulse 1.5s ease-in-out infinite;
94
+ }
95
+
96
+ @keyframes pulse {
97
+ 0%, 100% {
98
+ opacity: 1;
99
+ transform: scale(1);
100
+ box-shadow: 0 0 0 0 rgba(255, 200, 100, 0.7);
101
+ }
102
+ 50% {
103
+ opacity: 0.7;
104
+ transform: scale(1.1);
105
+ box-shadow: 0 0 0 10px rgba(255, 200, 100, 0);
106
+ }
107
+ }
108
+
109
+ /* Radar table */
110
+ .myr_radar_table {
111
+ width: 100%;
112
+ border-collapse: separate;
113
+ border-spacing: 0;
114
+ background: rgba(3, 37, 37, 0.8);
115
+ border-radius: 8px;
116
+ overflow: hidden;
117
+ }
118
+
119
+ .myr_radar_row {
120
+ transition: background 0.2s ease;
121
+ }
122
+
123
+ .myr_radar_row:hover {
124
+ background: rgba(100, 200, 180, 0.1);
125
+ }
126
+
127
+ .myr_radar_name {
128
+ padding: 15px 20px;
129
+ font-weight: bold;
130
+ color: rgb(152, 217, 204);
131
+ font-size: 16px;
132
+ }
133
+
134
+ .myr_radar_actions {
135
+ padding: 15px 20px;
136
+ text-align: right;
137
+ display: flex;
138
+ gap: 10px;
139
+ justify-content: flex-end;
140
+ }
141
+
142
+ .myr_radar_link {
143
+ padding: 10px 18px;
144
+ border-radius: 6px;
145
+ text-decoration: none;
146
+ font-weight: bold;
147
+ font-size: 14px;
148
+ transition: all 0.2s ease;
149
+ }
150
+
151
+ .myr_radar_link_primary {
152
+ background: rgb(100, 200, 180);
153
+ color: #000;
154
+ }
155
+
156
+ .myr_radar_link_primary:hover {
157
+ background: rgb(130, 230, 210);
158
+ transform: translateY(-1px);
159
+ }
160
+
161
+ .myr_radar_link_secondary {
162
+ background: rgba(100, 200, 180, 0.2);
163
+ color: rgb(152, 217, 204);
164
+ border: 1px solid rgba(100, 200, 180, 0.4);
165
+ }
166
+
167
+ .myr_radar_link_secondary:hover {
168
+ background: rgba(100, 200, 180, 0.3);
169
+ }
170
+
171
+ /* Network help section */
172
+ .myr_network_help {
173
+ margin-top: 20px;
174
+ background: rgba(20, 40, 40, 0.8);
175
+ border: 1px solid rgba(100, 200, 180, 0.2);
176
+ border-radius: 8px;
177
+ overflow: hidden;
178
+ }
179
+
180
+ .myr_network_help summary {
181
+ padding: 15px 20px;
182
+ cursor: pointer;
183
+ font-weight: bold;
184
+ color: rgb(100, 200, 180);
185
+ background: rgba(100, 200, 180, 0.1);
186
+ transition: background 0.2s ease;
187
+ }
188
+
189
+ .myr_network_help summary:hover {
190
+ background: rgba(100, 200, 180, 0.15);
191
+ }
192
+
193
+ .myr_help_content {
194
+ padding: 20px;
195
+ }
196
+
197
+ .myr_brand_section {
198
+ padding: 15px;
199
+ margin-bottom: 15px;
200
+ background: rgba(0, 0, 0, 0.3);
201
+ border-radius: 6px;
202
+ border-left: 3px solid rgb(100, 200, 180);
203
+ }
204
+
205
+ .myr_brand_section.myr_brand_other {
206
+ border-left-color: rgba(100, 200, 180, 0.5);
207
+ opacity: 0.8;
208
+ }
209
+
210
+ .myr_brand_header {
211
+ font-weight: bold;
212
+ color: rgb(100, 200, 180);
213
+ margin-bottom: 10px;
214
+ font-size: 15px;
215
+ }
216
+
217
+ .myr_brand_section p {
218
+ margin: 8px 0;
219
+ color: rgb(180, 200, 200);
220
+ line-height: 1.5;
221
+ }
222
+
223
+ .myr_setup_steps {
224
+ margin: 10px 0;
225
+ }
226
+
227
+ .myr_setup_step {
228
+ padding: 6px 0;
229
+ color: rgb(200, 220, 220);
230
+ }
231
+
232
+ .myr_code_example {
233
+ margin-top: 10px;
234
+ padding: 10px 15px;
235
+ background: rgba(0, 0, 0, 0.5);
236
+ border-radius: 4px;
237
+ font-family: 'Consolas', 'Monaco', monospace;
238
+ }
239
+
240
+ .myr_code_example code {
241
+ color: rgb(150, 220, 150);
242
+ }
243
+
244
+ /* Interface table */
245
+ .myr_interface_table {
246
+ width: 100%;
247
+ border-collapse: separate;
248
+ border-spacing: 0;
249
+ background: rgba(3, 37, 37, 0.8);
250
+ border-radius: 8px;
251
+ overflow: hidden;
252
+ font-size: 14px;
253
+ }
254
+
255
+ .myr_interface_table td {
256
+ padding: 10px 15px;
257
+ border-bottom: 1px solid rgba(100, 200, 180, 0.1);
258
+ }
259
+
260
+ .myr_interface_header td {
261
+ background: rgba(100, 200, 180, 0.15);
262
+ font-weight: bold;
263
+ color: rgb(100, 200, 180);
264
+ }
265
+
266
+ .myr_interface_name {
267
+ color: rgb(152, 217, 204);
268
+ font-weight: bold;
269
+ }
270
+
271
+ .myr_interface_ok {
272
+ color: rgb(100, 200, 100);
273
+ }
274
+
275
+ .myr_interface_error {
276
+ color: rgb(200, 100, 100);
277
+ }
278
+
279
+ /* ============================================
280
+ WebGPU Warning & Error Pages
281
+ ============================================ */
282
+
283
+ .myr_webgpu_warning {
284
+ background: linear-gradient(135deg, rgba(180, 80, 40, 0.9), rgba(140, 60, 30, 0.9));
285
+ border: 1px solid rgba(255, 150, 100, 0.5);
286
+ border-radius: 12px;
287
+ padding: 20px;
288
+ margin-bottom: 25px;
289
+ box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
290
+ }
291
+
292
+ .myr_warning_title {
293
+ font-size: 20px;
294
+ font-weight: bold;
295
+ color: #fff;
296
+ margin-bottom: 15px;
297
+ display: flex;
298
+ align-items: center;
299
+ gap: 10px;
300
+ }
301
+
302
+ .myr_warning_title::before {
303
+ content: "!";
304
+ display: inline-flex;
305
+ align-items: center;
306
+ justify-content: center;
307
+ width: 28px;
308
+ height: 28px;
309
+ background: rgba(255, 255, 255, 0.2);
310
+ border-radius: 50%;
311
+ font-weight: bold;
312
+ }
313
+
314
+ .myr_warning_content {
315
+ color: rgba(255, 255, 255, 0.9);
316
+ }
317
+
318
+ .myr_warning_item {
319
+ margin-bottom: 20px;
320
+ padding: 15px;
321
+ background: rgba(0, 0, 0, 0.2);
322
+ border-radius: 8px;
323
+ }
324
+
325
+ .myr_warning_item strong {
326
+ color: #fff;
327
+ display: block;
328
+ margin-bottom: 8px;
329
+ font-size: 16px;
330
+ }
331
+
332
+ .myr_warning_item p {
333
+ margin: 6px 0;
334
+ line-height: 1.5;
335
+ }
336
+
337
+ .myr_warning_https {
338
+ border-left: 3px solid #ff6b6b;
339
+ }
340
+
341
+ .myr_warning_options {
342
+ margin-top: 12px;
343
+ }
344
+
345
+ .myr_warning_option {
346
+ padding: 8px 0;
347
+ }
348
+
349
+ .myr_code_block {
350
+ margin-top: 10px;
351
+ padding: 12px 15px;
352
+ background: rgba(0, 0, 0, 0.4);
353
+ border-radius: 6px;
354
+ font-size: 14px;
355
+ }
356
+
357
+ .myr_code_block p {
358
+ margin: 5px 0;
359
+ }
360
+
361
+ .myr_code_block code {
362
+ background: rgba(255, 255, 255, 0.15);
363
+ padding: 2px 8px;
364
+ border-radius: 4px;
365
+ font-family: 'Consolas', 'Monaco', monospace;
366
+ color: rgb(150, 220, 150);
367
+ }
368
+
369
+ .myr_note {
370
+ font-style: italic;
371
+ opacity: 0.8;
372
+ font-size: 13px;
373
+ margin-top: 10px !important;
374
+ }
375
+
376
+ .myr_flag_link {
377
+ color: rgb(150, 220, 150);
378
+ text-decoration: underline;
379
+ cursor: pointer;
380
+ }
381
+
382
+ .myr_flag_link:hover {
383
+ color: rgb(180, 255, 180);
384
+ }
385
+
386
+ /* WebGPU Error Page (viewer) */
387
+ .myr_webgpu_error {
388
+ max-width: 700px;
389
+ margin: 50px auto;
390
+ padding: 30px;
391
+ background: linear-gradient(135deg, rgba(60, 30, 30, 0.95), rgba(40, 20, 20, 0.95));
392
+ border: 1px solid rgba(200, 100, 100, 0.4);
393
+ border-radius: 12px;
394
+ color: rgb(220, 200, 200);
395
+ }
396
+
397
+ .myr_webgpu_error h2 {
398
+ color: rgb(255, 150, 150);
399
+ margin: 0 0 15px 0;
400
+ font-size: 24px;
401
+ }
402
+
403
+ .myr_webgpu_error h3 {
404
+ color: rgb(200, 180, 180);
405
+ margin: 20px 0 10px 0;
406
+ font-size: 16px;
407
+ }
408
+
409
+ .myr_error_message {
410
+ background: rgba(0, 0, 0, 0.3);
411
+ padding: 12px 15px;
412
+ border-radius: 6px;
413
+ border-left: 3px solid rgb(200, 100, 100);
414
+ margin-bottom: 20px;
415
+ }
416
+
417
+ .myr_error_section {
418
+ margin: 20px 0;
419
+ padding: 15px;
420
+ background: rgba(0, 0, 0, 0.2);
421
+ border-radius: 8px;
422
+ }
423
+
424
+ .myr_code_instructions {
425
+ margin-top: 10px;
426
+ padding: 12px;
427
+ background: rgba(0, 0, 0, 0.3);
428
+ border-radius: 6px;
429
+ font-size: 14px;
430
+ }
431
+
432
+ .myr_code_instructions p {
433
+ margin: 6px 0;
434
+ }
435
+
436
+ .myr_code_instructions code {
437
+ background: rgba(100, 200, 100, 0.2);
438
+ padding: 2px 8px;
439
+ border-radius: 4px;
440
+ font-family: 'Consolas', 'Monaco', monospace;
441
+ color: rgb(150, 220, 150);
442
+ }
443
+
444
+ .myr_error_actions {
445
+ margin-top: 25px;
446
+ display: flex;
447
+ gap: 15px;
448
+ justify-content: center;
449
+ }
450
+
451
+ .myr_back_link {
452
+ padding: 12px 24px;
453
+ background: rgba(100, 200, 180, 0.2);
454
+ color: rgb(100, 200, 180);
455
+ text-decoration: none;
456
+ border-radius: 6px;
457
+ border: 1px solid rgba(100, 200, 180, 0.4);
458
+ transition: all 0.2s ease;
459
+ }
460
+
461
+ .myr_back_link:hover {
462
+ background: rgba(100, 200, 180, 0.3);
463
+ }
464
+
465
+ .myr_retry_button {
466
+ padding: 12px 24px;
467
+ background: rgb(100, 200, 180);
468
+ color: #000;
469
+ border: none;
470
+ border-radius: 6px;
471
+ font-weight: bold;
472
+ cursor: pointer;
473
+ transition: all 0.2s ease;
474
+ }
475
+
476
+ .myr_retry_button:hover {
477
+ background: rgb(130, 230, 210);
478
+ }
Binary file
@@ -0,0 +1,45 @@
1
+ <!DOCTYPE html>
2
+ <html lang="en">
3
+ <head>
4
+ <title>Mayara Radar</title>
5
+ <meta charset="utf-8" />
6
+ <meta name="viewport" content="width=device-width, initial-scale=1" />
7
+ <meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate" />
8
+ <meta http-equiv="Pragma" content="no-cache" />
9
+ <meta http-equiv="Expires" content="0" />
10
+ <link type="text/css" rel="stylesheet" href="base.css?v=1" />
11
+ <link type="text/css" rel="stylesheet" href="discovery.css?v=1" />
12
+ <script type="module" src="mayara.js?v=3"></script>
13
+ </head>
14
+ <body>
15
+ <div class="myr_discovery_container">
16
+ <div class="myr_discovery_header">
17
+ <div class="myr_radar_icon">
18
+ <svg viewBox="0 0 100 100" class="myr_radar_sweep">
19
+ <circle cx="50" cy="50" r="45" fill="none" stroke="currentColor" stroke-width="1" opacity="0.3"/>
20
+ <circle cx="50" cy="50" r="30" fill="none" stroke="currentColor" stroke-width="1" opacity="0.3"/>
21
+ <circle cx="50" cy="50" r="15" fill="none" stroke="currentColor" stroke-width="1" opacity="0.3"/>
22
+ <line x1="50" y1="50" x2="50" y2="5" stroke="currentColor" stroke-width="2" class="myr_sweep_line"/>
23
+ </svg>
24
+ </div>
25
+ <h1>Mayara Radar</h1>
26
+ </div>
27
+
28
+ <div id="webgpu_warning" class="myr_webgpu_warning" style="display: none;">
29
+ </div>
30
+
31
+ <div id="radars" class="myr_discovery_section">
32
+ <div class="myr_detecting">
33
+ <span class="myr_pulse"></span>
34
+ Detecting radars...
35
+ </div>
36
+ </div>
37
+
38
+ <div id="interfaces" class="myr_discovery_section">
39
+ </div>
40
+
41
+ <div id="info" class="myr_discovery_section">
42
+ </div>
43
+ </div>
44
+ </body>
45
+ </html>
@@ -0,0 +1,87 @@
1
+ /* ============================================
2
+ Layout - Container, Panels, PPI, Canvas
3
+ ============================================ */
4
+
5
+ /* Main container */
6
+ div.myr_container {
7
+ width: 100%;
8
+ height: 100vh;
9
+ overflow: hidden;
10
+ }
11
+
12
+ /* Control panel */
13
+ div.myr_controller {
14
+ display: block;
15
+ width: 200px;
16
+ }
17
+
18
+ div.myr_controller_left {
19
+ float: left;
20
+ height: 100vh;
21
+ max-height: 100vh;
22
+ overflow-y: scroll;
23
+ }
24
+
25
+ /* PPI viewer area */
26
+ div.myr_ppi {
27
+ float: left;
28
+ display:flex;
29
+ flex-direction:column;
30
+ background-color: rgb(0, 0, 0);
31
+ position: relative;
32
+ width: calc(100% - 200px);
33
+ height: 100vh;
34
+ overflow: hidden;
35
+ }
36
+
37
+ /* Canvas layers */
38
+ #myr_canvas, #myr_canvas_webgl, #myr_canvas_webgpu {
39
+ z-index: 2;
40
+ position: absolute;
41
+ left: 0;
42
+ top: 0;
43
+ }
44
+
45
+ #myr_canvas_background {
46
+ z-index: 1;
47
+ position: absolute;
48
+ left: 0;
49
+ top: 0;
50
+ }
51
+
52
+ #myr_canvas_overlay {
53
+ z-index: 3;
54
+ position: absolute;
55
+ left: 0;
56
+ top: 0;
57
+ pointer-events: none;
58
+ }
59
+
60
+ /* Heading mode toggle button */
61
+ .myr_heading_toggle {
62
+ position: absolute;
63
+ bottom: 20px;
64
+ right: 20px;
65
+ padding: 8px 12px;
66
+ background: rgba(0, 50, 0, 0.8);
67
+ color: #00ff00;
68
+ border: 2px solid #00ff00;
69
+ border-radius: 6px;
70
+ font-family: Verdana, Geneva, sans-serif;
71
+ font-size: 14px;
72
+ font-weight: bold;
73
+ cursor: pointer;
74
+ user-select: none;
75
+ z-index: 100;
76
+ transition: all 0.2s ease;
77
+ }
78
+
79
+ .myr_heading_toggle:hover {
80
+ background: rgba(0, 100, 0, 0.9);
81
+ border-color: #00ff80;
82
+ color: #00ff80;
83
+ }
84
+
85
+ .myr_heading_toggle:active {
86
+ transform: scale(0.95);
87
+ }