Skip to content

Commit

Permalink
Merge tag 'v3.68.0' into sc
Browse files Browse the repository at this point in the history
* Only allow to start a DM with one email if encryption by default is enabled ([\matrix-org#10253](matrix-org#10253)). Fixes element-hq/element-web#23133.
* DM rooms are now encrypted if encryption by default is enabled and only inviting a single email address. Any action in the result DM room will be blocked until the other has joined. ([\matrix-org#10229](matrix-org#10229)).
* Reduce bottom margin of ReplyChain on compact modern layout ([\matrix-org#8972](matrix-org#8972)). Fixes element-hq/element-web#22748. Contributed by @luixxiul.
* Support for v2 of MSC3903 ([\matrix-org#10165](matrix-org#10165)). Contributed by @hughns.
* When starting a DM, existing rooms with pending third-party invites will be reused. ([\matrix-org#10256](matrix-org#10256)). Fixes element-hq/element-web#23139.
* Polls push rules: synchronise poll rules with message rules ([\matrix-org#10263](matrix-org#10263)). Contributed by @kerryarchibald.
* New verification request toast button labels ([\matrix-org#10259](matrix-org#10259)).
* Remove padding around integration manager iframe ([\matrix-org#10148](matrix-org#10148)).
* Fix block code styling in rich text editor ([\matrix-org#10246](matrix-org#10246)). Contributed by @alunturner.
* Poll history: fetch more poll history ([\matrix-org#10235](matrix-org#10235)). Contributed by @kerryarchibald.
* Sort short/exact emoji matches before longer incomplete matches ([\matrix-org#10212](matrix-org#10212)). Fixes element-hq/element-web#23210. Contributed by @grimhilt.
* Poll history: detail screen ([\matrix-org#10172](matrix-org#10172)). Contributed by @kerryarchibald.
* Provide a more detailed error message than "No known servers" ([\matrix-org#6048](matrix-org#6048)). Fixes element-hq/element-web#13247. Contributed by @aaronraimist.
* Say when a call was answered from a different device ([\matrix-org#10224](matrix-org#10224)).
* Widget permissions customizations using module api ([\matrix-org#10121](matrix-org#10121)). Contributed by @maheichyk.
* Fix copy button icon overlapping with copyable text ([\matrix-org#10227](matrix-org#10227)). Contributed by @Adesh-Pandey.
* Support joining non-peekable rooms via the module API ([\matrix-org#10154](matrix-org#10154)). Contributed by @maheichyk.
* The "new login" toast does now display the same device information as in the settings. "No" does now open the device settings. "Yes, it was me" dismisses the toast. ([\matrix-org#10200](matrix-org#10200)).
* Do not prompt for a password when doing a „reset all“ after login ([\matrix-org#10208](matrix-org#10208)).
* Fix incorrect copy in space creation flow ([\matrix-org#10296](matrix-org#10296)). Fixes element-hq/element-web#24741.
* Fix space settings dialog having rogue title tooltip ([\matrix-org#10293](matrix-org#10293)). Fixes element-hq/element-web#24740.
* Show spinner when starting a DM from the user profile (right panel) ([\matrix-org#10290](matrix-org#10290)).
* Reduce height of toggle on expanded view source event ([\matrix-org#10283](matrix-org#10283)). Fixes element-hq/element-web#22873. Contributed by @luixxiul.
* Pillify http and non-prefixed matrix.to links ([\matrix-org#10277](matrix-org#10277)). Fixes element-hq/element-web#20844.
* Fix some features not being configurable via `features` ([\matrix-org#10276](matrix-org#10276)).
* Fix starting a DM from the right panel in some cases ([\matrix-org#10278](matrix-org#10278)). Fixes element-hq/element-web#24722.
* Align info EventTile and normal EventTile on IRC layout ([\matrix-org#10197](matrix-org#10197)). Fixes element-hq/element-web#22782. Contributed by @luixxiul.
* Fix blowout of waveform of the voice message player on narrow UI ([\matrix-org#8861](matrix-org#8861)). Fixes element-hq/element-web#22604. Contributed by @luixxiul.
* Fix the hidden view source toggle on IRC layout ([\matrix-org#10266](matrix-org#10266)). Fixes element-hq/element-web#22872. Contributed by @luixxiul.
* Fix buttons on the room header being compressed due to long room name ([\matrix-org#10155](matrix-org#10155)). Contributed by @luixxiul.
* Use the room avatar as a placeholder in calls ([\matrix-org#10231](matrix-org#10231)).
* Fix calls showing as 'connecting' after hangup ([\matrix-org#10223](matrix-org#10223)).
* Prevent multiple Jitsi calls started at the same time ([\matrix-org#10183](matrix-org#10183)). Fixes element-hq/element-web#23009.
* Make localization keys compatible with agglutinative and/or SOV type languages ([\matrix-org#10159](matrix-org#10159)). Contributed by @luixxiul.
  • Loading branch information
su-ex committed Mar 15, 2023
2 parents aec5cfb + 2d1d1fb commit 57dcffd
Show file tree
Hide file tree
Showing 491 changed files with 9,040 additions and 8,592 deletions.
2 changes: 1 addition & 1 deletion .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@ indent_size = 4
trim_trailing_whitespace = true

[*.{yml,yaml}]
indent_size = 2
indent_size = 4
26 changes: 26 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -165,17 +165,43 @@ module.exports = {
},
{
files: ["test/**/*.{ts,tsx}", "cypress/**/*.ts"],
extends: ["plugin:matrix-org/jest"],
rules: {
// We don't need super strict typing in test utilities
"@typescript-eslint/explicit-function-return-type": "off",
"@typescript-eslint/explicit-member-accessibility": "off",

// Jest/Cypress specific

// Disabled tests are a reality for now but as soon as all of the xits are
// eliminated, we should enforce this.
"jest/no-disabled-tests": "off",
// TODO: There are many tests with invalid expects that should be fixed,
// https://github.com/vector-im/element-web/issues/24709
"jest/valid-expect": "off",
// TODO: There are many cases to refactor away,
// https://github.com/vector-im/element-web/issues/24710
"jest/no-conditional-expect": "off",
// Also treat "oldBackendOnly" as a test function.
// Used in some crypto tests.
"jest/no-standalone-expect": [
"error",
{
additionalTestBlockFunctions: ["beforeAll", "beforeEach", "oldBackendOnly"],
},
],
},
},
{
files: ["cypress/**/*.ts"],
parserOptions: {
project: ["./cypress/tsconfig.json"],
},
rules: {
// Cypress "promises" work differently - disable some related rules
"jest/valid-expect-in-promise": "off",
"jest/no-done-callback": "off",
},
},
],
settings: {
Expand Down
36 changes: 31 additions & 5 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,15 @@
Changes in [3.67.0](https://github.com/matrix-org/matrix-react-sdk/releases/tag/v3.67.0) (2023-02-28)
Changes in [3.68.0](https://github.com/matrix-org/matrix-react-sdk/releases/tag/v3.68.0) (2023-03-15)
=====================================================================================================

## ✨ Features
* Only allow to start a DM with one email if encryption by default is enabled ([\#10253](https://github.com/matrix-org/matrix-react-sdk/pull/10253)). Fixes vector-im/element-web#23133.
* DM rooms are now encrypted if encryption by default is enabled and only inviting a single email address. Any action in the result DM room will be blocked until the other has joined. ([\#10229](https://github.com/matrix-org/matrix-react-sdk/pull/10229)).
* Reduce bottom margin of ReplyChain on compact modern layout ([\#8972](https://github.com/matrix-org/matrix-react-sdk/pull/8972)). Fixes vector-im/element-web#22748. Contributed by @luixxiul.
* Support for v2 of MSC3903 ([\#10165](https://github.com/matrix-org/matrix-react-sdk/pull/10165)). Contributed by @hughns.
* When starting a DM, existing rooms with pending third-party invites will be reused. ([\#10256](https://github.com/matrix-org/matrix-react-sdk/pull/10256)). Fixes vector-im/element-web#23139.
* Polls push rules: synchronise poll rules with message rules ([\#10263](https://github.com/matrix-org/matrix-react-sdk/pull/10263)). Contributed by @kerryarchibald.
* New verification request toast button labels ([\#10259](https://github.com/matrix-org/matrix-react-sdk/pull/10259)).
* Remove padding around integration manager iframe ([\#10148](https://github.com/matrix-org/matrix-react-sdk/pull/10148)).
* Fix block code styling in rich text editor ([\#10246](https://github.com/matrix-org/matrix-react-sdk/pull/10246)). Contributed by @alunturner.
* Poll history: fetch more poll history ([\#10235](https://github.com/matrix-org/matrix-react-sdk/pull/10235)). Contributed by @kerryarchibald.
* Sort short/exact emoji matches before longer incomplete matches ([\#10212](https://github.com/matrix-org/matrix-react-sdk/pull/10212)). Fixes vector-im/element-web#23210. Contributed by @grimhilt.
Expand All @@ -13,6 +21,28 @@ Changes in [3.67.0](https://github.com/matrix-org/matrix-react-sdk/releases/tag/
* Support joining non-peekable rooms via the module API ([\#10154](https://github.com/matrix-org/matrix-react-sdk/pull/10154)). Contributed by @maheichyk.
* The "new login" toast does now display the same device information as in the settings. "No" does now open the device settings. "Yes, it was me" dismisses the toast. ([\#10200](https://github.com/matrix-org/matrix-react-sdk/pull/10200)).
* Do not prompt for a password when doing a „reset all“ after login ([\#10208](https://github.com/matrix-org/matrix-react-sdk/pull/10208)).

## 🐛 Bug Fixes
* Fix incorrect copy in space creation flow ([\#10296](https://github.com/matrix-org/matrix-react-sdk/pull/10296)). Fixes vector-im/element-web#24741.
* Fix space settings dialog having rogue title tooltip ([\#10293](https://github.com/matrix-org/matrix-react-sdk/pull/10293)). Fixes vector-im/element-web#24740.
* Show spinner when starting a DM from the user profile (right panel) ([\#10290](https://github.com/matrix-org/matrix-react-sdk/pull/10290)).
* Reduce height of toggle on expanded view source event ([\#10283](https://github.com/matrix-org/matrix-react-sdk/pull/10283)). Fixes vector-im/element-web#22873. Contributed by @luixxiul.
* Pillify http and non-prefixed matrix.to links ([\#10277](https://github.com/matrix-org/matrix-react-sdk/pull/10277)). Fixes vector-im/element-web#20844.
* Fix some features not being configurable via `features` ([\#10276](https://github.com/matrix-org/matrix-react-sdk/pull/10276)).
* Fix starting a DM from the right panel in some cases ([\#10278](https://github.com/matrix-org/matrix-react-sdk/pull/10278)). Fixes vector-im/element-web#24722.
* Align info EventTile and normal EventTile on IRC layout ([\#10197](https://github.com/matrix-org/matrix-react-sdk/pull/10197)). Fixes vector-im/element-web#22782. Contributed by @luixxiul.
* Fix blowout of waveform of the voice message player on narrow UI ([\#8861](https://github.com/matrix-org/matrix-react-sdk/pull/8861)). Fixes vector-im/element-web#22604. Contributed by @luixxiul.
* Fix the hidden view source toggle on IRC layout ([\#10266](https://github.com/matrix-org/matrix-react-sdk/pull/10266)). Fixes vector-im/element-web#22872. Contributed by @luixxiul.
* Fix buttons on the room header being compressed due to long room name ([\#10155](https://github.com/matrix-org/matrix-react-sdk/pull/10155)). Contributed by @luixxiul.
* Use the room avatar as a placeholder in calls ([\#10231](https://github.com/matrix-org/matrix-react-sdk/pull/10231)).
* Fix calls showing as 'connecting' after hangup ([\#10223](https://github.com/matrix-org/matrix-react-sdk/pull/10223)).
* Prevent multiple Jitsi calls started at the same time ([\#10183](https://github.com/matrix-org/matrix-react-sdk/pull/10183)). Fixes vector-im/element-web#23009.
* Make localization keys compatible with agglutinative and/or SOV type languages ([\#10159](https://github.com/matrix-org/matrix-react-sdk/pull/10159)). Contributed by @luixxiul.

Changes in [3.67.0](https://github.com/matrix-org/matrix-react-sdk/releases/tag/v3.67.0) (2023-02-28)
=====================================================================================================

## ✨ Features
* Display "The sender has blocked you from receiving this message" error message instead of "Unable to decrypt message" ([\#10202](https://github.com/matrix-org/matrix-react-sdk/pull/10202)). Contributed by @florianduros.
* Polls: show warning about undecryptable relations ([\#10179](https://github.com/matrix-org/matrix-react-sdk/pull/10179)). Contributed by @kerryarchibald.
* Poll history: fetch last 30 days of polls ([\#10157](https://github.com/matrix-org/matrix-react-sdk/pull/10157)). Contributed by @kerryarchibald.
Expand All @@ -25,11 +55,7 @@ Changes in [3.67.0](https://github.com/matrix-org/matrix-react-sdk/releases/tag/
* Render poll end events in timeline ([\#10027](https://github.com/matrix-org/matrix-react-sdk/pull/10027)). Contributed by @kerryarchibald.

## 🐛 Bug Fixes
* Use the room avatar as a placeholder in calls ([\#10231](https://github.com/matrix-org/matrix-react-sdk/pull/10231)).
* Fix calls showing as 'connecting' after hangup ([\#10223](https://github.com/matrix-org/matrix-react-sdk/pull/10223)).
* Stop access token overflowing the box ([\#10069](https://github.com/matrix-org/matrix-react-sdk/pull/10069)). Fixes vector-im/element-web#24023. Contributed by @sbjaj33.
* Prevent multiple Jitsi calls started at the same time ([\#10183](https://github.com/matrix-org/matrix-react-sdk/pull/10183)). Fixes vector-im/element-web#23009.
* Make localization keys compatible with agglutinative and/or SOV type languages ([\#10159](https://github.com/matrix-org/matrix-react-sdk/pull/10159)). Contributed by @luixxiul.
* Add link to next file in the export ([\#10190](https://github.com/matrix-org/matrix-react-sdk/pull/10190)). Fixes vector-im/element-web#20272. Contributed by @grimhilt.
* Ended poll tiles: add ended the poll message ([\#10193](https://github.com/matrix-org/matrix-react-sdk/pull/10193)). Fixes vector-im/element-web#24579. Contributed by @kerryarchibald.
* Fix accidentally inverted condition for room ordering ([\#10178](https://github.com/matrix-org/matrix-react-sdk/pull/10178)). Fixes vector-im/element-web#24527. Contributed by @justjanne.
Expand Down
29 changes: 28 additions & 1 deletion cypress/e2e/create-room/create-room.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright 2022 The Matrix.org Foundation C.I.C.
Copyright 2022-2023 The Matrix.org Foundation C.I.C.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -61,4 +61,31 @@ describe("Create Room", () => {
cy.contains(".mx_RoomHeader_nametext", name);
cy.contains(".mx_RoomHeader_topic", topic);
});

it("should create a room with a long room name, which is displayed with ellipsis", () => {
let roomId: string;
const LONG_ROOM_NAME =
"Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore " +
"et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut " +
"aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum " +
"dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui " +
"officia deserunt mollit anim id est laborum.";

cy.createRoom({ name: LONG_ROOM_NAME }).then((_roomId) => {
roomId = _roomId;
cy.visit("/#/room/" + roomId);
});

// Wait until the room name is set
cy.get(".mx_RoomHeader_nametext").contains("Lorem ipsum");

// Make sure size of buttons on RoomHeader (except .mx_RoomHeader_name) are specified
// and the buttons are not compressed
// TODO: use a same class name
cy.get(".mx_RoomHeader_button").should("have.css", "height", "32px").should("have.css", "width", "32px");
cy.get(".mx_HeaderButtons > .mx_RightPanel_headerButton")
.should("have.css", "height", "32px")
.should("have.css", "width", "32px");
cy.get(".mx_RoomHeader").percySnapshotElement("Room header with a long room name");
});
});
35 changes: 28 additions & 7 deletions cypress/e2e/crypto/decryption-failure.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,12 @@ describe("Decryption Failure Bar", () => {
"Verify this device to access all messages",
);

cy.percySnapshot("DecryptionFailureBar prompts user to verify");
cy.get(".mx_DecryptionFailureBar").percySnapshotElement(
"DecryptionFailureBar prompts user to verify",
{
widths: [320, 640],
},
);

cy.contains(".mx_DecryptionFailureBar_button", "Resend key requests").should("not.exist");
cy.contains(".mx_DecryptionFailureBar_button", "Verify").click();
Expand Down Expand Up @@ -146,17 +151,23 @@ describe("Decryption Failure Bar", () => {
"Open another device to load encrypted messages",
);

cy.percySnapshot(
cy.get(".mx_DecryptionFailureBar").percySnapshotElement(
"DecryptionFailureBar prompts user to open another device, with Resend Key Requests button",
{
widths: [320, 640],
},
);

cy.intercept("/_matrix/client/r0/sendToDevice/m.room_key_request/*").as("keyRequest");
cy.contains(".mx_DecryptionFailureBar_button", "Resend key requests").click();
cy.wait("@keyRequest");
cy.contains(".mx_DecryptionFailureBar_button", "Resend key requests").should("not.exist");

cy.percySnapshot(
"DecryptionFailureBar prompts user to open another device, " + "without Resend Key Requests button",
cy.get(".mx_DecryptionFailureBar").percySnapshotElement(
"DecryptionFailureBar prompts user to open another device, without Resend Key Requests button",
{
widths: [320, 640],
},
);
},
);
Expand All @@ -177,7 +188,9 @@ describe("Decryption Failure Bar", () => {
"Reset your keys to prevent future decryption errors",
);

cy.percySnapshot("DecryptionFailureBar prompts user to reset keys");
cy.get(".mx_DecryptionFailureBar").percySnapshotElement("DecryptionFailureBar prompts user to reset keys", {
widths: [320, 640],
});

cy.contains(".mx_DecryptionFailureBar_button", "Reset").click();

Expand All @@ -196,7 +209,12 @@ describe("Decryption Failure Bar", () => {
"Some messages could not be decrypted",
);

cy.percySnapshot("DecryptionFailureBar displays general message with no call to action");
cy.get(".mx_DecryptionFailureBar").percySnapshotElement(
"DecryptionFailureBar displays general message with no call to action",
{
widths: [320, 640],
},
);
},
);

Expand All @@ -210,7 +228,10 @@ describe("Decryption Failure Bar", () => {
cy.get(".mx_DecryptionFailureBar").should("exist");
cy.get(".mx_DecryptionFailureBar .mx_Spinner").should("exist");

cy.percySnapshot("DecryptionFailureBar displays loading spinner");
cy.get(".mx_DecryptionFailureBar").percySnapshotElement("DecryptionFailureBar displays loading spinner", {
allowSpinners: true,
widths: [320, 640],
});

cy.wait(5000);
cy.get(".mx_DecryptionFailureBar .mx_Spinner").should("not.exist");
Expand Down
4 changes: 2 additions & 2 deletions cypress/e2e/polls/polls.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import { HomeserverInstance } from "../../plugins/utils/homeserver";
import { MatrixClient } from "../../global";
import Chainable = Cypress.Chainable;

const hideTimestampCSS = ".mx_MessageTimestamp { visibility: hidden !important; }";
const hidePercyCSS = ".mx_MessageTimestamp, .mx_RoomView_myReadMarker { visibility: hidden !important; }";

describe("Polls", () => {
let homeserver: HomeserverInstance;
Expand Down Expand Up @@ -133,7 +133,7 @@ describe("Polls", () => {
.as("pollId");

cy.get<string>("@pollId").then((pollId) => {
getPollTile(pollId).percySnapshotElement("Polls Timeline tile - no votes", { percyCSS: hideTimestampCSS });
getPollTile(pollId).percySnapshotElement("Polls Timeline tile - no votes", { percyCSS: hidePercyCSS });

// Bot votes 'Maybe' in the poll
botVoteForOption(bot, roomId, pollId, pollParams.options[2]);
Expand Down
2 changes: 1 addition & 1 deletion cypress/e2e/sliding-sync/sliding-sync.ts
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@ describe("Sliding Sync", () => {
});

// Regression test for https://github.com/vector-im/element-web/issues/21462
it("should not cancel replies when permalinks are clicked ", () => {
it("should not cancel replies when permalinks are clicked", () => {
cy.get<string>("@roomId").then((roomId) => {
// we require a first message as you cannot click the permalink text with the avatar in the way
return cy
Expand Down
43 changes: 22 additions & 21 deletions cypress/e2e/spotlight/spotlight.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import Timeoutable = Cypress.Timeoutable;
import Withinable = Cypress.Withinable;
import Shadow = Cypress.Shadow;

export enum Filter {
enum Filter {
People = "people",
PublicRooms = "public_rooms",
}
Expand Down Expand Up @@ -297,27 +297,28 @@ describe("Spotlight", () => {

// TODO: We currently can’t test finding rooms on other homeservers/other protocols
// We obviously don’t have federation or bridges in cypress tests
/*
const room3Name = "Matrix HQ";
const room3Id = "#matrix:matrix.org";
it("should find unknown public rooms on other homeservers", () => {
cy.openSpotlightDialog().within(() => {
cy.spotlightFilter(Filter.PublicRooms);
cy.spotlightSearch().clear().type(room3Name);
cy.get("[aria-haspopup=true][role=button]").click();
}).then(() => {
cy.contains(".mx_GenericDropdownMenu_Option--header", "matrix.org")
.next("[role=menuitemradio]")
.click();
cy.wait(3_600_000);
}).then(() => cy.spotlightDialog().within(() => {
cy.spotlightResults().should("have.length", 1);
cy.spotlightResults().eq(0).should("contain", room3Name);
cy.spotlightResults().eq(0).should("contain", room3Id);
}));
it.skip("should find unknown public rooms on other homeservers", () => {
cy.openSpotlightDialog()
.within(() => {
cy.spotlightFilter(Filter.PublicRooms);
cy.spotlightSearch().clear().type(room3Name);
cy.get("[aria-haspopup=true][role=button]").click();
})
.then(() => {
cy.contains(".mx_GenericDropdownMenu_Option--header", "matrix.org")
.next("[role=menuitemradio]")
.click();
cy.wait(3_600_000);
})
.then(() =>
cy.spotlightDialog().within(() => {
cy.spotlightResults().should("have.length", 1);
cy.spotlightResults().eq(0).should("contain", room3Name);
cy.spotlightResults().eq(0).should("contain", room3Id);
}),
);
});
*/

it("should find known people", () => {
cy.openSpotlightDialog()
.within(() => {
Expand Down
Loading

0 comments on commit 57dcffd

Please sign in to comment.