Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Feature: Custom gutter columns for per-line metadata (blame, annotations)

Aperta
#306 3 commenti 2 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
35/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Tranquilla
Stack tecnologico
typescript
Ambito
frontend

Direzione di ricerca

Start by reading the contributing guidelines, then inspect the File component and how annotations and renderHoverUtility currently work. The proposal leaves the API choice open between a callback and multiple gutters, so first clarify that design before implementation. Done means persistent per-line metadata can appear alongside code without requiring a separately synchronized column.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

diffs enhancement
Prerequisites
Proposal

Add support for custom gutter columns that display per-line metadata alongside code content.

This could be exposed as a renderGutter callback or a gutters prop:

// Option A: Simple callback
<File
  file={file}
  renderGutter={(lineNumber: number) => (
    <span className="blame">{blameData[lineNumber].author}</span>
  )}
/>
// Option B: Multiple gutters
<File
  file={file}
  gutters={[
    { id: 'blame', width: 180, render: (line) => <BlameInfo line={line} /> }
  ]}
/>

This would enable displaying git blame information (author, commit hash, date), inline linting/CI
annotations, and custom line markers.

Motivation and context

When building code review or repository browsing tools, users often need to see git blame data alongside each line. Currently there's no way to render persistent per-line content in a gutter column:

  • Annotations render as blocks below lines, not inline
  • renderHoverUtility only shows on hover, not persistently
  • unsafeCSS can style lines but cannot inject text content

The workaround is building a parallel column outside the component with synchronized scrolling, which is complex due to Shadow DOM encapsulation.

This is a common feature in code editors (VS Code, GitHub, GitLab) and would expand the library's use cases for code analysis and review tools.

Lingua principale
TypeScript
Stelle
6.2k
Fork
226
Merge medio
1g 11h
PR unite (30g)
34

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di pierrecomputer/pierre

Tutte le issue di pierrecomputer/pierre

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.