You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This PR has two distinct concerns: a comment cleanup and a meaningful functional change in FilterAndSortContainer.
Comment Cleanup (15 of 19 files)
The bulk of the PR removes AIDEV-NOTE: prefixes from inline comments, converting them to plain comments. The comments themselves are preserved — only the prefix is stripped. This is clean and consistent with the previous commit (67b084d).
One cosmetic nit in CoverList.astro:26:
- /* AIDEV-NOTE: The 250px values below cannot be extracted...+ /* The 250px values below cannot be extracted...
The replacement has extra leading spaces (/* The). Not a bug, just slightly untidy.
The more substantive change is the removal of this useEffect:
// Bridge for jsdom: native browsers fire cancel automatically; jsdom does not.useEffect(()=>{consthandleKeyDown=(e: KeyboardEvent): void=>{if(e.key==="Escape"&&filterDrawerVisible){dialogRef.current?.dispatchEvent(newEvent("cancel"));dialogRef.current?.close();}};document.addEventListener("keydown",handleKeyDown);return(): void=>document.removeEventListener("keydown",handleKeyDown);},[filterDrawerVisible]);
Assessment: correct. This was a workaround for jsdom's lack of native <dialog> Escape handling, not required in real browsers. Real browsers fire cancel and close the dialog natively. Removing it keeps production code clean of test-environment shims.
The corresponding test update correctly simulates the native browser sequence:
This directly mirrors what browsers do, without needing the bridge in production code.
The removal of the scrollIntoView mock from the spec is also correct — it was only needed for behavior that no longer exists.
PagefindSearch.astro Comment Style
HTML `` comments were converted to JSX {/* */} comments. Both are valid in `.astro` files, but the JSX style is slightly more consistent with the surrounding component expressions. The two free-standing block comments (for `` tags) now use wrapping `{ }` blocks:
{/* <template> content is inert until cloned by search-box.ts. ... */}
This is valid Astro syntax and renders no output, though it adds some visual noise. No functional concern.
Summary
The PR is clean and correct. The functional change (removing the jsdom bridge) is the right call — production code shouldn't carry test-environment workarounds. No bugs or regressions identified.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.