decord/source/modules/conversations/useConversationBackoffRef.tsx

28 lines
844 B
TypeScript
Raw Normal View History

2026-08-25 06:04:03 +00:00
// Module ID: 8710
// Function ID: 8711
2026-07-20 16:05:17 +00:00
// Name: useConversationBackoffRef
2026-08-25 06:04:03 +00:00
// Dependencies: [19, 7204, 584, 2]
2026-07-20 16:05:17 +00:00
// Exports: useConversationBackoffRef
2026-08-25 06:04:03 +00:00
// Module 8710 (useConversationBackoffRef)
2026-08-24 06:08:38 +00:00
import closure_2 from "noop" /* 19 */;
2026-08-25 06:04:03 +00:00
import CONVERSATION_COLORS from "CONVERSATION_COLORS" /* 7204 */;
2026-07-23 10:11:24 +00:00
2026-07-29 08:29:29 +00:00
({ FETCH_BACKOFF_MAX_MS: c3, FETCH_BACKOFF_MIN_MS: c4 } = CONVERSATION_COLORS);
2026-08-24 06:08:38 +00:00
const result = require("set").fileFinishedImporting("modules/conversations/useConversationBackoffRef.tsx");
2026-07-20 16:05:17 +00:00
export const useConversationBackoffRef = function useConversationBackoffRef(items) {
if (items === undefined) {
items = [];
}
2026-07-23 10:11:24 +00:00
let ref;
2026-07-29 08:29:29 +00:00
ref = React.useRef(new ref(584)(closure_4, closure_3));
2026-07-23 10:11:24 +00:00
const effect = React.useEffect(() => {
current = current.current;
return () => {
current.succeed();
};
2026-07-20 16:05:17 +00:00
}, items);
return ref;
};