Switch to importing models/{event-timeline{,set},user,device,event-status} from main js-sdk export (#11368)

This commit is contained in:
Michael Telatynski 2023-08-08 08:16:04 +01:00 committed by GitHub
parent b08bdf7e0d
commit 368b6b9355
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
40 changed files with 106 additions and 73 deletions

View file

@ -82,6 +82,26 @@ module.exports = {
name: "matrix-js-sdk/src/models/event", name: "matrix-js-sdk/src/models/event",
message: "Please use matrix-js-sdk/src/matrix instead", message: "Please use matrix-js-sdk/src/matrix instead",
}, },
{
name: "matrix-js-sdk/src/models/event-status",
message: "Please use matrix-js-sdk/src/matrix instead",
},
{
name: "matrix-js-sdk/src/models/user",
message: "Please use matrix-js-sdk/src/matrix instead",
},
{
name: "matrix-js-sdk/src/models/device",
message: "Please use matrix-js-sdk/src/matrix instead",
},
{
name: "matrix-js-sdk/src/models/event-timeline",
message: "Please use matrix-js-sdk/src/matrix instead",
},
{
name: "matrix-js-sdk/src/models/event-timeline-set",
message: "Please use matrix-js-sdk/src/matrix instead",
},
{ {
name: "matrix-react-sdk", name: "matrix-react-sdk",
message: "Please use matrix-react-sdk/src/index instead", message: "Please use matrix-react-sdk/src/index instead",

View file

@ -17,12 +17,17 @@ See the License for the specific language governing permissions and
limitations under the License. limitations under the License.
*/ */
import { ICreateClientOpts, PendingEventOrdering, RoomNameState, RoomNameType } from "matrix-js-sdk/src/matrix"; import {
ICreateClientOpts,
PendingEventOrdering,
RoomNameState,
RoomNameType,
EventTimeline,
EventTimelineSet,
} from "matrix-js-sdk/src/matrix";
import { IStartClientOpts, MatrixClient } from "matrix-js-sdk/src/client"; import { IStartClientOpts, MatrixClient } from "matrix-js-sdk/src/client";
import { MemoryStore } from "matrix-js-sdk/src/store/memory"; import { MemoryStore } from "matrix-js-sdk/src/store/memory";
import * as utils from "matrix-js-sdk/src/utils"; import * as utils from "matrix-js-sdk/src/utils";
import { EventTimeline } from "matrix-js-sdk/src/models/event-timeline";
import { EventTimelineSet } from "matrix-js-sdk/src/models/event-timeline-set";
import { verificationMethods } from "matrix-js-sdk/src/crypto"; import { verificationMethods } from "matrix-js-sdk/src/crypto";
import { SHOW_QR_CODE_METHOD } from "matrix-js-sdk/src/crypto/verification/QRCode"; import { SHOW_QR_CODE_METHOD } from "matrix-js-sdk/src/crypto/verification/QRCode";
import { logger } from "matrix-js-sdk/src/logger"; import { logger } from "matrix-js-sdk/src/logger";

View file

@ -18,11 +18,9 @@ limitations under the License.
*/ */
import * as React from "react"; import * as React from "react";
import { User } from "matrix-js-sdk/src/models/user"; import { User, IContent, Direction } from "matrix-js-sdk/src/matrix";
import { Direction } from "matrix-js-sdk/src/models/event-timeline";
import * as ContentHelpers from "matrix-js-sdk/src/content-helpers"; import * as ContentHelpers from "matrix-js-sdk/src/content-helpers";
import { logger } from "matrix-js-sdk/src/logger"; import { logger } from "matrix-js-sdk/src/logger";
import { IContent } from "matrix-js-sdk/src/matrix";
import { MRoomTopicEventContent } from "matrix-js-sdk/src/@types/topic"; import { MRoomTopicEventContent } from "matrix-js-sdk/src/@types/topic";
import dis from "./dispatcher/dispatcher"; import dis from "./dispatcher/dispatcher";

View file

@ -19,8 +19,15 @@ limitations under the License.
import React from "react"; import React from "react";
import { sortBy } from "lodash"; import { sortBy } from "lodash";
import { MatrixEvent, Room, RoomEvent, RoomMember, RoomState, RoomStateEvent } from "matrix-js-sdk/src/matrix"; import {
import { IRoomTimelineData } from "matrix-js-sdk/src/models/event-timeline-set"; MatrixEvent,
Room,
RoomEvent,
RoomMember,
RoomState,
RoomStateEvent,
IRoomTimelineData,
} from "matrix-js-sdk/src/matrix";
import { MatrixClientPeg } from "../MatrixClientPeg"; import { MatrixClientPeg } from "../MatrixClientPeg";
import QueryMatcher from "./QueryMatcher"; import QueryMatcher from "./QueryMatcher";

View file

@ -17,9 +17,15 @@ limitations under the License.
import React, { createRef } from "react"; import React, { createRef } from "react";
import { Filter } from "matrix-js-sdk/src/filter"; import { Filter } from "matrix-js-sdk/src/filter";
import { EventTimelineSet, IRoomTimelineData } from "matrix-js-sdk/src/models/event-timeline-set"; import {
import { Direction } from "matrix-js-sdk/src/models/event-timeline"; EventTimelineSet,
import { MatrixEvent, MatrixEventEvent, Room, RoomEvent } from "matrix-js-sdk/src/matrix"; IRoomTimelineData,
Direction,
MatrixEvent,
MatrixEventEvent,
Room,
RoomEvent,
} from "matrix-js-sdk/src/matrix";
import { TimelineWindow } from "matrix-js-sdk/src/timeline-window"; import { TimelineWindow } from "matrix-js-sdk/src/timeline-window";
import { logger } from "matrix-js-sdk/src/logger"; import { logger } from "matrix-js-sdk/src/logger";

View file

@ -28,9 +28,10 @@ import {
RoomStateEvent, RoomStateEvent,
MatrixEvent, MatrixEvent,
MatrixEventEvent, MatrixEventEvent,
EventTimeline,
IRoomTimelineData,
} from "matrix-js-sdk/src/matrix"; } from "matrix-js-sdk/src/matrix";
import { logger } from "matrix-js-sdk/src/logger"; import { logger } from "matrix-js-sdk/src/logger";
import { EventTimeline } from "matrix-js-sdk/src/models/event-timeline";
import { EventType } from "matrix-js-sdk/src/@types/event"; import { EventType } from "matrix-js-sdk/src/@types/event";
import { CallState, MatrixCall } from "matrix-js-sdk/src/webrtc/call"; import { CallState, MatrixCall } from "matrix-js-sdk/src/webrtc/call";
import { throttle } from "lodash"; import { throttle } from "lodash";
@ -40,7 +41,6 @@ import { CryptoEvent } from "matrix-js-sdk/src/crypto";
import { THREAD_RELATION_TYPE } from "matrix-js-sdk/src/models/thread"; import { THREAD_RELATION_TYPE } from "matrix-js-sdk/src/models/thread";
import { HistoryVisibility, JoinRule } from "matrix-js-sdk/src/@types/partials"; import { HistoryVisibility, JoinRule } from "matrix-js-sdk/src/@types/partials";
import { ISearchResults } from "matrix-js-sdk/src/@types/search"; import { ISearchResults } from "matrix-js-sdk/src/@types/search";
import { IRoomTimelineData } from "matrix-js-sdk/src/models/event-timeline-set";
import shouldHideEvent from "../../shouldHideEvent"; import shouldHideEvent from "../../shouldHideEvent";
import { _t } from "../../languageHandler"; import { _t } from "../../languageHandler";

View file

@ -16,9 +16,8 @@ limitations under the License.
import { Optional } from "matrix-events-sdk"; import { Optional } from "matrix-events-sdk";
import React, { useContext, useEffect, useRef, useState } from "react"; import React, { useContext, useEffect, useRef, useState } from "react";
import { EventTimelineSet } from "matrix-js-sdk/src/models/event-timeline-set"; import { EventTimelineSet, Room } from "matrix-js-sdk/src/matrix";
import { Thread } from "matrix-js-sdk/src/models/thread"; import { Thread } from "matrix-js-sdk/src/models/thread";
import { Room } from "matrix-js-sdk/src/matrix";
import BaseCard from "../views/right_panel/BaseCard"; import BaseCard from "../views/right_panel/BaseCard";
import ResizeNotifier from "../../utils/ResizeNotifier"; import ResizeNotifier from "../../utils/ResizeNotifier";

View file

@ -16,9 +16,18 @@ limitations under the License.
import React, { createRef, ReactNode } from "react"; import React, { createRef, ReactNode } from "react";
import ReactDOM from "react-dom"; import ReactDOM from "react-dom";
import { Room, RoomEvent, RoomMember, RoomMemberEvent, MatrixEvent, MatrixEventEvent } from "matrix-js-sdk/src/matrix"; import {
import { EventTimelineSet, IRoomTimelineData } from "matrix-js-sdk/src/models/event-timeline-set"; Room,
import { Direction, EventTimeline } from "matrix-js-sdk/src/models/event-timeline"; RoomEvent,
RoomMember,
RoomMemberEvent,
MatrixEvent,
MatrixEventEvent,
EventTimelineSet,
IRoomTimelineData,
Direction,
EventTimeline,
} from "matrix-js-sdk/src/matrix";
import { TimelineWindow } from "matrix-js-sdk/src/timeline-window"; import { TimelineWindow } from "matrix-js-sdk/src/timeline-window";
import { EventType, RelationType } from "matrix-js-sdk/src/@types/event"; import { EventType, RelationType } from "matrix-js-sdk/src/@types/event";
import { SyncState } from "matrix-js-sdk/src/sync"; import { SyncState } from "matrix-js-sdk/src/sync";

View file

@ -16,8 +16,7 @@ limitations under the License.
import React from "react"; import React from "react";
import classNames from "classnames"; import classNames from "classnames";
import { Room, RoomEvent, MatrixEvent } from "matrix-js-sdk/src/matrix"; import { Room, RoomEvent, MatrixEvent, User, UserEvent } from "matrix-js-sdk/src/matrix";
import { User, UserEvent } from "matrix-js-sdk/src/models/user";
import { EventType } from "matrix-js-sdk/src/@types/event"; import { EventType } from "matrix-js-sdk/src/@types/event";
import { JoinRule } from "matrix-js-sdk/src/@types/partials"; import { JoinRule } from "matrix-js-sdk/src/@types/partials";
import { UnstableValue } from "matrix-js-sdk/src/NamespacedValue"; import { UnstableValue } from "matrix-js-sdk/src/NamespacedValue";

View file

@ -17,8 +17,7 @@ limitations under the License.
import React, { useState } from "react"; import React, { useState } from "react";
import { logger } from "matrix-js-sdk/src/logger"; import { logger } from "matrix-js-sdk/src/logger";
import { MatrixClient } from "matrix-js-sdk/src/client"; import { MatrixClient } from "matrix-js-sdk/src/client";
import { RoomMember, Room, MatrixEvent } from "matrix-js-sdk/src/matrix"; import { RoomMember, Room, MatrixEvent, EventTimeline } from "matrix-js-sdk/src/matrix";
import { EventTimeline } from "matrix-js-sdk/src/models/event-timeline";
import { EventType } from "matrix-js-sdk/src/@types/event"; import { EventType } from "matrix-js-sdk/src/@types/event";
import { _t } from "../../../languageHandler"; import { _t } from "../../../languageHandler";

View file

@ -19,7 +19,7 @@ limitations under the License.
*/ */
import React, { useCallback } from "react"; import React, { useCallback } from "react";
import { Device } from "matrix-js-sdk/src/models/device"; import { Device } from "matrix-js-sdk/src/matrix";
import * as FormattingUtils from "../../../utils/FormattingUtils"; import * as FormattingUtils from "../../../utils/FormattingUtils";
import { _t } from "../../../languageHandler"; import { _t } from "../../../languageHandler";

View file

@ -16,8 +16,7 @@ limitations under the License.
*/ */
import * as React from "react"; import * as React from "react";
import { Room, RoomMember, MatrixEvent } from "matrix-js-sdk/src/matrix"; import { Room, RoomMember, MatrixEvent, User } from "matrix-js-sdk/src/matrix";
import { User } from "matrix-js-sdk/src/models/user";
import { _t } from "../../../languageHandler"; import { _t } from "../../../languageHandler";
import QRCode from "../elements/QRCode"; import QRCode from "../elements/QRCode";

View file

@ -15,7 +15,7 @@ limitations under the License.
*/ */
import React from "react"; import React from "react";
import { User } from "matrix-js-sdk/src/models/user"; import { User } from "matrix-js-sdk/src/matrix";
import { _t } from "../../../languageHandler"; import { _t } from "../../../languageHandler";
import { MatrixClientPeg } from "../../../MatrixClientPeg"; import { MatrixClientPeg } from "../../../MatrixClientPeg";

View file

@ -16,7 +16,7 @@ limitations under the License.
import React from "react"; import React from "react";
import { VerificationRequest } from "matrix-js-sdk/src/crypto-api"; import { VerificationRequest } from "matrix-js-sdk/src/crypto-api";
import { User } from "matrix-js-sdk/src/models/user"; import { User } from "matrix-js-sdk/src/matrix";
import { MatrixClientPeg } from "../../../MatrixClientPeg"; import { MatrixClientPeg } from "../../../MatrixClientPeg";
import { _t } from "../../../languageHandler"; import { _t } from "../../../languageHandler";

View file

@ -16,7 +16,7 @@ limitations under the License.
*/ */
import React from "react"; import React from "react";
import { Direction } from "matrix-js-sdk/src/models/event-timeline"; import { Direction } from "matrix-js-sdk/src/matrix";
import { logger } from "matrix-js-sdk/src/logger"; import { logger } from "matrix-js-sdk/src/logger";
import { ConnectionError, MatrixError, HTTPError } from "matrix-js-sdk/src/http-api"; import { ConnectionError, MatrixError, HTTPError } from "matrix-js-sdk/src/http-api";

View file

@ -15,8 +15,7 @@ limitations under the License.
*/ */
import React from "react"; import React from "react";
import { RoomMember } from "matrix-js-sdk/src/matrix"; import { RoomMember, User } from "matrix-js-sdk/src/matrix";
import { User } from "matrix-js-sdk/src/models/user";
import { _t } from "../../../languageHandler"; import { _t } from "../../../languageHandler";
import AccessibleButton from "../elements/AccessibleButton"; import AccessibleButton from "../elements/AccessibleButton";

View file

@ -16,8 +16,7 @@ limitations under the License.
import React, { useCallback, useEffect, useState } from "react"; import React, { useCallback, useEffect, useState } from "react";
import { VerificationPhase, VerificationRequest, VerificationRequestEvent } from "matrix-js-sdk/src/crypto-api"; import { VerificationPhase, VerificationRequest, VerificationRequestEvent } from "matrix-js-sdk/src/crypto-api";
import { RoomMember } from "matrix-js-sdk/src/matrix"; import { RoomMember, User } from "matrix-js-sdk/src/matrix";
import { User } from "matrix-js-sdk/src/models/user";
import EncryptionInfo from "./EncryptionInfo"; import EncryptionInfo from "./EncryptionInfo";
import VerificationPanel from "./VerificationPanel"; import VerificationPanel from "./VerificationPanel";

View file

@ -15,8 +15,7 @@ limitations under the License.
*/ */
import React from "react"; import React from "react";
import { IEventRelation, MatrixEvent, NotificationCountType, Room } from "matrix-js-sdk/src/matrix"; import { IEventRelation, MatrixEvent, NotificationCountType, Room, EventTimelineSet } from "matrix-js-sdk/src/matrix";
import { EventTimelineSet } from "matrix-js-sdk/src/models/event-timeline-set";
import { Thread } from "matrix-js-sdk/src/models/thread"; import { Thread } from "matrix-js-sdk/src/models/thread";
import BaseCard from "./BaseCard"; import BaseCard from "./BaseCard";

View file

@ -20,14 +20,12 @@ limitations under the License.
import React, { ReactNode, useCallback, useContext, useEffect, useMemo, useState } from "react"; import React, { ReactNode, useCallback, useContext, useEffect, useMemo, useState } from "react";
import classNames from "classnames"; import classNames from "classnames";
import { ClientEvent, MatrixClient } from "matrix-js-sdk/src/client"; import { ClientEvent, MatrixClient } from "matrix-js-sdk/src/client";
import { RoomMember, Room, RoomStateEvent, MatrixEvent } from "matrix-js-sdk/src/matrix"; import { RoomMember, Room, RoomStateEvent, MatrixEvent, User, Device } from "matrix-js-sdk/src/matrix";
import { User } from "matrix-js-sdk/src/models/user";
import { VerificationRequest } from "matrix-js-sdk/src/crypto-api"; import { VerificationRequest } from "matrix-js-sdk/src/crypto-api";
import { EventType } from "matrix-js-sdk/src/@types/event"; import { EventType } from "matrix-js-sdk/src/@types/event";
import { logger } from "matrix-js-sdk/src/logger"; import { logger } from "matrix-js-sdk/src/logger";
import { CryptoEvent } from "matrix-js-sdk/src/crypto"; import { CryptoEvent } from "matrix-js-sdk/src/crypto";
import { UserTrustLevel } from "matrix-js-sdk/src/crypto/CrossSigning"; import { UserTrustLevel } from "matrix-js-sdk/src/crypto/CrossSigning";
import { Device } from "matrix-js-sdk/src/models/device";
import dis from "../../../dispatcher/dispatcher"; import dis from "../../../dispatcher/dispatcher";
import Modal from "../../../Modal"; import Modal from "../../../Modal";

View file

@ -22,8 +22,7 @@ import {
VerificationRequest, VerificationRequest,
VerificationRequestEvent, VerificationRequestEvent,
} from "matrix-js-sdk/src/crypto-api"; } from "matrix-js-sdk/src/crypto-api";
import { RoomMember, Device } from "matrix-js-sdk/src/matrix"; import { RoomMember, Device, User } from "matrix-js-sdk/src/matrix";
import { User } from "matrix-js-sdk/src/models/user";
import { logger } from "matrix-js-sdk/src/logger"; import { logger } from "matrix-js-sdk/src/logger";
import { ShowQrCodeCallbacks, ShowSasCallbacks, VerifierEvent } from "matrix-js-sdk/src/crypto-api/verification"; import { ShowQrCodeCallbacks, ShowSasCallbacks, VerifierEvent } from "matrix-js-sdk/src/crypto-api/verification";

