mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[PR #4226] [CLOSED] Rework the background picker into a Background Library modal #6290
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#6290
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/4226
Author: @Gunterlie
Created: 7/28/2026
Status: ❌ Closed
Base:
staging← Head:background-picker-enhance📝 Commits (10+)
2acc287feat: enhance background library picker6f0a774polish: improve background library browsing117b92cfix: restore background folder browsing1595d49feat: add background folder rail, favorites, and shared thumbnails94e2cbepolish: replace background folder rail with a native folder select4a352bfpolish: browse background folders with wrapping chips4fddc83refactor: one background card, drag onto folder chips, star on the image2eccd23polish: float card actions over the thumbnail, label the library entryb758afapolish: name folders on create, import into the open folder, fix modal scrollc22de74fix: keep card actions off the tags on touch, restore a non-drag move📊 Changes
18 files changed (+1547 additions, -792 deletions)
View changed files
📝
e2e/core-flows.e2e.ts(+141 -62)📝
packages/client/src/components/panels/CharactersPanel.tsx(+1 -2)📝
packages/client/src/components/panels/PersonasPanel.tsx(+1 -2)📝
packages/client/src/components/panels/SettingsPanel.tsx(+3 -12)📝
packages/client/src/components/panels/settings/BackgroundPicker.tsx(+924 -571)📝
packages/client/src/lib/background-library.ts(+3 -1)📝
packages/client/src/localization/locales/en.json(+39 -1)📝
packages/client/src/localization/locales/ko.json(+1 -1)📝
packages/server/src/db/seed-backgrounds.ts(+1 -1)📝
packages/server/src/routes/backgrounds.routes.ts(+79 -62)📝
packages/server/src/routes/game-assets.routes.ts(+11 -2)📝
packages/server/src/routes/generate.routes.ts(+3 -3)📝
packages/server/src/routes/generate/retry-agents-route.ts(+6 -8)📝
packages/server/src/services/agents/agent-executor.ts(+22 -8)📝
packages/server/src/services/background-library-organization.ts(+39 -2)📝
packages/server/src/services/game/game-asset-generation.ts(+6 -5)➕
packages/server/src/services/image/image-thumbnail.ts(+75 -0)📝
packages/server/src/services/mari-db/mari-images.service.ts(+192 -49)📄 Description
Linked issue
Closes #
Why this change
bg_1749.pngstayed unreadable even though chats and agents need that filename to stay stable.What changed
PATCH /api/backgrounds/:filename/labelstores a display label inmeta.jsonwithout touching the filename. Control characters and newlines are normalised out; max 100 chars. The agent's<available_backgrounds>block prefers the label and now XML-escapes label and tag text.PATCH /api/backgrounds/favorite, persisted inorganization.json. A rename carries the star to the new id; deletes drop it.pruneBackgroundLibraryOrganizationdrops assignments and favorites for backgrounds that no longer exist, called on the write paths so listing stays read-only.services/image/image-thumbnail.tsout ofbackgrounds.routes.tsand reused it ingame-assets.routes.ts, so game-asset image grids can request?w=320instead of the full-size original.e2e/core-flows.e2e.tsto cover the modal, labels, favorites, the non-drag move, folder rename/delete, and that cards request the cached thumbnail (?w=320) withloading="lazy".en.json;ko.jsontouched for one key.Validation
pnpm checkpasses locallyCONTRIBUTING.mdManual verification notes
Needs manual verification in a real browser — nothing below has been confirmed by a human yet:
?w=320variant and fall back cleanly to the original on a platform withoutsharp.Docs and release impact
docs-i18nbranch updated to match, or a[docs-i18n]follow-up issue opened (see CONTRIBUTING.md § Translated documentation)UI evidence (if applicable)
Summary by CodeRabbit
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.