@gemeente-denhaag/alert 0.1.1-alpha.16 → 0.1.1-alpha.17

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 (2) hide show
  1. package/README.md +15 -11
  2. package/package.json +7 -7
package/README.md CHANGED
@@ -17,17 +17,20 @@ Use notifications to inform users of important changes, ongoing circumstances, u
17
17
  [Navigate to Card](../?path=/docs/components-cards-card--case)
18
18
 
19
19
  ## Anatomy
20
+
20
21
  The alert consists of:
21
22
 
22
23
  1. Support icon: informs users at a glance about the type of alert.
23
24
  2. Title: gives users a quick overview of the alert.
24
25
  3. Close icon (optional): closes the alert.
25
26
  4. Text: provides additional details and actionable steps the user can take.
26
- 6. Button (optional): button that allows users to perform an action that pertains to the notification or navigate to a page with more details.
27
- 5. Container
27
+ 5. Button (optional): button that allows users to perform an action that pertains to the notification or navigate to a page with more details.
28
+ 6. Container
28
29
 
29
30
  ## Design properties
31
+
30
32
  **Typography**
33
+
31
34
  - Title: TheSans/lg/400
32
35
  - Text: TheSans/md/400
33
36
 
@@ -43,6 +46,7 @@ There are 4 variants.
43
46
  The following buttons are used: medium, primary, text-only.
44
47
 
45
48
  **Structure**
49
+
46
50
  - Support icon: height and width 24px, padding-top and padding-right 24px, margin-left 24px
47
51
  - Title: margin-top 24px
48
52
  - Close icon: height and width 24px, padding-left 24px, margin-right 24px
@@ -50,15 +54,16 @@ The following buttons are used: medium, primary, text-only.
50
54
  - Button: margin-bottom 24px
51
55
 
52
56
  ## Accessibility
57
+
53
58
  - Alerts use a combination of icons and colors to show their meaning and importance.
54
59
  - [technical accessibility requirements]
55
60
 
56
61
  **Error alerts in forms**
57
62
 
58
- *Error alerts*
63
+ _Error alerts_
59
64
  If users submit long or complex forms with errors, use an error alert to summarize what went wrong. Place the alert at the top of the form and move the focus to the banner when the form is submitted. This will allow all users to scroll through the form in a logical order to resolve the issues.
60
65
 
61
- *Inline errors*
66
+ _Inline errors_
62
67
  Always include inline error messages for specific form fields so that users know what to do in context while correcting their errors.
63
68
 
64
69
  ## Content guidelines
@@ -82,16 +87,16 @@ The buttons should:
82
87
  • Be action-driven: buttons should always lead with a strong verb that encourages action. To provide users with enough context, you can use the {verb} + {noun} format on buttons, except in the case of general actions such as Save, Close, Cancel or OK.
83
88
  • Be scannable: avoid unnecessary words such as "the", "a" or "an".
84
89
 
85
-
86
90
  ## Best practices
87
91
 
88
92
  ### Do's
93
+
89
94
  Alerts should:
90
95
 
91
96
  - Put in the right context:
92
- - Alerts relevant to an entire page should be placed at the top of that page, below the page header. They should occupy the full width of the content area.
93
- - Alerts pertaining to a section of a page (such as a map, popover, or modal) should be placed in that section, under a section heading. These banners have less spacing and a simple design to fit a content context.
94
- - Alerts pertaining to an element that is more specific than a section should be placed directly above or below that element.
97
+ - Alerts relevant to an entire page should be placed at the top of that page, below the page header. They should occupy the full width of the content area.
98
+ - Alerts pertaining to a section of a page (such as a map, popover, or modal) should be placed in that section, under a section heading. These banners have less spacing and a simple design to fit a content context.
99
+ - Alerts pertaining to an element that is more specific than a section should be placed directly above or below that element.
95
100
  - Focus on one theme, piece of information, or required action.
96
101
  - Admissible unless they contain critical information or are an important step that users need to take.
97
102
  - Be concise and scannable: Users shouldn't spend much time figuring out what to know and do.
@@ -100,6 +105,7 @@ Alerts should:
100
105
  - Use the default icons for success, info, warning and error statuses.
101
106
 
102
107
  ### Don'ts
108
+
103
109
  Alerts should:
104
110
 
105
111
  - Not to be used as the primary access point for information or actions that users need on a regular basis.
@@ -108,16 +114,14 @@ Alerts should:
108
114
  - Not cover other contents.
109
115
  - Not contain links that can also be displayed as a button.
110
116
 
111
-
112
117
  ## Pattern
113
118
 
114
-
115
119
  **Notification status**
116
120
  Notification status helps convey the information being communicated. These statuses correspond with a color and icon to provide a consistent, universal experience for users.
117
121
 
118
122
  **Usage**
123
+
119
124
  - Error: Inform users of an error or critical failure and optionally block the user from proceeding until the issue has been resolved
120
125
  - Info: Provide additional information to users that may not be tied to their current action or task
121
126
  - Success: Confirm a task was completed as expected
122
127
  - Warning: Inform users that they are taking actions that are not desirable or might have unexpected results
123
-
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gemeente-denhaag/alert",
3
- "version": "0.1.1-alpha.16",
3
+ "version": "0.1.1-alpha.17",
4
4
  "description": "An alert component",
5
5
  "bugs": "https://github.com/Gemeente-DenHaag/denhaag-component-library/issues",
6
6
  "repository": {
@@ -22,14 +22,14 @@
22
22
  "clean": "yarn rimraf dist tsconfig.tsbuildinfo"
23
23
  },
24
24
  "dependencies": {
25
- "@gemeente-denhaag/baseprops": "^0.2.3-alpha.46",
26
- "@gemeente-denhaag/button": "^0.2.3-alpha.46",
27
- "@gemeente-denhaag/iconbutton": "^0.2.3-alpha.46",
28
- "@gemeente-denhaag/icons": "^0.2.3-alpha.46",
29
- "@gemeente-denhaag/typography": "^0.2.3-alpha.46"
25
+ "@gemeente-denhaag/baseprops": "^0.2.3-alpha.47",
26
+ "@gemeente-denhaag/button": "^0.2.3-alpha.47",
27
+ "@gemeente-denhaag/iconbutton": "^0.2.3-alpha.47",
28
+ "@gemeente-denhaag/icons": "^0.2.3-alpha.47",
29
+ "@gemeente-denhaag/typography": "^0.2.3-alpha.47"
30
30
  },
31
31
  "peerDependencies": {
32
32
  "react": "^17.0.1"
33
33
  },
34
- "gitHead": "0eeb4b12b229ca543fbbb9011acbd779b607cf7a"
34
+ "gitHead": "430bf8268c4b0b19ff884ad483787aae8dd4979d"
35
35
  }