Skip to content

feat(packages): introduce luna-stage-preview#92

Open
Dugyu wants to merge 1 commit intomainfrom
feat/extract-stage-preview
Open

feat(packages): introduce luna-stage-preview#92
Dugyu wants to merge 1 commit intomainfrom
feat/extract-stage-preview

Conversation

@Dugyu
Copy link
Copy Markdown
Owner

@Dugyu Dugyu commented Apr 13, 2026

Extract the stage visualization system (Mockup, Choreography, LunaLynxStage, Studio) from apps/studio into a standalone reusable package. apps/studio is now a thin consumer of it.

Summary by CodeRabbit

  • New Features

    • Introduced a new modular stage preview package for improved code organization and component reusability.
  • Refactor

    • Reorganized studio components and architecture for better maintainability.
    • Streamlined dependencies by consolidating and updating package requirements.
    • Updated TypeScript configuration to support enhanced modular structure.

@changeset-bot
Copy link
Copy Markdown

changeset-bot bot commented Apr 13, 2026

⚠️ No Changeset found

Latest commit: ca44293

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 13, 2026

Walkthrough

This PR extracts the core studio UI components and related utilities from apps/studio into a new shared library package @dugyu/luna-stage-preview. Components such as Studio, Choreography, LynxStage, and StudioFrame are removed from the monorepo app and re-implemented in the new package. The app is updated to import from the new library and pass configuration through props. Build configs and TypeScript references are added for the new package.

Changes

Cohort / File(s) Summary
Spell check and configuration
.cspell/misc.txt, apps/studio/tailwind.config.ts, apps/studio/tsconfig.json
Added tsgo to spell-check dictionary and extended Tailwind content scanning to include the new luna-stage-preview package dist files.
Apps/studio dependency updates
apps/studio/package.json
Removed UI and utility library dependencies (@headlessui/react, clsx, lucide-react, motion, tailwind-merge) and added workspace dependency on @dugyu/luna-stage-preview.
Apps/studio component removals
apps/studio/src/components/choreography/*, apps/studio/src/components/studio/*, apps/studio/src/components/studio-frame/*, apps/studio/src/components/lynx-stage/*, apps/studio/src/components/mockup-motion/*
Removed multiple component implementations and re-exports that are now part of the luna-stage-preview library, including Choreography, CompareView, FocusView, LynxStage, Studio, StudioFrame, and motion-related components.
Apps/studio integration
apps/studio/src/App.tsx, apps/studio/src/types/index.ts
Updated to import Studio and cn from @dugyu/luna-stage-preview and import RECORD_MODE from local constants; updated MoonriseEvent type source from local to external package.
Luna-stage-preview package initialization
packages/luna-stage-preview/package.json, packages/luna-stage-preview/rslib.config.ts, packages/luna-stage-preview/tsconfig.json, packages/luna-stage-preview/tsconfig.build.json
Created new package with rslib build configuration, TypeScript configs, and export map defining public API surface.
Luna-stage-preview components
packages/luna-stage-preview/src/components/choreography/*, packages/luna-stage-preview/src/components/studio/*, packages/luna-stage-preview/src/components/studio-frame/*, packages/luna-stage-preview/src/components/lynx-stage/*, packages/luna-stage-preview/src/components/mockup-motion/*, packages/luna-stage-preview/src/components/mockup/*
Re-implemented core components with updated prop APIs to accept configurable stages, layouts, and bundle base URL; added SSR-safe wrappers; extracted reusable context providers.
Luna-stage-preview types and utilities
packages/luna-stage-preview/src/types/global.d.ts, packages/luna-stage-preview/src/types/stage.ts, packages/luna-stage-preview/src/data/default-stages.ts, packages/luna-stage-preview/src/hooks/*
Added global JSX typings for lynx-view element, updated type imports to external packages, refactored hooks with improved SSR handling and null-safety, adjusted ResizeObserver and effect timing logic.
Luna-stage-preview public API
packages/luna-stage-preview/src/index.ts, packages/luna-stage-preview/src/utils/index.ts
Defined comprehensive public entrypoint exporting all components, types, hooks, and utilities; cleaned up JSDoc for internal utilities.
Root TypeScript configuration
tsconfig.json
Added luna-stage-preview to project references for composite build support.

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~50 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 28.57% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The PR title 'feat(packages): introduce luna-stage-preview' directly and concisely describes the main change: introducing a new package.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/extract-stage-preview

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Extract the stage visualization system (Mockup, Choreography,
LunaLynxStage, Studio) from apps/studio into a standalone
reusable package. apps/studio is now a thin consumer of it.
@Dugyu Dugyu force-pushed the feat/extract-stage-preview branch from fbfb54d to ca44293 Compare April 13, 2026 06:12
Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🧹 Nitpick comments (3)
packages/luna-stage-preview/src/components/studio-frame/studio-frame.tsx (1)

10-16: Consider clarifying non-interactive semantics in the prop API.

Since the root class always includes pointer-events-none, interactive handlers passed via restProps won’t fire. Consider either documenting that explicitly in StudioFrameProps or narrowing forwarded interactive props to avoid a misleading API surface.

Also applies to: 24-29

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/luna-stage-preview/src/components/studio-frame/studio-frame.tsx`
around lines 10 - 16, The StudioFrame component's root element always applies
the CSS class "pointer-events-none", which prevents any interactive handlers
forwarded via restProps from firing; update the StudioFrameProps type and usage
to either (A) document this behavior by adding a clear comment to
StudioFrameProps indicating the component is non-interactive and that event
handlers passed via restProps will be ignored, or (B) change the forwarding
logic to exclude interactive props (like onClick, onMouseDown, onKeyDown,
tabIndex, role) from restProps so callers aren't misled—locate the
StudioFrameProps definition and the root element where the "pointer-events-none"
class and restProps are applied to implement one of these fixes.
apps/studio/tailwind.config.ts (1)

10-14: Add src glob to Tailwind content config to prevent dev-time style drift from stale dist.

Studio's dev flow (rsbuild dev) doesn't orchestrate luna-stage-preview builds, so dist can lag during iteration. Scanning src as a fallback ensures class extraction stays current without requiring manual rebuilds.

♻️ Suggested update
   content: [
     './src/**/*.{html,js,ts,jsx,tsx,mdx}',
