fix(ui-library): render table dividers with separate borders for Firefox#23387
Open
FAMarfuaty wants to merge 1 commit into
Conversation
Firefox drops a collapsed row divider along a tall cell's edge when its neighbour is much shorter, so the separator above a grown bulk-editor inline-edit row disappeared. Switch the default-variant table to border-collapse: separate with per-cell borders so each divider paints independently and Firefox renders it reliably. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Coverage Report for CI Build 6Coverage increased (+2.6%) to 60.525%Details
Uncovered ChangesNo uncovered changes found. Coverage RegressionsNo coverage regressions found. Coverage Stats💛 - Coveralls |
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Context
In Firefox only, when a bulk-editor row entered inline-edit mode (text is replaced by
Textareainputs, growing the cells), the horizontal separator line at the top of the editing row was cut off / missing. Chrome and Safari rendered it correctly. The ui-libraryTable(.yst-table--default) inheritedborder-collapse: collapsefrom the root preflight and placed the row dividers on the<tr>via Tailwinddivide-y; Firefox drops a collapsed border along the tall edge of a cell when an adjacent cell is much shorter, so the divider disappeared next to the grown edit cell.Tracks Yoast/reserved-tasks#1293 (part of Bulk editor — Frontend).
Summary
This PR can be summarized in the following changelog entry:
Relevant technical choices:
border-collapse: collapse, move the dividers from the<tr>onto the cells) does not work: Firefox's bug is in collapsed-border resolution, so a cell-side border is still dropped. Measured in real Firefox, divider coverage above the tall cells stayed at 0%. Switching.yst-table--defaulttoborder-collapse: separate; border-spacing: 0makes each cell paint its own border independently, which Firefox renders reliably (coverage 100%, including above the tall cells). Because row and row-group borders are ignored inseparatemode, the thead/tbody line moves onto the header cells (border-b) and the row dividers onto the body cells (border-t).@yoast/ui-libraryrather than scoping to the bulk-editor page, so the same Firefox quirk is fixed for every default-variant table. Blast radius is limited to default-variant tables;minimal-variant tables are untouched.Test instructions
Test instructions for the acceptance test before the PR gets merged
This PR can be acceptance tested by following these steps:
Relevant test scenarios
This is a Firefox-specific rendering fix, so verify in Firefox primarily, and confirm no regression in Chrome and Safari (single dividers, correct corners). It also touches the shared
Tablecomponent, so spot-check other default-variant tables: the Dashboard task list and Settings → RSS.Test instructions for QA when the code is in the RC
QA can test this PR by following these steps:
Impact check
This PR affects the following parts of the plugin, which may require extra testing:
@yoast/ui-libraryTablecomponent (default variant). Every default-variant table is affected: the bulk editor table, the Dashboard task list, Settings → RSS, and the related-keyphrase-suggestions table.minimal-variant tables (Free redirects, Dashboard widget) are not affected.Other environments
[shopify-seo], added test instructions for Shopify and attached theShopifylabel to this PR.[yoast-doc-extension], added test instructions for Yoast SEO for Google Docs and attached theGoogle Docs Add-onlabel to this PR.Documentation
Quality assurance
grunt build:imagesand committed the results, if my PR introduces or edits images or SVGs.Innovation
innovationlabel.Fixes Yoast/reserved-tasks#1293
🤖 Generated with Claude Code