Skip to content

Style method entries as signature cards in aliki theme#1669

Merged
st0012 merged 1 commit intomasterfrom
signature-card-design
Apr 9, 2026
Merged

Style method entries as signature cards in aliki theme#1669
st0012 merged 1 commit intomasterfrom
signature-card-design

Conversation

@st0012
Copy link
Copy Markdown
Member

@st0012 st0012 commented Apr 2, 2026

Summary

  • Add subtle background card with left accent border to method headers, visually separating the API signature zone from documentation prose
  • New --color-sig-bg design token (lighter than --color-code-bg) for both light and dark themes
  • Source button repositioned with absolute positioning (was float-based)
  • Method heading links no longer inherit global underline styles
  • Description body gets slight left padding to align with the accent border

CSS-only change — no template modifications.

Before / After

Before After
sig-card-before Screenshot 2026-04-02 at 15 25 10

@matzbot
Copy link
Copy Markdown
Collaborator

matzbot commented Apr 2, 2026

🚀 Preview deployment available at: https://062b9e5c.rdoc-6cd.pages.dev (commit: 4b26c40)

@st0012 st0012 marked this pull request as ready for review April 2, 2026 14:39
@st0012 st0012 force-pushed the signature-card-design branch 2 times, most recently from 7235073 to 251f5db Compare April 2, 2026 16:23
@st0012 st0012 force-pushed the signature-card-design branch from 251f5db to be86678 Compare April 2, 2026 18:05
@kou kou requested a review from Copilot April 8, 2026 14:39
Copy link
Copy Markdown
Member

@kou kou left a comment

Choose a reason for hiding this comment

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

+1

Copy link
Copy Markdown

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

Updates the Aliki RDoc theme CSS to visually present method signature blocks as “cards,” improving separation between API signatures and documentation text while keeping templates unchanged.

Changes:

  • Introduces new signature-specific design tokens (--color-sig-bg, --color-sig-border) for light/dark themes.
  • Styles method headers with a background “card” and accent border; removes underline styling from method heading links.
  • Repositions the “Source” toggle button using absolute positioning and adjusts spacing in method descriptions.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 1337 to 1341
main .method-controls {
float: right;
position: absolute;
top: var(--space-3);
right: var(--space-3);
}
Copy link

Copilot AI Apr 8, 2026

Choose a reason for hiding this comment

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

main .method-controls is now absolutely positioned, but .method-header/.method-heading no longer reserves horizontal space for it (the previous max-width: calc(100% - 6em) was removed). With long call sequences or method names, the signature text can render underneath the “Source” control.

Consider reserving space via padding-right on .method-header/.method-heading (or a grid/flex layout that allocates a dedicated column for .method-controls) so the signature and control cannot overlap.

Copilot uses AI. Check for mistakes.
@st0012 st0012 force-pushed the signature-card-design branch from be86678 to 4b26c40 Compare April 9, 2026 14:54
@st0012 st0012 merged commit dc7a167 into master Apr 9, 2026
78 checks passed
@st0012 st0012 deleted the signature-card-design branch April 9, 2026 15:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants