Add OpenStreetMaps Attribution (#10691)

This commit is contained in:
Malte Jürgens
2021-12-26 05:38:40 +01:00
committed by GitHub
parent d7f0335f24
commit 75abe59951
4 changed files with 16 additions and 7 deletions

View File

@@ -250,7 +250,7 @@ export default defineComponent({
map = new Map({
container: container.value!,
style: style.value,
attributionControl: false,
customAttribution: '© OpenStreetMap contributors',
dragRotate: false,
logoPosition: 'bottom-right',
...props.defaultView,

View File

@@ -85,7 +85,7 @@ export default defineComponent({
map = new Map({
container: mapContainer.value!,
style: style.value,
attributionControl: false,
customAttribution: '© OpenStreetMap contributors',
...(defaultView.value || {}),
...(mapboxKey ? { accessToken: mapboxKey } : {}),
});

View File

@@ -125,7 +125,7 @@ export default defineComponent({
map = new Map({
container: 'map-container',
style: style.value,
attributionControl: false,
customAttribution: '© OpenStreetMap contributors',
dragRotate: false,
...props.camera,
...(mapboxKey ? { accessToken: mapboxKey } : {}),

View File

@@ -1,4 +1,3 @@
.mapboxgl-map {
font: inherit;
}
@@ -71,7 +70,8 @@
}
.mapboxgl-search-location-dot {
&, &::before {
&,
&::before {
background-color: var(--purple);
}
}
@@ -79,7 +79,7 @@
.mapboxgl-ctrl-attrib.mapboxgl-compact {
min-width: 24px;
min-height: 24px;
color: var(--foreground-subdued);
color: var(--foreground-normal);
background: var(--background-input) !important;
box-shadow: var(--card-shadow);
@@ -108,6 +108,16 @@
}
}
.mapboxgl-ctrl-attrib:not(.mapboxgl-compact) {
font-size: 0.8em;
color: var(--foreground-normal);
background: var(--background-input);
border-radius: 6px 0 0 0;
border: 1px solid var(--border-normal);
border-right: none;
border-bottom: none;
}
.mapboxgl-ctrl-geocoder {
font-size: inherit !important;
font-family: inherit !important;
@@ -171,7 +181,6 @@
pointer-events: none;
}
.maplibregl-ctrl-top-right {
max-width: 80%;
}