patternfly / patternfly/react-component-groups
MissingPage: support multiple action buttons
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 10
- Forks
- 40
- Avg merge
- 3d 22h
- Merged PRs (30d)
- 4
Description
Description
MissingPage currently supports only a single link/action via the toHomePageUrl prop (rendered as a "Go to home page" link). A common 404 page pattern includes multiple actions — typically both "Go Home" and "Go Back" buttons.
Use Case
In ansible/ansible-ui, our custom PageNotFound component renders two action buttons:
-
"Go to Dashboard" (navigate to home)
-
"Return to previous page" (browser back)
We cannot adopt MissingPage because it only renders one action.
Proposed Solution
Add support for custom footer actions, either via:
-
A
customFooteroractionsprop that acceptsReactNode(most flexible) -
An
additionalActionsarray prop alongside the existingtoHomePageUrl
This would align with how other component-groups components like ErrorState support customFooter.
Current Workaround
We maintain a custom PageNotFound component that duplicates MissingPage's layout but adds a second button.
Jira Issue: PF-4547
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading the MissingPage component and compare its footer API with ErrorState, which already supports customFooter. Confirm how the existing toHomePageUrl action is rendered, then add a supported way to render multiple custom actions while preserving the current behavior. Done means consumers can provide both home and back actions without duplicating the MissingPage layout.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 68/100