- Support 2 types of snippet are container and component. Container snippet can be dropped only into content area and component snippet can be dropped only into container.
- New options for toolbar buttons:
/**
* @option {String} btnMoveContainerText Text content for move button of container
* @option {String} btnMoveComponentText Text content for move button of component
* @option {String} btnSettingContainerText Text content for setting button of container
* @option {String} btnSettingComponentText Text content for setting button of component
* @option {String} btnDuplicateContainerText Text content for duplicate button of container
* @option {String} btnDuplicateComponentText Text content for duplicate button of component
* @option {String} btnDeleteContainerText Text content for delete button of container
* @option {String} btnDeleteComponentText Text content for delete button of component
*/
- New options for handle default component type
/**
* @option {String|Function} defaultComponentType Default component type of component. If type of component does not exist in KEditor.components, will be used 'defaultComponentType' as type of this component. If is function, argument is component - jQuery object of component
*/
- New callbacks for container
/**
* @option {Function} onInitContainer Callback will be called when initializing container. It can return array of jQuery objects which will be initialized as editable components in container content (NOTE: these objects MUST be under elements which have attribute data-type="container-content"). By default, all first level sections under container content will be initialized. Arguments: container
* @option {Function} onBeforeContainerDeleted Callback will be called before container is deleted. Arguments: event, selectedContainer
* @option {Function} onContainerDeleted Callback will be called after container and its components are already deleted. Arguments: event, selectedContainer
* @option {Function} onContainerChanged Callback will be called when content of container is changed. It can be when container received new component from snippet or from other container. Or content of any components are changed or any components are deleted or duplicated. Arguments: event, changedContainer
* @option {Function} onContainerDuplicated Callback will be called when a container is duplicated. Arguments: event, originalContainer, newContainer
* @option {Function} onContainerSelected Callback will be called when a container is selected. Arguments: event, selectedContainer
* @option {Function} onContainerSnippetDropped Callback will be called when a container snippet is dropped into content area. Arguments: event, newContainer, droppedContainer
- New callbacks for component
/**
* @option {Function} onComponentReady Callback will be called after component is initialized. This callback is available or not is depend on component type handler.
* @option {Function} onInitComponent Callback will be called when initializing component. Arguments: component
* @option {Function} onBeforeComponentDeleted Callback will be called before a component is deleted. Arguments: event, selectedComponent
* @option {Function} onComponentDeleted Callback will be called after a component is deleted. Arguments: event, selectedComponent
* @option {Function} onComponentChanged Callback will be called when content of a component is changed. Arguments: event, changedComponent
* @option {Function} onComponentDuplicated Callback will be called when a component is duplicated. Arguments: event, originalComponent, newComponent
* @option {Function} onComponentSelected Callback will be called when a component is selected. Arguments: event, selectedComponent
* @option {Function} onComponentSnippetDropped Callback will be called after a component snippet is dropped into a container. Arguments: event, newComponent, droppedComponent
*/
onInitContent
is changed to onInitContentArea
- All callbacks of section are removed
- Support multiple component types