skillui 1.1.8 → 1.1.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/cli.js +54 -3
  2. package/package.json +1 -1
package/dist/cli.js CHANGED
@@ -100917,14 +100917,65 @@ async function generateSkill(profile, designMdContent, outputDir, screenshotPath
100917
100917
  profile = { ...profile, fontSources: result.updatedSources };
100918
100918
  bundledFontCount = result.bundledCount;
100919
100919
  }
100920
- const skillMd = generateSkillMd(profile, screenshotPath, ultraResult);
100921
- fs13.writeFileSync(path14.join(skillDir, "SKILL.md"), skillMd, "utf-8");
100922
100920
  const finalDesignMd = bundledFontCount > 0 ? generateDesignMd(profile, screenshotPath) : designMdContent;
100923
100921
  fs13.writeFileSync(path14.join(refsDir, "DESIGN.md"), finalDesignMd, "utf-8");
100922
+ let skillMd = generateSkillMd(profile, screenshotPath, ultraResult);
100923
+ skillMd += embedReferenceFiles(refsDir, skillDir);
100924
+ fs13.writeFileSync(path14.join(skillDir, "SKILL.md"), skillMd, "utf-8");
100924
100925
  const skillFile = path14.join(outputDir, `${skillDirName}.skill`);
100925
100926
  await createZip(skillDir, skillFile);
100926
100927
  return { skillDir, skillFile };
100927
100928
  }
100929
+ function embedReferenceFiles(refsDir, skillDir) {
100930
+ let md = `
100931
+ ---
100932
+
100933
+ # Full Reference Files
100934
+
100935
+ `;
100936
+ md += `> All reference files are embedded below so Claude has complete context from /skills.
100937
+
100938
+ `;
100939
+ const refFiles = [
100940
+ { file: "DESIGN.md", title: "Design System Tokens" },
100941
+ { file: "ANIMATIONS.md", title: "Animations & Motion" },
100942
+ { file: "LAYOUT.md", title: "Layout & Grid" },
100943
+ { file: "COMPONENTS.md", title: "Component Patterns" },
100944
+ { file: "INTERACTIONS.md", title: "Interactions & States" }
100945
+ ];
100946
+ for (const { file, title } of refFiles) {
100947
+ const filePath = path14.join(refsDir, file);
100948
+ if (!fs13.existsSync(filePath)) continue;
100949
+ let content = fs13.readFileSync(filePath, "utf-8").trim();
100950
+ if (content.startsWith("---")) {
100951
+ const end = content.indexOf("---", 3);
100952
+ if (end !== -1) content = content.slice(end + 3).trim();
100953
+ }
100954
+ md += `## ${title}
100955
+
100956
+ `;
100957
+ md += content + "\n\n";
100958
+ }
100959
+ const tokensDir = path14.join(skillDir, "tokens");
100960
+ const tokenFiles = ["colors.json", "spacing.json", "typography.json"];
100961
+ const tokenSections = [];
100962
+ for (const tf of tokenFiles) {
100963
+ const p = path14.join(tokensDir, tf);
100964
+ if (!fs13.existsSync(p)) continue;
100965
+ const raw = fs13.readFileSync(p, "utf-8").trim();
100966
+ tokenSections.push(`### ${tf}
100967
+ \`\`\`json
100968
+ ${raw}
100969
+ \`\`\``);
100970
+ }
100971
+ if (tokenSections.length > 0) {
100972
+ md += `## Design Tokens (JSON)
100973
+
100974
+ `;
100975
+ md += tokenSections.join("\n\n") + "\n\n";
100976
+ }
100977
+ return md;
100978
+ }
100928
100979
  function generateSkillMd(profile, screenshotPath, ultraResult) {
100929
100980
  const bg = profile.colors.find((c) => c.role === "background");
100930
100981
  const surface = profile.colors.find((c) => c.role === "surface");
@@ -104559,7 +104610,7 @@ gradient.pastel = pastel;
104559
104610
  // src/ui.ts
104560
104611
  var import_cli_progress = __toESM(require_cli_progress());
104561
104612
  var path15 = __toESM(require("path"));
104562
- var VERSION = "1.1.8";
104613
+ var VERSION = "1.1.9";
104563
104614
  function padAnsi(str, width) {
104564
104615
  const raw = stripAnsi(str);
104565
104616
  return str + " ".repeat(Math.max(0, width - raw.length));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "skillui",
3
- "version": "1.1.8",
3
+ "version": "1.1.9",
4
4
  "description": "Reverse-engineer design systems from any website, repo, or project. Extracts colors, fonts, spacing, animations, and components — packaged as a .skill file for Claude. Pure static analysis, zero AI, zero API keys.",
5
5
  "main": "dist/cli.js",
6
6
  "bin": {