Sandbox: Set sandbox wrapper to height 100% for panel plugins (#75004)

Sandbox: Fix panel plugin not showing scrollbars
This commit is contained in:
Esteban Beltran 2023-09-19 09:11:56 +02:00 committed by GitHub
parent ec69e903ea
commit 62d0becd25
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -92,7 +92,10 @@ const withSandboxWrapper = <P extends object>(
): React.MemoExoticComponent<FC<P>> => {
const WithWrapper = React.memo((props: P) => {
return (
<div data-plugin-sandbox={pluginMeta.id} style={{ height: pluginMeta.type === PluginType.app ? '100%' : 'auto' }}>
<div
data-plugin-sandbox={pluginMeta.id}
style={{ height: pluginMeta.type === PluginType.app || pluginMeta.type === PluginType.panel ? '100%' : 'auto' }}
>
<WrappedComponent {...props} />
</div>
);