fix: Height in Advanced Editor [FC-0076] (#1649)

Updates the height of the Advanced Editor.
This commit is contained in:
Chris Chávez
2025-02-13 11:22:02 -05:00
committed by GitHub
parent 0b08d82f03
commit 59243b0cb3

View File

@@ -28,7 +28,10 @@ export const LibraryBlock = ({
view,
}: LibraryBlockProps) => {
const iframeRef = useRef<HTMLIFrameElement>(null);
const [iFrameHeight, setIFrameHeight] = useState(50);
const xblockView = view ?? 'student_view';
const defaultiFrameHeight = xblockView === 'studio_view' ? 80 : 50;
const [iFrameHeight, setIFrameHeight] = useState(defaultiFrameHeight);
const studioBaseUrl = getConfig().STUDIO_BASE_URL;
const intl = useIntl();
@@ -77,8 +80,6 @@ export const LibraryBlock = ({
const queryStr = version ? `?version=${version}` : '';
const xblockView = view ?? 'student_view';
return (
<div style={{
height: `${iFrameHeight}vh`,