View file

@ -15,7 +15,7 @@ limitations under the License.
*/ */
import React, { useContext } from "react"; import React, { useContext } from "react";
import { EventTimeline } from "matrix-js-sdk/src/models/event-timeline"; import { EventTimeline } from "matrix-js-sdk/src/matrix";
import EventTileBubble from "../messages/EventTileBubble"; import EventTileBubble from "../messages/EventTileBubble";
import RoomContext from "../../../contexts/RoomContext"; import RoomContext from "../../../contexts/RoomContext";

View file

@ -26,8 +26,9 @@ import {
RoomMemberEvent, RoomMemberEvent,
RoomState, RoomState,
RoomStateEvent, RoomStateEvent,
User,
UserEvent,
} from "matrix-js-sdk/src/matrix"; } from "matrix-js-sdk/src/matrix";
import { User, UserEvent } from "matrix-js-sdk/src/models/user";
import { throttle } from "lodash"; import { throttle } from "lodash";
import { JoinRule } from "matrix-js-sdk/src/@types/partials"; import { JoinRule } from "matrix-js-sdk/src/@types/partials";
import { ClientEvent } from "matrix-js-sdk/src/client"; import { ClientEvent } from "matrix-js-sdk/src/client";

View file

@ -17,8 +17,7 @@ limitations under the License.
import React, { useContext } from "react"; import React, { useContext } from "react";
import { EventType } from "matrix-js-sdk/src/@types/event"; import { EventType } from "matrix-js-sdk/src/@types/event";
import { MatrixClient } from "matrix-js-sdk/src/client"; import { MatrixClient } from "matrix-js-sdk/src/client";
import { Room } from "matrix-js-sdk/src/matrix"; import { Room, User } from "matrix-js-sdk/src/matrix";
import { User } from "matrix-js-sdk/src/models/user";
import MatrixClientContext from "../../../contexts/MatrixClientContext"; import MatrixClientContext from "../../../contexts/MatrixClientContext";
import RoomContext from "../../../contexts/RoomContext"; import RoomContext from "../../../contexts/RoomContext";

