mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2026-04-18 07:36:00 +01:00
Replace typescript compiler with native tsgo compiler
This commit is contained in:
@@ -161,8 +161,8 @@ export type OutgoingTextAttachmentType = Omit<TextAttachmentType, 'preview'> & {
|
||||
};
|
||||
|
||||
export type GroupV2InfoType = {
|
||||
groupChange?: Uint8Array;
|
||||
masterKey: Uint8Array;
|
||||
groupChange?: Uint8Array<ArrayBuffer>;
|
||||
masterKey: Uint8Array<ArrayBuffer>;
|
||||
revision: number;
|
||||
members: ReadonlyArray<ServiceIdString>;
|
||||
};
|
||||
@@ -221,7 +221,7 @@ export type SharedMessageOptionsType = Readonly<{
|
||||
pinMessage?: SendPinMessageType;
|
||||
pollCreate?: PollCreateType;
|
||||
preview?: ReadonlyArray<OutgoingLinkPreviewType>;
|
||||
profileKey?: Uint8Array;
|
||||
profileKey?: Uint8Array<ArrayBuffer>;
|
||||
quote?: OutgoingQuoteType;
|
||||
reaction?: ReactionType;
|
||||
sticker?: OutgoingStickerType;
|
||||
@@ -285,7 +285,7 @@ class Message {
|
||||
|
||||
preview?: ReadonlyArray<OutgoingLinkPreviewType>;
|
||||
|
||||
profileKey?: Uint8Array;
|
||||
profileKey?: Uint8Array<ArrayBuffer>;
|
||||
|
||||
quote?: OutgoingQuoteType;
|
||||
|
||||
@@ -775,7 +775,7 @@ export class MessageSender {
|
||||
|
||||
// Attachment upload functions
|
||||
|
||||
static getRandomPadding(): Uint8Array {
|
||||
static getRandomPadding(): Uint8Array<ArrayBuffer> {
|
||||
// Generate a random int from 1 and 512
|
||||
const buffer = getRandomBytes(2);
|
||||
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
|
||||
@@ -836,7 +836,7 @@ export class MessageSender {
|
||||
|
||||
async getDataOrEditMessage(
|
||||
options: Readonly<MessageOptionsType>
|
||||
): Promise<Uint8Array> {
|
||||
): Promise<Uint8Array<ArrayBuffer>> {
|
||||
const message = await this.getHydratedMessage(options);
|
||||
const dataMessage = message.toProto();
|
||||
|
||||
@@ -909,7 +909,7 @@ export class MessageSender {
|
||||
expireTimer,
|
||||
expireTimerVersion,
|
||||
pollVote,
|
||||
}: PollVoteBuildOptions): Promise<Uint8Array> {
|
||||
}: PollVoteBuildOptions): Promise<Uint8Array<ArrayBuffer>> {
|
||||
const proto = this.createDataMessageProtoForPollVote({
|
||||
groupV2,
|
||||
timestamp,
|
||||
@@ -1031,7 +1031,7 @@ export class MessageSender {
|
||||
bodyRanges?: Array<RawBodyRange>;
|
||||
fileAttachment?: UploadedAttachmentType;
|
||||
groupV2?: GroupV2InfoType;
|
||||
profileKey: Uint8Array;
|
||||
profileKey: Uint8Array<ArrayBuffer>;
|
||||
textAttachment?: OutgoingTextAttachmentType;
|
||||
}): Promise<Proto.StoryMessage.Params> {
|
||||
let attachment: Proto.StoryMessage.Params['attachment'];
|
||||
@@ -1123,7 +1123,7 @@ export class MessageSender {
|
||||
getTypingContentMessage(
|
||||
options: Readonly<{
|
||||
recipientId?: ServiceIdString;
|
||||
groupId?: Uint8Array;
|
||||
groupId?: Uint8Array<ArrayBuffer>;
|
||||
groupMembers: ReadonlyArray<ServiceIdString>;
|
||||
isTyping: boolean;
|
||||
timestamp?: number;
|
||||
@@ -1505,8 +1505,8 @@ export class MessageSender {
|
||||
storyMessage,
|
||||
storyMessageRecipients,
|
||||
}: Readonly<{
|
||||
encodedDataMessage?: Uint8Array;
|
||||
encodedEditMessage?: Uint8Array;
|
||||
encodedDataMessage?: Uint8Array<ArrayBuffer>;
|
||||
encodedEditMessage?: Uint8Array<ArrayBuffer>;
|
||||
timestamp: number;
|
||||
destinationE164: string | undefined;
|
||||
destinationServiceId: ServiceIdString | undefined;
|
||||
@@ -1547,7 +1547,7 @@ export class MessageSender {
|
||||
): Promise<Proto.SyncMessage.Sent.UnidentifiedDeliveryStatus.Params> => {
|
||||
const conv = window.ConversationController.get(conversationId);
|
||||
const serviceId = conv?.getServiceId();
|
||||
let destinationPniIdentityKey: Uint8Array | null = null;
|
||||
let destinationPniIdentityKey: Uint8Array<ArrayBuffer> | null = null;
|
||||
if (conv) {
|
||||
if (isPniString(serviceId)) {
|
||||
const pniIdentityKey =
|
||||
@@ -2221,7 +2221,7 @@ export class MessageSender {
|
||||
options: Readonly<{
|
||||
e164s: Array<string>;
|
||||
acis: Array<AciString>;
|
||||
groupIds: Array<Uint8Array>;
|
||||
groupIds: Array<Uint8Array<ArrayBuffer>>;
|
||||
}>
|
||||
): SingleProtoJobData {
|
||||
const myAci = itemStorage.user.getCheckedAci();
|
||||
@@ -2267,7 +2267,7 @@ export class MessageSender {
|
||||
static getMessageRequestResponseSync(
|
||||
options: Readonly<{
|
||||
threadAci?: AciString;
|
||||
groupId?: Uint8Array;
|
||||
groupId?: Uint8Array<ArrayBuffer>;
|
||||
type: number;
|
||||
}>
|
||||
): SingleProtoJobData {
|
||||
@@ -2362,7 +2362,7 @@ export class MessageSender {
|
||||
destinationE164: string | undefined,
|
||||
destinationAci: AciString | undefined,
|
||||
state: number,
|
||||
identityKey: Readonly<Uint8Array>
|
||||
identityKey: Readonly<Uint8Array<ArrayBuffer>>
|
||||
): SingleProtoJobData {
|
||||
const myAci = itemStorage.user.getCheckedAci();
|
||||
|
||||
@@ -2540,7 +2540,7 @@ export class MessageSender {
|
||||
|
||||
static getNullMessage(
|
||||
options: Readonly<{
|
||||
padding?: Uint8Array;
|
||||
padding?: Uint8Array<ArrayBuffer>;
|
||||
}> = {}
|
||||
): Proto.Content.Params {
|
||||
return {
|
||||
@@ -2570,7 +2570,7 @@ export class MessageSender {
|
||||
}: Readonly<{
|
||||
contentHint: number;
|
||||
messageId?: string;
|
||||
proto: Uint8Array;
|
||||
proto: Uint8Array<ArrayBuffer>;
|
||||
sendType: SendTypesType;
|
||||
timestamp: number;
|
||||
urgent: boolean;
|
||||
|
||||
Reference in New Issue
Block a user