Skip to content

Commit a5b22ab

Browse files
committed
Fix overflowing content with custom stage size
1 parent f31e9b1 commit a5b22ab

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

src/playground/interface.css

-2
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,6 @@ a {
4646
}
4747

4848
.editor {
49-
min-width: 1024px;
50-
min-height: 640px;
5149
height: 100%;
5250
}
5351
.editor .center {

src/playground/render-interface.jsx

+4
Original file line numberDiff line numberDiff line change
@@ -218,6 +218,10 @@ class Interface extends React.Component {
218218
[styles.playerOnly]: isHomepage,
219219
[styles.editor]: isEditor
220220
})}
221+
style={{
222+
minWidth: isEditor ? 1024 + Math.max(0, this.props.customStageSize.width - 480) : '',
223+
minHeight: isEditor ? 640 + Math.max(0, this.props.customStageSize.height - 360) : ''
224+
}}
221225
>
222226
{isHomepage ? (
223227
<div className={styles.menu}>

0 commit comments

Comments
 (0)