From 34d989246bef271085ada44627e5252d8a977404 Mon Sep 17 00:00:00 2001 From: Mohammed Khalid Date: Fri, 21 Nov 2025 14:42:06 +0000 Subject: [PATCH] refactor: Add location fields styling and update application stylesheet --- src/client/stylesheets/_location-fields.scss | 5 +++++ src/client/stylesheets/application.scss | 1 + src/client/stylesheets/shared.scss | 4 ---- .../engine/views/components/_location-field-base.html | 2 +- 4 files changed, 7 insertions(+), 5 deletions(-) create mode 100644 src/client/stylesheets/_location-fields.scss diff --git a/src/client/stylesheets/_location-fields.scss b/src/client/stylesheets/_location-fields.scss new file mode 100644 index 000000000..5f2d70e23 --- /dev/null +++ b/src/client/stylesheets/_location-fields.scss @@ -0,0 +1,5 @@ +@use "govuk-frontend" as *; + +.govuk-form-group .app-location-field-inputs .govuk-form-group { + margin-bottom: 0; +} diff --git a/src/client/stylesheets/application.scss b/src/client/stylesheets/application.scss index 349c344c2..2aa7b70f1 100644 --- a/src/client/stylesheets/application.scss +++ b/src/client/stylesheets/application.scss @@ -2,6 +2,7 @@ @use "shared"; @use "code"; @use "tag-env"; +@use "location-fields"; // An example of some user-supplied styling // Not great practice but it illustrates the point diff --git a/src/client/stylesheets/shared.scss b/src/client/stylesheets/shared.scss index 5501a8f63..cb7277959 100644 --- a/src/client/stylesheets/shared.scss +++ b/src/client/stylesheets/shared.scss @@ -31,7 +31,3 @@ content: none; } } - -.govuk-form-group .govuk-form-group { - margin-bottom: 0; -} diff --git a/src/server/plugins/engine/views/components/_location-field-base.html b/src/server/plugins/engine/views/components/_location-field-base.html index 4a73aa706..0cd96cddb 100644 --- a/src/server/plugins/engine/views/components/_location-field-base.html +++ b/src/server/plugins/engine/views/components/_location-field-base.html @@ -33,7 +33,7 @@ }) }} {% endif %} -
+
{% for item in component.model.items %}
{% set inputParams = {