diff --git a/i18next-parser.config.js b/i18next-parser.config.js index 0d79a31af5..2ada41c39f 100644 --- a/i18next-parser.config.js +++ b/i18next-parser.config.js @@ -70,6 +70,10 @@ module.exports = { customValueTemplate: null, + // Plural keys must be emitted as `key` / `key_plural` to match the runtime and + // the translated catalogs. Support for this format was dropped in i18next 24, + // so the `i18next-parser/i18next` resolution in package.json holds the parser + // on 23.x – removing it silently changes the format of the generated catalog. i18nextOptions: { compatibilityJSON: "v3", }, diff --git a/package.json b/package.json index c25f82af03..bdda25ce26 100644 --- a/package.json +++ b/package.json @@ -382,7 +382,8 @@ "ws@npm:~8.17.1": "^8.21.0", "uuid": "^11.1.1", "nodemailer@npm:9.0.0": "^9.0.1", - "linkify-it@npm:5.0.1": "5.0.2" + "linkify-it@npm:5.0.1": "5.0.2", + "i18next-parser/i18next": "^23.16.8" }, "version": "1.9.1", "packageManager": "yarn@4.11.0" diff --git a/shared/i18n/locales/en_US/translation.json b/shared/i18n/locales/en_US/translation.json index 812d7d4f8e..72675a8c7f 100644 --- a/shared/i18n/locales/en_US/translation.json +++ b/shared/i18n/locales/en_US/translation.json @@ -310,15 +310,12 @@ "Never viewed": "Never viewed", "Viewed": "Viewed", "in": "in", - "nested document_one": "nested document", - "nested document_many": "nested document", - "nested document_other": "nested document", - "{{ total }} task_one": "{{ total }} task", - "{{ total }} task_many": "{{ total }} task", - "{{ total }} task_other": "{{ total }} task", - "{{ completed }} task done_one": "{{ completed }} task done", - "{{ completed }} task done_many": "{{ completed }} task done", - "{{ completed }} task done_other": "{{ completed }} task done", + "nested document": "nested document", + "nested document_plural": "nested documents", + "{{ total }} task": "{{ total }} task", + "{{ total }} task_plural": "{{ total }} tasks", + "{{ completed }} task done": "{{ completed }} task done", + "{{ completed }} task done_plural": "{{ completed }} tasks done", "{{ completed }} of {{ total }} tasks": "{{ completed }} of {{ total }} tasks", "Currently editing": "Currently editing", "Currently viewing": "Currently viewing", @@ -360,16 +357,14 @@ "Include attachments": "Include attachments", "Including uploaded images and files in the exported data": "Including uploaded images and files in the exported data", "Include private collections": "Include private collections", - "{{count}} more user_one": "{{count}} more user", - "{{count}} more user_many": "{{count}} more user", - "{{count}} more user_other": "{{count}} more user", + "{{count}} more user": "{{count}} more user", + "{{count}} more user_plural": "{{count}} more users", "Filter options": "Filter options", "Filter": "Filter", "No results": "No results", "Close pane": "Close pane", - "{{ count }} members_one": "{{ count }} members", - "{{ count }} members_many": "{{ count }} members", - "{{ count }} members_other": "{{ count }} members", + "{{ count }} members": "{{ count }} member", + "{{ count }} members_plural": "{{ count }} members", "{{authorName}} created <3>": "{{authorName}} created <3>", "Lead": "Lead", "Target date": "Target date", @@ -450,9 +445,8 @@ "Allow this app to be installed by other workspaces": "Allow this app to be installed by other workspaces", "{{ username }} reacted with {{ emoji }}": "{{ username }} reacted with {{ emoji }}", "{{ firstUsername }} and {{ secondUsername }} reacted with {{ emoji }}": "{{ firstUsername }} and {{ secondUsername }} reacted with {{ emoji }}", - "{{ firstUsername }} and {{ count }} others reacted with {{ emoji }}_one": "{{ firstUsername }} and {{ count }} others reacted with {{ emoji }}", - "{{ firstUsername }} and {{ count }} others reacted with {{ emoji }}_many": "{{ firstUsername }} and {{ count }} others reacted with {{ emoji }}", - "{{ firstUsername }} and {{ count }} others reacted with {{ emoji }}_other": "{{ firstUsername }} and {{ count }} others reacted with {{ emoji }}", + "{{ firstUsername }} and {{ count }} others reacted with {{ emoji }}": "{{ firstUsername }} and {{ count }} other reacted with {{ emoji }}", + "{{ firstUsername }} and {{ count }} others reacted with {{ emoji }}_plural": "{{ firstUsername }} and {{ count }} others reacted with {{ emoji }}", "Add reaction": "Add reaction", "Reaction picker": "Reaction picker", "Could not load reactions": "Could not load reactions", @@ -462,9 +456,8 @@ "{{ minutes }}m read": "{{ minutes }}m read", "All members": "All members", "Everyone in the workspace": "Everyone in the workspace", - "{{ count }} member_one": "{{ count }} member", - "{{ count }} member_many": "{{ count }} member", - "{{ count }} member_other": "{{ count }} member", + "{{ count }} member": "{{ count }} member", + "{{ count }} member_plural": "{{ count }} members", "Public link copied to clipboard": "Public link copied to clipboard", "Only lowercase letters, digits and dashes allowed": "Only lowercase letters, digits and dashes allowed", "Sorry, this link has already been used": "Sorry, this link has already been used", @@ -474,12 +467,10 @@ "All documents in this collection will be shared on the web, including any new documents added later": "All documents in this collection will be shared on the web, including any new documents added later", "Invite": "Invite", "{{ userName }} was added to the collection": "{{ userName }} was added to the collection", - "{{ count }} people added to the collection_one": "{{ count }} people added to the collection", - "{{ count }} people added to the collection_many": "{{ count }} people added to the collection", - "{{ count }} people added to the collection_other": "{{ count }} people added to the collection", - "{{ count }} people and {{ count2 }} groups added to the collection_one": "{{ count }} people and {{ count2 }} groups added to the collection", - "{{ count }} people and {{ count2 }} groups added to the collection_many": "{{ count }} people and {{ count2 }} groups added to the collection", - "{{ count }} people and {{ count2 }} groups added to the collection_other": "{{ count }} people and {{ count2 }} groups added to the collection", + "{{ count }} people added to the collection": "{{ count }} person added to the collection", + "{{ count }} people added to the collection_plural": "{{ count }} people added to the collection", + "{{ count }} people and {{ count2 }} groups added to the collection": "{{ count }} person and {{ count2 }} groups added to the collection", + "{{ count }} people and {{ count2 }} groups added to the collection_plural": "{{ count }} people and {{ count2 }} groups added to the collection", "Switch to dark": "Switch to dark", "Switch to light": "Switch to light", "Subscribe to updates": "Subscribe to updates", @@ -531,12 +522,10 @@ "Anyone with the link can access because the parent document, <2>{sharedParent.sourceTitle}, is shared": "Anyone with the link can access because the parent document, <2>{sharedParent.sourceTitle}, is shared", "Nested documents are not shared on the web. Toggle sharing to enable access, this will be the default behavior in the future": "Nested documents are not shared on the web. Toggle sharing to enable access, this will be the default behavior in the future", "{{ userName }} was added to the document": "{{ userName }} was added to the document", - "{{ count }} people added to the document_one": "{{ count }} people added to the document", - "{{ count }} people added to the document_many": "{{ count }} people added to the document", - "{{ count }} people added to the document_other": "{{ count }} people added to the document", - "{{ count }} groups added to the document_one": "{{ count }} groups added to the document", - "{{ count }} groups added to the document_many": "{{ count }} groups added to the document", - "{{ count }} groups added to the document_other": "{{ count }} groups added to the document", + "{{ count }} people added to the document": "{{ count }} person added to the document", + "{{ count }} people added to the document_plural": "{{ count }} people added to the document", + "{{ count }} groups added to the document": "{{ count }} group added to the document", + "{{ count }} groups added to the document_plural": "{{ count }} groups added to the document", "Expand sidebar": "Expand sidebar", "Collapse sidebar": "Collapse sidebar", "Archived collections": "Archived collections", @@ -558,9 +547,8 @@ "Could not load starred documents": "Could not load starred documents", "Starred": "Starred", "Up to date": "Up to date", - "{{ releasesBehind }} versions behind_one": "{{ releasesBehind }} versions behind", - "{{ releasesBehind }} versions behind_many": "{{ releasesBehind }} versions behind", - "{{ releasesBehind }} versions behind_other": "{{ releasesBehind }} versions behind", + "{{ releasesBehind }} versions behind": "{{ releasesBehind }} version behind", + "{{ releasesBehind }} versions behind_plural": "{{ releasesBehind }} versions behind", "Change permissions?": "Change permissions?", "{{ documentName }} cannot be moved within {{ parentDocumentName }}": "{{ documentName }} cannot be moved within {{ parentDocumentName }}", "You can't reorder documents in an alphabetically sorted collection": "You can't reorder documents in an alphabetically sorted collection", @@ -776,18 +764,14 @@ "Done editing": "Done editing", "Drop documents to import": "Drop documents to import", "{{ collectionName }} doesn’t contain any\n documents yet.": "{{ collectionName }} doesn’t contain any\n documents yet.", - "{{ usersCount }} users and {{ groupsCount }} groups with access_one": "{{ usersCount }} users and {{ groupsCount }} groups with access", - "{{ usersCount }} users and {{ groupsCount }} groups with access_many": "{{ usersCount }} users and {{ groupsCount }} groups with access", - "{{ usersCount }} users and {{ groupsCount }} groups with access_other": "{{ usersCount }} users and {{ groupsCount }} groups with access", - "{{ usersCount }} users and a group have access_one": "{{ usersCount }} users and a group have access", - "{{ usersCount }} users and a group have access_many": "{{ usersCount }} users and a group have access", - "{{ usersCount }} users and a group have access_other": "{{ usersCount }} users and a group have access", - "{{ usersCount }} users with access_one": "{{ usersCount }} users with access", - "{{ usersCount }} users with access_many": "{{ usersCount }} users with access", - "{{ usersCount }} users with access_other": "{{ usersCount }} users with access", - "{{ groupsCount }} groups with access_one": "{{ groupsCount }} groups with access", - "{{ groupsCount }} groups with access_many": "{{ groupsCount }} groups with access", - "{{ groupsCount }} groups with access_other": "{{ groupsCount }} groups with access", + "{{ usersCount }} users and {{ groupsCount }} groups with access": "{{ usersCount }} user and {{ groupsCount }} groups with access", + "{{ usersCount }} users and {{ groupsCount }} groups with access_plural": "{{ usersCount }} users and {{ groupsCount }} groups with access", + "{{ usersCount }} users and a group have access": "{{ usersCount }} user and a group have access", + "{{ usersCount }} users and a group have access_plural": "{{ usersCount }} users and a group have access", + "{{ usersCount }} users with access": "{{ usersCount }} user with access", + "{{ usersCount }} users with access_plural": "{{ usersCount }} users with access", + "{{ groupsCount }} groups with access": "{{ groupsCount }} group with access", + "{{ groupsCount }} groups with access_plural": "{{ groupsCount }} groups with access", "Overview": "Overview", "Popular": "Popular", "Recently updated": "Recently updated", @@ -797,12 +781,10 @@ "Archived by {{userName}}": "Archived by {{userName}}", "Sorry, an error occurred saving the collection": "Sorry, an error occurred saving the collection", "Add a description": "Add a description", - "{{ current }} of {{ count }} changes_one": "{{ current }} of {{ count }} changes", - "{{ current }} of {{ count }} changes_many": "{{ current }} of {{ count }} changes", - "{{ current }} of {{ count }} changes_other": "{{ current }} of {{ count }} changes", - "{{ count }} changes_one": "{{ count }} changes", - "{{ count }} changes_many": "{{ count }} changes", - "{{ count }} changes_other": "{{ count }} changes", + "{{ current }} of {{ count }} changes": "{{ current }} of {{ count }} change", + "{{ current }} of {{ count }} changes_plural": "{{ current }} of {{ count }} changes", + "{{ count }} changes": "{{ count }} change", + "{{ count }} changes_plural": "{{ count }} changes", "Previous change": "Previous change", "Next change": "Next change", "Error creating comment": "Error creating comment", @@ -818,9 +800,8 @@ "Order in doc": "Order in doc", "Resolved": "Resolved", "Sort comments": "Sort comments", - "Show {{ count }} reply_one": "Show {{ count }} reply", - "Show {{ count }} reply_many": "Show {{ count }} reply", - "Show {{ count }} reply_other": "Show {{ count }} reply", + "Show {{ count }} reply": "Show {{ count }} reply", + "Show {{ count }} reply_plural": "Show {{ count }} replies", "Error updating comment": "Error updating comment", "Document is too large": "Document is too large", "This document has reached the maximum size and can no longer be edited": "This document has reached the maximum size and can no longer be edited", @@ -837,9 +818,8 @@ "Offline": "Offline", "Document restored": "Document restored", "Images are still uploading.\nAre you sure you want to discard them?": "Images are still uploading.\nAre you sure you want to discard them?", - "{{ count }} comment_one": "{{ count }} comment", - "{{ count }} comment_many": "{{ count }} comment", - "{{ count }} comment_other": "{{ count }} comment", + "{{ count }} comment": "{{ count }} comment", + "{{ count }} comment_plural": "{{ count }} comments", "Viewed by": "Viewed by", "only you": "only you", "person": "person", @@ -870,36 +850,30 @@ "Revision deleted": "Revision deleted", "Current version": "Current version", "{{userName}} edited": "{{userName}} edited", - "{{count}} people_one": "{{count}} people", - "{{count}} people_many": "{{count}} people", - "{{count}} people_other": "{{count}} people", + "{{count}} people": "{{count}} person", + "{{count}} people_plural": "{{count}} people", "Source": "Source", "Created": "Created", "Imported from {{ source }}": "Imported from {{ source }}", "Stats": "Stats", "{{ number }} minute read": "{{ number }} minute read", - "{{ number }} words_one": "{{ number }} words", - "{{ number }} words_many": "{{ number }} words", - "{{ number }} words_other": "{{ number }} words", - "{{ number }} characters_one": "{{ number }} characters", - "{{ number }} characters_many": "{{ number }} characters", - "{{ number }} characters_other": "{{ number }} characters", + "{{ number }} words": "{{ number }} word", + "{{ number }} words_plural": "{{ number }} words", + "{{ number }} characters": "{{ number }} character", + "{{ number }} characters_plural": "{{ number }} characters", "{{ number }} emoji": "{{ number }} emoji", "No text selected": "No text selected", - "{{ number }} words selected_one": "{{ number }} words selected", - "{{ number }} words selected_many": "{{ number }} words selected", - "{{ number }} words selected_other": "{{ number }} words selected", - "{{ number }} characters selected_one": "{{ number }} characters selected", - "{{ number }} characters selected_many": "{{ number }} characters selected", - "{{ number }} characters selected_other": "{{ number }} characters selected", + "{{ number }} words selected": "{{ number }} word selected", + "{{ number }} words selected_plural": "{{ number }} words selected", + "{{ number }} characters selected": "{{ number }} character selected", + "{{ number }} characters selected_plural": "{{ number }} characters selected", "Contributors": "Contributors", "Creator": "Creator", "Last edited": "Last edited", "Previously edited": "Previously edited", "Sorry, the last change could not be persisted – please reload the page": "Sorry, the last change could not be persisted – please reload the page", - "{{ count }} days_one": "{{ count }} days", - "{{ count }} days_many": "{{ count }} days", - "{{ count }} days_other": "{{ count }} days", + "{{ count }} days": "{{ count }} day", + "{{ count }} days_plural": "{{ count }} days", "This document will be permanently deleted in <2> unless restored.": "This document will be permanently deleted in <2> unless restored.", "Deleted by {{userName}}": "Deleted by {{userName}}", "Observing {{ userName }}": "Observing {{ userName }}", @@ -914,9 +888,8 @@ "Warning": "Warning", "This document is large which may affect performance": "This document is large which may affect performance", "Are you sure about that? Deleting the {{ documentTitle }} document will delete all of its history.": "Are you sure about that? Deleting the {{ documentTitle }} document will delete all of its history.", - "Are you sure about that? Deleting the {{ documentTitle }} document will delete all of its history and {{ any }} nested document._one": "Are you sure about that? Deleting the {{ documentTitle }} document will delete all of its history and {{ any }} nested document.", - "Are you sure about that? Deleting the {{ documentTitle }} document will delete all of its history and {{ any }} nested document._many": "Are you sure about that? Deleting the {{ documentTitle }} document will delete all of its history and {{ any }} nested document.", - "Are you sure about that? Deleting the {{ documentTitle }} document will delete all of its history and {{ any }} nested document._other": "Are you sure about that? Deleting the {{ documentTitle }} document will delete all of its history and {{ any }} nested document.", + "Are you sure about that? Deleting the {{ documentTitle }} document will delete all of its history and {{ any }} nested document.": "Are you sure about that? Deleting the {{ documentTitle }} document will delete all of its history and {{ any }} nested document.", + "Are you sure about that? Deleting the {{ documentTitle }} document will delete all of its history and {{ any }} nested document._plural": "Are you sure about that? Deleting the {{ documentTitle }} document will delete all of its history and {{ any }} nested documents.", "If you’d like the option of referencing or restoring the {{noun}} in the future, consider archiving it instead.": "If you’d like the option of referencing or restoring the {{noun}} in the future, consider archiving it instead.", "Couldn’t create the document, try again?": "Couldn’t create the document, try again?", "Document permanently deleted": "Document permanently deleted", @@ -948,9 +921,8 @@ "Documents with recent activity will appear here": "Documents with recent activity will appear here", "You haven’t created any documents yet": "You haven’t created any documents yet", "Documents you’ve recently viewed will be here for easy access": "Documents you’ve recently viewed will be here for easy access", - "{{ count }} invites sent_one": "{{ count }} invites sent", - "{{ count }} invites sent_many": "{{ count }} invites sent", - "{{ count }} invites sent_other": "{{ count }} invites sent", + "{{ count }} invites sent": "{{ count }} invite sent", + "{{ count }} invites sent_plural": "{{ count }} invites sent", "Those email addresses are already invited": "Those email addresses are already invited", "Sorry, you can only send {{MAX_INVITES}} invites at a time": "Sorry, you can only send {{MAX_INVITES}} invites at a time", "Invited {{roleName}} will receive access to": "Invited {{roleName}} will receive access to", @@ -1254,7 +1226,6 @@ "All sources": "All sources", "Manual": "Manual", "This group is hidden": "This group is hidden", - "{{ count }} member": "{{ count }} member", "Synced <2>": "Synced <2>", "Date created": "Date created", "Crop Image": "Crop Image", @@ -1266,9 +1237,8 @@ "Are you sure you want to cancel this import?": "Are you sure you want to cancel this import?", "Canceling": "Canceling", "Canceling this import will discard any progress made. This cannot be undone.": "Canceling this import will discard any progress made. This cannot be undone.", - "{{ total }} document imported_one": "{{ total }} document imported", - "{{ total }} document imported_many": "{{ total }} document imported", - "{{ total }} document imported_other": "{{ total }} document imported", + "{{ total }} document imported": "{{ total }} document imported", + "{{ total }} document imported_plural": "{{ total }} documents imported", "You can import a zip file that was previously exported from an Outline installation – collections, documents, and images will be imported. In Outline, open Export in the Settings sidebar and click on Export Data.": "You can import a zip file that was previously exported from an Outline installation – collections, documents, and images will be imported. In Outline, open Export in the Settings sidebar and click on Export Data.", "Drag and drop the zip file from the Markdown export option in {{appName}}, or click to upload": "Drag and drop the zip file from the Markdown export option in {{appName}}, or click to upload", "Configure": "Configure", @@ -1824,14 +1794,12 @@ "Open": "Open", "Loading": "Loading", "Error loading data": "Error loading data", - "Show {{ count }} completed_one": "Show {{ count }} completed", - "Show {{ count }} completed_many": "Show {{ count }} completed", - "Show {{ count }} completed_other": "Show {{ count }} completed", + "Show {{ count }} completed": "Show {{ count }} completed", + "Show {{ count }} completed_plural": "Show {{ count }} completed", "Hide completed": "Hide completed", "Sorry, the link could not be copied": "Sorry, the link could not be copied", "Write a caption": "Write a caption", "Add title": "Add title", "Add content": "Add content", - "Tomorrow": "Tomorrow", - "{{ count }} member_plural": "{{ count }} members" + "Tomorrow": "Tomorrow" } diff --git a/yarn.lock b/yarn.lock index a2ea696d17..124278a07b 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1514,7 +1514,7 @@ __metadata: languageName: node linkType: hard -"@babel/runtime@npm:^7.0.0, @babel/runtime@npm:^7.1.2, @babel/runtime@npm:^7.11.2, @babel/runtime@npm:^7.12.13, @babel/runtime@npm:^7.12.5, @babel/runtime@npm:^7.17.8, @babel/runtime@npm:^7.20.6, @babel/runtime@npm:^7.21.0, @babel/runtime@npm:^7.25.0, @babel/runtime@npm:^7.26.10, @babel/runtime@npm:^7.9.2": +"@babel/runtime@npm:^7.0.0, @babel/runtime@npm:^7.1.2, @babel/runtime@npm:^7.11.2, @babel/runtime@npm:^7.12.13, @babel/runtime@npm:^7.12.5, @babel/runtime@npm:^7.17.8, @babel/runtime@npm:^7.20.6, @babel/runtime@npm:^7.21.0, @babel/runtime@npm:^7.23.2, @babel/runtime@npm:^7.25.0, @babel/runtime@npm:^7.9.2": version: 7.29.7 resolution: "@babel/runtime@npm:7.29.7" checksum: 10c0/ca11572f7146b21e0bde6a9ed4bb6a89eafbee5f0944c7eb54d0d8a2dac962c33638a1d611e14faa71dfbb92b4b5f9236232208568a6b7d5c6f3f39ddb91771e @@ -12462,17 +12462,12 @@ __metadata: languageName: node linkType: hard -"i18next@npm:^23.5.1 || ^24.2.0": - version: 24.2.3 - resolution: "i18next@npm:24.2.3" +"i18next@npm:^23.16.8": + version: 23.16.8 + resolution: "i18next@npm:23.16.8" dependencies: - "@babel/runtime": "npm:^7.26.10" - peerDependencies: - typescript: ^5 - peerDependenciesMeta: - typescript: - optional: true - checksum: 10c0/7ac11a67d618ec714beef303aa497c1249bf5f1977dd3ebe9ca2673dfa6cadbba9e2d39ec1337688903ae3866ce9c1bc22cd6b265e66cce54c5db3a9bbedd390 + "@babel/runtime": "npm:^7.23.2" + checksum: 10c0/57d249191e8a39bbbbe190cfa2e2bb651d0198e14444fe80453d3df8d02927de3c147c77724e9ae6c72fa241898cd761e3fdcd55d053db373471f1ac084bf345 languageName: node linkType: hard