diff --git a/playwright/e2e/crypto/crypto.spec.ts b/playwright/e2e/crypto/crypto.spec.ts index 9d9b461cb4..515cddbc1b 100644 --- a/playwright/e2e/crypto/crypto.spec.ts +++ b/playwright/e2e/crypto/crypto.spec.ts @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { KnownMembership } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import type { Page } from "@playwright/test"; import { test, expect } from "../../element-web-test"; diff --git a/playwright/e2e/crypto/verification.spec.ts b/playwright/e2e/crypto/verification.spec.ts index 15f1fff68e..0c8047f4a1 100644 --- a/playwright/e2e/crypto/verification.spec.ts +++ b/playwright/e2e/crypto/verification.spec.ts @@ -15,7 +15,8 @@ limitations under the License. */ import jsQR from "jsqr"; -import { KnownMembership, type Preset, type Visibility } from "matrix-js-sdk/src/matrix"; +import { type Preset, type Visibility } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import type { JSHandle, Locator, Page } from "@playwright/test"; import type { VerificationRequest, Verifier } from "matrix-js-sdk/src/crypto-api"; diff --git a/playwright/e2e/knock/knock-into-room.spec.ts b/playwright/e2e/knock/knock-into-room.spec.ts index c6eff9d6ee..ac552ede2f 100644 --- a/playwright/e2e/knock/knock-into-room.spec.ts +++ b/playwright/e2e/knock/knock-into-room.spec.ts @@ -16,7 +16,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { KnownMembership, type Visibility } from "matrix-js-sdk/src/matrix"; +import { type Visibility } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { test, expect } from "../../element-web-test"; import { waitForRoom } from "../utils"; diff --git a/playwright/e2e/knock/manage-knocks.spec.ts b/playwright/e2e/knock/manage-knocks.spec.ts index 82c1c33bb1..d1bf7ee92b 100644 --- a/playwright/e2e/knock/manage-knocks.spec.ts +++ b/playwright/e2e/knock/manage-knocks.spec.ts @@ -16,7 +16,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { KnownMembership } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { test, expect } from "../../element-web-test"; import { waitForRoom } from "../utils"; diff --git a/playwright/pages/bot.ts b/playwright/pages/bot.ts index 0144763db7..d9fbc717bb 100644 --- a/playwright/pages/bot.ts +++ b/playwright/pages/bot.ts @@ -16,7 +16,8 @@ limitations under the License. import { JSHandle, Page } from "@playwright/test"; import { uniqueId } from "lodash"; -import { KnownMembership, type MatrixClient } from "matrix-js-sdk/src/matrix"; +import { type MatrixClient } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import type { Logger } from "matrix-js-sdk/src/logger"; import type { SecretStorageKeyDescription } from "matrix-js-sdk/src/secret-storage"; diff --git a/src/ScalarMessaging.ts b/src/ScalarMessaging.ts index 8ca7010092..d9f67f87ef 100644 --- a/src/ScalarMessaging.ts +++ b/src/ScalarMessaging.ts @@ -291,7 +291,8 @@ Response: */ -import { IContent, MatrixEvent, IEvent, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { IContent, MatrixEvent, IEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import { MatrixClientPeg } from "./MatrixClientPeg"; diff --git a/src/SlashCommands.tsx b/src/SlashCommands.tsx index aa5ed4f320..59dffea88a 100644 --- a/src/SlashCommands.tsx +++ b/src/SlashCommands.tsx @@ -18,14 +18,8 @@ limitations under the License. */ import * as React from "react"; -import { - User, - IContent, - Direction, - ContentHelpers, - MRoomTopicEventContent, - KnownMembership, -} from "matrix-js-sdk/src/matrix"; +import { User, IContent, Direction, ContentHelpers, MRoomTopicEventContent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import dis from "./dispatcher/dispatcher"; diff --git a/src/TextForEvent.tsx b/src/TextForEvent.tsx index be85ac6473..96eb38f01b 100644 --- a/src/TextForEvent.tsx +++ b/src/TextForEvent.tsx @@ -25,8 +25,8 @@ import { MsgType, M_POLL_START, M_POLL_END, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import { removeDirectionOverrideChars } from "matrix-js-sdk/src/utils"; import { PollStartEvent } from "matrix-js-sdk/src/extensible_events_v1/PollStartEvent"; diff --git a/src/VoipUserMapper.ts b/src/VoipUserMapper.ts index 26080de4a2..09e7cbd1af 100644 --- a/src/VoipUserMapper.ts +++ b/src/VoipUserMapper.ts @@ -14,7 +14,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { Room, EventType, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { Room, EventType } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import { ensureVirtualRoomExists } from "./createRoom"; diff --git a/src/autocomplete/UserProvider.tsx b/src/autocomplete/UserProvider.tsx index 05788ce06a..f362ff75eb 100644 --- a/src/autocomplete/UserProvider.tsx +++ b/src/autocomplete/UserProvider.tsx @@ -27,8 +27,8 @@ import { RoomState, RoomStateEvent, IRoomTimelineData, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { MatrixClientPeg } from "../MatrixClientPeg"; import QueryMatcher from "./QueryMatcher"; diff --git a/src/components/structures/RoomView.tsx b/src/components/structures/RoomView.tsx index 412ef38e4c..8d625fffb4 100644 --- a/src/components/structures/RoomView.tsx +++ b/src/components/structures/RoomView.tsx @@ -37,8 +37,8 @@ import { MatrixError, ISearchResults, THREAD_RELATION_TYPE, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import { CallState, MatrixCall } from "matrix-js-sdk/src/webrtc/call"; import { throttle } from "lodash"; diff --git a/src/components/structures/SpaceHierarchy.tsx b/src/components/structures/SpaceHierarchy.tsx index 81cea88a02..6889988be3 100644 --- a/src/components/structures/SpaceHierarchy.tsx +++ b/src/components/structures/SpaceHierarchy.tsx @@ -41,8 +41,8 @@ import { HistoryVisibility, HierarchyRelation, HierarchyRoom, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { RoomHierarchy } from "matrix-js-sdk/src/room-hierarchy"; import classNames from "classnames"; import { sortBy, uniqBy } from "lodash"; diff --git a/src/components/structures/SpaceRoomView.tsx b/src/components/structures/SpaceRoomView.tsx index 95210e6879..edc857edaf 100644 --- a/src/components/structures/SpaceRoomView.tsx +++ b/src/components/structures/SpaceRoomView.tsx @@ -14,7 +14,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { EventType, RoomType, JoinRule, Preset, Room, RoomEvent, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { EventType, RoomType, JoinRule, Preset, Room, RoomEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import React, { useCallback, useContext, useRef, useState } from "react"; diff --git a/src/components/structures/TimelinePanel.tsx b/src/components/structures/TimelinePanel.tsx index 11c288d92f..739cd63111 100644 --- a/src/components/structures/TimelinePanel.tsx +++ b/src/components/structures/TimelinePanel.tsx @@ -38,9 +38,8 @@ import { Thread, ThreadEvent, ReceiptType, - KnownMembership, - Membership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership, Membership } from "matrix-js-sdk/src/types"; import { debounce, findLastIndex, throttle } from "lodash"; import { logger } from "matrix-js-sdk/src/logger"; diff --git a/src/components/structures/grouper/CreationGrouper.tsx b/src/components/structures/grouper/CreationGrouper.tsx index e50b880195..fa91a1bd90 100644 --- a/src/components/structures/grouper/CreationGrouper.tsx +++ b/src/components/structures/grouper/CreationGrouper.tsx @@ -15,7 +15,8 @@ limitations under the License. */ import React, { ReactNode } from "react"; -import { EventType, KnownMembership, M_BEACON_INFO, MatrixEvent } from "matrix-js-sdk/src/matrix"; +import { EventType, M_BEACON_INFO, MatrixEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { BaseGrouper } from "./BaseGrouper"; import MessagePanel, { WrappedEvent } from "../MessagePanel"; diff --git a/src/components/views/context_menus/RoomContextMenu.tsx b/src/components/views/context_menus/RoomContextMenu.tsx index 35ee666679..6ae926707d 100644 --- a/src/components/views/context_menus/RoomContextMenu.tsx +++ b/src/components/views/context_menus/RoomContextMenu.tsx @@ -15,7 +15,8 @@ limitations under the License. */ import React, { useContext } from "react"; -import { KnownMembership, Room } from "matrix-js-sdk/src/matrix"; +import { Room } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { IProps as IContextMenuProps } from "../../structures/ContextMenu"; import IconizedContextMenu, { diff --git a/src/components/views/dialogs/AddExistingToSpaceDialog.tsx b/src/components/views/dialogs/AddExistingToSpaceDialog.tsx index 7effd5a174..3567dbecc7 100644 --- a/src/components/views/dialogs/AddExistingToSpaceDialog.tsx +++ b/src/components/views/dialogs/AddExistingToSpaceDialog.tsx @@ -16,7 +16,8 @@ limitations under the License. import React, { ReactElement, ReactNode, useContext, useMemo, useRef, useState } from "react"; import classNames from "classnames"; -import { Room, EventType, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { Room, EventType } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { sleep } from "matrix-js-sdk/src/utils"; import { logger } from "matrix-js-sdk/src/logger"; diff --git a/src/components/views/dialogs/ForwardDialog.tsx b/src/components/views/dialogs/ForwardDialog.tsx index 39c404b35b..a72b2b6296 100644 --- a/src/components/views/dialogs/ForwardDialog.tsx +++ b/src/components/views/dialogs/ForwardDialog.tsx @@ -28,8 +28,8 @@ import { LocationAssetType, M_TIMESTAMP, M_BEACON, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { _t } from "../../../languageHandler"; import dis from "../../../dispatcher/dispatcher"; diff --git a/src/components/views/dialogs/InviteDialog.tsx b/src/components/views/dialogs/InviteDialog.tsx index 4b1bea1fc8..2b3c7af8db 100644 --- a/src/components/views/dialogs/InviteDialog.tsx +++ b/src/components/views/dialogs/InviteDialog.tsx @@ -16,7 +16,8 @@ limitations under the License. import React, { createRef, ReactNode, SyntheticEvent } from "react"; import classNames from "classnames"; -import { RoomMember, Room, MatrixError, EventType, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { RoomMember, Room, MatrixError, EventType } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { MatrixCall } from "matrix-js-sdk/src/webrtc/call"; import { logger } from "matrix-js-sdk/src/logger"; import { uniqBy } from "lodash"; diff --git a/src/components/views/dialogs/ManageRestrictedJoinRuleDialog.tsx b/src/components/views/dialogs/ManageRestrictedJoinRuleDialog.tsx index 37e39643b7..9bc28ab4a0 100644 --- a/src/components/views/dialogs/ManageRestrictedJoinRuleDialog.tsx +++ b/src/components/views/dialogs/ManageRestrictedJoinRuleDialog.tsx @@ -15,7 +15,8 @@ limitations under the License. */ import React, { useMemo, useState } from "react"; -import { KnownMembership, Room } from "matrix-js-sdk/src/matrix"; +import { Room } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { _t } from "../../../languageHandler"; import BaseDialog from "./BaseDialog"; diff --git a/src/components/views/dialogs/devtools/ServersInRoom.tsx b/src/components/views/dialogs/devtools/ServersInRoom.tsx index 22b4c0d595..bf980163ea 100644 --- a/src/components/views/dialogs/devtools/ServersInRoom.tsx +++ b/src/components/views/dialogs/devtools/ServersInRoom.tsx @@ -16,7 +16,8 @@ limitations under the License. */ import React, { useContext, useMemo } from "react"; -import { EventType, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { EventType } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import BaseTool, { DevtoolsContext, IDevtoolsProps } from "./BaseTool"; import { _t } from "../../../../languageHandler"; diff --git a/src/components/views/dialogs/spotlight/SpotlightDialog.tsx b/src/components/views/dialogs/spotlight/SpotlightDialog.tsx index 920da6b472..ee42a59221 100644 --- a/src/components/views/dialogs/spotlight/SpotlightDialog.tsx +++ b/src/components/views/dialogs/spotlight/SpotlightDialog.tsx @@ -25,8 +25,8 @@ import { Room, HierarchyRoom, JoinRule, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { normalize } from "matrix-js-sdk/src/utils"; import React, { ChangeEvent, RefObject, useCallback, useContext, useEffect, useMemo, useRef, useState } from "react"; import sanitizeHtml from "sanitize-html"; diff --git a/src/components/views/elements/AppTile.tsx b/src/components/views/elements/AppTile.tsx index fc7bdbe6a1..0ca83a0edb 100644 --- a/src/components/views/elements/AppTile.tsx +++ b/src/components/views/elements/AppTile.tsx @@ -20,7 +20,8 @@ limitations under the License. import React, { ContextType, createRef, CSSProperties, MutableRefObject, ReactNode } from "react"; import classNames from "classnames"; import { IWidget, MatrixCapabilities } from "matrix-widget-api"; -import { KnownMembership, Room, RoomEvent } from "matrix-js-sdk/src/matrix"; +import { Room, RoomEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import { ApprovalOpts, WidgetLifecycle } from "@matrix-org/react-sdk-module-api/lib/lifecycles/WidgetLifecycle"; diff --git a/src/components/views/elements/EventListSummary.tsx b/src/components/views/elements/EventListSummary.tsx index 6e8490808a..a1270427cc 100644 --- a/src/components/views/elements/EventListSummary.tsx +++ b/src/components/views/elements/EventListSummary.tsx @@ -17,7 +17,8 @@ limitations under the License. */ import React, { ComponentProps, ReactNode } from "react"; -import { MatrixEvent, RoomMember, EventType, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { MatrixEvent, RoomMember, EventType } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { _t } from "../../../languageHandler"; import { formatList } from "../../../utils/FormattingUtils"; diff --git a/src/components/views/elements/RoomFacePile.tsx b/src/components/views/elements/RoomFacePile.tsx index 92e98c37eb..0d1491edba 100644 --- a/src/components/views/elements/RoomFacePile.tsx +++ b/src/components/views/elements/RoomFacePile.tsx @@ -15,7 +15,8 @@ limitations under the License. */ import React, { FC, HTMLAttributes, useContext } from "react"; -import { KnownMembership, Room, RoomMember } from "matrix-js-sdk/src/matrix"; +import { Room, RoomMember } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { sortBy } from "lodash"; import { _t } from "../../../languageHandler"; diff --git a/src/components/views/right_panel/TimelineCard.tsx b/src/components/views/right_panel/TimelineCard.tsx index b447f4791d..7dfcd63307 100644 --- a/src/components/views/right_panel/TimelineCard.tsx +++ b/src/components/views/right_panel/TimelineCard.tsx @@ -22,8 +22,8 @@ import { Room, EventTimelineSet, Thread, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import BaseCard from "./BaseCard"; import ResizeNotifier from "../../../utils/ResizeNotifier"; diff --git a/src/components/views/right_panel/UserInfo.tsx b/src/components/views/right_panel/UserInfo.tsx index b6acc9d057..aa7b54ddf9 100644 --- a/src/components/views/right_panel/UserInfo.tsx +++ b/src/components/views/right_panel/UserInfo.tsx @@ -29,8 +29,8 @@ import { User, Device, EventType, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { UserVerificationStatus, VerificationRequest } from "matrix-js-sdk/src/crypto-api"; import { logger } from "matrix-js-sdk/src/logger"; import { CryptoEvent } from "matrix-js-sdk/src/crypto"; diff --git a/src/components/views/rooms/MemberList.tsx b/src/components/views/rooms/MemberList.tsx index 7a1b8fd3fc..828f9691da 100644 --- a/src/components/views/rooms/MemberList.tsx +++ b/src/components/views/rooms/MemberList.tsx @@ -30,8 +30,8 @@ import { UserEvent, EventType, ClientEvent, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { throttle } from "lodash"; import { Button, Tooltip } from "@vector-im/compound-web"; import { Icon as UserAddIcon } from "@vector-im/compound-design-tokens/icons/user-add-solid.svg"; diff --git a/src/components/views/rooms/NewRoomIntro.tsx b/src/components/views/rooms/NewRoomIntro.tsx index 1e52d01582..70ea6c23a2 100644 --- a/src/components/views/rooms/NewRoomIntro.tsx +++ b/src/components/views/rooms/NewRoomIntro.tsx @@ -15,7 +15,8 @@ limitations under the License. */ import React, { useContext } from "react"; -import { EventType, Room, User, MatrixClient, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { EventType, Room, User, MatrixClient } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import MatrixClientContext from "../../../contexts/MatrixClientContext"; import RoomContext from "../../../contexts/RoomContext"; diff --git a/src/components/views/rooms/RoomInfoLine.tsx b/src/components/views/rooms/RoomInfoLine.tsx index 53ed1498ca..b443ecfada 100644 --- a/src/components/views/rooms/RoomInfoLine.tsx +++ b/src/components/views/rooms/RoomInfoLine.tsx @@ -15,7 +15,8 @@ limitations under the License. */ import React, { FC } from "react"; -import { Room, JoinRule, MatrixClient, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { Room, JoinRule, MatrixClient } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { _t } from "../../../languageHandler"; import RightPanelStore from "../../../stores/right-panel/RightPanelStore"; diff --git a/src/components/views/rooms/RoomKnocksBar.tsx b/src/components/views/rooms/RoomKnocksBar.tsx index a61f875a9c..9feb23a147 100644 --- a/src/components/views/rooms/RoomKnocksBar.tsx +++ b/src/components/views/rooms/RoomKnocksBar.tsx @@ -14,7 +14,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { EventTimeline, JoinRule, KnownMembership, MatrixError, Room, RoomStateEvent } from "matrix-js-sdk/src/matrix"; +import { EventTimeline, JoinRule, MatrixError, Room, RoomStateEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import React, { ReactElement, ReactNode, useCallback, useState, VFC } from "react"; import { Icon as CheckIcon } from "../../../../res/img/feather-customised/check.svg"; diff --git a/src/components/views/rooms/RoomPreviewBar.tsx b/src/components/views/rooms/RoomPreviewBar.tsx index f2f0f686ba..bbb3154f12 100644 --- a/src/components/views/rooms/RoomPreviewBar.tsx +++ b/src/components/views/rooms/RoomPreviewBar.tsx @@ -23,8 +23,8 @@ import { IJoinRuleEventContent, JoinRule, MatrixError, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import classNames from "classnames"; import { RoomPreviewOpts, RoomViewLifecycle } from "@matrix-org/react-sdk-module-api/lib/lifecycles/RoomViewLifecycle"; diff --git a/src/components/views/rooms/RoomPreviewCard.tsx b/src/components/views/rooms/RoomPreviewCard.tsx index 16c09c9a44..ee31206c38 100644 --- a/src/components/views/rooms/RoomPreviewCard.tsx +++ b/src/components/views/rooms/RoomPreviewCard.tsx @@ -15,7 +15,8 @@ limitations under the License. */ import React, { FC, useContext, useState } from "react"; -import { Room, JoinRule, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { Room, JoinRule } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { _t } from "../../../languageHandler"; import defaultDispatcher from "../../../dispatcher/dispatcher"; diff --git a/src/components/views/rooms/RoomTile.tsx b/src/components/views/rooms/RoomTile.tsx index b716e9dedb..79f0b93f78 100644 --- a/src/components/views/rooms/RoomTile.tsx +++ b/src/components/views/rooms/RoomTile.tsx @@ -16,7 +16,8 @@ limitations under the License. */ import React, { createRef } from "react"; -import { KnownMembership, Room, RoomEvent } from "matrix-js-sdk/src/matrix"; +import { Room, RoomEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import classNames from "classnames"; import type { Call } from "../../../models/Call"; diff --git a/src/components/views/settings/tabs/room/GeneralRoomSettingsTab.tsx b/src/components/views/settings/tabs/room/GeneralRoomSettingsTab.tsx index fa1b9d7ee6..7b260e3a7e 100644 --- a/src/components/views/settings/tabs/room/GeneralRoomSettingsTab.tsx +++ b/src/components/views/settings/tabs/room/GeneralRoomSettingsTab.tsx @@ -15,7 +15,8 @@ limitations under the License. */ import React, { ContextType } from "react"; -import { KnownMembership, Room } from "matrix-js-sdk/src/matrix"; +import { Room } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { _t } from "../../../../../languageHandler"; import RoomProfileSettings from "../../../room_settings/RoomProfileSettings"; diff --git a/src/components/views/settings/tabs/room/PeopleRoomSettingsTab.tsx b/src/components/views/settings/tabs/room/PeopleRoomSettingsTab.tsx index 14c78d345a..22c2bc471f 100644 --- a/src/components/views/settings/tabs/room/PeopleRoomSettingsTab.tsx +++ b/src/components/views/settings/tabs/room/PeopleRoomSettingsTab.tsx @@ -14,14 +14,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { - EventTimeline, - KnownMembership, - MatrixError, - Room, - RoomMember, - RoomStateEvent, -} from "matrix-js-sdk/src/matrix"; +import { EventTimeline, MatrixError, Room, RoomMember, RoomStateEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import React, { useCallback, useState, VFC } from "react"; import { Icon as CheckIcon } from "../../../../../../res/img/feather-customised/check.svg"; diff --git a/src/components/views/settings/tabs/room/RolesRoomSettingsTab.tsx b/src/components/views/settings/tabs/room/RolesRoomSettingsTab.tsx index f374f78583..665f8db244 100644 --- a/src/components/views/settings/tabs/room/RolesRoomSettingsTab.tsx +++ b/src/components/views/settings/tabs/room/RolesRoomSettingsTab.tsx @@ -15,15 +15,8 @@ limitations under the License. */ import React from "react"; -import { - EventType, - RoomMember, - RoomState, - RoomStateEvent, - Room, - IContent, - KnownMembership, -} from "matrix-js-sdk/src/matrix"; +import { EventType, RoomMember, RoomState, RoomStateEvent, Room, IContent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import { throttle, get } from "lodash"; import { compare } from "matrix-js-sdk/src/utils"; diff --git a/src/components/views/settings/tabs/user/SecurityUserSettingsTab.tsx b/src/components/views/settings/tabs/user/SecurityUserSettingsTab.tsx index 087383e23a..81ff32e38e 100644 --- a/src/components/views/settings/tabs/user/SecurityUserSettingsTab.tsx +++ b/src/components/views/settings/tabs/user/SecurityUserSettingsTab.tsx @@ -16,7 +16,8 @@ limitations under the License. import React, { ReactNode } from "react"; import { sleep } from "matrix-js-sdk/src/utils"; -import { KnownMembership, Room, RoomEvent } from "matrix-js-sdk/src/matrix"; +import { Room, RoomEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership, Membership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import { _t } from "../../../../../languageHandler"; @@ -37,7 +38,7 @@ import InlineSpinner from "../../../elements/InlineSpinner"; import { PosthogAnalytics } from "../../../../../PosthogAnalytics"; import { showDialog as showAnalyticsLearnMoreDialog } from "../../../dialogs/AnalyticsLearnMoreDialog"; import { privateShouldBeEncrypted } from "../../../../../utils/rooms"; -import type { IServerVersions, Membership } from "matrix-js-sdk/src/matrix"; +import type { IServerVersions } from "matrix-js-sdk/src/matrix"; import SettingsTab from "../SettingsTab"; import { SettingsSection } from "../../shared/SettingsSection"; import SettingsSubsection, { SettingsSubsectionText } from "../../shared/SettingsSubsection"; diff --git a/src/components/views/spaces/SpaceTreeLevel.tsx b/src/components/views/spaces/SpaceTreeLevel.tsx index 1743d2b366..6b43399c28 100644 --- a/src/components/views/spaces/SpaceTreeLevel.tsx +++ b/src/components/views/spaces/SpaceTreeLevel.tsx @@ -24,7 +24,8 @@ import React, { RefObject, } from "react"; import classNames from "classnames"; -import { KnownMembership, Room, RoomEvent } from "matrix-js-sdk/src/matrix"; +import { Room, RoomEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { DraggableProvidedDragHandleProps } from "react-beautiful-dnd"; import RoomAvatar from "../avatars/RoomAvatar"; diff --git a/src/hooks/useRoomMembers.ts b/src/hooks/useRoomMembers.ts index fb294debe6..09c9773842 100644 --- a/src/hooks/useRoomMembers.ts +++ b/src/hooks/useRoomMembers.ts @@ -15,7 +15,8 @@ limitations under the License. */ import { useMemo, useState } from "react"; -import { Membership, Room, RoomEvent, RoomMember, RoomStateEvent } from "matrix-js-sdk/src/matrix"; +import { Room, RoomEvent, RoomMember, RoomStateEvent } from "matrix-js-sdk/src/matrix"; +import { Membership } from "matrix-js-sdk/src/types"; import { throttle } from "lodash"; import { useTypedEventEmitter } from "./useEventEmitter"; diff --git a/src/hooks/useSpaceResults.ts b/src/hooks/useSpaceResults.ts index 39422af9ea..d2dde1315c 100644 --- a/src/hooks/useSpaceResults.ts +++ b/src/hooks/useSpaceResults.ts @@ -15,7 +15,8 @@ limitations under the License. */ import { useCallback, useEffect, useMemo, useState } from "react"; -import { Room, RoomType, HierarchyRoom, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { Room, RoomType, HierarchyRoom } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { RoomHierarchy } from "matrix-js-sdk/src/room-hierarchy"; import { normalize } from "matrix-js-sdk/src/utils"; diff --git a/src/indexing/EventIndex.ts b/src/indexing/EventIndex.ts index 5b08163f99..15419eecf6 100644 --- a/src/indexing/EventIndex.ts +++ b/src/indexing/EventIndex.ts @@ -37,8 +37,8 @@ import { SyncState, TimelineIndex, TimelineWindow, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { sleep } from "matrix-js-sdk/src/utils"; import { logger } from "matrix-js-sdk/src/logger"; diff --git a/src/models/Call.ts b/src/models/Call.ts index 82cb021b07..f6be759837 100644 --- a/src/models/Call.ts +++ b/src/models/Call.ts @@ -23,9 +23,8 @@ import { IMyDevice, Room, RoomMember, - Membership, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership, Membership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import { randomString } from "matrix-js-sdk/src/randomstring"; import { CallType } from "matrix-js-sdk/src/webrtc/call"; diff --git a/src/shouldHideEvent.ts b/src/shouldHideEvent.ts index e82e64e7f7..0ee16009e1 100644 --- a/src/shouldHideEvent.ts +++ b/src/shouldHideEvent.ts @@ -14,7 +14,8 @@ limitations under the License. */ -import { MatrixEvent, EventType, RelationType, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { MatrixEvent, EventType, RelationType } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import SettingsStore from "./settings/SettingsStore"; import { IRoomState } from "./components/structures/RoomView"; diff --git a/src/stores/BreadcrumbsStore.ts b/src/stores/BreadcrumbsStore.ts index 5fbe7c6edd..36bb0a78b6 100644 --- a/src/stores/BreadcrumbsStore.ts +++ b/src/stores/BreadcrumbsStore.ts @@ -14,7 +14,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { Room, RoomEvent, ClientEvent, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { Room, RoomEvent, ClientEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { isNullOrUndefined } from "matrix-js-sdk/src/utils"; import SettingsStore from "../settings/SettingsStore"; diff --git a/src/stores/MemberListStore.ts b/src/stores/MemberListStore.ts index 911f99e15d..f9e1df79a4 100644 --- a/src/stores/MemberListStore.ts +++ b/src/stores/MemberListStore.ts @@ -14,7 +14,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { KnownMembership, Room, RoomMember } from "matrix-js-sdk/src/matrix"; +import { Room, RoomMember } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import SettingsStore from "../settings/SettingsStore"; import { SdkContextClass } from "../contexts/SDKContext"; diff --git a/src/stores/OwnBeaconStore.ts b/src/stores/OwnBeaconStore.ts index 26ca80529e..55399ef264 100644 --- a/src/stores/OwnBeaconStore.ts +++ b/src/stores/OwnBeaconStore.ts @@ -27,8 +27,8 @@ import { ContentHelpers, MBeaconInfoEventContent, M_BEACON, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import defaultDispatcher from "../dispatcher/dispatcher"; diff --git a/src/stores/RoomViewStore.tsx b/src/stores/RoomViewStore.tsx index 5e6eb7330d..1bb98ed5e5 100644 --- a/src/stores/RoomViewStore.tsx +++ b/src/stores/RoomViewStore.tsx @@ -18,7 +18,8 @@ limitations under the License. import React, { ReactNode } from "react"; import * as utils from "matrix-js-sdk/src/utils"; -import { MatrixError, JoinRule, Room, MatrixEvent, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { MatrixError, JoinRule, Room, MatrixEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import { ViewRoom as ViewRoomEvent } from "@matrix-org/analytics-events/types/typescript/ViewRoom"; import { JoinedRoom as JoinedRoomEvent } from "@matrix-org/analytics-events/types/typescript/JoinedRoom"; diff --git a/src/stores/notifications/RoomNotificationState.ts b/src/stores/notifications/RoomNotificationState.ts index d3dcf4970e..b556563aba 100644 --- a/src/stores/notifications/RoomNotificationState.ts +++ b/src/stores/notifications/RoomNotificationState.ts @@ -14,7 +14,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { MatrixEventEvent, RoomEvent, ClientEvent, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { MatrixEventEvent, RoomEvent, ClientEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import type { Room, MatrixEvent } from "matrix-js-sdk/src/matrix"; import type { IDestroyable } from "../../utils/IDestroyable"; diff --git a/src/stores/room-list/RoomListStore.ts b/src/stores/room-list/RoomListStore.ts index 76e1170450..dc35cd7b5b 100644 --- a/src/stores/room-list/RoomListStore.ts +++ b/src/stores/room-list/RoomListStore.ts @@ -14,7 +14,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { MatrixClient, Room, RoomState, EventType, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { MatrixClient, Room, RoomState, EventType } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import SettingsStore from "../../settings/SettingsStore"; diff --git a/src/stores/room-list/algorithms/Algorithm.ts b/src/stores/room-list/algorithms/Algorithm.ts index 41565abcc6..acb9be710f 100644 --- a/src/stores/room-list/algorithms/Algorithm.ts +++ b/src/stores/room-list/algorithms/Algorithm.ts @@ -14,7 +14,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { KnownMembership, Room } from "matrix-js-sdk/src/matrix"; +import { Room } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { isNullOrUndefined } from "matrix-js-sdk/src/utils"; import { EventEmitter } from "events"; import { logger } from "matrix-js-sdk/src/logger"; diff --git a/src/stores/spaces/SpaceStore.ts b/src/stores/spaces/SpaceStore.ts index 9d9fdd9570..e0fd0090c8 100644 --- a/src/stores/spaces/SpaceStore.ts +++ b/src/stores/spaces/SpaceStore.ts @@ -25,8 +25,8 @@ import { MatrixEvent, ClientEvent, ISendEventResponse, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import { AsyncStoreWithClient } from "../AsyncStoreWithClient"; diff --git a/src/stores/widgets/StopGapWidget.ts b/src/stores/widgets/StopGapWidget.ts index 21f19ed37f..302ca5711d 100644 --- a/src/stores/widgets/StopGapWidget.ts +++ b/src/stores/widgets/StopGapWidget.ts @@ -14,14 +14,8 @@ * limitations under the License. */ -import { - Room, - MatrixEvent, - MatrixEventEvent, - MatrixClient, - ClientEvent, - KnownMembership, -} from "matrix-js-sdk/src/matrix"; +import { Room, MatrixEvent, MatrixEventEvent, MatrixClient, ClientEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { ClientWidgetApi, IModalWidgetOpenRequest, diff --git a/src/utils/DMRoomMap.ts b/src/utils/DMRoomMap.ts index 620affcb65..cdabb50ec0 100644 --- a/src/utils/DMRoomMap.ts +++ b/src/utils/DMRoomMap.ts @@ -15,7 +15,8 @@ limitations under the License. */ import { uniq } from "lodash"; -import { Room, MatrixEvent, EventType, ClientEvent, MatrixClient, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { Room, MatrixEvent, EventType, ClientEvent, MatrixClient } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import { Optional } from "matrix-events-sdk"; diff --git a/src/utils/MultiInviter.ts b/src/utils/MultiInviter.ts index 5c096f6b3e..3df4e747a9 100644 --- a/src/utils/MultiInviter.ts +++ b/src/utils/MultiInviter.ts @@ -14,7 +14,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { MatrixError, MatrixClient, EventType, HistoryVisibility, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { MatrixError, MatrixClient, EventType, HistoryVisibility } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { defer, IDeferred } from "matrix-js-sdk/src/utils"; import { logger } from "matrix-js-sdk/src/logger"; diff --git a/src/utils/RoomUpgrade.ts b/src/utils/RoomUpgrade.ts index bf85f622ca..a62ea1bf50 100644 --- a/src/utils/RoomUpgrade.ts +++ b/src/utils/RoomUpgrade.ts @@ -14,7 +14,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { Room, EventType, ClientEvent, MatrixClient, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { Room, EventType, ClientEvent, MatrixClient } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import { inviteUsersToRoom } from "../RoomInvite"; diff --git a/src/utils/SortMembers.ts b/src/utils/SortMembers.ts index abe70eed2e..413f7971b2 100644 --- a/src/utils/SortMembers.ts +++ b/src/utils/SortMembers.ts @@ -15,7 +15,8 @@ limitations under the License. */ import { groupBy, mapValues, maxBy, minBy, sumBy, takeRight } from "lodash"; -import { KnownMembership, MatrixClient, Room, RoomMember } from "matrix-js-sdk/src/matrix"; +import { MatrixClient, Room, RoomMember } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { Member } from "./direct-messages"; import DMRoomMap from "./DMRoomMap"; diff --git a/src/utils/WidgetUtils.ts b/src/utils/WidgetUtils.ts index 63c9b032cf..a0bb8d57e2 100644 --- a/src/utils/WidgetUtils.ts +++ b/src/utils/WidgetUtils.ts @@ -17,14 +17,8 @@ limitations under the License. import { base32 } from "rfc4648"; import { IWidget, IWidgetData } from "matrix-widget-api"; -import { - Room, - ClientEvent, - MatrixClient, - RoomStateEvent, - MatrixEvent, - KnownMembership, -} from "matrix-js-sdk/src/matrix"; +import { Room, ClientEvent, MatrixClient, RoomStateEvent, MatrixEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import { CallType } from "matrix-js-sdk/src/webrtc/call"; import { randomString, randomLowercaseString, randomUppercaseString } from "matrix-js-sdk/src/randomstring"; diff --git a/src/utils/dm/createDmLocalRoom.ts b/src/utils/dm/createDmLocalRoom.ts index 08de20786e..5ffa491bcf 100644 --- a/src/utils/dm/createDmLocalRoom.ts +++ b/src/utils/dm/createDmLocalRoom.ts @@ -15,13 +15,8 @@ limitations under the License. */ import { MEGOLM_ALGORITHM } from "matrix-js-sdk/src/crypto/olmlib"; -import { - EventType, - KNOWN_SAFE_ROOM_VERSION, - KnownMembership, - MatrixClient, - MatrixEvent, -} from "matrix-js-sdk/src/matrix"; +import { EventType, KNOWN_SAFE_ROOM_VERSION, MatrixClient, MatrixEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { LocalRoom, LOCAL_ROOM_ID_PREFIX } from "../../../src/models/LocalRoom"; import { determineCreateRoomEncryptionOption, Member } from "../../../src/utils/direct-messages"; diff --git a/src/utils/dm/findDMForUser.ts b/src/utils/dm/findDMForUser.ts index ba72a7f6bc..55b5f0093f 100644 --- a/src/utils/dm/findDMForUser.ts +++ b/src/utils/dm/findDMForUser.ts @@ -14,7 +14,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { KnownMembership, MatrixClient, Room } from "matrix-js-sdk/src/matrix"; +import { MatrixClient, Room } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import DMRoomMap from "../DMRoomMap"; import { isLocalRoom } from "../localRoom/isLocalRoom"; diff --git a/src/utils/membership.ts b/src/utils/membership.ts index 4eb8173e05..2ff99fa360 100644 --- a/src/utils/membership.ts +++ b/src/utils/membership.ts @@ -14,16 +14,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { - Room, - RoomMember, - RoomState, - RoomStateEvent, - MatrixEvent, - MatrixClient, - Membership, - KnownMembership, -} from "matrix-js-sdk/src/matrix"; +import { Room, RoomMember, RoomState, RoomStateEvent, MatrixEvent, MatrixClient } from "matrix-js-sdk/src/matrix"; +import { KnownMembership, Membership } from "matrix-js-sdk/src/types"; import { MatrixClientPeg } from "../MatrixClientPeg"; import SettingsStore from "../settings/SettingsStore"; diff --git a/src/utils/permalinks/Permalinks.ts b/src/utils/permalinks/Permalinks.ts index e9d0e8bede..537494b26b 100644 --- a/src/utils/permalinks/Permalinks.ts +++ b/src/utils/permalinks/Permalinks.ts @@ -16,7 +16,8 @@ limitations under the License. import isIp from "is-ip"; import * as utils from "matrix-js-sdk/src/utils"; -import { Room, MatrixClient, RoomStateEvent, EventType, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { Room, MatrixClient, RoomStateEvent, EventType } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import MatrixToPermalinkConstructor, { diff --git a/src/utils/room/canInviteTo.ts b/src/utils/room/canInviteTo.ts index 89283dd246..bd306d930e 100644 --- a/src/utils/room/canInviteTo.ts +++ b/src/utils/room/canInviteTo.ts @@ -14,7 +14,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { JoinRule, KnownMembership, Room } from "matrix-js-sdk/src/matrix"; +import { JoinRule, Room } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { shouldShowComponent } from "../../customisations/helpers/UIComponents"; import { UIComponent } from "../../settings/UIFeature"; diff --git a/src/utils/space.tsx b/src/utils/space.tsx index f1a61cbc39..4222ab14f3 100644 --- a/src/utils/space.tsx +++ b/src/utils/space.tsx @@ -15,7 +15,8 @@ limitations under the License. */ import React from "react"; -import { Room, ICreateRoomStateEvent, RoomType, EventType, JoinRule, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { Room, ICreateRoomStateEvent, RoomType, EventType, JoinRule } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { calculateRoomVia } from "./permalinks/Permalinks"; import Modal from "../Modal"; diff --git a/test/LegacyCallHandler-test.ts b/test/LegacyCallHandler-test.ts index 9ce83729ae..8e54ac0490 100644 --- a/test/LegacyCallHandler-test.ts +++ b/test/LegacyCallHandler-test.ts @@ -16,7 +16,6 @@ limitations under the License. import { IProtocol, - KnownMembership, LOCAL_NOTIFICATION_SETTINGS_PREFIX, MatrixEvent, PushRuleKind, @@ -24,6 +23,7 @@ import { RuleId, TweakName, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { CallEvent, CallState, CallType, MatrixCall } from "matrix-js-sdk/src/webrtc/call"; import EventEmitter from "events"; import { mocked } from "jest-mock"; diff --git a/test/RoomNotifs-test.ts b/test/RoomNotifs-test.ts index 994d0a65e7..3526acf4bf 100644 --- a/test/RoomNotifs-test.ts +++ b/test/RoomNotifs-test.ts @@ -24,8 +24,8 @@ import { EventType, MatrixEvent, PendingEventOrdering, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import type { MatrixClient } from "matrix-js-sdk/src/matrix"; import { mkEvent, mkRoom, mkRoomMember, muteRoom, stubClient, upsertRoomStateEvents } from "./test-utils"; diff --git a/test/SlashCommands-test.tsx b/test/SlashCommands-test.tsx index 37e7f3616e..6ef56aa7fd 100644 --- a/test/SlashCommands-test.tsx +++ b/test/SlashCommands-test.tsx @@ -14,7 +14,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { KnownMembership, MatrixClient, Room, RoomMember } from "matrix-js-sdk/src/matrix"; +import { MatrixClient, Room, RoomMember } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { mocked } from "jest-mock"; import { Command, Commands, getCommand } from "../src/SlashCommands"; diff --git a/test/TextForEvent-test.ts b/test/TextForEvent-test.ts index 0b13311ad5..a389333dc4 100644 --- a/test/TextForEvent-test.ts +++ b/test/TextForEvent-test.ts @@ -18,12 +18,12 @@ import { EventType, HistoryVisibility, JoinRule, - KnownMembership, MatrixClient, MatrixEvent, Room, RoomMember, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { render } from "@testing-library/react"; import { ReactElement } from "react"; import { Mocked, mocked } from "jest-mock"; diff --git a/test/components/structures/MessagePanel-test.tsx b/test/components/structures/MessagePanel-test.tsx index 42f537e878..3513cee91f 100644 --- a/test/components/structures/MessagePanel-test.tsx +++ b/test/components/structures/MessagePanel-test.tsx @@ -17,7 +17,8 @@ limitations under the License. import React from "react"; import { EventEmitter } from "events"; -import { MatrixEvent, Room, RoomMember, Thread, ReceiptType, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { MatrixEvent, Room, RoomMember, Thread, ReceiptType } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { render } from "@testing-library/react"; import { TooltipProvider } from "@vector-im/compound-web"; diff --git a/test/components/structures/RoomView-test.tsx b/test/components/structures/RoomView-test.tsx index 9de521d02e..d0d12d7105 100644 --- a/test/components/structures/RoomView-test.tsx +++ b/test/components/structures/RoomView-test.tsx @@ -28,8 +28,8 @@ import { MatrixEvent, SearchResult, IEvent, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { MEGOLM_ALGORITHM } from "matrix-js-sdk/src/crypto/olmlib"; import { fireEvent, render, screen, RenderResult, waitForElementToBeRemoved, waitFor } from "@testing-library/react"; import userEvent from "@testing-library/user-event"; diff --git a/test/components/structures/SpaceHierarchy-test.tsx b/test/components/structures/SpaceHierarchy-test.tsx index f2889a13bd..0246329d8d 100644 --- a/test/components/structures/SpaceHierarchy-test.tsx +++ b/test/components/structures/SpaceHierarchy-test.tsx @@ -17,7 +17,8 @@ limitations under the License. import React from "react"; import { mocked } from "jest-mock"; import { fireEvent, render, screen, waitFor, waitForElementToBeRemoved } from "@testing-library/react"; -import { MatrixClient, Room, HierarchyRoom, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { MatrixClient, Room, HierarchyRoom } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { RoomHierarchy } from "matrix-js-sdk/src/room-hierarchy"; import { TooltipProvider } from "@vector-im/compound-web"; diff --git a/test/components/structures/TimelinePanel-test.tsx b/test/components/structures/TimelinePanel-test.tsx index 964c5bbe3c..afbe173940 100644 --- a/test/components/structures/TimelinePanel-test.tsx +++ b/test/components/structures/TimelinePanel-test.tsx @@ -34,8 +34,8 @@ import { THREAD_RELATION_TYPE, ThreadEvent, ThreadFilterType, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import React, { createRef } from "react"; import { Mocked, mocked } from "jest-mock"; import { forEachRight } from "lodash"; diff --git a/test/components/views/context_menus/RoomContextMenu-test.tsx b/test/components/views/context_menus/RoomContextMenu-test.tsx index 4b03ffe9c5..535e03f517 100644 --- a/test/components/views/context_menus/RoomContextMenu-test.tsx +++ b/test/components/views/context_menus/RoomContextMenu-test.tsx @@ -19,7 +19,8 @@ limitations under the License. import { render, screen } from "@testing-library/react"; import React, { ComponentProps } from "react"; import { mocked } from "jest-mock"; -import { KnownMembership, MatrixClient, PendingEventOrdering, Room } from "matrix-js-sdk/src/matrix"; +import { MatrixClient, PendingEventOrdering, Room } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import MatrixClientContext from "../../../../src/contexts/MatrixClientContext"; import RoomContextMenu from "../../../../src/components/views/context_menus/RoomContextMenu"; diff --git a/test/components/views/context_menus/RoomGeneralContextMenu-test.tsx b/test/components/views/context_menus/RoomGeneralContextMenu-test.tsx index 7369219e88..fabf56d424 100644 --- a/test/components/views/context_menus/RoomGeneralContextMenu-test.tsx +++ b/test/components/views/context_menus/RoomGeneralContextMenu-test.tsx @@ -16,7 +16,8 @@ limitations under the License. import { fireEvent, getByLabelText, render, screen } from "@testing-library/react"; import { mocked } from "jest-mock"; -import { ReceiptType, MatrixClient, PendingEventOrdering, Room, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { ReceiptType, MatrixClient, PendingEventOrdering, Room } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import React from "react"; import userEvent from "@testing-library/user-event"; diff --git a/test/components/views/dialogs/ConfirmUserActionDialog-test.tsx b/test/components/views/dialogs/ConfirmUserActionDialog-test.tsx index e71d5a0a80..c87e2103c9 100644 --- a/test/components/views/dialogs/ConfirmUserActionDialog-test.tsx +++ b/test/components/views/dialogs/ConfirmUserActionDialog-test.tsx @@ -16,7 +16,7 @@ limitations under the License. import React from "react"; import { render } from "@testing-library/react"; -import { KnownMembership } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import ConfirmUserActionDialog from "../../../../src/components/views/dialogs/ConfirmUserActionDialog"; import { mkRoomMember } from "../../../test-utils"; diff --git a/test/components/views/dialogs/InviteDialog-test.tsx b/test/components/views/dialogs/InviteDialog-test.tsx index 562395acb2..16f756cb01 100644 --- a/test/components/views/dialogs/InviteDialog-test.tsx +++ b/test/components/views/dialogs/InviteDialog-test.tsx @@ -17,7 +17,8 @@ limitations under the License. import React from "react"; import { fireEvent, render, screen } from "@testing-library/react"; import userEvent from "@testing-library/user-event"; -import { RoomType, MatrixClient, MatrixError, Room, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { RoomType, MatrixClient, MatrixError, Room } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { sleep } from "matrix-js-sdk/src/utils"; import { mocked, Mocked } from "jest-mock"; diff --git a/test/components/views/dialogs/SpotlightDialog-test.tsx b/test/components/views/dialogs/SpotlightDialog-test.tsx index b4fef8f403..5bf1029bc9 100644 --- a/test/components/views/dialogs/SpotlightDialog-test.tsx +++ b/test/components/views/dialogs/SpotlightDialog-test.tsx @@ -21,11 +21,11 @@ import { IProtocol, IPublicRoomsChunkRoom, JoinRule, - KnownMembership, MatrixClient, Room, RoomMember, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import sanitizeHtml from "sanitize-html"; import { fireEvent, render, screen } from "@testing-library/react"; diff --git a/test/components/views/elements/EventListSummary-test.tsx b/test/components/views/elements/EventListSummary-test.tsx index 828c66bb4a..485c1c75b5 100644 --- a/test/components/views/elements/EventListSummary-test.tsx +++ b/test/components/views/elements/EventListSummary-test.tsx @@ -16,7 +16,8 @@ limitations under the License. import React, { ComponentProps } from "react"; import { render, RenderResult } from "@testing-library/react"; -import { KnownMembership, MatrixEvent, Membership, RoomMember } from "matrix-js-sdk/src/matrix"; +import { MatrixEvent, RoomMember } from "matrix-js-sdk/src/matrix"; +import { KnownMembership, Membership } from "matrix-js-sdk/src/types"; import { getMockClientWithEventEmitter, diff --git a/test/components/views/elements/FacePile-test.tsx b/test/components/views/elements/FacePile-test.tsx index fe48197d29..313a0299be 100644 --- a/test/components/views/elements/FacePile-test.tsx +++ b/test/components/views/elements/FacePile-test.tsx @@ -15,7 +15,7 @@ limitations under the License. import { render } from "@testing-library/react"; import React from "react"; import { TooltipProvider } from "@vector-im/compound-web"; -import { KnownMembership } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import FacePile from "../../../../src/components/views/elements/FacePile"; import { mkRoomMember } from "../../../test-utils"; diff --git a/test/components/views/elements/RoomFacePile-test.tsx b/test/components/views/elements/RoomFacePile-test.tsx index 74bf5648b1..29af381897 100644 --- a/test/components/views/elements/RoomFacePile-test.tsx +++ b/test/components/views/elements/RoomFacePile-test.tsx @@ -15,7 +15,7 @@ limitations under the License. import { render } from "@testing-library/react"; import React from "react"; import { TooltipProvider } from "@vector-im/compound-web"; -import { KnownMembership } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { mkRoom, mkRoomMember, stubClient, withClientContextRenderOptions } from "../../../test-utils"; import RoomFacePile from "../../../../src/components/views/elements/RoomFacePile"; diff --git a/test/components/views/right_panel/RoomSummaryCard-test.tsx b/test/components/views/right_panel/RoomSummaryCard-test.tsx index c5d7c8c97f..8fce2fdf86 100644 --- a/test/components/views/right_panel/RoomSummaryCard-test.tsx +++ b/test/components/views/right_panel/RoomSummaryCard-test.tsx @@ -16,7 +16,8 @@ limitations under the License. import React from "react"; import { render, fireEvent, screen } from "@testing-library/react"; -import { EventType, MatrixEvent, Room, MatrixClient, JoinRule, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { EventType, MatrixEvent, Room, MatrixClient, JoinRule } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { mocked, MockedObject } from "jest-mock"; import { TooltipProvider } from "@vector-im/compound-web"; diff --git a/test/components/views/right_panel/UserInfo-test.tsx b/test/components/views/right_panel/UserInfo-test.tsx index 6e786351db..789ae075bf 100644 --- a/test/components/views/right_panel/UserInfo-test.tsx +++ b/test/components/views/right_panel/UserInfo-test.tsx @@ -28,8 +28,8 @@ import { CryptoApi, DeviceVerificationStatus, Device, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { Phase, VerificationRequest, diff --git a/test/components/views/rooms/LegacyRoomHeader-test.tsx b/test/components/views/rooms/LegacyRoomHeader-test.tsx index 393c4bc034..198badd6fb 100644 --- a/test/components/views/rooms/LegacyRoomHeader-test.tsx +++ b/test/components/views/rooms/LegacyRoomHeader-test.tsx @@ -24,8 +24,8 @@ import { RoomStateEvent, PendingEventOrdering, ISearchResults, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { CallType } from "matrix-js-sdk/src/webrtc/call"; import { ClientWidgetApi, Widget } from "matrix-widget-api"; import EventEmitter from "events"; diff --git a/test/components/views/rooms/MemberList-test.tsx b/test/components/views/rooms/MemberList-test.tsx index cb78fb95fb..753b247e59 100644 --- a/test/components/views/rooms/MemberList-test.tsx +++ b/test/components/views/rooms/MemberList-test.tsx @@ -17,15 +17,8 @@ limitations under the License. import React from "react"; import { act, fireEvent, render, RenderResult, screen } from "@testing-library/react"; -import { - Room, - MatrixClient, - RoomState, - RoomMember, - User, - MatrixEvent, - KnownMembership, -} from "matrix-js-sdk/src/matrix"; +import { Room, MatrixClient, RoomState, RoomMember, User, MatrixEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { compare } from "matrix-js-sdk/src/utils"; import { mocked, MockedObject } from "jest-mock"; import { TooltipProvider } from "@vector-im/compound-web"; diff --git a/test/components/views/rooms/NotificationBadge/UnreadNotificationBadge-test.tsx b/test/components/views/rooms/NotificationBadge/UnreadNotificationBadge-test.tsx index 0677ae8bf7..173b52fabc 100644 --- a/test/components/views/rooms/NotificationBadge/UnreadNotificationBadge-test.tsx +++ b/test/components/views/rooms/NotificationBadge/UnreadNotificationBadge-test.tsx @@ -26,8 +26,8 @@ import { EventStatus, PendingEventOrdering, ReceiptType, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import type { MatrixClient } from "matrix-js-sdk/src/matrix"; import { mkThread } from "../../../../test-utils/threads"; diff --git a/test/components/views/rooms/RoomHeader-test.tsx b/test/components/views/rooms/RoomHeader-test.tsx index c824e834b1..55506bae49 100644 --- a/test/components/views/rooms/RoomHeader-test.tsx +++ b/test/components/views/rooms/RoomHeader-test.tsx @@ -19,13 +19,13 @@ import { CallType, MatrixCall } from "matrix-js-sdk/src/webrtc/call"; import { EventType, JoinRule, - KnownMembership, MatrixClient, MatrixEvent, PendingEventOrdering, Room, RoomMember, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { createEvent, fireEvent, diff --git a/test/components/views/rooms/RoomKnocksBar-test.tsx b/test/components/views/rooms/RoomKnocksBar-test.tsx index d69f4c78fe..22d69863f9 100644 --- a/test/components/views/rooms/RoomKnocksBar-test.tsx +++ b/test/components/views/rooms/RoomKnocksBar-test.tsx @@ -19,13 +19,13 @@ import { EventTimeline, EventType, JoinRule, - KnownMembership, MatrixError, MatrixEvent, Room, RoomMember, RoomStateEvent, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import React from "react"; import ErrorDialog from "../../../../src/components/views/dialogs/ErrorDialog"; diff --git a/test/components/views/rooms/RoomPreviewBar-test.tsx b/test/components/views/rooms/RoomPreviewBar-test.tsx index a4b81618a1..4bc442fbaa 100644 --- a/test/components/views/rooms/RoomPreviewBar-test.tsx +++ b/test/components/views/rooms/RoomPreviewBar-test.tsx @@ -16,7 +16,8 @@ limitations under the License. import React, { ComponentProps } from "react"; import { render, fireEvent, RenderResult, waitFor } from "@testing-library/react"; -import { Room, RoomMember, MatrixError, IContent, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { Room, RoomMember, MatrixError, IContent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { withClientContextRenderOptions, stubClient } from "../../../test-utils"; import { MatrixClientPeg } from "../../../../src/MatrixClientPeg"; diff --git a/test/components/views/rooms/RoomPreviewCard-test.tsx b/test/components/views/rooms/RoomPreviewCard-test.tsx index f5d29e9424..dbec1c7252 100644 --- a/test/components/views/rooms/RoomPreviewCard-test.tsx +++ b/test/components/views/rooms/RoomPreviewCard-test.tsx @@ -17,7 +17,8 @@ limitations under the License. import React from "react"; import { mocked, Mocked } from "jest-mock"; import { render, screen, act } from "@testing-library/react"; -import { KnownMembership, PendingEventOrdering, Room, RoomStateEvent, RoomType } from "matrix-js-sdk/src/matrix"; +import { PendingEventOrdering, Room, RoomStateEvent, RoomType } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import type { MatrixClient, RoomMember } from "matrix-js-sdk/src/matrix"; import { stubClient, wrapInMatrixClientContext, mkRoomMember } from "../../../test-utils"; diff --git a/test/components/views/rooms/RoomTile-test.tsx b/test/components/views/rooms/RoomTile-test.tsx index 6a8e1ee749..86be3a823f 100644 --- a/test/components/views/rooms/RoomTile-test.tsx +++ b/test/components/views/rooms/RoomTile-test.tsx @@ -24,8 +24,8 @@ import { MatrixEvent, RoomStateEvent, Thread, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { Widget } from "matrix-widget-api"; import type { RoomMember } from "matrix-js-sdk/src/matrix"; diff --git a/test/components/views/settings/JoinRuleSettings-test.tsx b/test/components/views/settings/JoinRuleSettings-test.tsx index f2ce64a1f3..d64b1c2367 100644 --- a/test/components/views/settings/JoinRuleSettings-test.tsx +++ b/test/components/views/settings/JoinRuleSettings-test.tsx @@ -27,8 +27,8 @@ import { RoomMember, MatrixError, Visibility, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { defer, IDeferred } from "matrix-js-sdk/src/utils"; import { diff --git a/test/components/views/settings/tabs/room/PeopleRoomSettingsTab-test.tsx b/test/components/views/settings/tabs/room/PeopleRoomSettingsTab-test.tsx index 300889440c..c91d0029af 100644 --- a/test/components/views/settings/tabs/room/PeopleRoomSettingsTab-test.tsx +++ b/test/components/views/settings/tabs/room/PeopleRoomSettingsTab-test.tsx @@ -18,13 +18,13 @@ import { act, fireEvent, render, screen, within } from "@testing-library/react"; import { EventTimeline, EventType, - KnownMembership, MatrixError, MatrixEvent, Room, RoomMember, RoomStateEvent, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import React from "react"; import ErrorDialog from "../../../../../../src/components/views/dialogs/ErrorDialog"; diff --git a/test/components/views/settings/tabs/room/RolesRoomSettingsTab-test.tsx b/test/components/views/settings/tabs/room/RolesRoomSettingsTab-test.tsx index a74a528027..92a694e2c2 100644 --- a/test/components/views/settings/tabs/room/RolesRoomSettingsTab-test.tsx +++ b/test/components/views/settings/tabs/room/RolesRoomSettingsTab-test.tsx @@ -16,15 +16,8 @@ limitations under the License. import React from "react"; import { fireEvent, render, RenderResult, screen, waitFor } from "@testing-library/react"; -import { - MatrixClient, - EventType, - MatrixEvent, - Room, - RoomMember, - ISendEventResponse, - KnownMembership, -} from "matrix-js-sdk/src/matrix"; +import { MatrixClient, EventType, MatrixEvent, Room, RoomMember, ISendEventResponse } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { mocked } from "jest-mock"; import { defer } from "matrix-js-sdk/src/utils"; diff --git a/test/hooks/useRoomMembers-test.tsx b/test/hooks/useRoomMembers-test.tsx index f97153c4fe..1db551acda 100644 --- a/test/hooks/useRoomMembers-test.tsx +++ b/test/hooks/useRoomMembers-test.tsx @@ -16,7 +16,8 @@ limitations under the License. import { waitFor } from "@testing-library/react"; import { renderHook, act } from "@testing-library/react-hooks/dom"; -import { KnownMembership, MatrixClient, MatrixEvent, Room } from "matrix-js-sdk/src/matrix"; +import { MatrixClient, MatrixEvent, Room } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { MatrixClientPeg } from "../../src/MatrixClientPeg"; import { stubClient } from "../test-utils"; diff --git a/test/hooks/useUnreadNotifications-test.ts b/test/hooks/useUnreadNotifications-test.ts index 456577da81..5a71bee9a5 100644 --- a/test/hooks/useUnreadNotifications-test.ts +++ b/test/hooks/useUnreadNotifications-test.ts @@ -15,13 +15,8 @@ limitations under the License. */ import { renderHook } from "@testing-library/react-hooks"; -import { - EventStatus, - KnownMembership, - NotificationCountType, - PendingEventOrdering, - Room, -} from "matrix-js-sdk/src/matrix"; +import { EventStatus, NotificationCountType, PendingEventOrdering, Room } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import type { MatrixClient } from "matrix-js-sdk/src/matrix"; import { useUnreadNotifications } from "../../src/hooks/useUnreadNotifications"; diff --git a/test/models/Call-test.ts b/test/models/Call-test.ts index cde65df3d5..cf1aed9ca7 100644 --- a/test/models/Call-test.ts +++ b/test/models/Call-test.ts @@ -17,15 +17,8 @@ limitations under the License. import EventEmitter from "events"; import { mocked } from "jest-mock"; import { waitFor } from "@testing-library/react"; -import { - RoomType, - Room, - RoomEvent, - MatrixEvent, - RoomStateEvent, - PendingEventOrdering, - KnownMembership, -} from "matrix-js-sdk/src/matrix"; +import { RoomType, Room, RoomEvent, MatrixEvent, RoomStateEvent, PendingEventOrdering } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { Widget } from "matrix-widget-api"; // eslint-disable-next-line no-restricted-imports import { MatrixRTCSessionManagerEvents } from "matrix-js-sdk/src/matrixrtc/MatrixRTCSessionManager"; diff --git a/test/stores/MemberListStore-test.ts b/test/stores/MemberListStore-test.ts index 245f20576e..9610f7e6fe 100644 --- a/test/stores/MemberListStore-test.ts +++ b/test/stores/MemberListStore-test.ts @@ -15,7 +15,8 @@ limitations under the License. */ import { mocked } from "jest-mock"; -import { EventType, IContent, KnownMembership, MatrixClient, MatrixEvent, Room } from "matrix-js-sdk/src/matrix"; +import { EventType, IContent, MatrixClient, MatrixEvent, Room } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import SdkConfig from "../../src/SdkConfig"; import SettingsStore from "../../src/settings/SettingsStore"; diff --git a/test/stores/OwnBeaconStore-test.ts b/test/stores/OwnBeaconStore-test.ts index 700c46940c..b546558f74 100644 --- a/test/stores/OwnBeaconStore-test.ts +++ b/test/stores/OwnBeaconStore-test.ts @@ -24,8 +24,8 @@ import { RoomMember, ContentHelpers, M_BEACON, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import { Mocked } from "jest-mock"; diff --git a/test/stores/SpaceStore-test.ts b/test/stores/SpaceStore-test.ts index 7dad0515c3..a0f53d38cf 100644 --- a/test/stores/SpaceStore-test.ts +++ b/test/stores/SpaceStore-test.ts @@ -24,8 +24,8 @@ import { MatrixEvent, Room, RoomEvent, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { defer } from "matrix-js-sdk/src/utils"; import SpaceStore from "../../src/stores/spaces/SpaceStore"; diff --git a/test/stores/notifications/RoomNotificationState-test.ts b/test/stores/notifications/RoomNotificationState-test.ts index aa96fdfc00..fc3ef9983b 100644 --- a/test/stores/notifications/RoomNotificationState-test.ts +++ b/test/stores/notifications/RoomNotificationState-test.ts @@ -22,8 +22,8 @@ import { NotificationCountType, EventType, MatrixEvent, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import type { MatrixClient } from "matrix-js-sdk/src/matrix"; import { mkEvent, muteRoom, stubClient } from "../../test-utils"; diff --git a/test/stores/room-list/RoomListStore-test.ts b/test/stores/room-list/RoomListStore-test.ts index 43315e03aa..4a446eff9a 100644 --- a/test/stores/room-list/RoomListStore-test.ts +++ b/test/stores/room-list/RoomListStore-test.ts @@ -18,12 +18,12 @@ import { ConditionKind, EventType, IPushRule, - KnownMembership, MatrixEvent, PendingEventOrdering, PushRuleActionName, Room, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import defaultDispatcher, { MatrixDispatcher } from "../../../src/dispatcher/dispatcher"; import { SettingLevel } from "../../../src/settings/SettingLevel"; diff --git a/test/stores/room-list/algorithms/Algorithm-test.ts b/test/stores/room-list/algorithms/Algorithm-test.ts index 5c9db560d2..62f2abc42b 100644 --- a/test/stores/room-list/algorithms/Algorithm-test.ts +++ b/test/stores/room-list/algorithms/Algorithm-test.ts @@ -15,7 +15,8 @@ limitations under the License. */ import { mocked, MockedObject } from "jest-mock"; -import { KnownMembership, PendingEventOrdering, Room, RoomStateEvent } from "matrix-js-sdk/src/matrix"; +import { PendingEventOrdering, Room, RoomStateEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { Widget } from "matrix-widget-api"; import type { MatrixClient } from "matrix-js-sdk/src/matrix"; diff --git a/test/stores/room-list/algorithms/RecentAlgorithm-test.ts b/test/stores/room-list/algorithms/RecentAlgorithm-test.ts index 5254d632b9..f925e47726 100644 --- a/test/stores/room-list/algorithms/RecentAlgorithm-test.ts +++ b/test/stores/room-list/algorithms/RecentAlgorithm-test.ts @@ -14,7 +14,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { Room, MatrixClient, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { Room, MatrixClient } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { mkMessage, mkRoom, stubClient } from "../../../test-utils"; import { MatrixClientPeg } from "../../../../src/MatrixClientPeg"; diff --git a/test/test-utils/room.ts b/test/test-utils/room.ts index bf4cc5b9e6..0a188c7cd5 100644 --- a/test/test-utils/room.ts +++ b/test/test-utils/room.ts @@ -15,7 +15,8 @@ limitations under the License. */ import { MockedObject } from "jest-mock"; -import { MatrixClient, MatrixEvent, EventType, Room, EventTimeline, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { MatrixClient, MatrixEvent, EventType, Room, EventTimeline } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { IRoomState } from "../../src/components/structures/RoomView"; import { TimelineRenderingType } from "../../src/contexts/RoomContext"; diff --git a/test/test-utils/test-utils.ts b/test/test-utils/test-utils.ts index 35595a60fe..933d324dd5 100644 --- a/test/test-utils/test-utils.ts +++ b/test/test-utils/test-utils.ts @@ -38,8 +38,8 @@ import { JoinRule, IEventDecryptionResult, OidcClientConfig, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { normalize } from "matrix-js-sdk/src/utils"; import { ReEmitter } from "matrix-js-sdk/src/ReEmitter"; import { MediaHandler } from "matrix-js-sdk/src/webrtc/mediaHandler"; @@ -50,7 +50,8 @@ import { MatrixRTCSessionManager } from "matrix-js-sdk/src/matrixrtc/MatrixRTCSe // eslint-disable-next-line no-restricted-imports import { MatrixRTCSession } from "matrix-js-sdk/src/matrixrtc/MatrixRTCSession"; -import type { GroupCall, Membership } from "matrix-js-sdk/src/matrix"; +import type { GroupCall } from "matrix-js-sdk/src/matrix"; +import type { Membership } from "matrix-js-sdk/src/types"; import { MatrixClientPeg as peg } from "../../src/MatrixClientPeg"; import { ValidatedServerConfig } from "../../src/utils/ValidatedServerConfig"; import { EnhancedMap } from "../../src/utils/maps"; diff --git a/test/utils/MultiInviter-test.ts b/test/utils/MultiInviter-test.ts index 8c610bb21e..ae1c6ef91b 100644 --- a/test/utils/MultiInviter-test.ts +++ b/test/utils/MultiInviter-test.ts @@ -15,15 +15,8 @@ limitations under the License. */ import { mocked } from "jest-mock"; -import { - EventType, - KnownMembership, - MatrixClient, - MatrixError, - MatrixEvent, - Room, - RoomMember, -} from "matrix-js-sdk/src/matrix"; +import { EventType, MatrixClient, MatrixError, MatrixEvent, Room, RoomMember } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { MatrixClientPeg } from "../../src/MatrixClientPeg"; import Modal, { ComponentType, ComponentProps } from "../../src/Modal"; diff --git a/test/utils/direct-messages-test.ts b/test/utils/direct-messages-test.ts index b7e653bef3..6a6e54edcf 100644 --- a/test/utils/direct-messages-test.ts +++ b/test/utils/direct-messages-test.ts @@ -15,7 +15,8 @@ limitations under the License. */ import { mocked } from "jest-mock"; -import { ClientEvent, KnownMembership, MatrixClient, Room } from "matrix-js-sdk/src/matrix"; +import { ClientEvent, MatrixClient, Room } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { logger } from "matrix-js-sdk/src/logger"; import DMRoomMap from "../../src/utils/DMRoomMap"; diff --git a/test/utils/dm/createDmLocalRoom-test.ts b/test/utils/dm/createDmLocalRoom-test.ts index 921c2fd5bb..2d9da9b75d 100644 --- a/test/utils/dm/createDmLocalRoom-test.ts +++ b/test/utils/dm/createDmLocalRoom-test.ts @@ -15,7 +15,8 @@ limitations under the License. */ import { mocked } from "jest-mock"; -import { EventType, KNOWN_SAFE_ROOM_VERSION, KnownMembership, MatrixClient } from "matrix-js-sdk/src/matrix"; +import { EventType, KNOWN_SAFE_ROOM_VERSION, MatrixClient } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { canEncryptToAllUsers } from "../../../src/createRoom"; import { LocalRoom, LOCAL_ROOM_ID_PREFIX } from "../../../src/models/LocalRoom"; diff --git a/test/utils/dm/findDMForUser-test.ts b/test/utils/dm/findDMForUser-test.ts index 45dc2e3d6b..9d0852d108 100644 --- a/test/utils/dm/findDMForUser-test.ts +++ b/test/utils/dm/findDMForUser-test.ts @@ -15,7 +15,8 @@ limitations under the License. */ import { mocked } from "jest-mock"; -import { KnownMembership, MatrixClient, Room } from "matrix-js-sdk/src/matrix"; +import { MatrixClient, Room } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import DMRoomMap from "../../../src/utils/DMRoomMap"; import { createTestClient, makeMembershipEvent, mkThirdPartyInviteEvent } from "../../test-utils"; diff --git a/test/utils/export-test.tsx b/test/utils/export-test.tsx index dd002156e3..42ee1dedcd 100644 --- a/test/utils/export-test.tsx +++ b/test/utils/export-test.tsx @@ -23,8 +23,8 @@ import { RoomMember, RelationType, EventType, - KnownMembership, } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { MatrixClientPeg } from "../../src/MatrixClientPeg"; import { IExportOptions, ExportType, ExportFormat } from "../../src/utils/exportUtils/exportUtils"; diff --git a/test/utils/local-room-test.ts b/test/utils/local-room-test.ts index 8de7ddfac4..593a045d88 100644 --- a/test/utils/local-room-test.ts +++ b/test/utils/local-room-test.ts @@ -15,7 +15,8 @@ limitations under the License. */ import { mocked } from "jest-mock"; -import { KnownMembership, MatrixClient, Room } from "matrix-js-sdk/src/matrix"; +import { MatrixClient, Room } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { LocalRoom, LocalRoomState, LOCAL_ROOM_ID_PREFIX } from "../../src/models/LocalRoom"; import * as localRoomModule from "../../src/utils/local-room"; diff --git a/test/utils/localRoom/isRoomReady-test.ts b/test/utils/localRoom/isRoomReady-test.ts index 1d4843196f..8f91553d6e 100644 --- a/test/utils/localRoom/isRoomReady-test.ts +++ b/test/utils/localRoom/isRoomReady-test.ts @@ -15,7 +15,8 @@ limitations under the License. */ import { mocked } from "jest-mock"; -import { EventType, KnownMembership, MatrixClient, Room } from "matrix-js-sdk/src/matrix"; +import { EventType, MatrixClient, Room } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { LocalRoom, LOCAL_ROOM_ID_PREFIX } from "../../../src/models/LocalRoom"; import { DirectoryMember } from "../../../src/utils/direct-messages"; diff --git a/test/utils/membership-test.ts b/test/utils/membership-test.ts index 7ad6f6911a..3a44263481 100644 --- a/test/utils/membership-test.ts +++ b/test/utils/membership-test.ts @@ -14,15 +14,8 @@ See the License for the specific language governing permissions and limitations under the License. */ -import { - KnownMembership, - MatrixClient, - MatrixEvent, - Room, - RoomMember, - RoomState, - RoomStateEvent, -} from "matrix-js-sdk/src/matrix"; +import { MatrixClient, MatrixEvent, Room, RoomMember, RoomState, RoomStateEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { mocked } from "jest-mock"; import { isKnockDenied, waitForMember } from "../../src/utils/membership"; diff --git a/test/utils/permalinks/Permalinks-test.ts b/test/utils/permalinks/Permalinks-test.ts index 444007f00f..3c3bbbbec9 100644 --- a/test/utils/permalinks/Permalinks-test.ts +++ b/test/utils/permalinks/Permalinks-test.ts @@ -14,7 +14,8 @@ limitations under the License. */ import { EventEmitter } from "events"; -import { Room, RoomMember, EventType, MatrixEvent, KnownMembership } from "matrix-js-sdk/src/matrix"; +import { Room, RoomMember, EventType, MatrixEvent } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { MatrixClientPeg } from "../../../src/MatrixClientPeg"; import { PermalinkParts } from "../../../src/utils/permalinks/PermalinkConstructor"; diff --git a/test/utils/room/canInviteTo-test.ts b/test/utils/room/canInviteTo-test.ts index 93a44213d2..2ee0ca87af 100644 --- a/test/utils/room/canInviteTo-test.ts +++ b/test/utils/room/canInviteTo-test.ts @@ -15,7 +15,8 @@ limitations under the License. */ import { mocked } from "jest-mock"; -import { JoinRule, KnownMembership, Room } from "matrix-js-sdk/src/matrix"; +import { JoinRule, Room } from "matrix-js-sdk/src/matrix"; +import { KnownMembership } from "matrix-js-sdk/src/types"; import { shouldShowComponent } from "../../../src/customisations/helpers/UIComponents"; import { UIComponent } from "../../../src/settings/UIFeature";