View file

@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
limitations under the License. limitations under the License.
*/ */
import { User } from "matrix-js-sdk/src/models/user"; import { User } from "matrix-js-sdk/src/matrix";
import { ActionPayload } from "../payloads"; import { ActionPayload } from "../payloads";
import { Action } from "../actions"; import { Action } from "../actions";

View file

@ -14,8 +14,7 @@ See the License for the specific language governing permissions and
limitations under the License. limitations under the License.
*/ */
import { RoomMember } from "matrix-js-sdk/src/matrix"; import { RoomMember, User } from "matrix-js-sdk/src/matrix";
import { User } from "matrix-js-sdk/src/models/user";
import { ActionPayload } from "../payloads"; import { ActionPayload } from "../payloads";
import { Action } from "../actions"; import { Action } from "../actions";

View file

@ -15,9 +15,18 @@ limitations under the License.
*/ */
import { EventEmitter } from "events"; import { EventEmitter } from "events";
import { RoomMember, Room, RoomEvent, RoomState, RoomStateEvent, MatrixEvent } from "matrix-js-sdk/src/matrix"; import {
import { Direction, EventTimeline } from "matrix-js-sdk/src/models/event-timeline"; RoomMember,
import { EventTimelineSet, IRoomTimelineData } from "matrix-js-sdk/src/models/event-timeline-set"; Room,
RoomEvent,
RoomState,
RoomStateEvent,
MatrixEvent,
Direction,
EventTimeline,
EventTimelineSet,
IRoomTimelineData,
} from "matrix-js-sdk/src/matrix";
import { TimelineIndex, TimelineWindow } from "matrix-js-sdk/src/timeline-window"; import { TimelineIndex, TimelineWindow } from "matrix-js-sdk/src/timeline-window";
import { sleep } from "matrix-js-sdk/src/utils"; import { sleep } from "matrix-js-sdk/src/utils";
import { IEventWithRoomId, IMatrixProfile, IResultRoomEvents } from "matrix-js-sdk/src/@types/search"; import { IEventWithRoomId, IMatrixProfile, IResultRoomEvents } from "matrix-js-sdk/src/@types/search";

