Build and adjust Lincx ad templates (HTML+CSS). Use when the user asks to create, modify, preview, or save a Lincx template, or when a slash command in the `/lincx-template-*` family is invoked.
How this skill is triggered — by the user, by Claude, or both
Slash command
/templates-editor-plugin:editing-lincx-templatesThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
You help users author and adjust Lincx ad creative templates (HTML + CSS) bound to a `creativeAssetGroup` (CAG) schema. You work with the `lincx-mcp` for reads (template, CAG, zone ads) and cache results into `./.lincx-session.json` so a local preview loop runs automatically on every edit.
You help users author and adjust Lincx ad creative templates (HTML + CSS) bound to a creativeAssetGroup (CAG) schema. You work with the lincx-mcp for reads (template, CAG, zone ads) and cache results into ./.lincx-session.json so a local preview loop runs automatically on every edit.
Two sources of truth, split by role:
${CLAUDE_PLUGIN_ROOT}/references/ are the authority for structure, conventions, class names, Mustache forms, data attributes, JS helpers, and required legal/tracking markup.creativeAssetGroup) for the specific template you're working on is the authority for which fields exist, their types, and their spelling. The CAG is loaded per session via mcp__claude_ai_Lincx__get_creative_asset_group(id=…) in flows A/B below, and cached in session state as cagSchema.Never confuse the two. A field that appears in an example under patterns/example-N/ does NOT mean that field exists on the template you're editing. Every CAG is its own contract.
Before proposing any template HTML or CSS, read the references in this order:
${CLAUDE_PLUGIN_ROOT}/references/README.md — the read-order overview and the example-picker table.${CLAUDE_PLUGIN_ROOT}/references/CHECKLIST.md — the deterministic production checklist. Every item is a MUST unless marked OPTIONAL. §6 is critical: it explains that fields come from the CAG, not from any universal catalog.${CLAUDE_PLUGIN_ROOT}/references/patterns.md — copy-paste-ready snippets. Jump to the section(s) matching the user's intent (listicle, sticky bar, product card, multi-CTA, rating, video, footer, etc.). Remember: the field names in snippets are illustrative — swap them for the CAG's field names.${CLAUDE_PLUGIN_ROOT}/references/anti-patterns.md — must-not-do list. At minimum, re-read the 🔴 production-breaking section every session. Re-check the matching entry before doing anything that could be an anti-pattern.${CLAUDE_PLUGIN_ROOT}/references/patterns/example-N/ directory — real production template + stylesheet + a brief notes.md. Use the picker table in references/README.md to choose the example that matches the brief. Copy the structure; don't copy the field names.Then:
data-lincx-cta, never drop legal disclosure blocks.Depth of consultation:
anti-patterns.md 🔴 section; touch the code. Skip the rest.Single source of truth: ./.lincx-session.json in the user's current working directory. Shape:
{
"previewDisabled": false,
"activeTemplates": [
{
"id": "<stable id, e.g. entry-1>",
"templateId": "<string or null>",
"creativeAssetGroupId": "<string>",
"htmlPath": "<user-chosen path>",
"cssPath": "<user-chosen path>",
"previewPath": "<typically sibling preview.html>",
"version": "<number or null>",
"dirty": false,
"cagSchema": { "fields": [ ... ] },
"mockAdsSource": { "kind": "synthesized" | "zone", "zoneId": "..." },
"mockAds": []
}
]
}
Use ${CLAUDE_PLUGIN_ROOT}/scripts/session-state.mjs (readSessionState, writeSessionState, upsertEntry, removeEntry, findEntryByPath) via a small inline node --input-type=module -e ... invocation. Do not hand-parse the file.
/lincx-template-edit <id>)auth_status — if unauthenticated, tell the user to run auth_login and stop.htmlPath and cssPath under their current project). Do not default silently.get_template(id) → write html and css to the chosen paths.get_creative_asset_group(id=<creativeAssetGroupId from template>) → cache as cagSchema..lincx-session.json (set dirty:false, version from template, previewOpened:false).node ${CLAUDE_PLUGIN_ROOT}/scripts/preview-render.mjs <entryId>. The browser opens.dirty:true after any write./lincx-template-save → Flow C./lincx-template-new <name>)auth_status.list_creative_asset_groups → ask the user to pick a CAG. Record creativeAssetGroupId.htmlPath and cssPath. Create empty files at those paths.get_creative_asset_group(id=<chosen>) → cache cagSchema.templateId:null.dirty:true./lincx-template-save).lincx-session.json.dirty:true:
mcp__claude_ai_Lincx__save_template_version is available in this session's tools.templateId != null: import saveAsync from ${CLAUDE_PLUGIN_ROOT}/scripts/save-seam.mjs; wrap the MCP call in a mcpWrite function you pass in:
async function mcpWrite({ templateId, html, css }) {
// Call the MCP tool with these params; return { version }.
}
Call saveAsync(entry, { mcpWriteAvailable: true, mcpWrite }).save and call save(entry, { mcpWriteAvailable: false }).dirty; if mode was mcp, update version from the result./lincx-template-load-ads <zoneId>)get_zone_ads(id=<zoneId>).mockAds: <returned>, mockAdsSource: { kind:"zone", zoneId }./lincx-template-preview-toggle)previewDisabled in session state./lincx-template-refresh-schema)get_creative_asset_group(id=entry.creativeAssetGroupId) → replace cagSchema.versions/ yourself. The save seam does that.save_template_version (when the tool exists). No HTTP calls, no CLI shell-outs..lincx-session.json.bak and start fresh../.lincx-session.log.npx claudepluginhub zakasalaheddine/lincx-marketplace --plugin templates-editor-pluginCreates, edits, and optimizes skills for Claude Code, including drafting, evaluating with test prompts, iterating on performance, and improving skill descriptions for better triggering accuracy.