Skip to content

feat: improve editor localization and element editing workflow#46

Open
vigstudio wants to merge 2 commits into
CristianOlivera1:mainfrom
vigstudio:feat/editor-element-panel-fill
Open

feat: improve editor localization and element editing workflow#46
vigstudio wants to merge 2 commits into
CristianOlivera1:mainfrom
vigstudio:feat/editor-element-panel-fill

Conversation

@vigstudio

@vigstudio vigstudio commented Jun 3, 2026

Copy link
Copy Markdown

Goal

This PR improves the editor’s element-editing workflow, completes Vietnamese localization coverage in core editor surfaces, and adds a fully offline image background-removal flow.

Scope of Changes

1) Editor Localization Improvements

  • Reviewed and updated user-facing editor labels/messages for better Vietnamese consistency.
  • Aligned context-menu actions and editor control labels.
  • Updated locale message usage to reduce mixed-language UI states.

2) Fully Offline Background Removal

  • Added local hosting flow for background-removal assets (no external API dependency).
  • Configured runtime to use local model/resources in the current environment.
  • Ensured middleware/routing behavior does not break local asset loading.

3) Background Removal on Selected Image Layer

  • Fixed behavior so background removal applies to the currently selected image element, not only the primary photo.
  • Added restore-original flow for processed layers.
  • Preserved expected behavior for the main-photo fallback path.

4) Dedicated Element Edit Panel

  • Added a dedicated element edit UI opened directly from element context actions.
  • Moved to a left-side docked panel to avoid blocking the canvas preview.
  • Included controls for:
    • Position (X/Y)
    • Size (W/H)
    • Rotation
    • Opacity
    • Visibility toggle
    • Lock/unlock
    • Delete element

5) Advanced Image Editing: Crop + Fill

  • Added per-edge crop controls to remove extra/unwanted parts.
  • Added image fill modes:
    • None
    • Solid color
    • Gradient
  • Added fill intensity control.
  • Fixed fill behavior to follow the image alpha/mask so fill affects actual image content, not the full element bounding box.

6) Preview and Export Rendering Sync

  • Updated both live canvas preview rendering and export rendering paths.
  • Ensured crop/fill/opacity/transform edits are consistently reflected in exported output.

7) Context Menu and Element Targeting Reliability

  • Improved right-click target resolution for canvas elements.
  • Reduced action mismatches caused by stale/async selection state.

Validation

  • Type check:
    • docker compose exec app pnpm exec tsc -p tsconfig.json --noEmit

Outcome

  • Element-level image editing is now more practical and precise.
  • Background removal works offline and on the correct selected layer.
  • Fill/crop behave correctly on real image detail regions.
  • Editor language experience is more consistent for Vietnamese users.

Risks / Notes

  • This PR touches UI + render/export logic across multiple editor surfaces; careful regression review is recommended.
  • Offline asset bundle is large, so clone/pull and CI artifact transfer may take longer.

@CristianOlivera1

Copy link
Copy Markdown
Owner

I review it and validate it, Thanks !

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