Skip to content

Conversation

@Robert-Stackflow
Copy link
Owner

No description provided.

Replaces all flutter_cloud imports and usage with awesome_cloud across the codebase. Updates dependency references in pubspec.yaml and pubspec.lock, removes flutter_cloud package and files, and adds/renames awesome_cloud package and its files. Adjusts cloud service implementations and screens to use awesome_cloud APIs, and updates HuaweiCloudService to use custom endpoints and client ID.
Introduces AliyunDrive and Box as supported cloud backup services, including new service screens, cloud service implementations, and backup management bottom sheets. Updates the cloud service config model, DAO, and main backup screen to integrate these providers. Also adds relevant localization entries and adjusts GoogleDrive and HuaweiCloud to use a configurable server endpoint.
Updated cloud backup service screens to use ChewieTheme for consistent colors, improved OAuth safety tips, and added server status checks before authentication. Enhanced UI feedback for backup and encryption settings, refactored context menu and token layout interactions, and fixed typos and minor logic issues. These changes improve user experience, maintainability, and security awareness across backup and token management features.
Introduces a reusable Utils.showQAuthDialog method to display an informational dialog about the OAuth relay server for Google Drive, Huawei Cloud, and Box services. The dialog is now shown on relevant backup service screens and can be forced or suppressed based on user acknowledgment. Also updates icons, improves logging, and refines localization for the dialog message. Minor UI and code cleanups included.
Corrects the import statement to use 'aliyundrive_cloud_service.dart' instead of 'aliyunDrive_cloud_service.dart' to match the actual file name and ensure proper module resolution.
Renamed the database file from 'cloudotps.db' to 'cloudotp.db' to correct a typo and ensure consistency across the application.
Replaces the image_gallery_saver dependency in chewie with a local path reference and adds the full plugin source under third-party/tool/image_gallery_saver. Downgrades Android Gradle plugin and wrapper versions for compatibility. Removes Gradle cache from release workflow.
@Robert-Stackflow Robert-Stackflow self-assigned this Jul 19, 2025
@Robert-Stackflow Robert-Stackflow requested a review from Copilot July 19, 2025 10:07
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR performs major internationalization (i18n) refactoring for the CloudOTP application, migrating from intl_utils to Flutter's native l10n system and adding support for new languages while improving theme naming and architecture.

  • Migrated i18n system from intl_utils to Flutter's native l10n with proper l10n.yaml configuration
  • Added Japanese language support and enhanced Chinese locale handling (zh, zh_CN, zh_TW)
  • Refactored theme system with internationalized theme names and improved color schemes
  • Updated architecture with new base state classes, dialog navigation helpers, and responsive utilities

Reviewed Changes

