Skip to content

Commit

Permalink
Move gov.uk components to another repo
Browse files Browse the repository at this point in the history
  • Loading branch information
dabreegster committed Feb 26, 2024
1 parent 00fc4dd commit ec58ca1
Show file tree
Hide file tree
Showing 85 changed files with 81 additions and 421 deletions.
12 changes: 12 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@
"@turf/nearest-point-on-line": "^6.5.0",
"@turf/random": "^6.5.0",
"govuk-frontend": "^5.1.0",
"govuk-svelte": "github:acteng/govuk-svelte",
"humanize-string": "^3.0.0",
"js-cookie": "^3.0.5",
"maplibre-gl": "^3.5.1",
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/Filters.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
FormElement,
SecondaryButton,
Select,
} from "lib/govuk";
} from "govuk-svelte";
import { onMount } from "svelte";
import type { FeatureUnion } from "types";
import { fundingProgrammesForColouringAndFiltering } from "./data";
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/InterventionColorSelector.svelte
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<script lang="ts">
import { CollapsibleCard, Legend } from "lib/common";
import { Select } from "lib/govuk";
import { Select } from "govuk-svelte";
import { colorInterventionsBySchema, schemaLegend } from "schemas";
import { map } from "stores";
import { styleByCurrentMilestone, styleByFundingProgramme } from "./colors";
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/LayerControls.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
LineMeasureController,
StreetViewTool,
} from "lib/common";
import { CheckboxGroup } from "lib/govuk";
import { CheckboxGroup } from "govuk-svelte";
import { layerId } from "lib/maplibre";
import { FillLayer, GeoJSON } from "svelte-maplibre";
import CensusOutputAreaLayerControl from "./layers/areas/CensusOutputAreas.svelte";
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/SchemeCard.svelte
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script lang="ts">
import type { FeatureCollection } from "geojson";
import { CollapsibleCard } from "lib/common";
import { ButtonGroup, SecondaryButton } from "lib/govuk";
import { ButtonGroup, SecondaryButton } from "govuk-svelte";
import { bbox } from "lib/maplibre";
import { map } from "stores";
import type { SchemeData } from "types";
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/areas/CensusOutputAreas.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId, makeColorRamp } from "lib/maplibre";
import {
FillLayer,
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/areas/CombinedAuthorities.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId } from "lib/maplibre";
import {
FillLayer,
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/areas/IMD.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId, makeColorRamp } from "lib/maplibre";
import {
FillLayer,
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/areas/LocalAuthorityDistricts.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId } from "lib/maplibre";
import {
FillLayer,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId } from "lib/maplibre";
import {
FillLayer,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId } from "lib/maplibre";
import {
FillLayer,
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/areas/Pollution.svelte
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<script lang="ts">
import { ExternalLink, HelpButton } from "lib/common";
import { Checkbox, Select } from "lib/govuk";
import { Checkbox, Select } from "govuk-svelte";
import { layerId } from "lib/maplibre";
import { RasterLayer, RasterTileSource } from "svelte-maplibre";
import OsOglLicense from "../OsOglLicense.svelte";
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/areas/Wards.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId } from "lib/maplibre";
import {
FillLayer,
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/lines/BusRoutes.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId } from "lib/maplibre";
import {
hoverStateFilter,
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/lines/CyclePaths.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox, CheckboxGroup } from "lib/govuk";
import { Checkbox, CheckboxGroup } from "govuk-svelte";
import { constructMatchExpression, layerId } from "lib/maplibre";
import type { ExpressionSpecification } from "maplibre-gl";
import {
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/lines/MajorRoadNetwork.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId } from "lib/maplibre";
import {
hoverStateFilter,
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/lines/NationalCycleNetwork.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId } from "lib/maplibre";
import {
hoverStateFilter,
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/lines/PCT.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox, Radio, Select } from "lib/govuk";
import { Checkbox, Radio, Select } from "govuk-svelte";
import { layerId, makeColorRamp } from "lib/maplibre";
import {
hoverStateFilter,
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/lines/PavementWidths.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Popup,
privateResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId, makeColorRamp } from "lib/maplibre";
import {
hoverStateFilter,
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/lines/RoadSpeeds.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Popup,
privateResourceBaseUrl,
} from "lib/common";
import { Checkbox, Radio } from "lib/govuk";
import { Checkbox, Radio } from "govuk-svelte";
import { layerId, makeColorRamp } from "lib/maplibre";
import {
hoverStateFilter,
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/lines/RoadWidths.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Popup,
privateResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId, makeColorRamp } from "lib/maplibre";
import {
hoverStateFilter,
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/lines/Trams.svelte
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<script lang="ts">
import { ColorLegend, HelpButton, publicResourceBaseUrl } from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId } from "lib/maplibre";
import {
hoverStateFilter,
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/points/BusStops.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId, makeColorRamp } from "lib/maplibre";
import { CircleLayer, VectorTileSource } from "svelte-maplibre";
import { colors } from "../../colors";
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/points/CriticalIssues.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
CheckboxGroup,
ErrorMessage,
FormElement,
} from "lib/govuk";
} from "govuk-svelte";
import { emptyGeojson, layerId } from "lib/maplibre";
import type { GeoJSONSource } from "maplibre-gl";
import { map } from "stores";
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/points/Crossings.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { constructMatchExpression, layerId } from "lib/maplibre";
import {
CircleLayer,
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/points/CycleParking.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId } from "lib/maplibre";
import { SymbolLayer, VectorTileSource } from "svelte-maplibre";
import cycleParking from "../../../../../assets/bicycle_parking.png?url";
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/points/Education.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox, CheckboxGroup } from "lib/govuk";
import { Checkbox, CheckboxGroup } from "govuk-svelte";
import { constructMatchExpression, layerId } from "lib/maplibre";
import {
FillLayer,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId } from "lib/maplibre";
import {
FillLayer,
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/points/RailwayStations.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId } from "lib/maplibre";
import { GeoJSON, SymbolLayer } from "svelte-maplibre";
import railwayStation from "../../../../../assets/railway_station.png?url";
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/points/Stats19.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox, CheckboxGroup } from "lib/govuk";
import { Checkbox, CheckboxGroup } from "govuk-svelte";
import { layerId, makeColorRamp } from "lib/maplibre";
import type { ExpressionSpecification } from "maplibre-gl";
import {
Expand Down
2 changes: 1 addition & 1 deletion src/lib/browse/layers/points/VehicleCounts.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId, makeColorRamp } from "lib/maplibre";
import {
CircleLayer,
Expand Down
2 changes: 1 addition & 1 deletion src/lib/common/BaselayerSwitcher.svelte
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script lang="ts">
import { Select } from "lib/govuk";
import { Select } from "govuk-svelte";
import { getStyleChoices } from "lib/maplibre";
import { mapStyle } from "stores";
Expand Down
2 changes: 1 addition & 1 deletion src/lib/common/FileInput.svelte
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<script lang="ts">
import { v4 as uuidv4 } from "uuid";
import { FormElement } from "lib/govuk";
import { FormElement } from "govuk-svelte";
export let label: string;
// Called with the file contents as text
Expand Down
2 changes: 1 addition & 1 deletion src/lib/common/LineMeasureController.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import length from "@turf/length";
import { colors } from "colors";
import DraggablePin from "lib/common/DraggablePin.svelte";
import { SecondaryButton } from "lib/govuk";
import { SecondaryButton } from "govuk-svelte";
import { emptyGeojson, layerId } from "lib/maplibre";
import { LngLat, MapMouseEvent } from "maplibre-gl";
import { map } from "stores";
Expand Down
2 changes: 1 addition & 1 deletion src/lib/common/LoggedIn.svelte
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script lang="ts">
import Cookies from "js-cookie";
import { Alpha, appVersion } from "lib/common";
import { ErrorMessage } from "lib/govuk";
import { ErrorMessage } from "govuk-svelte";
let email = Cookies.get("email");
</script>
Expand Down
2 changes: 1 addition & 1 deletion src/lib/common/Modal.svelte
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script lang="ts">
import { SecondaryButton } from "lib/govuk";
import { SecondaryButton } from "govuk-svelte";
export let title: string;
export let open = false;
Expand Down
2 changes: 1 addition & 1 deletion src/lib/common/StreetViewTool.svelte
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script lang="ts">
import { colors } from "colors";
import { CollapsibleCard } from "lib/common";
import { Radio, SecondaryButton } from "lib/govuk";
import { Radio, SecondaryButton } from "govuk-svelte";
import { getRoadLayerHelpers, LayerHelper } from "lib/maplibre";
import type { MapMouseEvent } from "maplibre-gl";
import { map, userSettings } from "stores";
Expand Down
2 changes: 1 addition & 1 deletion src/lib/common/ZoomOutMap.svelte
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<script lang="ts">
import type { GeoJSON } from "geojson";
import { SecondaryButton } from "lib/govuk";
import { SecondaryButton } from "govuk-svelte";
import { bbox } from "lib/maplibre";
import { map } from "stores";
import icon from "../../../assets/zoom_out_map.svg";
Expand Down
2 changes: 1 addition & 1 deletion src/lib/critical_entry/Form.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
Select,
TextArea,
WarningButton,
} from "lib/govuk";
} from "govuk-svelte";
import { setPrecision } from "lib/maplibre";
import type { LngLat } from "maplibre-gl";
import LocationDescription from "./LocationDescription.svelte";
Expand Down
2 changes: 1 addition & 1 deletion src/lib/critical_entry/LocationDescription.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
CheckboxGroup,
ErrorMessage,
FormElement,
} from "lib/govuk";
} from "govuk-svelte";
import type { LngLat } from "maplibre-gl";
export let locationDescription: string;
Expand Down
2 changes: 1 addition & 1 deletion src/lib/draw/EditGeometryMode.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
polygonTool,
routeTool,
} from "lib/draw/stores";
import { ButtonGroup, DefaultButton, SecondaryButton } from "lib/govuk";
import { ButtonGroup, DefaultButton, SecondaryButton } from "govuk-svelte";
import type { FeatureWithProps } from "lib/maplibre";
import { interventionName } from "lib/sidebar/scheme_data";
import { schema } from "stores";
Expand Down
2 changes: 1 addition & 1 deletion src/lib/draw/StreetViewMode.svelte
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script lang="ts">
import { StreetViewHelp, StreetViewTool } from "lib/common";
import { mode } from "lib/draw/stores";
import { DefaultButton, Radio } from "lib/govuk";
import { DefaultButton, Radio } from "govuk-svelte";
import { userSettings } from "stores";
let enabled = true;
Expand Down
Loading

0 comments on commit ec58ca1

Please sign in to comment.