Fix unused plugins not being able to be dragged into the preview
This commit is contained in:
parent
fecb8bb1a6
commit
dabc93e1b6
|
@ -21,13 +21,13 @@ const createDndStore = () => {
|
||||||
}
|
}
|
||||||
|
|
||||||
const startDraggingNewComponent = ({ component, definition }) => {
|
const startDraggingNewComponent = ({ component, definition }) => {
|
||||||
if (!component || !definition) {
|
if (!component) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
// Get size of new component so we can show a properly sized placeholder
|
// Get size of new component so we can show a properly sized placeholder
|
||||||
const width = definition.size?.width || 128
|
const width = definition?.size?.width || 128
|
||||||
const height = definition.size?.height || 64
|
const height = definition?.size?.height || 64
|
||||||
|
|
||||||
store.set({
|
store.set({
|
||||||
...initialState,
|
...initialState,
|
||||||
|
|
Loading…
Reference in New Issue