designsss

This commit is contained in:
LionTion committed 2026-09-20 21:46:48 +02:00
1 parent 9401ef3a9e
commit eb64159275
5 files changed
+202 -37

No files matched your search

+20
View File
@@ -98,3 +98,23 @@ a {
align-items: center;
justify-content: center;
}
.maplibregl-user-location-dot::before {
display: none !important;
}
.maplibregl-user-location-dot::after {
display: none !important;
}
.maplibregl-user-location-dot {
background-image: url('/icons/person.svg') !important;
background-size: contain !important;
background-repeat: no-repeat !important;
background-position: center !important;
background-color: transparent !important;
box-shadow: none !important;
border: none !important;
width: 42px !important;
height: 42px !important;
}
+20 -7
View File
@@ -1,6 +1,6 @@
'use client';
import React, { useEffect, useRef, useState, useCallback } from 'react';
import React, { useEffect, useRef, useState, useCallback, createElement } from 'react';
import * as maplibregl from 'maplibre-gl';
import 'maplibre-gl/dist/maplibre-gl.css';
import styles from '@/css/MapView.module.css';
@@ -73,7 +73,7 @@ export default function MapView({
source: 'osm-tiles',
minzoom: 0,
maxzoom: 19,
},
}
],
};
@@ -86,14 +86,21 @@ export default function MapView({
map.addControl(new maplibregl.NavigationControl({ visualizePitch: true }), 'bottom-right');
const el = document.createElement("img");
el.src = "/icons/person.svg";
el.alt = "You";
el.width = 42;
el.className = styles["sword"];
const geolocate = new maplibregl.GeolocateControl({
positionOptions: {
enableHighAccuracy: true,
},
trackUserLocation: true,
showUserLocation: true,
showAccuracyCircle: true,
showAccuracyCircle: false,
});
geolocate._dotElement = el;
map.addControl(geolocate, 'bottom-right');
map.addControl(new maplibregl.ScaleControl({ unit: 'metric' }), 'bottom-left');
@@ -135,15 +142,21 @@ export default function MapView({
markers.forEach((markerData) => {
if (!currentMarkers.has(markerData.id)) {
const popup = new maplibregl.Popup({ offset: 25, className: styles["marker"] }).setHTML(
/*const popup = new maplibregl.Popup({ offset: 25, className: styles["marker"] }).setHTML(
`<strong>${markerData.title}</strong>${
markerData.description ? `<p style="margin:4px 0 0;font-size:12px;">${markerData.description}</p>` : ''
}`
);
);*/
const newMarker = new maplibregl.Marker({ color: '#e11d48', })
const el = document.createElement("img");
el.src = "/icons/Schwert-gps.svg";
el.alt = "GPS Point";
el.width = 80;
el.className = styles["sword"];
const newMarker = new maplibregl.Marker({ element: el, anchor: "bottom" })
.setLngLat([markerData.lng, markerData.lat])
.setPopup(popup)
//.setPopup(popup)
.addTo(map);
newMarker.getElement().addEventListener('click', () => {
+8 -19
View File
@@ -51,29 +51,18 @@ export default function Tour() {
requestPosition();
return () => clearTimeout(timerId);
}, []);
}, []);
return (
<div className={styles["screen-container"]}>
<div className={styles["top-bar"]}>
<p>{"Ruf: " + points}</p>
<p>{"Players: " + playersStr}</p>
<br></br>
<ChargedButton onAction={() => {
setTourCode("");
setCompletedRiddles("");
setPlayers("");
setPoints("");
setStep("0");
}} holdDuration={500}>
Zurücksetzen
</ChargedButton>
<ChargedButton onAction={() => {
}} holdDuration={500}>
Test
</ChargedButton>
<div className={styles["top-bar-content"]}>
<div className={styles["points-outer-box"]}>
<div className={styles["points-inner-box"]}>
Your content goes here
</div>
</div>
</div>
</div>
<div className={styles["main-content"]}>
<div className={styles["map"]}>
+72 -9
View File
@@ -4,14 +4,67 @@
height: 100%;
min-height: 400px;
overflow: hidden;
canvas {
filter: sepia(.45) saturate(.8) hue-rotate(-8deg) brightness(0.8) contrast(1.2);
}
}
.mapContainer {
position: relative;
width: 100%;
height: 100%;
min-height: 500px;
}
/*.mapContainer::after {
content: "";
position: absolute;
inset: 0;
pointer-events: none;
z-index: 5;
mix-blend-mode: multiply;
opacity: 0.5;
background:
radial-gradient(circle at 12% 35%, rgba(60, 40, 15, 0.12) 0, rgba(60, 40, 15, 0) 40%),
radial-gradient(circle at 85% 15%, rgba(90, 60, 20, 0.15) 0, rgba(90, 60, 20, 0) 35%),
radial-gradient(circle at 45% 75%, rgba(70, 45, 10, 0.14) 0, rgba(70, 45, 10, 0) 45%),
radial-gradient(circle at 70% 90%, rgba(50, 30, 10, 0.1) 0, rgba(50, 30, 10, 0) 30%),
repeating-linear-gradient(
133deg,
rgba(80, 50, 20, 0.03) 0px,
rgba(80, 50, 20, 0.03) 2px,
transparent 2px,
transparent 27px
),
repeating-linear-gradient(
-23deg,
rgba(50, 30, 10, 0.02) 0px,
rgba(50, 30, 10, 0.02) 1px,
transparent 1px,
transparent 41px
),
radial-gradient(ellipse at 50% 50%, rgba(200, 170, 120, 0.1) 0%, rgba(120, 85, 45, 0.25) 100%);
background-size: 100% 100%;
}*/
/* Vignette / aged darkening toward the corners */
.mapContainer::before {
content: "";
position: absolute;
inset: 0;
pointer-events: none;
z-index: 4;
background:
radial-gradient(ellipse at center, transparent 55%, rgba(90, 60, 25, 0.28) 100%),
radial-gradient(ellipse at 50% 20%, rgba(0,0,0,0.06) 0, transparent 60%),
radial-gradient(ellipse at 85% 90%, rgba(20, 10, 0, 0.12) 0, transparent 55%);
mix-blend-mode: multiply;
}
.controlOverlay {
position: absolute;
top: 12px;
@@ -20,18 +73,19 @@
display: flex;
flex-direction: column;
gap: 8px;
background: rgba(18, 18, 18, 0.85);
/* Aged-paper / wax-seal style panel */
background: rgba(238, 222, 196, 0.9);
backdrop-filter: blur(8px);
padding: 10px 14px;
border-radius: 8px;
border: 1px solid rgba(255, 255, 255, 0.12);
color: #fff;
border: 1px solid rgba(140, 102, 50, 0.35);
color: #4a371c;
font-family: var(--font-geist-sans), sans-serif;
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}
.precacheButton {
background: #2563eb;
background: rgba(160, 110, 55, 0.95);
color: white;
border: none;
padding: 8px 12px;
@@ -43,7 +97,7 @@
}
.precacheButton:hover:not(:disabled) {
background: #1d4ed8;
background: rgba(120, 80, 40, 1);
}
.precacheButton:disabled {
@@ -61,21 +115,30 @@
.progressBar {
width: 100%;
height: 6px;
background: rgba(255, 255, 255, 0.2);
background: rgba(140, 102, 50, 0.3);
border-radius: 3px;
overflow: hidden;
}
.progressFill {
height: 100%;
background: #10b981;
background: #a06f37;
transition: width 0.2s ease;
}
.marker {
color: black;
color: #4a2f14;
button {
color: black;
color: #4a2f14;
}
}
/* maplibre dark-theme-ish control icons re-themed to parchment palette */
.mapWrapper svg {
fill: #4a2f14 !important;
}
.sword {
filter: drop-shadow(0px 0px 6px #0009);
}
+82 -2
View File
@@ -5,10 +5,73 @@
width: 100%;
overflow: hidden;
}
.top-bar {
padding: 8px;
position: absolute;
top: 0;
left: 0;
flex-shrink: 0;
width: 100%;
height: 120px;
z-index: 2;
background-color: transparent;
--corner-radius: 20px;
--border-width: 2px;
}
.top-bar::before {
content: "";
position: absolute;
inset: 0;
background-color: var(--dark-brown, #3d2b1f);
z-index: -2;
--r: var(--corner-radius);
-webkit-mask:
linear-gradient(black, black) top center / 100% calc(100% - var(--r) + 1px) no-repeat,
linear-gradient(black, black) top center / calc(100% - 2 * var(--r) + 1px) 100% no-repeat,
radial-gradient(circle at 0 100%, transparent var(--r), black calc(var(--r) + 0.5px)) bottom left / var(--r) var(--r) no-repeat,
radial-gradient(circle at 100% 100%, transparent var(--r), black calc(var(--r) + 0.5px)) bottom right / var(--r) var(--r) no-repeat;
mask:
linear-gradient(black, black) top center / 100% calc(100% - var(--r) + 1px) no-repeat,
linear-gradient(black, black) top center / calc(100% - 2 * var(--r) + 1px) 100% no-repeat,
radial-gradient(circle at 0 100%, transparent var(--r), black calc(var(--r) + 0.5px)) bottom left / var(--r) var(--r) no-repeat,
radial-gradient(circle at 100% 100%, transparent var(--r), black calc(var(--r) + 0.5px)) bottom right / var(--r) var(--r) no-repeat;
}
.top-bar::after {
content: "";
position: absolute;
inset: 0;
background-color: transparent;
background-image: url('/bg/Hintergrund_ohne_Verzierung.webp');
background-size: cover;
background-position: top center;
box-shadow: inset 0px -15px 32px 0px #0000004d;
z-index: -1;
--b: var(--border-width);
--r-inner: calc(var(--corner-radius) + var(--b));
-webkit-mask:
linear-gradient(black, black) top center / 100% calc(100% - var(--r-inner) + 1px) no-repeat,
linear-gradient(black, black) top center / calc(100% - 2 * var(--r-inner) + 1px) calc(100% - var(--b)) no-repeat,
radial-gradient(circle at 0 100%, transparent var(--r-inner), black calc(var(--r-inner) + 0.5px)) bottom left / var(--r-inner) var(--r-inner) no-repeat,
radial-gradient(circle at 100% 100%, transparent var(--r-inner), black calc(var(--r-inner) + 0.5px)) bottom right / var(--r-inner) var(--r-inner) no-repeat;
mask:
linear-gradient(black, black) top center / 100% calc(100% - var(--r-inner) + 1px) no-repeat,
linear-gradient(black, black) top center / calc(100% - 2 * var(--r-inner) + 1px) calc(100% - var(--b)) no-repeat,
radial-gradient(circle at 0 100%, transparent var(--r-inner), black calc(var(--r-inner) + 0.5px)) bottom left / var(--r-inner) var(--r-inner) no-repeat,
radial-gradient(circle at 100% 100%, transparent var(--r-inner), black calc(var(--r-inner) + 0.5px)) bottom right / var(--r-inner) var(--r-inner) no-repeat;
}
.top-bar-content {
padding: 8px;
position: relative;
z-index: 1;
}
.main-content {
@@ -20,8 +83,10 @@
}
.map {
z-index: 1;
width: 100%;
height: 100%;
position: relative;
}
.riddle-overlay {
@@ -45,3 +110,18 @@
background-color: #000000AA;
z-index: 10;
}
.points-outer-box {
position: relative;
width: 300px;
height: 200px;
background-color: #3498db;
color: #fff;
-webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 320 200'%3E%3Cpath d='M 20 0 Q 0 0 0 20 L 0 180 Q 0 200 20 200 L 300 200 Q 320 200 320 180 L 320 200 Z'/%3E%3C/svg%3E");
}
.points-inner-box {
padding: 30px;
color: #fff;
}