1 line
177 KiB
JavaScript
1 line
177 KiB
JavaScript
(function(t){function e(e){for(var i,o,c=e[0],s=e[1],l=e[2],u=0,f=[];u<c.length;u++)o=c[u],Object.prototype.hasOwnProperty.call(r,o)&&r[o]&&f.push(r[o][0]),r[o]=0;for(i in s)Object.prototype.hasOwnProperty.call(s,i)&&(t[i]=s[i]);d&&d(e);while(f.length)f.shift()();return a.push.apply(a,l||[]),n()}function n(){for(var t,e=0;e<a.length;e++){for(var n=a[e],i=!0,o=1;o<n.length;o++){var c=n[o];0!==r[c]&&(i=!1)}i&&(a.splice(e--,1),t=s(s.s=n[0]))}return t}var i={},o={app:0},r={app:0},a=[];function c(t){return s.p+"js/"+({}[t]||t)+"."+{"chunk-1d269d2f":"d4765ff2"}[t]+".js"}function s(e){if(i[e])return i[e].exports;var n=i[e]={i:e,l:!1,exports:{}};return t[e].call(n.exports,n,n.exports,s),n.l=!0,n.exports}s.e=function(t){var e=[],n={"chunk-1d269d2f":1};o[t]?e.push(o[t]):0!==o[t]&&n[t]&&e.push(o[t]=new Promise((function(e,n){for(var i="css/"+({}[t]||t)+"."+{"chunk-1d269d2f":"2b737400"}[t]+".css",r=s.p+i,a=document.getElementsByTagName("link"),c=0;c<a.length;c++){var l=a[c],u=l.getAttribute("data-href")||l.getAttribute("href");if("stylesheet"===l.rel&&(u===i||u===r))return e()}var f=document.getElementsByTagName("style");for(c=0;c<f.length;c++){l=f[c],u=l.getAttribute("data-href");if(u===i||u===r)return e()}var d=document.createElement("link");d.rel="stylesheet",d.type="text/css",d.onload=e,d.onerror=function(e){var i=e&&e.target&&e.target.src||r,a=new Error("Loading CSS chunk "+t+" failed.\n("+i+")");a.code="CSS_CHUNK_LOAD_FAILED",a.request=i,delete o[t],d.parentNode.removeChild(d),n(a)},d.href=r;var p=document.getElementsByTagName("head")[0];p.appendChild(d)})).then((function(){o[t]=0})));var i=r[t];if(0!==i)if(i)e.push(i[2]);else{var a=new Promise((function(e,n){i=r[t]=[e,n]}));e.push(i[2]=a);var l,u=document.createElement("script");u.charset="utf-8",u.timeout=120,s.nc&&u.setAttribute("nonce",s.nc),u.src=c(t);var f=new Error;l=function(e){u.onerror=u.onload=null,clearTimeout(d);var n=r[t];if(0!==n){if(n){var i=e&&("load"===e.type?"missing":e.type),o=e&&e.target&&e.target.src;f.message="Loading chunk "+t+" failed.\n("+i+": "+o+")",f.name="ChunkLoadError",f.type=i,f.request=o,n[1](f)}r[t]=void 0}};var d=setTimeout((function(){l({type:"timeout",target:u})}),12e4);u.onerror=u.onload=l,document.head.appendChild(u)}return Promise.all(e)},s.m=t,s.c=i,s.d=function(t,e,n){s.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},s.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},s.t=function(t,e){if(1&e&&(t=s(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(s.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)s.d(n,i,function(e){return t[e]}.bind(null,i));return n},s.n=function(t){var e=t&&t.__esModule?function(){return t["default"]}:function(){return t};return s.d(e,"a",e),e},s.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},s.p="/pampadu-blog/",s.oe=function(t){throw console.error(t),t};var l=window["webpackJsonp"]=window["webpackJsonp"]||[],u=l.push.bind(l);l.push=e,l=l.slice();for(var f=0;f<l.length;f++)e(l[f]);var d=u;a.push([0,"chunk-vendors"]),n()})({0:function(t,e,n){t.exports=n("cd49")},"0030":function(t,e,n){t.exports=n.p+"img/yt.d967c269.svg"},"0d4a":function(t,e,n){"use strict";n("150b")},"12d4":function(t,e,n){(function(t){function e(t){return e="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},e(t)}(function(i){"function"===typeof window.define?window.define.amd?window.define("wangEditor",["jquery"],i):window.define.cmd?window.define((function(t,e,n){return i})):i(window.jQuery):"object"===e(t)&&"object"===e(t.exports)?(n("8193"),t.exports=i(n("1157"))):i(window.jQuery)})((function(t){if(t&&t.fn&&t.fn.jquery){var e=function(e){"string"===typeof e&&(e="#"+e);var n=t(e);if(1===n.length){var i=n[0].nodeName;"TEXTAREA"!==i&&"DIV"!==i||(this.valueNodeName=i.toLowerCase(),this.$valueContainer=n,this.$prev=n.prev(),this.$parent=n.parent(),this.init())}};return e.fn=e.prototype,e.$body=t("body"),e.$document=t(document),e.$window=t(window),e.userAgent=navigator.userAgent,e.getComputedStyle=window.getComputedStyle,e.w3cRange="function"===typeof document.createRange,e.hostname=location.hostname.toLowerCase(),e.websiteHost="",e.isOnWebsite=e.websiteHost.indexOf(e.hostname)>=0,e.docsite="",e.plugin=function(t){e._plugins||(e._plugins=[]),"function"===typeof t&&e._plugins.push(t)},n((function(n){n(e,t)})),e}function n(t){t((function(t,e){t.fn.init=function(){this.initDefaultConfig(),this.addEditorContainer(),this.addTxt(),this.addMenuContainer(),this.menus={},this.commandHooks()}})),t((function(t,e){t.fn.ready=function(t){this.readyFns||(this.readyFns=[]),this.readyFns.push(t)},t.fn.readyHeadler=function(){var t=this.readyFns;while(t.length)t.shift().call(this)},t.fn.updateValue=function(){var t=this,e=t.$valueContainer,n=t.txt.$txt;if(e!==n){var i=n.html();e.val(i)}},t.fn.getInitValue=function(){var t=this,e=t.$valueContainer,n="",i=t.valueNodeName;return"div"===i?n=e.html():"textarea"===i&&(n=e.val()),n},t.fn.updateMenuStyle=function(){var t=this.menus;e.each(t,(function(t,e){e.updateSelected()}))},t.fn.enableMenusExcept=function(t){this._disabled||(t=t||[],"string"===typeof t&&(t=[t]),e.each(this.menus,(function(e,n){t.indexOf(e)>=0||n.disabled(!1)})))},t.fn.disableMenusExcept=function(t){this._disabled||(t=t||[],"string"===typeof t&&(t=[t]),e.each(this.menus,(function(e,n){t.indexOf(e)>=0||n.disabled(!0)})))},t.fn.hideDropPanelAndModal=function(){var t=this.menus;e.each(t,(function(t,e){var n=e.dropPanel||e.dropList||e.modal;n&&n.hide&&n.hide()}))}})),t((function(t,e){var n=!t.w3cRange;function i(){}t.fn.currentRange=function(t){if(!t)return this._rangeData;this._rangeData=t},t.fn.collapseRange=function(t,e){e=e||"end",e="start"===e,t=t||this.currentRange(),t&&(t.collapse(e),this.currentRange(t))},t.fn.getRangeText=n?i:function(t){if(t=t||this.currentRange(),t)return t.toString()},t.fn.getRangeElem=n?i:function(t){t=t||this.currentRange();var e=t.commonAncestorContainer;return 1===e.nodeType?e:e.parentNode},t.fn.isRangeEmpty=n?i:function(t){return t=t||this.currentRange(),!(!t||!t.startContainer||t.startContainer!==t.endContainer||t.startOffset!==t.endOffset)},t.fn.saveSelection=n?i:function(t){var n,i,o=this,r=o.txt.$txt.get(0);t?n=t.commonAncestorContainer:(i=document.getSelection(),i.getRangeAt&&i.rangeCount&&(t=document.getSelection().getRangeAt(0),n=t.commonAncestorContainer)),n&&(e.contains(r,n)||r===n)&&o.currentRange(t)},t.fn.restoreSelection=n?i:function(e){var n;if(e=e||this.currentRange(),e)try{n=document.getSelection(),n.removeAllRanges(),n.addRange(e)}catch(i){t.error("")}},t.fn.restoreSelectionByElem=n?i:function(t,e){t&&(e=e||"end",this.setRangeByElem(t),"start"===e&&this.collapseRange(this.currentRange(),"start"),"end"===e&&this.collapseRange(this.currentRange(),"end"),this.restoreSelection())},t.fn.initSelection=n?i:function(){var t=this;if(!t.currentRange()){var e=t.txt.$txt,n=e.children().first();n.length&&t.restoreSelectionByElem(n.get(0))}},t.fn.setRangeByElem=n?i:function(t){var n=this,i=n.txt.$txt.get(0);if(t&&e.contains(i,t)){var o=t.firstChild;while(o){if(3===o.nodeType)break;o=o.firstChild}var r=t.lastChild;while(r){if(3===r.nodeType)break;r=r.lastChild}var a=document.createRange();o&&r?(a.setStart(o,0),a.setEnd(r,r.textContent.length)):(a.setStart(t,0),a.setEnd(t,0)),n.saveSelection(a)}}})),t((function(t,e){t.w3cRange||(t.fn.getRangeText=function(t){if(t=t||this.currentRange(),t)return t.text},t.fn.getRangeElem=function(t){if(t=t||this.currentRange(),t){var e=t.parentElement();return 1===e.nodeType?e:e.parentNode}},t.fn.isRangeEmpty=function(t){return t=t||this.currentRange(),!t||!t.text},t.fn.saveSelection=function(t){var n,i=this,o=i.txt.$txt.get(0);t?n=t.parentElement():(t=document.selection.createRange(),n="undefined"===typeof t.parentElement?null:t.parentElement()),n&&(e.contains(o,n)||o===n)&&i.currentRange(t)},t.fn.restoreSelection=function(t){var e,n=this;if(t=t||n.currentRange(),t){e=document.selection.createRange();try{e.setEndPoint("EndToEnd",t)}catch(i){}if(0===t.text.length)try{e.collapse(!1)}catch(i){}else e.setEndPoint("StartToStart",t);e.select()}})})),t((function(t,e){t.fn.commandHooks=function(){var t=this,n={insertHtml:function(n){var i,o=e(n),r=t.getRangeElem();i=t.getLegalTags(r),i&&e(i).after(o)}};t.commandHooks=n}})),t((function(t,e){t.fn.command=function(t,e,n,i){var o,r=this;function a(){e&&(r.queryCommandSupported(e)?document.execCommand(e,!1,n):(o=r.commandHooks,e in o&&o[e](n)))}this.customCommand(t,a,i)},t.fn.commandForElem=function(t,e,n,i,o){var r,a;"string"===typeof t?r=t:(r=t.selector,a=t.check);var c=this.getRangeElem();c=this.getSelfOrParentByName(c,r,a),c&&this.setRangeByElem(c),this.command(e,n,i,o)},t.fn.customCommand=function(t,e,n){var i=this,o=i.currentRange();function r(){i.hideDropPanelAndModal()}o?(i.undoRecord(),this.restoreSelection(o),e.call(i),this.saveSelection(),this.restoreSelection(),n&&"function"===typeof n&&n.call(i),i.txt.insertEmptyP(),i.txt.wrapImgAndText(),i.updateValue(),i.updateMenuStyle(),setTimeout(r,200),t&&t.preventDefault()):t&&t.preventDefault()},t.fn.queryCommandValue=function(t){var e="";try{e=document.queryCommandValue(t)}catch(n){}return e},t.fn.queryCommandState=function(t){var e=!1;try{e=document.queryCommandState(t)}catch(n){}return e},t.fn.queryCommandSupported=function(t){var e=!1;try{e=document.queryCommandSupported(t)}catch(n){}return e}})),t((function(t,e){var n;function i(t){var n=this,i=e(t),o=!1;return i.each((function(){if(this===n)return o=!0,!1})),o}t.fn.getLegalTags=function(e){var n=this.config.legalTags;if(n)return this.getSelfOrParentByName(e,n);t.error("")},t.fn.getSelfOrParentByName=function(t,o,r){if(t&&o){n||(n=t.webkitMatchesSelector||t.mozMatchesSelector||t.oMatchesSelector||t.matchesSelector),n||(n=i);var a=this.txt.$txt.get(0);while(t&&a!==t&&e.contains(a,t)){if(n.call(t,o)){if(!r)return t;if(r(t))return t}t=t.parentNode}}}})),t((function(t,e){var n=20;function i(t){return null==t._redoList&&(t._redoList=[]),t._redoList}function o(t){return null==t._undoList&&(t._undoList=[]),t._undoList}function r(t,e,n){var i=e.val,o=t.txt.$txt.html();if(null!=i){if(i===o)return"redo"===n?void t.redo():"undo"===n?void t.undo():void 0;t.txt.$txt.html(i),t.updateValue(),t.onchange&&"function"===typeof t.onchange&&t.onchange.call(t)}}t.fn.undoRecord=function(){var t=this,e=t.txt.$txt,r=e.html(),a=o(t),c=i(t),s=a.length?a[0]:"";r!==s.val&&(c.length&&(c=[]),a.unshift({range:t.currentRange(),val:r}),a.length>n&&a.pop())},t.fn.undo=function(){var t=this,e=o(t),n=i(t);if(e.length){var a=e.shift();n.unshift(a),r(this,a,"undo")}},t.fn.redo=function(){var t=this,e=o(t),n=i(t);if(n.length){var a=n.shift();e.unshift(a),r(this,a,"redo")}}})),t((function(t,e){t.fn.create=function(){var n=this;t.$body&&0!==t.$body.length||(t.$body=e("body"),t.$document=e(document),t.$window=e(window)),n.addMenus(),n.renderMenus(),n.renderMenuContainer(),n.renderTxt(),n.renderEditorContainer(),n.eventMenus(),n.eventMenuContainer(),n.eventTxt(),n.readyHeadler(),n.initSelection(),n.$txt=n.txt.$txt;var i=t._plugins;i&&i.length&&e.each(i,(function(t,e){e.call(n)}))},t.fn.disable=function(){this.txt.$txt.removeAttr("contenteditable"),this.disableMenusExcept(),this._disabled=!0},t.fn.enable=function(){this._disabled=!1,this.txt.$txt.attr("contenteditable","true"),this.enableMenusExcept()},t.fn.destroy=function(){var t=this,e=t.$valueContainer,n=t.$editorContainer,i=t.valueNodeName;"div"===i?(e.removeAttr("contenteditable"),n.after(e),n.hide()):(e.show(),n.hide())},t.fn.undestroy=function(){var t=this,e=t.$valueContainer,n=t.$editorContainer,i=t.menuContainer.$menuContainer,o=t.valueNodeName;"div"===o?(e.attr("contenteditable","true"),i.after(e),n.show()):(e.hide(),n.show())},t.fn.clear=function(){var t=this,e=t.txt.$txt;e.html("<p><br></p>"),t.restoreSelectionByElem(e.find("p").get(0))}})),t((function(t,e){var n=function(t){this.editor=t,this.init()};n.fn=n.prototype,t.MenuContainer=n})),t((function(t,e){var n=t.MenuContainer;n.fn.init=function(){var t=this,n=e('<div class="wangEditor-menu-container"></div>');t.$menuContainer=n,t.changeShadow()},n.fn.changeShadow=function(){var t=this.$menuContainer,e=this.editor,n=e.txt.$txt;n.on("scroll",(function(){n.scrollTop()>10?t.addClass("wangEditor-menu-shadow"):t.removeClass("wangEditor-menu-shadow")}))}})),t((function(t,e){var n=t.MenuContainer;n.fn.render=function(){var t=this.$menuContainer,e=this.editor.$editorContainer;e.append(t)},n.fn.height=function(){var t=this.$menuContainer;return t.height()},n.fn.appendMenu=function(t,e){return this._addGroup(t),this._addOneMenu(e)},n.fn._addGroup=function(t){var n,i=this.$menuContainer;this.$currentGroup&&this.currentGroupIdx===t||(n=e('<div class="menu-group"></div>'),i.append(n),this.$currentGroup=n,this.currentGroupIdx=t)},n.fn._addOneMenu=function(t){var n=t.$domNormal,i=t.$domSelected,o=this.$currentGroup,r=e('<div class="menu-item"></div>');return i.hide(),r.append(n).append(i),o.append(r),r}})),t((function(t,e){var n=function(t){this.editor=t.editor,this.id=t.id,this.title=t.title,this.$domNormal=t.$domNormal,this.$domSelected=t.$domSelected||t.$domNormal,this.commandName=t.commandName,this.commandValue=t.commandValue,this.commandNameSelected=t.commandNameSelected||t.commandName,this.commandValueSelected=t.commandValueSelected||t.commandValue};n.fn=n.prototype,t.Menu=n})),t((function(t,e){var n=t.Menu;n.fn.initUI=function(){var n=this.editor,i=n.UI.menus,o=this.id,r=i[o];this.$domNormal&&this.$domSelected||(null==r&&(t.warn(o),r=i["default"]),this.$domNormal=e(r.normal),/^\./.test(r.selected)?this.$domSelected=this.$domNormal.clone().addClass(r.selected.slice(1)):this.$domSelected=e(r.selected))}})),t((function(t,e){var n=t.Menu;n.fn.render=function(t){this.initUI();var e=this.editor,n=e.menuContainer,i=n.appendMenu(t,this),o=this.onRender;this._renderTip(i),o&&"function"===typeof o&&o.call(this)},n.fn._renderTip=function(n){var i,o,r=this,a=r.editor,c=r.title,s=e('<div class="menu-tip"></div>');function l(){s.show()}function u(){s.hide()}r.tipWidth||(i=e('<p style="opacity:0; filter:Alpha(opacity=0); position:absolute;top:-10000px;">'+c+"</p>"),t.$body.append(i),a.ready((function(){var t=i.outerWidth()+5,e=s.outerWidth(),n=parseFloat(s.css("margin-left"),10);i.remove(),i=null,s.css({width:t,"margin-left":n+(e-t)/2}),r.tipWidth=t}))),s.append(c),n.append(s),n.find("a").on("mouseenter",(function(t){r.active()||r.disabled()||(o=setTimeout(l,200))})).on("mouseleave",(function(t){o&&clearTimeout(o),u()})).on("click",u)},n.fn.bindEvent=function(){var e=this,n=e.$domNormal,i=e.$domSelected,o=e.clickEvent;o||(o=function(n){var i=e.dropPanel||e.dropList||e.modal;if(i&&i.show)i.isShowing?i.hide():i.show();else{var o,r,a=e.editor,c=e.selected;c?(o=e.commandNameSelected,r=e.commandValueSelected):(o=e.commandName,r=e.commandValue),o?a.command(n,o,r):(t.warn(e.id),n.preventDefault())}});var r=e.clickEventSelected||o;n.click((function(t){e.disabled()||(o.call(e,t),e.updateSelected()),t.preventDefault()})),i.click((function(t){e.disabled()||(r.call(e,t),e.updateSelected()),t.preventDefault()}))},n.fn.updateSelected=function(){var t=this,e=(t.editor,t.updateSelectedEvent);e||(e=function(){var t=this,e=t.editor,n=t.commandName,i=t.commandValue;if(i){if(e.queryCommandValue(n).toLowerCase()===i.toLowerCase())return!0}else if(e.queryCommandState(n))return!0;return!1});var n=e.call(t);n=!!n,t.changeSelectedState(n)},n.fn.changeSelectedState=function(t){var e=this,n=e.selected;if(null!=t&&"boolean"===typeof t){if(n===t)return;e.selected=t,t?(e.$domNormal.hide(),e.$domSelected.show()):(e.$domNormal.show(),e.$domSelected.hide())}},n.fn.active=function(t){if(null==t)return this._activeState;this._activeState=t},n.fn.activeStyle=function(t){this.selected;var e=this.$domNormal,n=this.$domSelected;t?(e.addClass("active"),n.addClass("active")):(e.removeClass("active"),n.removeClass("active")),this.active(t)},n.fn.disabled=function(t){if(null==t)return!!this._disabled;if(this._disabled!==t){var e=this.$domNormal,n=this.$domSelected;t?(e.addClass("disable"),n.addClass("disable")):(e.removeClass("disable"),n.removeClass("disable")),this._disabled=t}}})),t((function(t,e){var n=function(t,e,n){this.editor=t,this.menu=e,this.data=n.data,this.tpl=n.tpl,this.selectorForELemCommand=n.selectorForELemCommand,this.beforeEvent=n.beforeEvent,this.afterEvent=n.afterEvent,this.init()};n.fn=n.prototype,t.DropList=n})),t((function(t,e){var n=t.DropList;n.fn.init=function(){var t=this;t.initDOM(),t.bindEvent(),t.initHideEvent()},n.fn.initDOM=function(){var t,n,i=this,o=i.data,r=i.tpl||"<span>{#title}</span>",a=e('<div class="wangEditor-drop-list"></div>');e.each(o,(function(i,o){t=r.replace(/{#commandValue}/gi,i).replace(/{#title}/gi,o),n=e('<a href="#" commandValue="'+i+'"></a>'),n.append(t),a.append(n)})),i.$list=a},n.fn.bindEvent=function(){var t=this,n=t.editor,i=t.menu,o=i.commandName,r=t.selectorForELemCommand,a=t.$list,c=t.beforeEvent,s=t.afterEvent;a.on("click","a[commandValue]",(function(t){c&&"function"===typeof c&&c.call(t);var a=e(t.currentTarget).attr("commandValue");i.selected&&n.isRangeEmpty()&&r?n.commandForElem(r,t,o,a):n.command(t,o,a),s&&"function"===typeof s&&s.call(t)}))},n.fn.initHideEvent=function(){var n=this,i=n.$list.get(0);t.$body.on("click",(function(t){if(n.isShowing){var o,r=t.target,a=n.menu;o=a.selected?a.$domSelected.get(0):a.$domNormal.get(0),o===r||e.contains(o,r)||i===r||e.contains(i,r)||n.hide()}})),t.$window.scroll((function(){n.hide()})),t.$window.on("resize",(function(){n.hide()}))}})),t((function(t,e){var n=t.DropList;n.fn._render=function(){var t=this,e=t.editor,n=t.$list;e.$editorContainer.append(n),t.rendered=!0},n.fn._position=function(){var t=this,e=t.$list,n=t.editor,i=t.menu,o=n.menuContainer.$menuContainer,r=i.selected?i.$domSelected:i.$domNormal,a=r.offsetParent().position(),c=a.top,s=a.left,l=r.offsetParent().height(),u=r.offsetParent().width(),f=e.outerWidth(),d=n.txt.$txt.outerWidth(),p=c+l,m=s+u/2,h=0-u/2,g=m+f-d;g>-10&&(h=h-g-10),e.css({top:p,left:m,"margin-left":h}),n._isMenufixed&&(p+=o.offset().top+o.outerHeight()-e.offset().top,e.css({top:p}))},n.fn.show=function(){var t=this,e=t.menu;if(t.rendered||t._render(),!t.isShowing){var n=t.$list;n.show(),t._position(),t.isShowing=!0,e.activeStyle(!0)}},n.fn.hide=function(){var t=this,e=t.menu;if(t.isShowing){var n=t.$list;n.hide(),t.isShowing=!1,e.activeStyle(!1)}}})),t((function(t,e){var n=function(t,e,n){this.editor=t,this.menu=e,this.$content=n.$content,this.width=n.width||200,this.height=n.height,this.onRender=n.onRender,this.init()};n.fn=n.prototype,t.DropPanel=n})),t((function(t,e){var n=t.DropPanel;n.fn.init=function(){var t=this;t.initDOM(),t.initHideEvent()},n.fn.initDOM=function(){var t=this,n=t.$content,i=t.width,o=t.height,r=e('<div class="wangEditor-drop-panel"></div>'),a=e('<div class="tip-triangle"></div>');r.css({width:i,height:o||"auto"}),r.append(a),r.append(n),t.$panel=r,t.$triangle=a},n.fn.initHideEvent=function(){var n=this,i=n.$panel.get(0);t.$body.on("click",(function(t){if(n.isShowing){var o,r=t.target,a=n.menu;o=a.selected?a.$domSelected.get(0):a.$domNormal.get(0),o===r||e.contains(o,r)||i===r||e.contains(i,r)||n.hide()}})),t.$window.scroll((function(t){n.hide()})),t.$window.on("resize",(function(){n.hide()}))}})),t((function(t,e){var n=t.DropPanel;n.fn._render=function(){var t=this,e=t.onRender,n=t.editor,i=t.$panel;n.$editorContainer.append(i),e&&e.call(t),t.rendered=!0},n.fn._position=function(){var t=this,e=t.$panel,n=t.$triangle,i=t.editor,o=i.menuContainer.$menuContainer,r=t.menu,a=r.selected?r.$domSelected:r.$domNormal,c=a.offsetParent().position(),s=c.top,l=c.left,u=a.offsetParent().height(),f=a.offsetParent().width(),d=e.outerWidth(),p=i.txt.$txt.outerWidth(),m=s+u,h=l+f/2,g=0-d/2,v=g;0-g>h-10&&(g=0-(h-10));var y=h+d+g-p;y>-10&&(g=g-y-10),e.css({top:m,left:h,"margin-left":g}),i._isMenufixed&&(m+=o.offset().top+o.outerHeight()-e.offset().top,e.css({top:m})),n.css({"margin-left":v-g-5})},n.fn.focusFirstInput=function(){var t=this,n=t.$panel;n.find("input[type=text],textarea").each((function(){var t=e(this);if(null==t.attr("disabled"))return t.focus(),!1}))},n.fn.show=function(){var e=this,n=e.menu;if(e.rendered||e._render(),!e.isShowing){var i=e.$panel;i.show(),e._position(),e.isShowing=!0,n.activeStyle(!0),t.w3cRange?e.focusFirstInput():t.placeholderForIE8(i)}},n.fn.hide=function(){var t=this,e=t.menu;if(t.isShowing){var n=t.$panel;n.hide(),t.isShowing=!1,e.activeStyle(!1)}}})),t((function(t,e){var n=function(t,e,n){this.editor=t,this.menu=e,this.$content=n.$content,this.init()};n.fn=n.prototype,t.Modal=n})),t((function(t,e){var n=t.Modal;n.fn.init=function(){var t=this;t.initDom(),t.initHideEvent()},n.fn.initDom=function(){var t=this,n=t.$content,i=e('<div class="wangEditor-modal"></div>'),o=e('<div class="wangEditor-modal-close"><i class="wangeditor-menu-img-cancel-circle"></i></div>');i.append(o),i.append(n),t.$modal=i,t.$close=o},n.fn.initHideEvent=function(){var n=this,i=n.$close,o=n.$modal.get(0);i.click((function(){n.hide()})),t.$body.on("click",(function(t){if(n.isShowing){var i,r=t.target,a=n.menu;a&&(i=a.selected?a.$domSelected.get(0):a.$domNormal.get(0),i===r||e.contains(i,r))||o===r||e.contains(o,r)||n.hide()}}))}})),t((function(t,e){var n=t.Modal;n.fn._render=function(){var e=this,n=e.editor,i=e.$modal;i.css("z-index",n.config.zindex+10+""),t.$body.append(i),e.rendered=!0},n.fn._position=function(){var e=this,n=e.$modal,i=n.offset().top,o=n.outerWidth(),r=n.outerHeight(),a=0-o/2,c=0-r/2,s=t.$window.scrollTop();r/2>i&&(c=0-i),n.css({"margin-left":a+"px","margin-top":c+s+"px"})},n.fn.show=function(){var t=this,e=t.menu;if(t.rendered||t._render(),!t.isShowing){t.isShowing=!0;var n=t.$modal;n.show(),t._position(),e&&e.activeStyle(!0)}},n.fn.hide=function(){var t=this,e=t.menu;if(t.isShowing){t.isShowing=!1;var n=t.$modal;n.hide(),e&&e.activeStyle(!1)}}})),t((function(t,e){var n=function(t){this.editor=t,this.init()};n.fn=n.prototype,t.Txt=n})),t((function(t,e){var n=t.Txt;n.fn.init=function(){var t,n=this,i=n.editor,o=i.$valueContainer,r=i.getInitValue();"DIV"===o.get(0).nodeName?(t=o,t.addClass("wangEditor-txt"),t.attr("contentEditable","true")):t=e('<div class="wangEditor-txt" contentEditable="true">'+r+"</div>"),i.ready((function(){n.insertEmptyP()})),n.$txt=t,n.contentEmptyHandle(),n.bindEnterForDiv(),n.bindEnterForText(),n.bindTabEvent(),n.bindPasteFilter(),n.bindFormatText(),n.bindHtml()},n.fn.contentEmptyHandle=function(){var t,n=this,i=n.editor,o=n.$txt;o.on("keydown",(function(t){if(8===t.keyCode){var n=e.trim(o.html().toLowerCase());"<p><br></p>"!==n||t.preventDefault()}})),o.on("keyup",(function(n){if(8===n.keyCode){var r=e.trim(o.html().toLowerCase());r&&"<br>"!==r||(t=e("<p><br/></p>"),o.html(""),o.append(t),i.restoreSelectionByElem(t.get(0)))}}))},n.fn.bindEnterForDiv=function(){t.config.legalTags;var n,i=this,o=i.editor,r=i.$txt;function a(){if(n){var t=e("<p>"+n.html()+"</p>");n.after(t),n.remove()}}r.on("keydown keyup",(function(t){if(13===t.keyCode){var i,r,c=o.getRangeElem(),s=o.getLegalTags(c);if(!s){if(s=o.getSelfOrParentByName(c,"div"),!s)return;i=e(s),"keydown"===t.type&&(n=i,setTimeout(a,0)),"keyup"===t.type&&(r=e("<p>"+i.html()+"</p>"),i.after(r),i.remove(),o.restoreSelectionByElem(r.get(0),"start"))}}}))},n.fn.bindEnterForText=function(){var t,e=this,n=e.$txt;n.on("keyup",(function(n){13===n.keyCode&&(t||(t=function(){e.wrapImgAndText()}),setTimeout(t))}))},n.fn.bindTabEvent=function(){var t=this,e=t.editor,n=t.$txt;n.on("keydown",(function(t){9===t.keyCode&&e.queryCommandSupported("insertHtml")&&e.command(t,"insertHtml"," ")}))},n.fn.bindPasteFilter=function(){var t=this,n=t.editor,i="",o=t.$txt,r=n.config.legalTags,a=r.split(",");function c(t){if(t&&t.nodeType&&t.nodeName){var n,o,r=t.nodeName.toLowerCase(),u=t.nodeType;if(3===u||1===u){if(n=e(t),"div"===r)return o=[],e.each(t.childNodes,(function(t,e){o.push(e)})),void e.each(o,(function(){c(this)}));if(a.indexOf(r)>=0)i+=s(t);else if(3===u)i+="<p>"+t.textContent+"</p>";else if("br"===r)i+="<br/>";else{if(["meta","style","script","object","form","iframe","hr"].indexOf(r)>=0)return;n=e(l(t)),i+=e("<div>").append(n.clone()).html()}}}}function s(t){var n,i=t.nodeName.toLowerCase(),o="",r="";return["blockquote"].indexOf(i)>=0?(n=e(t),"<"+i+">"+n.text()+"</"+i+">"):["p","h1","h2","h3","h4","h5"].indexOf(i)>=0?(t=l(t),n=e(t),o=n.html(),o=o.replace(/<.*?>/gi,(function(t){return"</a>"===t||0===t.indexOf("<a ")||0===t.indexOf("<img ")?t:""})),"<"+i+">"+o+"</"+i+">"):["ul","ol"].indexOf(i)>=0?(n=e(t),n.children().each((function(){var t=e(l(this)),n=t.html();n=n.replace(/<.*?>/gi,(function(t){return"</a>"===t||0===t.indexOf("<a ")||0===t.indexOf("<img ")?t:""})),r+="<li>"+n+"</li>"})),"<"+i+">"+r+"</"+i+">"):(n=e(l(t)),e("<div>").append(n).html())}function l(t){var n=t.attributes||[],i=[],o=["href","target","src","alt","rowspan","colspan"];e.each(n,(function(t,e){e&&2===e.nodeType&&i.push(e.nodeName)})),e.each(i,(function(e,n){o.indexOf(n)<0&&t.removeAttribute(n)}));var r=t.childNodes;return r.length&&e.each(r,(function(t,e){l(e)})),t}o.on("paste",(function(o){if(n.config.pasteFilter){var r=n.getRangeElem().nodeName;if("TD"!==r&&"TH"!==r){var a,s,l;i="";var u=o.clipboardData||o.originalEvent.clipboardData,f=window.clipboardData;if(n.config.pasteText){if(u&&u.getData)a=u.getData("text/plain");else{if(!f||!f.getData)return;a=f.getData("text")}a&&(i="<p>"+a+"</p>")}else if(u&&u.getData)a=u.getData("text/html"),l=a.split("</html>"),2===l.length&&(a=l[0]),a?(s=e("<div>"+a+"</div>"),c(s.get(0))):(a=u.getData("text/plain"),a&&(a=a.replace(/[ ]/g," ").replace(/</g,"<").replace(/>/g,">").replace(/\n/g,"</p><p>"),i="<p>"+a+"</p>",i=i.replace(/<p>(https?:\/\/.*?)<\/p>/gi,(function(t,e){return'<p><a href="'+e+'" target="_blank">'+e+"</p>"}))));else{if(!f||!f.getData)return;if(i=f.getData("text"),!i)return;i="<p>"+i+"</p>",i=i.replace(new RegExp("\n","g"),"</p><p>")}i&&(n.command(o,"insertHtml",i),t.clearEmptyOrNestP())}}}))},n.fn.bindFormatText=function(){var n=this,i=(n.editor,n.$txt),o=t.config.legalTags,r=o.split(","),a=(r.length,[]);e.each(r,(function(t,e){var n=">\\s*<("+e+")>";a.push(new RegExp(n,"ig"))})),a.push(new RegExp(">\\s*<(li)>","ig")),a.push(new RegExp(">\\s*<(tr)>","ig")),a.push(new RegExp(">\\s*<(code)>","ig")),i.formatText=function(){var t=e("<div>"),n=i.html();return n=n.replace(/\s*</gi,"<"),e.each(a,(function(t,e){e.test(n)&&(n=n.replace(e,(function(t,e){return">\n<"+e+">"})))})),t.html(n),t.text()}},n.fn.bindHtml=function(){var t=this,n=t.editor,i=t.$txt,o=n.$valueContainer,r=n.valueNodeName;i.html=function(t){var n;if("div"===r&&(n=e.fn.html.call(i,t)),void 0===t?(n=e.fn.html.call(i),n=n.replace(/(href|src)\=\"(.*)\"/gim,(function(t,e,n){return e+'="'+n.replace("&","&")+'"'}))):(n=e.fn.html.call(i,t),o.val(t)),void 0===t)return n;i.change()}}})),t((function(t,e){var n=t.Txt,i="propertychange change click keyup input paste";n.fn.render=function(){var t=this.$txt,e=this.editor.$editorContainer;e.append(t)},n.fn.initHeight=function(){var t=this.editor,e=this.$txt,n=t.$valueContainer.height(),i=t.menuContainer.height(),o=n-i;o=o<50?50:o,e.height(o),t.valueContainerHeight=n,this.initMaxHeight(o,i)},n.fn.initMaxHeight=function(n,i){var o=this.editor,r=o.menuContainer.$menuContainer,a=this.$txt,c=e("<div>");if(window.getComputedStyle&&"max-height"in window.getComputedStyle(a.get(0))){var s=parseInt(o.$valueContainer.css("max-height"));if(isNaN(s))return;if(o.menus.fullscreen)return void t.warn("max-height");o.useMaxHeight=!0,c.css({"max-height":s-i+"px","overflow-y":"auto"}),a.css({height:"auto","overflow-y":"visible","min-height":n+"px"}),c.on("scroll",(function(){a.parent().scrollTop()>10?r.addClass("wangEditor-menu-shadow"):r.removeClass("wangEditor-menu-shadow")})),a.wrap(c)}},n.fn.saveSelectionEvent=function(){var t,e=this.$txt,n=this.editor,o=Date.now();function r(){n.saveSelection()}function a(){Date.now()-o<100||(o=Date.now(),r())}function c(){t&&clearTimeout(t),t=setTimeout(r,300)}e.on(i+" focus blur",(function(t){a(),c()})),e.on("mousedown",(function(){e.on("mouseleave.saveSelection",(function(t){a(),c(),n.updateMenuStyle()}))})).on("mouseup",(function(){e.off("mouseleave.saveSelection")}))},n.fn.updateValueEvent=function(){var t,e,n=this.$txt,o=this.editor;function r(){var t=n.html();e!==t&&(o.onchange&&"function"===typeof o.onchange&&o.onchange.call(o),o.updateValue(),e=t)}n.on(i,(function(i){null==e&&(e=n.html()),t&&clearTimeout(t),t=setTimeout(r,100)}))},n.fn.updateMenuStyleEvent=function(){var t=this.$txt,e=this.editor;t.on(i,(function(t){e.updateMenuStyle()}))},n.fn.insertEmptyP=function(){var t=this.$txt,n=t.children();0!==n.length?"<br>"!==e.trim(n.last().html()).toLowerCase()&&t.append(e("<p><br></p>")):t.append(e("<p><br></p>"))},n.fn.wrapImgAndText=function(){var t,n,i=this.$txt,o=i.children("img"),r=i[0],a=r.childNodes,c=a.length;for(o.length&&o.each((function(){e(this).wrap("<p>")})),t=0;t<c;t++)n=a[t],3===n.nodeType&&n.textContent&&e.trim(n.textContent)&&e(n).wrap("<p>")},n.fn.clearEmptyOrNestP=function(){var t=this.$txt,n=t.find("p");n.each((function(){var t,n=e(this),i=n.children(),o=i.length,r=e.trim(n.html());r?1===o&&(t=i.first(),t.get(0)&&"P"===t.get(0).nodeName&&n.html(t.html())):n.remove()}))},n.fn.scrollTop=function(t){var e=this,n=e.editor,i=e.$txt;return n.useMaxHeight?i.parent().scrollTop(t):i.scrollTop(t)},n.fn.showHeightOnHover=function(){var t=this.editor,n=t.$editorContainer,i=t.menuContainer,o=this.$txt,r=e('<i class="height-tip"><i>'),a=!1;function c(t){a||(n.append(r),a=!0);o.position().top,o.outerHeight();var e=t.height(),c=t.position().top,s=parseInt(t.css("margin-top"),10),l=parseInt(t.css("padding-top"),10),u=parseInt(t.css("margin-bottom"),10),f=parseInt(t.css("padding-bottom"),10);i.height();r.css({height:e+l+s+f+u,top:c+i.height()})}function s(){a&&(r.remove(),a=!1)}o.on("mouseenter","ul,ol,blockquote,p,h1,h2,h3,h4,h5,table,pre",(function(t){c(e(t.currentTarget))})).on("mouseleave",(function(){s()}))}})),t((function(t,e){Array.prototype.indexOf||(Array.prototype.indexOf=function(t){for(var e=0,n=this.length;e<n;e++)if(this[e]===t)return e;return-1},Array.prototype.lastIndexOf=function(t){var e=this.length;for(e-=1;e>=0;e--)if(this[e]===t)return e;return-1}),Date.now||(Date.now=function(){return(new Date).valueOf()});var n=window.console,i=function(){};e.each(["info","log","warn","error"],(function(e,o){if(null==n)t[o]=i;else{t[o]=function(e){t.config&&t.config.printLog}}})),t.random=function(){return Math.random().toString().slice(2)},t.placeholder="placeholder"in document.createElement("input"),t.placeholderForIE8=function(n){t.placeholder||n.find("input[placeholder]").each((function(){var t=e(this),n=t.attr("placeholder");""===t.val()&&(t.css("color","#666"),t.val(n),t.on("focus.placeholder click.placeholder",(function(){t.val(""),t.css("color","#333"),t.off("focus.placeholder click.placeholder")})))}))}})),t((function(t,e){t.langs={},t.langs["zh-cn"]={bold:"粗体",underline:"下划线",italic:"斜体",forecolor:"文字颜色",bgcolor:"背景色",strikethrough:"删除线",eraser:"清空格式",source:"源码",quote:"引用",fontfamily:"字体",fontsize:"字号",head:"标题",orderlist:"有序列表",unorderlist:"无序列表",alignleft:"左对齐",aligncenter:"居中",alignright:"右对齐",link:"链接",linkTarget:"打开方式",text:"文本",submit:"提交",cancel:"取消",unlink:"取消链接",table:"表格",emotion:"表情",img:"图片",uploadImg:"上传图片",linkImg:"网络图片",video:"视频",width:"宽",height:"高",location:"位置",loading:"加载中",searchlocation:"搜索位置",dynamicMap:"动态地图",clearLocation:"清除位置",langDynamicOneLocation:"动态地图只能显示一个位置",insertcode:"插入代码",undo:"撤销",redo:"重复",fullscreen:"全屏",openLink:"打开链接",uploadPlaceTxt:"上传中__",uploadTimeoutPlaceTxt:"上传超时__",uploadErrorPlaceTxt:"上传错误__"},t.langs.en={bold:"Bold",underline:"Underline",italic:"Italic",forecolor:"Color",bgcolor:"Backcolor",strikethrough:"Strikethrough",eraser:"Eraser",source:"Codeview",quote:"Quote",fontfamily:"Font family",fontsize:"Font size",head:"Head",orderlist:"Ordered list",unorderlist:"Unordered list",alignleft:"Align left",aligncenter:"Align center",alignright:"Align right",link:"Insert link",linkTarget:"Open mode",text:"Text",submit:"Submit",cancel:"Cancel",unlink:"Unlink",table:"Table",emotion:"Emotions",img:"Image",uploadImg:"Upload",linkImg:"Link",video:"Video",width:"width",height:"height",location:"Location",loading:"Loading",searchlocation:"search",dynamicMap:"Dynamic",clearLocation:"Clear",langDynamicOneLocation:"Only one location in dynamic map",insertcode:"Insert Code",undo:"Undo",redo:"Redo",fullscreen:"Full screnn",openLink:"open link",uploadPlaceTxt:"uploading__",uploadTimeoutPlaceTxt:"upload_timeout__",uploadErrorPlaceTxt:"upload_error__"}})),t((function(t,e){t.config={},t.config.zindex=1e4,t.config.printLog=!0,t.config.menuFixed=0,t.config.jsFilter=!0,t.config.legalTags="p,h1,h2,h3,h4,h5,h6,blockquote,table,ul,ol,pre",t.config.lang=t.langs["zh-cn"],t.config.menus=["source","|","bold","underline","italic","strikethrough","eraser","forecolor","bgcolor","|","quote","fontfamily","fontsize","head","unorderlist","orderlist","alignleft","aligncenter","alignright","|","link","unlink","table","emotion","|","img","video","location","insertcode","|","undo","redo","fullscreen"],t.config.colors={"#880000":"暗红色","#800080":"紫色","#ff0000":"红色","#ff00ff":"鲜粉色","#000080":"深蓝色","#0000ff":"蓝色","#00ffff":"湖蓝色","#008080":"蓝绿色","#008000":"绿色","#808000":"橄榄色","#00ff00":"浅绿色","#ffcc00":"橙黄色","#808080":"灰色","#c0c0c0":"银色","#000000":"黑色","#ffffff":"白色"},t.config.familys=["宋体","黑体","楷体","微软雅黑","Arial","Verdana","Georgia","Times New Roman","Microsoft JhengHei","Trebuchet MS","Courier New","Impact","Comic Sans MS","Consolas"],t.config.fontsizes={1:"12px",2:"13px",3:"16px",4:"18px",5:"24px",6:"32px",7:"48px"},t.config.emotionsShow="icon",t.config.emotions={weibo:{title:"微博表情",data:[{icon:"http://img.t.sinajs.cn/t35/style/images/common/face/ext/normal/7a/shenshou_thumb.gif",value:"[草泥马]"},{icon:"http://img.t.sinajs.cn/t35/style/images/common/face/ext/normal/60/horse2_thumb.gif",value:"[神马]"},{icon:"http://img.t.sinajs.cn/t35/style/images/common/face/ext/normal/bc/fuyun_thumb.gif",value:"[浮云]"},{icon:"http://img.t.sinajs.cn/t35/style/images/common/face/ext/normal/c9/geili_thumb.gif",value:"[给力]"},{icon:"http://img.t.sinajs.cn/t35/style/images/common/face/ext/normal/f2/wg_thumb.gif",value:"[围观]"},{icon:"http://img.t.sinajs.cn/t35/style/images/common/face/ext/normal/70/vw_thumb.gif",value:"[威武]"},{icon:"http://img.t.sinajs.cn/t35/style/images/common/face/ext/normal/6e/panda_thumb.gif",value:"[熊猫]"},{icon:"http://img.t.sinajs.cn/t35/style/images/common/face/ext/normal/81/rabbit_thumb.gif",value:"[兔子]"},{icon:"http://img.t.sinajs.cn/t35/style/images/common/face/ext/normal/bc/otm_thumb.gif",value:"[奥特曼]"},{icon:"http://img.t.sinajs.cn/t35/style/images/common/face/ext/normal/15/j_thumb.gif",value:"[囧]"},{icon:"http://img.t.sinajs.cn/t35/style/images/common/face/ext/normal/89/hufen_thumb.gif",value:"[互粉]"},{icon:"http://img.t.sinajs.cn/t35/style/images/common/face/ext/normal/c4/liwu_thumb.gif",value:"[礼物]"},{icon:"http://img.t.sinajs.cn/t35/style/images/common/face/ext/normal/ac/smilea_thumb.gif",value:"[呵呵]"},{icon:"http://img.t.sinajs.cn/t35/style/images/common/face/ext/normal/0b/tootha_thumb.gif",value:"[哈哈]"}]}},t.config.uploadImgUrl="",t.config.uploadTimeout=2e4,t.config.uploadImgFns={},t.config.customUpload=!1,t.config.uploadPlaceholderImg="data:image/gif;base64,R0lGODlhAQABAIAAAAUEBAAAACwAAAAAAQABAAACAkQBADs=",t.config.uploadParams={},t.config.uploadHeaders={},t.config.withCredentials=!0,t.config.hideLinkImg=!1,t.config.pasteFilter=!0,t.config.pasteText=!1,t.config.codeDefaultLang="javascript"})),t((function(t,e){t.UI={},t.UI.menus={default:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-command"></i></a>',selected:".selected"},bold:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-bold"></i></a>',selected:".selected"},underline:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-underline"></i></a>',selected:".selected"},italic:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-italic"></i></a>',selected:".selected"},forecolor:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-pencil"></i></a>',selected:".selected"},bgcolor:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-brush"></i></a>',selected:".selected"},strikethrough:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-strikethrough"></i></a>',selected:".selected"},eraser:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-eraser"></i></a>',selected:".selected"},quote:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-quotes-left"></i></a>',selected:".selected"},source:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-code"></i></a>',selected:".selected"},fontfamily:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-font2"></i></a>',selected:".selected"},fontsize:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-text-height"></i></a>',selected:".selected"},head:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-header"></i></a>',selected:".selected"},orderlist:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-list-numbered"></i></a>',selected:".selected"},unorderlist:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-list-bullet"></i></a>',selected:".selected"},alignleft:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-align-left"></i></a>',selected:".selected"},aligncenter:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-align-center"></i></a>',selected:".selected"},alignright:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-align-right"></i></a>',selected:".selected"},link:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-link"></i></a>',selected:".selected"},unlink:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-unlink"></i></a>',selected:".selected"},table:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-table"></i></a>',selected:".selected"},emotion:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-happy"></i></a>',selected:".selected"},img:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-picture"></i></a>',selected:".selected"},video:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-play"></i></a>',selected:".selected"},location:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-location"></i></a>',selected:".selected"},insertcode:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-terminal"></i></a>',selected:".selected"},undo:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-ccw"></i></a>',selected:".selected"},redo:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-cw"></i></a>',selected:".selected"},fullscreen:{normal:'<a href="#" tabindex="-1"><i class="wangeditor-menu-img-enlarge2"></i></a>',selected:'<a href="#" tabindex="-1" class="selected"><i class="wangeditor-menu-img-shrink2"></i></a>'}}})),t((function(t,e){t.fn.initDefaultConfig=function(){var n=this;n.config=e.extend({},t.config),n.UI=e.extend({},t.UI)}})),t((function(t,e){t.fn.addEditorContainer=function(){this.$editorContainer=e('<div class="wangEditor-container"></div>')}})),t((function(t,e){t.fn.addTxt=function(){var e=this,n=new t.Txt(e);e.txt=n}})),t((function(t,e){t.fn.addMenuContainer=function(){var e=this;e.menuContainer=new t.MenuContainer(e)}})),t((function(t,e){t.createMenuFns=[],t.createMenu=function(e){t.createMenuFns.push(e)},t.fn.addMenus=function(){var n=this,i=n.config.menus;function o(t){return i.indexOf(t)>=0}e.each(t.createMenuFns,(function(t,e){e.call(n,o)}))}})),t((function(t,e){t.createMenu((function(e){var n="bold";if(e(n)){var i=this,o=i.config.lang,r=new t.Menu({editor:i,id:n,title:o.bold,commandName:"Bold"});r.clickEventSelected=function(t){var e=i.isRangeEmpty();e?i.commandForElem("b,strong,h1,h2,h3,h4,h5",t,"Bold"):i.command(t,"Bold")},i.menus[n]=r}}))})),t((function(t,e){t.createMenu((function(e){var n="underline";if(e(n)){var i=this,o=i.config.lang,r=new t.Menu({editor:i,id:n,title:o.underline,commandName:"Underline"});r.clickEventSelected=function(t){var e=i.isRangeEmpty();e?i.commandForElem("u,a",t,"Underline"):i.command(t,"Underline")},i.menus[n]=r}}))})),t((function(t,e){t.createMenu((function(e){var n="italic";if(e(n)){var i=this,o=i.config.lang,r=new t.Menu({editor:i,id:n,title:o.italic,commandName:"Italic"});r.clickEventSelected=function(t){var e=i.isRangeEmpty();e?i.commandForElem("i",t,"Italic"):i.command(t,"Italic")},i.menus[n]=r}}))})),t((function(t,e){t.createMenu((function(n){var i="forecolor";if(n(i)){var o=this,r=o.config.lang,a=o.config.colors,c=new t.Menu({editor:o,id:i,title:r.forecolor}),s=e("<div></div>");e.each(a,(function(t,e){s.append(['<a href="#" class="color-item"',' title="'+e+'" commandValue="'+t+'" ',' style="color: '+t+'" ','><i class="wangeditor-menu-img-pencil"></i></a>'].join(""))})),s.on("click","a[commandValue]",(function(t){var n=e(this),i=n.attr("commandValue");c.selected&&o.isRangeEmpty()?o.commandForElem("font[color]",t,"forecolor",i):o.command(t,"forecolor",i)})),c.dropPanel=new t.DropPanel(o,c,{$content:s,width:125}),c.updateSelectedEvent=function(){var t=o.getRangeElem();return t=o.getSelfOrParentByName(t,"font[color]"),!!t},o.menus[i]=c}}))})),t((function(t,e){t.createMenu((function(n){var i="bgcolor";if(n(i)){var o=this,r=o.config.lang,a=o.config.colors,c=new t.Menu({editor:o,id:i,title:r.bgcolor}),s=e("<div></div>");e.each(a,(function(t,e){s.append(['<a href="#" class="color-item"',' title="'+e+'" commandValue="'+t+'" ',' style="color: '+t+'" ','><i class="wangeditor-menu-img-brush"></i></a>'].join(""))})),s.on("click","a[commandValue]",(function(t){var n=e(this),i=n.attr("commandValue");c.selected&&o.isRangeEmpty()?o.commandForElem({selector:"span,font",check:l},t,"BackColor",i):o.command(t,"BackColor",i)})),c.dropPanel=new t.DropPanel(o,c,{$content:s,width:125}),c.updateSelectedEvent=function(){var t=o.getRangeElem();return t=o.getSelfOrParentByName(t,"span,font",l),!!t},o.menus[i]=c}function l(t){var e;return!!(t&&t.style&&null!=t.style.cssText&&(e=t.style.cssText,e&&e.indexOf("background-color:")>=0))}}))})),t((function(t,e){t.createMenu((function(e){var n="strikethrough";if(e(n)){var i=this,o=i.config.lang,r=new t.Menu({editor:i,id:n,title:o.strikethrough,commandName:"StrikeThrough"});r.clickEventSelected=function(t){var e=i.isRangeEmpty();e?i.commandForElem("strike",t,"StrikeThrough"):i.command(t,"StrikeThrough")},i.menus[n]=r}}))})),t((function(t,e){t.createMenu((function(n){var i="eraser";if(n(i)){var o=this,r=o.config.lang,a=new t.Menu({editor:o,id:i,title:r.eraser,commandName:"RemoveFormat"});a.clickEvent=function(t){var n,i=o.isRangeEmpty();i?o.customCommand(t,r,a):o.command(t,"RemoveFormat");function r(){var t,i,o,r,a,c,s,l=this;t=l.getRangeElem(),r=l.getSelfOrParentByName(t,"blockquote"),r&&(a=e(r),n=e("<p>"+a.text()+"</p>"),a.after(n).remove()),i=l.getSelfOrParentByName(t,"p,h1,h2,h3,h4,h5"),i&&(o=e(i),n=e("<p>"+o.text()+"</p>"),o.after(n).remove()),c=l.getSelfOrParentByName(t,"ul,ol"),c&&(s=e(c),n=e("<p>"+s.text()+"</p>"),s.after(n).remove())}function a(){var t=this;n&&t.restoreSelectionByElem(n.get(0))}},o.menus[i]=a}}))})),t((function(t,e){t.createMenu((function(n){var i="source";if(n(i)){var o,r=this,a=r.config.lang,c=new t.Menu({editor:r,id:i,title:a.source});c.isShowCode=!1,c.clickEvent=function(t){var n=this,i=n.editor,r=i.txt.$txt,a=r.outerHeight(),l=r.height();n.$codeTextarea||(n.$codeTextarea=e('<textarea class="code-textarea"></textarea>'));var u=n.$codeTextarea;u.css({height:l,"margin-top":a-l}),u.val(r.html()),u.on("change",(function(t){s()})),r.after(u).hide(),u.show(),c.isShowCode=!0,this.updateSelected(),i.disableMenusExcept("source"),o=r.html()},c.clickEventSelected=function(t){var e=this,n=e.editor,i=n.txt.$txt,r=e.$codeTextarea;r&&(s(),r.after(i).hide(),i.show(),c.isShowCode=!1,this.updateSelected(),n.enableMenusExcept("source"),i.html()!==o&&n.onchange&&"function"===typeof n.onchange&&n.onchange.call(n))},c.updateSelectedEvent=function(){return this.isShowCode},r.menus[i]=c}function s(){var t=c.$codeTextarea,n=r.txt.$txt,i=e.trim(t.val());i||(i="<p><br></p>"),r.config.jsFilter&&(i=i.replace(/<script[\s\S]*?<\/script>/gi,""));try{n.html(i)}catch(o){}}}))})),t((function(t,e){t.createMenu((function(n){var i="quote";if(n(i)){var o=this,r=o.config.lang,a=new t.Menu({editor:o,id:i,title:r.quote,commandName:"formatBlock",commandValue:"blockquote"});a.clickEvent=function(t){var n,i=o.getRangeElem();if(i){var r,a=o.getSelfOrParentByName(i,"blockquote");a?t.preventDefault():(i=o.getLegalTags(i),n=e(i),n.text()&&(i?o.customCommand(t,c,s):o.command(t,"formatBlock","blockquote")))}else t.preventDefault();function c(){r=e("<p>"+n.text()+"</p>"),n.after(r).remove(),r.wrap("<blockquote>")}function s(){var t=this;r&&t.restoreSelectionByElem(r.get(0))}},a.clickEventSelected=function(t){var n,i,r;function a(){var t,n;if(t=e(i),n=t.children(),n.length)return n.each((function(n){var i=e(this);"P"===i.get(0).nodeName?t.after(i):t.after("<p>"+i.text()+"</p>"),r=i})),void t.remove()}function c(){var t=this;r&&t.restoreSelectionByElem(r.get(0))}n=o.getRangeElem(),i=o.getSelfOrParentByName(n,"blockquote"),i?o.customCommand(t,a,c):t.preventDefault()},a.updateSelectedEvent=function(){var t,e=this,n=e.editor;return t=n.getRangeElem(),t=n.getSelfOrParentByName(t,"blockquote"),!!t},o.menus[i]=a,o.ready((function(){var t=this,n=t.txt.$txt,i=!1;n.on("keydown",(function(n){if(13===n.keyCode){var o=t.getRangeElem();if(o=t.getSelfOrParentByName(o,"blockquote"),o)if(i){var r=t.getRangeElem(),a=e(r);a.length&&a.parent().after(a),t.restoreSelectionByElem(r,"start"),i=!1,n.preventDefault()}else i=!0;else i=!1}else i=!1}))})),o.ready((function(){var t,n=this,i=n.txt.$txt;function o(){t&&t.remove()}function r(){if(t){var e=t.prev();e.length?n.restoreSelectionByElem(e.get(0)):n.initSelection()}}i.on("keydown",(function(i){if(8===i.keyCode){var a=n.getRangeElem();if(a=n.getSelfOrParentByName(a,"blockquote"),a){t=e(a);var c=t.text();c||n.customCommand(i,o,r)}}}))}))}}))})),t((function(t,e){t.createMenu((function(n){var i="fontfamily";if(n(i)){var o=this,r=o.config.lang,a=o.config.familys,c=new t.Menu({editor:o,id:i,title:r.fontfamily,commandName:"fontName"}),s={};e.each(a,(function(t,e){s[e]=e}));var l='<span style="font-family:{#commandValue};">{#title}</span>';c.dropList=new t.DropList(o,c,{data:s,tpl:l,selectorForELemCommand:"font[face]"}),c.updateSelectedEvent=function(){var t=o.getRangeElem();return t=o.getSelfOrParentByName(t,"font[face]"),!!t},o.menus[i]=c}}))})),t((function(t,e){t.createMenu((function(e){var n="fontsize";if(e(n)){var i=this,o=i.config.lang,r=i.config.fontsizes,a=new t.Menu({editor:i,id:n,title:o.fontsize,commandName:"fontSize"}),c=r,s='<span style="font-size:{#title};">{#title}</span>';a.dropList=new t.DropList(i,a,{data:c,tpl:s,selectorForELemCommand:"font[size]"}),a.updateSelectedEvent=function(){var t=i.getRangeElem();return t=i.getSelfOrParentByName(t,"font[size]"),!!t},i.menus[n]=a}}))})),t((function(t,e){t.createMenu((function(e){var n="head";if(e(n)){var i,o=this,r=o.config.lang,a=new t.Menu({editor:o,id:n,title:r.head,commandName:"formatBlock"}),c={"<h3>":r.head},s="{#commandValue}{#title}";a.dropList=new t.DropList(o,a,{data:c,tpl:s,beforeEvent:l,afterEvent:u}),a.updateSelectedEvent=function(){var t=o.getRangeElem();return t=o.getSelfOrParentByName(t,"h1,h2,h3,h4,h5"),!!t},o.menus[n]=a}function l(t){o.queryCommandState("InsertOrderedList")?(i=!0,o.command(t,"InsertOrderedList")):i=!1}function u(t){i&&o.command(t,"InsertOrderedList")}}))})),t((function(t,e){t.createMenu((function(e){var n="unorderlist";if(e(n)){var i=this,o=i.config.lang,r=new t.Menu({editor:i,id:n,title:o.unorderlist,commandName:"InsertUnorderedList"});i.menus[n]=r}}))})),t((function(t,e){t.createMenu((function(e){var n="orderlist";if(e(n)){var i=this,o=i.config.lang,r=new t.Menu({editor:i,id:n,title:o.orderlist,commandName:"InsertOrderedList"});i.menus[n]=r}}))})),t((function(t,e){t.createMenu((function(n){var i="alignleft";if(n(i)){var o=this,r=o.config.lang,a=new t.Menu({editor:o,id:i,title:r.alignleft,commandName:"JustifyLeft"});a.updateSelectedEvent=function(){var t=o.getRangeElem();return t=o.getSelfOrParentByName(t,"p,h1,h2,h3,h4,h5,li",(function(t){var n;return!!(t&&t.style&&null!=t.style.cssText&&(n=t.style.cssText,n&&/text-align:\s*left;/.test(n)))||"left"===e(t).attr("align")})),!!t},o.menus[i]=a}}))})),t((function(t,e){t.createMenu((function(n){var i="aligncenter";if(n(i)){var o=this,r=o.config.lang,a=new t.Menu({editor:o,id:i,title:r.aligncenter,commandName:"JustifyCenter"});a.updateSelectedEvent=function(){var t=o.getRangeElem();return t=o.getSelfOrParentByName(t,"p,h1,h2,h3,h4,h5,li",(function(t){var n;return!!(t&&t.style&&null!=t.style.cssText&&(n=t.style.cssText,n&&/text-align:\s*center;/.test(n)))||"center"===e(t).attr("align")})),!!t},o.menus[i]=a}}))})),t((function(t,e){t.createMenu((function(n){var i="alignright";if(n(i)){var o=this,r=o.config.lang,a=new t.Menu({editor:o,id:i,title:r.alignright,commandName:"JustifyRight"});a.updateSelectedEvent=function(){var t=o.getRangeElem();return t=o.getSelfOrParentByName(t,"p,h1,h2,h3,h4,h5,li",(function(t){var n;return!!(t&&t.style&&null!=t.style.cssText&&(n=t.style.cssText,n&&/text-align:\s*right;/.test(n)))||"right"===e(t).attr("align")})),!!t},o.menus[i]=a}}))})),t((function(t,e){t.createMenu((function(n){var i="link";if(n(i)){var o=this,r=o.config.lang,a=new t.Menu({editor:o,id:i,title:r.link}),c=e("<div></div>"),s=e('<div style="margin:20px 10px;"></div>'),l=s.clone(),u=s.clone().css("margin","0 10px"),f=s.clone().css("margin","0 10px"),d=e('<input type="text" class="block" placeholder="'+r.text+'"/>'),p=e('<input type="text" class="block" placeholder="'+r.link+'"/>'),m=e('<input type="text" class="block" placeholder="'+r.linkTarget+': _self / _blank / _top / _parent" />'),h=e('<button class="right">'+r.submit+"</button>"),g=e('<button class="right gray">'+r.cancel+"</button>");s.append(d),l.append(p),f.append(m),f.append(h).append(g),c.append(s).append(l).append(u).append(f),a.dropPanel=new t.DropPanel(o,a,{$content:c,width:300}),a.clickEvent=function(t){var e=this,n=e.dropPanel;if(n.isShowing)n.hide();else{d.val(""),p.val(""),m.val("");var i="",r=o.getRangeElem();r=o.getSelfOrParentByName(r,"a"),r&&(i=r.href||"");var a="",c=o.isRangeEmpty();c?r&&(a=r.textContent||r.innerHTML):a=o.getRangeText()||"",i&&p.val(i),a&&d.val(a),c?d.removeAttr("disabled"):d.attr("disabled",!0),n.show()}},a.updateSelectedEvent=function(){var t=o.getRangeElem();return t=o.getSelfOrParentByName(t,"a"),!!t},g.click((function(t){t.preventDefault(),a.dropPanel.hide()})),h.click((function(n){n.preventDefault();var i,r,c,s,l,u,f=o.getRangeElem(),h=o.getSelfOrParentByName(f,"a"),g=o.isRangeEmpty(),v=o.txt.$txt,y="link"+t.random(),b=e.trim(p.val()),w=e.trim(d.val()),x=e.trim(m.val());b?(w||(w=b),g?h?(i=e(h),c=function(){i.attr("href",b),i.text(w),x&&i.attr("target",x)},s=function(){var t=this;t.restoreSelectionByElem(h)},o.customCommand(n,c,s)):(r='<a href="'+b+'"'+(x?' target="'+x+'"':"")+">"+w+"</a>",t.userAgent.indexOf("Firefox")>0&&(r+="<span> </span>"),o.command(n,"insertHtml",r)):(l=v.find("a"),l.attr(y,"1"),o.command(n,"createLink",b),u=v.find("a").not("["+y+"]"),x&&u.attr("target",x),l.removeAttr(y))):a.dropPanel.focusFirstInput()})),o.menus[i]=a}}))})),t((function(t,e){t.createMenu((function(n){var i="unlink";if(n(i)){var o=this,r=o.config.lang,a=new t.Menu({editor:o,id:i,title:r.unlink,commandName:"unLink"});a.clickEvent=function(t){var n=o.isRangeEmpty();if(n){var i=o.getRangeElem(),r=o.getSelfOrParentByName(i,"a");if(r){var a=e(r),c=e("<span>"+a.text()+"</span>");o.customCommand(t,s,l)}else t.preventDefault()}else o.command(t,"unLink");function s(){a.after(c).remove()}function l(){o.restoreSelectionByElem(c.get(0))}},o.menus[i]=a}}))})),t((function(t,e){t.createMenu((function(n){var i="table";if(n(i)){var o,r,a,c=this,s=c.config.lang,l=new t.Menu({editor:c,id:i,title:s.table}),u=e('<div style="font-size: 14px; color: #666; text-align:right;"></div>'),f=e('<table class="choose-table" style="margin-bottom:10px;margin-top:5px;">'),d=e("<span>0</span>"),p=e("<span> строк </span>"),m=e("<span>0</span>"),h=e("<span> колонок </span>");for(r=0;r<15;r++){for(o=e('<tr index="'+(r+1)+'">'),a=0;a<20;a++)o.append(e('<td index="'+(a+1)+'">'));f.append(o)}u.append(f),u.append(d).append(p).append(m).append(h),f.on("mouseenter","td",(function(t){var n=e(t.currentTarget),i=n.attr("index"),o=n.parent(),r=o.attr("index");d.text(r),m.text(i),f.find("tr").each((function(){var t=e(this),n=t.attr("index");parseInt(n,10)<=parseInt(r,10)?t.find("td").each((function(){var t=e(this),n=t.attr("index");parseInt(n,10)<=parseInt(i,10)?t.addClass("active"):t.removeClass("active")})):t.find("td").removeClass("active")}))})).on("mouseleave",(function(t){f.find("td").removeClass("active"),d.text(0),m.text(0)})),f.on("click","td",(function(t){var n,i,o=e(t.currentTarget),r=o.attr("index"),a=o.parent(),s=a.attr("index"),l=parseInt(s,10),u=parseInt(r,10),f="<table>";for(n=0;n<l;n++){for(f+="<tr>",i=0;i<u;i++)f+="<td><span> </span></td>";f+="</tr>"}f+="</table>",c.command(t,"insertHtml",f)})),l.dropPanel=new t.DropPanel(c,l,{$content:u,width:262}),c.menus[i]=l}}))})),t((function(t,e){t.createMenu((function(n){var i="emotion";if(n(i)){var o=this,r=o.config,a=r.lang,c=r.emotions,s=r.emotionsShow;o.emotionUrls=[];var l=new t.Menu({editor:o,id:i,title:a.emotion}),u=e('<div class="panel-tab"></div>'),f=e('<div class="tab-container"></div>'),d=e('<div class="content-container emotion-content-container"></div>');e.each(c,(function(n,i){var o=i.title,r=i.data;t.log("正在处理 "+o+" 表情的数据...");var a=e('<a href="#">'+o+" </a>");f.append(a);var c=e('<div class="content"></div>');if(d.append(c),a.click((function(t){f.children().removeClass("selected"),d.children().removeClass("selected"),c.addClass("selected"),a.addClass("selected"),t.preventDefault()})),"string"===typeof r)t.log(" "+r+" "),e.get(r,(function(n){n=e.parseJSON(n),t.log(" "+n.length+" "),p(n,c)}));else{if(!(Object.prototype.toString.call(r).toLowerCase().indexOf("array")>0))return void t.error("data:"+t.docsite);p(r,c)}})),u.append(f).append(d),f.children().first().addClass("selected"),d.children().first().addClass("selected"),d.on("click","a[commandValue]",(function(t){var n=e(t.currentTarget),i=n.attr("commandValue");"icon"===s?o.command(t,"InsertImage",i):o.command(t,"insertHtml","<span>"+i+"</span>"),t.preventDefault()})),l.dropPanel=new t.DropPanel(o,l,{$content:u,width:350}),l.clickEvent=function(n){var i=this,o=i.dropPanel;o.isShowing?o.hide():(o.show(),i.imgLoaded||(d.find("img").each((function(){var n=e(this),i=n.attr("_src");n.on("error",(function(){t.error(" "+i)})),n.attr("src",i),n.removeAttr("_src")})),i.imgLoaded=!0))},o.menus[i]=l}function p(t,n){e.each(t,(function(t,i){var r=i.icon||i.url,a=i.value||i.title,c="icon"===s?r:a,l=e('<a href="#" commandValue="'+c+'"></a>'),u=e("<img>");u.attr("_src",r),l.append(u),n.append(l),o.emotionUrls.push(r)}))}}))})),t((function(t,e){function n(t,n,i){var o=t.config.lang,r=e('<div style="margin:20px 10px 10px 10px;"></div>'),a=e('<input type="text" class="block" placeholder="http://"/>');r.append(a);var c=e('<button class="right">'+o.submit+"</button>"),s=e('<button class="right gray">'+o.cancel+"</button>");function l(){a.val("")}i.append(r).append(c).append(s),s.click((function(t){t.preventDefault(),n.dropPanel.hide()})),c.click((function(n){n.preventDefault();var i=e.trim(a.val());if(i){var o='<img style="max-width:100%;" src="'+i+'"/>';t.command(n,"insertHtml",o,l)}else a.focus()}))}t.createMenu((function(i){var o="img";if(i(o)){var r=this,a=r.config.lang,c=new t.Menu({editor:r,id:o,title:a.img}),s=e('<div class="panel-tab"></div>'),l=e('<div class="tab-container"></div>'),u=e('<div class="content-container"></div>');s.append(l).append(u);var f=e('<a href="#">'+a.uploadImg+"</a>"),d=e('<a href="#">'+a.linkImg+"</a>");l.append(f).append(d);var p=e('<div class="content"></div>');u.append(p);var m=e('<div class="content"></div>');u.append(m),n(r,c,m),c.dropPanel=new t.DropPanel(r,c,{$content:s,width:400,onRender:function(){var t=r.config.customUploadInit;t&&t.call(r)}}),r.menus[o]=c,r.ready((function(){var t=this,e=t.config,n=e.uploadImgUrl,i=e.customUpload,o=e.hideLinkImg;function r(){c.dropPanel.hide()}n||i?(t.$uploadContent=p,h(),o&&v()):g(),p.click((function(){setTimeout(r)}))}))}function h(){f.click((function(t){l.children().removeClass("selected"),u.children().removeClass("selected"),p.addClass("selected"),f.addClass("selected"),t.preventDefault()})),d.click((function(e){l.children().removeClass("selected"),u.children().removeClass("selected"),m.addClass("selected"),d.addClass("selected"),e.preventDefault(),t.placeholder&&m.find("input[type=text]").focus()})),f.click()}function g(){l.remove(),p.remove(),m.addClass("selected")}function v(){l.remove(),m.remove(),p.addClass("selected")}}))})),t((function(t,e){t.createMenu((function(n){var i="video";if(n(i)){var o=this,r=o.config.lang,a=/^<(iframe)|(embed)/i,c=new t.Menu({editor:o,id:i,title:r.video}),s=e("<div></div>"),l=e('<div style="margin:20px 10px;"></div>'),u=e('<input type="text" class="block" placeholder=\'Пример:<iframe src="..." frameborder=0 allowfullscreen></iframe>\'/>');l.append(u);var f=e('<div style="margin:20px 10px;"></div>'),d=e('<input type="text" value="640" style="width:50px;text-align:center;"/>'),p=e('<input type="text" value="498" style="width:50px;text-align:center;"/>');f.append("<span> "+r.width+" </span>").append(d).append("<span> px </span>").append("<span> "+r.height+" </span>").append(p).append("<span> px </span>");var m=e("<div></div>"),h=e(""),g=e('<button class="right">'+r.submit+"</button>"),v=e('<button class="right gray">'+r.cancel+"</button>");m.append(h).append(g).append(v),s.append(l).append(f).append(m),v.click((function(t){t.preventDefault(),u.val(""),c.dropPanel.hide()})),g.click((function(t){t.preventDefault();var n,i=e.trim(u.val()),r=parseInt(d.val()),s=parseInt(p.val()),l=e("<div>"),f="<p>{content}</p>";if(i)return a.test(i)?void(isNaN(r)||isNaN(s)?alert(""):(n=e(i),n.attr("width",r).attr("height",s),f=f.replace("{content}",l.append(n).html()),o.command(t,"insertHtml",f),u.val(""))):(alert(""),void c.dropPanel.focusFirstInput());c.dropPanel.focusFirstInput()})),c.dropPanel=new t.DropPanel(o,c,{$content:s,width:400}),o.menus[i]=c}}))})),t((function(t,e){function n(){if(!(t.userAgent.indexOf("MSIE 8")>0)&&!window.hljs){var e=document.createElement("script");e.type="text/javascript",e.src="//cdn.bootcss.com/highlight.js/9.2.0/highlight.min.js",document.body.appendChild(e)}}t.createMenu((function(i){var o="insertcode";if(i(o)){setTimeout(n,0);var r=this,a=r.config,c=a.lang,s=r.txt.$txt,l=new t.Menu({editor:r,id:o,title:c.insertcode});l.clickEvent=function(t){var n=this,i=n.dropPanel;if(i.isShowing)i.hide();else{f.val(""),i.show();var o=window.hljs;if(o&&o.listLanguages){if(0!==d.children().length)return;d.css({"margin-top":"9px","margin-left":"5px"}),e.each(o.listLanguages(),(function(t,e){"xml"===e&&(e="html"),e===a.codeDefaultLang?d.append('<option value="'+e+'" selected="selected">'+e+"</option>"):d.append('<option value="'+e+'">'+e+"</option>")}))}else d.hide()}},l.clickEventSelected=function(t){var n=this,i=n.dropPanel;if(i.isShowing)i.hide();else{i.show();var o,a,c=r.getRangeElem(),s=r.getSelfOrParentByName(c,"pre");s&&(s=r.getSelfOrParentByName(c,"code")),s&&(o=e(s),f.val(o.text()),d&&(a=o.attr("class"),a&&d.val(a.split(" ")[0])))}},l.updateSelectedEvent=function(){var t,e=this,n=e.editor;return t=n.getRangeElem(),t=n.getSelfOrParentByName(t,"pre"),!!t};var u=e("<div></div>"),f=e("<textarea></textarea>"),d=e("<select></select>");p(u),l.dropPanel=new t.DropPanel(r,l,{$content:u,width:500}),r.menus[o]=l,s.on("keydown",(function(t){if(13===t.keyCode){var e=r.getRangeElem(),n=r.getSelfOrParentByName(e,"code");n&&r.command(t,"insertHtml","\n")}})),s.on("keydown click",(function(t){setTimeout(m)}))}function p(t){var n=e("<div></div>");n.css({margin:"15px 5px 5px 5px",height:"160px","text-align":"center"}),f.css({width:"100%",height:"100%",padding:"10px"}),f.on("keydown",(function(t){9===t.keyCode&&t.preventDefault()})),n.append(f),t.append(n);var i=e("<div></div>"),o=e('<button class="right">'+c.submit+"</button>"),a=e('<button class="right gray">'+c.cancel+"</button>");i.append(o).append(a).append(d),t.append(i),a.click((function(t){t.preventDefault(),l.dropPanel.hide()}));var u='<pre style="max-width:100%;overflow-x:auto;"><code{#langClass}>{#content}</code></pre>';o.click((function(t){t.preventDefault();var n=f.val();if(n){var i=r.getRangeElem();e.trim(e(i).text())&&0!==u.indexOf("<p><br></p>")&&(u="<p><br></p>"+u);var o=d?d.val():"",a="",c=function(){s.find("pre code").each((function(t,n){var i=e(n);i.attr("codemark")||window.hljs&&(window.hljs.highlightBlock(n),i.attr("codemark","1"))}))};if(o&&(a=' class="'+o+' hljs"'),n=n.replace(/&/gm,"&").replace(/</gm,"<").replace(/>/gm,">"),l.selected){var p,m=r.getSelfOrParentByName(i,"pre");m&&(m=r.getSelfOrParentByName(i,"code")),m&&(p=e(m),r.customCommand(t,g,v))}else{var h=u.replace("{#langClass}",a).replace("{#content}",n);r.command(t,"insertHtml",h,c)}}else f.focus();function g(){var t;o&&(t=p.attr("class"),t!==o+" hljs"&&p.attr("class",o+" hljs")),p.html(n)}function v(){r.restoreSelectionByElem(m),c()}}))}function m(){var t=r.getRangeElem(),e=r.getSelfOrParentByName(t,"code");e?r.disableMenusExcept("insertcode"):r.enableMenusExcept("insertcode")}}))})),t((function(t,e){t.createMenu((function(e){var n="undo";if(e(n)){var i=this,o=i.config.lang,r=new t.Menu({editor:i,id:n,title:o.undo});r.clickEvent=function(t){i.undo()},i.menus[n]=r,i.ready((function(){var t,e=this,n=e.txt.$txt;function i(){e.undoRecord()}n.on("keydown",(function(n){var o=n.keyCode;n.ctrlKey&&90===o?e.undo():13===o?i():(t&&clearTimeout(t),t=setTimeout(i,1e3))})),e.undoRecord()}))}}))})),t((function(t,e){t.createMenu((function(e){var n="redo";if(e(n)){var i=this,o=i.config.lang,r=new t.Menu({editor:i,id:n,title:o.redo});r.clickEvent=function(t){i.redo()},i.menus[n]=r}}))})),t((function(t,e){var n;t.createMenu((function(e){var i="fullscreen";if(e(i)){var o,r,a=this,c=a.txt.$txt,s=a.config,l=s.zindex||1e4,u=s.lang,f=!1,d=new t.Menu({editor:a,id:i,title:u.fullscreen});d.clickEvent=function(e){var i,s=a.$editorContainer;s.addClass("wangEditor-fullscreen"),o=s.css("z-index"),s.css("z-index",l);var u=c.height(),d=c.outerHeight();a.useMaxHeight&&(r=c.css("max-height"),c.css("max-height","none"),i=c.parent(),i.after(c),i.remove(),c.css("overflow-y","auto"));var p=a.menuContainer;c.height(t.$window.height()-p.height()-(d-u)),a.menuContainer.$menuContainer.attr("style",""),f=!0,a.isFullScreen=!0,n=t.$window.scrollTop()},d.clickEventSelected=function(e){var i=a.$editorContainer;i.removeClass("wangEditor-fullscreen"),i.css("z-index",o),a.useMaxHeight?c.css("max-height",r):a.$valueContainer.css("height",a.valueContainerHeight),a.txt.initHeight(),f=!1,a.isFullScreen=!1,null!=n&&t.$window.scrollTop(n)},d.updateSelectedEvent=function(t){return f},a.menus[i]=d}}))})),t((function(t,e){t.fn.renderMenus=function(){var t,n=this,i=n.menus,o=n.config.menus,r=(n.menuContainer,0);e.each(o,(function(e,n){"|"!==n?(t=i[n],t&&t.render(r)):r++}))}})),t((function(t,e){t.fn.renderMenuContainer=function(){var t=this,e=t.menuContainer;t.$editorContainer;e.render()}})),t((function(t,e){t.fn.renderTxt=function(){var t=this,e=t.txt;e.render(),t.ready((function(){e.initHeight()}))}})),t((function(t,e){t.fn.renderEditorContainer=function(){var t,e,n=this,i=n.$valueContainer,o=n.$editorContainer,r=n.txt.$txt;i===r?(t=n.$prev,e=n.$parent,t&&t.length?t.after(o):e.prepend(o)):(i.after(o),i.hide())}})),t((function(t,e){t.fn.eventMenus=function(){var t=this.menus;e.each(t,(function(t,e){e.bindEvent()}))}})),t((function(t,e){t.fn.eventMenuContainer=function(){}})),t((function(t,e){t.fn.eventTxt=function(){var t=this.txt;t.saveSelectionEvent(),t.updateValueEvent(),t.updateMenuStyleEvent()}})),t((function(t,e){t.plugin((function(){var e=this,n=e.config.uploadImgFns;n.onload||(n.onload=function(e,n){t.log(" "+e);var i,o=this,r=o.uploadImgOriginalName||"";0===e.indexOf("error|")?(t.warn(e.split("|")[1]),alert(e.split("|")[1])):(t.log(""+e),i=document.createElement("img"),i.onload=function(){var n='<img src="'+e+'" alt="'+r+'" style="max-width:100%;"/>';o.command(null,"insertHtml",n),t.log("已插入图片,地址 "+e),i=null},i.onerror=function(){t.error(""+e),i=null},i.src=e)}),n.ontimeout||(n.ontimeout=function(e){t.error(""),alert("")}),n.onerror||(n.onerror=function(e){t.error(""),alert("")})}))})),t((function(t,e){window.FileReader&&window.FormData&&t.plugin((function(){var n=this,i=n.config,o=i.uploadImgUrl,r=i.uploadTimeout,a=i.uploadImgFns,c=a.onload,s=a.ontimeout,l=a.onerror;function u(t,e){var n,i=window.atob(t.split(",")[1]),o=new ArrayBuffer(i.length),r=new Uint8Array(o);for(n=0;n<i.length;n++)r[n]=i.charCodeAt(n);return new Blob([o],{type:e})}function f(e,i){var o=document.createElement("img");o.onload=function(){var r='<img src="'+e+'" style="max-width:100%;"/>';n.command(i,"insertHtml",r),t.log(" "+e),o=null},o.onerror=function(){t.error(""+e),o=null},o.src=e}function d(t){if(t.lengthComputable){var e=t.loaded/t.total;n.showUploadProgress(100*e)}}o&&(n.xhrUploadImg=function(i){var a=i.event,p=i.filename||"",m=i.base64,h=i.fileType||"image/png",g=i.name||"wangEditor_upload_file",v=i.loadfn||c,y=i.errorfn||l,b=i.timeoutfn||s,w=n.config.uploadParams||{},x=n.config.uploadHeaders||{};if(p.indexOf(".")>0?p.slice(p.lastIndexOf(".")-p.length+1):h.indexOf("/")>0&&h.split("/")[1]&&h.split("/")[1],t.isOnWebsite)return t.log(""),void f(m,a);var C,S=new XMLHttpRequest,k=new FormData;function O(){C&&clearTimeout(C),S&&S.abort&&S.abort(),a.preventDefault(),b&&b.call(n,S,p),n.hideUploadProgress()}S.onload=function(){C&&clearTimeout(C),n.uploadImgOriginalName=p,p.indexOf(".")>0&&(n.uploadImgOriginalName=p.split(".")[0]),console.log(p),v&&v.call(n,S.responseText,S,p),n.hideUploadProgress()},S.onerror=function(){C&&clearTimeout(C),a.preventDefault(),y&&y.call(n,S,p),n.hideUploadProgress()},S.upload.onprogress=d,k.append(g,u(m,h),p),e.each(w,(function(t,e){k.append(t,e)})),S.open("POST",o,!0),e.each(x,(function(t,e){S.setRequestHeader(t,e)})),S.withCredentials=!!n.config.withCredentials,S.send(k),C=setTimeout(O,r),t.log("...")})}))})),t((function(t,e){t.plugin((function(){var t,n=this,i=n.menuContainer,o=i.height(),r=n.$editorContainer,a=r.width(),c=e('<div class="wangEditor-upload-progress"></div>'),s=!1;function l(){s||(s=!0,c.css({top:o+"px"}),r.append(c))}function u(){c.hide(),t=null}n.showUploadProgress=function(e){t&&clearTimeout(t),l(),c.show(),c.width(e*a/100)},n.hideUploadProgress=function(e){t&&clearTimeout(t),e=e||750,t=setTimeout(u,e)}}))})),t((function(t,e){t.plugin((function(){var n=this,i=n.config,o=i.uploadImgUrl,r=i.uploadTimeout;if(o){var a=n.$uploadContent;if(a){var c=e('<div class="upload-icon-container"><i class="wangeditor-menu-img-upload"></i></div>');a.append(c);var s=new t.UploadFile({editor:n,uploadUrl:o,timeout:r,fileAccept:"image/jpg,image/jpeg,image/png,image/gif,image/bmp"});c.click((function(t){t,s.selectFiles()}))}}}))})),t((function(t,e){if(window.FileReader&&window.FormData){var n=function(t){this.editor=t.editor,this.uploadUrl=t.uploadUrl,this.timeout=t.timeout,this.fileAccept=t.fileAccept,this.multiple=!0};n.fn=n.prototype,n.fn.clear=function(){this.$input.val(""),t.log("input value 已清空")},n.fn.render=function(){var n=this;if(!n._hasRender){t.log("渲染dom");var i=n.fileAccept,o=i?'accept="'+i+'"':"",r=n.multiple,a=r?'multiple="multiple"':"",c=e('<input type="file" '+o+" "+a+"/>"),s=e('<div style="display:none;"></div>');s.append(c),t.$body.append(s),c.on("change",(function(t){n.selected(t,c.get(0))})),n.$input=c,n._hasRender=!0}},n.fn.selectFiles=function(){var e=this;t.log(""),e.render(),t.log(""),e.$input.click()},n.fn.selected=function(n,i){var o=this,r=i.files||[];0!==r.length&&(t.log(" "+r.length+" "),e.each(r,(function(t,e){o.upload(e)})))},n.fn.upload=function(e){var n=this,i=n.editor,o=e.name||"",r=e.type||"",a=i.config.uploadImgFns,c=i.config.lang,s=i.config.uploadImgFileName||"wangEditorH5File",l=a.onload,u=a.ontimeout,f=a.onerror,d=new FileReader;function p(){n.clear()}l&&u&&f?(t.log(" "+o+" "),i.command(null,"insertHtml",'<img alt="'+c.uploadPlaceTxt+o+'" src="'+i.config.uploadPlaceholderImg+'"/>'),d.onload=function(e){t.log(""+o);var n=e.target.result||this.result;i.xhrUploadImg({event:e,filename:o,base64:n,fileType:r,name:s,loadfn:function(t,e,n){p();var i=this;l.call(i,t,e,n)},errorfn:function(e,n){p(),t.isOnWebsite&&alert("");var i=this;f.call(i,e,n)},timeoutfn:function(e,n){p(),t.isOnWebsite&&alert("");var i=this;u(i,e,n)}})},d.readAsDataURL(e)):t.error(" onload ontimeout onerror ")},t.UploadFile=n}})),t((function(t,e){if(!window.FileReader||!window.FormData){var n=function(t){this.editor=t.editor,this.uploadUrl=t.uploadUrl,this.timeout=t.timeout,this.fileAccept=t.fileAccept,this.multiple=!1};n.fn=n.prototype,n.fn.clear=function(){this.$input.val(""),t.log("")},n.fn.hideModal=function(){this.modal.hide()},n.fn.render=function(){var n=this,i=n.editor,o=i.config.uploadImgFileName||"wangEditorFormFile";if(!n._hasRender){var r=n.uploadUrl;t.log("渲染dom");var a="iframe"+t.random(),c=e('<iframe name="'+a+'" id="'+a+'" frameborder="0" width="0" height="0"></iframe>'),s=n.multiple,l=s?'multiple="multiple"':"",u=e("<p>НУЖЕН ПЕРЕВОД</p>"),f=e('<input type="file" '+l+' name="'+o+'"/>'),d=e('<input type="submit" value="НУЖЕН ПЕРЕВОД"/>'),p=e('<form enctype="multipart/form-data" method="post" action="'+r+'" target="'+a+'"></form>'),m=e('<div style="margin:10px 20px;"></div>');p.append(u).append(f).append(d),e.each(i.config.uploadParams,(function(t,n){p.append(e('<input type="hidden" name="'+t+'" value="'+n+'"/>'))})),m.append(p),m.append(c),n.$input=f,n.$iframe=c;var h=new t.Modal(i,void 0,{$content:m});n.modal=h,n._hasRender=!0}},n.fn.bindLoadEvent=function(){var t=this;if(!t._hasBindLoad){var n=t.editor,i=t.$iframe,o=i.get(0),r=o.contentWindow,a=n.config.uploadImgFns.onload;o.attachEvent?o.attachEvent("onload",c):o.onload=c,t._hasBindLoad=!0}function c(){var i=e.trim(r.document.body.innerHTML);if(i){var o=t.$input.val(),c=o;o.lastIndexOf("\\")>=0&&(c=o.slice(o.lastIndexOf("\\")+1),c.indexOf(".")>0&&(c=c.split(".")[0])),n.uploadImgOriginalName=c,a.call(n,i),t.clear(),t.hideModal()}}},n.fn.show=function(){var t=this,e=t.modal;function n(){e.show(),t.bindLoadEvent()}setTimeout(n)},n.fn.selectFiles=function(){var e=this;t.log("form"),e.render(),e.clear(),e.show()},t.UploadFile=n}})),t((function(t,e){t.plugin((function(){var n,i,o=this,r=o.txt,a=r.$txt,c=o.config,s=c.uploadImgUrl,l=c.uploadImgFileName||"wangEditorPasteFile";function u(){var r=/^data:(image\/\w+);base64/,c=a.find("img");t.log(""+c.length),e.each(c,(function(){var a,c,s=this,u=e(s),f=u.attr("src");i.each((function(){if(s===this)return a=!0,!1})),a||(t.log(""),r.test(f)?(t.log("sr base64 "),c=f.match(r)[1],o.xhrUploadImg({event:n,base64:f,fileType:c,name:l})):t.log("src "+f+" base64 "),u.remove())})),t.log("遍历结束")}s&&a.on("paste",(function(r){n=r;var c,s,f=n.clipboardData||n.originalEvent.clipboardData;c=null==f?window.clipboardData&&window.clipboardData.getData("text"):f.getData("text/plain")||f.getData("text/html"),c||(s=f&&f.items,s?(t.log("通过 data.items 得到了数据"),console.log(s),e.each(s,(function(e,i){var r=i.type||"";if(!(r.indexOf("image")<0)){var a=i.getAsFile(),c=new FileReader;t.log(""),c.onload=function(e){t.log("");var i=e.target.result||this.result;o.xhrUploadImg({event:n,base64:i,fileType:r,name:l})},c.readAsDataURL(a)}}))):(t.log(" data.items "),i=a.find("img"),t.log(""+i.length),setTimeout(u,0)))}))}))})),t((function(t,e){t.plugin((function(){var n=this,i=n.txt,o=i.$txt,r=n.config,a=n.config.lang,c=r.uploadImgUrl,s=r.uploadImgFileName||"wangEditorDragFile";c&&(t.$document.on("dragleave drop dragenter dragover",(function(t){t.preventDefault()})),o.on("drop",(function(i){i.preventDefault();var o=i.originalEvent,r=o.dataTransfer&&o.dataTransfer.files;r&&r.length&&e.each(r,(function(e,o){var r=o.type,c=o.name;if(!(r.indexOf("image/")<0)){t.log(" "+c),n.command(null,"insertHtml",'<img alt="'+a.uploadPlaceTxt+c+'" src="'+n.config.uploadPlaceholderImg+'" />');var l=new FileReader;l.onload=function(e){t.log(" "+c);var o=e.target.result||this.result;n.xhrUploadImg({event:i,filename:c,base64:o,fileType:r,name:s})},l.readAsDataURL(o)}}))})))}))})),t((function(t,e){t.plugin((function(){var n,i=this,o=i.txt,r=o.$txt,a="",c=i.useMaxHeight?r.parent():r,s=!1,l=e('<div class="txt-toolbar"></div>'),u=e('<div class="tip-triangle"></div>'),f=e('<a href="#"><i class="wangeditor-menu-img-trash-o"></i></a>'),d=e('<a href="#"><i class="wangeditor-menu-img-search-minus"></i></a>'),p=e('<a href="#"><i class="wangeditor-menu-img-search-plus"></i></a>');function m(){s||(h(),l.append(u).append(f).append(d).append(p),i.$editorContainer.append(l),s=!0)}function h(){var t;function e(e,n){a=r.html();var o=function(){n&&n(),a!==r.html()&&r.change()};t&&i.customCommand(e,t,o)}f.click((function(i){t=function(){n.remove()},e(i,(function(){setTimeout(v,100)}))})),p.click((function(i){t=function(){n.css({width:"100%"})},e(i,(function(){setTimeout(g)}))})),d.click((function(i){t=function(){n.css({width:"auto"})},e(i,(function(){setTimeout(g)}))}))}function g(){if(!i._disabled&&null!=n){n.addClass("clicked");var t=n.position(),e=t.top,o=t.left,r=n.outerHeight(),a=n.outerWidth(),s=e+r,f=o,d=0,p=c.position().top,m=c.outerHeight();s>p+m&&(s=p+m),l.show();var h=l.outerWidth();d=a/2-h/2,l.css({top:s+5,left:f,"margin-left":d}),d<0?(l.css("margin-left","0"),u.hide()):u.show()}}function v(){null!=n&&(n.removeClass("clicked"),n=null,l.hide())}c.on("click","table",(function(t){var i=e(t.currentTarget);m(),n&&n.get(0)===i.get(0)?setTimeout(v,100):(n=i,g(),t.preventDefault(),t.stopPropagation())})).on("click keydown scroll",(function(t){setTimeout(v,100)})),t.$body.on("click keydown scroll",(function(t){setTimeout(v,100)}))}))})),t((function(t,e){t.userAgent.indexOf("MSIE 8")>0||t.plugin((function(){var n,i=this,o=i.config.lang,r=i.txt,a=r.$txt,c="",s=i.useMaxHeight?a.parent():a,l=(i.$editorContainer,""),u=!1,f=e('<div class="img-drag-point"></div>'),d=e('<div class="txt-toolbar"></div>'),p=e('<div class="tip-triangle"></div>'),m=e("<div></div>"),h=e('<a href="#"><i class="wangeditor-menu-img-trash-o"></i></a>'),g=e('<a href="#"><i class="wangeditor-menu-img-search-minus"></i></a>'),v=e('<a href="#"><i class="wangeditor-menu-img-search-plus"></i></a>'),y=e('<a href="#"><i class="wangeditor-menu-img-align-left"></i></a>'),b=e('<a href="#"><i class="wangeditor-menu-img-align-center"></i></a>'),w=e('<a href="#"><i class="wangeditor-menu-img-align-right"></i></a>'),x=e('<a href="#"><i class="wangeditor-menu-img-link"></i></a>'),C=e('<a href="#"><i class="wangeditor-menu-img-unlink"></i></a>'),S=e('<div style="display:none;"></div>'),k=e('<input type="text" style="height:26px; margin-left:10px; width:200px;"/>'),O=e('<button class="right">'+o.submit+"</button>"),_=e('<button class="right gray">'+o.cancel+"</button>"),P=!1;function E(t,o){if(n){var r,s,u=function(){null!=o&&(l=o),c!==a.html()&&a.change()},f=!1,d=n.parent();if("a"===d.get(0).nodeName.toLowerCase()?(s=d,f=!0):s=e('<a target="_blank"></a>'),null==o)return s.attr("href")||"";if(""===o)f&&(r=function(){n.unwrap()});else{if(o===l)return;r=function(){s.attr("href",o),f||n.wrap(s)}}r&&(c=a.html(),i.customCommand(t,r,u))}}function T(){u||(j(),R(),m.append(h).append(g).append(v).append(y).append(b).append(w).append(x).append(C),S.append(k).append(_).append(O),d.append(p).append(m).append(S),i.$editorContainer.append(d).append(f),u=!0)}function j(){var t;function o(e,n){var o;c=a.html(),o=function(){n&&n(),c!==a.html()&&a.change()},t&&i.customCommand(e,t,o)}h.click((function(e){E(e,""),t=function(){n.remove()},o(e,(function(){setTimeout(D,100)}))})),v.click((function(e){t=function(){var t=n.get(0),e=t.width,i=t.height;e*=1.1,i*=1.1,n.css({width:e+"px",height:i+"px"})},o(e,(function(){setTimeout($)}))})),g.click((function(e){t=function(){var t=n.get(0),e=t.width,i=t.height;e*=.9,i*=.9,n.css({width:e+"px",height:i+"px"})},o(e,(function(){setTimeout($)}))})),y.click((function(e){t=function(){n.parents("p").css({"text-align":"left"}).attr("align","left")},o(e,(function(){setTimeout(D,100)}))})),w.click((function(e){t=function(){n.parents("p").css({"text-align":"right"}).attr("align","right")},o(e,(function(){setTimeout(D,100)}))})),b.click((function(e){t=function(){n.parents("p").css({"text-align":"center"}).attr("align","center")},o(e,(function(){setTimeout(D,100)}))})),x.click((function(t){t.preventDefault(),l=E(t),k.val(l),m.hide(),S.show()})),O.click((function(t){t.preventDefault();var n=e.trim(k.val());n&&E(t,n),setTimeout(D)})),_.click((function(t){t.preventDefault(),k.val(l),m.show(),S.hide()})),C.click((function(t){t.preventDefault(),E(t,""),setTimeout(D)}))}function R(){var e,i,o,r,a,c;function s(t){var s,l;s=t.pageX-e,l=t.pageY-i;var u=o+s,d=r+l;f.css({"margin-left":u,"margin-top":d});var p=a+s,m=c+l;n&&n.css({width:p,height:m})}f.on("mousedown",(function(l){n&&(e=l.pageX,i=l.pageY,o=parseFloat(f.css("margin-left"),10),r=parseFloat(f.css("margin-top"),10),a=n.width(),c=n.height(),d.hide(),t.$document.on("mousemove._dragResizeImg",s),t.$document.on("mouseup._dragResizeImg",(function(e){t.$document.off("mousemove._dragResizeImg"),t.$document.off("mouseup._dragResizeImg"),D(),f.css({"margin-left":o,"margin-top":r}),P=!1})),P=!0)}))}function $(){if(!i._disabled&&null!=n){n.addClass("clicked");var t=n.position(),e=t.top,o=t.left,r=n.outerHeight(),a=n.outerWidth();f.css({top:e+r,left:o+a});var c=e+r,l=o,u=0,m=s.position().top,h=s.outerHeight();c>m+h?c=m+h:f.show(),d.show();var g=d.outerWidth();u=a/2-g/2,d.css({top:c+5,left:l,"margin-left":u}),u<0?(d.css("margin-left","0"),p.hide()):p.show(),i.disableMenusExcept()}}function D(){null!=n&&(n.removeClass("clicked"),n=null,d.hide(),f.hide(),i.enableMenusExcept())}function M(t){var n=!1;return i.emotionUrls?(e.each(i.emotionUrls,(function(e,i){var o=!1;if(t===i&&(n=!0,o=!0),o)return!1})),n):n}s.on("mousedown","img",(function(t){t.preventDefault()})).on("click","img",(function(t){var i=e(t.currentTarget),o=i.attr("src");o&&!M(o)&&(T(),n&&n.get(0)===i.get(0)?setTimeout(D,100):(n=i,$(),m.show(),S.hide(),t.preventDefault(),t.stopPropagation()))})).on("click keydown scroll",(function(t){P||setTimeout(D,100)}))}))})),t((function(t,e){t.plugin((function(){var t,n,i,o,r,a=this,c=a.config.lang,s=a.txt.$txt,l=e('<div class="txt-toolbar"></div>'),u=e('<div class="tip-triangle"></div>'),f=e('<a href="#" target="_blank"><i class="wangeditor-menu-img-link"></i> '+c.openLink+"</a>"),d=!1;function p(){n||(l.append(u).append(f),a.$editorContainer.append(l),n=!0)}function m(){if(t){var e=t.position(),n=e.left,i=e.top,o=t.height(),r=i+o+5,c=a.menuContainer.height(),s=a.txt.$txt.outerHeight();r>c+s&&(r=c+s+5),l.css({top:r,left:n})}}function h(){if(!d&&t){p(),l.show();var e=t.attr("href");f.attr("href",e),m(),d=!0}}function g(){d&&t&&(l.hide(),d=!1)}s.on("mouseenter","a",(function(n){i&&clearTimeout(i),i=setTimeout((function(){var i=n.currentTarget,o=e(i);t=o;var r=o.children("img");r.length&&(r.click((function(t){g()})),r.hasClass("clicked"))||h()}),500)})).on("mouseleave","a",(function(t){o&&clearTimeout(o),o=setTimeout(g,500)})).on("click keydown scroll",(function(t){setTimeout(g,100)})),l.on("mouseenter",(function(t){o&&clearTimeout(o)})).on("mouseleave",(function(t){r&&clearTimeout(r),r=setTimeout(g,500)}))}))})),t((function(t,e){t.plugin((function(){var e=this,n=e.config.menuFixed;if(!1!==n&&"number"===typeof n){var i=parseFloat(t.$body.css("margin-top"),10);isNaN(i)&&(i=0);var o=e.$editorContainer,r=o.offset().top,a=o.outerHeight(),c=e.menuContainer.$menuContainer,s=c.css("position"),l=c.css("top"),u=c.offset().top,f=c.outerHeight();e.txt.$txt;t.$window.scroll((function(){if(!e.isFullScreen){var d=t.$window.scrollTop(),p=c.width();0===u&&(u=c.offset().top,r=o.offset().top,a=o.outerHeight(),f=c.outerHeight()),d>=u&&d+n+f+30<r+a?(c.css({position:"fixed",top:n}),c.width(p),t.$body.css({"margin-top":i+f}),e._isMenufixed||(e._isMenufixed=!0)):(c.css({position:s,top:l}),c.css("width","100%"),t.$body.css({"margin-top":i}),e._isMenufixed&&(e._isMenufixed=!1))}}))}}))})),t((function(t,e){t.createMenu((function(n){var i="indent";if(n(i)){var o=this,r=new t.Menu({editor:o,id:i,title:"indent-left",$domNormal:e('<a href="#" tabindex="-1"><i class="wangeditor-menu-img-indent-left"></i></a>'),$domSelected:e('<a href="#" tabindex="-1" class="selected"><i class="wangeditor-menu-img-indent-left"></i></a>')});r.clickEvent=function(t){var n,i=o.getRangeElem(),r=o.getSelfOrParentByName(i,"p");if(!r)return t.preventDefault();function a(){n.css("text-indent","2em")}n=e(r),o.customCommand(t,a)},r.clickEventSelected=function(t){var n,i=o.getRangeElem(),r=o.getSelfOrParentByName(i,"p");if(!r)return t.preventDefault();function a(){n.css("text-indent","0")}n=e(r),o.customCommand(t,a)},r.updateSelectedEvent=function(){var t,n,i=o.getRangeElem(),r=o.getSelfOrParentByName(i,"p");return!!r&&(t=e(r),n=t.css("text-indent"),!(!n||"0px"===n))},o.menus[i]=r}}))})),t((function(t,e){t.createMenu((function(n){var i="lineheight";if(n(i)){var o=this;o.commandHooks.lineHeight=function(t){var n=o.getRangeElem(),i=o.getSelfOrParentByName(n,"p,h1,h2,h3,h4,h5,pre");i&&e(i).css("line-height",t+"")};var r=new t.Menu({editor:o,id:i,title:"line Height",commandName:"lineHeight",$domNormal:e('<a href="#" tabindex="-1"><i class="wangeditor-menu-img-arrows-v"></i></a>'),$domSelected:e('<a href="#" tabindex="-1" class="selected"><i class="wangeditor-menu-img-arrows-v"></i></a>')}),a={"1.0":"1.0",1.5:"1.5",1.8:"1.8","2.0":"2.0",2.5:"2.5","3.0":"3.0"},c='<span style="line-height:{#commandValue}">{#title}</span>';r.dropList=new t.DropList(o,r,{data:a,tpl:c}),o.menus[i]=r}}))})),t((function(t,e){t.plugin((function(){var n=this,i=n.config.customUpload;if(i){if(n.config.uploadImgUrl)return alert(".log"),void t.error(" uploadImgUrl customUpload ");var o=n.$uploadContent;o||t.error(" editor.$uploadContent");var r=e('<div class="upload-icon-container"><i class="wangeditor-menu-img-upload"></i></div>');o.append(r);var a="upload"+t.random(),c="upload"+t.random();r.attr("id",a),o.attr("id",c),n.customUploadBtnId=a,n.customUploadContainerId=c}}))})),t((function(t,e){t.info(" ")}))}alert("")}))}).call(this,n("62e4")(t))},1310:function(t,e,n){"use strict";n("3672")},"150b":function(t,e,n){},2500:function(t,e,n){t.exports=n.p+"img/card3.ebd65c13.webp"},"26e0":function(t,e,n){},"2c09":function(t,e,n){"use strict";n("cf4e")},3672:function(t,e,n){},"399b":function(t,e,n){"use strict";n("9e37")},4283:function(t,e,n){t.exports=n.p+"img/card5.706ede64.png"},"50cc":function(t,e,n){},"52a2":function(t,e,n){t.exports=n.p+"img/card1.7ace7820.jpg"},"5b20":function(t,e,n){t.exports=n.p+"img/card4.0ff4df75.png"},"5bb1":function(t,e,n){"use strict";n("7eea")},"78bd":function(t,e,n){},"7d93":function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAq/SURBVHgBjVdbjB11Gf/N9czMuc05e/a+bc+2hd4obEmRpWCgoAhRTAGVkhhCfOKtTQzxxaT0zcREyovxscREqg/EJiraRFsikZvSDRQoW7Y923bvlzPnNveLvxnSmmqF7mYzs3P5f9//+36XbwTc4s+RAw+ZfaJ7QBLwoGO7E34U1RVJMtuOh2bbsaIYjQTx1IBpnGnDPXnsTMO6lXWFr3rghYl6va+UP2SWtOc1VTZzigKfQYMoQszXO7aLlu0jYgYRr/WVNPhRAj8MjttufPRXU43Gl60v/b8bRx6aMB++beBnsojXYiSTiiRqeV1lSBFJnCD9TfP3ghBBECGIgTCMYBY0CKKIMI4mRAGH76jq5kZDfve85bo3iyPe7OLB7UP1UPDPxlF0iOsiZADfj6AIAuIozgJLgsjsBeQUGZIkImJSEgML/PWZVHqu8F4hXzw8WDHPvsA1bymBF/fdNpEThdOeF9Zjxkq40YSBW7abPZ6WOWCANJTC8siSBFaH5xKDMtkoRPoekvSejHbPQcv1654ind7Xn5/Al7XgYNpvRX5DV9V6lMSQWcOEKLHdL3ZULujZgvXdOzE2sRuju3bAHB6CVipAkhW0m01Ui0W4gc/K5Pi+BJvnfpS1yFQk9bH7NtVOTi1a1wF6HYR10zSr/aWzD1dz9SJ7zX1k1yNmYHsBCrqGaiGH2tgIJn/4feTNGlEgZG2IeKblcvj87BTePvE7OB2b4AzgEoyW4yBmGXuOT2wI0IS40Teo7bnGkustuHdj/iVRFOsRH1LltKwybC7viCoSowSxWEY3ErD9wfuRS//n/RSQiqbDSP9nv7fsuROTTzyelTVrRRTwmHAtCZW8hnp/NX2ufvWqc+SGFhye3F5nfq91AsBUBSwmCj7uhqiMDWLDphpGxqoolfPQqwXYto3W6goXj1AbHICkqlmtojRY4GFovI63//w39LouCJ2MMQU9x0AJIrKk5XpY7XqTQ3m8erUbWlkCOwdLL5/vYiJhz3pEkBkHuOf2fmziU32GhhwXUoQEKlXIblloLS9j7sJ5XCXFS2WTJQZk3nc7bQgpI6x1rM7OsWV6dr1J3OgEbMwEXD8gHhL+SbjSdf8iHJ6om2eduLkcCLirAGyvllDUFQTlHKNK0LhDI6fyKCMh0HyKjt3twnZcgtODUS7DKBlsJmnJthjEiipI+Oy9czAIZC+MMbfWxUg1DzcMMd/qoktQz7c9ywvFcalnFA+u+PGBTQTYsFlGjgV1fRcxAwcsqcA6poxY7zqYv7KGkcFBDAyMcGciej0P040FvPH+DJ/1oSYEnt0j/0XURvrhxxGW59d5TOmcwOAm1rmBNTuEF8VaJITnpWK1/5AmRBODUqpsRC1FZyaQsNpz0V9QM+FJFc7q9VDpG8G+B79JWrF8S2vQ8kWMDdbgUppff+8CPppdRSzKkNOVCMJyrYoO7/W6HtI+pWv2/JCs4h8r48exJW2qFF+6t6wMbSbIRgsK5iMFoyowxoqsM5HYaRPJMdY6Dma5Gy2nwWCE2XUb733yGR7Zty/DyccXZzNv+OzKCj6dXcbFhSbml9ew2OlA4X3KI0RWU2Cbmq6f4SCtirw7L9RNVYLIC9MLLSxrRdxVy+FSm2hXihA8gWW1sJQzkGMPI0nH1t33QK8t4LFvfyfThg8/PAeVNIxZxYJhkKIiFqwWZhZbKORkbBsKsFHN4bb+ElqswOw6kyLdwzCpy24Ym4tejJriwtBklAIHPTtBn5yQswlGjQKacYgrBGlF1/H4Y9/ibkJs3bYTKjVgefojeI4Nx/OpCQSsplCKY+zaUsfU9CXoTMaUchlmdOqBYSoYLxuwuEacaKY47URYICrXBIXoBSpCSMrFGW+X1ylW5DcFCppMYep0MTczjU/ffwshq+KszpMVHfTX+lFkmUVZhZrTKcs5NJsWSkwmVdA+LcVFQuBFpKOEgaKKopqKHem7r6paFSNn+gQaE8RG7krO7FSAkTcY34PNFx1Sa9DQcer0aWzwEnQXVrHx7m1wiJHpy5dZNUouy6xyhyv0hJT/W8aG0aLsOwT2KG067XmYGpmQGhWt3PYtkS1qtOl0AfubWmkYpYj30GDv424nQ+18rEIhNe+/bxIr6+vo6jLG905wIQl/PPVXfDLzeZZ8tVxCl6jXqRubR8eytURJQUiBS0jJVDJT/wjIgPSeF6EhO14wxc1PpLaaenxAxK8kMtZoQBvEGBc8CR0a0kjoYvcDD2Ds9q349W9OYKbZxrnz09izdRA6sRG0AuR5XFolUzQNjbk5KNSSiAEdYmKAjumQfinZbW6q69Ihw2RKtNXim5nh6HksJDm82yUb7JhAivCuxUqsdlELOrh953ZUR4Yxv7CIxsISTpx6k2pmw45lUILgcdFVYqbZamOdDNCZhMQ1nF4XOVIvjRzRmNLRzeVw44UJEwnOyH9fcX+fRMHLWPdMmfNeX4EIpeqtkAlpr/oote1KAQ8/c5AgbGFx7iqcEBiqmSiWihSfRbRovwbtuEjT8X2Du/OxwkR0WcimKIvgtYoKNHpvujGBvhASD5yxToqNRoPTmn88INU8UintMYkEJfaIfAV66KFeKWPLzl3orq1CpBuO0ys201oNclkh97dvGsZz330U99+2CeOmgTKvlckaiUFSaw+5Ecv2MlV1OZn4FKWcIB2fsiwrVU0MB51XvrZx+HBCYLTJ91VBhdjfhz6HwuR7+MFzzyJ0qQ/tLpbYu+qdk7h66VPYzRZ++pND+PqBZ6CXyugsL+LN11/DMllx5fIsPjg/g9lmlwlIGZhlzgQLbQddtoDCdfT6PLDohtYT2wbNPl2d3FDUsKUoYX29CUvS8PS+u/CNpw6iubKCixdmYOXH4Lo9rFy+iPvu3Ysf/fhFaBxW0h6rOQlbxjdg165tuJNjW6WUx6m3/slKJrizVqEmcEbkpLTW84/94cryb2+YiCgTR1tdr7HQ7HGc8rCjoiH2bOx94nvZ5GbTSJYIzv1PPo3xLVswPlTD3rt3QgwD+kUPoB5E1hKCzioHDxeyKmLijm1EP8d0aso0WdOiC2qy2HB64dFrceVrJ0c5o3E22E+bPO0grA/RCR+9Zze279jJwZKU8X0M7ZzAth2bUZKfxCTHr/HRyhdjs9fORIbinm0lnZY8p4vF+TlI7LtByXOpAeu22xg0hP1nrP8MpTeM5cf4FTPrRk9ecsRGi1Dfu+8+mo/MHfloERuTjzyCjtVGdWgAG/Y+AGlsAheaCdYiUrjpEtlcUNUpyXLmfDYtfKxcgEmPSHdeLKhPHn3nxi+l//ku+NOFuSk3sfe3IqFR33FHOhZno9Tte/ZmtBREhe7IqYjUCzmEGAWqXyjDNYaxJI9ynqyiB7aPwItlHSVVwYhZbKxba/t//o8LU/8d76afZhQf6/Vf/uLVwsCIFkOcXF1agjxQp0ryM4wKWaaqeaRSREmVqKBp9dNjWv4unTUw+uHoAzD4zpW33jgW5LxnT5xbXbxZrK/8OF14+3T9g3+9c2TrI089P7BhDJcbc6hUKpDJ75kLDWweH6N+BBzNDdprjCbVkEZrxYl8HJL2yp4dw40vW/8rE7j202wmZmPu/IF8Pv9gTtEnrly+Wu+v1Uwjr6Pb7lgcSBvtdntqdOOGM0P9xZOcJW/p8/zfYz5tui59j0wAAAAASUVORK5CYII="},"7dad":function(t,e,n){},"7eea":function(t,e,n){},8193:function(t,e,n){},8813:function(t,e,n){"use strict";n("26e0")},9993:function(t,e,n){"use strict";n("7dad")},"9d57":function(t,e,n){t.exports=n.p+"img/card2.80a603f2.png"},"9e37":function(t,e,n){},b3be:function(t,e,n){},beb8:function(t,e,n){t.exports=n.p+"img/fb.4e9efd91.svg"},c226:function(t,e,n){t.exports=n.p+"img/ig.909e8e89.svg"},cd49:function(t,e,n){"use strict";n.r(e);n("a4d3"),n("e01a"),n("b636"),n("dc8d"),n("efe9"),n("d28b"),n("2a1b"),n("8edd"),n("80e0"),n("6b9e"),n("197b"),n("2351"),n("8172"),n("944a"),n("81b8"),n("967a"),n("99af"),n("a874"),n("a623"),n("cb29"),n("4de4"),n("7db0"),n("c740"),n("0481"),n("5db7"),n("4160"),n("a630"),n("caad"),n("c975"),n("e260"),n("a15b"),n("baa5"),n("d81d"),n("5ded"),n("13d5"),n("f4dd"),n("fb6a"),n("45fc"),n("f785"),n("a434"),n("4069"),n("73d9"),n("c19f"),n("82da"),n("ace4"),n("efec"),n("b56e"),n("b0c0"),n("6c57"),n("e9c4"),n("0c47"),n("4ec9"),n("5327"),n("79a8"),n("9ff9"),n("3ea3"),n("40d9"),n("ff9c"),n("0ac8"),n("f664"),n("4057"),n("bc01"),n("6b93"),n("ca21"),n("90d7"),n("2af1"),n("0261"),n("7898"),n("23dc"),n("b65f"),n("a9e3"),n("35b3"),n("f00c"),n("8ba4"),n("9129"),n("583b"),n("aff5"),n("e6e1"),n("c35a"),n("25eb"),n("b680"),n("cca6"),n("12a8"),n("e71b"),n("4fad"),n("dca8"),n("c1f9"),n("e439"),n("dbb4"),n("7039"),n("3410"),n("2b19"),n("c906"),n("e21d"),n("e43e"),n("b64b"),n("bf96"),n("5bf7"),n("cee8"),n("af93"),n("131a"),n("d3b7"),n("07ac"),n("e6cf"),n("820e"),n("dbfa"),n("a79d"),n("a6fd"),n("4ae1"),n("3f3a"),n("ac16"),n("5d41"),n("9e4a"),n("7f78"),n("c760"),n("db96"),n("1bf2"),n("d6dd"),n("7ed3"),n("8b9a"),n("f8c9"),n("4d63"),n("ac1f"),n("5377"),n("2c3e"),n("00b4"),n("25f0"),n("6062"),n("f5b2"),n("8a79"),n("f6d6"),n("2532"),n("3ca3"),n("466d"),n("a1f0"),n("843c"),n("4d90"),n("d80f"),n("38cf"),n("5319"),n("5b81"),n("841c"),n("1276"),n("2ca0"),n("498a"),n("1e25"),n("eee7"),n("18a5"),n("1393"),n("04d3"),n("cc71"),n("c7cd"),n("9767"),n("1913"),n("c5d0"),n("9911"),n("c96a"),n("2315"),n("4c53"),n("664f"),n("cfc3"),n("4a9b"),n("fd87"),n("8b09"),n("143c"),n("5cc6"),n("8a59"),n("84c3"),n("fb2c"),n("9a8c"),n("a975"),n("735e"),n("c1ac"),n("d139"),n("3a7b"),n("d5d6"),n("20bf"),n("82f8"),n("e91f"),n("60bd"),n("5f96"),n("3280"),n("3fcc"),n("ec97"),n("ca91"),n("25a1"),n("cd26"),n("3c5d"),n("2954"),n("649e"),n("219c"),n("170b"),n("b39a"),n("72f7"),n("10d1"),n("1fe2"),n("159b"),n("ddb0"),n("130f"),n("9f96"),n("2b3d"),n("bf19"),n("9861"),n("96cf");var i=n("b166"),o=n("e3ee"),r=n("ad53");Date.prototype.toJSON=function(){var t=this.getHours(),e=this.getHours()-this.getTimezoneOffset()/60;this.setHours(e);var n=this.toISOString();return this.setHours(t),n},Date.prototype.format=function(t){return Object(i["a"])(this,t,{locale:r["a"]})},String.prototype.format=function(t){return Object(i["a"])(Object(o["a"])(this),t,{locale:r["a"]})},Date.prototype.addMinutes=function(t){return new Date(this.setMinutes(this.getMinutes()+t))},Date.prototype.addHours=function(t){return new Date(this.setHours(this.getHours()+t))},Date.prototype.addDays=function(t){return new Date(this.setDate(this.getDate()+t))},Date.prototype.addMonths=function(t){return new Date(this.setMonth(this.getMonth()+t))},Date.prototype.addYears=function(t){return new Date(this.setFullYear(this.getFullYear()+t))},Date.prototype.isSameDay=function(t){return this.getFullYear()==t.getFullYear()&&this.getMonth()==t.getMonth()&&this.getDate()==t.getDate()},Array.prototype.remove=function(t){this.splice(t,1)};var a=n("2b0e"),c=n("f309"),s=n("94ed"),l={badge:"знак",close:"Закрыть",noDataText:"Отсутствует"};a["a"].use(c["a"]);var u=new c["a"]({breakpoint:{scrollBarWidth:0,thresholds:{xs:601,sm:1001,md:1265,lg:1905}},icons:{iconfont:"mdiSvg",values:{dropdown:s["c"]}},lang:{locales:{ru:l},current:"ru"},theme:{themes:{light:{primary:"#7245ff"}}}}),f=n("2f62"),d=n("1898"),p=n("a34a"),m=n.n(p);function h(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function g(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function v(t,e,n){return e&&g(t.prototype,e),n&&g(t,n),t}var y=function(){function t(){h(this,t),this.urls={local:"http://localhost:6600",external:"https://pampadu.ru"},this.file=this.urls.external+"/api/file",this.article=this.apiUrl+"/article"}return v(t,[{key:"combineUrl",value:function(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return"".concat(e?this.apiUrl:this.url).concat(t)}},{key:"combineFileUrl",value:function(t){return"".concat(this.apiUrl,"/file/content?fileName=").concat(t)}},{key:"url",get:function(){return this.urls.external}},{key:"apiUrl",get:function(){return this.url+"/api"}}]),t}(),b=new y,w=n("bc3a"),x=n.n(w);function C(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,i)}return n}function S(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?C(Object(n),!0).forEach((function(e){k(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):C(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function k(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function O(t,e,n,i,o,r,a){try{var c=t[r](a),s=c.value}catch(l){return void n(l)}c.done?e(s):Promise.resolve(s).then(i,o)}function _(t){return function(){var e=this,n=arguments;return new Promise((function(i,o){var r=t.apply(e,n);function a(t){O(r,i,o,a,c,"next",t)}function c(t){O(r,i,o,a,c,"throw",t)}a(void 0)}))}}function P(){return function(){var t=_(m.a.mark((function t(e,n,i,o,r){var a,c,s;return m.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return a={post:{"Content-Type":"application/json;charset=UTF-8"},put:{"Content-Type":"application/json;charset=UTF-8"}},c=S(S({},a[e.toLowerCase()]),o),t.prev=2,t.next=5,x.a.request({url:n,method:e,params:i,headers:c,data:JSON.stringify(r)});case 5:return s=t.sent,t.abrupt("return",s.data);case 9:throw t.prev=9,t.t0=t["catch"](2),console.log(t.t0,t.t0.response),t.t0;case 13:case"end":return t.stop()}}),t,null,[[2,9]])})));return function(e,n,i,o,r){return t.apply(this,arguments)}}()}var E=P();function T(t,e,n,i,o,r,a){try{var c=t[r](a),s=c.value}catch(l){return void n(l)}c.done?e(s):Promise.resolve(s).then(i,o)}function j(t){return function(){var e=this,n=arguments;return new Promise((function(i,o){var r=t.apply(e,n);function a(t){T(r,i,o,a,c,"next",t)}function c(t){T(r,i,o,a,c,"throw",t)}a(void 0)}))}}function R(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function $(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function D(t,e,n){return e&&$(t.prototype,e),n&&$(t,n),t}var M=function(){function t(){R(this,t),this.baseUrl=b.article}return D(t,[{key:"get",value:function(){var t=j(m.a.mark((function t(e){var n,i;return m.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return n="".concat(this.baseUrl,"/").concat(e),t.next=3,E("get",n);case 3:return i=t.sent,t.abrupt("return",i);case 5:case"end":return t.stop()}}),t,this)})));function e(e){return t.apply(this,arguments)}return e}()},{key:"getList",value:function(){var t=j(m.a.mark((function t(){var e,n,i=arguments;return m.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return e=i.length>0&&void 0!==i[0]?i[0]:999,n="".concat(this.baseUrl,"?batchSize=").concat(e),t.next=4,E("get",n);case 4:return t.abrupt("return",t.sent);case 5:case"end":return t.stop()}}),t,this)})));function e(){return t.apply(this,arguments)}return e}()}],[{key:"getInstance",value:function(){var e;return t.instance=null!==(e=t.instance)&&void 0!==e?e:new t,t.instance}}]),t}(),A=M.getInstance();function I(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var N=function t(){I(this,t)};function F(t){return F="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},F(t)}function L(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function H(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&B(t,e)}function B(t,e){return B=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},B(t,e)}function V(t){var e=z();return function(){var n,i=W(t);if(e){var o=W(this).constructor;n=Reflect.construct(i,arguments,o)}else n=i.apply(this,arguments);return U(this,n)}}function U(t,e){return!e||"object"!==F(e)&&"function"!==typeof e?q(t):e}function q(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function z(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}function W(t){return W=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},W(t)}var Y=function(t){H(n,t);var e=V(n);function n(){var t;return L(this,n),t=e.apply(this,arguments),t.creationDate=null,t}return n}(N);function K(t,e,n,i,o,r,a){try{var c=t[r](a),s=c.value}catch(l){return void n(l)}c.done?e(s):Promise.resolve(s).then(i,o)}function G(t){return function(){var e=this,n=arguments;return new Promise((function(i,o){var r=t.apply(e,n);function a(t){K(r,i,o,a,c,"next",t)}function c(t){K(r,i,o,a,c,"throw",t)}a(void 0)}))}}var Q={articles:[],currentArticle:new Y},J={namespaced:!0,state:Q,mutations:{setList:function(t,e){t.articles=e},setArticle:function(t,e){t.currentArticle=e}},actions:{getList:function(t,e){return G(m.a.mark((function n(){var i,o;return m.a.wrap((function(n){while(1)switch(n.prev=n.next){case 0:return i=t.commit,n.next=3,A.getList(e);case 3:return o=n.sent,i("setList",o),n.abrupt("return",o);case 6:case"end":return n.stop()}}),n)})))()},get:function(t,e){return G(m.a.mark((function n(){var i,o;return m.a.wrap((function(n){while(1)switch(n.prev=n.next){case 0:return i=t.commit,n.next=3,A.get(e);case 3:return o=n.sent,i("setArticle",o),n.abrupt("return",o);case 6:case"end":return n.stop()}}),n)})))()}},getters:{}};a["a"].use(f["a"]);var X={messages:null,confirm:null,debugData:null},Z=Object(d["a"])({state:X,modules:{news:J},mutations:{},getters:{}}),tt=Z.store,et=(Z.rootActionContext,Z.moduleActionContext,tt),nt=n("8c4f"),it=n("60a3"),ot=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",[t.$vuetify.breakpoint.smAndDown?i("div",[i("v-layout",{staticClass:"py-2",attrs:{"align-center":"","justify-space-between":""}},[i("v-icon",{staticClass:"mx-4",attrs:{size:"30",color:"#000"},domProps:{textContent:t._s(t.mdiChevron)}}),i("span",{staticStyle:{"font-family":"Montserrat","font-size":"16px"},domProps:{textContent:t._s("Блог")}}),i("v-icon",{staticClass:"mx-4",attrs:{size:"30",color:"#0000"},domProps:{textContent:t._s(t.mdiChevron)}})],1),i("v-divider")],1):t._e(),i("div",{staticClass:"ppd-container mt-0"},[t.$vuetify.breakpoint.smAndDown?t._e():[i("v-divider"),i("div",{staticClass:"article-crumbs"},[i("a",{attrs:{href:"https://pampadu.ru"},domProps:{textContent:t._s("Главная")}}),i("span",{staticClass:"crumb-divider",domProps:{textContent:t._s("—")}}),i("router-link",{attrs:{to:{name:"main"}},domProps:{textContent:t._s("Блог")}}),i("span",{staticClass:"crumb-divider",domProps:{textContent:t._s("—")}}),i("span",{domProps:{textContent:t._s(t.article.title)}})],1),i("v-divider"),t.$root.ppdToken?[i("div",{staticClass:"article-crumbs"},[i("v-btn",{staticClass:"mx-2",on:{click:function(e){return t.$router.push("/edit/article.id")}}},[i("span",{staticClass:"black--text",domProps:{textContent:t._s("Редактировать")}})]),i("v-btn",{staticClass:"mx-2",attrs:{color:"success"}},[i("span",{staticClass:"white--text",domProps:{textContent:t._s("Опубликовать")}})]),i("v-btn",{staticClass:"mx-2",attrs:{color:"error"}},[i("span",{staticClass:"white--text",domProps:{textContent:t._s("Удалить")}})]),i("v-btn",{staticClass:"mx-2",attrs:{color:"info"}},[i("span",{staticClass:"white--text",domProps:{textContent:t._s("Перенести в черновик")}})])],1),i("v-divider")]:t._e()],i("v-layout",{attrs:{column:t.$vuetify.breakpoint.smAndDown}},[i("div",{staticStyle:{flex:"1 0 auto"}},[i("h1",{staticClass:"article-title",domProps:{textContent:t._s(t.article.title)}}),t.$vuetify.breakpoint.smAndDown?t._e():i("h2",{staticClass:"h5 article-preview",domProps:{textContent:t._s(t.article.preview)}})]),i("v-img",{staticStyle:{flex:"0 1 auto"},attrs:{gradient:t.$vuetify.breakpoint.smAndDown?"":"to right, #ffff 5%, #fff0 50%",contain:"",position:t.$vuetify.breakpoint.smAndDown?"center":"right center","max-height":"360",src:n("4283")}}),t.$vuetify.breakpoint.smAndDown?i("h2",{staticClass:"h5 article-preview",domProps:{textContent:t._s(t.article.preview)}}):t._e()],1)],2),i("v-layout",{staticStyle:{padding:"0 16px","max-width":"1062px",margin:"auto"},attrs:{column:t.$vuetify.breakpoint.smAndDown,"justify-space-between":""}},[i("div",{staticClass:"ppd-article-container"},[i("span",{staticClass:"bg-l"}),i("span",{staticClass:"bg-r"}),i("article",{staticClass:"ppd-article",domProps:{innerHTML:t._s(t.article.content)}}),i("div",{staticClass:"btn outline px-5 mt-4",on:{click:function(e){return t.$router.push({name:"main"})}}},[i("v-icon",{staticStyle:{"margin-top":"-2px","margin-left":"-8px","margin-right":"8px"},attrs:{size:"26",color:"#000"},domProps:{textContent:t._s(t.mdiChevron)}}),i("div",{staticStyle:{display:"inline-block"},domProps:{textContent:t._s("Назад к списку статей")}})],1)]),i("div",{staticClass:"article-right"},[i("v-layout",{staticClass:"article-right-card",attrs:{"align-center":""}},[i("v-img",{staticClass:"mr-3",staticStyle:{flex:"0 0 40px"},attrs:{height:"40",width:"40",src:t.article.author.img}}),i("v-layout",{staticStyle:{width:"100%",height:"40px"},attrs:{column:"","justify-space-between":""}},[i("div",{staticClass:"article-author",domProps:{textContent:t._s(t.article.author.name)}}),i("v-layout",{staticClass:"article-author-info",attrs:{"align-center":""}},[i("span",{staticClass:"article-date",domProps:{textContent:t._s(t.article.creationDate.format("dd.MM.yyyy"))}}),i("v-spacer"),i("ViewsIcon",{attrs:{size:16}}),i("div",{staticClass:"article-views",domProps:{textContent:t._s(t.article.views)}})],1)],1)],1),i("div",{staticClass:"article-right-card"},[i("v-layout",{staticClass:"article-tags",attrs:{wrap:""}},t._l(t.article.tags,(function(e,n){return i("div",{key:n,staticClass:"article-tag",domProps:{textContent:t._s(e)}})})),0)],1),i("v-layout",{staticClass:"article-right-card",attrs:{column:""}},[i("span",{staticClass:"article-right-share-title",domProps:{textContent:t._s("Поделиться:")}}),i("div",t._l(t.socials,(function(t,e){return i("a",{key:e,staticStyle:{width:"26px",height:"26px",margin:"0 2px"},attrs:{href:t.url}},[i("img",{staticStyle:{width:"26px",height:"26px"},attrs:{src:t.image}})])})),0)]),i("div",{staticClass:"article-right-card join-tg"},[i("div",{staticStyle:{margin:"0 -10px"},domProps:{innerHTML:t._s("Зарегистрируйтесь и получите <b>доступ к закрытому Telegram каналу</b>, на который уже\n <b>подписано больше 3000</b> активных страховых агентов и брокеров")}}),i("div",{staticClass:"btn w-100 text-center",staticStyle:{margin:"20px -10px 0",height:"60px",padding:"18px 26px"},domProps:{textContent:t._s("Присоединиться")}})])],1)]),i("div",{staticStyle:{"background-color":"#F9F9FC"}},[i("div",{staticClass:"ppd-container py-10"},[i("div",{staticClass:"h4 mb-6",staticStyle:{"font-weight":"700"},domProps:{textContent:t._s("Вам будет интресно почитать")}}),i("ArticlesList",{attrs:{articles:t.articles}}),i("div",{staticClass:"btn",staticStyle:{display:"block",margin:"36px auto 60px",width:"213px","text-align":"center",cursor:"pointer"}},[i("span",{domProps:{textContent:t._s("Показать ещё")}})])],1)])],1)},rt=[],at=n("9ab4"),ct=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("svg",{attrs:{width:t.size,height:t.size,viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg"}},[n("path",{attrs:{d:"M11.9237 5.76655C11.8165 5.61991 9.26224 2.17578 5.99994 2.17578C2.73765 2.17578 0.183235 5.61991 0.0761486 5.76641C-0.0253829 5.90554 -0.0253829 6.09423 0.0761486 6.23336C0.183235 6.38001 2.73765 9.82413 5.99994 9.82413C9.26224 9.82413 11.8165 6.37999 11.9237 6.23348C12.0254 6.09438 12.0254 5.90554 11.9237 5.76655ZM5.99994 9.03293C3.59691 9.03293 1.51564 6.74699 0.899533 5.99969C1.51484 5.25173 3.59176 2.96699 5.99994 2.96699C8.40285 2.96699 10.484 5.25252 11.1004 6.00023C10.485 6.74817 8.40813 9.03293 5.99994 9.03293Z",fill:t.color}}),n("path",{attrs:{d:"M5.99961 3.62646C4.69081 3.62646 3.62598 4.6913 3.62598 6.0001C3.62598 7.3089 4.69081 8.37374 5.99961 8.37374C7.3084 8.37374 8.37324 7.3089 8.37324 6.0001C8.37324 4.6913 7.3084 3.62646 5.99961 3.62646ZM5.99961 7.58251C5.12703 7.58251 4.4172 6.87266 4.4172 6.0001C4.4172 5.12755 5.12705 4.41769 5.99961 4.41769C6.87216 4.41769 7.58201 5.12755 7.58201 6.0001C7.58201 6.87266 6.87218 7.58251 5.99961 7.58251Z",fill:t.color}})])},st=[];function lt(t){return lt="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},lt(t)}function ut(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function ft(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&dt(t,e)}function dt(t,e){return dt=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},dt(t,e)}function pt(t){var e=gt();return function(){var n,i=vt(t);if(e){var o=vt(this).constructor;n=Reflect.construct(i,arguments,o)}else n=i.apply(this,arguments);return mt(this,n)}}function mt(t,e){return!e||"object"!==lt(e)&&"function"!==typeof e?ht(t):e}function ht(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function gt(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}function vt(t){return vt=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},vt(t)}var yt=function(t){ft(n,t);var e=pt(n);function n(){return ut(this,n),e.apply(this,arguments)}return n}(it["c"]);Object(at["a"])([Object(it["b"])({default:"#7D8D93"})],yt.prototype,"color",void 0),Object(at["a"])([Object(it["b"])({default:12})],yt.prototype,"size",void 0),yt=Object(at["a"])([it["a"]],yt);var bt=yt,wt=bt,xt=n("2877"),Ct=Object(xt["a"])(wt,ct,st,!1,null,null,null),St=Ct.exports,kt=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("v-layout",{staticClass:"article-cards",attrs:{wrap:""}},t._l(t.articles,(function(e,i){return n("v-flex",{key:""+i+t.listKey,staticClass:"article-card-outer",attrs:{xs12:"",sm6:!e.emphasis,sm12:e.emphasis,md4:!e.emphasis,md8:e.emphasis,lg3:!e.emphasis,lg6:e.emphasis}},[n("ArticleCard",{attrs:{article:e}})],1)})),1)},Ot=[],_t=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("v-card",{staticClass:"article-card",class:{emphasis:t.article.emphasis},style:t.styles,attrs:{tile:""},on:{click:function(e){return t.$router.push({name:"article",params:{id:"article.id"}})}}},[t.article.emphasis?t._e():n("v-img",{attrs:{src:t.article.image,"aspect-ratio":t.$vuetify.breakpoint.smAndDown?16/9:1}}),n("v-layout",{staticClass:"article-card-body",attrs:{column:"","fill-height":""}},[t.article.emphasis?n("v-spacer"):t._e(),n("div",{staticClass:"article-card-tags"},t._l(t.article.tags,(function(e,i){return n("span",{key:i,staticClass:"article-card-tag",domProps:{textContent:t._s(e)}})})),0),n("div",{staticClass:"article-card-title",domProps:{textContent:t._s(t.article.title)}}),t.article.emphasis?t._e():n("div",{staticClass:"article-card-preview",domProps:{textContent:t._s(t.article.preview)}}),n("v-layout",{staticStyle:{flex:"0"},attrs:{"align-center":""}},[n("v-img",{staticStyle:{flex:"none"},attrs:{height:"16",width:"16",src:t.article.author.img,"aspect-ratio":1}}),n("div",{staticClass:"article-card-author",domProps:{textContent:t._s(t.article.author.name)}}),n("div",{staticClass:"article-card-date",domProps:{textContent:t._s(t.article.creationDate.format("dd.MM.yyyy"))}}),n("v-spacer"),n("ViewsIcon",{attrs:{color:t.article.emphasis?"#FFF":"#7D8D93"}}),n("div",{staticClass:"article-card-views",domProps:{textContent:t._s(t.article.views)}})],1)],1)],1)},Pt=[];function Et(t){return Et="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Et(t)}function Tt(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function jt(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function Rt(t,e,n){return e&&jt(t.prototype,e),n&&jt(t,n),t}function $t(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&Dt(t,e)}function Dt(t,e){return Dt=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},Dt(t,e)}function Mt(t){var e=Nt();return function(){var n,i=Ft(t);if(e){var o=Ft(this).constructor;n=Reflect.construct(i,arguments,o)}else n=i.apply(this,arguments);return At(this,n)}}function At(t,e){return!e||"object"!==Et(e)&&"function"!==typeof e?It(t):e}function It(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Nt(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}function Ft(t){return Ft=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},Ft(t)}var Lt=function(t){$t(n,t);var e=Mt(n);function n(){return Tt(this,n),e.apply(this,arguments)}return Rt(n,[{key:"styles",get:function(){var t="";return this.article.emphasis&&(t="linear-gradient(0, #0008 0%, #0000 100%), url(".concat(this.article.image,") !important")),{backgroundImage:t,backgroundSize:"cover, cover",backgroundRepeat:"no-repeat, no-repeat",backgroundPosition:"center, center"}}}]),n}(it["c"]);Object(at["a"])([Object(it["b"])({default:null})],Lt.prototype,"article",void 0),Lt=Object(at["a"])([Object(it["a"])({components:{ViewsIcon:St}})],Lt);var Ht=Lt,Bt=Ht,Vt=(n("2c09"),n("6544")),Ut=n.n(Vt),qt=n("b0af"),zt=n("adda"),Wt=n("a722"),Yt=n("2fa4"),Kt=Object(xt["a"])(Bt,_t,Pt,!1,null,null,null),Gt=Kt.exports;function Qt(t){return Qt="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Qt(t)}function Jt(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Xt(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&Zt(t,e)}function Zt(t,e){return Zt=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},Zt(t,e)}function te(t){var e=ie();return function(){var n,i=oe(t);if(e){var o=oe(this).constructor;n=Reflect.construct(i,arguments,o)}else n=i.apply(this,arguments);return ee(this,n)}}function ee(t,e){return!e||"object"!==Qt(e)&&"function"!==typeof e?ne(t):e}function ne(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function ie(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}function oe(t){return oe=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},oe(t)}Ut()(Kt,{VCard:qt["a"],VImg:zt["a"],VLayout:Wt["a"],VSpacer:Yt["a"]});var re=function(t){Xt(n,t);var e=te(n);function n(){return Jt(this,n),e.apply(this,arguments)}return n}(it["c"]);Object(at["a"])([Object(it["b"])({default:function(){return[]}})],re.prototype,"articles",void 0),Object(at["a"])([Object(it["b"])({default:"key"})],re.prototype,"listKey",void 0),re=Object(at["a"])([Object(it["a"])({components:{ArticleCard:Gt}})],re);var ae=re,ce=ae,se=(n("5bb1"),n("0e8f")),le=Object(xt["a"])(ce,kt,Ot,!1,null,null,null),ue=le.exports;function fe(t){return fe="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},fe(t)}function de(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function pe(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function me(t,e,n){return e&&pe(t.prototype,e),n&&pe(t,n),t}function he(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&ge(t,e)}function ge(t,e){return ge=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},ge(t,e)}function ve(t){var e=we();return function(){var n,i=xe(t);if(e){var o=xe(this).constructor;n=Reflect.construct(i,arguments,o)}else n=i.apply(this,arguments);return ye(this,n)}}function ye(t,e){return!e||"object"!==fe(e)&&"function"!==typeof e?be(t):e}function be(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function we(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}function xe(t){return xe=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},xe(t)}Ut()(le,{VFlex:se["a"],VLayout:Wt["a"]});var Ce=function(t){he(i,t);var e=ve(i);function i(){var t;return de(this,i),t=e.apply(this,arguments),t.mdiChevron=s["d"],t.socials=[{url:"https://tele.gg/joinchat/AAAAAE2b6VJSXwGX3WY7nw",image:n("e5cf")},{url:"https://www.facebook.com/Pampadu.ru/",image:n("beb8")},{url:"https://vk.com/avto_yslyga",image:n("e790")},{url:"https://www.instagram.com/pampadu.ru/",image:n("c226")}],t}return me(i,[{key:"article",get:function(){var t=function(t){return"<tr>\n <th>23344</th>\n <td>05.2019</td>\n <td>".concat(t,"</td>\n <td>13.191 руб.</td>\n </tr>")},e=function(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:6,n="",i=0;i<e;i++){var o=2==i?"Можно настроить программу страхования под себя. Внимание к каждому клиенту. С нами надёжно. Без посещения офиса!":"Команда Pampadu";n+=t(o)}return n},i='\n <h3>Что такое страховка от коронавируса</h3>\n <p>Напомним, что полис от COVID-19 не имеет ничего общего с туристическим или другими видами страхования. Это самостоятельный продукт, который обеспечивает застрахованному лицу финансовую защиту в случае заболевания коронавирусом.</p>\n <p>То есть по данной страховке вы получаете только денежные выплаты, но никак не лечение. Поэтому в данном случае страховая не оказывает никакую помощь больному в виде предоставления медицинских услуг. Лечение вы получаете по полису ОМС.</p>\n <h3>Какую страховку от коронавируса лучше выбрать</h3>\n <p>На сегодняшний день самым выгодным полисом является АльфаСтрахование. Данная страховка представлена на нашем сайте.</p>\n <ppd-alert type="success">\n Почему стоит оформить страховку? Мы работаем напрямую со страховыми компаниями, полисы которых представлены у нас на сайте. Но в отличие от самих компаний мы предоставляем скидку 15% на любую страховку. Все промокоды в данной статье.\n </ppd-alert>\n <p>У АльфаСтрахования хорошие условия страхования: выплаты осуществляются даже при пандемии, карантине, при чрезвычайном положении. Также немаловажным фактором является возраст страхования – до 70 лет. Высокая цена полиса оправдывает сумму компенсации – 50 и 100 тыс. руб.</p>\n <p>Из более бюджетных вариантов лучше выбрать полис от Гайде. Данная страховка также выплачивает деньги при объявлении пандемии или карантина. Возраст застрахованного может быть любым.</p>\n <img src="https://i.imgur.com/LOgcKb6.png">\n <p>У АльфаСтрахования хорошие условия страхования: выплаты осуществляются даже при пандемии, карантине, при чрезвычайном положении. Также немаловажным фактором является возраст страхования – до 70 лет. Высокая цена полиса оправдывает сумму компенсации – 50 и 100 тыс. руб.</p>\n <p>Из более бюджетных вариантов лучше выбрать полис от Гайде. Данная страховка также выплачивает деньги при объявлении пандемии или карантина. Возраст застрахованного может быть любым.</p>\n <div class="table-container">\n <table>\n <thead>\n <tr>\n <th>Колонка</th>\n <th>Колонка</th>\n <th>Колонка</th>\n <th>Колонка</th>\n </tr>\n </thead>\n <tbody>'.concat(e(6),"</tbody>\n </table>\n </div>\n <h3>Маркированный список</h3>\n <ul>\n <li>Автоматическое подтягивание данных по гос. номеру</li>\n <li>Автоматический поиск техосмотра</li>\n <li>Проверка КБМ по каждому водителю</li>\n </ul>\n <h3>Нумерованный список</h3>\n <ol>\n <li>Автоматическое подтягивание данных по гос. номеру</li>\n <li>Автоматический поиск техосмотра</li>\n <li>Проверка КБМ по каждому водителю</li>\n </ol>\n ");return{tags:["#страхование","#финансы","#дополнительныйтег","#финансы","#страхование"],title:"Страховка от коронавируса: цены, выплаты, условия страхования",preview:"В одной из наших статей мы уже рассказывали о том, что такое страхование от коронавируса и как оно работает. В данной статье сравним цены и условия полисов от COVID-19 разных компаний.",author:{img:n("7d93"),name:"Жанна Шмелева"},creationDate:new Date,views:2788,content:i}}},{key:"articles",get:function(){var t={tags:["#страхование","#финансы"],image:n("52a2"),title:"Началась у нас зелёная полоса/ итоги бюджета за 2 декабря",preview:"Так началась у нас зелёная полоса. Почему зелёная? Потому что те дни, когда нет у нас расходов, выделяю зелёным цветом.",author:{img:n("7d93"),name:"Жанна Шмелева"},creationDate:new Date,views:2788,emphasis:!1};return[t,t,t,t]}}]),i}(it["c"]);Ce=Object(at["a"])([Object(it["a"])({components:{ViewsIcon:St,ArticlesList:ue}})],Ce);var Se=Ce,ke=Se,Oe=(n("d497"),n("8336")),_e=n("ce7e"),Pe=n("132d"),Ee=Object(xt["a"])(ke,ot,rt,!1,null,null,null),Te=Ee.exports;Ut()(Ee,{VBtn:Oe["a"],VDivider:_e["a"],VIcon:Pe["a"],VImg:zt["a"],VLayout:Wt["a"],VSpacer:Yt["a"]});var je=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticStyle:{"background-color":"#f9f9fc"}},[n("BlogFirst"),n("BlogTags"),n("ArticlesContainer")],1)},Re=[],$e=n("e7c3"),De=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("v-layout",{staticClass:"ppd-container",attrs:{"align-start":"",column:t.$vuetify.breakpoint.smAndDown,wrap:t.editSocs}},[n("v-layout",{staticClass:"blog-tags",attrs:{wrap:""}},[n("v-card",{staticClass:"blog-tag",class:{active:0==t.activeTags.length},domProps:{textContent:t._s("Все")},on:{click:function(e){t.activeTags=[]}}}),t._l(t.tags,(function(e,i){return n("BlogTagCard",{key:i,attrs:{tag:e,active:t.activeTags.includes(e.id)},on:{toggle:function(n){return t.toggleTag(e.id)},remove:function(n){return t.removeTag(e)}}})})),t.$root.ppdToken&&!t.editTags?n("v-card",{staticClass:"blog-tag pl-3 pr-4",on:{click:function(e){t.editTags=!0}}},[n("v-icon",{staticClass:"mr-2",staticStyle:{height:"14px"},domProps:{textContent:t._s(t.mdiPlus)}}),n("span",{domProps:{textContent:t._s("Добавить")}})],1):t._e(),t.editTags?n("v-flex",{staticClass:"pt-4",attrs:{xs12:""}},[n("v-text-field",{staticClass:"px-1 mb-2",staticStyle:{width:"400px"},attrs:{solo:"","hide-details":"",label:"Добавить теги через запятую"},model:{value:t.newTags,callback:function(e){t.newTags=e},expression:"newTags"}}),n("v-layout",[n("v-card",{staticClass:"blog-tag active",domProps:{textContent:t._s("Сохранить")},on:{click:function(e){return t.saveTags()}}}),n("v-card",{staticClass:"blog-tag",domProps:{textContent:t._s("Отмена")},on:{click:function(e){t.newTags="",t.editTags=!1}}})],1)],1):t._e()],2),t.editSocs?t._e():n("v-layout",{staticStyle:{"min-width":"288px"},attrs:{column:"","align-end":""}},[n("v-layout",{class:{"mt-6":t.$vuetify.breakpoint.smAndDown},staticStyle:{"min-width":"288px",height:"36px","margin-left":"12px"},attrs:{"align-center":""}},[n("div",{staticStyle:{"font-weight":"500","font-size":"17px","margin-right":"12px"},domProps:{textContent:t._s("Мы в соц.сетях")}}),t._l(t.socials,(function(t,e){return n("a",{key:e,staticStyle:{width:"26px",height:"26px",margin:"0 2px"},attrs:{href:t.url,target:"_blank"}},[n("img",{staticStyle:{width:"26px",height:"26px"},attrs:{src:t.image}})])}))],2),t.$root.ppdToken?n("v-layout",{attrs:{"justify-center":""}},[t.$root.ppdToken&&!t.editSocs?n("v-card",{staticClass:"blog-tag active",domProps:{textContent:t._s("Изменить ссылки")},on:{click:function(e){t.editSocs=!0}}}):t._e()],1):t._e()],1),t.$root.ppdToken&&t.editSocs?n("v-flex",{attrs:{xs12:""}},[t._l(t.socials,(function(e,i){return n("v-layout",{key:i,staticClass:"my-2",attrs:{"align-center":""}},[n("img",{staticClass:"ml-1 mr-2",staticStyle:{width:"26px",height:"26px"},attrs:{src:e.image}}),n("v-text-field",{attrs:{"hide-details":"",solo:""},model:{value:e.url,callback:function(n){t.$set(e,"url",n)},expression:"soc.url"}})],1)})),n("v-layout",[n("v-card",{staticClass:"blog-tag active",domProps:{textContent:t._s("Сохранить")},on:{click:function(e){return t.saveSocs()}}}),n("v-card",{staticClass:"blog-tag",domProps:{textContent:t._s("Отмена")},on:{click:function(e){t.editSocs=!1}}})],1)],2):t._e()],1)},Me=[],Ae=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("v-card",{staticClass:"blog-tag",class:{active:t.active},on:{click:function(e){return t.$emit("toggle")}}},[n("span",{domProps:{textContent:t._s(t.tag.title)}}),t.$root.ppdToken?n("v-icon",{staticClass:"ml-1",staticStyle:{position:"absolute",right:"0px",top:"0px"},attrs:{size:"18",color:t.active?"white":""},domProps:{textContent:t._s(t.mdiClose)},on:{click:function(e){return t.$emit("remove")}}}):t._e()],1)},Ie=[];function Ne(t){return Ne="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ne(t)}function Fe(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Le(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&He(t,e)}function He(t,e){return He=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},He(t,e)}function Be(t){var e=qe();return function(){var n,i=ze(t);if(e){var o=ze(this).constructor;n=Reflect.construct(i,arguments,o)}else n=i.apply(this,arguments);return Ve(this,n)}}function Ve(t,e){return!e||"object"!==Ne(e)&&"function"!==typeof e?Ue(t):e}function Ue(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function qe(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}function ze(t){return ze=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},ze(t)}var We=function(t){Le(n,t);var e=Be(n);function n(){var t;return Fe(this,n),t=e.apply(this,arguments),t.mdiClose=s["e"],t}return n}(it["c"]);Object(at["a"])([Object(it["b"])(Object)],We.prototype,"tag",void 0),Object(at["a"])([Object(it["b"])(Boolean)],We.prototype,"active",void 0),We=Object(at["a"])([it["a"]],We);var Ye=We,Ke=Ye,Ge=Object(xt["a"])(Ke,Ae,Ie,!1,null,null,null),Qe=Ge.exports;function Je(t){return Je="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Je(t)}function Xe(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Ze(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function tn(t,e,n){return e&&Ze(t.prototype,e),n&&Ze(t,n),t}function en(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&nn(t,e)}function nn(t,e){return nn=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},nn(t,e)}function on(t){var e=cn();return function(){var n,i=sn(t);if(e){var o=sn(this).constructor;n=Reflect.construct(i,arguments,o)}else n=i.apply(this,arguments);return rn(this,n)}}function rn(t,e){return!e||"object"!==Je(e)&&"function"!==typeof e?an(t):e}function an(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function cn(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}function sn(t){return sn=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},sn(t)}Ut()(Ge,{VCard:qt["a"],VIcon:Pe["a"]});var ln=function(t){en(i,t);var e=on(i);function i(){var t;return Xe(this,i),t=e.apply(this,arguments),t.mdiPlus=s["h"],t.tags=[{id:1,title:"#название рубрики"},{id:2,title:"#ОСАГО"},{id:3,title:"#страхование"},{id:4,title:"#о компании"},{id:5,title:"#полисы"},{id:6,title:"#обновления"}],t.activeTags=[1,3,5],t.editTags=!1,t.editSocs=!1,t.newTags="",t.socials=[{url:"https://tele.gg/joinchat/AAAAAE2b6VJSXwGX3WY7nw",image:n("e5cf")},{url:"https://www.facebook.com/Pampadu.ru/",image:n("beb8")},{url:"https://vk.com/avto_yslyga",image:n("e790")},{url:"https://www.instagram.com/pampadu.ru/",image:n("c226")},{url:"https://www.youtube.com/channel/UC0SeTdHMfY67ku8e7m-GMTw",image:n("0030")}],t}return tn(i,[{key:"toggleTag",value:function(t){this.activeTags.includes(t)?this.activeTags.remove(this.activeTags.indexOf(t)):this.activeTags.push(t)}},{key:"saveTags",value:function(){var t=this,e=this.newTags.split(",");e.forEach((function(e){e=e.replace(" ","").replace("#","");var n=t.tags.length+1;t.tags.push({id:n,title:"#".concat(e)})})),this.newTags="",this.editTags=!1}},{key:"removeTag",value:function(t){var e=this.tags.map((function(t){return t.id})).indexOf(t.id);this.tags.remove(e),this.activeTags.remove(this.activeTags.indexOf(t.id))}},{key:"saveSocs",value:function(){this.editSocs=!1}}]),i}(it["c"]);ln=Object(at["a"])([Object(it["a"])({components:{BlogTagCard:Qe}})],ln);var un=ln,fn=un,dn=(n("0d4a"),n("8654")),pn=Object(xt["a"])(fn,De,Me,!1,null,null,null),mn=pn.exports;Ut()(pn,{VCard:qt["a"],VFlex:se["a"],VIcon:Pe["a"],VLayout:Wt["a"],VTextField:dn["a"]});var hn=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("v-layout",{staticClass:"ppd-container",attrs:{column:"","align-center":""}},[t.$root.ppdToken?n("v-layout",{staticClass:"w-100",attrs:{"align-center":""}},[n("span",{domProps:{textContent:t._s("Показать новости:")}}),n("v-btn-toggle",{staticClass:"ml-4",attrs:{multiple:""},model:{value:t.filter.statuses,callback:function(e){t.$set(t.filter,"statuses",e)},expression:"filter.statuses"}},[n("v-btn",[n("span",{domProps:{textContent:t._s("Опубликованные")}})]),n("v-btn",[n("span",{domProps:{textContent:t._s("Черновики")}})]),n("v-btn",[n("span",{domProps:{textContent:t._s("Удалённые")}})])],1),n("v-spacer"),n("v-card",{staticClass:"blog-tag active",attrs:{to:{name:"edit",params:{id:"new"}}}},[n("v-icon",{staticClass:"mr-2",attrs:{color:"white"},domProps:{textContent:t._s(t.mdiPlus)}}),n("span",{staticClass:"white--text",domProps:{textContent:t._s("Написать новую")}})],1)],1):t._e(),n("Pagination",{staticClass:"w-100 mb-4",attrs:{filter:t.filter,itemsNumber:110}}),n("ArticlesList",{attrs:{articles:t.articles.pre,listKey:"t"}}),n("v-flex",{staticClass:"w-100 my-6"},[n("div",{staticClass:"wi-regnow"},[n("div",{staticClass:"wi-regnow-inner"},[n("div",{directives:[{name:"show",rawName:"v-show",value:t.$vuetify.breakpoint.mdAndUp,expression:"$vuetify.breakpoint.mdAndUp"}],staticClass:"wi-regnow-side",domProps:{innerHTML:t._s(" ")}}),n("div",{staticClass:"wi-regnow-center"},[n("span",{staticClass:"h3",domProps:{textContent:t._s("Зарегистрируйтесь и получите")}}),n("div",{staticClass:"mt-1",staticStyle:{"font-family":"Roboto"}},[t._v(" доступ к бесплатным сервисам и 12 страховым компаниям ")])]),n("div",{staticClass:"wi-regnow-side"},[n("zond-btn",{staticClass:"btn inverted",staticStyle:{"min-width":"45px","min-height":"44px"},domProps:{textContent:t._s("Зарегистрироваться")}})],1)])])]),n("ArticlesList",{attrs:{articles:t.articles.post,listKey:"b"}}),n("Pagination",{staticClass:"w-100 mt-4",attrs:{filter:t.filter,itemsNumber:110}}),t.isEnd?[n("v-layout",{staticClass:"w-100 my-4",attrs:{"align-center":""}},[n("v-divider"),n("span",{staticClass:"mx-4 grey--text",domProps:{textContent:t._s("Вы добрались до конца")}}),n("v-divider")],1),n("div",{staticClass:"btn",staticStyle:{margin:"0px 0 40px","text-align":"center",cursor:"pointer"},on:{click:function(e){return t.scrollUp()}}},[n("v-icon",{staticClass:"mr-2",attrs:{color:"white"},domProps:{textContent:t._s(t.mdiArrowUp)}}),n("span",{domProps:{textContent:t._s("Подняться вверх")}})],1)]:n("div",{staticClass:"btn",staticStyle:{margin:"36px 0 60px",width:"213px","text-align":"center",cursor:"pointer"},on:{click:function(e){t.isEnd=!0}}},[n("span",{domProps:{textContent:t._s("Показать ещё")}})])],2)},gn=[],vn=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("v-layout",{staticClass:"pagination",attrs:{"align-center":"","justify-end":""}},[n("span",{staticClass:"items-number",domProps:{textContent:t._s(t.text)}}),t.showPrev?n("svg",{staticClass:"px-1 r90",staticStyle:{height:"26px",width:"34px",cursor:"pointer"},attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",role:"img","aria-hidden":"true",fill:"#8d9ba0"},on:{click:function(e){--t.pfilter.pageNumber}}},[n("path",{attrs:{d:t.chevron}})]):n("div",{staticClass:"btn-space",class:{small:t.$vuetify.breakpoint.lgAndUp},domProps:{innerHTML:t._s(" ")}}),t.showNext?n("svg",{staticClass:"px-1 r-90",staticStyle:{height:"26px",width:"34px",cursor:"pointer"},attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",role:"img","aria-hidden":"true",fill:"#8d9ba0"},on:{click:function(e){++t.pfilter.pageNumber}}},[n("path",{attrs:{d:t.chevron}})]):n("div",{staticStyle:{width:"14px",height:"14px"}}),n("v-spacer"),n("span",{staticClass:"lines-text",domProps:{textContent:t._s("Записей на странице")}}),n("v-select",{staticClass:"pagination-select mt-0 pt-0 pl-4",attrs:{"hide-details":"","single-line":"",multiple:!1,items:[11,22,44],"menu-props":{offsetY:!0}},model:{value:t.pfilter.pageSize,callback:function(e){t.$set(t.pfilter,"pageSize",e)},expression:"pfilter.pageSize"}})],1)},yn=[];function bn(t){return bn="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},bn(t)}function wn(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function xn(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function Cn(t,e,n){return e&&xn(t.prototype,e),n&&xn(t,n),t}function Sn(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&kn(t,e)}function kn(t,e){return kn=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},kn(t,e)}function On(t){var e=En();return function(){var n,i=Tn(t);if(e){var o=Tn(this).constructor;n=Reflect.construct(i,arguments,o)}else n=i.apply(this,arguments);return _n(this,n)}}function _n(t,e){return!e||"object"!==bn(e)&&"function"!==typeof e?Pn(t):e}function Pn(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function En(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}function Tn(t){return Tn=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},Tn(t)}var jn=function(t){Sn(n,t);var e=On(n);function n(){var t;return wn(this,n),t=e.apply(this,arguments),t.chevron=s["c"],t}return Cn(n,[{key:"onItemsNumberChanged",value:function(t){if(t)while(t<(this.pfilter.pageNumber-1)*this.pfilter.pageSize+1)this.pfilter.pageNumber--}},{key:"text",get:function(){var t,e=null!==(t=this.itemsNumber)&&void 0!==t?t:"",n="".concat(this.itemsStart,"-").concat(this.itemsEnd," из ").concat(e);return n}},{key:"pfilter",get:function(){return this.filter},set:function(t){this.$emit("update:filter",t)}},{key:"itemsStart",get:function(){return(this.pfilter.pageNumber-1)*this.pfilter.pageSize+1}},{key:"itemsEnd",get:function(){return(this.pfilter.pageNumber-1)*this.pfilter.pageSize+this.pfilter.pageSize}},{key:"showPrev",get:function(){return!(this.pfilter.pageNumber-1<1)}},{key:"showNext",get:function(){return!(this.pfilter.pageNumber*this.pfilter.pageSize+1>this.itemsNumber)}}]),n}(it["c"]);Object(at["a"])([Object(it["b"])()],jn.prototype,"filter",void 0),Object(at["a"])([Object(it["b"])({default:0})],jn.prototype,"itemsNumber",void 0),Object(at["a"])([Object(it["d"])("itemsNumber")],jn.prototype,"onItemsNumberChanged",null),jn=Object(at["a"])([it["a"]],jn);var Rn=jn,$n=Rn,Dn=(n("399b"),n("b974")),Mn=Object(xt["a"])($n,vn,yn,!1,null,null,null),An=Mn.exports;function In(t){return In="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},In(t)}function Nn(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function Fn(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function Ln(t,e,n){return e&&Fn(t.prototype,e),n&&Fn(t,n),t}function Hn(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&Bn(t,e)}function Bn(t,e){return Bn=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},Bn(t,e)}function Vn(t){var e=zn();return function(){var n,i=Wn(t);if(e){var o=Wn(this).constructor;n=Reflect.construct(i,arguments,o)}else n=i.apply(this,arguments);return Un(this,n)}}function Un(t,e){return!e||"object"!==In(e)&&"function"!==typeof e?qn(t):e}function qn(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function zn(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}function Wn(t){return Wn=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},Wn(t)}Ut()(Mn,{VLayout:Wt["a"],VSelect:Dn["a"],VSpacer:Yt["a"]});var Yn=function(t){Hn(i,t);var e=Vn(i);function i(){var t;return Nn(this,i),t=e.apply(this,arguments),t.mdiArrowUp=s["a"],t.mdiPlus=s["h"],t.isEnd=!1,t.filter={pageNumber:1,pageSize:11,isAscSort:!0,sortField:"creationDate",statuses:[]},t}return Ln(i,[{key:"scrollUp",value:function(){document.querySelector(".blog-tags").scrollIntoView({behavior:"smooth"})}},{key:"articles",get:function(){var t={tags:["#страхование","#финансы","#финансы","#финансы"],image:n("52a2"),title:"Началась у нас зелёная полоса/ итоги бюджета за 2 декабря",preview:"Так началась у нас зелёная полоса. Почему зелёная? Потому что те дни, когда нет у нас расходов, выделяю зелёным цветом.",author:{img:n("7d93"),name:"Жанна Шмелева"},creationDate:new Date,views:2788,emphasis:!1},e={tags:["#страхование"],image:n("9d57"),title:"Ускорение, упрощение и урезание рисков – тенденции в каско для юр.лиц – тенденции в каско для юр.лиц",preview:"Каско для юридических лиц и ИП пользуется растущим спросом. Страховщики готовы бороться за корпоративного страхователя ценами и технологиями.",author:{img:n("7d93"),name:"Жанна Шмелева"},creationDate:new Date,views:2788,emphasis:!1},i={tags:["#страхование","#финансы"],image:n("2500"),title:"Страховка для оформления шенгенской визы",preview:"Так началась у нас зелёная полоса. Почему зелёная? Потому что те дни, когда нет у нас расходов, выделяю зелёным цветом.",author:{img:n("7d93"),name:"Жанна Шмелева"},creationDate:new Date,views:2788,emphasis:!1},o={tags:["#страхование","#финансы"],image:n("5b20"),title:"Через несколько лет страховки будут бесплатными",preview:"Совсем недавно Майкл О'Лири из Rynair заявил о том, что в скором будущем полёты на некоторых направлениях станут бесплатными.",author:{img:n("7d93"),name:"Жанна Шмелева"},creationDate:new Date,views:2788,emphasis:!1},r={tags:["#страхование","#финансы"],image:n("4283"),title:"Через несколько лет страховки будут бесплатными",preview:"Совсем недавно Майкл О'Лири из Rynair заявил о том, что в скором будущем полёты на некоторых направлениях станут бесплатными.",author:{img:n("7d93"),name:"Жанна Шмелева"},creationDate:new Date,views:2788,emphasis:!0},a=[t,e,i,o,t,e,r,t,e,i,o],c=4,s=this.$vuetify.breakpoint;s.xsOnly&&(c=1),s.smOnly&&(c=2),s.mdOnly&&(c=3);var l={pre:a.slice(0,c),post:a.slice(c)};return l}}]),i}(it["c"]);Yn=Object(at["a"])([Object(it["a"])({components:{ArticlesList:ue,Pagination:An}})],Yn);var Kn=Yn,Gn=Kn,Qn=n("a609"),Jn=Object(xt["a"])(Gn,hn,gn,!1,null,null,null),Xn=Jn.exports;function Zn(t){return Zn="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Zn(t)}function ti(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function ei(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&ni(t,e)}function ni(t,e){return ni=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},ni(t,e)}function ii(t){var e=ai();return function(){var n,i=ci(t);if(e){var o=ci(this).constructor;n=Reflect.construct(i,arguments,o)}else n=i.apply(this,arguments);return oi(this,n)}}function oi(t,e){return!e||"object"!==Zn(e)&&"function"!==typeof e?ri(t):e}function ri(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function ai(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}function ci(t){return ci=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},ci(t)}Ut()(Jn,{VBtn:Oe["a"],VBtnToggle:Qn["a"],VCard:qt["a"],VDivider:_e["a"],VFlex:se["a"],VIcon:Pe["a"],VLayout:Wt["a"],VSpacer:Yt["a"]});var si=function(t){ei(n,t);var e=ii(n);function n(){return ti(this,n),e.apply(this,arguments)}return n}(it["c"]);si=Object(at["a"])([Object(it["a"])({components:{BlogFirst:$e["a"],BlogTags:mn,ArticlesContainer:Xn}})],si);var li=si,ui=li,fi=Object(xt["a"])(ui,je,Re,!1,null,null,null),di=fi.exports,pi=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("div",[t.$vuetify.breakpoint.smAndDown?i("div",[i("v-layout",{staticClass:"py-2",attrs:{"align-center":"","justify-space-between":""}},[i("v-icon",{staticClass:"mx-4",attrs:{size:"30",color:"#000"},domProps:{textContent:t._s(t.mdiChevron)}}),i("span",{staticStyle:{"font-family":"Montserrat","font-size":"16px"},domProps:{textContent:t._s("Блог")}}),i("v-icon",{staticClass:"mx-4",attrs:{size:"30",color:"#0000"},domProps:{textContent:t._s(t.mdiChevron)}})],1),i("v-divider")],1):t._e(),i("div",{staticClass:"ppd-container mt-0"},[t.$vuetify.breakpoint.smAndDown?t._e():[i("v-divider"),i("div",{staticClass:"article-crumbs"},[i("a",{attrs:{href:"https://pampadu.ru"},domProps:{textContent:t._s("Главная")}}),i("span",{staticClass:"crumb-divider",domProps:{textContent:t._s("—")}}),i("router-link",{attrs:{to:{name:"main"}},domProps:{textContent:t._s("Блог")}}),i("span",{staticClass:"crumb-divider",domProps:{textContent:t._s("—")}}),i("router-link",{attrs:{to:{name:"article",params:{id:t.article.id}}},domProps:{textContent:t._s(t.article.title)}}),i("span",{staticClass:"crumb-divider",domProps:{textContent:t._s("—")}}),i("span",{domProps:{textContent:t._s("Редактирование")}})],1),i("v-divider"),t.$root.ppdToken?[i("div",{staticClass:"article-crumbs"},[i("v-btn",{staticClass:"mx-2",attrs:{color:"success"},on:{click:function(e){return t.saveArticle()}}},[i("span",{staticClass:"white--text",domProps:{textContent:t._s("Сохранить")}})]),i("v-btn",{staticClass:"mx-2",attrs:{color:"error"}},[i("span",{staticClass:"white--text",domProps:{textContent:t._s("Назад")}})])],1),i("v-divider")]:t._e()],i("v-layout",{attrs:{column:t.$vuetify.breakpoint.smAndDown}},[i("div",{staticStyle:{flex:"1 0 auto"}},[i("div",{staticClass:"article-title editable-header active",attrs:{contenteditable:""},domProps:{textContent:t._s(t.article.title)}}),t.$vuetify.breakpoint.smAndDown?t._e():i("div",{staticClass:"h5 article-preview editable-header active",attrs:{contenteditable:""},domProps:{textContent:t._s(t.article.preview)}})]),i("v-img",{staticStyle:{flex:"0 1 auto"},attrs:{gradient:t.$vuetify.breakpoint.smAndDown?"":"to right, #ffff 5%, #fff0 50%",contain:"",position:t.$vuetify.breakpoint.smAndDown?"center":"right center","max-height":"360",src:n("4283")}}),t.$vuetify.breakpoint.smAndDown?i("h2",{staticClass:"h5 article-preview",domProps:{textContent:t._s(t.article.preview)}}):t._e()],1)],2),i("v-layout",{staticStyle:{padding:"0 16px","max-width":"1062px",margin:"auto"},attrs:{column:t.$vuetify.breakpoint.smAndDown,"justify-space-between":""}},[i("div",{staticClass:"ppd-article-container"},[i("span",{staticClass:"bg-l"}),i("span",{staticClass:"bg-r"}),i("YimoVueEditor",{staticClass:"ppd-article",attrs:{config:t.config},model:{value:t.article.content,callback:function(e){t.$set(t.article,"content",e)},expression:"article.content"}}),i("div",{staticClass:"btn outline px-5 mt-4",on:{click:function(e){return t.$router.push({name:"main"})}}},[i("v-icon",{staticStyle:{"margin-top":"-2px","margin-left":"-8px","margin-right":"8px"},attrs:{size:"26",color:"#000"},domProps:{textContent:t._s(t.mdiChevron)}}),i("div",{staticStyle:{display:"inline-block"},domProps:{textContent:t._s("Назад к списку статей")}})],1)],1),i("div",{staticClass:"article-right"},[i("v-layout",{staticClass:"article-right-card",attrs:{"align-center":""}},[i("v-img",{staticClass:"mr-3",staticStyle:{flex:"0 0 40px"},attrs:{height:"40",width:"40",src:t.article.author.img}}),i("v-layout",{staticStyle:{width:"100%",height:"40px"},attrs:{column:"","align-center":"","justify-center":""}},[i("div",{staticClass:"article-author",domProps:{textContent:t._s(t.article.author.name)}})])],1),i("div",{staticClass:"article-right-card pa-0"},[i("v-select",{attrs:{label:"Теги","hide-details":"",outlined:"",chips:"",multiple:"",items:t.availableTags},model:{value:t.article.tags,callback:function(e){t.$set(t.article,"tags",e)},expression:"article.tags"}})],1)],1)])],1)},mi=[],hi=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"yimo-vue-editor",attrs:{id:t.editorId}})},gi=[],vi=n("320c"),yi=n.n(vi),bi=n("12d4"),wi=n.n(bi),xi={name:"yimo-vue-editor",props:{value:{type:String},config:{type:Object,default:null},uploadHandler:{type:Function},globalOptions:{type:Object,required:!1,default:function(){return{}}}},data:function(){return{editorId:"editor_"+Date.now()+~~(1e3*Math.random()),currentValue:null,currentConfig:{},_currentEditor:null,hasInit:!1}},watch:{value:{handler:function(t){this.setContent(t)},immediate:!0},currentValue:function(t){var e=this,n=t;n!==this._currentEditor.$txt.html()&&this.$nextTick((function(){e._currentEditor&&e._currentEditor.$txt&&e._currentEditor.$txt.html(n)}))}},methods:{setContent:function(t){var e=this,n=function(){t!==e.currentValue&&(e.currentValue=t)};this.hasInit?n():this.$nextTick((function(){e.renderEditor(),n()}))},asyncValue:function(t){this.$emit("input",t).replace(/ /g," ")},renderEditor:function(){var t=this;if(t.hasInit)return null;var e=new wi.a(this.editorId);t.editorConfig(e),t.imageConfig(e),this.currentConfig=yi()(e.config,this.globalOptions.config,t.config),t.hasInit=!0,e.onchange=function(){var e=t._currentEditor.$txt.html();t.asyncValue(e)},e.create(),this._currentEditor=e},editorConfig:function(t){t.config.menus=["source","|","bold","underline","italic","strikethrough","eraser","forecolor","bgcolor","|","quote","fontfamily","fontsize","head","unorderlist","orderlist","alignleft","aligncenter","alignright","|","link","unlink","table","|","img","video","insertcode","|","undo","redo","fullscreen"],t.config.withCredentials=!1,t.config.uploadImgFileName="file",t.config.uploadImgUrl="/mockserver/api/upload",t.config.uploadParams={},t.config.uploadHeaders={},t.config.zindex=100,t.config.pasteFilter=!0,t.config.menuFixed=!1},imageConfig:function(t){var e=this;function n(t,e){var n=this.$txt.find('img[alt="'+this.config.lang.uploadPlaceTxt+t+'"]');n.after("【"+e+t+"】"),n.remove(),this.$txt.change()}t.config.uploadImgFns.onload=function(t,i,o){if(200===i.status){var r=e._uploadHandler("success",t),a=this.$txt.find('img[alt="'+this.config.lang.uploadPlaceTxt+o+'"]');r?a.length>0?(a.attr("src",r).removeAttr("alt"),this.$txt.change()):this.command(null,"insertHtml",'<img src="'+r+'"/>'):n.call(this,o,this.config.lang.uploadErrorPlaceTxt)}else{var c=e._uploadHandler("error");n.call(this,o,c||this.config.lang.uploadErrorPlaceTxt)}},t.config.uploadImgFns.ontimeout=function(t,i){var o=e._uploadHandler("timeout");n.call(this,i,o||this.config.lang.uploadTimeoutPlaceTxt)},t.config.uploadImgFns.onerror=function(t,i){var o=e._uploadHandler("error");n.call(this,i,o||this.config.lang.uploadErrorPlaceTxt)}},_uploadHandler:function(t,e){var n=this;return n.uploadHandler?n.uploadHandler(t,e):n.globalOptions.uploadHandler?n.globalOptions.uploadHandler(t,e):"success"===t?e:null}}},Ci=xi,Si=(n("cf21"),Object(xt["a"])(Ci,hi,gi,!1,null,null,null)),ki=Si.exports,Oi={bold:"Жирный",underline:"Подчеркивание",italic:"Курсив",forecolor:"Цвет текста",bgcolor:"Цвет фона",strikethrough:"Перечеркнуть",eraser:"Стерка",source:"Посмотреть код",quote:"Цитата",fontfamily:"Шрифт",fontsize:"Размер текста",head:"Заголовок",orderlist:"Упорядоченный список",unorderlist:"неупорядоченный список",alignleft:"Выровнить по левому краю",aligncenter:"Выровнить по центру",alignright:"Выровнить по правому краю",link:"Ссылка",linkTarget:"target ссылки",text:"Текст",submit:"Отправить",cancel:"Закрыть",unlink:"Убрать ссылку",table:"Таблица",emotion:"Смайлики",img:"Картинка",uploadImg:"Загрузить",linkImg:"Ссылка",video:"Видео",width:"Ширина",height:"Высота",location:"Позиция",loading:"Загрузка",searchlocation:"Поиск",dynamicMap:"Динамика",clearLocation:"Отчистить",langDynamicOneLocation:"Только одна локация на динамической карте",insertcode:"Код вставки",undo:"Отмена",redo:"Вернуть",fullscreen:"Во весь экран",openLink:"Открытая ссылка"},_i={"#5e36db":"primary","#0060a9":"secondary","#ab54ff":"accent","#4578FF":"electric","#7EC275":"success","#FDE126":"warning","#F83737":"error","#4C7DFF":"info","#7d8d93":"cookie","#6565CE":"help","#7245FF":"prime","#4D4D4D":"grey","#D8D8D8":"lightgrey","#F2F5FF":"notwhite","#ffffff":"white","#000000":"black","#880000":"","#800080":"","#ff0000":"","#ff00ff":"","#000080":"","#0000ff":"","#00ffff":"","#008080":"","#008000":"","#808000":"","#00ff00":"","#ffcc00":"","#808080":"","#c0c0c0":""},Pi=["Roboto","Montserrat","Arial","Times New Roman"],Ei={1:"12px",2:"13px",3:"14px",4:"16px",5:"18px",6:"24px",7:"32px",8:"48px"},Ti={printLog:!1,lang:Oi,familys:Pi,fontsizes:Ei,colors:_i,menus:["bold","underline","italic","strikethrough","eraser","forecolor","bgcolor","|","quote","fontfamily","fontsize","head","unorderlist","orderlist","alignleft","aligncenter","alignright","|","link","unlink","table","|","img","video","insertcode","|","undo","redo"],withCredentials:!1,uploadImgFileName:"file",uploadImgUrl:" http://localhost:5550/api/File/SaveFileFromEditor",uploadParams:{},uploadHeaders:{},zindex:100,pasteFilter:!0,menuFixed:!1};function ji(t){return ji="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ji(t)}function Ri(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function $i(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function Di(t,e,n){return e&&$i(t.prototype,e),n&&$i(t,n),t}function Mi(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&Ai(t,e)}function Ai(t,e){return Ai=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},Ai(t,e)}function Ii(t){var e=Li();return function(){var n,i=Hi(t);if(e){var o=Hi(this).constructor;n=Reflect.construct(i,arguments,o)}else n=i.apply(this,arguments);return Ni(this,n)}}function Ni(t,e){return!e||"object"!==ji(e)&&"function"!==typeof e?Fi(t):e}function Fi(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Li(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}function Hi(t){return Hi=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},Hi(t)}var Bi=function(t){Mi(i,t);var e=Ii(i);function i(){var t;return Ri(this,i),t=e.apply(this,arguments),t.mdiClose=s["e"],t.config=Ti,t.mdiChevron=s["d"],t.article={id:"article.id",tags:[],title:"",preview:"",author:{img:"",name:""},creationDate:new Date,views:0,content:""},t.availableTags=["#страхование","#финансы","#дополнительныйтег","#лайфхак","#ОСАГО"],t}return Di(i,[{key:"created",value:function(){var t=function(t){return"<tr>\n <th>23344</th>\n <td>05.2019</td>\n <td>".concat(t,"</td>\n <td>13.191 руб.</td>\n </tr>")},e=function(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:6,n="",i=0;i<e;i++){var o=2==i?"Можно настроить программу страхования под себя. Внимание к каждому клиенту. С нами надёжно. Без посещения офиса!":"Команда Pampadu";n+=t(o)}return n},i='\n <h3>Что такое страховка от коронавируса</h3>\n <p>Напомним, что полис от COVID-19 не имеет ничего общего с туристическим или другими видами страхования. Это самостоятельный продукт, который обеспечивает застрахованному лицу финансовую защиту в случае заболевания коронавирусом.</p>\n <p>То есть по данной страховке вы получаете только денежные выплаты, но никак не лечение. Поэтому в данном случае страховая не оказывает никакую помощь больному в виде предоставления медицинских услуг. Лечение вы получаете по полису ОМС.</p>\n <h3>Какую страховку от коронавируса лучше выбрать</h3>\n <p>На сегодняшний день самым выгодным полисом является АльфаСтрахование. Данная страховка представлена на нашем сайте.</p>\n <ppd-alert type="success">\n Почему стоит оформить страховку? Мы работаем напрямую со страховыми компаниями, полисы которых представлены у нас на сайте. Но в отличие от самих компаний мы предоставляем скидку 15% на любую страховку. Все промокоды в данной статье.\n </ppd-alert>\n <p>У АльфаСтрахования хорошие условия страхования: выплаты осуществляются даже при пандемии, карантине, при чрезвычайном положении. Также немаловажным фактором является возраст страхования – до 70 лет. Высокая цена полиса оправдывает сумму компенсации – 50 и 100 тыс. руб.</p>\n <p>Из более бюджетных вариантов лучше выбрать полис от Гайде. Данная страховка также выплачивает деньги при объявлении пандемии или карантина. Возраст застрахованного может быть любым.</p>\n <img src="https://i.imgur.com/LOgcKb6.png">\n <p>У АльфаСтрахования хорошие условия страхования: выплаты осуществляются даже при пандемии, карантине, при чрезвычайном положении. Также немаловажным фактором является возраст страхования – до 70 лет. Высокая цена полиса оправдывает сумму компенсации – 50 и 100 тыс. руб.</p>\n <p>Из более бюджетных вариантов лучше выбрать полис от Гайде. Данная страховка также выплачивает деньги при объявлении пандемии или карантина. Возраст застрахованного может быть любым.</p>\n <div class="table-container">\n <table>\n <thead>\n <tr>\n <th>Колонка</th>\n <th>Колонка</th>\n <th>Колонка</th>\n <th>Колонка</th>\n </tr>\n </thead>\n <tbody>'.concat(e(6),"</tbody>\n </table>\n </div>\n <h3>Маркированный список</h3>\n <ul>\n <li>Автоматическое подтягивание данных по гос. номеру</li>\n <li>Автоматический поиск техосмотра</li>\n <li>Проверка КБМ по каждому водителю</li>\n </ul>\n <h3>Нумерованный список</h3>\n <ol>\n <li>Автоматическое подтягивание данных по гос. номеру</li>\n <li>Автоматический поиск техосмотра</li>\n <li>Проверка КБМ по каждому водителю</li>\n </ol>\n ");this.article={tags:["#страхование"],title:"Страховка от коронавируса: цены, выплаты, условия страхования",preview:"В одной из наших статей мы уже рассказывали о том, что такое страхование от коронавируса и как оно работает. В данной статье сравним цены и условия полисов от COVID-19 разных компаний.",author:{img:n("7d93"),name:"Жанна Шмелева"},creationDate:new Date,views:2788,content:i,id:"article.id"}}},{key:"saveArticle",value:function(){this.$router.push({name:"article",params:{id:this.article.id}})}}]),i}(it["c"]);Bi=Object(at["a"])([Object(it["a"])({components:{ViewsIcon:St,YimoVueEditor:ki}})],Bi);var Vi=Bi,Ui=Vi,qi=Object(xt["a"])(Ui,pi,mi,!1,null,null,null),zi=qi.exports;Ut()(qi,{VBtn:Oe["a"],VDivider:_e["a"],VIcon:Pe["a"],VImg:zt["a"],VLayout:Wt["a"],VSelect:Dn["a"]});var Wi=function(t){return{id:t.params.id}},Yi=it["c"].component("router-view-proxy",{render:function(t){return t("router-view")}}),Ki=[{path:"",component:Yi,children:[{path:"",component:di,name:"main"},{path:"article/:id",component:Te,name:"article",props:Wi},{path:"edit/:id",component:zi,name:"edit",props:Wi}]}],Gi=Ki;function Qi(){return new nt["a"]({mode:"history",base:"/pampadu-blog/",routes:Gi,scrollBehavior:function(){var t=document.getElementById("app");t&&t.scrollIntoView()},linkActiveClass:"active"})}a["a"].use(nt["a"]);var Ji=n("0086"),Xi=n.n(Ji),Zi=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("v-app",{attrs:{id:"app"}},[n("BlogMain"),n("CarrotQuest")],1)},to=[],eo=n("0b7d"),no=n.n(eo),io=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div")},oo=[];function ro(t){return ro="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ro(t)}function ao(t,e,n,i,o,r,a){try{var c=t[r](a),s=c.value}catch(l){return void n(l)}c.done?e(s):Promise.resolve(s).then(i,o)}function co(t){return function(){var e=this,n=arguments;return new Promise((function(i,o){var r=t.apply(e,n);function a(t){ao(r,i,o,a,c,"next",t)}function c(t){ao(r,i,o,a,c,"throw",t)}a(void 0)}))}}function so(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function lo(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function uo(t,e,n){return e&&lo(t.prototype,e),n&&lo(t,n),t}function fo(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&po(t,e)}function po(t,e){return po=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},po(t,e)}function mo(t){var e=vo();return function(){var n,i=yo(t);if(e){var o=yo(this).constructor;n=Reflect.construct(i,arguments,o)}else n=i.apply(this,arguments);return ho(this,n)}}function ho(t,e){return!e||"object"!==ro(e)&&"function"!==typeof e?go(t):e}function go(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function vo(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}function yo(t){return yo=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},yo(t)}var bo=function(t){fo(n,t);var e=mo(n);function n(){var t;return so(this,n),t=e.apply(this,arguments),t.cqChat=null,t.cqInterval=null,t.kostyl=null,t}return uo(n,[{key:"created",value:function(){var t=co(m.a.mark((function t(){return m.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:case"end":return t.stop()}}),t)})));function e(){return t.apply(this,arguments)}return e}()},{key:"initCqChat",value:function(){var t=co(m.a.mark((function t(){var e=this;return m.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return console.log("initSqChat"),t.abrupt("return",new Promise((function(t,n){setTimeout((function(){e.cqInterval=setInterval((function(){var n;console.log("cqInterval works");var i=window.carrotquest;null!==(null===i||void 0===i||null===(n=i.messenger)||void 0===n?void 0:n.state)&&(console.log("cq.messenger exists, removing interval"),e.cqChat=window.carrotquest,e.br.mdAndDown&&e.setStateNo(),clearInterval(e.cqInterval),t())}),1e3)}),3e3)})));case 2:case"end":return t.stop()}}),t)})));function e(){return t.apply(this,arguments)}return e}()},{key:"onChatStateChange",value:function(t){"collapsed"==t&&this.setStateNo()}},{key:"onWidthChange",value:function(t){if(t)this.setStateNo();else{var e,n,i,o,r,a,c;if("opened"==(null===(e=this.cqChat)||void 0===e||null===(n=e.messenger)||void 0===n?void 0:n.state))null===(r=this.cqChat)||void 0===r||null===(a=r.messenger)||void 0===a||null===(c=a.toStateNo)||void 0===c||c.call(a);null===(i=this.cqChat)||void 0===i||null===(o=i.messenger)||void 0===o||o.toStateCollapsed()}}},{key:"onRoteChange",value:function(t){this.setStateNo()}},{key:"setStateNo",value:function(){this.br.mdAndDown&&this.cqChat&&this.cqChat.messenger.toStateNo()}},{key:"br",get:function(){return this.$vuetify.breakpoint}},{key:"chatState",get:function(){var t;return(null===(t=this.cqChat)||void 0===t?void 0:t.messenger)?this.cqChat.messenger.state:null}}]),n}(it["c"]);Object(at["a"])([Object(it["d"])("chatState")],bo.prototype,"onChatStateChange",null),Object(at["a"])([Object(it["d"])("br.mdAndDown")],bo.prototype,"onWidthChange",null),Object(at["a"])([Object(it["d"])("$route.path")],bo.prototype,"onRoteChange",null),bo=Object(at["a"])([it["a"]],bo);var wo=bo,xo=wo,Co=(n("8813"),Object(xt["a"])(xo,io,oo,!1,null,null,null)),So=Co.exports;function ko(t){return ko="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ko(t)}function Oo(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function _o(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function Po(t,e,n){return e&&_o(t.prototype,e),n&&_o(t,n),t}function Eo(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&To(t,e)}function To(t,e){return To=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},To(t,e)}function jo(t){var e=Do();return function(){var n,i=Mo(t);if(e){var o=Mo(this).constructor;n=Reflect.construct(i,arguments,o)}else n=i.apply(this,arguments);return Ro(this,n)}}function Ro(t,e){return!e||"object"!==ko(e)&&"function"!==typeof e?$o(t):e}function $o(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Do(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}function Mo(t){return Mo=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},Mo(t)}var Ao=function(t){Eo(n,t);var e=jo(n);function n(){var t;return Oo(this,n),t=e.apply(this,arguments),t.landingType=Object({NODE_ENV:"production",BASE_URL:"/pampadu-blog/"}).VUE_APP_COMPONENT,t.query=window.location.search,t}return Po(n,[{key:"created",value:function(){var t=window.location.href,e={AgentsMain:"agents",PartnersMain:"partners",WidgetsMain:"widgets",ScienceMain:"science",TruckMain:"trucks",BlogMain:"blog"},n=e[this.landingType];console.log("url:",t),console.log("landingType="+this.landingType+" "+n);localStorage.getItem("query");var i=t.split("".concat(n,"/"))[1],o=null;console.log("ref:",i),o=!i||0==i.length||i.startsWith("?")?"":i.split("?")[0],this.query?this.saveQuery(this.query):this.loadQuery(o),o?this.saveRef(o):this.loadRef(),this.$root.query=this.query,this.$root.zondScr=this.zondScr,this.$root.regLink=this.regLink}},{key:"mounted",value:function(){no()()}},{key:"saveQuery",value:function(t){console.log("saving query:",t),localStorage.setItem("query",t)}},{key:"loadQuery",value:function(t){console.log("loading query");var e=localStorage.getItem("query");console.log("query item:",e),e&&"null"!=e&&(this.query=e),t&&this.query.includes("refs")&&(this.query=this.removeQueryParam("refs",this.query))}},{key:"saveRef",value:function(t){console.log("saving ref",t),localStorage.setItem("ref",t),localStorage.setItem("refDate",(new Date).toISOString());var e=this.query.startsWith("?")?"&":"?";this.query=this.query+e+"refs=".concat(t)}},{key:"loadRef",value:function(){var t=localStorage.getItem("ref"),e=localStorage.getItem("refDate");if(console.log("loading ref...",t),t&&e)if(console.log("they exist in store"),"a1"!=t||this.lessThanDays(new Date(e),14)){console.log("not a1 or it's just in time!");var n=this.query.startsWith("?")?"&":"?";this.query=this.query+n+"refs=".concat(t)}else console.log("a1 or too old :("),localStorage.removeItem("ref"),localStorage.removeItem("refDate")}},{key:"removeQueryParam",value:function(t,e){if("undefined"!==typeof URLSearchParams){console.log("cleaning query param",t);var n=new URLSearchParams(this.query.split("?")[1]);return n.delete(t),"?"+n.toString()}return console.warn("URLSearchParams not supported"),e}},{key:"lessThanDays",value:function(t,e){var n=864e5*e,i=Date.now()-n;return t>i}},{key:"regLink",get:function(){var t;return"https://agents.pampadu.ru/#/register".concat(null!==(t=this.query)&&void 0!==t?t:"")}},{key:"pathNameMap",get:function(){return[{path:"/agents/osago-gruzoviki",name:"truck"},{path:"/agents",name:"agents"},{path:"/science",name:"science"},{path:"/webtools",name:"webtools"},{path:"/partners",name:"partners"},{path:"/blog",name:"blog"}]}},{key:"zondScr",get:function(){var t,e="ym(55127530, 'reachGoal', 'CONVKNOPOK');gtag_report_conversion('https://agents.pampadu.ru/#/register');ym(55127530, 'reachGoal', 'landing_registration');gtag('event', 'landing_registration', {'event_category' : 'landing_registration'});fbq('trackCustom', 'landing_registration');",n=window.location.pathname,i=null===(t=this.pathNameMap.find((function(t){return n.startsWith(t.path)})))||void 0===t?void 0:t.name;return i&&(e+="ym(55127530, 'reachGoal', 'landing_registration_".concat(i,"');\n gtag('event', 'landing_registration_").concat(i,"', {'event_category' : 'landing_registration'});\n fbq('trackCustom', 'landing_registration_").concat(i,"');")),e}}]),n}(it["c"]);Ao=Object(at["a"])([Object(it["a"])({components:{BlogMain:function(){return n.e("chunk-1d269d2f").then(n.bind(null,"8694"))},CarrotQuest:So}})],Ao);var Io=Ao,No=Io,Fo=(n("9993"),n("7496")),Lo=Object(xt["a"])(No,Zi,to,!1,null,null,null),Ho=Lo.exports;Ut()(Lo,{VApp:Fo["a"]});n("953f"),n("b3be"),n("4d21");var Bo=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("a",{staticClass:"btn text-center",attrs:{onclick:t.$root.zondScr,onauxclick:t.$root.zondScr,href:t.$root.regLink}},[t._t("default")],2)},Vo=[];function Uo(t){return Uo="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Uo(t)}function qo(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function zo(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&Wo(t,e)}function Wo(t,e){return Wo=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},Wo(t,e)}function Yo(t){var e=Qo();return function(){var n,i=Jo(t);if(e){var o=Jo(this).constructor;n=Reflect.construct(i,arguments,o)}else n=i.apply(this,arguments);return Ko(this,n)}}function Ko(t,e){return!e||"object"!==Uo(e)&&"function"!==typeof e?Go(t):e}function Go(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Qo(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}function Jo(t){return Jo=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},Jo(t)}var Xo=function(t){zo(n,t);var e=Yo(n);function n(){return qo(this,n),e.apply(this,arguments)}return n}(it["c"]);Xo=Object(at["a"])([it["a"]],Xo);var Zo=Xo,tr=Zo,er=Object(xt["a"])(tr,Bo,Vo,!1,null,null,null),nr=er.exports;a["a"].use(nt["a"]),a["a"].use(Xi.a),a["a"].component("zond-btn",nr),a["a"].config.productionTip=!1,new a["a"]({vuetify:u,store:et.original,router:Qi(),render:function(t){return t(Ho)},mounted:function(){try{document.dispatchEvent(new Event("render-event"))}catch(t){}},data:function(){return{zondScr:"",query:"",regLink:"",ppdToken:""}}}).$mount("#app")},cf21:function(t,e,n){"use strict";n("78bd")},cf4e:function(t,e,n){},d497:function(t,e,n){"use strict";n("50cc")},e5cf:function(t,e,n){t.exports=n.p+"img/tg.27b13b25.svg"},e790:function(t,e,n){t.exports=n.p+"img/vk.1377a292.svg"},e7c3:function(t,e,n){"use strict";var i=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"first-bg blog-first"},[n("div",{staticClass:"first-content"},[n("v-menu",{attrs:{disabled:!t.$root.ppdToken||t.isEditing,"open-on-hover":"",left:"","offset-x":"","max-width":"36","content-class":"no-overflow"},scopedSlots:t._u([{key:"activator",fn:function(e){var i=e.on;return[n("div",t._g({},i),[n(t.isEditing?"div":"h1",{tag:"component",staticClass:"h4 editable-header",class:{active:t.isEditing},attrs:{contenteditable:t.isEditing},domProps:{innerHTML:t._s(t.header)},on:{input:function(e){return t.editHeader=e.target.innerHTML}}}),n(t.isEditing?"div":"h5",{tag:"component",staticClass:"h5 mt-4 editable-header",class:{active:t.isEditing},attrs:{contenteditable:t.isEditing},domProps:{innerHTML:t._s(t.subheader)},on:{input:function(e){return t.editSubheader=e.target.innerHTML}}})],1)]}}])},[n("v-card",[n("v-icon",{attrs:{size:"36"},domProps:{textContent:t._s(t.mdiPen)},on:{click:function(e){return t.editHeaders()}}})],1)],1),t.isEditing?n("v-card",{staticClass:"mt-2",staticStyle:{width:"72px",height:"0px",overflow:"visible"}},[n("v-icon",{attrs:{color:"success",size:"36"},domProps:{textContent:t._s(t.mdiCheckBold)},on:{click:function(e){return t.saveHeaders()}}}),n("v-icon",{attrs:{color:"error",size:"36"},domProps:{textContent:t._s(t.mdiClose)},on:{click:function(e){t.isEditing=!1}}})],1):t._e()],1)])},o=[],r=n("9ab4"),a=n("94ed"),c=n("60a3");function s(t){return s="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},s(t)}function l(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function u(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,i.key,i)}}function f(t,e,n){return e&&u(t.prototype,e),n&&u(t,n),t}function d(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&p(t,e)}function p(t,e){return p=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},p(t,e)}function m(t){var e=v();return function(){var n,i=y(t);if(e){var o=y(this).constructor;n=Reflect.construct(i,arguments,o)}else n=i.apply(this,arguments);return h(this,n)}}function h(t,e){return!e||"object"!==s(e)&&"function"!==typeof e?g(t):e}function g(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function v(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}function y(t){return y=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},y(t)}var b=function(t){d(n,t);var e=m(n);function n(){var t;return l(this,n),t=e.apply(this,arguments),t.mdiPen=a["g"],t.mdiCheckBold=a["b"],t.mdiClose=a["f"],t.isEditing=!1,t.header="Заголовок для страницы со всеми записями в блоге",t.subheader="Рассказываем о страховании просто и понятно. Лайфхаки и последние тренды для наших подписчиков.",t.editHeader="",t.editSubheader="",t}return f(n,[{key:"editHeaders",value:function(){this.isEditing=!0,this.editHeader=this.header,this.editSubheader=this.subheader}},{key:"saveHeaders",value:function(){this.isEditing=!1,this.header=this.editHeader,this.subheader=this.editSubheader}},{key:"created",value:function(){}}]),n}(c["c"]);b=Object(r["a"])([c["a"]],b);var w=b,x=w,C=(n("1310"),n("2877")),S=n("6544"),k=n.n(S),O=n("b0af"),_=n("132d"),P=n("e449"),E=Object(C["a"])(x,i,o,!1,null,null,null);e["a"]=E.exports;k()(E,{VCard:O["a"],VIcon:_["a"],VMenu:P["a"]})}}); |