@patternfly/react-core 4.183.5 → 4.183.9

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 (28) hide show
  1. package/CHANGELOG.md +32 -0
  2. package/dist/esm/components/JumpLinks/JumpLinks.js +1 -1
  3. package/dist/esm/components/JumpLinks/JumpLinks.js.map +1 -1
  4. package/dist/js/components/JumpLinks/JumpLinks.js +1 -1
  5. package/dist/js/components/JumpLinks/JumpLinks.js.map +1 -1
  6. package/dist/umd/react-core.css +14 -14
  7. package/dist/umd/react-core.js +1 -1
  8. package/dist/umd/react-core.min.js +1 -1
  9. package/package.json +5 -5
  10. package/src/components/AboutModal/examples/AboutModal.md +4 -222
  11. package/src/components/AboutModal/examples/AboutModalBasic.tsx +46 -0
  12. package/src/components/AboutModal/examples/AboutModalComplexUserPositionedContent.tsx +52 -0
  13. package/src/components/AboutModal/examples/AboutModalCustomBackgroundImage.tsx +35 -0
  14. package/src/components/AboutModal/examples/AboutModalWithoutProductName.tsx +45 -0
  15. package/src/components/Accordion/examples/Accordion.md +4 -469
  16. package/src/components/Accordion/examples/AccordionBordered.tsx +134 -0
  17. package/src/components/Accordion/examples/AccordionDefinitionList.tsx +107 -0
  18. package/src/components/Accordion/examples/AccordionFixedWithMultipleExpandBehavior.tsx +92 -0
  19. package/src/components/Accordion/examples/AccordionSingleExpandBehavior.tsx +107 -0
  20. package/src/components/JumpLinks/JumpLinks.tsx +1 -1
  21. package/src/components/TextInputGroup/examples/TextInputGroup.md +4 -123
  22. package/src/components/TextInputGroup/examples/TextInputGroupBasic.tsx +8 -0
  23. package/src/components/TextInputGroup/examples/TextInputGroupDisabled.tsx +8 -0
  24. package/src/components/TextInputGroup/examples/TextInputGroupFilters.tsx +69 -0
  25. package/src/components/TextInputGroup/examples/TextInputGroupUtilitiesAndIcon.tsx +34 -0
  26. package/src/demos/TextInputGroupDemo.md +2 -2
  27. package/src/demos/examples/TextInputGroup/{AttributeValueFiltering.js → AttributeValueFiltering.tsx} +22 -18
  28. package/src/demos/examples/TextInputGroup/{AutoCompleteSearch.js → AutoCompleteSearch.tsx} +18 -18
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@patternfly/react-core",
3
- "version": "4.183.5",
3
+ "version": "4.183.9",
4
4
  "description": "This library provides a set of common React components for use with the PatternFly reference implementation.",
5
5
  "main": "dist/js/index.js",
6
6
  "module": "dist/esm/index.js",
@@ -34,9 +34,9 @@
34
34
  "generate": "node scripts/copyStyles.js"
35
35
  },
36
36
  "dependencies": {
37
- "@patternfly/react-icons": "^4.34.5",
38
- "@patternfly/react-styles": "^4.33.5",
39
- "@patternfly/react-tokens": "^4.35.5",
37
+ "@patternfly/react-icons": "^4.34.9",
38
+ "@patternfly/react-styles": "^4.33.9",
39
+ "@patternfly/react-tokens": "^4.35.9",
40
40
  "focus-trap": "6.2.2",
41
41
  "react-dropzone": "9.0.0",
42
42
  "tippy.js": "5.1.2",
@@ -60,5 +60,5 @@
60
60
  "react": "^16.8.0 || ^17.0.0",
61
61
  "react-dom": "^16.8.0 || ^17.0.0"
62
62
  },
63
- "gitHead": "39b9bbc6bf54e9e792552b6a0b18f1dd3b89cd8d"
63
+ "gitHead": "245bd40994d575c2a111d746f35d7f96e82809da"
64
64
  }
@@ -9,235 +9,17 @@ import bgImg from './patternfly-orb.svg';
9
9
 
10
10
  ## Examples
11
11
  ### Basic
