Skip to content

feat: show tagged GitHub accounts in bios as avatar pills - #720

Merged
nunomaduro merged 2 commits into
dev-null-sh:productionfrom
0z3:feat/bio-github-mentions
Oct 19, 2026
Merged

nunomaduro merged 2 commits into
dev-null-sh:productionfrom
0z3:feat/bio-github-mentions

Conversation

@0z3

@0z3 0z3 commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

TL;DR: @name tags in a synced GitHub bio or company now show as a small pill with that account's GitHub avatar. Clicking one opens the account on GitHub in a new tab.

Before / after

Before After
Before, light After, light
Before, dark After, dark

Hovering a pill turns it blue. Only the colors change, so the pill keeps its width and the bio text doesn't jump:

After, hovering the laravel pill

The screenshots render the real BioText component with the app's compiled CSS, using Nuno's current GitHub bio.

What changed

  • New resources/js/components/bio-text.tsx. Each @name becomes a pill with a round avatar from github.com/<name>.png and the handle next to it.
  • The profile page, the hover card and the sidebar use it for the bio.
  • The company field on the profile page uses it too, because GitHub links an @org there as well. A plain company name like "Laravel" stays plain text.
  • Search, connections and who-to-follow keep plain text. Those rows are already links to the profile, and a link inside a link is invalid HTML.
  • The mention regex moved from linkified-text.tsx to resources/js/lib/mentions.ts, with its comment unchanged. Without the move, linkified-text imports user-preview, which imports bio-text, which would import linkified-text again. The sync note in app/Services/Mentions.php now points to the new file.

Details

  • Tags follow the same rule as commit mentions, so emails, @scope/package and @vue.js stay plain text.
  • Copying the bio keeps the @. It stays in the text at zero font size, the same trick shortened URLs use.
  • If a handle doesn't exist on GitHub, its avatar fails to load and the pill shows a gray circle instead of a broken image.
  • Avatars load straight from GitHub like on the about page, so this adds no API calls and no database columns.

Checks

  • bunx vp test run tests/Unit/BioText.test.tsx tests/Unit/LinkifiedText.test.tsx: 51 passed, 4 of them new
  • bun run test:unit: 86 passed
  • bun run test:lint and bun run test:types: pass
  • vendor/bin/pint --test app/Services/Mentions.php: pass
  • vp build: builds
  • Pest not run. The only PHP change is a comment.

0z3 added 2 commits October 19, 2026 23:27
A bio synced from GitHub can tag users and organizations with @name.
Those tags now show as a small pill with the account's GitHub avatar
and link to it on GitHub, on the profile page, the hover card and the
sidebar. The mention rule moves to resources/js/lib/mentions.ts so the
bio and linkified text can share it without importing each other.
GitHub links an @org in the company field too. The profile page now shows those tags with the same pill as the bio.
@nunomaduro
nunomaduro merged commit be434e6 into dev-null-sh:production Oct 19, 2026
6 checks passed
@mnapoli

mnapoli commented Oct 19, 2026

Copy link
Copy Markdown
Member

looks awesome!

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.

3 participants