codeatlas-ui lint: gutter, header sem frame e superfície aninhada (resto de #1154)

Offen
#1,318 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Maintainer antworten meist innerhalb von 1 Tag

Dieses Issue hat noch niemand übernommen.

Bewertung

Schwierigkeit
3/5
Geschätzter Aufwand
1-2 Tage
Anfängerfreundlichkeit
35/100
Issue-Typ
Feature
Klarheit
Größtenteils klar
Aktivitätsstatus
Aktiv
Tech-Stack
css, typescript
Bereich
frontend, tooling

Rechercherichtung

Start by reading how rules are registered and asserted in packages/ui/tests/ui-guard.test.ts, then the gate in scripts/mobile-gate.ts and the existing nested-surface rule from #920, which together show how a finding is produced and suppressed by a ca-ui-workaround marker. Before writing a rule, collect real gutter and fixed/sticky-header examples in the repo to pin down what each one rejects, using /docs/getting-started/layout-principles/ for the one-gutter-per-level rule. Done means each new rule has a test that fails without it, codeatlas-ui lint --rules lists it, and the nested-surface item is either extended with gate-only cases or closed with evidence.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Beschreibung

area:cli enhancement

Origem: o título de #1154. O PR #1317 entregou só os três critérios de aceite de #1154 (viewport-unit, fixed-bottom-offset, safe-area-bottom); estas três regras do título ficaram de fora para manter o PR pequeno.

O que falta

  • gutter: padding horizontal de página escrito à mão em vez de --ca-page-px / --ca-page-px-sm, ou um filho que soma o seu gutter ao do pai (regra 1 de /docs/getting-started/layout-principles/: um gutter por nível). Definir o que é reprovado antes de escrever a regra: p.ex. padding-inline: var(--ca-space-6) na raiz de uma página, ou AppList/AppForm dentro de PageShell sem embedded.
  • header sem frame: definir com o gate do AC (scripts/mobile-gate.ts) o que conta. Hipótese: um header position: fixed | sticky no topo sem --ca-safe-top e sem superfície opaca (--ca-chrome-surface). Reunir exemplos reais antes de escrever a regra.
  • superfície aninhada: nested-surface já existe (#920: Card/Surface como primeiro filho de outro). Verificar se o gate do AC pega casos que ela não pega (filho que não é o primeiro, Surface dentro de Card através de um wrapper, .ca-surface em CSS) e estender a regra, ou fechar este item com a evidência.

Critério de aceite (testável)

  • Cada regra nova tem um teste em packages/ui/tests/ui-guard.test.ts que falha antes da regra existir.
  • codeatlas-ui lint --rules lista as regras novas; um marcador ca-ui-workaround na linha ou acima desculpa um achado.

Relacionadas: #1154

Mãe: #1089

Vorherrschende Sprache
TypeScript
Sterne
6
Forks
3
Ø Merge
5 Std. 21 Min.
Gemergte PRs (30 T.)
378

Entwicklungsumgebung

Erste Schritte

  1. Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
  3. Forken Sie das Repository und arbeiten Sie in einem Branch.
  4. Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.

Mehr aus codeatlasdev/ui

Alle Issues in codeatlasdev/ui

Ähnliche Issues

Weitere Issues zu TypeScript

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.