Skip to content

Refactor 404 error page to use div instead of p for search form #4038

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

AndrewDongminYoo
Copy link

@AndrewDongminYoo AndrewDongminYoo commented Apr 26, 2025

The 404 error page’s search form was wrapped in a <p> tag, but <p> cannot contain block-level elements like <form>. This change refactors the markup to use a <div> instead, which:

  • Improves semantic correctness of the HTML
  • Prevents any rendering glitches caused by invalid nesting

Files changed:

  • doc/api/__404error.html (replace <p>…</p> around the form with <div>…</div>)

No behavior changes beyond markup.


  • I’ve reviewed the contributor guide and applied the relevant portions to this PR.
Contribution guidelines:

Note that many Dart repos have a weekly cadence for reviewing PRs - please allow for some latency before initial review feedback.

Copy link

google-cla bot commented Apr 26, 2025

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

The search form on the 404 error page was previously wrapped in a `<p>` tag, which is semantically incorrect as `<p>` tags cannot contain block-level elements like `<form>`. This commit refactors the page to use a `<div>` tag instead, which is a more appropriate container for the search form. This change improves the semantic structure of the page and avoids potential rendering issues.
@AndrewDongminYoo AndrewDongminYoo force-pushed the refactor-404-search-layout branch from 30a8960 to bf2981b Compare April 26, 2025 09:51
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.

1 participant