@amsterdam/design-system-css 0.14.1 → 0.15.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 +51 -0
- package/README.md +2 -0
- 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/footer/footer.css +1 -1
- package/dist/footer/footer.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/header/header.css +1 -1
- package/dist/header/header.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-heading/page-heading.css +1 -1
- package/dist/page-heading/page-heading.css.map +1 -1
- package/dist/page-menu/page-menu.css +1 -1
- package/dist/page-menu/page-menu.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/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/top-task-link/top-task-link.css +1 -1
- package/dist/top-task-link/top-task-link.css.map +1 -1
- package/dist/unordered-list/unordered-list.css +1 -1
- package/dist/unordered-list/unordered-list.css.map +1 -1
- package/package.json +4 -4
- package/src/common/hyphenation.scss +3 -3
- package/src/components/accordion/accordion.scss +5 -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 +4 -4
- package/src/components/button/README.md +1 -1
- package/src/components/button/button.scss +4 -1
- package/src/components/card/card.scss +19 -22
- 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/dialog.scss +17 -5
- package/src/components/error-message/error-message.scss +2 -0
- package/src/components/field-set/field-set.scss +1 -1
- 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/footer/README.md +3 -2
- package/src/components/footer/footer.scss +41 -2
- package/src/components/gap/README.md +13 -9
- package/src/components/gap/gap.scss +8 -12
- package/src/components/grid/_mixins.scss +14 -12
- package/src/components/header/README.md +1 -0
- package/src/components/header/header.scss +30 -18
- package/src/components/heading/README.md +7 -7
- package/src/components/heading/heading.scss +19 -19
- package/src/components/icon/README.md +5 -5
- package/src/components/icon/icon.scss +42 -29
- package/src/components/icon-button/icon-button.scss +16 -15
- package/src/components/image-slider/image-slider.scss +11 -3
- package/src/components/index.scss +1 -1
- 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/link/README.md +1 -2
- package/src/components/link/link.scss +9 -20
- package/src/components/link-list/link-list.scss +7 -8
- 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-heading/page-heading.scss +1 -1
- package/src/components/page-menu/page-menu.scss +0 -2
- 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/screen/README.md +6 -6
- package/src/components/search-field/search-field.scss +2 -3
- package/src/components/select/select.scss +2 -2
- package/src/components/spotlight/README.md +5 -2
- package/src/components/spotlight/spotlight.scss +6 -10
- package/src/components/switch/switch.scss +2 -2
- package/src/components/table-of-contents/table-of-contents.scss +2 -0
- 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/top-task-link/top-task-link.scss +3 -3
- package/src/components/unordered-list/unordered-list.scss +3 -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/src/common/size.scss +0 -14
|
@@ -3,6 +3,7 @@
|
|
|
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
|
@mixin reset-figure {
|
|
@@ -25,9 +26,10 @@
|
|
|
25
26
|
font-weight: var(--ams-figure-caption-font-weight);
|
|
26
27
|
line-height: var(--ams-figure-caption-line-height);
|
|
27
28
|
|
|
29
|
+
@include hyphenation;
|
|
28
30
|
@include text-rendering;
|
|
29
31
|
}
|
|
30
32
|
|
|
31
|
-
.ams-figure__caption--inverse
|
|
33
|
+
.ams-figure__caption--inverse {
|
|
32
34
|
color: var(--ams-figure-caption-inverse-color);
|
|
33
35
|
}
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
@use "../../common/text-rendering" as *;
|
|
7
7
|
|
|
8
8
|
@mixin reset-button {
|
|
9
|
-
border:
|
|
9
|
+
border: none;
|
|
10
10
|
border-radius: 0; // Reset rounded borders on iOS devices
|
|
11
11
|
}
|
|
12
12
|
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
font-weight: var(--ams-file-input-font-weight);
|
|
22
22
|
inline-size: 100%;
|
|
23
23
|
line-height: var(--ams-file-input-line-height);
|
|
24
|
-
outline-offset:
|
|
24
|
+
outline-offset: var(--ams-file-input-outline-offset);
|
|
25
25
|
padding-block: var(--ams-file-input-padding-block);
|
|
26
26
|
padding-inline: var(--ams-file-input-padding-inline);
|
|
27
27
|
touch-action: manipulation;
|
|
@@ -3,6 +3,7 @@
|
|
|
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
|
@mixin reset-ul {
|
|
@@ -17,13 +18,13 @@
|
|
|
17
18
|
gap: var(--ams-file-list-gap);
|
|
18
19
|
padding-block: var(--ams-file-list-padding-block);
|
|
19
20
|
|
|
21
|
+
@include hyphenation;
|
|
20
22
|
@include text-rendering;
|
|
21
23
|
@include reset-ul;
|
|
22
24
|
}
|
|
23
25
|
|
|
24
26
|
.ams-file-list__item {
|
|
25
27
|
display: flex;
|
|
26
|
-
flex-direction: row;
|
|
27
28
|
font-family: var(--ams-file-list-file-font-family);
|
|
28
29
|
font-size: var(--ams-file-list-file-font-size);
|
|
29
30
|
font-weight: var(--ams-file-list-file-font-weight);
|
|
@@ -6,8 +6,9 @@ Provides service information at the bottom of every page.
|
|
|
6
6
|
|
|
7
7
|
## Guidelines
|
|
8
8
|
|
|
9
|
-
- The Footer usually consists of two sections: a full-width blue area and a
|
|
10
|
-
-
|
|
9
|
+
- The Footer usually consists of two sections: a full-width blue area and a `Footer.Menu` below it.
|
|
10
|
+
- Both sections are preceded by a visually hidden `Heading` for accessibility.
|
|
11
|
+
- A Footer containing only a `Footer.Menu` can be sufficient for applications.
|
|
11
12
|
- The Footer must be used on all websites for the City of Amsterdam.
|
|
12
13
|
- It must be the same on every page.
|
|
13
14
|
|
|
@@ -3,6 +3,45 @@
|
|
|
3
3
|
* Copyright Gemeente Amsterdam
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
@use "../../common/hyphenation" as *;
|
|
7
|
+
@use "../../common/text-rendering" as *;
|
|
8
|
+
|
|
9
|
+
@mixin reset-ul {
|
|
10
|
+
list-style: none;
|
|
11
|
+
margin-block: 0;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.ams-footer__spotlight {
|
|
15
|
+
background-color: var(--ams-footer-spotlight-background-color);
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.ams-footer__menu {
|
|
19
|
+
column-gap: var(--ams-footer-menu-column-gap);
|
|
20
|
+
display: flex;
|
|
21
|
+
flex-wrap: wrap;
|
|
22
|
+
padding-block: var(--ams-footer-menu-padding-block);
|
|
23
|
+
padding-inline: var(--ams-footer-menu-padding-inline);
|
|
24
|
+
row-gap: var(--ams-footer-menu-row-gap);
|
|
25
|
+
|
|
26
|
+
@include reset-ul;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.ams-footer__menu-link {
|
|
30
|
+
color: var(--ams-footer-menu-link-color);
|
|
31
|
+
font-family: var(--ams-footer-menu-link-font-family);
|
|
32
|
+
font-size: var(--ams-footer-menu-link-font-size);
|
|
33
|
+
font-weight: var(--ams-footer-menu-link-font-weight);
|
|
34
|
+
line-height: var(--ams-footer-menu-link-line-height);
|
|
35
|
+
outline-offset: var(--ams-footer-menu-link-outline-offset);
|
|
36
|
+
text-decoration-line: var(--ams-footer-menu-link-text-decoration-line);
|
|
37
|
+
text-decoration-thickness: var(--ams-footer-menu-link-text-decoration-thickness);
|
|
38
|
+
text-underline-offset: var(--ams-footer-menu-link-text-underline-offset);
|
|
39
|
+
|
|
40
|
+
@include hyphenation;
|
|
41
|
+
@include text-rendering;
|
|
42
|
+
|
|
43
|
+
&:hover {
|
|
44
|
+
color: var(--ams-footer-menu-link-hover-color);
|
|
45
|
+
text-decoration-line: var(--ams-footer-menu-link-hover-text-decoration-line);
|
|
46
|
+
}
|
|
8
47
|
}
|
|
@@ -6,15 +6,19 @@ Adds white space between a set of elements.
|
|
|
6
6
|
|
|
7
7
|
## Class names
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
9
|
+
Five options are available for the width or height of the gap:
|
|
10
|
+
|
|
11
|
+
- `ams-gap-xs`
|
|
12
|
+
- `ams-gap-s`
|
|
13
|
+
- `ams-gap-m`
|
|
14
|
+
- `ams-gap-l`
|
|
15
|
+
- `ams-gap-xl`
|
|
16
|
+
|
|
17
|
+
Because spacing is responsive, the gaps are as well.
|
|
18
|
+
They are also smaller in Compact Mode.
|
|
19
|
+
Consult the [Space](/docs/brand-design-tokens-space--docs) docs for an indication of their sizes.
|
|
20
|
+
|
|
21
|
+
The `2xl` space is intended for whitespace around a [Grid](/docs/components-layout-grid--docs) only, which can be produced through a `padding*` of `large`.
|
|
18
22
|
|
|
19
23
|
## Guidelines
|
|
20
24
|
|
|
@@ -3,17 +3,13 @@
|
|
|
3
3
|
* Copyright Gemeente Amsterdam
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
@if $size != "no" {
|
|
15
|
-
.ams-gap--#{$size} {
|
|
16
|
-
grid-gap: var(--ams-gap-#{$size}) !important;
|
|
17
|
-
}
|
|
6
|
+
// If you modify this list, you must also update the object in
|
|
7
|
+
// packages/react/src/common/shortSize.ts
|
|
8
|
+
// Note that we don’t offer a 2xl gap on purpose.
|
|
9
|
+
@each $size in ("xs", "s", "m", "l", "xl") {
|
|
10
|
+
.ams-gap-#{$size} {
|
|
11
|
+
display: grid !important;
|
|
12
|
+
/* stylelint-disable-next-line csstools/value-no-unknown-custom-properties */
|
|
13
|
+
gap: var(--ams-space-#{$size}) !important;
|
|
18
14
|
}
|
|
19
15
|
}
|
|
@@ -10,14 +10,16 @@
|
|
|
10
10
|
display: grid;
|
|
11
11
|
grid-template-columns: repeat(var(--ams-grid-column-count), 1fr);
|
|
12
12
|
padding-inline: var(--ams-grid-padding-inline);
|
|
13
|
-
row-gap: var(--ams-grid-row-gap-
|
|
13
|
+
row-gap: var(--ams-grid-row-gap-m);
|
|
14
14
|
|
|
15
15
|
@media screen and (min-width: $ams-breakpoint-medium) {
|
|
16
16
|
grid-template-columns: repeat(var(--ams-grid-medium-column-count), 1fr);
|
|
17
|
+
padding-inline: var(--ams-grid-medium-padding-inline);
|
|
17
18
|
}
|
|
18
19
|
|
|
19
20
|
@media screen and (min-width: $ams-breakpoint-wide) {
|
|
20
21
|
grid-template-columns: repeat(var(--ams-grid-wide-column-count), 1fr);
|
|
22
|
+
padding-inline: var(--ams-grid-wide-padding-inline);
|
|
21
23
|
}
|
|
22
24
|
}
|
|
23
25
|
|
|
@@ -28,49 +30,49 @@
|
|
|
28
30
|
}
|
|
29
31
|
|
|
30
32
|
@mixin ams-grid--gap-vertical--small {
|
|
31
|
-
row-gap: var(--ams-grid-row-gap-
|
|
33
|
+
row-gap: var(--ams-grid-row-gap-s);
|
|
32
34
|
}
|
|
33
35
|
|
|
34
36
|
@mixin ams-grid--gap-vertical--large {
|
|
35
|
-
row-gap: var(--ams-grid-row-gap-
|
|
37
|
+
row-gap: var(--ams-grid-row-gap-l);
|
|
36
38
|
}
|
|
37
39
|
|
|
38
40
|
// Grid padding
|
|
39
41
|
|
|
40
42
|
@mixin ams-grid--padding-bottom--small {
|
|
41
|
-
padding-block-end: var(--ams-grid-padding-block-
|
|
43
|
+
padding-block-end: var(--ams-grid-padding-block-s);
|
|
42
44
|
}
|
|
43
45
|
|
|
44
46
|
@mixin ams-grid--padding-bottom--medium {
|
|
45
|
-
padding-block-end: var(--ams-grid-padding-block-
|
|
47
|
+
padding-block-end: var(--ams-grid-padding-block-m);
|
|
46
48
|
}
|
|
47
49
|
|
|
48
50
|
@mixin ams-grid--padding-bottom--large {
|
|
49
|
-
padding-block-end: var(--ams-grid-padding-block-
|
|
51
|
+
padding-block-end: var(--ams-grid-padding-block-l);
|
|
50
52
|
}
|
|
51
53
|
|
|
52
54
|
@mixin ams-grid--padding-top--small {
|
|
53
|
-
padding-block-start: var(--ams-grid-padding-block-
|
|
55
|
+
padding-block-start: var(--ams-grid-padding-block-s);
|
|
54
56
|
}
|
|
55
57
|
|
|
56
58
|
@mixin ams-grid--padding-top--medium {
|
|
57
|
-
padding-block-start: var(--ams-grid-padding-block-
|
|
59
|
+
padding-block-start: var(--ams-grid-padding-block-m);
|
|
58
60
|
}
|
|
59
61
|
|
|
60
62
|
@mixin ams-grid--padding-top--large {
|
|
61
|
-
padding-block-start: var(--ams-grid-padding-block-
|
|
63
|
+
padding-block-start: var(--ams-grid-padding-block-l);
|
|
62
64
|
}
|
|
63
65
|
|
|
64
66
|
@mixin ams-grid--padding-vertical--small {
|
|
65
|
-
padding-block: var(--ams-grid-padding-block-
|
|
67
|
+
padding-block: var(--ams-grid-padding-block-s);
|
|
66
68
|
}
|
|
67
69
|
|
|
68
70
|
@mixin ams-grid--padding-vertical--medium {
|
|
69
|
-
padding-block: var(--ams-grid-padding-block-
|
|
71
|
+
padding-block: var(--ams-grid-padding-block-m);
|
|
70
72
|
}
|
|
71
73
|
|
|
72
74
|
@mixin ams-grid--padding-vertical--large {
|
|
73
|
-
padding-block: var(--ams-grid-padding-block-
|
|
75
|
+
padding-block: var(--ams-grid-padding-block-l);
|
|
74
76
|
}
|
|
75
77
|
|
|
76
78
|
@mixin ams-grid__cell--span-all {
|
|
@@ -18,6 +18,7 @@ Includes the name of the application if it is not the general website.
|
|
|
18
18
|
- On narrow windows, links can move from the inline menu to the collapsible one.
|
|
19
19
|
- Labels should be short to help the inline menu fit on a single line whenever possible.
|
|
20
20
|
- An icon can be added to the end of a link to make its destination easier to guess.
|
|
21
|
+
- For websites with a brand name that feature the standard Amsterdam logo, only the emblem is shown on narrow screens.
|
|
21
22
|
|
|
22
23
|
## References
|
|
23
24
|
|
|
@@ -8,34 +8,46 @@
|
|
|
8
8
|
|
|
9
9
|
.ams-header {
|
|
10
10
|
/*
|
|
11
|
-
* The
|
|
12
|
-
* This keeps all navigation in one nav element and lets the menu wrap around the
|
|
13
|
-
* Display grid is used to let both
|
|
11
|
+
* The logo link section is created twice: once outside the navigation and once hidden inside it.
|
|
12
|
+
* This keeps all navigation in one nav element and lets the menu wrap around the logo link section.
|
|
13
|
+
* Display grid is used to let both logo link sections overlap.
|
|
14
14
|
*/
|
|
15
15
|
display: grid;
|
|
16
|
+
font-family: var(--ams-header-font-family);
|
|
16
17
|
padding-block: var(--ams-header-padding-block);
|
|
17
18
|
padding-inline: var(--ams-header-padding-inline);
|
|
18
19
|
}
|
|
19
20
|
|
|
20
|
-
.ams-
|
|
21
|
+
.ams-header__logo-link {
|
|
21
22
|
align-items: center;
|
|
22
|
-
align-self: start; // To align the
|
|
23
|
-
column-gap: var(--ams-header-
|
|
23
|
+
align-self: start; // To align the logo link section to the top of the header when it wraps
|
|
24
|
+
column-gap: var(--ams-header-logo-link-column-gap);
|
|
24
25
|
display: flex;
|
|
25
|
-
grid-area: 1 / 1; // To allow this section to overlap with the second
|
|
26
|
+
grid-area: 1 / 1; // To allow this section to overlap with the second logo link section
|
|
27
|
+
inline-size: fit-content;
|
|
28
|
+
outline-offset: var(--ams-header-logo-link-outline-offset);
|
|
29
|
+
text-decoration: none;
|
|
26
30
|
}
|
|
27
31
|
|
|
28
|
-
.ams-
|
|
32
|
+
.ams-header__logo-link--hidden {
|
|
29
33
|
opacity: 0%;
|
|
30
|
-
user-select: none; // The hidden
|
|
34
|
+
user-select: none; // The hidden logo link section should not be selectable
|
|
31
35
|
}
|
|
32
36
|
|
|
33
|
-
.ams-header__logo-
|
|
34
|
-
|
|
37
|
+
.ams-header__logo-container {
|
|
38
|
+
flex-shrink: 0;
|
|
39
|
+
inline-size: 0.75rem;
|
|
40
|
+
overflow: hidden;
|
|
41
|
+
|
|
42
|
+
@media screen and (min-width: $ams-breakpoint-medium) {
|
|
43
|
+
inline-size: auto;
|
|
44
|
+
}
|
|
35
45
|
}
|
|
36
46
|
|
|
37
|
-
|
|
38
|
-
|
|
47
|
+
.ams-header__brand-name {
|
|
48
|
+
color: var(--ams-header-brand-name-color);
|
|
49
|
+
font-size: var(--ams-header-brand-name-font-size);
|
|
50
|
+
font-weight: var(--ams-header-brand-name-font-weight);
|
|
39
51
|
line-height: 1.35;
|
|
40
52
|
}
|
|
41
53
|
|
|
@@ -43,8 +55,8 @@
|
|
|
43
55
|
column-gap: var(--ams-header-navigation-column-gap);
|
|
44
56
|
display: flex;
|
|
45
57
|
flex-wrap: wrap;
|
|
46
|
-
grid-area: 1 / 1; // To allow this section to overlap with the
|
|
47
|
-
// This section blocks pointer events initially, so the hidden
|
|
58
|
+
grid-area: 1 / 1; // To allow this section to overlap with the logo link section
|
|
59
|
+
// This section blocks pointer events initially, so the hidden logo link section can't be activated.
|
|
48
60
|
// The menu and collapsible menu set it back to auto, to make sure they can be activated.
|
|
49
61
|
pointer-events: none;
|
|
50
62
|
row-gap: var(--ams-header-navigation-row-gap);
|
|
@@ -83,7 +95,6 @@
|
|
|
83
95
|
|
|
84
96
|
@mixin header-menu-action {
|
|
85
97
|
color: var(--ams-header-menu-item-color);
|
|
86
|
-
font-family: var(--ams-header-menu-item-font-family);
|
|
87
98
|
font-size: var(--ams-header-menu-item-font-size);
|
|
88
99
|
font-weight: var(--ams-header-menu-item-font-weight);
|
|
89
100
|
line-height: var(--ams-header-menu-item-line-height);
|
|
@@ -120,7 +131,7 @@
|
|
|
120
131
|
|
|
121
132
|
@mixin reset-button {
|
|
122
133
|
background: none;
|
|
123
|
-
border:
|
|
134
|
+
border: none;
|
|
124
135
|
margin-block: 0; // [1]
|
|
125
136
|
margin-inline: 0; // [1]
|
|
126
137
|
padding-inline: 0;
|
|
@@ -130,8 +141,9 @@
|
|
|
130
141
|
|
|
131
142
|
.ams-header__mega-menu-button {
|
|
132
143
|
column-gap: var(--ams-header-menu-item-column-gap);
|
|
133
|
-
cursor:
|
|
144
|
+
cursor: var(--ams-header-mega-menu-button-cursor);
|
|
134
145
|
display: grid;
|
|
146
|
+
font-family: inherit;
|
|
135
147
|
grid-auto-flow: column;
|
|
136
148
|
|
|
137
149
|
@include header-menu-action;
|
|
@@ -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
|
|
|
@@ -23,36 +23,36 @@
|
|
|
23
23
|
@include reset-hx;
|
|
24
24
|
}
|
|
25
25
|
|
|
26
|
-
.ams-heading--
|
|
27
|
-
font-size: var(--ams-heading-
|
|
28
|
-
line-height: var(--ams-heading-
|
|
26
|
+
.ams-heading--1 {
|
|
27
|
+
font-size: var(--ams-heading-1-font-size);
|
|
28
|
+
line-height: var(--ams-heading-1-line-height);
|
|
29
29
|
}
|
|
30
30
|
|
|
31
|
-
.ams-heading--
|
|
32
|
-
font-size: var(--ams-heading-
|
|
33
|
-
line-height: var(--ams-heading-
|
|
31
|
+
.ams-heading--2 {
|
|
32
|
+
font-size: var(--ams-heading-2-font-size);
|
|
33
|
+
line-height: var(--ams-heading-2-line-height);
|
|
34
34
|
}
|
|
35
35
|
|
|
36
|
-
.ams-heading--
|
|
37
|
-
font-size: var(--ams-heading-
|
|
38
|
-
line-height: var(--ams-heading-
|
|
36
|
+
.ams-heading--3 {
|
|
37
|
+
font-size: var(--ams-heading-3-font-size);
|
|
38
|
+
line-height: var(--ams-heading-3-line-height);
|
|
39
39
|
}
|
|
40
40
|
|
|
41
|
-
.ams-heading--
|
|
42
|
-
font-size: var(--ams-heading-
|
|
43
|
-
line-height: var(--ams-heading-
|
|
41
|
+
.ams-heading--4 {
|
|
42
|
+
font-size: var(--ams-heading-4-font-size);
|
|
43
|
+
line-height: var(--ams-heading-4-line-height);
|
|
44
44
|
}
|
|
45
45
|
|
|
46
|
-
.ams-heading--
|
|
47
|
-
font-size: var(--ams-heading-
|
|
48
|
-
line-height: var(--ams-heading-
|
|
46
|
+
.ams-heading--5 {
|
|
47
|
+
font-size: var(--ams-heading-5-font-size);
|
|
48
|
+
line-height: var(--ams-heading-5-line-height);
|
|
49
49
|
}
|
|
50
50
|
|
|
51
|
-
.ams-heading--
|
|
52
|
-
font-size: var(--ams-heading-
|
|
53
|
-
line-height: var(--ams-heading-
|
|
51
|
+
.ams-heading--6 {
|
|
52
|
+
font-size: var(--ams-heading-6-font-size);
|
|
53
|
+
line-height: var(--ams-heading-6-line-height);
|
|
54
54
|
}
|
|
55
55
|
|
|
56
|
-
.ams-heading--inverse
|
|
56
|
+
.ams-heading--inverse {
|
|
57
57
|
color: var(--ams-heading-inverse-color);
|
|
58
58
|
}
|
|
@@ -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,68 @@
|
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
6
|
.ams-icon {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
--ams-line-height: var(--ams-icon-line-height);
|
|
8
|
+
|
|
9
|
+
align-self: baseline; // Aligns the icon with text in flex or grid context
|
|
10
|
+
display: inline-flex; // Stretches the svg in order to align the icon vertically
|
|
11
|
+
font-size: var(--ams-icon-font-size);
|
|
12
|
+
line-height: var(--ams-line-height);
|
|
13
|
+
|
|
14
|
+
&::after {
|
|
15
|
+
content: "\00200B"; // This zero width space enables baseline alignment.
|
|
16
|
+
}
|
|
10
17
|
|
|
11
|
-
|
|
12
|
-
|
|
18
|
+
svg {
|
|
19
|
+
fill: currentColor;
|
|
20
|
+
inline-size: 1em;
|
|
21
|
+
}
|
|
13
22
|
}
|
|
14
23
|
|
|
15
|
-
.ams-icon--inverse
|
|
24
|
+
.ams-icon--inverse {
|
|
16
25
|
color: var(--ams-icon-inverse-color);
|
|
17
26
|
}
|
|
18
27
|
|
|
19
28
|
.ams-icon--square {
|
|
20
|
-
|
|
29
|
+
inline-size: calc(1em * var(--ams-line-height));
|
|
21
30
|
justify-content: center;
|
|
22
31
|
}
|
|
23
32
|
|
|
24
|
-
.ams-icon--
|
|
25
|
-
|
|
26
|
-
}
|
|
33
|
+
.ams-icon--small {
|
|
34
|
+
--ams-line-height: var(--ams-icon-small-line-height);
|
|
27
35
|
|
|
28
|
-
|
|
29
|
-
block-size: var(--ams-icon-size-3-font-size);
|
|
30
|
-
inline-size: var(--ams-icon-size-3-font-size);
|
|
36
|
+
font-size: var(--ams-icon-small-font-size);
|
|
31
37
|
}
|
|
32
38
|
|
|
33
|
-
.ams-icon--
|
|
34
|
-
|
|
35
|
-
}
|
|
39
|
+
.ams-icon--large {
|
|
40
|
+
--ams-line-height: var(--ams-icon-large-line-height);
|
|
36
41
|
|
|
37
|
-
|
|
38
|
-
block-size: var(--ams-icon-size-4-font-size);
|
|
39
|
-
inline-size: var(--ams-icon-size-4-font-size);
|
|
42
|
+
font-size: var(--ams-icon-large-font-size);
|
|
40
43
|
}
|
|
41
44
|
|
|
42
|
-
.ams-icon--
|
|
43
|
-
|
|
45
|
+
.ams-icon--heading-3 {
|
|
46
|
+
--ams-line-height: var(--ams-icon-heading-3-line-height);
|
|
47
|
+
|
|
48
|
+
font-size: var(--ams-icon-heading-3-font-size);
|
|
49
|
+
line-height: var(--ams-icon-heading-3-line-height);
|
|
44
50
|
}
|
|
45
51
|
|
|
46
|
-
.ams-icon--
|
|
47
|
-
|
|
48
|
-
|
|
52
|
+
.ams-icon--heading-4 {
|
|
53
|
+
--ams-line-height: var(--ams-icon-heading-4-line-height);
|
|
54
|
+
|
|
55
|
+
font-size: var(--ams-icon-heading-4-font-size);
|
|
56
|
+
line-height: var(--ams-icon-heading-4-line-height);
|
|
49
57
|
}
|
|
50
58
|
|
|
51
|
-
.ams-icon--
|
|
52
|
-
|
|
59
|
+
.ams-icon--heading-5 {
|
|
60
|
+
--ams-line-height: var(--ams-icon-heading-5-line-height);
|
|
61
|
+
|
|
62
|
+
font-size: var(--ams-icon-heading-5-font-size);
|
|
63
|
+
line-height: var(--ams-icon-heading-5-line-height);
|
|
53
64
|
}
|
|
54
65
|
|
|
55
|
-
.ams-icon--
|
|
56
|
-
|
|
57
|
-
|
|
66
|
+
.ams-icon--heading-6 {
|
|
67
|
+
--ams-line-height: var(--ams-icon-heading-6-line-height);
|
|
68
|
+
|
|
69
|
+
font-size: var(--ams-icon-heading-6-font-size);
|
|
70
|
+
line-height: var(--ams-icon-heading-6-line-height);
|
|
58
71
|
}
|
|
@@ -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
|
}
|