Skip to content

Use a CSS class for the status legend footer instead of inline styles - #130

Merged
TheWitness merged 3 commits into
mainfrom
feature/pin-legend-bottom
Oct 8, 2026
Merged

TheWitness merged 3 commits into
mainfrom
feature/pin-legend-bottom

Conversation

@TheWitness

@TheWitness TheWitness commented Oct 7, 2026 •

Copy link
Copy Markdown
Member

Description

Originally the status legend was wrapped in an inline-styled, fixed-position container copied from MacTrack:

print '<div class="center" style="position:fixed;left:0;bottom:0;display:table;margin-left:auto;margin-right:auto;width:100%;">';

Per review, the inline style is replaced with a dedicated .servcheck_legend_footer CSS class, and it now lays the legend out as a centered footer in normal document flow rather than position: fixed. Staying in flow means it reserves its own space and no longer overlays the bottom pagination or bulk-action controls — resolving the reviewer's overlay finding. MacTrack and the other legend plugins (Thold/Monitor/Syslog) are being updated the same way.

How

  • Add .servcheck_legend_footer to css/common.css (always loaded, alongside the existing .servcheck_legend grid).
  • Swap the inline-styled wrapper in servcheck_test.php for <div class="center servcheck_legend_footer">.

No change to the legend chip markup/styles themselves.

Types of changes

  • Improvement (non-breaking change which improves existing functionality)

Checklist

  • My code follows the code style of this project.
  • php -l clean on the changed files.

Wrap the servcheck legend render in the same fixed-position footer container MacTrack uses, so the legend stays pinned to the bottom of the viewport.
@TheWitness
TheWitness requested review from bmfmancini and xmacan and a balanced review from Copilot October 7, 2026 20:07

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

The fixed legend needs reserved layout space to avoid obscuring bottom controls when its status chips wrap.

1 open finding
What changed in this PR

Pins the Service Check status legend to the viewport bottom to match MacTrack’s footer behavior.

Changes:

  • Adds a full-width, fixed-position wrapper around the existing legend without changing its markup or styles.
File Description
servcheck_test.php Wraps the test-list legend in a fixed footer container.

🧠 Review effort: Balanced


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread servcheck_test.php Outdated
cigamit
cigamit previously approved these changes Oct 7, 2026
Replace the inline fixed-position wrapper around the status legend with a
plugin-specific *LegendFooter class defined in the plugin's stylesheet. The
class lays the legend out as a centered footer in normal document flow, so it
no longer sits outside flow and overlay the final rows, pagination, or action
controls at the bottom of the page.
@TheWitness TheWitness changed the title Pin status legend to the bottom of the page (match MacTrack) Use a CSS class for the status legend footer instead of inline styles Oct 7, 2026
servcheck_test.php is a web page controller that chdir()s and includes auth.php at the top level, so it cannot be loaded into the isolated unit process and is absent from Clover. The legend-footer edit tripped the patch-coverage gate; add it to the unmeasured allowlist.
@TheWitness
TheWitness merged commit b606e56 into main Oct 8, 2026
3 checks passed
@TheWitness
TheWitness deleted the feature/pin-legend-bottom branch October 8, 2026 00:59
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.

4 participants