+    '../../packages/luna-stage-preview/src/**/*.{js,ts,jsx,tsx,mdx}',
     // Scan compiled output of luna-stage-preview for Tailwind class names
     '../../packages/luna-stage-preview/dist/**/*.js',
   ],
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@apps/studio/tailwind.config.ts` around lines 10 - 14, The Tailwind content
array in tailwind.config.ts currently scans
'./src/**/*.{html,js,ts,jsx,tsx,mdx}' and the compiled
'../../packages/luna-stage-preview/dist/**/*.js', but you need to add a fallback
that scans the luna-stage-preview source to avoid dev-time style drift; update
the content array to include the luna-stage-preview source glob (e.g.,
'../../packages/luna-stage-preview/src/**/*.{html,js,ts,jsx,tsx,mdx}') so
Tailwind extracts class names from the package's src when dist is stale.
packages/luna-stage-preview/src/components/lynx-stage/luna-lynx-stage.tsx (1)

69-86: Consider adding a return value for unhandled bridge calls.

The onNativeModulesCall handler returns values for setFocusedComponent and setMoonriseState, but falls through without a return for other cases. If callers expect a response, this could cause issues.

♻️ Optional: Add explicit return for unhandled cases
     ref.current!.onNativeModulesCall = (
       name,
       data,
       moduleName,
     ) => {
       if (moduleName === 'bridge') {
         if (name === 'setFocusedComponent') {
           const component: string = (data as { id: string }).id;
           onFocusedChange?.(component);
           return { entry, focusedComponent: component };
         } else if (name === 'setMoonriseState') {
           onMoonriseChange?.(data as MoonriseEvent);
           return { entry, moonriseEvent: data as MoonriseEvent };
         }
       }
+      return undefined;
     };
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/luna-stage-preview/src/components/lynx-stage/luna-lynx-stage.tsx`
around lines 69 - 86, The onNativeModulesCall handler assigned to ref.current
(the onNativeModulesCall function) only returns for 'setFocusedComponent' and
'setMoonriseState' and leaves other bridge calls with no explicit return; update
the handler to always return a defined value for unhandled cases (e.g., null or
a standardized { entry } response) at the end of the function so callers receive
a predictable response when moduleName === 'bridge' but name is not one of the
handled values; ensure the change occurs inside the useEffect where
ref.current!.onNativeModulesCall is set.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@packages/luna-stage-preview/package.json`:
- Line 45: Remove the unused dependency "@headlessui/tailwindcss" from this
package's package.json by deleting its entry from the dependencies section;
ensure you do not move it to devDependencies, run a quick grep across the
package source/build configs to confirm there are no remaining imports or
references to "@headlessui/tailwindcss", then run the package manager's install
to update the lockfile (or regenerate it) so the removal is reflected in the
lockfile.

In `@packages/luna-stage-preview/src/components/choreography/choreography.tsx`:
- Around line 14-27: The prop type declares viewMode as required
(StudioViewMode) but the Choreography component provides a default, so make the
prop optional to match the default: update the component props/type so viewMode
is viewMode?: StudioViewMode (instead of required), leaving the destructured
default in the Choreography function ({ viewMode = 'compare', ... }) intact;
modify any related usages or consumers if they relied on non-optional typing
(e.g., places importing the props type) to accept the optional prop.

---

Nitpick comments:
In `@apps/studio/tailwind.config.ts`:
- Around line 10-14: The Tailwind content array in tailwind.config.ts currently
scans './src/**/*.{html,js,ts,jsx,tsx,mdx}' and the compiled
'../../packages/luna-stage-preview/dist/**/*.js', but you need to add a fallback
that scans the luna-stage-preview source to avoid dev-time style drift; update
the content array to include the luna-stage-preview source glob (e.g.,
'../../packages/luna-stage-preview/src/**/*.{html,js,ts,jsx,tsx,mdx}') so
Tailwind extracts class names from the package's src when dist is stale.

In `@packages/luna-stage-preview/src/components/lynx-stage/luna-lynx-stage.tsx`:
- Around line 69-86: The onNativeModulesCall handler assigned to ref.current
(the onNativeModulesCall function) only returns for 'setFocusedComponent' and
'setMoonriseState' and leaves other bridge calls with no explicit return; update
the handler to always return a defined value for unhandled cases (e.g., null or
a standardized { entry } response) at the end of the function so callers receive
a predictable response when moduleName === 'bridge' but name is not one of the
handled values; ensure the change occurs inside the useEffect where
ref.current!.onNativeModulesCall is set.

In `@packages/luna-stage-preview/src/components/studio-frame/studio-frame.tsx`:
- Around line 10-16: The StudioFrame component's root element always applies the
CSS class "pointer-events-none", which prevents any interactive handlers
forwarded via restProps from firing; update the StudioFrameProps type and usage
to either (A) document this behavior by adding a clear comment to
StudioFrameProps indicating the component is non-interactive and that event
handlers passed via restProps will be ignored, or (B) change the forwarding
logic to exclude interactive props (like onClick, onMouseDown, onKeyDown,
tabIndex, role) from restProps so callers aren't misled—locate the
StudioFrameProps definition and the root element where the "pointer-events-none"
class and restProps are applied to implement one of these fixes.
🪄 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: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 663dc772-f880-41dc-8db0-4c77bd66a0ff

📥 Commits

Reviewing files that changed from the base of the PR and between 4e65eb3 and fbfb54d.

⛔ Files ignored due to path filters (1)
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (65)
  • .cspell/misc.txt
  • apps/studio/package.json
  • apps/studio/src/App.tsx
  • apps/studio/src/components/choreography/archive/choreography-simple.tsx
  • apps/studio/src/components/choreography/archive/compare-view.tsx
  • apps/studio/src/components/choreography/archive/focus-view-test.tsx
  • apps/studio/src/components/choreography/archive/focus-view.tsx
  • apps/studio/src/components/choreography/choreography.tsx
  • apps/studio/src/components/lynx-stage/lynx-stage.tsx
  • apps/studio/src/components/mockup-motion/context/index.ts
  • apps/studio/src/components/mockup-motion/context/use-visual-size.ts
  • apps/studio/src/components/mockup-motion/index.ts
  • apps/studio/src/components/studio-frame/index.ts
  • apps/studio/src/components/studio-frame/studio-frame.tsx
  • apps/studio/src/components/studio/index.ts
  • apps/studio/src/components/studio/static.tsx
  • apps/studio/src/components/studio/studio.tsx
  • apps/studio/src/types/index.ts
  • apps/studio/tailwind.config.ts
  • apps/studio/tsconfig.json
  • packages/luna-stage-preview/package.json
  • packages/luna-stage-preview/rslib.config.ts
  • packages/luna-stage-preview/src/components/choreography/choreography.tsx
  • packages/luna-stage-preview/src/components/choreography/dynamic-view.tsx
  • packages/luna-stage-preview/src/components/choreography/index.ts
  • packages/luna-stage-preview/src/components/choreography/types.ts
  • packages/luna-stage-preview/src/components/choreography/utils.ts
  • packages/luna-stage-preview/src/components/container/container.tsx
  • packages/luna-stage-preview/src/components/container/index.ts
  • packages/luna-stage-preview/src/components/context/create-context.tsx
  • packages/luna-stage-preview/src/components/context/index.ts
  • packages/luna-stage-preview/src/components/lynx-stage/index.ts
  • packages/luna-stage-preview/src/components/lynx-stage/luna-lynx-stage.tsx
  • packages/luna-stage-preview/src/components/lynx-stage/lynx-stage.tsx
  • packages/luna-stage-preview/src/components/menu-bar/index.ts
  • packages/luna-stage-preview/src/components/menu-bar/menu-bar.tsx
  • packages/luna-stage-preview/src/components/mockup-motion/container-motion.tsx
  • packages/luna-stage-preview/src/components/mockup-motion/context/index.ts
  • packages/luna-stage-preview/src/components/mockup-motion/context/use-visual-size.ts
  • packages/luna-stage-preview/src/components/mockup-motion/context/visual-size-context.tsx
  • packages/luna-stage-preview/src/components/mockup-motion/context/visual-size-provider.tsx
  • packages/luna-stage-preview/src/components/mockup-motion/index.ts
  • packages/luna-stage-preview/src/components/mockup-motion/mockup-motion.tsx
  • packages/luna-stage-preview/src/components/mockup-motion/presentation-motion.tsx
  • packages/luna-stage-preview/src/components/mockup-motion/transform-utils.ts
  • packages/luna-stage-preview/src/components/mockup-motion/use-container-resize.ts
  • packages/luna-stage-preview/src/components/mockup/index.ts
  • packages/luna-stage-preview/src/components/mockup/mockup.tsx
  • packages/luna-stage-preview/src/components/studio-frame/index.ts
  • packages/luna-stage-preview/src/components/studio-frame/studio-frame.tsx
  • packages/luna-stage-preview/src/components/studio/index.ts
  • packages/luna-stage-preview/src/components/studio/studio.tsx
  • packages/luna-stage-preview/src/data/default-stages.ts
  • packages/luna-stage-preview/src/hooks/use-container-resize.ts
  • packages/luna-stage-preview/src/hooks/use-effect-event.ts
  • packages/luna-stage-preview/src/hooks/use-isomorphic-layout-effect.ts
  • packages/luna-stage-preview/src/hooks/use-merged-refs.ts
  • packages/luna-stage-preview/src/hooks/use-raf-clock.ts
  • packages/luna-stage-preview/src/index.ts
  • packages/luna-stage-preview/src/types/global.d.ts
  • packages/luna-stage-preview/src/types/stage.ts
  • packages/luna-stage-preview/src/utils/index.ts
  • packages/luna-stage-preview/tsconfig.build.json
  • packages/luna-stage-preview/tsconfig.json
  • tsconfig.json
💤 Files with no reviewable changes (15)
  • packages/luna-stage-preview/src/utils/index.ts
  • apps/studio/src/components/studio/index.ts
  • apps/studio/src/components/mockup-motion/context/index.ts
  • apps/studio/src/components/mockup-motion/index.ts
  • apps/studio/src/components/studio-frame/index.ts
  • apps/studio/src/components/mockup-motion/context/use-visual-size.ts
  • apps/studio/src/components/lynx-stage/lynx-stage.tsx
  • apps/studio/src/components/choreography/archive/choreography-simple.tsx
  • apps/studio/src/components/studio/static.tsx
  • apps/studio/src/components/studio-frame/studio-frame.tsx
  • apps/studio/src/components/choreography/archive/focus-view-test.tsx
  • apps/studio/src/components/choreography/archive/compare-view.tsx
  • apps/studio/src/components/choreography/choreography.tsx
  • apps/studio/src/components/choreography/archive/focus-view.tsx
  • apps/studio/src/components/studio/studio.tsx

"@dugyu/luna-catalog": "workspace:*",
"@dugyu/luna-core": "workspace:*",
"@headlessui/react": "^2.2.7",
"@headlessui/tailwindcss": "^0.2.2",
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Verify whether `@headlessui/tailwindcss` is runtime-imported or build-tool-only.

set -euo pipefail

echo "== Runtime/source imports =="
rg -nP --iglob 'packages/luna-stage-preview/src/**/*.{ts,tsx,js,jsx,mjs,cjs}' \
  "from\\s+['\"]@headlessui/tailwindcss['\"]|require\\(['\"]@headlessui/tailwindcss['\"]\\)" || true

echo "== Build/config imports =="
rg -nP --iglob 'packages/luna-stage-preview/**/*.{ts,tsx,js,jsx,mjs,cjs}' \
  "@headlessui/tailwindcss" || true

Repository: Dugyu/lunarium

Length of output: 113


🏁 Script executed:

#!/bin/bash
# Search for tailwind config files in the package
find packages/luna-stage-preview -name "*tailwind*" -type f 2>/dev/null | head -20

# Search more broadly for any reference to the package across all file types
rg "@headlessui/tailwindcss" packages/luna-stage-preview/ -n --max-count 20

# Check package.json structure
echo "=== Package.json context ==="
cat packages/luna-stage-preview/package.json | grep -A 20 '"dependencies"' | head -30

Repository: Dugyu/lunarium

Length of output: 866


🏁 Script executed:

#!/bin/bash
# Check if upstream workspace packages import `@headlessui/tailwindcss`
echo "=== Checking `@dugyu/luna-core` ==="
rg "@headlessui/tailwindcss" packages/luna-core/ -n 2>/dev/null | head -5 || echo "No matches found"

echo "=== Checking `@dugyu/luna-catalog` ==="
rg "@headlessui/tailwindcss" packages/luna-catalog/ -n 2>/dev/null | head -5 || echo "No matches found"

# Also check if it's listed in their dependencies
echo "=== luna-core package.json ==="
test -f packages/luna-core/package.json && grep -A 15 '"dependencies"' packages/luna-core/package.json | grep -E '(`@headlessui`|dependencies)' || echo "N/A"

echo "=== luna-catalog package.json ==="
test -f packages/luna-catalog/package.json && grep -A 15 '"dependencies"' packages/luna-catalog/package.json | grep -E '(`@headlessui`|dependencies)' || echo "N/A"

Repository: Dugyu/lunarium

Length of output: 201


Remove @headlessui/tailwindcss from dependencies—it's not used anywhere in this package.

No imports of this package were found in the source code, build configs, or upstream workspace dependencies. If it was previously used and is no longer needed, it should be removed entirely rather than moved to devDependencies.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/luna-stage-preview/package.json` at line 45, Remove the unused
dependency "@headlessui/tailwindcss" from this package's package.json by
deleting its entry from the dependencies section; ensure you do not move it to
devDependencies, run a quick grep across the package source/build configs to
confirm there are no remaining imports or references to
"@headlessui/tailwindcss", then run the package manager's install to update the
lockfile (or regenerate it) so the removal is reflected in the lockfile.

