diff --git a/src/components/md-deck/PltPreview.tsx b/src/components/md-deck/PltPreview.tsx index 34dd0a6..902d261 100644 --- a/src/components/md-deck/PltPreview.tsx +++ b/src/components/md-deck/PltPreview.tsx @@ -1,4 +1,5 @@ import { createSignal, For, Show, createMemo } from 'solid-js'; +import { Portal } from 'solid-js/web'; import { parsePlt, extractCutPaths } from '../../plotcutter/parser'; import { generateTravelPaths, travelPathsToSvg } from '../../plotcutter/layout'; import type { CardPath } from '../../plotcutter/types'; @@ -91,10 +92,11 @@ export function PltPreview(props: PltPreviewProps) { }; return ( -
-
- {/* 头部控制栏 */} -
+ +
+
+ {/* 头部控制栏 */} +

PLT 切割预览

0}> @@ -224,5 +226,6 @@ export function PltPreview(props: PltPreviewProps) {
+ ); } diff --git a/src/components/md-deck/PrintPreview.tsx b/src/components/md-deck/PrintPreview.tsx index 3a36fcb..5e8afcc 100644 --- a/src/components/md-deck/PrintPreview.tsx +++ b/src/components/md-deck/PrintPreview.tsx @@ -1,4 +1,5 @@ import { createSignal, For, Show } from 'solid-js'; +import { Portal } from 'solid-js/web'; import type { DeckStore } from './hooks/deckStore'; import { usePageLayout } from './hooks/usePageLayout'; import { usePDFExport, type ExportOptions } from './hooks/usePDFExport'; @@ -60,21 +61,22 @@ export function PrintPreview(props: PrintPreviewProps) { }; return ( - }> -
-
- + + }> +
+
+ - + -
- +
+ {(page) => { // 根据页面类型(正面/背面)决定使用哪个图层配置 const isFrontPage = page.cards[0]?.side !== 'back'; @@ -197,5 +199,6 @@ export function PrintPreview(props: PrintPreviewProps) {
+ ); }