@raruto/leaflet-elevation 2.6.0 → 2.7.0

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/README.md CHANGED
@@ -47,6 +47,7 @@ _For a working example see one of the following demos:_
47
47
  - [slope chart](https://raruto.github.io/leaflet-elevation/examples/leaflet-elevation_slope-chart.html)
48
48
  - [speed chart](https://raruto.github.io/leaflet-elevation/examples/leaflet-elevation_speed-chart.html)
49
49
  - [temperature chart](https://raruto.github.io/leaflet-elevation/examples/leaflet-elevation_temperature-chart.html)
50
+ - [bathymetry data](https://raruto.github.io/leaflet-elevation/examples/leaflet-elevation_bathymetry.html)
50
51
  - [walking marker](https://raruto.github.io/leaflet-elevation/examples/leaflet-elevation_dynamic-runner.html)
51
52
 
52
53
  ---
@@ -1,337 +1,278 @@
1
- .leaflet-hidden {
2
- visibility: hidden;
3
- }
4
-
5
- .legend {
6
- cursor: pointer;
7
- }
8
-
9
- .leaflet-container {
10
- z-index: 0;
11
- /* prevent overlapping the .elevation-detached chart */
12
- }
13
-
14
- .elevation-control .background {
15
- background-color: var(--ele-bg, rgba(70, 130, 180, 0.2));
16
- border-radius: 5px;
17
- overflow: visible;
18
- display: block;
19
- touch-action: none;
20
- user-select: none;
21
- max-width: 100%;
22
- }
23
-
24
- .elevation-control .grid,
25
- .elevation-control .area > foreignObject,
26
- .elevation-control .axis,
27
- .elevation-control .tooltip,
28
- .height-focus.line {
29
- pointer-events: none;
30
- }
31
-
32
- .elevation-control .axis line,
33
- .elevation-control .axis path {
34
- stroke: var(--ele-axis, #2D1130);
35
- stroke-width: 1;
36
- fill: none;
37
- }
38
-
39
- .elevation-control .grid .tick line {
40
- stroke: var(--ele-grid, #EEE);
41
- stroke-width: 1px;
42
- shape-rendering: crispEdges;
43
- }
44
-
45
- .elevation-control .grid path {
46
- stroke-width: 0;
47
- }
48
-
49
- .elevation-control .axis text,
50
- .elevation-control .legend text,
51
- .elevation-control .point text {
52
- fill: #000;
53
- font-weight: 700;
54
- paint-order: stroke fill;
55
- stroke: #fff;
56
- stroke-width: 2px
57
- }
58
-
59
- .elevation-control .y.axis text {
60
- text-anchor: end;
61
- }
62
-
63
- .elevation-control .area {
64
- fill: var(--ele-area, #4682B4);
65
- stroke: var(--ele-stroke, #000);
66
- stroke-width: 1.2;
67
- paint-order: stroke fill;
68
- }
69
-
70
- .elevation-control .horizontal-drag-line {
71
- cursor: row-resize;
72
- stroke: transparent;
73
- stroke-dasharray: 5;
74
- stroke-width: 1.1;
75
- }
76
-
77
- .elevation-control .active .horizontal-drag-line {
78
- stroke: #000;
79
- }
80
-
81
- .elevation-control .horizontal-drag-label {
82
- fill: #000;
83
- font-weight: 700;
84
- paint-order: stroke;
85
- stroke: #FFF;
86
- stroke-width: 2px;
87
- }
88
-
89
- .elevation-control .ruler {
90
- color: #000;
91
- cursor: row-resize;
92
- }
93
-
94
- .elevation-control .mouse-focus-line {
95
- stroke: #000;
96
- stroke-width: 1;
97
- }
98
-
99
- .elevation-control .mouse-focus-label-rect {
100
- fill: #000;
101
- fill-opacity: 0.75;
102
- stroke-width: 1;
103
- stroke: #444;
104
- }
105
-
106
- .elevation-control .mouse-focus-label-text {
107
- fill: #FFF;
108
- font-size: 10px;
109
- }
110
-
111
- .elevation-control .brush .overlay {
112
- cursor: unset;
113
- }
114
-
115
- .elevation-control .brush .selection {
116
- fill: var(--ele-brush, rgba(23, 74, 117, 0.4));
117
- stroke: none;
118
- fill-opacity: unset;
119
- }
120
-
121
- .elevation-summary {
122
- font-family: "Lucida Grande", "Lucida Sans Unicode", Verdana, Arial, Helvetica, sans-serif;
123
- font-size: 12px;
124
- margin: var(--ele-sum-margin, 0 auto);
125
- text-shadow: var(--ele-sum-shadow, 1px 0 0 #FFF, -1px 0 0 #FFF, 0 1px 0 #FFF, 0 -1px 0 #FFF, 1px 1px #FFF, -1px -1px 0 #FFF, 1px -1px 0 #FFF, -1px 1px 0 #FFF);
126
- }
127
-
128
- .elevation-summary>span:not(:last-child):after {
129
- content: var(--ele-sum-sep, '');
130
- }
131
-
132
- .multiline-summary>span {
133
- display: block;
134
- }
135
-
136
- .multiline-summary .download {
137
- float: right;
138
- margin-top: -3em;
139
- margin-right: 2em;
140
- font-weight: bold;
141
- font-size: 1.2em;
142
- }
143
-
144
- .elevation-summary .summaryvalue {
145
- font-weight: bold;
146
- }
147
-
148
- .elevation-toggle-icon {
149
- background-color: #fff;
150
- right: 5px;
151
- top: 5px;
152
- height: var(--ele-toggle-size, 36px);
153
- width: var(--ele-toggle-size, 36px);
154
- cursor: pointer;
155
- box-shadow: 0 1px 7px rgba(0, 0, 0, 0.4);
156
- border-radius: 5px;
157
- display: inline-block;
158
- position: var(--ele-toggle-pos, relative);
159
- }
160
-
161
- .elevation-toggle-icon:before {
162
- content: '\2716';
163
- display: var(--ele-close-btn, none);
164
- color: #000;
165
- width: 100%;
166
- line-height: 20px;
167
- text-align: center;
168
- font-weight: bold;
169
- font-size: 15px;
170
- }
171
-
172
- .leaflet-elevation-pane .height-focus,
173
- .leaflet-overlay-pane .height-focus {
174
- stroke: #000;
175
- fill: var(--ele-circle, var(--ele-area, #FFF));
176
- }
177
-
178
- .leaflet-elevation-pane .height-focus.line,
179
- .leaflet-overlay-pane .height-focus.line {
180
- stroke-width: 2;
181
- }
182
-
183
- .leaflet-elevation-pane .height-focus-label,
184
- .leaflet-overlay-pane .height-focus-label {
185
- font-size: 12px;
186
- font-weight: 600;
187
- fill: #000;
188
- paint-order: stroke;
189
- stroke: #FFF;
190
- stroke-width: 2px;
191
- }
192
-
193
- .elevation-waypoint-icon:before,
194
- .elevation-position-icon:before {
195
- content: "";
196
- width: 100%;
197
- height: 100%;
198
- display: inline-block;
199
- background: var(--ele-marker) no-repeat center center / contain;
200
- }
201
-
202
- .elevation-polyline {
203
- stroke: var(--ele-poly, var(--ele-area, #000));
204
- filter: drop-shadow(1px 1px 0 #FFF) drop-shadow(-1px -1px 0 #FFF) drop-shadow(1px -1px 0 #FFF) drop-shadow(-1px 1px 0 #FFF);
205
- }
206
-
207
- /* CHART STATES /////////////////////////////////////////////////// */
208
-
209
- .elevation-detached {
210
- font: 12px/1.5 "Helvetica Neue", Arial, Helvetica, sans-serif;
211
- height: auto;
212
- width: 100%;
213
- position: relative;
214
- z-index: 0;
215
- }
216
-
217
- .elevation-detached .area {
218
- fill-opacity: var(--ele-alpha, 0.8);
219
- }
220
-
221
- .elevation-detached.elevation-collapsed .elevation-summary {
222
- display: block;
223
- }
224
-
225
- .elevation-detached.elevation-collapsed .elevation-toggle-icon {
226
- top: 5px;
227
- right: 9px;
228
- bottom: 5px;
229
- margin: auto;
230
- }
231
-
232
- .elevation-control.elevation-collapsed > * {
233
- display: none;
234
- }
235
-
236
- .elevation-control.elevation-collapsed > .elevation-toggle-icon {
237
- display: inline-block;
238
- }
239
-
240
- .elevation-detached {
241
- --ele-sum-margin: 12px 35px;
242
- --ele-sum-shadow: none;
243
- --ele-toggle-pos: absolute;
244
- }
245
-
246
- .elevation-expanded {
247
- --ele-close-btn: inline-block;
248
- --ele-toggle-bg: none;
249
- --ele-toggle-pos: absolute;
250
- --ele-toggle-size: 20px;
251
- }
252
-
253
- .inline-summary {
254
- --ele-sum-sep: "\0020\2014\0020";
255
- }
256
-
257
- .elevation-waypoint-icon {
258
- --ele-marker: url(../images/elevation-pushpin.svg);
259
- }
260
-
261
- .elevation-position-icon {
262
- --ele-marker: url(../images/elevation-position.svg);
263
- }
264
-
265
- /* LIME THEME ///////////////////////////////////////////////////// */
266
-
267
- .lime-theme {
268
- --ele-bg: rgba(156, 194, 34, 0.2);
269
- --ele-axis: #566B13;
270
- --ele-area: #9CC222;
271
- --ele-grid: #CCC;
272
- --ele-brush: rgba(99, 126, 11, 0.4);
273
- --ele-poly: #566B13;
274
- --ele-line: #70ab00;
275
- }
276
-
277
- /* STEELBLUE THEME //////////////////////////////////////////////// */
278
-
279
- .steelblue-theme {
280
- --ele-axis: #0D1821;
281
- --ele-area: #4682B4;
282
- --ele-brush: rgba(23, 74, 117, 0.4);
283
- --ele-line: #174A75;
284
- }
285
-
286
- /* PURPLE THEME /////////////////////////////////////////////////// */
287
-
288
- .purple-theme {
289
- --ele-bg: rgba(115, 44, 123, 0.2);
290
- --ele-area: #732C7B;
291
- --ele-brush: rgba(74, 14, 80, 0.4);
292
- --ele-line: #732c7b;
293
- }
294
-
295
- /* YELLOW THEME /////////////////////////////////////////////////// */
296
-
297
- .yellow-theme {
298
- --ele-area: #FF0;
299
- }
300
-
301
- /* RED THEME ////////////////////////////////////////////////////// */
302
-
303
- .red-theme {
304
- --ele-area: #F00;
305
- }
306
-
307
- /* MAGENTA THEME ////////////////////////////////////////////////// */
308
-
309
- .magenta-theme {
310
- --ele-bg: rgba(255, 255, 255, 0.47);
311
- --ele-area: #FF005E;
312
- }
313
-
314
- /* LIGHTBLUE THEME //////////////////////////////////////////////// */
315
-
316
- .lightblue-theme {
317
- --ele-area: #3366CC;
318
- --ele-alpha: 0.45;
319
- --ele-stroke: #4682B4;
320
- --ele-circle: #fff;
321
- --ele-line: #000;
322
- }
323
-
324
- .elevation-detached.lightblue-theme .area {
325
- stroke: #3366CC;
326
- }
327
-
328
- /* leaflet-distance-markers */
329
-
330
- .dist-marker {
331
- font-size: 0.5rem;
332
- border: 1px solid #777;
333
- border-radius: 10px;
334
- text-align: center;
335
- color: #000;
336
- background: #fff;
337
- }
1
+ /* src/index.css */
2
+ .leaflet-hidden {
3
+ visibility: hidden;
4
+ }
5
+ .legend {
6
+ cursor: pointer;
7
+ }
8
+ .leaflet-container {
9
+ z-index: 0;
10
+ }
11
+ .elevation-control .background {
12
+ background-color: var(--ele-bg, rgba(70, 130, 180, 0.2));
13
+ border-radius: 5px;
14
+ overflow: visible;
15
+ display: block;
16
+ touch-action: none;
17
+ user-select: none;
18
+ max-width: 100%;
19
+ }
20
+ .elevation-control .grid,
21
+ .elevation-control .area > foreignObject,
22
+ .elevation-control .axis,
23
+ .elevation-control .tooltip,
24
+ .height-focus.line {
25
+ pointer-events: none;
26
+ }
27
+ .elevation-control .axis line,
28
+ .elevation-control .axis path {
29
+ stroke: var(--ele-axis, #2D1130);
30
+ stroke-width: 1;
31
+ fill: none;
32
+ }
33
+ .elevation-control .grid .tick line {
34
+ stroke: var(--ele-grid, #EEE);
35
+ stroke-width: 1px;
36
+ shape-rendering: crispEdges;
37
+ }
38
+ .elevation-control .grid path {
39
+ stroke-width: 0;
40
+ }
41
+ .elevation-control .axis text,
42
+ .elevation-control .legend text,
43
+ .elevation-control .point text {
44
+ fill: #000;
45
+ font-weight: 700;
46
+ paint-order: stroke fill;
47
+ stroke: #fff;
48
+ stroke-width: 2px;
49
+ }
50
+ .elevation-control .y.axis text {
51
+ text-anchor: end;
52
+ }
53
+ .elevation-control .area {
54
+ fill: var(--ele-area, #4682B4);
55
+ stroke: var(--ele-stroke, #000);
56
+ stroke-width: 1.2;
57
+ paint-order: stroke fill;
58
+ }
59
+ .elevation-control .horizontal-drag-line {
60
+ cursor: row-resize;
61
+ stroke: transparent;
62
+ stroke-dasharray: 5;
63
+ stroke-width: 1.1;
64
+ }
65
+ .elevation-control .active .horizontal-drag-line {
66
+ stroke: #000;
67
+ }
68
+ .elevation-control .horizontal-drag-label {
69
+ fill: #000;
70
+ font-weight: 700;
71
+ paint-order: stroke;
72
+ stroke: #FFF;
73
+ stroke-width: 2px;
74
+ }
75
+ .elevation-control .ruler {
76
+ color: #000;
77
+ cursor: row-resize;
78
+ }
79
+ .elevation-control .mouse-focus-line {
80
+ stroke: #000;
81
+ stroke-width: 1;
82
+ }
83
+ .elevation-control .mouse-focus-label-rect {
84
+ fill: #000;
85
+ fill-opacity: 0.75;
86
+ stroke-width: 1;
87
+ stroke: #444;
88
+ }
89
+ .elevation-control .mouse-focus-label-text {
90
+ fill: #FFF;
91
+ font-size: 10px;
92
+ }
93
+ .elevation-control .brush .overlay {
94
+ cursor: unset;
95
+ }
96
+ .elevation-control .brush .selection {
97
+ fill: var(--ele-brush, rgba(23, 74, 117, 0.4));
98
+ stroke: none;
99
+ fill-opacity: unset;
100
+ }
101
+ .elevation-summary {
102
+ font-family:
103
+ "Lucida Grande",
104
+ "Lucida Sans Unicode",
105
+ Verdana,
106
+ Arial,
107
+ Helvetica,
108
+ sans-serif;
109
+ font-size: 12px;
110
+ margin: var(--ele-sum-margin, 0 auto);
111
+ text-shadow: var(--ele-sum-shadow, 1px 0 0 #FFF, -1px 0 0 #FFF, 0 1px 0 #FFF, 0 -1px 0 #FFF, 1px 1px #FFF, -1px -1px 0 #FFF, 1px -1px 0 #FFF, -1px 1px 0 #FFF);
112
+ }
113
+ .elevation-summary > span:not(:last-child):after {
114
+ content: var(--ele-sum-sep, "");
115
+ }
116
+ .multiline-summary > span {
117
+ display: block;
118
+ }
119
+ .multiline-summary .download {
120
+ float: right;
121
+ margin-top: -3em;
122
+ margin-right: 2em;
123
+ font-weight: bold;
124
+ font-size: 1.2em;
125
+ }
126
+ .elevation-summary .summaryvalue {
127
+ font-weight: bold;
128
+ }
129
+ .elevation-toggle-icon {
130
+ background-color: #fff;
131
+ right: 5px;
132
+ top: 5px;
133
+ height: var(--ele-toggle-size, 36px);
134
+ width: var(--ele-toggle-size, 36px);
135
+ cursor: pointer;
136
+ box-shadow: 0 1px 7px rgba(0, 0, 0, 0.4);
137
+ border-radius: 5px;
138
+ display: inline-block;
139
+ position: var(--ele-toggle-pos, relative);
140
+ }
141
+ .elevation-toggle-icon:before {
142
+ content: "\2716";
143
+ display: var(--ele-close-btn, none);
144
+ color: #000;
145
+ width: 100%;
146
+ line-height: 20px;
147
+ text-align: center;
148
+ font-weight: bold;
149
+ font-size: 15px;
150
+ }
151
+ .leaflet-elevation-pane .height-focus,
152
+ .leaflet-overlay-pane .height-focus {
153
+ stroke: #000;
154
+ fill: var(--ele-circle, var(--ele-area, #FFF));
155
+ }
156
+ .leaflet-elevation-pane .height-focus.line,
157
+ .leaflet-overlay-pane .height-focus.line {
158
+ stroke-width: 2;
159
+ }
160
+ .leaflet-elevation-pane .height-focus-label,
161
+ .leaflet-overlay-pane .height-focus-label {
162
+ font-size: 12px;
163
+ font-weight: 600;
164
+ fill: #000;
165
+ paint-order: stroke;
166
+ stroke: #FFF;
167
+ stroke-width: 2px;
168
+ }
169
+ .elevation-waypoint-icon:before,
170
+ .elevation-position-icon:before {
171
+ content: "";
172
+ width: 100%;
173
+ height: 100%;
174
+ display: inline-block;
175
+ background: var(--ele-marker) no-repeat center center / contain;
176
+ }
177
+ .elevation-polyline {
178
+ stroke: var(--ele-poly, var(--ele-area, #000));
179
+ filter: drop-shadow(1px 1px 0 #FFF) drop-shadow(-1px -1px 0 #FFF) drop-shadow(1px -1px 0 #FFF) drop-shadow(-1px 1px 0 #FFF);
180
+ }
181
+ .elevation-detached {
182
+ font:
183
+ 12px/1.5 "Helvetica Neue",
184
+ Arial,
185
+ Helvetica,
186
+ sans-serif;
187
+ height: auto;
188
+ width: 100%;
189
+ position: relative;
190
+ z-index: 0;
191
+ }
192
+ .elevation-detached .area {
193
+ fill-opacity: var(--ele-alpha, 0.8);
194
+ }
195
+ .elevation-detached.elevation-collapsed .elevation-summary {
196
+ display: block;
197
+ }
198
+ .elevation-detached.elevation-collapsed .elevation-toggle-icon {
199
+ top: 5px;
200
+ right: 9px;
201
+ bottom: 5px;
202
+ margin: auto;
203
+ }
204
+ .elevation-control.elevation-collapsed > * {
205
+ display: none;
206
+ }
207
+ .elevation-control.elevation-collapsed > .elevation-toggle-icon {
208
+ display: inline-block;
209
+ }
210
+ .elevation-detached {
211
+ --ele-sum-margin: 12px 35px;
212
+ --ele-sum-shadow: none;
213
+ --ele-toggle-pos: absolute;
214
+ }
215
+ .elevation-expanded {
216
+ --ele-close-btn: inline-block;
217
+ --ele-toggle-bg: none;
218
+ --ele-toggle-pos: absolute;
219
+ --ele-toggle-size: 20px;
220
+ }
221
+ .inline-summary {
222
+ --ele-sum-sep: " \2014 ";
223
+ }
224
+ .elevation-waypoint-icon {
225
+ --ele-marker: url(../images/elevation-pushpin.svg);
226
+ }
227
+ .elevation-position-icon {
228
+ --ele-marker: url(../images/elevation-position.svg);
229
+ }
230
+ .lime-theme {
231
+ --ele-bg: rgba(156, 194, 34, 0.2);
232
+ --ele-axis: #566B13;
233
+ --ele-area: #9CC222;
234
+ --ele-grid: #CCC;
235
+ --ele-brush: rgba(99, 126, 11, 0.4);
236
+ --ele-poly: #566B13;
237
+ --ele-line: #70ab00;
238
+ }
239
+ .steelblue-theme {
240
+ --ele-axis: #0D1821;
241
+ --ele-area: #4682B4;
242
+ --ele-brush: rgba(23, 74, 117, 0.4);
243
+ --ele-line: #174A75;
244
+ }
245
+ .purple-theme {
246
+ --ele-bg: rgba(115, 44, 123, 0.2);
247
+ --ele-area: #732C7B;
248
+ --ele-brush: rgba(74, 14, 80, 0.4);
249
+ --ele-line: #732c7b;
250
+ }
251
+ .yellow-theme {
252
+ --ele-area: #FF0;
253
+ }
254
+ .red-theme {
255
+ --ele-area: #F00;
256
+ }
257
+ .magenta-theme {
258
+ --ele-bg: rgba(255, 255, 255, 0.47);
259
+ --ele-area: #FF005E;
260
+ }
261
+ .lightblue-theme {
262
+ --ele-area: #3366CC;
263
+ --ele-alpha: 0.45;
264
+ --ele-stroke: #4682B4;
265
+ --ele-circle: #fff;
266
+ --ele-line: #000;
267
+ }
268
+ .elevation-detached.lightblue-theme .area {
269
+ stroke: #3366CC;
270
+ }
271
+ .dist-marker {
272
+ font-size: 0.5rem;
273
+ border: 1px solid #777;
274
+ border-radius: 10px;
275
+ text-align: center;
276
+ color: #000;
277
+ background: #fff;
278
+ }