Copilot reviewed 179 out of 348 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
l10n.yaml New Flutter l10n configuration file
pubspec.yaml Version bump to 3.1.1 and dependency updates for i18n migration
lib/main.dart Updated localization delegates and context initialization
third-party/chewie/lib/src/l10n/*.arb Added new locale files and updated existing translations
third-party/chewie/lib/src/Resources/theme_color_data.dart Added internationalized theme names
third-party/chewie/lib/src/Utils/General/responsive_util.dart Enhanced responsive utilities with new naming conventions
various widget files Updated to use new localization system and base state classes
Comments suppressed due to low confidence (1)

third-party/chewie/lib/src/Widgets/Item/Tile/entry_item.dart:417

  • The class name 'CaptionItemState' is inconsistent with other state classes which follow the pattern '_WidgetNameState'. Consider renaming to '_CaptionItemState' to match Flutter conventions.
class CaptionItemState extends BaseDynamicState<CaptionItem>

@@ -1,5 +1,5 @@
{
"@@locale": "ja_JP",
"@@locale": "ja",
Copy link

Copilot AI Jul 19, 2025

Choose a reason for hiding this comment

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

The locale identifier changed from 'ja_JP' to 'ja'. Ensure this change is intentional and that all Japanese locale references are updated consistently throughout the codebase.

Suggested change
"@@locale": "ja",
"@@locale": "ja_JP",

Copilot uses AI. Check for mistakes.
Comment on lines 32 to +43
AndroidAuthMessages androidAuthMessages = AndroidAuthMessages(
cancelButton: ChewieS.current.biometricCancelButton,
goToSettingsButton: ChewieS.current.biometricGoToSettingsButton,
biometricNotRecognized: ChewieS.current.biometricNotRecognized,
goToSettingsDescription: ChewieS.current.biometricGoToSettingsDescription,
cancelButton: chewieLocalizations.biometricCancelButton,
goToSettingsButton: chewieLocalizations.biometricGoToSettingsButton,
biometricNotRecognized: chewieLocalizations.biometricNotRecognized,
goToSettingsDescription: chewieLocalizations.biometricGoToSettingsDescription,
biometricHint: ResponsiveUtil.isWindows()
? ChewieS.current.biometricReasonWindows(ResponsiveUtil.appName)
: ChewieS.current.biometricReason(ResponsiveUtil.appName),
biometricSuccess: ChewieS.current.biometricSuccess,
signInTitle: ChewieS.current.biometricSignInTitle,
? chewieLocalizations.biometricReasonWindows(ResponsiveUtil.appName)
: chewieLocalizations.biometricReason(ResponsiveUtil.appName),
biometricSuccess: chewieLocalizations.biometricSuccess,
signInTitle: chewieLocalizations.biometricSignInTitle,
deviceCredentialsRequiredTitle:
ChewieS.current.biometricDeviceCredentialsRequiredTitle,
chewieLocalizations.biometricDeviceCredentialsRequiredTitle,
Copy link

Copilot AI Jul 19, 2025

Choose a reason for hiding this comment

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

The constant 'androidAuthMessages' is accessing 'chewieLocalizations' during initialization, but this may cause issues if the localization context is not available at app startup. Consider using lazy initialization or providing fallback values.

Copilot uses AI. Check for mistakes.
final VoidCallback? onTap;
final double scaleFactor;
final double yOffset;
final double tiltAngle; // 倾斜角度控制
Copy link

Copilot AI Jul 19, 2025

Choose a reason for hiding this comment

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

[nitpick] The comment is in Chinese while the codebase appears to primarily use English comments. Consider translating to English: '// Tilt angle control' for consistency.

Suggested change
final double tiltAngle; // 倾斜角度控制
final double tiltAngle; // Tilt angle control

Copilot uses AI. Check for mistakes.
"triggerAutoBackupByCategoryUpdated": "修改分類",
"triggerAutoBackupByCategoriesUpdated": "修改分類",
"triggerAutoBackupByCategoryDe​​leted": "刪除分類",
"triggerAutoBackupByCategoryDeleted": "刪除分類",
Copy link

Copilot AI Jul 19, 2025

Choose a reason for hiding this comment

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

The key name was corrected from 'triggerAutoBackupByCategoryDe​​leted' (which contained hidden characters) to 'triggerAutoBackupByCategoryDeleted'. Ensure this key change is reflected in all code references.

Copilot uses AI. Check for mistakes.
Comment on lines +61 to +62
minHeight ?? double.infinity,
height ?? double.infinity,
Copy link

Copilot AI Jul 19, 2025

Choose a reason for hiding this comment

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

Using 'double.infinity' in the math.min operation could cause performance issues. Consider using a reasonable maximum value instead of infinity.

Suggested change
minHeight ?? double.infinity,
height ?? double.infinity,
minHeight ?? 10000.0,
height ?? 10000.0,

Copilot uses AI. Check for mistakes.
@Robert-Stackflow Robert-Stackflow merged commit 0ba5bd6 into main Jul 19, 2025
5 checks passed
@Robert-Stackflow Robert-Stackflow deleted the test-cloud branch July 19, 2025 10:11
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.

2 participants