noecosystem-design 0.1.0
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.
- package/.editorconfig +12 -0
- package/.github/CODEOWNERS +10 -0
- package/.github/dependabot.yml +12 -0
- package/.github/pull_request_template.md +17 -0
- package/.github/workflows/ci.yml +173 -0
- package/.github/workflows/security.yml +40 -0
- package/.mcp.json +8 -0
- package/.node-version +1 -0
- package/AGENTS.md +62 -0
- package/CONTRIBUTING.md +9 -0
- package/README.md +48 -0
- package/SECURITY.md +7 -0
- package/apps/showcase/index.html +28 -0
- package/apps/showcase/package.json +30 -0
- package/apps/showcase/src/app.css +8 -0
- package/apps/showcase/src/app.tsx +10 -0
- package/apps/showcase/src/catalog/agent-composer-preview.tsx +17 -0
- package/apps/showcase/src/catalog/catalog-index.tsx +2676 -0
- package/apps/showcase/src/catalog/catalog-shell.browser.test.tsx +73 -0
- package/apps/showcase/src/catalog/catalog-shell.tsx +506 -0
- package/apps/showcase/src/main.tsx +17 -0
- package/apps/showcase/tsconfig.json +11 -0
- package/apps/showcase/vite.config.ts +15 -0
- package/apps/storybook/.storybook/main.ts +21 -0
- package/apps/storybook/.storybook/preview.tsx +87 -0
- package/apps/storybook/.storybook/vitest.setup.ts +26 -0
- package/apps/storybook/README.md +5 -0
- package/apps/storybook/package.json +31 -0
- package/apps/storybook/stories/AgentStates.stories.tsx +72 -0
- package/apps/storybook/stories/Bidi.stories.tsx +31 -0
- package/apps/storybook/stories/Button.stories.tsx +19 -0
- package/apps/storybook/stories/Surfaces.stories.tsx +28 -0
- package/apps/storybook/stories/catalog/about-page.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/activity-feed.stories.tsx +50 -0
- package/apps/storybook/stories/catalog/activity-gauge.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/agent-composer.stories.tsx +49 -0
- package/apps/storybook/stories/catalog/agent-message.stories.tsx +37 -0
- package/apps/storybook/stories/catalog/agent-plan.stories.tsx +35 -0
- package/apps/storybook/stories/catalog/agent-workspace.stories.tsx +60 -0
- package/apps/storybook/stories/catalog/alert.stories.tsx +41 -0
- package/apps/storybook/stories/catalog/app-frame.stories.tsx +47 -0
- package/apps/storybook/stories/catalog/approval-request.stories.tsx +30 -0
- package/apps/storybook/stories/catalog/avatar.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/badge-group.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/badge.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/banner.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/bidi-text.stories.tsx +47 -0
- package/apps/storybook/stories/catalog/blog-index-page.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/blog-post-page.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/blog-section.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/bottom-navigation.stories.tsx +27 -0
- package/apps/storybook/stories/catalog/button-group.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/button.stories.tsx +27 -0
- package/apps/storybook/stories/catalog/calendar.stories.tsx +47 -0
- package/apps/storybook/stories/catalog/card.stories.tsx +40 -0
- package/apps/storybook/stories/catalog/careers-section.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/carousel.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/chart-frame.stories.tsx +34 -0
- package/apps/storybook/stories/catalog/chart.stories.tsx +43 -0
- package/apps/storybook/stories/catalog/checkbox.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/code-and-terminal.stories.tsx +39 -0
- package/apps/storybook/stories/catalog/color-picker.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/command-menu.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/contact-page.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/contact-section.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/content-divider.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/content-section.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/context-menu.stories.tsx +66 -0
- package/apps/storybook/stories/catalog/credit-card.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/cta-section.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/dashboard-01.stories.tsx +28 -0
- package/apps/storybook/stories/catalog/dashboard-02.stories.tsx +28 -0
- package/apps/storybook/stories/catalog/dashboard-shell.stories.tsx +65 -0
- package/apps/storybook/stories/catalog/data-list.stories.tsx +37 -0
- package/apps/storybook/stories/catalog/data-table.stories.tsx +51 -0
- package/apps/storybook/stories/catalog/date-picker.stories.tsx +31 -0
- package/apps/storybook/stories/catalog/dialog.stories.tsx +68 -0
- package/apps/storybook/stories/catalog/direction-provider.stories.tsx +36 -0
- package/apps/storybook/stories/catalog/drawer.stories.tsx +58 -0
- package/apps/storybook/stories/catalog/dropdown.stories.tsx +67 -0
- package/apps/storybook/stories/catalog/email-template.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/empty-state.stories.tsx +19 -0
- package/apps/storybook/stories/catalog/error-state.stories.tsx +19 -0
- package/apps/storybook/stories/catalog/fab.stories.tsx +22 -0
- package/apps/storybook/stories/catalog/faq-page.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/faq-section.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/feature-section.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/featured-icon.stories.tsx +45 -0
- package/apps/storybook/stories/catalog/field.stories.tsx +35 -0
- package/apps/storybook/stories/catalog/file-uploader.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/filter-bar.stories.tsx +33 -0
- package/apps/storybook/stories/catalog/footer.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/forgot-password-page.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/gradient-picker.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/header-navigation.stories.tsx +46 -0
- package/apps/storybook/stories/catalog/hero-header.stories.tsx +36 -0
- package/apps/storybook/stories/catalog/icon-system.stories.tsx +48 -0
- package/apps/storybook/stories/catalog/illustration.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/image-picker.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/informational-page-01.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/informational-page-02.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/inline-cta.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/input.stories.tsx +21 -0
- package/apps/storybook/stories/catalog/landing-page.stories.tsx +28 -0
- package/apps/storybook/stories/catalog/legal-page.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/login-page.stories.tsx +42 -0
- package/apps/storybook/stories/catalog/marketing-404-page.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/marketing-header.stories.tsx +35 -0
- package/apps/storybook/stories/catalog/menu.stories.tsx +46 -0
- package/apps/storybook/stories/catalog/messaging.stories.tsx +33 -0
- package/apps/storybook/stories/catalog/metric-card.stories.tsx +20 -0
- package/apps/storybook/stories/catalog/metrics-section.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/mobile-screen.stories.tsx +56 -0
- package/apps/storybook/stories/catalog/multi-select.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/newsletter.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/not-found.stories.tsx +30 -0
- package/apps/storybook/stories/catalog/notification.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/page-header.stories.tsx +37 -0
- package/apps/storybook/stories/catalog/pagination.stories.tsx +27 -0
- package/apps/storybook/stories/catalog/pie-chart.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/pricing-page.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/pricing-section.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/progress-indicator.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/progress-steps.stories.tsx +33 -0
- package/apps/storybook/stories/catalog/qr-code.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/radar-chart.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/radio-group.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/rating.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/rich-text-editor.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/run-inspector.stories.tsx +23 -0
- package/apps/storybook/stories/catalog/section-footer.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/section-header.stories.tsx +31 -0
- package/apps/storybook/stories/catalog/select.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/settings-01.stories.tsx +24 -0
- package/apps/storybook/stories/catalog/settings-02.stories.tsx +24 -0
- package/apps/storybook/stories/catalog/settings-page.stories.tsx +48 -0
- package/apps/storybook/stories/catalog/sidebar-navigation.stories.tsx +40 -0
- package/apps/storybook/stories/catalog/sign-in-form.stories.tsx +28 -0
- package/apps/storybook/stories/catalog/sign-up-page.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/skeleton.stories.tsx +21 -0
- package/apps/storybook/stories/catalog/slider.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/social-button.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/social-proof.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/spinner.stories.tsx +15 -0
- package/apps/storybook/stories/catalog/store-button.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/tabs.stories.tsx +38 -0
- package/apps/storybook/stories/catalog/tags.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/team-page.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/team-section.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/testimonial-section.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/textarea.stories.tsx +22 -0
- package/apps/storybook/stories/catalog/toggle.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/tool-call.stories.tsx +40 -0
- package/apps/storybook/stories/catalog/tooltip.stories.tsx +30 -0
- package/apps/storybook/stories/catalog/tree-view.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/utility-button.stories.tsx +60 -0
- package/apps/storybook/stories/catalog/verification-code.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/verification-page.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/video-player.stories.tsx +18 -0
- package/apps/storybook/stories/catalog/workflow-canvas.stories.tsx +45 -0
- package/apps/storybook/stories/catalog/workflow-node.stories.tsx +24 -0
- package/apps/storybook/vitest.config.ts +39 -0
- package/apps/web/README.md +13 -0
- package/apps/web/app.js +483 -0
- package/apps/web/favicon.svg +6 -0
- package/apps/web/index.html +205 -0
- package/apps/web/styles.css +1823 -0
- package/artifacts/original-delivery/NOE-Design-System-Delivery/README-FIRST.txt +20 -0
- package/artifacts/original-delivery/NOE-Design-System-Delivery/SHA256SUMS.txt +11 -0
- package/artifacts/original-delivery/NOE-Design-System-Delivery/noe-delivery-metadata.json +25 -0
- package/artifacts/original-delivery/NOE-Design-System-Delivery/noe-design-system-evidence.zip +0 -0
- package/artifacts/original-delivery/NOE-Design-System-Delivery/noe-design-system-execution-report.md +60 -0
- package/artifacts/original-delivery/NOE-Design-System-Delivery/noe-design-system-manifest.json +106 -0
- package/artifacts/original-delivery/NOE-Design-System-Delivery/noe-design-system-source.tar.gz +0 -0
- package/artifacts/original-delivery/NOE-Design-System-Delivery/noe-design-system-source.zip +0 -0
- package/artifacts/original-delivery/NOE-Design-System-Delivery/noe-design-system.bundle +0 -0
- package/artifacts/original-delivery/NOE-Design-System-Delivery/noe-evidence-index.html +38 -0
- package/artifacts/original-delivery/NOE-Design-System-Delivery/noe-verification-status.txt +15 -0
- package/artifacts/original-delivery/NOE-Design-System-Delivery/noe-visual-contact-sheet.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/README.txt +13 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/browser-console.json +4 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/layout-audit.json +4 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/review/contact-sheet.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-en-dark-1024.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-en-dark-1280.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-en-dark-1440.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-en-dark-390.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-en-dark-768.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-en-light-1024.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-en-light-1280.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-en-light-1440.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-en-light-390.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-en-light-768.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-fa-dark-1024.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-fa-dark-1280.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-fa-dark-1440.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-fa-dark-390.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-fa-dark-768.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-fa-light-1024.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-fa-light-1280.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-fa-light-1440.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-fa-light-390.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-fa-light-768.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-pseudo-ltr-1024.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/agent-pseudo-rtl-1024.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/consumer-en-light-1440.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/consumer-fa-dark-1440.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/dashboard-en-light-1440.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/dashboard-fa-dark-1440.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/workflow-en-light-1440.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots/workflow-fa-dark-1440.png +0 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/screenshots-manifest.json +203 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/verification-result.json +165 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/verification-result.txt +32 -0
- package/artifacts/original-delivery/noe-design-system-evidence/evidence/visual-index.html +1 -0
- package/artifacts/original-delivery/noe-design-system-evidence/noe-delivery-metadata.json +25 -0
- package/artifacts/original-delivery/noe-design-system-evidence/noe-design-system-execution-report.md +60 -0
- package/artifacts/original-delivery/noe-design-system-evidence/noe-design-system-manifest.json +106 -0
- package/artifacts/original-delivery/noe-design-system-evidence/noe-verification-status.txt +15 -0
- package/artifacts/original-delivery/noe-design-system.bundle +0 -0
- package/artifacts/original-delivery/source-evidence/verification-result.json +165 -0
- package/artifacts/original-delivery/source-evidence/verification-result.txt +32 -0
- package/artifacts/registry-consumer-report.json +153 -0
- package/artifacts/source-inputs/persian-fonts/Woff/IRANYekanXFaNum-Black.woff +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff/IRANYekanXFaNum-Bold.woff +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff/IRANYekanXFaNum-DemiBold.woff +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff/IRANYekanXFaNum-ExtraBlack.woff +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff/IRANYekanXFaNum-ExtraBold.woff +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff/IRANYekanXFaNum-Heavy.woff +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff/IRANYekanXFaNum-Light.woff +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff/IRANYekanXFaNum-Medium.woff +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff/IRANYekanXFaNum-Regular.woff +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff/IRANYekanXFaNum-Thin.woff +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff/IRANYekanXFaNum-UltraLight.woff +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff2/IRANYekanXFaNum-Black.woff2 +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff2/IRANYekanXFaNum-Bold.woff2 +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff2/IRANYekanXFaNum-DemiBold.woff2 +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff2/IRANYekanXFaNum-ExtraBlack.woff2 +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff2/IRANYekanXFaNum-ExtraBold.woff2 +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff2/IRANYekanXFaNum-Heavy.woff2 +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff2/IRANYekanXFaNum-Light.woff2 +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff2/IRANYekanXFaNum-Medium.woff2 +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff2/IRANYekanXFaNum-Regular.woff2 +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff2/IRANYekanXFaNum-Thin.woff2 +0 -0
- package/artifacts/source-inputs/persian-fonts/Woff2/IRANYekanXFaNum-UltraLight.woff2 +0 -0
- package/biome.json +170 -0
- package/components.json +23 -0
- package/docs/adr/0001-semantic-foundation.md +5 -0
- package/docs/adr/0002-locale-direction.md +5 -0
- package/docs/adr/0003-registry-mcp.md +5 -0
- package/docs/adr/0004-testing-evidence.md +5 -0
- package/docs/adr/0005-noe-package-namespace.md +9 -0
- package/docs/adr/0006-icons8-icon-policy.md +9 -0
- package/docs/adr/0007-registry-publication-contract.md +9 -0
- package/docs/adr/0008-capability-library-adapter-boundaries.md +16 -0
- package/docs/adr/0009-calendar-system-jalali.md +29 -0
- package/docs/adr/0010-canonical-manifest-ownership.md +29 -0
- package/docs/adr/0011-palette-graphite-governance.md +27 -0
- package/docs/adr/0012-persian-font-gating.md +25 -0
- package/docs/adr/0013-cinematic-token-exception.md +32 -0
- package/docs/design-system/README.md +16 -0
- package/docs/design-system/accessibility.md +20 -0
- package/docs/design-system/agent-guide.md +11 -0
- package/docs/design-system/agentic-ui.md +21 -0
- package/docs/design-system/architecture.md +40 -0
- package/docs/design-system/brand.md +59 -0
- package/docs/design-system/ci-cd.md +46 -0
- package/docs/design-system/components.md +88 -0
- package/docs/design-system/contributing.md +7 -0
- package/docs/design-system/foundations.md +40 -0
- package/docs/design-system/i18n.md +24 -0
- package/docs/design-system/inventory.md +389 -0
- package/docs/design-system/mcp.md +7 -0
- package/docs/design-system/motion.md +7 -0
- package/docs/design-system/noe-brand-audit.md +33 -0
- package/docs/design-system/registry.md +16 -0
- package/docs/design-system/rtl.md +27 -0
- package/docs/design-system/security.md +16 -0
- package/docs/design-system/testing.md +39 -0
- package/docs/design-system/tokens.md +38 -0
- package/docs/design-system/visual-qa.md +10 -0
- package/docs/superpowers/plans/2026-08-25-noe-design-system-development-ready.md +833 -0
- package/docs/superpowers/plans/2026-08-26-noe-complete-catalog.md +422 -0
- package/docs/superpowers/specs/2026-08-25-noe-design-system-development-ready-design.md +260 -0
- package/docs/superpowers/specs/2026-08-26-noe-complete-catalog-design.md +187 -0
- package/llms.txt +20 -0
- package/package.json +68 -0
- package/packages/ai-ui/package.json +15 -0
- package/packages/ai-ui/src/activity-feed.tsx +60 -0
- package/packages/ai-ui/src/agent-composer.tsx +54 -0
- package/packages/ai-ui/src/agent-message.tsx +50 -0
- package/packages/ai-ui/src/agent-plan.tsx +69 -0
- package/packages/ai-ui/src/agent-workspace.tsx +63 -0
- package/packages/ai-ui/src/approval-request.tsx +93 -0
- package/packages/ai-ui/src/index.ts +8 -0
- package/packages/ai-ui/src/run-inspector.tsx +54 -0
- package/packages/ai-ui/src/tool-call.tsx +71 -0
- package/packages/data-ui/package.json +16 -0
- package/packages/data-ui/src/activity-gauge.tsx +38 -0
- package/packages/data-ui/src/chart-frame.tsx +41 -0
- package/packages/data-ui/src/chart.tsx +131 -0
- package/packages/data-ui/src/dashboard-01.tsx +39 -0
- package/packages/data-ui/src/dashboard-02.tsx +33 -0
- package/packages/data-ui/src/dashboard-shell.tsx +56 -0
- package/packages/data-ui/src/data-table.tsx +99 -0
- package/packages/data-ui/src/filter-bar.tsx +28 -0
- package/packages/data-ui/src/index.ts +12 -0
- package/packages/data-ui/src/metric-card.tsx +43 -0
- package/packages/data-ui/src/pagination.tsx +67 -0
- package/packages/data-ui/src/pie-chart.tsx +38 -0
- package/packages/data-ui/src/radar-chart.tsx +38 -0
- package/packages/design-tokens/package.json +23 -0
- package/packages/design-tokens/src/base.css +255 -0
- package/packages/design-tokens/src/fonts/IRANYekanXFaNum-Bold.woff2 +0 -0
- package/packages/design-tokens/src/fonts/IRANYekanXFaNum-DemiBold.woff2 +0 -0
- package/packages/design-tokens/src/fonts/IRANYekanXFaNum-Medium.woff2 +0 -0
- package/packages/design-tokens/src/fonts/IRANYekanXFaNum-Regular.woff2 +0 -0
- package/packages/design-tokens/src/fonts/IRANYekanXVF.ttf +0 -0
- package/packages/design-tokens/src/fonts/README.md +13 -0
- package/packages/design-tokens/src/fonts.css +49 -0
- package/packages/design-tokens/src/index.test.ts +36 -0
- package/packages/design-tokens/src/index.ts +5 -0
- package/packages/design-tokens/src/palette.ts +27 -0
- package/packages/design-tokens/src/tailwind.css +3 -0
- package/packages/design-tokens/src/theme.css +67 -0
- package/packages/design-tokens/src/tokens.css +251 -0
- package/packages/design-tokens/src/tokens.json +275 -0
- package/packages/design-tokens/src/tokens.mjs +276 -0
- package/packages/i18n/package.json +13 -0
- package/packages/i18n/src/index.ts +17 -0
- package/packages/i18n/src/messages/en.json +116 -0
- package/packages/i18n/src/messages/fa.json +116 -0
- package/packages/i18n/src/runtime.d.mts +42 -0
- package/packages/i18n/src/runtime.mjs +113 -0
- package/packages/i18n/src/translate.test.ts +50 -0
- package/packages/i18n/src/translate.ts +29 -0
- package/packages/icons/package.json +12 -0
- package/packages/icons/src/adapters.tsx +167 -0
- package/packages/icons/src/index.tsx +103 -0
- package/packages/registry/README.md +7 -0
- package/packages/registry/catalog-index.json +1345 -0
- package/packages/registry/component-audit.json +1038 -0
- package/packages/registry/coss-adoption.json +281 -0
- package/packages/registry/docs-index.json +1881 -0
- package/packages/registry/manifest.json +11081 -0
- package/packages/registry/manifest.schema.json +135 -0
- package/packages/registry/package.json +10 -0
- package/packages/registry/r/activity-feed.json +67 -0
- package/packages/registry/r/agent-composer.json +79 -0
- package/packages/registry/r/agent-message.json +72 -0
- package/packages/registry/r/agent-plan.json +67 -0
- package/packages/registry/r/agent-workspace.json +67 -0
- package/packages/registry/r/alert.json +68 -0
- package/packages/registry/r/app-frame.json +67 -0
- package/packages/registry/r/approval-request.json +84 -0
- package/packages/registry/r/badge.json +68 -0
- package/packages/registry/r/bidi-text.json +70 -0
- package/packages/registry/r/bottom-navigation.json +67 -0
- package/packages/registry/r/button.json +83 -0
- package/packages/registry/r/calendar.json +97 -0
- package/packages/registry/r/card.json +67 -0
- package/packages/registry/r/chart-frame.json +67 -0
- package/packages/registry/r/chart.json +67 -0
- package/packages/registry/r/code-block.json +67 -0
- package/packages/registry/r/context-menu.json +81 -0
- package/packages/registry/r/dashboard-01.json +86 -0
- package/packages/registry/r/dashboard-02.json +84 -0
- package/packages/registry/r/dashboard-shell.json +67 -0
- package/packages/registry/r/data-list.json +67 -0
- package/packages/registry/r/data-table.json +72 -0
- package/packages/registry/r/date-picker.json +117 -0
- package/packages/registry/r/dialog.json +84 -0
- package/packages/registry/r/direction-provider.json +54 -0
- package/packages/registry/r/drawer.json +80 -0
- package/packages/registry/r/dropdown.json +78 -0
- package/packages/registry/r/empty-state.json +67 -0
- package/packages/registry/r/error-state.json +67 -0
- package/packages/registry/r/fab.json +80 -0
- package/packages/registry/r/featured-icon.json +71 -0
- package/packages/registry/r/filter-bar.json +69 -0
- package/packages/registry/r/gradient-picker.json +62 -0
- package/packages/registry/r/header-navigation.json +67 -0
- package/packages/registry/r/hero-header.json +63 -0
- package/packages/registry/r/icon-system.json +59 -0
- package/packages/registry/r/image-picker.json +62 -0
- package/packages/registry/r/inline-cta.json +73 -0
- package/packages/registry/r/input.json +73 -0
- package/packages/registry/r/landing-page.json +70 -0
- package/packages/registry/r/login-page.json +71 -0
- package/packages/registry/r/marketing-header.json +63 -0
- package/packages/registry/r/menu.json +74 -0
- package/packages/registry/r/messaging.json +69 -0
- package/packages/registry/r/metric-card.json +67 -0
- package/packages/registry/r/mobile-screen.json +67 -0
- package/packages/registry/r/not-found.json +63 -0
- package/packages/registry/r/page-header.json +67 -0
- package/packages/registry/r/pagination.json +91 -0
- package/packages/registry/r/progress-steps.json +69 -0
- package/packages/registry/r/run-inspector.json +72 -0
- package/packages/registry/r/section-header.json +67 -0
- package/packages/registry/r/settings-01.json +94 -0
- package/packages/registry/r/settings-02.json +99 -0
- package/packages/registry/r/settings-page.json +67 -0
- package/packages/registry/r/sidebar-navigation.json +67 -0
- package/packages/registry/r/sign-in-form.json +89 -0
- package/packages/registry/r/skeleton.json +67 -0
- package/packages/registry/r/spinner.json +67 -0
- package/packages/registry/r/tabs.json +69 -0
- package/packages/registry/r/textarea.json +73 -0
- package/packages/registry/r/tool-call.json +72 -0
- package/packages/registry/r/tooltip.json +73 -0
- package/packages/registry/r/utility-button.json +83 -0
- package/packages/registry/r/workflow-canvas.json +67 -0
- package/packages/registry/r/workflow-node.json +72 -0
- package/packages/registry/r-planned-backup/about-page.json +14 -0
- package/packages/registry/r-planned-backup/activity-gauge.json +14 -0
- package/packages/registry/r-planned-backup/avatar.json +14 -0
- package/packages/registry/r-planned-backup/badge-group.json +14 -0
- package/packages/registry/r-planned-backup/banner.json +14 -0
- package/packages/registry/r-planned-backup/blog-index-page.json +14 -0
- package/packages/registry/r-planned-backup/blog-post-page.json +14 -0
- package/packages/registry/r-planned-backup/blog-section.json +14 -0
- package/packages/registry/r-planned-backup/button-group.json +14 -0
- package/packages/registry/r-planned-backup/careers-section.json +14 -0
- package/packages/registry/r-planned-backup/carousel.json +14 -0
- package/packages/registry/r-planned-backup/checkbox.json +14 -0
- package/packages/registry/r-planned-backup/color-picker.json +14 -0
- package/packages/registry/r-planned-backup/command-menu.json +14 -0
- package/packages/registry/r-planned-backup/contact-page.json +14 -0
- package/packages/registry/r-planned-backup/contact-section.json +14 -0
- package/packages/registry/r-planned-backup/content-divider.json +14 -0
- package/packages/registry/r-planned-backup/content-section.json +14 -0
- package/packages/registry/r-planned-backup/credit-card.json +14 -0
- package/packages/registry/r-planned-backup/cta-section.json +14 -0
- package/packages/registry/r-planned-backup/email-template.json +14 -0
- package/packages/registry/r-planned-backup/faq-page.json +14 -0
- package/packages/registry/r-planned-backup/faq-section.json +14 -0
- package/packages/registry/r-planned-backup/feature-section.json +14 -0
- package/packages/registry/r-planned-backup/file-uploader.json +14 -0
- package/packages/registry/r-planned-backup/footer.json +14 -0
- package/packages/registry/r-planned-backup/forgot-password-page.json +14 -0
- package/packages/registry/r-planned-backup/illustration.json +14 -0
- package/packages/registry/r-planned-backup/informational-page-01.json +14 -0
- package/packages/registry/r-planned-backup/informational-page-02.json +14 -0
- package/packages/registry/r-planned-backup/legal-page.json +14 -0
- package/packages/registry/r-planned-backup/marketing-404-page.json +14 -0
- package/packages/registry/r-planned-backup/metrics-section.json +14 -0
- package/packages/registry/r-planned-backup/multi-select.json +14 -0
- package/packages/registry/r-planned-backup/newsletter.json +14 -0
- package/packages/registry/r-planned-backup/notification.json +14 -0
- package/packages/registry/r-planned-backup/pie-chart.json +14 -0
- package/packages/registry/r-planned-backup/pricing-page.json +14 -0
- package/packages/registry/r-planned-backup/pricing-section.json +14 -0
- package/packages/registry/r-planned-backup/progress-indicator.json +14 -0
- package/packages/registry/r-planned-backup/qr-code.json +14 -0
- package/packages/registry/r-planned-backup/radar-chart.json +14 -0
- package/packages/registry/r-planned-backup/radio-group.json +14 -0
- package/packages/registry/r-planned-backup/rating.json +14 -0
- package/packages/registry/r-planned-backup/rich-text-editor.json +14 -0
- package/packages/registry/r-planned-backup/section-footer.json +14 -0
- package/packages/registry/r-planned-backup/select.json +14 -0
- package/packages/registry/r-planned-backup/sign-up-page.json +14 -0
- package/packages/registry/r-planned-backup/slider.json +14 -0
- package/packages/registry/r-planned-backup/social-button.json +14 -0
- package/packages/registry/r-planned-backup/social-proof.json +14 -0
- package/packages/registry/r-planned-backup/store-button.json +14 -0
- package/packages/registry/r-planned-backup/tags.json +14 -0
- package/packages/registry/r-planned-backup/team-page.json +14 -0
- package/packages/registry/r-planned-backup/team-section.json +14 -0
- package/packages/registry/r-planned-backup/testimonial-section.json +14 -0
- package/packages/registry/r-planned-backup/toggle.json +14 -0
- package/packages/registry/r-planned-backup/tree-view.json +14 -0
- package/packages/registry/r-planned-backup/verification-code.json +14 -0
- package/packages/registry/r-planned-backup/verification-page.json +14 -0
- package/packages/registry/r-planned-backup/video-player.json +14 -0
- package/packages/registry/registry.json +1997 -0
- package/packages/registry/search-index.json +3942 -0
- package/packages/testing/package.json +9 -0
- package/packages/testing/src/index.mjs +10 -0
- package/packages/ui/package.json +26 -0
- package/packages/ui/src/about-page.tsx +19 -0
- package/packages/ui/src/alert.tsx +67 -0
- package/packages/ui/src/app-frame.tsx +63 -0
- package/packages/ui/src/avatar.tsx +19 -0
- package/packages/ui/src/badge-group.tsx +19 -0
- package/packages/ui/src/badge.tsx +35 -0
- package/packages/ui/src/banner.tsx +19 -0
- package/packages/ui/src/bidi.tsx +80 -0
- package/packages/ui/src/blog-index-page.tsx +19 -0
- package/packages/ui/src/blog-post-page.tsx +19 -0
- package/packages/ui/src/blog-section.tsx +19 -0
- package/packages/ui/src/bottom-navigation.tsx +60 -0
- package/packages/ui/src/button-group.tsx +19 -0
- package/packages/ui/src/button.browser.test.tsx +38 -0
- package/packages/ui/src/button.tsx +81 -0
- package/packages/ui/src/calendar-system.test.ts +103 -0
- package/packages/ui/src/calendar-system.ts +120 -0
- package/packages/ui/src/calendar.browser.test.tsx +52 -0
- package/packages/ui/src/calendar.tsx +339 -0
- package/packages/ui/src/card.tsx +63 -0
- package/packages/ui/src/careers-section.tsx +19 -0
- package/packages/ui/src/carousel.tsx +19 -0
- package/packages/ui/src/checkbox.tsx +17 -0
- package/packages/ui/src/cinematic/cinematic.css +2020 -0
- package/packages/ui/src/cinematic/ecosystem-motion-showcase.tsx +265 -0
- package/packages/ui/src/cinematic/ecosystem-sphere.tsx +627 -0
- package/packages/ui/src/cinematic/index.ts +5 -0
- package/packages/ui/src/cinematic/kinetic-experience.tsx +207 -0
- package/packages/ui/src/cinematic/portfolio.ts +132 -0
- package/packages/ui/src/cinematic/system-anatomy.tsx +173 -0
- package/packages/ui/src/code.tsx +119 -0
- package/packages/ui/src/color-picker.tsx +22 -0
- package/packages/ui/src/command-menu.tsx +19 -0
- package/packages/ui/src/contact-page.tsx +19 -0
- package/packages/ui/src/contact-section.tsx +19 -0
- package/packages/ui/src/content-divider.tsx +19 -0
- package/packages/ui/src/content-section.tsx +19 -0
- package/packages/ui/src/context-menu.tsx +208 -0
- package/packages/ui/src/credit-card.tsx +19 -0
- package/packages/ui/src/cta-section.tsx +19 -0
- package/packages/ui/src/data-list.tsx +81 -0
- package/packages/ui/src/date-picker.browser.test.tsx +48 -0
- package/packages/ui/src/date-picker.tsx +248 -0
- package/packages/ui/src/dialog.browser.test.tsx +32 -0
- package/packages/ui/src/dialog.tsx +144 -0
- package/packages/ui/src/direction.tsx +46 -0
- package/packages/ui/src/drawer.tsx +179 -0
- package/packages/ui/src/dropdown.tsx +200 -0
- package/packages/ui/src/email-template.tsx +19 -0
- package/packages/ui/src/empty-state.tsx +43 -0
- package/packages/ui/src/error-state.tsx +44 -0
- package/packages/ui/src/fab.tsx +32 -0
- package/packages/ui/src/faq-page.tsx +19 -0
- package/packages/ui/src/faq-section.tsx +19 -0
- package/packages/ui/src/feature-section.tsx +19 -0
- package/packages/ui/src/featured-icon.tsx +63 -0
- package/packages/ui/src/field.browser.test.tsx +33 -0
- package/packages/ui/src/field.tsx +117 -0
- package/packages/ui/src/file-uploader.tsx +19 -0
- package/packages/ui/src/footer.tsx +19 -0
- package/packages/ui/src/forgot-password-page.tsx +19 -0
- package/packages/ui/src/gradient-picker.tsx +65 -0
- package/packages/ui/src/header-navigation.tsx +71 -0
- package/packages/ui/src/hero-header.tsx +57 -0
- package/packages/ui/src/illustration.tsx +19 -0
- package/packages/ui/src/image-picker.tsx +56 -0
- package/packages/ui/src/index.ts +110 -0
- package/packages/ui/src/informational-page-01.tsx +19 -0
- package/packages/ui/src/informational-page-02.tsx +19 -0
- package/packages/ui/src/inline-cta.tsx +29 -0
- package/packages/ui/src/input.tsx +44 -0
- package/packages/ui/src/landing-page.tsx +56 -0
- package/packages/ui/src/legal-page.tsx +19 -0
- package/packages/ui/src/lib/cn.ts +6 -0
- package/packages/ui/src/lib/i18n-messages.ts +40 -0
- package/packages/ui/src/login-page.tsx +78 -0
- package/packages/ui/src/marketing-404-page.tsx +19 -0
- package/packages/ui/src/marketing-header.tsx +53 -0
- package/packages/ui/src/menu.tsx +220 -0
- package/packages/ui/src/messaging.tsx +62 -0
- package/packages/ui/src/metrics-section.tsx +19 -0
- package/packages/ui/src/mobile-screen.tsx +37 -0
- package/packages/ui/src/multi-select.tsx +16 -0
- package/packages/ui/src/newsletter.tsx +19 -0
- package/packages/ui/src/not-found.tsx +60 -0
- package/packages/ui/src/notification.tsx +19 -0
- package/packages/ui/src/page-header.tsx +80 -0
- package/packages/ui/src/pricing-page.tsx +19 -0
- package/packages/ui/src/pricing-section.tsx +19 -0
- package/packages/ui/src/progress-indicator.tsx +19 -0
- package/packages/ui/src/progress-steps.tsx +85 -0
- package/packages/ui/src/qr-code.tsx +19 -0
- package/packages/ui/src/radio-group.tsx +26 -0
- package/packages/ui/src/rating.tsx +19 -0
- package/packages/ui/src/rich-text-editor.tsx +18 -0
- package/packages/ui/src/section-footer.tsx +19 -0
- package/packages/ui/src/section-header.tsx +37 -0
- package/packages/ui/src/select.tsx +27 -0
- package/packages/ui/src/settings-01.tsx +49 -0
- package/packages/ui/src/settings-02.tsx +58 -0
- package/packages/ui/src/settings-page.tsx +62 -0
- package/packages/ui/src/sidebar-navigation.tsx +77 -0
- package/packages/ui/src/sign-in-form.tsx +60 -0
- package/packages/ui/src/sign-up-page.tsx +19 -0
- package/packages/ui/src/skeleton.tsx +14 -0
- package/packages/ui/src/slider.tsx +13 -0
- package/packages/ui/src/social-button.tsx +19 -0
- package/packages/ui/src/social-proof.tsx +19 -0
- package/packages/ui/src/spinner.tsx +26 -0
- package/packages/ui/src/store-button.tsx +19 -0
- package/packages/ui/src/tabs.browser.test.tsx +33 -0
- package/packages/ui/src/tabs.tsx +175 -0
- package/packages/ui/src/tags.tsx +11 -0
- package/packages/ui/src/team-page.tsx +19 -0
- package/packages/ui/src/team-section.tsx +19 -0
- package/packages/ui/src/testimonial-section.tsx +19 -0
- package/packages/ui/src/textarea.tsx +45 -0
- package/packages/ui/src/theme-provider.browser.test.tsx +90 -0
- package/packages/ui/src/theme-provider.tsx +417 -0
- package/packages/ui/src/theme-toggle.tsx +107 -0
- package/packages/ui/src/toggle.tsx +34 -0
- package/packages/ui/src/tooltip.tsx +50 -0
- package/packages/ui/src/tree-view.tsx +19 -0
- package/packages/ui/src/utility-button.tsx +33 -0
- package/packages/ui/src/utils.ts +13 -0
- package/packages/ui/src/verification-code.tsx +27 -0
- package/packages/ui/src/verification-page.tsx +19 -0
- package/packages/ui/src/video-player.tsx +19 -0
- package/packages/workflow-ui/package.json +15 -0
- package/packages/workflow-ui/src/index.ts +2 -0
- package/packages/workflow-ui/src/workflow-canvas.tsx +51 -0
- package/packages/workflow-ui/src/workflow-node.tsx +61 -0
- package/playwright.config.ts +58 -0
- package/pnpm-workspace.yaml +5 -0
- package/registry.json +216 -0
- package/scripts/build-static.mjs +68 -0
- package/scripts/capture-visuals.py +106 -0
- package/scripts/capture-visuals.sh +10 -0
- package/scripts/create-visual-index.mjs +16 -0
- package/scripts/enrich-registry-payloads.mjs +83 -0
- package/scripts/fix-noe-imports.mjs +134 -0
- package/scripts/fix-registry-closure.mjs +110 -0
- package/scripts/fix-registry-deps-cleanup.mjs +149 -0
- package/scripts/fix-relative-for-registry.mjs +103 -0
- package/scripts/generate-design-tokens.mjs +134 -0
- package/scripts/generate-inventory.mjs +62 -0
- package/scripts/generate-manifest.mjs +1149 -0
- package/scripts/generate-phase4.mjs +875 -0
- package/scripts/validate-manifest.mjs +477 -0
- package/scripts/validate-pngs.mjs +31 -0
- package/scripts/verify-registry-consumer.mjs +319 -0
- package/scripts/verify-registry-dependencies.mjs +162 -0
- package/scripts/verify.mjs +316 -0
- package/tests/catalog-audit.test.mjs +156 -0
- package/tests/e2e/capture-visuals.mjs +34 -0
- package/tests/e2e/catalog-typography.spec.ts +110 -0
- package/tests/e2e/catalog.spec.ts +68 -0
- package/tests/e2e/direction.spec.ts +60 -0
- package/tests/e2e/responsive.spec.ts +30 -0
- package/tests/e2e/surfaces.spec.ts +51 -0
- package/tests/i18n.test.mjs +36 -0
- package/tests/icons.test.mjs +21 -0
- package/tests/registry-publication.test.mjs +88 -0
- package/tests/registry.test.mjs +51 -0
- package/tests/rtl.test.mjs +21 -0
- package/tests/static-app.test.mjs +49 -0
- package/tests/tokens.test.mjs +24 -0
- package/tests/workspace.test.mjs +25 -0
- package/tsconfig.base.json +69 -0
- package/tsconfig.json +27 -0
- package/tsconfig.verify.json +19 -0
- package/types/offline-react.d.ts +73 -0
- package/vitest.config.ts +91 -0
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { readFile, writeFile } from 'node:fs/promises';
|
|
2
|
+
import path from 'node:path';
|
|
3
|
+
import { fileURLToPath } from 'node:url';
|
|
4
|
+
|
|
5
|
+
const root = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '..');
|
|
6
|
+
const manifest = JSON.parse(
|
|
7
|
+
await readFile(path.join(root, 'evidence/screenshots-manifest.json'), 'utf8'),
|
|
8
|
+
);
|
|
9
|
+
const cards = manifest.screenshots
|
|
10
|
+
.map(
|
|
11
|
+
(item) =>
|
|
12
|
+
`<article><a href="screenshots/${item.name}"><img src="screenshots/${item.name}" alt="${item.name}" loading="lazy"></a><h2>${item.name}</h2><p>${item.width}×${item.height} · ${item.bytes.toLocaleString()} bytes</p></article>`,
|
|
13
|
+
)
|
|
14
|
+
.join('');
|
|
15
|
+
const html = `<!doctype html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width"><title>NOE Visual Evidence</title><style>body{font-family:system-ui;margin:0;padding:2rem;background:#f2f0ec;color:#23211f}h1{letter-spacing:-.04em}main{display:grid;grid-template-columns:repeat(auto-fit,minmax(260px,1fr));gap:1rem}article{background:white;border:1px solid #d9d4cd;border-radius:12px;overflow:hidden}img{display:block;width:100%;height:220px;object-fit:cover;object-position:top}h2,p{margin:.75rem 1rem}h2{font-size:.8rem;overflow-wrap:anywhere}p{font-size:.7rem;color:#6c665f}</style></head><body><h1>NOE visual evidence</h1><p>${manifest.count} deterministic Chromium captures.</p><main>${cards}</main></body></html>`;
|
|
16
|
+
await writeFile(path.join(root, 'evidence/visual-index.html'), html);
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import { readFile, writeFile } from 'node:fs/promises';
|
|
2
|
+
import path from 'node:path';
|
|
3
|
+
import { fileURLToPath } from 'node:url';
|
|
4
|
+
|
|
5
|
+
const root = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '..');
|
|
6
|
+
const manifest = JSON.parse(
|
|
7
|
+
await readFile(path.join(root, 'packages/registry/manifest.json'), 'utf8'),
|
|
8
|
+
);
|
|
9
|
+
|
|
10
|
+
for (const item of manifest.items.filter(
|
|
11
|
+
(i) => i.status === 'available' || i.status === 'partial',
|
|
12
|
+
)) {
|
|
13
|
+
if (!item.registryItem) continue;
|
|
14
|
+
const payloadPath = path.join(root, `packages/registry/r/${item.registryItem}.json`);
|
|
15
|
+
let payload;
|
|
16
|
+
try {
|
|
17
|
+
payload = JSON.parse(await readFile(payloadPath, 'utf8'));
|
|
18
|
+
} catch {
|
|
19
|
+
console.log(`Missing payload for ${item.id} -> ${item.registryItem}`);
|
|
20
|
+
continue;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
// Enrich with agent-friendly docs from manifest
|
|
24
|
+
const enriched = {
|
|
25
|
+
...payload,
|
|
26
|
+
// Ensure core fields
|
|
27
|
+
name: payload.name || item.registryItem,
|
|
28
|
+
title: payload.title || item.title,
|
|
29
|
+
description: item.description, // Use manifest's description (has known limitation for partial)
|
|
30
|
+
// Agent-friendly metadata
|
|
31
|
+
status: item.status,
|
|
32
|
+
maturity: item.maturity,
|
|
33
|
+
package: item.package,
|
|
34
|
+
exportName: item.exportName,
|
|
35
|
+
category: item.category,
|
|
36
|
+
// Install info
|
|
37
|
+
install: `pnpm dlx shadcn@latest add @noe/${item.registryItem}`,
|
|
38
|
+
import: `import { ${item.exportName} } from '@noe/${item.package.replace('@noe/', '')}'`,
|
|
39
|
+
// Providers
|
|
40
|
+
requiredProviders:
|
|
41
|
+
item.package === '@noe/ui' &&
|
|
42
|
+
(item.id.includes('dialog') ||
|
|
43
|
+
item.id.includes('drawer') ||
|
|
44
|
+
item.id.includes('calendar') ||
|
|
45
|
+
item.id.includes('date-picker'))
|
|
46
|
+
? ['DirectionProvider']
|
|
47
|
+
: [],
|
|
48
|
+
// Dependencies — merge manifest and payload, keeping externally installable npm packages; workspace @noe/* are satisfied via included files/registryDependencies
|
|
49
|
+
registryDependencies: [...new Set([...(item.registryDependencies || []), ...(payload.registryDependencies || [])])],
|
|
50
|
+
dependencies: [...new Set([...(item.dependencies || []), ...(payload.dependencies || [])])].filter((d) => !d.startsWith('@noe/')),
|
|
51
|
+
peerDependencies: [...new Set([...(item.peerDependencies || []), ...(payload.peerDependencies || [])])],
|
|
52
|
+
// RTL/i18n
|
|
53
|
+
rtl: item.internationalization?.rtl || 'required',
|
|
54
|
+
i18n: {
|
|
55
|
+
messageKeys: item.internationalization?.messageKeys || [],
|
|
56
|
+
bidiNotes: item.internationalization?.bidiNotes || [],
|
|
57
|
+
},
|
|
58
|
+
// Accessibility
|
|
59
|
+
accessibility: item.accessibility || {},
|
|
60
|
+
// Tokens
|
|
61
|
+
tokenContracts: item.tokenContracts || [],
|
|
62
|
+
// Capabilities
|
|
63
|
+
capabilityAliases: item.capabilityAliases || [],
|
|
64
|
+
useWhen: item.useWhen || [],
|
|
65
|
+
doNotUseWhen: item.doNotUseWhen || [],
|
|
66
|
+
// Status and limitations
|
|
67
|
+
knownLimitations:
|
|
68
|
+
item.status === 'partial'
|
|
69
|
+
? 'Known limitation: not yet full a11y/i18n/Rtl coverage; use with caution. See manifest.'
|
|
70
|
+
: undefined,
|
|
71
|
+
};
|
|
72
|
+
|
|
73
|
+
// Keep files, but ensure they are sorted
|
|
74
|
+
enriched.files = payload.files;
|
|
75
|
+
|
|
76
|
+
// Remove undefined
|
|
77
|
+
if (!enriched.knownLimitations) delete enriched.knownLimitations;
|
|
78
|
+
|
|
79
|
+
await writeFile(payloadPath, `${JSON.stringify(enriched, null, 2)}\n`);
|
|
80
|
+
console.log(`Enriched ${item.registryItem}`);
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
console.log('Done enriching');
|
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
import { readFile, writeFile } from 'node:fs/promises';
|
|
2
|
+
import path from 'node:path';
|
|
3
|
+
|
|
4
|
+
const filesToFix = [
|
|
5
|
+
'packages/data-ui/src/data-table.tsx',
|
|
6
|
+
'packages/data-ui/src/chart.tsx',
|
|
7
|
+
'packages/data-ui/src/metric-card.tsx',
|
|
8
|
+
'packages/data-ui/src/filter-bar.tsx',
|
|
9
|
+
'packages/data-ui/src/dashboard-shell.tsx',
|
|
10
|
+
'packages/data-ui/src/activity-gauge.tsx',
|
|
11
|
+
'packages/data-ui/src/pagination.tsx',
|
|
12
|
+
'packages/data-ui/src/pie-chart.tsx',
|
|
13
|
+
'packages/data-ui/src/radar-chart.tsx',
|
|
14
|
+
'packages/data-ui/src/chart-frame.tsx',
|
|
15
|
+
'packages/ai-ui/src/activity-feed.tsx',
|
|
16
|
+
'packages/ai-ui/src/agent-message.tsx',
|
|
17
|
+
'packages/ai-ui/src/agent-composer.tsx',
|
|
18
|
+
'packages/ai-ui/src/agent-plan.tsx',
|
|
19
|
+
'packages/ai-ui/src/agent-workspace.tsx',
|
|
20
|
+
'packages/ai-ui/src/approval-request.tsx',
|
|
21
|
+
'packages/ai-ui/src/tool-call.tsx',
|
|
22
|
+
'packages/ai-ui/src/run-inspector.tsx',
|
|
23
|
+
'packages/workflow-ui/src/workflow-canvas.tsx',
|
|
24
|
+
'packages/workflow-ui/src/workflow-node.tsx',
|
|
25
|
+
'packages/ui/src/inline-cta.tsx',
|
|
26
|
+
'packages/ui/src/calendar.tsx',
|
|
27
|
+
'packages/data-ui/src/pagination.tsx',
|
|
28
|
+
];
|
|
29
|
+
|
|
30
|
+
async function fixFile(filePath) {
|
|
31
|
+
let content = await readFile(filePath, 'utf8');
|
|
32
|
+
const original = content;
|
|
33
|
+
|
|
34
|
+
// Fix @noe/ui imports
|
|
35
|
+
// Example: import { cn, TechnicalValue } from '@noe/ui';
|
|
36
|
+
// Should become: import { cn } from '../../ui/src/lib/cn'; import { TechnicalValue } from '../../ui/src/bidi';
|
|
37
|
+
// For files in data-ui/src, relative to ui/src is ../../ui/src/
|
|
38
|
+
// For files in ai-ui/src, relative is ../../ui/src/
|
|
39
|
+
// For files in workflow-ui/src, relative is ../../ui/src/
|
|
40
|
+
// For files in ui/src, relative to icons is ../../icons/src/
|
|
41
|
+
|
|
42
|
+
// Handle @noe/ui
|
|
43
|
+
if (content.includes("from '@noe/ui'") || content.includes('from "@noe/ui"')) {
|
|
44
|
+
// Determine relative prefix
|
|
45
|
+
const dir = path.dirname(filePath);
|
|
46
|
+
let relToUi = path.relative(dir, 'packages/ui/src').replace(/\\/g, '/');
|
|
47
|
+
if (!relToUi.startsWith('.')) relToUi = `./${relToUi}`;
|
|
48
|
+
// For cn
|
|
49
|
+
if (content.includes('cn')) {
|
|
50
|
+
// Add import for cn if not already via relative
|
|
51
|
+
}
|
|
52
|
+
// Simple replacement: replace the whole import line with relative imports
|
|
53
|
+
// We'll do a simple approach: replace "@noe/ui" with relative path to the specific file that provides the symbol
|
|
54
|
+
// But we need to know which file provides which symbol:
|
|
55
|
+
// cn -> lib/cn.ts
|
|
56
|
+
// TechnicalValue, Bidi, AutoDirectionText -> bidi.tsx
|
|
57
|
+
// Button -> button.tsx
|
|
58
|
+
// For simplicity, replace "@noe/ui" with relative to index, but index is not in payload
|
|
59
|
+
// Instead, we will replace with direct file imports
|
|
60
|
+
|
|
61
|
+
// Extract the import line
|
|
62
|
+
content = content.replace(
|
|
63
|
+
/import\s+\{([^}]+)\}\s+from\s+['"]@noe\/ui['"]/g,
|
|
64
|
+
(_match, imports) => {
|
|
65
|
+
const parts = imports.split(',').map((s) => s.trim());
|
|
66
|
+
const hasCn = parts.some((p) => p.includes('cn'));
|
|
67
|
+
const hasTechnical = parts.some(
|
|
68
|
+
(p) => p.includes('TechnicalValue') || p.includes('Bidi') || p.includes('AutoDirection'),
|
|
69
|
+
);
|
|
70
|
+
const hasButton = parts.some((p) => p.includes('Button'));
|
|
71
|
+
let result = '';
|
|
72
|
+
if (hasCn) {
|
|
73
|
+
// Check if file already has cn import via relative, but we will add
|
|
74
|
+
result += `import { cn } from '${relToUi}/lib/cn';\n`;
|
|
75
|
+
}
|
|
76
|
+
if (hasTechnical) {
|
|
77
|
+
const techImports = parts
|
|
78
|
+
.filter(
|
|
79
|
+
(p) =>
|
|
80
|
+
p.includes('TechnicalValue') || p.includes('Bidi') || p.includes('AutoDirection'),
|
|
81
|
+
)
|
|
82
|
+
.join(', ');
|
|
83
|
+
result += `import { ${techImports} } from '${relToUi}/bidi';\n`;
|
|
84
|
+
}
|
|
85
|
+
if (hasButton) {
|
|
86
|
+
const buttonImports = parts.filter((p) => p.includes('Button')).join(', ');
|
|
87
|
+
result += `import { ${buttonImports} } from '${relToUi}/button';\n`;
|
|
88
|
+
}
|
|
89
|
+
// Handle remaining (like other symbols)
|
|
90
|
+
const remaining = parts.filter(
|
|
91
|
+
(p) =>
|
|
92
|
+
!p.includes('cn') &&
|
|
93
|
+
!p.includes('TechnicalValue') &&
|
|
94
|
+
!p.includes('Bidi') &&
|
|
95
|
+
!p.includes('AutoDirection') &&
|
|
96
|
+
!p.includes('Button'),
|
|
97
|
+
);
|
|
98
|
+
if (remaining.length) {
|
|
99
|
+
result += `import { ${remaining.join(', ')} } from '${relToUi}/lib/cn';\n`; // fallback
|
|
100
|
+
}
|
|
101
|
+
return result.trim();
|
|
102
|
+
},
|
|
103
|
+
);
|
|
104
|
+
|
|
105
|
+
// Fix duplicate imports that may have been created
|
|
106
|
+
// Remove empty lines
|
|
107
|
+
content = content.replace(/\n\n\n+/g, '\n\n');
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
// Fix @noe/icons
|
|
111
|
+
if (content.includes("from '@noe/icons'") || content.includes('from "@noe/icons"')) {
|
|
112
|
+
const dir = path.dirname(filePath);
|
|
113
|
+
let relToIcons = path.relative(dir, 'packages/icons/src').replace(/\\/g, '/');
|
|
114
|
+
if (!relToIcons.startsWith('.')) relToIcons = `./${relToIcons}`;
|
|
115
|
+
content = content.replace(/from\s+['"]@noe\/icons['"]/g, `from '${relToIcons}/index.tsx'`);
|
|
116
|
+
content = content.replace(/from\s+['"]@noe\/icons\/[^'"]+['"]/g, (_m) => {
|
|
117
|
+
// For specific icon imports, map to index
|
|
118
|
+
return `from '${relToIcons}/index.tsx'`;
|
|
119
|
+
});
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
if (content !== original) {
|
|
123
|
+
await writeFile(filePath, content);
|
|
124
|
+
console.log(`Fixed ${filePath}`);
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
for (const f of filesToFix) {
|
|
129
|
+
try {
|
|
130
|
+
await fixFile(f);
|
|
131
|
+
} catch (e) {
|
|
132
|
+
console.error(`Failed ${f}: ${e.message}`);
|
|
133
|
+
}
|
|
134
|
+
}
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import { readdir, readFile, writeFile } from 'node:fs/promises';
|
|
2
|
+
import path from 'node:path';
|
|
3
|
+
import { fileURLToPath } from 'node:url';
|
|
4
|
+
|
|
5
|
+
const root = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '..');
|
|
6
|
+
|
|
7
|
+
function extractImports(content) {
|
|
8
|
+
const imports = [];
|
|
9
|
+
for (const m of content.matchAll(/from\s+['"]([^'"]+)['"]/g)) imports.push(m[1]);
|
|
10
|
+
for (const m of content.matchAll(/import\s+['"]([^'"]+)['"]/g)) if (!imports.includes(m[1])) imports.push(m[1]);
|
|
11
|
+
return imports;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
async function resolveRelative(fromFile, importPath) {
|
|
15
|
+
if (!importPath.startsWith('.')) return null;
|
|
16
|
+
const dir = path.dirname(fromFile);
|
|
17
|
+
const resolved = path.join(dir, importPath);
|
|
18
|
+
const candidates = [
|
|
19
|
+
`${resolved}.ts`,
|
|
20
|
+
`${resolved}.tsx`,
|
|
21
|
+
path.join(resolved, 'index.ts'),
|
|
22
|
+
path.join(resolved, 'index.tsx'),
|
|
23
|
+
resolved,
|
|
24
|
+
];
|
|
25
|
+
for (const cand of candidates) {
|
|
26
|
+
try {
|
|
27
|
+
await readFile(path.join(root, cand));
|
|
28
|
+
return cand;
|
|
29
|
+
} catch {}
|
|
30
|
+
}
|
|
31
|
+
try {
|
|
32
|
+
await readFile(path.join(root, resolved));
|
|
33
|
+
return resolved;
|
|
34
|
+
} catch {}
|
|
35
|
+
return null;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
const rDir = path.join(root, 'packages/registry/r');
|
|
39
|
+
const files = await readdir(rDir);
|
|
40
|
+
let totalFixed = 0;
|
|
41
|
+
|
|
42
|
+
for (const file of files) {
|
|
43
|
+
if (!file.endsWith('.json')) continue;
|
|
44
|
+
const payloadPath = path.join(rDir, file);
|
|
45
|
+
const payload = JSON.parse(await readFile(payloadPath, 'utf8'));
|
|
46
|
+
const originalFiles = new Set(payload.files?.map((f) => f.path) || []);
|
|
47
|
+
const toProcess = [...originalFiles];
|
|
48
|
+
const visited = new Set();
|
|
49
|
+
const missingFiles = new Set();
|
|
50
|
+
const registryDeps = new Set(payload.registryDependencies || []);
|
|
51
|
+
const dependencies = new Set(payload.dependencies || []);
|
|
52
|
+
|
|
53
|
+
while (toProcess.length) {
|
|
54
|
+
const current = toProcess.pop();
|
|
55
|
+
if (visited.has(current)) continue;
|
|
56
|
+
visited.add(current);
|
|
57
|
+
let content;
|
|
58
|
+
try {
|
|
59
|
+
content = await readFile(path.join(root, current), 'utf8');
|
|
60
|
+
} catch {
|
|
61
|
+
continue;
|
|
62
|
+
}
|
|
63
|
+
for (const imp of extractImports(content)) {
|
|
64
|
+
if (imp.startsWith('.')) {
|
|
65
|
+
const resolved = await resolveRelative(current, imp);
|
|
66
|
+
if (!resolved) {
|
|
67
|
+
console.error(`FAIL ${payload.name}: ${current} -> '${imp}' not found`);
|
|
68
|
+
continue;
|
|
69
|
+
}
|
|
70
|
+
if (!originalFiles.has(resolved) && !missingFiles.has(resolved)) {
|
|
71
|
+
missingFiles.add(resolved);
|
|
72
|
+
toProcess.push(resolved);
|
|
73
|
+
}
|
|
74
|
+
} else if (imp.startsWith('@noe/')) {
|
|
75
|
+
if (imp.startsWith('@noe/icons')) {
|
|
76
|
+
registryDeps.add('icon-system');
|
|
77
|
+
dependencies.add('@noe/icons');
|
|
78
|
+
} else if (imp.startsWith('@noe/i18n')) dependencies.add('@noe/i18n');
|
|
79
|
+
else if (imp.startsWith('@noe/ui')) dependencies.add('@noe/ui');
|
|
80
|
+
else if (imp.startsWith('@noe/data-ui')) dependencies.add('@noe/data-ui');
|
|
81
|
+
else if (imp.startsWith('@noe/ai-ui')) dependencies.add('@noe/ai-ui');
|
|
82
|
+
else dependencies.add(imp.split('/').slice(0, 2).join('/'));
|
|
83
|
+
} else if (imp.startsWith('@base-ui')) dependencies.add('@base-ui/react');
|
|
84
|
+
else if (imp === 'clsx') dependencies.add('clsx');
|
|
85
|
+
else if (imp === 'tailwind-merge') dependencies.add('tailwind-merge');
|
|
86
|
+
else if (imp.startsWith('class-variance-authority'))
|
|
87
|
+
dependencies.add('class-variance-authority');
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
if (
|
|
92
|
+
missingFiles.size > 0 ||
|
|
93
|
+
registryDeps.size !== (payload.registryDependencies || []).length ||
|
|
94
|
+
dependencies.size !== (payload.dependencies || []).length
|
|
95
|
+
) {
|
|
96
|
+
console.log(`Fixing ${payload.name}: missing ${[...missingFiles].join(', ')}`);
|
|
97
|
+
for (const mf of missingFiles) {
|
|
98
|
+
if (!originalFiles.has(mf)) {
|
|
99
|
+
payload.files.push({ path: mf, type: 'registry:component', target: mf });
|
|
100
|
+
originalFiles.add(mf);
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
payload.registryDependencies = [...registryDeps].sort();
|
|
104
|
+
payload.dependencies = [...dependencies].sort();
|
|
105
|
+
payload.files.sort((a, b) => a.path.localeCompare(b.path));
|
|
106
|
+
await writeFile(payloadPath, `${JSON.stringify(payload, null, 2)}\n`);
|
|
107
|
+
totalFixed++;
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
console.log(`Fixed ${totalFixed} payloads`);
|
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
import { readdir, readFile, writeFile } from 'node:fs/promises';
|
|
2
|
+
import path from 'node:path';
|
|
3
|
+
import { fileURLToPath } from 'node:url';
|
|
4
|
+
|
|
5
|
+
const root = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '..');
|
|
6
|
+
const rDir = path.join(root, 'packages/registry/r');
|
|
7
|
+
const files = await readdir(rDir);
|
|
8
|
+
|
|
9
|
+
for (const file of files) {
|
|
10
|
+
if (!file.endsWith('.json')) continue;
|
|
11
|
+
const p = path.join(rDir, file);
|
|
12
|
+
const payload = JSON.parse(await readFile(p, 'utf8'));
|
|
13
|
+
let changed = false;
|
|
14
|
+
|
|
15
|
+
// Remove local @noe/* from dependencies (they should be via files or registryDependencies)
|
|
16
|
+
const origDeps = [...(payload.dependencies || [])];
|
|
17
|
+
const newDeps = origDeps.filter((d) => !d.startsWith('@noe/'));
|
|
18
|
+
if (newDeps.length !== origDeps.length) {
|
|
19
|
+
payload.dependencies = newDeps;
|
|
20
|
+
changed = true;
|
|
21
|
+
console.log(`Fix ${payload.name}: removed @noe/* from dependencies ${origDeps} -> ${newDeps}`);
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
// For @noe/icons, ensure registryDependencies has icon-system if file imports it
|
|
25
|
+
// Check files for icon imports
|
|
26
|
+
let hasIconImport = false;
|
|
27
|
+
let hasI18nImport = false;
|
|
28
|
+
const _hasCnImport = false;
|
|
29
|
+
for (const f of payload.files || []) {
|
|
30
|
+
try {
|
|
31
|
+
const content = await readFile(path.join(root, f.path), 'utf8');
|
|
32
|
+
if (content.includes('@noe/icons') || content.includes('ChevronIcon')) hasIconImport = true;
|
|
33
|
+
if (
|
|
34
|
+
content.includes('@noe/i18n') ||
|
|
35
|
+
content.includes('t(') ||
|
|
36
|
+
content.includes('getMessages')
|
|
37
|
+
)
|
|
38
|
+
hasI18nImport = true;
|
|
39
|
+
if (
|
|
40
|
+
content.includes("from './lib/cn'") ||
|
|
41
|
+
content.includes('from "./lib/cn"') ||
|
|
42
|
+
content.includes('from "@/lib/cn"') ||
|
|
43
|
+
content.includes('cn(')
|
|
44
|
+
) {
|
|
45
|
+
// Check if lib/cn is already in files
|
|
46
|
+
}
|
|
47
|
+
} catch {}
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
// Ensure lib/cn is included if needed
|
|
51
|
+
const hasLibCn = payload.files.some((f) => f.path === 'packages/ui/src/lib/cn.ts');
|
|
52
|
+
// Check if any file imports cn
|
|
53
|
+
let needsCn = false;
|
|
54
|
+
for (const f of payload.files || []) {
|
|
55
|
+
try {
|
|
56
|
+
const c = await readFile(path.join(root, f.path), 'utf8');
|
|
57
|
+
if (
|
|
58
|
+
c.includes("from './lib/cn'") ||
|
|
59
|
+
c.includes('from "./lib/cn"') ||
|
|
60
|
+
c.includes("from '../lib/cn'") ||
|
|
61
|
+
c.includes('cn(') ||
|
|
62
|
+
c.includes("from '@/lib/cn'") ||
|
|
63
|
+
c.includes('@noe/ui')
|
|
64
|
+
) {
|
|
65
|
+
// Heuristic: if it imports from @noe/ui and that ui file is cn, or direct
|
|
66
|
+
if (c.includes('./lib/cn') || c.includes('cn(')) needsCn = true;
|
|
67
|
+
}
|
|
68
|
+
} catch {}
|
|
69
|
+
}
|
|
70
|
+
if (needsCn && !hasLibCn) {
|
|
71
|
+
payload.files.push({
|
|
72
|
+
path: 'packages/ui/src/lib/cn.ts',
|
|
73
|
+
type: 'registry:component',
|
|
74
|
+
target: 'packages/ui/src/lib/cn.ts',
|
|
75
|
+
});
|
|
76
|
+
payload.files.sort((a, b) => a.path.localeCompare(b.path));
|
|
77
|
+
changed = true;
|
|
78
|
+
console.log(`Fix ${payload.name}: added lib/cn.ts`);
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
// Handle @noe/icons: if hasIconImport, ensure registryDependencies has icon-system
|
|
82
|
+
if (hasIconImport) {
|
|
83
|
+
const rd = new Set(payload.registryDependencies || []);
|
|
84
|
+
if (!rd.has('icon-system')) {
|
|
85
|
+
rd.add('icon-system');
|
|
86
|
+
payload.registryDependencies = [...rd].sort();
|
|
87
|
+
changed = true;
|
|
88
|
+
console.log(`Fix ${payload.name}: added icon-system to registryDependencies`);
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
// Handle @noe/i18n
|
|
93
|
+
if (hasI18nImport) {
|
|
94
|
+
// Should have dependency on @noe/i18n? But that's local, not npm. Better to add file for i18n-messages
|
|
95
|
+
const hasI18nFile = payload.files.some(
|
|
96
|
+
(f) => f.path === 'packages/ui/src/lib/i18n-messages.ts',
|
|
97
|
+
);
|
|
98
|
+
if (!hasI18nFile) {
|
|
99
|
+
// Check if file exists and is needed
|
|
100
|
+
try {
|
|
101
|
+
await readFile(path.join(root, 'packages/ui/src/lib/i18n-messages.ts'));
|
|
102
|
+
// If any file imports from i18n-messages, add it
|
|
103
|
+
let needsI18nFile = false;
|
|
104
|
+
for (const f of payload.files || []) {
|
|
105
|
+
try {
|
|
106
|
+
const c = await readFile(path.join(root, f.path), 'utf8');
|
|
107
|
+
if (c.includes('i18n-messages') || c.includes("from '@noe/i18n'")) needsI18nFile = true;
|
|
108
|
+
} catch {}
|
|
109
|
+
}
|
|
110
|
+
if (needsI18nFile) {
|
|
111
|
+
payload.files.push({
|
|
112
|
+
path: 'packages/ui/src/lib/i18n-messages.ts',
|
|
113
|
+
type: 'registry:component',
|
|
114
|
+
target: 'packages/ui/src/lib/i18n-messages.ts',
|
|
115
|
+
});
|
|
116
|
+
payload.files.sort((a, b) => a.path.localeCompare(b.path));
|
|
117
|
+
changed = true;
|
|
118
|
+
console.log(`Fix ${payload.name}: added lib/i18n-messages.ts`);
|
|
119
|
+
}
|
|
120
|
+
} catch {}
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
// For data-ui/ai-ui that import from @noe/ui, ensure they have lib/cn or other ui files
|
|
125
|
+
// We already handled lib/cn, but also need to handle TechnicalValue etc. which is in bidi.tsx
|
|
126
|
+
// For data-table which imports TechnicalValue from @noe/ui, need bidi.tsx
|
|
127
|
+
let needsBidi = false;
|
|
128
|
+
for (const f of payload.files || []) {
|
|
129
|
+
try {
|
|
130
|
+
const c = await readFile(path.join(root, f.path), 'utf8');
|
|
131
|
+
if (c.includes('TechnicalValue') || c.includes('Bidi')) needsBidi = true;
|
|
132
|
+
} catch {}
|
|
133
|
+
}
|
|
134
|
+
if (needsBidi && !payload.files.some((f) => f.path === 'packages/ui/src/bidi.tsx')) {
|
|
135
|
+
payload.files.push({
|
|
136
|
+
path: 'packages/ui/src/bidi.tsx',
|
|
137
|
+
type: 'registry:component',
|
|
138
|
+
target: 'packages/ui/src/bidi.tsx',
|
|
139
|
+
});
|
|
140
|
+
payload.files.sort((a, b) => a.path.localeCompare(b.path));
|
|
141
|
+
changed = true;
|
|
142
|
+
console.log(`Fix ${payload.name}: added bidi.tsx for TechnicalValue`);
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
if (changed) {
|
|
146
|
+
await writeFile(p, `${JSON.stringify(payload, null, 2)}\n`);
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
console.log('Done cleanup');
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
import { readFile, writeFile } from 'node:fs/promises';
|
|
2
|
+
|
|
3
|
+
const files = [
|
|
4
|
+
'packages/data-ui/src/data-table.tsx',
|
|
5
|
+
'packages/data-ui/src/chart.tsx',
|
|
6
|
+
'packages/data-ui/src/metric-card.tsx',
|
|
7
|
+
'packages/data-ui/src/filter-bar.tsx',
|
|
8
|
+
'packages/data-ui/src/dashboard-shell.tsx',
|
|
9
|
+
'packages/data-ui/src/activity-gauge.tsx',
|
|
10
|
+
'packages/data-ui/src/pagination.tsx',
|
|
11
|
+
'packages/data-ui/src/pie-chart.tsx',
|
|
12
|
+
'packages/data-ui/src/radar-chart.tsx',
|
|
13
|
+
'packages/data-ui/src/chart-frame.tsx',
|
|
14
|
+
'packages/ai-ui/src/activity-feed.tsx',
|
|
15
|
+
'packages/ai-ui/src/agent-message.tsx',
|
|
16
|
+
'packages/ai-ui/src/agent-composer.tsx',
|
|
17
|
+
'packages/ai-ui/src/agent-plan.tsx',
|
|
18
|
+
'packages/ai-ui/src/agent-workspace.tsx',
|
|
19
|
+
'packages/ai-ui/src/approval-request.tsx',
|
|
20
|
+
'packages/ai-ui/src/tool-call.tsx',
|
|
21
|
+
'packages/ai-ui/src/run-inspector.tsx',
|
|
22
|
+
'packages/workflow-ui/src/workflow-canvas.tsx',
|
|
23
|
+
'packages/workflow-ui/src/workflow-node.tsx',
|
|
24
|
+
];
|
|
25
|
+
|
|
26
|
+
for (const file of files) {
|
|
27
|
+
let content = await readFile(file, 'utf8');
|
|
28
|
+
const orig = content;
|
|
29
|
+
// Replace @noe/ui imports with relative without src/
|
|
30
|
+
// For files in data-ui/src, ai-ui/src, workflow-ui/src, the relative to ui is ../ui/
|
|
31
|
+
// For ui/src files, they don't import from @noe/ui, so skip
|
|
32
|
+
if (content.includes("from '@noe/ui'") || content.includes('from "@noe/ui"')) {
|
|
33
|
+
// Extract the imported symbols
|
|
34
|
+
const match = content.match(/import\s+\{([^}]+)\}\s+from\s+['"]@noe\/ui['"]/);
|
|
35
|
+
if (match) {
|
|
36
|
+
const imports = match[1].split(',').map((s) => s.trim());
|
|
37
|
+
let replacement = '';
|
|
38
|
+
const cnImport = imports.find((i) => i.includes('cn'));
|
|
39
|
+
const techImport = imports.find(
|
|
40
|
+
(i) => i.includes('TechnicalValue') || i.includes('Bidi') || i.includes('AutoDirection'),
|
|
41
|
+
);
|
|
42
|
+
const buttonImport = imports.find((i) => i.includes('Button'));
|
|
43
|
+
if (cnImport) {
|
|
44
|
+
// Determine relative path: from data-ui/src to ui is ../ui, from ai-ui/src to ui is ../../ui? Actually both are packages/*/src to packages/ui
|
|
45
|
+
// For packages/data-ui/src/*.tsx, relative to packages/ui is ../../ui
|
|
46
|
+
// But for installed, it's ../ui
|
|
47
|
+
// We need a path that works for both: use ../ui for installed, but for source repo, ../../ui/src is correct
|
|
48
|
+
// For now, use ../ui/lib/cn without src/ to match installed
|
|
49
|
+
replacement += `import { cn } from '../ui/lib/cn';\n`;
|
|
50
|
+
}
|
|
51
|
+
if (techImport) {
|
|
52
|
+
const techParts = imports
|
|
53
|
+
.filter(
|
|
54
|
+
(i) =>
|
|
55
|
+
i.includes('TechnicalValue') || i.includes('Bidi') || i.includes('AutoDirection'),
|
|
56
|
+
)
|
|
57
|
+
.join(', ');
|
|
58
|
+
replacement += `import { ${techParts} } from '../ui/bidi';\n`;
|
|
59
|
+
}
|
|
60
|
+
if (buttonImport) {
|
|
61
|
+
replacement += `import { Button } from '../ui/button';\n`;
|
|
62
|
+
}
|
|
63
|
+
// Handle remaining
|
|
64
|
+
const remaining = imports.filter(
|
|
65
|
+
(i) =>
|
|
66
|
+
!i.includes('cn') &&
|
|
67
|
+
!i.includes('TechnicalValue') &&
|
|
68
|
+
!i.includes('Bidi') &&
|
|
69
|
+
!i.includes('AutoDirection') &&
|
|
70
|
+
!i.includes('Button'),
|
|
71
|
+
);
|
|
72
|
+
if (remaining.length) {
|
|
73
|
+
replacement += `import { ${remaining.join(', ')} } from '../ui/lib/cn';\n`;
|
|
74
|
+
}
|
|
75
|
+
content = content.replace(
|
|
76
|
+
/import\s+\{[^}]+\}\s+from\s+['"]@noe\/ui['"];?/,
|
|
77
|
+
replacement.trim(),
|
|
78
|
+
);
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
// Fix icons
|
|
82
|
+
if (content.includes("from '@noe/icons'")) {
|
|
83
|
+
// Determine relative: from data-ui/src to icons is ../../icons, but installed is ../icons
|
|
84
|
+
content = content.replace(/from\s+['"]@noe\/icons['"]/g, "from '../icons/index'");
|
|
85
|
+
content = content.replace(/from\s+['"]@noe\/icons\/[^'"]+['"]/g, "from '../icons/index'");
|
|
86
|
+
}
|
|
87
|
+
// For ui/src files that import from @noe/icons, they are at packages/ui/src, relative to icons is ../../icons
|
|
88
|
+
if (content.includes('../../icons/src/index')) {
|
|
89
|
+
content = content.replace(
|
|
90
|
+
/from\s+['"]\.\.\/\.\.\/icons\/src\/index['"]/g,
|
|
91
|
+
"from '../icons/index'",
|
|
92
|
+
);
|
|
93
|
+
content = content.replace(
|
|
94
|
+
/from\s+['"]\.\.\/\.\.\/icons\/src\/index\.tsx['"]/g,
|
|
95
|
+
"from '../icons/index'",
|
|
96
|
+
);
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
if (content !== orig) {
|
|
100
|
+
await writeFile(file, content);
|
|
101
|
+
console.log(`Fixed ${file}`);
|
|
102
|
+
}
|
|
103
|
+
}
|