From a1181f3d49edfd3232c920dcb567e70fb7c86139 Mon Sep 17 00:00:00 2001 From: David Ormsbee Date: Tue, 15 Oct 2024 00:16:25 -0400 Subject: [PATCH] refactor: switch Content Library XBlock preview to Studio edx-platform commit 7316111 (PR #35598) moved the XBlock embed view so that it can be rendered on either LMS or Studio. This commit moves the frontend to actually call the Studio endpoint. This will make Content Library static asset display easier, because that view will only be made available through Studio and not the LMS. --- src/library-authoring/LibraryBlock/LibraryBlock.tsx | 4 ++-- .../component-info/ComponentPreview.test.tsx | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/library-authoring/LibraryBlock/LibraryBlock.tsx b/src/library-authoring/LibraryBlock/LibraryBlock.tsx index 87defc0d8..dd4920612 100644 --- a/src/library-authoring/LibraryBlock/LibraryBlock.tsx +++ b/src/library-authoring/LibraryBlock/LibraryBlock.tsx @@ -20,7 +20,7 @@ interface LibraryBlockProps { const LibraryBlock = ({ onBlockNotification, usageKey }: LibraryBlockProps) => { const iframeRef = useRef(null); const [iFrameHeight, setIFrameHeight] = useState(600); - const lmsBaseUrl = getConfig().LMS_BASE_URL; + const studioBaseUrl = getConfig().STUDIO_BASE_URL; const intl = useIntl(); @@ -74,7 +74,7 @@ const LibraryBlock = ({ onBlockNotification, usageKey }: LibraryBlockProps) => {