mirror of
https://github.com/element-hq/element-desktop.git
synced 2026-01-04 13:39:09 -05:00
Compare commits
90 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9b59384759 | ||
|
|
5b3acbbafb | ||
|
|
22d4297f15 | ||
|
|
95bda97de7 | ||
|
|
05735eb62c | ||
|
|
7e7e6bee59 | ||
|
|
e735ce9974 | ||
|
|
6aa3216562 | ||
|
|
9d7d53723b | ||
|
|
990bbd468b | ||
|
|
96713a2f3c | ||
|
|
d5e28e71f3 | ||
|
|
c3ec9c1028 | ||
|
|
4de4c12eeb | ||
|
|
b81daa22cb | ||
|
|
6a2d4bb5ed | ||
|
|
5f5e1666cf | ||
|
|
13315ad63c | ||
|
|
162e3e2a89 | ||
|
|
7a24784628 | ||
|
|
6fca680085 | ||
|
|
a1a48a76ec | ||
|
|
38c3bc440e | ||
|
|
52715a8a89 | ||
|
|
ca05241e72 | ||
|
|
13a0d0d3e2 | ||
|
|
6239aa5d9f | ||
|
|
e603dad2fc | ||
|
|
d7281358da | ||
|
|
4b2126187c | ||
|
|
266a6a83dc | ||
|
|
a204fbafd9 | ||
|
|
fe2c4b9984 | ||
|
|
02db8659c1 | ||
|
|
a59c660b25 | ||
|
|
4ec81df715 | ||
|
|
de229a446f | ||
|
|
cd91442510 | ||
|
|
472aca04a2 | ||
|
|
effe3239db | ||
|
|
d1bd7a737a | ||
|
|
8f40ec2bdd | ||
|
|
9918467a8d | ||
|
|
525c984e8a | ||
|
|
9fb6e02c73 | ||
|
|
5f2a664a32 | ||
|
|
6afd264bc5 | ||
|
|
be0677cba7 | ||
|
|
a627ce93d7 | ||
|
|
78e0cc2859 | ||
|
|
71e85a32fc | ||
|
|
b406c90905 | ||
|
|
2af4f67d41 | ||
|
|
8754fa5fa2 | ||
|
|
14a24be4ea | ||
|
|
d3f21ca1e1 | ||
|
|
b799e20ce2 | ||
|
|
751efa4490 | ||
|
|
f0aab74c7c | ||
|
|
ab254ef453 | ||
|
|
ff100df8cb | ||
|
|
15052d23d4 | ||
|
|
2143be64bc | ||
|
|
00a8561995 | ||
|
|
f7d8540695 | ||
|
|
f7c4d6731d | ||
|
|
580d7f82cd | ||
|
|
56f49701aa | ||
|
|
7b03223218 | ||
|
|
2ae77c64a1 | ||
|
|
63698b6efa | ||
|
|
af23620d3e | ||
|
|
debe323247 | ||
|
|
1390e1ea3b | ||
|
|
beafe2c2fd | ||
|
|
a0665f5499 | ||
|
|
f21ac771eb | ||
|
|
04905a39a7 | ||
|
|
2018a51469 | ||
|
|
5c23a23f39 | ||
|
|
5ce99c9c61 | ||
|
|
bc0a9d3d6f | ||
|
|
22f6a4df54 | ||
|
|
597f3562e4 | ||
|
|
5061452d57 | ||
|
|
00d68c8193 | ||
|
|
3e871f07c4 | ||
|
|
270657a1a5 | ||
|
|
ca6edccaf4 | ||
|
|
79bd380ba2 |
4
.github/workflows/build_and_deploy.yaml
vendored
4
.github/workflows/build_and_deploy.yaml
vendored
@@ -85,7 +85,7 @@ jobs:
|
||||
strategy:
|
||||
matrix:
|
||||
arch: [amd64, arm64]
|
||||
sqlcipher: [system, static]
|
||||
sqlcipher: [static]
|
||||
uses: ./.github/workflows/build_linux.yaml
|
||||
with:
|
||||
arch: ${{ matrix.arch }}
|
||||
@@ -218,7 +218,7 @@ jobs:
|
||||
run: |
|
||||
for arch in amd64 arm64
|
||||
do
|
||||
echo "$arch=$(ls linux-$arch-sqlcipher-system/*.deb | tail -n1)" >> $GITHUB_OUTPUT
|
||||
echo "$arch=$(ls linux-$arch-sqlcipher-static/*.deb | tail -n1)" >> $GITHUB_OUTPUT
|
||||
done
|
||||
|
||||
- name: Stash debs
|
||||
|
||||
17
.github/workflows/build_and_test.yaml
vendored
17
.github/workflows/build_and_test.yaml
vendored
@@ -63,22 +63,22 @@ jobs:
|
||||
os: ubuntu-latest
|
||||
artifact: linux-amd64-sqlcipher-system
|
||||
executable: "/opt/Element/element-desktop"
|
||||
prepare_cmd: "sudo apt install ./dist/*.deb"
|
||||
prepare_cmd: "sudo apt-get -qq update && sudo apt install ./dist/*.deb"
|
||||
- name: "Linux (amd64) (sqlcipher: static)"
|
||||
os: ubuntu-latest
|
||||
artifact: linux-amd64-sqlcipher-static
|
||||
executable: "/opt/Element/element-desktop"
|
||||
prepare_cmd: "sudo apt install ./dist/*.deb"
|
||||
prepare_cmd: "sudo apt-get -qq update && sudo apt install ./dist/*.deb"
|
||||
- name: "Linux (arm64) (sqlcipher: system)"
|
||||
os: dind-l-arm64
|
||||
artifact: linux-arm64-sqlcipher-system
|
||||
executable: "/opt/Element/element-desktop"
|
||||
prepare_cmd: "sudo apt install -y ./dist/*.deb"
|
||||
prepare_cmd: "sudo apt-get -qq update && sudo apt install -y ./dist/*.deb"
|
||||
- name: "Linux (arm64) (sqlcipher: static)"
|
||||
os: dind-l-arm64
|
||||
artifact: linux-arm64-sqlcipher-static
|
||||
executable: "/opt/Element/element-desktop"
|
||||
prepare_cmd: "sudo apt install -y ./dist/*.deb"
|
||||
prepare_cmd: "sudo apt-get -qq update && sudo apt install -y ./dist/*.deb"
|
||||
- name: Windows (x86)
|
||||
os: windows-latest
|
||||
artifact: win-ia32
|
||||
@@ -94,6 +94,9 @@ jobs:
|
||||
- name: Install Yarn
|
||||
if: runner.environment == 'self-hosted'
|
||||
run: |
|
||||
# Sanity check that the arch is arm64 as we expect
|
||||
[[ $(uname -p) == "aarch64" ]] || exit 1
|
||||
|
||||
sudo apt-get -qq update
|
||||
sudo apt-get install -y curl
|
||||
curl -fsSL --create-dirs -o $HOME/bin/yarn https://github.com/yarnpkg/yarn/releases/download/v1.22.19/yarn-1.22.19.js
|
||||
@@ -128,6 +131,12 @@ jobs:
|
||||
# We need sudo on Linux as it is installed in /opt/
|
||||
RUN_AS: ${{ runner.os == 'Linux' && 'sudo' || '' }}
|
||||
|
||||
- name: Workaround macOS GHA permission issues
|
||||
if: matrix.os == 'macos-latest'
|
||||
run: |
|
||||
sqlite3 $HOME/Library/Application\ Support/com.apple.TCC/TCC.db "INSERT OR IGNORE INTO access VALUES ('kTCCServiceMicrophone','/usr/local/opt/runner/provisioner/provisioner',1,2,4,1,NULL,NULL,0,'UNUSED',NULL,0,1687786159,NULL,NULL,'UNUSED',1687786159);"
|
||||
sqlite3 $HOME/Library/Application\ Support/com.apple.TCC/TCC.db "INSERT OR IGNORE INTO access VALUES ('kTCCServiceMicrophone','/opt/off/opt/runner/provisioner/provisioner',1,2,4,1,NULL,NULL,0,'UNUSED',NULL,0,1687786159,NULL,NULL,'UNUSED',1687786159);"
|
||||
|
||||
- name: Run tests
|
||||
uses: coactions/setup-xvfb@6b00cf1889f4e1d5a48635647013c0508128ee1a
|
||||
timeout-minutes: 5
|
||||
|
||||
7
.github/workflows/build_linux.yaml
vendored
7
.github/workflows/build_linux.yaml
vendored
@@ -38,6 +38,9 @@ jobs:
|
||||
- name: Install missing tools
|
||||
if: runner.environment == 'self-hosted'
|
||||
run: |
|
||||
# Sanity check that the arch is arm64 as we expect
|
||||
[[ $(uname -p) == "aarch64" ]] || exit 1
|
||||
|
||||
sudo apt-get -qq update
|
||||
# curl for yarn download, git for tj-actions/changed-files, zstd for actions/cache
|
||||
sudo apt-get install -y curl git zstd
|
||||
@@ -109,14 +112,14 @@ jobs:
|
||||
- name: "Get modified files"
|
||||
id: changed_files
|
||||
if: steps.cache.outputs.cache-hit != 'true' && github.event_name == 'pull_request'
|
||||
uses: tj-actions/changed-files@a29e8b565651ce417abb5db7164b4a2ad8b6155c # v44
|
||||
uses: tj-actions/changed-files@40853de9f8ce2d6cfdc73c1b96f14e22ba44aec4 # v45
|
||||
with:
|
||||
files: |
|
||||
dockerbuild/**
|
||||
|
||||
# This allows contributors to test changes to the dockerbuild image within a pull request
|
||||
- name: Build docker image
|
||||
uses: docker/build-push-action@2cdde995de11925a030ce8070c3d77a52ffcf1c0 # v5
|
||||
uses: docker/build-push-action@5cd11c3a4ced054e52742c5fd54dca954e0edd85 # v6
|
||||
if: steps.changed_files.outputs.any_modified == 'true'
|
||||
with:
|
||||
context: dockerbuild
|
||||
|
||||
8
.github/workflows/dockerbuild.yaml
vendored
8
.github/workflows/dockerbuild.yaml
vendored
@@ -20,15 +20,15 @@ jobs:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Set up QEMU
|
||||
uses: docker/setup-qemu-action@68827325e0b33c7199eb31dd4e31fbe9023e06e3 # v3
|
||||
uses: docker/setup-qemu-action@49b3bc8e6bdd4a60e6116a5414239cba5943d3cf # v3
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@d70bba72b1f3fd22344832f00baa16ece964efeb # v3
|
||||
uses: docker/setup-buildx-action@988b5a0280414f521da01fcc63a27aeeb4b104db # v3
|
||||
with:
|
||||
install: true
|
||||
|
||||
- name: Log in to the Container registry
|
||||
uses: docker/login-action@406e1d71198d2324043d77a06783c53195decb37
|
||||
uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567
|
||||
with:
|
||||
registry: ${{ env.REGISTRY }}
|
||||
username: ${{ github.actor }}
|
||||
@@ -43,7 +43,7 @@ jobs:
|
||||
type=ref,event=branch
|
||||
|
||||
- name: Build and push Docker image
|
||||
uses: docker/build-push-action@2cdde995de11925a030ce8070c3d77a52ffcf1c0 # v5
|
||||
uses: docker/build-push-action@5cd11c3a4ced054e52742c5fd54dca954e0edd85 # v6
|
||||
with:
|
||||
context: dockerbuild
|
||||
push: true
|
||||
|
||||
2
.github/workflows/release-drafter.yml
vendored
2
.github/workflows/release-drafter.yml
vendored
@@ -3,8 +3,6 @@ on:
|
||||
push:
|
||||
branches: [staging]
|
||||
workflow_dispatch: {}
|
||||
repository_dispatch:
|
||||
types: [upstream-release-notify]
|
||||
concurrency: ${{ github.workflow }}
|
||||
jobs:
|
||||
draft:
|
||||
|
||||
1
.github/workflows/release.yml
vendored
1
.github/workflows/release.yml
vendored
@@ -20,7 +20,6 @@ jobs:
|
||||
GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}
|
||||
with:
|
||||
final: ${{ inputs.mode == 'final' }}
|
||||
include-changes: element-hq/element-web@$VERSION
|
||||
gpg-fingerprint: ${{ vars.GPG_FINGERPRINT }}
|
||||
expected-asset-count: 1
|
||||
|
||||
|
||||
235
CHANGELOG.md
235
CHANGELOG.md
@@ -1,3 +1,238 @@
|
||||
Changes in [1.11.78](https://github.com/element-hq/element-desktop/releases/tag/v1.11.78) (2024-09-24)
|
||||
======================================================================================================
|
||||
* No changes
|
||||
|
||||
## ✨ Features
|
||||
|
||||
* Add Release announcement for the pinning message list ([#46](https://github.com/element-hq/matrix-react-sdk/pull/46)). Contributed by @florianduros.
|
||||
* Unlabs feature pinning ([#22](https://github.com/element-hq/matrix-react-sdk/pull/22)). Contributed by @florianduros.
|
||||
* Add mobile registration ([#42](https://github.com/element-hq/matrix-react-sdk/pull/42)). Contributed by @langleyd.
|
||||
* Add support for `org.matrix.cross_signing_reset` UIA stage flow ([#34](https://github.com/element-hq/matrix-react-sdk/pull/34)). Contributed by @t3chguy.
|
||||
* Add timezone to user profile ([#20](https://github.com/element-hq/matrix-react-sdk/pull/20)). Contributed by @Half-Shot.
|
||||
* Add config option to force verification ([#29](https://github.com/element-hq/matrix-react-sdk/pull/29)). Contributed by @dbkr.
|
||||
* Reduce pinned message banner size ([#28](https://github.com/element-hq/matrix-react-sdk/pull/28)). Contributed by @florianduros.
|
||||
* Enable message pinning labs by default ([#25](https://github.com/element-hq/matrix-react-sdk/pull/25)). Contributed by @florianduros.
|
||||
* Remove release announcement of the new header ([#23](https://github.com/element-hq/matrix-react-sdk/pull/23)). Contributed by @florianduros.
|
||||
|
||||
## 🐛 Bug Fixes
|
||||
|
||||
* Fix timeout type ([#40](https://github.com/element-hq/matrix-react-sdk/pull/40)). Contributed by @dbkr.
|
||||
* Fix huge usage bandwidth and performance issue of pinned message banner. ([#37](https://github.com/element-hq/matrix-react-sdk/pull/37)). Contributed by @florianduros.
|
||||
* Reverse order of pinned message list ([#19](https://github.com/element-hq/matrix-react-sdk/pull/19)). Contributed by @florianduros.
|
||||
|
||||
|
||||
|
||||
Changes in [1.11.77](https://github.com/element-hq/element-desktop/releases/tag/v1.11.77) (2024-09-10)
|
||||
======================================================================================================
|
||||
## Licensing
|
||||
|
||||
matrix-react-sdk is being forked by Element at https://github.com/element-hq/matrix-react-sdk. Contributions are licensed to Element under a CLA and made available under an AGPLv3.0 or GPLv3.0 license at your choice.
|
||||
|
||||
You can read more about this here:
|
||||
https://matrix.org/blog/2024/08/heart-of-matrix/
|
||||
https://element.io/blog/sustainable-licensing-at-element-with-agpl/
|
||||
|
||||
The Matrix.org Foundation copy of the project will be archived. We don't expect any changes are needed by system administrators. Any updates will be communicated via our usual announcements channels and we are striving to make this as seamless as possible.
|
||||
|
||||
## ✨ Features
|
||||
|
||||
* Add docs for widget container height option ([#27922](https://github.com/element-hq/element-web/pull/27922)). Contributed by @dbkr.
|
||||
* Allow user to set timezone ([#12775](https://github.com/matrix-org/matrix-react-sdk/pull/12775)). Contributed by @Timshel.
|
||||
* Implement download\_file in widget driver ([#12931](https://github.com/matrix-org/matrix-react-sdk/pull/12931)). Contributed by @weeman1337.
|
||||
* Sort the pinning message list in the same order than the banner. By timeline order. ([#12937](https://github.com/matrix-org/matrix-react-sdk/pull/12937)). Contributed by @florianduros.
|
||||
* Display pinned messages on a banner at the top of a room ([#12917](https://github.com/matrix-org/matrix-react-sdk/pull/12917)). Contributed by @florianduros.
|
||||
* Add a config option to control the default widget container height ([#12893](https://github.com/matrix-org/matrix-react-sdk/pull/12893)). Contributed by @dbkr.
|
||||
* RTE drafts ([#12674](https://github.com/matrix-org/matrix-react-sdk/pull/12674)). Contributed by @langleyd.
|
||||
* Add thread information in pinned message list ([#12902](https://github.com/matrix-org/matrix-react-sdk/pull/12902)). Contributed by @florianduros.
|
||||
* Add Pin/Unpin action in quick access of the message action bar ([#12897](https://github.com/matrix-org/matrix-react-sdk/pull/12897)). Contributed by @florianduros.
|
||||
|
||||
## 🐛 Bug Fixes
|
||||
|
||||
* Fix read receipt animation ([#12923](https://github.com/matrix-org/matrix-react-sdk/pull/12923)). Contributed by @dbkr.
|
||||
* Display the indicator even with one message in pinned message banner ([#12946](https://github.com/matrix-org/matrix-react-sdk/pull/12946)). Contributed by @florianduros.
|
||||
* Always display last pinned message on the banner ([#12945](https://github.com/matrix-org/matrix-react-sdk/pull/12945)). Contributed by @florianduros.
|
||||
* The pinned message banner or list are triggering 🎉 effect. ([#12944](https://github.com/matrix-org/matrix-react-sdk/pull/12944)). Contributed by @florianduros.
|
||||
* Fix reply message truncation on 2 lines ([#12929](https://github.com/matrix-org/matrix-react-sdk/pull/12929)). Contributed by @florianduros.
|
||||
* Fix pin/unpin slowness and non refresh from the message action bar ([#12934](https://github.com/matrix-org/matrix-react-sdk/pull/12934)). Contributed by @florianduros.
|
||||
* Ignore desktop for minimum browser support. ([#12928](https://github.com/matrix-org/matrix-react-sdk/pull/12928)). Contributed by @florianduros.
|
||||
|
||||
|
||||
|
||||
Changes in [1.11.76](https://github.com/element-hq/element-desktop/releases/tag/v1.11.76) (2024-08-27)
|
||||
======================================================================================================
|
||||
## ✨ Features
|
||||
|
||||
* Message Pinning: rework the message pinning list in the right panel ([#12825](https://github.com/matrix-org/matrix-react-sdk/pull/12825)). Contributed by @florianduros.
|
||||
* Tweak UIA postMessage check to work cross-origin ([#12878](https://github.com/matrix-org/matrix-react-sdk/pull/12878)). Contributed by @t3chguy.
|
||||
* Delayed events (Futures) / MSC4140 for call widget ([#12714](https://github.com/matrix-org/matrix-react-sdk/pull/12714)). Contributed by @AndrewFerr.
|
||||
* Stop the ongoing ring if another device joins the call session. ([#12866](https://github.com/matrix-org/matrix-react-sdk/pull/12866)). Contributed by @toger5.
|
||||
* Rich text Editor: Auto-replace plain text emoticons with emoji ([#12828](https://github.com/matrix-org/matrix-react-sdk/pull/12828)). Contributed by @langleyd.
|
||||
* Clean up editor drafts for unknown rooms ([#12850](https://github.com/matrix-org/matrix-react-sdk/pull/12850)). Contributed by @langleyd.
|
||||
* Rename general user settings to account ([#12841](https://github.com/matrix-org/matrix-react-sdk/pull/12841)). Contributed by @dbkr.
|
||||
* Update settings tab icons ([#12867](https://github.com/matrix-org/matrix-react-sdk/pull/12867)). Contributed by @dbkr.
|
||||
* Disable jump to read receipt button instead of hiding when nothing to jump to ([#12863](https://github.com/matrix-org/matrix-react-sdk/pull/12863)). Contributed by @t3chguy.
|
||||
|
||||
## 🐛 Bug Fixes
|
||||
|
||||
* Ensure elements on Login page are disabled when in-flight ([#12895](https://github.com/matrix-org/matrix-react-sdk/pull/12895)). Contributed by @t3chguy.
|
||||
* Hide pinned messages when grouped in timeline when feature pinning is disabled ([#12888](https://github.com/matrix-org/matrix-react-sdk/pull/12888)). Contributed by @florianduros.
|
||||
* Add chat button on new room header for maximised widgets ([#12882](https://github.com/matrix-org/matrix-react-sdk/pull/12882)). Contributed by @t3chguy.
|
||||
* Show spinner whilst initial search request is in progress ([#12883](https://github.com/matrix-org/matrix-react-sdk/pull/12883)). Contributed by @t3chguy.
|
||||
* Fix user menu font ([#12879](https://github.com/matrix-org/matrix-react-sdk/pull/12879)). Contributed by @florianduros.
|
||||
* Allow selecting text in the right panel topic ([#12870](https://github.com/matrix-org/matrix-react-sdk/pull/12870)). Contributed by @t3chguy.
|
||||
* Add missing presence indicator to new room header ([#12865](https://github.com/matrix-org/matrix-react-sdk/pull/12865)). Contributed by @t3chguy.
|
||||
* Fix permissions in release tarballs ([#27904](https://github.com/element-hq/element-web/pull/27904)). Contributed by @t3chguy.
|
||||
|
||||
## 🧰 Maintenance
|
||||
|
||||
* Update dependencies for MSC4157 ([#27906](https://github.com/element-hq/element-web/pull/27906)). Contributed by @AndrewFerr.
|
||||
|
||||
|
||||
Changes in [1.11.75](https://github.com/element-hq/element-desktop/releases/tag/v1.11.75) (2024-08-20)
|
||||
======================================================================================================
|
||||
# Security
|
||||
- Fixes for [CVE-2024-42369](https://nvd.nist.gov/vuln/detail/CVE-2024-42369) / [GHSA-vhr5-g3pm-49fm](https://github.com/matrix-org/matrix-js-sdk/security/advisories/GHSA-vhr5-g3pm-49fm).
|
||||
|
||||
Changes in [1.11.74](https://github.com/element-hq/element-desktop/releases/tag/v1.11.74) (2024-08-13)
|
||||
======================================================================================================
|
||||
## ✨ Features
|
||||
|
||||
* Update unsupported browser react component to new designs ([#27857](https://github.com/element-hq/element-web/pull/27857)). Contributed by @t3chguy.
|
||||
* Invite dialog: display MXID on its own line ([#11756](https://github.com/matrix-org/matrix-react-sdk/pull/11756)). Contributed by @AndrewFerr.
|
||||
* Align RoomSummaryCard styles with Figma ([#12793](https://github.com/matrix-org/matrix-react-sdk/pull/12793)). Contributed by @t3chguy.
|
||||
* Extract Extensions into their own right panel tab ([#12844](https://github.com/matrix-org/matrix-react-sdk/pull/12844)). Contributed by @t3chguy.
|
||||
* Remove topic from new room header and expand right panel topic ([#12842](https://github.com/matrix-org/matrix-react-sdk/pull/12842)). Contributed by @t3chguy.
|
||||
* Rework how the onboarding notifications task works ([#12839](https://github.com/matrix-org/matrix-react-sdk/pull/12839)). Contributed by @t3chguy.
|
||||
* Update toast styles to match Figma ([#12833](https://github.com/matrix-org/matrix-react-sdk/pull/12833)). Contributed by @t3chguy.
|
||||
* Warn users on unsupported browsers before they lack features ([#12830](https://github.com/matrix-org/matrix-react-sdk/pull/12830)). Contributed by @t3chguy.
|
||||
* Add sign out button to settings profile section ([#12666](https://github.com/matrix-org/matrix-react-sdk/pull/12666)). Contributed by @dbkr.
|
||||
* Remove MatrixRTC realted import ES lint exceptions using a index.ts for matrixrtc ([#12780](https://github.com/matrix-org/matrix-react-sdk/pull/12780)). Contributed by @toger5.
|
||||
* Fix unwanted ringing of other devices even though the user is already connected to the call. ([#12742](https://github.com/matrix-org/matrix-react-sdk/pull/12742)). Contributed by @toger5.
|
||||
* Acknowledge `DeviceMute` widget actions ([#12790](https://github.com/matrix-org/matrix-react-sdk/pull/12790)). Contributed by @toger5.
|
||||
|
||||
## 🐛 Bug Fixes
|
||||
|
||||
* Update Element icons ([#27900](https://github.com/element-hq/element-web/pull/27900)). Contributed by @t3chguy.
|
||||
* Fix Jitsi by updating device mute updates over postMessage API ([#27858](https://github.com/element-hq/element-web/pull/27858)). Contributed by @t3chguy.
|
||||
* Fix formatting of rich text emotes ([#12862](https://github.com/matrix-org/matrix-react-sdk/pull/12862)). Contributed by @dbkr.
|
||||
* Fixed custom emotes background color #27745 ([#12798](https://github.com/matrix-org/matrix-react-sdk/pull/12798)). Contributed by @asimdelvi.
|
||||
* Ignore permalink\_prefix when serializing pills ([#11726](https://github.com/matrix-org/matrix-react-sdk/pull/11726)). Contributed by @herkulessi.
|
||||
* Deflake the chat export test ([#12854](https://github.com/matrix-org/matrix-react-sdk/pull/12854)). Contributed by @dbkr.
|
||||
* Fix alignment of RTL messages ([#12837](https://github.com/matrix-org/matrix-react-sdk/pull/12837)). Contributed by @dbkr.
|
||||
* Handle media download errors better ([#12848](https://github.com/matrix-org/matrix-react-sdk/pull/12848)). Contributed by @t3chguy.
|
||||
* Make micIcon display on primary ([#11908](https://github.com/matrix-org/matrix-react-sdk/pull/11908)). Contributed by @kdanielm.
|
||||
* Fix compound typography font component issues ([#12826](https://github.com/matrix-org/matrix-react-sdk/pull/12826)). Contributed by @t3chguy.
|
||||
* Allow Chrome page translator to translate messages in rooms ([#11113](https://github.com/matrix-org/matrix-react-sdk/pull/11113)). Contributed by @lukaszpolowczyk.
|
||||
|
||||
|
||||
|
||||
Changes in [1.11.73](https://github.com/element-hq/element-desktop/releases/tag/v1.11.73) (2024-08-06)
|
||||
======================================================================================================
|
||||
Fixes for CVE-2024-42347 / GHSA-f83w-wqhc-cfp4
|
||||
|
||||
|
||||
|
||||
Changes in [1.11.72](https://github.com/element-hq/element-desktop/releases/tag/v1.11.72) (2024-07-30)
|
||||
======================================================================================================
|
||||
## ✨ Features
|
||||
|
||||
* Support authenticated media downloads in Desktop too ([#1757](https://github.com/element-hq/element-desktop/pull/1757)). Contributed by @turt2live.
|
||||
* Polyfill Intl.Segmenter for wider web browser compatibility ([#27803](https://github.com/element-hq/element-web/pull/27803)). Contributed by @dbkr.
|
||||
* Enable audio/webaudio Modernizr rule ([#27772](https://github.com/element-hq/element-web/pull/27772)). Contributed by @t3chguy.
|
||||
* Add release announcement for the new room header ([#12802](https://github.com/matrix-org/matrix-react-sdk/pull/12802)). Contributed by @MidhunSureshR.
|
||||
* Default the room header to on ([#12803](https://github.com/matrix-org/matrix-react-sdk/pull/12803)). Contributed by @MidhunSureshR.
|
||||
* Update Thread Panel to match latest designs ([#12797](https://github.com/matrix-org/matrix-react-sdk/pull/12797)). Contributed by @t3chguy.
|
||||
* Close any open modals on logout ([#12777](https://github.com/matrix-org/matrix-react-sdk/pull/12777)). Contributed by @dbkr.
|
||||
* Iterate design of right panel empty state ([#12796](https://github.com/matrix-org/matrix-react-sdk/pull/12796)). Contributed by @t3chguy.
|
||||
* Update styling of UserInfo right panel card ([#12788](https://github.com/matrix-org/matrix-react-sdk/pull/12788)). Contributed by @t3chguy.
|
||||
* Accessibility: Add Landmark navigation ([#12190](https://github.com/matrix-org/matrix-react-sdk/pull/12190)). Contributed by @akirk.
|
||||
* Let Element Call widget receive m.room.create ([#12710](https://github.com/matrix-org/matrix-react-sdk/pull/12710)). Contributed by @AndrewFerr.
|
||||
* Let Element Call widget set session memberships ([#12713](https://github.com/matrix-org/matrix-react-sdk/pull/12713)). Contributed by @AndrewFerr.
|
||||
* Update right panel base card styling to match Compound ([#12768](https://github.com/matrix-org/matrix-react-sdk/pull/12768)). Contributed by @t3chguy.
|
||||
* Align `widget_build_url_ignore_dm` with call behaviour switch between 1:1 and Widget ([#12760](https://github.com/matrix-org/matrix-react-sdk/pull/12760)). Contributed by @t3chguy.
|
||||
* Move integrations switch ([#12733](https://github.com/matrix-org/matrix-react-sdk/pull/12733)). Contributed by @dbkr.
|
||||
* Element-R: Report events with withheld keys separately to Posthog. ([#12755](https://github.com/matrix-org/matrix-react-sdk/pull/12755)). Contributed by @richvdh.
|
||||
|
||||
## 🐛 Bug Fixes
|
||||
|
||||
* Fix Docker tooling for building native components ([#1779](https://github.com/element-hq/element-desktop/pull/1779)). Contributed by @t3chguy.
|
||||
* Add a modernizr check for WebAssembly support ([#27776](https://github.com/element-hq/element-web/pull/27776)). Contributed by @dbkr.
|
||||
* Test for lack of WebAssembly support ([#12792](https://github.com/matrix-org/matrix-react-sdk/pull/12792)). Contributed by @dbkr.
|
||||
* Fix stray 'account' heading ([#12791](https://github.com/matrix-org/matrix-react-sdk/pull/12791)). Contributed by @dbkr.
|
||||
* Add test for the unsupported browser screen ([#12787](https://github.com/matrix-org/matrix-react-sdk/pull/12787)). Contributed by @dbkr.
|
||||
* Fix HTML export test ([#12778](https://github.com/matrix-org/matrix-react-sdk/pull/12778)). Contributed by @dbkr.
|
||||
* Fix HTML export missing a bunch of Compound variables ([#12774](https://github.com/matrix-org/matrix-react-sdk/pull/12774)). Contributed by @t3chguy.
|
||||
* Fix inability to change accent colour consistently in custom theming ([#12772](https://github.com/matrix-org/matrix-react-sdk/pull/12772)). Contributed by @t3chguy.
|
||||
* Fix edge case of landing on 3pid email link with registration disabled ([#12771](https://github.com/matrix-org/matrix-react-sdk/pull/12771)). Contributed by @t3chguy.
|
||||
|
||||
|
||||
|
||||
Changes in [1.11.71](https://github.com/element-hq/element-desktop/releases/tag/v1.11.71) (2024-07-16)
|
||||
======================================================================================================
|
||||
## ✨ Features
|
||||
|
||||
* Add Modernizr rule for Intl.Segmenter ([#27677](https://github.com/element-hq/element-web/pull/27677)). Contributed by @t3chguy.
|
||||
* Add tabs to the right panel ([#12672](https://github.com/matrix-org/matrix-react-sdk/pull/12672)). Contributed by @MidhunSureshR.
|
||||
* Promote new room header from labs to Beta ([#12739](https://github.com/matrix-org/matrix-react-sdk/pull/12739)). Contributed by @t3chguy.
|
||||
* Redesign room search interface ([#12677](https://github.com/matrix-org/matrix-react-sdk/pull/12677)). Contributed by @t3chguy.
|
||||
* Move language settings to 'preferences' ([#12723](https://github.com/matrix-org/matrix-react-sdk/pull/12723)). Contributed by @dbkr.
|
||||
* New layout selector ui in user settings ([#12676](https://github.com/matrix-org/matrix-react-sdk/pull/12676)). Contributed by @florianduros.
|
||||
* Prevent Element appearing in system media controls ([#10995](https://github.com/matrix-org/matrix-react-sdk/pull/10995)). Contributed by @SuperKenVery.
|
||||
* Move the account management button ([#12663](https://github.com/matrix-org/matrix-react-sdk/pull/12663)). Contributed by @dbkr.
|
||||
* Disable profile controls if the HS doesn't allow them to be set ([#12652](https://github.com/matrix-org/matrix-react-sdk/pull/12652)). Contributed by @dbkr.
|
||||
* New theme ui in user settings ([#12576](https://github.com/matrix-org/matrix-react-sdk/pull/12576)). Contributed by @florianduros.
|
||||
* Adjust room header hover transition from 300ms to 200ms ([#12703](https://github.com/matrix-org/matrix-react-sdk/pull/12703)). Contributed by @t3chguy.
|
||||
* Split out email \& phone number settings to separate components \& move discovery to privacy tab ([#12670](https://github.com/matrix-org/matrix-react-sdk/pull/12670)). Contributed by @dbkr.
|
||||
|
||||
## 🐛 Bug Fixes
|
||||
|
||||
* Ensure we do not load matrix-react-sdk is a manner which can white-screen ([#27685](https://github.com/element-hq/element-web/pull/27685)). Contributed by @t3chguy.
|
||||
* Fix incoming call toast crash due to audio refactor ([#12737](https://github.com/matrix-org/matrix-react-sdk/pull/12737)). Contributed by @t3chguy.
|
||||
* Improve new room header accessibility ([#12725](https://github.com/matrix-org/matrix-react-sdk/pull/12725)). Contributed by @t3chguy.
|
||||
* Fix closing all modals ([#12728](https://github.com/matrix-org/matrix-react-sdk/pull/12728)). Contributed by @dbkr.
|
||||
* Fix close button on forgot password flow ([#12732](https://github.com/matrix-org/matrix-react-sdk/pull/12732)). Contributed by @dbkr.
|
||||
* Don't consider textual characters to be emoji ([#12582](https://github.com/matrix-org/matrix-react-sdk/pull/12582)). Contributed by @robintown.
|
||||
* Clear autocomplete input on selection accept ([#12709](https://github.com/matrix-org/matrix-react-sdk/pull/12709)). Contributed by @dbkr.
|
||||
* Fix `Match system theme` toggle ([#12719](https://github.com/matrix-org/matrix-react-sdk/pull/12719)). Contributed by @florianduros.
|
||||
|
||||
|
||||
|
||||
Changes in [1.11.70](https://github.com/element-hq/element-desktop/releases/tag/v1.11.70) (2024-07-08)
|
||||
======================================================================================================
|
||||
## ✨ Features
|
||||
|
||||
* Tighten macOS entitlements ([#1731](https://github.com/element-hq/element-desktop/pull/1731)). Contributed by @t3chguy.
|
||||
* Add SSO redirect option for login page ([#27576](https://github.com/element-hq/element-web/pull/27576)). Contributed by @bartvdbraak.
|
||||
* Use stable endpoints for MSC3916 ([#27558](https://github.com/element-hq/element-web/pull/27558)). Contributed by @turt2live.
|
||||
* Switch to Rust crypto stack for all logins ([#12630](https://github.com/matrix-org/matrix-react-sdk/pull/12630)). Contributed by @richvdh.
|
||||
* Hide voip buttons in group rooms in environments with widgets disabled ([#12664](https://github.com/matrix-org/matrix-react-sdk/pull/12664)). Contributed by @t3chguy.
|
||||
* Minor tweaks to UserSettings dialog ([#12651](https://github.com/matrix-org/matrix-react-sdk/pull/12651)). Contributed by @florianduros.
|
||||
* Hide voice call button when redundant ([#12639](https://github.com/matrix-org/matrix-react-sdk/pull/12639)). Contributed by @t3chguy.
|
||||
* Improve accessibility of the room summary card ([#12586](https://github.com/matrix-org/matrix-react-sdk/pull/12586)). Contributed by @t3chguy.
|
||||
* Show tooltips on narrow tabbed views ([#12624](https://github.com/matrix-org/matrix-react-sdk/pull/12624)). Contributed by @dbkr.
|
||||
* Update gfm.css to github-markdown-css ([#12613](https://github.com/matrix-org/matrix-react-sdk/pull/12613)). Contributed by @t3chguy.
|
||||
* Cache e2eStatus to avoid concerning unencrypted flicker when changing rooms ([#12606](https://github.com/matrix-org/matrix-react-sdk/pull/12606)). Contributed by @t3chguy.
|
||||
* Tweak copy for user verification toast ([#12605](https://github.com/matrix-org/matrix-react-sdk/pull/12605)). Contributed by @t3chguy.
|
||||
* Support s tags for strikethrough for Matrix v1.10 ([#12604](https://github.com/matrix-org/matrix-react-sdk/pull/12604)). Contributed by @t3chguy.
|
||||
|
||||
## 🐛 Bug Fixes
|
||||
|
||||
* Switch debs to use the SQLCipher static version ([#1001](https://github.com/element-hq/element-desktop/pull/1001)). Contributed by @MatMaul.
|
||||
* Fix "Unable to restore session" error ([#4299](https://github.com/matrix-org/matrix-js-sdk/pull/4299)).
|
||||
* Fix error when sending encrypted messages in large rooms ([#4297](https://github.com/matrix-org/matrix-js-sdk/pull/4297)).
|
||||
* Remove redundant copy in deactive uia modal ([#12668](https://github.com/matrix-org/matrix-react-sdk/pull/12668)). Contributed by @t3chguy.
|
||||
* Fix high contrast theme in settings ([#12649](https://github.com/matrix-org/matrix-react-sdk/pull/12649)). Contributed by @florianduros.
|
||||
* Fix background on live location sharing footer ([#12629](https://github.com/matrix-org/matrix-react-sdk/pull/12629)). Contributed by @t3chguy.
|
||||
* Remove outdated iframe sandbox attribute ([#12633](https://github.com/matrix-org/matrix-react-sdk/pull/12633)). Contributed by @t3chguy.
|
||||
* Remove stray setState which caused encryption state shields to flicker ([#12632](https://github.com/matrix-org/matrix-react-sdk/pull/12632)). Contributed by @t3chguy.
|
||||
* Fix stray background colour on markdown body ([#12628](https://github.com/matrix-org/matrix-react-sdk/pull/12628)). Contributed by @t3chguy.
|
||||
* Fix widgets not being cleaned up correctly. ([#12616](https://github.com/matrix-org/matrix-react-sdk/pull/12616)). Contributed by @toger5.
|
||||
* Add in-progress view to display name EditInPlace ([#12609](https://github.com/matrix-org/matrix-react-sdk/pull/12609)). Contributed by @dbkr.
|
||||
* Fix config override of other settings levels ([#12593](https://github.com/matrix-org/matrix-react-sdk/pull/12593)). Contributed by @langleyd.
|
||||
* Don't show 'saved' on display name save error ([#12600](https://github.com/matrix-org/matrix-react-sdk/pull/12600)). Contributed by @dbkr.
|
||||
|
||||
|
||||
|
||||
Changes in [1.11.69](https://github.com/element-hq/element-desktop/releases/tag/v1.11.69) (2024-06-18)
|
||||
======================================================================================================
|
||||
## ✨ Features
|
||||
|
||||
@@ -9,11 +9,11 @@
|
||||
Latest electron-builder does, but it appears to be causing issues:
|
||||
(https://github.com/electron-userland/electron-builder/issues/4390)
|
||||
-->
|
||||
|
||||
<!-- https://github.com/electron/electron-notarize#prerequisites -->
|
||||
<key>com.apple.security.cs.allow-jit</key>
|
||||
<true/>
|
||||
<key>com.apple.security.cs.allow-unsigned-executable-memory</key>
|
||||
<true/>
|
||||
|
||||
<!-- https://github.com/electron-userland/electron-builder/issues/3940 -->
|
||||
<key>com.apple.security.cs.disable-library-validation</key>
|
||||
<true/>
|
||||
|
||||
@@ -4,8 +4,8 @@ FROM rust:buster
|
||||
ENV DEBIAN_FRONTEND noninteractive
|
||||
|
||||
RUN curl --proto "=https" -L https://yarnpkg.com/latest.tar.gz | tar xvz && mv yarn-* /yarn && ln -s /yarn/bin/yarn /usr/bin/yarn
|
||||
RUN apt-get -qq update && apt-get -qq dist-upgrade && \
|
||||
apt-get -qq install --no-install-recommends \
|
||||
RUN apt-get -qq update && apt-get -y -qq dist-upgrade && \
|
||||
apt-get -y -qq install --no-install-recommends \
|
||||
# tclsh is required for building SQLite as part of SQLCipher
|
||||
tcl \
|
||||
# libsecret-1-dev is required even for prebuild keytar
|
||||
@@ -18,7 +18,9 @@ RUN ln -s /usr/bin/python3 /usr/bin/python & ln -s /usr/bin/pip3 /usr/bin/pip
|
||||
ENV DEBUG_COLORS true
|
||||
ENV FORCE_COLOR true
|
||||
|
||||
ENV NODE_VERSION 18.19.0
|
||||
WORKDIR /project
|
||||
|
||||
ENV NODE_VERSION 20.15.1
|
||||
ARG TARGETOS
|
||||
ARG TARGETARCH
|
||||
COPY setup.sh /setup.sh
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
"uisi_autorageshake_app": "element-auto-uisi",
|
||||
"show_labs_settings": true,
|
||||
"room_directory": {
|
||||
"servers": ["matrix.org", "gitter.im", "libera.chat"]
|
||||
"servers": ["matrix.org", "gitter.im"]
|
||||
},
|
||||
"enable_presence_by_hs_url": {
|
||||
"https://matrix.org": false,
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
"bug_report_endpoint_url": "https://element.io/bugreports/submit",
|
||||
"uisi_autorageshake_app": "element-auto-uisi",
|
||||
"room_directory": {
|
||||
"servers": ["matrix.org", "gitter.im", "libera.chat"]
|
||||
"servers": ["matrix.org", "gitter.im"]
|
||||
},
|
||||
"show_labs_settings": false,
|
||||
"enable_presence_by_hs_url": {
|
||||
|
||||
@@ -2,10 +2,10 @@
|
||||
"compilerOptions": {
|
||||
"moduleResolution": "node",
|
||||
"esModuleInterop": true,
|
||||
"target": "es2016",
|
||||
"target": "es2022",
|
||||
"sourceMap": false,
|
||||
"strict": true,
|
||||
"lib": ["es2020"]
|
||||
"lib": ["es2022"]
|
||||
},
|
||||
"include": ["../scripts/@types/*.d.ts", "./**/*.ts"],
|
||||
"ts-node": {
|
||||
|
||||
28
package.json
28
package.json
@@ -2,7 +2,7 @@
|
||||
"name": "element-desktop",
|
||||
"productName": "Element",
|
||||
"main": "lib/electron-main.js",
|
||||
"version": "1.11.69",
|
||||
"version": "1.11.78",
|
||||
"description": "A feature-rich client for Matrix.org",
|
||||
"author": "Element",
|
||||
"homepage": "https://element.io",
|
||||
@@ -62,7 +62,7 @@
|
||||
"test:screenshots:run": "docker run --rm --network host -v $(pwd):/work/element-desktop -v /var/run/docker.sock:/var/run/docker.sock --platform linux/amd64 -it element-desktop-playwright"
|
||||
},
|
||||
"dependencies": {
|
||||
"@sentry/electron": "^4.3.0",
|
||||
"@sentry/electron": "^5.0.0",
|
||||
"auto-launch": "^5.0.5",
|
||||
"counterpart": "^0.18.6",
|
||||
"electron-clear-data": "^1.0.5",
|
||||
@@ -71,7 +71,7 @@
|
||||
"minimist": "^1.2.6",
|
||||
"node-fetch": "^2",
|
||||
"png-to-ico": "^2.1.1",
|
||||
"uuid": "^9.0.0"
|
||||
"uuid": "^10.0.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@action-validator/cli": "^0.6.0",
|
||||
@@ -82,22 +82,21 @@
|
||||
"@electron/asar": "^3.2.3",
|
||||
"@electron/fuses": "^1.7.0",
|
||||
"@mapbox/node-pre-gyp": "^1.0.11",
|
||||
"@playwright/test": "1.44.1",
|
||||
"@playwright/test": "1.46.1",
|
||||
"@types/auto-launch": "^5.0.1",
|
||||
"@types/counterpart": "^0.18.1",
|
||||
"@types/minimist": "^1.2.1",
|
||||
"@types/mkdirp": "^2.0.0",
|
||||
"@types/node": "18.19.31",
|
||||
"@types/node": "18.19.45",
|
||||
"@types/pacote": "^11.1.1",
|
||||
"@types/tar": "^6.1.3",
|
||||
"@types/uuid": "^9.0.2",
|
||||
"@types/uuid": "^10.0.0",
|
||||
"@types/yargs": "^17.0.32",
|
||||
"@typescript-eslint/eslint-plugin": "^7.0.0",
|
||||
"@typescript-eslint/parser": "^7.0.0",
|
||||
"app-builder-lib": "24.13.3",
|
||||
"chokidar": "^3.5.2",
|
||||
"detect-libc": "^2.0.0",
|
||||
"electron": "^30.0.0",
|
||||
"electron": "^31.0.0",
|
||||
"electron-builder": "24.13.3",
|
||||
"electron-builder-squirrel-windows": "24.13.3",
|
||||
"electron-devtools-installer": "^3.2.0",
|
||||
@@ -106,25 +105,24 @@
|
||||
"eslint-config-prettier": "^9.0.0",
|
||||
"eslint-plugin-import": "^2.25.4",
|
||||
"eslint-plugin-matrix-org": "^1.0.0",
|
||||
"eslint-plugin-unicorn": "^53.0.0",
|
||||
"find-npm-prefix": "^1.0.2",
|
||||
"glob": "^10.0.0",
|
||||
"eslint-plugin-unicorn": "^55.0.0",
|
||||
"glob": "^11.0.0",
|
||||
"knip": "^5.0.0",
|
||||
"matrix-web-i18n": "^3.2.1",
|
||||
"mkdirp": "^3.0.0",
|
||||
"pacote": "^18.0.0",
|
||||
"prettier": "^3.0.0",
|
||||
"rimraf": "^5.0.0",
|
||||
"rimraf": "^6.0.0",
|
||||
"tar": "^6.2.1",
|
||||
"ts-node": "^10.9.1",
|
||||
"typescript": "5.4.5"
|
||||
"typescript": "5.5.4"
|
||||
},
|
||||
"hakDependencies": {
|
||||
"matrix-seshat": "^3.0.1",
|
||||
"matrix-seshat": "^4.0.0",
|
||||
"keytar": "^7.9.0"
|
||||
},
|
||||
"resolutions": {
|
||||
"@types/node": "18.19.31",
|
||||
"@types/node": "18.19.45",
|
||||
"config-file-ts": "0.2.8-rc1"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -29,5 +29,5 @@ export default defineConfig({
|
||||
reporter: [["html", { outputFolder: "playwright/html-report" }]],
|
||||
snapshotDir: "playwright/snapshots",
|
||||
snapshotPathTemplate: "{snapshotDir}/{testFilePath}/{arg}-{platform}{ext}",
|
||||
timeout: 10 * 1000,
|
||||
timeout: 30 * 1000,
|
||||
});
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
FROM mcr.microsoft.com/playwright:v1.44.0-jammy
|
||||
FROM mcr.microsoft.com/playwright:v1.46.1-jammy
|
||||
|
||||
WORKDIR /work/element-desktop
|
||||
|
||||
RUN apt-get update && apt-get -y install xvfb
|
||||
RUN apt-get update && apt-get -y install xvfb && apt-get purge -y --auto-remove && rm -rf /var/lib/apt/lists/*
|
||||
|
||||
USER 1000:1000
|
||||
|
||||
|
||||
@@ -3,9 +3,9 @@
|
||||
"resolveJsonModule": true,
|
||||
"moduleResolution": "node",
|
||||
"esModuleInterop": true,
|
||||
"target": "es2017",
|
||||
"target": "es2022",
|
||||
"module": "es2022",
|
||||
"lib": ["ESNext", "es2021", "dom"]
|
||||
"lib": ["es2022", "dom"]
|
||||
},
|
||||
"include": ["**/*.ts"]
|
||||
}
|
||||
|
||||
19
scripts/@types/find-npm-prefix.d.ts
vendored
19
scripts/@types/find-npm-prefix.d.ts
vendored
@@ -1,19 +0,0 @@
|
||||
/*
|
||||
Copyright 2022 New Vector Ltd
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
declare module "find-npm-prefix" {
|
||||
export default function findPrefix(dir: string): Promise<string>;
|
||||
}
|
||||
@@ -114,7 +114,7 @@ async function main(): Promise<number | undefined> {
|
||||
return 1;
|
||||
}
|
||||
|
||||
await new Promise<boolean>((resolve) => {
|
||||
await new Promise<boolean>((resolve, reject) => {
|
||||
const gpgProc = childProcess.execFile("gpg", ["--import"], (error) => {
|
||||
if (error) {
|
||||
console.log("Failed to import key", error);
|
||||
@@ -123,9 +123,11 @@ async function main(): Promise<number | undefined> {
|
||||
}
|
||||
resolve(!error);
|
||||
});
|
||||
fetch(PUB_KEY_URL).then((resp) => {
|
||||
stream.pipeline(resp.body, gpgProc.stdin!);
|
||||
});
|
||||
fetch(PUB_KEY_URL)
|
||||
.then((resp) => {
|
||||
stream.pipeline(resp.body, gpgProc.stdin!).catch(reject);
|
||||
})
|
||||
.catch(reject);
|
||||
});
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -97,15 +97,16 @@ export default class HakEnv {
|
||||
}
|
||||
|
||||
public makeGypEnv(): Record<string, string | undefined> {
|
||||
return Object.assign({}, process.env, {
|
||||
return {
|
||||
...process.env,
|
||||
npm_config_arch: this.target.arch,
|
||||
npm_config_target_arch: this.target.arch,
|
||||
npm_config_disturl: "https://electronjs.org/headers",
|
||||
npm_config_runtime: this.runtime,
|
||||
npm_config_target: this.runtimeVersion,
|
||||
npm_config_build_from_source: true,
|
||||
npm_config_build_from_source: "true",
|
||||
npm_config_devdir: path.join(os.homedir(), ".electron-gyp"),
|
||||
});
|
||||
};
|
||||
}
|
||||
|
||||
public wantsStaticSqlCipher(): boolean {
|
||||
|
||||
@@ -15,7 +15,6 @@ limitations under the License.
|
||||
*/
|
||||
|
||||
import path from "path";
|
||||
import findNpmPrefix from "find-npm-prefix";
|
||||
|
||||
import HakEnv from "./hakEnv";
|
||||
import { TargetId } from "./target";
|
||||
@@ -37,7 +36,7 @@ const METACOMMANDS: Record<string, string[]> = {
|
||||
const HAKSCRIPTS = ["check", "fetch", "build"];
|
||||
|
||||
async function main(): Promise<void> {
|
||||
const prefix = await findNpmPrefix(process.cwd());
|
||||
const prefix = path.join(__dirname, "..", "..");
|
||||
let packageJson;
|
||||
try {
|
||||
packageJson = require(path.join(prefix, "package.json"));
|
||||
|
||||
6
src/@types/glob.d.ts
vendored
6
src/@types/glob.d.ts
vendored
@@ -1,6 +0,0 @@
|
||||
import { GlobOptions } from "glob";
|
||||
|
||||
declare module "glob" {
|
||||
// Workaround for @electron/asar importing IOptions instead of GlobOptions
|
||||
export type IOptions = GlobOptions;
|
||||
}
|
||||
@@ -42,6 +42,7 @@ import { _t, AppLocalization } from "./language-helper";
|
||||
import { setDisplayMediaCallback } from "./displayMediaCallback";
|
||||
import { setupMacosTitleBar } from "./macos-titlebar";
|
||||
import { loadJsonFile } from "./utils";
|
||||
import { setupMediaAuth } from "./media-auth";
|
||||
|
||||
const argv = minimist(process.argv, {
|
||||
alias: { help: "h" },
|
||||
@@ -176,7 +177,7 @@ async function loadConfig(): Promise<void> {
|
||||
global.vectorConfig = Object.assign(global.vectorConfig, localConfig);
|
||||
} catch (e) {
|
||||
if (e instanceof SyntaxError) {
|
||||
dialog.showMessageBox({
|
||||
void dialog.showMessageBox({
|
||||
type: "error",
|
||||
title: `Your ${global.vectorConfig.brand || "Element"} is misconfigured`,
|
||||
message:
|
||||
@@ -292,7 +293,7 @@ const warnBeforeExit = (event: Event, input: Input): void => {
|
||||
}
|
||||
};
|
||||
|
||||
configureSentry();
|
||||
void configureSentry();
|
||||
|
||||
// handle uncaught errors otherwise it displays
|
||||
// stack traces in popup dialogs, which is terrible (which
|
||||
@@ -442,7 +443,7 @@ app.on("ready", async () => {
|
||||
console.log('Auto update disabled via command line flag "--no-update"');
|
||||
} else if (global.vectorConfig["update_base_url"]) {
|
||||
console.log(`Starting auto update with base URL: ${global.vectorConfig["update_base_url"]}`);
|
||||
updater.start(global.vectorConfig["update_base_url"]);
|
||||
void updater.start(global.vectorConfig["update_base_url"]);
|
||||
} else {
|
||||
console.log("No update_base_url is defined: auto update is disabled");
|
||||
}
|
||||
@@ -477,7 +478,7 @@ app.on("ready", async () => {
|
||||
webgl: true,
|
||||
},
|
||||
});
|
||||
global.mainWindow.loadURL("vector://vector/webapp/");
|
||||
void global.mainWindow.loadURL("vector://vector/webapp/");
|
||||
|
||||
if (process.platform === "darwin") {
|
||||
setupMacosTitleBar(global.mainWindow);
|
||||
@@ -549,6 +550,8 @@ app.on("ready", async () => {
|
||||
global.mainWindow?.webContents.send("openDesktopCapturerSourcePicker");
|
||||
setDisplayMediaCallback(callback);
|
||||
});
|
||||
|
||||
setupMediaAuth(global.mainWindow);
|
||||
});
|
||||
|
||||
app.on("window-all-closed", () => {
|
||||
|
||||
@@ -217,11 +217,11 @@ ipcMain.on("ipcCall", async function (_ev: IpcMainEvent, payload) {
|
||||
label: r.initial,
|
||||
backgroundColor: defaultColors[total % defaultColors.length],
|
||||
click: (): void => {
|
||||
global.mainWindow?.loadURL(`vector://vector/webapp/#/room/${r.roomId}`);
|
||||
void global.mainWindow?.loadURL(`vector://vector/webapp/#/room/${r.roomId}`);
|
||||
},
|
||||
});
|
||||
if (r.avatarUrl) {
|
||||
fetch(r.avatarUrl)
|
||||
void fetch(r.avatarUrl)
|
||||
.then((resp) => {
|
||||
if (!resp.ok) return;
|
||||
return resp.arrayBuffer();
|
||||
|
||||
@@ -150,15 +150,15 @@ export function setupMacosTitleBar(window: BrowserWindow): void {
|
||||
|
||||
window.on("enter-full-screen", () => {
|
||||
if (cssKey !== undefined) {
|
||||
window.webContents.removeInsertedCSS(cssKey);
|
||||
void window.webContents.removeInsertedCSS(cssKey);
|
||||
}
|
||||
});
|
||||
window.on("leave-full-screen", () => {
|
||||
applyStyling();
|
||||
void applyStyling();
|
||||
});
|
||||
window.webContents.on("did-finish-load", () => {
|
||||
if (!window.isFullScreen()) {
|
||||
applyStyling();
|
||||
void applyStyling();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
80
src/media-auth.ts
Normal file
80
src/media-auth.ts
Normal file
@@ -0,0 +1,80 @@
|
||||
/*
|
||||
Copyright 2024 New Vector Ltd
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
import { BrowserWindow, ipcMain, session } from "electron";
|
||||
|
||||
/**
|
||||
* Check for feature support from the server.
|
||||
* This requires asking the renderer process for supported versions.
|
||||
*/
|
||||
async function getSupportedVersions(window: BrowserWindow): Promise<string[]> {
|
||||
return new Promise((resolve) => {
|
||||
ipcMain.once("serverSupportedVersions", (_, versionsResponse) => {
|
||||
resolve(versionsResponse?.versions || []);
|
||||
});
|
||||
window.webContents.send("serverSupportedVersions"); // ping now that the listener exists
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the access token for the user.
|
||||
* This requires asking the renderer process for the access token.
|
||||
*/
|
||||
async function getAccessToken(window: BrowserWindow): Promise<string | undefined> {
|
||||
return new Promise((resolve) => {
|
||||
ipcMain.once("userAccessToken", (_, accessToken) => {
|
||||
resolve(accessToken);
|
||||
});
|
||||
window.webContents.send("userAccessToken"); // ping now that the listener exists
|
||||
});
|
||||
}
|
||||
|
||||
export function setupMediaAuth(window: BrowserWindow): void {
|
||||
session.defaultSession.webRequest.onBeforeRequest(async (req, callback) => {
|
||||
// This handler emulates the element-web service worker, where URLs are rewritten late in the request
|
||||
// for backwards compatibility. As authenticated media becomes more prevalent, this should be replaced
|
||||
// by the app using authenticated URLs from the outset.
|
||||
let url = req.url;
|
||||
if (!url.includes("/_matrix/media/v3/download") && !url.includes("/_matrix/media/v3/thumbnail")) {
|
||||
return callback({}); // not a URL we care about
|
||||
}
|
||||
|
||||
const supportedVersions = await getSupportedVersions(window);
|
||||
// We have to check that the access token is truthy otherwise we'd be intercepting pre-login media request too,
|
||||
// e.g. those required for SSO button icons.
|
||||
const accessToken = await getAccessToken(window);
|
||||
if (supportedVersions.includes("v1.11") && accessToken) {
|
||||
url = url.replace(/\/media\/v3\/(.*)\//, "/client/v1/media/$1/");
|
||||
return callback({ redirectURL: url });
|
||||
} else {
|
||||
return callback({}); // no support == no modification
|
||||
}
|
||||
});
|
||||
|
||||
session.defaultSession.webRequest.onBeforeSendHeaders(async (req, callback) => {
|
||||
if (!req.url.includes("/_matrix/client/v1/media")) {
|
||||
return callback({}); // invoke unmodified
|
||||
}
|
||||
|
||||
// Only add authorization header to authenticated media URLs. This emulates the service worker
|
||||
// behaviour in element-web.
|
||||
const accessToken = await getAccessToken(window);
|
||||
// `accessToken` can be falsy, but if we're trying to download media without authentication
|
||||
// then we should expect failure anyway.
|
||||
const headers = { ...req.requestHeaders, Authorization: `Bearer ${accessToken}` };
|
||||
return callback({ requestHeaders: headers });
|
||||
});
|
||||
}
|
||||
@@ -35,6 +35,8 @@ const CHANNELS = [
|
||||
"userDownloadCompleted",
|
||||
"userDownloadAction",
|
||||
"openDesktopCapturerSourcePicker",
|
||||
"userAccessToken",
|
||||
"serverSupportedVersions",
|
||||
];
|
||||
|
||||
contextBridge.exposeInMainWorld("electron", {
|
||||
|
||||
@@ -50,7 +50,7 @@ function processUrl(url: string): void {
|
||||
urlToLoad.hash = parsed.hash;
|
||||
|
||||
console.log("Opening URL: ", urlToLoad.href);
|
||||
global.mainWindow.loadURL(urlToLoad.href);
|
||||
void global.mainWindow.loadURL(urlToLoad.href);
|
||||
}
|
||||
|
||||
function readStore(): Record<string, string> {
|
||||
|
||||
@@ -43,7 +43,7 @@ function checkSquirrelHooks(): boolean {
|
||||
|
||||
switch (cmd) {
|
||||
case "--squirrel-install":
|
||||
runUpdateExe(["--createShortcut=" + target]).then(() => app.quit());
|
||||
void runUpdateExe(["--createShortcut=" + target]).then(() => app.quit());
|
||||
return true;
|
||||
|
||||
case "--squirrel-updated":
|
||||
@@ -52,7 +52,7 @@ function checkSquirrelHooks(): boolean {
|
||||
return true;
|
||||
|
||||
case "--squirrel-uninstall":
|
||||
runUpdateExe(["--removeShortcut=" + target]).then(() => app.quit());
|
||||
void runUpdateExe(["--removeShortcut=" + target]).then(() => app.quit());
|
||||
return true;
|
||||
|
||||
default:
|
||||
|
||||
@@ -79,7 +79,7 @@ async function pollForUpdates(): Promise<void> {
|
||||
|
||||
export async function start(updateBaseUrl: string): Promise<void> {
|
||||
if (!(await available(updateBaseUrl))) return;
|
||||
if (updateBaseUrl.slice(-1) !== "/") {
|
||||
if (!updateBaseUrl.endsWith("/")) {
|
||||
updateBaseUrl = updateBaseUrl + "/";
|
||||
}
|
||||
|
||||
|
||||
@@ -140,7 +140,7 @@ export function buildMenuTemplate(): Menu {
|
||||
// XXX: vectorConfig won't have defaults applied to it so we need to duplicate them here
|
||||
label: _t("common|brand_help", { brand: global.vectorConfig?.brand || "Element" }),
|
||||
click(): void {
|
||||
shell.openExternal(global.vectorConfig?.help_url || "https://element.io/help");
|
||||
void shell.openExternal(global.vectorConfig?.help_url || "https://element.io/help");
|
||||
},
|
||||
},
|
||||
],
|
||||
|
||||
@@ -53,7 +53,7 @@ function safeOpenURL(target: string): void {
|
||||
// so we know the url parser has understood all the parts
|
||||
// of the input string
|
||||
const newTarget = url.format(parsedUrl);
|
||||
shell.openExternal(newTarget);
|
||||
void shell.openExternal(newTarget);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -169,7 +169,7 @@ function onLinkContextMenu(ev: Event, params: ContextMenuParams, webContents: We
|
||||
}
|
||||
} catch (err) {
|
||||
console.error(err);
|
||||
dialog.showMessageBox({
|
||||
void dialog.showMessageBox({
|
||||
type: "error",
|
||||
title: _t("right_click_menu|save_image_as_error_title"),
|
||||
message: _t("right_click_menu|save_image_as_error_description"),
|
||||
@@ -275,7 +275,7 @@ const userDownloadMap = new Map<number, string>(); // Map from id to path
|
||||
ipcMain.on("userDownloadAction", function (ev: IpcMainEvent, { id, open = false }) {
|
||||
const path = userDownloadMap.get(id);
|
||||
if (open && path) {
|
||||
shell.openPath(path);
|
||||
void shell.openPath(path);
|
||||
}
|
||||
userDownloadMap.delete(id);
|
||||
});
|
||||
|
||||
@@ -4,13 +4,13 @@
|
||||
"esModuleInterop": true,
|
||||
"module": "commonjs",
|
||||
"moduleResolution": "node",
|
||||
"target": "es2016",
|
||||
"target": "es2022",
|
||||
"sourceMap": false,
|
||||
"outDir": "./lib",
|
||||
"rootDir": "./src",
|
||||
"declaration": true,
|
||||
"typeRoots": ["src/@types", "node_modules/@types"],
|
||||
"lib": ["es2020", "dom"],
|
||||
"lib": ["es2022", "dom"],
|
||||
"types": ["node"],
|
||||
"strict": true
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user