12
- ```js
13
- import React from 'react';
14
- import { AboutModal, Button, TextContent, TextList, TextListItem } from '@patternfly/react-core';
15
- import brandImg from './examples/brandImg.svg';
16
-
17
- class SimpleAboutModal extends React.Component {
18
- constructor(props) {
19
- super(props);
20
- this.state = {
21
- isModalOpen: false
22
- };
23
- this.handleModalToggle = () => {
24
- this.setState(({ isModalOpen }) => ({
25
- isModalOpen: !isModalOpen
26
- }));
27
- };
28
- }
29
-
30
- render() {
31
- const { isModalOpen } = this.state;
32
-
33
- return (
34
- <React.Fragment>
35
- <Button variant="primary" onClick={this.handleModalToggle}>
36
- Show about modal
37
- </Button>
38
- <AboutModal
39
- isOpen={isModalOpen}
40
- onClose={this.handleModalToggle}
41
- trademark="Trademark and copyright information here"
42
- brandImageSrc={brandImg}
43
- brandImageAlt="Patternfly Logo"
44
- productName="Product Name"
45
- >
46
- <TextContent>
47
- <TextList component="dl">
48
- <TextListItem component="dt">CFME Version</TextListItem>
49
- <TextListItem component="dd">5.5.3.4.20102789036450</TextListItem>
50
- <TextListItem component="dt">Cloudforms Version</TextListItem>
51
- <TextListItem component="dd">4.1</TextListItem>
52
- <TextListItem component="dt">Server Name</TextListItem>
53
- <TextListItem component="dd">40DemoMaster</TextListItem>
54
- <TextListItem component="dt">User Name</TextListItem>
55
- <TextListItem component="dd">Administrator</TextListItem>
56
- <TextListItem component="dt">User Role</TextListItem>
57
- <TextListItem component="dd">EvmRole-super_administrator</TextListItem>
58
- <TextListItem component="dt">Browser Version</TextListItem>
59
- <TextListItem component="dd">601.2</TextListItem>
60
- <TextListItem component="dt">Browser OS</TextListItem>
61
- <TextListItem component="dd">Mac</TextListItem>
62
- </TextList>
63
- </TextContent>
64
- </AboutModal>
65
- </React.Fragment>
66
- );
67
- }
68
- }
12
+ ```ts file="./AboutModalBasic.tsx"
69
13
  ```
70
14
 
71
15
  ### Without product name
72
- ```js
73
- import React from 'react';
74
- import { AboutModal, Button, TextContent, TextList, TextListItem } from '@patternfly/react-core';
75
- import brandImg from './examples/brandImg.svg';
76
-
77
- class SimpleAboutModal extends React.Component {
78
- constructor(props) {
79
- super(props);
80
- this.state = {
81
- isModalOpen: false
82
- };
83
- this.handleModalToggle = () => {
84
- this.setState(({ isModalOpen }) => ({
85
- isModalOpen: !isModalOpen
86
- }));
87
- };
88
- }
89
-
90
- render() {
91
- const { isModalOpen } = this.state;
92
-
93
- return (
94
- <React.Fragment>
95
- <Button variant="primary" onClick={this.handleModalToggle}>
96
- Show about modal
97
- </Button>
98
- <AboutModal
99
- isOpen={isModalOpen}
100
- onClose={this.handleModalToggle}
101
- trademark="Trademark and copyright information here"
102
- brandImageSrc={brandImg}
103
- brandImageAlt="Patternfly Logo"
104
- >
105
- <TextContent>
106
- <TextList component="dl">
107
- <TextListItem component="dt">CFME Version</TextListItem>
108
- <TextListItem component="dd">5.5.3.4.20102789036450</TextListItem>
109
- <TextListItem component="dt">Cloudforms Version</TextListItem>
110
- <TextListItem component="dd">4.1</TextListItem>
111
- <TextListItem component="dt">Server Name</TextListItem>
112
- <TextListItem component="dd">40DemoMaster</TextListItem>
113
- <TextListItem component="dt">User Name</TextListItem>
114
- <TextListItem component="dd">Administrator</TextListItem>
115
- <TextListItem component="dt">User Role</TextListItem>
116
- <TextListItem component="dd">EvmRole-super_administrator</TextListItem>
117
- <TextListItem component="dt">Browser Version</TextListItem>
118
- <TextListItem component="dd">601.2</TextListItem>
119
- <TextListItem component="dt">Browser OS</TextListItem>
120
- <TextListItem component="dd">Mac</TextListItem>
121
- </TextList>
122
- </TextContent>
123
- </AboutModal>
124
- </React.Fragment>
125
- );
126
- }
127
- }
16
+ ```ts file="./AboutModalWithoutProductName.tsx"
128
17
  ```
