Liferay.Loader.define("frontend-editor-ckeditor-web@5.0.65/editor/BalloonEditor",["module","exports","require","liferay!frontend-js-react-web$prop-types","liferay!frontend-js-react-web$react","./config/DefaultBalloonEditorConfiguration","../css/main.scss","./BaseEditor"],(function(e,t,r){window;{Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;i(r("liferay!frontend-js-react-web$prop-types"));var n=i(r("liferay!frontend-js-react-web$react")),o=i(r("./config/DefaultBalloonEditorConfiguration"));r("../css/main.scss");var a=i(r("./BaseEditor"));function i(e){return e&&e.__esModule?e:{default:e}}function l(){return(l=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e}).apply(this,arguments)}function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function s(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?c(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):c(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function u(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function f(e,t){if(null==e)return{};var r,n,o=function(e,t){if(null==e)return{};var r,n,o={},a=Object.keys(e);for(n=0;n<a.length;n++)r=a[n],t.indexOf(r)>=0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(n=0;n<a.length;n++)r=a[n],t.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}const e={};var d=t=>{let{config:r=e,contents:i,name:c}=t,u=f(t,["config","contents","name"]);const d=s(s({},o.default),r);return d.balloonEditorEnabled?n.default.createElement(a.default,l({config:d,data:i,name:c,onBeforeLoad:e=>{e.ADDITIONAL_RESOURCE_PARAMS={languageId:themeDisplay.getLanguageId()},e.disableAutoInline=!0,e.getNextZIndex=function(){return e.dialog._.currentZIndex?e.dialog._.currentZIndex+10:Liferay.zIndex.WINDOW+10}},onInstanceReady:e=>{const t=e.editor,r=t.editable();r.setAttribute("id","cke_".concat(t.name)),r.attachClass("liferay-editable");const n=t.balloonToolbars;d.toolbarText&&n.create({buttons:d.toolbarText,cssSelector:"*"}),d.toolbarImage&&n.create({buttons:d.toolbarImage,priority:window.CKEDITOR.plugins.balloontoolbar.PRIORITY.HIGH,widgets:"image,image2"}),d.toolbarVideo&&n.create({buttons:d.toolbarVideo,priority:window.CKEDITOR.plugins.balloontoolbar.PRIORITY.HIGH,widgets:"videoembed"})},type:"inline"},u)):null};t.default=d}}));
//# sourceMappingURL=BalloonEditor.js.map