View file

@ -14,8 +14,7 @@ See the License for the specific language governing permissions and
limitations under the License. limitations under the License.
*/ */
import { MatrixEvent, RoomStateEvent, MatrixError } from "matrix-js-sdk/src/matrix"; import { MatrixEvent, RoomStateEvent, MatrixError, User, UserEvent } from "matrix-js-sdk/src/matrix";
import { User, UserEvent } from "matrix-js-sdk/src/models/user";
import { throttle } from "lodash"; import { throttle } from "lodash";
import { EventType } from "matrix-js-sdk/src/@types/event"; import { EventType } from "matrix-js-sdk/src/@types/event";

View file

@ -20,7 +20,7 @@ import { IKeyBackupInfo } from "matrix-js-sdk/src/crypto/keybackup";
import { ISecretStorageKeyInfo } from "matrix-js-sdk/src/crypto/api"; import { ISecretStorageKeyInfo } from "matrix-js-sdk/src/crypto/api";
import { logger } from "matrix-js-sdk/src/logger"; import { logger } from "matrix-js-sdk/src/logger";
import { CryptoEvent } from "matrix-js-sdk/src/crypto"; import { CryptoEvent } from "matrix-js-sdk/src/crypto";
import { Device } from "matrix-js-sdk/src/models/device"; import { Device } from "matrix-js-sdk/src/matrix";
import { MatrixClientPeg } from "../MatrixClientPeg"; import { MatrixClientPeg } from "../MatrixClientPeg";
import { AccessCancelledError, accessSecretStorage } from "../SecurityManager"; import { AccessCancelledError, accessSecretStorage } from "../SecurityManager";

