234 lines
17 KiB
TypeScript
234 lines
17 KiB
TypeScript
/* Metro module 663; source: modules/collectibles/CollectiblesShopConstants.tsx; dependencies: [664, 665, 666, 667, 2] */
|
|
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
|
|
import * as FractionalPremiumSKUsModule from '../../external/discord_common/js/shared/shared-constants/FractionalPremiumSKUs.tsx'; /* Metro dependency 664 */
|
|
import * as CollectibleSearchItemTypeModule from '../../external/discord_common/js/shared/shared-constants/CollectibleSearchItemType.tsx'; /* Metro dependency 665 */
|
|
import * as CollectibleSearchSortTypeModule from '../../external/discord_common/js/shared/shared-constants/CollectibleSearchSortType.tsx'; /* Metro dependency 666 */
|
|
import * as CollectibleSearchSortDirectionModule from '../../external/discord_common/js/shared/shared-constants/CollectibleSearchSortDirection.tsx'; /* Metro dependency 667 */
|
|
|
|
function _fun8013(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#8013, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:713:6, offset: 0x00d317fd, size: 1575 bytes, params: 8, frame: 30
|
|
const env0_0 = require;
|
|
let Object = global.Object;
|
|
Object.defineProperty(exports, '__esModule', {value: true});
|
|
object = {VISIBLE: 0};
|
|
object[0] = 'VISIBLE';
|
|
object.HIDDEN = 1;
|
|
object[1] = 'HIDDEN';
|
|
object.IN = 2;
|
|
object[2] = 'IN';
|
|
object.OUT = 3;
|
|
object[3] = 'OUT';
|
|
const object3 = {HOME: 'home', CATALOG: 'catalog', ORBS: 'orbs', AVATAR_DECORATIONS: 'avatar-decorations',
|
|
PROFILE_EFFECTS: 'profile-effects', NAMEPLATES: 'nameplates', PROFILE_FRAMES: 'profile-frames',
|
|
BUNDLES: 'bundles', LAYOUT: 'layout', COLLECTION_INDEX: 'collection-index', GAME_SHOPS: 'game-shops'};
|
|
const AVATAR_DECORATIONS = object3.AVATAR_DECORATIONS;
|
|
const items4 = [AVATAR_DECORATIONS];
|
|
const PROFILE_EFFECTS = object3.PROFILE_EFFECTS;
|
|
items4[1] = PROFILE_EFFECTS;
|
|
const NAMEPLATES = object3.NAMEPLATES;
|
|
items4[2] = NAMEPLATES;
|
|
const PROFILE_FRAMES = object3.PROFILE_FRAMES;
|
|
items4[3] = PROFILE_FRAMES;
|
|
const BUNDLES = object3.BUNDLES;
|
|
items4[4] = BUNDLES;
|
|
const object4 = {FIAT: 0};
|
|
object4[0] = 'FIAT';
|
|
object4.ORB = 1;
|
|
object4[1] = 'ORB';
|
|
object4.PREMIUM_PURCHASE = 2;
|
|
object4[2] = 'PREMIUM_PURCHASE';
|
|
object4.PROMOTIONAL = 3;
|
|
object4[3] = 'PROMOTIONAL';
|
|
object4.TENURE_REWARD = 4;
|
|
object4[4] = 'TENURE_REWARD';
|
|
object4.GIFT = 5;
|
|
object4[5] = 'GIFT';
|
|
const object5 = {ORB_PROFILE_BADGE: '1342211853484429445'};
|
|
const FractionalPremiumSKUs = (FractionalPremiumSKUsModule).FractionalPremiumSKUs;
|
|
const PREMIUM_TIER_2_3_DAY = FractionalPremiumSKUs.PREMIUM_TIER_2_3_DAY;
|
|
object5.FRACTIONAL_PREMIUM = PREMIUM_TIER_2_3_DAY;
|
|
const PREMIUM_TIER_2_1_DAY = FractionalPremiumSKUs.PREMIUM_TIER_2_1_DAY;
|
|
object5.FRACTIONAL_PREMIUM_1_DAY = PREMIUM_TIER_2_1_DAY;
|
|
const Set = global.Set;
|
|
Object = global.Object;
|
|
const set = new Set(Object.values(object5));
|
|
const CollectibleSearchItemType = (CollectibleSearchItemTypeModule).CollectibleSearchItemType;
|
|
const AVATAR_DECORATION = CollectibleSearchItemType.AVATAR_DECORATION;
|
|
const items2 = [AVATAR_DECORATION];
|
|
const NAMEPLATE = CollectibleSearchItemType.NAMEPLATE;
|
|
items2[1] = NAMEPLATE;
|
|
const PROFILE_EFFECT = CollectibleSearchItemType.PROFILE_EFFECT;
|
|
items2[2] = PROFILE_EFFECT;
|
|
const PROFILE_FRAME = CollectibleSearchItemType.PROFILE_FRAME;
|
|
items2[3] = PROFILE_FRAME;
|
|
const BUNDLE = CollectibleSearchItemType.BUNDLE;
|
|
items2[4] = BUNDLE;
|
|
const object6 = {};
|
|
const CollectibleSearchSortType = (CollectibleSearchSortTypeModule).CollectibleSearchSortType;
|
|
const RELEVANCE = CollectibleSearchSortType.RELEVANCE;
|
|
object6.sortType = RELEVANCE;
|
|
const CollectibleSearchSortDirection = (CollectibleSearchSortDirectionModule).CollectibleSearchSortDirection;
|
|
let DESC = CollectibleSearchSortDirection.DESC;
|
|
object6.sortDirection = DESC;
|
|
const items3 = [object6];
|
|
const RECENCY = CollectibleSearchSortType.RECENCY;
|
|
DESC = CollectibleSearchSortDirection.DESC;
|
|
items3[1] = {sortType: RECENCY, sortDirection: DESC};
|
|
let PRICE = CollectibleSearchSortType.PRICE;
|
|
const ASC = CollectibleSearchSortDirection.ASC;
|
|
items3[2] = {sortType: PRICE, sortDirection: ASC};
|
|
PRICE = CollectibleSearchSortType.PRICE;
|
|
DESC = CollectibleSearchSortDirection.DESC;
|
|
items3[3] = {sortType: PRICE, sortDirection: DESC};
|
|
const POPULARITY = CollectibleSearchSortType.POPULARITY;
|
|
DESC = CollectibleSearchSortDirection.DESC;
|
|
items3[4] = {sortType: POPULARITY, sortDirection: DESC};
|
|
(FileImportTrackerModule).fileFinishedImporting('modules/collectibles/CollectiblesShopConstants.tsx');
|
|
exports.POPULAR_PICK_PRODUCTS = ['1212569433839636530', '1232073608168472638', '1232071712695386162',
|
|
'1212570343567261736', '1232071157746765906', '1144308439720394944', '1139323093991575696',
|
|
'1232070870093008937', '1232073286582538261', '1228234634379132958', '1144307957425778779',
|
|
'1197344764174008452', '1212569856189407352', '1139323093551165533', '1232073448415821854'];
|
|
exports.WISHLIST_POPULAR_SKU_IDS = ['1409898408042303629', '1232073608168472638', '1382845914225442886',
|
|
'1377377712028516443', '1366494385583165630', '1349849614286585866', '1271175049168031815',
|
|
'1349849614311751731', '1420225379246805012', '1437881613903069387', '1436367668881133598',
|
|
'1409898407971127427', '1404558257250373692', '1420045363049398282', '1343751617328975954',
|
|
'1436367668990050304', '1420225379284553810', '1366494385671245826', '1409898407769673900',
|
|
'1314020996327542894', '1412514944712310854', '1420045363171033128', '1333278032768536596'];
|
|
exports.SHOP_CARD_PER_PRODUCT_NEW_BADGE_EXPIRY_SETTINGS = {};
|
|
exports.COLLECTIBLES_SHOP_CACHE_DURATION_MS = 600000;
|
|
exports.COLLECTIBLES_SHOP_FETCH_ERROR_RETRY_THRESHOLD_MS = 600000;
|
|
exports.ViewState = object;
|
|
exports.SEARCH_BAR_ICON_WIDTH_PX = 24;
|
|
exports.SEARCH_BAR_WIDTH_PX = 225;
|
|
exports.STATE_TRANSITION_THRESHOLD_PX = 20;
|
|
exports.CollectiblesSearchBarCTAName = {SEARCH_ICON: 'search icon', SEARCH_BAR: 'search bar',
|
|
SEARCH_BAR_CLEAR: 'search bar clear'};
|
|
exports.CollectibleShopTab = object3;
|
|
exports.CollectiblesIndexPageTabs = items4;
|
|
exports.isIndexPageTab = isIndexPageTab;
|
|
exports.shouldAddTabToUrl = shouldAddTabToUrl;
|
|
exports.SHOP_FEED_TRANSITION_DURATION = 800;
|
|
exports.FEED_ITEMS = ['1212569433839636530', '1144308439720394944', '1314020996201713685', '1212570343567261736',
|
|
'1314020996776329279', '1271174640026255380', '1271175049168031815', '1232073608168472638',
|
|
'1293373563407175680', '1314020996327542894', '1139323093991575696', '1232071157746765906',
|
|
'1232071712695386162', '1144307957425778779', '1306330662990643252', '1280621222496964630',
|
|
'1306330663015809024', '1306330663070334996', '1243617249974288404', '1309668861578186803',
|
|
'1303490165213237338', '1306330662898372639', '1298033986508951685', '1282816432026943488',
|
|
'1306330663137443991', '1197344764174008452', '1298033986727055370', '1298033986571866112',
|
|
'1271175120437641261', '1314020996361093171', '1309668861645426729', '1256321669467865088',
|
|
'1314020996864413717', '1306752744278982737', '1271174732577767626', '1144307257807491094',
|
|
'1144308196723408958', '1287835633787732070', '1306330663162609685', '1306330662940311726',
|
|
'1309668861901279422', '1282816431871754281', '1287835633485877369', '1228234634379132958',
|
|
'1144305233707671573', '1298033986643169360', '1139323093551165533', '1212569856189407352',
|
|
'1282816431850782730', '1144307629225672846', '1232070870093008937', '1207047014769234001',
|
|
'1212582298893946880', '1232073286582538261', '1282816431985004594', '1293373563381878836',
|
|
'1282816431964028958', '1306752744258011166', '1309668861846753372', '1271174324375519273',
|
|
'1256321669426053198', '1287835633615765524', '1286504131325853739', '1306330663183581247',
|
|
'1139323099687436419', '1287835633590734848', '1256321669493166214', '1286504131518791816',
|
|
'1243620093431119922', '1262492035558932604', '1306330662927859723', '1197344326133502032',
|
|
'1228251351415263242', '1232073448415821854', '1158572178179108968', '1298033986752221204',
|
|
'1262491137394868311', '1309668861620260874', '1271174241860980907', '1220513989729976411',
|
|
'1282820582408192061', '1154896005045694555', '1207047597294886923', '1306330663036780695',
|
|
'1309668861674786877', '1197344693630009424', '1306330662965477478', '1174460780842856588',
|
|
'1271174907081789524', '1282816431813169272', '1298033986622328842', '1139323101881061466',
|
|
'1262491690900656267', '1303490165171294268', '1139323100568244355', '1243619479645065287',
|
|
'1262491690971955284', '1316087100260483174', '1139323101008642101', '1228251144065777765',
|
|
'1207048289610899526', '1287835633561239683', '1232072121950146560', '1303490165045727317',
|
|
'1228246010116050965', '1309668861871919316', '1207049364464345158', '1243618816639107223',
|
|
'1265421074514841751', '1316087100277395607', '1159280677246742548', '1262492035558932607',
|
|
'1207047808838799410', '1306752744299954306', '1298033986668335135', '1266160780928352268',
|
|
'1262491137386614812', '1139323092645183591', '1220513977683935373', '1256321669467865091',
|
|
'1237654942202990602', '1287835633536209079', '1262491137394868305', '1256321669493166217',
|
|
'1212582452640350238', '1158572275507937342', '1306752744228524052', '1174459546748600481',
|
|
'1262491137394868308', '1309668861599285249', '1262492035558932610', '1144046002110738634',
|
|
'1293373563184877618', '1298033986693500960', '1285465421260263464', '1306330663091306608',
|
|
'1287835633645125653', '1303490165074825296', '1298033986538569781', '1303490165150322698',
|
|
'1262491690900656261', '1256321669467865094', '1207048656289534022', '1285681070196396177',
|
|
'1287835633674620949', '1237654224712765440', '1293373563121696891', '1303490165255180298',
|
|
'1303490165120962651', '1212582372877541427', '1287835634005970994', '1303490165099991143',
|
|
'1271564593746939904', '1314020996629532686', '1316087100260483176', '1228233390260486164',
|
|
'1287835633867559022', '1158572263411556373', '1303490165192265799', '1237654783209508904',
|
|
'1309668861704146984', '1212581147675205652', '1309668861548957738', '1245088205330710539',
|
|
'1287835633896783952', '1316087100260483178', '1139323099251232828', '1262491690900656258',
|
|
'1232072859485208687', '1197344396983664670', '1309668861788033074', '1314020996600172554',
|
|
'1159280847262859364', '1314020996461760542', '1220514048068812901', '1293373563302318110',
|
|
'1228251846032756796', '1197344636558114986', '1282820582223642624', '1287835634035331072',
|
|
'1298033986777387059', '1243619781362450442', '1282816432001777794', '1212570596970467378',
|
|
'1157409074422481023', '1256321669426053195', '1146328961417224193', '1293373563327483984',
|
|
'1303490165234208810', '1266160780978556969', '1228237157554978817', '1287835633947115570',
|
|
'1282820582345408595', '1271174810227179562', '1282816431830077542', '1287835633842258022',
|
|
'1283211414323990538', '1282820582303334482', '1282820582429298748', '1306330663116472371',
|
|
'1157407831348228141', '1293373563210043442', '1287835633515102228', '1309668861758672997',
|
|
'1287835633703845888', '1287835633733341224', '1197344575832981605', '1316087100260483180',
|
|
'1237653964582031400', '1287835633817227297', '1266493591207940133', '1309668861817393263',
|
|
'1316087100260483182', '1298033986555351132', '1237650542772228096', '1207049498065375343',
|
|
'1287835633980669972', '1314020996516286485', '1285465421193154560', '1268362891946627103',
|
|
'1282820582244880496', '1293373563352649961', '1220432740638523543', '1243620329331626044',
|
|
'1220432697718083614', '1267521289330102344', '1146328960951668776', '1293373563457507463',
|
|
'1245088094437507163', '1262491690900656264', '1314020996432400404', '1220513984273186816',
|
|
'1293373563159449653', '1314020996721803306', '1285681070196396179', '1285465421050548345',
|
|
'1282820582366511229', '1256321669467865097', '1285465421285429258', '1293373563239272458',
|
|
'1271174154514595891', '1217625794382401577', '1228252219502100530', '1285465421029576704',
|
|
'1243618548673417298', '1220432647453409384', '1266493591275044903', '1217626024540508170',
|
|
'1232072520249643028', '1245088254647205991', '1237654867330469949', '1314020996570812506',
|
|
'1314020996227006484', '1245087968759382207', '1144006094134456352', '1314020997166403624',
|
|
'1144048390594908212', '1287835633762701382', '1212581390936178768', '1285465420995756065',
|
|
'1217626509737459852', '1314020996491116575', '1309668861729312898', '1237650411410685972',
|
|
'1245087661316898877', '1217627230818009171', '1256321669388308601', '1314020996310896672',
|
|
'1274105879238676561', '1293373563432341574', '1314020996273016863', '1282816431943057460',
|
|
'1220513995308400680', '1293373563264569416', '1228252042791878707', '1314020997078323200',
|
|
'1237654031732703272', '1267521289355268154', '1298033986592837754', '1285465421214126100',
|
|
'1245087724265013299', '1314020996990242816', '1314020996663087154', '1282820582282629171',
|
|
'1282816431922085888', '1314020997107683411', '1237654124443734026', '1314020997137043578',
|
|
'1266161342801383434', '1285465421096685639', '1237654692985700352', '1174459480348565554',
|
|
'1314020997019602984', '1314020996252176444', '1144003752978829455', '1282816431901118474',
|
|
'1285465421306400858', '1285465421239291904', '1285465420979245087', '1314020996692447234',
|
|
'1144048977138946230', '1217627051217911848', '1217626219651006495', '1217625572168044604',
|
|
'1286504131392962641', '1237650618777075712', '1207048049571139584', '1314020996289921154',
|
|
'1237654615474962472', '1314020996927328276', '1286504131439366184', '1285465421016862730',
|
|
'1217625289681801316', '1243619153688920206', '1217624148080332820', '1144049316009353338',
|
|
'1245481938202918912', '1245088023452975104', '1314020996960882789', '1285465421121851445',
|
|
'1243617981435478102', '1144049603109470370', '1285465421071519825', '1256321669426053192',
|
|
'1245087912350187520', '1207049115339591681', '1144049924397334651', '1237649939027333232',
|
|
'1237650103980920872', '1237650023794081823', '1237650179721527347', '1245087850177888356',
|
|
'1285465421167988758', '1277733174797008931'];
|
|
exports.PAGE_SIZE = 12;
|
|
exports.LIMITED_TIME_BADGE_DAYS_THRESHOLD = 60;
|
|
exports.MAX_FEED_SIZE = 36;
|
|
exports.SHOP_ALL_PAGE_SIZE = 5;
|
|
exports.ShopPurchaseType = object4;
|
|
exports.EXTERNAL_PRODUCT_SKU_IDS = object5;
|
|
exports.isFractionalPremiumSku = function(a0) {
|
|
var ALL = require(dependencyMap[0]).FractionalPremiumSKUsSets.ALL;
|
|
return ALL.has(a0);
|
|
};
|
|
exports.isExternalProduct = isExternalProduct;
|
|
exports.ALL_FILTERS = items2;
|
|
exports.SORT_OPTIONS = items3;
|
|
exports.CollectiblesMobileShopScreen = {FEATURED_PAGE: 'featured-page', SHOP_ALL: 'shop-all', ORBS: 'orbs'};
|
|
exports.REWARD_CATEGORY_AND_REWARD_SKU_IDS = [{'categorySkuId': '1440063059895779408',
|
|
'rewardSkuId': '1440063059862487193'}];
|
|
exports.ShopCtaEnum = {BUY_WITH_FIAT: 'buy_with_fiat', BUY_WITH_ORBS: 'buy_with_orbs', SEND_AS_GIFT: 'send_as_gift',
|
|
SUBSCRIBE_NOW: 'subscribe_now', ADD_TO_WISHLIST: 'add_to_wishlist',
|
|
REMOVE_FROM_WISHLIST: 'remove_from_wishlist', CLOSE_DETAIL: 'close_detail', COPY_LINK: 'copy_link',
|
|
USE_NOW: 'use_now', EDIT_PROFILE: 'edit_profile', UNLOCK_WITH_NITRO: 'unlock_with_nitro',
|
|
ADD_TO_COLLECTION: 'add_to_collection', BUNDLE_VIEW_AVATAR_DECORATION: 'bundle_view_avatar_decoration',
|
|
BUNDLE_VIEW_PROFILE_EFFECT: 'bundle_view_profile_effect', BUNDLE_VIEW_NAMEPLATE: 'bundle_view_nameplate',
|
|
FULL_PROFILE_PREVIEW: 'full_profile_preview', FULL_PROFILE_PREVIEW_BUTTON: 'full_profile_preview_button',
|
|
VIEW_DETAILS: 'view_details', PAYMENT_OPTIONS: 'payment_options', OPEN_DETAILS: 'open_details',
|
|
VARIANT_CLICK: 'variant_click', VARIANT_CLICK_MORE: 'variant_click_more'};
|
|
function isIndexPageTab(a0) { // fn#8014, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:713:4229, offset: 0x00d31e24, size: 22 bytes, params: 2, frame: 11
|
|
return env0_3.includes(a0);
|
|
}
|
|
|
|
function shouldAddTabToUrl(a0) { // fn#8015, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:713:4266, offset: 0x00d31e3a, size: 71 bytes, params: 2, frame: 3
|
|
return a0 != null && a0 !== env0_2.HOME && a0 !== env0_2.CATALOG && a0 !== env0_2.GAME_SHOPS;
|
|
}
|
|
|
|
function isExternalProduct(a0) { // fn#8017, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:713:11960, offset: 0x00d31eb4, size: 22 bytes, params: 2, frame: 11
|
|
return env0_4.has(a0);
|
|
}
|
|
|
|
}
|
|
|
|
global.__d(_fun8013, 663, [664, 665, 666, 667, 2]) /* metro module 663, dependencies: [664, 665, 666, 667, 2] */;
|