Skip to content

Feat/batch image group canvas insertion#195

Closed
AiW520 wants to merge 3 commits into
ljquan:developfrom
AiW520:feat/batch-image-group-canvas-insertion
Closed

Feat/batch image group canvas insertion#195
AiW520 wants to merge 3 commits into
ljquan:developfrom
AiW520:feat/batch-image-group-canvas-insertion

Conversation

@AiW520

@AiW520 AiW520 commented Jun 20, 2026

Copy link
Copy Markdown

背景

批量出图工具生成的图片插入画布后随机分布,用户无法直观区分不同批次提交的图片。本次改动让同一次提交产出的图片在画布上自动分组网格排列,不同批次之间有明显分隔。

改动内容

1. 传递分组键 (batch-image-generation.tsx)

executeSubmit 中为每个任务添加 batchGroupId 参数,值为 batch-submit-${globalBatchTimestamp}。同一批次提交的所有任务共享相同的时间戳。

2. 识别分组键 (image-generation-anchor-task.ts)

getImageGenerationTaskInsertGroupKey 中新增 batchGroupId 判断,优先按批次分组。

3. 画布排列

复用已有的 precalculateGroupedGridLayout 逻辑:

  • 同组图片水平网格排列,超出画布宽度自动换行
  • 不同组之间垂直分隔(默认 50px 间距)

4. 用户提示

在"生成选中行"按钮上添加 HoverTip,悬停时显示分组说明。

影响范围

  • 仅影响批量出图工具,其他功能(AI 对话出图、PPT 出图、单张出图等)完全不受影响
  • 所有现有测试用例通过,无回归

涉及文件

文件 改动
packages/drawnix/src/components/ttd-dialog/batch-image-generation.tsx 任务参数新增 batchGroupId;生成按钮添加 HoverTip
packages/drawnix/src/utils/image-generation-anchor-task.ts 新增 batchGroupId 分组判断
docs/BATCH_IMAGE_GROUP_CANVAS_INSERTION_LESSONS.md 新增功能总结文档

李泓震 added 3 commits June 19, 2026 17:10
同一批次提交的图片在画布上自动分组网格排列,不同批次间垂直分隔。通过 batchGroupId 参数传递分组键,仅影响批量出图工具,不影响其他功能。
在'生成选中行'按钮上添加 HoverTip,悬停时显示同批次图片将在画布上自动分组排列的说明
@vercel

vercel Bot commented Jun 20, 2026

Copy link
Copy Markdown

Someone is attempting to deploy a commit to the ljquan's projects Team on Vercel.

A member of the Team first needs to authorize it.

@netlify

netlify Bot commented Jun 20, 2026

Copy link
Copy Markdown

Deploy Preview for ai-tu ready!

Name Link
🔨 Latest commit c50fbf5
🔍 Latest deploy log https://app.netlify.com/projects/ai-tu/deploys/6a35eb6caee88f0008a2028b
😎 Deploy Preview https://deploy-preview-195--ai-tu.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 67
Accessibility: 80
Best Practices: 83
SEO: 90
PWA: 100
View the detailed breakdown and full score reports

To edit notification comments on pull requests, go to your Netlify project configuration.

@AiW520 AiW520 closed this Jun 20, 2026
@AiW520
AiW520 deleted the feat/batch-image-group-canvas-insertion branch June 20, 2026 02:12
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