Skip to content

Commit f1f4c5a

Browse files
ISSUE #1484: Show route info on heatmap
1 parent 68ca32e commit f1f4c5a

File tree

8 files changed

+667
-202
lines changed

8 files changed

+667
-202
lines changed

package-lock.json

Lines changed: 0 additions & 185 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,5 @@
66
"tailwindcss": "^4.1.13",
77
"webpack": "^5.102.1",
88
"webpack-cli": "^6.0.1"
9-
},
10-
"dependencies": {
11-
"@turf/helpers": "^7.3.1",
12-
"@turf/point-to-line-distance": "^7.3.1"
139
}
1410
}

public/css/dist/tailwind.min.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

public/css/tailwind.css

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,10 @@
7373
filter: grayscale(100%) brightness(75%);
7474
}
7575

76+
.leaflet-popup-content-wrapper .leaflet-popup-content{
77+
@apply text-base! m-0! leading-none!;
78+
}
79+
7680
.leaflet-control--fly-to-places {
7781
@apply rounded-sm border-2 border-black/[.3] bg-white bg-clip-padding divide-y divide-grey-yo;
7882

public/css/tailwind.output.css

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1063,6 +1063,9 @@
10631063
max-width: 96rem;
10641064
}
10651065
}
1066+
.m-4 {
1067+
margin: calc(var(--spacing) * 4);
1068+
}
10661069
.-mx-4 {
10671070
margin-inline: calc(var(--spacing) * -4);
10681071
}
@@ -1866,9 +1869,6 @@
18661869
.w-\[200px\] {
18671870
width: 200px;
18681871
}
1869-
.w-\[300px\] {
1870-
width: 300px;
1871-
}
18721872
.w-\[rem\] {
18731873
width: rem;
18741874
}
@@ -1881,9 +1881,6 @@
18811881
.w-full {
18821882
width: 100%;
18831883
}
1884-
.w-md {
1885-
width: var(--container-md);
1886-
}
18871884
.max-w-\(--breakpoint-sm\) {
18881885
max-width: var(--breakpoint-sm);
18891886
}
@@ -4427,6 +4424,13 @@
44274424
-webkit-filter: grayscale(100%) brightness(75%);
44284425
filter: grayscale(100%) brightness(75%);
44294426
}
4427+
.leaflet-popup-content-wrapper .leaflet-popup-content {
4428+
margin: calc(var(--spacing) * 0) !important;
4429+
font-size: var(--text-base) !important;
4430+
line-height: var(--tw-leading, var(--text-base--line-height)) !important;
4431+
--tw-leading: 1 !important;
4432+
line-height: 1 !important;
4433+
}
44304434
.leaflet-control--fly-to-places {
44314435
:where(& > :not(:last-child)) {
44324436
--tw-divide-y-reverse: 0;

public/js/dist/app.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

public/js/ui/heatmap.js

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import {DataTableStorage, FilterManager} from "../filters";
2-
import { pointToLineDistance } from "@turf/point-to-line-distance";
3-
import { point, lineString } from "@turf/helpers";
2+
import { pointToLineDistance, point, lineString } from "../../libraries/turf";
43

54
class HeatmapDrawer {
65
constructor(wrapper, config, modalManager) {
@@ -80,9 +79,9 @@ class HeatmapDrawer {
8079
});
8180

8281
const html = `
83-
<div class="max-h-[200px] overflow-y-auto">
84-
<div class="text-sm">${nearby.length} nearby route(s):</div>
85-
<ul class="divide-default w-[300px] divide-y divide-gray-200">
82+
<div class="m-4 text-sm max-h-[200px] overflow-y-auto">
83+
<div class="font-medium">${nearby.length} nearby route(s):</div>
84+
<ul class="divide-default divide-y divide-gray-200">
8685
${nearby.map(entry => `
8786
<li class="py-2">
8887
<a href="#" class="block truncate font-medium text-blue-600 hover:underline" data-model-content-url="/activity/${entry.route.id}.html"> ${entry.route.name} </a>

0 commit comments

Comments
 (0)