{"version":3,"sources":["Demo/Extension/Editor/EditorCkDocument.js","App/components/AllCkEditor.js"],"names":["EditorCkDocument","react__WEBPACK_IMPORTED_MODULE_5___default","a","createElement","_hoc_Aux__WEBPACK_IMPORTED_MODULE_9__","react_bootstrap__WEBPACK_IMPORTED_MODULE_6__","react_bootstrap__WEBPACK_IMPORTED_MODULE_7__","react_bootstrap__WEBPACK_IMPORTED_MODULE_8__","Header","Title","as","Body","className","_App_components_AllCkEditor__WEBPACK_IMPORTED_MODULE_10__","html","editor","React","Component","getEditor","ClassicEditor","BalloonEditor","InlineEditor","DecoupledEditor","AllCkEditor","_this","this","_ckeditor_ckeditor5_react__WEBPACK_IMPORTED_MODULE_6___default","props","data","onInit","document","querySelector","appendChild","ui","view","toolbar","element","window","onChange","event","onBlur","onFocus"],"mappings":"wMAMMA,mLA6CE,OACIC,EAAAC,EAAAC,cAACC,EAAA,EAAD,KACIH,EAAAC,EAAAC,cAACE,EAAA,EAAD,KACIJ,EAAAC,EAAAC,cAACG,EAAA,EAAD,KACIL,EAAAC,EAAAC,cAACI,EAAA,EAAD,KACIN,EAAAC,EAAAC,cAACI,EAAA,EAAKC,OAAN,KACIP,EAAAC,EAAAC,cAACI,EAAA,EAAKE,MAAN,CAAYC,GAAG,MAAf,oBAEJT,EAAAC,EAAAC,cAACI,EAAA,EAAKI,KAAN,KACIV,EAAAC,EAAAC,cAAA,OAAKS,UAAU,mBACXX,EAAAC,EAAAC,cAAA,OAAKS,UAAU,6BACfX,EAAAC,EAAAC,cAAA,OAAKS,UAAU,uCACXX,EAAAC,EAAAC,cAAA,OAAKS,UAAU,6BACXX,EAAAC,EAAAC,cAACU,EAAA,EAAD,CAAaC,KAxDvC,sxHAwDmDC,OAAO,4BA1D7CC,IAAMC,WAuEtBjB,iMCtEf,SAASkB,EAAUH,GACf,OAAQA,GACJ,IAAK,UACD,OAAOI,IACX,IAAK,UACD,OAAOC,IACX,IAAK,SACD,OAAOC,IACX,IAAK,WACD,OAAOC,IACX,QACI,OAAOH,SAIbI,mLACO,IAAAC,EAAAC,KACL,OAAOxB,EAAAC,EAAAC,cAACuB,EAAAxB,EAAD,CACCa,OAASG,EAAUO,KAAKE,MAAMZ,QAC9Ba,KAAOH,KAAKE,MAAMb,KAClBe,OAAS,SAAAd,GACqB,aAAtBS,EAAKG,MAAMZ,SACce,SAASC,cAAc,6BAC/BC,YAAYjB,EAAOkB,GAAGC,KAAKC,QAAQC,SACpDC,OAAOtB,OAASA,IAIxBuB,SAAW,SAAEC,EAAOxB,KAIpByB,OAAS,SAAAzB,KAGT0B,QAAU,SAAA1B,cApBAC,IAAMC,WA6BjBM","file":"static/js/109.782117e4.chunk.js","sourcesContent":["import React from 'react';\r\nimport {Row, Col, Card} from 'react-bootstrap';\r\n\r\nimport Aux from \"../../../hoc/_Aux\";\r\nimport AllCkEditor from \"../../../App/components/AllCkEditor\";\r\n\r\nclass EditorCkDocument extends React.Component {\r\n render() {\r\n const html = `\r\n <h2 style=\"text-align:center;\">The Flavorful Tuscany Meetup</h2>\r\n <h3 style=\"text-align:center;\">Welcome letter</h3>\r\n <p>Dear Guest,</p>\r\n <p>We are delighted to welcome you to the annual <i>Flavorful Tuscany Meetup</i> and hope you will enjoy the programmer as well as your stay at the <a href=\"http://ckeditor.com\">Bilancino Hotel</a>.</p>\r\n <p>Please find below the full schedule of the event.</p>\r\n <figure class=\"table ck-widget ck-widget_selectable\" contenteditable=\"false\">\r\n <table>\r\n <thead>\r\n <tr>\r\n <th class=\"ck-editor__editable ck-editor__nested-editable\" contenteditable=\"true\" colspan=\"2\">Saturday, July 14</th>\r\n </tr>\r\n </thead>\r\n <tbody>\r\n <tr>\r\n <td class=\"ck-editor__editable ck-editor__nested-editable\" contenteditable=\"true\">9:30 AM - 11:30 AM</td>\r\n <td class=\"ck-editor__editable ck-editor__nested-editable\" contenteditable=\"true\">Americano vs. Brewed - “know coffee” with <strong>Stefano Garau</strong></td>\r\n </tr>\r\n <tr>\r\n <td class=\"ck-editor__editable ck-editor__nested-editable\" contenteditable=\"true\">1:00 PM - 3:00 PM</td>\r\n <td class=\"ck-editor__editable ck-editor__nested-editable\" contenteditable=\"true\">Pappardelle al pomodoro -\r\n <mark class=\"marker-yellow\">live cooking</mark> with <strong>Rita</strong></td>\r\n </tr>\r\n <tr>\r\n <td class=\"ck-editor__editable ck-editor__nested-editable\" contenteditable=\"true\">5:00 PM - 8:00 PM</td>\r\n <td class=\"ck-editor__editable ck-editor__nested-editable\" contenteditable=\"true\">Tuscan vineyards at a glancewith <strong>Frederico Riscoli</strong></td>\r\n </tr>\r\n </tbody>\r\n </table>\r\n </figure>\r\n <blockquote>\r\n <p>The annual Flavorful Tuscany meetups are always a culinary discovery. You get the best of Tuscan flavors during an intense one-day stay at one of the top hotels of the region. All the\r\n sessions are lead by top chefs passionate about their profession. I would certainly recommend to save the date in your calendar for this one!</p>\r\n <p>Angelina Calvino, food journalist</p>\r\n </blockquote>\r\n <p>Please arrive at the <a href=\"http://ckeditor.com\">Bilancino Hotel</a> reception desk\r\n <mark class=\"marker-yellow\">at least half an hour earlier</mark> to make sure that the registration process goes as smoothly as possible.</p>\r\n <p>We look forward to welcoming you to the event.</p>\r\n <p><strong>Victoria Valc</strong></p>\r\n <p><strong>Event Manager</strong></p>\r\n <p><strong>Bilancino Hotel</strong></p>\r\n `;\r\n\r\n return (\r\n <Aux>\r\n <Row>\r\n <Col>\r\n <Card>\r\n <Card.Header>\r\n <Card.Title as='h5'>Document Editor</Card.Title>\r\n </Card.Header>\r\n <Card.Body>\r\n <div className='document-editor'>\r\n <div className=\"document-editor__toolbar\"/>\r\n <div className=\"document-editor__editable-container\">\r\n <div className=\"document-editor__editable\">\r\n <AllCkEditor html={html} editor='document'/>\r\n </div>\r\n </div>\r\n </div>\r\n </Card.Body>\r\n </Card>\r\n </Col>\r\n </Row>\r\n </Aux>\r\n );\r\n }\r\n}\r\n\r\nexport default EditorCkDocument;","import React from 'react';\r\nimport CKEditor from '@ckeditor/ckeditor5-react';\r\nimport ClassicEditor from '@ckeditor/ckeditor5-build-classic';\r\nimport InlineEditor from '@ckeditor/ckeditor5-build-inline';\r\nimport BalloonEditor from '@ckeditor/ckeditor5-build-balloon';\r\nimport DecoupledEditor from '@ckeditor/ckeditor5-build-decoupled-document';\r\n\r\nfunction getEditor(editor) {\r\n switch (editor) {\r\n case 'classic':\r\n return ClassicEditor;\r\n case 'balloon':\r\n return BalloonEditor;\r\n case 'inline':\r\n return InlineEditor;\r\n case 'document':\r\n return DecoupledEditor;\r\n default:\r\n return ClassicEditor;\r\n }\r\n}\r\n\r\nclass AllCkEditor extends React.Component {\r\n render() {\r\n return <CKEditor\r\n editor={ getEditor(this.props.editor) }\r\n data= {this.props.html}\r\n onInit={ editor => {\r\n if (this.props.editor === 'document') {\r\n const toolbarContainer = document.querySelector('.document-editor__toolbar');\r\n toolbarContainer.appendChild(editor.ui.view.toolbar.element);\r\n window.editor = editor;\r\n }\r\n // console.log( 'Editor is ready to use!', editor );\r\n } }\r\n onChange={ ( event, editor ) => {\r\n // const data = editor.getData();\r\n // console.log( { event, editor, data } );\r\n } }\r\n onBlur={ editor => {\r\n // console.log( 'Blur.', editor );\r\n } }\r\n onFocus={ editor => {\r\n // console.log( 'Focus.', editor );\r\n } }\r\n />\r\n\r\n\r\n }\r\n}\r\n\r\nexport default AllCkEditor;"],"sourceRoot":""}