@idealyst/mcp-server 1.2.117 → 1.2.119
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/dist/{chunk-TLA6ZBC5.js → chunk-UD56HXN3.js} +626 -55
- package/dist/chunk-UD56HXN3.js.map +1 -0
- package/dist/index.cjs +632 -55
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +12 -2
- package/dist/index.js.map +1 -1
- package/dist/tools/index.cjs +629 -54
- package/dist/tools/index.cjs.map +1 -1
- package/dist/tools/index.d.cts +16 -3
- package/dist/tools/index.d.ts +16 -3
- package/dist/tools/index.js +9 -1
- package/package.json +5 -5
- package/dist/chunk-TLA6ZBC5.js.map +0 -1
package/dist/index.js
CHANGED
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
storageGuides,
|
|
8
8
|
toolDefinitions,
|
|
9
9
|
translateGuides
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-UD56HXN3.js";
|
|
11
11
|
|
|
12
12
|
// src/index.ts
|
|
13
13
|
import { Server } from "@modelcontextprotocol/sdk/server/index.js";
|
|
@@ -2676,10 +2676,13 @@ Layout components are **web-only**. Native ignores \`layoutComponent\` entirely.
|
|
|
2676
2676
|
layouts/
|
|
2677
2677
|
AppLayout.web.tsx \u2190 Real layout with Outlet from @idealyst/navigation
|
|
2678
2678
|
AppLayout.native.tsx \u2190 No-op mock (return null)
|
|
2679
|
+
index.ts \u2190 REQUIRED: base export for TypeScript resolution
|
|
2679
2680
|
index.web.ts \u2190 export { AppLayout } from './AppLayout.web'
|
|
2680
2681
|
index.native.ts \u2190 export { AppLayout } from './AppLayout.native'
|
|
2681
2682
|
\`\`\`
|
|
2682
2683
|
|
|
2684
|
+
> **CRITICAL:** You MUST create a base \`index.ts\` alongside \`index.web.ts\` and \`index.native.ts\`. Without it, TypeScript cannot resolve \`import { AppLayout } from './layouts'\` and you get TS2307. The base \`index.ts\` re-exports from the web version (bundlers pick the platform-specific file at runtime).
|
|
2685
|
+
|
|
2683
2686
|
### Example Files
|
|
2684
2687
|
|
|
2685
2688
|
**\`AppLayout.web.tsx\`** \u2014 The real layout:
|
|
@@ -2717,6 +2720,11 @@ export function AppLayout() {
|
|
|
2717
2720
|
}
|
|
2718
2721
|
\`\`\`
|
|
2719
2722
|
|
|
2723
|
+
**\`index.ts\`** \u2014 Base export (REQUIRED for TypeScript module resolution):
|
|
2724
|
+
\`\`\`ts
|
|
2725
|
+
export { AppLayout } from './AppLayout.web';
|
|
2726
|
+
\`\`\`
|
|
2727
|
+
|
|
2720
2728
|
**\`index.web.ts\`**:
|
|
2721
2729
|
\`\`\`ts
|
|
2722
2730
|
export { AppLayout } from './AppLayout.web';
|
|
@@ -2747,7 +2755,9 @@ const appRouter: NavigatorParam = {
|
|
|
2747
2755
|
> **Key rules:**
|
|
2748
2756
|
> - Import \`Outlet\` from \`@idealyst/navigation\` (NOT from \`react-router-dom\`)
|
|
2749
2757
|
> - Layout props do NOT include \`children\` \u2014 content renders via \`<Outlet />\`
|
|
2750
|
-
> - Always create
|
|
2758
|
+
> - Always create \`.web.tsx\`, \`.native.tsx\`, AND a base \`index.ts\` \u2014 without the base \`index.ts\`, TypeScript reports TS2307 (cannot find module)
|
|
2759
|
+
> - The base \`index.ts\` re-exports from the \`.web\` version; bundlers pick the right platform file at runtime
|
|
2760
|
+
> - **Web-only CSS** in \`.web.tsx\`: cast with \`as any\`, NOT \`as React.CSSProperties\` \u2014 \`CSSProperties\` is incompatible with \`StyleProp<ViewStyle>\` (TS2322). Example: \`style={{ position: 'fixed', transition: 'width 0.2s' } as any}\`
|
|
2751
2761
|
|
|
2752
2762
|
## GeneralLayout Component
|
|
2753
2763
|
|