diff --git a/src/blocks.ts b/src/blocks.ts index 08d473f..1d9fb18 100644 --- a/src/blocks.ts +++ b/src/blocks.ts @@ -232,7 +232,7 @@ export default function(editor: Editor, opts: Required) { content: { type: 'text', content: 'Insert your text here', - style: { padding: '10px' }, + ...addBasicStyle && { style: { padding: '10px' } }, } }); @@ -246,7 +246,7 @@ export default function(editor: Editor, opts: Required) { content: { type: 'link', content: 'Link', - style: { color: '#d983a6' } + ...addBasicStyle && { style: { color: '#d983a6' } }, } }); @@ -259,8 +259,8 @@ export default function(editor: Editor, opts: Required) { `, content: { - style: { color: 'black' }, type: 'image', + ...addBasicStyle && { style: { color: 'black' } }, } }); @@ -274,10 +274,7 @@ export default function(editor: Editor, opts: Required) { content: { type: 'video', src: 'img/video2.webm', - style: { - height: '350px', - width: '615px' - } + ...addBasicStyle && { style: { height: '350px', width: '615px' } }, } }); @@ -290,7 +287,7 @@ export default function(editor: Editor, opts: Required) { `, content: { type: 'map', - style: { height: '350px' } + ...addBasicStyle && { style: { height: '350px' } }, } }); }