@payfit/unity-components 2.55.22 → 2.55.23

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.
@@ -13,7 +13,7 @@ export declare const catalogEntries: ({
13
13
  };
14
14
  related: never[];
15
15
  section: "components";
16
- tags: ("type:component" | "type:primitive" | "category:foundations")[];
16
+ tags: ("type:component" | "category:actions" | "category:tabular-data")[];
17
17
  title: string;
18
18
  principal?: undefined;
19
19
  } | {
@@ -31,7 +31,7 @@ export declare const catalogEntries: ({
31
31
  };
32
32
  related: never[];
33
33
  section: "components";
34
- tags: ("type:component" | "category:actions" | "category:tabular-data")[];
34
+ tags: ("type:component" | "type:primitive" | "category:foundations")[];
35
35
  title: string;
36
36
  principal?: undefined;
37
37
  } | {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@payfit/unity-components",
3
- "version": "2.55.22",
3
+ "version": "2.55.23",
4
4
  "module": "./dist/esm/index.js",
5
5
  "type": "module",
6
6
  "sideEffects": false,
@@ -50,18 +50,21 @@
50
50
  }
51
51
  },
52
52
  "./i18n/*.json": "./i18n/*.json",
53
+ "./agent-references/*": "./src/agent-references/*",
53
54
  "./package.json": "./package.json"
54
55
  },
55
56
  "files": [
56
57
  "dist",
57
58
  "i18n",
58
- "skills"
59
+ "skills",
60
+ "src/agent-references"
59
61
  ],
60
62
  "dependencies": {
61
63
  "@formatjs/intl": "4.1.12",
62
64
  "@hookform/devtools": "4.4.0",
63
65
  "@hookform/resolvers": "5.2.1",
64
66
  "@internationalized/date": "3.12.2",
67
+ "minimatch": "10.2.5",
65
68
  "@radix-ui/react-avatar": "1.2.2",
66
69
  "@radix-ui/react-slot": "1.3.0",
67
70
  "@react-aria/interactions": "3.28.1",
@@ -93,7 +96,7 @@
93
96
  "tailwind-variants": "3.2.2",
94
97
  "usehooks-ts": "3.1.1",
95
98
  "zod": "4.4.3",
96
- "@payfit/unity-illustrations": "2.55.22"
99
+ "@payfit/unity-illustrations": "2.55.23"
97
100
  },
98
101
  "peerDependencies": {
99
102
  "@hookform/devtools": "^4",
@@ -105,8 +108,8 @@
105
108
  "react-hook-form": "^7",
106
109
  "react-router-dom": "^5",
107
110
  "zod": "^3 || ^4",
108
- "@payfit/unity-icons": "2.55.22",
109
- "@payfit/unity-themes": "2.55.22"
111
+ "@payfit/unity-icons": "2.55.23",
112
+ "@payfit/unity-themes": "2.55.23"
110
113
  },
111
114
  "devDependencies": {
112
115
  "@figma/code-connect": "1.4.9",
@@ -156,10 +159,10 @@
156
159
  "@payfit/hr-apps-tsconfigs": "0.0.0-use.local",
157
160
  "@payfit/storybook-addon-console-errors": "0.0.0-use.local",
158
161
  "@payfit/storybook-config": "0.0.0-use.local",
159
- "@payfit/unity-icons": "2.55.22",
160
- "@payfit/unity-illustrations": "2.55.22",
161
- "@payfit/vite-configs": "0.0.0-use.local",
162
- "@payfit/unity-themes": "2.55.22"
162
+ "@payfit/unity-icons": "2.55.23",
163
+ "@payfit/unity-illustrations": "2.55.23",
164
+ "@payfit/unity-themes": "2.55.23",
165
+ "@payfit/vite-configs": "0.0.0-use.local"
163
166
  },
164
167
  "peerDependenciesMeta": {
165
168
  "@hookform/devtools": {
@@ -9,23 +9,34 @@ metadata:
9
9
  type: core
10
10
  library: '@payfit/unity-components'
11
11
  library_version: '2.x'
12
- sources:
13
- - 'PayFit/hr-apps:libs/shared/unity/components/src/index.ts'
14
- - 'PayFit/hr-apps:libs/shared/unity/icons/src/components/icon/parts/IconSprite.tsx'
15
- - 'PayFit/hr-apps:libs/shared/unity/icons/src/generated/index.ts'
16
- - 'PayFit/hr-apps:libs/shared/unity/components/OVERVIEW.md'
17
- - 'PayFit/hr-apps:AGENTS.md'
18
12
  ---
19
13
 
20
14
  Routing skill for selecting a Unity component before writing UI code. Walk
21
15
  the catalog, then the decision tree, then the commonly-confused pairs.
22
16
 
23
- ## Component Catalog
17
+ ## Component catalog
24
18
 
25
- Inspect the current exports in `src/index.ts`, then use the decision tree below.
26
- For a categorized catalog of commonly used exports, read
27
- [references/component-catalog.md](references/component-catalog.md) only when
28
- component discovery requires it.
19
+ Inspect the canonical [component catalog](../../src/agent-references/component-catalog.json)
20
+ before searching component source. It contains exact component ids, titles,
21
+ descriptions, keywords, sections, tags, related entries, and Storybook preview
22
+ metadata. There is no separate canonical Markdown catalog.
23
+
24
+ For a targeted lookup, search the full JSON and compare all plausible matches. Use whatever reliable local search tool is available (for example `rg`, a JSON-aware CLI, or a short Node script); do not assume `jq` is installed:
25
+
26
+ ```sh
27
+ rg -i -C 2 'dialog|confirmation|modal' \
28
+ libs/shared/unity/components/src/agent-references/component-catalog.json
29
+ ```
30
+
31
+ ## Standard operating procedure
32
+
33
+ 1. Extract the user's intent and expand it into synonyms, interaction patterns, and adjacent component terms.
34
+ 2. Search the complete catalog; do not stop at the first slice or plausible hit.
35
+ 3. Rank candidates by intent fit, description, keywords, tags, section, and related entries.
36
+ 4. Return the best match first. Mention an alternative only when the evidence is genuinely ambiguous.
37
+ 5. Search `libs/shared/unity/components/src` to confirm implementation details or locate nearby source.
38
+ 6. Inspect Storybook stories only for props, API details, or usage examples after a likely component has been identified. When the Storybook MCP is available, use its curated component manifest or matching Storybook entry as a complementary source for rendered examples; the canonical JSON catalog remains the source of truth for discovery.
39
+ 7. Walk the decision tree below before creating a custom primitive.
29
40
 
30
41
  ## Decision Tree
31
42
 
@@ -21,6 +21,14 @@ sources:
21
21
  Layout primitives, the `uy:` utility-class system, and the variant/merge tools
22
22
  used inside `@payfit/unity-components`.
23
23
 
24
+ ## Token lookup SOP
25
+
26
+ Before adding a token-based utility, search the canonical [Unity token catalog](../../../themes/src/agent-references/tokens-catalog.json).
27
+ Use its exact `name` and `cssVariable`, then consult the generated theme
28
+ blueprints under `../../../themes/src/storybook-mcp/` for common class
29
+ patterns. Do not infer token names from raw DTCG paths or standard Tailwind
30
+ conventions when the catalog can provide the transformed name.
31
+
24
32
  ## Setup
25
33
 
26
34
  ```tsx