129
18
 
130
19
  ### Complex user positioned content
131
- ```js
132
- import React from 'react';
133
- import { AboutModal, Alert, Button, TextContent, TextList, TextListItem } from '@patternfly/react-core';
134
- import brandImg from './examples/brandImg.svg';
135
-
136
- class ContentRichAboutModal extends React.Component {
137
- constructor(props) {
138
- super(props);
139
- this.state = {
140
- isModalOpen: false
141
- };
142
- this.handleModalToggle = () => {
143
- this.setState(({ isModalOpen }) => ({
144
- isModalOpen: !isModalOpen
145
- }));
146
- };
147
- }
148
-
149
- render() {
150
- const { isModalOpen } = this.state;
151
-
152
- return (
153
- <React.Fragment>
154
- <Button variant="primary" onClick={this.handleModalToggle}>
155
- Show about modal
156
- </Button>
157
- <AboutModal
158
- isOpen={isModalOpen}
159
- onClose={this.handleModalToggle}
160
- trademark="Trademark and copyright information here"
161
- brandImageSrc={brandImg}
162
- brandImageAlt="Patternfly Logo"
163
- noAboutModalBoxContentContainer={true}
164
- productName="Product Name"
165
- >
166
- <TextContent id="test1" className="pf-u-py-xl">
167
- <h4>About</h4>
168
- <p>Content here</p>
169
- </TextContent>
170
- <Alert variant="info" title="Updates available" />
171
- <TextContent id="test2" className="pf-u-py-xl">
172
- <TextList component="dl">
173
- <TextListItem component="dt">CFME Version</TextListItem>
174
- <TextListItem component="dd">5.5.3.4.20102789036450</TextListItem>
175
- <TextListItem component="dt">Cloudforms Version</TextListItem>
176
- <TextListItem component="dd">4.1</TextListItem>
177
- <TextListItem component="dt">Server Name</TextListItem>
178
- <TextListItem component="dd">40DemoMaster</TextListItem>
179
- <TextListItem component="dt">User Name</TextListItem>
180
- <TextListItem component="dd">Administrator</TextListItem>
181
- <TextListItem component="dt">User Role</TextListItem>
182
- <TextListItem component="dd">EvmRole-super_administrator</TextListItem>
183
- <TextListItem component="dt">Browser Version</TextListItem>
184
- <TextListItem component="dd">601.2</TextListItem>
185
- <TextListItem component="dt">Browser OS</TextListItem>
186
- <TextListItem component="dd">Mac</TextListItem>
187
- </TextList>
188
- </TextContent>
189
- </AboutModal>
190
- </React.Fragment>
191
- );
192
- }
193
- }
20
+ ```ts file="./AboutModalComplexUserPositionedContent.tsx"
194
21
  ```
195
22
 
196
23
  ### Custom background image
197
- ```js
198
- import React from 'react';
199
- import { AboutModal, Button, TextContent, TextList, TextListItem } from '@patternfly/react-core';
200
- import brandImg from './examples/brandImg.svg';
201
- import bgImg from './examples/patternfly-orb.svg';
202
-
203
- class SimpleAboutModal extends React.Component {
204
- constructor(props) {
205
- super(props);
206
- this.state = {
207
- isModalOpen: false
208
- };
209
- this.handleModalToggle = () => {
210
- this.setState(({ isModalOpen }) => ({
211
- isModalOpen: !isModalOpen
212
- }));
213
- };
214
- }
215
-
216
- render() {
217
- const { isModalOpen } = this.state;
218
-
219
- return (
220
- <React.Fragment>
221
- <Button variant="primary" onClick={this.handleModalToggle}>
222
- Show about modal
223
- </Button>
224
- <AboutModal
225
- isOpen={isModalOpen}
226
- onClose={this.handleModalToggle}
227
- trademark="Trademark and copyright information here"
228
- brandImageSrc={brandImg}
229
- brandImageAlt="Patternfly Logo"
230
- backgroundImageSrc={bgImg}
231
- >
232
- <TextContent>
233
- <TextList component="dl">
234
- <TextListItem component="dt">CFME Version</TextListItem>
235
- <TextListItem component="dd">5.5.3.4.20102789036450</TextListItem>
236
- </TextList>
237
- </TextContent>
238
- </AboutModal>
239
- </React.Fragment>
240
- );
241
- }
242
- }
24
+ ```ts file="./AboutModalCustomBackgroundImage.tsx"
243
25
  ```
