mirror of
https://github.com/vector-im/hydrogen-web.git
synced 2024-11-20 03:25:52 +01:00
Merge branch 'master' into sas-verification
This commit is contained in:
commit
e71ecdd0ba
@ -152,6 +152,8 @@ function toIceServer(settings: TurnServerSettings): RTCIceServer {
|
||||
urls: settings.uris,
|
||||
username: settings.username,
|
||||
credential: settings.password,
|
||||
// @ts-ignore
|
||||
// this field is deprecated but providing it nonetheless
|
||||
credentialType: "password"
|
||||
}
|
||||
}
|
||||
|
@ -243,7 +243,7 @@ export function tests() {
|
||||
get keySource(): KeySource { return KeySource.DeviceMessage; }
|
||||
|
||||
loadInto(session: Olm.InboundGroupSession) {
|
||||
const mockSession = session as MockInboundSession;
|
||||
const mockSession = session as unknown as MockInboundSession;
|
||||
mockSession.sessionId = this.sessionId;
|
||||
mockSession.firstKnownIndex = this._firstKnownIndex;
|
||||
}
|
||||
|
@ -58,7 +58,9 @@ export class SessionDecryption {
|
||||
this.decryptionRequests!.push(request);
|
||||
decryptionResult = await request.response();
|
||||
} else {
|
||||
decryptionResult = session.decrypt(ciphertext) as OlmDecryptionResult;
|
||||
// the return type of Olm.InboundGroupSession::decrypt is likely wrong, message_index is a number and not a string AFAIK
|
||||
// getting it fixed upstream but fixing it like this for now.
|
||||
decryptionResult = session.decrypt(ciphertext) as unknown as OlmDecryptionResult;
|
||||
}
|
||||
const {plaintext} = decryptionResult!;
|
||||
let payload;
|
||||
|
@ -173,8 +173,8 @@ export class CrossSigning {
|
||||
log.set({publishedMasterKey: publisedEd25519Key, derivedPublicKey});
|
||||
this._isMasterKeyTrusted = !!publisedEd25519Key && publisedEd25519Key === derivedPublicKey;
|
||||
if (!this._isMasterKeyTrusted) {
|
||||
return MSKVerification.DerivedPubKeyMismatch;
|
||||
log.set("failure", "mismatch");
|
||||
return MSKVerification.DerivedPubKeyMismatch;
|
||||
}
|
||||
return MSKVerification.Valid;
|
||||
});
|
||||
|
@ -65,7 +65,7 @@ export class MediaDevicesWrapper implements IMediaDevices {
|
||||
};
|
||||
}
|
||||
|
||||
private getScreenshareContraints(): DisplayMediaStreamConstraints {
|
||||
private getScreenshareContraints(): MediaStreamConstraints {
|
||||
return {
|
||||
audio: false,
|
||||
video: true,
|
||||
|
@ -29,17 +29,17 @@ function objHasFns(obj: ClassNames<unknown>): obj is { [className: string]: bool
|
||||
return false;
|
||||
}
|
||||
|
||||
export type RenderFn<T> = (t: Builder<T>, vm: T) => ViewNode;
|
||||
type TextBinding<T> = (T) => string | number | boolean | undefined | null;
|
||||
type Child<T> = NonBoundChild | TextBinding<T>;
|
||||
type Children<T> = Child<T> | Child<T>[];
|
||||
export type RenderFn<T extends IObservableValue> = (t: Builder<T>, vm: T) => ViewNode;
|
||||
type TextBinding<T extends IObservableValue> = (T) => string | number | boolean | undefined | null;
|
||||
type Child<T extends IObservableValue> = NonBoundChild | TextBinding<T>;
|
||||
type Children<T extends IObservableValue> = Child<T> | Child<T>[];
|
||||
type EventHandler = ((event: Event) => void);
|
||||
type AttributeStaticValue = string | boolean;
|
||||
type AttributeBinding<T> = (value: T) => AttributeStaticValue;
|
||||
export type AttrValue<T> = AttributeStaticValue | AttributeBinding<T> | EventHandler | ClassNames<T>;
|
||||
export type Attributes<T> = { [attribute: string]: AttrValue<T> };
|
||||
type ElementFn<T> = (attributes?: Attributes<T> | Children<T>, children?: Children<T>) => Element;
|
||||
export type Builder<T> = TemplateBuilder<T> & { [tagName in typeof TAG_NAMES[string][number]]: ElementFn<T> };
|
||||
type AttributeBinding<T extends IObservableValue> = (value: T) => AttributeStaticValue;
|
||||
export type AttrValue<T extends IObservableValue> = AttributeStaticValue | AttributeBinding<T> | EventHandler | ClassNames<T>;
|
||||
export type Attributes<T extends IObservableValue> = { [attribute: string]: AttrValue<T> };
|
||||
type ElementFn<T extends IObservableValue> = (attributes?: Attributes<T> | Children<T>, children?: Children<T>) => Element;
|
||||
export type Builder<T extends IObservableValue> = TemplateBuilder<T> & { [tagName in typeof TAG_NAMES[string][number]]: ElementFn<T> };
|
||||
|
||||
/**
|
||||
Bindable template. Renders once, and allows bindings for given nodes. If you need
|
||||
@ -394,7 +394,7 @@ for (const [ns, tags] of Object.entries(TAG_NAMES)) {
|
||||
}
|
||||
}
|
||||
|
||||
export class InlineTemplateView<T> extends TemplateView<T> {
|
||||
export class InlineTemplateView<T extends IObservableValue> extends TemplateView<T> {
|
||||
private _render: RenderFn<T>;
|
||||
|
||||
constructor(value: T, render: RenderFn<T>) {
|
||||
|
32
yarn.lock
32
yarn.lock
@ -83,12 +83,14 @@
|
||||
fastq "^1.6.0"
|
||||
|
||||
"@playwright/test@^1.27.1":
|
||||
version "1.27.1"
|
||||
resolved "https://registry.yarnpkg.com/@playwright/test/-/test-1.27.1.tgz#9364d1e02021261211c8ff586d903faa79ce95c4"
|
||||
integrity sha512-mrL2q0an/7tVqniQQF6RBL2saskjljXzqNcCOVMUjRIgE6Y38nCNaP+Dc2FBW06bcpD3tqIws/HT9qiMHbNU0A==
|
||||
version "1.32.1"
|
||||
resolved "https://registry.yarnpkg.com/@playwright/test/-/test-1.32.1.tgz#749c9791adb048c266277a39ba0f7e33fe593ffe"
|
||||
integrity sha512-FTwjCuhlm1qHUGf4hWjfr64UMJD/z0hXYbk+O387Ioe6WdyZQ+0TBDAc6P+pHjx2xCv1VYNgrKbYrNixFWy4Dg==
|
||||
dependencies:
|
||||
"@types/node" "*"
|
||||
playwright-core "1.27.1"
|
||||
playwright-core "1.32.1"
|
||||
optionalDependencies:
|
||||
fsevents "2.3.2"
|
||||
|
||||
"@trysound/sax@0.2.0":
|
||||
version "0.2.0"
|
||||
@ -101,9 +103,9 @@
|
||||
integrity sha512-qcUXuemtEu+E5wZSJHNxUXeCZhAfXKQ41D+duX+VYPde7xyEVZci+/oXKJL13tnRs9lR2pr4fod59GT6/X1/yQ==
|
||||
|
||||
"@types/node@*":
|
||||
version "18.7.13"
|
||||
resolved "https://registry.yarnpkg.com/@types/node/-/node-18.7.13.tgz#23e6c5168333480d454243378b69e861ab5c011a"
|
||||
integrity sha512-46yIhxSe5xEaJZXWdIBP7GU4HDTG8/eo0qd9atdiL+lFpA03y8KS+lkTN834TWJj5767GbWv4n/P6efyTFt1Dw==
|
||||
version "18.15.10"
|
||||
resolved "https://registry.yarnpkg.com/@types/node/-/node-18.15.10.tgz#4ee2171c3306a185d1208dad5f44dae3dee4cfe3"
|
||||
integrity sha512-9avDaQJczATcXgfmMAW3MIWArOO7A+m90vuCFLr8AotWf8igO/mRoYukrk2cqZVtv38tHs33retzHEilM7FpeQ==
|
||||
|
||||
"@typescript-eslint/eslint-plugin@^4.29.2":
|
||||
version "4.29.2"
|
||||
@ -1003,7 +1005,7 @@ fs.realpath@^1.0.0:
|
||||
resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f"
|
||||
integrity sha1-FQStJSMVjKpA20onh8sBQRmU6k8=
|
||||
|
||||
fsevents@~2.3.2:
|
||||
fsevents@2.3.2, fsevents@~2.3.2:
|
||||
version "2.3.2"
|
||||
resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.3.2.tgz#8a526f78b8fdf4623b709e0b975c52c24c02fd1a"
|
||||
integrity sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==
|
||||
@ -1382,10 +1384,10 @@ picomatch@^2.2.3:
|
||||
resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.0.tgz#f1f061de8f6a4bf022892e2d128234fb98302972"
|
||||
integrity sha512-lY1Q/PiJGC2zOv/z391WOTD+Z02bCgsFfvxoXXf6h7kv9o+WmsmzYqrAwY63sNgOxE4xEdq0WyUnXfKeBrSvYw==
|
||||
|
||||
playwright-core@1.27.1:
|
||||
version "1.27.1"
|
||||
resolved "https://registry.yarnpkg.com/playwright-core/-/playwright-core-1.27.1.tgz#840ef662e55a3ed759d8b5d3d00a5f885a7184f4"
|
||||
integrity sha512-9EmeXDncC2Pmp/z+teoVYlvmPWUC6ejSSYZUln7YaP89Z6lpAaiaAnqroUt/BoLo8tn7WYShcfaCh+xofZa44Q==
|
||||
playwright-core@1.32.1:
|
||||
version "1.32.1"
|
||||
resolved "https://registry.yarnpkg.com/playwright-core/-/playwright-core-1.32.1.tgz#5a10c32403323b07d75ea428ebeed866a80b76a1"
|
||||
integrity sha512-KZYUQC10mXD2Am1rGlidaalNGYk3LU1vZqqNk0gT4XPty1jOqgup8KDP8l2CUlqoNKhXM5IfGjWgW37xvGllBA==
|
||||
|
||||
postcss-css-variables@^0.18.0:
|
||||
version "0.18.0"
|
||||
@ -1689,9 +1691,9 @@ type-fest@^0.20.2:
|
||||
integrity sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==
|
||||
|
||||
typescript@^4.7.0:
|
||||
version "4.7.4"
|
||||
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.7.4.tgz#1a88596d1cf47d59507a1bcdfb5b9dfe4d488235"
|
||||
integrity sha512-C0WQT0gezHuw6AdY1M2jxUO83Rjf0HP7Sk1DtXj6j1EwkQNZrHAg2XPWlq62oqEhYvONq5pkC2Y9oPljWToLmQ==
|
||||
version "4.9.5"
|
||||
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.9.5.tgz#095979f9bcc0d09da324d58d03ce8f8374cbe65a"
|
||||
integrity sha512-1FXk9E2Hm+QzZQ7z+McJiHL4NW1F2EzMu9Nq9i3zAaGqibafqYwCVU6WyWAuyQRRzOlxou8xZSyXLEN8oKj24g==
|
||||
|
||||
typeson-registry@^1.0.0-alpha.20:
|
||||
version "1.0.0-alpha.39"
|
||||
|
Loading…
Reference in New Issue
Block a user