decord/source/modules/game_profile/GameProfileReviewUtils.tsx

84 lines
5 KiB
TypeScript
Raw Normal View History

2026-07-25 08:10:48 +00:00
// Module ID: 8455
2026-07-27 11:26:19 +00:00
// Function ID: 67384
2026-07-20 16:05:17 +00:00
// Name: getSteamReviewScoreDescriptionColor
2026-07-25 08:10:48 +00:00
// Dependencies: [4165, 1212, 2]
2026-07-20 16:05:17 +00:00
// Exports: canShowLocalizedSteamReview, getSteamReviewScoreDescriptionColor, getSteamReviewScoreDescriptionIntl
2026-07-25 08:10:48 +00:00
// Module 8455 (getSteamReviewScoreDescriptionColor)
2026-07-23 10:11:24 +00:00
const result = require("set").fileFinishedImporting("modules/game_profile/GameProfileReviewUtils.tsx");
2026-07-20 16:05:17 +00:00
export const getSteamReviewScoreDescriptionColor = function getSteamReviewScoreDescriptionColor(NO_USER_REVIEWS) {
2026-07-25 08:10:48 +00:00
if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.NO_USER_REVIEWS === NO_USER_REVIEWS) {
2026-07-20 16:05:17 +00:00
return "text-subtle";
} else {
2026-07-25 08:10:48 +00:00
if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.OVERWHELMINGLY_POSITIVE !== NO_USER_REVIEWS) {
if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.VERY_POSITIVE !== NO_USER_REVIEWS) {
if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.POSITIVE !== NO_USER_REVIEWS) {
if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.MOSTLY_POSITIVE !== NO_USER_REVIEWS) {
if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.MIXED === NO_USER_REVIEWS) {
2026-07-20 16:05:17 +00:00
return "steam-review-text-mixed";
} else {
2026-07-25 08:10:48 +00:00
if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.MOSTLY_NEGATIVE !== NO_USER_REVIEWS) {
if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.NEGATIVE !== NO_USER_REVIEWS) {
if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.VERY_NEGATIVE !== NO_USER_REVIEWS) {
if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.OVERWHELMINGLY_NEGATIVE !== NO_USER_REVIEWS) {
2026-07-20 16:05:17 +00:00
return "text-subtle";
}
}
}
}
return "steam-review-text-negative";
}
}
}
}
}
return "steam-review-text-positive";
}
};
export const getSteamReviewScoreDescriptionIntl = function getSteamReviewScoreDescriptionIntl(result) {
2026-07-25 08:10:48 +00:00
if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.NO_USER_REVIEWS === result) {
2026-07-23 10:11:24 +00:00
const intl10 = require(1212) /* getSystemLocale */.intl;
return intl10.string(require(1212) /* getSystemLocale */.t.CLMt8J);
2026-07-25 08:10:48 +00:00
} else if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.OVERWHELMINGLY_POSITIVE === result) {
2026-07-23 10:11:24 +00:00
const intl9 = require(1212) /* getSystemLocale */.intl;
return intl9.string(require(1212) /* getSystemLocale */.t["75sx1S"]);
2026-07-25 08:10:48 +00:00
} else if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.VERY_POSITIVE === result) {
2026-07-23 10:11:24 +00:00
const intl8 = require(1212) /* getSystemLocale */.intl;
return intl8.string(require(1212) /* getSystemLocale */.t["EkOVg+"]);
2026-07-25 08:10:48 +00:00
} else if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.POSITIVE === result) {
2026-07-23 10:11:24 +00:00
const intl7 = require(1212) /* getSystemLocale */.intl;
return intl7.string(require(1212) /* getSystemLocale */.t.ZUkFtr);
2026-07-25 08:10:48 +00:00
} else if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.MOSTLY_POSITIVE === result) {
2026-07-23 10:11:24 +00:00
const intl6 = require(1212) /* getSystemLocale */.intl;
return intl6.string(require(1212) /* getSystemLocale */.t.M7Z09a);
2026-07-25 08:10:48 +00:00
} else if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.MIXED === result) {
2026-07-23 10:11:24 +00:00
const intl5 = require(1212) /* getSystemLocale */.intl;
return intl5.string(require(1212) /* getSystemLocale */.t.c8yuHR);
2026-07-25 08:10:48 +00:00
} else if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.MOSTLY_NEGATIVE === result) {
2026-07-23 10:11:24 +00:00
const intl4 = require(1212) /* getSystemLocale */.intl;
return intl4.string(require(1212) /* getSystemLocale */.t.H0MSjG);
2026-07-25 08:10:48 +00:00
} else if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.NEGATIVE === result) {
2026-07-23 10:11:24 +00:00
const intl3 = require(1212) /* getSystemLocale */.intl;
return intl3.string(require(1212) /* getSystemLocale */.t.vpLrgz);
2026-07-25 08:10:48 +00:00
} else if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.VERY_NEGATIVE === result) {
2026-07-23 10:11:24 +00:00
const intl2 = require(1212) /* getSystemLocale */.intl;
return intl2.string(require(1212) /* getSystemLocale */.t["5spYuX"]);
2026-07-25 08:10:48 +00:00
} else if (require(4165) /* _isNativeReflectConstruct */.SteamReviewScoreDescription.OVERWHELMINGLY_NEGATIVE === result) {
2026-07-23 10:11:24 +00:00
const intl = require(1212) /* getSystemLocale */.intl;
return intl.string(require(1212) /* getSystemLocale */.t.A8uk5J);
2026-07-20 16:05:17 +00:00
} else {
return null;
}
};
export const canShowLocalizedSteamReview = function canShowLocalizedSteamReview(steam) {
let tmp = null != steam && null != steam.localizedRating && null != steam.localizedRatingCount && null != steam.ratingCount;
if (tmp) {
tmp = steam.localizedRatingCount >= 200;
}
if (tmp) {
tmp = steam.ratingCount >= 2000;
}
return tmp;
};