feat: generate Astryx UI profiles for Vite apps - #1328
Conversation
|
Warning Review limit reached
Next review available in: 8 seconds Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (8)
📝 WalkthroughWalkthroughAstryx UI 지원이 추가되었습니다. ChangesAstryx UI profile
Estimated code review effort: 4 (Complex) | ~60 minutes Sequence Diagram(s)sequenceDiagram
participant Developer
participant CreateCrocoApp
participant UiAstryx
participant GeneratedSmoke
participant RuntimeCatalog
Developer->>CreateCrocoApp: select --ui astryx
CreateCrocoApp->>UiAstryx: install profile and template
UiAstryx-->>CreateCrocoApp: write app metadata and dependencies
CreateCrocoApp->>GeneratedSmoke: run presentation smoke
GeneratedSmoke->>RuntimeCatalog: compare generated profile
RuntimeCatalog-->>GeneratedSmoke: validate runtime and UI metadata
Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
📊 Benchmark Results✅ All benchmarks passed
Updated: 2026-07-11T18:12:18.305Z · Commit: 7815eeb |
143422c to
7a41fde
Compare
7a41fde to
619cd81
Compare
There was a problem hiding this comment.
Actionable comments posted: 4
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@packages/ui-astryx/src/index.ts`:
- Around line 1-14: Reorder the exports in the barrel index so all
component/value exports, including AstryxAppShell, AstryxAuthState,
AstryxProblemView, and AstryxProvider, come first; move every type-only export
group, including the crocoUiTypes exports, to the final group while preserving
their existing exports.
In `@packages/ui-astryx/src/libs/AstryxAuthState.tsx`:
- Around line 1-8: Reorganize the imports in AstryxAuthState.tsx so value
imports come first, followed by a separate type-only import section. Preserve
the grouping order of external packages, `@croco/`* imports, and relative imports,
ensuring BadgeVariant is not mixed with the Badge, Button, and Card value
imports.
- Around line 90-112: Update AstryxAuthState to filter recoveryActions by each
AstryxRecoveryAction’s problemCodes using the same matching rules as
AstryxProblemView, based on problem?.code. Only render actions applicable to the
current problem, and render no problem-specific actions when no problem is
present; keep the existing actionButton rendering for the filtered list.
In `@scripts/package-entrypoint-smoke.mts`:
- Around line 983-989: Update the conditional exports handling around
isStaticAssetTargetPath so CSS values under both import and require branches are
treated as static assets. Route them through validateStaticAssetTarget and
return before pushStringTarget, ensuring they are not classified as module
targets.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro
Run ID: a34bac27-180c-4e9e-8e80-99c5431936b4
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (64)
.changeset/astryx-vite-ui-profile.md.github/workflows/ci.ymlREADME.mdcroco.arch.jsondocs/package-catalog.jsondocs/package-docs-report.mdpackages/create-croco-app/README.mdpackages/create-croco-app/src/cli-program.tspackages/create-croco-app/src/generator.tspackages/create-croco-app/src/goals.tspackages/create-croco-app/src/helpers/croco-ranges.tspackages/create-croco-app/src/installers/index.tspackages/create-croco-app/src/installers/ui-profile.tspackages/create-croco-app/src/options.tspackages/create-croco-app/src/prompts.tspackages/create-croco-app/src/supported-options.tspackages/create-croco-app/src/tests/e2e-vite-spa.spec.tspackages/create-croco-app/src/tests/options.spec.tspackages/create-croco-app/src/tests/prompts.spec.tspackages/create-croco-app/src/types.tspackages/create-croco-app/templates/addons/ui-astryx-vite-spa/src/App.tsx.hbspackages/create-croco-app/templates/addons/ui-astryx-vite-spa/src/main.tsxpackages/create-croco-app/templates/addons/ui-astryx-vite-spa/src/presentation-smoke.tsxpackages/docs/astro.config.mjspackages/docs/package.jsonpackages/docs/src/content/docs/api/presentation-preset/src/type-aliases/GeneratedRuntimeProfile.mdpackages/docs/src/content/docs/api/presentation-preset/src/type-aliases/GeneratedUiProfileMaturity.mdpackages/docs/src/content/docs/api/presentation-preset/src/type-aliases/GeneratedUiProfileMetadata.mdpackages/docs/src/content/docs/api/presentation-preset/src/type-aliases/GeneratedUiProfileName.mdpackages/docs/src/content/docs/api/presentation-preset/src/type-aliases/GeneratedUiStyleEngine.mdpackages/docs/src/content/docs/api/ui-astryx/src/type-aliases/AstryxProblemRecoveryAction.mdpackages/docs/src/content/docs/api/ui-astryx/src/type-aliases/AstryxRecoveryAction.mdpackages/docs/src/content/docs/api/ui-astryx/src/type-aliases/AstryxSession.mdpackages/docs/src/content/docs/api/ui-astryx/src/type-aliases/AstryxSessionState.mdpackages/docs/src/content/docs/en/guides/getting-started.mdxpackages/docs/src/content/docs/en/index.mdxpackages/docs/src/content/docs/en/reference/extension-matrix.mdpackages/docs/src/content/docs/en/reference/presentation-runtime-support.mdpackages/docs/tsconfig.typedoc.jsonpackages/presentation-preset/README.mdpackages/presentation-preset/runtime-profiles.jsonpackages/presentation-preset/src/__tests__/output-contract-validator.spec.tspackages/presentation-preset/src/index.tspackages/presentation-preset/src/output-contract-validator.tspackages/presentation-preset/src/output-contract.tspackages/ui-astryx/README.mdpackages/ui-astryx/package.jsonpackages/ui-astryx/src/index.tspackages/ui-astryx/src/libs/AstryxAppShell.tsxpackages/ui-astryx/src/libs/AstryxAuthState.tsxpackages/ui-astryx/src/libs/AstryxProblemView.tsxpackages/ui-astryx/src/libs/AstryxProvider.tsxpackages/ui-astryx/src/libs/crocoUiTypes.tspackages/ui-astryx/src/tests/AstryxUi.spec.tspackages/ui-astryx/styles.csspackages/ui-astryx/tsconfig.jsonpublic-api-surface.snapshot.jsonscripts/create-croco-app-generated-smoke-matrix.mtsscripts/create-croco-app-generated-smoke.mtsscripts/package-entrypoint-smoke.mtsscripts/static-misuse-raw-error-allowlist.jsonscripts/tests/create-croco-app-generated-smoke.spec.tsscripts/tests/package-entrypoint-smoke.spec.tstsconfig/contract-strict.baseline.json
|
@coderabbitai review |
✅ Action performedReview finished.
|
Fixes #1268.
Summary
ddd-fullstackVite SPAs can opt into a beta Astryx UI profile with provider, shell, Problem, and auth-state primitives; explicitnoneremains isolated and omitting--uipreserves the legacy output.Verification
pnpm checkpassed, including architecture, strict-contract, static-misuse, public API, lint, and formatting gates.pnpm typecheckpassed: 226/226 tasks.pnpm testpassed: 227/227 tasks.CROCO_GENERATED_SMOKE_CASES=graphql-vite-spa-astryx pnpm create-croco-app:smokepassed install, workspace build, GraphQL contract and snapshot, metadata, typecheck, Vite build, render, and drift canaries.@croco/ui-astryxartifact includes runtime files, type declarations, and the exported CSS subpath.Self-review gates
none, Astryx, and invalid no-write paths are covered.@croco/frontend-reactremains provider-neutral, with no production meta-vite or StyleX compiler/plugin coupling.Review and QA
Residual risk
Astryx remains beta and opt-in. This change proves the Vite SPA path; meta-vite SSR/hydration support and promotion to a default profile remain deferred until dedicated evidence exists.
Summary by CodeRabbit
@croco/ui-astryx가 추가되었습니다.create-croco-app에서--ui none|astryx옵션으로 Vite SPA UI를 선택할 수 있습니다.