Comment on lines +14 to +27
viewMode: StudioViewMode;
className?: string;
onThemeModeChange?: (mode: 'light' | 'dark') => void;
/** Override default stage configurations. */
stages?: Record<string, StageMeta>;
/** Override default layout configs per view mode. */
layouts?: Record<StudioViewMode, ViewSpec[]>;
/** Base URL for Lynx bundle files. @default '/' */
bundleBaseUrl?: string;
};

function Choreography(
{
viewMode = 'compare',
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

viewMode default and prop type are inconsistent.

viewMode is typed as required, but the function defines a default. Make it optional so callers can actually rely on the default.

Proposed fix
 type ChoreographyProps = {
-  viewMode: StudioViewMode;
+  viewMode?: StudioViewMode;
   className?: string;
   onThemeModeChange?: (mode: 'light' | 'dark') => void;
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
viewMode: StudioViewMode;
className?: string;
onThemeModeChange?: (mode: 'light' | 'dark') => void;
/** Override default stage configurations. */
stages?: Record<string, StageMeta>;
/** Override default layout configs per view mode. */
layouts?: Record<StudioViewMode, ViewSpec[]>;
/** Base URL for Lynx bundle files. @default '/' */
bundleBaseUrl?: string;
};
function Choreography(
{
viewMode = 'compare',
viewMode?: StudioViewMode;
className?: string;
onThemeModeChange?: (mode: 'light' | 'dark') => void;
/** Override default stage configurations. */
stages?: Record<string, StageMeta>;
/** Override default layout configs per view mode. */
layouts?: Record<StudioViewMode, ViewSpec[]>;
/** Base URL for Lynx bundle files. `@default` '/' */
bundleBaseUrl?: string;
};
function Choreography(
{
viewMode = 'compare',
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/luna-stage-preview/src/components/choreography/choreography.tsx`
around lines 14 - 27, The prop type declares viewMode as required
(StudioViewMode) but the Choreography component provides a default, so make the
prop optional to match the default: update the component props/type so viewMode
is viewMode?: StudioViewMode (instead of required), leaving the destructured
default in the Choreography function ({ viewMode = 'compare', ... }) intact;
modify any related usages or consumers if they relied on non-optional typing
(e.g., places importing the props type) to accept the optional prop.

@Dugyu Dugyu changed the title feat(packages): introduce @dugyu/luna-stage-preview feat(packages): introduce luna-stage-preview Apr 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant