import { getCurrentChannelId, getMyChannelMemberships, getMyCurrentChannelMembership } from "./common"; import { Channel, ChannelStats, ChannelMembership, ChannelModeration, ChannelMemberCountsByGroup } from "../../types/channels"; import { Post } from "../../types/posts"; import { GlobalState } from "../../types/store"; import { Team } from "../../types/teams"; import { UserProfile } from "../../types/users"; import { $ID, IDMappedObjects, NameMappedObjects, RelationOneToMany, RelationOneToOne, UserIDMappedObjects } from "../../types/utilities"; export { getCurrentChannelId, getMyChannelMemberships, getMyCurrentChannelMembership }; declare type SortingType = 'recent' | 'alpha'; export declare function getAllChannels(state: GlobalState): IDMappedObjects; export declare function getAllChannelStats(state: GlobalState): RelationOneToOne; export declare function getChannelsInTeam(state: GlobalState): RelationOneToMany; export declare const getDirectChannelsSet: (state: GlobalState) => Set; export declare function getChannelMembersInChannels(state: GlobalState): RelationOneToOne>; export declare const mapAndSortChannelIds: (channels: Channel[], currentUser: UserProfile, myMembers: RelationOneToOne, lastPosts: RelationOneToOne, sorting: SortingType, sortMentionsFirst?: boolean) => string[]; export declare function filterChannels(unreadIds: Array, favoriteIds: Array, channelIds: Array, unreadsAtTop: boolean, favoritesAtTop: boolean): Array; export declare function makeGetChannel(): (state: GlobalState, props: { id: string; }) => Channel; export declare const getChannel: (state: GlobalState, id: string) => Channel; export declare function makeGetChannelsForIds(): (state: GlobalState, ids: string[]) => Channel[]; export declare const getCurrentChannel: (state: GlobalState) => Channel; export declare const getMyChannelMember: (state: GlobalState, channelId: string) => ChannelMembership | undefined | null; export declare const getCurrentChannelStats: (state: GlobalState) => ChannelStats; export declare function isCurrentChannelFavorite(state: GlobalState): boolean; export declare const isCurrentChannelMuted: (state: GlobalState) => boolean; export declare const isCurrentChannelArchived: (state: GlobalState) => boolean; export declare const isCurrentChannelDefault: (state: GlobalState) => boolean; export declare function isCurrentChannelReadOnly(state: GlobalState): boolean; export declare function isChannelReadOnlyById(state: GlobalState, channelId: string): boolean; export declare function isChannelReadOnly(state: GlobalState, channel: Channel): boolean; export declare function shouldHideDefaultChannel(state: GlobalState, channel: Channel): boolean; export declare const countCurrentChannelUnreadMessages: (state: GlobalState) => number; export declare function getChannelByName(state: GlobalState, channelName: string): Channel | undefined | null; export declare const getChannelSetInCurrentTeam: (state: GlobalState) => Array; export declare const getChannelsInCurrentTeam: (state: GlobalState) => Array; export declare const getChannelsNameMapInTeam: (state: GlobalState, teamId: string) => NameMappedObjects; export declare const getChannelsNameMapInCurrentTeam: (state: GlobalState) => NameMappedObjects; export declare const getAllDirectChannels: (state: GlobalState) => Array; export declare const getAllDirectChannelsNameMapInCurrentTeam: (state: GlobalState) => NameMappedObjects; export declare const getGroupChannels: (state: GlobalState) => Array; export declare const getMyChannels: (state: GlobalState) => Array; export declare const getOtherChannels: (state: GlobalState, archived?: boolean | null) => Array; export declare const getDefaultChannel: (state: GlobalState) => Channel | undefined | null; export declare const getMembersInCurrentChannel: (state: GlobalState) => UserIDMappedObjects; export declare const getUnreads: (state: GlobalState) => { messageCount: number; mentionCount: number; }; export declare const getUnreadsInCurrentTeam: (a: GlobalState) => { messageCount: number; mentionCount: number; }; export declare const canManageChannelMembers: (state: GlobalState) => boolean; export declare const canManageAnyChannelMembersInCurrentTeam: (state: GlobalState) => boolean; export declare const getAllDirectChannelIds: (state: GlobalState) => Array; export declare const getChannelIdsInCurrentTeam: (state: GlobalState) => Array; export declare const getChannelIdsForCurrentTeam: (state: GlobalState) => Array; export declare const getUnreadChannelIds: (state: GlobalState, lastUnreadChannel?: Channel | null) => Array; export declare const getUnreadChannels: (state: GlobalState, lastUnreadChannel?: Channel | null) => Array; export declare const getMapAndSortedUnreadChannelIds: (state: GlobalState, lastUnreadChannel: Channel, sorting: SortingType) => Array; export declare const getSortedUnreadChannelIds: (state: GlobalState, lastUnreadChannel: Channel | null, unreadsAtTop: boolean, favoritesAtTop: boolean, sorting: SortingType) => Array; export declare const getAllRecentChannels: (state: GlobalState) => Array; export declare const getFavoriteChannels: (state: GlobalState) => Array; export declare const getFavoriteChannelIds: (state: GlobalState, lastUnreadChannel: Channel, unreadsAtTop: boolean, favoritesAtTop: boolean, sorting: SortingType) => Array; export declare const getSortedFavoriteChannelIds: (state: GlobalState, lastUnreadChannel: Channel | null, favoritesAtTop: boolean, unreadsAtTop: boolean, sorting: SortingType) => Array; export declare const getPublicChannels: (state: GlobalState) => Array; export declare const getPublicChannelIds: (state: GlobalState, lastUnreadChannel: Channel, unreadsAtTop: boolean, favoritesAtTop: boolean, sorting: SortingType) => Array; export declare const getSortedPublicChannelIds: (state: GlobalState, lastUnreadChannel: Channel | null, unreadsAtTop: boolean, favoritesAtTop: boolean, sorting: SortingType) => Array; export declare const getPrivateChannels: (a: GlobalState) => Array; export declare const getPrivateChannelIds: (state: GlobalState, lastUnreadChannel: Channel, unreadsAtTop: boolean, favoritesAtTop: boolean, sorting: SortingType) => Array; export declare const getSortedPrivateChannelIds: (state: GlobalState, lastUnreadChannel: Channel | null, unreadsAtTop: boolean, favoritesAtTop: boolean, sorting: SortingType) => Array; export declare const getDirectChannels: (state: GlobalState) => Array; export declare const getDirectAndGroupChannels: (a: GlobalState) => Array; export declare const getDirectChannelIds: (state: GlobalState, lastUnreadChannel: Channel, unreadsAtTop: boolean, favoritesAtTop: boolean, sorting: SortingType) => Array; export declare const getSortedDirectChannelIds: (state: GlobalState, lastUnreadChannel: Channel | null, unreadsAtTop: boolean, favoritesAtTop: boolean, sorting: SortingType) => Array<$ID>; export declare const getChannelsWithUserProfiles: (state: GlobalState) => Array<{ profiles: Array; } & Channel>; export declare const getAllChannelIds: (state: GlobalState, lastUnreadChannel: Channel, unreadsAtTop: boolean, favoritesAtTop: boolean, sorting: SortingType) => Array; export declare const getAllSortedChannelIds: (state: GlobalState, lastUnreadChannel: Channel | null, unreadsAtTop: boolean, favoritesAtTop: boolean, sorting: SortingType) => Array; declare type ChannelsByCategory = { type: string; name: string; items: string[]; }; export declare const getOrderedChannelIds: (state: GlobalState, lastUnreadChannel: Channel | null, grouping: "by_type" | "none", sorting: SortingType, unreadsAtTop: boolean, favoritesAtTop: boolean) => ChannelsByCategory[]; export declare const getDefaultChannelForTeams: (state: GlobalState) => RelationOneToOne; export declare const getMyFirstChannelForTeams: (state: GlobalState) => RelationOneToOne; export declare const getRedirectChannelNameForTeam: (state: GlobalState, teamId: string) => string; export declare function isManuallyUnread(state: GlobalState, channelId?: string): boolean; export declare function getChannelModerations(state: GlobalState, channelId: string): Array; export declare function getChannelMemberCountsByGroup(state: GlobalState, channelId: string): ChannelMemberCountsByGroup; export declare function isFavoriteChannel(state: GlobalState, channelId: string): boolean;