mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[PR #133] [MERGED] perf(client): split translation state from on-demand helpers #4479
Labels
No labels
android
bug
bugfix
ci
client
code freeze pause
container
dependencies
docs
documentation
duplicate
enhancement
feature
feature
feature
feature-creep
fixed-in-refactor
fixed-in-staging
good first issue
help wanted
in-pr
in-pr
needs-codeowner-decision
normal-scope
old-codebase
old-codebase
pull-request
qol
question
refactor
regression
revisit later
roadmap
scope-risk
scope-risk
server
server
shared
soup
upstream
windows
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Pasta-Devs/Marinara-Engine#4479
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/133
Author: @TheLonelyDevil9
Created: 4/20/2026
Status: ✅ Merged
Merged: 4/20/2026
Merged by: @SpicyMarinara
Base:
main← Head:codex/client-translation-loading-boundary📝 Commits (1)
112d3f0perf(client): split translation state from on-demand helpers📊 Changes
7 files changed (+82 additions, -79 deletions)
View changed files
📝
packages/client/src/components/chat/ChatArea.tsx(+1 -1)📝
packages/client/src/components/chat/ChatInput.tsx(+1 -1)📝
packages/client/src/components/chat/ConversationInput.tsx(+2 -2)📝
packages/client/src/hooks/use-generate.ts(+1 -1)📝
packages/client/src/hooks/use-translate.ts(+1 -74)➕
packages/client/src/lib/translate-text.ts(+16 -0)➕
packages/client/src/stores/translation.store.ts(+60 -0)📄 Description
Why
The client build currently emits a Vite warning because the translation module is imported both statically and dynamically. That prevents Vite from cleanly splitting the imperative input-translation path into its own async chunk and makes the loading boundary around translation behavior harder to reason about.
This PR is intentionally small and low-risk. It is the first slice in a broader optimization pass, and it only changes module boundaries around translation state and helper loading.
What Changed
Why This Shape
Review Guidance
Validation
Follow-ups
This is PR 1 of the optimization train. The next slices are planned as:
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.