@amsterdam/design-system-css 0.3.0 → 0.4.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.
Files changed (85) hide show
  1. package/CHANGELOG.md +23 -0
  2. package/LICENSE.md +1 -1
  3. package/README.md +2 -1
  4. package/dist/alert/alert.css +1 -1
  5. package/dist/alert/alert.css.map +1 -1
  6. package/dist/badge/badge.css +1 -0
  7. package/dist/badge/badge.css.map +1 -0
  8. package/dist/dialog/dialog.css +1 -1
  9. package/dist/dialog/dialog.css.map +1 -1
  10. package/dist/grid/grid.css +1 -1
  11. package/dist/grid/grid.css.map +1 -1
  12. package/dist/icon/icon.css +1 -1
  13. package/dist/icon/icon.css.map +1 -1
  14. package/dist/icon-button/icon-button.css +1 -0
  15. package/dist/icon-button/icon-button.css.map +1 -0
  16. package/dist/index.css +1 -1
  17. package/dist/index.css.map +1 -1
  18. package/dist/link-list/link-list.css +1 -0
  19. package/dist/link-list/link-list.css.map +1 -0
  20. package/dist/mega-menu/mega-menu.css +1 -0
  21. package/dist/mega-menu/mega-menu.css.map +1 -0
  22. package/dist/search-field/search-field.css +1 -1
  23. package/dist/search-field/search-field.css.map +1 -1
  24. package/dist/spotlight/spotlight.css +1 -1
  25. package/dist/spotlight/spotlight.css.map +1 -1
  26. package/dist/table/table.css +1 -0
  27. package/dist/table/table.css.map +1 -0
  28. package/documentation/coding-conventions.md +4 -2
  29. package/package.json +4 -4
  30. package/src/components/accordion/README.md +45 -38
  31. package/src/components/alert/README.md +15 -11
  32. package/src/components/alert/alert.scss +8 -38
  33. package/src/components/aspect-ratio/README.md +12 -12
  34. package/src/components/badge/README.md +10 -0
  35. package/src/components/badge/badge.scss +58 -0
  36. package/src/components/blockquote/README.md +8 -8
  37. package/src/components/breadcrumb/README.md +10 -7
  38. package/src/components/button/README.md +17 -14
  39. package/src/components/card/README.md +18 -19
  40. package/src/components/checkbox/README.md +19 -18
  41. package/src/components/dialog/README.md +9 -8
  42. package/src/components/dialog/dialog.scss +0 -16
  43. package/src/components/footer/README.md +11 -7
  44. package/src/components/form-label/README.md +5 -1
  45. package/src/components/grid/README.md +12 -13
  46. package/src/components/grid/grid.scss +4 -0
  47. package/src/components/header/README.md +2 -2
  48. package/src/components/heading/README.md +14 -11
  49. package/src/components/icon/README.md +19 -9
  50. package/src/components/icon/icon.scss +5 -0
  51. package/src/components/icon-button/README.md +14 -0
  52. package/src/components/icon-button/icon-button.scss +60 -0
  53. package/src/components/image/README.md +16 -17
  54. package/src/components/index.scss +5 -0
  55. package/src/components/link/README.md +26 -24
  56. package/src/components/link-list/README.md +16 -0
  57. package/src/components/link-list/link-list.scss +80 -0
  58. package/src/components/logo/README.md +21 -20
  59. package/src/components/mark/README.md +10 -11
  60. package/src/components/mega-menu/README.md +1 -0
  61. package/src/components/mega-menu/mega-menu.scss +14 -0
  62. package/src/components/ordered-list/README.md +5 -5
  63. package/src/components/overlap/README.md +1 -1
  64. package/src/components/page-heading/README.md +10 -9
  65. package/src/components/page-menu/README.md +10 -9
  66. package/src/components/pagination/README.md +13 -10
  67. package/src/components/paragraph/README.md +16 -14
  68. package/src/components/screen/README.md +12 -12
  69. package/src/components/search-field/README.md +18 -18
  70. package/src/components/search-field/search-field.scss +2 -10
  71. package/src/components/skip-link/README.md +18 -25
  72. package/src/components/spotlight/README.md +5 -5
  73. package/src/components/spotlight/spotlight.scss +4 -4
  74. package/src/components/switch/README.md +11 -9
  75. package/src/components/table/README.md +11 -0
  76. package/src/components/table/table.scss +36 -0
  77. package/src/components/text-input/README.md +10 -8
  78. package/src/components/top-task-link/README.md +15 -14
  79. package/src/components/unordered-list/README.md +5 -5
  80. package/src/components/visually-hidden/README.md +3 -2
  81. package/src/components/button/button-css.md +0 -12
  82. package/src/components/checkbox/checkbox-css.md +0 -3
  83. package/src/components/footer/footer-css.md +0 -11
  84. package/src/components/heading/heading-css.md +0 -3
  85. package/src/components/paragraph/paragraph-css.md +0 -3
