Skip to content

fix(theme/default): keep inline rich text baseline aligned#84

Merged
mambax7 merged 1 commit into
XOOPS:masterfrom
mambax7:fix-default-admin-reset-inline-align
May 30, 2026
Merged

fix(theme/default): keep inline rich text baseline aligned#84
mambax7 merged 1 commit into
XOOPS:masterfrom
mambax7:fix-default-admin-reset-inline-align

Conversation

@mambax7
Copy link
Copy Markdown
Contributor

@mambax7 mambax7 commented May 30, 2026

Summary by Sourcery

Bug Fixes:

  • Ensure inline rich text keeps its baseline alignment by no longer applying top vertical alignment globally.

Summary by CodeRabbit

  • Style
    • Reformatted CSS selector organization for improved code consistency.

Review Change Stack

Copilot AI review requested due to automatic review settings May 30, 2026 06:33
@sourcery-ai
Copy link
Copy Markdown

sourcery-ai Bot commented May 30, 2026

Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

Adjusts the CSS reset so inline rich text elements retain baseline alignment while table-related elements are still vertically aligned to the top.

File-Level Changes

Change Details Files
Separate generic font inheritance rules from table element vertical alignment to preserve inline rich-text baseline behavior.
  • Close the universal selector ruleset after font-related properties to avoid applying vertical alignment globally.
  • Introduce a dedicated selector block for table, caption, tbody, tfoot, thead, tr, th, and td that sets vertical-align: top.
htdocs/modules/system/themes/default/css/reset.css

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 30, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 84ff9b09-6f18-481e-9808-997b35f96176

📥 Commits

Reviewing files that changed from the base of the PR and between 9034672 and b5735ec.

📒 Files selected for processing (1)
  • htdocs/modules/system/themes/default/css/reset.css

Walkthrough

The reset.css stylesheet selector list is reformatted by separating the table-related selectors (table, caption, tbody, tfoot, thead, tr, th, td) onto their own line, closing the preceding selector group for improved readability without functional changes.

Changes

CSS Formatting Update

Layer / File(s) Summary
CSS Reset selector list formatting
htdocs/modules/system/themes/default/css/reset.css
The top-level selector group is closed and table-related selectors are moved to their own line (lines 23–25) for improved stylesheet organization and readability.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Title check ⚠️ Warning The PR title mentions 'inline rich text baseline aligned' but the actual change only reformats CSS selectors in reset.css with no baseline or alignment-related modifications visible. Update the title to accurately reflect the actual change, such as 'refactor(theme/default): reorganize table selectors in reset.css' to match the CSS reformatting work.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@sourcery-ai sourcery-ai Bot left a comment

Choose a reason for hiding this comment

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

Hey - I've left some high level feedback:

  • Since vertical-align only has an effect on inline/inline-block/table-cell elements, consider narrowing the selector to the elements that actually need it (e.g. th, td or caption, th, td) instead of applying it to all table-related tags.
  • To keep the reset file easier to scan, you might want to keep the new vertical-align rule immediately adjacent to (or within) the related table reset block, matching the existing grouping/ordering conventions in this file.
Prompt for AI Agents
Please address the comments from this code review:

## Overall Comments
- Since `vertical-align` only has an effect on inline/inline-block/table-cell elements, consider narrowing the selector to the elements that actually need it (e.g. `th, td` or `caption, th, td`) instead of applying it to all table-related tags.
- To keep the reset file easier to scan, you might want to keep the new `vertical-align` rule immediately adjacent to (or within) the related table reset block, matching the existing grouping/ordering conventions in this file.

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request separates the vertical-align property into a new CSS rule block for table-related elements in reset.css. The reviewer recommended simplifying the selector of this new rule to target only th and td elements, as vertical-align is ineffective on block-level or table-structure elements like table, caption, tbody, tfoot, thead, and tr.

Comment on lines +25 to 27
table, caption, tbody, tfoot, thead, tr, th, td {
vertical-align: top;
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

The vertical-align property only applies to inline-level elements and table cells (th, td). It has no effect on block-level or table-structure elements like table, caption, tbody, tfoot, thead, and tr.

Simplifying this selector to target only th, td keeps the CSS clean and avoids applying redundant properties.

th, td {
    vertical-align:     top;
    }

@codecov
Copy link
Copy Markdown

codecov Bot commented May 30, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 18.19%. Comparing base (62d52ff) to head (b5735ec).
⚠️ Report is 11 commits behind head on master.

Additional details and impacted files
@@             Coverage Diff              @@
##             master      #84      +/-   ##
============================================
+ Coverage     18.13%   18.19%   +0.05%     
- Complexity     7854     7861       +7     
============================================
  Files           666      667       +1     
  Lines         43208    43259      +51     
============================================
+ Hits           7837     7872      +35     
- Misses        35371    35387      +16     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

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 fixes baseline alignment for inline rich text in the System module’s default admin theme by limiting vertical-align: top to table-related elements instead of applying it to inline text elements.

Changes:

  • Removes global vertical-align: top from the broad reset selector.
  • Adds a narrower table-element rule preserving top alignment for admin tables.

@mambax7 mambax7 merged commit 84b831a into XOOPS:master May 30, 2026
12 checks passed
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