Skip to content

fix(template): improves button accessibility and interactivity#22142

Open
li-jia-nan wants to merge 1 commit intovitejs:mainfrom
li-jia-nan:temp-up
Open

fix(template): improves button accessibility and interactivity#22142
li-jia-nan wants to merge 1 commit intovitejs:mainfrom
li-jia-nan:temp-up

Conversation

@li-jia-nan
Copy link
Copy Markdown
Contributor

No description provided.

Copilot AI review requested due to automatic review settings April 5, 2026 22:58
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the create-vite React and React+TS templates to improve default button behavior and UI affordance in the starter counter button.

Changes:

  • Explicitly sets the counter <button> to type="button" in both React templates.
  • Adds cursor: pointer; to the .counter button styling in both template CSS files.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
packages/create-vite/template-react/src/App.jsx Adds type="button" to the counter button to avoid unintended submit behavior.
packages/create-vite/template-react/src/App.css Adds cursor: pointer to improve perceived interactivity of the counter button.
packages/create-vite/template-react-ts/src/App.tsx Adds type="button" to the counter button to avoid unintended submit behavior.
packages/create-vite/template-react-ts/src/App.css Adds cursor: pointer to improve perceived interactivity of the counter button.

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