@@ -1,25 +1,24 @@
1
1
  # Card
2
2
 
3
- Gebruik een card op een overzichtspagina om te verwijzen naar een detailpagina,
4
- zoals een nieuwsbericht, een vacature of een zoekresultaat.
5
- De card bevat meestal de titel, introductie en afbeelding van de content.
6
- De link is verplicht.
3
+ Use a card on an overview page to link to an article page, such as a news article, a job vacancy, or a search result.
4
+ The card typically includes the title, introduction, and an image of the content.
5
+ The link is mandatory.
7
6
 
8
- ## Richtlijnen
7
+ ## Guidelines
9
8
 
10
- - De titel van een card is een link in een heading.
11
- Hier gelden dezelfde richtlijnen voor als voor reguliere [links](?path=/docs/react_navigation-link--docs) en [headings](?path=/docs/react_text-heading--docs).
12
- De link is actief op het hele gebied van de card.
13
- - Een card heeft meer inhoud nodig dan alleen een titel.
14
- Vul dit aan met tekstuele en/of visuele inhoud.
15
- - De tekst zet je in een reguliere paragraaf.
16
- Alleen voor een tagline of datum gebruik je de kleinste tekstgrootte.
17
- - Als de inhoud geen detailpagina vertegenwoordigt is dit component niet de beste optie.
18
- Om te verwijzen naar een thematische pagina gebruik je een [top task link](?path=/docs/react_navigation-top-task-link--docs).
19
- Ook kun je een [reguliere link](?path=/docs/react_navigation-link--docs) inzetten.
9
+ - The title of a card is a link within a heading.
10
+ The same guidelines as for regular [links](?path=/docs/react_navigation-link--docs) and [headings](?path=/docs/react_text-heading--docs) apply here.
11
+ The link is active across the entire area of the card.
12
+ - A card needs more content than just a title.
13
+ Supplement this with textual and/or visual content.
14
+ - Place the text in a regular paragraph.
15
+ Only use the smallest text size for a tagline or date.
16
+ - This component may not be the best option if the content does not represent a detailed page.
17
+ For referencing a thematic page, use a [top task link](?path=/docs/react_navigation-top-task-link--docs).
18
+ You can also use a [regular link](?path=/docs/react_navigation-link--docs).
20
19
 
21
- ## Schermlezers
20
+ ## Screen Readers
22
21
 
23
- Met een schermlezer kun je onder andere navigeren via headings en links in een document.
24
- De titel van een card is een link in een heading, zodat je van beide navigatiemanieren gebruik kunt maken.
25
- Een schermlezer leest eerst de titel op, daarna de rest van de inhoud.
22
+ With a screen reader, you can navigate using headings and links in a document.
23
+ The title of a card is a link within a heading, allowing you to utilize both navigation methods.
24
+ A screen reader reads the title first, followed by the rest of the content.
@@ -1,27 +1,28 @@
1
1
  # Checkbox
2
2
 
3
- De checkbox (in het Nederlands: selectievakje) wordt gebruikt om gebruikers een selectie te laten maken. Hij wordt ook gebruikt om gebruikers te laten weten dat ze akkoord gaan met specifieke voorwaarden.
3
+ Allows users to make a selection or agree to terms.
4
4
 
5
- ## Richtlijnen
5
+ ## Guidelines
6
6
 
7
- - Selectievakjes worden gebruikt voor 1 of meerdere keuzes die elkaar niet uitsluiten.
8
- - Elk selectievakje werkt onafhankelijk van andere selectievakjes in een lijst op hetzelfde hiërarchische niveau. Het aanvinken van een extra vakje heeft geen invloed op andere selecties in die lijst.
9
- - Je kunt een selectievakje wel gebruiken voor een bulkselectie of –deselectie van een hele lijst met selectievakjes, maar dan moet duidelijk zijn dat het bulkselectievakje op een ander hiërarchisch niveau zit dan de lijst die volledig wordt geselecteerd of gedeselecteerd.
10
- - Een groep selectievakjes kan worden gebruikt om gegevens op een pagina, in een menu of binnen een component te filteren.
11
- - Een selectievakje kan een antwoord op een gesloten vraag zijn, als er meerdere antwoorden mogelijk zijn.
12
- - Een lijst van selectievakjes is verticaal gestapeld om leesbaarheid en bruikbaarheid te bevorderen.
13
- - Een lijst van selectievakjes moet in een `fieldset` zitten, met een `legend` die beschrijft waar de lijst over gaat. Als de selectievakjes bijvoorbeeld worden gebruikt om antwoord op een vraag te krijgen, dan is de `legend` de vraag.
7
+ - Checkboxes are used for one or multiple choices that do not exclude each other.
8
+ - Each checkbox operates independently of other checkboxes in a list at the same hierarchical level.
9
+ Checking an additional checkbox does not affect other selections in that list.
10
+ - You can use a checkbox for bulk selection or deselection of an entire list of checkboxes.
11
+ Still, it should be clear that the bulk selection checkbox is at a different hierarchical level than the list being fully selected or deselected.
12
+ - Use a group of checkboxes to filter data on a page, in a menu, or within a component.
13
+ - A checkbox can answer a closed question if multiple answers are possible.
14
+ - A list of checkboxes is vertically stacked to enhance readability and usability.
15
+ - A list of checkboxes should be in a `fieldset` with a `legend` describing what the list is about.
16
+ For example, if the checkboxes are used to get answers to a question, the `legend` is the question.
14
17
 
