From 3c3438f000fd8769765f5c7021b3929c4aced84a Mon Sep 17 00:00:00 2001 From: ElementRobot Date: Tue, 5 Sep 2023 16:56:48 +0100 Subject: [PATCH 01/52] Upgrade matrix-js-sdk to 28.1.0-rc.1 --- package.json | 2 +- yarn.lock | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index 99bc0c0db9..adeffa3dd0 100644 --- a/package.json +++ b/package.json @@ -98,7 +98,7 @@ "maplibre-gl": "^2.0.0", "matrix-encrypt-attachment": "^1.0.3", "matrix-events-sdk": "0.0.1", - "matrix-js-sdk": "github:matrix-org/matrix-js-sdk#develop", + "matrix-js-sdk": "28.1.0-rc.1", "matrix-widget-api": "^1.5.0", "memoize-one": "^6.0.0", "minimist": "^1.2.5", diff --git a/yarn.lock b/yarn.lock index 8b39fb9820..c99a2ba1e5 100644 --- a/yarn.lock +++ b/yarn.lock @@ -7473,9 +7473,10 @@ matrix-events-sdk@0.0.1: resolved "https://registry.yarnpkg.com/matrix-events-sdk/-/matrix-events-sdk-0.0.1.tgz#c8c38911e2cb29023b0bbac8d6f32e0de2c957dd" integrity sha512-1QEOsXO+bhyCroIe2/A5OwaxHvBm7EsSQ46DEDn8RBIfQwN5HWBpFvyWWR4QY0KHPPnnJdI99wgRiAl7Ad5qaA== -"matrix-js-sdk@github:matrix-org/matrix-js-sdk#develop": - version "28.0.0" - resolved "https://codeload.github.com/matrix-org/matrix-js-sdk/tar.gz/4c00b410466b855e178ed47217dac6b31536a7bf" +matrix-js-sdk@28.1.0-rc.1: + version "28.1.0-rc.1" + resolved "https://registry.yarnpkg.com/matrix-js-sdk/-/matrix-js-sdk-28.1.0-rc.1.tgz#b4aabc01087b7301f23ba3f80fcefcd8434d3591" + integrity sha512-lNzZ10sQW6SxZdLUFQMKYk9/vY1DbbSaOLG68NCOxRgund9Ef+KQWmp3AYyiDvKr5PTQWSIaJRgwZW3+AsV3Rg== dependencies: "@babel/runtime" "^7.12.5" "@matrix-org/matrix-sdk-crypto-wasm" "^1.2.1" From de8ef980cb00486d70ab9bde25674c2e0663d4ac Mon Sep 17 00:00:00 2001 From: ElementRobot Date: Tue, 5 Sep 2023 16:58:58 +0100 Subject: [PATCH 02/52] Prepare changelog for v3.80.0-rc.1 --- CHANGELOG.md | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index b588020eb7..241ee65d62 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,30 @@ +Changes in [3.80.0-rc.1](https://github.com/matrix-org/matrix-react-sdk/releases/tag/v3.80.0-rc.1) (2023-09-05) +=============================================================================================================== + +## ✨ Features + * Allow creating public knock rooms ([\#11481](https://github.com/matrix-org/matrix-react-sdk/pull/11481)). Contributed by @charlynguyen. + * Render custom images in reactions according to MSC4027 ([\#11087](https://github.com/matrix-org/matrix-react-sdk/pull/11087)). Contributed by @sumnerevans. + * Introduce room knocks bar ([\#11475](https://github.com/matrix-org/matrix-react-sdk/pull/11475)). Contributed by @charlynguyen. + * Room header UI updates ([\#11507](https://github.com/matrix-org/matrix-react-sdk/pull/11507)). Fixes vector-im/element-web#25892. + * Remove green "verified" bar for encrypted events ([\#11496](https://github.com/matrix-org/matrix-react-sdk/pull/11496)). + * Update member count on room summary update ([\#11488](https://github.com/matrix-org/matrix-react-sdk/pull/11488)). + * Support for E2EE in Element Call ([\#11492](https://github.com/matrix-org/matrix-react-sdk/pull/11492)). + * Allow requesting to join knock rooms via spotlight ([\#11482](https://github.com/matrix-org/matrix-react-sdk/pull/11482)). Contributed by @charlynguyen. + * Lock out the first tab if Element is opened in a second tab. ([\#11425](https://github.com/matrix-org/matrix-react-sdk/pull/11425)). Fixes vector-im/element-web#25157. + * Change avatar to use Compound implementation ([\#11448](https://github.com/matrix-org/matrix-react-sdk/pull/11448)). + +## 🐛 Bug Fixes + * Use RoomStateEvent.Update for knocks ([\#11516](https://github.com/matrix-org/matrix-react-sdk/pull/11516)). Contributed by @charlynguyen. + * Prevent event propagation when clicking icon buttons ([\#11515](https://github.com/matrix-org/matrix-react-sdk/pull/11515)). + * Only display RoomKnocksBar when feature flag is enabled ([\#11513](https://github.com/matrix-org/matrix-react-sdk/pull/11513)). Contributed by @andybalaam. + * Fix avatars of knock members for people tab of room settings ([\#11506](https://github.com/matrix-org/matrix-react-sdk/pull/11506)). Fixes vector-im/element-web#26083. Contributed by @charlynguyen. + * Fixes read receipt avatar offset ([\#11483](https://github.com/matrix-org/matrix-react-sdk/pull/11483)). Fixes vector-im/element-web#26067, vector-im/element-web#26064 vector-im/element-web#26059 and vector-im/element-web#26061. + * Fix avatar defects ([\#11473](https://github.com/matrix-org/matrix-react-sdk/pull/11473)). Fixes vector-im/element-web#26051 and vector-im/element-web#26046. + * Fix consistent avatar output for Percy ([\#11472](https://github.com/matrix-org/matrix-react-sdk/pull/11472)). Fixes vector-im/element-web#26049 and vector-im/element-web#26052. + * Fix colour of avatar and colour matching with username ([\#11470](https://github.com/matrix-org/matrix-react-sdk/pull/11470)). Fixes vector-im/element-web#26042. + * Fix incompatibility of Soft Logout with Element-R ([\#11468](https://github.com/matrix-org/matrix-react-sdk/pull/11468)). + * Fix instances of double translation and guard translation calls using typescript ([\#11443](https://github.com/matrix-org/matrix-react-sdk/pull/11443)). + Changes in [3.79.0](https://github.com/matrix-org/matrix-react-sdk/releases/tag/v3.79.0) (2023-08-29) ===================================================================================================== From 87272fc3c6a5c7a69cea0bb8f05ed28d025a037a Mon Sep 17 00:00:00 2001 From: ElementRobot Date: Tue, 5 Sep 2023 16:59:00 +0100 Subject: [PATCH 03/52] v3.80.0-rc.1 --- package.json | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index adeffa3dd0..924867e8d5 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "matrix-react-sdk", - "version": "3.79.0", + "version": "3.80.0-rc.1", "description": "SDK for matrix.org using React", "author": "matrix.org", "repository": { @@ -23,7 +23,7 @@ "package.json", ".stylelintrc.js" ], - "main": "./src/index.ts", + "main": "./lib/index.ts", "matrix_src_main": "./src/index.ts", "matrix_lib_main": "./lib/index.ts", "matrix_lib_typings": "./lib/index.d.ts", @@ -230,5 +230,6 @@ "outputDirectory": "coverage", "outputName": "jest-sonar-report.xml", "relativePaths": true - } + }, + "typings": "./lib/index.d.ts" } From 708537d615a599016fabb09a38731715993b352e Mon Sep 17 00:00:00 2001 From: ElementRobot Date: Thu, 7 Sep 2023 09:36:42 +0200 Subject: [PATCH 04/52] [Backport staging] Fix EventTile avatars being rendered with a size of 0 instead of hidden (#11577) Co-authored-by: Michael Telatynski <7t3chguy@gmail.com> --- src/components/views/rooms/EventTile.tsx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/components/views/rooms/EventTile.tsx b/src/components/views/rooms/EventTile.tsx index 986eafcca9..77fb270768 100644 --- a/src/components/views/rooms/EventTile.tsx +++ b/src/components/views/rooms/EventTile.tsx @@ -1003,7 +1003,7 @@ export class UnwrappedEventTile extends React.Component let avatar: JSX.Element | null = null; let sender: JSX.Element | null = null; - let avatarSize: string; + let avatarSize: string | null; let needsSenderProfile: boolean; if (isRenderingNotification) { @@ -1021,7 +1021,7 @@ export class UnwrappedEventTile extends React.Component avatarSize = "32px"; needsSenderProfile = true; } else if (eventType === EventType.RoomCreate || isBubbleMessage) { - avatarSize = "0"; + avatarSize = null; needsSenderProfile = false; } else if (this.props.layout == Layout.IRC) { avatarSize = "14px"; @@ -1032,14 +1032,14 @@ export class UnwrappedEventTile extends React.Component ElementCall.CALL_EVENT_TYPE.matches(eventType) ) { // no avatar or sender profile for continuation messages and call tiles - avatarSize = "0"; + avatarSize = null; needsSenderProfile = false; } else { avatarSize = "30px"; needsSenderProfile = true; } - if (this.props.mxEvent.sender && avatarSize) { + if (this.props.mxEvent.sender && avatarSize !== null) { let member: RoomMember | null = null; // set member to receiver (target) if it is a 3PID invite // so that the correct avatar is shown as the text is From d19a0e004411a59bfaa46a52b67d9da38b773f05 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 7 Sep 2023 08:43:27 +0100 Subject: [PATCH 05/52] Update definitelyTyped (#11563) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Michael Telatynski <7t3chguy@gmail.com> --- yarn.lock | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/yarn.lock b/yarn.lock index bcc748cf32..f41cdc0ad6 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2841,9 +2841,9 @@ integrity sha512-PcGNd//40kHAS3sTlzKB9C9XL4K0sTup8nbG5lC14kzEteTNuAFh9u5nA0o5TWnSG2r/JNPRXFVcHJIIeRlmqQ== "@types/node@^16", "@types/node@^16.18.39": - version "16.18.43" - resolved "https://registry.yarnpkg.com/@types/node/-/node-16.18.43.tgz#580905f150e1008474bc9bd5a098b82eddc1b6c8" - integrity sha512-YFpgPKPRcwYbeNOimfu70B+TVJe6tr88WiW/TzEldkwGxQXrmabpU+lDjrFlNqdqIi3ON0o69EQBW62VH4MIxw== + version "16.18.48" + resolved "https://registry.yarnpkg.com/@types/node/-/node-16.18.48.tgz#3bc872236cdb31cb51024d8875d655e25db489a4" + integrity sha512-mlaecDKQ7rIZrYD7iiKNdzFb6e/qD5I9U1rAhq+Fd+DWvYVs+G2kv74UFHmSOlg5+i/vF3XxuR522V4u8BqO+Q== "@types/normalize-package-data@^2.4.0": version "2.4.1" @@ -2871,14 +2871,14 @@ integrity sha512-JCB8C6SnDoQf0cNycqd/35A7MjcnK+ZTqE7judS6o7utxUCg6imJg3QK2qzHKszlTjcj2cn+NwMB2i96ubpj7w== "@types/q@^1.5.1": - version "1.5.5" - resolved "https://registry.yarnpkg.com/@types/q/-/q-1.5.5.tgz#75a2a8e7d8ab4b230414505d92335d1dcb53a6df" - integrity sha512-L28j2FcJfSZOnL1WBjDYp2vUHCeIFlyYI/53EwD/rKUBQ7MtUUfbQWiyKJGpcnv4/WgrhWsFKrcPstcAt/J0tQ== + version "1.5.6" + resolved "https://registry.yarnpkg.com/@types/q/-/q-1.5.6.tgz#a6edffe8283910e46dc7a573621f928e6b47fa56" + integrity sha512-IKjZ8RjTSwD4/YG+2gtj7BPFRB/lNbWKTiSj3M7U/TD2B7HfYCxvp2Zz6xA2WIY7pAuL1QOUPw8gQRbUrrq4fQ== "@types/qrcode@^1.3.5": - version "1.5.1" - resolved "https://registry.yarnpkg.com/@types/qrcode/-/qrcode-1.5.1.tgz#027c2dbfbc8505e1fe2f4033daba920dbd182b44" - integrity sha512-HpSN675K0PmxIDRpjMI3Mc2GiKo3dNu+X/F5SoItiaDS1lVfgC6Wac1c5lQDfKWbTJUSHWiHKzpJpBZG7k9gaA== + version "1.5.2" + resolved "https://registry.yarnpkg.com/@types/qrcode/-/qrcode-1.5.2.tgz#27633439b7fbe88cc3043b29c8e7612a8a789e15" + integrity sha512-W4KDz75m7rJjFbyCctzCtRzZUj+PrUHV+YjqDp50sSRezTbrtEAIq2iTzC6lISARl3qw+8IlcCyljdcVJE0Wug== dependencies: "@types/node" "*" @@ -2975,14 +2975,14 @@ integrity sha512-Q5vtl1W5ue16D+nIaW8JWebSSraJVlK+EthKn7e7UcD4KWsaSJ8BqGPXNaPghgtcn/fhvrN17Tv8ksUsQpiplw== "@types/ua-parser-js@^0.7.36": - version "0.7.36" - resolved "https://registry.yarnpkg.com/@types/ua-parser-js/-/ua-parser-js-0.7.36.tgz#9bd0b47f26b5a3151be21ba4ce9f5fa457c5f190" - integrity sha512-N1rW+njavs70y2cApeIw1vLMYXRwfBy+7trgavGuuTfOd7j1Yh7QTRc/yqsPl6ncokt72ZXuxEU0PiCp9bSwNQ== + version "0.7.37" + resolved "https://registry.yarnpkg.com/@types/ua-parser-js/-/ua-parser-js-0.7.37.tgz#2e45bf948a6a94391859a1b0682104ae3c13ba72" + integrity sha512-4sOxS3ZWXC0uHJLYcWAaLMxTvjRX3hT96eF4YWUh1ovTaenvibaZOE5uXtIp4mksKMLRwo7YDiCBCw6vBiUPVg== "@types/uuid@^9.0.2": - version "9.0.2" - resolved "https://registry.yarnpkg.com/@types/uuid/-/uuid-9.0.2.tgz#ede1d1b1e451548d44919dc226253e32a6952c4b" - integrity sha512-kNnC1GFBLuhImSnV7w4njQkUiJi0ZXUycu1rUaouPqiKlXkh77JKgdRnTAp1x5eBwcIwbtI+3otwzuIDEuDoxQ== + version "9.0.3" + resolved "https://registry.yarnpkg.com/@types/uuid/-/uuid-9.0.3.tgz#6cdd939b4316b4f81625de9f06028d848c4a1533" + integrity sha512-taHQQH/3ZyI3zP8M/puluDEIEvtQHVYcC6y3N8ijFtAd28+Ey/G4sg1u2gB01S8MwybLOKAp9/yCMu/uR5l3Ug== "@types/yargs-parser@*": version "21.0.0" @@ -3004,9 +3004,9 @@ "@types/node" "*" "@types/zxcvbn@^4.4.0": - version "4.4.1" - resolved "https://registry.yarnpkg.com/@types/zxcvbn/-/zxcvbn-4.4.1.tgz#46e42cbdcee681b22181478feaf4af2bc4c1abd2" - integrity sha512-3NoqvZC2W5gAC5DZbTpCeJ251vGQmgcWIHQJGq2J240HY6ErQ9aWKkwfoKJlHLx+A83WPNTZ9+3cd2ILxbvr1w== + version "4.4.2" + resolved "https://registry.yarnpkg.com/@types/zxcvbn/-/zxcvbn-4.4.2.tgz#7b16c35330a15471cd7b9d3576503a40b6bd2416" + integrity sha512-T7SEL8b/eN7AEhHQ8oFt7c6Y+l3p8OpH7KwJIe+5oBOPLMMioPeMsUTB3huNgEnXhiittV8Ohdw21Jg8E/f70Q== "@typescript-eslint/eslint-plugin@^5.35.1": version "5.62.0" From 3201ae3534075c52a14deb43810d853507cc9954 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 7 Sep 2023 07:43:49 +0000 Subject: [PATCH 06/52] Update cypress-io/github-action digest to 2558ee6 (#11559) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- .github/workflows/cypress.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/cypress.yaml b/.github/workflows/cypress.yaml index d2df5a26ca..89ab7724d5 100644 --- a/.github/workflows/cypress.yaml +++ b/.github/workflows/cypress.yaml @@ -163,7 +163,7 @@ jobs: echo "CYPRESS_RUST_CRYPTO=1" >> "$GITHUB_ENV" - name: Run Cypress tests - uses: cypress-io/github-action@fa88e4afe551e64c8827a4b9e379afc63d8f691a + uses: cypress-io/github-action@2558ee6af05072a19de2ce92cb68b38616132726 with: working-directory: matrix-react-sdk # The built-in Electron runner seems to grind to a halt trying to run the tests, so use chrome. From 36a7a96e0e91437344ae30e51ca3c08966aabe1e Mon Sep 17 00:00:00 2001 From: Michael Telatynski <7t3chguy@gmail.com> Date: Thu, 7 Sep 2023 10:37:09 +0100 Subject: [PATCH 07/52] Migrate more strings to translation keys (#11574) --- .../dialogs/AnalyticsLearnMoreDialog.tsx | 27 +- .../dialogs/SessionRestoreErrorDialog.tsx | 2 +- src/components/views/dialogs/TermsDialog.tsx | 4 +- .../views/elements/ErrorBoundary.tsx | 2 +- .../views/elements/EventListSummary.tsx | 70 ++-- .../views/emojipicker/EmojiPicker.tsx | 18 +- src/components/views/emojipicker/Header.tsx | 2 +- .../views/emojipicker/QuickReactions.tsx | 4 +- .../views/right_panel/EncryptionInfo.tsx | 2 +- .../views/right_panel/VerificationPanel.tsx | 19 +- .../views/settings/IntegrationManager.tsx | 2 +- .../views/settings/LayoutSwitcher.tsx | 4 +- src/components/views/settings/SetIdServer.tsx | 2 +- .../verification/VerificationCancelled.tsx | 2 +- .../verification/VerificationComplete.tsx | 4 +- .../verification/VerificationShowSas.tsx | 10 +- src/i18n/strings/ar.json | 54 +-- src/i18n/strings/az.json | 4 +- src/i18n/strings/bg.json | 236 ++++++------ src/i18n/strings/bn_BD.json | 6 +- src/i18n/strings/bn_IN.json | 6 +- src/i18n/strings/bs.json | 4 +- src/i18n/strings/ca.json | 178 ++++----- src/i18n/strings/cs.json | 362 +++++++++--------- src/i18n/strings/cy.json | 4 +- src/i18n/strings/da.json | 10 +- src/i18n/strings/de_DE.json | 362 +++++++++--------- src/i18n/strings/el.json | 344 +++++++++-------- src/i18n/strings/en_EN.json | 359 ++++++++--------- src/i18n/strings/eo.json | 260 +++++++------ src/i18n/strings/es.json | 346 +++++++++-------- src/i18n/strings/et.json | 362 +++++++++--------- src/i18n/strings/eu.json | 236 ++++++------ src/i18n/strings/fa.json | 244 ++++++------ src/i18n/strings/fi.json | 326 ++++++++-------- src/i18n/strings/fr.json | 362 +++++++++--------- src/i18n/strings/ga.json | 44 ++- src/i18n/strings/gl.json | 346 +++++++++-------- src/i18n/strings/he.json | 280 +++++++------- src/i18n/strings/hi.json | 10 +- src/i18n/strings/hr.json | 6 +- src/i18n/strings/hu.json | 346 +++++++++-------- src/i18n/strings/id.json | 362 +++++++++--------- src/i18n/strings/is.json | 306 ++++++++------- src/i18n/strings/it.json | 362 +++++++++--------- src/i18n/strings/ja.json | 346 +++++++++-------- src/i18n/strings/jbo.json | 16 +- src/i18n/strings/kab.json | 236 ++++++------ src/i18n/strings/ko.json | 222 +++++------ src/i18n/strings/lo.json | 344 +++++++++-------- src/i18n/strings/lt.json | 256 +++++++------ src/i18n/strings/lv.json | 240 ++++++------ src/i18n/strings/ml.json | 6 +- src/i18n/strings/nb_NO.json | 184 ++++----- src/i18n/strings/nl.json | 346 +++++++++-------- src/i18n/strings/nn.json | 174 +++++---- src/i18n/strings/oc.json | 22 +- src/i18n/strings/pl.json | 358 ++++++++--------- src/i18n/strings/pt_BR.json | 268 ++++++------- src/i18n/strings/ru.json | 346 +++++++++-------- src/i18n/strings/sk.json | 362 +++++++++--------- src/i18n/strings/sq.json | 346 +++++++++-------- src/i18n/strings/sr.json | 182 ++++----- src/i18n/strings/sv.json | 346 +++++++++-------- src/i18n/strings/tr.json | 226 +++++------ src/i18n/strings/tzm.json | 6 +- src/i18n/strings/uk.json | 362 +++++++++--------- src/i18n/strings/vi.json | 336 ++++++++-------- src/i18n/strings/vls.json | 196 +++++----- src/i18n/strings/zh_Hans.json | 344 +++++++++-------- src/i18n/strings/zh_Hant.json | 362 +++++++++--------- src/toasts/AnalyticsToast.tsx | 12 +- 72 files changed, 6593 insertions(+), 6152 deletions(-) diff --git a/src/components/views/dialogs/AnalyticsLearnMoreDialog.tsx b/src/components/views/dialogs/AnalyticsLearnMoreDialog.tsx index 9e2372545c..3b09adbb52 100644 --- a/src/components/views/dialogs/AnalyticsLearnMoreDialog.tsx +++ b/src/components/views/dialogs/AnalyticsLearnMoreDialog.tsx @@ -51,7 +51,7 @@ export const AnalyticsLearnMoreDialog: React.FC = ({ const privacyPolicyLink = privacyPolicyUrl ? ( {_t( - "You can read all our terms here", + "analytics|privacy_policy", {}, { PrivacyPolicyUrl: (sub) => { @@ -71,33 +71,18 @@ export const AnalyticsLearnMoreDialog: React.FC = ({
- {_t( - "Help us identify issues and improve %(analyticsOwner)s by sharing anonymous usage data. To understand how people use multiple devices, we'll generate a random identifier, shared by your devices.", - { analyticsOwner }, - )} + {_t("analytics|pseudonymous_usage_data", { analyticsOwner })}
    -
  • - {_t( - "We don't record or profile any account data", - {}, - { Bold: (sub) => {sub} }, - )} -
  • -
  • - {_t( - "We don't share information with third parties", - {}, - { Bold: (sub) => {sub} }, - )} -
  • -
  • {_t("You can turn this off anytime in settings")}
  • +
  • {_t("analytics|bullet_1", {}, { Bold: (sub) => {sub} })}
  • +
  • {_t("analytics|bullet_2", {}, { Bold: (sub) => {sub} })}
  • +
  • {_t("analytics|disable_prompt")}
{privacyPolicyLink}
diff --git a/src/components/views/dialogs/SessionRestoreErrorDialog.tsx b/src/components/views/dialogs/SessionRestoreErrorDialog.tsx index 27e8965f6f..7893e271db 100644 --- a/src/components/views/dialogs/SessionRestoreErrorDialog.tsx +++ b/src/components/views/dialogs/SessionRestoreErrorDialog.tsx @@ -67,7 +67,7 @@ export default class SessionRestoreErrorDialog extends React.Component { if (SdkConfig.get().bug_report_endpoint_url) { dialogButtons = ( - {_t("Identity server")} + {_t("common|identity_server")}
({host})
); case SERVICE_TYPES.IM: return (
- {_t("Integration manager")} + {_t("common|integration_manager")}
({host})
); diff --git a/src/components/views/elements/ErrorBoundary.tsx b/src/components/views/elements/ErrorBoundary.tsx index 4a24d22f98..81584a5145 100644 --- a/src/components/views/elements/ErrorBoundary.tsx +++ b/src/components/views/elements/ErrorBoundary.tsx @@ -85,7 +85,7 @@ export default class ErrorBoundary extends React.PureComponent {

{_t( - "Please create a new issue on GitHub so that we can investigate this bug.", + "bug_reporting|create_new_issue", {}, { newIssueLink: (sub) => { diff --git a/src/components/views/elements/EventListSummary.tsx b/src/components/views/elements/EventListSummary.tsx index e0279a7c9c..9ed1345a0b 100644 --- a/src/components/views/elements/EventListSummary.tsx +++ b/src/components/views/elements/EventListSummary.tsx @@ -133,7 +133,7 @@ export default class EventListSummary extends React.Component< const desc = formatCommaSeparatedList(descs); - return _t("%(nameList)s %(transitionList)s", { nameList, transitionList: desc }); + return _t("timeline|summary|format", { nameList, transitionList: desc }); }); if (!summaries) { @@ -250,101 +250,101 @@ export default class EventListSummary extends React.Component< case TransitionType.Joined: res = userCount > 1 - ? _t("%(severalUsers)sjoined %(count)s times", { severalUsers: "", count }) - : _t("%(oneUser)sjoined %(count)s times", { oneUser: "", count }); + ? _t("timeline|summary|joined_multiple", { severalUsers: "", count }) + : _t("timeline|summary|joined", { oneUser: "", count }); break; case TransitionType.Left: res = userCount > 1 - ? _t("%(severalUsers)sleft %(count)s times", { severalUsers: "", count }) - : _t("%(oneUser)sleft %(count)s times", { oneUser: "", count }); + ? _t("timeline|summary|left_multiple", { severalUsers: "", count }) + : _t("timeline|summary|left", { oneUser: "", count }); break; case TransitionType.JoinedAndLeft: res = userCount > 1 - ? _t("%(severalUsers)sjoined and left %(count)s times", { severalUsers: "", count }) - : _t("%(oneUser)sjoined and left %(count)s times", { oneUser: "", count }); + ? _t("timeline|summary|joined_and_left_multiple", { severalUsers: "", count }) + : _t("timeline|summary|joined_and_left", { oneUser: "", count }); break; case TransitionType.LeftAndJoined: res = userCount > 1 - ? _t("%(severalUsers)sleft and rejoined %(count)s times", { severalUsers: "", count }) - : _t("%(oneUser)sleft and rejoined %(count)s times", { oneUser: "", count }); + ? _t("timeline|summary|rejoined_multiple", { severalUsers: "", count }) + : _t("timeline|summary|rejoined", { oneUser: "", count }); break; case TransitionType.InviteReject: res = userCount > 1 - ? _t("%(severalUsers)srejected their invitations %(count)s times", { + ? _t("timeline|summary|rejected_invite_multiple", { severalUsers: "", count, }) - : _t("%(oneUser)srejected their invitation %(count)s times", { oneUser: "", count }); + : _t("timeline|summary|rejected_invite", { oneUser: "", count }); break; case TransitionType.InviteWithdrawal: res = userCount > 1 - ? _t("%(severalUsers)shad their invitations withdrawn %(count)s times", { + ? _t("timeline|summary|invite_withdrawn_multiple", { severalUsers: "", count, }) - : _t("%(oneUser)shad their invitation withdrawn %(count)s times", { oneUser: "", count }); + : _t("timeline|summary|invite_withdrawn", { oneUser: "", count }); break; case TransitionType.Invited: res = userCount > 1 - ? _t("were invited %(count)s times", { count }) - : _t("was invited %(count)s times", { count }); + ? _t("timeline|summary|invited_multiple", { count }) + : _t("timeline|summary|invited", { count }); break; case TransitionType.Banned: res = userCount > 1 - ? _t("were banned %(count)s times", { count }) - : _t("was banned %(count)s times", { count }); + ? _t("timeline|summary|banned_multiple", { count }) + : _t("timeline|summary|banned", { count }); break; case TransitionType.Unbanned: res = userCount > 1 - ? _t("were unbanned %(count)s times", { count }) - : _t("was unbanned %(count)s times", { count }); + ? _t("timeline|summary|unbanned_multiple", { count }) + : _t("timeline|summary|unbanned", { count }); break; case TransitionType.Kicked: res = userCount > 1 - ? _t("were removed %(count)s times", { count }) - : _t("was removed %(count)s times", { count }); + ? _t("timeline|summary|kicked_multiple", { count }) + : _t("timeline|summary|kicked", { count }); break; case TransitionType.ChangedName: res = userCount > 1 - ? _t("%(severalUsers)schanged their name %(count)s times", { severalUsers: "", count }) - : _t("%(oneUser)schanged their name %(count)s times", { oneUser: "", count }); + ? _t("timeline|summary|changed_name_multiple", { severalUsers: "", count }) + : _t("timeline|summary|changed_name", { oneUser: "", count }); break; case TransitionType.ChangedAvatar: res = userCount > 1 - ? _t("%(severalUsers)schanged their profile picture %(count)s times", { + ? _t("timeline|summary|changed_avatar_multiple", { severalUsers: "", count, }) - : _t("%(oneUser)schanged their profile picture %(count)s times", { oneUser: "", count }); + : _t("timeline|summary|changed_avatar", { oneUser: "", count }); break; case TransitionType.NoChange: res = userCount > 1 - ? _t("%(severalUsers)smade no changes %(count)s times", { severalUsers: "", count }) - : _t("%(oneUser)smade no changes %(count)s times", { oneUser: "", count }); + ? _t("timeline|summary|no_change_multiple", { severalUsers: "", count }) + : _t("timeline|summary|no_change", { oneUser: "", count }); break; case TransitionType.ServerAcl: res = userCount > 1 - ? _t("%(severalUsers)schanged the server ACLs %(count)s times", { severalUsers: "", count }) - : _t("%(oneUser)schanged the server ACLs %(count)s times", { oneUser: "", count }); + ? _t("timeline|summary|server_acls_multiple", { severalUsers: "", count }) + : _t("timeline|summary|server_acls", { oneUser: "", count }); break; case TransitionType.ChangedPins: res = userCount > 1 ? _t( - "%(severalUsers)schanged the pinned messages for the room %(count)s times", + "timeline|summary|pinned_events_multiple", { severalUsers: "", count }, { a: (sub) => ( @@ -355,7 +355,7 @@ export default class EventListSummary extends React.Component< }, ) : _t( - "%(oneUser)schanged the pinned messages for the room %(count)s times", + "timeline|summary|pinned_events", { oneUser: "", count }, { a: (sub) => ( @@ -369,14 +369,14 @@ export default class EventListSummary extends React.Component< case TransitionType.MessageRemoved: res = userCount > 1 - ? _t("%(severalUsers)sremoved a message %(count)s times", { severalUsers: "", count }) - : _t("%(oneUser)sremoved a message %(count)s times", { oneUser: "", count }); + ? _t("timeline|summary|redacted_multiple", { severalUsers: "", count }) + : _t("timeline|summary|redacted", { oneUser: "", count }); break; case TransitionType.HiddenEvent: res = userCount > 1 - ? _t("%(severalUsers)ssent %(count)s hidden messages", { severalUsers: "", count }) - : _t("%(oneUser)ssent %(count)s hidden messages", { oneUser: "", count }); + ? _t("timeline|summary|hidden_event_multiple", { severalUsers: "", count }) + : _t("timeline|summary|hidden_event", { oneUser: "", count }); break; } diff --git a/src/components/views/emojipicker/EmojiPicker.tsx b/src/components/views/emojipicker/EmojiPicker.tsx index 51b3b77796..7d1956c815 100644 --- a/src/components/views/emojipicker/EmojiPicker.tsx +++ b/src/components/views/emojipicker/EmojiPicker.tsx @@ -87,63 +87,63 @@ class EmojiPicker extends React.Component { this.categories = [ { id: "recent", - name: _t("Frequently Used"), + name: _t("emoji|category_frequently_used"), enabled: this.recentlyUsed.length > 0, visible: this.recentlyUsed.length > 0, ref: React.createRef(), }, { id: "people", - name: _t("Smileys & People"), + name: _t("emoji|category_smileys_people"), enabled: true, visible: true, ref: React.createRef(), }, { id: "nature", - name: _t("Animals & Nature"), + name: _t("emoji|category_animals_nature"), enabled: true, visible: false, ref: React.createRef(), }, { id: "foods", - name: _t("Food & Drink"), + name: _t("emoji|category_food_drink"), enabled: true, visible: false, ref: React.createRef(), }, { id: "activity", - name: _t("Activities"), + name: _t("emoji|category_activities"), enabled: true, visible: false, ref: React.createRef(), }, { id: "places", - name: _t("Travel & Places"), + name: _t("emoji|category_travel_places"), enabled: true, visible: false, ref: React.createRef(), }, { id: "objects", - name: _t("Objects"), + name: _t("emoji|category_objects"), enabled: true, visible: false, ref: React.createRef(), }, { id: "symbols", - name: _t("Symbols"), + name: _t("emoji|category_symbols"), enabled: true, visible: false, ref: React.createRef(), }, { id: "flags", - name: _t("Flags"), + name: _t("emoji|category_flags"), enabled: true, visible: false, ref: React.createRef(), diff --git a/src/components/views/emojipicker/Header.tsx b/src/components/views/emojipicker/Header.tsx index c3643f6e2a..27638bae1a 100644 --- a/src/components/views/emojipicker/Header.tsx +++ b/src/components/views/emojipicker/Header.tsx @@ -95,7 +95,7 @@ class Header extends React.PureComponent {