Skip to content

Commit

Permalink
Merge branch 'develop' of github.com:vector-im/element-web into super…
Browse files Browse the repository at this point in the history
…kenvery/webaudioapi
  • Loading branch information
SuperKenVery committed Jun 26, 2023
2 parents 29c176b + bdbae36 commit 85dbaaa
Show file tree
Hide file tree
Showing 16 changed files with 597 additions and 304 deletions.
1 change: 1 addition & 0 deletions .github/cfp_headers
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
/*
! Access-Control-Allow-Origin
X-XSS-Protection: 1; mode=block
X-Content-Type-Options: nosniff
Strict-Transport-Security: max-age=31536000; includeSubDomains; preload
Expand Down
9 changes: 4 additions & 5 deletions .github/workflows/build_develop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -74,10 +74,9 @@ jobs:
run: |
{
echo "/develop.tar.gz $R2_PUBLIC_URL/develop.tar.gz 301"
RESULTS=$(aws s3api --region auto --endpoint-url $R2_URL list-objects-v2 --bucket $R2_BUCKET \
--query "sort_by(Contents[?ends_with(Key, '/bundle.css')], &LastModified)[-100:].Key"
--prefix "bundles/" | jq -r '.[]' | grep -oE '[^\"].*\/\s*')
for bundle in "$RESULTS"; do
aws s3api --region auto --endpoint-url $R2_URL list-objects-v2 --bucket $R2_BUCKET \
--query "sort_by(Contents[?ends_with(Key, '/bundle.css')], &LastModified)[-100:].Key" \
--prefix "bundles/" | jq -r '.[]' | grep -oE '[^\"].*\/\s*' | while read -r path ; do
echo "/${path}* $R2_PUBLIC_URL/${path}:splat 301"
done
} | tee _deploy/_redirects
Expand Down Expand Up @@ -107,7 +106,7 @@ jobs:

- name: Deploy to Cloudflare Pages
id: cfp
uses: cloudflare/pages-action@61eafe73baad0195ab582cb447b2c6e15a0df9ce # v1
uses: cloudflare/pages-action@f0a1cd58cd66095dee69bfa18fa5efd1dde93bca # v1
with:
apiToken: ${{ secrets.CF_PAGES_TOKEN }}
accountId: ${{ secrets.CF_PAGES_ACCOUNT_ID }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/dockerhub.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:

- name: Docker meta
id: meta
uses: docker/metadata-action@c4ee3adeed93b1fa6a762f209fb01608c1a22f1e # v4
uses: docker/metadata-action@818d4b7b91585d195f67373fd9cb0332e31a7175 # v4
with:
images: |
vectorim/element-web
Expand All @@ -44,7 +44,7 @@ jobs:
latest=${{ contains(github.ref_name, '-rc.') && 'false' || 'auto' }}
- name: Build and push
uses: docker/build-push-action@3b5e8027fcad23fda98b2e3ac259d8d67585f671 # v4
uses: docker/build-push-action@2eb1c1961a95fc15694676618e422e8ba1d63825 # v4
with:
context: .
push: true
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/pending-reviews.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ jobs:
await updateCounter("gh_reviews", URL, "warning", "Pending reviews", issueCount);
const { data } = await github.rest.search.issuesAndPullRequests({
q: `is:open ${repos.map(repo => `repo:${repo}`).join(" ")}`,
q: `is:open ${repos.map(repo => `repo:${repo}`).join(" ")} label:X-Release-Blocker`,
});
const blockerCount = data.total_count;
await updateCounter("release_blockers", "error", RELEASE_BLOCKERS_URL, "Release Blockers", blockerCount, true);
await updateCounter("release_blockers", RELEASE_BLOCKERS_URL, "alert", "Release Blockers", blockerCount, true);
2 changes: 1 addition & 1 deletion .github/workflows/static_analysis.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ jobs:

- name: Get diff lines
id: diff
uses: Equip-Collaboration/diff-line-numbers@df70b4b83e05105c15f20dc6cc61f1463411b2a6 # v1.0.0
uses: Equip-Collaboration/diff-line-numbers@e752977e2cb4207d671bb9e4dad18c07c1b73d52 # v1.1.0
with:
include: '["\\.tsx?$"]'

Expand Down
120 changes: 120 additions & 0 deletions CHANGELOG.md

Large diffs are not rendered by default.

5 changes: 4 additions & 1 deletion docs/config.md
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,8 @@ complete re-branding/private labeling, a more personalised experience can be ach
1. `title`: Required. Title to show at the top of the notice.
2. `description`: Required. The description to use for the notice.
3. `show_once`: Optional. If true then the notice will only be shown once per device.
18. `help_url`: The URL to point users to for help with the app, defaults to `https://element.io/help`.
19. `help_encrption_url`: The URL to point users to for help with encryption, defaults to `https://element.io/help#encryption`.

### `desktop_builds` and `mobile_builds`

Expand Down Expand Up @@ -320,7 +322,8 @@ The VoIP and Jitsi options are:
}
```
The `widget` is the `content` of a normal widget state event. The `layout` is the layout specifier for the widget being created,
as defined by the `io.element.widgets.layout` state event.
as defined by the `io.element.widgets.layout` state event. By default this applies to all rooms, but the behaviour can be skipped for DMs
by setting the option `widget_build_url_ignore_dm` to `true`.
5. `audio_stream_url`: Optional URL to pass to Jitsi to enable live streaming. This option is considered experimental and may be removed
at any time without notice.
6. `element_call`: Optional configuration for native group calls using Element Call, with the following subkeys:
Expand Down
9 changes: 0 additions & 9 deletions docs/labs.md
Original file line number Diff line number Diff line change
Expand Up @@ -105,11 +105,6 @@ For some sample themes, check out [aaronraimist/element-themes](https://github.c
Allows users to receive encrypted messages by creating a device that is stored
encrypted on the server, as described in [MSC2697](https://github.com/matrix-org/matrix-doc/pull/2697).

## Breadcrumbs v2 (`feature_breadcrumbs_v2`)

Instead of showing the horizontal list of breadcrumbs under the filter field, the new UX is an interactive context menu
triggered by the button to the right of the filter field.

## Spotlight search (`feature_spotlight`) [In Development]

Switches to a new room search experience.
Expand Down Expand Up @@ -168,10 +163,6 @@ Enables rendering of MD / HTML in room topics.
Enables exploring public spaces in the new search dialog. Requires the server to
have [MSC3827](https://github.com/matrix-org/matrix-spec-proposals/pull/3827) enabled.

## Favourite Messages (`feature_favourite_messages`) [In Development]

Enables users to bookmark a message or content for a later reference.

## Sign in another device by showing a QR code (`feature_qr_signin_reciprocate_show`)

Add capability to the session/device manager screens to generate a QR code to sign in another device + set up E2EE. This requires the homeserver to have support for [MSC3882](https://github.com/matrix-org/matrix-spec-proposals/pull/3882) and [MSC3886](https://github.com/matrix-org/matrix-spec-proposals/pull/3886) enabled.
Expand Down
2 changes: 1 addition & 1 deletion element.io/develop/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
"feature_video_rooms": true
},
"element_call": {
"url": "https://element-call.netlify.app"
"url": "https://element-call-livekit.netlify.app"
},
"map_style_url": "https://api.maptiler.com/maps/streets/style.json?key=fU3vlMsMn4Jb6dnEIFsx"
}
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "element-web",
"version": "1.11.31",
"version": "1.11.34",
"description": "A feature-rich client for Matrix.org",
"author": "New Vector Ltd.",
"repository": {
Expand Down Expand Up @@ -101,7 +101,7 @@
"@babel/runtime": "^7.12.5",
"@casualbot/jest-sonar-reporter": "^2.2.5",
"@principalstudio/html-webpack-inject-preload": "^1.2.7",
"@sentry/webpack-plugin": "^1.18.1",
"@sentry/webpack-plugin": "^2.0.0",
"@svgr/webpack": "^5.5.0",
"@testing-library/react": "^12.1.5",
"@types/jest": "^29.0.0",
Expand All @@ -123,7 +123,7 @@
"cpx": "^1.5.0",
"css-loader": "^4",
"dotenv": "^16.0.2",
"eslint": "8.40.0",
"eslint": "8.41.0",
"eslint-config-google": "^0.14.0",
"eslint-config-prettier": "^8.5.0",
"eslint-plugin-deprecate": "^0.7.0",
Expand All @@ -139,7 +139,7 @@
"fs-extra": "^11.0.0",
"html-webpack-plugin": "^4.5.2",
"jest": "^29.0.0",
"jest-canvas-mock": "2.4.0",
"jest-canvas-mock": "2.5.1",
"jest-environment-jsdom": "^29.0.0",
"jest-mock": "^29.0.0",
"jest-raw-loader": "^1.0.1",
Expand All @@ -166,7 +166,7 @@
"prettier": "2.8.8",
"raw-loader": "^4.0.2",
"rimraf": "^5.0.0",
"semver": "^7.3.7",
"semver": "^7.5.2",
"simple-proxy-agent": "^1.1.0",
"string-replace-loader": "3",
"style-loader": "2",
Expand Down
4 changes: 3 additions & 1 deletion src/i18n/strings/pt.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,7 @@
"%(brand)s uses advanced browser features which aren't supported by your current browser.": "%(brand)s utiliza funções avançadas que não são suportadas pelo teu atual browser.",
"Your browser can't run %(brand)s": "O teu browser não consegue executar %(brand)s",
"Use %(brand)s on mobile": "Usar %(brand)s no telemóvel",
"Decentralised, encrypted chat & collaboration powered by $matrixLogo": "Chat descentralizado e encriptado & colaboração alimentada por $matrixLogo"
"Decentralised, encrypted chat & collaboration powered by $matrixLogo": "Chat descentralizado e encriptado & colaboração alimentada por $matrixLogo",
"%(brand)s Desktop: %(platformName)s": "%(brand)s Desktop: %(platformName)s",
"%(appName)s: %(browserName)s on %(osName)s": "%(appName)s: %(browserName)s em %(osName)s"
}
4 changes: 2 additions & 2 deletions src/i18n/strings/vi.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@
"Unable to load config file: please refresh the page to try again.": "Không thể tải tệp cấu hình: hãy tải lại trang để thử lại.",
"Failed to start": "Không khởi động được",
"Use %(brand)s on mobile": "Sử dụng %(brand)s trên di động",
"Powered by Matrix": "Được chạy trên giao thức Matrix",
"Powered by Matrix": "Chạy trên giao thức Matrix",
"Your Element configuration contains invalid JSON. Please correct the problem and reload the page.": "Thiết lập Element của bạn đang chứa mã JSON không hợp lệ. Vui lòng sửa lại và tải lại trang.",
"Your Element is misconfigured": "Element đang bị thiết lập sai",
"Decentralised, encrypted chat & collaboration powered by $matrixLogo": "Dịch vụ nhắn tin & liên lạc được mã hóa, phi tập trung. Được cung cấp bởi $matrixLogo",
"Decentralised, encrypted chat & collaboration powered by $matrixLogo": "Dịch vụ nhắn tin & liên lạc được mã hóa, phi tập trung. Được vận hành trên $matrixLogo",
"%(appName)s: %(browserName)s on %(osName)s": "%(appName)s: %(browserName)s trên %(osName)s",
"%(brand)s Desktop: %(platformName)s": "%(brand)s máy tính: %(platformName)s"
}
3 changes: 2 additions & 1 deletion src/vector/app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,8 @@ export async function loadApp(fragParams: {}): Promise<ReactElement> {
const ssoRedirects = parseSsoRedirectOptions(config);
let autoRedirect = ssoRedirects.immediate === true;
// XXX: This path matching is a bit brittle, but better to do it early instead of in the app code.
const isWelcomeOrLanding = window.location.hash === "#/welcome" || window.location.hash === "#";
const isWelcomeOrLanding =
window.location.hash === "#/welcome" || window.location.hash === "#" || window.location.hash === "";
if (!autoRedirect && ssoRedirects.on_welcome_page && isWelcomeOrLanding) {
autoRedirect = true;
}
Expand Down
2 changes: 1 addition & 1 deletion src/vector/platform/WebPlatform.ts
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ export default class WebPlatform extends VectorBasePlatform {
logger.error("Failed to poll for update", err);
return {
status: UpdateCheckStatus.Error,
detail: err.message || err.status ? err.status.toString() : "Unknown Error",
detail: err.message || (err.status ? err.status.toString() : "Unknown Error"),
};
},
);
Expand Down
8 changes: 5 additions & 3 deletions webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const MiniCssExtractPlugin = require("mini-css-extract-plugin");
const TerserPlugin = require("terser-webpack-plugin");
const OptimizeCSSAssetsPlugin = require("optimize-css-assets-webpack-plugin");
const HtmlWebpackInjectPreload = require("@principalstudio/html-webpack-inject-preload");
const SentryCliPlugin = require("@sentry/webpack-plugin");
const { sentryWebpackPlugin } = require("@sentry/webpack-plugin");
const crypto = require("crypto");

// XXX: mangle Crypto::createHash to replace md4 with sha256, output.hashFunction is insufficient as multiple bits
Expand Down Expand Up @@ -660,9 +660,11 @@ module.exports = (env, argv) => {

// upload to sentry if sentry env is present
process.env.SENTRY_DSN &&
new SentryCliPlugin({
sentryWebpackPlugin({
release: process.env.VERSION,
include: "./webapp/bundles",
sourcemaps: {
paths: "./webapp/bundles/**",
},
errorHandler: (err, invokeErr, compilation) => {
compilation.warnings.push("Sentry CLI Plugin: " + err.message);
console.log(`::warning title=Sentry error::${err.message}`);
Expand Down
Loading

0 comments on commit 85dbaaa

Please sign in to comment.