@patternfly/patternfly 4.210.2 → 4.211.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 (38) hide show
  1. package/components/Masthead/masthead.css +1 -1
  2. package/components/Masthead/masthead.scss +1 -1
  3. package/components/NotificationBadge/notification-badge.css +13 -1
  4. package/components/NotificationBadge/notification-badge.scss +13 -1
  5. package/components/NotificationBadge/themes/dark/notification-badge.scss +2 -0
  6. package/components/Page/page.css +1 -0
  7. package/components/Page/page.scss +1 -0
  8. package/docs/components/Dropdown/examples/Dropdown.md +2 -2
  9. package/docs/components/NotificationBadge/examples/NotificationBadge.md +81 -24
  10. package/docs/components/Tabs/examples/Tabs.md +866 -139
  11. package/docs/demos/AboutModal/examples/AboutModal.md +1 -12
  12. package/docs/demos/Alert/examples/Alert.md +3 -36
  13. package/docs/demos/BackToTop/examples/BackToTop.md +1 -12
  14. package/docs/demos/Banner/examples/Banner.md +2 -24
  15. package/docs/demos/Card/examples/Card.md +15 -3
  16. package/docs/demos/CardView/examples/CardView.md +1 -12
  17. package/docs/demos/ContextSelector/examples/ContextSelector.md +3 -36
  18. package/docs/demos/Dashboard/examples/Dashboard.md +1 -12
  19. package/docs/demos/DataList/examples/DataList.md +4 -48
  20. package/docs/demos/DescriptionList/examples/DescriptionList.md +5 -36
  21. package/docs/demos/Drawer/examples/Drawer.md +7 -60
  22. package/docs/demos/JumpLinks/examples/JumpLinks.md +6 -72
  23. package/docs/demos/Masthead/examples/Masthead.md +2 -24
  24. package/docs/demos/Modal/examples/Modal.md +6 -72
  25. package/docs/demos/Nav/examples/Nav.md +8 -96
  26. package/docs/demos/NotificationDrawer/examples/NotificationDrawer.md +30 -23
  27. package/docs/demos/Page/examples/Page.md +9 -108
  28. package/docs/demos/PrimaryDetail/examples/PrimaryDetail.md +19 -85
  29. package/docs/demos/Skeleton/examples/Skeleton.md +1 -12
  30. package/docs/demos/Table/examples/Table.md +14 -168
  31. package/docs/demos/Tabs/examples/Tabs.md +56 -96
  32. package/docs/demos/Toolbar/examples/Toolbar.md +1 -12
  33. package/docs/demos/Wizard/examples/Wizard.md +8 -96
  34. package/package.json +2 -2
  35. package/patternfly-no-reset.css +15 -2
  36. package/patternfly.css +15 -2
  37. package/patternfly.min.css +1 -1
  38. package/patternfly.min.css.map +1 -1
@@ -228,7 +228,7 @@
228
228
  align-self: stretch;
229
229
  }
230
230
  .pf-c-masthead .pf-c-button.pf-m-plain {
231
- color: var(--pf-global--Color--200);
231
+ color: var(--pf-c-button--m-plain--Color);
232
232
  }
233
233
 
234
234
  .pf-c-masthead__main {
@@ -245,7 +245,7 @@ $pf-c-masthead--inset-map: build-spacer-map("none", "sm", "md", "lg", "xl", "2xl
245
245
  }
246
246
 
247
247
  .pf-c-button.pf-m-plain {
248
- @include pf-t-dark(--pf-global--Color--200); // for all plain buttons, especially inside other components (.pf-c-input-group), for dark mode
248
+ @include pf-t-dark(--pf-c-button--m-plain--Color); // for all plain buttons, especially inside other components (.pf-c-input-group), for dark mode
249
249
  }
250
250
  }
251
251
 
@@ -21,12 +21,15 @@
21
21
  --pf-c-notification-badge__i--Height: auto;
22
22
  --pf-c-notification-badge--m-read--after--BorderColor: transparent;
23
23
  --pf-c-notification-badge--m-read--after--BackgroundColor: transparent;
24
+ --pf-c-notification-badge--m-read--m-expanded--after--BackgroundColor: var(--pf-global--BackgroundColor--dark-200);
24
25
  --pf-c-notification-badge--m-unread--Color: var(--pf-global--Color--light-100);
25
26
  --pf-c-notification-badge--m-unread--after--BackgroundColor: var(--pf-global--active-color--100);