View file

@ -14,8 +14,7 @@ See the License for the specific language governing permissions and
limitations under the License. limitations under the License.
*/ */
import { MatrixEvent, Room, RoomMember } from "matrix-js-sdk/src/matrix"; import { MatrixEvent, Room, RoomMember, User } from "matrix-js-sdk/src/matrix";
import { User } from "matrix-js-sdk/src/models/user";
import { VerificationRequest } from "matrix-js-sdk/src/crypto-api"; import { VerificationRequest } from "matrix-js-sdk/src/crypto-api";
import { RightPanelPhases } from "./RightPanelStorePhases"; import { RightPanelPhases } from "./RightPanelStorePhases";

View file

@ -14,8 +14,7 @@ See the License for the specific language governing permissions and
limitations under the License. limitations under the License.
*/ */
import { MatrixEvent, Room } from "matrix-js-sdk/src/matrix"; import { MatrixEvent, Room, Direction } from "matrix-js-sdk/src/matrix";
import { Direction } from "matrix-js-sdk/src/models/event-timeline";
import { saveAs } from "file-saver"; import { saveAs } from "file-saver";
import { logger } from "matrix-js-sdk/src/logger"; import { logger } from "matrix-js-sdk/src/logger";
import sanitizeFilename from "sanitize-filename"; import sanitizeFilename from "sanitize-filename";

