|
|
|
@ -1,3 +1,5 @@ |
|
|
|
import Component from '../model/Component'; |
|
|
|
|
|
|
|
export interface DomComponentsConfig { |
|
|
|
stylePrefix?: string; |
|
|
|
|
|
|
|
@ -12,6 +14,19 @@ export interface DomComponentsConfig { |
|
|
|
*/ |
|
|
|
draggableComponents?: boolean; |
|
|
|
|
|
|
|
/** |
|
|
|
* Experimental: Disable text inner components. |
|
|
|
* With this option, you're able to decide which inner component inside text should be |
|
|
|
* disabled (eg. no select, no hover, no layer visibility) once edited. |
|
|
|
* @default false |
|
|
|
* @example |
|
|
|
* // disable all inner childs
|
|
|
|
* disableTextInnerChilds: true, |
|
|
|
* // disable all except link components
|
|
|
|
* disableTextInnerChilds: (child) => !child.is('link'), |
|
|
|
*/ |
|
|
|
disableTextInnerChilds?: boolean | ((cmp: Component) => boolean | void); |
|
|
|
|
|
|
|
/** |
|
|
|
* You can setup a custom component definition processor before adding it into the editor. |
|
|
|
* It might be useful to transform custom objects (es. some framework specific JSX) to GrapesJS component one. |
|
|
|
@ -44,6 +59,7 @@ export default { |
|
|
|
stylePrefix: 'comp-', |
|
|
|
components: [], |
|
|
|
draggableComponents: true, |
|
|
|
disableTextInnerChilds: false, |
|
|
|
processor: undefined, |
|
|
|
voidElements: [ |
|
|
|
'area', |
|
|
|
|