Skip to content

Commit

Permalink
Move two more components to the shared repo
Browse files Browse the repository at this point in the history
  • Loading branch information
dabreegster committed Feb 26, 2024
1 parent ec58ca1 commit 176c662
Show file tree
Hide file tree
Showing 16 changed files with 17 additions and 69 deletions.
2 changes: 1 addition & 1 deletion package-lock.json

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

2 changes: 1 addition & 1 deletion src/lib/browse/Filters.svelte
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script lang="ts">
import { CollapsibleCard } from "lib/common";
import {
Checkbox,
CollapsibleCard,
CheckboxGroup,
FormElement,
SecondaryButton,
Expand Down
4 changes: 2 additions & 2 deletions 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 "govuk-svelte";
import { Legend } from "lib/common";
import { CollapsibleCard, Select } from "govuk-svelte";
import { colorInterventionsBySchema, schemaLegend } from "schemas";
import { map } from "stores";
import { styleByCurrentMilestone, styleByFundingProgramme } from "./colors";
Expand Down
3 changes: 1 addition & 2 deletions src/lib/browse/LayerControls.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,10 @@
import {
appVersion,
BaselayerSwitcher,
CollapsibleCard,
LineMeasureController,
StreetViewTool,
} from "lib/common";
import { CheckboxGroup } from "govuk-svelte";
import { CollapsibleCard, CheckboxGroup } from "govuk-svelte";
import { layerId } from "lib/maplibre";
import { FillLayer, GeoJSON } from "svelte-maplibre";
import CensusOutputAreaLayerControl from "./layers/areas/CensusOutputAreas.svelte";
Expand Down
3 changes: 1 addition & 2 deletions src/lib/browse/SchemeCard.svelte
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<script lang="ts">
import type { FeatureCollection } from "geojson";
import { CollapsibleCard } from "lib/common";
import { ButtonGroup, SecondaryButton } from "govuk-svelte";
import { CollapsibleCard, 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/lines/Gradients.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
Popup,
publicResourceBaseUrl,
} from "lib/common";
import { Checkbox } from "lib/govuk";
import { Checkbox } from "govuk-svelte";
import { layerId, makeColorRamp } from "lib/maplibre";
import {
hoverStateFilter,
Expand Down
3 changes: 2 additions & 1 deletion src/lib/browse/layers/points/CriticalIssues.svelte
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<script lang="ts">
import { CollapsibleCard, ColorLegend, Popup } from "lib/common";
import { ColorLegend, Popup } from "lib/common";
import {
CollapsibleCard,
Checkbox,
CheckboxGroup,
ErrorMessage,
Expand Down
13 changes: 0 additions & 13 deletions src/lib/common/CollapsibleCard.svelte

This file was deleted.

34 changes: 0 additions & 34 deletions src/lib/common/FileInput.svelte

This file was deleted.

3 changes: 1 addition & 2 deletions src/lib/common/LineMeasureController.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,12 @@
import length from "@turf/length";
import { colors } from "colors";
import DraggablePin from "lib/common/DraggablePin.svelte";
import { SecondaryButton } from "govuk-svelte";
import { CollapsibleCard, SecondaryButton } from "govuk-svelte";
import { emptyGeojson, layerId } from "lib/maplibre";
import { LngLat, MapMouseEvent } from "maplibre-gl";
import { map } from "stores";
import { onDestroy, onMount } from "svelte";
import { GeoJSON, LineLayer } from "svelte-maplibre";
import { CollapsibleCard } from ".";
let isInactive = true;
let waypoints: any[] = [];
Expand Down
3 changes: 1 addition & 2 deletions src/lib/common/StreetViewTool.svelte
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<script lang="ts">
import { colors } from "colors";
import { CollapsibleCard } from "lib/common";
import { Radio, SecondaryButton } from "govuk-svelte";
import { CollapsibleCard, 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: 0 additions & 2 deletions src/lib/common/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,8 @@ import authoritiesUrl from "../../../assets/authorities.geojson?url";

export { default as Alpha } from "./Alpha.svelte";
export { default as BaselayerSwitcher } from "./BaselayerSwitcher.svelte";
export { default as CollapsibleCard } from "./CollapsibleCard.svelte";
export { default as ColorLegend } from "./ColorLegend.svelte";
export { default as ExternalLink } from "./ExternalLink.svelte";
export { default as FileInput } from "./FileInput.svelte";
export { default as Geocoder } from "./Geocoder.svelte";
export { default as HelpButton } from "./HelpButton.svelte";
export { default as Layout } from "./Layout.svelte";
Expand Down
4 changes: 3 additions & 1 deletion src/lib/sidebar/FileManagement.svelte
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script lang="ts">
import { CollapsibleCard, FileInput, Modal } from "lib/common";
import { Modal } from "lib/common";
import {
gjSchemeCollection,
hideSchemes,
Expand All @@ -9,6 +9,8 @@
import {
ButtonGroup,
ErrorMessage,
CollapsibleCard,
FileInput,
SecondaryButton,
WarningButton,
} from "govuk-svelte";
Expand Down
3 changes: 1 addition & 2 deletions src/lib/sidebar/ListMode.svelte
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<script lang="ts">
import { FileInput } from "lib/common";
import { gjSchemeCollection } from "lib/draw/stores";
import { ErrorMessage, SecondaryButton } from "govuk-svelte";
import { ErrorMessage, FileInput, SecondaryButton } from "govuk-svelte";
import PerSchemeControls from "./PerSchemeControls.svelte";
import { addEmptyScheme, backfill } from "./scheme_data";
Expand Down
3 changes: 1 addition & 2 deletions src/pages/BrowseSchemes.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,14 @@
import { schemes, schemesGj } from "lib/browse/stores";
import {
appVersion,
FileInput,
Geocoder,
Layout,
LoggedIn,
MapLibreMap,
Modal,
ZoomOutMap,
} from "lib/common";
import { ErrorMessage, SecondaryButton } from "govuk-svelte";
import { ErrorMessage, FileInput, SecondaryButton } from "govuk-svelte";
import { mapStyle } from "stores";
import { onMount } from "svelte";
Expand Down
2 changes: 1 addition & 1 deletion src/pages/ChooseArea.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
DefaultButton,
ErrorMessage,
FormElement,
FileInput,
Radio,
SecondaryButton,
} from "govuk-svelte";
Expand All @@ -16,7 +17,6 @@
import { findSmallestAuthority, type AuthorityBoundaries } from "boundaries";
import {
appVersion,
FileInput,
getAuthoritiesGeoJson,
LoggedIn,
MapLibreMap,
Expand Down

0 comments on commit 176c662

Please sign in to comment.