15
- ## Checkbox labels
18
+ ## Checkbox Labels
16
19
 
17
- Een label:
20
+ A label starts with a capital letter.
21
+ It does not have punctuation at the end if it is a single sentence, word, or fragment.
22
+ It is written in the first person when asking the user to agree to the terms and conditions.
18
23
 
19
- - ... begint met een hoofdletter
20
- - ... heeft geen interpunctie aan het einde als het een enkele zin, woord of fragment is.
21
- - ... is in de eerste persoon geschreven als het gaat om de vraag of de gebruiker akkoord gaat met de algemene voorwaarden
24
+ ## Relevant WCAG Requirements
22
25
 
23
- ## Relevante WCAG eisen
26
+ - [WCAG 1.3.5](https://www.w3.org/WAI/WCAG21/Understanding/identify-input-purpose.html): It is clear for both users and programmatically what the purpose of a form field is.
24
27
 
25
- - [WCAG 1.3.5](https://www.w3.org/WAI/WCAG21/Understanding/identify-input-purpose.html): het is zowel voor een gebruiker als programmatisch duidelijk wat het doel van een formulierveld is.
26
-
27
- Checkbox is een interactief element, hier gelden [de algemene eisen en richtlijnen voor interactieve elementen](https://amsterdam.github.io/design-system/?path=/docs/docs-designrichtlijnen-interactieve-elementen--docs) voor.
28
+ Checkbox is an interactive element; therefore, [the general requirements and guidelines for interactive elements](https://amsterdam.github.io/design-system/?path=/docs/docs-designrichtlijnen-interactieve-elementen--docs) apply.
@@ -1,19 +1,20 @@
1
1
  # Dialog
2
2
 
3
- A Dialog allows the user to focus on one task or a piece of information, by popping-up and blocking the page content until the modal task is completed, or until the user dismisses the action.
3
+ A Dialog allows the user to focus on one task or a piece of information by popping up and blocking the page content until the modal task is completed or until the user dismisses the action.
4
4
 
5
5
  ## Guidelines
6
6
 
7
- - Use Dialog sparingly, because it interrupts the user's workflow.
8
- - Use Dialog for short and non-frequent tasks. For common tasks consider using the main flow.
7
+ - Use dialogs sparingly because they interrupt the users workflow.
8
+ - Use a dialog for short and non-frequent tasks.
9
+ Consider using the main flow for regular tasks.
9
10
 
10
11
  ## Keyboard Support
11
12
 
12
- | key | function |
13
- | :---------- | :----------------------------------------------------------- |
14
- | Tab | Moves focus to next focusable element inside the dialog. |
15
- | Shift + Tab | Moves focus to previous focusable element inside the dialog. |
16
- | Escape | Closes the dialog. |
13
+ | key | function |
14
+ | :---------- | :--------------------------------------------------------------- |
15
+ | Tab | Moves focus to the next focusable element inside the dialog. |
16
+ | Shift + Tab | Moves focus to the previous focusable element inside the dialog. |
17
+ | Escape | Closes the dialog. |
17
18
 
18
19
  ## References
19
20
 
@@ -74,19 +74,3 @@
74
74
  justify-content: end;
75
75
  }
76
76
  }
77
-
78
- .amsterdam-dialog__close {
79
- background-color: var(--amsterdam-dialog-close-background-color);
80
- border: 0;
81
- cursor: pointer;
82
- padding-block: 0;
83
- padding-inline: 0;
84
- }
85
-
86
- .amsterdam-dialog__close svg {
87
- fill: var(--amsterdam-dialog-close-fill);
88
- }
89
-
90
- .amsterdam-dialog__close:hover svg {
91
- fill: var(--amsterdam-dialog-close-hover-fill);
92
- }
@@ -1,11 +1,15 @@
1
1
  # Footer
2
2
 
3
- De footer (in het Nederlands: voettekst) sluit iedere webpagina af. De inhoud is service-informatie. Een gedeelte is voorgeschreven en een deel wordt ingevuld vanuit de doelstelling van de website.
3
+ The footer is the closing section on every web page.
4
+ Its content provides service information.
5
+ A part is prescribed, and a part is filled based on the website’s objectives.
4
6
 
5
- ## Richtlijnen
7
+ ## Guidelines
6
8
 
7
- - De voettekst is verplicht, er staat er 1 op elke pagina.
8
- - De eerste kolom richt zich op contactinformatie. De informatie is zo specifiek mogelijk gebonden aan de betreffende website of pagina (bijvoorbeeld een chatmogelijkheid indien aanwezig).
9
- - De tweede kolom bevat links naar relevante (online) sites of bronnen.
10
- - De derde kolom verwijst naar nieuwsbrieven, socials enz.
11
- - Het laatste deel van de voettekst is bedoeld voor koppelingen naar privacy, cookieverklaring, uitleg over de website e.d. Het is niet bedoeld voor koppelingen naar bijvoorbeeld contactinformatie.
9
+ - The footer is mandatory, and there is one on every page.
10
+ - The first column focuses on contact information.
11
+ The information is as specific as possible and tailored to the respective website or page (e.g., including a chat option if available).
12
+ - The second column contains links to relevant (online) sites or sources.
13
+ - The third column refers to newsletters, social media, etc.
14
+ - The last part of the footer is intended for links to privacy policies, cookie statements, explanations about the website, etc.
15
+ It is not intended for links to contact information, for example.
@@ -1,3 +1,7 @@
1
1
  # Form Label
2
2
 
3
- Een label element gebruik je om een formulierelement te beschrijven. Koppel een formulierelement (zoals een `input` of `textarea`) altijd aan een label.
3
+ Describes a form control.
4
+
5
+ ## Guidelines
6
+
7
+ Always associate a form element (such as an `input` or `textarea`) with a label.
@@ -1,21 +1,20 @@
1
1
  # Grid
2
2
 
3
- Verdeelt de breedte van het scherm in kolommen waarop de elementen van een pagina worden uitgelijnd.
3
+ Divides the screen into columns to align the elements of a page.
4
4
 
5
- ## Gebruik
5
+ ## Usage
6
6
 
7
- Elke pagina moet het grid gebruiken als basis voor de layout.
8
- Het staat dus direct binnen [Screen](?path=/docs/layout-screen--docs).
7
+ Every page should use the grid as the foundation for its layout.
8
+ It is placed directly within the [Screen](?path=/docs/layout-screen--docs).
9
9
 
10
- Een [Footer](?path=/docs/react_containers-footer--docs) en een [Highlight](?path=/docs/react_containers-highlight--docs) zijn iets breder dan het grid.
11
- Vóór deze componenten sluit je een instantie van het grid af.
12
- Erbinnen en eventueel erna start je een nieuwe.
13
- Meerdere instanties van het grid component zijn dus mogelijk op een pagina.
14
- De kolommen van alle grids moeten wel precies op elkaar aansluiten.
10
+ A [Footer](?path=/docs/react_containers-footer--docs) and a [Spotlight](?path=/docs/react_containers-spotlight--docs) are slightly wider than the grid.
11
+ You close one instance of the grid before these components.
12
+ Inside and optionally after them, you start a new one.
13
+ Multiple instances of the grid component are possible on a page, but the columns of all grids must align precisely.
15
14
 
16
- Binnen het grid maak je cellen die de gewenste inhoud bevatten.
17
- Een cel beslaat vaak meerdere kolommen van het grid.
15
+ Within the grid, you create cells containing the desired content.
16
+ A cell often spans multiple columns of the grid.
18
17
 
19
- ## Ontwerp
18
+ ## Design
20
19
 
21
- De [ontwerpkeuzes](?path=/docs/docs-designrichtlijnen-grid--docs) staan beschreven onder de designrichtlijnen.
20
+ The [design choices](?path=/docs/docs-designrichtlijnen-grid--docs) are described in the design guidelines.
@@ -28,6 +28,10 @@
28
28
  --amsterdam-grid-padding-inline: var(--amsterdam-grid-compact-padding-inline);
29
29
  }
30
30
 
31
+ .amsterdam-grid--gap-vertical--none {
32
+ row-gap: initial;
33
+ }
34
+
31
35
  .amsterdam-grid--gap-vertical--small {
32
36
  row-gap: calc(var(--amsterdam-grid-gap) / 2);
33
37
  }
@@ -1,12 +1,12 @@
1
1
  # Header
2
2
 
3
- A Header offers a container to display a City of Amsterdam logo, subsite title and page menu.
3
+ Arranges the City’s logo, the title of the website, and a page menu.
4
4
 
5
5
  ## Guidelines
6
6
 
7
7
  - Use the Header when the site is hosted on amsterdam.nl or one of its subdomains.
8
8
  - The page menu can contain a maximum of 5 items, including menu and search.
9
- - When you have a long subsite title, use no or as little page menu items as possible.
9
+ - When you have a long subsite title, use no or as few page menu items as possible.
10
10
 
11
11
  ## References
12
12
 
@@ -1,22 +1,25 @@
1
1
  # Heading
2
2
 
3
- Een heading zegt iets over de onderstaande content. Met behulp van headings kan de gebruiker snel een overzicht krijgen van de structuur van de webpagina.
3
+ A heading conveys information about the content below it.
4
+ Use headings to allow the user to grasp the structure of the page quickly.
4
5
 
5
- ## Richtlijnen
6
+ ## Guidelines
6
7
 
7
- - Een heading omschrijft de content eronder.
8
- - Gebruik een heading niet voor opmaak en styling, maar om de structuur van de pagina weer te geven.
9
- - Gebruik headings hierarchisch en sla geen heading niveaus over. Dus na een `h1` volgt een `h2` en dus niet een `h3`.
8
+ - A heading describes the content beneath it.
9
+ - Do not use a heading for formatting and styling. Use it to represent the page’s structure.
10
+ - Use headings hierarchically, and do not skip heading levels.
11
+ So, an `h1` heading should be followed by an `h2`, not an `h3`.
10
12
 
11
- ## Relevante WCAG eisen
13
+ ## Relevant WCAG Requirements
12
14
 
13
15
  - [WCAG 1.3.1](https://www.w3.org/WAI/WCAG21/quickref/#qr-content-structure-separation-programmatic):
14
- Tekst die er uit ziet als een heading wordt ook door een computer herkend als een heading. Door gebruik te maken van het juiste heading niveau is voor alle gebruikers duidelijk hoe de pagina is gestructeerd.
15
- - [WCAG 2.4.1](https://www.w3.org/WAI/WCAG21/quickref/#qr-navigation-mechanisms-skip): Headings kunnen gebruikt worden om naar een volgende sectie te navigeren met het toetsenbord
16
- - [WCAG 2.4.6](https://www.w3.org/WAI/WCAG21/quickref/#headings-and-labels): Beschrijf met headings het doel of het onderwerp van de onderliggende content
17
- - [WCAG 2.4.10](https://www.w3.org/WAI/WCAG21/quickref/#qr-navigation-mechanisms-headings): Gebruik headings om de content te structureren
16
+ Text that looks like a heading is also recognized as a heading by a computer.
17
+ Using the correct heading level makes the page structure clear for all users.
18
+ - [WCAG 2.4.1](https://www.w3.org/WAI/WCAG21/quickref/#qr-navigation-mechanisms-skip): Headings can be used to navigate to the next section with the keyboard.
19
+ - [WCAG 2.4.6](https://www.w3.org/WAI/WCAG21/quickref/#headings-and-labels): Use headings to describe the purpose or subject of the underlying content.
20
+ - [WCAG 2.4.10](https://www.w3.org/WAI/WCAG21/quickref/#qr-navigation-mechanisms-headings): Use headings to structure the content.
18
21
 
19
- ## Referenties
22
+ ## References
20
23
 
21
24
  - [W3C - Headings](https://www.w3.org/WAI/tutorials/page-structure/headings/)
22
25
  - [W3C - Headings & labels](https://www.w3.org/TR/WCAG21/#headings-and-labels)
@@ -1,19 +1,29 @@
1
1
  # Icon
2
2
 
3
- Iconen zijn visuele symbolen die worden gebruikt om ideeën, thema’s of acties weer te geven. Ze communiceren in één oogopslag de boodschap en vestigen de aandacht op belangrijke (interactieve) informatie. Gebruik altijd een `Icon` component om een SVG icoon heen voor de juiste vormgeving en maatvoering.
3
+ Icons are visual symbols used to represent ideas, themes, or actions.
4
+ They communicate the message at a glance and draw attention to important (interactive) information.
5
+ Always use an `Icon` component to encapsulate an SVG icon for proper styling and sizing.
4
6
 
5
- ## Interactieve elementen
7
+ ## Interactive Elements
6
8
 
7
- Ter ondersteuning van tekstuele interactie-elementen, zoals knoppen en links, kunnen iconen gebruikt worden. Probeer altijd een icoon te voorzien van begeleidende tekst. Iconen zonder begeleidende tekst mogen alleen gebruikt worden als ze aan internationale standaarden voldoen, zoals menu (hamburger icoon), zoek (vergrootglas), volgende, vorige, play, pauze, enz.
9
+ Use an icon to support textual interactive elements like buttons and links.
10
+ Always try to provide accompanying text for an icon.
11
+ 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.
8
12
 
9
- ## Kleur
13
+ ## Color
10
14
 
11
- Iconen zijn zwart of wit. Bij interactie zijn ze donkerblauw. Uitgeschakeld zijn ze grijs. En ze moeten voldoen aan dezelfde contrastverhouding voor toegankelijkheid als typografie bij een achtergrondkleur. Het icoon neemt standaard de kleur van de _container_ waar deze in zit over.
15
+ Icons are black or white.
16
+ When used as part of an interactive element, they are dark blue.
17
+ When disabled, they are grey.
18
+ They must adhere to the same contrast ratio for accessibility as typography against a background colour.
19
+ The icon defaults to the colour of the container it is in.
12
20
 
13
- ## Uitlijning
21
+ ## Alignment
14
22
 
15
- Iconen staan standaard links van de tekst en zijn verticaal in het midden van de eerste regel tekst uitgelijnd.
23
+ Icons are aligned to the left of the text by default and vertically centred to the middle of the first line of text.
16
24
 
17
- ## Grootte
25
+ ## Size
18
26
 
19
- De iconen gebruiken dezelfde tekstniveaus als alle typografische componenten om hun grootte te bepalen. Hierdoor zijn icoon en tekst makkelijk op elkaar af te stemmen. [Bekijk de documentatie over typografie voor meer informatie](/docs/docs-designrichtlijnen-typografie--docs#tekstniveaus).
27
+ Icons use the same text levels as all typographic components to determine their size.
28
+ This ensures easy alignment between icons and text.
29
+ [Refer to the typography documentation for more information](/docs/docs-designrichtlijnen-typografie--docs#tekstniveaus).
@@ -12,6 +12,11 @@
12
12
  fill: currentColor;
13
13
  }
14
14
 
15
+ .amsterdam-icon--square {
16
+ aspect-ratio: 1 / 1;
17
+ justify-content: center;
18
+ }
19
+
15
20
  .amsterdam-icon--size-3 {
16
21
  height: calc(var(--amsterdam-icon-spacious-size-3-font-size) * var(--amsterdam-icon-spacious-size-3-line-height));
17
22
  }
@@ -0,0 +1,14 @@
1
+ # Icon Button
2
+
3
+ A button containing only an icon.
4
+
5
+ ## Guidelines
6
+
7
+ - Use this button only if the icon is entirely clear and understandable.
8
+ Many icons are interpreted differently by different users.
9
+ Only use universally recognized icons, such as a close icon or a play icon.
10
+ - Provide a label text that describes what the button does for screen reader users.
11
+
12
+ ## Relevant WCAG Requirements
13
+
14
+ The Icon Button follows [the same requirements and guidelines as a regular button](https://amsterdam.github.io/design-system/?path=/docs/react_buttons-button--docs).
@@ -0,0 +1,60 @@
1
+ /**
2
+ * @license EUPL-1.2+
3
+ * Copyright (c) 2023 Gemeente Amsterdam
4
+ */
5
+
6
+ @mixin reset {
7
+ border: 0;
8
+ padding-block: 0;
9
+ padding-inline: 0;
10
+ }
11
+
12
+ .amsterdam-icon-button {
13
+ background-color: transparent;
14
+ color: var(--amsterdam-icon-button-color);
15
+ cursor: pointer;
16
+ outline-offset: var(--amsterdam-icon-button-outline-offset);
17
+ touch-action: manipulation;
18
+
19
+ &:hover {
20
+ background-color: var(--amsterdam-icon-button-hover-background-color);
21
+ color: var(--amsterdam-icon-button-hover-color);
22
+ }
23
+
24
+ &:disabled {
25
+ background-color: transparent;
26
+ color: var(--amsterdam-icon-button-disabled-color);
27
+ cursor: not-allowed;
28
+ }
29
+
30
+ @include reset;
31
+ }
32
+
33
+ .amsterdam-icon-button--on-background-light {
34
+ color: var(--amsterdam-icon-button-on-background-light-color);
35
+
36
+ &:hover {
37
+ background-color: var(--amsterdam-icon-button-on-background-light-hover-background-color);
38
+ color: var(--amsterdam-icon-button-on-background-light-hover-color);
39
+ }
40
+
41
+ &:disabled {
42
+ background-color: transparent;
43
+ color: var(--amsterdam-icon-button-on-background-light-disabled-color);
44
+ }
45
+ }
46
+
47
+ .amsterdam-icon-button--on-background-dark {
48
+ background-color: var(--amsterdam-icon-button-on-background-dark-background-color);
49
+ color: var(--amsterdam-icon-button-on-background-dark-color);
50
+
51
+ &:hover {
52
+ background-color: var(--amsterdam-icon-button-on-background-dark-hover-background-color);
53
+ color: var(--amsterdam-icon-button-on-background-dark-hover-color);
54
+ }
55
+
56
+ &:disabled {
57
+ background-color: var(--amsterdam-icon-button-on-background-dark-disabled-background-color);
58
+ color: var(--amsterdam-icon-button-on-background-dark-disabled-color);
59
+ }
60
+ }
@@ -1,23 +1,22 @@
1
1
  # Image
2
2
 
3
- Toont een afbeelding.
3
+ Displays an image.
4
4
 
5
- ## Richtlijnen
5
+ ## Guidelines
6
6
 
7
- - Vergeet niet om een beschrijving van de afbeelding op te nemen in het `alt`-attribuut.
8
- Dit zorgt ervoor dat gebruikers van schermlezers deze informatie ook tot zich kunnen nemen.
9
- Daarnaast kan het helpen bij zoekmachineoptimalisatie.
10
- Alleen voor decoratieve afbeeldingen is zo’n beschrijving niet nodig. Gebruik in dit geval `alt=""`.
11
- Denk aan afbeeldingen die weinig toevoegen aan de nabije tekst of afbeeldingen die louter bijdragen aan het ontwerp of de sfeer van de pagina (bron: [W3C Web Accessibility Initiative](https://www.w3.org/WAI/tutorials/images/decorative/)).
12
- - Specificeer eventueel meerdere kandidaten voor de afbeelding via het `srcSet`-attribuut.
13
- Bijvoorbeeld een kleine, middelgrote en grote variant voor de diverse schermformaten.
14
- Zo voorkom je het onnodige downloaden van grote bestanden.
15
- Doe dit vooral voor de hoofdafbeelding van een pagina,
16
- daar is het verschil tussen de formaten op een smal en breed scherm het grootst.
17
- - Zorg ervoor dat de afbeelding een beeldverhouding heeft die ondersteund wordt door het [Aspect Ratio](?path=/docs/layout-aspect-ratio--docs) component.
7
+ - Do not forget to include a description of the image in the `alt` attribute.
8
+ This ensures that screen reader users can also access this information.
9
+ Additionally, it can aid in search engine optimization.
10
+ - A description is unnecessary for decorative images; use `alt=""` for these.
11
+ Examples are images that add little to the nearby text or pictures that purely contribute to the design or atmosphere of the page (source: [W3C Web Accessibility Initiative](https://www.w3.org/WAI/tutorials/images/decorative/)).
12
+ - Optionally specify multiple candidates for the image through the `srcSet` attribute.
13
+ For example, provide small, medium, and large variants for various screen sizes.
14
+ This prevents unnecessary downloading of large files.
15
+ Do this especially for the main image of a page, where the difference between sizes on a narrow and wide screen is most significant.
16
+ - Ensure that the aspect ratio of the image is supported by the [Aspect Ratio](?path=/docs/layout-aspect-ratio--docs) component.
18
17
 
19
- ## Relevante WCAG-eisen
18
+ ## Relevant WCAG Requirements
20
19
 
21
- - [WCAG 1.1.1](https://www.w3.org/TR/WCAG22/#non-text-content): niet-tekstuele content heeft een tekstueel alternatief
22
- - [WCAG 1.4.5](https://www.w3.org/TR/WCAG22/#images-of-text): gebruik tekst in plaats van afbeeldingen van tekst
23
- - [WCAG 1.4.9](https://www.w3.org/TR/WCAG22/#images-of-text-no-exception): gebruik afbeeldingen van tekst alleen als er geen alternatief is
20
+ - [WCAG 1.1.1](https://www.w3.org/TR/WCAG22/#non-text-content): Non-text content must have a text alternative.
21
+ - [WCAG 1.4.5](https://www.w3.org/TR/WCAG22/#images-of-text): Use text instead of images of text.
22
+ - [WCAG 1.4.9](https://www.w3.org/TR/WCAG22/#images-of-text-no-exception): Use images of text only when there is no alternative.
@@ -4,6 +4,11 @@
4
4
  */
5
5
 
6
6
  /* Append here */
7
+ @import "./link-list/link-list";
8
+ @import "./badge/badge";
9
+ @import "./table/table";
10
+ @import "./mega-menu/mega-menu";
11
+ @import "./icon-button/icon-button";
7
12
  @import "./skip-link/skip-link";
8
13
  @import "./overlap/overlap";
9
14
  @import "./header/header";
@@ -1,42 +1,44 @@
1
1
  # Link
2
2
 
3
- Een link (in het Nederlands: koppeling) wordt gebruikt als navigatie-element en kan op zichzelf of inline met tekst worden gebruikt. Het is de lichtgewicht variant voor navigatie.
3
+ A link is a navigation element and can be used independently or inline with text.
4
+ It is the lightweight variant for navigation.
4
5
 
5
- ## Richtlijnen
6
+ ## Guidelines
6
7
 
7
- Gebruik een link in de volgende gevallen:
8
+ Use a link in the following cases:
8
9
 
9
- - Navigatie naar een andere pagina binnen de website of applicatie
10
- - Navigatie naar een andere website (zie [Externe links](#externe-links))
11
- - Navigatie naar een element op dezelfde pagina
12
- - Koppeling naar e-mails of telefoonnummers (begin de link met `mailto:` of `tel:`)
10
+ - To navigate to another page within the website or application
11
+ - To navigate to another website (see [External links](#external-links))
12
+ - To navigate to an element on the same page
13
+ - To link to emails or phone numbers (start the link with `mailto:` or `tel:`)
13
14
 
14
- Een link is een navigatie component. Gebruik een knop in plaats van een link als er een actie gewenst is.
15
+ A link is a navigation component.
16
+ Use a button instead of a link when an action is desired.
15
17
 
16
- <!--
17
- TODO: According to the spec, you should use a link for downloads as well. Last time I checked, different browsers handled this differently,
18
- which led to unexpected results. Maybe that changed in the meantime. Do we want to figure this out and describe this in the docs as well?
19
- -->
18
+ ### External links
20
19
 
21
- ### Externe links
20
+ Always include `rel="external"` for an external link.
21
+ Avoid `target="_blank"`, but use `rel="external noopener"` if necessary.
22
+ For more information: [Links to cross-origin destinations are unsafe](https://developer.chrome.com/docs/lighthouse/best-practices/external-anchors-use-rel-noopener/)
22
23
 
23
- Geef een externe link altijd `rel="external"` mee. Vermijd `target="_blank"`, maar gebruik in ieder geval `rel="external noopener"` als het moet. Voor meer informatie: [Links to cross-origin destinations are unsafe](https://developer.chrome.com/docs/lighthouse/best-practices/external-anchors-use-rel-noopener/)
24
+ ### Visited style
24
25
 
25
- ### Bezochte stijl
26
+ Visited links indicate that a user has already opened the link.
27
+ We discourage using styles for visited links because they often make the page less clear and navigation more challenging.
28
+ The inline link does have a visited style.
29
+ It is not part of navigation elements that are frequently scanned.
26
30
 
27
- Bezochte koppelingen geven aan dat een gebruiker de koppeling al heeft geopend. Gebruikte stijlen raden we af bij koppelingen, omdat ze de pagina vaak onoverzichtelijk maken. Het maakt navigeren door een pagina moeilijker. De inline koppeling heeft wel een bezochte stijl. Het vormt geen onderdeel van navigatie elementen die veel gescand worden.
28
-
29
- ## Relevante WCAG eisen
31
+ ## Relevant WCAG Requirements
30
32
 
31
33
  - [WCAG 1.4.3](https://www.w3.org/TR/WCAG21/#contrast-minimum)
32
34
  - [WCAG 2.4.4](https://www.w3.org/TR/WCAG21/#link-purpose-in-context)
33
35
  - [WCAG 2.5.3](https://www.w3.org/TR/WCAG21/#label-in-name)
34
36
  - [WCAG 3.1.2](https://www.w3.org/TR/WCAG21/#language-of-parts)
35
37
 
36
- ## Referenties
38
+ ## References
37
39
 
38
- - [Links to cross-origin destinations are unsafe](https://developer.chrome.com/docs/lighthouse/best-practices/external-anchors-use-rel-noopener/): Vermijd `target="_blank"` of gebruik `rel="external noopener"` als het moet.
39
- - [_A comprehensive guide to designing perfect links in UX_, op Prototypr](https://blog.prototypr.io/a-guide-to-designing-perfect-links-in-ux-414558f35730): best practices rondom links.
40
- - [_Writing Hyperlinks: Salient, Descriptive, Start with Keyword_ door Norman Nielsen Group](https://www.nngroup.com/articles/writing-links/): hoe schrijf je goede links? Een uitgebreid artikel over links.
41
- - [_Hover, focus, active_, door Wunder](https://wunder.io/wunderpedia/accessibility/accessible-uis/hover-focus-active/): goede uitleg over de states die elementen zoals de link en button hebben in browsers.
42
- - [MDN: `<a>`: The Anchor element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a): uitgebreid overzicht van alle mogelijkheden van links in HTML.
40
+ - [Links to cross-origin destinations are unsafe](https://developer.chrome.com/docs/lighthouse/best-practices/external-anchors-use-rel-noopener/): Avoid `target="_blank"` or use `rel="external noopener"` if necessary.
41
+ - [_A comprehensive guide to designing perfect links in UX_, on Prototypr](https://blog.prototypr.io/a-guide-to-designing-perfect-links-in-ux-414558f35730): Best practices for links.
42
+ - [_Writing Hyperlinks: Salient, Descriptive, Start with Keyword_ by Norman Nielsen Group](https://www.nngroup.com/articles/writing-links/): How to write good links? An extensive article on links.
43
+ - [_Hover, focus, active_, by Wunder](https://wunder.io/wunderpedia/accessibility/accessible-uis/hover-focus-active/): A good explanation of the states that elements like links and buttons have in browsers.
44
+ - [MDN: `<a>`: The Anchor element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a): Comprehensive overview of all possibilities of links in HTML.
@@ -0,0 +1,16 @@
1
+ # Link List
2
+
3
+ A collection of related links.
4
+
5
+ ## Design
6
+
7
+ Every list item starts with a chevron.
8
+ It emphasizes the list structure and thematic coherence.
9
+ The chevron is part of the link.
10
+ Therefore, it is blue and clickable.
11
+
12
+ ## Guidelines
13
+
14
+ Use a Link List to present multiple links within a theme.
15
+
16
+ For additional guidelines, refer to the [Link](?path=/docs/navigation-link--docs) component.