@toolr/seedr 0.1.40 → 0.1.42

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.
@@ -55,8 +55,9 @@ async function loadManifest() {
55
55
  cache.assembled = manifest;
56
56
  return manifest;
57
57
  }
58
- async function getItem(slug) {
58
+ async function getItem(slug, type) {
59
59
  const manifest = await loadManifest();
60
+ if (type) return manifest.items.find((item) => item.slug === slug && item.type === type);
60
61
  return manifest.items.find((item) => item.slug === slug);
61
62
  }
62
63
  async function listItems(type) {
package/dist/cli.js CHANGED
@@ -23,7 +23,7 @@ import {
23
23
  skillHandler,
24
24
  uninstallSkill,
25
25
  writeTextFile
26
- } from "./chunk-HYIVKVYC.js";
26
+ } from "./chunk-6A3VPHMO.js";
27
27
 
28
28
  // src/cli.ts
29
29
  import { Command as Command5 } from "commander";
@@ -745,7 +745,7 @@ registerHandler(pluginHandler);
745
745
  // src/commands/add.ts
746
746
  async function resolveItem(itemName, type) {
747
747
  if (itemName) {
748
- const item = await getItem(itemName);
748
+ const item = await getItem(itemName, type);
749
749
  if (item) return item;
750
750
  const results = await searchItems(itemName);
751
751
  const filtered = type ? results.filter((r) => r.type === type) : results;
package/dist/index.d.ts CHANGED
@@ -54,7 +54,7 @@ declare function getToolConfig(tool: AITool): AIToolConfig;
54
54
  declare function getToolPath(tool: AITool, scope: "project" | "user", cwd?: string): string;
55
55
 
56
56
  declare function loadManifest(): Promise<RegistryManifest>;
57
- declare function getItem(slug: string): Promise<RegistryItem | undefined>;
57
+ declare function getItem(slug: string, type?: ComponentType): Promise<RegistryItem | undefined>;
58
58
  declare function listItems(type?: ComponentType): Promise<RegistryItem[]>;
59
59
  declare function searchItems(query: string): Promise<RegistryItem[]>;
60
60
  /**
package/dist/index.js CHANGED
@@ -15,7 +15,7 @@ import {
15
15
  loadManifest,
16
16
  searchItems,
17
17
  uninstallSkill
18
- } from "./chunk-HYIVKVYC.js";
18
+ } from "./chunk-6A3VPHMO.js";
19
19
 
20
20
  // src/converters/index.ts
21
21
  import matter from "gray-matter";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@toolr/seedr",
3
- "version": "0.1.40",
3
+ "version": "0.1.42",
4
4
  "description": "Seed your projects with AI configurations",
5
5
  "type": "module",
6
6
  "bin": {