diff --git a/src/components/checkboxes/_macro.njk b/src/components/checkboxes/_macro.njk
index ea89d65d5b..05bb0e3ff9 100644
--- a/src/components/checkboxes/_macro.njk
+++ b/src/components/checkboxes/_macro.njk
@@ -4,14 +4,14 @@
{% call onsField({
"id": params.id,
- "legend": params.legend,
"description": params.description,
"classes": params.classes,
"mutuallyExclusive": params.mutuallyExclusive,
- "legendClasses": params.legendClasses
+ "legendClasses": params.legendClasses,
+ "noField": params.noField
}) %}
-
{{ params.checkboxesLabel }}
-
+ {{ params.checkboxesLabel }}
+
{% for checkbox in params.checkboxes %}
{% set labelHTML = checkbox.label.text %}
{% if params.mutuallyExclusive %}
@@ -54,6 +54,6 @@
{% endif %}
{% endfor %}
-
+
{% endcall %}
{% endmacro %}
diff --git a/src/components/field/_field.scss b/src/components/field/_field.scss
index 656d16b2a0..534f7c6f39 100644
--- a/src/components/field/_field.scss
+++ b/src/components/field/_field.scss
@@ -20,13 +20,16 @@
margin-top: -1rem;
}
+ &__items {
+ display: block;
+ }
+
&__item {
display: inline-block;
position: relative;
}
- & > &,
- &__items > & {
+ *:not(.field__group) > & {
&__item {
margin: 0 0 0.5rem;
width: 100%;
diff --git a/src/components/field/_macro.njk b/src/components/field/_macro.njk
index 6958000e36..55a36e36d6 100644
--- a/src/components/field/_macro.njk
+++ b/src/components/field/_macro.njk
@@ -43,16 +43,17 @@
{% endif %}
{% else %}
+ {% set tag = "div" if params.mutuallyExclusive else "p" %}
{% if not params.noField %}
-
+ <{{ tag }}{% if params.id %} id="{{ params.id }}"{% endif %} class="field{% if params.mutuallyExclusive %} js-mutually-exclusive{% endif %}{% if params.classes %} {{ params.classes }}{% endif %}">
{% endif %}
{% if params.description %}
-
{{ params.description }}
+ {{ params.description }}
{% endif %}
{{ caller() }}
{{ mutuallyExclusive | safe }}
{% if not params.noField %}
-
+ {{ tag }}>
{% endif %}
{% endif %}
{% endmacro %}