Skip to content

feat: add compression results display and enhance multilingual support - #21

Merged
CodeDead merged 1 commit into
developmentfrom
feature/before-and-after
May 25, 2026
Merged

feat: add compression results display and enhance multilingual support#21
CodeDead merged 1 commit into
developmentfrom
feature/before-and-after

Conversation

@CodeDead

Copy link
Copy Markdown
Owner
  • Introduced "Compression Results" view to display compression statistics.
  • Enhanced language files with new keys for displaying compression results in multiple languages.
  • Updated ImageService to return detailed compression results, including file size savings.
  • Added optional setting to toggle the display of compression results post-compression.
  • Refactored views.rs and app.rs to accommodate the new "Results" view.

- Introduced "Compression Results" view to display compression statistics.
- Enhanced language files with new keys for displaying compression results in multiple languages.
- Updated `ImageService` to return detailed compression results, including file size savings.
- Added optional setting to toggle the display of compression results post-compression.
- Refactored `views.rs` and `app.rs` to accommodate the new "Results" view.
@CodeDead
CodeDead requested a review from Copilot May 25, 2026 18:26
@CodeDead CodeDead self-assigned this May 25, 2026
@CodeDead CodeDead added the enhancement New feature or request label May 25, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

Adds a post-compression “Compression Results” window and related plumbing so the app can display per-file size statistics, along with new localized strings and a user setting to enable/disable the results window.

Changes:

  • Introduced a new Results window/view that lists original vs. compressed sizes and totals.
  • Updated compression pipeline to return CompressionResult data (per file) instead of ().
  • Added multilingual UI keys and a new settings toggle (show_compression_results) to control whether the results window auto-opens.

Reviewed changes

Copilot reviewed 18 out of 18 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
src/views/settings_view.rs Adds a settings checkbox to toggle showing compression results.
src/views/results_view.rs New view rendering per-file compression stats, totals, and a close button.
src/views.rs Registers the new results_view module.
src/services/theme_service.rs Expands Rustdoc for string_to_theme.
src/services/image_service.rs Introduces CompressionResult and updates compress_single to return detailed results.
src/models/language.rs Adds new language keys for results UI and the new settings toggle label.
src/components/state.rs Stores compression_results in app state and initializes it.
src/components/settings.rs Adds show_compression_results setting and default.
src/components/app.rs Adds Results window kind, new messages, and hooks to open/close results after compression.
languages/en_us.json Adds strings for results UI and “show compression results” setting.
languages/es_es.json Adds strings for results UI and “show compression results” setting.
languages/fr_fr.json Adds strings for results UI and “show compression results” setting.
languages/ja_jp.json Adds strings for results UI and “show compression results” setting.
languages/nl_nl.json Adds strings for results UI and “show compression results” setting.
languages/pt_pt.json Adds strings for results UI and “show compression results” setting.
languages/ru_ru.json Adds strings for results UI and “show compression results” setting.
languages/uk_ua.json Adds strings for results UI and “show compression results” setting.
languages/zh_cn.json Adds strings for results UI and “show compression results” setting.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/components/settings.rs
Comment thread src/views/results_view.rs
@CodeDead
CodeDead merged commit 34ac93c into development May 25, 2026
1 check passed
@CodeDead
CodeDead deleted the feature/before-and-after branch May 25, 2026 18:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants