fix(settings): use Save as the primary label on settings form dialogs (#1571)

This commit is contained in:
WuFeng authored and GitHub committed 2026-10-08 16:31:16 +08:00
1 parent 224b488087
commit ba84a04a43
3 files changed
+4 -4

No files matched your search

@@ -201,7 +201,7 @@ Future<DownloadCategoryDraft?> showDownloadCategoryDialog(
onPressed: () => shad.closeOverlay(dialogContext), onPressed: () => shad.closeOverlay(dialogContext),
child: Text(dialogContext.l10n.cancel), child: Text(dialogContext.l10n.cancel),
), ),
AppPrimaryButton(onPressed: submit, child: Text(dialogContext.l10n.confirm)), AppPrimaryButton(onPressed: submit, child: Text(dialogContext.l10n.save)),
], ],
); );
}, },
@@ -234,7 +234,7 @@ Future<String?> showTextSettingDialog(
} }
shad.closeOverlay(dialogContext, controller.text.trim()); shad.closeOverlay(dialogContext, controller.text.trim());
}, },
child: Text(dialogContext.l10n.confirm), child: Text(dialogContext.l10n.save),
), ),
], ],
); );
@@ -321,7 +321,7 @@ Future<GithubMirrorDraft?> showGithubMirrorDialog(BuildContext context, {GithubM
} }
shad.closeOverlay(dialogContext, GithubMirrorDraft(type: selectedType, url: value)); shad.closeOverlay(dialogContext, GithubMirrorDraft(type: selectedType, url: value));
}, },
child: Text(dialogContext.l10n.confirm), child: Text(dialogContext.l10n.save),
), ),
], ],
); );
+1 -1
View File
@@ -2480,7 +2480,7 @@ void main() {
expect(find.text('%date% — Full date (YYYY-MM-DD)'), findsOneWidget); expect(find.text('%date% — Full date (YYYY-MM-DD)'), findsOneWidget);
await tester.tap(find.byKey(const ValueKey('path-placeholder-%date%'))); await tester.tap(find.byKey(const ValueKey('path-placeholder-%date%')));
await tester.pumpAndSettle(); await tester.pumpAndSettle();
await tester.tap(find.text('Confirm')); await tester.tap(find.text('Save'));
await tester.pumpAndSettle(); await tester.pumpAndSettle();
expect(find.text('归档'), findsOneWidget); expect(find.text('归档'), findsOneWidget);