Skip to content

Commit c59747c

Browse files
committed
OWC-137 add color classes markers
1 parent bff8f31 commit c59747c

4 files changed

Lines changed: 42 additions & 42 deletions

File tree

src/blocks/owc-openkaarten/streetmap/assets/scripts/utils/make-marker-cluster.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ export const makeMarkerCluster = ({
2828
return L.divIcon({
2929
html: `
3030
<div
31-
class="owc-openkaarten-streetmap__cluster-group__circle owc-openkaarten-streetmap__cluster-group__circle-${color.replace("#", "")}"
31+
class="owc-openkaarten-streetmap__cluster-group__circle ${color}"
3232
>
3333
<span class="owc-openkaarten-streetmap__cluster-group__count">${count}</span>
3434
</div>`,

src/blocks/owc-openkaarten/streetmap/assets/scripts/utils/make-marker-icon.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ export const makeMarkerIcon = (L, { marker, defaultColor }) => {
2828
return L.divIcon({
2929
className: 'leaflet-custom-icon--hosted-svg',
3030
html: L.Util.template(
31-
`<div class="leaflet-svg leaflet-svg-${iconColor.replace("#", "")}"><img src=${iconSettings.iconUrl} /></div>`, iconSettings
31+
`<div class="leaflet-svg ${iconColor}"><img src=${iconSettings.iconUrl} /></div>`, iconSettings
3232
),
3333
iconAnchor: [12, 32],
3434
iconSize: [25, 30],

src/blocks/owc-openkaarten/streetmap/assets/scripts/vue/BaseFilters.vue

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ onUnmounted(() => {
155155
<div
156156
:class="[
157157
'owc-openkaarten-streetmap__filters__body__list-item__dl-indicator',
158-
'owc-openkaarten-streetmap__filters__body__list-item__dl-indicator-' + getDatalayerColor(layer).replace('#', '')
158+
getDatalayerColor(layer)
159159
]"
160160
/>
161161
</li>
@@ -243,43 +243,43 @@ onUnmounted(() => {
243243
height: 28px;
244244
border-radius: 50%;
245245
opacity: 0.5;
246-
&-0072B2 {
246+
&.marker-blue {
247247
background-color: #0072B2;
248248
}
249-
&-9D6D00 {
249+
&.marker-organge {
250250
background-color: #9D6D00;
251251
}
252-
&-C15500 {
252+
&.marker--red {
253253
background-color: #C15500;
254254
}
255-
&-008661 {
255+
&.marker-green {
256256
background-color: #008661;
257257
}
258-
&-7E7722 {
258+
&.marker-yellow {
259259
background-color: #7E7722;
260260
}
261-
&-A26085 {
261+
&.marker-purple {
262262
background-color: #A26085;
263263
}
264-
&-3B7BA0 {
264+
&.marker-turquoise {
265265
background-color: #3B7BA0;
266266
}
267-
&-A0522D {
267+
&.marker-brown {
268268
background-color: #A0522D;
269269
}
270-
&-757575 {
270+
&.marker-gray {
271271
background-color: #757575;
272272
}
273-
&-000000 {
273+
&.marker-black {
274274
background-color: #000000;
275275
}
276-
&-555555 {
276+
&.marker-dargray {
277277
background-color: #555555;
278278
}
279-
&-003366 {
279+
&.marker-navy-blue {
280280
background-color: #003366;
281281
}
282-
&-4B0082 {
282+
&.marker-deep-purple {
283283
background-color: #4B0082;
284284
}
285285
}

src/blocks/owc-openkaarten/streetmap/assets/scripts/vue/TheMap.vue

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -421,43 +421,43 @@ const handleSearch = async (query) => {
421421
rgba(255, 255, 255, 0.05) 75%
422422
);
423423
background: var(--owc-cluster-background);
424-
&-0072B2 {
424+
&.marker-blue {
425425
--owc-openkaarten-streetmap--cluster-color: #0072B2;
426426
}
427-
&-9D6D00 {
427+
&.marker-orange {
428428
--owc-openkaarten-streetmap--cluster-color: #9D6D00;
429429
}
430-
&-C15500 {
430+
&.marker-red {
431431
--owc-openkaarten-streetmap--cluster-color: #C15500;
432432
}
433-
&-008661 {
433+
&.marker-green {
434434
--owc-openkaarten-streetmap--cluster-color: #008661;
435435
}
436-
&-7E7722 {
436+
&.marker-yellow {
437437
--owc-openkaarten-streetmap--cluster-color: #7E7722;
438438
}
439-
&-A26085 {
439+
&.marker-purple {
440440
--owc-openkaarten-streetmap--cluster-color: #A26085;
441441
}
442-
&-3B7BA0 {
442+
&.marker-turquoise {
443443
--owc-openkaarten-streetmap--cluster-color: #3B7BA0;
444444
}
445-
&-A0522D {
445+
&.marker-brown {
446446
--owc-openkaarten-streetmap--cluster-color: #A0522D;
447447
}
448-
&-757575 {
448+
&.marker-gray {
449449
--owc-openkaarten-streetmap--cluster-color: #757575;
450450
}
451-
&-000000 {
451+
&.marker-black {
452452
--owc-openkaarten-streetmap--cluster-color: #000000;
453453
}
454-
&-555555 {
454+
&.marker-darkgray {
455455
--owc-openkaarten-streetmap--cluster-color: #555555;
456456
}
457-
&-003366 {
457+
&.marker-navy-blue {
458458
--owc-openkaarten-streetmap--cluster-color: #003366;
459459
}
460-
&-4B0082 {
460+
&.marker-deep-purple {
461461
--owc-openkaarten-streetmap--cluster-color: #4B0082;
462462
}
463463
}
@@ -495,43 +495,43 @@ const handleSearch = async (query) => {
495495
img {
496496
transform: rotate(45deg);
497497
}
498-
&-0072B2 {
498+
&.marker-blue {
499499
border: 4px solid #0072B2;
500500
}
501-
&-9D6D00 {
501+
&.marker-orange {
502502
border: 4px solid #9D6D00;
503503
}
504-
&-C15500 {
504+
&.marker-red {
505505
border: 4px solid #C15500;
506506
}
507-
&-008661 {
507+
&.marker-green {
508508
border: 4px solid #008661;
509509
}
510-
&-7E7722 {
510+
&.marker-yellow {
511511
border: 4px solid #7E7722;
512512
}
513-
&-A26085 {
513+
&.marker-purple {
514514
border: 4px solid #A26085;
515515
}
516-
&-3B7BA0 {
516+
&.marker-turquoise {
517517
border: 4px solid #3B7BA0;
518518
}
519-
&-A0522D {
519+
&.marker-brown {
520520
border: 4px solid #A0522D;
521521
}
522-
&-757575 {
522+
&.marker-gray {
523523
border: 4px solid #757575;
524524
}
525-
&-000000 {
525+
&.marker-black {
526526
border: 4px solid #000000;
527527
}
528-
&-555555 {
528+
&.marker-darkgray {
529529
border: 4px solid #555555;
530530
}
531-
&-003366 {
531+
&.marker-navy-blue {
532532
border: 4px solid #003366;
533533
}
534-
&-4B0082 {
534+
&.marker-deep-purple {
535535
border: 4px solid #4B0082;
536536
}
537537
}

0 commit comments

Comments
 (0)