diff --git a/e2e/lifecycle-snapshot-export.test.ts b/e2e/lifecycle-snapshot-export.test.ts index 48f9557a0..151d372a7 100644 --- a/e2e/lifecycle-snapshot-export.test.ts +++ b/e2e/lifecycle-snapshot-export.test.ts @@ -135,7 +135,11 @@ test('per-row Export writes a valid envelope JSON to disk @windows @macos @linux const firstFilename = filenames[0]! await popup.waitForSelector('.snapshot-row.is-expanded', { timeout: 5_000 }) - await popup.waitForSelector(byTestId(TID.snapshotRowExport(firstFilename)), { timeout: 5_000 }) + await popup.clickUntilVisible( + byTestId(TID.snapshotRowMore(firstFilename)), + byTestId(TID.snapshotRowExport(firstFilename)), + { timeout: 5_000 } + ) expect(await popup.click(byTestId(TID.snapshotRowExport(firstFilename)))).toBe(true) diff --git a/e2e/lifecycle-snapshot-restore.test.ts b/e2e/lifecycle-snapshot-restore.test.ts index ef99d9781..7b923538c 100644 --- a/e2e/lifecycle-snapshot-restore.test.ts +++ b/e2e/lifecycle-snapshot-restore.test.ts @@ -320,13 +320,12 @@ test('picker-driven restore surfaces inline op-card + auto-dismisses on success .toBe(true) await expect - .poll(async () => popup.evaluate(`!!document.querySelector('.snapshots-rail-cta')`), { - timeout: 8_000, - intervals: [200, 400] - }) + .poll( + async () => + popup.evaluate( + `!document.querySelector('${byTestId(TID.snapshotsOpCard)}') && document.querySelector('${byTestId(TID.snapshotsSaveCta)}')?.disabled === false` + ), + { timeout: 8_000, intervals: [200, 400] } + ) .toBe(true) - - expect( - await popup.evaluate(`!!document.querySelector('${byTestId(TID.snapshotsOpCard)}')`) - ).toBe(false) }) diff --git a/locales/en.json b/locales/en.json index 08133508e..896dbac76 100644 --- a/locales/en.json +++ b/locales/en.json @@ -1167,8 +1167,6 @@ "snapshots": { "empty": "No snapshots yet. Snapshots are captured automatically when ComfyUI starts.", "createSnapshot": "Create Snapshot", - "createNew": "Create Snapshot", - "createLabel": "Create Snapshot", "changesInSnapshot": "What changed in this snapshot", "ifYouRestore": "What restoring this would change", "noSnapshotsToShare": "There are no snapshots to share yet.", @@ -1261,6 +1259,7 @@ "importPreviewLabel": "Snapshots", "importedSnapshot": "Imported snapshot", "latestBadge": "Latest", + "moreActions": "More actions", "latestLabel": "Latest:", "noneYet": "No snapshots yet", "restoreCancelled": "Restore cancelled", diff --git a/locales/zh.json b/locales/zh.json index 941523c9c..ac9e96a8c 100644 --- a/locales/zh.json +++ b/locales/zh.json @@ -1167,8 +1167,6 @@ "snapshots": { "empty": "还没有快照。ComfyUI 启动时会自动捕获快照。", "createSnapshot": "创建快照", - "createNew": "创建快照", - "createLabel": "创建快照", "changesInSnapshot": "此快照中发生的更改", "ifYouRestore": "恢复此快照将改变的内容", "noSnapshotsToShare": "还没有可分享的快照。", @@ -1261,6 +1259,7 @@ "importPreviewLabel": "快照", "importedSnapshot": "导入的快照", "latestBadge": "最新", + "moreActions": "更多操作", "latestLabel": "最新:", "noneYet": "还没有快照", "restoreCancelled": "恢复已取消", diff --git a/src/renderer/src/assets/design-system-theme.css b/src/renderer/src/assets/design-system-theme.css index 42e4cf75e..2b9d6bb22 100644 --- a/src/renderer/src/assets/design-system-theme.css +++ b/src/renderer/src/assets/design-system-theme.css @@ -27,8 +27,6 @@ --color-subtle-foreground: oklch(0.6 0 0); --color-border-strong: oklch(1 0 0 / 0.14); --color-media-overlay: oklch(0 0 0 / 0.55); - --color-snapshot-chip: #202020; - --color-snapshot-ring: #262729; --text-ui: 13px; --text-ui--line-height: 20px; diff --git a/src/renderer/src/views/comfyUISettings/SnapshotRow.vue b/src/renderer/src/views/comfyUISettings/SnapshotRow.vue index 48dfca51d..45b0181c5 100644 --- a/src/renderer/src/views/comfyUISettings/SnapshotRow.vue +++ b/src/renderer/src/views/comfyUISettings/SnapshotRow.vue @@ -2,7 +2,7 @@ import { computed } from 'vue' import { useI18n } from 'vue-i18n' import Button from '@comfyorg/design-system/button/Button' -import { ChevronDown, Tag, Boxes, Package } from 'lucide-vue-next' +import { ChevronRight } from 'lucide-vue-next' import type { SnapshotSummary } from '../../types/ipc' import { triggerLabel as _triggerLabel, @@ -81,124 +81,107 @@ const titlePillText = computed(() => { return props.snapshot.comfyuiVersion }) const hasTitlePill = computed(() => !!titlePillText.value) +const showVersionChange = computed(() => !hasCustomLabel.value && comfyuiChanged.value) diff --git a/src/shared/testIds.ts b/src/shared/testIds.ts index 11617a7ba..912834236 100644 --- a/src/shared/testIds.ts +++ b/src/shared/testIds.ts @@ -37,6 +37,8 @@ export const TID = { snapshotRow: (filename: string) => `snapshot-row-${filename}`, snapshotRowRestore: (filename: string) => `snapshot-row-restore-${filename}`, snapshotRowExport: (filename: string) => `snapshot-row-export-${filename}`, + snapshotRowMore: (filename: string) => `snapshot-row-more-${filename}`, + snapshotRowDelete: (filename: string) => `snapshot-row-delete-${filename}`, snapshotsImport: 'snapshots-import', snapshotsExportAll: 'snapshots-export-all', snapshotsOpCard: 'snapshots-op-card',