decord/source/modules/parent_tools/native/FamilyCenterActivityGiftRow.tsx
2026-07-31 08:44:05 +00:00

94 lines
3.3 KiB
TypeScript

// Module ID: 13955
// Function ID: 13956
// Name: FamilyCenterActivityGiftRow
// Dependencies: [19, 17, 21, 4193, 712, 7959, 13943, 13952, 13954, 4032, 13953, 4189, 2]
// Exports: default
// Module 13955 (FamilyCenterActivityGiftRow)
import "noop";
import { View } from "get ActivityIndicator";
import jsxProd from "jsxProd";
import createCacheKey from "createCacheKey";
let c4;
let c5;
const require = arg1;
({ jsx: c4, jsxs: c5 } = jsxProd);
createCacheKey = { container: null, textContainer: null };
createCacheKey = { display: "flex", flexDirection: "row", alignItems: "center", borderBottomColor: require("Themes").colors.BORDER_SUBTLE, borderBottomWidth: 1, paddingVertical: 12 };
createCacheKey[0] = createCacheKey;
createCacheKey[1] = { display: "flex", flexDirection: "column", flexShrink: 1 };
createCacheKey = createCacheKey.createStyles(createCacheKey);
const result = require("jsxProd").fileFinishedImporting("modules/parent_tools/native/FamilyCenterActivityGiftRow.tsx");
export default function FamilyCenterActivityGiftRow(arg0) {
let claimed;
let claimedAt;
let displayName;
let gifterUserId;
let isSubscription;
let offeredAt;
let price;
let skuId;
let subscriptionPlanId;
({ skuId, subscriptionPlanId } = arg0);
({ price, gifterUserId, claimed, offeredAt, claimedAt } = arg0);
const tmp = createCacheKey();
let product = importDefault(7959)(skuId).product;
let obj = require(13943) /* useSelectedTeenUser */;
const teenUserForId = obj.useTeenUserForId(gifterUserId);
let obj1 = require(13952) /* getCollectibleTypeName */;
let tmp7 = product;
if (product == null) {
tmp7 = null;
}
const purchaseDisplayInfo = obj1.getPurchaseDisplayInfo(tmp7, subscriptionPlanId);
({ displayName, isSubscription } = purchaseDisplayInfo);
if (null != skuId) {
if (!isSubscription) {
if (null == product) {
return null;
}
}
}
if (null == displayName) {
return null;
} else {
obj = { claimed: null, price: null, gifterName: null, offeredAt: null, claimedAt: null };
obj[0] = claimed;
obj[1] = price;
let name = null;
if (null != teenUserForId) {
let tmp2Result = tmp2(4032);
name = tmp2Result.getName(teenUserForId);
}
obj[2] = name;
obj[3] = offeredAt;
obj[4] = claimedAt;
obj = { style: null, children: null };
obj[0] = tmp.container;
const giftSubtext = tmp5(13954).getGiftSubtext(obj);
obj1 = { displayName: null, product: null, isSubscription: null, subscriptionPlanId: null };
obj1[0] = displayName;
tmp2Result = tmp2(13953);
if (product == null) {
product = null;
}
obj1[1] = product;
obj1[2] = isSubscription;
obj1[3] = subscriptionPlanId;
const items = [closure_4(tmp2Result, obj1), ];
const obj2 = { style: null, children: null };
obj2[0] = tmp.textContainer;
const obj3 = { variant: "text-md/semibold", color: "interactive-text-active", ellipsizeMode: "tail", lineClamp: 1, children: null };
obj3[4] = displayName;
const items1 = [closure_4(tmp5(4189).Text, obj3), ];
const obj4 = { variant: "text-xs/medium", color: "text-muted", children: null };
obj4[2] = giftSubtext;
items1[1] = closure_4(tmp5(4189).Text, obj4);
obj2[1] = items1;
items[1] = closure_5(View, obj2);
obj[1] = items;
return closure_5(View, obj);
}
};