Skip to content

Commit

Permalink
add grid media field to layout refresh (#4663)
Browse files Browse the repository at this point in the history
  • Loading branch information
benjaminpkane authored Aug 12, 2024
1 parent 2e0e2aa commit 3393ba0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion app/packages/core/src/components/Grid/useRefreshers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,18 @@ export default function useRefreshers() {
const extendedStages = fos.stringifyObj(useRecoilValue(fos.extendedStages));
const filters = fos.stringifyObj(useRecoilValue(fos.filters));
const groupSlice = useRecoilValue(fos.groupSlice);
const mediaField = useRecoilValue(fos.selectedMediaField(false));
const refresher = useRecoilValue(fos.refresher);
const shouldRenderImaVidLooker = useRecoilValue(fos.shouldRenderImaVidLooker);
const view = fos.filterView(useRecoilValue(fos.view));

// only reload, attempt to return to the last grid location
const layoutReset = useMemo(() => {
cropToContent;
mediaField;
refresher;
return uuid();
}, [cropToContent, refresher]);
}, [cropToContent, mediaField, refresher]);

// the values reset the page, i.e. return to the top
const pageReset = useMemo(() => {
Expand Down

0 comments on commit 3393ba0

Please sign in to comment.