diff --git a/.dockerignore b/.dockerignore index 66c77ccd0d..ece83a9dc8 100644 --- a/.dockerignore +++ b/.dockerignore @@ -8,8 +8,6 @@ deps erl_crash.dump build.sh deploy.sh -/priv/static/* -!/priv/static/icon-svg/ aws dotcom-build.zip bin diff --git a/.gitignore b/.gitignore index da3166460c..303d60774e 100644 --- a/.gitignore +++ b/.gitignore @@ -49,10 +49,9 @@ node_modules /**/react_renderer/dist # Since we are building assets from assets, -# we ignore priv/static. You may want to comment -# this depending on your deployment strategy. -/priv/static/* -!/priv/static/icon-svg/ +# we ignore certain directories in priv/static. +/priv/static/css +/priv/static/js # The config/prod.secret.exs file by default contains sensitive # data and you should not commit it into version control. diff --git a/assets/css/_form.scss b/assets/css/_form.scss index eb296ddaed..d2973cbe42 100644 --- a/assets/css/_form.scss +++ b/assets/css/_form.scss @@ -33,6 +33,7 @@ width: 100%; &:focus { + box-shadow: none; outline: 0; } } diff --git a/assets/css/_spacing.scss b/assets/css/_spacing.scss index bbaef0b2b3..f51449212e 100644 --- a/assets/css/_spacing.scss +++ b/assets/css/_spacing.scss @@ -1,104 +1,104 @@ -.w-100 { +.u-w-100 { width: 100%; } //// PADDING -.p-16 { +.u-p-16 { padding: 1rem; } // Top -.pt-2 { +.u-pt-2 { padding-top: .125rem; } -.pt-4 { +.u-pt-4 { padding-top: .25rem; } -.pt-8 { +.u-pt-8 { padding-top: .5rem; } -.pt-10 { +.u-pt-10 { padding-top: .625rem; } -.pt-14 { +.u-pt-14 { padding-top: .875rem; } -.pt-16 { +.u-pt-16 { padding-top: 1rem; } -.pt-18 { +.u-pt-18 { padding-top: 1.125rem; } -.pt-24 { +.u-pt-24 { padding-top: 1.5rem; } -.pt-40 { +.u-pt-40 { padding-top: 2.5rem; } // End Top // Bottom -.pb-8 { +.u-pb-8 { padding-bottom: .5rem; } -.pb-10 { +.u-pb-10 { padding-bottom: .625rem; } -.pb-14 { +.u-pb-14 { padding-bottom: .875rem; } -.pb-16 { +.u-pb-16 { padding-bottom: 1rem; } -.pb-18 { +.u-pb-18 { padding-bottom: 1.125rem; } -.pb-40 { +.u-pb-40 { padding-bottom: 2.5rem; } // End Bottom // Start -.ps-0 { +.u-ps-0 { padding-left: 0; } -.ps-5 { +.u-ps-5 { padding-left: .313rem; } -.ps-8 { +.u-ps-8 { padding-left: .5rem; } -.ps-16 { +.u-ps-16 { padding-left: 1rem; } // End Start // End -.pe-5 { +.u-pe-5 { padding-right: .313rem; } -.pe-8 { +.u-pe-8 { padding-right: .5rem; } -.pe-16 { +.u-pe-16 { padding-right: 1rem; } // End End @@ -106,96 +106,96 @@ //// MARGINS -.m-8 { +.u-m-8 { margin: .5rem; } -.m-16 { +.u-m-16 { margin: 1rem; } -.m-24 { +.u-m-24 { margin: 1.5rem; } // Negative margins need to be turned on in bootstrap 5 -.m-n24 { +.u-m-n24 { margin: -1.5rem; } // Top -.mt-n5 { +.u-mt-n5 { margin-top: -.313rem; } -.mt-6 { +.u-mt-6 { margin-top: .375rem; } -.mt-8 { +.u-mt-8 { margin-top: .5rem; } -.mt-10 { +.u-mt-10 { margin-top: .625rem; } -.mt-12 { +.u-mt-12 { margin-top: .75rem; } -.mt-16 { +.u-mt-16 { margin-top: 1rem; } -.mt-24 { +.u-mt-24 { margin-top: 1.5rem; } -.mt-n8 { +.u-mt-n8 { margin-top: -.5rem; } -.mt-n16 { +.u-mt-n16 { margin-top: -1rem; } -.mt-n20 { +.u-mt-n20 { margin-top: -1.25rem; } // End Top // Bottom -.mb-6 { +.u-mb-6 { margin-bottom: .375rem; } -.mb-8 { +.u-mb-8 { margin-bottom: .5rem; } // End -.me-4 { +.u-me-4 { margin-right: .25rem; } -.me-5 { +.u-me-5 { margin-right: .313rem; } -.me-8 { +.u-me-8 { margin-right: .5rem; } -.me-12 { +.u-me-12 { margin-right: .75rem; } -.me-14 { +.u-me-14 { margin-right: .875rem; } -.me-16 { +.u-me-16 { margin-right: 1rem; } // End End diff --git a/assets/css/_stop-card.scss b/assets/css/_stop-card.scss index 40af74b5a3..87fa57d376 100644 --- a/assets/css/_stop-card.scss +++ b/assets/css/_stop-card.scss @@ -439,8 +439,8 @@ $radius: 4px; @extend .c-alert-item--low; @extend .d-flex; @extend .justify-content-center; - @extend .m-8; - @extend .pb-40; - @extend .pt-40; + @extend .u-m-8; + @extend .u-pb-40; + @extend .u-pt-40; } } diff --git a/assets/css/_utilities.scss b/assets/css/_utilities.scss index 2356f49507..1a006c31a5 100644 --- a/assets/css/_utilities.scss +++ b/assets/css/_utilities.scss @@ -251,43 +251,43 @@ // quick margin utilities loosely based off Bootstrap v4 /* stylelint-disable declaration-no-important */ -.mb-0 { +.u-mb-0 { margin-bottom: 0 !important; } -.mb-05 { +.u-mb-05 { margin-bottom: calc(#{$base-spacing} / 2) !important; } -.mb-1 { +.u-mb-1 { margin-bottom: $base-spacing !important; } -.mb-2 { +.u-mb-2 { margin-bottom: $base-spacing * 2 !important; } -.mt-0 { +.u-mt-0 { margin-top: 0 !important; } -.mt-05 { +.u-mt-05 { margin-top: calc(#{$base-spacing} / 2) !important; } -.mt-1 { +.u-mt-1 { margin-top: $base-spacing !important; } -.mt-2 { +.u-mt-2 { margin-top: $base-spacing * 2 !important; } -.mt-3 { +.u-mt-3 { margin-top: $base-spacing * 3 !important; } -.mr-025 { +.u-mr-025 { margin-right: $base-spacing * .25 !important; } /* stylelint-enable declaration-no-important */ diff --git a/assets/css/app.scss b/assets/css/app.scss index 2c34ff1cd7..3e81b98493 100644 --- a/assets/css/app.scss +++ b/assets/css/app.scss @@ -1,6 +1,5 @@ -// TailwindCSS -@import 'tailwindcss/components'; -@import 'tailwindcss/utilities'; +// MBTA METRO +@import '../../deps/mbta_metro/priv/static/assets/default.css'; //////////////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////////////// diff --git a/assets/js/algolia-result.js b/assets/js/algolia-result.js index 65ad0f6d85..ff3970ebe3 100644 --- a/assets/js/algolia-result.js +++ b/assets/js/algolia-result.js @@ -449,11 +449,11 @@ function _sortFeatures(features) { function _getCommuterRailZone(hit) { if (hit.zone) { - return [`Zone ${hit.zone}`]; + return [`Zone ${hit.zone}`]; } if (hit.icon === "station") { // the north/south station popular result - return [`Zone 1A`]; + return [`Zone 1A`]; } return []; } @@ -482,7 +482,7 @@ function _stopIcons(hit, type) { .split(", ") .map( num => - `${num}` + `${num}` ) .join(""); }); diff --git a/assets/js/app.js b/assets/js/app.js index ef6e2658ad..33ad7c83ad 100644 --- a/assets/js/app.js +++ b/assets/js/app.js @@ -1,4 +1,5 @@ /* eslint-disable */ +import { Hooks } from "mbta_metro"; import "../vendor/fixedsticky"; import "../vendor/accessible-date-picker"; import "bootstrap/dist/js/umd/collapse"; @@ -43,7 +44,7 @@ import pslPageSetup from "./psl-page-setup.js"; import tabbedNav from "./tabbed-nav.js"; import { accordionInit } from "../ts/ui/accordion"; import initializeSentry from "../ts/sentry"; -import Hooks from "../ts/phoenix-hooks/index.ts"; +import DotcomHooks from "../ts/phoenix-hooks/index.ts"; import mobileAppBanner from "./mobile-app-banner.js"; @@ -57,7 +58,7 @@ let csrfToken = document let liveSocket = new LiveSocket("/live", Socket, { params: { _csrf_token: csrfToken }, - hooks: Hooks + hooks: { ...Hooks, ...DotcomHooks } }); // connect if there are any LiveViews on the page diff --git a/assets/package-lock.json b/assets/package-lock.json index aeb5e7b879..622d230747 100644 --- a/assets/package-lock.json +++ b/assets/package-lock.json @@ -35,6 +35,7 @@ "leaflet": "^1.4.0", "leaflet-rotatedmarker": "^0.2.0", "lodash": "^4.17.21", + "mbta_metro": "^0.0.18", "mobile-detect": "^1.4.5", "phoenix": "file:../deps/phoenix", "phoenix_html": "file:../deps/phoenix_html", @@ -163,7 +164,7 @@ "license": "MIT" }, "../deps/phoenix_html": { - "version": "3.3.3" + "version": "4.1.0" }, "node_modules/@adobe/css-tools": { "version": "4.3.3", @@ -360,7 +361,6 @@ "version": "5.2.0", "resolved": "https://registry.npmjs.org/@alloc/quick-lru/-/quick-lru-5.2.0.tgz", "integrity": "sha512-UrcABB+4bUrFABwbluTIBErXwvbsU/V7TZWfmbgJfbkwiBuziS9gxdODUyuiecfdGQ85jglMW6juS3+z5TsKLw==", - "dev": true, "license": "MIT", "engines": { "node": ">=10" @@ -2804,7 +2804,7 @@ }, "node_modules/@cspotcode/source-map-support": { "version": "0.8.1", - "dev": true, + "devOptional": true, "license": "MIT", "dependencies": { "@jridgewell/trace-mapping": "0.3.9" @@ -2815,7 +2815,7 @@ }, "node_modules/@cspotcode/source-map-support/node_modules/@jridgewell/trace-mapping": { "version": "0.3.9", - "dev": true, + "devOptional": true, "license": "MIT", "dependencies": { "@jridgewell/resolve-uri": "^3.0.3", @@ -4071,7 +4071,6 @@ "version": "8.0.2", "resolved": "https://registry.npmjs.org/@isaacs/cliui/-/cliui-8.0.2.tgz", "integrity": "sha512-O8jcjabXaleOG9DQ0+ARXWZBTfnP4WNAqzuiJK7ll44AmxGKv/J2M4TPjxjY3znBCfvBXFzucm1twdyFybFqEA==", - "dev": true, "dependencies": { "string-width": "^5.1.2", "string-width-cjs": "npm:string-width@^4.2.0", @@ -4088,7 +4087,6 @@ "version": "6.0.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-6.0.1.tgz", "integrity": "sha512-n5M855fKb2SsfMIiFFoVrABHJC8QtHwVx+mHWP3QcEqBHYienj5dHSgjbxtC0WEZXYt4wcD6zrQElDPhFuZgfA==", - "dev": true, "engines": { "node": ">=12" }, @@ -4100,7 +4098,6 @@ "version": "6.2.1", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-6.2.1.tgz", "integrity": "sha512-bN798gFfQX+viw3R7yrGWRqnrN2oRkEkUjjl4JNn4E8GxxbjtG3FbrEIIY3l8/hrwUwIeCZvi4QuOTP4MErVug==", - "dev": true, "engines": { "node": ">=12" }, @@ -4111,14 +4108,12 @@ "node_modules/@isaacs/cliui/node_modules/emoji-regex": { "version": "9.2.2", "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-9.2.2.tgz", - "integrity": "sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==", - "dev": true + "integrity": "sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==" }, "node_modules/@isaacs/cliui/node_modules/string-width": { "version": "5.1.2", "resolved": "https://registry.npmjs.org/string-width/-/string-width-5.1.2.tgz", "integrity": "sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==", - "dev": true, "dependencies": { "eastasianwidth": "^0.2.0", "emoji-regex": "^9.2.2", @@ -4135,7 +4130,6 @@ "version": "7.1.0", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-7.1.0.tgz", "integrity": "sha512-iq6eVVI64nQQTRYq2KtEg2d2uU7LElhTJwsH4YzIHZshxlgZms/wIc4VoDQTlG/IvVIrBKG06CrZnp0qv7hkcQ==", - "dev": true, "dependencies": { "ansi-regex": "^6.0.1" }, @@ -4150,7 +4144,6 @@ "version": "8.1.0", "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-8.1.0.tgz", "integrity": "sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ==", - "dev": true, "dependencies": { "ansi-styles": "^6.1.0", "string-width": "^5.0.1", @@ -4818,7 +4811,6 @@ }, "node_modules/@jridgewell/resolve-uri": { "version": "3.1.0", - "dev": true, "license": "MIT", "engines": { "node": ">=6.0.0" @@ -4828,7 +4820,6 @@ "version": "1.2.1", "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.2.1.tgz", "integrity": "sha512-R8gLRTZeyp03ymzP/6Lil/28tGeGEzhx1q2k703KGWRAI1VdvPIXdG70VJc2pAMw3NA6JKL5hhFu1sJX0Mnn/A==", - "dev": true, "engines": { "node": ">=6.0.0" } @@ -4859,14 +4850,12 @@ }, "node_modules/@jridgewell/sourcemap-codec": { "version": "1.4.14", - "dev": true, "license": "MIT" }, "node_modules/@jridgewell/trace-mapping": { "version": "0.3.25", "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.25.tgz", "integrity": "sha512-vNk6aEwybGtawWmy/PzwnGDOjCkLWSD2wqvjGGAgOAwCGWySYXfYoxt00IJkTF+8Lb57DwOb3Aa0o9CApepiYQ==", - "dev": true, "dependencies": { "@jridgewell/resolve-uri": "^3.1.0", "@jridgewell/sourcemap-codec": "^1.4.14" @@ -4878,9 +4867,95 @@ "integrity": "sha512-Vo+PSpZG2/fmgmiNzYK9qWRh8h/CHrwD0mo1h1DzL4yzHNSfWYujGTYsWGreD000gcgmZ7K4Ys6Tx9TxtsKdDw==", "dev": true }, + "node_modules/@mapbox/geojson-rewind": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/@mapbox/geojson-rewind/-/geojson-rewind-0.5.2.tgz", + "integrity": "sha512-tJaT+RbYGJYStt7wI3cq4Nl4SXxG8W7JDG5DMJu97V25RnbNg3QtQtf+KD+VLjNpWKYsRvXDNmNrBgEETr1ifA==", + "dependencies": { + "get-stream": "^6.0.1", + "minimist": "^1.2.6" + }, + "bin": { + "geojson-rewind": "geojson-rewind" + } + }, + "node_modules/@mapbox/geojson-rewind/node_modules/get-stream": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", + "integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==", + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@mapbox/jsonlint-lines-primitives": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/@mapbox/jsonlint-lines-primitives/-/jsonlint-lines-primitives-2.0.2.tgz", + "integrity": "sha512-rY0o9A5ECsTQRVhv7tL/OyDpGAoUB4tTvLiW1DSzQGq4bvTPhNw1VpSNjDJc5GFZ2XuyOtSWSVN05qOtcD71qQ==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/@mapbox/point-geometry": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/@mapbox/point-geometry/-/point-geometry-0.1.0.tgz", + "integrity": "sha512-6j56HdLTwWGO0fJPlrZtdU/B13q8Uwmo18Ck2GnGgN9PCFyKTZ3UbXeEdRFh18i9XQ92eH2VdtpJHpBD3aripQ==" + }, + "node_modules/@mapbox/tiny-sdf": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/@mapbox/tiny-sdf/-/tiny-sdf-2.0.6.tgz", + "integrity": "sha512-qMqa27TLw+ZQz5Jk+RcwZGH7BQf5G/TrutJhspsca/3SHwmgKQ1iq+d3Jxz5oysPVYTGP6aXxCo5Lk9Er6YBAA==" + }, + "node_modules/@mapbox/unitbezier": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/@mapbox/unitbezier/-/unitbezier-0.0.1.tgz", + "integrity": "sha512-nMkuDXFv60aBr9soUG5q+GvZYL+2KZHVvsqFCzqnkGEf46U2fvmytHaEVc1/YZbiLn8X+eR3QzX1+dwDO1lxlw==" + }, + "node_modules/@mapbox/vector-tile": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@mapbox/vector-tile/-/vector-tile-1.3.1.tgz", + "integrity": "sha512-MCEddb8u44/xfQ3oD+Srl/tNcQoqTw3goGk2oLsrFxOTc3dUp+kAnby3PvAeeBYSMSjSPD1nd1AJA6W49WnoUw==", + "dependencies": { + "@mapbox/point-geometry": "~0.1.0" + } + }, + "node_modules/@mapbox/whoots-js": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@mapbox/whoots-js/-/whoots-js-3.1.0.tgz", + "integrity": "sha512-Es6WcD0nO5l+2BOQS4uLfNPYQaNDfbot3X1XUoloz+x0mPDS3eeORZJl06HXjwBG1fOGwCRnzK88LMdxKRrd6Q==", + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@maplibre/maplibre-gl-style-spec": { + "version": "20.3.1", + "resolved": "https://registry.npmjs.org/@maplibre/maplibre-gl-style-spec/-/maplibre-gl-style-spec-20.3.1.tgz", + "integrity": "sha512-5ueL4UDitzVtceQ8J4kY+Px3WK+eZTsmGwha3MBKHKqiHvKrjWWwBCIl1K8BuJSc5OFh83uI8IFNoFvQxX2uUw==", + "dependencies": { + "@mapbox/jsonlint-lines-primitives": "~2.0.2", + "@mapbox/unitbezier": "^0.0.1", + "json-stringify-pretty-compact": "^4.0.0", + "minimist": "^1.2.8", + "quickselect": "^2.0.0", + "rw": "^1.3.3", + "sort-object": "^3.0.3", + "tinyqueue": "^3.0.0" + }, + "bin": { + "gl-style-format": "dist/gl-style-format.mjs", + "gl-style-migrate": "dist/gl-style-migrate.mjs", + "gl-style-validate": "dist/gl-style-validate.mjs" + } + }, + "node_modules/@maplibre/maplibre-gl-style-spec/node_modules/quickselect": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/quickselect/-/quickselect-2.0.0.tgz", + "integrity": "sha512-RKJ22hX8mHe3Y6wH/N3wCM6BWtjaxIyyUIkpHOvfFnxdI4yD4tBXEBKSbriGujF6jnSVkJrffuo6vxACiSSxIw==" + }, "node_modules/@nodelib/fs.scandir": { "version": "2.1.5", - "dev": true, "license": "MIT", "dependencies": { "@nodelib/fs.stat": "2.0.5", @@ -4892,7 +4967,6 @@ }, "node_modules/@nodelib/fs.stat": { "version": "2.0.5", - "dev": true, "license": "MIT", "engines": { "node": ">= 8" @@ -4900,7 +4974,6 @@ }, "node_modules/@nodelib/fs.walk": { "version": "1.2.8", - "dev": true, "license": "MIT", "dependencies": { "@nodelib/fs.scandir": "2.1.5", @@ -4914,7 +4987,6 @@ "version": "0.11.0", "resolved": "https://registry.npmjs.org/@pkgjs/parseargs/-/parseargs-0.11.0.tgz", "integrity": "sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==", - "dev": true, "optional": true, "engines": { "node": ">=14" @@ -4926,6 +4998,15 @@ "integrity": "sha512-j7P6Rgr3mmtdkeDGTe0E/aYyWEWVtc5yFXtHCRHs28/jptDEWfaVOc5T7cblqy1XKPPfCxJc/8DwQ5YgLOZOVQ==", "dev": true }, + "node_modules/@popperjs/core": { + "version": "2.11.8", + "resolved": "https://registry.npmjs.org/@popperjs/core/-/core-2.11.8.tgz", + "integrity": "sha512-P1st0aksCrn9sGZhp8GMYwBnQsbvAWsZAX44oXNNvLHGqAOcoVxmjZiohstwQ7SqKnbR47akdNi+uleWD8+g6A==", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/popperjs" + } + }, "node_modules/@remix-run/router": { "version": "1.9.0", "resolved": "https://registry.npmjs.org/@remix-run/router/-/router-1.9.0.tgz", @@ -5165,16 +5246,14 @@ } }, "node_modules/@tailwindcss/forms": { - "version": "0.5.7", - "resolved": "https://registry.npmjs.org/@tailwindcss/forms/-/forms-0.5.7.tgz", - "integrity": "sha512-QE7X69iQI+ZXwldE+rzasvbJiyV/ju1FGHH0Qn2W3FKbuYtqp8LKcy6iSw79fVUT5/Vvf+0XgLCeYVG+UV6hOw==", - "dev": true, - "license": "MIT", + "version": "0.5.9", + "resolved": "https://registry.npmjs.org/@tailwindcss/forms/-/forms-0.5.9.tgz", + "integrity": "sha512-tM4XVr2+UVTxXJzey9Twx48c1gcxFStqn1pQz0tRsX8o3DvxhN5oY5pvyAbUx7VTaZxpej4Zzvc6h+1RJBzpIg==", "dependencies": { "mini-svg-data-uri": "^1.2.3" }, "peerDependencies": { - "tailwindcss": ">=3.0.0 || >= 3.0.0-alpha.1" + "tailwindcss": ">=3.0.0 || >= 3.0.0-alpha.1 || >= 4.0.0-alpha.20" } }, "node_modules/@testing-library/dom": { @@ -5417,22 +5496,22 @@ }, "node_modules/@tsconfig/node10": { "version": "1.0.9", - "dev": true, + "devOptional": true, "license": "MIT" }, "node_modules/@tsconfig/node12": { "version": "1.0.11", - "dev": true, + "devOptional": true, "license": "MIT" }, "node_modules/@tsconfig/node14": { "version": "1.0.3", - "dev": true, + "devOptional": true, "license": "MIT" }, "node_modules/@tsconfig/node16": { "version": "1.0.3", - "dev": true, + "devOptional": true, "license": "MIT" }, "node_modules/@types/aria-query": { @@ -5623,9 +5702,17 @@ } }, "node_modules/@types/geojson": { - "version": "7946.0.10", - "dev": true, - "license": "MIT" + "version": "7946.0.14", + "resolved": "https://registry.npmjs.org/@types/geojson/-/geojson-7946.0.14.tgz", + "integrity": "sha512-WCfD5Ht3ZesJUsONdhvm84dmzWOiOzOAqOncN0++w0lBw1o8OuDNJF2McvvCef/yBqb/HYRahp1BYtODFQ8bRg==" + }, + "node_modules/@types/geojson-vt": { + "version": "3.2.5", + "resolved": "https://registry.npmjs.org/@types/geojson-vt/-/geojson-vt-3.2.5.tgz", + "integrity": "sha512-qDO7wqtprzlpe8FfQ//ClPV9xiuoh2nkIgiouIptON9w5jvD/fA4szvP9GBlDVdJ5dldAl0kX/sy3URbWwLx0g==", + "dependencies": { + "@types/geojson": "*" + } }, "node_modules/@types/googlemaps": { "version": "3.43.3", @@ -5715,6 +5802,21 @@ "dev": true, "license": "MIT" }, + "node_modules/@types/mapbox__point-geometry": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/@types/mapbox__point-geometry/-/mapbox__point-geometry-0.1.4.tgz", + "integrity": "sha512-mUWlSxAmYLfwnRBmgYV86tgYmMIICX4kza8YnE/eIlywGe2XoOxlpVnXWwir92xRLjwyarqwpu2EJKD2pk0IUA==" + }, + "node_modules/@types/mapbox__vector-tile": { + "version": "1.3.4", + "resolved": "https://registry.npmjs.org/@types/mapbox__vector-tile/-/mapbox__vector-tile-1.3.4.tgz", + "integrity": "sha512-bpd8dRn9pr6xKvuEBQup8pwQfD4VUyqO/2deGjfpe6AwC8YRlyEipvefyRJUSiCJTZuCb8Pl1ciVV5ekqJ96Bg==", + "dependencies": { + "@types/geojson": "*", + "@types/mapbox__point-geometry": "*", + "@types/pbf": "*" + } + }, "node_modules/@types/mdast": { "version": "3.0.12", "dev": true, @@ -5735,7 +5837,7 @@ }, "node_modules/@types/node": { "version": "18.11.9", - "dev": true, + "devOptional": true, "license": "MIT" }, "node_modules/@types/node-forge": { @@ -5757,6 +5859,11 @@ "dev": true, "license": "MIT" }, + "node_modules/@types/pbf": { + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/@types/pbf/-/pbf-3.0.5.tgz", + "integrity": "sha512-j3pOPiEcWZ34R6a6mN07mUkM4o4Lwf6hPNt8eilOeZhTFbxFXmKhvXl9Y28jotFPaI1bpPDJsbCprUoNke6OrA==" + }, "node_modules/@types/phoenix": { "version": "1.5.4", "dev": true, @@ -5909,6 +6016,14 @@ "dev": true, "license": "MIT" }, + "node_modules/@types/supercluster": { + "version": "7.1.3", + "resolved": "https://registry.npmjs.org/@types/supercluster/-/supercluster-7.1.3.tgz", + "integrity": "sha512-Z0pOY34GDFl3Q6hUFYf3HkTwKEE02e7QgtJppBt+beEAxnyOpJua+voGFvxINBHa06GwLFFym7gRPY2SiKIfIA==", + "dependencies": { + "@types/geojson": "*" + } + }, "node_modules/@types/testing-library__jest-dom": { "version": "5.14.5", "dev": true, @@ -6487,7 +6602,7 @@ }, "node_modules/acorn": { "version": "8.10.0", - "dev": true, + "devOptional": true, "license": "MIT", "bin": { "acorn": "bin/acorn" @@ -6732,7 +6847,6 @@ }, "node_modules/ansi-regex": { "version": "5.0.1", - "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -6753,12 +6867,10 @@ "version": "1.3.0", "resolved": "https://registry.npmjs.org/any-promise/-/any-promise-1.3.0.tgz", "integrity": "sha512-7UvmKalWRt1wgjL1RrGxoSJW/0QZFIegpeGvZG9kjp8vrRu55XTHbwnqq2GpXm9uLbcuhxm3IqX9OB4MZR1b2A==", - "dev": true, "license": "MIT" }, "node_modules/anymatch": { "version": "3.1.2", - "dev": true, "license": "ISC", "dependencies": { "normalize-path": "^3.0.0", @@ -6789,7 +6901,7 @@ }, "node_modules/arg": { "version": "4.1.3", - "dev": true, + "devOptional": true, "license": "MIT" }, "node_modules/argparse": { @@ -6808,6 +6920,14 @@ "deep-equal": "^2.0.5" } }, + "node_modules/arr-union": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/arr-union/-/arr-union-3.1.0.tgz", + "integrity": "sha512-sKpyeERZ02v1FeCZT8lrfJq5u6goHCtpTAzPwJYe7c8SPFOboNjNg1vz2L4VTn9T4PQxEx13TbXLmYUcS6Ug7Q==", + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/array-equal": { "version": "1.0.0", "dev": true, @@ -6942,6 +7062,14 @@ "node": "*" } }, + "node_modules/assign-symbols": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/assign-symbols/-/assign-symbols-1.0.0.tgz", + "integrity": "sha512-Q+JC7Whu8HhmTdBph/Tq59IoRtoy6KAm5zzPv00WdujX82lbAL8K7WVjne7vdCsAmbF4AYaDOPyO3k0kl8qIrw==", + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/ast-types-flow": { "version": "0.0.7", "dev": true, @@ -7464,7 +7592,6 @@ }, "node_modules/balanced-match": { "version": "1.0.2", - "dev": true, "license": "MIT" }, "node_modules/base64-js": { @@ -7509,7 +7636,6 @@ }, "node_modules/binary-extensions": { "version": "2.2.0", - "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -7610,7 +7736,6 @@ }, "node_modules/braces": { "version": "3.0.2", - "dev": true, "license": "MIT", "dependencies": { "fill-range": "^7.0.1" @@ -7748,6 +7873,23 @@ "node": ">= 0.8" } }, + "node_modules/bytewise": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/bytewise/-/bytewise-1.1.0.tgz", + "integrity": "sha512-rHuuseJ9iQ0na6UDhnrRVDh8YnWVlU6xM3VH6q/+yHDeUH2zIhUzP+2/h3LIrhLDBtTqzWpE3p3tP/boefskKQ==", + "dependencies": { + "bytewise-core": "^1.2.2", + "typewise": "^1.0.3" + } + }, + "node_modules/bytewise-core": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/bytewise-core/-/bytewise-core-1.2.3.tgz", + "integrity": "sha512-nZD//kc78OOxeYtRlVk8/zXqTB4gf/nlguL1ggWA8FuchMyOxcyHR4QPQZMUmA7czC+YnaBrPUCubqAWe50DaA==", + "dependencies": { + "typewise-core": "^1.2" + } + }, "node_modules/cachedir": { "version": "2.3.0", "dev": true, @@ -7788,7 +7930,6 @@ "version": "2.0.1", "resolved": "https://registry.npmjs.org/camelcase-css/-/camelcase-css-2.0.1.tgz", "integrity": "sha512-QOSvevhslijgYwRx6Rv7zKdMF8lbRmx+uQGx2+vDc+KI/eBnsy9kit5aj23AgGu3pa4t9AgwbnXWqS+iOY+2aA==", - "dev": true, "license": "MIT", "engines": { "node": ">= 6" @@ -7955,7 +8096,6 @@ }, "node_modules/chokidar": { "version": "3.5.3", - "dev": true, "funding": [ { "type": "individual", @@ -8372,12 +8512,11 @@ }, "node_modules/create-require": { "version": "1.1.1", - "dev": true, + "devOptional": true, "license": "MIT" }, "node_modules/cross-spawn": { "version": "7.0.3", - "dev": true, "license": "MIT", "dependencies": { "path-key": "^3.1.0", @@ -8783,7 +8922,6 @@ }, "node_modules/cssesc": { "version": "3.0.0", - "dev": true, "license": "MIT", "bin": { "cssesc": "bin/cssesc" @@ -9129,14 +9267,6 @@ "node": ">=8" } }, - "node_modules/cypress/node_modules/minimist": { - "version": "1.2.8", - "dev": true, - "license": "MIT", - "funding": { - "url": "https://github.com/sponsors/ljharb" - } - }, "node_modules/cypress/node_modules/ms": { "version": "2.1.2", "dev": true, @@ -9500,7 +9630,6 @@ "version": "1.2.2", "resolved": "https://registry.npmjs.org/didyoumean/-/didyoumean-1.2.2.tgz", "integrity": "sha512-gxtyfqMg7GKyhQmb056K7M3xszy/myH8w+B4RT+QXBQsvAOdc3XymqDDPHx1BgPgsdAA5SIifona89YtRATDzw==", - "dev": true, "license": "Apache-2.0" }, "node_modules/diff": { @@ -9539,7 +9668,6 @@ "version": "1.1.3", "resolved": "https://registry.npmjs.org/dlv/-/dlv-1.1.3.tgz", "integrity": "sha512-+HlytyjlPKnIG8XuRG8WvmBP8xs8P71y+SKKS6ZXWoEgLuePxtDoUEiH7WkdePWrQ5JBpE6aoVqfZfJUQkjXwA==", - "dev": true, "license": "MIT" }, "node_modules/dns-packet": { @@ -9657,11 +9785,15 @@ "dev": true, "license": "MIT" }, + "node_modules/earcut": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/earcut/-/earcut-3.0.0.tgz", + "integrity": "sha512-41Fs7Q/PLq1SDbqjsgcY7GA42T0jvaCNGXgGtsNdvg+Yv8eIu06bxv4/PoREkZ9nMDNwnUSG9OFB9+yv8eKhDg==" + }, "node_modules/eastasianwidth": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/eastasianwidth/-/eastasianwidth-0.2.0.tgz", - "integrity": "sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==", - "dev": true + "integrity": "sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==" }, "node_modules/ecc-jsbn": { "version": "0.1.2", @@ -9697,7 +9829,6 @@ }, "node_modules/emoji-regex": { "version": "8.0.0", - "dev": true, "license": "MIT" }, "node_modules/emojis-list": { @@ -10973,6 +11104,17 @@ "dev": true, "license": "MIT" }, + "node_modules/extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha512-zCnTtlxNoAiDc3gqY2aYAWFx7XWWiasuF2K8Me5WbN8otHKTUKBwjPtNpRs/rbUZm7KxWAaNj7P1a/p52GbVug==", + "dependencies": { + "is-extendable": "^0.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/extract-zip": { "version": "2.0.1", "dev": true, @@ -11035,7 +11177,6 @@ "version": "3.3.2", "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.2.tgz", "integrity": "sha512-oX2ruAFQwf/Orj8m737Y5adxDQO0LAB7/S5MnxCdTNDd4p6BsyIVsv9JQsATbTSq8KHRpLwIHbVlUNatxd+1Ow==", - "dev": true, "dependencies": { "@nodelib/fs.stat": "^2.0.2", "@nodelib/fs.walk": "^1.2.3", @@ -11067,7 +11208,6 @@ }, "node_modules/fastq": { "version": "1.13.0", - "dev": true, "license": "ISC", "dependencies": { "reusify": "^1.0.4" @@ -11167,7 +11307,6 @@ }, "node_modules/fill-range": { "version": "7.0.1", - "dev": true, "license": "MIT", "dependencies": { "to-regex-range": "^5.0.1" @@ -11306,7 +11445,6 @@ "version": "3.1.1", "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.1.1.tgz", "integrity": "sha512-TMKDUnIte6bfb5nWv7V/caI169OHgvwjb7V4WkeUvbQQdjr5rWKqHFiKWb/fcOwB+CzBT+qbWjvj+DVwRskpIg==", - "dev": true, "dependencies": { "cross-spawn": "^7.0.0", "signal-exit": "^4.0.1" @@ -11322,7 +11460,6 @@ "version": "4.1.0", "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", - "dev": true, "engines": { "node": ">=14" }, @@ -11430,7 +11567,6 @@ "version": "2.3.3", "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", - "dev": true, "hasInstallScript": true, "optional": true, "os": [ @@ -11444,7 +11580,6 @@ "version": "1.1.2", "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", - "dev": true, "license": "MIT", "funding": { "url": "https://github.com/sponsors/ljharb" @@ -11488,6 +11623,11 @@ "node": ">=6.9.0" } }, + "node_modules/geojson-vt": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/geojson-vt/-/geojson-vt-4.0.2.tgz", + "integrity": "sha512-AV9ROqlNqoZEIJGfm1ncNjEXfkz2hdFlZf0qkVfmkwdKa8vj7H16YUOT81rJw1rdFhyEDlN2Tds91p/glzbl5A==" + }, "node_modules/get-caller-file": { "version": "2.0.5", "dev": true, @@ -11557,6 +11697,14 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/get-value": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/get-value/-/get-value-2.0.6.tgz", + "integrity": "sha512-Ln0UQDlxH1BapMu3GPtf7CuYNwRZf2gwCuPqbyG6pB8WfmFpzqcy4xtAaAMUhnNqjMKTiCPZG2oMT3YSx8U2NA==", + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/getos": { "version": "3.2.1", "dev": true, @@ -11578,6 +11726,11 @@ "assert-plus": "^1.0.0" } }, + "node_modules/gl-matrix": { + "version": "3.4.3", + "resolved": "https://registry.npmjs.org/gl-matrix/-/gl-matrix-3.4.3.tgz", + "integrity": "sha512-wcCp8vu8FT22BnvKVPjXa/ICBWRq/zjFfdofZy1WSpQZpphblv12/bOQLBC1rMM7SGOFS9ltVmKOHil5+Ml7gA==" + }, "node_modules/glob": { "version": "7.2.3", "dev": true, @@ -11599,7 +11752,6 @@ }, "node_modules/glob-parent": { "version": "5.1.2", - "dev": true, "license": "ISC", "dependencies": { "is-glob": "^4.0.1" @@ -11862,7 +12014,6 @@ "version": "2.0.2", "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", "integrity": "sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==", - "dev": true, "license": "MIT", "dependencies": { "function-bind": "^1.1.2" @@ -12227,7 +12378,6 @@ }, "node_modules/ieee754": { "version": "1.2.1", - "dev": true, "funding": [ { "type": "github", @@ -12491,7 +12641,6 @@ }, "node_modules/is-binary-path": { "version": "2.1.0", - "dev": true, "license": "MIT", "dependencies": { "binary-extensions": "^2.0.0" @@ -12563,7 +12712,6 @@ "version": "2.15.1", "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.15.1.tgz", "integrity": "sha512-z0vtXSwucUJtANQWldhbtbt7BnL0vxiFjIdDLAatwhDYty2bad6s+rijD6Ri4YuYJubLzIJLUidCh09e1djEVQ==", - "dev": true, "license": "MIT", "dependencies": { "hasown": "^2.0.2" @@ -12613,9 +12761,16 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/is-extendable": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-0.1.1.tgz", + "integrity": "sha512-5BMULNob1vgFX6EjQw5izWDxrecWK9AM72rugNr0TFldMOi0fj6Jk+zeKIt0xGj4cEfQIJth4w3OKWOJ4f+AFw==", + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/is-extglob": { "version": "2.1.1", - "dev": true, "license": "MIT", "engines": { "node": ">=0.10.0" @@ -12623,7 +12778,6 @@ }, "node_modules/is-fullwidth-code-point": { "version": "3.0.0", - "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -12639,7 +12793,6 @@ }, "node_modules/is-glob": { "version": "4.0.3", - "dev": true, "license": "MIT", "dependencies": { "is-extglob": "^2.1.1" @@ -12723,7 +12876,6 @@ }, "node_modules/is-number": { "version": "7.0.0", - "dev": true, "license": "MIT", "engines": { "node": ">=0.12.0" @@ -12761,7 +12913,6 @@ }, "node_modules/is-plain-object": { "version": "2.0.4", - "dev": true, "license": "MIT", "dependencies": { "isobject": "^3.0.1" @@ -12947,12 +13098,10 @@ }, "node_modules/isexe": { "version": "2.0.0", - "dev": true, "license": "ISC" }, "node_modules/isobject": { "version": "3.0.1", - "dev": true, "license": "MIT", "engines": { "node": ">=0.10.0" @@ -14924,7 +15073,6 @@ "version": "1.21.0", "resolved": "https://registry.npmjs.org/jiti/-/jiti-1.21.0.tgz", "integrity": "sha512-gFqAIbuKyyso/3G2qhiO2OM6shY6EPP/R0+mkDbyspxKazh8BXDC5FiFsUjlczgdNz/vfra0da2y+aHrusLG/Q==", - "dev": true, "bin": { "jiti": "bin/jiti.js" } @@ -15083,6 +15231,11 @@ "dev": true, "license": "MIT" }, + "node_modules/json-stringify-pretty-compact": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/json-stringify-pretty-compact/-/json-stringify-pretty-compact-4.0.0.tgz", + "integrity": "sha512-3CNZ2DnrpByG9Nqj6Xo8vqbjT4F6N+tb4Gb28ESAZjYZ5yqvmc56J+/kuIwkaAMOyblTQhUW7PxMkUb8Q36N3Q==" + }, "node_modules/json-stringify-safe": { "version": "5.0.1", "dev": true, @@ -15142,9 +15295,13 @@ "dev": true, "license": "MIT" }, + "node_modules/kdbush": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/kdbush/-/kdbush-4.0.2.tgz", + "integrity": "sha512-WbCVYJ27Sz8zi9Q7Q0xHC+05iwkm3Znipc2XTlrnJbsHMYktW4hPhXUE8Ys1engBrvffoSCqbil1JQAa7clRpA==" + }, "node_modules/kind-of": { "version": "6.0.3", - "dev": true, "license": "MIT", "engines": { "node": ">=0.10.0" @@ -15231,14 +15388,12 @@ "version": "2.1.0", "resolved": "https://registry.npmjs.org/lilconfig/-/lilconfig-2.1.0.tgz", "integrity": "sha512-utWOt/GHzuUxnLKxB6dk81RoOeoNeHgbrXiuGk4yyF5qlRz+iIVWu56E2fqGHFrXz0QNUhLB/8nKqvRH66JKGQ==", - "dev": true, "engines": { "node": ">=10" } }, "node_modules/lines-and-columns": { "version": "1.2.4", - "dev": true, "license": "MIT" }, "node_modules/lint-staged": { @@ -16044,7 +16199,7 @@ }, "node_modules/make-error": { "version": "1.3.6", - "dev": true, + "devOptional": true, "license": "ISC" }, "node_modules/makeerror": { @@ -16070,6 +16225,89 @@ "version": "0.1.0", "dev": true }, + "node_modules/maplibre-gl": { + "version": "4.7.1", + "resolved": "https://registry.npmjs.org/maplibre-gl/-/maplibre-gl-4.7.1.tgz", + "integrity": "sha512-lgL7XpIwsgICiL82ITplfS7IGwrB1OJIw/pCvprDp2dhmSSEBgmPzYRvwYYYvJGJD7fxUv1Tvpih4nZ6VrLuaA==", + "dependencies": { + "@mapbox/geojson-rewind": "^0.5.2", + "@mapbox/jsonlint-lines-primitives": "^2.0.2", + "@mapbox/point-geometry": "^0.1.0", + "@mapbox/tiny-sdf": "^2.0.6", + "@mapbox/unitbezier": "^0.0.1", + "@mapbox/vector-tile": "^1.3.1", + "@mapbox/whoots-js": "^3.1.0", + "@maplibre/maplibre-gl-style-spec": "^20.3.1", + "@types/geojson": "^7946.0.14", + "@types/geojson-vt": "3.2.5", + "@types/mapbox__point-geometry": "^0.1.4", + "@types/mapbox__vector-tile": "^1.3.4", + "@types/pbf": "^3.0.5", + "@types/supercluster": "^7.1.3", + "earcut": "^3.0.0", + "geojson-vt": "^4.0.2", + "gl-matrix": "^3.4.3", + "global-prefix": "^4.0.0", + "kdbush": "^4.0.2", + "murmurhash-js": "^1.0.0", + "pbf": "^3.3.0", + "potpack": "^2.0.0", + "quickselect": "^3.0.0", + "supercluster": "^8.0.1", + "tinyqueue": "^3.0.0", + "vt-pbf": "^3.1.3" + }, + "engines": { + "node": ">=16.14.0", + "npm": ">=8.1.0" + }, + "funding": { + "url": "https://github.com/maplibre/maplibre-gl-js?sponsor=1" + } + }, + "node_modules/maplibre-gl/node_modules/global-prefix": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/global-prefix/-/global-prefix-4.0.0.tgz", + "integrity": "sha512-w0Uf9Y9/nyHinEk5vMJKRie+wa4kR5hmDbEhGGds/kG1PwGLLHKRoNMeJOyCQjjBkANlnScqgzcFwGHgmgLkVA==", + "dependencies": { + "ini": "^4.1.3", + "kind-of": "^6.0.3", + "which": "^4.0.0" + }, + "engines": { + "node": ">=16" + } + }, + "node_modules/maplibre-gl/node_modules/ini": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/ini/-/ini-4.1.3.tgz", + "integrity": "sha512-X7rqawQBvfdjS10YU1y1YVreA3SsLrW9dX2CewP2EbBJM4ypVNLDkO5y04gejPwKIY9lR+7r9gn3rFPt/kmWFg==", + "engines": { + "node": "^14.17.0 || ^16.13.0 || >=18.0.0" + } + }, + "node_modules/maplibre-gl/node_modules/isexe": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-3.1.1.tgz", + "integrity": "sha512-LpB/54B+/2J5hqQ7imZHfdU31OlgQqx7ZicVlkm9kzg9/w8GKLEcFfJl/t7DCEDueOyBAD6zCCwTO6Fzs0NoEQ==", + "engines": { + "node": ">=16" + } + }, + "node_modules/maplibre-gl/node_modules/which": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/which/-/which-4.0.0.tgz", + "integrity": "sha512-GlaYyEb07DPxYCKhKzplCWBJtvxZcZMrL+4UkrTSJHHPyZU4mYYTv3qaOe77H7EODLSSopAUFAc6W8U4yqvscg==", + "dependencies": { + "isexe": "^3.1.1" + }, + "bin": { + "node-which": "bin/which.js" + }, + "engines": { + "node": "^16.13.0 || >=18.0.0" + } + }, "node_modules/mathml-tag-names": { "version": "2.1.3", "dev": true, @@ -16079,6 +16317,27 @@ "url": "https://github.com/sponsors/wooorm" } }, + "node_modules/mbta_metro": { + "version": "0.0.18", + "resolved": "https://registry.npmjs.org/mbta_metro/-/mbta_metro-0.0.18.tgz", + "integrity": "sha512-1+54QwZHmTEbf5RRNHQnC4ss0U78gQqsjo73or6abO6VTPOcxPcwtNHr4eBy6enCXQigTZgkNKxjJ+kr/6dJIA==", + "dependencies": { + "@tailwindcss/forms": "^0.5.9", + "date-fns": "^4.1.0", + "flatpickr": "^4.6.13", + "maplibre-gl": "^4.7.0", + "preline": "^2.4.1" + } + }, + "node_modules/mbta_metro/node_modules/date-fns": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-4.1.0.tgz", + "integrity": "sha512-Ukq0owbQXxa/U3EGtsdVBkR1w7KOQ5gIBqdH2hkvknzZPYvBxb/aa6E8L7tmjFtkwZBu3UXBbjIgPo/Ez4xaNg==", + "funding": { + "type": "github", + "url": "https://github.com/sponsors/kossnocorp" + } + }, "node_modules/mdast-util-from-markdown": { "version": "0.8.5", "dev": true, @@ -16214,7 +16473,6 @@ }, "node_modules/merge2": { "version": "1.4.1", - "dev": true, "license": "MIT", "engines": { "node": ">= 8" @@ -16270,7 +16528,6 @@ }, "node_modules/micromatch": { "version": "4.0.5", - "dev": true, "license": "MIT", "dependencies": { "braces": "^3.0.2", @@ -16356,7 +16613,6 @@ "version": "1.4.4", "resolved": "https://registry.npmjs.org/mini-svg-data-uri/-/mini-svg-data-uri-1.4.4.tgz", "integrity": "sha512-r9deDe9p5FJUPZAk3A59wGH7Ii9YrjjWw0jmw/liSbHl2CHiyXj6FcDXDu2K3TjVAXqiJdaw3xxwlZZr9E6nHg==", - "dev": true, "license": "MIT", "bin": { "mini-svg-data-uri": "cli.js" @@ -16379,9 +16635,9 @@ } }, "node_modules/minimist": { - "version": "1.2.7", - "dev": true, - "license": "MIT", + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", "funding": { "url": "https://github.com/sponsors/ljharb" } @@ -16411,7 +16667,6 @@ "version": "7.1.2", "resolved": "https://registry.npmjs.org/minipass/-/minipass-7.1.2.tgz", "integrity": "sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw==", - "dev": true, "license": "ISC", "engines": { "node": ">=16 || 14 >=14.17" @@ -16948,11 +17203,15 @@ "multicast-dns": "cli.js" } }, + "node_modules/murmurhash-js": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/murmurhash-js/-/murmurhash-js-1.0.0.tgz", + "integrity": "sha512-TvmkNhkv8yct0SVBSy+o8wYzXjE4Zz3PCesbfs8HiCXXdcTuocApFv11UWlNFWKYsP2okqrhb7JNlSm9InBhIw==" + }, "node_modules/mz": { "version": "2.7.0", "resolved": "https://registry.npmjs.org/mz/-/mz-2.7.0.tgz", "integrity": "sha512-z81GNO7nnYMEhrGh9LeymoE4+Yr0Wn5McHIZMK5cfQCl+NDX08sCZgUc9/6MHni9IWuFLm1Z3HTCXu2z9fN62Q==", - "dev": true, "license": "MIT", "dependencies": { "any-promise": "^1.0.0", @@ -16964,7 +17223,6 @@ "version": "3.3.7", "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.7.tgz", "integrity": "sha512-eSRppjcPIatRIMC1U6UngP8XFcz8MQWGQdt1MTBQ7NaAmvXDfvNxbvWV3x2y6CdEUciCSsDHDQZbhYaB8QEo2g==", - "dev": true, "funding": [ { "type": "github", @@ -17117,7 +17375,6 @@ }, "node_modules/normalize-path": { "version": "3.0.0", - "dev": true, "license": "MIT", "engines": { "node": ">=0.10.0" @@ -17187,7 +17444,6 @@ "version": "3.0.0", "resolved": "https://registry.npmjs.org/object-hash/-/object-hash-3.0.0.tgz", "integrity": "sha512-RSn9F68PjH9HqtltsSnqYC1XXoWe9Bju5+213R98cNGttag9q9yAOTzdbsqvIa7aNm5WffBZFpWYr2aWrklWAw==", - "dev": true, "license": "MIT", "engines": { "node": ">= 6" @@ -17458,7 +17714,6 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/package-json-from-dist/-/package-json-from-dist-1.0.0.tgz", "integrity": "sha512-dATvCeZN/8wQsGywez1mzHtTlP22H8OEfPrVMLNr4/eGa+ijtLn/6M5f0dY8UKNrC2O9UCU6SSoG3qRKnt7STw==", - "dev": true, "license": "BlueOak-1.0.0" }, "node_modules/parent-module": { @@ -17555,7 +17810,6 @@ }, "node_modules/path-key": { "version": "3.1.1", - "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -17563,14 +17817,12 @@ }, "node_modules/path-parse": { "version": "1.0.7", - "dev": true, "license": "MIT" }, "node_modules/path-scurry": { "version": "1.11.1", "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-1.11.1.tgz", "integrity": "sha512-Xa4Nw17FS9ApQFJ9umLiJS4orGjm7ZzwUrwamcGQuHSzDyth9boKDaycYdDcZDuqYATXw4HFXgaqWTctW/v1HA==", - "dev": true, "license": "BlueOak-1.0.0", "dependencies": { "lru-cache": "^10.2.0", @@ -17587,7 +17839,6 @@ "version": "10.2.0", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.2.0.tgz", "integrity": "sha512-2bIM8x+VAf6JT4bKAljS1qUWgMsqZRPGJS6FSahIMPVvctcNhyVp7AJu7quxOW9jwkryBReKZY5tY5JYv2n/7Q==", - "dev": true, "engines": { "node": "14 || >=16.14" } @@ -17624,6 +17875,18 @@ "through": "~2.3" } }, + "node_modules/pbf": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/pbf/-/pbf-3.3.0.tgz", + "integrity": "sha512-XDF38WCH3z5OV/OVa8GKUNtLAyneuzbCisx7QUCF8Q6Nutx0WnJrQe5O+kOtBlLfRNUws98Y58Lblp+NJG5T4Q==", + "dependencies": { + "ieee754": "^1.1.12", + "resolve-protobuf-schema": "^2.1.0" + }, + "bin": { + "pbf": "bin/pbf" + } + }, "node_modules/pend": { "version": "1.2.0", "dev": true, @@ -17651,12 +17914,10 @@ "version": "1.0.1", "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.1.tgz", "integrity": "sha512-anP1Z8qwhkbmu7MFP5iTt+wQKXgwzf7zTyGlcdzabySa9vd0Xt392U0rVmz9poOaBj0uHJKyyo9/upk0HrEQew==", - "dev": true, "license": "ISC" }, "node_modules/picomatch": { "version": "2.3.1", - "dev": true, "license": "MIT", "engines": { "node": ">=8.6" @@ -17686,7 +17947,6 @@ }, "node_modules/pirates": { "version": "4.0.5", - "dev": true, "license": "MIT", "engines": { "node": ">= 6" @@ -17769,7 +18029,6 @@ "version": "8.4.41", "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.41.tgz", "integrity": "sha512-TesUflQ0WKZqAvg52PWL6kHgLKP6xB6heTOdoYM0Wt2UHyxNa4K25EZZMgKns3BH1RLVbZCREPpLY0rhnNoHVQ==", - "dev": true, "funding": [ { "type": "opencollective", @@ -18370,7 +18629,6 @@ "version": "15.1.0", "resolved": "https://registry.npmjs.org/postcss-import/-/postcss-import-15.1.0.tgz", "integrity": "sha512-hpr+J05B2FVYUAXHeK1YyI267J/dDDhMU6B6civm8hSY1jYJnBXxzKDKDswzJmtLHryrjhnDjqqp/49t8FALew==", - "dev": true, "license": "MIT", "dependencies": { "postcss-value-parser": "^4.0.0", @@ -18388,7 +18646,6 @@ "version": "4.0.1", "resolved": "https://registry.npmjs.org/postcss-js/-/postcss-js-4.0.1.tgz", "integrity": "sha512-dDLF8pEO191hJMtlHFPRa8xsizHaM82MLfNkUHdUtVEV3tgTp5oj+8qbEqYM57SLfc74KSbw//4SeJma2LRVIw==", - "dev": true, "license": "MIT", "dependencies": { "camelcase-css": "^2.0.1" @@ -18469,7 +18726,6 @@ "version": "4.0.2", "resolved": "https://registry.npmjs.org/postcss-load-config/-/postcss-load-config-4.0.2.tgz", "integrity": "sha512-bSVhyJGL00wMVoPUzAVAnbEoWyqRxkjv64tUl427SKnPrENtq6hJwUojroMz2VB+Q1edmi4IfrAPpami5VVgMQ==", - "dev": true, "funding": [ { "type": "opencollective", @@ -18505,7 +18761,6 @@ "version": "3.1.2", "resolved": "https://registry.npmjs.org/lilconfig/-/lilconfig-3.1.2.tgz", "integrity": "sha512-eop+wDAvpItUys0FWkHIKeC9ybYrTGbU41U5K7+bttZZeohvnY7M9dZ5kB21GNWiFT2q1OoPTvncPCgSOVO5ow==", - "dev": true, "license": "MIT", "engines": { "node": ">=14" @@ -18518,7 +18773,6 @@ "version": "2.5.0", "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.5.0.tgz", "integrity": "sha512-2wWLbGbYDiSqqIKoPjar3MPgB94ErzCtrNE1FdqGuaO0pi2JGjmE8aW8TDZwzU7vuxcGRdL/4gPQwQ7hD5AMSw==", - "dev": true, "license": "ISC", "bin": { "yaml": "bin.mjs" @@ -18821,7 +19075,6 @@ "version": "6.2.0", "resolved": "https://registry.npmjs.org/postcss-nested/-/postcss-nested-6.2.0.tgz", "integrity": "sha512-HQbt28KulC5AJzG+cZtj9kvKB93CFCdLvog1WFLf1D+xmMvPGlBstkpTEZfK5+AN9hfJocyBFCNiqyS48bpgzQ==", - "dev": true, "funding": [ { "type": "opencollective", @@ -19375,7 +19628,6 @@ "version": "6.1.2", "resolved": "https://registry.npmjs.org/postcss-selector-parser/-/postcss-selector-parser-6.1.2.tgz", "integrity": "sha512-Q8qQfPiZ+THO/3ZrOrO0cJJKfpYCagtMUkXbnEfmgUjwXg6z/WBeOyS9APBBPCTSiDV+s4SwQGu8yFsiMRIudg==", - "dev": true, "license": "MIT", "dependencies": { "cssesc": "^3.0.0", @@ -19459,9 +19711,13 @@ }, "node_modules/postcss-value-parser": { "version": "4.2.0", - "dev": true, "license": "MIT" }, + "node_modules/potpack": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/potpack/-/potpack-2.0.0.tgz", + "integrity": "sha512-Q+/tYsFU9r7xoOJ+y/ZTtdVQwTWfzjbiXBDMM/JKUux3+QPP02iUuIoeBQ+Ot6oEDlC+/PGjB/5A3K7KKb7hcw==" + }, "node_modules/preact": { "version": "10.18.1", "resolved": "https://registry.npmjs.org/preact/-/preact-10.18.1.tgz", @@ -19471,6 +19727,14 @@ "url": "https://opencollective.com/preact" } }, + "node_modules/preline": { + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/preline/-/preline-2.5.0.tgz", + "integrity": "sha512-UC+ddXHsL3xXU0TogA/O3DGqy+xF2/xQYnTSR6vpzEpD3+Te5R9m4NbQy/zhAkFMAfQKKJ9yQBgpA3ML5nPYGg==", + "dependencies": { + "@popperjs/core": "^2.11.2" + } + }, "node_modules/prelude-ls": { "version": "1.2.1", "dev": true, @@ -19592,6 +19856,11 @@ "reflect.ownkeys": "^0.2.0" } }, + "node_modules/protocol-buffers-schema": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/protocol-buffers-schema/-/protocol-buffers-schema-3.6.0.tgz", + "integrity": "sha512-TdDRD+/QNdrCGCE7v8340QyuXd4kIWIgapsE2+n/SaGiSSbomYl4TjHlvIoCWRpE7wFt02EpB35VVA2ImcBVqw==" + }, "node_modules/proxy-addr": { "version": "2.0.7", "dev": true, @@ -19761,7 +20030,6 @@ }, "node_modules/queue-microtask": { "version": "1.2.3", - "dev": true, "funding": [ { "type": "github", @@ -19786,6 +20054,11 @@ "node": ">=8" } }, + "node_modules/quickselect": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/quickselect/-/quickselect-3.0.0.tgz", + "integrity": "sha512-XdjUArbK4Bm5fLLvlm5KpTFOiOThgfWWI4axAZDWg4E/0mKdZyI9tNEfds27qCi1ze/vwTR16kvmmGhRra3c2g==" + }, "node_modules/raf": { "version": "3.4.1", "dev": true, @@ -19985,7 +20258,6 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/read-cache/-/read-cache-1.0.0.tgz", "integrity": "sha512-Owdv/Ft7IjOgm/i0xvNDZ1LrRANRfew4b2prF3OWMQLxLfu3bS8FVhCsrSCMK4lR56Y9ya+AThoTpDCTxCmpRA==", - "dev": true, "license": "MIT", "dependencies": { "pify": "^2.3.0" @@ -19995,7 +20267,6 @@ "version": "2.3.0", "resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz", "integrity": "sha512-udgsAY+fTnvv7kI7aaxbqwWNb0AHiB0qBO89PZKPkoTmGOgdbrHDKD+0B2X4uTfJ/FT1R09r9gTsjUjNJotuog==", - "dev": true, "license": "MIT", "engines": { "node": ">=0.10.0" @@ -20122,7 +20393,6 @@ }, "node_modules/readdirp": { "version": "3.6.0", - "dev": true, "license": "MIT", "dependencies": { "picomatch": "^2.2.1" @@ -20460,7 +20730,6 @@ "version": "1.22.8", "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.8.tgz", "integrity": "sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw==", - "dev": true, "license": "MIT", "dependencies": { "is-core-module": "^2.13.0", @@ -20493,6 +20762,14 @@ "node": ">=8" } }, + "node_modules/resolve-protobuf-schema": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/resolve-protobuf-schema/-/resolve-protobuf-schema-2.1.0.tgz", + "integrity": "sha512-kI5ffTiZWmJaS/huM8wZfEMer1eRd7oJQhDuxeCLe3t7N7mX3z94CN0xPxBQxFYQTSNz9T0i+v6inKqSdK8xrQ==", + "dependencies": { + "protocol-buffers-schema": "^3.3.1" + } + }, "node_modules/resolve.exports": { "version": "1.1.0", "dev": true, @@ -20532,7 +20809,6 @@ }, "node_modules/reusify": { "version": "1.0.4", - "dev": true, "license": "MIT", "engines": { "iojs": ">=1.0.0", @@ -20581,7 +20857,6 @@ }, "node_modules/run-parallel": { "version": "1.2.0", - "dev": true, "funding": [ { "type": "github", @@ -20601,6 +20876,11 @@ "queue-microtask": "^1.2.2" } }, + "node_modules/rw": { + "version": "1.3.3", + "resolved": "https://registry.npmjs.org/rw/-/rw-1.3.3.tgz", + "integrity": "sha512-PdhdWy89SiZogBLaw42zdeqtRJ//zFd2PgQavcICDUgJT5oW10QCRKbJ6bg4r0/UY2M6BWd5tkxuGFRvCkgfHQ==" + }, "node_modules/rxjs": { "version": "7.8.1", "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-7.8.1.tgz", @@ -20947,6 +21227,20 @@ "node": ">= 0.8.0" } }, + "node_modules/set-value": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/set-value/-/set-value-2.0.1.tgz", + "integrity": "sha512-JxHc1weCN68wRY0fhCoXpyK55m/XPHafOmK4UWD7m2CI14GMcFypt4w/0+NV5f/ZMby2F6S2wwA7fgynh9gWSw==", + "dependencies": { + "extend-shallow": "^2.0.1", + "is-extendable": "^0.1.1", + "is-plain-object": "^2.0.3", + "split-string": "^3.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/setprototypeof": { "version": "1.2.0", "dev": true, @@ -20965,7 +21259,6 @@ }, "node_modules/shebang-command": { "version": "2.0.0", - "dev": true, "license": "MIT", "dependencies": { "shebang-regex": "^3.0.0" @@ -20976,7 +21269,6 @@ }, "node_modules/shebang-regex": { "version": "3.0.0", - "dev": true, "license": "MIT", "engines": { "node": ">=8" @@ -21125,6 +21417,38 @@ "websocket-driver": "^0.7.4" } }, + "node_modules/sort-asc": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/sort-asc/-/sort-asc-0.2.0.tgz", + "integrity": "sha512-umMGhjPeHAI6YjABoSTrFp2zaBtXBej1a0yKkuMUyjjqu6FJsTF+JYwCswWDg+zJfk/5npWUUbd33HH/WLzpaA==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/sort-desc": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/sort-desc/-/sort-desc-0.2.0.tgz", + "integrity": "sha512-NqZqyvL4VPW+RAxxXnB8gvE1kyikh8+pR+T+CXLksVRN9eiQqkQlPwqWYU0mF9Jm7UnctShlxLyAt1CaBOTL1w==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/sort-object": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/sort-object/-/sort-object-3.0.3.tgz", + "integrity": "sha512-nK7WOY8jik6zaG9CRwZTaD5O7ETWDLZYMM12pqY8htll+7dYeqGfEUPcUBHOpSJg2vJOrvFIY2Dl5cX2ih1hAQ==", + "dependencies": { + "bytewise": "^1.1.0", + "get-value": "^2.0.2", + "is-extendable": "^0.1.1", + "sort-asc": "^0.2.0", + "sort-desc": "^0.2.0", + "union-value": "^1.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/source-map": { "version": "0.6.1", "dev": true, @@ -21137,7 +21461,6 @@ "version": "1.2.0", "resolved": "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.0.tgz", "integrity": "sha512-itJW8lvSA0TXEphiRoawsCksnlf8SyvmFzIhltqAHluXd88pkCd+cXJVHTDwdCr0IzwptSm035IHQktUu1QUMg==", - "dev": true, "engines": { "node": ">=0.10.0" } @@ -21268,6 +21591,40 @@ "node": "*" } }, + "node_modules/split-string": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/split-string/-/split-string-3.1.0.tgz", + "integrity": "sha512-NzNVhJDYpwceVVii8/Hu6DKfD2G+NrQHlS/V/qgv763EYudVwEcMQNxd2lh+0VrUByXN/oJkl5grOhYWvQUYiw==", + "dependencies": { + "extend-shallow": "^3.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/split-string/node_modules/extend-shallow": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-3.0.2.tgz", + "integrity": "sha512-BwY5b5Ql4+qZoefgMj2NUmx+tehVTH/Kf4k1ZEtOHNFcm2wSxMRo992l6X3TIgni2eZVTZ85xMOjF31fwZAj6Q==", + "dependencies": { + "assign-symbols": "^1.0.0", + "is-extendable": "^1.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/split-string/node_modules/is-extendable": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-1.0.1.tgz", + "integrity": "sha512-arnXMxT1hhoKo9k1LZdmlNyJdDDfy2v0fXjFlmok4+i8ul/6WlbVge9bhM74OpNPQPMGUToDtz+KXa1PneJxOA==", + "dependencies": { + "is-plain-object": "^2.0.4" + }, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/sprintf-js": { "version": "1.0.3", "dev": true, @@ -21472,7 +21829,6 @@ }, "node_modules/string-width": { "version": "4.2.3", - "dev": true, "license": "MIT", "dependencies": { "emoji-regex": "^8.0.0", @@ -21488,7 +21844,6 @@ "version": "4.2.3", "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, "dependencies": { "emoji-regex": "^8.0.0", "is-fullwidth-code-point": "^3.0.0", @@ -21560,7 +21915,6 @@ }, "node_modules/strip-ansi": { "version": "6.0.1", - "dev": true, "license": "MIT", "dependencies": { "ansi-regex": "^5.0.1" @@ -21574,7 +21928,6 @@ "version": "6.0.1", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "dev": true, "dependencies": { "ansi-regex": "^5.0.1" }, @@ -21936,7 +22289,6 @@ "version": "3.35.0", "resolved": "https://registry.npmjs.org/sucrase/-/sucrase-3.35.0.tgz", "integrity": "sha512-8EbVDiu9iN/nESwxeSxDKe0dunta1GOlHufmSSXxMD2z2/tMZpDMpvXQGsc+ajGo8y2uYUmixaSRUc/QPoQ0GA==", - "dev": true, "license": "MIT", "dependencies": { "@jridgewell/gen-mapping": "^0.3.2", @@ -21959,7 +22311,6 @@ "version": "0.3.5", "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.5.tgz", "integrity": "sha512-IzL8ZoEDIBRWEzlCcRhOaCupYyN5gdIK+Q6fbFdPDg6HqX6jpkItn7DFIpW9LQzXG6Df9sA7+OKnq0qlz/GaQg==", - "dev": true, "license": "MIT", "dependencies": { "@jridgewell/set-array": "^1.2.1", @@ -21974,7 +22325,6 @@ "version": "2.0.1", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz", "integrity": "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==", - "dev": true, "license": "MIT", "dependencies": { "balanced-match": "^1.0.0" @@ -21984,7 +22334,6 @@ "version": "4.1.1", "resolved": "https://registry.npmjs.org/commander/-/commander-4.1.1.tgz", "integrity": "sha512-NOKm8xhkzAjzFx8B2v5OAHT+u5pRQc2UCa2Vq9jYL/31o2wi9mxBA7LIFs3sV5VSC49z6pEhfbMULvShKj26WA==", - "dev": true, "license": "MIT", "engines": { "node": ">= 6" @@ -21994,7 +22343,6 @@ "version": "10.4.5", "resolved": "https://registry.npmjs.org/glob/-/glob-10.4.5.tgz", "integrity": "sha512-7Bv8RF0k6xjo7d4A/PxYLbUCfb6c+Vpd2/mB2yRDlew7Jb5hEXiCD9ibfO7wpk8i4sevK6DFny9h7EYbM3/sHg==", - "dev": true, "license": "ISC", "dependencies": { "foreground-child": "^3.1.0", @@ -22015,7 +22363,6 @@ "version": "3.4.3", "resolved": "https://registry.npmjs.org/jackspeak/-/jackspeak-3.4.3.tgz", "integrity": "sha512-OGlZQpz2yfahA/Rd1Y8Cd9SIEsqvXkLVoSw/cgwhnhFMDbsQFeZYoJJ7bIZBS9BcamUW96asq/npPWugM+RQBw==", - "dev": true, "license": "BlueOak-1.0.0", "dependencies": { "@isaacs/cliui": "^8.0.2" @@ -22031,7 +22378,6 @@ "version": "9.0.5", "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.5.tgz", "integrity": "sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==", - "dev": true, "license": "ISC", "dependencies": { "brace-expansion": "^2.0.1" @@ -22072,6 +22418,14 @@ "url": "https://opencollective.com/postcss/" } }, + "node_modules/supercluster": { + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/supercluster/-/supercluster-8.0.1.tgz", + "integrity": "sha512-IiOea5kJ9iqzD2t7QJq/cREyLHTtSmUT6gQsweojg9WH2sYJqZK9SswTu6jrscO6D1G5v5vYZ9ru/eq85lXeZQ==", + "dependencies": { + "kdbush": "^4.0.2" + } + }, "node_modules/supports-color": { "version": "5.5.0", "dev": true, @@ -22116,7 +22470,6 @@ }, "node_modules/supports-preserve-symlinks-flag": { "version": "1.0.0", - "dev": true, "license": "MIT", "engines": { "node": ">= 0.4" @@ -22299,7 +22652,6 @@ "version": "3.4.10", "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-3.4.10.tgz", "integrity": "sha512-KWZkVPm7yJRhdu4SRSl9d4AK2wM3a50UsvgHZO7xY77NQr2V+fIrEuoDGQcbvswWvFGbS2f6e+jC/6WJm1Dl0w==", - "dev": true, "license": "MIT", "dependencies": { "@alloc/quick-lru": "^5.2.0", @@ -22337,14 +22689,12 @@ "version": "5.0.2", "resolved": "https://registry.npmjs.org/arg/-/arg-5.0.2.tgz", "integrity": "sha512-PYjyFOLKQ9y57JvQ6QLo8dAgNqswh8M1RMJYdQduT6xbWSgK36P/Z/v+p888pM69jMMfS8Xd8F6I1kQ/I9HUGg==", - "dev": true, "license": "MIT" }, "node_modules/tailwindcss/node_modules/glob-parent": { "version": "6.0.2", "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz", "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==", - "dev": true, "license": "ISC", "dependencies": { "is-glob": "^4.0.3" @@ -22486,7 +22836,6 @@ "version": "3.3.1", "resolved": "https://registry.npmjs.org/thenify/-/thenify-3.3.1.tgz", "integrity": "sha512-RVZSIV5IG10Hk3enotrhvz0T9em6cyHBLkH/YAZuKqd8hRkKhSfCGIcP2KUY0EPxndzANBmNllzWPwak+bheSw==", - "dev": true, "license": "MIT", "dependencies": { "any-promise": "^1.0.0" @@ -22496,7 +22845,6 @@ "version": "1.6.0", "resolved": "https://registry.npmjs.org/thenify-all/-/thenify-all-1.6.0.tgz", "integrity": "sha512-RNxQH/qI8/t3thXJDwcstUO4zeqo64+Uy/+sNVRBx4Xn2OX+OZ9oP+iJnNFqplFra2ZUVeKCSa2oVWi3T4uVmA==", - "dev": true, "license": "MIT", "dependencies": { "thenify": ">= 3.1.0 < 4" @@ -22525,6 +22873,11 @@ "integrity": "sha512-eHY7nBftgThBqOyHGVN+l8gF0BucP09fMo0oO/Lb0w1OF80dJv+lDVpXG60WMQvkcxAkNybKsrEIE3ZtKGmPrA==", "dev": true }, + "node_modules/tinyqueue": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/tinyqueue/-/tinyqueue-3.0.0.tgz", + "integrity": "sha512-gRa9gwYU3ECmQYv3lslts5hxuIa90veaEcxDYuu3QGOIAEM2mOZkVHp48ANJuu1CURtRdHKUBY5Lm1tHV+sD4g==" + }, "node_modules/tmp": { "version": "0.2.1", "dev": true, @@ -22551,7 +22904,6 @@ }, "node_modules/to-regex-range": { "version": "5.0.1", - "dev": true, "license": "MIT", "dependencies": { "is-number": "^7.0.0" @@ -22621,7 +22973,6 @@ "version": "0.1.13", "resolved": "https://registry.npmjs.org/ts-interface-checker/-/ts-interface-checker-0.1.13.tgz", "integrity": "sha512-Y/arvbn+rrz3JCKl9C4kVNfTfSm2/mEp5FSz5EsZSANGPSlQrpRI5M4PKF+mJnE52jOO90PnPSc3Ur3bTQw0gA==", - "dev": true, "license": "Apache-2.0" }, "node_modules/ts-jest": { @@ -22789,7 +23140,7 @@ }, "node_modules/ts-node": { "version": "10.9.1", - "dev": true, + "devOptional": true, "license": "MIT", "dependencies": { "@cspotcode/source-map-support": "^0.8.0", @@ -22831,7 +23182,7 @@ }, "node_modules/ts-node/node_modules/acorn-walk": { "version": "8.2.0", - "dev": true, + "devOptional": true, "license": "MIT", "engines": { "node": ">=0.4.0" @@ -22839,7 +23190,7 @@ }, "node_modules/ts-node/node_modules/diff": { "version": "4.0.2", - "dev": true, + "devOptional": true, "license": "BSD-3-Clause", "engines": { "node": ">=0.3.1" @@ -22954,7 +23305,7 @@ }, "node_modules/typescript": { "version": "4.8.4", - "dev": true, + "devOptional": true, "license": "Apache-2.0", "bin": { "tsc": "bin/tsc", @@ -22964,6 +23315,19 @@ "node": ">=4.2.0" } }, + "node_modules/typewise": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/typewise/-/typewise-1.0.3.tgz", + "integrity": "sha512-aXofE06xGhaQSPzt8hlTY+/YWQhm9P0jYUp1f2XtmW/3Bk0qzXcyFWAtPoo2uTGQj1ZwbDuSyuxicq+aDo8lCQ==", + "dependencies": { + "typewise-core": "^1.2.0" + } + }, + "node_modules/typewise-core": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/typewise-core/-/typewise-core-1.2.0.tgz", + "integrity": "sha512-2SCC/WLzj2SbUwzFOzqMCkz5amXLlxtJqDKTICqg30x+2DZxcfZN2MvQZmGfXWKNWaKK9pBPsvkcwv8bF/gxKg==" + }, "node_modules/unbox-primitive": { "version": "1.0.2", "dev": true, @@ -23043,6 +23407,20 @@ "url": "https://opencollective.com/unified" } }, + "node_modules/union-value": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/union-value/-/union-value-1.0.1.tgz", + "integrity": "sha512-tJfXmxMeWYnczCVs7XAEvIV7ieppALdyepWMkHkwciRpZraG/xwT+s2JN8+pr1+8jCRf80FFzvr+MpQeeoF4Xg==", + "dependencies": { + "arr-union": "^3.1.0", + "get-value": "^2.0.6", + "is-extendable": "^0.1.1", + "set-value": "^2.0.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/unist-util-find-all-after": { "version": "3.0.2", "dev": true, @@ -23173,7 +23551,6 @@ }, "node_modules/util-deprecate": { "version": "1.0.2", - "dev": true, "license": "MIT" }, "node_modules/utils-merge": { @@ -23199,7 +23576,7 @@ }, "node_modules/v8-compile-cache-lib": { "version": "3.0.1", - "dev": true, + "devOptional": true, "license": "MIT" }, "node_modules/v8-to-istanbul": { @@ -23281,6 +23658,16 @@ "url": "https://opencollective.com/unified" } }, + "node_modules/vt-pbf": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/vt-pbf/-/vt-pbf-3.1.3.tgz", + "integrity": "sha512-2LzDFzt0mZKZ9IpVF2r69G9bXaP2Q2sArJCmcCgvfTdCCZzSyz4aCLoQyUilu37Ll56tCblIZrXFIjNUpGIlmA==", + "dependencies": { + "@mapbox/point-geometry": "0.1.0", + "@mapbox/vector-tile": "^1.3.1", + "pbf": "^3.2.1" + } + }, "node_modules/w3c-hr-time": { "version": "1.0.2", "dev": true, @@ -23921,7 +24308,6 @@ }, "node_modules/which": { "version": "2.0.2", - "dev": true, "license": "ISC", "dependencies": { "isexe": "^2.0.0" @@ -24021,7 +24407,6 @@ "version": "7.0.0", "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", - "dev": true, "dependencies": { "ansi-styles": "^4.0.0", "string-width": "^4.1.0", @@ -24038,7 +24423,6 @@ "version": "4.3.0", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, "dependencies": { "color-convert": "^2.0.1" }, @@ -24053,7 +24437,6 @@ "version": "2.0.1", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, "dependencies": { "color-name": "~1.1.4" }, @@ -24064,8 +24447,7 @@ "node_modules/wrap-ansi-cjs/node_modules/color-name": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" }, "node_modules/wrap-ansi/node_modules/ansi-styles": { "version": "4.3.0", @@ -24227,7 +24609,7 @@ }, "node_modules/yn": { "version": "3.1.1", - "dev": true, + "devOptional": true, "license": "MIT", "engines": { "node": ">=6" diff --git a/assets/package.json b/assets/package.json index 1e4c5bb2ea..557fcf9ab9 100644 --- a/assets/package.json +++ b/assets/package.json @@ -30,6 +30,7 @@ "leaflet": "^1.4.0", "leaflet-rotatedmarker": "^0.2.0", "lodash": "^4.17.21", + "mbta_metro": "^0.0.18", "mobile-detect": "^1.4.5", "phoenix": "file:../deps/phoenix", "phoenix_html": "file:../deps/phoenix_html", diff --git a/assets/static/fonts/Inter-Black.woff2 b/assets/static/fonts/Inter-Black.woff2 deleted file mode 100644 index 18b35db75c..0000000000 Binary files a/assets/static/fonts/Inter-Black.woff2 and /dev/null differ diff --git a/assets/static/fonts/Inter-BlackItalic.woff2 b/assets/static/fonts/Inter-BlackItalic.woff2 deleted file mode 100644 index 02c9d8ecc2..0000000000 Binary files a/assets/static/fonts/Inter-BlackItalic.woff2 and /dev/null differ diff --git a/assets/static/fonts/Inter-Bold.woff2 b/assets/static/fonts/Inter-Bold.woff2 deleted file mode 100644 index 0f1b157633..0000000000 Binary files a/assets/static/fonts/Inter-Bold.woff2 and /dev/null differ diff --git a/assets/static/fonts/Inter-BoldItalic.woff2 b/assets/static/fonts/Inter-BoldItalic.woff2 deleted file mode 100644 index bc50f24c87..0000000000 Binary files a/assets/static/fonts/Inter-BoldItalic.woff2 and /dev/null differ diff --git a/assets/static/fonts/Inter-ExtraBold.woff2 b/assets/static/fonts/Inter-ExtraBold.woff2 deleted file mode 100644 index b1133688a4..0000000000 Binary files a/assets/static/fonts/Inter-ExtraBold.woff2 and /dev/null differ diff --git a/assets/static/fonts/Inter-ExtraBoldItalic.woff2 b/assets/static/fonts/Inter-ExtraBoldItalic.woff2 deleted file mode 100644 index a5b76ca8da..0000000000 Binary files a/assets/static/fonts/Inter-ExtraBoldItalic.woff2 and /dev/null differ diff --git a/assets/static/fonts/Inter-ExtraLight.woff2 b/assets/static/fonts/Inter-ExtraLight.woff2 deleted file mode 100644 index 1d77ae8d04..0000000000 Binary files a/assets/static/fonts/Inter-ExtraLight.woff2 and /dev/null differ diff --git a/assets/static/fonts/Inter-ExtraLightItalic.woff2 b/assets/static/fonts/Inter-ExtraLightItalic.woff2 deleted file mode 100644 index 8c6849209d..0000000000 Binary files a/assets/static/fonts/Inter-ExtraLightItalic.woff2 and /dev/null differ diff --git a/assets/static/fonts/Inter-Italic.woff2 b/assets/static/fonts/Inter-Italic.woff2 deleted file mode 100644 index 4c24ce2815..0000000000 Binary files a/assets/static/fonts/Inter-Italic.woff2 and /dev/null differ diff --git a/assets/static/fonts/Inter-Light.woff2 b/assets/static/fonts/Inter-Light.woff2 deleted file mode 100644 index dbe61437a1..0000000000 Binary files a/assets/static/fonts/Inter-Light.woff2 and /dev/null differ diff --git a/assets/static/fonts/Inter-LightItalic.woff2 b/assets/static/fonts/Inter-LightItalic.woff2 deleted file mode 100644 index a40d042158..0000000000 Binary files a/assets/static/fonts/Inter-LightItalic.woff2 and /dev/null differ diff --git a/assets/static/fonts/Inter-Medium.woff2 b/assets/static/fonts/Inter-Medium.woff2 deleted file mode 100644 index 0fd2ee7370..0000000000 Binary files a/assets/static/fonts/Inter-Medium.woff2 and /dev/null differ diff --git a/assets/static/fonts/Inter-MediumItalic.woff2 b/assets/static/fonts/Inter-MediumItalic.woff2 deleted file mode 100644 index 96767155d9..0000000000 Binary files a/assets/static/fonts/Inter-MediumItalic.woff2 and /dev/null differ diff --git a/assets/static/fonts/Inter-Regular.woff2 b/assets/static/fonts/Inter-Regular.woff2 deleted file mode 100644 index b8699af29b..0000000000 Binary files a/assets/static/fonts/Inter-Regular.woff2 and /dev/null differ diff --git a/assets/static/fonts/Inter-SemiBold.woff2 b/assets/static/fonts/Inter-SemiBold.woff2 deleted file mode 100644 index 95c48b184e..0000000000 Binary files a/assets/static/fonts/Inter-SemiBold.woff2 and /dev/null differ diff --git a/assets/static/fonts/Inter-SemiBoldItalic.woff2 b/assets/static/fonts/Inter-SemiBoldItalic.woff2 deleted file mode 100644 index ddfe19e839..0000000000 Binary files a/assets/static/fonts/Inter-SemiBoldItalic.woff2 and /dev/null differ diff --git a/assets/static/fonts/Inter-Thin.woff2 b/assets/static/fonts/Inter-Thin.woff2 deleted file mode 100644 index 07909608cd..0000000000 Binary files a/assets/static/fonts/Inter-Thin.woff2 and /dev/null differ diff --git a/assets/static/fonts/Inter-ThinItalic.woff2 b/assets/static/fonts/Inter-ThinItalic.woff2 deleted file mode 100644 index a7bf213801..0000000000 Binary files a/assets/static/fonts/Inter-ThinItalic.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-Black.woff2 b/assets/static/fonts/InterDisplay-Black.woff2 deleted file mode 100644 index 8138123c13..0000000000 Binary files a/assets/static/fonts/InterDisplay-Black.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-BlackItalic.woff2 b/assets/static/fonts/InterDisplay-BlackItalic.woff2 deleted file mode 100644 index 735ba21f99..0000000000 Binary files a/assets/static/fonts/InterDisplay-BlackItalic.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-Bold.woff2 b/assets/static/fonts/InterDisplay-Bold.woff2 deleted file mode 100644 index 11c67196e1..0000000000 Binary files a/assets/static/fonts/InterDisplay-Bold.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-BoldItalic.woff2 b/assets/static/fonts/InterDisplay-BoldItalic.woff2 deleted file mode 100644 index 5b6a1fb006..0000000000 Binary files a/assets/static/fonts/InterDisplay-BoldItalic.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-ExtraBold.woff2 b/assets/static/fonts/InterDisplay-ExtraBold.woff2 deleted file mode 100644 index 9058e98613..0000000000 Binary files a/assets/static/fonts/InterDisplay-ExtraBold.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-ExtraBoldItalic.woff2 b/assets/static/fonts/InterDisplay-ExtraBoldItalic.woff2 deleted file mode 100644 index 4cd61c0672..0000000000 Binary files a/assets/static/fonts/InterDisplay-ExtraBoldItalic.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-ExtraLight.woff2 b/assets/static/fonts/InterDisplay-ExtraLight.woff2 deleted file mode 100644 index 8621b29951..0000000000 Binary files a/assets/static/fonts/InterDisplay-ExtraLight.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-ExtraLightItalic.woff2 b/assets/static/fonts/InterDisplay-ExtraLightItalic.woff2 deleted file mode 100644 index 689c8d9ca1..0000000000 Binary files a/assets/static/fonts/InterDisplay-ExtraLightItalic.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-Italic.woff2 b/assets/static/fonts/InterDisplay-Italic.woff2 deleted file mode 100644 index 11f20bc821..0000000000 Binary files a/assets/static/fonts/InterDisplay-Italic.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-Light.woff2 b/assets/static/fonts/InterDisplay-Light.woff2 deleted file mode 100644 index 446301c35e..0000000000 Binary files a/assets/static/fonts/InterDisplay-Light.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-LightItalic.woff2 b/assets/static/fonts/InterDisplay-LightItalic.woff2 deleted file mode 100644 index f688196103..0000000000 Binary files a/assets/static/fonts/InterDisplay-LightItalic.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-Medium.woff2 b/assets/static/fonts/InterDisplay-Medium.woff2 deleted file mode 100644 index 29160b2c5d..0000000000 Binary files a/assets/static/fonts/InterDisplay-Medium.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-MediumItalic.woff2 b/assets/static/fonts/InterDisplay-MediumItalic.woff2 deleted file mode 100644 index ef1bcbe3c7..0000000000 Binary files a/assets/static/fonts/InterDisplay-MediumItalic.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-Regular.woff2 b/assets/static/fonts/InterDisplay-Regular.woff2 deleted file mode 100644 index a6c04f68ec..0000000000 Binary files a/assets/static/fonts/InterDisplay-Regular.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-SemiBold.woff2 b/assets/static/fonts/InterDisplay-SemiBold.woff2 deleted file mode 100644 index 2b4db239b4..0000000000 Binary files a/assets/static/fonts/InterDisplay-SemiBold.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-SemiBoldItalic.woff2 b/assets/static/fonts/InterDisplay-SemiBoldItalic.woff2 deleted file mode 100644 index 59091db311..0000000000 Binary files a/assets/static/fonts/InterDisplay-SemiBoldItalic.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-Thin.woff2 b/assets/static/fonts/InterDisplay-Thin.woff2 deleted file mode 100644 index dc0b948607..0000000000 Binary files a/assets/static/fonts/InterDisplay-Thin.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterDisplay-ThinItalic.woff2 b/assets/static/fonts/InterDisplay-ThinItalic.woff2 deleted file mode 100644 index 96439c0c08..0000000000 Binary files a/assets/static/fonts/InterDisplay-ThinItalic.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterVariable-Italic.woff2 b/assets/static/fonts/InterVariable-Italic.woff2 deleted file mode 100644 index f22ec25549..0000000000 Binary files a/assets/static/fonts/InterVariable-Italic.woff2 and /dev/null differ diff --git a/assets/static/fonts/InterVariable.woff2 b/assets/static/fonts/InterVariable.woff2 deleted file mode 100644 index 22a12b04e1..0000000000 Binary files a/assets/static/fonts/InterVariable.woff2 and /dev/null differ diff --git a/assets/static/google778e4cfd8ca77f44.html b/assets/static/google778e4cfd8ca77f44.html deleted file mode 100644 index a8a9c2b791..0000000000 --- a/assets/static/google778e4cfd8ca77f44.html +++ /dev/null @@ -1 +0,0 @@ -google-site-verification: google778e4cfd8ca77f44.html \ No newline at end of file diff --git a/assets/static/loaderio-392aa6a67825336b70393c6be61d56ce b/assets/static/loaderio-392aa6a67825336b70393c6be61d56ce deleted file mode 100644 index cd68a89769..0000000000 --- a/assets/static/loaderio-392aa6a67825336b70393c6be61d56ce +++ /dev/null @@ -1 +0,0 @@ -loaderio-392aa6a67825336b70393c6be61d56ce diff --git a/assets/static/loaderio-b4c35b9431db61b4421fcf03e17c3818 b/assets/static/loaderio-b4c35b9431db61b4421fcf03e17c3818 deleted file mode 100644 index a2d779d245..0000000000 --- a/assets/static/loaderio-b4c35b9431db61b4421fcf03e17c3818 +++ /dev/null @@ -1 +0,0 @@ -loaderio-b4c35b9431db61b4421fcf03e17c3818 diff --git a/assets/static_page/apple-touch-icon.png b/assets/static_page/apple-touch-icon.png deleted file mode 120000 index 866536d8b7..0000000000 --- a/assets/static_page/apple-touch-icon.png +++ /dev/null @@ -1 +0,0 @@ -../static/apple-touch-icon.png \ No newline at end of file diff --git a/assets/static_page/error-bus.gif b/assets/static_page/error-bus.gif deleted file mode 120000 index aac5aca9f0..0000000000 --- a/assets/static_page/error-bus.gif +++ /dev/null @@ -1 +0,0 @@ -../static/images/error-bus.gif \ No newline at end of file diff --git a/assets/static_page/favicon.ico b/assets/static_page/favicon.ico deleted file mode 120000 index 94fab71771..0000000000 --- a/assets/static_page/favicon.ico +++ /dev/null @@ -1 +0,0 @@ -../static/favicon.ico \ No newline at end of file diff --git a/assets/static_page/maintenance.html b/assets/static_page/maintenance.html deleted file mode 100644 index 2e635868bb..0000000000 --- a/assets/static_page/maintenance.html +++ /dev/null @@ -1,155 +0,0 @@ - - - - - - - - - - MBTA.com Under Maintenance - - - - - - - - -
-
-
-
- MBTA Home Page - -
-
-
-
-

