@mapcomponents/react-maplibre 0.1.26 → 0.1.30
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/CHANGELOG.md +31 -0
- package/coverage/clover.xml +456 -479
- package/coverage/coverage-final.json +21 -20
- package/coverage/lcov-report/index.html +94 -79
- package/coverage/lcov-report/src/components/MapLibreMap/MapLibreMap.js.html +22 -22
- package/coverage/lcov-report/src/components/MapLibreMap/index.html +1 -1
- package/coverage/lcov-report/src/components/MlCreatePdfButton/MlCreatePdfButton.js.html +11 -11
- package/coverage/lcov-report/src/components/MlCreatePdfButton/index.html +11 -11
- package/coverage/lcov-report/src/components/MlFeatureEditor/MlFeatureEditor.js.html +1 -1
- package/coverage/lcov-report/src/components/MlFeatureEditor/index.html +1 -1
- package/coverage/lcov-report/src/components/MlFillExtrusionLayer/MlFillExtrusionLayer.js.html +4 -4
- package/coverage/lcov-report/src/components/MlFillExtrusionLayer/index.html +1 -1
- package/coverage/lcov-report/src/components/MlFollowGps/MlFollowGps.js.html +212 -26
- package/coverage/lcov-report/src/components/MlFollowGps/index.html +19 -19
- package/coverage/lcov-report/src/components/MlGPXViewer/MlGPXViewer.js.html +129 -165
- package/coverage/lcov-report/src/components/MlGPXViewer/gpxConverter.js.html +8 -8
- package/coverage/lcov-report/src/components/MlGPXViewer/index.html +20 -20
- package/coverage/lcov-report/src/components/MlGeoJsonLayer/MlGeoJsonLayer.js.html +45 -297
- package/coverage/lcov-report/src/components/MlGeoJsonLayer/index.html +19 -19
- package/coverage/lcov-report/src/components/MlImageMarkerLayer/MlImageMarkerLayer.js.html +2 -2
- package/coverage/lcov-report/src/components/MlImageMarkerLayer/index.html +1 -1
- package/coverage/lcov-report/src/components/MlLayer/MlLayer.js.html +2 -2
- package/coverage/lcov-report/src/components/MlLayer/index.html +1 -1
- package/coverage/lcov-report/src/components/MlLayerMagnify/MlLayerMagnify.js.html +4 -4
- package/coverage/lcov-report/src/components/MlLayerMagnify/index.html +1 -1
- package/coverage/lcov-report/src/components/MlLayerSwipe/MlLayerSwipe.js.html +3 -3
- package/coverage/lcov-report/src/components/MlLayerSwipe/index.html +1 -1
- package/coverage/lcov-report/src/components/MlLayerSwitcher/MlLayerSwitcher.js.html +1 -1
- package/coverage/lcov-report/src/components/MlLayerSwitcher/components/LayerBox.js.html +1 -1
- package/coverage/lcov-report/src/components/MlLayerSwitcher/components/index.html +1 -1
- package/coverage/lcov-report/src/components/MlLayerSwitcher/index.html +1 -1
- package/coverage/lcov-report/src/components/MlMarker/MlMarker.js.html +1 -1
- package/coverage/lcov-report/src/components/MlMarker/index.html +1 -1
- package/coverage/lcov-report/src/components/MlNavigationCompass/MlNavigationCompass.js.html +38 -104
- package/coverage/lcov-report/src/components/MlNavigationCompass/index.html +19 -19
- package/coverage/lcov-report/src/components/MlNavigationTools/MlNavigationTools.js.html +40 -139
- package/coverage/lcov-report/src/components/MlNavigationTools/index.html +15 -15
- package/coverage/lcov-report/src/components/MlOsmLayer/MlOsmLayer.js.html +32 -155
- package/coverage/lcov-report/src/components/MlOsmLayer/index.html +19 -19
- package/coverage/lcov-report/src/components/MlScaleReference/MlScaleReference.js.html +39 -198
- package/coverage/lcov-report/src/components/MlScaleReference/index.html +9 -9
- package/coverage/lcov-report/src/components/MlShareMapState/MlShareMapState.js.html +1 -1
- package/coverage/lcov-report/src/components/MlShareMapState/index.html +1 -1
- package/coverage/lcov-report/src/components/MlSpatialElevationProfile/MlSpatialElevationProfile.js.html +4 -4
- package/coverage/lcov-report/src/components/MlSpatialElevationProfile/index.html +1 -1
- package/coverage/lcov-report/src/components/MlThreeJsLayer/MlThreeJsLayer.js.html +1 -1
- package/coverage/lcov-report/src/components/MlThreeJsLayer/index.html +1 -1
- package/coverage/lcov-report/src/components/MlTransitionGeoJsonLayer/MlTransitionGeoJsonLayer.js.html +580 -0
- package/coverage/lcov-report/src/components/MlTransitionGeoJsonLayer/index.html +116 -0
- package/coverage/lcov-report/src/components/MlUseMapDebugger/MlUseMapDebugger.js.html +1 -1
- package/coverage/lcov-report/src/components/MlUseMapDebugger/index.html +1 -1
- package/coverage/lcov-report/src/components/MlVectorTileLayer/MlVectorTileLayer.js.html +3 -3
- package/coverage/lcov-report/src/components/MlVectorTileLayer/index.html +1 -1
- package/coverage/lcov-report/src/components/MlWmsFeatureInfoPopup/MlWmsFeatureInfoPopup.js.html +1 -1
- package/coverage/lcov-report/src/components/MlWmsFeatureInfoPopup/index.html +1 -1
- package/coverage/lcov-report/src/components/MlWmsLayer/MlWmsLayer.js.html +8 -11
- package/coverage/lcov-report/src/components/MlWmsLayer/index.html +1 -1
- package/coverage/lcov-report/src/components/MlWmsLoader/MlWmsLoader.js.html +1 -1
- package/coverage/lcov-report/src/components/MlWmsLoader/index.html +1 -1
- package/coverage/lcov-report/src/hooks/index.html +6 -6
- package/coverage/lcov-report/src/hooks/useMap.js.html +38 -26
- package/coverage/lcov-report/src/hooks/useMapState.js.html +47 -38
- package/coverage/lcov-report/src/hooks/useWms.js.html +1 -1
- package/coverage/lcov-report/src/i18n.js.html +1 -1
- package/coverage/lcov-report/src/index.html +1 -1
- package/coverage/lcov-report/src/translations/english.js.html +1 -1
- package/coverage/lcov-report/src/translations/german.js.html +1 -1
- package/coverage/lcov-report/src/translations/index.html +1 -1
- package/coverage/lcov.info +813 -858
- package/dist/index.esm.js +210 -425
- package/dist/index.esm.js.map +1 -1
- package/jsdoc.json +3 -3
- package/package.json +19 -13
- package/src/components/MapLibreMap/lib/MapLibreGlWrapper.js +6 -2
- package/src/components/MapLibreMap/lib/MapLibreGlWrapper.test.js +3 -3
- package/src/components/MlFeatureEditor/MlFeatureEditor.test.js +2 -2
- package/src/components/MlFollowGps/MlFollowGps.js +74 -12
- package/src/components/MlGPXViewer/MlGPXViewer.js +69 -81
- package/src/components/MlGeoJsonLayer/MlGeoJsonLayer.js +6 -90
- package/src/components/MlGeoJsonLayer/MlGeoJsonLayer.stories.js +4 -22
- package/src/components/MlGeoJsonLayer/util/getDefaultPaintPropsByType.js +2 -2
- package/src/components/MlNavigationCompass/MlNavigationCompass.js +17 -39
- package/src/components/MlNavigationCompass/MlNavigationCompass.test.js +3 -3
- package/src/components/MlNavigationTools/MlNavigationTools.js +30 -63
- package/src/components/MlOsmLayer/MlOsmLayer.js +15 -56
- package/src/components/MlOsmLayer/MlOsmLayer.stories.js +21 -10
- package/src/components/MlOsmLayer/MlOsmLayer.test.js +4 -4
- package/src/components/MlScaleReference/MlScaleReference.js +29 -82
- package/src/components/MlShareMapState/MlShareMapState.stories.js +1 -3
- package/src/components/MlThreeJsLayer/lib/GLTFLoader.js +2369 -2591
- package/src/components/MlTransitionGeoJsonLayer/MlTransitionGeoJsonLayer.doc.de.md +3 -0
- package/src/components/MlTransitionGeoJsonLayer/MlTransitionGeoJsonLayer.js +165 -0
- package/src/components/MlTransitionGeoJsonLayer/MlTransitionGeoJsonLayer.meta.json +15 -0
- package/src/components/MlTransitionGeoJsonLayer/MlTransitionGeoJsonLayer.stories.js +52 -0
- package/src/components/MlTransitionGeoJsonLayer/MlTransitionGeoJsonLayer.test.js +20 -0
- package/src/components/MlTransitionGeoJsonLayer/assets/sample_1.json +26 -0
- package/src/components/MlTransitionGeoJsonLayer/assets/sample_2.json +22 -0
- package/src/components/MlTransitionGeoJsonLayer/assets/sample_polygon_1.json +33 -0
- package/src/components/{MlGeoJsonLayer → MlTransitionGeoJsonLayer}/util/transitionFunctions.js +63 -97
- package/src/components/MlWmsLayer/MlWmsLayer.js +1 -2
- package/src/decorators/MapContextDecorator.js +5 -0
- package/src/decorators/MultiMapContextDecorator.js +6 -0
- package/src/hooks/useMap.js +8 -4
- package/src/hooks/useMapState.js +4 -1
- package/src/decorators/EmptyMapContextDecorator.js +0 -25
- package/src/decorators/MapContext3DDecorator.js +0 -39
- package/src/decorators/MapContextDashboardDecorator.js +0 -19
- package/src/decorators/MapContextKlokantechBasicDecorator.js +0 -39
|
@@ -23,30 +23,30 @@
|
|
|
23
23
|
<div class='clearfix'>
|
|
24
24
|
|
|
25
25
|
<div class='fl pad1y space-right2'>
|
|
26
|
-
<span class="strong">
|
|
26
|
+
<span class="strong">46.42% </span>
|
|
27
27
|
<span class="quiet">Statements</span>
|
|
28
|
-
<span class='fraction'>
|
|
28
|
+
<span class='fraction'>52/112</span>
|
|
29
29
|
</div>
|
|
30
30
|
|
|
31
31
|
|
|
32
32
|
<div class='fl pad1y space-right2'>
|
|
33
|
-
<span class="strong">
|
|
33
|
+
<span class="strong">23.07% </span>
|
|
34
34
|
<span class="quiet">Branches</span>
|
|
35
|
-
<span class='fraction'>
|
|
35
|
+
<span class='fraction'>6/26</span>
|
|
36
36
|
</div>
|
|
37
37
|
|
|
38
38
|
|
|
39
39
|
<div class='fl pad1y space-right2'>
|
|
40
|
-
<span class="strong">
|
|
40
|
+
<span class="strong">25% </span>
|
|
41
41
|
<span class="quiet">Functions</span>
|
|
42
|
-
<span class='fraction'>
|
|
42
|
+
<span class='fraction'>6/24</span>
|
|
43
43
|
</div>
|
|
44
44
|
|
|
45
45
|
|
|
46
46
|
<div class='fl pad1y space-right2'>
|
|
47
|
-
<span class="strong">
|
|
47
|
+
<span class="strong">47.16% </span>
|
|
48
48
|
<span class="quiet">Lines</span>
|
|
49
|
-
<span class='fraction'>
|
|
49
|
+
<span class='fraction'>50/106</span>
|
|
50
50
|
</div>
|
|
51
51
|
|
|
52
52
|
|
|
@@ -61,7 +61,7 @@
|
|
|
61
61
|
</div>
|
|
62
62
|
</template>
|
|
63
63
|
</div>
|
|
64
|
-
<div class='status-line
|
|
64
|
+
<div class='status-line low'></div>
|
|
65
65
|
<pre><table class="coverage">
|
|
66
66
|
<tr><td class="line-count quiet"><a name='L1'></a><a href='#L1'>1</a>
|
|
67
67
|
<a name='L2'></a><a href='#L2'>2</a>
|
|
@@ -422,19 +422,7 @@
|
|
|
422
422
|
<a name='L357'></a><a href='#L357'>357</a>
|
|
423
423
|
<a name='L358'></a><a href='#L358'>358</a>
|
|
424
424
|
<a name='L359'></a><a href='#L359'>359</a>
|
|
425
|
-
<a name='L360'></a><a href='#L360'>360</a>
|
|
426
|
-
<a name='L361'></a><a href='#L361'>361</a>
|
|
427
|
-
<a name='L362'></a><a href='#L362'>362</a>
|
|
428
|
-
<a name='L363'></a><a href='#L363'>363</a>
|
|
429
|
-
<a name='L364'></a><a href='#L364'>364</a>
|
|
430
|
-
<a name='L365'></a><a href='#L365'>365</a>
|
|
431
|
-
<a name='L366'></a><a href='#L366'>366</a>
|
|
432
|
-
<a name='L367'></a><a href='#L367'>367</a>
|
|
433
|
-
<a name='L368'></a><a href='#L368'>368</a>
|
|
434
|
-
<a name='L369'></a><a href='#L369'>369</a>
|
|
435
|
-
<a name='L370'></a><a href='#L370'>370</a>
|
|
436
|
-
<a name='L371'></a><a href='#L371'>371</a>
|
|
437
|
-
<a name='L372'></a><a href='#L372'>372</a></td><td class="line-coverage quiet"><span class="cline-any cline-neutral"> </span>
|
|
425
|
+
<a name='L360'></a><a href='#L360'>360</a></td><td class="line-coverage quiet"><span class="cline-any cline-neutral"> </span>
|
|
438
426
|
<span class="cline-any cline-neutral"> </span>
|
|
439
427
|
<span class="cline-any cline-neutral"> </span>
|
|
440
428
|
<span class="cline-any cline-neutral"> </span>
|
|
@@ -457,53 +445,31 @@
|
|
|
457
445
|
<span class="cline-any cline-neutral"> </span>
|
|
458
446
|
<span class="cline-any cline-neutral"> </span>
|
|
459
447
|
<span class="cline-any cline-neutral"> </span>
|
|
448
|
+
<span class="cline-any cline-yes">2x</span>
|
|
449
|
+
<span class="cline-any cline-yes">18x</span>
|
|
450
|
+
<span class="cline-any cline-yes">18x</span>
|
|
451
|
+
<span class="cline-any cline-yes">18x</span>
|
|
452
|
+
<span class="cline-any cline-yes">18x</span>
|
|
453
|
+
<span class="cline-any cline-yes">18x</span>
|
|
454
|
+
<span class="cline-any cline-yes">18x</span>
|
|
460
455
|
<span class="cline-any cline-neutral"> </span>
|
|
456
|
+
<span class="cline-any cline-yes">18x</span>
|
|
457
|
+
<span class="cline-any cline-yes">18x</span>
|
|
458
|
+
<span class="cline-any cline-yes">18x</span>
|
|
459
|
+
<span class="cline-any cline-yes">18x</span>
|
|
460
|
+
<span class="cline-any cline-yes">18x</span>
|
|
461
|
+
<span class="cline-any cline-yes">18x</span>
|
|
461
462
|
<span class="cline-any cline-neutral"> </span>
|
|
462
|
-
<span class="cline-any cline-yes">
|
|
463
|
-
<span class="cline-any cline-yes">12x</span>
|
|
464
|
-
<span class="cline-any cline-yes">12x</span>
|
|
465
|
-
<span class="cline-any cline-yes">12x</span>
|
|
466
|
-
<span class="cline-any cline-yes">12x</span>
|
|
467
|
-
<span class="cline-any cline-yes">12x</span>
|
|
468
|
-
<span class="cline-any cline-yes">12x</span>
|
|
469
|
-
<span class="cline-any cline-yes">12x</span>
|
|
470
|
-
<span class="cline-any cline-yes">12x</span>
|
|
471
|
-
<span class="cline-any cline-yes">12x</span>
|
|
472
|
-
<span class="cline-any cline-neutral"> </span>
|
|
473
|
-
<span class="cline-any cline-yes">12x</span>
|
|
474
|
-
<span class="cline-any cline-yes">12x</span>
|
|
475
|
-
<span class="cline-any cline-yes">12x</span>
|
|
476
|
-
<span class="cline-any cline-yes">12x</span>
|
|
477
|
-
<span class="cline-any cline-yes">12x</span>
|
|
478
|
-
<span class="cline-any cline-yes">12x</span>
|
|
479
|
-
<span class="cline-any cline-neutral"> </span>
|
|
480
|
-
<span class="cline-any cline-yes">12x</span>
|
|
463
|
+
<span class="cline-any cline-yes">18x</span>
|
|
481
464
|
<span class="cline-any cline-neutral"> </span>
|
|
482
465
|
<span class="cline-any cline-neutral"> </span>
|
|
483
466
|
<span class="cline-any cline-neutral"> </span>
|
|
484
467
|
<span class="cline-any cline-neutral"> </span>
|
|
485
468
|
<span class="cline-any cline-neutral"> </span>
|
|
486
469
|
<span class="cline-any cline-neutral"> </span>
|
|
470
|
+
<span class="cline-any cline-yes">18x</span>
|
|
487
471
|
<span class="cline-any cline-yes">12x</span>
|
|
488
|
-
<span class="cline-any cline-yes">6x</span>
|
|
489
|
-
<span class="cline-any cline-yes">6x</span>
|
|
490
|
-
<span class="cline-any cline-yes">6x</span>
|
|
491
472
|
<span class="cline-any cline-neutral"> </span>
|
|
492
|
-
<span class="cline-any cline-yes">3x</span>
|
|
493
|
-
<span class="cline-any cline-yes">3x</span>
|
|
494
|
-
<span class="cline-any cline-neutral"> </span>
|
|
495
|
-
<span class="cline-any cline-yes">3x</span>
|
|
496
|
-
<span class="cline-any cline-neutral"> </span>
|
|
497
|
-
<span class="cline-any cline-yes">3x</span>
|
|
498
|
-
<span class="cline-any cline-neutral"> </span>
|
|
499
|
-
<span class="cline-any cline-yes">3x</span>
|
|
500
|
-
<span class="cline-any cline-neutral"> </span>
|
|
501
|
-
<span class="cline-any cline-neutral"> </span>
|
|
502
|
-
<span class="cline-any cline-neutral"> </span>
|
|
503
|
-
<span class="cline-any cline-yes">12x</span>
|
|
504
|
-
<span class="cline-any cline-yes">12x</span>
|
|
505
|
-
<span class="cline-any cline-neutral"> </span>
|
|
506
|
-
<span class="cline-any cline-yes">6x</span>
|
|
507
473
|
<span class="cline-any cline-yes">6x</span>
|
|
508
474
|
<span class="cline-any cline-neutral"> </span>
|
|
509
475
|
<span class="cline-any cline-yes">6x</span>
|
|
@@ -547,7 +513,9 @@
|
|
|
547
513
|
<span class="cline-any cline-neutral"> </span>
|
|
548
514
|
<span class="cline-any cline-yes">6x</span>
|
|
549
515
|
<span class="cline-any cline-neutral"> </span>
|
|
550
|
-
<span class="cline-any cline-
|
|
516
|
+
<span class="cline-any cline-neutral"> </span>
|
|
517
|
+
<span class="cline-any cline-neutral"> </span>
|
|
518
|
+
<span class="cline-any cline-neutral"> </span>
|
|
551
519
|
<span class="cline-any cline-neutral"> </span>
|
|
552
520
|
<span class="cline-any cline-no"> </span>
|
|
553
521
|
<span class="cline-any cline-neutral"> </span>
|
|
@@ -566,50 +534,56 @@
|
|
|
566
534
|
<span class="cline-any cline-no"> </span>
|
|
567
535
|
<span class="cline-any cline-neutral"> </span>
|
|
568
536
|
<span class="cline-any cline-neutral"> </span>
|
|
537
|
+
<span class="cline-any cline-neutral"> </span>
|
|
538
|
+
<span class="cline-any cline-neutral"> </span>
|
|
569
539
|
<span class="cline-any cline-yes">6x</span>
|
|
540
|
+
<span class="cline-any cline-neutral"> </span>
|
|
541
|
+
<span class="cline-any cline-neutral"> </span>
|
|
542
|
+
<span class="cline-any cline-neutral"> </span>
|
|
570
543
|
<span class="cline-any cline-no"> </span>
|
|
571
544
|
<span class="cline-any cline-no"> </span>
|
|
572
545
|
<span class="cline-any cline-neutral"> </span>
|
|
573
546
|
<span class="cline-any cline-neutral"> </span>
|
|
547
|
+
<span class="cline-any cline-neutral"> </span>
|
|
548
|
+
<span class="cline-any cline-neutral"> </span>
|
|
574
549
|
<span class="cline-any cline-yes">6x</span>
|
|
575
550
|
<span class="cline-any cline-neutral"> </span>
|
|
576
551
|
<span class="cline-any cline-neutral"> </span>
|
|
577
|
-
<span class="cline-any cline-yes">
|
|
578
|
-
<span class="cline-any cline-yes">
|
|
579
|
-
<span class="cline-any cline-yes">
|
|
552
|
+
<span class="cline-any cline-yes">18x</span>
|
|
553
|
+
<span class="cline-any cline-yes">18x</span>
|
|
554
|
+
<span class="cline-any cline-yes">18x</span>
|
|
580
555
|
<span class="cline-any cline-no"> </span>
|
|
581
556
|
<span class="cline-any cline-no"> </span>
|
|
582
557
|
<span class="cline-any cline-neutral"> </span>
|
|
583
|
-
<span class="cline-any cline-yes">
|
|
558
|
+
<span class="cline-any cline-yes">18x</span>
|
|
584
559
|
<span class="cline-any cline-no"> </span>
|
|
585
560
|
<span class="cline-any cline-neutral"> </span>
|
|
586
|
-
<span class="cline-any cline-yes">
|
|
561
|
+
<span class="cline-any cline-yes">18x</span>
|
|
587
562
|
<span class="cline-any cline-no"> </span>
|
|
588
563
|
<span class="cline-any cline-no"> </span>
|
|
589
564
|
<span class="cline-any cline-neutral"> </span>
|
|
590
565
|
<span class="cline-any cline-neutral"> </span>
|
|
591
|
-
<span class="cline-any cline-yes">
|
|
592
|
-
<span class="cline-any cline-yes">
|
|
566
|
+
<span class="cline-any cline-yes">18x</span>
|
|
567
|
+
<span class="cline-any cline-yes">18x</span>
|
|
593
568
|
<span class="cline-any cline-neutral"> </span>
|
|
594
|
-
<span class="cline-any cline-yes">
|
|
569
|
+
<span class="cline-any cline-yes">18x</span>
|
|
595
570
|
<span class="cline-any cline-neutral"> </span>
|
|
596
|
-
<span class="cline-any cline-yes">
|
|
571
|
+
<span class="cline-any cline-yes">18x</span>
|
|
597
572
|
<span class="cline-any cline-neutral"> </span>
|
|
598
|
-
<span class="cline-any cline-yes">
|
|
599
|
-
<span class="cline-any cline-yes">
|
|
600
|
-
<span class="cline-any cline-yes">
|
|
601
|
-
<span class="cline-any cline-yes">
|
|
602
|
-
<span class="cline-any cline-yes">
|
|
603
|
-
<span class="cline-any cline-yes">9x</span>
|
|
573
|
+
<span class="cline-any cline-yes">18x</span>
|
|
574
|
+
<span class="cline-any cline-yes">15x</span>
|
|
575
|
+
<span class="cline-any cline-yes">15x</span>
|
|
576
|
+
<span class="cline-any cline-yes">15x</span>
|
|
577
|
+
<span class="cline-any cline-yes">15x</span>
|
|
604
578
|
<span class="cline-any cline-neutral"> </span>
|
|
605
579
|
<span class="cline-any cline-neutral"> </span>
|
|
606
580
|
<span class="cline-any cline-neutral"> </span>
|
|
607
|
-
<span class="cline-any cline-yes">
|
|
581
|
+
<span class="cline-any cline-yes">18x</span>
|
|
608
582
|
<span class="cline-any cline-no"> </span>
|
|
609
583
|
<span class="cline-any cline-no"> </span>
|
|
610
584
|
<span class="cline-any cline-neutral"> </span>
|
|
611
585
|
<span class="cline-any cline-neutral"> </span>
|
|
612
|
-
<span class="cline-any cline-yes">
|
|
586
|
+
<span class="cline-any cline-yes">18x</span>
|
|
613
587
|
<span class="cline-any cline-yes">6x</span>
|
|
614
588
|
<span class="cline-any cline-neutral"> </span>
|
|
615
589
|
<span class="cline-any cline-no"> </span>
|
|
@@ -619,7 +593,7 @@
|
|
|
619
593
|
<span class="cline-any cline-neutral"> </span>
|
|
620
594
|
<span class="cline-any cline-neutral"> </span>
|
|
621
595
|
<span class="cline-any cline-neutral"> </span>
|
|
622
|
-
<span class="cline-any cline-yes">
|
|
596
|
+
<span class="cline-any cline-yes">18x</span>
|
|
623
597
|
<span class="cline-any cline-no"> </span>
|
|
624
598
|
<span class="cline-any cline-neutral"> </span>
|
|
625
599
|
<span class="cline-any cline-no"> </span>
|
|
@@ -640,7 +614,7 @@
|
|
|
640
614
|
<span class="cline-any cline-neutral"> </span>
|
|
641
615
|
<span class="cline-any cline-neutral"> </span>
|
|
642
616
|
<span class="cline-any cline-neutral"> </span>
|
|
643
|
-
<span class="cline-any cline-yes">
|
|
617
|
+
<span class="cline-any cline-yes">18x</span>
|
|
644
618
|
<span class="cline-any cline-no"> </span>
|
|
645
619
|
<span class="cline-any cline-no"> </span>
|
|
646
620
|
<span class="cline-any cline-no"> </span>
|
|
@@ -673,11 +647,11 @@
|
|
|
673
647
|
<span class="cline-any cline-neutral"> </span>
|
|
674
648
|
<span class="cline-any cline-neutral"> </span>
|
|
675
649
|
<span class="cline-any cline-neutral"> </span>
|
|
676
|
-
<span class="cline-any cline-yes">
|
|
650
|
+
<span class="cline-any cline-yes">18x</span>
|
|
677
651
|
<span class="cline-any cline-no"> </span>
|
|
678
652
|
<span class="cline-any cline-neutral"> </span>
|
|
679
653
|
<span class="cline-any cline-neutral"> </span>
|
|
680
|
-
<span class="cline-any cline-yes">
|
|
654
|
+
<span class="cline-any cline-yes">18x</span>
|
|
681
655
|
<span class="cline-any cline-no"> </span>
|
|
682
656
|
<span class="cline-any cline-no"> </span>
|
|
683
657
|
<span class="cline-any cline-no"> </span>
|
|
@@ -688,10 +662,12 @@
|
|
|
688
662
|
<span class="cline-any cline-no"> </span>
|
|
689
663
|
<span class="cline-any cline-neutral"> </span>
|
|
690
664
|
<span class="cline-any cline-neutral"> </span>
|
|
691
|
-
<span class="cline-any cline-yes">
|
|
665
|
+
<span class="cline-any cline-yes">18x</span>
|
|
692
666
|
<span class="cline-any cline-no"> </span>
|
|
693
667
|
<span class="cline-any cline-neutral"> </span>
|
|
694
|
-
<span class="cline-any cline-yes">
|
|
668
|
+
<span class="cline-any cline-yes">18x</span>
|
|
669
|
+
<span class="cline-any cline-neutral"> </span>
|
|
670
|
+
<span class="cline-any cline-neutral"> </span>
|
|
695
671
|
<span class="cline-any cline-neutral"> </span>
|
|
696
672
|
<span class="cline-any cline-neutral"> </span>
|
|
697
673
|
<span class="cline-any cline-neutral"> </span>
|
|
@@ -780,11 +756,11 @@
|
|
|
780
756
|
<span class="cline-any cline-neutral"> </span>
|
|
781
757
|
<span class="cline-any cline-neutral"> </span>
|
|
782
758
|
<span class="cline-any cline-neutral"> </span>
|
|
783
|
-
<span class="cline-any cline-yes">
|
|
759
|
+
<span class="cline-any cline-yes">2x</span>
|
|
784
760
|
<span class="cline-any cline-neutral"> </span>
|
|
785
761
|
<span class="cline-any cline-neutral"> </span>
|
|
786
762
|
<span class="cline-any cline-neutral"> </span>
|
|
787
|
-
<span class="cline-any cline-yes">
|
|
763
|
+
<span class="cline-any cline-yes">2x</span>
|
|
788
764
|
<span class="cline-any cline-neutral"> </span>
|
|
789
765
|
<span class="cline-any cline-neutral"> </span>
|
|
790
766
|
<span class="cline-any cline-neutral"> </span>
|
|
@@ -805,25 +781,23 @@
|
|
|
805
781
|
<span class="cline-any cline-neutral"> </span>
|
|
806
782
|
<span class="cline-any cline-neutral"> </span>
|
|
807
783
|
<span class="cline-any cline-neutral"> </span>
|
|
808
|
-
<span class="cline-any cline-neutral"> </span></td><td class="text"><pre class="prettyprint lang-js">import React, {useContext, useRef, useEffect, useState} from "react";
|
|
784
|
+
<span class="cline-any cline-neutral"> </span></td><td class="text"><pre class="prettyprint lang-js">import React, { useContext, useRef, useEffect, useState } from "react";
|
|
809
785
|
import PropTypes from "prop-types";
|
|
810
|
-
import {
|
|
811
|
-
import {bbox} from "@turf/turf";
|
|
786
|
+
import { bbox } from "@turf/turf";
|
|
812
787
|
import Divider from "@mui/material/Divider";
|
|
813
788
|
import Typography from "@mui/material/Typography";
|
|
814
789
|
import Drawer from "@mui/material/Drawer";
|
|
815
790
|
import IconButton from "@mui/material/IconButton";
|
|
816
791
|
import InfoIcon from "@mui/icons-material/Info";
|
|
817
792
|
import FileCopy from "@mui/icons-material/FileCopy";
|
|
818
|
-
import {Popup} from "maplibre-gl";
|
|
793
|
+
import { Popup } from "maplibre-gl";
|
|
819
794
|
import List from "@mui/material/List";
|
|
820
795
|
import ListItem from "@mui/material/ListItem";
|
|
821
796
|
import ListItemText from "@mui/material/ListItemText";
|
|
822
797
|
import GeoJsonContext from "./util/GeoJsonContext";
|
|
823
798
|
import toGeoJSON from "./gpxConverter";
|
|
824
799
|
import useMediaQuery from "@mui/material/useMediaQuery";
|
|
825
|
-
|
|
826
|
-
import {v4 as uuidv4} from "uuid";
|
|
800
|
+
import useMap from "../../hooks/useMap";
|
|
827
801
|
|
|
828
802
|
/**
|
|
829
803
|
* MlGPXViewer returns a dropzone and a button to load a GPX Track into the map.
|
|
@@ -832,11 +806,8 @@ import {v4 as uuidv4} from "uuid";
|
|
|
832
806
|
*/
|
|
833
807
|
const MlGPXViewer = (props) => {
|
|
834
808
|
const dataSource = useContext(GeoJsonContext);
|
|
835
|
-
const componentId = useRef((props.idPrefix ? <span class="branch-0 cbranch-no" title="branch not covered" >props.idPrefix </span>: "MlGpxViewer-") + uuidv4());
|
|
836
|
-
const mapContext = useContext(MapContext);
|
|
837
|
-
const mapId = props.mapId;
|
|
838
809
|
const initializedRef = useRef(false);
|
|
839
|
-
const
|
|
810
|
+
const mapHook = useMap({ mapId: props.mapId, waitForLayer: props.insertBeforeLayer });
|
|
840
811
|
const sourceName = "import-source";
|
|
841
812
|
const layerNameLines = "importer-layer-lines";
|
|
842
813
|
const layerNamePoints = "importer-layer-points";
|
|
@@ -856,36 +827,19 @@ const MlGPXViewer = (props) => {
|
|
|
856
827
|
);
|
|
857
828
|
|
|
858
829
|
useEffect(() => {
|
|
859
|
-
|
|
860
|
-
let _popup = popup.current;
|
|
861
|
-
return () => {
|
|
862
|
-
// This is the cleanup function, it is called when this react component is removed from react-dom
|
|
863
|
-
if (mapRef.current) {
|
|
864
|
-
mapRef.current.cleanup(_componentId);
|
|
865
|
-
|
|
866
|
-
mapRef.current.getCanvas().style.cursor = "";
|
|
867
|
-
|
|
868
|
-
mapRef.current = null;
|
|
869
|
-
}
|
|
870
|
-
_popup.remove();
|
|
871
|
-
};
|
|
872
|
-
}, []);
|
|
873
|
-
|
|
874
|
-
useEffect(() => {
|
|
875
|
-
if (!mapContext.mapExists(mapId) || initializedRef.current) return;
|
|
830
|
+
if (!mapHook.map || initializedRef.current) return;
|
|
876
831
|
|
|
877
832
|
initializedRef.current = true;
|
|
878
|
-
mapRef.current = mapContext.getMap(mapId);
|
|
879
833
|
|
|
880
|
-
|
|
834
|
+
mapHook.map.addSource(
|
|
881
835
|
sourceName,
|
|
882
836
|
{
|
|
883
837
|
type: "geojson",
|
|
884
838
|
data: dataSource.data,
|
|
885
839
|
},
|
|
886
|
-
componentId
|
|
840
|
+
mapHook.componentId
|
|
887
841
|
);
|
|
888
|
-
|
|
842
|
+
mapHook.map.addLayer(
|
|
889
843
|
{
|
|
890
844
|
id: layerNameLines,
|
|
891
845
|
source: sourceName,
|
|
@@ -896,9 +850,9 @@ const MlGPXViewer = (props) => {
|
|
|
896
850
|
},
|
|
897
851
|
},
|
|
898
852
|
props.insertBeforeLayer,
|
|
899
|
-
componentId
|
|
853
|
+
mapHook.componentId
|
|
900
854
|
);
|
|
901
|
-
|
|
855
|
+
mapHook.map.addLayer(
|
|
902
856
|
{
|
|
903
857
|
id: layerNamePoints,
|
|
904
858
|
source: sourceName,
|
|
@@ -910,40 +864,49 @@ const MlGPXViewer = (props) => {
|
|
|
910
864
|
filter: ["==", "$type", "Point"],
|
|
911
865
|
},
|
|
912
866
|
props.insertBeforeLayer,
|
|
913
|
-
componentId
|
|
867
|
+
mapHook.componentId
|
|
914
868
|
);
|
|
915
869
|
|
|
916
870
|
[layerNameLines, layerNamePoints].forEach((layerName) => {
|
|
917
|
-
|
|
871
|
+
mapHook.map.setLayoutProperty(layerName, "visibility", "visible");
|
|
918
872
|
});
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
873
|
+
mapHook.map.on(
|
|
874
|
+
"mouseenter",
|
|
875
|
+
layerNamePoints,
|
|
876
|
+
<span class="fstat-no" title="function not covered" > (e</span>) => {
|
|
877
|
+
// Change the cursor style as a UI indicator.
|
|
922
878
|
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
879
|
+
const coordinates = <span class="cstat-no" title="statement not covered" >e.features[0].geometry.coordinates.slice();</span>
|
|
880
|
+
//const description = e.features[0].properties.desc;
|
|
881
|
+
const name = <span class="cstat-no" title="statement not covered" >e.features[0].properties.name;</span>
|
|
926
882
|
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
<span class="cstat-no" title="statement not covered" >
|
|
931
|
-
<span class="cstat-no" title="statement not covered" >
|
|
932
|
-
|
|
883
|
+
// Ensure that if the map is zoomed out such that multiple
|
|
884
|
+
// copies of the feature are visible, the popup appears
|
|
885
|
+
// over the copy being pointed to.
|
|
886
|
+
<span class="cstat-no" title="statement not covered" > while (Math.abs(e.lngLat.lng - coordinates[0]) > 180) {</span>
|
|
887
|
+
<span class="cstat-no" title="statement not covered" > coordinates[0] += e.lngLat.lng > coordinates[0] ? 360 : -360;</span>
|
|
888
|
+
}
|
|
933
889
|
|
|
934
|
-
|
|
890
|
+
// Populate the popup and set its coordinates
|
|
935
891
|
|
|
936
|
-
|
|
937
|
-
<span class="cstat-no" title="statement not covered" >
|
|
938
|
-
|
|
892
|
+
// based on the feature found.
|
|
893
|
+
<span class="cstat-no" title="statement not covered" > popup.current.setLngLat(coordinates).setHTML(name).addTo(mapHook.map);</span>
|
|
894
|
+
},
|
|
895
|
+
mapHook.componentId
|
|
896
|
+
);
|
|
939
897
|
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
898
|
+
mapHook.map.on(
|
|
899
|
+
"mouseleave",
|
|
900
|
+
"places",
|
|
901
|
+
<span class="fstat-no" title="function not covered" > fu</span>nction () {
|
|
902
|
+
<span class="cstat-no" title="statement not covered" > mapHook.map.getCanvas().style.cursor = "";</span>
|
|
903
|
+
<span class="cstat-no" title="statement not covered" > popup.current.remove();</span>
|
|
904
|
+
},
|
|
905
|
+
mapHook.componentId
|
|
906
|
+
);
|
|
944
907
|
|
|
945
|
-
|
|
946
|
-
}, [
|
|
908
|
+
mapHook.map.setZoom(10);
|
|
909
|
+
}, [mapHook.map]);
|
|
947
910
|
|
|
948
911
|
useEffect(() => {
|
|
949
912
|
const dropZoneCurrent = dropZone.current;
|
|
@@ -969,9 +932,8 @@ const MlGPXViewer = (props) => {
|
|
|
969
932
|
return () => {
|
|
970
933
|
window.removeEventListener("dragenter", raiseDropZoneAndStopDefault);
|
|
971
934
|
window.removeEventListener("dragover", stopDefault);
|
|
972
|
-
window.removeEventListener("drop", stopDefault);
|
|
973
935
|
dropZoneCurrent.removeEventListener("dragleave", lowerDropZone);
|
|
974
|
-
window.removeEventListener("drop",
|
|
936
|
+
window.removeEventListener("drop", lowerDropZoneAndStopDefault);
|
|
975
937
|
};
|
|
976
938
|
});
|
|
977
939
|
|
|
@@ -981,12 +943,12 @@ const MlGPXViewer = (props) => {
|
|
|
981
943
|
};
|
|
982
944
|
|
|
983
945
|
useEffect(() => {
|
|
984
|
-
if (!
|
|
946
|
+
if (!mapHook.map) return;
|
|
985
947
|
|
|
986
948
|
const visibility = <span class="cstat-no" title="statement not covered" >props.visible ? "visible" : "none";</span>
|
|
987
949
|
|
|
988
950
|
<span class="cstat-no" title="statement not covered" > [layerNameLines, layerNamePoints].forEach(<span class="fstat-no" title="function not covered" >(l</span>ayerName) => {</span>
|
|
989
|
-
<span class="cstat-no" title="statement not covered" >
|
|
951
|
+
<span class="cstat-no" title="statement not covered" > mapHook.map.setLayoutProperty(layerName, "visibility", visibility);</span>
|
|
990
952
|
});
|
|
991
953
|
}, [props.visible]);
|
|
992
954
|
|
|
@@ -1012,7 +974,7 @@ const MlGPXViewer = (props) => {
|
|
|
1012
974
|
};
|
|
1013
975
|
|
|
1014
976
|
const addGPXToMap = <span class="fstat-no" title="function not covered" >(g</span>pxAsString) => {
|
|
1015
|
-
<span class="cstat-no" title="statement not covered" > if (!
|
|
977
|
+
<span class="cstat-no" title="statement not covered" > if (!mapHook.map) <span class="cstat-no" title="statement not covered" >return;</span></span>
|
|
1016
978
|
<span class="cstat-no" title="statement not covered" > try {</span>
|
|
1017
979
|
<span class="cstat-no" title="statement not covered" > setMetaData([]);</span>
|
|
1018
980
|
const domParser = <span class="cstat-no" title="statement not covered" >new DOMParser();</span>
|
|
@@ -1036,9 +998,9 @@ const MlGPXViewer = (props) => {
|
|
|
1036
998
|
});
|
|
1037
999
|
const data = <span class="cstat-no" title="statement not covered" >toGeoJSON.gpx(gpxDoc);</span>
|
|
1038
1000
|
<span class="cstat-no" title="statement not covered" > dataSource.setData(data);</span>
|
|
1039
|
-
<span class="cstat-no" title="statement not covered" >
|
|
1001
|
+
<span class="cstat-no" title="statement not covered" > mapHook.map.getSource(sourceName).setData(data);</span>
|
|
1040
1002
|
const bounds = <span class="cstat-no" title="statement not covered" >bbox(data);</span>
|
|
1041
|
-
<span class="cstat-no" title="statement not covered" >
|
|
1003
|
+
<span class="cstat-no" title="statement not covered" > mapHook.map.fitBounds(bounds);</span>
|
|
1042
1004
|
} catch (e) {
|
|
1043
1005
|
<span class="cstat-no" title="statement not covered" > console.log(e);</span>
|
|
1044
1006
|
}
|
|
@@ -1064,15 +1026,17 @@ const MlGPXViewer = (props) => {
|
|
|
1064
1026
|
};
|
|
1065
1027
|
return (
|
|
1066
1028
|
<>
|
|
1067
|
-
<div
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1029
|
+
<div
|
|
1030
|
+
style={{
|
|
1031
|
+
position: "fixed",
|
|
1032
|
+
right: "5px",
|
|
1033
|
+
bottom: mediaIsMobile ? <span class="branch-0 cbranch-no" title="branch not covered" >"40px" </span>: "25px",
|
|
1034
|
+
display: "flex",
|
|
1035
|
+
flexDirection: "column",
|
|
1036
|
+
gap: "5px",
|
|
1037
|
+
zIndex: 1000,
|
|
1038
|
+
}}
|
|
1039
|
+
>
|
|
1076
1040
|
<IconButton
|
|
1077
1041
|
onClick={manualUpload}
|
|
1078
1042
|
style={{
|
|
@@ -1086,9 +1050,9 @@ const MlGPXViewer = (props) => {
|
|
|
1086
1050
|
type="file"
|
|
1087
1051
|
id="input"
|
|
1088
1052
|
multiple
|
|
1089
|
-
style={{display: "none"}}
|
|
1053
|
+
style={{ display: "none" }}
|
|
1090
1054
|
></input>
|
|
1091
|
-
<FileCopy/>
|
|
1055
|
+
<FileCopy />
|
|
1092
1056
|
</IconButton>
|
|
1093
1057
|
<IconButton
|
|
1094
1058
|
onClick={toogleDrawer}
|
|
@@ -1097,7 +1061,7 @@ const MlGPXViewer = (props) => {
|
|
|
1097
1061
|
}}
|
|
1098
1062
|
size="large"
|
|
1099
1063
|
>
|
|
1100
|
-
<InfoIcon/>
|
|
1064
|
+
<InfoIcon />
|
|
1101
1065
|
</IconButton>
|
|
1102
1066
|
</div>
|
|
1103
1067
|
<Drawer variant="persistent" anchor="left" open={open}>
|
|
@@ -1111,11 +1075,11 @@ const MlGPXViewer = (props) => {
|
|
|
1111
1075
|
>
|
|
1112
1076
|
Informationen zur Route
|
|
1113
1077
|
</Typography>
|
|
1114
|
-
<Divider/>
|
|
1078
|
+
<Divider />
|
|
1115
1079
|
<List>
|
|
1116
1080
|
{metaData.map(<span class="fstat-no" title="function not covered" >(i</span>tem) => (
|
|
1117
1081
|
<span class="cstat-no" title="statement not covered" > <ListItem key={`item--${item.id}`}></span>
|
|
1118
|
-
<ListItemText primary={item.value}/>
|
|
1082
|
+
<ListItemText primary={item.value} />
|
|
1119
1083
|
</ListItem>
|
|
1120
1084
|
))}
|
|
1121
1085
|
</List>
|
|
@@ -1157,7 +1121,7 @@ MlGPXViewer.defaultProps = {
|
|
|
1157
1121
|
|
|
1158
1122
|
MlGPXViewer.propTypes = {
|
|
1159
1123
|
/**
|
|
1160
|
-
* Id of the target MapLibre instance in
|
|
1124
|
+
* Id of the target MapLibre instance in mapHook
|
|
1161
1125
|
*/
|
|
1162
1126
|
mapId: PropTypes.string,
|
|
1163
1127
|
/**
|
|
@@ -1183,7 +1147,7 @@ export default MlGPXViewer;
|
|
|
1183
1147
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
1184
1148
|
Code coverage generated by
|
|
1185
1149
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
1186
|
-
at
|
|
1150
|
+
at Sun Feb 20 2022 16:39:08 GMT+0000 (Coordinated Universal Time)
|
|
1187
1151
|
</div>
|
|
1188
1152
|
<script src="../../../prettify.js"></script>
|
|
1189
1153
|
<script>
|
|
@@ -596,10 +596,10 @@
|
|
|
596
596
|
<span class="cline-any cline-neutral"> </span>
|
|
597
597
|
<span class="cline-any cline-neutral"> </span>
|
|
598
598
|
<span class="cline-any cline-neutral"> </span>
|
|
599
|
-
<span class="cline-any cline-yes">
|
|
600
|
-
<span class="cline-any cline-yes">
|
|
601
|
-
<span class="cline-any cline-yes">
|
|
602
|
-
<span class="cline-any cline-yes">
|
|
599
|
+
<span class="cline-any cline-yes">2x</span>
|
|
600
|
+
<span class="cline-any cline-yes">2x</span>
|
|
601
|
+
<span class="cline-any cline-yes">2x</span>
|
|
602
|
+
<span class="cline-any cline-yes">2x</span>
|
|
603
603
|
<span class="cline-any cline-neutral"> </span>
|
|
604
604
|
<span class="cline-any cline-neutral"> </span>
|
|
605
605
|
<span class="cline-any cline-no"> </span>
|
|
@@ -701,7 +701,7 @@
|
|
|
701
701
|
<span class="cline-any cline-neutral"> </span>
|
|
702
702
|
<span class="cline-any cline-neutral"> </span>
|
|
703
703
|
<span class="cline-any cline-neutral"> </span>
|
|
704
|
-
<span class="cline-any cline-yes">
|
|
704
|
+
<span class="cline-any cline-yes">2x</span>
|
|
705
705
|
<span class="cline-any cline-neutral"> </span>
|
|
706
706
|
<span class="cline-any cline-neutral"> </span>
|
|
707
707
|
<span class="cline-any cline-neutral"> </span>
|
|
@@ -721,7 +721,7 @@
|
|
|
721
721
|
<span class="cline-any cline-no"> </span>
|
|
722
722
|
<span class="cline-any cline-neutral"> </span>
|
|
723
723
|
<span class="cline-any cline-neutral"> </span>
|
|
724
|
-
<span class="cline-any cline-yes">
|
|
724
|
+
<span class="cline-any cline-yes">2x</span>
|
|
725
725
|
<span class="cline-any cline-neutral"> </span>
|
|
726
726
|
<span class="cline-any cline-no"> </span>
|
|
727
727
|
<span class="cline-any cline-neutral"> </span>
|
|
@@ -1099,7 +1099,7 @@
|
|
|
1099
1099
|
<span class="cline-any cline-no"> </span>
|
|
1100
1100
|
<span class="cline-any cline-neutral"> </span>
|
|
1101
1101
|
<span class="cline-any cline-neutral"> </span>
|
|
1102
|
-
<span class="cline-any cline-yes">
|
|
1102
|
+
<span class="cline-any cline-yes">2x</span>
|
|
1103
1103
|
<span class="cline-any cline-neutral"> </span>
|
|
1104
1104
|
<span class="cline-any cline-neutral"> </span>
|
|
1105
1105
|
<span class="cline-any cline-neutral"> </span>
|
|
@@ -1630,7 +1630,7 @@ export default toGeoJSON;
|
|
|
1630
1630
|
<div class='footer quiet pad2 space-top1 center small'>
|
|
1631
1631
|
Code coverage generated by
|
|
1632
1632
|
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
1633
|
-
at
|
|
1633
|
+
at Sun Feb 20 2022 16:39:08 GMT+0000 (Coordinated Universal Time)
|
|
1634
1634
|
</div>
|
|
1635
1635
|
<script src="../../../prettify.js"></script>
|
|
1636
1636
|
<script>
|