@1money/component-ui 0.0.23 → 0.0.24

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 (97) hide show
  1. package/es/stories/docs/ComponentDocsPage.js +234 -0
  2. package/es/stories/docs/componentDocMeta.js +97 -0
  3. package/es/stories/docs/storybook-docs.css +79 -0
  4. package/lib/stories/docs/ComponentDocsPage.js +244 -0
  5. package/lib/stories/docs/componentDocMeta.js +104 -0
  6. package/lib/stories/docs/storybook-docs.css +79 -0
  7. package/package.json +23 -8
  8. package/scripts/mcp-server/README.md +267 -0
  9. package/scripts/mcp-server/bin.mjs +2 -0
  10. package/scripts/mcp-server/drift.json +5 -0
  11. package/scripts/mcp-server/examples.generated.json +2651 -0
  12. package/scripts/mcp-server/index.generated.json +18098 -0
  13. package/scripts/mcp-server/index.mjs +308 -26
  14. package/scripts/mcp-server/tools/get-examples.mjs +125 -0
  15. package/scripts/mcp-server/tools/get-library-info.mjs +25 -0
  16. package/scripts/mcp-server/tools/get-symbol.mjs +232 -0
  17. package/scripts/mcp-server/tools/get-token.mjs +60 -0
  18. package/scripts/mcp-server/tools/list-icons.mjs +38 -0
  19. package/scripts/mcp-server/tools/list-symbols.mjs +46 -0
  20. package/scripts/mcp-server/tools/resolve-import.mjs +125 -0
  21. package/scripts/mcp-server/tools/search-symbols.mjs +79 -0
  22. package/.agents/skills/1money-component-dev/SKILL.md +0 -224
  23. package/.agents/skills/1money-component-dev/checklist.md +0 -159
  24. package/.agents/skills/1money-component-dev/references/ComponentPatterns.md +0 -478
  25. package/.agents/skills/1money-component-dev/references/FigmaExtractionChecklist.md +0 -144
  26. package/.agents/skills/1money-component-dev/references/HooksGuide.md +0 -360
  27. package/.agents/skills/1money-component-dev/references/SemanticColors.md +0 -215
  28. package/.agents/skills/1money-component-dev/references/StyleSystemAPI.md +0 -389
  29. package/.claude/settings.local.json +0 -120
  30. package/.claude/skills/1money-component-dev/SKILL.md +0 -229
  31. package/.claude/skills/1money-component-dev/checklist.md +0 -159
  32. package/.claude/skills/1money-component-dev/references/ComponentPatterns.md +0 -478
  33. package/.claude/skills/1money-component-dev/references/FigmaExtractionChecklist.md +0 -144
  34. package/.claude/skills/1money-component-dev/references/HooksGuide.md +0 -360
  35. package/.claude/skills/1money-component-dev/references/SemanticColors.md +0 -215
  36. package/.claude/skills/1money-component-dev/references/StyleSystemAPI.md +0 -389
  37. package/.claude/skills/1money-component-review/SKILL.md +0 -316
  38. package/.claude/skills/component-pipeline/SKILL.md +0 -116
  39. package/.claude/skills/component-pipeline/checklist.md +0 -125
  40. package/.hintrc +0 -13
  41. package/@types/global.d.ts +0 -28
  42. package/AGENTS.md +0 -546
  43. package/CLAUDE.md +0 -1
  44. package/jest.setup.d.ts +0 -1
  45. package/jest.setup.ts +0 -1
  46. package/patches/primereact.patch +0 -323
  47. package/patches/react-pro-sidebar.patch +0 -6421
  48. package/public/favicon.ico +0 -0
  49. package/public/fonts/Aeonik/Aeonik-Air.ttf +0 -0
  50. package/public/fonts/Aeonik/Aeonik-AirItalic.ttf +0 -0
  51. package/public/fonts/Aeonik/Aeonik-Black.ttf +0 -0
  52. package/public/fonts/Aeonik/Aeonik-BlackItalic.ttf +0 -0
  53. package/public/fonts/Aeonik/Aeonik-Bold.ttf +0 -0
  54. package/public/fonts/Aeonik/Aeonik-BoldItalic.ttf +0 -0
  55. package/public/fonts/Aeonik/Aeonik-Light.ttf +0 -0
  56. package/public/fonts/Aeonik/Aeonik-LightItalic.ttf +0 -0
  57. package/public/fonts/Aeonik/Aeonik-Medium.ttf +0 -0
  58. package/public/fonts/Aeonik/Aeonik-MediumItalic.ttf +0 -0
  59. package/public/fonts/Aeonik/Aeonik-Regular.ttf +0 -0
  60. package/public/fonts/Aeonik/Aeonik-RegularItalic.ttf +0 -0
  61. package/public/fonts/Aeonik/Aeonik-Thin.ttf +0 -0
  62. package/public/fonts/Aeonik/Aeonik-ThinItalic.ttf +0 -0
  63. package/public/fonts/Inter/Inter-Black.ttf +0 -0
  64. package/public/fonts/Inter/Inter-BlackItalic.ttf +0 -0
  65. package/public/fonts/Inter/Inter-Bold.ttf +0 -0
  66. package/public/fonts/Inter/Inter-BoldItalic.ttf +0 -0
  67. package/public/fonts/Inter/Inter-ExtraBold.ttf +0 -0
  68. package/public/fonts/Inter/Inter-ExtraBoldItalic.ttf +0 -0
  69. package/public/fonts/Inter/Inter-ExtraLight.ttf +0 -0
  70. package/public/fonts/Inter/Inter-ExtraLightItalic.ttf +0 -0
  71. package/public/fonts/Inter/Inter-Italic.ttf +0 -0
  72. package/public/fonts/Inter/Inter-Light.ttf +0 -0
  73. package/public/fonts/Inter/Inter-LightItalic.ttf +0 -0
  74. package/public/fonts/Inter/Inter-Medium.ttf +0 -0
  75. package/public/fonts/Inter/Inter-MediumItalic.ttf +0 -0
  76. package/public/fonts/Inter/Inter-Regular.ttf +0 -0
  77. package/public/fonts/Inter/Inter-SemiBold.ttf +0 -0
  78. package/public/fonts/Inter/Inter-SemiBoldItalic.ttf +0 -0
  79. package/public/fonts/Inter/Inter-Thin.ttf +0 -0
  80. package/public/fonts/Inter/Inter-ThinItalic.ttf +0 -0
  81. package/public/fonts/Outfit/Outfit-Black.ttf +0 -0
  82. package/public/fonts/Outfit/Outfit-Bold.ttf +0 -0
  83. package/public/fonts/Outfit/Outfit-ExtraBold.ttf +0 -0
  84. package/public/fonts/Outfit/Outfit-ExtraLight.ttf +0 -0
  85. package/public/fonts/Outfit/Outfit-Light.ttf +0 -0
  86. package/public/fonts/Outfit/Outfit-Medium.ttf +0 -0
  87. package/public/fonts/Outfit/Outfit-Regular.ttf +0 -0
  88. package/public/fonts/Outfit/Outfit-SemiBold.ttf +0 -0
  89. package/public/fonts/Outfit/Outfit-Thin.ttf +0 -0
  90. package/public/github-mark.svg +0 -3
  91. package/public/tokens/GYEN.svg +0 -9
  92. package/public/tokens/PYUSD.svg +0 -9
  93. package/public/tokens/USDT.svg +0 -6
  94. package/scripts/mcp-server/resources.d.mts +0 -1
  95. package/scripts/mcp-server/resources.mjs +0 -102
  96. package/test/jsdom-global-register.d.ts +0 -1
  97. package/test/jsdom-global-register.js +0 -1
