/** * Kendo UI v2018.1.117 (http://www.telerik.com/kendo-ui) * Copyright 2018 Telerik AD. All rights reserved. * * Kendo UI commercial licenses may be obtained at * http://www.telerik.com/purchase/license-agreement/kendo-ui-complete * If you do not own a commercial license, this file shall be governed by the trial license terms. */ !function(e,define){define("util/undoredostack.min",["kendo.core.min"],e)}(function(){!function(e){var t=e.Observable.extend({init:function(t){e.Observable.fn.init.call(this,t),this.clear()},events:["undo","redo"],push:function(e){this.stack=this.stack.slice(0,this.currentCommandIndex+1),this.currentCommandIndex=this.stack.push(e)-1},undo:function(){if(this.canUndo()){var e=this.stack[this.currentCommandIndex--];e.undo(),this.trigger("undo",{command:e})}},redo:function(){if(this.canRedo()){var e=this.stack[++this.currentCommandIndex];e.redo(),this.trigger("redo",{command:e})}},clear:function(){this.stack=[],this.currentCommandIndex=-1},canUndo:function(){return this.currentCommandIndex>=0},canRedo:function(){return this.currentCommandIndex!=this.stack.length-1}});e.deepExtend(e,{util:{UndoRedoStack:t}})}(kendo)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("editor/main.min",["util/undoredostack.min","kendo.combobox.min","kendo.dropdownlist.min","kendo.window.min","kendo.colorpicker.min"],e)}(function(){!function(e,t){var n,i,o,r,a=window.kendo,s=a.Class,l=a.ui.Widget,d=a.support.mobileOS,c=a.support.browser,u=e.extend,f=e.proxy,p=a.deepExtend,m=a.keys,h="select",g="select.k-select-overlay",b=s.extend({init:function(e){this.options=e},getHtml:function(){var e=this.options;return a.template(e.template,{useWithBlock:!1})(e)}}),v={editorWrapperTemplate:'',buttonTemplate:'# var iconCssClass= "k-icon k-i-" + kendo.toHyphens(data.cssClass.replace("k-", ""));##= data.title #',colorPickerTemplate:'
',comboBoxTemplate:'',separatorTemplate:'',overflowAnchorTemplate:'',formatByName:function(t,n){for(var i=0;i=0)return n[i]},getToolCssClass:function(e){var t={superscript:"sup-script",subscript:"sub-script",justifyLeft:"align-left",justifyCenter:"align-center",justifyRight:"align-right",justifyFull:"align-justify",insertUnorderedList:"list-unordered",insertOrderedList:"list-ordered","import":"login",indent:"indent-increase",outdent:"indent-decrease",createLink:"link-horizontal",unlink:"unlink-horizontal",insertImage:"image",insertFile:"file-add",viewHtml:"html",foreColor:"foreground-color",backColor:"paint",createTable:"table-insert",addColumnLeft:"table-column-insert-left",addColumnRight:"table-column-insert-right",addRowAbove:"table-row-insert-above",addRowBelow:"table-row-insert-below",deleteRow:"table-row-delete",deleteColumn:"table-column-delete",tableWizard:"table-properties",tableWizardInsert:"table-wizard",cleanFormatting:"clear-css"},n=t[e];return n?n:e},registerTool:function(e,t){var n=t.options;n&&n.template&&(n.template.options.cssClass="k-"+v.getToolCssClass(e)),t.name||(t.options.name=e,t.name=e.toLowerCase()),x.defaultTools[e]=t},registerFormat:function(e,t){x.fn.options.formats[e]=t}},k={bold:"Bold",italic:"Italic",underline:"Underline",strikethrough:"Strikethrough",superscript:"Superscript",subscript:"Subscript",justifyCenter:"Center text",justifyLeft:"Align text left",justifyRight:"Align text right",justifyFull:"Justify",insertUnorderedList:"Insert unordered list",insertOrderedList:"Insert ordered list",indent:"Indent",outdent:"Outdent",createLink:"Insert hyperlink",unlink:"Remove hyperlink",insertImage:"Insert image",insertFile:"Insert file",insertHtml:"Insert HTML",viewHtml:"View HTML",fontName:"Select font family",fontNameInherit:"(inherited font)",fontSize:"Select font size",fontSizeInherit:"(inherited size)",formatBlock:"Format",formatting:"Format",foreColor:"Color",backColor:"Background color",style:"Styles",emptyFolder:"Empty Folder",editAreaTitle:"Editable area. Press F10 for toolbar.",uploadFile:"Upload",overflowAnchor:"More tools",orderBy:"Arrange by:",orderBySize:"Size",orderByName:"Name",invalidFileType:'The selected file "{0}" is not valid. Supported file types are {1}.',deleteFile:'Are you sure you want to delete "{0}"?',overwriteFile:'A file with name "{0}" already exists in the current directory. Do you want to overwrite it?',directoryNotFound:"A directory with this name was not found.",imageWebAddress:"Web address",imageAltText:"Alternate text",imageWidth:"Width (px)",imageHeight:"Height (px)",fileWebAddress:"Web address",fileTitle:"Title",fileText:"Text",linkWebAddress:"Web address",linkText:"Text",linkToolTip:"ToolTip",linkOpenInNewWindow:"Open link in new window",dialogUpdate:"Update",dialogInsert:"Insert",dialogOk:"Ok",dialogCancel:"Cancel",cleanFormatting:"Clean formatting",createTable:"Create a table",createTableHint:"Create a {0} x {1} table",addColumnLeft:"Add column on the left",addColumnRight:"Add column on the right",addRowAbove:"Add row above",addRowBelow:"Add row below",deleteRow:"Delete row",deleteColumn:"Delete column",tableWizard:"Table Wizard",tableTab:"Table",cellTab:"Cell",accessibilityTab:"Accessibility",caption:"Caption",summary:"Summary",width:"Width",height:"Height",units:"Units",cellSpacing:"Cell Spacing",cellPadding:"Cell Padding",cellMargin:"Cell Margin",alignment:"Alignment",background:"Background",cssClass:"CSS Class",id:"ID",border:"Border",borderStyle:"Border Style",collapseBorders:"Collapse borders",wrapText:"Wrap text",associateCellsWithHeaders:"Associate cells with headers",alignLeft:"Align Left",alignCenter:"Align Center",alignRight:"Align Right",alignLeftTop:"Align Left Top",alignCenterTop:"Align Center Top",alignRightTop:"Align Right Top",alignLeftMiddle:"Align Left Middle",alignCenterMiddle:"Align Center Middle",alignRightMiddle:"Align Right Middle",alignLeftBottom:"Align Left Bottom",alignCenterBottom:"Align Center Bottom",alignRightBottom:"Align Right Bottom",alignRemove:"Remove Alignment",columns:"Columns",rows:"Rows",selectAllCells:"Select All Cells",exportAs:"Export As","import":"Import"},y=!d||d.ios&&d.flatVersion>=500||!d.ios&&t!==document.documentElement.contentEditable,w={basic:["bold","italic","underline"],alignment:["justifyLeft","justifyCenter","justifyRight"],lists:["insertUnorderedList","insertOrderedList"],indenting:["indent","outdent"],links:["createLink","unlink"],tables:["tableWizard","createTable","addColumnLeft","addColumnRight","addRowAbove","addRowBelow","deleteRow","deleteColumn"]},x=l.extend({init:function(n,i){var o,r,s,d,c,m=this,h=a.ui.editor,g=h.Dom;y&&(l.fn.init.call(m,n,i),m.options=p({},m.options,i),m.options.tools=m.options.tools.slice(),n=m.element,c=n[0],d=g.name(c),this._registerHandler(n.closest("form"),"submit",f(m.update,m,t)),s=u({},m.options),s.editor=m,"textarea"==d?(m._wrapTextarea(),r=m.wrapper.find(".k-editor-toolbar"),c.id&&r.attr("aria-controls",c.id)):(m.element.attr("contenteditable",!0).addClass("k-widget k-editor k-editor-inline"),s.popup=!0,r=e('"),c=this.isBlock(t),T.focus(),u=T.getRange(),u.deleteContents(),u.startContainer==T.document&&u.selectNodeContents(T.body),f=new s,p=f.addCaret(u),m=this.splittableParent(c,p),h=!1,g=m!=T.body&&!r.is(m,"td"),n.split&&g&&(c||r.isInline(m))&&(u.selectNode(p),o.split(u,m,!0),h=!0),b=this.htmlToFragment(t),b.firstChild&&"k-paste-container"===b.firstChild.className){for(v=[],i=0,a=b.childNodes.length;i"))}if(l=b.childNodes,e(l).filter("table").addClass("k-table").end().find("table").addClass("k-table"),e(l).each(function(e,t){r.isBlock(t)&&""===t.innerHTML&&t.appendChild(T.document.createTextNode("\ufeff"))}),u.insertNode(b),m=this.splittableParent(c,p),h){for(;p.parentNode!=m;)r.unwrap(p.parentNode);r.unwrap(p.parentNode)}if(r.normalize(u.commonAncestorContainer),p.style.display="inline",r.restoreScrollTop(T.document),r.scrollTo(p),f.removeCaret(u),k=u.commonAncestorContainer.parentNode,u.collapsed&&"tbody"==r.name(k)&&(u.setStartAfter(e(k).closest("table")[0]),u.collapse(!0)),y=e(u.commonAncestorContainer.parentNode).closest("table"),y.get(0)){for(w=y.parent().contents(),x=w.length-1,C=w.get(x);null!==C.nodeValue&&(" "===C.nodeValue||""===C.nodeValue);)x-=1,C=w.get(x);C===y.get(0)&&r.insertAfter(r.createEmptyNode(T.document,"p"),y[0])}T.selectRange(u)}}),u=n.extend({init:function(e){this.options=e||{},this.replacements=[]},clean:function(e,t){var n,i,o=this,r=t||o.replacements;for(n=0,i=r.length;n]*)>/i,"<$1telerik:script$2>"]},applicable:function(e){return!this.options.none&&/]*>/i.test(e)}}),p=u.extend({init:function(e){u.fn.init.call(this,e);var t=" ";this.replacements=[/]*>\s*<\/span>/gi,t,/\t/gi,t,/    /gi,t]},applicable:function(e){return/    |class="?Apple-tab-span/i.test(e)}}),m=u.extend({init:function(e){u.fn.init.call(this,e),this.junkReplacements=[/<\?xml[^>]*>/gi,"",//g,"",/"/g,"'",/ <\/o:p>/gi," ",/<\/?(meta|link|style|o:|v:|x:)[^>]*>((?:.|\n)*?<\/(meta|link|style|o:|v:|x:)[^>]*>)?/gi,"",/<\/o>/g,""],this.replacements=this.junkReplacements.concat([/(?:
 [\s\r\n]+|
)*(<\/?(h[1-6]|hr|p|div|table|tbody|thead|tfoot|th|tr|td|li|ol|ul|caption|address|pre|form|blockquote|dl|dt|dd|dir|fieldset)[^>]*>)(?:
 [\s\r\n]+|
)*/g,"$1",/

/g,"

",/
(?!\n)/g," ",/]*)>(\s| )+]*>(\s| )*<\/tr>/gi,"",/]*>(\s| )*<\/tbody>/gi,"",/]*>(\s| )*<\/table>/gi,"",/

