Comments – wpDiscuz - Version 7.0.2

Version Description

Download this release

Release Info

Developer AdvancedCoding
Plugin Icon 128x128 Comments – wpDiscuz
Version 7.0.2
Comparing to
See all releases

Code changes from version 7.0.1 to 7.0.2

assets/js/wpd-editor.js CHANGED
@@ -141,10 +141,10 @@ class WpdEditor {
141
  this.container = editor.container.id;
142
  }
143
  });
144
- editor.clipboard.addMatcher('PRE', (node, delta) => {
145
- var Delta = Quill.import('delta');
146
- return new Delta([{insert: this._htmlEntities(node.innerHTML), attributes: {'code-block': true}}]);
147
- });
148
  editor.clipboard.addMatcher('a', (node, delta) => {
149
  if (node.getAttribute("href") === node.innerHTML) {
150
  var Delta = Quill.import('delta');
@@ -175,11 +175,11 @@ class WpdEditor {
175
  return this.currentEditor;
176
  }
177
 
178
- _htmlEntities(str) {
179
- var txt = document.createElement('textarea');
180
- txt.innerHTML = str;
181
- return txt.value.replace(/<\!\-\-\?php/g, '<?php').replace(/\?\-\->/g, '?>').replace(/\-\-\->/g, '->');
182
- }
183
 
184
  removeEditor(container) {
185
  this.container = container;
@@ -193,9 +193,11 @@ class WpdEditor {
193
  textEditorHtml = document.getElementById(textEditorID);
194
  textEditorHtml.style.cssText = "display: none;";
195
  editor.addContainer(this.textEditorContainer).appendChild(textEditorHtml);
196
- if (editor.container.id.indexOf('-edit_') > 0) {
197
- editor.clipboard.dangerouslyPasteHTML(0, textEditorHtml.value);
198
- }
 
 
199
  /* editor.on('text-change', (delta, oldDelta, source) => {
200
  if (source === Quill.sources.USER) {
201
  textEditorHtml.value = editor.root.innerHTML;
141
  this.container = editor.container.id;
142
  }
143
  });
144
+ // editor.clipboard.addMatcher('PRE', (node, delta) => {
145
+ // var Delta = Quill.import('delta');
146
+ // return new Delta([{insert: this._htmlEntities(node.innerHTML), attributes: {'code-block': true}}]);
147
+ // });
148
  editor.clipboard.addMatcher('a', (node, delta) => {
149
  if (node.getAttribute("href") === node.innerHTML) {
150
  var Delta = Quill.import('delta');
175
  return this.currentEditor;
176
  }
177
 
178
+ // _htmlEntities(str) {
179
+ // var txt = document.createElement('textarea');
180
+ // txt.innerHTML = str;
181
+ // return txt.value.replace(/<\!\-\-\?php/g, '<?php').replace(/\?\-\->/g, '?>').replace(/\-\-\->/g, '->');
182
+ // }
183
 
184
  removeEditor(container) {
185
  this.container = container;
193
  textEditorHtml = document.getElementById(textEditorID);
194
  textEditorHtml.style.cssText = "display: none;";
195
  editor.addContainer(this.textEditorContainer).appendChild(textEditorHtml);
196
+ // if (editor.container.id.indexOf('-edit_') > 0) {
197
+ // console.log(textEditorHtml.value);
198
+ // editor.clipboard.dangerouslyPasteHTML(0, textEditorHtml.value);
199
+ // editor.update();
200
+ // }
201
  /* editor.on('text-change', (delta, oldDelta, source) => {
202
  if (source === Quill.sources.USER) {
203
  textEditorHtml.value = editor.root.innerHTML;
assets/js/wpd-editor.min.js CHANGED
@@ -1 +1 @@
1
- "use strict";function _typeof(t){return(_typeof="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})(t)}function _get(t,e,i){return(_get="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(t,e,i){var n=_superPropBase(t,e);if(n){var r=Object.getOwnPropertyDescriptor(n,e);return r.get?r.get.call(i):r.value}})(t,e,i||t)}function _superPropBase(t,e){for(;!Object.prototype.hasOwnProperty.call(t,e)&&null!==(t=_getPrototypeOf(t)););return t}function _inherits(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&&_setPrototypeOf(t,e)}function _setPrototypeOf(t,e){return(_setPrototypeOf=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function _createSuper(t){var e=_isNativeReflectConstruct();return function(){var i,n=_getPrototypeOf(t);if(e){var r=_getPrototypeOf(this).constructor;i=Reflect.construct(n,arguments,r)}else i=n.apply(this,arguments);return _possibleConstructorReturn(this,i)}}function _possibleConstructorReturn(t,e){return!e||"object"!==_typeof(e)&&"function"!=typeof e?_assertThisInitialized(t):e}function _assertThisInitialized(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function _isNativeReflectConstruct(){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 _getPrototypeOf(t){return(_getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function _instanceof(t,e){return null!=e&&"undefined"!=typeof Symbol&&e[Symbol.hasInstance]?!!e[Symbol.hasInstance](t):t instanceof e}function _classCallCheck(t,e){if(!_instanceof(t,e))throw new TypeError("Cannot call a class as a function")}function _defineProperties(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function _createClass(t,e,i){return e&&_defineProperties(t.prototype,e),i&&_defineProperties(t,i),t}var wpdEditorCounter=function(){function t(e,i){_classCallCheck(this,t),this.quill=e,this.options=i,this.maxCount=i.maxcount,this.minCount=i.mincount,this.container=document.getElementById("wpd-editor-char-counter-"+i.uniqueID),this.submit=document.getElementById("wpd-field-submit-"+i.uniqueID),e.on("editor-change",this.update.bind(this)),this.update()}return _createClass(t,[{key:"calculate",value:function(){var t=this.quill.getText().length,e=this.quill.container.id,i=document.querySelectorAll("#".concat(e," .ql-editor img"));return i.length&&i.forEach(function(e){null!==e.src.match(/https\:\/\/s\.w\.org\/images\/core\/emoji/gi)?t+=e.alt.length:e.classList.contains("wpdem-sticker")?t+=e.alt.length:t+=e.src.length}),t}},{key:"update",value:function(){var t=this.calculate(),e=t-1;if(this.maxCount>0&&t>=this.maxCount&&this.quill.deleteText(this.maxCount,t),this.maxCount>0){var i=this.maxCount-e;this.container.innerText=i>=0?i:0,t+10>this.maxCount?this.container.classList.add("error"):this.container.classList.remove("error")}else this.container.remove()}}]),t}();Quill.register("modules/counter",wpdEditorCounter);var Link=Quill.import("formats/link"),wpdEditorLink=function(t){_inherits(i,Link);var e=_createSuper(i);function i(){return _classCallCheck(this,i),e.apply(this,arguments)}return _createClass(i,null,[{key:"create",value:function(t){var e=_get(_getPrototypeOf(i),"create",this).call(this,t);t=this.sanitize(t),e.setAttribute("href",t);var n=location.protocol+"//"+location.hostname;return(t.startsWith(n)||"#"===t.charAt(0)||"/"===t.charAt(0)&&"/"!==t.charAt(1))&&e.removeAttribute("target"),e}},{key:"sanitize",value:function(t){var e=_get(_getPrototypeOf(i),"sanitize",this).call(this,t),n=e.slice(0,e.indexOf(":"));return"#"!==e.charAt(0)&&"/"!==e.charAt(0)&&-1===this.PROTOCOL_WHITELIST.indexOf(n)&&(e="http://"+t),e}}]),i}();Quill.register(wpdEditorLink,!0);var WpdEditor=function(){function t(){_classCallCheck(this,t),this.editorWraperPrefix="wpd-editor-wraper",this.textEditorContainer="ql-texteditor",this.textEditorPrefix="wc-textarea",this.editorToolbarPrefix="wpd-editor-toolbar",this.sourceCodeButtonName="sourcecode",this.spoiler="spoiler",this.spoilerPromtTitle=wpdiscuzAjaxObj.wc_spoiler_title,this._container="",this._uniqueid="",this.currentEditor=null,this._editors=new Map,this._handlers=new Map,this._initDefaults()}return _createClass(t,[{key:"addButtonEventHandler",value:function(t,e){this._handlers.set(t,e)}},{key:"createEditor",value:function(t){var e=this;if(this.container=t,this._editors.has(this.uniqueid))this.currentEditor=this._editors.get(this.uniqueid);else{var i="#".concat(this.editorToolbarPrefix,"-").concat(this.uniqueid);wpdiscuzEditorOptions.modules.toolbar=i,wpdiscuzEditorOptions.modules.counter.uniqueID=this.uniqueid;var n=new Quill(this.container,wpdiscuzEditorOptions);n.on("editor-change",function(t){null!==(arguments.length<=1?void 0:arguments[1])&&(e.currentEditor=n,e.container=n.container.id)}),n.clipboard.addMatcher("PRE",function(t,i){return new(Quill.import("delta"))([{insert:e._htmlEntities(t.innerHTML),attributes:{"code-block":!0}}])}),n.clipboard.addMatcher("a",function(t,e){return t.getAttribute("href")===t.innerHTML?new(Quill.import("delta"))([{insert:t.innerHTML}]):e}),document.querySelectorAll("".concat(i," button")).forEach(function(t){t.onclick=function(){e.currentEditor=n,e.container=n.container.id;var i=t.dataset.wpde_button_name;void 0!==i&&"string"==typeof i&&""!==i.trim()&&e._handlers.has(i)&&e._handlers.get(i)(e.currentEditor,e.uniqueid)}}),this._bindTextEditor(n),this._editors.set(this.uniqueid,n),document.getElementById("".concat(this.editorWraperPrefix,"-").concat(this.uniqueid)).style.display=""}return this.currentEditor}},{key:"_htmlEntities",value:function(t){var e=document.createElement("textarea");return e.innerHTML=t,e.value.replace(/<\!\-\-\?php/g,"<?php").replace(/\?\-\->/g,"?>").replace(/\-\-\->/g,"->")}},{key:"removeEditor",value:function(t){this.container=t,this._editors.has(this.uniqueid)&&this._editors.delete(this.uniqueid)}},{key:"_bindTextEditor",value:function(t){var e="".concat(this.textEditorPrefix,"-").concat(this.uniqueid),i=document.getElementById(e);i.style.cssText="display: none;",t.addContainer(this.textEditorContainer).appendChild(i),t.container.id.indexOf("-edit_")>0&&t.clipboard.dangerouslyPasteHTML(0,i.value),this.currentEditor=t}},{key:"_findUniqueId",value:function(){return this.container.substring(this.container.lastIndexOf("-")+1)}},{key:"_initDefaults",value:function(){var t=this;this.addButtonEventHandler(this.sourceCodeButtonName,function(e){document.getElementById("".concat(t.textEditorPrefix,"-").concat(t.uniqueid));var i=document.getElementById("wpd-editor-source-code-wrapper-bg"),n=document.getElementById("wpd-editor-source-code-wrapper"),r=document.getElementById("wpd-editor-source-code"),o=document.getElementById("wpd-editor-uid");i.style.display="block",n.style.display="block",o.value=e.container.id,r.value=e.root.innerHTML}),this.addButtonEventHandler(this.spoiler,function(e){var i=prompt(t.spoilerPromtTitle);if(null!==i){var n=' [spoiler title="'.concat(i,'"] '),r=e.getSelection();null===r&&(r={index:e.getLength()-1,length:0}),0===r.length?(e.insertText(r.index,n+" [/spoiler] ",Quill.sources.USER),e.setSelection(r.index+n.length,Quill.sources.USER)):(e.insertText(r.index,n),e.insertText(r.index+n.length+r.length," [/spoiler] ",Quill.sources.USER),e.setSelection(r.index+n.length+r.length+" [/spoiler] ".length,Quill.sources.USER))}})}},{key:"uniqueid",set:function(t){""!==t&&"string"==typeof t?this._uniqueid=t:""===t?this._uniqueid=this._findUniqueId():console.error("Incorrect uniqueid.")},get:function(){return this._uniqueid}},{key:"container",set:function(t){""!==t&&"string"==typeof t?(this._container=t,this.uniqueid=this._findUniqueId()):console.error("Incorrect uniqueid.")},get:function(){return this._container}}]),t}();
1
+ "use strict";function _typeof(t){return(_typeof="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})(t)}function _get(t,e,i){return(_get="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(t,e,i){var n=_superPropBase(t,e);if(n){var r=Object.getOwnPropertyDescriptor(n,e);return r.get?r.get.call(i):r.value}})(t,e,i||t)}function _superPropBase(t,e){for(;!Object.prototype.hasOwnProperty.call(t,e)&&null!==(t=_getPrototypeOf(t)););return t}function _inherits(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&&_setPrototypeOf(t,e)}function _setPrototypeOf(t,e){return(_setPrototypeOf=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function _createSuper(t){var e=_isNativeReflectConstruct();return function(){var i,n=_getPrototypeOf(t);if(e){var r=_getPrototypeOf(this).constructor;i=Reflect.construct(n,arguments,r)}else i=n.apply(this,arguments);return _possibleConstructorReturn(this,i)}}function _possibleConstructorReturn(t,e){return!e||"object"!==_typeof(e)&&"function"!=typeof e?_assertThisInitialized(t):e}function _assertThisInitialized(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function _isNativeReflectConstruct(){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 _getPrototypeOf(t){return(_getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function _instanceof(t,e){return null!=e&&"undefined"!=typeof Symbol&&e[Symbol.hasInstance]?!!e[Symbol.hasInstance](t):t instanceof e}function _classCallCheck(t,e){if(!_instanceof(t,e))throw new TypeError("Cannot call a class as a function")}function _defineProperties(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function _createClass(t,e,i){return e&&_defineProperties(t.prototype,e),i&&_defineProperties(t,i),t}var wpdEditorCounter=function(){function t(e,i){_classCallCheck(this,t),this.quill=e,this.options=i,this.maxCount=i.maxcount,this.minCount=i.mincount,this.container=document.getElementById("wpd-editor-char-counter-"+i.uniqueID),this.submit=document.getElementById("wpd-field-submit-"+i.uniqueID),e.on("editor-change",this.update.bind(this)),this.update()}return _createClass(t,[{key:"calculate",value:function(){var t=this.quill.getText().length,e=this.quill.container.id,i=document.querySelectorAll("#".concat(e," .ql-editor img"));return i.length&&i.forEach(function(e){null!==e.src.match(/https\:\/\/s\.w\.org\/images\/core\/emoji/gi)?t+=e.alt.length:e.classList.contains("wpdem-sticker")?t+=e.alt.length:t+=e.src.length}),t}},{key:"update",value:function(){var t=this.calculate(),e=t-1;if(this.maxCount>0&&t>=this.maxCount&&this.quill.deleteText(this.maxCount,t),this.maxCount>0){var i=this.maxCount-e;this.container.innerText=i>=0?i:0,t+10>this.maxCount?this.container.classList.add("error"):this.container.classList.remove("error")}else this.container.remove()}}]),t}();Quill.register("modules/counter",wpdEditorCounter);var Link=Quill.import("formats/link"),wpdEditorLink=function(t){_inherits(i,Link);var e=_createSuper(i);function i(){return _classCallCheck(this,i),e.apply(this,arguments)}return _createClass(i,null,[{key:"create",value:function(t){var e=_get(_getPrototypeOf(i),"create",this).call(this,t);t=this.sanitize(t),e.setAttribute("href",t);var n=location.protocol+"//"+location.hostname;return(t.startsWith(n)||"#"===t.charAt(0)||"/"===t.charAt(0)&&"/"!==t.charAt(1))&&e.removeAttribute("target"),e}},{key:"sanitize",value:function(t){var e=_get(_getPrototypeOf(i),"sanitize",this).call(this,t),n=e.slice(0,e.indexOf(":"));return"#"!==e.charAt(0)&&"/"!==e.charAt(0)&&-1===this.PROTOCOL_WHITELIST.indexOf(n)&&(e="http://"+t),e}}]),i}();Quill.register(wpdEditorLink,!0);var WpdEditor=function(){function t(){_classCallCheck(this,t),this.editorWraperPrefix="wpd-editor-wraper",this.textEditorContainer="ql-texteditor",this.textEditorPrefix="wc-textarea",this.editorToolbarPrefix="wpd-editor-toolbar",this.sourceCodeButtonName="sourcecode",this.spoiler="spoiler",this.spoilerPromtTitle=wpdiscuzAjaxObj.wc_spoiler_title,this._container="",this._uniqueid="",this.currentEditor=null,this._editors=new Map,this._handlers=new Map,this._initDefaults()}return _createClass(t,[{key:"addButtonEventHandler",value:function(t,e){this._handlers.set(t,e)}},{key:"createEditor",value:function(t){var e=this;if(this.container=t,this._editors.has(this.uniqueid))this.currentEditor=this._editors.get(this.uniqueid);else{var i="#".concat(this.editorToolbarPrefix,"-").concat(this.uniqueid);wpdiscuzEditorOptions.modules.toolbar=i,wpdiscuzEditorOptions.modules.counter.uniqueID=this.uniqueid;var n=new Quill(this.container,wpdiscuzEditorOptions);n.on("editor-change",function(t){null!==(arguments.length<=1?void 0:arguments[1])&&(e.currentEditor=n,e.container=n.container.id)}),n.clipboard.addMatcher("a",function(t,e){return t.getAttribute("href")===t.innerHTML?new(Quill.import("delta"))([{insert:t.innerHTML}]):e}),document.querySelectorAll("".concat(i," button")).forEach(function(t){t.onclick=function(){e.currentEditor=n,e.container=n.container.id;var i=t.dataset.wpde_button_name;void 0!==i&&"string"==typeof i&&""!==i.trim()&&e._handlers.has(i)&&e._handlers.get(i)(e.currentEditor,e.uniqueid)}}),this._bindTextEditor(n),this._editors.set(this.uniqueid,n),document.getElementById("".concat(this.editorWraperPrefix,"-").concat(this.uniqueid)).style.display=""}return this.currentEditor}},{key:"removeEditor",value:function(t){this.container=t,this._editors.has(this.uniqueid)&&this._editors.delete(this.uniqueid)}},{key:"_bindTextEditor",value:function(t){var e="".concat(this.textEditorPrefix,"-").concat(this.uniqueid),i=document.getElementById(e);i.style.cssText="display: none;",t.addContainer(this.textEditorContainer).appendChild(i),this.currentEditor=t}},{key:"_findUniqueId",value:function(){return this.container.substring(this.container.lastIndexOf("-")+1)}},{key:"_initDefaults",value:function(){var t=this;this.addButtonEventHandler(this.sourceCodeButtonName,function(e){document.getElementById("".concat(t.textEditorPrefix,"-").concat(t.uniqueid));var i=document.getElementById("wpd-editor-source-code-wrapper-bg"),n=document.getElementById("wpd-editor-source-code-wrapper"),r=document.getElementById("wpd-editor-source-code"),o=document.getElementById("wpd-editor-uid");i.style.display="block",n.style.display="block",o.value=e.container.id,r.value=e.root.innerHTML}),this.addButtonEventHandler(this.spoiler,function(e){var i=prompt(t.spoilerPromtTitle);if(null!==i){var n=' [spoiler title="'.concat(i,'"] '),r=e.getSelection();null===r&&(r={index:e.getLength()-1,length:0}),0===r.length?(e.insertText(r.index,n+" [/spoiler] ",Quill.sources.USER),e.setSelection(r.index+n.length,Quill.sources.USER)):(e.insertText(r.index,n),e.insertText(r.index+n.length+r.length," [/spoiler] ",Quill.sources.USER),e.setSelection(r.index+n.length+r.length+" [/spoiler] ".length,Quill.sources.USER))}})}},{key:"uniqueid",set:function(t){""!==t&&"string"==typeof t?this._uniqueid=t:""===t?this._uniqueid=this._findUniqueId():console.error("Incorrect uniqueid.")},get:function(){return this._uniqueid}},{key:"container",set:function(t){""!==t&&"string"==typeof t?(this._container=t,this.uniqueid=this._findUniqueId()):console.error("Incorrect uniqueid.")},get:function(){return this._container}}]),t}();
assets/js/wpdiscuz-combo-no_quill.min.js CHANGED
@@ -3,7 +3,7 @@
3
  /* Autogrow */
4
  jQuery.fn.autoGrow=function(){return this.each(function(){var createMirror=function(textarea){jQuery(textarea).after('<div class="autogrow-textarea-mirror"></div>');return jQuery(textarea).next(".autogrow-textarea-mirror")[0]};var sendContentToMirror=function(textarea){mirror.innerHTML=String(textarea.value).replace(/&/g,"&amp;").replace(/"/g,"&quot;").replace(/'/g,"&#39;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/\n/g,"<br />")+".<br/>.";if(jQuery(textarea).height()!=jQuery(mirror).height())jQuery(textarea).height(jQuery(mirror).height())};var growTextarea=function(){sendContentToMirror(this)};var mirror=createMirror(this);mirror.style.display="none";mirror.style.wordWrap="break-word";mirror.style.padding=jQuery(this).css("padding");mirror.style.width=jQuery(this).css("width");mirror.style.fontFamily=jQuery(this).css("font-family");mirror.style.fontSize=jQuery(this).css("font-size");mirror.style.lineHeight=jQuery(this).css("line-height");this.style.overflow="hidden";this.style.minHeight=this.rows+"em";this.onkeydown=growTextarea;sendContentToMirror(this)})};
5
  /* wpDiscuz */
6
- var wpdiscuzLoadRichEditor=parseInt(wpdiscuzAjaxObj.loadRichEditor);if(wpdiscuzLoadRichEditor)var wpDiscuzEditor=new WpdEditor;function wpdMessagesOnInit(e,t){wpdiscuzAjaxObj.setCommentMessage(e,t),setTimeout(function(){location.href=location.href.substring(0,location.href.indexOf("wpdiscuzUrlAnchor")-1)},3e3)}wpdiscuzAjaxObj.setCommentMessage=function(e,t,a){var o="wpdiscuz-message-error";if("[object Array]"===Object.prototype.toString.call(e))for(var d in e)"[object Array]"===Object.prototype.toString.call(t)?"success"===t[d]?o="wpdiscuz-message-success":"warning"===t[d]&&(o="wpdiscuz-message-warning"):"success"===t?o="wpdiscuz-message-success":"warning"===t&&(o="wpdiscuz-message-warning"),jQuery("<div/>").addClass(o).html(e[d]).prependTo("#wpdiscuz-comment-message").delay("[object Array]"===Object.prototype.toString.call(a)?a[d]:a||4e3).fadeOut(1e3,function(){jQuery(this).remove()});else"success"===t?o="wpdiscuz-message-success":"warning"===t&&(o="wpdiscuz-message-warning"),jQuery("<div/>").addClass(o).html(e).prependTo("#wpdiscuz-comment-message").delay(a||4e3).fadeOut(1e3,function(){jQuery(this).remove()})},jQuery(document).ready(function(e){e("body").addClass("wpdiscuz_"+wpdiscuzAjaxObj.version);var t=wpdiscuzAjaxObj.is_user_logged_in,a=1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!t,o=1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&t,d=wpdiscuzAjaxObj.wpDiscuzReCaptchaVersion,n=parseInt(wpdiscuzAjaxObj.commentListLoadType),i=parseInt(wpdiscuzAjaxObj.wc_post_id),s=parseInt(wpdiscuzAjaxObj.commentListUpdateType),c=1e3*parseInt(wpdiscuzAjaxObj.commentListUpdateTimer),p=parseInt(wpdiscuzAjaxObj.liveUpdateGuests),r=wpdiscuzAjaxObj.loadLastCommentId,l=r,m=parseInt(wpdiscuzAjaxObj.firstLoadWithAjax);Cookies.get("wpdiscuz_comments_sorting")&&Cookies.remove("wpdiscuz_comments_sorting",{path:""}),Cookies.get("wordpress_last_visit")&&Cookies.remove("wordpress_last_visit",{path:""}),Cookies.get("wpdiscuz_last_visit")&&Cookies.remove("wpdiscuz_last_visit",{path:""});var w,u=wpdiscuzAjaxObj.storeCommenterData,f=parseInt(wpdiscuzAjaxObj.wmuEnabled),h=wpdiscuzAjaxObj.isCookiesEnabled,b=!0,g=wpdiscuzAjaxObj.cookiehash,_=parseInt(wpdiscuzAjaxObj.isLoadOnlyParentComments),v=parseInt(wpdiscuzAjaxObj.enableDropAnimation)?500:0,z=parseInt(wpdiscuzAjaxObj.isNativeAjaxEnabled),j=parseInt(wpdiscuzAjaxObj.enableBubble),C=parseInt(wpdiscuzAjaxObj.bubbleLiveUpdate),k=parseInt(wpdiscuzAjaxObj.bubbleHintTimeout),x=parseInt(wpdiscuzAjaxObj.bubbleHintHideTimeout)?parseInt(wpdiscuzAjaxObj.bubbleHintHideTimeout):5,y=parseInt(wpdiscuzAjaxObj.bubbleShowNewCommentMessage),O=wpdiscuzAjaxObj.bubbleLocation,A=wpdiscuzAjaxObj.inlineFeedbackAttractionType,I=[],T=[],D=[],E=!1,M=1;(e(".wc_social_plugin_wrapper .wp-social-login-provider-list").length?e(".wc_social_plugin_wrapper .wp-social-login-provider-list").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .the_champ_login_container").length?e(".wc_social_plugin_wrapper .the_champ_login_container").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .social_connect_form").length?e(".wc_social_plugin_wrapper .social_connect_form").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .oneall_social_login_providers").length&&e(".wc_social_plugin_wrapper .oneall_social_login .oneall_social_login_providers").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"),wpdiscuzLoadRichEditor&&e("#wpd-editor-0_0").length&&wpDiscuzEditor.createEditor("#wpd-editor-0_0"),e(document).delegate("#wpdcom .ql-editor, #wpdcom .wc_comment","focus",function(){e(".wpd-form-foot",e(this).parents(".wpd_comm_form")).slideDown(v)}),e(document).delegate("#wpdcom textarea","focus",function(){e(this).next(".autogrow-textarea-mirror").length||e(this).autoGrow()}),t)||S({comment_author:Cookies.get("comment_author_"+g),comment_author_email:Cookies.get("comment_author_email_"+g),comment_author_url:Cookies.get("comment_author_url_"+g)});if(e(".wpd-vote-down.wpd-dislike-hidden").remove(),e(".wpd-toolbar-hidden").prev("[id^=wpd-editor-]").css("border-bottom","1px solid #dddddd"),e(document).delegate("#wpd-editor-source-code-wrapper-bg","click",function(){e(this).hide(),e("#wpd-editor-source-code-wrapper").hide(),e("#wpd-editor-uid").val(""),e("#wpd-editor-source-code").val("")}),wpdiscuzLoadRichEditor&&e(document).delegate("#wpd-insert-source-code","click",function(){var t=wpDiscuzEditor.createEditor("#"+e("#wpd-editor-uid").val());t.deleteText(0,t.getLength(),Quill.sources.USER);var a=e("#wpd-editor-source-code").val();a.length&&t.clipboard.dangerouslyPasteHTML(0,a,Quill.sources.USER),t.update(),e("#wpd-editor-source-code-wrapper-bg").hide(),e("#wpd-editor-source-code-wrapper").hide(),e("#wpd-editor-uid").val(""),e("#wpd-editor-source-code").val("")}),e(document).delegate(".wpd-reply-button","click",function(){var n=V(e(this),0);e(this).hasClass("wpdiscuz-clonned")?(wpdiscuzLoadRichEditor?setTimeout(function(){wpDiscuzEditor.createEditor("#wpd-editor-"+n).focus()},v):setTimeout(function(){e("#wc-textarea-"+n).trigger("focus")},v),e("#wpd-secondary-form-wrapper-"+n).slideToggle(v)):function(a){var o=V(a,0);e("#wpdiscuz_form_anchor-"+o).before(function(t){return e("#wpdiscuz_hidden_secondary_form").html().replace(/wpdiscuzuniqueid/g,t)}(o));var d=e("#wpd-secondary-form-wrapper-"+o);if(!t){var n={comment_author:Cookies.get("comment_author_"+g),comment_author_email:Cookies.get("comment_author_email_"+g),comment_author_url:Cookies.get("comment_author_url_"+g)};S(n)}wpdiscuzLoadRichEditor?setTimeout(function(){wpDiscuzEditor.createEditor("#wpd-editor-"+o).focus()},v):setTimeout(function(){e("#wc-textarea-"+o).trigger("focus")},v);d.slideToggle(v,function(){a.addClass("wpdiscuz-clonned")})}(e(this)),function(t){if((a||o)&&"2.0"===d){var n=B(t);setTimeout(function(){if(!T[n])try{T[n]=grecaptcha.render("wpdiscuz-recaptcha-"+t,{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(a){e("#wpdiscuz-recaptcha-field-"+t).val("key")},"expired-callback":function(){e("#wpdiscuz-recaptcha-field-"+t).val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}},1e3)}}(n)}),e(document).delegate("#wpdcom .wpd-comment-link [data-comment-url]","click",function(){var t=e(this).data("comment-url"),a=e("<input/>");a.appendTo("body").css({position:"absolute",top:"-10000000px"}).val(t),a.select(),document.execCommand("copy"),a.remove(),wpdiscuzAjaxObj.setCommentMessage(t+"<br/>"+wpdiscuzAjaxObj.wc_copied_to_clipboard,"success",5e3)}),e(document).delegate(".wpdiscuz-nofollow,.wc_captcha_refresh_img,.wpd-load-more-submit","click",function(e){e.preventDefault()}),e(document).delegate(".wpd-toggle.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked");var a=V(e(this),0),o=e(this),d=e(".fas",o);!o.parents(".wpd-comment:not(.wpd-reply)").children(".wpd-reply").length&&_?function(t,a){var o=B(t),d=new FormData;d.append("action","wpdShowReplies"),d.append("commentId",o),ce(z,!0,d).done(function(o){a.addClass("wpd_not_clicked"),"object"==typeof o&&o.success&&(e("#wpd-comm-"+t).replaceWith(o.data.comment_list),e("#wpd-comm-"+t+" .wpd-toggle .fas").removeClass("fa-chevron-down").addClass("fa-chevron-up"),e("#wpd-comm-"+t+" .wpd-toggle").attr("wpd-tooltip",wpdiscuzAjaxObj.wc_hide_replies_text),e("#wpd-comm-"+t+" .wpd-toggle .wpd-view-replies").remove(),se(o)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,o,d){console.log(d),a.addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}(a,t):e("#wpd-comm-"+a+"> .wpd-reply").slideToggle(700,function(){e(this).is(":hidden")?(d.removeClass("fa-chevron-up"),d.addClass("fa-chevron-down"),o.attr("wpd-tooltip",wpdiscuzAjaxObj.wc_show_replies_text)):(d.removeClass("fa-chevron-down"),d.addClass("fa-chevron-up"),o.attr("wpd-tooltip",wpdiscuzAjaxObj.wc_hide_replies_text)),t.addClass("wpd_not_clicked")})}),e(document).delegate(".wpd-new-loaded-comment","mouseenter",function(){e(this).removeClass("wpd-new-loaded-comment")}),e(document).delegate(".wpd-sbs-toggle","click",function(){e(".wpdiscuz-subscribe-bar").slideToggle(v)}),parseInt(wpdiscuzAjaxObj.wpDiscuzIsShowOnSubscribeForm)&&!t&&wpdiscuzAjaxObj.wpDiscuzReCaptchaSK&&("2.0"===d?(setTimeout(function(){try{grecaptcha.render("wpdiscuz-recaptcha-subscribe-form",{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(t){e("#wpdiscuz-recaptcha-field-subscribe-form").val("key")},"expired-callback":function(){e("#wpdiscuz-recaptcha-field-subscribe-form").val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}},1e3),e(document).delegate("#wpdiscuz-subscribe-form","submit",function(t){e("#wpdiscuz-recaptcha-field-subscribe-form").val()?e(".wpdiscuz-recaptcha",e(this)).css("border","none"):(e(".wpdiscuz-recaptcha",e(this)).css("border","1px solid red"),t.preventDefault())})):"3.0"===d&&e(document).delegate("#wpdiscuz_subscription_button","click",function(t){var a=e(this).parents("#wpdiscuz-subscribe-form");t.preventDefault();try{grecaptcha.ready(function(){grecaptcha.execute(wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,{action:"wpdiscuz/wpdAddSubscription"}).then(function(e){console.log(5555),document.getElementById("wpdiscuz-recaptcha-field-subscribe-form").value=e,a.submit()},function(e){wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error","error"),console.log(e)})})}catch(t){console.log(t),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+t.message,"error")}})),(a||o)&&"2.0"===d){var F=e(window).width(),L=e("#wpdcom").width();L>=1100&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"65%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"35%"})),L>=940&&L<1100&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"60%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"40%"})),L>=810&&L<940&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"40%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"60%"})),L>=730&&L<810&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"45%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"55%"})),L>=610&&L<730&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.85)","-webkit-transform":"scale(0.85)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"43%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"55%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"30%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"70%"})),F>650&&(L>=510&&L<610&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"center 0","-webkit-transform-origin":"center 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"35%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"63%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"30%",position:"relative",right:"-60px"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"70%"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"})),L>=470&&L<510&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"center 0","-webkit-transform-origin":"center 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"40%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"60%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd_main_comm_form .wc-form-footer").css({"margin-left":"0px"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"})),L<470&&(e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({margin:"0px auto","transform-origin":"center 0","-webkit-transform-origin":"center 0"}),e("#wpdcom .wpd-form-col-left").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-form-col-right").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"}),e("#wpdcom .wpd-secondary-form-wrapper .wc_notification_checkboxes").css({"text-align":"center"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-field-submit").css({"text-align":"center"})))}function R(t,a,o){ce(z||f,!1,a).done(function(a){if(e(o).addClass("wpd_not_clicked"),"object"==typeof a)if(a.success){"collapsed"===wpdiscuzAjaxObj.commentFormView&&e(".wpd-form-foot",t).slideUp(v),e(".wpd-thread-info").html(a.data.wc_all_comments_count_new_html),a.data.wc_all_comments_count_new=parseInt(a.data.wc_all_comments_count_new),e("#wpd-bubble-all-comments-count").text(a.data.wc_all_comments_count_new),a.data.wc_all_comments_count_new?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide();var d=v;a.data.is_main?X(a.data.message):(d=v+700,e("#wpd-secondary-form-wrapper-"+a.data.uniqueid).slideToggle(700),1==a.data.is_in_same_container?e("#wpd-secondary-form-wrapper-"+a.data.uniqueid).after(a.data.message):e("#wpd-comm-"+a.data.uniqueid).after(a.data.message)),function(e){if(!e.data.held_moderate){var t=new FormData;t.append("action","wpdCheckNotificationType"),t.append("comment_id",e.data.new_comment_id),t.append("email",e.data.comment_author_email),t.append("isParent",e.data.is_main),ce(z,!0,t)}}(a),function(e){if(e.data.redirect>0&&e.data.new_comment_id){var t=new FormData;t.append("action","wpdRedirect"),t.append("commentId",e.data.new_comment_id),ce(z,!0,t).done(function(e){"object"==typeof e&&e.success&&setTimeout(function(){location.href=e.data},2e3)}).fail(function(e,t,a){console.log(a)})}}(a),h&&b?function(t){var a=t.comment_author_email,o=t.comment_author,d=t.comment_author_url;null==u?(Cookies.set("comment_author_email_"+g,a),Cookies.set("comment_author_"+g,o),d.length&&Cookies.set("comment_author_url_"+g,d)):(u=parseInt(u),Cookies.set("comment_author_email_"+g,a,{expires:u,path:"/"}),Cookies.set("comment_author_"+g,o,{expires:u,path:"/"}),d.length&&Cookies.set("comment_author_url_"+g,d,{expires:u,path:"/"}));e(".wpd-cookies-checkbox").length&&e(".wpd-cookies-checkbox").attr("checked","checked")}(a.data):b||e(".wpd-cookies-checkbox").removeAttr("checked"),wpdiscuzLoadRichEditor&&wpDiscuzEditor.createEditor("#wpd-editor-"+e(".wpdiscuz_unique_id",t).val()).setContents([{insert:"\n"}]),t.get(0).reset(),S(a.data),e(".wmu-preview-wrap",t).remove(),I.length&&(I.forEach(function(e){e.parents(".wpd-field-checkbox").remove()}),I=[]),setTimeout(function(){e("html, body").animate({scrollTop:e("#comment-"+a.data.new_comment_id).offset().top-32},1e3)},d),se(a,t)}else a.data&&(wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"),se(a,t));else wpdiscuzAjaxObj.setCommentMessage(a,"error");e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,d){console.log(d),e(o).addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}function S(t){e(".wpd_comm_form .wc_name").val(t.comment_author),t.comment_author_email&&t.comment_author_email.indexOf("@example.com")<0&&e(".wpd_comm_form .wc_email").val(t.comment_author_email),t.comment_author_url&&e(".wpd_comm_form .wc_website").val(t.comment_author_url)}function q(t,a){e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd_editable_comment").show(),e("#wpd-comm-"+t+" .wpdiscuz-edit-form-wrap").replaceWith(a),e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").show()}e(document).delegate(".wc_comm_submit.wpd_not_clicked","click",function(){var t=e(this),n=1,i=e(this).parents("form");if(i.hasClass("wpd_main_comm_form")||(n=function(t){var a=t.attr("class").split(" "),o="";return e.each(a,function(e,t){"wpd_comment_level"===G(t,!1)&&(o=G(t,!0))}),parseInt(o)+1}(e(this).parents(".wpd-comment"))),J(i,"#wpd-editor-"+e(".wpdiscuz_unique_id",i).val()),i.submit(function(e){e.preventDefault()}),""!==e(".wc_comment",i).val().trim()&&"<br>"!==e(".wc_comment",i).val().trim()){if(i[0].checkValidity()&&(c=i,p=!0,"2.0"===d&&e("input[name=wc_captcha]",c).length&&!e("input[name=wc_captcha]",c).val().length?(p=!1,e(".wpdiscuz-recaptcha",c).css("border","1px solid red")):"2.0"===d&&e("input[name=wc_captcha]",c).length&&e(".wpdiscuz-recaptcha",c).css("border","none"),p)){E=!0,function(t){e(".wpd-agreement-checkbox",t).each(function(){e(this).hasClass("wpd_agreement_hide")&&h&&e(this).prop("checked")&&(Cookies.set(e(this).attr("name")+"_"+g,1,{expires:30,path:"/"}),e("input[name="+e(this).attr("name")+"]").each(function(){I.push(e(this))}))})}(i),e(t).removeClass("wpd_not_clicked");var s=new FormData;if(s.append("action","wpdAddComment"),e(":input",i).each(function(){""!=this.name&&"checkbox"!=this.type&&"radio"!=this.type&&s.append(this.name+"",e(this).val().trim()),"checkbox"!=this.type&&"radio"!=this.type||e(this).is(":checked")&&s.append(this.name+"",e(this).val())}),s.append("wpd_comment_depth",n),wpdiscuzAjaxObj.wpdiscuz_zs&&s.append("wpdiscuz_zs",wpdiscuzAjaxObj.wpdiscuz_zs),e(".wpd-cookies-checkbox",i).length&&!e(".wpd-cookies-checkbox",i).prop("checked")&&(b=!1),e("#wpdiscuz-loading-bar").show(),wpdiscuzAjaxObj.wpDiscuzReCaptchaSK&&"3.0"===d&&(1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!wpdiscuzAjaxObj.is_user_logged_in||1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&wpdiscuzAjaxObj.is_user_logged_in))try{grecaptcha.ready(function(){grecaptcha.execute(wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,{action:"wpdiscuz/addComment"}).then(function(e){s.append("g-recaptcha-response",e),R(i,s,t)},function(e){wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error","error"),console.log(e)})})}catch(t){console.log(t),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+t.message,"error"),e("#wpdiscuz-loading-bar").fadeOut(250)}else R(i,s,t)}var c,p;!function(e){if((a||o)&&"2.0"===d){var t=B(e);grecaptcha.reset(T[t])}}(e(".wpdiscuz_unique_id",i).val()),e(".wpdiscuz_reset").val("")}else wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj.wc_msg_required_fields,"error")}),e(document).delegate(".wpd_editable_comment","click",function(){w&&e(".wpdiscuz-edit-form-wrap").length&&q(V(e(".wpdiscuz-edit-form-wrap"),0),w);var t=V(e(this),0),a=B(t),o=new FormData;o.append("action","wpdEditComment"),o.append("commentId",a),w=e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-text").get(0),ce(z,!0,o).done(function(a){"object"==typeof a?a.success?(e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd-comment-text").replaceWith(a.data),wpdiscuzLoadRichEditor&&(wpDiscuzEditor.createEditor("#wpd-editor-edit_"+t),e(".wpd-toolbar-hidden").prev("[id^=wpd-editor-]").css("border-bottom","1px solid #dddddd")),e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd_editable_comment").hide(),e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").hide()):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"):console.log(a),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wc_save_edited_comment","click",function(){var t=V(e(this)),a=B(t),o=e("#wpd-comm-"+t+" #wpdiscuz-edit-form");if(J(o,"#wpd-editor-edit_"+t),o.submit(function(e){e.preventDefault()}),o[0].checkValidity()){var d=new FormData;d.append("action","wpdSaveEditedComment"),d.append("commentId",a),e(":input",o).each(function(){""!==this.name&&"checkbox"!==this.type&&"radio"!==this.type&&d.append(this.name+"",e(this).val()),"checkbox"!==this.type&&"radio"!==this.type||e(this).is(":checked")&&d.append(this.name+"",e(this).val())}),ce(z,!0,d).done(function(o){"object"==typeof o?(o.success?(q(t,o.data.message),o.data.lastEdited&&(e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").remove(),e(o.data.lastEdited).insertAfter("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd-comment-text")),o.data.twitterShareLink&&e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-share .wpd-tooltip-content .wc_tw").attr("href",o.data.twitterShareLink),o.data.whatsappShareLink&&e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-share .wpd-tooltip-content .wc_whatsapp").attr("href",o.data.whatsappShareLink),wpdiscuzLoadRichEditor&&wpDiscuzEditor.removeEditor("#wpd-editor-edit_"+t)):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[o.data],"error"),se(o,a)):console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(document).delegate(".wc_cancel_edit","click",function(){var t=V(e(this));q(t,w),wpdiscuzLoadRichEditor&&wpDiscuzEditor.removeEditor("#wpd-editor-edit_"+t)}),!wpdiscuzAjaxObj.wordpressIsPaginate&&m&&(M=0,1==m?setTimeout(function(){W(!0)},500):e(document).delegate(".wpd-load-comments","click",function(){e(this).remove(),W(!0)})),e(document).delegate(".wpd-load-more-submit","click",function(){var t=e(this);t.hasClass("wpd-loaded")&&W(!1,t,"wpd-loaded","wpd-loading")});var U=!1;function H(){var t=e("#wpdiscuzHasMoreComments").val(),a=e(document).height(),o=e(window).height()+e(window).scrollTop();a&&o&&(100*o/a>=80&&!1===U&&1==t&&(U=!0,W(!1,e(".wpd-load-more-submit"))))}function W(t,a,o,d){a&&(a.toggleClass(o),a.toggleClass(d));var i=new FormData;i.append("action","wpdLoadMoreComments");var s=e(".wpdiscuz-sort-button-active").attr("data-sorting");s&&i.append("sorting",s),i.append("offset",M),i.append("lastParentId",e(".wpd-load-more-submit").attr("data-lastparentid")),i.append("isFirstLoad",t?1:0);var c=e(".wpdf-active").attr("data-filter-type");i.append("wpdType",c||""),ce(z,!0,i).done(function(i){"object"==typeof i&&i.success&&(M++,e(".wpdiscuz-comment-pagination").before(i.data.comment_list),K(i,t&&2!==n),e(".wpdiscuz_single").remove(),U=!1,r=i.data.loadLastCommentId,se(i),t&&N(!1)),e("#wpdiscuz-loading-bar").fadeOut(250),e(".wpd-load-more-submit").blur(),a&&(a.toggleClass(o),a.toggleClass(d))}).fail(function(t,n,i){console.log(i),e("#wpdiscuz-loading-bar").fadeOut(250),e(".wpd-load-more-submit").blur(),a&&(a.toggleClass(o),a.toggleClass(d))})}function K(t,a){var o;0==t.data.is_show_load_more?(e("#wpdiscuzHasMoreComments").val(0),e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").hide()):(o=t.data.last_parent_id,e(".wpd-load-more-submit").attr("data-lastparentid",o),2!==n&&e(".wpdiscuz-comment-pagination").show(),e("#wpdiscuzHasMoreComments").val(1),a&&e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").show()),se(t)}function N(t){var a=location.href.match(/#comment\-(\d+)/);if(null!==a){var o=a[1];if(e("#comment-"+o).length)setTimeout(function(){e("html, body").animate({scrollTop:e("#comment-"+o).parents("[id^=wpd-comm-]").offset().top-32},1e3),t&&P(o)},500);else{var d=new FormData;d.append("action","wpdGetSingleComment"),d.append("commentId",o),ce(z,!0,d).done(function(a){if("object"==typeof a&&a.success){var d="#comment-"+o;e("#comment-"+a.data.parentCommentID).length?e("#comment-"+a.data.parentCommentID).parents("[id^=wpd-comm-"+a.data.parentCommentID+"]").replaceWith(a.data.message):e(".wpd-thread-list").prepend(a.data.message),se(a),e("html, body").animate({scrollTop:e(d).offset().top-32},1e3),t&&P(o)}e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}}function P(t){setTimeout(function(){e("#comment-"+t).siblings(".wpd-secondary-form-wrapper").is(":visible")||e("#comment-"+t).find(".wpd-reply-button").trigger("click")},1100)}function Q(e){if(void 0!==e.data.message)for(var t,a=e.data.message,o=0;o<a.length;o++)$((t=a[o]).comment_parent,t.comment_html)}function V(e,t){var a="";return(a=t?e.parents(".wpd-main-form-wrapper").attr("id"):e.parents(".wpd-comment").attr("id")).substring(a.lastIndexOf("-")+1)}function B(e){return e.substring(0,e.indexOf("_"))}function G(e,t){return t?e.substring(e.indexOf("-")+1):e.substring(0,e.indexOf("-"))}function $(t,a){if(0==t)X(a);else{var o=V(e("#comment-"+t),0);e("#wpdiscuz_form_anchor-"+o).after(a)}}function Y(){var t,a,o="";return e(".wpd-comment-right").each(function(){t=V(e(this),0),a=B(t),o+=a+","}),o}function J(t,a){var o=t.find(".wpd-required-group");wpdiscuzLoadRichEditor&&t.find(".wc_comment").val(e(a+">.ql-editor").html()),function(e){var t=e.find(".wc_comment"),a=t.val().trim();a=(a=(a=(a=a.replace(/<img src=["|']https\:\/\/s\.w\.org\/images\/core\/emoji\/([^"|']+)["|'](.*?)alt=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$3")).replace(/<img[^>]+alt=["|']([^"|']+)["|'][^>]+src=["|']https\:\/\/s\.w\.org\/images\/core\/emoji\/([^"|']+)["|'][^>]?>/g,"$1")).replace(/<img\s+([^>]*)class=["|']wpdem\-sticker["|'](.*?)alt=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$3")).replace(/<img\s+([^>]*)src=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$2"),t.val(a)}(t),e.each(o,function(){e("input",this).removeAttr("required"),0===e("input:checked",this).length?e("input",e(this)).attr("required","required"):e(".wpd-field-invalid",this).remove()})}function X(t){e(".wpd-sticky-comment").last()[0]?e(t).insertAfter(e(".wpd-sticky-comment").last()[0]):e(".wpd-thread-list").prepend(t)}function Z(t){t?t.prop("required")||(t.val()?t.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","inline-block"):t.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","none")):e.each(e(".wc_email"),function(t,a){var o=e(a);o.prop("required")||(o.val()?o.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","inline-block"):o.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","none"))})}if(2!==n||wpdiscuzAjaxObj.wordpressIsPaginate||(e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").hide(),H(),e(window).scroll(function(){H()})),wpdiscuzAjaxObj.setLoadMoreVisibility=K,e(document).delegate(".wpd-vote-up.wpd_not_clicked, .wpd-vote-down.wpd_not_clicked","click",function(){var t=e(this);e(t).removeClass("wpd_not_clicked");var a,o=B(V(t));a=e(this).hasClass("wpd-vote-up")?1:-1;var d=new FormData;d.append("action","wpdVoteOnComment"),d.append("commentId",o),d.append("voteType",a),ce(z,!0,d).done(function(d){if(e(t).addClass("wpd_not_clicked"),"object"==typeof d){if(d.success){if("total"===d.data.buttonsStyle){var n=e(".wpd-comment-footer .wpd-vote-result",e("#comment-"+o)),i=d.data.votes;n.text(i),n.removeClass("wpd-up wpd-down"),i>0&&n.addClass("wpd-up"),i<0&&n.addClass("wpd-down")}else{var s=e(".wpd-comment-footer .wpd-vote-result-like",e("#comment-"+o)),c=e(".wpd-comment-footer .wpd-vote-result-dislike",e("#comment-"+o));s.text(d.data.likeCount),c.text(d.data.dislikeCount),parseInt(d.data.likeCount)>0?s.addClass("wpd-up"):s.removeClass("wpd-up"),parseInt(d.data.dislikeCount)<0?c.addClass("wpd-down"):c.removeClass("wpd-down")}var p=e(".wpd-comment-footer .wpd-vote-up",e("#comment-"+o)),r=e(".wpd-comment-footer .wpd-vote-down",e("#comment-"+o));p.removeClass("wpd-up"),r.removeClass("wpd-down"),d.data.curUserReaction>0?p.addClass("wpd-up"):d.data.curUserReaction<0&&r.addClass("wpd-down")}else d.data&&wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[d.data],"error");se(d,o,a)}else console.log(d);e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(a,o,d){console.log(d),e(t).addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate("body","click",function(t){var a=e(".wpdiscuz-sort-buttons");e(t.target).hasClass("wpdf-sorting")||e(t.target).parent().hasClass("wpdf-sorting")?a.css({display:a.is(":visible")?"none":"flex"}):a.hide()}),e(document).delegate(".wpdiscuz-sort-button:not(.wpdiscuz-sort-button-active)","click",function(){var t=e(this),a=e(this).attr("data-sorting");if(a){e(".wpdiscuz-sort-button.wpdiscuz-sort-button-active").removeClass("wpdiscuz-sort-button-active").appendTo(".wpdiscuz-sort-buttons"),t.addClass("wpdiscuz-sort-button-active").prependTo(".wpdf-sorting");var o=new FormData;o.append("action","wpdSorting"),o.append("sorting",a);var d=e(".wpdf-active").attr("data-filter-type");o.append("wpdType",d||""),ce(z,!0,o).done(function(t){"object"==typeof t&&t.success&&(e("#wpdcom .wpd-comment").remove(),e("#wpdcom .wpd-thread-list").prepend(t.data.message),K(t,!1),M=1),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),window.onhashchange=function(){N(!1)},1!=m&&N(!1),e(document).delegate(".wpdiscuz-readmore","click",function(){var t=V(e(this)),a=B(t),o=new FormData;o.append("action","wpdReadMore"),o.append("commentId",a),ce(z,!0,o).done(function(o){"object"==typeof o?(o.success?(e("#comment-"+a+" .wpd-comment-text").html(" "+o.data.message),e("#wpdiscuz-readmore-"+t).remove()):console.log(o.data),se(o)):console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-required-group","change",function(){0!==e("input:checked",this).length?e("input",e(this)).removeAttr("required"):e("input",e(this)).attr("required","required")}),e(document).delegate(".wpdiscuz-spoiler","click",function(){e(this).next().slideToggle(),e(this).hasClass("wpdiscuz-spoiler-closed")?e(this).parents(".wpdiscuz-spoiler-wrap").find(".fa-plus").removeClass("fa-plus").addClass("fa-minus"):e(this).parents(".wpdiscuz-spoiler-wrap").find(".fa-minus").removeClass("fa-minus").addClass("fa-plus"),e(this).toggleClass("wpdiscuz-spoiler-closed")}),e(document).delegate(".wpd-tools i","click",function(){var t=e(this).siblings(".wpd-tools-actions");t.css({display:t.is(":visible")?"none":"flex"})}),e(document).delegate(".wpd-comment-right","mouseleave",function(){e(this).find(".wpd-tools-actions").hide()}),e(document).delegate(".wpd_stick_btn","click",function(){var t=B(V(e(this),0)),a=new FormData;a.append("action","wpdStickComment"),a.append("commentId",t),ce(z,!0,a).done(function(t){"object"==typeof t&&t.success&&location.reload(!0),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd_close_btn","click",function(){var t=B(V(e(this),0)),a=new FormData;a.append("action","wpdCloseThread"),a.append("commentId",t),ce(z,!0,a).done(function(t){"object"==typeof t&&t.success&&location.reload(!0),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-filter.wpd_not_clicked[data-filter-type]","click",function(){var t=e(this),a=t.attr("data-filter-type");wpdiscuzAjaxObj.resetActiveFilters(".wpdf-"+a),t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var o=new FormData;o.append("action","wpdLoadMoreComments");var d=e(".wpdiscuz-sort-button-active").attr("data-sorting");d&&o.append("sorting",d),o.append("lastParentId",0),o.append("offset",0),M=1,o.append("wpdType",t.hasClass("wpdf-active")?"":a),o.append("isFirstLoad",1),e(this).hasClass("wpdf-inline")?e(this).hasClass("wpdf-active")?e(".wpd-comment-info-bar").hide():e(".wpd-comment-info-bar").css("display","flex"):e(".wpd-comment-info-bar").hide(),ce(z,!1,o).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(t.toggleClass("wpdf-active"),e(".wpd-load-comments").remove(),e(".wpd-comment").remove(),e(".wpd-thread-list").prepend(a.data.comment_list),K(a),r=a.data.loadLastCommentId,e(".wpd-load-more-submit").blur(),se(a)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpdf-reacted.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=new FormData;a.append("action","wpdMostReactedComment"),ce(z,!1,a).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(e("#comment-"+a.data.parentCommentID).length?e("#comment-"+a.data.parentCommentID).parents("[id^=wpd-comm-"+a.data.parentCommentID+"]").replaceWith(a.data.message):e("#comment-"+a.data.commentId).length||e(".wpd-thread-list").prepend(a.data.message),se(a),e("html, body").animate({scrollTop:e("#comment-"+a.data.commentId).offset().top-32},1e3))}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner")})}),e(document).delegate(".wpdf-hottest.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=new FormData;a.append("action","wpdHottestThread"),ce(z,!1,a).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(e("#comment-"+a.data.commentId).length?e("#comment-"+a.data.commentId).parents("[id^=wpd-comm-"+a.data.commentId+"]").replaceWith(a.data.message):e(".wpd-thread-list").prepend(a.data.message),se(a),e("html, body").animate({scrollTop:e("#comment-"+a.data.commentId).offset().top-32},1e3))}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner")})}),e(document).delegate(".wpd-filter-view-all","click",function(){e(".wpdf-inline.wpdf-active.wpd_not_clicked").trigger("click")}),e(document).delegate(".wpd-follow-link.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=B(V(t,0)),o=new FormData;o.append("action","wpdFollowUser"),o.append("commentId",a),ce(z,!0,o).done(function(a){t.addClass("wpd_not_clicked"),"object"==typeof a?a.success?(wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data.code],"success"),t.removeClass("wpd-follow-active"),a.data.followTip&&t.attr("wpd-tooltip",a.data.followTip),a.data.followClass&&t.addClass(a.data.followClass)):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"):console.log(a),e(".fas",t).removeClass("fa-pulse fa-spinner"),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner"),e("#wpdiscuz-loading-bar").fadeOut(250)})}),Z(),e(document).delegate(".wc_email","keyup",function(){Z(e(this))}),j){if(e("#wpd-bubble-wrapper").hover(function(){e(this).addClass("wpd-bubble-hover")},function(){e(this).removeClass("wpd-bubble-hover")}),k&&!Cookies.get(wpdiscuzAjaxObj.cookieHideBubbleHint)&&setTimeout(function(){e("#wpd-bubble-wrapper").addClass("wpd-bubble-hover"),Cookies.set(wpdiscuzAjaxObj.cookieHideBubbleHint,"1",{expires:7,path:"/"}),setTimeout(function(){e("#wpd-bubble-wrapper").removeClass("wpd-bubble-hover")},1e3*x)},1e3*k),"content_left"===O)if(e(".entry-content").length){var ee=(te=Math.min(e(".entry-content").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else if(e(".post-entry").length){ee=(te=Math.min(e(".post-entry").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else if(e(".container").length){var te;ee=(te=Math.min(e(".container").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else e("#wpd-bubble-wrapper").css({left:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-corner");else"left_corner"===O?(e("#wpd-bubble-wrapper").css({left:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-corner")):"right_corner"===O&&(e("#wpd-bubble-wrapper").css({right:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-right-corner"));e("#wpd-bubble-wrapper").show(),e("#wpd-bubble-add-message-close").click(function(t){t.preventDefault(),t.stopPropagation(),e("#wpd-bubble-wrapper").removeClass("wpd-bubble-hover")}),e("#wpd-bubble").click(function(){e("html, body").animate({scrollTop:e("#wpdcom").offset().top-60},1e3,function(){wpdiscuzLoadRichEditor?wpDiscuzEditor.createEditor("#wpd-editor-0_0").focus():e("#wc-textarea-0_0").focus()})}),e("#wpd-bubble-comment-close").click(function(t){t.preventDefault(),e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added")}),e("#wpd-bubble-comment-reply-link a").click(function(){var t=e(this).attr("href");setTimeout(function(){e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added"),N(!0);var a=t.match(/#comment\-(\d+)/);D=D.filter(function(e){return e!=a[1]}),e("#wpd-bubble-count .wpd-new-comments-count").text(D.length),0==D.length&&e("#wpd-bubble-count").removeClass("wpd-new-comments")},100)}),e("#wpd-bubble-count").click(function(){if(D.length){var t=new FormData;t.append("action","wpdBubbleUpdate"),t.append("newCommentIds",D.join()),ce(z,!0,t).done(function(t){"object"==typeof t&&t.success&&(t.data.message=t.data.message.filter(function(t){if(!e("#comment-"+t.comment_id).length)return t}),Q(t),e("#wpd-bubble-count").removeClass("wpd-new-comments"),e("#wpd-bubble-count .wpd-new-comments-count").text("0"),D=[],e("html, body").animate({scrollTop:e(e(".wpd-new-loaded-comment")[0]).offset().top-60},1e3),se(t)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(e,t,a){console.log(a)})}})}if((j&&C||s)&&(t||!t&&p)&&setTimeout(function t(){e.ajax({type:"GET",url:wpdiscuzAjaxObj.bubbleUpdateUrl,data:{postId:i,lastId:l,visibleCommentIds:Y()}}).done(function(a){if(!E)if("object"==typeof a){if(a.ids.length){s&&((n=new FormData).append("action","wpdUpdateAutomatically"),n.append("loadLastCommentId",r),n.append("visibleCommentIds",Y()),ce(z,!1,n).done(function(t){E||"object"==typeof t&&t.success&&(Q(t),e(".wpd-thread-info").html(t.data.wc_all_comments_count_new_html),t.data.wc_all_comments_count_new=parseInt(t.data.wc_all_comments_count_new),e("#wpd-bubble-all-comments-count").text(t.data.wc_all_comments_count_new),t.data.wc_all_comments_count_new?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),r=t.data.loadLastCommentId)}).fail(function(e,t,a){console.log(a)})),a.ids=a.ids.filter(function(t){if(!e("#comment-"+t).length)return t});var o=5e3;l=parseInt(a.ids[a.ids.length-1]),D=D.concat(a.ids),y&&a.commentText&&(e("#wpd-bubble-author-avatar").html(a.avatar),e("#wpd-bubble-author-name").html(a.authorName),e("#wpd-bubble-comment-date span").html(a.commentDate),e("#wpd-bubble-comment-text").html(a.commentText),e("#wpd-bubble-comment-reply-link a").attr("href",a.commentLink),e("#wpd-bubble-notification-message").show(),o=1e4);var d=parseInt(e(".wpd-new-comments-count").text());d+=a.ids.length,e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added"),e("#wpd-bubble-wrapper").addClass("wpd-new-comment-added"),setTimeout(function(){e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added")},o),e(".wpd-new-comments-count").text(d),e("#wpd-bubble-count").addClass("wpd-new-comments"),a.all_comments_count=parseInt(a.all_comments_count),e("#wpd-bubble-all-comments-count").text(a.all_comments_count),a.all_comments_count?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),e(".wpd-thread-info").html(a.all_comments_count_html)}}else console.log(a);var n;setTimeout(t,c)}).fail(function(e,a,o){console.log(o),setTimeout(t,c)})},c),e(".wpd-inline-form-wrapper").length){var ae=new FormData;ae.append("action","wpdGetInlineCommentForm"),ce(z,!1,ae).done(function(t){"object"==typeof t?t.success?(e(".wpd-inline-form-wrapper").append(t.data),e.each(e("[name=_wpd_inline_nonce]"),function(){var t=e(this).attr("id"),a=e(this).parents(".wpd-inline-shortcode").attr("id");e(this).attr("id",t+"-"+a.substring(a.lastIndexOf("-")+1))}),e(".wpd-inline-opened").addClass("wpd-active"),e(".wpd-inline-opened").find(".wpd-inline-form-wrapper").show(),e(".wpd-inline-opened").find(".wpd-inline-icon").addClass("wpd-open"),e(".wpd-inline-opened").find(".wpd-inline-icon").removeClass("wpd-ignored"),ie()):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error"):console.log(t)}).fail(function(e,t,a){console.log(a)})}function oe(t){if(e(t).hasClass("wpd-inline-shortcode"))var a=e(t).attr("id");else a=e(t).parents(".wpd-inline-shortcode").attr("id");return a.substring(a.lastIndexOf("-")+1)}function de(){e(".wpd-inline-form-wrapper").hide(),e(".wpd-inline-shortcode").removeClass("wpd-active"),e(".wpd-inline-icon").removeClass("wpd-open")}function ne(){e.each(e(".wpd-inline-shortcode:not(.wpd-inline-opened) .wpd-inline-icon"),function(){var t=e(this),a=t.offset().top-window.pageYOffset;a>0&&a<300&&("blink"===A?(t.addClass("wpd-blink"),setTimeout(function(){t.removeClass("wpd-blink")},3e3)):(t.parents(".wpd-inline-shortcode").addClass("wpd-active"),t.siblings(".wpd-inline-form-wrapper").show(),t.addClass("wpd-open"),ie(t.siblings(".wpd-inline-form-wrapper"))))})}function ie(t){if(t){if(t.offset().left<=10)t.css("left",Math.ceil(parseInt(t.css("left"))-t.offset().left+10)),(a=Math.ceil(t.siblings(".wpd-inline-icon.wpd-open").offset().left-t.offset().left+2))<3&&(a=3),document.styleSheets[0].addRule("#"+t.parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+a+"px;");else if(t.offset().left+t.width()>document.body.clientWidth-10){var a;t.css("left",Math.ceil(parseInt(t.css("left"))+(document.body.clientWidth-(t.offset().left+t.width()))-10)),(a=Math.ceil(t.siblings(".wpd-inline-icon.wpd-open").offset().left-t.offset().left+2))>t.width()-3&&(a=t.width()-3),document.styleSheets[0].addRule("#"+t.parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+a+"px;")}}else e.each(e(".wpd-inline-form-wrapper:visible"),function(){if(e(this).offset().left<=10)e(this).css("left",Math.ceil(parseInt(e(this).css("left"))-e(this).offset().left+10)),(t=Math.ceil(e(this).siblings(".wpd-inline-icon.wpd-open").offset().left-e(this).offset().left+2))<3&&(t=3),document.styleSheets[0].addRule("#"+e(this).parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+t+"px;");else if(e(this).offset().left+e(this).width()>document.body.clientWidth-10){var t;e(this).css("left",Math.ceil(parseInt(e(this).css("left"))+(document.body.clientWidth-(e(this).offset().left+e(this).width()))-10)),(t=Math.ceil(e(this).siblings(".wpd-inline-icon.wpd-open").offset().left-e(this).offset().left+2))>e(this).width()-3&&(t=e(this).width()-3),document.styleSheets[0].addRule("#"+e(this).parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+t+"px;")}})}function se(t,a,o,d){t.data.callbackFunctions&&e.each(t.data.callbackFunctions,function(e){"function"==typeof wpdiscuzAjaxObj[t.data.callbackFunctions[e]]?wpdiscuzAjaxObj[t.data.callbackFunctions[e]](t,a,o,d):console.log(t.data.callbackFunctions[e]+" is not a function")})}function ce(t,a,o){a&&e("#wpdiscuz-loading-bar").show(),o.append("postId",i);var d=o.get("action");wpdiscuzAjaxObj.dataFilterCallbacks&&wpdiscuzAjaxObj.dataFilterCallbacks[d]&&e.each(wpdiscuzAjaxObj.dataFilterCallbacks[d],function(e){"function"==typeof wpdiscuzAjaxObj[wpdiscuzAjaxObj.dataFilterCallbacks[d][e]]&&(o=wpdiscuzAjaxObj[wpdiscuzAjaxObj.dataFilterCallbacks[d][e]](o,t,a))});var n=t?wpdiscuzAjaxObj.url:wpdiscuzAjaxObj.customAjaxUrl;return e.ajax({type:"POST",url:n,data:o,contentType:!1,processData:!1})}e(document).delegate("body","click",function(t){if(e(t.target).hasClass("wpd-inline-form-close")||e(t.target).parents(".wpd-inline-form-close").length)t.preventDefault(),e(t.target).parents(".wpd-inline-form-wrapper").hide(),e(t.target).parents(".wpd-inline-shortcode").removeClass("wpd-active"),e(t.target).parents(".wpd-inline-form-wrapper").siblings(".wpd-inline-icon").removeClass("wpd-open");else if(!e(t.target).hasClass("wpd-inline-form-wrapper")&&!e(t.target).parents(".wpd-inline-form-wrapper").length){de();var a="";e(t.target).hasClass("wpd-inline-icon")?a=e(t.target):e(t.target).parents(".wpd-inline-icon").length&&(a=e(t.target).parents(".wpd-inline-icon")),a.length&&(a.parents(".wpd-inline-shortcode").addClass("wpd-active"),a.siblings(".wpd-inline-form-wrapper").show(),a.addClass("wpd-open"),a.removeClass("wpd-ignored"),ie(a.siblings(".wpd-inline-form-wrapper")))}(!e(t.target).hasClass("wpd-last-inline-comments-wrapper")&&!e(t.target).parents(".wpd-last-inline-comments-wrapper").length||e(t.target).parents(".wpd-last-inline-comments-wrapper").length&&e(t.target).hasClass("wpd-load-inline-comment"))&&e(".wpd-last-inline-comments-wrapper").remove()}),e(document).delegate(".wpd-inline-submit.wpd_not_clicked","click",function(t){t.preventDefault();var a=e(this),o=e(this).parents(".wpd_inline_comm_form");if(o[0].checkValidity()){e(this).removeClass("wpd_not_clicked");var d=new FormData;d.append("action","wpdAddInlineComment"),d.append("inline_form_id",oe(o)),e.each(e("input, textarea",o),function(t,a){"checkbox"===this.type?e(this).is(":checked")&&d.append(e(a).attr("name"),e(a).val()):d.append(e(a).attr("name"),e(a).val())}),ce(z,!0,d).done(function(t){if(a.addClass("wpd_not_clicked"),"object"==typeof t)if(t.success){o[0].reset(),de();var d=parseInt(t.data.newCount),n=a.parents(".wpd-inline-icon-wrapper").find(".wpd-inline-icon-count");n.text(d),d?n.addClass("wpd-has-comments"):n.removeClass("wpd-has-comments"),e(".wpd-thread-info").html(t.data.allCommentsCountNewHtml),t.data.allCommentsCountNew=parseInt(t.data.allCommentsCountNew),e("#wpd-bubble-all-comments-count").text(t.data.allCommentsCountNew),t.data.allCommentsCountNew?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),t.data.message&&X(t.data.message),wpdiscuzAjaxObj.setCommentMessage(t.data.notification,"success")}else t.data&&wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error");else wpdiscuzAjaxObj.setCommentMessage(t,"error");e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(document).delegate(".wpd-form","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).find(".wc_comm_submit").trigger("click")}),e(document).delegate("#wpdiscuz-edit-form","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).find(".wc_save_edited_comment").trigger("click")}),e(document).delegate(".wpd-inline-comment-content","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).parents(".wpd_inline_comm_form").find(".wpd-inline-submit.wpd_not_clicked").trigger("click")}),e(document).delegate(".wpd-inline-icon-count.wpd-has-comments","click",function(){var t=e(this),a=new FormData;a.append("action","wpdGetLastInlineComments"),a.append("inline_form_id",oe(t)),ce(z,!0,a).done(function(a){"object"==typeof a?a.success?e(a.data).insertAfter(t):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"):console.log(a),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-view-all-inline-comments","click",function(t){t.preventDefault(),e(this).parents(".wpd-last-inline-comments-wrapper").remove(),e(".wpdf-inline").hasClass("wpdf-active")||e(".wpdf-inline").trigger("click"),e("html, body").animate({scrollTop:e(".wpdf-inline").offset().top-32},1e3)}),e(document).delegate(".wpd-feedback-content-link","click",function(t){t.preventDefault();var a=e(this).data("feedback-content-id");e("html, body").animate({scrollTop:e("#wpd-inline-"+a).offset().top-38},1e3,function(){e("#wpd-inline-"+a).addClass("wpd-active")})}),"scroll_open"!==A&&"blink"!==A||(ne(),e(window).scroll(ne)),e(document).delegate("#wpd-post-rating.wpd-not-rated .wpd-rate-starts svg","click",function(){var t=new FormData,a=e(this).index();a>=0&&a<5&&(t.append("action","wpdUserRate"),t.append("rating",a+1),ce(z,!0,t).done(function(t){"object"==typeof t?t.success?location.reload(!0):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error"):console.log(t),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}))}),e("#wpdiscuz-subscribe-form").submit(function(t){t.preventDefault();var a,o,n=e(this);if(n[0].checkValidity()&&(a=n,o=!0,"2.0"===d&&e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).length&&!e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).val().length?(o=!1,e(".wpdiscuz-recaptcha",a).css("border","1px solid red")):"2.0"===d&&e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).length&&e(".wpdiscuz-recaptcha",a).css("border","none"),o)){var i=new FormData;i.append("action","wpdAddSubscription"),e("*",n).each(function(){""!=this.name&&"checkbox"!=this.type&&"radio"!=this.type&&i.append(this.name+"",e(this).val()),"checkbox"!=this.type&&"radio"!=this.type||e(this).is(":checked")&&i.append(this.name+"",e(this).val())}),ce(z,!0,i).done(function(t){"object"==typeof t?t.success?(wpdiscuzAjaxObj.setCommentMessage(t.data,"success"),setTimeout(function(){location.reload(!0)},3e3)):wpdiscuzAjaxObj.setCommentMessage(t.data,"error"):wpdiscuzAjaxObj.setCommentMessage(t,"error"),e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(".wpd-unsubscribe").click(function(t){t.preventDefault();var a=new FormData;a.append("action","wpdUnsubscribe"),a.append("sid",e(this).data("sid")),a.append("skey",e(this).data("skey")),ce(z,!0,a).done(function(t){"object"==typeof t?t.success?(wpdiscuzAjaxObj.setCommentMessage(t.data,"success"),setTimeout(function(){location.reload(!0)},3e3)):wpdiscuzAjaxObj.setCommentMessage(t.data,"error"):console.log(t),e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),wpdiscuzAjaxObj.resetActiveFilters=function(t){e(".wpd-filter.wpdf-active"+(t?":not("+t+")":"")).removeClass("wpdf-active")},wpdiscuzAjaxObj.getAjaxObj=ce});var onloadCallback=function(){if(document.getElementById("wpdiscuz-recaptcha-0_0")&&"2.0"===wpdiscuzAjaxObj.wpDiscuzReCaptchaVersion&&(1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!wpdiscuzAjaxObj.is_user_logged_in||1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&wpdiscuzAjaxObj.is_user_logged_in))try{grecaptcha.render("wpdiscuz-recaptcha-0_0",{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(e){jQuery("#wpdiscuz-recaptcha-field-0_0").val("key")},"expired-callback":function(){jQuery("#wpdiscuz-recaptcha-field-0_0").val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}};
7
  /* Colorbox */
8
  (function(t,e,i){function n(i,n,o){var r=e.createElement(i);return n&&(r.id=Z+n),o&&(r.style.cssText=o),t(r)}function o(){return i.innerHeight?i.innerHeight:t(i).height()}function r(e,i){i!==Object(i)&&(i={}),this.cache={},this.el=e,this.value=function(e){var n;return void 0===this.cache[e]&&(n=t(this.el).attr("data-cbox-"+e),void 0!==n?this.cache[e]=n:void 0!==i[e]?this.cache[e]=i[e]:void 0!==X[e]&&(this.cache[e]=X[e])),this.cache[e]},this.get=function(e){var i=this.value(e);return t.isFunction(i)?i.call(this.el,this):i}}function h(t){var e=W.length,i=(A+t)%e;return 0>i?e+i:i}function a(t,e){return Math.round((/%/.test(t)?("x"===e?E.width():o())/100:1)*parseInt(t,10))}function s(t,e){return t.get("photo")||t.get("photoRegex").test(e)}function l(t,e){return t.get("retinaUrl")&&i.devicePixelRatio>1?e.replace(t.get("photoRegex"),t.get("retinaSuffix")):e}function d(t){"contains"in x[0]&&!x[0].contains(t.target)&&t.target!==v[0]&&(t.stopPropagation(),x.focus())}function c(t){c.str!==t&&(x.add(v).removeClass(c.str).addClass(t),c.str=t)}function g(e){A=0,e&&e!==!1&&"nofollow"!==e?(W=t("."+te).filter(function(){var i=t.data(this,Y),n=new r(this,i);return n.get("rel")===e}),A=W.index(_.el),-1===A&&(W=W.add(_.el),A=W.length-1)):W=t(_.el)}function u(i){t(e).trigger(i),ae.triggerHandler(i)}function f(i){var o;if(!G){if(o=t(i).data(Y),_=new r(i,o),g(_.get("rel")),!U){U=$=!0,c(_.get("className")),x.css({visibility:"hidden",display:"block",opacity:""}),I=n(se,"LoadedContent","width:0; height:0; overflow:hidden; visibility:hidden"),b.css({width:"",height:""}).append(I),j=T.height()+k.height()+b.outerHeight(!0)-b.height(),D=C.width()+H.width()+b.outerWidth(!0)-b.width(),N=I.outerHeight(!0),z=I.outerWidth(!0);var h=a(_.get("initialWidth"),"x"),s=a(_.get("initialHeight"),"y"),l=_.get("maxWidth"),f=_.get("maxHeight");_.w=Math.max((l!==!1?Math.min(h,a(l,"x")):h)-z-D,0),_.h=Math.max((f!==!1?Math.min(s,a(f,"y")):s)-N-j,0),I.css({width:"",height:_.h}),J.position(),u(ee),_.get("onOpen"),O.add(F).hide(),x.focus(),_.get("trapFocus")&&e.addEventListener&&(e.addEventListener("focus",d,!0),ae.one(re,function(){e.removeEventListener("focus",d,!0)})),_.get("returnFocus")&&ae.one(re,function(){t(_.el).focus()})}var p=parseFloat(_.get("opacity"));v.css({opacity:p===p?p:"",cursor:_.get("overlayClose")?"pointer":"",visibility:"visible"}).show(),_.get("closeButton")?B.html(_.get("close")).appendTo(b):B.appendTo("<div/>"),w()}}function p(){x||(V=!1,E=t(i),x=n(se).attr({id:Y,"class":t.support.opacity===!1?Z+"IE":"",role:"dialog",tabindex:"-1"}).hide(),v=n(se,"Overlay").hide(),L=t([n(se,"LoadingOverlay")[0],n(se,"LoadingGraphic")[0]]),y=n(se,"Wrapper"),b=n(se,"Content").append(F=n(se,"Title"),R=n(se,"Current"),P=t('<button type="button"/>').attr({id:Z+"Previous"}),K=t('<button type="button"/>').attr({id:Z+"Next"}),S=t('<button type="button"/>').attr({id:Z+"Slideshow"}),L),B=t('<button type="button"/>').attr({id:Z+"Close"}),y.append(n(se).append(n(se,"TopLeft"),T=n(se,"TopCenter"),n(se,"TopRight")),n(se,!1,"clear:left").append(C=n(se,"MiddleLeft"),b,H=n(se,"MiddleRight")),n(se,!1,"clear:left").append(n(se,"BottomLeft"),k=n(se,"BottomCenter"),n(se,"BottomRight"))).find("div div").css({"float":"left"}),M=n(se,!1,"position:absolute; width:9999px; visibility:hidden; display:none; max-width:none;"),O=K.add(P).add(R).add(S)),e.body&&!x.parent().length&&t(e.body).append(v,x.append(y,M))}function m(){function i(t){t.which>1||t.shiftKey||t.altKey||t.metaKey||t.ctrlKey||(t.preventDefault(),f(this))}return x?(V||(V=!0,K.click(function(){J.next()}),P.click(function(){J.prev()}),B.click(function(){J.close()}),v.click(function(){_.get("overlayClose")&&J.close()}),t(e).bind("keydown."+Z,function(t){var e=t.keyCode;U&&_.get("escKey")&&27===e&&(t.preventDefault(),J.close()),U&&_.get("arrowKey")&&W[1]&&!t.altKey&&(37===e?(t.preventDefault(),P.click()):39===e&&(t.preventDefault(),K.click()))}),t.isFunction(t.fn.on)?t(e).on("click."+Z,"."+te,i):t("."+te).live("click."+Z,i)),!0):!1}function w(){var e,o,r,h=J.prep,d=++le;if($=!0,q=!1,u(he),u(ie),_.get("onLoad"),_.h=_.get("height")?a(_.get("height"),"y")-N-j:_.get("innerHeight")&&a(_.get("innerHeight"),"y"),_.w=_.get("width")?a(_.get("width"),"x")-z-D:_.get("innerWidth")&&a(_.get("innerWidth"),"x"),_.mw=_.w,_.mh=_.h,_.get("maxWidth")&&(_.mw=a(_.get("maxWidth"),"x")-z-D,_.mw=_.w&&_.w<_.mw?_.w:_.mw),_.get("maxHeight")&&(_.mh=a(_.get("maxHeight"),"y")-N-j,_.mh=_.h&&_.h<_.mh?_.h:_.mh),e=_.get("href"),Q=setTimeout(function(){L.show()},100),_.get("inline")){var c=t(e).eq(0);r=t("<div>").hide().insertBefore(c),ae.one(he,function(){r.replaceWith(c)}),h(c)}else _.get("iframe")?h(" "):_.get("html")?h(_.get("html")):s(_,e)?(e=l(_,e),q=_.get("createImg"),t(q).addClass(Z+"Photo").bind("error."+Z,function(){h(n(se,"Error").html(_.get("imgError")))}).one("load",function(){d===le&&setTimeout(function(){var e;_.get("retinaImage")&&i.devicePixelRatio>1&&(q.height=q.height/i.devicePixelRatio,q.width=q.width/i.devicePixelRatio),_.get("scalePhotos")&&(o=function(){q.height-=q.height*e,q.width-=q.width*e},_.mw&&q.width>_.mw&&(e=(q.width-_.mw)/q.width,o()),_.mh&&q.height>_.mh&&(e=(q.height-_.mh)/q.height,o())),_.h&&(q.style.marginTop=Math.max(_.mh-q.height,0)/2+"px"),W[1]&&(_.get("loop")||W[A+1])&&(q.style.cursor="pointer",t(q).bind("click."+Z,function(){J.next()})),q.style.width=q.width+"px",q.style.height=q.height+"px",h(q)},1)}),q.src=e):e&&M.load(e,_.get("data"),function(e,i){d===le&&h("error"===i?n(se,"Error").html(_.get("xhrError")):t(this).contents())})}var v,x,y,b,T,C,H,k,W,E,I,M,L,F,R,S,K,P,B,O,_,j,D,N,z,A,q,U,$,G,Q,J,V,X={html:!1,photo:!1,iframe:!1,inline:!1,transition:"elastic",speed:300,fadeOut:300,width:!1,initialWidth:"600",innerWidth:!1,maxWidth:!1,height:!1,initialHeight:"450",innerHeight:!1,maxHeight:!1,scalePhotos:!0,scrolling:!0,opacity:.9,preloading:!0,className:!1,overlayClose:!0,escKey:!0,arrowKey:!0,top:!1,bottom:!1,left:!1,right:!1,fixed:!1,data:void 0,closeButton:!0,fastIframe:!0,open:!1,reposition:!0,loop:!0,slideshow:!1,slideshowAuto:!0,slideshowSpeed:2500,slideshowStart:"start slideshow",slideshowStop:"stop slideshow",photoRegex:/\.(gif|png|jp(e|g|eg)|bmp|ico|webp|jxr|svg)((#|\?).*)?$/i,retinaImage:!1,retinaUrl:!1,retinaSuffix:"@2x.$1",current:"image {current} of {total}",previous:"previous",next:"next",close:"close",xhrError:"This content failed to load.",imgError:"This image failed to load.",returnFocus:!0,trapFocus:!0,onOpen:!1,onLoad:!1,onComplete:!1,onCleanup:!1,onClosed:!1,rel:function(){return this.rel},href:function(){return t(this).attr("href")},title:function(){return this.title},createImg:function(){var e=new Image,i=t(this).data("cbox-img-attrs");return"object"==typeof i&&t.each(i,function(t,i){e[t]=i}),e},createIframe:function(){var i=e.createElement("iframe"),n=t(this).data("cbox-iframe-attrs");return"object"==typeof n&&t.each(n,function(t,e){i[t]=e}),"frameBorder"in i&&(i.frameBorder=0),"allowTransparency"in i&&(i.allowTransparency="true"),i.name=(new Date).getTime(),i.allowFullscreen=!0,i}},Y="colorbox",Z="cbox",te=Z+"Element",ee=Z+"_open",ie=Z+"_load",ne=Z+"_complete",oe=Z+"_cleanup",re=Z+"_closed",he=Z+"_purge",ae=t("<a/>"),se="div",le=0,de={},ce=function(){function t(){clearTimeout(h)}function e(){(_.get("loop")||W[A+1])&&(t(),h=setTimeout(J.next,_.get("slideshowSpeed")))}function i(){S.html(_.get("slideshowStop")).unbind(s).one(s,n),ae.bind(ne,e).bind(ie,t),x.removeClass(a+"off").addClass(a+"on")}function n(){t(),ae.unbind(ne,e).unbind(ie,t),S.html(_.get("slideshowStart")).unbind(s).one(s,function(){J.next(),i()}),x.removeClass(a+"on").addClass(a+"off")}function o(){r=!1,S.hide(),t(),ae.unbind(ne,e).unbind(ie,t),x.removeClass(a+"off "+a+"on")}var r,h,a=Z+"Slideshow_",s="click."+Z;return function(){r?_.get("slideshow")||(ae.unbind(oe,o),o()):_.get("slideshow")&&W[1]&&(r=!0,ae.one(oe,o),_.get("slideshowAuto")?i():n(),S.show())}}();t[Y]||(t(p),J=t.fn[Y]=t[Y]=function(e,i){var n,o=this;return e=e||{},t.isFunction(o)&&(o=t("<a/>"),e.open=!0),o[0]?(p(),m()&&(i&&(e.onComplete=i),o.each(function(){var i=t.data(this,Y)||{};t.data(this,Y,t.extend(i,e))}).addClass(te),n=new r(o[0],e),n.get("open")&&f(o[0])),o):o},J.position=function(e,i){function n(){T[0].style.width=k[0].style.width=b[0].style.width=parseInt(x[0].style.width,10)-D+"px",b[0].style.height=C[0].style.height=H[0].style.height=parseInt(x[0].style.height,10)-j+"px"}var r,h,s,l=0,d=0,c=x.offset();if(E.unbind("resize."+Z),x.css({top:-9e4,left:-9e4}),h=E.scrollTop(),s=E.scrollLeft(),_.get("fixed")?(c.top-=h,c.left-=s,x.css({position:"fixed"})):(l=h,d=s,x.css({position:"absolute"})),d+=_.get("right")!==!1?Math.max(E.width()-_.w-z-D-a(_.get("right"),"x"),0):_.get("left")!==!1?a(_.get("left"),"x"):Math.round(Math.max(E.width()-_.w-z-D,0)/2),l+=_.get("bottom")!==!1?Math.max(o()-_.h-N-j-a(_.get("bottom"),"y"),0):_.get("top")!==!1?a(_.get("top"),"y"):Math.round(Math.max(o()-_.h-N-j,0)/2),x.css({top:c.top,left:c.left,visibility:"visible"}),y[0].style.width=y[0].style.height="9999px",r={width:_.w+z+D,height:_.h+N+j,top:l,left:d},e){var g=0;t.each(r,function(t){return r[t]!==de[t]?(g=e,void 0):void 0}),e=g}de=r,e||x.css(r),x.dequeue().animate(r,{duration:e||0,complete:function(){n(),$=!1,y[0].style.width=_.w+z+D+"px",y[0].style.height=_.h+N+j+"px",_.get("reposition")&&setTimeout(function(){E.bind("resize."+Z,J.position)},1),t.isFunction(i)&&i()},step:n})},J.resize=function(t){var e;U&&(t=t||{},t.width&&(_.w=a(t.width,"x")-z-D),t.innerWidth&&(_.w=a(t.innerWidth,"x")),I.css({width:_.w}),t.height&&(_.h=a(t.height,"y")-N-j),t.innerHeight&&(_.h=a(t.innerHeight,"y")),t.innerHeight||t.height||(e=I.scrollTop(),I.css({height:"auto"}),_.h=I.height()),I.css({height:_.h}),e&&I.scrollTop(e),J.position("none"===_.get("transition")?0:_.get("speed")))},J.prep=function(i){function o(){return _.w=_.w||I.width(),_.w=_.mw&&_.mw<_.w?_.mw:_.w,_.w}function a(){return _.h=_.h||I.height(),_.h=_.mh&&_.mh<_.h?_.mh:_.h,_.h}if(U){var d,g="none"===_.get("transition")?0:_.get("speed");I.remove(),I=n(se,"LoadedContent").append(i),I.hide().appendTo(M.show()).css({width:o(),overflow:_.get("scrolling")?"auto":"hidden"}).css({height:a()}).prependTo(b),M.hide(),t(q).css({"float":"none"}),c(_.get("className")),d=function(){function i(){t.support.opacity===!1&&x[0].style.removeAttribute("filter")}var n,o,a=W.length;U&&(o=function(){clearTimeout(Q),L.hide(),u(ne),_.get("onComplete")},F.html(_.get("title")).show(),I.show(),a>1?("string"==typeof _.get("current")&&R.html(_.get("current").replace("{current}",A+1).replace("{total}",a)).show(),K[_.get("loop")||a-1>A?"show":"hide"]().html(_.get("next")),P[_.get("loop")||A?"show":"hide"]().html(_.get("previous")),ce(),_.get("preloading")&&t.each([h(-1),h(1)],function(){var i,n=W[this],o=new r(n,t.data(n,Y)),h=o.get("href");h&&s(o,h)&&(h=l(o,h),i=e.createElement("img"),i.src=h)})):O.hide(),_.get("iframe")?(n=_.get("createIframe"),_.get("scrolling")||(n.scrolling="no"),t(n).attr({src:_.get("href"),"class":Z+"Iframe"}).one("load",o).appendTo(I),ae.one(he,function(){n.src="//about:blank"}),_.get("fastIframe")&&t(n).trigger("load")):o(),"fade"===_.get("transition")?x.fadeTo(g,1,i):i())},"fade"===_.get("transition")?x.fadeTo(g,0,function(){J.position(0,d)}):J.position(g,d)}},J.next=function(){!$&&W[1]&&(_.get("loop")||W[A+1])&&(A=h(1),f(W[A]))},J.prev=function(){!$&&W[1]&&(_.get("loop")||A)&&(A=h(-1),f(W[A]))},J.close=function(){U&&!G&&(G=!0,U=!1,u(oe),_.get("onCleanup"),E.unbind("."+Z),v.fadeTo(_.get("fadeOut")||0,0),x.stop().fadeTo(_.get("fadeOut")||0,0,function(){x.hide(),v.hide(),u(he),I.remove(),setTimeout(function(){G=!1,u(re),_.get("onClosed")},1)}))},J.remove=function(){x&&(x.stop(),t[Y].close(),x.stop(!1,!0).remove(),v.remove(),G=!1,x=null,t("."+te).removeData(Y).removeClass(te),t(e).unbind("click."+Z).unbind("keydown."+Z))},J.element=function(){return t(_.el)},J.settings=X)})(jQuery,document,window);
9
  /* Media Uploader */
3
  /* Autogrow */
4
  jQuery.fn.autoGrow=function(){return this.each(function(){var createMirror=function(textarea){jQuery(textarea).after('<div class="autogrow-textarea-mirror"></div>');return jQuery(textarea).next(".autogrow-textarea-mirror")[0]};var sendContentToMirror=function(textarea){mirror.innerHTML=String(textarea.value).replace(/&/g,"&amp;").replace(/"/g,"&quot;").replace(/'/g,"&#39;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/\n/g,"<br />")+".<br/>.";if(jQuery(textarea).height()!=jQuery(mirror).height())jQuery(textarea).height(jQuery(mirror).height())};var growTextarea=function(){sendContentToMirror(this)};var mirror=createMirror(this);mirror.style.display="none";mirror.style.wordWrap="break-word";mirror.style.padding=jQuery(this).css("padding");mirror.style.width=jQuery(this).css("width");mirror.style.fontFamily=jQuery(this).css("font-family");mirror.style.fontSize=jQuery(this).css("font-size");mirror.style.lineHeight=jQuery(this).css("line-height");this.style.overflow="hidden";this.style.minHeight=this.rows+"em";this.onkeydown=growTextarea;sendContentToMirror(this)})};
5
  /* wpDiscuz */
6
+ var wpdiscuzLoadRichEditor=parseInt(wpdiscuzAjaxObj.loadRichEditor);if(wpdiscuzLoadRichEditor)var wpDiscuzEditor=new WpdEditor;function wpdMessagesOnInit(e,t){wpdiscuzAjaxObj.setCommentMessage(e,t),setTimeout(function(){location.href=location.href.substring(0,location.href.indexOf("wpdiscuzUrlAnchor")-1)},3e3)}wpdiscuzAjaxObj.setCommentMessage=function(e,t,a){var o="wpdiscuz-message-error";if("[object Array]"===Object.prototype.toString.call(e))for(var d in e)"[object Array]"===Object.prototype.toString.call(t)?"success"===t[d]?o="wpdiscuz-message-success":"warning"===t[d]&&(o="wpdiscuz-message-warning"):"success"===t?o="wpdiscuz-message-success":"warning"===t&&(o="wpdiscuz-message-warning"),jQuery("<div/>").addClass(o).html(e[d]).prependTo("#wpdiscuz-comment-message").delay("[object Array]"===Object.prototype.toString.call(a)?a[d]:a||4e3).fadeOut(1e3,function(){jQuery(this).remove()});else"success"===t?o="wpdiscuz-message-success":"warning"===t&&(o="wpdiscuz-message-warning"),jQuery("<div/>").addClass(o).html(e).prependTo("#wpdiscuz-comment-message").delay(a||4e3).fadeOut(1e3,function(){jQuery(this).remove()})},jQuery(document).ready(function(e){e("body").addClass("wpdiscuz_"+wpdiscuzAjaxObj.version);var t=wpdiscuzAjaxObj.is_user_logged_in,a=1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!t,o=1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&t,d=wpdiscuzAjaxObj.wpDiscuzReCaptchaVersion,n=parseInt(wpdiscuzAjaxObj.commentListLoadType),s=parseInt(wpdiscuzAjaxObj.wc_post_id),i=parseInt(wpdiscuzAjaxObj.commentListUpdateType),c=1e3*parseInt(wpdiscuzAjaxObj.commentListUpdateTimer),p=parseInt(wpdiscuzAjaxObj.liveUpdateGuests),r=wpdiscuzAjaxObj.loadLastCommentId,l=r,m=parseInt(wpdiscuzAjaxObj.firstLoadWithAjax);Cookies.get("wpdiscuz_comments_sorting")&&Cookies.remove("wpdiscuz_comments_sorting",{path:""}),Cookies.get("wordpress_last_visit")&&Cookies.remove("wordpress_last_visit",{path:""}),Cookies.get("wpdiscuz_last_visit")&&Cookies.remove("wpdiscuz_last_visit",{path:""});var w,u=wpdiscuzAjaxObj.storeCommenterData,f=parseInt(wpdiscuzAjaxObj.wmuEnabled),h=wpdiscuzAjaxObj.isCookiesEnabled,b=!0,g=wpdiscuzAjaxObj.cookiehash,_=parseInt(wpdiscuzAjaxObj.isLoadOnlyParentComments),v=parseInt(wpdiscuzAjaxObj.enableDropAnimation)?500:0,z=parseInt(wpdiscuzAjaxObj.isNativeAjaxEnabled),j=parseInt(wpdiscuzAjaxObj.enableBubble),C=parseInt(wpdiscuzAjaxObj.bubbleLiveUpdate),k=parseInt(wpdiscuzAjaxObj.bubbleHintTimeout),x=parseInt(wpdiscuzAjaxObj.bubbleHintHideTimeout)?parseInt(wpdiscuzAjaxObj.bubbleHintHideTimeout):5,y=parseInt(wpdiscuzAjaxObj.bubbleShowNewCommentMessage),O=wpdiscuzAjaxObj.bubbleLocation,A=wpdiscuzAjaxObj.inlineFeedbackAttractionType,I=[],T=[],D=[],E=!1,M=1;(e(".wc_social_plugin_wrapper .wp-social-login-provider-list").length?e(".wc_social_plugin_wrapper .wp-social-login-provider-list").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .the_champ_login_container").length?e(".wc_social_plugin_wrapper .the_champ_login_container").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .social_connect_form").length?e(".wc_social_plugin_wrapper .social_connect_form").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .oneall_social_login_providers").length&&e(".wc_social_plugin_wrapper .oneall_social_login .oneall_social_login_providers").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"),wpdiscuzLoadRichEditor&&e("#wpd-editor-0_0").length&&wpDiscuzEditor.createEditor("#wpd-editor-0_0"),e(document).delegate("#wpdcom .ql-editor, #wpdcom .wc_comment","focus",function(){e(".wpd-form-foot",e(this).parents(".wpd_comm_form")).slideDown(v)}),e(document).delegate("#wpdcom textarea","focus",function(){e(this).next(".autogrow-textarea-mirror").length||e(this).autoGrow()}),t)||S({comment_author:Cookies.get("comment_author_"+g),comment_author_email:Cookies.get("comment_author_email_"+g),comment_author_url:Cookies.get("comment_author_url_"+g)});if(e(".wpd-vote-down.wpd-dislike-hidden").remove(),e(".wpd-toolbar-hidden").prev("[id^=wpd-editor-]").css("border-bottom","1px solid #dddddd"),e(document).delegate("#wpd-editor-source-code-wrapper-bg","click",function(){e(this).hide(),e("#wpd-editor-source-code-wrapper").hide(),e("#wpd-editor-uid").val(""),e("#wpd-editor-source-code").val("")}),wpdiscuzLoadRichEditor&&e(document).delegate("#wpd-insert-source-code","click",function(){var t=wpDiscuzEditor.createEditor("#"+e("#wpd-editor-uid").val());t.deleteText(0,t.getLength(),Quill.sources.USER);var a=e("#wpd-editor-source-code").val();a.length&&(console.log(a),t.clipboard.dangerouslyPasteHTML(0,a,Quill.sources.USER)),t.update(),e("#wpd-editor-source-code-wrapper-bg").hide(),e("#wpd-editor-source-code-wrapper").hide(),e("#wpd-editor-uid").val(""),e("#wpd-editor-source-code").val("")}),e(document).delegate(".wpd-reply-button","click",function(){var n=V(e(this),0);e(this).hasClass("wpdiscuz-clonned")?(wpdiscuzLoadRichEditor?setTimeout(function(){wpDiscuzEditor.createEditor("#wpd-editor-"+n).focus()},v):setTimeout(function(){e("#wc-textarea-"+n).trigger("focus")},v),e("#wpd-secondary-form-wrapper-"+n).slideToggle(v)):function(a){var o=V(a,0);e("#wpdiscuz_form_anchor-"+o).before(function(t){return e("#wpdiscuz_hidden_secondary_form").html().replace(/wpdiscuzuniqueid/g,t)}(o));var d=e("#wpd-secondary-form-wrapper-"+o);if(!t){var n={comment_author:Cookies.get("comment_author_"+g),comment_author_email:Cookies.get("comment_author_email_"+g),comment_author_url:Cookies.get("comment_author_url_"+g)};S(n)}wpdiscuzLoadRichEditor?setTimeout(function(){wpDiscuzEditor.createEditor("#wpd-editor-"+o).focus()},v):setTimeout(function(){e("#wc-textarea-"+o).trigger("focus")},v);d.slideToggle(v,function(){a.addClass("wpdiscuz-clonned")})}(e(this)),function(t){if((a||o)&&"2.0"===d){var n=B(t);setTimeout(function(){if(!T[n])try{T[n]=grecaptcha.render("wpdiscuz-recaptcha-"+t,{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(a){e("#wpdiscuz-recaptcha-field-"+t).val("key")},"expired-callback":function(){e("#wpdiscuz-recaptcha-field-"+t).val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}},1e3)}}(n)}),e(document).delegate("#wpdcom .wpd-comment-link [data-comment-url]","click",function(){var t=e(this).data("comment-url"),a=e("<input/>");a.appendTo("body").css({position:"absolute",top:"-10000000px"}).val(t),a.select(),document.execCommand("copy"),a.remove(),wpdiscuzAjaxObj.setCommentMessage(t+"<br/>"+wpdiscuzAjaxObj.wc_copied_to_clipboard,"success",5e3)}),e(document).delegate(".wpdiscuz-nofollow,.wc_captcha_refresh_img,.wpd-load-more-submit","click",function(e){e.preventDefault()}),e(document).delegate(".wpd-toggle.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked");var a=V(e(this),0),o=e(this),d=e(".fas",o);!o.parents(".wpd-comment:not(.wpd-reply)").children(".wpd-reply").length&&_?function(t,a){var o=B(t),d=new FormData;d.append("action","wpdShowReplies"),d.append("commentId",o),ce(z,!0,d).done(function(o){a.addClass("wpd_not_clicked"),"object"==typeof o&&o.success&&(e("#wpd-comm-"+t).replaceWith(o.data.comment_list),e("#wpd-comm-"+t+" .wpd-toggle .fas").removeClass("fa-chevron-down").addClass("fa-chevron-up"),e("#wpd-comm-"+t+" .wpd-toggle").attr("wpd-tooltip",wpdiscuzAjaxObj.wc_hide_replies_text),e("#wpd-comm-"+t+" .wpd-toggle .wpd-view-replies").remove(),ie(o)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,o,d){console.log(d),a.addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}(a,t):e("#wpd-comm-"+a+"> .wpd-reply").slideToggle(700,function(){e(this).is(":hidden")?(d.removeClass("fa-chevron-up"),d.addClass("fa-chevron-down"),o.attr("wpd-tooltip",wpdiscuzAjaxObj.wc_show_replies_text)):(d.removeClass("fa-chevron-down"),d.addClass("fa-chevron-up"),o.attr("wpd-tooltip",wpdiscuzAjaxObj.wc_hide_replies_text)),t.addClass("wpd_not_clicked")})}),e(document).delegate(".wpd-new-loaded-comment","mouseenter",function(){e(this).removeClass("wpd-new-loaded-comment")}),e(document).delegate(".wpd-sbs-toggle","click",function(){e(".wpdiscuz-subscribe-bar").slideToggle(v)}),parseInt(wpdiscuzAjaxObj.wpDiscuzIsShowOnSubscribeForm)&&!t&&wpdiscuzAjaxObj.wpDiscuzReCaptchaSK&&("2.0"===d?(setTimeout(function(){try{grecaptcha.render("wpdiscuz-recaptcha-subscribe-form",{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(t){e("#wpdiscuz-recaptcha-field-subscribe-form").val("key")},"expired-callback":function(){e("#wpdiscuz-recaptcha-field-subscribe-form").val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}},1e3),e(document).delegate("#wpdiscuz-subscribe-form","submit",function(t){e("#wpdiscuz-recaptcha-field-subscribe-form").val()?e(".wpdiscuz-recaptcha",e(this)).css("border","none"):(e(".wpdiscuz-recaptcha",e(this)).css("border","1px solid red"),t.preventDefault())})):"3.0"===d&&e(document).delegate("#wpdiscuz_subscription_button","click",function(t){var a=e(this).parents("#wpdiscuz-subscribe-form");t.preventDefault();try{grecaptcha.ready(function(){grecaptcha.execute(wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,{action:"wpdiscuz/wpdAddSubscription"}).then(function(e){console.log(5555),document.getElementById("wpdiscuz-recaptcha-field-subscribe-form").value=e,a.submit()},function(e){wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error","error"),console.log(e)})})}catch(t){console.log(t),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+t.message,"error")}})),(a||o)&&"2.0"===d){var F=e(window).width(),L=e("#wpdcom").width();L>=1100&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"65%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"35%"})),L>=940&&L<1100&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"60%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"40%"})),L>=810&&L<940&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"40%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"60%"})),L>=730&&L<810&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"45%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"55%"})),L>=610&&L<730&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.85)","-webkit-transform":"scale(0.85)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"43%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"55%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"30%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"70%"})),F>650&&(L>=510&&L<610&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"center 0","-webkit-transform-origin":"center 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"35%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"63%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"30%",position:"relative",right:"-60px"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"70%"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"})),L>=470&&L<510&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"center 0","-webkit-transform-origin":"center 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"40%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"60%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd_main_comm_form .wc-form-footer").css({"margin-left":"0px"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"})),L<470&&(e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({margin:"0px auto","transform-origin":"center 0","-webkit-transform-origin":"center 0"}),e("#wpdcom .wpd-form-col-left").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-form-col-right").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"}),e("#wpdcom .wpd-secondary-form-wrapper .wc_notification_checkboxes").css({"text-align":"center"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-field-submit").css({"text-align":"center"})))}function R(t,a,o){ce(z||f,!1,a).done(function(a){if(e(o).addClass("wpd_not_clicked"),"object"==typeof a)if(a.success){"collapsed"===wpdiscuzAjaxObj.commentFormView&&e(".wpd-form-foot",t).slideUp(v),e(".wpd-thread-info").html(a.data.wc_all_comments_count_new_html),a.data.wc_all_comments_count_new=parseInt(a.data.wc_all_comments_count_new),e("#wpd-bubble-all-comments-count").text(a.data.wc_all_comments_count_new),a.data.wc_all_comments_count_new?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide();var d=v;a.data.is_main?X(a.data.message):(d=v+700,e("#wpd-secondary-form-wrapper-"+a.data.uniqueid).slideToggle(700),1==a.data.is_in_same_container?e("#wpd-secondary-form-wrapper-"+a.data.uniqueid).after(a.data.message):e("#wpd-comm-"+a.data.uniqueid).after(a.data.message)),function(e){if(!e.data.held_moderate){var t=new FormData;t.append("action","wpdCheckNotificationType"),t.append("comment_id",e.data.new_comment_id),t.append("email",e.data.comment_author_email),t.append("isParent",e.data.is_main),ce(z,!0,t)}}(a),function(e){if(e.data.redirect>0&&e.data.new_comment_id){var t=new FormData;t.append("action","wpdRedirect"),t.append("commentId",e.data.new_comment_id),ce(z,!0,t).done(function(e){"object"==typeof e&&e.success&&setTimeout(function(){location.href=e.data},2e3)}).fail(function(e,t,a){console.log(a)})}}(a),h&&b?function(t){var a=t.comment_author_email,o=t.comment_author,d=t.comment_author_url;null==u?(Cookies.set("comment_author_email_"+g,a),Cookies.set("comment_author_"+g,o),d.length&&Cookies.set("comment_author_url_"+g,d)):(u=parseInt(u),Cookies.set("comment_author_email_"+g,a,{expires:u,path:"/"}),Cookies.set("comment_author_"+g,o,{expires:u,path:"/"}),d.length&&Cookies.set("comment_author_url_"+g,d,{expires:u,path:"/"}));e(".wpd-cookies-checkbox").length&&e(".wpd-cookies-checkbox").attr("checked","checked")}(a.data):b||e(".wpd-cookies-checkbox").removeAttr("checked"),wpdiscuzLoadRichEditor&&wpDiscuzEditor.createEditor("#wpd-editor-"+e(".wpdiscuz_unique_id",t).val()).setContents([{insert:"\n"}]),t.get(0).reset(),S(a.data),e(".wmu-preview-wrap",t).remove(),I.length&&(I.forEach(function(e){e.parents(".wpd-field-checkbox").remove()}),I=[]),setTimeout(function(){e("html, body").animate({scrollTop:e("#comment-"+a.data.new_comment_id).offset().top-32},1e3)},d),ie(a,t)}else a.data&&(wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"),ie(a,t));else wpdiscuzAjaxObj.setCommentMessage(a,"error");e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,d){console.log(d),e(o).addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}function S(t){e(".wpd_comm_form .wc_name").val(t.comment_author),t.comment_author_email&&t.comment_author_email.indexOf("@example.com")<0&&e(".wpd_comm_form .wc_email").val(t.comment_author_email),t.comment_author_url&&e(".wpd_comm_form .wc_website").val(t.comment_author_url)}function q(t,a){e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd_editable_comment").show(),e("#wpd-comm-"+t+" .wpdiscuz-edit-form-wrap").replaceWith(a),e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").show()}e(document).delegate(".wc_comm_submit.wpd_not_clicked","click",function(){var t=e(this),n=1,s=e(this).parents("form");if(s.hasClass("wpd_main_comm_form")||(n=function(t){var a=t.attr("class").split(" "),o="";return e.each(a,function(e,t){"wpd_comment_level"===G(t,!1)&&(o=G(t,!0))}),parseInt(o)+1}(e(this).parents(".wpd-comment"))),J(s,"#wpd-editor-"+e(".wpdiscuz_unique_id",s).val()),s.submit(function(e){e.preventDefault()}),""!==e(".wc_comment",s).val().trim()&&"<br>"!==e(".wc_comment",s).val().trim()){if(s[0].checkValidity()&&(c=s,p=!0,"2.0"===d&&e("input[name=wc_captcha]",c).length&&!e("input[name=wc_captcha]",c).val().length?(p=!1,e(".wpdiscuz-recaptcha",c).css("border","1px solid red")):"2.0"===d&&e("input[name=wc_captcha]",c).length&&e(".wpdiscuz-recaptcha",c).css("border","none"),p)){E=!0,function(t){e(".wpd-agreement-checkbox",t).each(function(){e(this).hasClass("wpd_agreement_hide")&&h&&e(this).prop("checked")&&(Cookies.set(e(this).attr("name")+"_"+g,1,{expires:30,path:"/"}),e("input[name="+e(this).attr("name")+"]").each(function(){I.push(e(this))}))})}(s),e(t).removeClass("wpd_not_clicked");var i=new FormData;if(i.append("action","wpdAddComment"),e(":input",s).each(function(){""!=this.name&&"checkbox"!=this.type&&"radio"!=this.type&&i.append(this.name+"",e(this).val().trim()),"checkbox"!=this.type&&"radio"!=this.type||e(this).is(":checked")&&i.append(this.name+"",e(this).val())}),i.append("wpd_comment_depth",n),wpdiscuzAjaxObj.wpdiscuz_zs&&i.append("wpdiscuz_zs",wpdiscuzAjaxObj.wpdiscuz_zs),e(".wpd-cookies-checkbox",s).length&&!e(".wpd-cookies-checkbox",s).prop("checked")&&(b=!1),e("#wpdiscuz-loading-bar").show(),wpdiscuzAjaxObj.wpDiscuzReCaptchaSK&&"3.0"===d&&(1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!wpdiscuzAjaxObj.is_user_logged_in||1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&wpdiscuzAjaxObj.is_user_logged_in))try{grecaptcha.ready(function(){grecaptcha.execute(wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,{action:"wpdiscuz/addComment"}).then(function(e){i.append("g-recaptcha-response",e),R(s,i,t)},function(e){wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error","error"),console.log(e)})})}catch(t){console.log(t),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+t.message,"error"),e("#wpdiscuz-loading-bar").fadeOut(250)}else R(s,i,t)}var c,p;!function(e){if((a||o)&&"2.0"===d){var t=B(e);grecaptcha.reset(T[t])}}(e(".wpdiscuz_unique_id",s).val()),e(".wpdiscuz_reset").val("")}else wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj.wc_msg_required_fields,"error")}),e(document).delegate(".wpd_editable_comment","click",function(){w&&e(".wpdiscuz-edit-form-wrap").length&&q(V(e(".wpdiscuz-edit-form-wrap"),0),w);var t=V(e(this),0),a=B(t),o=new FormData;o.append("action","wpdEditComment"),o.append("commentId",a),w=e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-text").get(0),ce(z,!0,o).done(function(a){if("object"==typeof a)if(a.success){if(e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd-comment-text").replaceWith(a.data.html),wpdiscuzLoadRichEditor){let o=wpDiscuzEditor.createEditor("#wpd-editor-edit_"+t);o.clipboard.dangerouslyPasteHTML(0,a.data.content),o.update(),e(".wpd-toolbar-hidden").prev("[id^=wpd-editor-]").css("border-bottom","1px solid #dddddd")}else e("#wc-textarea-edit_"+t).val(a.data.content);e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd_editable_comment").hide(),e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").hide()}else wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error");else console.log(a);e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wc_save_edited_comment","click",function(){var t=V(e(this)),a=B(t),o=e("#wpd-comm-"+t+" #wpdiscuz-edit-form");if(J(o,"#wpd-editor-edit_"+t),o.submit(function(e){e.preventDefault()}),o[0].checkValidity()){var d=new FormData;d.append("action","wpdSaveEditedComment"),d.append("commentId",a),e(":input",o).each(function(){""!==this.name&&"checkbox"!==this.type&&"radio"!==this.type&&d.append(this.name+"",e(this).val()),"checkbox"!==this.type&&"radio"!==this.type||e(this).is(":checked")&&d.append(this.name+"",e(this).val())}),ce(z,!0,d).done(function(o){"object"==typeof o?(o.success?(q(t,o.data.message),o.data.lastEdited&&(e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").remove(),e(o.data.lastEdited).insertAfter("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd-comment-text")),o.data.twitterShareLink&&e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-share .wpd-tooltip-content .wc_tw").attr("href",o.data.twitterShareLink),o.data.whatsappShareLink&&e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-share .wpd-tooltip-content .wc_whatsapp").attr("href",o.data.whatsappShareLink),wpdiscuzLoadRichEditor&&wpDiscuzEditor.removeEditor("#wpd-editor-edit_"+t)):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[o.data],"error"),ie(o,a)):console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(document).delegate(".wc_cancel_edit","click",function(){var t=V(e(this));q(t,w),wpdiscuzLoadRichEditor&&wpDiscuzEditor.removeEditor("#wpd-editor-edit_"+t)}),!wpdiscuzAjaxObj.wordpressIsPaginate&&m&&(M=0,1==m?setTimeout(function(){W(!0)},500):e(document).delegate(".wpd-load-comments","click",function(){e(this).remove(),W(!0)})),e(document).delegate(".wpd-load-more-submit","click",function(){var t=e(this);t.hasClass("wpd-loaded")&&W(!1,t,"wpd-loaded","wpd-loading")});var U=!1;function H(){var t=e("#wpdiscuzHasMoreComments").val(),a=e(document).height(),o=e(window).height()+e(window).scrollTop();a&&o&&(100*o/a>=80&&!1===U&&1==t&&(U=!0,W(!1,e(".wpd-load-more-submit"))))}function W(t,a,o,d){a&&(a.toggleClass(o),a.toggleClass(d));var s=new FormData;s.append("action","wpdLoadMoreComments");var i=e(".wpdiscuz-sort-button-active").attr("data-sorting");i&&s.append("sorting",i),s.append("offset",M),s.append("lastParentId",e(".wpd-load-more-submit").attr("data-lastparentid")),s.append("isFirstLoad",t?1:0);var c=e(".wpdf-active").attr("data-filter-type");s.append("wpdType",c||""),ce(z,!0,s).done(function(s){"object"==typeof s&&s.success&&(M++,e(".wpdiscuz-comment-pagination").before(s.data.comment_list),K(s,t&&2!==n),e(".wpdiscuz_single").remove(),U=!1,r=s.data.loadLastCommentId,ie(s),t&&P(!1)),e("#wpdiscuz-loading-bar").fadeOut(250),e(".wpd-load-more-submit").blur(),a&&(a.toggleClass(o),a.toggleClass(d))}).fail(function(t,n,s){console.log(s),e("#wpdiscuz-loading-bar").fadeOut(250),e(".wpd-load-more-submit").blur(),a&&(a.toggleClass(o),a.toggleClass(d))})}function K(t,a){var o;0==t.data.is_show_load_more?(e("#wpdiscuzHasMoreComments").val(0),e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").hide()):(o=t.data.last_parent_id,e(".wpd-load-more-submit").attr("data-lastparentid",o),2!==n&&e(".wpdiscuz-comment-pagination").show(),e("#wpdiscuzHasMoreComments").val(1),a&&e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").show()),ie(t)}function P(t){var a=location.href.match(/#comment\-(\d+)/);if(null!==a){var o=a[1];if(e("#comment-"+o).length)setTimeout(function(){e("html, body").animate({scrollTop:e("#comment-"+o).parents("[id^=wpd-comm-]").offset().top-32},1e3),t&&N(o)},500);else{var d=new FormData;d.append("action","wpdGetSingleComment"),d.append("commentId",o),ce(z,!0,d).done(function(a){if("object"==typeof a&&a.success){var d="#comment-"+o;e("#comment-"+a.data.parentCommentID).length?e("#comment-"+a.data.parentCommentID).parents("[id^=wpd-comm-"+a.data.parentCommentID+"]").replaceWith(a.data.message):e(".wpd-thread-list").prepend(a.data.message),ie(a),e("html, body").animate({scrollTop:e(d).offset().top-32},1e3),t&&N(o)}e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}}function N(t){setTimeout(function(){e("#comment-"+t).siblings(".wpd-secondary-form-wrapper").is(":visible")||e("#comment-"+t).find(".wpd-reply-button").trigger("click")},1100)}function Q(e){if(void 0!==e.data.message)for(var t,a=e.data.message,o=0;o<a.length;o++)$((t=a[o]).comment_parent,t.comment_html)}function V(e,t){var a="";return(a=t?e.parents(".wpd-main-form-wrapper").attr("id"):e.parents(".wpd-comment").attr("id")).substring(a.lastIndexOf("-")+1)}function B(e){return e.substring(0,e.indexOf("_"))}function G(e,t){return t?e.substring(e.indexOf("-")+1):e.substring(0,e.indexOf("-"))}function $(t,a){if(0==t)X(a);else{var o=V(e("#comment-"+t),0);e("#wpdiscuz_form_anchor-"+o).after(a)}}function Y(){var t,a,o="";return e(".wpd-comment-right").each(function(){t=V(e(this),0),a=B(t),o+=a+","}),o}function J(t,a){var o=t.find(".wpd-required-group");wpdiscuzLoadRichEditor&&t.find(".wc_comment").val(e(a+">.ql-editor").html()),function(e){var t=e.find(".wc_comment"),a=t.val().trim().replace(/<p><br><\/p>/g,"&nbsp;\n").replace(/<p>(.*?)<\/p>/g,"$1\n");a=(a=(a=(a=a.replace(/<img src=["|']https\:\/\/s\.w\.org\/images\/core\/emoji\/([^"|']+)["|'](.*?)alt=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$3")).replace(/<img[^>]+alt=["|']([^"|']+)["|'][^>]+src=["|']https\:\/\/s\.w\.org\/images\/core\/emoji\/([^"|']+)["|'][^>]?>/g,"$1")).replace(/<img\s+([^>]*)class=["|']wpdem\-sticker["|'](.*?)alt=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$3")).replace(/<img\s+([^>]*)src=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$2"),t.val(a)}(t),e.each(o,function(){e("input",this).removeAttr("required"),0===e("input:checked",this).length?e("input",e(this)).attr("required","required"):e(".wpd-field-invalid",this).remove()})}function X(t){e(".wpd-sticky-comment").last()[0]?e(t).insertAfter(e(".wpd-sticky-comment").last()[0]):e(".wpd-thread-list").prepend(t)}function Z(t){t?t.prop("required")||(t.val()?t.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","inline-block"):t.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","none")):e.each(e(".wc_email"),function(t,a){var o=e(a);o.prop("required")||(o.val()?o.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","inline-block"):o.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","none"))})}if(2!==n||wpdiscuzAjaxObj.wordpressIsPaginate||(e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").hide(),H(),e(window).scroll(function(){H()})),wpdiscuzAjaxObj.setLoadMoreVisibility=K,e(document).delegate(".wpd-vote-up.wpd_not_clicked, .wpd-vote-down.wpd_not_clicked","click",function(){var t=e(this);e(t).removeClass("wpd_not_clicked");var a,o=B(V(t));a=e(this).hasClass("wpd-vote-up")?1:-1;var d=new FormData;d.append("action","wpdVoteOnComment"),d.append("commentId",o),d.append("voteType",a),ce(z,!0,d).done(function(d){if(e(t).addClass("wpd_not_clicked"),"object"==typeof d){if(d.success){if("total"===d.data.buttonsStyle){var n=e(".wpd-comment-footer .wpd-vote-result",e("#comment-"+o)),s=d.data.votes;n.text(s),n.removeClass("wpd-up wpd-down"),s>0&&n.addClass("wpd-up"),s<0&&n.addClass("wpd-down")}else{var i=e(".wpd-comment-footer .wpd-vote-result-like",e("#comment-"+o)),c=e(".wpd-comment-footer .wpd-vote-result-dislike",e("#comment-"+o));i.text(d.data.likeCount),c.text(d.data.dislikeCount),parseInt(d.data.likeCount)>0?i.addClass("wpd-up"):i.removeClass("wpd-up"),parseInt(d.data.dislikeCount)<0?c.addClass("wpd-down"):c.removeClass("wpd-down")}var p=e(".wpd-comment-footer .wpd-vote-up",e("#comment-"+o)),r=e(".wpd-comment-footer .wpd-vote-down",e("#comment-"+o));p.removeClass("wpd-up"),r.removeClass("wpd-down"),d.data.curUserReaction>0?p.addClass("wpd-up"):d.data.curUserReaction<0&&r.addClass("wpd-down")}else d.data&&wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[d.data],"error");ie(d,o,a)}else console.log(d);e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(a,o,d){console.log(d),e(t).addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate("body","click",function(t){var a=e(".wpdiscuz-sort-buttons");e(t.target).hasClass("wpdf-sorting")||e(t.target).parent().hasClass("wpdf-sorting")?a.css({display:a.is(":visible")?"none":"flex"}):a.hide()}),e(document).delegate(".wpdiscuz-sort-button:not(.wpdiscuz-sort-button-active)","click",function(){var t=e(this),a=e(this).attr("data-sorting");if(a){e(".wpdiscuz-sort-button.wpdiscuz-sort-button-active").removeClass("wpdiscuz-sort-button-active").appendTo(".wpdiscuz-sort-buttons"),t.addClass("wpdiscuz-sort-button-active").prependTo(".wpdf-sorting");var o=new FormData;o.append("action","wpdSorting"),o.append("sorting",a);var d=e(".wpdf-active").attr("data-filter-type");o.append("wpdType",d||""),ce(z,!0,o).done(function(t){"object"==typeof t&&t.success&&(e("#wpdcom .wpd-comment").remove(),e("#wpdcom .wpd-thread-list").prepend(t.data.message),K(t,!1),M=1),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),window.onhashchange=function(){P(!1)},1!=m&&P(!1),e(document).delegate(".wpdiscuz-readmore","click",function(){var t=V(e(this)),a=B(t),o=new FormData;o.append("action","wpdReadMore"),o.append("commentId",a),ce(z,!0,o).done(function(o){"object"==typeof o?(o.success?(e("#comment-"+a+" .wpd-comment-text").html(" "+o.data.message),e("#wpdiscuz-readmore-"+t).remove()):console.log(o.data),ie(o)):console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-required-group","change",function(){0!==e("input:checked",this).length?e("input",e(this)).removeAttr("required"):e("input",e(this)).attr("required","required")}),e(document).delegate(".wpdiscuz-spoiler","click",function(){e(this).next().slideToggle(),e(this).hasClass("wpdiscuz-spoiler-closed")?e(this).parents(".wpdiscuz-spoiler-wrap").find(".fa-plus").removeClass("fa-plus").addClass("fa-minus"):e(this).parents(".wpdiscuz-spoiler-wrap").find(".fa-minus").removeClass("fa-minus").addClass("fa-plus"),e(this).toggleClass("wpdiscuz-spoiler-closed")}),e(document).delegate(".wpd-tools i","click",function(){var t=e(this).siblings(".wpd-tools-actions");t.css({display:t.is(":visible")?"none":"flex"})}),e(document).delegate(".wpd-comment-right","mouseleave",function(){e(this).find(".wpd-tools-actions").hide()}),e(document).delegate(".wpd_stick_btn","click",function(){var t=B(V(e(this),0)),a=new FormData;a.append("action","wpdStickComment"),a.append("commentId",t),ce(z,!0,a).done(function(t){"object"==typeof t&&t.success&&location.reload(!0),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd_close_btn","click",function(){var t=B(V(e(this),0)),a=new FormData;a.append("action","wpdCloseThread"),a.append("commentId",t),ce(z,!0,a).done(function(t){"object"==typeof t&&t.success&&location.reload(!0),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-filter.wpd_not_clicked[data-filter-type]","click",function(){var t=e(this),a=t.attr("data-filter-type");wpdiscuzAjaxObj.resetActiveFilters(".wpdf-"+a),t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var o=new FormData;o.append("action","wpdLoadMoreComments");var d=e(".wpdiscuz-sort-button-active").attr("data-sorting");d&&o.append("sorting",d),o.append("lastParentId",0),o.append("offset",0),M=1,o.append("wpdType",t.hasClass("wpdf-active")?"":a),o.append("isFirstLoad",1),e(this).hasClass("wpdf-inline")?e(this).hasClass("wpdf-active")?e(".wpd-comment-info-bar").hide():e(".wpd-comment-info-bar").css("display","flex"):e(".wpd-comment-info-bar").hide(),ce(z,!1,o).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(t.toggleClass("wpdf-active"),e(".wpd-load-comments").remove(),e(".wpd-comment").remove(),e(".wpd-thread-list").prepend(a.data.comment_list),K(a),r=a.data.loadLastCommentId,e(".wpd-load-more-submit").blur(),ie(a)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpdf-reacted.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=new FormData;a.append("action","wpdMostReactedComment"),ce(z,!1,a).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(e("#comment-"+a.data.parentCommentID).length?e("#comment-"+a.data.parentCommentID).parents("[id^=wpd-comm-"+a.data.parentCommentID+"]").replaceWith(a.data.message):e("#comment-"+a.data.commentId).length||e(".wpd-thread-list").prepend(a.data.message),ie(a),e("html, body").animate({scrollTop:e("#comment-"+a.data.commentId).offset().top-32},1e3))}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner")})}),e(document).delegate(".wpdf-hottest.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=new FormData;a.append("action","wpdHottestThread"),ce(z,!1,a).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(e("#comment-"+a.data.commentId).length?e("#comment-"+a.data.commentId).parents("[id^=wpd-comm-"+a.data.commentId+"]").replaceWith(a.data.message):e(".wpd-thread-list").prepend(a.data.message),ie(a),e("html, body").animate({scrollTop:e("#comment-"+a.data.commentId).offset().top-32},1e3))}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner")})}),e(document).delegate(".wpd-filter-view-all","click",function(){e(".wpdf-inline.wpdf-active.wpd_not_clicked").trigger("click")}),e(document).delegate(".wpd-follow-link.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=B(V(t,0)),o=new FormData;o.append("action","wpdFollowUser"),o.append("commentId",a),ce(z,!0,o).done(function(a){t.addClass("wpd_not_clicked"),"object"==typeof a?a.success?(wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data.code],"success"),t.removeClass("wpd-follow-active"),a.data.followTip&&t.attr("wpd-tooltip",a.data.followTip),a.data.followClass&&t.addClass(a.data.followClass)):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"):console.log(a),e(".fas",t).removeClass("fa-pulse fa-spinner"),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner"),e("#wpdiscuz-loading-bar").fadeOut(250)})}),Z(),e(document).delegate(".wc_email","keyup",function(){Z(e(this))}),j){if(e("#wpd-bubble-wrapper").hover(function(){e(this).addClass("wpd-bubble-hover")},function(){e(this).removeClass("wpd-bubble-hover")}),k&&!Cookies.get(wpdiscuzAjaxObj.cookieHideBubbleHint)&&setTimeout(function(){e("#wpd-bubble-wrapper").addClass("wpd-bubble-hover"),Cookies.set(wpdiscuzAjaxObj.cookieHideBubbleHint,"1",{expires:7,path:"/"}),setTimeout(function(){e("#wpd-bubble-wrapper").removeClass("wpd-bubble-hover")},1e3*x)},1e3*k),"content_left"===O)if(e(".entry-content").length){var ee=(te=Math.min(e(".entry-content").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else if(e(".post-entry").length){ee=(te=Math.min(e(".post-entry").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else if(e(".container").length){var te;ee=(te=Math.min(e(".container").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else e("#wpd-bubble-wrapper").css({left:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-corner");else"left_corner"===O?(e("#wpd-bubble-wrapper").css({left:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-corner")):"right_corner"===O&&(e("#wpd-bubble-wrapper").css({right:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-right-corner"));e("#wpd-bubble-wrapper").show(),e("#wpd-bubble-add-message-close").click(function(t){t.preventDefault(),t.stopPropagation(),e("#wpd-bubble-wrapper").removeClass("wpd-bubble-hover")}),e("#wpd-bubble").click(function(){e("html, body").animate({scrollTop:e("#wpdcom").offset().top-60},1e3,function(){wpdiscuzLoadRichEditor?wpDiscuzEditor.createEditor("#wpd-editor-0_0").focus():e("#wc-textarea-0_0").focus()})}),e("#wpd-bubble-comment-close").click(function(t){t.preventDefault(),e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added")}),e("#wpd-bubble-comment-reply-link a").click(function(){var t=e(this).attr("href");setTimeout(function(){e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added"),P(!0);var a=t.match(/#comment\-(\d+)/);D=D.filter(function(e){return e!=a[1]}),e("#wpd-bubble-count .wpd-new-comments-count").text(D.length),0==D.length&&e("#wpd-bubble-count").removeClass("wpd-new-comments")},100)}),e("#wpd-bubble-count").click(function(){if(D.length){var t=new FormData;t.append("action","wpdBubbleUpdate"),t.append("newCommentIds",D.join()),ce(z,!0,t).done(function(t){"object"==typeof t&&t.success&&(t.data.message=t.data.message.filter(function(t){if(!e("#comment-"+t.comment_id).length)return t}),Q(t),e("#wpd-bubble-count").removeClass("wpd-new-comments"),e("#wpd-bubble-count .wpd-new-comments-count").text("0"),D=[],e("html, body").animate({scrollTop:e(e(".wpd-new-loaded-comment")[0]).offset().top-60},1e3),ie(t)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(e,t,a){console.log(a)})}})}if((j&&C||i)&&(t||!t&&p)&&setTimeout(function t(){e.ajax({type:"GET",url:wpdiscuzAjaxObj.bubbleUpdateUrl,data:{postId:s,lastId:l,visibleCommentIds:Y()}}).done(function(a){if(!E)if("object"==typeof a){if(a.ids.length){i&&((n=new FormData).append("action","wpdUpdateAutomatically"),n.append("loadLastCommentId",r),n.append("visibleCommentIds",Y()),ce(z,!1,n).done(function(t){E||"object"==typeof t&&t.success&&(Q(t),e(".wpd-thread-info").html(t.data.wc_all_comments_count_new_html),t.data.wc_all_comments_count_new=parseInt(t.data.wc_all_comments_count_new),e("#wpd-bubble-all-comments-count").text(t.data.wc_all_comments_count_new),t.data.wc_all_comments_count_new?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),r=t.data.loadLastCommentId)}).fail(function(e,t,a){console.log(a)})),a.ids=a.ids.filter(function(t){if(!e("#comment-"+t).length)return t});var o=5e3;l=parseInt(a.ids[a.ids.length-1]),D=D.concat(a.ids),y&&a.commentText&&(e("#wpd-bubble-author-avatar").html(a.avatar),e("#wpd-bubble-author-name").html(a.authorName),e("#wpd-bubble-comment-date span").html(a.commentDate),e("#wpd-bubble-comment-text").html(a.commentText),e("#wpd-bubble-comment-reply-link a").attr("href",a.commentLink),e("#wpd-bubble-notification-message").show(),o=1e4);var d=parseInt(e(".wpd-new-comments-count").text());d+=a.ids.length,e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added"),e("#wpd-bubble-wrapper").addClass("wpd-new-comment-added"),setTimeout(function(){e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added")},o),e(".wpd-new-comments-count").text(d),e("#wpd-bubble-count").addClass("wpd-new-comments"),a.all_comments_count=parseInt(a.all_comments_count),e("#wpd-bubble-all-comments-count").text(a.all_comments_count),a.all_comments_count?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),e(".wpd-thread-info").html(a.all_comments_count_html)}}else console.log(a);var n;setTimeout(t,c)}).fail(function(e,a,o){console.log(o),setTimeout(t,c)})},c),e(".wpd-inline-form-wrapper").length){var ae=new FormData;ae.append("action","wpdGetInlineCommentForm"),ce(z,!1,ae).done(function(t){"object"==typeof t?t.success?(e(".wpd-inline-form-wrapper").append(t.data),e.each(e("[name=_wpd_inline_nonce]"),function(){var t=e(this).attr("id"),a=e(this).parents(".wpd-inline-shortcode").attr("id");e(this).attr("id",t+"-"+a.substring(a.lastIndexOf("-")+1))}),e(".wpd-inline-opened").addClass("wpd-active"),e(".wpd-inline-opened").find(".wpd-inline-form-wrapper").show(),e(".wpd-inline-opened").find(".wpd-inline-icon").addClass("wpd-open"),e(".wpd-inline-opened").find(".wpd-inline-icon").removeClass("wpd-ignored"),se()):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error"):console.log(t)}).fail(function(e,t,a){console.log(a)})}function oe(t){if(e(t).hasClass("wpd-inline-shortcode"))var a=e(t).attr("id");else a=e(t).parents(".wpd-inline-shortcode").attr("id");return a.substring(a.lastIndexOf("-")+1)}function de(){e(".wpd-inline-form-wrapper").hide(),e(".wpd-inline-shortcode").removeClass("wpd-active"),e(".wpd-inline-icon").removeClass("wpd-open")}function ne(){e.each(e(".wpd-inline-shortcode:not(.wpd-inline-opened) .wpd-inline-icon"),function(){var t=e(this),a=t.offset().top-window.pageYOffset;a>0&&a<300&&("blink"===A?(t.addClass("wpd-blink"),setTimeout(function(){t.removeClass("wpd-blink")},3e3)):(t.parents(".wpd-inline-shortcode").addClass("wpd-active"),t.siblings(".wpd-inline-form-wrapper").show(),t.addClass("wpd-open"),se(t.siblings(".wpd-inline-form-wrapper"))))})}function se(t){if(t){if(t.offset().left<=10)t.css("left",Math.ceil(parseInt(t.css("left"))-t.offset().left+10)),(a=Math.ceil(t.siblings(".wpd-inline-icon.wpd-open").offset().left-t.offset().left+2))<3&&(a=3),document.styleSheets[0].addRule("#"+t.parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+a+"px;");else if(t.offset().left+t.width()>document.body.clientWidth-10){var a;t.css("left",Math.ceil(parseInt(t.css("left"))+(document.body.clientWidth-(t.offset().left+t.width()))-10)),(a=Math.ceil(t.siblings(".wpd-inline-icon.wpd-open").offset().left-t.offset().left+2))>t.width()-3&&(a=t.width()-3),document.styleSheets[0].addRule("#"+t.parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+a+"px;")}}else e.each(e(".wpd-inline-form-wrapper:visible"),function(){if(e(this).offset().left<=10)e(this).css("left",Math.ceil(parseInt(e(this).css("left"))-e(this).offset().left+10)),(t=Math.ceil(e(this).siblings(".wpd-inline-icon.wpd-open").offset().left-e(this).offset().left+2))<3&&(t=3),document.styleSheets[0].addRule("#"+e(this).parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+t+"px;");else if(e(this).offset().left+e(this).width()>document.body.clientWidth-10){var t;e(this).css("left",Math.ceil(parseInt(e(this).css("left"))+(document.body.clientWidth-(e(this).offset().left+e(this).width()))-10)),(t=Math.ceil(e(this).siblings(".wpd-inline-icon.wpd-open").offset().left-e(this).offset().left+2))>e(this).width()-3&&(t=e(this).width()-3),document.styleSheets[0].addRule("#"+e(this).parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+t+"px;")}})}function ie(t,a,o,d){t.data.callbackFunctions&&e.each(t.data.callbackFunctions,function(e){"function"==typeof wpdiscuzAjaxObj[t.data.callbackFunctions[e]]?wpdiscuzAjaxObj[t.data.callbackFunctions[e]](t,a,o,d):console.log(t.data.callbackFunctions[e]+" is not a function")})}function ce(t,a,o){a&&e("#wpdiscuz-loading-bar").show(),o.append("postId",s);var d=o.get("action");wpdiscuzAjaxObj.dataFilterCallbacks&&wpdiscuzAjaxObj.dataFilterCallbacks[d]&&e.each(wpdiscuzAjaxObj.dataFilterCallbacks[d],function(e){"function"==typeof wpdiscuzAjaxObj[wpdiscuzAjaxObj.dataFilterCallbacks[d][e]]&&(o=wpdiscuzAjaxObj[wpdiscuzAjaxObj.dataFilterCallbacks[d][e]](o,t,a))});var n=t?wpdiscuzAjaxObj.url:wpdiscuzAjaxObj.customAjaxUrl;return e.ajax({type:"POST",url:n,data:o,contentType:!1,processData:!1})}e(document).delegate("body","click",function(t){if(e(t.target).hasClass("wpd-inline-form-close")||e(t.target).parents(".wpd-inline-form-close").length)t.preventDefault(),e(t.target).parents(".wpd-inline-form-wrapper").hide(),e(t.target).parents(".wpd-inline-shortcode").removeClass("wpd-active"),e(t.target).parents(".wpd-inline-form-wrapper").siblings(".wpd-inline-icon").removeClass("wpd-open");else if(!e(t.target).hasClass("wpd-inline-form-wrapper")&&!e(t.target).parents(".wpd-inline-form-wrapper").length){de();var a="";e(t.target).hasClass("wpd-inline-icon")?a=e(t.target):e(t.target).parents(".wpd-inline-icon").length&&(a=e(t.target).parents(".wpd-inline-icon")),a.length&&(a.parents(".wpd-inline-shortcode").addClass("wpd-active"),a.siblings(".wpd-inline-form-wrapper").show(),a.addClass("wpd-open"),a.removeClass("wpd-ignored"),se(a.siblings(".wpd-inline-form-wrapper")))}(!e(t.target).hasClass("wpd-last-inline-comments-wrapper")&&!e(t.target).parents(".wpd-last-inline-comments-wrapper").length||e(t.target).parents(".wpd-last-inline-comments-wrapper").length&&e(t.target).hasClass("wpd-load-inline-comment"))&&e(".wpd-last-inline-comments-wrapper").remove()}),e(document).delegate(".wpd-inline-submit.wpd_not_clicked","click",function(t){t.preventDefault();var a=e(this),o=e(this).parents(".wpd_inline_comm_form");if(o[0].checkValidity()){e(this).removeClass("wpd_not_clicked");var d=new FormData;d.append("action","wpdAddInlineComment"),d.append("inline_form_id",oe(o)),e.each(e("input, textarea",o),function(t,a){"checkbox"===this.type?e(this).is(":checked")&&d.append(e(a).attr("name"),e(a).val()):d.append(e(a).attr("name"),e(a).val())}),ce(z,!0,d).done(function(t){if(a.addClass("wpd_not_clicked"),"object"==typeof t)if(t.success){o[0].reset(),de();var d=parseInt(t.data.newCount),n=a.parents(".wpd-inline-icon-wrapper").find(".wpd-inline-icon-count");n.text(d),d?n.addClass("wpd-has-comments"):n.removeClass("wpd-has-comments"),e(".wpd-thread-info").html(t.data.allCommentsCountNewHtml),t.data.allCommentsCountNew=parseInt(t.data.allCommentsCountNew),e("#wpd-bubble-all-comments-count").text(t.data.allCommentsCountNew),t.data.allCommentsCountNew?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),t.data.message&&X(t.data.message),wpdiscuzAjaxObj.setCommentMessage(t.data.notification,"success")}else t.data&&wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error");else wpdiscuzAjaxObj.setCommentMessage(t,"error");e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(document).delegate(".wpd-form","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).find(".wc_comm_submit").trigger("click")}),e(document).delegate("#wpdiscuz-edit-form","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).find(".wc_save_edited_comment").trigger("click")}),e(document).delegate(".wpd-inline-comment-content","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).parents(".wpd_inline_comm_form").find(".wpd-inline-submit.wpd_not_clicked").trigger("click")}),e(document).delegate(".wpd-inline-icon-count.wpd-has-comments","click",function(){var t=e(this),a=new FormData;a.append("action","wpdGetLastInlineComments"),a.append("inline_form_id",oe(t)),ce(z,!0,a).done(function(a){"object"==typeof a?a.success?e(a.data).insertAfter(t):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"):console.log(a),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-view-all-inline-comments","click",function(t){t.preventDefault(),e(this).parents(".wpd-last-inline-comments-wrapper").remove(),e(".wpdf-inline").hasClass("wpdf-active")||e(".wpdf-inline").trigger("click"),e("html, body").animate({scrollTop:e(".wpdf-inline").offset().top-32},1e3)}),e(document).delegate(".wpd-feedback-content-link","click",function(t){t.preventDefault();var a=e(this).data("feedback-content-id");e("html, body").animate({scrollTop:e("#wpd-inline-"+a).offset().top-38},1e3,function(){e("#wpd-inline-"+a).addClass("wpd-active")})}),"scroll_open"!==A&&"blink"!==A||(ne(),e(window).scroll(ne)),e(document).delegate("#wpd-post-rating.wpd-not-rated .wpd-rate-starts svg","click",function(){var t=new FormData,a=e(this).index();a>=0&&a<5&&(t.append("action","wpdUserRate"),t.append("rating",a+1),ce(z,!0,t).done(function(t){"object"==typeof t?t.success?location.reload(!0):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error"):console.log(t),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}))}),e("#wpdiscuz-subscribe-form").submit(function(t){t.preventDefault();var a,o,n=e(this);if(n[0].checkValidity()&&(a=n,o=!0,"2.0"===d&&e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).length&&!e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).val().length?(o=!1,e(".wpdiscuz-recaptcha",a).css("border","1px solid red")):"2.0"===d&&e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).length&&e(".wpdiscuz-recaptcha",a).css("border","none"),o)){var s=new FormData;s.append("action","wpdAddSubscription"),e("*",n).each(function(){""!=this.name&&"checkbox"!=this.type&&"radio"!=this.type&&s.append(this.name+"",e(this).val()),"checkbox"!=this.type&&"radio"!=this.type||e(this).is(":checked")&&s.append(this.name+"",e(this).val())}),ce(z,!0,s).done(function(t){"object"==typeof t?t.success?(wpdiscuzAjaxObj.setCommentMessage(t.data,"success"),setTimeout(function(){location.reload(!0)},3e3)):wpdiscuzAjaxObj.setCommentMessage(t.data,"error"):wpdiscuzAjaxObj.setCommentMessage(t,"error"),e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(".wpd-unsubscribe").click(function(t){t.preventDefault();var a=new FormData;a.append("action","wpdUnsubscribe"),a.append("sid",e(this).data("sid")),a.append("skey",e(this).data("skey")),ce(z,!0,a).done(function(t){"object"==typeof t?t.success?(wpdiscuzAjaxObj.setCommentMessage(t.data,"success"),setTimeout(function(){location.reload(!0)},3e3)):wpdiscuzAjaxObj.setCommentMessage(t.data,"error"):console.log(t),e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),wpdiscuzAjaxObj.resetActiveFilters=function(t){e(".wpd-filter.wpdf-active"+(t?":not("+t+")":"")).removeClass("wpdf-active")},wpdiscuzAjaxObj.getAjaxObj=ce});var onloadCallback=function(){if(document.getElementById("wpdiscuz-recaptcha-0_0")&&"2.0"===wpdiscuzAjaxObj.wpDiscuzReCaptchaVersion&&(1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!wpdiscuzAjaxObj.is_user_logged_in||1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&wpdiscuzAjaxObj.is_user_logged_in))try{grecaptcha.render("wpdiscuz-recaptcha-0_0",{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(e){jQuery("#wpdiscuz-recaptcha-field-0_0").val("key")},"expired-callback":function(){jQuery("#wpdiscuz-recaptcha-field-0_0").val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}};
7
  /* Colorbox */
8
  (function(t,e,i){function n(i,n,o){var r=e.createElement(i);return n&&(r.id=Z+n),o&&(r.style.cssText=o),t(r)}function o(){return i.innerHeight?i.innerHeight:t(i).height()}function r(e,i){i!==Object(i)&&(i={}),this.cache={},this.el=e,this.value=function(e){var n;return void 0===this.cache[e]&&(n=t(this.el).attr("data-cbox-"+e),void 0!==n?this.cache[e]=n:void 0!==i[e]?this.cache[e]=i[e]:void 0!==X[e]&&(this.cache[e]=X[e])),this.cache[e]},this.get=function(e){var i=this.value(e);return t.isFunction(i)?i.call(this.el,this):i}}function h(t){var e=W.length,i=(A+t)%e;return 0>i?e+i:i}function a(t,e){return Math.round((/%/.test(t)?("x"===e?E.width():o())/100:1)*parseInt(t,10))}function s(t,e){return t.get("photo")||t.get("photoRegex").test(e)}function l(t,e){return t.get("retinaUrl")&&i.devicePixelRatio>1?e.replace(t.get("photoRegex"),t.get("retinaSuffix")):e}function d(t){"contains"in x[0]&&!x[0].contains(t.target)&&t.target!==v[0]&&(t.stopPropagation(),x.focus())}function c(t){c.str!==t&&(x.add(v).removeClass(c.str).addClass(t),c.str=t)}function g(e){A=0,e&&e!==!1&&"nofollow"!==e?(W=t("."+te).filter(function(){var i=t.data(this,Y),n=new r(this,i);return n.get("rel")===e}),A=W.index(_.el),-1===A&&(W=W.add(_.el),A=W.length-1)):W=t(_.el)}function u(i){t(e).trigger(i),ae.triggerHandler(i)}function f(i){var o;if(!G){if(o=t(i).data(Y),_=new r(i,o),g(_.get("rel")),!U){U=$=!0,c(_.get("className")),x.css({visibility:"hidden",display:"block",opacity:""}),I=n(se,"LoadedContent","width:0; height:0; overflow:hidden; visibility:hidden"),b.css({width:"",height:""}).append(I),j=T.height()+k.height()+b.outerHeight(!0)-b.height(),D=C.width()+H.width()+b.outerWidth(!0)-b.width(),N=I.outerHeight(!0),z=I.outerWidth(!0);var h=a(_.get("initialWidth"),"x"),s=a(_.get("initialHeight"),"y"),l=_.get("maxWidth"),f=_.get("maxHeight");_.w=Math.max((l!==!1?Math.min(h,a(l,"x")):h)-z-D,0),_.h=Math.max((f!==!1?Math.min(s,a(f,"y")):s)-N-j,0),I.css({width:"",height:_.h}),J.position(),u(ee),_.get("onOpen"),O.add(F).hide(),x.focus(),_.get("trapFocus")&&e.addEventListener&&(e.addEventListener("focus",d,!0),ae.one(re,function(){e.removeEventListener("focus",d,!0)})),_.get("returnFocus")&&ae.one(re,function(){t(_.el).focus()})}var p=parseFloat(_.get("opacity"));v.css({opacity:p===p?p:"",cursor:_.get("overlayClose")?"pointer":"",visibility:"visible"}).show(),_.get("closeButton")?B.html(_.get("close")).appendTo(b):B.appendTo("<div/>"),w()}}function p(){x||(V=!1,E=t(i),x=n(se).attr({id:Y,"class":t.support.opacity===!1?Z+"IE":"",role:"dialog",tabindex:"-1"}).hide(),v=n(se,"Overlay").hide(),L=t([n(se,"LoadingOverlay")[0],n(se,"LoadingGraphic")[0]]),y=n(se,"Wrapper"),b=n(se,"Content").append(F=n(se,"Title"),R=n(se,"Current"),P=t('<button type="button"/>').attr({id:Z+"Previous"}),K=t('<button type="button"/>').attr({id:Z+"Next"}),S=t('<button type="button"/>').attr({id:Z+"Slideshow"}),L),B=t('<button type="button"/>').attr({id:Z+"Close"}),y.append(n(se).append(n(se,"TopLeft"),T=n(se,"TopCenter"),n(se,"TopRight")),n(se,!1,"clear:left").append(C=n(se,"MiddleLeft"),b,H=n(se,"MiddleRight")),n(se,!1,"clear:left").append(n(se,"BottomLeft"),k=n(se,"BottomCenter"),n(se,"BottomRight"))).find("div div").css({"float":"left"}),M=n(se,!1,"position:absolute; width:9999px; visibility:hidden; display:none; max-width:none;"),O=K.add(P).add(R).add(S)),e.body&&!x.parent().length&&t(e.body).append(v,x.append(y,M))}function m(){function i(t){t.which>1||t.shiftKey||t.altKey||t.metaKey||t.ctrlKey||(t.preventDefault(),f(this))}return x?(V||(V=!0,K.click(function(){J.next()}),P.click(function(){J.prev()}),B.click(function(){J.close()}),v.click(function(){_.get("overlayClose")&&J.close()}),t(e).bind("keydown."+Z,function(t){var e=t.keyCode;U&&_.get("escKey")&&27===e&&(t.preventDefault(),J.close()),U&&_.get("arrowKey")&&W[1]&&!t.altKey&&(37===e?(t.preventDefault(),P.click()):39===e&&(t.preventDefault(),K.click()))}),t.isFunction(t.fn.on)?t(e).on("click."+Z,"."+te,i):t("."+te).live("click."+Z,i)),!0):!1}function w(){var e,o,r,h=J.prep,d=++le;if($=!0,q=!1,u(he),u(ie),_.get("onLoad"),_.h=_.get("height")?a(_.get("height"),"y")-N-j:_.get("innerHeight")&&a(_.get("innerHeight"),"y"),_.w=_.get("width")?a(_.get("width"),"x")-z-D:_.get("innerWidth")&&a(_.get("innerWidth"),"x"),_.mw=_.w,_.mh=_.h,_.get("maxWidth")&&(_.mw=a(_.get("maxWidth"),"x")-z-D,_.mw=_.w&&_.w<_.mw?_.w:_.mw),_.get("maxHeight")&&(_.mh=a(_.get("maxHeight"),"y")-N-j,_.mh=_.h&&_.h<_.mh?_.h:_.mh),e=_.get("href"),Q=setTimeout(function(){L.show()},100),_.get("inline")){var c=t(e).eq(0);r=t("<div>").hide().insertBefore(c),ae.one(he,function(){r.replaceWith(c)}),h(c)}else _.get("iframe")?h(" "):_.get("html")?h(_.get("html")):s(_,e)?(e=l(_,e),q=_.get("createImg"),t(q).addClass(Z+"Photo").bind("error."+Z,function(){h(n(se,"Error").html(_.get("imgError")))}).one("load",function(){d===le&&setTimeout(function(){var e;_.get("retinaImage")&&i.devicePixelRatio>1&&(q.height=q.height/i.devicePixelRatio,q.width=q.width/i.devicePixelRatio),_.get("scalePhotos")&&(o=function(){q.height-=q.height*e,q.width-=q.width*e},_.mw&&q.width>_.mw&&(e=(q.width-_.mw)/q.width,o()),_.mh&&q.height>_.mh&&(e=(q.height-_.mh)/q.height,o())),_.h&&(q.style.marginTop=Math.max(_.mh-q.height,0)/2+"px"),W[1]&&(_.get("loop")||W[A+1])&&(q.style.cursor="pointer",t(q).bind("click."+Z,function(){J.next()})),q.style.width=q.width+"px",q.style.height=q.height+"px",h(q)},1)}),q.src=e):e&&M.load(e,_.get("data"),function(e,i){d===le&&h("error"===i?n(se,"Error").html(_.get("xhrError")):t(this).contents())})}var v,x,y,b,T,C,H,k,W,E,I,M,L,F,R,S,K,P,B,O,_,j,D,N,z,A,q,U,$,G,Q,J,V,X={html:!1,photo:!1,iframe:!1,inline:!1,transition:"elastic",speed:300,fadeOut:300,width:!1,initialWidth:"600",innerWidth:!1,maxWidth:!1,height:!1,initialHeight:"450",innerHeight:!1,maxHeight:!1,scalePhotos:!0,scrolling:!0,opacity:.9,preloading:!0,className:!1,overlayClose:!0,escKey:!0,arrowKey:!0,top:!1,bottom:!1,left:!1,right:!1,fixed:!1,data:void 0,closeButton:!0,fastIframe:!0,open:!1,reposition:!0,loop:!0,slideshow:!1,slideshowAuto:!0,slideshowSpeed:2500,slideshowStart:"start slideshow",slideshowStop:"stop slideshow",photoRegex:/\.(gif|png|jp(e|g|eg)|bmp|ico|webp|jxr|svg)((#|\?).*)?$/i,retinaImage:!1,retinaUrl:!1,retinaSuffix:"@2x.$1",current:"image {current} of {total}",previous:"previous",next:"next",close:"close",xhrError:"This content failed to load.",imgError:"This image failed to load.",returnFocus:!0,trapFocus:!0,onOpen:!1,onLoad:!1,onComplete:!1,onCleanup:!1,onClosed:!1,rel:function(){return this.rel},href:function(){return t(this).attr("href")},title:function(){return this.title},createImg:function(){var e=new Image,i=t(this).data("cbox-img-attrs");return"object"==typeof i&&t.each(i,function(t,i){e[t]=i}),e},createIframe:function(){var i=e.createElement("iframe"),n=t(this).data("cbox-iframe-attrs");return"object"==typeof n&&t.each(n,function(t,e){i[t]=e}),"frameBorder"in i&&(i.frameBorder=0),"allowTransparency"in i&&(i.allowTransparency="true"),i.name=(new Date).getTime(),i.allowFullscreen=!0,i}},Y="colorbox",Z="cbox",te=Z+"Element",ee=Z+"_open",ie=Z+"_load",ne=Z+"_complete",oe=Z+"_cleanup",re=Z+"_closed",he=Z+"_purge",ae=t("<a/>"),se="div",le=0,de={},ce=function(){function t(){clearTimeout(h)}function e(){(_.get("loop")||W[A+1])&&(t(),h=setTimeout(J.next,_.get("slideshowSpeed")))}function i(){S.html(_.get("slideshowStop")).unbind(s).one(s,n),ae.bind(ne,e).bind(ie,t),x.removeClass(a+"off").addClass(a+"on")}function n(){t(),ae.unbind(ne,e).unbind(ie,t),S.html(_.get("slideshowStart")).unbind(s).one(s,function(){J.next(),i()}),x.removeClass(a+"on").addClass(a+"off")}function o(){r=!1,S.hide(),t(),ae.unbind(ne,e).unbind(ie,t),x.removeClass(a+"off "+a+"on")}var r,h,a=Z+"Slideshow_",s="click."+Z;return function(){r?_.get("slideshow")||(ae.unbind(oe,o),o()):_.get("slideshow")&&W[1]&&(r=!0,ae.one(oe,o),_.get("slideshowAuto")?i():n(),S.show())}}();t[Y]||(t(p),J=t.fn[Y]=t[Y]=function(e,i){var n,o=this;return e=e||{},t.isFunction(o)&&(o=t("<a/>"),e.open=!0),o[0]?(p(),m()&&(i&&(e.onComplete=i),o.each(function(){var i=t.data(this,Y)||{};t.data(this,Y,t.extend(i,e))}).addClass(te),n=new r(o[0],e),n.get("open")&&f(o[0])),o):o},J.position=function(e,i){function n(){T[0].style.width=k[0].style.width=b[0].style.width=parseInt(x[0].style.width,10)-D+"px",b[0].style.height=C[0].style.height=H[0].style.height=parseInt(x[0].style.height,10)-j+"px"}var r,h,s,l=0,d=0,c=x.offset();if(E.unbind("resize."+Z),x.css({top:-9e4,left:-9e4}),h=E.scrollTop(),s=E.scrollLeft(),_.get("fixed")?(c.top-=h,c.left-=s,x.css({position:"fixed"})):(l=h,d=s,x.css({position:"absolute"})),d+=_.get("right")!==!1?Math.max(E.width()-_.w-z-D-a(_.get("right"),"x"),0):_.get("left")!==!1?a(_.get("left"),"x"):Math.round(Math.max(E.width()-_.w-z-D,0)/2),l+=_.get("bottom")!==!1?Math.max(o()-_.h-N-j-a(_.get("bottom"),"y"),0):_.get("top")!==!1?a(_.get("top"),"y"):Math.round(Math.max(o()-_.h-N-j,0)/2),x.css({top:c.top,left:c.left,visibility:"visible"}),y[0].style.width=y[0].style.height="9999px",r={width:_.w+z+D,height:_.h+N+j,top:l,left:d},e){var g=0;t.each(r,function(t){return r[t]!==de[t]?(g=e,void 0):void 0}),e=g}de=r,e||x.css(r),x.dequeue().animate(r,{duration:e||0,complete:function(){n(),$=!1,y[0].style.width=_.w+z+D+"px",y[0].style.height=_.h+N+j+"px",_.get("reposition")&&setTimeout(function(){E.bind("resize."+Z,J.position)},1),t.isFunction(i)&&i()},step:n})},J.resize=function(t){var e;U&&(t=t||{},t.width&&(_.w=a(t.width,"x")-z-D),t.innerWidth&&(_.w=a(t.innerWidth,"x")),I.css({width:_.w}),t.height&&(_.h=a(t.height,"y")-N-j),t.innerHeight&&(_.h=a(t.innerHeight,"y")),t.innerHeight||t.height||(e=I.scrollTop(),I.css({height:"auto"}),_.h=I.height()),I.css({height:_.h}),e&&I.scrollTop(e),J.position("none"===_.get("transition")?0:_.get("speed")))},J.prep=function(i){function o(){return _.w=_.w||I.width(),_.w=_.mw&&_.mw<_.w?_.mw:_.w,_.w}function a(){return _.h=_.h||I.height(),_.h=_.mh&&_.mh<_.h?_.mh:_.h,_.h}if(U){var d,g="none"===_.get("transition")?0:_.get("speed");I.remove(),I=n(se,"LoadedContent").append(i),I.hide().appendTo(M.show()).css({width:o(),overflow:_.get("scrolling")?"auto":"hidden"}).css({height:a()}).prependTo(b),M.hide(),t(q).css({"float":"none"}),c(_.get("className")),d=function(){function i(){t.support.opacity===!1&&x[0].style.removeAttribute("filter")}var n,o,a=W.length;U&&(o=function(){clearTimeout(Q),L.hide(),u(ne),_.get("onComplete")},F.html(_.get("title")).show(),I.show(),a>1?("string"==typeof _.get("current")&&R.html(_.get("current").replace("{current}",A+1).replace("{total}",a)).show(),K[_.get("loop")||a-1>A?"show":"hide"]().html(_.get("next")),P[_.get("loop")||A?"show":"hide"]().html(_.get("previous")),ce(),_.get("preloading")&&t.each([h(-1),h(1)],function(){var i,n=W[this],o=new r(n,t.data(n,Y)),h=o.get("href");h&&s(o,h)&&(h=l(o,h),i=e.createElement("img"),i.src=h)})):O.hide(),_.get("iframe")?(n=_.get("createIframe"),_.get("scrolling")||(n.scrolling="no"),t(n).attr({src:_.get("href"),"class":Z+"Iframe"}).one("load",o).appendTo(I),ae.one(he,function(){n.src="//about:blank"}),_.get("fastIframe")&&t(n).trigger("load")):o(),"fade"===_.get("transition")?x.fadeTo(g,1,i):i())},"fade"===_.get("transition")?x.fadeTo(g,0,function(){J.position(0,d)}):J.position(g,d)}},J.next=function(){!$&&W[1]&&(_.get("loop")||W[A+1])&&(A=h(1),f(W[A]))},J.prev=function(){!$&&W[1]&&(_.get("loop")||A)&&(A=h(-1),f(W[A]))},J.close=function(){U&&!G&&(G=!0,U=!1,u(oe),_.get("onCleanup"),E.unbind("."+Z),v.fadeTo(_.get("fadeOut")||0,0),x.stop().fadeTo(_.get("fadeOut")||0,0,function(){x.hide(),v.hide(),u(he),I.remove(),setTimeout(function(){G=!1,u(re),_.get("onClosed")},1)}))},J.remove=function(){x&&(x.stop(),t[Y].close(),x.stop(!1,!0).remove(),v.remove(),G=!1,x=null,t("."+te).removeData(Y).removeClass(te),t(e).unbind("click."+Z).unbind("keydown."+Z))},J.element=function(){return t(_.el)},J.settings=X)})(jQuery,document,window);
9
  /* Media Uploader */
assets/js/wpdiscuz-combo.min.js CHANGED
@@ -3,11 +3,11 @@
3
  /* Quill */
4
  !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.Quill=e():t.Quill=e()}("undefined"!=typeof self?self:this,function(){return function(t){function e(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,e),o.l=!0,o.exports}var n={};return e.m=t,e.c=n,e.d=function(t,n,r){e.o(t,n)||Object.defineProperty(t,n,{configurable:!1,enumerable:!0,get:r})},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=45)}([function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(17),o=n(18),i=n(19),l=n(48),a=n(49),s=n(50),u=n(51),c=n(52),f=n(11),h=n(29),p=n(30),d=n(28),y=n(1),v={Scope:y.Scope,create:y.create,find:y.find,query:y.query,register:y.register,Container:r.default,Format:o.default,Leaf:i.default,Embed:u.default,Scroll:l.default,Block:s.default,Inline:a.default,Text:c.default,Attributor:{Attribute:f.default,Class:h.default,Style:p.default,Store:d.default}};e.default=v},function(t,e,n){"use strict";function r(t,e){var n=i(t);if(null==n)throw new s("Unable to create "+t+" blot");var r=n;return new r(t instanceof Node||t.nodeType===Node.TEXT_NODE?t:r.create(e),e)}function o(t,n){return void 0===n&&(n=!1),null==t?null:null!=t[e.DATA_KEY]?t[e.DATA_KEY].blot:n?o(t.parentNode,n):null}function i(t,e){void 0===e&&(e=p.ANY);var n;if("string"==typeof t)n=h[t]||u[t];else if(t instanceof Text||t.nodeType===Node.TEXT_NODE)n=h.text;else if("number"==typeof t)t&p.LEVEL&p.BLOCK?n=h.block:t&p.LEVEL&p.INLINE&&(n=h.inline);else if(t instanceof HTMLElement){var r=(t.getAttribute("class")||"").split(/\s+/);for(var o in r)if(n=c[r[o]])break;n=n||f[t.tagName]}return null==n?null:e&p.LEVEL&n.scope&&e&p.TYPE&n.scope?n:null}function l(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];if(t.length>1)return t.map(function(t){return l(t)});var n=t[0];if("string"!=typeof n.blotName&&"string"!=typeof n.attrName)throw new s("Invalid definition");if("abstract"===n.blotName)throw new s("Cannot register abstract class");if(h[n.blotName||n.attrName]=n,"string"==typeof n.keyName)u[n.keyName]=n;else if(null!=n.className&&(c[n.className]=n),null!=n.tagName){Array.isArray(n.tagName)?n.tagName=n.tagName.map(function(t){return t.toUpperCase()}):n.tagName=n.tagName.toUpperCase();var r=Array.isArray(n.tagName)?n.tagName:[n.tagName];r.forEach(function(t){null!=f[t]&&null!=n.className||(f[t]=n)})}return n}var a=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var s=function(t){function e(e){var n=this;return e="[Parchment] "+e,n=t.call(this,e)||this,n.message=e,n.name=n.constructor.name,n}return a(e,t),e}(Error);e.ParchmentError=s;var u={},c={},f={},h={};e.DATA_KEY="__blot";var p;!function(t){t[t.TYPE=3]="TYPE",t[t.LEVEL=12]="LEVEL",t[t.ATTRIBUTE=13]="ATTRIBUTE",t[t.BLOT=14]="BLOT",t[t.INLINE=7]="INLINE",t[t.BLOCK=11]="BLOCK",t[t.BLOCK_BLOT=10]="BLOCK_BLOT",t[t.INLINE_BLOT=6]="INLINE_BLOT",t[t.BLOCK_ATTRIBUTE=9]="BLOCK_ATTRIBUTE",t[t.INLINE_ATTRIBUTE=5]="INLINE_ATTRIBUTE",t[t.ANY=15]="ANY"}(p=e.Scope||(e.Scope={})),e.create=r,e.find=o,e.query=i,e.register=l},function(t,e){"use strict";var n=Object.prototype.hasOwnProperty,r=Object.prototype.toString,o=function(t){return"function"==typeof Array.isArray?Array.isArray(t):"[object Array]"===r.call(t)},i=function(t){if(!t||"[object Object]"!==r.call(t))return!1;var e=n.call(t,"constructor"),o=t.constructor&&t.constructor.prototype&&n.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!e&&!o)return!1;var i;for(i in t);return void 0===i||n.call(t,i)};t.exports=function t(){var e,n,r,l,a,s,u=arguments[0],c=1,f=arguments.length,h=!1;for("boolean"==typeof u&&(h=u,u=arguments[1]||{},c=2),(null==u||"object"!=typeof u&&"function"!=typeof u)&&(u={});c<f;++c)if(null!=(e=arguments[c]))for(n in e)r=u[n],l=e[n],u!==l&&(h&&l&&(i(l)||(a=o(l)))?(a?(a=!1,s=r&&o(r)?r:[]):s=r&&i(r)?r:{},u[n]=t(h,s,l)):void 0!==l&&(u[n]=l));return u}},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function a(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return null==t?e:("function"==typeof t.formats&&(e=(0,f.default)(e,t.formats())),null==t.parent||"scroll"==t.parent.blotName||t.parent.statics.scope!==t.statics.scope?e:a(t.parent,e))}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.BlockEmbed=e.bubbleFormats=void 0;var s=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),u=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},c=n(2),f=r(c),h=n(4),p=r(h),d=n(0),y=r(d),v=n(14),b=r(v),g=n(5),m=r(g),_=n(8),O=r(_),w=function(t){function e(){return o(this,e),i(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return l(e,t),s(e,[{key:"attach",value:function(){u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"attach",this).call(this),this.attributes=new y.default.Attributor.Store(this.domNode)}},{key:"delta",value:function(){return(new p.default).insert(this.value(),(0,f.default)(this.formats(),this.attributes.values()))}},{key:"format",value:function(t,e){var n=y.default.query(t,y.default.Scope.BLOCK_ATTRIBUTE);null!=n&&this.attributes.attribute(n,e)}},{key:"formatAt",value:function(t,e,n,r){this.format(n,r)}},{key:"insertAt",value:function(t,n,r){if("string"==typeof n&&n.endsWith("\n")){var o=y.default.create(x.blotName);this.parent.insertBefore(o,0===t?this:this.next),o.insertAt(0,n.slice(0,-1))}else u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"insertAt",this).call(this,t,n,r)}}]),e}(y.default.Embed);w.scope=y.default.Scope.BLOCK_BLOT;var x=function(t){function e(t){o(this,e);var n=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return n.cache={},n}return l(e,t),s(e,[{key:"delta",value:function(){return null==this.cache.delta&&(this.cache.delta=this.descendants(y.default.Leaf).reduce(function(t,e){return 0===e.length()?t:t.insert(e.value(),a(e))},new p.default).insert("\n",a(this))),this.cache.delta}},{key:"deleteAt",value:function(t,n){u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"deleteAt",this).call(this,t,n),this.cache={}}},{key:"formatAt",value:function(t,n,r,o){n<=0||(y.default.query(r,y.default.Scope.BLOCK)?t+n===this.length()&&this.format(r,o):u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"formatAt",this).call(this,t,Math.min(n,this.length()-t-1),r,o),this.cache={})}},{key:"insertAt",value:function(t,n,r){if(null!=r)return u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"insertAt",this).call(this,t,n,r);if(0!==n.length){var o=n.split("\n"),i=o.shift();i.length>0&&(t<this.length()-1||null==this.children.tail?u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"insertAt",this).call(this,Math.min(t,this.length()-1),i):this.children.tail.insertAt(this.children.tail.length(),i),this.cache={});var l=this;o.reduce(function(t,e){return l=l.split(t,!0),l.insertAt(0,e),e.length},t+i.length)}}},{key:"insertBefore",value:function(t,n){var r=this.children.head;u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"insertBefore",this).call(this,t,n),r instanceof b.default&&r.remove(),this.cache={}}},{key:"length",value:function(){return null==this.cache.length&&(this.cache.length=u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"length",this).call(this)+1),this.cache.length}},{key:"moveChildren",value:function(t,n){u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"moveChildren",this).call(this,t,n),this.cache={}}},{key:"optimize",value:function(t){u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"optimize",this).call(this,t),this.cache={}}},{key:"path",value:function(t){return u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"path",this).call(this,t,!0)}},{key:"removeChild",value:function(t){u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"removeChild",this).call(this,t),this.cache={}}},{key:"split",value:function(t){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(n&&(0===t||t>=this.length()-1)){var r=this.clone();return 0===t?(this.parent.insertBefore(r,this),this):(this.parent.insertBefore(r,this.next),r)}var o=u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"split",this).call(this,t,n);return this.cache={},o}}]),e}(y.default.Block);x.blotName="block",x.tagName="P",x.defaultChild="break",x.allowedChildren=[m.default,y.default.Embed,O.default],e.bubbleFormats=a,e.BlockEmbed=w,e.default=x},function(t,e,n){var r=n(54),o=n(12),i=n(2),l=n(20),a=String.fromCharCode(0),s=function(t){Array.isArray(t)?this.ops=t:null!=t&&Array.isArray(t.ops)?this.ops=t.ops:this.ops=[]};s.prototype.insert=function(t,e){var n={};return 0===t.length?this:(n.insert=t,null!=e&&"object"==typeof e&&Object.keys(e).length>0&&(n.attributes=e),this.push(n))},s.prototype.delete=function(t){return t<=0?this:this.push({delete:t})},s.prototype.retain=function(t,e){if(t<=0)return this;var n={retain:t};return null!=e&&"object"==typeof e&&Object.keys(e).length>0&&(n.attributes=e),this.push(n)},s.prototype.push=function(t){var e=this.ops.length,n=this.ops[e-1];if(t=i(!0,{},t),"object"==typeof n){if("number"==typeof t.delete&&"number"==typeof n.delete)return this.ops[e-1]={delete:n.delete+t.delete},this;if("number"==typeof n.delete&&null!=t.insert&&(e-=1,"object"!=typeof(n=this.ops[e-1])))return this.ops.unshift(t),this;if(o(t.attributes,n.attributes)){if("string"==typeof t.insert&&"string"==typeof n.insert)return this.ops[e-1]={insert:n.insert+t.insert},"object"==typeof t.attributes&&(this.ops[e-1].attributes=t.attributes),this;if("number"==typeof t.retain&&"number"==typeof n.retain)return this.ops[e-1]={retain:n.retain+t.retain},"object"==typeof t.attributes&&(this.ops[e-1].attributes=t.attributes),this}}return e===this.ops.length?this.ops.push(t):this.ops.splice(e,0,t),this},s.prototype.chop=function(){var t=this.ops[this.ops.length-1];return t&&t.retain&&!t.attributes&&this.ops.pop(),this},s.prototype.filter=function(t){return this.ops.filter(t)},s.prototype.forEach=function(t){this.ops.forEach(t)},s.prototype.map=function(t){return this.ops.map(t)},s.prototype.partition=function(t){var e=[],n=[];return this.forEach(function(r){(t(r)?e:n).push(r)}),[e,n]},s.prototype.reduce=function(t,e){return this.ops.reduce(t,e)},s.prototype.changeLength=function(){return this.reduce(function(t,e){return e.insert?t+l.length(e):e.delete?t-e.delete:t},0)},s.prototype.length=function(){return this.reduce(function(t,e){return t+l.length(e)},0)},s.prototype.slice=function(t,e){t=t||0,"number"!=typeof e&&(e=1/0);for(var n=[],r=l.iterator(this.ops),o=0;o<e&&r.hasNext();){var i;o<t?i=r.next(t-o):(i=r.next(e-o),n.push(i)),o+=l.length(i)}return new s(n)},s.prototype.compose=function(t){for(var e=l.iterator(this.ops),n=l.iterator(t.ops),r=new s;e.hasNext()||n.hasNext();)if("insert"===n.peekType())r.push(n.next());else if("delete"===e.peekType())r.push(e.next());else{var o=Math.min(e.peekLength(),n.peekLength()),i=e.next(o),a=n.next(o);if("number"==typeof a.retain){var u={};"number"==typeof i.retain?u.retain=o:u.insert=i.insert;var c=l.attributes.compose(i.attributes,a.attributes,"number"==typeof i.retain);c&&(u.attributes=c),r.push(u)}else"number"==typeof a.delete&&"number"==typeof i.retain&&r.push(a)}return r.chop()},s.prototype.concat=function(t){var e=new s(this.ops.slice());return t.ops.length>0&&(e.push(t.ops[0]),e.ops=e.ops.concat(t.ops.slice(1))),e},s.prototype.diff=function(t,e){if(this.ops===t.ops)return new s;var n=[this,t].map(function(e){return e.map(function(n){if(null!=n.insert)return"string"==typeof n.insert?n.insert:a;var r=e===t?"on":"with";throw new Error("diff() called "+r+" non-document")}).join("")}),i=new s,u=r(n[0],n[1],e),c=l.iterator(this.ops),f=l.iterator(t.ops);return u.forEach(function(t){for(var e=t[1].length;e>0;){var n=0;switch(t[0]){case r.INSERT:n=Math.min(f.peekLength(),e),i.push(f.next(n));break;case r.DELETE:n=Math.min(e,c.peekLength()),c.next(n),i.delete(n);break;case r.EQUAL:n=Math.min(c.peekLength(),f.peekLength(),e);var a=c.next(n),s=f.next(n);o(a.insert,s.insert)?i.retain(n,l.attributes.diff(a.attributes,s.attributes)):i.push(s).delete(n)}e-=n}}),i.chop()},s.prototype.eachLine=function(t,e){e=e||"\n";for(var n=l.iterator(this.ops),r=new s,o=0;n.hasNext();){if("insert"!==n.peekType())return;var i=n.peek(),a=l.length(i)-n.peekLength(),u="string"==typeof i.insert?i.insert.indexOf(e,a)-a:-1;if(u<0)r.push(n.next());else if(u>0)r.push(n.next(u));else{if(!1===t(r,n.next(1).attributes||{},o))return;o+=1,r=new s}}r.length()>0&&t(r,{},o)},s.prototype.transform=function(t,e){if(e=!!e,"number"==typeof t)return this.transformPosition(t,e);for(var n=l.iterator(this.ops),r=l.iterator(t.ops),o=new s;n.hasNext()||r.hasNext();)if("insert"!==n.peekType()||!e&&"insert"===r.peekType())if("insert"===r.peekType())o.push(r.next());else{var i=Math.min(n.peekLength(),r.peekLength()),a=n.next(i),u=r.next(i);if(a.delete)continue;u.delete?o.push(u):o.retain(i,l.attributes.transform(a.attributes,u.attributes,e))}else o.retain(l.length(n.next()));return o.chop()},s.prototype.transformPosition=function(t,e){e=!!e;for(var n=l.iterator(this.ops),r=0;n.hasNext()&&r<=t;){var o=n.peekLength(),i=n.peekType();n.next(),"delete"!==i?("insert"===i&&(r<t||!e)&&(t+=o),r+=o):t-=Math.min(o,t-r)}return t},t.exports=s},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var a=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),s=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},u=n(8),c=r(u),f=n(0),h=r(f),p=function(t){function e(){return o(this,e),i(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return l(e,t),a(e,[{key:"formatAt",value:function(t,n,r,o){if(e.compare(this.statics.blotName,r)<0&&h.default.query(r,h.default.Scope.BLOT)){var i=this.isolate(t,n);o&&i.wrap(r,o)}else s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"formatAt",this).call(this,t,n,r,o)}},{key:"optimize",value:function(t){if(s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"optimize",this).call(this,t),this.parent instanceof e&&e.compare(this.statics.blotName,this.parent.statics.blotName)>0){var n=this.parent.isolate(this.offset(),this.length());this.moveChildren(n),n.wrap(this)}}}],[{key:"compare",value:function(t,n){var r=e.order.indexOf(t),o=e.order.indexOf(n);return r>=0||o>=0?r-o:t===n?0:t<n?-1:1}}]),e}(h.default.Inline);p.allowedChildren=[p,h.default.Embed,c.default],p.order=["cursor","inline","underline","strike","italic","bold","script","link","code"],e.default=p},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function l(t,e){if(e=(0,N.default)(!0,{container:t,modules:{clipboard:!0,keyboard:!0,history:!0}},e),e.theme&&e.theme!==S.DEFAULTS.theme){if(e.theme=S.import("themes/"+e.theme),null==e.theme)throw new Error("Invalid theme "+e.theme+". Did you register it?")}else e.theme=T.default;var n=(0,N.default)(!0,{},e.theme.DEFAULTS);[n,e].forEach(function(t){t.modules=t.modules||{},Object.keys(t.modules).forEach(function(e){!0===t.modules[e]&&(t.modules[e]={})})});var r=Object.keys(n.modules).concat(Object.keys(e.modules)),o=r.reduce(function(t,e){var n=S.import("modules/"+e);return null==n?P.error("Cannot load "+e+" module. Are you sure you registered it?"):t[e]=n.DEFAULTS||{},t},{});return null!=e.modules&&e.modules.toolbar&&e.modules.toolbar.constructor!==Object&&(e.modules.toolbar={container:e.modules.toolbar}),e=(0,N.default)(!0,{},S.DEFAULTS,{modules:o},n,e),["bounds","container","scrollingContainer"].forEach(function(t){"string"==typeof e[t]&&(e[t]=document.querySelector(e[t]))}),e.modules=Object.keys(e.modules).reduce(function(t,n){return e.modules[n]&&(t[n]=e.modules[n]),t},{}),e}function a(t,e,n,r){if(this.options.strict&&!this.isEnabled()&&e===g.default.sources.USER)return new d.default;var o=null==n?null:this.getSelection(),i=this.editor.delta,l=t();if(null!=o&&(!0===n&&(n=o.index),null==r?o=u(o,l,e):0!==r&&(o=u(o,n,r,e)),this.setSelection(o,g.default.sources.SILENT)),l.length()>0){var a,s=[g.default.events.TEXT_CHANGE,l,i,e];if((a=this.emitter).emit.apply(a,[g.default.events.EDITOR_CHANGE].concat(s)),e!==g.default.sources.SILENT){var c;(c=this.emitter).emit.apply(c,s)}}return l}function s(t,e,n,r,o){var i={};return"number"==typeof t.index&&"number"==typeof t.length?"number"!=typeof e?(o=r,r=n,n=e,e=t.length,t=t.index):(e=t.length,t=t.index):"number"!=typeof e&&(o=r,r=n,n=e,e=0),"object"===(void 0===n?"undefined":c(n))?(i=n,o=r):"string"==typeof n&&(null!=r?i[n]=r:o=n),o=o||g.default.sources.API,[t,e,i,o]}function u(t,e,n,r){if(null==t)return null;var o=void 0,i=void 0;if(e instanceof d.default){var l=[t.index,t.index+t.length].map(function(t){return e.transformPosition(t,r!==g.default.sources.USER)}),a=f(l,2);o=a[0],i=a[1]}else{var s=[t.index,t.index+t.length].map(function(t){return t<e||t===e&&r===g.default.sources.USER?t:n>=0?t+n:Math.max(e,t+n)}),u=f(s,2);o=u[0],i=u[1]}return new x.Range(o,i-o)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.overload=e.expandConfig=void 0;var c="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=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),h=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}();n(53);var p=n(4),d=r(p),y=n(57),v=r(y),b=n(9),g=r(b),m=n(7),_=r(m),O=n(0),w=r(O),x=n(22),k=r(x),E=n(2),N=r(E),j=n(10),A=r(j),q=n(32),T=r(q),P=(0,A.default)("quill"),S=function(){function t(e){var n=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(i(this,t),this.options=l(e,r),this.container=this.options.container,null==this.container)return P.error("Invalid Quill container",e);this.options.debug&&t.debug(this.options.debug);var o=this.container.innerHTML.trim();this.container.classList.add("ql-container"),this.container.innerHTML="",this.container.__quill=this,this.root=this.addContainer("ql-editor"),this.root.classList.add("ql-blank"),this.root.setAttribute("data-gramm",!1),this.scrollingContainer=this.options.scrollingContainer||this.root,this.emitter=new g.default,this.scroll=w.default.create(this.root,{emitter:this.emitter,whitelist:this.options.formats}),this.editor=new v.default(this.scroll),this.selection=new k.default(this.scroll,this.emitter),this.theme=new this.options.theme(this,this.options),this.keyboard=this.theme.addModule("keyboard"),this.clipboard=this.theme.addModule("clipboard"),this.history=this.theme.addModule("history"),this.theme.init(),this.emitter.on(g.default.events.EDITOR_CHANGE,function(t){t===g.default.events.TEXT_CHANGE&&n.root.classList.toggle("ql-blank",n.editor.isBlank())}),this.emitter.on(g.default.events.SCROLL_UPDATE,function(t,e){var r=n.selection.lastRange,o=r&&0===r.length?r.index:void 0;a.call(n,function(){return n.editor.update(null,e,o)},t)});var s=this.clipboard.convert("<div class='ql-editor' style=\"white-space: normal;\">"+o+"<p><br></p></div>");this.setContents(s),this.history.clear(),this.options.placeholder&&this.root.setAttribute("data-placeholder",this.options.placeholder),this.options.readOnly&&this.disable()}return h(t,null,[{key:"debug",value:function(t){!0===t&&(t="log"),A.default.level(t)}},{key:"find",value:function(t){return t.__quill||w.default.find(t)}},{key:"import",value:function(t){return null==this.imports[t]&&P.error("Cannot import "+t+". Are you sure it was registered?"),this.imports[t]}},{key:"register",value:function(t,e){var n=this,r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if("string"!=typeof t){var o=t.attrName||t.blotName;"string"==typeof o?this.register("formats/"+o,t,e):Object.keys(t).forEach(function(r){n.register(r,t[r],e)})}else null==this.imports[t]||r||P.warn("Overwriting "+t+" with",e),this.imports[t]=e,(t.startsWith("blots/")||t.startsWith("formats/"))&&"abstract"!==e.blotName?w.default.register(e):t.startsWith("modules")&&"function"==typeof e.register&&e.register()}}]),h(t,[{key:"addContainer",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if("string"==typeof t){var n=t;t=document.createElement("div"),t.classList.add(n)}return this.container.insertBefore(t,e),t}},{key:"blur",value:function(){this.selection.setRange(null)}},{key:"deleteText",value:function(t,e,n){var r=this,o=s(t,e,n),i=f(o,4);return t=i[0],e=i[1],n=i[3],a.call(this,function(){return r.editor.deleteText(t,e)},n,t,-1*e)}},{key:"disable",value:function(){this.enable(!1)}},{key:"enable",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this.scroll.enable(t),this.container.classList.toggle("ql-disabled",!t)}},{key:"focus",value:function(){var t=this.scrollingContainer.scrollTop;this.selection.focus(),this.scrollingContainer.scrollTop=t,this.scrollIntoView()}},{key:"format",value:function(t,e){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:g.default.sources.API;return a.call(this,function(){var r=n.getSelection(!0),i=new d.default;if(null==r)return i;if(w.default.query(t,w.default.Scope.BLOCK))i=n.editor.formatLine(r.index,r.length,o({},t,e));else{if(0===r.length)return n.selection.format(t,e),i;i=n.editor.formatText(r.index,r.length,o({},t,e))}return n.setSelection(r,g.default.sources.SILENT),i},r)}},{key:"formatLine",value:function(t,e,n,r,o){var i=this,l=void 0,u=s(t,e,n,r,o),c=f(u,4);return t=c[0],e=c[1],l=c[2],o=c[3],a.call(this,function(){return i.editor.formatLine(t,e,l)},o,t,0)}},{key:"formatText",value:function(t,e,n,r,o){var i=this,l=void 0,u=s(t,e,n,r,o),c=f(u,4);return t=c[0],e=c[1],l=c[2],o=c[3],a.call(this,function(){return i.editor.formatText(t,e,l)},o,t,0)}},{key:"getBounds",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=void 0;n="number"==typeof t?this.selection.getBounds(t,e):this.selection.getBounds(t.index,t.length);var r=this.container.getBoundingClientRect();return{bottom:n.bottom-r.top,height:n.height,left:n.left-r.left,right:n.right-r.left,top:n.top-r.top,width:n.width}}},{key:"getContents",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.getLength()-t,n=s(t,e),r=f(n,2);return t=r[0],e=r[1],this.editor.getContents(t,e)}},{key:"getFormat",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.getSelection(!0),e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return"number"==typeof t?this.editor.getFormat(t,e):this.editor.getFormat(t.index,t.length)}},{key:"getIndex",value:function(t){return t.offset(this.scroll)}},{key:"getLength",value:function(){return this.scroll.length()}},{key:"getLeaf",value:function(t){return this.scroll.leaf(t)}},{key:"getLine",value:function(t){return this.scroll.line(t)}},{key:"getLines",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.MAX_VALUE;return"number"!=typeof t?this.scroll.lines(t.index,t.length):this.scroll.lines(t,e)}},{key:"getModule",value:function(t){return this.theme.modules[t]}},{key:"getSelection",value:function(){return arguments.length>0&&void 0!==arguments[0]&&arguments[0]&&this.focus(),this.update(),this.selection.getRange()[0]}},{key:"getText",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.getLength()-t,n=s(t,e),r=f(n,2);return t=r[0],e=r[1],this.editor.getText(t,e)}},{key:"hasFocus",value:function(){return this.selection.hasFocus()}},{key:"insertEmbed",value:function(e,n,r){var o=this,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:t.sources.API;return a.call(this,function(){return o.editor.insertEmbed(e,n,r)},i,e)}},{key:"insertText",value:function(t,e,n,r,o){var i=this,l=void 0,u=s(t,0,n,r,o),c=f(u,4);return t=c[0],l=c[2],o=c[3],a.call(this,function(){return i.editor.insertText(t,e,l)},o,t,e.length)}},{key:"isEnabled",value:function(){return!this.container.classList.contains("ql-disabled")}},{key:"off",value:function(){return this.emitter.off.apply(this.emitter,arguments)}},{key:"on",value:function(){return this.emitter.on.apply(this.emitter,arguments)}},{key:"once",value:function(){return this.emitter.once.apply(this.emitter,arguments)}},{key:"pasteHTML",value:function(t,e,n){this.clipboard.dangerouslyPasteHTML(t,e,n)}},{key:"removeFormat",value:function(t,e,n){var r=this,o=s(t,e,n),i=f(o,4);return t=i[0],e=i[1],n=i[3],a.call(this,function(){return r.editor.removeFormat(t,e)},n,t)}},{key:"scrollIntoView",value:function(){this.selection.scrollIntoView(this.scrollingContainer)}},{key:"setContents",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:g.default.sources.API;return a.call(this,function(){t=new d.default(t);var n=e.getLength(),r=e.editor.deleteText(0,n),o=e.editor.applyDelta(t),i=o.ops[o.ops.length-1];return null!=i&&"string"==typeof i.insert&&"\n"===i.insert[i.insert.length-1]&&(e.editor.deleteText(e.getLength()-1,1),o.delete(1)),r.compose(o)},n)}},{key:"setSelection",value:function(e,n,r){if(null==e)this.selection.setRange(null,n||t.sources.API);else{var o=s(e,n,r),i=f(o,4);e=i[0],n=i[1],r=i[3],this.selection.setRange(new x.Range(e,n),r),r!==g.default.sources.SILENT&&this.selection.scrollIntoView(this.scrollingContainer)}}},{key:"setText",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:g.default.sources.API,n=(new d.default).insert(t);return this.setContents(n,e)}},{key:"update",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:g.default.sources.USER,e=this.scroll.update(t);return this.selection.update(t),e}},{key:"updateContents",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:g.default.sources.API;return a.call(this,function(){return t=new d.default(t),e.editor.applyDelta(t,n)},n,!0)}}]),t}();S.DEFAULTS={bounds:null,formats:null,modules:{},placeholder:"",readOnly:!1,scrollingContainer:null,strict:!0,theme:"default"},S.events=g.default.events,S.sources=g.default.sources,S.version="1.3.6",S.imports={delta:d.default,parchment:w.default,"core/module":_.default,"core/theme":T.default},e.expandConfig=l,e.overload=s,e.default=S},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});var o=function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};r(this,t),this.quill=e,this.options=n};o.DEFAULTS={},e.default=o},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=n(0),a=function(t){return t&&t.__esModule?t:{default:t}}(l),s=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),e}(a.default.Text);e.default=s},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var a=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),s=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},u=n(58),c=r(u),f=n(10),h=r(f),p=(0,h.default)("quill:events");["selectionchange","mousedown","mouseup","click"].forEach(function(t){document.addEventListener(t,function(){for(var t=arguments.length,e=Array(t),n=0;n<t;n++)e[n]=arguments[n];[].slice.call(document.querySelectorAll(".ql-container")).forEach(function(t){if(t.__quill&&t.__quill.emitter){var n;(n=t.__quill.emitter).handleDOM.apply(n,e)}})})});var d=function(t){function e(){o(this,e);var t=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this));return t.listeners={},t.on("error",p.error),t}return l(e,t),a(e,[{key:"emit",value:function(){p.log.apply(p,arguments),s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"emit",this).apply(this,arguments)}},{key:"handleDOM",value:function(t){for(var e=arguments.length,n=Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];(this.listeners[t.type]||[]).forEach(function(e){var r=e.node,o=e.handler;(t.target===r||r.contains(t.target))&&o.apply(void 0,[t].concat(n))})}},{key:"listenDOM",value:function(t,e,n){this.listeners[t]||(this.listeners[t]=[]),this.listeners[t].push({node:e,handler:n})}}]),e}(c.default);d.events={EDITOR_CHANGE:"editor-change",SCROLL_BEFORE_UPDATE:"scroll-before-update",SCROLL_OPTIMIZE:"scroll-optimize",SCROLL_UPDATE:"scroll-update",SELECTION_CHANGE:"selection-change",TEXT_CHANGE:"text-change"},d.sources={API:"api",SILENT:"silent",USER:"user"},e.default=d},function(t,e,n){"use strict";function r(t){if(i.indexOf(t)<=i.indexOf(l)){for(var e,n=arguments.length,r=Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];(e=console)[t].apply(e,r)}}function o(t){return i.reduce(function(e,n){return e[n]=r.bind(console,n,t),e},{})}Object.defineProperty(e,"__esModule",{value:!0});var i=["error","warn","log","info"],l="warn";r.level=o.level=function(t){l=t},e.default=o},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1),o=function(){function t(t,e,n){void 0===n&&(n={}),this.attrName=t,this.keyName=e;var o=r.Scope.TYPE&r.Scope.ATTRIBUTE;null!=n.scope?this.scope=n.scope&r.Scope.LEVEL|o:this.scope=r.Scope.ATTRIBUTE,null!=n.whitelist&&(this.whitelist=n.whitelist)}return t.keys=function(t){return[].map.call(t.attributes,function(t){return t.name})},t.prototype.add=function(t,e){return!!this.canAdd(t,e)&&(t.setAttribute(this.keyName,e),!0)},t.prototype.canAdd=function(t,e){return null!=r.query(t,r.Scope.BLOT&(this.scope|r.Scope.TYPE))&&(null==this.whitelist||("string"==typeof e?this.whitelist.indexOf(e.replace(/["']/g,""))>-1:this.whitelist.indexOf(e)>-1))},t.prototype.remove=function(t){t.removeAttribute(this.keyName)},t.prototype.value=function(t){var e=t.getAttribute(this.keyName);return this.canAdd(t,e)&&e?e:""},t}();e.default=o},function(t,e,n){function r(t){return null===t||void 0===t}function o(t){return!(!t||"object"!=typeof t||"number"!=typeof t.length)&&("function"==typeof t.copy&&"function"==typeof t.slice&&!(t.length>0&&"number"!=typeof t[0]))}function i(t,e,n){var i,c;if(r(t)||r(e))return!1;if(t.prototype!==e.prototype)return!1;if(s(t))return!!s(e)&&(t=l.call(t),e=l.call(e),u(t,e,n));if(o(t)){if(!o(e))return!1;if(t.length!==e.length)return!1;for(i=0;i<t.length;i++)if(t[i]!==e[i])return!1;return!0}try{var f=a(t),h=a(e)}catch(t){return!1}if(f.length!=h.length)return!1;for(f.sort(),h.sort(),i=f.length-1;i>=0;i--)if(f[i]!=h[i])return!1;for(i=f.length-1;i>=0;i--)if(c=f[i],!u(t[c],e[c],n))return!1;return typeof t==typeof e}var l=Array.prototype.slice,a=n(55),s=n(56),u=t.exports=function(t,e,n){return n||(n={}),t===e||(t instanceof Date&&e instanceof Date?t.getTime()===e.getTime():!t||!e||"object"!=typeof t&&"object"!=typeof e?n.strict?t===e:t==e:i(t,e,n))}},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.Code=void 0;var a=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),s=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),u=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},c=n(4),f=r(c),h=n(0),p=r(h),d=n(3),y=r(d),v=n(5),b=r(v),g=n(8),m=r(g),_=function(t){function e(){return o(this,e),i(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return l(e,t),e}(b.default);_.blotName="code",_.tagName="CODE";var O=function(t){function e(){return o(this,e),i(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return l(e,t),s(e,[{key:"delta",value:function(){var t=this,e=this.domNode.textContent;return e.endsWith("\n")&&(e=e.slice(0,-1)),e.split("\n").reduce(function(e,n){return e.insert(n).insert("\n",t.formats())},new f.default)}},{key:"format",value:function(t,n){if(t!==this.statics.blotName||!n){var r=this.descendant(m.default,this.length()-1),o=a(r,1),i=o[0];null!=i&&i.deleteAt(i.length()-1,1),u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"format",this).call(this,t,n)}}},{key:"formatAt",value:function(t,n,r,o){if(0!==n&&null!=p.default.query(r,p.default.Scope.BLOCK)&&(r!==this.statics.blotName||o!==this.statics.formats(this.domNode))){var i=this.newlineIndex(t);if(!(i<0||i>=t+n)){var l=this.newlineIndex(t,!0)+1,a=i-l+1,s=this.isolate(l,a),u=s.next;s.format(r,o),u instanceof e&&u.formatAt(0,t-l+n-a,r,o)}}}},{key:"insertAt",value:function(t,e,n){if(null==n){var r=this.descendant(m.default,t),o=a(r,2),i=o[0],l=o[1];i.insertAt(l,e)}}},{key:"length",value:function(){var t=this.domNode.textContent.length;return this.domNode.textContent.endsWith("\n")?t:t+1}},{key:"newlineIndex",value:function(t){if(arguments.length>1&&void 0!==arguments[1]&&arguments[1])return this.domNode.textContent.slice(0,t).lastIndexOf("\n");var e=this.domNode.textContent.slice(t).indexOf("\n");return e>-1?t+e:-1}},{key:"optimize",value:function(t){this.domNode.textContent.endsWith("\n")||this.appendChild(p.default.create("text","\n")),u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"optimize",this).call(this,t);var n=this.next;null!=n&&n.prev===this&&n.statics.blotName===this.statics.blotName&&this.statics.formats(this.domNode)===n.statics.formats(n.domNode)&&(n.optimize(t),n.moveChildren(this),n.remove())}},{key:"replace",value:function(t){u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"replace",this).call(this,t),[].slice.call(this.domNode.querySelectorAll("*")).forEach(function(t){var e=p.default.find(t);null==e?t.parentNode.removeChild(t):e instanceof p.default.Embed?e.remove():e.unwrap()})}}],[{key:"create",value:function(t){var n=u(e.__proto__||Object.getPrototypeOf(e),"create",this).call(this,t);return n.setAttribute("spellcheck",!1),n}},{key:"formats",value:function(){return!0}}]),e}(y.default);O.blotName="code-block",O.tagName="PRE",O.TAB=" ",e.Code=_,e.default=O},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(0),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,[{key:"insertInto",value:function(t,n){0===t.children.length?a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"insertInto",this).call(this,t,n):this.remove()}},{key:"length",value:function(){return 0}},{key:"value",value:function(){return""}}],[{key:"value",value:function(){}}]),e}(u.default.Embed);c.blotName="break",c.tagName="BR",e.default=c},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function l(t,e){var n=document.createElement("a");n.href=t;var r=n.href.slice(0,n.href.indexOf(":"));return e.indexOf(r)>-1}Object.defineProperty(e,"__esModule",{value:!0}),e.sanitize=e.default=void 0;var a=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),s=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},u=n(5),c=function(t){return t&&t.__esModule?t:{default:t}}(u),f=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),a(e,[{key:"format",value:function(t,n){if(t!==this.statics.blotName||!n)return s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"format",this).call(this,t,n);n=this.constructor.sanitize(n),this.domNode.setAttribute("href",n)}}],[{key:"create",value:function(t){var n=s(e.__proto__||Object.getPrototypeOf(e),"create",this).call(this,t);return t=this.sanitize(t),n.setAttribute("href",t),n.setAttribute("target","_blank"),n}},{key:"formats",value:function(t){return t.getAttribute("href")}},{key:"sanitize",value:function(t){return l(t,this.PROTOCOL_WHITELIST)?t:this.SANITIZED_URL}}]),e}(c.default);f.blotName="link",f.tagName="A",f.SANITIZED_URL="about:blank",f.PROTOCOL_WHITELIST=["http","https","mailto","tel"],e.default=f,e.sanitize=l},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){t.setAttribute(e,!("true"===t.getAttribute(e)))}Object.defineProperty(e,"__esModule",{value:!0});var l="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},a=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),s=n(25),u=r(s),c=n(106),f=r(c),h=0,p=function(){function t(e){var n=this;o(this,t),this.select=e,this.container=document.createElement("span"),this.buildPicker(),this.select.style.display="none",this.select.parentNode.insertBefore(this.container,this.select),this.label.addEventListener("mousedown",function(){n.togglePicker()}),this.label.addEventListener("keydown",function(t){switch(t.keyCode){case u.default.keys.ENTER:n.togglePicker();break;case u.default.keys.ESCAPE:n.escape(),t.preventDefault()}}),this.select.addEventListener("change",this.update.bind(this))}return a(t,[{key:"togglePicker",value:function(){this.container.classList.toggle("ql-expanded"),i(this.label,"aria-expanded"),i(this.options,"aria-hidden")}},{key:"buildItem",value:function(t){var e=this,n=document.createElement("span");return n.tabIndex="0",n.setAttribute("role","button"),n.classList.add("ql-picker-item"),t.hasAttribute("value")&&n.setAttribute("data-value",t.getAttribute("value")),t.textContent&&n.setAttribute("data-label",t.textContent),n.addEventListener("click",function(){e.selectItem(n,!0)}),n.addEventListener("keydown",function(t){switch(t.keyCode){case u.default.keys.ENTER:e.selectItem(n,!0),t.preventDefault();break;case u.default.keys.ESCAPE:e.escape(),t.preventDefault()}}),n}},{key:"buildLabel",value:function(){var t=document.createElement("span");return t.classList.add("ql-picker-label"),t.innerHTML=f.default,t.tabIndex="0",t.setAttribute("role","button"),t.setAttribute("aria-expanded","false"),this.container.appendChild(t),t}},{key:"buildOptions",value:function(){var t=this,e=document.createElement("span");e.classList.add("ql-picker-options"),e.setAttribute("aria-hidden","true"),e.tabIndex="-1",e.id="ql-picker-options-"+h,h+=1,this.label.setAttribute("aria-controls",e.id),this.options=e,[].slice.call(this.select.options).forEach(function(n){var r=t.buildItem(n);e.appendChild(r),!0===n.selected&&t.selectItem(r)}),this.container.appendChild(e)}},{key:"buildPicker",value:function(){var t=this;[].slice.call(this.select.attributes).forEach(function(e){t.container.setAttribute(e.name,e.value)}),this.container.classList.add("ql-picker"),this.label=this.buildLabel(),this.buildOptions()}},{key:"escape",value:function(){var t=this;this.close(),setTimeout(function(){return t.label.focus()},1)}},{key:"close",value:function(){this.container.classList.remove("ql-expanded"),this.label.setAttribute("aria-expanded","false"),this.options.setAttribute("aria-hidden","true")}},{key:"selectItem",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=this.container.querySelector(".ql-selected");if(t!==n&&(null!=n&&n.classList.remove("ql-selected"),null!=t&&(t.classList.add("ql-selected"),this.select.selectedIndex=[].indexOf.call(t.parentNode.children,t),t.hasAttribute("data-value")?this.label.setAttribute("data-value",t.getAttribute("data-value")):this.label.removeAttribute("data-value"),t.hasAttribute("data-label")?this.label.setAttribute("data-label",t.getAttribute("data-label")):this.label.removeAttribute("data-label"),e))){if("function"==typeof Event)this.select.dispatchEvent(new Event("change"));else if("object"===("undefined"==typeof Event?"undefined":l(Event))){var r=document.createEvent("Event");r.initEvent("change",!0,!0),this.select.dispatchEvent(r)}this.close()}}},{key:"update",value:function(){var t=void 0;if(this.select.selectedIndex>-1){var e=this.container.querySelector(".ql-picker-options").children[this.select.selectedIndex];t=this.select.options[this.select.selectedIndex],this.selectItem(e)}else this.selectItem(null);var n=null!=t&&t!==this.select.querySelector("option[selected]");this.label.classList.toggle("ql-active",n)}}]),t}();e.default=p},function(t,e,n){"use strict";function r(t){var e=a.find(t);if(null==e)try{e=a.create(t)}catch(n){e=a.create(a.Scope.INLINE),[].slice.call(t.childNodes).forEach(function(t){e.domNode.appendChild(t)}),t.parentNode&&t.parentNode.replaceChild(e.domNode,t),e.attach()}return e}var o=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var i=n(47),l=n(27),a=n(1),s=function(t){function e(e){var n=t.call(this,e)||this;return n.build(),n}return o(e,t),e.prototype.appendChild=function(t){this.insertBefore(t)},e.prototype.attach=function(){t.prototype.attach.call(this),this.children.forEach(function(t){t.attach()})},e.prototype.build=function(){var t=this;this.children=new i.default,[].slice.call(this.domNode.childNodes).reverse().forEach(function(e){try{var n=r(e);t.insertBefore(n,t.children.head||void 0)}catch(t){if(t instanceof a.ParchmentError)return;throw t}})},e.prototype.deleteAt=function(t,e){if(0===t&&e===this.length())return this.remove();this.children.forEachAt(t,e,function(t,e,n){t.deleteAt(e,n)})},e.prototype.descendant=function(t,n){var r=this.children.find(n),o=r[0],i=r[1];return null==t.blotName&&t(o)||null!=t.blotName&&o instanceof t?[o,i]:o instanceof e?o.descendant(t,i):[null,-1]},e.prototype.descendants=function(t,n,r){void 0===n&&(n=0),void 0===r&&(r=Number.MAX_VALUE);var o=[],i=r;return this.children.forEachAt(n,r,function(n,r,l){(null==t.blotName&&t(n)||null!=t.blotName&&n instanceof t)&&o.push(n),n instanceof e&&(o=o.concat(n.descendants(t,r,i))),i-=l}),o},e.prototype.detach=function(){this.children.forEach(function(t){t.detach()}),t.prototype.detach.call(this)},e.prototype.formatAt=function(t,e,n,r){this.children.forEachAt(t,e,function(t,e,o){t.formatAt(e,o,n,r)})},e.prototype.insertAt=function(t,e,n){var r=this.children.find(t),o=r[0],i=r[1];if(o)o.insertAt(i,e,n);else{var l=null==n?a.create("text",e):a.create(e,n);this.appendChild(l)}},e.prototype.insertBefore=function(t,e){if(null!=this.statics.allowedChildren&&!this.statics.allowedChildren.some(function(e){return t instanceof e}))throw new a.ParchmentError("Cannot insert "+t.statics.blotName+" into "+this.statics.blotName);t.insertInto(this,e)},e.prototype.length=function(){return this.children.reduce(function(t,e){return t+e.length()},0)},e.prototype.moveChildren=function(t,e){this.children.forEach(function(n){t.insertBefore(n,e)})},e.prototype.optimize=function(e){if(t.prototype.optimize.call(this,e),0===this.children.length)if(null!=this.statics.defaultChild){var n=a.create(this.statics.defaultChild);this.appendChild(n),n.optimize(e)}else this.remove()},e.prototype.path=function(t,n){void 0===n&&(n=!1);var r=this.children.find(t,n),o=r[0],i=r[1],l=[[this,t]];return o instanceof e?l.concat(o.path(i,n)):(null!=o&&l.push([o,i]),l)},e.prototype.removeChild=function(t){this.children.remove(t)},e.prototype.replace=function(n){n instanceof e&&n.moveChildren(this),t.prototype.replace.call(this,n)},e.prototype.split=function(t,e){if(void 0===e&&(e=!1),!e){if(0===t)return this;if(t===this.length())return this.next}var n=this.clone();return this.parent.insertBefore(n,this.next),this.children.forEachAt(t,this.length(),function(t,r,o){t=t.split(r,e),n.appendChild(t)}),n},e.prototype.unwrap=function(){this.moveChildren(this.parent,this.next),this.remove()},e.prototype.update=function(t,e){var n=this,o=[],i=[];t.forEach(function(t){t.target===n.domNode&&"childList"===t.type&&(o.push.apply(o,t.addedNodes),i.push.apply(i,t.removedNodes))}),i.forEach(function(t){if(!(null!=t.parentNode&&"IFRAME"!==t.tagName&&document.body.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_CONTAINED_BY)){var e=a.find(t);null!=e&&(null!=e.domNode.parentNode&&e.domNode.parentNode!==n.domNode||e.detach())}}),o.filter(function(t){return t.parentNode==n.domNode}).sort(function(t,e){return t===e?0:t.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_FOLLOWING?1:-1}).forEach(function(t){var e=null;null!=t.nextSibling&&(e=a.find(t.nextSibling));var o=r(t);o.next==e&&null!=o.next||(null!=o.parent&&o.parent.removeChild(n),n.insertBefore(o,e||void 0))})},e}(l.default);e.default=s},function(t,e,n){"use strict";var r=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var o=n(11),i=n(28),l=n(17),a=n(1),s=function(t){function e(e){var n=t.call(this,e)||this;return n.attributes=new i.default(n.domNode),n}return r(e,t),e.formats=function(t){return"string"==typeof this.tagName||(Array.isArray(this.tagName)?t.tagName.toLowerCase():void 0)},e.prototype.format=function(t,e){var n=a.query(t);n instanceof o.default?this.attributes.attribute(n,e):e&&(null==n||t===this.statics.blotName&&this.formats()[t]===e||this.replaceWith(t,e))},e.prototype.formats=function(){var t=this.attributes.values(),e=this.statics.formats(this.domNode);return null!=e&&(t[this.statics.blotName]=e),t},e.prototype.replaceWith=function(e,n){var r=t.prototype.replaceWith.call(this,e,n);return this.attributes.copy(r),r},e.prototype.update=function(e,n){var r=this;t.prototype.update.call(this,e,n),e.some(function(t){return t.target===r.domNode&&"attributes"===t.type})&&this.attributes.build()},e.prototype.wrap=function(n,r){var o=t.prototype.wrap.call(this,n,r);return o instanceof e&&o.statics.scope===this.statics.scope&&this.attributes.move(o),o},e}(l.default);e.default=s},function(t,e,n){"use strict";var r=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var o=n(27),i=n(1),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.value=function(t){return!0},e.prototype.index=function(t,e){return this.domNode===t||this.domNode.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_CONTAINED_BY?Math.min(e,1):-1},e.prototype.position=function(t,e){var n=[].indexOf.call(this.parent.domNode.childNodes,this.domNode);return t>0&&(n+=1),[this.parent.domNode,n]},e.prototype.value=function(){return t={},t[this.statics.blotName]=this.statics.value(this.domNode)||!0,t;var t},e.scope=i.Scope.INLINE_BLOT,e}(o.default);e.default=l},function(t,e,n){function r(t){this.ops=t,this.index=0,this.offset=0}var o=n(12),i=n(2),l={attributes:{compose:function(t,e,n){"object"!=typeof t&&(t={}),"object"!=typeof e&&(e={});var r=i(!0,{},e);n||(r=Object.keys(r).reduce(function(t,e){return null!=r[e]&&(t[e]=r[e]),t},{}));for(var o in t)void 0!==t[o]&&void 0===e[o]&&(r[o]=t[o]);return Object.keys(r).length>0?r:void 0},diff:function(t,e){"object"!=typeof t&&(t={}),"object"!=typeof e&&(e={});var n=Object.keys(t).concat(Object.keys(e)).reduce(function(n,r){return o(t[r],e[r])||(n[r]=void 0===e[r]?null:e[r]),n},{});return Object.keys(n).length>0?n:void 0},transform:function(t,e,n){if("object"!=typeof t)return e;if("object"==typeof e){if(!n)return e;var r=Object.keys(e).reduce(function(n,r){return void 0===t[r]&&(n[r]=e[r]),n},{});return Object.keys(r).length>0?r:void 0}}},iterator:function(t){return new r(t)},length:function(t){return"number"==typeof t.delete?t.delete:"number"==typeof t.retain?t.retain:"string"==typeof t.insert?t.insert.length:1}};r.prototype.hasNext=function(){return this.peekLength()<1/0},r.prototype.next=function(t){t||(t=1/0);var e=this.ops[this.index];if(e){var n=this.offset,r=l.length(e);if(t>=r-n?(t=r-n,this.index+=1,this.offset=0):this.offset+=t,"number"==typeof e.delete)return{delete:t};var o={};return e.attributes&&(o.attributes=e.attributes),"number"==typeof e.retain?o.retain=t:"string"==typeof e.insert?o.insert=e.insert.substr(n,t):o.insert=e.insert,o}return{retain:1/0}},r.prototype.peek=function(){return this.ops[this.index]},r.prototype.peekLength=function(){return this.ops[this.index]?l.length(this.ops[this.index])-this.offset:1/0},r.prototype.peekType=function(){return this.ops[this.index]?"number"==typeof this.ops[this.index].delete?"delete":"number"==typeof this.ops[this.index].retain?"retain":"insert":"retain"},t.exports=l},function(t,e){var n=function(){"use strict";function t(t,e){return null!=e&&t instanceof e}function e(n,r,o,i,c){function f(n,o){if(null===n)return null;if(0===o)return n;var y,v;if("object"!=typeof n)return n;if(t(n,a))y=new a;else if(t(n,s))y=new s;else if(t(n,u))y=new u(function(t,e){n.then(function(e){t(f(e,o-1))},function(t){e(f(t,o-1))})});else if(e.__isArray(n))y=[];else if(e.__isRegExp(n))y=new RegExp(n.source,l(n)),n.lastIndex&&(y.lastIndex=n.lastIndex);else if(e.__isDate(n))y=new Date(n.getTime());else{if(d&&Buffer.isBuffer(n))return y=new Buffer(n.length),n.copy(y),y;t(n,Error)?y=Object.create(n):void 0===i?(v=Object.getPrototypeOf(n),y=Object.create(v)):(y=Object.create(i),v=i)}if(r){var b=h.indexOf(n);if(-1!=b)return p[b];h.push(n),p.push(y)}t(n,a)&&n.forEach(function(t,e){var n=f(e,o-1),r=f(t,o-1);y.set(n,r)}),t(n,s)&&n.forEach(function(t){var e=f(t,o-1);y.add(e)});for(var g in n){var m;v&&(m=Object.getOwnPropertyDescriptor(v,g)),m&&null==m.set||(y[g]=f(n[g],o-1))}if(Object.getOwnPropertySymbols)for(var _=Object.getOwnPropertySymbols(n),g=0;g<_.length;g++){var O=_[g],w=Object.getOwnPropertyDescriptor(n,O);(!w||w.enumerable||c)&&(y[O]=f(n[O],o-1),w.enumerable||Object.defineProperty(y,O,{enumerable:!1}))}if(c)for(var x=Object.getOwnPropertyNames(n),g=0;g<x.length;g++){var k=x[g],w=Object.getOwnPropertyDescriptor(n,k);w&&w.enumerable||(y[k]=f(n[k],o-1),Object.defineProperty(y,k,{enumerable:!1}))}return y}"object"==typeof r&&(o=r.depth,i=r.prototype,c=r.includeNonEnumerable,r=r.circular);var h=[],p=[],d="undefined"!=typeof Buffer;return void 0===r&&(r=!0),void 0===o&&(o=1/0),f(n,o)}function n(t){return Object.prototype.toString.call(t)}function r(t){return"object"==typeof t&&"[object Date]"===n(t)}function o(t){return"object"==typeof t&&"[object Array]"===n(t)}function i(t){return"object"==typeof t&&"[object RegExp]"===n(t)}function l(t){var e="";return t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),e}var a;try{a=Map}catch(t){a=function(){}}var s;try{s=Set}catch(t){s=function(){}}var u;try{u=Promise}catch(t){u=function(){}}return e.clonePrototype=function(t){if(null===t)return null;var e=function(){};return e.prototype=t,new e},e.__objToStr=n,e.__isDate=r,e.__isArray=o,e.__isRegExp=i,e.__getRegExpFlags=l,e}();"object"==typeof t&&t.exports&&(t.exports=n)},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e<t.length;e++)n[e]=t[e];return n}return Array.from(t)}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function l(t,e){try{e.parentNode}catch(t){return!1}return e instanceof Text&&(e=e.parentNode),t.contains(e)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.Range=void 0;var a=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),s=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),u=n(0),c=r(u),f=n(21),h=r(f),p=n(12),d=r(p),y=n(9),v=r(y),b=n(10),g=r(b),m=(0,g.default)("quill:selection"),_=function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;i(this,t),this.index=e,this.length=n},O=function(){function t(e,n){var r=this;i(this,t),this.emitter=n,this.scroll=e,this.composing=!1,this.mouseDown=!1,this.root=this.scroll.domNode,this.cursor=c.default.create("cursor",this),this.lastRange=this.savedRange=new _(0,0),this.handleComposition(),this.handleDragging(),this.emitter.listenDOM("selectionchange",document,function(){r.mouseDown||setTimeout(r.update.bind(r,v.default.sources.USER),1)}),this.emitter.on(v.default.events.EDITOR_CHANGE,function(t,e){t===v.default.events.TEXT_CHANGE&&e.length()>0&&r.update(v.default.sources.SILENT)}),this.emitter.on(v.default.events.SCROLL_BEFORE_UPDATE,function(){if(r.hasFocus()){var t=r.getNativeRange();null!=t&&t.start.node!==r.cursor.textNode&&r.emitter.once(v.default.events.SCROLL_UPDATE,function(){try{r.setNativeRange(t.start.node,t.start.offset,t.end.node,t.end.offset)}catch(t){}})}}),this.emitter.on(v.default.events.SCROLL_OPTIMIZE,function(t,e){if(e.range){var n=e.range,o=n.startNode,i=n.startOffset,l=n.endNode,a=n.endOffset;r.setNativeRange(o,i,l,a)}}),this.update(v.default.sources.SILENT)}return s(t,[{key:"handleComposition",value:function(){var t=this;this.root.addEventListener("compositionstart",function(){t.composing=!0}),this.root.addEventListener("compositionend",function(){if(t.composing=!1,t.cursor.parent){var e=t.cursor.restore();if(!e)return;setTimeout(function(){t.setNativeRange(e.startNode,e.startOffset,e.endNode,e.endOffset)},1)}})}},{key:"handleDragging",value:function(){var t=this;this.emitter.listenDOM("mousedown",document.body,function(){t.mouseDown=!0}),this.emitter.listenDOM("mouseup",document.body,function(){t.mouseDown=!1,t.update(v.default.sources.USER)})}},{key:"focus",value:function(){this.hasFocus()||(this.root.focus(),this.setRange(this.savedRange))}},{key:"format",value:function(t,e){if(null==this.scroll.whitelist||this.scroll.whitelist[t]){this.scroll.update();var n=this.getNativeRange();if(null!=n&&n.native.collapsed&&!c.default.query(t,c.default.Scope.BLOCK)){if(n.start.node!==this.cursor.textNode){var r=c.default.find(n.start.node,!1);if(null==r)return;if(r instanceof c.default.Leaf){var o=r.split(n.start.offset);r.parent.insertBefore(this.cursor,o)}else r.insertBefore(this.cursor,n.start.node);this.cursor.attach()}this.cursor.format(t,e),this.scroll.optimize(),this.setNativeRange(this.cursor.textNode,this.cursor.textNode.data.length),this.update()}}}},{key:"getBounds",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=this.scroll.length();t=Math.min(t,n-1),e=Math.min(t+e,n-1)-t;var r=void 0,o=this.scroll.leaf(t),i=a(o,2),l=i[0],s=i[1];if(null==l)return null;var u=l.position(s,!0),c=a(u,2);r=c[0],s=c[1];var f=document.createRange();if(e>0){f.setStart(r,s);var h=this.scroll.leaf(t+e),p=a(h,2);if(l=p[0],s=p[1],null==l)return null;var d=l.position(s,!0),y=a(d,2);return r=y[0],s=y[1],f.setEnd(r,s),f.getBoundingClientRect()}var v="left",b=void 0;return r instanceof Text?(s<r.data.length?(f.setStart(r,s),f.setEnd(r,s+1)):(f.setStart(r,s-1),f.setEnd(r,s),v="right"),b=f.getBoundingClientRect()):(b=l.domNode.getBoundingClientRect(),s>0&&(v="right")),{bottom:b.top+b.height,height:b.height,left:b[v],right:b[v],top:b.top,width:0}}},{key:"getNativeRange",value:function(){var t=document.getSelection();if(null==t||t.rangeCount<=0)return null;var e=t.getRangeAt(0);if(null==e)return null;var n=this.normalizeNative(e);return m.info("getNativeRange",n),n}},{key:"getRange",value:function(){var t=this.getNativeRange();return null==t?[null,null]:[this.normalizedToRange(t),t]}},{key:"hasFocus",value:function(){return document.activeElement===this.root}},{key:"normalizedToRange",value:function(t){var e=this,n=[[t.start.node,t.start.offset]];t.native.collapsed||n.push([t.end.node,t.end.offset]);var r=n.map(function(t){var n=a(t,2),r=n[0],o=n[1],i=c.default.find(r,!0),l=i.offset(e.scroll);return 0===o?l:i instanceof c.default.Container?l+i.length():l+i.index(r,o)}),i=Math.min(Math.max.apply(Math,o(r)),this.scroll.length()-1),l=Math.min.apply(Math,[i].concat(o(r)));return new _(l,i-l)}},{key:"normalizeNative",value:function(t){if(!l(this.root,t.startContainer)||!t.collapsed&&!l(this.root,t.endContainer))return null;var e={start:{node:t.startContainer,offset:t.startOffset},end:{node:t.endContainer,offset:t.endOffset},native:t};return[e.start,e.end].forEach(function(t){for(var e=t.node,n=t.offset;!(e instanceof Text)&&e.childNodes.length>0;)if(e.childNodes.length>n)e=e.childNodes[n],n=0;else{if(e.childNodes.length!==n)break;e=e.lastChild,n=e instanceof Text?e.data.length:e.childNodes.length+1}t.node=e,t.offset=n}),e}},{key:"rangeToNative",value:function(t){var e=this,n=t.collapsed?[t.index]:[t.index,t.index+t.length],r=[],o=this.scroll.length();return n.forEach(function(t,n){t=Math.min(o-1,t);var i=void 0,l=e.scroll.leaf(t),s=a(l,2),u=s[0],c=s[1],f=u.position(c,0!==n),h=a(f,2);i=h[0],c=h[1],r.push(i,c)}),r.length<2&&(r=r.concat(r)),r}},{key:"scrollIntoView",value:function(t){var e=this.lastRange;if(null!=e){var n=this.getBounds(e.index,e.length);if(null!=n){var r=this.scroll.length()-1,o=this.scroll.line(Math.min(e.index,r)),i=a(o,1),l=i[0],s=l;if(e.length>0){var u=this.scroll.line(Math.min(e.index+e.length,r));s=a(u,1)[0]}if(null!=l&&null!=s){var c=t.getBoundingClientRect();n.top<c.top?t.scrollTop-=c.top-n.top:n.bottom>c.bottom&&(t.scrollTop+=n.bottom-c.bottom)}}}}},{key:"setNativeRange",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:e,o=arguments.length>4&&void 0!==arguments[4]&&arguments[4];if(m.info("setNativeRange",t,e,n,r),null==t||null!=this.root.parentNode&&null!=t.parentNode&&null!=n.parentNode){var i=document.getSelection();if(null!=i)if(null!=t){this.hasFocus()||this.root.focus();var l=(this.getNativeRange()||{}).native;if(null==l||o||t!==l.startContainer||e!==l.startOffset||n!==l.endContainer||r!==l.endOffset){"BR"==t.tagName&&(e=[].indexOf.call(t.parentNode.childNodes,t),t=t.parentNode),"BR"==n.tagName&&(r=[].indexOf.call(n.parentNode.childNodes,n),n=n.parentNode);var a=document.createRange();a.setStart(t,e),a.setEnd(n,r),i.removeAllRanges(),i.addRange(a)}}else i.removeAllRanges(),this.root.blur(),document.body.focus()}}},{key:"setRange",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:v.default.sources.API;if("string"==typeof e&&(n=e,e=!1),m.info("setRange",t),null!=t){var r=this.rangeToNative(t);this.setNativeRange.apply(this,o(r).concat([e]))}else this.setNativeRange(null);this.update(n)}},{key:"update",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:v.default.sources.USER,e=this.lastRange,n=this.getRange(),r=a(n,2),o=r[0],i=r[1];if(this.lastRange=o,null!=this.lastRange&&(this.savedRange=this.lastRange),!(0,d.default)(e,this.lastRange)){var l;!this.composing&&null!=i&&i.native.collapsed&&i.start.node!==this.cursor.textNode&&this.cursor.restore();var s=[v.default.events.SELECTION_CHANGE,(0,h.default)(this.lastRange),(0,h.default)(e),t];if((l=this.emitter).emit.apply(l,[v.default.events.EDITOR_CHANGE].concat(s)),t!==v.default.sources.SILENT){var u;(u=this.emitter).emit.apply(u,s)}}}}]),t}();e.Range=_,e.default=O},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var a=n(0),s=r(a),u=n(3),c=r(u),f=function(t){function e(){return o(this,e),i(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return l(e,t),e}(s.default.Container);f.allowedChildren=[c.default,u.BlockEmbed,f],e.default=f},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0}),e.ColorStyle=e.ColorClass=e.ColorAttributor=void 0;var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(0),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,[{key:"value",value:function(t){var n=a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"value",this).call(this,t);return n.startsWith("rgb(")?(n=n.replace(/^[^\d]+/,"").replace(/[^\d]+$/,""),"#"+n.split(",").map(function(t){return("00"+parseInt(t).toString(16)).slice(-2)}).join("")):n}}]),e}(u.default.Attributor.Style),f=new u.default.Attributor.Class("color","ql-color",{scope:u.default.Scope.INLINE}),h=new c("color","color",{scope:u.default.Scope.INLINE});e.ColorAttributor=c,e.ColorClass=f,e.ColorStyle=h},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function l(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function s(t,e){var n,r=t===D.keys.LEFT?"prefix":"suffix";return n={key:t,shiftKey:e,altKey:null},o(n,r,/^$/),o(n,"handler",function(n){var r=n.index;t===D.keys.RIGHT&&(r+=n.length+1);var o=this.quill.getLeaf(r);return!(b(o,1)[0]instanceof T.default.Embed)||(t===D.keys.LEFT?e?this.quill.setSelection(n.index-1,n.length+1,S.default.sources.USER):this.quill.setSelection(n.index-1,S.default.sources.USER):e?this.quill.setSelection(n.index,n.length+1,S.default.sources.USER):this.quill.setSelection(n.index+n.length+1,S.default.sources.USER),!1)}),n}function u(t,e){if(!(0===t.index||this.quill.getLength()<=1)){var n=this.quill.getLine(t.index),r=b(n,1),o=r[0],i={};if(0===e.offset){var l=this.quill.getLine(t.index-1),a=b(l,1),s=a[0];if(null!=s&&s.length()>1){var u=o.formats(),c=this.quill.getFormat(t.index-1,1);i=A.default.attributes.diff(u,c)||{}}}var f=/[\uD800-\uDBFF][\uDC00-\uDFFF]$/.test(e.prefix)?2:1;this.quill.deleteText(t.index-f,f,S.default.sources.USER),Object.keys(i).length>0&&this.quill.formatLine(t.index-f,f,i,S.default.sources.USER),this.quill.focus()}}function c(t,e){var n=/^[\uD800-\uDBFF][\uDC00-\uDFFF]/.test(e.suffix)?2:1;if(!(t.index>=this.quill.getLength()-n)){var r={},o=0,i=this.quill.getLine(t.index),l=b(i,1),a=l[0];if(e.offset>=a.length()-1){var s=this.quill.getLine(t.index+1),u=b(s,1),c=u[0];if(c){var f=a.formats(),h=this.quill.getFormat(t.index,1);r=A.default.attributes.diff(f,h)||{},o=c.length()}}this.quill.deleteText(t.index,n,S.default.sources.USER),Object.keys(r).length>0&&this.quill.formatLine(t.index+o-1,n,r,S.default.sources.USER)}}function f(t){var e=this.quill.getLines(t),n={};if(e.length>1){var r=e[0].formats(),o=e[e.length-1].formats();n=A.default.attributes.diff(o,r)||{}}this.quill.deleteText(t,S.default.sources.USER),Object.keys(n).length>0&&this.quill.formatLine(t.index,1,n,S.default.sources.USER),this.quill.setSelection(t.index,S.default.sources.SILENT),this.quill.focus()}function h(t,e){var n=this;t.length>0&&this.quill.scroll.deleteAt(t.index,t.length);var r=Object.keys(e.format).reduce(function(t,n){return T.default.query(n,T.default.Scope.BLOCK)&&!Array.isArray(e.format[n])&&(t[n]=e.format[n]),t},{});this.quill.insertText(t.index,"\n",r,S.default.sources.USER),this.quill.setSelection(t.index+1,S.default.sources.SILENT),this.quill.focus(),Object.keys(e.format).forEach(function(t){null==r[t]&&(Array.isArray(e.format[t])||"link"!==t&&n.quill.format(t,e.format[t],S.default.sources.USER))})}function p(t){return{key:D.keys.TAB,shiftKey:!t,format:{"code-block":!0},handler:function(e){var n=T.default.query("code-block"),r=e.index,o=e.length,i=this.quill.scroll.descendant(n,r),l=b(i,2),a=l[0],s=l[1];if(null!=a){var u=this.quill.getIndex(a),c=a.newlineIndex(s,!0)+1,f=a.newlineIndex(u+s+o),h=a.domNode.textContent.slice(c,f).split("\n");s=0,h.forEach(function(e,i){t?(a.insertAt(c+s,n.TAB),s+=n.TAB.length,0===i?r+=n.TAB.length:o+=n.TAB.length):e.startsWith(n.TAB)&&(a.deleteAt(c+s,n.TAB.length),s-=n.TAB.length,0===i?r-=n.TAB.length:o-=n.TAB.length),s+=e.length+1}),this.quill.update(S.default.sources.USER),this.quill.setSelection(r,o,S.default.sources.SILENT)}}}}function d(t){return{key:t[0].toUpperCase(),shortKey:!0,handler:function(e,n){this.quill.format(t,!n.format[t],S.default.sources.USER)}}}function y(t){if("string"==typeof t||"number"==typeof t)return y({key:t});if("object"===(void 0===t?"undefined":v(t))&&(t=(0,_.default)(t,!1)),"string"==typeof t.key)if(null!=D.keys[t.key.toUpperCase()])t.key=D.keys[t.key.toUpperCase()];else{if(1!==t.key.length)return null;t.key=t.key.toUpperCase().charCodeAt(0)}return t.shortKey&&(t[B]=t.shortKey,delete t.shortKey),t}Object.defineProperty(e,"__esModule",{value:!0}),e.SHORTKEY=e.default=void 0;var v="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},b=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),g=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),m=n(21),_=r(m),O=n(12),w=r(O),x=n(2),k=r(x),E=n(4),N=r(E),j=n(20),A=r(j),q=n(0),T=r(q),P=n(6),S=r(P),C=n(10),L=r(C),M=n(7),R=r(M),I=(0,L.default)("quill:keyboard"),B=/Mac/i.test(navigator.platform)?"metaKey":"ctrlKey",D=function(t){function e(t,n){i(this,e);var r=l(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.bindings={},Object.keys(r.options.bindings).forEach(function(e){("list autofill"!==e||null==t.scroll.whitelist||t.scroll.whitelist.list)&&r.options.bindings[e]&&r.addBinding(r.options.bindings[e])}),r.addBinding({key:e.keys.ENTER,shiftKey:null},h),r.addBinding({key:e.keys.ENTER,metaKey:null,ctrlKey:null,altKey:null},function(){}),/Firefox/i.test(navigator.userAgent)?(r.addBinding({key:e.keys.BACKSPACE},{collapsed:!0},u),r.addBinding({key:e.keys.DELETE},{collapsed:!0},c)):(r.addBinding({key:e.keys.BACKSPACE},{collapsed:!0,prefix:/^.?$/},u),r.addBinding({key:e.keys.DELETE},{collapsed:!0,suffix:/^.?$/},c)),r.addBinding({key:e.keys.BACKSPACE},{collapsed:!1},f),r.addBinding({key:e.keys.DELETE},{collapsed:!1},f),r.addBinding({key:e.keys.BACKSPACE,altKey:null,ctrlKey:null,metaKey:null,shiftKey:null},{collapsed:!0,offset:0},u),r.listen(),r}return a(e,t),g(e,null,[{key:"match",value:function(t,e){return e=y(e),!["altKey","ctrlKey","metaKey","shiftKey"].some(function(n){return!!e[n]!==t[n]&&null!==e[n]})&&e.key===(t.which||t.keyCode)}}]),g(e,[{key:"addBinding",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=y(t);if(null==r||null==r.key)return I.warn("Attempted to add invalid keyboard binding",r);"function"==typeof e&&(e={handler:e}),"function"==typeof n&&(n={handler:n}),r=(0,k.default)(r,e,n),this.bindings[r.key]=this.bindings[r.key]||[],this.bindings[r.key].push(r)}},{key:"listen",value:function(){var t=this;this.quill.root.addEventListener("keydown",function(n){if(!n.defaultPrevented){var r=n.which||n.keyCode,o=(t.bindings[r]||[]).filter(function(t){return e.match(n,t)});if(0!==o.length){var i=t.quill.getSelection();if(null!=i&&t.quill.hasFocus()){var l=t.quill.getLine(i.index),a=b(l,2),s=a[0],u=a[1],c=t.quill.getLeaf(i.index),f=b(c,2),h=f[0],p=f[1],d=0===i.length?[h,p]:t.quill.getLeaf(i.index+i.length),y=b(d,2),g=y[0],m=y[1],_=h instanceof T.default.Text?h.value().slice(0,p):"",O=g instanceof T.default.Text?g.value().slice(m):"",x={collapsed:0===i.length,empty:0===i.length&&s.length()<=1,format:t.quill.getFormat(i),offset:u,prefix:_,suffix:O};o.some(function(e){if(null!=e.collapsed&&e.collapsed!==x.collapsed)return!1;if(null!=e.empty&&e.empty!==x.empty)return!1;if(null!=e.offset&&e.offset!==x.offset)return!1;if(Array.isArray(e.format)){if(e.format.every(function(t){return null==x.format[t]}))return!1}else if("object"===v(e.format)&&!Object.keys(e.format).every(function(t){return!0===e.format[t]?null!=x.format[t]:!1===e.format[t]?null==x.format[t]:(0,w.default)(e.format[t],x.format[t])}))return!1;return!(null!=e.prefix&&!e.prefix.test(x.prefix))&&(!(null!=e.suffix&&!e.suffix.test(x.suffix))&&!0!==e.handler.call(t,i,x))})&&n.preventDefault()}}}})}}]),e}(R.default);D.keys={BACKSPACE:8,TAB:9,ENTER:13,ESCAPE:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46},D.DEFAULTS={bindings:{bold:d("bold"),italic:d("italic"),underline:d("underline"),indent:{key:D.keys.TAB,format:["blockquote","indent","list"],handler:function(t,e){if(e.collapsed&&0!==e.offset)return!0;this.quill.format("indent","+1",S.default.sources.USER)}},outdent:{key:D.keys.TAB,shiftKey:!0,format:["blockquote","indent","list"],handler:function(t,e){if(e.collapsed&&0!==e.offset)return!0;this.quill.format("indent","-1",S.default.sources.USER)}},"outdent backspace":{key:D.keys.BACKSPACE,collapsed:!0,shiftKey:null,metaKey:null,ctrlKey:null,altKey:null,format:["indent","list"],offset:0,handler:function(t,e){null!=e.format.indent?this.quill.format("indent","-1",S.default.sources.USER):null!=e.format.list&&this.quill.format("list",!1,S.default.sources.USER)}},"indent code-block":p(!0),"outdent code-block":p(!1),"remove tab":{key:D.keys.TAB,shiftKey:!0,collapsed:!0,prefix:/\t$/,handler:function(t){this.quill.deleteText(t.index-1,1,S.default.sources.USER)}},tab:{key:D.keys.TAB,handler:function(t){this.quill.history.cutoff();var e=(new N.default).retain(t.index).delete(t.length).insert("\t");this.quill.updateContents(e,S.default.sources.USER),this.quill.history.cutoff(),this.quill.setSelection(t.index+1,S.default.sources.SILENT)}},"list empty enter":{key:D.keys.ENTER,collapsed:!0,format:["list"],empty:!0,handler:function(t,e){this.quill.format("list",!1,S.default.sources.USER),e.format.indent&&this.quill.format("indent",!1,S.default.sources.USER)}},"checklist enter":{key:D.keys.ENTER,collapsed:!0,format:{list:"checked"},handler:function(t){var e=this.quill.getLine(t.index),n=b(e,2),r=n[0],o=n[1],i=(0,k.default)({},r.formats(),{list:"checked"}),l=(new N.default).retain(t.index).insert("\n",i).retain(r.length()-o-1).retain(1,{list:"unchecked"});this.quill.updateContents(l,S.default.sources.USER),this.quill.setSelection(t.index+1,S.default.sources.SILENT),this.quill.scrollIntoView()}},"header enter":{key:D.keys.ENTER,collapsed:!0,format:["header"],suffix:/^$/,handler:function(t,e){var n=this.quill.getLine(t.index),r=b(n,2),o=r[0],i=r[1],l=(new N.default).retain(t.index).insert("\n",e.format).retain(o.length()-i-1).retain(1,{header:null});this.quill.updateContents(l,S.default.sources.USER),this.quill.setSelection(t.index+1,S.default.sources.SILENT),this.quill.scrollIntoView()}},"list autofill":{key:" ",collapsed:!0,format:{list:!1},prefix:/^\s*?(\d+\.|-|\*|\[ ?\]|\[x\])$/,handler:function(t,e){var n=e.prefix.length,r=this.quill.getLine(t.index),o=b(r,2),i=o[0],l=o[1];if(l>n)return!0;var a=void 0;switch(e.prefix.trim()){case"[]":case"[ ]":a="unchecked";break;case"[x]":a="checked";break;case"-":case"*":a="bullet";break;default:a="ordered"}this.quill.insertText(t.index," ",S.default.sources.USER),this.quill.history.cutoff();var s=(new N.default).retain(t.index-l).delete(n+1).retain(i.length()-2-l).retain(1,{list:a});this.quill.updateContents(s,S.default.sources.USER),this.quill.history.cutoff(),this.quill.setSelection(t.index-n,S.default.sources.SILENT)}},"code exit":{key:D.keys.ENTER,collapsed:!0,format:["code-block"],prefix:/\n\n$/,suffix:/^\s+$/,handler:function(t){var e=this.quill.getLine(t.index),n=b(e,2),r=n[0],o=n[1],i=(new N.default).retain(t.index+r.length()-o-2).retain(1,{"code-block":null}).delete(1);this.quill.updateContents(i,S.default.sources.USER)}},"embed left":s(D.keys.LEFT,!1),"embed left shift":s(D.keys.LEFT,!0),"embed right":s(D.keys.RIGHT,!1),"embed right shift":s(D.keys.RIGHT,!0)}},e.default=D,e.SHORTKEY=B},function(t,e,n){"use strict";t.exports={align:{"":n(75),center:n(76),right:n(77),justify:n(78)},background:n(79),blockquote:n(80),bold:n(81),clean:n(82),code:n(40),"code-block":n(40),color:n(83),direction:{"":n(84),rtl:n(85)},float:{center:n(86),full:n(87),left:n(88),right:n(89)},formula:n(90),header:{1:n(91),2:n(92)},italic:n(93),image:n(94),indent:{"+1":n(95),"-1":n(96)},link:n(97),list:{ordered:n(98),bullet:n(99),check:n(100)},script:{sub:n(101),super:n(102)},strike:n(103),underline:n(104),video:n(105)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1),o=function(){function t(t){this.domNode=t,this.domNode[r.DATA_KEY]={blot:this}}return Object.defineProperty(t.prototype,"statics",{get:function(){return this.constructor},enumerable:!0,configurable:!0}),t.create=function(t){if(null==this.tagName)throw new r.ParchmentError("Blot definition missing tagName");var e;return Array.isArray(this.tagName)?("string"==typeof t&&(t=t.toUpperCase(),parseInt(t).toString()===t&&(t=parseInt(t))),e="number"==typeof t?document.createElement(this.tagName[t-1]):this.tagName.indexOf(t)>-1?document.createElement(t):document.createElement(this.tagName[0])):e=document.createElement(this.tagName),this.className&&e.classList.add(this.className),e},t.prototype.attach=function(){null!=this.parent&&(this.scroll=this.parent.scroll)},t.prototype.clone=function(){var t=this.domNode.cloneNode(!1);return r.create(t)},t.prototype.detach=function(){null!=this.parent&&this.parent.removeChild(this),delete this.domNode[r.DATA_KEY]},t.prototype.deleteAt=function(t,e){this.isolate(t,e).remove()},t.prototype.formatAt=function(t,e,n,o){var i=this.isolate(t,e);if(null!=r.query(n,r.Scope.BLOT)&&o)i.wrap(n,o);else if(null!=r.query(n,r.Scope.ATTRIBUTE)){var l=r.create(this.statics.scope);i.wrap(l),l.format(n,o)}},t.prototype.insertAt=function(t,e,n){var o=null==n?r.create("text",e):r.create(e,n),i=this.split(t);this.parent.insertBefore(o,i)},t.prototype.insertInto=function(t,e){void 0===e&&(e=null),null!=this.parent&&this.parent.children.remove(this);var n=null;t.children.insertBefore(this,e),null!=e&&(n=e.domNode),this.domNode.parentNode==t.domNode&&this.domNode.nextSibling==n||t.domNode.insertBefore(this.domNode,n),this.parent=t,this.attach()},t.prototype.isolate=function(t,e){var n=this.split(t);return n.split(e),n},t.prototype.length=function(){return 1},t.prototype.offset=function(t){return void 0===t&&(t=this.parent),null==this.parent||this==t?0:this.parent.children.offset(this)+this.parent.offset(t)},t.prototype.optimize=function(t){null!=this.domNode[r.DATA_KEY]&&delete this.domNode[r.DATA_KEY].mutations},t.prototype.remove=function(){null!=this.domNode.parentNode&&this.domNode.parentNode.removeChild(this.domNode),this.detach()},t.prototype.replace=function(t){null!=t.parent&&(t.parent.insertBefore(this,t.next),t.remove())},t.prototype.replaceWith=function(t,e){var n="string"==typeof t?r.create(t,e):t;return n.replace(this),n},t.prototype.split=function(t,e){return 0===t?this:this.next},t.prototype.update=function(t,e){},t.prototype.wrap=function(t,e){var n="string"==typeof t?r.create(t,e):t;return null!=this.parent&&this.parent.insertBefore(n,this.next),n.appendChild(this),n},t.blotName="abstract",t}();e.default=o},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(11),o=n(29),i=n(30),l=n(1),a=function(){function t(t){this.attributes={},this.domNode=t,this.build()}return t.prototype.attribute=function(t,e){e?t.add(this.domNode,e)&&(null!=t.value(this.domNode)?this.attributes[t.attrName]=t:delete this.attributes[t.attrName]):(t.remove(this.domNode),delete this.attributes[t.attrName])},t.prototype.build=function(){var t=this;this.attributes={};var e=r.default.keys(this.domNode),n=o.default.keys(this.domNode),a=i.default.keys(this.domNode);e.concat(n).concat(a).forEach(function(e){var n=l.query(e,l.Scope.ATTRIBUTE);n instanceof r.default&&(t.attributes[n.attrName]=n)})},t.prototype.copy=function(t){var e=this;Object.keys(this.attributes).forEach(function(n){var r=e.attributes[n].value(e.domNode);t.format(n,r)})},t.prototype.move=function(t){var e=this;this.copy(t),Object.keys(this.attributes).forEach(function(t){e.attributes[t].remove(e.domNode)}),this.attributes={}},t.prototype.values=function(){var t=this;return Object.keys(this.attributes).reduce(function(e,n){return e[n]=t.attributes[n].value(t.domNode),e},{})},t}();e.default=a},function(t,e,n){"use strict";function r(t,e){return(t.getAttribute("class")||"").split(/\s+/).filter(function(t){return 0===t.indexOf(e+"-")})}var o=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var i=n(11),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return o(e,t),e.keys=function(t){return(t.getAttribute("class")||"").split(/\s+/).map(function(t){return t.split("-").slice(0,-1).join("-")})},e.prototype.add=function(t,e){return!!this.canAdd(t,e)&&(this.remove(t),t.classList.add(this.keyName+"-"+e),!0)},e.prototype.remove=function(t){r(t,this.keyName).forEach(function(e){t.classList.remove(e)}),0===t.classList.length&&t.removeAttribute("class")},e.prototype.value=function(t){var e=r(t,this.keyName)[0]||"",n=e.slice(this.keyName.length+1);return this.canAdd(t,n)?n:""},e}(i.default);e.default=l},function(t,e,n){"use strict";function r(t){var e=t.split("-"),n=e.slice(1).map(function(t){return t[0].toUpperCase()+t.slice(1)}).join("");return e[0]+n}var o=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var i=n(11),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return o(e,t),e.keys=function(t){return(t.getAttribute("style")||"").split(";").map(function(t){return t.split(":")[0].trim()})},e.prototype.add=function(t,e){return!!this.canAdd(t,e)&&(t.style[r(this.keyName)]=e,!0)},e.prototype.remove=function(t){t.style[r(this.keyName)]="",t.getAttribute("style")||t.removeAttribute("style")},e.prototype.value=function(t){var e=t.style[r(this.keyName)];return this.canAdd(t,e)?e:""},e}(i.default);e.default=l},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var a=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),s=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},u=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),c=n(0),f=r(c),h=n(8),p=r(h),d=function(t){function e(t,n){o(this,e);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return r.selection=n,r.textNode=document.createTextNode(e.CONTENTS),r.domNode.appendChild(r.textNode),r._length=0,r}return l(e,t),u(e,null,[{key:"value",value:function(){}}]),u(e,[{key:"detach",value:function(){null!=this.parent&&this.parent.removeChild(this)}},{key:"format",value:function(t,n){if(0!==this._length)return s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"format",this).call(this,t,n);for(var r=this,o=0;null!=r&&r.statics.scope!==f.default.Scope.BLOCK_BLOT;)o+=r.offset(r.parent),r=r.parent;null!=r&&(this._length=e.CONTENTS.length,r.optimize(),r.formatAt(o,e.CONTENTS.length,t,n),this._length=0)}},{key:"index",value:function(t,n){return t===this.textNode?0:s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"index",this).call(this,t,n)}},{key:"length",value:function(){return this._length}},{key:"position",value:function(){return[this.textNode,this.textNode.data.length]}},{key:"remove",value:function(){s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"remove",this).call(this),this.parent=null}},{key:"restore",value:function(){if(!this.selection.composing&&null!=this.parent){var t=this.textNode,n=this.selection.getNativeRange(),r=void 0,o=void 0,i=void 0;if(null!=n&&n.start.node===t&&n.end.node===t){var l=[t,n.start.offset,n.end.offset];r=l[0],o=l[1],i=l[2]}for(;null!=this.domNode.lastChild&&this.domNode.lastChild!==this.textNode;)this.domNode.parentNode.insertBefore(this.domNode.lastChild,this.domNode);if(this.textNode.data!==e.CONTENTS){var s=this.textNode.data.split(e.CONTENTS).join("");this.next instanceof p.default?(r=this.next.domNode,this.next.insertAt(0,s),this.textNode.data=e.CONTENTS):(this.textNode.data=s,this.parent.insertBefore(f.default.create(this.textNode),this),this.textNode=document.createTextNode(e.CONTENTS),this.domNode.appendChild(this.textNode))}if(this.remove(),null!=o){var u=[o,i].map(function(t){return Math.max(0,Math.min(r.data.length,t-1))}),c=a(u,2);return o=c[0],i=c[1],{startNode:r,startOffset:o,endNode:r,endOffset:i}}}}},{key:"update",value:function(t,e){var n=this;if(t.some(function(t){return"characterData"===t.type&&t.target===n.textNode})){var r=this.restore();r&&(e.range=r)}}},{key:"value",value:function(){return""}}]),e}(f.default.Embed);d.blotName="cursor",d.className="ql-cursor",d.tagName="span",d.CONTENTS="\ufeff",e.default=d},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});var o=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),i=function(){function t(e,n){r(this,t),this.quill=e,this.options=n,this.modules={}}return o(t,[{key:"init",value:function(){var t=this;Object.keys(this.options.modules).forEach(function(e){null==t.modules[e]&&t.addModule(e)})}},{key:"addModule",value:function(t){var e=this.quill.constructor.import("modules/"+t);return this.modules[t]=new e(this.quill,this.options.modules[t]||{}),this.modules[t]}}]),t}();i.DEFAULTS={modules:{}},i.themes={default:i},e.default=i},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var a=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),s=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},u=n(0),c=r(u),f=n(8),h=r(f),p="\ufeff",d=function(t){function e(t){o(this,e);var n=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return n.contentNode=document.createElement("span"),n.contentNode.setAttribute("contenteditable",!1),[].slice.call(n.domNode.childNodes).forEach(function(t){n.contentNode.appendChild(t)}),n.leftGuard=document.createTextNode(p),n.rightGuard=document.createTextNode(p),n.domNode.appendChild(n.leftGuard),n.domNode.appendChild(n.contentNode),n.domNode.appendChild(n.rightGuard),n}return l(e,t),a(e,[{key:"index",value:function(t,n){return t===this.leftGuard?0:t===this.rightGuard?1:s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"index",this).call(this,t,n)}},{key:"restore",value:function(t){var e=void 0,n=void 0,r=t.data.split(p).join("");if(t===this.leftGuard)if(this.prev instanceof h.default){var o=this.prev.length();this.prev.insertAt(o,r),e={startNode:this.prev.domNode,startOffset:o+r.length}}else n=document.createTextNode(r),this.parent.insertBefore(c.default.create(n),this),e={startNode:n,startOffset:r.length};else t===this.rightGuard&&(this.next instanceof h.default?(this.next.insertAt(0,r),e={startNode:this.next.domNode,startOffset:r.length}):(n=document.createTextNode(r),this.parent.insertBefore(c.default.create(n),this.next),e={startNode:n,startOffset:r.length}));return t.data=p,e}},{key:"update",value:function(t,e){var n=this;t.forEach(function(t){if("characterData"===t.type&&(t.target===n.leftGuard||t.target===n.rightGuard)){var r=n.restore(t.target);r&&(e.range=r)}})}}]),e}(c.default.Embed);e.default=d},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AlignStyle=e.AlignClass=e.AlignAttribute=void 0;var r=n(0),o=function(t){return t&&t.__esModule?t:{default:t}}(r),i={scope:o.default.Scope.BLOCK,whitelist:["right","center","justify"]},l=new o.default.Attributor.Attribute("align","align",i),a=new o.default.Attributor.Class("align","ql-align",i),s=new o.default.Attributor.Style("align","text-align",i);e.AlignAttribute=l,e.AlignClass=a,e.AlignStyle=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BackgroundStyle=e.BackgroundClass=void 0;var r=n(0),o=function(t){return t&&t.__esModule?t:{default:t}}(r),i=n(24),l=new o.default.Attributor.Class("background","ql-bg",{scope:o.default.Scope.INLINE}),a=new i.ColorAttributor("background","background-color",{scope:o.default.Scope.INLINE});e.BackgroundClass=l,e.BackgroundStyle=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DirectionStyle=e.DirectionClass=e.DirectionAttribute=void 0;var r=n(0),o=function(t){return t&&t.__esModule?t:{default:t}}(r),i={scope:o.default.Scope.BLOCK,whitelist:["rtl"]},l=new o.default.Attributor.Attribute("direction","dir",i),a=new o.default.Attributor.Class("direction","ql-direction",i),s=new o.default.Attributor.Style("direction","direction",i);e.DirectionAttribute=l,e.DirectionClass=a,e.DirectionStyle=s},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0}),e.FontClass=e.FontStyle=void 0;var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(0),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c={scope:u.default.Scope.INLINE,whitelist:["serif","monospace"]},f=new u.default.Attributor.Class("font","ql-font",c),h=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,[{key:"value",value:function(t){return a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"value",this).call(this,t).replace(/["']/g,"")}}]),e}(u.default.Attributor.Style),p=new h("font","font-family",c);e.FontStyle=p,e.FontClass=f},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.SizeStyle=e.SizeClass=void 0;var r=n(0),o=function(t){return t&&t.__esModule?t:{default:t}}(r),i=new o.default.Attributor.Class("size","ql-size",{scope:o.default.Scope.INLINE,whitelist:["small","large","huge"]}),l=new o.default.Attributor.Style("size","font-size",{scope:o.default.Scope.INLINE,whitelist:["10px","18px","32px"]});e.SizeClass=i,e.SizeStyle=l},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(5),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,[{key:"optimize",value:function(t){a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"optimize",this).call(this,t),this.domNode.tagName!==this.statics.tagName[0]&&this.replaceWith(this.statics.blotName)}}],[{key:"create",value:function(){return a(e.__proto__||Object.getPrototypeOf(e),"create",this).call(this)}},{key:"formats",value:function(){return!0}}]),e}(u.default);c.blotName="bold",c.tagName=["STRONG","B"],e.default=c},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <polyline class="ql-even ql-stroke" points="5 7 3 9 5 11"></polyline> <polyline class="ql-even ql-stroke" points="13 7 15 9 13 11"></polyline> <line class=ql-stroke x1=10 x2=8 y1=5 y2=13></line> </svg>'},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(16),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c=function(t){function e(t,n){r(this,e);var i=o(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return i.label.innerHTML=n,i.container.classList.add("ql-color-picker"),[].slice.call(i.container.querySelectorAll(".ql-picker-item"),0,7).forEach(function(t){t.classList.add("ql-primary")}),i}return i(e,t),l(e,[{key:"buildItem",value:function(t){var n=a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"buildItem",this).call(this,t);return n.style.backgroundColor=t.getAttribute("value")||"",n}},{key:"selectItem",value:function(t,n){a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"selectItem",this).call(this,t,n);var r=this.label.querySelector(".ql-color-label"),o=t?t.getAttribute("data-value")||"":"";r&&("line"===r.tagName?r.style.stroke=o:r.style.fill=o)}}]),e}(u.default);e.default=c},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(16),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c=function(t){function e(t,n){r(this,e);var i=o(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return i.container.classList.add("ql-icon-picker"),[].forEach.call(i.container.querySelectorAll(".ql-picker-item"),function(t){t.innerHTML=n[t.getAttribute("data-value")||""]}),i.defaultItem=i.container.querySelector(".ql-selected"),i.selectItem(i.defaultItem),i}return i(e,t),l(e,[{key:"selectItem",value:function(t,n){a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"selectItem",this).call(this,t,n),t=t||this.defaultItem,this.label.innerHTML=t.innerHTML}}]),e}(u.default);e.default=c},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});var o=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),i=function(){function t(e,n){var o=this;r(this,t),this.quill=e,this.boundsContainer=n||document.body,this.root=e.addContainer("ql-tooltip"),this.root.innerHTML=this.constructor.TEMPLATE,this.quill.root===this.quill.scrollingContainer&&this.quill.root.addEventListener("scroll",function(){o.root.style.marginTop=-1*o.quill.root.scrollTop+"px"}),this.hide()}return o(t,[{key:"hide",value:function(){this.root.classList.add("ql-hidden")}},{key:"position",value:function(t){var e=t.left+t.width/2-this.root.offsetWidth/2,n=t.bottom+this.quill.root.scrollTop;this.root.style.left=e+"px",this.root.style.top=n+"px",this.root.classList.remove("ql-flip");var r=this.boundsContainer.getBoundingClientRect(),o=this.root.getBoundingClientRect(),i=0;if(o.right>r.right&&(i=r.right-o.right,this.root.style.left=e+i+"px"),o.left<r.left&&(i=r.left-o.left,this.root.style.left=e+i+"px"),o.bottom>r.bottom){var l=o.bottom-o.top,a=t.bottom-t.top+l;this.root.style.top=n-a+"px",this.root.classList.add("ql-flip")}return i}},{key:"show",value:function(){this.root.classList.remove("ql-editing"),this.root.classList.remove("ql-hidden")}}]),t}();e.default=i},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function a(t){var e=t.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtube\.com\/watch.*v=([a-zA-Z0-9_-]+)/)||t.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtu\.be\/([a-zA-Z0-9_-]+)/);return e?(e[1]||"https")+"://www.youtube.com/embed/"+e[2]+"?showinfo=0":(e=t.match(/^(?:(https?):\/\/)?(?:www\.)?vimeo\.com\/(\d+)/))?(e[1]||"https")+"://player.vimeo.com/video/"+e[2]+"/":t}function s(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];e.forEach(function(e){var r=document.createElement("option");e===n?r.setAttribute("selected","selected"):r.setAttribute("value",e),t.appendChild(r)})}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.BaseTooltip=void 0;var u=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),c=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},f=n(2),h=r(f),p=n(4),d=r(p),y=n(9),v=r(y),b=n(25),g=r(b),m=n(32),_=r(m),O=n(41),w=r(O),x=n(42),k=r(x),E=n(16),N=r(E),j=n(43),A=r(j),q=[!1,"center","right","justify"],T=["#000000","#e60000","#ff9900","#ffff00","#008a00","#0066cc","#9933ff","#ffffff","#facccc","#ffebcc","#ffffcc","#cce8cc","#cce0f5","#ebd6ff","#bbbbbb","#f06666","#ffc266","#ffff66","#66b966","#66a3e0","#c285ff","#888888","#a10000","#b26b00","#b2b200","#006100","#0047b2","#6b24b2","#444444","#5c0000","#663d00","#666600","#003700","#002966","#3d1466"],P=[!1,"serif","monospace"],S=["1","2","3",!1],C=["small",!1,"large","huge"],L=function(t){function e(t,n){o(this,e);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n)),l=function e(n){if(!document.body.contains(t.root))return document.body.removeEventListener("click",e);null==r.tooltip||r.tooltip.root.contains(n.target)||document.activeElement===r.tooltip.textbox||r.quill.hasFocus()||r.tooltip.hide(),null!=r.pickers&&r.pickers.forEach(function(t){t.container.contains(n.target)||t.close()})};return t.emitter.listenDOM("click",document.body,l),r}return l(e,t),u(e,[{key:"addModule",value:function(t){var n=c(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"addModule",this).call(this,t);return"toolbar"===t&&this.extendToolbar(n),n}},{key:"buildButtons",value:function(t,e){t.forEach(function(t){(t.getAttribute("class")||"").split(/\s+/).forEach(function(n){if(n.startsWith("ql-")&&(n=n.slice("ql-".length),null!=e[n]))if("direction"===n)t.innerHTML=e[n][""]+e[n].rtl;else if("string"==typeof e[n])t.innerHTML=e[n];else{var r=t.value||"";null!=r&&e[n][r]&&(t.innerHTML=e[n][r])}})})}},{key:"buildPickers",value:function(t,e){var n=this;this.pickers=t.map(function(t){if(t.classList.contains("ql-align"))return null==t.querySelector("option")&&s(t,q),new k.default(t,e.align);if(t.classList.contains("ql-background")||t.classList.contains("ql-color")){var n=t.classList.contains("ql-background")?"background":"color";return null==t.querySelector("option")&&s(t,T,"background"===n?"#ffffff":"#000000"),new w.default(t,e[n])}return null==t.querySelector("option")&&(t.classList.contains("ql-font")?s(t,P):t.classList.contains("ql-header")?s(t,S):t.classList.contains("ql-size")&&s(t,C)),new N.default(t)});var r=function(){n.pickers.forEach(function(t){t.update()})};this.quill.on(v.default.events.EDITOR_CHANGE,r)}}]),e}(_.default);L.DEFAULTS=(0,h.default)(!0,{},_.default.DEFAULTS,{modules:{toolbar:{handlers:{formula:function(){this.quill.theme.tooltip.edit("formula")},image:function(){var t=this,e=this.container.querySelector("input.ql-image[type=file]");null==e&&(e=document.createElement("input"),e.setAttribute("type","file"),e.setAttribute("accept","image/png, image/gif, image/jpeg, image/bmp, image/x-icon"),e.classList.add("ql-image"),e.addEventListener("change",function(){if(null!=e.files&&null!=e.files[0]){var n=new FileReader;n.onload=function(n){var r=t.quill.getSelection(!0);t.quill.updateContents((new d.default).retain(r.index).delete(r.length).insert({image:n.target.result}),v.default.sources.USER),t.quill.setSelection(r.index+1,v.default.sources.SILENT),e.value=""},n.readAsDataURL(e.files[0])}}),this.container.appendChild(e)),e.click()},video:function(){this.quill.theme.tooltip.edit("video")}}}}});var M=function(t){function e(t,n){o(this,e);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.textbox=r.root.querySelector('input[type="text"]'),r.listen(),r}return l(e,t),u(e,[{key:"listen",value:function(){var t=this;this.textbox.addEventListener("keydown",function(e){g.default.match(e,"enter")?(t.save(),e.preventDefault()):g.default.match(e,"escape")&&(t.cancel(),e.preventDefault())})}},{key:"cancel",value:function(){this.hide()}},{key:"edit",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"link",e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;this.root.classList.remove("ql-hidden"),this.root.classList.add("ql-editing"),null!=e?this.textbox.value=e:t!==this.root.getAttribute("data-mode")&&(this.textbox.value=""),this.position(this.quill.getBounds(this.quill.selection.savedRange)),this.textbox.select(),this.textbox.setAttribute("placeholder",this.textbox.getAttribute("data-"+t)||""),this.root.setAttribute("data-mode",t)}},{key:"restoreFocus",value:function(){var t=this.quill.scrollingContainer.scrollTop;this.quill.focus(),this.quill.scrollingContainer.scrollTop=t}},{key:"save",value:function(){var t=this.textbox.value;switch(this.root.getAttribute("data-mode")){case"link":var e=this.quill.root.scrollTop;this.linkRange?(this.quill.formatText(this.linkRange,"link",t,v.default.sources.USER),delete this.linkRange):(this.restoreFocus(),this.quill.format("link",t,v.default.sources.USER)),this.quill.root.scrollTop=e;break;case"video":t=a(t);case"formula":if(!t)break;var n=this.quill.getSelection(!0);if(null!=n){var r=n.index+n.length;this.quill.insertEmbed(r,this.root.getAttribute("data-mode"),t,v.default.sources.USER),"formula"===this.root.getAttribute("data-mode")&&this.quill.insertText(r+1," ",v.default.sources.USER),this.quill.setSelection(r+2,v.default.sources.USER)}}this.textbox.value="",this.hide()}}]),e}(A.default);e.BaseTooltip=M,e.default=L},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(46),i=r(o),l=n(34),a=n(36),s=n(62),u=n(63),c=r(u),f=n(64),h=r(f),p=n(65),d=r(p),y=n(35),v=n(24),b=n(37),g=n(38),m=n(39),_=r(m),O=n(66),w=r(O),x=n(15),k=r(x),E=n(67),N=r(E),j=n(68),A=r(j),q=n(69),T=r(q),P=n(70),S=r(P),C=n(71),L=r(C),M=n(13),R=r(M),I=n(72),B=r(I),D=n(73),U=r(D),F=n(74),H=r(F),K=n(26),z=r(K),Z=n(16),V=r(Z),W=n(41),G=r(W),Y=n(42),X=r(Y),$=n(43),Q=r($),J=n(107),tt=r(J),et=n(108),nt=r(et);i.default.register({"attributors/attribute/direction":a.DirectionAttribute,"attributors/class/align":l.AlignClass,"attributors/class/background":y.BackgroundClass,"attributors/class/color":v.ColorClass,"attributors/class/direction":a.DirectionClass,"attributors/class/font":b.FontClass,"attributors/class/size":g.SizeClass,"attributors/style/align":l.AlignStyle,"attributors/style/background":y.BackgroundStyle,"attributors/style/color":v.ColorStyle,"attributors/style/direction":a.DirectionStyle,"attributors/style/font":b.FontStyle,"attributors/style/size":g.SizeStyle},!0),i.default.register({"formats/align":l.AlignClass,"formats/direction":a.DirectionClass,"formats/indent":s.IndentClass,"formats/background":y.BackgroundStyle,"formats/color":v.ColorStyle,"formats/font":b.FontClass,"formats/size":g.SizeClass,"formats/blockquote":c.default,"formats/code-block":R.default,"formats/header":h.default,"formats/list":d.default,"formats/bold":_.default,"formats/code":M.Code,"formats/italic":w.default,"formats/link":k.default,"formats/script":N.default,"formats/strike":A.default,"formats/underline":T.default,"formats/image":S.default,"formats/video":L.default,"formats/list/item":p.ListItem,"modules/formula":B.default,"modules/syntax":U.default,"modules/toolbar":H.default,"themes/bubble":tt.default,"themes/snow":nt.default,"ui/icons":z.default,"ui/picker":V.default,"ui/icon-picker":X.default,"ui/color-picker":G.default,"ui/tooltip":Q.default},!0),e.default=i.default},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(0),i=r(o),l=n(6),a=r(l),s=n(3),u=r(s),c=n(14),f=r(c),h=n(23),p=r(h),d=n(31),y=r(d),v=n(33),b=r(v),g=n(5),m=r(g),_=n(59),O=r(_),w=n(8),x=r(w),k=n(60),E=r(k),N=n(61),j=r(N),A=n(25),q=r(A);a.default.register({"blots/block":u.default,"blots/block/embed":s.BlockEmbed,"blots/break":f.default,"blots/container":p.default,"blots/cursor":y.default,"blots/embed":b.default,"blots/inline":m.default,"blots/scroll":O.default,"blots/text":x.default,"modules/clipboard":E.default,"modules/history":j.default,"modules/keyboard":q.default}),i.default.register(u.default,f.default,y.default,m.default,O.default,x.default),e.default=a.default},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=function(){function t(){this.head=this.tail=null,this.length=0}return t.prototype.append=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this.insertBefore(t[0],null),t.length>1&&this.append.apply(this,t.slice(1))},t.prototype.contains=function(t){for(var e,n=this.iterator();e=n();)if(e===t)return!0;return!1},t.prototype.insertBefore=function(t,e){t&&(t.next=e,null!=e?(t.prev=e.prev,null!=e.prev&&(e.prev.next=t),e.prev=t,e===this.head&&(this.head=t)):null!=this.tail?(this.tail.next=t,t.prev=this.tail,this.tail=t):(t.prev=null,this.head=this.tail=t),this.length+=1)},t.prototype.offset=function(t){for(var e=0,n=this.head;null!=n;){if(n===t)return e;e+=n.length(),n=n.next}return-1},t.prototype.remove=function(t){this.contains(t)&&(null!=t.prev&&(t.prev.next=t.next),null!=t.next&&(t.next.prev=t.prev),t===this.head&&(this.head=t.next),t===this.tail&&(this.tail=t.prev),this.length-=1)},t.prototype.iterator=function(t){return void 0===t&&(t=this.head),function(){var e=t;return null!=t&&(t=t.next),e}},t.prototype.find=function(t,e){void 0===e&&(e=!1);for(var n,r=this.iterator();n=r();){var o=n.length();if(t<o||e&&t===o&&(null==n.next||0!==n.next.length()))return[n,t];t-=o}return[null,0]},t.prototype.forEach=function(t){for(var e,n=this.iterator();e=n();)t(e)},t.prototype.forEachAt=function(t,e,n){if(!(e<=0))for(var r,o=this.find(t),i=o[0],l=o[1],a=t-l,s=this.iterator(i);(r=s())&&a<t+e;){var u=r.length();t>a?n(r,t-a,Math.min(e,a+u-t)):n(r,0,Math.min(u,t+e-a)),a+=u}},t.prototype.map=function(t){return this.reduce(function(e,n){return e.push(t(n)),e},[])},t.prototype.reduce=function(t,e){for(var n,r=this.iterator();n=r();)e=t(e,n);return e},t}();e.default=r},function(t,e,n){"use strict";var r=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var o=n(17),i=n(1),l={attributes:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0},a=function(t){function e(e){var n=t.call(this,e)||this;return n.scroll=n,n.observer=new MutationObserver(function(t){n.update(t)}),n.observer.observe(n.domNode,l),n.attach(),n}return r(e,t),e.prototype.detach=function(){t.prototype.detach.call(this),this.observer.disconnect()},e.prototype.deleteAt=function(e,n){this.update(),0===e&&n===this.length()?this.children.forEach(function(t){t.remove()}):t.prototype.deleteAt.call(this,e,n)},e.prototype.formatAt=function(e,n,r,o){this.update(),t.prototype.formatAt.call(this,e,n,r,o)},e.prototype.insertAt=function(e,n,r){this.update(),t.prototype.insertAt.call(this,e,n,r)},e.prototype.optimize=function(e,n){var r=this;void 0===e&&(e=[]),void 0===n&&(n={}),t.prototype.optimize.call(this,n);for(var l=[].slice.call(this.observer.takeRecords());l.length>0;)e.push(l.pop());for(var a=function(t,e){void 0===e&&(e=!0),null!=t&&t!==r&&null!=t.domNode.parentNode&&(null==t.domNode[i.DATA_KEY].mutations&&(t.domNode[i.DATA_KEY].mutations=[]),e&&a(t.parent))},s=function(t){null!=t.domNode[i.DATA_KEY]&&null!=t.domNode[i.DATA_KEY].mutations&&(t instanceof o.default&&t.children.forEach(s),t.optimize(n))},u=e,c=0;u.length>0;c+=1){if(c>=100)throw new Error("[Parchment] Maximum optimize iterations reached");for(u.forEach(function(t){var e=i.find(t.target,!0);null!=e&&(e.domNode===t.target&&("childList"===t.type?(a(i.find(t.previousSibling,!1)),[].forEach.call(t.addedNodes,function(t){var e=i.find(t,!1);a(e,!1),e instanceof o.default&&e.children.forEach(function(t){a(t,!1)})})):"attributes"===t.type&&a(e.prev)),a(e))}),this.children.forEach(s),u=[].slice.call(this.observer.takeRecords()),l=u.slice();l.length>0;)e.push(l.pop())}},e.prototype.update=function(e,n){var r=this;void 0===n&&(n={}),e=e||this.observer.takeRecords(),e.map(function(t){var e=i.find(t.target,!0);return null==e?null:null==e.domNode[i.DATA_KEY].mutations?(e.domNode[i.DATA_KEY].mutations=[t],e):(e.domNode[i.DATA_KEY].mutations.push(t),null)}).forEach(function(t){null!=t&&t!==r&&null!=t.domNode[i.DATA_KEY]&&t.update(t.domNode[i.DATA_KEY].mutations||[],n)}),null!=this.domNode[i.DATA_KEY].mutations&&t.prototype.update.call(this,this.domNode[i.DATA_KEY].mutations,n),this.optimize(e,n)},e.blotName="scroll",e.defaultChild="block",e.scope=i.Scope.BLOCK_BLOT,e.tagName="DIV",e}(o.default);e.default=a},function(t,e,n){"use strict";function r(t,e){if(Object.keys(t).length!==Object.keys(e).length)return!1;for(var n in t)if(t[n]!==e[n])return!1;return!0}var o=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var i=n(18),l=n(1),a=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return o(e,t),e.formats=function(n){if(n.tagName!==e.tagName)return t.formats.call(this,n)},e.prototype.format=function(n,r){var o=this;n!==this.statics.blotName||r?t.prototype.format.call(this,n,r):(this.children.forEach(function(t){t instanceof i.default||(t=t.wrap(e.blotName,!0)),o.attributes.copy(t)}),this.unwrap())},e.prototype.formatAt=function(e,n,r,o){if(null!=this.formats()[r]||l.query(r,l.Scope.ATTRIBUTE)){this.isolate(e,n).format(r,o)}else t.prototype.formatAt.call(this,e,n,r,o)},e.prototype.optimize=function(n){t.prototype.optimize.call(this,n);var o=this.formats();if(0===Object.keys(o).length)return this.unwrap();var i=this.next;i instanceof e&&i.prev===this&&r(o,i.formats())&&(i.moveChildren(this),i.remove())},e.blotName="inline",e.scope=l.Scope.INLINE_BLOT,e.tagName="SPAN",e}(i.default);e.default=a},function(t,e,n){"use strict";var r=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var o=n(18),i=n(1),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.formats=function(n){var r=i.query(e.blotName).tagName;if(n.tagName!==r)return t.formats.call(this,n)},e.prototype.format=function(n,r){null!=i.query(n,i.Scope.BLOCK)&&(n!==this.statics.blotName||r?t.prototype.format.call(this,n,r):this.replaceWith(e.blotName))},e.prototype.formatAt=function(e,n,r,o){null!=i.query(r,i.Scope.BLOCK)?this.format(r,o):t.prototype.formatAt.call(this,e,n,r,o)},e.prototype.insertAt=function(e,n,r){if(null==r||null!=i.query(n,i.Scope.INLINE))t.prototype.insertAt.call(this,e,n,r);else{var o=this.split(e),l=i.create(n,r);o.parent.insertBefore(l,o)}},e.prototype.update=function(e,n){navigator.userAgent.match(/Trident/)?this.build():t.prototype.update.call(this,e,n)},e.blotName="block",e.scope=i.Scope.BLOCK_BLOT,e.tagName="P",e}(o.default);e.default=l},function(t,e,n){"use strict";var r=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var o=n(19),i=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.formats=function(t){},e.prototype.format=function(e,n){t.prototype.formatAt.call(this,0,this.length(),e,n)},e.prototype.formatAt=function(e,n,r,o){0===e&&n===this.length()?this.format(r,o):t.prototype.formatAt.call(this,e,n,r,o)},e.prototype.formats=function(){return this.statics.formats(this.domNode)},e}(o.default);e.default=i},function(t,e,n){"use strict";var r=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var o=n(19),i=n(1),l=function(t){function e(e){var n=t.call(this,e)||this;return n.text=n.statics.value(n.domNode),n}return r(e,t),e.create=function(t){return document.createTextNode(t)},e.value=function(t){var e=t.data;return e.normalize&&(e=e.normalize()),e},e.prototype.deleteAt=function(t,e){this.domNode.data=this.text=this.text.slice(0,t)+this.text.slice(t+e)},e.prototype.index=function(t,e){return this.domNode===t?e:-1},e.prototype.insertAt=function(e,n,r){null==r?(this.text=this.text.slice(0,e)+n+this.text.slice(e),this.domNode.data=this.text):t.prototype.insertAt.call(this,e,n,r)},e.prototype.length=function(){return this.text.length},e.prototype.optimize=function(n){t.prototype.optimize.call(this,n),this.text=this.statics.value(this.domNode),0===this.text.length?this.remove():this.next instanceof e&&this.next.prev===this&&(this.insertAt(this.length(),this.next.value()),this.next.remove())},e.prototype.position=function(t,e){return void 0===e&&(e=!1),[this.domNode,t]},e.prototype.split=function(t,e){if(void 0===e&&(e=!1),!e){if(0===t)return this;if(t===this.length())return this.next}var n=i.create(this.domNode.splitText(t));return this.parent.insertBefore(n,this.next),this.text=this.statics.value(this.domNode),n},e.prototype.update=function(t,e){var n=this;t.some(function(t){return"characterData"===t.type&&t.target===n.domNode})&&(this.text=this.statics.value(this.domNode))},e.prototype.value=function(){return this.text},e.blotName="text",e.scope=i.Scope.INLINE_BLOT,e}(o.default);e.default=l},function(t,e,n){"use strict";var r=document.createElement("div");if(r.classList.toggle("test-class",!1),r.classList.contains("test-class")){var o=DOMTokenList.prototype.toggle;DOMTokenList.prototype.toggle=function(t,e){return arguments.length>1&&!this.contains(t)==!e?e:o.call(this,t)}}String.prototype.startsWith||(String.prototype.startsWith=function(t,e){return e=e||0,this.substr(e,t.length)===t}),String.prototype.endsWith||(String.prototype.endsWith=function(t,e){var n=this.toString();("number"!=typeof e||!isFinite(e)||Math.floor(e)!==e||e>n.length)&&(e=n.length),e-=t.length;var r=n.indexOf(t,e);return-1!==r&&r===e}),Array.prototype.find||Object.defineProperty(Array.prototype,"find",{value:function(t){if(null===this)throw new TypeError("Array.prototype.find called on null or undefined");if("function"!=typeof t)throw new TypeError("predicate must be a function");for(var e,n=Object(this),r=n.length>>>0,o=arguments[1],i=0;i<r;i++)if(e=n[i],t.call(o,e,i,n))return e}}),document.addEventListener("DOMContentLoaded",function(){document.execCommand("enableObjectResizing",!1,!1),document.execCommand("autoUrlDetect",!1,!1)})},function(t,e){function n(t,e,n){if(t==e)return t?[[v,t]]:[];(n<0||t.length<n)&&(n=null);var o=l(t,e),i=t.substring(0,o);t=t.substring(o),e=e.substring(o),o=a(t,e);var s=t.substring(t.length-o);t=t.substring(0,t.length-o),e=e.substring(0,e.length-o);var c=r(t,e);return i&&c.unshift([v,i]),s&&c.push([v,s]),u(c),null!=n&&(c=f(c,n)),c=h(c)}function r(t,e){var r;if(!t)return[[y,e]];if(!e)return[[d,t]];var i=t.length>e.length?t:e,l=t.length>e.length?e:t,a=i.indexOf(l);if(-1!=a)return r=[[y,i.substring(0,a)],[v,l],[y,i.substring(a+l.length)]],t.length>e.length&&(r[0][0]=r[2][0]=d),r;if(1==l.length)return[[d,t],[y,e]];var u=s(t,e);if(u){var c=u[0],f=u[1],h=u[2],p=u[3],b=u[4],g=n(c,h),m=n(f,p);return g.concat([[v,b]],m)}return o(t,e)}function o(t,e){for(var n=t.length,r=e.length,o=Math.ceil((n+r)/2),l=o,a=2*o,s=new Array(a),u=new Array(a),c=0;c<a;c++)s[c]=-1,u[c]=-1;s[l+1]=0,u[l+1]=0;for(var f=n-r,h=f%2!=0,p=0,v=0,b=0,g=0,m=0;m<o;m++){for(var _=-m+p;_<=m-v;_+=2){var O,w=l+_;O=_==-m||_!=m&&s[w-1]<s[w+1]?s[w+1]:s[w-1]+1;for(var x=O-_;O<n&&x<r&&t.charAt(O)==e.charAt(x);)O++,x++;if(s[w]=O,O>n)v+=2;else if(x>r)p+=2;else if(h){var k=l+f-_;if(k>=0&&k<a&&-1!=u[k]){var E=n-u[k];if(O>=E)return i(t,e,O,x)}}}for(var N=-m+b;N<=m-g;N+=2){var E,k=l+N;E=N==-m||N!=m&&u[k-1]<u[k+1]?u[k+1]:u[k-1]+1;for(var j=E-N;E<n&&j<r&&t.charAt(n-E-1)==e.charAt(r-j-1);)E++,j++;if(u[k]=E,E>n)g+=2;else if(j>r)b+=2;else if(!h){var w=l+f-N;if(w>=0&&w<a&&-1!=s[w]){var O=s[w],x=l+O-w;if(E=n-E,O>=E)return i(t,e,O,x)}}}}return[[d,t],[y,e]]}function i(t,e,r,o){var i=t.substring(0,r),l=e.substring(0,o),a=t.substring(r),s=e.substring(o),u=n(i,l),c=n(a,s);return u.concat(c)}function l(t,e){if(!t||!e||t.charAt(0)!=e.charAt(0))return 0;for(var n=0,r=Math.min(t.length,e.length),o=r,i=0;n<o;)t.substring(i,o)==e.substring(i,o)?(n=o,i=n):r=o,o=Math.floor((r-n)/2+n);return o}function a(t,e){if(!t||!e||t.charAt(t.length-1)!=e.charAt(e.length-1))return 0;for(var n=0,r=Math.min(t.length,e.length),o=r,i=0;n<o;)t.substring(t.length-o,t.length-i)==e.substring(e.length-o,e.length-i)?(n=o,i=n):r=o,o=Math.floor((r-n)/2+n);return o}function s(t,e){function n(t,e,n){for(var r,o,i,s,u=t.substring(n,n+Math.floor(t.length/4)),c=-1,f="";-1!=(c=e.indexOf(u,c+1));){var h=l(t.substring(n),e.substring(c)),p=a(t.substring(0,n),e.substring(0,c));f.length<p+h&&(f=e.substring(c-p,c)+e.substring(c,c+h),r=t.substring(0,n-p),o=t.substring(n+h),i=e.substring(0,c-p),s=e.substring(c+h))}return 2*f.length>=t.length?[r,o,i,s,f]:null}var r=t.length>e.length?t:e,o=t.length>e.length?e:t;if(r.length<4||2*o.length<r.length)return null;var i,s=n(r,o,Math.ceil(r.length/4)),u=n(r,o,Math.ceil(r.length/2));if(!s&&!u)return null;i=u?s&&s[4].length>u[4].length?s:u:s;var c,f,h,p;return t.length>e.length?(c=i[0],f=i[1],h=i[2],p=i[3]):(h=i[0],p=i[1],c=i[2],f=i[3]),[c,f,h,p,i[4]]}function u(t){t.push([v,""]);for(var e,n=0,r=0,o=0,i="",s="";n<t.length;)switch(t[n][0]){case y:o++,s+=t[n][1],n++;break;case d:r++,i+=t[n][1],n++;break;case v:r+o>1?(0!==r&&0!==o&&(e=l(s,i),0!==e&&(n-r-o>0&&t[n-r-o-1][0]==v?t[n-r-o-1][1]+=s.substring(0,e):(t.splice(0,0,[v,s.substring(0,e)]),n++),s=s.substring(e),i=i.substring(e)),0!==(e=a(s,i))&&(t[n][1]=s.substring(s.length-e)+t[n][1],s=s.substring(0,s.length-e),i=i.substring(0,i.length-e))),0===r?t.splice(n-o,r+o,[y,s]):0===o?t.splice(n-r,r+o,[d,i]):t.splice(n-r-o,r+o,[d,i],[y,s]),n=n-r-o+(r?1:0)+(o?1:0)+1):0!==n&&t[n-1][0]==v?(t[n-1][1]+=t[n][1],t.splice(n,1)):n++,o=0,r=0,i="",s=""}""===t[t.length-1][1]&&t.pop();var c=!1;for(n=1;n<t.length-1;)t[n-1][0]==v&&t[n+1][0]==v&&(t[n][1].substring(t[n][1].length-t[n-1][1].length)==t[n-1][1]?(t[n][1]=t[n-1][1]+t[n][1].substring(0,t[n][1].length-t[n-1][1].length),t[n+1][1]=t[n-1][1]+t[n+1][1],t.splice(n-1,1),c=!0):t[n][1].substring(0,t[n+1][1].length)==t[n+1][1]&&(t[n-1][1]+=t[n+1][1],t[n][1]=t[n][1].substring(t[n+1][1].length)+t[n+1][1],t.splice(n+1,1),c=!0)),n++;c&&u(t)}function c(t,e){if(0===e)return[v,t];for(var n=0,r=0;r<t.length;r++){var o=t[r];if(o[0]===d||o[0]===v){var i=n+o[1].length;if(e===i)return[r+1,t];if(e<i){t=t.slice();var l=e-n,a=[o[0],o[1].slice(0,l)],s=[o[0],o[1].slice(l)];return t.splice(r,1,a,s),[r+1,t]}n=i}}throw new Error("cursor_pos is out of bounds!")}function f(t,e){var n=c(t,e),r=n[1],o=n[0],i=r[o],l=r[o+1];if(null==i)return t;if(i[0]!==v)return t;if(null!=l&&i[1]+l[1]===l[1]+i[1])return r.splice(o,2,l,i),p(r,o,2);if(null!=l&&0===l[1].indexOf(i[1])){r.splice(o,2,[l[0],i[1]],[0,i[1]]);var a=l[1].slice(i[1].length);return a.length>0&&r.splice(o+2,0,[l[0],a]),p(r,o,3)}return t}function h(t){for(var e=!1,n=function(t){return t.charCodeAt(0)>=56320&&t.charCodeAt(0)<=57343},r=2;r<t.length;r+=1)t[r-2][0]===v&&function(t){return t.charCodeAt(t.length-1)>=55296&&t.charCodeAt(t.length-1)<=56319}(t[r-2][1])&&t[r-1][0]===d&&n(t[r-1][1])&&t[r][0]===y&&n(t[r][1])&&(e=!0,t[r-1][1]=t[r-2][1].slice(-1)+t[r-1][1],t[r][1]=t[r-2][1].slice(-1)+t[r][1],t[r-2][1]=t[r-2][1].slice(0,-1));if(!e)return t;for(var o=[],r=0;r<t.length;r+=1)t[r][1].length>0&&o.push(t[r]);return o}function p(t,e,n){for(var r=e+n-1;r>=0&&r>=e-1;r--)if(r+1<t.length){var o=t[r],i=t[r+1];o[0]===i[1]&&t.splice(r,2,[o[0],o[1]+i[1]])}return t}var d=-1,y=1,v=0,b=n;b.INSERT=y,b.DELETE=d,b.EQUAL=v,t.exports=b},function(t,e){function n(t){var e=[];for(var n in t)e.push(n);return e}e=t.exports="function"==typeof Object.keys?Object.keys:n,e.shim=n},function(t,e){function n(t){return"[object Arguments]"==Object.prototype.toString.call(t)}function r(t){return t&&"object"==typeof t&&"number"==typeof t.length&&Object.prototype.hasOwnProperty.call(t,"callee")&&!Object.prototype.propertyIsEnumerable.call(t,"callee")||!1}var o="[object Arguments]"==function(){return Object.prototype.toString.call(arguments)}();e=t.exports=o?n:r,e.supported=n,e.unsupported=r},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function l(t,e){return Object.keys(e).reduce(function(n,r){return null==t[r]?n:(e[r]===t[r]?n[r]=e[r]:Array.isArray(e[r])?e[r].indexOf(t[r])<0&&(n[r]=e[r].concat([t[r]])):n[r]=[e[r],t[r]],n)},{})}function a(t){return t.reduce(function(t,e){if(1===e.insert){var n=(0,N.default)(e.attributes);return delete n.image,t.insert({image:e.attributes.image},n)}if(null==e.attributes||!0!==e.attributes.list&&!0!==e.attributes.bullet||(e=(0,N.default)(e),e.attributes.list?e.attributes.list="ordered":(e.attributes.list="bullet",delete e.attributes.bullet)),"string"==typeof e.insert){var r=e.insert.replace(/\r\n/g,"\n").replace(/\r/g,"\n");return t.insert(r,e.attributes)}return t.push(e)},new h.default)}Object.defineProperty(e,"__esModule",{value:!0});var 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},u=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),c=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),f=n(4),h=r(f),p=n(20),d=r(p),y=n(0),v=r(y),b=n(13),g=r(b),m=n(31),_=r(m),O=n(3),w=r(O),x=n(14),k=r(x),E=n(21),N=r(E),j=n(12),A=r(j),q=n(2),T=r(q),P=/^[ -~]*$/,S=function(){function t(e){i(this,t),this.scroll=e,this.delta=this.getDelta()}return c(t,[{key:"applyDelta",value:function(t){var e=this,n=!1;this.scroll.update();var r=this.scroll.length();return this.scroll.batchStart(),t=a(t),t.reduce(function(t,o){var i=o.retain||o.delete||o.insert.length||1,l=o.attributes||{};if(null!=o.insert){if("string"==typeof o.insert){var a=o.insert;a.endsWith("\n")&&n&&(n=!1,a=a.slice(0,-1)),t>=r&&!a.endsWith("\n")&&(n=!0),e.scroll.insertAt(t,a);var c=e.scroll.line(t),f=u(c,2),h=f[0],p=f[1],y=(0,T.default)({},(0,O.bubbleFormats)(h));if(h instanceof w.default){var b=h.descendant(v.default.Leaf,p),g=u(b,1),m=g[0];y=(0,T.default)(y,(0,O.bubbleFormats)(m))}l=d.default.attributes.diff(y,l)||{}}else if("object"===s(o.insert)){var _=Object.keys(o.insert)[0];if(null==_)return t;e.scroll.insertAt(t,_,o.insert[_])}r+=i}return Object.keys(l).forEach(function(n){e.scroll.formatAt(t,i,n,l[n])}),t+i},0),t.reduce(function(t,n){return"number"==typeof n.delete?(e.scroll.deleteAt(t,n.delete),t):t+(n.retain||n.insert.length||1)},0),this.scroll.batchEnd(),this.update(t)}},{key:"deleteText",value:function(t,e){return this.scroll.deleteAt(t,e),this.update((new h.default).retain(t).delete(e))}},{key:"formatLine",value:function(t,e){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.scroll.update(),Object.keys(r).forEach(function(o){if(null==n.scroll.whitelist||n.scroll.whitelist[o]){var i=n.scroll.lines(t,Math.max(e,1)),l=e;i.forEach(function(e){var i=e.length();if(e instanceof g.default){var a=t-e.offset(n.scroll),s=e.newlineIndex(a+l)-a+1;e.formatAt(a,s,o,r[o])}else e.format(o,r[o]);l-=i})}}),this.scroll.optimize(),this.update((new h.default).retain(t).retain(e,(0,N.default)(r)))}},{key:"formatText",value:function(t,e){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return Object.keys(r).forEach(function(o){n.scroll.formatAt(t,e,o,r[o])}),this.update((new h.default).retain(t).retain(e,(0,N.default)(r)))}},{key:"getContents",value:function(t,e){return this.delta.slice(t,t+e)}},{key:"getDelta",value:function(){return this.scroll.lines().reduce(function(t,e){return t.concat(e.delta())},new h.default)}},{key:"getFormat",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=[],r=[];0===e?this.scroll.path(t).forEach(function(t){var e=u(t,1),o=e[0];o instanceof w.default?n.push(o):o instanceof v.default.Leaf&&r.push(o)}):(n=this.scroll.lines(t,e),r=this.scroll.descendants(v.default.Leaf,t,e));var o=[n,r].map(function(t){if(0===t.length)return{};for(var e=(0,O.bubbleFormats)(t.shift());Object.keys(e).length>0;){var n=t.shift();if(null==n)return e;e=l((0,O.bubbleFormats)(n),e)}return e});return T.default.apply(T.default,o)}},{key:"getText",value:function(t,e){return this.getContents(t,e).filter(function(t){return"string"==typeof t.insert}).map(function(t){return t.insert}).join("")}},{key:"insertEmbed",value:function(t,e,n){return this.scroll.insertAt(t,e,n),this.update((new h.default).retain(t).insert(o({},e,n)))}},{key:"insertText",value:function(t,e){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return e=e.replace(/\r\n/g,"\n").replace(/\r/g,"\n"),this.scroll.insertAt(t,e),Object.keys(r).forEach(function(o){n.scroll.formatAt(t,e.length,o,r[o])}),this.update((new h.default).retain(t).insert(e,(0,N.default)(r)))}},{key:"isBlank",value:function(){if(0==this.scroll.children.length)return!0;if(this.scroll.children.length>1)return!1;var t=this.scroll.children.head;return t.statics.blotName===w.default.blotName&&(!(t.children.length>1)&&t.children.head instanceof k.default)}},{key:"removeFormat",value:function(t,e){var n=this.getText(t,e),r=this.scroll.line(t+e),o=u(r,2),i=o[0],l=o[1],a=0,s=new h.default;null!=i&&(a=i instanceof g.default?i.newlineIndex(l)-l+1:i.length()-l,s=i.delta().slice(l,l+a-1).insert("\n"));var c=this.getContents(t,e+a),f=c.diff((new h.default).insert(n).concat(s)),p=(new h.default).retain(t).concat(f);return this.applyDelta(p)}},{key:"update",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,r=this.delta;if(1===e.length&&"characterData"===e[0].type&&e[0].target.data.match(P)&&v.default.find(e[0].target)){var o=v.default.find(e[0].target),i=(0,O.bubbleFormats)(o),l=o.offset(this.scroll),a=e[0].oldValue.replace(_.default.CONTENTS,""),s=(new h.default).insert(a),u=(new h.default).insert(o.value());t=(new h.default).retain(l).concat(s.diff(u,n)).reduce(function(t,e){return e.insert?t.insert(e.insert,i):t.push(e)},new h.default),this.delta=r.compose(t)}else this.delta=this.getDelta(),t&&(0,A.default)(r.compose(t),this.delta)||(t=r.diff(this.delta,n));return t}}]),t}();e.default=S},function(t,e){"use strict";function n(){}function r(t,e,n){this.fn=t,this.context=e,this.once=n||!1}function o(){this._events=new n,this._eventsCount=0}var i=Object.prototype.hasOwnProperty,l="~";Object.create&&(n.prototype=Object.create(null),(new n).__proto__||(l=!1)),o.prototype.eventNames=function(){var t,e,n=[];if(0===this._eventsCount)return n;for(e in t=this._events)i.call(t,e)&&n.push(l?e.slice(1):e);return Object.getOwnPropertySymbols?n.concat(Object.getOwnPropertySymbols(t)):n},o.prototype.listeners=function(t,e){var n=l?l+t:t,r=this._events[n];if(e)return!!r;if(!r)return[];if(r.fn)return[r.fn];for(var o=0,i=r.length,a=new Array(i);o<i;o++)a[o]=r[o].fn;return a},o.prototype.emit=function(t,e,n,r,o,i){var a=l?l+t:t;if(!this._events[a])return!1;var s,u,c=this._events[a],f=arguments.length;if(c.fn){switch(c.once&&this.removeListener(t,c.fn,void 0,!0),f){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,e),!0;case 3:return c.fn.call(c.context,e,n),!0;case 4:return c.fn.call(c.context,e,n,r),!0;case 5:return c.fn.call(c.context,e,n,r,o),!0;case 6:return c.fn.call(c.context,e,n,r,o,i),!0}for(u=1,s=new Array(f-1);u<f;u++)s[u-1]=arguments[u];c.fn.apply(c.context,s)}else{var h,p=c.length;for(u=0;u<p;u++)switch(c[u].once&&this.removeListener(t,c[u].fn,void 0,!0),f){case 1:c[u].fn.call(c[u].context);break;case 2:c[u].fn.call(c[u].context,e);break;case 3:c[u].fn.call(c[u].context,e,n);break;case 4:c[u].fn.call(c[u].context,e,n,r);break;default:if(!s)for(h=1,s=new Array(f-1);h<f;h++)s[h-1]=arguments[h];c[u].fn.apply(c[u].context,s)}}return!0},o.prototype.on=function(t,e,n){var o=new r(e,n||this),i=l?l+t:t;return this._events[i]?this._events[i].fn?this._events[i]=[this._events[i],o]:this._events[i].push(o):(this._events[i]=o,this._eventsCount++),this},o.prototype.once=function(t,e,n){var o=new r(e,n||this,!0),i=l?l+t:t;return this._events[i]?this._events[i].fn?this._events[i]=[this._events[i],o]:this._events[i].push(o):(this._events[i]=o,this._eventsCount++),this},o.prototype.removeListener=function(t,e,r,o){var i=l?l+t:t;if(!this._events[i])return this;if(!e)return 0==--this._eventsCount?this._events=new n:delete this._events[i],this;var a=this._events[i];if(a.fn)a.fn!==e||o&&!a.once||r&&a.context!==r||(0==--this._eventsCount?this._events=new n:delete this._events[i]);else{for(var s=0,u=[],c=a.length;s<c;s++)(a[s].fn!==e||o&&!a[s].once||r&&a[s].context!==r)&&u.push(a[s]);u.length?this._events[i]=1===u.length?u[0]:u:0==--this._eventsCount?this._events=new n:delete this._events[i]}return this},o.prototype.removeAllListeners=function(t){var e;return t?(e=l?l+t:t,this._events[e]&&(0==--this._eventsCount?this._events=new n:delete this._events[e])):(this._events=new n,this._eventsCount=0),this},o.prototype.off=o.prototype.removeListener,o.prototype.addListener=o.prototype.on,o.prototype.setMaxListeners=function(){return this},o.prefixed=l,o.EventEmitter=o,void 0!==t&&(t.exports=o)},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function a(t){return t instanceof v.default||t instanceof y.BlockEmbed}Object.defineProperty(e,"__esModule",{value:!0});var s=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),u=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),c=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},f=n(0),h=r(f),p=n(9),d=r(p),y=n(3),v=r(y),b=n(14),g=r(b),m=n(13),_=r(m),O=n(23),w=r(O),x=function(t){function e(t,n){o(this,e);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return r.emitter=n.emitter,Array.isArray(n.whitelist)&&(r.whitelist=n.whitelist.reduce(function(t,e){return t[e]=!0,t},{})),r.optimize(),r.enable(),r}return l(e,t),u(e,[{key:"batchStart",value:function(){this.batch=!0}},{key:"batchEnd",value:function(){this.batch=!1,this.optimize()}},{key:"deleteAt",value:function(t,n){var r=this.line(t),o=s(r,2),i=o[0],l=o[1],a=this.line(t+n),u=s(a,1),f=u[0];if(c(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"deleteAt",this).call(this,t,n),null!=f&&i!==f&&l>0){if(i instanceof y.BlockEmbed||f instanceof y.BlockEmbed)return void this.optimize();if(i instanceof _.default){var h=i.newlineIndex(i.length(),!0);if(h>-1&&(i=i.split(h+1))===f)return void this.optimize()}else if(f instanceof _.default){var p=f.newlineIndex(0);p>-1&&f.split(p+1)}var d=f.children.head instanceof g.default?null:f.children.head;i.moveChildren(f,d),i.remove()}this.optimize()}},{key:"enable",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this.domNode.setAttribute("contenteditable",t)}},{key:"formatAt",value:function(t,n,r,o){(null==this.whitelist||this.whitelist[r])&&(c(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"formatAt",this).call(this,t,n,r,o),this.optimize())}},{key:"insertAt",value:function(t,n,r){if(null==r||null==this.whitelist||this.whitelist[n]){if(t>=this.length())if(null==r||null==h.default.query(n,h.default.Scope.BLOCK)){var o=h.default.create(this.statics.defaultChild);this.appendChild(o),null==r&&n.endsWith("\n")&&(n=n.slice(0,-1)),o.insertAt(0,n,r)}else{var i=h.default.create(n,r);this.appendChild(i)}else c(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"insertAt",this).call(this,t,n,r);this.optimize()}}},{key:"insertBefore",value:function(t,n){if(t.statics.scope===h.default.Scope.INLINE_BLOT){var r=h.default.create(this.statics.defaultChild);r.appendChild(t),t=r}c(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"insertBefore",this).call(this,t,n)}},{key:"leaf",value:function(t){return this.path(t).pop()||[null,-1]}},{key:"line",value:function(t){return t===this.length()?this.line(t-1):this.descendant(a,t)}},{key:"lines",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.MAX_VALUE;return function t(e,n,r){var o=[],i=r;return e.children.forEachAt(n,r,function(e,n,r){a(e)?o.push(e):e instanceof h.default.Container&&(o=o.concat(t(e,n,i))),i-=r}),o}(this,t,e)}},{key:"optimize",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};!0!==this.batch&&(c(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"optimize",this).call(this,t,n),t.length>0&&this.emitter.emit(d.default.events.SCROLL_OPTIMIZE,t,n))}},{key:"path",value:function(t){return c(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"path",this).call(this,t).slice(1)}},{key:"update",value:function(t){if(!0!==this.batch){var n=d.default.sources.USER;"string"==typeof t&&(n=t),Array.isArray(t)||(t=this.observer.takeRecords()),t.length>0&&this.emitter.emit(d.default.events.SCROLL_BEFORE_UPDATE,n,t),c(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"update",this).call(this,t.concat([])),t.length>0&&this.emitter.emit(d.default.events.SCROLL_UPDATE,n,t)}}}]),e}(h.default.Scroll);x.blotName="scroll",x.className="ql-editor",x.tagName="DIV",x.defaultChild="block",x.allowedChildren=[v.default,y.BlockEmbed,w.default],e.default=x},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function l(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function s(t,e,n){return"object"===(void 0===e?"undefined":x(e))?Object.keys(e).reduce(function(t,n){return s(t,n,e[n])},t):t.reduce(function(t,r){return r.attributes&&r.attributes[e]?t.push(r):t.insert(r.insert,(0,j.default)({},o({},e,n),r.attributes))},new q.default)}function u(t){if(t.nodeType!==Node.ELEMENT_NODE)return{};return t["__ql-computed-style"]||(t["__ql-computed-style"]=window.getComputedStyle(t))}function c(t,e){for(var n="",r=t.ops.length-1;r>=0&&n.length<e.length;--r){var o=t.ops[r];if("string"!=typeof o.insert)break;n=o.insert+n}return n.slice(-1*e.length)===e}function f(t){return 0!==t.childNodes.length&&["block","list-item"].indexOf(u(t).display)>-1}function h(t,e,n){return t.nodeType===t.TEXT_NODE?n.reduce(function(e,n){return n(t,e)},new q.default):t.nodeType===t.ELEMENT_NODE?[].reduce.call(t.childNodes||[],function(r,o){var i=h(o,e,n);return o.nodeType===t.ELEMENT_NODE&&(i=e.reduce(function(t,e){return e(o,t)},i),i=(o[W]||[]).reduce(function(t,e){return e(o,t)},i)),r.concat(i)},new q.default):new q.default}function p(t,e,n){return s(n,t,!0)}function d(t,e){var n=P.default.Attributor.Attribute.keys(t),r=P.default.Attributor.Class.keys(t),o=P.default.Attributor.Style.keys(t),i={};return n.concat(r).concat(o).forEach(function(e){var n=P.default.query(e,P.default.Scope.ATTRIBUTE);null!=n&&(i[n.attrName]=n.value(t),i[n.attrName])||(n=Y[e],null==n||n.attrName!==e&&n.keyName!==e||(i[n.attrName]=n.value(t)||void 0),null==(n=X[e])||n.attrName!==e&&n.keyName!==e||(n=X[e],i[n.attrName]=n.value(t)||void 0))}),Object.keys(i).length>0&&(e=s(e,i)),e}function y(t,e){var n=P.default.query(t);if(null==n)return e;if(n.prototype instanceof P.default.Embed){var r={},o=n.value(t);null!=o&&(r[n.blotName]=o,e=(new q.default).insert(r,n.formats(t)))}else"function"==typeof n.formats&&(e=s(e,n.blotName,n.formats(t)));return e}function v(t,e){return c(e,"\n")||e.insert("\n"),e}function b(){return new q.default}function g(t,e){var n=P.default.query(t);if(null==n||"list-item"!==n.blotName||!c(e,"\n"))return e;for(var r=-1,o=t.parentNode;!o.classList.contains("ql-clipboard");)"list"===(P.default.query(o)||{}).blotName&&(r+=1),o=o.parentNode;return r<=0?e:e.compose((new q.default).retain(e.length()-1).retain(1,{indent:r}))}function m(t,e){return c(e,"\n")||(f(t)||e.length()>0&&t.nextSibling&&f(t.nextSibling))&&e.insert("\n"),e}function _(t,e){if(f(t)&&null!=t.nextElementSibling&&!c(e,"\n\n")){var n=t.offsetHeight+parseFloat(u(t).marginTop)+parseFloat(u(t).marginBottom);t.nextElementSibling.offsetTop>t.offsetTop+1.5*n&&e.insert("\n")}return e}function O(t,e){var n={},r=t.style||{};return r.fontStyle&&"italic"===u(t).fontStyle&&(n.italic=!0),r.fontWeight&&(u(t).fontWeight.startsWith("bold")||parseInt(u(t).fontWeight)>=700)&&(n.bold=!0),Object.keys(n).length>0&&(e=s(e,n)),parseFloat(r.textIndent||0)>0&&(e=(new q.default).insert("\t").concat(e)),e}function w(t,e){var n=t.data;if("O:P"===t.parentNode.tagName)return e.insert(n.trim());if(0===n.trim().length&&t.parentNode.classList.contains("ql-clipboard"))return e;if(!u(t.parentNode).whiteSpace.startsWith("pre")){var r=function(t,e){return e=e.replace(/[^\u00a0]/g,""),e.length<1&&t?" ":e};n=n.replace(/\r\n/g," ").replace(/\n/g," "),n=n.replace(/\s\s+/g,r.bind(r,!0)),(null==t.previousSibling&&f(t.parentNode)||null!=t.previousSibling&&f(t.previousSibling))&&(n=n.replace(/^\s+/,r.bind(r,!1))),(null==t.nextSibling&&f(t.parentNode)||null!=t.nextSibling&&f(t.nextSibling))&&(n=n.replace(/\s+$/,r.bind(r,!1)))}return e.insert(n)}Object.defineProperty(e,"__esModule",{value:!0}),e.matchText=e.matchSpacing=e.matchNewline=e.matchBlot=e.matchAttributor=e.default=void 0;var x="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},k=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),E=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),N=n(2),j=r(N),A=n(4),q=r(A),T=n(0),P=r(T),S=n(6),C=r(S),L=n(10),M=r(L),R=n(7),I=r(R),B=n(34),D=n(35),U=n(13),F=r(U),H=n(24),K=n(36),z=n(37),Z=n(38),V=(0,M.default)("quill:clipboard"),W="__ql-matcher",G=[[Node.TEXT_NODE,w],[Node.TEXT_NODE,m],["br",v],[Node.ELEMENT_NODE,m],[Node.ELEMENT_NODE,y],[Node.ELEMENT_NODE,_],[Node.ELEMENT_NODE,d],[Node.ELEMENT_NODE,O],["li",g],["b",p.bind(p,"bold")],["i",p.bind(p,"italic")],["style",b]],Y=[B.AlignAttribute,K.DirectionAttribute].reduce(function(t,e){return t[e.keyName]=e,t},{}),X=[B.AlignStyle,D.BackgroundStyle,H.ColorStyle,K.DirectionStyle,z.FontStyle,Z.SizeStyle].reduce(function(t,e){return t[e.keyName]=e,t},{}),$=function(t){function e(t,n){i(this,e);var r=l(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.quill.root.addEventListener("paste",r.onPaste.bind(r)),r.container=r.quill.addContainer("ql-clipboard"),r.container.setAttribute("contenteditable",!0),r.container.setAttribute("tabindex",-1),r.matchers=[],G.concat(r.options.matchers).forEach(function(t){var e=k(t,2),o=e[0],i=e[1];(n.matchVisual||i!==_)&&r.addMatcher(o,i)}),r}return a(e,t),E(e,[{key:"addMatcher",value:function(t,e){this.matchers.push([t,e])}},{key:"convert",value:function(t){if("string"==typeof t)return this.container.innerHTML=t.replace(/\>\r?\n +\</g,"><"),this.convert();var e=this.quill.getFormat(this.quill.selection.savedRange.index);if(e[F.default.blotName]){var n=this.container.innerText;return this.container.innerHTML="",(new q.default).insert(n,o({},F.default.blotName,e[F.default.blotName]))}var r=this.prepareMatching(),i=k(r,2),l=i[0],a=i[1],s=h(this.container,l,a);return c(s,"\n")&&null==s.ops[s.ops.length-1].attributes&&(s=s.compose((new q.default).retain(s.length()-1).delete(1))),V.log("convert",this.container.innerHTML,s),this.container.innerHTML="",s}},{key:"dangerouslyPasteHTML",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:C.default.sources.API;if("string"==typeof t)this.quill.setContents(this.convert(t),e),this.quill.setSelection(0,C.default.sources.SILENT);else{var r=this.convert(e);this.quill.updateContents((new q.default).retain(t).concat(r),n),this.quill.setSelection(t+r.length(),C.default.sources.SILENT)}}},{key:"onPaste",value:function(t){var e=this;if(!t.defaultPrevented&&this.quill.isEnabled()){var n=this.quill.getSelection(),r=(new q.default).retain(n.index),o=this.quill.scrollingContainer.scrollTop;this.container.focus(),this.quill.selection.update(C.default.sources.SILENT),setTimeout(function(){r=r.concat(e.convert()).delete(n.length),e.quill.updateContents(r,C.default.sources.USER),e.quill.setSelection(r.length()-n.length,C.default.sources.SILENT),e.quill.scrollingContainer.scrollTop=o,e.quill.focus()},1)}}},{key:"prepareMatching",value:function(){var t=this,e=[],n=[];return this.matchers.forEach(function(r){var o=k(r,2),i=o[0],l=o[1];switch(i){case Node.TEXT_NODE:n.push(l);break;case Node.ELEMENT_NODE:e.push(l);break;default:[].forEach.call(t.container.querySelectorAll(i),function(t){t[W]=t[W]||[],t[W].push(l)})}}),[e,n]}}]),e}(I.default);$.DEFAULTS={matchers:[],matchVisual:!0},e.default=$,e.matchAttributor=d,e.matchBlot=y,e.matchNewline=m,e.matchSpacing=_,e.matchText=w},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function a(t){var e=t.ops[t.ops.length-1];return null!=e&&(null!=e.insert?"string"==typeof e.insert&&e.insert.endsWith("\n"):null!=e.attributes&&Object.keys(e.attributes).some(function(t){return null!=f.default.query(t,f.default.Scope.BLOCK)}))}function s(t){var e=t.reduce(function(t,e){return t+=e.delete||0},0),n=t.length()-e;return a(t)&&(n-=1),n}Object.defineProperty(e,"__esModule",{value:!0}),e.getLastChangeIndex=e.default=void 0;var u=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),c=n(0),f=r(c),h=n(6),p=r(h),d=n(7),y=r(d),v=function(t){function e(t,n){o(this,e);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.lastRecorded=0,r.ignoreChange=!1,r.clear(),r.quill.on(p.default.events.EDITOR_CHANGE,function(t,e,n,o){t!==p.default.events.TEXT_CHANGE||r.ignoreChange||(r.options.userOnly&&o!==p.default.sources.USER?r.transform(e):r.record(e,n))}),r.quill.keyboard.addBinding({key:"Z",shortKey:!0},r.undo.bind(r)),r.quill.keyboard.addBinding({key:"Z",shortKey:!0,shiftKey:!0},r.redo.bind(r)),/Win/i.test(navigator.platform)&&r.quill.keyboard.addBinding({key:"Y",shortKey:!0},r.redo.bind(r)),r}return l(e,t),u(e,[{key:"change",value:function(t,e){if(0!==this.stack[t].length){var n=this.stack[t].pop();this.stack[e].push(n),this.lastRecorded=0,this.ignoreChange=!0,this.quill.updateContents(n[t],p.default.sources.USER),this.ignoreChange=!1;var r=s(n[t]);this.quill.setSelection(r)}}},{key:"clear",value:function(){this.stack={undo:[],redo:[]}}},{key:"cutoff",value:function(){this.lastRecorded=0}},{key:"record",value:function(t,e){if(0!==t.ops.length){this.stack.redo=[];var n=this.quill.getContents().diff(e),r=Date.now();if(this.lastRecorded+this.options.delay>r&&this.stack.undo.length>0){var o=this.stack.undo.pop();n=n.compose(o.undo),t=o.redo.compose(t)}else this.lastRecorded=r;this.stack.undo.push({redo:t,undo:n}),this.stack.undo.length>this.options.maxStack&&this.stack.undo.shift()}}},{key:"redo",value:function(){this.change("redo","undo")}},{key:"transform",value:function(t){this.stack.undo.forEach(function(e){e.undo=t.transform(e.undo,!0),e.redo=t.transform(e.redo,!0)}),this.stack.redo.forEach(function(e){e.undo=t.transform(e.undo,!0),e.redo=t.transform(e.redo,!0)})}},{key:"undo",value:function(){this.change("undo","redo")}}]),e}(y.default);v.DEFAULTS={delay:1e3,maxStack:100,userOnly:!1},e.default=v,e.getLastChangeIndex=s},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0}),e.IndentClass=void 0;var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(0),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,[{key:"add",value:function(t,n){if("+1"===n||"-1"===n){var r=this.value(t)||0;n="+1"===n?r+1:r-1}return 0===n?(this.remove(t),!0):a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"add",this).call(this,t,n)}},{key:"canAdd",value:function(t,n){return a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"canAdd",this).call(this,t,n)||a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"canAdd",this).call(this,t,parseInt(n))}},{key:"value",value:function(t){return parseInt(a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"value",this).call(this,t))||void 0}}]),e}(u.default.Attributor.Class),f=new c("indent","ql-indent",{scope:u.default.Scope.BLOCK,whitelist:[1,2,3,4,5,6,7,8]});e.IndentClass=f},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=n(3),a=function(t){return t&&t.__esModule?t:{default:t}}(l),s=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),e}(a.default);s.blotName="blockquote",s.tagName="blockquote",e.default=s},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=n(3),s=function(t){return t&&t.__esModule?t:{default:t}}(a),u=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,null,[{key:"formats",value:function(t){return this.tagName.indexOf(t.tagName)+1}}]),e}(s.default);u.blotName="header",u.tagName=["H1","H2","H3","H4","H5","H6"],e.default=u},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function l(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.ListItem=void 0;var s=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),u=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},c=n(0),f=r(c),h=n(3),p=r(h),d=n(23),y=r(d),v=function(t){function e(){return i(this,e),l(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return a(e,t),s(e,[{key:"format",value:function(t,n){t!==b.blotName||n?u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"format",this).call(this,t,n):this.replaceWith(f.default.create(this.statics.scope))}},{key:"remove",value:function(){null==this.prev&&null==this.next?this.parent.remove():u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"remove",this).call(this)}},{key:"replaceWith",value:function(t,n){return this.parent.isolate(this.offset(this.parent),this.length()),t===this.parent.statics.blotName?(this.parent.replaceWith(t,n),this):(this.parent.unwrap(),u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"replaceWith",this).call(this,t,n))}}],[{key:"formats",value:function(t){return t.tagName===this.tagName?void 0:u(e.__proto__||Object.getPrototypeOf(e),"formats",this).call(this,t)}}]),e}(p.default);v.blotName="list-item",v.tagName="LI";var b=function(t){function e(t){i(this,e);var n=l(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t)),r=function(e){if(e.target.parentNode===t){var r=n.statics.formats(t),o=f.default.find(e.target);"checked"===r?o.format("list","unchecked"):"unchecked"===r&&o.format("list","checked")}};return t.addEventListener("touchstart",r),t.addEventListener("mousedown",r),n}return a(e,t),s(e,null,[{key:"create",value:function(t){var n="ordered"===t?"OL":"UL",r=u(e.__proto__||Object.getPrototypeOf(e),"create",this).call(this,n);return"checked"!==t&&"unchecked"!==t||r.setAttribute("data-checked","checked"===t),r}},{key:"formats",value:function(t){return"OL"===t.tagName?"ordered":"UL"===t.tagName?t.hasAttribute("data-checked")?"true"===t.getAttribute("data-checked")?"checked":"unchecked":"bullet":void 0}}]),s(e,[{key:"format",value:function(t,e){this.children.length>0&&this.children.tail.format(t,e)}},{key:"formats",value:function(){return o({},this.statics.blotName,this.statics.formats(this.domNode))}},{key:"insertBefore",value:function(t,n){if(t instanceof v)u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"insertBefore",this).call(this,t,n);else{var r=null==n?this.length():n.offset(this),o=this.split(r);o.parent.insertBefore(t,o)}}},{key:"optimize",value:function(t){u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"optimize",this).call(this,t);var n=this.next;null!=n&&n.prev===this&&n.statics.blotName===this.statics.blotName&&n.domNode.tagName===this.domNode.tagName&&n.domNode.getAttribute("data-checked")===this.domNode.getAttribute("data-checked")&&(n.moveChildren(this),n.remove())}},{key:"replace",value:function(t){if(t.statics.blotName!==this.statics.blotName){var n=f.default.create(this.statics.defaultChild);t.moveChildren(n),this.appendChild(n)}u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"replace",this).call(this,t)}}]),e}(y.default);b.blotName="list",b.scope=f.default.Scope.BLOCK_BLOT,b.tagName=["OL","UL"],b.defaultChild="list-item",b.allowedChildren=[v],e.ListItem=v,e.default=b},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=n(39),a=function(t){return t&&t.__esModule?t:{default:t}}(l),s=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),e}(a.default);s.blotName="italic",s.tagName=["EM","I"],e.default=s},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(5),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,null,[{key:"create",value:function(t){return"super"===t?document.createElement("sup"):"sub"===t?document.createElement("sub"):a(e.__proto__||Object.getPrototypeOf(e),"create",this).call(this,t)}},{key:"formats",value:function(t){return"SUB"===t.tagName?"sub":"SUP"===t.tagName?"super":void 0}}]),e}(u.default);c.blotName="script",c.tagName=["SUB","SUP"],e.default=c},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=n(5),a=function(t){return t&&t.__esModule?t:{default:t}}(l),s=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),e}(a.default);s.blotName="strike",s.tagName="S",e.default=s},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=n(5),a=function(t){return t&&t.__esModule?t:{default:t}}(l),s=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),e}(a.default);s.blotName="underline",s.tagName="U",e.default=s},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(0),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c=n(15),f=["alt","height","width"],h=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,[{key:"format",value:function(t,n){f.indexOf(t)>-1?n?this.domNode.setAttribute(t,n):this.domNode.removeAttribute(t):a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"format",this).call(this,t,n)}}],[{key:"create",value:function(t){var n=a(e.__proto__||Object.getPrototypeOf(e),"create",this).call(this,t);return"string"==typeof t&&n.setAttribute("src",this.sanitize(t)),n}},{key:"formats",value:function(t){return f.reduce(function(e,n){return t.hasAttribute(n)&&(e[n]=t.getAttribute(n)),e},{})}},{key:"match",value:function(t){return/\.(jpe?g|gif|png)$/.test(t)||/^data:image\/.+;base64/.test(t)}},{key:"sanitize",value:function(t){return(0,c.sanitize)(t,["http","https","data"])?t:"//:0"}},{key:"value",value:function(t){return t.getAttribute("src")}}]),e}(u.default.Embed);h.blotName="image",h.tagName="IMG",e.default=h},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(3),u=n(15),c=function(t){return t&&t.__esModule?t:{default:t}}(u),f=["height","width"],h=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,[{key:"format",value:function(t,n){f.indexOf(t)>-1?n?this.domNode.setAttribute(t,n):this.domNode.removeAttribute(t):a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"format",this).call(this,t,n)}}],[{key:"create",value:function(t){var n=a(e.__proto__||Object.getPrototypeOf(e),"create",this).call(this,t);return n.setAttribute("frameborder","0"),n.setAttribute("allowfullscreen",!0),n.setAttribute("src",this.sanitize(t)),n}},{key:"formats",value:function(t){return f.reduce(function(e,n){return t.hasAttribute(n)&&(e[n]=t.getAttribute(n)),e},{})}},{key:"sanitize",value:function(t){return c.default.sanitize(t)}},{key:"value",value:function(t){return t.getAttribute("src")}}]),e}(s.BlockEmbed);h.blotName="video",h.className="ql-video",h.tagName="IFRAME",e.default=h},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.FormulaBlot=void 0;var a=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),s=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},u=n(33),c=r(u),f=n(6),h=r(f),p=n(7),d=r(p),y=function(t){function e(){return o(this,e),i(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return l(e,t),a(e,null,[{key:"create",value:function(t){var n=s(e.__proto__||Object.getPrototypeOf(e),"create",this).call(this,t);return"string"==typeof t&&(window.katex.render(t,n,{throwOnError:!1,errorColor:"#f00"}),n.setAttribute("data-value",t)),n}},{key:"value",value:function(t){return t.getAttribute("data-value")}}]),e}(c.default);y.blotName="formula",y.className="ql-formula",y.tagName="SPAN";var v=function(t){function e(){o(this,e);var t=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this));if(null==window.katex)throw new Error("Formula module requires KaTeX.");return t}return l(e,t),a(e,null,[{key:"register",value:function(){h.default.register(y,!0)}}]),e}(d.default);e.FormulaBlot=y,e.default=v},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.CodeToken=e.CodeBlock=void 0;var a=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),s=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},u=n(0),c=r(u),f=n(6),h=r(f),p=n(7),d=r(p),y=n(13),v=r(y),b=function(t){function e(){return o(this,e),i(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return l(e,t),a(e,[{key:"replaceWith",value:function(t){this.domNode.textContent=this.domNode.textContent,this.attach(),s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"replaceWith",this).call(this,t)}},{key:"highlight",value:function(t){var e=this.domNode.textContent;this.cachedText!==e&&((e.trim().length>0||null==this.cachedText)&&(this.domNode.innerHTML=t(e),this.domNode.normalize(),this.attach()),this.cachedText=e)}}]),e}(v.default);b.className="ql-syntax";var g=new c.default.Attributor.Class("token","hljs",{scope:c.default.Scope.INLINE}),m=function(t){function e(t,n){o(this,e);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));if("function"!=typeof r.options.highlight)throw new Error("Syntax module requires highlight.js. Please include the library on the page before Quill.");var l=null;return r.quill.on(h.default.events.SCROLL_OPTIMIZE,function(){clearTimeout(l),l=setTimeout(function(){r.highlight(),l=null},r.options.interval)}),r.highlight(),r}return l(e,t),a(e,null,[{key:"register",value:function(){h.default.register(g,!0),h.default.register(b,!0)}}]),a(e,[{key:"highlight",value:function(){var t=this;if(!this.quill.selection.composing){this.quill.update(h.default.sources.USER);var e=this.quill.getSelection();this.quill.scroll.descendants(b).forEach(function(e){e.highlight(t.options.highlight)}),this.quill.update(h.default.sources.SILENT),null!=e&&this.quill.setSelection(e,h.default.sources.SILENT)}}}]),e}(d.default);m.DEFAULTS={highlight:function(){return null==window.hljs?null:function(t){return window.hljs.highlightAuto(t).value}}(),interval:1e3},e.CodeBlock=b,e.CodeToken=g,e.default=m},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function l(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function s(t,e,n){var r=document.createElement("button");r.setAttribute("type","button"),r.classList.add("ql-"+e),null!=n&&(r.value=n),t.appendChild(r)}function u(t,e){Array.isArray(e[0])||(e=[e]),e.forEach(function(e){var n=document.createElement("span");n.classList.add("ql-formats"),e.forEach(function(t){if("string"==typeof t)s(n,t);else{var e=Object.keys(t)[0],r=t[e];Array.isArray(r)?c(n,e,r):s(n,e,r)}}),t.appendChild(n)})}function c(t,e,n){var r=document.createElement("select");r.classList.add("ql-"+e),n.forEach(function(t){var e=document.createElement("option");!1!==t?e.setAttribute("value",t):e.setAttribute("selected","selected"),r.appendChild(e)}),t.appendChild(r)}Object.defineProperty(e,"__esModule",{value:!0}),e.addControls=e.default=void 0;var f=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),h=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),p=n(4),d=r(p),y=n(0),v=r(y),b=n(6),g=r(b),m=n(10),_=r(m),O=n(7),w=r(O),x=(0,_.default)("quill:toolbar"),k=function(t){function e(t,n){i(this,e);var r=l(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));if(Array.isArray(r.options.container)){var o=document.createElement("div");u(o,r.options.container),t.container.parentNode.insertBefore(o,t.container),r.container=o}else"string"==typeof r.options.container?r.container=document.querySelector(r.options.container):r.container=r.options.container;if(!(r.container instanceof HTMLElement)){var a;return a=x.error("Container required for toolbar",r.options),l(r,a)}return r.container.classList.add("ql-toolbar"),r.controls=[],r.handlers={},Object.keys(r.options.handlers).forEach(function(t){r.addHandler(t,r.options.handlers[t])}),[].forEach.call(r.container.querySelectorAll("button, select"),function(t){r.attach(t)}),r.quill.on(g.default.events.EDITOR_CHANGE,function(t,e){t===g.default.events.SELECTION_CHANGE&&r.update(e)}),r.quill.on(g.default.events.SCROLL_OPTIMIZE,function(){var t=r.quill.selection.getRange(),e=f(t,1),n=e[0];r.update(n)}),r}return a(e,t),h(e,[{key:"addHandler",value:function(t,e){this.handlers[t]=e}},{key:"attach",value:function(t){var e=this,n=[].find.call(t.classList,function(t){return 0===t.indexOf("ql-")});if(n){if(n=n.slice("ql-".length),"BUTTON"===t.tagName&&t.setAttribute("type","button"),null==this.handlers[n]){if(null!=this.quill.scroll.whitelist&&null==this.quill.scroll.whitelist[n])return void x.warn("ignoring attaching to disabled format",n,t);if(null==v.default.query(n))return void x.warn("ignoring attaching to nonexistent format",n,t)}var r="SELECT"===t.tagName?"change":"click";t.addEventListener(r,function(r){var i=void 0;if("SELECT"===t.tagName){if(t.selectedIndex<0)return;var l=t.options[t.selectedIndex];i=!l.hasAttribute("selected")&&(l.value||!1)}else i=!t.classList.contains("ql-active")&&(t.value||!t.hasAttribute("value")),r.preventDefault();e.quill.focus();var a=e.quill.selection.getRange(),s=f(a,1),u=s[0];if(null!=e.handlers[n])e.handlers[n].call(e,i);else if(v.default.query(n).prototype instanceof v.default.Embed){if(!(i=prompt("Enter "+n)))return;e.quill.updateContents((new d.default).retain(u.index).delete(u.length).insert(o({},n,i)),g.default.sources.USER)}else e.quill.format(n,i,g.default.sources.USER);e.update(u)}),this.controls.push([n,t])}}},{key:"update",value:function(t){var e=null==t?{}:this.quill.getFormat(t);this.controls.forEach(function(n){var r=f(n,2),o=r[0],i=r[1];if("SELECT"===i.tagName){var l=void 0;if(null==t)l=null;else if(null==e[o])l=i.querySelector("option[selected]");else if(!Array.isArray(e[o])){var a=e[o];"string"==typeof a&&(a=a.replace(/\"/g,'\\"')),l=i.querySelector('option[value="'+a+'"]')}null==l?(i.value="",i.selectedIndex=-1):l.selected=!0}else if(null==t)i.classList.remove("ql-active");else if(i.hasAttribute("value")){var s=e[o]===i.getAttribute("value")||null!=e[o]&&e[o].toString()===i.getAttribute("value")||null==e[o]&&!i.getAttribute("value");i.classList.toggle("ql-active",s)}else i.classList.toggle("ql-active",null!=e[o])})}}]),e}(w.default);k.DEFAULTS={},k.DEFAULTS={container:null,handlers:{clean:function(){var t=this,e=this.quill.getSelection();if(null!=e)if(0==e.length){var n=this.quill.getFormat();Object.keys(n).forEach(function(e){null!=v.default.query(e,v.default.Scope.INLINE)&&t.quill.format(e,!1)})}else this.quill.removeFormat(e,g.default.sources.USER)},direction:function(t){var e=this.quill.getFormat().align;"rtl"===t&&null==e?this.quill.format("align","right",g.default.sources.USER):t||"right"!==e||this.quill.format("align",!1,g.default.sources.USER),this.quill.format("direction",t,g.default.sources.USER)},indent:function(t){var e=this.quill.getSelection(),n=this.quill.getFormat(e),r=parseInt(n.indent||0);if("+1"===t||"-1"===t){var o="+1"===t?1:-1;"rtl"===n.direction&&(o*=-1),this.quill.format("indent",r+o,g.default.sources.USER)}},link:function(t){!0===t&&(t=prompt("Enter link URL:")),this.quill.format("link",t,g.default.sources.USER)},list:function(t){var e=this.quill.getSelection(),n=this.quill.getFormat(e);"check"===t?"checked"===n.list||"unchecked"===n.list?this.quill.format("list",!1,g.default.sources.USER):this.quill.format("list","unchecked",g.default.sources.USER):this.quill.format("list",t,g.default.sources.USER)}}},e.default=k,e.addControls=u},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=3 x2=13 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=9 y1=4 y2=4></line> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=14 x2=4 y1=14 y2=14></line> <line class=ql-stroke x1=12 x2=6 y1=4 y2=4></line> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=15 x2=5 y1=14 y2=14></line> <line class=ql-stroke x1=15 x2=9 y1=4 y2=4></line> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=15 x2=3 y1=14 y2=14></line> <line class=ql-stroke x1=15 x2=3 y1=4 y2=4></line> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <g class="ql-fill ql-color-label"> <polygon points="6 6.868 6 6 5 6 5 7 5.942 7 6 6.868"></polygon> <rect height=1 width=1 x=4 y=4></rect> <polygon points="6.817 5 6 5 6 6 6.38 6 6.817 5"></polygon> <rect height=1 width=1 x=2 y=6></rect> <rect height=1 width=1 x=3 y=5></rect> <rect height=1 width=1 x=4 y=7></rect> <polygon points="4 11.439 4 11 3 11 3 12 3.755 12 4 11.439"></polygon> <rect height=1 width=1 x=2 y=12></rect> <rect height=1 width=1 x=2 y=9></rect> <rect height=1 width=1 x=2 y=15></rect> <polygon points="4.63 10 4 10 4 11 4.192 11 4.63 10"></polygon> <rect height=1 width=1 x=3 y=8></rect> <path d=M10.832,4.2L11,4.582V4H10.708A1.948,1.948,0,0,1,10.832,4.2Z></path> <path d=M7,4.582L7.168,4.2A1.929,1.929,0,0,1,7.292,4H7V4.582Z></path> <path d=M8,13H7.683l-0.351.8a1.933,1.933,0,0,1-.124.2H8V13Z></path> <rect height=1 width=1 x=12 y=2></rect> <rect height=1 width=1 x=11 y=3></rect> <path d=M9,3H8V3.282A1.985,1.985,0,0,1,9,3Z></path> <rect height=1 width=1 x=2 y=3></rect> <rect height=1 width=1 x=6 y=2></rect> <rect height=1 width=1 x=3 y=2></rect> <rect height=1 width=1 x=5 y=3></rect> <rect height=1 width=1 x=9 y=2></rect> <rect height=1 width=1 x=15 y=14></rect> <polygon points="13.447 10.174 13.469 10.225 13.472 10.232 13.808 11 14 11 14 10 13.37 10 13.447 10.174"></polygon> <rect height=1 width=1 x=13 y=7></rect> <rect height=1 width=1 x=15 y=5></rect> <rect height=1 width=1 x=14 y=6></rect> <rect height=1 width=1 x=15 y=8></rect> <rect height=1 width=1 x=14 y=9></rect> <path d=M3.775,14H3v1H4V14.314A1.97,1.97,0,0,1,3.775,14Z></path> <rect height=1 width=1 x=14 y=3></rect> <polygon points="12 6.868 12 6 11.62 6 12 6.868"></polygon> <rect height=1 width=1 x=15 y=2></rect> <rect height=1 width=1 x=12 y=5></rect> <rect height=1 width=1 x=13 y=4></rect> <polygon points="12.933 9 13 9 13 8 12.495 8 12.933 9"></polygon> <rect height=1 width=1 x=9 y=14></rect> <rect height=1 width=1 x=8 y=15></rect> <path d=M6,14.926V15H7V14.316A1.993,1.993,0,0,1,6,14.926Z></path> <rect height=1 width=1 x=5 y=15></rect> <path d=M10.668,13.8L10.317,13H10v1h0.792A1.947,1.947,0,0,1,10.668,13.8Z></path> <rect height=1 width=1 x=11 y=15></rect> <path d=M14.332,12.2a1.99,1.99,0,0,1,.166.8H15V12H14.245Z></path> <rect height=1 width=1 x=14 y=15></rect> <rect height=1 width=1 x=15 y=11></rect> </g> <polyline class=ql-stroke points="5.5 13 9 5 12.5 13"></polyline> <line class=ql-stroke x1=11.63 x2=6.38 y1=11 y2=11></line> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <rect class="ql-fill ql-stroke" height=3 width=3 x=4 y=5></rect> <rect class="ql-fill ql-stroke" height=3 width=3 x=11 y=5></rect> <path class="ql-even ql-fill ql-stroke" d=M7,8c0,4.031-3,5-3,5></path> <path class="ql-even ql-fill ql-stroke" d=M14,8c0,4.031-3,5-3,5></path> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-stroke d=M5,4H9.5A2.5,2.5,0,0,1,12,6.5v0A2.5,2.5,0,0,1,9.5,9H5A0,0,0,0,1,5,9V4A0,0,0,0,1,5,4Z></path> <path class=ql-stroke d=M5,9h5.5A2.5,2.5,0,0,1,13,11.5v0A2.5,2.5,0,0,1,10.5,14H5a0,0,0,0,1,0,0V9A0,0,0,0,1,5,9Z></path> </svg>'},function(t,e){t.exports='<svg class="" viewbox="0 0 18 18"> <line class=ql-stroke x1=5 x2=13 y1=3 y2=3></line> <line class=ql-stroke x1=6 x2=9.35 y1=12 y2=3></line> <line class=ql-stroke x1=11 x2=15 y1=11 y2=15></line> <line class=ql-stroke x1=15 x2=11 y1=11 y2=15></line> <rect class=ql-fill height=1 rx=0.5 ry=0.5 width=7 x=2 y=14></rect> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class="ql-color-label ql-stroke ql-transparent" x1=3 x2=15 y1=15 y2=15></line> <polyline class=ql-stroke points="5.5 11 9 3 12.5 11"></polyline> <line class=ql-stroke x1=11.63 x2=6.38 y1=9 y2=9></line> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <polygon class="ql-stroke ql-fill" points="3 11 5 9 3 7 3 11"></polygon> <line class="ql-stroke ql-fill" x1=15 x2=11 y1=4 y2=4></line> <path class=ql-fill d=M11,3a3,3,0,0,0,0,6h1V3H11Z></path> <rect class=ql-fill height=11 width=1 x=11 y=4></rect> <rect class=ql-fill height=11 width=1 x=13 y=4></rect> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <polygon class="ql-stroke ql-fill" points="15 12 13 10 15 8 15 12"></polygon> <line class="ql-stroke ql-fill" x1=9 x2=5 y1=4 y2=4></line> <path class=ql-fill d=M5,3A3,3,0,0,0,5,9H6V3H5Z></path> <rect class=ql-fill height=11 width=1 x=5 y=4></rect> <rect class=ql-fill height=11 width=1 x=7 y=4></rect> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M14,16H4a1,1,0,0,1,0-2H14A1,1,0,0,1,14,16Z /> <path class=ql-fill d=M14,4H4A1,1,0,0,1,4,2H14A1,1,0,0,1,14,4Z /> <rect class=ql-fill x=3 y=6 width=12 height=6 rx=1 ry=1 /> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M13,16H5a1,1,0,0,1,0-2h8A1,1,0,0,1,13,16Z /> <path class=ql-fill d=M13,4H5A1,1,0,0,1,5,2h8A1,1,0,0,1,13,4Z /> <rect class=ql-fill x=2 y=6 width=14 height=6 rx=1 ry=1 /> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15,8H13a1,1,0,0,1,0-2h2A1,1,0,0,1,15,8Z /> <path class=ql-fill d=M15,12H13a1,1,0,0,1,0-2h2A1,1,0,0,1,15,12Z /> <path class=ql-fill d=M15,16H5a1,1,0,0,1,0-2H15A1,1,0,0,1,15,16Z /> <path class=ql-fill d=M15,4H5A1,1,0,0,1,5,2H15A1,1,0,0,1,15,4Z /> <rect class=ql-fill x=2 y=6 width=8 height=6 rx=1 ry=1 /> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M5,8H3A1,1,0,0,1,3,6H5A1,1,0,0,1,5,8Z /> <path class=ql-fill d=M5,12H3a1,1,0,0,1,0-2H5A1,1,0,0,1,5,12Z /> <path class=ql-fill d=M13,16H3a1,1,0,0,1,0-2H13A1,1,0,0,1,13,16Z /> <path class=ql-fill d=M13,4H3A1,1,0,0,1,3,2H13A1,1,0,0,1,13,4Z /> <rect class=ql-fill x=8 y=6 width=8 height=6 rx=1 ry=1 transform="translate(24 18) rotate(-180)"/> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M11.759,2.482a2.561,2.561,0,0,0-3.53.607A7.656,7.656,0,0,0,6.8,6.2C6.109,9.188,5.275,14.677,4.15,14.927a1.545,1.545,0,0,0-1.3-.933A0.922,0.922,0,0,0,2,15.036S1.954,16,4.119,16s3.091-2.691,3.7-5.553c0.177-.826.36-1.726,0.554-2.6L8.775,6.2c0.381-1.421.807-2.521,1.306-2.676a1.014,1.014,0,0,0,1.02.56A0.966,0.966,0,0,0,11.759,2.482Z></path> <rect class=ql-fill height=1.6 rx=0.8 ry=0.8 width=5 x=5.15 y=6.2></rect> <path class=ql-fill d=M13.663,12.027a1.662,1.662,0,0,1,.266-0.276q0.193,0.069.456,0.138a2.1,2.1,0,0,0,.535.069,1.075,1.075,0,0,0,.767-0.3,1.044,1.044,0,0,0,.314-0.8,0.84,0.84,0,0,0-.238-0.619,0.8,0.8,0,0,0-.594-0.239,1.154,1.154,0,0,0-.781.3,4.607,4.607,0,0,0-.781,1q-0.091.15-.218,0.346l-0.246.38c-0.068-.288-0.137-0.582-0.212-0.885-0.459-1.847-2.494-.984-2.941-0.8-0.482.2-.353,0.647-0.094,0.529a0.869,0.869,0,0,1,1.281.585c0.217,0.751.377,1.436,0.527,2.038a5.688,5.688,0,0,1-.362.467,2.69,2.69,0,0,1-.264.271q-0.221-.08-0.471-0.147a2.029,2.029,0,0,0-.522-0.066,1.079,1.079,0,0,0-.768.3A1.058,1.058,0,0,0,9,15.131a0.82,0.82,0,0,0,.832.852,1.134,1.134,0,0,0,.787-0.3,5.11,5.11,0,0,0,.776-0.993q0.141-.219.215-0.34c0.046-.076.122-0.194,0.223-0.346a2.786,2.786,0,0,0,.918,1.726,2.582,2.582,0,0,0,2.376-.185c0.317-.181.212-0.565,0-0.494A0.807,0.807,0,0,1,14.176,15a5.159,5.159,0,0,1-.913-2.446l0,0Q13.487,12.24,13.663,12.027Z></path> </svg>'},function(t,e){t.exports='<svg viewBox="0 0 18 18"> <path class=ql-fill d=M10,4V14a1,1,0,0,1-2,0V10H3v4a1,1,0,0,1-2,0V4A1,1,0,0,1,3,4V8H8V4a1,1,0,0,1,2,0Zm6.06787,9.209H14.98975V7.59863a.54085.54085,0,0,0-.605-.60547h-.62744a1.01119,1.01119,0,0,0-.748.29688L11.645,8.56641a.5435.5435,0,0,0-.022.8584l.28613.30762a.53861.53861,0,0,0,.84717.0332l.09912-.08789a1.2137,1.2137,0,0,0,.2417-.35254h.02246s-.01123.30859-.01123.60547V13.209H12.041a.54085.54085,0,0,0-.605.60547v.43945a.54085.54085,0,0,0,.605.60547h4.02686a.54085.54085,0,0,0,.605-.60547v-.43945A.54085.54085,0,0,0,16.06787,13.209Z /> </svg>'},function(t,e){t.exports='<svg viewBox="0 0 18 18"> <path class=ql-fill d=M16.73975,13.81445v.43945a.54085.54085,0,0,1-.605.60547H11.855a.58392.58392,0,0,1-.64893-.60547V14.0127c0-2.90527,3.39941-3.42187,3.39941-4.55469a.77675.77675,0,0,0-.84717-.78125,1.17684,1.17684,0,0,0-.83594.38477c-.2749.26367-.561.374-.85791.13184l-.4292-.34082c-.30811-.24219-.38525-.51758-.1543-.81445a2.97155,2.97155,0,0,1,2.45361-1.17676,2.45393,2.45393,0,0,1,2.68408,2.40918c0,2.45312-3.1792,2.92676-3.27832,3.93848h2.79443A.54085.54085,0,0,1,16.73975,13.81445ZM9,3A.99974.99974,0,0,0,8,4V8H3V4A1,1,0,0,0,1,4V14a1,1,0,0,0,2,0V10H8v4a1,1,0,0,0,2,0V4A.99974.99974,0,0,0,9,3Z /> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=13 y1=4 y2=4></line> <line class=ql-stroke x1=5 x2=11 y1=14 y2=14></line> <line class=ql-stroke x1=8 x2=10 y1=14 y2=4></line> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <rect class=ql-stroke height=10 width=12 x=3 y=4></rect> <circle class=ql-fill cx=6 cy=7 r=1></circle> <polyline class="ql-even ql-fill" points="5 12 5 11 7 9 8 10 11 7 13 9 13 12 5 12"></polyline> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class="ql-fill ql-stroke" points="3 7 3 11 5 9 3 7"></polyline> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class=ql-stroke points="5 7 5 11 3 9 5 7"></polyline> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=11 y1=7 y2=11></line> <path class="ql-even ql-stroke" d=M8.9,4.577a3.476,3.476,0,0,1,.36,4.679A3.476,3.476,0,0,1,4.577,8.9C3.185,7.5,2.035,6.4,4.217,4.217S7.5,3.185,8.9,4.577Z></path> <path class="ql-even ql-stroke" d=M13.423,9.1a3.476,3.476,0,0,0-4.679-.36,3.476,3.476,0,0,0,.36,4.679c1.392,1.392,2.5,2.542,4.679.36S14.815,10.5,13.423,9.1Z></path> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=7 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=7 x2=15 y1=14 y2=14></line> <line class="ql-stroke ql-thin" x1=2.5 x2=4.5 y1=5.5 y2=5.5></line> <path class=ql-fill d=M3.5,6A0.5,0.5,0,0,1,3,5.5V3.085l-0.276.138A0.5,0.5,0,0,1,2.053,3c-0.124-.247-0.023-0.324.224-0.447l1-.5A0.5,0.5,0,0,1,4,2.5v3A0.5,0.5,0,0,1,3.5,6Z></path> <path class="ql-stroke ql-thin" d=M4.5,10.5h-2c0-.234,1.85-1.076,1.85-2.234A0.959,0.959,0,0,0,2.5,8.156></path> <path class="ql-stroke ql-thin" d=M2.5,14.846a0.959,0.959,0,0,0,1.85-.109A0.7,0.7,0,0,0,3.75,14a0.688,0.688,0,0,0,.6-0.736,0.959,0.959,0,0,0-1.85-.109></path> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=6 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=6 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=6 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=3 y1=4 y2=4></line> <line class=ql-stroke x1=3 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=3 x2=3 y1=14 y2=14></line> </svg>'},function(t,e){t.exports='<svg class="" viewbox="0 0 18 18"> <line class=ql-stroke x1=9 x2=15 y1=4 y2=4></line> <polyline class=ql-stroke points="3 4 4 5 6 3"></polyline> <line class=ql-stroke x1=9 x2=15 y1=14 y2=14></line> <polyline class=ql-stroke points="3 14 4 15 6 13"></polyline> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class=ql-stroke points="3 9 4 10 6 8"></polyline> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15.5,15H13.861a3.858,3.858,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.921,1.921,0,0,0,12.021,11.7a0.50013,0.50013,0,1,0,.957.291h0a0.914,0.914,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.076-1.16971,1.86982-1.93971,2.43082A1.45639,1.45639,0,0,0,12,15.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,15Z /> <path class=ql-fill d=M9.65,5.241a1,1,0,0,0-1.409.108L6,7.964,3.759,5.349A1,1,0,0,0,2.192,6.59178Q2.21541,6.6213,2.241,6.649L4.684,9.5,2.241,12.35A1,1,0,0,0,3.71,13.70722q0.02557-.02768.049-0.05722L6,11.036,8.241,13.65a1,1,0,1,0,1.567-1.24277Q9.78459,12.3777,9.759,12.35L7.316,9.5,9.759,6.651A1,1,0,0,0,9.65,5.241Z /> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15.5,7H13.861a4.015,4.015,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.922,1.922,0,0,0,12.021,3.7a0.5,0.5,0,1,0,.957.291,0.917,0.917,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.077-1.164,1.925-1.934,2.486A1.423,1.423,0,0,0,12,7.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,7Z /> <path class=ql-fill d=M9.651,5.241a1,1,0,0,0-1.41.108L6,7.964,3.759,5.349a1,1,0,1,0-1.519,1.3L4.683,9.5,2.241,12.35a1,1,0,1,0,1.519,1.3L6,11.036,8.241,13.65a1,1,0,0,0,1.519-1.3L7.317,9.5,9.759,6.651A1,1,0,0,0,9.651,5.241Z /> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class="ql-stroke ql-thin" x1=15.5 x2=2.5 y1=8.5 y2=9.5></line> <path class=ql-fill d=M9.007,8C6.542,7.791,6,7.519,6,6.5,6,5.792,7.283,5,9,5c1.571,0,2.765.679,2.969,1.309a1,1,0,0,0,1.9-.617C13.356,4.106,11.354,3,9,3,6.2,3,4,4.538,4,6.5a3.2,3.2,0,0,0,.5,1.843Z></path> <path class=ql-fill d=M8.984,10C11.457,10.208,12,10.479,12,11.5c0,0.708-1.283,1.5-3,1.5-1.571,0-2.765-.679-2.969-1.309a1,1,0,1,0-1.9.617C4.644,13.894,6.646,15,9,15c2.8,0,5-1.538,5-3.5a3.2,3.2,0,0,0-.5-1.843Z></path> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-stroke d=M5,3V9a4.012,4.012,0,0,0,4,4H9a4.012,4.012,0,0,0,4-4V3></path> <rect class=ql-fill height=1 rx=0.5 ry=0.5 width=12 x=3 y=15></rect> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <rect class=ql-stroke height=12 width=12 x=3 y=3></rect> <rect class=ql-fill height=12 width=1 x=5 y=3></rect> <rect class=ql-fill height=12 width=1 x=12 y=3></rect> <rect class=ql-fill height=2 width=8 x=5 y=8></rect> <rect class=ql-fill height=1 width=3 x=3 y=5></rect> <rect class=ql-fill height=1 width=3 x=3 y=7></rect> <rect class=ql-fill height=1 width=3 x=3 y=10></rect> <rect class=ql-fill height=1 width=3 x=3 y=12></rect> <rect class=ql-fill height=1 width=3 x=12 y=5></rect> <rect class=ql-fill height=1 width=3 x=12 y=7></rect> <rect class=ql-fill height=1 width=3 x=12 y=10></rect> <rect class=ql-fill height=1 width=3 x=12 y=12></rect> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <polygon class=ql-stroke points="7 11 9 13 11 11 7 11"></polygon> <polygon class=ql-stroke points="7 7 9 5 11 7 7 7"></polygon> </svg>'},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.BubbleTooltip=void 0;var a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),u=n(2),c=r(u),f=n(9),h=r(f),p=n(44),d=r(p),y=n(22),v=n(26),b=r(v),g=[["bold","italic","link"],[{header:1},{header:2},"blockquote"]],m=function(t){function e(t,n){o(this,e),null!=n.modules.toolbar&&null==n.modules.toolbar.container&&(n.modules.toolbar.container=g);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.quill.container.classList.add("ql-bubble"),r}return l(e,t),s(e,[{key:"extendToolbar",value:function(t){this.tooltip=new _(this.quill,this.options.bounds),this.tooltip.root.appendChild(t.container),this.buildButtons([].slice.call(t.container.querySelectorAll("button")),b.default),this.buildPickers([].slice.call(t.container.querySelectorAll("select")),b.default)}}]),e}(d.default);m.DEFAULTS=(0,c.default)(!0,{},d.default.DEFAULTS,{modules:{toolbar:{handlers:{link:function(t){t?this.quill.theme.tooltip.edit():this.quill.format("link",!1)}}}}});var _=function(t){function e(t,n){o(this,e);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.quill.on(h.default.events.EDITOR_CHANGE,function(t,e,n,o){if(t===h.default.events.SELECTION_CHANGE)if(null!=e&&e.length>0&&o===h.default.sources.USER){r.show(),r.root.style.left="0px",r.root.style.width="",r.root.style.width=r.root.offsetWidth+"px";var i=r.quill.getLines(e.index,e.length);if(1===i.length)r.position(r.quill.getBounds(e));else{var l=i[i.length-1],a=r.quill.getIndex(l),s=Math.min(l.length()-1,e.index+e.length-a),u=r.quill.getBounds(new y.Range(a,s));r.position(u)}}else document.activeElement!==r.textbox&&r.quill.hasFocus()&&r.hide()}),r}return l(e,t),s(e,[{key:"listen",value:function(){var t=this;a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"listen",this).call(this),this.root.querySelector(".ql-close").addEventListener("click",function(){t.root.classList.remove("ql-editing")}),this.quill.on(h.default.events.SCROLL_OPTIMIZE,function(){setTimeout(function(){if(!t.root.classList.contains("ql-hidden")){var e=t.quill.getSelection();null!=e&&t.position(t.quill.getBounds(e))}},1)})}},{key:"cancel",value:function(){this.show()}},{key:"position",value:function(t){var n=a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"position",this).call(this,t),r=this.root.querySelector(".ql-tooltip-arrow");if(r.style.marginLeft="",0===n)return n;r.style.marginLeft=-1*n-r.offsetWidth/2+"px"}}]),e}(p.BaseTooltip);_.TEMPLATE=['<span class="ql-tooltip-arrow"></span>','<div class="ql-tooltip-editor">','<input type="text" data-formula="e=mc^2" data-link="https://quilljs.com" data-video="Embed URL">','<a class="ql-close"></a>',"</div>"].join(""),e.BubbleTooltip=_,e.default=m},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var a=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),s=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},u=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),c=n(2),f=r(c),h=n(9),p=r(h),d=n(44),y=r(d),v=n(15),b=r(v),g=n(22),m=n(26),_=r(m),O=[[{header:["1","2","3",!1]}],["bold","italic","underline","link"],[{list:"ordered"},{list:"bullet"}],["clean"]],w=function(t){function e(t,n){o(this,e),null!=n.modules.toolbar&&null==n.modules.toolbar.container&&(n.modules.toolbar.container=O);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.quill.container.classList.add("ql-snow"),r}return l(e,t),u(e,[{key:"extendToolbar",value:function(t){t.container.classList.add("ql-snow"),this.buildButtons([].slice.call(t.container.querySelectorAll("button")),_.default),this.buildPickers([].slice.call(t.container.querySelectorAll("select")),_.default),this.tooltip=new x(this.quill,this.options.bounds),t.container.querySelector(".ql-link")&&this.quill.keyboard.addBinding({key:"K",shortKey:!0},function(e,n){t.handlers.link.call(t,!n.format.link)})}}]),e}(y.default);w.DEFAULTS=(0,f.default)(!0,{},y.default.DEFAULTS,{modules:{toolbar:{handlers:{link:function(t){if(t){var e=this.quill.getSelection();if(null==e||0==e.length)return;var n=this.quill.getText(e);/^\S+@\S+\.\S+$/.test(n)&&0!==n.indexOf("mailto:")&&(n="mailto:"+n);this.quill.theme.tooltip.edit("link",n)}else this.quill.format("link",!1)}}}}});var x=function(t){function e(t,n){o(this,e);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.preview=r.root.querySelector("a.ql-preview"),r}return l(e,t),u(e,[{key:"listen",value:function(){var t=this;s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"listen",this).call(this),this.root.querySelector("a.ql-action").addEventListener("click",function(e){t.root.classList.contains("ql-editing")?t.save():t.edit("link",t.preview.textContent),e.preventDefault()}),this.root.querySelector("a.ql-remove").addEventListener("click",function(e){if(null!=t.linkRange){var n=t.linkRange;t.restoreFocus(),t.quill.formatText(n,"link",!1,p.default.sources.USER),delete t.linkRange}e.preventDefault(),t.hide()}),this.quill.on(p.default.events.SELECTION_CHANGE,function(e,n,r){if(null!=e){if(0===e.length&&r===p.default.sources.USER){var o=t.quill.scroll.descendant(b.default,e.index),i=a(o,2),l=i[0],s=i[1];if(null!=l){t.linkRange=new g.Range(e.index-s,l.length());var u=b.default.formats(l.domNode);return t.preview.textContent=u,t.preview.setAttribute("href",u),t.show(),void t.position(t.quill.getBounds(t.linkRange))}}else delete t.linkRange;t.hide()}})}},{key:"show",value:function(){s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"show",this).call(this),this.root.removeAttribute("data-mode")}}]),e}(d.BaseTooltip);x.TEMPLATE=['<a class="ql-preview" target="_blank" href="about:blank"></a>','<input type="text" data-formula="e=mc^2" data-link="https://example.com" data-video="Embed URL">','<a class="ql-action"></a>','<a class="ql-remove"></a>'].join(""),e.default=w}]).default});
5
  /* wpdEditor */
6
- "use strict";function _typeof(t){return(_typeof="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})(t)}function _get(t,e,i){return(_get="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(t,e,i){var n=_superPropBase(t,e);if(n){var r=Object.getOwnPropertyDescriptor(n,e);return r.get?r.get.call(i):r.value}})(t,e,i||t)}function _superPropBase(t,e){for(;!Object.prototype.hasOwnProperty.call(t,e)&&null!==(t=_getPrototypeOf(t)););return t}function _inherits(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&&_setPrototypeOf(t,e)}function _setPrototypeOf(t,e){return(_setPrototypeOf=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function _createSuper(t){var e=_isNativeReflectConstruct();return function(){var i,n=_getPrototypeOf(t);if(e){var r=_getPrototypeOf(this).constructor;i=Reflect.construct(n,arguments,r)}else i=n.apply(this,arguments);return _possibleConstructorReturn(this,i)}}function _possibleConstructorReturn(t,e){return!e||"object"!==_typeof(e)&&"function"!=typeof e?_assertThisInitialized(t):e}function _assertThisInitialized(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function _isNativeReflectConstruct(){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 _getPrototypeOf(t){return(_getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function _instanceof(t,e){return null!=e&&"undefined"!=typeof Symbol&&e[Symbol.hasInstance]?!!e[Symbol.hasInstance](t):t instanceof e}function _classCallCheck(t,e){if(!_instanceof(t,e))throw new TypeError("Cannot call a class as a function")}function _defineProperties(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function _createClass(t,e,i){return e&&_defineProperties(t.prototype,e),i&&_defineProperties(t,i),t}var wpdEditorCounter=function(){function t(e,i){_classCallCheck(this,t),this.quill=e,this.options=i,this.maxCount=i.maxcount,this.minCount=i.mincount,this.container=document.getElementById("wpd-editor-char-counter-"+i.uniqueID),this.submit=document.getElementById("wpd-field-submit-"+i.uniqueID),e.on("editor-change",this.update.bind(this)),this.update()}return _createClass(t,[{key:"calculate",value:function(){var t=this.quill.getText().length,e=this.quill.container.id,i=document.querySelectorAll("#".concat(e," .ql-editor img"));return i.length&&i.forEach(function(e){null!==e.src.match(/https\:\/\/s\.w\.org\/images\/core\/emoji/gi)?t+=e.alt.length:e.classList.contains("wpdem-sticker")?t+=e.alt.length:t+=e.src.length}),t}},{key:"update",value:function(){var t=this.calculate(),e=t-1;if(this.maxCount>0&&t>=this.maxCount&&this.quill.deleteText(this.maxCount,t),this.maxCount>0){var i=this.maxCount-e;this.container.innerText=i>=0?i:0,t+10>this.maxCount?this.container.classList.add("error"):this.container.classList.remove("error")}else this.container.remove()}}]),t}();Quill.register("modules/counter",wpdEditorCounter);var Link=Quill.import("formats/link"),wpdEditorLink=function(t){_inherits(i,Link);var e=_createSuper(i);function i(){return _classCallCheck(this,i),e.apply(this,arguments)}return _createClass(i,null,[{key:"create",value:function(t){var e=_get(_getPrototypeOf(i),"create",this).call(this,t);t=this.sanitize(t),e.setAttribute("href",t);var n=location.protocol+"//"+location.hostname;return(t.startsWith(n)||"#"===t.charAt(0)||"/"===t.charAt(0)&&"/"!==t.charAt(1))&&e.removeAttribute("target"),e}},{key:"sanitize",value:function(t){var e=_get(_getPrototypeOf(i),"sanitize",this).call(this,t),n=e.slice(0,e.indexOf(":"));return"#"!==e.charAt(0)&&"/"!==e.charAt(0)&&-1===this.PROTOCOL_WHITELIST.indexOf(n)&&(e="http://"+t),e}}]),i}();Quill.register(wpdEditorLink,!0);var WpdEditor=function(){function t(){_classCallCheck(this,t),this.editorWraperPrefix="wpd-editor-wraper",this.textEditorContainer="ql-texteditor",this.textEditorPrefix="wc-textarea",this.editorToolbarPrefix="wpd-editor-toolbar",this.sourceCodeButtonName="sourcecode",this.spoiler="spoiler",this.spoilerPromtTitle=wpdiscuzAjaxObj.wc_spoiler_title,this._container="",this._uniqueid="",this.currentEditor=null,this._editors=new Map,this._handlers=new Map,this._initDefaults()}return _createClass(t,[{key:"addButtonEventHandler",value:function(t,e){this._handlers.set(t,e)}},{key:"createEditor",value:function(t){var e=this;if(this.container=t,this._editors.has(this.uniqueid))this.currentEditor=this._editors.get(this.uniqueid);else{var i="#".concat(this.editorToolbarPrefix,"-").concat(this.uniqueid);wpdiscuzEditorOptions.modules.toolbar=i,wpdiscuzEditorOptions.modules.counter.uniqueID=this.uniqueid;var n=new Quill(this.container,wpdiscuzEditorOptions);n.on("editor-change",function(t){null!==(arguments.length<=1?void 0:arguments[1])&&(e.currentEditor=n,e.container=n.container.id)}),n.clipboard.addMatcher("PRE",function(t,i){return new(Quill.import("delta"))([{insert:e._htmlEntities(t.innerHTML),attributes:{"code-block":!0}}])}),n.clipboard.addMatcher("a",function(t,e){return t.getAttribute("href")===t.innerHTML?new(Quill.import("delta"))([{insert:t.innerHTML}]):e}),document.querySelectorAll("".concat(i," button")).forEach(function(t){t.onclick=function(){e.currentEditor=n,e.container=n.container.id;var i=t.dataset.wpde_button_name;void 0!==i&&"string"==typeof i&&""!==i.trim()&&e._handlers.has(i)&&e._handlers.get(i)(e.currentEditor,e.uniqueid)}}),this._bindTextEditor(n),this._editors.set(this.uniqueid,n),document.getElementById("".concat(this.editorWraperPrefix,"-").concat(this.uniqueid)).style.display=""}return this.currentEditor}},{key:"_htmlEntities",value:function(t){var e=document.createElement("textarea");return e.innerHTML=t,e.value.replace(/<\!\-\-\?php/g,"<?php").replace(/\?\-\->/g,"?>").replace(/\-\-\->/g,"->")}},{key:"removeEditor",value:function(t){this.container=t,this._editors.has(this.uniqueid)&&this._editors.delete(this.uniqueid)}},{key:"_bindTextEditor",value:function(t){var e="".concat(this.textEditorPrefix,"-").concat(this.uniqueid),i=document.getElementById(e);i.style.cssText="display: none;",t.addContainer(this.textEditorContainer).appendChild(i),t.container.id.indexOf("-edit_")>0&&t.clipboard.dangerouslyPasteHTML(0,i.value),this.currentEditor=t}},{key:"_findUniqueId",value:function(){return this.container.substring(this.container.lastIndexOf("-")+1)}},{key:"_initDefaults",value:function(){var t=this;this.addButtonEventHandler(this.sourceCodeButtonName,function(e){document.getElementById("".concat(t.textEditorPrefix,"-").concat(t.uniqueid));var i=document.getElementById("wpd-editor-source-code-wrapper-bg"),n=document.getElementById("wpd-editor-source-code-wrapper"),r=document.getElementById("wpd-editor-source-code"),o=document.getElementById("wpd-editor-uid");i.style.display="block",n.style.display="block",o.value=e.container.id,r.value=e.root.innerHTML}),this.addButtonEventHandler(this.spoiler,function(e){var i=prompt(t.spoilerPromtTitle);if(null!==i){var n=' [spoiler title="'.concat(i,'"] '),r=e.getSelection();null===r&&(r={index:e.getLength()-1,length:0}),0===r.length?(e.insertText(r.index,n+" [/spoiler] ",Quill.sources.USER),e.setSelection(r.index+n.length,Quill.sources.USER)):(e.insertText(r.index,n),e.insertText(r.index+n.length+r.length," [/spoiler] ",Quill.sources.USER),e.setSelection(r.index+n.length+r.length+" [/spoiler] ".length,Quill.sources.USER))}})}},{key:"uniqueid",set:function(t){""!==t&&"string"==typeof t?this._uniqueid=t:""===t?this._uniqueid=this._findUniqueId():console.error("Incorrect uniqueid.")},get:function(){return this._uniqueid}},{key:"container",set:function(t){""!==t&&"string"==typeof t?(this._container=t,this.uniqueid=this._findUniqueId()):console.error("Incorrect uniqueid.")},get:function(){return this._container}}]),t}();
7
  /* Autogrow */
8
  jQuery.fn.autoGrow=function(){return this.each(function(){var createMirror=function(textarea){jQuery(textarea).after('<div class="autogrow-textarea-mirror"></div>');return jQuery(textarea).next(".autogrow-textarea-mirror")[0]};var sendContentToMirror=function(textarea){mirror.innerHTML=String(textarea.value).replace(/&/g,"&amp;").replace(/"/g,"&quot;").replace(/'/g,"&#39;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/\n/g,"<br />")+".<br/>.";if(jQuery(textarea).height()!=jQuery(mirror).height())jQuery(textarea).height(jQuery(mirror).height())};var growTextarea=function(){sendContentToMirror(this)};var mirror=createMirror(this);mirror.style.display="none";mirror.style.wordWrap="break-word";mirror.style.padding=jQuery(this).css("padding");mirror.style.width=jQuery(this).css("width");mirror.style.fontFamily=jQuery(this).css("font-family");mirror.style.fontSize=jQuery(this).css("font-size");mirror.style.lineHeight=jQuery(this).css("line-height");this.style.overflow="hidden";this.style.minHeight=this.rows+"em";this.onkeydown=growTextarea;sendContentToMirror(this)})};
9
  /* wpDiscuz */
10
- var wpdiscuzLoadRichEditor=parseInt(wpdiscuzAjaxObj.loadRichEditor);if(wpdiscuzLoadRichEditor)var wpDiscuzEditor=new WpdEditor;function wpdMessagesOnInit(e,t){wpdiscuzAjaxObj.setCommentMessage(e,t),setTimeout(function(){location.href=location.href.substring(0,location.href.indexOf("wpdiscuzUrlAnchor")-1)},3e3)}wpdiscuzAjaxObj.setCommentMessage=function(e,t,a){var o="wpdiscuz-message-error";if("[object Array]"===Object.prototype.toString.call(e))for(var d in e)"[object Array]"===Object.prototype.toString.call(t)?"success"===t[d]?o="wpdiscuz-message-success":"warning"===t[d]&&(o="wpdiscuz-message-warning"):"success"===t?o="wpdiscuz-message-success":"warning"===t&&(o="wpdiscuz-message-warning"),jQuery("<div/>").addClass(o).html(e[d]).prependTo("#wpdiscuz-comment-message").delay("[object Array]"===Object.prototype.toString.call(a)?a[d]:a||4e3).fadeOut(1e3,function(){jQuery(this).remove()});else"success"===t?o="wpdiscuz-message-success":"warning"===t&&(o="wpdiscuz-message-warning"),jQuery("<div/>").addClass(o).html(e).prependTo("#wpdiscuz-comment-message").delay(a||4e3).fadeOut(1e3,function(){jQuery(this).remove()})},jQuery(document).ready(function(e){e("body").addClass("wpdiscuz_"+wpdiscuzAjaxObj.version);var t=wpdiscuzAjaxObj.is_user_logged_in,a=1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!t,o=1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&t,d=wpdiscuzAjaxObj.wpDiscuzReCaptchaVersion,n=parseInt(wpdiscuzAjaxObj.commentListLoadType),i=parseInt(wpdiscuzAjaxObj.wc_post_id),s=parseInt(wpdiscuzAjaxObj.commentListUpdateType),c=1e3*parseInt(wpdiscuzAjaxObj.commentListUpdateTimer),p=parseInt(wpdiscuzAjaxObj.liveUpdateGuests),r=wpdiscuzAjaxObj.loadLastCommentId,l=r,m=parseInt(wpdiscuzAjaxObj.firstLoadWithAjax);Cookies.get("wpdiscuz_comments_sorting")&&Cookies.remove("wpdiscuz_comments_sorting",{path:""}),Cookies.get("wordpress_last_visit")&&Cookies.remove("wordpress_last_visit",{path:""}),Cookies.get("wpdiscuz_last_visit")&&Cookies.remove("wpdiscuz_last_visit",{path:""});var w,u=wpdiscuzAjaxObj.storeCommenterData,f=parseInt(wpdiscuzAjaxObj.wmuEnabled),h=wpdiscuzAjaxObj.isCookiesEnabled,b=!0,g=wpdiscuzAjaxObj.cookiehash,_=parseInt(wpdiscuzAjaxObj.isLoadOnlyParentComments),v=parseInt(wpdiscuzAjaxObj.enableDropAnimation)?500:0,z=parseInt(wpdiscuzAjaxObj.isNativeAjaxEnabled),j=parseInt(wpdiscuzAjaxObj.enableBubble),C=parseInt(wpdiscuzAjaxObj.bubbleLiveUpdate),k=parseInt(wpdiscuzAjaxObj.bubbleHintTimeout),x=parseInt(wpdiscuzAjaxObj.bubbleHintHideTimeout)?parseInt(wpdiscuzAjaxObj.bubbleHintHideTimeout):5,y=parseInt(wpdiscuzAjaxObj.bubbleShowNewCommentMessage),O=wpdiscuzAjaxObj.bubbleLocation,A=wpdiscuzAjaxObj.inlineFeedbackAttractionType,I=[],T=[],D=[],E=!1,M=1;(e(".wc_social_plugin_wrapper .wp-social-login-provider-list").length?e(".wc_social_plugin_wrapper .wp-social-login-provider-list").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .the_champ_login_container").length?e(".wc_social_plugin_wrapper .the_champ_login_container").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .social_connect_form").length?e(".wc_social_plugin_wrapper .social_connect_form").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .oneall_social_login_providers").length&&e(".wc_social_plugin_wrapper .oneall_social_login .oneall_social_login_providers").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"),wpdiscuzLoadRichEditor&&e("#wpd-editor-0_0").length&&wpDiscuzEditor.createEditor("#wpd-editor-0_0"),e(document).delegate("#wpdcom .ql-editor, #wpdcom .wc_comment","focus",function(){e(".wpd-form-foot",e(this).parents(".wpd_comm_form")).slideDown(v)}),e(document).delegate("#wpdcom textarea","focus",function(){e(this).next(".autogrow-textarea-mirror").length||e(this).autoGrow()}),t)||S({comment_author:Cookies.get("comment_author_"+g),comment_author_email:Cookies.get("comment_author_email_"+g),comment_author_url:Cookies.get("comment_author_url_"+g)});if(e(".wpd-vote-down.wpd-dislike-hidden").remove(),e(".wpd-toolbar-hidden").prev("[id^=wpd-editor-]").css("border-bottom","1px solid #dddddd"),e(document).delegate("#wpd-editor-source-code-wrapper-bg","click",function(){e(this).hide(),e("#wpd-editor-source-code-wrapper").hide(),e("#wpd-editor-uid").val(""),e("#wpd-editor-source-code").val("")}),wpdiscuzLoadRichEditor&&e(document).delegate("#wpd-insert-source-code","click",function(){var t=wpDiscuzEditor.createEditor("#"+e("#wpd-editor-uid").val());t.deleteText(0,t.getLength(),Quill.sources.USER);var a=e("#wpd-editor-source-code").val();a.length&&t.clipboard.dangerouslyPasteHTML(0,a,Quill.sources.USER),t.update(),e("#wpd-editor-source-code-wrapper-bg").hide(),e("#wpd-editor-source-code-wrapper").hide(),e("#wpd-editor-uid").val(""),e("#wpd-editor-source-code").val("")}),e(document).delegate(".wpd-reply-button","click",function(){var n=V(e(this),0);e(this).hasClass("wpdiscuz-clonned")?(wpdiscuzLoadRichEditor?setTimeout(function(){wpDiscuzEditor.createEditor("#wpd-editor-"+n).focus()},v):setTimeout(function(){e("#wc-textarea-"+n).trigger("focus")},v),e("#wpd-secondary-form-wrapper-"+n).slideToggle(v)):function(a){var o=V(a,0);e("#wpdiscuz_form_anchor-"+o).before(function(t){return e("#wpdiscuz_hidden_secondary_form").html().replace(/wpdiscuzuniqueid/g,t)}(o));var d=e("#wpd-secondary-form-wrapper-"+o);if(!t){var n={comment_author:Cookies.get("comment_author_"+g),comment_author_email:Cookies.get("comment_author_email_"+g),comment_author_url:Cookies.get("comment_author_url_"+g)};S(n)}wpdiscuzLoadRichEditor?setTimeout(function(){wpDiscuzEditor.createEditor("#wpd-editor-"+o).focus()},v):setTimeout(function(){e("#wc-textarea-"+o).trigger("focus")},v);d.slideToggle(v,function(){a.addClass("wpdiscuz-clonned")})}(e(this)),function(t){if((a||o)&&"2.0"===d){var n=B(t);setTimeout(function(){if(!T[n])try{T[n]=grecaptcha.render("wpdiscuz-recaptcha-"+t,{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(a){e("#wpdiscuz-recaptcha-field-"+t).val("key")},"expired-callback":function(){e("#wpdiscuz-recaptcha-field-"+t).val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}},1e3)}}(n)}),e(document).delegate("#wpdcom .wpd-comment-link [data-comment-url]","click",function(){var t=e(this).data("comment-url"),a=e("<input/>");a.appendTo("body").css({position:"absolute",top:"-10000000px"}).val(t),a.select(),document.execCommand("copy"),a.remove(),wpdiscuzAjaxObj.setCommentMessage(t+"<br/>"+wpdiscuzAjaxObj.wc_copied_to_clipboard,"success",5e3)}),e(document).delegate(".wpdiscuz-nofollow,.wc_captcha_refresh_img,.wpd-load-more-submit","click",function(e){e.preventDefault()}),e(document).delegate(".wpd-toggle.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked");var a=V(e(this),0),o=e(this),d=e(".fas",o);!o.parents(".wpd-comment:not(.wpd-reply)").children(".wpd-reply").length&&_?function(t,a){var o=B(t),d=new FormData;d.append("action","wpdShowReplies"),d.append("commentId",o),ce(z,!0,d).done(function(o){a.addClass("wpd_not_clicked"),"object"==typeof o&&o.success&&(e("#wpd-comm-"+t).replaceWith(o.data.comment_list),e("#wpd-comm-"+t+" .wpd-toggle .fas").removeClass("fa-chevron-down").addClass("fa-chevron-up"),e("#wpd-comm-"+t+" .wpd-toggle").attr("wpd-tooltip",wpdiscuzAjaxObj.wc_hide_replies_text),e("#wpd-comm-"+t+" .wpd-toggle .wpd-view-replies").remove(),se(o)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,o,d){console.log(d),a.addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}(a,t):e("#wpd-comm-"+a+"> .wpd-reply").slideToggle(700,function(){e(this).is(":hidden")?(d.removeClass("fa-chevron-up"),d.addClass("fa-chevron-down"),o.attr("wpd-tooltip",wpdiscuzAjaxObj.wc_show_replies_text)):(d.removeClass("fa-chevron-down"),d.addClass("fa-chevron-up"),o.attr("wpd-tooltip",wpdiscuzAjaxObj.wc_hide_replies_text)),t.addClass("wpd_not_clicked")})}),e(document).delegate(".wpd-new-loaded-comment","mouseenter",function(){e(this).removeClass("wpd-new-loaded-comment")}),e(document).delegate(".wpd-sbs-toggle","click",function(){e(".wpdiscuz-subscribe-bar").slideToggle(v)}),parseInt(wpdiscuzAjaxObj.wpDiscuzIsShowOnSubscribeForm)&&!t&&wpdiscuzAjaxObj.wpDiscuzReCaptchaSK&&("2.0"===d?(setTimeout(function(){try{grecaptcha.render("wpdiscuz-recaptcha-subscribe-form",{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(t){e("#wpdiscuz-recaptcha-field-subscribe-form").val("key")},"expired-callback":function(){e("#wpdiscuz-recaptcha-field-subscribe-form").val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}},1e3),e(document).delegate("#wpdiscuz-subscribe-form","submit",function(t){e("#wpdiscuz-recaptcha-field-subscribe-form").val()?e(".wpdiscuz-recaptcha",e(this)).css("border","none"):(e(".wpdiscuz-recaptcha",e(this)).css("border","1px solid red"),t.preventDefault())})):"3.0"===d&&e(document).delegate("#wpdiscuz_subscription_button","click",function(t){var a=e(this).parents("#wpdiscuz-subscribe-form");t.preventDefault();try{grecaptcha.ready(function(){grecaptcha.execute(wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,{action:"wpdiscuz/wpdAddSubscription"}).then(function(e){console.log(5555),document.getElementById("wpdiscuz-recaptcha-field-subscribe-form").value=e,a.submit()},function(e){wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error","error"),console.log(e)})})}catch(t){console.log(t),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+t.message,"error")}})),(a||o)&&"2.0"===d){var F=e(window).width(),L=e("#wpdcom").width();L>=1100&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"65%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"35%"})),L>=940&&L<1100&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"60%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"40%"})),L>=810&&L<940&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"40%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"60%"})),L>=730&&L<810&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"45%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"55%"})),L>=610&&L<730&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.85)","-webkit-transform":"scale(0.85)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"43%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"55%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"30%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"70%"})),F>650&&(L>=510&&L<610&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"center 0","-webkit-transform-origin":"center 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"35%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"63%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"30%",position:"relative",right:"-60px"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"70%"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"})),L>=470&&L<510&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"center 0","-webkit-transform-origin":"center 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"40%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"60%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd_main_comm_form .wc-form-footer").css({"margin-left":"0px"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"})),L<470&&(e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({margin:"0px auto","transform-origin":"center 0","-webkit-transform-origin":"center 0"}),e("#wpdcom .wpd-form-col-left").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-form-col-right").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"}),e("#wpdcom .wpd-secondary-form-wrapper .wc_notification_checkboxes").css({"text-align":"center"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-field-submit").css({"text-align":"center"})))}function R(t,a,o){ce(z||f,!1,a).done(function(a){if(e(o).addClass("wpd_not_clicked"),"object"==typeof a)if(a.success){"collapsed"===wpdiscuzAjaxObj.commentFormView&&e(".wpd-form-foot",t).slideUp(v),e(".wpd-thread-info").html(a.data.wc_all_comments_count_new_html),a.data.wc_all_comments_count_new=parseInt(a.data.wc_all_comments_count_new),e("#wpd-bubble-all-comments-count").text(a.data.wc_all_comments_count_new),a.data.wc_all_comments_count_new?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide();var d=v;a.data.is_main?X(a.data.message):(d=v+700,e("#wpd-secondary-form-wrapper-"+a.data.uniqueid).slideToggle(700),1==a.data.is_in_same_container?e("#wpd-secondary-form-wrapper-"+a.data.uniqueid).after(a.data.message):e("#wpd-comm-"+a.data.uniqueid).after(a.data.message)),function(e){if(!e.data.held_moderate){var t=new FormData;t.append("action","wpdCheckNotificationType"),t.append("comment_id",e.data.new_comment_id),t.append("email",e.data.comment_author_email),t.append("isParent",e.data.is_main),ce(z,!0,t)}}(a),function(e){if(e.data.redirect>0&&e.data.new_comment_id){var t=new FormData;t.append("action","wpdRedirect"),t.append("commentId",e.data.new_comment_id),ce(z,!0,t).done(function(e){"object"==typeof e&&e.success&&setTimeout(function(){location.href=e.data},2e3)}).fail(function(e,t,a){console.log(a)})}}(a),h&&b?function(t){var a=t.comment_author_email,o=t.comment_author,d=t.comment_author_url;null==u?(Cookies.set("comment_author_email_"+g,a),Cookies.set("comment_author_"+g,o),d.length&&Cookies.set("comment_author_url_"+g,d)):(u=parseInt(u),Cookies.set("comment_author_email_"+g,a,{expires:u,path:"/"}),Cookies.set("comment_author_"+g,o,{expires:u,path:"/"}),d.length&&Cookies.set("comment_author_url_"+g,d,{expires:u,path:"/"}));e(".wpd-cookies-checkbox").length&&e(".wpd-cookies-checkbox").attr("checked","checked")}(a.data):b||e(".wpd-cookies-checkbox").removeAttr("checked"),wpdiscuzLoadRichEditor&&wpDiscuzEditor.createEditor("#wpd-editor-"+e(".wpdiscuz_unique_id",t).val()).setContents([{insert:"\n"}]),t.get(0).reset(),S(a.data),e(".wmu-preview-wrap",t).remove(),I.length&&(I.forEach(function(e){e.parents(".wpd-field-checkbox").remove()}),I=[]),setTimeout(function(){e("html, body").animate({scrollTop:e("#comment-"+a.data.new_comment_id).offset().top-32},1e3)},d),se(a,t)}else a.data&&(wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"),se(a,t));else wpdiscuzAjaxObj.setCommentMessage(a,"error");e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,d){console.log(d),e(o).addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}function S(t){e(".wpd_comm_form .wc_name").val(t.comment_author),t.comment_author_email&&t.comment_author_email.indexOf("@example.com")<0&&e(".wpd_comm_form .wc_email").val(t.comment_author_email),t.comment_author_url&&e(".wpd_comm_form .wc_website").val(t.comment_author_url)}function q(t,a){e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd_editable_comment").show(),e("#wpd-comm-"+t+" .wpdiscuz-edit-form-wrap").replaceWith(a),e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").show()}e(document).delegate(".wc_comm_submit.wpd_not_clicked","click",function(){var t=e(this),n=1,i=e(this).parents("form");if(i.hasClass("wpd_main_comm_form")||(n=function(t){var a=t.attr("class").split(" "),o="";return e.each(a,function(e,t){"wpd_comment_level"===G(t,!1)&&(o=G(t,!0))}),parseInt(o)+1}(e(this).parents(".wpd-comment"))),J(i,"#wpd-editor-"+e(".wpdiscuz_unique_id",i).val()),i.submit(function(e){e.preventDefault()}),""!==e(".wc_comment",i).val().trim()&&"<br>"!==e(".wc_comment",i).val().trim()){if(i[0].checkValidity()&&(c=i,p=!0,"2.0"===d&&e("input[name=wc_captcha]",c).length&&!e("input[name=wc_captcha]",c).val().length?(p=!1,e(".wpdiscuz-recaptcha",c).css("border","1px solid red")):"2.0"===d&&e("input[name=wc_captcha]",c).length&&e(".wpdiscuz-recaptcha",c).css("border","none"),p)){E=!0,function(t){e(".wpd-agreement-checkbox",t).each(function(){e(this).hasClass("wpd_agreement_hide")&&h&&e(this).prop("checked")&&(Cookies.set(e(this).attr("name")+"_"+g,1,{expires:30,path:"/"}),e("input[name="+e(this).attr("name")+"]").each(function(){I.push(e(this))}))})}(i),e(t).removeClass("wpd_not_clicked");var s=new FormData;if(s.append("action","wpdAddComment"),e(":input",i).each(function(){""!=this.name&&"checkbox"!=this.type&&"radio"!=this.type&&s.append(this.name+"",e(this).val().trim()),"checkbox"!=this.type&&"radio"!=this.type||e(this).is(":checked")&&s.append(this.name+"",e(this).val())}),s.append("wpd_comment_depth",n),wpdiscuzAjaxObj.wpdiscuz_zs&&s.append("wpdiscuz_zs",wpdiscuzAjaxObj.wpdiscuz_zs),e(".wpd-cookies-checkbox",i).length&&!e(".wpd-cookies-checkbox",i).prop("checked")&&(b=!1),e("#wpdiscuz-loading-bar").show(),wpdiscuzAjaxObj.wpDiscuzReCaptchaSK&&"3.0"===d&&(1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!wpdiscuzAjaxObj.is_user_logged_in||1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&wpdiscuzAjaxObj.is_user_logged_in))try{grecaptcha.ready(function(){grecaptcha.execute(wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,{action:"wpdiscuz/addComment"}).then(function(e){s.append("g-recaptcha-response",e),R(i,s,t)},function(e){wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error","error"),console.log(e)})})}catch(t){console.log(t),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+t.message,"error"),e("#wpdiscuz-loading-bar").fadeOut(250)}else R(i,s,t)}var c,p;!function(e){if((a||o)&&"2.0"===d){var t=B(e);grecaptcha.reset(T[t])}}(e(".wpdiscuz_unique_id",i).val()),e(".wpdiscuz_reset").val("")}else wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj.wc_msg_required_fields,"error")}),e(document).delegate(".wpd_editable_comment","click",function(){w&&e(".wpdiscuz-edit-form-wrap").length&&q(V(e(".wpdiscuz-edit-form-wrap"),0),w);var t=V(e(this),0),a=B(t),o=new FormData;o.append("action","wpdEditComment"),o.append("commentId",a),w=e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-text").get(0),ce(z,!0,o).done(function(a){"object"==typeof a?a.success?(e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd-comment-text").replaceWith(a.data),wpdiscuzLoadRichEditor&&(wpDiscuzEditor.createEditor("#wpd-editor-edit_"+t),e(".wpd-toolbar-hidden").prev("[id^=wpd-editor-]").css("border-bottom","1px solid #dddddd")),e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd_editable_comment").hide(),e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").hide()):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"):console.log(a),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wc_save_edited_comment","click",function(){var t=V(e(this)),a=B(t),o=e("#wpd-comm-"+t+" #wpdiscuz-edit-form");if(J(o,"#wpd-editor-edit_"+t),o.submit(function(e){e.preventDefault()}),o[0].checkValidity()){var d=new FormData;d.append("action","wpdSaveEditedComment"),d.append("commentId",a),e(":input",o).each(function(){""!==this.name&&"checkbox"!==this.type&&"radio"!==this.type&&d.append(this.name+"",e(this).val()),"checkbox"!==this.type&&"radio"!==this.type||e(this).is(":checked")&&d.append(this.name+"",e(this).val())}),ce(z,!0,d).done(function(o){"object"==typeof o?(o.success?(q(t,o.data.message),o.data.lastEdited&&(e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").remove(),e(o.data.lastEdited).insertAfter("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd-comment-text")),o.data.twitterShareLink&&e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-share .wpd-tooltip-content .wc_tw").attr("href",o.data.twitterShareLink),o.data.whatsappShareLink&&e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-share .wpd-tooltip-content .wc_whatsapp").attr("href",o.data.whatsappShareLink),wpdiscuzLoadRichEditor&&wpDiscuzEditor.removeEditor("#wpd-editor-edit_"+t)):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[o.data],"error"),se(o,a)):console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(document).delegate(".wc_cancel_edit","click",function(){var t=V(e(this));q(t,w),wpdiscuzLoadRichEditor&&wpDiscuzEditor.removeEditor("#wpd-editor-edit_"+t)}),!wpdiscuzAjaxObj.wordpressIsPaginate&&m&&(M=0,1==m?setTimeout(function(){W(!0)},500):e(document).delegate(".wpd-load-comments","click",function(){e(this).remove(),W(!0)})),e(document).delegate(".wpd-load-more-submit","click",function(){var t=e(this);t.hasClass("wpd-loaded")&&W(!1,t,"wpd-loaded","wpd-loading")});var U=!1;function H(){var t=e("#wpdiscuzHasMoreComments").val(),a=e(document).height(),o=e(window).height()+e(window).scrollTop();a&&o&&(100*o/a>=80&&!1===U&&1==t&&(U=!0,W(!1,e(".wpd-load-more-submit"))))}function W(t,a,o,d){a&&(a.toggleClass(o),a.toggleClass(d));var i=new FormData;i.append("action","wpdLoadMoreComments");var s=e(".wpdiscuz-sort-button-active").attr("data-sorting");s&&i.append("sorting",s),i.append("offset",M),i.append("lastParentId",e(".wpd-load-more-submit").attr("data-lastparentid")),i.append("isFirstLoad",t?1:0);var c=e(".wpdf-active").attr("data-filter-type");i.append("wpdType",c||""),ce(z,!0,i).done(function(i){"object"==typeof i&&i.success&&(M++,e(".wpdiscuz-comment-pagination").before(i.data.comment_list),K(i,t&&2!==n),e(".wpdiscuz_single").remove(),U=!1,r=i.data.loadLastCommentId,se(i),t&&N(!1)),e("#wpdiscuz-loading-bar").fadeOut(250),e(".wpd-load-more-submit").blur(),a&&(a.toggleClass(o),a.toggleClass(d))}).fail(function(t,n,i){console.log(i),e("#wpdiscuz-loading-bar").fadeOut(250),e(".wpd-load-more-submit").blur(),a&&(a.toggleClass(o),a.toggleClass(d))})}function K(t,a){var o;0==t.data.is_show_load_more?(e("#wpdiscuzHasMoreComments").val(0),e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").hide()):(o=t.data.last_parent_id,e(".wpd-load-more-submit").attr("data-lastparentid",o),2!==n&&e(".wpdiscuz-comment-pagination").show(),e("#wpdiscuzHasMoreComments").val(1),a&&e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").show()),se(t)}function N(t){var a=location.href.match(/#comment\-(\d+)/);if(null!==a){var o=a[1];if(e("#comment-"+o).length)setTimeout(function(){e("html, body").animate({scrollTop:e("#comment-"+o).parents("[id^=wpd-comm-]").offset().top-32},1e3),t&&P(o)},500);else{var d=new FormData;d.append("action","wpdGetSingleComment"),d.append("commentId",o),ce(z,!0,d).done(function(a){if("object"==typeof a&&a.success){var d="#comment-"+o;e("#comment-"+a.data.parentCommentID).length?e("#comment-"+a.data.parentCommentID).parents("[id^=wpd-comm-"+a.data.parentCommentID+"]").replaceWith(a.data.message):e(".wpd-thread-list").prepend(a.data.message),se(a),e("html, body").animate({scrollTop:e(d).offset().top-32},1e3),t&&P(o)}e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}}function P(t){setTimeout(function(){e("#comment-"+t).siblings(".wpd-secondary-form-wrapper").is(":visible")||e("#comment-"+t).find(".wpd-reply-button").trigger("click")},1100)}function Q(e){if(void 0!==e.data.message)for(var t,a=e.data.message,o=0;o<a.length;o++)$((t=a[o]).comment_parent,t.comment_html)}function V(e,t){var a="";return(a=t?e.parents(".wpd-main-form-wrapper").attr("id"):e.parents(".wpd-comment").attr("id")).substring(a.lastIndexOf("-")+1)}function B(e){return e.substring(0,e.indexOf("_"))}function G(e,t){return t?e.substring(e.indexOf("-")+1):e.substring(0,e.indexOf("-"))}function $(t,a){if(0==t)X(a);else{var o=V(e("#comment-"+t),0);e("#wpdiscuz_form_anchor-"+o).after(a)}}function Y(){var t,a,o="";return e(".wpd-comment-right").each(function(){t=V(e(this),0),a=B(t),o+=a+","}),o}function J(t,a){var o=t.find(".wpd-required-group");wpdiscuzLoadRichEditor&&t.find(".wc_comment").val(e(a+">.ql-editor").html()),function(e){var t=e.find(".wc_comment"),a=t.val().trim();a=(a=(a=(a=a.replace(/<img src=["|']https\:\/\/s\.w\.org\/images\/core\/emoji\/([^"|']+)["|'](.*?)alt=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$3")).replace(/<img[^>]+alt=["|']([^"|']+)["|'][^>]+src=["|']https\:\/\/s\.w\.org\/images\/core\/emoji\/([^"|']+)["|'][^>]?>/g,"$1")).replace(/<img\s+([^>]*)class=["|']wpdem\-sticker["|'](.*?)alt=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$3")).replace(/<img\s+([^>]*)src=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$2"),t.val(a)}(t),e.each(o,function(){e("input",this).removeAttr("required"),0===e("input:checked",this).length?e("input",e(this)).attr("required","required"):e(".wpd-field-invalid",this).remove()})}function X(t){e(".wpd-sticky-comment").last()[0]?e(t).insertAfter(e(".wpd-sticky-comment").last()[0]):e(".wpd-thread-list").prepend(t)}function Z(t){t?t.prop("required")||(t.val()?t.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","inline-block"):t.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","none")):e.each(e(".wc_email"),function(t,a){var o=e(a);o.prop("required")||(o.val()?o.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","inline-block"):o.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","none"))})}if(2!==n||wpdiscuzAjaxObj.wordpressIsPaginate||(e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").hide(),H(),e(window).scroll(function(){H()})),wpdiscuzAjaxObj.setLoadMoreVisibility=K,e(document).delegate(".wpd-vote-up.wpd_not_clicked, .wpd-vote-down.wpd_not_clicked","click",function(){var t=e(this);e(t).removeClass("wpd_not_clicked");var a,o=B(V(t));a=e(this).hasClass("wpd-vote-up")?1:-1;var d=new FormData;d.append("action","wpdVoteOnComment"),d.append("commentId",o),d.append("voteType",a),ce(z,!0,d).done(function(d){if(e(t).addClass("wpd_not_clicked"),"object"==typeof d){if(d.success){if("total"===d.data.buttonsStyle){var n=e(".wpd-comment-footer .wpd-vote-result",e("#comment-"+o)),i=d.data.votes;n.text(i),n.removeClass("wpd-up wpd-down"),i>0&&n.addClass("wpd-up"),i<0&&n.addClass("wpd-down")}else{var s=e(".wpd-comment-footer .wpd-vote-result-like",e("#comment-"+o)),c=e(".wpd-comment-footer .wpd-vote-result-dislike",e("#comment-"+o));s.text(d.data.likeCount),c.text(d.data.dislikeCount),parseInt(d.data.likeCount)>0?s.addClass("wpd-up"):s.removeClass("wpd-up"),parseInt(d.data.dislikeCount)<0?c.addClass("wpd-down"):c.removeClass("wpd-down")}var p=e(".wpd-comment-footer .wpd-vote-up",e("#comment-"+o)),r=e(".wpd-comment-footer .wpd-vote-down",e("#comment-"+o));p.removeClass("wpd-up"),r.removeClass("wpd-down"),d.data.curUserReaction>0?p.addClass("wpd-up"):d.data.curUserReaction<0&&r.addClass("wpd-down")}else d.data&&wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[d.data],"error");se(d,o,a)}else console.log(d);e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(a,o,d){console.log(d),e(t).addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate("body","click",function(t){var a=e(".wpdiscuz-sort-buttons");e(t.target).hasClass("wpdf-sorting")||e(t.target).parent().hasClass("wpdf-sorting")?a.css({display:a.is(":visible")?"none":"flex"}):a.hide()}),e(document).delegate(".wpdiscuz-sort-button:not(.wpdiscuz-sort-button-active)","click",function(){var t=e(this),a=e(this).attr("data-sorting");if(a){e(".wpdiscuz-sort-button.wpdiscuz-sort-button-active").removeClass("wpdiscuz-sort-button-active").appendTo(".wpdiscuz-sort-buttons"),t.addClass("wpdiscuz-sort-button-active").prependTo(".wpdf-sorting");var o=new FormData;o.append("action","wpdSorting"),o.append("sorting",a);var d=e(".wpdf-active").attr("data-filter-type");o.append("wpdType",d||""),ce(z,!0,o).done(function(t){"object"==typeof t&&t.success&&(e("#wpdcom .wpd-comment").remove(),e("#wpdcom .wpd-thread-list").prepend(t.data.message),K(t,!1),M=1),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),window.onhashchange=function(){N(!1)},1!=m&&N(!1),e(document).delegate(".wpdiscuz-readmore","click",function(){var t=V(e(this)),a=B(t),o=new FormData;o.append("action","wpdReadMore"),o.append("commentId",a),ce(z,!0,o).done(function(o){"object"==typeof o?(o.success?(e("#comment-"+a+" .wpd-comment-text").html(" "+o.data.message),e("#wpdiscuz-readmore-"+t).remove()):console.log(o.data),se(o)):console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-required-group","change",function(){0!==e("input:checked",this).length?e("input",e(this)).removeAttr("required"):e("input",e(this)).attr("required","required")}),e(document).delegate(".wpdiscuz-spoiler","click",function(){e(this).next().slideToggle(),e(this).hasClass("wpdiscuz-spoiler-closed")?e(this).parents(".wpdiscuz-spoiler-wrap").find(".fa-plus").removeClass("fa-plus").addClass("fa-minus"):e(this).parents(".wpdiscuz-spoiler-wrap").find(".fa-minus").removeClass("fa-minus").addClass("fa-plus"),e(this).toggleClass("wpdiscuz-spoiler-closed")}),e(document).delegate(".wpd-tools i","click",function(){var t=e(this).siblings(".wpd-tools-actions");t.css({display:t.is(":visible")?"none":"flex"})}),e(document).delegate(".wpd-comment-right","mouseleave",function(){e(this).find(".wpd-tools-actions").hide()}),e(document).delegate(".wpd_stick_btn","click",function(){var t=B(V(e(this),0)),a=new FormData;a.append("action","wpdStickComment"),a.append("commentId",t),ce(z,!0,a).done(function(t){"object"==typeof t&&t.success&&location.reload(!0),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd_close_btn","click",function(){var t=B(V(e(this),0)),a=new FormData;a.append("action","wpdCloseThread"),a.append("commentId",t),ce(z,!0,a).done(function(t){"object"==typeof t&&t.success&&location.reload(!0),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-filter.wpd_not_clicked[data-filter-type]","click",function(){var t=e(this),a=t.attr("data-filter-type");wpdiscuzAjaxObj.resetActiveFilters(".wpdf-"+a),t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var o=new FormData;o.append("action","wpdLoadMoreComments");var d=e(".wpdiscuz-sort-button-active").attr("data-sorting");d&&o.append("sorting",d),o.append("lastParentId",0),o.append("offset",0),M=1,o.append("wpdType",t.hasClass("wpdf-active")?"":a),o.append("isFirstLoad",1),e(this).hasClass("wpdf-inline")?e(this).hasClass("wpdf-active")?e(".wpd-comment-info-bar").hide():e(".wpd-comment-info-bar").css("display","flex"):e(".wpd-comment-info-bar").hide(),ce(z,!1,o).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(t.toggleClass("wpdf-active"),e(".wpd-load-comments").remove(),e(".wpd-comment").remove(),e(".wpd-thread-list").prepend(a.data.comment_list),K(a),r=a.data.loadLastCommentId,e(".wpd-load-more-submit").blur(),se(a)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpdf-reacted.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=new FormData;a.append("action","wpdMostReactedComment"),ce(z,!1,a).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(e("#comment-"+a.data.parentCommentID).length?e("#comment-"+a.data.parentCommentID).parents("[id^=wpd-comm-"+a.data.parentCommentID+"]").replaceWith(a.data.message):e("#comment-"+a.data.commentId).length||e(".wpd-thread-list").prepend(a.data.message),se(a),e("html, body").animate({scrollTop:e("#comment-"+a.data.commentId).offset().top-32},1e3))}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner")})}),e(document).delegate(".wpdf-hottest.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=new FormData;a.append("action","wpdHottestThread"),ce(z,!1,a).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(e("#comment-"+a.data.commentId).length?e("#comment-"+a.data.commentId).parents("[id^=wpd-comm-"+a.data.commentId+"]").replaceWith(a.data.message):e(".wpd-thread-list").prepend(a.data.message),se(a),e("html, body").animate({scrollTop:e("#comment-"+a.data.commentId).offset().top-32},1e3))}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner")})}),e(document).delegate(".wpd-filter-view-all","click",function(){e(".wpdf-inline.wpdf-active.wpd_not_clicked").trigger("click")}),e(document).delegate(".wpd-follow-link.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=B(V(t,0)),o=new FormData;o.append("action","wpdFollowUser"),o.append("commentId",a),ce(z,!0,o).done(function(a){t.addClass("wpd_not_clicked"),"object"==typeof a?a.success?(wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data.code],"success"),t.removeClass("wpd-follow-active"),a.data.followTip&&t.attr("wpd-tooltip",a.data.followTip),a.data.followClass&&t.addClass(a.data.followClass)):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"):console.log(a),e(".fas",t).removeClass("fa-pulse fa-spinner"),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner"),e("#wpdiscuz-loading-bar").fadeOut(250)})}),Z(),e(document).delegate(".wc_email","keyup",function(){Z(e(this))}),j){if(e("#wpd-bubble-wrapper").hover(function(){e(this).addClass("wpd-bubble-hover")},function(){e(this).removeClass("wpd-bubble-hover")}),k&&!Cookies.get(wpdiscuzAjaxObj.cookieHideBubbleHint)&&setTimeout(function(){e("#wpd-bubble-wrapper").addClass("wpd-bubble-hover"),Cookies.set(wpdiscuzAjaxObj.cookieHideBubbleHint,"1",{expires:7,path:"/"}),setTimeout(function(){e("#wpd-bubble-wrapper").removeClass("wpd-bubble-hover")},1e3*x)},1e3*k),"content_left"===O)if(e(".entry-content").length){var ee=(te=Math.min(e(".entry-content").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else if(e(".post-entry").length){ee=(te=Math.min(e(".post-entry").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else if(e(".container").length){var te;ee=(te=Math.min(e(".container").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else e("#wpd-bubble-wrapper").css({left:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-corner");else"left_corner"===O?(e("#wpd-bubble-wrapper").css({left:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-corner")):"right_corner"===O&&(e("#wpd-bubble-wrapper").css({right:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-right-corner"));e("#wpd-bubble-wrapper").show(),e("#wpd-bubble-add-message-close").click(function(t){t.preventDefault(),t.stopPropagation(),e("#wpd-bubble-wrapper").removeClass("wpd-bubble-hover")}),e("#wpd-bubble").click(function(){e("html, body").animate({scrollTop:e("#wpdcom").offset().top-60},1e3,function(){wpdiscuzLoadRichEditor?wpDiscuzEditor.createEditor("#wpd-editor-0_0").focus():e("#wc-textarea-0_0").focus()})}),e("#wpd-bubble-comment-close").click(function(t){t.preventDefault(),e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added")}),e("#wpd-bubble-comment-reply-link a").click(function(){var t=e(this).attr("href");setTimeout(function(){e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added"),N(!0);var a=t.match(/#comment\-(\d+)/);D=D.filter(function(e){return e!=a[1]}),e("#wpd-bubble-count .wpd-new-comments-count").text(D.length),0==D.length&&e("#wpd-bubble-count").removeClass("wpd-new-comments")},100)}),e("#wpd-bubble-count").click(function(){if(D.length){var t=new FormData;t.append("action","wpdBubbleUpdate"),t.append("newCommentIds",D.join()),ce(z,!0,t).done(function(t){"object"==typeof t&&t.success&&(t.data.message=t.data.message.filter(function(t){if(!e("#comment-"+t.comment_id).length)return t}),Q(t),e("#wpd-bubble-count").removeClass("wpd-new-comments"),e("#wpd-bubble-count .wpd-new-comments-count").text("0"),D=[],e("html, body").animate({scrollTop:e(e(".wpd-new-loaded-comment")[0]).offset().top-60},1e3),se(t)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(e,t,a){console.log(a)})}})}if((j&&C||s)&&(t||!t&&p)&&setTimeout(function t(){e.ajax({type:"GET",url:wpdiscuzAjaxObj.bubbleUpdateUrl,data:{postId:i,lastId:l,visibleCommentIds:Y()}}).done(function(a){if(!E)if("object"==typeof a){if(a.ids.length){s&&((n=new FormData).append("action","wpdUpdateAutomatically"),n.append("loadLastCommentId",r),n.append("visibleCommentIds",Y()),ce(z,!1,n).done(function(t){E||"object"==typeof t&&t.success&&(Q(t),e(".wpd-thread-info").html(t.data.wc_all_comments_count_new_html),t.data.wc_all_comments_count_new=parseInt(t.data.wc_all_comments_count_new),e("#wpd-bubble-all-comments-count").text(t.data.wc_all_comments_count_new),t.data.wc_all_comments_count_new?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),r=t.data.loadLastCommentId)}).fail(function(e,t,a){console.log(a)})),a.ids=a.ids.filter(function(t){if(!e("#comment-"+t).length)return t});var o=5e3;l=parseInt(a.ids[a.ids.length-1]),D=D.concat(a.ids),y&&a.commentText&&(e("#wpd-bubble-author-avatar").html(a.avatar),e("#wpd-bubble-author-name").html(a.authorName),e("#wpd-bubble-comment-date span").html(a.commentDate),e("#wpd-bubble-comment-text").html(a.commentText),e("#wpd-bubble-comment-reply-link a").attr("href",a.commentLink),e("#wpd-bubble-notification-message").show(),o=1e4);var d=parseInt(e(".wpd-new-comments-count").text());d+=a.ids.length,e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added"),e("#wpd-bubble-wrapper").addClass("wpd-new-comment-added"),setTimeout(function(){e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added")},o),e(".wpd-new-comments-count").text(d),e("#wpd-bubble-count").addClass("wpd-new-comments"),a.all_comments_count=parseInt(a.all_comments_count),e("#wpd-bubble-all-comments-count").text(a.all_comments_count),a.all_comments_count?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),e(".wpd-thread-info").html(a.all_comments_count_html)}}else console.log(a);var n;setTimeout(t,c)}).fail(function(e,a,o){console.log(o),setTimeout(t,c)})},c),e(".wpd-inline-form-wrapper").length){var ae=new FormData;ae.append("action","wpdGetInlineCommentForm"),ce(z,!1,ae).done(function(t){"object"==typeof t?t.success?(e(".wpd-inline-form-wrapper").append(t.data),e.each(e("[name=_wpd_inline_nonce]"),function(){var t=e(this).attr("id"),a=e(this).parents(".wpd-inline-shortcode").attr("id");e(this).attr("id",t+"-"+a.substring(a.lastIndexOf("-")+1))}),e(".wpd-inline-opened").addClass("wpd-active"),e(".wpd-inline-opened").find(".wpd-inline-form-wrapper").show(),e(".wpd-inline-opened").find(".wpd-inline-icon").addClass("wpd-open"),e(".wpd-inline-opened").find(".wpd-inline-icon").removeClass("wpd-ignored"),ie()):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error"):console.log(t)}).fail(function(e,t,a){console.log(a)})}function oe(t){if(e(t).hasClass("wpd-inline-shortcode"))var a=e(t).attr("id");else a=e(t).parents(".wpd-inline-shortcode").attr("id");return a.substring(a.lastIndexOf("-")+1)}function de(){e(".wpd-inline-form-wrapper").hide(),e(".wpd-inline-shortcode").removeClass("wpd-active"),e(".wpd-inline-icon").removeClass("wpd-open")}function ne(){e.each(e(".wpd-inline-shortcode:not(.wpd-inline-opened) .wpd-inline-icon"),function(){var t=e(this),a=t.offset().top-window.pageYOffset;a>0&&a<300&&("blink"===A?(t.addClass("wpd-blink"),setTimeout(function(){t.removeClass("wpd-blink")},3e3)):(t.parents(".wpd-inline-shortcode").addClass("wpd-active"),t.siblings(".wpd-inline-form-wrapper").show(),t.addClass("wpd-open"),ie(t.siblings(".wpd-inline-form-wrapper"))))})}function ie(t){if(t){if(t.offset().left<=10)t.css("left",Math.ceil(parseInt(t.css("left"))-t.offset().left+10)),(a=Math.ceil(t.siblings(".wpd-inline-icon.wpd-open").offset().left-t.offset().left+2))<3&&(a=3),document.styleSheets[0].addRule("#"+t.parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+a+"px;");else if(t.offset().left+t.width()>document.body.clientWidth-10){var a;t.css("left",Math.ceil(parseInt(t.css("left"))+(document.body.clientWidth-(t.offset().left+t.width()))-10)),(a=Math.ceil(t.siblings(".wpd-inline-icon.wpd-open").offset().left-t.offset().left+2))>t.width()-3&&(a=t.width()-3),document.styleSheets[0].addRule("#"+t.parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+a+"px;")}}else e.each(e(".wpd-inline-form-wrapper:visible"),function(){if(e(this).offset().left<=10)e(this).css("left",Math.ceil(parseInt(e(this).css("left"))-e(this).offset().left+10)),(t=Math.ceil(e(this).siblings(".wpd-inline-icon.wpd-open").offset().left-e(this).offset().left+2))<3&&(t=3),document.styleSheets[0].addRule("#"+e(this).parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+t+"px;");else if(e(this).offset().left+e(this).width()>document.body.clientWidth-10){var t;e(this).css("left",Math.ceil(parseInt(e(this).css("left"))+(document.body.clientWidth-(e(this).offset().left+e(this).width()))-10)),(t=Math.ceil(e(this).siblings(".wpd-inline-icon.wpd-open").offset().left-e(this).offset().left+2))>e(this).width()-3&&(t=e(this).width()-3),document.styleSheets[0].addRule("#"+e(this).parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+t+"px;")}})}function se(t,a,o,d){t.data.callbackFunctions&&e.each(t.data.callbackFunctions,function(e){"function"==typeof wpdiscuzAjaxObj[t.data.callbackFunctions[e]]?wpdiscuzAjaxObj[t.data.callbackFunctions[e]](t,a,o,d):console.log(t.data.callbackFunctions[e]+" is not a function")})}function ce(t,a,o){a&&e("#wpdiscuz-loading-bar").show(),o.append("postId",i);var d=o.get("action");wpdiscuzAjaxObj.dataFilterCallbacks&&wpdiscuzAjaxObj.dataFilterCallbacks[d]&&e.each(wpdiscuzAjaxObj.dataFilterCallbacks[d],function(e){"function"==typeof wpdiscuzAjaxObj[wpdiscuzAjaxObj.dataFilterCallbacks[d][e]]&&(o=wpdiscuzAjaxObj[wpdiscuzAjaxObj.dataFilterCallbacks[d][e]](o,t,a))});var n=t?wpdiscuzAjaxObj.url:wpdiscuzAjaxObj.customAjaxUrl;return e.ajax({type:"POST",url:n,data:o,contentType:!1,processData:!1})}e(document).delegate("body","click",function(t){if(e(t.target).hasClass("wpd-inline-form-close")||e(t.target).parents(".wpd-inline-form-close").length)t.preventDefault(),e(t.target).parents(".wpd-inline-form-wrapper").hide(),e(t.target).parents(".wpd-inline-shortcode").removeClass("wpd-active"),e(t.target).parents(".wpd-inline-form-wrapper").siblings(".wpd-inline-icon").removeClass("wpd-open");else if(!e(t.target).hasClass("wpd-inline-form-wrapper")&&!e(t.target).parents(".wpd-inline-form-wrapper").length){de();var a="";e(t.target).hasClass("wpd-inline-icon")?a=e(t.target):e(t.target).parents(".wpd-inline-icon").length&&(a=e(t.target).parents(".wpd-inline-icon")),a.length&&(a.parents(".wpd-inline-shortcode").addClass("wpd-active"),a.siblings(".wpd-inline-form-wrapper").show(),a.addClass("wpd-open"),a.removeClass("wpd-ignored"),ie(a.siblings(".wpd-inline-form-wrapper")))}(!e(t.target).hasClass("wpd-last-inline-comments-wrapper")&&!e(t.target).parents(".wpd-last-inline-comments-wrapper").length||e(t.target).parents(".wpd-last-inline-comments-wrapper").length&&e(t.target).hasClass("wpd-load-inline-comment"))&&e(".wpd-last-inline-comments-wrapper").remove()}),e(document).delegate(".wpd-inline-submit.wpd_not_clicked","click",function(t){t.preventDefault();var a=e(this),o=e(this).parents(".wpd_inline_comm_form");if(o[0].checkValidity()){e(this).removeClass("wpd_not_clicked");var d=new FormData;d.append("action","wpdAddInlineComment"),d.append("inline_form_id",oe(o)),e.each(e("input, textarea",o),function(t,a){"checkbox"===this.type?e(this).is(":checked")&&d.append(e(a).attr("name"),e(a).val()):d.append(e(a).attr("name"),e(a).val())}),ce(z,!0,d).done(function(t){if(a.addClass("wpd_not_clicked"),"object"==typeof t)if(t.success){o[0].reset(),de();var d=parseInt(t.data.newCount),n=a.parents(".wpd-inline-icon-wrapper").find(".wpd-inline-icon-count");n.text(d),d?n.addClass("wpd-has-comments"):n.removeClass("wpd-has-comments"),e(".wpd-thread-info").html(t.data.allCommentsCountNewHtml),t.data.allCommentsCountNew=parseInt(t.data.allCommentsCountNew),e("#wpd-bubble-all-comments-count").text(t.data.allCommentsCountNew),t.data.allCommentsCountNew?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),t.data.message&&X(t.data.message),wpdiscuzAjaxObj.setCommentMessage(t.data.notification,"success")}else t.data&&wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error");else wpdiscuzAjaxObj.setCommentMessage(t,"error");e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(document).delegate(".wpd-form","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).find(".wc_comm_submit").trigger("click")}),e(document).delegate("#wpdiscuz-edit-form","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).find(".wc_save_edited_comment").trigger("click")}),e(document).delegate(".wpd-inline-comment-content","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).parents(".wpd_inline_comm_form").find(".wpd-inline-submit.wpd_not_clicked").trigger("click")}),e(document).delegate(".wpd-inline-icon-count.wpd-has-comments","click",function(){var t=e(this),a=new FormData;a.append("action","wpdGetLastInlineComments"),a.append("inline_form_id",oe(t)),ce(z,!0,a).done(function(a){"object"==typeof a?a.success?e(a.data).insertAfter(t):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"):console.log(a),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-view-all-inline-comments","click",function(t){t.preventDefault(),e(this).parents(".wpd-last-inline-comments-wrapper").remove(),e(".wpdf-inline").hasClass("wpdf-active")||e(".wpdf-inline").trigger("click"),e("html, body").animate({scrollTop:e(".wpdf-inline").offset().top-32},1e3)}),e(document).delegate(".wpd-feedback-content-link","click",function(t){t.preventDefault();var a=e(this).data("feedback-content-id");e("html, body").animate({scrollTop:e("#wpd-inline-"+a).offset().top-38},1e3,function(){e("#wpd-inline-"+a).addClass("wpd-active")})}),"scroll_open"!==A&&"blink"!==A||(ne(),e(window).scroll(ne)),e(document).delegate("#wpd-post-rating.wpd-not-rated .wpd-rate-starts svg","click",function(){var t=new FormData,a=e(this).index();a>=0&&a<5&&(t.append("action","wpdUserRate"),t.append("rating",a+1),ce(z,!0,t).done(function(t){"object"==typeof t?t.success?location.reload(!0):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error"):console.log(t),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}))}),e("#wpdiscuz-subscribe-form").submit(function(t){t.preventDefault();var a,o,n=e(this);if(n[0].checkValidity()&&(a=n,o=!0,"2.0"===d&&e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).length&&!e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).val().length?(o=!1,e(".wpdiscuz-recaptcha",a).css("border","1px solid red")):"2.0"===d&&e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).length&&e(".wpdiscuz-recaptcha",a).css("border","none"),o)){var i=new FormData;i.append("action","wpdAddSubscription"),e("*",n).each(function(){""!=this.name&&"checkbox"!=this.type&&"radio"!=this.type&&i.append(this.name+"",e(this).val()),"checkbox"!=this.type&&"radio"!=this.type||e(this).is(":checked")&&i.append(this.name+"",e(this).val())}),ce(z,!0,i).done(function(t){"object"==typeof t?t.success?(wpdiscuzAjaxObj.setCommentMessage(t.data,"success"),setTimeout(function(){location.reload(!0)},3e3)):wpdiscuzAjaxObj.setCommentMessage(t.data,"error"):wpdiscuzAjaxObj.setCommentMessage(t,"error"),e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(".wpd-unsubscribe").click(function(t){t.preventDefault();var a=new FormData;a.append("action","wpdUnsubscribe"),a.append("sid",e(this).data("sid")),a.append("skey",e(this).data("skey")),ce(z,!0,a).done(function(t){"object"==typeof t?t.success?(wpdiscuzAjaxObj.setCommentMessage(t.data,"success"),setTimeout(function(){location.reload(!0)},3e3)):wpdiscuzAjaxObj.setCommentMessage(t.data,"error"):console.log(t),e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),wpdiscuzAjaxObj.resetActiveFilters=function(t){e(".wpd-filter.wpdf-active"+(t?":not("+t+")":"")).removeClass("wpdf-active")},wpdiscuzAjaxObj.getAjaxObj=ce});var onloadCallback=function(){if(document.getElementById("wpdiscuz-recaptcha-0_0")&&"2.0"===wpdiscuzAjaxObj.wpDiscuzReCaptchaVersion&&(1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!wpdiscuzAjaxObj.is_user_logged_in||1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&wpdiscuzAjaxObj.is_user_logged_in))try{grecaptcha.render("wpdiscuz-recaptcha-0_0",{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(e){jQuery("#wpdiscuz-recaptcha-field-0_0").val("key")},"expired-callback":function(){jQuery("#wpdiscuz-recaptcha-field-0_0").val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}};
11
  /* Colorbox */
12
  (function(t,e,i){function n(i,n,o){var r=e.createElement(i);return n&&(r.id=Z+n),o&&(r.style.cssText=o),t(r)}function o(){return i.innerHeight?i.innerHeight:t(i).height()}function r(e,i){i!==Object(i)&&(i={}),this.cache={},this.el=e,this.value=function(e){var n;return void 0===this.cache[e]&&(n=t(this.el).attr("data-cbox-"+e),void 0!==n?this.cache[e]=n:void 0!==i[e]?this.cache[e]=i[e]:void 0!==X[e]&&(this.cache[e]=X[e])),this.cache[e]},this.get=function(e){var i=this.value(e);return t.isFunction(i)?i.call(this.el,this):i}}function h(t){var e=W.length,i=(A+t)%e;return 0>i?e+i:i}function a(t,e){return Math.round((/%/.test(t)?("x"===e?E.width():o())/100:1)*parseInt(t,10))}function s(t,e){return t.get("photo")||t.get("photoRegex").test(e)}function l(t,e){return t.get("retinaUrl")&&i.devicePixelRatio>1?e.replace(t.get("photoRegex"),t.get("retinaSuffix")):e}function d(t){"contains"in x[0]&&!x[0].contains(t.target)&&t.target!==v[0]&&(t.stopPropagation(),x.focus())}function c(t){c.str!==t&&(x.add(v).removeClass(c.str).addClass(t),c.str=t)}function g(e){A=0,e&&e!==!1&&"nofollow"!==e?(W=t("."+te).filter(function(){var i=t.data(this,Y),n=new r(this,i);return n.get("rel")===e}),A=W.index(_.el),-1===A&&(W=W.add(_.el),A=W.length-1)):W=t(_.el)}function u(i){t(e).trigger(i),ae.triggerHandler(i)}function f(i){var o;if(!G){if(o=t(i).data(Y),_=new r(i,o),g(_.get("rel")),!U){U=$=!0,c(_.get("className")),x.css({visibility:"hidden",display:"block",opacity:""}),I=n(se,"LoadedContent","width:0; height:0; overflow:hidden; visibility:hidden"),b.css({width:"",height:""}).append(I),j=T.height()+k.height()+b.outerHeight(!0)-b.height(),D=C.width()+H.width()+b.outerWidth(!0)-b.width(),N=I.outerHeight(!0),z=I.outerWidth(!0);var h=a(_.get("initialWidth"),"x"),s=a(_.get("initialHeight"),"y"),l=_.get("maxWidth"),f=_.get("maxHeight");_.w=Math.max((l!==!1?Math.min(h,a(l,"x")):h)-z-D,0),_.h=Math.max((f!==!1?Math.min(s,a(f,"y")):s)-N-j,0),I.css({width:"",height:_.h}),J.position(),u(ee),_.get("onOpen"),O.add(F).hide(),x.focus(),_.get("trapFocus")&&e.addEventListener&&(e.addEventListener("focus",d,!0),ae.one(re,function(){e.removeEventListener("focus",d,!0)})),_.get("returnFocus")&&ae.one(re,function(){t(_.el).focus()})}var p=parseFloat(_.get("opacity"));v.css({opacity:p===p?p:"",cursor:_.get("overlayClose")?"pointer":"",visibility:"visible"}).show(),_.get("closeButton")?B.html(_.get("close")).appendTo(b):B.appendTo("<div/>"),w()}}function p(){x||(V=!1,E=t(i),x=n(se).attr({id:Y,"class":t.support.opacity===!1?Z+"IE":"",role:"dialog",tabindex:"-1"}).hide(),v=n(se,"Overlay").hide(),L=t([n(se,"LoadingOverlay")[0],n(se,"LoadingGraphic")[0]]),y=n(se,"Wrapper"),b=n(se,"Content").append(F=n(se,"Title"),R=n(se,"Current"),P=t('<button type="button"/>').attr({id:Z+"Previous"}),K=t('<button type="button"/>').attr({id:Z+"Next"}),S=t('<button type="button"/>').attr({id:Z+"Slideshow"}),L),B=t('<button type="button"/>').attr({id:Z+"Close"}),y.append(n(se).append(n(se,"TopLeft"),T=n(se,"TopCenter"),n(se,"TopRight")),n(se,!1,"clear:left").append(C=n(se,"MiddleLeft"),b,H=n(se,"MiddleRight")),n(se,!1,"clear:left").append(n(se,"BottomLeft"),k=n(se,"BottomCenter"),n(se,"BottomRight"))).find("div div").css({"float":"left"}),M=n(se,!1,"position:absolute; width:9999px; visibility:hidden; display:none; max-width:none;"),O=K.add(P).add(R).add(S)),e.body&&!x.parent().length&&t(e.body).append(v,x.append(y,M))}function m(){function i(t){t.which>1||t.shiftKey||t.altKey||t.metaKey||t.ctrlKey||(t.preventDefault(),f(this))}return x?(V||(V=!0,K.click(function(){J.next()}),P.click(function(){J.prev()}),B.click(function(){J.close()}),v.click(function(){_.get("overlayClose")&&J.close()}),t(e).bind("keydown."+Z,function(t){var e=t.keyCode;U&&_.get("escKey")&&27===e&&(t.preventDefault(),J.close()),U&&_.get("arrowKey")&&W[1]&&!t.altKey&&(37===e?(t.preventDefault(),P.click()):39===e&&(t.preventDefault(),K.click()))}),t.isFunction(t.fn.on)?t(e).on("click."+Z,"."+te,i):t("."+te).live("click."+Z,i)),!0):!1}function w(){var e,o,r,h=J.prep,d=++le;if($=!0,q=!1,u(he),u(ie),_.get("onLoad"),_.h=_.get("height")?a(_.get("height"),"y")-N-j:_.get("innerHeight")&&a(_.get("innerHeight"),"y"),_.w=_.get("width")?a(_.get("width"),"x")-z-D:_.get("innerWidth")&&a(_.get("innerWidth"),"x"),_.mw=_.w,_.mh=_.h,_.get("maxWidth")&&(_.mw=a(_.get("maxWidth"),"x")-z-D,_.mw=_.w&&_.w<_.mw?_.w:_.mw),_.get("maxHeight")&&(_.mh=a(_.get("maxHeight"),"y")-N-j,_.mh=_.h&&_.h<_.mh?_.h:_.mh),e=_.get("href"),Q=setTimeout(function(){L.show()},100),_.get("inline")){var c=t(e).eq(0);r=t("<div>").hide().insertBefore(c),ae.one(he,function(){r.replaceWith(c)}),h(c)}else _.get("iframe")?h(" "):_.get("html")?h(_.get("html")):s(_,e)?(e=l(_,e),q=_.get("createImg"),t(q).addClass(Z+"Photo").bind("error."+Z,function(){h(n(se,"Error").html(_.get("imgError")))}).one("load",function(){d===le&&setTimeout(function(){var e;_.get("retinaImage")&&i.devicePixelRatio>1&&(q.height=q.height/i.devicePixelRatio,q.width=q.width/i.devicePixelRatio),_.get("scalePhotos")&&(o=function(){q.height-=q.height*e,q.width-=q.width*e},_.mw&&q.width>_.mw&&(e=(q.width-_.mw)/q.width,o()),_.mh&&q.height>_.mh&&(e=(q.height-_.mh)/q.height,o())),_.h&&(q.style.marginTop=Math.max(_.mh-q.height,0)/2+"px"),W[1]&&(_.get("loop")||W[A+1])&&(q.style.cursor="pointer",t(q).bind("click."+Z,function(){J.next()})),q.style.width=q.width+"px",q.style.height=q.height+"px",h(q)},1)}),q.src=e):e&&M.load(e,_.get("data"),function(e,i){d===le&&h("error"===i?n(se,"Error").html(_.get("xhrError")):t(this).contents())})}var v,x,y,b,T,C,H,k,W,E,I,M,L,F,R,S,K,P,B,O,_,j,D,N,z,A,q,U,$,G,Q,J,V,X={html:!1,photo:!1,iframe:!1,inline:!1,transition:"elastic",speed:300,fadeOut:300,width:!1,initialWidth:"600",innerWidth:!1,maxWidth:!1,height:!1,initialHeight:"450",innerHeight:!1,maxHeight:!1,scalePhotos:!0,scrolling:!0,opacity:.9,preloading:!0,className:!1,overlayClose:!0,escKey:!0,arrowKey:!0,top:!1,bottom:!1,left:!1,right:!1,fixed:!1,data:void 0,closeButton:!0,fastIframe:!0,open:!1,reposition:!0,loop:!0,slideshow:!1,slideshowAuto:!0,slideshowSpeed:2500,slideshowStart:"start slideshow",slideshowStop:"stop slideshow",photoRegex:/\.(gif|png|jp(e|g|eg)|bmp|ico|webp|jxr|svg)((#|\?).*)?$/i,retinaImage:!1,retinaUrl:!1,retinaSuffix:"@2x.$1",current:"image {current} of {total}",previous:"previous",next:"next",close:"close",xhrError:"This content failed to load.",imgError:"This image failed to load.",returnFocus:!0,trapFocus:!0,onOpen:!1,onLoad:!1,onComplete:!1,onCleanup:!1,onClosed:!1,rel:function(){return this.rel},href:function(){return t(this).attr("href")},title:function(){return this.title},createImg:function(){var e=new Image,i=t(this).data("cbox-img-attrs");return"object"==typeof i&&t.each(i,function(t,i){e[t]=i}),e},createIframe:function(){var i=e.createElement("iframe"),n=t(this).data("cbox-iframe-attrs");return"object"==typeof n&&t.each(n,function(t,e){i[t]=e}),"frameBorder"in i&&(i.frameBorder=0),"allowTransparency"in i&&(i.allowTransparency="true"),i.name=(new Date).getTime(),i.allowFullscreen=!0,i}},Y="colorbox",Z="cbox",te=Z+"Element",ee=Z+"_open",ie=Z+"_load",ne=Z+"_complete",oe=Z+"_cleanup",re=Z+"_closed",he=Z+"_purge",ae=t("<a/>"),se="div",le=0,de={},ce=function(){function t(){clearTimeout(h)}function e(){(_.get("loop")||W[A+1])&&(t(),h=setTimeout(J.next,_.get("slideshowSpeed")))}function i(){S.html(_.get("slideshowStop")).unbind(s).one(s,n),ae.bind(ne,e).bind(ie,t),x.removeClass(a+"off").addClass(a+"on")}function n(){t(),ae.unbind(ne,e).unbind(ie,t),S.html(_.get("slideshowStart")).unbind(s).one(s,function(){J.next(),i()}),x.removeClass(a+"on").addClass(a+"off")}function o(){r=!1,S.hide(),t(),ae.unbind(ne,e).unbind(ie,t),x.removeClass(a+"off "+a+"on")}var r,h,a=Z+"Slideshow_",s="click."+Z;return function(){r?_.get("slideshow")||(ae.unbind(oe,o),o()):_.get("slideshow")&&W[1]&&(r=!0,ae.one(oe,o),_.get("slideshowAuto")?i():n(),S.show())}}();t[Y]||(t(p),J=t.fn[Y]=t[Y]=function(e,i){var n,o=this;return e=e||{},t.isFunction(o)&&(o=t("<a/>"),e.open=!0),o[0]?(p(),m()&&(i&&(e.onComplete=i),o.each(function(){var i=t.data(this,Y)||{};t.data(this,Y,t.extend(i,e))}).addClass(te),n=new r(o[0],e),n.get("open")&&f(o[0])),o):o},J.position=function(e,i){function n(){T[0].style.width=k[0].style.width=b[0].style.width=parseInt(x[0].style.width,10)-D+"px",b[0].style.height=C[0].style.height=H[0].style.height=parseInt(x[0].style.height,10)-j+"px"}var r,h,s,l=0,d=0,c=x.offset();if(E.unbind("resize."+Z),x.css({top:-9e4,left:-9e4}),h=E.scrollTop(),s=E.scrollLeft(),_.get("fixed")?(c.top-=h,c.left-=s,x.css({position:"fixed"})):(l=h,d=s,x.css({position:"absolute"})),d+=_.get("right")!==!1?Math.max(E.width()-_.w-z-D-a(_.get("right"),"x"),0):_.get("left")!==!1?a(_.get("left"),"x"):Math.round(Math.max(E.width()-_.w-z-D,0)/2),l+=_.get("bottom")!==!1?Math.max(o()-_.h-N-j-a(_.get("bottom"),"y"),0):_.get("top")!==!1?a(_.get("top"),"y"):Math.round(Math.max(o()-_.h-N-j,0)/2),x.css({top:c.top,left:c.left,visibility:"visible"}),y[0].style.width=y[0].style.height="9999px",r={width:_.w+z+D,height:_.h+N+j,top:l,left:d},e){var g=0;t.each(r,function(t){return r[t]!==de[t]?(g=e,void 0):void 0}),e=g}de=r,e||x.css(r),x.dequeue().animate(r,{duration:e||0,complete:function(){n(),$=!1,y[0].style.width=_.w+z+D+"px",y[0].style.height=_.h+N+j+"px",_.get("reposition")&&setTimeout(function(){E.bind("resize."+Z,J.position)},1),t.isFunction(i)&&i()},step:n})},J.resize=function(t){var e;U&&(t=t||{},t.width&&(_.w=a(t.width,"x")-z-D),t.innerWidth&&(_.w=a(t.innerWidth,"x")),I.css({width:_.w}),t.height&&(_.h=a(t.height,"y")-N-j),t.innerHeight&&(_.h=a(t.innerHeight,"y")),t.innerHeight||t.height||(e=I.scrollTop(),I.css({height:"auto"}),_.h=I.height()),I.css({height:_.h}),e&&I.scrollTop(e),J.position("none"===_.get("transition")?0:_.get("speed")))},J.prep=function(i){function o(){return _.w=_.w||I.width(),_.w=_.mw&&_.mw<_.w?_.mw:_.w,_.w}function a(){return _.h=_.h||I.height(),_.h=_.mh&&_.mh<_.h?_.mh:_.h,_.h}if(U){var d,g="none"===_.get("transition")?0:_.get("speed");I.remove(),I=n(se,"LoadedContent").append(i),I.hide().appendTo(M.show()).css({width:o(),overflow:_.get("scrolling")?"auto":"hidden"}).css({height:a()}).prependTo(b),M.hide(),t(q).css({"float":"none"}),c(_.get("className")),d=function(){function i(){t.support.opacity===!1&&x[0].style.removeAttribute("filter")}var n,o,a=W.length;U&&(o=function(){clearTimeout(Q),L.hide(),u(ne),_.get("onComplete")},F.html(_.get("title")).show(),I.show(),a>1?("string"==typeof _.get("current")&&R.html(_.get("current").replace("{current}",A+1).replace("{total}",a)).show(),K[_.get("loop")||a-1>A?"show":"hide"]().html(_.get("next")),P[_.get("loop")||A?"show":"hide"]().html(_.get("previous")),ce(),_.get("preloading")&&t.each([h(-1),h(1)],function(){var i,n=W[this],o=new r(n,t.data(n,Y)),h=o.get("href");h&&s(o,h)&&(h=l(o,h),i=e.createElement("img"),i.src=h)})):O.hide(),_.get("iframe")?(n=_.get("createIframe"),_.get("scrolling")||(n.scrolling="no"),t(n).attr({src:_.get("href"),"class":Z+"Iframe"}).one("load",o).appendTo(I),ae.one(he,function(){n.src="//about:blank"}),_.get("fastIframe")&&t(n).trigger("load")):o(),"fade"===_.get("transition")?x.fadeTo(g,1,i):i())},"fade"===_.get("transition")?x.fadeTo(g,0,function(){J.position(0,d)}):J.position(g,d)}},J.next=function(){!$&&W[1]&&(_.get("loop")||W[A+1])&&(A=h(1),f(W[A]))},J.prev=function(){!$&&W[1]&&(_.get("loop")||A)&&(A=h(-1),f(W[A]))},J.close=function(){U&&!G&&(G=!0,U=!1,u(oe),_.get("onCleanup"),E.unbind("."+Z),v.fadeTo(_.get("fadeOut")||0,0),x.stop().fadeTo(_.get("fadeOut")||0,0,function(){x.hide(),v.hide(),u(he),I.remove(),setTimeout(function(){G=!1,u(re),_.get("onClosed")},1)}))},J.remove=function(){x&&(x.stop(),t[Y].close(),x.stop(!1,!0).remove(),v.remove(),G=!1,x=null,t("."+te).removeData(Y).removeClass(te),t(e).unbind("click."+Z).unbind("keydown."+Z))},J.element=function(){return t(_.el)},J.settings=X)})(jQuery,document,window);
13
  /* Media Uploader */
3
  /* Quill */
4
  !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.Quill=e():t.Quill=e()}("undefined"!=typeof self?self:this,function(){return function(t){function e(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,e),o.l=!0,o.exports}var n={};return e.m=t,e.c=n,e.d=function(t,n,r){e.o(t,n)||Object.defineProperty(t,n,{configurable:!1,enumerable:!0,get:r})},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=45)}([function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(17),o=n(18),i=n(19),l=n(48),a=n(49),s=n(50),u=n(51),c=n(52),f=n(11),h=n(29),p=n(30),d=n(28),y=n(1),v={Scope:y.Scope,create:y.create,find:y.find,query:y.query,register:y.register,Container:r.default,Format:o.default,Leaf:i.default,Embed:u.default,Scroll:l.default,Block:s.default,Inline:a.default,Text:c.default,Attributor:{Attribute:f.default,Class:h.default,Style:p.default,Store:d.default}};e.default=v},function(t,e,n){"use strict";function r(t,e){var n=i(t);if(null==n)throw new s("Unable to create "+t+" blot");var r=n;return new r(t instanceof Node||t.nodeType===Node.TEXT_NODE?t:r.create(e),e)}function o(t,n){return void 0===n&&(n=!1),null==t?null:null!=t[e.DATA_KEY]?t[e.DATA_KEY].blot:n?o(t.parentNode,n):null}function i(t,e){void 0===e&&(e=p.ANY);var n;if("string"==typeof t)n=h[t]||u[t];else if(t instanceof Text||t.nodeType===Node.TEXT_NODE)n=h.text;else if("number"==typeof t)t&p.LEVEL&p.BLOCK?n=h.block:t&p.LEVEL&p.INLINE&&(n=h.inline);else if(t instanceof HTMLElement){var r=(t.getAttribute("class")||"").split(/\s+/);for(var o in r)if(n=c[r[o]])break;n=n||f[t.tagName]}return null==n?null:e&p.LEVEL&n.scope&&e&p.TYPE&n.scope?n:null}function l(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];if(t.length>1)return t.map(function(t){return l(t)});var n=t[0];if("string"!=typeof n.blotName&&"string"!=typeof n.attrName)throw new s("Invalid definition");if("abstract"===n.blotName)throw new s("Cannot register abstract class");if(h[n.blotName||n.attrName]=n,"string"==typeof n.keyName)u[n.keyName]=n;else if(null!=n.className&&(c[n.className]=n),null!=n.tagName){Array.isArray(n.tagName)?n.tagName=n.tagName.map(function(t){return t.toUpperCase()}):n.tagName=n.tagName.toUpperCase();var r=Array.isArray(n.tagName)?n.tagName:[n.tagName];r.forEach(function(t){null!=f[t]&&null!=n.className||(f[t]=n)})}return n}var a=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var s=function(t){function e(e){var n=this;return e="[Parchment] "+e,n=t.call(this,e)||this,n.message=e,n.name=n.constructor.name,n}return a(e,t),e}(Error);e.ParchmentError=s;var u={},c={},f={},h={};e.DATA_KEY="__blot";var p;!function(t){t[t.TYPE=3]="TYPE",t[t.LEVEL=12]="LEVEL",t[t.ATTRIBUTE=13]="ATTRIBUTE",t[t.BLOT=14]="BLOT",t[t.INLINE=7]="INLINE",t[t.BLOCK=11]="BLOCK",t[t.BLOCK_BLOT=10]="BLOCK_BLOT",t[t.INLINE_BLOT=6]="INLINE_BLOT",t[t.BLOCK_ATTRIBUTE=9]="BLOCK_ATTRIBUTE",t[t.INLINE_ATTRIBUTE=5]="INLINE_ATTRIBUTE",t[t.ANY=15]="ANY"}(p=e.Scope||(e.Scope={})),e.create=r,e.find=o,e.query=i,e.register=l},function(t,e){"use strict";var n=Object.prototype.hasOwnProperty,r=Object.prototype.toString,o=function(t){return"function"==typeof Array.isArray?Array.isArray(t):"[object Array]"===r.call(t)},i=function(t){if(!t||"[object Object]"!==r.call(t))return!1;var e=n.call(t,"constructor"),o=t.constructor&&t.constructor.prototype&&n.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!e&&!o)return!1;var i;for(i in t);return void 0===i||n.call(t,i)};t.exports=function t(){var e,n,r,l,a,s,u=arguments[0],c=1,f=arguments.length,h=!1;for("boolean"==typeof u&&(h=u,u=arguments[1]||{},c=2),(null==u||"object"!=typeof u&&"function"!=typeof u)&&(u={});c<f;++c)if(null!=(e=arguments[c]))for(n in e)r=u[n],l=e[n],u!==l&&(h&&l&&(i(l)||(a=o(l)))?(a?(a=!1,s=r&&o(r)?r:[]):s=r&&i(r)?r:{},u[n]=t(h,s,l)):void 0!==l&&(u[n]=l));return u}},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function a(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return null==t?e:("function"==typeof t.formats&&(e=(0,f.default)(e,t.formats())),null==t.parent||"scroll"==t.parent.blotName||t.parent.statics.scope!==t.statics.scope?e:a(t.parent,e))}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.BlockEmbed=e.bubbleFormats=void 0;var s=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),u=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},c=n(2),f=r(c),h=n(4),p=r(h),d=n(0),y=r(d),v=n(14),b=r(v),g=n(5),m=r(g),_=n(8),O=r(_),w=function(t){function e(){return o(this,e),i(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return l(e,t),s(e,[{key:"attach",value:function(){u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"attach",this).call(this),this.attributes=new y.default.Attributor.Store(this.domNode)}},{key:"delta",value:function(){return(new p.default).insert(this.value(),(0,f.default)(this.formats(),this.attributes.values()))}},{key:"format",value:function(t,e){var n=y.default.query(t,y.default.Scope.BLOCK_ATTRIBUTE);null!=n&&this.attributes.attribute(n,e)}},{key:"formatAt",value:function(t,e,n,r){this.format(n,r)}},{key:"insertAt",value:function(t,n,r){if("string"==typeof n&&n.endsWith("\n")){var o=y.default.create(x.blotName);this.parent.insertBefore(o,0===t?this:this.next),o.insertAt(0,n.slice(0,-1))}else u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"insertAt",this).call(this,t,n,r)}}]),e}(y.default.Embed);w.scope=y.default.Scope.BLOCK_BLOT;var x=function(t){function e(t){o(this,e);var n=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return n.cache={},n}return l(e,t),s(e,[{key:"delta",value:function(){return null==this.cache.delta&&(this.cache.delta=this.descendants(y.default.Leaf).reduce(function(t,e){return 0===e.length()?t:t.insert(e.value(),a(e))},new p.default).insert("\n",a(this))),this.cache.delta}},{key:"deleteAt",value:function(t,n){u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"deleteAt",this).call(this,t,n),this.cache={}}},{key:"formatAt",value:function(t,n,r,o){n<=0||(y.default.query(r,y.default.Scope.BLOCK)?t+n===this.length()&&this.format(r,o):u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"formatAt",this).call(this,t,Math.min(n,this.length()-t-1),r,o),this.cache={})}},{key:"insertAt",value:function(t,n,r){if(null!=r)return u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"insertAt",this).call(this,t,n,r);if(0!==n.length){var o=n.split("\n"),i=o.shift();i.length>0&&(t<this.length()-1||null==this.children.tail?u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"insertAt",this).call(this,Math.min(t,this.length()-1),i):this.children.tail.insertAt(this.children.tail.length(),i),this.cache={});var l=this;o.reduce(function(t,e){return l=l.split(t,!0),l.insertAt(0,e),e.length},t+i.length)}}},{key:"insertBefore",value:function(t,n){var r=this.children.head;u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"insertBefore",this).call(this,t,n),r instanceof b.default&&r.remove(),this.cache={}}},{key:"length",value:function(){return null==this.cache.length&&(this.cache.length=u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"length",this).call(this)+1),this.cache.length}},{key:"moveChildren",value:function(t,n){u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"moveChildren",this).call(this,t,n),this.cache={}}},{key:"optimize",value:function(t){u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"optimize",this).call(this,t),this.cache={}}},{key:"path",value:function(t){return u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"path",this).call(this,t,!0)}},{key:"removeChild",value:function(t){u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"removeChild",this).call(this,t),this.cache={}}},{key:"split",value:function(t){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(n&&(0===t||t>=this.length()-1)){var r=this.clone();return 0===t?(this.parent.insertBefore(r,this),this):(this.parent.insertBefore(r,this.next),r)}var o=u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"split",this).call(this,t,n);return this.cache={},o}}]),e}(y.default.Block);x.blotName="block",x.tagName="P",x.defaultChild="break",x.allowedChildren=[m.default,y.default.Embed,O.default],e.bubbleFormats=a,e.BlockEmbed=w,e.default=x},function(t,e,n){var r=n(54),o=n(12),i=n(2),l=n(20),a=String.fromCharCode(0),s=function(t){Array.isArray(t)?this.ops=t:null!=t&&Array.isArray(t.ops)?this.ops=t.ops:this.ops=[]};s.prototype.insert=function(t,e){var n={};return 0===t.length?this:(n.insert=t,null!=e&&"object"==typeof e&&Object.keys(e).length>0&&(n.attributes=e),this.push(n))},s.prototype.delete=function(t){return t<=0?this:this.push({delete:t})},s.prototype.retain=function(t,e){if(t<=0)return this;var n={retain:t};return null!=e&&"object"==typeof e&&Object.keys(e).length>0&&(n.attributes=e),this.push(n)},s.prototype.push=function(t){var e=this.ops.length,n=this.ops[e-1];if(t=i(!0,{},t),"object"==typeof n){if("number"==typeof t.delete&&"number"==typeof n.delete)return this.ops[e-1]={delete:n.delete+t.delete},this;if("number"==typeof n.delete&&null!=t.insert&&(e-=1,"object"!=typeof(n=this.ops[e-1])))return this.ops.unshift(t),this;if(o(t.attributes,n.attributes)){if("string"==typeof t.insert&&"string"==typeof n.insert)return this.ops[e-1]={insert:n.insert+t.insert},"object"==typeof t.attributes&&(this.ops[e-1].attributes=t.attributes),this;if("number"==typeof t.retain&&"number"==typeof n.retain)return this.ops[e-1]={retain:n.retain+t.retain},"object"==typeof t.attributes&&(this.ops[e-1].attributes=t.attributes),this}}return e===this.ops.length?this.ops.push(t):this.ops.splice(e,0,t),this},s.prototype.chop=function(){var t=this.ops[this.ops.length-1];return t&&t.retain&&!t.attributes&&this.ops.pop(),this},s.prototype.filter=function(t){return this.ops.filter(t)},s.prototype.forEach=function(t){this.ops.forEach(t)},s.prototype.map=function(t){return this.ops.map(t)},s.prototype.partition=function(t){var e=[],n=[];return this.forEach(function(r){(t(r)?e:n).push(r)}),[e,n]},s.prototype.reduce=function(t,e){return this.ops.reduce(t,e)},s.prototype.changeLength=function(){return this.reduce(function(t,e){return e.insert?t+l.length(e):e.delete?t-e.delete:t},0)},s.prototype.length=function(){return this.reduce(function(t,e){return t+l.length(e)},0)},s.prototype.slice=function(t,e){t=t||0,"number"!=typeof e&&(e=1/0);for(var n=[],r=l.iterator(this.ops),o=0;o<e&&r.hasNext();){var i;o<t?i=r.next(t-o):(i=r.next(e-o),n.push(i)),o+=l.length(i)}return new s(n)},s.prototype.compose=function(t){for(var e=l.iterator(this.ops),n=l.iterator(t.ops),r=new s;e.hasNext()||n.hasNext();)if("insert"===n.peekType())r.push(n.next());else if("delete"===e.peekType())r.push(e.next());else{var o=Math.min(e.peekLength(),n.peekLength()),i=e.next(o),a=n.next(o);if("number"==typeof a.retain){var u={};"number"==typeof i.retain?u.retain=o:u.insert=i.insert;var c=l.attributes.compose(i.attributes,a.attributes,"number"==typeof i.retain);c&&(u.attributes=c),r.push(u)}else"number"==typeof a.delete&&"number"==typeof i.retain&&r.push(a)}return r.chop()},s.prototype.concat=function(t){var e=new s(this.ops.slice());return t.ops.length>0&&(e.push(t.ops[0]),e.ops=e.ops.concat(t.ops.slice(1))),e},s.prototype.diff=function(t,e){if(this.ops===t.ops)return new s;var n=[this,t].map(function(e){return e.map(function(n){if(null!=n.insert)return"string"==typeof n.insert?n.insert:a;var r=e===t?"on":"with";throw new Error("diff() called "+r+" non-document")}).join("")}),i=new s,u=r(n[0],n[1],e),c=l.iterator(this.ops),f=l.iterator(t.ops);return u.forEach(function(t){for(var e=t[1].length;e>0;){var n=0;switch(t[0]){case r.INSERT:n=Math.min(f.peekLength(),e),i.push(f.next(n));break;case r.DELETE:n=Math.min(e,c.peekLength()),c.next(n),i.delete(n);break;case r.EQUAL:n=Math.min(c.peekLength(),f.peekLength(),e);var a=c.next(n),s=f.next(n);o(a.insert,s.insert)?i.retain(n,l.attributes.diff(a.attributes,s.attributes)):i.push(s).delete(n)}e-=n}}),i.chop()},s.prototype.eachLine=function(t,e){e=e||"\n";for(var n=l.iterator(this.ops),r=new s,o=0;n.hasNext();){if("insert"!==n.peekType())return;var i=n.peek(),a=l.length(i)-n.peekLength(),u="string"==typeof i.insert?i.insert.indexOf(e,a)-a:-1;if(u<0)r.push(n.next());else if(u>0)r.push(n.next(u));else{if(!1===t(r,n.next(1).attributes||{},o))return;o+=1,r=new s}}r.length()>0&&t(r,{},o)},s.prototype.transform=function(t,e){if(e=!!e,"number"==typeof t)return this.transformPosition(t,e);for(var n=l.iterator(this.ops),r=l.iterator(t.ops),o=new s;n.hasNext()||r.hasNext();)if("insert"!==n.peekType()||!e&&"insert"===r.peekType())if("insert"===r.peekType())o.push(r.next());else{var i=Math.min(n.peekLength(),r.peekLength()),a=n.next(i),u=r.next(i);if(a.delete)continue;u.delete?o.push(u):o.retain(i,l.attributes.transform(a.attributes,u.attributes,e))}else o.retain(l.length(n.next()));return o.chop()},s.prototype.transformPosition=function(t,e){e=!!e;for(var n=l.iterator(this.ops),r=0;n.hasNext()&&r<=t;){var o=n.peekLength(),i=n.peekType();n.next(),"delete"!==i?("insert"===i&&(r<t||!e)&&(t+=o),r+=o):t-=Math.min(o,t-r)}return t},t.exports=s},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var a=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),s=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},u=n(8),c=r(u),f=n(0),h=r(f),p=function(t){function e(){return o(this,e),i(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return l(e,t),a(e,[{key:"formatAt",value:function(t,n,r,o){if(e.compare(this.statics.blotName,r)<0&&h.default.query(r,h.default.Scope.BLOT)){var i=this.isolate(t,n);o&&i.wrap(r,o)}else s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"formatAt",this).call(this,t,n,r,o)}},{key:"optimize",value:function(t){if(s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"optimize",this).call(this,t),this.parent instanceof e&&e.compare(this.statics.blotName,this.parent.statics.blotName)>0){var n=this.parent.isolate(this.offset(),this.length());this.moveChildren(n),n.wrap(this)}}}],[{key:"compare",value:function(t,n){var r=e.order.indexOf(t),o=e.order.indexOf(n);return r>=0||o>=0?r-o:t===n?0:t<n?-1:1}}]),e}(h.default.Inline);p.allowedChildren=[p,h.default.Embed,c.default],p.order=["cursor","inline","underline","strike","italic","bold","script","link","code"],e.default=p},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function l(t,e){if(e=(0,N.default)(!0,{container:t,modules:{clipboard:!0,keyboard:!0,history:!0}},e),e.theme&&e.theme!==S.DEFAULTS.theme){if(e.theme=S.import("themes/"+e.theme),null==e.theme)throw new Error("Invalid theme "+e.theme+". Did you register it?")}else e.theme=T.default;var n=(0,N.default)(!0,{},e.theme.DEFAULTS);[n,e].forEach(function(t){t.modules=t.modules||{},Object.keys(t.modules).forEach(function(e){!0===t.modules[e]&&(t.modules[e]={})})});var r=Object.keys(n.modules).concat(Object.keys(e.modules)),o=r.reduce(function(t,e){var n=S.import("modules/"+e);return null==n?P.error("Cannot load "+e+" module. Are you sure you registered it?"):t[e]=n.DEFAULTS||{},t},{});return null!=e.modules&&e.modules.toolbar&&e.modules.toolbar.constructor!==Object&&(e.modules.toolbar={container:e.modules.toolbar}),e=(0,N.default)(!0,{},S.DEFAULTS,{modules:o},n,e),["bounds","container","scrollingContainer"].forEach(function(t){"string"==typeof e[t]&&(e[t]=document.querySelector(e[t]))}),e.modules=Object.keys(e.modules).reduce(function(t,n){return e.modules[n]&&(t[n]=e.modules[n]),t},{}),e}function a(t,e,n,r){if(this.options.strict&&!this.isEnabled()&&e===g.default.sources.USER)return new d.default;var o=null==n?null:this.getSelection(),i=this.editor.delta,l=t();if(null!=o&&(!0===n&&(n=o.index),null==r?o=u(o,l,e):0!==r&&(o=u(o,n,r,e)),this.setSelection(o,g.default.sources.SILENT)),l.length()>0){var a,s=[g.default.events.TEXT_CHANGE,l,i,e];if((a=this.emitter).emit.apply(a,[g.default.events.EDITOR_CHANGE].concat(s)),e!==g.default.sources.SILENT){var c;(c=this.emitter).emit.apply(c,s)}}return l}function s(t,e,n,r,o){var i={};return"number"==typeof t.index&&"number"==typeof t.length?"number"!=typeof e?(o=r,r=n,n=e,e=t.length,t=t.index):(e=t.length,t=t.index):"number"!=typeof e&&(o=r,r=n,n=e,e=0),"object"===(void 0===n?"undefined":c(n))?(i=n,o=r):"string"==typeof n&&(null!=r?i[n]=r:o=n),o=o||g.default.sources.API,[t,e,i,o]}function u(t,e,n,r){if(null==t)return null;var o=void 0,i=void 0;if(e instanceof d.default){var l=[t.index,t.index+t.length].map(function(t){return e.transformPosition(t,r!==g.default.sources.USER)}),a=f(l,2);o=a[0],i=a[1]}else{var s=[t.index,t.index+t.length].map(function(t){return t<e||t===e&&r===g.default.sources.USER?t:n>=0?t+n:Math.max(e,t+n)}),u=f(s,2);o=u[0],i=u[1]}return new x.Range(o,i-o)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.overload=e.expandConfig=void 0;var c="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=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),h=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}();n(53);var p=n(4),d=r(p),y=n(57),v=r(y),b=n(9),g=r(b),m=n(7),_=r(m),O=n(0),w=r(O),x=n(22),k=r(x),E=n(2),N=r(E),j=n(10),A=r(j),q=n(32),T=r(q),P=(0,A.default)("quill"),S=function(){function t(e){var n=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(i(this,t),this.options=l(e,r),this.container=this.options.container,null==this.container)return P.error("Invalid Quill container",e);this.options.debug&&t.debug(this.options.debug);var o=this.container.innerHTML.trim();this.container.classList.add("ql-container"),this.container.innerHTML="",this.container.__quill=this,this.root=this.addContainer("ql-editor"),this.root.classList.add("ql-blank"),this.root.setAttribute("data-gramm",!1),this.scrollingContainer=this.options.scrollingContainer||this.root,this.emitter=new g.default,this.scroll=w.default.create(this.root,{emitter:this.emitter,whitelist:this.options.formats}),this.editor=new v.default(this.scroll),this.selection=new k.default(this.scroll,this.emitter),this.theme=new this.options.theme(this,this.options),this.keyboard=this.theme.addModule("keyboard"),this.clipboard=this.theme.addModule("clipboard"),this.history=this.theme.addModule("history"),this.theme.init(),this.emitter.on(g.default.events.EDITOR_CHANGE,function(t){t===g.default.events.TEXT_CHANGE&&n.root.classList.toggle("ql-blank",n.editor.isBlank())}),this.emitter.on(g.default.events.SCROLL_UPDATE,function(t,e){var r=n.selection.lastRange,o=r&&0===r.length?r.index:void 0;a.call(n,function(){return n.editor.update(null,e,o)},t)});var s=this.clipboard.convert("<div class='ql-editor' style=\"white-space: normal;\">"+o+"<p><br></p></div>");this.setContents(s),this.history.clear(),this.options.placeholder&&this.root.setAttribute("data-placeholder",this.options.placeholder),this.options.readOnly&&this.disable()}return h(t,null,[{key:"debug",value:function(t){!0===t&&(t="log"),A.default.level(t)}},{key:"find",value:function(t){return t.__quill||w.default.find(t)}},{key:"import",value:function(t){return null==this.imports[t]&&P.error("Cannot import "+t+". Are you sure it was registered?"),this.imports[t]}},{key:"register",value:function(t,e){var n=this,r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if("string"!=typeof t){var o=t.attrName||t.blotName;"string"==typeof o?this.register("formats/"+o,t,e):Object.keys(t).forEach(function(r){n.register(r,t[r],e)})}else null==this.imports[t]||r||P.warn("Overwriting "+t+" with",e),this.imports[t]=e,(t.startsWith("blots/")||t.startsWith("formats/"))&&"abstract"!==e.blotName?w.default.register(e):t.startsWith("modules")&&"function"==typeof e.register&&e.register()}}]),h(t,[{key:"addContainer",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if("string"==typeof t){var n=t;t=document.createElement("div"),t.classList.add(n)}return this.container.insertBefore(t,e),t}},{key:"blur",value:function(){this.selection.setRange(null)}},{key:"deleteText",value:function(t,e,n){var r=this,o=s(t,e,n),i=f(o,4);return t=i[0],e=i[1],n=i[3],a.call(this,function(){return r.editor.deleteText(t,e)},n,t,-1*e)}},{key:"disable",value:function(){this.enable(!1)}},{key:"enable",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this.scroll.enable(t),this.container.classList.toggle("ql-disabled",!t)}},{key:"focus",value:function(){var t=this.scrollingContainer.scrollTop;this.selection.focus(),this.scrollingContainer.scrollTop=t,this.scrollIntoView()}},{key:"format",value:function(t,e){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:g.default.sources.API;return a.call(this,function(){var r=n.getSelection(!0),i=new d.default;if(null==r)return i;if(w.default.query(t,w.default.Scope.BLOCK))i=n.editor.formatLine(r.index,r.length,o({},t,e));else{if(0===r.length)return n.selection.format(t,e),i;i=n.editor.formatText(r.index,r.length,o({},t,e))}return n.setSelection(r,g.default.sources.SILENT),i},r)}},{key:"formatLine",value:function(t,e,n,r,o){var i=this,l=void 0,u=s(t,e,n,r,o),c=f(u,4);return t=c[0],e=c[1],l=c[2],o=c[3],a.call(this,function(){return i.editor.formatLine(t,e,l)},o,t,0)}},{key:"formatText",value:function(t,e,n,r,o){var i=this,l=void 0,u=s(t,e,n,r,o),c=f(u,4);return t=c[0],e=c[1],l=c[2],o=c[3],a.call(this,function(){return i.editor.formatText(t,e,l)},o,t,0)}},{key:"getBounds",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=void 0;n="number"==typeof t?this.selection.getBounds(t,e):this.selection.getBounds(t.index,t.length);var r=this.container.getBoundingClientRect();return{bottom:n.bottom-r.top,height:n.height,left:n.left-r.left,right:n.right-r.left,top:n.top-r.top,width:n.width}}},{key:"getContents",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.getLength()-t,n=s(t,e),r=f(n,2);return t=r[0],e=r[1],this.editor.getContents(t,e)}},{key:"getFormat",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.getSelection(!0),e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return"number"==typeof t?this.editor.getFormat(t,e):this.editor.getFormat(t.index,t.length)}},{key:"getIndex",value:function(t){return t.offset(this.scroll)}},{key:"getLength",value:function(){return this.scroll.length()}},{key:"getLeaf",value:function(t){return this.scroll.leaf(t)}},{key:"getLine",value:function(t){return this.scroll.line(t)}},{key:"getLines",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.MAX_VALUE;return"number"!=typeof t?this.scroll.lines(t.index,t.length):this.scroll.lines(t,e)}},{key:"getModule",value:function(t){return this.theme.modules[t]}},{key:"getSelection",value:function(){return arguments.length>0&&void 0!==arguments[0]&&arguments[0]&&this.focus(),this.update(),this.selection.getRange()[0]}},{key:"getText",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.getLength()-t,n=s(t,e),r=f(n,2);return t=r[0],e=r[1],this.editor.getText(t,e)}},{key:"hasFocus",value:function(){return this.selection.hasFocus()}},{key:"insertEmbed",value:function(e,n,r){var o=this,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:t.sources.API;return a.call(this,function(){return o.editor.insertEmbed(e,n,r)},i,e)}},{key:"insertText",value:function(t,e,n,r,o){var i=this,l=void 0,u=s(t,0,n,r,o),c=f(u,4);return t=c[0],l=c[2],o=c[3],a.call(this,function(){return i.editor.insertText(t,e,l)},o,t,e.length)}},{key:"isEnabled",value:function(){return!this.container.classList.contains("ql-disabled")}},{key:"off",value:function(){return this.emitter.off.apply(this.emitter,arguments)}},{key:"on",value:function(){return this.emitter.on.apply(this.emitter,arguments)}},{key:"once",value:function(){return this.emitter.once.apply(this.emitter,arguments)}},{key:"pasteHTML",value:function(t,e,n){this.clipboard.dangerouslyPasteHTML(t,e,n)}},{key:"removeFormat",value:function(t,e,n){var r=this,o=s(t,e,n),i=f(o,4);return t=i[0],e=i[1],n=i[3],a.call(this,function(){return r.editor.removeFormat(t,e)},n,t)}},{key:"scrollIntoView",value:function(){this.selection.scrollIntoView(this.scrollingContainer)}},{key:"setContents",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:g.default.sources.API;return a.call(this,function(){t=new d.default(t);var n=e.getLength(),r=e.editor.deleteText(0,n),o=e.editor.applyDelta(t),i=o.ops[o.ops.length-1];return null!=i&&"string"==typeof i.insert&&"\n"===i.insert[i.insert.length-1]&&(e.editor.deleteText(e.getLength()-1,1),o.delete(1)),r.compose(o)},n)}},{key:"setSelection",value:function(e,n,r){if(null==e)this.selection.setRange(null,n||t.sources.API);else{var o=s(e,n,r),i=f(o,4);e=i[0],n=i[1],r=i[3],this.selection.setRange(new x.Range(e,n),r),r!==g.default.sources.SILENT&&this.selection.scrollIntoView(this.scrollingContainer)}}},{key:"setText",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:g.default.sources.API,n=(new d.default).insert(t);return this.setContents(n,e)}},{key:"update",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:g.default.sources.USER,e=this.scroll.update(t);return this.selection.update(t),e}},{key:"updateContents",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:g.default.sources.API;return a.call(this,function(){return t=new d.default(t),e.editor.applyDelta(t,n)},n,!0)}}]),t}();S.DEFAULTS={bounds:null,formats:null,modules:{},placeholder:"",readOnly:!1,scrollingContainer:null,strict:!0,theme:"default"},S.events=g.default.events,S.sources=g.default.sources,S.version="1.3.6",S.imports={delta:d.default,parchment:w.default,"core/module":_.default,"core/theme":T.default},e.expandConfig=l,e.overload=s,e.default=S},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});var o=function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};r(this,t),this.quill=e,this.options=n};o.DEFAULTS={},e.default=o},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=n(0),a=function(t){return t&&t.__esModule?t:{default:t}}(l),s=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),e}(a.default.Text);e.default=s},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var a=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),s=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},u=n(58),c=r(u),f=n(10),h=r(f),p=(0,h.default)("quill:events");["selectionchange","mousedown","mouseup","click"].forEach(function(t){document.addEventListener(t,function(){for(var t=arguments.length,e=Array(t),n=0;n<t;n++)e[n]=arguments[n];[].slice.call(document.querySelectorAll(".ql-container")).forEach(function(t){if(t.__quill&&t.__quill.emitter){var n;(n=t.__quill.emitter).handleDOM.apply(n,e)}})})});var d=function(t){function e(){o(this,e);var t=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this));return t.listeners={},t.on("error",p.error),t}return l(e,t),a(e,[{key:"emit",value:function(){p.log.apply(p,arguments),s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"emit",this).apply(this,arguments)}},{key:"handleDOM",value:function(t){for(var e=arguments.length,n=Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];(this.listeners[t.type]||[]).forEach(function(e){var r=e.node,o=e.handler;(t.target===r||r.contains(t.target))&&o.apply(void 0,[t].concat(n))})}},{key:"listenDOM",value:function(t,e,n){this.listeners[t]||(this.listeners[t]=[]),this.listeners[t].push({node:e,handler:n})}}]),e}(c.default);d.events={EDITOR_CHANGE:"editor-change",SCROLL_BEFORE_UPDATE:"scroll-before-update",SCROLL_OPTIMIZE:"scroll-optimize",SCROLL_UPDATE:"scroll-update",SELECTION_CHANGE:"selection-change",TEXT_CHANGE:"text-change"},d.sources={API:"api",SILENT:"silent",USER:"user"},e.default=d},function(t,e,n){"use strict";function r(t){if(i.indexOf(t)<=i.indexOf(l)){for(var e,n=arguments.length,r=Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];(e=console)[t].apply(e,r)}}function o(t){return i.reduce(function(e,n){return e[n]=r.bind(console,n,t),e},{})}Object.defineProperty(e,"__esModule",{value:!0});var i=["error","warn","log","info"],l="warn";r.level=o.level=function(t){l=t},e.default=o},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1),o=function(){function t(t,e,n){void 0===n&&(n={}),this.attrName=t,this.keyName=e;var o=r.Scope.TYPE&r.Scope.ATTRIBUTE;null!=n.scope?this.scope=n.scope&r.Scope.LEVEL|o:this.scope=r.Scope.ATTRIBUTE,null!=n.whitelist&&(this.whitelist=n.whitelist)}return t.keys=function(t){return[].map.call(t.attributes,function(t){return t.name})},t.prototype.add=function(t,e){return!!this.canAdd(t,e)&&(t.setAttribute(this.keyName,e),!0)},t.prototype.canAdd=function(t,e){return null!=r.query(t,r.Scope.BLOT&(this.scope|r.Scope.TYPE))&&(null==this.whitelist||("string"==typeof e?this.whitelist.indexOf(e.replace(/["']/g,""))>-1:this.whitelist.indexOf(e)>-1))},t.prototype.remove=function(t){t.removeAttribute(this.keyName)},t.prototype.value=function(t){var e=t.getAttribute(this.keyName);return this.canAdd(t,e)&&e?e:""},t}();e.default=o},function(t,e,n){function r(t){return null===t||void 0===t}function o(t){return!(!t||"object"!=typeof t||"number"!=typeof t.length)&&("function"==typeof t.copy&&"function"==typeof t.slice&&!(t.length>0&&"number"!=typeof t[0]))}function i(t,e,n){var i,c;if(r(t)||r(e))return!1;if(t.prototype!==e.prototype)return!1;if(s(t))return!!s(e)&&(t=l.call(t),e=l.call(e),u(t,e,n));if(o(t)){if(!o(e))return!1;if(t.length!==e.length)return!1;for(i=0;i<t.length;i++)if(t[i]!==e[i])return!1;return!0}try{var f=a(t),h=a(e)}catch(t){return!1}if(f.length!=h.length)return!1;for(f.sort(),h.sort(),i=f.length-1;i>=0;i--)if(f[i]!=h[i])return!1;for(i=f.length-1;i>=0;i--)if(c=f[i],!u(t[c],e[c],n))return!1;return typeof t==typeof e}var l=Array.prototype.slice,a=n(55),s=n(56),u=t.exports=function(t,e,n){return n||(n={}),t===e||(t instanceof Date&&e instanceof Date?t.getTime()===e.getTime():!t||!e||"object"!=typeof t&&"object"!=typeof e?n.strict?t===e:t==e:i(t,e,n))}},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.Code=void 0;var a=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),s=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),u=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},c=n(4),f=r(c),h=n(0),p=r(h),d=n(3),y=r(d),v=n(5),b=r(v),g=n(8),m=r(g),_=function(t){function e(){return o(this,e),i(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return l(e,t),e}(b.default);_.blotName="code",_.tagName="CODE";var O=function(t){function e(){return o(this,e),i(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return l(e,t),s(e,[{key:"delta",value:function(){var t=this,e=this.domNode.textContent;return e.endsWith("\n")&&(e=e.slice(0,-1)),e.split("\n").reduce(function(e,n){return e.insert(n).insert("\n",t.formats())},new f.default)}},{key:"format",value:function(t,n){if(t!==this.statics.blotName||!n){var r=this.descendant(m.default,this.length()-1),o=a(r,1),i=o[0];null!=i&&i.deleteAt(i.length()-1,1),u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"format",this).call(this,t,n)}}},{key:"formatAt",value:function(t,n,r,o){if(0!==n&&null!=p.default.query(r,p.default.Scope.BLOCK)&&(r!==this.statics.blotName||o!==this.statics.formats(this.domNode))){var i=this.newlineIndex(t);if(!(i<0||i>=t+n)){var l=this.newlineIndex(t,!0)+1,a=i-l+1,s=this.isolate(l,a),u=s.next;s.format(r,o),u instanceof e&&u.formatAt(0,t-l+n-a,r,o)}}}},{key:"insertAt",value:function(t,e,n){if(null==n){var r=this.descendant(m.default,t),o=a(r,2),i=o[0],l=o[1];i.insertAt(l,e)}}},{key:"length",value:function(){var t=this.domNode.textContent.length;return this.domNode.textContent.endsWith("\n")?t:t+1}},{key:"newlineIndex",value:function(t){if(arguments.length>1&&void 0!==arguments[1]&&arguments[1])return this.domNode.textContent.slice(0,t).lastIndexOf("\n");var e=this.domNode.textContent.slice(t).indexOf("\n");return e>-1?t+e:-1}},{key:"optimize",value:function(t){this.domNode.textContent.endsWith("\n")||this.appendChild(p.default.create("text","\n")),u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"optimize",this).call(this,t);var n=this.next;null!=n&&n.prev===this&&n.statics.blotName===this.statics.blotName&&this.statics.formats(this.domNode)===n.statics.formats(n.domNode)&&(n.optimize(t),n.moveChildren(this),n.remove())}},{key:"replace",value:function(t){u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"replace",this).call(this,t),[].slice.call(this.domNode.querySelectorAll("*")).forEach(function(t){var e=p.default.find(t);null==e?t.parentNode.removeChild(t):e instanceof p.default.Embed?e.remove():e.unwrap()})}}],[{key:"create",value:function(t){var n=u(e.__proto__||Object.getPrototypeOf(e),"create",this).call(this,t);return n.setAttribute("spellcheck",!1),n}},{key:"formats",value:function(){return!0}}]),e}(y.default);O.blotName="code-block",O.tagName="PRE",O.TAB=" ",e.Code=_,e.default=O},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(0),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,[{key:"insertInto",value:function(t,n){0===t.children.length?a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"insertInto",this).call(this,t,n):this.remove()}},{key:"length",value:function(){return 0}},{key:"value",value:function(){return""}}],[{key:"value",value:function(){}}]),e}(u.default.Embed);c.blotName="break",c.tagName="BR",e.default=c},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function l(t,e){var n=document.createElement("a");n.href=t;var r=n.href.slice(0,n.href.indexOf(":"));return e.indexOf(r)>-1}Object.defineProperty(e,"__esModule",{value:!0}),e.sanitize=e.default=void 0;var a=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),s=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},u=n(5),c=function(t){return t&&t.__esModule?t:{default:t}}(u),f=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),a(e,[{key:"format",value:function(t,n){if(t!==this.statics.blotName||!n)return s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"format",this).call(this,t,n);n=this.constructor.sanitize(n),this.domNode.setAttribute("href",n)}}],[{key:"create",value:function(t){var n=s(e.__proto__||Object.getPrototypeOf(e),"create",this).call(this,t);return t=this.sanitize(t),n.setAttribute("href",t),n.setAttribute("target","_blank"),n}},{key:"formats",value:function(t){return t.getAttribute("href")}},{key:"sanitize",value:function(t){return l(t,this.PROTOCOL_WHITELIST)?t:this.SANITIZED_URL}}]),e}(c.default);f.blotName="link",f.tagName="A",f.SANITIZED_URL="about:blank",f.PROTOCOL_WHITELIST=["http","https","mailto","tel"],e.default=f,e.sanitize=l},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){t.setAttribute(e,!("true"===t.getAttribute(e)))}Object.defineProperty(e,"__esModule",{value:!0});var l="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},a=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),s=n(25),u=r(s),c=n(106),f=r(c),h=0,p=function(){function t(e){var n=this;o(this,t),this.select=e,this.container=document.createElement("span"),this.buildPicker(),this.select.style.display="none",this.select.parentNode.insertBefore(this.container,this.select),this.label.addEventListener("mousedown",function(){n.togglePicker()}),this.label.addEventListener("keydown",function(t){switch(t.keyCode){case u.default.keys.ENTER:n.togglePicker();break;case u.default.keys.ESCAPE:n.escape(),t.preventDefault()}}),this.select.addEventListener("change",this.update.bind(this))}return a(t,[{key:"togglePicker",value:function(){this.container.classList.toggle("ql-expanded"),i(this.label,"aria-expanded"),i(this.options,"aria-hidden")}},{key:"buildItem",value:function(t){var e=this,n=document.createElement("span");return n.tabIndex="0",n.setAttribute("role","button"),n.classList.add("ql-picker-item"),t.hasAttribute("value")&&n.setAttribute("data-value",t.getAttribute("value")),t.textContent&&n.setAttribute("data-label",t.textContent),n.addEventListener("click",function(){e.selectItem(n,!0)}),n.addEventListener("keydown",function(t){switch(t.keyCode){case u.default.keys.ENTER:e.selectItem(n,!0),t.preventDefault();break;case u.default.keys.ESCAPE:e.escape(),t.preventDefault()}}),n}},{key:"buildLabel",value:function(){var t=document.createElement("span");return t.classList.add("ql-picker-label"),t.innerHTML=f.default,t.tabIndex="0",t.setAttribute("role","button"),t.setAttribute("aria-expanded","false"),this.container.appendChild(t),t}},{key:"buildOptions",value:function(){var t=this,e=document.createElement("span");e.classList.add("ql-picker-options"),e.setAttribute("aria-hidden","true"),e.tabIndex="-1",e.id="ql-picker-options-"+h,h+=1,this.label.setAttribute("aria-controls",e.id),this.options=e,[].slice.call(this.select.options).forEach(function(n){var r=t.buildItem(n);e.appendChild(r),!0===n.selected&&t.selectItem(r)}),this.container.appendChild(e)}},{key:"buildPicker",value:function(){var t=this;[].slice.call(this.select.attributes).forEach(function(e){t.container.setAttribute(e.name,e.value)}),this.container.classList.add("ql-picker"),this.label=this.buildLabel(),this.buildOptions()}},{key:"escape",value:function(){var t=this;this.close(),setTimeout(function(){return t.label.focus()},1)}},{key:"close",value:function(){this.container.classList.remove("ql-expanded"),this.label.setAttribute("aria-expanded","false"),this.options.setAttribute("aria-hidden","true")}},{key:"selectItem",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=this.container.querySelector(".ql-selected");if(t!==n&&(null!=n&&n.classList.remove("ql-selected"),null!=t&&(t.classList.add("ql-selected"),this.select.selectedIndex=[].indexOf.call(t.parentNode.children,t),t.hasAttribute("data-value")?this.label.setAttribute("data-value",t.getAttribute("data-value")):this.label.removeAttribute("data-value"),t.hasAttribute("data-label")?this.label.setAttribute("data-label",t.getAttribute("data-label")):this.label.removeAttribute("data-label"),e))){if("function"==typeof Event)this.select.dispatchEvent(new Event("change"));else if("object"===("undefined"==typeof Event?"undefined":l(Event))){var r=document.createEvent("Event");r.initEvent("change",!0,!0),this.select.dispatchEvent(r)}this.close()}}},{key:"update",value:function(){var t=void 0;if(this.select.selectedIndex>-1){var e=this.container.querySelector(".ql-picker-options").children[this.select.selectedIndex];t=this.select.options[this.select.selectedIndex],this.selectItem(e)}else this.selectItem(null);var n=null!=t&&t!==this.select.querySelector("option[selected]");this.label.classList.toggle("ql-active",n)}}]),t}();e.default=p},function(t,e,n){"use strict";function r(t){var e=a.find(t);if(null==e)try{e=a.create(t)}catch(n){e=a.create(a.Scope.INLINE),[].slice.call(t.childNodes).forEach(function(t){e.domNode.appendChild(t)}),t.parentNode&&t.parentNode.replaceChild(e.domNode,t),e.attach()}return e}var o=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var i=n(47),l=n(27),a=n(1),s=function(t){function e(e){var n=t.call(this,e)||this;return n.build(),n}return o(e,t),e.prototype.appendChild=function(t){this.insertBefore(t)},e.prototype.attach=function(){t.prototype.attach.call(this),this.children.forEach(function(t){t.attach()})},e.prototype.build=function(){var t=this;this.children=new i.default,[].slice.call(this.domNode.childNodes).reverse().forEach(function(e){try{var n=r(e);t.insertBefore(n,t.children.head||void 0)}catch(t){if(t instanceof a.ParchmentError)return;throw t}})},e.prototype.deleteAt=function(t,e){if(0===t&&e===this.length())return this.remove();this.children.forEachAt(t,e,function(t,e,n){t.deleteAt(e,n)})},e.prototype.descendant=function(t,n){var r=this.children.find(n),o=r[0],i=r[1];return null==t.blotName&&t(o)||null!=t.blotName&&o instanceof t?[o,i]:o instanceof e?o.descendant(t,i):[null,-1]},e.prototype.descendants=function(t,n,r){void 0===n&&(n=0),void 0===r&&(r=Number.MAX_VALUE);var o=[],i=r;return this.children.forEachAt(n,r,function(n,r,l){(null==t.blotName&&t(n)||null!=t.blotName&&n instanceof t)&&o.push(n),n instanceof e&&(o=o.concat(n.descendants(t,r,i))),i-=l}),o},e.prototype.detach=function(){this.children.forEach(function(t){t.detach()}),t.prototype.detach.call(this)},e.prototype.formatAt=function(t,e,n,r){this.children.forEachAt(t,e,function(t,e,o){t.formatAt(e,o,n,r)})},e.prototype.insertAt=function(t,e,n){var r=this.children.find(t),o=r[0],i=r[1];if(o)o.insertAt(i,e,n);else{var l=null==n?a.create("text",e):a.create(e,n);this.appendChild(l)}},e.prototype.insertBefore=function(t,e){if(null!=this.statics.allowedChildren&&!this.statics.allowedChildren.some(function(e){return t instanceof e}))throw new a.ParchmentError("Cannot insert "+t.statics.blotName+" into "+this.statics.blotName);t.insertInto(this,e)},e.prototype.length=function(){return this.children.reduce(function(t,e){return t+e.length()},0)},e.prototype.moveChildren=function(t,e){this.children.forEach(function(n){t.insertBefore(n,e)})},e.prototype.optimize=function(e){if(t.prototype.optimize.call(this,e),0===this.children.length)if(null!=this.statics.defaultChild){var n=a.create(this.statics.defaultChild);this.appendChild(n),n.optimize(e)}else this.remove()},e.prototype.path=function(t,n){void 0===n&&(n=!1);var r=this.children.find(t,n),o=r[0],i=r[1],l=[[this,t]];return o instanceof e?l.concat(o.path(i,n)):(null!=o&&l.push([o,i]),l)},e.prototype.removeChild=function(t){this.children.remove(t)},e.prototype.replace=function(n){n instanceof e&&n.moveChildren(this),t.prototype.replace.call(this,n)},e.prototype.split=function(t,e){if(void 0===e&&(e=!1),!e){if(0===t)return this;if(t===this.length())return this.next}var n=this.clone();return this.parent.insertBefore(n,this.next),this.children.forEachAt(t,this.length(),function(t,r,o){t=t.split(r,e),n.appendChild(t)}),n},e.prototype.unwrap=function(){this.moveChildren(this.parent,this.next),this.remove()},e.prototype.update=function(t,e){var n=this,o=[],i=[];t.forEach(function(t){t.target===n.domNode&&"childList"===t.type&&(o.push.apply(o,t.addedNodes),i.push.apply(i,t.removedNodes))}),i.forEach(function(t){if(!(null!=t.parentNode&&"IFRAME"!==t.tagName&&document.body.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_CONTAINED_BY)){var e=a.find(t);null!=e&&(null!=e.domNode.parentNode&&e.domNode.parentNode!==n.domNode||e.detach())}}),o.filter(function(t){return t.parentNode==n.domNode}).sort(function(t,e){return t===e?0:t.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_FOLLOWING?1:-1}).forEach(function(t){var e=null;null!=t.nextSibling&&(e=a.find(t.nextSibling));var o=r(t);o.next==e&&null!=o.next||(null!=o.parent&&o.parent.removeChild(n),n.insertBefore(o,e||void 0))})},e}(l.default);e.default=s},function(t,e,n){"use strict";var r=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var o=n(11),i=n(28),l=n(17),a=n(1),s=function(t){function e(e){var n=t.call(this,e)||this;return n.attributes=new i.default(n.domNode),n}return r(e,t),e.formats=function(t){return"string"==typeof this.tagName||(Array.isArray(this.tagName)?t.tagName.toLowerCase():void 0)},e.prototype.format=function(t,e){var n=a.query(t);n instanceof o.default?this.attributes.attribute(n,e):e&&(null==n||t===this.statics.blotName&&this.formats()[t]===e||this.replaceWith(t,e))},e.prototype.formats=function(){var t=this.attributes.values(),e=this.statics.formats(this.domNode);return null!=e&&(t[this.statics.blotName]=e),t},e.prototype.replaceWith=function(e,n){var r=t.prototype.replaceWith.call(this,e,n);return this.attributes.copy(r),r},e.prototype.update=function(e,n){var r=this;t.prototype.update.call(this,e,n),e.some(function(t){return t.target===r.domNode&&"attributes"===t.type})&&this.attributes.build()},e.prototype.wrap=function(n,r){var o=t.prototype.wrap.call(this,n,r);return o instanceof e&&o.statics.scope===this.statics.scope&&this.attributes.move(o),o},e}(l.default);e.default=s},function(t,e,n){"use strict";var r=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var o=n(27),i=n(1),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.value=function(t){return!0},e.prototype.index=function(t,e){return this.domNode===t||this.domNode.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_CONTAINED_BY?Math.min(e,1):-1},e.prototype.position=function(t,e){var n=[].indexOf.call(this.parent.domNode.childNodes,this.domNode);return t>0&&(n+=1),[this.parent.domNode,n]},e.prototype.value=function(){return t={},t[this.statics.blotName]=this.statics.value(this.domNode)||!0,t;var t},e.scope=i.Scope.INLINE_BLOT,e}(o.default);e.default=l},function(t,e,n){function r(t){this.ops=t,this.index=0,this.offset=0}var o=n(12),i=n(2),l={attributes:{compose:function(t,e,n){"object"!=typeof t&&(t={}),"object"!=typeof e&&(e={});var r=i(!0,{},e);n||(r=Object.keys(r).reduce(function(t,e){return null!=r[e]&&(t[e]=r[e]),t},{}));for(var o in t)void 0!==t[o]&&void 0===e[o]&&(r[o]=t[o]);return Object.keys(r).length>0?r:void 0},diff:function(t,e){"object"!=typeof t&&(t={}),"object"!=typeof e&&(e={});var n=Object.keys(t).concat(Object.keys(e)).reduce(function(n,r){return o(t[r],e[r])||(n[r]=void 0===e[r]?null:e[r]),n},{});return Object.keys(n).length>0?n:void 0},transform:function(t,e,n){if("object"!=typeof t)return e;if("object"==typeof e){if(!n)return e;var r=Object.keys(e).reduce(function(n,r){return void 0===t[r]&&(n[r]=e[r]),n},{});return Object.keys(r).length>0?r:void 0}}},iterator:function(t){return new r(t)},length:function(t){return"number"==typeof t.delete?t.delete:"number"==typeof t.retain?t.retain:"string"==typeof t.insert?t.insert.length:1}};r.prototype.hasNext=function(){return this.peekLength()<1/0},r.prototype.next=function(t){t||(t=1/0);var e=this.ops[this.index];if(e){var n=this.offset,r=l.length(e);if(t>=r-n?(t=r-n,this.index+=1,this.offset=0):this.offset+=t,"number"==typeof e.delete)return{delete:t};var o={};return e.attributes&&(o.attributes=e.attributes),"number"==typeof e.retain?o.retain=t:"string"==typeof e.insert?o.insert=e.insert.substr(n,t):o.insert=e.insert,o}return{retain:1/0}},r.prototype.peek=function(){return this.ops[this.index]},r.prototype.peekLength=function(){return this.ops[this.index]?l.length(this.ops[this.index])-this.offset:1/0},r.prototype.peekType=function(){return this.ops[this.index]?"number"==typeof this.ops[this.index].delete?"delete":"number"==typeof this.ops[this.index].retain?"retain":"insert":"retain"},t.exports=l},function(t,e){var n=function(){"use strict";function t(t,e){return null!=e&&t instanceof e}function e(n,r,o,i,c){function f(n,o){if(null===n)return null;if(0===o)return n;var y,v;if("object"!=typeof n)return n;if(t(n,a))y=new a;else if(t(n,s))y=new s;else if(t(n,u))y=new u(function(t,e){n.then(function(e){t(f(e,o-1))},function(t){e(f(t,o-1))})});else if(e.__isArray(n))y=[];else if(e.__isRegExp(n))y=new RegExp(n.source,l(n)),n.lastIndex&&(y.lastIndex=n.lastIndex);else if(e.__isDate(n))y=new Date(n.getTime());else{if(d&&Buffer.isBuffer(n))return y=new Buffer(n.length),n.copy(y),y;t(n,Error)?y=Object.create(n):void 0===i?(v=Object.getPrototypeOf(n),y=Object.create(v)):(y=Object.create(i),v=i)}if(r){var b=h.indexOf(n);if(-1!=b)return p[b];h.push(n),p.push(y)}t(n,a)&&n.forEach(function(t,e){var n=f(e,o-1),r=f(t,o-1);y.set(n,r)}),t(n,s)&&n.forEach(function(t){var e=f(t,o-1);y.add(e)});for(var g in n){var m;v&&(m=Object.getOwnPropertyDescriptor(v,g)),m&&null==m.set||(y[g]=f(n[g],o-1))}if(Object.getOwnPropertySymbols)for(var _=Object.getOwnPropertySymbols(n),g=0;g<_.length;g++){var O=_[g],w=Object.getOwnPropertyDescriptor(n,O);(!w||w.enumerable||c)&&(y[O]=f(n[O],o-1),w.enumerable||Object.defineProperty(y,O,{enumerable:!1}))}if(c)for(var x=Object.getOwnPropertyNames(n),g=0;g<x.length;g++){var k=x[g],w=Object.getOwnPropertyDescriptor(n,k);w&&w.enumerable||(y[k]=f(n[k],o-1),Object.defineProperty(y,k,{enumerable:!1}))}return y}"object"==typeof r&&(o=r.depth,i=r.prototype,c=r.includeNonEnumerable,r=r.circular);var h=[],p=[],d="undefined"!=typeof Buffer;return void 0===r&&(r=!0),void 0===o&&(o=1/0),f(n,o)}function n(t){return Object.prototype.toString.call(t)}function r(t){return"object"==typeof t&&"[object Date]"===n(t)}function o(t){return"object"==typeof t&&"[object Array]"===n(t)}function i(t){return"object"==typeof t&&"[object RegExp]"===n(t)}function l(t){var e="";return t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),e}var a;try{a=Map}catch(t){a=function(){}}var s;try{s=Set}catch(t){s=function(){}}var u;try{u=Promise}catch(t){u=function(){}}return e.clonePrototype=function(t){if(null===t)return null;var e=function(){};return e.prototype=t,new e},e.__objToStr=n,e.__isDate=r,e.__isArray=o,e.__isRegExp=i,e.__getRegExpFlags=l,e}();"object"==typeof t&&t.exports&&(t.exports=n)},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e<t.length;e++)n[e]=t[e];return n}return Array.from(t)}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function l(t,e){try{e.parentNode}catch(t){return!1}return e instanceof Text&&(e=e.parentNode),t.contains(e)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.Range=void 0;var a=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),s=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),u=n(0),c=r(u),f=n(21),h=r(f),p=n(12),d=r(p),y=n(9),v=r(y),b=n(10),g=r(b),m=(0,g.default)("quill:selection"),_=function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;i(this,t),this.index=e,this.length=n},O=function(){function t(e,n){var r=this;i(this,t),this.emitter=n,this.scroll=e,this.composing=!1,this.mouseDown=!1,this.root=this.scroll.domNode,this.cursor=c.default.create("cursor",this),this.lastRange=this.savedRange=new _(0,0),this.handleComposition(),this.handleDragging(),this.emitter.listenDOM("selectionchange",document,function(){r.mouseDown||setTimeout(r.update.bind(r,v.default.sources.USER),1)}),this.emitter.on(v.default.events.EDITOR_CHANGE,function(t,e){t===v.default.events.TEXT_CHANGE&&e.length()>0&&r.update(v.default.sources.SILENT)}),this.emitter.on(v.default.events.SCROLL_BEFORE_UPDATE,function(){if(r.hasFocus()){var t=r.getNativeRange();null!=t&&t.start.node!==r.cursor.textNode&&r.emitter.once(v.default.events.SCROLL_UPDATE,function(){try{r.setNativeRange(t.start.node,t.start.offset,t.end.node,t.end.offset)}catch(t){}})}}),this.emitter.on(v.default.events.SCROLL_OPTIMIZE,function(t,e){if(e.range){var n=e.range,o=n.startNode,i=n.startOffset,l=n.endNode,a=n.endOffset;r.setNativeRange(o,i,l,a)}}),this.update(v.default.sources.SILENT)}return s(t,[{key:"handleComposition",value:function(){var t=this;this.root.addEventListener("compositionstart",function(){t.composing=!0}),this.root.addEventListener("compositionend",function(){if(t.composing=!1,t.cursor.parent){var e=t.cursor.restore();if(!e)return;setTimeout(function(){t.setNativeRange(e.startNode,e.startOffset,e.endNode,e.endOffset)},1)}})}},{key:"handleDragging",value:function(){var t=this;this.emitter.listenDOM("mousedown",document.body,function(){t.mouseDown=!0}),this.emitter.listenDOM("mouseup",document.body,function(){t.mouseDown=!1,t.update(v.default.sources.USER)})}},{key:"focus",value:function(){this.hasFocus()||(this.root.focus(),this.setRange(this.savedRange))}},{key:"format",value:function(t,e){if(null==this.scroll.whitelist||this.scroll.whitelist[t]){this.scroll.update();var n=this.getNativeRange();if(null!=n&&n.native.collapsed&&!c.default.query(t,c.default.Scope.BLOCK)){if(n.start.node!==this.cursor.textNode){var r=c.default.find(n.start.node,!1);if(null==r)return;if(r instanceof c.default.Leaf){var o=r.split(n.start.offset);r.parent.insertBefore(this.cursor,o)}else r.insertBefore(this.cursor,n.start.node);this.cursor.attach()}this.cursor.format(t,e),this.scroll.optimize(),this.setNativeRange(this.cursor.textNode,this.cursor.textNode.data.length),this.update()}}}},{key:"getBounds",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=this.scroll.length();t=Math.min(t,n-1),e=Math.min(t+e,n-1)-t;var r=void 0,o=this.scroll.leaf(t),i=a(o,2),l=i[0],s=i[1];if(null==l)return null;var u=l.position(s,!0),c=a(u,2);r=c[0],s=c[1];var f=document.createRange();if(e>0){f.setStart(r,s);var h=this.scroll.leaf(t+e),p=a(h,2);if(l=p[0],s=p[1],null==l)return null;var d=l.position(s,!0),y=a(d,2);return r=y[0],s=y[1],f.setEnd(r,s),f.getBoundingClientRect()}var v="left",b=void 0;return r instanceof Text?(s<r.data.length?(f.setStart(r,s),f.setEnd(r,s+1)):(f.setStart(r,s-1),f.setEnd(r,s),v="right"),b=f.getBoundingClientRect()):(b=l.domNode.getBoundingClientRect(),s>0&&(v="right")),{bottom:b.top+b.height,height:b.height,left:b[v],right:b[v],top:b.top,width:0}}},{key:"getNativeRange",value:function(){var t=document.getSelection();if(null==t||t.rangeCount<=0)return null;var e=t.getRangeAt(0);if(null==e)return null;var n=this.normalizeNative(e);return m.info("getNativeRange",n),n}},{key:"getRange",value:function(){var t=this.getNativeRange();return null==t?[null,null]:[this.normalizedToRange(t),t]}},{key:"hasFocus",value:function(){return document.activeElement===this.root}},{key:"normalizedToRange",value:function(t){var e=this,n=[[t.start.node,t.start.offset]];t.native.collapsed||n.push([t.end.node,t.end.offset]);var r=n.map(function(t){var n=a(t,2),r=n[0],o=n[1],i=c.default.find(r,!0),l=i.offset(e.scroll);return 0===o?l:i instanceof c.default.Container?l+i.length():l+i.index(r,o)}),i=Math.min(Math.max.apply(Math,o(r)),this.scroll.length()-1),l=Math.min.apply(Math,[i].concat(o(r)));return new _(l,i-l)}},{key:"normalizeNative",value:function(t){if(!l(this.root,t.startContainer)||!t.collapsed&&!l(this.root,t.endContainer))return null;var e={start:{node:t.startContainer,offset:t.startOffset},end:{node:t.endContainer,offset:t.endOffset},native:t};return[e.start,e.end].forEach(function(t){for(var e=t.node,n=t.offset;!(e instanceof Text)&&e.childNodes.length>0;)if(e.childNodes.length>n)e=e.childNodes[n],n=0;else{if(e.childNodes.length!==n)break;e=e.lastChild,n=e instanceof Text?e.data.length:e.childNodes.length+1}t.node=e,t.offset=n}),e}},{key:"rangeToNative",value:function(t){var e=this,n=t.collapsed?[t.index]:[t.index,t.index+t.length],r=[],o=this.scroll.length();return n.forEach(function(t,n){t=Math.min(o-1,t);var i=void 0,l=e.scroll.leaf(t),s=a(l,2),u=s[0],c=s[1],f=u.position(c,0!==n),h=a(f,2);i=h[0],c=h[1],r.push(i,c)}),r.length<2&&(r=r.concat(r)),r}},{key:"scrollIntoView",value:function(t){var e=this.lastRange;if(null!=e){var n=this.getBounds(e.index,e.length);if(null!=n){var r=this.scroll.length()-1,o=this.scroll.line(Math.min(e.index,r)),i=a(o,1),l=i[0],s=l;if(e.length>0){var u=this.scroll.line(Math.min(e.index+e.length,r));s=a(u,1)[0]}if(null!=l&&null!=s){var c=t.getBoundingClientRect();n.top<c.top?t.scrollTop-=c.top-n.top:n.bottom>c.bottom&&(t.scrollTop+=n.bottom-c.bottom)}}}}},{key:"setNativeRange",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:e,o=arguments.length>4&&void 0!==arguments[4]&&arguments[4];if(m.info("setNativeRange",t,e,n,r),null==t||null!=this.root.parentNode&&null!=t.parentNode&&null!=n.parentNode){var i=document.getSelection();if(null!=i)if(null!=t){this.hasFocus()||this.root.focus();var l=(this.getNativeRange()||{}).native;if(null==l||o||t!==l.startContainer||e!==l.startOffset||n!==l.endContainer||r!==l.endOffset){"BR"==t.tagName&&(e=[].indexOf.call(t.parentNode.childNodes,t),t=t.parentNode),"BR"==n.tagName&&(r=[].indexOf.call(n.parentNode.childNodes,n),n=n.parentNode);var a=document.createRange();a.setStart(t,e),a.setEnd(n,r),i.removeAllRanges(),i.addRange(a)}}else i.removeAllRanges(),this.root.blur(),document.body.focus()}}},{key:"setRange",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:v.default.sources.API;if("string"==typeof e&&(n=e,e=!1),m.info("setRange",t),null!=t){var r=this.rangeToNative(t);this.setNativeRange.apply(this,o(r).concat([e]))}else this.setNativeRange(null);this.update(n)}},{key:"update",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:v.default.sources.USER,e=this.lastRange,n=this.getRange(),r=a(n,2),o=r[0],i=r[1];if(this.lastRange=o,null!=this.lastRange&&(this.savedRange=this.lastRange),!(0,d.default)(e,this.lastRange)){var l;!this.composing&&null!=i&&i.native.collapsed&&i.start.node!==this.cursor.textNode&&this.cursor.restore();var s=[v.default.events.SELECTION_CHANGE,(0,h.default)(this.lastRange),(0,h.default)(e),t];if((l=this.emitter).emit.apply(l,[v.default.events.EDITOR_CHANGE].concat(s)),t!==v.default.sources.SILENT){var u;(u=this.emitter).emit.apply(u,s)}}}}]),t}();e.Range=_,e.default=O},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var a=n(0),s=r(a),u=n(3),c=r(u),f=function(t){function e(){return o(this,e),i(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return l(e,t),e}(s.default.Container);f.allowedChildren=[c.default,u.BlockEmbed,f],e.default=f},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0}),e.ColorStyle=e.ColorClass=e.ColorAttributor=void 0;var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(0),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,[{key:"value",value:function(t){var n=a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"value",this).call(this,t);return n.startsWith("rgb(")?(n=n.replace(/^[^\d]+/,"").replace(/[^\d]+$/,""),"#"+n.split(",").map(function(t){return("00"+parseInt(t).toString(16)).slice(-2)}).join("")):n}}]),e}(u.default.Attributor.Style),f=new u.default.Attributor.Class("color","ql-color",{scope:u.default.Scope.INLINE}),h=new c("color","color",{scope:u.default.Scope.INLINE});e.ColorAttributor=c,e.ColorClass=f,e.ColorStyle=h},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function l(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function s(t,e){var n,r=t===D.keys.LEFT?"prefix":"suffix";return n={key:t,shiftKey:e,altKey:null},o(n,r,/^$/),o(n,"handler",function(n){var r=n.index;t===D.keys.RIGHT&&(r+=n.length+1);var o=this.quill.getLeaf(r);return!(b(o,1)[0]instanceof T.default.Embed)||(t===D.keys.LEFT?e?this.quill.setSelection(n.index-1,n.length+1,S.default.sources.USER):this.quill.setSelection(n.index-1,S.default.sources.USER):e?this.quill.setSelection(n.index,n.length+1,S.default.sources.USER):this.quill.setSelection(n.index+n.length+1,S.default.sources.USER),!1)}),n}function u(t,e){if(!(0===t.index||this.quill.getLength()<=1)){var n=this.quill.getLine(t.index),r=b(n,1),o=r[0],i={};if(0===e.offset){var l=this.quill.getLine(t.index-1),a=b(l,1),s=a[0];if(null!=s&&s.length()>1){var u=o.formats(),c=this.quill.getFormat(t.index-1,1);i=A.default.attributes.diff(u,c)||{}}}var f=/[\uD800-\uDBFF][\uDC00-\uDFFF]$/.test(e.prefix)?2:1;this.quill.deleteText(t.index-f,f,S.default.sources.USER),Object.keys(i).length>0&&this.quill.formatLine(t.index-f,f,i,S.default.sources.USER),this.quill.focus()}}function c(t,e){var n=/^[\uD800-\uDBFF][\uDC00-\uDFFF]/.test(e.suffix)?2:1;if(!(t.index>=this.quill.getLength()-n)){var r={},o=0,i=this.quill.getLine(t.index),l=b(i,1),a=l[0];if(e.offset>=a.length()-1){var s=this.quill.getLine(t.index+1),u=b(s,1),c=u[0];if(c){var f=a.formats(),h=this.quill.getFormat(t.index,1);r=A.default.attributes.diff(f,h)||{},o=c.length()}}this.quill.deleteText(t.index,n,S.default.sources.USER),Object.keys(r).length>0&&this.quill.formatLine(t.index+o-1,n,r,S.default.sources.USER)}}function f(t){var e=this.quill.getLines(t),n={};if(e.length>1){var r=e[0].formats(),o=e[e.length-1].formats();n=A.default.attributes.diff(o,r)||{}}this.quill.deleteText(t,S.default.sources.USER),Object.keys(n).length>0&&this.quill.formatLine(t.index,1,n,S.default.sources.USER),this.quill.setSelection(t.index,S.default.sources.SILENT),this.quill.focus()}function h(t,e){var n=this;t.length>0&&this.quill.scroll.deleteAt(t.index,t.length);var r=Object.keys(e.format).reduce(function(t,n){return T.default.query(n,T.default.Scope.BLOCK)&&!Array.isArray(e.format[n])&&(t[n]=e.format[n]),t},{});this.quill.insertText(t.index,"\n",r,S.default.sources.USER),this.quill.setSelection(t.index+1,S.default.sources.SILENT),this.quill.focus(),Object.keys(e.format).forEach(function(t){null==r[t]&&(Array.isArray(e.format[t])||"link"!==t&&n.quill.format(t,e.format[t],S.default.sources.USER))})}function p(t){return{key:D.keys.TAB,shiftKey:!t,format:{"code-block":!0},handler:function(e){var n=T.default.query("code-block"),r=e.index,o=e.length,i=this.quill.scroll.descendant(n,r),l=b(i,2),a=l[0],s=l[1];if(null!=a){var u=this.quill.getIndex(a),c=a.newlineIndex(s,!0)+1,f=a.newlineIndex(u+s+o),h=a.domNode.textContent.slice(c,f).split("\n");s=0,h.forEach(function(e,i){t?(a.insertAt(c+s,n.TAB),s+=n.TAB.length,0===i?r+=n.TAB.length:o+=n.TAB.length):e.startsWith(n.TAB)&&(a.deleteAt(c+s,n.TAB.length),s-=n.TAB.length,0===i?r-=n.TAB.length:o-=n.TAB.length),s+=e.length+1}),this.quill.update(S.default.sources.USER),this.quill.setSelection(r,o,S.default.sources.SILENT)}}}}function d(t){return{key:t[0].toUpperCase(),shortKey:!0,handler:function(e,n){this.quill.format(t,!n.format[t],S.default.sources.USER)}}}function y(t){if("string"==typeof t||"number"==typeof t)return y({key:t});if("object"===(void 0===t?"undefined":v(t))&&(t=(0,_.default)(t,!1)),"string"==typeof t.key)if(null!=D.keys[t.key.toUpperCase()])t.key=D.keys[t.key.toUpperCase()];else{if(1!==t.key.length)return null;t.key=t.key.toUpperCase().charCodeAt(0)}return t.shortKey&&(t[B]=t.shortKey,delete t.shortKey),t}Object.defineProperty(e,"__esModule",{value:!0}),e.SHORTKEY=e.default=void 0;var v="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},b=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),g=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),m=n(21),_=r(m),O=n(12),w=r(O),x=n(2),k=r(x),E=n(4),N=r(E),j=n(20),A=r(j),q=n(0),T=r(q),P=n(6),S=r(P),C=n(10),L=r(C),M=n(7),R=r(M),I=(0,L.default)("quill:keyboard"),B=/Mac/i.test(navigator.platform)?"metaKey":"ctrlKey",D=function(t){function e(t,n){i(this,e);var r=l(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.bindings={},Object.keys(r.options.bindings).forEach(function(e){("list autofill"!==e||null==t.scroll.whitelist||t.scroll.whitelist.list)&&r.options.bindings[e]&&r.addBinding(r.options.bindings[e])}),r.addBinding({key:e.keys.ENTER,shiftKey:null},h),r.addBinding({key:e.keys.ENTER,metaKey:null,ctrlKey:null,altKey:null},function(){}),/Firefox/i.test(navigator.userAgent)?(r.addBinding({key:e.keys.BACKSPACE},{collapsed:!0},u),r.addBinding({key:e.keys.DELETE},{collapsed:!0},c)):(r.addBinding({key:e.keys.BACKSPACE},{collapsed:!0,prefix:/^.?$/},u),r.addBinding({key:e.keys.DELETE},{collapsed:!0,suffix:/^.?$/},c)),r.addBinding({key:e.keys.BACKSPACE},{collapsed:!1},f),r.addBinding({key:e.keys.DELETE},{collapsed:!1},f),r.addBinding({key:e.keys.BACKSPACE,altKey:null,ctrlKey:null,metaKey:null,shiftKey:null},{collapsed:!0,offset:0},u),r.listen(),r}return a(e,t),g(e,null,[{key:"match",value:function(t,e){return e=y(e),!["altKey","ctrlKey","metaKey","shiftKey"].some(function(n){return!!e[n]!==t[n]&&null!==e[n]})&&e.key===(t.which||t.keyCode)}}]),g(e,[{key:"addBinding",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=y(t);if(null==r||null==r.key)return I.warn("Attempted to add invalid keyboard binding",r);"function"==typeof e&&(e={handler:e}),"function"==typeof n&&(n={handler:n}),r=(0,k.default)(r,e,n),this.bindings[r.key]=this.bindings[r.key]||[],this.bindings[r.key].push(r)}},{key:"listen",value:function(){var t=this;this.quill.root.addEventListener("keydown",function(n){if(!n.defaultPrevented){var r=n.which||n.keyCode,o=(t.bindings[r]||[]).filter(function(t){return e.match(n,t)});if(0!==o.length){var i=t.quill.getSelection();if(null!=i&&t.quill.hasFocus()){var l=t.quill.getLine(i.index),a=b(l,2),s=a[0],u=a[1],c=t.quill.getLeaf(i.index),f=b(c,2),h=f[0],p=f[1],d=0===i.length?[h,p]:t.quill.getLeaf(i.index+i.length),y=b(d,2),g=y[0],m=y[1],_=h instanceof T.default.Text?h.value().slice(0,p):"",O=g instanceof T.default.Text?g.value().slice(m):"",x={collapsed:0===i.length,empty:0===i.length&&s.length()<=1,format:t.quill.getFormat(i),offset:u,prefix:_,suffix:O};o.some(function(e){if(null!=e.collapsed&&e.collapsed!==x.collapsed)return!1;if(null!=e.empty&&e.empty!==x.empty)return!1;if(null!=e.offset&&e.offset!==x.offset)return!1;if(Array.isArray(e.format)){if(e.format.every(function(t){return null==x.format[t]}))return!1}else if("object"===v(e.format)&&!Object.keys(e.format).every(function(t){return!0===e.format[t]?null!=x.format[t]:!1===e.format[t]?null==x.format[t]:(0,w.default)(e.format[t],x.format[t])}))return!1;return!(null!=e.prefix&&!e.prefix.test(x.prefix))&&(!(null!=e.suffix&&!e.suffix.test(x.suffix))&&!0!==e.handler.call(t,i,x))})&&n.preventDefault()}}}})}}]),e}(R.default);D.keys={BACKSPACE:8,TAB:9,ENTER:13,ESCAPE:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46},D.DEFAULTS={bindings:{bold:d("bold"),italic:d("italic"),underline:d("underline"),indent:{key:D.keys.TAB,format:["blockquote","indent","list"],handler:function(t,e){if(e.collapsed&&0!==e.offset)return!0;this.quill.format("indent","+1",S.default.sources.USER)}},outdent:{key:D.keys.TAB,shiftKey:!0,format:["blockquote","indent","list"],handler:function(t,e){if(e.collapsed&&0!==e.offset)return!0;this.quill.format("indent","-1",S.default.sources.USER)}},"outdent backspace":{key:D.keys.BACKSPACE,collapsed:!0,shiftKey:null,metaKey:null,ctrlKey:null,altKey:null,format:["indent","list"],offset:0,handler:function(t,e){null!=e.format.indent?this.quill.format("indent","-1",S.default.sources.USER):null!=e.format.list&&this.quill.format("list",!1,S.default.sources.USER)}},"indent code-block":p(!0),"outdent code-block":p(!1),"remove tab":{key:D.keys.TAB,shiftKey:!0,collapsed:!0,prefix:/\t$/,handler:function(t){this.quill.deleteText(t.index-1,1,S.default.sources.USER)}},tab:{key:D.keys.TAB,handler:function(t){this.quill.history.cutoff();var e=(new N.default).retain(t.index).delete(t.length).insert("\t");this.quill.updateContents(e,S.default.sources.USER),this.quill.history.cutoff(),this.quill.setSelection(t.index+1,S.default.sources.SILENT)}},"list empty enter":{key:D.keys.ENTER,collapsed:!0,format:["list"],empty:!0,handler:function(t,e){this.quill.format("list",!1,S.default.sources.USER),e.format.indent&&this.quill.format("indent",!1,S.default.sources.USER)}},"checklist enter":{key:D.keys.ENTER,collapsed:!0,format:{list:"checked"},handler:function(t){var e=this.quill.getLine(t.index),n=b(e,2),r=n[0],o=n[1],i=(0,k.default)({},r.formats(),{list:"checked"}),l=(new N.default).retain(t.index).insert("\n",i).retain(r.length()-o-1).retain(1,{list:"unchecked"});this.quill.updateContents(l,S.default.sources.USER),this.quill.setSelection(t.index+1,S.default.sources.SILENT),this.quill.scrollIntoView()}},"header enter":{key:D.keys.ENTER,collapsed:!0,format:["header"],suffix:/^$/,handler:function(t,e){var n=this.quill.getLine(t.index),r=b(n,2),o=r[0],i=r[1],l=(new N.default).retain(t.index).insert("\n",e.format).retain(o.length()-i-1).retain(1,{header:null});this.quill.updateContents(l,S.default.sources.USER),this.quill.setSelection(t.index+1,S.default.sources.SILENT),this.quill.scrollIntoView()}},"list autofill":{key:" ",collapsed:!0,format:{list:!1},prefix:/^\s*?(\d+\.|-|\*|\[ ?\]|\[x\])$/,handler:function(t,e){var n=e.prefix.length,r=this.quill.getLine(t.index),o=b(r,2),i=o[0],l=o[1];if(l>n)return!0;var a=void 0;switch(e.prefix.trim()){case"[]":case"[ ]":a="unchecked";break;case"[x]":a="checked";break;case"-":case"*":a="bullet";break;default:a="ordered"}this.quill.insertText(t.index," ",S.default.sources.USER),this.quill.history.cutoff();var s=(new N.default).retain(t.index-l).delete(n+1).retain(i.length()-2-l).retain(1,{list:a});this.quill.updateContents(s,S.default.sources.USER),this.quill.history.cutoff(),this.quill.setSelection(t.index-n,S.default.sources.SILENT)}},"code exit":{key:D.keys.ENTER,collapsed:!0,format:["code-block"],prefix:/\n\n$/,suffix:/^\s+$/,handler:function(t){var e=this.quill.getLine(t.index),n=b(e,2),r=n[0],o=n[1],i=(new N.default).retain(t.index+r.length()-o-2).retain(1,{"code-block":null}).delete(1);this.quill.updateContents(i,S.default.sources.USER)}},"embed left":s(D.keys.LEFT,!1),"embed left shift":s(D.keys.LEFT,!0),"embed right":s(D.keys.RIGHT,!1),"embed right shift":s(D.keys.RIGHT,!0)}},e.default=D,e.SHORTKEY=B},function(t,e,n){"use strict";t.exports={align:{"":n(75),center:n(76),right:n(77),justify:n(78)},background:n(79),blockquote:n(80),bold:n(81),clean:n(82),code:n(40),"code-block":n(40),color:n(83),direction:{"":n(84),rtl:n(85)},float:{center:n(86),full:n(87),left:n(88),right:n(89)},formula:n(90),header:{1:n(91),2:n(92)},italic:n(93),image:n(94),indent:{"+1":n(95),"-1":n(96)},link:n(97),list:{ordered:n(98),bullet:n(99),check:n(100)},script:{sub:n(101),super:n(102)},strike:n(103),underline:n(104),video:n(105)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1),o=function(){function t(t){this.domNode=t,this.domNode[r.DATA_KEY]={blot:this}}return Object.defineProperty(t.prototype,"statics",{get:function(){return this.constructor},enumerable:!0,configurable:!0}),t.create=function(t){if(null==this.tagName)throw new r.ParchmentError("Blot definition missing tagName");var e;return Array.isArray(this.tagName)?("string"==typeof t&&(t=t.toUpperCase(),parseInt(t).toString()===t&&(t=parseInt(t))),e="number"==typeof t?document.createElement(this.tagName[t-1]):this.tagName.indexOf(t)>-1?document.createElement(t):document.createElement(this.tagName[0])):e=document.createElement(this.tagName),this.className&&e.classList.add(this.className),e},t.prototype.attach=function(){null!=this.parent&&(this.scroll=this.parent.scroll)},t.prototype.clone=function(){var t=this.domNode.cloneNode(!1);return r.create(t)},t.prototype.detach=function(){null!=this.parent&&this.parent.removeChild(this),delete this.domNode[r.DATA_KEY]},t.prototype.deleteAt=function(t,e){this.isolate(t,e).remove()},t.prototype.formatAt=function(t,e,n,o){var i=this.isolate(t,e);if(null!=r.query(n,r.Scope.BLOT)&&o)i.wrap(n,o);else if(null!=r.query(n,r.Scope.ATTRIBUTE)){var l=r.create(this.statics.scope);i.wrap(l),l.format(n,o)}},t.prototype.insertAt=function(t,e,n){var o=null==n?r.create("text",e):r.create(e,n),i=this.split(t);this.parent.insertBefore(o,i)},t.prototype.insertInto=function(t,e){void 0===e&&(e=null),null!=this.parent&&this.parent.children.remove(this);var n=null;t.children.insertBefore(this,e),null!=e&&(n=e.domNode),this.domNode.parentNode==t.domNode&&this.domNode.nextSibling==n||t.domNode.insertBefore(this.domNode,n),this.parent=t,this.attach()},t.prototype.isolate=function(t,e){var n=this.split(t);return n.split(e),n},t.prototype.length=function(){return 1},t.prototype.offset=function(t){return void 0===t&&(t=this.parent),null==this.parent||this==t?0:this.parent.children.offset(this)+this.parent.offset(t)},t.prototype.optimize=function(t){null!=this.domNode[r.DATA_KEY]&&delete this.domNode[r.DATA_KEY].mutations},t.prototype.remove=function(){null!=this.domNode.parentNode&&this.domNode.parentNode.removeChild(this.domNode),this.detach()},t.prototype.replace=function(t){null!=t.parent&&(t.parent.insertBefore(this,t.next),t.remove())},t.prototype.replaceWith=function(t,e){var n="string"==typeof t?r.create(t,e):t;return n.replace(this),n},t.prototype.split=function(t,e){return 0===t?this:this.next},t.prototype.update=function(t,e){},t.prototype.wrap=function(t,e){var n="string"==typeof t?r.create(t,e):t;return null!=this.parent&&this.parent.insertBefore(n,this.next),n.appendChild(this),n},t.blotName="abstract",t}();e.default=o},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(11),o=n(29),i=n(30),l=n(1),a=function(){function t(t){this.attributes={},this.domNode=t,this.build()}return t.prototype.attribute=function(t,e){e?t.add(this.domNode,e)&&(null!=t.value(this.domNode)?this.attributes[t.attrName]=t:delete this.attributes[t.attrName]):(t.remove(this.domNode),delete this.attributes[t.attrName])},t.prototype.build=function(){var t=this;this.attributes={};var e=r.default.keys(this.domNode),n=o.default.keys(this.domNode),a=i.default.keys(this.domNode);e.concat(n).concat(a).forEach(function(e){var n=l.query(e,l.Scope.ATTRIBUTE);n instanceof r.default&&(t.attributes[n.attrName]=n)})},t.prototype.copy=function(t){var e=this;Object.keys(this.attributes).forEach(function(n){var r=e.attributes[n].value(e.domNode);t.format(n,r)})},t.prototype.move=function(t){var e=this;this.copy(t),Object.keys(this.attributes).forEach(function(t){e.attributes[t].remove(e.domNode)}),this.attributes={}},t.prototype.values=function(){var t=this;return Object.keys(this.attributes).reduce(function(e,n){return e[n]=t.attributes[n].value(t.domNode),e},{})},t}();e.default=a},function(t,e,n){"use strict";function r(t,e){return(t.getAttribute("class")||"").split(/\s+/).filter(function(t){return 0===t.indexOf(e+"-")})}var o=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var i=n(11),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return o(e,t),e.keys=function(t){return(t.getAttribute("class")||"").split(/\s+/).map(function(t){return t.split("-").slice(0,-1).join("-")})},e.prototype.add=function(t,e){return!!this.canAdd(t,e)&&(this.remove(t),t.classList.add(this.keyName+"-"+e),!0)},e.prototype.remove=function(t){r(t,this.keyName).forEach(function(e){t.classList.remove(e)}),0===t.classList.length&&t.removeAttribute("class")},e.prototype.value=function(t){var e=r(t,this.keyName)[0]||"",n=e.slice(this.keyName.length+1);return this.canAdd(t,n)?n:""},e}(i.default);e.default=l},function(t,e,n){"use strict";function r(t){var e=t.split("-"),n=e.slice(1).map(function(t){return t[0].toUpperCase()+t.slice(1)}).join("");return e[0]+n}var o=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var i=n(11),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return o(e,t),e.keys=function(t){return(t.getAttribute("style")||"").split(";").map(function(t){return t.split(":")[0].trim()})},e.prototype.add=function(t,e){return!!this.canAdd(t,e)&&(t.style[r(this.keyName)]=e,!0)},e.prototype.remove=function(t){t.style[r(this.keyName)]="",t.getAttribute("style")||t.removeAttribute("style")},e.prototype.value=function(t){var e=t.style[r(this.keyName)];return this.canAdd(t,e)?e:""},e}(i.default);e.default=l},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var a=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),s=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},u=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),c=n(0),f=r(c),h=n(8),p=r(h),d=function(t){function e(t,n){o(this,e);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return r.selection=n,r.textNode=document.createTextNode(e.CONTENTS),r.domNode.appendChild(r.textNode),r._length=0,r}return l(e,t),u(e,null,[{key:"value",value:function(){}}]),u(e,[{key:"detach",value:function(){null!=this.parent&&this.parent.removeChild(this)}},{key:"format",value:function(t,n){if(0!==this._length)return s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"format",this).call(this,t,n);for(var r=this,o=0;null!=r&&r.statics.scope!==f.default.Scope.BLOCK_BLOT;)o+=r.offset(r.parent),r=r.parent;null!=r&&(this._length=e.CONTENTS.length,r.optimize(),r.formatAt(o,e.CONTENTS.length,t,n),this._length=0)}},{key:"index",value:function(t,n){return t===this.textNode?0:s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"index",this).call(this,t,n)}},{key:"length",value:function(){return this._length}},{key:"position",value:function(){return[this.textNode,this.textNode.data.length]}},{key:"remove",value:function(){s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"remove",this).call(this),this.parent=null}},{key:"restore",value:function(){if(!this.selection.composing&&null!=this.parent){var t=this.textNode,n=this.selection.getNativeRange(),r=void 0,o=void 0,i=void 0;if(null!=n&&n.start.node===t&&n.end.node===t){var l=[t,n.start.offset,n.end.offset];r=l[0],o=l[1],i=l[2]}for(;null!=this.domNode.lastChild&&this.domNode.lastChild!==this.textNode;)this.domNode.parentNode.insertBefore(this.domNode.lastChild,this.domNode);if(this.textNode.data!==e.CONTENTS){var s=this.textNode.data.split(e.CONTENTS).join("");this.next instanceof p.default?(r=this.next.domNode,this.next.insertAt(0,s),this.textNode.data=e.CONTENTS):(this.textNode.data=s,this.parent.insertBefore(f.default.create(this.textNode),this),this.textNode=document.createTextNode(e.CONTENTS),this.domNode.appendChild(this.textNode))}if(this.remove(),null!=o){var u=[o,i].map(function(t){return Math.max(0,Math.min(r.data.length,t-1))}),c=a(u,2);return o=c[0],i=c[1],{startNode:r,startOffset:o,endNode:r,endOffset:i}}}}},{key:"update",value:function(t,e){var n=this;if(t.some(function(t){return"characterData"===t.type&&t.target===n.textNode})){var r=this.restore();r&&(e.range=r)}}},{key:"value",value:function(){return""}}]),e}(f.default.Embed);d.blotName="cursor",d.className="ql-cursor",d.tagName="span",d.CONTENTS="\ufeff",e.default=d},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});var o=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),i=function(){function t(e,n){r(this,t),this.quill=e,this.options=n,this.modules={}}return o(t,[{key:"init",value:function(){var t=this;Object.keys(this.options.modules).forEach(function(e){null==t.modules[e]&&t.addModule(e)})}},{key:"addModule",value:function(t){var e=this.quill.constructor.import("modules/"+t);return this.modules[t]=new e(this.quill,this.options.modules[t]||{}),this.modules[t]}}]),t}();i.DEFAULTS={modules:{}},i.themes={default:i},e.default=i},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var a=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),s=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},u=n(0),c=r(u),f=n(8),h=r(f),p="\ufeff",d=function(t){function e(t){o(this,e);var n=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return n.contentNode=document.createElement("span"),n.contentNode.setAttribute("contenteditable",!1),[].slice.call(n.domNode.childNodes).forEach(function(t){n.contentNode.appendChild(t)}),n.leftGuard=document.createTextNode(p),n.rightGuard=document.createTextNode(p),n.domNode.appendChild(n.leftGuard),n.domNode.appendChild(n.contentNode),n.domNode.appendChild(n.rightGuard),n}return l(e,t),a(e,[{key:"index",value:function(t,n){return t===this.leftGuard?0:t===this.rightGuard?1:s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"index",this).call(this,t,n)}},{key:"restore",value:function(t){var e=void 0,n=void 0,r=t.data.split(p).join("");if(t===this.leftGuard)if(this.prev instanceof h.default){var o=this.prev.length();this.prev.insertAt(o,r),e={startNode:this.prev.domNode,startOffset:o+r.length}}else n=document.createTextNode(r),this.parent.insertBefore(c.default.create(n),this),e={startNode:n,startOffset:r.length};else t===this.rightGuard&&(this.next instanceof h.default?(this.next.insertAt(0,r),e={startNode:this.next.domNode,startOffset:r.length}):(n=document.createTextNode(r),this.parent.insertBefore(c.default.create(n),this.next),e={startNode:n,startOffset:r.length}));return t.data=p,e}},{key:"update",value:function(t,e){var n=this;t.forEach(function(t){if("characterData"===t.type&&(t.target===n.leftGuard||t.target===n.rightGuard)){var r=n.restore(t.target);r&&(e.range=r)}})}}]),e}(c.default.Embed);e.default=d},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AlignStyle=e.AlignClass=e.AlignAttribute=void 0;var r=n(0),o=function(t){return t&&t.__esModule?t:{default:t}}(r),i={scope:o.default.Scope.BLOCK,whitelist:["right","center","justify"]},l=new o.default.Attributor.Attribute("align","align",i),a=new o.default.Attributor.Class("align","ql-align",i),s=new o.default.Attributor.Style("align","text-align",i);e.AlignAttribute=l,e.AlignClass=a,e.AlignStyle=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BackgroundStyle=e.BackgroundClass=void 0;var r=n(0),o=function(t){return t&&t.__esModule?t:{default:t}}(r),i=n(24),l=new o.default.Attributor.Class("background","ql-bg",{scope:o.default.Scope.INLINE}),a=new i.ColorAttributor("background","background-color",{scope:o.default.Scope.INLINE});e.BackgroundClass=l,e.BackgroundStyle=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DirectionStyle=e.DirectionClass=e.DirectionAttribute=void 0;var r=n(0),o=function(t){return t&&t.__esModule?t:{default:t}}(r),i={scope:o.default.Scope.BLOCK,whitelist:["rtl"]},l=new o.default.Attributor.Attribute("direction","dir",i),a=new o.default.Attributor.Class("direction","ql-direction",i),s=new o.default.Attributor.Style("direction","direction",i);e.DirectionAttribute=l,e.DirectionClass=a,e.DirectionStyle=s},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0}),e.FontClass=e.FontStyle=void 0;var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(0),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c={scope:u.default.Scope.INLINE,whitelist:["serif","monospace"]},f=new u.default.Attributor.Class("font","ql-font",c),h=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,[{key:"value",value:function(t){return a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"value",this).call(this,t).replace(/["']/g,"")}}]),e}(u.default.Attributor.Style),p=new h("font","font-family",c);e.FontStyle=p,e.FontClass=f},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.SizeStyle=e.SizeClass=void 0;var r=n(0),o=function(t){return t&&t.__esModule?t:{default:t}}(r),i=new o.default.Attributor.Class("size","ql-size",{scope:o.default.Scope.INLINE,whitelist:["small","large","huge"]}),l=new o.default.Attributor.Style("size","font-size",{scope:o.default.Scope.INLINE,whitelist:["10px","18px","32px"]});e.SizeClass=i,e.SizeStyle=l},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(5),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,[{key:"optimize",value:function(t){a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"optimize",this).call(this,t),this.domNode.tagName!==this.statics.tagName[0]&&this.replaceWith(this.statics.blotName)}}],[{key:"create",value:function(){return a(e.__proto__||Object.getPrototypeOf(e),"create",this).call(this)}},{key:"formats",value:function(){return!0}}]),e}(u.default);c.blotName="bold",c.tagName=["STRONG","B"],e.default=c},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <polyline class="ql-even ql-stroke" points="5 7 3 9 5 11"></polyline> <polyline class="ql-even ql-stroke" points="13 7 15 9 13 11"></polyline> <line class=ql-stroke x1=10 x2=8 y1=5 y2=13></line> </svg>'},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(16),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c=function(t){function e(t,n){r(this,e);var i=o(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return i.label.innerHTML=n,i.container.classList.add("ql-color-picker"),[].slice.call(i.container.querySelectorAll(".ql-picker-item"),0,7).forEach(function(t){t.classList.add("ql-primary")}),i}return i(e,t),l(e,[{key:"buildItem",value:function(t){var n=a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"buildItem",this).call(this,t);return n.style.backgroundColor=t.getAttribute("value")||"",n}},{key:"selectItem",value:function(t,n){a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"selectItem",this).call(this,t,n);var r=this.label.querySelector(".ql-color-label"),o=t?t.getAttribute("data-value")||"":"";r&&("line"===r.tagName?r.style.stroke=o:r.style.fill=o)}}]),e}(u.default);e.default=c},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(16),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c=function(t){function e(t,n){r(this,e);var i=o(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return i.container.classList.add("ql-icon-picker"),[].forEach.call(i.container.querySelectorAll(".ql-picker-item"),function(t){t.innerHTML=n[t.getAttribute("data-value")||""]}),i.defaultItem=i.container.querySelector(".ql-selected"),i.selectItem(i.defaultItem),i}return i(e,t),l(e,[{key:"selectItem",value:function(t,n){a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"selectItem",this).call(this,t,n),t=t||this.defaultItem,this.label.innerHTML=t.innerHTML}}]),e}(u.default);e.default=c},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(e,"__esModule",{value:!0});var o=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),i=function(){function t(e,n){var o=this;r(this,t),this.quill=e,this.boundsContainer=n||document.body,this.root=e.addContainer("ql-tooltip"),this.root.innerHTML=this.constructor.TEMPLATE,this.quill.root===this.quill.scrollingContainer&&this.quill.root.addEventListener("scroll",function(){o.root.style.marginTop=-1*o.quill.root.scrollTop+"px"}),this.hide()}return o(t,[{key:"hide",value:function(){this.root.classList.add("ql-hidden")}},{key:"position",value:function(t){var e=t.left+t.width/2-this.root.offsetWidth/2,n=t.bottom+this.quill.root.scrollTop;this.root.style.left=e+"px",this.root.style.top=n+"px",this.root.classList.remove("ql-flip");var r=this.boundsContainer.getBoundingClientRect(),o=this.root.getBoundingClientRect(),i=0;if(o.right>r.right&&(i=r.right-o.right,this.root.style.left=e+i+"px"),o.left<r.left&&(i=r.left-o.left,this.root.style.left=e+i+"px"),o.bottom>r.bottom){var l=o.bottom-o.top,a=t.bottom-t.top+l;this.root.style.top=n-a+"px",this.root.classList.add("ql-flip")}return i}},{key:"show",value:function(){this.root.classList.remove("ql-editing"),this.root.classList.remove("ql-hidden")}}]),t}();e.default=i},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function a(t){var e=t.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtube\.com\/watch.*v=([a-zA-Z0-9_-]+)/)||t.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtu\.be\/([a-zA-Z0-9_-]+)/);return e?(e[1]||"https")+"://www.youtube.com/embed/"+e[2]+"?showinfo=0":(e=t.match(/^(?:(https?):\/\/)?(?:www\.)?vimeo\.com\/(\d+)/))?(e[1]||"https")+"://player.vimeo.com/video/"+e[2]+"/":t}function s(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];e.forEach(function(e){var r=document.createElement("option");e===n?r.setAttribute("selected","selected"):r.setAttribute("value",e),t.appendChild(r)})}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.BaseTooltip=void 0;var u=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),c=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},f=n(2),h=r(f),p=n(4),d=r(p),y=n(9),v=r(y),b=n(25),g=r(b),m=n(32),_=r(m),O=n(41),w=r(O),x=n(42),k=r(x),E=n(16),N=r(E),j=n(43),A=r(j),q=[!1,"center","right","justify"],T=["#000000","#e60000","#ff9900","#ffff00","#008a00","#0066cc","#9933ff","#ffffff","#facccc","#ffebcc","#ffffcc","#cce8cc","#cce0f5","#ebd6ff","#bbbbbb","#f06666","#ffc266","#ffff66","#66b966","#66a3e0","#c285ff","#888888","#a10000","#b26b00","#b2b200","#006100","#0047b2","#6b24b2","#444444","#5c0000","#663d00","#666600","#003700","#002966","#3d1466"],P=[!1,"serif","monospace"],S=["1","2","3",!1],C=["small",!1,"large","huge"],L=function(t){function e(t,n){o(this,e);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n)),l=function e(n){if(!document.body.contains(t.root))return document.body.removeEventListener("click",e);null==r.tooltip||r.tooltip.root.contains(n.target)||document.activeElement===r.tooltip.textbox||r.quill.hasFocus()||r.tooltip.hide(),null!=r.pickers&&r.pickers.forEach(function(t){t.container.contains(n.target)||t.close()})};return t.emitter.listenDOM("click",document.body,l),r}return l(e,t),u(e,[{key:"addModule",value:function(t){var n=c(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"addModule",this).call(this,t);return"toolbar"===t&&this.extendToolbar(n),n}},{key:"buildButtons",value:function(t,e){t.forEach(function(t){(t.getAttribute("class")||"").split(/\s+/).forEach(function(n){if(n.startsWith("ql-")&&(n=n.slice("ql-".length),null!=e[n]))if("direction"===n)t.innerHTML=e[n][""]+e[n].rtl;else if("string"==typeof e[n])t.innerHTML=e[n];else{var r=t.value||"";null!=r&&e[n][r]&&(t.innerHTML=e[n][r])}})})}},{key:"buildPickers",value:function(t,e){var n=this;this.pickers=t.map(function(t){if(t.classList.contains("ql-align"))return null==t.querySelector("option")&&s(t,q),new k.default(t,e.align);if(t.classList.contains("ql-background")||t.classList.contains("ql-color")){var n=t.classList.contains("ql-background")?"background":"color";return null==t.querySelector("option")&&s(t,T,"background"===n?"#ffffff":"#000000"),new w.default(t,e[n])}return null==t.querySelector("option")&&(t.classList.contains("ql-font")?s(t,P):t.classList.contains("ql-header")?s(t,S):t.classList.contains("ql-size")&&s(t,C)),new N.default(t)});var r=function(){n.pickers.forEach(function(t){t.update()})};this.quill.on(v.default.events.EDITOR_CHANGE,r)}}]),e}(_.default);L.DEFAULTS=(0,h.default)(!0,{},_.default.DEFAULTS,{modules:{toolbar:{handlers:{formula:function(){this.quill.theme.tooltip.edit("formula")},image:function(){var t=this,e=this.container.querySelector("input.ql-image[type=file]");null==e&&(e=document.createElement("input"),e.setAttribute("type","file"),e.setAttribute("accept","image/png, image/gif, image/jpeg, image/bmp, image/x-icon"),e.classList.add("ql-image"),e.addEventListener("change",function(){if(null!=e.files&&null!=e.files[0]){var n=new FileReader;n.onload=function(n){var r=t.quill.getSelection(!0);t.quill.updateContents((new d.default).retain(r.index).delete(r.length).insert({image:n.target.result}),v.default.sources.USER),t.quill.setSelection(r.index+1,v.default.sources.SILENT),e.value=""},n.readAsDataURL(e.files[0])}}),this.container.appendChild(e)),e.click()},video:function(){this.quill.theme.tooltip.edit("video")}}}}});var M=function(t){function e(t,n){o(this,e);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.textbox=r.root.querySelector('input[type="text"]'),r.listen(),r}return l(e,t),u(e,[{key:"listen",value:function(){var t=this;this.textbox.addEventListener("keydown",function(e){g.default.match(e,"enter")?(t.save(),e.preventDefault()):g.default.match(e,"escape")&&(t.cancel(),e.preventDefault())})}},{key:"cancel",value:function(){this.hide()}},{key:"edit",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"link",e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;this.root.classList.remove("ql-hidden"),this.root.classList.add("ql-editing"),null!=e?this.textbox.value=e:t!==this.root.getAttribute("data-mode")&&(this.textbox.value=""),this.position(this.quill.getBounds(this.quill.selection.savedRange)),this.textbox.select(),this.textbox.setAttribute("placeholder",this.textbox.getAttribute("data-"+t)||""),this.root.setAttribute("data-mode",t)}},{key:"restoreFocus",value:function(){var t=this.quill.scrollingContainer.scrollTop;this.quill.focus(),this.quill.scrollingContainer.scrollTop=t}},{key:"save",value:function(){var t=this.textbox.value;switch(this.root.getAttribute("data-mode")){case"link":var e=this.quill.root.scrollTop;this.linkRange?(this.quill.formatText(this.linkRange,"link",t,v.default.sources.USER),delete this.linkRange):(this.restoreFocus(),this.quill.format("link",t,v.default.sources.USER)),this.quill.root.scrollTop=e;break;case"video":t=a(t);case"formula":if(!t)break;var n=this.quill.getSelection(!0);if(null!=n){var r=n.index+n.length;this.quill.insertEmbed(r,this.root.getAttribute("data-mode"),t,v.default.sources.USER),"formula"===this.root.getAttribute("data-mode")&&this.quill.insertText(r+1," ",v.default.sources.USER),this.quill.setSelection(r+2,v.default.sources.USER)}}this.textbox.value="",this.hide()}}]),e}(A.default);e.BaseTooltip=M,e.default=L},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(46),i=r(o),l=n(34),a=n(36),s=n(62),u=n(63),c=r(u),f=n(64),h=r(f),p=n(65),d=r(p),y=n(35),v=n(24),b=n(37),g=n(38),m=n(39),_=r(m),O=n(66),w=r(O),x=n(15),k=r(x),E=n(67),N=r(E),j=n(68),A=r(j),q=n(69),T=r(q),P=n(70),S=r(P),C=n(71),L=r(C),M=n(13),R=r(M),I=n(72),B=r(I),D=n(73),U=r(D),F=n(74),H=r(F),K=n(26),z=r(K),Z=n(16),V=r(Z),W=n(41),G=r(W),Y=n(42),X=r(Y),$=n(43),Q=r($),J=n(107),tt=r(J),et=n(108),nt=r(et);i.default.register({"attributors/attribute/direction":a.DirectionAttribute,"attributors/class/align":l.AlignClass,"attributors/class/background":y.BackgroundClass,"attributors/class/color":v.ColorClass,"attributors/class/direction":a.DirectionClass,"attributors/class/font":b.FontClass,"attributors/class/size":g.SizeClass,"attributors/style/align":l.AlignStyle,"attributors/style/background":y.BackgroundStyle,"attributors/style/color":v.ColorStyle,"attributors/style/direction":a.DirectionStyle,"attributors/style/font":b.FontStyle,"attributors/style/size":g.SizeStyle},!0),i.default.register({"formats/align":l.AlignClass,"formats/direction":a.DirectionClass,"formats/indent":s.IndentClass,"formats/background":y.BackgroundStyle,"formats/color":v.ColorStyle,"formats/font":b.FontClass,"formats/size":g.SizeClass,"formats/blockquote":c.default,"formats/code-block":R.default,"formats/header":h.default,"formats/list":d.default,"formats/bold":_.default,"formats/code":M.Code,"formats/italic":w.default,"formats/link":k.default,"formats/script":N.default,"formats/strike":A.default,"formats/underline":T.default,"formats/image":S.default,"formats/video":L.default,"formats/list/item":p.ListItem,"modules/formula":B.default,"modules/syntax":U.default,"modules/toolbar":H.default,"themes/bubble":tt.default,"themes/snow":nt.default,"ui/icons":z.default,"ui/picker":V.default,"ui/icon-picker":X.default,"ui/color-picker":G.default,"ui/tooltip":Q.default},!0),e.default=i.default},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(0),i=r(o),l=n(6),a=r(l),s=n(3),u=r(s),c=n(14),f=r(c),h=n(23),p=r(h),d=n(31),y=r(d),v=n(33),b=r(v),g=n(5),m=r(g),_=n(59),O=r(_),w=n(8),x=r(w),k=n(60),E=r(k),N=n(61),j=r(N),A=n(25),q=r(A);a.default.register({"blots/block":u.default,"blots/block/embed":s.BlockEmbed,"blots/break":f.default,"blots/container":p.default,"blots/cursor":y.default,"blots/embed":b.default,"blots/inline":m.default,"blots/scroll":O.default,"blots/text":x.default,"modules/clipboard":E.default,"modules/history":j.default,"modules/keyboard":q.default}),i.default.register(u.default,f.default,y.default,m.default,O.default,x.default),e.default=a.default},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=function(){function t(){this.head=this.tail=null,this.length=0}return t.prototype.append=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this.insertBefore(t[0],null),t.length>1&&this.append.apply(this,t.slice(1))},t.prototype.contains=function(t){for(var e,n=this.iterator();e=n();)if(e===t)return!0;return!1},t.prototype.insertBefore=function(t,e){t&&(t.next=e,null!=e?(t.prev=e.prev,null!=e.prev&&(e.prev.next=t),e.prev=t,e===this.head&&(this.head=t)):null!=this.tail?(this.tail.next=t,t.prev=this.tail,this.tail=t):(t.prev=null,this.head=this.tail=t),this.length+=1)},t.prototype.offset=function(t){for(var e=0,n=this.head;null!=n;){if(n===t)return e;e+=n.length(),n=n.next}return-1},t.prototype.remove=function(t){this.contains(t)&&(null!=t.prev&&(t.prev.next=t.next),null!=t.next&&(t.next.prev=t.prev),t===this.head&&(this.head=t.next),t===this.tail&&(this.tail=t.prev),this.length-=1)},t.prototype.iterator=function(t){return void 0===t&&(t=this.head),function(){var e=t;return null!=t&&(t=t.next),e}},t.prototype.find=function(t,e){void 0===e&&(e=!1);for(var n,r=this.iterator();n=r();){var o=n.length();if(t<o||e&&t===o&&(null==n.next||0!==n.next.length()))return[n,t];t-=o}return[null,0]},t.prototype.forEach=function(t){for(var e,n=this.iterator();e=n();)t(e)},t.prototype.forEachAt=function(t,e,n){if(!(e<=0))for(var r,o=this.find(t),i=o[0],l=o[1],a=t-l,s=this.iterator(i);(r=s())&&a<t+e;){var u=r.length();t>a?n(r,t-a,Math.min(e,a+u-t)):n(r,0,Math.min(u,t+e-a)),a+=u}},t.prototype.map=function(t){return this.reduce(function(e,n){return e.push(t(n)),e},[])},t.prototype.reduce=function(t,e){for(var n,r=this.iterator();n=r();)e=t(e,n);return e},t}();e.default=r},function(t,e,n){"use strict";var r=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var o=n(17),i=n(1),l={attributes:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0},a=function(t){function e(e){var n=t.call(this,e)||this;return n.scroll=n,n.observer=new MutationObserver(function(t){n.update(t)}),n.observer.observe(n.domNode,l),n.attach(),n}return r(e,t),e.prototype.detach=function(){t.prototype.detach.call(this),this.observer.disconnect()},e.prototype.deleteAt=function(e,n){this.update(),0===e&&n===this.length()?this.children.forEach(function(t){t.remove()}):t.prototype.deleteAt.call(this,e,n)},e.prototype.formatAt=function(e,n,r,o){this.update(),t.prototype.formatAt.call(this,e,n,r,o)},e.prototype.insertAt=function(e,n,r){this.update(),t.prototype.insertAt.call(this,e,n,r)},e.prototype.optimize=function(e,n){var r=this;void 0===e&&(e=[]),void 0===n&&(n={}),t.prototype.optimize.call(this,n);for(var l=[].slice.call(this.observer.takeRecords());l.length>0;)e.push(l.pop());for(var a=function(t,e){void 0===e&&(e=!0),null!=t&&t!==r&&null!=t.domNode.parentNode&&(null==t.domNode[i.DATA_KEY].mutations&&(t.domNode[i.DATA_KEY].mutations=[]),e&&a(t.parent))},s=function(t){null!=t.domNode[i.DATA_KEY]&&null!=t.domNode[i.DATA_KEY].mutations&&(t instanceof o.default&&t.children.forEach(s),t.optimize(n))},u=e,c=0;u.length>0;c+=1){if(c>=100)throw new Error("[Parchment] Maximum optimize iterations reached");for(u.forEach(function(t){var e=i.find(t.target,!0);null!=e&&(e.domNode===t.target&&("childList"===t.type?(a(i.find(t.previousSibling,!1)),[].forEach.call(t.addedNodes,function(t){var e=i.find(t,!1);a(e,!1),e instanceof o.default&&e.children.forEach(function(t){a(t,!1)})})):"attributes"===t.type&&a(e.prev)),a(e))}),this.children.forEach(s),u=[].slice.call(this.observer.takeRecords()),l=u.slice();l.length>0;)e.push(l.pop())}},e.prototype.update=function(e,n){var r=this;void 0===n&&(n={}),e=e||this.observer.takeRecords(),e.map(function(t){var e=i.find(t.target,!0);return null==e?null:null==e.domNode[i.DATA_KEY].mutations?(e.domNode[i.DATA_KEY].mutations=[t],e):(e.domNode[i.DATA_KEY].mutations.push(t),null)}).forEach(function(t){null!=t&&t!==r&&null!=t.domNode[i.DATA_KEY]&&t.update(t.domNode[i.DATA_KEY].mutations||[],n)}),null!=this.domNode[i.DATA_KEY].mutations&&t.prototype.update.call(this,this.domNode[i.DATA_KEY].mutations,n),this.optimize(e,n)},e.blotName="scroll",e.defaultChild="block",e.scope=i.Scope.BLOCK_BLOT,e.tagName="DIV",e}(o.default);e.default=a},function(t,e,n){"use strict";function r(t,e){if(Object.keys(t).length!==Object.keys(e).length)return!1;for(var n in t)if(t[n]!==e[n])return!1;return!0}var o=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var i=n(18),l=n(1),a=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return o(e,t),e.formats=function(n){if(n.tagName!==e.tagName)return t.formats.call(this,n)},e.prototype.format=function(n,r){var o=this;n!==this.statics.blotName||r?t.prototype.format.call(this,n,r):(this.children.forEach(function(t){t instanceof i.default||(t=t.wrap(e.blotName,!0)),o.attributes.copy(t)}),this.unwrap())},e.prototype.formatAt=function(e,n,r,o){if(null!=this.formats()[r]||l.query(r,l.Scope.ATTRIBUTE)){this.isolate(e,n).format(r,o)}else t.prototype.formatAt.call(this,e,n,r,o)},e.prototype.optimize=function(n){t.prototype.optimize.call(this,n);var o=this.formats();if(0===Object.keys(o).length)return this.unwrap();var i=this.next;i instanceof e&&i.prev===this&&r(o,i.formats())&&(i.moveChildren(this),i.remove())},e.blotName="inline",e.scope=l.Scope.INLINE_BLOT,e.tagName="SPAN",e}(i.default);e.default=a},function(t,e,n){"use strict";var r=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var o=n(18),i=n(1),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.formats=function(n){var r=i.query(e.blotName).tagName;if(n.tagName!==r)return t.formats.call(this,n)},e.prototype.format=function(n,r){null!=i.query(n,i.Scope.BLOCK)&&(n!==this.statics.blotName||r?t.prototype.format.call(this,n,r):this.replaceWith(e.blotName))},e.prototype.formatAt=function(e,n,r,o){null!=i.query(r,i.Scope.BLOCK)?this.format(r,o):t.prototype.formatAt.call(this,e,n,r,o)},e.prototype.insertAt=function(e,n,r){if(null==r||null!=i.query(n,i.Scope.INLINE))t.prototype.insertAt.call(this,e,n,r);else{var o=this.split(e),l=i.create(n,r);o.parent.insertBefore(l,o)}},e.prototype.update=function(e,n){navigator.userAgent.match(/Trident/)?this.build():t.prototype.update.call(this,e,n)},e.blotName="block",e.scope=i.Scope.BLOCK_BLOT,e.tagName="P",e}(o.default);e.default=l},function(t,e,n){"use strict";var r=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var o=n(19),i=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r(e,t),e.formats=function(t){},e.prototype.format=function(e,n){t.prototype.formatAt.call(this,0,this.length(),e,n)},e.prototype.formatAt=function(e,n,r,o){0===e&&n===this.length()?this.format(r,o):t.prototype.formatAt.call(this,e,n,r,o)},e.prototype.formats=function(){return this.statics.formats(this.domNode)},e}(o.default);e.default=i},function(t,e,n){"use strict";var r=this&&this.__extends||function(){var t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])};return function(e,n){function r(){this.constructor=e}t(e,n),e.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}();Object.defineProperty(e,"__esModule",{value:!0});var o=n(19),i=n(1),l=function(t){function e(e){var n=t.call(this,e)||this;return n.text=n.statics.value(n.domNode),n}return r(e,t),e.create=function(t){return document.createTextNode(t)},e.value=function(t){var e=t.data;return e.normalize&&(e=e.normalize()),e},e.prototype.deleteAt=function(t,e){this.domNode.data=this.text=this.text.slice(0,t)+this.text.slice(t+e)},e.prototype.index=function(t,e){return this.domNode===t?e:-1},e.prototype.insertAt=function(e,n,r){null==r?(this.text=this.text.slice(0,e)+n+this.text.slice(e),this.domNode.data=this.text):t.prototype.insertAt.call(this,e,n,r)},e.prototype.length=function(){return this.text.length},e.prototype.optimize=function(n){t.prototype.optimize.call(this,n),this.text=this.statics.value(this.domNode),0===this.text.length?this.remove():this.next instanceof e&&this.next.prev===this&&(this.insertAt(this.length(),this.next.value()),this.next.remove())},e.prototype.position=function(t,e){return void 0===e&&(e=!1),[this.domNode,t]},e.prototype.split=function(t,e){if(void 0===e&&(e=!1),!e){if(0===t)return this;if(t===this.length())return this.next}var n=i.create(this.domNode.splitText(t));return this.parent.insertBefore(n,this.next),this.text=this.statics.value(this.domNode),n},e.prototype.update=function(t,e){var n=this;t.some(function(t){return"characterData"===t.type&&t.target===n.domNode})&&(this.text=this.statics.value(this.domNode))},e.prototype.value=function(){return this.text},e.blotName="text",e.scope=i.Scope.INLINE_BLOT,e}(o.default);e.default=l},function(t,e,n){"use strict";var r=document.createElement("div");if(r.classList.toggle("test-class",!1),r.classList.contains("test-class")){var o=DOMTokenList.prototype.toggle;DOMTokenList.prototype.toggle=function(t,e){return arguments.length>1&&!this.contains(t)==!e?e:o.call(this,t)}}String.prototype.startsWith||(String.prototype.startsWith=function(t,e){return e=e||0,this.substr(e,t.length)===t}),String.prototype.endsWith||(String.prototype.endsWith=function(t,e){var n=this.toString();("number"!=typeof e||!isFinite(e)||Math.floor(e)!==e||e>n.length)&&(e=n.length),e-=t.length;var r=n.indexOf(t,e);return-1!==r&&r===e}),Array.prototype.find||Object.defineProperty(Array.prototype,"find",{value:function(t){if(null===this)throw new TypeError("Array.prototype.find called on null or undefined");if("function"!=typeof t)throw new TypeError("predicate must be a function");for(var e,n=Object(this),r=n.length>>>0,o=arguments[1],i=0;i<r;i++)if(e=n[i],t.call(o,e,i,n))return e}}),document.addEventListener("DOMContentLoaded",function(){document.execCommand("enableObjectResizing",!1,!1),document.execCommand("autoUrlDetect",!1,!1)})},function(t,e){function n(t,e,n){if(t==e)return t?[[v,t]]:[];(n<0||t.length<n)&&(n=null);var o=l(t,e),i=t.substring(0,o);t=t.substring(o),e=e.substring(o),o=a(t,e);var s=t.substring(t.length-o);t=t.substring(0,t.length-o),e=e.substring(0,e.length-o);var c=r(t,e);return i&&c.unshift([v,i]),s&&c.push([v,s]),u(c),null!=n&&(c=f(c,n)),c=h(c)}function r(t,e){var r;if(!t)return[[y,e]];if(!e)return[[d,t]];var i=t.length>e.length?t:e,l=t.length>e.length?e:t,a=i.indexOf(l);if(-1!=a)return r=[[y,i.substring(0,a)],[v,l],[y,i.substring(a+l.length)]],t.length>e.length&&(r[0][0]=r[2][0]=d),r;if(1==l.length)return[[d,t],[y,e]];var u=s(t,e);if(u){var c=u[0],f=u[1],h=u[2],p=u[3],b=u[4],g=n(c,h),m=n(f,p);return g.concat([[v,b]],m)}return o(t,e)}function o(t,e){for(var n=t.length,r=e.length,o=Math.ceil((n+r)/2),l=o,a=2*o,s=new Array(a),u=new Array(a),c=0;c<a;c++)s[c]=-1,u[c]=-1;s[l+1]=0,u[l+1]=0;for(var f=n-r,h=f%2!=0,p=0,v=0,b=0,g=0,m=0;m<o;m++){for(var _=-m+p;_<=m-v;_+=2){var O,w=l+_;O=_==-m||_!=m&&s[w-1]<s[w+1]?s[w+1]:s[w-1]+1;for(var x=O-_;O<n&&x<r&&t.charAt(O)==e.charAt(x);)O++,x++;if(s[w]=O,O>n)v+=2;else if(x>r)p+=2;else if(h){var k=l+f-_;if(k>=0&&k<a&&-1!=u[k]){var E=n-u[k];if(O>=E)return i(t,e,O,x)}}}for(var N=-m+b;N<=m-g;N+=2){var E,k=l+N;E=N==-m||N!=m&&u[k-1]<u[k+1]?u[k+1]:u[k-1]+1;for(var j=E-N;E<n&&j<r&&t.charAt(n-E-1)==e.charAt(r-j-1);)E++,j++;if(u[k]=E,E>n)g+=2;else if(j>r)b+=2;else if(!h){var w=l+f-N;if(w>=0&&w<a&&-1!=s[w]){var O=s[w],x=l+O-w;if(E=n-E,O>=E)return i(t,e,O,x)}}}}return[[d,t],[y,e]]}function i(t,e,r,o){var i=t.substring(0,r),l=e.substring(0,o),a=t.substring(r),s=e.substring(o),u=n(i,l),c=n(a,s);return u.concat(c)}function l(t,e){if(!t||!e||t.charAt(0)!=e.charAt(0))return 0;for(var n=0,r=Math.min(t.length,e.length),o=r,i=0;n<o;)t.substring(i,o)==e.substring(i,o)?(n=o,i=n):r=o,o=Math.floor((r-n)/2+n);return o}function a(t,e){if(!t||!e||t.charAt(t.length-1)!=e.charAt(e.length-1))return 0;for(var n=0,r=Math.min(t.length,e.length),o=r,i=0;n<o;)t.substring(t.length-o,t.length-i)==e.substring(e.length-o,e.length-i)?(n=o,i=n):r=o,o=Math.floor((r-n)/2+n);return o}function s(t,e){function n(t,e,n){for(var r,o,i,s,u=t.substring(n,n+Math.floor(t.length/4)),c=-1,f="";-1!=(c=e.indexOf(u,c+1));){var h=l(t.substring(n),e.substring(c)),p=a(t.substring(0,n),e.substring(0,c));f.length<p+h&&(f=e.substring(c-p,c)+e.substring(c,c+h),r=t.substring(0,n-p),o=t.substring(n+h),i=e.substring(0,c-p),s=e.substring(c+h))}return 2*f.length>=t.length?[r,o,i,s,f]:null}var r=t.length>e.length?t:e,o=t.length>e.length?e:t;if(r.length<4||2*o.length<r.length)return null;var i,s=n(r,o,Math.ceil(r.length/4)),u=n(r,o,Math.ceil(r.length/2));if(!s&&!u)return null;i=u?s&&s[4].length>u[4].length?s:u:s;var c,f,h,p;return t.length>e.length?(c=i[0],f=i[1],h=i[2],p=i[3]):(h=i[0],p=i[1],c=i[2],f=i[3]),[c,f,h,p,i[4]]}function u(t){t.push([v,""]);for(var e,n=0,r=0,o=0,i="",s="";n<t.length;)switch(t[n][0]){case y:o++,s+=t[n][1],n++;break;case d:r++,i+=t[n][1],n++;break;case v:r+o>1?(0!==r&&0!==o&&(e=l(s,i),0!==e&&(n-r-o>0&&t[n-r-o-1][0]==v?t[n-r-o-1][1]+=s.substring(0,e):(t.splice(0,0,[v,s.substring(0,e)]),n++),s=s.substring(e),i=i.substring(e)),0!==(e=a(s,i))&&(t[n][1]=s.substring(s.length-e)+t[n][1],s=s.substring(0,s.length-e),i=i.substring(0,i.length-e))),0===r?t.splice(n-o,r+o,[y,s]):0===o?t.splice(n-r,r+o,[d,i]):t.splice(n-r-o,r+o,[d,i],[y,s]),n=n-r-o+(r?1:0)+(o?1:0)+1):0!==n&&t[n-1][0]==v?(t[n-1][1]+=t[n][1],t.splice(n,1)):n++,o=0,r=0,i="",s=""}""===t[t.length-1][1]&&t.pop();var c=!1;for(n=1;n<t.length-1;)t[n-1][0]==v&&t[n+1][0]==v&&(t[n][1].substring(t[n][1].length-t[n-1][1].length)==t[n-1][1]?(t[n][1]=t[n-1][1]+t[n][1].substring(0,t[n][1].length-t[n-1][1].length),t[n+1][1]=t[n-1][1]+t[n+1][1],t.splice(n-1,1),c=!0):t[n][1].substring(0,t[n+1][1].length)==t[n+1][1]&&(t[n-1][1]+=t[n+1][1],t[n][1]=t[n][1].substring(t[n+1][1].length)+t[n+1][1],t.splice(n+1,1),c=!0)),n++;c&&u(t)}function c(t,e){if(0===e)return[v,t];for(var n=0,r=0;r<t.length;r++){var o=t[r];if(o[0]===d||o[0]===v){var i=n+o[1].length;if(e===i)return[r+1,t];if(e<i){t=t.slice();var l=e-n,a=[o[0],o[1].slice(0,l)],s=[o[0],o[1].slice(l)];return t.splice(r,1,a,s),[r+1,t]}n=i}}throw new Error("cursor_pos is out of bounds!")}function f(t,e){var n=c(t,e),r=n[1],o=n[0],i=r[o],l=r[o+1];if(null==i)return t;if(i[0]!==v)return t;if(null!=l&&i[1]+l[1]===l[1]+i[1])return r.splice(o,2,l,i),p(r,o,2);if(null!=l&&0===l[1].indexOf(i[1])){r.splice(o,2,[l[0],i[1]],[0,i[1]]);var a=l[1].slice(i[1].length);return a.length>0&&r.splice(o+2,0,[l[0],a]),p(r,o,3)}return t}function h(t){for(var e=!1,n=function(t){return t.charCodeAt(0)>=56320&&t.charCodeAt(0)<=57343},r=2;r<t.length;r+=1)t[r-2][0]===v&&function(t){return t.charCodeAt(t.length-1)>=55296&&t.charCodeAt(t.length-1)<=56319}(t[r-2][1])&&t[r-1][0]===d&&n(t[r-1][1])&&t[r][0]===y&&n(t[r][1])&&(e=!0,t[r-1][1]=t[r-2][1].slice(-1)+t[r-1][1],t[r][1]=t[r-2][1].slice(-1)+t[r][1],t[r-2][1]=t[r-2][1].slice(0,-1));if(!e)return t;for(var o=[],r=0;r<t.length;r+=1)t[r][1].length>0&&o.push(t[r]);return o}function p(t,e,n){for(var r=e+n-1;r>=0&&r>=e-1;r--)if(r+1<t.length){var o=t[r],i=t[r+1];o[0]===i[1]&&t.splice(r,2,[o[0],o[1]+i[1]])}return t}var d=-1,y=1,v=0,b=n;b.INSERT=y,b.DELETE=d,b.EQUAL=v,t.exports=b},function(t,e){function n(t){var e=[];for(var n in t)e.push(n);return e}e=t.exports="function"==typeof Object.keys?Object.keys:n,e.shim=n},function(t,e){function n(t){return"[object Arguments]"==Object.prototype.toString.call(t)}function r(t){return t&&"object"==typeof t&&"number"==typeof t.length&&Object.prototype.hasOwnProperty.call(t,"callee")&&!Object.prototype.propertyIsEnumerable.call(t,"callee")||!1}var o="[object Arguments]"==function(){return Object.prototype.toString.call(arguments)}();e=t.exports=o?n:r,e.supported=n,e.unsupported=r},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function l(t,e){return Object.keys(e).reduce(function(n,r){return null==t[r]?n:(e[r]===t[r]?n[r]=e[r]:Array.isArray(e[r])?e[r].indexOf(t[r])<0&&(n[r]=e[r].concat([t[r]])):n[r]=[e[r],t[r]],n)},{})}function a(t){return t.reduce(function(t,e){if(1===e.insert){var n=(0,N.default)(e.attributes);return delete n.image,t.insert({image:e.attributes.image},n)}if(null==e.attributes||!0!==e.attributes.list&&!0!==e.attributes.bullet||(e=(0,N.default)(e),e.attributes.list?e.attributes.list="ordered":(e.attributes.list="bullet",delete e.attributes.bullet)),"string"==typeof e.insert){var r=e.insert.replace(/\r\n/g,"\n").replace(/\r/g,"\n");return t.insert(r,e.attributes)}return t.push(e)},new h.default)}Object.defineProperty(e,"__esModule",{value:!0});var 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},u=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),c=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),f=n(4),h=r(f),p=n(20),d=r(p),y=n(0),v=r(y),b=n(13),g=r(b),m=n(31),_=r(m),O=n(3),w=r(O),x=n(14),k=r(x),E=n(21),N=r(E),j=n(12),A=r(j),q=n(2),T=r(q),P=/^[ -~]*$/,S=function(){function t(e){i(this,t),this.scroll=e,this.delta=this.getDelta()}return c(t,[{key:"applyDelta",value:function(t){var e=this,n=!1;this.scroll.update();var r=this.scroll.length();return this.scroll.batchStart(),t=a(t),t.reduce(function(t,o){var i=o.retain||o.delete||o.insert.length||1,l=o.attributes||{};if(null!=o.insert){if("string"==typeof o.insert){var a=o.insert;a.endsWith("\n")&&n&&(n=!1,a=a.slice(0,-1)),t>=r&&!a.endsWith("\n")&&(n=!0),e.scroll.insertAt(t,a);var c=e.scroll.line(t),f=u(c,2),h=f[0],p=f[1],y=(0,T.default)({},(0,O.bubbleFormats)(h));if(h instanceof w.default){var b=h.descendant(v.default.Leaf,p),g=u(b,1),m=g[0];y=(0,T.default)(y,(0,O.bubbleFormats)(m))}l=d.default.attributes.diff(y,l)||{}}else if("object"===s(o.insert)){var _=Object.keys(o.insert)[0];if(null==_)return t;e.scroll.insertAt(t,_,o.insert[_])}r+=i}return Object.keys(l).forEach(function(n){e.scroll.formatAt(t,i,n,l[n])}),t+i},0),t.reduce(function(t,n){return"number"==typeof n.delete?(e.scroll.deleteAt(t,n.delete),t):t+(n.retain||n.insert.length||1)},0),this.scroll.batchEnd(),this.update(t)}},{key:"deleteText",value:function(t,e){return this.scroll.deleteAt(t,e),this.update((new h.default).retain(t).delete(e))}},{key:"formatLine",value:function(t,e){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.scroll.update(),Object.keys(r).forEach(function(o){if(null==n.scroll.whitelist||n.scroll.whitelist[o]){var i=n.scroll.lines(t,Math.max(e,1)),l=e;i.forEach(function(e){var i=e.length();if(e instanceof g.default){var a=t-e.offset(n.scroll),s=e.newlineIndex(a+l)-a+1;e.formatAt(a,s,o,r[o])}else e.format(o,r[o]);l-=i})}}),this.scroll.optimize(),this.update((new h.default).retain(t).retain(e,(0,N.default)(r)))}},{key:"formatText",value:function(t,e){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return Object.keys(r).forEach(function(o){n.scroll.formatAt(t,e,o,r[o])}),this.update((new h.default).retain(t).retain(e,(0,N.default)(r)))}},{key:"getContents",value:function(t,e){return this.delta.slice(t,t+e)}},{key:"getDelta",value:function(){return this.scroll.lines().reduce(function(t,e){return t.concat(e.delta())},new h.default)}},{key:"getFormat",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=[],r=[];0===e?this.scroll.path(t).forEach(function(t){var e=u(t,1),o=e[0];o instanceof w.default?n.push(o):o instanceof v.default.Leaf&&r.push(o)}):(n=this.scroll.lines(t,e),r=this.scroll.descendants(v.default.Leaf,t,e));var o=[n,r].map(function(t){if(0===t.length)return{};for(var e=(0,O.bubbleFormats)(t.shift());Object.keys(e).length>0;){var n=t.shift();if(null==n)return e;e=l((0,O.bubbleFormats)(n),e)}return e});return T.default.apply(T.default,o)}},{key:"getText",value:function(t,e){return this.getContents(t,e).filter(function(t){return"string"==typeof t.insert}).map(function(t){return t.insert}).join("")}},{key:"insertEmbed",value:function(t,e,n){return this.scroll.insertAt(t,e,n),this.update((new h.default).retain(t).insert(o({},e,n)))}},{key:"insertText",value:function(t,e){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return e=e.replace(/\r\n/g,"\n").replace(/\r/g,"\n"),this.scroll.insertAt(t,e),Object.keys(r).forEach(function(o){n.scroll.formatAt(t,e.length,o,r[o])}),this.update((new h.default).retain(t).insert(e,(0,N.default)(r)))}},{key:"isBlank",value:function(){if(0==this.scroll.children.length)return!0;if(this.scroll.children.length>1)return!1;var t=this.scroll.children.head;return t.statics.blotName===w.default.blotName&&(!(t.children.length>1)&&t.children.head instanceof k.default)}},{key:"removeFormat",value:function(t,e){var n=this.getText(t,e),r=this.scroll.line(t+e),o=u(r,2),i=o[0],l=o[1],a=0,s=new h.default;null!=i&&(a=i instanceof g.default?i.newlineIndex(l)-l+1:i.length()-l,s=i.delta().slice(l,l+a-1).insert("\n"));var c=this.getContents(t,e+a),f=c.diff((new h.default).insert(n).concat(s)),p=(new h.default).retain(t).concat(f);return this.applyDelta(p)}},{key:"update",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,r=this.delta;if(1===e.length&&"characterData"===e[0].type&&e[0].target.data.match(P)&&v.default.find(e[0].target)){var o=v.default.find(e[0].target),i=(0,O.bubbleFormats)(o),l=o.offset(this.scroll),a=e[0].oldValue.replace(_.default.CONTENTS,""),s=(new h.default).insert(a),u=(new h.default).insert(o.value());t=(new h.default).retain(l).concat(s.diff(u,n)).reduce(function(t,e){return e.insert?t.insert(e.insert,i):t.push(e)},new h.default),this.delta=r.compose(t)}else this.delta=this.getDelta(),t&&(0,A.default)(r.compose(t),this.delta)||(t=r.diff(this.delta,n));return t}}]),t}();e.default=S},function(t,e){"use strict";function n(){}function r(t,e,n){this.fn=t,this.context=e,this.once=n||!1}function o(){this._events=new n,this._eventsCount=0}var i=Object.prototype.hasOwnProperty,l="~";Object.create&&(n.prototype=Object.create(null),(new n).__proto__||(l=!1)),o.prototype.eventNames=function(){var t,e,n=[];if(0===this._eventsCount)return n;for(e in t=this._events)i.call(t,e)&&n.push(l?e.slice(1):e);return Object.getOwnPropertySymbols?n.concat(Object.getOwnPropertySymbols(t)):n},o.prototype.listeners=function(t,e){var n=l?l+t:t,r=this._events[n];if(e)return!!r;if(!r)return[];if(r.fn)return[r.fn];for(var o=0,i=r.length,a=new Array(i);o<i;o++)a[o]=r[o].fn;return a},o.prototype.emit=function(t,e,n,r,o,i){var a=l?l+t:t;if(!this._events[a])return!1;var s,u,c=this._events[a],f=arguments.length;if(c.fn){switch(c.once&&this.removeListener(t,c.fn,void 0,!0),f){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,e),!0;case 3:return c.fn.call(c.context,e,n),!0;case 4:return c.fn.call(c.context,e,n,r),!0;case 5:return c.fn.call(c.context,e,n,r,o),!0;case 6:return c.fn.call(c.context,e,n,r,o,i),!0}for(u=1,s=new Array(f-1);u<f;u++)s[u-1]=arguments[u];c.fn.apply(c.context,s)}else{var h,p=c.length;for(u=0;u<p;u++)switch(c[u].once&&this.removeListener(t,c[u].fn,void 0,!0),f){case 1:c[u].fn.call(c[u].context);break;case 2:c[u].fn.call(c[u].context,e);break;case 3:c[u].fn.call(c[u].context,e,n);break;case 4:c[u].fn.call(c[u].context,e,n,r);break;default:if(!s)for(h=1,s=new Array(f-1);h<f;h++)s[h-1]=arguments[h];c[u].fn.apply(c[u].context,s)}}return!0},o.prototype.on=function(t,e,n){var o=new r(e,n||this),i=l?l+t:t;return this._events[i]?this._events[i].fn?this._events[i]=[this._events[i],o]:this._events[i].push(o):(this._events[i]=o,this._eventsCount++),this},o.prototype.once=function(t,e,n){var o=new r(e,n||this,!0),i=l?l+t:t;return this._events[i]?this._events[i].fn?this._events[i]=[this._events[i],o]:this._events[i].push(o):(this._events[i]=o,this._eventsCount++),this},o.prototype.removeListener=function(t,e,r,o){var i=l?l+t:t;if(!this._events[i])return this;if(!e)return 0==--this._eventsCount?this._events=new n:delete this._events[i],this;var a=this._events[i];if(a.fn)a.fn!==e||o&&!a.once||r&&a.context!==r||(0==--this._eventsCount?this._events=new n:delete this._events[i]);else{for(var s=0,u=[],c=a.length;s<c;s++)(a[s].fn!==e||o&&!a[s].once||r&&a[s].context!==r)&&u.push(a[s]);u.length?this._events[i]=1===u.length?u[0]:u:0==--this._eventsCount?this._events=new n:delete this._events[i]}return this},o.prototype.removeAllListeners=function(t){var e;return t?(e=l?l+t:t,this._events[e]&&(0==--this._eventsCount?this._events=new n:delete this._events[e])):(this._events=new n,this._eventsCount=0),this},o.prototype.off=o.prototype.removeListener,o.prototype.addListener=o.prototype.on,o.prototype.setMaxListeners=function(){return this},o.prefixed=l,o.EventEmitter=o,void 0!==t&&(t.exports=o)},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function a(t){return t instanceof v.default||t instanceof y.BlockEmbed}Object.defineProperty(e,"__esModule",{value:!0});var s=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),u=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),c=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},f=n(0),h=r(f),p=n(9),d=r(p),y=n(3),v=r(y),b=n(14),g=r(b),m=n(13),_=r(m),O=n(23),w=r(O),x=function(t){function e(t,n){o(this,e);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return r.emitter=n.emitter,Array.isArray(n.whitelist)&&(r.whitelist=n.whitelist.reduce(function(t,e){return t[e]=!0,t},{})),r.optimize(),r.enable(),r}return l(e,t),u(e,[{key:"batchStart",value:function(){this.batch=!0}},{key:"batchEnd",value:function(){this.batch=!1,this.optimize()}},{key:"deleteAt",value:function(t,n){var r=this.line(t),o=s(r,2),i=o[0],l=o[1],a=this.line(t+n),u=s(a,1),f=u[0];if(c(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"deleteAt",this).call(this,t,n),null!=f&&i!==f&&l>0){if(i instanceof y.BlockEmbed||f instanceof y.BlockEmbed)return void this.optimize();if(i instanceof _.default){var h=i.newlineIndex(i.length(),!0);if(h>-1&&(i=i.split(h+1))===f)return void this.optimize()}else if(f instanceof _.default){var p=f.newlineIndex(0);p>-1&&f.split(p+1)}var d=f.children.head instanceof g.default?null:f.children.head;i.moveChildren(f,d),i.remove()}this.optimize()}},{key:"enable",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this.domNode.setAttribute("contenteditable",t)}},{key:"formatAt",value:function(t,n,r,o){(null==this.whitelist||this.whitelist[r])&&(c(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"formatAt",this).call(this,t,n,r,o),this.optimize())}},{key:"insertAt",value:function(t,n,r){if(null==r||null==this.whitelist||this.whitelist[n]){if(t>=this.length())if(null==r||null==h.default.query(n,h.default.Scope.BLOCK)){var o=h.default.create(this.statics.defaultChild);this.appendChild(o),null==r&&n.endsWith("\n")&&(n=n.slice(0,-1)),o.insertAt(0,n,r)}else{var i=h.default.create(n,r);this.appendChild(i)}else c(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"insertAt",this).call(this,t,n,r);this.optimize()}}},{key:"insertBefore",value:function(t,n){if(t.statics.scope===h.default.Scope.INLINE_BLOT){var r=h.default.create(this.statics.defaultChild);r.appendChild(t),t=r}c(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"insertBefore",this).call(this,t,n)}},{key:"leaf",value:function(t){return this.path(t).pop()||[null,-1]}},{key:"line",value:function(t){return t===this.length()?this.line(t-1):this.descendant(a,t)}},{key:"lines",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.MAX_VALUE;return function t(e,n,r){var o=[],i=r;return e.children.forEachAt(n,r,function(e,n,r){a(e)?o.push(e):e instanceof h.default.Container&&(o=o.concat(t(e,n,i))),i-=r}),o}(this,t,e)}},{key:"optimize",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};!0!==this.batch&&(c(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"optimize",this).call(this,t,n),t.length>0&&this.emitter.emit(d.default.events.SCROLL_OPTIMIZE,t,n))}},{key:"path",value:function(t){return c(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"path",this).call(this,t).slice(1)}},{key:"update",value:function(t){if(!0!==this.batch){var n=d.default.sources.USER;"string"==typeof t&&(n=t),Array.isArray(t)||(t=this.observer.takeRecords()),t.length>0&&this.emitter.emit(d.default.events.SCROLL_BEFORE_UPDATE,n,t),c(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"update",this).call(this,t.concat([])),t.length>0&&this.emitter.emit(d.default.events.SCROLL_UPDATE,n,t)}}}]),e}(h.default.Scroll);x.blotName="scroll",x.className="ql-editor",x.tagName="DIV",x.defaultChild="block",x.allowedChildren=[v.default,y.BlockEmbed,w.default],e.default=x},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function l(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function s(t,e,n){return"object"===(void 0===e?"undefined":x(e))?Object.keys(e).reduce(function(t,n){return s(t,n,e[n])},t):t.reduce(function(t,r){return r.attributes&&r.attributes[e]?t.push(r):t.insert(r.insert,(0,j.default)({},o({},e,n),r.attributes))},new q.default)}function u(t){if(t.nodeType!==Node.ELEMENT_NODE)return{};return t["__ql-computed-style"]||(t["__ql-computed-style"]=window.getComputedStyle(t))}function c(t,e){for(var n="",r=t.ops.length-1;r>=0&&n.length<e.length;--r){var o=t.ops[r];if("string"!=typeof o.insert)break;n=o.insert+n}return n.slice(-1*e.length)===e}function f(t){return 0!==t.childNodes.length&&["block","list-item"].indexOf(u(t).display)>-1}function h(t,e,n){return t.nodeType===t.TEXT_NODE?n.reduce(function(e,n){return n(t,e)},new q.default):t.nodeType===t.ELEMENT_NODE?[].reduce.call(t.childNodes||[],function(r,o){var i=h(o,e,n);return o.nodeType===t.ELEMENT_NODE&&(i=e.reduce(function(t,e){return e(o,t)},i),i=(o[W]||[]).reduce(function(t,e){return e(o,t)},i)),r.concat(i)},new q.default):new q.default}function p(t,e,n){return s(n,t,!0)}function d(t,e){var n=P.default.Attributor.Attribute.keys(t),r=P.default.Attributor.Class.keys(t),o=P.default.Attributor.Style.keys(t),i={};return n.concat(r).concat(o).forEach(function(e){var n=P.default.query(e,P.default.Scope.ATTRIBUTE);null!=n&&(i[n.attrName]=n.value(t),i[n.attrName])||(n=Y[e],null==n||n.attrName!==e&&n.keyName!==e||(i[n.attrName]=n.value(t)||void 0),null==(n=X[e])||n.attrName!==e&&n.keyName!==e||(n=X[e],i[n.attrName]=n.value(t)||void 0))}),Object.keys(i).length>0&&(e=s(e,i)),e}function y(t,e){var n=P.default.query(t);if(null==n)return e;if(n.prototype instanceof P.default.Embed){var r={},o=n.value(t);null!=o&&(r[n.blotName]=o,e=(new q.default).insert(r,n.formats(t)))}else"function"==typeof n.formats&&(e=s(e,n.blotName,n.formats(t)));return e}function v(t,e){return c(e,"\n")||e.insert("\n"),e}function b(){return new q.default}function g(t,e){var n=P.default.query(t);if(null==n||"list-item"!==n.blotName||!c(e,"\n"))return e;for(var r=-1,o=t.parentNode;!o.classList.contains("ql-clipboard");)"list"===(P.default.query(o)||{}).blotName&&(r+=1),o=o.parentNode;return r<=0?e:e.compose((new q.default).retain(e.length()-1).retain(1,{indent:r}))}function m(t,e){return c(e,"\n")||(f(t)||e.length()>0&&t.nextSibling&&f(t.nextSibling))&&e.insert("\n"),e}function _(t,e){if(f(t)&&null!=t.nextElementSibling&&!c(e,"\n\n")){var n=t.offsetHeight+parseFloat(u(t).marginTop)+parseFloat(u(t).marginBottom);t.nextElementSibling.offsetTop>t.offsetTop+1.5*n&&e.insert("\n")}return e}function O(t,e){var n={},r=t.style||{};return r.fontStyle&&"italic"===u(t).fontStyle&&(n.italic=!0),r.fontWeight&&(u(t).fontWeight.startsWith("bold")||parseInt(u(t).fontWeight)>=700)&&(n.bold=!0),Object.keys(n).length>0&&(e=s(e,n)),parseFloat(r.textIndent||0)>0&&(e=(new q.default).insert("\t").concat(e)),e}function w(t,e){var n=t.data;if("O:P"===t.parentNode.tagName)return e.insert(n.trim());if(0===n.trim().length&&t.parentNode.classList.contains("ql-clipboard"))return e;if(!u(t.parentNode).whiteSpace.startsWith("pre")){var r=function(t,e){return e=e.replace(/[^\u00a0]/g,""),e.length<1&&t?" ":e};n=n.replace(/\r\n/g," ").replace(/\n/g," "),n=n.replace(/\s\s+/g,r.bind(r,!0)),(null==t.previousSibling&&f(t.parentNode)||null!=t.previousSibling&&f(t.previousSibling))&&(n=n.replace(/^\s+/,r.bind(r,!1))),(null==t.nextSibling&&f(t.parentNode)||null!=t.nextSibling&&f(t.nextSibling))&&(n=n.replace(/\s+$/,r.bind(r,!1)))}return e.insert(n)}Object.defineProperty(e,"__esModule",{value:!0}),e.matchText=e.matchSpacing=e.matchNewline=e.matchBlot=e.matchAttributor=e.default=void 0;var x="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},k=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),E=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),N=n(2),j=r(N),A=n(4),q=r(A),T=n(0),P=r(T),S=n(6),C=r(S),L=n(10),M=r(L),R=n(7),I=r(R),B=n(34),D=n(35),U=n(13),F=r(U),H=n(24),K=n(36),z=n(37),Z=n(38),V=(0,M.default)("quill:clipboard"),W="__ql-matcher",G=[[Node.TEXT_NODE,w],[Node.TEXT_NODE,m],["br",v],[Node.ELEMENT_NODE,m],[Node.ELEMENT_NODE,y],[Node.ELEMENT_NODE,_],[Node.ELEMENT_NODE,d],[Node.ELEMENT_NODE,O],["li",g],["b",p.bind(p,"bold")],["i",p.bind(p,"italic")],["style",b]],Y=[B.AlignAttribute,K.DirectionAttribute].reduce(function(t,e){return t[e.keyName]=e,t},{}),X=[B.AlignStyle,D.BackgroundStyle,H.ColorStyle,K.DirectionStyle,z.FontStyle,Z.SizeStyle].reduce(function(t,e){return t[e.keyName]=e,t},{}),$=function(t){function e(t,n){i(this,e);var r=l(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.quill.root.addEventListener("paste",r.onPaste.bind(r)),r.container=r.quill.addContainer("ql-clipboard"),r.container.setAttribute("contenteditable",!0),r.container.setAttribute("tabindex",-1),r.matchers=[],G.concat(r.options.matchers).forEach(function(t){var e=k(t,2),o=e[0],i=e[1];(n.matchVisual||i!==_)&&r.addMatcher(o,i)}),r}return a(e,t),E(e,[{key:"addMatcher",value:function(t,e){this.matchers.push([t,e])}},{key:"convert",value:function(t){if("string"==typeof t)return this.container.innerHTML=t.replace(/\>\r?\n +\</g,"><"),this.convert();var e=this.quill.getFormat(this.quill.selection.savedRange.index);if(e[F.default.blotName]){var n=this.container.innerText;return this.container.innerHTML="",(new q.default).insert(n,o({},F.default.blotName,e[F.default.blotName]))}var r=this.prepareMatching(),i=k(r,2),l=i[0],a=i[1],s=h(this.container,l,a);return c(s,"\n")&&null==s.ops[s.ops.length-1].attributes&&(s=s.compose((new q.default).retain(s.length()-1).delete(1))),V.log("convert",this.container.innerHTML,s),this.container.innerHTML="",s}},{key:"dangerouslyPasteHTML",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:C.default.sources.API;if("string"==typeof t)this.quill.setContents(this.convert(t),e),this.quill.setSelection(0,C.default.sources.SILENT);else{var r=this.convert(e);this.quill.updateContents((new q.default).retain(t).concat(r),n),this.quill.setSelection(t+r.length(),C.default.sources.SILENT)}}},{key:"onPaste",value:function(t){var e=this;if(!t.defaultPrevented&&this.quill.isEnabled()){var n=this.quill.getSelection(),r=(new q.default).retain(n.index),o=this.quill.scrollingContainer.scrollTop;this.container.focus(),this.quill.selection.update(C.default.sources.SILENT),setTimeout(function(){r=r.concat(e.convert()).delete(n.length),e.quill.updateContents(r,C.default.sources.USER),e.quill.setSelection(r.length()-n.length,C.default.sources.SILENT),e.quill.scrollingContainer.scrollTop=o,e.quill.focus()},1)}}},{key:"prepareMatching",value:function(){var t=this,e=[],n=[];return this.matchers.forEach(function(r){var o=k(r,2),i=o[0],l=o[1];switch(i){case Node.TEXT_NODE:n.push(l);break;case Node.ELEMENT_NODE:e.push(l);break;default:[].forEach.call(t.container.querySelectorAll(i),function(t){t[W]=t[W]||[],t[W].push(l)})}}),[e,n]}}]),e}(I.default);$.DEFAULTS={matchers:[],matchVisual:!0},e.default=$,e.matchAttributor=d,e.matchBlot=y,e.matchNewline=m,e.matchSpacing=_,e.matchText=w},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function a(t){var e=t.ops[t.ops.length-1];return null!=e&&(null!=e.insert?"string"==typeof e.insert&&e.insert.endsWith("\n"):null!=e.attributes&&Object.keys(e.attributes).some(function(t){return null!=f.default.query(t,f.default.Scope.BLOCK)}))}function s(t){var e=t.reduce(function(t,e){return t+=e.delete||0},0),n=t.length()-e;return a(t)&&(n-=1),n}Object.defineProperty(e,"__esModule",{value:!0}),e.getLastChangeIndex=e.default=void 0;var u=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),c=n(0),f=r(c),h=n(6),p=r(h),d=n(7),y=r(d),v=function(t){function e(t,n){o(this,e);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.lastRecorded=0,r.ignoreChange=!1,r.clear(),r.quill.on(p.default.events.EDITOR_CHANGE,function(t,e,n,o){t!==p.default.events.TEXT_CHANGE||r.ignoreChange||(r.options.userOnly&&o!==p.default.sources.USER?r.transform(e):r.record(e,n))}),r.quill.keyboard.addBinding({key:"Z",shortKey:!0},r.undo.bind(r)),r.quill.keyboard.addBinding({key:"Z",shortKey:!0,shiftKey:!0},r.redo.bind(r)),/Win/i.test(navigator.platform)&&r.quill.keyboard.addBinding({key:"Y",shortKey:!0},r.redo.bind(r)),r}return l(e,t),u(e,[{key:"change",value:function(t,e){if(0!==this.stack[t].length){var n=this.stack[t].pop();this.stack[e].push(n),this.lastRecorded=0,this.ignoreChange=!0,this.quill.updateContents(n[t],p.default.sources.USER),this.ignoreChange=!1;var r=s(n[t]);this.quill.setSelection(r)}}},{key:"clear",value:function(){this.stack={undo:[],redo:[]}}},{key:"cutoff",value:function(){this.lastRecorded=0}},{key:"record",value:function(t,e){if(0!==t.ops.length){this.stack.redo=[];var n=this.quill.getContents().diff(e),r=Date.now();if(this.lastRecorded+this.options.delay>r&&this.stack.undo.length>0){var o=this.stack.undo.pop();n=n.compose(o.undo),t=o.redo.compose(t)}else this.lastRecorded=r;this.stack.undo.push({redo:t,undo:n}),this.stack.undo.length>this.options.maxStack&&this.stack.undo.shift()}}},{key:"redo",value:function(){this.change("redo","undo")}},{key:"transform",value:function(t){this.stack.undo.forEach(function(e){e.undo=t.transform(e.undo,!0),e.redo=t.transform(e.redo,!0)}),this.stack.redo.forEach(function(e){e.undo=t.transform(e.undo,!0),e.redo=t.transform(e.redo,!0)})}},{key:"undo",value:function(){this.change("undo","redo")}}]),e}(y.default);v.DEFAULTS={delay:1e3,maxStack:100,userOnly:!1},e.default=v,e.getLastChangeIndex=s},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0}),e.IndentClass=void 0;var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(0),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,[{key:"add",value:function(t,n){if("+1"===n||"-1"===n){var r=this.value(t)||0;n="+1"===n?r+1:r-1}return 0===n?(this.remove(t),!0):a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"add",this).call(this,t,n)}},{key:"canAdd",value:function(t,n){return a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"canAdd",this).call(this,t,n)||a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"canAdd",this).call(this,t,parseInt(n))}},{key:"value",value:function(t){return parseInt(a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"value",this).call(this,t))||void 0}}]),e}(u.default.Attributor.Class),f=new c("indent","ql-indent",{scope:u.default.Scope.BLOCK,whitelist:[1,2,3,4,5,6,7,8]});e.IndentClass=f},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=n(3),a=function(t){return t&&t.__esModule?t:{default:t}}(l),s=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),e}(a.default);s.blotName="blockquote",s.tagName="blockquote",e.default=s},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=n(3),s=function(t){return t&&t.__esModule?t:{default:t}}(a),u=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,null,[{key:"formats",value:function(t){return this.tagName.indexOf(t.tagName)+1}}]),e}(s.default);u.blotName="header",u.tagName=["H1","H2","H3","H4","H5","H6"],e.default=u},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function l(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.ListItem=void 0;var s=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),u=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},c=n(0),f=r(c),h=n(3),p=r(h),d=n(23),y=r(d),v=function(t){function e(){return i(this,e),l(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return a(e,t),s(e,[{key:"format",value:function(t,n){t!==b.blotName||n?u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"format",this).call(this,t,n):this.replaceWith(f.default.create(this.statics.scope))}},{key:"remove",value:function(){null==this.prev&&null==this.next?this.parent.remove():u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"remove",this).call(this)}},{key:"replaceWith",value:function(t,n){return this.parent.isolate(this.offset(this.parent),this.length()),t===this.parent.statics.blotName?(this.parent.replaceWith(t,n),this):(this.parent.unwrap(),u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"replaceWith",this).call(this,t,n))}}],[{key:"formats",value:function(t){return t.tagName===this.tagName?void 0:u(e.__proto__||Object.getPrototypeOf(e),"formats",this).call(this,t)}}]),e}(p.default);v.blotName="list-item",v.tagName="LI";var b=function(t){function e(t){i(this,e);var n=l(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t)),r=function(e){if(e.target.parentNode===t){var r=n.statics.formats(t),o=f.default.find(e.target);"checked"===r?o.format("list","unchecked"):"unchecked"===r&&o.format("list","checked")}};return t.addEventListener("touchstart",r),t.addEventListener("mousedown",r),n}return a(e,t),s(e,null,[{key:"create",value:function(t){var n="ordered"===t?"OL":"UL",r=u(e.__proto__||Object.getPrototypeOf(e),"create",this).call(this,n);return"checked"!==t&&"unchecked"!==t||r.setAttribute("data-checked","checked"===t),r}},{key:"formats",value:function(t){return"OL"===t.tagName?"ordered":"UL"===t.tagName?t.hasAttribute("data-checked")?"true"===t.getAttribute("data-checked")?"checked":"unchecked":"bullet":void 0}}]),s(e,[{key:"format",value:function(t,e){this.children.length>0&&this.children.tail.format(t,e)}},{key:"formats",value:function(){return o({},this.statics.blotName,this.statics.formats(this.domNode))}},{key:"insertBefore",value:function(t,n){if(t instanceof v)u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"insertBefore",this).call(this,t,n);else{var r=null==n?this.length():n.offset(this),o=this.split(r);o.parent.insertBefore(t,o)}}},{key:"optimize",value:function(t){u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"optimize",this).call(this,t);var n=this.next;null!=n&&n.prev===this&&n.statics.blotName===this.statics.blotName&&n.domNode.tagName===this.domNode.tagName&&n.domNode.getAttribute("data-checked")===this.domNode.getAttribute("data-checked")&&(n.moveChildren(this),n.remove())}},{key:"replace",value:function(t){if(t.statics.blotName!==this.statics.blotName){var n=f.default.create(this.statics.defaultChild);t.moveChildren(n),this.appendChild(n)}u(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"replace",this).call(this,t)}}]),e}(y.default);b.blotName="list",b.scope=f.default.Scope.BLOCK_BLOT,b.tagName=["OL","UL"],b.defaultChild="list-item",b.allowedChildren=[v],e.ListItem=v,e.default=b},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=n(39),a=function(t){return t&&t.__esModule?t:{default:t}}(l),s=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),e}(a.default);s.blotName="italic",s.tagName=["EM","I"],e.default=s},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(5),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,null,[{key:"create",value:function(t){return"super"===t?document.createElement("sup"):"sub"===t?document.createElement("sub"):a(e.__proto__||Object.getPrototypeOf(e),"create",this).call(this,t)}},{key:"formats",value:function(t){return"SUB"===t.tagName?"sub":"SUP"===t.tagName?"super":void 0}}]),e}(u.default);c.blotName="script",c.tagName=["SUB","SUP"],e.default=c},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=n(5),a=function(t){return t&&t.__esModule?t:{default:t}}(l),s=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),e}(a.default);s.blotName="strike",s.tagName="S",e.default=s},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=n(5),a=function(t){return t&&t.__esModule?t:{default:t}}(l),s=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),e}(a.default);s.blotName="underline",s.tagName="U",e.default=s},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(0),u=function(t){return t&&t.__esModule?t:{default:t}}(s),c=n(15),f=["alt","height","width"],h=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,[{key:"format",value:function(t,n){f.indexOf(t)>-1?n?this.domNode.setAttribute(t,n):this.domNode.removeAttribute(t):a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"format",this).call(this,t,n)}}],[{key:"create",value:function(t){var n=a(e.__proto__||Object.getPrototypeOf(e),"create",this).call(this,t);return"string"==typeof t&&n.setAttribute("src",this.sanitize(t)),n}},{key:"formats",value:function(t){return f.reduce(function(e,n){return t.hasAttribute(n)&&(e[n]=t.getAttribute(n)),e},{})}},{key:"match",value:function(t){return/\.(jpe?g|gif|png)$/.test(t)||/^data:image\/.+;base64/.test(t)}},{key:"sanitize",value:function(t){return(0,c.sanitize)(t,["http","https","data"])?t:"//:0"}},{key:"value",value:function(t){return t.getAttribute("src")}}]),e}(u.default.Embed);h.blotName="image",h.tagName="IMG",e.default=h},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function o(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var l=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=n(3),u=n(15),c=function(t){return t&&t.__esModule?t:{default:t}}(u),f=["height","width"],h=function(t){function e(){return r(this,e),o(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return i(e,t),l(e,[{key:"format",value:function(t,n){f.indexOf(t)>-1?n?this.domNode.setAttribute(t,n):this.domNode.removeAttribute(t):a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"format",this).call(this,t,n)}}],[{key:"create",value:function(t){var n=a(e.__proto__||Object.getPrototypeOf(e),"create",this).call(this,t);return n.setAttribute("frameborder","0"),n.setAttribute("allowfullscreen",!0),n.setAttribute("src",this.sanitize(t)),n}},{key:"formats",value:function(t){return f.reduce(function(e,n){return t.hasAttribute(n)&&(e[n]=t.getAttribute(n)),e},{})}},{key:"sanitize",value:function(t){return c.default.sanitize(t)}},{key:"value",value:function(t){return t.getAttribute("src")}}]),e}(s.BlockEmbed);h.blotName="video",h.className="ql-video",h.tagName="IFRAME",e.default=h},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.FormulaBlot=void 0;var a=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),s=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},u=n(33),c=r(u),f=n(6),h=r(f),p=n(7),d=r(p),y=function(t){function e(){return o(this,e),i(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return l(e,t),a(e,null,[{key:"create",value:function(t){var n=s(e.__proto__||Object.getPrototypeOf(e),"create",this).call(this,t);return"string"==typeof t&&(window.katex.render(t,n,{throwOnError:!1,errorColor:"#f00"}),n.setAttribute("data-value",t)),n}},{key:"value",value:function(t){return t.getAttribute("data-value")}}]),e}(c.default);y.blotName="formula",y.className="ql-formula",y.tagName="SPAN";var v=function(t){function e(){o(this,e);var t=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this));if(null==window.katex)throw new Error("Formula module requires KaTeX.");return t}return l(e,t),a(e,null,[{key:"register",value:function(){h.default.register(y,!0)}}]),e}(d.default);e.FormulaBlot=y,e.default=v},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.CodeToken=e.CodeBlock=void 0;var a=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),s=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},u=n(0),c=r(u),f=n(6),h=r(f),p=n(7),d=r(p),y=n(13),v=r(y),b=function(t){function e(){return o(this,e),i(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return l(e,t),a(e,[{key:"replaceWith",value:function(t){this.domNode.textContent=this.domNode.textContent,this.attach(),s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"replaceWith",this).call(this,t)}},{key:"highlight",value:function(t){var e=this.domNode.textContent;this.cachedText!==e&&((e.trim().length>0||null==this.cachedText)&&(this.domNode.innerHTML=t(e),this.domNode.normalize(),this.attach()),this.cachedText=e)}}]),e}(v.default);b.className="ql-syntax";var g=new c.default.Attributor.Class("token","hljs",{scope:c.default.Scope.INLINE}),m=function(t){function e(t,n){o(this,e);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));if("function"!=typeof r.options.highlight)throw new Error("Syntax module requires highlight.js. Please include the library on the page before Quill.");var l=null;return r.quill.on(h.default.events.SCROLL_OPTIMIZE,function(){clearTimeout(l),l=setTimeout(function(){r.highlight(),l=null},r.options.interval)}),r.highlight(),r}return l(e,t),a(e,null,[{key:"register",value:function(){h.default.register(g,!0),h.default.register(b,!0)}}]),a(e,[{key:"highlight",value:function(){var t=this;if(!this.quill.selection.composing){this.quill.update(h.default.sources.USER);var e=this.quill.getSelection();this.quill.scroll.descendants(b).forEach(function(e){e.highlight(t.options.highlight)}),this.quill.update(h.default.sources.SILENT),null!=e&&this.quill.setSelection(e,h.default.sources.SILENT)}}}]),e}(d.default);m.DEFAULTS={highlight:function(){return null==window.hljs?null:function(t){return window.hljs.highlightAuto(t).value}}(),interval:1e3},e.CodeBlock=b,e.CodeToken=g,e.default=m},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function l(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function a(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function s(t,e,n){var r=document.createElement("button");r.setAttribute("type","button"),r.classList.add("ql-"+e),null!=n&&(r.value=n),t.appendChild(r)}function u(t,e){Array.isArray(e[0])||(e=[e]),e.forEach(function(e){var n=document.createElement("span");n.classList.add("ql-formats"),e.forEach(function(t){if("string"==typeof t)s(n,t);else{var e=Object.keys(t)[0],r=t[e];Array.isArray(r)?c(n,e,r):s(n,e,r)}}),t.appendChild(n)})}function c(t,e,n){var r=document.createElement("select");r.classList.add("ql-"+e),n.forEach(function(t){var e=document.createElement("option");!1!==t?e.setAttribute("value",t):e.setAttribute("selected","selected"),r.appendChild(e)}),t.appendChild(r)}Object.defineProperty(e,"__esModule",{value:!0}),e.addControls=e.default=void 0;var f=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),h=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),p=n(4),d=r(p),y=n(0),v=r(y),b=n(6),g=r(b),m=n(10),_=r(m),O=n(7),w=r(O),x=(0,_.default)("quill:toolbar"),k=function(t){function e(t,n){i(this,e);var r=l(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));if(Array.isArray(r.options.container)){var o=document.createElement("div");u(o,r.options.container),t.container.parentNode.insertBefore(o,t.container),r.container=o}else"string"==typeof r.options.container?r.container=document.querySelector(r.options.container):r.container=r.options.container;if(!(r.container instanceof HTMLElement)){var a;return a=x.error("Container required for toolbar",r.options),l(r,a)}return r.container.classList.add("ql-toolbar"),r.controls=[],r.handlers={},Object.keys(r.options.handlers).forEach(function(t){r.addHandler(t,r.options.handlers[t])}),[].forEach.call(r.container.querySelectorAll("button, select"),function(t){r.attach(t)}),r.quill.on(g.default.events.EDITOR_CHANGE,function(t,e){t===g.default.events.SELECTION_CHANGE&&r.update(e)}),r.quill.on(g.default.events.SCROLL_OPTIMIZE,function(){var t=r.quill.selection.getRange(),e=f(t,1),n=e[0];r.update(n)}),r}return a(e,t),h(e,[{key:"addHandler",value:function(t,e){this.handlers[t]=e}},{key:"attach",value:function(t){var e=this,n=[].find.call(t.classList,function(t){return 0===t.indexOf("ql-")});if(n){if(n=n.slice("ql-".length),"BUTTON"===t.tagName&&t.setAttribute("type","button"),null==this.handlers[n]){if(null!=this.quill.scroll.whitelist&&null==this.quill.scroll.whitelist[n])return void x.warn("ignoring attaching to disabled format",n,t);if(null==v.default.query(n))return void x.warn("ignoring attaching to nonexistent format",n,t)}var r="SELECT"===t.tagName?"change":"click";t.addEventListener(r,function(r){var i=void 0;if("SELECT"===t.tagName){if(t.selectedIndex<0)return;var l=t.options[t.selectedIndex];i=!l.hasAttribute("selected")&&(l.value||!1)}else i=!t.classList.contains("ql-active")&&(t.value||!t.hasAttribute("value")),r.preventDefault();e.quill.focus();var a=e.quill.selection.getRange(),s=f(a,1),u=s[0];if(null!=e.handlers[n])e.handlers[n].call(e,i);else if(v.default.query(n).prototype instanceof v.default.Embed){if(!(i=prompt("Enter "+n)))return;e.quill.updateContents((new d.default).retain(u.index).delete(u.length).insert(o({},n,i)),g.default.sources.USER)}else e.quill.format(n,i,g.default.sources.USER);e.update(u)}),this.controls.push([n,t])}}},{key:"update",value:function(t){var e=null==t?{}:this.quill.getFormat(t);this.controls.forEach(function(n){var r=f(n,2),o=r[0],i=r[1];if("SELECT"===i.tagName){var l=void 0;if(null==t)l=null;else if(null==e[o])l=i.querySelector("option[selected]");else if(!Array.isArray(e[o])){var a=e[o];"string"==typeof a&&(a=a.replace(/\"/g,'\\"')),l=i.querySelector('option[value="'+a+'"]')}null==l?(i.value="",i.selectedIndex=-1):l.selected=!0}else if(null==t)i.classList.remove("ql-active");else if(i.hasAttribute("value")){var s=e[o]===i.getAttribute("value")||null!=e[o]&&e[o].toString()===i.getAttribute("value")||null==e[o]&&!i.getAttribute("value");i.classList.toggle("ql-active",s)}else i.classList.toggle("ql-active",null!=e[o])})}}]),e}(w.default);k.DEFAULTS={},k.DEFAULTS={container:null,handlers:{clean:function(){var t=this,e=this.quill.getSelection();if(null!=e)if(0==e.length){var n=this.quill.getFormat();Object.keys(n).forEach(function(e){null!=v.default.query(e,v.default.Scope.INLINE)&&t.quill.format(e,!1)})}else this.quill.removeFormat(e,g.default.sources.USER)},direction:function(t){var e=this.quill.getFormat().align;"rtl"===t&&null==e?this.quill.format("align","right",g.default.sources.USER):t||"right"!==e||this.quill.format("align",!1,g.default.sources.USER),this.quill.format("direction",t,g.default.sources.USER)},indent:function(t){var e=this.quill.getSelection(),n=this.quill.getFormat(e),r=parseInt(n.indent||0);if("+1"===t||"-1"===t){var o="+1"===t?1:-1;"rtl"===n.direction&&(o*=-1),this.quill.format("indent",r+o,g.default.sources.USER)}},link:function(t){!0===t&&(t=prompt("Enter link URL:")),this.quill.format("link",t,g.default.sources.USER)},list:function(t){var e=this.quill.getSelection(),n=this.quill.getFormat(e);"check"===t?"checked"===n.list||"unchecked"===n.list?this.quill.format("list",!1,g.default.sources.USER):this.quill.format("list","unchecked",g.default.sources.USER):this.quill.format("list",t,g.default.sources.USER)}}},e.default=k,e.addControls=u},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=3 x2=13 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=9 y1=4 y2=4></line> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=14 x2=4 y1=14 y2=14></line> <line class=ql-stroke x1=12 x2=6 y1=4 y2=4></line> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=15 x2=5 y1=14 y2=14></line> <line class=ql-stroke x1=15 x2=9 y1=4 y2=4></line> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=15 x2=3 y1=14 y2=14></line> <line class=ql-stroke x1=15 x2=3 y1=4 y2=4></line> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <g class="ql-fill ql-color-label"> <polygon points="6 6.868 6 6 5 6 5 7 5.942 7 6 6.868"></polygon> <rect height=1 width=1 x=4 y=4></rect> <polygon points="6.817 5 6 5 6 6 6.38 6 6.817 5"></polygon> <rect height=1 width=1 x=2 y=6></rect> <rect height=1 width=1 x=3 y=5></rect> <rect height=1 width=1 x=4 y=7></rect> <polygon points="4 11.439 4 11 3 11 3 12 3.755 12 4 11.439"></polygon> <rect height=1 width=1 x=2 y=12></rect> <rect height=1 width=1 x=2 y=9></rect> <rect height=1 width=1 x=2 y=15></rect> <polygon points="4.63 10 4 10 4 11 4.192 11 4.63 10"></polygon> <rect height=1 width=1 x=3 y=8></rect> <path d=M10.832,4.2L11,4.582V4H10.708A1.948,1.948,0,0,1,10.832,4.2Z></path> <path d=M7,4.582L7.168,4.2A1.929,1.929,0,0,1,7.292,4H7V4.582Z></path> <path d=M8,13H7.683l-0.351.8a1.933,1.933,0,0,1-.124.2H8V13Z></path> <rect height=1 width=1 x=12 y=2></rect> <rect height=1 width=1 x=11 y=3></rect> <path d=M9,3H8V3.282A1.985,1.985,0,0,1,9,3Z></path> <rect height=1 width=1 x=2 y=3></rect> <rect height=1 width=1 x=6 y=2></rect> <rect height=1 width=1 x=3 y=2></rect> <rect height=1 width=1 x=5 y=3></rect> <rect height=1 width=1 x=9 y=2></rect> <rect height=1 width=1 x=15 y=14></rect> <polygon points="13.447 10.174 13.469 10.225 13.472 10.232 13.808 11 14 11 14 10 13.37 10 13.447 10.174"></polygon> <rect height=1 width=1 x=13 y=7></rect> <rect height=1 width=1 x=15 y=5></rect> <rect height=1 width=1 x=14 y=6></rect> <rect height=1 width=1 x=15 y=8></rect> <rect height=1 width=1 x=14 y=9></rect> <path d=M3.775,14H3v1H4V14.314A1.97,1.97,0,0,1,3.775,14Z></path> <rect height=1 width=1 x=14 y=3></rect> <polygon points="12 6.868 12 6 11.62 6 12 6.868"></polygon> <rect height=1 width=1 x=15 y=2></rect> <rect height=1 width=1 x=12 y=5></rect> <rect height=1 width=1 x=13 y=4></rect> <polygon points="12.933 9 13 9 13 8 12.495 8 12.933 9"></polygon> <rect height=1 width=1 x=9 y=14></rect> <rect height=1 width=1 x=8 y=15></rect> <path d=M6,14.926V15H7V14.316A1.993,1.993,0,0,1,6,14.926Z></path> <rect height=1 width=1 x=5 y=15></rect> <path d=M10.668,13.8L10.317,13H10v1h0.792A1.947,1.947,0,0,1,10.668,13.8Z></path> <rect height=1 width=1 x=11 y=15></rect> <path d=M14.332,12.2a1.99,1.99,0,0,1,.166.8H15V12H14.245Z></path> <rect height=1 width=1 x=14 y=15></rect> <rect height=1 width=1 x=15 y=11></rect> </g> <polyline class=ql-stroke points="5.5 13 9 5 12.5 13"></polyline> <line class=ql-stroke x1=11.63 x2=6.38 y1=11 y2=11></line> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <rect class="ql-fill ql-stroke" height=3 width=3 x=4 y=5></rect> <rect class="ql-fill ql-stroke" height=3 width=3 x=11 y=5></rect> <path class="ql-even ql-fill ql-stroke" d=M7,8c0,4.031-3,5-3,5></path> <path class="ql-even ql-fill ql-stroke" d=M14,8c0,4.031-3,5-3,5></path> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-stroke d=M5,4H9.5A2.5,2.5,0,0,1,12,6.5v0A2.5,2.5,0,0,1,9.5,9H5A0,0,0,0,1,5,9V4A0,0,0,0,1,5,4Z></path> <path class=ql-stroke d=M5,9h5.5A2.5,2.5,0,0,1,13,11.5v0A2.5,2.5,0,0,1,10.5,14H5a0,0,0,0,1,0,0V9A0,0,0,0,1,5,9Z></path> </svg>'},function(t,e){t.exports='<svg class="" viewbox="0 0 18 18"> <line class=ql-stroke x1=5 x2=13 y1=3 y2=3></line> <line class=ql-stroke x1=6 x2=9.35 y1=12 y2=3></line> <line class=ql-stroke x1=11 x2=15 y1=11 y2=15></line> <line class=ql-stroke x1=15 x2=11 y1=11 y2=15></line> <rect class=ql-fill height=1 rx=0.5 ry=0.5 width=7 x=2 y=14></rect> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class="ql-color-label ql-stroke ql-transparent" x1=3 x2=15 y1=15 y2=15></line> <polyline class=ql-stroke points="5.5 11 9 3 12.5 11"></polyline> <line class=ql-stroke x1=11.63 x2=6.38 y1=9 y2=9></line> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <polygon class="ql-stroke ql-fill" points="3 11 5 9 3 7 3 11"></polygon> <line class="ql-stroke ql-fill" x1=15 x2=11 y1=4 y2=4></line> <path class=ql-fill d=M11,3a3,3,0,0,0,0,6h1V3H11Z></path> <rect class=ql-fill height=11 width=1 x=11 y=4></rect> <rect class=ql-fill height=11 width=1 x=13 y=4></rect> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <polygon class="ql-stroke ql-fill" points="15 12 13 10 15 8 15 12"></polygon> <line class="ql-stroke ql-fill" x1=9 x2=5 y1=4 y2=4></line> <path class=ql-fill d=M5,3A3,3,0,0,0,5,9H6V3H5Z></path> <rect class=ql-fill height=11 width=1 x=5 y=4></rect> <rect class=ql-fill height=11 width=1 x=7 y=4></rect> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M14,16H4a1,1,0,0,1,0-2H14A1,1,0,0,1,14,16Z /> <path class=ql-fill d=M14,4H4A1,1,0,0,1,4,2H14A1,1,0,0,1,14,4Z /> <rect class=ql-fill x=3 y=6 width=12 height=6 rx=1 ry=1 /> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M13,16H5a1,1,0,0,1,0-2h8A1,1,0,0,1,13,16Z /> <path class=ql-fill d=M13,4H5A1,1,0,0,1,5,2h8A1,1,0,0,1,13,4Z /> <rect class=ql-fill x=2 y=6 width=14 height=6 rx=1 ry=1 /> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15,8H13a1,1,0,0,1,0-2h2A1,1,0,0,1,15,8Z /> <path class=ql-fill d=M15,12H13a1,1,0,0,1,0-2h2A1,1,0,0,1,15,12Z /> <path class=ql-fill d=M15,16H5a1,1,0,0,1,0-2H15A1,1,0,0,1,15,16Z /> <path class=ql-fill d=M15,4H5A1,1,0,0,1,5,2H15A1,1,0,0,1,15,4Z /> <rect class=ql-fill x=2 y=6 width=8 height=6 rx=1 ry=1 /> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M5,8H3A1,1,0,0,1,3,6H5A1,1,0,0,1,5,8Z /> <path class=ql-fill d=M5,12H3a1,1,0,0,1,0-2H5A1,1,0,0,1,5,12Z /> <path class=ql-fill d=M13,16H3a1,1,0,0,1,0-2H13A1,1,0,0,1,13,16Z /> <path class=ql-fill d=M13,4H3A1,1,0,0,1,3,2H13A1,1,0,0,1,13,4Z /> <rect class=ql-fill x=8 y=6 width=8 height=6 rx=1 ry=1 transform="translate(24 18) rotate(-180)"/> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M11.759,2.482a2.561,2.561,0,0,0-3.53.607A7.656,7.656,0,0,0,6.8,6.2C6.109,9.188,5.275,14.677,4.15,14.927a1.545,1.545,0,0,0-1.3-.933A0.922,0.922,0,0,0,2,15.036S1.954,16,4.119,16s3.091-2.691,3.7-5.553c0.177-.826.36-1.726,0.554-2.6L8.775,6.2c0.381-1.421.807-2.521,1.306-2.676a1.014,1.014,0,0,0,1.02.56A0.966,0.966,0,0,0,11.759,2.482Z></path> <rect class=ql-fill height=1.6 rx=0.8 ry=0.8 width=5 x=5.15 y=6.2></rect> <path class=ql-fill d=M13.663,12.027a1.662,1.662,0,0,1,.266-0.276q0.193,0.069.456,0.138a2.1,2.1,0,0,0,.535.069,1.075,1.075,0,0,0,.767-0.3,1.044,1.044,0,0,0,.314-0.8,0.84,0.84,0,0,0-.238-0.619,0.8,0.8,0,0,0-.594-0.239,1.154,1.154,0,0,0-.781.3,4.607,4.607,0,0,0-.781,1q-0.091.15-.218,0.346l-0.246.38c-0.068-.288-0.137-0.582-0.212-0.885-0.459-1.847-2.494-.984-2.941-0.8-0.482.2-.353,0.647-0.094,0.529a0.869,0.869,0,0,1,1.281.585c0.217,0.751.377,1.436,0.527,2.038a5.688,5.688,0,0,1-.362.467,2.69,2.69,0,0,1-.264.271q-0.221-.08-0.471-0.147a2.029,2.029,0,0,0-.522-0.066,1.079,1.079,0,0,0-.768.3A1.058,1.058,0,0,0,9,15.131a0.82,0.82,0,0,0,.832.852,1.134,1.134,0,0,0,.787-0.3,5.11,5.11,0,0,0,.776-0.993q0.141-.219.215-0.34c0.046-.076.122-0.194,0.223-0.346a2.786,2.786,0,0,0,.918,1.726,2.582,2.582,0,0,0,2.376-.185c0.317-.181.212-0.565,0-0.494A0.807,0.807,0,0,1,14.176,15a5.159,5.159,0,0,1-.913-2.446l0,0Q13.487,12.24,13.663,12.027Z></path> </svg>'},function(t,e){t.exports='<svg viewBox="0 0 18 18"> <path class=ql-fill d=M10,4V14a1,1,0,0,1-2,0V10H3v4a1,1,0,0,1-2,0V4A1,1,0,0,1,3,4V8H8V4a1,1,0,0,1,2,0Zm6.06787,9.209H14.98975V7.59863a.54085.54085,0,0,0-.605-.60547h-.62744a1.01119,1.01119,0,0,0-.748.29688L11.645,8.56641a.5435.5435,0,0,0-.022.8584l.28613.30762a.53861.53861,0,0,0,.84717.0332l.09912-.08789a1.2137,1.2137,0,0,0,.2417-.35254h.02246s-.01123.30859-.01123.60547V13.209H12.041a.54085.54085,0,0,0-.605.60547v.43945a.54085.54085,0,0,0,.605.60547h4.02686a.54085.54085,0,0,0,.605-.60547v-.43945A.54085.54085,0,0,0,16.06787,13.209Z /> </svg>'},function(t,e){t.exports='<svg viewBox="0 0 18 18"> <path class=ql-fill d=M16.73975,13.81445v.43945a.54085.54085,0,0,1-.605.60547H11.855a.58392.58392,0,0,1-.64893-.60547V14.0127c0-2.90527,3.39941-3.42187,3.39941-4.55469a.77675.77675,0,0,0-.84717-.78125,1.17684,1.17684,0,0,0-.83594.38477c-.2749.26367-.561.374-.85791.13184l-.4292-.34082c-.30811-.24219-.38525-.51758-.1543-.81445a2.97155,2.97155,0,0,1,2.45361-1.17676,2.45393,2.45393,0,0,1,2.68408,2.40918c0,2.45312-3.1792,2.92676-3.27832,3.93848h2.79443A.54085.54085,0,0,1,16.73975,13.81445ZM9,3A.99974.99974,0,0,0,8,4V8H3V4A1,1,0,0,0,1,4V14a1,1,0,0,0,2,0V10H8v4a1,1,0,0,0,2,0V4A.99974.99974,0,0,0,9,3Z /> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=13 y1=4 y2=4></line> <line class=ql-stroke x1=5 x2=11 y1=14 y2=14></line> <line class=ql-stroke x1=8 x2=10 y1=14 y2=4></line> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <rect class=ql-stroke height=10 width=12 x=3 y=4></rect> <circle class=ql-fill cx=6 cy=7 r=1></circle> <polyline class="ql-even ql-fill" points="5 12 5 11 7 9 8 10 11 7 13 9 13 12 5 12"></polyline> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class="ql-fill ql-stroke" points="3 7 3 11 5 9 3 7"></polyline> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class=ql-stroke points="5 7 5 11 3 9 5 7"></polyline> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=11 y1=7 y2=11></line> <path class="ql-even ql-stroke" d=M8.9,4.577a3.476,3.476,0,0,1,.36,4.679A3.476,3.476,0,0,1,4.577,8.9C3.185,7.5,2.035,6.4,4.217,4.217S7.5,3.185,8.9,4.577Z></path> <path class="ql-even ql-stroke" d=M13.423,9.1a3.476,3.476,0,0,0-4.679-.36,3.476,3.476,0,0,0,.36,4.679c1.392,1.392,2.5,2.542,4.679.36S14.815,10.5,13.423,9.1Z></path> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=7 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=7 x2=15 y1=14 y2=14></line> <line class="ql-stroke ql-thin" x1=2.5 x2=4.5 y1=5.5 y2=5.5></line> <path class=ql-fill d=M3.5,6A0.5,0.5,0,0,1,3,5.5V3.085l-0.276.138A0.5,0.5,0,0,1,2.053,3c-0.124-.247-0.023-0.324.224-0.447l1-.5A0.5,0.5,0,0,1,4,2.5v3A0.5,0.5,0,0,1,3.5,6Z></path> <path class="ql-stroke ql-thin" d=M4.5,10.5h-2c0-.234,1.85-1.076,1.85-2.234A0.959,0.959,0,0,0,2.5,8.156></path> <path class="ql-stroke ql-thin" d=M2.5,14.846a0.959,0.959,0,0,0,1.85-.109A0.7,0.7,0,0,0,3.75,14a0.688,0.688,0,0,0,.6-0.736,0.959,0.959,0,0,0-1.85-.109></path> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=6 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=6 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=6 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=3 y1=4 y2=4></line> <line class=ql-stroke x1=3 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=3 x2=3 y1=14 y2=14></line> </svg>'},function(t,e){t.exports='<svg class="" viewbox="0 0 18 18"> <line class=ql-stroke x1=9 x2=15 y1=4 y2=4></line> <polyline class=ql-stroke points="3 4 4 5 6 3"></polyline> <line class=ql-stroke x1=9 x2=15 y1=14 y2=14></line> <polyline class=ql-stroke points="3 14 4 15 6 13"></polyline> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class=ql-stroke points="3 9 4 10 6 8"></polyline> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15.5,15H13.861a3.858,3.858,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.921,1.921,0,0,0,12.021,11.7a0.50013,0.50013,0,1,0,.957.291h0a0.914,0.914,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.076-1.16971,1.86982-1.93971,2.43082A1.45639,1.45639,0,0,0,12,15.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,15Z /> <path class=ql-fill d=M9.65,5.241a1,1,0,0,0-1.409.108L6,7.964,3.759,5.349A1,1,0,0,0,2.192,6.59178Q2.21541,6.6213,2.241,6.649L4.684,9.5,2.241,12.35A1,1,0,0,0,3.71,13.70722q0.02557-.02768.049-0.05722L6,11.036,8.241,13.65a1,1,0,1,0,1.567-1.24277Q9.78459,12.3777,9.759,12.35L7.316,9.5,9.759,6.651A1,1,0,0,0,9.65,5.241Z /> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15.5,7H13.861a4.015,4.015,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.922,1.922,0,0,0,12.021,3.7a0.5,0.5,0,1,0,.957.291,0.917,0.917,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.077-1.164,1.925-1.934,2.486A1.423,1.423,0,0,0,12,7.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,7Z /> <path class=ql-fill d=M9.651,5.241a1,1,0,0,0-1.41.108L6,7.964,3.759,5.349a1,1,0,1,0-1.519,1.3L4.683,9.5,2.241,12.35a1,1,0,1,0,1.519,1.3L6,11.036,8.241,13.65a1,1,0,0,0,1.519-1.3L7.317,9.5,9.759,6.651A1,1,0,0,0,9.651,5.241Z /> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <line class="ql-stroke ql-thin" x1=15.5 x2=2.5 y1=8.5 y2=9.5></line> <path class=ql-fill d=M9.007,8C6.542,7.791,6,7.519,6,6.5,6,5.792,7.283,5,9,5c1.571,0,2.765.679,2.969,1.309a1,1,0,0,0,1.9-.617C13.356,4.106,11.354,3,9,3,6.2,3,4,4.538,4,6.5a3.2,3.2,0,0,0,.5,1.843Z></path> <path class=ql-fill d=M8.984,10C11.457,10.208,12,10.479,12,11.5c0,0.708-1.283,1.5-3,1.5-1.571,0-2.765-.679-2.969-1.309a1,1,0,1,0-1.9.617C4.644,13.894,6.646,15,9,15c2.8,0,5-1.538,5-3.5a3.2,3.2,0,0,0-.5-1.843Z></path> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <path class=ql-stroke d=M5,3V9a4.012,4.012,0,0,0,4,4H9a4.012,4.012,0,0,0,4-4V3></path> <rect class=ql-fill height=1 rx=0.5 ry=0.5 width=12 x=3 y=15></rect> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <rect class=ql-stroke height=12 width=12 x=3 y=3></rect> <rect class=ql-fill height=12 width=1 x=5 y=3></rect> <rect class=ql-fill height=12 width=1 x=12 y=3></rect> <rect class=ql-fill height=2 width=8 x=5 y=8></rect> <rect class=ql-fill height=1 width=3 x=3 y=5></rect> <rect class=ql-fill height=1 width=3 x=3 y=7></rect> <rect class=ql-fill height=1 width=3 x=3 y=10></rect> <rect class=ql-fill height=1 width=3 x=3 y=12></rect> <rect class=ql-fill height=1 width=3 x=12 y=5></rect> <rect class=ql-fill height=1 width=3 x=12 y=7></rect> <rect class=ql-fill height=1 width=3 x=12 y=10></rect> <rect class=ql-fill height=1 width=3 x=12 y=12></rect> </svg>'},function(t,e){t.exports='<svg viewbox="0 0 18 18"> <polygon class=ql-stroke points="7 11 9 13 11 11 7 11"></polygon> <polygon class=ql-stroke points="7 7 9 5 11 7 7 7"></polygon> </svg>'},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=e.BubbleTooltip=void 0;var a=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},s=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),u=n(2),c=r(u),f=n(9),h=r(f),p=n(44),d=r(p),y=n(22),v=n(26),b=r(v),g=[["bold","italic","link"],[{header:1},{header:2},"blockquote"]],m=function(t){function e(t,n){o(this,e),null!=n.modules.toolbar&&null==n.modules.toolbar.container&&(n.modules.toolbar.container=g);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.quill.container.classList.add("ql-bubble"),r}return l(e,t),s(e,[{key:"extendToolbar",value:function(t){this.tooltip=new _(this.quill,this.options.bounds),this.tooltip.root.appendChild(t.container),this.buildButtons([].slice.call(t.container.querySelectorAll("button")),b.default),this.buildPickers([].slice.call(t.container.querySelectorAll("select")),b.default)}}]),e}(d.default);m.DEFAULTS=(0,c.default)(!0,{},d.default.DEFAULTS,{modules:{toolbar:{handlers:{link:function(t){t?this.quill.theme.tooltip.edit():this.quill.format("link",!1)}}}}});var _=function(t){function e(t,n){o(this,e);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.quill.on(h.default.events.EDITOR_CHANGE,function(t,e,n,o){if(t===h.default.events.SELECTION_CHANGE)if(null!=e&&e.length>0&&o===h.default.sources.USER){r.show(),r.root.style.left="0px",r.root.style.width="",r.root.style.width=r.root.offsetWidth+"px";var i=r.quill.getLines(e.index,e.length);if(1===i.length)r.position(r.quill.getBounds(e));else{var l=i[i.length-1],a=r.quill.getIndex(l),s=Math.min(l.length()-1,e.index+e.length-a),u=r.quill.getBounds(new y.Range(a,s));r.position(u)}}else document.activeElement!==r.textbox&&r.quill.hasFocus()&&r.hide()}),r}return l(e,t),s(e,[{key:"listen",value:function(){var t=this;a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"listen",this).call(this),this.root.querySelector(".ql-close").addEventListener("click",function(){t.root.classList.remove("ql-editing")}),this.quill.on(h.default.events.SCROLL_OPTIMIZE,function(){setTimeout(function(){if(!t.root.classList.contains("ql-hidden")){var e=t.quill.getSelection();null!=e&&t.position(t.quill.getBounds(e))}},1)})}},{key:"cancel",value:function(){this.show()}},{key:"position",value:function(t){var n=a(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"position",this).call(this,t),r=this.root.querySelector(".ql-tooltip-arrow");if(r.style.marginLeft="",0===n)return n;r.style.marginLeft=-1*n-r.offsetWidth/2+"px"}}]),e}(p.BaseTooltip);_.TEMPLATE=['<span class="ql-tooltip-arrow"></span>','<div class="ql-tooltip-editor">','<input type="text" data-formula="e=mc^2" data-link="https://quilljs.com" data-video="Embed URL">','<a class="ql-close"></a>',"</div>"].join(""),e.BubbleTooltip=_,e.default=m},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function l(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var a=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var l,a=t[Symbol.iterator]();!(r=(l=a.next()).done)&&(n.push(l.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),s=function t(e,n,r){null===e&&(e=Function.prototype);var o=Object.getOwnPropertyDescriptor(e,n);if(void 0===o){var i=Object.getPrototypeOf(e);return null===i?void 0:t(i,n,r)}if("value"in o)return o.value;var l=o.get;if(void 0!==l)return l.call(r)},u=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),c=n(2),f=r(c),h=n(9),p=r(h),d=n(44),y=r(d),v=n(15),b=r(v),g=n(22),m=n(26),_=r(m),O=[[{header:["1","2","3",!1]}],["bold","italic","underline","link"],[{list:"ordered"},{list:"bullet"}],["clean"]],w=function(t){function e(t,n){o(this,e),null!=n.modules.toolbar&&null==n.modules.toolbar.container&&(n.modules.toolbar.container=O);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.quill.container.classList.add("ql-snow"),r}return l(e,t),u(e,[{key:"extendToolbar",value:function(t){t.container.classList.add("ql-snow"),this.buildButtons([].slice.call(t.container.querySelectorAll("button")),_.default),this.buildPickers([].slice.call(t.container.querySelectorAll("select")),_.default),this.tooltip=new x(this.quill,this.options.bounds),t.container.querySelector(".ql-link")&&this.quill.keyboard.addBinding({key:"K",shortKey:!0},function(e,n){t.handlers.link.call(t,!n.format.link)})}}]),e}(y.default);w.DEFAULTS=(0,f.default)(!0,{},y.default.DEFAULTS,{modules:{toolbar:{handlers:{link:function(t){if(t){var e=this.quill.getSelection();if(null==e||0==e.length)return;var n=this.quill.getText(e);/^\S+@\S+\.\S+$/.test(n)&&0!==n.indexOf("mailto:")&&(n="mailto:"+n);this.quill.theme.tooltip.edit("link",n)}else this.quill.format("link",!1)}}}}});var x=function(t){function e(t,n){o(this,e);var r=i(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,n));return r.preview=r.root.querySelector("a.ql-preview"),r}return l(e,t),u(e,[{key:"listen",value:function(){var t=this;s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"listen",this).call(this),this.root.querySelector("a.ql-action").addEventListener("click",function(e){t.root.classList.contains("ql-editing")?t.save():t.edit("link",t.preview.textContent),e.preventDefault()}),this.root.querySelector("a.ql-remove").addEventListener("click",function(e){if(null!=t.linkRange){var n=t.linkRange;t.restoreFocus(),t.quill.formatText(n,"link",!1,p.default.sources.USER),delete t.linkRange}e.preventDefault(),t.hide()}),this.quill.on(p.default.events.SELECTION_CHANGE,function(e,n,r){if(null!=e){if(0===e.length&&r===p.default.sources.USER){var o=t.quill.scroll.descendant(b.default,e.index),i=a(o,2),l=i[0],s=i[1];if(null!=l){t.linkRange=new g.Range(e.index-s,l.length());var u=b.default.formats(l.domNode);return t.preview.textContent=u,t.preview.setAttribute("href",u),t.show(),void t.position(t.quill.getBounds(t.linkRange))}}else delete t.linkRange;t.hide()}})}},{key:"show",value:function(){s(e.prototype.__proto__||Object.getPrototypeOf(e.prototype),"show",this).call(this),this.root.removeAttribute("data-mode")}}]),e}(d.BaseTooltip);x.TEMPLATE=['<a class="ql-preview" target="_blank" href="about:blank"></a>','<input type="text" data-formula="e=mc^2" data-link="https://example.com" data-video="Embed URL">','<a class="ql-action"></a>','<a class="ql-remove"></a>'].join(""),e.default=w}]).default});
5
  /* wpdEditor */
6
+ "use strict";function _typeof(t){return(_typeof="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})(t)}function _get(t,e,i){return(_get="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(t,e,i){var n=_superPropBase(t,e);if(n){var r=Object.getOwnPropertyDescriptor(n,e);return r.get?r.get.call(i):r.value}})(t,e,i||t)}function _superPropBase(t,e){for(;!Object.prototype.hasOwnProperty.call(t,e)&&null!==(t=_getPrototypeOf(t)););return t}function _inherits(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&&_setPrototypeOf(t,e)}function _setPrototypeOf(t,e){return(_setPrototypeOf=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}function _createSuper(t){var e=_isNativeReflectConstruct();return function(){var i,n=_getPrototypeOf(t);if(e){var r=_getPrototypeOf(this).constructor;i=Reflect.construct(n,arguments,r)}else i=n.apply(this,arguments);return _possibleConstructorReturn(this,i)}}function _possibleConstructorReturn(t,e){return!e||"object"!==_typeof(e)&&"function"!=typeof e?_assertThisInitialized(t):e}function _assertThisInitialized(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function _isNativeReflectConstruct(){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 _getPrototypeOf(t){return(_getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}function _instanceof(t,e){return null!=e&&"undefined"!=typeof Symbol&&e[Symbol.hasInstance]?!!e[Symbol.hasInstance](t):t instanceof e}function _classCallCheck(t,e){if(!_instanceof(t,e))throw new TypeError("Cannot call a class as a function")}function _defineProperties(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function _createClass(t,e,i){return e&&_defineProperties(t.prototype,e),i&&_defineProperties(t,i),t}var wpdEditorCounter=function(){function t(e,i){_classCallCheck(this,t),this.quill=e,this.options=i,this.maxCount=i.maxcount,this.minCount=i.mincount,this.container=document.getElementById("wpd-editor-char-counter-"+i.uniqueID),this.submit=document.getElementById("wpd-field-submit-"+i.uniqueID),e.on("editor-change",this.update.bind(this)),this.update()}return _createClass(t,[{key:"calculate",value:function(){var t=this.quill.getText().length,e=this.quill.container.id,i=document.querySelectorAll("#".concat(e," .ql-editor img"));return i.length&&i.forEach(function(e){null!==e.src.match(/https\:\/\/s\.w\.org\/images\/core\/emoji/gi)?t+=e.alt.length:e.classList.contains("wpdem-sticker")?t+=e.alt.length:t+=e.src.length}),t}},{key:"update",value:function(){var t=this.calculate(),e=t-1;if(this.maxCount>0&&t>=this.maxCount&&this.quill.deleteText(this.maxCount,t),this.maxCount>0){var i=this.maxCount-e;this.container.innerText=i>=0?i:0,t+10>this.maxCount?this.container.classList.add("error"):this.container.classList.remove("error")}else this.container.remove()}}]),t}();Quill.register("modules/counter",wpdEditorCounter);var Link=Quill.import("formats/link"),wpdEditorLink=function(t){_inherits(i,Link);var e=_createSuper(i);function i(){return _classCallCheck(this,i),e.apply(this,arguments)}return _createClass(i,null,[{key:"create",value:function(t){var e=_get(_getPrototypeOf(i),"create",this).call(this,t);t=this.sanitize(t),e.setAttribute("href",t);var n=location.protocol+"//"+location.hostname;return(t.startsWith(n)||"#"===t.charAt(0)||"/"===t.charAt(0)&&"/"!==t.charAt(1))&&e.removeAttribute("target"),e}},{key:"sanitize",value:function(t){var e=_get(_getPrototypeOf(i),"sanitize",this).call(this,t),n=e.slice(0,e.indexOf(":"));return"#"!==e.charAt(0)&&"/"!==e.charAt(0)&&-1===this.PROTOCOL_WHITELIST.indexOf(n)&&(e="http://"+t),e}}]),i}();Quill.register(wpdEditorLink,!0);var WpdEditor=function(){function t(){_classCallCheck(this,t),this.editorWraperPrefix="wpd-editor-wraper",this.textEditorContainer="ql-texteditor",this.textEditorPrefix="wc-textarea",this.editorToolbarPrefix="wpd-editor-toolbar",this.sourceCodeButtonName="sourcecode",this.spoiler="spoiler",this.spoilerPromtTitle=wpdiscuzAjaxObj.wc_spoiler_title,this._container="",this._uniqueid="",this.currentEditor=null,this._editors=new Map,this._handlers=new Map,this._initDefaults()}return _createClass(t,[{key:"addButtonEventHandler",value:function(t,e){this._handlers.set(t,e)}},{key:"createEditor",value:function(t){var e=this;if(this.container=t,this._editors.has(this.uniqueid))this.currentEditor=this._editors.get(this.uniqueid);else{var i="#".concat(this.editorToolbarPrefix,"-").concat(this.uniqueid);wpdiscuzEditorOptions.modules.toolbar=i,wpdiscuzEditorOptions.modules.counter.uniqueID=this.uniqueid;var n=new Quill(this.container,wpdiscuzEditorOptions);n.on("editor-change",function(t){null!==(arguments.length<=1?void 0:arguments[1])&&(e.currentEditor=n,e.container=n.container.id)}),n.clipboard.addMatcher("a",function(t,e){return t.getAttribute("href")===t.innerHTML?new(Quill.import("delta"))([{insert:t.innerHTML}]):e}),document.querySelectorAll("".concat(i," button")).forEach(function(t){t.onclick=function(){e.currentEditor=n,e.container=n.container.id;var i=t.dataset.wpde_button_name;void 0!==i&&"string"==typeof i&&""!==i.trim()&&e._handlers.has(i)&&e._handlers.get(i)(e.currentEditor,e.uniqueid)}}),this._bindTextEditor(n),this._editors.set(this.uniqueid,n),document.getElementById("".concat(this.editorWraperPrefix,"-").concat(this.uniqueid)).style.display=""}return this.currentEditor}},{key:"removeEditor",value:function(t){this.container=t,this._editors.has(this.uniqueid)&&this._editors.delete(this.uniqueid)}},{key:"_bindTextEditor",value:function(t){var e="".concat(this.textEditorPrefix,"-").concat(this.uniqueid),i=document.getElementById(e);i.style.cssText="display: none;",t.addContainer(this.textEditorContainer).appendChild(i),this.currentEditor=t}},{key:"_findUniqueId",value:function(){return this.container.substring(this.container.lastIndexOf("-")+1)}},{key:"_initDefaults",value:function(){var t=this;this.addButtonEventHandler(this.sourceCodeButtonName,function(e){document.getElementById("".concat(t.textEditorPrefix,"-").concat(t.uniqueid));var i=document.getElementById("wpd-editor-source-code-wrapper-bg"),n=document.getElementById("wpd-editor-source-code-wrapper"),r=document.getElementById("wpd-editor-source-code"),o=document.getElementById("wpd-editor-uid");i.style.display="block",n.style.display="block",o.value=e.container.id,r.value=e.root.innerHTML}),this.addButtonEventHandler(this.spoiler,function(e){var i=prompt(t.spoilerPromtTitle);if(null!==i){var n=' [spoiler title="'.concat(i,'"] '),r=e.getSelection();null===r&&(r={index:e.getLength()-1,length:0}),0===r.length?(e.insertText(r.index,n+" [/spoiler] ",Quill.sources.USER),e.setSelection(r.index+n.length,Quill.sources.USER)):(e.insertText(r.index,n),e.insertText(r.index+n.length+r.length," [/spoiler] ",Quill.sources.USER),e.setSelection(r.index+n.length+r.length+" [/spoiler] ".length,Quill.sources.USER))}})}},{key:"uniqueid",set:function(t){""!==t&&"string"==typeof t?this._uniqueid=t:""===t?this._uniqueid=this._findUniqueId():console.error("Incorrect uniqueid.")},get:function(){return this._uniqueid}},{key:"container",set:function(t){""!==t&&"string"==typeof t?(this._container=t,this.uniqueid=this._findUniqueId()):console.error("Incorrect uniqueid.")},get:function(){return this._container}}]),t}();
7
  /* Autogrow */
8
  jQuery.fn.autoGrow=function(){return this.each(function(){var createMirror=function(textarea){jQuery(textarea).after('<div class="autogrow-textarea-mirror"></div>');return jQuery(textarea).next(".autogrow-textarea-mirror")[0]};var sendContentToMirror=function(textarea){mirror.innerHTML=String(textarea.value).replace(/&/g,"&amp;").replace(/"/g,"&quot;").replace(/'/g,"&#39;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/\n/g,"<br />")+".<br/>.";if(jQuery(textarea).height()!=jQuery(mirror).height())jQuery(textarea).height(jQuery(mirror).height())};var growTextarea=function(){sendContentToMirror(this)};var mirror=createMirror(this);mirror.style.display="none";mirror.style.wordWrap="break-word";mirror.style.padding=jQuery(this).css("padding");mirror.style.width=jQuery(this).css("width");mirror.style.fontFamily=jQuery(this).css("font-family");mirror.style.fontSize=jQuery(this).css("font-size");mirror.style.lineHeight=jQuery(this).css("line-height");this.style.overflow="hidden";this.style.minHeight=this.rows+"em";this.onkeydown=growTextarea;sendContentToMirror(this)})};
9
  /* wpDiscuz */
10
+ var wpdiscuzLoadRichEditor=parseInt(wpdiscuzAjaxObj.loadRichEditor);if(wpdiscuzLoadRichEditor)var wpDiscuzEditor=new WpdEditor;function wpdMessagesOnInit(e,t){wpdiscuzAjaxObj.setCommentMessage(e,t),setTimeout(function(){location.href=location.href.substring(0,location.href.indexOf("wpdiscuzUrlAnchor")-1)},3e3)}wpdiscuzAjaxObj.setCommentMessage=function(e,t,a){var o="wpdiscuz-message-error";if("[object Array]"===Object.prototype.toString.call(e))for(var d in e)"[object Array]"===Object.prototype.toString.call(t)?"success"===t[d]?o="wpdiscuz-message-success":"warning"===t[d]&&(o="wpdiscuz-message-warning"):"success"===t?o="wpdiscuz-message-success":"warning"===t&&(o="wpdiscuz-message-warning"),jQuery("<div/>").addClass(o).html(e[d]).prependTo("#wpdiscuz-comment-message").delay("[object Array]"===Object.prototype.toString.call(a)?a[d]:a||4e3).fadeOut(1e3,function(){jQuery(this).remove()});else"success"===t?o="wpdiscuz-message-success":"warning"===t&&(o="wpdiscuz-message-warning"),jQuery("<div/>").addClass(o).html(e).prependTo("#wpdiscuz-comment-message").delay(a||4e3).fadeOut(1e3,function(){jQuery(this).remove()})},jQuery(document).ready(function(e){e("body").addClass("wpdiscuz_"+wpdiscuzAjaxObj.version);var t=wpdiscuzAjaxObj.is_user_logged_in,a=1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!t,o=1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&t,d=wpdiscuzAjaxObj.wpDiscuzReCaptchaVersion,n=parseInt(wpdiscuzAjaxObj.commentListLoadType),s=parseInt(wpdiscuzAjaxObj.wc_post_id),i=parseInt(wpdiscuzAjaxObj.commentListUpdateType),c=1e3*parseInt(wpdiscuzAjaxObj.commentListUpdateTimer),p=parseInt(wpdiscuzAjaxObj.liveUpdateGuests),r=wpdiscuzAjaxObj.loadLastCommentId,l=r,m=parseInt(wpdiscuzAjaxObj.firstLoadWithAjax);Cookies.get("wpdiscuz_comments_sorting")&&Cookies.remove("wpdiscuz_comments_sorting",{path:""}),Cookies.get("wordpress_last_visit")&&Cookies.remove("wordpress_last_visit",{path:""}),Cookies.get("wpdiscuz_last_visit")&&Cookies.remove("wpdiscuz_last_visit",{path:""});var w,u=wpdiscuzAjaxObj.storeCommenterData,f=parseInt(wpdiscuzAjaxObj.wmuEnabled),h=wpdiscuzAjaxObj.isCookiesEnabled,b=!0,g=wpdiscuzAjaxObj.cookiehash,_=parseInt(wpdiscuzAjaxObj.isLoadOnlyParentComments),v=parseInt(wpdiscuzAjaxObj.enableDropAnimation)?500:0,z=parseInt(wpdiscuzAjaxObj.isNativeAjaxEnabled),j=parseInt(wpdiscuzAjaxObj.enableBubble),C=parseInt(wpdiscuzAjaxObj.bubbleLiveUpdate),k=parseInt(wpdiscuzAjaxObj.bubbleHintTimeout),x=parseInt(wpdiscuzAjaxObj.bubbleHintHideTimeout)?parseInt(wpdiscuzAjaxObj.bubbleHintHideTimeout):5,y=parseInt(wpdiscuzAjaxObj.bubbleShowNewCommentMessage),O=wpdiscuzAjaxObj.bubbleLocation,A=wpdiscuzAjaxObj.inlineFeedbackAttractionType,I=[],T=[],D=[],E=!1,M=1;(e(".wc_social_plugin_wrapper .wp-social-login-provider-list").length?e(".wc_social_plugin_wrapper .wp-social-login-provider-list").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .the_champ_login_container").length?e(".wc_social_plugin_wrapper .the_champ_login_container").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .social_connect_form").length?e(".wc_social_plugin_wrapper .social_connect_form").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .oneall_social_login_providers").length&&e(".wc_social_plugin_wrapper .oneall_social_login .oneall_social_login_providers").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"),wpdiscuzLoadRichEditor&&e("#wpd-editor-0_0").length&&wpDiscuzEditor.createEditor("#wpd-editor-0_0"),e(document).delegate("#wpdcom .ql-editor, #wpdcom .wc_comment","focus",function(){e(".wpd-form-foot",e(this).parents(".wpd_comm_form")).slideDown(v)}),e(document).delegate("#wpdcom textarea","focus",function(){e(this).next(".autogrow-textarea-mirror").length||e(this).autoGrow()}),t)||S({comment_author:Cookies.get("comment_author_"+g),comment_author_email:Cookies.get("comment_author_email_"+g),comment_author_url:Cookies.get("comment_author_url_"+g)});if(e(".wpd-vote-down.wpd-dislike-hidden").remove(),e(".wpd-toolbar-hidden").prev("[id^=wpd-editor-]").css("border-bottom","1px solid #dddddd"),e(document).delegate("#wpd-editor-source-code-wrapper-bg","click",function(){e(this).hide(),e("#wpd-editor-source-code-wrapper").hide(),e("#wpd-editor-uid").val(""),e("#wpd-editor-source-code").val("")}),wpdiscuzLoadRichEditor&&e(document).delegate("#wpd-insert-source-code","click",function(){var t=wpDiscuzEditor.createEditor("#"+e("#wpd-editor-uid").val());t.deleteText(0,t.getLength(),Quill.sources.USER);var a=e("#wpd-editor-source-code").val();a.length&&(console.log(a),t.clipboard.dangerouslyPasteHTML(0,a,Quill.sources.USER)),t.update(),e("#wpd-editor-source-code-wrapper-bg").hide(),e("#wpd-editor-source-code-wrapper").hide(),e("#wpd-editor-uid").val(""),e("#wpd-editor-source-code").val("")}),e(document).delegate(".wpd-reply-button","click",function(){var n=V(e(this),0);e(this).hasClass("wpdiscuz-clonned")?(wpdiscuzLoadRichEditor?setTimeout(function(){wpDiscuzEditor.createEditor("#wpd-editor-"+n).focus()},v):setTimeout(function(){e("#wc-textarea-"+n).trigger("focus")},v),e("#wpd-secondary-form-wrapper-"+n).slideToggle(v)):function(a){var o=V(a,0);e("#wpdiscuz_form_anchor-"+o).before(function(t){return e("#wpdiscuz_hidden_secondary_form").html().replace(/wpdiscuzuniqueid/g,t)}(o));var d=e("#wpd-secondary-form-wrapper-"+o);if(!t){var n={comment_author:Cookies.get("comment_author_"+g),comment_author_email:Cookies.get("comment_author_email_"+g),comment_author_url:Cookies.get("comment_author_url_"+g)};S(n)}wpdiscuzLoadRichEditor?setTimeout(function(){wpDiscuzEditor.createEditor("#wpd-editor-"+o).focus()},v):setTimeout(function(){e("#wc-textarea-"+o).trigger("focus")},v);d.slideToggle(v,function(){a.addClass("wpdiscuz-clonned")})}(e(this)),function(t){if((a||o)&&"2.0"===d){var n=B(t);setTimeout(function(){if(!T[n])try{T[n]=grecaptcha.render("wpdiscuz-recaptcha-"+t,{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(a){e("#wpdiscuz-recaptcha-field-"+t).val("key")},"expired-callback":function(){e("#wpdiscuz-recaptcha-field-"+t).val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}},1e3)}}(n)}),e(document).delegate("#wpdcom .wpd-comment-link [data-comment-url]","click",function(){var t=e(this).data("comment-url"),a=e("<input/>");a.appendTo("body").css({position:"absolute",top:"-10000000px"}).val(t),a.select(),document.execCommand("copy"),a.remove(),wpdiscuzAjaxObj.setCommentMessage(t+"<br/>"+wpdiscuzAjaxObj.wc_copied_to_clipboard,"success",5e3)}),e(document).delegate(".wpdiscuz-nofollow,.wc_captcha_refresh_img,.wpd-load-more-submit","click",function(e){e.preventDefault()}),e(document).delegate(".wpd-toggle.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked");var a=V(e(this),0),o=e(this),d=e(".fas",o);!o.parents(".wpd-comment:not(.wpd-reply)").children(".wpd-reply").length&&_?function(t,a){var o=B(t),d=new FormData;d.append("action","wpdShowReplies"),d.append("commentId",o),ce(z,!0,d).done(function(o){a.addClass("wpd_not_clicked"),"object"==typeof o&&o.success&&(e("#wpd-comm-"+t).replaceWith(o.data.comment_list),e("#wpd-comm-"+t+" .wpd-toggle .fas").removeClass("fa-chevron-down").addClass("fa-chevron-up"),e("#wpd-comm-"+t+" .wpd-toggle").attr("wpd-tooltip",wpdiscuzAjaxObj.wc_hide_replies_text),e("#wpd-comm-"+t+" .wpd-toggle .wpd-view-replies").remove(),ie(o)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,o,d){console.log(d),a.addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}(a,t):e("#wpd-comm-"+a+"> .wpd-reply").slideToggle(700,function(){e(this).is(":hidden")?(d.removeClass("fa-chevron-up"),d.addClass("fa-chevron-down"),o.attr("wpd-tooltip",wpdiscuzAjaxObj.wc_show_replies_text)):(d.removeClass("fa-chevron-down"),d.addClass("fa-chevron-up"),o.attr("wpd-tooltip",wpdiscuzAjaxObj.wc_hide_replies_text)),t.addClass("wpd_not_clicked")})}),e(document).delegate(".wpd-new-loaded-comment","mouseenter",function(){e(this).removeClass("wpd-new-loaded-comment")}),e(document).delegate(".wpd-sbs-toggle","click",function(){e(".wpdiscuz-subscribe-bar").slideToggle(v)}),parseInt(wpdiscuzAjaxObj.wpDiscuzIsShowOnSubscribeForm)&&!t&&wpdiscuzAjaxObj.wpDiscuzReCaptchaSK&&("2.0"===d?(setTimeout(function(){try{grecaptcha.render("wpdiscuz-recaptcha-subscribe-form",{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(t){e("#wpdiscuz-recaptcha-field-subscribe-form").val("key")},"expired-callback":function(){e("#wpdiscuz-recaptcha-field-subscribe-form").val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}},1e3),e(document).delegate("#wpdiscuz-subscribe-form","submit",function(t){e("#wpdiscuz-recaptcha-field-subscribe-form").val()?e(".wpdiscuz-recaptcha",e(this)).css("border","none"):(e(".wpdiscuz-recaptcha",e(this)).css("border","1px solid red"),t.preventDefault())})):"3.0"===d&&e(document).delegate("#wpdiscuz_subscription_button","click",function(t){var a=e(this).parents("#wpdiscuz-subscribe-form");t.preventDefault();try{grecaptcha.ready(function(){grecaptcha.execute(wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,{action:"wpdiscuz/wpdAddSubscription"}).then(function(e){console.log(5555),document.getElementById("wpdiscuz-recaptcha-field-subscribe-form").value=e,a.submit()},function(e){wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error","error"),console.log(e)})})}catch(t){console.log(t),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+t.message,"error")}})),(a||o)&&"2.0"===d){var F=e(window).width(),L=e("#wpdcom").width();L>=1100&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"65%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"35%"})),L>=940&&L<1100&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"60%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"40%"})),L>=810&&L<940&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"40%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"60%"})),L>=730&&L<810&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"45%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"55%"})),L>=610&&L<730&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.85)","-webkit-transform":"scale(0.85)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"43%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"55%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"30%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"70%"})),F>650&&(L>=510&&L<610&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"center 0","-webkit-transform-origin":"center 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"35%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"63%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"30%",position:"relative",right:"-60px"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"70%"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"})),L>=470&&L<510&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"center 0","-webkit-transform-origin":"center 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"40%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"60%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd_main_comm_form .wc-form-footer").css({"margin-left":"0px"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"})),L<470&&(e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({margin:"0px auto","transform-origin":"center 0","-webkit-transform-origin":"center 0"}),e("#wpdcom .wpd-form-col-left").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-form-col-right").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"}),e("#wpdcom .wpd-secondary-form-wrapper .wc_notification_checkboxes").css({"text-align":"center"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-field-submit").css({"text-align":"center"})))}function R(t,a,o){ce(z||f,!1,a).done(function(a){if(e(o).addClass("wpd_not_clicked"),"object"==typeof a)if(a.success){"collapsed"===wpdiscuzAjaxObj.commentFormView&&e(".wpd-form-foot",t).slideUp(v),e(".wpd-thread-info").html(a.data.wc_all_comments_count_new_html),a.data.wc_all_comments_count_new=parseInt(a.data.wc_all_comments_count_new),e("#wpd-bubble-all-comments-count").text(a.data.wc_all_comments_count_new),a.data.wc_all_comments_count_new?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide();var d=v;a.data.is_main?X(a.data.message):(d=v+700,e("#wpd-secondary-form-wrapper-"+a.data.uniqueid).slideToggle(700),1==a.data.is_in_same_container?e("#wpd-secondary-form-wrapper-"+a.data.uniqueid).after(a.data.message):e("#wpd-comm-"+a.data.uniqueid).after(a.data.message)),function(e){if(!e.data.held_moderate){var t=new FormData;t.append("action","wpdCheckNotificationType"),t.append("comment_id",e.data.new_comment_id),t.append("email",e.data.comment_author_email),t.append("isParent",e.data.is_main),ce(z,!0,t)}}(a),function(e){if(e.data.redirect>0&&e.data.new_comment_id){var t=new FormData;t.append("action","wpdRedirect"),t.append("commentId",e.data.new_comment_id),ce(z,!0,t).done(function(e){"object"==typeof e&&e.success&&setTimeout(function(){location.href=e.data},2e3)}).fail(function(e,t,a){console.log(a)})}}(a),h&&b?function(t){var a=t.comment_author_email,o=t.comment_author,d=t.comment_author_url;null==u?(Cookies.set("comment_author_email_"+g,a),Cookies.set("comment_author_"+g,o),d.length&&Cookies.set("comment_author_url_"+g,d)):(u=parseInt(u),Cookies.set("comment_author_email_"+g,a,{expires:u,path:"/"}),Cookies.set("comment_author_"+g,o,{expires:u,path:"/"}),d.length&&Cookies.set("comment_author_url_"+g,d,{expires:u,path:"/"}));e(".wpd-cookies-checkbox").length&&e(".wpd-cookies-checkbox").attr("checked","checked")}(a.data):b||e(".wpd-cookies-checkbox").removeAttr("checked"),wpdiscuzLoadRichEditor&&wpDiscuzEditor.createEditor("#wpd-editor-"+e(".wpdiscuz_unique_id",t).val()).setContents([{insert:"\n"}]),t.get(0).reset(),S(a.data),e(".wmu-preview-wrap",t).remove(),I.length&&(I.forEach(function(e){e.parents(".wpd-field-checkbox").remove()}),I=[]),setTimeout(function(){e("html, body").animate({scrollTop:e("#comment-"+a.data.new_comment_id).offset().top-32},1e3)},d),ie(a,t)}else a.data&&(wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"),ie(a,t));else wpdiscuzAjaxObj.setCommentMessage(a,"error");e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,d){console.log(d),e(o).addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}function S(t){e(".wpd_comm_form .wc_name").val(t.comment_author),t.comment_author_email&&t.comment_author_email.indexOf("@example.com")<0&&e(".wpd_comm_form .wc_email").val(t.comment_author_email),t.comment_author_url&&e(".wpd_comm_form .wc_website").val(t.comment_author_url)}function q(t,a){e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd_editable_comment").show(),e("#wpd-comm-"+t+" .wpdiscuz-edit-form-wrap").replaceWith(a),e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").show()}e(document).delegate(".wc_comm_submit.wpd_not_clicked","click",function(){var t=e(this),n=1,s=e(this).parents("form");if(s.hasClass("wpd_main_comm_form")||(n=function(t){var a=t.attr("class").split(" "),o="";return e.each(a,function(e,t){"wpd_comment_level"===G(t,!1)&&(o=G(t,!0))}),parseInt(o)+1}(e(this).parents(".wpd-comment"))),J(s,"#wpd-editor-"+e(".wpdiscuz_unique_id",s).val()),s.submit(function(e){e.preventDefault()}),""!==e(".wc_comment",s).val().trim()&&"<br>"!==e(".wc_comment",s).val().trim()){if(s[0].checkValidity()&&(c=s,p=!0,"2.0"===d&&e("input[name=wc_captcha]",c).length&&!e("input[name=wc_captcha]",c).val().length?(p=!1,e(".wpdiscuz-recaptcha",c).css("border","1px solid red")):"2.0"===d&&e("input[name=wc_captcha]",c).length&&e(".wpdiscuz-recaptcha",c).css("border","none"),p)){E=!0,function(t){e(".wpd-agreement-checkbox",t).each(function(){e(this).hasClass("wpd_agreement_hide")&&h&&e(this).prop("checked")&&(Cookies.set(e(this).attr("name")+"_"+g,1,{expires:30,path:"/"}),e("input[name="+e(this).attr("name")+"]").each(function(){I.push(e(this))}))})}(s),e(t).removeClass("wpd_not_clicked");var i=new FormData;if(i.append("action","wpdAddComment"),e(":input",s).each(function(){""!=this.name&&"checkbox"!=this.type&&"radio"!=this.type&&i.append(this.name+"",e(this).val().trim()),"checkbox"!=this.type&&"radio"!=this.type||e(this).is(":checked")&&i.append(this.name+"",e(this).val())}),i.append("wpd_comment_depth",n),wpdiscuzAjaxObj.wpdiscuz_zs&&i.append("wpdiscuz_zs",wpdiscuzAjaxObj.wpdiscuz_zs),e(".wpd-cookies-checkbox",s).length&&!e(".wpd-cookies-checkbox",s).prop("checked")&&(b=!1),e("#wpdiscuz-loading-bar").show(),wpdiscuzAjaxObj.wpDiscuzReCaptchaSK&&"3.0"===d&&(1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!wpdiscuzAjaxObj.is_user_logged_in||1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&wpdiscuzAjaxObj.is_user_logged_in))try{grecaptcha.ready(function(){grecaptcha.execute(wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,{action:"wpdiscuz/addComment"}).then(function(e){i.append("g-recaptcha-response",e),R(s,i,t)},function(e){wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error","error"),console.log(e)})})}catch(t){console.log(t),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+t.message,"error"),e("#wpdiscuz-loading-bar").fadeOut(250)}else R(s,i,t)}var c,p;!function(e){if((a||o)&&"2.0"===d){var t=B(e);grecaptcha.reset(T[t])}}(e(".wpdiscuz_unique_id",s).val()),e(".wpdiscuz_reset").val("")}else wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj.wc_msg_required_fields,"error")}),e(document).delegate(".wpd_editable_comment","click",function(){w&&e(".wpdiscuz-edit-form-wrap").length&&q(V(e(".wpdiscuz-edit-form-wrap"),0),w);var t=V(e(this),0),a=B(t),o=new FormData;o.append("action","wpdEditComment"),o.append("commentId",a),w=e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-text").get(0),ce(z,!0,o).done(function(a){if("object"==typeof a)if(a.success){if(e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd-comment-text").replaceWith(a.data.html),wpdiscuzLoadRichEditor){let o=wpDiscuzEditor.createEditor("#wpd-editor-edit_"+t);o.clipboard.dangerouslyPasteHTML(0,a.data.content),o.update(),e(".wpd-toolbar-hidden").prev("[id^=wpd-editor-]").css("border-bottom","1px solid #dddddd")}else e("#wc-textarea-edit_"+t).val(a.data.content);e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd_editable_comment").hide(),e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").hide()}else wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error");else console.log(a);e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wc_save_edited_comment","click",function(){var t=V(e(this)),a=B(t),o=e("#wpd-comm-"+t+" #wpdiscuz-edit-form");if(J(o,"#wpd-editor-edit_"+t),o.submit(function(e){e.preventDefault()}),o[0].checkValidity()){var d=new FormData;d.append("action","wpdSaveEditedComment"),d.append("commentId",a),e(":input",o).each(function(){""!==this.name&&"checkbox"!==this.type&&"radio"!==this.type&&d.append(this.name+"",e(this).val()),"checkbox"!==this.type&&"radio"!==this.type||e(this).is(":checked")&&d.append(this.name+"",e(this).val())}),ce(z,!0,d).done(function(o){"object"==typeof o?(o.success?(q(t,o.data.message),o.data.lastEdited&&(e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").remove(),e(o.data.lastEdited).insertAfter("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd-comment-text")),o.data.twitterShareLink&&e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-share .wpd-tooltip-content .wc_tw").attr("href",o.data.twitterShareLink),o.data.whatsappShareLink&&e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-share .wpd-tooltip-content .wc_whatsapp").attr("href",o.data.whatsappShareLink),wpdiscuzLoadRichEditor&&wpDiscuzEditor.removeEditor("#wpd-editor-edit_"+t)):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[o.data],"error"),ie(o,a)):console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(document).delegate(".wc_cancel_edit","click",function(){var t=V(e(this));q(t,w),wpdiscuzLoadRichEditor&&wpDiscuzEditor.removeEditor("#wpd-editor-edit_"+t)}),!wpdiscuzAjaxObj.wordpressIsPaginate&&m&&(M=0,1==m?setTimeout(function(){W(!0)},500):e(document).delegate(".wpd-load-comments","click",function(){e(this).remove(),W(!0)})),e(document).delegate(".wpd-load-more-submit","click",function(){var t=e(this);t.hasClass("wpd-loaded")&&W(!1,t,"wpd-loaded","wpd-loading")});var U=!1;function H(){var t=e("#wpdiscuzHasMoreComments").val(),a=e(document).height(),o=e(window).height()+e(window).scrollTop();a&&o&&(100*o/a>=80&&!1===U&&1==t&&(U=!0,W(!1,e(".wpd-load-more-submit"))))}function W(t,a,o,d){a&&(a.toggleClass(o),a.toggleClass(d));var s=new FormData;s.append("action","wpdLoadMoreComments");var i=e(".wpdiscuz-sort-button-active").attr("data-sorting");i&&s.append("sorting",i),s.append("offset",M),s.append("lastParentId",e(".wpd-load-more-submit").attr("data-lastparentid")),s.append("isFirstLoad",t?1:0);var c=e(".wpdf-active").attr("data-filter-type");s.append("wpdType",c||""),ce(z,!0,s).done(function(s){"object"==typeof s&&s.success&&(M++,e(".wpdiscuz-comment-pagination").before(s.data.comment_list),K(s,t&&2!==n),e(".wpdiscuz_single").remove(),U=!1,r=s.data.loadLastCommentId,ie(s),t&&P(!1)),e("#wpdiscuz-loading-bar").fadeOut(250),e(".wpd-load-more-submit").blur(),a&&(a.toggleClass(o),a.toggleClass(d))}).fail(function(t,n,s){console.log(s),e("#wpdiscuz-loading-bar").fadeOut(250),e(".wpd-load-more-submit").blur(),a&&(a.toggleClass(o),a.toggleClass(d))})}function K(t,a){var o;0==t.data.is_show_load_more?(e("#wpdiscuzHasMoreComments").val(0),e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").hide()):(o=t.data.last_parent_id,e(".wpd-load-more-submit").attr("data-lastparentid",o),2!==n&&e(".wpdiscuz-comment-pagination").show(),e("#wpdiscuzHasMoreComments").val(1),a&&e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").show()),ie(t)}function P(t){var a=location.href.match(/#comment\-(\d+)/);if(null!==a){var o=a[1];if(e("#comment-"+o).length)setTimeout(function(){e("html, body").animate({scrollTop:e("#comment-"+o).parents("[id^=wpd-comm-]").offset().top-32},1e3),t&&N(o)},500);else{var d=new FormData;d.append("action","wpdGetSingleComment"),d.append("commentId",o),ce(z,!0,d).done(function(a){if("object"==typeof a&&a.success){var d="#comment-"+o;e("#comment-"+a.data.parentCommentID).length?e("#comment-"+a.data.parentCommentID).parents("[id^=wpd-comm-"+a.data.parentCommentID+"]").replaceWith(a.data.message):e(".wpd-thread-list").prepend(a.data.message),ie(a),e("html, body").animate({scrollTop:e(d).offset().top-32},1e3),t&&N(o)}e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}}function N(t){setTimeout(function(){e("#comment-"+t).siblings(".wpd-secondary-form-wrapper").is(":visible")||e("#comment-"+t).find(".wpd-reply-button").trigger("click")},1100)}function Q(e){if(void 0!==e.data.message)for(var t,a=e.data.message,o=0;o<a.length;o++)$((t=a[o]).comment_parent,t.comment_html)}function V(e,t){var a="";return(a=t?e.parents(".wpd-main-form-wrapper").attr("id"):e.parents(".wpd-comment").attr("id")).substring(a.lastIndexOf("-")+1)}function B(e){return e.substring(0,e.indexOf("_"))}function G(e,t){return t?e.substring(e.indexOf("-")+1):e.substring(0,e.indexOf("-"))}function $(t,a){if(0==t)X(a);else{var o=V(e("#comment-"+t),0);e("#wpdiscuz_form_anchor-"+o).after(a)}}function Y(){var t,a,o="";return e(".wpd-comment-right").each(function(){t=V(e(this),0),a=B(t),o+=a+","}),o}function J(t,a){var o=t.find(".wpd-required-group");wpdiscuzLoadRichEditor&&t.find(".wc_comment").val(e(a+">.ql-editor").html()),function(e){var t=e.find(".wc_comment"),a=t.val().trim().replace(/<p><br><\/p>/g,"&nbsp;\n").replace(/<p>(.*?)<\/p>/g,"$1\n");a=(a=(a=(a=a.replace(/<img src=["|']https\:\/\/s\.w\.org\/images\/core\/emoji\/([^"|']+)["|'](.*?)alt=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$3")).replace(/<img[^>]+alt=["|']([^"|']+)["|'][^>]+src=["|']https\:\/\/s\.w\.org\/images\/core\/emoji\/([^"|']+)["|'][^>]?>/g,"$1")).replace(/<img\s+([^>]*)class=["|']wpdem\-sticker["|'](.*?)alt=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$3")).replace(/<img\s+([^>]*)src=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$2"),t.val(a)}(t),e.each(o,function(){e("input",this).removeAttr("required"),0===e("input:checked",this).length?e("input",e(this)).attr("required","required"):e(".wpd-field-invalid",this).remove()})}function X(t){e(".wpd-sticky-comment").last()[0]?e(t).insertAfter(e(".wpd-sticky-comment").last()[0]):e(".wpd-thread-list").prepend(t)}function Z(t){t?t.prop("required")||(t.val()?t.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","inline-block"):t.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","none")):e.each(e(".wc_email"),function(t,a){var o=e(a);o.prop("required")||(o.val()?o.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","inline-block"):o.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","none"))})}if(2!==n||wpdiscuzAjaxObj.wordpressIsPaginate||(e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").hide(),H(),e(window).scroll(function(){H()})),wpdiscuzAjaxObj.setLoadMoreVisibility=K,e(document).delegate(".wpd-vote-up.wpd_not_clicked, .wpd-vote-down.wpd_not_clicked","click",function(){var t=e(this);e(t).removeClass("wpd_not_clicked");var a,o=B(V(t));a=e(this).hasClass("wpd-vote-up")?1:-1;var d=new FormData;d.append("action","wpdVoteOnComment"),d.append("commentId",o),d.append("voteType",a),ce(z,!0,d).done(function(d){if(e(t).addClass("wpd_not_clicked"),"object"==typeof d){if(d.success){if("total"===d.data.buttonsStyle){var n=e(".wpd-comment-footer .wpd-vote-result",e("#comment-"+o)),s=d.data.votes;n.text(s),n.removeClass("wpd-up wpd-down"),s>0&&n.addClass("wpd-up"),s<0&&n.addClass("wpd-down")}else{var i=e(".wpd-comment-footer .wpd-vote-result-like",e("#comment-"+o)),c=e(".wpd-comment-footer .wpd-vote-result-dislike",e("#comment-"+o));i.text(d.data.likeCount),c.text(d.data.dislikeCount),parseInt(d.data.likeCount)>0?i.addClass("wpd-up"):i.removeClass("wpd-up"),parseInt(d.data.dislikeCount)<0?c.addClass("wpd-down"):c.removeClass("wpd-down")}var p=e(".wpd-comment-footer .wpd-vote-up",e("#comment-"+o)),r=e(".wpd-comment-footer .wpd-vote-down",e("#comment-"+o));p.removeClass("wpd-up"),r.removeClass("wpd-down"),d.data.curUserReaction>0?p.addClass("wpd-up"):d.data.curUserReaction<0&&r.addClass("wpd-down")}else d.data&&wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[d.data],"error");ie(d,o,a)}else console.log(d);e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(a,o,d){console.log(d),e(t).addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate("body","click",function(t){var a=e(".wpdiscuz-sort-buttons");e(t.target).hasClass("wpdf-sorting")||e(t.target).parent().hasClass("wpdf-sorting")?a.css({display:a.is(":visible")?"none":"flex"}):a.hide()}),e(document).delegate(".wpdiscuz-sort-button:not(.wpdiscuz-sort-button-active)","click",function(){var t=e(this),a=e(this).attr("data-sorting");if(a){e(".wpdiscuz-sort-button.wpdiscuz-sort-button-active").removeClass("wpdiscuz-sort-button-active").appendTo(".wpdiscuz-sort-buttons"),t.addClass("wpdiscuz-sort-button-active").prependTo(".wpdf-sorting");var o=new FormData;o.append("action","wpdSorting"),o.append("sorting",a);var d=e(".wpdf-active").attr("data-filter-type");o.append("wpdType",d||""),ce(z,!0,o).done(function(t){"object"==typeof t&&t.success&&(e("#wpdcom .wpd-comment").remove(),e("#wpdcom .wpd-thread-list").prepend(t.data.message),K(t,!1),M=1),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),window.onhashchange=function(){P(!1)},1!=m&&P(!1),e(document).delegate(".wpdiscuz-readmore","click",function(){var t=V(e(this)),a=B(t),o=new FormData;o.append("action","wpdReadMore"),o.append("commentId",a),ce(z,!0,o).done(function(o){"object"==typeof o?(o.success?(e("#comment-"+a+" .wpd-comment-text").html(" "+o.data.message),e("#wpdiscuz-readmore-"+t).remove()):console.log(o.data),ie(o)):console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-required-group","change",function(){0!==e("input:checked",this).length?e("input",e(this)).removeAttr("required"):e("input",e(this)).attr("required","required")}),e(document).delegate(".wpdiscuz-spoiler","click",function(){e(this).next().slideToggle(),e(this).hasClass("wpdiscuz-spoiler-closed")?e(this).parents(".wpdiscuz-spoiler-wrap").find(".fa-plus").removeClass("fa-plus").addClass("fa-minus"):e(this).parents(".wpdiscuz-spoiler-wrap").find(".fa-minus").removeClass("fa-minus").addClass("fa-plus"),e(this).toggleClass("wpdiscuz-spoiler-closed")}),e(document).delegate(".wpd-tools i","click",function(){var t=e(this).siblings(".wpd-tools-actions");t.css({display:t.is(":visible")?"none":"flex"})}),e(document).delegate(".wpd-comment-right","mouseleave",function(){e(this).find(".wpd-tools-actions").hide()}),e(document).delegate(".wpd_stick_btn","click",function(){var t=B(V(e(this),0)),a=new FormData;a.append("action","wpdStickComment"),a.append("commentId",t),ce(z,!0,a).done(function(t){"object"==typeof t&&t.success&&location.reload(!0),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd_close_btn","click",function(){var t=B(V(e(this),0)),a=new FormData;a.append("action","wpdCloseThread"),a.append("commentId",t),ce(z,!0,a).done(function(t){"object"==typeof t&&t.success&&location.reload(!0),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-filter.wpd_not_clicked[data-filter-type]","click",function(){var t=e(this),a=t.attr("data-filter-type");wpdiscuzAjaxObj.resetActiveFilters(".wpdf-"+a),t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var o=new FormData;o.append("action","wpdLoadMoreComments");var d=e(".wpdiscuz-sort-button-active").attr("data-sorting");d&&o.append("sorting",d),o.append("lastParentId",0),o.append("offset",0),M=1,o.append("wpdType",t.hasClass("wpdf-active")?"":a),o.append("isFirstLoad",1),e(this).hasClass("wpdf-inline")?e(this).hasClass("wpdf-active")?e(".wpd-comment-info-bar").hide():e(".wpd-comment-info-bar").css("display","flex"):e(".wpd-comment-info-bar").hide(),ce(z,!1,o).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(t.toggleClass("wpdf-active"),e(".wpd-load-comments").remove(),e(".wpd-comment").remove(),e(".wpd-thread-list").prepend(a.data.comment_list),K(a),r=a.data.loadLastCommentId,e(".wpd-load-more-submit").blur(),ie(a)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpdf-reacted.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=new FormData;a.append("action","wpdMostReactedComment"),ce(z,!1,a).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(e("#comment-"+a.data.parentCommentID).length?e("#comment-"+a.data.parentCommentID).parents("[id^=wpd-comm-"+a.data.parentCommentID+"]").replaceWith(a.data.message):e("#comment-"+a.data.commentId).length||e(".wpd-thread-list").prepend(a.data.message),ie(a),e("html, body").animate({scrollTop:e("#comment-"+a.data.commentId).offset().top-32},1e3))}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner")})}),e(document).delegate(".wpdf-hottest.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=new FormData;a.append("action","wpdHottestThread"),ce(z,!1,a).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(e("#comment-"+a.data.commentId).length?e("#comment-"+a.data.commentId).parents("[id^=wpd-comm-"+a.data.commentId+"]").replaceWith(a.data.message):e(".wpd-thread-list").prepend(a.data.message),ie(a),e("html, body").animate({scrollTop:e("#comment-"+a.data.commentId).offset().top-32},1e3))}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner")})}),e(document).delegate(".wpd-filter-view-all","click",function(){e(".wpdf-inline.wpdf-active.wpd_not_clicked").trigger("click")}),e(document).delegate(".wpd-follow-link.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=B(V(t,0)),o=new FormData;o.append("action","wpdFollowUser"),o.append("commentId",a),ce(z,!0,o).done(function(a){t.addClass("wpd_not_clicked"),"object"==typeof a?a.success?(wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data.code],"success"),t.removeClass("wpd-follow-active"),a.data.followTip&&t.attr("wpd-tooltip",a.data.followTip),a.data.followClass&&t.addClass(a.data.followClass)):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"):console.log(a),e(".fas",t).removeClass("fa-pulse fa-spinner"),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner"),e("#wpdiscuz-loading-bar").fadeOut(250)})}),Z(),e(document).delegate(".wc_email","keyup",function(){Z(e(this))}),j){if(e("#wpd-bubble-wrapper").hover(function(){e(this).addClass("wpd-bubble-hover")},function(){e(this).removeClass("wpd-bubble-hover")}),k&&!Cookies.get(wpdiscuzAjaxObj.cookieHideBubbleHint)&&setTimeout(function(){e("#wpd-bubble-wrapper").addClass("wpd-bubble-hover"),Cookies.set(wpdiscuzAjaxObj.cookieHideBubbleHint,"1",{expires:7,path:"/"}),setTimeout(function(){e("#wpd-bubble-wrapper").removeClass("wpd-bubble-hover")},1e3*x)},1e3*k),"content_left"===O)if(e(".entry-content").length){var ee=(te=Math.min(e(".entry-content").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else if(e(".post-entry").length){ee=(te=Math.min(e(".post-entry").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else if(e(".container").length){var te;ee=(te=Math.min(e(".container").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else e("#wpd-bubble-wrapper").css({left:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-corner");else"left_corner"===O?(e("#wpd-bubble-wrapper").css({left:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-corner")):"right_corner"===O&&(e("#wpd-bubble-wrapper").css({right:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-right-corner"));e("#wpd-bubble-wrapper").show(),e("#wpd-bubble-add-message-close").click(function(t){t.preventDefault(),t.stopPropagation(),e("#wpd-bubble-wrapper").removeClass("wpd-bubble-hover")}),e("#wpd-bubble").click(function(){e("html, body").animate({scrollTop:e("#wpdcom").offset().top-60},1e3,function(){wpdiscuzLoadRichEditor?wpDiscuzEditor.createEditor("#wpd-editor-0_0").focus():e("#wc-textarea-0_0").focus()})}),e("#wpd-bubble-comment-close").click(function(t){t.preventDefault(),e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added")}),e("#wpd-bubble-comment-reply-link a").click(function(){var t=e(this).attr("href");setTimeout(function(){e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added"),P(!0);var a=t.match(/#comment\-(\d+)/);D=D.filter(function(e){return e!=a[1]}),e("#wpd-bubble-count .wpd-new-comments-count").text(D.length),0==D.length&&e("#wpd-bubble-count").removeClass("wpd-new-comments")},100)}),e("#wpd-bubble-count").click(function(){if(D.length){var t=new FormData;t.append("action","wpdBubbleUpdate"),t.append("newCommentIds",D.join()),ce(z,!0,t).done(function(t){"object"==typeof t&&t.success&&(t.data.message=t.data.message.filter(function(t){if(!e("#comment-"+t.comment_id).length)return t}),Q(t),e("#wpd-bubble-count").removeClass("wpd-new-comments"),e("#wpd-bubble-count .wpd-new-comments-count").text("0"),D=[],e("html, body").animate({scrollTop:e(e(".wpd-new-loaded-comment")[0]).offset().top-60},1e3),ie(t)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(e,t,a){console.log(a)})}})}if((j&&C||i)&&(t||!t&&p)&&setTimeout(function t(){e.ajax({type:"GET",url:wpdiscuzAjaxObj.bubbleUpdateUrl,data:{postId:s,lastId:l,visibleCommentIds:Y()}}).done(function(a){if(!E)if("object"==typeof a){if(a.ids.length){i&&((n=new FormData).append("action","wpdUpdateAutomatically"),n.append("loadLastCommentId",r),n.append("visibleCommentIds",Y()),ce(z,!1,n).done(function(t){E||"object"==typeof t&&t.success&&(Q(t),e(".wpd-thread-info").html(t.data.wc_all_comments_count_new_html),t.data.wc_all_comments_count_new=parseInt(t.data.wc_all_comments_count_new),e("#wpd-bubble-all-comments-count").text(t.data.wc_all_comments_count_new),t.data.wc_all_comments_count_new?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),r=t.data.loadLastCommentId)}).fail(function(e,t,a){console.log(a)})),a.ids=a.ids.filter(function(t){if(!e("#comment-"+t).length)return t});var o=5e3;l=parseInt(a.ids[a.ids.length-1]),D=D.concat(a.ids),y&&a.commentText&&(e("#wpd-bubble-author-avatar").html(a.avatar),e("#wpd-bubble-author-name").html(a.authorName),e("#wpd-bubble-comment-date span").html(a.commentDate),e("#wpd-bubble-comment-text").html(a.commentText),e("#wpd-bubble-comment-reply-link a").attr("href",a.commentLink),e("#wpd-bubble-notification-message").show(),o=1e4);var d=parseInt(e(".wpd-new-comments-count").text());d+=a.ids.length,e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added"),e("#wpd-bubble-wrapper").addClass("wpd-new-comment-added"),setTimeout(function(){e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added")},o),e(".wpd-new-comments-count").text(d),e("#wpd-bubble-count").addClass("wpd-new-comments"),a.all_comments_count=parseInt(a.all_comments_count),e("#wpd-bubble-all-comments-count").text(a.all_comments_count),a.all_comments_count?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),e(".wpd-thread-info").html(a.all_comments_count_html)}}else console.log(a);var n;setTimeout(t,c)}).fail(function(e,a,o){console.log(o),setTimeout(t,c)})},c),e(".wpd-inline-form-wrapper").length){var ae=new FormData;ae.append("action","wpdGetInlineCommentForm"),ce(z,!1,ae).done(function(t){"object"==typeof t?t.success?(e(".wpd-inline-form-wrapper").append(t.data),e.each(e("[name=_wpd_inline_nonce]"),function(){var t=e(this).attr("id"),a=e(this).parents(".wpd-inline-shortcode").attr("id");e(this).attr("id",t+"-"+a.substring(a.lastIndexOf("-")+1))}),e(".wpd-inline-opened").addClass("wpd-active"),e(".wpd-inline-opened").find(".wpd-inline-form-wrapper").show(),e(".wpd-inline-opened").find(".wpd-inline-icon").addClass("wpd-open"),e(".wpd-inline-opened").find(".wpd-inline-icon").removeClass("wpd-ignored"),se()):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error"):console.log(t)}).fail(function(e,t,a){console.log(a)})}function oe(t){if(e(t).hasClass("wpd-inline-shortcode"))var a=e(t).attr("id");else a=e(t).parents(".wpd-inline-shortcode").attr("id");return a.substring(a.lastIndexOf("-")+1)}function de(){e(".wpd-inline-form-wrapper").hide(),e(".wpd-inline-shortcode").removeClass("wpd-active"),e(".wpd-inline-icon").removeClass("wpd-open")}function ne(){e.each(e(".wpd-inline-shortcode:not(.wpd-inline-opened) .wpd-inline-icon"),function(){var t=e(this),a=t.offset().top-window.pageYOffset;a>0&&a<300&&("blink"===A?(t.addClass("wpd-blink"),setTimeout(function(){t.removeClass("wpd-blink")},3e3)):(t.parents(".wpd-inline-shortcode").addClass("wpd-active"),t.siblings(".wpd-inline-form-wrapper").show(),t.addClass("wpd-open"),se(t.siblings(".wpd-inline-form-wrapper"))))})}function se(t){if(t){if(t.offset().left<=10)t.css("left",Math.ceil(parseInt(t.css("left"))-t.offset().left+10)),(a=Math.ceil(t.siblings(".wpd-inline-icon.wpd-open").offset().left-t.offset().left+2))<3&&(a=3),document.styleSheets[0].addRule("#"+t.parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+a+"px;");else if(t.offset().left+t.width()>document.body.clientWidth-10){var a;t.css("left",Math.ceil(parseInt(t.css("left"))+(document.body.clientWidth-(t.offset().left+t.width()))-10)),(a=Math.ceil(t.siblings(".wpd-inline-icon.wpd-open").offset().left-t.offset().left+2))>t.width()-3&&(a=t.width()-3),document.styleSheets[0].addRule("#"+t.parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+a+"px;")}}else e.each(e(".wpd-inline-form-wrapper:visible"),function(){if(e(this).offset().left<=10)e(this).css("left",Math.ceil(parseInt(e(this).css("left"))-e(this).offset().left+10)),(t=Math.ceil(e(this).siblings(".wpd-inline-icon.wpd-open").offset().left-e(this).offset().left+2))<3&&(t=3),document.styleSheets[0].addRule("#"+e(this).parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+t+"px;");else if(e(this).offset().left+e(this).width()>document.body.clientWidth-10){var t;e(this).css("left",Math.ceil(parseInt(e(this).css("left"))+(document.body.clientWidth-(e(this).offset().left+e(this).width()))-10)),(t=Math.ceil(e(this).siblings(".wpd-inline-icon.wpd-open").offset().left-e(this).offset().left+2))>e(this).width()-3&&(t=e(this).width()-3),document.styleSheets[0].addRule("#"+e(this).parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+t+"px;")}})}function ie(t,a,o,d){t.data.callbackFunctions&&e.each(t.data.callbackFunctions,function(e){"function"==typeof wpdiscuzAjaxObj[t.data.callbackFunctions[e]]?wpdiscuzAjaxObj[t.data.callbackFunctions[e]](t,a,o,d):console.log(t.data.callbackFunctions[e]+" is not a function")})}function ce(t,a,o){a&&e("#wpdiscuz-loading-bar").show(),o.append("postId",s);var d=o.get("action");wpdiscuzAjaxObj.dataFilterCallbacks&&wpdiscuzAjaxObj.dataFilterCallbacks[d]&&e.each(wpdiscuzAjaxObj.dataFilterCallbacks[d],function(e){"function"==typeof wpdiscuzAjaxObj[wpdiscuzAjaxObj.dataFilterCallbacks[d][e]]&&(o=wpdiscuzAjaxObj[wpdiscuzAjaxObj.dataFilterCallbacks[d][e]](o,t,a))});var n=t?wpdiscuzAjaxObj.url:wpdiscuzAjaxObj.customAjaxUrl;return e.ajax({type:"POST",url:n,data:o,contentType:!1,processData:!1})}e(document).delegate("body","click",function(t){if(e(t.target).hasClass("wpd-inline-form-close")||e(t.target).parents(".wpd-inline-form-close").length)t.preventDefault(),e(t.target).parents(".wpd-inline-form-wrapper").hide(),e(t.target).parents(".wpd-inline-shortcode").removeClass("wpd-active"),e(t.target).parents(".wpd-inline-form-wrapper").siblings(".wpd-inline-icon").removeClass("wpd-open");else if(!e(t.target).hasClass("wpd-inline-form-wrapper")&&!e(t.target).parents(".wpd-inline-form-wrapper").length){de();var a="";e(t.target).hasClass("wpd-inline-icon")?a=e(t.target):e(t.target).parents(".wpd-inline-icon").length&&(a=e(t.target).parents(".wpd-inline-icon")),a.length&&(a.parents(".wpd-inline-shortcode").addClass("wpd-active"),a.siblings(".wpd-inline-form-wrapper").show(),a.addClass("wpd-open"),a.removeClass("wpd-ignored"),se(a.siblings(".wpd-inline-form-wrapper")))}(!e(t.target).hasClass("wpd-last-inline-comments-wrapper")&&!e(t.target).parents(".wpd-last-inline-comments-wrapper").length||e(t.target).parents(".wpd-last-inline-comments-wrapper").length&&e(t.target).hasClass("wpd-load-inline-comment"))&&e(".wpd-last-inline-comments-wrapper").remove()}),e(document).delegate(".wpd-inline-submit.wpd_not_clicked","click",function(t){t.preventDefault();var a=e(this),o=e(this).parents(".wpd_inline_comm_form");if(o[0].checkValidity()){e(this).removeClass("wpd_not_clicked");var d=new FormData;d.append("action","wpdAddInlineComment"),d.append("inline_form_id",oe(o)),e.each(e("input, textarea",o),function(t,a){"checkbox"===this.type?e(this).is(":checked")&&d.append(e(a).attr("name"),e(a).val()):d.append(e(a).attr("name"),e(a).val())}),ce(z,!0,d).done(function(t){if(a.addClass("wpd_not_clicked"),"object"==typeof t)if(t.success){o[0].reset(),de();var d=parseInt(t.data.newCount),n=a.parents(".wpd-inline-icon-wrapper").find(".wpd-inline-icon-count");n.text(d),d?n.addClass("wpd-has-comments"):n.removeClass("wpd-has-comments"),e(".wpd-thread-info").html(t.data.allCommentsCountNewHtml),t.data.allCommentsCountNew=parseInt(t.data.allCommentsCountNew),e("#wpd-bubble-all-comments-count").text(t.data.allCommentsCountNew),t.data.allCommentsCountNew?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),t.data.message&&X(t.data.message),wpdiscuzAjaxObj.setCommentMessage(t.data.notification,"success")}else t.data&&wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error");else wpdiscuzAjaxObj.setCommentMessage(t,"error");e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(document).delegate(".wpd-form","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).find(".wc_comm_submit").trigger("click")}),e(document).delegate("#wpdiscuz-edit-form","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).find(".wc_save_edited_comment").trigger("click")}),e(document).delegate(".wpd-inline-comment-content","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).parents(".wpd_inline_comm_form").find(".wpd-inline-submit.wpd_not_clicked").trigger("click")}),e(document).delegate(".wpd-inline-icon-count.wpd-has-comments","click",function(){var t=e(this),a=new FormData;a.append("action","wpdGetLastInlineComments"),a.append("inline_form_id",oe(t)),ce(z,!0,a).done(function(a){"object"==typeof a?a.success?e(a.data).insertAfter(t):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"):console.log(a),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-view-all-inline-comments","click",function(t){t.preventDefault(),e(this).parents(".wpd-last-inline-comments-wrapper").remove(),e(".wpdf-inline").hasClass("wpdf-active")||e(".wpdf-inline").trigger("click"),e("html, body").animate({scrollTop:e(".wpdf-inline").offset().top-32},1e3)}),e(document).delegate(".wpd-feedback-content-link","click",function(t){t.preventDefault();var a=e(this).data("feedback-content-id");e("html, body").animate({scrollTop:e("#wpd-inline-"+a).offset().top-38},1e3,function(){e("#wpd-inline-"+a).addClass("wpd-active")})}),"scroll_open"!==A&&"blink"!==A||(ne(),e(window).scroll(ne)),e(document).delegate("#wpd-post-rating.wpd-not-rated .wpd-rate-starts svg","click",function(){var t=new FormData,a=e(this).index();a>=0&&a<5&&(t.append("action","wpdUserRate"),t.append("rating",a+1),ce(z,!0,t).done(function(t){"object"==typeof t?t.success?location.reload(!0):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error"):console.log(t),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}))}),e("#wpdiscuz-subscribe-form").submit(function(t){t.preventDefault();var a,o,n=e(this);if(n[0].checkValidity()&&(a=n,o=!0,"2.0"===d&&e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).length&&!e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).val().length?(o=!1,e(".wpdiscuz-recaptcha",a).css("border","1px solid red")):"2.0"===d&&e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).length&&e(".wpdiscuz-recaptcha",a).css("border","none"),o)){var s=new FormData;s.append("action","wpdAddSubscription"),e("*",n).each(function(){""!=this.name&&"checkbox"!=this.type&&"radio"!=this.type&&s.append(this.name+"",e(this).val()),"checkbox"!=this.type&&"radio"!=this.type||e(this).is(":checked")&&s.append(this.name+"",e(this).val())}),ce(z,!0,s).done(function(t){"object"==typeof t?t.success?(wpdiscuzAjaxObj.setCommentMessage(t.data,"success"),setTimeout(function(){location.reload(!0)},3e3)):wpdiscuzAjaxObj.setCommentMessage(t.data,"error"):wpdiscuzAjaxObj.setCommentMessage(t,"error"),e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(".wpd-unsubscribe").click(function(t){t.preventDefault();var a=new FormData;a.append("action","wpdUnsubscribe"),a.append("sid",e(this).data("sid")),a.append("skey",e(this).data("skey")),ce(z,!0,a).done(function(t){"object"==typeof t?t.success?(wpdiscuzAjaxObj.setCommentMessage(t.data,"success"),setTimeout(function(){location.reload(!0)},3e3)):wpdiscuzAjaxObj.setCommentMessage(t.data,"error"):console.log(t),e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),wpdiscuzAjaxObj.resetActiveFilters=function(t){e(".wpd-filter.wpdf-active"+(t?":not("+t+")":"")).removeClass("wpdf-active")},wpdiscuzAjaxObj.getAjaxObj=ce});var onloadCallback=function(){if(document.getElementById("wpdiscuz-recaptcha-0_0")&&"2.0"===wpdiscuzAjaxObj.wpDiscuzReCaptchaVersion&&(1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!wpdiscuzAjaxObj.is_user_logged_in||1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&wpdiscuzAjaxObj.is_user_logged_in))try{grecaptcha.render("wpdiscuz-recaptcha-0_0",{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(e){jQuery("#wpdiscuz-recaptcha-field-0_0").val("key")},"expired-callback":function(){jQuery("#wpdiscuz-recaptcha-field-0_0").val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}};
11
  /* Colorbox */
12
  (function(t,e,i){function n(i,n,o){var r=e.createElement(i);return n&&(r.id=Z+n),o&&(r.style.cssText=o),t(r)}function o(){return i.innerHeight?i.innerHeight:t(i).height()}function r(e,i){i!==Object(i)&&(i={}),this.cache={},this.el=e,this.value=function(e){var n;return void 0===this.cache[e]&&(n=t(this.el).attr("data-cbox-"+e),void 0!==n?this.cache[e]=n:void 0!==i[e]?this.cache[e]=i[e]:void 0!==X[e]&&(this.cache[e]=X[e])),this.cache[e]},this.get=function(e){var i=this.value(e);return t.isFunction(i)?i.call(this.el,this):i}}function h(t){var e=W.length,i=(A+t)%e;return 0>i?e+i:i}function a(t,e){return Math.round((/%/.test(t)?("x"===e?E.width():o())/100:1)*parseInt(t,10))}function s(t,e){return t.get("photo")||t.get("photoRegex").test(e)}function l(t,e){return t.get("retinaUrl")&&i.devicePixelRatio>1?e.replace(t.get("photoRegex"),t.get("retinaSuffix")):e}function d(t){"contains"in x[0]&&!x[0].contains(t.target)&&t.target!==v[0]&&(t.stopPropagation(),x.focus())}function c(t){c.str!==t&&(x.add(v).removeClass(c.str).addClass(t),c.str=t)}function g(e){A=0,e&&e!==!1&&"nofollow"!==e?(W=t("."+te).filter(function(){var i=t.data(this,Y),n=new r(this,i);return n.get("rel")===e}),A=W.index(_.el),-1===A&&(W=W.add(_.el),A=W.length-1)):W=t(_.el)}function u(i){t(e).trigger(i),ae.triggerHandler(i)}function f(i){var o;if(!G){if(o=t(i).data(Y),_=new r(i,o),g(_.get("rel")),!U){U=$=!0,c(_.get("className")),x.css({visibility:"hidden",display:"block",opacity:""}),I=n(se,"LoadedContent","width:0; height:0; overflow:hidden; visibility:hidden"),b.css({width:"",height:""}).append(I),j=T.height()+k.height()+b.outerHeight(!0)-b.height(),D=C.width()+H.width()+b.outerWidth(!0)-b.width(),N=I.outerHeight(!0),z=I.outerWidth(!0);var h=a(_.get("initialWidth"),"x"),s=a(_.get("initialHeight"),"y"),l=_.get("maxWidth"),f=_.get("maxHeight");_.w=Math.max((l!==!1?Math.min(h,a(l,"x")):h)-z-D,0),_.h=Math.max((f!==!1?Math.min(s,a(f,"y")):s)-N-j,0),I.css({width:"",height:_.h}),J.position(),u(ee),_.get("onOpen"),O.add(F).hide(),x.focus(),_.get("trapFocus")&&e.addEventListener&&(e.addEventListener("focus",d,!0),ae.one(re,function(){e.removeEventListener("focus",d,!0)})),_.get("returnFocus")&&ae.one(re,function(){t(_.el).focus()})}var p=parseFloat(_.get("opacity"));v.css({opacity:p===p?p:"",cursor:_.get("overlayClose")?"pointer":"",visibility:"visible"}).show(),_.get("closeButton")?B.html(_.get("close")).appendTo(b):B.appendTo("<div/>"),w()}}function p(){x||(V=!1,E=t(i),x=n(se).attr({id:Y,"class":t.support.opacity===!1?Z+"IE":"",role:"dialog",tabindex:"-1"}).hide(),v=n(se,"Overlay").hide(),L=t([n(se,"LoadingOverlay")[0],n(se,"LoadingGraphic")[0]]),y=n(se,"Wrapper"),b=n(se,"Content").append(F=n(se,"Title"),R=n(se,"Current"),P=t('<button type="button"/>').attr({id:Z+"Previous"}),K=t('<button type="button"/>').attr({id:Z+"Next"}),S=t('<button type="button"/>').attr({id:Z+"Slideshow"}),L),B=t('<button type="button"/>').attr({id:Z+"Close"}),y.append(n(se).append(n(se,"TopLeft"),T=n(se,"TopCenter"),n(se,"TopRight")),n(se,!1,"clear:left").append(C=n(se,"MiddleLeft"),b,H=n(se,"MiddleRight")),n(se,!1,"clear:left").append(n(se,"BottomLeft"),k=n(se,"BottomCenter"),n(se,"BottomRight"))).find("div div").css({"float":"left"}),M=n(se,!1,"position:absolute; width:9999px; visibility:hidden; display:none; max-width:none;"),O=K.add(P).add(R).add(S)),e.body&&!x.parent().length&&t(e.body).append(v,x.append(y,M))}function m(){function i(t){t.which>1||t.shiftKey||t.altKey||t.metaKey||t.ctrlKey||(t.preventDefault(),f(this))}return x?(V||(V=!0,K.click(function(){J.next()}),P.click(function(){J.prev()}),B.click(function(){J.close()}),v.click(function(){_.get("overlayClose")&&J.close()}),t(e).bind("keydown."+Z,function(t){var e=t.keyCode;U&&_.get("escKey")&&27===e&&(t.preventDefault(),J.close()),U&&_.get("arrowKey")&&W[1]&&!t.altKey&&(37===e?(t.preventDefault(),P.click()):39===e&&(t.preventDefault(),K.click()))}),t.isFunction(t.fn.on)?t(e).on("click."+Z,"."+te,i):t("."+te).live("click."+Z,i)),!0):!1}function w(){var e,o,r,h=J.prep,d=++le;if($=!0,q=!1,u(he),u(ie),_.get("onLoad"),_.h=_.get("height")?a(_.get("height"),"y")-N-j:_.get("innerHeight")&&a(_.get("innerHeight"),"y"),_.w=_.get("width")?a(_.get("width"),"x")-z-D:_.get("innerWidth")&&a(_.get("innerWidth"),"x"),_.mw=_.w,_.mh=_.h,_.get("maxWidth")&&(_.mw=a(_.get("maxWidth"),"x")-z-D,_.mw=_.w&&_.w<_.mw?_.w:_.mw),_.get("maxHeight")&&(_.mh=a(_.get("maxHeight"),"y")-N-j,_.mh=_.h&&_.h<_.mh?_.h:_.mh),e=_.get("href"),Q=setTimeout(function(){L.show()},100),_.get("inline")){var c=t(e).eq(0);r=t("<div>").hide().insertBefore(c),ae.one(he,function(){r.replaceWith(c)}),h(c)}else _.get("iframe")?h(" "):_.get("html")?h(_.get("html")):s(_,e)?(e=l(_,e),q=_.get("createImg"),t(q).addClass(Z+"Photo").bind("error."+Z,function(){h(n(se,"Error").html(_.get("imgError")))}).one("load",function(){d===le&&setTimeout(function(){var e;_.get("retinaImage")&&i.devicePixelRatio>1&&(q.height=q.height/i.devicePixelRatio,q.width=q.width/i.devicePixelRatio),_.get("scalePhotos")&&(o=function(){q.height-=q.height*e,q.width-=q.width*e},_.mw&&q.width>_.mw&&(e=(q.width-_.mw)/q.width,o()),_.mh&&q.height>_.mh&&(e=(q.height-_.mh)/q.height,o())),_.h&&(q.style.marginTop=Math.max(_.mh-q.height,0)/2+"px"),W[1]&&(_.get("loop")||W[A+1])&&(q.style.cursor="pointer",t(q).bind("click."+Z,function(){J.next()})),q.style.width=q.width+"px",q.style.height=q.height+"px",h(q)},1)}),q.src=e):e&&M.load(e,_.get("data"),function(e,i){d===le&&h("error"===i?n(se,"Error").html(_.get("xhrError")):t(this).contents())})}var v,x,y,b,T,C,H,k,W,E,I,M,L,F,R,S,K,P,B,O,_,j,D,N,z,A,q,U,$,G,Q,J,V,X={html:!1,photo:!1,iframe:!1,inline:!1,transition:"elastic",speed:300,fadeOut:300,width:!1,initialWidth:"600",innerWidth:!1,maxWidth:!1,height:!1,initialHeight:"450",innerHeight:!1,maxHeight:!1,scalePhotos:!0,scrolling:!0,opacity:.9,preloading:!0,className:!1,overlayClose:!0,escKey:!0,arrowKey:!0,top:!1,bottom:!1,left:!1,right:!1,fixed:!1,data:void 0,closeButton:!0,fastIframe:!0,open:!1,reposition:!0,loop:!0,slideshow:!1,slideshowAuto:!0,slideshowSpeed:2500,slideshowStart:"start slideshow",slideshowStop:"stop slideshow",photoRegex:/\.(gif|png|jp(e|g|eg)|bmp|ico|webp|jxr|svg)((#|\?).*)?$/i,retinaImage:!1,retinaUrl:!1,retinaSuffix:"@2x.$1",current:"image {current} of {total}",previous:"previous",next:"next",close:"close",xhrError:"This content failed to load.",imgError:"This image failed to load.",returnFocus:!0,trapFocus:!0,onOpen:!1,onLoad:!1,onComplete:!1,onCleanup:!1,onClosed:!1,rel:function(){return this.rel},href:function(){return t(this).attr("href")},title:function(){return this.title},createImg:function(){var e=new Image,i=t(this).data("cbox-img-attrs");return"object"==typeof i&&t.each(i,function(t,i){e[t]=i}),e},createIframe:function(){var i=e.createElement("iframe"),n=t(this).data("cbox-iframe-attrs");return"object"==typeof n&&t.each(n,function(t,e){i[t]=e}),"frameBorder"in i&&(i.frameBorder=0),"allowTransparency"in i&&(i.allowTransparency="true"),i.name=(new Date).getTime(),i.allowFullscreen=!0,i}},Y="colorbox",Z="cbox",te=Z+"Element",ee=Z+"_open",ie=Z+"_load",ne=Z+"_complete",oe=Z+"_cleanup",re=Z+"_closed",he=Z+"_purge",ae=t("<a/>"),se="div",le=0,de={},ce=function(){function t(){clearTimeout(h)}function e(){(_.get("loop")||W[A+1])&&(t(),h=setTimeout(J.next,_.get("slideshowSpeed")))}function i(){S.html(_.get("slideshowStop")).unbind(s).one(s,n),ae.bind(ne,e).bind(ie,t),x.removeClass(a+"off").addClass(a+"on")}function n(){t(),ae.unbind(ne,e).unbind(ie,t),S.html(_.get("slideshowStart")).unbind(s).one(s,function(){J.next(),i()}),x.removeClass(a+"on").addClass(a+"off")}function o(){r=!1,S.hide(),t(),ae.unbind(ne,e).unbind(ie,t),x.removeClass(a+"off "+a+"on")}var r,h,a=Z+"Slideshow_",s="click."+Z;return function(){r?_.get("slideshow")||(ae.unbind(oe,o),o()):_.get("slideshow")&&W[1]&&(r=!0,ae.one(oe,o),_.get("slideshowAuto")?i():n(),S.show())}}();t[Y]||(t(p),J=t.fn[Y]=t[Y]=function(e,i){var n,o=this;return e=e||{},t.isFunction(o)&&(o=t("<a/>"),e.open=!0),o[0]?(p(),m()&&(i&&(e.onComplete=i),o.each(function(){var i=t.data(this,Y)||{};t.data(this,Y,t.extend(i,e))}).addClass(te),n=new r(o[0],e),n.get("open")&&f(o[0])),o):o},J.position=function(e,i){function n(){T[0].style.width=k[0].style.width=b[0].style.width=parseInt(x[0].style.width,10)-D+"px",b[0].style.height=C[0].style.height=H[0].style.height=parseInt(x[0].style.height,10)-j+"px"}var r,h,s,l=0,d=0,c=x.offset();if(E.unbind("resize."+Z),x.css({top:-9e4,left:-9e4}),h=E.scrollTop(),s=E.scrollLeft(),_.get("fixed")?(c.top-=h,c.left-=s,x.css({position:"fixed"})):(l=h,d=s,x.css({position:"absolute"})),d+=_.get("right")!==!1?Math.max(E.width()-_.w-z-D-a(_.get("right"),"x"),0):_.get("left")!==!1?a(_.get("left"),"x"):Math.round(Math.max(E.width()-_.w-z-D,0)/2),l+=_.get("bottom")!==!1?Math.max(o()-_.h-N-j-a(_.get("bottom"),"y"),0):_.get("top")!==!1?a(_.get("top"),"y"):Math.round(Math.max(o()-_.h-N-j,0)/2),x.css({top:c.top,left:c.left,visibility:"visible"}),y[0].style.width=y[0].style.height="9999px",r={width:_.w+z+D,height:_.h+N+j,top:l,left:d},e){var g=0;t.each(r,function(t){return r[t]!==de[t]?(g=e,void 0):void 0}),e=g}de=r,e||x.css(r),x.dequeue().animate(r,{duration:e||0,complete:function(){n(),$=!1,y[0].style.width=_.w+z+D+"px",y[0].style.height=_.h+N+j+"px",_.get("reposition")&&setTimeout(function(){E.bind("resize."+Z,J.position)},1),t.isFunction(i)&&i()},step:n})},J.resize=function(t){var e;U&&(t=t||{},t.width&&(_.w=a(t.width,"x")-z-D),t.innerWidth&&(_.w=a(t.innerWidth,"x")),I.css({width:_.w}),t.height&&(_.h=a(t.height,"y")-N-j),t.innerHeight&&(_.h=a(t.innerHeight,"y")),t.innerHeight||t.height||(e=I.scrollTop(),I.css({height:"auto"}),_.h=I.height()),I.css({height:_.h}),e&&I.scrollTop(e),J.position("none"===_.get("transition")?0:_.get("speed")))},J.prep=function(i){function o(){return _.w=_.w||I.width(),_.w=_.mw&&_.mw<_.w?_.mw:_.w,_.w}function a(){return _.h=_.h||I.height(),_.h=_.mh&&_.mh<_.h?_.mh:_.h,_.h}if(U){var d,g="none"===_.get("transition")?0:_.get("speed");I.remove(),I=n(se,"LoadedContent").append(i),I.hide().appendTo(M.show()).css({width:o(),overflow:_.get("scrolling")?"auto":"hidden"}).css({height:a()}).prependTo(b),M.hide(),t(q).css({"float":"none"}),c(_.get("className")),d=function(){function i(){t.support.opacity===!1&&x[0].style.removeAttribute("filter")}var n,o,a=W.length;U&&(o=function(){clearTimeout(Q),L.hide(),u(ne),_.get("onComplete")},F.html(_.get("title")).show(),I.show(),a>1?("string"==typeof _.get("current")&&R.html(_.get("current").replace("{current}",A+1).replace("{total}",a)).show(),K[_.get("loop")||a-1>A?"show":"hide"]().html(_.get("next")),P[_.get("loop")||A?"show":"hide"]().html(_.get("previous")),ce(),_.get("preloading")&&t.each([h(-1),h(1)],function(){var i,n=W[this],o=new r(n,t.data(n,Y)),h=o.get("href");h&&s(o,h)&&(h=l(o,h),i=e.createElement("img"),i.src=h)})):O.hide(),_.get("iframe")?(n=_.get("createIframe"),_.get("scrolling")||(n.scrolling="no"),t(n).attr({src:_.get("href"),"class":Z+"Iframe"}).one("load",o).appendTo(I),ae.one(he,function(){n.src="//about:blank"}),_.get("fastIframe")&&t(n).trigger("load")):o(),"fade"===_.get("transition")?x.fadeTo(g,1,i):i())},"fade"===_.get("transition")?x.fadeTo(g,0,function(){J.position(0,d)}):J.position(g,d)}},J.next=function(){!$&&W[1]&&(_.get("loop")||W[A+1])&&(A=h(1),f(W[A]))},J.prev=function(){!$&&W[1]&&(_.get("loop")||A)&&(A=h(-1),f(W[A]))},J.close=function(){U&&!G&&(G=!0,U=!1,u(oe),_.get("onCleanup"),E.unbind("."+Z),v.fadeTo(_.get("fadeOut")||0,0),x.stop().fadeTo(_.get("fadeOut")||0,0,function(){x.hide(),v.hide(),u(he),I.remove(),setTimeout(function(){G=!1,u(re),_.get("onClosed")},1)}))},J.remove=function(){x&&(x.stop(),t[Y].close(),x.stop(!1,!0).remove(),v.remove(),G=!1,x=null,t("."+te).removeData(Y).removeClass(te),t(e).unbind("click."+Z).unbind("keydown."+Z))},J.element=function(){return t(_.el)},J.settings=X)})(jQuery,document,window);
13
  /* Media Uploader */
assets/js/wpdiscuz.js CHANGED
@@ -142,6 +142,7 @@ jQuery(document).ready(function ($) {
142
  editor.deleteText(0, editor.getLength(), Quill.sources.USER);
143
  var html = $('#wpd-editor-source-code').val();
144
  if (html.length) {
 
145
  editor.clipboard.dangerouslyPasteHTML(0, html, Quill.sources.USER);
146
  }
147
  editor.update();
@@ -608,10 +609,14 @@ jQuery(document).ready(function ($) {
608
  .done(function (r) {
609
  if (typeof r === 'object') {
610
  if (r.success) {
611
- $('#wpd-comm-' + uniqueID + ' > .wpd-comment-wrap .wpd-comment-right .wpd-comment-text').replaceWith(r.data);
612
  if (wpdiscuzLoadRichEditor) {
613
- wpDiscuzEditor.createEditor('#wpd-editor-edit_' + uniqueID);
 
 
614
  $('.wpd-toolbar-hidden').prev('[id^=wpd-editor-]').css('border-bottom', "1px solid #dddddd");
 
 
615
  }
616
  $('#wpd-comm-' + uniqueID + ' > .wpd-comment-wrap .wpd-comment-right .wpd_editable_comment').hide();
617
  $('#wpd-comm-' + uniqueID + ' > .wpd-comment-wrap .wpd-comment-last-edited').hide();
@@ -1190,7 +1195,7 @@ jQuery(document).ready(function ($) {
1190
  function wpdSanitizeCommentText(form) {
1191
  var textarea = form.find('.wc_comment');
1192
  var commentText = textarea.val().trim();
1193
- var replacedText = commentText;
1194
  replacedText = replacedText.replace(/<img src=["|']https\:\/\/s\.w\.org\/images\/core\/emoji\/([^"|']+)["|'](.*?)alt=["|']([^"|']+)["|'](.*?)[^>]*>/g, "$3");
1195
  replacedText = replacedText.replace(/<img[^>]+alt=["|']([^"|']+)["|'][^>]+src=["|']https\:\/\/s\.w\.org\/images\/core\/emoji\/([^"|']+)["|'][^>]?>/g, "$1");
1196
  replacedText = replacedText.replace(/<img\s+([^>]*)class=["|']wpdem\-sticker["|'](.*?)alt=["|']([^"|']+)["|'](.*?)[^>]*>/g, "$3");
142
  editor.deleteText(0, editor.getLength(), Quill.sources.USER);
143
  var html = $('#wpd-editor-source-code').val();
144
  if (html.length) {
145
+ console.log(html);
146
  editor.clipboard.dangerouslyPasteHTML(0, html, Quill.sources.USER);
147
  }
148
  editor.update();
609
  .done(function (r) {
610
  if (typeof r === 'object') {
611
  if (r.success) {
612
+ $('#wpd-comm-' + uniqueID + ' > .wpd-comment-wrap .wpd-comment-right .wpd-comment-text').replaceWith(r.data.html);
613
  if (wpdiscuzLoadRichEditor) {
614
+ let currentEditor = wpDiscuzEditor.createEditor('#wpd-editor-edit_' + uniqueID);
615
+ currentEditor.clipboard.dangerouslyPasteHTML(0, r.data.content);
616
+ currentEditor.update();
617
  $('.wpd-toolbar-hidden').prev('[id^=wpd-editor-]').css('border-bottom', "1px solid #dddddd");
618
+ }else{
619
+ $('#wc-textarea-edit_'+ uniqueID).val(r.data.content);
620
  }
621
  $('#wpd-comm-' + uniqueID + ' > .wpd-comment-wrap .wpd-comment-right .wpd_editable_comment').hide();
622
  $('#wpd-comm-' + uniqueID + ' > .wpd-comment-wrap .wpd-comment-last-edited').hide();
1195
  function wpdSanitizeCommentText(form) {
1196
  var textarea = form.find('.wc_comment');
1197
  var commentText = textarea.val().trim();
1198
+ var replacedText = commentText.replace(/<p><br><\/p>/g, "&nbsp;\n").replace(/<p>(.*?)<\/p>/g, "$1\n");
1199
  replacedText = replacedText.replace(/<img src=["|']https\:\/\/s\.w\.org\/images\/core\/emoji\/([^"|']+)["|'](.*?)alt=["|']([^"|']+)["|'](.*?)[^>]*>/g, "$3");
1200
  replacedText = replacedText.replace(/<img[^>]+alt=["|']([^"|']+)["|'][^>]+src=["|']https\:\/\/s\.w\.org\/images\/core\/emoji\/([^"|']+)["|'][^>]?>/g, "$1");
1201
  replacedText = replacedText.replace(/<img\s+([^>]*)class=["|']wpdem\-sticker["|'](.*?)alt=["|']([^"|']+)["|'](.*?)[^>]*>/g, "$3");
assets/js/wpdiscuz.min.js CHANGED
@@ -1 +1 @@
1
- var wpdiscuzLoadRichEditor=parseInt(wpdiscuzAjaxObj.loadRichEditor);if(wpdiscuzLoadRichEditor)var wpDiscuzEditor=new WpdEditor;function wpdMessagesOnInit(e,t){wpdiscuzAjaxObj.setCommentMessage(e,t),setTimeout(function(){location.href=location.href.substring(0,location.href.indexOf("wpdiscuzUrlAnchor")-1)},3e3)}wpdiscuzAjaxObj.setCommentMessage=function(e,t,a){var o="wpdiscuz-message-error";if("[object Array]"===Object.prototype.toString.call(e))for(var d in e)"[object Array]"===Object.prototype.toString.call(t)?"success"===t[d]?o="wpdiscuz-message-success":"warning"===t[d]&&(o="wpdiscuz-message-warning"):"success"===t?o="wpdiscuz-message-success":"warning"===t&&(o="wpdiscuz-message-warning"),jQuery("<div/>").addClass(o).html(e[d]).prependTo("#wpdiscuz-comment-message").delay("[object Array]"===Object.prototype.toString.call(a)?a[d]:a||4e3).fadeOut(1e3,function(){jQuery(this).remove()});else"success"===t?o="wpdiscuz-message-success":"warning"===t&&(o="wpdiscuz-message-warning"),jQuery("<div/>").addClass(o).html(e).prependTo("#wpdiscuz-comment-message").delay(a||4e3).fadeOut(1e3,function(){jQuery(this).remove()})},jQuery(document).ready(function(e){e("body").addClass("wpdiscuz_"+wpdiscuzAjaxObj.version);var t=wpdiscuzAjaxObj.is_user_logged_in,a=1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!t,o=1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&t,d=wpdiscuzAjaxObj.wpDiscuzReCaptchaVersion,n=parseInt(wpdiscuzAjaxObj.commentListLoadType),i=parseInt(wpdiscuzAjaxObj.wc_post_id),s=parseInt(wpdiscuzAjaxObj.commentListUpdateType),c=1e3*parseInt(wpdiscuzAjaxObj.commentListUpdateTimer),p=parseInt(wpdiscuzAjaxObj.liveUpdateGuests),r=wpdiscuzAjaxObj.loadLastCommentId,l=r,m=parseInt(wpdiscuzAjaxObj.firstLoadWithAjax);Cookies.get("wpdiscuz_comments_sorting")&&Cookies.remove("wpdiscuz_comments_sorting",{path:""}),Cookies.get("wordpress_last_visit")&&Cookies.remove("wordpress_last_visit",{path:""}),Cookies.get("wpdiscuz_last_visit")&&Cookies.remove("wpdiscuz_last_visit",{path:""});var w,u=wpdiscuzAjaxObj.storeCommenterData,f=parseInt(wpdiscuzAjaxObj.wmuEnabled),h=wpdiscuzAjaxObj.isCookiesEnabled,b=!0,g=wpdiscuzAjaxObj.cookiehash,_=parseInt(wpdiscuzAjaxObj.isLoadOnlyParentComments),v=parseInt(wpdiscuzAjaxObj.enableDropAnimation)?500:0,z=parseInt(wpdiscuzAjaxObj.isNativeAjaxEnabled),j=parseInt(wpdiscuzAjaxObj.enableBubble),C=parseInt(wpdiscuzAjaxObj.bubbleLiveUpdate),k=parseInt(wpdiscuzAjaxObj.bubbleHintTimeout),x=parseInt(wpdiscuzAjaxObj.bubbleHintHideTimeout)?parseInt(wpdiscuzAjaxObj.bubbleHintHideTimeout):5,y=parseInt(wpdiscuzAjaxObj.bubbleShowNewCommentMessage),O=wpdiscuzAjaxObj.bubbleLocation,A=wpdiscuzAjaxObj.inlineFeedbackAttractionType,I=[],T=[],D=[],E=!1,M=1;(e(".wc_social_plugin_wrapper .wp-social-login-provider-list").length?e(".wc_social_plugin_wrapper .wp-social-login-provider-list").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .the_champ_login_container").length?e(".wc_social_plugin_wrapper .the_champ_login_container").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .social_connect_form").length?e(".wc_social_plugin_wrapper .social_connect_form").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .oneall_social_login_providers").length&&e(".wc_social_plugin_wrapper .oneall_social_login .oneall_social_login_providers").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"),wpdiscuzLoadRichEditor&&e("#wpd-editor-0_0").length&&wpDiscuzEditor.createEditor("#wpd-editor-0_0"),e(document).delegate("#wpdcom .ql-editor, #wpdcom .wc_comment","focus",function(){e(".wpd-form-foot",e(this).parents(".wpd_comm_form")).slideDown(v)}),e(document).delegate("#wpdcom textarea","focus",function(){e(this).next(".autogrow-textarea-mirror").length||e(this).autoGrow()}),t)||S({comment_author:Cookies.get("comment_author_"+g),comment_author_email:Cookies.get("comment_author_email_"+g),comment_author_url:Cookies.get("comment_author_url_"+g)});if(e(".wpd-vote-down.wpd-dislike-hidden").remove(),e(".wpd-toolbar-hidden").prev("[id^=wpd-editor-]").css("border-bottom","1px solid #dddddd"),e(document).delegate("#wpd-editor-source-code-wrapper-bg","click",function(){e(this).hide(),e("#wpd-editor-source-code-wrapper").hide(),e("#wpd-editor-uid").val(""),e("#wpd-editor-source-code").val("")}),wpdiscuzLoadRichEditor&&e(document).delegate("#wpd-insert-source-code","click",function(){var t=wpDiscuzEditor.createEditor("#"+e("#wpd-editor-uid").val());t.deleteText(0,t.getLength(),Quill.sources.USER);var a=e("#wpd-editor-source-code").val();a.length&&t.clipboard.dangerouslyPasteHTML(0,a,Quill.sources.USER),t.update(),e("#wpd-editor-source-code-wrapper-bg").hide(),e("#wpd-editor-source-code-wrapper").hide(),e("#wpd-editor-uid").val(""),e("#wpd-editor-source-code").val("")}),e(document).delegate(".wpd-reply-button","click",function(){var n=V(e(this),0);e(this).hasClass("wpdiscuz-clonned")?(wpdiscuzLoadRichEditor?setTimeout(function(){wpDiscuzEditor.createEditor("#wpd-editor-"+n).focus()},v):setTimeout(function(){e("#wc-textarea-"+n).trigger("focus")},v),e("#wpd-secondary-form-wrapper-"+n).slideToggle(v)):function(a){var o=V(a,0);e("#wpdiscuz_form_anchor-"+o).before(function(t){return e("#wpdiscuz_hidden_secondary_form").html().replace(/wpdiscuzuniqueid/g,t)}(o));var d=e("#wpd-secondary-form-wrapper-"+o);if(!t){var n={comment_author:Cookies.get("comment_author_"+g),comment_author_email:Cookies.get("comment_author_email_"+g),comment_author_url:Cookies.get("comment_author_url_"+g)};S(n)}wpdiscuzLoadRichEditor?setTimeout(function(){wpDiscuzEditor.createEditor("#wpd-editor-"+o).focus()},v):setTimeout(function(){e("#wc-textarea-"+o).trigger("focus")},v);d.slideToggle(v,function(){a.addClass("wpdiscuz-clonned")})}(e(this)),function(t){if((a||o)&&"2.0"===d){var n=B(t);setTimeout(function(){if(!T[n])try{T[n]=grecaptcha.render("wpdiscuz-recaptcha-"+t,{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(a){e("#wpdiscuz-recaptcha-field-"+t).val("key")},"expired-callback":function(){e("#wpdiscuz-recaptcha-field-"+t).val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}},1e3)}}(n)}),e(document).delegate("#wpdcom .wpd-comment-link [data-comment-url]","click",function(){var t=e(this).data("comment-url"),a=e("<input/>");a.appendTo("body").css({position:"absolute",top:"-10000000px"}).val(t),a.select(),document.execCommand("copy"),a.remove(),wpdiscuzAjaxObj.setCommentMessage(t+"<br/>"+wpdiscuzAjaxObj.wc_copied_to_clipboard,"success",5e3)}),e(document).delegate(".wpdiscuz-nofollow,.wc_captcha_refresh_img,.wpd-load-more-submit","click",function(e){e.preventDefault()}),e(document).delegate(".wpd-toggle.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked");var a=V(e(this),0),o=e(this),d=e(".fas",o);!o.parents(".wpd-comment:not(.wpd-reply)").children(".wpd-reply").length&&_?function(t,a){var o=B(t),d=new FormData;d.append("action","wpdShowReplies"),d.append("commentId",o),ce(z,!0,d).done(function(o){a.addClass("wpd_not_clicked"),"object"==typeof o&&o.success&&(e("#wpd-comm-"+t).replaceWith(o.data.comment_list),e("#wpd-comm-"+t+" .wpd-toggle .fas").removeClass("fa-chevron-down").addClass("fa-chevron-up"),e("#wpd-comm-"+t+" .wpd-toggle").attr("wpd-tooltip",wpdiscuzAjaxObj.wc_hide_replies_text),e("#wpd-comm-"+t+" .wpd-toggle .wpd-view-replies").remove(),se(o)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,o,d){console.log(d),a.addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}(a,t):e("#wpd-comm-"+a+"> .wpd-reply").slideToggle(700,function(){e(this).is(":hidden")?(d.removeClass("fa-chevron-up"),d.addClass("fa-chevron-down"),o.attr("wpd-tooltip",wpdiscuzAjaxObj.wc_show_replies_text)):(d.removeClass("fa-chevron-down"),d.addClass("fa-chevron-up"),o.attr("wpd-tooltip",wpdiscuzAjaxObj.wc_hide_replies_text)),t.addClass("wpd_not_clicked")})}),e(document).delegate(".wpd-new-loaded-comment","mouseenter",function(){e(this).removeClass("wpd-new-loaded-comment")}),e(document).delegate(".wpd-sbs-toggle","click",function(){e(".wpdiscuz-subscribe-bar").slideToggle(v)}),parseInt(wpdiscuzAjaxObj.wpDiscuzIsShowOnSubscribeForm)&&!t&&wpdiscuzAjaxObj.wpDiscuzReCaptchaSK&&("2.0"===d?(setTimeout(function(){try{grecaptcha.render("wpdiscuz-recaptcha-subscribe-form",{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(t){e("#wpdiscuz-recaptcha-field-subscribe-form").val("key")},"expired-callback":function(){e("#wpdiscuz-recaptcha-field-subscribe-form").val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}},1e3),e(document).delegate("#wpdiscuz-subscribe-form","submit",function(t){e("#wpdiscuz-recaptcha-field-subscribe-form").val()?e(".wpdiscuz-recaptcha",e(this)).css("border","none"):(e(".wpdiscuz-recaptcha",e(this)).css("border","1px solid red"),t.preventDefault())})):"3.0"===d&&e(document).delegate("#wpdiscuz_subscription_button","click",function(t){var a=e(this).parents("#wpdiscuz-subscribe-form");t.preventDefault();try{grecaptcha.ready(function(){grecaptcha.execute(wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,{action:"wpdiscuz/wpdAddSubscription"}).then(function(e){console.log(5555),document.getElementById("wpdiscuz-recaptcha-field-subscribe-form").value=e,a.submit()},function(e){wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error","error"),console.log(e)})})}catch(t){console.log(t),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+t.message,"error")}})),(a||o)&&"2.0"===d){var F=e(window).width(),L=e("#wpdcom").width();L>=1100&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"65%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"35%"})),L>=940&&L<1100&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"60%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"40%"})),L>=810&&L<940&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"40%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"60%"})),L>=730&&L<810&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"45%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"55%"})),L>=610&&L<730&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.85)","-webkit-transform":"scale(0.85)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"43%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"55%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"30%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"70%"})),F>650&&(L>=510&&L<610&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"center 0","-webkit-transform-origin":"center 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"35%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"63%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"30%",position:"relative",right:"-60px"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"70%"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"})),L>=470&&L<510&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"center 0","-webkit-transform-origin":"center 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"40%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"60%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd_main_comm_form .wc-form-footer").css({"margin-left":"0px"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"})),L<470&&(e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({margin:"0px auto","transform-origin":"center 0","-webkit-transform-origin":"center 0"}),e("#wpdcom .wpd-form-col-left").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-form-col-right").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"}),e("#wpdcom .wpd-secondary-form-wrapper .wc_notification_checkboxes").css({"text-align":"center"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-field-submit").css({"text-align":"center"})))}function R(t,a,o){ce(z||f,!1,a).done(function(a){if(e(o).addClass("wpd_not_clicked"),"object"==typeof a)if(a.success){"collapsed"===wpdiscuzAjaxObj.commentFormView&&e(".wpd-form-foot",t).slideUp(v),e(".wpd-thread-info").html(a.data.wc_all_comments_count_new_html),a.data.wc_all_comments_count_new=parseInt(a.data.wc_all_comments_count_new),e("#wpd-bubble-all-comments-count").text(a.data.wc_all_comments_count_new),a.data.wc_all_comments_count_new?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide();var d=v;a.data.is_main?X(a.data.message):(d=v+700,e("#wpd-secondary-form-wrapper-"+a.data.uniqueid).slideToggle(700),1==a.data.is_in_same_container?e("#wpd-secondary-form-wrapper-"+a.data.uniqueid).after(a.data.message):e("#wpd-comm-"+a.data.uniqueid).after(a.data.message)),function(e){if(!e.data.held_moderate){var t=new FormData;t.append("action","wpdCheckNotificationType"),t.append("comment_id",e.data.new_comment_id),t.append("email",e.data.comment_author_email),t.append("isParent",e.data.is_main),ce(z,!0,t)}}(a),function(e){if(e.data.redirect>0&&e.data.new_comment_id){var t=new FormData;t.append("action","wpdRedirect"),t.append("commentId",e.data.new_comment_id),ce(z,!0,t).done(function(e){"object"==typeof e&&e.success&&setTimeout(function(){location.href=e.data},2e3)}).fail(function(e,t,a){console.log(a)})}}(a),h&&b?function(t){var a=t.comment_author_email,o=t.comment_author,d=t.comment_author_url;null==u?(Cookies.set("comment_author_email_"+g,a),Cookies.set("comment_author_"+g,o),d.length&&Cookies.set("comment_author_url_"+g,d)):(u=parseInt(u),Cookies.set("comment_author_email_"+g,a,{expires:u,path:"/"}),Cookies.set("comment_author_"+g,o,{expires:u,path:"/"}),d.length&&Cookies.set("comment_author_url_"+g,d,{expires:u,path:"/"}));e(".wpd-cookies-checkbox").length&&e(".wpd-cookies-checkbox").attr("checked","checked")}(a.data):b||e(".wpd-cookies-checkbox").removeAttr("checked"),wpdiscuzLoadRichEditor&&wpDiscuzEditor.createEditor("#wpd-editor-"+e(".wpdiscuz_unique_id",t).val()).setContents([{insert:"\n"}]),t.get(0).reset(),S(a.data),e(".wmu-preview-wrap",t).remove(),I.length&&(I.forEach(function(e){e.parents(".wpd-field-checkbox").remove()}),I=[]),setTimeout(function(){e("html, body").animate({scrollTop:e("#comment-"+a.data.new_comment_id).offset().top-32},1e3)},d),se(a,t)}else a.data&&(wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"),se(a,t));else wpdiscuzAjaxObj.setCommentMessage(a,"error");e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,d){console.log(d),e(o).addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}function S(t){e(".wpd_comm_form .wc_name").val(t.comment_author),t.comment_author_email&&t.comment_author_email.indexOf("@example.com")<0&&e(".wpd_comm_form .wc_email").val(t.comment_author_email),t.comment_author_url&&e(".wpd_comm_form .wc_website").val(t.comment_author_url)}function q(t,a){e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd_editable_comment").show(),e("#wpd-comm-"+t+" .wpdiscuz-edit-form-wrap").replaceWith(a),e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").show()}e(document).delegate(".wc_comm_submit.wpd_not_clicked","click",function(){var t=e(this),n=1,i=e(this).parents("form");if(i.hasClass("wpd_main_comm_form")||(n=function(t){var a=t.attr("class").split(" "),o="";return e.each(a,function(e,t){"wpd_comment_level"===G(t,!1)&&(o=G(t,!0))}),parseInt(o)+1}(e(this).parents(".wpd-comment"))),J(i,"#wpd-editor-"+e(".wpdiscuz_unique_id",i).val()),i.submit(function(e){e.preventDefault()}),""!==e(".wc_comment",i).val().trim()&&"<br>"!==e(".wc_comment",i).val().trim()){if(i[0].checkValidity()&&(c=i,p=!0,"2.0"===d&&e("input[name=wc_captcha]",c).length&&!e("input[name=wc_captcha]",c).val().length?(p=!1,e(".wpdiscuz-recaptcha",c).css("border","1px solid red")):"2.0"===d&&e("input[name=wc_captcha]",c).length&&e(".wpdiscuz-recaptcha",c).css("border","none"),p)){E=!0,function(t){e(".wpd-agreement-checkbox",t).each(function(){e(this).hasClass("wpd_agreement_hide")&&h&&e(this).prop("checked")&&(Cookies.set(e(this).attr("name")+"_"+g,1,{expires:30,path:"/"}),e("input[name="+e(this).attr("name")+"]").each(function(){I.push(e(this))}))})}(i),e(t).removeClass("wpd_not_clicked");var s=new FormData;if(s.append("action","wpdAddComment"),e(":input",i).each(function(){""!=this.name&&"checkbox"!=this.type&&"radio"!=this.type&&s.append(this.name+"",e(this).val().trim()),"checkbox"!=this.type&&"radio"!=this.type||e(this).is(":checked")&&s.append(this.name+"",e(this).val())}),s.append("wpd_comment_depth",n),wpdiscuzAjaxObj.wpdiscuz_zs&&s.append("wpdiscuz_zs",wpdiscuzAjaxObj.wpdiscuz_zs),e(".wpd-cookies-checkbox",i).length&&!e(".wpd-cookies-checkbox",i).prop("checked")&&(b=!1),e("#wpdiscuz-loading-bar").show(),wpdiscuzAjaxObj.wpDiscuzReCaptchaSK&&"3.0"===d&&(1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!wpdiscuzAjaxObj.is_user_logged_in||1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&wpdiscuzAjaxObj.is_user_logged_in))try{grecaptcha.ready(function(){grecaptcha.execute(wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,{action:"wpdiscuz/addComment"}).then(function(e){s.append("g-recaptcha-response",e),R(i,s,t)},function(e){wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error","error"),console.log(e)})})}catch(t){console.log(t),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+t.message,"error"),e("#wpdiscuz-loading-bar").fadeOut(250)}else R(i,s,t)}var c,p;!function(e){if((a||o)&&"2.0"===d){var t=B(e);grecaptcha.reset(T[t])}}(e(".wpdiscuz_unique_id",i).val()),e(".wpdiscuz_reset").val("")}else wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj.wc_msg_required_fields,"error")}),e(document).delegate(".wpd_editable_comment","click",function(){w&&e(".wpdiscuz-edit-form-wrap").length&&q(V(e(".wpdiscuz-edit-form-wrap"),0),w);var t=V(e(this),0),a=B(t),o=new FormData;o.append("action","wpdEditComment"),o.append("commentId",a),w=e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-text").get(0),ce(z,!0,o).done(function(a){"object"==typeof a?a.success?(e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd-comment-text").replaceWith(a.data),wpdiscuzLoadRichEditor&&(wpDiscuzEditor.createEditor("#wpd-editor-edit_"+t),e(".wpd-toolbar-hidden").prev("[id^=wpd-editor-]").css("border-bottom","1px solid #dddddd")),e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd_editable_comment").hide(),e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").hide()):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"):console.log(a),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wc_save_edited_comment","click",function(){var t=V(e(this)),a=B(t),o=e("#wpd-comm-"+t+" #wpdiscuz-edit-form");if(J(o,"#wpd-editor-edit_"+t),o.submit(function(e){e.preventDefault()}),o[0].checkValidity()){var d=new FormData;d.append("action","wpdSaveEditedComment"),d.append("commentId",a),e(":input",o).each(function(){""!==this.name&&"checkbox"!==this.type&&"radio"!==this.type&&d.append(this.name+"",e(this).val()),"checkbox"!==this.type&&"radio"!==this.type||e(this).is(":checked")&&d.append(this.name+"",e(this).val())}),ce(z,!0,d).done(function(o){"object"==typeof o?(o.success?(q(t,o.data.message),o.data.lastEdited&&(e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").remove(),e(o.data.lastEdited).insertAfter("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd-comment-text")),o.data.twitterShareLink&&e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-share .wpd-tooltip-content .wc_tw").attr("href",o.data.twitterShareLink),o.data.whatsappShareLink&&e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-share .wpd-tooltip-content .wc_whatsapp").attr("href",o.data.whatsappShareLink),wpdiscuzLoadRichEditor&&wpDiscuzEditor.removeEditor("#wpd-editor-edit_"+t)):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[o.data],"error"),se(o,a)):console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(document).delegate(".wc_cancel_edit","click",function(){var t=V(e(this));q(t,w),wpdiscuzLoadRichEditor&&wpDiscuzEditor.removeEditor("#wpd-editor-edit_"+t)}),!wpdiscuzAjaxObj.wordpressIsPaginate&&m&&(M=0,1==m?setTimeout(function(){W(!0)},500):e(document).delegate(".wpd-load-comments","click",function(){e(this).remove(),W(!0)})),e(document).delegate(".wpd-load-more-submit","click",function(){var t=e(this);t.hasClass("wpd-loaded")&&W(!1,t,"wpd-loaded","wpd-loading")});var U=!1;function H(){var t=e("#wpdiscuzHasMoreComments").val(),a=e(document).height(),o=e(window).height()+e(window).scrollTop();a&&o&&(100*o/a>=80&&!1===U&&1==t&&(U=!0,W(!1,e(".wpd-load-more-submit"))))}function W(t,a,o,d){a&&(a.toggleClass(o),a.toggleClass(d));var i=new FormData;i.append("action","wpdLoadMoreComments");var s=e(".wpdiscuz-sort-button-active").attr("data-sorting");s&&i.append("sorting",s),i.append("offset",M),i.append("lastParentId",e(".wpd-load-more-submit").attr("data-lastparentid")),i.append("isFirstLoad",t?1:0);var c=e(".wpdf-active").attr("data-filter-type");i.append("wpdType",c||""),ce(z,!0,i).done(function(i){"object"==typeof i&&i.success&&(M++,e(".wpdiscuz-comment-pagination").before(i.data.comment_list),K(i,t&&2!==n),e(".wpdiscuz_single").remove(),U=!1,r=i.data.loadLastCommentId,se(i),t&&N(!1)),e("#wpdiscuz-loading-bar").fadeOut(250),e(".wpd-load-more-submit").blur(),a&&(a.toggleClass(o),a.toggleClass(d))}).fail(function(t,n,i){console.log(i),e("#wpdiscuz-loading-bar").fadeOut(250),e(".wpd-load-more-submit").blur(),a&&(a.toggleClass(o),a.toggleClass(d))})}function K(t,a){var o;0==t.data.is_show_load_more?(e("#wpdiscuzHasMoreComments").val(0),e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").hide()):(o=t.data.last_parent_id,e(".wpd-load-more-submit").attr("data-lastparentid",o),2!==n&&e(".wpdiscuz-comment-pagination").show(),e("#wpdiscuzHasMoreComments").val(1),a&&e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").show()),se(t)}function N(t){var a=location.href.match(/#comment\-(\d+)/);if(null!==a){var o=a[1];if(e("#comment-"+o).length)setTimeout(function(){e("html, body").animate({scrollTop:e("#comment-"+o).parents("[id^=wpd-comm-]").offset().top-32},1e3),t&&P(o)},500);else{var d=new FormData;d.append("action","wpdGetSingleComment"),d.append("commentId",o),ce(z,!0,d).done(function(a){if("object"==typeof a&&a.success){var d="#comment-"+o;e("#comment-"+a.data.parentCommentID).length?e("#comment-"+a.data.parentCommentID).parents("[id^=wpd-comm-"+a.data.parentCommentID+"]").replaceWith(a.data.message):e(".wpd-thread-list").prepend(a.data.message),se(a),e("html, body").animate({scrollTop:e(d).offset().top-32},1e3),t&&P(o)}e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}}function P(t){setTimeout(function(){e("#comment-"+t).siblings(".wpd-secondary-form-wrapper").is(":visible")||e("#comment-"+t).find(".wpd-reply-button").trigger("click")},1100)}function Q(e){if(void 0!==e.data.message)for(var t,a=e.data.message,o=0;o<a.length;o++)$((t=a[o]).comment_parent,t.comment_html)}function V(e,t){var a="";return(a=t?e.parents(".wpd-main-form-wrapper").attr("id"):e.parents(".wpd-comment").attr("id")).substring(a.lastIndexOf("-")+1)}function B(e){return e.substring(0,e.indexOf("_"))}function G(e,t){return t?e.substring(e.indexOf("-")+1):e.substring(0,e.indexOf("-"))}function $(t,a){if(0==t)X(a);else{var o=V(e("#comment-"+t),0);e("#wpdiscuz_form_anchor-"+o).after(a)}}function Y(){var t,a,o="";return e(".wpd-comment-right").each(function(){t=V(e(this),0),a=B(t),o+=a+","}),o}function J(t,a){var o=t.find(".wpd-required-group");wpdiscuzLoadRichEditor&&t.find(".wc_comment").val(e(a+">.ql-editor").html()),function(e){var t=e.find(".wc_comment"),a=t.val().trim();a=(a=(a=(a=a.replace(/<img src=["|']https\:\/\/s\.w\.org\/images\/core\/emoji\/([^"|']+)["|'](.*?)alt=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$3")).replace(/<img[^>]+alt=["|']([^"|']+)["|'][^>]+src=["|']https\:\/\/s\.w\.org\/images\/core\/emoji\/([^"|']+)["|'][^>]?>/g,"$1")).replace(/<img\s+([^>]*)class=["|']wpdem\-sticker["|'](.*?)alt=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$3")).replace(/<img\s+([^>]*)src=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$2"),t.val(a)}(t),e.each(o,function(){e("input",this).removeAttr("required"),0===e("input:checked",this).length?e("input",e(this)).attr("required","required"):e(".wpd-field-invalid",this).remove()})}function X(t){e(".wpd-sticky-comment").last()[0]?e(t).insertAfter(e(".wpd-sticky-comment").last()[0]):e(".wpd-thread-list").prepend(t)}function Z(t){t?t.prop("required")||(t.val()?t.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","inline-block"):t.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","none")):e.each(e(".wc_email"),function(t,a){var o=e(a);o.prop("required")||(o.val()?o.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","inline-block"):o.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","none"))})}if(2!==n||wpdiscuzAjaxObj.wordpressIsPaginate||(e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").hide(),H(),e(window).scroll(function(){H()})),wpdiscuzAjaxObj.setLoadMoreVisibility=K,e(document).delegate(".wpd-vote-up.wpd_not_clicked, .wpd-vote-down.wpd_not_clicked","click",function(){var t=e(this);e(t).removeClass("wpd_not_clicked");var a,o=B(V(t));a=e(this).hasClass("wpd-vote-up")?1:-1;var d=new FormData;d.append("action","wpdVoteOnComment"),d.append("commentId",o),d.append("voteType",a),ce(z,!0,d).done(function(d){if(e(t).addClass("wpd_not_clicked"),"object"==typeof d){if(d.success){if("total"===d.data.buttonsStyle){var n=e(".wpd-comment-footer .wpd-vote-result",e("#comment-"+o)),i=d.data.votes;n.text(i),n.removeClass("wpd-up wpd-down"),i>0&&n.addClass("wpd-up"),i<0&&n.addClass("wpd-down")}else{var s=e(".wpd-comment-footer .wpd-vote-result-like",e("#comment-"+o)),c=e(".wpd-comment-footer .wpd-vote-result-dislike",e("#comment-"+o));s.text(d.data.likeCount),c.text(d.data.dislikeCount),parseInt(d.data.likeCount)>0?s.addClass("wpd-up"):s.removeClass("wpd-up"),parseInt(d.data.dislikeCount)<0?c.addClass("wpd-down"):c.removeClass("wpd-down")}var p=e(".wpd-comment-footer .wpd-vote-up",e("#comment-"+o)),r=e(".wpd-comment-footer .wpd-vote-down",e("#comment-"+o));p.removeClass("wpd-up"),r.removeClass("wpd-down"),d.data.curUserReaction>0?p.addClass("wpd-up"):d.data.curUserReaction<0&&r.addClass("wpd-down")}else d.data&&wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[d.data],"error");se(d,o,a)}else console.log(d);e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(a,o,d){console.log(d),e(t).addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate("body","click",function(t){var a=e(".wpdiscuz-sort-buttons");e(t.target).hasClass("wpdf-sorting")||e(t.target).parent().hasClass("wpdf-sorting")?a.css({display:a.is(":visible")?"none":"flex"}):a.hide()}),e(document).delegate(".wpdiscuz-sort-button:not(.wpdiscuz-sort-button-active)","click",function(){var t=e(this),a=e(this).attr("data-sorting");if(a){e(".wpdiscuz-sort-button.wpdiscuz-sort-button-active").removeClass("wpdiscuz-sort-button-active").appendTo(".wpdiscuz-sort-buttons"),t.addClass("wpdiscuz-sort-button-active").prependTo(".wpdf-sorting");var o=new FormData;o.append("action","wpdSorting"),o.append("sorting",a);var d=e(".wpdf-active").attr("data-filter-type");o.append("wpdType",d||""),ce(z,!0,o).done(function(t){"object"==typeof t&&t.success&&(e("#wpdcom .wpd-comment").remove(),e("#wpdcom .wpd-thread-list").prepend(t.data.message),K(t,!1),M=1),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),window.onhashchange=function(){N(!1)},1!=m&&N(!1),e(document).delegate(".wpdiscuz-readmore","click",function(){var t=V(e(this)),a=B(t),o=new FormData;o.append("action","wpdReadMore"),o.append("commentId",a),ce(z,!0,o).done(function(o){"object"==typeof o?(o.success?(e("#comment-"+a+" .wpd-comment-text").html(" "+o.data.message),e("#wpdiscuz-readmore-"+t).remove()):console.log(o.data),se(o)):console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-required-group","change",function(){0!==e("input:checked",this).length?e("input",e(this)).removeAttr("required"):e("input",e(this)).attr("required","required")}),e(document).delegate(".wpdiscuz-spoiler","click",function(){e(this).next().slideToggle(),e(this).hasClass("wpdiscuz-spoiler-closed")?e(this).parents(".wpdiscuz-spoiler-wrap").find(".fa-plus").removeClass("fa-plus").addClass("fa-minus"):e(this).parents(".wpdiscuz-spoiler-wrap").find(".fa-minus").removeClass("fa-minus").addClass("fa-plus"),e(this).toggleClass("wpdiscuz-spoiler-closed")}),e(document).delegate(".wpd-tools i","click",function(){var t=e(this).siblings(".wpd-tools-actions");t.css({display:t.is(":visible")?"none":"flex"})}),e(document).delegate(".wpd-comment-right","mouseleave",function(){e(this).find(".wpd-tools-actions").hide()}),e(document).delegate(".wpd_stick_btn","click",function(){var t=B(V(e(this),0)),a=new FormData;a.append("action","wpdStickComment"),a.append("commentId",t),ce(z,!0,a).done(function(t){"object"==typeof t&&t.success&&location.reload(!0),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd_close_btn","click",function(){var t=B(V(e(this),0)),a=new FormData;a.append("action","wpdCloseThread"),a.append("commentId",t),ce(z,!0,a).done(function(t){"object"==typeof t&&t.success&&location.reload(!0),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-filter.wpd_not_clicked[data-filter-type]","click",function(){var t=e(this),a=t.attr("data-filter-type");wpdiscuzAjaxObj.resetActiveFilters(".wpdf-"+a),t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var o=new FormData;o.append("action","wpdLoadMoreComments");var d=e(".wpdiscuz-sort-button-active").attr("data-sorting");d&&o.append("sorting",d),o.append("lastParentId",0),o.append("offset",0),M=1,o.append("wpdType",t.hasClass("wpdf-active")?"":a),o.append("isFirstLoad",1),e(this).hasClass("wpdf-inline")?e(this).hasClass("wpdf-active")?e(".wpd-comment-info-bar").hide():e(".wpd-comment-info-bar").css("display","flex"):e(".wpd-comment-info-bar").hide(),ce(z,!1,o).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(t.toggleClass("wpdf-active"),e(".wpd-load-comments").remove(),e(".wpd-comment").remove(),e(".wpd-thread-list").prepend(a.data.comment_list),K(a),r=a.data.loadLastCommentId,e(".wpd-load-more-submit").blur(),se(a)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpdf-reacted.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=new FormData;a.append("action","wpdMostReactedComment"),ce(z,!1,a).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(e("#comment-"+a.data.parentCommentID).length?e("#comment-"+a.data.parentCommentID).parents("[id^=wpd-comm-"+a.data.parentCommentID+"]").replaceWith(a.data.message):e("#comment-"+a.data.commentId).length||e(".wpd-thread-list").prepend(a.data.message),se(a),e("html, body").animate({scrollTop:e("#comment-"+a.data.commentId).offset().top-32},1e3))}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner")})}),e(document).delegate(".wpdf-hottest.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=new FormData;a.append("action","wpdHottestThread"),ce(z,!1,a).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(e("#comment-"+a.data.commentId).length?e("#comment-"+a.data.commentId).parents("[id^=wpd-comm-"+a.data.commentId+"]").replaceWith(a.data.message):e(".wpd-thread-list").prepend(a.data.message),se(a),e("html, body").animate({scrollTop:e("#comment-"+a.data.commentId).offset().top-32},1e3))}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner")})}),e(document).delegate(".wpd-filter-view-all","click",function(){e(".wpdf-inline.wpdf-active.wpd_not_clicked").trigger("click")}),e(document).delegate(".wpd-follow-link.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=B(V(t,0)),o=new FormData;o.append("action","wpdFollowUser"),o.append("commentId",a),ce(z,!0,o).done(function(a){t.addClass("wpd_not_clicked"),"object"==typeof a?a.success?(wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data.code],"success"),t.removeClass("wpd-follow-active"),a.data.followTip&&t.attr("wpd-tooltip",a.data.followTip),a.data.followClass&&t.addClass(a.data.followClass)):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"):console.log(a),e(".fas",t).removeClass("fa-pulse fa-spinner"),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner"),e("#wpdiscuz-loading-bar").fadeOut(250)})}),Z(),e(document).delegate(".wc_email","keyup",function(){Z(e(this))}),j){if(e("#wpd-bubble-wrapper").hover(function(){e(this).addClass("wpd-bubble-hover")},function(){e(this).removeClass("wpd-bubble-hover")}),k&&!Cookies.get(wpdiscuzAjaxObj.cookieHideBubbleHint)&&setTimeout(function(){e("#wpd-bubble-wrapper").addClass("wpd-bubble-hover"),Cookies.set(wpdiscuzAjaxObj.cookieHideBubbleHint,"1",{expires:7,path:"/"}),setTimeout(function(){e("#wpd-bubble-wrapper").removeClass("wpd-bubble-hover")},1e3*x)},1e3*k),"content_left"===O)if(e(".entry-content").length){var ee=(te=Math.min(e(".entry-content").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else if(e(".post-entry").length){ee=(te=Math.min(e(".post-entry").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else if(e(".container").length){var te;ee=(te=Math.min(e(".container").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else e("#wpd-bubble-wrapper").css({left:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-corner");else"left_corner"===O?(e("#wpd-bubble-wrapper").css({left:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-corner")):"right_corner"===O&&(e("#wpd-bubble-wrapper").css({right:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-right-corner"));e("#wpd-bubble-wrapper").show(),e("#wpd-bubble-add-message-close").click(function(t){t.preventDefault(),t.stopPropagation(),e("#wpd-bubble-wrapper").removeClass("wpd-bubble-hover")}),e("#wpd-bubble").click(function(){e("html, body").animate({scrollTop:e("#wpdcom").offset().top-60},1e3,function(){wpdiscuzLoadRichEditor?wpDiscuzEditor.createEditor("#wpd-editor-0_0").focus():e("#wc-textarea-0_0").focus()})}),e("#wpd-bubble-comment-close").click(function(t){t.preventDefault(),e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added")}),e("#wpd-bubble-comment-reply-link a").click(function(){var t=e(this).attr("href");setTimeout(function(){e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added"),N(!0);var a=t.match(/#comment\-(\d+)/);D=D.filter(function(e){return e!=a[1]}),e("#wpd-bubble-count .wpd-new-comments-count").text(D.length),0==D.length&&e("#wpd-bubble-count").removeClass("wpd-new-comments")},100)}),e("#wpd-bubble-count").click(function(){if(D.length){var t=new FormData;t.append("action","wpdBubbleUpdate"),t.append("newCommentIds",D.join()),ce(z,!0,t).done(function(t){"object"==typeof t&&t.success&&(t.data.message=t.data.message.filter(function(t){if(!e("#comment-"+t.comment_id).length)return t}),Q(t),e("#wpd-bubble-count").removeClass("wpd-new-comments"),e("#wpd-bubble-count .wpd-new-comments-count").text("0"),D=[],e("html, body").animate({scrollTop:e(e(".wpd-new-loaded-comment")[0]).offset().top-60},1e3),se(t)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(e,t,a){console.log(a)})}})}if((j&&C||s)&&(t||!t&&p)&&setTimeout(function t(){e.ajax({type:"GET",url:wpdiscuzAjaxObj.bubbleUpdateUrl,data:{postId:i,lastId:l,visibleCommentIds:Y()}}).done(function(a){if(!E)if("object"==typeof a){if(a.ids.length){s&&((n=new FormData).append("action","wpdUpdateAutomatically"),n.append("loadLastCommentId",r),n.append("visibleCommentIds",Y()),ce(z,!1,n).done(function(t){E||"object"==typeof t&&t.success&&(Q(t),e(".wpd-thread-info").html(t.data.wc_all_comments_count_new_html),t.data.wc_all_comments_count_new=parseInt(t.data.wc_all_comments_count_new),e("#wpd-bubble-all-comments-count").text(t.data.wc_all_comments_count_new),t.data.wc_all_comments_count_new?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),r=t.data.loadLastCommentId)}).fail(function(e,t,a){console.log(a)})),a.ids=a.ids.filter(function(t){if(!e("#comment-"+t).length)return t});var o=5e3;l=parseInt(a.ids[a.ids.length-1]),D=D.concat(a.ids),y&&a.commentText&&(e("#wpd-bubble-author-avatar").html(a.avatar),e("#wpd-bubble-author-name").html(a.authorName),e("#wpd-bubble-comment-date span").html(a.commentDate),e("#wpd-bubble-comment-text").html(a.commentText),e("#wpd-bubble-comment-reply-link a").attr("href",a.commentLink),e("#wpd-bubble-notification-message").show(),o=1e4);var d=parseInt(e(".wpd-new-comments-count").text());d+=a.ids.length,e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added"),e("#wpd-bubble-wrapper").addClass("wpd-new-comment-added"),setTimeout(function(){e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added")},o),e(".wpd-new-comments-count").text(d),e("#wpd-bubble-count").addClass("wpd-new-comments"),a.all_comments_count=parseInt(a.all_comments_count),e("#wpd-bubble-all-comments-count").text(a.all_comments_count),a.all_comments_count?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),e(".wpd-thread-info").html(a.all_comments_count_html)}}else console.log(a);var n;setTimeout(t,c)}).fail(function(e,a,o){console.log(o),setTimeout(t,c)})},c),e(".wpd-inline-form-wrapper").length){var ae=new FormData;ae.append("action","wpdGetInlineCommentForm"),ce(z,!1,ae).done(function(t){"object"==typeof t?t.success?(e(".wpd-inline-form-wrapper").append(t.data),e.each(e("[name=_wpd_inline_nonce]"),function(){var t=e(this).attr("id"),a=e(this).parents(".wpd-inline-shortcode").attr("id");e(this).attr("id",t+"-"+a.substring(a.lastIndexOf("-")+1))}),e(".wpd-inline-opened").addClass("wpd-active"),e(".wpd-inline-opened").find(".wpd-inline-form-wrapper").show(),e(".wpd-inline-opened").find(".wpd-inline-icon").addClass("wpd-open"),e(".wpd-inline-opened").find(".wpd-inline-icon").removeClass("wpd-ignored"),ie()):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error"):console.log(t)}).fail(function(e,t,a){console.log(a)})}function oe(t){if(e(t).hasClass("wpd-inline-shortcode"))var a=e(t).attr("id");else a=e(t).parents(".wpd-inline-shortcode").attr("id");return a.substring(a.lastIndexOf("-")+1)}function de(){e(".wpd-inline-form-wrapper").hide(),e(".wpd-inline-shortcode").removeClass("wpd-active"),e(".wpd-inline-icon").removeClass("wpd-open")}function ne(){e.each(e(".wpd-inline-shortcode:not(.wpd-inline-opened) .wpd-inline-icon"),function(){var t=e(this),a=t.offset().top-window.pageYOffset;a>0&&a<300&&("blink"===A?(t.addClass("wpd-blink"),setTimeout(function(){t.removeClass("wpd-blink")},3e3)):(t.parents(".wpd-inline-shortcode").addClass("wpd-active"),t.siblings(".wpd-inline-form-wrapper").show(),t.addClass("wpd-open"),ie(t.siblings(".wpd-inline-form-wrapper"))))})}function ie(t){if(t){if(t.offset().left<=10)t.css("left",Math.ceil(parseInt(t.css("left"))-t.offset().left+10)),(a=Math.ceil(t.siblings(".wpd-inline-icon.wpd-open").offset().left-t.offset().left+2))<3&&(a=3),document.styleSheets[0].addRule("#"+t.parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+a+"px;");else if(t.offset().left+t.width()>document.body.clientWidth-10){var a;t.css("left",Math.ceil(parseInt(t.css("left"))+(document.body.clientWidth-(t.offset().left+t.width()))-10)),(a=Math.ceil(t.siblings(".wpd-inline-icon.wpd-open").offset().left-t.offset().left+2))>t.width()-3&&(a=t.width()-3),document.styleSheets[0].addRule("#"+t.parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+a+"px;")}}else e.each(e(".wpd-inline-form-wrapper:visible"),function(){if(e(this).offset().left<=10)e(this).css("left",Math.ceil(parseInt(e(this).css("left"))-e(this).offset().left+10)),(t=Math.ceil(e(this).siblings(".wpd-inline-icon.wpd-open").offset().left-e(this).offset().left+2))<3&&(t=3),document.styleSheets[0].addRule("#"+e(this).parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+t+"px;");else if(e(this).offset().left+e(this).width()>document.body.clientWidth-10){var t;e(this).css("left",Math.ceil(parseInt(e(this).css("left"))+(document.body.clientWidth-(e(this).offset().left+e(this).width()))-10)),(t=Math.ceil(e(this).siblings(".wpd-inline-icon.wpd-open").offset().left-e(this).offset().left+2))>e(this).width()-3&&(t=e(this).width()-3),document.styleSheets[0].addRule("#"+e(this).parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+t+"px;")}})}function se(t,a,o,d){t.data.callbackFunctions&&e.each(t.data.callbackFunctions,function(e){"function"==typeof wpdiscuzAjaxObj[t.data.callbackFunctions[e]]?wpdiscuzAjaxObj[t.data.callbackFunctions[e]](t,a,o,d):console.log(t.data.callbackFunctions[e]+" is not a function")})}function ce(t,a,o){a&&e("#wpdiscuz-loading-bar").show(),o.append("postId",i);var d=o.get("action");wpdiscuzAjaxObj.dataFilterCallbacks&&wpdiscuzAjaxObj.dataFilterCallbacks[d]&&e.each(wpdiscuzAjaxObj.dataFilterCallbacks[d],function(e){"function"==typeof wpdiscuzAjaxObj[wpdiscuzAjaxObj.dataFilterCallbacks[d][e]]&&(o=wpdiscuzAjaxObj[wpdiscuzAjaxObj.dataFilterCallbacks[d][e]](o,t,a))});var n=t?wpdiscuzAjaxObj.url:wpdiscuzAjaxObj.customAjaxUrl;return e.ajax({type:"POST",url:n,data:o,contentType:!1,processData:!1})}e(document).delegate("body","click",function(t){if(e(t.target).hasClass("wpd-inline-form-close")||e(t.target).parents(".wpd-inline-form-close").length)t.preventDefault(),e(t.target).parents(".wpd-inline-form-wrapper").hide(),e(t.target).parents(".wpd-inline-shortcode").removeClass("wpd-active"),e(t.target).parents(".wpd-inline-form-wrapper").siblings(".wpd-inline-icon").removeClass("wpd-open");else if(!e(t.target).hasClass("wpd-inline-form-wrapper")&&!e(t.target).parents(".wpd-inline-form-wrapper").length){de();var a="";e(t.target).hasClass("wpd-inline-icon")?a=e(t.target):e(t.target).parents(".wpd-inline-icon").length&&(a=e(t.target).parents(".wpd-inline-icon")),a.length&&(a.parents(".wpd-inline-shortcode").addClass("wpd-active"),a.siblings(".wpd-inline-form-wrapper").show(),a.addClass("wpd-open"),a.removeClass("wpd-ignored"),ie(a.siblings(".wpd-inline-form-wrapper")))}(!e(t.target).hasClass("wpd-last-inline-comments-wrapper")&&!e(t.target).parents(".wpd-last-inline-comments-wrapper").length||e(t.target).parents(".wpd-last-inline-comments-wrapper").length&&e(t.target).hasClass("wpd-load-inline-comment"))&&e(".wpd-last-inline-comments-wrapper").remove()}),e(document).delegate(".wpd-inline-submit.wpd_not_clicked","click",function(t){t.preventDefault();var a=e(this),o=e(this).parents(".wpd_inline_comm_form");if(o[0].checkValidity()){e(this).removeClass("wpd_not_clicked");var d=new FormData;d.append("action","wpdAddInlineComment"),d.append("inline_form_id",oe(o)),e.each(e("input, textarea",o),function(t,a){"checkbox"===this.type?e(this).is(":checked")&&d.append(e(a).attr("name"),e(a).val()):d.append(e(a).attr("name"),e(a).val())}),ce(z,!0,d).done(function(t){if(a.addClass("wpd_not_clicked"),"object"==typeof t)if(t.success){o[0].reset(),de();var d=parseInt(t.data.newCount),n=a.parents(".wpd-inline-icon-wrapper").find(".wpd-inline-icon-count");n.text(d),d?n.addClass("wpd-has-comments"):n.removeClass("wpd-has-comments"),e(".wpd-thread-info").html(t.data.allCommentsCountNewHtml),t.data.allCommentsCountNew=parseInt(t.data.allCommentsCountNew),e("#wpd-bubble-all-comments-count").text(t.data.allCommentsCountNew),t.data.allCommentsCountNew?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),t.data.message&&X(t.data.message),wpdiscuzAjaxObj.setCommentMessage(t.data.notification,"success")}else t.data&&wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error");else wpdiscuzAjaxObj.setCommentMessage(t,"error");e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(document).delegate(".wpd-form","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).find(".wc_comm_submit").trigger("click")}),e(document).delegate("#wpdiscuz-edit-form","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).find(".wc_save_edited_comment").trigger("click")}),e(document).delegate(".wpd-inline-comment-content","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).parents(".wpd_inline_comm_form").find(".wpd-inline-submit.wpd_not_clicked").trigger("click")}),e(document).delegate(".wpd-inline-icon-count.wpd-has-comments","click",function(){var t=e(this),a=new FormData;a.append("action","wpdGetLastInlineComments"),a.append("inline_form_id",oe(t)),ce(z,!0,a).done(function(a){"object"==typeof a?a.success?e(a.data).insertAfter(t):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"):console.log(a),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-view-all-inline-comments","click",function(t){t.preventDefault(),e(this).parents(".wpd-last-inline-comments-wrapper").remove(),e(".wpdf-inline").hasClass("wpdf-active")||e(".wpdf-inline").trigger("click"),e("html, body").animate({scrollTop:e(".wpdf-inline").offset().top-32},1e3)}),e(document).delegate(".wpd-feedback-content-link","click",function(t){t.preventDefault();var a=e(this).data("feedback-content-id");e("html, body").animate({scrollTop:e("#wpd-inline-"+a).offset().top-38},1e3,function(){e("#wpd-inline-"+a).addClass("wpd-active")})}),"scroll_open"!==A&&"blink"!==A||(ne(),e(window).scroll(ne)),e(document).delegate("#wpd-post-rating.wpd-not-rated .wpd-rate-starts svg","click",function(){var t=new FormData,a=e(this).index();a>=0&&a<5&&(t.append("action","wpdUserRate"),t.append("rating",a+1),ce(z,!0,t).done(function(t){"object"==typeof t?t.success?location.reload(!0):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error"):console.log(t),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}))}),e("#wpdiscuz-subscribe-form").submit(function(t){t.preventDefault();var a,o,n=e(this);if(n[0].checkValidity()&&(a=n,o=!0,"2.0"===d&&e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).length&&!e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).val().length?(o=!1,e(".wpdiscuz-recaptcha",a).css("border","1px solid red")):"2.0"===d&&e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).length&&e(".wpdiscuz-recaptcha",a).css("border","none"),o)){var i=new FormData;i.append("action","wpdAddSubscription"),e("*",n).each(function(){""!=this.name&&"checkbox"!=this.type&&"radio"!=this.type&&i.append(this.name+"",e(this).val()),"checkbox"!=this.type&&"radio"!=this.type||e(this).is(":checked")&&i.append(this.name+"",e(this).val())}),ce(z,!0,i).done(function(t){"object"==typeof t?t.success?(wpdiscuzAjaxObj.setCommentMessage(t.data,"success"),setTimeout(function(){location.reload(!0)},3e3)):wpdiscuzAjaxObj.setCommentMessage(t.data,"error"):wpdiscuzAjaxObj.setCommentMessage(t,"error"),e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(".wpd-unsubscribe").click(function(t){t.preventDefault();var a=new FormData;a.append("action","wpdUnsubscribe"),a.append("sid",e(this).data("sid")),a.append("skey",e(this).data("skey")),ce(z,!0,a).done(function(t){"object"==typeof t?t.success?(wpdiscuzAjaxObj.setCommentMessage(t.data,"success"),setTimeout(function(){location.reload(!0)},3e3)):wpdiscuzAjaxObj.setCommentMessage(t.data,"error"):console.log(t),e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),wpdiscuzAjaxObj.resetActiveFilters=function(t){e(".wpd-filter.wpdf-active"+(t?":not("+t+")":"")).removeClass("wpdf-active")},wpdiscuzAjaxObj.getAjaxObj=ce});var onloadCallback=function(){if(document.getElementById("wpdiscuz-recaptcha-0_0")&&"2.0"===wpdiscuzAjaxObj.wpDiscuzReCaptchaVersion&&(1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!wpdiscuzAjaxObj.is_user_logged_in||1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&wpdiscuzAjaxObj.is_user_logged_in))try{grecaptcha.render("wpdiscuz-recaptcha-0_0",{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(e){jQuery("#wpdiscuz-recaptcha-field-0_0").val("key")},"expired-callback":function(){jQuery("#wpdiscuz-recaptcha-field-0_0").val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}};
1
+ var wpdiscuzLoadRichEditor=parseInt(wpdiscuzAjaxObj.loadRichEditor);if(wpdiscuzLoadRichEditor)var wpDiscuzEditor=new WpdEditor;function wpdMessagesOnInit(e,t){wpdiscuzAjaxObj.setCommentMessage(e,t),setTimeout(function(){location.href=location.href.substring(0,location.href.indexOf("wpdiscuzUrlAnchor")-1)},3e3)}wpdiscuzAjaxObj.setCommentMessage=function(e,t,a){var o="wpdiscuz-message-error";if("[object Array]"===Object.prototype.toString.call(e))for(var d in e)"[object Array]"===Object.prototype.toString.call(t)?"success"===t[d]?o="wpdiscuz-message-success":"warning"===t[d]&&(o="wpdiscuz-message-warning"):"success"===t?o="wpdiscuz-message-success":"warning"===t&&(o="wpdiscuz-message-warning"),jQuery("<div/>").addClass(o).html(e[d]).prependTo("#wpdiscuz-comment-message").delay("[object Array]"===Object.prototype.toString.call(a)?a[d]:a||4e3).fadeOut(1e3,function(){jQuery(this).remove()});else"success"===t?o="wpdiscuz-message-success":"warning"===t&&(o="wpdiscuz-message-warning"),jQuery("<div/>").addClass(o).html(e).prependTo("#wpdiscuz-comment-message").delay(a||4e3).fadeOut(1e3,function(){jQuery(this).remove()})},jQuery(document).ready(function(e){e("body").addClass("wpdiscuz_"+wpdiscuzAjaxObj.version);var t=wpdiscuzAjaxObj.is_user_logged_in,a=1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!t,o=1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&t,d=wpdiscuzAjaxObj.wpDiscuzReCaptchaVersion,n=parseInt(wpdiscuzAjaxObj.commentListLoadType),s=parseInt(wpdiscuzAjaxObj.wc_post_id),i=parseInt(wpdiscuzAjaxObj.commentListUpdateType),c=1e3*parseInt(wpdiscuzAjaxObj.commentListUpdateTimer),p=parseInt(wpdiscuzAjaxObj.liveUpdateGuests),r=wpdiscuzAjaxObj.loadLastCommentId,l=r,m=parseInt(wpdiscuzAjaxObj.firstLoadWithAjax);Cookies.get("wpdiscuz_comments_sorting")&&Cookies.remove("wpdiscuz_comments_sorting",{path:""}),Cookies.get("wordpress_last_visit")&&Cookies.remove("wordpress_last_visit",{path:""}),Cookies.get("wpdiscuz_last_visit")&&Cookies.remove("wpdiscuz_last_visit",{path:""});var w,u=wpdiscuzAjaxObj.storeCommenterData,f=parseInt(wpdiscuzAjaxObj.wmuEnabled),h=wpdiscuzAjaxObj.isCookiesEnabled,b=!0,g=wpdiscuzAjaxObj.cookiehash,_=parseInt(wpdiscuzAjaxObj.isLoadOnlyParentComments),v=parseInt(wpdiscuzAjaxObj.enableDropAnimation)?500:0,z=parseInt(wpdiscuzAjaxObj.isNativeAjaxEnabled),j=parseInt(wpdiscuzAjaxObj.enableBubble),C=parseInt(wpdiscuzAjaxObj.bubbleLiveUpdate),k=parseInt(wpdiscuzAjaxObj.bubbleHintTimeout),x=parseInt(wpdiscuzAjaxObj.bubbleHintHideTimeout)?parseInt(wpdiscuzAjaxObj.bubbleHintHideTimeout):5,y=parseInt(wpdiscuzAjaxObj.bubbleShowNewCommentMessage),O=wpdiscuzAjaxObj.bubbleLocation,A=wpdiscuzAjaxObj.inlineFeedbackAttractionType,I=[],T=[],D=[],E=!1,M=1;(e(".wc_social_plugin_wrapper .wp-social-login-provider-list").length?e(".wc_social_plugin_wrapper .wp-social-login-provider-list").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .the_champ_login_container").length?e(".wc_social_plugin_wrapper .the_champ_login_container").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .social_connect_form").length?e(".wc_social_plugin_wrapper .social_connect_form").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"):e(".wc_social_plugin_wrapper .oneall_social_login_providers").length&&e(".wc_social_plugin_wrapper .oneall_social_login .oneall_social_login_providers").clone().prependTo("#wpdiscuz_hidden_secondary_form > .wpd-form-wrapper > .wpd-secondary-forms-social-content"),wpdiscuzLoadRichEditor&&e("#wpd-editor-0_0").length&&wpDiscuzEditor.createEditor("#wpd-editor-0_0"),e(document).delegate("#wpdcom .ql-editor, #wpdcom .wc_comment","focus",function(){e(".wpd-form-foot",e(this).parents(".wpd_comm_form")).slideDown(v)}),e(document).delegate("#wpdcom textarea","focus",function(){e(this).next(".autogrow-textarea-mirror").length||e(this).autoGrow()}),t)||S({comment_author:Cookies.get("comment_author_"+g),comment_author_email:Cookies.get("comment_author_email_"+g),comment_author_url:Cookies.get("comment_author_url_"+g)});if(e(".wpd-vote-down.wpd-dislike-hidden").remove(),e(".wpd-toolbar-hidden").prev("[id^=wpd-editor-]").css("border-bottom","1px solid #dddddd"),e(document).delegate("#wpd-editor-source-code-wrapper-bg","click",function(){e(this).hide(),e("#wpd-editor-source-code-wrapper").hide(),e("#wpd-editor-uid").val(""),e("#wpd-editor-source-code").val("")}),wpdiscuzLoadRichEditor&&e(document).delegate("#wpd-insert-source-code","click",function(){var t=wpDiscuzEditor.createEditor("#"+e("#wpd-editor-uid").val());t.deleteText(0,t.getLength(),Quill.sources.USER);var a=e("#wpd-editor-source-code").val();a.length&&(console.log(a),t.clipboard.dangerouslyPasteHTML(0,a,Quill.sources.USER)),t.update(),e("#wpd-editor-source-code-wrapper-bg").hide(),e("#wpd-editor-source-code-wrapper").hide(),e("#wpd-editor-uid").val(""),e("#wpd-editor-source-code").val("")}),e(document).delegate(".wpd-reply-button","click",function(){var n=V(e(this),0);e(this).hasClass("wpdiscuz-clonned")?(wpdiscuzLoadRichEditor?setTimeout(function(){wpDiscuzEditor.createEditor("#wpd-editor-"+n).focus()},v):setTimeout(function(){e("#wc-textarea-"+n).trigger("focus")},v),e("#wpd-secondary-form-wrapper-"+n).slideToggle(v)):function(a){var o=V(a,0);e("#wpdiscuz_form_anchor-"+o).before(function(t){return e("#wpdiscuz_hidden_secondary_form").html().replace(/wpdiscuzuniqueid/g,t)}(o));var d=e("#wpd-secondary-form-wrapper-"+o);if(!t){var n={comment_author:Cookies.get("comment_author_"+g),comment_author_email:Cookies.get("comment_author_email_"+g),comment_author_url:Cookies.get("comment_author_url_"+g)};S(n)}wpdiscuzLoadRichEditor?setTimeout(function(){wpDiscuzEditor.createEditor("#wpd-editor-"+o).focus()},v):setTimeout(function(){e("#wc-textarea-"+o).trigger("focus")},v);d.slideToggle(v,function(){a.addClass("wpdiscuz-clonned")})}(e(this)),function(t){if((a||o)&&"2.0"===d){var n=B(t);setTimeout(function(){if(!T[n])try{T[n]=grecaptcha.render("wpdiscuz-recaptcha-"+t,{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(a){e("#wpdiscuz-recaptcha-field-"+t).val("key")},"expired-callback":function(){e("#wpdiscuz-recaptcha-field-"+t).val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}},1e3)}}(n)}),e(document).delegate("#wpdcom .wpd-comment-link [data-comment-url]","click",function(){var t=e(this).data("comment-url"),a=e("<input/>");a.appendTo("body").css({position:"absolute",top:"-10000000px"}).val(t),a.select(),document.execCommand("copy"),a.remove(),wpdiscuzAjaxObj.setCommentMessage(t+"<br/>"+wpdiscuzAjaxObj.wc_copied_to_clipboard,"success",5e3)}),e(document).delegate(".wpdiscuz-nofollow,.wc_captcha_refresh_img,.wpd-load-more-submit","click",function(e){e.preventDefault()}),e(document).delegate(".wpd-toggle.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked");var a=V(e(this),0),o=e(this),d=e(".fas",o);!o.parents(".wpd-comment:not(.wpd-reply)").children(".wpd-reply").length&&_?function(t,a){var o=B(t),d=new FormData;d.append("action","wpdShowReplies"),d.append("commentId",o),ce(z,!0,d).done(function(o){a.addClass("wpd_not_clicked"),"object"==typeof o&&o.success&&(e("#wpd-comm-"+t).replaceWith(o.data.comment_list),e("#wpd-comm-"+t+" .wpd-toggle .fas").removeClass("fa-chevron-down").addClass("fa-chevron-up"),e("#wpd-comm-"+t+" .wpd-toggle").attr("wpd-tooltip",wpdiscuzAjaxObj.wc_hide_replies_text),e("#wpd-comm-"+t+" .wpd-toggle .wpd-view-replies").remove(),ie(o)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,o,d){console.log(d),a.addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}(a,t):e("#wpd-comm-"+a+"> .wpd-reply").slideToggle(700,function(){e(this).is(":hidden")?(d.removeClass("fa-chevron-up"),d.addClass("fa-chevron-down"),o.attr("wpd-tooltip",wpdiscuzAjaxObj.wc_show_replies_text)):(d.removeClass("fa-chevron-down"),d.addClass("fa-chevron-up"),o.attr("wpd-tooltip",wpdiscuzAjaxObj.wc_hide_replies_text)),t.addClass("wpd_not_clicked")})}),e(document).delegate(".wpd-new-loaded-comment","mouseenter",function(){e(this).removeClass("wpd-new-loaded-comment")}),e(document).delegate(".wpd-sbs-toggle","click",function(){e(".wpdiscuz-subscribe-bar").slideToggle(v)}),parseInt(wpdiscuzAjaxObj.wpDiscuzIsShowOnSubscribeForm)&&!t&&wpdiscuzAjaxObj.wpDiscuzReCaptchaSK&&("2.0"===d?(setTimeout(function(){try{grecaptcha.render("wpdiscuz-recaptcha-subscribe-form",{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(t){e("#wpdiscuz-recaptcha-field-subscribe-form").val("key")},"expired-callback":function(){e("#wpdiscuz-recaptcha-field-subscribe-form").val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}},1e3),e(document).delegate("#wpdiscuz-subscribe-form","submit",function(t){e("#wpdiscuz-recaptcha-field-subscribe-form").val()?e(".wpdiscuz-recaptcha",e(this)).css("border","none"):(e(".wpdiscuz-recaptcha",e(this)).css("border","1px solid red"),t.preventDefault())})):"3.0"===d&&e(document).delegate("#wpdiscuz_subscription_button","click",function(t){var a=e(this).parents("#wpdiscuz-subscribe-form");t.preventDefault();try{grecaptcha.ready(function(){grecaptcha.execute(wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,{action:"wpdiscuz/wpdAddSubscription"}).then(function(e){console.log(5555),document.getElementById("wpdiscuz-recaptcha-field-subscribe-form").value=e,a.submit()},function(e){wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error","error"),console.log(e)})})}catch(t){console.log(t),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+t.message,"error")}})),(a||o)&&"2.0"===d){var F=e(window).width(),L=e("#wpdcom").width();L>=1100&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"65%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"35%"})),L>=940&&L<1100&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"60%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"40%"})),L>=810&&L<940&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"40%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"60%"})),L>=730&&L<810&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.9)","-webkit-transform":"scale(0.9)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"45%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"55%"})),L>=610&&L<730&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.85)","-webkit-transform":"scale(0.85)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({transform:"scale(0.8)","-webkit-transform":"scale(0.8)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"43%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"55%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"30%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"70%"})),F>650&&(L>=510&&L<610&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"center 0","-webkit-transform-origin":"center 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"35%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"63%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({width:"30%",position:"relative",right:"-60px"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({width:"70%"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"})),L>=470&&L<510&&(e("#wpdcom .wpd_main_comm_form .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"center 0","-webkit-transform-origin":"center 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({"transform-origin":"right 0","-webkit-transform-origin":"right 0",transform:"scale(0.77)","-webkit-transform":"scale(0.77)"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-left").css({width:"40%"}),e("#wpdcom .wpd_main_comm_form .wpd-form-col-right").css({width:"60%"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-left").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-secondary-form-wrapper .wpd-form-col-right").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd_main_comm_form .wc-form-footer").css({"margin-left":"0px"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"})),L<470&&(e("#wpdcom .wpd-secondary-form-wrapper .wpd-field-captcha .wpdiscuz-recaptcha").css({margin:"0px auto","transform-origin":"center 0","-webkit-transform-origin":"center 0"}),e("#wpdcom .wpd-form-col-left").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-form-col-right").css({float:"none",width:"100%",display:"block"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-form-footer").css({"margin-left":"0px"}),e("#wpdcom .wpd-secondary-form-wrapper .wc_notification_checkboxes").css({"text-align":"center"}),e("#wpdcom .wpd-secondary-form-wrapper .wc-field-submit").css({"text-align":"center"})))}function R(t,a,o){ce(z||f,!1,a).done(function(a){if(e(o).addClass("wpd_not_clicked"),"object"==typeof a)if(a.success){"collapsed"===wpdiscuzAjaxObj.commentFormView&&e(".wpd-form-foot",t).slideUp(v),e(".wpd-thread-info").html(a.data.wc_all_comments_count_new_html),a.data.wc_all_comments_count_new=parseInt(a.data.wc_all_comments_count_new),e("#wpd-bubble-all-comments-count").text(a.data.wc_all_comments_count_new),a.data.wc_all_comments_count_new?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide();var d=v;a.data.is_main?X(a.data.message):(d=v+700,e("#wpd-secondary-form-wrapper-"+a.data.uniqueid).slideToggle(700),1==a.data.is_in_same_container?e("#wpd-secondary-form-wrapper-"+a.data.uniqueid).after(a.data.message):e("#wpd-comm-"+a.data.uniqueid).after(a.data.message)),function(e){if(!e.data.held_moderate){var t=new FormData;t.append("action","wpdCheckNotificationType"),t.append("comment_id",e.data.new_comment_id),t.append("email",e.data.comment_author_email),t.append("isParent",e.data.is_main),ce(z,!0,t)}}(a),function(e){if(e.data.redirect>0&&e.data.new_comment_id){var t=new FormData;t.append("action","wpdRedirect"),t.append("commentId",e.data.new_comment_id),ce(z,!0,t).done(function(e){"object"==typeof e&&e.success&&setTimeout(function(){location.href=e.data},2e3)}).fail(function(e,t,a){console.log(a)})}}(a),h&&b?function(t){var a=t.comment_author_email,o=t.comment_author,d=t.comment_author_url;null==u?(Cookies.set("comment_author_email_"+g,a),Cookies.set("comment_author_"+g,o),d.length&&Cookies.set("comment_author_url_"+g,d)):(u=parseInt(u),Cookies.set("comment_author_email_"+g,a,{expires:u,path:"/"}),Cookies.set("comment_author_"+g,o,{expires:u,path:"/"}),d.length&&Cookies.set("comment_author_url_"+g,d,{expires:u,path:"/"}));e(".wpd-cookies-checkbox").length&&e(".wpd-cookies-checkbox").attr("checked","checked")}(a.data):b||e(".wpd-cookies-checkbox").removeAttr("checked"),wpdiscuzLoadRichEditor&&wpDiscuzEditor.createEditor("#wpd-editor-"+e(".wpdiscuz_unique_id",t).val()).setContents([{insert:"\n"}]),t.get(0).reset(),S(a.data),e(".wmu-preview-wrap",t).remove(),I.length&&(I.forEach(function(e){e.parents(".wpd-field-checkbox").remove()}),I=[]),setTimeout(function(){e("html, body").animate({scrollTop:e("#comment-"+a.data.new_comment_id).offset().top-32},1e3)},d),ie(a,t)}else a.data&&(wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"),ie(a,t));else wpdiscuzAjaxObj.setCommentMessage(a,"error");e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,d){console.log(d),e(o).addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}function S(t){e(".wpd_comm_form .wc_name").val(t.comment_author),t.comment_author_email&&t.comment_author_email.indexOf("@example.com")<0&&e(".wpd_comm_form .wc_email").val(t.comment_author_email),t.comment_author_url&&e(".wpd_comm_form .wc_website").val(t.comment_author_url)}function q(t,a){e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd_editable_comment").show(),e("#wpd-comm-"+t+" .wpdiscuz-edit-form-wrap").replaceWith(a),e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").show()}e(document).delegate(".wc_comm_submit.wpd_not_clicked","click",function(){var t=e(this),n=1,s=e(this).parents("form");if(s.hasClass("wpd_main_comm_form")||(n=function(t){var a=t.attr("class").split(" "),o="";return e.each(a,function(e,t){"wpd_comment_level"===G(t,!1)&&(o=G(t,!0))}),parseInt(o)+1}(e(this).parents(".wpd-comment"))),J(s,"#wpd-editor-"+e(".wpdiscuz_unique_id",s).val()),s.submit(function(e){e.preventDefault()}),""!==e(".wc_comment",s).val().trim()&&"<br>"!==e(".wc_comment",s).val().trim()){if(s[0].checkValidity()&&(c=s,p=!0,"2.0"===d&&e("input[name=wc_captcha]",c).length&&!e("input[name=wc_captcha]",c).val().length?(p=!1,e(".wpdiscuz-recaptcha",c).css("border","1px solid red")):"2.0"===d&&e("input[name=wc_captcha]",c).length&&e(".wpdiscuz-recaptcha",c).css("border","none"),p)){E=!0,function(t){e(".wpd-agreement-checkbox",t).each(function(){e(this).hasClass("wpd_agreement_hide")&&h&&e(this).prop("checked")&&(Cookies.set(e(this).attr("name")+"_"+g,1,{expires:30,path:"/"}),e("input[name="+e(this).attr("name")+"]").each(function(){I.push(e(this))}))})}(s),e(t).removeClass("wpd_not_clicked");var i=new FormData;if(i.append("action","wpdAddComment"),e(":input",s).each(function(){""!=this.name&&"checkbox"!=this.type&&"radio"!=this.type&&i.append(this.name+"",e(this).val().trim()),"checkbox"!=this.type&&"radio"!=this.type||e(this).is(":checked")&&i.append(this.name+"",e(this).val())}),i.append("wpd_comment_depth",n),wpdiscuzAjaxObj.wpdiscuz_zs&&i.append("wpdiscuz_zs",wpdiscuzAjaxObj.wpdiscuz_zs),e(".wpd-cookies-checkbox",s).length&&!e(".wpd-cookies-checkbox",s).prop("checked")&&(b=!1),e("#wpdiscuz-loading-bar").show(),wpdiscuzAjaxObj.wpDiscuzReCaptchaSK&&"3.0"===d&&(1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!wpdiscuzAjaxObj.is_user_logged_in||1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&wpdiscuzAjaxObj.is_user_logged_in))try{grecaptcha.ready(function(){grecaptcha.execute(wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,{action:"wpdiscuz/addComment"}).then(function(e){i.append("g-recaptcha-response",e),R(s,i,t)},function(e){wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error","error"),console.log(e)})})}catch(t){console.log(t),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+t.message,"error"),e("#wpdiscuz-loading-bar").fadeOut(250)}else R(s,i,t)}var c,p;!function(e){if((a||o)&&"2.0"===d){var t=B(e);grecaptcha.reset(T[t])}}(e(".wpdiscuz_unique_id",s).val()),e(".wpdiscuz_reset").val("")}else wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj.wc_msg_required_fields,"error")}),e(document).delegate(".wpd_editable_comment","click",function(){w&&e(".wpdiscuz-edit-form-wrap").length&&q(V(e(".wpdiscuz-edit-form-wrap"),0),w);var t=V(e(this),0),a=B(t),o=new FormData;o.append("action","wpdEditComment"),o.append("commentId",a),w=e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-text").get(0),ce(z,!0,o).done(function(a){if("object"==typeof a)if(a.success){if(e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd-comment-text").replaceWith(a.data.html),wpdiscuzLoadRichEditor){let o=wpDiscuzEditor.createEditor("#wpd-editor-edit_"+t);o.clipboard.dangerouslyPasteHTML(0,a.data.content),o.update(),e(".wpd-toolbar-hidden").prev("[id^=wpd-editor-]").css("border-bottom","1px solid #dddddd")}else e("#wc-textarea-edit_"+t).val(a.data.content);e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd_editable_comment").hide(),e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").hide()}else wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error");else console.log(a);e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wc_save_edited_comment","click",function(){var t=V(e(this)),a=B(t),o=e("#wpd-comm-"+t+" #wpdiscuz-edit-form");if(J(o,"#wpd-editor-edit_"+t),o.submit(function(e){e.preventDefault()}),o[0].checkValidity()){var d=new FormData;d.append("action","wpdSaveEditedComment"),d.append("commentId",a),e(":input",o).each(function(){""!==this.name&&"checkbox"!==this.type&&"radio"!==this.type&&d.append(this.name+"",e(this).val()),"checkbox"!==this.type&&"radio"!==this.type||e(this).is(":checked")&&d.append(this.name+"",e(this).val())}),ce(z,!0,d).done(function(o){"object"==typeof o?(o.success?(q(t,o.data.message),o.data.lastEdited&&(e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-last-edited").remove(),e(o.data.lastEdited).insertAfter("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-right .wpd-comment-text")),o.data.twitterShareLink&&e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-share .wpd-tooltip-content .wc_tw").attr("href",o.data.twitterShareLink),o.data.whatsappShareLink&&e("#wpd-comm-"+t+" > .wpd-comment-wrap .wpd-comment-share .wpd-tooltip-content .wc_whatsapp").attr("href",o.data.whatsappShareLink),wpdiscuzLoadRichEditor&&wpDiscuzEditor.removeEditor("#wpd-editor-edit_"+t)):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[o.data],"error"),ie(o,a)):console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(document).delegate(".wc_cancel_edit","click",function(){var t=V(e(this));q(t,w),wpdiscuzLoadRichEditor&&wpDiscuzEditor.removeEditor("#wpd-editor-edit_"+t)}),!wpdiscuzAjaxObj.wordpressIsPaginate&&m&&(M=0,1==m?setTimeout(function(){W(!0)},500):e(document).delegate(".wpd-load-comments","click",function(){e(this).remove(),W(!0)})),e(document).delegate(".wpd-load-more-submit","click",function(){var t=e(this);t.hasClass("wpd-loaded")&&W(!1,t,"wpd-loaded","wpd-loading")});var U=!1;function H(){var t=e("#wpdiscuzHasMoreComments").val(),a=e(document).height(),o=e(window).height()+e(window).scrollTop();a&&o&&(100*o/a>=80&&!1===U&&1==t&&(U=!0,W(!1,e(".wpd-load-more-submit"))))}function W(t,a,o,d){a&&(a.toggleClass(o),a.toggleClass(d));var s=new FormData;s.append("action","wpdLoadMoreComments");var i=e(".wpdiscuz-sort-button-active").attr("data-sorting");i&&s.append("sorting",i),s.append("offset",M),s.append("lastParentId",e(".wpd-load-more-submit").attr("data-lastparentid")),s.append("isFirstLoad",t?1:0);var c=e(".wpdf-active").attr("data-filter-type");s.append("wpdType",c||""),ce(z,!0,s).done(function(s){"object"==typeof s&&s.success&&(M++,e(".wpdiscuz-comment-pagination").before(s.data.comment_list),K(s,t&&2!==n),e(".wpdiscuz_single").remove(),U=!1,r=s.data.loadLastCommentId,ie(s),t&&P(!1)),e("#wpdiscuz-loading-bar").fadeOut(250),e(".wpd-load-more-submit").blur(),a&&(a.toggleClass(o),a.toggleClass(d))}).fail(function(t,n,s){console.log(s),e("#wpdiscuz-loading-bar").fadeOut(250),e(".wpd-load-more-submit").blur(),a&&(a.toggleClass(o),a.toggleClass(d))})}function K(t,a){var o;0==t.data.is_show_load_more?(e("#wpdiscuzHasMoreComments").val(0),e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").hide()):(o=t.data.last_parent_id,e(".wpd-load-more-submit").attr("data-lastparentid",o),2!==n&&e(".wpdiscuz-comment-pagination").show(),e("#wpdiscuzHasMoreComments").val(1),a&&e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").show()),ie(t)}function P(t){var a=location.href.match(/#comment\-(\d+)/);if(null!==a){var o=a[1];if(e("#comment-"+o).length)setTimeout(function(){e("html, body").animate({scrollTop:e("#comment-"+o).parents("[id^=wpd-comm-]").offset().top-32},1e3),t&&N(o)},500);else{var d=new FormData;d.append("action","wpdGetSingleComment"),d.append("commentId",o),ce(z,!0,d).done(function(a){if("object"==typeof a&&a.success){var d="#comment-"+o;e("#comment-"+a.data.parentCommentID).length?e("#comment-"+a.data.parentCommentID).parents("[id^=wpd-comm-"+a.data.parentCommentID+"]").replaceWith(a.data.message):e(".wpd-thread-list").prepend(a.data.message),ie(a),e("html, body").animate({scrollTop:e(d).offset().top-32},1e3),t&&N(o)}e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}}function N(t){setTimeout(function(){e("#comment-"+t).siblings(".wpd-secondary-form-wrapper").is(":visible")||e("#comment-"+t).find(".wpd-reply-button").trigger("click")},1100)}function Q(e){if(void 0!==e.data.message)for(var t,a=e.data.message,o=0;o<a.length;o++)$((t=a[o]).comment_parent,t.comment_html)}function V(e,t){var a="";return(a=t?e.parents(".wpd-main-form-wrapper").attr("id"):e.parents(".wpd-comment").attr("id")).substring(a.lastIndexOf("-")+1)}function B(e){return e.substring(0,e.indexOf("_"))}function G(e,t){return t?e.substring(e.indexOf("-")+1):e.substring(0,e.indexOf("-"))}function $(t,a){if(0==t)X(a);else{var o=V(e("#comment-"+t),0);e("#wpdiscuz_form_anchor-"+o).after(a)}}function Y(){var t,a,o="";return e(".wpd-comment-right").each(function(){t=V(e(this),0),a=B(t),o+=a+","}),o}function J(t,a){var o=t.find(".wpd-required-group");wpdiscuzLoadRichEditor&&t.find(".wc_comment").val(e(a+">.ql-editor").html()),function(e){var t=e.find(".wc_comment"),a=t.val().trim().replace(/<p><br><\/p>/g,"&nbsp;\n").replace(/<p>(.*?)<\/p>/g,"$1\n");a=(a=(a=(a=a.replace(/<img src=["|']https\:\/\/s\.w\.org\/images\/core\/emoji\/([^"|']+)["|'](.*?)alt=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$3")).replace(/<img[^>]+alt=["|']([^"|']+)["|'][^>]+src=["|']https\:\/\/s\.w\.org\/images\/core\/emoji\/([^"|']+)["|'][^>]?>/g,"$1")).replace(/<img\s+([^>]*)class=["|']wpdem\-sticker["|'](.*?)alt=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$3")).replace(/<img\s+([^>]*)src=["|']([^"|']+)["|'](.*?)[^>]*>/g,"$2"),t.val(a)}(t),e.each(o,function(){e("input",this).removeAttr("required"),0===e("input:checked",this).length?e("input",e(this)).attr("required","required"):e(".wpd-field-invalid",this).remove()})}function X(t){e(".wpd-sticky-comment").last()[0]?e(t).insertAfter(e(".wpd-sticky-comment").last()[0]):e(".wpd-thread-list").prepend(t)}function Z(t){t?t.prop("required")||(t.val()?t.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","inline-block"):t.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","none")):e.each(e(".wc_email"),function(t,a){var o=e(a);o.prop("required")||(o.val()?o.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","inline-block"):o.parents("form").find("[name=wpdiscuz_notification_type]").parent().css("display","none"))})}if(2!==n||wpdiscuzAjaxObj.wordpressIsPaginate||(e(".wpd-load-more-submit").parents(".wpdiscuz-comment-pagination").hide(),H(),e(window).scroll(function(){H()})),wpdiscuzAjaxObj.setLoadMoreVisibility=K,e(document).delegate(".wpd-vote-up.wpd_not_clicked, .wpd-vote-down.wpd_not_clicked","click",function(){var t=e(this);e(t).removeClass("wpd_not_clicked");var a,o=B(V(t));a=e(this).hasClass("wpd-vote-up")?1:-1;var d=new FormData;d.append("action","wpdVoteOnComment"),d.append("commentId",o),d.append("voteType",a),ce(z,!0,d).done(function(d){if(e(t).addClass("wpd_not_clicked"),"object"==typeof d){if(d.success){if("total"===d.data.buttonsStyle){var n=e(".wpd-comment-footer .wpd-vote-result",e("#comment-"+o)),s=d.data.votes;n.text(s),n.removeClass("wpd-up wpd-down"),s>0&&n.addClass("wpd-up"),s<0&&n.addClass("wpd-down")}else{var i=e(".wpd-comment-footer .wpd-vote-result-like",e("#comment-"+o)),c=e(".wpd-comment-footer .wpd-vote-result-dislike",e("#comment-"+o));i.text(d.data.likeCount),c.text(d.data.dislikeCount),parseInt(d.data.likeCount)>0?i.addClass("wpd-up"):i.removeClass("wpd-up"),parseInt(d.data.dislikeCount)<0?c.addClass("wpd-down"):c.removeClass("wpd-down")}var p=e(".wpd-comment-footer .wpd-vote-up",e("#comment-"+o)),r=e(".wpd-comment-footer .wpd-vote-down",e("#comment-"+o));p.removeClass("wpd-up"),r.removeClass("wpd-down"),d.data.curUserReaction>0?p.addClass("wpd-up"):d.data.curUserReaction<0&&r.addClass("wpd-down")}else d.data&&wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[d.data],"error");ie(d,o,a)}else console.log(d);e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(a,o,d){console.log(d),e(t).addClass("wpd_not_clicked"),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate("body","click",function(t){var a=e(".wpdiscuz-sort-buttons");e(t.target).hasClass("wpdf-sorting")||e(t.target).parent().hasClass("wpdf-sorting")?a.css({display:a.is(":visible")?"none":"flex"}):a.hide()}),e(document).delegate(".wpdiscuz-sort-button:not(.wpdiscuz-sort-button-active)","click",function(){var t=e(this),a=e(this).attr("data-sorting");if(a){e(".wpdiscuz-sort-button.wpdiscuz-sort-button-active").removeClass("wpdiscuz-sort-button-active").appendTo(".wpdiscuz-sort-buttons"),t.addClass("wpdiscuz-sort-button-active").prependTo(".wpdf-sorting");var o=new FormData;o.append("action","wpdSorting"),o.append("sorting",a);var d=e(".wpdf-active").attr("data-filter-type");o.append("wpdType",d||""),ce(z,!0,o).done(function(t){"object"==typeof t&&t.success&&(e("#wpdcom .wpd-comment").remove(),e("#wpdcom .wpd-thread-list").prepend(t.data.message),K(t,!1),M=1),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),window.onhashchange=function(){P(!1)},1!=m&&P(!1),e(document).delegate(".wpdiscuz-readmore","click",function(){var t=V(e(this)),a=B(t),o=new FormData;o.append("action","wpdReadMore"),o.append("commentId",a),ce(z,!0,o).done(function(o){"object"==typeof o?(o.success?(e("#comment-"+a+" .wpd-comment-text").html(" "+o.data.message),e("#wpdiscuz-readmore-"+t).remove()):console.log(o.data),ie(o)):console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-required-group","change",function(){0!==e("input:checked",this).length?e("input",e(this)).removeAttr("required"):e("input",e(this)).attr("required","required")}),e(document).delegate(".wpdiscuz-spoiler","click",function(){e(this).next().slideToggle(),e(this).hasClass("wpdiscuz-spoiler-closed")?e(this).parents(".wpdiscuz-spoiler-wrap").find(".fa-plus").removeClass("fa-plus").addClass("fa-minus"):e(this).parents(".wpdiscuz-spoiler-wrap").find(".fa-minus").removeClass("fa-minus").addClass("fa-plus"),e(this).toggleClass("wpdiscuz-spoiler-closed")}),e(document).delegate(".wpd-tools i","click",function(){var t=e(this).siblings(".wpd-tools-actions");t.css({display:t.is(":visible")?"none":"flex"})}),e(document).delegate(".wpd-comment-right","mouseleave",function(){e(this).find(".wpd-tools-actions").hide()}),e(document).delegate(".wpd_stick_btn","click",function(){var t=B(V(e(this),0)),a=new FormData;a.append("action","wpdStickComment"),a.append("commentId",t),ce(z,!0,a).done(function(t){"object"==typeof t&&t.success&&location.reload(!0),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd_close_btn","click",function(){var t=B(V(e(this),0)),a=new FormData;a.append("action","wpdCloseThread"),a.append("commentId",t),ce(z,!0,a).done(function(t){"object"==typeof t&&t.success&&location.reload(!0),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-filter.wpd_not_clicked[data-filter-type]","click",function(){var t=e(this),a=t.attr("data-filter-type");wpdiscuzAjaxObj.resetActiveFilters(".wpdf-"+a),t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var o=new FormData;o.append("action","wpdLoadMoreComments");var d=e(".wpdiscuz-sort-button-active").attr("data-sorting");d&&o.append("sorting",d),o.append("lastParentId",0),o.append("offset",0),M=1,o.append("wpdType",t.hasClass("wpdf-active")?"":a),o.append("isFirstLoad",1),e(this).hasClass("wpdf-inline")?e(this).hasClass("wpdf-active")?e(".wpd-comment-info-bar").hide():e(".wpd-comment-info-bar").css("display","flex"):e(".wpd-comment-info-bar").hide(),ce(z,!1,o).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(t.toggleClass("wpdf-active"),e(".wpd-load-comments").remove(),e(".wpd-comment").remove(),e(".wpd-thread-list").prepend(a.data.comment_list),K(a),r=a.data.loadLastCommentId,e(".wpd-load-more-submit").blur(),ie(a)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpdf-reacted.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=new FormData;a.append("action","wpdMostReactedComment"),ce(z,!1,a).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(e("#comment-"+a.data.parentCommentID).length?e("#comment-"+a.data.parentCommentID).parents("[id^=wpd-comm-"+a.data.parentCommentID+"]").replaceWith(a.data.message):e("#comment-"+a.data.commentId).length||e(".wpd-thread-list").prepend(a.data.message),ie(a),e("html, body").animate({scrollTop:e("#comment-"+a.data.commentId).offset().top-32},1e3))}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner")})}),e(document).delegate(".wpdf-hottest.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=new FormData;a.append("action","wpdHottestThread"),ce(z,!1,a).done(function(a){t.addClass("wpd_not_clicked"),e(".fas",t).removeClass("fa-pulse fa-spinner"),"object"==typeof a&&a.success&&(e("#comment-"+a.data.commentId).length?e("#comment-"+a.data.commentId).parents("[id^=wpd-comm-"+a.data.commentId+"]").replaceWith(a.data.message):e(".wpd-thread-list").prepend(a.data.message),ie(a),e("html, body").animate({scrollTop:e("#comment-"+a.data.commentId).offset().top-32},1e3))}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner")})}),e(document).delegate(".wpd-filter-view-all","click",function(){e(".wpdf-inline.wpdf-active.wpd_not_clicked").trigger("click")}),e(document).delegate(".wpd-follow-link.wpd_not_clicked","click",function(){var t=e(this);t.removeClass("wpd_not_clicked"),e(".fas",t).addClass("fa-pulse fa-spinner");var a=B(V(t,0)),o=new FormData;o.append("action","wpdFollowUser"),o.append("commentId",a),ce(z,!0,o).done(function(a){t.addClass("wpd_not_clicked"),"object"==typeof a?a.success?(wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data.code],"success"),t.removeClass("wpd-follow-active"),a.data.followTip&&t.attr("wpd-tooltip",a.data.followTip),a.data.followClass&&t.addClass(a.data.followClass)):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"):console.log(a),e(".fas",t).removeClass("fa-pulse fa-spinner"),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(a,o,d){console.log(d),e(".fas",t).removeClass("fa-pulse fa-spinner"),e("#wpdiscuz-loading-bar").fadeOut(250)})}),Z(),e(document).delegate(".wc_email","keyup",function(){Z(e(this))}),j){if(e("#wpd-bubble-wrapper").hover(function(){e(this).addClass("wpd-bubble-hover")},function(){e(this).removeClass("wpd-bubble-hover")}),k&&!Cookies.get(wpdiscuzAjaxObj.cookieHideBubbleHint)&&setTimeout(function(){e("#wpd-bubble-wrapper").addClass("wpd-bubble-hover"),Cookies.set(wpdiscuzAjaxObj.cookieHideBubbleHint,"1",{expires:7,path:"/"}),setTimeout(function(){e("#wpd-bubble-wrapper").removeClass("wpd-bubble-hover")},1e3*x)},1e3*k),"content_left"===O)if(e(".entry-content").length){var ee=(te=Math.min(e(".entry-content").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else if(e(".post-entry").length){ee=(te=Math.min(e(".post-entry").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else if(e(".container").length){var te;ee=(te=Math.min(e(".container").offset().left,e("#wpdcom").offset().left)-120)>25?te:25;e("#wpd-bubble-wrapper").css({left:ee+"px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-content")}else e("#wpd-bubble-wrapper").css({left:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-corner");else"left_corner"===O?(e("#wpd-bubble-wrapper").css({left:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-left-corner")):"right_corner"===O&&(e("#wpd-bubble-wrapper").css({right:"25px"}),e("#wpd-bubble-wrapper").addClass("wpd-right-corner"));e("#wpd-bubble-wrapper").show(),e("#wpd-bubble-add-message-close").click(function(t){t.preventDefault(),t.stopPropagation(),e("#wpd-bubble-wrapper").removeClass("wpd-bubble-hover")}),e("#wpd-bubble").click(function(){e("html, body").animate({scrollTop:e("#wpdcom").offset().top-60},1e3,function(){wpdiscuzLoadRichEditor?wpDiscuzEditor.createEditor("#wpd-editor-0_0").focus():e("#wc-textarea-0_0").focus()})}),e("#wpd-bubble-comment-close").click(function(t){t.preventDefault(),e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added")}),e("#wpd-bubble-comment-reply-link a").click(function(){var t=e(this).attr("href");setTimeout(function(){e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added"),P(!0);var a=t.match(/#comment\-(\d+)/);D=D.filter(function(e){return e!=a[1]}),e("#wpd-bubble-count .wpd-new-comments-count").text(D.length),0==D.length&&e("#wpd-bubble-count").removeClass("wpd-new-comments")},100)}),e("#wpd-bubble-count").click(function(){if(D.length){var t=new FormData;t.append("action","wpdBubbleUpdate"),t.append("newCommentIds",D.join()),ce(z,!0,t).done(function(t){"object"==typeof t&&t.success&&(t.data.message=t.data.message.filter(function(t){if(!e("#comment-"+t.comment_id).length)return t}),Q(t),e("#wpd-bubble-count").removeClass("wpd-new-comments"),e("#wpd-bubble-count .wpd-new-comments-count").text("0"),D=[],e("html, body").animate({scrollTop:e(e(".wpd-new-loaded-comment")[0]).offset().top-60},1e3),ie(t)),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(e,t,a){console.log(a)})}})}if((j&&C||i)&&(t||!t&&p)&&setTimeout(function t(){e.ajax({type:"GET",url:wpdiscuzAjaxObj.bubbleUpdateUrl,data:{postId:s,lastId:l,visibleCommentIds:Y()}}).done(function(a){if(!E)if("object"==typeof a){if(a.ids.length){i&&((n=new FormData).append("action","wpdUpdateAutomatically"),n.append("loadLastCommentId",r),n.append("visibleCommentIds",Y()),ce(z,!1,n).done(function(t){E||"object"==typeof t&&t.success&&(Q(t),e(".wpd-thread-info").html(t.data.wc_all_comments_count_new_html),t.data.wc_all_comments_count_new=parseInt(t.data.wc_all_comments_count_new),e("#wpd-bubble-all-comments-count").text(t.data.wc_all_comments_count_new),t.data.wc_all_comments_count_new?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),r=t.data.loadLastCommentId)}).fail(function(e,t,a){console.log(a)})),a.ids=a.ids.filter(function(t){if(!e("#comment-"+t).length)return t});var o=5e3;l=parseInt(a.ids[a.ids.length-1]),D=D.concat(a.ids),y&&a.commentText&&(e("#wpd-bubble-author-avatar").html(a.avatar),e("#wpd-bubble-author-name").html(a.authorName),e("#wpd-bubble-comment-date span").html(a.commentDate),e("#wpd-bubble-comment-text").html(a.commentText),e("#wpd-bubble-comment-reply-link a").attr("href",a.commentLink),e("#wpd-bubble-notification-message").show(),o=1e4);var d=parseInt(e(".wpd-new-comments-count").text());d+=a.ids.length,e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added"),e("#wpd-bubble-wrapper").addClass("wpd-new-comment-added"),setTimeout(function(){e("#wpd-bubble-notification-message").hide(),e("#wpd-bubble-wrapper").removeClass("wpd-new-comment-added")},o),e(".wpd-new-comments-count").text(d),e("#wpd-bubble-count").addClass("wpd-new-comments"),a.all_comments_count=parseInt(a.all_comments_count),e("#wpd-bubble-all-comments-count").text(a.all_comments_count),a.all_comments_count?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),e(".wpd-thread-info").html(a.all_comments_count_html)}}else console.log(a);var n;setTimeout(t,c)}).fail(function(e,a,o){console.log(o),setTimeout(t,c)})},c),e(".wpd-inline-form-wrapper").length){var ae=new FormData;ae.append("action","wpdGetInlineCommentForm"),ce(z,!1,ae).done(function(t){"object"==typeof t?t.success?(e(".wpd-inline-form-wrapper").append(t.data),e.each(e("[name=_wpd_inline_nonce]"),function(){var t=e(this).attr("id"),a=e(this).parents(".wpd-inline-shortcode").attr("id");e(this).attr("id",t+"-"+a.substring(a.lastIndexOf("-")+1))}),e(".wpd-inline-opened").addClass("wpd-active"),e(".wpd-inline-opened").find(".wpd-inline-form-wrapper").show(),e(".wpd-inline-opened").find(".wpd-inline-icon").addClass("wpd-open"),e(".wpd-inline-opened").find(".wpd-inline-icon").removeClass("wpd-ignored"),se()):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error"):console.log(t)}).fail(function(e,t,a){console.log(a)})}function oe(t){if(e(t).hasClass("wpd-inline-shortcode"))var a=e(t).attr("id");else a=e(t).parents(".wpd-inline-shortcode").attr("id");return a.substring(a.lastIndexOf("-")+1)}function de(){e(".wpd-inline-form-wrapper").hide(),e(".wpd-inline-shortcode").removeClass("wpd-active"),e(".wpd-inline-icon").removeClass("wpd-open")}function ne(){e.each(e(".wpd-inline-shortcode:not(.wpd-inline-opened) .wpd-inline-icon"),function(){var t=e(this),a=t.offset().top-window.pageYOffset;a>0&&a<300&&("blink"===A?(t.addClass("wpd-blink"),setTimeout(function(){t.removeClass("wpd-blink")},3e3)):(t.parents(".wpd-inline-shortcode").addClass("wpd-active"),t.siblings(".wpd-inline-form-wrapper").show(),t.addClass("wpd-open"),se(t.siblings(".wpd-inline-form-wrapper"))))})}function se(t){if(t){if(t.offset().left<=10)t.css("left",Math.ceil(parseInt(t.css("left"))-t.offset().left+10)),(a=Math.ceil(t.siblings(".wpd-inline-icon.wpd-open").offset().left-t.offset().left+2))<3&&(a=3),document.styleSheets[0].addRule("#"+t.parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+a+"px;");else if(t.offset().left+t.width()>document.body.clientWidth-10){var a;t.css("left",Math.ceil(parseInt(t.css("left"))+(document.body.clientWidth-(t.offset().left+t.width()))-10)),(a=Math.ceil(t.siblings(".wpd-inline-icon.wpd-open").offset().left-t.offset().left+2))>t.width()-3&&(a=t.width()-3),document.styleSheets[0].addRule("#"+t.parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+a+"px;")}}else e.each(e(".wpd-inline-form-wrapper:visible"),function(){if(e(this).offset().left<=10)e(this).css("left",Math.ceil(parseInt(e(this).css("left"))-e(this).offset().left+10)),(t=Math.ceil(e(this).siblings(".wpd-inline-icon.wpd-open").offset().left-e(this).offset().left+2))<3&&(t=3),document.styleSheets[0].addRule("#"+e(this).parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+t+"px;");else if(e(this).offset().left+e(this).width()>document.body.clientWidth-10){var t;e(this).css("left",Math.ceil(parseInt(e(this).css("left"))+(document.body.clientWidth-(e(this).offset().left+e(this).width()))-10)),(t=Math.ceil(e(this).siblings(".wpd-inline-icon.wpd-open").offset().left-e(this).offset().left+2))>e(this).width()-3&&(t=e(this).width()-3),document.styleSheets[0].addRule("#"+e(this).parents(".wpd-inline-shortcode").attr("id")+" .wpd-inline-form-wrapper::before","left: "+t+"px;")}})}function ie(t,a,o,d){t.data.callbackFunctions&&e.each(t.data.callbackFunctions,function(e){"function"==typeof wpdiscuzAjaxObj[t.data.callbackFunctions[e]]?wpdiscuzAjaxObj[t.data.callbackFunctions[e]](t,a,o,d):console.log(t.data.callbackFunctions[e]+" is not a function")})}function ce(t,a,o){a&&e("#wpdiscuz-loading-bar").show(),o.append("postId",s);var d=o.get("action");wpdiscuzAjaxObj.dataFilterCallbacks&&wpdiscuzAjaxObj.dataFilterCallbacks[d]&&e.each(wpdiscuzAjaxObj.dataFilterCallbacks[d],function(e){"function"==typeof wpdiscuzAjaxObj[wpdiscuzAjaxObj.dataFilterCallbacks[d][e]]&&(o=wpdiscuzAjaxObj[wpdiscuzAjaxObj.dataFilterCallbacks[d][e]](o,t,a))});var n=t?wpdiscuzAjaxObj.url:wpdiscuzAjaxObj.customAjaxUrl;return e.ajax({type:"POST",url:n,data:o,contentType:!1,processData:!1})}e(document).delegate("body","click",function(t){if(e(t.target).hasClass("wpd-inline-form-close")||e(t.target).parents(".wpd-inline-form-close").length)t.preventDefault(),e(t.target).parents(".wpd-inline-form-wrapper").hide(),e(t.target).parents(".wpd-inline-shortcode").removeClass("wpd-active"),e(t.target).parents(".wpd-inline-form-wrapper").siblings(".wpd-inline-icon").removeClass("wpd-open");else if(!e(t.target).hasClass("wpd-inline-form-wrapper")&&!e(t.target).parents(".wpd-inline-form-wrapper").length){de();var a="";e(t.target).hasClass("wpd-inline-icon")?a=e(t.target):e(t.target).parents(".wpd-inline-icon").length&&(a=e(t.target).parents(".wpd-inline-icon")),a.length&&(a.parents(".wpd-inline-shortcode").addClass("wpd-active"),a.siblings(".wpd-inline-form-wrapper").show(),a.addClass("wpd-open"),a.removeClass("wpd-ignored"),se(a.siblings(".wpd-inline-form-wrapper")))}(!e(t.target).hasClass("wpd-last-inline-comments-wrapper")&&!e(t.target).parents(".wpd-last-inline-comments-wrapper").length||e(t.target).parents(".wpd-last-inline-comments-wrapper").length&&e(t.target).hasClass("wpd-load-inline-comment"))&&e(".wpd-last-inline-comments-wrapper").remove()}),e(document).delegate(".wpd-inline-submit.wpd_not_clicked","click",function(t){t.preventDefault();var a=e(this),o=e(this).parents(".wpd_inline_comm_form");if(o[0].checkValidity()){e(this).removeClass("wpd_not_clicked");var d=new FormData;d.append("action","wpdAddInlineComment"),d.append("inline_form_id",oe(o)),e.each(e("input, textarea",o),function(t,a){"checkbox"===this.type?e(this).is(":checked")&&d.append(e(a).attr("name"),e(a).val()):d.append(e(a).attr("name"),e(a).val())}),ce(z,!0,d).done(function(t){if(a.addClass("wpd_not_clicked"),"object"==typeof t)if(t.success){o[0].reset(),de();var d=parseInt(t.data.newCount),n=a.parents(".wpd-inline-icon-wrapper").find(".wpd-inline-icon-count");n.text(d),d?n.addClass("wpd-has-comments"):n.removeClass("wpd-has-comments"),e(".wpd-thread-info").html(t.data.allCommentsCountNewHtml),t.data.allCommentsCountNew=parseInt(t.data.allCommentsCountNew),e("#wpd-bubble-all-comments-count").text(t.data.allCommentsCountNew),t.data.allCommentsCountNew?e("#wpd-bubble-all-comments-count").show():e("#wpd-bubble-all-comments-count").hide(),t.data.message&&X(t.data.message),wpdiscuzAjaxObj.setCommentMessage(t.data.notification,"success")}else t.data&&wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error");else wpdiscuzAjaxObj.setCommentMessage(t,"error");e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(document).delegate(".wpd-form","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).find(".wc_comm_submit").trigger("click")}),e(document).delegate("#wpdiscuz-edit-form","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).find(".wc_save_edited_comment").trigger("click")}),e(document).delegate(".wpd-inline-comment-content","keydown",function(t){t.ctrlKey&&13==t.keyCode&&e(this).parents(".wpd_inline_comm_form").find(".wpd-inline-submit.wpd_not_clicked").trigger("click")}),e(document).delegate(".wpd-inline-icon-count.wpd-has-comments","click",function(){var t=e(this),a=new FormData;a.append("action","wpdGetLastInlineComments"),a.append("inline_form_id",oe(t)),ce(z,!0,a).done(function(a){"object"==typeof a?a.success?e(a.data).insertAfter(t):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[a.data],"error"):console.log(a),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),e(document).delegate(".wpd-view-all-inline-comments","click",function(t){t.preventDefault(),e(this).parents(".wpd-last-inline-comments-wrapper").remove(),e(".wpdf-inline").hasClass("wpdf-active")||e(".wpdf-inline").trigger("click"),e("html, body").animate({scrollTop:e(".wpdf-inline").offset().top-32},1e3)}),e(document).delegate(".wpd-feedback-content-link","click",function(t){t.preventDefault();var a=e(this).data("feedback-content-id");e("html, body").animate({scrollTop:e("#wpd-inline-"+a).offset().top-38},1e3,function(){e("#wpd-inline-"+a).addClass("wpd-active")})}),"scroll_open"!==A&&"blink"!==A||(ne(),e(window).scroll(ne)),e(document).delegate("#wpd-post-rating.wpd-not-rated .wpd-rate-starts svg","click",function(){var t=new FormData,a=e(this).index();a>=0&&a<5&&(t.append("action","wpdUserRate"),t.append("rating",a+1),ce(z,!0,t).done(function(t){"object"==typeof t?t.success?location.reload(!0):wpdiscuzAjaxObj.setCommentMessage(wpdiscuzAjaxObj[t.data],"error"):console.log(t),e("#wpdiscuz-loading-bar").fadeOut(250)}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)}))}),e("#wpdiscuz-subscribe-form").submit(function(t){t.preventDefault();var a,o,n=e(this);if(n[0].checkValidity()&&(a=n,o=!0,"2.0"===d&&e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).length&&!e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).val().length?(o=!1,e(".wpdiscuz-recaptcha",a).css("border","1px solid red")):"2.0"===d&&e("input[name=wpdiscuz_recaptcha_subscribe_form]",a).length&&e(".wpdiscuz-recaptcha",a).css("border","none"),o)){var s=new FormData;s.append("action","wpdAddSubscription"),e("*",n).each(function(){""!=this.name&&"checkbox"!=this.type&&"radio"!=this.type&&s.append(this.name+"",e(this).val()),"checkbox"!=this.type&&"radio"!=this.type||e(this).is(":checked")&&s.append(this.name+"",e(this).val())}),ce(z,!0,s).done(function(t){"object"==typeof t?t.success?(wpdiscuzAjaxObj.setCommentMessage(t.data,"success"),setTimeout(function(){location.reload(!0)},3e3)):wpdiscuzAjaxObj.setCommentMessage(t.data,"error"):wpdiscuzAjaxObj.setCommentMessage(t,"error"),e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}}),e(".wpd-unsubscribe").click(function(t){t.preventDefault();var a=new FormData;a.append("action","wpdUnsubscribe"),a.append("sid",e(this).data("sid")),a.append("skey",e(this).data("skey")),ce(z,!0,a).done(function(t){"object"==typeof t?t.success?(wpdiscuzAjaxObj.setCommentMessage(t.data,"success"),setTimeout(function(){location.reload(!0)},3e3)):wpdiscuzAjaxObj.setCommentMessage(t.data,"error"):console.log(t),e("#wpdiscuz-loading-bar").fadeOut(250),E=!1}).fail(function(t,a,o){console.log(o),e("#wpdiscuz-loading-bar").fadeOut(250)})}),wpdiscuzAjaxObj.resetActiveFilters=function(t){e(".wpd-filter.wpdf-active"+(t?":not("+t+")":"")).removeClass("wpdf-active")},wpdiscuzAjaxObj.getAjaxObj=ce});var onloadCallback=function(){if(document.getElementById("wpdiscuz-recaptcha-0_0")&&"2.0"===wpdiscuzAjaxObj.wpDiscuzReCaptchaVersion&&(1==wpdiscuzAjaxObj.wc_captcha_show_for_guest&&!wpdiscuzAjaxObj.is_user_logged_in||1==wpdiscuzAjaxObj.wc_captcha_show_for_members&&wpdiscuzAjaxObj.is_user_logged_in))try{grecaptcha.render("wpdiscuz-recaptcha-0_0",{sitekey:wpdiscuzAjaxObj.wpDiscuzReCaptchaSK,theme:wpdiscuzAjaxObj.wpDiscuzReCaptchaTheme,callback:function(e){jQuery("#wpdiscuz-recaptcha-field-0_0").val("key")},"expired-callback":function(){jQuery("#wpdiscuz-recaptcha-field-0_0").val("")}})}catch(e){console.log(e),wpdiscuzAjaxObj.setCommentMessage("reCaptcha Error: "+e.message,"error")}};
class.WpdiscuzCore.php CHANGED
@@ -2,12 +2,13 @@
2
  /*
3
  * Plugin Name: wpDiscuz
4
  * Description: #1 WordPress Comment Plugin. Innovative, modern and feature-rich comment system to supercharge your website comment section.
5
- * Version: 7.0.1
6
  * Author: gVectors Team
7
  * Author URI: https://gvectors.com/
8
  * Plugin URI: https://wpdiscuz.com/
9
  * Text Domain: wpdiscuz
10
  * Domain Path: /languages/
 
11
  */
12
  if (!defined("ABSPATH")) {
13
  exit();
@@ -142,6 +143,9 @@ class WpdiscuzCore implements WpDiscuzConstants {
142
  add_action("wp_ajax_nopriv_wpdAddInlineComment", [&$this, "addInlineComment"]);
143
  add_action("wp_footer", [&$this, "footerContents"]);
144
  add_action("enqueue_block_editor_assets", [&$this, "gutenbergButton"]);
 
 
 
145
  }
146
 
147
  public static function getInstance() {
@@ -151,6 +155,29 @@ class WpdiscuzCore implements WpDiscuzConstants {
151
  return self::$_instance;
152
  }
153
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
154
  public function pluginActivation($networkwide) {
155
  if (function_exists("is_multisite") && is_multisite() && $networkwide) {
156
  $oldBlogID = $this->dbManager->getBlogID();
@@ -430,6 +457,9 @@ class WpdiscuzCore implements WpDiscuzConstants {
430
  do_action("wpdiscuz_after_comment_post", $newComment, $currentUser);
431
  $response["callbackFunctions"] = [];
432
  $response = apply_filters("wpdiscuz_comment_post", $response);
 
 
 
433
  wp_send_json_success($response);
434
  } else {
435
  wp_send_json_error("wc_invalid_field");
@@ -500,6 +530,7 @@ class WpdiscuzCore implements WpDiscuzConstants {
500
  $username = $lastEditedBy ? $lastEditedBy->display_name : $comment->comment_author;
501
  $response["lastEdited"] = "<div class='wpd-comment-last-edited'><i class='far fa-edit'></i>" . esc_html(sprintf($this->options->phrases["wc_last_edited"], $this->helper->dateDiff($lastEditedAt), $username)) . "</div>";
502
  }
 
503
  }
504
 
505
  $form->saveCommentMeta($comment->comment_ID);
@@ -1347,6 +1378,9 @@ class WpdiscuzCore implements WpDiscuzConstants {
1347
  if (version_compare($this->version, "5.2.1", "<=")) {
1348
  $oldOptions["isNativeAjaxEnabled"] = 1;
1349
  }
 
 
 
1350
  return $oldOptions;
1351
  }
1352
 
@@ -1942,6 +1976,9 @@ class WpdiscuzCore implements WpDiscuzConstants {
1942
  $response["notification"] = esc_html($this->options->phrases["wc_feedback_comment_success"]);
1943
  $response["allCommentsCountNew"] = esc_html(get_comments_number($inline_form->post_id));
1944
  $response["allCommentsCountNewHtml"] = "<span class='wpdtc'>" . esc_html($response["allCommentsCountNew"]) . "</span> " . esc_html(1 == $response["allCommentsCountNew"] ? $form->getHeaderTextSingle() : $form->getHeaderTextPlural());
 
 
 
1945
  wp_send_json_success($response);
1946
  } else {
1947
  wp_send_json_error("wc_invalid_field");
2
  /*
3
  * Plugin Name: wpDiscuz
4
  * Description: #1 WordPress Comment Plugin. Innovative, modern and feature-rich comment system to supercharge your website comment section.
5
+ * Version: 7.0.2
6
  * Author: gVectors Team
7
  * Author URI: https://gvectors.com/
8
  * Plugin URI: https://wpdiscuz.com/
9
  * Text Domain: wpdiscuz
10
  * Domain Path: /languages/
11
+ * wpDiscuz Update: auto
12
  */
13
  if (!defined("ABSPATH")) {
14
  exit();
143
  add_action("wp_ajax_nopriv_wpdAddInlineComment", [&$this, "addInlineComment"]);
144
  add_action("wp_footer", [&$this, "footerContents"]);
145
  add_action("enqueue_block_editor_assets", [&$this, "gutenbergButton"]);
146
+
147
+ add_filter("extra_plugin_headers", [&$this, "extraPluginHeaders"]);
148
+ add_filter("auto_update_plugin", [&$this, "shouldUpdate"], 10, 2);
149
  }
150
 
151
  public static function getInstance() {
155
  return self::$_instance;
156
  }
157
 
158
+ public function extraPluginHeaders($headers) {
159
+ $headers[] = "wpDiscuz Update";
160
+ return $headers;
161
+ }
162
+
163
+ public function shouldUpdate($shouldUpdate, $plugin) {
164
+ if (!isset($plugin->plugin, $plugin->new_version)) {
165
+ return $shouldUpdate;
166
+ }
167
+
168
+ if ("wpdiscuz/class.WpdiscuzCore.php" !== $plugin->plugin) {
169
+ return $shouldUpdate;
170
+ }
171
+
172
+ $pluginData = get_plugin_data(__FILE__);
173
+
174
+ if (isset($pluginData["wpDiscuz Update"]) && $pluginData["wpDiscuz Update"] === "manual") {
175
+ return false;
176
+ }
177
+
178
+ return $shouldUpdate;
179
+ }
180
+
181
  public function pluginActivation($networkwide) {
182
  if (function_exists("is_multisite") && is_multisite() && $networkwide) {
183
  $oldBlogID = $this->dbManager->getBlogID();
457
  do_action("wpdiscuz_after_comment_post", $newComment, $currentUser);
458
  $response["callbackFunctions"] = [];
459
  $response = apply_filters("wpdiscuz_comment_post", $response);
460
+ if (apply_filters("wpdiscuz_clean_cache_after_comment_post", true)) {
461
+ clean_post_cache($postId);
462
+ }
463
  wp_send_json_success($response);
464
  } else {
465
  wp_send_json_error("wc_invalid_field");
530
  $username = $lastEditedBy ? $lastEditedBy->display_name : $comment->comment_author;
531
  $response["lastEdited"] = "<div class='wpd-comment-last-edited'><i class='far fa-edit'></i>" . esc_html(sprintf($this->options->phrases["wc_last_edited"], $this->helper->dateDiff($lastEditedAt), $username)) . "</div>";
532
  }
533
+ clean_post_cache($comment->comment_post_ID);
534
  }
535
 
536
  $form->saveCommentMeta($comment->comment_ID);
1378
  if (version_compare($this->version, "5.2.1", "<=")) {
1379
  $oldOptions["isNativeAjaxEnabled"] = 1;
1380
  }
1381
+ if (version_compare($this->version, "7.0.0", ">=") && version_compare($this->version, "7.0.2", "<")) {
1382
+ $oldOptions[self::TAB_RATING]["enablePostRatingSchema"] = 0;
1383
+ }
1384
  return $oldOptions;
1385
  }
1386
 
1976
  $response["notification"] = esc_html($this->options->phrases["wc_feedback_comment_success"]);
1977
  $response["allCommentsCountNew"] = esc_html(get_comments_number($inline_form->post_id));
1978
  $response["allCommentsCountNewHtml"] = "<span class='wpdtc'>" . esc_html($response["allCommentsCountNew"]) . "</span> " . esc_html(1 == $response["allCommentsCountNew"] ? $form->getHeaderTextSingle() : $form->getHeaderTextPlural());
1979
+ if (apply_filters("wpdiscuz_clean_cache_after_comment_post", true)) {
1980
+ clean_post_cache($postId);
1981
+ }
1982
  wp_send_json_success($response);
1983
  } else {
1984
  wp_send_json_error("wc_invalid_field");
forms/wpdFormAttr/Field/ColorField.php CHANGED
@@ -85,8 +85,8 @@ class ColorField extends Field {
85
  <div class="wpd-field-icon"><i style="opacity: 0.8;" class="<?php echo strpos(trim($args["icon"]), " ") ? esc_attr($args["icon"]) : "fas " . esc_attr($args["icon"]); ?>"></i></div>
86
  <?php } ?>
87
  <?php $required = $args["required"] ? "required='required'" : ""; ?>
88
- <input id="<?php echo esc_attr($name); ?>" <?php echo $required; ?> class="<?php echo esc_attr($name); ?> wpd-field wpd-field-color" type="color" name="<?php echo esc_attr($name); ?>" value="#000000" placeholder="#ff8040" pattern="^\#[A-Za-z0-9]{6}$" title="#ff8040">
89
- <label for="<?php echo esc_attr($name); ?>" class="wpdlb"><?php echo esc_attr($args["name"]) . (!empty($args["required"]) ? "*" : ""); ?></label>
90
  <?php if ($args["desc"]) { ?>
91
  <div class="wpd-field-desc"><i class="far fa-question-circle"></i><span><?php echo esc_html($args["desc"]); ?></span></div>
92
  <?php } ?>
85
  <div class="wpd-field-icon"><i style="opacity: 0.8;" class="<?php echo strpos(trim($args["icon"]), " ") ? esc_attr($args["icon"]) : "fas " . esc_attr($args["icon"]); ?>"></i></div>
86
  <?php } ?>
87
  <?php $required = $args["required"] ? "required='required'" : ""; ?>
88
+ <input id="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" <?php echo $required; ?> class="<?php echo esc_attr($name); ?> wpd-field wpd-field-color" type="color" name="<?php echo esc_attr($name); ?>" value="#000000" placeholder="#ff8040" pattern="^\#[A-Za-z0-9]{6}$" title="#ff8040">
89
+ <label for="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" class="wpdlb"><?php echo esc_attr($args["name"]) . (!empty($args["required"]) ? "*" : ""); ?></label>
90
  <?php if ($args["desc"]) { ?>
91
  <div class="wpd-field-desc"><i class="far fa-question-circle"></i><span><?php echo esc_html($args["desc"]); ?></span></div>
92
  <?php } ?>
forms/wpdFormAttr/Field/DateField.php CHANGED
@@ -85,8 +85,8 @@ class DateField extends Field {
85
  <div class="wpd-field-icon"><i style="opacity: 0.8;" class="<?php echo strpos(trim($args["icon"]), " ") ? esc_attr($args["icon"]) : "fas " . esc_attr($args["icon"]); ?>"></i></div>
86
  <?php } ?>
87
  <?php $required = $args["required"] ? "required='required'" : ""; ?>
88
- <input id="<?php echo esc_attr($name); ?>" <?php echo $required; ?> class="<?php echo esc_attr($name); ?> wpd-field wpd-field-date" type="date" name="<?php echo esc_attr($name); ?>" value="" placeholder="03/28/2016<?php echo!empty($args["required"]) ? "*" : "" ?>" pattern="^(1[0-2]|0[1-9])/(3[01]|[12][0-9]|0[1-9])/[0-9]{4}$" title="03/28/2016">
89
- <label for="<?php echo esc_attr($name); ?>" class="wpdlb"><?php echo esc_attr($args["name"]) . (!empty($args["required"]) ? "*" : ""); ?></label>
90
  <?php if ($args["desc"]) { ?>
91
  <div class="wpd-field-desc"><i class="far fa-question-circle"></i><span><?php echo esc_html($args["desc"]); ?></span></div>
92
  <?php } ?>
85
  <div class="wpd-field-icon"><i style="opacity: 0.8;" class="<?php echo strpos(trim($args["icon"]), " ") ? esc_attr($args["icon"]) : "fas " . esc_attr($args["icon"]); ?>"></i></div>
86
  <?php } ?>
87
  <?php $required = $args["required"] ? "required='required'" : ""; ?>
88
+ <input id="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" <?php echo $required; ?> class="<?php echo esc_attr($name); ?> wpd-field wpd-field-date" type="date" name="<?php echo esc_attr($name); ?>" value="" placeholder="03/28/2016<?php echo!empty($args["required"]) ? "*" : "" ?>" pattern="^(1[0-2]|0[1-9])/(3[01]|[12][0-9]|0[1-9])/[0-9]{4}$" title="03/28/2016">
89
+ <label for="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" class="wpdlb"><?php echo esc_attr($args["name"]) . (!empty($args["required"]) ? "*" : ""); ?></label>
90
  <?php if ($args["desc"]) { ?>
91
  <div class="wpd-field-desc"><i class="far fa-question-circle"></i><span><?php echo esc_html($args["desc"]); ?></span></div>
92
  <?php } ?>
forms/wpdFormAttr/Field/DefaultField/Email.php CHANGED
@@ -52,8 +52,8 @@ class Email extends Field {
52
  }
53
  $required = $args["required"] ? "required='required'" : "";
54
  ?>
55
- <input id="<?php echo esc_attr($name); ?>" value="" <?php echo $required; ?> class="<?php echo esc_attr($name); ?> wpd-field" type="email" name="<?php echo esc_attr($name); ?>" placeholder="<?php echo esc_attr($args["name"]) . (!empty($args["required"]) ? "*" : ""); ?>" />
56
- <label for="<?php echo esc_attr($name); ?>" class="wpdlb"><?php echo esc_attr($args["name"]) . (!empty($args["required"]) ? "*" : ""); ?></label>
57
  <?php if ($args["desc"]) { ?>
58
  <div class="wpd-field-desc"><i class="far fa-question-circle"></i><span><?php echo esc_html($args["desc"]); ?></span></div>
59
  <?php } ?>
52
  }
53
  $required = $args["required"] ? "required='required'" : "";
54
  ?>
55
+ <input id="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" value="" <?php echo $required; ?> class="<?php echo esc_attr($name); ?> wpd-field" type="email" name="<?php echo esc_attr($name); ?>" placeholder="<?php echo esc_attr($args["name"]) . (!empty($args["required"]) ? "*" : ""); ?>" />
56
+ <label for="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" class="wpdlb"><?php echo esc_attr($args["name"]) . (!empty($args["required"]) ? "*" : ""); ?></label>
57
  <?php if ($args["desc"]) { ?>
58
  <div class="wpd-field-desc"><i class="far fa-question-circle"></i><span><?php echo esc_html($args["desc"]); ?></span></div>
59
  <?php } ?>
forms/wpdFormAttr/Field/DefaultField/Name.php CHANGED
@@ -52,8 +52,8 @@ class Name extends Field {
52
  }
53
  $required = $args["required"] ? "required='required'" : "";
54
  ?>
55
- <input id="<?php echo esc_attr($name); ?>" value="" <?php echo $required; ?> class="<?php echo esc_attr($name); ?> wpd-field" type="text" name="<?php echo esc_attr($name); ?>" placeholder="<?php echo esc_attr__($args["name"], "wpdiscuz") . (!empty($args["required"]) ? "*" : ""); ?>" maxlength="<?php echo esc_attr($options->form["commenterNameMaxLength"]); ?>" <?php echo $nameLengthRange; ?> title="">
56
- <label for="<?php echo esc_attr($name); ?>" class="wpdlb"><?php echo esc_attr($args["name"]) . (!empty($args["required"]) ? "*" : ""); ?></label>
57
  <?php if ($args["desc"]) { ?>
58
  <div class="wpd-field-desc"><i class="far fa-question-circle"></i><span><?php echo esc_html($args["desc"]); ?></span></div>
59
  <?php } ?>
52
  }
53
  $required = $args["required"] ? "required='required'" : "";
54
  ?>
55
+ <input id="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" value="" <?php echo $required; ?> class="<?php echo esc_attr($name); ?> wpd-field" type="text" name="<?php echo esc_attr($name); ?>" placeholder="<?php echo esc_attr__($args["name"], "wpdiscuz") . (!empty($args["required"]) ? "*" : ""); ?>" maxlength="<?php echo esc_attr($options->form["commenterNameMaxLength"]); ?>" <?php echo $nameLengthRange; ?> title="">
56
+ <label for="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" class="wpdlb"><?php echo esc_attr($args["name"]) . (!empty($args["required"]) ? "*" : ""); ?></label>
57
  <?php if ($args["desc"]) { ?>
58
  <div class="wpd-field-desc"><i class="far fa-question-circle"></i><span><?php echo esc_html($args["desc"]); ?></span></div>
59
  <?php } ?>
forms/wpdFormAttr/Field/DefaultField/Website.php CHANGED
@@ -49,8 +49,8 @@ class Website extends Field {
49
  <?php if ($hasIcon) { ?>
50
  <div class="wpd-field-icon"><i class="<?php echo strpos(trim($args["icon"]), " ") ? esc_attr($args["icon"]) : "fas " . esc_attr($args["icon"]); ?>"></i></div>
51
  <?php } ?>
52
- <input id="<?php echo esc_attr($name); ?>" value="" class="<?php echo $name; ?> wpd-field" type="text" name="<?php echo htmlentities($name, ENT_QUOTES); ?>" placeholder="<?php echo htmlentities($args["name"], ENT_QUOTES); ?>" />
53
- <label for="<?php echo esc_attr($name); ?>" class="wpdlb"><?php echo htmlentities($args["name"], ENT_QUOTES); ?></label>
54
  <?php if ($args["desc"]) { ?>
55
  <div class="wpd-field-desc"><i class="far fa-question-circle"></i><span><?php echo esc_html($args["desc"]); ?></span></div>
56
  <?php } ?>
49
  <?php if ($hasIcon) { ?>
50
  <div class="wpd-field-icon"><i class="<?php echo strpos(trim($args["icon"]), " ") ? esc_attr($args["icon"]) : "fas " . esc_attr($args["icon"]); ?>"></i></div>
51
  <?php } ?>
52
+ <input id="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" value="" class="<?php echo $name; ?> wpd-field" type="text" name="<?php echo htmlentities($name, ENT_QUOTES); ?>" placeholder="<?php echo htmlentities($args["name"], ENT_QUOTES); ?>" />
53
+ <label for="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" class="wpdlb"><?php echo htmlentities($args["name"], ENT_QUOTES); ?></label>
54
  <?php if ($args["desc"]) { ?>
55
  <div class="wpd-field-desc"><i class="far fa-question-circle"></i><span><?php echo esc_html($args["desc"]); ?></span></div>
56
  <?php } ?>
forms/wpdFormAttr/Field/NumberField.php CHANGED
@@ -98,8 +98,8 @@ class NumberField extends Field {
98
  $min = is_numeric($args["min"]) ? "min='" . $args["min"] . "'" : "";
99
  $max = is_numeric($args["max"]) ? "max='" . $args["max"] . "'" : "";
100
  ?>
101
- <input id="<?php echo esc_attr($name); ?>" <?php echo $required; ?> class="<?php echo esc_attr($name); ?> wpd-field wpd-field-number" type="number" name="<?php echo esc_attr($name); ?>" value="" placeholder="<?php echo esc_html__($args["name"], "wpdiscuz") . (!empty($args["required"]) ? "*" : ""); ?>" <?php echo $min . " " . $max; ?>>
102
- <label for="<?php echo esc_attr($name); ?>" class="wpdlb"><?php echo esc_html__($args["name"], "wpdiscuz") . (!empty($args["required"]) ? "*" : ""); ?></label>
103
  <?php if ($args["desc"]) { ?>
104
  <div class="wpd-field-desc"><i class="far fa-question-circle"></i><span><?php echo $args["desc"]; ?></span></div>
105
  <?php } ?>
98
  $min = is_numeric($args["min"]) ? "min='" . $args["min"] . "'" : "";
99
  $max = is_numeric($args["max"]) ? "max='" . $args["max"] . "'" : "";
100
  ?>
101
+ <input id="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" <?php echo $required; ?> class="<?php echo esc_attr($name); ?> wpd-field wpd-field-number" type="number" name="<?php echo esc_attr($name); ?>" value="" placeholder="<?php echo esc_html__($args["name"], "wpdiscuz") . (!empty($args["required"]) ? "*" : ""); ?>" <?php echo $min . " " . $max; ?>>
102
+ <label for="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" class="wpdlb"><?php echo esc_html__($args["name"], "wpdiscuz") . (!empty($args["required"]) ? "*" : ""); ?></label>
103
  <?php if ($args["desc"]) { ?>
104
  <div class="wpd-field-desc"><i class="far fa-question-circle"></i><span><?php echo $args["desc"]; ?></span></div>
105
  <?php } ?>
forms/wpdFormAttr/Field/RadioField.php CHANGED
@@ -100,7 +100,8 @@ class RadioField extends Field {
100
  <input id="<?php echo esc_attr($name) . "-" . esc_attr($index + 1) . "_" . esc_attr($uniqueId); ?>" type="radio" name="<?php echo esc_attr($name); ?>" value="<?php echo esc_attr($index + 1); ?>" class="<?php echo esc_attr($name); ?> wpd-field" >
101
  <label class="wpd-field-label wpd-cursor-pointer" for="<?php echo esc_attr($name) . "-" . esc_attr($index + 1) . "_" . esc_attr($uniqueId); ?>"><?php echo esc_html($val); ?></label>
102
  </div>
103
- <?php }
 
104
  ?>
105
  </div>
106
  </div>
100
  <input id="<?php echo esc_attr($name) . "-" . esc_attr($index + 1) . "_" . esc_attr($uniqueId); ?>" type="radio" name="<?php echo esc_attr($name); ?>" value="<?php echo esc_attr($index + 1); ?>" class="<?php echo esc_attr($name); ?> wpd-field" >
101
  <label class="wpd-field-label wpd-cursor-pointer" for="<?php echo esc_attr($name) . "-" . esc_attr($index + 1) . "_" . esc_attr($uniqueId); ?>"><?php echo esc_html($val); ?></label>
102
  </div>
103
+ <?php
104
+ }
105
  ?>
106
  </div>
107
  </div>
forms/wpdFormAttr/Field/TextAreaField.php CHANGED
@@ -70,8 +70,8 @@ class TextAreaField extends Field {
70
  ?>
71
  <div class="wpdiscuz-item <?php echo "$name-wrapper"; ?>">
72
  <?php $required = $args["required"] ? "required='required'" : ""; ?>
73
- <textarea id="<?php echo esc_attr($name); ?>" <?php echo $required; ?> class="<?php echo esc_attr($name); ?> wpd-field wpd-field-textarea" name="<?php echo esc_attr($name); ?>" value="" placeholder="<?php echo esc_attr__($args["name"], "wpdiscuz") . (!empty($args["required"]) ? "*" : ""); ?>"></textarea>
74
- <label for="<?php echo esc_attr($name); ?>" class="wpdlb"><?php echo esc_attr__($args["name"], "wpdiscuz") . (!empty($args["required"]) ? "*" : ""); ?></label>
75
  <?php if ($args["desc"]) { ?>
76
  <div class="wpd-field-desc"><i class="far fa-question-circle"></i><span><?php echo esc_html($args["desc"]); ?></span></div>
77
  <?php } ?>
70
  ?>
71
  <div class="wpdiscuz-item <?php echo "$name-wrapper"; ?>">
72
  <?php $required = $args["required"] ? "required='required'" : ""; ?>
73
+ <textarea id="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" <?php echo $required; ?> class="<?php echo esc_attr($name); ?> wpd-field wpd-field-textarea" name="<?php echo esc_attr($name); ?>" value="" placeholder="<?php echo esc_attr__($args["name"], "wpdiscuz") . (!empty($args["required"]) ? "*" : ""); ?>"></textarea>
74
+ <label for="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" class="wpdlb"><?php echo esc_attr__($args["name"], "wpdiscuz") . (!empty($args["required"]) ? "*" : ""); ?></label>
75
  <?php if ($args["desc"]) { ?>
76
  <div class="wpd-field-desc"><i class="far fa-question-circle"></i><span><?php echo esc_html($args["desc"]); ?></span></div>
77
  <?php } ?>
forms/wpdFormAttr/Field/TextField.php CHANGED
@@ -82,8 +82,8 @@ class TextField extends Field {
82
  <div class="wpd-field-icon"><i style="opacity: 0.8;" class="<?php echo strpos(trim($args["icon"]), " ") ? esc_attr($args["icon"]) : "fas " . esc_attr($args["icon"]); ?>"></i></div>
83
  <?php } ?>
84
  <?php $required = $args["required"] ? "required='required'" : ""; ?>
85
- <input id="<?php echo esc_attr($name); ?>" <?php echo $required; ?> class="<?php echo esc_attr($name); ?> wpd-field wpd-field-text" type="text" name="<?php echo esc_attr($name); ?>" value="" placeholder="<?php echo esc_attr__($args["name"], "wpdiscuz") . (!empty($args["required"]) ? "*" : ""); ?>">
86
- <label for="<?php echo esc_attr($name); ?>" class="wpdlb"><?php echo esc_attr($args["name"]) . (!empty($args["required"]) ? "*" : ""); ?></label>
87
  <?php if ($args["desc"]) { ?>
88
  <div class="wpd-field-desc"><i class="far fa-question-circle"></i><span><?php echo esc_html($args["desc"]); ?></span></div>
89
  <?php } ?>
82
  <div class="wpd-field-icon"><i style="opacity: 0.8;" class="<?php echo strpos(trim($args["icon"]), " ") ? esc_attr($args["icon"]) : "fas " . esc_attr($args["icon"]); ?>"></i></div>
83
  <?php } ?>
84
  <?php $required = $args["required"] ? "required='required'" : ""; ?>
85
+ <input id="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" <?php echo $required; ?> class="<?php echo esc_attr($name); ?> wpd-field wpd-field-text" type="text" name="<?php echo esc_attr($name); ?>" value="" placeholder="<?php echo esc_attr__($args["name"], "wpdiscuz") . (!empty($args["required"]) ? "*" : ""); ?>">
86
+ <label for="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" class="wpdlb"><?php echo esc_attr($args["name"]) . (!empty($args["required"]) ? "*" : ""); ?></label>
87
  <?php if ($args["desc"]) { ?>
88
  <div class="wpd-field-desc"><i class="far fa-question-circle"></i><span><?php echo esc_html($args["desc"]); ?></span></div>
89
  <?php } ?>
forms/wpdFormAttr/Field/UrlField.php CHANGED
@@ -87,8 +87,8 @@ class UrlField extends Field {
87
  }
88
  ?>
89
  <?php $required = $args["required"] ? "required='required'" : ""; ?>
90
- <input id="<?php echo esc_attr($name); ?>" <?php echo $required; ?> class="<?php echo esc_attr($name); ?> wpd-field" type="url" name="<?php echo esc_attr($name); ?>" value="" placeholder="<?php echo esc_attr__($args["name"], "wpdiscuz") . (!empty($args["required"]) ? "*" : ""); ?>">
91
- <label for="<?php echo esc_attr($name); ?>" class="wpdlb"><?php echo esc_attr($args["name"]) . (!empty($args["required"]) ? "*" : ""); ?></label>
92
  <?php
93
  if ($args["desc"]) {
94
  ?>
87
  }
88
  ?>
89
  <?php $required = $args["required"] ? "required='required'" : ""; ?>
90
+ <input id="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" <?php echo $required; ?> class="<?php echo esc_attr($name); ?> wpd-field" type="url" name="<?php echo esc_attr($name); ?>" value="" placeholder="<?php echo esc_attr__($args["name"], "wpdiscuz") . (!empty($args["required"]) ? "*" : ""); ?>">
91
+ <label for="<?php echo esc_attr($name) . "-" . $uniqueId; ?>" class="wpdlb"><?php echo esc_attr($args["name"]) . (!empty($args["required"]) ? "*" : ""); ?></label>
92
  <?php
93
  if ($args["desc"]) {
94
  ?>
forms/wpdFormAttr/Form.php CHANGED
@@ -401,23 +401,18 @@ class Form {
401
  $count = (int) get_post_meta($post->ID, wpdFormConst::POSTMETA_POST_RATING_COUNT, true);
402
  $prefix = (int) $rating;
403
  $suffix = $rating - $prefix;
404
- $showSchema = $this->wpdOptions->rating["enablePostRatingSchema"] && $count;
405
  $fullStarSVG = apply_filters("wpdiscuz_full_star_svg", "<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M0 0h24v24H0z' fill='none'/><path class='wpd-star' d='M12 17.27L18.18 21l-1.64-7.03L22 9.24l-7.19-.61L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21z'/><path d='M0 0h24v24H0z' fill='none'/></svg>", "post", "fas fa-star");
406
  $halfStarSVG = apply_filters("wpdiscuz_half_star_svg", "<svg xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' viewBox='0 0 24 24'><defs><path id='a' d='M0 0h24v24H0V0z'/></defs><clipPath id='b'><use xlink:href='#a' overflow='visible'/></clipPath><path class='wpd-star wpd-active' clip-path='url(#b)' d='M22 9.24l-7.19-.62L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21 12 17.27 18.18 21l-1.63-7.03L22 9.24zM12 15.4V6.1l1.71 4.04 4.38.38-3.32 2.88 1 4.28L12 15.4z'/></svg>", "post", "fas fa-star");
407
  $html .= "<div id='wpd-post-rating'{$class}>
408
- <div" . ($showSchema ? " itemscope itemtype='http://schema.org/Product'" : "") . " class='wpd-rating-wrap'>
409
  <div class='wpd-rating-left'></div>
410
  <div class='wpd-rating-data'>
411
- <div class='wpd-rating-value'" . ($showSchema ? " itemprop='aggregateRating' itemscope itemtype='http://schema.org/AggregateRating'" : "") . ">
412
- <span class='wpdrv'" . ($showSchema ? " itemprop='ratingValue'" : "") . ">" . esc_html($rating) . "</span>
413
- <span class='wpdrc'" . ($showSchema ? " itemprop='ratingCount'" : "") . ">" . esc_html($count) . "</span>
414
  <span class='wpdrt'>" . ((int) $count > 1 ? esc_html($this->wpdOptions->phrases["wc_votes_phrase"]) : esc_html($this->wpdOptions->phrases["wc_vote_phrase"])) . "</span>";
415
- if ($showSchema) {
416
- $html .= "<span style='display:none!important;' itemprop='bestRating'>5</span>
417
- <span style='display:none!important;' itemprop='worstRating'>1</span>";
418
- }
419
  $html .= "</div>
420
- <div class='wpd-rating-title'" . ($showSchema ? " itemprop='name'" : "") . ">" . esc_html($this->getPostRatingTitle()) . "</div>
421
  <div class='wpd-rating-stars'>";
422
  if ($prefix) {
423
  for ($i = 1; $i < 6; $i++) {
@@ -440,6 +435,9 @@ class Form {
440
  }
441
  $html .= "</div>
442
  <div class='wpd-rating-right'></div></div></div>";
 
 
 
443
  }
444
  return $html;
445
  }
@@ -514,12 +512,12 @@ class Form {
514
  $html .= $this->getSingleRatingHtml($key, $value, $atts);
515
  }
516
  if ($atts["itemprop"]) {
517
- $html .= $this->getRatingSchema($atts["metakey"], $ratingList);
518
  }
519
  } else {
520
  $html .= $this->getSingleRatingHtml($atts["metakey"], $ratingList[$atts["metakey"]], $atts);
521
  if ($atts["itemprop"] && $ratingList[$atts["metakey"]]["count"]) {
522
- $html .= $this->getRatingSchema($atts["metakey"], $ratingList);
523
  }
524
  }
525
  $html .= "</div>";
@@ -575,7 +573,7 @@ class Form {
575
  return $html;
576
  }
577
 
578
- private function getRatingSchema($key, $ratingList) {
579
  $average = 0;
580
  $count = 0;
581
  if ($key === "" || $key === "all") {
@@ -594,7 +592,7 @@ class Form {
594
  }
595
  $schema = "";
596
  if ($average) {
597
- $schema = "<div style='display: none;' itemscope itemtype='http://schema.org/Product'><meta itemprop='name' content='" . esc_attr__("Average Rating", "wpdiscuz") . "'><div style='display: none;' itemprop='aggregateRating' itemscope itemtype='http://schema.org/AggregateRating'><meta itemprop='bestRating' content='5'><meta itemprop='worstRating' content='1'><meta itemprop='ratingValue' content='" . esc_attr($average) . "'><meta itemprop='ratingCount' content='" . esc_attr($count) . "'></div></div>";
598
  }
599
  return $schema;
600
  }
@@ -830,12 +828,12 @@ class Form {
830
  <?php
831
  }
832
 
833
- private function renderTextEditor($uniqueId, $commentsCount, $data = "") {
834
  if ($this->wpdOptions->form["richEditor"] === "both" || (!wp_is_mobile() && $this->wpdOptions->form["richEditor"] === "desktop")) {
835
  ?>
836
  <div id="wpd-editor-wraper-<?php echo esc_attr($uniqueId); ?>" style="display: none;">
837
  <div id="wpd-editor-char-counter-<?php echo esc_attr($uniqueId); ?>" class="wpd-editor-char-counter"></div>
838
- <textarea id="wc-textarea-<?php echo esc_attr($uniqueId); ?>" required name="wc_comment" class="wc_comment wpd-field"><?php echo $data; ?></textarea>
839
  <div id="wpd-editor-<?php echo esc_attr($uniqueId); ?>"></div>
840
  <?php $this->renderTextEditorButtons($uniqueId); ?>
841
  </div>
@@ -847,7 +845,7 @@ class Form {
847
  $textarea_placeholder = $this->wpdOptions->phrases["wc_be_the_first_text"];
848
  }
849
  ?>
850
- <textarea id="wc-textarea-<?php echo esc_attr($uniqueId); ?>" placeholder="<?php echo esc_attr($textarea_placeholder); ?>" required name="wc_comment" class="wc_comment wpd-field"><?php echo $data; ?></textarea>
851
  <?php
852
  echo apply_filters("wpdiscuz_editor_buttons_html", "", $uniqueId);
853
  }
@@ -914,8 +912,9 @@ class Form {
914
  $uniqueId = $comment->comment_ID . "_" . $comment->comment_parent;
915
  $html = "<div class='wpdiscuz-edit-form-wrap'><form id='wpdiscuz-edit-form'>";
916
  $html .= "<div class='wpdiscuz-item wpdiscuz-textarea-wrap'>";
 
917
  ob_start();
918
- $this->renderTextEditor("edit_" . $uniqueId, 1, str_replace(["<code>", "</code>"], ["`", "`"], $comment->comment_content));
919
  $html .= ob_get_clean();
920
  $html .= "</div>";
921
  if ($this->formCustomFields) {
@@ -934,7 +933,7 @@ class Form {
934
  $html .= "<input type='hidden' name='wpdiscuz_unique_id' value='" . esc_attr($uniqueId) . "'>";
935
  $html .= "<div class='wc_save_wrap'><input class='wc_cancel_edit wpd-second-button' type='button' value='" . esc_attr($this->wpdOptions->phrases["wc_comment_edit_cancel_button"]) . "'><input id='wpd-field-submit-edit_" . esc_attr($uniqueId) . "' class='wc_save_edited_comment wpd-prim-button' type='submit' value='" . esc_attr($this->wpdOptions->phrases["wc_comment_edit_save_button"]) . "'></div>";
936
  $html .= "</form></div>";
937
- return $html;
938
  }
939
 
940
  public function renderEditAdminCommentForm($comment) {
401
  $count = (int) get_post_meta($post->ID, wpdFormConst::POSTMETA_POST_RATING_COUNT, true);
402
  $prefix = (int) $rating;
403
  $suffix = $rating - $prefix;
 
404
  $fullStarSVG = apply_filters("wpdiscuz_full_star_svg", "<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M0 0h24v24H0z' fill='none'/><path class='wpd-star' d='M12 17.27L18.18 21l-1.64-7.03L22 9.24l-7.19-.61L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21z'/><path d='M0 0h24v24H0z' fill='none'/></svg>", "post", "fas fa-star");
405
  $halfStarSVG = apply_filters("wpdiscuz_half_star_svg", "<svg xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' viewBox='0 0 24 24'><defs><path id='a' d='M0 0h24v24H0V0z'/></defs><clipPath id='b'><use xlink:href='#a' overflow='visible'/></clipPath><path class='wpd-star wpd-active' clip-path='url(#b)' d='M22 9.24l-7.19-.62L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21 12 17.27 18.18 21l-1.63-7.03L22 9.24zM12 15.4V6.1l1.71 4.04 4.38.38-3.32 2.88 1 4.28L12 15.4z'/></svg>", "post", "fas fa-star");
406
  $html .= "<div id='wpd-post-rating'{$class}>
407
+ <div class='wpd-rating-wrap'>
408
  <div class='wpd-rating-left'></div>
409
  <div class='wpd-rating-data'>
410
+ <div class='wpd-rating-value'>
411
+ <span class='wpdrv'>" . esc_html($rating) . "</span>
412
+ <span class='wpdrc'>" . esc_html($count) . "</span>
413
  <span class='wpdrt'>" . ((int) $count > 1 ? esc_html($this->wpdOptions->phrases["wc_votes_phrase"]) : esc_html($this->wpdOptions->phrases["wc_vote_phrase"])) . "</span>";
 
 
 
 
414
  $html .= "</div>
415
+ <div class='wpd-rating-title'>" . esc_html($this->getPostRatingTitle()) . "</div>
416
  <div class='wpd-rating-stars'>";
417
  if ($prefix) {
418
  for ($i = 1; $i < 6; $i++) {
435
  }
436
  $html .= "</div>
437
  <div class='wpd-rating-right'></div></div></div>";
438
+ if ($this->wpdOptions->rating["enablePostRatingSchema"] && $count) {
439
+ $html .= apply_filters("wpdiscuz_rating_schema", "<div style='display: none;' itemscope itemtype='http://schema.org/Product'><meta itemprop='name' content='" . esc_html($this->getPostRatingTitle()) . "'><div style='display: none;' itemprop='aggregateRating' itemscope itemtype='http://schema.org/AggregateRating'><meta itemprop='bestRating' content='5'><meta itemprop='worstRating' content='1'><meta itemprop='ratingValue' content='" . esc_html($rating) . "'><meta itemprop='ratingCount' content='" . esc_attr($count) . "'></div></div>", "post", $post->ID);
440
+ }
441
  }
442
  return $html;
443
  }
512
  $html .= $this->getSingleRatingHtml($key, $value, $atts);
513
  }
514
  if ($atts["itemprop"]) {
515
+ $html .= $this->getRatingSchema($atts["metakey"], $ratingList, $atts["postid"]);
516
  }
517
  } else {
518
  $html .= $this->getSingleRatingHtml($atts["metakey"], $ratingList[$atts["metakey"]], $atts);
519
  if ($atts["itemprop"] && $ratingList[$atts["metakey"]]["count"]) {
520
+ $html .= $this->getRatingSchema($atts["metakey"], $ratingList, $atts["postid"]);
521
  }
522
  }
523
  $html .= "</div>";
573
  return $html;
574
  }
575
 
576
+ private function getRatingSchema($key, $ratingList, $postId) {
577
  $average = 0;
578
  $count = 0;
579
  if ($key === "" || $key === "all") {
592
  }
593
  $schema = "";
594
  if ($average) {
595
+ $schema = apply_filters("wpdiscuz_rating_schema", "<div style='display: none;' itemscope itemtype='http://schema.org/Product'><meta itemprop='name' content='" . esc_attr__("Average Rating", "wpdiscuz") . "'><div style='display: none;' itemprop='aggregateRating' itemscope itemtype='http://schema.org/AggregateRating'><meta itemprop='bestRating' content='5'><meta itemprop='worstRating' content='1'><meta itemprop='ratingValue' content='" . esc_attr($average) . "'><meta itemprop='ratingCount' content='" . esc_attr($count) . "'></div></div>", $key, $postId);
596
  }
597
  return $schema;
598
  }
828
  <?php
829
  }
830
 
831
+ private function renderTextEditor($uniqueId, $commentsCount) {
832
  if ($this->wpdOptions->form["richEditor"] === "both" || (!wp_is_mobile() && $this->wpdOptions->form["richEditor"] === "desktop")) {
833
  ?>
834
  <div id="wpd-editor-wraper-<?php echo esc_attr($uniqueId); ?>" style="display: none;">
835
  <div id="wpd-editor-char-counter-<?php echo esc_attr($uniqueId); ?>" class="wpd-editor-char-counter"></div>
836
+ <textarea id="wc-textarea-<?php echo esc_attr($uniqueId); ?>" required name="wc_comment" class="wc_comment wpd-field"></textarea>
837
  <div id="wpd-editor-<?php echo esc_attr($uniqueId); ?>"></div>
838
  <?php $this->renderTextEditorButtons($uniqueId); ?>
839
  </div>
845
  $textarea_placeholder = $this->wpdOptions->phrases["wc_be_the_first_text"];
846
  }
847
  ?>
848
+ <textarea id="wc-textarea-<?php echo esc_attr($uniqueId); ?>" placeholder="<?php echo esc_attr($textarea_placeholder); ?>" required name="wc_comment" class="wc_comment wpd-field"></textarea>
849
  <?php
850
  echo apply_filters("wpdiscuz_editor_buttons_html", "", $uniqueId);
851
  }
912
  $uniqueId = $comment->comment_ID . "_" . $comment->comment_parent;
913
  $html = "<div class='wpdiscuz-edit-form-wrap'><form id='wpdiscuz-edit-form'>";
914
  $html .= "<div class='wpdiscuz-item wpdiscuz-textarea-wrap'>";
915
+ $content = str_replace(["<code>", "</code>"], ["`", "`"], ($this->wpdOptions->form["richEditor"] === "both" || (!wp_is_mobile() && $this->wpdOptions->form["richEditor"] === "desktop") ? str_replace(["</p>\n","<br />\n"],["</p><br>","<br />"],wpautop($comment->comment_content)) : $comment->comment_content));
916
  ob_start();
917
+ $this->renderTextEditor("edit_" . $uniqueId, 1);
918
  $html .= ob_get_clean();
919
  $html .= "</div>";
920
  if ($this->formCustomFields) {
933
  $html .= "<input type='hidden' name='wpdiscuz_unique_id' value='" . esc_attr($uniqueId) . "'>";
934
  $html .= "<div class='wc_save_wrap'><input class='wc_cancel_edit wpd-second-button' type='button' value='" . esc_attr($this->wpdOptions->phrases["wc_comment_edit_cancel_button"]) . "'><input id='wpd-field-submit-edit_" . esc_attr($uniqueId) . "' class='wc_save_edited_comment wpd-prim-button' type='submit' value='" . esc_attr($this->wpdOptions->phrases["wc_comment_edit_save_button"]) . "'></div>";
935
  $html .= "</form></div>";
936
+ return wp_send_json_success(['html'=>$html,'content'=>$content]);
937
  }
938
 
939
  public function renderEditAdminCommentForm($comment) {
forms/wpdFormAttr/Login/SocialLogin.php CHANGED
@@ -188,12 +188,11 @@ class SocialLogin {
188
  $providerData = Utils::getProviderByState($state);
189
  $provider = $providerData["provider"];
190
  $postID = $providerData["postID"];
191
- $postURL = $this->getPostLink($postID);
192
  if (!$state || ($provider != "facebook")) {
193
- $this->redirect($postURL, esc_html__("Facebook authentication failed (OAuth state does not exist).", "wpdiscuz"));
194
  }
195
  if (!$code) {
196
- $this->redirect($postURL, esc_html__("Facebook authentication failed (OAuth code does not exist).", "wpdiscuz"));
197
  }
198
  $fbCallBack = $this->createCallBackURL("facebook");
199
  $fbAccessTokenURL = "https://graph.facebook.com/v3.0/oauth/access_token";
@@ -205,32 +204,32 @@ class SocialLogin {
205
  $fbAccesTokenResponse = wp_remote_get($fbAccessTokenURL);
206
 
207
  if (is_wp_error($fbAccesTokenResponse)) {
208
- $this->redirect($postURL, $fbAccesTokenResponse->get_error_message());
209
  }
210
  $fbAccesTokenData = json_decode(wp_remote_retrieve_body($fbAccesTokenResponse), true);
211
  if (isset($fbAccesTokenData["error"])) {
212
- $this->redirect($postURL, $fbAccesTokenData["error"]["message"]);
213
  }
214
  $token = $fbAccesTokenData["access_token"];
215
  $appsecret_proof = hash_hmac("sha256", $token, trim($this->generalOptions->social["fbAppSecret"]));
216
  $fbGetUserDataURL = add_query_arg(["fields" => "id,first_name,last_name,picture,email", "access_token" => $token, "appsecret_proof" => $appsecret_proof], "https://graph.facebook.com/v3.0/me");
217
  $getFbUserResponse = wp_remote_get($fbGetUserDataURL);
218
  if (is_wp_error($getFbUserResponse)) {
219
- $this->redirect($postURL, $getFbUserResponse->get_error_message());
220
  }
221
  $fbUserData = json_decode(wp_remote_retrieve_body($getFbUserResponse), true);
222
  if (isset($fbUserData["error"])) {
223
- $this->redirect($postURL, $fbUserData["error"]["message"]);
224
  }
225
  if (empty($fbUserData["email"]) && $fbUserData["id"]) {
226
  $fbUserData["email"] = $fbUserData["id"] . "@facebook.com";
227
  }
228
  $uID = Utils::addUser($fbUserData, "facebook");
229
  if (is_wp_error($uID)) {
230
- $this->redirect($postURL, $uID->get_error_message());
231
  }
232
  $this->setCurrentUser($uID);
233
- $this->redirect($postURL);
234
  }
235
 
236
  // https://developers.facebook.com/docs/instagram-basic-display-api/getting-started
@@ -263,13 +262,12 @@ class SocialLogin {
263
  $providerData = Utils::getProviderByState($state);
264
  $provider = $providerData["provider"];
265
  $postID = $providerData["postID"];
266
- $postURL = $this->getPostLink($postID);
267
 
268
  if (!$state || ($provider != "instagram")) {
269
- $this->redirect($postURL, esc_html__("Instagram authentication failed (OAuth state does not exist).", "wpdiscuz"));
270
  }
271
  if (!$code) {
272
- $this->redirect($postURL, esc_html__("Instagram authentication failed (OAuth code does not exist).", "wpdiscuz"));
273
  }
274
  $instagramCallBack = site_url('/wpdiscuz_auth/instagram/');
275
  $instagramAccessTokenURL = "https://api.instagram.com/oauth/access_token";
@@ -281,11 +279,11 @@ class SocialLogin {
281
  $instagramAccesTokenResponse = wp_remote_post($instagramAccessTokenURL, ['body' => $accessTokenArgs]);
282
 
283
  if (is_wp_error($instagramAccesTokenResponse)) {
284
- $this->redirect($postURL, $instagramAccesTokenResponse->get_error_message());
285
  }
286
  $instagramAccesTokenData = json_decode(wp_remote_retrieve_body($instagramAccesTokenResponse), true);
287
  if (isset($instagramAccesTokenData["error"])) {
288
- $this->redirect($postURL, $instagramAccesTokenData["error"]["message"]);
289
  }
290
  $token = $instagramAccesTokenData["access_token"];
291
  $userID = $instagramAccesTokenData["user_id"];
@@ -294,21 +292,21 @@ class SocialLogin {
294
  $getInstagramUserResponse = wp_remote_get($instagramGetUserDataURL);
295
 
296
  if (is_wp_error($getInstagramUserResponse)) {
297
- $this->redirect($postURL, $getInstagramUserResponse->get_error_message());
298
  }
299
  $instagramUserData = json_decode(wp_remote_retrieve_body($getInstagramUserResponse), true);
300
  if (isset($instagramUserData["error"])) {
301
- $this->redirect($postURL, $instagramUserData["error"]["message"]);
302
  }
303
  if (empty($instagramUserData["email"]) && $userID) {
304
  $instagramUserData["email"] = $userID . "@instagram.com";
305
  }
306
  $uID = Utils::addUser($instagramUserData, "instagram");
307
  if (is_wp_error($uID)) {
308
- $this->redirect($postURL, $uID->get_error_message());
309
  }
310
  $this->setCurrentUser($uID);
311
- $this->redirect($postURL);
312
  }
313
 
314
  // https://console.developers.google.com/
@@ -342,12 +340,11 @@ class SocialLogin {
342
  $providerData = Utils::getProviderByState($state);
343
  $provider = $providerData["provider"];
344
  $postID = $providerData["postID"];
345
- $postURL = $this->getPostLink($postID);
346
  if (!$state || ($provider != "google")) {
347
- $this->redirect($postURL, esc_html__("Google authentication failed (OAuth state does not exist).", "wpdiscuz"));
348
  }
349
  if (!$code) {
350
- $this->redirect($postURL, esc_html__("Google authentication failed (OAuth code does not exist).", "wpdiscuz"));
351
  }
352
  $googleCallBack = $this->createCallBackURL("google");
353
  $googleAccessTokenURL = "https://www.googleapis.com/oauth2/v4/token";
@@ -358,28 +355,28 @@ class SocialLogin {
358
  "grant_type" => 'authorization_code'];
359
  $googleAccesTokenResponse = wp_remote_post($googleAccessTokenURL, ['body' => $accessTokenArgs]);
360
  if (is_wp_error($googleAccesTokenResponse)) {
361
- $this->redirect($postURL, $googleAccesTokenResponse->get_error_message());
362
  }
363
  $googleAccesTokenData = json_decode(wp_remote_retrieve_body($googleAccesTokenResponse), true);
364
  if (isset($googleAccesTokenData["error"])) {
365
- $this->redirect($postURL, $googleAccesTokenData["error_description"]);
366
  }
367
  $idToken = $googleAccesTokenData["id_token"];
368
  $getGoogleUserRataURL = add_query_arg(["id_token" => $idToken], 'https://oauth2.googleapis.com/tokeninfo');
369
  $googleUserDataResponse = wp_remote_get($getGoogleUserRataURL);
370
  if (is_wp_error($googleUserDataResponse)) {
371
- $this->redirect($postURL, $googleUserDataResponse->get_error_message());
372
  }
373
  $googleUserData = json_decode(wp_remote_retrieve_body($googleUserDataResponse), true);
374
  if (isset($googleUserData["error"])) {
375
- $this->redirect($postURL, $googleUserData["error_description"]);
376
  }
377
  $uID = Utils::addUser($googleUserData, "google");
378
  if (is_wp_error($uID)) {
379
- $this->redirect($postURL, $uID->get_error_message());
380
  }
381
  $this->setCurrentUser($uID);
382
- $this->redirect($postURL);
383
  }
384
 
385
  // https://docs.microsoft.com/en-us/linkedin/shared/authentication/authorization-code-flow?context=linkedin/context
@@ -412,13 +409,12 @@ class SocialLogin {
412
  $providerData = Utils::getProviderByState($state);
413
  $provider = $providerData["provider"];
414
  $postID = $providerData["postID"];
415
- $postURL = $this->getPostLink($postID);
416
 
417
  if (!$state || ($provider != "linkedin")) {
418
- $this->redirect($postURL, esc_html__("Linkedin authentication failed (OAuth state does not exist).", "wpdiscuz"));
419
  }
420
  if (!$code) {
421
- $this->redirect($postURL, esc_html__("Linkedin authentication failed (OAuth code does not exist).", "wpdiscuz"));
422
  }
423
  $linkedinCallBack = site_url('/wpdiscuz_auth/linkedin/');
424
  $linkedinAccessTokenURL = "https://www.linkedin.com/oauth/v2/accessToken";
@@ -430,11 +426,11 @@ class SocialLogin {
430
  $linkedinAccesTokenResponse = wp_remote_post($linkedinAccessTokenURL, ['body' => $accessTokenArgs]);
431
 
432
  if (is_wp_error($linkedinAccesTokenResponse)) {
433
- $this->redirect($postURL, $linkedinAccesTokenResponse->get_error_message());
434
  }
435
  $linkedinAccesTokenData = json_decode(wp_remote_retrieve_body($linkedinAccesTokenResponse), true);
436
  if (isset($linkedinAccesTokenData["error"])) {
437
- $this->redirect($postURL, $linkedinAccesTokenData["error_description"]);
438
  }
439
  $token = $linkedinAccesTokenData["access_token"];
440
 
@@ -471,12 +467,12 @@ class SocialLogin {
471
 
472
  $getLinkedinUserResponse = wp_remote_get($linkedinGetUserDataURL, $getLinkedinRequestArgs);
473
  if (is_wp_error($getLinkedinUserResponse)) {
474
- $this->redirect($postURL, $getLinkedinUserResponse->get_error_message());
475
  }
476
  $linkedinUserData = json_decode(wp_remote_retrieve_body($getLinkedinUserResponse), true);
477
 
478
  if (isset($linkedinUserData["error"])) {
479
- $this->redirect($postURL, $linkedinUserData["error_description"]);
480
  }
481
  if ($email) {
482
  $linkedinUserData["email"] = $email;
@@ -488,10 +484,10 @@ class SocialLogin {
488
 
489
  $uID = Utils::addUser($linkedinUserData, "linkedin");
490
  if (is_wp_error($uID)) {
491
- $this->redirect($postURL, $uID->get_error_message());
492
  }
493
  $this->setCurrentUser($uID);
494
- $this->redirect($postURL);
495
  }
496
 
497
  public function disqusLogin($postID, $response) {
@@ -523,12 +519,11 @@ class SocialLogin {
523
  $providerData = Utils::getProviderByState($state);
524
  $provider = $providerData["provider"];
525
  $postID = $providerData["postID"];
526
- $postURL = $this->getPostLink($postID);
527
  if (!$state || ($provider != "disqus")) {
528
- $this->redirect($postURL, esc_html__("Disqus authentication failed (OAuth state does not exist).", "wpdiscuz"));
529
  }
530
  if (!$code) {
531
- $this->redirect($postURL, esc_html__("Disqus authentication failed (OAuth code does not exist).", "wpdiscuz"));
532
  }
533
  $disqusCallBack = $this->createCallBackURL("disqus");
534
  $disqusAccessTokenURL = "https://disqus.com/api/oauth/2.0/access_token";
@@ -542,17 +537,17 @@ class SocialLogin {
542
  $disqusAccesTokenResponse = wp_remote_post($disqusAccessTokenURL, ["body" => $accessTokenArgs]);
543
 
544
  if (is_wp_error($disqusAccesTokenResponse)) {
545
- $this->redirect($postURL, $disqusAccesTokenResponse->get_error_message());
546
  }
547
  $disqusAccesTokenData = json_decode(wp_remote_retrieve_body($disqusAccesTokenResponse), true);
548
  if (isset($disqusAccesTokenData["error"])) {
549
- $this->redirect($postURL, $disqusAccesTokenData["error_description"]);
550
  }
551
  if (!isset($disqusAccesTokenData["access_token"])) {
552
- $this->redirect($postURL, esc_html__("Disqus authentication failed (access_token does not exist).", "wpdiscuz"));
553
  }
554
  if (!isset($disqusAccesTokenData["user_id"])) {
555
- $this->redirect($postURL, esc_html__("Disqus authentication failed (user_id does not exist).", "wpdiscuz"));
556
  }
557
  $userID = $disqusAccesTokenData["user_id"];
558
  $accesToken = $disqusAccesTokenData["access_token"];
@@ -564,20 +559,20 @@ class SocialLogin {
564
 
565
  $getDisqusUserResponse = wp_remote_get($disqusGetUserDataURL, ["body" => $disqusGetUserDataAttr]);
566
  if (is_wp_error($getDisqusUserResponse)) {
567
- $this->redirect($postURL, $getDisqusUserResponse->get_error_message());
568
  }
569
  $disqusUserData = json_decode(wp_remote_retrieve_body($getDisqusUserResponse), true);
570
  if (isset($disqusUserData["code"]) && $disqusUserData["code"] != 0) {
571
- $this->redirect($postURL, $disqusUserData["response"]);
572
  }
573
  $disqusUser = $disqusUserData["response"];
574
  $disqusUser["user_id"] = $userID;
575
  $uID = Utils::addUser($disqusUser, "disqus");
576
  if (is_wp_error($uID)) {
577
- $this->redirect($postURL, $uID->get_error_message());
578
  }
579
  $this->setCurrentUser($uID);
580
- $this->redirect($postURL);
581
  }
582
 
583
  //https://developer.wordpress.com/docs/oauth2/ https://developer.wordpress.com/docs/wpcc/
@@ -610,12 +605,11 @@ class SocialLogin {
610
  $providerData = Utils::getProviderByState($state);
611
  $provider = $providerData["provider"];
612
  $postID = $providerData["postID"];
613
- $postURL = $this->getPostLink($postID);
614
  if (!$state || ($provider != "wordpress")) {
615
- $this->redirect($postURL, esc_html__("Wordpress.com authentication failed (OAuth state does not exist).", "wpdiscuz"));
616
  }
617
  if (!$code) {
618
- $this->redirect($postURL, esc_html__("Wordpress.com authentication failed (OAuth code does not exist).", "wpdiscuz"));
619
  }
620
  $wordpressCallBack = $this->createCallBackURL("wordpress");
621
  $wordpressAccessTokenURL = "https://public-api.wordpress.com/oauth2/token";
@@ -629,14 +623,14 @@ class SocialLogin {
629
  $wordpressAccesTokenResponse = wp_remote_post($wordpressAccessTokenURL, ["body" => $accessTokenArgs]);
630
 
631
  if (is_wp_error($wordpressAccesTokenResponse)) {
632
- $this->redirect($postURL, $wordpressAccesTokenResponse->get_error_message());
633
  }
634
  $wordpressAccesTokenData = json_decode(wp_remote_retrieve_body($wordpressAccesTokenResponse), true);
635
  if (isset($wordpressAccesTokenData["error"])) {
636
- $this->redirect($postURL, $wordpressAccesTokenData["error_description"]);
637
  }
638
  if (!isset($wordpressAccesTokenData["access_token"])) {
639
- $this->redirect($postURL, esc_html__("Wordpress.com authentication failed (access_token does not exist).", "wpdiscuz"));
640
  }
641
  $accesToken = $wordpressAccesTokenData["access_token"];
642
  $wordpressAccesTokenValidateURL = "https://public-api.wordpress.com/oauth2/token-info";
@@ -644,11 +638,11 @@ class SocialLogin {
644
  $wordpressAccesTokenValidateURL = add_query_arg($accesTokenValidateArgs, $wordpressAccesTokenValidateURL);
645
  $accesTokenValidateResponse = wp_remote_get($wordpressAccesTokenValidateURL, $accesTokenValidateArgs);
646
  if (is_wp_error($accesTokenValidateResponse)) {
647
- $this->redirect($postURL, $accesTokenValidateResponse->get_error_message());
648
  }
649
  $accesTokenValidateData = json_decode(wp_remote_retrieve_body($accesTokenValidateResponse), true);
650
  if (!isset($accesTokenValidateData["user_id"]) || !$accesTokenValidateData["user_id"]) {
651
- $this->redirect($postURL, esc_html__("Wordpress.com authentication failed (user_id does not exist).", "wpdiscuz"));
652
  }
653
 
654
  $wordpressGetUserDataURL = "https://public-api.wordpress.com/rest/v1/me/";
@@ -657,18 +651,18 @@ class SocialLogin {
657
  $getWordpressUserResponse = wp_remote_get($wordpressGetUserDataURL, ["headers" => $wordpressGetUserDataAttr]);
658
 
659
  if (is_wp_error($getWordpressUserResponse)) {
660
- $this->redirect($postURL, $getWordpressUserResponse->get_error_message());
661
  }
662
  $wordpressUserData = json_decode(wp_remote_retrieve_body($getWordpressUserResponse), true);
663
  if (isset($wordpressUserData["error"])) {
664
- $this->redirect($postURL, $wordpressUserData["message"]);
665
  }
666
  $uID = Utils::addUser($wordpressUserData, "wordpress");
667
  if (is_wp_error($uID)) {
668
- $this->redirect($postURL, $uID->get_error_message());
669
  }
670
  $this->setCurrentUser($uID);
671
- $this->redirect($postURL);
672
  }
673
 
674
  // https://apps.twitter.com/
@@ -698,9 +692,8 @@ class SocialLogin {
698
  $oauthSecretData = Utils::getProviderByState($oauthToken);
699
  $oauthSecret = $oauthSecretData["provider"];
700
  $postID = $oauthSecretData["postID"];
701
- $postURL = $this->getPostLink($postID);
702
  if (!$oauthVerifier || !$oauthSecret) {
703
- $this->redirect($postURL, esc_html__("Twitter authentication failed (OAuth secret does not exist).", "wpdiscuz"));
704
  }
705
  $twitter = new TwitterOAuth($this->generalOptions->social["twitterAppID"], $this->generalOptions->social["twitterAppSecret"], $oauthToken, $oauthSecret);
706
  try {
@@ -710,15 +703,15 @@ class SocialLogin {
710
  if (!empty($twitterUser->id)) {
711
  $uID = Utils::addUser($twitterUser, "twitter");
712
  if (is_wp_error($uID)) {
713
- $this->redirect($postURL, $uID->get_error_message());
714
  }
715
  $this->setCurrentUser($uID);
716
- $this->redirect($postURL);
717
  } else {
718
- $this->redirect($postURL, esc_html__("Twitter connection failed.", "wpdiscuz"));
719
  }
720
  } catch (TwitterOAuthException $e) {
721
- $this->redirect($postURL, $e->getOAuthMessage());
722
  }
723
  }
724
 
@@ -752,12 +745,11 @@ class SocialLogin {
752
  $providerData = Utils::getProviderByState($state);
753
  $provider = $providerData["provider"];
754
  $postID = $providerData["postID"];
755
- $postURL = $this->getPostLink($postID);
756
  if (!$state || ($provider != "vk")) {
757
- $this->redirect($postURL, esc_html__("VK authentication failed (OAuth state does not exist).", "wpdiscuz"));
758
  }
759
  if (!$code) {
760
- $this->redirect($postURL, esc_html__("VK authentication failed (OAuth code does not exist).", "wpdiscuz"));
761
  }
762
  $vkCallBack = $this->createCallBackURL("vk");
763
  $vkAccessTokenURL = "https://oauth.vk.com/access_token";
@@ -768,14 +760,14 @@ class SocialLogin {
768
  $vkAccesTokenResponse = wp_remote_post($vkAccessTokenURL, ["body" => $accessTokenArgs]);
769
 
770
  if (is_wp_error($vkAccesTokenResponse)) {
771
- $this->redirect($postURL, $vkAccesTokenResponse->get_error_message());
772
  }
773
  $vkAccesTokenData = json_decode(wp_remote_retrieve_body($vkAccesTokenResponse), true);
774
  if (isset($vkAccesTokenData["error"])) {
775
- $this->redirect($postURL, $vkAccesTokenData["error_description"]);
776
  }
777
  if (!isset($vkAccesTokenData["user_id"])) {
778
- $this->redirect($postURL, esc_html__("VK authentication failed (user_id does not exist).", "wpdiscuz"));
779
  }
780
  $userID = $vkAccesTokenData["user_id"];
781
  $email = isset($vkAccesTokenData["email"]) ? $vkAccesTokenData["email"] : $userID . "@vk.com";
@@ -786,20 +778,20 @@ class SocialLogin {
786
  "v" => "5.78"];
787
  $getVkUserResponse = wp_remote_post($vkGetUserDataURL, ["body" => $vkGetUserDataAttr]);
788
  if (is_wp_error($getVkUserResponse)) {
789
- $this->redirect($postURL, $getVkUserResponse->get_error_message());
790
  }
791
  $vkUserData = json_decode(wp_remote_retrieve_body($getVkUserResponse), true);
792
  if (isset($vkUserData["error"])) {
793
- $this->redirect($postURL, $vkUserData["error_msg"]);
794
  }
795
  $vkUser = $vkUserData["response"][0];
796
  $vkUser["email"] = $email;
797
  $uID = Utils::addUser($vkUser, "vk");
798
  if (is_wp_error($uID)) {
799
- $this->redirect($postURL, $uID->get_error_message());
800
  }
801
  $this->setCurrentUser($uID);
802
- $this->redirect($postURL);
803
  }
804
 
805
  //https://apiok.ru/dev/app/create
@@ -830,12 +822,11 @@ class SocialLogin {
830
  $providerData = Utils::getProviderByState($state);
831
  $provider = $providerData["provider"];
832
  $postID = $providerData["postID"];
833
- $postURL = $this->getPostLink($postID);
834
  if (!$state || ($provider != "ok")) {
835
- $this->redirect($postURL, esc_html__("OK authentication failed (OAuth state does not exist).", "wpdiscuz"));
836
  }
837
  if (!$code) {
838
- $this->redirect($postURL, esc_html__("OK authentication failed (code does not exist).", "wpdiscuz"));
839
  }
840
  $okCallBack = $this->createCallBackURL("ok");
841
  $okAccessTokenURL = "https://api.ok.ru/oauth/token.do";
@@ -847,14 +838,14 @@ class SocialLogin {
847
  $okAccesTokenResponse = wp_remote_post($okAccessTokenURL, ["body" => $accessTokenArgs]);
848
 
849
  if (is_wp_error($okAccesTokenResponse)) {
850
- $this->redirect($postURL, $okAccesTokenResponse->get_error_message());
851
  }
852
  $okAccesTokenData = json_decode(wp_remote_retrieve_body($okAccesTokenResponse), true);
853
  if (isset($okAccesTokenData["error_code"])) {
854
- $this->redirect($postURL, $okAccesTokenData["error_msg"]);
855
  }
856
  if (!isset($okAccesTokenData["access_token"])) {
857
- $this->redirect($postURL, esc_html__("OK authentication failed (access_token does not exist).", "wpdiscuz"));
858
  }
859
  $accessToken = $okAccesTokenData["access_token"];
860
  $secretKey = md5($accessToken . $this->generalOptions->social["okAppSecret"]);
@@ -867,18 +858,18 @@ class SocialLogin {
867
  "access_token" => $accessToken];
868
  $getOkUserResponse = wp_remote_post($okGetUserDataURL, ["body" => $okGetUserDataAttr]);
869
  if (is_wp_error($getOkUserResponse)) {
870
- $this->redirect($postURL, $getOkUserResponse->get_error_message());
871
  }
872
  $okUserData = json_decode(wp_remote_retrieve_body($getOkUserResponse), true);
873
  if (isset($okUserData["error_code"])) {
874
- $this->redirect($postURL, $okUserData["error_msg"]);
875
  }
876
  $uID = Utils::addUser($okUserData, "ok");
877
  if (is_wp_error($uID)) {
878
- $this->redirect($postURL, $uID->get_error_message());
879
  }
880
  $this->setCurrentUser($uID);
881
- $this->redirect($postURL);
882
  }
883
 
884
  //https://yandex.ru/dev/oauth/doc/dg/reference/auto-code-client-docpage/#auto-code-client
@@ -910,15 +901,14 @@ class SocialLogin {
910
  $providerData = Utils::getProviderByState($state);
911
  $provider = $providerData["provider"];
912
  $postID = $providerData["postID"];
913
- $postURL = $this->getPostLink($postID);
914
  if ($error) {
915
- $this->redirect($postURL, esc_html($errorDesc));
916
  }
917
  if (!$state || ($provider != "yandex")) {
918
- $this->redirect($postURL, esc_html__("Yandex authentication failed (OAuth state does not exist).", "wpdiscuz"));
919
  }
920
  if (!$code) {
921
- $this->redirect($postURL, esc_html__("Yandex authentication failed (code does not exist).", "wpdiscuz"));
922
  }
923
  $yandexCallBack = $this->createCallBackURL("yandex");
924
  $yandexAccessTokenURL = "https://oauth.yandex.ru/token";
@@ -930,15 +920,15 @@ class SocialLogin {
930
  $yandexAccesTokenResponse = wp_remote_post($yandexAccessTokenURL, ["body" => $accessTokenArgs]);
931
 
932
  if (is_wp_error($yandexAccesTokenResponse)) {
933
- $this->redirect($postURL, $yandexAccesTokenResponse->get_error_message());
934
  }
935
  $yandexAccesTokenData = json_decode(wp_remote_retrieve_body($yandexAccesTokenResponse), true);
936
 
937
  if (isset($yandexAccesTokenData["error"])) {
938
- $this->redirect($postURL, $yandexAccesTokenData["error_description"]);
939
  }
940
  if (!isset($yandexAccesTokenData["access_token"])) {
941
- $this->redirect($postURL, esc_html__("Yandex authentication failed (access_token does not exist).", "wpdiscuz"));
942
  }
943
  $accessToken = $yandexAccesTokenData["access_token"];
944
  $yandexGetUserDataURL = "https://login.yandex.ru/info?format=json";
@@ -953,19 +943,19 @@ class SocialLogin {
953
  $getYandexUserResponse = wp_remote_post($yandexGetUserDataURL, $yandexGetUserDataAttr);
954
 
955
  if (is_wp_error($getYandexUserResponse)) {
956
- $this->redirect($postURL, $getYandexUserResponse->get_error_message());
957
  }
958
  $yandexUserData = json_decode(wp_remote_retrieve_body($getYandexUserResponse), true);
959
  if (isset($yandexUserData["error"])) {
960
- $this->redirect($postURL, $yandexUserData["error_description"]);
961
  }
962
 
963
  $uID = Utils::addUser($yandexUserData, "yandex");
964
  if (is_wp_error($uID)) {
965
- $this->redirect($postURL, $uID->get_error_message());
966
  }
967
  $this->setCurrentUser($uID);
968
- $this->redirect($postURL);
969
  }
970
 
971
  //https://o2.mail.ru/docs/
@@ -1000,16 +990,15 @@ class SocialLogin {
1000
  $providerData = Utils::getProviderByState($state);
1001
  $provider = $providerData["provider"];
1002
  $postID = $providerData["postID"];
1003
- $postURL = $this->getPostLink($postID);
1004
 
1005
  if ($error) {
1006
- $this->redirect($postURL, esc_html($errorDesc));
1007
  }
1008
  if (!$state || ($provider != "mailru")) {
1009
- $this->redirect($postURL, esc_html__("Mail.ru authentication failed (OAuth state does not exist).", "wpdiscuz"));
1010
  }
1011
  if (!$code) {
1012
- $this->redirect($postURL, esc_html__("Mail.ru authentication failed (code does not exist).", "wpdiscuz"));
1013
  }
1014
  $mailruCallBack = $this->createCallBackURL("mailru");
1015
  $mailruAccessTokenURL = "https://oauth.mail.ru/token";
@@ -1038,10 +1027,10 @@ class SocialLogin {
1038
  $mailruAccesTokenData = json_decode($mailruAccesTokenResponse, true);
1039
 
1040
  if (isset($mailruAccesTokenData["error"])) {
1041
- $this->redirect($postURL, $mailruAccesTokenData["error_description"]);
1042
  }
1043
  if (!isset($mailruAccesTokenData["access_token"])) {
1044
- $this->redirect($postURL, esc_html__("Mail.ru authentication failed (access_token does not exist).", "wpdiscuz"));
1045
  }
1046
  $accessToken = $mailruAccesTokenData["access_token"];
1047
 
@@ -1049,15 +1038,15 @@ class SocialLogin {
1049
  $mailruUserData = json_decode(file_get_contents($mailruGetUserDataURL), true);
1050
 
1051
  if (isset($mailruUserData["error"])) {
1052
- $this->redirect($postURL, $mailruUserData["error_description"]);
1053
  }
1054
 
1055
  $uID = Utils::addUser($mailruUserData, "mailru");
1056
  if (is_wp_error($uID)) {
1057
- $this->redirect($postURL, $uID->get_error_message());
1058
  }
1059
  $this->setCurrentUser($uID);
1060
- $this->redirect($postURL);
1061
  }
1062
 
1063
  //https://developers.weixin.qq.com/doc/oplatform/en/Website_App/WeChat_Login/Wechat_Login.html
@@ -1091,15 +1080,14 @@ class SocialLogin {
1091
  $providerData = Utils::getProviderByState($state);
1092
  $provider = $providerData["provider"];
1093
  $postID = $providerData["postID"];
1094
- $postURL = $this->getPostLink($postID);
1095
  if ($error) {
1096
- $this->redirect($postURL, esc_html($errorDesc));
1097
  }
1098
  if (!$state || ($provider != "wechat")) {
1099
- $this->redirect($postURL, esc_html__("WeChat authentication failed (OAuth state does not exist).", "wpdiscuz"));
1100
  }
1101
  if (!$code) {
1102
- $this->redirect($postURL, esc_html__("WeChat authentication failed (code does not exist).", "wpdiscuz"));
1103
  }
1104
  $wechatAccessTokenURL = "https://api.weixin.qq.com/sns/oauth2/access_token";
1105
  $accessTokenArgs = ["appid" => $this->generalOptions->social["wechatAppID"],
@@ -1109,15 +1097,15 @@ class SocialLogin {
1109
  $wechatAccesTokenResponse = wp_remote_post($wechatAccessTokenURL, ["body" => $accessTokenArgs]);
1110
 
1111
  if (is_wp_error($wechatAccesTokenResponse)) {
1112
- $this->redirect($postURL, $wechatAccesTokenResponse->get_error_message());
1113
  }
1114
  $wechatAccesTokenData = json_decode(wp_remote_retrieve_body($wechatAccesTokenResponse), true);
1115
 
1116
  if (isset($wechatAccesTokenData["errcode"])) {
1117
- $this->redirect($postURL, $wechatAccesTokenData["errmsg"]);
1118
  }
1119
  if (!isset($wechatAccesTokenData["access_token"])) {
1120
- $this->redirect($postURL, esc_html__("WeChat authentication failed (access_token does not exist).", "wpdiscuz"));
1121
  }
1122
  $accessToken = $wechatAccesTokenData["access_token"];
1123
  $uid = $wechatAccesTokenData["openid"];
@@ -1132,18 +1120,18 @@ class SocialLogin {
1132
  $getWechatUserResponse = wp_remote_get($wechatGetUserDataURL);
1133
 
1134
  if (is_wp_error($getWechatUserResponse)) {
1135
- $this->redirect($postURL, $getWechatUserResponse->get_error_message());
1136
  }
1137
  $wechatUserData = json_decode(wp_remote_retrieve_body($getWechatUserResponse), true);
1138
  if (isset($wechatUserData["errcode"])) {
1139
- $this->redirect($postURL, $wechatUserData["errmsg"]);
1140
  }
1141
  $uID = Utils::addUser($wechatUserData, "wechat");
1142
  if (is_wp_error($uID)) {
1143
- $this->redirect($postURL, $uID->get_error_message());
1144
  }
1145
  $this->setCurrentUser($uID);
1146
- $this->redirect($postURL);
1147
  }
1148
 
1149
  //https://wiki.connect.qq.com/%E5%BC%80%E5%8F%91%E6%94%BB%E7%95%A5_server-side
@@ -1177,15 +1165,14 @@ class SocialLogin {
1177
  $providerData = Utils::getProviderByState($state);
1178
  $provider = $providerData["provider"];
1179
  $postID = $providerData["postID"];
1180
- $postURL = $this->getPostLink($postID);
1181
  if ($error) {
1182
- $this->redirect($postURL, esc_html($errorDesc));
1183
  }
1184
  if (!$state || ($provider != "qq")) {
1185
- $this->redirect($postURL, esc_html__("QQ authentication failed (OAuth state does not exist).", "wpdiscuz"));
1186
  }
1187
  if (!$code) {
1188
- $this->redirect($postURL, esc_html__("QQ authentication failed (code does not exist).", "wpdiscuz"));
1189
  }
1190
  $qqCallBack = $this->createCallBackURL("qq");
1191
  $accessTokenArgs = ["client_id" => $this->generalOptions->social["qqAppID"],
@@ -1196,7 +1183,7 @@ class SocialLogin {
1196
  $qqAccessTokenURL = add_query_arg($accessTokenArgs, "https://graph.qq.com/oauth2.0/token");
1197
  $qqAccesTokenResponse = wp_remote_get($qqAccessTokenURL);
1198
  if (is_wp_error($qqAccesTokenResponse)) {
1199
- $this->redirect($postURL, $qqAccesTokenResponse->get_error_message());
1200
  }
1201
  $qqAccesTokenResponseBody = wp_remote_retrieve_body($qqAccesTokenResponse);
1202
  if (strpos($qqAccesTokenResponseBody, "callback") !== false) {
@@ -1205,17 +1192,17 @@ class SocialLogin {
1205
  $qqAccesTokenResponseBody = substr($qqAccesTokenResponseBody, $lpos + 1, $rpos - $lpos - 1);
1206
  $qqAccesTokenResponseMsg = json_decode($qqAccesTokenResponseBody, true);
1207
  if (isset($qqAccesTokenResponseMsg["error"])) {
1208
- $this->redirect($postURL, $qqAccesTokenResponseMsg["error_description"]);
1209
  }
1210
  $qqAccesTokenData = array();
1211
  parse_str($qqAccesTokenResponseBody, $qqAccesTokenData);
1212
  if (!isset($qqAccesTokenData["access_token"])) {
1213
- $this->redirect($postURL, esc_html__("QQ authentication failed (access_token does not exist).", "wpdiscuz"));
1214
  }
1215
  $accessToken = $qqAccesTokenData["access_token"];
1216
  $qqOpenIdResponse = wp_remote_get("https://graph.qq.com/oauth2.0/me?access_token=" . $accessToken);
1217
  if (is_wp_error($qqOpenIdResponse)) {
1218
- $this->redirect($postURL, $qqOpenIdResponse->get_error_message());
1219
  }
1220
  $qqOpenIdResponseBody = wp_remote_retrieve_body($qqAccesTokenResponse);
1221
  if (strpos($qqOpenIdResponseBody, "callback") !== false) {
@@ -1225,7 +1212,7 @@ class SocialLogin {
1225
  }
1226
  $qqOpenIdResponseMsg = json_decode($qqOpenIdResponseBody, true);
1227
  if (isset($qqOpenIdResponseMsg["error"])) {
1228
- $this->redirect($postURL, $qqOpenIdResponseMsg["error_description"]);
1229
  }
1230
  $openid = $qqOpenIdResponseMsg["openid"];
1231
  $qqGetUserDataAttributs = ["oauth_consumer_key" => $this->generalOptions->social["qqAppID"],
@@ -1235,21 +1222,21 @@ class SocialLogin {
1235
  $qqGetUserDataURL = add_query_arg($qqGetUserDataAttributs, "https://graph.qq.com/user/get_user_info");
1236
  $getQQUserResponse = wp_remote_get($qqGetUserDataURL);
1237
  if (is_wp_error($getQQUserResponse)) {
1238
- $this->redirect($postURL, $getQQUserResponse->get_error_message());
1239
  }
1240
  $qqUserData = json_decode(wp_remote_retrieve_body($getQQUserResponse), true);
1241
  if (isset($qqUserData["error"])) {
1242
- $this->redirect($postURL, $qqUserData["error_description"]);
1243
  }
1244
  $qqUserData["openid"] = $openid;
1245
  $uID = Utils::addUser($qqUserData, "qq");
1246
  if (is_wp_error($uID)) {
1247
- $this->redirect($postURL, $uID->get_error_message());
1248
  }
1249
  $this->setCurrentUser($uID);
1250
- $this->redirect($postURL);
1251
  } else {
1252
- $this->redirect($postURL, esc_html__("QQ authentication failed (access_token does not exist).", "wpdiscuz"));
1253
  }
1254
  }
1255
 
@@ -1284,15 +1271,14 @@ class SocialLogin {
1284
  $providerData = Utils::getProviderByState($state);
1285
  $provider = $providerData["provider"];
1286
  $postID = $providerData["postID"];
1287
- $postURL = $this->getPostLink($postID);
1288
  if ($error) {
1289
- $this->redirect($postURL, esc_html($errorDesc));
1290
  }
1291
  if (!$state || ($provider != "weibo")) {
1292
- $this->redirect($postURL, esc_html__("Weibo authentication failed (OAuth state does not exist).", "wpdiscuz"));
1293
  }
1294
  if (!$code) {
1295
- $this->redirect($postURL, esc_html__("Weibo authentication failed (code does not exist).", "wpdiscuz"));
1296
  }
1297
  $weiboCallBack = $this->createCallBackURL("weibo");
1298
  $weiboAccessTokenURL = "https://api.weibo.com/oauth2/access_token";
@@ -1304,15 +1290,15 @@ class SocialLogin {
1304
  $weiboAccesTokenResponse = wp_remote_post($weiboAccessTokenURL, ["body" => $accessTokenArgs]);
1305
 
1306
  if (is_wp_error($weiboAccesTokenResponse)) {
1307
- $this->redirect($postURL, $weiboAccesTokenResponse->get_error_message());
1308
  }
1309
  $weiboAccesTokenData = json_decode(wp_remote_retrieve_body($weiboAccesTokenResponse), true);
1310
 
1311
  if (isset($weiboAccesTokenData["error"])) {
1312
- $this->redirect($postURL, $weiboAccesTokenData["error_description"]);
1313
  }
1314
  if (!isset($weiboAccesTokenData["access_token"])) {
1315
- $this->redirect($postURL, esc_html__("Weibo authentication failed (access_token does not exist).", "wpdiscuz"));
1316
  }
1317
  $accessToken = $weiboAccesTokenData["access_token"];
1318
  $uid = $weiboAccesTokenData["uid"];
@@ -1326,18 +1312,18 @@ class SocialLogin {
1326
 
1327
  $getWeiboUserResponse = wp_remote_get($weiboGetUserDataURL, $weiboGetUserDataAttr);
1328
  if (is_wp_error($getWeiboUserResponse)) {
1329
- $this->redirect($postURL, $getWeiboUserResponse->get_error_message());
1330
  }
1331
  $weiboUserData = json_decode(wp_remote_retrieve_body($getWeiboUserResponse), true);
1332
  if (isset($weiboUserData["error"])) {
1333
- $this->redirect($postURL, $weiboUserData["error_description"]);
1334
  }
1335
  $uID = Utils::addUser($weiboUserData, "weibo");
1336
  if (is_wp_error($uID)) {
1337
- $this->redirect($postURL, $uID->get_error_message());
1338
  }
1339
  $this->setCurrentUser($uID);
1340
- $this->redirect($postURL);
1341
  }
1342
 
1343
  //https://developer.baidu.com/wiki/index.php?title=docs/oauth/application
@@ -1374,15 +1360,14 @@ class SocialLogin {
1374
  $providerData = Utils::getProviderByState($state);
1375
  $provider = $providerData["provider"];
1376
  $postID = $providerData["postID"];
1377
- $postURL = $this->getPostLink($postID);
1378
  if ($error) {
1379
- $this->redirect($postURL, esc_html($errorDesc));
1380
  }
1381
  if (!$state || ($provider != "baidu")) {
1382
- $this->redirect($postURL, esc_html__("Baidu authentication failed (OAuth state does not exist).", "wpdiscuz"));
1383
  }
1384
  if (!$code) {
1385
- $this->redirect($postURL, esc_html__("Baidu authentication failed (code does not exist).", "wpdiscuz"));
1386
  }
1387
  $baiduCallBack = $this->createCallBackURL("baidu");
1388
  $baiduAccessTokenURL = "https://openapi.baidu.com/oauth/2.0/token";
@@ -1394,39 +1379,40 @@ class SocialLogin {
1394
  $baiduAccesTokenResponse = wp_remote_post($baiduAccessTokenURL, ["body" => $accessTokenArgs]);
1395
 
1396
  if (is_wp_error($baiduAccesTokenResponse)) {
1397
- $this->redirect($postURL, $baiduAccesTokenResponse->get_error_message());
1398
  }
1399
  $baiduAccesTokenData = json_decode(wp_remote_retrieve_body($baiduAccesTokenResponse), true);
1400
 
1401
  if (isset($baiduAccesTokenData["error"])) {
1402
- $this->redirect($postURL, $baiduAccesTokenData["error_description"]);
1403
  }
1404
  if (!isset($baiduAccesTokenData["access_token"])) {
1405
- $this->redirect($postURL, esc_html__("Baidu authentication failed (access_token does not exist).", "wpdiscuz"));
1406
  }
1407
  $accessToken = $baiduAccesTokenData["access_token"];
1408
 
1409
  $getBaiduUserResponse = wp_remote_get("https://openapi.baidu.com/rest/2.0/passport/users/getLoggedInUser?access_token=" . $accessToken);
1410
  if (is_wp_error($getBaiduUserResponse)) {
1411
- $this->redirect($postURL, $getBaiduUserResponse->get_error_message());
1412
  }
1413
  $baiduUserData = json_decode(wp_remote_retrieve_body($getBaiduUserResponse), true);
1414
  if (isset($baiduUserData["error_code"])) {
1415
- $this->redirect($postURL, $baiduUserData["error_msg"]);
1416
  }
1417
  $uID = Utils::addUser($baiduUserData, "baidu");
1418
  if (is_wp_error($uID)) {
1419
- $this->redirect($postURL, $uID->get_error_message());
1420
  }
1421
  $this->setCurrentUser($uID);
1422
- $this->redirect($postURL);
1423
  }
1424
 
1425
- private function redirect($postURL, $message = "") {
1426
  if ($message) {
1427
  setcookie('wpdiscuz_social_login_message', $message, time() + 3600, '/');
1428
  }
1429
- wp_redirect($postURL, 302);
 
1430
  exit();
1431
  }
1432
 
188
  $providerData = Utils::getProviderByState($state);
189
  $provider = $providerData["provider"];
190
  $postID = $providerData["postID"];
 
191
  if (!$state || ($provider != "facebook")) {
192
+ $this->redirect($postID, esc_html__("Facebook authentication failed (OAuth state does not exist).", "wpdiscuz"));
193
  }
194
  if (!$code) {
195
+ $this->redirect($postID, esc_html__("Facebook authentication failed (OAuth code does not exist).", "wpdiscuz"));
196
  }
197
  $fbCallBack = $this->createCallBackURL("facebook");
198
  $fbAccessTokenURL = "https://graph.facebook.com/v3.0/oauth/access_token";
204
  $fbAccesTokenResponse = wp_remote_get($fbAccessTokenURL);
205
 
206
  if (is_wp_error($fbAccesTokenResponse)) {
207
+ $this->redirect($postID, $fbAccesTokenResponse->get_error_message());
208
  }
209
  $fbAccesTokenData = json_decode(wp_remote_retrieve_body($fbAccesTokenResponse), true);
210
  if (isset($fbAccesTokenData["error"])) {
211
+ $this->redirect($postID, $fbAccesTokenData["error"]["message"]);
212
  }
213
  $token = $fbAccesTokenData["access_token"];
214
  $appsecret_proof = hash_hmac("sha256", $token, trim($this->generalOptions->social["fbAppSecret"]));
215
  $fbGetUserDataURL = add_query_arg(["fields" => "id,first_name,last_name,picture,email", "access_token" => $token, "appsecret_proof" => $appsecret_proof], "https://graph.facebook.com/v3.0/me");
216
  $getFbUserResponse = wp_remote_get($fbGetUserDataURL);
217
  if (is_wp_error($getFbUserResponse)) {
218
+ $this->redirect($postID, $getFbUserResponse->get_error_message());
219
  }
220
  $fbUserData = json_decode(wp_remote_retrieve_body($getFbUserResponse), true);
221
  if (isset($fbUserData["error"])) {
222
+ $this->redirect($postID, $fbUserData["error"]["message"]);
223
  }
224
  if (empty($fbUserData["email"]) && $fbUserData["id"]) {
225
  $fbUserData["email"] = $fbUserData["id"] . "@facebook.com";
226
  }
227
  $uID = Utils::addUser($fbUserData, "facebook");
228
  if (is_wp_error($uID)) {
229
+ $this->redirect($postID, $uID->get_error_message());
230
  }
231
  $this->setCurrentUser($uID);
232
+ $this->redirect($postID);
233
  }
234
 
235
  // https://developers.facebook.com/docs/instagram-basic-display-api/getting-started
262
  $providerData = Utils::getProviderByState($state);
263
  $provider = $providerData["provider"];
264
  $postID = $providerData["postID"];
 
265
 
266
  if (!$state || ($provider != "instagram")) {
267
+ $this->redirect($postID, esc_html__("Instagram authentication failed (OAuth state does not exist).", "wpdiscuz"));
268
  }
269
  if (!$code) {
270
+ $this->redirect($postID, esc_html__("Instagram authentication failed (OAuth code does not exist).", "wpdiscuz"));
271
  }
272
  $instagramCallBack = site_url('/wpdiscuz_auth/instagram/');
273
  $instagramAccessTokenURL = "https://api.instagram.com/oauth/access_token";
279
  $instagramAccesTokenResponse = wp_remote_post($instagramAccessTokenURL, ['body' => $accessTokenArgs]);
280
 
281
  if (is_wp_error($instagramAccesTokenResponse)) {
282
+ $this->redirect($postID, $instagramAccesTokenResponse->get_error_message());
283
  }
284
  $instagramAccesTokenData = json_decode(wp_remote_retrieve_body($instagramAccesTokenResponse), true);
285
  if (isset($instagramAccesTokenData["error"])) {
286
+ $this->redirect($postID, $instagramAccesTokenData["error"]["message"]);
287
  }
288
  $token = $instagramAccesTokenData["access_token"];
289
  $userID = $instagramAccesTokenData["user_id"];
292
  $getInstagramUserResponse = wp_remote_get($instagramGetUserDataURL);
293
 
294
  if (is_wp_error($getInstagramUserResponse)) {
295
+ $this->redirect($postID, $getInstagramUserResponse->get_error_message());
296
  }
297
  $instagramUserData = json_decode(wp_remote_retrieve_body($getInstagramUserResponse), true);
298
  if (isset($instagramUserData["error"])) {
299
+ $this->redirect($postID, $instagramUserData["error"]["message"]);
300
  }
301
  if (empty($instagramUserData["email"]) && $userID) {
302
  $instagramUserData["email"] = $userID . "@instagram.com";
303
  }
304
  $uID = Utils::addUser($instagramUserData, "instagram");
305
  if (is_wp_error($uID)) {
306
+ $this->redirect($postID, $uID->get_error_message());
307
  }
308
  $this->setCurrentUser($uID);
309
+ $this->redirect($postID);
310
  }
311
 
312
  // https://console.developers.google.com/
340
  $providerData = Utils::getProviderByState($state);
341
  $provider = $providerData["provider"];
342
  $postID = $providerData["postID"];
 
343
  if (!$state || ($provider != "google")) {
344
+ $this->redirect($postID, esc_html__("Google authentication failed (OAuth state does not exist).", "wpdiscuz"));
345
  }
346
  if (!$code) {
347
+ $this->redirect($postID, esc_html__("Google authentication failed (OAuth code does not exist).", "wpdiscuz"));
348
  }
349
  $googleCallBack = $this->createCallBackURL("google");
350
  $googleAccessTokenURL = "https://www.googleapis.com/oauth2/v4/token";
355
  "grant_type" => 'authorization_code'];
356
  $googleAccesTokenResponse = wp_remote_post($googleAccessTokenURL, ['body' => $accessTokenArgs]);
357
  if (is_wp_error($googleAccesTokenResponse)) {
358
+ $this->redirect($postID, $googleAccesTokenResponse->get_error_message());
359
  }
360
  $googleAccesTokenData = json_decode(wp_remote_retrieve_body($googleAccesTokenResponse), true);
361
  if (isset($googleAccesTokenData["error"])) {
362
+ $this->redirect($postID, $googleAccesTokenData["error_description"]);
363
  }
364
  $idToken = $googleAccesTokenData["id_token"];
365
  $getGoogleUserRataURL = add_query_arg(["id_token" => $idToken], 'https://oauth2.googleapis.com/tokeninfo');
366
  $googleUserDataResponse = wp_remote_get($getGoogleUserRataURL);
367
  if (is_wp_error($googleUserDataResponse)) {
368
+ $this->redirect($postID, $googleUserDataResponse->get_error_message());
369
  }
370
  $googleUserData = json_decode(wp_remote_retrieve_body($googleUserDataResponse), true);
371
  if (isset($googleUserData["error"])) {
372
+ $this->redirect($postID, $googleUserData["error_description"]);
373
  }
374
  $uID = Utils::addUser($googleUserData, "google");
375
  if (is_wp_error($uID)) {
376
+ $this->redirect($postID, $uID->get_error_message());
377
  }
378
  $this->setCurrentUser($uID);
379
+ $this->redirect($postID);
380
  }
381
 
382
  // https://docs.microsoft.com/en-us/linkedin/shared/authentication/authorization-code-flow?context=linkedin/context
409
  $providerData = Utils::getProviderByState($state);
410
  $provider = $providerData["provider"];
411
  $postID = $providerData["postID"];
 
412
 
413
  if (!$state || ($provider != "linkedin")) {
414
+ $this->redirect($postID, esc_html__("Linkedin authentication failed (OAuth state does not exist).", "wpdiscuz"));
415
  }
416
  if (!$code) {
417
+ $this->redirect($postID, esc_html__("Linkedin authentication failed (OAuth code does not exist).", "wpdiscuz"));
418
  }
419
  $linkedinCallBack = site_url('/wpdiscuz_auth/linkedin/');
420
  $linkedinAccessTokenURL = "https://www.linkedin.com/oauth/v2/accessToken";
426
  $linkedinAccesTokenResponse = wp_remote_post($linkedinAccessTokenURL, ['body' => $accessTokenArgs]);
427
 
428
  if (is_wp_error($linkedinAccesTokenResponse)) {
429
+ $this->redirect($postID, $linkedinAccesTokenResponse->get_error_message());
430
  }
431
  $linkedinAccesTokenData = json_decode(wp_remote_retrieve_body($linkedinAccesTokenResponse), true);
432
  if (isset($linkedinAccesTokenData["error"])) {
433
+ $this->redirect($postID, $linkedinAccesTokenData["error_description"]);
434
  }
435
  $token = $linkedinAccesTokenData["access_token"];
436
 
467
 
468
  $getLinkedinUserResponse = wp_remote_get($linkedinGetUserDataURL, $getLinkedinRequestArgs);
469
  if (is_wp_error($getLinkedinUserResponse)) {
470
+ $this->redirect($postID, $getLinkedinUserResponse->get_error_message());
471
  }
472
  $linkedinUserData = json_decode(wp_remote_retrieve_body($getLinkedinUserResponse), true);
473
 
474
  if (isset($linkedinUserData["error"])) {
475
+ $this->redirect($postID, $linkedinUserData["error_description"]);
476
  }
477
  if ($email) {
478
  $linkedinUserData["email"] = $email;
484
 
485
  $uID = Utils::addUser($linkedinUserData, "linkedin");
486
  if (is_wp_error($uID)) {
487
+ $this->redirect($postID, $uID->get_error_message());
488
  }
489
  $this->setCurrentUser($uID);
490
+ $this->redirect($postID);
491
  }
492
 
493
  public function disqusLogin($postID, $response) {
519
  $providerData = Utils::getProviderByState($state);
520
  $provider = $providerData["provider"];
521
  $postID = $providerData["postID"];
 
522
  if (!$state || ($provider != "disqus")) {
523
+ $this->redirect($postID, esc_html__("Disqus authentication failed (OAuth state does not exist).", "wpdiscuz"));
524
  }
525
  if (!$code) {
526
+ $this->redirect($postID, esc_html__("Disqus authentication failed (OAuth code does not exist).", "wpdiscuz"));
527
  }
528
  $disqusCallBack = $this->createCallBackURL("disqus");
529
  $disqusAccessTokenURL = "https://disqus.com/api/oauth/2.0/access_token";
537
  $disqusAccesTokenResponse = wp_remote_post($disqusAccessTokenURL, ["body" => $accessTokenArgs]);
538
 
539
  if (is_wp_error($disqusAccesTokenResponse)) {
540
+ $this->redirect($postID, $disqusAccesTokenResponse->get_error_message());
541
  }
542
  $disqusAccesTokenData = json_decode(wp_remote_retrieve_body($disqusAccesTokenResponse), true);
543
  if (isset($disqusAccesTokenData["error"])) {
544
+ $this->redirect($postID, $disqusAccesTokenData["error_description"]);
545
  }
546
  if (!isset($disqusAccesTokenData["access_token"])) {
547
+ $this->redirect($postID, esc_html__("Disqus authentication failed (access_token does not exist).", "wpdiscuz"));
548
  }
549
  if (!isset($disqusAccesTokenData["user_id"])) {
550
+ $this->redirect($postID, esc_html__("Disqus authentication failed (user_id does not exist).", "wpdiscuz"));
551
  }
552
  $userID = $disqusAccesTokenData["user_id"];
553
  $accesToken = $disqusAccesTokenData["access_token"];
559
 
560
  $getDisqusUserResponse = wp_remote_get($disqusGetUserDataURL, ["body" => $disqusGetUserDataAttr]);
561
  if (is_wp_error($getDisqusUserResponse)) {
562
+ $this->redirect($postID, $getDisqusUserResponse->get_error_message());
563
  }
564
  $disqusUserData = json_decode(wp_remote_retrieve_body($getDisqusUserResponse), true);
565
  if (isset($disqusUserData["code"]) && $disqusUserData["code"] != 0) {
566
+ $this->redirect($postID, $disqusUserData["response"]);
567
  }
568
  $disqusUser = $disqusUserData["response"];
569
  $disqusUser["user_id"] = $userID;
570
  $uID = Utils::addUser($disqusUser, "disqus");
571
  if (is_wp_error($uID)) {
572
+ $this->redirect($postID, $uID->get_error_message());
573
  }
574
  $this->setCurrentUser($uID);
575
+ $this->redirect($postID);
576
  }
577
 
578
  //https://developer.wordpress.com/docs/oauth2/ https://developer.wordpress.com/docs/wpcc/
605
  $providerData = Utils::getProviderByState($state);
606
  $provider = $providerData["provider"];
607
  $postID = $providerData["postID"];
 
608
  if (!$state || ($provider != "wordpress")) {
609
+ $this->redirect($postID, esc_html__("Wordpress.com authentication failed (OAuth state does not exist).", "wpdiscuz"));
610
  }
611
  if (!$code) {
612
+ $this->redirect($postID, esc_html__("Wordpress.com authentication failed (OAuth code does not exist).", "wpdiscuz"));
613
  }
614
  $wordpressCallBack = $this->createCallBackURL("wordpress");
615
  $wordpressAccessTokenURL = "https://public-api.wordpress.com/oauth2/token";
623
  $wordpressAccesTokenResponse = wp_remote_post($wordpressAccessTokenURL, ["body" => $accessTokenArgs]);
624
 
625
  if (is_wp_error($wordpressAccesTokenResponse)) {
626
+ $this->redirect($postID, $wordpressAccesTokenResponse->get_error_message());
627
  }
628
  $wordpressAccesTokenData = json_decode(wp_remote_retrieve_body($wordpressAccesTokenResponse), true);
629
  if (isset($wordpressAccesTokenData["error"])) {
630
+ $this->redirect($postID, $wordpressAccesTokenData["error_description"]);
631
  }
632
  if (!isset($wordpressAccesTokenData["access_token"])) {
633
+ $this->redirect($postID, esc_html__("Wordpress.com authentication failed (access_token does not exist).", "wpdiscuz"));
634
  }
635
  $accesToken = $wordpressAccesTokenData["access_token"];
636
  $wordpressAccesTokenValidateURL = "https://public-api.wordpress.com/oauth2/token-info";
638
  $wordpressAccesTokenValidateURL = add_query_arg($accesTokenValidateArgs, $wordpressAccesTokenValidateURL);
639
  $accesTokenValidateResponse = wp_remote_get($wordpressAccesTokenValidateURL, $accesTokenValidateArgs);
640
  if (is_wp_error($accesTokenValidateResponse)) {
641
+ $this->redirect($postID, $accesTokenValidateResponse->get_error_message());
642
  }
643
  $accesTokenValidateData = json_decode(wp_remote_retrieve_body($accesTokenValidateResponse), true);
644
  if (!isset($accesTokenValidateData["user_id"]) || !$accesTokenValidateData["user_id"]) {
645
+ $this->redirect($postID, esc_html__("Wordpress.com authentication failed (user_id does not exist).", "wpdiscuz"));
646
  }
647
 
648
  $wordpressGetUserDataURL = "https://public-api.wordpress.com/rest/v1/me/";
651
  $getWordpressUserResponse = wp_remote_get($wordpressGetUserDataURL, ["headers" => $wordpressGetUserDataAttr]);
652
 
653
  if (is_wp_error($getWordpressUserResponse)) {
654
+ $this->redirect($postID, $getWordpressUserResponse->get_error_message());
655
  }
656
  $wordpressUserData = json_decode(wp_remote_retrieve_body($getWordpressUserResponse), true);
657
  if (isset($wordpressUserData["error"])) {
658
+ $this->redirect($postID, $wordpressUserData["message"]);
659
  }
660
  $uID = Utils::addUser($wordpressUserData, "wordpress");
661
  if (is_wp_error($uID)) {
662
+ $this->redirect($postID, $uID->get_error_message());
663
  }
664
  $this->setCurrentUser($uID);
665
+ $this->redirect($postID);
666
  }
667
 
668
  // https://apps.twitter.com/
692
  $oauthSecretData = Utils::getProviderByState($oauthToken);
693
  $oauthSecret = $oauthSecretData["provider"];
694
  $postID = $oauthSecretData["postID"];
 
695
  if (!$oauthVerifier || !$oauthSecret) {
696
+ $this->redirect($postID, esc_html__("Twitter authentication failed (OAuth secret does not exist).", "wpdiscuz"));
697
  }
698
  $twitter = new TwitterOAuth($this->generalOptions->social["twitterAppID"], $this->generalOptions->social["twitterAppSecret"], $oauthToken, $oauthSecret);
699
  try {
703
  if (!empty($twitterUser->id)) {
704
  $uID = Utils::addUser($twitterUser, "twitter");
705
  if (is_wp_error($uID)) {
706
+ $this->redirect($postID, $uID->get_error_message());
707
  }
708
  $this->setCurrentUser($uID);
709
+ $this->redirect($postID);
710
  } else {
711
+ $this->redirect($postID, esc_html__("Twitter connection failed.", "wpdiscuz"));
712
  }
713
  } catch (TwitterOAuthException $e) {
714
+ $this->redirect($postID, $e->getOAuthMessage());
715
  }
716
  }
717
 
745
  $providerData = Utils::getProviderByState($state);
746
  $provider = $providerData["provider"];
747
  $postID = $providerData["postID"];
 
748
  if (!$state || ($provider != "vk")) {
749
+ $this->redirect($postID, esc_html__("VK authentication failed (OAuth state does not exist).", "wpdiscuz"));
750
  }
751
  if (!$code) {
752
+ $this->redirect($postID, esc_html__("VK authentication failed (OAuth code does not exist).", "wpdiscuz"));
753
  }
754
  $vkCallBack = $this->createCallBackURL("vk");
755
  $vkAccessTokenURL = "https://oauth.vk.com/access_token";
760
  $vkAccesTokenResponse = wp_remote_post($vkAccessTokenURL, ["body" => $accessTokenArgs]);
761
 
762
  if (is_wp_error($vkAccesTokenResponse)) {
763
+ $this->redirect($postID, $vkAccesTokenResponse->get_error_message());
764
  }
765
  $vkAccesTokenData = json_decode(wp_remote_retrieve_body($vkAccesTokenResponse), true);
766
  if (isset($vkAccesTokenData["error"])) {
767
+ $this->redirect($postID, $vkAccesTokenData["error_description"]);
768
  }
769
  if (!isset($vkAccesTokenData["user_id"])) {
770
+ $this->redirect($postID, esc_html__("VK authentication failed (user_id does not exist).", "wpdiscuz"));
771
  }
772
  $userID = $vkAccesTokenData["user_id"];
773
  $email = isset($vkAccesTokenData["email"]) ? $vkAccesTokenData["email"] : $userID . "@vk.com";
778
  "v" => "5.78"];
779
  $getVkUserResponse = wp_remote_post($vkGetUserDataURL, ["body" => $vkGetUserDataAttr]);
780
  if (is_wp_error($getVkUserResponse)) {
781
+ $this->redirect($postID, $getVkUserResponse->get_error_message());
782
  }
783
  $vkUserData = json_decode(wp_remote_retrieve_body($getVkUserResponse), true);
784
  if (isset($vkUserData["error"])) {
785
+ $this->redirect($postID, $vkUserData["error_msg"]);
786
  }
787
  $vkUser = $vkUserData["response"][0];
788
  $vkUser["email"] = $email;
789
  $uID = Utils::addUser($vkUser, "vk");
790
  if (is_wp_error($uID)) {
791
+ $this->redirect($postID, $uID->get_error_message());
792
  }
793
  $this->setCurrentUser($uID);
794
+ $this->redirect($postID);
795
  }
796
 
797
  //https://apiok.ru/dev/app/create
822
  $providerData = Utils::getProviderByState($state);
823
  $provider = $providerData["provider"];
824
  $postID = $providerData["postID"];
 
825
  if (!$state || ($provider != "ok")) {
826
+ $this->redirect($postID, esc_html__("OK authentication failed (OAuth state does not exist).", "wpdiscuz"));
827
  }
828
  if (!$code) {
829
+ $this->redirect($postID, esc_html__("OK authentication failed (code does not exist).", "wpdiscuz"));
830
  }
831
  $okCallBack = $this->createCallBackURL("ok");
832
  $okAccessTokenURL = "https://api.ok.ru/oauth/token.do";
838
  $okAccesTokenResponse = wp_remote_post($okAccessTokenURL, ["body" => $accessTokenArgs]);
839
 
840
  if (is_wp_error($okAccesTokenResponse)) {
841
+ $this->redirect($postID, $okAccesTokenResponse->get_error_message());
842
  }
843
  $okAccesTokenData = json_decode(wp_remote_retrieve_body($okAccesTokenResponse), true);
844
  if (isset($okAccesTokenData["error_code"])) {
845
+ $this->redirect($postID, $okAccesTokenData["error_msg"]);
846
  }
847
  if (!isset($okAccesTokenData["access_token"])) {
848
+ $this->redirect($postID, esc_html__("OK authentication failed (access_token does not exist).", "wpdiscuz"));
849
  }
850
  $accessToken = $okAccesTokenData["access_token"];
851
  $secretKey = md5($accessToken . $this->generalOptions->social["okAppSecret"]);
858
  "access_token" => $accessToken];
859
  $getOkUserResponse = wp_remote_post($okGetUserDataURL, ["body" => $okGetUserDataAttr]);
860
  if (is_wp_error($getOkUserResponse)) {
861
+ $this->redirect($postID, $getOkUserResponse->get_error_message());
862
  }
863
  $okUserData = json_decode(wp_remote_retrieve_body($getOkUserResponse), true);
864
  if (isset($okUserData["error_code"])) {
865
+ $this->redirect($postID, $okUserData["error_msg"]);
866
  }
867
  $uID = Utils::addUser($okUserData, "ok");
868
  if (is_wp_error($uID)) {
869
+ $this->redirect($postID, $uID->get_error_message());
870
  }
871
  $this->setCurrentUser($uID);
872
+ $this->redirect($postID);
873
  }
874
 
875
  //https://yandex.ru/dev/oauth/doc/dg/reference/auto-code-client-docpage/#auto-code-client
901
  $providerData = Utils::getProviderByState($state);
902
  $provider = $providerData["provider"];
903
  $postID = $providerData["postID"];
 
904
  if ($error) {
905
+ $this->redirect($postID, esc_html($errorDesc));
906
  }
907
  if (!$state || ($provider != "yandex")) {
908
+ $this->redirect($postID, esc_html__("Yandex authentication failed (OAuth state does not exist).", "wpdiscuz"));
909
  }
910
  if (!$code) {
911
+ $this->redirect($postID, esc_html__("Yandex authentication failed (code does not exist).", "wpdiscuz"));
912
  }
913
  $yandexCallBack = $this->createCallBackURL("yandex");
914
  $yandexAccessTokenURL = "https://oauth.yandex.ru/token";
920
  $yandexAccesTokenResponse = wp_remote_post($yandexAccessTokenURL, ["body" => $accessTokenArgs]);
921
 
922
  if (is_wp_error($yandexAccesTokenResponse)) {
923
+ $this->redirect($postID, $yandexAccesTokenResponse->get_error_message());
924
  }
925
  $yandexAccesTokenData = json_decode(wp_remote_retrieve_body($yandexAccesTokenResponse), true);
926
 
927
  if (isset($yandexAccesTokenData["error"])) {
928
+ $this->redirect($postID, $yandexAccesTokenData["error_description"]);
929
  }
930
  if (!isset($yandexAccesTokenData["access_token"])) {
931
+ $this->redirect($postID, esc_html__("Yandex authentication failed (access_token does not exist).", "wpdiscuz"));
932
  }
933
  $accessToken = $yandexAccesTokenData["access_token"];
934
  $yandexGetUserDataURL = "https://login.yandex.ru/info?format=json";
943
  $getYandexUserResponse = wp_remote_post($yandexGetUserDataURL, $yandexGetUserDataAttr);
944
 
945
  if (is_wp_error($getYandexUserResponse)) {
946
+ $this->redirect($postID, $getYandexUserResponse->get_error_message());
947
  }
948
  $yandexUserData = json_decode(wp_remote_retrieve_body($getYandexUserResponse), true);
949
  if (isset($yandexUserData["error"])) {
950
+ $this->redirect($postID, $yandexUserData["error_description"]);
951
  }
952
 
953
  $uID = Utils::addUser($yandexUserData, "yandex");
954
  if (is_wp_error($uID)) {
955
+ $this->redirect($postID, $uID->get_error_message());
956
  }
957
  $this->setCurrentUser($uID);
958
+ $this->redirect($postID);
959
  }
960
 
961
  //https://o2.mail.ru/docs/
990
  $providerData = Utils::getProviderByState($state);
991
  $provider = $providerData["provider"];
992
  $postID = $providerData["postID"];
 
993
 
994
  if ($error) {
995
+ $this->redirect($postID, esc_html($errorDesc));
996
  }
997
  if (!$state || ($provider != "mailru")) {
998
+ $this->redirect($postID, esc_html__("Mail.ru authentication failed (OAuth state does not exist).", "wpdiscuz"));
999
  }
1000
  if (!$code) {
1001
+ $this->redirect($postID, esc_html__("Mail.ru authentication failed (code does not exist).", "wpdiscuz"));
1002
  }
1003
  $mailruCallBack = $this->createCallBackURL("mailru");
1004
  $mailruAccessTokenURL = "https://oauth.mail.ru/token";
1027
  $mailruAccesTokenData = json_decode($mailruAccesTokenResponse, true);
1028
 
1029
  if (isset($mailruAccesTokenData["error"])) {
1030
+ $this->redirect($postID, $mailruAccesTokenData["error_description"]);
1031
  }
1032
  if (!isset($mailruAccesTokenData["access_token"])) {
1033
+ $this->redirect($postID, esc_html__("Mail.ru authentication failed (access_token does not exist).", "wpdiscuz"));
1034
  }
1035
  $accessToken = $mailruAccesTokenData["access_token"];
1036
 
1038
  $mailruUserData = json_decode(file_get_contents($mailruGetUserDataURL), true);
1039
 
1040
  if (isset($mailruUserData["error"])) {
1041
+ $this->redirect($postID, $mailruUserData["error_description"]);
1042
  }
1043
 
1044
  $uID = Utils::addUser($mailruUserData, "mailru");
1045
  if (is_wp_error($uID)) {
1046
+ $this->redirect($postID, $uID->get_error_message());
1047
  }
1048
  $this->setCurrentUser($uID);
1049
+ $this->redirect($postID);
1050
  }
1051
 
1052
  //https://developers.weixin.qq.com/doc/oplatform/en/Website_App/WeChat_Login/Wechat_Login.html
1080
  $providerData = Utils::getProviderByState($state);
1081
  $provider = $providerData["provider"];
1082
  $postID = $providerData["postID"];
 
1083
  if ($error) {
1084
+ $this->redirect($postID, esc_html($errorDesc));
1085
  }
1086
  if (!$state || ($provider != "wechat")) {
1087
+ $this->redirect($postID, esc_html__("WeChat authentication failed (OAuth state does not exist).", "wpdiscuz"));
1088
  }
1089
  if (!$code) {
1090
+ $this->redirect($postID, esc_html__("WeChat authentication failed (code does not exist).", "wpdiscuz"));
1091
  }
1092
  $wechatAccessTokenURL = "https://api.weixin.qq.com/sns/oauth2/access_token";
1093
  $accessTokenArgs = ["appid" => $this->generalOptions->social["wechatAppID"],
1097
  $wechatAccesTokenResponse = wp_remote_post($wechatAccessTokenURL, ["body" => $accessTokenArgs]);
1098
 
1099
  if (is_wp_error($wechatAccesTokenResponse)) {
1100
+ $this->redirect($postID, $wechatAccesTokenResponse->get_error_message());
1101
  }
1102
  $wechatAccesTokenData = json_decode(wp_remote_retrieve_body($wechatAccesTokenResponse), true);
1103
 
1104
  if (isset($wechatAccesTokenData["errcode"])) {
1105
+ $this->redirect($postID, $wechatAccesTokenData["errmsg"]);
1106
  }
1107
  if (!isset($wechatAccesTokenData["access_token"])) {
1108
+ $this->redirect($postID, esc_html__("WeChat authentication failed (access_token does not exist).", "wpdiscuz"));
1109
  }
1110
  $accessToken = $wechatAccesTokenData["access_token"];
1111
  $uid = $wechatAccesTokenData["openid"];
1120
  $getWechatUserResponse = wp_remote_get($wechatGetUserDataURL);
1121
 
1122
  if (is_wp_error($getWechatUserResponse)) {
1123
+ $this->redirect($postID, $getWechatUserResponse->get_error_message());
1124
  }
1125
  $wechatUserData = json_decode(wp_remote_retrieve_body($getWechatUserResponse), true);
1126
  if (isset($wechatUserData["errcode"])) {
1127
+ $this->redirect($postID, $wechatUserData["errmsg"]);
1128
  }
1129
  $uID = Utils::addUser($wechatUserData, "wechat");
1130
  if (is_wp_error($uID)) {
1131
+ $this->redirect($postID, $uID->get_error_message());
1132
  }
1133
  $this->setCurrentUser($uID);
1134
+ $this->redirect($postID);
1135
  }
1136
 
1137
  //https://wiki.connect.qq.com/%E5%BC%80%E5%8F%91%E6%94%BB%E7%95%A5_server-side
1165
  $providerData = Utils::getProviderByState($state);
1166
  $provider = $providerData["provider"];
1167
  $postID = $providerData["postID"];
 
1168
  if ($error) {
1169
+ $this->redirect($postID, esc_html($errorDesc));
1170
  }
1171
  if (!$state || ($provider != "qq")) {
1172
+ $this->redirect($postID, esc_html__("QQ authentication failed (OAuth state does not exist).", "wpdiscuz"));
1173
  }
1174
  if (!$code) {
1175
+ $this->redirect($postID, esc_html__("QQ authentication failed (code does not exist).", "wpdiscuz"));
1176
  }
1177
  $qqCallBack = $this->createCallBackURL("qq");
1178
  $accessTokenArgs = ["client_id" => $this->generalOptions->social["qqAppID"],
1183
  $qqAccessTokenURL = add_query_arg($accessTokenArgs, "https://graph.qq.com/oauth2.0/token");
1184
  $qqAccesTokenResponse = wp_remote_get($qqAccessTokenURL);
1185
  if (is_wp_error($qqAccesTokenResponse)) {
1186
+ $this->redirect($postID, $qqAccesTokenResponse->get_error_message());
1187
  }
1188
  $qqAccesTokenResponseBody = wp_remote_retrieve_body($qqAccesTokenResponse);
1189
  if (strpos($qqAccesTokenResponseBody, "callback") !== false) {
1192
  $qqAccesTokenResponseBody = substr($qqAccesTokenResponseBody, $lpos + 1, $rpos - $lpos - 1);
1193
  $qqAccesTokenResponseMsg = json_decode($qqAccesTokenResponseBody, true);
1194
  if (isset($qqAccesTokenResponseMsg["error"])) {
1195
+ $this->redirect($postID, $qqAccesTokenResponseMsg["error_description"]);
1196
  }
1197
  $qqAccesTokenData = array();
1198
  parse_str($qqAccesTokenResponseBody, $qqAccesTokenData);
1199
  if (!isset($qqAccesTokenData["access_token"])) {
1200
+ $this->redirect($postID, esc_html__("QQ authentication failed (access_token does not exist).", "wpdiscuz"));
1201
  }
1202
  $accessToken = $qqAccesTokenData["access_token"];
1203
  $qqOpenIdResponse = wp_remote_get("https://graph.qq.com/oauth2.0/me?access_token=" . $accessToken);
1204
  if (is_wp_error($qqOpenIdResponse)) {
1205
+ $this->redirect($postID, $qqOpenIdResponse->get_error_message());
1206
  }
1207
  $qqOpenIdResponseBody = wp_remote_retrieve_body($qqAccesTokenResponse);
1208
  if (strpos($qqOpenIdResponseBody, "callback") !== false) {
1212
  }
1213
  $qqOpenIdResponseMsg = json_decode($qqOpenIdResponseBody, true);
1214
  if (isset($qqOpenIdResponseMsg["error"])) {
1215
+ $this->redirect($postID, $qqOpenIdResponseMsg["error_description"]);
1216
  }
1217
  $openid = $qqOpenIdResponseMsg["openid"];
1218
  $qqGetUserDataAttributs = ["oauth_consumer_key" => $this->generalOptions->social["qqAppID"],
1222
  $qqGetUserDataURL = add_query_arg($qqGetUserDataAttributs, "https://graph.qq.com/user/get_user_info");
1223
  $getQQUserResponse = wp_remote_get($qqGetUserDataURL);
1224
  if (is_wp_error($getQQUserResponse)) {
1225
+ $this->redirect($postID, $getQQUserResponse->get_error_message());
1226
  }
1227
  $qqUserData = json_decode(wp_remote_retrieve_body($getQQUserResponse), true);
1228
  if (isset($qqUserData["error"])) {
1229
+ $this->redirect($postID, $qqUserData["error_description"]);
1230
  }
1231
  $qqUserData["openid"] = $openid;
1232
  $uID = Utils::addUser($qqUserData, "qq");
1233
  if (is_wp_error($uID)) {
1234
+ $this->redirect($postID, $uID->get_error_message());
1235
  }
1236
  $this->setCurrentUser($uID);
1237
+ $this->redirect($postID);
1238
  } else {
1239
+ $this->redirect($postID, esc_html__("QQ authentication failed (access_token does not exist).", "wpdiscuz"));
1240
  }
1241
  }
1242
 
1271
  $providerData = Utils::getProviderByState($state);
1272
  $provider = $providerData["provider"];
1273
  $postID = $providerData["postID"];
 
1274
  if ($error) {
1275
+ $this->redirect($postID, esc_html($errorDesc));
1276
  }
1277
  if (!$state || ($provider != "weibo")) {
1278
+ $this->redirect($postID, esc_html__("Weibo authentication failed (OAuth state does not exist).", "wpdiscuz"));
1279
  }
1280
  if (!$code) {
1281
+ $this->redirect($postID, esc_html__("Weibo authentication failed (code does not exist).", "wpdiscuz"));
1282
  }
1283
  $weiboCallBack = $this->createCallBackURL("weibo");
1284
  $weiboAccessTokenURL = "https://api.weibo.com/oauth2/access_token";
1290
  $weiboAccesTokenResponse = wp_remote_post($weiboAccessTokenURL, ["body" => $accessTokenArgs]);
1291
 
1292
  if (is_wp_error($weiboAccesTokenResponse)) {
1293
+ $this->redirect($postID, $weiboAccesTokenResponse->get_error_message());
1294
  }
1295
  $weiboAccesTokenData = json_decode(wp_remote_retrieve_body($weiboAccesTokenResponse), true);
1296
 
1297
  if (isset($weiboAccesTokenData["error"])) {
1298
+ $this->redirect($postID, $weiboAccesTokenData["error_description"]);
1299
  }
1300
  if (!isset($weiboAccesTokenData["access_token"])) {
1301
+ $this->redirect($postID, esc_html__("Weibo authentication failed (access_token does not exist).", "wpdiscuz"));
1302
  }
1303
  $accessToken = $weiboAccesTokenData["access_token"];
1304
  $uid = $weiboAccesTokenData["uid"];
1312
 
1313
  $getWeiboUserResponse = wp_remote_get($weiboGetUserDataURL, $weiboGetUserDataAttr);
1314
  if (is_wp_error($getWeiboUserResponse)) {
1315
+ $this->redirect($postID, $getWeiboUserResponse->get_error_message());
1316
  }
1317
  $weiboUserData = json_decode(wp_remote_retrieve_body($getWeiboUserResponse), true);
1318
  if (isset($weiboUserData["error"])) {
1319
+ $this->redirect($postID, $weiboUserData["error_description"]);
1320
  }
1321
  $uID = Utils::addUser($weiboUserData, "weibo");
1322
  if (is_wp_error($uID)) {
1323
+ $this->redirect($postID, $uID->get_error_message());
1324
  }
1325
  $this->setCurrentUser($uID);
1326
+ $this->redirect($postID);
1327
  }
1328
 
1329
  //https://developer.baidu.com/wiki/index.php?title=docs/oauth/application
1360
  $providerData = Utils::getProviderByState($state);
1361
  $provider = $providerData["provider"];
1362
  $postID = $providerData["postID"];
 
1363
  if ($error) {
1364
+ $this->redirect($postID, esc_html($errorDesc));
1365
  }
1366
  if (!$state || ($provider != "baidu")) {
1367
+ $this->redirect($postID, esc_html__("Baidu authentication failed (OAuth state does not exist).", "wpdiscuz"));
1368
  }
1369
  if (!$code) {
1370
+ $this->redirect($postID, esc_html__("Baidu authentication failed (code does not exist).", "wpdiscuz"));
1371
  }
1372
  $baiduCallBack = $this->createCallBackURL("baidu");
1373
  $baiduAccessTokenURL = "https://openapi.baidu.com/oauth/2.0/token";
1379
  $baiduAccesTokenResponse = wp_remote_post($baiduAccessTokenURL, ["body" => $accessTokenArgs]);
1380
 
1381
  if (is_wp_error($baiduAccesTokenResponse)) {
1382
+ $this->redirect($postID, $baiduAccesTokenResponse->get_error_message());
1383
  }
1384
  $baiduAccesTokenData = json_decode(wp_remote_retrieve_body($baiduAccesTokenResponse), true);
1385
 
1386
  if (isset($baiduAccesTokenData["error"])) {
1387
+ $this->redirect($postID, $baiduAccesTokenData["error_description"]);
1388
  }
1389
  if (!isset($baiduAccesTokenData["access_token"])) {
1390
+ $this->redirect($postID, esc_html__("Baidu authentication failed (access_token does not exist).", "wpdiscuz"));
1391
  }
1392
  $accessToken = $baiduAccesTokenData["access_token"];
1393
 
1394
  $getBaiduUserResponse = wp_remote_get("https://openapi.baidu.com/rest/2.0/passport/users/getLoggedInUser?access_token=" . $accessToken);
1395
  if (is_wp_error($getBaiduUserResponse)) {
1396
+ $this->redirect($postID, $getBaiduUserResponse->get_error_message());
1397
  }
1398
  $baiduUserData = json_decode(wp_remote_retrieve_body($getBaiduUserResponse), true);
1399
  if (isset($baiduUserData["error_code"])) {
1400
+ $this->redirect($postID, $baiduUserData["error_msg"]);
1401
  }
1402
  $uID = Utils::addUser($baiduUserData, "baidu");
1403
  if (is_wp_error($uID)) {
1404
+ $this->redirect($postID, $uID->get_error_message());
1405
  }
1406
  $this->setCurrentUser($uID);
1407
+ $this->redirect($postID);
1408
  }
1409
 
1410
+ private function redirect($postID, $message = "") {
1411
  if ($message) {
1412
  setcookie('wpdiscuz_social_login_message', $message, time() + 3600, '/');
1413
  }
1414
+ clean_post_cache($postID);
1415
+ wp_redirect($this->getPostLink($postID), 302);
1416
  exit();
1417
  }
1418
 
languages/wpdiscuz.pot CHANGED
@@ -3,7 +3,7 @@ msgid ""
3
  msgstr ""
4
  "Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
5
  "Project-Id-Version: wpDiscuz\n"
6
- "POT-Creation-Date: 2020-05-26 09:45+0000\n"
7
  "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
8
  "Last-Translator: \n"
9
  "Language-Team: \n"
@@ -27,115 +27,115 @@ msgstr ""
27
  msgid "Every 48 hours"
28
  msgstr ""
29
 
30
- #: class.WpdiscuzCore.php:900 class.WpdiscuzCore.php:1355
31
  msgid "Dashboard"
32
  msgstr ""
33
 
34
- #: class.WpdiscuzCore.php:901 class.WpdiscuzCore.php:1356 options/html-options.php:399 options/html-options.php:510
35
  msgid "Settings"
36
  msgstr ""
37
 
38
- #: class.WpdiscuzCore.php:903 class.WpdiscuzCore.php:1358
39
  msgid "Phrases"
40
  msgstr ""
41
 
42
- #: class.WpdiscuzCore.php:905
43
  msgid "Tools"
44
  msgstr ""
45
 
46
- #: class.WpdiscuzCore.php:906 options/html-options.php:26
47
  msgid "Addons"
48
  msgstr ""
49
 
50
- #: class.WpdiscuzCore.php:921
51
  msgid "Do you really want to reset all options?"
52
  msgstr ""
53
 
54
- #: class.WpdiscuzCore.php:922
55
  msgid "Do you really want to reset tab options?"
56
  msgstr ""
57
 
58
- #: class.WpdiscuzCore.php:923
59
  msgid "Do you really want to remove voting data?"
60
  msgstr ""
61
 
62
- #: class.WpdiscuzCore.php:924
63
  msgid "Do you really want to reset phrases?"
64
  msgstr ""
65
 
66
- #: class.WpdiscuzCore.php:925
67
  msgid "Do you really want to delet this attachment?"
68
  msgstr ""
69
 
70
- #: class.WpdiscuzCore.php:926
71
  msgid "Do you really want to delete gravatars cache?"
72
  msgstr ""
73
 
74
- #: class.WpdiscuzCore.php:982
75
  msgid "Please check one of reasons before sending feedback!"
76
  msgstr ""
77
 
78
- #: class.WpdiscuzCore.php:983 utils/deactivation-reason-modal.php:137
79
  msgid "Please provide more information"
80
  msgstr ""
81
 
82
- #: class.WpdiscuzCore.php:998 class.WpdiscuzCore.php:1766
83
  msgid "No text is selected. Please select a part of text from post content."
84
  msgstr ""
85
 
86
- #: class.WpdiscuzCore.php:1482 options/phrases-layouts/phrases-comment.php:56
87
  msgid "Admin"
88
  msgstr ""
89
 
90
- #: class.WpdiscuzCore.php:1485 class.WpdiscuzCore.php:1498 options/phrases-layouts/phrases-comment.php:58
91
  msgid "Author"
92
  msgstr ""
93
 
94
- #: class.WpdiscuzCore.php:1488 options/phrases-layouts/phrases-comment.php:60
95
  msgid "Editor"
96
  msgstr ""
97
 
98
- #: class.WpdiscuzCore.php:1491 options/phrases-layouts/phrases-comment.php:64
99
  msgid "Member"
100
  msgstr ""
101
 
102
- #: class.WpdiscuzCore.php:1499 options/phrases-layouts/phrases-comment.php:62
103
  msgid "Guest"
104
  msgstr ""
105
 
106
- #: class.WpdiscuzCore.php:1764
107
  msgid "Selected Text"
108
  msgstr ""
109
 
110
- #: class.WpdiscuzCore.php:1771
111
  msgid "Your Question to Readers"
112
  msgstr ""
113
 
114
- #: class.WpdiscuzCore.php:1772
115
  msgid "A simple question or a call to leave a feedback on the selected part of text. Something like &quot;By the way. Do you agree with this?&quot; or &quot;Would love your thoughts, please comment on this.&quot;"
116
  msgstr ""
117
 
118
- #: class.WpdiscuzCore.php:1777
119
  msgid "e.g: Any thoughts on this?"
120
  msgstr ""
121
 
122
- #: class.WpdiscuzCore.php:1782
123
  msgid "Feedback Button Display Type"
124
  msgstr ""
125
 
126
- #: class.WpdiscuzCore.php:1783
127
  msgid "By default the inline feedback form is closed and only the button is displayed. Once reader scrolled and reached to the selected text part, this button animates with comment button size and color changes attracting readers attention. Readers click on the button and open your question with feedback form. Using this option you can keep opened the feedback form. Readers can close it using [x] button."
128
  msgstr ""
129
 
130
- #: class.WpdiscuzCore.php:1791
131
  msgid "CLOSED"
132
  msgstr ""
133
 
134
- #: class.WpdiscuzCore.php:1800
135
  msgid "OPENED"
136
  msgstr ""
137
 
138
- #: class.WpdiscuzCore.php:1809
139
  msgid "Add Inline Feedback Button"
140
  msgstr ""
141
 
@@ -179,7 +179,7 @@ msgstr ""
179
  msgid "Post IDs"
180
  msgstr ""
181
 
182
- #: forms/wpDiscuzForm.php:176 forms/wpdFormAttr/Form.php:981
183
  msgid "Language"
184
  msgstr ""
185
 
@@ -191,7 +191,7 @@ msgstr ""
191
  msgid "Two column"
192
  msgstr ""
193
 
194
- #: forms/wpDiscuzForm.php:224 utils/class.WpdiscuzHelperUpload.php:657 forms/wpdFormAttr/Row.php:24 forms/wpdFormAttr/Field/Field.php:73
195
  msgid "Delete"
196
  msgstr ""
197
 
@@ -203,7 +203,7 @@ msgstr ""
203
  msgid "Add Field"
204
  msgstr ""
205
 
206
- #: forms/wpDiscuzForm.php:227 options/class.WpdiscuzOptions.php:325 options/phrases-layouts/phrases-comment.php:19 forms/wpdFormAttr/Field/Field.php:70
207
  msgid "Edit"
208
  msgstr ""
209
 
@@ -219,7 +219,7 @@ msgstr ""
219
  msgid "Permission Denied !!!"
220
  msgstr ""
221
 
222
- #: forms/wpDiscuzForm.php:257 forms/wpdFormAttr/Form.php:946 forms/wpdFormAttr/html/admin-form-fields-list.php:18
223
  msgid "Custom Fields"
224
  msgstr ""
225
 
@@ -231,23 +231,23 @@ msgstr ""
231
  msgid "Default Form"
232
  msgstr ""
233
 
234
- #: forms/wpDiscuzForm.php:403 options/html-phrases.php:21 forms/wpdFormAttr/Form.php:114 forms/wpdFormAttr/Form.php:1062 forms/wpdFormAttr/Form.php:1062 options/options-layouts/html-moderation.php:133
235
  msgid "Comment"
236
  msgstr ""
237
 
238
- #: forms/wpDiscuzForm.php:404 utils/class.WpdiscuzHelperAjax.php:901 forms/wpdFormAttr/Form.php:122 forms/wpdFormAttr/Form.php:1073 forms/wpdFormAttr/Form.php:1073
239
  msgid "Comments"
240
  msgstr ""
241
 
242
- #: forms/wpDiscuzForm.php:411 forms/wpdFormAttr/Form.php:174 forms/wpdFormAttr/Form.php:618 forms/wpdFormAttr/Form.php:1185 forms/wpdFormAttr/Form.php:1185
243
  msgid "Article Rating"
244
  msgstr ""
245
 
246
- #: forms/wpDiscuzForm.php:431 forms/wpdFormAttr/Form.php:1276 forms/wpdFormAttr/Field/AgreementCheckbox.php:12 forms/wpdFormAttr/Field/CheckboxField.php:12 forms/wpdFormAttr/Field/ColorField.php:12 forms/wpdFormAttr/Field/CookiesConsent.php:14 forms/wpdFormAttr/Field/DateField.php:12 forms/wpdFormAttr/Field/HTMLField.php:12 forms/wpdFormAttr/Field/NumberField.php:12 forms/wpdFormAttr/Field/RadioField.php:12 forms/wpdFormAttr/Field/RatingField.php:12 forms/wpdFormAttr/Field/SelectField.php:12 forms/wpdFormAttr/Field/TextAreaField.php:12 forms/wpdFormAttr/Field/TextField.php:12 forms/wpdFormAttr/Field/UrlField.php:12 forms/wpdFormAttr/Field/DefaultField/Email.php:19 forms/wpdFormAttr/Field/DefaultField/Name.php:18 forms/wpdFormAttr/Field/DefaultField/Name.php:67 forms/wpdFormAttr/Field/DefaultField/Submit.php:18 forms/wpdFormAttr/Field/DefaultField/Website.php:18
247
  msgid "Name"
248
  msgstr ""
249
 
250
- #: forms/wpDiscuzForm.php:433 options/class.WpdiscuzOptions.php:311 options/html-phrases.php:23 forms/wpdFormAttr/Form.php:1283 forms/wpdFormAttr/Field/DefaultField/Email.php:67
251
  msgid "Email"
252
  msgstr ""
253
 
@@ -255,7 +255,7 @@ msgstr ""
255
  msgid "WebSite URL"
256
  msgstr ""
257
 
258
- #: forms/wpDiscuzForm.php:438 forms/wpdFormAttr/Form.php:1306 forms/wpdFormAttr/Field/DefaultField/Submit.php:117
259
  msgid "Post Comment"
260
  msgstr ""
261
 
@@ -271,1901 +271,1909 @@ msgstr ""
271
  msgid "Add Comment Form"
272
  msgstr ""
273
 
274
- #: options/class.WpdiscuzOptions.php:305
275
  msgid "Be the First to Comment!"
276
  msgstr ""
277
 
278
- #: options/class.WpdiscuzOptions.php:306
279
  msgid "Start the discussion"
280
  msgstr ""
281
 
282
- #: options/class.WpdiscuzOptions.php:307
283
  msgid "Join the discussion"
284
  msgstr ""
285
 
286
- #: options/class.WpdiscuzOptions.php:308 options/phrases-layouts/phrases-form.php:19
287
  msgid "Most reacted comment"
288
  msgstr ""
289
 
290
- #: options/class.WpdiscuzOptions.php:309 options/phrases-layouts/phrases-form.php:23
291
  msgid "Hottest comment thread"
292
  msgstr ""
293
 
294
- #: options/class.WpdiscuzOptions.php:310 options/phrases-layouts/phrases-form.php:27
295
  msgid "Inline Comments"
296
  msgstr ""
297
 
298
- #: options/class.WpdiscuzOptions.php:312 options/phrases-layouts/phrases-form.php:35
299
  msgid "Subscribe"
300
  msgstr ""
301
 
302
- #: options/class.WpdiscuzOptions.php:313 options/phrases-layouts/phrases-form.php:39
303
  msgid "Notify of"
304
  msgstr ""
305
 
306
- #: options/class.WpdiscuzOptions.php:314
307
  msgid "new follow-up comments"
308
  msgstr ""
309
 
310
- #: options/class.WpdiscuzOptions.php:315
311
  msgid "new replies to my comments"
312
  msgstr ""
313
 
314
- #: options/class.WpdiscuzOptions.php:316
315
  msgid "Notify of new replies to this comment"
316
  msgstr ""
317
 
318
- #: options/class.WpdiscuzOptions.php:317 options/phrases-layouts/phrases-form.php:55
319
  msgid "Sort by"
320
  msgstr ""
321
 
322
- #: options/class.WpdiscuzOptions.php:318 options/phrases-layouts/phrases-form.php:59
323
  msgid "Newest"
324
  msgstr ""
325
 
326
- #: options/class.WpdiscuzOptions.php:319 options/phrases-layouts/phrases-form.php:63
327
  msgid "Oldest"
328
  msgstr ""
329
 
330
- #: options/class.WpdiscuzOptions.php:320 options/phrases-layouts/phrases-form.php:67
331
  msgid "Most Voted"
332
  msgstr ""
333
 
334
- #: options/class.WpdiscuzOptions.php:321
335
  msgid "Load More Comments"
336
  msgstr ""
337
 
338
- #: options/class.WpdiscuzOptions.php:322 options/phrases-layouts/phrases-general.php:19
339
  msgid "Load Rest of Comments"
340
  msgstr ""
341
 
342
- #: options/class.WpdiscuzOptions.php:323 options/options-layouts/html-moderation.php:135 options/phrases-layouts/phrases-comment.php:11
343
  msgid "Reply"
344
  msgstr ""
345
 
346
- #: options/class.WpdiscuzOptions.php:324 options/phrases-layouts/phrases-comment.php:15
347
  msgid "Share"
348
  msgstr ""
349
 
350
- #: options/class.WpdiscuzOptions.php:326 options/phrases-layouts/phrases-comment.php:23
351
  msgid "Share On Facebook"
352
  msgstr ""
353
 
354
- #: options/class.WpdiscuzOptions.php:327 options/phrases-layouts/phrases-comment.php:27
355
  msgid "Share On Twitter"
356
  msgstr ""
357
 
358
- #: options/class.WpdiscuzOptions.php:328 options/phrases-layouts/phrases-comment.php:31
359
  msgid "Share On WhatsApp"
360
  msgstr ""
361
 
362
- #: options/class.WpdiscuzOptions.php:329 options/phrases-layouts/phrases-comment.php:35
363
  msgid "Share On VKontakte"
364
  msgstr ""
365
 
366
- #: options/class.WpdiscuzOptions.php:330 options/phrases-layouts/phrases-comment.php:39
367
  msgid "Share On Odnoklassniki"
368
  msgstr ""
369
 
370
- #: options/class.WpdiscuzOptions.php:331 options/phrases-layouts/phrases-comment.php:43
371
  msgid "Hide Replies"
372
  msgstr ""
373
 
374
- #: options/class.WpdiscuzOptions.php:332 options/phrases-layouts/phrases-comment.php:47
375
  msgid "View Replies"
376
  msgstr ""
377
 
378
- #: options/class.WpdiscuzOptions.php:333 options/class.WpdiscuzOptions.php:453
379
  msgid "New Comment"
380
  msgstr ""
381
 
382
- #: options/class.WpdiscuzOptions.php:334
383
  msgid "Hi [SUBSCRIBER_NAME],<br/><br/> new comment have been posted by the <em><strong>[COMMENT_AUTHOR]</em></strong> on the discussion section you've been interested in<br/><br/><a href='[COMMENT_URL]'>[COMMENT_URL]</a><br/><br/>[COMMENT_CONTENT]<br/><br/><a href='[UNSUBSCRIBE_URL]'>Unsubscribe</a>"
384
  msgstr ""
385
 
386
- #: options/class.WpdiscuzOptions.php:335 options/class.WpdiscuzOptions.php:337
387
  msgid "New Reply"
388
  msgstr ""
389
 
390
- #: options/class.WpdiscuzOptions.php:336 options/class.WpdiscuzOptions.php:338
391
  msgid "Hi [SUBSCRIBER_NAME],<br/><br/> new reply have been posted by the <em><strong>[COMMENT_AUTHOR]</em></strong> on the discussion section you've been interested in<br/><br/><a href='[COMMENT_URL]'>[COMMENT_URL]</a><br/><br/>[COMMENT_CONTENT]<br/><br/><a href='[UNSUBSCRIBE_URL]'>Unsubscribe</a>"
392
  msgstr ""
393
 
394
- #: options/class.WpdiscuzOptions.php:339
395
  msgid "You're subscribed for new replies on this comment"
396
  msgstr ""
397
 
398
- #: options/class.WpdiscuzOptions.php:340
399
  msgid "You're subscribed for new replies on all your comments"
400
  msgstr ""
401
 
402
- #: options/class.WpdiscuzOptions.php:341
403
  msgid "You're subscribed for new follow-up comments on this post"
404
  msgstr ""
405
 
406
- #: options/class.WpdiscuzOptions.php:342 options/phrases-layouts/phrases-email.php:172
407
  msgid "Unsubscribe"
408
  msgstr ""
409
 
410
- #: options/class.WpdiscuzOptions.php:343
411
  msgid "Cancel subscription"
412
  msgstr ""
413
 
414
- #: options/class.WpdiscuzOptions.php:344 options/phrases-layouts/phrases-notification.php:19
415
  msgid "You've successfully unsubscribed."
416
  msgstr ""
417
 
418
- #: options/class.WpdiscuzOptions.php:345 options/phrases-layouts/phrases-notification.php:15
419
  msgid "You've successfully subscribed."
420
  msgstr ""
421
 
422
- #: options/class.WpdiscuzOptions.php:346 options/phrases-layouts/phrases-email.php:180
423
  msgid "Confirm your subscription"
424
  msgstr ""
425
 
426
- #: options/class.WpdiscuzOptions.php:347 options/phrases-layouts/phrases-email.php:184
427
  msgid "You've successfully confirmed your subscription."
428
  msgstr ""
429
 
430
- #: options/class.WpdiscuzOptions.php:348
431
  msgid "Subscription Confirmation"
432
  msgstr ""
433
 
434
- #: options/class.WpdiscuzOptions.php:349
435
  msgid "Hi, <br/> You just subscribed for new comments on our website. This means you will receive an email when new comments are posted according to subscription option you've chosen. <br/> To activate, click confirm below. If you believe this is an error, ignore this message and we'll never bother you again. <br/><br/><a href='[POST_URL]'>[POST_TITLE]</a><br/><br/><a href='[CONFIRM_URL]'>Confirm Your Subscrption</a><br/><br/><a href='[CANCEL_URL]'>Cancel Subscription</a>"
436
  msgstr ""
437
 
438
- #: options/class.WpdiscuzOptions.php:350
439
  msgid "please fill out this field to comment"
440
  msgstr ""
441
 
442
- #: options/class.WpdiscuzOptions.php:351
443
  msgid "email address is invalid"
444
  msgstr ""
445
 
446
- #: options/class.WpdiscuzOptions.php:352
447
  msgid "url is invalid"
448
  msgstr ""
449
 
450
- #: options/class.WpdiscuzOptions.php:353
451
  msgid "year"
452
  msgstr ""
453
 
454
- #: options/class.WpdiscuzOptions.php:354
455
  msgid "years"
456
  msgstr ""
457
 
458
- #: options/class.WpdiscuzOptions.php:355
459
  msgid "month"
460
  msgstr ""
461
 
462
- #: options/class.WpdiscuzOptions.php:356
463
  msgid "months"
464
  msgstr ""
465
 
466
- #: options/class.WpdiscuzOptions.php:357
467
  msgid "day"
468
  msgstr ""
469
 
470
- #: options/class.WpdiscuzOptions.php:358 options/options-layouts/html-general.php:248
471
  msgid "days"
472
  msgstr ""
473
 
474
- #: options/class.WpdiscuzOptions.php:359
475
  msgid "hour"
476
  msgstr ""
477
 
478
- #: options/class.WpdiscuzOptions.php:360
479
  msgid "hours"
480
  msgstr ""
481
 
482
- #: options/class.WpdiscuzOptions.php:361
483
  msgid "minute"
484
  msgstr ""
485
 
486
- #: options/class.WpdiscuzOptions.php:362
487
  msgid "minutes"
488
  msgstr ""
489
 
490
- #: options/class.WpdiscuzOptions.php:363
491
  msgid "second"
492
  msgstr ""
493
 
494
- #: options/class.WpdiscuzOptions.php:364 options/options-layouts/html-live.php:111 options/options-layouts/html-live.php:126
495
  msgid "seconds"
496
  msgstr ""
497
 
498
- #: options/class.WpdiscuzOptions.php:365
499
  msgid "right now"
500
  msgstr ""
501
 
502
- #: options/class.WpdiscuzOptions.php:366
503
  msgid "ago"
504
  msgstr ""
505
 
506
- #: options/class.WpdiscuzOptions.php:367 options/phrases-layouts/phrases-notification.php:38
507
  msgid "You must be"
508
  msgstr ""
509
 
510
- #: options/class.WpdiscuzOptions.php:368
511
  msgid "You are logged in as"
512
  msgstr ""
513
 
514
- #: options/class.WpdiscuzOptions.php:369 options/phrases-layouts/phrases-notification.php:29
515
  msgid "Login"
516
  msgstr ""
517
 
518
- #: options/class.WpdiscuzOptions.php:370 options/phrases-layouts/phrases-notification.php:33
519
  #, php-format
520
  msgid "Please %s to comment"
521
  msgstr ""
522
 
523
- #: options/class.WpdiscuzOptions.php:371 options/phrases-layouts/phrases-notification.php:54
524
  msgid "Log out"
525
  msgstr ""
526
 
527
- #: options/class.WpdiscuzOptions.php:372
528
  msgid "logged in"
529
  msgstr ""
530
 
531
- #: options/class.WpdiscuzOptions.php:373
532
  msgid "to post a comment."
533
  msgstr ""
534
 
535
- #: options/class.WpdiscuzOptions.php:374 options/phrases-layouts/phrases-comment.php:75
536
  msgid "Vote Up"
537
  msgstr ""
538
 
539
- #: options/class.WpdiscuzOptions.php:375 options/phrases-layouts/phrases-comment.php:79
540
  msgid "Vote Down"
541
  msgstr ""
542
 
543
- #: options/class.WpdiscuzOptions.php:376 options/phrases-layouts/phrases-notification.php:58
544
  msgid "Vote Counted"
545
  msgstr ""
546
 
547
- #: options/class.WpdiscuzOptions.php:377
548
  msgid "You've already voted for this comment"
549
  msgstr ""
550
 
551
- #: options/class.WpdiscuzOptions.php:378 options/phrases-layouts/phrases-error.php:27
552
  msgid "Voting Error"
553
  msgstr ""
554
 
555
- #: options/class.WpdiscuzOptions.php:379
556
  msgid "You Must Be Logged In To Vote"
557
  msgstr ""
558
 
559
- #: options/class.WpdiscuzOptions.php:380
560
  msgid "You cannot vote for your comment"
561
  msgstr ""
562
 
563
- #: options/class.WpdiscuzOptions.php:381
564
  msgid "You are not allowed to vote for this comment"
565
  msgstr ""
566
 
567
- #: options/class.WpdiscuzOptions.php:382 options/phrases-layouts/phrases-error.php:39
568
  msgid "Invalid Captcha Code"
569
  msgstr ""
570
 
571
- #: options/class.WpdiscuzOptions.php:383 options/phrases-layouts/phrases-error.php:43
572
  msgid "Some of field value is invalid"
573
  msgstr ""
574
 
575
- #: options/class.WpdiscuzOptions.php:384 options/phrases-layouts/phrases-notification.php:66
576
  msgid "Awaiting for approval"
577
  msgstr ""
578
 
579
- #: options/class.WpdiscuzOptions.php:385
580
  msgid "Sorry, the comment was not updated"
581
  msgstr ""
582
 
583
- #: options/class.WpdiscuzOptions.php:386
584
  msgid "Sorry, this comment is no longer possible to edit"
585
  msgstr ""
586
 
587
- #: options/class.WpdiscuzOptions.php:387
588
  msgid "You've not made any changes"
589
  msgstr ""
590
 
591
- #: options/class.WpdiscuzOptions.php:388 utils/class.WpdiscuzHelper.php:1135
592
  msgid "Save"
593
  msgstr ""
594
 
595
- #: options/class.WpdiscuzOptions.php:389
596
  msgid "Cancel"
597
  msgstr ""
598
 
599
- #: options/class.WpdiscuzOptions.php:390
600
  msgid "Input is too short"
601
  msgstr ""
602
 
603
- #: options/class.WpdiscuzOptions.php:391
604
  msgid "Input is too long"
605
  msgstr ""
606
 
607
- #: options/class.WpdiscuzOptions.php:392
608
  msgid "Read more &raquo;"
609
  msgstr ""
610
 
611
- #: options/class.WpdiscuzOptions.php:393
612
  msgid "Anonymous"
613
  msgstr ""
614
 
615
- #: options/class.WpdiscuzOptions.php:394 options/phrases-layouts/phrases-error.php:67
616
  msgid "Please fill out required fields"
617
  msgstr ""
618
 
619
- #: options/class.WpdiscuzOptions.php:395 options/phrases-layouts/phrases-social-login.php:11
620
  msgid "Connect with"
621
  msgstr ""
622
 
623
- #: options/class.WpdiscuzOptions.php:396 options/phrases-layouts/phrases-notification.php:11
624
  msgid "You're subscribed to"
625
  msgstr ""
626
 
627
- #: options/class.WpdiscuzOptions.php:397
628
  msgid "Participate in this discussion via email"
629
  msgstr ""
630
 
631
- #: options/class.WpdiscuzOptions.php:398 utils/layouts/pagination.php:45
632
  msgid "&rsaquo;"
633
  msgstr ""
634
 
635
- #: options/class.WpdiscuzOptions.php:399
636
  msgid "Your comment is approved!"
637
  msgstr ""
638
 
639
- #: options/class.WpdiscuzOptions.php:400
640
  msgid "Hi [COMMENT_AUTHOR],<br/><br/>your comment was approved.<br/><br/><a href=\"[COMMENT_URL]\">[COMMENT_URL]</a><br/><br/>[COMMENT_CONTENT]"
641
  msgstr ""
642
 
643
- #: options/class.WpdiscuzOptions.php:401
644
  msgid "Comments are closed."
645
  msgstr ""
646
 
647
- #: options/class.WpdiscuzOptions.php:402
648
  msgid "Stick this comment"
649
  msgstr ""
650
 
651
- #: options/class.WpdiscuzOptions.php:403 options/phrases-layouts/phrases-comment.php:103
652
  msgid "Stick"
653
  msgstr ""
654
 
655
- #: options/class.WpdiscuzOptions.php:404 options/phrases-layouts/phrases-comment.php:107
656
  msgid "Unstick"
657
  msgstr ""
658
 
659
- #: options/class.WpdiscuzOptions.php:405
660
  msgid "Sticky Comment Thread"
661
  msgstr ""
662
 
663
- #: options/class.WpdiscuzOptions.php:406
664
  msgid "Close this thread"
665
  msgstr ""
666
 
667
- #: options/class.WpdiscuzOptions.php:407 options/html-dashboard.php:34 options/phrases-layouts/phrases-comment.php:119
668
  msgid "Close"
669
  msgstr ""
670
 
671
- #: options/class.WpdiscuzOptions.php:408 options/phrases-layouts/phrases-comment.php:123
672
  msgid "Open"
673
  msgstr ""
674
 
675
- #: options/class.WpdiscuzOptions.php:409
676
  msgid "Closed Comment Thread"
677
  msgstr ""
678
 
679
- #: options/class.WpdiscuzOptions.php:410
680
  msgid "I allow to create an account"
681
  msgstr ""
682
 
683
- #: options/class.WpdiscuzOptions.php:411
684
  msgid "When you login first time using a Social Login button, we collect your account public profile information shared by Social Login provider, based on your privacy settings. We also get your email address to automatically create an account for you in our website. Once your account is created, you'll be logged-in to this account."
685
  msgstr ""
686
 
687
- #: options/class.WpdiscuzOptions.php:412 options/phrases-layouts/phrases-social-login.php:23
688
  msgid "Disagree"
689
  msgstr ""
690
 
691
- #: options/class.WpdiscuzOptions.php:413 options/phrases-layouts/phrases-social-login.php:27
692
  msgid "Agree"
693
  msgstr ""
694
 
695
- #: options/class.WpdiscuzOptions.php:414 options/phrases-layouts/phrases-user-settings.php:11
696
  msgid "My content and settings"
697
  msgstr ""
698
 
699
- #: options/class.WpdiscuzOptions.php:415 options/phrases-layouts/phrases-user-settings.php:15
700
  msgid "Activity"
701
  msgstr ""
702
 
703
- #: options/class.WpdiscuzOptions.php:416 options/html-dashboard.php:201 utils/class.WpdiscuzHelperAjax.php:905 options/phrases-layouts/phrases-user-settings.php:19
704
  msgid "Subscriptions"
705
  msgstr ""
706
 
707
- #: options/class.WpdiscuzOptions.php:417 options/phrases-layouts/phrases-user-settings.php:23
708
  msgid "Follows"
709
  msgstr ""
710
 
711
- #: options/class.WpdiscuzOptions.php:418 options/phrases-layouts/phrases-user-settings.php:27
712
  msgid "In response to:"
713
  msgstr ""
714
 
715
- #: options/class.WpdiscuzOptions.php:419 options/class.WpdiscuzOptions.php:425 options/phrases-layouts/phrases-user-settings.php:31 options/phrases-layouts/phrases-user-settings.php:55
716
  msgid "Bulk management via email"
717
  msgstr ""
718
 
719
- #: options/class.WpdiscuzOptions.php:420
720
  msgid "Click the button above to get an email with bulk delete and unsubscribe links."
721
  msgstr ""
722
 
723
- #: options/class.WpdiscuzOptions.php:421 options/phrases-layouts/phrases-user-settings.php:39
724
  msgid "No data found!"
725
  msgstr ""
726
 
727
- #: options/class.WpdiscuzOptions.php:422 options/class.WpdiscuzOptions.php:426 options/phrases-layouts/phrases-user-settings.php:43 options/phrases-layouts/phrases-user-settings.php:60
728
  msgid "Delete all my comments"
729
  msgstr ""
730
 
731
- #: options/class.WpdiscuzOptions.php:423 options/phrases-layouts/phrases-user-settings.php:47
732
  msgid "Cancel all comment subscriptions"
733
  msgstr ""
734
 
735
- #: options/class.WpdiscuzOptions.php:424 options/phrases-layouts/phrases-user-settings.php:51
736
  msgid "Clear cookies with my personal data"
737
  msgstr ""
738
 
739
- #: options/class.WpdiscuzOptions.php:427
740
  msgid "Please use this link to delete all your comments. Please note, that this action cannot be undone.<br/><br/><a href=\"[DELETE_COMMENTS_URL]\" target=\"_blank\">Delete all my comments</a><br/><br/>"
741
  msgstr ""
742
 
743
- #: options/class.WpdiscuzOptions.php:428 options/phrases-layouts/phrases-user-settings.php:85
744
  msgid "Delete all my subscriptions"
745
  msgstr ""
746
 
747
- #: options/class.WpdiscuzOptions.php:429
748
  msgid "Please use this link to cancel all subscriptions for new comments. Please note, that this action cannot be undone.<br/><br/><a href=\"[DELETE_SUBSCRIPTIONS_URL]\" target=\"_blank\">Delete all my subscriptions</a><br/><br/>"
749
  msgstr ""
750
 
751
- #: options/class.WpdiscuzOptions.php:430 options/phrases-layouts/phrases-user-settings.php:110
752
  msgid "Delete all my follows"
753
  msgstr ""
754
 
755
- #: options/class.WpdiscuzOptions.php:431
756
  msgid "Please use this link to cancel all follows for new comments. Please note, that this action cannot be undone.<br/><br/><a href=\"[DELETE_FOLLOWS_URL]\" target=\"_blank\">Delete all my follows</a><br/><br/>"
757
  msgstr ""
758
 
759
- #: options/class.WpdiscuzOptions.php:432 options/phrases-layouts/phrases-user-settings.php:134
760
  msgid "subscribed to this comment"
761
  msgstr ""
762
 
763
- #: options/class.WpdiscuzOptions.php:433 options/phrases-layouts/phrases-user-settings.php:138
764
  msgid "subscribed to my comments"
765
  msgstr ""
766
 
767
- #: options/class.WpdiscuzOptions.php:434 options/phrases-layouts/phrases-user-settings.php:142
768
  msgid "subscribed to all follow-up comments of this post"
769
  msgstr ""
770
 
771
- #: options/class.WpdiscuzOptions.php:436 options/phrases-layouts/phrases-user-settings.php:150
772
  msgid "Error : Can't send email."
773
  msgstr ""
774
 
775
- #: options/class.WpdiscuzOptions.php:437 options/phrases-layouts/phrases-user-settings.php:154
776
  msgid "Are you sure you want to delete this comment?"
777
  msgstr ""
778
 
779
- #: options/class.WpdiscuzOptions.php:438 options/phrases-layouts/phrases-user-settings.php:158
780
  msgid "Are you sure you want to cancel this subscription?"
781
  msgstr ""
782
 
783
- #: options/class.WpdiscuzOptions.php:439 options/phrases-layouts/phrases-user-settings.php:162
784
  msgid "Are you sure you want to cancel this follow?"
785
  msgstr ""
786
 
787
- #: options/class.WpdiscuzOptions.php:440 options/phrases-layouts/phrases-follow.php:11
788
  msgid "Follow this user"
789
  msgstr ""
790
 
791
- #: options/class.WpdiscuzOptions.php:441 options/phrases-layouts/phrases-follow.php:15
792
  msgid "Unfollow this user"
793
  msgstr ""
794
 
795
- #: options/class.WpdiscuzOptions.php:442 options/phrases-layouts/phrases-follow.php:19
796
  msgid "You started following this comment author"
797
  msgstr ""
798
 
799
- #: options/class.WpdiscuzOptions.php:443
800
  msgid "You stopped following this comment author."
801
  msgstr ""
802
 
803
- #: options/class.WpdiscuzOptions.php:444
804
  msgid "Please check your email and confirm the user following request."
805
  msgstr ""
806
 
807
- #: options/class.WpdiscuzOptions.php:445
808
  msgid "Sorry, we couldn't send confirmation email."
809
  msgstr ""
810
 
811
- #: options/class.WpdiscuzOptions.php:446
812
  msgid "Please login to follow users."
813
  msgstr ""
814
 
815
- #: options/class.WpdiscuzOptions.php:447
816
  msgid "We are sorry, but you can't follow this user."
817
  msgstr ""
818
 
819
- #: options/class.WpdiscuzOptions.php:448
820
  msgid "Following failed. Please try again later."
821
  msgstr ""
822
 
823
- #: options/class.WpdiscuzOptions.php:449
824
  msgid "Confirm user following request"
825
  msgstr ""
826
 
827
- #: options/class.WpdiscuzOptions.php:450
828
  msgid "Cancel user following request"
829
  msgstr ""
830
 
831
- #: options/class.WpdiscuzOptions.php:451
832
  msgid "User Following Confirmation"
833
  msgstr ""
834
 
835
- #: options/class.WpdiscuzOptions.php:452 options/class.WpdiscuzOptions.php:454
836
  msgid "</a>"
837
  msgstr ""
838
 
839
- #: options/class.WpdiscuzOptions.php:455
840
  msgid "You have been mentioned in comment"
841
  msgstr ""
842
 
843
- #: options/class.WpdiscuzOptions.php:456
844
  msgid "Hi [MENTIONED_USER_NAME]!<br/>You have been mentioned in a comment posted on \"[POST_TITLE]\" post by [COMMENT_AUTHOR].<br/><br/>Comment URL: <a href=\"[COMMENT_URL]\">[COMMENT_URL]</a>"
845
  msgstr ""
846
 
847
- #: options/class.WpdiscuzOptions.php:457 options/phrases-layouts/phrases-general.php:23
848
  msgid "Copied to clipboard!"
849
  msgstr ""
850
 
851
- #: options/class.WpdiscuzOptions.php:458 options/phrases-layouts/phrases-general.php:27
852
  msgid "Select a part of text and ask readers for feedback (inline commenting)"
853
  msgstr ""
854
 
855
- #: options/class.WpdiscuzOptions.php:459 options/phrases-layouts/phrases-general.php:31
856
  msgid "Ask for Feedback"
857
  msgstr ""
858
 
859
- #: options/class.WpdiscuzOptions.php:460 options/phrases-layouts/phrases-general.php:35
860
  msgid "Please leave a feedback on this"
861
  msgstr ""
862
 
863
- #: options/class.WpdiscuzOptions.php:462 utils/deactivation-reason-modal.php:157
864
  msgid "Thank you for your feedback!"
865
  msgstr ""
866
 
867
- #: options/class.WpdiscuzOptions.php:463
868
  msgid "Commenting is closed!"
869
  msgstr ""
870
 
871
- #: options/class.WpdiscuzOptions.php:464 options/phrases-layouts/phrases-general.php:51
872
  msgid "This is closed comment thread"
873
  msgstr ""
874
 
875
- #: options/class.WpdiscuzOptions.php:465
876
  msgid "Would love your thoughts, please comment."
877
  msgstr ""
878
 
879
- #: options/class.WpdiscuzOptions.php:466 options/phrases-layouts/phrases-general.php:59
880
  msgid "vote"
881
  msgstr ""
882
 
883
- #: options/class.WpdiscuzOptions.php:467 options/phrases-layouts/phrases-general.php:63
884
  msgid "votes"
885
  msgstr ""
886
 
887
- #: options/class.WpdiscuzOptions.php:468 options/phrases-layouts/phrases-general.php:67
888
  msgid "Comment Link"
889
  msgstr ""
890
 
891
- #: options/class.WpdiscuzOptions.php:469 options/class.WpdiscuzOptions.php:470
892
  #, php-format
893
  msgid "We are sorry, you are not allowed to comment more than %d time(s)!"
894
  msgstr ""
895
 
896
- #: options/class.WpdiscuzOptions.php:471
897
  #, php-format
898
  msgid "We are sorry, you are not allowed to reply more than %d time(s)!"
899
  msgstr ""
900
 
901
- #: options/class.WpdiscuzOptions.php:472 options/phrases-layouts/phrases-general.php:83
902
  msgid "Your comment here..."
903
  msgstr ""
904
 
905
- #: options/class.WpdiscuzOptions.php:473 options/phrases-layouts/phrases-general.php:87
906
  msgid "Notify me via email when a new reply is posted"
907
  msgstr ""
908
 
909
- #: options/class.WpdiscuzOptions.php:474 options/phrases-layouts/phrases-general.php:91
910
  msgid "Your Name*"
911
  msgstr ""
912
 
913
- #: options/class.WpdiscuzOptions.php:475 options/phrases-layouts/phrases-general.php:95
914
  msgid "Your Email"
915
  msgstr ""
916
 
917
- #: options/class.WpdiscuzOptions.php:476 options/phrases-layouts/phrases-general.php:99
918
  msgid "COMMENT"
919
  msgstr ""
920
 
921
- #: options/class.WpdiscuzOptions.php:477 options/phrases-layouts/phrases-general.php:103
922
  msgid "View all comments"
923
  msgstr ""
924
 
925
- #: options/class.WpdiscuzOptions.php:478 options/html-dashboard.php:127 options/phrases-layouts/phrases-general.php:107
926
  msgid "Inline Feedbacks"
927
  msgstr ""
928
 
929
- #: options/class.WpdiscuzOptions.php:479 options/phrases-layouts/phrases-general.php:111
930
  msgid "Unable to send an email"
931
  msgstr ""
932
 
933
- #: options/class.WpdiscuzOptions.php:480 options/phrases-layouts/phrases-general.php:115
934
  msgid "Subscription Fault"
935
  msgstr ""
936
 
937
- #: options/class.WpdiscuzOptions.php:481 options/phrases-layouts/phrases-general.php:119
938
  msgid "Your comments have been deleted from database"
939
  msgstr ""
940
 
941
- #: options/class.WpdiscuzOptions.php:482 options/phrases-layouts/phrases-general.php:123
942
  msgid "You cancel all your subscriptions successfully"
943
  msgstr ""
944
 
945
- #: options/class.WpdiscuzOptions.php:483 options/phrases-layouts/phrases-general.php:127
946
  msgid "You cancel all your follows successfully"
947
  msgstr ""
948
 
949
- #: options/class.WpdiscuzOptions.php:484 options/phrases-layouts/phrases-general.php:131
950
  msgid "Follow has been confirmed successfully"
951
  msgstr ""
952
 
953
- #: options/class.WpdiscuzOptions.php:485 options/phrases-layouts/phrases-general.php:135
954
  msgid "Follow has been canceled successfully"
955
  msgstr ""
956
 
957
- #: options/class.WpdiscuzOptions.php:486 options/phrases-layouts/phrases-general.php:139
958
  msgid "Please login to comment"
959
  msgstr ""
960
 
961
- #: options/class.WpdiscuzOptions.php:487 options/phrases-layouts/phrases-general.php:143
962
  msgid "View Comments"
963
  msgstr ""
964
 
965
- #: options/class.WpdiscuzOptions.php:488 options/options-layouts/html-form.php:111 options/phrases-layouts/phrases-general.php:147
966
  msgid "Spoiler"
967
  msgstr ""
968
 
969
- #: options/class.WpdiscuzOptions.php:489 options/phrases-layouts/phrases-general.php:151
970
  #, php-format
971
  msgid "Last edited %1$s by %2$s"
972
  msgstr ""
973
 
974
- #: options/class.WpdiscuzOptions.php:490 options/phrases-layouts/phrases-general.php:155
975
  msgid "Reply to"
976
  msgstr ""
977
 
978
- #: options/class.WpdiscuzOptions.php:491 options/phrases-layouts/phrases-general.php:159
979
  msgid "Manage Comment"
980
  msgstr ""
981
 
982
- #: options/class.WpdiscuzOptions.php:492 options/phrases-layouts/phrases-general.php:163
983
  msgid "Spoiler Title"
984
  msgstr ""
985
 
986
- #: options/class.WpdiscuzOptions.php:493 options/phrases-layouts/phrases-general.php:167
987
  msgid "You cannot rate again"
988
  msgstr ""
989
 
990
- #: options/class.WpdiscuzOptions.php:494 options/phrases-layouts/phrases-general.php:171
991
  msgid "You're not allowed to rate here"
992
  msgstr ""
993
 
994
- #: options/class.WpdiscuzOptions.php:496
995
  msgid "Are you sure you want to delete this attachment?"
996
  msgstr ""
997
 
998
- #: options/class.WpdiscuzOptions.php:497
999
  msgid "Not allowed file type"
1000
  msgstr ""
1001
 
1002
- #: options/class.WpdiscuzOptions.php:498
1003
  msgid "Maximum number of uploaded files is"
1004
  msgstr ""
1005
 
1006
- #: options/class.WpdiscuzOptions.php:499
1007
  msgid "Maximum upload file size is"
1008
  msgstr ""
1009
 
1010
- #: options/class.WpdiscuzOptions.php:500
1011
  msgid "Maximum post size is"
1012
  msgstr ""
1013
 
1014
- #: options/class.WpdiscuzOptions.php:501 options/phrases-layouts/phrases-media.php:31
1015
  msgid "Attach an image to this comment"
1016
  msgstr ""
1017
 
1018
- #: options/class.WpdiscuzOptions.php:502 options/phrases-layouts/phrases-media.php:35
1019
  msgid "Change the attached image"
1020
  msgstr ""
1021
 
1022
- #: options/class.WpdiscuzOptions.php:1083
1023
  msgid "Post ID not exists"
1024
  msgstr ""
1025
 
1026
- #: options/class.WpdiscuzOptions.php:1084
1027
  msgid "Sorry, uploading not allowed for this post"
1028
  msgstr ""
1029
 
1030
- #: options/class.WpdiscuzOptions.php:1085
1031
  msgid "You do not have sufficient permissions to perform this action"
1032
  msgstr ""
1033
 
1034
- #: options/class.WpdiscuzOptions.php:1157 options/class.WpdiscuzOptions.php:1396 options/class.WpdiscuzOptions.php:1739
1035
  msgid "Hacker?"
1036
  msgstr ""
1037
 
1038
- #: options/class.WpdiscuzOptions.php:1652
1039
  msgid "Settings updated"
1040
  msgstr ""
1041
 
1042
- #: options/class.WpdiscuzOptions.php:1659
1043
  msgid "Phrases updated"
1044
  msgstr ""
1045
 
1046
- #: options/class.WpdiscuzOptions.php:1683
1047
  msgid "Options were backed up!"
1048
  msgstr ""
1049
 
1050
- #: options/class.WpdiscuzOptions.php:1685
1051
  msgid "Cannot back up the options!"
1052
  msgstr ""
1053
 
1054
- #: options/class.WpdiscuzOptions.php:1696
1055
  msgid "Options Imported Successfully!"
1056
  msgstr ""
1057
 
1058
- #: options/class.WpdiscuzOptions.php:1698 options/class.WpdiscuzOptions.php:1728
1059
  msgid "Error occured! File content is empty or data is not valid!"
1060
  msgstr ""
1061
 
1062
- #: options/class.WpdiscuzOptions.php:1701 options/class.WpdiscuzOptions.php:1731
1063
  msgid "Error occured! Can not get file content!"
1064
  msgstr ""
1065
 
1066
- #: options/class.WpdiscuzOptions.php:1704 options/class.WpdiscuzOptions.php:1734
1067
  msgid "Error occured! Please choose file!"
1068
  msgstr ""
1069
 
1070
- #: options/class.WpdiscuzOptions.php:1713
1071
  msgid "Phrases were backed up!"
1072
  msgstr ""
1073
 
1074
- #: options/class.WpdiscuzOptions.php:1715
1075
  msgid "Cannot back up the phrases!"
1076
  msgstr ""
1077
 
1078
- #: options/class.WpdiscuzOptions.php:1726
1079
  msgid "Phrases Imported Successfully!"
1080
  msgstr ""
1081
 
1082
- #: options/class.WpdiscuzOptions.php:1750
1083
  msgid "All 16 addons in one bundle. Save 90% and get Unlimited Site License with one year premium support."
1084
  msgstr ""
1085
 
1086
- #: options/class.WpdiscuzOptions.php:1751
1087
  msgid "Extended comment attachment system. Allows to upload images, videos, audios and other file types."
1088
  msgstr ""
1089
 
1090
- #: options/class.WpdiscuzOptions.php:1752
1091
  msgid "All in one powerful yet simple admin toolkit to moderate comments on front-end."
1092
  msgstr ""
1093
 
1094
- #: options/class.WpdiscuzOptions.php:1753
1095
  msgid "Brings an ocean of emotions to your comments. It comes with an awesome smile package."
1096
  msgstr ""
1097
 
1098
- #: options/class.WpdiscuzOptions.php:1754
1099
  msgid "Adds Invisible reCAPTCHA on all comment forms. Stops spam and bot comments with reCAPTCHA version 3"
1100
  msgstr ""
1101
 
1102
- #: options/class.WpdiscuzOptions.php:1755
1103
  msgid "Extended information about comment author with Profile, Activity, Votes and Subscriptions Tabs on pop-up window."
1104
  msgstr ""
1105
 
1106
- #: options/class.WpdiscuzOptions.php:1756
1107
  msgid "Comment reporting tools. Auto-moderates comments based on number of flags and dislikes."
1108
  msgstr ""
1109
 
1110
- #: options/class.WpdiscuzOptions.php:1757
1111
  msgid "Real-time online user checking, pop-up notification of new online users and online/offline badges."
1112
  msgstr ""
1113
 
1114
- #: options/class.WpdiscuzOptions.php:1758
1115
  msgid "Allows to create private comment threads. Rich management options in dashboard by user roles."
1116
  msgstr ""
1117
 
1118
- #: options/class.WpdiscuzOptions.php:1759
1119
  msgid "Total control over comment subscriptions. Full list, monitor, manage, filter, unsubscribe, confirm..."
1120
  msgstr ""
1121
 
1122
- #: options/class.WpdiscuzOptions.php:1760
1123
  msgid "A full-fledged tool-kit for advertising in comment section of your website. Separate banner and ad managment."
1124
  msgstr ""
1125
 
1126
- #: options/class.WpdiscuzOptions.php:1761
1127
  msgid "Allows to mention comments and users in comment text using #comment-id and @username tags."
1128
  msgstr ""
1129
 
1130
- #: options/class.WpdiscuzOptions.php:1762
1131
  msgid "See comment likers and voters of each comment. Adds user reputation and badges based on received likes."
1132
  msgstr ""
1133
 
1134
- #: options/class.WpdiscuzOptions.php:1763
1135
  msgid "Adds a smart and intuitive AJAX \"Translate\" button with 60 language options. Uses free translation API."
1136
  msgstr ""
1137
 
1138
- #: options/class.WpdiscuzOptions.php:1764
1139
  msgid "AJAX powered front-end comment search. It starts searching while you type search words. "
1140
  msgstr ""
1141
 
1142
- #: options/class.WpdiscuzOptions.php:1765
1143
  msgid "Most voted comments, Active comment threads, Most commented posts, Active comment authors"
1144
  msgstr ""
1145
 
1146
- #: options/class.WpdiscuzOptions.php:1766
1147
  msgid "Integrates myCRED Badges and Ranks. Converts wpDiscuz comment votes/likes to myCRED points. "
1148
  msgstr ""
1149
 
1150
- #: options/class.WpdiscuzOptions.php:1772
1151
  msgid "Custom Comment Forms"
1152
  msgstr ""
1153
 
1154
- #: options/class.WpdiscuzOptions.php:1773
1155
  msgid "You can create custom comment forms with wpDiscuz. wpDiscuz 4 comes with custom comment forms and fields. You can create custom comment forms for each post type, each form can beceated with different form fields, for eaxample: text, dropdown, rating, checkboxes, etc..."
1156
  msgstr ""
1157
 
1158
- #: options/class.WpdiscuzOptions.php:1776
1159
  msgid "Emoticons"
1160
  msgstr ""
1161
 
1162
- #: options/class.WpdiscuzOptions.php:1777
1163
  msgid "You can add more emotions to your comments using wpDiscuz Emoticons addon."
1164
  msgstr ""
1165
 
1166
- #: options/class.WpdiscuzOptions.php:1780
1167
  msgid "Ads Manager"
1168
  msgstr ""
1169
 
1170
- #: options/class.WpdiscuzOptions.php:1781
1171
  msgid "Increase your income using ad banners. Comment area is the most active sections for advertising. wpDiscuz Ads Manager addon is designed to help you add banners and control ads in this section."
1172
  msgstr ""
1173
 
1174
- #: options/class.WpdiscuzOptions.php:1784
1175
  msgid "User and Comment Mentioning"
1176
  msgstr ""
1177
 
1178
- #: options/class.WpdiscuzOptions.php:1785
1179
  msgid "Using wpDiscuz User &amp; Comment Mentioning addon you can allow commenters mention comments and users in comment text using #comment-id and @username tags."
1180
  msgstr ""
1181
 
1182
- #: options/class.WpdiscuzOptions.php:1788 options/addons/al/title.php:7
1183
  msgid "Advanced Likers"
1184
  msgstr ""
1185
 
1186
- #: options/class.WpdiscuzOptions.php:1789
1187
  msgid "wpDiscuz Advanced Likers addon displays likers and voters of each comment. Adds user reputation and badges based on received likes."
1188
  msgstr ""
1189
 
1190
- #: options/class.WpdiscuzOptions.php:1792 options/addons/raf/title.php:7
1191
  msgid "Report and Flagging"
1192
  msgstr ""
1193
 
1194
- #: options/class.WpdiscuzOptions.php:1793
1195
  msgid "Let your commenters help you to determine and remove spam comments. wpDiscuz Report and Flagging addon comes with comment reporting tools. Automaticaly auto-moderates comments based on number of flags and dislikes."
1196
  msgstr ""
1197
 
1198
- #: options/class.WpdiscuzOptions.php:1796
1199
  msgid "Comment Translate"
1200
  msgstr ""
1201
 
1202
- #: options/class.WpdiscuzOptions.php:1797
1203
  msgid "In most cases the big part of your visitors are not a native speakers of your language. Make your comments comprehensible for all visitors using wpDiscuz Comment Translation addon. It adds smart and intuitive AJAX 'Translate' button with 60 language translation options. Uses free translation API."
1204
  msgstr ""
1205
 
1206
- #: options/class.WpdiscuzOptions.php:1800
1207
  msgid "Comment Search"
1208
  msgstr ""
1209
 
1210
- #: options/class.WpdiscuzOptions.php:1801
1211
  msgid "You can let website visitor search in comments. It's always more attractive to find a comment about something that interest you. Using wpDiscuz Comment Search addon you'll get a nice, AJAX powered front-end comment search form above comment list."
1212
  msgstr ""
1213
 
1214
- #: options/class.WpdiscuzOptions.php:1804
1215
  msgid "wpDiscuz Widgets"
1216
  msgstr ""
1217
 
1218
- #: options/class.WpdiscuzOptions.php:1805
1219
  msgid "More Comment Widgets! Most voted comments, Active comment threads, Most commented posts, Active comment authors widgets are available in wpDiscuz Widgets Addon"
1220
  msgstr ""
1221
 
1222
- #: options/class.WpdiscuzOptions.php:1808
1223
  msgid "Front-end Moderation"
1224
  msgstr ""
1225
 
1226
- #: options/class.WpdiscuzOptions.php:1809
1227
  msgid "You can moderate comments on front-end using all in one powerful yet simple wpDiscuz Frontend Moderation addon."
1228
  msgstr ""
1229
 
1230
- #: options/class.WpdiscuzOptions.php:1812 options/addons/mu/title.php:7
1231
  msgid "Media Uploader"
1232
  msgstr ""
1233
 
1234
- #: options/class.WpdiscuzOptions.php:1813
1235
  msgid "You can let website visitors attach images and files to comments and embed video/audio content using wpDiscuz Media Uploader addon."
1236
  msgstr ""
1237
 
1238
- #: options/class.WpdiscuzOptions.php:1816
1239
  msgid "Google ReCaptcha"
1240
  msgstr ""
1241
 
1242
- #: options/class.WpdiscuzOptions.php:1817
1243
  msgid "Advanced spam protection with wpDiscuz Google reCAPTCHA addon. This addon adds No-CAPTCHA reCAPTCHA on all comment forms. Stops spam and bot comments."
1244
  msgstr ""
1245
 
1246
- #: options/class.WpdiscuzOptions.php:1833
1247
  msgid "Finally wpDiscuz Addons Bundle is ready for You!"
1248
  msgstr ""
1249
 
1250
- #: options/class.WpdiscuzOptions.php:1843
1251
  msgid "View Addons Bundle"
1252
  msgstr ""
1253
 
1254
- #: options/class.WpdiscuzOptions.php:1931
1255
  msgid "Please complete required steps to start using wpDiscuz 7"
1256
  msgstr ""
1257
 
1258
- #: options/class.WpdiscuzOptions.php:1932
1259
  msgid "Go to Update Wizard &raquo;"
1260
  msgstr ""
1261
 
1262
- #: options/class.WpdiscuzOptions.php:1932
1263
  msgid "Go to Installation Wizard &raquo;"
1264
  msgstr ""
1265
 
1266
- #: options/class.WpdiscuzOptions.php:1941
1267
  msgid "Jetpack Comments are active."
1268
  msgstr ""
1269
 
1270
- #: options/class.WpdiscuzOptions.php:1950
1271
  msgid "Comment votes meta data need to be regenerated"
1272
  msgstr ""
1273
 
1274
- #: options/class.WpdiscuzOptions.php:1951 options/html-tools.php:20 options/tools-layouts/regenerate-vote-metas.php:10 options/tools-layouts/regenerate-vote-metas.php:18
1275
  msgid "Regenerate Vote Metas"
1276
  msgstr ""
1277
 
1278
- #: options/class.WpdiscuzOptions.php:1960
1279
  msgid "Closed Comments data need be regenerated"
1280
  msgstr ""
1281
 
1282
- #: options/class.WpdiscuzOptions.php:1961 options/html-tools.php:21 options/tools-layouts/regenerate-closed-comments.php:10 options/tools-layouts/regenerate-closed-comments.php:18
1283
  msgid "Regenerate Closed Comments"
1284
  msgstr ""
1285
 
1286
- #: options/class.WpdiscuzOptions.php:1970
1287
  msgid "Comments votes data need to be regenerated"
1288
  msgstr ""
1289
 
1290
- #: options/class.WpdiscuzOptions.php:1971 options/html-tools.php:22 options/tools-layouts/regenerate-vote-data.php:10 options/tools-layouts/regenerate-vote-data.php:18
1291
  msgid "Regenerate Vote Data"
1292
  msgstr ""
1293
 
1294
- #: options/class.WpdiscuzOptions.php:1980
1295
  msgid "Please synchronize comment data for the best performance and fastest experience"
1296
  msgstr ""
1297
 
1298
- #: options/class.WpdiscuzOptions.php:1981 options/tools-layouts/sync-commenter-data.php:8 options/tools-layouts/sync-commenter-data.php:16
1299
  msgid "Synchronize Commenters Data"
1300
  msgstr ""
1301
 
1302
- #: options/class.WpdiscuzOptions.php:2489
1303
  msgid "Comment Form Settings"
1304
  msgstr ""
1305
 
1306
- #: options/class.WpdiscuzOptions.php:2497
1307
  msgid "Keep guest commenter credentials in browser cookies for X days"
1308
  msgstr ""
1309
 
1310
- #: options/class.WpdiscuzOptions.php:2499
1311
  msgid "wpDiscuz uses WordPress functions to keep guest Name, Email and Website information in cookies. Those are used to fill according fields of comment form on next commenting time. Set this option value -1 to make it unlimited. Set this option value 0 to clear those data when user closes browser."
1312
  msgstr ""
1313
 
1314
- #: options/class.WpdiscuzOptions.php:2504
1315
  msgid "Comment author name length (for guests only)"
1316
  msgstr ""
1317
 
1318
- #: options/class.WpdiscuzOptions.php:2511
1319
  msgid "Comment Form View"
1320
  msgstr ""
1321
 
1322
- #: options/class.WpdiscuzOptions.php:2513
1323
  msgid "By default, only the comment text field is visible. When you click on the comment text field it opens all other fields (Name, Email, Website, etc...). If you want to keep all fields open, please set this option \"expended\"."
1324
  msgstr ""
1325
 
1326
- #: options/class.WpdiscuzOptions.php:2518
1327
  msgid "Enable drop animation for comment form and subscription bar"
1328
  msgstr ""
1329
 
1330
- #: options/class.WpdiscuzOptions.php:2525
1331
  msgid "Load Rich Editor"
1332
  msgstr ""
1333
 
1334
- #: options/class.WpdiscuzOptions.php:2527
1335
  msgid "Search engines rank web pages for mobile devices totally different. For the mobile devices, there are more restrictions for JS and CSS files loading. This is the main reason why wpDiscuz disables the Rich Editor for mobile devices by default. It's only enabled for desktop. If you have good cache and website optimizer plugins you can enable the rich editor for mobile devices as well."
1336
  msgstr ""
1337
 
1338
- #: options/class.WpdiscuzOptions.php:2532
1339
  msgid "Rich Editor Toolbar Buttons"
1340
  msgstr ""
1341
 
1342
- #: options/class.WpdiscuzOptions.php:2534
1343
  msgid "Please click on buttons to disable or enable. The enabled buttons are colored green, the disabled buttons are gray. If you want to disable the whole formatting toolbar, please click on the [Disable formatting buttons] button. Options to manage Image Attachment button are located in 'Comment Content and Media' setting page."
1344
  msgstr ""
1345
 
1346
- #: options/class.WpdiscuzOptions.php:2541 forms/wpdFormAttr/Field/Field.php:63
1347
  msgid "Google reCAPTCHA"
1348
  msgstr ""
1349
 
1350
- #: options/class.WpdiscuzOptions.php:2549
1351
  msgid "Site Key"
1352
  msgstr ""
1353
 
1354
- #: options/class.WpdiscuzOptions.php:2556 options/options-layouts/html-social.php:696
1355
  msgid "Secret Key"
1356
  msgstr ""
1357
 
1358
- #: options/class.WpdiscuzOptions.php:2563
1359
  msgid "reCAPTCHA Theme"
1360
  msgstr ""
1361
 
1362
- #: options/class.WpdiscuzOptions.php:2570
1363
  msgid "reCAPTCHA Language"
1364
  msgstr ""
1365
 
1366
- #: options/class.WpdiscuzOptions.php:2577
1367
  msgid "Request Method"
1368
  msgstr ""
1369
 
1370
- #: options/class.WpdiscuzOptions.php:2584
1371
  msgid "Enable for Guests"
1372
  msgstr ""
1373
 
1374
- #: options/class.WpdiscuzOptions.php:2591
1375
  msgid "Enable for Logged-in Users"
1376
  msgstr ""
1377
 
1378
- #: options/class.WpdiscuzOptions.php:2598
1379
  msgid "Display on Subscription Form"
1380
  msgstr ""
1381
 
1382
- #: options/class.WpdiscuzOptions.php:2608
1383
  msgid "User Authorization and Profile Data"
1384
  msgstr ""
1385
 
1386
- #: options/class.WpdiscuzOptions.php:2616
1387
  msgid "Display logged-in user name and logout link on comment form"
1388
  msgstr ""
1389
 
1390
- #: options/class.WpdiscuzOptions.php:2623
1391
  msgid "Show \"Login\" link on comment form"
1392
  msgstr ""
1393
 
1394
- #: options/class.WpdiscuzOptions.php:2630
1395
  msgid "\"My Content and Settings\" button"
1396
  msgstr ""
1397
 
1398
- #: options/class.WpdiscuzOptions.php:2632
1399
  msgid "The \"My Content & Settings\" button is located in comment filter panel on top of all comments, right after the [X Comments] phrase. This button opens a pop-up window allowing commenters manage their content and settings."
1400
  msgstr ""
1401
 
1402
- #: options/class.WpdiscuzOptions.php:2637
1403
  msgid "Enable Profiles URL"
1404
  msgstr ""
1405
 
1406
- #: options/class.WpdiscuzOptions.php:2639
1407
  #, php-format
1408
  msgid "By default wpDiscuz adds a link with comment author avatar to the author profile page, you can disable this link using this option. However in case you use some plugin with User Profile page, you should keep this option enabled. wpDiscuz is well integrated with %s, BuddyPress and Ultimate Member profile builder plugins."
1409
  msgstr ""
1410
 
1411
- #: options/class.WpdiscuzOptions.php:2644
1412
  msgid "Use Website URL as Profile URL"
1413
  msgstr ""
1414
 
1415
- #: options/class.WpdiscuzOptions.php:2651
1416
  msgid "Use guest email to detect registered account"
1417
  msgstr ""
1418
 
1419
- #: options/class.WpdiscuzOptions.php:2653
1420
  msgid "Sometimes registered users comment as guest using the same email address. wpDiscuz can detect the account role using guest email and display commenter label correctly."
1421
  msgstr ""
1422
 
1423
- #: options/class.WpdiscuzOptions.php:2660
1424
  msgid "Social Login and Share"
1425
  msgstr ""
1426
 
1427
- #: options/class.WpdiscuzOptions.php:2668
1428
  msgid "User agreement prior to a social login action"
1429
  msgstr ""
1430
 
1431
- #: options/class.WpdiscuzOptions.php:2670
1432
  msgid "If this option is enabled, all Social Login buttons become not-clickable until user accept automatic account creation process based on his/her Social Network Account shared information (email, name). This checkbox and appropriate information will be displayed when user click on a social login button, prior to the login process. This extra step is added to comply with the GDPR"
1433
  msgstr ""
1434
 
1435
- #: options/class.WpdiscuzOptions.php:2670
1436
  msgid "The note text and the label of this checkbox can be managed in Comments > Phrases > Social Login tab."
1437
  msgstr ""
1438
 
1439
- #: options/class.WpdiscuzOptions.php:2675
1440
  msgid "Display social login buttons on reply forms"
1441
  msgstr ""
1442
 
1443
- #: options/class.WpdiscuzOptions.php:2682
1444
  msgid "Display Social Network Icon on User Avatars"
1445
  msgstr ""
1446
 
1447
- #: options/class.WpdiscuzOptions.php:2689
1448
  msgid "Facebook Login Button"
1449
  msgstr ""
1450
 
1451
- #: options/class.WpdiscuzOptions.php:2696
1452
  msgid "Use Facebook OAuth2"
1453
  msgstr ""
1454
 
1455
- #: options/class.WpdiscuzOptions.php:2698
1456
  msgid "If you enable this option, please make sure you've inserted the Valid OAuth Redirect URI in according field when you create Facebook Login App. Your website OAuth Redirect URI is displayed above."
1457
  msgstr ""
1458
 
1459
- #: options/class.WpdiscuzOptions.php:2703
1460
  msgid "Facebook Share Button"
1461
  msgstr ""
1462
 
1463
- #: options/class.WpdiscuzOptions.php:2710
1464
  msgid "Facebook Application ID"
1465
  msgstr ""
1466
 
1467
- #: options/class.WpdiscuzOptions.php:2717
1468
  msgid "Facebook Application Secret"
1469
  msgstr ""
1470
 
1471
- #: options/class.WpdiscuzOptions.php:2724
1472
  msgid "Twitter Login Button"
1473
  msgstr ""
1474
 
1475
- #: options/class.WpdiscuzOptions.php:2731
1476
  msgid "Twitter Share Button"
1477
  msgstr ""
1478
 
1479
- #: options/class.WpdiscuzOptions.php:2738
1480
  msgid "Twitter - Consumer Key (API Key)"
1481
  msgstr ""
1482
 
1483
- #: options/class.WpdiscuzOptions.php:2745
1484
  msgid "Twitter - Consumer Secret (API Secret)"
1485
  msgstr ""
1486
 
1487
- #: options/class.WpdiscuzOptions.php:2752
1488
  msgid "Google Login Button"
1489
  msgstr ""
1490
 
1491
- #: options/class.WpdiscuzOptions.php:2759
1492
  msgid "Google Client ID"
1493
  msgstr ""
1494
 
1495
- #: options/class.WpdiscuzOptions.php:2766
1496
  msgid "Google Client Secret"
1497
  msgstr ""
1498
 
1499
- #: options/class.WpdiscuzOptions.php:2773
1500
  msgid "Disqus Login Button"
1501
  msgstr ""
1502
 
1503
- #: options/class.WpdiscuzOptions.php:2780
1504
  msgid "Disqus Public Key"
1505
  msgstr ""
1506
 
1507
- #: options/class.WpdiscuzOptions.php:2787
1508
  msgid "Disqus Secret Key"
1509
  msgstr ""
1510
 
1511
- #: options/class.WpdiscuzOptions.php:2794
1512
  msgid "WordPress Login Button"
1513
  msgstr ""
1514
 
1515
- #: options/class.WpdiscuzOptions.php:2801
1516
  msgid "WordPress Client ID"
1517
  msgstr ""
1518
 
1519
- #: options/class.WpdiscuzOptions.php:2808
1520
  msgid "WordPress Client Secret"
1521
  msgstr ""
1522
 
1523
- #: options/class.WpdiscuzOptions.php:2815
1524
  msgid "Instagram Login Button"
1525
  msgstr ""
1526
 
1527
- #: options/class.WpdiscuzOptions.php:2822
1528
  msgid "Instagram App ID"
1529
  msgstr ""
1530
 
1531
- #: options/class.WpdiscuzOptions.php:2829
1532
  msgid "Instagram App Secret"
1533
  msgstr ""
1534
 
1535
- #: options/class.WpdiscuzOptions.php:2836
1536
  msgid "LinkedIn Login Button"
1537
  msgstr ""
1538
 
1539
- #: options/class.WpdiscuzOptions.php:2843
1540
  msgid "LinkedIn Client ID"
1541
  msgstr ""
1542
 
1543
- #: options/class.WpdiscuzOptions.php:2850
1544
  msgid "LinkedIn Client Secret"
1545
  msgstr ""
1546
 
1547
- #: options/class.WpdiscuzOptions.php:2857
1548
  msgid "WhatsApp Share Button"
1549
  msgstr ""
1550
 
1551
- #: options/class.WpdiscuzOptions.php:2864
1552
  msgid "Yandex Login Button"
1553
  msgstr ""
1554
 
1555
- #: options/class.WpdiscuzOptions.php:2871
1556
  msgid "Yandex ID"
1557
  msgstr ""
1558
 
1559
- #: options/class.WpdiscuzOptions.php:2878
1560
  msgid "Yandex Password"
1561
  msgstr ""
1562
 
1563
- #: options/class.WpdiscuzOptions.php:2885
1564
  msgid "Mail.ru Login Button"
1565
  msgstr ""
1566
 
1567
- #: options/class.WpdiscuzOptions.php:2892
1568
  msgid "Mail.ru Client ID"
1569
  msgstr ""
1570
 
1571
- #: options/class.WpdiscuzOptions.php:2899
1572
  msgid "Mail.ru Client Secret"
1573
  msgstr ""
1574
 
1575
- #: options/class.WpdiscuzOptions.php:2906
1576
  msgid "Weibo Login Button"
1577
  msgstr ""
1578
 
1579
- #: options/class.WpdiscuzOptions.php:2913
1580
  msgid "Weibo App Key"
1581
  msgstr ""
1582
 
1583
- #: options/class.WpdiscuzOptions.php:2920
1584
  msgid "Weibo App Secret"
1585
  msgstr ""
1586
 
1587
- #: options/class.WpdiscuzOptions.php:2927
1588
  msgid "WeChat Login Button"
1589
  msgstr ""
1590
 
1591
- #: options/class.WpdiscuzOptions.php:2934
1592
  msgid "WeChat App ID"
1593
  msgstr ""
1594
 
1595
- #: options/class.WpdiscuzOptions.php:2941
1596
  msgid "WeChat Secret"
1597
  msgstr ""
1598
 
1599
- #: options/class.WpdiscuzOptions.php:2948
1600
  msgid "QQ Login Button"
1601
  msgstr ""
1602
 
1603
- #: options/class.WpdiscuzOptions.php:2955
1604
  msgid "QQ AppID"
1605
  msgstr ""
1606
 
1607
- #: options/class.WpdiscuzOptions.php:2962
1608
  msgid "QQ AppKey"
1609
  msgstr ""
1610
 
1611
- #: options/class.WpdiscuzOptions.php:2969
1612
  msgid "Baidu Login Button"
1613
  msgstr ""
1614
 
1615
- #: options/class.WpdiscuzOptions.php:2976
1616
  msgid "Baidu Client ID"
1617
  msgstr ""
1618
 
1619
- #: options/class.WpdiscuzOptions.php:2983
1620
  msgid "Baidu Client Secret"
1621
  msgstr ""
1622
 
1623
- #: options/class.WpdiscuzOptions.php:2990
1624
  msgid "VK Login Button"
1625
  msgstr ""
1626
 
1627
- #: options/class.WpdiscuzOptions.php:2997
1628
  msgid "VK Share Button"
1629
  msgstr ""
1630
 
1631
- #: options/class.WpdiscuzOptions.php:3004
1632
  msgid "VK Application ID"
1633
  msgstr ""
1634
 
1635
- #: options/class.WpdiscuzOptions.php:3011
1636
  msgid "VK Secure Key"
1637
  msgstr ""
1638
 
1639
- #: options/class.WpdiscuzOptions.php:3018
1640
  msgid "OK Login Button"
1641
  msgstr ""
1642
 
1643
- #: options/class.WpdiscuzOptions.php:3025
1644
  msgid "OK Share Button"
1645
  msgstr ""
1646
 
1647
- #: options/class.WpdiscuzOptions.php:3032
1648
  msgid "OK Application ID"
1649
  msgstr ""
1650
 
1651
- #: options/class.WpdiscuzOptions.php:3039
1652
  msgid "OK Application Key"
1653
  msgstr ""
1654
 
1655
- #: options/class.WpdiscuzOptions.php:3046
1656
  msgid "OK Application Secret"
1657
  msgstr ""
1658
 
1659
- #: options/class.WpdiscuzOptions.php:3055
1660
  msgid "Article and Comment Rating"
1661
  msgstr ""
1662
 
1663
- #: options/class.WpdiscuzOptions.php:3063
1664
  msgid "Enable Aggregate Rating Schema"
1665
  msgstr ""
1666
 
1667
- #: options/class.WpdiscuzOptions.php:3065
1668
  msgid "Aggregate rating schema is a code integrated with post rating HTML. This enables Google to feature your post ratings and attract customers with it. When searching the internet, people will see your posts search results with star ratings. Even though those results are not at the top of search engine results page, those sites caught people attention first."
1669
  msgstr ""
1670
 
1671
- #: options/class.WpdiscuzOptions.php:3070
1672
  msgid "Display Ratings"
1673
  msgstr ""
1674
 
1675
- #: options/class.WpdiscuzOptions.php:3077
1676
  msgid "Rating Star Colors"
1677
  msgstr ""
1678
 
1679
- #: options/class.WpdiscuzOptions.php:3086
1680
  msgid "Comment Thread Displaying"
1681
  msgstr ""
1682
 
1683
- #: options/class.WpdiscuzOptions.php:3094
1684
  msgid "Comment List Loading Type"
1685
  msgstr ""
1686
 
1687
- #: options/class.WpdiscuzOptions.php:3096
1688
  msgid "Keep your page loading speed high by disabling comments loading. Once the page loading is complete, this option will initiate AJAX request and load comments without affecting page loading speed. Also, you can select the [View Comments] button option to allow visitors load comments manually whenever they want."
1689
  msgstr ""
1690
 
1691
- #: options/class.WpdiscuzOptions.php:3101
1692
  msgid "Display only parent comments and <u>view replies &or;</u> button"
1693
  msgstr ""
1694
 
1695
- #: options/class.WpdiscuzOptions.php:3103
1696
  msgid "If this option is enabled only parent comments will be displayed. This increases page load speed and keeps pages light. If visitor wants to read replies he/she just need to click on [view replies (12)] button located on all parent comments which have replies."
1697
  msgstr ""
1698
 
1699
- #: options/class.WpdiscuzOptions.php:3108
1700
  msgid "Display \"Most Reacted Comments\" filter button"
1701
  msgstr ""
1702
 
1703
- #: options/class.WpdiscuzOptions.php:3115
1704
  msgid "Display \"Hottest Comment Threads\" filter button"
1705
  msgstr ""
1706
 
1707
- #: options/class.WpdiscuzOptions.php:3122
1708
  msgid "Display Comment Sorting Options"
1709
  msgstr ""
1710
 
1711
- #: options/class.WpdiscuzOptions.php:3124
1712
  msgid "This option enables comment sorting buttons (newest | oldest | most voted). Sorting buttons are not available for the default comments pagination type [1][2][3]... It's only active for [Load more] and other AJAX pagination types."
1713
  msgstr ""
1714
 
1715
- #: options/class.WpdiscuzOptions.php:3129
1716
  msgid "Set comments order to \"Most voted\" by default"
1717
  msgstr ""
1718
 
1719
- #: options/class.WpdiscuzOptions.php:3136
1720
  msgid "Reverse Child Comments Order"
1721
  msgstr ""
1722
 
1723
- #: options/class.WpdiscuzOptions.php:3138
1724
  msgid "By default child comments are sorted by oldest on top. Using this option you can revers child comments order and sort them by newest on top."
1725
  msgstr ""
1726
 
1727
- #: options/class.WpdiscuzOptions.php:3143
1728
  msgid "Comments Pagination Type"
1729
  msgstr ""
1730
 
1731
- #: options/class.WpdiscuzOptions.php:3145
1732
  msgid "You can manage the number of comments for [Load more] option in Settings > Discussion page, using \"Break comments into pages with [X] top level comments per page\" option. To show the default Wordpress comment pagination you should enable the checkbox on beginning of the same option."
1733
  msgstr ""
1734
 
1735
- #: options/class.WpdiscuzOptions.php:3150
1736
  msgid "Highlight Unread Comments"
1737
  msgstr ""
1738
 
1739
- #: options/class.WpdiscuzOptions.php:3159
1740
  msgid "Comment Thread Features"
1741
  msgstr ""
1742
 
1743
- #: options/class.WpdiscuzOptions.php:3167
1744
  msgid "Show Comment Link"
1745
  msgstr ""
1746
 
1747
- #: options/class.WpdiscuzOptions.php:3174
1748
  msgid "Show Comment Date"
1749
  msgstr ""
1750
 
1751
- #: options/class.WpdiscuzOptions.php:3181
1752
  msgid "Show Voting Buttons"
1753
  msgstr ""
1754
 
1755
- #: options/class.WpdiscuzOptions.php:3188
1756
  msgid "Voting Buttons Icon"
1757
  msgstr ""
1758
 
1759
- #: options/class.WpdiscuzOptions.php:3195
1760
  msgid "Comment Voting Result Mode"
1761
  msgstr ""
1762
 
1763
- #: options/class.WpdiscuzOptions.php:3202
1764
  msgid "Enable down vote button (dislike)"
1765
  msgstr ""
1766
 
1767
- #: options/class.WpdiscuzOptions.php:3209
1768
  msgid "Allow Guests to Vote for Comments"
1769
  msgstr ""
1770
 
1771
- #: options/class.WpdiscuzOptions.php:3216
1772
  msgid "Highlight Voting Buttons for Voters"
1773
  msgstr ""
1774
 
1775
- #: options/class.WpdiscuzOptions.php:3218
1776
  msgid "This allows users to see own voted comments."
1777
  msgstr ""
1778
 
1779
- #: options/class.WpdiscuzOptions.php:3223
1780
  msgid "Display Avatars"
1781
  msgstr ""
1782
 
1783
- #: options/class.WpdiscuzOptions.php:3225
1784
  msgid "This option only related to avatars in comment system. For sitewide avatar control, please use WordPress native avatar settings in Dashboard > Settings > Discussions admin page."
1785
  msgstr ""
1786
 
1787
- #: options/class.WpdiscuzOptions.php:3230
1788
  msgid "Default Avatar Source URL for Users"
1789
  msgstr ""
1790
 
1791
- #: options/class.WpdiscuzOptions.php:3237
1792
  msgid "Default Avatar Source URL for Guests"
1793
  msgstr ""
1794
 
1795
- #: options/class.WpdiscuzOptions.php:3244
1796
  msgid "Enable Sitewide Usage of Default Avatars"
1797
  msgstr ""
1798
 
1799
- #: options/class.WpdiscuzOptions.php:3253
1800
  msgid "Styles and Colors"
1801
  msgstr ""
1802
 
1803
- #: options/class.WpdiscuzOptions.php:3261
1804
  msgid "Comment Form and Comment List Style"
1805
  msgstr ""
1806
 
1807
- #: options/class.WpdiscuzOptions.php:3263
1808
  msgid "Starting from wpDiscuz 7 you can choose the Minimal option of comment style. It'll remove most of wpDiscuz CSS code and allow you write your own CSS for custom comment styling."
1809
  msgstr ""
1810
 
1811
- #: options/class.WpdiscuzOptions.php:3268
1812
  msgid "Colors"
1813
  msgstr ""
1814
 
1815
- #: options/class.WpdiscuzOptions.php:3275
1816
  msgid "Comment Text Size"
1817
  msgstr ""
1818
 
1819
- #: options/class.WpdiscuzOptions.php:3282
1820
  msgid "Load Font Awesome css lib"
1821
  msgstr ""
1822
 
1823
- #: options/class.WpdiscuzOptions.php:3284
1824
  msgid "IMPORTANT: In case your theme uses old versions of Font-Awesome lib, you should not disable this this option. The theme old version doesn't support new version icons, thus some wpDiscuz icons might be lost."
1825
  msgstr ""
1826
 
1827
- #: options/class.WpdiscuzOptions.php:3289
1828
  msgid "Custom CSS Code"
1829
  msgstr ""
1830
 
1831
- #: options/class.WpdiscuzOptions.php:3298
1832
  msgid "Subscription and User Following"
1833
  msgstr ""
1834
 
1835
- #: options/class.WpdiscuzOptions.php:3306
1836
  msgid "Enable User Mentioning"
1837
  msgstr ""
1838
 
1839
- #: options/class.WpdiscuzOptions.php:3308
1840
  #, php-format
1841
  msgid "This option allows mentioning users in comments using @nickname method. Mentioned users will get notification via email if the next option is enabled. To get an advanced user mentioning features and to be able mention comments by #CommentID, we recommend the %s addon."
1842
  msgstr ""
1843
 
1844
- #: options/class.WpdiscuzOptions.php:3313
1845
  msgid "Send E-Mail Notification to Mentioned Users"
1846
  msgstr ""
1847
 
1848
- #: options/class.WpdiscuzOptions.php:3320
1849
  msgid "Notify comment author once comment is approved"
1850
  msgstr ""
1851
 
1852
- #: options/class.WpdiscuzOptions.php:3327
1853
  msgid "Enable subscription confirmation for registered users"
1854
  msgstr ""
1855
 
1856
- #: options/class.WpdiscuzOptions.php:3334
1857
  msgid "Enable subscription confirmation for guests"
1858
  msgstr ""
1859
 
1860
- #: options/class.WpdiscuzOptions.php:3341
1861
  msgid "Subscription types in Subscription Bar drop-down"
1862
  msgstr ""
1863
 
1864
- #: options/class.WpdiscuzOptions.php:3348
1865
  msgid "Display \"Notify of new replies to this comment\" option in comment form"
1866
  msgstr ""
1867
 
1868
- #: options/class.WpdiscuzOptions.php:3350
1869
  msgid "wpDiscuz is the only comment plugin which allows you to subscribe to certain comment replies. This option is located above [Post Comment] button in comment form. You can disable this subscription way by unchecking this option."
1870
  msgstr ""
1871
 
1872
- #: options/class.WpdiscuzOptions.php:3355
1873
  msgid "Keep checked the \"Notify of new replies to this comment\" option by default"
1874
  msgstr ""
1875
 
1876
- #: options/class.WpdiscuzOptions.php:3362
1877
  msgid "Use Postmatic for subscriptions and commenting by email"
1878
  msgstr ""
1879
 
1880
- #: options/class.WpdiscuzOptions.php:3364
1881
  msgid "Postmatic allows your users subscribe to comments. Instead of just being notified, they add a reply right from their inbox."
1882
  msgstr ""
1883
 
1884
- #: options/class.WpdiscuzOptions.php:3369
1885
  msgid "Enable User Following Feature"
1886
  msgstr ""
1887
 
1888
- #: options/class.WpdiscuzOptions.php:3376
1889
  msgid "Follow users without email confirmation"
1890
  msgstr ""
1891
 
1892
- #: options/class.WpdiscuzOptions.php:3385
1893
  msgid "User Labels and Badges"
1894
  msgstr ""
1895
 
1896
- #: options/class.WpdiscuzOptions.php:3393
1897
  msgid "Display Comment Author Labels"
1898
  msgstr ""
1899
 
1900
- #: options/class.WpdiscuzOptions.php:3400
1901
  msgid "Comment Author Label Colors by User Role"
1902
  msgstr ""
1903
 
1904
- #: options/class.WpdiscuzOptions.php:3409
1905
  msgid "Comment Moderation"
1906
  msgstr ""
1907
 
1908
- #: options/class.WpdiscuzOptions.php:3417
1909
  msgid "Edit Button - Allow comment editing for"
1910
  msgstr ""
1911
 
1912
- #: options/class.WpdiscuzOptions.php:3424
1913
  msgid "Enable editing for replied comments"
1914
  msgstr ""
1915
 
1916
- #: options/class.WpdiscuzOptions.php:3431
1917
  msgid "Display comment editing Information"
1918
  msgstr ""
1919
 
1920
- #: options/class.WpdiscuzOptions.php:3438
1921
  msgid "Stick Button - Stick a comment thread"
1922
  msgstr ""
1923
 
1924
- #: options/class.WpdiscuzOptions.php:3445
1925
  msgid "Close Button - Close a comment thread"
1926
  msgstr ""
1927
 
1928
- #: options/class.WpdiscuzOptions.php:3452
1929
  msgid "Limit Comments per User"
1930
  msgstr ""
1931
 
1932
- #: options/class.WpdiscuzOptions.php:3454
1933
  msgid "This option allows control commenting activity per user. You can set maximum number of comments users can leave per post or sitewide. It also allow to set restriction for comments or for replies only."
1934
  msgstr ""
1935
 
1936
- #: options/class.WpdiscuzOptions.php:3461
1937
  msgid "Comment Content and Media"
1938
  msgstr ""
1939
 
1940
- #: options/class.WpdiscuzOptions.php:3469
1941
  msgid "Comment Text Length"
1942
  msgstr ""
1943
 
1944
- #: options/class.WpdiscuzOptions.php:3471
1945
  msgid "Allows to set minimum and maximum number of chars can be inserted in comment textarea. Leave the max value empty to remove the limit."
1946
  msgstr ""
1947
 
1948
- #: options/class.WpdiscuzOptions.php:3476
1949
  msgid "Image Source URL to Image Conversion"
1950
  msgstr ""
1951
 
1952
- #: options/class.WpdiscuzOptions.php:3483
 
 
 
 
 
 
 
 
1953
  msgid "The number of words before breaking comment text (Read more)"
1954
  msgstr ""
1955
 
1956
- #: options/class.WpdiscuzOptions.php:3485
1957
  msgid "Set this option value 0, to turn off comment text breaking function."
1958
  msgstr ""
1959
 
1960
- #: options/class.WpdiscuzOptions.php:3490
1961
  msgid "Enable Media Uploading"
1962
  msgstr ""
1963
 
1964
- #: options/class.WpdiscuzOptions.php:3492
1965
  msgid "This option allows commenters to attach an image with comments."
1966
  msgstr ""
1967
 
1968
- #: options/class.WpdiscuzOptions.php:3497
1969
  msgid "Allow Media Uploading for Guests"
1970
  msgstr ""
1971
 
1972
- #: options/class.WpdiscuzOptions.php:3504
1973
  msgid "Enable Lightbox for Attached Images"
1974
  msgstr ""
1975
 
1976
- #: options/class.WpdiscuzOptions.php:3511
1977
  msgid "Allowed File Types"
1978
  msgstr ""
1979
 
1980
- #: options/class.WpdiscuzOptions.php:3518
1981
  msgid "Max Uploaded Size"
1982
  msgstr ""
1983
 
1984
- #: options/class.WpdiscuzOptions.php:3520
1985
  msgid "You can not set this value more than 'upload_max_filesize' and 'post_max_size'. If you want to increase server parameters please contact to your hosting service support."
1986
  msgstr ""
1987
 
1988
- #: options/class.WpdiscuzOptions.php:3525
1989
  msgid "Show Comments Media in Dashboard"
1990
  msgstr ""
1991
 
1992
- #: options/class.WpdiscuzOptions.php:3532
1993
  msgid "Single Image Sizes in Comments"
1994
  msgstr ""
1995
 
1996
- #: options/class.WpdiscuzOptions.php:3539
1997
  msgid "Generate Thumbnail Sizes"
1998
  msgstr ""
1999
 
2000
- #: options/class.WpdiscuzOptions.php:3541
2001
  msgid "Once image is uploaded, it'll generate thumbnails according to your selected sizes. When you set up a new WordPress website, the platform gives you three image sizes to play with: thumbnail, medium, and large (plus the file's original resolution). You may have other options and sizes which are registered by current active theme and by other plugins."
2002
  msgstr ""
2003
 
2004
- #: options/class.WpdiscuzOptions.php:3548
2005
  msgid "Live Commenting and Notifications"
2006
  msgstr ""
2007
 
2008
- #: options/class.WpdiscuzOptions.php:3556 options/html-options.php:254 options/html-options.php:263
2009
  msgid "Comment Bubble"
2010
  msgstr ""
2011
 
2012
- #: options/class.WpdiscuzOptions.php:3558
2013
  msgid "Comment Bubble is a real-time updating sticky comment icon on your web pages. It invites people to comment, displays current comments information and notifies current page viewers about new comments."
2014
  msgstr ""
2015
 
2016
- #: options/class.WpdiscuzOptions.php:3563
2017
  msgid "Comment Bubble Live Update"
2018
  msgstr ""
2019
 
2020
- #: options/class.WpdiscuzOptions.php:3570 options/html-options.php:289
2021
  msgid "Comment Bubble Location"
2022
  msgstr ""
2023
 
2024
- #: options/class.WpdiscuzOptions.php:3577
2025
  msgid "Bubble - Notify on New Comments"
2026
  msgstr ""
2027
 
2028
- #: options/class.WpdiscuzOptions.php:3579
2029
  msgid "If the Bubble live update is enabled, it shows new comments excerpts as a pop-up information to article reads in real-time. This keeps website visitors up to date and engages them join to the discussion."
2030
  msgstr ""
2031
 
2032
- #: options/class.WpdiscuzOptions.php:3584
2033
  msgid "Bubble - Invite to comment in X seconds"
2034
  msgstr ""
2035
 
2036
- #: options/class.WpdiscuzOptions.php:3586
2037
  msgid "In most cases article readers don't even think about leaving some comment. Using this option you can enable Bubble &laquo;Invite to Comment&raquo; message. Once page is loaded and visitor has read some content, it reminds about comments and calls to leave a reply."
2038
  msgstr ""
2039
 
2040
- #: options/class.WpdiscuzOptions.php:3591
2041
  msgid "Bubble - Hide the invitation message in X seconds"
2042
  msgstr ""
2043
 
2044
- #: options/class.WpdiscuzOptions.php:3598
2045
  msgid "Live Update"
2046
  msgstr ""
2047
 
2048
- #: options/class.WpdiscuzOptions.php:3600
2049
  msgid "wpDiscuz live update is very light and doesn't overload your server. However we recommend to monitor your server resources if you're on a Shared hosting plan. There are some very weak hosting plans which may not be able to perform very frequently live update requests. If you found some issue you can set the option below 30 seconds or more."
2050
  msgstr ""
2051
 
2052
- #: options/class.WpdiscuzOptions.php:3605
2053
  msgid "Enable Live Update for Guests"
2054
  msgstr ""
2055
 
2056
- #: options/class.WpdiscuzOptions.php:3612
2057
  msgid "Update Comment List Every"
2058
  msgstr ""
2059
 
2060
- #: options/class.WpdiscuzOptions.php:3621
2061
  msgid "Inline Commenting"
2062
  msgstr ""
2063
 
2064
- #: options/class.WpdiscuzOptions.php:3629
2065
  msgid "Display filter button to load inline feedbacks"
2066
  msgstr ""
2067
 
2068
- #: options/class.WpdiscuzOptions.php:3631
2069
  msgid "This filter button appears next to all filter buttons and comment sorting options. It allows to filter and display article inline feedbacks (comments made while reading current article)."
2070
  msgstr ""
2071
 
2072
- #: options/class.WpdiscuzOptions.php:3636
2073
  msgid "Animation for \"Leave a Feedback\" button in article content"
2074
  msgstr ""
2075
 
2076
- #: options/class.WpdiscuzOptions.php:3638
2077
  msgid "Once a question is added in article editor (backend), readers will see a small comment icon (call to leave a feedback) next to the text part you've selected for your question on article (front-end). This icon calls people to leave a feedback, using the type you've selected in this option. For example, if you've chosen the \"Blink\" option, once reader scrolled and reached to the article text with question, it animates with comment button size and color changes attracting readers attention."
2078
  msgstr ""
2079
 
2080
- #: options/class.WpdiscuzOptions.php:3645
2081
  msgid "General Settings"
2082
  msgstr ""
2083
 
2084
- #: options/class.WpdiscuzOptions.php:3653
2085
  msgid "Enable wpDiscuz on Home Page"
2086
  msgstr ""
2087
 
2088
- #: options/class.WpdiscuzOptions.php:3660
2089
  msgid "Use WordPress native AJAX functions"
2090
  msgstr ""
2091
 
2092
- #: options/class.WpdiscuzOptions.php:3662
2093
  msgid "By disabling this option you're automatically enabling wpDiscuz custom AJAX functions, which are many times faster that the default WordPress functions. Just make sure it doesn't conflict with your plugins."
2094
  msgstr ""
2095
 
2096
- #: options/class.WpdiscuzOptions.php:3667
2097
  msgid "Load Combo Version"
2098
  msgstr ""
2099
 
2100
- #: options/class.WpdiscuzOptions.php:3674
2101
  msgid "Load Min Versions"
2102
  msgstr ""
2103
 
2104
- #: options/class.WpdiscuzOptions.php:3681
2105
  msgid "Secure comment content in HTTPS protocol."
2106
  msgstr ""
2107
 
2108
- #: options/class.WpdiscuzOptions.php:3683
2109
  msgid "This option detects images and other contents with non-https source URLs and fix according to your selected logic."
2110
  msgstr ""
2111
 
2112
- #: options/class.WpdiscuzOptions.php:3688
2113
  msgid "Redirect First Comment to"
2114
  msgstr ""
2115
 
2116
- #: options/class.WpdiscuzOptions.php:3695
2117
  msgid "Use WordPress Date/Time Format"
2118
  msgstr ""
2119
 
2120
- #: options/class.WpdiscuzOptions.php:3697
2121
  msgid "wpDiscuz shows Human Readable date format. If you check this option it'll show the date/time format set in WordPress General Settings."
2122
  msgstr ""
2123
 
2124
- #: options/class.WpdiscuzOptions.php:3702
2125
  msgid "Structure of Human Readable Date Format"
2126
  msgstr ""
2127
 
2128
- #: options/class.WpdiscuzOptions.php:3704
2129
  msgid "By default, comment date is displayed with the human readable format, such as [X days ago]. For some languages, you may need to change the sequence of words in this date. This option provides shordcodes for each word allowing you manage the order. [number] is the 'X', [time_unit] is the 'days', [adjective] is the 'ago'."
2130
  msgstr ""
2131
 
2132
- #: options/class.WpdiscuzOptions.php:3709
2133
  msgid "Use Plugin .PO/.MO Files"
2134
  msgstr ""
2135
 
2136
- #: options/class.WpdiscuzOptions.php:3711
2137
  msgid "wpDiscuz phrase system allows you to translate all front-end phrases. However if you have a multi-language website it'll not allow you to add more than one language translation. The only way to get it is the plugin translation files (.PO / .MO). If wpDiscuz has the languages you need you should check this option to disable phrase system and it'll automatically translate all phrases based on language files according to current language."
2138
  msgstr ""
2139
 
2140
- #: options/class.WpdiscuzOptions.php:3716
2141
  msgid "Help wpDiscuz to grow allowing people to recognize which comment plugin you use"
2142
  msgstr ""
2143
 
2144
- #: options/class.WpdiscuzOptions.php:3718
2145
  msgid "Please check this option on to help wpDiscuz get more popularity as your thank to the hard work we do for you totally free. This option adds a very small (16x16px) icon under the comment section which will allow your site visitors recognize the name of comment solution you use."
2146
  msgstr ""
2147
 
2148
- #: options/class.WpdiscuzOptions.php:3723
2149
  msgid "Enable Gravatar caching"
2150
  msgstr ""
2151
 
2152
- #: options/class.WpdiscuzOptions.php:3730
2153
  msgid "Caching Method"
2154
  msgstr ""
2155
 
2156
- #: options/class.WpdiscuzOptions.php:3737
2157
  msgid "Reset Avatar Cache Frequency"
2158
  msgstr ""
2159
 
2160
- #: options/class.WpdiscuzOptions.php:3744
2161
  msgid "Remove Vote Data"
2162
  msgstr ""
2163
 
2164
- #: options/class.WpdiscuzOptions.php:3751
2165
  msgid "Purge Expired Avatar Caches"
2166
  msgstr ""
2167
 
2168
- #: options/class.WpdiscuzOptions.php:3758
2169
  msgid "Purge All Avatar Caches"
2170
  msgstr ""
2171
 
@@ -2799,31 +2807,31 @@ msgstr ""
2799
  msgid "Fix Tables"
2800
  msgstr ""
2801
 
2802
- #: utils/class.WpdiscuzHelper.php:362
2803
  msgid "Sticky"
2804
  msgstr ""
2805
 
2806
- #: utils/class.WpdiscuzHelper.php:955
2807
  msgid "Reset Ratings"
2808
  msgstr ""
2809
 
2810
- #: utils/class.WpdiscuzHelper.php:995
2811
  msgid "Reset Post Rating"
2812
  msgstr ""
2813
 
2814
- #: utils/class.WpdiscuzHelper.php:996 utils/class.WpdiscuzHelper.php:1035
2815
  msgid "Working..."
2816
  msgstr ""
2817
 
2818
- #: utils/class.WpdiscuzHelper.php:997 utils/class.WpdiscuzHelper.php:1036
2819
  msgid "Done"
2820
  msgstr ""
2821
 
2822
- #: utils/class.WpdiscuzHelper.php:1034
2823
  msgid "Reset Fields Ratings"
2824
  msgstr ""
2825
 
2826
- #: utils/class.WpdiscuzHelper.php:1134
2827
  msgid "Enter link:"
2828
  msgstr ""
2829
 
@@ -2831,35 +2839,35 @@ msgstr ""
2831
  msgid "Read More"
2832
  msgstr ""
2833
 
2834
- #: utils/class.WpdiscuzHelperAjax.php:847
2835
  msgid "Subscribers"
2836
  msgstr ""
2837
 
2838
- #: utils/class.WpdiscuzHelperAjax.php:848
2839
  msgid "Subscription - posts"
2840
  msgstr ""
2841
 
2842
- #: utils/class.WpdiscuzHelperAjax.php:849
2843
  msgid "Subscription - all comments"
2844
  msgstr ""
2845
 
2846
- #: utils/class.WpdiscuzHelperAjax.php:850
2847
  msgid "Subscription - comment"
2848
  msgstr ""
2849
 
2850
- #: utils/class.WpdiscuzHelperAjax.php:851 utils/class.WpdiscuzHelperAjax.php:913
2851
  msgid "Followers"
2852
  msgstr ""
2853
 
2854
- #: utils/class.WpdiscuzHelperAjax.php:852 utils/class.WpdiscuzHelperAjax.php:909
2855
  msgid "Following"
2856
  msgstr ""
2857
 
2858
- #: utils/class.WpdiscuzHelperAjax.php:898 options/addons/cai/title.php:7
2859
  msgid "Comment Author"
2860
  msgstr ""
2861
 
2862
- #: utils/class.WpdiscuzHelperAjax.php:917
2863
  msgid "Last Activity"
2864
  msgstr ""
2865
 
@@ -2867,11 +2875,11 @@ msgstr ""
2867
  msgid "Unfollow"
2868
  msgstr ""
2869
 
2870
- #: utils/class.WpdiscuzHelperUpload.php:432
2871
  msgid "The attachment not exists"
2872
  msgstr ""
2873
 
2874
- #: utils/class.WpdiscuzHelperUpload.php:710
2875
  msgid "Attached Images"
2876
  msgstr ""
2877
 
@@ -2955,7 +2963,7 @@ msgstr ""
2955
  msgid "Dismiss and never show again"
2956
  msgstr ""
2957
 
2958
- #: forms/wpdFormAttr/Form.php:207 forms/wpdFormAttr/Form.php:614 forms/wpdFormAttr/Form.php:1052
2959
  msgid "I allow to use my email address and send notification about new comments and replies (you can unsubscribe at any time)."
2960
  msgstr ""
2961
 
@@ -2963,95 +2971,95 @@ msgstr ""
2963
  msgid "Average Rating"
2964
  msgstr ""
2965
 
2966
- #: forms/wpdFormAttr/Form.php:986 forms/wpdFormAttr/Form.php:1008 forms/wpdFormAttr/Form.php:1020 forms/wpdFormAttr/Form.php:1032 forms/wpdFormAttr/Form.php:1044 forms/wpdFormAttr/Form.php:1064 forms/wpdFormAttr/Form.php:1075 forms/wpdFormAttr/Form.php:1104 forms/wpdFormAttr/Form.php:1114 forms/wpdFormAttr/Form.php:1160 forms/wpdFormAttr/Form.php:1176 forms/wpdFormAttr/Form.php:1198 forms/wpdFormAttr/Form.php:1205 options/options-layouts/html-content.php:13 options/options-layouts/html-content.php:29 options/options-layouts/html-content.php:47 options/options-layouts/html-content.php:62 options/options-layouts/html-content.php:84 options/options-layouts/html-content.php:118 options/options-layouts/html-content.php:131 options/options-layouts/html-content.php:177 options/options-layouts/html-content.php:195 options/options-layouts/html-content.php:211 options/options-layouts/html-content.php:243 options/options-layouts/html-form.php:13 options/options-layouts/html-form.php:33 options/options-layouts/html-form.php:51 options/options-layouts/html-form.php:80 options/options-layouts/html-form.php:122 options/options-layouts/html-form.php:138 options/options-layouts/html-form.php:153 options/options-layouts/html-general.php:20 options/options-layouts/html-general.php:38 options/options-layouts/html-general.php:55 options/options-layouts/html-general.php:72 options/options-layouts/html-general.php:121 options/options-layouts/html-general.php:143 options/options-layouts/html-general.php:158 options/options-layouts/html-general.php:176 options/options-layouts/html-general.php:217 options/options-layouts/html-general.php:235 options/options-layouts/html-general.php:251 options/options-layouts/html-inline.php:21 options/options-layouts/html-inline.php:39 options/options-layouts/html-inline.php:69 options/options-layouts/html-labels.php:13 options/options-layouts/html-labels.php:39 options/options-layouts/html-labels.php:63 options/options-layouts/html-live.php:15 options/options-layouts/html-live.php:35 options/options-layouts/html-live.php:57 options/options-layouts/html-live.php:77 options/options-layouts/html-live.php:98 options/options-layouts/html-live.php:114 options/options-layouts/html-live.php:129 options/options-layouts/html-live.php:149 options/options-layouts/html-live.php:167 options/options-layouts/html-live.php:190 options/options-layouts/html-login.php:13 options/options-layouts/html-login.php:31 options/options-layouts/html-login.php:49 options/options-layouts/html-login.php:99 options/options-layouts/html-login.php:117 options/options-layouts/html-login.php:135 options/options-layouts/html-login.php:153 options/options-layouts/html-moderation.php:13 options/options-layouts/html-moderation.php:36 options/options-layouts/html-moderation.php:54 options/options-layouts/html-moderation.php:72 options/options-layouts/html-moderation.php:90 options/options-layouts/html-moderation.php:108 options/options-layouts/html-moderation.php:143 options/options-layouts/html-rating.php:13 options/options-layouts/html-rating.php:31 options/options-layouts/html-rating.php:61 options/options-layouts/html-recaptcha.php:14 options/options-layouts/html-recaptcha.php:38 options/options-layouts/html-recaptcha.php:56 options/options-layouts/html-recaptcha.php:74 options/options-layouts/html-recaptcha.php:92 options/options-layouts/html-recaptcha.php:111 options/options-layouts/html-recaptcha.php:126 options/options-layouts/html-recaptcha.php:144 options/options-layouts/html-recaptcha.php:160 options/options-layouts/html-social.php:13 options/options-layouts/html-social.php:31 options/options-layouts/html-social.php:49 options/options-layouts/html-social.php:67 options/options-layouts/html-social.php:140 options/options-layouts/html-social.php:155 options/options-layouts/html-social.php:212 options/options-layouts/html-social.php:227 options/options-layouts/html-social.php:267 options/options-layouts/html-social.php:282 options/options-layouts/html-social.php:323 options/options-layouts/html-social.php:338 options/options-layouts/html-social.php:378 options/options-layouts/html-social.php:393 options/options-layouts/html-social.php:431 options/options-layouts/html-social.php:446 options/options-layouts/html-social.php:485 options/options-layouts/html-social.php:500 options/options-layouts/html-social.php:559 options/options-layouts/html-social.php:574 options/options-layouts/html-social.php:630 options/options-layouts/html-social.php:645 options/options-layouts/html-social.php:684 options/options-layouts/html-social.php:699 options/options-layouts/html-social.php:756 options/options-layouts/html-social.php:771 options/options-layouts/html-social.php:786 options/options-layouts/html-social.php:824 options/options-layouts/html-social.php:839 options/options-layouts/html-social.php:878 options/options-layouts/html-social.php:893 options/options-layouts/html-social.php:932 options/options-layouts/html-social.php:947 options/options-layouts/html-social.php:986 options/options-layouts/html-social.php:1001 options/options-layouts/html-subscription.php:13 options/options-layouts/html-subscription.php:31 options/options-layouts/html-subscription.php:49 options/options-layouts/html-subscription.php:67 options/options-layouts/html-subscription.php:85 options/options-layouts/html-subscription.php:103 options/options-layouts/html-subscription.php:132 options/options-layouts/html-subscription.php:150 options/options-layouts/html-subscription.php:185 options/options-layouts/html-subscription.php:204 options/options-layouts/html-subscription.php:222 options/options-layouts/html-thread_display.php:13 options/options-layouts/html-thread_display.php:42 options/options-layouts/html-thread_display.php:78 options/options-layouts/html-thread_display.php:96 options/options-layouts/html-thread_display.php:114 options/options-layouts/html-thread_display.php:132 options/options-layouts/html-thread_display.php:150 options/options-layouts/html-thread_display.php:168 options/options-layouts/html-thread_display.php:186 options/options-layouts/html-thread_display.php:204 options/options-layouts/html-thread_layouts.php:32 options/options-layouts/html-thread_layouts.php:55 options/options-layouts/html-thread_layouts.php:70 options/options-layouts/html-thread_layouts.php:85 options/options-layouts/html-thread_layouts.php:103 options/options-layouts/html-thread_layouts.php:125 options/options-layouts/html-thread_layouts.php:149 options/options-layouts/html-thread_layouts.php:167 options/options-layouts/html-thread_layouts.php:185 options/options-layouts/html-thread_layouts.php:203 options/options-layouts/html-thread_layouts.php:221 options/options-layouts/html-thread_layouts.php:244 options/options-layouts/html-thread_styles.php:13 options/options-layouts/html-thread_styles.php:32 options/options-layouts/html-thread_styles.php:70 options/options-layouts/html-thread_styles.php:111 options/options-layouts/html-thread_styles.php:126
2967
  msgid "Read the documentation"
2968
  msgstr ""
2969
 
2970
- #: forms/wpdFormAttr/Form.php:991
2971
  msgid "Disable commenting for roles"
2972
  msgstr ""
2973
 
2974
- #: forms/wpdFormAttr/Form.php:1013
2975
  msgid "Allow guests to comment"
2976
  msgstr ""
2977
 
2978
- #: forms/wpdFormAttr/Form.php:1017 forms/wpdFormAttr/Form.php:1029 forms/wpdFormAttr/Form.php:1041 forms/wpdFormAttr/Form.php:1173 forms/wpdFormAttr/Form.php:1195
2979
  msgid "Yes"
2980
  msgstr ""
2981
 
2982
- #: forms/wpdFormAttr/Form.php:1019 forms/wpdFormAttr/Form.php:1031 forms/wpdFormAttr/Form.php:1043 forms/wpdFormAttr/Form.php:1175 forms/wpdFormAttr/Form.php:1197
2983
  msgid "No"
2984
  msgstr ""
2985
 
2986
- #: forms/wpdFormAttr/Form.php:1025
2987
  msgid "Enable subscription bar"
2988
  msgstr ""
2989
 
2990
- #: forms/wpdFormAttr/Form.php:1037
2991
  msgid "Display agreement checkbox in Comment Subscription bar"
2992
  msgstr ""
2993
 
2994
- #: forms/wpdFormAttr/Form.php:1049
2995
  msgid "Comment Subscription bar agreement checkbox label"
2996
  msgstr ""
2997
 
2998
- #: forms/wpdFormAttr/Form.php:1058
2999
  msgid "Comment form header text (singular)"
3000
  msgstr ""
3001
 
3002
- #: forms/wpdFormAttr/Form.php:1069
3003
  msgid "Comment form header text (plural)"
3004
  msgstr ""
3005
 
3006
- #: forms/wpdFormAttr/Form.php:1079
3007
  msgid "Display comment form for post types"
3008
  msgstr ""
3009
 
3010
- #: forms/wpdFormAttr/Form.php:1086
3011
  msgid "The red marked post types are already attached to other comment form. If you set this form too, the old forms will not be used for them."
3012
  msgstr ""
3013
 
3014
- #: forms/wpdFormAttr/Form.php:1109
3015
  msgid "Display comment form for post IDs"
3016
  msgstr ""
3017
 
3018
- #: forms/wpdFormAttr/Form.php:1110
3019
  msgid "You can use this form for certain posts/pages specified by comma separated IDs."
3020
  msgstr ""
3021
 
3022
- #: forms/wpdFormAttr/Form.php:1124
3023
  msgid "Theme"
3024
  msgstr ""
3025
 
3026
- #: forms/wpdFormAttr/Form.php:1143
3027
  msgid "Comment List Layout"
3028
  msgstr ""
3029
 
3030
- #: forms/wpdFormAttr/Form.php:1154
3031
  msgid "Layout"
3032
  msgstr ""
3033
 
3034
- #: forms/wpdFormAttr/Form.php:1169
3035
  msgid "Enable Post Rating"
3036
  msgstr ""
3037
 
3038
- #: forms/wpdFormAttr/Form.php:1181
3039
  msgid "Post Rating Title"
3040
  msgstr ""
3041
 
3042
- #: forms/wpdFormAttr/Form.php:1191
3043
  msgid "Allow Guests to Rate"
3044
  msgstr ""
3045
 
3046
- #: forms/wpdFormAttr/Form.php:1209
3047
  msgid "Comment Text Field"
3048
  msgstr ""
3049
 
3050
- #: forms/wpdFormAttr/Form.php:1224
3051
  msgid "ADD ROW"
3052
  msgstr ""
3053
 
3054
- #: forms/wpdFormAttr/Form.php:1290 forms/wpdFormAttr/Field/DefaultField/Website.php:84
3055
  msgid "Website"
3056
  msgstr ""
3057
 
@@ -3068,35 +3076,35 @@ msgstr ""
3068
  msgid "Max"
3069
  msgstr ""
3070
 
3071
- #: options/options-layouts/html-content.php:68
3072
  msgid "File Attachment Settings"
3073
  msgstr ""
3074
 
3075
- #: options/options-layouts/html-content.php:149
3076
  msgid "Select All"
3077
  msgstr ""
3078
 
3079
- #: options/options-layouts/html-content.php:150
3080
  msgid "Unselect All"
3081
  msgstr ""
3082
 
3083
- #: options/options-layouts/html-content.php:151
3084
  msgid "Invert Selection"
3085
  msgstr ""
3086
 
3087
- #: options/options-layouts/html-content.php:172
3088
  msgid "Server 'upload_max_filesize' is "
3089
  msgstr ""
3090
 
3091
- #: options/options-layouts/html-content.php:173
3092
  msgid "Server 'post_max_size' is "
3093
  msgstr ""
3094
 
3095
- #: options/options-layouts/html-content.php:207
3096
  msgid "Width (px)"
3097
  msgstr ""
3098
 
3099
- #: options/options-layouts/html-content.php:208
3100
  msgid "Height (px)"
3101
  msgstr ""
3102
 
@@ -4276,7 +4284,7 @@ msgstr ""
4276
  msgid "Don't show again if the agreement is accepted once"
4277
  msgstr ""
4278
 
4279
- #: forms/wpdFormAttr/Field/AgreementCheckbox.php:101 forms/wpdFormAttr/Field/CheckboxField.php:150 forms/wpdFormAttr/Field/ColorField.php:113 forms/wpdFormAttr/Field/DateField.php:113 forms/wpdFormAttr/Field/NumberField.php:123 forms/wpdFormAttr/Field/RadioField.php:128 forms/wpdFormAttr/Field/RatingField.php:129 forms/wpdFormAttr/Field/SelectField.php:122 forms/wpdFormAttr/Field/TextAreaField.php:95 forms/wpdFormAttr/Field/TextField.php:107 forms/wpdFormAttr/Field/UrlField.php:117
4280
  msgid "field is required!"
4281
  msgstr ""
4282
 
3
  msgstr ""
4
  "Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
5
  "Project-Id-Version: wpDiscuz\n"
6
+ "POT-Creation-Date: 2020-05-29 15:52+0000\n"
7
  "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
8
  "Last-Translator: \n"
9
  "Language-Team: \n"
27
  msgid "Every 48 hours"
28
  msgstr ""
29
 
30
+ #: class.WpdiscuzCore.php:903 class.WpdiscuzCore.php:1358
31
  msgid "Dashboard"
32
  msgstr ""
33
 
34
+ #: class.WpdiscuzCore.php:904 class.WpdiscuzCore.php:1359 options/html-options.php:399 options/html-options.php:510
35
  msgid "Settings"
36
  msgstr ""
37
 
38
+ #: class.WpdiscuzCore.php:906 class.WpdiscuzCore.php:1361
39
  msgid "Phrases"
40
  msgstr ""
41
 
42
+ #: class.WpdiscuzCore.php:908
43
  msgid "Tools"
44
  msgstr ""
45
 
46
+ #: class.WpdiscuzCore.php:909 options/html-options.php:26
47
  msgid "Addons"
48
  msgstr ""
49
 
50
+ #: class.WpdiscuzCore.php:924
51
  msgid "Do you really want to reset all options?"
52
  msgstr ""
53
 
54
+ #: class.WpdiscuzCore.php:925
55
  msgid "Do you really want to reset tab options?"
56
  msgstr ""
57
 
58
+ #: class.WpdiscuzCore.php:926
59
  msgid "Do you really want to remove voting data?"
60
  msgstr ""
61
 
62
+ #: class.WpdiscuzCore.php:927
63
  msgid "Do you really want to reset phrases?"
64
  msgstr ""
65
 
66
+ #: class.WpdiscuzCore.php:928
67
  msgid "Do you really want to delet this attachment?"
68
  msgstr ""
69
 
70
+ #: class.WpdiscuzCore.php:929
71
  msgid "Do you really want to delete gravatars cache?"
72
  msgstr ""
73
 
74
+ #: class.WpdiscuzCore.php:985
75
  msgid "Please check one of reasons before sending feedback!"
76
  msgstr ""
77
 
78
+ #: class.WpdiscuzCore.php:986 utils/deactivation-reason-modal.php:137
79
  msgid "Please provide more information"
80
  msgstr ""
81
 
82
+ #: class.WpdiscuzCore.php:1001 class.WpdiscuzCore.php:1769
83
  msgid "No text is selected. Please select a part of text from post content."
84
  msgstr ""
85
 
86
+ #: class.WpdiscuzCore.php:1485 options/phrases-layouts/phrases-comment.php:56
87
  msgid "Admin"
88
  msgstr ""
89
 
90
+ #: class.WpdiscuzCore.php:1488 class.WpdiscuzCore.php:1501 options/phrases-layouts/phrases-comment.php:58
91
  msgid "Author"
92
  msgstr ""
93
 
94
+ #: class.WpdiscuzCore.php:1491 options/phrases-layouts/phrases-comment.php:60
95
  msgid "Editor"
96
  msgstr ""
97
 
98
+ #: class.WpdiscuzCore.php:1494 options/phrases-layouts/phrases-comment.php:64
99
  msgid "Member"
100
  msgstr ""
101
 
102
+ #: class.WpdiscuzCore.php:1502 options/phrases-layouts/phrases-comment.php:62
103
  msgid "Guest"
104
  msgstr ""
105
 
106
+ #: class.WpdiscuzCore.php:1767
107
  msgid "Selected Text"
108
  msgstr ""
109
 
110
+ #: class.WpdiscuzCore.php:1774
111
  msgid "Your Question to Readers"
112
  msgstr ""
113
 
114
+ #: class.WpdiscuzCore.php:1775
115
  msgid "A simple question or a call to leave a feedback on the selected part of text. Something like &quot;By the way. Do you agree with this?&quot; or &quot;Would love your thoughts, please comment on this.&quot;"
116
  msgstr ""
117
 
118
+ #: class.WpdiscuzCore.php:1780
119
  msgid "e.g: Any thoughts on this?"
120
  msgstr ""
121
 
122
+ #: class.WpdiscuzCore.php:1785
123
  msgid "Feedback Button Display Type"
124
  msgstr ""
125
 
126
+ #: class.WpdiscuzCore.php:1786
127
  msgid "By default the inline feedback form is closed and only the button is displayed. Once reader scrolled and reached to the selected text part, this button animates with comment button size and color changes attracting readers attention. Readers click on the button and open your question with feedback form. Using this option you can keep opened the feedback form. Readers can close it using [x] button."
128
  msgstr ""
129
 
130
+ #: class.WpdiscuzCore.php:1794
131
  msgid "CLOSED"
132
  msgstr ""
133
 
134
+ #: class.WpdiscuzCore.php:1803
135
  msgid "OPENED"
136
  msgstr ""
137
 
138
+ #: class.WpdiscuzCore.php:1812
139
  msgid "Add Inline Feedback Button"
140
  msgstr ""
141
 
179
  msgid "Post IDs"
180
  msgstr ""
181
 
182
+ #: forms/wpDiscuzForm.php:176 forms/wpdFormAttr/Form.php:982
183
  msgid "Language"
184
  msgstr ""
185
 
191
  msgid "Two column"
192
  msgstr ""
193
 
194
+ #: forms/wpDiscuzForm.php:224 utils/class.WpdiscuzHelperUpload.php:681 forms/wpdFormAttr/Row.php:24 forms/wpdFormAttr/Field/Field.php:73
195
  msgid "Delete"
196
  msgstr ""
197
 
203
  msgid "Add Field"
204
  msgstr ""
205
 
206
+ #: forms/wpDiscuzForm.php:227 options/class.WpdiscuzOptions.php:326 options/phrases-layouts/phrases-comment.php:19 forms/wpdFormAttr/Field/Field.php:70
207
  msgid "Edit"
208
  msgstr ""
209
 
219
  msgid "Permission Denied !!!"
220
  msgstr ""
221
 
222
+ #: forms/wpDiscuzForm.php:257 forms/wpdFormAttr/Form.php:947 forms/wpdFormAttr/html/admin-form-fields-list.php:18
223
  msgid "Custom Fields"
224
  msgstr ""
225
 
231
  msgid "Default Form"
232
  msgstr ""
233
 
234
+ #: forms/wpDiscuzForm.php:403 options/html-phrases.php:21 forms/wpdFormAttr/Form.php:114 forms/wpdFormAttr/Form.php:1063 forms/wpdFormAttr/Form.php:1063 options/options-layouts/html-moderation.php:133
235
  msgid "Comment"
236
  msgstr ""
237
 
238
+ #: forms/wpDiscuzForm.php:404 utils/class.WpdiscuzHelperAjax.php:903 forms/wpdFormAttr/Form.php:122 forms/wpdFormAttr/Form.php:1074 forms/wpdFormAttr/Form.php:1074
239
  msgid "Comments"
240
  msgstr ""
241
 
242
+ #: forms/wpDiscuzForm.php:411 forms/wpdFormAttr/Form.php:174 forms/wpdFormAttr/Form.php:618 forms/wpdFormAttr/Form.php:1186 forms/wpdFormAttr/Form.php:1186
243
  msgid "Article Rating"
244
  msgstr ""
245
 
246
+ #: forms/wpDiscuzForm.php:431 forms/wpdFormAttr/Form.php:1277 forms/wpdFormAttr/Field/AgreementCheckbox.php:12 forms/wpdFormAttr/Field/CheckboxField.php:12 forms/wpdFormAttr/Field/ColorField.php:12 forms/wpdFormAttr/Field/CookiesConsent.php:14 forms/wpdFormAttr/Field/DateField.php:12 forms/wpdFormAttr/Field/HTMLField.php:12 forms/wpdFormAttr/Field/NumberField.php:12 forms/wpdFormAttr/Field/RadioField.php:12 forms/wpdFormAttr/Field/RatingField.php:12 forms/wpdFormAttr/Field/SelectField.php:12 forms/wpdFormAttr/Field/TextAreaField.php:12 forms/wpdFormAttr/Field/TextField.php:12 forms/wpdFormAttr/Field/UrlField.php:12 forms/wpdFormAttr/Field/DefaultField/Email.php:19 forms/wpdFormAttr/Field/DefaultField/Name.php:18 forms/wpdFormAttr/Field/DefaultField/Name.php:67 forms/wpdFormAttr/Field/DefaultField/Submit.php:18 forms/wpdFormAttr/Field/DefaultField/Website.php:18
247
  msgid "Name"
248
  msgstr ""
249
 
250
+ #: forms/wpDiscuzForm.php:433 options/class.WpdiscuzOptions.php:312 options/html-phrases.php:23 forms/wpdFormAttr/Form.php:1284 forms/wpdFormAttr/Field/DefaultField/Email.php:67
251
  msgid "Email"
252
  msgstr ""
253
 
255
  msgid "WebSite URL"
256
  msgstr ""
257
 
258
+ #: forms/wpDiscuzForm.php:438 forms/wpdFormAttr/Form.php:1307 forms/wpdFormAttr/Field/DefaultField/Submit.php:117
259
  msgid "Post Comment"
260
  msgstr ""
261
 
271
  msgid "Add Comment Form"
272
  msgstr ""
273
 
274
+ #: options/class.WpdiscuzOptions.php:306
275
  msgid "Be the First to Comment!"
276
  msgstr ""
277
 
278
+ #: options/class.WpdiscuzOptions.php:307
279
  msgid "Start the discussion"
280
  msgstr ""
281
 
282
+ #: options/class.WpdiscuzOptions.php:308
283
  msgid "Join the discussion"
284
  msgstr ""
285
 
286
+ #: options/class.WpdiscuzOptions.php:309 options/phrases-layouts/phrases-form.php:19
287
  msgid "Most reacted comment"
288
  msgstr ""
289
 
290
+ #: options/class.WpdiscuzOptions.php:310 options/phrases-layouts/phrases-form.php:23
291
  msgid "Hottest comment thread"
292
  msgstr ""
293
 
294
+ #: options/class.WpdiscuzOptions.php:311 options/phrases-layouts/phrases-form.php:27
295
  msgid "Inline Comments"
296
  msgstr ""
297
 
298
+ #: options/class.WpdiscuzOptions.php:313 options/phrases-layouts/phrases-form.php:35
299
  msgid "Subscribe"
300
  msgstr ""
301
 
302
+ #: options/class.WpdiscuzOptions.php:314 options/phrases-layouts/phrases-form.php:39
303
  msgid "Notify of"
304
  msgstr ""
305
 
306
+ #: options/class.WpdiscuzOptions.php:315
307
  msgid "new follow-up comments"
308
  msgstr ""
309
 
310
+ #: options/class.WpdiscuzOptions.php:316
311
  msgid "new replies to my comments"
312
  msgstr ""
313
 
314
+ #: options/class.WpdiscuzOptions.php:317
315
  msgid "Notify of new replies to this comment"
316
  msgstr ""
317
 
318
+ #: options/class.WpdiscuzOptions.php:318 options/phrases-layouts/phrases-form.php:55
319
  msgid "Sort by"
320
  msgstr ""
321
 
322
+ #: options/class.WpdiscuzOptions.php:319 options/phrases-layouts/phrases-form.php:59
323
  msgid "Newest"
324
  msgstr ""
325
 
326
+ #: options/class.WpdiscuzOptions.php:320 options/phrases-layouts/phrases-form.php:63
327
  msgid "Oldest"
328
  msgstr ""
329
 
330
+ #: options/class.WpdiscuzOptions.php:321 options/phrases-layouts/phrases-form.php:67
331
  msgid "Most Voted"
332
  msgstr ""
333
 
334
+ #: options/class.WpdiscuzOptions.php:322
335
  msgid "Load More Comments"
336
  msgstr ""
337
 
338
+ #: options/class.WpdiscuzOptions.php:323 options/phrases-layouts/phrases-general.php:19
339
  msgid "Load Rest of Comments"
340
  msgstr ""
341
 
342
+ #: options/class.WpdiscuzOptions.php:324 options/options-layouts/html-moderation.php:135 options/phrases-layouts/phrases-comment.php:11
343
  msgid "Reply"
344
  msgstr ""
345
 
346
+ #: options/class.WpdiscuzOptions.php:325 options/phrases-layouts/phrases-comment.php:15
347
  msgid "Share"
348
  msgstr ""
349
 
350
+ #: options/class.WpdiscuzOptions.php:327 options/phrases-layouts/phrases-comment.php:23
351
  msgid "Share On Facebook"
352
  msgstr ""
353
 
354
+ #: options/class.WpdiscuzOptions.php:328 options/phrases-layouts/phrases-comment.php:27
355
  msgid "Share On Twitter"
356
  msgstr ""
357
 
358
+ #: options/class.WpdiscuzOptions.php:329 options/phrases-layouts/phrases-comment.php:31
359
  msgid "Share On WhatsApp"
360
  msgstr ""
361
 
362
+ #: options/class.WpdiscuzOptions.php:330 options/phrases-layouts/phrases-comment.php:35
363
  msgid "Share On VKontakte"
364
  msgstr ""
365
 
366
+ #: options/class.WpdiscuzOptions.php:331 options/phrases-layouts/phrases-comment.php:39
367
  msgid "Share On Odnoklassniki"
368
  msgstr ""
369
 
370
+ #: options/class.WpdiscuzOptions.php:332 options/phrases-layouts/phrases-comment.php:43
371
  msgid "Hide Replies"
372
  msgstr ""
373
 
374
+ #: options/class.WpdiscuzOptions.php:333 options/phrases-layouts/phrases-comment.php:47
375
  msgid "View Replies"
376
  msgstr ""
377
 
378
+ #: options/class.WpdiscuzOptions.php:334 options/class.WpdiscuzOptions.php:454
379
  msgid "New Comment"
380
  msgstr ""
381
 
382
+ #: options/class.WpdiscuzOptions.php:335
383
  msgid "Hi [SUBSCRIBER_NAME],<br/><br/> new comment have been posted by the <em><strong>[COMMENT_AUTHOR]</em></strong> on the discussion section you've been interested in<br/><br/><a href='[COMMENT_URL]'>[COMMENT_URL]</a><br/><br/>[COMMENT_CONTENT]<br/><br/><a href='[UNSUBSCRIBE_URL]'>Unsubscribe</a>"
384
  msgstr ""
385
 
386
+ #: options/class.WpdiscuzOptions.php:336 options/class.WpdiscuzOptions.php:338
387
  msgid "New Reply"
388
  msgstr ""
389
 
390
+ #: options/class.WpdiscuzOptions.php:337 options/class.WpdiscuzOptions.php:339
391
  msgid "Hi [SUBSCRIBER_NAME],<br/><br/> new reply have been posted by the <em><strong>[COMMENT_AUTHOR]</em></strong> on the discussion section you've been interested in<br/><br/><a href='[COMMENT_URL]'>[COMMENT_URL]</a><br/><br/>[COMMENT_CONTENT]<br/><br/><a href='[UNSUBSCRIBE_URL]'>Unsubscribe</a>"
392
  msgstr ""
393
 
394
+ #: options/class.WpdiscuzOptions.php:340
395
  msgid "You're subscribed for new replies on this comment"
396
  msgstr ""
397
 
398
+ #: options/class.WpdiscuzOptions.php:341
399
  msgid "You're subscribed for new replies on all your comments"
400
  msgstr ""
401
 
402
+ #: options/class.WpdiscuzOptions.php:342
403
  msgid "You're subscribed for new follow-up comments on this post"
404
  msgstr ""
405
 
406
+ #: options/class.WpdiscuzOptions.php:343 options/phrases-layouts/phrases-email.php:172
407
  msgid "Unsubscribe"
408
  msgstr ""
409
 
410
+ #: options/class.WpdiscuzOptions.php:344
411
  msgid "Cancel subscription"
412
  msgstr ""
413
 
414
+ #: options/class.WpdiscuzOptions.php:345 options/phrases-layouts/phrases-notification.php:19
415
  msgid "You've successfully unsubscribed."
416
  msgstr ""
417
 
418
+ #: options/class.WpdiscuzOptions.php:346 options/phrases-layouts/phrases-notification.php:15
419
  msgid "You've successfully subscribed."
420
  msgstr ""
421
 
422
+ #: options/class.WpdiscuzOptions.php:347 options/phrases-layouts/phrases-email.php:180
423
  msgid "Confirm your subscription"
424
  msgstr ""
425
 
426
+ #: options/class.WpdiscuzOptions.php:348 options/phrases-layouts/phrases-email.php:184
427
  msgid "You've successfully confirmed your subscription."
428
  msgstr ""
429
 
430
+ #: options/class.WpdiscuzOptions.php:349
431
  msgid "Subscription Confirmation"
432
  msgstr ""
433
 
434
+ #: options/class.WpdiscuzOptions.php:350
435
  msgid "Hi, <br/> You just subscribed for new comments on our website. This means you will receive an email when new comments are posted according to subscription option you've chosen. <br/> To activate, click confirm below. If you believe this is an error, ignore this message and we'll never bother you again. <br/><br/><a href='[POST_URL]'>[POST_TITLE]</a><br/><br/><a href='[CONFIRM_URL]'>Confirm Your Subscrption</a><br/><br/><a href='[CANCEL_URL]'>Cancel Subscription</a>"
436
  msgstr ""
437
 
438
+ #: options/class.WpdiscuzOptions.php:351
439
  msgid "please fill out this field to comment"
440
  msgstr ""
441
 
442
+ #: options/class.WpdiscuzOptions.php:352
443
  msgid "email address is invalid"
444
  msgstr ""
445
 
446
+ #: options/class.WpdiscuzOptions.php:353
447
  msgid "url is invalid"
448
  msgstr ""
449
 
450
+ #: options/class.WpdiscuzOptions.php:354
451
  msgid "year"
452
  msgstr ""
453
 
454
+ #: options/class.WpdiscuzOptions.php:355
455
  msgid "years"
456
  msgstr ""
457
 
458
+ #: options/class.WpdiscuzOptions.php:356
459
  msgid "month"
460
  msgstr ""
461
 
462
+ #: options/class.WpdiscuzOptions.php:357
463
  msgid "months"
464
  msgstr ""
465
 
466
+ #: options/class.WpdiscuzOptions.php:358
467
  msgid "day"
468
  msgstr ""
469
 
470
+ #: options/class.WpdiscuzOptions.php:359 options/options-layouts/html-general.php:248
471
  msgid "days"
472
  msgstr ""
473
 
474
+ #: options/class.WpdiscuzOptions.php:360
475
  msgid "hour"
476
  msgstr ""
477
 
478
+ #: options/class.WpdiscuzOptions.php:361
479
  msgid "hours"
480
  msgstr ""
481
 
482
+ #: options/class.WpdiscuzOptions.php:362
483
  msgid "minute"
484
  msgstr ""
485
 
486
+ #: options/class.WpdiscuzOptions.php:363
487
  msgid "minutes"
488
  msgstr ""
489
 
490
+ #: options/class.WpdiscuzOptions.php:364
491
  msgid "second"
492
  msgstr ""
493
 
494
+ #: options/class.WpdiscuzOptions.php:365 options/options-layouts/html-live.php:111 options/options-layouts/html-live.php:126
495
  msgid "seconds"
496
  msgstr ""
497
 
498
+ #: options/class.WpdiscuzOptions.php:366
499
  msgid "right now"
500
  msgstr ""
501
 
502
+ #: options/class.WpdiscuzOptions.php:367
503
  msgid "ago"
504
  msgstr ""
505
 
506
+ #: options/class.WpdiscuzOptions.php:368 options/phrases-layouts/phrases-notification.php:38
507
  msgid "You must be"
508
  msgstr ""
509
 
510
+ #: options/class.WpdiscuzOptions.php:369
511
  msgid "You are logged in as"
512
  msgstr ""
513
 
514
+ #: options/class.WpdiscuzOptions.php:370 options/phrases-layouts/phrases-notification.php:29
515
  msgid "Login"
516
  msgstr ""
517
 
518
+ #: options/class.WpdiscuzOptions.php:371 options/phrases-layouts/phrases-notification.php:33
519
  #, php-format
520
  msgid "Please %s to comment"
521
  msgstr ""
522
 
523
+ #: options/class.WpdiscuzOptions.php:372 options/phrases-layouts/phrases-notification.php:54
524
  msgid "Log out"
525
  msgstr ""
526
 
527
+ #: options/class.WpdiscuzOptions.php:373
528
  msgid "logged in"
529
  msgstr ""
530
 
531
+ #: options/class.WpdiscuzOptions.php:374
532
  msgid "to post a comment."
533
  msgstr ""
534
 
535
+ #: options/class.WpdiscuzOptions.php:375 options/phrases-layouts/phrases-comment.php:75
536
  msgid "Vote Up"
537
  msgstr ""
538
 
539
+ #: options/class.WpdiscuzOptions.php:376 options/phrases-layouts/phrases-comment.php:79
540
  msgid "Vote Down"
541
  msgstr ""
542
 
543
+ #: options/class.WpdiscuzOptions.php:377 options/phrases-layouts/phrases-notification.php:58
544
  msgid "Vote Counted"
545
  msgstr ""
546
 
547
+ #: options/class.WpdiscuzOptions.php:378
548
  msgid "You've already voted for this comment"
549
  msgstr ""
550
 
551
+ #: options/class.WpdiscuzOptions.php:379 options/phrases-layouts/phrases-error.php:27
552
  msgid "Voting Error"
553
  msgstr ""
554
 
555
+ #: options/class.WpdiscuzOptions.php:380
556
  msgid "You Must Be Logged In To Vote"
557
  msgstr ""
558
 
559
+ #: options/class.WpdiscuzOptions.php:381
560
  msgid "You cannot vote for your comment"
561
  msgstr ""
562
 
563
+ #: options/class.WpdiscuzOptions.php:382
564
  msgid "You are not allowed to vote for this comment"
565
  msgstr ""
566
 
567
+ #: options/class.WpdiscuzOptions.php:383 options/phrases-layouts/phrases-error.php:39
568
  msgid "Invalid Captcha Code"
569
  msgstr ""
570
 
571
+ #: options/class.WpdiscuzOptions.php:384 options/phrases-layouts/phrases-error.php:43
572
  msgid "Some of field value is invalid"
573
  msgstr ""
574
 
575
+ #: options/class.WpdiscuzOptions.php:385 options/phrases-layouts/phrases-notification.php:66
576
  msgid "Awaiting for approval"
577
  msgstr ""
578
 
579
+ #: options/class.WpdiscuzOptions.php:386
580
  msgid "Sorry, the comment was not updated"
581
  msgstr ""
582
 
583
+ #: options/class.WpdiscuzOptions.php:387
584
  msgid "Sorry, this comment is no longer possible to edit"
585
  msgstr ""
586
 
587
+ #: options/class.WpdiscuzOptions.php:388
588
  msgid "You've not made any changes"
589
  msgstr ""
590
 
591
+ #: options/class.WpdiscuzOptions.php:389 utils/class.WpdiscuzHelper.php:1145
592
  msgid "Save"
593
  msgstr ""
594
 
595
+ #: options/class.WpdiscuzOptions.php:390
596
  msgid "Cancel"
597
  msgstr ""
598
 
599
+ #: options/class.WpdiscuzOptions.php:391
600
  msgid "Input is too short"
601
  msgstr ""
602
 
603
+ #: options/class.WpdiscuzOptions.php:392
604
  msgid "Input is too long"
605
  msgstr ""
606
 
607
+ #: options/class.WpdiscuzOptions.php:393
608
  msgid "Read more &raquo;"
609
  msgstr ""
610
 
611
+ #: options/class.WpdiscuzOptions.php:394
612
  msgid "Anonymous"
613
  msgstr ""
614
 
615
+ #: options/class.WpdiscuzOptions.php:395 options/phrases-layouts/phrases-error.php:67
616
  msgid "Please fill out required fields"
617
  msgstr ""
618
 
619
+ #: options/class.WpdiscuzOptions.php:396 options/phrases-layouts/phrases-social-login.php:11
620
  msgid "Connect with"
621
  msgstr ""
622
 
623
+ #: options/class.WpdiscuzOptions.php:397 options/phrases-layouts/phrases-notification.php:11
624
  msgid "You're subscribed to"
625
  msgstr ""
626
 
627
+ #: options/class.WpdiscuzOptions.php:398
628
  msgid "Participate in this discussion via email"
629
  msgstr ""
630
 
631
+ #: options/class.WpdiscuzOptions.php:399 utils/layouts/pagination.php:45
632
  msgid "&rsaquo;"
633
  msgstr ""
634
 
635
+ #: options/class.WpdiscuzOptions.php:400
636
  msgid "Your comment is approved!"
637
  msgstr ""
638
 
639
+ #: options/class.WpdiscuzOptions.php:401
640
  msgid "Hi [COMMENT_AUTHOR],<br/><br/>your comment was approved.<br/><br/><a href=\"[COMMENT_URL]\">[COMMENT_URL]</a><br/><br/>[COMMENT_CONTENT]"
641
  msgstr ""
642
 
643
+ #: options/class.WpdiscuzOptions.php:402
644
  msgid "Comments are closed."
645
  msgstr ""
646
 
647
+ #: options/class.WpdiscuzOptions.php:403
648
  msgid "Stick this comment"
649
  msgstr ""
650
 
651
+ #: options/class.WpdiscuzOptions.php:404 options/phrases-layouts/phrases-comment.php:103
652
  msgid "Stick"
653
  msgstr ""
654
 
655
+ #: options/class.WpdiscuzOptions.php:405 options/phrases-layouts/phrases-comment.php:107
656
  msgid "Unstick"
657
  msgstr ""
658
 
659
+ #: options/class.WpdiscuzOptions.php:406
660
  msgid "Sticky Comment Thread"
661
  msgstr ""
662
 
663
+ #: options/class.WpdiscuzOptions.php:407
664
  msgid "Close this thread"
665
  msgstr ""
666
 
667
+ #: options/class.WpdiscuzOptions.php:408 options/html-dashboard.php:34 options/phrases-layouts/phrases-comment.php:119
668
  msgid "Close"
669
  msgstr ""
670
 
671
+ #: options/class.WpdiscuzOptions.php:409 options/phrases-layouts/phrases-comment.php:123
672
  msgid "Open"
673
  msgstr ""
674
 
675
+ #: options/class.WpdiscuzOptions.php:410
676
  msgid "Closed Comment Thread"
677
  msgstr ""
678
 
679
+ #: options/class.WpdiscuzOptions.php:411
680
  msgid "I allow to create an account"
681
  msgstr ""
682
 
683
+ #: options/class.WpdiscuzOptions.php:412
684
  msgid "When you login first time using a Social Login button, we collect your account public profile information shared by Social Login provider, based on your privacy settings. We also get your email address to automatically create an account for you in our website. Once your account is created, you'll be logged-in to this account."
685
  msgstr ""
686
 
687
+ #: options/class.WpdiscuzOptions.php:413 options/phrases-layouts/phrases-social-login.php:23
688
  msgid "Disagree"
689
  msgstr ""
690
 
691
+ #: options/class.WpdiscuzOptions.php:414 options/phrases-layouts/phrases-social-login.php:27
692
  msgid "Agree"
693
  msgstr ""
694
 
695
+ #: options/class.WpdiscuzOptions.php:415 options/phrases-layouts/phrases-user-settings.php:11
696
  msgid "My content and settings"
697
  msgstr ""
698
 
699
+ #: options/class.WpdiscuzOptions.php:416 options/phrases-layouts/phrases-user-settings.php:15
700
  msgid "Activity"
701
  msgstr ""
702
 
703
+ #: options/class.WpdiscuzOptions.php:417 options/html-dashboard.php:201 utils/class.WpdiscuzHelperAjax.php:907 options/phrases-layouts/phrases-user-settings.php:19
704
  msgid "Subscriptions"
705
  msgstr ""
706
 
707
+ #: options/class.WpdiscuzOptions.php:418 options/phrases-layouts/phrases-user-settings.php:23
708
  msgid "Follows"
709
  msgstr ""
710
 
711
+ #: options/class.WpdiscuzOptions.php:419 options/phrases-layouts/phrases-user-settings.php:27
712
  msgid "In response to:"
713
  msgstr ""
714
 
715
+ #: options/class.WpdiscuzOptions.php:420 options/class.WpdiscuzOptions.php:426 options/phrases-layouts/phrases-user-settings.php:31 options/phrases-layouts/phrases-user-settings.php:55
716
  msgid "Bulk management via email"
717
  msgstr ""
718
 
719
+ #: options/class.WpdiscuzOptions.php:421
720
  msgid "Click the button above to get an email with bulk delete and unsubscribe links."
721
  msgstr ""
722
 
723
+ #: options/class.WpdiscuzOptions.php:422 options/phrases-layouts/phrases-user-settings.php:39
724
  msgid "No data found!"
725
  msgstr ""
726
 
727
+ #: options/class.WpdiscuzOptions.php:423 options/class.WpdiscuzOptions.php:427 options/phrases-layouts/phrases-user-settings.php:43 options/phrases-layouts/phrases-user-settings.php:60
728
  msgid "Delete all my comments"
729
  msgstr ""
730
 
731
+ #: options/class.WpdiscuzOptions.php:424 options/phrases-layouts/phrases-user-settings.php:47
732
  msgid "Cancel all comment subscriptions"
733
  msgstr ""
734
 
735
+ #: options/class.WpdiscuzOptions.php:425 options/phrases-layouts/phrases-user-settings.php:51
736
  msgid "Clear cookies with my personal data"
737
  msgstr ""
738
 
739
+ #: options/class.WpdiscuzOptions.php:428
740
  msgid "Please use this link to delete all your comments. Please note, that this action cannot be undone.<br/><br/><a href=\"[DELETE_COMMENTS_URL]\" target=\"_blank\">Delete all my comments</a><br/><br/>"
741
  msgstr ""
742
 
743
+ #: options/class.WpdiscuzOptions.php:429 options/phrases-layouts/phrases-user-settings.php:85
744
  msgid "Delete all my subscriptions"
745
  msgstr ""
746
 
747
+ #: options/class.WpdiscuzOptions.php:430
748
  msgid "Please use this link to cancel all subscriptions for new comments. Please note, that this action cannot be undone.<br/><br/><a href=\"[DELETE_SUBSCRIPTIONS_URL]\" target=\"_blank\">Delete all my subscriptions</a><br/><br/>"
749
  msgstr ""
750
 
751
+ #: options/class.WpdiscuzOptions.php:431 options/phrases-layouts/phrases-user-settings.php:110
752
  msgid "Delete all my follows"
753
  msgstr ""
754
 
755
+ #: options/class.WpdiscuzOptions.php:432
756
  msgid "Please use this link to cancel all follows for new comments. Please note, that this action cannot be undone.<br/><br/><a href=\"[DELETE_FOLLOWS_URL]\" target=\"_blank\">Delete all my follows</a><br/><br/>"
757
  msgstr ""
758
 
759
+ #: options/class.WpdiscuzOptions.php:433 options/phrases-layouts/phrases-user-settings.php:134
760
  msgid "subscribed to this comment"
761
  msgstr ""
762
 
763
+ #: options/class.WpdiscuzOptions.php:434 options/phrases-layouts/phrases-user-settings.php:138
764
  msgid "subscribed to my comments"
765
  msgstr ""
766
 
767
+ #: options/class.WpdiscuzOptions.php:435 options/phrases-layouts/phrases-user-settings.php:142
768
  msgid "subscribed to all follow-up comments of this post"
769
  msgstr ""
770
 
771
+ #: options/class.WpdiscuzOptions.php:437 options/phrases-layouts/phrases-user-settings.php:150
772
  msgid "Error : Can't send email."
773
  msgstr ""
774
 
775
+ #: options/class.WpdiscuzOptions.php:438 options/phrases-layouts/phrases-user-settings.php:154
776
  msgid "Are you sure you want to delete this comment?"
777
  msgstr ""
778
 
779
+ #: options/class.WpdiscuzOptions.php:439 options/phrases-layouts/phrases-user-settings.php:158
780
  msgid "Are you sure you want to cancel this subscription?"
781
  msgstr ""
782
 
783
+ #: options/class.WpdiscuzOptions.php:440 options/phrases-layouts/phrases-user-settings.php:162
784
  msgid "Are you sure you want to cancel this follow?"
785
  msgstr ""
786
 
787
+ #: options/class.WpdiscuzOptions.php:441 options/phrases-layouts/phrases-follow.php:11
788
  msgid "Follow this user"
789
  msgstr ""
790
 
791
+ #: options/class.WpdiscuzOptions.php:442 options/phrases-layouts/phrases-follow.php:15
792
  msgid "Unfollow this user"
793
  msgstr ""
794
 
795
+ #: options/class.WpdiscuzOptions.php:443 options/phrases-layouts/phrases-follow.php:19
796
  msgid "You started following this comment author"
797
  msgstr ""
798
 
799
+ #: options/class.WpdiscuzOptions.php:444
800
  msgid "You stopped following this comment author."
801
  msgstr ""
802
 
803
+ #: options/class.WpdiscuzOptions.php:445
804
  msgid "Please check your email and confirm the user following request."
805
  msgstr ""
806
 
807
+ #: options/class.WpdiscuzOptions.php:446
808
  msgid "Sorry, we couldn't send confirmation email."
809
  msgstr ""
810
 
811
+ #: options/class.WpdiscuzOptions.php:447
812
  msgid "Please login to follow users."
813
  msgstr ""
814
 
815
+ #: options/class.WpdiscuzOptions.php:448
816
  msgid "We are sorry, but you can't follow this user."
817
  msgstr ""
818
 
819
+ #: options/class.WpdiscuzOptions.php:449
820
  msgid "Following failed. Please try again later."
821
  msgstr ""
822
 
823
+ #: options/class.WpdiscuzOptions.php:450
824
  msgid "Confirm user following request"
825
  msgstr ""
826
 
827
+ #: options/class.WpdiscuzOptions.php:451
828
  msgid "Cancel user following request"
829
  msgstr ""
830
 
831
+ #: options/class.WpdiscuzOptions.php:452
832
  msgid "User Following Confirmation"
833
  msgstr ""
834
 
835
+ #: options/class.WpdiscuzOptions.php:453 options/class.WpdiscuzOptions.php:455
836
  msgid "</a>"
837
  msgstr ""
838
 
839
+ #: options/class.WpdiscuzOptions.php:456
840
  msgid "You have been mentioned in comment"
841
  msgstr ""
842
 
843
+ #: options/class.WpdiscuzOptions.php:457
844
  msgid "Hi [MENTIONED_USER_NAME]!<br/>You have been mentioned in a comment posted on \"[POST_TITLE]\" post by [COMMENT_AUTHOR].<br/><br/>Comment URL: <a href=\"[COMMENT_URL]\">[COMMENT_URL]</a>"
845
  msgstr ""
846
 
847
+ #: options/class.WpdiscuzOptions.php:458 options/phrases-layouts/phrases-general.php:23
848
  msgid "Copied to clipboard!"
849
  msgstr ""
850
 
851
+ #: options/class.WpdiscuzOptions.php:459 options/phrases-layouts/phrases-general.php:27
852
  msgid "Select a part of text and ask readers for feedback (inline commenting)"
853
  msgstr ""
854
 
855
+ #: options/class.WpdiscuzOptions.php:460 options/phrases-layouts/phrases-general.php:31
856
  msgid "Ask for Feedback"
857
  msgstr ""
858
 
859
+ #: options/class.WpdiscuzOptions.php:461 options/phrases-layouts/phrases-general.php:35
860
  msgid "Please leave a feedback on this"
861
  msgstr ""
862
 
863
+ #: options/class.WpdiscuzOptions.php:463 utils/deactivation-reason-modal.php:157
864
  msgid "Thank you for your feedback!"
865
  msgstr ""
866
 
867
+ #: options/class.WpdiscuzOptions.php:464
868
  msgid "Commenting is closed!"
869
  msgstr ""
870
 
871
+ #: options/class.WpdiscuzOptions.php:465 options/phrases-layouts/phrases-general.php:51
872
  msgid "This is closed comment thread"
873
  msgstr ""
874
 
875
+ #: options/class.WpdiscuzOptions.php:466
876
  msgid "Would love your thoughts, please comment."
877
  msgstr ""
878
 
879
+ #: options/class.WpdiscuzOptions.php:467 options/phrases-layouts/phrases-general.php:59
880
  msgid "vote"
881
  msgstr ""
882
 
883
+ #: options/class.WpdiscuzOptions.php:468 options/phrases-layouts/phrases-general.php:63
884
  msgid "votes"
885
  msgstr ""
886
 
887
+ #: options/class.WpdiscuzOptions.php:469 options/phrases-layouts/phrases-general.php:67
888
  msgid "Comment Link"
889
  msgstr ""
890
 
891
+ #: options/class.WpdiscuzOptions.php:470 options/class.WpdiscuzOptions.php:471
892
  #, php-format
893
  msgid "We are sorry, you are not allowed to comment more than %d time(s)!"
894
  msgstr ""
895
 
896
+ #: options/class.WpdiscuzOptions.php:472
897
  #, php-format
898
  msgid "We are sorry, you are not allowed to reply more than %d time(s)!"
899
  msgstr ""
900
 
901
+ #: options/class.WpdiscuzOptions.php:473 options/phrases-layouts/phrases-general.php:83
902
  msgid "Your comment here..."
903
  msgstr ""
904
 
905
+ #: options/class.WpdiscuzOptions.php:474 options/phrases-layouts/phrases-general.php:87
906
  msgid "Notify me via email when a new reply is posted"
907
  msgstr ""
908
 
909
+ #: options/class.WpdiscuzOptions.php:475 options/phrases-layouts/phrases-general.php:91
910
  msgid "Your Name*"
911
  msgstr ""
912
 
913
+ #: options/class.WpdiscuzOptions.php:476 options/phrases-layouts/phrases-general.php:95
914
  msgid "Your Email"
915
  msgstr ""
916
 
917
+ #: options/class.WpdiscuzOptions.php:477 options/phrases-layouts/phrases-general.php:99
918
  msgid "COMMENT"
919
  msgstr ""
920
 
921
+ #: options/class.WpdiscuzOptions.php:478 options/phrases-layouts/phrases-general.php:103
922
  msgid "View all comments"
923
  msgstr ""
924
 
925
+ #: options/class.WpdiscuzOptions.php:479 options/html-dashboard.php:127 options/phrases-layouts/phrases-general.php:107
926
  msgid "Inline Feedbacks"
927
  msgstr ""
928
 
929
+ #: options/class.WpdiscuzOptions.php:480 options/phrases-layouts/phrases-general.php:111
930
  msgid "Unable to send an email"
931
  msgstr ""
932
 
933
+ #: options/class.WpdiscuzOptions.php:481 options/phrases-layouts/phrases-general.php:115
934
  msgid "Subscription Fault"
935
  msgstr ""
936
 
937
+ #: options/class.WpdiscuzOptions.php:482 options/phrases-layouts/phrases-general.php:119
938
  msgid "Your comments have been deleted from database"
939
  msgstr ""
940
 
941
+ #: options/class.WpdiscuzOptions.php:483 options/phrases-layouts/phrases-general.php:123
942
  msgid "You cancel all your subscriptions successfully"
943
  msgstr ""
944
 
945
+ #: options/class.WpdiscuzOptions.php:484 options/phrases-layouts/phrases-general.php:127
946
  msgid "You cancel all your follows successfully"
947
  msgstr ""
948
 
949
+ #: options/class.WpdiscuzOptions.php:485 options/phrases-layouts/phrases-general.php:131
950
  msgid "Follow has been confirmed successfully"
951
  msgstr ""
952
 
953
+ #: options/class.WpdiscuzOptions.php:486 options/phrases-layouts/phrases-general.php:135
954
  msgid "Follow has been canceled successfully"
955
  msgstr ""
956
 
957
+ #: options/class.WpdiscuzOptions.php:487 options/phrases-layouts/phrases-general.php:139
958
  msgid "Please login to comment"
959
  msgstr ""
960
 
961
+ #: options/class.WpdiscuzOptions.php:488 options/phrases-layouts/phrases-general.php:143
962
  msgid "View Comments"
963
  msgstr ""
964
 
965
+ #: options/class.WpdiscuzOptions.php:489 options/options-layouts/html-form.php:111 options/phrases-layouts/phrases-general.php:147
966
  msgid "Spoiler"
967
  msgstr ""
968
 
969
+ #: options/class.WpdiscuzOptions.php:490 options/phrases-layouts/phrases-general.php:151
970
  #, php-format
971
  msgid "Last edited %1$s by %2$s"
972
  msgstr ""
973
 
974
+ #: options/class.WpdiscuzOptions.php:491 options/phrases-layouts/phrases-general.php:155
975
  msgid "Reply to"
976
  msgstr ""
977
 
978
+ #: options/class.WpdiscuzOptions.php:492 options/phrases-layouts/phrases-general.php:159
979
  msgid "Manage Comment"
980
  msgstr ""
981
 
982
+ #: options/class.WpdiscuzOptions.php:493 options/phrases-layouts/phrases-general.php:163
983
  msgid "Spoiler Title"
984
  msgstr ""
985
 
986
+ #: options/class.WpdiscuzOptions.php:494 options/phrases-layouts/phrases-general.php:167
987
  msgid "You cannot rate again"
988
  msgstr ""
989
 
990
+ #: options/class.WpdiscuzOptions.php:495 options/phrases-layouts/phrases-general.php:171
991
  msgid "You're not allowed to rate here"
992
  msgstr ""
993
 
994
+ #: options/class.WpdiscuzOptions.php:497
995
  msgid "Are you sure you want to delete this attachment?"
996
  msgstr ""
997
 
998
+ #: options/class.WpdiscuzOptions.php:498
999
  msgid "Not allowed file type"
1000
  msgstr ""
1001
 
1002
+ #: options/class.WpdiscuzOptions.php:499
1003
  msgid "Maximum number of uploaded files is"
1004
  msgstr ""
1005
 
1006
+ #: options/class.WpdiscuzOptions.php:500
1007
  msgid "Maximum upload file size is"
1008
  msgstr ""
1009
 
1010
+ #: options/class.WpdiscuzOptions.php:501
1011
  msgid "Maximum post size is"
1012
  msgstr ""
1013
 
1014
+ #: options/class.WpdiscuzOptions.php:502 options/phrases-layouts/phrases-media.php:31
1015
  msgid "Attach an image to this comment"
1016
  msgstr ""
1017
 
1018
+ #: options/class.WpdiscuzOptions.php:503 options/phrases-layouts/phrases-media.php:35
1019
  msgid "Change the attached image"
1020
  msgstr ""
1021
 
1022
+ #: options/class.WpdiscuzOptions.php:1086
1023
  msgid "Post ID not exists"
1024
  msgstr ""
1025
 
1026
+ #: options/class.WpdiscuzOptions.php:1087
1027
  msgid "Sorry, uploading not allowed for this post"
1028
  msgstr ""
1029
 
1030
+ #: options/class.WpdiscuzOptions.php:1088
1031
  msgid "You do not have sufficient permissions to perform this action"
1032
  msgstr ""
1033
 
1034
+ #: options/class.WpdiscuzOptions.php:1160 options/class.WpdiscuzOptions.php:1400 options/class.WpdiscuzOptions.php:1743
1035
  msgid "Hacker?"
1036
  msgstr ""
1037
 
1038
+ #: options/class.WpdiscuzOptions.php:1656
1039
  msgid "Settings updated"
1040
  msgstr ""
1041
 
1042
+ #: options/class.WpdiscuzOptions.php:1663
1043
  msgid "Phrases updated"
1044
  msgstr ""
1045
 
1046
+ #: options/class.WpdiscuzOptions.php:1687
1047
  msgid "Options were backed up!"
1048
  msgstr ""
1049
 
1050
+ #: options/class.WpdiscuzOptions.php:1689
1051
  msgid "Cannot back up the options!"
1052
  msgstr ""
1053
 
1054
+ #: options/class.WpdiscuzOptions.php:1700
1055
  msgid "Options Imported Successfully!"
1056
  msgstr ""
1057
 
1058
+ #: options/class.WpdiscuzOptions.php:1702 options/class.WpdiscuzOptions.php:1732
1059
  msgid "Error occured! File content is empty or data is not valid!"
1060
  msgstr ""
1061
 
1062
+ #: options/class.WpdiscuzOptions.php:1705 options/class.WpdiscuzOptions.php:1735
1063
  msgid "Error occured! Can not get file content!"
1064
  msgstr ""
1065
 
1066
+ #: options/class.WpdiscuzOptions.php:1708 options/class.WpdiscuzOptions.php:1738
1067
  msgid "Error occured! Please choose file!"
1068
  msgstr ""
1069
 
1070
+ #: options/class.WpdiscuzOptions.php:1717
1071
  msgid "Phrases were backed up!"
1072
  msgstr ""
1073
 
1074
+ #: options/class.WpdiscuzOptions.php:1719
1075
  msgid "Cannot back up the phrases!"
1076
  msgstr ""
1077
 
1078
+ #: options/class.WpdiscuzOptions.php:1730
1079
  msgid "Phrases Imported Successfully!"
1080
  msgstr ""
1081
 
1082
+ #: options/class.WpdiscuzOptions.php:1754
1083
  msgid "All 16 addons in one bundle. Save 90% and get Unlimited Site License with one year premium support."
1084
  msgstr ""
1085
 
1086
+ #: options/class.WpdiscuzOptions.php:1755
1087
  msgid "Extended comment attachment system. Allows to upload images, videos, audios and other file types."
1088
  msgstr ""
1089
 
1090
+ #: options/class.WpdiscuzOptions.php:1756
1091
  msgid "All in one powerful yet simple admin toolkit to moderate comments on front-end."
1092
  msgstr ""
1093
 
1094
+ #: options/class.WpdiscuzOptions.php:1757
1095
  msgid "Brings an ocean of emotions to your comments. It comes with an awesome smile package."
1096
  msgstr ""
1097
 
1098
+ #: options/class.WpdiscuzOptions.php:1758
1099
  msgid "Adds Invisible reCAPTCHA on all comment forms. Stops spam and bot comments with reCAPTCHA version 3"
1100
  msgstr ""
1101
 
1102
+ #: options/class.WpdiscuzOptions.php:1759
1103
  msgid "Extended information about comment author with Profile, Activity, Votes and Subscriptions Tabs on pop-up window."
1104
  msgstr ""
1105
 
1106
+ #: options/class.WpdiscuzOptions.php:1760
1107
  msgid "Comment reporting tools. Auto-moderates comments based on number of flags and dislikes."
1108
  msgstr ""
1109
 
1110
+ #: options/class.WpdiscuzOptions.php:1761
1111
  msgid "Real-time online user checking, pop-up notification of new online users and online/offline badges."
1112
  msgstr ""
1113
 
1114
+ #: options/class.WpdiscuzOptions.php:1762
1115
  msgid "Allows to create private comment threads. Rich management options in dashboard by user roles."
1116
  msgstr ""
1117
 
1118
+ #: options/class.WpdiscuzOptions.php:1763
1119
  msgid "Total control over comment subscriptions. Full list, monitor, manage, filter, unsubscribe, confirm..."
1120
  msgstr ""
1121
 
1122
+ #: options/class.WpdiscuzOptions.php:1764
1123
  msgid "A full-fledged tool-kit for advertising in comment section of your website. Separate banner and ad managment."
1124
  msgstr ""
1125
 
1126
+ #: options/class.WpdiscuzOptions.php:1765
1127
  msgid "Allows to mention comments and users in comment text using #comment-id and @username tags."
1128
  msgstr ""
1129
 
1130
+ #: options/class.WpdiscuzOptions.php:1766
1131
  msgid "See comment likers and voters of each comment. Adds user reputation and badges based on received likes."
1132
  msgstr ""
1133
 
1134
+ #: options/class.WpdiscuzOptions.php:1767
1135
  msgid "Adds a smart and intuitive AJAX \"Translate\" button with 60 language options. Uses free translation API."
1136
  msgstr ""
1137
 
1138
+ #: options/class.WpdiscuzOptions.php:1768
1139
  msgid "AJAX powered front-end comment search. It starts searching while you type search words. "
1140
  msgstr ""
1141
 
1142
+ #: options/class.WpdiscuzOptions.php:1769
1143
  msgid "Most voted comments, Active comment threads, Most commented posts, Active comment authors"
1144
  msgstr ""
1145
 
1146
+ #: options/class.WpdiscuzOptions.php:1770
1147
  msgid "Integrates myCRED Badges and Ranks. Converts wpDiscuz comment votes/likes to myCRED points. "
1148
  msgstr ""
1149
 
1150
+ #: options/class.WpdiscuzOptions.php:1776
1151
  msgid "Custom Comment Forms"
1152
  msgstr ""
1153
 
1154
+ #: options/class.WpdiscuzOptions.php:1777
1155
  msgid "You can create custom comment forms with wpDiscuz. wpDiscuz 4 comes with custom comment forms and fields. You can create custom comment forms for each post type, each form can beceated with different form fields, for eaxample: text, dropdown, rating, checkboxes, etc..."
1156
  msgstr ""
1157
 
1158
+ #: options/class.WpdiscuzOptions.php:1780
1159
  msgid "Emoticons"
1160
  msgstr ""
1161
 
1162
+ #: options/class.WpdiscuzOptions.php:1781
1163
  msgid "You can add more emotions to your comments using wpDiscuz Emoticons addon."
1164
  msgstr ""
1165
 
1166
+ #: options/class.WpdiscuzOptions.php:1784
1167
  msgid "Ads Manager"
1168
  msgstr ""
1169
 
1170
+ #: options/class.WpdiscuzOptions.php:1785
1171
  msgid "Increase your income using ad banners. Comment area is the most active sections for advertising. wpDiscuz Ads Manager addon is designed to help you add banners and control ads in this section."
1172
  msgstr ""
1173
 
1174
+ #: options/class.WpdiscuzOptions.php:1788
1175
  msgid "User and Comment Mentioning"
1176
  msgstr ""
1177
 
1178
+ #: options/class.WpdiscuzOptions.php:1789
1179
  msgid "Using wpDiscuz User &amp; Comment Mentioning addon you can allow commenters mention comments and users in comment text using #comment-id and @username tags."
1180
  msgstr ""
1181
 
1182
+ #: options/class.WpdiscuzOptions.php:1792 options/addons/al/title.php:7
1183
  msgid "Advanced Likers"
1184
  msgstr ""
1185
 
1186
+ #: options/class.WpdiscuzOptions.php:1793
1187
  msgid "wpDiscuz Advanced Likers addon displays likers and voters of each comment. Adds user reputation and badges based on received likes."
1188
  msgstr ""
1189
 
1190
+ #: options/class.WpdiscuzOptions.php:1796 options/addons/raf/title.php:7
1191
  msgid "Report and Flagging"
1192
  msgstr ""
1193
 
1194
+ #: options/class.WpdiscuzOptions.php:1797
1195
  msgid "Let your commenters help you to determine and remove spam comments. wpDiscuz Report and Flagging addon comes with comment reporting tools. Automaticaly auto-moderates comments based on number of flags and dislikes."
1196
  msgstr ""
1197
 
1198
+ #: options/class.WpdiscuzOptions.php:1800
1199
  msgid "Comment Translate"
1200
  msgstr ""
1201
 
1202
+ #: options/class.WpdiscuzOptions.php:1801
1203
  msgid "In most cases the big part of your visitors are not a native speakers of your language. Make your comments comprehensible for all visitors using wpDiscuz Comment Translation addon. It adds smart and intuitive AJAX 'Translate' button with 60 language translation options. Uses free translation API."
1204
  msgstr ""
1205
 
1206
+ #: options/class.WpdiscuzOptions.php:1804
1207
  msgid "Comment Search"
1208
  msgstr ""
1209
 
1210
+ #: options/class.WpdiscuzOptions.php:1805
1211
  msgid "You can let website visitor search in comments. It's always more attractive to find a comment about something that interest you. Using wpDiscuz Comment Search addon you'll get a nice, AJAX powered front-end comment search form above comment list."
1212
  msgstr ""
1213
 
1214
+ #: options/class.WpdiscuzOptions.php:1808
1215
  msgid "wpDiscuz Widgets"
1216
  msgstr ""
1217
 
1218
+ #: options/class.WpdiscuzOptions.php:1809
1219
  msgid "More Comment Widgets! Most voted comments, Active comment threads, Most commented posts, Active comment authors widgets are available in wpDiscuz Widgets Addon"
1220
  msgstr ""
1221
 
1222
+ #: options/class.WpdiscuzOptions.php:1812
1223
  msgid "Front-end Moderation"
1224
  msgstr ""
1225
 
1226
+ #: options/class.WpdiscuzOptions.php:1813
1227
  msgid "You can moderate comments on front-end using all in one powerful yet simple wpDiscuz Frontend Moderation addon."
1228
  msgstr ""
1229
 
1230
+ #: options/class.WpdiscuzOptions.php:1816 options/addons/mu/title.php:7
1231
  msgid "Media Uploader"
1232
  msgstr ""
1233
 
1234
+ #: options/class.WpdiscuzOptions.php:1817
1235
  msgid "You can let website visitors attach images and files to comments and embed video/audio content using wpDiscuz Media Uploader addon."
1236
  msgstr ""
1237
 
1238
+ #: options/class.WpdiscuzOptions.php:1820
1239
  msgid "Google ReCaptcha"
1240
  msgstr ""
1241
 
1242
+ #: options/class.WpdiscuzOptions.php:1821
1243
  msgid "Advanced spam protection with wpDiscuz Google reCAPTCHA addon. This addon adds No-CAPTCHA reCAPTCHA on all comment forms. Stops spam and bot comments."
1244
  msgstr ""
1245
 
1246
+ #: options/class.WpdiscuzOptions.php:1837
1247
  msgid "Finally wpDiscuz Addons Bundle is ready for You!"
1248
  msgstr ""
1249
 
1250
+ #: options/class.WpdiscuzOptions.php:1847
1251
  msgid "View Addons Bundle"
1252
  msgstr ""
1253
 
1254
+ #: options/class.WpdiscuzOptions.php:1935
1255
  msgid "Please complete required steps to start using wpDiscuz 7"
1256
  msgstr ""
1257
 
1258
+ #: options/class.WpdiscuzOptions.php:1936
1259
  msgid "Go to Update Wizard &raquo;"
1260
  msgstr ""
1261
 
1262
+ #: options/class.WpdiscuzOptions.php:1936
1263
  msgid "Go to Installation Wizard &raquo;"
1264
  msgstr ""
1265
 
1266
+ #: options/class.WpdiscuzOptions.php:1945
1267
  msgid "Jetpack Comments are active."
1268
  msgstr ""
1269
 
1270
+ #: options/class.WpdiscuzOptions.php:1954
1271
  msgid "Comment votes meta data need to be regenerated"
1272
  msgstr ""
1273
 
1274
+ #: options/class.WpdiscuzOptions.php:1955 options/html-tools.php:20 options/tools-layouts/regenerate-vote-metas.php:10 options/tools-layouts/regenerate-vote-metas.php:18
1275
  msgid "Regenerate Vote Metas"
1276
  msgstr ""
1277
 
1278
+ #: options/class.WpdiscuzOptions.php:1964
1279
  msgid "Closed Comments data need be regenerated"
1280
  msgstr ""
1281
 
1282
+ #: options/class.WpdiscuzOptions.php:1965 options/html-tools.php:21 options/tools-layouts/regenerate-closed-comments.php:10 options/tools-layouts/regenerate-closed-comments.php:18
1283
  msgid "Regenerate Closed Comments"
1284
  msgstr ""
1285
 
1286
+ #: options/class.WpdiscuzOptions.php:1974
1287
  msgid "Comments votes data need to be regenerated"
1288
  msgstr ""
1289
 
1290
+ #: options/class.WpdiscuzOptions.php:1975 options/html-tools.php:22 options/tools-layouts/regenerate-vote-data.php:10 options/tools-layouts/regenerate-vote-data.php:18
1291
  msgid "Regenerate Vote Data"
1292
  msgstr ""
1293
 
1294
+ #: options/class.WpdiscuzOptions.php:1984
1295
  msgid "Please synchronize comment data for the best performance and fastest experience"
1296
  msgstr ""
1297
 
1298
+ #: options/class.WpdiscuzOptions.php:1985 options/tools-layouts/sync-commenter-data.php:8 options/tools-layouts/sync-commenter-data.php:16
1299
  msgid "Synchronize Commenters Data"
1300
  msgstr ""
1301
 
1302
+ #: options/class.WpdiscuzOptions.php:2493
1303
  msgid "Comment Form Settings"
1304
  msgstr ""
1305
 
1306
+ #: options/class.WpdiscuzOptions.php:2501
1307
  msgid "Keep guest commenter credentials in browser cookies for X days"
1308
  msgstr ""
1309
 
1310
+ #: options/class.WpdiscuzOptions.php:2503
1311
  msgid "wpDiscuz uses WordPress functions to keep guest Name, Email and Website information in cookies. Those are used to fill according fields of comment form on next commenting time. Set this option value -1 to make it unlimited. Set this option value 0 to clear those data when user closes browser."
1312
  msgstr ""
1313
 
1314
+ #: options/class.WpdiscuzOptions.php:2508
1315
  msgid "Comment author name length (for guests only)"
1316
  msgstr ""
1317
 
1318
+ #: options/class.WpdiscuzOptions.php:2515
1319
  msgid "Comment Form View"
1320
  msgstr ""
1321
 
1322
+ #: options/class.WpdiscuzOptions.php:2517
1323
  msgid "By default, only the comment text field is visible. When you click on the comment text field it opens all other fields (Name, Email, Website, etc...). If you want to keep all fields open, please set this option \"expended\"."
1324
  msgstr ""
1325
 
1326
+ #: options/class.WpdiscuzOptions.php:2522
1327
  msgid "Enable drop animation for comment form and subscription bar"
1328
  msgstr ""
1329
 
1330
+ #: options/class.WpdiscuzOptions.php:2529
1331
  msgid "Load Rich Editor"
1332
  msgstr ""
1333
 
1334
+ #: options/class.WpdiscuzOptions.php:2531
1335
  msgid "Search engines rank web pages for mobile devices totally different. For the mobile devices, there are more restrictions for JS and CSS files loading. This is the main reason why wpDiscuz disables the Rich Editor for mobile devices by default. It's only enabled for desktop. If you have good cache and website optimizer plugins you can enable the rich editor for mobile devices as well."
1336
  msgstr ""
1337
 
1338
+ #: options/class.WpdiscuzOptions.php:2536
1339
  msgid "Rich Editor Toolbar Buttons"
1340
  msgstr ""
1341
 
1342
+ #: options/class.WpdiscuzOptions.php:2538
1343
  msgid "Please click on buttons to disable or enable. The enabled buttons are colored green, the disabled buttons are gray. If you want to disable the whole formatting toolbar, please click on the [Disable formatting buttons] button. Options to manage Image Attachment button are located in 'Comment Content and Media' setting page."
1344
  msgstr ""
1345
 
1346
+ #: options/class.WpdiscuzOptions.php:2545 forms/wpdFormAttr/Field/Field.php:63
1347
  msgid "Google reCAPTCHA"
1348
  msgstr ""
1349
 
1350
+ #: options/class.WpdiscuzOptions.php:2553
1351
  msgid "Site Key"
1352
  msgstr ""
1353
 
1354
+ #: options/class.WpdiscuzOptions.php:2560 options/options-layouts/html-social.php:696
1355
  msgid "Secret Key"
1356
  msgstr ""
1357
 
1358
+ #: options/class.WpdiscuzOptions.php:2567
1359
  msgid "reCAPTCHA Theme"
1360
  msgstr ""
1361
 
1362
+ #: options/class.WpdiscuzOptions.php:2574
1363
  msgid "reCAPTCHA Language"
1364
  msgstr ""
1365
 
1366
+ #: options/class.WpdiscuzOptions.php:2581
1367
  msgid "Request Method"
1368
  msgstr ""
1369
 
1370
+ #: options/class.WpdiscuzOptions.php:2588
1371
  msgid "Enable for Guests"
1372
  msgstr ""
1373
 
1374
+ #: options/class.WpdiscuzOptions.php:2595
1375
  msgid "Enable for Logged-in Users"
1376
  msgstr ""
1377
 
1378
+ #: options/class.WpdiscuzOptions.php:2602
1379
  msgid "Display on Subscription Form"
1380
  msgstr ""
1381
 
1382
+ #: options/class.WpdiscuzOptions.php:2612
1383
  msgid "User Authorization and Profile Data"
1384
  msgstr ""
1385
 
1386
+ #: options/class.WpdiscuzOptions.php:2620
1387
  msgid "Display logged-in user name and logout link on comment form"
1388
  msgstr ""
1389
 
1390
+ #: options/class.WpdiscuzOptions.php:2627
1391
  msgid "Show \"Login\" link on comment form"
1392
  msgstr ""
1393
 
1394
+ #: options/class.WpdiscuzOptions.php:2634
1395
  msgid "\"My Content and Settings\" button"
1396
  msgstr ""
1397
 
1398
+ #: options/class.WpdiscuzOptions.php:2636
1399
  msgid "The \"My Content & Settings\" button is located in comment filter panel on top of all comments, right after the [X Comments] phrase. This button opens a pop-up window allowing commenters manage their content and settings."
1400
  msgstr ""
1401
 
1402
+ #: options/class.WpdiscuzOptions.php:2641
1403
  msgid "Enable Profiles URL"
1404
  msgstr ""
1405
 
1406
+ #: options/class.WpdiscuzOptions.php:2643
1407
  #, php-format
1408
  msgid "By default wpDiscuz adds a link with comment author avatar to the author profile page, you can disable this link using this option. However in case you use some plugin with User Profile page, you should keep this option enabled. wpDiscuz is well integrated with %s, BuddyPress and Ultimate Member profile builder plugins."
1409
  msgstr ""
1410
 
1411
+ #: options/class.WpdiscuzOptions.php:2648
1412
  msgid "Use Website URL as Profile URL"
1413
  msgstr ""
1414
 
1415
+ #: options/class.WpdiscuzOptions.php:2655
1416
  msgid "Use guest email to detect registered account"
1417
  msgstr ""
1418
 
1419
+ #: options/class.WpdiscuzOptions.php:2657
1420
  msgid "Sometimes registered users comment as guest using the same email address. wpDiscuz can detect the account role using guest email and display commenter label correctly."
1421
  msgstr ""
1422
 
1423
+ #: options/class.WpdiscuzOptions.php:2664
1424
  msgid "Social Login and Share"
1425
  msgstr ""
1426
 
1427
+ #: options/class.WpdiscuzOptions.php:2672
1428
  msgid "User agreement prior to a social login action"
1429
  msgstr ""
1430
 
1431
+ #: options/class.WpdiscuzOptions.php:2674
1432
  msgid "If this option is enabled, all Social Login buttons become not-clickable until user accept automatic account creation process based on his/her Social Network Account shared information (email, name). This checkbox and appropriate information will be displayed when user click on a social login button, prior to the login process. This extra step is added to comply with the GDPR"
1433
  msgstr ""
1434
 
1435
+ #: options/class.WpdiscuzOptions.php:2674
1436
  msgid "The note text and the label of this checkbox can be managed in Comments > Phrases > Social Login tab."
1437
  msgstr ""
1438
 
1439
+ #: options/class.WpdiscuzOptions.php:2679
1440
  msgid "Display social login buttons on reply forms"
1441
  msgstr ""
1442
 
1443
+ #: options/class.WpdiscuzOptions.php:2686
1444
  msgid "Display Social Network Icon on User Avatars"
1445
  msgstr ""
1446
 
1447
+ #: options/class.WpdiscuzOptions.php:2693
1448
  msgid "Facebook Login Button"
1449
  msgstr ""
1450
 
1451
+ #: options/class.WpdiscuzOptions.php:2700
1452
  msgid "Use Facebook OAuth2"
1453
  msgstr ""
1454
 
1455
+ #: options/class.WpdiscuzOptions.php:2702
1456
  msgid "If you enable this option, please make sure you've inserted the Valid OAuth Redirect URI in according field when you create Facebook Login App. Your website OAuth Redirect URI is displayed above."
1457
  msgstr ""
1458
 
1459
+ #: options/class.WpdiscuzOptions.php:2707
1460
  msgid "Facebook Share Button"
1461
  msgstr ""
1462
 
1463
+ #: options/class.WpdiscuzOptions.php:2714
1464
  msgid "Facebook Application ID"
1465
  msgstr ""
1466
 
1467
+ #: options/class.WpdiscuzOptions.php:2721
1468
  msgid "Facebook Application Secret"
1469
  msgstr ""
1470
 
1471
+ #: options/class.WpdiscuzOptions.php:2728
1472
  msgid "Twitter Login Button"
1473
  msgstr ""
1474
 
1475
+ #: options/class.WpdiscuzOptions.php:2735
1476
  msgid "Twitter Share Button"
1477
  msgstr ""
1478
 
1479
+ #: options/class.WpdiscuzOptions.php:2742
1480
  msgid "Twitter - Consumer Key (API Key)"
1481
  msgstr ""
1482
 
1483
+ #: options/class.WpdiscuzOptions.php:2749
1484
  msgid "Twitter - Consumer Secret (API Secret)"
1485
  msgstr ""
1486
 
1487
+ #: options/class.WpdiscuzOptions.php:2756
1488
  msgid "Google Login Button"
1489
  msgstr ""
1490
 
1491
+ #: options/class.WpdiscuzOptions.php:2763
1492
  msgid "Google Client ID"
1493
  msgstr ""
1494
 
1495
+ #: options/class.WpdiscuzOptions.php:2770
1496
  msgid "Google Client Secret"
1497
  msgstr ""
1498
 
1499
+ #: options/class.WpdiscuzOptions.php:2777
1500
  msgid "Disqus Login Button"
1501
  msgstr ""
1502
 
1503
+ #: options/class.WpdiscuzOptions.php:2784
1504
  msgid "Disqus Public Key"
1505
  msgstr ""
1506
 
1507
+ #: options/class.WpdiscuzOptions.php:2791
1508
  msgid "Disqus Secret Key"
1509
  msgstr ""
1510
 
1511
+ #: options/class.WpdiscuzOptions.php:2798
1512
  msgid "WordPress Login Button"
1513
  msgstr ""
1514
 
1515
+ #: options/class.WpdiscuzOptions.php:2805
1516
  msgid "WordPress Client ID"
1517
  msgstr ""
1518
 
1519
+ #: options/class.WpdiscuzOptions.php:2812
1520
  msgid "WordPress Client Secret"
1521
  msgstr ""
1522
 
1523
+ #: options/class.WpdiscuzOptions.php:2819
1524
  msgid "Instagram Login Button"
1525
  msgstr ""
1526
 
1527
+ #: options/class.WpdiscuzOptions.php:2826
1528
  msgid "Instagram App ID"
1529
  msgstr ""
1530
 
1531
+ #: options/class.WpdiscuzOptions.php:2833
1532
  msgid "Instagram App Secret"
1533
  msgstr ""
1534
 
1535
+ #: options/class.WpdiscuzOptions.php:2840
1536
  msgid "LinkedIn Login Button"
1537
  msgstr ""
1538
 
1539
+ #: options/class.WpdiscuzOptions.php:2847
1540
  msgid "LinkedIn Client ID"
1541
  msgstr ""
1542
 
1543
+ #: options/class.WpdiscuzOptions.php:2854
1544
  msgid "LinkedIn Client Secret"
1545
  msgstr ""
1546
 
1547
+ #: options/class.WpdiscuzOptions.php:2861
1548
  msgid "WhatsApp Share Button"
1549
  msgstr ""
1550
 
1551
+ #: options/class.WpdiscuzOptions.php:2868
1552
  msgid "Yandex Login Button"
1553
  msgstr ""
1554
 
1555
+ #: options/class.WpdiscuzOptions.php:2875
1556
  msgid "Yandex ID"
1557
  msgstr ""
1558
 
1559
+ #: options/class.WpdiscuzOptions.php:2882
1560
  msgid "Yandex Password"
1561
  msgstr ""
1562
 
1563
+ #: options/class.WpdiscuzOptions.php:2889
1564
  msgid "Mail.ru Login Button"
1565
  msgstr ""
1566
 
1567
+ #: options/class.WpdiscuzOptions.php:2896
1568
  msgid "Mail.ru Client ID"
1569
  msgstr ""
1570
 
1571
+ #: options/class.WpdiscuzOptions.php:2903
1572
  msgid "Mail.ru Client Secret"
1573
  msgstr ""
1574
 
1575
+ #: options/class.WpdiscuzOptions.php:2910
1576
  msgid "Weibo Login Button"
1577
  msgstr ""
1578
 
1579
+ #: options/class.WpdiscuzOptions.php:2917
1580
  msgid "Weibo App Key"
1581
  msgstr ""
1582
 
1583
+ #: options/class.WpdiscuzOptions.php:2924
1584
  msgid "Weibo App Secret"
1585
  msgstr ""
1586
 
1587
+ #: options/class.WpdiscuzOptions.php:2931
1588
  msgid "WeChat Login Button"
1589
  msgstr ""
1590
 
1591
+ #: options/class.WpdiscuzOptions.php:2938
1592
  msgid "WeChat App ID"
1593
  msgstr ""
1594
 
1595
+ #: options/class.WpdiscuzOptions.php:2945
1596
  msgid "WeChat Secret"
1597
  msgstr ""
1598
 
1599
+ #: options/class.WpdiscuzOptions.php:2952
1600
  msgid "QQ Login Button"
1601
  msgstr ""
1602
 
1603
+ #: options/class.WpdiscuzOptions.php:2959
1604
  msgid "QQ AppID"
1605
  msgstr ""
1606
 
1607
+ #: options/class.WpdiscuzOptions.php:2966
1608
  msgid "QQ AppKey"
1609
  msgstr ""
1610
 
1611
+ #: options/class.WpdiscuzOptions.php:2973
1612
  msgid "Baidu Login Button"
1613
  msgstr ""
1614
 
1615
+ #: options/class.WpdiscuzOptions.php:2980
1616
  msgid "Baidu Client ID"
1617
  msgstr ""
1618
 
1619
+ #: options/class.WpdiscuzOptions.php:2987
1620
  msgid "Baidu Client Secret"
1621
  msgstr ""
1622
 
1623
+ #: options/class.WpdiscuzOptions.php:2994
1624
  msgid "VK Login Button"
1625
  msgstr ""
1626
 
1627
+ #: options/class.WpdiscuzOptions.php:3001
1628
  msgid "VK Share Button"
1629
  msgstr ""
1630
 
1631
+ #: options/class.WpdiscuzOptions.php:3008
1632
  msgid "VK Application ID"
1633
  msgstr ""
1634
 
1635
+ #: options/class.WpdiscuzOptions.php:3015
1636
  msgid "VK Secure Key"
1637
  msgstr ""
1638
 
1639
+ #: options/class.WpdiscuzOptions.php:3022
1640
  msgid "OK Login Button"
1641
  msgstr ""
1642
 
1643
+ #: options/class.WpdiscuzOptions.php:3029
1644
  msgid "OK Share Button"
1645
  msgstr ""
1646
 
1647
+ #: options/class.WpdiscuzOptions.php:3036
1648
  msgid "OK Application ID"
1649
  msgstr ""
1650
 
1651
+ #: options/class.WpdiscuzOptions.php:3043
1652
  msgid "OK Application Key"
1653
  msgstr ""
1654
 
1655
+ #: options/class.WpdiscuzOptions.php:3050
1656
  msgid "OK Application Secret"
1657
  msgstr ""
1658
 
1659
+ #: options/class.WpdiscuzOptions.php:3059
1660
  msgid "Article and Comment Rating"
1661
  msgstr ""
1662
 
1663
+ #: options/class.WpdiscuzOptions.php:3067
1664
  msgid "Enable Aggregate Rating Schema"
1665
  msgstr ""
1666
 
1667
+ #: options/class.WpdiscuzOptions.php:3069
1668
  msgid "Aggregate rating schema is a code integrated with post rating HTML. This enables Google to feature your post ratings and attract customers with it. When searching the internet, people will see your posts search results with star ratings. Even though those results are not at the top of search engine results page, those sites caught people attention first."
1669
  msgstr ""
1670
 
1671
+ #: options/class.WpdiscuzOptions.php:3074
1672
  msgid "Display Ratings"
1673
  msgstr ""
1674
 
1675
+ #: options/class.WpdiscuzOptions.php:3081
1676
  msgid "Rating Star Colors"
1677
  msgstr ""
1678
 
1679
+ #: options/class.WpdiscuzOptions.php:3090
1680
  msgid "Comment Thread Displaying"
1681
  msgstr ""
1682
 
1683
+ #: options/class.WpdiscuzOptions.php:3098
1684
  msgid "Comment List Loading Type"
1685
  msgstr ""
1686
 
1687
+ #: options/class.WpdiscuzOptions.php:3100
1688
  msgid "Keep your page loading speed high by disabling comments loading. Once the page loading is complete, this option will initiate AJAX request and load comments without affecting page loading speed. Also, you can select the [View Comments] button option to allow visitors load comments manually whenever they want."
1689
  msgstr ""
1690
 
1691
+ #: options/class.WpdiscuzOptions.php:3105
1692
  msgid "Display only parent comments and <u>view replies &or;</u> button"
1693
  msgstr ""
1694
 
1695
+ #: options/class.WpdiscuzOptions.php:3107
1696
  msgid "If this option is enabled only parent comments will be displayed. This increases page load speed and keeps pages light. If visitor wants to read replies he/she just need to click on [view replies (12)] button located on all parent comments which have replies."
1697
  msgstr ""
1698
 
1699
+ #: options/class.WpdiscuzOptions.php:3112
1700
  msgid "Display \"Most Reacted Comments\" filter button"
1701
  msgstr ""
1702
 
1703
+ #: options/class.WpdiscuzOptions.php:3119
1704
  msgid "Display \"Hottest Comment Threads\" filter button"
1705
  msgstr ""
1706
 
1707
+ #: options/class.WpdiscuzOptions.php:3126
1708
  msgid "Display Comment Sorting Options"
1709
  msgstr ""
1710
 
1711
+ #: options/class.WpdiscuzOptions.php:3128
1712
  msgid "This option enables comment sorting buttons (newest | oldest | most voted). Sorting buttons are not available for the default comments pagination type [1][2][3]... It's only active for [Load more] and other AJAX pagination types."
1713
  msgstr ""
1714
 
1715
+ #: options/class.WpdiscuzOptions.php:3133
1716
  msgid "Set comments order to \"Most voted\" by default"
1717
  msgstr ""
1718
 
1719
+ #: options/class.WpdiscuzOptions.php:3140
1720
  msgid "Reverse Child Comments Order"
1721
  msgstr ""
1722
 
1723
+ #: options/class.WpdiscuzOptions.php:3142
1724
  msgid "By default child comments are sorted by oldest on top. Using this option you can revers child comments order and sort them by newest on top."
1725
  msgstr ""
1726
 
1727
+ #: options/class.WpdiscuzOptions.php:3147
1728
  msgid "Comments Pagination Type"
1729
  msgstr ""
1730
 
1731
+ #: options/class.WpdiscuzOptions.php:3149
1732
  msgid "You can manage the number of comments for [Load more] option in Settings > Discussion page, using \"Break comments into pages with [X] top level comments per page\" option. To show the default Wordpress comment pagination you should enable the checkbox on beginning of the same option."
1733
  msgstr ""
1734
 
1735
+ #: options/class.WpdiscuzOptions.php:3154
1736
  msgid "Highlight Unread Comments"
1737
  msgstr ""
1738
 
1739
+ #: options/class.WpdiscuzOptions.php:3163
1740
  msgid "Comment Thread Features"
1741
  msgstr ""
1742
 
1743
+ #: options/class.WpdiscuzOptions.php:3171
1744
  msgid "Show Comment Link"
1745
  msgstr ""
1746
 
1747
+ #: options/class.WpdiscuzOptions.php:3178
1748
  msgid "Show Comment Date"
1749
  msgstr ""
1750
 
1751
+ #: options/class.WpdiscuzOptions.php:3185
1752
  msgid "Show Voting Buttons"
1753
  msgstr ""
1754
 
1755
+ #: options/class.WpdiscuzOptions.php:3192
1756
  msgid "Voting Buttons Icon"
1757
  msgstr ""
1758
 
1759
+ #: options/class.WpdiscuzOptions.php:3199
1760
  msgid "Comment Voting Result Mode"
1761
  msgstr ""
1762
 
1763
+ #: options/class.WpdiscuzOptions.php:3206
1764
  msgid "Enable down vote button (dislike)"
1765
  msgstr ""
1766
 
1767
+ #: options/class.WpdiscuzOptions.php:3213
1768
  msgid "Allow Guests to Vote for Comments"
1769
  msgstr ""
1770
 
1771
+ #: options/class.WpdiscuzOptions.php:3220
1772
  msgid "Highlight Voting Buttons for Voters"
1773
  msgstr ""
1774
 
1775
+ #: options/class.WpdiscuzOptions.php:3222
1776
  msgid "This allows users to see own voted comments."
1777
  msgstr ""
1778
 
1779
+ #: options/class.WpdiscuzOptions.php:3227
1780
  msgid "Display Avatars"
1781
  msgstr ""
1782
 
1783
+ #: options/class.WpdiscuzOptions.php:3229
1784
  msgid "This option only related to avatars in comment system. For sitewide avatar control, please use WordPress native avatar settings in Dashboard > Settings > Discussions admin page."
1785
  msgstr ""
1786
 
1787
+ #: options/class.WpdiscuzOptions.php:3234
1788
  msgid "Default Avatar Source URL for Users"
1789
  msgstr ""
1790
 
1791
+ #: options/class.WpdiscuzOptions.php:3241
1792
  msgid "Default Avatar Source URL for Guests"
1793
  msgstr ""
1794
 
1795
+ #: options/class.WpdiscuzOptions.php:3248
1796
  msgid "Enable Sitewide Usage of Default Avatars"
1797
  msgstr ""
1798
 
1799
+ #: options/class.WpdiscuzOptions.php:3257
1800
  msgid "Styles and Colors"
1801
  msgstr ""
1802
 
1803
+ #: options/class.WpdiscuzOptions.php:3265
1804
  msgid "Comment Form and Comment List Style"
1805
  msgstr ""
1806
 
1807
+ #: options/class.WpdiscuzOptions.php:3267
1808
  msgid "Starting from wpDiscuz 7 you can choose the Minimal option of comment style. It'll remove most of wpDiscuz CSS code and allow you write your own CSS for custom comment styling."
1809
  msgstr ""
1810
 
1811
+ #: options/class.WpdiscuzOptions.php:3272
1812
  msgid "Colors"
1813
  msgstr ""
1814
 
1815
+ #: options/class.WpdiscuzOptions.php:3279
1816
  msgid "Comment Text Size"
1817
  msgstr ""
1818
 
1819
+ #: options/class.WpdiscuzOptions.php:3286
1820
  msgid "Load Font Awesome css lib"
1821
  msgstr ""
1822
 
1823
+ #: options/class.WpdiscuzOptions.php:3288
1824
  msgid "IMPORTANT: In case your theme uses old versions of Font-Awesome lib, you should not disable this this option. The theme old version doesn't support new version icons, thus some wpDiscuz icons might be lost."
1825
  msgstr ""
1826
 
1827
+ #: options/class.WpdiscuzOptions.php:3293
1828
  msgid "Custom CSS Code"
1829
  msgstr ""
1830
 
1831
+ #: options/class.WpdiscuzOptions.php:3302
1832
  msgid "Subscription and User Following"
1833
  msgstr ""
1834
 
1835
+ #: options/class.WpdiscuzOptions.php:3310
1836
  msgid "Enable User Mentioning"
1837
  msgstr ""
1838
 
1839
+ #: options/class.WpdiscuzOptions.php:3312
1840
  #, php-format
1841
  msgid "This option allows mentioning users in comments using @nickname method. Mentioned users will get notification via email if the next option is enabled. To get an advanced user mentioning features and to be able mention comments by #CommentID, we recommend the %s addon."
1842
  msgstr ""
1843
 
1844
+ #: options/class.WpdiscuzOptions.php:3317
1845
  msgid "Send E-Mail Notification to Mentioned Users"
1846
  msgstr ""
1847
 
1848
+ #: options/class.WpdiscuzOptions.php:3324
1849
  msgid "Notify comment author once comment is approved"
1850
  msgstr ""
1851
 
1852
+ #: options/class.WpdiscuzOptions.php:3331
1853
  msgid "Enable subscription confirmation for registered users"
1854
  msgstr ""
1855
 
1856
+ #: options/class.WpdiscuzOptions.php:3338
1857
  msgid "Enable subscription confirmation for guests"
1858
  msgstr ""
1859
 
1860
+ #: options/class.WpdiscuzOptions.php:3345
1861
  msgid "Subscription types in Subscription Bar drop-down"
1862
  msgstr ""
1863
 
1864
+ #: options/class.WpdiscuzOptions.php:3352
1865
  msgid "Display \"Notify of new replies to this comment\" option in comment form"
1866
  msgstr ""
1867
 
1868
+ #: options/class.WpdiscuzOptions.php:3354
1869
  msgid "wpDiscuz is the only comment plugin which allows you to subscribe to certain comment replies. This option is located above [Post Comment] button in comment form. You can disable this subscription way by unchecking this option."
1870
  msgstr ""
1871
 
1872
+ #: options/class.WpdiscuzOptions.php:3359
1873
  msgid "Keep checked the \"Notify of new replies to this comment\" option by default"
1874
  msgstr ""
1875
 
1876
+ #: options/class.WpdiscuzOptions.php:3366
1877
  msgid "Use Postmatic for subscriptions and commenting by email"
1878
  msgstr ""
1879
 
1880
+ #: options/class.WpdiscuzOptions.php:3368
1881
  msgid "Postmatic allows your users subscribe to comments. Instead of just being notified, they add a reply right from their inbox."
1882
  msgstr ""
1883
 
1884
+ #: options/class.WpdiscuzOptions.php:3373
1885
  msgid "Enable User Following Feature"
1886
  msgstr ""
1887
 
1888
+ #: options/class.WpdiscuzOptions.php:3380
1889
  msgid "Follow users without email confirmation"
1890
  msgstr ""
1891
 
1892
+ #: options/class.WpdiscuzOptions.php:3389
1893
  msgid "User Labels and Badges"
1894
  msgstr ""
1895
 
1896
+ #: options/class.WpdiscuzOptions.php:3397
1897
  msgid "Display Comment Author Labels"
1898
  msgstr ""
1899
 
1900
+ #: options/class.WpdiscuzOptions.php:3404
1901
  msgid "Comment Author Label Colors by User Role"
1902
  msgstr ""
1903
 
1904
+ #: options/class.WpdiscuzOptions.php:3413
1905
  msgid "Comment Moderation"
1906
  msgstr ""
1907
 
1908
+ #: options/class.WpdiscuzOptions.php:3421
1909
  msgid "Edit Button - Allow comment editing for"
1910
  msgstr ""
1911
 
1912
+ #: options/class.WpdiscuzOptions.php:3428
1913
  msgid "Enable editing for replied comments"
1914
  msgstr ""
1915
 
1916
+ #: options/class.WpdiscuzOptions.php:3435
1917
  msgid "Display comment editing Information"
1918
  msgstr ""
1919
 
1920
+ #: options/class.WpdiscuzOptions.php:3442
1921
  msgid "Stick Button - Stick a comment thread"
1922
  msgstr ""
1923
 
1924
+ #: options/class.WpdiscuzOptions.php:3449
1925
  msgid "Close Button - Close a comment thread"
1926
  msgstr ""
1927
 
1928
+ #: options/class.WpdiscuzOptions.php:3456
1929
  msgid "Limit Comments per User"
1930
  msgstr ""
1931
 
1932
+ #: options/class.WpdiscuzOptions.php:3458
1933
  msgid "This option allows control commenting activity per user. You can set maximum number of comments users can leave per post or sitewide. It also allow to set restriction for comments or for replies only."
1934
  msgstr ""
1935
 
1936
+ #: options/class.WpdiscuzOptions.php:3465
1937
  msgid "Comment Content and Media"
1938
  msgstr ""
1939
 
1940
+ #: options/class.WpdiscuzOptions.php:3473
1941
  msgid "Comment Text Length"
1942
  msgstr ""
1943
 
1944
+ #: options/class.WpdiscuzOptions.php:3475
1945
  msgid "Allows to set minimum and maximum number of chars can be inserted in comment textarea. Leave the max value empty to remove the limit."
1946
  msgstr ""
1947
 
1948
+ #: options/class.WpdiscuzOptions.php:3480
1949
  msgid "Image Source URL to Image Conversion"
1950
  msgstr ""
1951
 
1952
+ #: options/class.WpdiscuzOptions.php:3487
1953
+ msgid "Enable WordPress Shortcodes in Comment Content"
1954
+ msgstr ""
1955
+
1956
+ #: options/class.WpdiscuzOptions.php:3489
1957
+ msgid "This option allows embedding other plugins shortcodes in comment content. Some plugin shortcodes work very slow, so this may affect your page load speed if the shortcode provider plugin is not well optimized."
1958
+ msgstr ""
1959
+
1960
+ #: options/class.WpdiscuzOptions.php:3494
1961
  msgid "The number of words before breaking comment text (Read more)"
1962
  msgstr ""
1963
 
1964
+ #: options/class.WpdiscuzOptions.php:3496
1965
  msgid "Set this option value 0, to turn off comment text breaking function."
1966
  msgstr ""
1967
 
1968
+ #: options/class.WpdiscuzOptions.php:3501
1969
  msgid "Enable Media Uploading"
1970
  msgstr ""
1971
 
1972
+ #: options/class.WpdiscuzOptions.php:3503
1973
  msgid "This option allows commenters to attach an image with comments."
1974
  msgstr ""
1975
 
1976
+ #: options/class.WpdiscuzOptions.php:3508
1977
  msgid "Allow Media Uploading for Guests"
1978
  msgstr ""
1979
 
1980
+ #: options/class.WpdiscuzOptions.php:3515
1981
  msgid "Enable Lightbox for Attached Images"
1982
  msgstr ""
1983
 
1984
+ #: options/class.WpdiscuzOptions.php:3522
1985
  msgid "Allowed File Types"
1986
  msgstr ""
1987
 
1988
+ #: options/class.WpdiscuzOptions.php:3529
1989
  msgid "Max Uploaded Size"
1990
  msgstr ""
1991
 
1992
+ #: options/class.WpdiscuzOptions.php:3531
1993
  msgid "You can not set this value more than 'upload_max_filesize' and 'post_max_size'. If you want to increase server parameters please contact to your hosting service support."
1994
  msgstr ""
1995
 
1996
+ #: options/class.WpdiscuzOptions.php:3536
1997
  msgid "Show Comments Media in Dashboard"
1998
  msgstr ""
1999
 
2000
+ #: options/class.WpdiscuzOptions.php:3543
2001
  msgid "Single Image Sizes in Comments"
2002
  msgstr ""
2003
 
2004
+ #: options/class.WpdiscuzOptions.php:3550
2005
  msgid "Generate Thumbnail Sizes"
2006
  msgstr ""
2007
 
2008
+ #: options/class.WpdiscuzOptions.php:3552
2009
  msgid "Once image is uploaded, it'll generate thumbnails according to your selected sizes. When you set up a new WordPress website, the platform gives you three image sizes to play with: thumbnail, medium, and large (plus the file's original resolution). You may have other options and sizes which are registered by current active theme and by other plugins."
2010
  msgstr ""
2011
 
2012
+ #: options/class.WpdiscuzOptions.php:3559
2013
  msgid "Live Commenting and Notifications"
2014
  msgstr ""
2015
 
2016
+ #: options/class.WpdiscuzOptions.php:3567 options/html-options.php:254 options/html-options.php:263
2017
  msgid "Comment Bubble"
2018
  msgstr ""
2019
 
2020
+ #: options/class.WpdiscuzOptions.php:3569
2021
  msgid "Comment Bubble is a real-time updating sticky comment icon on your web pages. It invites people to comment, displays current comments information and notifies current page viewers about new comments."
2022
  msgstr ""
2023
 
2024
+ #: options/class.WpdiscuzOptions.php:3574
2025
  msgid "Comment Bubble Live Update"
2026
  msgstr ""
2027
 
2028
+ #: options/class.WpdiscuzOptions.php:3581 options/html-options.php:289
2029
  msgid "Comment Bubble Location"
2030
  msgstr ""
2031
 
2032
+ #: options/class.WpdiscuzOptions.php:3588
2033
  msgid "Bubble - Notify on New Comments"
2034
  msgstr ""
2035
 
2036
+ #: options/class.WpdiscuzOptions.php:3590
2037
  msgid "If the Bubble live update is enabled, it shows new comments excerpts as a pop-up information to article reads in real-time. This keeps website visitors up to date and engages them join to the discussion."
2038
  msgstr ""
2039
 
2040
+ #: options/class.WpdiscuzOptions.php:3595
2041
  msgid "Bubble - Invite to comment in X seconds"
2042
  msgstr ""
2043
 
2044
+ #: options/class.WpdiscuzOptions.php:3597
2045
  msgid "In most cases article readers don't even think about leaving some comment. Using this option you can enable Bubble &laquo;Invite to Comment&raquo; message. Once page is loaded and visitor has read some content, it reminds about comments and calls to leave a reply."
2046
  msgstr ""
2047
 
2048
+ #: options/class.WpdiscuzOptions.php:3602
2049
  msgid "Bubble - Hide the invitation message in X seconds"
2050
  msgstr ""
2051
 
2052
+ #: options/class.WpdiscuzOptions.php:3609
2053
  msgid "Live Update"
2054
  msgstr ""
2055
 
2056
+ #: options/class.WpdiscuzOptions.php:3611
2057
  msgid "wpDiscuz live update is very light and doesn't overload your server. However we recommend to monitor your server resources if you're on a Shared hosting plan. There are some very weak hosting plans which may not be able to perform very frequently live update requests. If you found some issue you can set the option below 30 seconds or more."
2058
  msgstr ""
2059
 
2060
+ #: options/class.WpdiscuzOptions.php:3616
2061
  msgid "Enable Live Update for Guests"
2062
  msgstr ""
2063
 
2064
+ #: options/class.WpdiscuzOptions.php:3623
2065
  msgid "Update Comment List Every"
2066
  msgstr ""
2067
 
2068
+ #: options/class.WpdiscuzOptions.php:3632
2069
  msgid "Inline Commenting"
2070
  msgstr ""
2071
 
2072
+ #: options/class.WpdiscuzOptions.php:3640
2073
  msgid "Display filter button to load inline feedbacks"
2074
  msgstr ""
2075
 
2076
+ #: options/class.WpdiscuzOptions.php:3642
2077
  msgid "This filter button appears next to all filter buttons and comment sorting options. It allows to filter and display article inline feedbacks (comments made while reading current article)."
2078
  msgstr ""
2079
 
2080
+ #: options/class.WpdiscuzOptions.php:3647
2081
  msgid "Animation for \"Leave a Feedback\" button in article content"
2082
  msgstr ""
2083
 
2084
+ #: options/class.WpdiscuzOptions.php:3649
2085
  msgid "Once a question is added in article editor (backend), readers will see a small comment icon (call to leave a feedback) next to the text part you've selected for your question on article (front-end). This icon calls people to leave a feedback, using the type you've selected in this option. For example, if you've chosen the \"Blink\" option, once reader scrolled and reached to the article text with question, it animates with comment button size and color changes attracting readers attention."
2086
  msgstr ""
2087
 
2088
+ #: options/class.WpdiscuzOptions.php:3656
2089
  msgid "General Settings"
2090
  msgstr ""
2091
 
2092
+ #: options/class.WpdiscuzOptions.php:3664
2093
  msgid "Enable wpDiscuz on Home Page"
2094
  msgstr ""
2095
 
2096
+ #: options/class.WpdiscuzOptions.php:3671
2097
  msgid "Use WordPress native AJAX functions"
2098
  msgstr ""
2099
 
2100
+ #: options/class.WpdiscuzOptions.php:3673
2101
  msgid "By disabling this option you're automatically enabling wpDiscuz custom AJAX functions, which are many times faster that the default WordPress functions. Just make sure it doesn't conflict with your plugins."
2102
  msgstr ""
2103
 
2104
+ #: options/class.WpdiscuzOptions.php:3678
2105
  msgid "Load Combo Version"
2106
  msgstr ""
2107
 
2108
+ #: options/class.WpdiscuzOptions.php:3685
2109
  msgid "Load Min Versions"
2110
  msgstr ""
2111
 
2112
+ #: options/class.WpdiscuzOptions.php:3692
2113
  msgid "Secure comment content in HTTPS protocol."
2114
  msgstr ""
2115
 
2116
+ #: options/class.WpdiscuzOptions.php:3694
2117
  msgid "This option detects images and other contents with non-https source URLs and fix according to your selected logic."
2118
  msgstr ""
2119
 
2120
+ #: options/class.WpdiscuzOptions.php:3699
2121
  msgid "Redirect First Comment to"
2122
  msgstr ""
2123
 
2124
+ #: options/class.WpdiscuzOptions.php:3706
2125
  msgid "Use WordPress Date/Time Format"
2126
  msgstr ""
2127
 
2128
+ #: options/class.WpdiscuzOptions.php:3708
2129
  msgid "wpDiscuz shows Human Readable date format. If you check this option it'll show the date/time format set in WordPress General Settings."
2130
  msgstr ""
2131
 
2132
+ #: options/class.WpdiscuzOptions.php:3713
2133
  msgid "Structure of Human Readable Date Format"
2134
  msgstr ""
2135
 
2136
+ #: options/class.WpdiscuzOptions.php:3715
2137
  msgid "By default, comment date is displayed with the human readable format, such as [X days ago]. For some languages, you may need to change the sequence of words in this date. This option provides shordcodes for each word allowing you manage the order. [number] is the 'X', [time_unit] is the 'days', [adjective] is the 'ago'."
2138
  msgstr ""
2139
 
2140
+ #: options/class.WpdiscuzOptions.php:3720
2141
  msgid "Use Plugin .PO/.MO Files"
2142
  msgstr ""
2143
 
2144
+ #: options/class.WpdiscuzOptions.php:3722
2145
  msgid "wpDiscuz phrase system allows you to translate all front-end phrases. However if you have a multi-language website it'll not allow you to add more than one language translation. The only way to get it is the plugin translation files (.PO / .MO). If wpDiscuz has the languages you need you should check this option to disable phrase system and it'll automatically translate all phrases based on language files according to current language."
2146
  msgstr ""
2147
 
2148
+ #: options/class.WpdiscuzOptions.php:3727
2149
  msgid "Help wpDiscuz to grow allowing people to recognize which comment plugin you use"
2150
  msgstr ""
2151
 
2152
+ #: options/class.WpdiscuzOptions.php:3729
2153
  msgid "Please check this option on to help wpDiscuz get more popularity as your thank to the hard work we do for you totally free. This option adds a very small (16x16px) icon under the comment section which will allow your site visitors recognize the name of comment solution you use."
2154
  msgstr ""
2155
 
2156
+ #: options/class.WpdiscuzOptions.php:3734
2157
  msgid "Enable Gravatar caching"
2158
  msgstr ""
2159
 
2160
+ #: options/class.WpdiscuzOptions.php:3741
2161
  msgid "Caching Method"
2162
  msgstr ""
2163
 
2164
+ #: options/class.WpdiscuzOptions.php:3748
2165
  msgid "Reset Avatar Cache Frequency"
2166
  msgstr ""
2167
 
2168
+ #: options/class.WpdiscuzOptions.php:3755
2169
  msgid "Remove Vote Data"
2170
  msgstr ""
2171
 
2172
+ #: options/class.WpdiscuzOptions.php:3762
2173
  msgid "Purge Expired Avatar Caches"
2174
  msgstr ""
2175
 
2176
+ #: options/class.WpdiscuzOptions.php:3769
2177
  msgid "Purge All Avatar Caches"
2178
  msgstr ""
2179
 
2807
  msgid "Fix Tables"
2808
  msgstr ""
2809
 
2810
+ #: utils/class.WpdiscuzHelper.php:365
2811
  msgid "Sticky"
2812
  msgstr ""
2813
 
2814
+ #: utils/class.WpdiscuzHelper.php:965
2815
  msgid "Reset Ratings"
2816
  msgstr ""
2817
 
2818
+ #: utils/class.WpdiscuzHelper.php:1005
2819
  msgid "Reset Post Rating"
2820
  msgstr ""
2821
 
2822
+ #: utils/class.WpdiscuzHelper.php:1006 utils/class.WpdiscuzHelper.php:1045
2823
  msgid "Working..."
2824
  msgstr ""
2825
 
2826
+ #: utils/class.WpdiscuzHelper.php:1007 utils/class.WpdiscuzHelper.php:1046
2827
  msgid "Done"
2828
  msgstr ""
2829
 
2830
+ #: utils/class.WpdiscuzHelper.php:1044
2831
  msgid "Reset Fields Ratings"
2832
  msgstr ""
2833
 
2834
+ #: utils/class.WpdiscuzHelper.php:1144
2835
  msgid "Enter link:"
2836
  msgstr ""
2837
 
2839
  msgid "Read More"
2840
  msgstr ""
2841
 
2842
+ #: utils/class.WpdiscuzHelperAjax.php:849
2843
  msgid "Subscribers"
2844
  msgstr ""
2845
 
2846
+ #: utils/class.WpdiscuzHelperAjax.php:850
2847
  msgid "Subscription - posts"
2848
  msgstr ""
2849
 
2850
+ #: utils/class.WpdiscuzHelperAjax.php:851
2851
  msgid "Subscription - all comments"
2852
  msgstr ""
2853
 
2854
+ #: utils/class.WpdiscuzHelperAjax.php:852
2855
  msgid "Subscription - comment"
2856
  msgstr ""
2857
 
2858
+ #: utils/class.WpdiscuzHelperAjax.php:853 utils/class.WpdiscuzHelperAjax.php:915
2859
  msgid "Followers"
2860
  msgstr ""
2861
 
2862
+ #: utils/class.WpdiscuzHelperAjax.php:854 utils/class.WpdiscuzHelperAjax.php:911
2863
  msgid "Following"
2864
  msgstr ""
2865
 
2866
+ #: utils/class.WpdiscuzHelperAjax.php:900 options/addons/cai/title.php:7
2867
  msgid "Comment Author"
2868
  msgstr ""
2869
 
2870
+ #: utils/class.WpdiscuzHelperAjax.php:919
2871
  msgid "Last Activity"
2872
  msgstr ""
2873
 
2875
  msgid "Unfollow"
2876
  msgstr ""
2877
 
2878
+ #: utils/class.WpdiscuzHelperUpload.php:459
2879
  msgid "The attachment not exists"
2880
  msgstr ""
2881
 
2882
+ #: utils/class.WpdiscuzHelperUpload.php:734
2883
  msgid "Attached Images"
2884
  msgstr ""
2885
 
2963
  msgid "Dismiss and never show again"
2964
  msgstr ""
2965
 
2966
+ #: forms/wpdFormAttr/Form.php:207 forms/wpdFormAttr/Form.php:614 forms/wpdFormAttr/Form.php:1053
2967
  msgid "I allow to use my email address and send notification about new comments and replies (you can unsubscribe at any time)."
2968
  msgstr ""
2969
 
2971
  msgid "Average Rating"
2972
  msgstr ""
2973
 
2974
+ #: forms/wpdFormAttr/Form.php:987 forms/wpdFormAttr/Form.php:1009 forms/wpdFormAttr/Form.php:1021 forms/wpdFormAttr/Form.php:1033 forms/wpdFormAttr/Form.php:1045 forms/wpdFormAttr/Form.php:1065 forms/wpdFormAttr/Form.php:1076 forms/wpdFormAttr/Form.php:1105 forms/wpdFormAttr/Form.php:1115 forms/wpdFormAttr/Form.php:1161 forms/wpdFormAttr/Form.php:1177 forms/wpdFormAttr/Form.php:1199 forms/wpdFormAttr/Form.php:1206 options/options-layouts/html-content.php:13 options/options-layouts/html-content.php:29 options/options-layouts/html-content.php:47 options/options-layouts/html-content.php:65 options/options-layouts/html-content.php:80 options/options-layouts/html-content.php:102 options/options-layouts/html-content.php:136 options/options-layouts/html-content.php:149 options/options-layouts/html-content.php:195 options/options-layouts/html-content.php:213 options/options-layouts/html-content.php:229 options/options-layouts/html-content.php:261 options/options-layouts/html-form.php:13 options/options-layouts/html-form.php:33 options/options-layouts/html-form.php:51 options/options-layouts/html-form.php:80 options/options-layouts/html-form.php:122 options/options-layouts/html-form.php:138 options/options-layouts/html-form.php:153 options/options-layouts/html-general.php:20 options/options-layouts/html-general.php:38 options/options-layouts/html-general.php:55 options/options-layouts/html-general.php:72 options/options-layouts/html-general.php:121 options/options-layouts/html-general.php:143 options/options-layouts/html-general.php:158 options/options-layouts/html-general.php:176 options/options-layouts/html-general.php:217 options/options-layouts/html-general.php:235 options/options-layouts/html-general.php:251 options/options-layouts/html-inline.php:21 options/options-layouts/html-inline.php:39 options/options-layouts/html-inline.php:69 options/options-layouts/html-labels.php:13 options/options-layouts/html-labels.php:39 options/options-layouts/html-labels.php:63 options/options-layouts/html-live.php:15 options/options-layouts/html-live.php:35 options/options-layouts/html-live.php:57 options/options-layouts/html-live.php:77 options/options-layouts/html-live.php:98 options/options-layouts/html-live.php:114 options/options-layouts/html-live.php:129 options/options-layouts/html-live.php:149 options/options-layouts/html-live.php:167 options/options-layouts/html-live.php:190 options/options-layouts/html-login.php:13 options/options-layouts/html-login.php:31 options/options-layouts/html-login.php:49 options/options-layouts/html-login.php:99 options/options-layouts/html-login.php:117 options/options-layouts/html-login.php:135 options/options-layouts/html-login.php:153 options/options-layouts/html-moderation.php:13 options/options-layouts/html-moderation.php:36 options/options-layouts/html-moderation.php:54 options/options-layouts/html-moderation.php:72 options/options-layouts/html-moderation.php:90 options/options-layouts/html-moderation.php:108 options/options-layouts/html-moderation.php:143 options/options-layouts/html-rating.php:13 options/options-layouts/html-rating.php:31 options/options-layouts/html-rating.php:61 options/options-layouts/html-recaptcha.php:14 options/options-layouts/html-recaptcha.php:38 options/options-layouts/html-recaptcha.php:56 options/options-layouts/html-recaptcha.php:74 options/options-layouts/html-recaptcha.php:92 options/options-layouts/html-recaptcha.php:111 options/options-layouts/html-recaptcha.php:126 options/options-layouts/html-recaptcha.php:144 options/options-layouts/html-recaptcha.php:160 options/options-layouts/html-social.php:13 options/options-layouts/html-social.php:31 options/options-layouts/html-social.php:49 options/options-layouts/html-social.php:67 options/options-layouts/html-social.php:140 options/options-layouts/html-social.php:155 options/options-layouts/html-social.php:212 options/options-layouts/html-social.php:227 options/options-layouts/html-social.php:267 options/options-layouts/html-social.php:282 options/options-layouts/html-social.php:323 options/options-layouts/html-social.php:338 options/options-layouts/html-social.php:378 options/options-layouts/html-social.php:393 options/options-layouts/html-social.php:431 options/options-layouts/html-social.php:446 options/options-layouts/html-social.php:485 options/options-layouts/html-social.php:500 options/options-layouts/html-social.php:559 options/options-layouts/html-social.php:574 options/options-layouts/html-social.php:630 options/options-layouts/html-social.php:645 options/options-layouts/html-social.php:684 options/options-layouts/html-social.php:699 options/options-layouts/html-social.php:756 options/options-layouts/html-social.php:771 options/options-layouts/html-social.php:786 options/options-layouts/html-social.php:824 options/options-layouts/html-social.php:839 options/options-layouts/html-social.php:878 options/options-layouts/html-social.php:893 options/options-layouts/html-social.php:932 options/options-layouts/html-social.php:947 options/options-layouts/html-social.php:986 options/options-layouts/html-social.php:1001 options/options-layouts/html-subscription.php:13 options/options-layouts/html-subscription.php:31 options/options-layouts/html-subscription.php:49 options/options-layouts/html-subscription.php:67 options/options-layouts/html-subscription.php:85 options/options-layouts/html-subscription.php:103 options/options-layouts/html-subscription.php:132 options/options-layouts/html-subscription.php:150 options/options-layouts/html-subscription.php:185 options/options-layouts/html-subscription.php:204 options/options-layouts/html-subscription.php:222 options/options-layouts/html-thread_display.php:13 options/options-layouts/html-thread_display.php:42 options/options-layouts/html-thread_display.php:78 options/options-layouts/html-thread_display.php:96 options/options-layouts/html-thread_display.php:114 options/options-layouts/html-thread_display.php:132 options/options-layouts/html-thread_display.php:150 options/options-layouts/html-thread_display.php:168 options/options-layouts/html-thread_display.php:186 options/options-layouts/html-thread_display.php:204 options/options-layouts/html-thread_layouts.php:32 options/options-layouts/html-thread_layouts.php:55 options/options-layouts/html-thread_layouts.php:70 options/options-layouts/html-thread_layouts.php:85 options/options-layouts/html-thread_layouts.php:103 options/options-layouts/html-thread_layouts.php:125 options/options-layouts/html-thread_layouts.php:149 options/options-layouts/html-thread_layouts.php:167 options/options-layouts/html-thread_layouts.php:185 options/options-layouts/html-thread_layouts.php:203 options/options-layouts/html-thread_layouts.php:221 options/options-layouts/html-thread_layouts.php:244 options/options-layouts/html-thread_styles.php:13 options/options-layouts/html-thread_styles.php:32 options/options-layouts/html-thread_styles.php:70 options/options-layouts/html-thread_styles.php:111 options/options-layouts/html-thread_styles.php:126
2975
  msgid "Read the documentation"
2976
  msgstr ""
2977
 
2978
+ #: forms/wpdFormAttr/Form.php:992
2979
  msgid "Disable commenting for roles"
2980
  msgstr ""
2981
 
2982
+ #: forms/wpdFormAttr/Form.php:1014
2983
  msgid "Allow guests to comment"
2984
  msgstr ""
2985
 
2986
+ #: forms/wpdFormAttr/Form.php:1018 forms/wpdFormAttr/Form.php:1030 forms/wpdFormAttr/Form.php:1042 forms/wpdFormAttr/Form.php:1174 forms/wpdFormAttr/Form.php:1196
2987
  msgid "Yes"
2988
  msgstr ""
2989
 
2990
+ #: forms/wpdFormAttr/Form.php:1020 forms/wpdFormAttr/Form.php:1032 forms/wpdFormAttr/Form.php:1044 forms/wpdFormAttr/Form.php:1176 forms/wpdFormAttr/Form.php:1198
2991
  msgid "No"
2992
  msgstr ""
2993
 
2994
+ #: forms/wpdFormAttr/Form.php:1026
2995
  msgid "Enable subscription bar"
2996
  msgstr ""
2997
 
2998
+ #: forms/wpdFormAttr/Form.php:1038
2999
  msgid "Display agreement checkbox in Comment Subscription bar"
3000
  msgstr ""
3001
 
3002
+ #: forms/wpdFormAttr/Form.php:1050
3003
  msgid "Comment Subscription bar agreement checkbox label"
3004
  msgstr ""
3005
 
3006
+ #: forms/wpdFormAttr/Form.php:1059
3007
  msgid "Comment form header text (singular)"
3008
  msgstr ""
3009
 
3010
+ #: forms/wpdFormAttr/Form.php:1070
3011
  msgid "Comment form header text (plural)"
3012
  msgstr ""
3013
 
3014
+ #: forms/wpdFormAttr/Form.php:1080
3015
  msgid "Display comment form for post types"
3016
  msgstr ""
3017
 
3018
+ #: forms/wpdFormAttr/Form.php:1087
3019
  msgid "The red marked post types are already attached to other comment form. If you set this form too, the old forms will not be used for them."
3020
  msgstr ""
3021
 
3022
+ #: forms/wpdFormAttr/Form.php:1110
3023
  msgid "Display comment form for post IDs"
3024
  msgstr ""
3025
 
3026
+ #: forms/wpdFormAttr/Form.php:1111
3027
  msgid "You can use this form for certain posts/pages specified by comma separated IDs."
3028
  msgstr ""
3029
 
3030
+ #: forms/wpdFormAttr/Form.php:1125
3031
  msgid "Theme"
3032
  msgstr ""
3033
 
3034
+ #: forms/wpdFormAttr/Form.php:1144
3035
  msgid "Comment List Layout"
3036
  msgstr ""
3037
 
3038
+ #: forms/wpdFormAttr/Form.php:1155
3039
  msgid "Layout"
3040
  msgstr ""
3041
 
3042
+ #: forms/wpdFormAttr/Form.php:1170
3043
  msgid "Enable Post Rating"
3044
  msgstr ""
3045
 
3046
+ #: forms/wpdFormAttr/Form.php:1182
3047
  msgid "Post Rating Title"
3048
  msgstr ""
3049
 
3050
+ #: forms/wpdFormAttr/Form.php:1192
3051
  msgid "Allow Guests to Rate"
3052
  msgstr ""
3053
 
3054
+ #: forms/wpdFormAttr/Form.php:1210
3055
  msgid "Comment Text Field"
3056
  msgstr ""
3057
 
3058
+ #: forms/wpdFormAttr/Form.php:1225
3059
  msgid "ADD ROW"
3060
  msgstr ""
3061
 
3062
+ #: forms/wpdFormAttr/Form.php:1291 forms/wpdFormAttr/Field/DefaultField/Website.php:84
3063
  msgid "Website"
3064
  msgstr ""
3065
 
3076
  msgid "Max"
3077
  msgstr ""
3078
 
3079
+ #: options/options-layouts/html-content.php:86
3080
  msgid "File Attachment Settings"
3081
  msgstr ""
3082
 
3083
+ #: options/options-layouts/html-content.php:167
3084
  msgid "Select All"
3085
  msgstr ""
3086
 
3087
+ #: options/options-layouts/html-content.php:168
3088
  msgid "Unselect All"
3089
  msgstr ""
3090
 
3091
+ #: options/options-layouts/html-content.php:169
3092
  msgid "Invert Selection"
3093
  msgstr ""
3094
 
3095
+ #: options/options-layouts/html-content.php:190
3096
  msgid "Server 'upload_max_filesize' is "
3097
  msgstr ""
3098
 
3099
+ #: options/options-layouts/html-content.php:191
3100
  msgid "Server 'post_max_size' is "
3101
  msgstr ""
3102
 
3103
+ #: options/options-layouts/html-content.php:225
3104
  msgid "Width (px)"
3105
  msgstr ""
3106
 
3107
+ #: options/options-layouts/html-content.php:226
3108
  msgid "Height (px)"
3109
  msgstr ""
3110
 
4284
  msgid "Don't show again if the agreement is accepted once"
4285
  msgstr ""
4286
 
4287
+ #: forms/wpdFormAttr/Field/AgreementCheckbox.php:101 forms/wpdFormAttr/Field/CheckboxField.php:150 forms/wpdFormAttr/Field/ColorField.php:113 forms/wpdFormAttr/Field/DateField.php:113 forms/wpdFormAttr/Field/NumberField.php:123 forms/wpdFormAttr/Field/RadioField.php:129 forms/wpdFormAttr/Field/RatingField.php:129 forms/wpdFormAttr/Field/SelectField.php:122 forms/wpdFormAttr/Field/TextAreaField.php:95 forms/wpdFormAttr/Field/TextField.php:107 forms/wpdFormAttr/Field/UrlField.php:117
4288
  msgid "field is required!"
4289
  msgstr ""
4290
 
options/class.WpdiscuzOptions.php CHANGED
@@ -257,6 +257,7 @@ class WpdiscuzOptions implements WpDiscuzConstants {
257
  $this->content["commentTextMinLength"] = isset($options[self::TAB_CONTENT]["commentTextMinLength"]) ? $options[self::TAB_CONTENT]["commentTextMinLength"] : $defaultOptions[self::TAB_CONTENT]["commentTextMinLength"];
258
  $this->content["commentTextMaxLength"] = isset($options[self::TAB_CONTENT]["commentTextMaxLength"]) ? $options[self::TAB_CONTENT]["commentTextMaxLength"] : $defaultOptions[self::TAB_CONTENT]["commentTextMaxLength"];
259
  $this->content["enableImageConversion"] = isset($options[self::TAB_CONTENT]["enableImageConversion"]) ? $options[self::TAB_CONTENT]["enableImageConversion"] : $defaultOptions[self::TAB_CONTENT]["enableImageConversion"];
 
260
  $this->content["commentReadMoreLimit"] = isset($options[self::TAB_CONTENT]["commentReadMoreLimit"]) ? $options[self::TAB_CONTENT]["commentReadMoreLimit"] : $defaultOptions[self::TAB_CONTENT]["commentReadMoreLimit"];
261
  $this->content["wmuIsEnabled"] = isset($options[self::TAB_CONTENT]["wmuIsEnabled"]) ? $options[self::TAB_CONTENT]["wmuIsEnabled"] : $defaultOptions[self::TAB_CONTENT]["wmuIsEnabled"];
262
  $this->content["wmuIsGuestAllowed"] = isset($options[self::TAB_CONTENT]["wmuIsGuestAllowed"]) ? $options[self::TAB_CONTENT]["wmuIsGuestAllowed"] : $defaultOptions[self::TAB_CONTENT]["wmuIsGuestAllowed"];
@@ -693,6 +694,7 @@ class WpdiscuzOptions implements WpDiscuzConstants {
693
  "commentTextMinLength" => $this->content["commentTextMinLength"],
694
  "commentTextMaxLength" => $this->content["commentTextMaxLength"],
695
  "enableImageConversion" => $this->content["enableImageConversion"],
 
696
  "commentReadMoreLimit" => $this->content["commentReadMoreLimit"],
697
  "wmuIsEnabled" => $this->content["wmuIsEnabled"],
698
  "wmuIsGuestAllowed" => $this->content["wmuIsGuestAllowed"],
@@ -920,6 +922,7 @@ class WpdiscuzOptions implements WpDiscuzConstants {
920
  "commentTextMinLength" => 1,
921
  "commentTextMaxLength" => "",
922
  "enableImageConversion" => 1,
 
923
  "commentReadMoreLimit" => 100,
924
  "wmuIsEnabled" => 1,
925
  "wmuIsGuestAllowed" => 1,
@@ -1158,7 +1161,7 @@ class WpdiscuzOptions implements WpDiscuzConstants {
1158
  }
1159
  check_admin_referer("wc_options_form-" . $_POST["wpd_tab"]);
1160
  if (self::TAB_FORM === $_POST["wpd_tab"]) {
1161
- $this->form["commentFormView"] = isset($_POST[self::TAB_FORM]["commentFormView"]) ? absint($_POST[self::TAB_FORM]["commentFormView"]) : "collapsed";
1162
  $this->form["enableDropAnimation"] = isset($_POST[self::TAB_FORM]["enableDropAnimation"]) ? absint($_POST[self::TAB_FORM]["enableDropAnimation"]) : 0;
1163
  $this->form["richEditor"] = isset($_POST[self::TAB_FORM]["richEditor"]) ? trim($_POST[self::TAB_FORM]["richEditor"]) : "desktop";
1164
  $this->form["boldButton"] = isset($_POST[self::TAB_FORM]["boldButton"]) ? intval($_POST[self::TAB_FORM]["boldButton"]) : 0;
@@ -1347,6 +1350,7 @@ class WpdiscuzOptions implements WpDiscuzConstants {
1347
  $this->content["commentTextMinLength"] = isset($_POST[self::TAB_CONTENT]["commentTextMinLength"]) && absint($_POST[self::TAB_CONTENT]["commentTextMinLength"]) > 0 ? absint($_POST[self::TAB_CONTENT]["commentTextMinLength"]) : 1;
1348
  $this->content["commentTextMaxLength"] = isset($_POST[self::TAB_CONTENT]["commentTextMaxLength"]) && absint($_POST[self::TAB_CONTENT]["commentTextMaxLength"]) > 0 ? absint($_POST[self::TAB_CONTENT]["commentTextMaxLength"]) : "";
1349
  $this->content["enableImageConversion"] = isset($_POST[self::TAB_CONTENT]["enableImageConversion"]) ? absint($_POST[self::TAB_CONTENT]["enableImageConversion"]) : 0;
 
1350
  $this->content["commentReadMoreLimit"] = isset($_POST[self::TAB_CONTENT]["commentReadMoreLimit"]) && absint($_POST[self::TAB_CONTENT]["commentReadMoreLimit"]) >= 0 ? absint($_POST[self::TAB_CONTENT]["commentReadMoreLimit"]) : 100;
1351
  $this->content["wmuIsEnabled"] = isset($_POST[self::TAB_CONTENT]["wmuIsEnabled"]) ? absint($_POST[self::TAB_CONTENT]["wmuIsEnabled"]) : 0;
1352
  $this->content["wmuIsGuestAllowed"] = isset($_POST[self::TAB_CONTENT]["wmuIsGuestAllowed"]) ? absint($_POST[self::TAB_CONTENT]["wmuIsGuestAllowed"]) : 0;
@@ -3479,6 +3483,13 @@ class WpdiscuzOptions implements WpDiscuzConstants {
3479
  "description_original" => "",
3480
  "docurl" => "https://wpdiscuz.com/docs/wpdiscuz-7/plugin-settings/comment-content-and-media/#image-source-url-to-image-conversion"
3481
  ],
 
 
 
 
 
 
 
3482
  "commentReadMoreLimit" => [
3483
  "label" => esc_html__("The number of words before breaking comment text (Read more)", "wpdiscuz"),
3484
  "label_original" => "The number of words before breaking comment text (Read more)",
257
  $this->content["commentTextMinLength"] = isset($options[self::TAB_CONTENT]["commentTextMinLength"]) ? $options[self::TAB_CONTENT]["commentTextMinLength"] : $defaultOptions[self::TAB_CONTENT]["commentTextMinLength"];
258
  $this->content["commentTextMaxLength"] = isset($options[self::TAB_CONTENT]["commentTextMaxLength"]) ? $options[self::TAB_CONTENT]["commentTextMaxLength"] : $defaultOptions[self::TAB_CONTENT]["commentTextMaxLength"];
259
  $this->content["enableImageConversion"] = isset($options[self::TAB_CONTENT]["enableImageConversion"]) ? $options[self::TAB_CONTENT]["enableImageConversion"] : $defaultOptions[self::TAB_CONTENT]["enableImageConversion"];
260
+ $this->content["enableShortcodes"] = isset($options[self::TAB_CONTENT]["enableShortcodes"]) ? $options[self::TAB_CONTENT]["enableShortcodes"] : $defaultOptions[self::TAB_CONTENT]["enableShortcodes"];
261
  $this->content["commentReadMoreLimit"] = isset($options[self::TAB_CONTENT]["commentReadMoreLimit"]) ? $options[self::TAB_CONTENT]["commentReadMoreLimit"] : $defaultOptions[self::TAB_CONTENT]["commentReadMoreLimit"];
262
  $this->content["wmuIsEnabled"] = isset($options[self::TAB_CONTENT]["wmuIsEnabled"]) ? $options[self::TAB_CONTENT]["wmuIsEnabled"] : $defaultOptions[self::TAB_CONTENT]["wmuIsEnabled"];
263
  $this->content["wmuIsGuestAllowed"] = isset($options[self::TAB_CONTENT]["wmuIsGuestAllowed"]) ? $options[self::TAB_CONTENT]["wmuIsGuestAllowed"] : $defaultOptions[self::TAB_CONTENT]["wmuIsGuestAllowed"];
694
  "commentTextMinLength" => $this->content["commentTextMinLength"],
695
  "commentTextMaxLength" => $this->content["commentTextMaxLength"],
696
  "enableImageConversion" => $this->content["enableImageConversion"],
697
+ "enableShortcodes" => $this->content["enableShortcodes"],
698
  "commentReadMoreLimit" => $this->content["commentReadMoreLimit"],
699
  "wmuIsEnabled" => $this->content["wmuIsEnabled"],
700
  "wmuIsGuestAllowed" => $this->content["wmuIsGuestAllowed"],
922
  "commentTextMinLength" => 1,
923
  "commentTextMaxLength" => "",
924
  "enableImageConversion" => 1,
925
+ "enableShortcodes" => 0,
926
  "commentReadMoreLimit" => 100,
927
  "wmuIsEnabled" => 1,
928
  "wmuIsGuestAllowed" => 1,
1161
  }
1162
  check_admin_referer("wc_options_form-" . $_POST["wpd_tab"]);
1163
  if (self::TAB_FORM === $_POST["wpd_tab"]) {
1164
+ $this->form["commentFormView"] = isset($_POST[self::TAB_FORM]["commentFormView"]) ? trim($_POST[self::TAB_FORM]["commentFormView"]) : "collapsed";
1165
  $this->form["enableDropAnimation"] = isset($_POST[self::TAB_FORM]["enableDropAnimation"]) ? absint($_POST[self::TAB_FORM]["enableDropAnimation"]) : 0;
1166
  $this->form["richEditor"] = isset($_POST[self::TAB_FORM]["richEditor"]) ? trim($_POST[self::TAB_FORM]["richEditor"]) : "desktop";
1167
  $this->form["boldButton"] = isset($_POST[self::TAB_FORM]["boldButton"]) ? intval($_POST[self::TAB_FORM]["boldButton"]) : 0;
1350
  $this->content["commentTextMinLength"] = isset($_POST[self::TAB_CONTENT]["commentTextMinLength"]) && absint($_POST[self::TAB_CONTENT]["commentTextMinLength"]) > 0 ? absint($_POST[self::TAB_CONTENT]["commentTextMinLength"]) : 1;
1351
  $this->content["commentTextMaxLength"] = isset($_POST[self::TAB_CONTENT]["commentTextMaxLength"]) && absint($_POST[self::TAB_CONTENT]["commentTextMaxLength"]) > 0 ? absint($_POST[self::TAB_CONTENT]["commentTextMaxLength"]) : "";
1352
  $this->content["enableImageConversion"] = isset($_POST[self::TAB_CONTENT]["enableImageConversion"]) ? absint($_POST[self::TAB_CONTENT]["enableImageConversion"]) : 0;
1353
+ $this->content["enableShortcodes"] = isset($_POST[self::TAB_CONTENT]["enableShortcodes"]) ? absint($_POST[self::TAB_CONTENT]["enableShortcodes"]) : 0;
1354
  $this->content["commentReadMoreLimit"] = isset($_POST[self::TAB_CONTENT]["commentReadMoreLimit"]) && absint($_POST[self::TAB_CONTENT]["commentReadMoreLimit"]) >= 0 ? absint($_POST[self::TAB_CONTENT]["commentReadMoreLimit"]) : 100;
1355
  $this->content["wmuIsEnabled"] = isset($_POST[self::TAB_CONTENT]["wmuIsEnabled"]) ? absint($_POST[self::TAB_CONTENT]["wmuIsEnabled"]) : 0;
1356
  $this->content["wmuIsGuestAllowed"] = isset($_POST[self::TAB_CONTENT]["wmuIsGuestAllowed"]) ? absint($_POST[self::TAB_CONTENT]["wmuIsGuestAllowed"]) : 0;
3483
  "description_original" => "",
3484
  "docurl" => "https://wpdiscuz.com/docs/wpdiscuz-7/plugin-settings/comment-content-and-media/#image-source-url-to-image-conversion"
3485
  ],
3486
+ "enableShortcodes" => [
3487
+ "label" => esc_html__("Enable WordPress Shortcodes in Comment Content", "wpdiscuz"),
3488
+ "label_original" => "Enable WordPress Shortcodes in Comment Content",
3489
+ "description" => esc_html__("This option allows embedding other plugins shortcodes in comment content. Some plugin shortcodes work very slow, so this may affect your page load speed if the shortcode provider plugin is not well optimized.", "wpdiscuz"),
3490
+ "description_original" => "This option allows embedding other plugins shortcodes in comment content. Some plugin shortcodes work very slow, so this may affect your page load speed if the shortcode provider plugin is not well optimized.",
3491
+ "docurl" => ""
3492
+ ],
3493
  "commentReadMoreLimit" => [
3494
  "label" => esc_html__("The number of words before breaking comment text (Read more)", "wpdiscuz"),
3495
  "label_original" => "The number of words before breaking comment text (Read more)",
options/options-layouts/html-content.php CHANGED
@@ -49,6 +49,24 @@ if (!defined("ABSPATH")) {
49
  </div>
50
  <!-- Option end -->
51
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
52
  <!-- Option start -->
53
  <div class="wpd-opt-row" data-wpd-opt="commentReadMoreLimit">
54
  <div class="wpd-opt-name">
49
  </div>
50
  <!-- Option end -->
51
 
52
+ <!-- Option start -->
53
+ <div class="wpd-opt-row" data-wpd-opt="enableShortcodes">
54
+ <div class="wpd-opt-name">
55
+ <label for="enableShortcodes"><?php echo esc_html($setting["options"]["enableShortcodes"]["label"]); ?></label>
56
+ <p class="wpd-desc"><?php echo $setting["options"]["enableShortcodes"]["description"] ?></p>
57
+ </div>
58
+ <div class="wpd-opt-input">
59
+ <div class="wpd-switcher">
60
+ <input type="checkbox" <?php checked($this->content["enableShortcodes"] == 1) ?> value="1" name="<?php echo esc_attr(WpdiscuzCore::TAB_CONTENT); ?>[enableShortcodes]" id="enableShortcodes">
61
+ <label for="enableShortcodes"></label>
62
+ </div>
63
+ </div>
64
+ <div class="wpd-opt-doc">
65
+ <a href="<?php echo esc_url_raw($setting["options"]["enableShortcodes"]["docurl"]) ?>" title="<?php esc_attr_e("Read the documentation", "wpdiscuz") ?>" target="_blank"><i class="far fa-question-circle"></i></a>
66
+ </div>
67
+ </div>
68
+ <!-- Option end -->
69
+
70
  <!-- Option start -->
71
  <div class="wpd-opt-row" data-wpd-opt="commentReadMoreLimit">
72
  <div class="wpd-opt-name">
options/options-layouts/html-form.php CHANGED
@@ -25,7 +25,7 @@ if (!defined("ABSPATH")) {
25
  <div class="wpd-switch-field">
26
  <input type="radio" value="collapsed" <?php checked("collapsed" === $this->form["commentFormView"]); ?> name="<?php echo esc_attr(WpdiscuzCore::TAB_FORM); ?>[commentFormView]" id="collapsedForm" />
27
  <label for="collapsedForm" style="min-width:60px;"><?php esc_html_e("collapsed", "wpdiscuz"); ?></label>
28
- <input type="radio" value="expanded" <?php checked("expanded" == $this->form["commentFormView"]); ?> name="<?php echo esc_attr(WpdiscuzCore::TAB_FORM); ?>[commentFormView]" id="expandedForm" />
29
  <label for="expandedForm" style="min-width:60px;"><?php esc_html_e("expanded", "wpdiscuz"); ?></label>
30
  </div>
31
  </div>
25
  <div class="wpd-switch-field">
26
  <input type="radio" value="collapsed" <?php checked("collapsed" === $this->form["commentFormView"]); ?> name="<?php echo esc_attr(WpdiscuzCore::TAB_FORM); ?>[commentFormView]" id="collapsedForm" />
27
  <label for="collapsedForm" style="min-width:60px;"><?php esc_html_e("collapsed", "wpdiscuz"); ?></label>
28
+ <input type="radio" value="expanded" <?php checked("expanded" === $this->form["commentFormView"]); ?> name="<?php echo esc_attr(WpdiscuzCore::TAB_FORM); ?>[commentFormView]" id="expandedForm" />
29
  <label for="expandedForm" style="min-width:60px;"><?php esc_html_e("expanded", "wpdiscuz"); ?></label>
30
  </div>
31
  </div>
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: gVectors Team
3
  Tags: comment, comments, ajax comments, comment form, comment fields
4
  Requires at least: 5.0
5
  Tested up to: 5.4
6
- Stable tag: 7.0.1
7
  Requires PHP: 5.4 and higher
8
  License: GPLv3
9
  License URI: https://www.gnu.org/licenses/gpl-3.0.html
@@ -178,7 +178,7 @@ Nothing will be lost! **Comments - wpDiscuz** will show all old comments.
178
 
179
  == Changelog ==
180
 
181
- = Comments - wpDiscuz v7.0.0 / v7.0.1 =
182
 
183
  **IMPORTANT!**
184
  This is a major version update!
@@ -192,6 +192,14 @@ As you can see we jump from 5.3.5 version to 7.0.x, so you should understand, th
192
 
193
  **What's new in wpDiscuz 7!**
194
 
 
 
 
 
 
 
 
 
195
  * version 7.0.1
196
  * Added: New option to collapse/expend comment form fields
197
  * Added: New option to disable Social Network icons on avatars
3
  Tags: comment, comments, ajax comments, comment form, comment fields
4
  Requires at least: 5.0
5
  Tested up to: 5.4
6
+ Stable tag: 7.0.2
7
  Requires PHP: 5.4 and higher
8
  License: GPLv3
9
  License URI: https://www.gnu.org/licenses/gpl-3.0.html
178
 
179
  == Changelog ==
180
 
181
+ = Comments - wpDiscuz v7.0.0 / v7.0.1 / v7.0.2 =
182
 
183
  **IMPORTANT!**
184
  This is a major version update!
192
 
193
  **What's new in wpDiscuz 7!**
194
 
195
+ * version 7.0.2
196
+ * Added: New Option - Enable WordPress Shortcodes in Comment Content
197
+ * Fixed Bug: Rating is not updated because of cache plugins
198
+ * Fixed Bug: Paragraph HTML code in Dashboard comment editor
199
+ * Fixed Bug: Problem with duplicated IDs in the HTML code
200
+ * Fixed Bug: Problem with the [collapsed | expended] comment form option
201
+ * Disabled Feature: Aggregate Rating Schema is disabled. Google has removed the "Article" type, so we don't have a general type for all. We have to disable it to avoid Google Search Console error reports. We'll add a FAQ topic in wpDiscuz support forum for users who want to enable it for existing [Rating Types](https://webmasters.googleblog.com/2019/09/making-review-rich-results-more-helpful.html)
202
+ * ----------
203
  * version 7.0.1
204
  * Added: New option to collapse/expend comment form fields
205
  * Added: New option to disable Social Network icons on avatars
utils/class.WpdiscuzHelper.php CHANGED
@@ -30,6 +30,9 @@ class WpdiscuzHelper implements WpDiscuzConstants {
30
  if ($this->options->subscription["enableUserMentioning"]) {
31
  add_filter("comment_text", [&$this, "userMentioning"], 10, 3);
32
  }
 
 
 
33
  add_filter("wp_update_comment_data", [&$this, "commentDataArr"], 10, 3);
34
  add_action("post_updated", [&$this, "checkFeedbackShortcodes"], 10, 3);
35
  add_filter("comment_row_actions", [&$this, "commentRowStickAction"], 10, 2);
@@ -789,6 +792,13 @@ class WpdiscuzHelper implements WpDiscuzConstants {
789
  return $content;
790
  }
791
 
 
 
 
 
 
 
 
792
  public function getMentionedUsers($content) {
793
  $users = [];
794
  if (preg_match_all("/(@[^\s\,\@\.\!\?\#\$\%\:\;\'\"\`\~\)\(\}\{\|\\\[\]]*)/is", $content, $nicenames)) {
30
  if ($this->options->subscription["enableUserMentioning"]) {
31
  add_filter("comment_text", [&$this, "userMentioning"], 10, 3);
32
  }
33
+ if ($this->options->content["enableShortcodes"]) {
34
+ add_filter("comment_text", [&$this, "doShortcode"], 10, 3);
35
+ }
36
  add_filter("wp_update_comment_data", [&$this, "commentDataArr"], 10, 3);
37
  add_action("post_updated", [&$this, "checkFeedbackShortcodes"], 10, 3);
38
  add_filter("comment_row_actions", [&$this, "commentRowStickAction"], 10, 2);
792
  return $content;
793
  }
794
 
795
+ public function doShortcode($content, $comment, $args = []) {
796
+ if (!empty($args["is_wpdiscuz_comment"])) {
797
+ return do_shortcode($content);
798
+ }
799
+ return $content;
800
+ }
801
+
802
  public function getMentionedUsers($content) {
803
  $users = [];
804
  if (preg_match_all("/(@[^\s\,\@\.\!\?\#\$\%\:\;\'\"\`\~\)\(\}\{\|\\\[\]]*)/is", $content, $nicenames)) {
utils/class.WpdiscuzHelperAjax.php CHANGED
@@ -684,6 +684,7 @@ class WpdiscuzHelperAjax implements WpDiscuzConstants {
684
  }
685
  $response["callbackFunctions"] = [];
686
  $response = apply_filters("wpdiscuz_comment_vote", $response);
 
687
  wp_send_json_success($response);
688
  } else {
689
  wp_send_json_error("wc_voting_error");
@@ -798,6 +799,7 @@ class WpdiscuzHelperAjax implements WpDiscuzConstants {
798
  $count = count($data);
799
  update_post_meta($post_id, self::POSTMETA_POST_RATING, round($votes / $count, 1));
800
  update_post_meta($post_id, self::POSTMETA_POST_RATING_COUNT, $count);
 
801
  wp_send_json_success();
802
  } else {
803
  wp_send_json_error("wc_cannot_rate_again");
@@ -814,6 +816,7 @@ class WpdiscuzHelperAjax implements WpDiscuzConstants {
814
  $count = count($data);
815
  update_post_meta($post_id, self::POSTMETA_POST_RATING, round($votes / $count, 1));
816
  update_post_meta($post_id, self::POSTMETA_POST_RATING_COUNT, $count);
 
817
  wp_send_json_success();
818
  } else {
819
  wp_send_json_error("wc_cannot_rate_again");
684
  }
685
  $response["callbackFunctions"] = [];
686
  $response = apply_filters("wpdiscuz_comment_vote", $response);
687
+ clean_post_cache($comment->comment_post_ID);
688
  wp_send_json_success($response);
689
  } else {
690
  wp_send_json_error("wc_voting_error");
799
  $count = count($data);
800
  update_post_meta($post_id, self::POSTMETA_POST_RATING, round($votes / $count, 1));
801
  update_post_meta($post_id, self::POSTMETA_POST_RATING_COUNT, $count);
802
+ clean_post_cache($post_id);
803
  wp_send_json_success();
804
  } else {
805
  wp_send_json_error("wc_cannot_rate_again");
816
  $count = count($data);
817
  update_post_meta($post_id, self::POSTMETA_POST_RATING, round($votes / $count, 1));
818
  update_post_meta($post_id, self::POSTMETA_POST_RATING_COUNT, $count);
819
+ clean_post_cache($post_id);
820
  wp_send_json_success();
821
  } else {
822
  wp_send_json_error("wc_cannot_rate_again");