@@ -0,0 +1,46 @@
1
+ import React from 'react';
2
+ import { AboutModal, Button, TextContent, TextList, TextListItem } from '@patternfly/react-core';
3
+ import brandImg from './brandImg.svg';
4
+
5
+ export const AboutModalBasic: React.FunctionComponent = () => {
6
+ const [isModalOpen, setIsModalOpen] = React.useState(false);
7
+
8
+ const toggleModal = () => {
9
+ setIsModalOpen(!isModalOpen);
10
+ };
11
+
12
+ return (
13
+ <React.Fragment>
14
+ <Button variant="primary" onClick={toggleModal}>
15
+ Show about modal
16
+ </Button>
17
+ <AboutModal
18
+ isOpen={isModalOpen}
19
+ onClose={toggleModal}
20
+ trademark="Trademark and copyright information here"
21
+ brandImageSrc={brandImg}
22
+ brandImageAlt="Patternfly Logo"
23
+ productName="Product Name"
24
+ >
25
+ <TextContent>
26
+ <TextList component="dl">
27
+ <TextListItem component="dt">CFME Version</TextListItem>
28
+ <TextListItem component="dd">5.5.3.4.20102789036450</TextListItem>
29
+ <TextListItem component="dt">Cloudforms Version</TextListItem>
30
+ <TextListItem component="dd">4.1</TextListItem>
31
+ <TextListItem component="dt">Server Name</TextListItem>
32
+ <TextListItem component="dd">40DemoMaster</TextListItem>
33
+ <TextListItem component="dt">User Name</TextListItem>
34
+ <TextListItem component="dd">Administrator</TextListItem>
35
+ <TextListItem component="dt">User Role</TextListItem>
36
+ <TextListItem component="dd">EvmRole-super_administrator</TextListItem>
37
+ <TextListItem component="dt">Browser Version</TextListItem>
38
+ <TextListItem component="dd">601.2</TextListItem>
39
+ <TextListItem component="dt">Browser OS</TextListItem>
40
+ <TextListItem component="dd">Mac</TextListItem>
41
+ </TextList>
42
+ </TextContent>
43
+ </AboutModal>
44
+ </React.Fragment>
45
+ );
46
+ };
@@ -0,0 +1,52 @@
1
+ import React from 'react';
2
+ import { AboutModal, Alert, Button, TextContent, TextList, TextListItem } from '@patternfly/react-core';
3
+ import brandImg from './brandImg.svg';
4
+
5
+ export const AboutModalComplexUserPositionedContent: React.FunctionComponent = () => {
6
+ const [isModalOpen, setIsModalOpen] = React.useState(false);
7
+
8
+ const toggleModal = () => {
9
+ setIsModalOpen(!isModalOpen);
10
+ };
11
+
12
+ return (
13
+ <React.Fragment>
14
+ <Button variant="primary" onClick={toggleModal}>
15
+ Show about modal
16
+ </Button>
17
+ <AboutModal
18
+ isOpen={isModalOpen}
19
+ onClose={toggleModal}
20
+ trademark="Trademark and copyright information here"
21
+ brandImageSrc={brandImg}
22
+ brandImageAlt="Patternfly Logo"
23
+ noAboutModalBoxContentContainer={true}
24
+ productName="Product Name"
25
+ >
26
+ <TextContent id="test1" className="pf-u-py-xl">
27
+ <h4>About</h4>
28
+ <p>Content here</p>
29
+ </TextContent>
30
+ <Alert variant="info" title="Updates available" />
31
+ <TextContent id="test2" className="pf-u-py-xl">
32
+ <TextList component="dl">
33
+ <TextListItem component="dt">CFME Version</TextListItem>
34
+ <TextListItem component="dd">5.5.3.4.20102789036450</TextListItem>
35
+ <TextListItem component="dt">Cloudforms Version</TextListItem>
36
+ <TextListItem component="dd">4.1</TextListItem>
37
+ <TextListItem component="dt">Server Name</TextListItem>
38
+ <TextListItem component="dd">40DemoMaster</TextListItem>
39
+ <TextListItem component="dt">User Name</TextListItem>
40
+ <TextListItem component="dd">Administrator</TextListItem>
41
+ <TextListItem component="dt">User Role</TextListItem>
42
+ <TextListItem component="dd">EvmRole-super_administrator</TextListItem>
43
+ <TextListItem component="dt">Browser Version</TextListItem>
44
+ <TextListItem component="dd">601.2</TextListItem>
45
+ <TextListItem component="dt">Browser OS</TextListItem>
46
+ <TextListItem component="dd">Mac</TextListItem>
47
+ </TextList>
48
+ </TextContent>
49
+ </AboutModal>
50
+ </React.Fragment>
51
+ );
52
+ };
@@ -0,0 +1,35 @@
1
+ import React from 'react';
2
+ import { AboutModal, Button, TextContent, TextList, TextListItem } from '@patternfly/react-core';
3
+ import brandImg from './brandImg.svg';
4
+ import bgImg from './patternfly-orb.svg';
5
+
6
+ export const AboutModalCustomBackgroundImage: React.FunctionComponent = () => {
7
+ const [isModalOpen, setIsModalOpen] = React.useState(false);
8
+
9
+ const toggleModal = () => {
10
+ setIsModalOpen(!isModalOpen);
11
+ };
12
+
13
+ return (
14
+ <React.Fragment>
15
+ <Button variant="primary" onClick={toggleModal}>
16
+ Show about modal
17
+ </Button>
18
+ <AboutModal
19
+ isOpen={isModalOpen}
20
+ onClose={toggleModal}
21
+ trademark="Trademark and copyright information here"
22
+ brandImageSrc={brandImg}
23
+ brandImageAlt="Patternfly Logo"
24
+ backgroundImageSrc={bgImg}
25
+ >
26
+ <TextContent>
27
+ <TextList component="dl">
28
+ <TextListItem component="dt">CFME Version</TextListItem>
29
+ <TextListItem component="dd">5.5.3.4.20102789036450</TextListItem>
30
+ </TextList>
31
+ </TextContent>
32
+ </AboutModal>
33
+ </React.Fragment>
34
+ );
35
+ };
@@ -0,0 +1,45 @@
1
+ import React from 'react';
2
+ import { AboutModal, Button, TextContent, TextList, TextListItem } from '@patternfly/react-core';
3
+ import brandImg from './brandImg.svg';
4
+
5
+ export const AboutModalWithoutProductName: React.FunctionComponent = () => {
6
+ const [isModalOpen, setIsModalOpen] = React.useState(false);
7
+
8
+ const toggleModal = () => {
9
+ setIsModalOpen(!isModalOpen);
10
+ };
11
+
12
+ return (
13
+ <React.Fragment>
14
+ <Button variant="primary" onClick={toggleModal}>
15
+ Show about modal
16
+ </Button>
17
+ <AboutModal
18
+ isOpen={isModalOpen}
19
+ onClose={toggleModal}
20
+ trademark="Trademark and copyright information here"
21
+ brandImageSrc={brandImg}
22
+ brandImageAlt="Patternfly Logo"
23
+ >
24
+ <TextContent>
25
+ <TextList component="dl">
26
+ <TextListItem component="dt">CFME Version</TextListItem>
27
+ <TextListItem component="dd">5.5.3.4.20102789036450</TextListItem>
28
+ <TextListItem component="dt">Cloudforms Version</TextListItem>
29
+ <TextListItem component="dd">4.1</TextListItem>
30
+ <TextListItem component="dt">Server Name</TextListItem>
31
+ <TextListItem component="dd">40DemoMaster</TextListItem>
32
+ <TextListItem component="dt">User Name</TextListItem>
33
+ <TextListItem component="dd">Administrator</TextListItem>
34
+ <TextListItem component="dt">User Role</TextListItem>
35
+ <TextListItem component="dd">EvmRole-super_administrator</TextListItem>
36
+ <TextListItem component="dt">Browser Version</TextListItem>
37
+ <TextListItem component="dd">601.2</TextListItem>
38
+ <TextListItem component="dt">Browser OS</TextListItem>
39
+ <TextListItem component="dd">Mac</TextListItem>
40
+ </TextList>
41
+ </TextContent>
42
+ </AboutModal>
43
+ </React.Fragment>
44
+ );
45
+ };