decord/source/modules/user_profile/utils/shouldShowActivityTimeBar.tsx

29 lines
787 B
TypeScript
Raw Normal View History

// Module ID: 13137
// Function ID: 13138
2026-07-20 16:05:17 +00:00
// Name: shouldShowActivityTimeBar
// Dependencies: [1074, 2]
2026-07-20 16:05:17 +00:00
// Exports: default
// Module 13137 (shouldShowActivityTimeBar)
import Constants from "Constants" /* 1074 */;
import size from "module_2" /* 2 */;
2026-07-23 10:11:24 +00:00
const ActivityTypes = Constants.ActivityTypes;
const result = size.fileFinishedImporting("modules/user_profile/utils/shouldShowActivityTimeBar.tsx");
2026-07-20 16:05:17 +00:00
export default function shouldShowActivityTimeBar(type) {
2026-07-29 08:29:29 +00:00
let tmp2 = type.type === ActivityTypes.LISTENING || type.type === tmp.WATCHING;
if (tmp2) {
2026-07-20 16:05:17 +00:00
const timestamps = type.timestamps;
let start;
2026-07-29 08:29:29 +00:00
if (timestamps != null) {
2026-07-20 16:05:17 +00:00
start = timestamps.start;
}
2026-07-29 08:29:29 +00:00
tmp2 = null != start;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
if (tmp2) {
tmp2 = null != type.timestamps.end;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
return tmp2;
2026-07-20 16:05:17 +00:00
};