mirror of
https://github.com/element-hq/element-web
synced 2024-11-27 19:56:47 +03:00
Merge branches 't3chguy/toasts3' and 't3chguy/toasts3_2' of github.com:matrix-org/matrix-react-sdk into t3chguy/toasts3_2
This commit is contained in:
commit
4892d8cdd0
6 changed files with 40 additions and 40 deletions
|
@ -1,3 +1,12 @@
|
||||||
|
Changes in [2.6.1](https://github.com/matrix-org/matrix-react-sdk/releases/tag/v2.6.1) (2020-05-22)
|
||||||
|
===================================================================================================
|
||||||
|
[Full Changelog](https://github.com/matrix-org/matrix-react-sdk/compare/v2.6.0...v2.6.1)
|
||||||
|
|
||||||
|
* Fix key backup restore with SSSS
|
||||||
|
[\#4617](https://github.com/matrix-org/matrix-react-sdk/pull/4617)
|
||||||
|
* Remove SSSS key upgrade check from rageshake
|
||||||
|
[\#4616](https://github.com/matrix-org/matrix-react-sdk/pull/4616)
|
||||||
|
|
||||||
Changes in [2.6.0](https://github.com/matrix-org/matrix-react-sdk/releases/tag/v2.6.0) (2020-05-19)
|
Changes in [2.6.0](https://github.com/matrix-org/matrix-react-sdk/releases/tag/v2.6.0) (2020-05-19)
|
||||||
===================================================================================================
|
===================================================================================================
|
||||||
[Full Changelog](https://github.com/matrix-org/matrix-react-sdk/compare/v2.6.0-rc.1...v2.6.0)
|
[Full Changelog](https://github.com/matrix-org/matrix-react-sdk/compare/v2.6.0-rc.1...v2.6.0)
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "matrix-react-sdk",
|
"name": "matrix-react-sdk",
|
||||||
"version": "2.6.0",
|
"version": "2.6.1",
|
||||||
"description": "SDK for matrix.org using React",
|
"description": "SDK for matrix.org using React",
|
||||||
"author": "matrix.org",
|
"author": "matrix.org",
|
||||||
"repository": {
|
"repository": {
|
||||||
|
|
|
@ -1,5 +1,3 @@
|
||||||
// @flow
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
Copyright 2016 Aviral Dasgupta
|
Copyright 2016 Aviral Dasgupta
|
||||||
Copyright 2016 OpenMarket Ltd
|
Copyright 2016 OpenMarket Ltd
|
||||||
|
@ -19,9 +17,10 @@ See the License for the specific language governing permissions and
|
||||||
limitations under the License.
|
limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import {MatrixClient} from "matrix-js-sdk";
|
import {MatrixClient} from "matrix-js-sdk/src/client";
|
||||||
import dis from './dispatcher/dispatcher';
|
import dis from './dispatcher/dispatcher';
|
||||||
import BaseEventIndexManager from './indexing/BaseEventIndexManager';
|
import BaseEventIndexManager from './indexing/BaseEventIndexManager';
|
||||||
|
import {ActionPayload} from "./dispatcher/payloads";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Base class for classes that provide platform-specific functionality
|
* Base class for classes that provide platform-specific functionality
|
||||||
|
@ -29,27 +28,25 @@ import BaseEventIndexManager from './indexing/BaseEventIndexManager';
|
||||||
*
|
*
|
||||||
* Instances of this class are provided by the application.
|
* Instances of this class are provided by the application.
|
||||||
*/
|
*/
|
||||||
export default class BasePlatform {
|
export default abstract class BasePlatform {
|
||||||
constructor() {
|
protected notificationCount = 0;
|
||||||
this.notificationCount = 0;
|
protected errorDidOccur = false;
|
||||||
this.errorDidOccur = false;
|
|
||||||
|
|
||||||
dis.register(this._onAction.bind(this));
|
constructor() {
|
||||||
|
dis.register(this.onAction);
|
||||||
}
|
}
|
||||||
|
|
||||||
_onAction(payload: Object) {
|
protected onAction = (payload: ActionPayload) => {
|
||||||
switch (payload.action) {
|
switch (payload.action) {
|
||||||
case 'on_client_not_viable':
|
case 'on_client_not_viable':
|
||||||
case 'on_logged_out':
|
case 'on_logged_out':
|
||||||
this.setNotificationCount(0);
|
this.setNotificationCount(0);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
};
|
||||||
|
|
||||||
// Used primarily for Analytics
|
// Used primarily for Analytics
|
||||||
getHumanReadableName(): string {
|
abstract getHumanReadableName(): string;
|
||||||
return 'Base Platform';
|
|
||||||
}
|
|
||||||
|
|
||||||
setNotificationCount(count: number) {
|
setNotificationCount(count: number) {
|
||||||
this.notificationCount = count;
|
this.notificationCount = count;
|
||||||
|
@ -84,22 +81,17 @@ export default class BasePlatform {
|
||||||
* that is 'granted' if the user allowed the request or
|
* that is 'granted' if the user allowed the request or
|
||||||
* 'denied' otherwise.
|
* 'denied' otherwise.
|
||||||
*/
|
*/
|
||||||
requestNotificationPermission(): Promise<string> {
|
abstract requestNotificationPermission(): Promise<string>;
|
||||||
}
|
|
||||||
|
|
||||||
displayNotification(title: string, msg: string, avatarUrl: string, room: Object) {
|
abstract displayNotification(title: string, msg: string, avatarUrl: string, room: Object);
|
||||||
}
|
|
||||||
|
|
||||||
loudNotification(ev: Event, room: Object) {
|
loudNotification(ev: Event, room: Object) {
|
||||||
}
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns a promise that resolves to a string representing
|
* Returns a promise that resolves to a string representing the current version of the application.
|
||||||
* the current version of the application.
|
|
||||||
*/
|
*/
|
||||||
getAppVersion(): Promise<string> {
|
abstract getAppVersion(): Promise<string>;
|
||||||
throw new Error("getAppVersion not implemented!");
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* If it's not expected that capturing the screen will work
|
* If it's not expected that capturing the screen will work
|
||||||
|
@ -114,20 +106,18 @@ export default class BasePlatform {
|
||||||
* Restarts the application, without neccessarily reloading
|
* Restarts the application, without neccessarily reloading
|
||||||
* any application code
|
* any application code
|
||||||
*/
|
*/
|
||||||
reload() {
|
abstract reload();
|
||||||
throw new Error("reload not implemented!");
|
|
||||||
}
|
|
||||||
|
|
||||||
supportsAutoLaunch(): boolean {
|
supportsAutoLaunch(): boolean {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
// XXX: Surely this should be a setting like any other?
|
// XXX: Surely this should be a setting like any other?
|
||||||
async getAutoLaunchEnabled(): boolean {
|
async getAutoLaunchEnabled(): Promise<boolean> {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
async setAutoLaunchEnabled(enabled: boolean): void {
|
async setAutoLaunchEnabled(enabled: boolean): Promise<void> {
|
||||||
throw new Error("Unimplemented");
|
throw new Error("Unimplemented");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -135,11 +125,11 @@ export default class BasePlatform {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
async getAutoHideMenuBarEnabled(): boolean {
|
async getAutoHideMenuBarEnabled(): Promise<boolean> {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
async setAutoHideMenuBarEnabled(enabled: boolean): void {
|
async setAutoHideMenuBarEnabled(enabled: boolean): Promise<void> {
|
||||||
throw new Error("Unimplemented");
|
throw new Error("Unimplemented");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -147,11 +137,11 @@ export default class BasePlatform {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
async getMinimizeToTrayEnabled(): boolean {
|
async getMinimizeToTrayEnabled(): Promise<boolean> {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
async setMinimizeToTrayEnabled(enabled: boolean): void {
|
async setMinimizeToTrayEnabled(enabled: boolean): Promise<void> {
|
||||||
throw new Error("Unimplemented");
|
throw new Error("Unimplemented");
|
||||||
}
|
}
|
||||||
|
|
|
@ -44,6 +44,7 @@ import {RoomListStoreTempProxy} from "../../../stores/room-list/RoomListStoreTem
|
||||||
import {DefaultTagID} from "../../../stores/room-list/models";
|
import {DefaultTagID} from "../../../stores/room-list/models";
|
||||||
import * as Unread from "../../../Unread";
|
import * as Unread from "../../../Unread";
|
||||||
import RoomViewStore from "../../../stores/RoomViewStore";
|
import RoomViewStore from "../../../stores/RoomViewStore";
|
||||||
|
import {TAG_DM} from "../../../stores/RoomListStore";
|
||||||
|
|
||||||
const HIDE_CONFERENCE_CHANS = true;
|
const HIDE_CONFERENCE_CHANS = true;
|
||||||
const STANDARD_TAGS_REGEX = /^(m\.(favourite|lowpriority|server_notice)|im\.vector\.fake\.(invite|recent|direct|archived))$/;
|
const STANDARD_TAGS_REGEX = /^(m\.(favourite|lowpriority|server_notice)|im\.vector\.fake\.(invite|recent|direct|archived))$/;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
Copyright 2019 The Matrix.org Foundation C.I.C.
|
Copyright 2019, 2020 The Matrix.org Foundation C.I.C.
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
you may not use this file except in compliance with the License.
|
you may not use this file except in compliance with the License.
|
||||||
|
@ -20,7 +20,7 @@ export interface MatrixEvent {
|
||||||
content: {};
|
content: {};
|
||||||
event_id: string;
|
event_id: string;
|
||||||
origin_server_ts: number;
|
origin_server_ts: number;
|
||||||
unsigned: ?{};
|
unsigned?: {};
|
||||||
room_id: string;
|
room_id: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -59,7 +59,7 @@ export interface SearchArgs {
|
||||||
before_limit: number;
|
before_limit: number;
|
||||||
after_limit: number;
|
after_limit: number;
|
||||||
order_by_recency: boolean;
|
order_by_recency: boolean;
|
||||||
room_id: ?string;
|
room_id?: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface EventAndProfile {
|
export interface EventAndProfile {
|
||||||
|
@ -85,7 +85,7 @@ export interface IndexStats {
|
||||||
*
|
*
|
||||||
* Instances of this class are provided by the application.
|
* Instances of this class are provided by the application.
|
||||||
*/
|
*/
|
||||||
export default class BaseEventIndexManager {
|
export default abstract class BaseEventIndexManager {
|
||||||
/**
|
/**
|
||||||
* Does our EventIndexManager support event indexing.
|
* Does our EventIndexManager support event indexing.
|
||||||
*
|
*
|
||||||
|
@ -119,7 +119,7 @@ export default class BaseEventIndexManager {
|
||||||
* @return {Promise} A promise that will resolve when the was queued up for
|
* @return {Promise} A promise that will resolve when the was queued up for
|
||||||
* addition.
|
* addition.
|
||||||
*/
|
*/
|
||||||
async addEventToIndex(ev: MatrixEvent, profile: MatrixProfile): Promise<> {
|
async addEventToIndex(ev: MatrixEvent, profile: MatrixProfile): Promise<void> {
|
||||||
throw new Error("Unimplemented");
|
throw new Error("Unimplemented");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -188,7 +188,7 @@ export default class BaseEventIndexManager {
|
||||||
events: [EventAndProfile],
|
events: [EventAndProfile],
|
||||||
checkpoint: CrawlerCheckpoint | null,
|
checkpoint: CrawlerCheckpoint | null,
|
||||||
oldCheckpoint: CrawlerCheckpoint | null,
|
oldCheckpoint: CrawlerCheckpoint | null,
|
||||||
): Promise<bool> {
|
): Promise<boolean> {
|
||||||
throw new Error("Unimplemented");
|
throw new Error("Unimplemented");
|
||||||
}
|
}
|
||||||
|
|
|
@ -5765,7 +5765,7 @@ mathml-tag-names@^2.0.1:
|
||||||
|
|
||||||
"matrix-js-sdk@github:matrix-org/matrix-js-sdk#develop":
|
"matrix-js-sdk@github:matrix-org/matrix-js-sdk#develop":
|
||||||
version "6.1.0"
|
version "6.1.0"
|
||||||
resolved "https://codeload.github.com/matrix-org/matrix-js-sdk/tar.gz/e3c6a0e1a08a3812ba988e60eb5a2a013bb27404"
|
resolved "https://codeload.github.com/matrix-org/matrix-js-sdk/tar.gz/a4a7097c103da42075f2c70e070fd01fa6fb0d48"
|
||||||
dependencies:
|
dependencies:
|
||||||
"@babel/runtime" "^7.8.3"
|
"@babel/runtime" "^7.8.3"
|
||||||
another-json "^0.2.0"
|
another-json "^0.2.0"
|
||||||
|
|
Loading…
Reference in a new issue