2026-08-25 06:04:03 +00:00
|
|
|
// Module ID: 7464
|
|
|
|
|
// Function ID: 7465
|
2026-07-20 16:05:17 +00:00
|
|
|
// Name: getHasImportantUnread
|
2026-08-25 06:04:03 +00:00
|
|
|
// Dependencies: [4395, 4589, 4590, 589, 2]
|
2026-07-20 16:05:17 +00:00
|
|
|
// Exports: getHasImportantUnread, useHasImportantUnread
|
|
|
|
|
|
2026-08-25 06:04:03 +00:00
|
|
|
// Module 7464 (getHasImportantUnread)
|
|
|
|
|
import closure_2 from "generateOldThreadCutoff" /* 4395 */;
|
|
|
|
|
import closure_3 from "updateUserGuildSettingsInternal" /* 4589 */;
|
|
|
|
|
import { UnreadSetting } from "ReadStateTypes" /* 4590 */;
|
2026-07-23 10:11:24 +00:00
|
|
|
|
|
|
|
|
const require = arg1;
|
2026-08-24 06:08:38 +00:00
|
|
|
const result = require("set").fileFinishedImporting("modules/read_states/ReadStateUtils.tsx");
|
2026-07-20 16:05:17 +00:00
|
|
|
|
|
|
|
|
export const getHasImportantUnread = function getHasImportantUnread(channel) {
|
2026-08-24 06:08:38 +00:00
|
|
|
let hasUnreadResult = closure_2.hasUnread(channel.id);
|
2026-07-20 16:05:17 +00:00
|
|
|
if (hasUnreadResult) {
|
2026-08-24 06:08:38 +00:00
|
|
|
hasUnreadResult = closure_3.resolveUnreadSetting(channel) === UnreadSetting.ALL_MESSAGES;
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
|
|
|
|
return hasUnreadResult;
|
|
|
|
|
};
|
|
|
|
|
export const useHasImportantUnread = function useHasImportantUnread(arg0) {
|
2026-07-23 10:11:24 +00:00
|
|
|
const _require = arg0;
|
2026-08-24 06:08:38 +00:00
|
|
|
const items = [closure_2, closure_3];
|
2026-07-29 08:29:29 +00:00
|
|
|
return _require(589).useStateFromStores(items, () => {
|
2026-08-24 06:08:38 +00:00
|
|
|
let hasUnreadResult = closure_1_2.hasUnread(id.id);
|
2026-07-20 16:05:17 +00:00
|
|
|
if (hasUnreadResult) {
|
2026-08-24 06:08:38 +00:00
|
|
|
hasUnreadResult = closure_1_3.resolveUnreadSetting(id) === closure_1_4.ALL_MESSAGES;
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
|
|
|
|
return hasUnreadResult;
|
|
|
|
|
});
|
|
|
|
|
};
|