Skip to content

feat: Add pull image option for container management#1149

Merged
GT-610 merged 3 commits into
mainfrom
feat/image-pull-menu
May 2, 2026
Merged

feat: Add pull image option for container management#1149
GT-610 merged 3 commits into
mainfrom
feat/image-pull-menu

Conversation

@GT-610
Copy link
Copy Markdown
Collaborator

@GT-610 GT-610 commented May 2, 2026

Resolve #1145.

Summary by CodeRabbit

  • New Features

    • Image context menu added with Pull and Remove actions; Pull prompts for confirmation and shows operation progress and error reporting.
  • Internationalization

    • Added "pull" translations across 15 locales (en, de, es, fr, id, it, ja, ko, nl, pt, ru, tr, uk, zh, zh_TW).

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 2, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 2339e807-20a3-44ba-acd0-6706a0bb3cca

📥 Commits

Reviewing files that changed from the base of the PR and between 4509f25 and 672ce32.

📒 Files selected for processing (1)
  • lib/view/page/container/actions.dart

📝 Walkthrough

Walkthrough

Adds an ImageMenu enum (pull, rm) with items, an icon getter, and a localized toStr getter. Adds a pull localization key to multiple ARB files. Replaces the image-list delete button with a PopupMenu<ImageMenu> and introduces _onTapImageMenu which either runs a pull flow (repo/tag check, confirmation, run, then show error dialog on failure) or delegates to the existing image removal dialog.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main change: adding a pull image option for container management, which is the primary objective of the PR.
Linked Issues check ✅ Passed The PR implementation fully addresses issue #1145 by adding a UI option to pull (update) container images alongside the existing delete functionality.
Out of Scope Changes check ✅ Passed All changes are directly related to implementing the pull image feature: new ImageMenu enum, localization strings, UI handler, and popup menu integration are all in scope.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/image-pull-menu

Review rate limit: 3/5 reviews remaining, refill in 23 minutes and 49 seconds.

Comment @coderabbitai help to get the list of available commands and usage tips.

@GT-610 GT-610 requested a review from lollipopkit May 2, 2026 00:18
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@lib/l10n/app_ko.arb`:
- Line 111: The new ARB key "pull" was added but generated localization sources
are not present; run the Flutter localization generator and commit the outputs:
execute `flutter gen-l10n` (or your project's configured gen-l10n command) to
regenerate lib/l10n/app_localizations.dart and any language-specific generated
files so the l10n.pull key is available, then add and commit those generated
files to the repo.

In `@lib/view/page/container/actions.dart`:
- Around line 145-152: Replace the two hardcoded English strings in the image
action flow with localized keys: change the context.showSnackBar('Repository is
null') call to use a libL10n key (e.g., libL10n.repositoryIsNull) and change the
dialog Text(l10n.askContinue('${l10n.pull} Image($imageRef)')) to build the
inner text from l10n/libL10n keys (e.g., use libL10n.pull and a new
libL10n.askContinueWithImage(imageRef) or compose libL10n.askContinue with
libL10n.imageLabel(imageRef)), update the corresponding l10n entries in the
localization resources, and ensure you reference libL10n for shared strings to
follow the project guideline.
- Around line 141-164: The ImageMenu.pull case in _onTapImageMenu falls through
because it lacks an explicit terminator; update the switch so each non-empty
case ends with a terminator (e.g., add break; or return;) — specifically, after
the context.showRoundDialog(...) block for the ImageMenu.pull case add a break;
(or return) to prevent fall-through into ImageMenu.rm, and verify other cases
like the call to _showImageRmDialog(e) are similarly terminated as needed.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 3526d578-6806-467e-896e-975864b15ea7

📥 Commits

Reviewing files that changed from the base of the PR and between edf9924 and 7c78bfb.

⛔ Files ignored due to path filters (16)
  • lib/generated/l10n/l10n.dart is excluded by !**/generated/**
  • lib/generated/l10n/l10n_de.dart is excluded by !**/generated/**
  • lib/generated/l10n/l10n_en.dart is excluded by !**/generated/**
  • lib/generated/l10n/l10n_es.dart is excluded by !**/generated/**
  • lib/generated/l10n/l10n_fr.dart is excluded by !**/generated/**
  • lib/generated/l10n/l10n_id.dart is excluded by !**/generated/**
  • lib/generated/l10n/l10n_it.dart is excluded by !**/generated/**
  • lib/generated/l10n/l10n_ja.dart is excluded by !**/generated/**
  • lib/generated/l10n/l10n_ko.dart is excluded by !**/generated/**
  • lib/generated/l10n/l10n_nl.dart is excluded by !**/generated/**
  • lib/generated/l10n/l10n_pt.dart is excluded by !**/generated/**
  • lib/generated/l10n/l10n_ru.dart is excluded by !**/generated/**
  • lib/generated/l10n/l10n_tr.dart is excluded by !**/generated/**
  • lib/generated/l10n/l10n_uk.dart is excluded by !**/generated/**
  • lib/generated/l10n/l10n_zh.dart is excluded by !**/generated/**
  • pubspec.lock is excluded by !**/*.lock
📒 Files selected for processing (18)
  • lib/data/model/app/menu/image.dart
  • lib/l10n/app_de.arb
  • lib/l10n/app_en.arb
  • lib/l10n/app_es.arb
  • lib/l10n/app_fr.arb
  • lib/l10n/app_id.arb
  • lib/l10n/app_it.arb
  • lib/l10n/app_ja.arb
  • lib/l10n/app_ko.arb
  • lib/l10n/app_nl.arb
  • lib/l10n/app_pt.arb
  • lib/l10n/app_ru.arb
  • lib/l10n/app_tr.arb
  • lib/l10n/app_uk.arb
  • lib/l10n/app_zh.arb
  • lib/l10n/app_zh_tw.arb
  • lib/view/page/container/actions.dart
  • lib/view/page/container/container.dart

Comment thread lib/l10n/app_ko.arb
Comment thread lib/view/page/container/actions.dart
Comment thread lib/view/page/container/actions.dart Outdated
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@lib/view/page/container/actions.dart`:
- Around line 154-160: Wrap the pull invocation in a loading/error-handling flow
instead of calling _containerNotifier.run('pull $imageRef') directly inside the
onTap callback: close the dialog (context.pop()) if desired, show a progress
indicator or set a loading state before calling _containerNotifier.run, run the
async call inside a try/catch to capture exceptions and convert them into
user-visible messages, finally hide the progress indicator and call
context.showSnackBar with either result.message or the caught error message;
update the onTap handler and any involved state in the container notifier so
long-running pulls surface progress/errors reliably.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: c0e97941-e5b7-456a-8bf0-36ecbedac419

📥 Commits

Reviewing files that changed from the base of the PR and between 7c78bfb and 4509f25.

📒 Files selected for processing (1)
  • lib/view/page/container/actions.dart

Comment thread lib/view/page/container/actions.dart
@GT-610 GT-610 removed the request for review from lollipopkit May 2, 2026 00:25
@GT-610 GT-610 merged commit 07e5bd0 into main May 2, 2026
3 checks passed
@GT-610 GT-610 deleted the feat/image-pull-menu branch May 2, 2026 00:34
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.

Image pull (update) UI option

1 participant