Changeset View
Changeset View
Standalone View
Standalone View
lib/shared/messages/create-sidebar-message-spec.js
Show All 10 Lines | |||||
} from './message-spec.js'; | } from './message-spec.js'; | ||||
import { joinResult } from './utils.js'; | import { joinResult } from './utils.js'; | ||||
import type { PlatformDetails } from '../../types/device-types.js'; | import type { PlatformDetails } from '../../types/device-types.js'; | ||||
import { messageTypes } from '../../types/message-types-enum.js'; | import { messageTypes } from '../../types/message-types-enum.js'; | ||||
import type { | import type { | ||||
MessageInfo, | MessageInfo, | ||||
ClientDBMessageInfo, | ClientDBMessageInfo, | ||||
} from '../../types/message-types.js'; | } from '../../types/message-types.js'; | ||||
import type { | import { | ||||
CreateSidebarMessageData, | type CreateSidebarMessageData, | ||||
CreateSidebarMessageInfo, | type CreateSidebarMessageInfo, | ||||
RawCreateSidebarMessageInfo, | type RawCreateSidebarMessageInfo, | ||||
rawCreateSidebarMessageInfoValidator, | |||||
} from '../../types/messages/create-sidebar.js'; | } from '../../types/messages/create-sidebar.js'; | ||||
import type { RawUnsupportedMessageInfo } from '../../types/messages/unsupported.js'; | import type { RawUnsupportedMessageInfo } from '../../types/messages/unsupported.js'; | ||||
import type { NotifTexts } from '../../types/notif-types.js'; | import type { NotifTexts } from '../../types/notif-types.js'; | ||||
import type { ThreadInfo } from '../../types/thread-types.js'; | import type { ThreadInfo } from '../../types/thread-types.js'; | ||||
import type { RelativeUserInfo } from '../../types/user-types.js'; | import type { RelativeUserInfo } from '../../types/user-types.js'; | ||||
import { | import { | ||||
ET, | ET, | ||||
type EntityText, | type EntityText, | ||||
▲ Show 20 Lines • Show All 191 Lines • ▼ Show 20 Lines | > = Object.freeze({ | ||||
}, | }, | ||||
threadIDs( | threadIDs( | ||||
rawMessageInfo: RawCreateSidebarMessageInfo, | rawMessageInfo: RawCreateSidebarMessageInfo, | ||||
): $ReadOnlyArray<string> { | ): $ReadOnlyArray<string> { | ||||
const { parentThreadID } = rawMessageInfo.initialThreadState; | const { parentThreadID } = rawMessageInfo.initialThreadState; | ||||
return [parentThreadID]; | return [parentThreadID]; | ||||
}, | }, | ||||
validator: rawCreateSidebarMessageInfoValidator, | |||||
}); | }); |