Skip to content

style: subtle color and size adjustment for <details> in the readme#2392

Merged
ghostdevv merged 2 commits intonpmx-dev:mainfrom
ayo-run:main
Apr 5, 2026
Merged

style: subtle color and size adjustment for <details> in the readme#2392
ghostdevv merged 2 commits intonpmx-dev:mainfrom
ayo-run:main

Conversation

@ayo-run
Copy link
Copy Markdown
Contributor

@ayo-run ayo-run commented Apr 5, 2026

🔗 Linked issue

resolves #2391

🧭 Context

Hello, sorry if I went ahead and fixed this one without discussion first of the issue 😆. It's a small one. This PR will implement a subtle difference in <details> content.

📚 Description

The PR applies a change in how <details> on the readme of a package is rendered. The <summary> content remains unchanged, while the content hidden/shown when toggling are smaller and subtler. More description on the issue #2391

See screenshots

The following are screenshots for the readme of @ayo-run/mnswpr

npmjs.com npmx.dev (before) npmx.dev (after)
Screenshot from 2026-04-05 16-59-46 Screenshot from 2026-04-05 17-14-26 Screenshot from 2026-04-05 17-14-15

@vercel
Copy link
Copy Markdown

vercel bot commented Apr 5, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
npmx.dev (canary) Ready Ready Preview, Comment Apr 5, 2026 3:21pm
2 Skipped Deployments
Project Deployment Actions Updated (UTC)
docs.npmx.dev Ignored Ignored Preview Apr 5, 2026 3:21pm
npmx-lunaria Ignored Ignored Apr 5, 2026 3:21pm

Request Review

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 5, 2026

Hello! Thank you for opening your first PR to npmx, @ayo-run! 🚀

Here’s what will happen next:

  1. Our GitHub bots will run to check your changes.
    If they spot any issues you will see some error messages on this PR.
    Don’t hesitate to ask any questions if you’re not sure what these mean!

  2. In a few minutes, you’ll be able to see a preview of your changes on Vercel

  3. One or more of our maintainers will take a look and may ask you to make changes.
    We try to be responsive, but don’t worry if this takes a few days.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Apr 5, 2026

📝 Walkthrough

Walkthrough

This pull request introduces styling enhancements to the app/components/Readme.vue file for improved visual differentiation of <details> elements in rendered README content. The changes add CSS rules that apply a default font size and subtle text colour to <details> elements, alongside customised styling for nested summary elements. Minor whitespace formatting adjustments are also included. No functional logic modifications to scripts or templates were made.

Possibly related PRs

Suggested labels

front

Suggested reviewers

  • danielroe
  • 43081j
🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description check ✅ Passed The PR description is directly related to the changeset, explaining the styling modifications to
Details elements in the README component.
Linked Issues check ✅ Passed The PR successfully implements the styling requirements from issue #2391: subtle colour and size adjustments for
content with customised styling.
Out of Scope Changes check ✅ Passed All changes are within scope, limited to styling modifications in Readme.vue for
Details elements as specified in the linked issue.

✏️ 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.

@codecov
Copy link
Copy Markdown

codecov bot commented Apr 5, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ All tests successful. No failed tests found.

📢 Thoughts on this report? Let us know!

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

🧹 Nitpick comments (1)
app/components/Readme.vue (1)

478-490: LGTM! Correctly implements the subtle styling for details elements.

The styling achieves the PR objective:

  • Details content is rendered smaller (0.925rem) and with a more subtle colour (--fg-subtle)
  • Summary remains at standard size (1rem) and colour (--fg-muted, matching the base readme text on line 81)

The comment clearly explains the font-size choice. The nested CSS syntax is valid and should compile correctly with Vue 3 and modern build tools.

Optional: Consider more explicit selector syntax

For improved clarity, you could use a separate rule instead of nested syntax:

 /* Details element */
 .readme :deep(details) {
   /**
    * same size as [data-level='5']
    */
   font-size: 0.925rem;
   color: var(--fg-subtle);
+}

-  summary {
-    font-size: 1rem;
-    color: var(--fg-muted);
-  }
+.readme :deep(details summary) {
+  font-size: 1rem;
+  color: var(--fg-muted);
 }

The current nested syntax works fine; this is purely a stylistic preference.


ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 52362977-0f01-40e8-a37d-78734b877aac

📥 Commits

Reviewing files that changed from the base of the PR and between 5324b96 and 50379bf.

📒 Files selected for processing (1)
  • app/components/Readme.vue

@ghostdevv ghostdevv added this pull request to the merge queue Apr 5, 2026
@ghostdevv ghostdevv removed this pull request from the merge queue due to a manual request Apr 5, 2026
@ghostdevv ghostdevv changed the title style: subtle color and size adjustment for <details> in the readme fix(style): subtle color and size adjustment for <details> in the readme Apr 5, 2026
@ghostdevv ghostdevv changed the title fix(style): subtle color and size adjustment for <details> in the readme style: subtle color and size adjustment for <details> in the readme Apr 5, 2026
@ghostdevv ghostdevv added this pull request to the merge queue Apr 5, 2026
Merged via the queue into npmx-dev:main with commit 5eb1627 Apr 5, 2026
20 of 21 checks passed
@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 5, 2026

Thanks for your first contribution, @ayo-run! ✨

We'd love to welcome you to the npmx community. Come and say hi on Discord! And once you've joined, visit npmx.wamellow.com to claim the contributor role.

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.

style: subtle color and size adjustment for <details> in the readme

2 participants