@madgex/design-system 3.2.3 → 3.2.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/coverage/cobertura-coverage.xml +1 -1
- package/coverage/components/accordion/accordion.js.html +2 -2
- package/coverage/components/accordion/index.html +1 -1
- package/coverage/components/button/button.js.html +1 -1
- package/coverage/components/button/index.html +1 -1
- package/coverage/components/inputs/combobox/combobox.js.html +1 -1
- package/coverage/components/inputs/combobox/index.html +1 -1
- package/coverage/components/inputs/combobox/vue-components/Combobox.vue.html +1 -1
- package/coverage/components/inputs/combobox/vue-components/ListBoxOption.vue.html +1 -1
- package/coverage/components/inputs/combobox/vue-components/index.html +1 -1
- package/coverage/components/inputs/file-upload/file-upload.js.html +1 -1
- package/coverage/components/inputs/file-upload/index.html +1 -1
- package/coverage/components/inputs/textarea/character-count.js.html +1 -1
- package/coverage/components/inputs/textarea/index.html +1 -1
- package/coverage/components/modal/index.html +1 -1
- package/coverage/components/modal/modal.js.html +1 -1
- package/coverage/components/notification/index.html +1 -1
- package/coverage/components/notification/notification.js.html +1 -1
- package/coverage/components/popover/index.html +1 -1
- package/coverage/components/popover/popover.js.html +1 -1
- package/coverage/components/switch-state/index.html +1 -1
- package/coverage/components/switch-state/switch-state.js.html +1 -1
- package/coverage/components/tabs/index.html +1 -1
- package/coverage/components/tabs/tabs.js.html +1 -1
- package/coverage/index.html +1 -1
- package/coverage/js/common.js.html +1 -1
- package/coverage/js/fractal-scripts/combobox.js.html +1 -1
- package/coverage/js/fractal-scripts/index.html +1 -1
- package/coverage/js/fractal-scripts/notification.js.html +1 -1
- package/coverage/js/fractal-scripts/switch-state.js.html +1 -1
- package/coverage/js/index-fractal.js.html +1 -1
- package/coverage/js/index-polyfills.js.html +1 -1
- package/coverage/js/index-vue.js.html +1 -1
- package/coverage/js/index.html +1 -1
- package/coverage/js/index.js.html +1 -1
- package/coverage/js/polyfills/arrayPrototypeFind.js.html +1 -1
- package/coverage/js/polyfills/closest.js.html +1 -1
- package/coverage/js/polyfills/index.html +1 -1
- package/coverage/js/polyfills/objectAssign.js.html +1 -1
- package/coverage/js/polyfills/remove.js.html +1 -1
- package/coverage/tokens/_config.js.html +1 -1
- package/coverage/tokens/index.html +1 -1
- package/dist/_tokens/css/_tokens.css +1 -1
- package/dist/_tokens/js/_tokens-module.js +1 -1
- package/dist/_tokens/scss/_tokens.scss +1 -1
- package/dist/js/index.js +1 -1
- package/package.json +1 -1
- package/src/components/accordion/accordion.js +1 -1
- package/src/components/inputs/checkbox-list/README.md +1 -1
- package/src/components/inputs/checkbox-list/_template.njk +5 -0
- package/src/components/inputs/checkbox-list/checkbox-list.config.js +0 -1
package/package.json
CHANGED
|
@@ -94,7 +94,7 @@ const accordion = {
|
|
|
94
94
|
// can't use multiple arguments in classList.add() due to IE
|
|
95
95
|
accordionTriggerButton.classList.add('mds-button');
|
|
96
96
|
accordionTriggerButton.classList.add('mds-button--plain');
|
|
97
|
-
accordionTriggerButton.classList.add('mds-padding-b0');
|
|
97
|
+
accordionTriggerButton.classList.add('mds-padding-x-b0');
|
|
98
98
|
accordionTriggerButton.setAttribute('aria-expanded', false);
|
|
99
99
|
if (accordionTriggerSpan) {
|
|
100
100
|
accordionTriggerButton.appendChild(accordionTriggerSpan);
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
- `classes`: add extra classes to the fieldgroup - **optional**
|
|
12
12
|
- `describedBy`: adding aria-describeby to the fieldset (if multiple checkboxes) or the input field if only one checkbox - **optional**
|
|
13
13
|
- `options`: This is an array of objects containing the parameters for each option: `labelText`, `value`, `id`, `classes`
|
|
14
|
-
- `selectedOptions`: Preselected checkboxes - Array or comma-
|
|
14
|
+
- `selectedOptions`: Preselected checkboxes - Array or comma-separated string **optional**
|
|
15
15
|
|
|
16
16
|
**Note:** `id` in `options` is optional. If you don't specify one, an id will be created for you using the name/id of the field and the value of the option.
|
|
17
17
|
|
|
@@ -23,6 +23,11 @@
|
|
|
23
23
|
{%- set accordionIsExpanded = false -%}
|
|
24
24
|
{% if checkboxParams.selectedOptions %}
|
|
25
25
|
{% set selectedOptions = checkboxParams.selectedOptions %}
|
|
26
|
+
{# check if `selectedOptions` is an array or not - if it isn't, change it into one #}
|
|
27
|
+
{# didn't find any other way than to check the first character of the JSON.stringify version of the parameter #}
|
|
28
|
+
{% if selectedOptions | dump | first != '[' %}
|
|
29
|
+
{% set selectedOptions = [selectedOptions] %}
|
|
30
|
+
{% endif %}
|
|
26
31
|
{% for selectedOption in selectedOptions %}
|
|
27
32
|
{% if selectedOption == option.value %}
|
|
28
33
|
{%- set isSelected = true -%}
|