Skip to content

Commit ce43490

Browse files
authored
Merge pull request #108 from MrAlders0n/copilot/reposition-gps-overlay-elements
Reposition GPS overlay elements on coverage map
2 parents 3549af7 + 13224f7 commit ce43490

2 files changed

Lines changed: 72 additions & 11 deletions

File tree

content/tailwind.css

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,8 @@
3737
--text-xs--line-height: calc(1 / 0.75);
3838
--text-sm: 0.875rem;
3939
--text-sm--line-height: calc(1.25 / 0.875);
40+
--text-base: 1rem;
41+
--text-base--line-height: calc(1.5 / 1);
4042
--text-lg: 1.125rem;
4143
--text-lg--line-height: calc(1.75 / 1.125);
4244
--text-xl: 1.25rem;
@@ -228,6 +230,9 @@
228230
.static {
229231
position: static;
230232
}
233+
.top-2 {
234+
top: calc(var(--spacing) * 2);
235+
}
231236
.right-2 {
232237
right: calc(var(--spacing) * 2);
233238
}
@@ -237,6 +242,9 @@
237242
.left-2 {
238243
left: calc(var(--spacing) * 2);
239244
}
245+
.z-10 {
246+
z-index: 10;
247+
}
240248
.mt-0\.5 {
241249
margin-top: calc(var(--spacing) * 0.5);
242250
}
@@ -264,6 +272,9 @@
264272
.inline {
265273
display: inline;
266274
}
275+
.h-6 {
276+
height: calc(var(--spacing) * 6);
277+
}
267278
.h-8 {
268279
height: calc(var(--spacing) * 8);
269280
}
@@ -273,6 +284,9 @@
273284
.min-h-screen {
274285
min-height: 100vh;
275286
}
287+
.w-6 {
288+
width: calc(var(--spacing) * 6);
289+
}
276290
.w-8 {
277291
width: calc(var(--spacing) * 8);
278292
}
@@ -306,6 +320,9 @@
306320
.grid-cols-2 {
307321
grid-template-columns: repeat(2, minmax(0, 1fr));
308322
}
323+
.flex-col {
324+
flex-direction: column;
325+
}
309326
.flex-wrap {
310327
flex-wrap: wrap;
311328
}
@@ -371,14 +388,34 @@
371388
.rounded-xl {
372389
border-radius: var(--radius-xl);
373390
}
391+
.rounded-t-xl {
392+
border-top-left-radius: var(--radius-xl);
393+
border-top-right-radius: var(--radius-xl);
394+
}
395+
.rounded-b-none {
396+
border-bottom-right-radius: 0;
397+
border-bottom-left-radius: 0;
398+
}
399+
.rounded-b-xl {
400+
border-bottom-right-radius: var(--radius-xl);
401+
border-bottom-left-radius: var(--radius-xl);
402+
}
374403
.border {
375404
border-style: var(--tw-border-style);
376405
border-width: 1px;
377406
}
407+
.border-x {
408+
border-inline-style: var(--tw-border-style);
409+
border-inline-width: 1px;
410+
}
378411
.border-t {
379412
border-top-style: var(--tw-border-style);
380413
border-top-width: 1px;
381414
}
415+
.border-b {
416+
border-bottom-style: var(--tw-border-style);
417+
border-bottom-width: 1px;
418+
}
382419
.border-slate-700 {
383420
border-color: var(--color-slate-700);
384421
}
@@ -448,6 +485,9 @@
448485
.py-0\.5 {
449486
padding-block: calc(var(--spacing) * 0.5);
450487
}
488+
.py-1\.5 {
489+
padding-block: calc(var(--spacing) * 1.5);
490+
}
451491
.py-2 {
452492
padding-block: calc(var(--spacing) * 2);
453493
}
@@ -457,13 +497,20 @@
457497
.text-center {
458498
text-align: center;
459499
}
500+
.text-right {
501+
text-align: right;
502+
}
460503
.font-mono {
461504
font-family: var(--font-mono);
462505
}
463506
.text-2xl {
464507
font-size: var(--text-2xl);
465508
line-height: var(--tw-leading, var(--text-2xl--line-height));
466509
}
510+
.text-base {
511+
font-size: var(--text-base);
512+
line-height: var(--tw-leading, var(--text-base--line-height));
513+
}
467514
.text-lg {
468515
font-size: var(--text-lg);
469516
line-height: var(--tw-leading, var(--text-lg--line-height));
@@ -622,6 +669,17 @@
622669
background-color: var(--color-emerald-600);
623670
}
624671
}
672+
.sm\:h-8 {
673+
@media (width >= 40rem) {
674+
height: calc(var(--spacing) * 8);
675+
}
676+
}
677+
.sm\:text-xl {
678+
@media (width >= 40rem) {
679+
font-size: var(--text-xl);
680+
line-height: var(--tw-leading, var(--text-xl--line-height));
681+
}
682+
}
625683
}
626684
@property --tw-space-y-reverse {
627685
syntax: "*";

index.html

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -147,23 +147,26 @@ <h2 class="text-sm font-medium text-slate-300 uppercase tracking-wide">Settings<
147147
src="https://yow.meshmapper.net/embed.php?cov_grid=1&fail_grid=1&pings=0&repeaters=1&rep_coverage=0&grid_lines=0&lat=45.42150&lon=-75.69720&meters=10000">
148148
</iframe>
149149

150-
<!-- Map Overlays - Single Row Horizontal Layout -->
151-
<div class="absolute bottom-2 left-2 right-2 flex gap-2 justify-between items-center">
152-
<!-- GPS Accuracy - Left -->
153-
<div class="bg-slate-900/80 backdrop-blur-sm border border-slate-700 rounded-lg px-3 py-2 text-xs text-slate-300 whitespace-nowrap flex-shrink-0">
150+
<!-- Map Overlays -->
151+
<!-- Top-right corner: GPS Accuracy and Distance stacked vertically -->
152+
<div class="absolute top-2 right-2 z-10 flex flex-col gap-2 text-right">
153+
<!-- GPS Accuracy -->
154+
<div class="bg-slate-900/80 backdrop-blur-sm border border-slate-700 rounded-lg px-3 py-2 text-xs text-slate-300">
154155
<span id="gpsAcc">±-</span>
155156
</div>
156157

157-
<!-- GPS Coordinates - Center (flexible but constrained) -->
158-
<div class="bg-slate-900/80 backdrop-blur-sm border border-slate-700 rounded-lg px-3 py-2 text-xs text-slate-300 text-center flex-1 min-w-0">
159-
<div id="gpsInfo" class="truncate">-</div>
160-
</div>
161-
162-
<!-- Distance from Last Ping - Right -->
163-
<div class="bg-slate-900/80 backdrop-blur-sm border border-slate-700 rounded-lg px-3 py-2 text-xs text-slate-300 whitespace-nowrap flex-shrink-0">
158+
<!-- Distance from Last Ping -->
159+
<div class="bg-slate-900/80 backdrop-blur-sm border border-slate-700 rounded-lg px-3 py-2 text-xs text-slate-300">
164160
<span id="distanceInfo">-</span>
165161
</div>
166162
</div>
163+
164+
<!-- Bottom: GPS Coordinates spanning full width -->
165+
<div class="absolute bottom-2 left-2 right-2 z-10">
166+
<div class="bg-slate-900/80 backdrop-blur-sm border border-slate-700 rounded-lg px-3 py-2 text-xs text-slate-300 text-center">
167+
<div id="gpsInfo">-</div>
168+
</div>
169+
</div>
167170
</section>
168171

169172
<!-- Control Buttons -->

0 commit comments

Comments
 (0)