View file

@ -16,8 +16,7 @@ limitations under the License.
import { sleep } from "matrix-js-sdk/src/utils"; import { sleep } from "matrix-js-sdk/src/utils";
import React, { ReactNode } from "react"; import React, { ReactNode } from "react";
import { EventStatus } from "matrix-js-sdk/src/models/event-status"; import { EventStatus, MatrixEventEvent, Room, MatrixClient, MatrixError } from "matrix-js-sdk/src/matrix";
import { MatrixEventEvent, Room, MatrixClient, MatrixError } from "matrix-js-sdk/src/matrix";
import Modal, { IHandle } from "../Modal"; import Modal, { IHandle } from "../Modal";
import Spinner from "../components/views/elements/Spinner"; import Spinner from "../components/views/elements/Spinner";

View file

@ -14,9 +14,8 @@ See the License for the specific language governing permissions and
limitations under the License. limitations under the License.
*/ */
import { User } from "matrix-js-sdk/src/models/user"; import { User, MatrixClient, RoomMember } from "matrix-js-sdk/src/matrix";
import { verificationMethods as VerificationMethods } from "matrix-js-sdk/src/crypto"; import { verificationMethods as VerificationMethods } from "matrix-js-sdk/src/crypto";
import { MatrixClient, RoomMember } from "matrix-js-sdk/src/matrix";
import { CrossSigningKey, VerificationRequest } from "matrix-js-sdk/src/crypto-api"; import { CrossSigningKey, VerificationRequest } from "matrix-js-sdk/src/crypto-api";
import dis from "./dispatcher/dispatcher"; import dis from "./dispatcher/dispatcher";

