Skip to content

Commit 37645e1

Browse files
committed
feat: update the homepage to be interactive
1 parent 9927d96 commit 37645e1

3 files changed

Lines changed: 910 additions & 21 deletions

File tree

src/routes/homepage.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ pub fn routes() -> Router<SharedState> {
3737
#[template(path = "homepage.html")]
3838
struct HomepageTemplate {
3939
shared: SharedContext,
40+
towns: Vec<Town>,
4041
}
4142

4243
#[derive(Template, WebTemplate)]
@@ -69,6 +70,7 @@ struct UpdateRunnerInfoTemplate {
6970
async fn homepage(State(state): State<SharedState>, NoUser: NoUser) -> HomepageTemplate {
7071
HomepageTemplate {
7172
shared: SharedContext::new(&state.app_info, None),
73+
towns: state.town_service.find_all().await,
7274
}
7375
}
7476

templates/completed_towns_map.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -342,8 +342,8 @@
342342
d="M 300.97 140 301.16 140.93 301.67 143.57 301.98 145.05 302.45 147.46 302.6 148 302.91 149.2 303.1 150.04 303.9 153.53 305.31 161.01 305.37 161.43 306.11 164.87 306.35 165.96 306.57 167.05 307.22 170.02 300.46 173.51 300.26 173.63 298.59 174.46 291.44 175.1 291.64 175.97 292.61 180.43 291.92 180.44 291.49 180.41 291.25 180.39 288.13 180.15 287.97 180.14 285.48 179.93 285.35 179.94 282.62 181.01 281.68 181.37 280.24 181.94 279.79 182.11 279.62 182.19 279.39 182.27 279.04 181.46 276.64 175.97 275.89 174.25 274.99 172.18 273.94 169.78 273.92 169.71 273.68 169.14 273.86 167.82 274.14 165.75 274.86 160.5 275.49 156.08 276.32 150.6 277.7 141.81 280.69 141.52 285.1 141.02 285.3 140.98 286.29 140.86 286.85 140.8 300.46 139.29 300.79 139.23 300.97 140 Z"
343343
/>
344344
<path
345-
id="Harwington"
346-
data-tooltip="Harwington"
345+
id="Harwinton"
346+
data-tooltip="Harwinton"
347347
d="M 268.83 104.71 268.94 104.72 270.56 104.72 271.71 104.73 274.96 104.74 277.4 104.76 278.19 104.76 278.74 104.76 279.94 104.78 283.01 104.79 284.87 104.79 285.59 104.79 285.8 104.81 286.67 104.8 287.75 104.79 289.41 104.8 290.27 104.79 290.58 104.79 290.77 104.8 292.86 104.82 293.22 104.83 293.28 104.81 293.31 105.05 293.43 105.82 293.46 105.95 293.6 106.39 293.65 106.55 293.87 107.87 294.17 109.09 294.26 109.49 294.31 109.75 294.36 109.98 294.75 112.07 294.85 112.48 294.93 112.75 294.95 112.81 294.99 113.15 295.08 113.47 295.08 113.52 295.32 114.68 295.4 114.99 295.54 115.6 295.61 115.96 295.76 116.65 295.83 116.97 295.9 117.26 296.05 117.95 296.1 118.21 296.21 118.75 296.32 119.29 296.62 120.61 297.13 122.91 297.51 124.57 297.59 124.8 299.41 133.01 299.89 135.13 300.27 136.86 300.46 137.85 300.79 139.23 300.46 139.29 286.85 140.8 286.29 140.86 285.3 140.98 285.1 141.02 280.69 141.52 277.7 141.81 274.77 142.09 272.21 142.3 272.2 142.29 272.09 142.2 271.97 142.11 271.87 142 271.78 141.92 271.69 141.77 271.59 141.56 271.52 141.42 271.4 141.19 271.33 141.09 271.23 141.02 271.13 140.95 271.02 140.86 270.81 140.73 270.6 140.6 270.44 140.5 270.28 140.41 270.11 140.34 269.95 140.27 269.79 140.18 269.6 140.08 269.42 139.99 269.24 139.92 269.01 139.82 268.69 139.68 268.52 139.58 268.29 139.44 268.11 139.32 268.04 139.26 267.95 139.21 267.88 139.15 267.78 139.06 267.61 138.89 267.5 138.81 267.32 138.65 267.16 138.5 267.11 138.46 267.05 138.42 266.98 138.36 266.86 138.24 266.77 138.16 266.72 138.14 266.62 138.12 266.54 138.11 266.47 138.11 266.34 138.11 266.22 138.12 266.13 138.12 265.99 138.12 265.82 138.09 265.69 138.1 265.53 138.1 265.3 138.1 265.01 138.08 264.89 138.05 264.77 138.03 264.65 138.02 264.5 138 264.34 137.97 264.15 137.92 264.08 137.9 264.01 137.87 263.97 137.84 263.88 137.78 263.82 137.73 263.79 137.7 263.75 137.65 263.72 137.58 263.69 137.51 263.66 137.44 263.65 137.35 263.65 137.25 263.64 137.15 263.62 137.1 263.59 137.06 263.53 137.02 263.43 136.99 263.36 136.95 263.28 136.9 263.16 136.83 263.09 136.8 263.04 136.73 263 136.69 262.88 136.58 262.78 136.45 262.73 136.37 262.69 136.32 262.64 136.27 262.57 136.26 262.45 136.22 262.38 136.18 262.32 136.12 262.27 136.05 262.22 136.01 262.18 135.94 262.13 135.87 262.07 135.79 262.03 135.69 261.99 135.59 261.96 135.43 261.97 135.36 261.98 135.26 262.01 135.19 262.01 135.11 261.99 135 261.86 134.9 261.67 134.79 261.6 134.77 261.53 134.75 261.5 134.73 261.47 134.7 261.33 134.48 261.15 134.24 260.97 134.02 260.85 133.89 260.74 133.79 260.69 133.73 260.63 133.69 260.56 133.57 260.5 133.44 260.45 133.29 260.43 133.25 260.39 133.18 260.36 133.14 260.31 133.08 260.09 132.91 259.99 132.85 259.91 132.8 259.84 132.74 259.77 132.67 259.63 132.59 259.5 132.56 259.35 132.55 259.12 132.52 258.74 132.5 258.57 132.5 258.47 132.47 258.37 132.42 258.29 132.38 258.23 132.31 258.12 132.14 258.07 132.06 257.98 131.94 257.82 131.75 257.8 131.69 257.74 131.68 257.67 131.68 257.64 131.66 257.61 131.64 257.56 131.59 257.51 131.52 257.44 131.4 257.42 131.32 257.38 131.28 257.35 131.24 257.29 131.18 257.23 131.14 257.18 131.08 257.14 131.04 257.1 131 257.09 130.94 257.08 130.88 257.09 130.79 257.11 130.61 257.11 130.56 257.1 130.52 257.07 130.47 257.04 130.42 257.01 130.37 256.96 130.33 256.83 130.22 256.78 130.17 256.73 130.13 256.68 130.09 256.51 130.02 256.29 129.92 256.22 129.89 256.17 129.85 256.07 129.76 255.98 129.7 255.92 129.64 255.86 129.59 255.78 129.52 255.65 129.43 255.41 129.29 255.33 129.25 255.26 129.23 255.18 129.21 255.03 129.2 254.91 129.19 254.77 129.16 254.54 129.12 254.45 129.11 254.35 129.09 254.25 129.07 254.08 128.98 253.91 128.87 253.66 128.72 253.6 128.69 253.53 128.66 253.44 128.63 253.37 128.59 253.31 128.53 253.28 128.46 253.21 128.38 253.08 128.25 252.98 128.16 252.92 128.11 252.81 128 252.77 127.9 252.75 127.81 252.72 127.76 252.72 127.71 252.71 127.65 252.72 127.61 252.74 127.5 252.78 127.34 252.81 127.24 252.83 127.12 252.87 126.94 252.87 126.89 252.86 126.82 252.86 126.67 252.85 126.61 252.89 126.55 252.94 126.48 253 126.39 253.02 126.3 253.07 126.21 253.1 126.18 253.17 126.13 253.22 126.09 253.28 126.03 253.31 125.98 253.35 125.93 253.37 125.86 253.39 125.81 253.39 125.74 253.36 125.68 253.34 125.59 253.36 125.57 253.37 125.55 253.4 125.53 253.42 125.52 253.45 125.5 253.51 125.47 253.78 125.35 254.01 125.23 254.17 125.17 254.34 125.11 254.48 125.07 254.56 125.04 254.61 125.01 254.64 124.98 254.65 124.94 254.65 124.91 254.65 124.86 254.64 124.82 254.63 124.79 254.61 124.73 254.58 124.71 254.54 124.67 254.5 124.62 254.46 124.57 254.43 124.54 254.28 124.33 254.17 124.22 254.05 124.13 254.02 124.05 253.91 123.84 253.84 123.75 253.71 123.52 253.55 123.31 253.39 123.14 252.92 122.71 252.73 122.57 252.5 122.39 252.28 122.24 252.11 122.03 252.04 121.91 252.04 121.83 252.11 121.52 252.12 121.21 252.19 121.01 252.25 120.93 252.41 120.88 252.57 120.88 252.71 120.86 252.77 120.85 252.83 120.8 252.88 120.72 252.92 120.59 252.91 120.46 252.85 120.35 252.64 120.11 252.56 120.01 252.28 119.73 252.23 119.64 252.11 119.41 252.09 119.32 252.1 119.19 252.16 119.07 252.23 118.97 252.32 118.82 252.38 118.65 252.42 118.56 252.47 118.23 252.57 117.84 252.53 117.67 252.47 117.5 252.3 117.08 252.29 116.97 252.36 116.83 252.48 116.57 252.49 116.5 252.46 116.42 252.11 116.07 251.82 115.73 251.54 115.32 251.45 115.23 251.33 115.13 251.1 114.97 250.95 114.89 250.8 114.79 250.73 114.69 250.7 114.52 250.75 114.4 250.86 114.25 251.04 114.05 251.07 114.01 251.66 113.37 251.76 113.22 251.82 113.01 251.81 112.59 251.84 112.42 251.94 111.92 252 111.82 252.06 111.76 252.17 111.7 252.29 111.66 252.56 111.61 252.72 111.55 252.88 111.5 253.28 111.43 253.42 111.42 253.81 111.37 253.98 111.37 254.05 111.38 254.11 111.4 254.17 111.48 254.23 111.54 254.29 111.59 254.39 111.64 254.48 111.65 254.55 111.62 254.62 111.54 254.7 111.42 254.78 111.14 254.82 110.91 254.79 110.79 254.74 110.71 254.64 110.55 254.49 110.41 254.37 110.34 254.25 110.2 254.18 110.16 254.11 110.1 254.45 109.7 255.68 108.3 256.5 107.37 257.65 106.08 257.51 104.66 257.52 104.65 258.53 104.66 262.13 104.69 264.5 104.7 266.3 104.7 266.75 104.71 267.07 104.71 267.2 104.71 268.36 104.72 268.52 104.73 268.83 104.71 Z"
348348
/>
349349
<path

0 commit comments

Comments
 (0)