@ons/design-system 67.2.0 → 68.0.1
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/README.md +6 -0
- package/components/access-code/_macro.njk +1 -1
- package/components/access-code/_macro.spec.js +2 -10
- package/components/access-code/access-code.dom.js +1 -1
- package/components/access-code/access-code.spec.js +2 -2
- package/components/access-code/example-access-code-error.njk +9 -14
- package/components/access-code/example-access-code.njk +3 -5
- package/components/accordion/accordion.js +4 -4
- package/components/address-input/_macro.spec.js +3 -15
- package/components/address-input/autosuggest.address.dom.js +1 -1
- package/components/address-input/autosuggest.address.js +3 -2
- package/components/address-input/autosuggest.address.setter.js +3 -3
- package/components/address-input/autosuggest.address.spec.js +66 -69
- package/components/address-output/_macro.spec.js +6 -30
- package/components/autosuggest/_autosuggest.scss +1 -1
- package/components/autosuggest/autosuggest.dom.js +1 -1
- package/components/autosuggest/autosuggest.helpers.js +1 -1
- package/components/back-to-top/_back-to-top.scss +34 -0
- package/components/back-to-top/_macro.njk +17 -0
- package/components/back-to-top/_macro.spec.js +60 -0
- package/components/back-to-top/back-to-top.dom.js +12 -0
- package/components/back-to-top/back-to-top.js +58 -0
- package/components/back-to-top/back-to-top.spec.js +117 -0
- package/components/back-to-top/example-back-to-top.njk +37 -0
- package/components/back-to-top/example-full-page-back-to-top.njk +192 -0
- package/components/browser-banner/_macro.spec.js +4 -12
- package/components/button/_macro.njk +6 -6
- package/components/button/_macro.spec.js +1 -5
- package/components/button/button.js +7 -8
- package/components/button/button.spec.js +17 -39
- package/components/call-to-action/_macro.spec.js +2 -6
- package/components/card/_macro.njk +25 -25
- package/components/card/_macro.spec.js +10 -34
- package/components/char-check-limit/_macro.njk +1 -1
- package/components/char-check-limit/_macro.spec.js +3 -7
- package/components/char-check-limit/character-check.spec.js +24 -20
- package/components/checkboxes/_checkbox-macro.njk +1 -1
- package/components/checkboxes/_checkbox.scss +0 -3
- package/components/checkboxes/_macro.spec.js +1 -5
- package/components/checkboxes/checkbox-with-autoselect.js +3 -3
- package/components/checkboxes/checkbox-with-fieldset.js +2 -2
- package/components/checkboxes/checkboxes-with-reveal.js +4 -2
- package/components/checkboxes/checkboxes.dom.js +2 -2
- package/components/checkboxes/checkboxes.spec.js +13 -13
- package/components/content-pagination/_macro.spec.js +2 -2
- package/components/cookies-banner/cookies-banner.dom.js +1 -1
- package/components/cookies-banner/cookies-banner.js +1 -1
- package/components/cookies-banner/cookies-banner.spec.js +7 -7
- package/components/date-input/_macro.njk +71 -69
- package/components/date-input/_macro.spec.js +20 -5
- package/components/date-input/example-date-input-double-field.njk +27 -0
- package/components/date-input/example-date-input-single-field.njk +18 -0
- package/components/details/details.spec.js +12 -12
- package/components/details/example-details-with-warning.njk +5 -7
- package/components/document-list/_macro.spec.js +9 -27
- package/components/document-list/document-list.scss +1 -1
- package/components/document-list/example-document-list-downloads.njk +3 -3
- package/components/document-list/example-document-list-search-result-featured.njk +1 -1
- package/components/document-list/example-document-list-search-results.njk +3 -3
- package/components/download-resources/download-resources.js +54 -54
- package/components/download-resources/download-resources.spec.js +3 -1
- package/components/duration/_macro.njk +52 -48
- package/components/duration/_macro.spec.js +112 -4
- package/components/duration/example-duration-error-for-single-field.njk +1 -1
- package/components/duration/example-duration-single-field.njk +24 -0
- package/components/error/_macro.njk +1 -1
- package/components/error/_macro.spec.js +2 -6
- package/components/feedback/_macro.njk +1 -1
- package/components/feedback/_macro.spec.js +4 -20
- package/components/field/_field-group.scss +3 -4
- package/components/field/_macro.spec.js +1 -3
- package/components/fieldset/_fieldset.scss +1 -2
- package/components/fieldset/_macro.spec.js +3 -9
- package/components/footer/_footer.scss +8 -0
- package/components/footer/_macro.njk +8 -7
- package/components/footer/_macro.spec.js +14 -2
- package/components/header/_macro.njk +1 -1
- package/components/header/_macro.spec.js +1 -1
- package/components/helpers/grid.njk +15 -15
- package/components/icon/_macro.njk +17 -13
- package/components/icon/_macro.spec.js +8 -16
- package/components/image/_macro.spec.js +1 -5
- package/components/input/_macro.njk +22 -23
- package/components/input/_macro.spec.js +1 -1
- package/components/input/character-check.dom.js +1 -1
- package/components/input/input.spec.js +1 -4
- package/components/label/_label.scss +1 -0
- package/components/label/_macro.njk +3 -3
- package/components/label/_macro.spec.js +4 -13
- package/components/list/_macro.spec.js +4 -12
- package/components/message/_macro.njk +17 -17
- package/components/message/_macro.spec.js +9 -33
- package/components/message-list/_macro.spec.js +7 -39
- package/components/metadata/_macro.njk +10 -10
- package/components/modal/_macro.spec.js +3 -9
- package/components/modal/modal.dom.js +1 -1
- package/components/modal/modal.spec.js +5 -5
- package/components/multiple-input-fields/_macro.njk +49 -0
- package/components/mutually-exclusive/_macro.spec.js +2 -10
- package/components/mutually-exclusive/mutually-exclusive.checkboxes.spec.js +26 -26
- package/components/mutually-exclusive/mutually-exclusive.date.spec.js +128 -14
- package/components/mutually-exclusive/mutually-exclusive.dom.js +1 -1
- package/components/mutually-exclusive/mutually-exclusive.duration.spec.js +129 -8
- package/components/mutually-exclusive/mutually-exclusive.email.spec.js +7 -7
- package/components/mutually-exclusive/mutually-exclusive.js +13 -13
- package/components/mutually-exclusive/mutually-exclusive.multiple-options.checkboxes.spec.js +29 -29
- package/components/mutually-exclusive/mutually-exclusive.number.spec.js +7 -7
- package/components/mutually-exclusive/mutually-exclusive.textarea.spec.js +8 -8
- package/components/navigation/navigation.spec.js +0 -2
- package/components/pagination/_macro.spec.js +11 -53
- package/components/panel/_macro.njk +17 -17
- package/components/panel/_macro.spec.js +25 -25
- package/components/panel/_panel.scss +10 -9
- package/components/panel/example-panel-bare.njk +3 -4
- package/components/panel/example-panel-with-announcement.njk +6 -10
- package/components/panel/example-panel-with-error-summary.njk +2 -2
- package/components/panel/example-panel-with-information.njk +0 -1
- package/components/panel/example-panel-with-success-message.njk +1 -1
- package/components/panel/example-panel-with-warning.njk +2 -3
- package/components/password/password.dom.js +1 -1
- package/components/phase-banner/_macro.spec.js +3 -9
- package/components/question/_macro.njk +1 -1
- package/components/question/_macro.spec.js +5 -19
- package/components/question/_question.scss +1 -4
- package/components/question/example-question-interviewer-note.njk +1 -1
- package/components/quote/_macro.spec.js +2 -10
- package/components/radios/clear-radios.js +3 -3
- package/components/radios/radio-with-fieldset.js +4 -4
- package/components/radios/radios.dom.js +1 -1
- package/components/radios/radios.spec.js +26 -26
- package/components/related-content/_macro.spec.js +2 -4
- package/components/related-content/_section-macro.spec.js +2 -8
- package/components/relationships/example-relationships-error.njk +16 -18
- package/components/relationships/relationships.dom.js +1 -1
- package/components/relationships/relationships.js +2 -2
- package/components/reply/_macro.spec.js +3 -3
- package/components/reply/reply.dom.js +1 -1
- package/components/reply/reply.spec.js +3 -3
- package/components/section-navigation/_macro.njk +12 -12
- package/components/section-navigation/_macro.spec.js +13 -21
- package/components/select/_macro.spec.js +6 -6
- package/components/share-page/_macro.spec.js +6 -14
- package/components/skip-to-content/_macro.spec.js +3 -11
- package/components/skip-to-content/skip-to-content.dom.js +1 -1
- package/components/skip-to-content/skip-to-content.js +1 -1
- package/components/skip-to-content/skip-to-content.spec.js +2 -2
- package/components/status/_macro.njk +2 -2
- package/components/status/_macro.spec.js +5 -9
- package/components/status/example-status-dead.njk +1 -1
- package/components/status/example-status-error.njk +1 -1
- package/components/status/example-status-pending.njk +1 -1
- package/components/status/example-status-small.njk +1 -1
- package/components/status/example-status-success.njk +1 -1
- package/components/summary/_macro.njk +7 -8
- package/components/summary/_macro.spec.js +27 -9
- package/components/table/_macro.spec.js +6 -10
- package/components/table/scrollable-table.dom.js +1 -1
- package/components/table/scrollable-table.js +1 -1
- package/components/table/sortable-table.js +4 -4
- package/components/table/table.spec.js +21 -17
- package/components/table-of-contents/_macro.njk +31 -31
- package/components/table-of-contents/_macro.spec.js +3 -11
- package/components/table-of-contents/toc.dom.js +1 -1
- package/components/table-of-contents/toc.spec.js +36 -32
- package/components/tabs/example-tabs-details.njk +1 -1
- package/components/tabs/tabs.dom.js +1 -1
- package/components/tabs/tabs.js +8 -8
- package/components/text-indent/_macro.spec.js +2 -6
- package/components/textarea/textarea.dom.js +1 -1
- package/components/textarea/textarea.spec.js +8 -8
- package/components/timeout-modal/_macro.spec.js +1 -3
- package/components/timeout-modal/timeout-modal.dom.js +1 -1
- package/components/timeout-modal/timeout-modal.spec.js +10 -10
- package/components/timeout-panel/_macro.njk +16 -17
- package/components/timeout-panel/_macro.spec.js +1 -1
- package/components/timeout-panel/timeout-panel.dom.js +1 -1
- package/components/timeout-panel/timeout-panel.spec.js +8 -8
- package/components/video/_macro.spec.js +1 -5
- package/components/video/video.dom.js +1 -1
- package/components/video/video.spec.js +16 -12
- package/css/main.css +1 -1
- package/favicons/safari-pinned-tab.svg +23 -23
- package/js/analytics.js +15 -14
- package/js/cookies-settings.dom.js +1 -1
- package/js/cookies-settings.spec.js +19 -19
- package/js/domready.js +1 -1
- package/js/fetch.js +1 -1
- package/js/inpagelink.js +3 -3
- package/js/main.js +1 -0
- package/js/print-button.js +1 -1
- package/js/timeout.js +1 -1
- package/package.json +2 -1
- package/scripts/main.es5.js +1 -1
- package/scripts/main.js +1 -1
- package/scss/base/_typography.scss +8 -2
- package/scss/main.scss +1 -0
- package/scss/overrides/hcm.scss +8 -1
- package/scss/vars/_colors.scss +2 -1
- package/components/date-field-input/_macro.njk +0 -86
|
@@ -23,11 +23,17 @@ h5,
|
|
|
23
23
|
h6 {
|
|
24
24
|
line-height: 1.2;
|
|
25
25
|
margin: 0 0 1rem;
|
|
26
|
-
|
|
27
|
-
|
|
26
|
+
strong {
|
|
27
|
+
@extend .ons-highlight;
|
|
28
28
|
}
|
|
29
29
|
}
|
|
30
30
|
|
|
31
|
+
mark {
|
|
32
|
+
@extend .ons-highlight;
|
|
33
|
+
|
|
34
|
+
font-weight: $font-weight-bold;
|
|
35
|
+
}
|
|
36
|
+
|
|
31
37
|
code {
|
|
32
38
|
font-size: 0.8rem;
|
|
33
39
|
}
|
package/scss/main.scss
CHANGED
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
@import '../components/access-code/access-code';
|
|
7
7
|
@import '../components/address-output/address-output';
|
|
8
8
|
@import '../components/autosuggest/autosuggest';
|
|
9
|
+
@import '../components/back-to-top/back-to-top';
|
|
9
10
|
@import '../components/breadcrumbs/breadcrumbs';
|
|
10
11
|
@import '../components/browser-banner/browser-banner';
|
|
11
12
|
@import '../components/button/button';
|
package/scss/overrides/hcm.scss
CHANGED
|
@@ -193,7 +193,14 @@
|
|
|
193
193
|
}
|
|
194
194
|
|
|
195
195
|
// Highlighting
|
|
196
|
-
h1
|
|
196
|
+
h1 strong,
|
|
197
|
+
h2 strong,
|
|
198
|
+
h3 strong,
|
|
199
|
+
h4 strong,
|
|
200
|
+
h5 strong,
|
|
201
|
+
h6 strong,
|
|
202
|
+
mark,
|
|
203
|
+
.ons-fieldset__legend-title strong,
|
|
197
204
|
.ons-highlight {
|
|
198
205
|
background-color: mark;
|
|
199
206
|
color: marktext;
|
package/scss/vars/_colors.scss
CHANGED
|
@@ -102,7 +102,8 @@
|
|
|
102
102
|
--ons-color-borders-document-image-focus: var(--ons-color-black);
|
|
103
103
|
|
|
104
104
|
// Placeholders
|
|
105
|
-
--ons-color-placeholder: var(--ons-color-grey-
|
|
105
|
+
--ons-color-text-placeholder: var(--ons-color-grey-75);
|
|
106
|
+
--ons-color-image-placeholder: var(--ons-color-grey-15);
|
|
106
107
|
|
|
107
108
|
// Form elements
|
|
108
109
|
--ons-color-button: var(--ons-color-leaf-green);
|
|
@@ -1,86 +0,0 @@
|
|
|
1
|
-
{% from "components/mutually-exclusive/_macro.njk" import onsMutuallyExclusive %}
|
|
2
|
-
{% from "components/fieldset/_macro.njk" import onsFieldset %}
|
|
3
|
-
{% from "components/input/_macro.njk" import onsInput %}
|
|
4
|
-
{% from "components/error/_macro.njk" import onsError %}
|
|
5
|
-
|
|
6
|
-
{% macro onsDateFieldInput(params) %}
|
|
7
|
-
{% set fields %}
|
|
8
|
-
{% for field in params.fields %}
|
|
9
|
-
{{
|
|
10
|
-
onsInput({
|
|
11
|
-
"id": field.id,
|
|
12
|
-
"classes": field.classes,
|
|
13
|
-
"width": field.width,
|
|
14
|
-
"type": "number",
|
|
15
|
-
"name": field.name,
|
|
16
|
-
"value": field.value,
|
|
17
|
-
"min": field.min,
|
|
18
|
-
"max": field.max,
|
|
19
|
-
"maxLength": field.maxLength,
|
|
20
|
-
"suffix": field.suffix,
|
|
21
|
-
"label": field.label,
|
|
22
|
-
"attributes": field.attributes,
|
|
23
|
-
"error": field.error,
|
|
24
|
-
"fieldId": field.fieldId
|
|
25
|
-
})
|
|
26
|
-
}}
|
|
27
|
-
{% endfor %}
|
|
28
|
-
{% endset %}
|
|
29
|
-
|
|
30
|
-
{% if numberOfFields > 1 %}
|
|
31
|
-
{% set fields %}
|
|
32
|
-
<div class="ons-field-group">
|
|
33
|
-
{{ fields | safe }}
|
|
34
|
-
</div>
|
|
35
|
-
{% endset %}
|
|
36
|
-
{% endif %}
|
|
37
|
-
|
|
38
|
-
{% if params.mutuallyExclusive %}
|
|
39
|
-
{% set mutuallyExclusive = params.mutuallyExclusive | setAttributes({
|
|
40
|
-
"id": params.id,
|
|
41
|
-
"legend": params.legendOrLabel,
|
|
42
|
-
"legendClasses": params.legendClasses,
|
|
43
|
-
"description": params.description,
|
|
44
|
-
"error": params.error,
|
|
45
|
-
"classes": params.classes,
|
|
46
|
-
"legendIsQuestionTitle": params.legendIsQuestionTitle,
|
|
47
|
-
"dontWrap": params.dontWrap,
|
|
48
|
-
"exclusiveOptions": params.mutuallyExclusive.exclusiveOptions,
|
|
49
|
-
"or": params.mutuallyExclusive.or,
|
|
50
|
-
"deselectMessage": params.mutuallyExclusive.deselectMessage,
|
|
51
|
-
"deselectGroupAdjective": params.mutuallyExclusive.deselectGroupAdjective,
|
|
52
|
-
"deselectExclusiveOptionAdjective": params.mutuallyExclusive.deselectExclusiveOptionAdjective
|
|
53
|
-
}) %}
|
|
54
|
-
|
|
55
|
-
{% call onsMutuallyExclusive(mutuallyExclusive) %}
|
|
56
|
-
<div class="ons-field-group">
|
|
57
|
-
{{ fields | safe }}
|
|
58
|
-
</div>
|
|
59
|
-
{% endcall %}
|
|
60
|
-
{% elif params.numberOfFields > 1 %}
|
|
61
|
-
{% call onsFieldset({
|
|
62
|
-
"id": params.id,
|
|
63
|
-
"legend": params.legendOrLabel,
|
|
64
|
-
"classes": params.classes,
|
|
65
|
-
"description": params.description,
|
|
66
|
-
"legendClasses": params.legendClasses,
|
|
67
|
-
"error": params.error,
|
|
68
|
-
"legendIsQuestionTitle": params.legendIsQuestionTitle,
|
|
69
|
-
"dontWrap": params.dontWrap
|
|
70
|
-
}) %}
|
|
71
|
-
<div class="ons-field-group">
|
|
72
|
-
{{ fields | safe }}
|
|
73
|
-
</div>
|
|
74
|
-
{% endcall %}
|
|
75
|
-
{% elif params.numberOfFields == 1 %}
|
|
76
|
-
{% if params.error %}
|
|
77
|
-
{% call onsError(params.error) %}
|
|
78
|
-
{{ fields | safe }}
|
|
79
|
-
{% endcall %}
|
|
80
|
-
{% else %}
|
|
81
|
-
{{ fields | safe }}
|
|
82
|
-
{% endif %}
|
|
83
|
-
{% else %}
|
|
84
|
-
{{ fields | safe }}
|
|
85
|
-
{% endif %}
|
|
86
|
-
{% endmacro %}
|