View file

@ -15,12 +15,11 @@ limitations under the License.
*/ */
import { Mocked, mocked } from "jest-mock"; import { Mocked, mocked } from "jest-mock";
import { MatrixEvent, Room, MatrixClient, DeviceVerificationStatus, CryptoApi } from "matrix-js-sdk/src/matrix"; import { MatrixEvent, Room, MatrixClient, DeviceVerificationStatus, CryptoApi, Device } from "matrix-js-sdk/src/matrix";
import { logger } from "matrix-js-sdk/src/logger"; import { logger } from "matrix-js-sdk/src/logger";
import { CrossSigningInfo } from "matrix-js-sdk/src/crypto/CrossSigning"; import { CrossSigningInfo } from "matrix-js-sdk/src/crypto/CrossSigning";
import { CryptoEvent } from "matrix-js-sdk/src/crypto"; import { CryptoEvent } from "matrix-js-sdk/src/crypto";
import { IKeyBackupInfo } from "matrix-js-sdk/src/crypto/keybackup"; import { IKeyBackupInfo } from "matrix-js-sdk/src/crypto/keybackup";
import { Device } from "matrix-js-sdk/src/models/device";
import DeviceListener from "../src/DeviceListener"; import DeviceListener from "../src/DeviceListener";
import { MatrixClientPeg } from "../src/MatrixClientPeg"; import { MatrixClientPeg } from "../src/MatrixClientPeg";

View file

