Skip to content

armgit / macro

Public Imported from GitHub
0

Macro is a unified workspace for teams: email, chat, docs, tasks, agents, calls, and CRM — @-linked together with shared AI memory.

unified-infinite-list remove logs (#699)

Caleb Taylord306839cf4d1
diff --git a/js/app/packages/macro-entity/src/components/UnifiedInfiniteList.tsx b/js/app/packages/macro-entity/src/components/UnifiedInfiniteList.tsx
index 328ffecb31..a7fa55ecd1 100644
--- a/js/app/packages/macro-entity/src/components/UnifiedInfiniteList.tsx
+++ b/js/app/packages/macro-entity/src/components/UnifiedInfiniteList.tsx
@@ -494,9 +494,7 @@ export function createUnifiedInfiniteList<T extends EntityData>({
const restoreScrollPosition = () => {
const handle = virtualizerHandle();
const { offset: cachedOffset } = cacheMap.get(cacheKey) || { offset: 0 };
- console.log('restoreScrollPosition', { cacheKey, handle, cachedOffset });
if (handle && cachedOffset) {
- console.log({ cachedOffset });
handle.scrollTo(cachedOffset);
}
};
@@ -515,8 +513,7 @@ export function createUnifiedInfiniteList<T extends EntityData>({
if (handle && key) {
const { scrollOffset } = handle;
- console.log('cacheVirtualizerHandle', { key, scrollOffset });
- cacheMap.set(key, { offset: handle.scrollOffset });
+ cacheMap.set(key, { offset: scrollOffset });
}
};
const { isPending } = useSuspenseContext();
@@ -531,7 +528,6 @@ export function createUnifiedInfiniteList<T extends EntityData>({
isPending,
(isPending, prevIsPending) => {
if (isPending) {
- console.log(cacheKey, 'cache BY SUSPENSE');
cacheVirtualizerHandle();
}
if (isPending === false && prevIsPending === true) {