This commit is contained in:
janisslsm committed 2026-11-01 12:12:55 +02:00
1 parent 1781d25a15
commit 732c0ad767
33051 files changed
+2591613 -3019689

No files matched your search

@@ -0,0 +1,42 @@
// Metro module 7932 (f7933).
import { MessageFailureState } from "./RowGeneratorConstants";
import { MessageEmbedTypes } from "../../../../Constants";
import { getAssetUriForEmbed } from "./EmbedUtils";
import Module7933 from "../../../../_bundle/Module7933";
import { intl, t } from "../../../../intl/index.native";
import Module7934 from "../../../../_bundle/Module7934";
import { sizeString } from "../../../../utils/FileUtils";
export default function createMessageFailedEmbed({ uploaderFile, useAttachmentUploadPreview, colors }) {
return uploaderFile != null ? useAttachmentUploadPreview ? {
type: MessageEmbedTypes.TEXT,
messageSendError: intl.string(t.lBLP4u),
failureState: MessageFailureState.UNSPECIFIED,
disableBackgroundColor: true,
bodyTextColor: colors.failedMessageBodyTextColor,
iconURL: getAssetUriForEmbed(Module7934)
} : {
type: MessageEmbedTypes.TEXT,
numAttachments: intl.formatToPlainString(t.D0noUt, {
count: uploaderFile.attachmentsCount
}),
failureState: MessageFailureState.UPLOAD_FAILED,
attachmentsSize: "" + (uploaderFile.currentSize !== 0 ? ` (${sizeString(uploaderFile.currentSize)})` : ""),
bodyTextColor: colors.embedBodyTextColor
} : {
type: MessageEmbedTypes.TEXT,
messageSendError: intl.string(t.lBLP4u),
failureState: MessageFailureState.UNSPECIFIED,
disableBackgroundColor: true,
bodyTextColor: colors.failedMessageBodyTextColor
};
};
export function createAutomodBlockedMessageEmbed(a0) {
return {
type: MessageEmbedTypes.TEXT,
messageSendError: a0.errorMessage,
failureState: MessageFailureState.AUTO_MODERATION_BLOCKED_MESSAGE,
disableBackgroundColor: true,
bodyTextColor: a0.colors.automodBlockedBodyTextColor,
iconURL: getAssetUriForEmbed(Module7933)
};
}