diff --git a/BTCPayServer/wwwroot/vendor/summernote/font/summernote.eot b/BTCPayServer/wwwroot/vendor/summernote/font/summernote.eot
index d287ac1df..4f047db9a 100644
Binary files a/BTCPayServer/wwwroot/vendor/summernote/font/summernote.eot and b/BTCPayServer/wwwroot/vendor/summernote/font/summernote.eot differ
diff --git a/BTCPayServer/wwwroot/vendor/summernote/font/summernote.ttf b/BTCPayServer/wwwroot/vendor/summernote/font/summernote.ttf
index 76301c423..64ef84c14 100644
Binary files a/BTCPayServer/wwwroot/vendor/summernote/font/summernote.ttf and b/BTCPayServer/wwwroot/vendor/summernote/font/summernote.ttf differ
diff --git a/BTCPayServer/wwwroot/vendor/summernote/font/summernote.woff b/BTCPayServer/wwwroot/vendor/summernote/font/summernote.woff
index 99f941c53..dfd4f6626 100644
Binary files a/BTCPayServer/wwwroot/vendor/summernote/font/summernote.woff and b/BTCPayServer/wwwroot/vendor/summernote/font/summernote.woff differ
diff --git a/BTCPayServer/wwwroot/vendor/summernote/font/summernote.woff2 b/BTCPayServer/wwwroot/vendor/summernote/font/summernote.woff2
new file mode 100644
index 000000000..40b203082
Binary files /dev/null and b/BTCPayServer/wwwroot/vendor/summernote/font/summernote.woff2 differ
diff --git a/BTCPayServer/wwwroot/vendor/summernote/summernote-bs4.css b/BTCPayServer/wwwroot/vendor/summernote/summernote-bs4.css
index 9558702a2..7a750beac 100644
--- a/BTCPayServer/wwwroot/vendor/summernote/summernote-bs4.css
+++ b/BTCPayServer/wwwroot/vendor/summernote/summernote-bs4.css
@@ -1 +1,13 @@
-@font-face{font-family:"summernote";font-style:normal;font-weight:normal;src:url("./font/summernote.eot?4c7e83314b68cfa6a0d18a8b4690044b");src:url("./font/summernote.eot?4c7e83314b68cfa6a0d18a8b4690044b#iefix") format("embedded-opentype"),url("./font/summernote.woff?4c7e83314b68cfa6a0d18a8b4690044b") format("woff"),url("./font/summernote.ttf?4c7e83314b68cfa6a0d18a8b4690044b") format("truetype")}[class^="note-icon-"]:before,[class*=" note-icon-"]:before{display:inline-block;font:normal normal normal 14px summernote;font-size:inherit;-webkit-font-smoothing:antialiased;text-decoration:inherit;text-rendering:auto;text-transform:none;vertical-align:middle;speak:none;-moz-osx-font-smoothing:grayscale}.note-icon-align-center:before,.note-icon-align-indent:before,.note-icon-align-justify:before,.note-icon-align-left:before,.note-icon-align-outdent:before,.note-icon-align-right:before,.note-icon-align:before,.note-icon-arrow-circle-down:before,.note-icon-arrow-circle-left:before,.note-icon-arrow-circle-right:before,.note-icon-arrow-circle-up:before,.note-icon-arrows-alt:before,.note-icon-arrows-h:before,.note-icon-arrows-v:before,.note-icon-bold:before,.note-icon-caret:before,.note-icon-chain-broken:before,.note-icon-circle:before,.note-icon-close:before,.note-icon-code:before,.note-icon-col-after:before,.note-icon-col-before:before,.note-icon-col-remove:before,.note-icon-eraser:before,.note-icon-font:before,.note-icon-frame:before,.note-icon-italic:before,.note-icon-link:before,.note-icon-magic:before,.note-icon-menu-check:before,.note-icon-minus:before,.note-icon-orderedlist:before,.note-icon-pencil:before,.note-icon-picture:before,.note-icon-question:before,.note-icon-redo:before,.note-icon-row-above:before,.note-icon-row-below:before,.note-icon-row-remove:before,.note-icon-special-character:before,.note-icon-square:before,.note-icon-strikethrough:before,.note-icon-subscript:before,.note-icon-summernote:before,.note-icon-superscript:before,.note-icon-table:before,.note-icon-text-height:before,.note-icon-trash:before,.note-icon-underline:before,.note-icon-undo:before,.note-icon-unorderedlist:before,.note-icon-video:before{display:inline-block;font-family:"summernote";font-style:normal;font-weight:normal;text-decoration:inherit}.note-icon-align-center:before{content:"\f101"}.note-icon-align-indent:before{content:"\f102"}.note-icon-align-justify:before{content:"\f103"}.note-icon-align-left:before{content:"\f104"}.note-icon-align-outdent:before{content:"\f105"}.note-icon-align-right:before{content:"\f106"}.note-icon-align:before{content:"\f107"}.note-icon-arrow-circle-down:before{content:"\f108"}.note-icon-arrow-circle-left:before{content:"\f109"}.note-icon-arrow-circle-right:before{content:"\f10a"}.note-icon-arrow-circle-up:before{content:"\f10b"}.note-icon-arrows-alt:before{content:"\f10c"}.note-icon-arrows-h:before{content:"\f10d"}.note-icon-arrows-v:before{content:"\f10e"}.note-icon-bold:before{content:"\f10f"}.note-icon-caret:before{content:"\f110"}.note-icon-chain-broken:before{content:"\f111"}.note-icon-circle:before{content:"\f112"}.note-icon-close:before{content:"\f113"}.note-icon-code:before{content:"\f114"}.note-icon-col-after:before{content:"\f115"}.note-icon-col-before:before{content:"\f116"}.note-icon-col-remove:before{content:"\f117"}.note-icon-eraser:before{content:"\f118"}.note-icon-font:before{content:"\f119"}.note-icon-frame:before{content:"\f11a"}.note-icon-italic:before{content:"\f11b"}.note-icon-link:before{content:"\f11c"}.note-icon-magic:before{content:"\f11d"}.note-icon-menu-check:before{content:"\f11e"}.note-icon-minus:before{content:"\f11f"}.note-icon-orderedlist:before{content:"\f120"}.note-icon-pencil:before{content:"\f121"}.note-icon-picture:before{content:"\f122"}.note-icon-question:before{content:"\f123"}.note-icon-redo:before{content:"\f124"}.note-icon-row-above:before{content:"\f125"}.note-icon-row-below:before{content:"\f126"}.note-icon-row-remove:before{content:"\f127"}.note-icon-special-character:before{content:"\f128"}.note-icon-square:before{content:"\f129"}.note-icon-strikethrough:before{content:"\f12a"}.note-icon-subscript:before{content:"\f12b"}.note-icon-summernote:before{content:"\f12c"}.note-icon-superscript:before{content:"\f12d"}.note-icon-table:before{content:"\f12e"}.note-icon-text-height:before{content:"\f12f"}.note-icon-trash:before{content:"\f130"}.note-icon-underline:before{content:"\f131"}.note-icon-undo:before{content:"\f132"}.note-icon-unorderedlist:before{content:"\f133"}.note-icon-video:before{content:"\f134"}.note-editor{position:relative}.note-editor .note-dropzone{position:absolute;z-index:100;display:none;color:#87cefa;background-color:#fff;opacity:.95}.note-editor .note-dropzone .note-dropzone-message{display:table-cell;font-size:28px;font-weight:700;text-align:center;vertical-align:middle}.note-editor .note-dropzone.hover{color:#098ddf}.note-editor.dragover .note-dropzone{display:table}.note-editor .note-editing-area{position:relative}.note-editor .note-editing-area .note-editable{outline:0}.note-editor .note-editing-area .note-editable sup{vertical-align:super}.note-editor .note-editing-area .note-editable sub{vertical-align:sub}.note-editor .note-editing-area img.note-float-left{margin-right:10px}.note-editor .note-editing-area img.note-float-right{margin-left:10px}.note-editor.note-frame{border:1px solid #a9a9a9}.note-editor.note-frame.codeview .note-editing-area .note-editable{display:none}.note-editor.note-frame.codeview .note-editing-area .note-codable{display:block}.note-editor.note-frame .note-editing-area{overflow:hidden}.note-editor.note-frame .note-editing-area .note-editable{padding:10px;overflow:auto;color:#000;word-wrap:break-word;background-color:#fff}.note-editor.note-frame .note-editing-area .note-editable[contenteditable="false"]{background-color:#e5e5e5}.note-editor.note-frame .note-editing-area .note-codable{display:none;width:100%;padding:10px;margin-bottom:0;font-family:Menlo,Monaco,monospace,sans-serif;font-size:14px;color:#ccc;background-color:#222;border:0;-webkit-border-radius:0;-moz-border-radius:0;border-radius:0;box-shadow:none;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;-ms-box-sizing:border-box;box-sizing:border-box;resize:none}.note-editor.note-frame.fullscreen{position:fixed;top:0;left:0;z-index:1050;width:100%!important}.note-editor.note-frame.fullscreen .note-editable{background-color:#fff}.note-editor.note-frame.fullscreen .note-resizebar{display:none}.note-editor.note-frame .note-status-output{display:block;width:100%;height:20px;margin-bottom:0;font-size:14px;line-height:1.42857143;color:#000;border:0;border-top:1px solid #e2e2e2}.note-editor.note-frame .note-status-output:empty{height:0;border-top:0 solid transparent}.note-editor.note-frame .note-status-output .pull-right{float:right!important}.note-editor.note-frame .note-status-output .text-muted{color:#777}.note-editor.note-frame .note-status-output .text-primary{color:#286090}.note-editor.note-frame .note-status-output .text-success{color:#3c763d}.note-editor.note-frame .note-status-output .text-info{color:#31708f}.note-editor.note-frame .note-status-output .text-warning{color:#8a6d3b}.note-editor.note-frame .note-status-output .text-danger{color:#a94442}.note-editor.note-frame .note-status-output .alert{padding:7px 10px 2px 10px;margin:-7px 0 0 0;color:#000;background-color:#f5f5f5;border-radius:0}.note-editor.note-frame .note-status-output .alert .note-icon{margin-right:5px}.note-editor.note-frame .note-status-output .alert-success{color:#3c763d!important;background-color:#dff0d8!important}.note-editor.note-frame .note-status-output .alert-info{color:#31708f!important;background-color:#d9edf7!important}.note-editor.note-frame .note-status-output .alert-warning{color:#8a6d3b!important;background-color:#fcf8e3!important}.note-editor.note-frame .note-status-output .alert-danger{color:#a94442!important;background-color:#f2dede!important}.note-editor.note-frame .note-statusbar{background-color:#f5f5f5;border-top:1px solid #ddd;border-bottom-right-radius:4px;border-bottom-left-radius:4px}.note-editor.note-frame .note-statusbar .note-resizebar{width:100%;height:9px;padding-top:1px;cursor:ns-resize}.note-editor.note-frame .note-statusbar .note-resizebar .note-icon-bar{width:20px;margin:1px auto;border-top:1px solid #a9a9a9}.note-editor.note-frame .note-statusbar.locked .note-resizebar{cursor:default}.note-editor.note-frame .note-statusbar.locked .note-resizebar .note-icon-bar{display:none}.note-editor.note-frame .note-placeholder{padding:10px}.note-popover.popover{display:none;max-width:none}.note-popover.popover .popover-content a{display:inline-block;max-width:200px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;vertical-align:middle}.note-popover.popover .arrow{left:20px!important}.note-toolbar{position:relative;z-index:500}.note-popover .popover-content,.card-header.note-toolbar{padding:0 0 5px 5px;margin:0;background:#f5f5f5}.note-popover .popover-content>.btn-group,.card-header.note-toolbar>.btn-group{margin-top:5px;margin-right:5px;margin-left:0}.note-popover .popover-content .btn-group .note-table,.card-header.note-toolbar .btn-group .note-table{min-width:0;padding:5px}.note-popover .popover-content .btn-group .note-table .note-dimension-picker,.card-header.note-toolbar .btn-group .note-table .note-dimension-picker{font-size:18px}.note-popover .popover-content .btn-group .note-table .note-dimension-picker .note-dimension-picker-mousecatcher,.card-header.note-toolbar .btn-group .note-table .note-dimension-picker .note-dimension-picker-mousecatcher{position:absolute!important;z-index:3;width:10em;height:10em;cursor:pointer}.note-popover .popover-content .btn-group .note-table .note-dimension-picker .note-dimension-picker-unhighlighted,.card-header.note-toolbar .btn-group .note-table .note-dimension-picker .note-dimension-picker-unhighlighted{position:relative!important;z-index:1;width:5em;height:5em;background:url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASAgMAAAAroGbEAAAACVBMVEUAAIj4+Pjp6ekKlAqjAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxMAAAsTAQCanBgAAAAHdElNRQfYAR0BKhmnaJzPAAAAG0lEQVQI12NgAAOtVatWMTCohoaGUY+EmIkEAEruEzK2J7tvAAAAAElFTkSuQmCC') repeat}.note-popover .popover-content .btn-group .note-table .note-dimension-picker .note-dimension-picker-highlighted,.card-header.note-toolbar .btn-group .note-table .note-dimension-picker .note-dimension-picker-highlighted{position:absolute!important;z-index:2;width:1em;height:1em;background:url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASAgMAAAAroGbEAAAACVBMVEUAAIjd6vvD2f9LKLW+AAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxMAAAsTAQCanBgAAAAHdElNRQfYAR0BKwNDEVT0AAAAG0lEQVQI12NgAAOtVatWMTCohoaGUY+EmIkEAEruEzK2J7tvAAAAAElFTkSuQmCC') repeat}.note-popover .popover-content .note-style .dropdown-style blockquote,.card-header.note-toolbar .note-style .dropdown-style blockquote,.note-popover .popover-content .note-style .dropdown-style pre,.card-header.note-toolbar .note-style .dropdown-style pre{padding:5px 10px;margin:0}.note-popover .popover-content .note-style .dropdown-style h1,.card-header.note-toolbar .note-style .dropdown-style h1,.note-popover .popover-content .note-style .dropdown-style h2,.card-header.note-toolbar .note-style .dropdown-style h2,.note-popover .popover-content .note-style .dropdown-style h3,.card-header.note-toolbar .note-style .dropdown-style h3,.note-popover .popover-content .note-style .dropdown-style h4,.card-header.note-toolbar .note-style .dropdown-style h4,.note-popover .popover-content .note-style .dropdown-style h5,.card-header.note-toolbar .note-style .dropdown-style h5,.note-popover .popover-content .note-style .dropdown-style h6,.card-header.note-toolbar .note-style .dropdown-style h6,.note-popover .popover-content .note-style .dropdown-style p,.card-header.note-toolbar .note-style .dropdown-style p{padding:0;margin:0}.note-popover .popover-content .note-color-all .dropdown-menu,.card-header.note-toolbar .note-color-all .dropdown-menu{min-width:337px}.note-popover .popover-content .note-color .dropdown-toggle,.card-header.note-toolbar .note-color .dropdown-toggle{width:20px;padding-left:5px}.note-popover .popover-content .note-color .dropdown-menu .note-palette,.card-header.note-toolbar .note-color .dropdown-menu .note-palette{display:inline-block;width:160px;margin:0}.note-popover .popover-content .note-color .dropdown-menu .note-palette:first-child,.card-header.note-toolbar .note-color .dropdown-menu .note-palette:first-child{margin:0 5px}.note-popover .popover-content .note-color .dropdown-menu .note-palette .note-palette-title,.card-header.note-toolbar .note-color .dropdown-menu .note-palette .note-palette-title{margin:2px 7px;font-size:12px;text-align:center;border-bottom:1px solid #eee}.note-popover .popover-content .note-color .dropdown-menu .note-palette .note-color-reset,.card-header.note-toolbar .note-color .dropdown-menu .note-palette .note-color-reset,.note-popover .popover-content .note-color .dropdown-menu .note-palette .note-color-select,.card-header.note-toolbar .note-color .dropdown-menu .note-palette .note-color-select{width:100%;padding:0 3px;margin:3px;font-size:11px;cursor:pointer;-webkit-border-radius:5px;-moz-border-radius:5px;border-radius:5px}.note-popover .popover-content .note-color .dropdown-menu .note-palette .note-color-row,.card-header.note-toolbar .note-color .dropdown-menu .note-palette .note-color-row{height:20px}.note-popover .popover-content .note-color .dropdown-menu .note-palette .note-color-reset:hover,.card-header.note-toolbar .note-color .dropdown-menu .note-palette .note-color-reset:hover{background:#eee}.note-popover .popover-content .note-color .dropdown-menu .note-palette .note-color-select-btn,.card-header.note-toolbar .note-color .dropdown-menu .note-palette .note-color-select-btn{display:none}.note-popover .popover-content .note-color .dropdown-menu .note-palette .note-holder-custom .note-color-btn,.card-header.note-toolbar .note-color .dropdown-menu .note-palette .note-holder-custom .note-color-btn{border:1px solid #eee}.note-popover .popover-content .note-para .dropdown-menu,.card-header.note-toolbar .note-para .dropdown-menu{min-width:216px;padding:5px}.note-popover .popover-content .note-para .dropdown-menu>div:first-child,.card-header.note-toolbar .note-para .dropdown-menu>div:first-child{margin-right:5px}.note-popover .popover-content .dropdown-menu,.card-header.note-toolbar .dropdown-menu{min-width:90px}.note-popover .popover-content .dropdown-menu.right,.card-header.note-toolbar .dropdown-menu.right{right:0;left:auto}.note-popover .popover-content .dropdown-menu.right::before,.card-header.note-toolbar .dropdown-menu.right::before{right:9px;left:auto!important}.note-popover .popover-content .dropdown-menu.right::after,.card-header.note-toolbar .dropdown-menu.right::after{right:10px;left:auto!important}.note-popover .popover-content .dropdown-menu.note-check a i,.card-header.note-toolbar .dropdown-menu.note-check a i{color:deepskyblue;visibility:hidden}.note-popover .popover-content .dropdown-menu.note-check a.checked i,.card-header.note-toolbar .dropdown-menu.note-check a.checked i{visibility:visible}.note-popover .popover-content .note-fontsize-10,.card-header.note-toolbar .note-fontsize-10{font-size:10px}.note-popover .popover-content .note-color-palette,.card-header.note-toolbar .note-color-palette{line-height:1}.note-popover .popover-content .note-color-palette div .note-color-btn,.card-header.note-toolbar .note-color-palette div .note-color-btn{width:20px;height:20px;padding:0;margin:0;border:1px solid #fff}.note-popover .popover-content .note-color-palette div .note-color-btn:hover,.card-header.note-toolbar .note-color-palette div .note-color-btn:hover{border:1px solid #000}.note-dialog>div{display:none}.note-dialog .form-group{margin-right:0;margin-left:0}.note-dialog .note-modal-form{margin:0}.note-dialog .note-image-dialog .note-dropzone{min-height:100px;margin-bottom:10px;font-size:30px;line-height:4;color:lightgray;text-align:center;border:4px dashed lightgray}@-moz-document url-prefix(){.note-image-input{height:auto}}.note-placeholder{position:absolute;display:none;color:gray}.note-handle .note-control-selection{position:absolute;display:none;border:1px solid black}.note-handle .note-control-selection>div{position:absolute}.note-handle .note-control-selection .note-control-selection-bg{width:100%;height:100%;background-color:black;-webkit-opacity:.3;-khtml-opacity:.3;-moz-opacity:.3;opacity:.3;-ms-filter:alpha(opacity=30);filter:alpha(opacity=30)}.note-handle .note-control-selection .note-control-handle{width:7px;height:7px;border:1px solid black}.note-handle .note-control-selection .note-control-holder{width:7px;height:7px;border:1px solid black}.note-handle .note-control-selection .note-control-sizing{width:7px;height:7px;background-color:white;border:1px solid black}.note-handle .note-control-selection .note-control-nw{top:-5px;left:-5px;border-right:0;border-bottom:0}.note-handle .note-control-selection .note-control-ne{top:-5px;right:-5px;border-bottom:0;border-left:none}.note-handle .note-control-selection .note-control-sw{bottom:-5px;left:-5px;border-top:0;border-right:0}.note-handle .note-control-selection .note-control-se{right:-5px;bottom:-5px;cursor:se-resize}.note-handle .note-control-selection .note-control-se.note-control-holder{cursor:default;border-top:0;border-left:none}.note-handle .note-control-selection .note-control-selection-info{right:0;bottom:0;padding:5px;margin:5px;font-size:12px;color:#fff;background-color:#000;-webkit-border-radius:5px;-moz-border-radius:5px;border-radius:5px;-webkit-opacity:.7;-khtml-opacity:.7;-moz-opacity:.7;opacity:.7;-ms-filter:alpha(opacity=70);filter:alpha(opacity=70)}.note-hint-popover{min-width:100px;padding:2px}.note-hint-popover .popover-content{max-height:150px;padding:3px;overflow:auto}.note-hint-popover .popover-content .note-hint-group .note-hint-item{display:block!important;padding:3px}.note-hint-popover .popover-content .note-hint-group .note-hint-item.active,.note-hint-popover .popover-content .note-hint-group .note-hint-item:hover{display:block;clear:both;font-weight:400;line-height:1.4;color:#fff;text-decoration:none;white-space:nowrap;cursor:pointer;background-color:#428bca;outline:0}
\ No newline at end of file
+/*!
+ *
+ * Super simple wysiwyg editor v0.8.18
+ * https://summernote.org
+ *
+ *
+ * Copyright 2013- Alan Hong. and other contributors
+ * summernote may be freely distributed under the MIT license.
+ *
+ * Date: 2020-05-20T18:09Z
+ *
+ */
+@font-face{font-family:"summernote";font-style:normal;font-weight:400;font-display:auto;src:url(font/summernote.eot);src:url(font/summernote.eot?#iefix) format("embedded-opentype"),url(font/summernote.woff2) format("woff2"),url(font/summernote.woff) format("woff"),url(font/summernote.ttf) format("truetype")}[class^=note-icon]:before,[class*=" note-icon"]:before{display:inline-block;font-family:summernote;font-style:normal;font-size:inherit;text-decoration:inherit;text-rendering:auto;text-transform:none;vertical-align:middle;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;speak:none}.note-icon-fw{text-align:center;width:1.25em}.note-icon-border{border:solid .08em #eee;border-radius:.1em;padding:.2em .25em .15em}.note-icon-pull-left{float:left}.note-icon-pull-right{float:right}.note-icon.note-icon-pull-left{margin-right:.3em}.note-icon.note-icon-pull-right{margin-left:.3em}.note-icon-align::before{content:""}.note-icon-align-center::before{content:""}.note-icon-align-indent::before{content:""}.note-icon-align-justify::before{content:""}.note-icon-align-left::before{content:""}.note-icon-align-outdent::before{content:""}.note-icon-align-right::before{content:""}.note-icon-arrow-circle-down::before{content:""}.note-icon-arrow-circle-left::before{content:""}.note-icon-arrow-circle-right::before{content:""}.note-icon-arrow-circle-up::before{content:""}.note-icon-arrows-alt::before{content:""}.note-icon-arrows-h::before{content:""}.note-icon-arrows-v::before{content:""}.note-icon-bold::before{content:""}.note-icon-caret::before{content:""}.note-icon-chain-broken::before{content:""}.note-icon-circle::before{content:""}.note-icon-close::before{content:""}.note-icon-code::before{content:""}.note-icon-col-after::before{content:""}.note-icon-col-before::before{content:""}.note-icon-col-remove::before{content:""}.note-icon-eraser::before{content:""}.note-icon-float-left::before{content:""}.note-icon-float-none::before{content:""}.note-icon-float-right::before{content:""}.note-icon-font::before{content:""}.note-icon-frame::before{content:""}.note-icon-italic::before{content:""}.note-icon-link::before{content:""}.note-icon-magic::before{content:""}.note-icon-menu-check::before{content:""}.note-icon-minus::before{content:""}.note-icon-orderedlist::before{content:""}.note-icon-pencil::before{content:""}.note-icon-picture::before{content:""}.note-icon-question::before{content:""}.note-icon-redo::before{content:""}.note-icon-rollback::before{content:""}.note-icon-row-above::before{content:""}.note-icon-row-below::before{content:""}.note-icon-row-remove::before{content:""}.note-icon-special-character::before{content:""}.note-icon-square::before{content:""}.note-icon-strikethrough::before{content:""}.note-icon-subscript::before{content:""}.note-icon-summernote::before{content:""}.note-icon-superscript::before{content:""}.note-icon-table::before{content:""}.note-icon-text-height::before{content:""}.note-icon-trash::before{content:""}.note-icon-underline::before{content:""}.note-icon-undo::before{content:""}.note-icon-unorderedlist::before{content:""}.note-icon-video::before{content:""}.note-editor{position:relative}.note-editor .note-dropzone{position:absolute;display:none;z-index:100;color:#87cefa;background-color:#fff;opacity:.95}.note-editor .note-dropzone .note-dropzone-message{display:table-cell;vertical-align:middle;text-align:center;font-size:28px;font-weight:700}.note-editor .note-dropzone.hover{color:#098ddf}.note-editor.dragover .note-dropzone{display:table}.note-editor .note-editing-area{position:relative}.note-editor .note-editing-area .note-editable{outline:none}.note-editor .note-editing-area .note-editable sup{vertical-align:super}.note-editor .note-editing-area .note-editable sub{vertical-align:sub}.note-editor .note-editing-area .note-editable img.note-float-left{margin-right:10px}.note-editor .note-editing-area .note-editable img.note-float-right{margin-left:10px}.note-editor.note-frame,.note-editor.note-airframe{border:1px solid #00000032}.note-editor.note-frame.codeview .note-editing-area .note-editable,.note-editor.note-airframe.codeview .note-editing-area .note-editable{display:none}.note-editor.note-frame.codeview .note-editing-area .note-codable,.note-editor.note-airframe.codeview .note-editing-area .note-codable{display:block}.note-editor.note-frame .note-editing-area,.note-editor.note-airframe .note-editing-area{overflow:hidden}.note-editor.note-frame .note-editing-area .note-editable,.note-editor.note-airframe .note-editing-area .note-editable{padding:10px;overflow:auto;word-wrap:break-word}.note-editor.note-frame .note-editing-area .note-editable[contenteditable=false],.note-editor.note-airframe .note-editing-area .note-editable[contenteditable=false]{background-color:#8080801d}.note-editor.note-frame .note-editing-area .note-codable,.note-editor.note-airframe .note-editing-area .note-codable{display:none;width:100%;padding:10px;border:none;box-shadow:none;font-family:Menlo,Monaco,monospace,sans-serif;font-size:14px;color:#ccc;background-color:#222;resize:none;outline:none;-ms-box-sizing:border-box;box-sizing:border-box;border-radius:0;margin-bottom:0}.note-editor.note-frame.fullscreen,.note-editor.note-airframe.fullscreen{position:fixed;top:0;left:0;width:100% !important;z-index:1050}.note-editor.note-frame.fullscreen .note-resizebar,.note-editor.note-airframe.fullscreen .note-resizebar{display:none}.note-editor.note-frame .note-status-output,.note-editor.note-airframe .note-status-output{display:block;width:100%;font-size:14px;line-height:1.42857143;height:20px;margin-bottom:0;color:#000;border:0;border-top:1px solid #e2e2e2}.note-editor.note-frame .note-status-output:empty,.note-editor.note-airframe .note-status-output:empty{height:0;border-top:0 solid transparent}.note-editor.note-frame .note-status-output .pull-right,.note-editor.note-airframe .note-status-output .pull-right{float:right !important}.note-editor.note-frame .note-status-output .text-muted,.note-editor.note-airframe .note-status-output .text-muted{color:#777}.note-editor.note-frame .note-status-output .text-primary,.note-editor.note-airframe .note-status-output .text-primary{color:#286090}.note-editor.note-frame .note-status-output .text-success,.note-editor.note-airframe .note-status-output .text-success{color:#3c763d}.note-editor.note-frame .note-status-output .text-info,.note-editor.note-airframe .note-status-output .text-info{color:#31708f}.note-editor.note-frame .note-status-output .text-warning,.note-editor.note-airframe .note-status-output .text-warning{color:#8a6d3b}.note-editor.note-frame .note-status-output .text-danger,.note-editor.note-airframe .note-status-output .text-danger{color:#a94442}.note-editor.note-frame .note-status-output .alert,.note-editor.note-airframe .note-status-output .alert{margin:-7px 0 0 0;padding:7px 10px 2px 10px;border-radius:0;color:#000;background-color:#f5f5f5}.note-editor.note-frame .note-status-output .alert .note-icon,.note-editor.note-airframe .note-status-output .alert .note-icon{margin-right:5px}.note-editor.note-frame .note-status-output .alert-success,.note-editor.note-airframe .note-status-output .alert-success{color:#3c763d !important;background-color:#dff0d8 !important}.note-editor.note-frame .note-status-output .alert-info,.note-editor.note-airframe .note-status-output .alert-info{color:#31708f !important;background-color:#d9edf7 !important}.note-editor.note-frame .note-status-output .alert-warning,.note-editor.note-airframe .note-status-output .alert-warning{color:#8a6d3b !important;background-color:#fcf8e3 !important}.note-editor.note-frame .note-status-output .alert-danger,.note-editor.note-airframe .note-status-output .alert-danger{color:#a94442 !important;background-color:#f2dede !important}.note-editor.note-frame .note-statusbar,.note-editor.note-airframe .note-statusbar{background-color:#8080801d;border-bottom-left-radius:4px;border-bottom-right-radius:4px;border-top:1px solid #00000032}.note-editor.note-frame .note-statusbar .note-resizebar,.note-editor.note-airframe .note-statusbar .note-resizebar{padding-top:1px;height:9px;width:100%;cursor:ns-resize}.note-editor.note-frame .note-statusbar .note-resizebar .note-icon-bar,.note-editor.note-airframe .note-statusbar .note-resizebar .note-icon-bar{width:20px;margin:1px auto;border-top:1px solid #00000032}.note-editor.note-frame .note-statusbar.locked .note-resizebar,.note-editor.note-airframe .note-statusbar.locked .note-resizebar{cursor:default}.note-editor.note-frame .note-statusbar.locked .note-resizebar .note-icon-bar,.note-editor.note-airframe .note-statusbar.locked .note-resizebar .note-icon-bar{display:none}.note-editor.note-frame .note-placeholder,.note-editor.note-airframe .note-placeholder{padding:10px}.note-editor.note-airframe{border:0}.note-editor.note-airframe .note-editing-area .note-editable{padding:0}.note-popover.popover{display:none;max-width:none}.note-popover.popover .popover-content a{display:inline-block;max-width:200px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;vertical-align:middle}.note-popover.popover .arrow{left:20px !important}.note-toolbar{position:relative}.note-popover .popover-content,.note-editor .note-toolbar{margin:0;padding:0 0 5px 5px}.note-popover .popover-content>.note-btn-group,.note-editor .note-toolbar>.note-btn-group{margin-top:5px;margin-left:0;margin-right:5px}.note-popover .popover-content .note-btn-group .note-table,.note-editor .note-toolbar .note-btn-group .note-table{min-width:0;padding:5px}.note-popover .popover-content .note-btn-group .note-table .note-dimension-picker,.note-editor .note-toolbar .note-btn-group .note-table .note-dimension-picker{font-size:18px}.note-popover .popover-content .note-btn-group .note-table .note-dimension-picker .note-dimension-picker-mousecatcher,.note-editor .note-toolbar .note-btn-group .note-table .note-dimension-picker .note-dimension-picker-mousecatcher{position:absolute !important;z-index:3;width:10em;height:10em;cursor:pointer}.note-popover .popover-content .note-btn-group .note-table .note-dimension-picker .note-dimension-picker-unhighlighted,.note-editor .note-toolbar .note-btn-group .note-table .note-dimension-picker .note-dimension-picker-unhighlighted{position:relative !important;z-index:1;width:5em;height:5em;background:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASAgMAAAAroGbEAAAACVBMVEUAAIj4+Pjp6ekKlAqjAAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxMAAAsTAQCanBgAAAAHdElNRQfYAR0BKhmnaJzPAAAAG0lEQVQI12NgAAOtVatWMTCohoaGUY+EmIkEAEruEzK2J7tvAAAAAElFTkSuQmCC") repeat}.note-popover .popover-content .note-btn-group .note-table .note-dimension-picker .note-dimension-picker-highlighted,.note-editor .note-toolbar .note-btn-group .note-table .note-dimension-picker .note-dimension-picker-highlighted{position:absolute !important;z-index:2;width:1em;height:1em;background:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASAgMAAAAroGbEAAAACVBMVEUAAIjd6vvD2f9LKLW+AAAAAXRSTlMAQObYZgAAAAFiS0dEAIgFHUgAAAAJcEhZcwAACxMAAAsTAQCanBgAAAAHdElNRQfYAR0BKwNDEVT0AAAAG0lEQVQI12NgAAOtVatWMTCohoaGUY+EmIkEAEruEzK2J7tvAAAAAElFTkSuQmCC") repeat}.note-popover .popover-content .note-style .dropdown-style blockquote,.note-popover .popover-content .note-style .dropdown-style pre,.note-editor .note-toolbar .note-style .dropdown-style blockquote,.note-editor .note-toolbar .note-style .dropdown-style pre{margin:0;padding:5px 10px}.note-popover .popover-content .note-style .dropdown-style h1,.note-popover .popover-content .note-style .dropdown-style h2,.note-popover .popover-content .note-style .dropdown-style h3,.note-popover .popover-content .note-style .dropdown-style h4,.note-popover .popover-content .note-style .dropdown-style h5,.note-popover .popover-content .note-style .dropdown-style h6,.note-popover .popover-content .note-style .dropdown-style p,.note-editor .note-toolbar .note-style .dropdown-style h1,.note-editor .note-toolbar .note-style .dropdown-style h2,.note-editor .note-toolbar .note-style .dropdown-style h3,.note-editor .note-toolbar .note-style .dropdown-style h4,.note-editor .note-toolbar .note-style .dropdown-style h5,.note-editor .note-toolbar .note-style .dropdown-style h6,.note-editor .note-toolbar .note-style .dropdown-style p{margin:0;padding:0}.note-popover .popover-content .note-color-all .note-dropdown-menu,.note-editor .note-toolbar .note-color-all .note-dropdown-menu{min-width:337px}.note-popover .popover-content .note-color .dropdown-toggle,.note-editor .note-toolbar .note-color .dropdown-toggle{width:20px;padding-left:5px}.note-popover .popover-content .note-color .note-dropdown-menu .note-palette,.note-editor .note-toolbar .note-color .note-dropdown-menu .note-palette{display:inline-block;margin:0;width:160px}.note-popover .popover-content .note-color .note-dropdown-menu .note-palette:first-child,.note-editor .note-toolbar .note-color .note-dropdown-menu .note-palette:first-child{margin:0 5px}.note-popover .popover-content .note-color .note-dropdown-menu .note-palette .note-palette-title,.note-editor .note-toolbar .note-color .note-dropdown-menu .note-palette .note-palette-title{font-size:12px;margin:2px 7px;text-align:center;border-bottom:1px solid #eee}.note-popover .popover-content .note-color .note-dropdown-menu .note-palette .note-color-reset,.note-popover .popover-content .note-color .note-dropdown-menu .note-palette .note-color-select,.note-editor .note-toolbar .note-color .note-dropdown-menu .note-palette .note-color-reset,.note-editor .note-toolbar .note-color .note-dropdown-menu .note-palette .note-color-select{font-size:11px;margin:3px;padding:0 3px;cursor:pointer;width:100%;border-radius:5px}.note-popover .popover-content .note-color .note-dropdown-menu .note-palette .note-color-reset:hover,.note-popover .popover-content .note-color .note-dropdown-menu .note-palette .note-color-select:hover,.note-editor .note-toolbar .note-color .note-dropdown-menu .note-palette .note-color-reset:hover,.note-editor .note-toolbar .note-color .note-dropdown-menu .note-palette .note-color-select:hover{background:#eee}.note-popover .popover-content .note-color .note-dropdown-menu .note-palette .note-color-row,.note-editor .note-toolbar .note-color .note-dropdown-menu .note-palette .note-color-row{height:20px}.note-popover .popover-content .note-color .note-dropdown-menu .note-palette .note-color-select-btn,.note-editor .note-toolbar .note-color .note-dropdown-menu .note-palette .note-color-select-btn{display:none}.note-popover .popover-content .note-color .note-dropdown-menu .note-palette .note-holder-custom .note-color-btn,.note-editor .note-toolbar .note-color .note-dropdown-menu .note-palette .note-holder-custom .note-color-btn{border:1px solid #eee}.note-popover .popover-content .note-para .note-dropdown-menu,.note-editor .note-toolbar .note-para .note-dropdown-menu{min-width:228px;padding:5px}.note-popover .popover-content .note-para .note-dropdown-menu>div+div,.note-editor .note-toolbar .note-para .note-dropdown-menu>div+div{margin-left:5px}.note-popover .popover-content .note-dropdown-menu,.note-editor .note-toolbar .note-dropdown-menu{min-width:160px}.note-popover .popover-content .note-dropdown-menu.right,.note-editor .note-toolbar .note-dropdown-menu.right{right:0;left:auto}.note-popover .popover-content .note-dropdown-menu.right::before,.note-editor .note-toolbar .note-dropdown-menu.right::before{right:9px;left:auto !important}.note-popover .popover-content .note-dropdown-menu.right::after,.note-editor .note-toolbar .note-dropdown-menu.right::after{right:10px;left:auto !important}.note-popover .popover-content .note-dropdown-menu.note-check a i,.note-editor .note-toolbar .note-dropdown-menu.note-check a i{color:#00bfff;visibility:hidden}.note-popover .popover-content .note-dropdown-menu.note-check a.checked i,.note-editor .note-toolbar .note-dropdown-menu.note-check a.checked i{visibility:visible}.note-popover .popover-content .note-fontsize-10,.note-editor .note-toolbar .note-fontsize-10{font-size:10px}.note-popover .popover-content .note-color-palette,.note-editor .note-toolbar .note-color-palette{line-height:1}.note-popover .popover-content .note-color-palette div .note-color-btn,.note-editor .note-toolbar .note-color-palette div .note-color-btn{width:20px;height:20px;padding:0;margin:0;border:0;border-radius:0}.note-popover .popover-content .note-color-palette div .note-color-btn:hover,.note-editor .note-toolbar .note-color-palette div .note-color-btn:hover{transform:scale(1.2);transition:all .2s}.note-modal .modal-dialog{outline:0;border-radius:5px;box-shadow:0 3px 9px rgba(0,0,0,.5)}.note-modal .form-group{margin-left:0;margin-right:0}.note-modal .note-modal-form{margin:0}.note-modal .note-image-dialog .note-dropzone{min-height:100px;font-size:30px;line-height:4;color:#d3d3d3;text-align:center;border:4px dashed #d3d3d3;margin-bottom:10px}@-moz-document url-prefix(){.note-modal .note-image-input{height:auto}}.note-placeholder{position:absolute;display:none;color:gray}.note-handle .note-control-selection{position:absolute;display:none;border:1px solid #000}.note-handle .note-control-selection>div{position:absolute}.note-handle .note-control-selection .note-control-selection-bg{width:100%;height:100%;background-color:#000;-webkit-opacity:.3;-khtml-opacity:.3;-moz-opacity:.3;opacity:.3;-ms-filter:progid:DXImageTransform.Microsoft.Alpha(opacity=30);filter:alpha(opacity=30)}.note-handle .note-control-selection .note-control-handle,.note-handle .note-control-selection .note-control-sizing,.note-handle .note-control-selection .note-control-holder{width:7px;height:7px;border:1px solid #000}.note-handle .note-control-selection .note-control-sizing{background-color:#000}.note-handle .note-control-selection .note-control-nw{top:-5px;left:-5px;border-right:none;border-bottom:none}.note-handle .note-control-selection .note-control-ne{top:-5px;right:-5px;border-bottom:none;border-left:none}.note-handle .note-control-selection .note-control-sw{bottom:-5px;left:-5px;border-top:none;border-right:none}.note-handle .note-control-selection .note-control-se{right:-5px;bottom:-5px;cursor:se-resize}.note-handle .note-control-selection .note-control-se.note-control-holder{cursor:default;border-top:none;border-left:none}.note-handle .note-control-selection .note-control-selection-info{right:0;bottom:0;padding:5px;margin:5px;color:#fff;background-color:#000;font-size:12px;border-radius:5px;-webkit-opacity:.7;-khtml-opacity:.7;-moz-opacity:.7;opacity:.7;-ms-filter:progid:DXImageTransform.Microsoft.Alpha(opacity=70);filter:alpha(opacity=70)}.note-hint-popover{min-width:100px;padding:2px}.note-hint-popover .popover-content{padding:3px;max-height:150px;overflow:auto}.note-hint-popover .popover-content .note-hint-group .note-hint-item{display:block !important;padding:3px}.note-hint-popover .popover-content .note-hint-group .note-hint-item.active,.note-hint-popover .popover-content .note-hint-group .note-hint-item:hover{display:block;clear:both;font-weight:400;line-height:1.4;color:#fff;white-space:nowrap;text-decoration:none;background-color:#428bca;outline:0;cursor:pointer}.note-toolbar{background:#8080801d}.note-btn-group .note-btn{border-color:#00000032;padding:.28rem .65rem;font-size:13px}
diff --git a/BTCPayServer/wwwroot/vendor/summernote/summernote-bs4.js b/BTCPayServer/wwwroot/vendor/summernote/summernote-bs4.js
index efe375795..7347d6e99 100644
--- a/BTCPayServer/wwwroot/vendor/summernote/summernote-bs4.js
+++ b/BTCPayServer/wwwroot/vendor/summernote/summernote-bs4.js
@@ -1,7574 +1,10234 @@
-/**
- * Super simple wysiwyg editor v0.8.11
+/*!
+ *
+ * Super simple wysiwyg editor v0.8.18
* https://summernote.org
- *
+ *
+ *
* Copyright 2013- Alan Hong. and other contributors
* summernote may be freely distributed under the MIT license.
- *
- * Date: 2018-11-24T12:13Z
+ *
+ * Date: 2020-05-20T18:09Z
+ *
*/
-(function (global, factory) {
- typeof exports === 'object' && typeof module !== 'undefined' ? factory(require('jquery')) :
- typeof define === 'function' && define.amd ? define(['jquery'], factory) :
- (factory(global.jQuery));
-}(this, (function ($$1) { 'use strict';
+(function webpackUniversalModuleDefinition(root, factory) {
+ if(typeof exports === 'object' && typeof module === 'object')
+ module.exports = factory(require("jquery"));
+ else if(typeof define === 'function' && define.amd)
+ define(["jquery"], factory);
+ else {
+ var a = typeof exports === 'object' ? factory(require("jquery")) : factory(root["jQuery"]);
+ for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
+ }
+})(window, function(__WEBPACK_EXTERNAL_MODULE__0__) {
+return /******/ (function(modules) { // webpackBootstrap
+/******/ // The module cache
+/******/ var installedModules = {};
+/******/
+/******/ // The require function
+/******/ function __webpack_require__(moduleId) {
+/******/
+/******/ // Check if module is in cache
+/******/ if(installedModules[moduleId]) {
+/******/ return installedModules[moduleId].exports;
+/******/ }
+/******/ // Create a new module (and put it into the cache)
+/******/ var module = installedModules[moduleId] = {
+/******/ i: moduleId,
+/******/ l: false,
+/******/ exports: {}
+/******/ };
+/******/
+/******/ // Execute the module function
+/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
+/******/
+/******/ // Flag the module as loaded
+/******/ module.l = true;
+/******/
+/******/ // Return the exports of the module
+/******/ return module.exports;
+/******/ }
+/******/
+/******/
+/******/ // expose the modules object (__webpack_modules__)
+/******/ __webpack_require__.m = modules;
+/******/
+/******/ // expose the module cache
+/******/ __webpack_require__.c = installedModules;
+/******/
+/******/ // define getter function for harmony exports
+/******/ __webpack_require__.d = function(exports, name, getter) {
+/******/ if(!__webpack_require__.o(exports, name)) {
+/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter });
+/******/ }
+/******/ };
+/******/
+/******/ // define __esModule on exports
+/******/ __webpack_require__.r = function(exports) {
+/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
+/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
+/******/ }
+/******/ Object.defineProperty(exports, '__esModule', { value: true });
+/******/ };
+/******/
+/******/ // create a fake namespace object
+/******/ // mode & 1: value is a module id, require it
+/******/ // mode & 2: merge all properties of value into the ns
+/******/ // mode & 4: return value when already ns object
+/******/ // mode & 8|1: behave like require
+/******/ __webpack_require__.t = function(value, mode) {
+/******/ if(mode & 1) value = __webpack_require__(value);
+/******/ if(mode & 8) return value;
+/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
+/******/ var ns = Object.create(null);
+/******/ __webpack_require__.r(ns);
+/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value });
+/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
+/******/ return ns;
+/******/ };
+/******/
+/******/ // getDefaultExport function for compatibility with non-harmony modules
+/******/ __webpack_require__.n = function(module) {
+/******/ var getter = module && module.__esModule ?
+/******/ function getDefault() { return module['default']; } :
+/******/ function getModuleExports() { return module; };
+/******/ __webpack_require__.d(getter, 'a', getter);
+/******/ return getter;
+/******/ };
+/******/
+/******/ // Object.prototype.hasOwnProperty.call
+/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
+/******/
+/******/ // __webpack_public_path__
+/******/ __webpack_require__.p = "";
+/******/
+/******/
+/******/ // Load entry module and return exports
+/******/ return __webpack_require__(__webpack_require__.s = 53);
+/******/ })
+/************************************************************************/
+/******/ ({
- $$1 = $$1 && $$1.hasOwnProperty('default') ? $$1['default'] : $$1;
+/***/ 0:
+/***/ (function(module, exports) {
- var Renderer = /** @class */ (function () {
- function Renderer(markup, children, options, callback) {
- this.markup = markup;
- this.children = children;
- this.options = options;
- this.callback = callback;
+module.exports = __WEBPACK_EXTERNAL_MODULE__0__;
+
+/***/ }),
+
+/***/ 1:
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(0);
+/* harmony import */ var jquery__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(jquery__WEBPACK_IMPORTED_MODULE_0__);
+function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
+
+function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+
+function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
+
+function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; }
+
+
+
+var Renderer = /*#__PURE__*/function () {
+ function Renderer(markup, children, options, callback) {
+ _classCallCheck(this, Renderer);
+
+ this.markup = markup;
+ this.children = children;
+ this.options = options;
+ this.callback = callback;
+ }
+
+ _createClass(Renderer, [{
+ key: "render",
+ value: function render($parent) {
+ var $node = jquery__WEBPACK_IMPORTED_MODULE_0___default()(this.markup);
+
+ if (this.options && this.options.contents) {
+ $node.html(this.options.contents);
}
- Renderer.prototype.render = function ($parent) {
- var $node = $$1(this.markup);
- if (this.options && this.options.contents) {
- $node.html(this.options.contents);
- }
- if (this.options && this.options.className) {
- $node.addClass(this.options.className);
- }
- if (this.options && this.options.data) {
- $$1.each(this.options.data, function (k, v) {
- $node.attr('data-' + k, v);
- });
- }
- if (this.options && this.options.click) {
- $node.on('click', this.options.click);
- }
- if (this.children) {
- var $container_1 = $node.find('.note-children-container');
- this.children.forEach(function (child) {
- child.render($container_1.length ? $container_1 : $node);
- });
- }
- if (this.callback) {
- this.callback($node, this.options);
- }
- if (this.options && this.options.callback) {
- this.options.callback($node);
- }
- if ($parent) {
- $parent.append($node);
- }
- return $node;
+
+ if (this.options && this.options.className) {
+ $node.addClass(this.options.className);
+ }
+
+ if (this.options && this.options.data) {
+ jquery__WEBPACK_IMPORTED_MODULE_0___default.a.each(this.options.data, function (k, v) {
+ $node.attr('data-' + k, v);
+ });
+ }
+
+ if (this.options && this.options.click) {
+ $node.on('click', this.options.click);
+ }
+
+ if (this.children) {
+ var $container = $node.find('.note-children-container');
+ this.children.forEach(function (child) {
+ child.render($container.length ? $container : $node);
+ });
+ }
+
+ if (this.callback) {
+ this.callback($node, this.options);
+ }
+
+ if (this.options && this.options.callback) {
+ this.options.callback($node);
+ }
+
+ if ($parent) {
+ $parent.append($node);
+ }
+
+ return $node;
+ }
+ }]);
+
+ return Renderer;
+}();
+
+/* harmony default export */ __webpack_exports__["a"] = ({
+ create: function create(markup, callback) {
+ return function () {
+ var options = _typeof(arguments[1]) === 'object' ? arguments[1] : arguments[0];
+ var children = Array.isArray(arguments[0]) ? arguments[0] : [];
+
+ if (options && options.children) {
+ children = options.children;
+ }
+
+ return new Renderer(markup, children, options, callback);
+ };
+ }
+});
+
+/***/ }),
+
+/***/ 2:
+/***/ (function(module, exports) {
+
+/* WEBPACK VAR INJECTION */(function(__webpack_amd_options__) {/* globals __webpack_amd_options__ */
+module.exports = __webpack_amd_options__;
+
+/* WEBPACK VAR INJECTION */}.call(this, {}))
+
+/***/ }),
+
+/***/ 3:
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
+
+"use strict";
+
+// EXTERNAL MODULE: external {"root":"jQuery","commonjs2":"jquery","commonjs":"jquery","amd":"jquery"}
+var external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_ = __webpack_require__(0);
+var external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default = /*#__PURE__*/__webpack_require__.n(external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_);
+
+// CONCATENATED MODULE: ./src/js/base/summernote-en-US.js
+
+external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.summernote = external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.summernote || {
+ lang: {}
+};
+external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.extend(external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.summernote.lang, {
+ 'en-US': {
+ font: {
+ bold: 'Bold',
+ italic: 'Italic',
+ underline: 'Underline',
+ clear: 'Remove Font Style',
+ height: 'Line Height',
+ name: 'Font Family',
+ strikethrough: 'Strikethrough',
+ subscript: 'Subscript',
+ superscript: 'Superscript',
+ size: 'Font Size',
+ sizeunit: 'Font Size Unit'
+ },
+ image: {
+ image: 'Picture',
+ insert: 'Insert Image',
+ resizeFull: 'Resize full',
+ resizeHalf: 'Resize half',
+ resizeQuarter: 'Resize quarter',
+ resizeNone: 'Original size',
+ floatLeft: 'Float Left',
+ floatRight: 'Float Right',
+ floatNone: 'Remove float',
+ shapeRounded: 'Shape: Rounded',
+ shapeCircle: 'Shape: Circle',
+ shapeThumbnail: 'Shape: Thumbnail',
+ shapeNone: 'Shape: None',
+ dragImageHere: 'Drag image or text here',
+ dropImage: 'Drop image or Text',
+ selectFromFiles: 'Select from files',
+ maximumFileSize: 'Maximum file size',
+ maximumFileSizeError: 'Maximum file size exceeded.',
+ url: 'Image URL',
+ remove: 'Remove Image',
+ original: 'Original'
+ },
+ video: {
+ video: 'Video',
+ videoLink: 'Video Link',
+ insert: 'Insert Video',
+ url: 'Video URL',
+ providers: '(YouTube, Vimeo, Vine, Instagram, DailyMotion or Youku)'
+ },
+ link: {
+ link: 'Link',
+ insert: 'Insert Link',
+ unlink: 'Unlink',
+ edit: 'Edit',
+ textToDisplay: 'Text to display',
+ url: 'To what URL should this link go?',
+ openInNewWindow: 'Open in new window',
+ useProtocol: 'Use default protocol'
+ },
+ table: {
+ table: 'Table',
+ addRowAbove: 'Add row above',
+ addRowBelow: 'Add row below',
+ addColLeft: 'Add column left',
+ addColRight: 'Add column right',
+ delRow: 'Delete row',
+ delCol: 'Delete column',
+ delTable: 'Delete table'
+ },
+ hr: {
+ insert: 'Insert Horizontal Rule'
+ },
+ style: {
+ style: 'Style',
+ p: 'Normal',
+ blockquote: 'Quote',
+ pre: 'Code',
+ h1: 'Header 1',
+ h2: 'Header 2',
+ h3: 'Header 3',
+ h4: 'Header 4',
+ h5: 'Header 5',
+ h6: 'Header 6'
+ },
+ lists: {
+ unordered: 'Unordered list',
+ ordered: 'Ordered list'
+ },
+ options: {
+ help: 'Help',
+ fullscreen: 'Full Screen',
+ codeview: 'Code View'
+ },
+ paragraph: {
+ paragraph: 'Paragraph',
+ outdent: 'Outdent',
+ indent: 'Indent',
+ left: 'Align left',
+ center: 'Align center',
+ right: 'Align right',
+ justify: 'Justify full'
+ },
+ color: {
+ recent: 'Recent Color',
+ more: 'More Color',
+ background: 'Background Color',
+ foreground: 'Text Color',
+ transparent: 'Transparent',
+ setTransparent: 'Set transparent',
+ reset: 'Reset',
+ resetToDefault: 'Reset to default',
+ cpSelect: 'Select'
+ },
+ shortcut: {
+ shortcuts: 'Keyboard shortcuts',
+ close: 'Close',
+ textFormatting: 'Text formatting',
+ action: 'Action',
+ paragraphFormatting: 'Paragraph formatting',
+ documentStyle: 'Document Style',
+ extraKeys: 'Extra keys'
+ },
+ help: {
+ 'escape': 'Escape',
+ 'insertParagraph': 'Insert Paragraph',
+ 'undo': 'Undo the last command',
+ 'redo': 'Redo the last command',
+ 'tab': 'Tab',
+ 'untab': 'Untab',
+ 'bold': 'Set a bold style',
+ 'italic': 'Set a italic style',
+ 'underline': 'Set a underline style',
+ 'strikethrough': 'Set a strikethrough style',
+ 'removeFormat': 'Clean a style',
+ 'justifyLeft': 'Set left align',
+ 'justifyCenter': 'Set center align',
+ 'justifyRight': 'Set right align',
+ 'justifyFull': 'Set full align',
+ 'insertUnorderedList': 'Toggle unordered list',
+ 'insertOrderedList': 'Toggle ordered list',
+ 'outdent': 'Outdent on current paragraph',
+ 'indent': 'Indent on current paragraph',
+ 'formatPara': 'Change current block\'s format as a paragraph(P tag)',
+ 'formatH1': 'Change current block\'s format as H1',
+ 'formatH2': 'Change current block\'s format as H2',
+ 'formatH3': 'Change current block\'s format as H3',
+ 'formatH4': 'Change current block\'s format as H4',
+ 'formatH5': 'Change current block\'s format as H5',
+ 'formatH6': 'Change current block\'s format as H6',
+ 'insertHorizontalRule': 'Insert horizontal rule',
+ 'linkDialog.show': 'Show Link Dialog'
+ },
+ history: {
+ undo: 'Undo',
+ redo: 'Redo'
+ },
+ specialChar: {
+ specialChar: 'SPECIAL CHARACTERS',
+ select: 'Select Special characters'
+ },
+ output: {
+ noSelection: 'No Selection Made!'
+ }
+ }
+});
+// CONCATENATED MODULE: ./src/js/base/core/env.js
+
+var isSupportAmd = typeof define === 'function' && __webpack_require__(2); // eslint-disable-line
+
+/**
+ * returns whether font is installed or not.
+ *
+ * @param {String} fontName
+ * @return {Boolean}
+ */
+
+var genericFontFamilies = ['sans-serif', 'serif', 'monospace', 'cursive', 'fantasy'];
+
+function validFontName(fontName) {
+ return external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.inArray(fontName.toLowerCase(), genericFontFamilies) === -1 ? "'".concat(fontName, "'") : fontName;
+}
+
+function env_isFontInstalled(fontName) {
+ var testFontName = fontName === 'Comic Sans MS' ? 'Courier New' : 'Comic Sans MS';
+ var testText = 'mmmmmmmmmmwwwww';
+ var testSize = '200px';
+ var canvas = document.createElement('canvas');
+ var context = canvas.getContext('2d');
+ context.font = testSize + " '" + testFontName + "'";
+ var originalWidth = context.measureText(testText).width;
+ context.font = testSize + ' ' + validFontName(fontName) + ', "' + testFontName + '"';
+ var width = context.measureText(testText).width;
+ return originalWidth !== width;
+}
+
+var userAgent = navigator.userAgent;
+var isMSIE = /MSIE|Trident/i.test(userAgent);
+var browserVersion;
+
+if (isMSIE) {
+ var matches = /MSIE (\d+[.]\d+)/.exec(userAgent);
+
+ if (matches) {
+ browserVersion = parseFloat(matches[1]);
+ }
+
+ matches = /Trident\/.*rv:([0-9]{1,}[.0-9]{0,})/.exec(userAgent);
+
+ if (matches) {
+ browserVersion = parseFloat(matches[1]);
+ }
+}
+
+var isEdge = /Edge\/\d+/.test(userAgent);
+var isSupportTouch = 'ontouchstart' in window || navigator.MaxTouchPoints > 0 || navigator.msMaxTouchPoints > 0; // [workaround] IE doesn't have input events for contentEditable
+// - see: https://goo.gl/4bfIvA
+
+var inputEventName = isMSIE ? 'DOMCharacterDataModified DOMSubtreeModified DOMNodeInserted' : 'input';
+/**
+ * @class core.env
+ *
+ * Object which check platform and agent
+ *
+ * @singleton
+ * @alternateClassName env
+ */
+
+/* harmony default export */ var env = ({
+ isMac: navigator.appVersion.indexOf('Mac') > -1,
+ isMSIE: isMSIE,
+ isEdge: isEdge,
+ isFF: !isEdge && /firefox/i.test(userAgent),
+ isPhantom: /PhantomJS/i.test(userAgent),
+ isWebkit: !isEdge && /webkit/i.test(userAgent),
+ isChrome: !isEdge && /chrome/i.test(userAgent),
+ isSafari: !isEdge && /safari/i.test(userAgent) && !/chrome/i.test(userAgent),
+ browserVersion: browserVersion,
+ jqueryVersion: parseFloat(external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.fn.jquery),
+ isSupportAmd: isSupportAmd,
+ isSupportTouch: isSupportTouch,
+ isFontInstalled: env_isFontInstalled,
+ isW3CRangeSupport: !!document.createRange,
+ inputEventName: inputEventName,
+ genericFontFamilies: genericFontFamilies,
+ validFontName: validFontName
+});
+// CONCATENATED MODULE: ./src/js/base/core/func.js
+
+/**
+ * @class core.func
+ *
+ * func utils (for high-order func's arg)
+ *
+ * @singleton
+ * @alternateClassName func
+ */
+
+function eq(itemA) {
+ return function (itemB) {
+ return itemA === itemB;
+ };
+}
+
+function eq2(itemA, itemB) {
+ return itemA === itemB;
+}
+
+function peq2(propName) {
+ return function (itemA, itemB) {
+ return itemA[propName] === itemB[propName];
+ };
+}
+
+function ok() {
+ return true;
+}
+
+function fail() {
+ return false;
+}
+
+function not(f) {
+ return function () {
+ return !f.apply(f, arguments);
+ };
+}
+
+function and(fA, fB) {
+ return function (item) {
+ return fA(item) && fB(item);
+ };
+}
+
+function func_self(a) {
+ return a;
+}
+
+function func_invoke(obj, method) {
+ return function () {
+ return obj[method].apply(obj, arguments);
+ };
+}
+
+var idCounter = 0;
+/**
+ * reset globally-unique id
+ *
+ */
+
+function resetUniqueId() {
+ idCounter = 0;
+}
+/**
+ * generate a globally-unique id
+ *
+ * @param {String} [prefix]
+ */
+
+
+function uniqueId(prefix) {
+ var id = ++idCounter + '';
+ return prefix ? prefix + id : id;
+}
+/**
+ * returns bnd (bounds) from rect
+ *
+ * - IE Compatibility Issue: http://goo.gl/sRLOAo
+ * - Scroll Issue: http://goo.gl/sNjUc
+ *
+ * @param {Rect} rect
+ * @return {Object} bounds
+ * @return {Number} bounds.top
+ * @return {Number} bounds.left
+ * @return {Number} bounds.width
+ * @return {Number} bounds.height
+ */
+
+
+function rect2bnd(rect) {
+ var $document = external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default()(document);
+ return {
+ top: rect.top + $document.scrollTop(),
+ left: rect.left + $document.scrollLeft(),
+ width: rect.right - rect.left,
+ height: rect.bottom - rect.top
+ };
+}
+/**
+ * returns a copy of the object where the keys have become the values and the values the keys.
+ * @param {Object} obj
+ * @return {Object}
+ */
+
+
+function invertObject(obj) {
+ var inverted = {};
+
+ for (var key in obj) {
+ if (Object.prototype.hasOwnProperty.call(obj, key)) {
+ inverted[obj[key]] = key;
+ }
+ }
+
+ return inverted;
+}
+/**
+ * @param {String} namespace
+ * @param {String} [prefix]
+ * @return {String}
+ */
+
+
+function namespaceToCamel(namespace, prefix) {
+ prefix = prefix || '';
+ return prefix + namespace.split('.').map(function (name) {
+ return name.substring(0, 1).toUpperCase() + name.substring(1);
+ }).join('');
+}
+/**
+ * Returns a function, that, as long as it continues to be invoked, will not
+ * be triggered. The function will be called after it stops being called for
+ * N milliseconds. If `immediate` is passed, trigger the function on the
+ * leading edge, instead of the trailing.
+ * @param {Function} func
+ * @param {Number} wait
+ * @param {Boolean} immediate
+ * @return {Function}
+ */
+
+
+function debounce(func, wait, immediate) {
+ var timeout;
+ return function () {
+ var context = this;
+ var args = arguments;
+
+ var later = function later() {
+ timeout = null;
+
+ if (!immediate) {
+ func.apply(context, args);
+ }
+ };
+
+ var callNow = immediate && !timeout;
+ clearTimeout(timeout);
+ timeout = setTimeout(later, wait);
+
+ if (callNow) {
+ func.apply(context, args);
+ }
+ };
+}
+/**
+ *
+ * @param {String} url
+ * @return {Boolean}
+ */
+
+
+function isValidUrl(url) {
+ var expression = /[-a-zA-Z0-9@:%._\+~#=]{2,256}\.[a-z]{2,6}\b([-a-zA-Z0-9@:%_\+.~#?&//=]*)/gi;
+ return expression.test(url);
+}
+
+/* harmony default export */ var func = ({
+ eq: eq,
+ eq2: eq2,
+ peq2: peq2,
+ ok: ok,
+ fail: fail,
+ self: func_self,
+ not: not,
+ and: and,
+ invoke: func_invoke,
+ resetUniqueId: resetUniqueId,
+ uniqueId: uniqueId,
+ rect2bnd: rect2bnd,
+ invertObject: invertObject,
+ namespaceToCamel: namespaceToCamel,
+ debounce: debounce,
+ isValidUrl: isValidUrl
+});
+// CONCATENATED MODULE: ./src/js/base/core/lists.js
+
+/**
+ * returns the first item of an array.
+ *
+ * @param {Array} array
+ */
+
+function lists_head(array) {
+ return array[0];
+}
+/**
+ * returns the last item of an array.
+ *
+ * @param {Array} array
+ */
+
+
+function lists_last(array) {
+ return array[array.length - 1];
+}
+/**
+ * returns everything but the last entry of the array.
+ *
+ * @param {Array} array
+ */
+
+
+function initial(array) {
+ return array.slice(0, array.length - 1);
+}
+/**
+ * returns the rest of the items in an array.
+ *
+ * @param {Array} array
+ */
+
+
+function tail(array) {
+ return array.slice(1);
+}
+/**
+ * returns item of array
+ */
+
+
+function find(array, pred) {
+ for (var idx = 0, len = array.length; idx < len; idx++) {
+ var item = array[idx];
+
+ if (pred(item)) {
+ return item;
+ }
+ }
+}
+/**
+ * returns true if all of the values in the array pass the predicate truth test.
+ */
+
+
+function lists_all(array, pred) {
+ for (var idx = 0, len = array.length; idx < len; idx++) {
+ if (!pred(array[idx])) {
+ return false;
+ }
+ }
+
+ return true;
+}
+/**
+ * returns true if the value is present in the list.
+ */
+
+
+function contains(array, item) {
+ if (array && array.length && item) {
+ if (array.indexOf) {
+ return array.indexOf(item) !== -1;
+ } else if (array.contains) {
+ // `DOMTokenList` doesn't implement `.indexOf`, but it implements `.contains`
+ return array.contains(item);
+ }
+ }
+
+ return false;
+}
+/**
+ * get sum from a list
+ *
+ * @param {Array} array - array
+ * @param {Function} fn - iterator
+ */
+
+
+function sum(array, fn) {
+ fn = fn || func.self;
+ return array.reduce(function (memo, v) {
+ return memo + fn(v);
+ }, 0);
+}
+/**
+ * returns a copy of the collection with array type.
+ * @param {Collection} collection - collection eg) node.childNodes, ...
+ */
+
+
+function from(collection) {
+ var result = [];
+ var length = collection.length;
+ var idx = -1;
+
+ while (++idx < length) {
+ result[idx] = collection[idx];
+ }
+
+ return result;
+}
+/**
+ * returns whether list is empty or not
+ */
+
+
+function lists_isEmpty(array) {
+ return !array || !array.length;
+}
+/**
+ * cluster elements by predicate function.
+ *
+ * @param {Array} array - array
+ * @param {Function} fn - predicate function for cluster rule
+ * @param {Array[]}
+ */
+
+
+function clusterBy(array, fn) {
+ if (!array.length) {
+ return [];
+ }
+
+ var aTail = tail(array);
+ return aTail.reduce(function (memo, v) {
+ var aLast = lists_last(memo);
+
+ if (fn(lists_last(aLast), v)) {
+ aLast[aLast.length] = v;
+ } else {
+ memo[memo.length] = [v];
+ }
+
+ return memo;
+ }, [[lists_head(array)]]);
+}
+/**
+ * returns a copy of the array with all false values removed
+ *
+ * @param {Array} array - array
+ * @param {Function} fn - predicate function for cluster rule
+ */
+
+
+function compact(array) {
+ var aResult = [];
+
+ for (var idx = 0, len = array.length; idx < len; idx++) {
+ if (array[idx]) {
+ aResult.push(array[idx]);
+ }
+ }
+
+ return aResult;
+}
+/**
+ * produces a duplicate-free version of the array
+ *
+ * @param {Array} array
+ */
+
+
+function unique(array) {
+ var results = [];
+
+ for (var idx = 0, len = array.length; idx < len; idx++) {
+ if (!contains(results, array[idx])) {
+ results.push(array[idx]);
+ }
+ }
+
+ return results;
+}
+/**
+ * returns next item.
+ * @param {Array} array
+ */
+
+
+function lists_next(array, item) {
+ if (array && array.length && item) {
+ var idx = array.indexOf(item);
+ return idx === -1 ? null : array[idx + 1];
+ }
+
+ return null;
+}
+/**
+ * returns prev item.
+ * @param {Array} array
+ */
+
+
+function prev(array, item) {
+ if (array && array.length && item) {
+ var idx = array.indexOf(item);
+ return idx === -1 ? null : array[idx - 1];
+ }
+
+ return null;
+}
+/**
+ * @class core.list
+ *
+ * list utils
+ *
+ * @singleton
+ * @alternateClassName list
+ */
+
+
+/* harmony default export */ var lists = ({
+ head: lists_head,
+ last: lists_last,
+ initial: initial,
+ tail: tail,
+ prev: prev,
+ next: lists_next,
+ find: find,
+ contains: contains,
+ all: lists_all,
+ sum: sum,
+ from: from,
+ isEmpty: lists_isEmpty,
+ clusterBy: clusterBy,
+ compact: compact,
+ unique: unique
+});
+// CONCATENATED MODULE: ./src/js/base/core/dom.js
+
+
+
+
+var NBSP_CHAR = String.fromCharCode(160);
+var ZERO_WIDTH_NBSP_CHAR = "\uFEFF";
+/**
+ * @method isEditable
+ *
+ * returns whether node is `note-editable` or not.
+ *
+ * @param {Node} node
+ * @return {Boolean}
+ */
+
+function isEditable(node) {
+ return node && external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default()(node).hasClass('note-editable');
+}
+/**
+ * @method isControlSizing
+ *
+ * returns whether node is `note-control-sizing` or not.
+ *
+ * @param {Node} node
+ * @return {Boolean}
+ */
+
+
+function isControlSizing(node) {
+ return node && external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default()(node).hasClass('note-control-sizing');
+}
+/**
+ * @method makePredByNodeName
+ *
+ * returns predicate which judge whether nodeName is same
+ *
+ * @param {String} nodeName
+ * @return {Function}
+ */
+
+
+function makePredByNodeName(nodeName) {
+ nodeName = nodeName.toUpperCase();
+ return function (node) {
+ return node && node.nodeName.toUpperCase() === nodeName;
+ };
+}
+/**
+ * @method isText
+ *
+ *
+ *
+ * @param {Node} node
+ * @return {Boolean} true if node's type is text(3)
+ */
+
+
+function isText(node) {
+ return node && node.nodeType === 3;
+}
+/**
+ * @method isElement
+ *
+ *
+ *
+ * @param {Node} node
+ * @return {Boolean} true if node's type is element(1)
+ */
+
+
+function isElement(node) {
+ return node && node.nodeType === 1;
+}
+/**
+ * ex) br, col, embed, hr, img, input, ...
+ * @see http://www.w3.org/html/wg/drafts/html/master/syntax.html#void-elements
+ */
+
+
+function isVoid(node) {
+ return node && /^BR|^IMG|^HR|^IFRAME|^BUTTON|^INPUT|^AUDIO|^VIDEO|^EMBED/.test(node.nodeName.toUpperCase());
+}
+
+function isPara(node) {
+ if (isEditable(node)) {
+ return false;
+ } // Chrome(v31.0), FF(v25.0.1) use DIV for paragraph
+
+
+ return node && /^DIV|^P|^LI|^H[1-7]/.test(node.nodeName.toUpperCase());
+}
+
+function isHeading(node) {
+ return node && /^H[1-7]/.test(node.nodeName.toUpperCase());
+}
+
+var isPre = makePredByNodeName('PRE');
+var isLi = makePredByNodeName('LI');
+
+function isPurePara(node) {
+ return isPara(node) && !isLi(node);
+}
+
+var isTable = makePredByNodeName('TABLE');
+var isData = makePredByNodeName('DATA');
+
+function dom_isInline(node) {
+ return !isBodyContainer(node) && !isList(node) && !isHr(node) && !isPara(node) && !isTable(node) && !isBlockquote(node) && !isData(node);
+}
+
+function isList(node) {
+ return node && /^UL|^OL/.test(node.nodeName.toUpperCase());
+}
+
+var isHr = makePredByNodeName('HR');
+
+function dom_isCell(node) {
+ return node && /^TD|^TH/.test(node.nodeName.toUpperCase());
+}
+
+var isBlockquote = makePredByNodeName('BLOCKQUOTE');
+
+function isBodyContainer(node) {
+ return dom_isCell(node) || isBlockquote(node) || isEditable(node);
+}
+
+var isAnchor = makePredByNodeName('A');
+
+function isParaInline(node) {
+ return dom_isInline(node) && !!dom_ancestor(node, isPara);
+}
+
+function isBodyInline(node) {
+ return dom_isInline(node) && !dom_ancestor(node, isPara);
+}
+
+var isBody = makePredByNodeName('BODY');
+/**
+ * returns whether nodeB is closest sibling of nodeA
+ *
+ * @param {Node} nodeA
+ * @param {Node} nodeB
+ * @return {Boolean}
+ */
+
+function isClosestSibling(nodeA, nodeB) {
+ return nodeA.nextSibling === nodeB || nodeA.previousSibling === nodeB;
+}
+/**
+ * returns array of closest siblings with node
+ *
+ * @param {Node} node
+ * @param {function} [pred] - predicate function
+ * @return {Node[]}
+ */
+
+
+function withClosestSiblings(node, pred) {
+ pred = pred || func.ok;
+ var siblings = [];
+
+ if (node.previousSibling && pred(node.previousSibling)) {
+ siblings.push(node.previousSibling);
+ }
+
+ siblings.push(node);
+
+ if (node.nextSibling && pred(node.nextSibling)) {
+ siblings.push(node.nextSibling);
+ }
+
+ return siblings;
+}
+/**
+ * blank HTML for cursor position
+ * - [workaround] old IE only works with
+ * - [workaround] IE11 and other browser works with bogus br
+ */
+
+
+var blankHTML = env.isMSIE && env.browserVersion < 11 ? ' ' : '
';
+/**
+ * @method nodeLength
+ *
+ * returns #text's text size or element's childNodes size
+ *
+ * @param {Node} node
+ */
+
+function nodeLength(node) {
+ if (isText(node)) {
+ return node.nodeValue.length;
+ }
+
+ if (node) {
+ return node.childNodes.length;
+ }
+
+ return 0;
+}
+/**
+ * returns whether deepest child node is empty or not.
+ *
+ * @param {Node} node
+ * @return {Boolean}
+ */
+
+
+function deepestChildIsEmpty(node) {
+ do {
+ if (node.firstElementChild === null || node.firstElementChild.innerHTML === '') break;
+ } while (node = node.firstElementChild);
+
+ return dom_isEmpty(node);
+}
+/**
+ * returns whether node is empty or not.
+ *
+ * @param {Node} node
+ * @return {Boolean}
+ */
+
+
+function dom_isEmpty(node) {
+ var len = nodeLength(node);
+
+ if (len === 0) {
+ return true;
+ } else if (!isText(node) && len === 1 && node.innerHTML === blankHTML) {
+ // ex)
] + var ancestors = listAncestor(point.node, func.eq(root)); + + if (!ancestors.length) { + return null; + } else if (ancestors.length === 1) { + return splitNode(point, options); + } + + return ancestors.reduce(function (node, parent) { + if (node === point.node) { + node = splitNode(point, options); + } + + return splitNode({ + node: parent, + offset: node ? dom_position(node) : nodeLength(parent) + }, options); + }); +} +/** + * split point + * + * @param {Point} point + * @param {Boolean} isInline + * @return {Object} + */ + + +function splitPoint(point, isInline) { + // find splitRoot, container + // - inline: splitRoot is a child of paragraph + // - block: splitRoot is a child of bodyContainer + var pred = isInline ? isPara : isBodyContainer; + var ancestors = listAncestor(point.node, pred); + var topAncestor = lists.last(ancestors) || point.node; + var splitRoot, container; + + if (pred(topAncestor)) { + splitRoot = ancestors[ancestors.length - 2]; + container = topAncestor; + } else { + splitRoot = topAncestor; + container = splitRoot.parentNode; + } // if splitRoot is exists, split with splitTree + + + var pivot = splitRoot && splitTree(splitRoot, point, { + isSkipPaddingBlankHTML: isInline, + isNotSplitEdgePoint: isInline + }); // if container is point.node, find pivot with point.offset + + if (!pivot && container === point.node) { + pivot = point.node.childNodes[point.offset]; + } + + return { + rightNode: pivot, + container: container + }; +} + +function dom_create(nodeName) { + return document.createElement(nodeName); +} + +function createText(text) { + return document.createTextNode(text); +} +/** + * @method remove + * + * remove node, (isRemoveChild: remove child or not) + * + * @param {Node} node + * @param {Boolean} isRemoveChild + */ + + +function remove(node, isRemoveChild) { + if (!node || !node.parentNode) { + return; + } + + if (node.removeNode) { + return node.removeNode(isRemoveChild); + } + + var parent = node.parentNode; + + if (!isRemoveChild) { + var nodes = []; + + for (var i = 0, len = node.childNodes.length; i < len; i++) { + nodes.push(node.childNodes[i]); + } + + for (var _i = 0, _len = nodes.length; _i < _len; _i++) { + parent.insertBefore(nodes[_i], node); + } + } + + parent.removeChild(node); +} +/** + * @method removeWhile + * + * @param {Node} node + * @param {Function} pred + */ + + +function removeWhile(node, pred) { + while (node) { + if (isEditable(node) || !pred(node)) { + break; + } + + var parent = node.parentNode; + remove(node); + node = parent; + } +} +/** + * @method replace + * + * replace node with provided nodeName + * + * @param {Node} node + * @param {String} nodeName + * @return {Node} - new node + */ + + +function dom_replace(node, nodeName) { + if (node.nodeName.toUpperCase() === nodeName.toUpperCase()) { + return node; + } + + var newNode = dom_create(nodeName); + + if (node.style.cssText) { + newNode.style.cssText = node.style.cssText; + } + + appendChildNodes(newNode, lists.from(node.childNodes)); + insertAfter(newNode, node); + remove(node); + return newNode; +} + +var isTextarea = makePredByNodeName('TEXTAREA'); +/** + * @param {jQuery} $node + * @param {Boolean} [stripLinebreaks] - default: false + */ + +function dom_value($node, stripLinebreaks) { + var val = isTextarea($node[0]) ? $node.val() : $node.html(); + + if (stripLinebreaks) { + return val.replace(/[\n\r]/g, ''); + } + + return val; +} +/** + * @method html + * + * get the HTML contents of node + * + * @param {jQuery} $node + * @param {Boolean} [isNewlineOnBlock] + */ + + +function dom_html($node, isNewlineOnBlock) { + var markup = dom_value($node); + + if (isNewlineOnBlock) { + var regexTag = /<(\/?)(\b(?!!)[^>\s]*)(.*?)(\s*\/?>)/g; + markup = markup.replace(regexTag, function (match, endSlash, name) { + name = name.toUpperCase(); + var isEndOfInlineContainer = /^DIV|^TD|^TH|^P|^LI|^H[1-7]/.test(name) && !!endSlash; + var isBlockNode = /^BLOCKQUOTE|^TABLE|^TBODY|^TR|^HR|^UL|^OL/.test(name); + return match + (isEndOfInlineContainer || isBlockNode ? '\n' : ''); + }); + markup = markup.trim(); + } + + return markup; +} + +function posFromPlaceholder(placeholder) { + var $placeholder = external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default()(placeholder); + var pos = $placeholder.offset(); + var height = $placeholder.outerHeight(true); // include margin + + return { + left: pos.left, + top: pos.top + height + }; +} + +function attachEvents($node, events) { + Object.keys(events).forEach(function (key) { + $node.on(key, events[key]); + }); +} + +function detachEvents($node, events) { + Object.keys(events).forEach(function (key) { + $node.off(key, events[key]); + }); +} +/** + * @method isCustomStyleTag + * + * assert if a node contains a "note-styletag" class, + * which implies that's a custom-made style tag node + * + * @param {Node} an HTML DOM node + */ + + +function isCustomStyleTag(node) { + return node && !isText(node) && lists.contains(node.classList, 'note-styletag'); +} + +/* harmony default export */ var dom = ({ + /** @property {String} NBSP_CHAR */ + NBSP_CHAR: NBSP_CHAR, + + /** @property {String} ZERO_WIDTH_NBSP_CHAR */ + ZERO_WIDTH_NBSP_CHAR: ZERO_WIDTH_NBSP_CHAR, + + /** @property {String} blank */ + blank: blankHTML, + + /** @property {String} emptyPara */ + emptyPara: "
".concat(blankHTML, "
"), + makePredByNodeName: makePredByNodeName, + isEditable: isEditable, + isControlSizing: isControlSizing, + isText: isText, + isElement: isElement, + isVoid: isVoid, + isPara: isPara, + isPurePara: isPurePara, + isHeading: isHeading, + isInline: dom_isInline, + isBlock: func.not(dom_isInline), + isBodyInline: isBodyInline, + isBody: isBody, + isParaInline: isParaInline, + isPre: isPre, + isList: isList, + isTable: isTable, + isData: isData, + isCell: dom_isCell, + isBlockquote: isBlockquote, + isBodyContainer: isBodyContainer, + isAnchor: isAnchor, + isDiv: makePredByNodeName('DIV'), + isLi: isLi, + isBR: makePredByNodeName('BR'), + isSpan: makePredByNodeName('SPAN'), + isB: makePredByNodeName('B'), + isU: makePredByNodeName('U'), + isS: makePredByNodeName('S'), + isI: makePredByNodeName('I'), + isImg: makePredByNodeName('IMG'), + isTextarea: isTextarea, + deepestChildIsEmpty: deepestChildIsEmpty, + isEmpty: dom_isEmpty, + isEmptyAnchor: func.and(isAnchor, dom_isEmpty), + isClosestSibling: isClosestSibling, + withClosestSiblings: withClosestSiblings, + nodeLength: nodeLength, + isLeftEdgePoint: isLeftEdgePoint, + isRightEdgePoint: isRightEdgePoint, + isEdgePoint: isEdgePoint, + isLeftEdgeOf: dom_isLeftEdgeOf, + isRightEdgeOf: isRightEdgeOf, + isLeftEdgePointOf: isLeftEdgePointOf, + isRightEdgePointOf: isRightEdgePointOf, + prevPoint: dom_prevPoint, + nextPoint: dom_nextPoint, + nextPointWithEmptyNode: nextPointWithEmptyNode, + isSamePoint: isSamePoint, + isVisiblePoint: isVisiblePoint, + prevPointUntil: prevPointUntil, + nextPointUntil: nextPointUntil, + isCharPoint: isCharPoint, + isSpacePoint: isSpacePoint, + walkPoint: walkPoint, + ancestor: dom_ancestor, + singleChildAncestor: singleChildAncestor, + listAncestor: listAncestor, + lastAncestor: lastAncestor, + listNext: listNext, + listPrev: listPrev, + listDescendant: listDescendant, + commonAncestor: dom_commonAncestor, + wrap: wrap, + insertAfter: insertAfter, + appendChildNodes: appendChildNodes, + position: dom_position, + hasChildren: hasChildren, + makeOffsetPath: makeOffsetPath, + fromOffsetPath: fromOffsetPath, + splitTree: splitTree, + splitPoint: splitPoint, + create: dom_create, + createText: createText, + remove: remove, + removeWhile: removeWhile, + replace: dom_replace, + html: dom_html, + value: dom_value, + posFromPlaceholder: posFromPlaceholder, + attachEvents: attachEvents, + detachEvents: detachEvents, + isCustomStyleTag: isCustomStyleTag +}); +// CONCATENATED MODULE: ./src/js/base/Context.js +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } + +function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; } + + + + + + +var Context_Context = /*#__PURE__*/function () { + /** + * @param {jQuery} $note + * @param {Object} options + */ + function Context($note, options) { + _classCallCheck(this, Context); + + this.$note = $note; + this.memos = {}; + this.modules = {}; + this.layoutInfo = {}; + this.options = external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.extend(true, {}, options); // init ui with options + + external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.summernote.ui = external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.summernote.ui_template(this.options); + this.ui = external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.summernote.ui; + this.initialize(); + } + /** + * create layout and initialize modules and other resources + */ + + + _createClass(Context, [{ + key: "initialize", + value: function initialize() { + this.layoutInfo = this.ui.createLayout(this.$note); + + this._initialize(); + + this.$note.hide(); + return this; + } + /** + * destroy modules and other resources and remove layout + */ + + }, { + key: "destroy", + value: function destroy() { + this._destroy(); + + this.$note.removeData('summernote'); + this.ui.removeLayout(this.$note, this.layoutInfo); + } + /** + * destory modules and other resources and initialize it again + */ + + }, { + key: "reset", + value: function reset() { + var disabled = this.isDisabled(); + this.code(dom.emptyPara); + + this._destroy(); + + this._initialize(); + + if (disabled) { + this.disable(); + } + } + }, { + key: "_initialize", + value: function _initialize() { + var _this = this; + + // set own id + this.options.id = func.uniqueId(external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.now()); // set default container for tooltips, popovers, and dialogs + + this.options.container = this.options.container || this.layoutInfo.editor; // add optional buttons + + var buttons = external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.extend({}, this.options.buttons); + Object.keys(buttons).forEach(function (key) { + _this.memo('button.' + key, buttons[key]); + }); + var modules = external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.extend({}, this.options.modules, external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.summernote.plugins || {}); // add and initialize modules + + Object.keys(modules).forEach(function (key) { + _this.module(key, modules[key], true); + }); + Object.keys(this.modules).forEach(function (key) { + _this.initializeModule(key); + }); + } + }, { + key: "_destroy", + value: function _destroy() { + var _this2 = this; + + // destroy modules with reversed order + Object.keys(this.modules).reverse().forEach(function (key) { + _this2.removeModule(key); + }); + Object.keys(this.memos).forEach(function (key) { + _this2.removeMemo(key); + }); // trigger custom onDestroy callback + + this.triggerEvent('destroy', this); + } + }, { + key: "code", + value: function code(html) { + var isActivated = this.invoke('codeview.isActivated'); + + if (html === undefined) { + this.invoke('codeview.sync'); + return isActivated ? this.layoutInfo.codable.val() : this.layoutInfo.editable.html(); + } else { + if (isActivated) { + this.invoke('codeview.sync', html); + } else { + this.layoutInfo.editable.html(html); + } + + this.$note.val(html); + this.triggerEvent('change', html, this.layoutInfo.editable); + } + } + }, { + key: "isDisabled", + value: function isDisabled() { + return this.layoutInfo.editable.attr('contenteditable') === 'false'; + } + }, { + key: "enable", + value: function enable() { + this.layoutInfo.editable.attr('contenteditable', true); + this.invoke('toolbar.activate', true); + this.triggerEvent('disable', false); + this.options.editing = true; + } + }, { + key: "disable", + value: function disable() { + // close codeview if codeview is opend + if (this.invoke('codeview.isActivated')) { + this.invoke('codeview.deactivate'); + } + + this.layoutInfo.editable.attr('contenteditable', false); + this.options.editing = false; + this.invoke('toolbar.deactivate', true); + this.triggerEvent('disable', true); + } + }, { + key: "triggerEvent", + value: function triggerEvent() { + var namespace = lists.head(arguments); + var args = lists.tail(lists.from(arguments)); + var callback = this.options.callbacks[func.namespaceToCamel(namespace, 'on')]; + + if (callback) { + callback.apply(this.$note[0], args); + } + + this.$note.trigger('summernote.' + namespace, args); + } + }, { + key: "initializeModule", + value: function initializeModule(key) { + var module = this.modules[key]; + module.shouldInitialize = module.shouldInitialize || func.ok; + + if (!module.shouldInitialize()) { + return; + } // initialize module + + + if (module.initialize) { + module.initialize(); + } // attach events + + + if (module.events) { + dom.attachEvents(this.$note, module.events); + } + } + }, { + key: "module", + value: function module(key, ModuleClass, withoutIntialize) { + if (arguments.length === 1) { + return this.modules[key]; + } + + this.modules[key] = new ModuleClass(this); + + if (!withoutIntialize) { + this.initializeModule(key); + } + } + }, { + key: "removeModule", + value: function removeModule(key) { + var module = this.modules[key]; + + if (module.shouldInitialize()) { + if (module.events) { + dom.detachEvents(this.$note, module.events); + } + + if (module.destroy) { + module.destroy(); + } + } + + delete this.modules[key]; + } + }, { + key: "memo", + value: function memo(key, obj) { + if (arguments.length === 1) { + return this.memos[key]; + } + + this.memos[key] = obj; + } + }, { + key: "removeMemo", + value: function removeMemo(key) { + if (this.memos[key] && this.memos[key].destroy) { + this.memos[key].destroy(); + } + + delete this.memos[key]; + } + /** + * Some buttons need to change their visual style immediately once they get pressed + */ + + }, { + key: "createInvokeHandlerAndUpdateState", + value: function createInvokeHandlerAndUpdateState(namespace, value) { + var _this3 = this; + + return function (event) { + _this3.createInvokeHandler(namespace, value)(event); + + _this3.invoke('buttons.updateCurrentStyle'); }; - return Renderer; - }()); - var renderer = { - create: function (markup, callback) { - return function () { - var options = typeof arguments[1] === 'object' ? arguments[1] : arguments[0]; - var children = $$1.isArray(arguments[0]) ? arguments[0] : []; - if (options && options.children) { - children = options.children; - } - return new Renderer(markup, children, options, callback); - }; + } + }, { + key: "createInvokeHandler", + value: function createInvokeHandler(namespace, value) { + var _this4 = this; + + return function (event) { + event.preventDefault(); + var $target = external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default()(event.target); + + _this4.invoke(namespace, value || $target.closest('[data-value]').data('value'), $target); + }; + } + }, { + key: "invoke", + value: function invoke() { + var namespace = lists.head(arguments); + var args = lists.tail(lists.from(arguments)); + var splits = namespace.split('.'); + var hasSeparator = splits.length > 1; + var moduleName = hasSeparator && lists.head(splits); + var methodName = hasSeparator ? lists.last(splits) : lists.head(splits); + var module = this.modules[moduleName || 'editor']; + + if (!moduleName && this[methodName]) { + return this[methodName].apply(this, args); + } else if (module && module[methodName] && module.shouldInitialize()) { + return module[methodName].apply(module, args); } + } + }]); + + return Context; +}(); + + +// CONCATENATED MODULE: ./src/js/summernote.js + + + + +external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.fn.extend({ + /** + * Summernote API + * + * @param {Object|String} + * @return {this} + */ + summernote: function summernote() { + var type = external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.type(lists.head(arguments)); + var isExternalAPICalled = type === 'string'; + var hasInitOptions = type === 'object'; + var options = external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.extend({}, external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.summernote.options, hasInitOptions ? lists.head(arguments) : {}); // Update options + + options.langInfo = external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.extend(true, {}, external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.summernote.lang['en-US'], external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.summernote.lang[options.lang]); + options.icons = external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.extend(true, {}, external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default.a.summernote.options.icons, options.icons); + options.tooltip = options.tooltip === 'auto' ? !env.isSupportTouch : options.tooltip; + this.each(function (idx, note) { + var $note = external_root_jQuery_commonjs2_jquery_commonjs_jquery_amd_jquery_default()(note); + + if (!$note.data('summernote')) { + var context = new Context_Context($note, options); + $note.data('summernote', context); + $note.data('summernote').triggerEvent('init', context.layoutInfo); + } + }); + var $note = this.first(); + + if ($note.length) { + var context = $note.data('summernote'); + + if (isExternalAPICalled) { + return context.invoke.apply(context, lists.from(arguments)); + } else if (options.focus) { + context.invoke('editor.focus'); + } + } + + return this; + } +}); +// CONCATENATED MODULE: ./src/js/base/core/range.js +function range_classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function range_defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } + +function range_createClass(Constructor, protoProps, staticProps) { if (protoProps) range_defineProperties(Constructor.prototype, protoProps); if (staticProps) range_defineProperties(Constructor, staticProps); return Constructor; } + + + + + + +/** + * return boundaryPoint from TextRange, inspired by Andy Na's HuskyRange.js + * + * @param {TextRange} textRange + * @param {Boolean} isStart + * @return {BoundaryPoint} + * + * @see http://msdn.microsoft.com/en-us/library/ie/ms535872(v=vs.85).aspx + */ + +function textRangeToPoint(textRange, isStart) { + var container = textRange.parentElement(); + var offset; + var tester = document.body.createTextRange(); + var prevContainer; + var childNodes = lists.from(container.childNodes); + + for (offset = 0; offset < childNodes.length; offset++) { + if (dom.isText(childNodes[offset])) { + continue; + } + + tester.moveToElementText(childNodes[offset]); + + if (tester.compareEndPoints('StartToStart', textRange) >= 0) { + break; + } + + prevContainer = childNodes[offset]; + } + + if (offset !== 0 && dom.isText(childNodes[offset - 1])) { + var textRangeStart = document.body.createTextRange(); + var curTextNode = null; + textRangeStart.moveToElementText(prevContainer || container); + textRangeStart.collapse(!prevContainer); + curTextNode = prevContainer ? prevContainer.nextSibling : container.firstChild; + var pointTester = textRange.duplicate(); + pointTester.setEndPoint('StartToStart', textRangeStart); + var textCount = pointTester.text.replace(/[\r\n]/g, '').length; + + while (textCount > curTextNode.nodeValue.length && curTextNode.nextSibling) { + textCount -= curTextNode.nodeValue.length; + curTextNode = curTextNode.nextSibling; + } // [workaround] enforce IE to re-reference curTextNode, hack + + + var dummy = curTextNode.nodeValue; // eslint-disable-line + + if (isStart && curTextNode.nextSibling && dom.isText(curTextNode.nextSibling) && textCount === curTextNode.nodeValue.length) { + textCount -= curTextNode.nodeValue.length; + curTextNode = curTextNode.nextSibling; + } + + container = curTextNode; + offset = textCount; + } + + return { + cont: container, + offset: offset + }; +} +/** + * return TextRange from boundary point (inspired by google closure-library) + * @param {BoundaryPoint} point + * @return {TextRange} + */ + + +function pointToTextRange(point) { + var textRangeInfo = function textRangeInfo(container, offset) { + var node, isCollapseToStart; + + if (dom.isText(container)) { + var prevTextNodes = dom.listPrev(container, func.not(dom.isText)); + var prevContainer = lists.last(prevTextNodes).previousSibling; + node = prevContainer || container.parentNode; + offset += lists.sum(lists.tail(prevTextNodes), dom.nodeLength); + isCollapseToStart = !prevContainer; + } else { + node = container.childNodes[offset] || container; + + if (dom.isText(node)) { + return textRangeInfo(node, 0); + } + + offset = 0; + isCollapseToStart = false; + } + + return { + node: node, + collapseToStart: isCollapseToStart, + offset: offset + }; }; - var editor = renderer.create(''); - var toolbar = renderer.create(''); - var editingArea = renderer.create(''); - var codable = renderer.create(''); - var editable = renderer.create(''); - var statusbar = renderer.create([ - '', - '' - ].join('')); - var airEditor = renderer.create(''); - var airEditable = renderer.create([ - '', - '' - ].join('')); - var buttonGroup = renderer.create('