26
27
  --pf-c-notification-badge--m-unread--hover--after--BackgroundColor: var(--pf-global--primary-color--200);
28
+ --pf-c-notification-badge--m-unread--m-expanded--after--BackgroundColor: var(--pf-global--primary-color--200);
27
29
  --pf-c-notification-badge--m-attention--Color: var(--pf-global--Color--light-100);
28
30
  --pf-c-notification-badge--m-attention--after--BackgroundColor: var(--pf-global--danger-color--100);
29
31
  --pf-c-notification-badge--m-attention--hover--after--BackgroundColor: var(--pf-global--danger-color--200);
32
+ --pf-c-notification-badge--m-attention--m-expanded--after--BackgroundColor: var(--pf-global--danger-color--200);
30
33
  --pf-c-notification-badge__count--MarginLeft: var(--pf-global--spacer--xs);
31
34
  --pf-c-notification-badge--pf-icon-attention-bell--LineHeight: var(--pf-global--LineHeight--sm);
32
35
  position: relative;
@@ -68,6 +71,7 @@
68
71
  .pf-c-notification-badge.pf-m-read {
69
72
  --pf-c-notification-badge--after--BackgroundColor: var(--pf-c-notification-badge--m-read--after--BackgroundColor);
70
73
  --pf-c-notification-badge--after--BorderColor: var(--pf-c-notification-badge--m-read--after--BorderColor);
74
+ color: var(--pf-c-notification-badge--m-read--Color, inherit);
71
75
  }
72
76
  .pf-c-notification-badge.pf-m-unread {
73
77
  --pf-c-notification-badge--after--BackgroundColor: var(--pf-c-notification-badge--m-unread--after--BackgroundColor);
@@ -81,7 +85,13 @@
81
85
  color: var(--pf-c-notification-badge--m-attention--Color);
82
86
  }
83
87
  .pf-c-notification-badge.pf-m-attention:hover {
84
- --pf-c-notification-badge--after--BackgroundColor: var(--pf-c-notification-badge--m-attention--hover--after--BackgroundColor);
88
+ --pf-c-notification-badge--m-attention--after--BackgroundColor: var(--pf-c-notification-badge--m-attention--hover--after--BackgroundColor);
89
+ }
90
+ .pf-c-notification-badge.pf-m-expanded {
91
+ --pf-c-notification-badge--m-read--Color: var(--pf-global--Color--light-100);
92
+ --pf-c-notification-badge--m-read--after--BackgroundColor: var(--pf-c-notification-badge--m-read--m-expanded--after--BackgroundColor);
93
+ --pf-c-notification-badge--m-unread--after--BackgroundColor: var(--pf-c-notification-badge--m-unread--m-expanded--after--BackgroundColor);
94
+ --pf-c-notification-badge--m-attention--after--BackgroundColor: var(--pf-c-notification-badge--m-attention--m-expanded--after--BackgroundColor);
85
95
  }
86
96
 
87
97
  .pf-c-notification-badge__count {
@@ -89,5 +99,7 @@
89
99
  }
90
100
 
91
101
  :where(.pf-theme-dark) .pf-c-notification-badge {
102
+ --pf-c-notification-badge--m-read--m-expanded--after--BackgroundColor: var(--pf-global--BackgroundColor--400);
92
103
  --pf-c-notification-badge--m-unread--after--BackgroundColor: var(--pf-global--primary-color--300);
104
+ --pf-c-notification-badge--m-attention--Color: var(--pf-global--palette--black-900);
93
105
  }
@@ -31,16 +31,19 @@
31
31
  // Modifiers
32
32
  --pf-c-notification-badge--m-read--after--BorderColor: transparent; // remove at breaking change
33
33
  --pf-c-notification-badge--m-read--after--BackgroundColor: transparent;
34
+ --pf-c-notification-badge--m-read--m-expanded--after--BackgroundColor: var(--pf-global--BackgroundColor--dark-200);
34
35
 
35
36
  // Unread
36
37
  --pf-c-notification-badge--m-unread--Color: var(--pf-global--Color--light-100);
37
38
  --pf-c-notification-badge--m-unread--after--BackgroundColor: var(--pf-global--active-color--100);
38
39
  --pf-c-notification-badge--m-unread--hover--after--BackgroundColor: var(--pf-global--primary-color--200);
40
+ --pf-c-notification-badge--m-unread--m-expanded--after--BackgroundColor: var(--pf-global--primary-color--200);
39
41
 
