Merge branch 'develop' into fix/space-shortcut-local/17776

This commit is contained in:
Michael Telatynski 2021-07-15 13:53:06 +01:00 committed by GitHub
commit 43695fbc58
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
55 changed files with 465 additions and 1049 deletions

View file

@ -1,23 +1,30 @@
module.exports = {
"extends": ["matrix-org", "matrix-org/react"],
"env": {
"browser": true,
"node": true,
plugins: ["matrix-org"],
extends: [
"plugin:matrix-org/babel",
"plugin:matrix-org/react",
],
env: {
browser: true,
node: true,
},
"rules": {
rules: {
// Things we do that break the ideal style
"quotes": "off",
},
"overrides": [{
"files": ["src/**/*.{ts,tsx}"],
"extends": ["matrix-org/ts", "matrix-org/react"],
"env": {
"browser": true,
},
"rules": {
"quotes": "off",
// While converting to ts we allow this
"@typescript-eslint/no-explicit-any": "off",
overrides: [{
files: ["src/**/*.{ts,tsx}"],
extends: [
"plugin:matrix-org/typescript",
"plugin:matrix-org/react",
],
rules: {
// Things we do that break the ideal style
"prefer-promise-reject-errors": "off",
"quotes": "off",
// We disable this while we're transitioning
"@typescript-eslint/no-explicit-any": "off",
},
}],
};

View file

@ -12,11 +12,11 @@ that aren't relevant to your particular case.
Text between <!-- and --> marks will be invisible in the report.
-->
### Description
#### Description
Describe here the problem that you are experiencing, or the feature you are requesting.
### Steps to reproduce
#### Steps to reproduce
- For bugs, list the steps
- that reproduce the bug
@ -30,7 +30,7 @@ file a bug here too! -->
<!-- Include screenshots if possible: you can drag and drop images below. -->
### Version information
#### Version information
<!-- IMPORTANT: please answer the following questions, to help us narrow down the problem -->

View file

@ -21,11 +21,11 @@ that aren't relevant to your particular case.
Text between <!-- and --> marks will be invisible in the report.
-->
### Description
#### Description
Describe here the problem that you are experiencing, or the feature you are requesting.
### Steps to reproduce
#### Steps to reproduce
- For bugs, list the steps
- that reproduce the bug
@ -40,7 +40,7 @@ Logs being sent: yes/no
<!-- Include screenshots if possible: you can drag and drop images below. -->
### Version information
#### Version information
<!-- IMPORTANT: please answer the following questions, to help us narrow down the problem -->

View file

@ -1,3 +1,3 @@
<!-- Please read CONTRIBUTING.md before submitting your pull request -->
<!-- Please read https://github.com/matrix-org/matrix-js-sdk/blob/develop/CONTRIBUTING.md before submitting your pull request -->
<!-- Include a Sign-Off at the end of your Pull Request (as described in CONTRIBUTING.md), or on every commit -->
<!-- Include a Sign-Off as described in https://github.com/matrix-org/matrix-js-sdk/blob/develop/CONTRIBUTING.md#sign-off -->

2
.gitignore vendored
View file

@ -19,3 +19,5 @@ electron/pub
/src/component-index.js
/.tmp
/webpack-stats.json
.vscode
.vscode/

View file

@ -1,9 +1,6 @@
{
"minify": true,
"classPrefix": "modernizr_",
"options": [
"setClasses"
],
"enableClasses": false,
"feature-detects": [
"test/css/animations",
"test/css/displaytable",

View file

@ -1,3 +1,37 @@
Changes in [1.7.32](https://github.com/vector-im/element-web/releases/tag/v1.7.32) (2021-07-05)
===============================================================================================
[Full Changelog](https://github.com/vector-im/element-web/compare/v1.7.32-rc.1...v1.7.32)
* No changes from rc.1
Changes in [1.7.32-rc.1](https://github.com/vector-im/element-web/releases/tag/v1.7.32-rc.1) (2021-06-29)
=========================================================================================================
[Full Changelog](https://github.com/vector-im/element-web/compare/v1.7.31...v1.7.32-rc.1)
* Update to react-sdk v3.25.0-rc.1 and js-sdk v12.0.1-rc.1
* Translations update from Weblate
[\#17832](https://github.com/vector-im/element-web/pull/17832)
* Fix canvas-filter-polyfill mock path
[\#17785](https://github.com/vector-im/element-web/pull/17785)
* Mock context-filter-polyfill for app-tests
[\#17774](https://github.com/vector-im/element-web/pull/17774)
* Add libera.chat to default room directory
[\#17772](https://github.com/vector-im/element-web/pull/17772)
* Improve typing of Event Index Manager / Seshat
[\#17704](https://github.com/vector-im/element-web/pull/17704)
* Bump dns-packet from 1.3.1 to 1.3.4
[\#17478](https://github.com/vector-im/element-web/pull/17478)
* Update matrix-widget-api to fix build issues
[\#17747](https://github.com/vector-im/element-web/pull/17747)
* Fix whitespace in Dockerfile
[\#17742](https://github.com/vector-im/element-web/pull/17742)
* Upgrade @types/react and @types/react-dom
[\#17723](https://github.com/vector-im/element-web/pull/17723)
* Spaces keyboard shortcuts first cut
[\#17457](https://github.com/vector-im/element-web/pull/17457)
* Labs: feature_report_to_moderators
[\#17694](https://github.com/vector-im/element-web/pull/17694)
Changes in [1.7.31](https://github.com/vector-im/element-web/releases/tag/v1.7.31) (2021-06-21)
===============================================================================================
[Full Changelog](https://github.com/vector-im/element-web/compare/v1.7.31-rc.1...v1.7.31)

View file

@ -9,10 +9,7 @@ ARG REACT_SDK_BRANCH="master"
ARG JS_SDK_REPO="https://github.com/matrix-org/matrix-js-sdk.git"
ARG JS_SDK_BRANCH="master"
RUN apt-get update && apt-get install -y git dos2unix \
# These packages are required for building Canvas on architectures like Arm
# See https://www.npmjs.com/package/canvas#compiling
build-essential libcairo2-dev libpango1.0-dev libjpeg-dev libgif-dev librsvg2-dev
RUN apt-get update && apt-get install -y git dos2unix
WORKDIR /src

View file

@ -298,6 +298,7 @@ cd element-web
yarn link matrix-js-sdk
yarn link matrix-react-sdk
yarn install
yarn reskindex
yarn start
```

View file

@ -10,7 +10,6 @@ module.exports = {
],
}],
"@babel/preset-typescript",
"@babel/preset-flow",
"@babel/preset-react",
],
"plugins": [
@ -21,7 +20,6 @@ module.exports = {
"@babel/plugin-proposal-object-rest-spread",
"@babel/plugin-proposal-optional-chaining",
"@babel/plugin-proposal-nullish-coalescing-operator",
"@babel/plugin-transform-flow-comments",
"@babel/plugin-syntax-dynamic-import",
"@babel/plugin-transform-runtime",
],

View file

@ -1,6 +1,6 @@
{
"name": "element-web",
"version": "1.7.31",
"version": "1.7.32",
"description": "A feature-rich client for Matrix.org",
"author": "New Vector Ltd.",
"repository": {
@ -58,7 +58,7 @@
"browser-request": "^0.3.3",
"gfm.css": "^1.1.2",
"highlight.js": "^10.5.0",
"jsrsasign": "^10.1.5",
"jsrsasign": "^10.2.0",
"katex": "^0.12.0",
"matrix-js-sdk": "github:matrix-org/matrix-js-sdk#develop",
"matrix-react-sdk": "github:matrix-org/matrix-react-sdk#develop",
@ -71,6 +71,8 @@
},
"devDependencies": {
"@babel/core": "^7.12.10",
"@babel/eslint-parser": "^7.12.10",
"@babel/eslint-plugin": "^7.12.10",
"@babel/plugin-proposal-class-properties": "^7.12.1",
"@babel/plugin-proposal-decorators": "^7.12.12",
"@babel/plugin-proposal-export-default-from": "^7.12.1",
@ -79,10 +81,8 @@
"@babel/plugin-proposal-object-rest-spread": "^7.12.1",
"@babel/plugin-proposal-optional-chaining": "^7.12.7",
"@babel/plugin-syntax-dynamic-import": "^7.8.3",
"@babel/plugin-transform-flow-comments": "^7.12.1",
"@babel/plugin-transform-runtime": "^7.12.10",
"@babel/preset-env": "^7.12.11",
"@babel/preset-flow": "^7.12.1",
"@babel/preset-react": "^7.12.10",
"@babel/preset-typescript": "^7.12.7",
"@babel/register": "^7.12.10",
@ -94,19 +94,18 @@
"@types/react": "^17.0.2",
"@types/react-dom": "^17.0.2",
"@types/sanitize-html": "^2.3.1",
"@typescript-eslint/eslint-plugin": "^4.17.0",
"@typescript-eslint/parser": "^4.17.0",
"autoprefixer": "^9.8.6",
"babel-eslint": "^10.1.0",
"babel-jest": "^26.6.3",
"babel-loader": "^8.2.2",
"canvas": "^2.6.1",
"chokidar": "^3.5.1",
"concurrently": "^5.3.0",
"cpx": "^1.5.0",
"css-loader": "^3.6.0",
"eslint": "7.18.0",
"eslint-config-matrix-org": "^0.2.0",
"eslint-plugin-babel": "^5.3.1",
"eslint-plugin-flowtype": "^5.2.0",
"eslint-config-google": "^0.14.0",
"eslint-plugin-matrix-org": "github:matrix-org/eslint-plugin-matrix-org#main",
"eslint-plugin-react": "^7.22.0",
"eslint-plugin-react-hooks": "^4.2.0",
"extract-text-webpack-plugin": "^4.0.0-beta.0",
@ -124,10 +123,9 @@
"mini-css-extract-plugin": "^0.12.0",
"minimist": "^1.2.5",
"mkdirp": "^1.0.4",
"modernizr": "^3.11.4",
"modernizr": "^3.11.7",
"node-fetch": "^2.6.1",
"optimize-css-assets-webpack-plugin": "^5.0.4",
"postcss-calc": "^7.0.5",
"postcss-easings": "^2.0.0",
"postcss-extend": "^1.0.5",
"postcss-hexrgba": "^2.0.1",
@ -143,11 +141,14 @@
"shell-escape": "^0.2.0",
"simple-proxy-agent": "^1.1.0",
"stylelint": "^13.9.0",
"stylelint-config-standard": "^20.0.0",
"stylelint-scss": "^3.18.0",
"terser-webpack-plugin": "^2.3.8",
"typescript": "^4.1.3",
"webpack": "^4.46.0",
"webpack-cli": "^3.3.12",
"webpack-dev-server": "^3.11.2"
"webpack-dev-server": "^3.11.2",
"worker-loader": "^2.0.0"
},
"jest": {
"testEnvironment": "jest-environment-jsdom-sixteen",
@ -168,7 +169,10 @@
"^matrix-react-sdk$": "<rootDir>/node_modules/matrix-react-sdk/src",
"decoderWorker\\.min\\.js": "<rootDir>/node_modules/matrix-react-sdk/__mocks__/empty.js",
"decoderWorker\\.min\\.wasm": "<rootDir>/node_modules/matrix-react-sdk/__mocks__/empty.js",
"waveWorker\\.min\\.js": "<rootDir>/node_modules/matrix-react-sdk/__mocks__/empty.js"
"waveWorker\\.min\\.js": "<rootDir>/node_modules/matrix-react-sdk/__mocks__/empty.js",
"context-filter-polyfill": "<rootDir>/node_modules/matrix-react-sdk/__mocks__/empty.js",
"FontManager.ts": "<rootDir>/node_modules/matrix-react-sdk/__mocks__/FontManager.js",
"workers/(.+)\\.worker\\.ts": "<rootDir>/node_modules/matrix-react-sdk/__mocks__/workerMock.js"
},
"transformIgnorePatterns": [
"/node_modules/(?!matrix-js-sdk).+$",

View file

@ -76,7 +76,7 @@ dodep matrix-org matrix-js-sdk
pushd matrix-js-sdk
yarn link
yarn install
yarn install --pure-lockfile
popd
yarn link matrix-js-sdk
@ -90,7 +90,7 @@ dodep matrix-org matrix-react-sdk
pushd matrix-react-sdk
yarn link
yarn link matrix-js-sdk
yarn install
yarn install --pure-lockfile
yarn reskindex
popd

View file

@ -15,7 +15,7 @@ limitations under the License.
*/
import "matrix-react-sdk/src/@types/global"; // load matrix-react-sdk's type extensions first
import type {Renderer} from "react-dom";
import type { Renderer } from "react-dom";
type ElectronChannel =
"app_onAction" |

View file

@ -27,7 +27,7 @@ interface IProps {
}
const CompatibilityView: React.FC<IProps> = ({ onAccept }) => {
const {brand, mobileBuilds} = SdkConfig.get();
const { brand, mobileBuilds } = SdkConfig.get();
let ios = null;
const iosCustomUrl = mobileBuilds?.ios;
@ -71,7 +71,7 @@ const CompatibilityView: React.FC<IProps> = ({ onAccept }) => {
android = [];
}
let mobileHeader = <h2 id="step2_heading">{_t("Use %(brand)s on mobile", {brand})}</h2>;
let mobileHeader = <h2 id="step2_heading">{_t("Use %(brand)s on mobile", { brand })}</h2>;
if (!android.length && !ios) {
mobileHeader = null;
}

View file

@ -27,7 +27,7 @@ interface IProps {
messages?: string[];
}
const ErrorView: React.FC<IProps> = ({title, messages}) => {
const ErrorView: React.FC<IProps> = ({ title, messages }) => {
return <div className="mx_ErrorView">
<div className="mx_ErrorView_container">
<div className="mx_HomePage_header">

View file

@ -22,9 +22,9 @@ import { _t } from 'matrix-react-sdk/src/languageHandler';
const VectorAuthFooter = () => {
const brandingConfig = SdkConfig.get().branding;
let links = [
{"text": "Blog", "url": "https://element.io/blog"},
{"text": "Twitter", "url": "https://twitter.com/element_hq"},
{"text": "GitHub", "url": "https://github.com/vector-im/element-web"},
{ "text": "Blog", "url": "https://element.io/blog" },
{ "text": "Twitter", "url": "https://twitter.com/element_hq" },
{ "text": "GitHub", "url": "https://github.com/vector-im/element-web" },
];
if (brandingConfig && brandingConfig.authFooterLinks) {

View file

@ -19,7 +19,7 @@ import React from 'react';
import SdkConfig from 'matrix-react-sdk/src/SdkConfig';
export default class VectorAuthHeaderLogo extends React.PureComponent {
static replaces = 'AuthHeaderLogo'
static replaces = 'AuthHeaderLogo';
render() {
const brandingConfig = SdkConfig.get().branding;

View file

@ -19,7 +19,7 @@ import * as sdk from 'matrix-react-sdk/src/index';
import SdkConfig from 'matrix-react-sdk/src/SdkConfig';
export default class VectorAuthPage extends React.PureComponent {
static replaces = 'AuthPage'
static replaces = 'AuthPage';
static welcomeBackgroundUrl;

View file

@ -57,7 +57,7 @@ export default class Favicon {
private readyCb = () => {};
constructor(params: Partial<IParams> = {}) {
this.params = {...defaults, ...params};
this.params = { ...defaults, ...params };
this.icons = Favicon.getIcons();
// create work canvas
@ -125,7 +125,7 @@ export default class Favicon {
}
private circle(n: number | string, opts?: Partial<IParams>) {
const params = {...this.params, ...opts};
const params = { ...this.params, ...opts };
const opt = this.options(n, params);
let more = false;
@ -214,7 +214,7 @@ export default class Favicon {
if (!this.isReady) {
this.readyCb = () => {
this.badge(content, opts);
}
};
return;
}

View file

@ -33,5 +33,6 @@
"Powered by Matrix": "Běží na Matrixu",
"%(brand)s Desktop (%(platformName)s)": "%(brand)s pro desktopový počítač (%(platformName)s)",
"Missing indexeddb worker script!": "Nenačetl se skript spravující indexdb!",
"Use %(brand)s on mobile": "Používání %(brand)s v mobilních zařízeních"
"Use %(brand)s on mobile": "Používání %(brand)s v mobilních zařízeních",
"Switch to space by number": "Přepnout na prostor podle čísla"
}

View file

@ -33,5 +33,6 @@
"%(brand)s uses advanced browser features which aren't supported by your current browser.": "%(brand)s verwendet erweiterte Browserfunktionen, die von deinem Browser nicht unterstützt werden.",
"Your browser can't run %(brand)s": "Dein Browser kann %(brand)s nicht ausführen",
"Powered by Matrix": "Betrieben mit Matrix",
"Use %(brand)s on mobile": "Verwende %(brand)s auf dem Handy"
"Use %(brand)s on mobile": "Verwende %(brand)s am Handy",
"Switch to space by number": "Zum n-ten Space wechseln"
}

View file

@ -1,5 +1,4 @@
{
"Missing indexeddb worker script!": "Missing indexeddb worker script!",
"Invalid configuration: can only specify one of default_server_config, default_server_name, or default_hs_url.": "Invalid configuration: can only specify one of default_server_config, default_server_name, or default_hs_url.",
"Invalid configuration: no default server specified.": "Invalid configuration: no default server specified.",
"Your Element is misconfigured": "Your Element is misconfigured",

View file

@ -33,5 +33,6 @@
"Your browser can't run %(brand)s": "Tu navegador no es compatible con %(brand)s",
"%(brand)s uses advanced browser features which aren't supported by your current browser.": "%(brand)s usa funciones avanzadas que su navegador actual no soporta.",
"Powered by Matrix": "Funciona con Matrix",
"Use %(brand)s on mobile": "Usar %(brand)s en modo móvil"
"Use %(brand)s on mobile": "Usar %(brand)s en modo móvil",
"Switch to space by number": "Cambiar a espacio por número"
}

View file

@ -33,5 +33,6 @@
"Your browser can't run %(brand)s": "%(brand)s ei toimi sinu brauseris",
"%(brand)s uses advanced browser features which aren't supported by your current browser.": "%(brand)s kasutab mitmeid uusi brauseri-põhiseid tehnoloogiaid, mis ei ole veel sinu veebibrauseris toetatud.",
"Powered by Matrix": "Põhineb Matrix'il",
"Use %(brand)s on mobile": "Kasuta %(brand)s rakendust nutiseadmes"
"Use %(brand)s on mobile": "Kasuta %(brand)s rakendust nutiseadmes",
"Switch to space by number": "Vaata kogukonnakeskust tema numbri alusel"
}

View file

@ -33,5 +33,6 @@
"Your browser can't run %(brand)s": "O teu navegador non pode executar %(brand)s",
"%(brand)s uses advanced browser features which aren't supported by your current browser.": "%(brand)s utiliza características avanzadas do navegador que non están dispoñibles no teu navegador.",
"Powered by Matrix": "Funciona grazas a Matrix",
"Use %(brand)s on mobile": "Utiliza %(brand)s no móbil"
"Use %(brand)s on mobile": "Utiliza %(brand)s no móbil",
"Switch to space by number": "Cambiar a espazo polo número"
}

View file

@ -4,9 +4,9 @@
"Unknown device": "מכשיר לא ידוע",
"You need to be using HTTPS to place a screen-sharing call.": "עליך להשתמש ב HTTPS בכדי לבצע שיחת ווידאו משותפת.",
"Welcome to Element": "ברוכים הבאים ל Element",
"Decentralised, encrypted chat &amp; collaboration powered by [matrix]": 'ט מוצפן &amp; ושת\"פ נעשה ע\"י ה [matrix]",
"Decentralised, encrypted chat &amp; collaboration powered by [matrix]": א'ט וכלי שיתוף פעולה מבוזר ומוצפן &amp; מופעל ע\"י [matrix]",
"Invalid JSON": "JSON לא חוקי",
"Invalid configuration: can only specify one of default_server_config, default_server_name, or default_hs_url.": "תצורה שגויה: ניתן לציין רק אחד מהבאים, default_server_config, default_server_name, או default_hs_url.",
"Invalid configuration: can only specify one of default_server_config, default_server_name, or default_hs_url.": "תצורה שגויה: ניתן לציין רק אחד מהערכים הבאים, default_server_config, default_server_name, או default_hs_url.",
"Invalid configuration: no default server specified.": "תצורה שגויה: לא צוין שרת ברירת מחדל.",
"Open user settings": "פתח הגדרות משתמש",
"Go to your browser to complete Sign In": "עבור לדפדפן להמשך ההתחברות",
@ -17,7 +17,7 @@
"Open": "פתח",
"Download Completed": "ההורדה הושלמה",
"Unexpected error preparing the app. See console for details.": "שגיאה לא צפויה במהלך הכנת האפליקציה. ראו קונסול לפרטים נוספים.",
"Unable to load config file: please refresh the page to try again.": "לא יכול לקרוא את קובץ ההגדרות: אנא אתחלו את הדף לנסות שנית.",
"Unable to load config file: please refresh the page to try again.": "לא יכול לטעון את קובץ ההגדרות: יש לרענן את הדף כדי לנסות שנית.",
"Your Element configuration contains invalid JSON. Please correct the problem and reload the page.": "האלמנט מכיל הגדרת JSON שגויה, אנא תקנו את הבעיה ואתחלו את הדף.",
"Your Element is misconfigured": "האלמנט מוגדר באופן שגוי",
"Go to element.io": "חזור לאתר הראשי: element.io",
@ -31,6 +31,7 @@
"Powered by Matrix": "מופעל על ידי מטריקס",
"%(appName)s (%(browserName)s, %(osName)s)": "%(appName)s (%(browserName)s, %(osName)s)",
"%(brand)s Desktop (%(platformName)s)": "%(brand)s שולחן עבודה %(platformName)s",
"The message from the parser is: %(message)s": "ההודעה מהניתוח היא: %(message)s",
"Missing indexeddb worker script!": "סקריפט indexeddb worker חסר!"
"The message from the parser is: %(message)s": "ההודעה מהמנתח היא: %(message)s",
"Missing indexeddb worker script!": "סקריפט indexeddb worker חסר!",
"Switch to space by number": "עבור אל 'Space' על פי מספרו"
}

View file

@ -33,5 +33,6 @@
"Your browser can't run %(brand)s": "A böngészője nem tudja futtatni ezt: %(brand)s",
"%(brand)s uses advanced browser features which aren't supported by your current browser.": "%(brand)s speciális böngészőfunkciókat használ, amelyeket a jelenlegi böngészője nem támogat.",
"Powered by Matrix": "A gépházban: Matrix",
"Use %(brand)s on mobile": "Mobilon használd ezt: %(brand)s"
"Use %(brand)s on mobile": "Mobilon használd ezt: %(brand)s",
"Switch to space by number": "Tér váltás számmal"
}

View file

@ -33,5 +33,6 @@
"Your browser can't run %(brand)s": "Il tuo browser non può eseguire %(brand)s",
"%(brand)s uses advanced browser features which aren't supported by your current browser.": "%(brand)s usa funzionalità avanzate del browser che non sono supportate dal tuo browser attuale.",
"Powered by Matrix": "Offerto da Matrix",
"Use %(brand)s on mobile": "Usa %(brand)s su mobile"
"Use %(brand)s on mobile": "Usa %(brand)s su mobile",
"Switch to space by number": "Passa allo spazio per numero"
}

View file

@ -4,5 +4,28 @@
"Dismiss": "უარის თქმა",
"powered by Matrix": "Matrix-ზე დაფუძნებული",
"Welcome to Element": "კეთილი იყოს თქვენი მობრძანება Element-ზე",
"Decentralised, encrypted chat &amp; collaboration powered by [matrix]": "დეცენტრალიზებული, დაშიფრული ჩატი &amp; კოლაბორაცია, დაფუძნებული [matrix]-ზე"
"Decentralised, encrypted chat &amp; collaboration powered by [matrix]": "დეცენტრალიზებული, დაშიფრული ჩატი &amp; კოლაბორაცია, დაფუძნებული [matrix]-ზე",
"Explore rooms": "ოთახების დათავლიერება",
"Failed to start": "ჩართვა ვერ მოხერხდა",
"Use %(brand)s on mobile": "გამოიყენე %(brand)s-ი მობილურზე",
"%(brand)s Desktop (%(platformName)s)": "%(brand)s დესკტოპი (%(platformName)s)",
"Unexpected error preparing the app. See console for details.": "მოულოდნელი ერორი აპლიკაციის შემზადებისას. იხილეთ კონსოლი დეტალებისთვის.",
"Your Element configuration contains invalid JSON. Please correct the problem and reload the page.": "თქვენი Element-ის კონფიგურაცია შეიცავს მიუღებელ JSON-ს. გთხოვთ გადაჭრათ პრობლემა და დაარაფრეშოთ გვერდი.",
"Sign In": "შესვლა",
"Invalid configuration: no default server specified.": "არასწორი კონფიგურაცია: მთავარი სერვერი არ არის მითითებული.",
"Create Account": "ანგარიშის შექმნა",
"Go to element.io": "გადადი element.io-ზე",
"I understand the risks and wish to continue": "მესმის რისკები და მსურს გაგრძელება",
"Unsupported browser": "ბრაუზერი არ არის მხარდაჭერილი",
"Your browser can't run %(brand)s": "შენ ბრაუზერს არ შეუძლია გაუშვას %(brand)s-ი",
"Unable to load config file: please refresh the page to try again.": "კონფიგურაციის ფაილის ჩატვირთვა ვერ მოხერხდა: დაარეფრეშე გვერდი თავიდან საცდელად",
"Invalid JSON": "მიუღებელი JSON-ი",
"Your Element is misconfigured": "შენი Element-ი არასწორადაა კონფიგურირებული",
"Please install <chromeLink>Chrome</chromeLink>, <firefoxLink>Firefox</firefoxLink>, or <safariLink>Safari</safariLink> for the best experience.": "გთხოვთ დააინსტალოთ <chromeLink>Chrome-ი</chromeLink>, <firefoxLink>Firefox-ი</firefoxLink>, ან <safariLink>Safari</safariLink> საუკეთესო გამოცდილებისთვის.",
"Powered by Matrix": "მუშაობს Matrix-ის მეშვეობით",
"%(appName)s (%(browserName)s, %(osName)s)": "%(appName)s (%(browserName)s, %(osName)s)",
"Go to your browser to complete Sign In": "გახსენი ბრაუზერი Sign In-ის დასასრულებლად",
"Open user settings": "მომხმარებლების პარამეტრების გახსნა",
"Open": "გახსნა",
"Download Completed": "გადმოწერა დასრულებულია"
}

View file

@ -6,7 +6,7 @@
"Welcome to Element": "Welkom bij Element",
"Decentralised, encrypted chat &amp; collaboration powered by [matrix]": "Gedecentraliseerd en versleuteld chatten &amp; samenwerken dankzij [matrix]",
"Sign In": "Inloggen",
"Create Account": "Registeren",
"Create Account": "Registreren",
"Explore rooms": "Gesprekken ontdekken",
"Unexpected error preparing the app. See console for details.": "Er is een onverwachte fout opgetreden bij het voorbereiden van de app. Zie de console voor details.",
"Invalid configuration: can only specify one of default_server_config, default_server_name, or default_hs_url.": "Configuratiefout: kan slechts één van default_server_config, default_server_name, of default_hs_url opgeven.",
@ -33,5 +33,6 @@
"Your browser can't run %(brand)s": "Uw browser kan %(brand)s niet starten",
"%(brand)s uses advanced browser features which aren't supported by your current browser.": "%(brand)s gebruikt geavanceerde functies die niet ondersteund worden in uw huidige browser.",
"Powered by Matrix": "Mogelijk gemaakt door Matrix",
"Use %(brand)s on mobile": "Gebruik %(brand)s op uw mobiel"
"Use %(brand)s on mobile": "Gebruik %(brand)s op uw mobiel",
"Switch to space by number": "Wissel naar space per nummer"
}

View file

@ -33,5 +33,6 @@
"Your browser can't run %(brand)s": "Seu browser não consegue rodar %(brand)s",
"%(brand)s uses advanced browser features which aren't supported by your current browser.": "%(brand)s usa funcionalidade de browser avançada que não é suportada por seu browser atual.",
"Powered by Matrix": "Powered by Matrix",
"Use %(brand)s on mobile": "Usar %(brand)s em celular"
"Use %(brand)s on mobile": "Usar %(brand)s em celular",
"Switch to space by number": "Trocar para espaço por número"
}

View file

@ -4,5 +4,15 @@
"Welcome to Element": "ඉලමන්ට් වෙත සාදරයෙන් පිළිගනිමු",
"Open": "විවෘත කරන්න",
"Powered by Matrix": "මැට්‍රික්ස් මඟින් බලගන්වා ඇත",
"Sign In": "පිවිසෙන්න"
"Sign In": "පිවිසෙන්න",
"Dismiss": "ඉවතලන්න",
"Explore rooms": "කාමර බලන්න",
"Create Account": "ගිණුමක් සාදන්න",
"Failed to start": "ඇරඹීමට අපොහොසත් විය",
"Go to element.io": "element.io වෙත යන්න",
"Your browser can't run %(brand)s": "ඔබගේ අතිරික්සුවට %(brand)s ධාවනය කළ නොහැකිය",
"Unsupported browser": "සහය නොදක්වන අතිරික්සුව කි",
"Go to your browser to complete Sign In": "පිවිසීම සම්පූර්ණ කිරීමට ඔබගේ අතිරික්සුව වෙත යන්න",
"Download Completed": "බාගැනීම සම්පූර්ණයි",
"Open user settings": "පරිශීලක සැකසුම් විවෘත කරන්න"
}

View file

@ -33,5 +33,6 @@
"Your browser can't run %(brand)s": "Shfletuesi juaj smund të xhirojë %(brand)s",
"%(brand)s uses advanced browser features which aren't supported by your current browser.": "%(brand)s përdor veçori të thelluara të shfletuesit, të cilat shfletuesi juaj i tanishëm si mbulon.",
"Powered by Matrix": "Bazuar në Matrix",
"Use %(brand)s on mobile": "Përdor %(brand)s në celular"
"Use %(brand)s on mobile": "Përdor %(brand)s në celular",
"Switch to space by number": "Kalo te hapësira me numrin"
}

View file

@ -33,5 +33,6 @@
"Powered by Matrix": "Drivs av Matrix",
"Your browser can't run %(brand)s": "Din webbläsare kan inte köra %(brand)s",
"%(brand)s uses advanced browser features which aren't supported by your current browser.": "%(brand)s använder avancerade webbläsarfunktioner som inte stöds av din aktuella webbläsare.",
"Use %(brand)s on mobile": "Använd %(brand)s på mobilen"
"Use %(brand)s on mobile": "Använd %(brand)s på mobilen",
"Switch to space by number": "Byt till utrymme med nummer"
}

View file

@ -1,16 +1,37 @@
{
"Dismiss": "நீக்கு",
"powered by Matrix": "Matrix-ஆல் ஆனது",
"Unknown device": "தெரியாத கருவி",
"You need to be using HTTPS to place a screen-sharing call.": "நீங்கள் திரைபகிர்வு அழைப்பை மேற்க்கொள்ள HTTPS-ஐ பயன்படுத்த வேண்டும்.",
"Welcome to Element": "Element -ற்க்கு வரவேற்க்கிறோம்",
"Unknown device": "அறியப்படாத சாதனம்",
"You need to be using HTTPS to place a screen-sharing call.": "நீங்கள் திரைபகிர்வு அழைப்பை மேற்க்கொள்ள HTTPS ஐ பயன்படுத்த வேண்டும்.",
"Welcome to Element": "எலிமெண்டிற்க்கு வரவேற்க்கிறோம்",
"The message from the parser is: %(message)s": "பாகுபடுத்தி அனுப்பிய செய்தி: %(message)s",
"Invalid JSON": "தவறான JSON",
"Unexpected error preparing the app. See console for details.": "பயன்பாட்டைத் தயாரிப்பதில் எதிர்பாராத பிழை. விவரங்களுக்கு console ஐப் பார்க்கவும்.",
"Unexpected error preparing the app. See console for details.": "பயன்பாட்டைத் தயார் செய்வதில் எதிர்பாராத பிழை. விவரங்களுக்கு console ஐப் பார்க்கவும்.",
"Invalid configuration: can only specify one of default_server_config, default_server_name, or default_hs_url.": "தவறான உள்ளமைவு: default_server_config, default_server_name அல்லது default_hs_url இல் ஒன்றை மட்டுமே குறிப்பிட முடியும்.",
"Invalid configuration: no default server specified.": "தவறான உள்ளமைவு: இயல்புநிலை சேவையகம் குறிப்பிடப்படவில்லை.",
"Decentralised, encrypted chat &amp; collaboration powered by [matrix]": "[matrix] ஆல் இயக்கப்படும் பரவலாக்கப்பட்ட, மறைகுறியாக்கப்பட்ட அரட்டை &amp; ஒத்துழைப்பு",
"Decentralised, encrypted chat &amp; collaboration powered by [matrix]": "[matrix] மூலம் இயக்கப்படும் பரவலாக்கப்பட்ட, மறைகுறியாக்கப்பட்ட அரட்டை பயன்பாட்டு",
"Sign In": "உள்நுழைக",
"Create Account": "உங்கள் கணக்கை துவங்குங்கள்",
"Explore rooms": "அறைகளை ஆராயுங்கள்"
"Explore rooms": "அறைகளை ஆராயுங்கள்",
"Missing indexeddb worker script!": "indexeddb வேலையாளி குறியீட்டை காணவில்லை!",
"Powered by Matrix": "மேட்ரிக்ஸ் மூலம் இயக்கப்படுகிறது",
"Previous/next recently visited room or community": "முந்தைய/அடுத்த சமீபத்தில் பார்வையிட்ட அறை அல்லது சமூகம்",
"Failed to start": "துவங்குவதில் தோல்வி",
"Go to element.io": "element.io க்குச் செல்லவும்",
"I understand the risks and wish to continue": "நான் அபாயங்களைப் புரிந்துகொண்டு தொடர விரும்புகிறேன்",
"You can continue using your current browser, but some or all features may not work and the look and feel of the application may be incorrect.": "உங்கள் தற்போதைய உலாவியை நீங்கள் தொடர்ந்து பயன்படுத்தலாம், ஆனால் சில அல்லது அனைத்து அம்சங்களும் செயல்படாமல் போகலாம் மற்றும் பயன்பாட்டின் தோற்றமும் உணர்வும் தவறாக இருக்கலாம்.",
"Please install <chromeLink>Chrome</chromeLink>, <firefoxLink>Firefox</firefoxLink>, or <safariLink>Safari</safariLink> for the best experience.": "சிறந்த அனுபவத்திற்காக <chromeLink>Chrome</chromeLink>, <firefoxLink>Firefox</firefoxLink>, அல்லது அதை <safariLink>Safari</safariLink> ஐ நிறுவவும்.",
"%(brand)s uses advanced browser features which aren't supported by your current browser.": "%(brand)s உங்கள் தற்போதைய உலாவியால் ஆதரிக்கப்படாத மேம்பட்ட உலாவி அம்சங்களைப் பயன்படுத்துகிறது.",
"Your browser can't run %(brand)s": "உங்கள் உலாவியில் %(brand)s ஐ இயக்க முடியாது",
"Unsupported browser": "ஆதரிக்கப்படாத உலாவி",
"Use %(brand)s on mobile": "%(brand)s ஐ திறன்பேசியில் பயன்படுத்தவும்",
"%(appName)s (%(browserName)s, %(osName)s)": "%(appName)s (%(browserName)s, %(osName)s)",
"Go to your browser to complete Sign In": "உள்நுழைவை முடிவுசெய்ய உங்கள் உலாவிக்குச் செல்லவும்",
"%(brand)s Desktop (%(platformName)s)": "%(brand)s திரைமுகப்பு (%(platformName)s)",
"Open user settings": "பயனர் அமைப்புகளைத் திறக்கவும்",
"Open": "திற",
"Download Completed": "பதிவிறக்கம் முடிவடைந்தது",
"Unable to load config file: please refresh the page to try again.": "கட்டமைப்பு கோப்பை ஏற்ற முடியவில்லை: மீண்டும் முயற்சிக்க பக்கத்தைப் புதுப்பிக்கவும்.",
"Your Element configuration contains invalid JSON. Please correct the problem and reload the page.": "உங்கள் எலிமெண்ட் உள்ளமைவில் தவறான JSON உள்ளது. தயவுசெய்து இதை சரிசெய்து பக்கத்தை மீண்டும் ஏற்றவும்.",
"Your Element is misconfigured": "உங்கள் எலிமெண்ட் தவறாக உள்ளமைக்கப்பட்டுள்ளது"
}

View file

@ -33,5 +33,6 @@
"%(brand)s Desktop (%(platformName)s)": "%(brand)s Masaüstü (%(platformName)s)",
"Open": "Aç",
"Missing indexeddb worker script!": "Indexeddb worker kodu eksik!",
"Use %(brand)s on mobile": "Mobilde %(brand)s kullan"
"Use %(brand)s on mobile": "Mobilde %(brand)s kullan",
"Switch to space by number": "Sayı ile belirtilen alana geç"
}

View file

@ -33,5 +33,6 @@
"Powered by Matrix": "Працює на Matrix",
"Your browser can't run %(brand)s": "Ваш переглядач неспроможний запустити %(brand)s",
"%(brand)s uses advanced browser features which aren't supported by your current browser.": "%(brand)s використовує передові властивості, які ваш браузер не підтримує.",
"Use %(brand)s on mobile": "Користуйтеся %(brand)s на мобільному"
"Use %(brand)s on mobile": "Користуйтеся %(brand)s на мобільному",
"Switch to space by number": "Перейдіть до простору за номером"
}

View file

@ -33,5 +33,6 @@
"Your browser can't run %(brand)s": "浏览器无法运行 %(brand)s",
"%(brand)s uses advanced browser features which aren't supported by your current browser.": "当前浏览器不支持 %(brand)s 所需的高级浏览器特性。",
"Powered by Matrix": "由 Matrix 驱动",
"Use %(brand)s on mobile": "在移动设备上使用 %(brand)s"
"Use %(brand)s on mobile": "在移动设备上使用 %(brand)s",
"Switch to space by number": "按数字切换空间"
}

View file

@ -30,8 +30,9 @@
"Open": "開啟",
"Your Element is misconfigured": "Element 配置錯誤",
"Your Element configuration contains invalid JSON. Please correct the problem and reload the page.": "Element 的配置中包含無效JSON請更正錯誤並重新加載網頁。",
"Your browser can't run %(brand)s": "當前瀏覽器無法運行%(brand)s",
"%(brand)s uses advanced browser features which aren't supported by your current browser.": "當前瀏覽器不支持%(brand)s使用的高級特性。",
"Your browser can't run %(brand)s": "您的瀏覽器無法執行 %(brand)s",
"%(brand)s uses advanced browser features which aren't supported by your current browser.": "%(brand)s 使用了您目前的瀏覽器不支援的進階瀏覽器功能。",
"Powered by Matrix": "由 Matrix 提供",
"Use %(brand)s on mobile": "在行動裝置上使用 %(brand)s"
"Use %(brand)s on mobile": "在行動裝置上使用 %(brand)s",
"Switch to space by number": "依數字切換至空間"
}

View file

@ -25,17 +25,16 @@ window.React = React;
import * as sdk from 'matrix-react-sdk';
import PlatformPeg from 'matrix-react-sdk/src/PlatformPeg';
import {_td, newTranslatableError} from 'matrix-react-sdk/src/languageHandler';
import { _td, newTranslatableError } from 'matrix-react-sdk/src/languageHandler';
import AutoDiscoveryUtils from 'matrix-react-sdk/src/utils/AutoDiscoveryUtils';
import {AutoDiscovery} from "matrix-js-sdk/src/autodiscovery";
import { AutoDiscovery } from "matrix-js-sdk/src/autodiscovery";
import * as Lifecycle from "matrix-react-sdk/src/Lifecycle";
import type MatrixChatType from "matrix-react-sdk/src/components/structures/MatrixChat";
import {MatrixClientPeg} from 'matrix-react-sdk/src/MatrixClientPeg';
import SdkConfig from "matrix-react-sdk/src/SdkConfig";
import {parseQs, parseQsFromFragment} from './url_utils';
import { parseQs, parseQsFromFragment } from './url_utils';
import VectorBasePlatform from "./platform/VectorBasePlatform";
import {createClient} from "matrix-js-sdk/src/matrix";
import { createClient } from "matrix-js-sdk/src/matrix";
let lastLocationHashSet: string = null;
@ -129,18 +128,6 @@ function onTokenLoginCompleted() {
}
export async function loadApp(fragParams: {}) {
// XXX: the way we pass the path to the worker script from webpack via html in body's dataset is a hack
// but alternatives seem to require changing the interface to passing Workers to js-sdk
const vectorIndexeddbWorkerScript = document.body.dataset.vectorIndexeddbWorkerScript;
if (!vectorIndexeddbWorkerScript) {
// If this is missing, something has probably gone wrong with
// the bundling. The js-sdk will just fall back to accessing
// indexeddb directly with no worker script, but we want to
// make sure the indexeddb script is present, so fail hard.
throw newTranslatableError(_td("Missing indexeddb worker script!"));
}
MatrixClientPeg.setIndexedDbWorkerScript(vectorIndexeddbWorkerScript);
window.addEventListener('hashchange', onHashChange);
const platform = PlatformPeg.get();
@ -257,12 +244,12 @@ async function verifyServerConfig() {
validatedConfig = AutoDiscoveryUtils.buildValidatedConfigFromDiscovery(serverName, discoveryResult, true);
} catch (e) {
const {hsUrl, isUrl, userId} = await Lifecycle.getStoredSessionVars();
const { hsUrl, isUrl, userId } = await Lifecycle.getStoredSessionVars();
if (hsUrl && userId) {
console.error(e);
console.warn("A session was found - suppressing config error and using the session's homeserver");
console.log("Using pre-existing hsUrl and isUrl: ", {hsUrl, isUrl});
console.log("Using pre-existing hsUrl and isUrl: ", { hsUrl, isUrl });
validatedConfig = await AutoDiscoveryUtils.validateServerConfigWithStaticUrls(hsUrl, isUrl, true);
} else {
// the user is not logged in, so scream
@ -277,7 +264,7 @@ async function verifyServerConfig() {
// Add the newly built config to the actual config for use by the app
console.log("Updating SdkConfig with validated discovery information");
SdkConfig.add({"validated_server_config": validatedConfig});
SdkConfig.add({ "validated_server_config": validatedConfig });
return SdkConfig.get();
}

View file

@ -55,7 +55,7 @@ function getConfig(configJsonFilename: string): Promise<{}> {
resolve({});
}
}
reject({err: err, response: response});
reject({ err: err, response: response });
return;
}
@ -65,7 +65,7 @@ function getConfig(configJsonFilename: string): Promise<{}> {
// loading from the filesystem (see above).
resolve(JSON.parse(body));
} catch (e) {
reject({err: e});
reject({ err: e });
}
},
);

View file

@ -35,7 +35,6 @@
worker-src 'self';
frame-src * blob: data:;
form-action 'self';
object-src 'self';
manifest-src 'self';
">
<% for (var i=0; i < htmlWebpackPlugin.files.css.length; i++) {
@ -61,11 +60,10 @@
</head>
<body
style="height: 100%; margin: 0;"
data-vector-indexeddb-worker-script="<%= htmlWebpackPlugin.files.js.find(entry => entry.includes("indexeddb-worker.js")) %>"
data-vector-recorder-worklet-script="<%= htmlWebpackPlugin.files.js.find(entry => entry.includes("recorder-worklet.js")) %>"
>
<noscript>Sorry, Element requires JavaScript to be enabled.</noscript> <!-- TODO: Translate this? -->
<section id="matrixchat" style="height: 100%; overflow: auto;" class="notranslate"></section>
<section id="matrixchat" style="height: 100%;" class="notranslate"></section>
<script src="<%= htmlWebpackPlugin.files.js.find(entry => entry.includes("bundle.js")) %>"></script>
<!-- Legacy supporting Prefetch images -->

View file

@ -26,7 +26,7 @@ require('highlight.js/styles/github.css');
require('katex/dist/katex.css');
// These are things that can run before the skin loads - be careful not to reference the react-sdk though.
import {parseQsFromFragment} from "./url_utils";
import { parseQsFromFragment } from "./url_utils";
import './modernizr';
async function settled(...promises: Array<Promise<any>>) {

View file

@ -14,8 +14,8 @@ See the License for the specific language governing permissions and
limitations under the License.
*/
import {IndexedDBStoreWorker} from 'matrix-js-sdk/src/indexeddb-worker.js';
import { IndexedDBStoreWorker } from 'matrix-js-sdk/src/indexeddb-worker';
const remoteWorker = new IndexedDBStoreWorker(postMessage);
const remoteWorker = new IndexedDBStoreWorker(postMessage as InstanceType<typeof Worker>["postMessage"]);
global.onmessage = remoteWorker.onMessage;

View file

@ -31,10 +31,9 @@ import PWAPlatform from "./platform/PWAPlatform";
import WebPlatform from "./platform/WebPlatform";
import PlatformPeg from "matrix-react-sdk/src/PlatformPeg";
import SdkConfig from "matrix-react-sdk/src/SdkConfig";
import {setTheme} from "matrix-react-sdk/src/theme";
import {initRageshake, initRageshakeStore} from "./rageshakesetup";
import { setTheme } from "matrix-react-sdk/src/theme";
import { initRageshake, initRageshakeStore } from "./rageshakesetup";
export const rageshakePromise = initRageshake();

View file

@ -18,7 +18,7 @@ limitations under the License.
require("./index.scss");
import * as qs from 'querystring';
import {KJUR} from 'jsrsasign';
import { KJUR } from 'jsrsasign';
import {
IOpenIDCredentials,
IWidgetApiRequest,
@ -138,7 +138,7 @@ let meetApi: any; // JitsiMeetExternalAPI
});
widgetApi.transport.reply(ev.detail, {}); // ack
} else {
widgetApi.transport.reply(ev.detail, {error: {message: "Conference not joined"}});
widgetApi.transport.reply(ev.detail, { error: { message: "Conference not joined" } });
}
},
);
@ -168,7 +168,7 @@ function switchVisibleContainers() {
*/
function createJWTToken() {
// Header
const header = {alg: 'HS256', typ: 'JWT'};
const header = { alg: 'HS256', typ: 'JWT' };
// Payload
const payload = {
// As per Jitsi token auth, `iss` needs to be set to something agreed between

View file

@ -326,7 +326,7 @@ body {
<a class="mx_Button" id="configure_element_button" href="#">Configure</a>
<p class="mx_Subtext mx_SubtextTop">Tap the button above, or manually enable <em>Use custom server</em> and enter:</p>
<p class="mx_Subtext">Homeserver: <em id="hs_url"></em></p>
<p class="mx_Subtext" id="custom_is">Identity Server: <em id="is_url"></em></p>
<p class="mx_Subtext" id="custom_is">Identity server: <em id="is_url"></em></p>
</div>
</div>
</div>

View file

@ -1,19 +1,21 @@
import {getVectorConfig} from '../getconfig';
import { getVectorConfig } from '../getconfig';
function onBackToElementClick() {
function onBackToElementClick(): void {
// Cookie should expire in 4 hours
document.cookie = 'element_mobile_redirect_to_guide=false;path=/;max-age=14400';
window.location.href = '../';
}
// NEVER pass user-controlled content to this function! Hardcoded strings only please.
function renderConfigError(message) {
function renderConfigError(message: string): void {
const contactMsg = "If this is unexpected, please contact your system administrator " +
"or technical support representative.";
message = `<h2>Error loading Element</h2><p>${message}</p><p>${contactMsg}</p>`;
const toHide = document.getElementsByClassName("mx_HomePage_container");
const errorContainers = document.getElementsByClassName("mx_HomePage_errorContainer");
const errorContainers = document.getElementsByClassName(
"mx_HomePage_errorContainer",
) as HTMLCollectionOf<HTMLDialogElement>;
for (const e of toHide) {
// We have to clear the content because .style.display='none'; doesn't work
@ -26,7 +28,7 @@ function renderConfigError(message) {
}
}
async function initPage() {
async function initPage(): Promise<void> {
document.getElementById('back_to_element_button').onclick = onBackToElementClick;
const config = await getVectorConfig('..');
@ -92,7 +94,7 @@ async function initPage() {
if (isUrl && !isUrl.endsWith('/')) isUrl += '/';
if (hsUrl !== 'https://matrix.org/') {
document.getElementById('configure_element_button').href =
(document.getElementById('configure_element_button') as HTMLAnchorElement).href =
"https://mobile.element.io?hs_url=" + encodeURIComponent(hsUrl) +
"&is_url=" + encodeURIComponent(isUrl);
document.getElementById('step1_heading').innerHTML= '1: Install the app';

File diff suppressed because one or more lines are too long

View file

@ -22,10 +22,7 @@ import BaseEventIndexManager, {
ICrawlerCheckpoint,
IEventAndProfile,
IIndexStats,
IMatrixEvent,
IMatrixProfile,
ISearchArgs,
ISearchResult,
} from 'matrix-react-sdk/src/indexing/BaseEventIndexManager';
import dis from 'matrix-react-sdk/src/dispatcher/dispatcher';
import { _t, _td } from 'matrix-react-sdk/src/languageHandler';
@ -48,12 +45,13 @@ import React from "react";
import { randomString } from "matrix-js-sdk/src/randomstring";
import { Action } from "matrix-react-sdk/src/dispatcher/actions";
import { ActionPayload } from "matrix-react-sdk/src/dispatcher/payloads";
import { SwitchSpacePayload} from "matrix-react-sdk/src/dispatcher/payloads/SwitchSpacePayload";
import { SwitchSpacePayload } from "matrix-react-sdk/src/dispatcher/payloads/SwitchSpacePayload";
import { showToast as showUpdateToast } from "matrix-react-sdk/src/toasts/UpdateToast";
import { CheckUpdatesPayload } from "matrix-react-sdk/src/dispatcher/payloads/CheckUpdatesPayload";
import ToastStore from "matrix-react-sdk/src/stores/ToastStore";
import GenericExpiringToast from "matrix-react-sdk/src/components/views/toasts/GenericExpiringToast";
import SettingsStore from 'matrix-react-sdk/src/settings/SettingsStore';
import { IMatrixProfile, IEventWithRoomId as IMatrixEvent, IResultRoomEvents } from "matrix-js-sdk/src/@types/search";
import VectorBasePlatform from './VectorBasePlatform';
@ -119,8 +117,8 @@ class SeshatIndexManager extends BaseEventIndexManager {
// TODO this should be moved into the preload.js file.
const ipcCallId = ++this.nextIpcCallId;
return new Promise((resolve, reject) => {
this.pendingIpcCalls[ipcCallId] = {resolve, reject};
window.electron.send('seshat', {id: ipcCallId, name, args});
this.pendingIpcCalls[ipcCallId] = { resolve, reject };
window.electron.send('seshat', { id: ipcCallId, name, args });
});
}
@ -172,7 +170,7 @@ class SeshatIndexManager extends BaseEventIndexManager {
return this._ipcCall('commitLiveEvents');
}
async searchEventIndex(searchConfig: ISearchArgs): Promise<ISearchResult> {
async searchEventIndex(searchConfig: ISearchArgs): Promise<IResultRoomEvents> {
return this._ipcCall('searchEventIndex', searchConfig);
}
@ -258,9 +256,9 @@ export default class ElectronPlatform extends VectorBasePlatform {
dis.fire(Action.ViewUserSettings);
});
electron.on('userDownloadCompleted', (ev, {path, name}) => {
electron.on('userDownloadCompleted', (ev, { path, name }) => {
const onAccept = () => {
electron.send('userDownloadOpen', {path});
electron.send('userDownloadOpen', { path });
};
ToastStore.sharedInstance().addOrReplaceToast({
@ -326,7 +324,7 @@ export default class ElectronPlatform extends VectorBasePlatform {
return this._ipcCall('getConfig');
}
onUpdateDownloaded = async (ev, {releaseNotes, releaseName}) => {
onUpdateDownloaded = async (ev, { releaseNotes, releaseName }) => {
dis.dispatch<CheckUpdatesPayload>({
action: Action.CheckUpdates,
status: UpdateCheckStatus.Ready,
@ -497,8 +495,8 @@ export default class ElectronPlatform extends VectorBasePlatform {
async _ipcCall(name: string, ...args: any[]): Promise<any> {
const ipcCallId = ++this.nextIpcCallId;
return new Promise((resolve, reject) => {
this.pendingIpcCalls[ipcCallId] = {resolve, reject};
window.electron.send('ipcCall', {id: ipcCallId, name, args});
this.pendingIpcCalls[ipcCallId] = { resolve, reject };
window.electron.send('ipcCall', { id: ipcCallId, name, args });
// Maybe add a timeout to these? Probably not necessary.
});
}
@ -593,8 +591,9 @@ export default class ElectronPlatform extends VectorBasePlatform {
break;
}
if (
!handled &&
if (!handled &&
// ideally we would use SpaceStore.spacesEnabled here but importing SpaceStore in this platform
// breaks skinning as the platform is instantiated prior to the skin being loaded
SettingsStore.getValue("feature_spaces") &&
ev.code.startsWith("Digit") &&
isOnlyCtrlOrCmdKeyEvent(ev)

View file

@ -18,8 +18,8 @@ limitations under the License.
*/
import BasePlatform from 'matrix-react-sdk/src/BasePlatform';
import {_t} from 'matrix-react-sdk/src/languageHandler';
import {getVectorConfig} from "../getconfig";
import { _t } from 'matrix-react-sdk/src/languageHandler';
import { getVectorConfig } from "../getconfig";
import Favicon from "../../favicon";

View file

@ -17,13 +17,13 @@ limitations under the License.
*/
import VectorBasePlatform from './VectorBasePlatform';
import {UpdateCheckStatus} from "matrix-react-sdk/src/BasePlatform";
import { UpdateCheckStatus } from "matrix-react-sdk/src/BasePlatform";
import request from 'browser-request';
import dis from 'matrix-react-sdk/src/dispatcher/dispatcher';
import {_t} from 'matrix-react-sdk/src/languageHandler';
import {Room} from "matrix-js-sdk/src/models/room";
import {hideToast as hideUpdateToast, showToast as showUpdateToast} from "matrix-react-sdk/src/toasts/UpdateToast";
import {Action} from "matrix-react-sdk/src/dispatcher/actions";
import { _t } from 'matrix-react-sdk/src/languageHandler';
import { Room } from "matrix-js-sdk/src/models/room";
import { hideToast as hideUpdateToast, showToast as showUpdateToast } from "matrix-react-sdk/src/toasts/UpdateToast";
import { Action } from "matrix-react-sdk/src/dispatcher/actions";
import { CheckUpdatesPayload } from 'matrix-react-sdk/src/dispatcher/payloads/CheckUpdatesPayload';
import UAParser from 'ua-parser-js';

View file

@ -55,8 +55,7 @@ module.exports = (env, argv) => {
entry: {
"bundle": "./src/vector/index.ts",
"indexeddb-worker": "./src/vector/indexeddb-worker.js",
"mobileguide": "./src/vector/mobile_guide/index.js",
"mobileguide": "./src/vector/mobile_guide/index.ts",
"jitsi": "./src/vector/jitsi/index.ts",
"usercontent": "./node_modules/matrix-react-sdk/src/usercontent/index.js",
"recorder-worklet": "./node_modules/matrix-react-sdk/src/voice/RecorderWorklet.ts",
@ -151,6 +150,10 @@ module.exports = (env, argv) => {
/olm[\\/](javascript[\\/])?olm\.js$/,
],
rules: [
{
test: /\.worker\.ts$/,
loader: "worker-loader",
},
{
test: /\.(ts|js)x?$/,
include: (f) => {
@ -251,7 +254,6 @@ module.exports = (env, argv) => {
require("postcss-easings")(),
require("postcss-strip-inline-comments")(),
require("postcss-hexrgba")(),
require("postcss-calc")(),
// It's important that this plugin is last otherwise we end
// up with broken CSS.

1098
yarn.lock

File diff suppressed because it is too large Load diff