@@ -1,102 +0,0 @@
1
- /* eslint-env node */
2
- import fs from 'fs/promises';
3
- import path from 'path';
4
- import { fileURLToPath, pathToFileURL } from 'url';
5
-
6
- const __filename = fileURLToPath(import.meta.url);
7
- const __dirname = path.dirname(__filename);
8
-
9
- const repoRoot = path.resolve(__dirname, '../../');
10
- const componentsRoot = path.join(repoRoot, 'src/components');
11
-
12
- let cachedResources = null;
13
-
14
- function isWithinComponents(targetPath) {
15
- const absolute = path.resolve(targetPath);
16
- return absolute.startsWith(componentsRoot);
17
- }
18
-
19
- function detectMimeType(filePath) {
20
- const ext = path.extname(filePath).toLowerCase();
21
- if (ext === '.ts') return 'text/typescript';
22
- if (ext === '.tsx') return 'text/tsx';
23
- if (ext === '.js') return 'text/javascript';
24
- if (ext === '.jsx') return 'text/jsx';
25
- if (ext === '.scss' || ext === '.css' || ext === '.less') {
26
- return 'text/css';
27
- }
28
- if (ext === '.md' || ext === '.mdx') return 'text/markdown';
29
- return 'text/plain';
30
- }
31
-
32
- async function walkFiles(dir) {
33
- const entries = await fs.readdir(dir, { withFileTypes: true });
34
- const files = [];
35
- for (const entry of entries) {
36
- if (entry.name.startsWith('.')) continue;
37
- const fullPath = path.join(dir, entry.name);
38
- if (entry.isDirectory()) {
39
- files.push(...(await walkFiles(fullPath)));
40
- } else {
41
- files.push(fullPath);
42
- }
43
- }
44
- return files;
45
- }
46
-
47
- async function buildResourceCache() {
48
- try {
49
- const files = await walkFiles(componentsRoot);
50
- return files.map(filePath => {
51
- const uri = pathToFileURL(filePath).href;
52
- return {
53
- uri,
54
- filePath,
55
- mimeType: detectMimeType(filePath),
56
- name: path.relative(repoRoot, filePath)
57
- };
58
- });
59
- } catch (error) {
60
- throw new Error(
61
- `Failed to scan components under ${componentsRoot}: ${error}`
62
- );
63
- }
64
- }
65
-
66
- async function ensureCache() {
67
- if (!cachedResources) {
68
- cachedResources = await buildResourceCache();
69
- }
70
- return cachedResources;
71
- }
72
-
73
- async function readFile(entry) {
74
- if (!isWithinComponents(entry.filePath)) {
75
- throw new Error('Resource not allowed');
76
- }
77
-
78
- const text = await fs.readFile(entry.filePath, 'utf8');
79
- return {
80
- contents: [
81
- { uri: entry.uri, mimeType: entry.mimeType, text }
82
- ]
83
- };
84
- }
85
-
86
- export async function registerComponentResources(server) {
87
- const resources = await ensureCache();
88
-
89
- resources.forEach(entry => {
90
- server.registerResource(
91
- entry.name,
92
- entry.uri,
93
- {
94
- description: 'src/components resource',
95
- mimeType: entry.mimeType
96
- },
97
- async () => readFile(entry)
98
- );
99
- });
100
-
101
- return resources.length;
102
- }
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- module.exports = {};