40
42
  // Attention
41
43
  --pf-c-notification-badge--m-attention--Color: var(--pf-global--Color--light-100);
42
44
  --pf-c-notification-badge--m-attention--after--BackgroundColor: var(--pf-global--danger-color--100);
43
45
  --pf-c-notification-badge--m-attention--hover--after--BackgroundColor: var(--pf-global--danger-color--200);
46
+ --pf-c-notification-badge--m-attention--m-expanded--after--BackgroundColor: var(--pf-global--danger-color--200);
44
47
  --pf-c-notification-badge__count--MarginLeft: var(--pf-global--spacer--xs);
45
48
 
46
49
  // Attention icon
@@ -90,6 +93,8 @@
90
93
  &.pf-m-read {
91
94
  --pf-c-notification-badge--after--BackgroundColor: var(--pf-c-notification-badge--m-read--after--BackgroundColor);
92
95
  --pf-c-notification-badge--after--BorderColor: var(--pf-c-notification-badge--m-read--after--BorderColor);
96
+
97
+ color: var(--pf-c-notification-badge--m-read--Color, inherit);
93
98
  }
94
99
 
95
100
  &.pf-m-unread {
@@ -108,9 +113,16 @@
108
113
  color: var(--pf-c-notification-badge--m-attention--Color);
109
114
 
110
115
  &:hover {
111
- --pf-c-notification-badge--after--BackgroundColor: var(--pf-c-notification-badge--m-attention--hover--after--BackgroundColor);
116
+ --pf-c-notification-badge--m-attention--after--BackgroundColor: var(--pf-c-notification-badge--m-attention--hover--after--BackgroundColor);
112
117
  }
113
118
  }
119
+
120
+ &.pf-m-expanded {
121
+ --pf-c-notification-badge--m-read--Color: var(--pf-global--Color--light-100);
122
+ --pf-c-notification-badge--m-read--after--BackgroundColor: var(--pf-c-notification-badge--m-read--m-expanded--after--BackgroundColor);
123
+ --pf-c-notification-badge--m-unread--after--BackgroundColor: var(--pf-c-notification-badge--m-unread--m-expanded--after--BackgroundColor);
124
+ --pf-c-notification-badge--m-attention--after--BackgroundColor: var(--pf-c-notification-badge--m-attention--m-expanded--after--BackgroundColor);
125
+ }
114
126
  }
115
127
 