We'll be right back!

-

MBTA.com is down for a bit of maintenance right now. Thanks for your patience. -

- -
-
- -
- - - diff --git a/assets/static_page/mbta-logo-t-favicon.png b/assets/static_page/mbta-logo-t-favicon.png deleted file mode 120000 index 7c096ee355..0000000000 --- a/assets/static_page/mbta-logo-t-favicon.png +++ /dev/null @@ -1 +0,0 @@ -../static/images/mbta-logo-t-favicon.png \ No newline at end of file diff --git a/assets/tailwind.config.js b/assets/tailwind.config.js index 780d75c345..6995bf1d3f 100644 --- a/assets/tailwind.config.js +++ b/assets/tailwind.config.js @@ -1,80 +1,65 @@ // See the Tailwind configuration guide for advanced usage // https://tailwindcss.com/docs/configuration -const plugin = require("tailwindcss/plugin") -const fs = require("fs") -const path = require("path") +const plugin = require("tailwindcss/plugin"); + +const { + colors, + content, + fontFamily, + plugins, + safelist +} = require("mbta_metro"); module.exports = { - prefix: "tw-", - corePlugins: { - preflight: false - }, - content: [ - "./js/**/*.js", - "./ts/**/*.ts", - "./ts/**/*.tsx", - "../lib/dotcom_web.ex", - "../lib/dotcom_web/**/*.*ex" - ], - theme: { - extend: { - colors: { - brand: "#FD4F00", - } - }, + corePlugins: { + preflight: false + }, + blocklist: ["container", "collapse"], + content: [ + ...content, + "./js/**/*.js", + "./ts/**/*.ts", + "./ts/**/*.tsx", + "../lib/dotcom_web.ex", + "../lib/dotcom_web/**/*.*ex" + ], + safelist: [...safelist], + theme: { + extend: { + colors: { + ...colors + } }, - plugins: [ - require("@tailwindcss/forms"), - // Allows prefixing tailwind classes with LiveView classes to add rules - // only when LiveView classes are applied, for example: - // - //
- // - plugin(({ addVariant }) => addVariant("phx-click-loading", [".phx-click-loading&", ".phx-click-loading &"])), - plugin(({ addVariant }) => addVariant("phx-submit-loading", [".phx-submit-loading&", ".phx-submit-loading &"])), - plugin(({ addVariant }) => addVariant("phx-change-loading", [".phx-change-loading&", ".phx-change-loading &"])), - - // Embeds Heroicons (https://heroicons.com) into your app.css bundle - // See your `CoreComponents.icon/1` for more information. - // - plugin(function ({ matchComponents, theme }) { - let iconsDir = path.join(__dirname, "../deps/heroicons/optimized") - let values = {} - let icons = [ - ["", "/24/outline"], - ["-solid", "/24/solid"], - ["-mini", "/20/solid"], - ["-micro", "/16/solid"] - ] - icons.forEach(([suffix, dir]) => { - fs.readdirSync(path.join(iconsDir, dir)).forEach(file => { - let name = path.basename(file, ".svg") + suffix - values[name] = { name, fullPath: path.join(iconsDir, dir, file) } - }) - }) - matchComponents({ - "hero": ({ name, fullPath }) => { - let content = fs.readFileSync(fullPath).toString().replace(/\r?\n|\r/g, "") - let size = theme("spacing.6") - if (name.endsWith("-mini")) { - size = theme("spacing.5") - } else if (name.endsWith("-micro")) { - size = theme("spacing.4") - } - return { - [`--hero-${name}`]: `url('data:image/svg+xml;utf8,${content}')`, - "-webkit-mask": `var(--hero-${name})`, - "mask": `var(--hero-${name})`, - "mask-repeat": "no-repeat", - "background-color": "currentColor", - "vertical-align": "middle", - "display": "inline-block", - "width": size, - "height": size - } - } - }, { values }) - }) - ], -} + fontFamily: { + ...fontFamily + } + }, + plugins: [ + ...plugins, + require("@tailwindcss/forms"), + // Allows prefixing tailwind classes with LiveView classes to add rules + // only when LiveView classes are applied, for example: + // + //
+ // + plugin(({ addVariant }) => + addVariant("phx-click-loading", [ + ".phx-click-loading&", + ".phx-click-loading &" + ]) + ), + plugin(({ addVariant }) => + addVariant("phx-submit-loading", [ + ".phx-submit-loading&", + ".phx-submit-loading &" + ]) + ), + plugin(({ addVariant }) => + addVariant("phx-change-loading", [ + ".phx-change-loading&", + ".phx-change-loading &" + ]) + ) + ] +}; diff --git a/assets/ts/components/Badge.tsx b/assets/ts/components/Badge.tsx index 6a694c08b6..6ba18d5f59 100644 --- a/assets/ts/components/Badge.tsx +++ b/assets/ts/components/Badge.tsx @@ -12,7 +12,7 @@ const Badge = ({ return (
{/* The purpose of this block is to have invisble text for screen readers */} diff --git a/assets/ts/components/ErrorPage.tsx b/assets/ts/components/ErrorPage.tsx index 2e5702a115..b72e05d78c 100644 --- a/assets/ts/components/ErrorPage.tsx +++ b/assets/ts/components/ErrorPage.tsx @@ -10,7 +10,7 @@ const ErrorPage: FallbackRender = errorData => {
-

Oh no! We're experiencing delays.

+

Oh no! We're experiencing delays.

Something went wrong on our end.

@@ -27,7 +27,7 @@ const ErrorPage: FallbackRender = errorData => {
- +
diff --git a/assets/ts/components/FeedbackForm.tsx b/assets/ts/components/FeedbackForm.tsx index c990326490..5e3b33e752 100644 --- a/assets/ts/components/FeedbackForm.tsx +++ b/assets/ts/components/FeedbackForm.tsx @@ -119,7 +119,7 @@ const FeedbackForm = ({ setShowConfirmation(true); }} > -
+
{vote === null ? promptText : "Thanks for your response!"}
@@ -153,9 +153,9 @@ const FeedbackForm = ({ )} {showComment && ( -
+
-
- """ - end - - # All other inputs text, datetime-local, url, password, etc. are handled here... - def input(assigns) do - ~H""" -
- <.label for={@id}><%= @label %> - - <.error :for={msg <- @errors}><%= msg %> -
- """ - end - - @doc """ - Renders a label. - """ - attr :for, :string, default: nil - slot :inner_block, required: true - - def label(assigns) do - ~H""" - - """ - end - - @doc """ - Generates a generic error message. - """ - slot :inner_block, required: true - - def error(assigns) do - ~H""" -

- <.icon name="hero-exclamation-circle-mini" class="tw-mt-0.5 tw-h-5 tw-w-5 tw-flex-none" /> - <%= render_slot(@inner_block) %> -

- """ - end - - @doc """ - Renders a header with title. - """ - attr :class, :string, default: nil - - slot :inner_block, required: true - slot :subtitle - slot :actions - - def header(assigns) do - ~H""" -
-
-

- <%= render_slot(@inner_block) %> -

-

- <%= render_slot(@subtitle) %> -

-
-
<%= render_slot(@actions) %>
-
- """ - end - - @doc ~S""" - Renders a table with generic styling. - - ## Examples - - <.table id="users" rows={@users}> - <:col :let={user} label="id"><%= user.id %> - <:col :let={user} label="username"><%= user.username %> - - """ - attr :id, :string, required: true - attr :rows, :list, required: true - attr :row_id, :any, default: nil, doc: "the function for generating the row id" - attr :row_click, :any, default: nil, doc: "the function for handling phx-click on each row" - - attr :row_item, :any, - default: &Function.identity/1, - doc: "the function for mapping each row before calling the :col and :action slots" - - slot :col, required: true do - attr :label, :string - end - - slot :action, doc: "the slot for showing user actions in the last table column" - - def table(assigns) do - assigns = - with %{rows: %Phoenix.LiveView.LiveStream{}} <- assigns do - assign(assigns, row_id: assigns.row_id || fn {id, _item} -> id end) - end - - ~H""" -
- - - - - - - - - - - - - -
- <%= col[:label] %> - - <%= gettext("Actions") %> -
-
- - - <%= render_slot(col, @row_item.(row)) %> - -
-
-
- - - <%= render_slot(action, @row_item.(row)) %> - -
-
-
- """ - end - - @doc """ - Renders a data list. - - ## Examples - - <.list> - <:item title="Title"><%= @post.title %> - <:item title="Views"><%= @post.views %> - - """ - slot :item, required: true do - attr :title, :string, required: true - end - - def list(assigns) do - ~H""" -
-
-
-
<%= item.title %>
-
<%= render_slot(item) %>
-
-
-
- """ - end - - @doc """ - Renders a back navigation link. - - ## Examples - - <.back navigate={~p"/posts"}>Back to posts - """ - attr :navigate, :any, required: true - slot :inner_block, required: true - - def back(assigns) do - ~H""" -
- <.link - navigate={@navigate} - class="tw-text-sm tw-font-semibold tw-leading-6 tw-text-zinc-900 tw-hover:text-zinc-700" - > - <.icon name="hero-arrow-left-solid" class="tw-h-3 tw-w-3" /> - <%= render_slot(@inner_block) %> - -
- """ - end - - @doc """ - Renders a [Heroicon](https://heroicons.com). - - Heroicons come in three styles – outline, solid, and mini. - By default, the outline style is used, but solid and mini may - be applied by using the `-solid` and `-mini` suffix. - - You can customize the size and colors of the icons by setting - width, height, and background color classes. - - Icons are extracted from the `deps/heroicons` directory and bundled within - your compiled app.css by the plugin in your `assets/tailwind.config.js`. - - ## Examples - - <.icon name="hero-x-mark-solid" /> - <.icon name="hero-arrow-path" class="tw-ml-1 tw-w-3 tw-h-3 tw-animate-spin" /> - """ - attr :name, :string, required: true - attr :class, :string, default: nil - - def icon(%{name: "hero-" <> _} = assigns) do - ~H""" - - """ - end - - ## JS Commands - - def show(js \\ %JS{}, selector) do - JS.show(js, - to: selector, - time: 300, - transition: - {"tw-transition-all tw-transform tw-ease-out tw-duration-300", - "tw-opacity-0 tw-translate-y-4 tw-sm:translate-y-0 tw-sm:scale-95", - "tw-opacity-100 tw-translate-y-0 tw-sm:scale-100"} - ) - end - - def hide(js \\ %JS{}, selector) do - JS.hide(js, - to: selector, - time: 200, - transition: - {"tw-transition-all tw-transform tw-ease-in tw-duration-200", - "tw-opacity-100 tw-translate-y-0 tw-sm:scale-100", - "tw-opacity-0 tw-translate-y-4 tw-sm:translate-y-0 tw-sm:scale-95"} - ) - end - - def show_modal(js \\ %JS{}, id) when is_binary(id) do - js - |> JS.show(to: "##{id}") - |> JS.show( - to: "##{id}-bg", - time: 300, - transition: - {"tw-transition-all tw-transform tw-ease-out tw-duration-300", "tw-opacity-0", - "tw-opacity-100"} - ) - |> show("##{id}-container") - |> JS.add_class("tw-overflow-hidden", to: "body") - |> JS.focus_first(to: "##{id}-content") - end - - def hide_modal(js \\ %JS{}, id) do - js - |> JS.hide( - to: "##{id}-bg", - transition: - {"tw-transition-all tw-transform tw-ease-in tw-duration-200", "tw-opacity-100", - "tw-opacity-0"} - ) - |> hide("##{id}-container") - |> JS.hide(to: "##{id}", transition: {"tw-block", "tw-block", "tw-hidden"}) - |> JS.remove_class("tw-overflow-hidden", to: "body") - |> JS.pop_focus() - end - - @doc """ - Translates an error message using gettext. - """ - def translate_error({msg, opts}) do - # When using gettext, we typically pass the strings we want - # to translate as a static argument: - # - # # Translate the number of files with plural rules - # dngettext("errors", "1 file", "%{count} files", count) - # - # However the error messages in our forms and APIs are generated - # dynamically, so we need to translate them by calling Gettext - # with our gettext backend as first argument. Translations are - # available in the errors.po file (as we use the "errors" domain). - if count = opts[:count] do - Gettext.dngettext(HelloWeb.Gettext, "errors", msg, msg, count, opts) - else - Gettext.dgettext(HelloWeb.Gettext, "errors", msg, opts) - end - end - - @doc """ - Translates the errors for a field from a keyword list of errors. - """ - def translate_errors(errors, field) when is_list(errors) do - for {^field, {msg, opts}} <- errors, do: translate_error({msg, opts}) - end -end diff --git a/lib/dotcom_web/components/live_components/trip_planner_form.ex b/lib/dotcom_web/components/live_components/trip_planner_form.ex new file mode 100644 index 0000000000..213502aa40 --- /dev/null +++ b/lib/dotcom_web/components/live_components/trip_planner_form.ex @@ -0,0 +1,274 @@ +defmodule DotcomWeb.Components.LiveComponents.TripPlannerForm do + @moduledoc """ + A form to plan trips. + """ + use DotcomWeb, :live_component + + import DotcomWeb.ViewHelpers, only: [svg: 1] + import Phoenix.HTML.Form, only: [input_name: 2, input_value: 2, input_id: 2] + + import MbtaMetro.Components.Feedback + import MbtaMetro.Components.InputGroup + + alias Dotcom.TripPlan.{InputForm, OpenTripPlanner} + + @all_modes [:RAIL, :SUBWAY, :BUS, :FERRY] + @form_defaults %{ + "datetime_type" => :now, + "datetime" => NaiveDateTime.local_now(), + "modes" => @all_modes, + "wheelchair" => true + } + + @impl true + def mount(socket) do + form = + %InputForm{} + |> InputForm.changeset(@form_defaults) + |> to_form() + + {:ok, + assign(socket, %{ + form: form, + location_keys: InputForm.Location.fields(), + show_datepicker: input_value(form, :datetime_type) != :now + })} + end + + @impl true + def render(assigns) do + ~H""" +
+ <.form + :let={f} + class="md:grid md:grid-cols-2 gap-x-8 gap-y-2" + id={@id} + for={@form} + method="get" + phx-change="validate" + phx-submit="save_form" + phx-target={@myself} + > +
+ <.algolia_autocomplete + config_type="trip-planner" + placeholder="Enter a location" + id={"#{@form_name}--#{field}"} + > + <.inputs_for :let={location_f} field={f[field]} skip_hidden={true}> + + + <.feedback :for={{msg, _} <- f[field].errors} :if={used_input?(f[field])} kind={:error}> + <%= msg %> + + +
+ <.fieldset legend="When"> +
    +
  • + <.input + id={input_id(@form, :datetime_type) <> "_#{type}"} + type="radio" + field={f[:datetime_type]} + value={type} + checked={input_value(@form, :datetime_type) == type} + phx-click="toggle_datepicker" + phx-target={@myself} + /> +
  • +
+ + <.feedback + :for={{msg, _} <- f[:datetime_type].errors} + :if={used_input?(f[:datetime_type])} + kind={:error} + > + <%= msg %> + + <.label :if={@show_datepicker} for="timepick"> + + Date and time to leave at or arrive by + + <.feedback + :for={{msg, _} <- f[:datetime_type].errors} + :if={used_input?(f[:datetime_type])} + kind={:error} + > + <%= msg %> + + <.feedback + :for={{msg, _} <- f[:datetime].errors} + :if={used_input?(f[:datetime])} + kind={:error} + > + <%= msg %> + + +
+ <.fieldset legend="Modes"> + <.accordion> + <:heading> + <%= selected_modes(input_value(@form, :modes)) %> + + <:content> +
+ "[]"} + value="" + checked="true" + /> + +
+ + <:extra :if={used_input?(f[:modes])}> + <.feedback :for={{msg, _} <- f[:modes].errors} kind={:error}> + <%= msg %> + + + + +
+ <.input type="checkbox" field={f[:wheelchair]} label="Prefer accessible routes" /> + <%= svg("icon-accessible-small.svg") %> +
+
+
+ <.button color="green" type="submit" phx-disable-with="Planning your trip..."> + Get trip suggestions + +
+ +
+ """ + end + + @impl true + def handle_event("toggle_datepicker", %{"value" => datetime_value}, socket) do + {:noreply, assign(socket, :show_datepicker, datetime_value !== "now")} + end + + def handle_event("validate", %{"input_form" => params}, socket) do + form = + params + |> InputForm.validate_params() + |> Phoenix.Component.to_form() + + {:noreply, assign(socket, %{form: form})} + end + + def handle_event("save_form", %{"input_form" => params}, socket) do + params + |> InputForm.validate_params() + |> Ecto.Changeset.apply_action(:update) + |> case do + {:ok, data} -> + %{on_submit: on_submit} = socket.assigns + {:noreply, assign(socket, :plan, plan(data, on_submit))} + + {:error, changeset} -> + form = + changeset + |> Phoenix.Component.to_form() + + {:noreply, assign(socket, %{form: form})} + end + end + + defp plan(data, on_submit) do + _ = on_submit.(data) + result = OpenTripPlanner.plan(data) + _ = on_submit.(result) + result + end + + defp mode_atom(mode) do + case mode do + :RAIL -> :commuter_rail + :SUBWAY -> :subway + :BUS -> :bus + :FERRY -> :ferry + other when is_binary(other) and other != "" -> String.to_atom(other) + _ -> :unknown + end + end + + defp mode_name(mode) do + case mode_atom(mode) do + :unknown -> + "" + + other -> + DotcomWeb.ViewHelpers.mode_name(other) + end + end + + defp selected_modes(modes) when modes == @all_modes do + "All modes" + end + + defp selected_modes([]), do: "No transit modes selected" + defp selected_modes(nil), do: "No transit modes selected" + + defp selected_modes([mode]), do: mode_name(mode) <> " Only" + defp selected_modes([mode1, mode2]), do: mode_name(mode1) <> " and " <> mode_name(mode2) + + defp selected_modes(modes) do + modes + |> Enum.map(&mode_name/1) + |> Enum.reject(&(&1 == "")) + |> Enum.intersperse(", ") + |> List.insert_at(-2, "and ") + |> Enum.join("") + end +end diff --git a/lib/dotcom_web/components/trip_planner.ex b/lib/dotcom_web/components/trip_planner.ex deleted file mode 100644 index 41dbedfbcb..0000000000 --- a/lib/dotcom_web/components/trip_planner.ex +++ /dev/null @@ -1,98 +0,0 @@ -defmodule DotcomWeb.Components.TripPlannerForm do - @moduledoc """ - Reusable components mainly used for the Trip Planner - """ - use DotcomWeb, :component - - alias Dotcom.TripPlan.InputForm - - attr :id, :string - attr :params, :map, default: %{} - attr :phx_submit_handler, :string, default: nil - attr :on_validated_pid, :any - - attr :do_validation, :boolean, - default: false, - doc: "Whether to run the form validation on render." - - @doc """ - A form to plan trips. Use in a LiveView and specify the phx-action: - - ``` <.TripPlanner.input_form params={%{}} id="widget" phx_submit_handler="my_form_save_event" /> ``` - - With no phx-action provided, we'll assume we're outside a LiveView, and will - use an action to submit to the trip planner page. - """ - def input_form(assigns) do - assigns = - assigns - |> assign(:action, assign_action(assigns)) - |> assign(:form, create_form(assigns)) - |> assign(:location_keys, InputForm.Location.fields()) - - ~H""" - <.form - :let={f} - for={@form} - action={@action} - method="get" - phx-change="input_change" - phx-submit={@phx_submit_handler} - > -
- <.algolia_autocomplete - config_type="trip-planner" - placeholder="Enter a location" - id={"#{@id}--#{field}"} - > - <.inputs_for :let={location_f} field={f[field]} skip_hidden={true}> - - -

- <%= msg %> -

- -
- - - """ - end - - defp create_form(%{do_validation: true, params: params, on_validated_pid: on_validated_pid}) - when is_pid(on_validated_pid) do - changeset = InputForm.validate_params(params) - - case Ecto.Changeset.apply_action(changeset, :insert) do - {:ok, data} -> - send(on_validated_pid, {:updated_form, data}) - - data - |> InputForm.changeset(%{}) - |> Phoenix.Component.to_form(as: "plan") - - {:error, changeset} -> - send(on_validated_pid, {:updated_form, nil}) - Phoenix.Component.to_form(changeset, as: "plan") - end - end - - defp create_form(%{params: params}) do - params - |> InputForm.changeset() - |> Phoenix.Component.to_form(as: "plan") - end - - defp assign_action(%{phx_submit_handler: handler}) when is_nil(handler), - do: "/preview/trip-planner" - - defp assign_action(_), do: nil -end diff --git a/lib/dotcom_web/components/trip_planner/itinerary_group.ex b/lib/dotcom_web/components/trip_planner/itinerary_group.ex new file mode 100644 index 0000000000..e1dd1c2d01 --- /dev/null +++ b/lib/dotcom_web/components/trip_planner/itinerary_group.ex @@ -0,0 +1,44 @@ +defmodule DotcomWeb.Components.TripPlanner.ItineraryGroup do + @moduledoc """ + A component to render an itinerary group. + """ + + use DotcomWeb, :component + + import DotcomWeb.Components.TripPlanner.Leg + + attr :group, :map + + @doc """ + Renders a single itinerary group. + """ + def itinerary_group(assigns) do + ~H""" +
+
Group with <%= Enum.count(@group) %> options
+ <.accordion :for={{variation, index} <- Enum.with_index(@group)} open={index === 0}> + <:heading> + <%= format_datetime(variation.departure) %> — <%= format_datetime(variation.arrival) %> + + <:content> +
+ <.leg + start_time={leg.start} + end_time={leg.stop} + from={leg.from} + to={leg.to} + mode={leg.mode} + realtime={leg.realtime} + realtime_state={leg.realtime_state} + /> +
+ + +
+ """ + end + + defp format_datetime(datetime) do + Timex.format!(datetime, "%-I:%M %p", :strftime) + end +end diff --git a/lib/dotcom_web/components/trip_planner/leg.ex b/lib/dotcom_web/components/trip_planner/leg.ex new file mode 100644 index 0000000000..6796b354d0 --- /dev/null +++ b/lib/dotcom_web/components/trip_planner/leg.ex @@ -0,0 +1,96 @@ +defmodule DotcomWeb.Components.TripPlanner.Leg do + @moduledoc """ + Renders information about an itinerary's leg, going from one place to another via either transit or walking. + """ + + use DotcomWeb, :component + + alias DotcomWeb.PartialView.SvgIconWithCircle + alias DotcomWeb.ViewHelpers + alias Dotcom.TripPlan.{PersonalDetail, TransitDetail} + alias OpenTripPlannerClient.Schema.Step + alias Stops.Stop + + attr :from, :any + attr :to, :any + attr :start_time, :any + attr :end_time, :any + attr :mode, :any + attr :realtime, :boolean + attr :realtime_state, :string + + def leg(assigns) do + assigns = + assign( + assigns, + :realtime_class, + if(assigns.realtime, + do: "bg-emerald-100 border-emerald-600 border-4", + else: "bg-zinc-100 border-zinc-300" + ) + ) + + ~H""" +
+
+ <%= @from.name %> + <%= format_time(@start_time) %> +
+
+

Realtime data: <%= @realtime_state %>

+ <.mode mode={@mode} /> +
+
+ <%= @to.name %> + <%= format_time(@end_time) %> +
+
+ """ + end + + defp format_time(datetime), do: Timex.format!(datetime, "%-I:%M %p", :strftime) + + attr :mode, :any + + def mode(assigns) do + case assigns.mode do + %PersonalDetail{} -> + ~H""" + <.walking_steps steps={assigns.mode.steps} /> + """ + + %TransitDetail{} -> + ~H""" + <.transit + route={assigns.mode.route} + trip_id={assigns.mode.trip_id} + stops={assigns.mode.intermediate_stops} + /> + """ + end + end + + def transit(assigns) do + ~H""" +
+ <%= ViewHelpers.line_icon(@route, :default) %> (<%= @route.name %>) on trip <%= @trip_id %> +
+
    +
  • + <%= stop.name %> <%= if Stop.accessible?(stop), + do: SvgIconWithCircle.svg_icon_with_circle(%SvgIconWithCircle{icon: :access}) %> +
  • +
+ """ + end + + def walking_steps(assigns) do + ~H""" +
    +
  • + <%= Step.walk_summary(step) %> +
  • +
+ """ + end +end diff --git a/lib/dotcom_web/controllers/trip_plan/feedback_csv.ex b/lib/dotcom_web/controllers/trip_plan/feedback_csv.ex index 57d1256022..7e33c470fb 100644 --- a/lib/dotcom_web/controllers/trip_plan/feedback_csv.ex +++ b/lib/dotcom_web/controllers/trip_plan/feedback_csv.ex @@ -2,11 +2,10 @@ defmodule DotcomWeb.TripPlan.FeedbackCSV do @moduledoc """ Handle formatting feedback into a spreadsheet-friendly format. """ + alias OpenTripPlannerClient.Schema.Step require Logger - alias Dotcom.TripPlan.PersonalDetail.Step - @headers [ "generated_time", "itinerary_index", @@ -139,19 +138,18 @@ defmodule DotcomWeb.TripPlan.FeedbackCSV do defp mode_description(%{"steps" => steps, "distance" => distance}) do step_description = - Enum.map_join(steps, ";\n\t", fn %{ - "relative_direction" => direction, - "street_name" => street_name - } -> - relative_direction = String.to_atom(direction) - - [ - Step.human_relative_direction(relative_direction), - Step.human_relative_preposition(relative_direction), - street_name - ] - |> Enum.join(" ") + steps + |> Enum.map(fn step -> + # since this is happening after data serialization, re-create the atom + # keys so that Nestru can re-decode it and compute the appropriate text + # via Step.walk_summary/1 + Enum.map(step, fn {k, v} -> + {String.to_atom(k), v} + end) + |> Enum.into(%{}) end) + |> Nestru.decode_from_list!(Step) + |> Enum.map_join(";\n\t", &Step.walk_summary/1) "walking #{distance} meters:\n\t#{step_description}" end diff --git a/lib/dotcom_web/live/admin.ex b/lib/dotcom_web/live/admin.ex index 30b9f6c119..0a1e9ee221 100644 --- a/lib/dotcom_web/live/admin.ex +++ b/lib/dotcom_web/live/admin.ex @@ -26,13 +26,13 @@ defmodule DotcomWeb.Live.Admin do
<%= for feature <- @admin_features do %> <%= link to: feature.url, class: "btn btn-secondary", style: "white-space: inherit;" do %> -
<%= feature.title %>
-

<%= feature.description %>

+
<%= feature.title %>
+

<%= feature.description %>

<% end %> <% end %>
-
???
-

Your idea here (just send a message to @thecristen)

+
???
+

Your idea here (just send a message to @thecristen)

""" diff --git a/lib/dotcom_web/live/trip_planner.ex b/lib/dotcom_web/live/trip_planner.ex index 01894cc657..3c3e12bc5f 100644 --- a/lib/dotcom_web/live/trip_planner.ex +++ b/lib/dotcom_web/live/trip_planner.ex @@ -7,52 +7,56 @@ defmodule DotcomWeb.Live.TripPlanner do use DotcomWeb, :live_view - import DotcomWeb.Components.TripPlannerForm + alias DotcomWeb.Components.LiveComponents.TripPlannerForm + alias Dotcom.TripPlan.ItineraryGroups - @form_id "trip-planner-form" - - @impl true - def mount(params, _session, socket) do - pid = self() - {:ok, assign(socket, :params, plan_params(params)) |> assign(:pid, pid)} - end + import DotcomWeb.Components.TripPlanner.ItineraryGroup, only: [itinerary_group: 1] - defp plan_params(%{"plan" => params}), do: params - defp plan_params(_), do: %{} + @form_id "trip-planner-form" @impl true - def handle_params(params, _uri, socket) do - {:noreply, assign(socket, :params, plan_params(params))} + def mount(_params, _session, socket) do + socket = + socket + |> assign(:form_name, @form_id) + |> assign(:submitted_values, nil) + |> assign(:groups, nil) + |> assign(:error, nil) + + {:ok, socket} end @impl true def render(assigns) do - assigns = - assigns - |> assign_new(:submitted_values, fn -> nil end) - |> assign_new(:do_validation, fn -> false end) - |> assign(:form_id, @form_id) - ~H"""

Trip Planner Preview

-
- <.input_form - params={@params} - id={@form_id} - do_validation={@do_validation} - on_validated_pid={@pid} - phx_submit_handler="save_form" - /> - - <%= inspect(@submitted_values) %> - + <.live_component + module={TripPlannerForm} + id={@form_name} + form_name={@form_name} + on_submit={fn data -> send(self(), {:updated_form, data}) end} + /> +
+

+ <%= Enum.count(@groups) %> ways to get from <%= @submitted_values.from.name %> to <%= @submitted_values.to.name %>, using <%= inspect( + @submitted_values.modes + ) %> +

-
-
-
+
+
+ <%= inspect(@error) %>
-
+
+ <%= for group <- @groups do %> + <.itinerary_group group={group} /> + <% end %> +
+
+
+
+
""" end @@ -63,38 +67,26 @@ defmodule DotcomWeb.Live.TripPlanner do end @impl true - def handle_event("input_change", %{"plan" => params}, socket) do - merged_params = - socket.assigns.params - |> Map.merge(params, fn _, a, b -> Map.merge(a, b) end) - - {:noreply, - assign(socket, %{ - do_validation: false, - params: merged_params - })} + def handle_event(_event, _params, socket) do + {:noreply, socket} end @impl true - def handle_event("save_form", %{"plan" => params}, socket) do - {:noreply, - socket - |> assign(:do_validation, true) - |> push_patch(to: path_with_params(params), replace: true)} + def handle_info({:updated_form, %Dotcom.TripPlan.InputForm{} = data}, socket) do + {:noreply, assign(socket, %{submitted_values: data, groups: nil})} end - @impl true - def handle_event(_, _, socket), do: {:noreply, socket} + def handle_info({:updated_form, {:ok, itineraries}}, socket) do + groups = ItineraryGroups.from_itineraries(itineraries) + {:noreply, assign(socket, %{error: nil, groups: groups})} + end - @impl true - def handle_info({:updated_form, data}, socket) do - {:noreply, assign(socket, :submitted_values, data)} + def handle_info({:updated_form, {:error, error}}, socket) do + {:noreply, assign(socket, :error, error)} end - defp path_with_params(params) do - %{"plan" => params} - |> Plug.Conn.Query.encode() - |> then(&("/preview/trip-planner?" <> &1)) + def handle_info(_info, socket) do + {:noreply, socket} end # Selected from list of popular locations diff --git a/lib/dotcom_web/plugs/static.ex b/lib/dotcom_web/plugs/static.ex index d982b23dc6..57c1564d99 100644 --- a/lib/dotcom_web/plugs/static.ex +++ b/lib/dotcom_web/plugs/static.ex @@ -8,11 +8,10 @@ defmodule DotcomWeb.Plugs.Static do Plug.Static, at: "/", from: :dotcom, - gzip: true, + gzip: Mix.env() == :prod, headers: %{"access-control-allow-origin" => "*"}, cache_control_for_etags: "public, max-age=86400", - only: - ~w(css fonts icon-svg images js robots.txt google778e4cfd8ca77f44.html loaderio-b4c35b9431db61b4421fcf03e17c3818 loaderio-392aa6a67825336b70393c6be61d56ce), + only: DotcomWeb.static_paths(), only_matching: ~w(favicon apple-touch-icon) ) diff --git a/lib/dotcom_web/templates/alert/_item.html.eex b/lib/dotcom_web/templates/alert/_item.html.eex index 8d5a394211..9f9ae8cf61 100644 --- a/lib/dotcom_web/templates/alert/_item.html.eex +++ b/lib/dotcom_web/templates/alert/_item.html.eex @@ -34,7 +34,7 @@
<%= if Map.get(@alert, :image) do %> - <%= @alert.image_alternative_text %> + <%= @alert.image_alternative_text %> <% end %>
diff --git a/lib/dotcom_web/templates/bus_stop_change/index.html.eex b/lib/dotcom_web/templates/bus_stop_change/index.html.eex index ba9f1dca68..d61b3bc653 100644 --- a/lib/dotcom_web/templates/bus_stop_change/index.html.eex +++ b/lib/dotcom_web/templates/bus_stop_change/index.html.eex @@ -24,10 +24,10 @@
No alerts here.
<% else %> <%= for {municipality, muni_alerts} <- alerts_grouped_by_municipality do %> -

<%= municipality %>

+

<%= municipality %>

<%= for {stop, alerts} <- muni_alerts do %>
-

<%= affected_stop_link(@conn, stop) %>

+

<%= affected_stop_link(@conn, stop) %>

<%= for alert <- alerts do %> <%= for route <- affected_routes(alert) do %> diff --git a/lib/dotcom_web/templates/customer_support/_form.html.eex b/lib/dotcom_web/templates/customer_support/_form.html.eex index fa4cbfefdb..b82a01228f 100644 --- a/lib/dotcom_web/templates/customer_support/_form.html.eex +++ b/lib/dotcom_web/templates/customer_support/_form.html.eex @@ -128,7 +128,7 @@ <%= label f, :phone, "Phone number", [for: "phone", class: "form-control-label"] %> <%= telephone_input f, :phone, placeholder: placeholder_text("phone"), class: "support-form-input support-form-input--small form-control", "aria-describedby": "phoneHelp", autocomplete: "tel", id: "phone" %>
-
mb-0 mt-1"> +
u-mb-0 u-mt-1"> <%= support_error_tag @errors, "privacy" %> <%= DotcomWeb.PartialView.render("_checkbox.html", %{ form: f, @@ -158,12 +158,12 @@
-