decord/source/modules/polls/chat/buildPlatformPollResources.native.tsx
github-actions f0f877e8ce chore: update source for alpha 347.1
Skipped 1 file(s) >100MB (GitHub limit): source/__polyfill/04xxx/module_4824.js (118.4 MB)
2026-09-15 14:23:42 +00:00

54 lines
2 KiB
TypeScript

// Module ID: 11852
// Function ID: 11853
// Name: buildPlatformPollResources
// Dependencies: [12, 11853, 4639, 576, 8053, 7251, 5703, 1400, 2]
// Exports: buildPlatformPollResources, getAvatarUrl
// Module 11852 (buildPlatformPollResources)
import nativeDefault from "native" /* 576 */;
import utils_AvatarUtils from "utils/AvatarUtils" /* 1400 */;
import _modDef5703 from "module_5703" /* 5703 */;
import _modDef7251 from "module_7251" /* 7251 */;
import renderer_EmbedUtils from "renderer/EmbedUtils" /* 8053 */;
import apply from "module_12" /* 12 */;
require = fn;
let closure_3 = apply.mapValues(fn(11853).pollStyleSets, (arg0) => {
_require = arg0;
closure_1 = require("createStyles").createNativeStyleProperties((arg0) => {
let tmp = closure_0(nativeDefault, arg0);
return apply.pickBy(tmp, (num) => {
let tmp = typeof num !== "number";
if (typeof num !== "number") {
tmp = typeof num !== "boolean";
}
return tmp;
});
});
return (arg0, arg1) => {
let tmp = closure_0(nativeDefault, arg1);
const merged = Object.assign(closure_1(arg0, arg1));
const merged1 = Object.assign(apply.pickBy(tmp, (num) => {
let tmp = typeof num === "number";
if (typeof num !== "number") {
tmp = typeof num === "boolean";
}
return tmp;
}));
return {};
};
});
const size = fn(2);
const result = size.fileFinishedImporting("modules/polls/chat/buildPlatformPollResources.native.tsx");
export const buildPlatformPollResources = function buildPlatformPollResources(theme, layoutType) {
closure_0 = theme;
closure_1 = layoutType;
const obj = { styles: apply.mapValues(closure_3, (fn) => fn(closure_0, closure_1)), selectedIcon: null, checkmarkIcon: null };
obj.selectedIcon = renderer_EmbedUtils.getAssetUriForEmbed(_modDef7251);
obj.checkmarkIcon = renderer_EmbedUtils.getAssetUriForEmbed(_modDef5703);
return obj;
};
export const getAvatarUrl = function getAvatarUrl(currentUser, guildId) {
return utils_AvatarUtils.ensureAvatarSource(currentUser.getAvatarSource(guildId, false)).uri;
};