Skip to content

Commit

Permalink
Re-render panels when context changes (#8407)
Browse files Browse the repository at this point in the history
  • Loading branch information
SchrodingersGat authored Nov 2, 2024
1 parent 18e5b0d commit cc6a2f4
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/frontend/src/hooks/UsePluginPanels.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -76,14 +76,15 @@ export function usePluginPanels({

// Cache the context data which is delivered to the plugins
const inventreeContext = useInvenTreeContext();

const contextData = useMemo<PluginPanelContext>(() => {
return {
model: model,
id: id,
instance: instance,
...inventreeContext
};
}, [model, id, instance]);
}, [model, id, instance, inventreeContext]);

const pluginPanels: PanelType[] = useMemo(() => {
return (
Expand Down

0 comments on commit cc6a2f4

Please sign in to comment.