← ClaudeAtlas

webtweak-reconcilelisted

Reconcile visual edits captured by the webtweak tool into a site's real source. Reads a <page>.webtweak.json edits file, locates each patched element by its fingerprint, writes clean CSS in the site's house conventions (single-element scope by default), translates nudge intent into clean margin/padding, and marks batches reconciled. Use when the user has finished a webtweak session, says "reconcile my webtweak edits", "apply the webtweak changes", mentions a *.webtweak.json file, or wants webtweak edits folded into source and optionally pushed.
stueydubs/webtweak · ★ 2 · Web & Frontend · score 63
Install: claude install-skill stueydubs/webtweak
# webtweak reconcile The second half of the webtweak loop. The webtweak tool (`~/projects/webtweak`) captures visual edits as *intent* and never touches source; this skill turns that intent into clean source. Reconcile is judgment work - when a match or a scope decision is genuinely ambiguous, ask rather than guess. That is the whole reason this half is a skill and not code. ## Input A `<page>.webtweak.json` file sitting next to the edited page: ``` { target, batches: [ { sessionId, savedAt, viewport, status, patches: [ { fingerprint, changes: { ...cssProps, nudge? }, media?: { "<condition>": { ...cssProps } } } ] } ] } ``` Only `status: "pending"` batches are reconciled. `reconciled` batches are history - never re-apply them. Two patch shapes share the array. An **edit patch** (`{ fingerprint, changes, media? }`, no `op`) restyles an element that already exists in source - the original and most common case, and the only one that can carry the optional `media` map described below. A **create patch** (`{ op: "create", ... }`) *inserts* a new shape element - webtweak's only element-creation feature. Branch on `op`: treat anything without `op` (or with `op: "edit"`) as an edit patch; `op: "create"` is handled in **"The `create` op"** below. - `fingerprint`: `{ tag, id, classes, text, ownText, selector, siblingIndex, openTag }`. `ownText` is the element's own direct text (excluding descendants') - prefer it for matching leaf/text elements; `text` includes descendant text -