116
128
  .pf-c-notification-badge__count {
@@ -2,6 +2,8 @@
2
2
 
3
3
  @mixin pf-theme-dark-notification-badge() {
4
4
  .pf-c-notification-badge {
5
+ --pf-c-notification-badge--m-read--m-expanded--after--BackgroundColor: var(--pf-global--BackgroundColor--400);
5
6
  --pf-c-notification-badge--m-unread--after--BackgroundColor: var(--pf-global--primary-color--300);
7
+ --pf-c-notification-badge--m-attention--Color: var(--pf-global--palette--black-900);
6
8
  }
7
9
  }
@@ -273,6 +273,7 @@
273
273
  .pf-c-page.pf-m-full-height {
274
274
  height: 100vh;
275
275
  height: 100dvh;
276
+ max-height: 100%;
276
277
  }
277
278
 
278
279
  .pf-c-page__header,
@@ -212,6 +212,7 @@ $pf-c-page--height-breakpoint-map: build-breakpoint-map("base", "sm", "md", "lg"
212
212
  &.pf-m-full-height {
213
213
  height: 100vh;
214
214
  height: 100dvh;
215
+ max-height: 100%;
215
216
  }
216
217
  }
217
218
 
@@ -435,7 +435,7 @@ cssPrefix: pf-c-dropdown
435
435
  <div class="pf-c-dropdown pf-m-expanded">
436
436
  <button
437
437
  class="pf-c-dropdown__toggle"
438
- id="-button"
438
+ id="dropdown-align-on-different-breakpoint-button"
439
439
  aria-expanded="true"
440
440
  type="button"
441
441
  >
@@ -446,7 +446,7 @@ cssPrefix: pf-c-dropdown
446
446
  </button>
447
447
  <ul
448
448
  class="pf-c-dropdown__menu pf-m-align-right-on-lg pf-m-align-left-on-2xl"
449
- aria-labelledby="-button"
449
+ aria-labelledby="dropdown-align-on-different-breakpoint-button"
450
450
  >
451
451
  <li>
452
452
  <a class="pf-c-dropdown__menu-item" href="#">Link</a>
@@ -19,7 +19,6 @@ cssPrefix: pf-c-notification-badge
19
19
  <i class="pf-icon-bell" aria-hidden="true"></i>
20
20
  </span>
21
21
  </button>
22
-
23
22
  <button
24
23
  class="pf-c-button pf-m-plain"
25
24
  type="button"
@@ -29,7 +28,6 @@ cssPrefix: pf-c-notification-badge
29
28
  <i class="pf-icon-bell" aria-hidden="true"></i>
30
29
  </span>
31
30
  </button>
32
-
33
31
  <button
34
32
  class="pf-c-button pf-m-plain"
35
33
  type="button"
@@ -39,16 +37,13 @@ cssPrefix: pf-c-notification-badge
39
37
  <i class="pf-icon-attention-bell" aria-hidden="true"></i>
40
38
  </span>
41
39
  </button>
42
-
43
40
  <br />
44
41
  <br />
45
-
46
42
  <button class="pf-c-button pf-m-plain" type="button" aria-label="Tasks">
47
43
  <span class="pf-c-notification-badge pf-m-read">
48
44
  <i class="pf-icon-task" aria-hidden="true"></i>
49
45
  </span>
50
46
  </button>
51
-
52
47
  <button
53
48
  class="pf-c-button pf-m-plain"
54
49
  type="button"
@@ -58,7 +53,6 @@ cssPrefix: pf-c-notification-badge
58
53
  <i class="pf-icon-task" aria-hidden="true"></i>
59
54
  </span>
60
55
  </button>
61
-
62
56
  <button
63
57
  class="pf-c-button pf-m-plain"
64
58
  type="button"
@@ -79,65 +73,129 @@ cssPrefix: pf-c-notification-badge
79
73
  <button
80
74
  class="pf-c-button pf-m-plain"
81
75
  type="button"
82
- aria-label="Notifications"
76
+ aria-label="24 notifications"
83
77
  >
84
78
  <span class="pf-c-notification-badge pf-m-read">
85
79
  <i class="pf-icon-bell" aria-hidden="true"></i>
86
80
  <span class="pf-c-notification-badge__count">24</span>
87
81
  </span>
88
82
  </button>
89
-
90
83
  <button
91
84
  class="pf-c-button pf-m-plain"
92
85
  type="button"
93
- aria-label="Unread notifications"
86
+ aria-label="24 unread notifications"
94
87
  >
95
88
  <span class="pf-c-notification-badge pf-m-unread">
96
89
  <i class="pf-icon-bell" aria-hidden="true"></i>
97
- <span class="pf-c-notification-badge__count">25</span>
90
+ <span class="pf-c-notification-badge__count">24</span>
98
91
  </span>
99
92
  </button>
100
-
101
93
  <button
102
94
  class="pf-c-button pf-m-plain"
103
95
  type="button"
104
- aria-label="Attention notifications"
96
+ aria-label="24 attention notifications"
105
97
  >
106
98
  <span class="pf-c-notification-badge pf-m-attention">
107
99
  <i class="pf-icon-attention-bell" aria-hidden="true"></i>
108
- <span class="pf-c-notification-badge__count">26</span>
100
+ <span class="pf-c-notification-badge__count">24</span>
109
101
  </span>
110
102
  </button>
111
-
112
103
  <br />
113
104
  <br />
114
-
115
- <button class="pf-c-button pf-m-plain" type="button" aria-label="Tasks">
105
+ <button class="pf-c-button pf-m-plain" type="button" aria-label="24 tasks">
116
106
  <span class="pf-c-notification-badge pf-m-read">
117
107
  <i class="pf-icon-task" aria-hidden="true"></i>
118
108
  <span class="pf-c-notification-badge__count">24</span>
119
109
  </span>
120
110
  </button>
121
-
122
111
  <button
123
112
  class="pf-c-button pf-m-plain"
124
113
  type="button"
125
- aria-label="Unread tasks"
114
+ aria-label="24 unread tasks"
126
115
  >
127
116
  <span class="pf-c-notification-badge pf-m-unread">
128
117
  <i class="pf-icon-task" aria-hidden="true"></i>
129
- <span class="pf-c-notification-badge__count">25</span>
118
+ <span class="pf-c-notification-badge__count">24</span>
130
119
  </span>
131
120
  </button>
121
+ <button
122
+ class="pf-c-button pf-m-plain"
123
+ type="button"
124
+ aria-label="24 attention tasks"
125
+ >
126
+ <span class="pf-c-notification-badge pf-m-attention">
127
+ <i class="pf-icon-task" aria-hidden="true"></i>
128
+ <span class="pf-c-notification-badge__count">24</span>
129
+ </span>
130
+ </button>
131
+ </div>
132
132
 
133
+ ```
134
+
135
+ ### Expanded
136
+
137
+ ```html
138
+ <div class="pf-t-dark">
133
139
  <button
134
140
  class="pf-c-button pf-m-plain"
135
141
  type="button"
142
+ aria-expanded="true"
143
+ aria-label="Notifications"
144
+ >
145
+ <span class="pf-c-notification-badge pf-m-read pf-m-expanded">
146
+ <i class="pf-icon-bell" aria-hidden="true"></i>
147
+ </span>
148
+ </button>
149
+ <button
150
+ class="pf-c-button pf-m-plain"
151
+ type="button"
152
+ aria-expanded="true"
153
+ aria-label="Unread notifications"
154
+ >
155
+ <span class="pf-c-notification-badge pf-m-unread pf-m-expanded">
156
+ <i class="pf-icon-bell" aria-hidden="true"></i>
157
+ </span>
158
+ </button>
159
+ <button
160
+ class="pf-c-button pf-m-plain"
161
+ type="button"
162
+ aria-expanded="true"
163
+ aria-label="Attention notifications"
164
+ >
165
+ <span class="pf-c-notification-badge pf-m-attention pf-m-expanded">
166
+ <i class="pf-icon-attention-bell" aria-hidden="true"></i>
167
+ </span>
168
+ </button>
169
+ <br />
170
+ <br />
171
+ <button
172
+ class="pf-c-button pf-m-plain"
173
+ type="button"
174
+ aria-expanded="true"
175
+ aria-label="Tasks"
176
+ >
177
+ <span class="pf-c-notification-badge pf-m-read pf-m-expanded">
178
+ <i class="pf-icon-task" aria-hidden="true"></i>
179
+ </span>
180
+ </button>
181
+ <button
182
+ class="pf-c-button pf-m-plain"
183
+ type="button"
184
+ aria-expanded="true"
185
+ aria-label="Unread tasks"
186
+ >
187
+ <span class="pf-c-notification-badge pf-m-unread pf-m-expanded">
188
+ <i class="pf-icon-task" aria-hidden="true"></i>
189
+ </span>
190
+ </button>
191
+ <button
192
+ class="pf-c-button pf-m-plain"
193
+ type="button"
194
+ aria-expanded="true"
136
195
  aria-label="Attention tasks"
137
196
  >
138
- <span class="pf-c-notification-badge pf-m-attention">
197
+ <span class="pf-c-notification-badge pf-m-attention pf-m-expanded">
139
198
  <i class="pf-icon-task" aria-hidden="true"></i>
140
- <span class="pf-c-notification-badge__count">26</span>
141
199
  </span>
142
200
  </button>
143
201
  </div>
@@ -148,9 +206,7 @@ cssPrefix: pf-c-notification-badge
148
206
 
149
207
  ### Overview
150
208
 
151
- Always add a modifier class. Never use the class `.pf-c-notification-badge` on its own. This component is designed to be used within a dark component such as the [masthead](/components/masthead).
152
-
153
- Note: The [page component](/components/page) currently handles the selected state styling of the notification badge using the page header tools item styling. If this component is used elsewhere, custom styling may be needed to correctly indicate the selected state.
209
+ Always add a modifier class to indicate read, unread, or attention state. Never use the class `.pf-c-notification-badge` on its own. This component is designed to be used within a dark component such as the [masthead](/components/masthead).
154
210
 
155
211
  ### Accessibility
156
212
 
@@ -165,3 +221,4 @@ Be sure that the component associated with this indicator handles screen reader
165
221
  | `.pf-m-read` | `.pf-c-notification-badge` | Applies read notification badge styling. |
166
222
  | `.pf-m-unread` | `.pf-c-notification-badge` | Applies unread notification badge styling. |
167
223
  | `.pf-m-attention` | `.pf-c-notification-badge` | Applies attention notification badge styling. |
224
+ | `.pf-m-expanded` | `.pf-c-notification-badge` | Applies expanded notification badge styling. |