@ -28,8 +28,8 @@ import {
RoomMember, RoomMember,
RoomState, RoomState,
TimelineWindow, TimelineWindow,
EventTimeline,
} from "matrix-js-sdk/src/matrix"; } from "matrix-js-sdk/src/matrix";
import { EventTimeline } from "matrix-js-sdk/src/models/event-timeline";
import { import {
FeatureSupport, FeatureSupport,
Thread, Thread,

View file

@ -16,7 +16,7 @@
import React from "react"; import React from "react";
import { render, screen } from "@testing-library/react"; import { render, screen } from "@testing-library/react";
import { Device } from "matrix-js-sdk/src/models/device"; import { Device } from "matrix-js-sdk/src/matrix";
import { MatrixClient } from "matrix-js-sdk/src/client"; import { MatrixClient } from "matrix-js-sdk/src/client";
import { stubClient } from "../../../test-utils"; import { stubClient } from "../../../test-utils";

View file

@ -27,6 +27,7 @@ import {
EventType, EventType,
CryptoApi, CryptoApi,
DeviceVerificationStatus, DeviceVerificationStatus,
Device,
} from "matrix-js-sdk/src/matrix"; } from "matrix-js-sdk/src/matrix";
import { import {
Phase, Phase,
@ -34,7 +35,6 @@ import {
VerificationRequestEvent, VerificationRequestEvent,
} from "matrix-js-sdk/src/crypto/verification/request/VerificationRequest"; } from "matrix-js-sdk/src/crypto/verification/request/VerificationRequest";
import { UserTrustLevel } from "matrix-js-sdk/src/crypto/CrossSigning"; import { UserTrustLevel } from "matrix-js-sdk/src/crypto/CrossSigning";
import { Device } from "matrix-js-sdk/src/models/device";
import { defer } from "matrix-js-sdk/src/utils"; import { defer } from "matrix-js-sdk/src/utils";
import { EventEmitter } from "events"; import { EventEmitter } from "events";

View file

@ -16,7 +16,7 @@ limitations under the License.
import { act, render, waitFor } from "@testing-library/react"; import { act, render, waitFor } from "@testing-library/react";
import React, { ComponentProps } from "react"; import React, { ComponentProps } from "react";
import { User } from "matrix-js-sdk/src/models/user"; import { User, TypedEventEmitter, Device, MatrixClient } from "matrix-js-sdk/src/matrix";
import { mocked, Mocked } from "jest-mock"; import { mocked, Mocked } from "jest-mock";
import { import {
EmojiMapping, EmojiMapping,
@ -28,7 +28,6 @@ import {
VerifierEvent, VerifierEvent,
VerifierEventHandlerMap, VerifierEventHandlerMap,
} from "matrix-js-sdk/src/crypto-api/verification"; } from "matrix-js-sdk/src/crypto-api/verification";
import { TypedEventEmitter, Device, MatrixClient } from "matrix-js-sdk/src/matrix";
import VerificationPanel from "../../../../src/components/views/right_panel/VerificationPanel"; import VerificationPanel from "../../../../src/components/views/right_panel/VerificationPanel";
import { flushPromises, stubClient } from "../../../test-utils"; import { flushPromises, stubClient } from "../../../test-utils";

View file

@ -17,8 +17,7 @@ limitations under the License.
import React from "react"; import React from "react";
import { act, render, RenderResult } from "@testing-library/react"; import { act, render, RenderResult } from "@testing-library/react";
import { Room, MatrixClient, RoomState, RoomMember } from "matrix-js-sdk/src/matrix"; import { Room, MatrixClient, RoomState, RoomMember, User } from "matrix-js-sdk/src/matrix";
import { User } from "matrix-js-sdk/src/models/user";
import { compare } from "matrix-js-sdk/src/utils"; import { compare } from "matrix-js-sdk/src/utils";
import { MatrixClientPeg } from "../../../../src/MatrixClientPeg"; import { MatrixClientPeg } from "../../../../src/MatrixClientPeg";

View file

@ -17,9 +17,8 @@ limitations under the License.
import React from "react"; import React from "react";
import "jest-mock"; import "jest-mock";
import { screen, act, render } from "@testing-library/react"; import { screen, act, render } from "@testing-library/react";
import { MatrixEvent, MsgType, RelationType, NotificationCountType, Room } from "matrix-js-sdk/src/matrix"; import { MatrixEvent, MsgType, RelationType, NotificationCountType, Room, EventStatus } from "matrix-js-sdk/src/matrix";
import { PendingEventOrdering } from "matrix-js-sdk/src/client"; import { PendingEventOrdering } from "matrix-js-sdk/src/client";
import { EventStatus } from "matrix-js-sdk/src/models/event-status";
import { ReceiptType } from "matrix-js-sdk/src/@types/read_receipts"; import { ReceiptType } from "matrix-js-sdk/src/@types/read_receipts";
import type { MatrixClient } from "matrix-js-sdk/src/client"; import type { MatrixClient } from "matrix-js-sdk/src/client";

View file

@ -16,9 +16,8 @@ limitations under the License.
import { mocked, Mocked } from "jest-mock"; import { mocked, Mocked } from "jest-mock";
import { IBootstrapCrossSigningOpts } from "matrix-js-sdk/src/crypto"; import { IBootstrapCrossSigningOpts } from "matrix-js-sdk/src/crypto";
import { CryptoApi, DeviceVerificationStatus, MatrixClient } from "matrix-js-sdk/src/matrix"; import { CryptoApi, DeviceVerificationStatus, MatrixClient, Device } from "matrix-js-sdk/src/matrix";
import { SecretStorageKeyDescriptionAesV1, ServerSideSecretStorage } from "matrix-js-sdk/src/secret-storage"; import { SecretStorageKeyDescriptionAesV1, ServerSideSecretStorage } from "matrix-js-sdk/src/secret-storage";
import { Device } from "matrix-js-sdk/src/models/device";
import { IDehydratedDevice } from "matrix-js-sdk/src/crypto/dehydration"; import { IDehydratedDevice } from "matrix-js-sdk/src/crypto/dehydration";
import { SdkContextClass } from "../../src/contexts/SDKContext"; import { SdkContextClass } from "../../src/contexts/SDKContext";