#1 PDF Application on GitHub that lets you edit PDFs on any device anywhere
TypeScript dockerhacktoberfestjavapdfpdf-converterpdf-editorpdf-manipulationpdf-mergerpdf-ocrpdf-toolspdf-web-appspdfmergerself-hosted
Translate hardcoded UI text in components (#8288)
Anthony Stirlingaf06b37950b8
diff --git a/frontend/editor/public/locales/en-US/translation.toml b/frontend/editor/public/locales/en-US/translation.tomlindex 83ded88d38..4adf56ade1 100644--- a/frontend/editor/public/locales/en-US/translation.toml+++ b/frontend/editor/public/locales/en-US/translation.toml@@ -278,6 +278,7 @@ customNumberDesc = "e.g., \"Page {n}\" or leave blank for just numbers"fontName = "Font Name"fontSize = "Font Size"numberPagesDesc = "e.g., 1,3,5-8 or leave blank for all pages"+pagePreviewAlt = "Page preview"pagesAndStarting = "Pages & Starting Number"positionAndPages = "Position & Pages"preview = "Position Selection"@@ -350,7 +351,9 @@ text = "These permissions control what users can do with the PDF. Most effectivetitle = "Change Permissions"[addStamp]+pagePreviewAlt = "Page preview"preview = "Preview Stamp"+stampPreviewAlt = "Stamp preview"tags = "stamp,mark,seal,approved,rejected,confidential,stamp tool,rubber stamp,date stamp,approval stamp,received,void,copy,original"[AddStampRequest]@@ -383,6 +386,7 @@ positionAndFormatting = "Position & Formatting"preview = "Preview:"quickPosition = "Select a position on the page to place the stamp."rotation = "Rotation"+selectedImageAlt = "Selected stamp image"selectTemplate = "Select a template..."stampSetup = "Stamp Setup"stampText = "Stamp Text"@@ -534,6 +538,9 @@ letter = "Letter"[adjustPageScale.scaleFactor]label = "Scale Factor"+[adjustPageScale.settings]+title = "Settings"+[adjustPageScale.tooltip.description]text = "Adjust the size of PDF content and change the page dimensions."title = "Description"@@ -728,6 +735,7 @@ noLanguages = "No tessdata languages found in the configured directory."permissionNotice = "The tessdata path is not writable. Downloads will be opened in the browser; please save the .traineddata files manually into the tessdata folder."[admin.settings.ai]+customProvider = "Custom (OpenAI-compatible)"description = "Connect Stirling to the Python AI engine, choose its models, and set the guardrails it runs under."managedByCloud = "Managed by Stirling Cloud in this mode."managedByCloudShort = "Managed by Stirling Cloud"@@ -1279,6 +1287,7 @@ label = "Custom Metadata"[admin.settings.general.customMetadata.author]description = "Default author for PDF metadata (e.g., username)"label = "Default Author"+placeholder = "username"[admin.settings.general.customMetadata.autoUpdate]description = "Automatically update PDF metadata on all processed documents"@@ -1394,6 +1403,7 @@ defaultLocaleLink = "Configure the default locale"description = "Show a disclaimer users must accept after logging in. The text follows each user's language."discardConfirm = "You have unsaved changes that will be lost. Switch language anyway?"editLabel = "Markdown"+editPlaceholder = "## Heading\n\nYour disclaimer text..."emptyPreview = "Nothing to preview yet."language = "Language"languageHelp = "Each language has its own file. If a user's language has no file, the agreement falls back to the default locale's file, then to the fallback text."@@ -1512,8 +1522,10 @@ label = "JWKS URL (optional)"placeholder = "Auto-discovered from issuer"[admin.settings.mcp.mode]+apikey = "API key (Stirling per-user key)"description = "OAuth needs an external IdP. API key uses a Stirling per-user API key (X-API-KEY) - simplest for self-host."label = "Authentication mode"+oauth = "OAuth 2.1 (external IdP)"[admin.settings.mcp.requireAccount]description = "Only let tokens through if their subject maps to a provisioned, enabled Stirling user."@@ -1930,6 +1942,14 @@ title = "User Control Settings"[agents]stirling_name = "Stirling"+[alphabetOptions]+arabic = "Arabic"+chinese = "Chinese (Simplified)"+japanese = "Japanese"+korean = "Korean"+roman = "Roman"+thai = "Thai"+[analytics]learnMore = "Learn more about our analytics"paragraph1 = "Stirling PDF has opt-in analytics to help us improve the product. We do not track any personal information or file contents."@@ -2051,6 +2071,7 @@ week = "Week"[audit.clearData]cancel = "Cancel"+closeAlert = "Close alert"codeDoesNotMatch = "Code does not match"codePlaceholder = "Type the code here"confirmationCode = "Confirmation Code"@@ -2060,6 +2081,7 @@ confirmTitle = "Please confirm you want to delete"deleteButton = "Delete"enterCode = "Confirmation Code"enterCodeBelow = "Enter the code exactly as shown above (case-sensitive)"+failed = "Failed to clear audit data"initiateDelete = "Delete All Data"irreversible = "IRREVERSIBLE"success = "Success"@@ -2068,6 +2090,7 @@ warning1 = "This action cannot be undone"warning2 = "Deleting audit data will permanently remove all historical audit logs, including security events, user activities, and file operations from the database."[audit.error]+loadStatus = "Failed to load audit system status"title = "Error loading audit system"[audit.events]@@ -2083,6 +2106,7 @@ fileHash = "File Hash"filterByType = "Filter by type"filterByUser = "Filter by user"ipAddress = "IP Address"+loadFailed = "Failed to load events"noEvents = "No events found"startDate = "Start date"timestamp = "Timestamp"@@ -2123,6 +2147,7 @@ avgLatency = "Avg Latency"error = "Error loading statistics"excellent = "Excellent"good = "Good"+loadFailed = "Failed to load statistics"noData = "N/A"successRate = "Success Rate"totalEvents = "Total Events"@@ -2157,14 +2182,28 @@ accessDenied = "Access Denied"insufficientPermissions = "You do not have permission to perform this action."[auth.callback]+alreadySignedIn = "Already signed in! Redirecting..."+backToLogin = "Back to login"completing = "Completing authentication"+exchanging = "Exchanging authorization code..."+failedWithReason = "Authentication failed: {{error}}"invalidToken = "OAuth login failed - invalid token."missingToken = "OAuth login failed - no token received."+noData = "No authentication data found"oauthFailed = "OAuth login failed. Please try again."pleaseWait = "Please wait while we finish signing you in."+processing = "Processing authentication..."signedOut = "You have been signed out. Please sign in again."+signInFailed = "Failed to complete sign in: {{error}}"+success = "Sign in successful! Redirecting..."+unknownError = "Unknown error"windowMayClose = "You can close this window once it completes."+[auth.callback.title]+default = "Authentication"+processing = "Signing you in"+success = "You're all set!"+[auth.displayName]guest = "Guest"user = "User"@@ -2316,6 +2355,7 @@ title = "Import automation"unresolved = "Unmapped: {{ops}}"[automate.run]+progress = "Progress: {{current}}/{{total}}"title = "Run Automation"[automate.selection]@@ -2465,6 +2505,7 @@ whatHappensNext = "What happens next?"[billing.portal]error = "Failed to open billing portal"+errorFallback = "Please try again or contact support."[bookletImposition]paperSizeNote = "Paper size is automatically derived from your first page."@@ -2513,6 +2554,9 @@ title = "Manual Duplex Mode"label = "Right-to-left binding"tooltip = "For Arabic, Hebrew, or other right-to-left languages"+[bookletImposition.settings]+title = "Settings"+[bookletImposition.tooltip.advanced]bullet1 = "Right-to-Left Binding: For Arabic, Hebrew, or RTL languages"bullet2 = "Borders: Shows cut lines for trimming"@@ -2581,6 +2625,8 @@ detail = "Click or press Space to play again"headline = "All clear"[bulkSelection]+selectedPages_one = "Selected: {{count}} page ({{pages}})"+selectedPages_other = "Selected: {{count}} pages ({{pages}})"syntaxError = "There is a syntax issue. See Page Selection tips for help."[bulkSelection.advanced]@@ -2801,6 +2847,7 @@ declineButton = "Decline"deleteSelected = "Delete selected signature"drawSignature = "Draw your signature below"fileTooLarge = "File size must be less than 5MB"+fontBrushScript = "Brush Script MT (cursive)"fontFamily = "Font Family"fontSize = "Font Size: {{size}}px"fontSizePlaceholder = "Size"@@ -2820,6 +2867,7 @@ removeImage = "Remove Image"savedSignatures = "Saved Signatures"selectFile = "Select Image File"selectSignatureTitle = "Select or Create Signature"+signatureImageAlt = "Signature"signatureInfo = "These settings are configured by the document owner"signatureSettings = "Signature Settings"signatureText = "Signature Text"@@ -3590,13 +3638,19 @@ confirm = "Confirm"continue = "Continue"copied = "Copied!"copy = "Copy"+copyCode = "Copy code"+dismiss = "Dismiss"done = "Done"enterValue = "Enter value"error = "Error"expand = "Expand"filterEmpty = "Nothing to filter on"+goToSlide = "Go to slide {{number}}"loading = "Loading..."+moreInformation = "More information"next = "Next"+noData = "No data"+nOfTotal = "{{current}} of {{total}}"open = "Open"preview = "Preview"previous = "Previous"@@ -3605,6 +3659,9 @@ remaining = "Remaining"retry = "Retry"save = "Save"search = "Search"+settingsSections = "Settings sections"+showAllTotal = "Show all {{total}}"+showLess = "Show less"stepOf = "Step {{current}} of {{total}}"[compare]@@ -3616,6 +3673,7 @@ newLine = "new-line"pages = "Pages"tags = "differentiate,contrast,changes,analysis"title = "Compare"+workbenchLabel = "Compare view"[compare.actions]linkScroll = "Link scroll"@@ -3769,6 +3827,7 @@ title = "Compression Method"desiredSize = "Desired File Size"desiredSizePlaceholder = "Enter size"desiredSizeUnit = "Size unit"+title = "Settings"[compress.tooltip.description]text = "Compression is an easy way to reduce your file size. Pick File Size to enter a target size and have us adjust quality for you. Pick Quality to set compression strength manually."@@ -3818,10 +3877,13 @@ title = "Account Settings"description = "Upload an image to personalize your account."help = "PNG, JPG, or WebP up to 2MB."remove = "Remove"+removeFailed = "Failed to remove profile picture"sizeError = "Please select an image smaller than 2MB."switchedToCustom = "Switched to custom picture. You can now upload your own."+switchFailed = "Failed to switch to custom picture"title = "Profile picture"upload = "Upload"+uploadFailed = "Failed to upload profile picture"useCustom = "Use custom picture"usingProvider = "Using {{provider}} profile picture"@@ -3835,6 +3897,7 @@ title = "Crop Profile Picture"zoom = "Zoom"[config.account.security]+changeFailed = "Failed to change password"changePassword = "Change password"description = "Manage your password and security settings."title = "Passwords & Security"@@ -3845,11 +3908,15 @@ description = "Link your account to preserve your history and access more featuremail = "Email"emailPassword = "or enter your email & password"emailPlaceholder = "Enter your email"+failed = "Failed to upgrade account"+failedWithProvider = "Failed to upgrade account with {{provider}}"linkWith = "Link with"+linkWithProvider = "Link with {{provider}}"password = "Password (optional)"passwordNote = "Leave empty to use email verification only"passwordPlaceholder = "Set a password"socialLogin = "Upgrade with Social Account"+success = "Account upgraded successfully! You can now sign in with your email."title = "Upgrade Guest Account"upgradeButton = "Upgrade Account"@@ -4008,6 +4075,7 @@ multiple = "Multiple"optimizeForEbook = "Optimize PDF for ebook readers (uses Ghostscript)"output = "Output"outputFormat = "Output Format"+pdfaAccessibleFormat = "{{format}} (accessible)"pdfaDigitalSignatureWarning = "The PDF contains a digital signature. This will be removed in the next step."pdfaNote = "PDF/A-1b is more compatible, PDF/A-2b supports more features, PDF/A-3b supports embedded files."pdfaOptions = "PDF/A Options"@@ -4068,6 +4136,24 @@ tabletPhone = "Tablet/Phone (with images)"targetDevice = "Target device"targetDeviceDesc = "Choose an output profile optimized for the reader device"+[convert.formatGroups]+archive = "Archive"+document = "Document"+ebook = "eBook"+email = "Email"+file = "File"+image = "Image"+multipleFiles = "Multiple Files"+presentation = "Presentation"+spreadsheet = "Spreadsheet"+text = "Text"+web = "Web"++[convert.formatOptions]+any = "Any"+images = "Images"+msgOutlook = "MSG (Outlook)"+[cookieBanner.popUp]acceptAllBtn = "Okay"acceptNecessaryBtn = "No Thanks"@@ -4202,6 +4288,11 @@ title = "Settings Opened"message = "Stirling PDF is now your default PDF editor"title = "Default App Set"+[desktop.titleBar]+maximize = "Maximize"+minimize = "Minimize"+restore = "Restore"+[desktopBilling]description = "Manage usage and billing in your browser. Sign in with the same Stirling account you use here."open = "Open Usage & Billing in browser"@@ -4270,6 +4361,7 @@ tags = "SSO,single sign-on,authentication,SAML,OAuth,OIDC,login,enterprise,identnoItems = "No items available"noResults = "No results found"searchPlaceholder = "Search..."+selectedCount = "{{count}} selected"selectLanguages = "Select languages"selectOption = "Select an option"@@ -4280,6 +4372,7 @@ editSecretValue = "Edit secret value"[editTableOfContents]submit = "Apply table of contents"tags = "bookmarks,contents,edit,table of contents,TOC,outline,navigation,chapters,sections,add bookmarks,edit bookmarks,PDF outline"+workbenchLabel = "Outline workspace"[editTableOfContents.actions]clipboardUnavailable = "Clipboard access is not available in this browser."@@ -4440,6 +4533,27 @@ closeFile = "Close file"[fileEditor]addFiles = "Add Files"+closedFile = "Closed {{name}}"+couldNotSave = "Could not save {{name}}"+filesAdded_one = "Added {{count}} file"+filesAdded_other = "Added {{count}} files"+filesReordered_one = "File reordered"+filesReordered_other = "{{count}} files reordered"+loadedFromStorage_one = "Loaded {{count}} file from storage"+loadedFromStorage_other = "Loaded {{count}} files from storage"+loadFromStorageFailed = "Failed to load some files from storage"+pinnedFile = "Pinned {{name}}"+processFilesFailed = "Failed to process files"+savedAndClosed = "Saved and closed {{name}}"+saveFailed = "Save failed"+unpinnedFile = "Unpinned {{name}}"+unzipping = "Unzipping {{name}}"++[fileEditor.unzip]+error = "Error unzipping {{name}}"+extracted_one = "Extracted {{count}} file from {{name}}"+extracted_other = "Extracted {{count}} files from {{name}}"+failed = "Failed to extract files from {{name}}"[fileManager]addToUpload = "Add to Upload"@@ -4456,6 +4570,7 @@ noFiles = "No files available"noFilesFound = "No files found matching your search"openInFileEditor = "Open in File Editor"openInPageEditor = "Open in Page Editor"+reloadFiles = "Reload Files"saveSelected = "Save Files"searchFiles = "Search files..."share = "Share"@@ -4465,6 +4580,8 @@ sharedEditNoticeConfirm = "Got it"sharedEditNoticeTitle = "Read-only server copy"sharedWithYou = "Shared with you"showAll = "Show All"+showAllCount_one = "Show All ({{count}} file)"+showAllCount_other = "Show All ({{count}} files)"sortBy = "Sort files"sortByDate = "Sort by Date"sortByName = "Sort by Name"@@ -4502,6 +4619,11 @@ subtitle = "Choose from your library or add something new."title = "Add files"unsupported = "This file type isn't supported by the selected tool."+[filePreview]+loadingThumbnail = "Loading thumbnail..."+locked = "Locked"+previewOf = "Preview of {{name}}"+[files]addFiles = "Add files"created = "Created"@@ -4936,13 +5058,15 @@ title = "File to PDF"[fileUpload]dropFilesHere = "Drop files here or click the upload button"dropFilesHereOpen = "Drop files here or click the open button"-filesAvailable = "files available"+filesAvailableCount_one = "{{count}} file available"+filesAvailableCount_other = "{{count}} files available"loadFromStorage = "Load from Storage"noFilesInStorage = "No files available in storage. Upload some files first."noFilesInStorageOpen = "No files available in storage. Open some files first."open = "Open"openFile = "Open File"openFiles = "Open Files"+selectedCount = "{{count}} selected"selectFile = "Select {{name}}"selectFromStorage = "Select from Storage"upload = "Upload"@@ -5034,6 +5158,7 @@ rescanFields = "Re-scan fields"rescanFormFields = "Re-scan form fields"save = "Save"saveShortcut = "Ctrl+S to save"+selectOptionPlaceholder = "— select —"skippedEdits_one = "1 change could not be applied:"skippedEdits_other = "{{count}} changes could not be applied:"skippedEditsTruncated = "{{count}} more not listed."@@ -5096,6 +5221,16 @@ tooltipHelp = "The hint shown when someone hovers the field in a PDF reader."type = "Type"typeHelp = "What kind of field this is. Changing it rebuilds the field, so its current value is not carried over."+[formFill.fieldTypes]+button = "Button"+checkbox = "Checkbox"+combobox = "Dropdown"+listbox = "List box"+radio = "Radio"+radioGroup = "Radio group"+signature = "Signature"+text = "Text"+[formFill.mode]create = "Create"fill = "Fill"@@ -5113,11 +5248,16 @@ restore = "Restore"[formFill.sidebar]close = "Close sidebar"+empty = "No form fields found in this PDF"+loading = "Loading form fields..."+pageNumber = "Page {{page}}"+title = "Form Fields"[getPdfInfo]downloadJson = "Download JSON"downloads = "Downloads"indexTitle = "Index"+noData = "No Data"noneDetected = "None detected"noResults = "Run the tool to generate a report."processing = "Extracting information..."@@ -5133,6 +5273,8 @@ noVerification = "No Verification Performed"noVerificationDesc = "PDF standards compliance was not verified for this document."passed = "Passed"passedCount = "passed"+secCompliant = "Document meets SEC EDGAR filing requirements"+secNotCompliant = "Document does not meet SEC EDGAR filing requirements"[getPdfInfo.error]partial = "Some files could not be processed."@@ -5140,10 +5282,15 @@ unexpected = "Unexpected error during extraction."[getPdfInfo.other]attachments = "Attachments"+created = "Created: {{date}}"embeddedFiles = "Embedded Files"+fileSizeBytes = "({{size}} bytes)"javaScript = "JavaScript"layers = "Layers"+modified = "Modified: {{date}}"structureTree = "StructureTree"+unnamedAttachment = "Unnamed attachment"+unnamedFile = "Unnamed file"xmp = "XMPMetadata"[getPdfInfo.perPage]@@ -5153,6 +5300,7 @@ images = "Images"links = "Links"multimedia = "Multimedia"size = "Size"+unnamedImage = "Image"xobjects = "XObject Counts"[getPdfInfo.report]@@ -5681,6 +5829,7 @@ invalidEmail = "Invalid email address"invalidInvitation = "Invalid Invitation"invalidToken = "Invalid invitation link"linkExpires = "Link expires"+linkExpiresAt = "Link expires: {{date}} at {{time}}"passwordMismatch = "Passwords do not match"passwordPlaceholder = "Enter your password"passwordRequired = "Password is required"@@ -5695,6 +5844,7 @@ welcomeTitle = "You've been invited!"addFiles = "Add Files"mobileUpload = "Upload from Mobile"openFromComputer = "Open from computer"+settingUpSession = "Setting up your session..."uploadFromComputer = "Browse files"[language]@@ -5776,6 +5926,7 @@ sessionExpired = "Your session has expired. Please sign in again."signin = "Sign in"signingIn = "Signing in..."signInWith = "Sign in with"+signInWithProvider = "Sign in with {{provider}}"title = "Sign in"unexpectedError = "Unexpected error: {{message}}"updatePassword = "Update password"@@ -5817,6 +5968,9 @@ label = "Remove digital signature in the merged file?"description = "Digital signatures will be invalidated when merging files. Check this to remove them from the final merged PDF."title = "Remove Digital Signature"+[merge.settings]+title = "Settings"+[merge.sortBy]ascending = "Ascending"dateModified = "Date Modified"@@ -5826,6 +5980,9 @@ filename = "File Name"label = "Sort By"sort = "Sort"+[merge.sortFiles]+title = "Sort Files"+[merge.tooltip.header]title = "Merge Settings Overview"@@ -5873,6 +6030,7 @@ validating = "Validating session..."[mobileSign]clear = "Clear"+drawingArea = "Signature drawing area"invalidSession = "Session expired"invalidSessionMessage = "This QR code is no longer valid. Open the Sign tool on your computer and scan the new code."penSizeLabel = "Pen size"@@ -5888,6 +6046,7 @@ validating = "Checking session…"fromGallery = "From gallery"hint = "Photograph a signature on white paper, or choose an existing image."invalidType = "Please choose an image file."+previewAlt = "Signature"takePhoto = "Take a photo"[mobileSign.tab]@@ -6000,6 +6159,9 @@ desc = "Cleanup scans and detects text from images within a PDF and re-adds it atags = "recognition,text,image,scan,read,identify,detection,editable"title = "OCR / Scan Cleanup"+[ocr.advanced]+title = "Advanced"+[ocr.error]failed = "OCR operation failed"@@ -6194,6 +6356,7 @@ message = "The application has undergone significant changes recently. Your servroleAdmin = "Admin"rolePlaceholder = "Confirm your role"roleUser = "User"+title = "Security Check"[onboarding.serverLicense]freeBody = "Our <strong>Open-Core</strong> licensing includes <strong>OAuth SSO</strong> and up to <strong>{{freeTierLimit}}</strong> users for free. To scale uninterrupted, we recommend the Stirling Team plan - <strong>100 users</strong> for $99/mo."@@ -6347,12 +6510,29 @@ deselectAll = "None"selectAll = "Check All"[pageEditor]+dragPreviewAlt = "Dragging"+filePosition = "Position {{position}}"+pageLabel = "Page {{page}}"title = "Page Editor"+[pageEditor.actions]+deletePage = "Delete Page"+insertFileAfter = "Insert File After"+moveLeft = "Move Left"+moveRight = "Move Right"+rotateLeft = "Rotate Left"+rotateRight = "Rotate Right"+splitAfter = "Split After"+[pageEditor.emptyState]body = "Add files to start editing pages"title = "No PDF files loaded"+[pageEditor.fileDropdown]+addFile = "Add File"+selectedCount = "{{selected}}/{{total}} files selected"+untitled = "Untitled"+[pageEditor.toolbar]delete = "Delete Selected"redo = "Redo"@@ -6458,6 +6638,11 @@ label = "Reading Direction:"ltr = "Left to Right"rtl = "Right to Left"+[pageLayout.steps]+advanced = "Advanced settings"+layout = "Layout settings"+marginsBorders = "Margins and borders"+[pageLayout.tooltip.header]title = "Page Layout Guide"@@ -6778,6 +6963,7 @@ teamChangeUnavailable = "Scheduled Team changes could not be loaded. Refresh toteamPending = "Your Team purchase is still processing. Refresh this page shortly."teamProcessing = "Team purchase processing"teamScheduled = "Your Team change is scheduled for {{date}}. Your current capacity stays active until then."+unknownError = "An unknown error occurred"upgradeComplete = "Upgrade Complete"upgradeCompleteMessage = "Your subscription has been upgraded successfully. Your existing license key has been updated."upgradeSuccess = "Payment successful! Your subscription has been upgraded. The license has been updated on your server. You will receive a confirmation email shortly."@@ -6835,6 +7021,14 @@ selectedYearly = "Yearly"selectMonthly = "Select Monthly"selectYearly = "Select Yearly"+[payment.priceDisplay]+basePrice = "Base Price"+perPeriod = "/{{period}}"+perSeat = "Per Seat"+perSeatPeriod = "/seat/{{period}}"+totalSeats_one = "Total ({{count}} seat)"+totalSeats_other = "Total ({{count}} seats)"+[payment.upgradeTeam]title = "Upgrade to Team"@@ -7054,6 +7248,10 @@ style = "Style"tapToPlace = "Tap the page where the text should go"unlock = "Unlock"+[pdfTextEditor.pageView]+pageNumber = "Page {{page}}"+renderFailed = "Failed to render page"+[pdfTextEditor.password]cancel = "Cancel"incorrect = "Incorrect password - try again."@@ -7280,6 +7478,7 @@ title = "Pipeline"contact = "Contact Us"current = "Current Plan"featureComparison = "Feature Comparison"+fetchError = "Failed to fetch pricing data"from = "From"hideComparison = "Hide Feature Comparison"licensedSeats = "Licensed: {{count}} seats"@@ -7295,6 +7494,8 @@ withServer = "+ Team plan"[plan.api]large = "5,000 Credits"medium = "1,000 Credits"+perCredit = "{{price}} per credit"+perCreditWithDiscount = "{{price}} per credit • {{discount}}% discount"small = "500 Credits"xsmall = "100 Credits"@@ -7372,6 +7573,7 @@ usersIncluded = "100 users included"[plan.period]month = "month"+year = "year"[plan.pro]highlight1 = "Unlimited Tool Usage"@@ -9517,6 +9719,7 @@ labelId = "Label ID"labelIdHelp = "The label's GUID, from the Purview portal. Applying a label writes its metadata onto the PDF; it cannot encrypt, which needs the Microsoft client."labelName = "Label name (optional)"labelNameHelp = "Recorded alongside the ID so people and tools can recognise the label."+labelNamePlaceholder = "Confidential"[portal.policies.config.purview.fields.method]help = "Purview distinguishes a label a policy applied from one a person chose."@@ -10579,6 +10782,10 @@ label = "Client ID"description = "Allow users to import files directly from Google Drive"label = "Enable Google Drive File Picker"+[provider.googledrive.errors]+notConfigured = "Google Drive is not configured"+pickerFailed = "Failed to open Google Drive picker"+[provider.oauth2.generic]name = "Generic OAuth2"scope = "SSO"@@ -10826,6 +11033,7 @@ applyWarning = "⚠️ Permanent application, cannot be undone and the data undecolorLabel = "Redaction Color"controlsTitle = "Manual Redaction Controls"instructions = "Select text or draw areas on the PDF to mark content for redaction."+notImplemented = "Manual redaction interface will be available here when implemented."title = "Redaction Tools"[redact.modeSelector]@@ -11153,6 +11361,9 @@ failed = "An error occurred while rotating the PDF."[rotate.preview]title = "Rotation Preview"+[rotate.settings]+title = "Settings"+[rotate.tooltip.controls]text = "Use the rotation buttons to adjust orientation. Left button rotates counterclockwise, right button rotates clockwise. Each click rotates by 90 degrees."title = "Controls"@@ -11171,6 +11382,16 @@ physicalValues = "Physical"scaled = "Scaled"showAllLabels = "Show all labels"+[ruler.units]+cm = "Centimeters (cm)"+ft = "Feet (ft)"+in = "Inches (in)"+km = "Kilometers (km)"+m = "Meters (m)"+mi = "Miles (mi)"+mm = "Millimeters (mm)"+yd = "Yards (yd)"+[sanitize]desc = "Remove potentially harmful elements from PDF files."sanitizationResults = "Sanitization Results"@@ -11235,6 +11456,7 @@ calibrationPaperDistance = "Measured page distance: {{distance}}"calibrationTitle = "Calibrate Scale"calibrationTooltip = "Measure a known distance to calculate the scale automatically"customScale = "Custom Scale"+customUnit = "{{unit}} (custom)"noneSet = "No custom scale set"presets = "Preset Scales"ratio = "Scale Ratio"@@ -11259,6 +11481,9 @@ title = "Extracted Images"[scannerImageSplit.error]failed = "An error occurred while extracting image scans."+[scannerImageSplit.settings]+title = "Settings"+[scannerImageSplit.tooltip]headsUp = "Heads-up"headsUpDesc = "Overlapping photos or backgrounds very close in color to the photos can reduce accuracy-try a lighter or darker background and leave more space."@@ -11326,6 +11551,9 @@ limits = "Limits & Performance"models = "Models & Providers"title = "AI"+[settings.billing]+title = "Billing"+[settings.configuration]advanced = "Advanced"database = "Database"@@ -11667,6 +11895,15 @@ people = "People"teams = "Teams"title = "Workspace"+[setup.error]+loginIncomplete = "Failed to complete login"+noSaasServer = "No SaaS server configured"+noServer = "No server configured"+saasLoginFailed = "SaaS login failed"+saasLoginIncomplete = "Failed to complete SaaS login"+selfHostedLoginFailed = "Self-hosted login failed"+signupIncomplete = "Failed to complete signup"+[setup.login]connectingTo = "Connecting to:"oauthPending = "Opening browser for authentication..."@@ -11710,6 +11947,7 @@ configFetchError = "Failed to fetch server configuration: {{error}}"emptyUrl = "Please enter a server URL"invalidUrl = "Invalid URL format. Please enter a valid URL like https://your-server.com"testFailed = "Connection test failed"+unknown = "Unknown error"unreachable = "Could not connect to server"[setup.server.error.securityDisabled]@@ -11818,6 +12056,7 @@ canvas = "After drawing your signature in the canvas, close the modal then clickimage = "After uploading your signature image above, click anywhere on the PDF to place it."noSignature = "Create a signature above to enable placement tools."paused = "Placement paused"+placeAnnotation = "Click anywhere on the PDF to place your annotation."resumeHint = "Resume placement to click and add your signature."saved = "Select a saved signature above, then click anywhere on the PDF to place it."text = "After entering your name above, click anywhere on the PDF to place your signature."@@ -11971,7 +12210,9 @@ signUpWith = "Sign up with"skip = "Skip"subtitle = "Join Stirling PDF to get started"title = "Create an account"+unableToAccessTool = "Unable to access tool: {{error}}"unexpectedError = "Unexpected error: {{message}}"+unknownError = "Unknown error"[sizes]large = "Large"@@ -12045,6 +12286,14 @@ rightToLeft = "Split right-to-left"description = "Size of output pages for printing"label = "Target Page Size"+[split.poster.pageSize.options]+a3 = "A3 (297 × 420 mm)"+a4 = "A4 (210 × 297 mm)"+a5 = "A5 (148 × 210 mm)"+legal = "Legal (8.5 × 14 in)"+letter = "Letter (8.5 × 11 in)"+tabloid = "Tabloid (11 × 17 in)"+[split.poster.xFactor]description = "Number of columns to split each page into"label = "Horizontal Divisions"@@ -12445,6 +12694,10 @@ XML = "an XML file"XPS = "an XPS document"ZIP = "a ZIP archive"+[toolLoading]+generic = "Loading tool..."+named = "Loading {{toolName}}..."+[toolPanel]alpha = "Alpha"backToAllTools = "Back to all tools"@@ -12549,6 +12802,8 @@ stable = "STABLE"updateAvailable = "Update Available"urgentUpdateAvailable = "Urgent Update"version = "Version"+versionCount_one = "{{count}} version"+versionCount_other = "{{count}} versions"versionHistory = "Version History"viewGuide = "View Guide"whatsNewIn = "What's new in"@@ -12576,6 +12831,7 @@ title = "URL To PDF"aboutUsageAnalytics = "About Usage Analytics"configureSettings = "Configure Analytics Settings"error = "Error loading usage statistics"+loadFailed = "Failed to load usage statistics"noData = "No usage yet"noDataMessage = "Endpoint activity appears here once people start running tools."usageAnalyticsExplanation = "Usage analytics track endpoint requests and tool usage patterns. Combined with the Audit Logging dashboard, you get complete visibility into system activity, performance, and security events."@@ -12870,6 +13126,7 @@ signaturesInvalid = "{{count}} invalid"signaturesUnverified_one = "{{count}} needs review"signaturesUnverified_other = "{{count}} need review"signaturesValid = "{{count}} fully valid"+thumbnailAlt = "{{fileName}} thumbnail"title = "Signature Validation Report"[validateSignature.report.fields]@@ -12907,6 +13164,7 @@ lastPage = "Last Page"loadingEngine = "Loading PDF Engine..."moreOptions = "More"nextPage = "Next Page"+noPdfProvided = "No PDF provided"onlyPdfSupported = "This file format is not supported for preview."pageNavigation = "Page navigation"previousPage = "Previous Page"@@ -12944,8 +13202,17 @@ collapseAll = "Collapse all bookmarks"editorOnly = "This document's bookmarks can only be edited in the editor."empty = "No bookmarks in this document"expandAll = "Expand all bookmarks"+loadFailed = "Failed to load bookmarks"+loading = "Loading bookmarks..."+noDocument = "Open a PDF to view its bookmarks."+noSearchResults = "No bookmarks match your search"+openEditor = "Need to reorder or nest? Open the Bookmark Editor"+pageLabel = "Page"+pageNumber = "Page {{page}}"+saveFailed = "Failed to save bookmark"searchPlaceholder = "Search bookmarks"title = "Bookmarks"+untitled = "Untitled"[viewer.comments]addComment = "Add comment"@@ -12993,16 +13260,26 @@ unsavedDesc = "You have unsaved changes"[viewer.layers]closeSidebar = "Close layers sidebar"+empty = "This document has no layers."hideAll = "Hide all layers"+loadFailed = "Failed to load layers."+loading = "Loading layers..."+noDocument = "Open a PDF to view its layers."+readFailed = "Failed to read PDF layers"showAll = "Show all layers"title = "Layers"[viewer.link]delete = "Delete link"+goTo = "Go to {{label}}"+open = "Open Link"+openAria = "Open link"+page = "Page {{page}}"[viewer.nonPdf]columnDefault = "Column {{index}}"convertToPdf = "Convert to PDF"+copied = "Copied"csvStats = "{{rows}} rows · {{columns}} columns · {{size}}"emptyFile = "Empty file"htmlHidePreview = "Hide preview"@@ -13013,6 +13290,8 @@ htmlShowPreview = "Show preview anyway"invalidJson = "Invalid JSON - showing raw content"lineNumbers = "Line numbers"loading = "Loading..."+noFile = "No file loaded"+previewUnavailable = "Preview not available for this file type"renderMarkdown = "Render markdown"sortedBy = "Sorted by: {{column}}"textStats = "{{lines}} lines · {{size}}"@@ -13039,11 +13318,28 @@ next = "Next result"previous = "Previous result"resultsOf = "of {{total}}"+[viewer.sidebar]+close = "Close sidebar"+searchPlaceholder = "Search..."+[viewer.signature]delete = "Delete signature"+previewAlt = "Signature preview"++[viewer.signatureField]+badge = "Signature"+fieldTitle = "Signature field: {{name}}"+signed = "Signed"+signedWithReason = "Signed: {{reason}}"+unsignedFieldTitle = "Unsigned signature field: {{name}}"+withTime = "{{label}} ({{time}})"[viewer.thumbnails]closeSidebar = "Close thumbnails sidebar"+failed = "Failed"+pageNumber = "Page {{page}}"+thumbnailAlt = "Page {{page}} thumbnail"+title = "Pages"[viewPdf]tags = "view,read,annotate,text,image,highlight,edit"@@ -13253,6 +13549,10 @@ certTypeServer = "Server Certificate (if available)"completedDeclined = "You have declined this document."completedSigned = "You have signed this document."decline = "Decline"+declineConfirm = "Are you sure you want to decline signing this document?"+declineFailed = "Failed to decline: {{error}}"+declineSuccess = "You have declined this signing request."+defaultReason = "Document Signing"downloadDocument = "Download Document"dueDate = "Due Date: {{date}}"errorTitle = "Error"@@ -13263,6 +13563,7 @@ locationPlaceholder = "e.g., San Francisco, CA"pageNumber = "Page Number (optional)"reason = "Reason"reasonPlaceholder = "e.g., Document approval"+selectCertificateFile = "Please select a certificate file"sessionNotFound = "Session not found or access denied."signDocument = "Sign Document"statusDeclined = "Declined"@@ -13270,7 +13571,9 @@ statusNotified = "Notified"statusPending = "Pending"statusSigned = "Signed"statusViewed = "Viewed"+submitFailed = "Failed to submit signature: {{error}}"submitSignature = "Submit Signature"+submitSuccess = "Signature submitted successfully!"[workspace]title = "Workspace"diff --git a/frontend/editor/src/cloud/components/shared/config/cloudConfigNavSections.tsx b/frontend/editor/src/cloud/components/shared/config/cloudConfigNavSections.tsxindex ad7cb6c13d..2d3e97cb76 100644--- a/frontend/editor/src/cloud/components/shared/config/cloudConfigNavSections.tsx+++ b/frontend/editor/src/cloud/components/shared/config/cloudConfigNavSections.tsx@@ -53,7 +53,7 @@ export function createCloudTeamNavItem(t: Translate): ConfigNavItem {/** Billing nav section wrapping the Plan item, for leaves that group it (saas). */export function createCloudBillingSection(t: Translate): ConfigNavSection {return {- title: "Billing",+ title: t("settings.billing.title", "Billing"),items: [createCloudPlanNavItem(t)],};}diff --git a/frontend/editor/src/core/components/StorageStatsCard.tsx b/frontend/editor/src/core/components/StorageStatsCard.tsxindex 9e5d7bdd3d..bd44eb8da6 100644--- a/frontend/editor/src/core/components/StorageStatsCard.tsx+++ b/frontend/editor/src/core/components/StorageStatsCard.tsx@@ -69,7 +69,7 @@ const StorageStatsCard: React.FC<StorageStatsCardProps> = ({</Button>)}<Button variant="secondary" size="sm" onClick={onReloadFiles}>- Reload Files+ {t("fileManager.reloadFiles", "Reload Files")}</Button></Group></Group>diff --git a/frontend/editor/src/core/components/annotation/shared/BaseAnnotationTool.tsx b/frontend/editor/src/core/components/annotation/shared/BaseAnnotationTool.tsxindex e611ba4b83..b720f9fd43 100644--- a/frontend/editor/src/core/components/annotation/shared/BaseAnnotationTool.tsx+++ b/frontend/editor/src/core/components/annotation/shared/BaseAnnotationTool.tsx@@ -112,7 +112,10 @@ export const BaseAnnotationTool: React.FC<BaseAnnotationToolProps> = ({title={t("sign.instructions.title", "How to add signature")}><Text size="sm">- Click anywhere on the PDF to place your annotation.+ {t(+ "sign.instructions.placeAnnotation",+ "Click anywhere on the PDF to place your annotation.",+ )}</Text></Alert>diff --git a/frontend/editor/src/core/components/docs/MarkdownDoc.tsx b/frontend/editor/src/core/components/docs/MarkdownDoc.tsxindex 212993e8a4..7c9064c151 100644--- a/frontend/editor/src/core/components/docs/MarkdownDoc.tsx+++ b/frontend/editor/src/core/components/docs/MarkdownDoc.tsx@@ -4,6 +4,7 @@ import ReactMarkdown, {type Components,} from "react-markdown";import remarkGfm from "remark-gfm";+import { useTranslation } from "react-i18next";import { Button } from "@app/ui";import { makeSlugger } from "@app/docs/headings";@@ -30,6 +31,7 @@ function urlTransform(url: string): string {*/function CopyButton({ text }: { text: string }) {+ const { t } = useTranslation();const [copied, setCopied] = useState(false);return (<Button@@ -43,7 +45,7 @@ function CopyButton({ text }: { text: string }) {})}>- {copied ? "✓ Copied" : "Copy"}+ {copied ? `✓ ${t("common.copied", "Copied!")}` : t("common.copy", "Copy")}</Button>);}diff --git a/frontend/editor/src/core/components/fileEditor/FileEditor.tsx b/frontend/editor/src/core/components/fileEditor/FileEditor.tsxindex eeee41a1f0..25d2141bd3 100644--- a/frontend/editor/src/core/components/fileEditor/FileEditor.tsx+++ b/frontend/editor/src/core/components/fileEditor/FileEditor.tsx@@ -2,6 +2,7 @@ import { useState, useCallback, useMemo, useEffect, useRef } from "react";import { flushSync } from "react-dom";import { Center, Box, LoadingOverlay } from "@mantine/core";import { Dropzone } from "@mantine/dropzone";+import { useTranslation } from "react-i18next";import {useFileSelection,useFileState,@@ -36,6 +37,7 @@ const FileEditor = ({toolMode = false,supportedExtensions = ["pdf"],}: FileEditorProps) => {+ const { t } = useTranslation();const policyFileBadges = usePolicyFileBadges();const isFileSupported = useCallback(@@ -83,14 +85,17 @@ const FileEditor = ({},[],);- const showError = useCallback((message: string) => {- alert({- alertType: "error",- title: "Error",- body: message,- expandable: true,- });- }, []);+ const showError = useCallback(+ (message: string) => {+ alert({+ alertType: "error",+ title: t("common.error", "Error"),+ body: message,+ expandable: true,+ });+ },+ [t],+ );const { selectedTool } = useToolWorkflow();@@ -117,16 +122,33 @@ const FileEditor = ({setSelectedFiles(nowSelectedIds.slice(-maxAllowed));}}- showStatus(`Added ${uploadedFiles.length} file(s)`, "success");+ showStatus(+ t("fileEditor.filesAdded", {+ count: uploadedFiles.length,+ defaultValue_one: "Added {{count}} file",+ defaultValue_other: "Added {{count}} files",+ }),+ "success",+ );}} catch (err) {const errorMessage =- err instanceof Error ? err.message : "Failed to process files";+ err instanceof Error+ ? err.message+ : t("fileEditor.processFilesFailed", "Failed to process files");showError(errorMessage);console.error("File processing error:", err);}},- [addFiles, showStatus, showError, selectors, maxAllowed, setSelectedFiles],+ [+ addFiles,+ showStatus,+ showError,+ selectors,+ maxAllowed,+ setSelectedFiles,+ t,+ ],);useEffect(() => {@@ -189,9 +211,15 @@ const FileEditor = ({}const moveCount = filesToMove.length;- showStatus(`${moveCount > 1 ? `${moveCount} files` : "File"} reordered`);+ showStatus(+ t("fileEditor.filesReordered", {+ count: moveCount,+ defaultValue_one: "File reordered",+ defaultValue_other: "{{count}} files reordered",+ }),+ );},- [reorderFiles, showStatus],+ [reorderFiles, showStatus, t],);const handleCloseFile = useCallback(@@ -266,14 +294,23 @@ const FileEditor = ({alert({alertType: "success",- title: `Extracted ${result.extractedStubs.length} file(s) from ${file.name}`,+ title: t("fileEditor.unzip.extracted", {+ count: result.extractedStubs.length,+ name: file.name,+ defaultValue_one: "Extracted {{count}} file from {{name}}",+ defaultValue_other: "Extracted {{count}} files from {{name}}",+ }),expandable: false,durationMs: 3500,});} else {alert({alertType: "error",- title: `Failed to extract files from ${file.name}`,+ title: t(+ "fileEditor.unzip.failed",+ "Failed to extract files from {{name}}",+ { name: file.name },+ ),body: result.errors.join("\n"),expandable: true,durationMs: 3500,@@ -283,14 +320,16 @@ const FileEditor = ({console.error("Failed to unzip file:", error);alert({alertType: "error",- title: `Error unzipping ${file.name}`,+ title: t("fileEditor.unzip.error", "Error unzipping {{name}}", {+ name: file.name,+ }),expandable: false,durationMs: 3500,});}}},- [selectors, fileActions, removeFiles],+ [selectors, fileActions, removeFiles, t],);const handleViewFile = useCallback(@@ -305,16 +344,30 @@ const FileEditor = ({[setActiveFileId, setActiveFileIndex, navActions.setWorkbench],);- const handleLoadFromStorage = useCallback(async (selectedFiles: File[]) => {- if (selectedFiles.length === 0) return;+ const handleLoadFromStorage = useCallback(+ async (selectedFiles: File[]) => {+ if (selectedFiles.length === 0) return;- try {- showStatus(`Loaded ${selectedFiles.length} files from storage`);- } catch (err) {- console.error("Error loading files from storage:", err);- showError("Failed to load some files from storage");- }- }, []);+ try {+ showStatus(+ t("fileEditor.loadedFromStorage", {+ count: selectedFiles.length,+ defaultValue_one: "Loaded {{count}} file from storage",+ defaultValue_other: "Loaded {{count}} files from storage",+ }),+ );+ } catch (err) {+ console.error("Error loading files from storage:", err);+ showError(+ t(+ "fileEditor.loadFromStorageFailed",+ "Failed to load some files from storage",+ ),+ );+ }+ },+ [showStatus, showError, t],+ );return (<Dropzonediff --git a/frontend/editor/src/core/components/fileEditor/FileEditorThumbnail.tsx b/frontend/editor/src/core/components/fileEditor/FileEditorThumbnail.tsxindex 72d2e17f3e..b60619601d 100644--- a/frontend/editor/src/core/components/fileEditor/FileEditorThumbnail.tsx+++ b/frontend/editor/src/core/components/fileEditor/FileEditorThumbnail.tsx@@ -239,12 +239,12 @@ const FileEditorThumbnail = ({onCloseFile(file.id);alert({alertType: "neutral",- title: `Closed ${file.name}`,+ title: t("fileEditor.closedFile", "Closed {{name}}", { name: file.name }),expandable: false,durationMs: 3500,});setShowCloseModal(false);- }, [file.id, file.name, onCloseFile]);+ }, [file.id, file.name, onCloseFile, t]);const handleSaveAndClose = useCallback(async () => {const fileToSave = selectors.getFile(file.id);@@ -269,8 +269,10 @@ const FileEditorThumbnail = ({console.error(`Failed to save ${file.name}:`, error);alert({alertType: "error",- title: "Save failed",- body: `Could not save ${file.name}`,+ title: t("fileEditor.saveFailed", "Save failed"),+ body: t("fileEditor.couldNotSave", "Could not save {{name}}", {+ name: file.name,+ }),expandable: true,});setShowCloseModal(false);@@ -280,7 +282,9 @@ const FileEditorThumbnail = ({onCloseFile(file.id);alert({alertType: "success",- title: `Saved and closed ${file.name}`,+ title: t("fileEditor.savedAndClosed", "Saved and closed {{name}}", {+ name: file.name,+ }),expandable: false,durationMs: 3500,});@@ -292,6 +296,7 @@ const FileEditorThumbnail = ({onCloseFile,selectors,fileActions,+ t,]);const [showVersionHistory, setShowVersionHistory] = useState(false);@@ -351,7 +356,9 @@ const FileEditorThumbnail = ({unpinFile(actualFile);alert({alertType: "neutral",- title: `Unpinned ${file.name}`,+ title: t("fileEditor.unpinnedFile", "Unpinned {{name}}", {+ name: file.name,+ }),expandable: false,durationMs: 3000,});@@ -359,7 +366,9 @@ const FileEditorThumbnail = ({pinFile(actualFile);alert({alertType: "success",- title: `Pinned ${file.name}`,+ title: t("fileEditor.pinnedFile", "Pinned {{name}}", {+ name: file.name,+ }),expandable: false,durationMs: 3000,});@@ -424,7 +433,9 @@ const FileEditorThumbnail = ({onUnzipFile(file.id);alert({alertType: "success",- title: `Unzipping ${file.name}`,+ title: t("fileEditor.unzipping", "Unzipping {{name}}", {+ name: file.name,+ }),expandable: false,durationMs: 2500,});diff --git a/frontend/editor/src/core/components/mobileSign/MobileDrawCanvas.tsx b/frontend/editor/src/core/components/mobileSign/MobileDrawCanvas.tsxindex 8461727240..17d58fc3e6 100644--- a/frontend/editor/src/core/components/mobileSign/MobileDrawCanvas.tsx+++ b/frontend/editor/src/core/components/mobileSign/MobileDrawCanvas.tsx@@ -5,6 +5,7 @@ import {useImperativeHandle,useRef,} from "react";+import { useTranslation } from "react-i18next";/*** Touch-first signature canvas for the phone `/mobile-sign` page.@@ -76,6 +77,7 @@ export const MobileDrawCanvas = forwardRef<MobileDrawCanvasHandle,MobileDrawCanvasProps>(function MobileDrawCanvas({ penColor, penSize, onHasInkChange }, ref) {+ const { t } = useTranslation();const canvasRef = useRef<HTMLCanvasElement>(null);const strokesRef = useRef<Stroke[]>([]);const activeStrokeRef = useRef<Stroke | null>(null);@@ -227,7 +229,7 @@ export const MobileDrawCanvas = forwardRef<touchAction: "none",cursor: "crosshair",}}- aria-label="Signature drawing area"+ aria-label={t("mobileSign.drawingArea", "Signature drawing area")}/>);});diff --git a/frontend/editor/src/core/components/onboarding/slides/SecurityCheckSlide.tsx b/frontend/editor/src/core/components/onboarding/slides/SecurityCheckSlide.tsxindex 7c34937f7a..38082941a1 100644--- a/frontend/editor/src/core/components/onboarding/slides/SecurityCheckSlide.tsx+++ b/frontend/editor/src/core/components/onboarding/slides/SecurityCheckSlide.tsx@@ -17,7 +17,7 @@ export default function SecurityCheckSlide({}: SecurityCheckSlideProps): SlideConfig {return {key: "security-check",- title: "Security Check",+ title: i18n.t("onboarding.securityCheck.title", "Security Check"),body: (<div className={styles.securitySlideContent}><div className={styles.securityCard}>diff --git a/frontend/editor/src/core/components/pageEditor/DragDropGrid.tsx b/frontend/editor/src/core/components/pageEditor/DragDropGrid.tsxindex 2a4e1fda36..ecb70967fd 100644--- a/frontend/editor/src/core/components/pageEditor/DragDropGrid.tsx+++ b/frontend/editor/src/core/components/pageEditor/DragDropGrid.tsx@@ -6,6 +6,7 @@ import React, {useMemo,} from "react";import { Box } from "@mantine/core";+import { useTranslation } from "react-i18next";import { useVirtualizer } from "@tanstack/react-virtual";import { GRID_CONSTANTS } from "@app/components/pageEditor/constants";import styles from "@app/components/pageEditor/DragDropGrid.module.css";@@ -387,6 +388,7 @@ const DragDropGrid = <T extends DragDropItem>({selectedPageIds,onVisibleItemsChange,}: DragDropGridProps<T>) => {+ const { t } = useTranslation();const itemRefs = useRef<Map<string, HTMLDivElement>>(new Map());const containerRef = useRef<HTMLDivElement>(null);@@ -999,7 +1001,7 @@ const DragDropGrid = <T extends DragDropItem>({{dragPreview ? (<imgsrc={dragPreview.src}- alt="Dragging"+ alt={t("pageEditor.dragPreviewAlt", "Dragging")}style={{width: `calc(20rem * ${zoomLevel})`,height: `calc(20rem * ${zoomLevel})`,diff --git a/frontend/editor/src/core/components/pageEditor/FileThumbnail.tsx b/frontend/editor/src/core/components/pageEditor/FileThumbnail.tsxindex 59915189a8..9a450b03fc 100644--- a/frontend/editor/src/core/components/pageEditor/FileThumbnail.tsx+++ b/frontend/editor/src/core/components/pageEditor/FileThumbnail.tsx@@ -248,7 +248,9 @@ const FileThumbnail = ({{/* Centered index */}<divclassName={styles.headerIndex}- aria-label={`Position ${index + 1}`}+ aria-label={t("pageEditor.filePosition", "Position {{position}}", {+ position: index + 1,+ })}>{index + 1}</div>diff --git a/frontend/editor/src/core/components/pageEditor/PageThumbnail.tsx b/frontend/editor/src/core/components/pageEditor/PageThumbnail.tsxindex e6ad547c1d..68ffd2e65c 100644--- a/frontend/editor/src/core/components/pageEditor/PageThumbnail.tsx+++ b/frontend/editor/src/core/components/pageEditor/PageThumbnail.tsx@@ -6,6 +6,7 @@ import React, {useMemo,} from "react";import { Text, Checkbox } from "@mantine/core";+import { useTranslation } from "react-i18next";import { useIsMobile } from "@app/hooks/useIsMobile";import { Icon } from "@app/ui/Icon";import { PDFPage, PDFDocument } from "@app/types/pageEditor";@@ -94,6 +95,7 @@ const PageThumbnail: React.FC<PageThumbnailProps> = ({zoomLevel = 1.0,justMoved = false,}: PageThumbnailProps) => {+ const { t } = useTranslation();const pageIndex = page.pageNumber - 1;const isSelected = Array.isArray(selectedPageIds)? selectedPageIds.includes(page.id)@@ -321,7 +323,7 @@ const PageThumbnail: React.FC<PageThumbnailProps> = ({{id: "move-left",icon: <Icon name="arrow-left" size={20} />,- label: "Move Left",+ label: t("pageEditor.actions.moveLeft", "Move Left"),onClick: (e) => {e.stopPropagation();if (pageIndex > 0 && !isAnimating) {@@ -334,7 +336,7 @@ const PageThumbnail: React.FC<PageThumbnailProps> = ({{id: "move-right",icon: <Icon name="arrow-right" size={20} />,- label: "Move Right",+ label: t("pageEditor.actions.moveRight", "Move Right"),onClick: (e) => {e.stopPropagation();if (pageIndex < totalPages - 1 && !isAnimating) {@@ -348,33 +350,33 @@ const PageThumbnail: React.FC<PageThumbnailProps> = ({{id: "rotate-left",icon: <Icon name="rotate-ccw" size={20} />,- label: "Rotate Left",+ label: t("pageEditor.actions.rotateLeft", "Rotate Left"),onClick: handleRotateLeft,},{id: "rotate-right",icon: <Icon name="rotate-cw" size={20} />,- label: "Rotate Right",+ label: t("pageEditor.actions.rotateRight", "Rotate Right"),onClick: handleRotateRight,},{id: "delete",icon: <Icon name="trash" size={20} />,- label: "Delete Page",+ label: t("pageEditor.actions.deletePage", "Delete Page"),onClick: handleDelete,color: "red",},{id: "split",icon: <Icon name="scissors" size={20} />,- label: "Split After",+ label: t("pageEditor.actions.splitAfter", "Split After"),onClick: handleSplit,hidden: pageIndex >= totalPages - 1,},{id: "insert",icon: <Icon name="plus" size={20} />,- label: "Insert File After",+ label: t("pageEditor.actions.insertFileAfter", "Insert File After"),onClick: handleInsertFileAfter,},],@@ -390,6 +392,7 @@ const PageThumbnail: React.FC<PageThumbnailProps> = ({handleInsertFileAfter,onReorderPages,onSetStatus,+ t,],);@@ -505,7 +508,9 @@ const PageThumbnail: React.FC<PageThumbnailProps> = ({<imgclassName="ph-no-capture"src={thumbnailUrl}- alt={`Page ${page.pageNumber}`}+ alt={t("pageEditor.pageLabel", "Page {{page}}", {+ page: page.pageNumber,+ })}draggable={false}data-original-rotation={page.rotation}style={{@@ -524,7 +529,9 @@ const PageThumbnail: React.FC<PageThumbnailProps> = ({📄</Text><Text size="xs" c="dimmed" mt={4}>- Page {page.pageNumber}+ {t("pageEditor.pageLabel", "Page {{page}}", {+ page: page.pageNumber,+ })}</Text></div>)}diff --git a/frontend/editor/src/core/components/pageEditor/bulkSelectionPanel/SelectPages.tsx b/frontend/editor/src/core/components/pageEditor/bulkSelectionPanel/SelectPages.tsxindex d2daa6499c..5553579f59 100644--- a/frontend/editor/src/core/components/pageEditor/bulkSelectionPanel/SelectPages.tsx+++ b/frontend/editor/src/core/components/pageEditor/bulkSelectionPanel/SelectPages.tsx@@ -1,6 +1,7 @@import { useState } from "react";import { Text, NumberInput, Group } from "@mantine/core";import { Button } from "@app/ui/Button";+import { useTranslation } from "react-i18next";import classes from "@app/components/pageEditor/bulkSelectionPanel/BulkSelectionPanel.module.css";interface SelectPagesProps {@@ -25,6 +26,7 @@ const SelectPages = ({onRangeEndChange,rangeEndPlaceholder,}: SelectPagesProps) => {+ const { t } = useTranslation();const [value, setValue] = useState<number | "">("");const [error, setError] = useState<string | null>(null);@@ -100,7 +102,7 @@ const SelectPages = ({onClick={handleApply}disabled={isDisabled}>- Apply+ {t("apply", "Apply")}</Button></Group></div>diff --git a/frontend/editor/src/core/components/pageEditor/bulkSelectionPanel/SelectedPagesDisplay.tsx b/frontend/editor/src/core/components/pageEditor/bulkSelectionPanel/SelectedPagesDisplay.tsxindex 96c65f6485..672bb583c5 100644--- a/frontend/editor/src/core/components/pageEditor/bulkSelectionPanel/SelectedPagesDisplay.tsx+++ b/frontend/editor/src/core/components/pageEditor/bulkSelectionPanel/SelectedPagesDisplay.tsx@@ -1,4 +1,5 @@import { Text } from "@mantine/core";+import { useTranslation } from "react-i18next";import classes from "@app/components/pageEditor/bulkSelectionPanel/BulkSelectionPanel.module.css";interface SelectedPagesDisplayProps {@@ -12,6 +13,8 @@ const SelectedPagesDisplay = ({displayDocument,syntaxError,}: SelectedPagesDisplayProps) => {+ const { t } = useTranslation();+if (selectedPageIds.length === 0 && !syntaxError) {return null;}@@ -24,17 +27,24 @@ const SelectedPagesDisplay = ({</Text>) : (<Text size="sm" c="dimmed" className={classes.selectedText}>- Selected: {selectedPageIds.length} pages (- {displayDocument- ? selectedPageIds- .map((id) => {- const page = displayDocument.pages.find((p) => p.id === id);- return page?.pageNumber || 0;- })- .filter((n) => n > 0)- .join(", ")- : ""}- )+ {t(+ "bulkSelection.selectedPages",+ "Selected: {{count}} pages ({{pages}})",+ {+ count: selectedPageIds.length,+ pages: displayDocument+ ? selectedPageIds+ .map((id) => {+ const page = displayDocument.pages.find(+ (p) => p.id === id,+ );+ return page?.pageNumber || 0;+ })+ .filter((n) => n > 0)+ .join(", ")+ : "",+ },+ )}</Text>)}</div>diff --git a/frontend/editor/src/core/components/shared/DropdownListWithFooter.tsx b/frontend/editor/src/core/components/shared/DropdownListWithFooter.tsxindex 71b3922930..cd82bbbe16 100644--- a/frontend/editor/src/core/components/shared/DropdownListWithFooter.tsx+++ b/frontend/editor/src/core/components/shared/DropdownListWithFooter.tsx@@ -108,7 +108,9 @@ const DropdownListWithFooter: React.FC<DropdownListWithFooterProps> = ({);return selectedItem?.name || selectedValues[0];} else {- return `${selectedValues.length} selected`;+ return t("dropdownList.selectedCount", "{{count}} selected", {+ count: selectedValues.length,+ });}};diff --git a/frontend/editor/src/core/components/shared/FileGrid.tsx b/frontend/editor/src/core/components/shared/FileGrid.tsxindex c37bc2c7f1..efa0a82084 100644--- a/frontend/editor/src/core/components/shared/FileGrid.tsx+++ b/frontend/editor/src/core/components/shared/FileGrid.tsx@@ -173,7 +173,11 @@ const FileGrid = ({{hasMoreFiles && onShowAll && (<Group justify="center" mt="md"><Button variant="secondary" onClick={onShowAll}>- {t("fileManager.showAll", "Show All")} ({sortedFiles.length} files)+ {t("fileManager.showAllCount", {+ count: sortedFiles.length,+ defaultValue_one: "Show All ({{count}} file)",+ defaultValue_other: "Show All ({{count}} files)",+ })}</Button></Group>)}diff --git a/frontend/editor/src/core/components/shared/FilePickerModal.tsx b/frontend/editor/src/core/components/shared/FilePickerModal.tsxindex 0372ea7bd6..10fdfa228a 100644--- a/frontend/editor/src/core/components/shared/FilePickerModal.tsx+++ b/frontend/editor/src/core/components/shared/FilePickerModal.tsx@@ -152,10 +152,18 @@ const FilePickerModal = ({{/* Selection controls */}<Group justify="space-between"><Text size="sm" c="dimmed">- {storedFiles.length}{" "}- {t("fileUpload.filesAvailable", "files available")}+ {t("fileUpload.filesAvailableCount", {+ count: storedFiles.length,+ defaultValue_one: "{{count}} file available",+ defaultValue_other: "{{count}} files available",+ })}{selectedFileIds.length > 0 && (- <> • {selectedFileIds.length} selected</>+ <>+ {" • "}+ {t("fileUpload.selectedCount", "{{count}} selected", {+ count: selectedFileIds.length,+ })}+ </>)}</Text><Group gap="xs">diff --git a/frontend/editor/src/core/components/shared/PageEditorFileDropdown.tsx b/frontend/editor/src/core/components/shared/PageEditorFileDropdown.tsxindex bd8fc784ef..0c9aa31a75 100644--- a/frontend/editor/src/core/components/shared/PageEditorFileDropdown.tsx+++ b/frontend/editor/src/core/components/shared/PageEditorFileDropdown.tsx@@ -1,5 +1,6 @@import React from "react";import { Menu, Loader, Group, Text, Checkbox } from "@mantine/core";+import { useTranslation } from "react-i18next";import { Icon } from "@app/ui/Icon";import FitText from "@app/components/shared/FitText";import { getFileColorWithOpacity } from "@app/components/pageEditor/fileColors";@@ -32,6 +33,7 @@ const FileMenuItem: React.FC<FileMenuItemProps> = ({onToggleSelection,onReorder,}) => {+ const { t } = useTranslation();const {itemRef,isDragging,@@ -47,7 +49,8 @@ const FileMenuItem: React.FC<FileMenuItemProps> = ({onReorder,});- const itemName = file?.name || "Untitled";+ const itemName =+ file?.name || t("pageEditor.fileDropdown.untitled", "Untitled");const fileColorBorder = getFileColorWithOpacity(colorIndex, 1);const fileColorBorderHover = getFileColorWithOpacity(colorIndex, 1.0);@@ -165,6 +168,7 @@ export const PageEditorFileDropdown: React.FC<PageEditorFileDropdownProps> = ({selectedCount,totalCount,}) => {+ const { t } = useTranslation();const { openFilesModal } = useFilesModalContext();return (@@ -185,7 +189,11 @@ export const PageEditorFileDropdown: React.FC<PageEditorFileDropdownProps> = ({<Icon name="layout-dashboard" size="1.4rem" />)}<span className="ph-no-capture">- {selectedCount}/{totalCount} files selected+ {t(+ "pageEditor.fileDropdown.selectedCount",+ "{{selected}}/{{total}} files selected",+ { selected: selectedCount, total: totalCount },+ )}</span><Icon name="chevron-down" size={20} /></div>@@ -249,7 +257,7 @@ export const PageEditorFileDropdown: React.FC<PageEditorFileDropdownProps> = ({style={{ color: "var(--mantine-color-text)" }}className="ph-no-capture">- Add File+ {t("pageEditor.fileDropdown.addFile", "Add File")}</Text></Group></div>diff --git a/frontend/editor/src/core/components/shared/UpdateModal.tsx b/frontend/editor/src/core/components/shared/UpdateModal.tsxindex 61fe724050..55886c25ea 100644--- a/frontend/editor/src/core/components/shared/UpdateModal.tsx+++ b/frontend/editor/src/core/components/shared/UpdateModal.tsx@@ -741,7 +741,11 @@ function VersionHistory({{t("update.versionHistory", "Version History")}</Text><Text size="xs" c="dimmed">- {versions.length} {versions.length === 1 ? "version" : "versions"}+ {t("update.versionCount", {+ count: versions.length,+ defaultValue_one: "{{count}} version",+ defaultValue_other: "{{count}} versions",+ })}</Text></Group><Stack gap={0}>diff --git a/frontend/editor/src/core/components/shared/filePreview/DocumentThumbnail.tsx b/frontend/editor/src/core/components/shared/filePreview/DocumentThumbnail.tsxindex 03ba611656..e35b5c458c 100644--- a/frontend/editor/src/core/components/shared/filePreview/DocumentThumbnail.tsx+++ b/frontend/editor/src/core/components/shared/filePreview/DocumentThumbnail.tsx@@ -1,5 +1,6 @@import React from "react";import { Box, Center, Loader, Stack, Text } from "@mantine/core";+import { useTranslation } from "react-i18next";import { Icon } from "@app/ui/Icon";import { getFileTypeIcon } from "@app/components/shared/filePreview/getFileTypeIcon";import { StirlingFileStub } from "@app/types/fileContext";@@ -31,6 +32,7 @@ const DocumentThumbnail: React.FC<DocumentThumbnailProps> = ({onClick,children,}) => {+ const { t } = useTranslation();if (!file) return null;const containerStyle: React.CSSProperties = {@@ -51,7 +53,9 @@ const DocumentThumbnail: React.FC<DocumentThumbnailProps> = ({<PrivateContent><imgsrc={thumbnail}- alt={`Preview of ${file.name}`}+ alt={t("filePreview.previewOf", "Preview of {{name}}", {+ name: file.name,+ })}className={imgClassName}style={imgClassName@@ -108,7 +112,7 @@ const DocumentThumbnail: React.FC<DocumentThumbnailProps> = ({borderRadius: "6px",}}>- Locked+ {t("filePreview.locked", "Locked")}</span></div>{children}@@ -127,7 +131,7 @@ const DocumentThumbnail: React.FC<DocumentThumbnailProps> = ({><Loader size="sm" /><Text size="xs" c="dimmed">- Loading thumbnail...+ {t("filePreview.loadingThumbnail", "Loading thumbnail...")}</Text></Stack>{children}diff --git a/frontend/editor/src/core/components/shared/wetSignature/TypeSignatureText.tsx b/frontend/editor/src/core/components/shared/wetSignature/TypeSignatureText.tsxindex f6d858c29d..c76e2261d6 100644--- a/frontend/editor/src/core/components/shared/wetSignature/TypeSignatureText.tsx+++ b/frontend/editor/src/core/components/shared/wetSignature/TypeSignatureText.tsx@@ -74,7 +74,13 @@ export const TypeSignatureText: React.FC<TypeSignatureTextProps> = ({{ value: "Georgia", label: "Georgia" },{ value: "Verdana", label: "Verdana" },{ value: "Comic Sans MS", label: "Comic Sans MS" },- { value: "Brush Script MT", label: "Brush Script MT (cursive)" },+ {+ value: "Brush Script MT",+ label: t(+ "certSign.collab.signRequest.fontBrushScript",+ "Brush Script MT (cursive)",+ ),+ },];return (diff --git a/frontend/editor/src/core/components/shared/wetSignature/UploadSignatureImage.tsx b/frontend/editor/src/core/components/shared/wetSignature/UploadSignatureImage.tsxindex 6041ec9c04..0dbb4753fb 100644--- a/frontend/editor/src/core/components/shared/wetSignature/UploadSignatureImage.tsx+++ b/frontend/editor/src/core/components/shared/wetSignature/UploadSignatureImage.tsx@@ -92,7 +92,10 @@ export const UploadSignatureImage: React.FC<UploadSignatureImageProps> = ({><Imagesrc={signature}- alt="Signature"+ alt={t(+ "certSign.collab.signRequest.signatureImageAlt",+ "Signature",+ )}fit="contain"style={{ maxHeight: "150px", maxWidth: "100%" }}/>diff --git a/frontend/editor/src/core/components/tools/ToolLoadingFallback.tsx b/frontend/editor/src/core/components/tools/ToolLoadingFallback.tsxindex 442715f348..f46ecd5ae3 100644--- a/frontend/editor/src/core/components/tools/ToolLoadingFallback.tsx+++ b/frontend/editor/src/core/components/tools/ToolLoadingFallback.tsx@@ -1,16 +1,20 @@import { Center, Stack, Loader, Text } from "@mantine/core";+import { useTranslation } from "react-i18next";export default function ToolLoadingFallback({toolName,}: {toolName?: string;}) {+ const { t } = useTranslation();return (<Center h="100%" w="100%"><Stack align="center" gap="md"><Loader size="lg" /><Text c="dimmed" size="sm">- {toolName ? `Loading ${toolName}...` : "Loading tool..."}+ {toolName+ ? t("toolLoading.named", "Loading {{toolName}}...", { toolName })+ : t("toolLoading.generic", "Loading tool...")}</Text></Stack></Center>diff --git a/frontend/editor/src/core/components/tools/addPageNumbers/PageNumberPreview.tsx b/frontend/editor/src/core/components/tools/addPageNumbers/PageNumberPreview.tsxindex 9991c4b849..c4b2448315 100644--- a/frontend/editor/src/core/components/tools/addPageNumbers/PageNumberPreview.tsx+++ b/frontend/editor/src/core/components/tools/addPageNumbers/PageNumberPreview.tsx@@ -243,7 +243,7 @@ export default function PageNumberPreview({<PrivateContent><imgsrc={pageThumbnail}- alt="page preview"+ alt={t("addPageNumbers.pagePreviewAlt", "Page preview")}className={styles.pageThumbnail}draggable={false}/>diff --git a/frontend/editor/src/core/components/tools/addStamp/StampPreview.tsx b/frontend/editor/src/core/components/tools/addStamp/StampPreview.tsxindex dc7c1ee1ad..08fecedf32 100644--- a/frontend/editor/src/core/components/tools/addStamp/StampPreview.tsx+++ b/frontend/editor/src/core/components/tools/addStamp/StampPreview.tsx@@ -384,7 +384,7 @@ export default function StampPreview({<PrivateContent><imgsrc={pageThumbnail}- alt="page preview"+ alt={t("addStamp.pagePreviewAlt", "Page preview")}className={styles.pageThumbnail}draggable={false}/>@@ -420,7 +420,7 @@ export default function StampPreview({><imgsrc={imageMeta.url}- alt="stamp preview"+ alt={t("addStamp.stampPreviewAlt", "Stamp preview")}className={styles.stampImage}/>{itemHandles}@@ -457,7 +457,10 @@ export default function StampPreview({)}</div><div className={styles.previewDisclaimer}>- Preview is approximate. Final output may vary due to PDF font metrics.+ {t(+ "addPageNumbers.previewDisclaimer",+ "Preview is approximate. Final output may vary due to PDF font metrics.",+ )}</div></div>);diff --git a/frontend/editor/src/core/components/tools/addStamp/StampSetupSettings.tsx b/frontend/editor/src/core/components/tools/addStamp/StampSetupSettings.tsxindex 06df3aeaf8..3249ce3f57 100644--- a/frontend/editor/src/core/components/tools/addStamp/StampSetupSettings.tsx+++ b/frontend/editor/src/core/components/tools/addStamp/StampSetupSettings.tsx@@ -21,6 +21,7 @@ import styles from "@app/components/tools/addStamp/StampPreview.module.css";import { getDefaultFontSizeForAlphabet } from "@app/components/tools/addStamp/StampPreviewUtils";import { useFileWithUrl } from "@app/hooks/useFileWithUrl";import { Z_INDEX_AUTOMATE_DROPDOWN } from "@app/styles/zIndex";+import { alphabetOptions } from "@app/constants/addWatermarkConstants";const STAMP_TEMPLATES = [{@@ -649,14 +650,10 @@ const StampSetupSettings = ({const nextDefault = getDefaultFontSizeForAlphabet(nextAlphabet);onParameterChange("fontSize", nextDefault);}}- data={[- { value: "roman", label: "Roman" },- { value: "arabic", label: "العربية" },- { value: "japanese", label: "日本語" },- { value: "korean", label: "한국어" },- { value: "chinese", label: "简体中文" },- { value: "thai", label: "ไทย" },- ]}+ data={alphabetOptions.map((option) => ({+ value: option.value,+ label: t(option.labelKey, option.label),+ }))}disabled={disabled}comboboxProps={{withinPortal: true,@@ -691,7 +688,10 @@ const StampSetupSettings = ({<Stack gap="xs"><imgsrc={stampImageWithUrl.url}- alt="Selected stamp image"+ alt={t(+ "AddStampRequest.selectedImageAlt",+ "Selected stamp image",+ )}className="max-h-24 w-full object-contain border border-gray-200 rounded bg-gray-50"/><Text size="xs" c="dimmed">diff --git a/frontend/editor/src/core/components/tools/addWatermark/WatermarkTextStyle.tsx b/frontend/editor/src/core/components/tools/addWatermark/WatermarkTextStyle.tsxindex 259c78d0e8..63a674e462 100644--- a/frontend/editor/src/core/components/tools/addWatermark/WatermarkTextStyle.tsx+++ b/frontend/editor/src/core/components/tools/addWatermark/WatermarkTextStyle.tsx@@ -50,7 +50,10 @@ const WatermarkTextStyle = ({aria-labelledby={alphabetLabelId}value={parameters.alphabet}onChange={(value) => value && onParameterChange("alphabet", value)}- data={alphabetOptions}+ data={alphabetOptions.map((option) => ({+ value: option.value,+ label: t(option.labelKey, option.label),+ }))}disabled={disabled}comboboxProps={{withinPortal: true,diff --git a/frontend/editor/src/core/components/tools/automate/AutomationRun.tsx b/frontend/editor/src/core/components/tools/automate/AutomationRun.tsxindex ef3d16f8e6..7729136a5b 100644--- a/frontend/editor/src/core/components/tools/automate/AutomationRun.tsx+++ b/frontend/editor/src/core/components/tools/automate/AutomationRun.tsx@@ -197,7 +197,10 @@ export default function AutomationRun({{isExecuting && (<div><Text size="sm" mb="xs">- Progress: {currentStepIndex + 1}/{executionSteps.length}+ {t("automate.run.progress", "Progress: {{current}}/{{total}}", {+ current: currentStepIndex + 1,+ total: executionSteps.length,+ })}</Text><Progress value={getProgress()} size="lg" /></div>diff --git a/frontend/editor/src/core/components/tools/convert/ConvertToPdfaSettings.tsx b/frontend/editor/src/core/components/tools/convert/ConvertToPdfaSettings.tsxindex fa035eb067..53094e04ff 100644--- a/frontend/editor/src/core/components/tools/convert/ConvertToPdfaSettings.tsx+++ b/frontend/editor/src/core/components/tools/convert/ConvertToPdfaSettings.tsx@@ -38,9 +38,36 @@ const ConvertToPdfaSettings = ({...(taggingAvailable === false? []: [- { value: "pdfa-1a", label: "PDF/A-1a (accessible)" },- { value: "pdfa-2a", label: "PDF/A-2a (accessible)" },- { value: "pdfa-3a", label: "PDF/A-3a (accessible)" },+ {+ value: "pdfa-1a",+ label: t(+ "convert.pdfaAccessibleFormat",+ "{{format}} (accessible)",+ {+ format: "PDF/A-1a",+ },+ ),+ },+ {+ value: "pdfa-2a",+ label: t(+ "convert.pdfaAccessibleFormat",+ "{{format}} (accessible)",+ {+ format: "PDF/A-2a",+ },+ ),+ },+ {+ value: "pdfa-3a",+ label: t(+ "convert.pdfaAccessibleFormat",+ "{{format}} (accessible)",+ {+ format: "PDF/A-3a",+ },+ ),+ },]),];diff --git a/frontend/editor/src/core/components/tools/convert/GroupedFormatDropdown.tsx b/frontend/editor/src/core/components/tools/convert/GroupedFormatDropdown.tsxindex 1f19e8d279..8e87884e78 100644--- a/frontend/editor/src/core/components/tools/convert/GroupedFormatDropdown.tsx+++ b/frontend/editor/src/core/components/tools/convert/GroupedFormatDropdown.tsx@@ -11,10 +11,12 @@ import { Button } from "@app/ui/Button";import { useTranslation } from "react-i18next";import { Icon } from "@app/ui/Icon";import { Z_INDEX_AUTOMATE_DROPDOWN } from "@app/styles/zIndex";+import { FORMAT_GROUP_LABEL_KEYS } from "@app/constants/convertConstants";interface FormatOption {value: string;label: string;+ labelKey?: string;group: string;enabled?: boolean;usesCloud?: boolean;@@ -48,6 +50,13 @@ const GroupedFormatDropdown = ({const [dropdownOpened, setDropdownOpened] = useState(false);const theme = useMantineTheme();+ const getOptionLabel = (option: FormatOption) =>+ option.labelKey ? t(option.labelKey, option.label) : option.label;+ const getGroupLabel = (group: string) => {+ const key = FORMAT_GROUP_LABEL_KEYS[group];+ return key ? t(key, group) : group;+ };+const groupedOptions = useMemo(() => {const groups: Record<string, FormatOption[]> = {};@@ -65,9 +74,9 @@ const GroupedFormatDropdown = ({if (!value) return resolvedPlaceholder;const selected = options.find((opt) => opt.value === value);return selected- ? `${selected.group} (${selected.label})`+ ? `${getGroupLabel(selected.group)} (${getOptionLabel(selected)})`: value.toUpperCase();- }, [value, options, resolvedPlaceholder]);+ }, [value, options, resolvedPlaceholder, t]);const handleOptionSelect = (selectedValue: string) => {onChange(selectedValue);@@ -145,7 +154,7 @@ const GroupedFormatDropdown = ({mb="xs"style={{ color: "var(--dropdown-group-label)" }}>- {groupName}+ {getGroupLabel(groupName)}</Text><Group gap="xs" style={{ flexWrap: "wrap" }}>{groupOptions.map((option) => (@@ -173,7 +182,7 @@ const GroupedFormatDropdown = ({position: "relative",}}>- {option.label}+ {getOptionLabel(option)}</Button>))}</Group>diff --git a/frontend/editor/src/core/components/tools/getPdfInfo/GetPdfInfoReportView.tsx b/frontend/editor/src/core/components/tools/getPdfInfo/GetPdfInfoReportView.tsxindex 8a3e3c381d..f5b4e586e0 100644--- a/frontend/editor/src/core/components/tools/getPdfInfo/GetPdfInfoReportView.tsx+++ b/frontend/editor/src/core/components/tools/getPdfInfo/GetPdfInfoReportView.tsx@@ -91,10 +91,10 @@ const GetPdfInfoReportView: React.FC<GetPdfInfoReportViewProps> = ({<div className="report-container"><Stack gap="md" align="center"><Badge color="gray" variant="light">- No Data+ {t("getPdfInfo.noData", "No Data")}</Badge><Text size="sm" c="dimmed">- Run the tool to generate the report.+ {t("getPdfInfo.noResults", "Run the tool to generate a report.")}</Text></Stack></div>diff --git a/frontend/editor/src/core/components/tools/getPdfInfo/sections/ComplianceSection.tsx b/frontend/editor/src/core/components/tools/getPdfInfo/sections/ComplianceSection.tsxindex 806a16ec8a..d7e16c6d85 100644--- a/frontend/editor/src/core/components/tools/getPdfInfo/sections/ComplianceSection.tsx+++ b/frontend/editor/src/core/components/tools/getPdfInfo/sections/ComplianceSection.tsx@@ -16,6 +16,7 @@ import type {PdfComplianceSummary,} from "@app/types/getPdfInfo";import { useTranslation } from "react-i18next";+import type { TFunction } from "i18next";interface ComplianceSectionProps {anchorId: string;@@ -119,6 +120,7 @@ const parseStandardDisplayName = (};const buildComplianceResults = (+ t: TFunction,complianceSummary?: PdfComplianceSummary[] | null,legacyCompliance?: PdfCompliance | null,): ComplianceCheckResult[] => {@@ -161,8 +163,14 @@ const buildComplianceResults = (category: "SEC",isCompliant: isSecCompliant,summary: isSecCompliant- ? "Document meets SEC EDGAR filing requirements"- : "Document does not meet SEC EDGAR filing requirements",+ ? t(+ "getPdfInfo.compliance.secCompliant",+ "Document meets SEC EDGAR filing requirements",+ )+ : t(+ "getPdfInfo.compliance.secNotCompliant",+ "Document does not meet SEC EDGAR filing requirements",+ ),standardId: "sec-edgar",sortOrder: 600,});@@ -277,8 +285,8 @@ const ComplianceSection: React.FC<ComplianceSectionProps> = ({const { t } = useTranslation();const complianceResults = useMemo(- () => buildComplianceResults(complianceSummary, legacyCompliance),- [complianceSummary, legacyCompliance],+ () => buildComplianceResults(t, complianceSummary, legacyCompliance),+ [t, complianceSummary, legacyCompliance],);const conformanceLevel = useMemo(diff --git a/frontend/editor/src/core/components/tools/getPdfInfo/sections/OtherSection.tsx b/frontend/editor/src/core/components/tools/getPdfInfo/sections/OtherSection.tsxindex 72d3067910..0a6116b490 100644--- a/frontend/editor/src/core/components/tools/getPdfInfo/sections/OtherSection.tsx+++ b/frontend/editor/src/core/components/tools/getPdfInfo/sections/OtherSection.tsx@@ -1,6 +1,7 @@import React from "react";import { Accordion, Stack, Text } from "@mantine/core";import { useTranslation } from "react-i18next";+import type { TFunction } from "i18next";import type {PdfOtherInfo,PdfAttachmentInfo,@@ -18,6 +19,7 @@ interface OtherSectionProps {const renderAttachmentsList = (attachments: PdfAttachmentInfo[] | undefined,emptyText: string,+ t: TFunction,) => {if (!attachments || attachments.length === 0)return (@@ -33,9 +35,13 @@ const renderAttachmentsList = (style={{ wordBreak: "break-word", overflowWrap: "break-word" }}><Text size="sm" c="dimmed">- <strong>{attachment.Name || "Unnamed attachment"}</strong>+ <strong>+ {attachment.Name ||+ t("getPdfInfo.other.unnamedAttachment", "Unnamed attachment")}+ </strong>{attachment.Description && ` - ${attachment.Description}`}- {attachment.FileSize != null && ` (${attachment.FileSize} bytes)`}+ {attachment.FileSize != null &&+ ` ${t("getPdfInfo.other.fileSizeBytes", "({{size}} bytes)", { size: attachment.FileSize })}`}</Text></div>))}@@ -46,6 +52,7 @@ const renderAttachmentsList = (const renderEmbeddedFilesList = (embeddedFiles: PdfEmbeddedFileInfo[] | undefined,emptyText: string,+ t: TFunction,) => {if (!embeddedFiles || embeddedFiles.length === 0)return (@@ -61,11 +68,16 @@ const renderEmbeddedFilesList = (style={{ wordBreak: "break-word", overflowWrap: "break-word" }}><Text size="sm" c="dimmed">- <strong>{file.Name || "Unnamed file"}</strong>- {file.FileSize != null && ` (${file.FileSize} bytes)`}+ <strong>+ {file.Name || t("getPdfInfo.other.unnamedFile", "Unnamed file")}+ </strong>+ {file.FileSize != null &&+ ` ${t("getPdfInfo.other.fileSizeBytes", "({{size}} bytes)", { size: file.FileSize })}`}{file.MimeType && ` - ${file.MimeType}`}- {file.CreationDate && ` - Created: ${file.CreationDate}`}- {file.ModificationDate && ` - Modified: ${file.ModificationDate}`}+ {file.CreationDate &&+ ` - ${t("getPdfInfo.other.created", "Created: {{date}}", { date: file.CreationDate })}`}+ {file.ModificationDate &&+ ` - ${t("getPdfInfo.other.modified", "Modified: {{date}}", { date: file.ModificationDate })}`}</Text></div>))}@@ -115,13 +127,13 @@ const OtherSection: React.FC<OtherSectionProps> = ({ anchorId, other }) => {<Text fw={600} size="sm">{t("getPdfInfo.other.attachments", "Attachments")}</Text>- {renderAttachmentsList(other?.Attachments, noneDetected)}+ {renderAttachmentsList(other?.Attachments, noneDetected, t)}</Stack><Stack gap={6}><Text fw={600} size="sm">{t("getPdfInfo.other.embeddedFiles", "Embedded Files")}</Text>- {renderEmbeddedFilesList(other?.EmbeddedFiles, noneDetected)}+ {renderEmbeddedFilesList(other?.EmbeddedFiles, noneDetected, t)}</Stack><Stack gap={6}><Text fw={600} size="sm">diff --git a/frontend/editor/src/core/components/tools/getPdfInfo/sections/PerPageSection.tsx b/frontend/editor/src/core/components/tools/getPdfInfo/sections/PerPageSection.tsxindex 80eb184a42..f45c522f15 100644--- a/frontend/editor/src/core/components/tools/getPdfInfo/sections/PerPageSection.tsx+++ b/frontend/editor/src/core/components/tools/getPdfInfo/sections/PerPageSection.tsx@@ -1,6 +1,7 @@import React from "react";import { Accordion, Stack, Text } from "@mantine/core";import { useTranslation } from "react-i18next";+import type { TFunction } from "i18next";import type {PdfPerPageInfo,PdfPageInfo,@@ -19,6 +20,7 @@ interface PerPageSectionProps {const renderImagesList = (images: PdfImageInfo[] | undefined,emptyText: string,+ t: TFunction,) => {if (!images || images.length === 0)return (@@ -34,8 +36,8 @@ const renderImagesList = (style={{ wordBreak: "break-word", overflowWrap: "break-word" }}><Text size="sm" c="dimmed">- {image.Name ? `${image.Name} ` : "Image "}({image.Width}×- {image.Height}px+ {image.Name || t("getPdfInfo.perPage.unnamedImage", "Image")} (+ {image.Width}×{image.Height}px{image.ColorSpace ? `, ${image.ColorSpace}` : ""})</Text></div>@@ -165,7 +167,7 @@ const PerPageSection: React.FC<PerPageSectionProps> = ({<Text fw={600} size="sm">{t("getPdfInfo.perPage.images", "Images")}</Text>- {renderImagesList(pageInfo?.Images, noneDetected)}+ {renderImagesList(pageInfo?.Images, noneDetected, t)}</Stack><Stack gap={4}><Text fw={600} size="sm">diff --git a/frontend/editor/src/core/components/tools/getPdfInfo/shared/KeyValueList.tsx b/frontend/editor/src/core/components/tools/getPdfInfo/shared/KeyValueList.tsxindex be35732340..80278a7bdf 100644--- a/frontend/editor/src/core/components/tools/getPdfInfo/shared/KeyValueList.tsx+++ b/frontend/editor/src/core/components/tools/getPdfInfo/shared/KeyValueList.tsx@@ -1,5 +1,6 @@import React from "react";import { Group, Stack, Text } from "@mantine/core";+import { useTranslation } from "react-i18next";interface KeyValueListProps {obj?: Record<string, unknown> | null;@@ -7,10 +8,11 @@ interface KeyValueListProps {}const KeyValueList: React.FC<KeyValueListProps> = ({ obj, emptyLabel }) => {+ const { t } = useTranslation();if (!obj || Object.keys(obj).length === 0) {return (<Text size="sm" c="dimmed">- {emptyLabel ?? "None detected"}+ {emptyLabel ?? t("getPdfInfo.noneDetected", "None detected")}</Text>);}diff --git a/frontend/editor/src/core/components/tools/redact/RedactSingleStepSettings.tsx b/frontend/editor/src/core/components/tools/redact/RedactSingleStepSettings.tsxindex c537b327bc..c20e5db0b3 100644--- a/frontend/editor/src/core/components/tools/redact/RedactSingleStepSettings.tsx+++ b/frontend/editor/src/core/components/tools/redact/RedactSingleStepSettings.tsx@@ -1,4 +1,5 @@import { Stack, Divider } from "@mantine/core";+import { useTranslation } from "react-i18next";import { RedactParameters } from "@app/hooks/tools/redact/useRedactParameters";import RedactModeSelector from "@app/components/tools/redact/RedactModeSelector";import WordsToRedactInput from "@app/components/tools/redact/WordsToRedactInput";@@ -18,6 +19,7 @@ const RedactSingleStepSettings = ({onParameterChange,disabled = false,}: RedactSingleStepSettingsProps) => {+ const { t } = useTranslation();return (<Stack gap="md">{/* Mode Selection */}@@ -62,8 +64,10 @@ const RedactSingleStepSettings = ({color: "var(--c-text-muted)",}}>- Manual redaction interface will be available here when- implemented.+ {t(+ "redact.manual.notImplemented",+ "Manual redaction interface will be available here when implemented.",+ )}</div></Stack></>diff --git a/frontend/editor/src/core/components/tools/rotate/RotateSettings.test.tsx b/frontend/editor/src/core/components/tools/rotate/RotateSettings.test.tsxindex 0730521b8e..6b8c5c149c 100644--- a/frontend/editor/src/core/components/tools/rotate/RotateSettings.test.tsx+++ b/frontend/editor/src/core/components/tools/rotate/RotateSettings.test.tsx@@ -21,7 +21,10 @@ vi.mock("@app/contexts/NavigationContext", () => ({vi.mock("@app/contexts/FileContext", () => ({ useAllFiles: () => files }));vi.mock("react-i18next", () => ({useTranslation: () => ({- t: (_key: string, fallback?: string) => fallback ?? _key,+ t: (_key: string, fallback?: string, values?: Record<string, unknown>) =>+ (fallback ?? _key).replace(/{{(\w+)}}/g, (_, name: string) =>+ String(values?.[name] ?? ""),+ ),}),}));diff --git a/frontend/editor/src/core/components/tools/shared/FileMetadata.tsx b/frontend/editor/src/core/components/tools/shared/FileMetadata.tsxindex 3a11ff1be3..1916b7cfb4 100644--- a/frontend/editor/src/core/components/tools/shared/FileMetadata.tsx+++ b/frontend/editor/src/core/components/tools/shared/FileMetadata.tsx@@ -1,4 +1,5 @@import { Stack, Text } from "@mantine/core";+import { useTranslation } from "react-i18next";import { formatFileSize, getFileDate } from "@app/utils/fileUtils";export interface FileMetadataProps {@@ -6,6 +7,7 @@ export interface FileMetadataProps {}const FileMetadata = ({ file }: FileMetadataProps) => {+ const { t } = useTranslation();return (<Stack gap="xs" style={{ flex: 1, minWidth: 0 }}><Stack gap="0.125rem">@@ -13,7 +15,7 @@ const FileMetadata = ({ file }: FileMetadataProps) => {{formatFileSize(file.size)}</Text><Text size="xs" c="dimmed">- {file.type || "Unknown"}+ {file.type || t("unknown", "Unknown")}</Text><Text size="xs" c="dimmed">{getFileDate(file)}diff --git a/frontend/editor/src/core/components/tools/shared/NavigationControls.tsx b/frontend/editor/src/core/components/tools/shared/NavigationControls.tsxindex c93975fa52..08f15eaba8 100644--- a/frontend/editor/src/core/components/tools/shared/NavigationControls.tsx+++ b/frontend/editor/src/core/components/tools/shared/NavigationControls.tsx@@ -33,7 +33,10 @@ const NavigationControls = ({<Icon name="chevron-left" size={"1rem"} /></ActionIcon><Text size="xs" c="dimmed">- {currentIndex + 1} of {totalFiles}+ {t("common.nOfTotal", "{{current}} of {{total}}", {+ current: currentIndex + 1,+ total: totalFiles,+ })}</Text><ActionIcondiff --git a/frontend/editor/src/core/components/tools/split/SplitSettings.tsx b/frontend/editor/src/core/components/tools/split/SplitSettings.tsxindex 7bcba13299..16313f2afc 100644--- a/frontend/editor/src/core/components/tools/split/SplitSettings.tsx+++ b/frontend/editor/src/core/components/tools/split/SplitSettings.tsx@@ -243,12 +243,39 @@ const SplitSettings = ({value={parameters.pageSize || "A4"}onChange={(value) => onParameterChange("pageSize", value || "A4")}data={[- { value: "A4", label: "A4 (210 × 297 mm)" },- { value: "Letter", label: "Letter (8.5 × 11 in)" },- { value: "A3", label: "A3 (297 × 420 mm)" },- { value: "A5", label: "A5 (148 × 210 mm)" },- { value: "Legal", label: "Legal (8.5 × 14 in)" },- { value: "Tabloid", label: "Tabloid (11 × 17 in)" },+ {+ value: "A4",+ label: t("split.poster.pageSize.options.a4", "A4 (210 × 297 mm)"),+ },+ {+ value: "Letter",+ label: t(+ "split.poster.pageSize.options.letter",+ "Letter (8.5 × 11 in)",+ ),+ },+ {+ value: "A3",+ label: t("split.poster.pageSize.options.a3", "A3 (297 × 420 mm)"),+ },+ {+ value: "A5",+ label: t("split.poster.pageSize.options.a5", "A5 (148 × 210 mm)"),+ },+ {+ value: "Legal",+ label: t(+ "split.poster.pageSize.options.legal",+ "Legal (8.5 × 14 in)",+ ),+ },+ {+ value: "Tabloid",+ label: t(+ "split.poster.pageSize.options.tabloid",+ "Tabloid (11 × 17 in)",+ ),+ },]}disabled={disabled}comboboxProps={{diff --git a/frontend/editor/src/core/components/tools/validateSignature/reportView/ThumbnailPreview.tsx b/frontend/editor/src/core/components/tools/validateSignature/reportView/ThumbnailPreview.tsxindex a47f661373..3f537731fe 100644--- a/frontend/editor/src/core/components/tools/validateSignature/reportView/ThumbnailPreview.tsx+++ b/frontend/editor/src/core/components/tools/validateSignature/reportView/ThumbnailPreview.tsx@@ -1,3 +1,4 @@+import { useTranslation } from "react-i18next";import { Icon } from "@app/ui/Icon";import "@app/components/tools/validateSignature/reportView/styles.css";@@ -8,12 +9,19 @@ const ThumbnailPreview = ({thumbnailUrl?: string | null;fileName: string;}) => {+ const { t } = useTranslation();if (thumbnailUrl) {return (<div className="thumbnail-container"><imgsrc={thumbnailUrl}- alt={`${fileName} thumbnail`}+ alt={t(+ "validateSignature.report.thumbnailAlt",+ "{{fileName}} thumbnail",+ {+ fileName,+ },+ )}className="thumbnail-image"/></div>diff --git a/frontend/editor/src/core/components/viewer/BookmarkSidebar.tsx b/frontend/editor/src/core/components/viewer/BookmarkSidebar.tsxindex b2868ee4a5..0e71e06149 100644--- a/frontend/editor/src/core/components/viewer/BookmarkSidebar.tsx+++ b/frontend/editor/src/core/components/viewer/BookmarkSidebar.tsx@@ -288,7 +288,9 @@ export const BookmarkSidebar = ({.catch((error) => {if (cancelled) return;const message =- error instanceof Error ? error.message : "Failed to load bookmarks";+ error instanceof Error+ ? error.message+ : t("viewer.bookmarks.loadFailed", "Failed to load bookmarks");const fallback = cacheRef.current.get(key);const entry = createEntry({status: "error",@@ -447,7 +449,9 @@ export const BookmarkSidebar = ({setNewBookmarkTitle("");} catch (error) {const message =- error instanceof Error ? error.message : "Failed to save bookmark";+ error instanceof Error+ ? error.message+ : t("viewer.bookmarks.saveFailed", "Failed to save bookmark");setAddBookmarkError(message);} finally {setIsSavingBookmark(false);@@ -626,7 +630,11 @@ export const BookmarkSidebar = ({variant="tertiary"size="sm"className="bookmark-item__expand-icon"- aria-label={isNodeExpanded ? "Collapse" : "Expand"}+ aria-label={+ isNodeExpanded+ ? t("common.collapse", "Collapse")+ : t("common.expand", "Expand")+ }onClick={(event) => {event.stopPropagation();toggleNode(node.id);@@ -642,11 +650,13 @@ export const BookmarkSidebar = ({)}<div className="bookmark-item__content"><Text size="sm" fw={500} className="bookmark-item__title">- {node.title || "Untitled"}+ {node.title || t("viewer.bookmarks.untitled", "Untitled")}</Text>{pageNumber && (<Text size="xs" c="dimmed" className="bookmark-item__page">- Page {pageNumber}+ {t("viewer.bookmarks.pageNumber", "Page {{page}}", {+ page: pageNumber,+ })}</Text>)}</div>@@ -733,7 +743,10 @@ export const BookmarkSidebar = ({{bookmarkSupport && showNoDocument && (<div className="sidebar-base__empty-state"><Text size="sm" c="dimmed" ta="center">- Open a PDF to view its bookmarks.+ {t(+ "viewer.bookmarks.noDocument",+ "Open a PDF to view its bookmarks.",+ )}</Text></div>)}@@ -744,7 +757,7 @@ export const BookmarkSidebar = ({{currentError}</Text><Button variant="secondary" size="sm" onClick={requestReload}>- Retry+ {t("common.retry", "Retry")}</Button></Stack>)}@@ -759,7 +772,7 @@ export const BookmarkSidebar = ({><Loader size="md" type="dots" /><Text size="sm" ta="center">- Loading bookmarks...+ {t("viewer.bookmarks.loading", "Loading bookmarks...")}</Text></Stack>)}@@ -813,7 +826,7 @@ export const BookmarkSidebar = ({/><NumberInputsize="xs"- label="Page"+ label={t("viewer.bookmarks.pageLabel", "Page")}min={1}clampBehavior="strict"value={newBookmarkPage}@@ -834,7 +847,7 @@ export const BookmarkSidebar = ({onClick={handleCancelAddBookmark}disabled={isSavingBookmark}>- Cancel+ {t("common.cancel", "Cancel")}</Button><Buttonsize="sm"@@ -843,7 +856,7 @@ export const BookmarkSidebar = ({loading={isSavingBookmark}disabled={!newBookmarkTitle.trim()}>- Save+ {t("common.save", "Save")}</Button></Group></Stack>@@ -873,7 +886,10 @@ export const BookmarkSidebar = ({{showSearchEmpty && (<div className="sidebar-base__empty-state"><Text size="sm" c="dimmed" ta="center">- No bookmarks match your search+ {t(+ "viewer.bookmarks.noSearchResults",+ "No bookmarks match your search",+ )}</Text></div>)}@@ -908,7 +924,10 @@ export const BookmarkSidebar = ({ta="center"style={{ textDecoration: "underline" }}>- Need to reorder or nest? Open the Bookmark Editor+ {t(+ "viewer.bookmarks.openEditor",+ "Need to reorder or nest? Open the Bookmark Editor",+ )}</Text></Group></Button>diff --git a/frontend/editor/src/core/components/viewer/LayerSidebar.tsx b/frontend/editor/src/core/components/viewer/LayerSidebar.tsxindex 95e30728a6..6161ed81b6 100644--- a/frontend/editor/src/core/components/viewer/LayerSidebar.tsx+++ b/frontend/editor/src/core/components/viewer/LayerSidebar.tsx@@ -107,7 +107,9 @@ export function LayerSidebar({if (cancelled) return;setStatus("error");setLoadError(- err instanceof Error ? err.message : "Failed to read PDF layers",+ err instanceof Error+ ? err.message+ : t("viewer.layers.readFailed", "Failed to read PDF layers"),);onLayersDetected?.(false);});@@ -349,7 +351,7 @@ export function LayerSidebar({{status === "idle" && (<div className="sidebar-base__empty-state"><Text size="sm" c="dimmed" ta="center">- Open a PDF to view its layers.+ {t("viewer.layers.noDocument", "Open a PDF to view its layers.")}</Text></div>)}@@ -364,7 +366,7 @@ export function LayerSidebar({><Loader size="md" type="dots" /><Text size="sm" ta="center">- Loading layers...+ {t("viewer.layers.loading", "Loading layers...")}</Text></Stack>)}@@ -372,7 +374,8 @@ export function LayerSidebar({{status === "error" && (<div className="sidebar-base__error"><Text size="sm" c="var(--color-red-dark)" ta="center">- {loadError ?? "Failed to load layers."}+ {loadError ??+ t("viewer.layers.loadFailed", "Failed to load layers.")}</Text></div>)}@@ -380,7 +383,7 @@ export function LayerSidebar({{status === "no-layers" && (<div className="sidebar-base__empty-state"><Text size="sm" c="dimmed" ta="center">- This document has no layers.+ {t("viewer.layers.empty", "This document has no layers.")}</Text></div>)}diff --git a/frontend/editor/src/core/components/viewer/LinkLayer.tsx b/frontend/editor/src/core/components/viewer/LinkLayer.tsxindex 0be5ee64e3..fbb288dddf 100644--- a/frontend/editor/src/core/components/viewer/LinkLayer.tsx+++ b/frontend/editor/src/core/components/viewer/LinkLayer.tsx@@ -8,6 +8,7 @@ import React, {} from "react";import { createPortal } from "react-dom";import { useTranslation } from "react-i18next";+import type { TFunction } from "i18next";import { useDocumentState } from "@embedpdf/core/react";import { useScroll } from "@embedpdf/plugin-scroll/react";import { useAnnotation } from "@embedpdf/plugin-annotation/react";@@ -103,21 +104,24 @@ function truncateUrl(url: string, maxLen = 32): string {}}-function getLinkLabel(annotationLink: PdfLinkAnnoObject): string {- if (!annotationLink.target) return "Open Link";+function getLinkLabel(annotationLink: PdfLinkAnnoObject, t: TFunction): string {+ const openLink = t("viewer.link.open", "Open Link");+ const pageLabel = (pageIndex: number) =>+ t("viewer.link.page", "Page {{page}}", { page: pageIndex + 1 });+ if (!annotationLink.target) return openLink;if (annotationLink.target.type === "action") {const action = annotationLink.target.action;if (action.type === PdfActionType.URI) return truncateUrl(action.uri);if (action.type === PdfActionType.Goto)- return `Page ${action.destination.pageIndex + 1}`;+ return pageLabel(action.destination.pageIndex);if (action.type === PdfActionType.RemoteGoto)- return `Page ${action.destination.pageIndex + 1}`;+ return pageLabel(action.destination.pageIndex);} else if (annotationLink.target.type === "destination") {- return `Page ${annotationLink.target.destination.pageIndex + 1}`;+ return pageLabel(annotationLink.target.destination.pageIndex);}- return "Open Link";+ return openLink;}function isInternalLink(annotationLink: PdfLinkAnnoObject): boolean {@@ -193,7 +197,7 @@ const LinkToolbar: React.FC<LinkToolbarProps> = React.memo(}) => {const { t } = useTranslation();const internal = isInternalLink(annotationLink);- const label = getLinkLabel(annotationLink);+ const label = getLinkLabel(annotationLink, t);return (<div@@ -232,7 +236,11 @@ const LinkToolbar: React.FC<LinkToolbarProps> = React.memo(e.stopPropagation();onNavigate(annotationLink);}}- aria-label={internal ? `Go to ${label}` : "Open link"}+ aria-label={+ internal+ ? t("viewer.link.goTo", "Go to {{label}}", { label })+ : t("viewer.link.openAria", "Open link")+ }title={label}>{internal ? <PageIcon /> : <ExternalLinkIcon />}@@ -258,6 +266,7 @@ export const LinkLayer: React.FC<LinkLayerProps> = ({documentId,pageIndex,}) => {+ const { t } = useTranslation();const { provides: scroll } = useScroll(documentId);const { state, provides: scope } = useAnnotation(documentId);const documentState = useDocumentState(documentId);@@ -546,7 +555,7 @@ export const LinkLayer: React.FC<LinkLayerProps> = ({}}role="link"tabIndex={0}- aria-label={getLinkLabel(annotationLink)}+ aria-label={getLinkLabel(annotationLink, t)}/>);})}diff --git a/frontend/editor/src/core/components/viewer/LocalEmbedPDF.tsx b/frontend/editor/src/core/components/viewer/LocalEmbedPDF.tsxindex 874c6982b5..dcdf1f1f12 100644--- a/frontend/editor/src/core/components/viewer/LocalEmbedPDF.tsx+++ b/frontend/editor/src/core/components/viewer/LocalEmbedPDF.tsx@@ -1070,7 +1070,7 @@ export function LocalEmbedPDF({<Stack align="center" gap="md"><div style={{ fontSize: "24px" }}>📄</div><Text c="dimmed" size="sm">- No PDF provided+ {t("viewer.noPdfProvided", "No PDF provided")}</Text></Stack></Center>diff --git a/frontend/editor/src/core/components/viewer/NonPdfViewer.tsx b/frontend/editor/src/core/components/viewer/NonPdfViewer.tsxindex 3926bc3516..04e72d9832 100644--- a/frontend/editor/src/core/components/viewer/NonPdfViewer.tsx+++ b/frontend/editor/src/core/components/viewer/NonPdfViewer.tsx@@ -1,5 +1,6 @@import React, { useCallback, useMemo } from "react";import { Box, Center, Stack, Text } from "@mantine/core";+import { useTranslation } from "react-i18next";import { Button } from "@app/ui/Button";import { Icon } from "@app/ui/Icon";import { useAllFiles } from "@app/contexts/FileContext";@@ -28,6 +29,7 @@ export interface NonPdfViewerProps extends ViewerProps {}export function NonPdfViewer({ file }: NonPdfViewerProps) {+ const { t } = useTranslation();const fileType = useMemo(() => detectNonPdfFileType(file), [file]);const { handleToolSelect, toolAvailability } = useToolWorkflow();@@ -73,7 +75,10 @@ export function NonPdfViewer({ file }: NonPdfViewerProps) {style={{ color: "var(--mantine-color-gray-4)" }}/><Text c="dimmed" size="sm">- Preview not available for this file type+ {t(+ "viewer.nonPdf.previewUnavailable",+ "Preview not available for this file type",+ )}</Text>{isConvertAvailable && (<Button@@ -82,7 +87,7 @@ export function NonPdfViewer({ file }: NonPdfViewerProps) {leftSection={<Icon name="file-pdf" />}onClick={handleConvertToPdf}>- Convert to PDF+ {t("viewer.nonPdf.convertToPdf", "Convert to PDF")}</Button>)}</Stack>@@ -124,6 +129,7 @@ export function NonPdfViewer({ file }: NonPdfViewerProps) {// ─── Wrapper that resolves the active file from FileContext ───────────────────export function NonPdfViewerWrapper(props: ViewerProps) {+ const { t } = useTranslation();const { files: activeFiles } = useAllFiles();const { activeFileIndex } = useViewer();@@ -134,7 +140,7 @@ export function NonPdfViewerWrapper(props: ViewerProps) {return (<Center style={{ flex: 1 }}><Text c="dimmed" size="sm">- No file loaded+ {t("viewer.nonPdf.noFile", "No file loaded")}</Text></Center>);diff --git a/frontend/editor/src/core/components/viewer/ScaleCalibrationDialog.tsx b/frontend/editor/src/core/components/viewer/ScaleCalibrationDialog.tsxindex 3b7b54311f..a0d4a5ab88 100644--- a/frontend/editor/src/core/components/viewer/ScaleCalibrationDialog.tsx+++ b/frontend/editor/src/core/components/viewer/ScaleCalibrationDialog.tsx@@ -4,7 +4,7 @@ import { useTranslation } from "react-i18next";import { Button } from "@app/ui/Button";import type { MeasureScale, PagePoint } from "@app/utils/measurementTypes";import {- UNIT_OPTIONS,+ getUnitOptions,formatPaperDistance,validateRealDistance,calculateCalibratedScale,@@ -157,7 +157,7 @@ export function ScaleCalibrationDialog({/><Selectlabel={t("scaleSettings.unit", "Unit")}- data={UNIT_OPTIONS}+ data={getUnitOptions(t)}value={unit}onChange={handleUnitChange}searchablediff --git a/frontend/editor/src/core/components/viewer/ScaleSettingsPanel.tsx b/frontend/editor/src/core/components/viewer/ScaleSettingsPanel.tsxindex 622eeef9ae..a3391cfdea 100644--- a/frontend/editor/src/core/components/viewer/ScaleSettingsPanel.tsx+++ b/frontend/editor/src/core/components/viewer/ScaleSettingsPanel.tsx@@ -7,7 +7,7 @@ import {generateScaleLabel,parsePresetRatio,calculateScaleFactor,- UNIT_OPTIONS,+ getUnitOptions,} from "@app/utils/measurementUtils";// ─── Constants ─────────────────────────────────────────────────────────────@@ -245,7 +245,7 @@ export function ScaleSettingsPanel({<div onMouseDown={(e) => e.stopPropagation()}><Selectlabel={t("scaleSettings.unit", "Unit")}- data={UNIT_OPTIONS}+ data={getUnitOptions(t)}value={unit}onChange={handleUnitChange}size="xs"@@ -281,7 +281,9 @@ export function ScaleSettingsPanel({{currentScale && currentScale.ratio? generateScaleLabel(currentScale.ratio, currentScale.unit): currentScale && !currentScale.ratio- ? `${currentScale.unit} (custom)`+ ? t("scaleSettings.customUnit", "{{unit}} (custom)", {+ unit: currentScale.unit,+ }): t("scaleSettings.noneSet", "No custom scale set")}</Text></div>diff --git a/frontend/editor/src/core/components/viewer/SidebarBase.tsx b/frontend/editor/src/core/components/viewer/SidebarBase.tsxindex 264a8581df..e89c718135 100644--- a/frontend/editor/src/core/components/viewer/SidebarBase.tsx+++ b/frontend/editor/src/core/components/viewer/SidebarBase.tsx@@ -1,5 +1,6 @@import type { ReactNode } from "react";import { Box, ScrollArea, Text, TextInput } from "@mantine/core";+import { useTranslation } from "react-i18next";import { ActionIcon } from "@app/ui/ActionIcon";import "@app/components/viewer/SidebarBase.css";@@ -42,7 +43,7 @@ export function SidebarBase({visible = true,className = "",onClose,- closeLabel = "Close sidebar",+ closeLabel,headerActions,searchTerm,searchPlaceholder,@@ -50,6 +51,10 @@ export function SidebarBase({viewportRef,children,}: SidebarBaseProps) {+ const { t } = useTranslation();+ const resolvedCloseLabel =+ closeLabel ?? t("viewer.sidebar.close", "Close sidebar");+if (!visible) {return null;}@@ -87,8 +92,8 @@ export function SidebarBase({accent="neutral"size="sm"onClick={onClose}- aria-label={closeLabel}- title={closeLabel}+ aria-label={resolvedCloseLabel}+ title={resolvedCloseLabel}><Icon name="x" size="1.1rem" /></ActionIcon>@@ -100,7 +105,10 @@ export function SidebarBase({<Box px="sm" pb="sm" className="sidebar-base__search"><TextInputvalue={searchTerm ?? ""}- placeholder={searchPlaceholder ?? "Search..."}+ placeholder={+ searchPlaceholder ??+ t("viewer.sidebar.searchPlaceholder", "Search...")+ }onChange={(e) => onSearchChange(e.currentTarget.value)}leftSection={<Icon name="search" size="1.1rem" />}size="xs"diff --git a/frontend/editor/src/core/components/viewer/SignatureFieldOverlay.tsx b/frontend/editor/src/core/components/viewer/SignatureFieldOverlay.tsxindex ddc41a1e94..35bd0d56fd 100644--- a/frontend/editor/src/core/components/viewer/SignatureFieldOverlay.tsx+++ b/frontend/editor/src/core/components/viewer/SignatureFieldOverlay.tsx@@ -16,6 +16,7 @@ import { getDocumentBytes } from "@app/services/documentBytesCache";import { documentHasFormFields } from "@app/services/documentFormProbe";import { runPdfiumScan } from "@app/services/pdfiumScanQueue";import React, { useEffect, useMemo, useRef, useState, memo } from "react";+import { useTranslation } from "react-i18next";import {renderSignatureFieldAppearances,extractSignatures,@@ -121,6 +122,7 @@ function SignatureFieldOverlayInner({pageWidth,pageHeight,}: SignatureFieldOverlayProps) {+ const { t } = useTranslation();const staleNames = useStaleBakedFieldNames();const [fields, setFields] = useState<ResolvedSignatureField[]>([]);@@ -154,6 +156,19 @@ function SignatureFieldOverlayInner({if (pageFields.length === 0) return null;+ const getSignedTitle = (field: ResolvedSignatureField) => {+ const label = field.reason+ ? t("viewer.signatureField.signedWithReason", "Signed: {{reason}}", {+ reason: field.reason,+ })+ : t("viewer.signatureField.signed", "Signed");+ if (!field.time) return label;+ return t("viewer.signatureField.withTime", "{{label}} ({{time}})", {+ label,+ time: field.time,+ });+ };+return (<divstyle={{@@ -197,8 +212,12 @@ function SignatureFieldOverlayInner({}}title={field.isSigned- ? `Signed${field.reason ? `: ${field.reason}` : ""}${field.time ? ` (${field.time})` : ""}`- : `Signature field: ${field.fieldName}`+ ? getSignedTitle(field)+ : t(+ "viewer.signatureField.fieldTitle",+ "Signature field: {{name}}",+ { name: field.fieldName },+ )}><SignatureBitmapCanvas@@ -236,8 +255,12 @@ function SignatureFieldOverlayInner({}}title={field.isSigned- ? `Signed${field.reason ? `: ${field.reason}` : ""}${field.time ? ` (${field.time})` : ""}`- : `Unsigned signature field: ${field.fieldName}`+ ? getSignedTitle(field)+ : t(+ "viewer.signatureField.unsignedFieldTitle",+ "Unsigned signature field: {{name}}",+ { name: field.fieldName },+ )}><span@@ -257,7 +280,9 @@ function SignatureFieldOverlayInner({maxWidth: "100%",}}>- {field.isSigned ? "🔒 Signed" : "✎ Signature"}+ {field.isSigned+ ? `🔒 ${t("viewer.signatureField.signed", "Signed")}`+ : `✎ ${t("viewer.signatureField.badge", "Signature")}`}</span></div>);diff --git a/frontend/editor/src/core/components/viewer/SignaturePreviewLayer.tsx b/frontend/editor/src/core/components/viewer/SignaturePreviewLayer.tsxindex 36e5325123..104af05e37 100644--- a/frontend/editor/src/core/components/viewer/SignaturePreviewLayer.tsx+++ b/frontend/editor/src/core/components/viewer/SignaturePreviewLayer.tsx@@ -250,7 +250,7 @@ export const SignaturePreviewLayer = memo(function SignaturePreviewLayer({><imgsrc={preview.signatureData}- alt="Signature preview"+ alt={t("viewer.signature.previewAlt", "Signature preview")}style={{width: "100%",height: "100%",diff --git a/frontend/editor/src/core/components/viewer/ThumbnailSidebar.tsx b/frontend/editor/src/core/components/viewer/ThumbnailSidebar.tsxindex 079d2ed920..491f933d1d 100644--- a/frontend/editor/src/core/components/viewer/ThumbnailSidebar.tsx+++ b/frontend/editor/src/core/components/viewer/ThumbnailSidebar.tsx@@ -180,7 +180,7 @@ export function ThumbnailSidebar({lts={0.5}style={{ flex: 1 }}>- Pages+ {t("viewer.thumbnails.title", "Pages")}</Text></div><ActionIcon@@ -252,7 +252,11 @@ export function ThumbnailSidebar({<PrivateContent><imgsrc={thumbnails[pageIndex]}- alt={`Page ${pageIndex + 1} thumbnail`}+ alt={t(+ "viewer.thumbnails.thumbnailAlt",+ "Page {{page}} thumbnail",+ { page: pageIndex + 1 },+ )}style={{maxWidth: "100%",height: "auto",@@ -277,7 +281,7 @@ export function ThumbnailSidebar({fontSize: "12px",}}>- Failed+ {t("viewer.thumbnails.failed", "Failed")}</div>) : (<div@@ -294,7 +298,7 @@ export function ThumbnailSidebar({fontSize: "12px",}}>- Loading...+ {t("loading", "Loading...")}</div>)}@@ -309,7 +313,9 @@ export function ThumbnailSidebar({: "var(--c-text-subtle)",}}>- Page {pageIndex + 1}+ {t("viewer.thumbnails.pageNumber", "Page {{page}}", {+ page: pageIndex + 1,+ })}</div></Box>),diff --git a/frontend/editor/src/core/components/viewer/nonpdf/MarkdownRenderer.tsx b/frontend/editor/src/core/components/viewer/nonpdf/MarkdownRenderer.tsxindex 7cd69a2330..fe820aa2db 100644--- a/frontend/editor/src/core/components/viewer/nonpdf/MarkdownRenderer.tsx+++ b/frontend/editor/src/core/components/viewer/nonpdf/MarkdownRenderer.tsx@@ -2,9 +2,11 @@ import React, { useState } from "react";import ReactMarkdown from "react-markdown";import type { Components } from "react-markdown";import remarkGfm from "remark-gfm";+import { useTranslation } from "react-i18next";import { Button } from "@app/ui/Button";function CopyButton({ text }: { text: string }) {+ const { t } = useTranslation();const [copied, setCopied] = useState(false);return (<Button@@ -32,7 +34,9 @@ function CopyButton({ text }: { text: string }) {: "var(--mantine-color-gray-7)",}}>- {copied ? "✓ Copied" : "Copy"}+ {copied+ ? `✓ ${t("viewer.nonPdf.copied", "Copied")}`+ : t("common.copy", "Copy")}</Button>);}diff --git a/frontend/editor/src/core/constants/addWatermarkConstants.ts b/frontend/editor/src/core/constants/addWatermarkConstants.tsindex 7ea1fe29c2..a3b9547542 100644--- a/frontend/editor/src/core/constants/addWatermarkConstants.ts+++ b/frontend/editor/src/core/constants/addWatermarkConstants.ts@@ -1,13 +1,22 @@export interface AlphabetOption {value: string;label: string;+ labelKey: string;}export const alphabetOptions: AlphabetOption[] = [- { value: "roman", label: "Roman" },- { value: "arabic", label: "العربية" },- { value: "japanese", label: "日本語" },- { value: "korean", label: "한국어" },- { value: "chinese", label: "简体中文" },- { value: "thai", label: "ไทย" },+ { value: "roman", label: "Roman", labelKey: "alphabetOptions.roman" },+ { value: "arabic", label: "Arabic", labelKey: "alphabetOptions.arabic" },+ {+ value: "japanese",+ label: "Japanese",+ labelKey: "alphabetOptions.japanese",+ },+ { value: "korean", label: "Korean", labelKey: "alphabetOptions.korean" },+ {+ value: "chinese",+ label: "Chinese (Simplified)",+ labelKey: "alphabetOptions.chinese",+ },+ { value: "thai", label: "Thai", labelKey: "alphabetOptions.thai" },];diff --git a/frontend/editor/src/core/constants/convertConstants.ts b/frontend/editor/src/core/constants/convertConstants.tsindex 4f240d9fd0..19995220a3 100644--- a/frontend/editor/src/core/constants/convertConstants.ts+++ b/frontend/editor/src/core/constants/convertConstants.ts@@ -98,10 +98,35 @@ export const ENDPOINT_I18N: Record<string, [string, string]> = {"pdf-to-epub": ["convert.pdfToEpub", "PDF → EPUB"],};+// Translation keys for the dropdown group names below; the English name is the default+export const FORMAT_GROUP_LABEL_KEYS: Record<string, string> = {+ "Multiple Files": "convert.formatGroups.multipleFiles",+ Document: "convert.formatGroups.document",+ Archive: "convert.formatGroups.archive",+ Spreadsheet: "convert.formatGroups.spreadsheet",+ Presentation: "convert.formatGroups.presentation",+ Image: "convert.formatGroups.image",+ Web: "convert.formatGroups.web",+ Text: "convert.formatGroups.text",+ Email: "convert.formatGroups.email",+ eBook: "convert.formatGroups.ebook",+ File: "convert.formatGroups.file",+};+// Grouped file extensions for dropdownsexport const FROM_FORMAT_OPTIONS = [- { value: "any", label: "Any", group: "Multiple Files" },- { value: "image", label: "Images", group: "Multiple Files" },+ {+ value: "any",+ label: "Any",+ labelKey: "convert.formatOptions.any",+ group: "Multiple Files",+ },+ {+ value: "image",+ label: "Images",+ labelKey: "convert.formatOptions.images",+ group: "Multiple Files",+ },{ value: "pdf", label: "PDF", group: "Document" },{ value: "cbz", label: "CBZ", group: "Archive" },{ value: "cbr", label: "CBR", group: "Archive" },@@ -128,7 +153,12 @@ export const FROM_FORMAT_OPTIONS = [{ value: "txt", label: "TXT", group: "Text" },{ value: "rtf", label: "RTF", group: "Text" },{ value: "eml", label: "EML", group: "Email" },- { value: "msg", label: "MSG (Outlook)", group: "Email" },+ {+ value: "msg",+ label: "MSG (Outlook)",+ labelKey: "convert.formatOptions.msgOutlook",+ group: "Email",+ },{ value: "epub", label: "EPUB", group: "eBook" },{ value: "mobi", label: "MOBI", group: "eBook" },{ value: "azw3", label: "AZW3", group: "eBook" },diff --git a/frontend/editor/src/core/hooks/useGoogleDrivePicker.ts b/frontend/editor/src/core/hooks/useGoogleDrivePicker.tsindex acc0890b01..564561d2a6 100644--- a/frontend/editor/src/core/hooks/useGoogleDrivePicker.ts+++ b/frontend/editor/src/core/hooks/useGoogleDrivePicker.ts@@ -1,4 +1,5 @@import { useState, useCallback, useEffect, useMemo } from "react";+import { useTranslation } from "react-i18next";import { useAppConfig } from "@app/contexts/AppConfigContext";import {getGoogleDrivePickerService,@@ -22,6 +23,7 @@ interface UseGoogleDrivePickerReturn {/** Initializes Drive lazily; failed picks resolve to [] and set error until cleared or retried. */export function useGoogleDrivePicker(): UseGoogleDrivePickerReturn {+ const { t } = useTranslation();const { config } = useAppConfig();const [isEnabled, setIsEnabled] = useState(false);const [isLoading, setIsLoading] = useState(false);@@ -53,18 +55,28 @@ export function useGoogleDrivePicker(): UseGoogleDrivePickerReturn {const googleDriveConfig = getGoogleDriveConfig(googleDriveBackendConfig);if (!googleDriveConfig) {- throw new Error("Google Drive is not configured");+ throw new Error(+ t(+ "provider.googledrive.errors.notConfigured",+ "Google Drive is not configured",+ ),+ );}const service = getGoogleDrivePickerService();await service.initialize(googleDriveConfig);setIsInitialized(true);- }, [isInitialized, googleDriveBackendConfig]);+ }, [isInitialized, googleDriveBackendConfig, t]);const openPicker = useCallback(async (options: UseGoogleDrivePickerOptions = {}): Promise<File[]> => {if (!isEnabled) {- setError("Google Drive is not configured");+ setError(+ t(+ "provider.googledrive.errors.notConfigured",+ "Google Drive is not configured",+ ),+ );return [];}@@ -85,7 +97,10 @@ export function useGoogleDrivePicker(): UseGoogleDrivePickerReturn {const errorMessage =err instanceof Error? err.message- : "Failed to open Google Drive picker";+ : t(+ "provider.googledrive.errors.pickerFailed",+ "Failed to open Google Drive picker",+ );setError(errorMessage);console.error("Google Drive picker error:", err);return [];@@ -93,7 +108,7 @@ export function useGoogleDrivePicker(): UseGoogleDrivePickerReturn {setIsLoading(false);}},- [isEnabled, initializeService],+ [isEnabled, initializeService, t],);return {diff --git a/frontend/editor/src/core/pages/MobileSignPage.tsx b/frontend/editor/src/core/pages/MobileSignPage.tsxindex b2537ffb00..c57ed8e5c9 100644--- a/frontend/editor/src/core/pages/MobileSignPage.tsx+++ b/frontend/editor/src/core/pages/MobileSignPage.tsx@@ -32,8 +32,8 @@ type SignatureTab = "draw" | "type" | "photo";// Ink pigments, not UI theme colours: they are baked into the exported PNG// and transferred to the desktop, so they must be fixed literals.const INK_COLORS = [- { value: "#101010", label: "black" }, // theme-allow-color ink pigment, serialized into the signature- { value: "#1d4ed8", label: "blue" }, // theme-allow-color ink pigment, serialized into the signature+ { value: "#101010", labelKey: "black", label: "Black" }, // theme-allow-color ink pigment, serialized into the signature+ { value: "#1d4ed8", labelKey: "blue", label: "Blue" }, // theme-allow-color ink pigment, serialized into the signature];const PEN_SIZES = [@@ -350,7 +350,7 @@ export default function MobileSignPage() {key={color.value}component="button"onClick={() => setInkColor(color.value)}- aria-label={color.label}+ aria-label={t(color.labelKey, color.label)}style={{width: 32,height: 32,@@ -421,7 +421,7 @@ export default function MobileSignPage() {key={color.value}component="button"onClick={() => setInkColor(color.value)}- aria-label={color.label}+ aria-label={t(color.labelKey, color.label)}style={{width: 32,height: 32,@@ -477,7 +477,7 @@ export default function MobileSignPage() {<Card withBorder radius="md" style={{ background: "white" }}><Imagesrc={photoDataUrl}- alt="Signature"+ alt={t("mobileSign.photo.previewAlt", "Signature")}fit="contain"mah={220}/>diff --git a/frontend/editor/src/core/tools/AdjustContrast.tsx b/frontend/editor/src/core/tools/AdjustContrast.tsxindex ba94258e26..768aa220ea 100644--- a/frontend/editor/src/core/tools/AdjustContrast.tsx+++ b/frontend/editor/src/core/tools/AdjustContrast.tsx@@ -105,7 +105,10 @@ const AdjustContrast = (props: BaseToolProps) => {color: "var(--text-color-muted)",}}>- {`${previewIndex + 1} of ${totalSelected}`}+ {t("common.nOfTotal", "{{current}} of {{total}}", {+ current: previewIndex + 1,+ total: totalSelected,+ })}</div>)}</div>diff --git a/frontend/editor/src/core/tools/AdjustPageScale.tsx b/frontend/editor/src/core/tools/AdjustPageScale.tsxindex fd2806e2e1..e004c81950 100644--- a/frontend/editor/src/core/tools/AdjustPageScale.tsx+++ b/frontend/editor/src/core/tools/AdjustPageScale.tsx@@ -25,7 +25,7 @@ const AdjustPageScale = (props: BaseToolProps) => {},steps: [{- title: "Settings",+ title: t("adjustPageScale.settings.title", "Settings"),isCollapsed: base.settingsCollapsed,onCollapsedClick: base.settingsCollapsed? base.handleSettingsResetdiff --git a/frontend/editor/src/core/tools/BookletImposition.tsx b/frontend/editor/src/core/tools/BookletImposition.tsxindex 834758c95c..20008ec5d4 100644--- a/frontend/editor/src/core/tools/BookletImposition.tsx+++ b/frontend/editor/src/core/tools/BookletImposition.tsx@@ -26,7 +26,7 @@ const BookletImposition = (props: BaseToolProps) => {},steps: [{- title: "Settings",+ title: t("bookletImposition.settings.title", "Settings"),isCollapsed: base.settingsCollapsed,onCollapsedClick: base.settingsCollapsed? base.handleSettingsResetdiff --git a/frontend/editor/src/core/tools/Compare.tsx b/frontend/editor/src/core/tools/Compare.tsxindex eb34646258..80f4c535ab 100644--- a/frontend/editor/src/core/tools/Compare.tsx+++ b/frontend/editor/src/core/tools/Compare.tsx@@ -119,7 +119,7 @@ const Compare = (props: BaseToolProps) => {registerCustomWorkbenchView({id: CUSTOM_VIEW_ID,workbenchId: CUSTOM_WORKBENCH_ID,- label: "Compare view",+ label: t("compare.workbenchLabel", "Compare view"),icon: compareIcon,component: CompareWorkbenchView,});diff --git a/frontend/editor/src/core/tools/Compress.tsx b/frontend/editor/src/core/tools/Compress.tsxindex 8525b73c2a..7befcb8b6c 100644--- a/frontend/editor/src/core/tools/Compress.tsx+++ b/frontend/editor/src/core/tools/Compress.tsx@@ -25,7 +25,7 @@ const Compress = (props: BaseToolProps) => {},steps: [{- title: "Settings",+ title: t("compress.settings.title", "Settings"),isCollapsed: base.settingsCollapsed,onCollapsedClick: base.settingsCollapsed? base.handleSettingsResetdiff --git a/frontend/editor/src/core/tools/EditTableOfContents.tsx b/frontend/editor/src/core/tools/EditTableOfContents.tsxindex 89a3880e17..e6f643acc4 100644--- a/frontend/editor/src/core/tools/EditTableOfContents.tsx+++ b/frontend/editor/src/core/tools/EditTableOfContents.tsx@@ -92,7 +92,7 @@ const EditTableOfContents = (props: BaseToolProps) => {registerCustomWorkbenchView({id: WORKBENCH_VIEW_ID,workbenchId: WORKBENCH_ID,- label: "Outline workspace",+ label: t("editTableOfContents.workbenchLabel", "Outline workspace"),icon: viewIcon,component: EditTableOfContentsWorkbenchView,});diff --git a/frontend/editor/src/core/tools/Merge.tsx b/frontend/editor/src/core/tools/Merge.tsxindex ae2bed26fe..8ef72136fd 100644--- a/frontend/editor/src/core/tools/Merge.tsx+++ b/frontend/editor/src/core/tools/Merge.tsx@@ -138,7 +138,7 @@ const Merge = (props: BaseToolProps) => {},steps: [{- title: "Sort Files",+ title: t("merge.sortFiles.title", "Sort Files"),isCollapsed: base.settingsCollapsed,content: (<MergeFileSorter@@ -148,7 +148,7 @@ const Merge = (props: BaseToolProps) => {),},{- title: "Settings",+ title: t("merge.settings.title", "Settings"),isCollapsed: base.settingsCollapsed,onCollapsedClick: base.settingsCollapsed? base.handleSettingsResetdiff --git a/frontend/editor/src/core/tools/OCR.tsx b/frontend/editor/src/core/tools/OCR.tsxindex 257d1c26c7..7efb6ea35f 100644--- a/frontend/editor/src/core/tools/OCR.tsx+++ b/frontend/editor/src/core/tools/OCR.tsx@@ -113,7 +113,7 @@ const OCR = ({ onPreviewFile, onComplete, onError }: BaseToolProps) => {),},{- title: "Advanced",+ title: t("ocr.advanced.title", "Advanced"),isCollapsed: expandedStep !== "advanced",onCollapsedClick: hasResults? handleSettingsResetdiff --git a/frontend/editor/src/core/tools/PageLayout.tsx b/frontend/editor/src/core/tools/PageLayout.tsxindex f4779ae312..ae68580141 100644--- a/frontend/editor/src/core/tools/PageLayout.tsx+++ b/frontend/editor/src/core/tools/PageLayout.tsx@@ -52,7 +52,7 @@ const PageLayout = (props: BaseToolProps) => {preview: <PageLayoutPreview parameters={base.params.parameters} />,steps: [{- title: "Layout settings",+ title: t("pageLayout.steps.layout", "Layout settings"),isCollapsed: accordion.getCollapsedState(PageLayoutStep.LAYOUT),onCollapsedClick: () =>accordion.handleStepToggle(PageLayoutStep.LAYOUT),@@ -66,7 +66,7 @@ const PageLayout = (props: BaseToolProps) => {),},{- title: "Advanced settings",+ title: t("pageLayout.steps.advanced", "Advanced settings"),isCollapsed: accordion.getCollapsedState(PageLayoutStep.ADVANCED),onCollapsedClick: () =>accordion.handleStepToggle(PageLayoutStep.ADVANCED),@@ -80,7 +80,7 @@ const PageLayout = (props: BaseToolProps) => {),},{- title: "Margins and borders",+ title: t("pageLayout.steps.marginsBorders", "Margins and borders"),isCollapsed: accordion.getCollapsedState(PageLayoutStep.MARGINS_BORDERS,),diff --git a/frontend/editor/src/core/tools/Rotate.tsx b/frontend/editor/src/core/tools/Rotate.tsxindex 565953d1fd..a4c86c2c56 100644--- a/frontend/editor/src/core/tools/Rotate.tsx+++ b/frontend/editor/src/core/tools/Rotate.tsx@@ -25,7 +25,7 @@ const Rotate = (props: BaseToolProps) => {},steps: [{- title: "Settings",+ title: t("rotate.settings.title", "Settings"),isCollapsed: base.settingsCollapsed,onCollapsedClick: base.settingsCollapsed? base.handleSettingsResetdiff --git a/frontend/editor/src/core/tools/ScannerImageSplit.tsx b/frontend/editor/src/core/tools/ScannerImageSplit.tsxindex 95093be9c4..59d863078a 100644--- a/frontend/editor/src/core/tools/ScannerImageSplit.tsx+++ b/frontend/editor/src/core/tools/ScannerImageSplit.tsx@@ -25,7 +25,7 @@ const ScannerImageSplit = (props: BaseToolProps) => {},steps: [{- title: "Settings",+ title: t("scannerImageSplit.settings.title", "Settings"),isCollapsed: base.settingsCollapsed,onCollapsedClick: base.settingsCollapsed? base.handleSettingsResetdiff --git a/frontend/editor/src/core/tools/formFill/FormFieldCreatePanel.tsx b/frontend/editor/src/core/tools/formFill/FormFieldCreatePanel.tsxindex c6587956aa..8d6a319372 100644--- a/frontend/editor/src/core/tools/formFill/FormFieldCreatePanel.tsx+++ b/frontend/editor/src/core/tools/formFill/FormFieldCreatePanel.tsx@@ -38,14 +38,17 @@ interface FormFieldCreatePanelProps {onApplied?: (blob: Blob) => void;}-const TYPE_LABEL: Record<CreatableFieldType, string> = {- text: "Text",- checkbox: "Checkbox",- combobox: "Dropdown",- listbox: "List box",- radio: "Radio",- button: "Button",- signature: "Signature",+const TYPE_LABEL: Record<+ CreatableFieldType,+ { key: string; fallback: string }+> = {+ text: { key: "formFill.fieldTypes.text", fallback: "Text" },+ checkbox: { key: "formFill.fieldTypes.checkbox", fallback: "Checkbox" },+ combobox: { key: "formFill.fieldTypes.combobox", fallback: "Dropdown" },+ listbox: { key: "formFill.fieldTypes.listbox", fallback: "List box" },+ radio: { key: "formFill.fieldTypes.radio", fallback: "Radio" },+ button: { key: "formFill.fieldTypes.button", fallback: "Button" },+ signature: { key: "formFill.fieldTypes.signature", fallback: "Signature" },};export function FormFieldCreatePanel({@@ -53,6 +56,8 @@ export function FormFieldCreatePanel({onApplied,}: FormFieldCreatePanelProps) {const { t } = useTranslation();+ const typeLabel = (type: CreatableFieldType) =>+ t(TYPE_LABEL[type].key, TYPE_LABEL[type].fallback);const {creationType,setCreationType,@@ -128,7 +133,7 @@ export function FormFieldCreatePanel({onClick={() => setCreationType(armed ? null : type)}data-testid={`form-create-type-${type}`}>- {TYPE_LABEL[type]}+ {typeLabel(type)}</Button>);})}@@ -140,7 +145,7 @@ export function FormFieldCreatePanel({{t("formFill.create.placing","Draw a {{type}} field on the page. Press Esc to stop.",- { type: TYPE_LABEL[creationType] },+ { type: typeLabel(creationType) },)}</Text></Alert>diff --git a/frontend/editor/src/core/tools/formFill/FormFieldOverlay.tsx b/frontend/editor/src/core/tools/formFill/FormFieldOverlay.tsxindex 45b658d69d..e15948c228 100644--- a/frontend/editor/src/core/tools/formFill/FormFieldOverlay.tsx+++ b/frontend/editor/src/core/tools/formFill/FormFieldOverlay.tsx@@ -18,6 +18,7 @@* AnnotationLayer, and LinkLayer.*/import React, { useCallback, useMemo, memo } from "react";+import { useTranslation } from "react-i18next";import { useDocumentState } from "@embedpdf/core/react";import {useFormFill,@@ -196,6 +197,7 @@ function WidgetInputInner({onButtonClick,editing,}: WidgetInputProps) {+ const { t } = useTranslation();// Per-field value subscription — only this widget re-renders when its value changesconst value = useFieldValue(field.name);@@ -447,7 +449,11 @@ function WidgetInputInner({aria-invalid={!!error}{...captureStopProps}>- {!field.multiSelect && <option value="">— select —</option>}+ {!field.multiSelect && (+ <option value="">+ {t("formFill.selectOptionPlaceholder", "— select —")}+ </option>+ )}{(field.options || []).map((opt, idx) => (<option key={opt} value={opt}>{(field.displayOptions && field.displayOptions[idx]) || opt}diff --git a/frontend/editor/src/core/tools/formFill/FormFieldPropertyEditor.tsx b/frontend/editor/src/core/tools/formFill/FormFieldPropertyEditor.tsxindex a0f0d0b552..cdeb6d987d 100644--- a/frontend/editor/src/core/tools/formFill/FormFieldPropertyEditor.tsx+++ b/frontend/editor/src/core/tools/formFill/FormFieldPropertyEditor.tsx@@ -82,14 +82,14 @@ interface FormFieldPropertyEditorProps {allowTypeChange?: boolean;}-const TYPE_LABEL: Record<string, string> = {- text: "Text",- checkbox: "Checkbox",- combobox: "Dropdown",- listbox: "List box",- radio: "Radio group",- button: "Button",- signature: "Signature",+const TYPE_LABEL: Record<string, { key: string; fallback: string }> = {+ text: { key: "formFill.fieldTypes.text", fallback: "Text" },+ checkbox: { key: "formFill.fieldTypes.checkbox", fallback: "Checkbox" },+ combobox: { key: "formFill.fieldTypes.combobox", fallback: "Dropdown" },+ listbox: { key: "formFill.fieldTypes.listbox", fallback: "List box" },+ radio: { key: "formFill.fieldTypes.radioGroup", fallback: "Radio group" },+ button: { key: "formFill.fieldTypes.button", fallback: "Button" },+ signature: { key: "formFill.fieldTypes.signature", fallback: "Signature" },};// Type-change is only safe between the "simple" single-widget types; retyping@@ -132,6 +132,10 @@ export function FormFieldPropertyEditor({allowTypeChange = false,}: FormFieldPropertyEditorProps) {const { t } = useTranslation();+ const typeLabel = (type: string): string | undefined => {+ const entry = TYPE_LABEL[type];+ return entry ? t(entry.key, entry.fallback) : undefined;+ };const hasOptions =value.type === "combobox" ||value.type === "listbox" ||@@ -234,10 +238,10 @@ export function FormFieldPropertyEditor({value={canRetype ? value.type : null}data={TYPE_CHANGE_OPTIONS.map((tp) => ({value: tp,- label: TYPE_LABEL[tp],+ label: typeLabel(tp) ?? tp,}))}disabled={!canRetype}- placeholder={canRetype ? undefined : TYPE_LABEL[value.type]}+ placeholder={canRetype ? undefined : typeLabel(value.type)}onChange={(v) => v && onChange({ type: v })}comboboxProps={{ withinPortal: true }}/>diff --git a/frontend/editor/src/core/tools/formFill/FormFieldSidebar.tsx b/frontend/editor/src/core/tools/formFill/FormFieldSidebar.tsxindex 4d9ae167ab..8861772e2c 100644--- a/frontend/editor/src/core/tools/formFill/FormFieldSidebar.tsx+++ b/frontend/editor/src/core/tools/formFill/FormFieldSidebar.tsx@@ -102,7 +102,7 @@ export function FormFieldSidebar({ visible, onToggle }: FormFieldSidebarProps) {<div style={{ display: "flex", alignItems: "center", gap: "0.5rem" }}><Icon name="type" size={18} style={{ opacity: 0.7 }} /><Text fw={600} size="sm">- Form Fields+ {t("formFill.sidebar.title", "Form Fields")}</Text><Badge size="xs" variant="light" color="blue" radius="sm">{fields.length}@@ -123,7 +123,7 @@ export function FormFieldSidebar({ visible, onToggle }: FormFieldSidebarProps) {{loading && (<div className={styles.emptyState}><Text size="sm" c="dimmed">- Loading form fields...+ {t("formFill.sidebar.loading", "Loading form fields...")}</Text></div>)}@@ -131,7 +131,7 @@ export function FormFieldSidebar({ visible, onToggle }: FormFieldSidebarProps) {{!loading && fields.length === 0 && (<div className={styles.emptyState}><span className={styles.emptyStateText}>- No form fields found in this PDF+ {t("formFill.sidebar.empty", "No form fields found in this PDF")}</span></div>)}@@ -145,7 +145,9 @@ export function FormFieldSidebar({ visible, onToggle }: FormFieldSidebarProps) {style={i === 0 ? { marginTop: 0 } : undefined}><Text className={styles.pageDividerLabel}>- Page {pageIdx + 1}+ {t("formFill.sidebar.pageNumber", "Page {{page}}", {+ page: pageIdx + 1,+ })}</Text></div>@@ -160,7 +162,14 @@ export function FormFieldSidebar({ visible, onToggle }: FormFieldSidebarProps) {onClick={() => handleFieldClick(field.name)}><div className={styles.fieldHeader}>- <Tooltip label={field.type} withArrow position="left">+ <Tooltip+ label={t(+ `formFill.fieldTypes.${field.type}`,+ field.type,+ )}+ withArrow+ position="left"+ ><spanclassName={styles.fieldTypeIcon}style={{@@ -177,7 +186,9 @@ export function FormFieldSidebar({ visible, onToggle }: FormFieldSidebarProps) {{field.label || field.name}</span>{field.required && (- <span className={styles.fieldRequired}>req</span>+ <span className={styles.fieldRequired}>+ {t("formFill.requiredAbbreviation", "req")}+ </span>)}</div>diff --git a/frontend/editor/src/core/tools/pdfTextEditor/components/PageView.tsx b/frontend/editor/src/core/tools/pdfTextEditor/components/PageView.tsxindex 129cfdd870..7696bd2714 100644--- a/frontend/editor/src/core/tools/pdfTextEditor/components/PageView.tsx+++ b/frontend/editor/src/core/tools/pdfTextEditor/components/PageView.tsx@@ -1,5 +1,6 @@import { useEffect, useRef, useState } from "react";import { Box, Loader } from "@mantine/core";+import { useTranslation } from "react-i18next";import { Button } from "@app/ui/Button";import { PdfiumPageRenderer } from "@app/tools/pdfTextEditor/pdfium/PdfiumPageRenderer";import type { EditorDocument } from "@app/tools/pdfTextEditor/model/EditorDocument";@@ -83,6 +84,7 @@ export function PageView({onFirstVisible,onFirstRendered,}: PageViewProps) {+ const { t } = useTranslation();const canvasRef = useRef<HTMLCanvasElement | null>(null);const containerRef = useRef<HTMLDivElement | null>(null);// `raster` is the CSS layout size; the bitmap itself renders at deviceScale@@ -262,7 +264,9 @@ export function PageView({}}data-testid={`pdf-editor-page-${page.pageIndex}-placeholder`}>- Page {page.pageIndex + 1}+ {t("pdfTextEditor.pageView.pageNumber", "Page {{page}}", {+ page: page.pageIndex + 1,+ })}</Box>)}{rendering && nearViewport && (@@ -292,17 +296,19 @@ export function PageView({}}data-testid={`pdf-editor-page-${page.pageIndex}-error`}>- <span style={{ fontSize: 13 }}>Failed to render page</span>+ <span style={{ fontSize: 13 }}>+ {t("pdfTextEditor.pageView.renderFailed", "Failed to render page")}+ </span><span style={{ fontSize: 11, opacity: 0.8 }}>{renderError}</span><Buttontype="button"size="sm"variant="secondary"accent="danger"- onClick={() => setRetryToken((t) => t + 1)}+ onClick={() => setRetryToken((token) => token + 1)}data-testid={`pdf-editor-page-${page.pageIndex}-retry`}>- Retry+ {t("common.retry", "Retry")}</Button></Box>)}diff --git a/frontend/editor/src/core/ui/Banner.tsx b/frontend/editor/src/core/ui/Banner.tsxindex ca89f57aab..cd84ee2a56 100644--- a/frontend/editor/src/core/ui/Banner.tsx+++ b/frontend/editor/src/core/ui/Banner.tsx@@ -1,4 +1,5 @@import type { ReactNode } from "react";+import { useTranslation } from "react-i18next";import { ActionIcon } from "@app/ui/ActionIcon";import "@app/ui/Banner.css";@@ -27,6 +28,7 @@ export function Banner({className,children,}: BannerProps) {+ const { t } = useTranslation();return (<divrole="status"@@ -53,7 +55,7 @@ export function Banner({shape="circle"className="sui-banner__close"onClick={onDismiss}- aria-label="Dismiss"+ aria-label={t("common.dismiss", "Dismiss")}><span aria-hidden>×</span></ActionIcon>diff --git a/frontend/editor/src/core/ui/Button.tsx b/frontend/editor/src/core/ui/Button.tsxindex 4b6bf2db85..5554ba9ef5 100644--- a/frontend/editor/src/core/ui/Button.tsx+++ b/frontend/editor/src/core/ui/Button.tsx@@ -1,5 +1,6 @@import { Button as MantineButton } from "@mantine/core";import { forwardRef } from "react";+import { useTranslation } from "react-i18next";import type {ComponentPropsWithoutRef,CSSProperties,@@ -150,6 +151,7 @@ const ButtonRoot = forwardRef<HTMLButtonElement, ButtonProps>(},ref,) {+ const { t } = useTranslation();const label = text ?? children;const hasLabel = label != null && label !== false && label !== "";// A labelless button collapses to a square icon-only button — but never when@@ -162,7 +164,7 @@ const ButtonRoot = forwardRef<HTMLButtonElement, ButtonProps>(// accessible name; the spinner and any icon are decorative.const fallbackLabel =!hasLabel && loading && !rest["aria-label"] && !rest["aria-labelledby"]- ? "Loading"+ ? t("common.loading", "Loading..."): undefined;// px/py override p for their axis; each stays undefined (= size default) if unset.diff --git a/frontend/editor/src/core/ui/CarouselDots.tsx b/frontend/editor/src/core/ui/CarouselDots.tsxindex 67fd006c7f..3b3cb21349 100644--- a/frontend/editor/src/core/ui/CarouselDots.tsx+++ b/frontend/editor/src/core/ui/CarouselDots.tsx@@ -1,4 +1,5 @@import type { CSSProperties } from "react";+import { useTranslation } from "react-i18next";import "@app/ui/CarouselDots.css";/** default = blue pill on light surfaces; onImage = white dots over dark photography. */@@ -31,6 +32,7 @@ export function CarouselDots({className,style,}: CarouselDotsProps) {+ const { t } = useTranslation();const classes = ["sui-carousel-dots",`sui-carousel-dots--${tone}`,@@ -49,7 +51,13 @@ export function CarouselDots({type="button"className={"sui-carousel-dots__dot" + (active ? " is-active" : "")}aria-current={active ? "true" : undefined}- aria-label={dotLabel ? dotLabel(i) : `Go to slide ${i + 1}`}+ aria-label={+ dotLabel+ ? dotLabel(i)+ : t("common.goToSlide", "Go to slide {{number}}", {+ number: i + 1,+ })+ }onClick={onSelect ? () => onSelect(i) : undefined}/>);diff --git a/frontend/editor/src/core/ui/ChatFABButton.tsx b/frontend/editor/src/core/ui/ChatFABButton.tsxindex b80c985b66..e1ee7cea96 100644--- a/frontend/editor/src/core/ui/ChatFABButton.tsx+++ b/frontend/editor/src/core/ui/ChatFABButton.tsx@@ -1,4 +1,5 @@import type { ButtonHTMLAttributes } from "react";+import { useTranslation } from "react-i18next";import { BrandMark } from "@app/components/shared/BrandMark";import "@app/ui/ChatFABButton.css";@@ -15,6 +16,7 @@ export function ChatFABButton({className,...rest}: ChatFABButtonProps) {+ const { t } = useTranslation();const classes = ["chat-fab-btn",loading ? "chat-fab-btn--loading" : "",@@ -28,7 +30,7 @@ export function ChatFABButton({<buttontype="button"className={classes}- aria-label="Open assistant"+ aria-label={t("portal.assistant.open", "Open assistant")}{...rest}>{/* Decorative: the button itself carries the accessible name. */}diff --git a/frontend/editor/src/core/ui/CodeBlock.tsx b/frontend/editor/src/core/ui/CodeBlock.tsxindex 7f3b850d28..fa97d70d58 100644--- a/frontend/editor/src/core/ui/CodeBlock.tsx+++ b/frontend/editor/src/core/ui/CodeBlock.tsx@@ -64,7 +64,7 @@ export function CodeBlock({shape="pill"className="sui-code__copy"onClick={copy}- aria-label="Copy code"+ aria-label={t("common.copyCode", "Copy code")}>{copied ? t("common.copied", "Copied!") : t("common.copy", "Copy")}</Button>diff --git a/frontend/editor/src/core/ui/DataTable.tsx b/frontend/editor/src/core/ui/DataTable.tsxindex 84dba6ef41..552f522931 100644--- a/frontend/editor/src/core/ui/DataTable.tsx+++ b/frontend/editor/src/core/ui/DataTable.tsx@@ -149,12 +149,14 @@ export function DataTable<T extends RowData>({toolbar,variant = "default",caption,- collapseLabels = {- showAll: (n) => `Show all ${n}`,- showLess: "Show less",- },+ collapseLabels,}: DataTableProps<T>) {const { t } = useTranslation();+ const resolvedCollapseLabels = collapseLabels ?? {+ showAll: (total: number) =>+ t("common.showAllTotal", "Show all {{total}}", { total }),+ showLess: t("common.showLess", "Show less"),+ };const [sorting, setSorting] = useState<SortingState>(defaultSort? [{ id: defaultSort.key, desc: defaultSort.direction === "desc" }]@@ -326,7 +328,7 @@ export function DataTable<T extends RowData>({}colSpan={colCount}>- {empty ?? "No data"}+ {empty ?? t("common.noData", "No data")}</td></tr>);@@ -375,8 +377,8 @@ export function DataTable<T extends RowData>({onClick={() => toggleGroup(g.key)}>{open- ? collapseLabels.showLess- : collapseLabels.showAll(g.rows.length)}+ ? resolvedCollapseLabels.showLess+ : resolvedCollapseLabels.showAll(g.rows.length)}</button></td></tr>diff --git a/frontend/editor/src/core/ui/Drawer.tsx b/frontend/editor/src/core/ui/Drawer.tsxindex 8ef10baf79..b8ccf7c615 100644--- a/frontend/editor/src/core/ui/Drawer.tsx+++ b/frontend/editor/src/core/ui/Drawer.tsx@@ -1,6 +1,7 @@import { useEffect, useId, type ReactNode } from "react";import { createPortal } from "react-dom";import { FocusTrap } from "@mantine/core";+import { useTranslation } from "react-i18next";import { Button } from "@app/ui/Button";import "@app/ui/Drawer.css";@@ -38,6 +39,7 @@ export function Drawer({ariaLabel,children,}: DrawerProps) {+ const { t } = useTranslation();const titleId = useId();useEffect(() => {@@ -108,7 +110,7 @@ export function Drawer({shape="circle"className="sui-drawer__close"onClick={onClose}- aria-label="Close"+ aria-label={t("common.close", "Close")}leftSection={<svgviewBox="0 0 24 24"diff --git a/frontend/editor/src/core/ui/InfoTooltip.tsx b/frontend/editor/src/core/ui/InfoTooltip.tsxindex 9c3572565b..b03ffa217a 100644--- a/frontend/editor/src/core/ui/InfoTooltip.tsx+++ b/frontend/editor/src/core/ui/InfoTooltip.tsx@@ -1,5 +1,6 @@import type { ReactNode } from "react";import { Tooltip, type FloatingPosition } from "@mantine/core";+import { useTranslation } from "react-i18next";import "@app/ui/InfoTooltip.css";export interface InfoTooltipProps {@@ -21,6 +22,7 @@ export function InfoTooltip({ariaLabel,position = "top",}: InfoTooltipProps) {+ const { t } = useTranslation();return (<Tooltiplabel={label}@@ -34,7 +36,10 @@ export function InfoTooltip({type="button"className="sui-info"aria-label={- ariaLabel ?? (typeof label === "string" ? label : "More information")+ ariaLabel ??+ (typeof label === "string"+ ? label+ : t("common.moreInformation", "More information"))}><svgdiff --git a/frontend/editor/src/core/ui/Modal.tsx b/frontend/editor/src/core/ui/Modal.tsxindex 21c1b58c18..495d343089 100644--- a/frontend/editor/src/core/ui/Modal.tsx+++ b/frontend/editor/src/core/ui/Modal.tsx@@ -1,6 +1,7 @@import { useEffect, useId, useRef, type ReactNode } from "react";import { createPortal } from "react-dom";import { FocusTrap } from "@mantine/core";+import { useTranslation } from "react-i18next";import { Button } from "@app/ui/Button";import { useIsOverflowing } from "@app/hooks/useIsOverflowing";import "@app/ui/Modal.css";@@ -45,6 +46,7 @@ export function Modal({zIndex,children,}: ModalProps) {+ const { t } = useTranslation();const titleId = useId();const bodyRef = useRef<HTMLDivElement>(null);// A body that overflows must be reachable by keyboard to scroll; only its non-focusable@@ -107,7 +109,7 @@ export function Modal({shape="circle"className="sui-modal__back"onClick={onBack}- aria-label={backLabel ?? "Back"}+ aria-label={backLabel ?? t("common.back", "Back")}leftSection={<svgviewBox="0 0 24 24"@@ -141,7 +143,7 @@ export function Modal({shape="circle"className="sui-modal__close"onClick={onClose}- aria-label="Close"+ aria-label={t("common.close", "Close")}leftSection={<svgviewBox="0 0 24 24"diff --git a/frontend/editor/src/core/ui/SettingsShell.tsx b/frontend/editor/src/core/ui/SettingsShell.tsxindex 8e86715d80..2e47dd6219 100644--- a/frontend/editor/src/core/ui/SettingsShell.tsx+++ b/frontend/editor/src/core/ui/SettingsShell.tsx@@ -1,4 +1,5 @@import type { ReactNode } from "react";+import { useTranslation } from "react-i18next";import { Button } from "@app/ui/Button";import "@app/ui/SettingsShell.css";@@ -42,13 +43,17 @@ export function SettingsShell({children,className,}: SettingsShellProps) {+ const { t } = useTranslation();return (<divclassName={["sui-settings-shell", className ?? ""].filter(Boolean).join(" ")}>- <nav className="sui-settings-shell__nav" aria-label="Settings sections">+ <nav+ className="sui-settings-shell__nav"+ aria-label={t("common.settingsSections", "Settings sections")}+ >{sections.map((section) => (<div key={section.title} className="sui-settings-shell__group"><span className="sui-settings-shell__group-title">@@ -98,7 +103,7 @@ export function SettingsShell({shape="circle"className="sui-settings-shell__close"onClick={onClose}- aria-label="Close"+ aria-label={t("common.close", "Close")}leftSection={<svgviewBox="0 0 24 24"diff --git a/frontend/editor/src/core/ui/Toast.tsx b/frontend/editor/src/core/ui/Toast.tsxindex 12dcc16990..cbda6da026 100644--- a/frontend/editor/src/core/ui/Toast.tsx+++ b/frontend/editor/src/core/ui/Toast.tsx@@ -10,6 +10,7 @@ import {} from "react";import { createPortal } from "react-dom";import { Button } from "@app/ui/Button";+import { useTranslation } from "react-i18next";import "@app/ui/Toast.css";export type ToastTone = "info" | "success" | "warning" | "danger";@@ -85,13 +86,14 @@ function ToastViewport({entries: ToastEntry[];onDismiss: (id: number) => void;}) {+ const { t } = useTranslation();// Portal keeps toasts above any stacking context; document check is SSR safety.if (typeof document === "undefined") return null;return createPortal(<divclassName="sui-toast-viewport"role="region"- aria-label="Notifications"+ aria-label={t("notifications.title", "Notifications")}>{entries.map((entry) => (<ToastItem key={entry.id} entry={entry} onDismiss={onDismiss} />@@ -108,6 +110,7 @@ function ToastItem({entry: ToastEntry;onDismiss: (id: number) => void;}) {+ const { t } = useTranslation();useEffect(() => {// Escape dismisses the focused toast.function onKey(e: KeyboardEvent) {@@ -135,7 +138,7 @@ function ToastItem({shape="circle"className="sui-toast__close"onClick={() => onDismiss(entry.id)}- aria-label="Dismiss"+ aria-label={t("toast.dismiss", "Dismiss")}leftSection={<span>×</span>}/></div>diff --git a/frontend/editor/src/core/utils/measurementUtils.ts b/frontend/editor/src/core/utils/measurementUtils.tsindex d73785d191..5aaf9cfa89 100644--- a/frontend/editor/src/core/utils/measurementUtils.ts+++ b/frontend/editor/src/core/utils/measurementUtils.ts@@ -1,5 +1,6 @@// PDF point to real-world unit conversions+import type { TFunction } from "i18next";import type {Measurement,MeasureScale,@@ -109,16 +110,26 @@ export function parsePresetRatio(preset: string): number | null {// UI dropdown options - shared across componentsexport const UNIT_OPTIONS = [- { value: "m", label: "Meters (m)" },- { value: "cm", label: "Centimeters (cm)" },- { value: "mm", label: "Millimeters (mm)" },- { value: "km", label: "Kilometers (km)" },- { value: "ft", label: "Feet (ft)" },- { value: "in", label: "Inches (in)" },- { value: "yd", label: "Yards (yd)" },- { value: "mi", label: "Miles (mi)" },+ { value: "m", labelKey: "ruler.units.m", label: "Meters (m)" },+ { value: "cm", labelKey: "ruler.units.cm", label: "Centimeters (cm)" },+ { value: "mm", labelKey: "ruler.units.mm", label: "Millimeters (mm)" },+ { value: "km", labelKey: "ruler.units.km", label: "Kilometers (km)" },+ { value: "ft", labelKey: "ruler.units.ft", label: "Feet (ft)" },+ { value: "in", labelKey: "ruler.units.in", label: "Inches (in)" },+ { value: "yd", labelKey: "ruler.units.yd", label: "Yards (yd)" },+ { value: "mi", labelKey: "ruler.units.mi", label: "Miles (mi)" },] as const;+/** UNIT_OPTIONS with labels translated; call at render time. */+export function getUnitOptions(+ t: TFunction,+): { value: (typeof UNIT_OPTIONS)[number]["value"]; label: string }[] {+ return UNIT_OPTIONS.map(({ value, labelKey, label }) => ({+ value,+ label: t(labelKey, label),+ }));+}+const MAX_SESSION_ENTRIES = 50;const TRIMMED_SESSION_ENTRIES = 40;diff --git a/frontend/editor/src/desktop/components/SetupWizard/SaaSSignupScreen.tsx b/frontend/editor/src/desktop/components/SetupWizard/SaaSSignupScreen.tsxindex a3765c2c98..b4fda16f87 100644--- a/frontend/editor/src/desktop/components/SetupWizard/SaaSSignupScreen.tsx+++ b/frontend/editor/src/desktop/components/SetupWizard/SaaSSignupScreen.tsx@@ -67,7 +67,9 @@ export const SaaSSignupScreen: React.FC<SaaSSignupScreenProps> = ({const message =err instanceof Error? err.message- : t("signup.unexpectedError", { message: "Unknown error" });+ : t("signup.unexpectedError", "Unexpected error: {{message}}", {+ message: t("signup.unknownError", "Unknown error"),+ });setValidationError(message);} finally {setIsSignupSubmitting(false);diff --git a/frontend/editor/src/desktop/components/SetupWizard/ServerSelection.tsx b/frontend/editor/src/desktop/components/SetupWizard/ServerSelection.tsxindex fcfc8e9914..479270d481 100644--- a/frontend/editor/src/desktop/components/SetupWizard/ServerSelection.tsx+++ b/frontend/editor/src/desktop/components/SetupWizard/ServerSelection.tsx@@ -195,7 +195,9 @@ export const ServerSelection: React.FC<ServerSelectionProps> = ({// For any other error (network, CORS, invalid JSON, etc.), show error and don't proceedconst errorMessage =- err instanceof Error ? err.message : "Unknown error";+ err instanceof Error+ ? err.message+ : t("setup.server.error.unknown", "Unknown error");console.error("[ServerSelection] Configuration fetch error details:",errorMessage,diff --git a/frontend/editor/src/desktop/components/SetupWizard/index.tsx b/frontend/editor/src/desktop/components/SetupWizard/index.tsxindex b0779e6b78..ea3671c0f6 100644--- a/frontend/editor/src/desktop/components/SetupWizard/index.tsx+++ b/frontend/editor/src/desktop/components/SetupWizard/index.tsx@@ -58,7 +58,7 @@ export const SetupWizard: React.FC<SetupWizardProps> = ({const handleSaaSLogin = async (username: string, password: string) => {if (!serverConfig) {- setError("No SaaS server configured");+ setError(t("setup.error.noSaasServer", "No SaaS server configured"));return;}@@ -78,14 +78,18 @@ export const SetupWizard: React.FC<SetupWizardProps> = ({onComplete();} catch (err) {console.error("SaaS login failed:", err);- setError(err instanceof Error ? err.message : "SaaS login failed");+ setError(+ err instanceof Error+ ? err.message+ : t("setup.error.saasLoginFailed", "SaaS login failed"),+ );setLoading(false);}};const handleSaaSLoginOAuth = async (_userInfo: UserInfo) => {if (!serverConfig) {- setError("No SaaS server configured");+ setError(t("setup.error.noSaasServer", "No SaaS server configured"));return;}@@ -100,7 +104,12 @@ export const SetupWizard: React.FC<SetupWizardProps> = ({} catch (err) {console.error("SaaS OAuth login completion failed:", err);setError(- err instanceof Error ? err.message : "Failed to complete SaaS login",+ err instanceof Error+ ? err.message+ : t(+ "setup.error.saasLoginIncomplete",+ "Failed to complete SaaS login",+ ),);setLoading(false);}@@ -160,7 +169,7 @@ export const SetupWizard: React.FC<SetupWizardProps> = ({if (!serverConfig) {console.error("[SetupWizard] ❌ No server configured");- setError("No server configured");+ setError(t("setup.error.noServer", "No server configured"));return;}@@ -189,7 +198,10 @@ export const SetupWizard: React.FC<SetupWizardProps> = ({onComplete();} catch (err) {console.error("[SetupWizard] ❌ Self-hosted login failed:", err);- let errorMessage = "Self-hosted login failed";+ let errorMessage = t(+ "setup.error.selfHostedLoginFailed",+ "Self-hosted login failed",+ );if (err instanceof AuthServiceError) {if (err.code === "mfa_required" || err.code === "invalid_mfa_code") {setSelfHostedMfaRequired(true);@@ -218,7 +230,7 @@ export const SetupWizard: React.FC<SetupWizardProps> = ({if (!serverConfig) {console.error("[SetupWizard] ❌ No server configured");- setError("No server configured");+ setError(t("setup.error.noServer", "No server configured"));return;}@@ -243,7 +255,9 @@ export const SetupWizard: React.FC<SetupWizardProps> = ({err,);const errorMessage =- err instanceof Error ? err.message : "Failed to complete login";+ err instanceof Error+ ? err.message+ : t("setup.error.loginIncomplete", "Failed to complete login");console.error("[SetupWizard] Error message:", errorMessage);setError(errorMessage);setLoading(false);@@ -320,7 +334,9 @@ export const SetupWizard: React.FC<SetupWizardProps> = ({} catch (err) {console.error("[SetupWizard] Failed to handle deep link", err);setError(- err instanceof Error ? err.message : "Failed to complete signup",+ err instanceof Error+ ? err.message+ : t("setup.error.signupIncomplete", "Failed to complete signup"),);setLoading(false);}diff --git a/frontend/editor/src/desktop/components/layout/TitleBarStrip.tsx b/frontend/editor/src/desktop/components/layout/TitleBarStrip.tsxindex 33b3c82f59..22b464c6e6 100644--- a/frontend/editor/src/desktop/components/layout/TitleBarStrip.tsx+++ b/frontend/editor/src/desktop/components/layout/TitleBarStrip.tsx@@ -1,6 +1,7 @@import { useEffect, useState, type ReactNode } from "react";import { getCurrentWindow } from "@tauri-apps/api/window";import { isTauri } from "@tauri-apps/api/core";+import { useTranslation } from "react-i18next";import { Icon } from "@app/ui/Icon";import { getDesktopOs, DesktopOs } from "@app/services/platformService";import styles from "@app/components/layout/TitleBarStrip.module.css";@@ -28,6 +29,7 @@ interface TitleBarStripProps {* the right, since Tauri has no native-caption-plus-content mode there.*/export function TitleBarStrip({ children }: TitleBarStripProps) {+ const { t } = useTranslation();const [os, setOs] = useState<DesktopOs>(seedOs);const [maximized, setMaximized] = useState(false);const isWindows = os === DesktopOs.Windows;@@ -132,7 +134,7 @@ export function TitleBarStrip({ children }: TitleBarStripProps) {type="button"className={styles.button}onClick={() => void getCurrentWindow().minimize()}- aria-label="Minimize"+ aria-label={t("desktop.titleBar.minimize", "Minimize")}tabIndex={-1}><Icon name="minus" size="1em" />@@ -141,7 +143,11 @@ export function TitleBarStrip({ children }: TitleBarStripProps) {type="button"className={styles.button}onClick={() => void getCurrentWindow().toggleMaximize()}- aria-label={maximized ? "Restore" : "Maximize"}+ aria-label={+ maximized+ ? t("desktop.titleBar.restore", "Restore")+ : t("desktop.titleBar.maximize", "Maximize")+ }tabIndex={-1}>{maximized ? (@@ -154,7 +160,7 @@ export function TitleBarStrip({ children }: TitleBarStripProps) {type="button"className={`${styles.button} ${styles.close}`}onClick={() => void getCurrentWindow().close()}- aria-label="Close"+ aria-label={t("common.close", "Close")}tabIndex={-1}><Icon name="x" size="1em" />diff --git a/frontend/editor/src/portal/components/policies/PolicyPurviewConfig.tsx b/frontend/editor/src/portal/components/policies/PolicyPurviewConfig.tsxindex b21a800a08..3118a05d83 100644--- a/frontend/editor/src/portal/components/policies/PolicyPurviewConfig.tsx+++ b/frontend/editor/src/portal/components/policies/PolicyPurviewConfig.tsx@@ -65,7 +65,10 @@ export function PolicyPurviewConfig({><Inputvalue={parameters.labelName ?? ""}- placeholder="Confidential"+ placeholder={t(+ "portal.policies.config.purview.fields.labelNamePlaceholder",+ "Confidential",+ )}onChange={(e) => set("labelName", e.target.value)}/></FormField>diff --git a/frontend/editor/src/proprietary/components/policies/PolicyRecoveryGate.tsx b/frontend/editor/src/proprietary/components/policies/PolicyRecoveryGate.tsxindex 3e72a9f9f8..74a59a06cc 100644--- a/frontend/editor/src/proprietary/components/policies/PolicyRecoveryGate.tsx+++ b/frontend/editor/src/proprietary/components/policies/PolicyRecoveryGate.tsx@@ -92,7 +92,7 @@ function RecoveryDialog({ blocks, policies, runs }: RecoveryDialogProps) {const labels = new Map(loadPolicyCatalog().categories.map((category) => [category.id,- category.label,+ t(`portal.policies.categories.${category.id}.label`, category.label),]),);const fileIds = affectedFileIds(blocks);diff --git a/frontend/editor/src/proprietary/components/policies/useEditorPipelines.test.tsx b/frontend/editor/src/proprietary/components/policies/useEditorPipelines.test.tsxindex cbf0724cfb..22e273e4bc 100644--- a/frontend/editor/src/proprietary/components/policies/useEditorPipelines.test.tsx+++ b/frontend/editor/src/proprietary/components/policies/useEditorPipelines.test.tsx@@ -13,6 +13,10 @@ vi.mock("@app/services/policyStorage", () => ({loadPolicies: () => cache.value,onPoliciesChange: () => () => {},}));+const i18nMock = vi.hoisted(() => ({+ t: (_key: string, fallback: string) => fallback,+}));+vi.mock("react-i18next", () => ({ useTranslation: () => i18nMock }));vi.mock("@app/services/policyCatalog", () => ({loadPolicyCatalog: () => ({categories: [diff --git a/frontend/editor/src/proprietary/components/policies/useEditorPipelines.ts b/frontend/editor/src/proprietary/components/policies/useEditorPipelines.tsindex cf14a91754..29108383ed 100644--- a/frontend/editor/src/proprietary/components/policies/useEditorPipelines.ts+++ b/frontend/editor/src/proprietary/components/policies/useEditorPipelines.ts@@ -3,6 +3,7 @@* policy cache directly; usePolicies would refire a backend reconcile on every mount.*/import { useEffect, useMemo, useState } from "react";+import { useTranslation } from "react-i18next";import { loadPolicies, onPoliciesChange } from "@app/services/policyStorage";import { loadPolicyCatalog } from "@app/services/policyCatalog";import { editorTriggerOf, type PolicyRunOn } from "@app/policies/runOn";@@ -53,10 +54,14 @@ export function useEditorPipelines(): EditorPipelines {const [policies, setPolicies] = useState<PoliciesByKey>(loadPolicies);useEffect(() => onPoliciesChange(() => setPolicies(loadPolicies())), []);const runs = usePolicyRuns();+ const { t } = useTranslation();return useMemo(() => {const categoryLabels = new Map(- loadPolicyCatalog().categories.map((c) => [c.id, c.label]),+ loadPolicyCatalog().categories.map((c) => [+ c.id,+ t(`portal.policies.categories.${c.id}.label`, c.label),+ ]),);const startOfDay = new Date().setHours(0, 0, 0, 0);const runsByPolicy = new Map<string, PolicyRunRecord[]>();@@ -89,5 +94,5 @@ export function useEditorPipelines(): EditorPipelines {onExport,total: onImport.length + onExport.length,};- }, [policies, runs]);+ }, [policies, runs, t]);}diff --git a/frontend/editor/src/proprietary/components/shared/ManageBillingButton.tsx b/frontend/editor/src/proprietary/components/shared/ManageBillingButton.tsxindex 5583f9c9ff..601b55c14f 100644--- a/frontend/editor/src/proprietary/components/shared/ManageBillingButton.tsx+++ b/frontend/editor/src/proprietary/components/shared/ManageBillingButton.tsx@@ -46,7 +46,10 @@ export const ManageBillingButton: React.FC<ManageBillingButtonProps> = ({title: t("billing.portal.error", "Failed to open billing portal"),body:(error instanceof Error ? error.message : undefined) ||- "Please try again or contact support.",+ t(+ "billing.portal.errorFallback",+ "Please try again or contact support.",+ ),});setLoading(false);}diff --git a/frontend/editor/src/proprietary/components/shared/config/configSections/AdminAuditSection.tsx b/frontend/editor/src/proprietary/components/shared/config/configSections/AdminAuditSection.tsxindex 4618e5184f..854737f0ec 100644--- a/frontend/editor/src/proprietary/components/shared/config/configSections/AdminAuditSection.tsx+++ b/frontend/editor/src/proprietary/components/shared/config/configSections/AdminAuditSection.tsx@@ -64,7 +64,10 @@ const AdminAuditSection: React.FC = () => {setError(err instanceof Error? err.message- : "Failed to load audit system status",+ : t(+ "audit.error.loadStatus",+ "Failed to load audit system status",+ ),);}} finally {diff --git a/frontend/editor/src/proprietary/components/shared/config/configSections/AdminUsageSection.tsx b/frontend/editor/src/proprietary/components/shared/config/configSections/AdminUsageSection.tsxindex 6c46fa913c..b6b94baf39 100644--- a/frontend/editor/src/proprietary/components/shared/config/configSections/AdminUsageSection.tsx+++ b/frontend/editor/src/proprietary/components/shared/config/configSections/AdminUsageSection.tsx@@ -161,7 +161,9 @@ const AdminUsageSection: React.FC = () => {setData(response);} catch (err) {setError(- err instanceof Error ? err.message : "Failed to load usage statistics",+ err instanceof Error+ ? err.message+ : t("usage.loadFailed", "Failed to load usage statistics"),);} finally {setLoading(false);diff --git a/frontend/editor/src/proprietary/components/shared/config/configSections/LoginAgreementEditor.tsx b/frontend/editor/src/proprietary/components/shared/config/configSections/LoginAgreementEditor.tsxindex 6c28b03cb4..e38f4b829f 100644--- a/frontend/editor/src/proprietary/components/shared/config/configSections/LoginAgreementEditor.tsx+++ b/frontend/editor/src/proprietary/components/shared/config/configSections/LoginAgreementEditor.tsx@@ -199,7 +199,10 @@ export default function LoginAgreementEditor({<SimpleGrid cols={{ base: 1, sm: 2 }} spacing="md"><Textarealabel={t("admin.settings.legal.loginAgreement.editLabel", "Markdown")}- placeholder={"## Heading\n\nYour disclaimer text..."}+ placeholder={t(+ "admin.settings.legal.loginAgreement.editPlaceholder",+ "## Heading\n\nYour disclaimer text...",+ )}value={content}onChange={(event) => setContent(event.currentTarget.value)}autosizediff --git a/frontend/editor/src/proprietary/components/shared/config/configSections/ai/AiDocumentsCard.tsx b/frontend/editor/src/proprietary/components/shared/config/configSections/ai/AiDocumentsCard.tsxindex 407099b0c5..3b7ddb3747 100644--- a/frontend/editor/src/proprietary/components/shared/config/configSections/ai/AiDocumentsCard.tsx+++ b/frontend/editor/src/proprietary/components/shared/config/configSections/ai/AiDocumentsCard.tsx@@ -96,7 +96,13 @@ export function AiDocumentsCard({{ value: "voyageai", label: "VoyageAI" },{ value: "openai", label: "OpenAI" },{ value: "ollama", label: "Ollama" },- { value: "custom", label: "Custom (OpenAI-compatible)" },+ {+ value: "custom",+ label: t(+ "admin.settings.ai.customProvider",+ "Custom (OpenAI-compatible)",+ ),+ },]}value={embeddingProvider}onChange={(v) => {diff --git a/frontend/editor/src/proprietary/components/shared/config/configSections/ai/AiModelsCard.tsx b/frontend/editor/src/proprietary/components/shared/config/configSections/ai/AiModelsCard.tsxindex 5e0303c26d..582fcdf6b5 100644--- a/frontend/editor/src/proprietary/components/shared/config/configSections/ai/AiModelsCard.tsx+++ b/frontend/editor/src/proprietary/components/shared/config/configSections/ai/AiModelsCard.tsx@@ -82,7 +82,13 @@ export function AiModelsCard({{ value: "anthropic", label: "Anthropic" },{ value: "openai", label: "OpenAI" },{ value: "ollama", label: "Ollama" },- { value: "custom", label: "Custom (OpenAI-compatible)" },+ {+ value: "custom",+ label: t(+ "admin.settings.ai.customProvider",+ "Custom (OpenAI-compatible)",+ ),+ },]}value={provider}onChange={(v) => {diff --git a/frontend/editor/src/proprietary/components/shared/config/configSections/audit/AuditClearDataSection.tsx b/frontend/editor/src/proprietary/components/shared/config/configSections/audit/AuditClearDataSection.tsxindex 7e25982dc1..e24901f113 100644--- a/frontend/editor/src/proprietary/components/shared/config/configSections/audit/AuditClearDataSection.tsx+++ b/frontend/editor/src/proprietary/components/shared/config/configSections/audit/AuditClearDataSection.tsx@@ -59,7 +59,9 @@ const AuditClearDataSection: React.FC<AuditClearDataSectionProps> = ({setTimeout(() => setSuccess(false), 5000);} catch (err) {setError(- err instanceof Error ? err.message : "Failed to clear audit data",+ err instanceof Error+ ? err.message+ : t("audit.clearData.failed", "Failed to clear audit data"),);} finally {setClearing(false);@@ -74,7 +76,7 @@ const AuditClearDataSection: React.FC<AuditClearDataSectionProps> = ({icon={<Icon name="circle-check" size="1.2rem" />}title={t("audit.clearData.success", "Success")}onClose={() => setSuccess(false)}- closeButtonLabel="Close alert"+ closeButtonLabel={t("audit.clearData.closeAlert", "Close alert")}withCloseButton>{t(diff --git a/frontend/editor/src/proprietary/components/shared/config/configSections/audit/AuditEventsTable.tsx b/frontend/editor/src/proprietary/components/shared/config/configSections/audit/AuditEventsTable.tsxindex 921e5b7578..d457ff4a2c 100644--- a/frontend/editor/src/proprietary/components/shared/config/configSections/audit/AuditEventsTable.tsx+++ b/frontend/editor/src/proprietary/components/shared/config/configSections/audit/AuditEventsTable.tsx@@ -471,7 +471,11 @@ const AuditEventsTable: React.FC<AuditEventsTableProps> = ({setEvents(response.events);setTotalPages(response.totalPages);} catch (err) {- setError(err instanceof Error ? err.message : "Failed to load events");+ setError(+ err instanceof Error+ ? err.message+ : t("audit.events.loadFailed", "Failed to load events"),+ );} finally {setLoading(false);}diff --git a/frontend/editor/src/proprietary/components/shared/config/configSections/audit/AuditStatsCards.tsx b/frontend/editor/src/proprietary/components/shared/config/configSections/audit/AuditStatsCards.tsxindex 6c34380cfd..7b72616f61 100644--- a/frontend/editor/src/proprietary/components/shared/config/configSections/audit/AuditStatsCards.tsx+++ b/frontend/editor/src/proprietary/components/shared/config/configSections/audit/AuditStatsCards.tsx@@ -35,7 +35,9 @@ const AuditStatsCards: React.FC<AuditStatsCardsProps> = ({setStats(data);} catch (err) {setError(- err instanceof Error ? err.message : "Failed to load statistics",+ err instanceof Error+ ? err.message+ : t("audit.stats.loadFailed", "Failed to load statistics"),);} finally {setLoading(false);diff --git a/frontend/editor/src/proprietary/components/shared/config/configSections/server/CustomMetadataCard.tsx b/frontend/editor/src/proprietary/components/shared/config/configSections/server/CustomMetadataCard.tsxindex 09ab64e17b..e33f79c629 100644--- a/frontend/editor/src/proprietary/components/shared/config/configSections/server/CustomMetadataCard.tsx+++ b/frontend/editor/src/proprietary/components/shared/config/configSections/server/CustomMetadataCard.tsx@@ -69,7 +69,10 @@ export function CustomMetadataCard({},})}- placeholder="username"+ placeholder={t(+ "admin.settings.general.customMetadata.author.placeholder",+ "username",+ )}disabled={!loginEnabled}/></div>diff --git a/frontend/editor/src/proprietary/components/shared/config/configSections/server/McpCard.tsx b/frontend/editor/src/proprietary/components/shared/config/configSections/server/McpCard.tsxindex e423ec4758..5e1a93a04b 100644--- a/frontend/editor/src/proprietary/components/shared/config/configSections/server/McpCard.tsx+++ b/frontend/editor/src/proprietary/components/shared/config/configSections/server/McpCard.tsx@@ -89,8 +89,20 @@ export function McpCard({</Group>}data={[- { value: "oauth", label: "OAuth 2.1 (external IdP)" },- { value: "apikey", label: "API key (Stirling per-user key)" },+ {+ value: "oauth",+ label: t(+ "admin.settings.mcp.mode.oauth",+ "OAuth 2.1 (external IdP)",+ ),+ },+ {+ value: "apikey",+ label: t(+ "admin.settings.mcp.mode.apikey",+ "API key (Stirling per-user key)",+ ),+ },]}value={authMode}onChange={(v) => setAuth({ mode: v || "oauth" })}diff --git a/frontend/editor/src/proprietary/components/shared/stripeCheckout/StripeCheckout.tsx b/frontend/editor/src/proprietary/components/shared/stripeCheckout/StripeCheckout.tsxindex dfbd9cb024..4ea6528a66 100644--- a/frontend/editor/src/proprietary/components/shared/stripeCheckout/StripeCheckout.tsx+++ b/frontend/editor/src/proprietary/components/shared/stripeCheckout/StripeCheckout.tsx@@ -286,7 +286,10 @@ const StripeCheckout: React.FC<StripeCheckoutProps> = ({case "error":return (<ErrorStage- error={checkoutState.state.error || "An unknown error occurred"}+ error={+ checkoutState.state.error ||+ t("payment.unknownError", "An unknown error occurred")+ }onClose={handleClose}/>);diff --git a/frontend/editor/src/proprietary/components/shared/stripeCheckout/components/PriceDisplay.tsx b/frontend/editor/src/proprietary/components/shared/stripeCheckout/components/PriceDisplay.tsxindex d2cd569cd2..c07c536fb3 100644--- a/frontend/editor/src/proprietary/components/shared/stripeCheckout/components/PriceDisplay.tsx+++ b/frontend/editor/src/proprietary/components/shared/stripeCheckout/components/PriceDisplay.tsx@@ -1,5 +1,6 @@import React from "react";import { Text, Stack } from "@mantine/core";+import { useTranslation } from "react-i18next";import { formatPrice } from "@app/components/shared/stripeCheckout/utils/pricingUtils";import { PRICE_FONT_WEIGHT } from "@app/components/shared/stripeCheckout/utils/cardStyles";@@ -25,6 +26,7 @@ interface EnterprisePriceProps {type PriceDisplayProps = SimplePriceProps | EnterprisePriceProps;export const PriceDisplay: React.FC<PriceDisplayProps> = (props) => {+ const { t } = useTranslation();if (props.mode === "simple") {const fontSize = props.size || "2.25rem";return (@@ -51,37 +53,47 @@ export const PriceDisplay: React.FC<PriceDisplayProps> = (props) => {} = props;const fontSize = size === "lg" ? "2rem" : size === "sm" ? "md" : "xl";const totalFontSize = size === "lg" ? "2rem" : "2rem";+ const monthLabel = t("plan.period.month", "month");+ const periodLabel =+ period === "year" ? t("plan.period.year", "year") : monthLabel;return (<Stack gap="sm"><div><Text size="sm" c="dimmed" mb="xs">- Base Price+ {t("payment.priceDisplay.basePrice", "Base Price")}</Text><Text size={fontSize} fw={PRICE_FONT_WEIGHT}>{formatPrice(basePrice, currency)}<Text component="span" size="sm" c="dimmed" fw={400}>{" "}- /{period}+ {t("payment.priceDisplay.perPeriod", "/{{period}}", {+ period: periodLabel,+ })}</Text></Text></div><div><Text size="sm" c="dimmed" mb="xs">- Per Seat+ {t("payment.priceDisplay.perSeat", "Per Seat")}</Text><Text size={fontSize} fw={PRICE_FONT_WEIGHT}>{formatPrice(seatPrice, currency)}<Text component="span" size="sm" c="dimmed" fw={400}>{" "}- /seat/{period}+ {t("payment.priceDisplay.perSeatPeriod", "/seat/{{period}}", {+ period: periodLabel,+ })}</Text></Text></div>{totalPrice !== undefined && seatCount && (<div><Text size="sm" c="dimmed" mb="xs">- Total ({seatCount} seats)+ {t("payment.priceDisplay.totalSeats", {+ count: seatCount,+ defaultValue: "Total ({{count}} seats)",+ })}</Text><Textsize={totalFontSize}@@ -91,7 +103,9 @@ export const PriceDisplay: React.FC<PriceDisplayProps> = (props) => {{formatPrice(totalPrice, currency)}<Text component="span" size="sm" c="dimmed" fw={400}>{" "}- /{period === "year" ? "month" : period}+ {t("payment.priceDisplay.perPeriod", "/{{period}}", {+ period: monthLabel,+ })}</Text></Text></div>diff --git a/frontend/editor/src/proprietary/components/workflow/ParticipantView.tsx b/frontend/editor/src/proprietary/components/workflow/ParticipantView.tsxindex 6c3ee988a5..37213609bb 100644--- a/frontend/editor/src/proprietary/components/workflow/ParticipantView.tsx+++ b/frontend/editor/src/proprietary/components/workflow/ParticipantView.tsx@@ -35,7 +35,9 @@ const ParticipantView: React.FC<ParticipantViewProps> = ({ token }) => {const [password, setPassword] = useState<string>("");const [certFile, setCertFile] = useState<File | null>(null);const [location, setLocation] = useState<string>("");- const [reason, setReason] = useState<string>("Document Signing");+ const [reason, setReason] = useState<string>(() =>+ t("workflow.participant.defaultReason", "Document Signing"),+ );const [showSignature, _setShowSignature] = useState<boolean>(true);const [pageNumber, setPageNumber] = useState<number>(1);const [declineReason, _setDeclineReason] = useState<string>("");@@ -123,7 +125,10 @@ const ParticipantView: React.FC<ParticipantViewProps> = ({ token }) => {if (!certFile && certType !== "SERVER") {setNotification({type: "error",- message: "Please select a certificate file",+ message: t(+ "workflow.participant.selectCertificateFile",+ "Please select a certificate file",+ ),});return;}@@ -145,12 +150,21 @@ const ParticipantView: React.FC<ParticipantViewProps> = ({ token }) => {});setNotification({type: "success",- message: "Signature submitted successfully!",+ message: t(+ "workflow.participant.submitSuccess",+ "Signature submitted successfully!",+ ),});} catch (err: unknown) {setNotification({type: "error",- message: `Failed to submit signature: ${err instanceof Error ? err.message : String(err)}`,+ message: t(+ "workflow.participant.submitFailed",+ "Failed to submit signature: {{error}}",+ {+ error: err instanceof Error ? err.message : String(err),+ },+ ),});} finally {setIsSubmitting(false);@@ -159,19 +173,33 @@ const ParticipantView: React.FC<ParticipantViewProps> = ({ token }) => {const handleDecline = async () => {if (- window.confirm("Are you sure you want to decline signing this document?")+ window.confirm(+ t(+ "workflow.participant.declineConfirm",+ "Are you sure you want to decline signing this document?",+ ),+ )) {setNotification(null);try {await decline(token, declineReason || "Declined by participant");setNotification({type: "success",- message: "You have declined this signing request.",+ message: t(+ "workflow.participant.declineSuccess",+ "You have declined this signing request.",+ ),});} catch (err: unknown) {setNotification({type: "error",- message: `Failed to decline: ${err instanceof Error ? err.message : String(err)}`,+ message: t(+ "workflow.participant.declineFailed",+ "Failed to decline: {{error}}",+ {+ error: err instanceof Error ? err.message : String(err),+ },+ ),});}}diff --git a/frontend/editor/src/proprietary/routes/InviteAccept.tsx b/frontend/editor/src/proprietary/routes/InviteAccept.tsxindex 84b96e0665..59e416716c 100644--- a/frontend/editor/src/proprietary/routes/InviteAccept.tsx+++ b/frontend/editor/src/proprietary/routes/InviteAccept.tsx@@ -205,9 +205,10 @@ export default function InviteAccept() {{inviteData.email}</Text><Text size="xs" c="dimmed">- {t("invite.linkExpires", "Link expires")}:{" "}- {new Date(inviteData.expiresAt).toLocaleDateString()} at{" "}- {new Date(inviteData.expiresAt).toLocaleTimeString()}+ {t("invite.linkExpiresAt", "Link expires: {{date}} at {{time}}", {+ date: new Date(inviteData.expiresAt).toLocaleDateString(),+ time: new Date(inviteData.expiresAt).toLocaleTimeString(),+ })}</Text></Stack></Paper>diff --git a/frontend/editor/src/saas/components/shared/config/configSections/Overview.tsx b/frontend/editor/src/saas/components/shared/config/configSections/Overview.tsxindex 62f84977c1..bb0652cba0 100644--- a/frontend/editor/src/saas/components/shared/config/configSections/Overview.tsx+++ b/frontend/editor/src/saas/components/shared/config/configSections/Overview.tsx@@ -122,7 +122,13 @@ const Overview: React.FC<OverviewProps> = ({ onLogoutClick }) => {});if (error) {- setProfileError(error.message || "Failed to upload profile picture");+ setProfileError(+ error.message ||+ t(+ "config.account.profilePicture.uploadFailed",+ "Failed to upload profile picture",+ ),+ );} else {// Mark as manual upload in metadataawait updateProfilePictureMetadata(user.id, {@@ -151,7 +157,13 @@ const Overview: React.FC<OverviewProps> = ({ onLogoutClick }) => {.remove([profilePath]);if (error) {- setProfileError(error.message || "Failed to remove profile picture");+ setProfileError(+ error.message ||+ t(+ "config.account.profilePicture.removeFailed",+ "Failed to remove profile picture",+ ),+ );} else {// Clear metadata when removing pictureawait updateProfilePictureMetadata(user.id, {@@ -194,7 +206,10 @@ const Overview: React.FC<OverviewProps> = ({ onLogoutClick }) => {setProfileError(error instanceof Error? error.message- : "Failed to switch to custom picture",+ : t(+ "config.account.profilePicture.switchFailed",+ "Failed to switch to custom picture",+ ),);} finally {setProfileUploading(false);@@ -205,7 +220,7 @@ const Overview: React.FC<OverviewProps> = ({ onLogoutClick }) => {e.preventDefault();if (!email.trim()) {- setUpgradeError("Email is required");+ setUpgradeError(t("signup.emailRequired", "Email is required"));return;}@@ -224,13 +239,18 @@ const Overview: React.FC<OverviewProps> = ({ onLogoutClick }) => {await refreshSession();setSuccess(- "Account upgraded successfully! You can now sign in with your email.",+ t(+ "config.account.upgrade.success",+ "Account upgraded successfully! You can now sign in with your email.",+ ),);setEmail("");setPassword("");} catch (err: unknown) {setUpgradeError(- err instanceof Error ? err.message : "Failed to upgrade account",+ err instanceof Error+ ? err.message+ : t("config.account.upgrade.failed", "Failed to upgrade account"),);} finally {setIsLoading(false);@@ -261,7 +281,11 @@ const Overview: React.FC<OverviewProps> = ({ onLogoutClick }) => {const errorMessage =err instanceof Error? err.message- : `Failed to upgrade account with ${provider}`;+ : t(+ "config.account.upgrade.failedWithProvider",+ "Failed to upgrade account with {{provider}}",+ { provider },+ );setUpgradeError(errorMessage);setIsLoading(false);sessionStorage.removeItem("pendingUpgrade");@@ -550,7 +574,13 @@ const Overview: React.FC<OverviewProps> = ({ onLogoutClick }) => {.map((provider) => (<Tooltipkey={provider.id}- content={`${t("config.account.upgrade.linkWith", "Link with")} ${provider.label}`}+ content={t(+ "config.account.upgrade.linkWithProvider",+ "Link with {{provider}}",+ {+ provider: provider.label,+ },+ )}><DSButtonvariant="secondary"diff --git a/frontend/editor/src/saas/components/shared/config/configSections/PasswordSecurity.tsx b/frontend/editor/src/saas/components/shared/config/configSections/PasswordSecurity.tsxindex d38e46e1a7..ba458fe645 100644--- a/frontend/editor/src/saas/components/shared/config/configSections/PasswordSecurity.tsx+++ b/frontend/editor/src/saas/components/shared/config/configSections/PasswordSecurity.tsx@@ -76,7 +76,14 @@ const PasswordSecurity: React.FC = () => {setDidUpdate(false);}, 2000);} catch (e: unknown) {- setError(e instanceof Error ? e.message : "Failed to change password");+ setError(+ e instanceof Error+ ? e.message+ : t(+ "config.account.security.changeFailed",+ "Failed to change password",+ ),+ );} finally {setIsLoading(false);}diff --git a/frontend/editor/src/saas/components/shared/config/saasConfigNavSections.tsx b/frontend/editor/src/saas/components/shared/config/saasConfigNavSections.tsxindex 73512e1b81..02b89d8eb2 100644--- a/frontend/editor/src/saas/components/shared/config/saasConfigNavSections.tsx+++ b/frontend/editor/src/saas/components/shared/config/saasConfigNavSections.tsx@@ -29,26 +29,28 @@ interface CreateSaasConfigNavSectionsOptions {function ensurePreferencesSection(sections: ConfigNavSection[],+ t: TFunction<"translation", undefined>,): ConfigNavSection[] {const preferencesIndex = sections.findIndex(- (section) => section.title === "Preferences",+ (section) => section.id === "preferences",);if (preferencesIndex === -1) {return [...sections,{- title: "Preferences",+ id: "preferences",+ title: t("settings.preferences.title", "Preferences"),items: [{key: "general",- label: "General",+ label: t("settings.general.title", "General"),icon: "settings",component: <GeneralSection />,},{key: "hotkeys",- label: "Keyboard Shortcuts",+ label: t("settings.hotkeys.title", "Keyboard Shortcuts"),icon: "keyboard",component: <HotkeysSection />,},@@ -62,6 +64,7 @@ function ensurePreferencesSection(function appendDeveloperSection(sections: ConfigNavSection[],+ t: TFunction<"translation", undefined>,): ConfigNavSection[] {const hasDeveloper = sections.some((section) =>section.items.some(@@ -76,11 +79,11 @@ function appendDeveloperSection(return [...sections,{- title: "Developer",+ title: t("settings.developer.title", "Developer"),items: [{key: "api-keys",- label: "API Keys",+ label: t("settings.developer.apiKeys", "API Keys"),icon: "key",component: <ApiKeys />,},@@ -138,7 +141,13 @@ function appendMcpSection();if (developerIndex === -1) {- return [...sections, { title: "Developer", items: [mcpItem] }];+ return [+ ...sections,+ {+ title: t("settings.developer.title", "Developer"),+ items: [mcpItem],+ },+ ];}return sections.map((section, index) =>@@ -232,7 +241,7 @@ export function createSaasConfigNavSections(},{key: "security",- label: "Passwords & Security",+ label: t("config.account.security.title", "Passwords & Security"),icon: "lock",component: <PasswordSecurity />,},@@ -259,8 +268,8 @@ export function createSaasConfigNavSections(),}));- sections = ensurePreferencesSection(sections);- sections = appendDeveloperSection(sections);+ sections = ensurePreferencesSection(sections, t);+ sections = appendDeveloperSection(sections, t);sections = appendMcpSection(sections, t);if (!isAnonymous) {diff --git a/frontend/editor/src/saas/hooks/usePlans.ts b/frontend/editor/src/saas/hooks/usePlans.tsindex a5d299affe..062effeaa6 100644--- a/frontend/editor/src/saas/hooks/usePlans.ts+++ b/frontend/editor/src/saas/hooks/usePlans.ts@@ -119,7 +119,9 @@ export const usePlans = (currency: string = getPreferredCurrency()) => {} catch (err) {console.error("Error fetching pricing:", err);setError(- err instanceof Error ? err.message : "Failed to fetch pricing data",+ err instanceof Error+ ? err.message+ : t("plan.fetchError", "Failed to fetch pricing data"),);// continue with static prices if needed} finally {@@ -279,6 +281,22 @@ export const usePlans = (currency: string = getPreferredCurrency()) => {(1 - largePerCredit / xsmallPerCredit) * 100,);+ const describePackage = (+ info: { price: number; currencySymbol: string },+ credits: number,+ discount: number,+ ) => {+ const price = `${info.currencySymbol}${(info.price / credits).toFixed(3)}`;+ if (discount > 0) {+ return t(+ "plan.api.perCreditWithDiscount",+ "{{price}} per credit • {{discount}}% discount",+ { price, discount },+ );+ }+ return t("plan.api.perCredit", "{{price}} per credit", { price });+ };+const apiPackages: ApiPackage[] = [{id: "xsmall",@@ -286,7 +304,7 @@ export const usePlans = (currency: string = getPreferredCurrency()) => {price: xsmallPrice.price,currency: xsmallPrice.currencySymbol,credits: 100,- description: `${xsmallPrice.currencySymbol}${(xsmallPrice.price / 100).toFixed(3)} per credit`,+ description: describePackage(xsmallPrice, 100, 0),},{id: "small",@@ -294,7 +312,7 @@ export const usePlans = (currency: string = getPreferredCurrency()) => {price: smallPrice.price,currency: smallPrice.currencySymbol,credits: 500,- description: `${smallPrice.currencySymbol}${(smallPrice.price / 500).toFixed(3)} per credit${smallDiscount > 0 ? ` • ${smallDiscount}% discount` : ""}`,+ description: describePackage(smallPrice, 500, smallDiscount),},{id: "medium",@@ -302,7 +320,7 @@ export const usePlans = (currency: string = getPreferredCurrency()) => {price: mediumPrice.price,currency: mediumPrice.currencySymbol,credits: 1000,- description: `${mediumPrice.currencySymbol}${(mediumPrice.price / 1000).toFixed(3)} per credit${mediumDiscount > 0 ? ` • ${mediumDiscount}% discount` : ""}`,+ description: describePackage(mediumPrice, 1000, mediumDiscount),},{id: "large",@@ -310,7 +328,7 @@ export const usePlans = (currency: string = getPreferredCurrency()) => {price: largePrice.price,currency: largePrice.currencySymbol,credits: 5000,- description: `${largePrice.currencySymbol}${(largePrice.price / 5000).toFixed(3)} per credit${largeDiscount > 0 ? ` • ${largeDiscount}% discount` : ""}`,+ description: describePackage(largePrice, 5000, largeDiscount),},];diff --git a/frontend/editor/src/saas/routes/AuthCallback.tsx b/frontend/editor/src/saas/routes/AuthCallback.tsxindex 6cf197f934..6be67a6c78 100644--- a/frontend/editor/src/saas/routes/AuthCallback.tsx+++ b/frontend/editor/src/saas/routes/AuthCallback.tsx@@ -1,5 +1,6 @@import { useEffect, useState } from "react";import { useNavigate } from "react-router-dom";+import { useTranslation } from "react-i18next";import { resolveLandingPath } from "@app/utils/loginLanding";import { supabase } from "@app/auth/supabase";import { Button } from "@app/ui/Button";@@ -21,9 +22,10 @@ interface CallbackState {export default function AuthCallback() {const navigate = useNavigate();+ const { t } = useTranslation();const [state, setState] = useState<CallbackState>({status: "processing",- message: "Processing authentication...",+ message: t("auth.callback.processing", "Processing authentication..."),});useEffect(() => {@@ -58,7 +60,11 @@ export default function AuthCallback() {setState({status: "error",- message: `Authentication failed: ${errorMsg}`,+ message: t(+ "auth.callback.failedWithReason",+ "Authentication failed: {{error}}",+ { error: errorMsg },+ ),details: { error, errorDescription },});@@ -73,7 +79,10 @@ export default function AuthCallback() {setState({status: "processing",- message: "Exchanging authorization code...",+ message: t(+ "auth.callback.exchanging",+ "Exchanging authorization code...",+ ),});const { data, error: exchangeError } =@@ -87,7 +96,13 @@ export default function AuthCallback() {setState({status: "error",- message: `Failed to complete sign in: ${exchangeError.message}`,+ message: t(+ "auth.callback.signInFailed",+ "Failed to complete sign in: {{error}}",+ {+ error: exchangeError.message,+ },+ ),details: { exchangeError },});@@ -103,7 +118,10 @@ export default function AuthCallback() {setState({status: "success",- message: "Sign in successful! Redirecting...",+ message: t(+ "auth.callback.success",+ "Sign in successful! Redirecting...",+ ),details: {userId: data.session?.user?.id,email: data.session?.user?.email,@@ -122,13 +140,19 @@ export default function AuthCallback() {console.log("[Auth Callback Debug] Existing session found");setState({status: "success",- message: "Already signed in! Redirecting...",+ message: t(+ "auth.callback.alreadySignedIn",+ "Already signed in! Redirecting...",+ ),});} else {console.log("[Auth Callback Debug] No session found");setState({status: "error",- message: "No authentication data found",+ message: t(+ "auth.callback.noData",+ "No authentication data found",+ ),});setTimeout(() => navigate("/login", { replace: true }), 2000);return;@@ -156,7 +180,12 @@ export default function AuthCallback() {setState({status: "error",- message: `Unexpected error: ${err instanceof Error ? err.message : "Unknown error"}`,+ message: t("login.unexpectedError", "Unexpected error: {{message}}", {+ message:+ err instanceof Error+ ? err.message+ : t("auth.callback.unknownError", "Unknown error"),+ }),details: { error: err },});@@ -170,13 +199,13 @@ export default function AuthCallback() {const getTitle = () => {switch (state.status) {case "processing":- return "Signing you in";+ return t("auth.callback.title.processing", "Signing you in");case "success":- return "You're all set!";+ return t("auth.callback.title.success", "You're all set!");case "error":- return "Authentication failed";+ return t("oauth.error.title", "Authentication failed");default:- return "Authentication";+ return t("auth.callback.title.default", "Authentication");}};@@ -226,7 +255,7 @@ export default function AuthCallback() {fullWidthonClick={() => navigate("/login", { replace: true })}>- Back to login+ {t("auth.callback.backToLogin", "Back to login")}</Button></div>)}diff --git a/frontend/editor/src/saas/routes/Landing.tsx b/frontend/editor/src/saas/routes/Landing.tsxindex b161c0df77..66365eb061 100644--- a/frontend/editor/src/saas/routes/Landing.tsx+++ b/frontend/editor/src/saas/routes/Landing.tsx@@ -1,5 +1,6 @@import React, { useMemo } from "react";import { Navigate, useLocation } from "react-router-dom";+import { useTranslation } from "react-i18next";import { useAuth } from "@app/auth/UseSession";import { useAutoAnonymousAuth } from "@app/hooks/useAutoAnonymousAuth";import { isHomeRoute, isToolRoute } from "@app/utils/pathUtils";@@ -9,6 +10,7 @@ import GuestUserBanner from "@app/components/auth/GuestUserBanner";import { TeamInvitationBanner } from "@app/components/shared/TeamInvitationBanner";export default function Landing() {+ const { t } = useTranslation();const { session, loading } = useAuth();const { isAutoAuthenticating, autoAuthError, shouldTriggerAutoAuth } =useAutoAnonymousAuth();@@ -59,7 +61,9 @@ export default function Landing() {<div className="text-center"><div className="animate-spin rounded-full h-8 w-8 border-b-2 border-blue-600 mx-auto mb-3"></div><div className="text-gray-600">- {isAutoAuthenticating ? "Setting up your session..." : "Loading..."}+ {isAutoAuthenticating+ ? t("landing.settingUpSession", "Setting up your session...")+ : t("loading", "Loading...")}</div></div></div>diff --git a/frontend/editor/src/saas/routes/Signup.tsx b/frontend/editor/src/saas/routes/Signup.tsxindex c1d401645d..cc5da517ec 100644--- a/frontend/editor/src/saas/routes/Signup.tsx+++ b/frontend/editor/src/saas/routes/Signup.tsx@@ -53,7 +53,11 @@ export default function Signup() {useEffect(() => {const state = location.state as { autoAuthError?: string } | null;if (state?.autoAuthError) {- setError(`Unable to access tool: ${state.autoAuthError}`);+ setError(+ t("signup.unableToAccessTool", "Unable to access tool: {{error}}", {+ error: state.autoAuthError,+ }),+ );}}, [location.state]);@@ -99,7 +103,12 @@ export default function Signup() {} catch (err) {console.error("[Signup] Anonymous sign-in unexpected error:", err);setError(- `Unexpected error: ${err instanceof Error ? err.message : "Unknown error"}`,+ t("signup.unexpectedError", "Unexpected error: {{message}}", {+ message:+ err instanceof Error+ ? err.message+ : t("signup.unknownError", "Unknown error"),+ }),);} finally {setIsSigningUp(false);@@ -167,7 +176,9 @@ export default function Signup() {setError(err instanceof Error? err.message- : t("signup.unexpectedError", { message: "Unknown error" }),+ : t("signup.unexpectedError", "Unexpected error: {{message}}", {+ message: t("signup.unknownError", "Unknown error"),+ }),);} finally {setIsSigningUp(false);@@ -185,7 +196,9 @@ export default function Signup() {setError(err instanceof Error? err.message- : t("signup.unexpectedError", { message: "Unknown error" }),+ : t("signup.unexpectedError", "Unexpected error: {{message}}", {+ message: t("signup.unknownError", "Unknown error"),+ }),);} finally {setIsSigningUp(false);diff --git a/frontend/editor/src/saas/routes/login/OAuthButtons.tsx b/frontend/editor/src/saas/routes/login/OAuthButtons.tsxindex 202a1c9d3c..b7c5b85d65 100644--- a/frontend/editor/src/saas/routes/login/OAuthButtons.tsx+++ b/frontend/editor/src/saas/routes/login/OAuthButtons.tsx@@ -36,7 +36,13 @@ export default function OAuthButtons({{oauthProviders.map((p) => (<Tooltipkey={p.id}- content={`${t("login.signInWith", "Sign in with")} ${p.label}`}+ content={t(+ "login.signInWithProvider",+ "Sign in with {{provider}}",+ {+ provider: p.label,+ },+ )}position="top"><Button@@ -44,7 +50,13 @@ export default function OAuthButtons({onClick={() => onProviderClick(p.id as "github" | "google")}disabled={isSubmitting || p.isDisabled}className="oauth-button-icon"- aria-label={`${t("login.signInWith", "Sign in with")} ${p.label}`}+ aria-label={t(+ "login.signInWithProvider",+ "Sign in with {{provider}}",+ {+ provider: p.label,+ },+ )}><imgsrc={oauthIconUrl(p.file)}@@ -64,7 +76,13 @@ export default function OAuthButtons({{oauthProviders.map((p) => (<Tooltipkey={p.id}- content={`${t("login.signInWith", "Sign in with")} ${p.label}`}+ content={t(+ "login.signInWithProvider",+ "Sign in with {{provider}}",+ {+ provider: p.label,+ },+ )}position="top"><Button@@ -72,7 +90,13 @@ export default function OAuthButtons({onClick={() => onProviderClick(p.id as "github" | "google")}disabled={isSubmitting || p.isDisabled}className="oauth-button-grid"- aria-label={`${t("login.signInWith", "Sign in with")} ${p.label}`}+ aria-label={t(+ "login.signInWithProvider",+ "Sign in with {{provider}}",+ {+ provider: p.label,+ },+ )}><imgsrc={oauthIconUrl(p.file)}