Files
multica/packages/views/locales/en/common.json
Naiyuan Qing c6783efd88 feat(views): unify avatar upload with crop editing (#5074)
* feat(views): unify avatar upload with crop editing across web/desktop

Add a shared AvatarUploadControl + AvatarCropDialog used by the user,
workspace, agent, and squad avatar entry points. Cropping (pan/zoom, fixed
1:1) and compression run client-side on canvas; the existing /api/upload-file
+ avatar_url chain is reused unchanged (no backend/API/DB changes). This
collapses four hand-rolled upload buttons into one control and removes
AvatarPicker.

Also make the shared display avatar treat all non-human actors (agent, squad,
system) as rounded squares — completing the "circles are for humans"
convention the editors already assumed, so display and editors agree.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-authored-by: multica-agent <github@multica.ai>

* feat(views): rebuild avatar cropper to the "Edit avatar" reference form

Replace the hand-rolled canvas cropper with react-easy-crop to match the
requested design: full-bleed image with a dimmed overlay outside a bright
crop window, a rotate control, a zoom slider flanked by −/+, and a
Reset / Cancel / Save footer. Round window for people, rounded-square for
non-human actors; output stays a 512px square (webp, jpeg fallback) through
the same upload/avatar_url chain.

avatar-crop.ts keeps the encode pipeline and gains rotation-aware
getCroppedAvatarBlob; the interactive geometry now lives in react-easy-crop.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-authored-by: multica-agent <github@multica.ai>

* fix(views): round square avatar crop frame

---------

Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Co-authored-by: multica-agent <github@multica.ai>
2026-07-09 20:27:33 +08:00

64 lines
3.2 KiB
JSON

{
"avatar_upload": {
"change": "Change avatar",
"remove": "Remove",
"select_image": "Please choose an image file.",
"updated": "Avatar updated",
"failed": "Failed to upload avatar"
},
"avatar_crop": {
"title": "Edit avatar",
"zoom": "Zoom",
"zoom_in": "Zoom in",
"zoom_out": "Zoom out",
"rotate": "Rotate",
"reset": "Reset",
"cancel": "Cancel",
"apply": "Save",
"uploading": "Uploading…",
"loading": "Loading…",
"load_failed": "Couldn't load image"
},
"save": "Save",
"cancel": "Cancel",
"delete": "Delete",
"confirm": "Confirm",
"loading": "Loading...",
"time": {
"just_now": "just now",
"minutes_ago": "{{count}}m ago",
"hours_ago": "{{count}}h ago",
"days_ago": "{{count}}d ago"
},
"lark_bind": {
"page_title": "Bind your Lark account",
"redeeming": "Redeeming binding token…",
"needs_auth_description": "Sign in to Multica to complete the binding. The token in the link binds your Lark account to this Multica user, so you must be logged in first.",
"sign_in": "Sign in",
"done_title": "You're bound.",
"done_description": "Your next message to the Bot in Lark will go straight to the Agent. You can close this tab.",
"error_title": "Couldn't complete the binding",
"error_admin_hint": "If this keeps happening, ask the workspace admin to re-send the binding link from Lark.",
"error_missing_token": "The link is missing its binding token. Ask the Bot to send a new one in Lark.",
"error_expired": "This binding link is invalid or expired (links are valid for 15 minutes). Ask the Bot to send a new one.",
"error_already_bound": "This Lark account is already bound to a different Multica user. Account transfers must go through an explicit unbind first.",
"error_not_member": "You're signed in to a Multica account that isn't a member of this workspace.",
"error_unknown": "Something went wrong. Try again, and if the problem persists, contact the workspace admin."
},
"slack_bind": {
"page_title": "Link your Slack account",
"redeeming": "Linking your account…",
"needs_auth_description": "Sign in to Multica to complete the link. The token in the link binds your Slack account to this Multica user, so you must be logged in first.",
"sign_in": "Sign in",
"done_title": "You're linked.",
"done_description": "Your next message to the bot in Slack will go straight to the agent. You can close this tab.",
"error_title": "Couldn't complete the link",
"error_admin_hint": "If this keeps happening, message the bot again in Slack to get a fresh link.",
"error_missing_token": "The link is missing its token. Message the bot again in Slack to get a new one.",
"error_expired": "This link is invalid or expired (links are valid for 15 minutes). Message the bot again to get a new one.",
"error_already_bound": "This Slack account is already linked to a different Multica user. Account transfers must go through an explicit unbind first.",
"error_not_member": "You're signed in to a Multica account that isn't a member of this workspace.",
"error_unknown": "Something went wrong. Try again, and if the problem persists, contact the workspace admin."
}
}