diff --git a/app/components/Editor.js b/app/components/Editor.js index 94b19425..a683c0dd 100644 --- a/app/components/Editor.js +++ b/app/components/Editor.js @@ -102,7 +102,7 @@ function Editor(props: PropsWithRef) { deleteTable: t("Delete table"), em: t("Italic"), embedInvalidLink: t("Sorry, that link won’t work for this embed type"), - findOrCreateDoc: t("Find or create a doc…"), + findOrCreateDoc: `${t("Find or create a doc")}…`, h1: t("Big heading"), h2: t("Medium heading"), h3: t("Small heading"), @@ -115,18 +115,18 @@ function Editor(props: PropsWithRef) { link: t("Link"), linkCopied: t("Link copied to clipboard"), mark: t("Highlight"), - newLineEmpty: t("Type '/' to insert…"), - newLineWithSlash: t("Keep typing to filter…"), + newLineEmpty: `${t("Type '/' to insert")}…`, + newLineWithSlash: `${t("Keep typing to filter")}…`, noResults: t("No results"), openLink: t("Open link"), orderedList: t("Ordered list"), - pasteLink: t("Paste a link…"), + pasteLink: `${t("Paste a link")}…`, pasteLinkWithTitle: (service: string) => t("Paste a {{service}} link…", { service }), placeholder: t("Placeholder"), quote: t("Quote"), removeLink: t("Remove link"), - searchOrPasteLink: t("Search or paste a link…"), + searchOrPasteLink: `${t("Search or paste a link")}…`, strikethrough: t("Strikethrough"), strong: t("Bold"), subheading: t("Subheading"), diff --git a/app/components/IconPicker.js b/app/components/IconPicker.js index d15239d5..279c9233 100644 --- a/app/components/IconPicker.js +++ b/app/components/IconPicker.js @@ -200,7 +200,7 @@ class IconPicker extends React.Component { })} - {t("Loading…")}}> + {t("Loading")}…}> diff --git a/app/components/InputSearch.js b/app/components/InputSearch.js index 85c20c76..8cb37273 100644 --- a/app/components/InputSearch.js +++ b/app/components/InputSearch.js @@ -54,7 +54,7 @@ class InputSearch extends React.Component { render() { const { t } = this.props; - const { theme, placeholder = t("Search…") } = this.props; + const { theme, placeholder = `${t("Search")}…` } = this.props; return ( { to="/collections" onClick={this.props.onCreateCollection} icon={} - label={t("New collection…")} + label={`${t("New collection")}…`} exact /> diff --git a/app/menus/CollectionMenu.js b/app/menus/CollectionMenu.js index f8c884d7..d00fb4c5 100644 --- a/app/menus/CollectionMenu.js +++ b/app/menus/CollectionMenu.js @@ -159,22 +159,22 @@ class CollectionMenu extends React.Component { type: "separator", }, { - title: t("Edit…"), + title: `${t("Edit")}…`, visible: !!(collection && can.update), onClick: this.handleEditCollectionOpen, }, { - title: t("Permissions…"), + title: `${t("Permissions")}…`, visible: !!(collection && can.update), onClick: this.handleMembersModalOpen, }, { - title: t("Export…"), + title: `${t("Export")}…`, visible: !!(collection && can.export), onClick: this.handleExportCollectionOpen, }, { - title: t("Delete…"), + title: `${t("Delete")}…`, visible: !!(collection && can.delete), onClick: this.handleDeleteCollectionOpen, }, diff --git a/app/menus/DocumentMenu.js b/app/menus/DocumentMenu.js index 1554cf1c..a28df456 100644 --- a/app/menus/DocumentMenu.js +++ b/app/menus/DocumentMenu.js @@ -200,7 +200,7 @@ class DocumentMenu extends React.Component { onClick: this.handleRestore, }, { - title: t("Restore…"), + title: `${t("Restore")}…`, visible: !collection && !!can.restore, style: { left: -170, @@ -251,7 +251,7 @@ class DocumentMenu extends React.Component { visible: !document.isStarred && !!can.star, }, { - title: t("Share link…"), + title: `${t("Share link")}…`, onClick: this.handleShareLink, visible: canShareDocuments, }, @@ -274,7 +274,7 @@ class DocumentMenu extends React.Component { visible: !!can.createChildDocument, }, { - title: t("Create template…"), + title: `${t("Create template")}…`, onClick: this.handleOpenTemplateModal, visible: !!can.update && !document.isTemplate, }, @@ -299,12 +299,12 @@ class DocumentMenu extends React.Component { visible: !!can.archive, }, { - title: t("Delete…"), + title: `${t("Delete")}…`, onClick: this.handleDelete, visible: !!can.delete, }, { - title: t("Move…"), + title: `${t("Move")}…`, onClick: this.handleMove, visible: !!can.move, }, diff --git a/app/menus/GroupMenu.js b/app/menus/GroupMenu.js index b3e8b7b8..6197bb79 100644 --- a/app/menus/GroupMenu.js +++ b/app/menus/GroupMenu.js @@ -78,7 +78,7 @@ class GroupMenu extends React.Component { { type: "separator", }, { - title: t("Edit…"), + title: `${t("Edit")}…`, onClick: this.onEdit, visible: !!(group && can.update), }, { - title: t("Delete…"), + title: `${t("Delete")}…`, onClick: this.onDelete, visible: !!(group && can.delete), }, diff --git a/app/menus/NewChildDocumentMenu.js b/app/menus/NewChildDocumentMenu.js index b691ff23..675dd173 100644 --- a/app/menus/NewChildDocumentMenu.js +++ b/app/menus/NewChildDocumentMenu.js @@ -2,7 +2,7 @@ import { observable } from "mobx"; import { observer, inject } from "mobx-react"; import * as React from "react"; -import { withTranslation, type TFunction } from "react-i18next"; +import { Trans, withTranslation, type TFunction } from "react-i18next"; import { Redirect } from "react-router-dom"; import CollectionsStore from "stores/CollectionsStore"; @@ -43,6 +43,7 @@ class NewChildDocumentMenu extends React.Component { const { label, document, collections, t } = this.props; const collection = collections.get(document.collectionId); + const collectionName = collection ? collection.name : t("collection"); return ( @@ -50,12 +51,9 @@ class NewChildDocumentMenu extends React.Component { items={[ { title: ( - - {t("New document in")}{" "} - - {collection ? collection.name : t("collection")} - - + + New document in {{ collectionName }} + ), onClick: this.handleNewDocument, }, diff --git a/app/menus/NewTemplateMenu.js b/app/menus/NewTemplateMenu.js index e1657ad5..a63e31c7 100644 --- a/app/menus/NewTemplateMenu.js +++ b/app/menus/NewTemplateMenu.js @@ -45,7 +45,7 @@ class NewTemplateMenu extends React.Component { label={ label || ( ) } diff --git a/app/menus/UserMenu.js b/app/menus/UserMenu.js index 7629eaa8..901499c1 100644 --- a/app/menus/UserMenu.js +++ b/app/menus/UserMenu.js @@ -99,7 +99,7 @@ class UserMenu extends React.Component { type: "separator", }, { - title: t("Revoke invite…"), + title: `${t("Revoke invite")}…`, onClick: this.handleRevoke, visible: user.isInvited, }, @@ -109,7 +109,7 @@ class UserMenu extends React.Component { visible: !user.isInvited && user.isSuspended, }, { - title: t("Suspend account…"), + title: `${t("Suspend account")}…`, onClick: this.handleSuspend, visible: !user.isInvited && !user.isSuspended, }, diff --git a/app/scenes/Collection.js b/app/scenes/Collection.js index 0a7fbb2d..27f086a1 100644 --- a/app/scenes/Collection.js +++ b/app/scenes/Collection.js @@ -144,7 +144,7 @@ class CollectionScene extends React.Component { @@ -207,7 +207,7 @@ class CollectionScene extends React.Component {    {collection.private && ( )} diff --git a/app/scenes/CollectionEdit.js b/app/scenes/CollectionEdit.js index a619f4d7..9feb3a17 100644 --- a/app/scenes/CollectionEdit.js +++ b/app/scenes/CollectionEdit.js @@ -120,7 +120,7 @@ class CollectionEdit extends React.Component { type="submit" disabled={this.isSaving || !this.props.collection.name} > - {this.isSaving ? t("Saving…") : t("Save")} + {this.isSaving ? `${t("Saving")}…` : t("Save")} diff --git a/app/scenes/CollectionMembers/AddGroupsToCollection.js b/app/scenes/CollectionMembers/AddGroupsToCollection.js index 7a0c3b13..39225c12 100644 --- a/app/scenes/CollectionMembers/AddGroupsToCollection.js +++ b/app/scenes/CollectionMembers/AddGroupsToCollection.js @@ -92,7 +92,7 @@ class AddGroupsToCollection extends React.Component { { - {t("Members…")} + {t("Members")}…
diff --git a/app/scenes/CollectionNew.js b/app/scenes/CollectionNew.js index 48448439..8833385b 100644 --- a/app/scenes/CollectionNew.js +++ b/app/scenes/CollectionNew.js @@ -148,7 +148,7 @@ class CollectionNew extends React.Component { ); diff --git a/app/scenes/Document/components/Header.js b/app/scenes/Document/components/Header.js index c03b35db..f9c2c7a3 100644 --- a/app/scenes/Document/components/Header.js +++ b/app/scenes/Document/components/Header.js @@ -203,7 +203,7 @@ class Header extends React.Component { {isSaving && !isPublishing && ( - {t("Saving…")} + {t("Saving")}… )}   @@ -331,7 +331,7 @@ class Header extends React.Component { disabled={publishingIsDisabled} small > - {isPublishing ? t("Publishing…") : t("Publish")} + {isPublishing ? `${t("Publishing")}…` : t("Publish")} diff --git a/app/scenes/GroupMembers/AddPeopleToGroup.js b/app/scenes/GroupMembers/AddPeopleToGroup.js index 980c5cb7..5b1dea45 100644 --- a/app/scenes/GroupMembers/AddPeopleToGroup.js +++ b/app/scenes/GroupMembers/AddPeopleToGroup.js @@ -88,7 +88,7 @@ class AddPeopleToGroup extends React.Component { { icon={} neutral > - {t("Add people…")} + {t("Add people")}… diff --git a/app/scenes/Search/Search.js b/app/scenes/Search/Search.js index a61df472..831c34fc 100644 --- a/app/scenes/Search/Search.js +++ b/app/scenes/Search/Search.js @@ -270,7 +270,7 @@ class Search extends React.Component { )} { . diff --git a/shared/i18n/locales/en_US/translation.json b/shared/i18n/locales/en_US/translation.json index 0ba13b35..1cc7284b 100644 --- a/shared/i18n/locales/en_US/translation.json +++ b/shared/i18n/locales/en_US/translation.json @@ -43,7 +43,7 @@ "Delete table": "Delete table", "Italic": "Italic", "Sorry, that link won’t work for this embed type": "Sorry, that link won’t work for this embed type", - "Find or create a doc…": "Find or create a doc…", + "Find or create a doc": "Find or create a doc", "Big heading": "Big heading", "Medium heading": "Medium heading", "Small heading": "Small heading", @@ -56,17 +56,17 @@ "Link": "Link", "Link copied to clipboard": "Link copied to clipboard", "Highlight": "Highlight", - "Type '/' to insert…": "Type '/' to insert…", - "Keep typing to filter…": "Keep typing to filter…", + "Type '/' to insert": "Type '/' to insert", + "Keep typing to filter": "Keep typing to filter", "No results": "No results", "Open link": "Open link", "Ordered list": "Ordered list", - "Paste a link…": "Paste a link…", + "Paste a link": "Paste a link", "Paste a {{service}} link…": "Paste a {{service}} link…", "Placeholder": "Placeholder", "Quote": "Quote", "Remove link": "Remove link", - "Search or paste a link…": "Search or paste a link…", + "Search or paste a link": "Search or paste a link", "Strikethrough": "Strikethrough", "Bold": "Bold", "Subheading": "Subheading", @@ -76,17 +76,16 @@ "Warning": "Warning", "Warning notice": "Warning notice", "Icon": "Icon", - "Loading…": "Loading…", - "Search…": "Search…", + "Loading": "Loading", + "Search": "Search", "Outline is available in your language {{optionLabel}}, would you like to change?": "Outline is available in your language {{optionLabel}}, would you like to change?", "Change Language": "Change Language", "Dismiss": "Dismiss", "Keyboard shortcuts": "Keyboard shortcuts", - "New collection…": "New collection…", + "New collection": "New collection", "Collections": "Collections", "Untitled": "Untitled", "Home": "Home", - "Search": "Search", "Starred": "Starred", "Invite people…": "Invite people…", "Invite people": "Invite people", @@ -116,10 +115,10 @@ "Collection permissions": "Collection permissions", "New document": "New document", "Import document": "Import document", - "Edit…": "Edit…", - "Permissions…": "Permissions…", - "Export…": "Export…", - "Delete…": "Delete…", + "Edit": "Edit", + "Permissions": "Permissions", + "Export": "Export", + "Delete": "Delete", "Edit collection": "Edit collection", "Delete collection": "Delete collection", "Export collection": "Export collection", @@ -128,33 +127,30 @@ "Document restored": "Document restored", "Document unpublished": "Document unpublished", "Restore": "Restore", - "Restore…": "Restore…", "Choose a collection": "Choose a collection", "Unpin": "Unpin", "Pin to collection": "Pin to collection", "Unstar": "Unstar", "Star": "Star", - "Share link…": "Share link…", + "Share link": "Share link", "Enable embeds": "Enable embeds", "Disable embeds": "Disable embeds", "New nested document": "New nested document", - "Create template…": "Create template…", - "Edit": "Edit", + "Create template": "Create template", "Duplicate": "Duplicate", "Unpublish": "Unpublish", - "Move…": "Move…", + "Move": "Move", "History": "History", "Download": "Download", "Print": "Print", "Delete {{ documentName }}": "Delete {{ documentName }}", - "Create template": "Create template", "Share document": "Share document", "Edit group": "Edit group", "Delete group": "Delete group", - "Members…": "Members…", - "New document in": "New document in", + "Members": "Members", "collection": "collection", - "New template…": "New template…", + "New document in <1>{{collectionName}}": "New document in <1>{{collectionName}}", + "New template": "New template", "Link copied": "Link copied", "Restore version": "Restore version", "Copy link": "Copy link", @@ -168,16 +164,16 @@ "Are you sure you want to suspend this account? Suspended users will be prevented from logging in.": "Are you sure you want to suspend this account? Suspended users will be prevented from logging in.", "Make {{ userName }} a member…": "Make {{ userName }} a member…", "Make {{ userName }} an admin…": "Make {{ userName }} an admin…", - "Revoke invite…": "Revoke invite…", + "Revoke invite": "Revoke invite", "Activate account": "Activate account", - "Suspend account…": "Suspend account…", + "Suspend account": "Suspend account", "Documents": "Documents", "The document archive is empty at the moment.": "The document archive is empty at the moment.", - "Search in collection…": "Search in collection…", + "Search in collection": "Search in collection", "<0>{{collectionName}} doesn’t contain any documents yet.": "<0>{{collectionName}} doesn’t contain any documents yet.", "Get started by creating a new one!": "Get started by creating a new one!", "Create a document": "Create a document", - "Manage members…": "Manage members…", + "Manage members": "Manage members", "Pinned": "Pinned", "Recently updated": "Recently updated", "Recently published": "Recently published", @@ -190,13 +186,13 @@ "More details about this collection…": "More details about this collection…", "Private collection": "Private collection", "A private collection will only be visible to invited team members.": "A private collection will only be visible to invited team members.", - "Saving…": "Saving…", + "Saving": "Saving", "Save": "Save", "{{ groupName }} was added to the collection": "{{ groupName }} was added to the collection", "Could not add user": "Could not add user", "Can’t find the group you’re looking for?": "Can’t find the group you’re looking for?", "Create a group": "Create a group", - "Search by group name…": "Search by group name…", + "Search by group name": "Search by group name", "Search groups": "Search groups", "No groups matching your search": "No groups matching your search", "No groups left to add": "No groups left to add", @@ -204,20 +200,19 @@ "{{ userName }} was added to the collection": "{{ userName }} was added to the collection", "Need to add someone who’s not yet on the team yet?": "Need to add someone who’s not yet on the team yet?", "Invite people to {{ teamName }}": "Invite people to {{ teamName }}", - "Search by name…": "Search by name…", + "Search by name": "Search by name", "Search people": "Search people", "No people matching your search": "No people matching your search", "No people left to add": "No people left to add", "Read only": "Read only", "Read & Edit": "Read & Edit", - "Permissions": "Permissions", "Remove": "Remove", "Active <1> ago": "Active <1> ago", "Never signed in": "Never signed in", "Invited": "Invited", "Admin": "Admin", "Collections are for grouping your knowledge base. They work best when organized around a topic or internal team — Product or Engineering for example.": "Collections are for grouping your knowledge base. They work best when organized around a topic or internal team — Product or Engineering for example.", - "Creating…": "Creating…", + "Creating": "Creating", "Create": "Create", "Recently viewed": "Recently viewed", "Created by me": "Created by me", @@ -232,7 +227,7 @@ "New from template": "New from template", "Publish": "Publish", "Publish document": "Publish document", - "Publishing…": "Publishing…", + "Publishing": "Publishing", "No documents found for your filters.": "No documents found for your filters.", "You’ve not got any drafts at the moment.": "You’ve not got any drafts at the moment.", "Not found": "Not found", @@ -246,7 +241,7 @@ "Invite them to {{teamName}}": "Invite them to {{teamName}}", "{{userName}} was removed from the group": "{{userName}} was removed from the group", "Could not remove user": "Could not remove user", - "Add people…": "Add people…", + "Add people": "Add people", "This group has no members.": "This group has no members.", "Outline is designed to be fast and easy to use. All of your usual keyboard shortcuts work here, and there’s Markdown too.": "Outline is designed to be fast and easy to use. All of your usual keyboard shortcuts work here, and there’s Markdown too.", "Navigation": "Navigation",