Skip to content

Commit

Permalink
Applying govuk controls in a few more places
Browse files Browse the repository at this point in the history
  • Loading branch information
dabreegster committed Jul 14, 2023
1 parent 2bdad6d commit 4b16635
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 22 deletions.
10 changes: 8 additions & 2 deletions src/lib/common/ConfirmationModal.svelte
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
<script lang="ts">
import { createEventDispatcher } from "svelte";
import SecondaryButton from "../govuk/SecondaryButton.svelte";
import WarningButton from "../govuk/WarningButton.svelte";
import Modal from "./Modal.svelte";
const dispatch = createEventDispatcher();
Expand Down Expand Up @@ -28,6 +30,10 @@
bind:canCloseByClickingBackground
>
<p>{message}</p>
<button type="button" on:click={onClickConfirm}>{confirmButtonText}</button>
<button type="button" on:click={onClickCancel}>{cancelButtonText}</button>
<div class="govuk-button-group">
<WarningButton on:click={onClickConfirm}>{confirmButtonText}</WarningButton>
<SecondaryButton on:click={onClickCancel}
>{cancelButtonText}</SecondaryButton
>
</div>
</Modal>
28 changes: 11 additions & 17 deletions src/lib/draw/StreetViewMode.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import { currentMode, map, userSettings } from "../../stores";
import type { Mode } from "../../types";
import CollapsibleCard from "../common/CollapsibleCard.svelte";
import Radio from "../govuk/Radio.svelte";
import type { EventHandler } from "./event_handler";
export let eventHandler: EventHandler;
Expand Down Expand Up @@ -43,23 +44,16 @@
</script>

{#if $currentMode == thisMode}
<label>
<input
type="radio"
bind:group={$userSettings.streetViewImagery}
value="google"
/>
Google Street View
</label>
<br />
<label>
<input
type="radio"
bind:group={$userSettings.streetViewImagery}
value="bing"
/>
Bing Streetside
</label>
<Radio
legend="Source"
id="streetViewImagery"
choices={[
["google", "Google Street View"],
["bing", "Bing Streetside"],
]}
inlineSmall
bind:value={$userSettings.streetViewImagery}
/>

<CollapsibleCard label="Help">
<ul>
Expand Down
2 changes: 0 additions & 2 deletions src/lib/sidebar/EntireScheme.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -175,8 +175,6 @@
Export to GeoJSON
</SecondaryButton>

<hr />

<div style="display: flex; justify-content: space-between">
<p>{$gjScheme.features.length} {schemaPluralNoun(schema)}</p>
<p>{$gjScheme.features.length} objects</p>
Expand Down
2 changes: 1 addition & 1 deletion src/pages/App.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@
<ZoomOutMap {boundaryGeojson} />
</div>
<EntireScheme {authorityName} {schema} />
<br />
<hr />
<InterventionList {schema} />
<hr />
<ContextualLayers />
Expand Down

0 comments on commit 4b16635

Please sign in to comment.