Skip to content

Commit 8cdaa3e

Browse files
Merge branch 'patternfly:main' into main
2 parents 122e761 + 5e50a62 commit 8cdaa3e

File tree

24 files changed

+1311
-42
lines changed

24 files changed

+1311
-42
lines changed

package-lock.json

Lines changed: 1088 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/module/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@
4646
"@patternfly/documentation-framework": "^2.0.0-alpha.57",
4747
"@patternfly/patternfly": "^5.1.0",
4848
"@patternfly/react-code-editor": "^5.1.1",
49+
"@openshift-console/dynamic-plugin-sdk": "^0.0.21",
4950
"@types/react": "^18.2.33",
5051
"@types/react-dom": "^18.2.14",
5152
"@types/react-router-dom": "^5.3.3",

packages/module/patternfly-docs/content/extensions/component-groups/examples/Ansible/Ansible.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ source: react
1111
# If you use typescript, the name of the interface to display props for
1212
# These are found through the sourceProps function provided in patternfly-docs.source.js
1313
propComponents: ['Ansible']
14+
sourceLink: https://github.com/patternfly/react-component-groups/blob/main/packages/module/patternfly-docs/content/extensions/component-groups/examples/Ansible/Ansible.md
1415
---
1516

1617
import Ansible from '@patternfly/react-component-groups/dist/dynamic/Ansible';

packages/module/patternfly-docs/content/extensions/component-groups/examples/Battery/Battery.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ source: react
1111
# If you use typescript, the name of the interface to display props for
1212
# These are found through the sourceProps function provided in patternfly-docs.source.js
1313
propComponents: ['Battery']
14+
sourceLink: https://github.com/patternfly/react-component-groups/blob/main/packages/module/patternfly-docs/content/extensions/component-groups/examples/Battery/Battery.md
1415
---
1516

1617
import Battery from '@patternfly/react-component-groups/dist/dynamic/Battery';
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
---
2+
# Sidenav top-level section
3+
# should be the same for all markdown files
4+
section: extensions
5+
subsection: Component groups
6+
# Sidenav secondary level section
7+
# should be the same for all markdown files
8+
id: CloseButton
9+
# Tab (react | react-demos | html | html-demos | design-guidelines | accessibility)
10+
source: react
11+
# If you use typescript, the name of the interface to display props for
12+
# These are found through the sourceProps function provided in patternfly-docs.source.js
13+
propComponents: ['CloseButton']
14+
---
15+
16+
import { CloseIcon } from '@patternfly/react-icons';
17+
import CloseButton from '@patternfly/react-component-groups/dist/dynamic/CloseButton';
18+
19+
**Close button**
20+
21+
The close button component provides a way for users to exit a modal, dialogue, or similar action.
22+
23+
## Examples ##
24+
25+
You can use onClick to execute a callback when a user selects the close button.
26+
27+
```js file="./CloseButtonExample.tsx"
28+
29+
```
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
/* eslint-disable no-console */
2+
import React from 'react'
3+
import CloseButton from '@patternfly/react-component-groups/dist/dynamic/CloseButton';
4+
5+
export const BasicExample: React.FunctionComponent = () => (
6+
<>
7+
<CloseButton onClick={()=>{console.log('Close button clicked')}} />
8+
</>
9+
);

packages/module/patternfly-docs/content/extensions/component-groups/examples/DetailsPage/DetailsPage.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ propComponents: [
2424
# 'Tab', # No output --> is a type and not an interface
2525
]
2626
beta: true
27+
sourceLink: https://github.com/patternfly/react-component-groups/blob/main/packages/module/patternfly-docs/content/extensions/component-groups/examples/DetailsPage/DetailsPage.md
2728
---
2829

2930
import { ActionMenu } from '@patternfly/react-component-groups';

packages/module/patternfly-docs/content/extensions/component-groups/examples/ErrorBoundary/ErrorBoundary.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ source: react
1111
# If you use typescript, the name of the interface to display props for
1212
# These are found through the sourceProps function provided in patternfly-docs.source.js
1313
propComponents: ['ErrorBoundary']
14+
sourceLink: https://github.com/patternfly/react-component-groups/blob/main/packages/module/patternfly-docs/content/extensions/component-groups/examples/ErrorBoundary/ErrorBoundary.md
1415
---
1516

1617
import ErrorBoundary from "@patternfly/react-component-groups/dist/dynamic/ErrorBoundary";

packages/module/patternfly-docs/content/extensions/component-groups/examples/ErrorState/ErrorState.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ source: react
1111
# If you use typescript, the name of the interface to display props for
1212
# These are found through the sourceProps function provided in patternfly-docs.source.js
1313
propComponents: ['ErrorState']
14+
sourceLink: https://github.com/patternfly/react-component-groups/blob/main/packages/module/patternfly-docs/content/extensions/component-groups/examples/ErrorState/ErrorState.md
1415
---
1516

1617
import ErrorState from "@patternfly/react-component-groups/dist/dynamic/ErrorState";

packages/module/patternfly-docs/content/extensions/component-groups/examples/InvalidObject/InvalidObject.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ source: react
1111
# If you use typescript, the name of the interface to display props for
1212
# These are found through the sourceProps function provided in patternfly-docs.source.js
1313
propComponents: ['InvalidObject']
14+
sourceLink: https://github.com/patternfly/react-component-groups/blob/main/packages/module/patternfly-docs/content/extensions/component-groups/examples/InvalidObject/InvalidObject.md
1415
---
1516

1617
import InvalidObject from '@patternfly/react-component-groups/dist/dynamic/InvalidObject';

0 commit comments

Comments
 (0)