Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(radio): add pf-radio #2882

Open
wants to merge 11 commits into
base: main
Choose a base branch
from

Conversation

Arathy-s
Copy link
Collaborator

What I did

Developed a custom pf-radio component utilizing the standard <input type="radio" /> element for enhanced functionality and styling.
Screenshot 2024-11-27 at 1 19 45 PM

Testing Instructions

1. Mouse Interaction

  • Single Click: Clicking a radio button should select it.
  • Subsequent Click: Clicking an already selected radio button should not deselect it.
  • Group Selection: When clicking a different radio button within the same group, the previously selected radio button should be deselected, and the new radio button should be selected.

2. Keyboard Navigation

  • Tab Key(on page navigation): Pressing the Tab key should focus on the first radio button in the group. If a radio button is already selected, that selected button should be focused instead of the first one.
  • Shift + Tab(on page navigation): Pressing Shift + Tab should focus on the last radio button in the group. If a radio button is already selected, that selected button should be focused instead of the last one.
  • Radio Selection: A radio button can be selected using the Space, or arrow keys.
  • Arrow Keys:
  • Arrow Down or Right: Pressing the Down Arrow or Right Arrow should move the focus in a clockwise direction within the radio group.
  • Arrow Up or Left: Pressing the Up Arrow or Left Arrow should move the focus in a counterclockwise direction within the radio group.

Notes to Reviewers

Please note that the CSS variables, code comments, test cases, and updated documentation will be added asap.

Copy link

changeset-bot bot commented Nov 27, 2024

⚠️ No Changeset found

Latest commit: 82275a1

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@bennypowers bennypowers changed the title 2566: Create pf-radio component feat(radio): add pf-radio Nov 27, 2024
Copy link

netlify bot commented Nov 27, 2024

Deploy Preview for patternfly-elements ready!

Name Link
🔨 Latest commit 82275a1
🔍 Latest deploy log https://app.netlify.com/sites/patternfly-elements/deploys/67472a8652868300086a6c36
😎 Deploy Preview https://deploy-preview-2882--patternfly-elements.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants