[PR #8098] [CLOSED] feat: cover image reposition(#2462) #8298

Closed
opened 2026-03-23 23:23:31 +00:00 by mirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/AppFlowy-IO/AppFlowy/pull/8098
Author: @PirateBrook
Created: 7/2/2025
Status: Closed

Base: mainHead: feat_cover_image_reposition


📝 Commits (10+)

  • d9f4725 feat: cover image reposition add baisc code
  • 9a51c9b feat: cover image reposition change cover auto reset to Aliginment.center
  • 2d42a8b feat: cover image reposition add coverAlignController dispose
  • ea5785b feat: cover image reposition rename to alignEnable
  • 63f46c8 featL conver image reposition add support method
  • 22898ff fix: ViewListener in the DocumentCoverWidget use the shaowed value, so it can not be update correctly.
  • 7b1a153 chore: remove extra space in createdAt translation of zh-CN (#8094)
  • 8199139 feat: cover image reposition add baisc code
  • bed09e0 feat: cover image reposition change cover auto reset to Aliginment.center
  • cda7c13 feat: cover image reposition add coverAlignController dispose

📊 Changes

6 files changed (+731 additions, -34 deletions)

View changed files

📝 frontend/appflowy_flutter/lib/mobile/application/page_style/document_page_style_bloc.dart (+1 -0)
📝 frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/header/desktop_cover.dart (+112 -13)
frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/header/desktop_cover_align.dart (+227 -0)
📝 frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/header/document_cover_widget.dart (+384 -20)
📝 frontend/appflowy_flutter/lib/shared/appflowy_network_image.dart (+6 -0)
📝 frontend/resources/translations/zh-CN.json (+1 -1)

📄 Description

Feature Preview

related feat https://github.com/AppFlowy-IO/AppFlowy/issues/2462

Kapture 2025-07-02 at 18.35.13.webm


PR Checklist

  • My code adheres to AppFlowy's Conventions
  • I've listed at least one issue that this PR fixes in the description above.
  • I've added a test(s) to validate changes in this PR, or this PR only contains semantic changes.
  • All existing tests are passing.

Summary by Sourcery

Enable repositioning of document cover images by adding drag-and-align controls and persisting offsets.

New Features:

  • Add UI controls to enter alignment mode, drag to reposition covers, and save or cancel alignment changes.

Enhancements:

  • Introduce DesktopCoverAlign widget and controller to render and manage cover image alignment.
  • Extend FlowyNetworkImage with imageBuilder support for custom rendering in alignment workflows.
  • Persist cover alignment offsets in document attributes and propagate alignment data through cover change callbacks.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/AppFlowy-IO/AppFlowy/pull/8098 **Author:** [@PirateBrook](https://github.com/PirateBrook) **Created:** 7/2/2025 **Status:** ❌ Closed **Base:** `main` ← **Head:** `feat_cover_image_reposition` --- ### 📝 Commits (10+) - [`d9f4725`](https://github.com/AppFlowy-IO/AppFlowy/commit/d9f4725004a0a8a809a7d7210a85349fe3558640) feat: cover image reposition add baisc code - [`9a51c9b`](https://github.com/AppFlowy-IO/AppFlowy/commit/9a51c9b4cfc5f9fdfb0a26ce81357cf36eb2e86f) feat: cover image reposition change cover auto reset to Aliginment.center - [`2d42a8b`](https://github.com/AppFlowy-IO/AppFlowy/commit/2d42a8b247472dedcadbbba961231c65410dd84d) feat: cover image reposition add coverAlignController dispose - [`ea5785b`](https://github.com/AppFlowy-IO/AppFlowy/commit/ea5785b237f09e92809c7f1658592cf3ca036c7c) feat: cover image reposition rename to alignEnable - [`63f46c8`](https://github.com/AppFlowy-IO/AppFlowy/commit/63f46c8ff560453a963376d49ffef9d655cbd003) featL conver image reposition add support method - [`22898ff`](https://github.com/AppFlowy-IO/AppFlowy/commit/22898ff0b4fd5aa9d908186eee2c85e37ac76866) fix: ViewListener in the DocumentCoverWidget use the shaowed value, so it can not be update correctly. - [`7b1a153`](https://github.com/AppFlowy-IO/AppFlowy/commit/7b1a15374910a4ea2fa44e8f07778ad902efdfdf) chore: remove extra space in createdAt translation of zh-CN (#8094) - [`8199139`](https://github.com/AppFlowy-IO/AppFlowy/commit/8199139b90f25447b87e7d7dd07b88d67b0e12f7) feat: cover image reposition add baisc code - [`bed09e0`](https://github.com/AppFlowy-IO/AppFlowy/commit/bed09e0432f834568f5a1c9fa9d187d8de258d26) feat: cover image reposition change cover auto reset to Aliginment.center - [`cda7c13`](https://github.com/AppFlowy-IO/AppFlowy/commit/cda7c13875f34bf9b53ded7678c7730d02fd5776) feat: cover image reposition add coverAlignController dispose ### 📊 Changes **6 files changed** (+731 additions, -34 deletions) <details> <summary>View changed files</summary> 📝 `frontend/appflowy_flutter/lib/mobile/application/page_style/document_page_style_bloc.dart` (+1 -0) 📝 `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/header/desktop_cover.dart` (+112 -13) ➕ `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/header/desktop_cover_align.dart` (+227 -0) 📝 `frontend/appflowy_flutter/lib/plugins/document/presentation/editor_plugins/header/document_cover_widget.dart` (+384 -20) 📝 `frontend/appflowy_flutter/lib/shared/appflowy_network_image.dart` (+6 -0) 📝 `frontend/resources/translations/zh-CN.json` (+1 -1) </details> ### 📄 Description <!--- Thank you for submitting a pull request to AppFlowy. The team will dedicate their best efforts to reviewing and approving your pull request. If you have any questions about the project or feedback for us, please join our [Discord](https://discord.gg/wdjWUXXhtw). --> <!--- If your pull request adds a new feature, please drag and drop a video into this section to showcase what you've done! If not, you may delete this section. --> ### Feature Preview related feat https://github.com/AppFlowy-IO/AppFlowy/issues/2462 [Kapture 2025-07-02 at 18.35.13.webm](https://github.com/user-attachments/assets/0323da28-eb5d-4cbf-b3b9-6a7123f6a9b4) <!--- List at least one issue here that this PR addresses. If it fixes the issue, please use the [fixes](https://docs.github.com/en/get-started/writing-on-github/working-with-advanced-formatting/using-keywords-in-issues-and-pull-requests) keyword to close the issue. For example: fixes https://github.com/AppFlowy-IO/AppFlowy/pull/2106 --> --- <!--- Before you mark this PR ready for review, run through this checklist! --> #### PR Checklist - [x] My code adheres to [AppFlowy's Conventions](https://docs.appflowy.io/docs/documentation/software-contributions/conventions) - [x] I've listed at least one issue that this PR fixes in the description above. - [ ] I've added a test(s) to validate changes in this PR, or this PR only contains semantic changes. - [ ] All existing tests are passing. ## Summary by Sourcery Enable repositioning of document cover images by adding drag-and-align controls and persisting offsets. New Features: - Add UI controls to enter alignment mode, drag to reposition covers, and save or cancel alignment changes. Enhancements: - Introduce DesktopCoverAlign widget and controller to render and manage cover image alignment. - Extend FlowyNetworkImage with imageBuilder support for custom rendering in alignment workflows. - Persist cover alignment offsets in document attributes and propagate alignment data through cover change callbacks. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
mirror 2026-03-23 23:23:31 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
AppFlowy-IO/AppFlowy#8298
No description provided.