/g,"
",/^\s*( )+/gi,"",/( |]*>)+\s*$/gi,"",/mso-[^;"]*;?/gi,"",/<(\/?)b(\s[^>]*)?>/gi,"<$1strong$2>",/<(\/?)font(\s[^>]*)?>/gi,this.convertFontMatch,/<(\/?)i(\s[^>]*)?>/gi,"<$1em$2>",/style=(["|'])\s*\1/g,"",/(]*>)?\n/g,function(e,t){return t?e:" "}])},convertFontMatch:function(e,t,n){var i=/face=['"]([^'"]+)['"]/i,o=i.exec(n),r=n&&o&&o[1];return t?"
":r?'':""},applicable:function(e){return/class="?Mso/i.test(e)||/style="[^"]*mso-/i.test(e)||/urn:schemas-microsoft-com:office/.test(e)},stripEmptyAnchors:function(e){return e.replace(/]*)>\s*<\/a>/gi,function(e,t){return!t||t.indexOf("href")<0?"":e})},listType:function(e,t){var n,i=e.innerHTML,o=r.innerText(e),a=i.match(/^(?:]*texhtml[^>]*>)?]*(?:Symbol|Wingdings)[^>]*>([^<]+)/i),s=a&&a[1],l=/^[a-z\d]/i.test(s),d=function(e){return e.replace(/^(?: |[\u00a0\n\r\s])+/,"")};return a&&(n=!0),i=i.replace(/<\/?\w+[^>]*>/g,"").replace(/ /g," "),!n&&/^[\u2022\u00b7\u00a7\u00d8o]\u00a0+/.test(i)||n&&/^.\u00a0+/.test(i)||s&&!l&&t?{tag:"ul",style:this._guessUnorderedListStyle(d(o))}:/^\s*\w+[\.\)][\u00a0 ]{2,}/.test(i)?{tag:"ol",style:this._guessOrderedListStyle(d(o))}:void 0},_convertToLi:function(e){var t,n=r.name(e);return 1==e.childNodes.length?t=e.firstChild.innerHTML.replace(/^\w+[\.\)]( )+ /,""):(r.remove(e.firstChild),3==e.firstChild.nodeType&&/^[ivxlcdm]+\.$/i.test(e.firstChild.nodeValue)&&r.remove(e.firstChild),/^( |\s)+$/i.test(e.firstChild.innerHTML)&&r.remove(e.firstChild),t="p"!=n?"<"+n+">"+e.innerHTML+"":e.innerHTML),r.remove(e),r.create(document,"li",{innerHTML:t})},_guessUnorderedListStyle:function(e){return/^[\u2022\u00b7\u00FC\u00D8\u002dv-]/.test(e)?null:/^o/.test(e)?"circle":"square"},_guessOrderedListStyle:function(e){var t=null;return/^\d/.test(e)||(t=(/^[a-z]/.test(e)?"lower-":"upper-")+(/^[ivxlcdm]/i.test(e)?"roman":"alpha")),t},extractListLevels:function(e){var n=/style=['"]?[^'"]*?mso-list:\s?[a-zA-Z]+(\d+)\s[a-zA-Z]+(\d+)\s(\w+)/gi;return e=e.replace(n,function(e,n,i){return t.format('data-list="{0}" data-level="{1}" {2}',n,i,e)})},_createList:function(e,t){return r.create(document,e,{style:{listStyleType:t}})},lists:function(t){var n,i,o,a,s,l,d,c,u,f,p,m,h,g,b,v,k=e(t).find(r.blockElements.join(",")),y=-1,w={},x=["p","h1","h2","h3","h4","h5","h6"];for(c=0;cy||!m)&&(m=this._createList(f,b.style),w[p][v]=m,i.appendChild(m)),i=this._convertToLi(u),m.appendChild(i),l?o=y=-1:y=p))},removeAttributes:function(e){for(var t=e.attributes,n=t.length;n--;)"colspan"!=r.name(t[n])&&e.removeAttributeNode(t[n])},createColGroup:function(n){var i=n.cells,o=e(n).closest("table"),r=o.children("colgroup");i.length<2||(r.length&&(i=r.children(),r[0].parentNode.removeChild(r[0])),r=e(e.map(i,function(e){var n=e.width;return n&&0!==parseInt(n,10)?t.format('',n):""}).join("")),r.is("colgroup")||(r=e("").append(r)),r.prependTo(o))},convertHeaders:function(t){var n,i=t.cells,o=e.map(i,function(t){var n=e(t).children("p").children("strong")[0];if(n&&"strong"==r.name(n))return n});if(o.length==i.length){for(n=0;n").end().find("thead").append(t),n=0;no.cells.length&&(o=n[a]);l.createColGroup(o),l.convertHeaders(i),l.removeAttributes(s[r]),l.removeParagraphs(s.eq(r).find("td,th")),l.removeDefaultColors(s.eq(r).find("span"))}},headers:function(t){var n,i=e(t).find("p.MsoTitle");for(n=0;n]*)\s+class="?[^"\s>]*"?/gi,"$1")),e}}),h=u.extend({init:function(e){u.fn.init.call(this,e),this.replacements=[/\s+class="Apple-style-span[^"]*"/gi,"",/<(div|p|h[1-6])\s+style="[^"]*"/gi,"<$1",/^
(.*)<\/div>$/,"$1"]},applicable:function(e){return/class="?Apple-style-span|style="[^"]*-webkit-nbsp-mode/i.test(e)}}),g=u.extend({clean:function(e){var t=r.create(document,"div",{innerHTML:e});return t=this.cleanDom(t),t.innerHTML},cleanDom:function(e){return e}}),b=g.extend({cleanDom:function(t){var n=this.collectTags();return e(t).find(n).each(function(){r.unwrap(this)}),t},collectTags:function(){if(this.options.span)return"span"},applicable:function(){return this.options.span}}),v=g.extend({cleanDom:function(t){var n=this.collectAttr(),i=e(t).find("["+n.join("],[")+"]");return i.removeAttr(n.join(" ")),t},collectAttr:function(){return this.options.css?["class","style"]:[]},applicable:function(){return this.options.css}}),k=function(){this.text="",this.add=function(e){this.text+=e}},y=n.extend({init:function(e){this.separators=e||{text:" ",line:"
"},this.lines=[],this.inlineBlockText=[],this.resetLine()},appendText:function(e){3===e.nodeType&&(e=e.nodeValue),this.textContainer.add(e)},appendInlineBlockText:function(e){this.inlineBlockText.push(e)},flashInlineBlockText:function(){this.inlineBlockText.length&&(this.appendText(this.inlineBlockText.join(" ")),this.inlineBlockText=[])},endLine:function(){this.flashInlineBlockText(),this.resetLine()},html:function(){var e,t,n,i,o,r,a,s,l=this.separators,d="",c=this.lines;for(this.flashInlineBlockText(),e=0,t=c.length,n=t-1;e"}},actions:{ul:e.noop,ol:e.noop,table:e.noop,thead:e.noop,tbody:e.noop,td:function(e,t){var n=new x({all:!0}),i=n.cleanDom(t);return e.htmlLines.appendInlineBlockText(i),!0},block:function(e){e.htmlLines.endLine()}}}),C=u.extend({clean:function(e){return this.options.custom(e)},applicable:function(){return"function"==typeof this.options.custom}});d(i,{Clipboard:c,Cleaner:u,ScriptCleaner:f,TabCleaner:p,MSWordFormatCleaner:m,WebkitFormatCleaner:h,HtmlTagsCleaner:b,HtmlAttrCleaner:v,HtmlContentCleaner:x,HtmlTextLines:y,CustomCleaner:C})}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("editor/plugins/keyboard.min",["editor/command.min"],e)}(function(){!function(e){function t(e,t){return t.startContainer===e&&t.endContainer===e&&0===t.startOffset&&t.endOffset==e.childNodes.length}function n(e,t,n){for(var i=e?e[t]:null;i&&!n(i);)i=i[t];return i}var i=window.kendo,o=i.Class,r=i.ui.editor,a=r.RangeUtils,s=r.Dom,l=r.RestorePoint,d=r.Marker,c=i.support.browser,u='
',f=e.extend,p=s.nodeTypes,m="previousSibling",h="td,th,caption",g="table,tbody,thead,tfoot,tr",b=g+","+h,v=function(t){return!t.collapsed&&e(t.commonAncestorContainer).is(g)},k=o.extend({remove:function(t){var n,i,o,r,l,c,u,f=this,p=new d;p.add(t,!1),n=a.getAll(t,function(t){return e(t).is(b)}),i=a.documentFromRange(t),o=p.start,r=p.end,l=h.split(","),c=s.parentOfType(o,l),u=s.parentOfType(r,l),f._removeContent(o,c,!0),f._removeContent(r,u,!1),e(n).each(function(t,n){n=e(n),(n.is(h)?n:n.find(h)).each(function(e,t){t.innerHTML=""})}),c&&!o.previousSibling&&s.insertBefore(i.createTextNode("\ufeff"),o),u&&!r.nextSibling&&s.insertAfter(i.createTextNode("\ufeff"),r),c?t.setStartBefore(o):n[0]&&(c=e(n[0]),c=c.is(h)?c:c.find(h).first(),c.length&&t.setStart(c.get(0),0)),t.collapse(!0),s.remove(o),s.remove(r)},_removeContent:function(t,n,i){if(n){var o,r=i?"nextSibling":"previousSibling",a=function(t){for(;t&&!t[r];)t=t.parentNode;return t&&e.contains(n,t)?t[r]:null};for(t=a(t);t;)o=a(t),s.remove(t),t=o}}}),y=o.extend({init:function(e){this.editor=e},keydown:function(n){var i,o,a,s,d=this,u=d.editor,p=u.keyboard,m=p.isTypingKey(n),h=f(e.Event(),n);return d.editor.trigger("keydown",h),h.isDefaultPrevented()?(n.preventDefault(),!0):!(h.isDefaultPrevented()||!m||p.isTypingInProgress())&&(i=u.getRange(),o=u.body,d.startRestorePoint=new l(i,o),v(i)&&(a=new k(u),a.remove(i),u.selectRange(i)),c.webkit&&!i.collapsed&&t(o,i)&&(o.innerHTML=""),u.immutables&&r.Immutables.immutablesContext(i)&&(s=new r.BackspaceHandler(u),s.deleteSelection(i)),p.startTyping(function(){d.endRestorePoint=r._finishUpdate(u,d.startRestorePoint)}),!0)},keyup:function(e){var t=this.editor.keyboard;return this.editor.trigger("keyup",e),!!t.isTypingInProgress()&&(t.endTyping(),!0)}}),w=o.extend({init:function(e){this.editor=e},_addCaret:function(e){var t=s.create(this.editor.document,"a");return s.insertAt(e,t,0),s.stripBomNode(t.previousSibling),s.stripBomNode(t.nextSibling),t},_restoreCaret:function(e){var t=this.editor.createRange();!e.nextSibling&&s.isDataNode(e.previousSibling)?t.setStart(e.previousSibling,e.previousSibling.length):t.setStartAfter(e),t.collapse(!0),this.editor.selectRange(t),s.remove(e)},_handleDelete:function(e){var t,n,i=e.endContainer,o=s.closestEditableOfType(i,s.blockElements);return!(!o||!r.RangeUtils.isEndOf(e,o))&&(t=s.next(o),!(!t||"p"!=s.name(t))&&(n=this._addCaret(t),this._merge(o,t),this._restoreCaret(n),!0))},_cleanBomBefore:function(e){for(var t=e.startOffset,n=e.startContainer,i=n.nodeValue,o=0;t-o>=0&&"\ufeff"==i[t-o-1];)o++;o>0&&(n.deleteData(t-o,o),e.setStart(n,Math.max(0,t-o)),e.collapse(!0),this.editor.selectRange(e))},_handleBackspace:function(t){var i,o,a,l,d,c,u,f,p,h,g,b,v,k=t.startContainer,y=s.closestEditableOfType(k,["li"]),w=s.closestEditableOfType(k,"p,h1,h2,h3,h4,h5,h6".split(",")),x=this.editor;if(s.isDataNode(k)){if(t.collapsed&&/^\s[\ufeff]+$/.test(k.nodeValue))return t.setStart(k,0),t.setEnd(k,k.length),x.selectRange(t),!1;this._cleanBomBefore(t)}return i=n(w,m,function(e){return!s.htmlIndentSpace(e)}),t.collapsed&&t.startOffset!==t.endOffset&&t.startOffset<0&&(t.startOffset=0,t.endOffset=0,x.selectRange(t)),o=y&&r.RangeUtils.isStartOf(t,y),a=y&&e(y).index(),l=o&&a>0,l&&(w=y,i=s.prev(y)),w&&i&&s.is(i,"table")&&r.RangeUtils.isStartOf(t,w)?(""===w.innerText&&(w.innerHTML="\ufeff"),!0):w&&i&&r.RangeUtils.isStartOf(t,w)||l?(d=this._addCaret(w),this._merge(i,w),this._restoreCaret(d),!0):o&&0===a?(c=y.firstChild,c||(y.innerHTML=r.emptyElementContent,c=y.firstChild),u=new r.ListFormatter(s.name(y.parentNode),"p"),t.selectNodeContents(y),u.toggle(t),s.insignificant(c)?t.setStartBefore(c):t.setStart(c,0),x.selectRange(t),!0):(f=k.childNodes[t.startOffset-1],p=t,h=f&&s.closestEditableOfType(f,["a"]),g=n(f||k,m,function(e){return!s.isDataNode(e)||!s.isBom(e)&&e.length>0}),(h||(0===t.startOffset||f)&&s.is(g,"a"))&&(h=h||g,p=x.createRange(),p.setStart(h,h.childNodes.length),p.collapse(!0)),h=h||s.closestEditableOfType(f||p.startContainer,["a"]),b=h&&r.RangeUtils.isEndOf(p,h),b&&(v=new r.UnlinkCommand({range:p,body:x.body,immutables:!!x.immutables}),x.execCommand(v),x._selectionChange()),!1)},_handleSelection:function(t){var n,i,o,a,l=t.commonAncestorContainer,c=s.closest(l,"table"),u=r.emptyElementContent,f=this.editor;return v(t)?(n=new k(f),n.remove(t),f.selectRange(t),!0):(i=new d,i.add(t,!1),f.immutables&&this._handleImmutables(i),this._surroundFullySelectedAnchor(i,t),t.setStartAfter(i.start),t.setEndBefore(i.end),o=t.startContainer,a=t.endContainer,t.deleteContents(),c&&""===e(c).text()&&(t.selectNode(c),t.deleteContents()),l=t.commonAncestorContainer,"p"===s.name(l)&&""===l.innerHTML&&(l.innerHTML=u,t.setStart(l,0)),this._join(o,a),s.insertAfter(f.document.createTextNode("\ufeff"),i.start),i.remove(t),o=t.startContainer,"tr"==s.name(o)&&(o=o.childNodes[Math.max(0,t.startOffset-1)],t.setStart(o,s.getNodeLength(o))),t.collapse(!0),f.selectRange(t),!0)},_handleImmutables:function(e){var t=r.Immutables.immutableParent,n=t(e.start),i=t(e.start);n&&s.insertBefore(e.start,n),i&&s.insertAfter(e.end,i),n&&s.remove(n),i&&i.parentNode&&s.remove(i)},_surroundFullySelectedAnchor:function(t,n){var i=t.start,o=e(i).closest("a").get(0),r=t.end,l=e(r).closest("a").get(0);o&&a.isStartOf(n,o)&&s.insertBefore(i,o),l&&a.isEndOf(n,l)&&s.insertAfter(r,l)},_root:function(e){for(;e&&"body"!=s.name(e)&&e.parentNode&&"body"!=s.name(e.parentNode);)e=e.parentNode;return e},_join:function(e,t){e=this._root(e),t=this._root(t),e!=t&&s.is(t,"p")&&this._merge(e,t)},_merge:function(e,t){for(s.removeTrailingBreak(e);e&&t.firstChild;)1==e.nodeType?(e=s.list(e)?e.children[e.children.length-1]:e,e&&e.appendChild(t.firstChild)):e.nodeType===p.TEXT_NODE?this._mergeWithTextNode(e,t.firstChild):e.parentNode.appendChild(t.firstChild);s.remove(t)},_mergeWithTextNode:function(e,t){e&&e.nodeType===p.TEXT_NODE&&(e.nextSibling&&this._isCaret(e.nextSibling)?s.insertAfter(t,e.nextSibling):s.insertAfter(t,e))},_isCaret:function(t){return e(t).is("a")},keydown:function(e){var t,n,o=this.editor,a=o.getRange(),s=e.keyCode,d=i.keys,c=s===d.BACKSPACE,u=s==d.DELETE;o.immutables&&o.immutables.keydown(e,a)||(!c&&!u||a.collapsed?c?t="_handleBackspace":u&&(t="_handleDelete"):t="_handleSelection",t&&(n=new l(a,o.body),this[t](a)&&(e.preventDefault(),r._finishUpdate(o,n))))},deleteSelection:function(e){this._handleSelection(e)},keyup:e.noop}),x=o.extend({init:function(e){this.editor=e,this.systemCommandIsInProgress=!1},createUndoCommand:function(){this.startRestorePoint=this.endRestorePoint=r._finishUpdate(this.editor,this.startRestorePoint)},changed:function(){return!!this.startRestorePoint&&this.startRestorePoint.html!=this.editor.body.innerHTML},keydown:function(e){var t=this,n=t.editor,i=n.keyboard;return i.isModifierKey(e)?(i.isTypingInProgress()&&i.endTyping(!0),t.startRestorePoint=new l(n.getRange(),n.body),!0):!!i.isSystem(e)&&(t.systemCommandIsInProgress=!0,t.changed()&&(t.systemCommandIsInProgress=!1,t.createUndoCommand()),!0)},keyup:function(){var e=this;return!(!e.systemCommandIsInProgress||!e.changed())&&(e.systemCommandIsInProgress=!1,e.createUndoCommand(),!0)}}),C=o.extend({init:function(e){this.editor=e},keydown:function(e){!c.webkit||e.isDefaultPrevented()||!e.ctrlKey||65!=e.keyCode||e.altKey||e.shiftKey||(this.editor.options.immutables&&this._toSelectableImmutables(),this._selectEditorBody())},_selectEditorBody:function(){var e=this.editor,t=e.getRange();t.selectNodeContents(e.body),e.selectRange(t)},_toSelectableImmutables:function(){for(var t=this.editor,n=t.body,i=r.Immutables.immutable,o=s.emptyTextNode,a=n.firstChild,l=n.lastChild;o(a);)a=a.nextSibling;for(;o(l);)l=l.previousSibling;a&&i(a)&&e(u).prependTo(n),l&&i(l)&&e(u).appendTo(n)},keyup:e.noop}),T=o.extend({init:function(e){this.handlers=e,this.typingInProgress=!1},isCharacter:function(e){return e>=48&&e<=90||e>=96&&e<=111||e>=186&&e<=192||e>=219&&e<=222||229==e},toolFromShortcut:function(t,n){var i,o,r=String.fromCharCode(n.keyCode),a=this._getShortcutModifier(n,navigator.platform);for(i in t)if(o=e.extend({ctrl:!1,alt:!1,shift:!1},t[i].options),(o.key==r||o.key==n.keyCode)&&o.ctrl==a&&o.alt==n.altKey&&o.shift==n.shiftKey)return i},_getShortcutModifier:function(e,t){var n=t.toUpperCase().indexOf("MAC")>=0;return n?e.metaKey:e.ctrlKey},toolsFromShortcut:function(t,n){var i,o,r,a=String.fromCharCode(n.keyCode),s=[],l=function(e){return e==a||e==n.keyCode||e==n.charCode};for(i in t)o=e.extend({ctrl:!1,alt:!1,shift:!1},t[i].options),r=e.isArray(o.key)?e.grep(o.key,l).length>0:l(o.key),r&&o.ctrl==n.ctrlKey&&o.alt==n.altKey&&o.shift==n.shiftKey&&s.push(t[i]);return s},isTypingKey:function(e){var t=e.keyCode;return this.isCharacter(t)&&!e.ctrlKey&&!e.altKey||32==t||13==t||8==t||46==t&&!e.shiftKey&&!e.ctrlKey&&!e.altKey},isModifierKey:function(e){var t=e.keyCode;return 17==t&&!e.shiftKey&&!e.altKey||16==t&&!e.ctrlKey&&!e.altKey||18==t&&!e.ctrlKey&&!e.shiftKey},isSystem:function(e){return 46==e.keyCode&&e.ctrlKey&&!e.altKey&&!e.shiftKey},startTyping:function(e){this.onEndTyping=e,this.typingInProgress=!0},stopTyping:function(){this.typingInProgress&&this.onEndTyping&&this.onEndTyping(),this.typingInProgress=!1},endTyping:function(t){var n=this;n.clearTimeout(),t?n.stopTyping():n.timeout=window.setTimeout(e.proxy(n.stopTyping,n),1e3)},isTypingInProgress:function(){return this.typingInProgress},clearTimeout:function(){window.clearTimeout(this.timeout)},notify:function(e,t){var n,i=this.handlers;for(n=0;nt.clientHeight?e.support.scrollbar():0}function o(e,t){return r(e)?p(e):p(e)/t*100}function r(e){return typeof e===w&&k.test(e)}function a(e){return typeof e===w&&y.test(e)}function s(e){return p(e)+b}function l(e){return p(e)+v}var d=window,c=d.Math,u=c.min,f=c.max,p=d.parseFloat,m=e.jQuery,h=m.extend,g=e.ui.editor,b="%",v="px",k=/(\d+)(\.?)(\d*)%/,y=/(\d+)(\.?)(\d*)px/,w="string",x={constrain:n,getScrollBarWidth:i,calculatePercentageRatio:o,inPercentages:r,inPixels:a,toPercentages:s,toPixels:l};h(g,{ResizingUtils:x})}(window.kendo)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("editor/resizing/table-element-resizing.min",["editor/main.min","kendo.resizable.min","editor/resizing/resizing-utils.min"],e)}(function(){!function(e,t){var n=e.jQuery,i=n.extend,o=n.noop,r=n.proxy,a=e.ui.editor,s=e.Class,l="keydown",d="mousedown",c="mouseenter",u="mouseleave",f="mousemove",p="mouseup",m=",",h=".",g=":last-child",b="table",v=s.extend({init:function(e,t){var o=this;o.options=i({},o.options,t),o.options.tags=n.isArray(o.options.tags)?o.options.tags:[o.options.tags],n(e).is(b)&&(o.element=e,o._attachEventHandlers())},destroy:function(){var e=this,t=e.options.eventNamespace;e.element&&(n(e.element).off(t),e.element=null),n(e.options.rootElement).off(l+t),e._destroyResizeHandle()},options:{tags:[],min:0,rootElement:null,eventNamespace:"",rtl:!1,handle:{dataAttribute:"",height:0,width:0,classNames:{},template:""}},_attachEventHandlers:function(){var e=this,t=e.options;n(e.element).on(f+t.eventNamespace,t.tags.join(m),r(e.detectElementBorderHovering,e))},resizingInProgress:function(){var e=this,t=e._resizable;return!!t&&!!t.resizing},resize:o,detectElementBorderHovering:function(e){var t=this,i=t.options,o=i.handle,r=n(e.currentTarget),a=t.resizeHandle,s=o.dataAttribute;t.resizingInProgress()||(!r.is(g)&&t.elementBorderHovered(r,e)?a?a.data(s)&&a.data(s)!==r[0]&&t.showResizeHandle(r,e):t.showResizeHandle(r,e):a&&t._destroyResizeHandle())},elementBorderHovered:o,showResizeHandle:function(e,t){var n=this;0===t.buttons&&(n._initResizeHandle(),n.setResizeHandlePosition(e),n.setResizeHandleDimensions(),n.setResizeHandleDataAttributes(e[0]),n._attachResizeHandleEventHandlers(),n._initResizable(e),n._hideResizeMarker(),n.resizeHandle.show())},_initResizeHandle:function(){var e=this,t=e.options;e._destroyResizeHandle(),e.resizeHandle=n(t.handle.template).appendTo(t.rootElement)},setResizeHandlePosition:o,setResizeHandleDimensions:o,setResizeHandleDataAttributes:function(e){var t=this;t.resizeHandle.data(t.options.handle.dataAttribute,e)},_attachResizeHandleEventHandlers:function(){var e=this,t=e.options,n=t.eventNamespace,i=t.handle.classNames.marker,o=e.resizeHandle;e.resizeHandle.on(d+n,function(){o.find(h+i).show()}).on(p+n,function(){o.find(h+i).hide()})},_hideResizeMarker:function(){var e=this;e.resizeHandle.find(h+e.options.handle.classNames.marker).hide()},_destroyResizeHandle:function(){var e=this;e.resizeHandle&&(e._destroyResizable(),e.resizeHandle.off(e.options.eventNamespace).remove(),e.resizeHandle=null)},_initResizable:function(t){var n=this;n.resizeHandle&&(n._destroyResizable(),n._resizable=new e.ui.Resizable(t,{draggableElement:n.resizeHandle[0],start:r(n.onResizeStart,n),resize:r(n.onResize,n),resizeend:r(n.onResizeEnd,n)}))},_destroyResizable:function(){var e=this;e._resizable&&(e._resizable.destroy(),e._resizable=null)},onResizeStart:function(){this._disableKeyboard()},onResize:function(e){this.setResizeHandleDragPosition(e)},setResizeHandleDragPosition:o,onResizeEnd:function(e){var t=this;t.resize(e),t._destroyResizeHandle(),t._enableKeyboard()},_enableKeyboard:function(){var e=this.options;n(e.rootElement).off(l+e.eventNamespace)},_disableKeyboard:function(){var e=this.options;n(e.rootElement).on(l+e.eventNamespace,function(e){e.preventDefault()})},_forceResizing:function(e){var t=this._resizable;t&&t.userEvents&&t.userEvents._end(e)}}),k=s.extend({create:function(e,t){var i=this,o=t.name,r=t.eventNamespace;n(e.body).on(c+r,b,function(n){var r=n.currentTarget,a=e[o];n.stopPropagation(),a?a.element===r||a.resizingInProgress()||(i._destroyResizing(e,t),i._initResizing(e,r,t)):i._initResizing(e,r,t)}).on(u+r,b,function(r){var a,s=e[o];r.stopPropagation(),!s||s.resizingInProgress()||s.resizeHandle||(a=n(s.element).parents(b)[0],a&&(i._destroyResizing(e,t),i._initResizing(e,a,t)))}).on(u+r,function(){var n=e[o];n&&!n.resizingInProgress()&&i._destroyResizing(e,t)}).on(p+r,function(r){var a,s=e[o];s&&s.resizingInProgress()&&(a=n(r.target).parents(b)[0],a&&(s._forceResizing(r),i._destroyResizing(e,t),i._initResizing(e,a,t)))})},dispose:function(e,t){n(e.body).off(t.eventNamespace)},_initResizing:function(t,n,i){var o=i.name,r=i.type;t[o]=new r(n,{rtl:e.support.isRtl(t.element),rootElement:t.body})},_destroyResizing:function(e,t){var n=t.name;e[n]&&(e[n].destroy(),e[n]=null)}});k.current=new k,v.create=function(e,t){k.current.create(e,t)},v.dispose=function(e,t){k.current.dispose(e,t)},i(a,{TableElementResizing:v})}(window.kendo)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("editor/resizing/column-resizing.min",["editor/main.min","editor/resizing/resizing-utils.min","editor/resizing/table-element-resizing.min"],e)}(function(){!function(e,t){var n=window,i=n.Math,o=i.abs,r=e.jQuery,a=r.extend,s=e.ui.editor,l=s.TableElementResizing,d=s.ResizingUtils,c=d.constrain,u=d.calculatePercentageRatio,f=d.getScrollBarWidth,p=d.inPercentages,m=d.toPercentages,h=d.toPixels,g=e._outerWidth,b=".kendoEditorColumnResizing",v="k-column-resize-handle",k="k-column-resize-marker",y="body",w="tbody",x="td",C="th",T="tr",_=",",N="width",R=l.extend({options:{tags:[x,C],min:20,rootElement:null,eventNamespace:b,rtl:!1,handle:{dataAttribute:"column",width:10,height:0,classNames:{handle:v,marker:k},template:'
'}},elementBorderHovered:function(e,t){var n=this,i=n.options,o=i.handle.width,a=e.offset().left+(i.rtl?0:g(e)),s=t.clientX+r(e[0].ownerDocument).scrollLeft();return s>a-o&&s
'}},elementBorderHovered:function(e,t){var n=this,i=n.options.handle[C],r=e.offset().top+h(e),a=t.clientY+o(e[0].ownerDocument).scrollTop();return a>r-i&&a
"},events:[O,F,L,W,M],show:function(){this._setPosition()},_setPosition:function(){var e=this,t=e._positioningStrategy.getPosition();T(e.element).css({top:t.top,left:t.left,position:"absolute"})},_attachEventHandlers:function(){var e=this;T(e.element).on(W+H,R(e._onMouseOver,e)).on(M+H,R(e._onMouseOut,e))},_onMouseOver:function(){this.trigger(W)},_onMouseOut:function(){this.trigger(M)},_addStyles:function(){var e=this;T(e.element).children(Z+B).addClass("k-resize-"+e.options.direction)},_initPositioningStrategy:function(){var e=this,t=e.options;e._positioningStrategy=n.create({name:t.direction,handle:e.element,resizableElement:t.resizableElement,rootElement:t.rootElement,rtl:t.rtl})},_initDraggable:function(){var e=this,t=e.element;!e._draggable&&t&&(e._draggable=new A(t,{dragstart:R(e._onDragStart,e),drag:R(e._onDrag,e),dragend:R(e._onDragEnd,e)}))},_onDragStart:function(){this.trigger(O)},_onDrag:function(e){var t=this;t.trigger(F,t._draggingStrategy.adjustDragDelta({deltaX:e.x.delta,deltaY:e.y.delta,initialDeltaX:e.x.initialDelta,initialDeltaY:e.y.initialDelta}))},_onDragEnd:function(){this.trigger(L)},_destroyDraggable:function(){var e=this;e._draggable&&(e._draggable.destroy(),e._draggable=null)},_initDraggingStrategy:function(){var e=this;e._draggingStrategy=f.create({name:e.options.direction})}}),te=z.extend({init:function(){this._items=[]},register:function(e,t){this._items.push({name:e,type:t})},create:function(e){var t,n,i,o=this._items,r=o.length,a=e.name?e.name.toLowerCase():"";for(i=0;im?(o=a(d,m),l=r(d,m)):(o=r(d,m),l=a(d,m)),i=y(g(o,l))):i=w(d),c._setColumnsWidth(),u[0].style[L]=i)},_resizeHeight:function(e,t){var i,o,l,d,c=this,u=s(c.element),f=u[0].style[U],p=C(u),m=u.parent(),h=m.height(),k=c._getMaxDimensionValue(U),x=c.options.minHeight,T=c._hasRowsInPixels();0!==e&&(n(c._initialElementHeight)&&(c._initialElementHeight=p),d=b({value:c._initialElementHeight+t,min:x,max:k}),T&&e<0&&c._setRowsHeightInPercentages(),v(f)?(p+e>h?(o=a(d,h),l=r(d,h)):(o=r(d,h),l=a(d,h)),i=y(g(o,l))):i=w(d),u[0].style[U]=i,T&&e<0&&c._setRowsHeightInPixels())},_getMaxDimensionValue:function(e){var t=this,n=s(t.element),i=e.toLowerCase(),o=t.options.rtl?-1:1,r=s(t.element).parent(),a=r[0],l=r[i](),d=o*(e===L?r.scrollLeft():r.scrollTop());return a===n.closest(H)[0]?""!==a.style[i]||v(t.element.style[i])?l+d:1/0:l+d},_setColumnsWidth:function(){function e(e){var t=e.style.width;return""!==t?!!v(t):!!s(e).hasClass(N)}var t,n=this,i=s(n.element),o=i.parent()[0],r=i.closest(H),a=r.closest(B).children(),l=a.length;if(e(i[0])&&o===r[0]&&""===o.style[L])for(t=0;t0)){for(e=0;e0;!n||i===o||l(i,o)||r||e._destroyTableResizing()})},dispose:function(e){s(e.body).off(T)},_initResizing:function(t,n){u.msie||u.mozilla||(t.tableResizing=new X(n,{appendHandlesTo:t.body,rtl:e.support.isRtl(t.element),rootElement:t.body}))}});Y.current=new Y,X.create=function(e){Y.current.create(e)},X.dispose=function(e){Y.current.dispose(e)},d(f,{TableResizing:X})}(window.kendo)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("editor/table-wizard/table-wizard-command.min",["editor/plugins/tables.min"],e)}(function(){!function(e,t){var n=window.kendo,i=n.ui.editor,o=i.EditorUtils,r=i.RangeUtils,a=i.Dom,s=o.registerTool,l=i.ToolTemplate,d=i.Command,c=new i.BlockFormatFinder([{tags:["table"]}]),u=new i.BlockFormatFinder([{tags:["td","th"]}]),f=/([a-z]+|%)$/i,p=d.extend({exec:function(){var o=this,r=o.editor,a=o.range=o.lockRange(),s=o._sourceTable=o.options.insertNewTable?t:o._selectedTable(a),l=o._selectedTableCells=s?o._selectedCells(a):t,d={visible:!1,messages:r.options.messages,closeCallback:e.proxy(o.onDialogClose,o),table:o.parseTable(s,l),dialogOptions:r.options.dialogOptions,isRtl:n.support.isRtl(r.wrapper)},c=new i.TableWizardDialog(d);c.open()},onDialogClose:function(e){var t=this;t.releaseRange(t.range),e&&(t.options.insertNewTable?t.insertTable(t.createNewTable(e)):t.updateTable(e,t._sourceTable,t._selectedTableCells))},releaseRange:function(e){var t=this,n=t.editor.document;a.windowFromDocument(n).focus(),d.fn.releaseRange.call(t,e)},insertTable:function(e){var t=this.range;t.insertNode(e),t.collapse(!0),this.editor.selectRange(t),this._ensureFocusableAfterTable(e)},_ensureFocusableAfterTable:function(t){for(var n=e(t).parent().contents(),i=n.length-1,o=n.get(i);null!==o.nodeValue&&(" "===o.nodeValue||""===o.nodeValue);)i-=1,o=n.get(i);o===t&&a.insertAfter(a.createEmptyNode(this.editor.document,"p"),t)},updateTable:function(t,n,i){for(var o,r,s,l,d,c,u,f,p=this,m=e(n.rows).toArray(),h=t.tableProperties,g=h.rows,b=h.columns,v=function(e){return e[e.length-1]};i.length>1;)i.pop();if(o=i.length?v(i).parentNode:v(m),p._deleteTableRows(m,m.length-g),m.lengthb&&e(m).each(function(e,t){for(;t.cells.length>b;)t.deleteCell(-1)}),m[0].cells.length-1}),!!n.length},_insertCells:function(e,t,n){n=isNaN(n)?-1:n;for(var i,o=0;o",valueTemplate:""},s={dataSource:[{className:"k-icon k-i-table-align-top-left",value:"left top"},{className:"k-icon k-i-table-align-top-center",value:"center top"},{className:"k-icon k-i-table-align-top-right",value:"right top"},{className:"k-icon k-i-table-align-middle-left",value:"left middle"},{className:"k-icon k-i-table-align-middle-center",value:"center middle"},{className:"k-icon k-i-table-align-middle-right",value:"right middle"},{className:"k-icon k-i-table-align-bottom-left",value:"left bottom"},{className:"k-icon k-i-table-align-bottom-center",value:"center bottom"},{className:"k-icon k-i-table-align-bottom-right",value:"right bottom"},{className:"k-icon k-i-align-remove",value:""}],dataTextField:"className",dataValueField:"value",template:"",valueTemplate:""},l={dataSource:[{className:"k-icon k-i-table-align-top-left",value:"left top"},{className:"k-icon k-i-table-align-top-center",value:"center top"},{className:"k-icon k-i-table-align-top-right",value:"right top"},{className:"k-icon k-i-table-align-bottom-left",value:"left bottom"},{className:"k-icon k-i-table-align-bottom-center",value:"center bottom"},{className:"k-icon k-i-table-align-bottom-right",value:"right bottom"},{className:"k-icon k-i-align-remove",value:""}],dataTextField:"className",dataValueField:"value",template:"",valueTemplate:""},d='
  • #= messages.tableTab #
  • #= messages.cellTab #
  • #= messages.accessibilityTab #
 
 
 
',c=n.Class.extend({init:function(e){this.options=e},open:function(){function t(e){e.preventDefault(),l.destroy(),r.destroy()}function i(e){l.collectDialogValues(u),t(e),l.change&&l.change(),d.closeCallback(u)}function o(e){t(e),d.closeCallback(); }var r,a,s,l=this,d=l.options,c=d.dialogOptions,u=d.table,f=d.messages,p=n.support.browser.msie;c.close=o,c.title=f.tableWizard,c.visible=d.visible,r=e(l._dialogTemplate(f)).appendTo(document.body).kendoWindow(c).closest(".k-window").toggleClass("k-rtl",d.isRtl).end().find(".k-dialog-ok").click(i).end().find(".k-dialog-close").click(o).end().data("kendoWindow"),a=r.element,l._initTabStripComponent(a),l._initTableViewComponents(a,u),l._initCellViewComponents(a,u),l._initAccessibilityViewComponents(a,u),r.center(),r.open(),p&&(s=a.closest(".k-window").height(),a.css("max-height",s))},_initTabStripComponent:function(e){var t=this.components={};t.tabStrip=e.find("#k-table-wizard-tabs").kendoTabStrip({animation:!1}).data("kendoTabStrip")},collectDialogValues:function(){var e=this,t=e.options.table;e._collectTableViewValues(t),e._collectCellViewValues(t),e._collectAccessibilityViewValues(t)},_collectTableViewValues:function(e){var t=this.components.tableView,n=e.tableProperties;n.width=t.width.value(),n.widthUnit=t.widthUnit.value(),n.height=t.height.value(),n.columns=t.columns.value(),n.rows=t.rows.value(),n.heightUnit=t.heightUnit.value(),n.cellSpacing=t.cellSpacing.value(),n.cellPadding=t.cellPadding.value(),n.alignment=t.alignment.value(),n.bgColor=t.bgColor.value(),n.className=t.className.value,n.id=t.id.value,n.borderWidth=t.borderWidth.value(),n.borderColor=t.borderColor.value(),n.borderStyle=t.borderStyle.value(),n.collapseBorders=t.collapseBorders.checked},_collectCellViewValues:function(e){var t=e.cellProperties={},n=this.components.cellView;t.selectAllCells=n.selectAllCells.checked,t.width=n.width.value(),t.widthUnit=n.widthUnit.value(),t.height=n.height.value(),t.heightUnit=n.heightUnit.value(),t.cellMargin=n.cellMargin.value(),t.cellPadding=n.cellPadding.value(),t.alignment=n.alignment.value(),t.bgColor=n.bgColor.value(),t.className=n.className.value,t.id=n.id.value,t.borderWidth=n.borderWidth.value(),t.borderColor=n.borderColor.value(),t.borderStyle=n.borderStyle.value(),t.wrapText=n.wrapText.checked,t.width||(t.selectAllCells=!0,t.width=100/e.tableProperties.columns,t.widthUnit="%")},_collectAccessibilityViewValues:function(e){var t=e.tableProperties,n=this.components.accessibilityView;t.captionContent=n.captionContent.value,t.captionAlignment=n.captionAlignment.value(),t.summary=n.summary.value,t.cellsWithHeaders=n.cellsWithHeaders.checked},_addUnit:function(t,n){n&&e.inArray(n,t)==-1&&t.push(n)},_initTableViewComponents:function(e,t){var n=this.components,i=n.tableView={},a=t.tableProperties=t.tableProperties||{};a.borderStyle=a.borderStyle||"",this._addUnit(o,a.widthUnit),this._addUnit(o,a.heightUnit),this._initNumericTextbox(e.find("#k-editor-table-width"),"width",a,i),this._initNumericTextbox(e.find("#k-editor-table-height"),"height",a,i),this._initNumericTextbox(e.find("#k-editor-table-columns"),"columns",a,i,{min:1,value:4}),this._initNumericTextbox(e.find("#k-editor-table-rows"),"rows",a,i,{min:1,value:4}),this._initDropDownList(e.find("#k-editor-table-width-type"),"widthUnit",a,i,o),this._initDropDownList(e.find("#k-editor-table-height-type"),"heightUnit",a,i,o),this._initNumericTextbox(e.find("#k-editor-table-cell-spacing"),"cellSpacing",a,i),this._initNumericTextbox(e.find("#k-editor-table-cell-padding"),"cellPadding",a,i),this._initTableAlignmentDropDown(e.find("#k-editor-table-alignment"),a),this._initColorPicker(e.find("#k-editor-table-bg"),"bgColor",a,i),this._initInput(e.find("#k-editor-css-class"),"className",a,i),this._initInput(e.find("#k-editor-id"),"id",a,i),this._initNumericTextbox(e.find("#k-editor-border-width"),"borderWidth",a,i),this._initColorPicker(e.find("#k-editor-border-color"),"borderColor",a,i),this._initDropDownList(e.find("#k-editor-border-style"),"borderStyle",a,i,r),this._initCheckbox(e.find("#k-editor-collapse-borders"),"collapseBorders",a,i)},_initCellViewComponents:function(e,t){var n,i=this.components,a=i.cellView={};t.selectedCells=t.selectedCells=t.selectedCells||[],n=t.selectedCells[0]||{borderStyle:"",wrapText:!0},this._addUnit(o,n.widthUnit),this._addUnit(o,n.heightUnit),this._initCheckbox(e.find("#k-editor-selectAllCells"),"selectAllCells",t.tableProperties,a),this._initNumericTextbox(e.find("#k-editor-cell-width"),"width",n,a),this._initNumericTextbox(e.find("#k-editor-cell-height"),"height",n,a),this._initDropDownList(e.find("#k-editor-cell-width-type"),"widthUnit",n,a,o),this._initDropDownList(e.find("#k-editor-cell-height-type"),"heightUnit",n,a,o),this._initNumericTextbox(e.find("#k-editor-table-cell-margin"),"cellMargin",n,a),this._initNumericTextbox(e.find("#k-editor-table-cells-padding"),"cellPadding",n,a),this._initCellAlignmentDropDown(e.find("#k-editor-cell-alignment"),n),this._initColorPicker(e.find("#k-editor-cell-bg"),"bgColor",n,a),this._initInput(e.find("#k-editor-cell-css-class"),"className",n,a),this._initInput(e.find("#k-editor-cell-id"),"id",n,a),this._initNumericTextbox(e.find("#k-editor-cell-border-width"),"borderWidth",n,a),this._initColorPicker(e.find("#k-editor-cell-border-color"),"borderColor",n,a),this._initDropDownList(e.find("#k-editor-cell-border-style"),"borderStyle",n,a,r),this._initCheckbox(e.find("#k-editor-wrap-text"),"wrapText",n,a)},_initAccessibilityViewComponents:function(e,t){var n=this.components,i=n.accessibilityView={},o=t.tableProperties;this._initInput(e.find("#k-editor-table-caption"),"captionContent",o,i),this._initAccessibilityAlignmentDropDown(e.find("#k-editor-accessibility-alignment"),o),this._initInput(e.find("#k-editor-accessibility-summary"),"summary",o,i),this._initCheckbox(e.find("#k-editor-cells-headers"),"cellsWithHeaders",o,i)},_initNumericTextbox:function(t,n,o,r,a){var s=r[n]=t.kendoNumericTextBox(a?e.extend({},i,a):i).data("kendoNumericTextBox");n in o&&s.value(parseInt(o[n],10))},_initDropDownList:function(e,t,n,i,o){var r=i[t]=e.kendoDropDownList({dataSource:o}).data("kendoDropDownList");this._setComponentValue(r,n,t)},_initTableAlignmentDropDown:function(e,t){var n=this.options.messages,i=this.components.tableView,o=a.dataSource;o[0].tooltip=n.alignLeft,o[1].tooltip=n.alignCenter,o[2].tooltip=n.alignRight,o[3].tooltip=n.alignRemove,this._initAlignmentDropDown(e,a,"alignment",t,i)},_initCellAlignmentDropDown:function(e,t){var n=this.options.messages,i=this.components.cellView,o=s.dataSource;o[0].tooltip=n.alignLeftTop,o[1].tooltip=n.alignCenterTop,o[2].tooltip=n.alignRightTop,o[3].tooltip=n.alignLeftMiddle,o[4].tooltip=n.alignCenterMiddle,o[5].tooltip=n.alignRightMiddle,o[6].tooltip=n.alignLeftBottom,o[7].tooltip=n.alignCenterBottom,o[8].tooltip=n.alignRightBottom,o[9].tooltip=n.alignRemove,this._initAlignmentDropDown(e,s,"alignment",t,i)},_initAccessibilityAlignmentDropDown:function(e,t){var n=this.options.messages,i=this.components.accessibilityView,o=l.dataSource;o[0].tooltip=n.alignLeftTop,o[1].tooltip=n.alignCenterTop,o[2].tooltip=n.alignRightTop,o[3].tooltip=n.alignLeftBottom,o[4].tooltip=n.alignCenterBottom,o[5].tooltip=n.alignRightBottom,o[6].tooltip=n.alignRemove,this._initAlignmentDropDown(e,l,"captionAlignment",t,i)},_initAlignmentDropDown:function(e,t,n,i,o){var r=o[n]=e.kendoDropDownList(t).data("kendoDropDownList");r.list.addClass("k-align").css("width","110px"),this._setComponentValue(r,i,n)},_setComponentValue:function(e,t,n){n in t&&e.value(t[n])},_initColorPicker:function(e,t,n,i){var o=i[t]=e.kendoColorPicker({buttons:!1,clearButton:!0}).data("kendoColorPicker");n[t]&&o.value(n[t])},_initInput:function(e,t,n,i){var o=i[t]=e.get(0);t in n&&(o.value=n[t])},_initCheckbox:function(e,t,n,i){var o=i[t]=e.get(0);t in n&&(o.checked=n[t])},destroy:function(){this._destroyComponents(this.components.tableView),this._destroyComponents(this.components.cellView),this._destroyComponents(this.components.accessibilityView),this._destroyComponents(this.components),delete this.components},_destroyComponents:function(e){for(var t in e)e[t].destroy&&e[t].destroy(),delete e[t]},_dialogTemplate:function(e){return n.template(d)({messages:e})}});n.ui.editor.TableWizardDialog=c}(window.kendo.jQuery)},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}),function(e,define){define("kendo.editor.min",["kendo.combobox.min","kendo.dropdownlist.min","kendo.resizable.min","kendo.window.min","kendo.colorpicker.min","kendo.imagebrowser.min","kendo.tabstrip.min","kendo.numerictextbox.min","util/undoredostack.min","editor/main.min","editor/dom.min","editor/serializer.min","editor/range.min","editor/command.min","editor/components.min","editor/toolbar.min","editor/immutables.min","editor/plugins/viewhtml.min","editor/plugins/link.min","editor/plugins/lists.min","editor/plugins/formatting.min","editor/plugins/image.min","editor/plugins/import.min","editor/plugins/insert.min","editor/plugins/export.min","editor/plugins/indent.min","editor/plugins/linebreak.min","editor/plugins/format.min","editor/plugins/inlineformat.min","editor/plugins/formatblock.min","editor/plugins/file.min","editor/plugins/tables.min","editor/plugins/clipboard.min","editor/plugins/keyboard.min","editor/plugins/exportpdf.min","editor/plugins/print.min","editor/resizing/column-resizing.min","editor/resizing/row-resizing.min","editor/resizing/table-resizing.min","editor/resizing/table-resize-handle.min","editor/table-wizard/table-wizard-command.min","editor/table-wizard/table-wizard-dialog.min"],e)}(function(){return window.kendo},"function"==typeof define&&define.amd?define:function(e,t,n){(n||t)()}); //# sourceMappingURL=kendo.editor.min.js.map