@amsterdam/design-system-css 0.14.1 → 0.16.0
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/CHANGELOG.md +91 -0
- package/README.md +3 -1
- package/dist/accordion/accordion.css +1 -1
- package/dist/accordion/accordion.css.map +1 -1
- package/dist/action-group/action-group.css +1 -1
- package/dist/action-group/action-group.css.map +1 -1
- package/dist/alert/alert.css +1 -1
- package/dist/alert/alert.css.map +1 -1
- package/dist/aspect-ratio/aspect-ratio.css +1 -1
- package/dist/aspect-ratio/aspect-ratio.css.map +1 -1
- package/dist/avatar/avatar.css +1 -1
- package/dist/avatar/avatar.css.map +1 -1
- package/dist/badge/badge.css +1 -1
- package/dist/badge/badge.css.map +1 -1
- package/dist/blockquote/blockquote.css +1 -1
- package/dist/blockquote/blockquote.css.map +1 -1
- package/dist/breadcrumb/breadcrumb.css +1 -1
- package/dist/breadcrumb/breadcrumb.css.map +1 -1
- package/dist/breakout/breakout.css +1 -1
- package/dist/breakout/breakout.css.map +1 -1
- package/dist/button/button.css +1 -1
- package/dist/button/button.css.map +1 -1
- package/dist/card/card.css +1 -1
- package/dist/card/card.css.map +1 -1
- package/dist/character-count/character-count.css +1 -1
- package/dist/character-count/character-count.css.map +1 -1
- package/dist/checkbox/checkbox.css +1 -1
- package/dist/checkbox/checkbox.css.map +1 -1
- package/dist/column/column.css +1 -1
- package/dist/column/column.css.map +1 -1
- package/dist/date-input/date-input.css +1 -1
- package/dist/date-input/date-input.css.map +1 -1
- package/dist/description-list/description-list.css +1 -1
- package/dist/description-list/description-list.css.map +1 -1
- package/dist/dialog/dialog.css +1 -1
- package/dist/dialog/dialog.css.map +1 -1
- package/dist/error-message/error-message.css +1 -1
- package/dist/error-message/error-message.css.map +1 -1
- package/dist/field-set/field-set.css +1 -1
- package/dist/field-set/field-set.css.map +1 -1
- package/dist/figure/figure.css +1 -1
- package/dist/figure/figure.css.map +1 -1
- package/dist/file-input/file-input.css +1 -1
- package/dist/file-input/file-input.css.map +1 -1
- package/dist/file-list/file-list.css +1 -1
- package/dist/file-list/file-list.css.map +1 -1
- package/dist/gap/gap.css +1 -1
- package/dist/gap/gap.css.map +1 -1
- package/dist/grid/grid.css +1 -1
- package/dist/grid/grid.css.map +1 -1
- package/dist/heading/heading.css +1 -1
- package/dist/heading/heading.css.map +1 -1
- package/dist/icon/icon.css +1 -1
- package/dist/icon/icon.css.map +1 -1
- package/dist/icon-button/icon-button.css +1 -1
- package/dist/icon-button/icon-button.css.map +1 -1
- package/dist/image-slider/image-slider.css +1 -1
- package/dist/image-slider/image-slider.css.map +1 -1
- package/dist/index.css +1 -1
- package/dist/index.css.map +1 -1
- package/dist/invalid-form-alert/invalid-form-alert.css +1 -0
- package/dist/invalid-form-alert/invalid-form-alert.css.map +1 -0
- package/dist/label/label.css +1 -1
- package/dist/label/label.css.map +1 -1
- package/dist/link/link.css +1 -1
- package/dist/link/link.css.map +1 -1
- package/dist/link-list/link-list.css +1 -1
- package/dist/link-list/link-list.css.map +1 -1
- package/dist/margin/margin.css +1 -1
- package/dist/margin/margin.css.map +1 -1
- package/dist/ordered-list/ordered-list.css +1 -1
- package/dist/ordered-list/ordered-list.css.map +1 -1
- package/dist/page/page.css +1 -0
- package/dist/page/page.css.map +1 -0
- package/dist/page-footer/page-footer.css +1 -0
- package/dist/page-footer/page-footer.css.map +1 -0
- package/dist/page-header/page-header.css +1 -0
- package/dist/page-header/page-header.css.map +1 -0
- package/dist/page-heading/page-heading.css +1 -1
- package/dist/page-heading/page-heading.css.map +1 -1
- package/dist/pagination/pagination.css +1 -1
- package/dist/pagination/pagination.css.map +1 -1
- package/dist/paragraph/paragraph.css +1 -1
- package/dist/paragraph/paragraph.css.map +1 -1
- package/dist/password-input/password-input.css +1 -1
- package/dist/password-input/password-input.css.map +1 -1
- package/dist/radio/radio.css +1 -1
- package/dist/radio/radio.css.map +1 -1
- package/dist/row/row.css +1 -1
- package/dist/row/row.css.map +1 -1
- package/dist/search-field/search-field.css +1 -1
- package/dist/search-field/search-field.css.map +1 -1
- package/dist/select/select.css +1 -1
- package/dist/select/select.css.map +1 -1
- package/dist/spotlight/spotlight.css +1 -1
- package/dist/spotlight/spotlight.css.map +1 -1
- package/dist/standalone-link/standalone-link.css +1 -0
- package/dist/standalone-link/standalone-link.css.map +1 -0
- package/dist/switch/switch.css +1 -1
- package/dist/switch/switch.css.map +1 -1
- package/dist/table-of-contents/table-of-contents.css +1 -1
- package/dist/table-of-contents/table-of-contents.css.map +1 -1
- package/dist/tabs/tabs.css +1 -1
- package/dist/tabs/tabs.css.map +1 -1
- package/dist/text-area/text-area.css +1 -1
- package/dist/text-area/text-area.css.map +1 -1
- package/dist/text-input/text-input.css +1 -1
- package/dist/text-input/text-input.css.map +1 -1
- package/dist/time-input/time-input.css +1 -1
- package/dist/time-input/time-input.css.map +1 -1
- package/dist/unordered-list/unordered-list.css +1 -1
- package/dist/unordered-list/unordered-list.css.map +1 -1
- package/dist/visually-hidden/visually-hidden.css +1 -1
- package/dist/visually-hidden/visually-hidden.css.map +1 -1
- package/package.json +4 -4
- package/src/common/hyphenation.scss +3 -3
- package/src/components/accordion/accordion.scss +6 -6
- package/src/components/action-group/README.md +1 -1
- package/src/components/action-group/action-group.scss +1 -1
- package/src/components/alert/README.md +13 -15
- package/src/components/alert/alert.scss +29 -14
- package/src/components/aspect-ratio/README.md +8 -8
- package/src/components/aspect-ratio/aspect-ratio.scss +6 -3
- package/src/components/avatar/README.md +5 -4
- package/src/components/avatar/avatar.scss +8 -46
- package/src/components/badge/README.md +7 -6
- package/src/components/badge/badge.scss +13 -40
- package/src/components/blockquote/blockquote.scss +1 -1
- package/src/components/breadcrumb/breadcrumb.scss +2 -0
- package/src/components/breakout/breakout.scss +23 -23
- package/src/components/button/README.md +1 -1
- package/src/components/button/button.scss +4 -1
- package/src/components/card/README.md +15 -14
- package/src/components/card/card.scss +24 -19
- package/src/components/character-count/character-count.scss +2 -0
- package/src/components/checkbox/checkbox.scss +6 -7
- package/src/components/column/column.scss +9 -8
- package/src/components/date-input/date-input.scss +3 -4
- package/src/components/description-list/description-list.scss +12 -10
- package/src/components/dialog/README.md +3 -5
- package/src/components/dialog/dialog.scss +38 -5
- package/src/components/error-message/error-message.scss +2 -0
- package/src/components/field-set/field-set.scss +8 -7
- package/src/components/figure/figure.scss +3 -1
- package/src/components/file-input/file-input.scss +2 -2
- package/src/components/file-list/file-list.scss +2 -1
- package/src/components/gap/README.md +13 -9
- package/src/components/gap/gap.scss +8 -12
- package/src/components/grid/README.md +9 -8
- package/src/components/grid/_mixins.scss +27 -25
- package/src/components/grid/grid.scss +19 -19
- package/src/components/heading/README.md +7 -7
- package/src/components/heading/heading.scss +20 -19
- package/src/components/icon/README.md +5 -5
- package/src/components/icon/icon.scss +41 -27
- package/src/components/icon-button/icon-button.scss +16 -15
- package/src/components/image-slider/README.md +1 -1
- package/src/components/image-slider/image-slider.scss +11 -3
- package/src/components/index.scss +5 -7
- package/src/components/{form-error-list → invalid-form-alert}/README.md +9 -9
- package/src/components/{form-error-list/form-error-list.scss → invalid-form-alert/invalid-form-alert.scss} +4 -4
- package/src/components/label/label.scss +1 -0
- package/src/components/link/README.md +9 -11
- package/src/components/link/link.scss +13 -46
- package/src/components/link-list/link-list.scss +7 -8
- package/src/components/logo/README.md +1 -1
- package/src/components/margin/README.md +16 -10
- package/src/components/margin/margin.scss +6 -8
- package/src/components/ordered-list/ordered-list.scss +3 -1
- package/src/components/page/README.md +23 -0
- package/src/components/page/page.scss +12 -0
- package/src/components/{footer → page-footer}/README.md +7 -4
- package/src/components/page-footer/page-footer.scss +56 -0
- package/src/components/{header → page-header}/README.md +6 -5
- package/src/components/page-header/page-header.scss +237 -0
- package/src/components/page-heading/README.md +1 -1
- package/src/components/page-heading/page-heading.scss +2 -1
- package/src/components/pagination/pagination.scss +23 -34
- package/src/components/paragraph/paragraph.scss +3 -1
- package/src/components/password-input/password-input.scss +2 -3
- package/src/components/radio/radio.scss +4 -5
- package/src/components/row/row.scss +9 -9
- package/src/components/search-field/search-field.scss +2 -3
- package/src/components/select/select.scss +2 -2
- package/src/components/skip-link/README.md +3 -3
- package/src/components/spotlight/README.md +5 -3
- package/src/components/spotlight/spotlight.scss +6 -10
- package/src/components/standalone-link/README.md +11 -0
- package/src/components/standalone-link/standalone-link.scss +53 -0
- package/src/components/switch/switch.scss +2 -2
- package/src/components/table-of-contents/table-of-contents.scss +2 -0
- package/src/components/tabs/README.md +1 -1
- package/src/components/tabs/tabs.scss +6 -3
- package/src/components/text-area/text-area.scss +1 -2
- package/src/components/text-input/text-input.scss +2 -3
- package/src/components/time-input/time-input.scss +3 -4
- package/src/components/unordered-list/unordered-list.scss +3 -1
- package/src/components/visually-hidden/visually-hidden.scss +1 -0
- package/dist/footer/footer.css +0 -1
- package/dist/footer/footer.css.map +0 -1
- package/dist/form-error-list/form-error-list.css +0 -1
- package/dist/form-error-list/form-error-list.css.map +0 -1
- package/dist/header/header.css +0 -1
- package/dist/header/header.css.map +0 -1
- package/dist/mega-menu/mega-menu.css +0 -1
- package/dist/mega-menu/mega-menu.css.map +0 -1
- package/dist/page-menu/page-menu.css +0 -1
- package/dist/page-menu/page-menu.css.map +0 -1
- package/dist/screen/screen.css +0 -1
- package/dist/screen/screen.css.map +0 -1
- package/dist/top-task-link/top-task-link.css +0 -1
- package/dist/top-task-link/top-task-link.css.map +0 -1
- package/src/common/size.scss +0 -14
- package/src/components/footer/footer.scss +0 -8
- package/src/components/header/header.scss +0 -216
- package/src/components/mega-menu/README.md +0 -3
- package/src/components/mega-menu/mega-menu.scss +0 -16
- package/src/components/page-menu/README.md +0 -24
- package/src/components/page-menu/page-menu.scss +0 -67
- package/src/components/screen/README.md +0 -23
- package/src/components/screen/screen.scss +0 -23
- package/src/components/top-task-link/README.md +0 -27
- package/src/components/top-task-link/top-task-link.scss +0 -45
|
@@ -18,52 +18,52 @@ $ams-grid-column-count: 12;
|
|
|
18
18
|
@include ams-grid--gap-vertical--none;
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
.ams-grid--gap-vertical--small {
|
|
22
|
-
@include ams-grid--gap-vertical--small;
|
|
23
|
-
}
|
|
24
|
-
|
|
25
21
|
.ams-grid--gap-vertical--large {
|
|
26
22
|
@include ams-grid--gap-vertical--large;
|
|
27
23
|
}
|
|
28
24
|
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
.ams-grid--padding-bottom--small {
|
|
32
|
-
@include ams-grid--padding-bottom--small;
|
|
25
|
+
.ams-grid--gap-vertical--2x-large {
|
|
26
|
+
@include ams-grid--gap-vertical--2x-large;
|
|
33
27
|
}
|
|
34
28
|
|
|
35
|
-
|
|
36
|
-
@include ams-grid--padding-bottom--medium;
|
|
37
|
-
}
|
|
29
|
+
// Grid padding
|
|
38
30
|
|
|
39
31
|
.ams-grid--padding-bottom--large {
|
|
40
32
|
@include ams-grid--padding-bottom--large;
|
|
41
33
|
}
|
|
42
34
|
|
|
43
|
-
.ams-grid--padding-
|
|
44
|
-
@include ams-grid--padding-
|
|
35
|
+
.ams-grid--padding-bottom--x-large {
|
|
36
|
+
@include ams-grid--padding-bottom--x-large;
|
|
45
37
|
}
|
|
46
38
|
|
|
47
|
-
.ams-grid--padding-
|
|
48
|
-
@include ams-grid--padding-
|
|
39
|
+
.ams-grid--padding-bottom--2x-large {
|
|
40
|
+
@include ams-grid--padding-bottom--2x-large;
|
|
49
41
|
}
|
|
50
42
|
|
|
51
43
|
.ams-grid--padding-top--large {
|
|
52
44
|
@include ams-grid--padding-top--large;
|
|
53
45
|
}
|
|
54
46
|
|
|
55
|
-
.ams-grid--padding-
|
|
56
|
-
@include ams-grid--padding-
|
|
47
|
+
.ams-grid--padding-top--x-large {
|
|
48
|
+
@include ams-grid--padding-top--x-large;
|
|
57
49
|
}
|
|
58
50
|
|
|
59
|
-
.ams-grid--padding-
|
|
60
|
-
@include ams-grid--padding-
|
|
51
|
+
.ams-grid--padding-top--2x-large {
|
|
52
|
+
@include ams-grid--padding-top--2x-large;
|
|
61
53
|
}
|
|
62
54
|
|
|
63
55
|
.ams-grid--padding-vertical--large {
|
|
64
56
|
@include ams-grid--padding-vertical--large;
|
|
65
57
|
}
|
|
66
58
|
|
|
59
|
+
.ams-grid--padding-vertical--x-large {
|
|
60
|
+
@include ams-grid--padding-vertical--x-large;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.ams-grid--padding-vertical--2x-large {
|
|
64
|
+
@include ams-grid--padding-vertical--2x-large;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
67
|
// Column span
|
|
68
68
|
// The order of these declaration blocks ensures the intended specificity.
|
|
69
69
|
|
|
@@ -2,16 +2,16 @@
|
|
|
2
2
|
|
|
3
3
|
# Heading
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
Use Headings to allow the user to grasp the structure of the page quickly.
|
|
5
|
+
Introduces a page section and describes the following content.
|
|
7
6
|
|
|
8
7
|
## Guidelines
|
|
9
8
|
|
|
10
|
-
-
|
|
11
|
-
-
|
|
12
|
-
-
|
|
13
|
-
|
|
14
|
-
|
|
9
|
+
- Use Headings to allow the user to quickly grasp the structure of the page.
|
|
10
|
+
- All headings together represent the document’s structure. Users of screen readers may use headings to navigate the page – an incorrect hierarchy will confuse them.
|
|
11
|
+
- Every page should contain one heading with level 1.
|
|
12
|
+
Do not skip heading levels, e.g. a level 2 Heading should be followed by one with level 3, not level 4.
|
|
13
|
+
The `level` prop doesn’t have a default value; the correct level should be determined for each instance.
|
|
14
|
+
- Don’t use a Heading just for its visual appearance.
|
|
15
15
|
|
|
16
16
|
## Relevant WCAG requirements
|
|
17
17
|
|
|
@@ -17,42 +17,43 @@
|
|
|
17
17
|
color: var(--ams-heading-color);
|
|
18
18
|
font-family: var(--ams-heading-font-family);
|
|
19
19
|
font-weight: var(--ams-heading-font-weight);
|
|
20
|
+
text-wrap: var(--ams-heading-text-wrap);
|
|
20
21
|
|
|
21
22
|
@include hyphenation;
|
|
22
23
|
@include text-rendering;
|
|
23
24
|
@include reset-hx;
|
|
24
25
|
}
|
|
25
26
|
|
|
26
|
-
.ams-heading--
|
|
27
|
-
font-size: var(--ams-heading-
|
|
28
|
-
line-height: var(--ams-heading-
|
|
27
|
+
.ams-heading--1 {
|
|
28
|
+
font-size: var(--ams-heading-1-font-size);
|
|
29
|
+
line-height: var(--ams-heading-1-line-height);
|
|
29
30
|
}
|
|
30
31
|
|
|
31
|
-
.ams-heading--
|
|
32
|
-
font-size: var(--ams-heading-
|
|
33
|
-
line-height: var(--ams-heading-
|
|
32
|
+
.ams-heading--2 {
|
|
33
|
+
font-size: var(--ams-heading-2-font-size);
|
|
34
|
+
line-height: var(--ams-heading-2-line-height);
|
|
34
35
|
}
|
|
35
36
|
|
|
36
|
-
.ams-heading--
|
|
37
|
-
font-size: var(--ams-heading-
|
|
38
|
-
line-height: var(--ams-heading-
|
|
37
|
+
.ams-heading--3 {
|
|
38
|
+
font-size: var(--ams-heading-3-font-size);
|
|
39
|
+
line-height: var(--ams-heading-3-line-height);
|
|
39
40
|
}
|
|
40
41
|
|
|
41
|
-
.ams-heading--
|
|
42
|
-
font-size: var(--ams-heading-
|
|
43
|
-
line-height: var(--ams-heading-
|
|
42
|
+
.ams-heading--4 {
|
|
43
|
+
font-size: var(--ams-heading-4-font-size);
|
|
44
|
+
line-height: var(--ams-heading-4-line-height);
|
|
44
45
|
}
|
|
45
46
|
|
|
46
|
-
.ams-heading--
|
|
47
|
-
font-size: var(--ams-heading-
|
|
48
|
-
line-height: var(--ams-heading-
|
|
47
|
+
.ams-heading--5 {
|
|
48
|
+
font-size: var(--ams-heading-5-font-size);
|
|
49
|
+
line-height: var(--ams-heading-5-line-height);
|
|
49
50
|
}
|
|
50
51
|
|
|
51
|
-
.ams-heading--
|
|
52
|
-
font-size: var(--ams-heading-
|
|
53
|
-
line-height: var(--ams-heading-
|
|
52
|
+
.ams-heading--6 {
|
|
53
|
+
font-size: var(--ams-heading-6-font-size);
|
|
54
|
+
line-height: var(--ams-heading-6-line-height);
|
|
54
55
|
}
|
|
55
56
|
|
|
56
|
-
.ams-heading--inverse
|
|
57
|
+
.ams-heading--inverse {
|
|
57
58
|
color: var(--ams-heading-inverse-color);
|
|
58
59
|
}
|
|
@@ -12,10 +12,10 @@ Use an icon to support textual interactive elements like buttons and links.
|
|
|
12
12
|
Always try to provide accompanying text for an icon.
|
|
13
13
|
Only use icons without accompanying text if they adhere to international standards, such as menu (hamburger icon), search (magnifying glass), next, previous, play, pause, etc.
|
|
14
14
|
|
|
15
|
-
##
|
|
15
|
+
## Colour
|
|
16
16
|
|
|
17
17
|
Icons are black or white.
|
|
18
|
-
When used as part of an interactive element, they are
|
|
18
|
+
When used as part of an interactive element, they are blue.
|
|
19
19
|
When disabled, they are grey.
|
|
20
20
|
They must adhere to the same contrast ratio for accessibility as typography against a background colour.
|
|
21
21
|
The icon defaults to the colour of the container it is in.
|
|
@@ -26,9 +26,9 @@ Icons are aligned to the left of the text by default and vertically centred to t
|
|
|
26
26
|
|
|
27
27
|
## Size
|
|
28
28
|
|
|
29
|
-
Icons
|
|
30
|
-
|
|
31
|
-
[
|
|
29
|
+
Icons have extra whitespace at their top and bottom to match the line height of text components.
|
|
30
|
+
Specify the appropriate size to pair an icon with small or large body text or with a heading.
|
|
31
|
+
[Read more in the typography documentation](/docs/brand-design-tokens-typography--docs).
|
|
32
32
|
|
|
33
33
|
## Overview
|
|
34
34
|
|
|
@@ -4,55 +4,69 @@
|
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
6
|
.ams-icon {
|
|
7
|
+
--ams-line-height: var(--ams-icon-line-height);
|
|
8
|
+
|
|
7
9
|
align-items: center;
|
|
10
|
+
align-self: baseline; // Aligns the icon with text in flex or grid context
|
|
8
11
|
display: inline-flex;
|
|
9
|
-
|
|
12
|
+
font-size: var(--ams-icon-font-size);
|
|
13
|
+
line-height: var(--ams-line-height);
|
|
14
|
+
|
|
15
|
+
&::after {
|
|
16
|
+
content: "\00200B"; // This zero width space enables baseline alignment.
|
|
17
|
+
}
|
|
10
18
|
|
|
11
|
-
|
|
12
|
-
|
|
19
|
+
svg {
|
|
20
|
+
fill: currentColor;
|
|
21
|
+
inline-size: 1em;
|
|
22
|
+
}
|
|
13
23
|
}
|
|
14
24
|
|
|
15
|
-
.ams-icon--inverse
|
|
25
|
+
.ams-icon--inverse {
|
|
16
26
|
color: var(--ams-icon-inverse-color);
|
|
17
27
|
}
|
|
18
28
|
|
|
19
29
|
.ams-icon--square {
|
|
20
|
-
|
|
30
|
+
inline-size: calc(1em * var(--ams-line-height));
|
|
21
31
|
justify-content: center;
|
|
22
32
|
}
|
|
23
33
|
|
|
24
|
-
.ams-icon--
|
|
25
|
-
|
|
26
|
-
}
|
|
34
|
+
.ams-icon--small {
|
|
35
|
+
--ams-line-height: var(--ams-icon-small-line-height);
|
|
27
36
|
|
|
28
|
-
|
|
29
|
-
block-size: var(--ams-icon-size-3-font-size);
|
|
30
|
-
inline-size: var(--ams-icon-size-3-font-size);
|
|
37
|
+
font-size: var(--ams-icon-small-font-size);
|
|
31
38
|
}
|
|
32
39
|
|
|
33
|
-
.ams-icon--
|
|
34
|
-
|
|
35
|
-
}
|
|
40
|
+
.ams-icon--large {
|
|
41
|
+
--ams-line-height: var(--ams-icon-large-line-height);
|
|
36
42
|
|
|
37
|
-
|
|
38
|
-
block-size: var(--ams-icon-size-4-font-size);
|
|
39
|
-
inline-size: var(--ams-icon-size-4-font-size);
|
|
43
|
+
font-size: var(--ams-icon-large-font-size);
|
|
40
44
|
}
|
|
41
45
|
|
|
42
|
-
.ams-icon--
|
|
43
|
-
|
|
46
|
+
.ams-icon--heading-3 {
|
|
47
|
+
--ams-line-height: var(--ams-icon-heading-3-line-height);
|
|
48
|
+
|
|
49
|
+
font-size: var(--ams-icon-heading-3-font-size);
|
|
50
|
+
line-height: var(--ams-icon-heading-3-line-height);
|
|
44
51
|
}
|
|
45
52
|
|
|
46
|
-
.ams-icon--
|
|
47
|
-
|
|
48
|
-
|
|
53
|
+
.ams-icon--heading-4 {
|
|
54
|
+
--ams-line-height: var(--ams-icon-heading-4-line-height);
|
|
55
|
+
|
|
56
|
+
font-size: var(--ams-icon-heading-4-font-size);
|
|
57
|
+
line-height: var(--ams-icon-heading-4-line-height);
|
|
49
58
|
}
|
|
50
59
|
|
|
51
|
-
.ams-icon--
|
|
52
|
-
|
|
60
|
+
.ams-icon--heading-5 {
|
|
61
|
+
--ams-line-height: var(--ams-icon-heading-5-line-height);
|
|
62
|
+
|
|
63
|
+
font-size: var(--ams-icon-heading-5-font-size);
|
|
64
|
+
line-height: var(--ams-icon-heading-5-line-height);
|
|
53
65
|
}
|
|
54
66
|
|
|
55
|
-
.ams-icon--
|
|
56
|
-
|
|
57
|
-
|
|
67
|
+
.ams-icon--heading-6 {
|
|
68
|
+
--ams-line-height: var(--ams-icon-heading-6-line-height);
|
|
69
|
+
|
|
70
|
+
font-size: var(--ams-icon-heading-6-font-size);
|
|
71
|
+
line-height: var(--ams-icon-heading-6-line-height);
|
|
58
72
|
}
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
6
|
@mixin reset-button {
|
|
7
|
-
border:
|
|
7
|
+
border: none;
|
|
8
8
|
margin-block: 0; // [1]
|
|
9
9
|
margin-inline: 0; // [1]
|
|
10
10
|
padding-block: 0;
|
|
@@ -16,7 +16,8 @@
|
|
|
16
16
|
.ams-icon-button {
|
|
17
17
|
background-color: transparent;
|
|
18
18
|
color: var(--ams-icon-button-color);
|
|
19
|
-
cursor:
|
|
19
|
+
cursor: var(--ams-icon-button-cursor);
|
|
20
|
+
display: inline-flex;
|
|
20
21
|
outline-offset: var(--ams-icon-button-outline-offset);
|
|
21
22
|
touch-action: manipulation;
|
|
22
23
|
|
|
@@ -30,35 +31,35 @@
|
|
|
30
31
|
&:disabled {
|
|
31
32
|
background-color: transparent;
|
|
32
33
|
color: var(--ams-icon-button-disabled-color);
|
|
33
|
-
cursor:
|
|
34
|
+
cursor: var(--ams-icon-button-disabled-cursor);
|
|
34
35
|
}
|
|
35
36
|
}
|
|
36
37
|
|
|
37
|
-
.ams-icon-button--contrast
|
|
38
|
-
color: var(--ams-icon-button-contrast-color
|
|
38
|
+
.ams-icon-button--contrast {
|
|
39
|
+
color: var(--ams-icon-button-contrast-color);
|
|
39
40
|
|
|
40
41
|
&:hover {
|
|
41
|
-
background-color: var(--ams-icon-button-contrast-
|
|
42
|
-
color: var(--ams-icon-button-contrast-
|
|
42
|
+
background-color: var(--ams-icon-button-contrast-hover-background-color);
|
|
43
|
+
color: var(--ams-icon-button-contrast-hover-color);
|
|
43
44
|
}
|
|
44
45
|
|
|
45
46
|
&:disabled {
|
|
46
47
|
background-color: transparent;
|
|
47
|
-
color: var(--ams-icon-button-contrast-
|
|
48
|
+
color: var(--ams-icon-button-contrast-disabled-color);
|
|
48
49
|
}
|
|
49
50
|
}
|
|
50
51
|
|
|
51
|
-
.ams-icon-button--inverse
|
|
52
|
-
background-color: var(--ams-icon-button-inverse-
|
|
53
|
-
color: var(--ams-icon-button-inverse-color
|
|
52
|
+
.ams-icon-button--inverse {
|
|
53
|
+
background-color: var(--ams-icon-button-inverse-background-color);
|
|
54
|
+
color: var(--ams-icon-button-inverse-color);
|
|
54
55
|
|
|
55
56
|
&:hover {
|
|
56
|
-
background-color: var(--ams-icon-button-inverse-
|
|
57
|
-
color: var(--ams-icon-button-inverse-
|
|
57
|
+
background-color: var(--ams-icon-button-inverse-hover-background-color);
|
|
58
|
+
color: var(--ams-icon-button-inverse-hover-color);
|
|
58
59
|
}
|
|
59
60
|
|
|
60
61
|
&:disabled {
|
|
61
|
-
background-color: var(--ams-icon-button-inverse-
|
|
62
|
-
color: var(--ams-icon-button-inverse-
|
|
62
|
+
background-color: var(--ams-icon-button-inverse-disabled-background-color);
|
|
63
|
+
color: var(--ams-icon-button-inverse-disabled-color);
|
|
63
64
|
}
|
|
64
65
|
}
|
|
@@ -19,7 +19,7 @@ The images do not slide automatically.
|
|
|
19
19
|
- Feature the most essential image first.
|
|
20
20
|
- Assume that some or many users will not navigate between the slides and only see the first image.
|
|
21
21
|
Display all images separately if you want each of them to receive attention.
|
|
22
|
-
- A full-width Image Slider should run from one edge of the
|
|
22
|
+
- A full-width Image Slider should run from one edge of the [Page](/docs/components-containers-page--docs) container to the other;
|
|
23
23
|
position it next to a Grid, not in a Cell spanning all columns.
|
|
24
24
|
Smaller sliders are fine in a Grid Cell.
|
|
25
25
|
- Consult the [Image](/docs/components-media-image--docs) docs for guidelines on the individual images.
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
* @license EUPL-1.2+
|
|
3
3
|
* Copyright Gemeente Amsterdam
|
|
4
4
|
*/
|
|
5
|
+
|
|
5
6
|
@use "../../common/breakpoint" as *;
|
|
6
7
|
|
|
7
8
|
.ams-image-slider {
|
|
@@ -66,19 +67,26 @@
|
|
|
66
67
|
max-inline-size: 100%;
|
|
67
68
|
}
|
|
68
69
|
|
|
70
|
+
@mixin reset-button {
|
|
71
|
+
border: none;
|
|
72
|
+
border-radius: 0; // Reset rounded borders on iOS devices
|
|
73
|
+
padding-block: 0;
|
|
74
|
+
padding-inline: 0;
|
|
75
|
+
}
|
|
76
|
+
|
|
69
77
|
.ams-image-slider__thumbnail {
|
|
78
|
+
aspect-ratio: var(--ams-image-aspect-ratio); // Use the same default aspect ratio as the Image component
|
|
70
79
|
background-color: var(--ams-image-slider-thumbnails-thumbnail-background-color);
|
|
71
80
|
background-position: center;
|
|
72
81
|
background-size: cover;
|
|
73
|
-
border: none;
|
|
74
82
|
cursor: var(--ams-image-slider-thumbnails-thumbnail-cursor);
|
|
75
83
|
opacity: var(--ams-image-slider-thumbnails-thumbnail-opacity);
|
|
76
84
|
outline-offset: var(--ams-button-outline-offset);
|
|
77
|
-
padding-block: 0;
|
|
78
|
-
padding-inline: 0;
|
|
79
85
|
position: relative;
|
|
80
86
|
scroll-snap-align: start;
|
|
81
87
|
|
|
88
|
+
@include reset-button;
|
|
89
|
+
|
|
82
90
|
&:hover {
|
|
83
91
|
opacity: var(--ams-image-slider-thumbnails-thumbnail-hover-opacity);
|
|
84
92
|
}
|
|
@@ -28,38 +28,37 @@
|
|
|
28
28
|
@use "figure/figure";
|
|
29
29
|
@use "file-input/file-input";
|
|
30
30
|
@use "file-list/file-list";
|
|
31
|
-
@use "footer/footer";
|
|
32
|
-
@use "form-error-list/form-error-list";
|
|
33
31
|
@use "gap/gap";
|
|
34
32
|
@use "grid/grid";
|
|
35
|
-
@use "header/header";
|
|
36
33
|
@use "heading/heading";
|
|
37
34
|
@use "hint/hint";
|
|
38
35
|
@use "icon-button/icon-button";
|
|
39
36
|
@use "icon/icon";
|
|
40
37
|
@use "image-slider/image-slider";
|
|
41
38
|
@use "image/image";
|
|
39
|
+
@use "invalid-form-alert/invalid-form-alert";
|
|
42
40
|
@use "label/label";
|
|
43
41
|
@use "link-list/link-list";
|
|
44
42
|
@use "link/link";
|
|
45
43
|
@use "logo/logo";
|
|
46
44
|
@use "margin/margin";
|
|
47
45
|
@use "mark/mark";
|
|
48
|
-
@use "mega-menu/mega-menu";
|
|
49
46
|
@use "ordered-list/ordered-list";
|
|
50
47
|
@use "overlap/overlap";
|
|
48
|
+
@use "page/page";
|
|
49
|
+
@use "page-footer/page-footer";
|
|
50
|
+
@use "page-header/page-header";
|
|
51
51
|
@use "page-heading/page-heading";
|
|
52
|
-
@use "page-menu/page-menu";
|
|
53
52
|
@use "pagination/pagination";
|
|
54
53
|
@use "paragraph/paragraph";
|
|
55
54
|
@use "password-input/password-input";
|
|
56
55
|
@use "radio/radio";
|
|
57
56
|
@use "row/row";
|
|
58
|
-
@use "screen/screen";
|
|
59
57
|
@use "search-field/search-field";
|
|
60
58
|
@use "select/select";
|
|
61
59
|
@use "skip-link/skip-link";
|
|
62
60
|
@use "spotlight/spotlight";
|
|
61
|
+
@use "standalone-link/standalone-link";
|
|
63
62
|
@use "switch/switch";
|
|
64
63
|
@use "table-of-contents/table-of-contents";
|
|
65
64
|
@use "table/table";
|
|
@@ -67,6 +66,5 @@
|
|
|
67
66
|
@use "text-area/text-area";
|
|
68
67
|
@use "text-input/text-input";
|
|
69
68
|
@use "time-input/time-input";
|
|
70
|
-
@use "top-task-link/top-task-link";
|
|
71
69
|
@use "unordered-list/unordered-list";
|
|
72
70
|
@use "visually-hidden/visually-hidden";
|
|
@@ -1,27 +1,27 @@
|
|
|
1
1
|
<!-- @license CC0-1.0 -->
|
|
2
2
|
|
|
3
|
-
# Form
|
|
3
|
+
# Invalid Form Alert
|
|
4
4
|
|
|
5
5
|
Use this component at the top of a page to summarise any errors a user has made.
|
|
6
|
-
When a user makes an error, you must show both a Form
|
|
6
|
+
When a user makes an error, you must show both a Invalid Form Alert and an Error Message above each answer that contains an error.
|
|
7
7
|
|
|
8
8
|
## Guidelines
|
|
9
9
|
|
|
10
|
-
- Always show
|
|
11
|
-
- You must link the errors in the Form
|
|
10
|
+
- Always show an Invalid Form Alert when there is a validation error, even if there’s only one.
|
|
11
|
+
- You must link the errors in the Invalid Form Alert to the answer they relate to (see below).
|
|
12
12
|
|
|
13
|
-
## Linking from the Form
|
|
13
|
+
## Linking from the Invalid Form Alert to each answer
|
|
14
14
|
|
|
15
|
-
For questions that require a user to answer using a single field, like a file upload, select, textarea
|
|
15
|
+
For questions that require a user to answer using a single field, like a file upload, select, textarea or text input, link to the `id` of that field.
|
|
16
16
|
|
|
17
17
|
When a user has to enter their answer into multiple fields, such as day, month and year fields, link to the `id` of the first field that contains an error.
|
|
18
18
|
If you do not know which field contains an error, link to the `id` of the first field.
|
|
19
19
|
|
|
20
20
|
For questions that require a user to select one or more options from a list using Radios or Checkboxes, link to the `id` of the first Radio or Checkbox.
|
|
21
21
|
|
|
22
|
-
## Where to put the Form
|
|
22
|
+
## Where to put the Invalid Form Alert
|
|
23
23
|
|
|
24
|
-
Put the Form
|
|
24
|
+
Put the Invalid Form Alert directly above the first question on the page. Place it outside of the `<form>`-tag, [to make sure screen readers do not skip it](https://nldesignsystem.nl/richtlijnen/formulieren/meerdere-stappen/#plaats-de-informatie-over-waar-de-gebruiker-is-in-de-stappen-boven-het-formulier).
|
|
25
25
|
|
|
26
26
|
## Error count in document title
|
|
27
27
|
|
|
@@ -39,7 +39,7 @@ Note: this functionality has been disabled on this page, to prevent unexpected f
|
|
|
39
39
|
|
|
40
40
|
Pay extra attention to these parts:
|
|
41
41
|
|
|
42
|
-
- [WCAG requirement 1.3.1](https://www.w3.org/TR/WCAG21/#info-and-relationships): the heading level of the Form
|
|
42
|
+
- [WCAG requirement 1.3.1](https://www.w3.org/TR/WCAG21/#info-and-relationships): the heading level of the Invalid Form Alert depends on where in the page it is placed, this may differ per page.
|
|
43
43
|
|
|
44
44
|
## References
|
|
45
45
|
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
.ams-form-
|
|
2
|
-
outline-offset: var(--ams-form-
|
|
1
|
+
.ams-invalid-form-alert {
|
|
2
|
+
outline-offset: var(--ams-invalid-form-alert-outline-offset);
|
|
3
3
|
|
|
4
4
|
// In Chromium browsers, the outline overlaps with the border in this component.
|
|
5
5
|
// We're not sure why, but to fix this we double the offset for Chromium browsers here.
|
|
6
6
|
@supports (contain: paint) and (not (-moz-appearance: none)) {
|
|
7
|
-
outline-offset: calc(var(--ams-form-
|
|
7
|
+
outline-offset: calc(var(--ams-invalid-form-alert-outline-offset) * 2);
|
|
8
8
|
|
|
9
9
|
// Reset for Safari
|
|
10
10
|
@supports (font: -apple-system-body) {
|
|
11
|
-
outline-offset: var(--ams-form-
|
|
11
|
+
outline-offset: var(--ams-invalid-form-alert-outline-offset);
|
|
12
12
|
}
|
|
13
13
|
}
|
|
14
14
|
}
|
|
@@ -7,16 +7,15 @@ It is the lightweight variant for navigation.
|
|
|
7
7
|
|
|
8
8
|
## Guidelines
|
|
9
9
|
|
|
10
|
-
Use a link in the following cases:
|
|
11
|
-
|
|
12
|
-
- To navigate to another
|
|
13
|
-
- To navigate to
|
|
14
|
-
- To
|
|
15
|
-
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
Use a button instead of a link when an action is desired.
|
|
10
|
+
- Use a link in the following cases:
|
|
11
|
+
- To navigate to another page within the website or application
|
|
12
|
+
- To navigate to another website (see [External links](#external-links))
|
|
13
|
+
- To navigate to an element on the same page
|
|
14
|
+
- To link to emails or phone numbers (start the link with `mailto:` or `tel:`)
|
|
15
|
+
- A link is a navigation component.
|
|
16
|
+
Use a button instead of a link when an action is desired.
|
|
17
|
+
- An icon can be added to links, positioned after the link.
|
|
18
|
+
- Too many links on the same page may confuse the user.
|
|
20
19
|
|
|
21
20
|
### External links
|
|
22
21
|
|
|
@@ -28,7 +27,6 @@ For more information: [Links to cross-origin destinations are unsafe](https://de
|
|
|
28
27
|
|
|
29
28
|
Visited links indicate that a user has already opened the link.
|
|
30
29
|
We discourage using styles for visited links because they often make the page less clear and navigation more challenging.
|
|
31
|
-
The inline link does have a visited style.
|
|
32
30
|
It is not part of navigation elements that are frequently scanned.
|
|
33
31
|
|
|
34
32
|
### Using links with routing libraries
|
|
@@ -3,73 +3,40 @@
|
|
|
3
3
|
* Copyright Gemeente Amsterdam
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
+
@use "../../common/hyphenation" as *;
|
|
6
7
|
@use "../../common/text-rendering" as *;
|
|
7
8
|
|
|
8
9
|
.ams-link {
|
|
9
10
|
color: var(--ams-link-color);
|
|
10
11
|
font-family: var(--ams-link-font-family);
|
|
12
|
+
font-size: var(--ams-link-font-size);
|
|
11
13
|
font-weight: var(--ams-link-font-weight);
|
|
14
|
+
line-height: var(--ams-link-line-height);
|
|
12
15
|
outline-offset: var(--ams-link-outline-offset);
|
|
16
|
+
text-decoration-thickness: var(--ams-link-text-decoration-thickness);
|
|
17
|
+
text-underline-offset: var(--ams-link-text-underline-offset);
|
|
13
18
|
|
|
14
19
|
@include text-rendering;
|
|
15
20
|
|
|
16
21
|
&:hover {
|
|
17
22
|
color: var(--ams-link-hover-color);
|
|
23
|
+
text-decoration-thickness: var(--ams-link-hover-text-decoration-thickness);
|
|
24
|
+
text-underline-offset: var(--ams-link-hover-text-underline-offset);
|
|
18
25
|
}
|
|
19
26
|
}
|
|
20
27
|
|
|
21
|
-
.ams-link--
|
|
22
|
-
|
|
23
|
-
font-size: var(--ams-link-standalone-font-size);
|
|
24
|
-
line-height: var(--ams-link-standalone-line-height);
|
|
25
|
-
text-decoration-line: var(--ams-link-standalone-text-decoration-line);
|
|
26
|
-
text-decoration-thickness: var(--ams-link-standalone-text-decoration-thickness);
|
|
27
|
-
text-underline-offset: var(--ams-link-standalone-text-underline-offset);
|
|
28
|
+
.ams-link--contrast {
|
|
29
|
+
color: var(--ams-link-contrast-color);
|
|
28
30
|
|
|
29
31
|
&:hover {
|
|
30
|
-
|
|
31
|
-
text-underline-offset: var(--ams-link-standalone-hover-text-underline-offset);
|
|
32
|
+
color: var(--ams-link-contrast-hover-color);
|
|
32
33
|
}
|
|
33
34
|
}
|
|
34
35
|
|
|
35
|
-
.ams-link--
|
|
36
|
-
|
|
37
|
-
font-size: var(--ams-link-inline-font-size);
|
|
38
|
-
line-height: var(--ams-link-inline-line-height);
|
|
39
|
-
text-decoration-line: var(--ams-link-inline-text-decoration-line);
|
|
40
|
-
text-decoration-thickness: var(--ams-link-inline-text-decoration-thickness);
|
|
41
|
-
text-underline-offset: var(--ams-link-inline-text-underline-offset);
|
|
36
|
+
.ams-link--inverse {
|
|
37
|
+
color: var(--ams-link-inverse-color);
|
|
42
38
|
|
|
43
39
|
&:hover {
|
|
44
|
-
|
|
45
|
-
text-underline-offset: var(--ams-link-inline-hover-text-underline-offset);
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
&:visited {
|
|
49
|
-
color: var(--ams-link-inline-visited-color);
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
.ams-link--contrast-color {
|
|
54
|
-
color: var(--ams-link-contrast-color-color);
|
|
55
|
-
|
|
56
|
-
&:hover {
|
|
57
|
-
color: var(--ams-link-contrast-color-hover-color);
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
&:visited {
|
|
61
|
-
color: var(--ams-link-contrast-color-visited-color);
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
.ams-link--inverse-color {
|
|
66
|
-
color: var(--ams-link-inverse-color-color);
|
|
67
|
-
|
|
68
|
-
&:hover {
|
|
69
|
-
color: var(--ams-link-inverse-color-hover-color);
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
&:visited {
|
|
73
|
-
color: var(--ams-link-inverse-color-visited-color);
|
|
40
|
+
color: var(--ams-link-inverse-hover-color);
|
|
74
41
|
}
|
|
75
42
|
}
|