feat: preview library block changes in course unit [FC-0062] (#1506)
Creates a new preview library block modal. Intercepts the message when the block is iframed to open the new modal.
This commit is contained in:
@@ -285,10 +285,11 @@ export const useLibraryPasteClipboard = () => {
|
||||
});
|
||||
};
|
||||
|
||||
export const useLibraryBlockMetadata = (usageId: string) => (
|
||||
export const useLibraryBlockMetadata = (usageId: string | undefined) => (
|
||||
useQuery({
|
||||
queryKey: xblockQueryKeys.componentMetadata(usageId),
|
||||
queryFn: () => getLibraryBlockMetadata(usageId),
|
||||
queryKey: xblockQueryKeys.componentMetadata(usageId!),
|
||||
queryFn: () => getLibraryBlockMetadata(usageId!),
|
||||
enabled: !!usageId,
|
||||
})
|
||||
);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user