migrate to new git
This commit is contained in:
1 parent
946eb9961e
commit
af2c152ef6
8623 files changed
+1000453
-1
No files matched your search
Binary file not shown.
@@ -0,0 +1,2 @@
|
||||
//PLUGINS
|
||||
_cb.settings.plugins = ['preview','wordcount', 'buttoneditor', 'symbols']; // 'searchreplace', 'symbols',
|
||||
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,62 @@
|
||||
function e(t){return(e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(t)}function t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function n(e,t,n){return t&&i(e.prototype,t),n&&i(e,n),e}var o,r,a,l,s,c,d,u,p=function(){function e(i){t(this,e),this.builder=i}return n(e,[{key:"cellSelected",value:function(){return document.querySelector(".cell-active")}},{key:"builderStuff",value:function(){return document.querySelector("#_cbhtml")}},{key:"cellNext",value:function(e){var t=new v,i=e.nextElementSibling;return i?t.hasClass(i,"is-row-tool")||t.hasClass(i,"is-rowadd-tool")?null:i:null}},{key:"out",value:function(e){if(this.builder){var t=this.builder.opts.lang[e];return t||(this.builder.checkLang&&console.log(e),e)}return e}},{key:"confirm",value:function(e,t){var i=this,n=new v,o='<div class="is-modal is-confirm">\n <div style="max-width:526px;text-align:center;">\n <p>'.concat(e,'</p>\n <button title="').concat(this.out("Delete"),'" class="input-ok classic">').concat(this.out("Delete"),"</button>\n </div>\n </div>"),r=this.builderStuff(),a=r.querySelector(".is-confirm");a||(n.appendHtml(r,o),a=r.querySelector(".is-confirm")),this.showModal(a,!1,(function(){a.parentNode.removeChild(a),t(!1)}),!0);var l=a.querySelector(".is-confirm .input-ok");n.addEventListener(l,"click",(function(){i.hideModal(a),a.parentNode.removeChild(a),t(!0)}))}},{key:"showModal",value:function(e,t,i,n){var o=this,r=new v;r.addClass(e,"active");var a,l=!1;if(this.builder?this.builder.opts.animateModal&&(l=!0,n||(l=!1)):n&&(l=!0),l&&this.builder){var s=document.querySelectorAll(this.builder.opts.container);Array.prototype.forEach.call(s,(function(e){e.style.transform="scale(0.98)",e.style.WebkitTransform="scale(0.98)",e.style.MozTransform="scale(0.98)"}))}if(!e.querySelector(".is-modal-overlay")&&(a=t?'<div class="is-modal-overlay" style="position:absolute;top:0;left:0;width:100%;height:100%;background:rgba(255,255,255,0.3);z-index:-1;"></div>':'<div class="is-modal-overlay" style="position:absolute;top:0;left:0;width:100%;height:100%;background:rgba(255,255,255,0.000001);z-index:-1;"></div>',e.insertAdjacentHTML("afterbegin",a),!t)){var c=e.querySelector(".is-modal-overlay");r.addEventListener(c,"click",(function(){i&&i(),o.hideModal(e)}))}}},{key:"hideModal",value:function(e){if(this.builder){var t=document.querySelectorAll(this.builder.opts.container);Array.prototype.forEach.call(t,(function(e){e.style.transform="",e.style.WebkitTransform="",e.style.MozTransform=""}))}(new v).removeClass(e,"active")}},{key:"fixLayout",value:function(e){var t=new v,i=e.childElementCount-2,n=this.builder.opts.row,o=this.builder.opts.cols,r=this.builder.opts.colequal;if(r.length>0)t.elementChildren(e).forEach((function(e){if(!t.hasClass(e,"is-row-tool")&&!t.hasClass(e,"is-rowadd-tool")){for(var n=0;n<=o.length-1;n++)t.removeClass(e,o[n]);for(var a=0;a<=r.length-1;a++)if(r[a].length===i){t.addClass(e,r[a][0]);break}1===i&&t.addClass(e,o[o.length-1])}}));else if(""!==n&&o.length>0){var a=0;t.elementChildren(e).forEach((function(e){if(!t.hasClass(e,"is-row-tool")&&!t.hasClass(e,"is-rowadd-tool")){a++;for(var n=0;n<=o.length-1;n++)t.removeClass(e,o[n]);1===i&&t.addClass(e,o[11]),2===i&&t.addClass(e,o[5]),3===i&&t.addClass(e,o[3]),4===i&&t.addClass(e,o[2]),5===i&&(5===a?t.addClass(e,o[3]):t.addClass(e,o[1])),6===i&&t.addClass(e,o[1]),7===i&&(a>=6?t.addClass(e,o[0]):t.addClass(e,o[1])),8===i&&(a>=5?t.addClass(e,o[0]):t.addClass(e,o[1])),9===i&&(a>=4?t.addClass(e,o[0]):t.addClass(e,o[1])),10===i&&(a>=3?t.addClass(e,o[0]):t.addClass(e,o[1])),11===i&&(a>=2?t.addClass(e,o[0]):t.addClass(e,o[1])),12===i&&t.addClass(e,o[0])}}))}}},{key:"addContent",value:function(e,t,i){var n,o=new v,r=this.cellSelected();if(r)n=r.parentNode;else{if(!(n=document.querySelector(".row-active")))return;t="row"}if("cell"===t||"cell-left"===t||"cell-right"===t){var a,l=4;if(this.builder.maxColumns&&(l=this.builder.maxColumns),n.childElementCount>=l+2)return alert(this.out("You have reached the maximum number of columns")),!1;if(this.builder.uo.saveForUndo(),""===this.builder.opts.row){var s=this.builder.opts.cellFormat,c=s.indexOf("</");e=s.substring(0,c)+e+s.substring(c),a=this.createElementFromHTML(e)}else{(a=r.cloneNode(!0)).removeAttribute("data-noedit"),a.removeAttribute("data-protected"),a.removeAttribute("data-module"),a.removeAttribute("data-module-desc"),a.removeAttribute("data-dialog-width"),a.removeAttribute("data-html"),a.removeAttribute("data-settings");for(var d=1;d<=20;d++)a.removeAttribute("data-html-"+d);a.removeAttribute("data-noedit"),o.removeClass(a,"cell-actiLine truncated
|
||||
/**!
|
||||
* Sortable 1.10.1
|
||||
* @author RubaXa <trash@rubaxa.org>
|
||||
* @author owenm <owen23355@gmail.com>
|
||||
* @license MIT
|
||||
*/
|
||||
function N(e){return(N="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function R(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function B(){return(B=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e}).apply(this,arguments)}function I(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{},n=Object.keys(i);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(i).filter((function(e){return Object.getOwnPropertyDescriptor(i,e).enumerable})))),n.forEach((function(t){R(e,t,i[t])}))}return e}function H(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}function D(e){return function(e){if(Array.isArray(e)){for(var t=0,i=new Array(e.length);t<e.length;t++)i[t]=e[t];return i}}(e)||function(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function F(e){if("undefined"!=typeof window&&window.navigator)return!!navigator.userAgent.match(e)}var P=F(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),U=F(/Edge/i),z=F(/firefox/i),W=F(/safari/i)&&!F(/chrome/i)&&!F(/android/i),j=F(/iP(ad|od|hone)/i),Y=F(/chrome/i)&&F(/android/i),X={capture:!1,passive:!1};function G(e,t,i){e.addEventListener(t,i,!P&&X)}function V(e,t,i){e.removeEventListener(t,i,!P&&X)}function Z(e,t){if(t){if(">"===t[0]&&(t=t.substring(1)),e)try{if(e.matches)return e.matches(t);if(e.msMatchesSelector)return e.msMatchesSelector(t);if(e.webkitMatchesSelector)return e.webkitMatchesSelector(t)}catch(e){return!1}return!1}}function K(e){return e.host&&e!==document&&e.host.nodeType?e.host:e.parentNode}function J(e,t,i,n){if(e){i=i||document;do{if(null!=t&&(">"===t[0]?e.parentNode===i&&Z(e,t):Z(e,t))||n&&e===i)return e;if(e===i)break}while(e=K(e))}return null}var $,Q=/\s+/g;function ee(e,t,i){if(e&&t)if(e.classList)e.classList[i?"add":"remove"](t);else{var n=(" "+e.className+" ").replace(Q," ").replace(" "+t+" "," ");e.className=(n+(i?" "+t:"")).replace(Q," ")}}function te(e,t,i){var n=e&&e.style;if(n){if(void 0===i)return document.defaultView&&document.defaultView.getComputedStyle?i=document.defaultView.getComputedStyle(e,""):e.currentStyle&&(i=e.currentStyle),void 0===t?i:i[t];t in n||-1!==t.indexOf("webkit")||(t="-webkit-"+t),n[t]=i+("string"==typeof i?"":"px")}}function ie(e,t){var i="";if("string"==typeof e)i=e;else do{var n=te(e,"transform");n&&"none"!==n&&(i=n+" "+i)}while(!t&&(e=e.parentNode));var o=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix;return o&&new o(i)}function ne(e,t,i){if(e){var n=e.getElementsByTagName(t),o=0,r=n.length;if(i)for(;o<r;o++)i(n[o],o);return n}return[]}function oe(){return P?document.documentElement:document.scrollingElement}function re(e,t,i,n,o){if(e.getBoundingClientRect||e===window){var r,a,l,s,c,d,u;if(e!==window&&e!==oe()?(a=(r=e.getBoundingClientRect()).top,l=r.left,s=r.bottom,c=r.right,d=r.height,u=r.width):(a=0,l=0,s=window.innerHeight,c=window.innerWidth,d=window.innerHeight,u=window.innerWidth),(t||i)&&e!==window&&(o=o||e.parentNode,!P))do{if(o&&o.getBoundingClientRect&&("none"!==te(o,"transform")||i&&"static"!==te(o,"position"))){var p=o.getBoundingClientRect();a-=p.top+parseInt(te(o,"border-top-width")),l-=p.left+parseInt(te(o,"border-left-width")),s=a+r.height,c=l+r.width;break}}while(o=o.parentNode);if(n&&e!==window){var v=ie(o||e),h=v&&v.a,f=v&&v.d;v&&(s=(a/=f)+(d/=f),c=(l/=h)+(u/=h))}return{top:a,left:l,bottom:s,right:c,width:u,height:d}}}function ae(e,t,i){for(var n=ue(e,!0),o=re(e)[t];n;){var r=re(n)[i];if(!("top"===i||"left"===i?o>=r:o<=r))return n;if(n===oe())break;n=ue(n,!1)}return!1}function le(e,t,i){for(var n=0,o=0,r=e.children;o<r.length;){if("none"!==r[o].style.display&&r[o]!==gt.ghost&&r[o]!==gt.dragged&&J(r[o],i.draggable,e,!1)){if(n===t)return r[o];n++}o++}return null}function se(e,t){for(var i=e.lastElementChild;i&&(i===gt.ghost||"none"===te(i,"display")||t&&!Z(i,t));)i=i.previousElementSibling;return i||null}function ce(e,t){var i=0;if(!e||!e.parentNode)return-1;for(;e=e.previousElementSibling;)"TEMPLATE"===e.nodeName.toUpperCase()||e===gt.clone||t&&!Z(e,t)||i++;return i}function de(e){var t=0,i=0,n=oe();if(e)do{var o=ie(e),r=o.a,a=o.d;t+=e.scrollLeft*r,i+=e.scrollTop*a}while(e!==n&&(e=e.parentNode));return[t,i]}function ue(e,t){if(!e||!e.geLine truncated
|
||||
/*!
|
||||
* Cropper.js v1.5.5
|
||||
* https://fengyuanchen.github.io/cropperjs
|
||||
*
|
||||
* Copyright 2015-present Chen Fengyuan
|
||||
* Released under the MIT license
|
||||
*
|
||||
* Date: 2019-08-04T02:26:31.160Z
|
||||
*/(e))}),!1);var h=document.querySelector(".is-design-list"),f=e.opts.snippetPath,g=!0;if(window.jQuery&&window.jQuery.fn.slick&&(g=!1),g)for(var m=0;m<e.opts.snippetJSON.snippets.length;m++)if(-1!==e.opts.snippetJSON.snippets[m].thumbnail.indexOf("element-slider.png")){e.opts.snippetJSON.snippets.splice(m,1);break}var y=1;e.opts.emailMode?e.opts.snippetJSON.snippets.forEach((function(t){t.id=y,t.category===e.opts.defaultEmailSnippetCategory+""&&Kt.appendHtml(h,'<div class="snippet-item" data-id="'+t.id+'" data-cat="'+t.category+'"><img src="'+f+t.thumbnail+'"></div>'),y++})):e.opts.snippetJSON.snippets.forEach((function(t){t.id=y,t.category===e.opts.defaultSnippetCategory+""&&Kt.appendHtml(h,'<div class="snippet-item" data-id="'+t.id+'" data-cat="'+t.category+'"><img src="'+f+t.thumbnail+'"></div>'),y++}));var b=navigator.userAgent,x=b.indexOf("Safari")>-1;if(b.indexOf("Chrome")>-1&&x&&(x=!1),new gt(h,{forceFallback:x,group:{name:"shared",pull:"clone",put:!1},sort:!1,animation:150,onMove:function(){var e=document.querySelector(".row-add-initial");e&&e.parentNode.removeChild(e)},onStart:function(){e.uo.saveForUndo();var t=document.querySelector(".is-sidebar-overlay");t&&(t.style.display="none")},onEnd:function(){var e=document.querySelector(".is-sidebar-overlay");e&&(e.style.display="block"),t.checkEmpty()}}),new O(document.querySelector(".snippet-cat"),{onChange:function(t){var i=t,n=h.querySelectorAll(".snippet-item"),o=!1;Array.prototype.forEach.call(n,(function(e){e.getAttribute("data-cat")===i&&(o=!0)})),o||e.opts.snippetJSON.snippets.forEach((function(e){e.category===i&&Kt.appendHtml(h,'<div class="snippet-item" data-id="'+e.id+'" data-cat="'+e.category+'"><img src="'+f+e.thumbnail+'"></div>')})),i&&(Array.prototype.forEach.call(n,(function(e){Kt.addClass(e,"hide")})),Array.prototype.forEach.call(n,(function(e){e.getAttribute("data-cat")===i&&(e.className=e.className.replace(/hide/g,""))})))}}),"#divSnippetList"===e.opts.snippetList){var w=v.querySelector("#divSnippetHandle");Kt.addEventListener(w,"click",(function(){$t(e),t.clearActiveCell(),t.clearControls()}));var S=window.innerWidth;e.opts.snippetOpen&&S>=960&&(v.style.cssText="transition: all ease 0.8s;",setTimeout((function(){$t(e)}),100),setTimeout((function(){v.style.cssText=""}),1300))}var C=v.querySelector("#divSnippetScrollUp"),E=v.querySelector("#divSnippetScrollDown");C.style.display="none",E.style.display="none"};function $t(e){var t=document.querySelector("#divSnippetList"),i=t.querySelector("#divSnippetHandle");Kt.hasClass(t,"active")?(Kt.removeClass(t,"active"),"right"===e.opts.sidePanel?i.innerHTML='<svg class="is-icon-flex" style="width:17px;height:17px;fill:rgba(0, 0, 0, 0.75);"><use xlink:href="#ion-ios-arrow-left"></use></svg>':i.innerHTML='<svg class="is-icon-flex" style="width:17px;height:17px;fill:rgba(0, 0, 0, 0.75);"><use xlink:href="#ion-ios-arrow-right"></use></svg>'):(Kt.addClass(t,"active"),"right"===e.opts.sidePanel?i.innerHTML='<svg class="is-icon-flex" style="width:17px;height:17px;fill:rgba(0, 0, 0, 0.75);"><use xlink:href="#ion-ios-arrow-right"></use></svg>':i.innerHTML='<svg class="is-icon-flex" style="width:17px;height:17px;fill:rgba(0, 0, 0, 0.75);"><use xlink:href="#ion-ios-arrow-left"></use></svg>')}function Qt(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function ei(e){return function(e){if(Array.isArray(e)){for(var t=0,i=new Array(e.length);t<e.length;t++)i[t]=e[t];return i}}(e)||function(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}var ti="undefined"!=typeof window&&void 0!==window.document,ii=ti?window:{},ni=!!ti&&"ontouchstart"in ii.document.documentElement,oi=!!ti&&"PointerEvent"in ii,ri="".concat("cropper","-crop"),ai="".concat("cropper","-disabled"),li="".concat("cropper","-hidden"),si="".concat("cropper","-hide"),ci="".concat("cropper","-invisible"),di="".concat("cropper","-modal"),ui="".concat("cropper","-move"),pi="".concat("cropper","Action"),vi="".concat("cropper","Preview"),hi=oi?"pointerdown":ni?"touchstart":"mousedown",fi=oi?"pointermove":ni?"touchmove":"mousemove",gi=oi?"pointerup pointercancel":ni?"touchend touchcancel":"mouseup",mi=/^e|w|s|n|se|sw|ne|nw|all|crop|move|zoom$/,yi=/^data:/,bi=/^data:image\/jpeg;base64,/,xi=/^img|canvas$/i,wi={viewMode:0,dragMode:"crop",initialAspectRatio:NaN,aspectRatio:NaN,data:null,preview:"",responsive:!0,restore:!0,checkCrossOrigin:!0,checkOrientation:!0,modal:!0,guides:!0,center:!0,highlight:!0,background:!0,autoCrop:!0,autoCropArea:.8,movable:!0,rotatable:!0,scalable:!0,zoomable:!0,zoomOnTouch:!0,zoomOnWheel:!0,wheelZoomRatio:.1,cropBoxMovable:!0,cropBoxResizable:!0,toggleDragModeOnDblclick:!0,minCanvasWidth:0,minCanvasHeight:0,minCropBoxWidth:0,minCropBoxHeight:0,minContainerWidth:200,minCoLine truncated
|
||||
/*! *****************************************************************************
|
||||
Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
||||
this file except in compliance with the License. You may obtain a copy of the
|
||||
License at http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
|
||||
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
|
||||
MERCHANTABLITY OR NON-INFRINGEMENT.
|
||||
|
||||
See the Apache Version 2.0 License for specific language governing permissions
|
||||
and limitations under the License.
|
||||
***************************************************************************** */var ta=function(e,t){return(ta=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)t.hasOwnProperty(i)&&(e[i]=t[i])})(e,t)};var ia=function(){return(ia=Object.assign||function(e){for(var t,i=1,n=arguments.length;i<n;i++)for(var o in t=arguments[i])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};
|
||||
/*! *****************************************************************************
|
||||
Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
||||
this file except in compliance with the License. You may obtain a copy of the
|
||||
License at http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
|
||||
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
|
||||
MERCHANTABLITY OR NON-INFRINGEMENT.
|
||||
|
||||
See the Apache Version 2.0 License for specific language governing permissions
|
||||
and limitations under the License.
|
||||
***************************************************************************** */
|
||||
var na=function(){return(na=Object.assign||function(e){for(var t,i=1,n=arguments.length;i<n;i++)for(var o in t=arguments[i])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};function oa(e,t,i,n){var o=ua(e),r=ua(t),a=ua(n);return aa(pa(n[0],va(o,a)),pa(n[0],va(r,a)),i[0])}function ra(e){return e.touches?ca(e.touches):[da(e)]}function aa(e,t,i){var n=e.clientX,o=e.clientY;return{clientX:n,clientY:o,deltaX:n-t.clientX,deltaY:o-t.clientY,distX:n-i.clientX,distY:o-i.clientY}}function la(e){return Math.sqrt(Math.pow(e[0].clientX-e[1].clientX,2)+Math.pow(e[0].clientY-e[1].clientY,2))}function sa(e,t,i){return e.map((function(e,n){return aa(e,t[n],i[n])}))}function ca(e){for(var t=Math.min(e.length,2),i=[],n=0;n<t;++n)i.push(da(e[n]));return i}function da(e){return{clientX:e.clientX,clientY:e.clientY}}function ua(e){return{clientX:(e[0].clientX+e[1].clientX)/2,clientY:(e[0].clientY+e[1].clientY)/2}}function pa(e,t){return{clientX:e.clientX+t.clientX,clientY:e.clientY+t.clientY}}function va(e,t){return{clientX:e.clientX-t.clientX,clientY:e.clientY-t.clientY}}var ha=function(){function e(e,t){var i=this;void 0===t&&(t={}),this.el=e,this.options={},this.flag=!1,this.pinchFlag=!1,this.datas={},this.isDrag=!1,this.isPinch=!1,this.isMouse=!1,this.isTouch=!1,this.prevClients=[],this.startClients=[],this.movement=0,this.startPinchClients=[],this.startDistance=0,this.customDist=[0,0],this.onDragStart=function(e){if(i.flag||!1!==e.cancelable){if(function(e){return e.touches&&e.touches.length>=2}(e)){if(!i.flag&&e.touches.length!==e.changedTouches.length)return;i.pinchFlag||i.onPinchStart(e)}if(!i.flag){var t=i.startClients[0]?i.startClients:ra(e);i.customDist=[0,0],i.flag=!0,i.isDrag=!1,i.startClients=t,i.prevClients=t,i.datas={},i.movement=0;var n=aa(t[0],i.prevClients[0],i.startClients[0]),o=i.options,r=o.dragstart,a=o.preventRightClick,l=o.preventDefault;(a&&3===e.which||!1===(r&&r(na({datas:i.datas,inputEvent:e},n))))&&(i.startClients=[],i.prevClients=[],i.flag=!1),i.flag&&l&&e.preventDefault()}}},this.onDrag=function(e,t){if(i.flag){var n=ra(e);i.pinchFlag&&i.onPinch(e,n);var o=i.move([0,0],e,n);if(o&&(o.deltaX||o.deltaY)){var r=i.options.drag;r&&r(na({},o,{isScroll:!!t,inputEvent:e}))}}},this.onDragEnd=function(e){if(i.flag){i.pinchFlag&&i.onPinchEnd(e),i.flag=!1;var t=i.options.dragend,n=i.prevClients,o=i.startClients,r=i.pinchFlag?oa(n,n,o,i.startPinchClients):aa(n[0],n[0],o[0]);i.startClients=[],i.prevClients=[],t&&t(na({datas:i.datas,isDrag:i.isDrag,inputEvent:e},r))}},this.options=na({container:e,preventRightClick:!0,preventDefault:!0,pinchThreshold:0,events:["touch","mouse"]},t);var n=this.options,o=n.container,r=n.events;if(this.isTouch=r.indexOf("touch")>-1,this.isMouse=r.indexOf("mouse")>-1,this.customDist=[0,0],this.isMouse&&(qr(e,"mousedown",this.onDragStart),qr(o,"mousemove",this.onDrag),qr(o,"mouseup",this.onDragEnd)),this.isTouch){var a={passive:!1};qr(e,"touchstart",this.onDragStart,a),qr(o,"touchmove",this.onDrag,a),qr(o,"touchend",this.onDragEnd,a)}}var t=e.prototype;return t.isDragging=function(){return this.isDrag},t.isFlag=function(){return this.flag},t.isPinching=function(){return this.isPinch},t.scrollBy=function(e,t,i,n){void 0===n&&(n=!0),this.flag&&(this.startClients.forEach((function(i){i.clientX-=e,i.clientY-=t})),this.prevClients.forEach((function(i){i.clientX-=e,i.clientY-=t})),n&&this.onDrag(i,!0))},t.move=function(e,t,i){var n=e[0],o=e[1];void 0===i&&(i=this.prevClients);var r=this.customDist,a=this.prevClients,l=this.startClients,s=this.pinchFlag?oa(i,a,l,this.startPinchClients):aa(i[0],a[0],l[0]);r[0]+=n,r[1]+=o,s.deltaX+=n,s.deltaY+=o;var c=s.deltaX,d=s.deltaY;return s.distX+=r[0],s.distY+=r[1],this.movement+=Math.sqrt(c*c+d*d),this.prevClients=i,this.isDrag=!0,na({datas:this.datas},s,{isScroll:!1,inputEvent:t})},t.onPinchStart=function(e){var t,i,n=this.options,o=n.pinchstart,r=n.pinchThreshold;if(!(this.isDrag&&this.movement>r)){var a=ca(e.changedTouches);if(this.pinchFlag=!0,(t=this.startClients).push.apply(t,a),(i=this.prevClients).push.apply(i,a),this.startDistance=la(this.prevClients),this.startPinchClients=this.prevClients.slice(),o){var l=this.prevClients,s=ua(l),c=aa(s,s,s);o(na({datas:this.datas,touches:sa(l,l,l)},c,{inputEvent:e}))}}},t.onPinch=function(e,t){if(this.flag&&this.pinchFlag){this.isPinch=!0;var i=this.options.pinch;if(i){var n=this.prevClients,o=this.startClients,r=aa(ua(t),ua(n),ua(o)),a=la(t);i(na({datas:this.datas,touches:sa(t,n,o),scale:a/this.startDistance,distance:a},r,{inputEvent:e}))}}},t.onPinchEnd=function(e){if(this.flag&&this.pinchFlag){var t=this.isPinch;this.isPinch=!1,this.pinchFlag=!1;var i=this.options.pinchend;if(i){var n=this.prevClients,o=this.startClients,r=aa(ua(n),ua(n),ua(o));i(na({datas:this.datas,isPinch:t,touches:sa(n,n,o)},r,{inputEvent:e})),this.isPinch=!1,this.pinchFlag=!1}}},t.unset=function(){var e=this.el,t=this.options.container;this.isMouse&&(Mr(e,"mousedown",this.onDragStart),Mr(t,"mousLine truncated
|
||||
/*! *****************************************************************************
|
||||
Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
||||
this file except in compliance with the License. You may obtain a copy of the
|
||||
License at http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
|
||||
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
|
||||
MERCHANTABLITY OR NON-INFRINGEMENT.
|
||||
|
||||
See the Apache Version 2.0 License for specific language governing permissions
|
||||
and limitations under the License.
|
||||
***************************************************************************** */var Sa,Ca="function"==typeof Map?void 0:(Sa=0,function(e){return e.__DIFF_KEY__||(e.__DIFF_KEY__=++Sa)}),Ea=function(e){function t(t){return void 0===t&&(t=[]),e.call(this,t,Ca)||this}return function(e,t){function i(){this.constructor=e}wa(e,t),e.prototype=null===t?Object.create(t):(i.prototype=t.prototype,new i)}(t,e),t}(xa),ka=function(e,t){return(ka=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)t.hasOwnProperty(i)&&(e[i]=t[i])})(e,t)};function La(e,t){function i(){this.constructor=e}ka(e,t),e.prototype=null===t?Object.create(t):(i.prototype=t.prototype,new i)}var Aa=function(){return(Aa=Object.assign||function(e){for(var t,i=1,n=arguments.length;i<n;i++)for(var o in t=arguments[i])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};function qa(e,t){return'data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="'+32*e+'px" height="'+32*e+'px" viewBox="0 0 32 32" ><path d="M 16,5 L 12,10 L 14.5,10 L 14.5,22 L 12,22 L 16,27 L 20,22 L 17.5,22 L 17.5,10 L 20, 10 L 16,5 Z" stroke-linejoin="round" stroke-width="1.2" fill="black" stroke="white" style="transform:rotate('+t+'deg);transform-origin: 16px 16px"></path></svg>'}var Ma=br(),_a=Ma.os.name.indexOf("ios")>-1||Ma.browser.name.indexOf("safari")>-1,Ta="moveable-",Oa=function(e,t){return t.replace(/([^}{]*){/gm,(function(t,i){return i.replace(/\.([^{,\s\d.]+)/g,"."+e+"$1")+"{"}))}(Ta,"\n{\n\tposition: fixed;\n\twidth: 0;\n\theight: 0;\n\tleft: 0;\n\ttop: 0;\n\tz-index: 3000;\n}\n.control-box {\n z-index: 0;\n}\n.line, .control {\n\tleft: 0;\n\ttop: 0;\n}\n.control {\n\tposition: absolute;\n\twidth: 14px;\n\theight: 14px;\n\tborder-radius: 50%;\n\tborder: 2px solid #fff;\n\tbox-sizing: border-box;\n\tbackground: #4af;\n\tmargin-top: -7px;\n margin-left: -7px;\n z-index: 10;\n will-change: transform;\n}\n.line {\n\tposition: absolute;\n\twidth: 1px;\n\theight: 1px;\n\tbackground: #4af;\n\ttransform-origin: 0px 0.5px;\n}\n.line.dashed {\n box-sizing: border-box;\n background: transparent;\n}\n.line.dashed.horizontal {\n border-top: 1px dashed #4af;\n}\n.line.dashed.vertical {\n border-left: 1px dashed #4af;\n}\n.line.rotation-line {\n\theight: 40px;\n\twidth: 1px;\n\ttransform-origin: 0.5px 39.5px;\n}\n.line.rotation-line .control {\n\tborder-color: #4af;\n\tbackground:#fff;\n\tcursor: alias;\n}\n.line.vertical {\n transform: translateX(-50%);\n}\n.line.horizontal {\n transform: translateY(-50%);\n}\n.line.vertical.bold {\n width: 2px;\n}\n.line.horizontal.bold {\n height: 2px;\n}\n.control.origin {\n\tborder-color: #f55;\n\tbackground: #fff;\n\twidth: 12px;\n\theight: 12px;\n\tmargin-top: -6px;\n\tmargin-left: -6px;\n\tpointer-events: none;\n}\n"+[0,15,30,45,60,75,90,105,120,135,150,165].map((function(e){return'\n.direction[data-rotation="'+e+'"] {\n\t'+function(e){var t=qa(1,e),i=qa(2,e),n=45*Math.round(e/45)%180,o=135===n?"nwse-resize":45===n?"nesw-resize":90===n?"ew-resize":"ns-resize";return"cursor:"+o+";cursor: url('"+t+"') 16 16, "+o+";cursor: -webkit-image-set(url('"+t+"') 1x, url('"+i+"') 2x) 16 16, "+o+";"}(e)+"\n}\n"})).join("\n")+"\n.group {\n z-index: -1;\n}\n.area {\n position: absolute;\n}\n.area-pieces {\n position: absolute;\n top: 0;\n left: 0;\n display: none;\n}\n.area.avoid {\n pointer-events: none;\n}\n.area.avoid+.area-pieces {\n display: block;\n}\n.area-piece {\n position: absolute;\n}\n"+(_a?':global svg *:before {\n\tcontent:"";\n\ttransform-origin: inherit;\n}':"")+"\n"),Na=[[0,1,2],[1,0,3],[2,0,3],[3,1,2]],Ra=1e-7,Ba=Math.pow(10,10),Ia=-Ba,Ha={n:[0,1],s:[2,3],w:[2,0],e:[1,3],nw:[0],ne:[1],sw:[2],se:[3]},Da={n:0,s:180,w:270,e:90,nw:315,ne:45,sw:225,se:135};function Fa(e,t){return[e[0]*t[0],e[1]*t[1]]}function Pa(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return bn.apply(void 0,[Ta].concat(e))}function Ua(){return Zr(3)}function za(e){return e&&"none"!==e?Er(e)?e:function(e){var t=/([^(]*)\(([\s\S]*)\)([\s\S]*)/g.exec(e);return!t||t.length<4?{}:{prefix:t[1],value:t[2],suffix:t[3]}}(e).value.split(/s*,\s*/g).map((function(e){return parseFloat(e)})):[1,0,0,1,0,0]}function Wa(e,t,i){return Dr(t,Jr(i,t),e,Jr(i.map((function(e){return-e})),t))}function ja(e){return Ya(ml(e,":before")).map((function(t,i){var n=Lr(t),o=n.value,r=n.unit;return o*function(e,t,i){return"%"===t?e.ownerSVGElement.viewBox.baseVal[i?"width":"height"]/100:1}(e,r,0===i)}))}function Ya(e){var t=e.transformOrigin;return t?t.split(" "):["0","0"]}function Xa(e,t,i){for(var n=document.body,o=!e||i?e:e.parentElement,r=!1,a="relative";o&&o!==n;){t===o&&(r=!0);var l=ml(o),s=l.transform;if("static"!==(a=l.position)||s&&"none"!==s)break;o=o.parentElement,a="relative"}return{isStatic:"static"===a,isEnd:r||!o||o===n,offsetParent:o||n}}function Ga(e,t,i,n){var o,r,a,l=e,s=[],c="svg"!==l.tagName.toLowerCaseLine truncated
|
||||
/*! Mega pixel image rendering library for iOS6 Safari | Copyright (c) 2012 Shinichi Tomita <shinichi.tomita@gmail.com> | MIT license | https://github.com/stomita/ios-imagefile-megapixel */
|
||||
function(e){var t=e.naturalWidth;if(t*e.naturalHeight>1048576){var i=document.createElement("canvas");i.width=i.height=1;var n=i.getContext("2d");return n.drawImage(e,1-t,0),0===n.getImageData(0,0,1,1).data[3]}return!1}(e)&&(o/=2,r/=2);var c=1024,d=document.createElement("canvas");d.width=d.height=c;for(var u=d.getContext("2d"),p=n?function(e,t,i){var n=document.createElement("canvas");n.width=1,n.height=i;var o=n.getContext("2d");o.drawImage(e,0,0);for(var r=o.getImageData(0,0,1,i).data,a=0,l=i,s=i;s>a;){0===r[4*(s-1)+3]?l=s:a=s,s=l+a>>1}var c=s/i;return 0===c?1:c}(e,0,r):1,v=Math.ceil(c*a/o),h=Math.ceil(c*l/r/p),f=0,g=0;f<r;){for(var m=0,y=0;m<o;)u.clearRect(0,0,c,c),u.drawImage(e,-m,-f),s.drawImage(d,0,0,c,c,y,g,v,h),m+=c,y+=v;f+=c,g+=h}s.restore(),d=u=null}}var Gs=window.URL&&window.URL.createObjectURL?window.URL:window.webkitURL&&window.webkitURL.createObjectURL?window.webkitURL:null;function Vs(e){if(window.Blob&&e instanceof Blob){if(!Gs)throw Error("No createObjectURL function found to create blob url");var t=new Ys;t.src=Gs.createObjectURL(e),this.blob=e,e=t}if(!e.naturalWidth&&!e.naturalHeight){var i=this;e.onload=e.onerror=function(){var e=i.imageLoadListeners;if(e){i.imageLoadListeners=null;for(var t=0,n=e.length;t<n;t++)e[t]()}},this.imageLoadListeners=[]}this.srcImage=e}function Zs(e,t,i){var n,o=document.createElement("img");return o.onerror=function(n){return Zs.onerror(o,n,e,t,i)},o.onload=function(n){return Zs.onload(o,n,e,t,i)},"string"==typeof e?(Zs.fetchBlob(e,(function(t){t?(e=t,n=Zs.createObjectURL(e)):(n=e,i&&i.crossOrigin&&(o.crossOrigin=i.crossOrigin)),o.src=n}),i),o):Zs.isInstanceOf("Blob",e)||Zs.isInstanceOf("File",e)?(n=o._objectURL=Zs.createObjectURL(e))?(o.src=n,o):Zs.readFile(e,(function(e){var i=e.target;i&&i.result?o.src=i.result:t&&t(e)})):void 0}Vs.prototype.render=function(e,t,i){if(this.imageLoadListeners){var n=this;this.imageLoadListeners.push((function(){n.render(e,t,i)}))}else{t=t||{};var o=this.srcImage.naturalWidth,r=this.srcImage.naturalHeight,a=t.width,l=t.height,s=t.maxWidth,c=t.maxHeight,d=!this.blob||"image/jpeg"===this.blob.type;a&&!l?l=r*a/o<<0:l&&!a?a=o*l/r<<0:(a=o,l=r),s&&a>s&&(l=r*(a=s)/o<<0),c&&l>c&&(a=o*(l=c)/r<<0);var u={width:a,height:l};for(var p in t)u[p]=t[p];var v=e.tagName.toLowerCase();"img"===v?e.src=function(e,t,i){var n=document.createElement("canvas");return Xs(e,n,t,i),n.toDataURL("image/jpeg",t.quality||.8)}(this.srcImage,u,d):"canvas"===v&&Xs(this.srcImage,e,u,d),"function"==typeof this.onrender&&this.onrender(e),i&&i(),this.blob&&(this.blob=null,Gs.revokeObjectURL(this.srcImage.src))}};var Ks=Gs.revokeObjectURL&&Gs;function Js(e,t){!e._objectURL||t&&t.noRevoke||(Zs.revokeObjectURL(e._objectURL),delete e._objectURL)}Zs.fetchBlob=function(e,t){t()},Zs.isInstanceOf=function(e,t){return Object.prototype.toString.call(t)==="[object "+e+"]"},Zs.transform=function(e,t,i,n,o){i(e,o)},Zs.onerror=function(e,t,i,n,o){Js(e,o),n&&n.call(e,t)},Zs.onload=function(e,t,i,n,o){Js(e,o),n&&Zs.transform(e,o,n,i,{originalWidth:e.naturalWidth||e.width,originalHeight:e.naturalHeight||e.height})},Zs.createObjectURL=function(e){return!!Ks&&Ks.createObjectURL(e)},Zs.revokeObjectURL=function(e){return!!Ks&&Ks.revokeObjectURL(e)},Zs.readFile=function(e,t,i){if(FileReader){var n=new FileReader;if(n.onload=n.onerror=t,n[i=i||"readAsDataURL"])return n[i](e),n}return!1};var $s="undefined"!=typeof Blob&&(Blob.prototype.slice||Blob.prototype.webkitSlice||Blob.prototype.mozSlice);Zs.blobSlice=$s&&function(){var e=this.slice||this.webkitSlice||this.mozSlice;return e.apply(this,arguments)},Zs.metaDataParsers={jpeg:{65505:[],65517:[]}},Zs.parseMetaData=function(e,t,i,n){n=n||{};var o=this,r=(i=i||{}).maxMetaDataSize||262144;!!("undefined"!=typeof DataView&&e&&e.size>=12&&"image/jpeg"===e.type&&Zs.blobSlice)&&Zs.readFile(Zs.blobSlice.call(e,0,r),(function(e){if(e.target.error)return console.log(e.target.error),void t(n);var r,a,l,s,c=e.target.result,d=new DataView(c),u=2,p=d.byteLength-4,v=u;if(65496===d.getUint16(0)){for(;u<p&&((r=d.getUint16(u))>=65504&&r<=65519||65534===r);){if(u+(a=d.getUint16(u+2)+2)>d.byteLength){console.log("Invalid meta data: Invalid segment size.");break}if(l=Zs.metaDataParsers.jpeg[r])for(s=0;s<l.length;s+=1)l[s].call(o,d,u,a,n,i);v=u+=a}!i.disableImageHead&&v>6&&(c.slice?n.imageHead=c.slice(0,v):n.imageHead=new Uint8Array(c).subarray(0,v))}else console.log("Invalid JPEG file: Missing JPEG marker.");t(n)}),"readAsArrayBuffer")||t(n)},Zs.hasMetaOption=function(e){return e&&e.meta};var Qs=Zs.transform;Zs.transform=function(e,t,i,n,o){Zs.hasMetaOption(t)?Zs.parseMetaData(n,(function(o){Qs.call(Zs,e,t,i,n,o)}),t,o):Qs.apply(Zs,arguments)},Zs.ExifMap=function(){return this},Zs.ExifMap.prototype.map={Orientation:274},Zs.ExifMap.prototype.get=function(e){return this[e]||this[this.map[e]]},Zs.getExifThumbnail=function(e,t,i){if(i&&!(t+i>e.byteLength))return Zs.createObjectURL(new Blob([e.buffer.slice(t,t+i)]));console.log("Invalid Exif data: Invalid thumbnLine truncated
|
||||
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,62 @@
|
||||
var ContentBuilder=function(){"use strict";function e(t){return(e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(t)}function t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function n(e,t,n){return t&&i(e.prototype,t),n&&i(e,n),e}var o,r,a,l,s,c,d,u,p=function(){function e(i){t(this,e),this.builder=i}return n(e,[{key:"cellSelected",value:function(){return document.querySelector(".cell-active")}},{key:"builderStuff",value:function(){return document.querySelector("#_cbhtml")}},{key:"cellNext",value:function(e){var t=new v,i=e.nextElementSibling;return i?t.hasClass(i,"is-row-tool")||t.hasClass(i,"is-rowadd-tool")?null:i:null}},{key:"out",value:function(e){if(this.builder){var t=this.builder.opts.lang[e];return t||(this.builder.checkLang&&console.log(e),e)}return e}},{key:"confirm",value:function(e,t){var i=this,n=new v,o='<div class="is-modal is-confirm">\n <div style="max-width:526px;text-align:center;">\n <p>'.concat(e,'</p>\n <button title="').concat(this.out("Delete"),'" class="input-ok classic">').concat(this.out("Delete"),"</button>\n </div>\n </div>"),r=this.builderStuff(),a=r.querySelector(".is-confirm");a||(n.appendHtml(r,o),a=r.querySelector(".is-confirm")),this.showModal(a,!1,(function(){a.parentNode.removeChild(a),t(!1)}),!0);var l=a.querySelector(".is-confirm .input-ok");n.addEventListener(l,"click",(function(){i.hideModal(a),a.parentNode.removeChild(a),t(!0)}))}},{key:"showModal",value:function(e,t,i,n){var o=this,r=new v;r.addClass(e,"active");var a,l=!1;if(this.builder?this.builder.opts.animateModal&&(l=!0,n||(l=!1)):n&&(l=!0),l&&this.builder){var s=document.querySelectorAll(this.builder.opts.container);Array.prototype.forEach.call(s,(function(e){e.style.transform="scale(0.98)",e.style.WebkitTransform="scale(0.98)",e.style.MozTransform="scale(0.98)"}))}if(!e.querySelector(".is-modal-overlay")&&(a=t?'<div class="is-modal-overlay" style="position:absolute;top:0;left:0;width:100%;height:100%;background:rgba(255,255,255,0.3);z-index:-1;"></div>':'<div class="is-modal-overlay" style="position:absolute;top:0;left:0;width:100%;height:100%;background:rgba(255,255,255,0.000001);z-index:-1;"></div>',e.insertAdjacentHTML("afterbegin",a),!t)){var c=e.querySelector(".is-modal-overlay");r.addEventListener(c,"click",(function(){i&&i(),o.hideModal(e)}))}}},{key:"hideModal",value:function(e){if(this.builder){var t=document.querySelectorAll(this.builder.opts.container);Array.prototype.forEach.call(t,(function(e){e.style.transform="",e.style.WebkitTransform="",e.style.MozTransform=""}))}(new v).removeClass(e,"active")}},{key:"fixLayout",value:function(e){var t=new v,i=e.childElementCount-2,n=this.builder.opts.row,o=this.builder.opts.cols,r=this.builder.opts.colequal;if(r.length>0)t.elementChildren(e).forEach((function(e){if(!t.hasClass(e,"is-row-tool")&&!t.hasClass(e,"is-rowadd-tool")){for(var n=0;n<=o.length-1;n++)t.removeClass(e,o[n]);for(var a=0;a<=r.length-1;a++)if(r[a].length===i){t.addClass(e,r[a][0]);break}1===i&&t.addClass(e,o[o.length-1])}}));else if(""!==n&&o.length>0){var a=0;t.elementChildren(e).forEach((function(e){if(!t.hasClass(e,"is-row-tool")&&!t.hasClass(e,"is-rowadd-tool")){a++;for(var n=0;n<=o.length-1;n++)t.removeClass(e,o[n]);1===i&&t.addClass(e,o[11]),2===i&&t.addClass(e,o[5]),3===i&&t.addClass(e,o[3]),4===i&&t.addClass(e,o[2]),5===i&&(5===a?t.addClass(e,o[3]):t.addClass(e,o[1])),6===i&&t.addClass(e,o[1]),7===i&&(a>=6?t.addClass(e,o[0]):t.addClass(e,o[1])),8===i&&(a>=5?t.addClass(e,o[0]):t.addClass(e,o[1])),9===i&&(a>=4?t.addClass(e,o[0]):t.addClass(e,o[1])),10===i&&(a>=3?t.addClass(e,o[0]):t.addClass(e,o[1])),11===i&&(a>=2?t.addClass(e,o[0]):t.addClass(e,o[1])),12===i&&t.addClass(e,o[0])}}))}}},{key:"addContent",value:function(e,t,i){var n,o=new v,r=this.cellSelected();if(r)n=r.parentNode;else{if(!(n=document.querySelector(".row-active")))return;t="row"}if("cell"===t||"cell-left"===t||"cell-right"===t){var a,l=4;if(this.builder.maxColumns&&(l=this.builder.maxColumns),n.childElementCount>=l+2)return alert(this.out("You have reached the maximum number of columns")),!1;if(this.builder.uo.saveForUndo(),""===this.builder.opts.row){var s=this.builder.opts.cellFormat,c=s.indexOf("</");e=s.substring(0,c)+e+s.substring(c),a=this.createElementFromHTML(e)}else{(a=r.cloneNode(!0)).removeAttribute("data-noedit"),a.removeAttribute("data-protected"),a.removeAttribute("data-module"),a.removeAttribute("data-module-desc"),a.removeAttribute("data-dialog-width"),a.removeAttribute("data-html"),a.removeAttribute("data-settings");for(var d=1;d<=20;d++)a.removeAttribute("data-html-"+d);a.removeAttributLine truncated
|
||||
/**!
|
||||
* Sortable 1.10.1
|
||||
* @author RubaXa <trash@rubaxa.org>
|
||||
* @author owenm <owen23355@gmail.com>
|
||||
* @license MIT
|
||||
*/
|
||||
function N(e){return(N="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function R(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function B(){return(B=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e}).apply(this,arguments)}function I(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{},n=Object.keys(i);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(i).filter((function(e){return Object.getOwnPropertyDescriptor(i,e).enumerable})))),n.forEach((function(t){R(e,t,i[t])}))}return e}function H(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}function D(e){return function(e){if(Array.isArray(e)){for(var t=0,i=new Array(e.length);t<e.length;t++)i[t]=e[t];return i}}(e)||function(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function F(e){if("undefined"!=typeof window&&window.navigator)return!!navigator.userAgent.match(e)}var P=F(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),U=F(/Edge/i),z=F(/firefox/i),W=F(/safari/i)&&!F(/chrome/i)&&!F(/android/i),j=F(/iP(ad|od|hone)/i),Y=F(/chrome/i)&&F(/android/i),X={capture:!1,passive:!1};function G(e,t,i){e.addEventListener(t,i,!P&&X)}function V(e,t,i){e.removeEventListener(t,i,!P&&X)}function Z(e,t){if(t){if(">"===t[0]&&(t=t.substring(1)),e)try{if(e.matches)return e.matches(t);if(e.msMatchesSelector)return e.msMatchesSelector(t);if(e.webkitMatchesSelector)return e.webkitMatchesSelector(t)}catch(e){return!1}return!1}}function K(e){return e.host&&e!==document&&e.host.nodeType?e.host:e.parentNode}function J(e,t,i,n){if(e){i=i||document;do{if(null!=t&&(">"===t[0]?e.parentNode===i&&Z(e,t):Z(e,t))||n&&e===i)return e;if(e===i)break}while(e=K(e))}return null}var $,Q=/\s+/g;function ee(e,t,i){if(e&&t)if(e.classList)e.classList[i?"add":"remove"](t);else{var n=(" "+e.className+" ").replace(Q," ").replace(" "+t+" "," ");e.className=(n+(i?" "+t:"")).replace(Q," ")}}function te(e,t,i){var n=e&&e.style;if(n){if(void 0===i)return document.defaultView&&document.defaultView.getComputedStyle?i=document.defaultView.getComputedStyle(e,""):e.currentStyle&&(i=e.currentStyle),void 0===t?i:i[t];t in n||-1!==t.indexOf("webkit")||(t="-webkit-"+t),n[t]=i+("string"==typeof i?"":"px")}}function ie(e,t){var i="";if("string"==typeof e)i=e;else do{var n=te(e,"transform");n&&"none"!==n&&(i=n+" "+i)}while(!t&&(e=e.parentNode));var o=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix;return o&&new o(i)}function ne(e,t,i){if(e){var n=e.getElementsByTagName(t),o=0,r=n.length;if(i)for(;o<r;o++)i(n[o],o);return n}return[]}function oe(){return P?document.documentElement:document.scrollingElement}function re(e,t,i,n,o){if(e.getBoundingClientRect||e===window){var r,a,l,s,c,d,u;if(e!==window&&e!==oe()?(a=(r=e.getBoundingClientRect()).top,l=r.left,s=r.bottom,c=r.right,d=r.height,u=r.width):(a=0,l=0,s=window.innerHeight,c=window.innerWidth,d=window.innerHeight,u=window.innerWidth),(t||i)&&e!==window&&(o=o||e.parentNode,!P))do{if(o&&o.getBoundingClientRect&&("none"!==te(o,"transform")||i&&"static"!==te(o,"position"))){var p=o.getBoundingClientRect();a-=p.top+parseInt(te(o,"border-top-width")),l-=p.left+parseInt(te(o,"border-left-width")),s=a+r.height,c=l+r.width;break}}while(o=o.parentNode);if(n&&e!==window){var v=ie(o||e),h=v&&v.a,f=v&&v.d;v&&(s=(a/=f)+(d/=f),c=(l/=h)+(u/=h))}return{top:a,left:l,bottom:s,right:c,width:u,height:d}}}function ae(e,t,i){for(var n=ue(e,!0),o=re(e)[t];n;){var r=re(n)[i];if(!("top"===i||"left"===i?o>=r:o<=r))return n;if(n===oe())break;n=ue(n,!1)}return!1}function le(e,t,i){for(var n=0,o=0,r=e.children;o<r.length;){if("none"!==r[o].style.display&&r[o]!==gt.ghost&&r[o]!==gt.dragged&&J(r[o],i.draggable,e,!1)){if(n===t)return r[o];n++}o++}return null}function se(e,t){for(var i=e.lastElementChild;i&&(i===gt.ghost||"none"===te(i,"display")||t&&!Z(i,t));)i=i.previousElementSibling;return i||null}function ce(e,t){var i=0;if(!e||!e.parentNode)return-1;for(;e=e.previousElementSibling;)"TEMPLATE"===e.nodeName.toUpperCase()||e===gt.clone||t&&!Z(e,t)||i++;return i}function de(e){var t=0,i=0,n=oe();if(e)do{var o=ie(e),r=o.a,a=o.d;t+=e.scrollLeft*r,i+=e.scrollTop*a}while(e!==n&&(e=e.parentNode));return[t,i]}function ue(e,t){if(!e||!e.geLine truncated
|
||||
/*!
|
||||
* Cropper.js v1.5.5
|
||||
* https://fengyuanchen.github.io/cropperjs
|
||||
*
|
||||
* Copyright 2015-present Chen Fengyuan
|
||||
* Released under the MIT license
|
||||
*
|
||||
* Date: 2019-08-04T02:26:31.160Z
|
||||
*/(e))}),!1);var h=document.querySelector(".is-design-list"),f=e.opts.snippetPath,g=!0;if(window.jQuery&&window.jQuery.fn.slick&&(g=!1),g)for(var m=0;m<e.opts.snippetJSON.snippets.length;m++)if(-1!==e.opts.snippetJSON.snippets[m].thumbnail.indexOf("element-slider.png")){e.opts.snippetJSON.snippets.splice(m,1);break}var y=1;e.opts.emailMode?e.opts.snippetJSON.snippets.forEach((function(t){t.id=y,t.category===e.opts.defaultEmailSnippetCategory+""&&Kt.appendHtml(h,'<div class="snippet-item" data-id="'+t.id+'" data-cat="'+t.category+'"><img src="'+f+t.thumbnail+'"></div>'),y++})):e.opts.snippetJSON.snippets.forEach((function(t){t.id=y,t.category===e.opts.defaultSnippetCategory+""&&Kt.appendHtml(h,'<div class="snippet-item" data-id="'+t.id+'" data-cat="'+t.category+'"><img src="'+f+t.thumbnail+'"></div>'),y++}));var b=navigator.userAgent,x=b.indexOf("Safari")>-1;if(b.indexOf("Chrome")>-1&&x&&(x=!1),new gt(h,{forceFallback:x,group:{name:"shared",pull:"clone",put:!1},sort:!1,animation:150,onMove:function(){var e=document.querySelector(".row-add-initial");e&&e.parentNode.removeChild(e)},onStart:function(){e.uo.saveForUndo();var t=document.querySelector(".is-sidebar-overlay");t&&(t.style.display="none")},onEnd:function(){var e=document.querySelector(".is-sidebar-overlay");e&&(e.style.display="block"),t.checkEmpty()}}),new O(document.querySelector(".snippet-cat"),{onChange:function(t){var i=t,n=h.querySelectorAll(".snippet-item"),o=!1;Array.prototype.forEach.call(n,(function(e){e.getAttribute("data-cat")===i&&(o=!0)})),o||e.opts.snippetJSON.snippets.forEach((function(e){e.category===i&&Kt.appendHtml(h,'<div class="snippet-item" data-id="'+e.id+'" data-cat="'+e.category+'"><img src="'+f+e.thumbnail+'"></div>')})),i&&(Array.prototype.forEach.call(n,(function(e){Kt.addClass(e,"hide")})),Array.prototype.forEach.call(n,(function(e){e.getAttribute("data-cat")===i&&(e.className=e.className.replace(/hide/g,""))})))}}),"#divSnippetList"===e.opts.snippetList){var w=v.querySelector("#divSnippetHandle");Kt.addEventListener(w,"click",(function(){$t(e),t.clearActiveCell(),t.clearControls()}));var S=window.innerWidth;e.opts.snippetOpen&&S>=960&&(v.style.cssText="transition: all ease 0.8s;",setTimeout((function(){$t(e)}),100),setTimeout((function(){v.style.cssText=""}),1300))}var C=v.querySelector("#divSnippetScrollUp"),E=v.querySelector("#divSnippetScrollDown");C.style.display="none",E.style.display="none"};function $t(e){var t=document.querySelector("#divSnippetList"),i=t.querySelector("#divSnippetHandle");Kt.hasClass(t,"active")?(Kt.removeClass(t,"active"),"right"===e.opts.sidePanel?i.innerHTML='<svg class="is-icon-flex" style="width:17px;height:17px;fill:rgba(0, 0, 0, 0.75);"><use xlink:href="#ion-ios-arrow-left"></use></svg>':i.innerHTML='<svg class="is-icon-flex" style="width:17px;height:17px;fill:rgba(0, 0, 0, 0.75);"><use xlink:href="#ion-ios-arrow-right"></use></svg>'):(Kt.addClass(t,"active"),"right"===e.opts.sidePanel?i.innerHTML='<svg class="is-icon-flex" style="width:17px;height:17px;fill:rgba(0, 0, 0, 0.75);"><use xlink:href="#ion-ios-arrow-right"></use></svg>':i.innerHTML='<svg class="is-icon-flex" style="width:17px;height:17px;fill:rgba(0, 0, 0, 0.75);"><use xlink:href="#ion-ios-arrow-left"></use></svg>')}function Qt(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function ei(e){return function(e){if(Array.isArray(e)){for(var t=0,i=new Array(e.length);t<e.length;t++)i[t]=e[t];return i}}(e)||function(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}var ti="undefined"!=typeof window&&void 0!==window.document,ii=ti?window:{},ni=!!ti&&"ontouchstart"in ii.document.documentElement,oi=!!ti&&"PointerEvent"in ii,ri="".concat("cropper","-crop"),ai="".concat("cropper","-disabled"),li="".concat("cropper","-hidden"),si="".concat("cropper","-hide"),ci="".concat("cropper","-invisible"),di="".concat("cropper","-modal"),ui="".concat("cropper","-move"),pi="".concat("cropper","Action"),vi="".concat("cropper","Preview"),hi=oi?"pointerdown":ni?"touchstart":"mousedown",fi=oi?"pointermove":ni?"touchmove":"mousemove",gi=oi?"pointerup pointercancel":ni?"touchend touchcancel":"mouseup",mi=/^e|w|s|n|se|sw|ne|nw|all|crop|move|zoom$/,yi=/^data:/,bi=/^data:image\/jpeg;base64,/,xi=/^img|canvas$/i,wi={viewMode:0,dragMode:"crop",initialAspectRatio:NaN,aspectRatio:NaN,data:null,preview:"",responsive:!0,restore:!0,checkCrossOrigin:!0,checkOrientation:!0,modal:!0,guides:!0,center:!0,highlight:!0,background:!0,autoCrop:!0,autoCropArea:.8,movable:!0,rotatable:!0,scalable:!0,zoomable:!0,zoomOnTouch:!0,zoomOnWheel:!0,wheelZoomRatio:.1,cropBoxMovable:!0,cropBoxResizable:!0,toggleDragModeOnDblclick:!0,minCanvasWidth:0,minCanvasHeight:0,minCropBoxWidth:0,minCropBoxHeight:0,minContainerWidth:200,minLine truncated
|
||||
/*! *****************************************************************************
|
||||
Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
||||
this file except in compliance with the License. You may obtain a copy of the
|
||||
License at http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
|
||||
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
|
||||
MERCHANTABLITY OR NON-INFRINGEMENT.
|
||||
|
||||
See the Apache Version 2.0 License for specific language governing permissions
|
||||
and limitations under the License.
|
||||
***************************************************************************** */var ta=function(e,t){return(ta=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)t.hasOwnProperty(i)&&(e[i]=t[i])})(e,t)};var ia=function(){return(ia=Object.assign||function(e){for(var t,i=1,n=arguments.length;i<n;i++)for(var o in t=arguments[i])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};
|
||||
/*! *****************************************************************************
|
||||
Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
||||
this file except in compliance with the License. You may obtain a copy of the
|
||||
License at http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
|
||||
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
|
||||
MERCHANTABLITY OR NON-INFRINGEMENT.
|
||||
|
||||
See the Apache Version 2.0 License for specific language governing permissions
|
||||
and limitations under the License.
|
||||
***************************************************************************** */
|
||||
var na=function(){return(na=Object.assign||function(e){for(var t,i=1,n=arguments.length;i<n;i++)for(var o in t=arguments[i])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};function oa(e,t,i,n){var o=ua(e),r=ua(t),a=ua(n);return aa(pa(n[0],va(o,a)),pa(n[0],va(r,a)),i[0])}function ra(e){return e.touches?ca(e.touches):[da(e)]}function aa(e,t,i){var n=e.clientX,o=e.clientY;return{clientX:n,clientY:o,deltaX:n-t.clientX,deltaY:o-t.clientY,distX:n-i.clientX,distY:o-i.clientY}}function la(e){return Math.sqrt(Math.pow(e[0].clientX-e[1].clientX,2)+Math.pow(e[0].clientY-e[1].clientY,2))}function sa(e,t,i){return e.map((function(e,n){return aa(e,t[n],i[n])}))}function ca(e){for(var t=Math.min(e.length,2),i=[],n=0;n<t;++n)i.push(da(e[n]));return i}function da(e){return{clientX:e.clientX,clientY:e.clientY}}function ua(e){return{clientX:(e[0].clientX+e[1].clientX)/2,clientY:(e[0].clientY+e[1].clientY)/2}}function pa(e,t){return{clientX:e.clientX+t.clientX,clientY:e.clientY+t.clientY}}function va(e,t){return{clientX:e.clientX-t.clientX,clientY:e.clientY-t.clientY}}var ha=function(){function e(e,t){var i=this;void 0===t&&(t={}),this.el=e,this.options={},this.flag=!1,this.pinchFlag=!1,this.datas={},this.isDrag=!1,this.isPinch=!1,this.isMouse=!1,this.isTouch=!1,this.prevClients=[],this.startClients=[],this.movement=0,this.startPinchClients=[],this.startDistance=0,this.customDist=[0,0],this.onDragStart=function(e){if(i.flag||!1!==e.cancelable){if(function(e){return e.touches&&e.touches.length>=2}(e)){if(!i.flag&&e.touches.length!==e.changedTouches.length)return;i.pinchFlag||i.onPinchStart(e)}if(!i.flag){var t=i.startClients[0]?i.startClients:ra(e);i.customDist=[0,0],i.flag=!0,i.isDrag=!1,i.startClients=t,i.prevClients=t,i.datas={},i.movement=0;var n=aa(t[0],i.prevClients[0],i.startClients[0]),o=i.options,r=o.dragstart,a=o.preventRightClick,l=o.preventDefault;(a&&3===e.which||!1===(r&&r(na({datas:i.datas,inputEvent:e},n))))&&(i.startClients=[],i.prevClients=[],i.flag=!1),i.flag&&l&&e.preventDefault()}}},this.onDrag=function(e,t){if(i.flag){var n=ra(e);i.pinchFlag&&i.onPinch(e,n);var o=i.move([0,0],e,n);if(o&&(o.deltaX||o.deltaY)){var r=i.options.drag;r&&r(na({},o,{isScroll:!!t,inputEvent:e}))}}},this.onDragEnd=function(e){if(i.flag){i.pinchFlag&&i.onPinchEnd(e),i.flag=!1;var t=i.options.dragend,n=i.prevClients,o=i.startClients,r=i.pinchFlag?oa(n,n,o,i.startPinchClients):aa(n[0],n[0],o[0]);i.startClients=[],i.prevClients=[],t&&t(na({datas:i.datas,isDrag:i.isDrag,inputEvent:e},r))}},this.options=na({container:e,preventRightClick:!0,preventDefault:!0,pinchThreshold:0,events:["touch","mouse"]},t);var n=this.options,o=n.container,r=n.events;if(this.isTouch=r.indexOf("touch")>-1,this.isMouse=r.indexOf("mouse")>-1,this.customDist=[0,0],this.isMouse&&(qr(e,"mousedown",this.onDragStart),qr(o,"mousemove",this.onDrag),qr(o,"mouseup",this.onDragEnd)),this.isTouch){var a={passive:!1};qr(e,"touchstart",this.onDragStart,a),qr(o,"touchmove",this.onDrag,a),qr(o,"touchend",this.onDragEnd,a)}}var t=e.prototype;return t.isDragging=function(){return this.isDrag},t.isFlag=function(){return this.flag},t.isPinching=function(){return this.isPinch},t.scrollBy=function(e,t,i,n){void 0===n&&(n=!0),this.flag&&(this.startClients.forEach((function(i){i.clientX-=e,i.clientY-=t})),this.prevClients.forEach((function(i){i.clientX-=e,i.clientY-=t})),n&&this.onDrag(i,!0))},t.move=function(e,t,i){var n=e[0],o=e[1];void 0===i&&(i=this.prevClients);var r=this.customDist,a=this.prevClients,l=this.startClients,s=this.pinchFlag?oa(i,a,l,this.startPinchClients):aa(i[0],a[0],l[0]);r[0]+=n,r[1]+=o,s.deltaX+=n,s.deltaY+=o;var c=s.deltaX,d=s.deltaY;return s.distX+=r[0],s.distY+=r[1],this.movement+=Math.sqrt(c*c+d*d),this.prevClients=i,this.isDrag=!0,na({datas:this.datas},s,{isScroll:!1,inputEvent:t})},t.onPinchStart=function(e){var t,i,n=this.options,o=n.pinchstart,r=n.pinchThreshold;if(!(this.isDrag&&this.movement>r)){var a=ca(e.changedTouches);if(this.pinchFlag=!0,(t=this.startClients).push.apply(t,a),(i=this.prevClients).push.apply(i,a),this.startDistance=la(this.prevClients),this.startPinchClients=this.prevClients.slice(),o){var l=this.prevClients,s=ua(l),c=aa(s,s,s);o(na({datas:this.datas,touches:sa(l,l,l)},c,{inputEvent:e}))}}},t.onPinch=function(e,t){if(this.flag&&this.pinchFlag){this.isPinch=!0;var i=this.options.pinch;if(i){var n=this.prevClients,o=this.startClients,r=aa(ua(t),ua(n),ua(o)),a=la(t);i(na({datas:this.datas,touches:sa(t,n,o),scale:a/this.startDistance,distance:a},r,{inputEvent:e}))}}},t.onPinchEnd=function(e){if(this.flag&&this.pinchFlag){var t=this.isPinch;this.isPinch=!1,this.pinchFlag=!1;var i=this.options.pinchend;if(i){var n=this.prevClients,o=this.startClients,r=aa(ua(n),ua(n),ua(o));i(na({datas:this.datas,isPinch:t,touches:sa(n,n,o)},r,{inputEvent:e})),this.isPinch=!1,this.pinchFlag=!1}}},t.unset=function(){var e=this.el,t=this.options.container;this.isMouse&&(Mr(e,"mousedown",this.onDragStart),Mr(t,"mousLine truncated
|
||||
/*! *****************************************************************************
|
||||
Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
||||
this file except in compliance with the License. You may obtain a copy of the
|
||||
License at http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
|
||||
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
|
||||
MERCHANTABLITY OR NON-INFRINGEMENT.
|
||||
|
||||
See the Apache Version 2.0 License for specific language governing permissions
|
||||
and limitations under the License.
|
||||
***************************************************************************** */var Sa,Ca="function"==typeof Map?void 0:(Sa=0,function(e){return e.__DIFF_KEY__||(e.__DIFF_KEY__=++Sa)}),Ea=function(e){function t(t){return void 0===t&&(t=[]),e.call(this,t,Ca)||this}return function(e,t){function i(){this.constructor=e}wa(e,t),e.prototype=null===t?Object.create(t):(i.prototype=t.prototype,new i)}(t,e),t}(xa),ka=function(e,t){return(ka=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)t.hasOwnProperty(i)&&(e[i]=t[i])})(e,t)};function La(e,t){function i(){this.constructor=e}ka(e,t),e.prototype=null===t?Object.create(t):(i.prototype=t.prototype,new i)}var Aa=function(){return(Aa=Object.assign||function(e){for(var t,i=1,n=arguments.length;i<n;i++)for(var o in t=arguments[i])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};function qa(e,t){return'data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="'+32*e+'px" height="'+32*e+'px" viewBox="0 0 32 32" ><path d="M 16,5 L 12,10 L 14.5,10 L 14.5,22 L 12,22 L 16,27 L 20,22 L 17.5,22 L 17.5,10 L 20, 10 L 16,5 Z" stroke-linejoin="round" stroke-width="1.2" fill="black" stroke="white" style="transform:rotate('+t+'deg);transform-origin: 16px 16px"></path></svg>'}var Ma=br(),_a=Ma.os.name.indexOf("ios")>-1||Ma.browser.name.indexOf("safari")>-1,Ta="moveable-",Oa=function(e,t){return t.replace(/([^}{]*){/gm,(function(t,i){return i.replace(/\.([^{,\s\d.]+)/g,"."+e+"$1")+"{"}))}(Ta,"\n{\n\tposition: fixed;\n\twidth: 0;\n\theight: 0;\n\tleft: 0;\n\ttop: 0;\n\tz-index: 3000;\n}\n.control-box {\n z-index: 0;\n}\n.line, .control {\n\tleft: 0;\n\ttop: 0;\n}\n.control {\n\tposition: absolute;\n\twidth: 14px;\n\theight: 14px;\n\tborder-radius: 50%;\n\tborder: 2px solid #fff;\n\tbox-sizing: border-box;\n\tbackground: #4af;\n\tmargin-top: -7px;\n margin-left: -7px;\n z-index: 10;\n will-change: transform;\n}\n.line {\n\tposition: absolute;\n\twidth: 1px;\n\theight: 1px;\n\tbackground: #4af;\n\ttransform-origin: 0px 0.5px;\n}\n.line.dashed {\n box-sizing: border-box;\n background: transparent;\n}\n.line.dashed.horizontal {\n border-top: 1px dashed #4af;\n}\n.line.dashed.vertical {\n border-left: 1px dashed #4af;\n}\n.line.rotation-line {\n\theight: 40px;\n\twidth: 1px;\n\ttransform-origin: 0.5px 39.5px;\n}\n.line.rotation-line .control {\n\tborder-color: #4af;\n\tbackground:#fff;\n\tcursor: alias;\n}\n.line.vertical {\n transform: translateX(-50%);\n}\n.line.horizontal {\n transform: translateY(-50%);\n}\n.line.vertical.bold {\n width: 2px;\n}\n.line.horizontal.bold {\n height: 2px;\n}\n.control.origin {\n\tborder-color: #f55;\n\tbackground: #fff;\n\twidth: 12px;\n\theight: 12px;\n\tmargin-top: -6px;\n\tmargin-left: -6px;\n\tpointer-events: none;\n}\n"+[0,15,30,45,60,75,90,105,120,135,150,165].map((function(e){return'\n.direction[data-rotation="'+e+'"] {\n\t'+function(e){var t=qa(1,e),i=qa(2,e),n=45*Math.round(e/45)%180,o=135===n?"nwse-resize":45===n?"nesw-resize":90===n?"ew-resize":"ns-resize";return"cursor:"+o+";cursor: url('"+t+"') 16 16, "+o+";cursor: -webkit-image-set(url('"+t+"') 1x, url('"+i+"') 2x) 16 16, "+o+";"}(e)+"\n}\n"})).join("\n")+"\n.group {\n z-index: -1;\n}\n.area {\n position: absolute;\n}\n.area-pieces {\n position: absolute;\n top: 0;\n left: 0;\n display: none;\n}\n.area.avoid {\n pointer-events: none;\n}\n.area.avoid+.area-pieces {\n display: block;\n}\n.area-piece {\n position: absolute;\n}\n"+(_a?':global svg *:before {\n\tcontent:"";\n\ttransform-origin: inherit;\n}':"")+"\n"),Na=[[0,1,2],[1,0,3],[2,0,3],[3,1,2]],Ra=1e-7,Ba=Math.pow(10,10),Ia=-Ba,Ha={n:[0,1],s:[2,3],w:[2,0],e:[1,3],nw:[0],ne:[1],sw:[2],se:[3]},Da={n:0,s:180,w:270,e:90,nw:315,ne:45,sw:225,se:135};function Fa(e,t){return[e[0]*t[0],e[1]*t[1]]}function Pa(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return bn.apply(void 0,[Ta].concat(e))}function Ua(){return Zr(3)}function za(e){return e&&"none"!==e?Er(e)?e:function(e){var t=/([^(]*)\(([\s\S]*)\)([\s\S]*)/g.exec(e);return!t||t.length<4?{}:{prefix:t[1],value:t[2],suffix:t[3]}}(e).value.split(/s*,\s*/g).map((function(e){return parseFloat(e)})):[1,0,0,1,0,0]}function Wa(e,t,i){return Dr(t,Jr(i,t),e,Jr(i.map((function(e){return-e})),t))}function ja(e){return Ya(ml(e,":before")).map((function(t,i){var n=Lr(t),o=n.value,r=n.unit;return o*function(e,t,i){return"%"===t?e.ownerSVGElement.viewBox.baseVal[i?"width":"height"]/100:1}(e,r,0===i)}))}function Ya(e){var t=e.transformOrigin;return t?t.split(" "):["0","0"]}function Xa(e,t,i){for(var n=document.body,o=!e||i?e:e.parentElement,r=!1,a="relative";o&&o!==n;){t===o&&(r=!0);var l=ml(o),s=l.transform;if("static"!==(a=l.position)||s&&"none"!==s)break;o=o.parentElement,a="relative"}return{isStatic:"static"===a,isEnd:r||!o||o===n,offsetParent:o||n}}function Ga(e,t,i,n){var o,r,a,l=e,s=[],c="svg"!==l.tagName.toLowerCaLine truncated
|
||||
/*! Mega pixel image rendering library for iOS6 Safari | Copyright (c) 2012 Shinichi Tomita <shinichi.tomita@gmail.com> | MIT license | https://github.com/stomita/ios-imagefile-megapixel */
|
||||
function(e){var t=e.naturalWidth;if(t*e.naturalHeight>1048576){var i=document.createElement("canvas");i.width=i.height=1;var n=i.getContext("2d");return n.drawImage(e,1-t,0),0===n.getImageData(0,0,1,1).data[3]}return!1}(e)&&(o/=2,r/=2);var c=1024,d=document.createElement("canvas");d.width=d.height=c;for(var u=d.getContext("2d"),p=n?function(e,t,i){var n=document.createElement("canvas");n.width=1,n.height=i;var o=n.getContext("2d");o.drawImage(e,0,0);for(var r=o.getImageData(0,0,1,i).data,a=0,l=i,s=i;s>a;){0===r[4*(s-1)+3]?l=s:a=s,s=l+a>>1}var c=s/i;return 0===c?1:c}(e,0,r):1,v=Math.ceil(c*a/o),h=Math.ceil(c*l/r/p),f=0,g=0;f<r;){for(var m=0,y=0;m<o;)u.clearRect(0,0,c,c),u.drawImage(e,-m,-f),s.drawImage(d,0,0,c,c,y,g,v,h),m+=c,y+=v;f+=c,g+=h}s.restore(),d=u=null}}var Gs=window.URL&&window.URL.createObjectURL?window.URL:window.webkitURL&&window.webkitURL.createObjectURL?window.webkitURL:null;function Vs(e){if(window.Blob&&e instanceof Blob){if(!Gs)throw Error("No createObjectURL function found to create blob url");var t=new Ys;t.src=Gs.createObjectURL(e),this.blob=e,e=t}if(!e.naturalWidth&&!e.naturalHeight){var i=this;e.onload=e.onerror=function(){var e=i.imageLoadListeners;if(e){i.imageLoadListeners=null;for(var t=0,n=e.length;t<n;t++)e[t]()}},this.imageLoadListeners=[]}this.srcImage=e}function Zs(e,t,i){var n,o=document.createElement("img");return o.onerror=function(n){return Zs.onerror(o,n,e,t,i)},o.onload=function(n){return Zs.onload(o,n,e,t,i)},"string"==typeof e?(Zs.fetchBlob(e,(function(t){t?(e=t,n=Zs.createObjectURL(e)):(n=e,i&&i.crossOrigin&&(o.crossOrigin=i.crossOrigin)),o.src=n}),i),o):Zs.isInstanceOf("Blob",e)||Zs.isInstanceOf("File",e)?(n=o._objectURL=Zs.createObjectURL(e))?(o.src=n,o):Zs.readFile(e,(function(e){var i=e.target;i&&i.result?o.src=i.result:t&&t(e)})):void 0}Vs.prototype.render=function(e,t,i){if(this.imageLoadListeners){var n=this;this.imageLoadListeners.push((function(){n.render(e,t,i)}))}else{t=t||{};var o=this.srcImage.naturalWidth,r=this.srcImage.naturalHeight,a=t.width,l=t.height,s=t.maxWidth,c=t.maxHeight,d=!this.blob||"image/jpeg"===this.blob.type;a&&!l?l=r*a/o<<0:l&&!a?a=o*l/r<<0:(a=o,l=r),s&&a>s&&(l=r*(a=s)/o<<0),c&&l>c&&(a=o*(l=c)/r<<0);var u={width:a,height:l};for(var p in t)u[p]=t[p];var v=e.tagName.toLowerCase();"img"===v?e.src=function(e,t,i){var n=document.createElement("canvas");return Xs(e,n,t,i),n.toDataURL("image/jpeg",t.quality||.8)}(this.srcImage,u,d):"canvas"===v&&Xs(this.srcImage,e,u,d),"function"==typeof this.onrender&&this.onrender(e),i&&i(),this.blob&&(this.blob=null,Gs.revokeObjectURL(this.srcImage.src))}};var Ks=Gs.revokeObjectURL&&Gs;function Js(e,t){!e._objectURL||t&&t.noRevoke||(Zs.revokeObjectURL(e._objectURL),delete e._objectURL)}Zs.fetchBlob=function(e,t){t()},Zs.isInstanceOf=function(e,t){return Object.prototype.toString.call(t)==="[object "+e+"]"},Zs.transform=function(e,t,i,n,o){i(e,o)},Zs.onerror=function(e,t,i,n,o){Js(e,o),n&&n.call(e,t)},Zs.onload=function(e,t,i,n,o){Js(e,o),n&&Zs.transform(e,o,n,i,{originalWidth:e.naturalWidth||e.width,originalHeight:e.naturalHeight||e.height})},Zs.createObjectURL=function(e){return!!Ks&&Ks.createObjectURL(e)},Zs.revokeObjectURL=function(e){return!!Ks&&Ks.revokeObjectURL(e)},Zs.readFile=function(e,t,i){if(FileReader){var n=new FileReader;if(n.onload=n.onerror=t,n[i=i||"readAsDataURL"])return n[i](e),n}return!1};var $s="undefined"!=typeof Blob&&(Blob.prototype.slice||Blob.prototype.webkitSlice||Blob.prototype.mozSlice);Zs.blobSlice=$s&&function(){var e=this.slice||this.webkitSlice||this.mozSlice;return e.apply(this,arguments)},Zs.metaDataParsers={jpeg:{65505:[],65517:[]}},Zs.parseMetaData=function(e,t,i,n){n=n||{};var o=this,r=(i=i||{}).maxMetaDataSize||262144;!!("undefined"!=typeof DataView&&e&&e.size>=12&&"image/jpeg"===e.type&&Zs.blobSlice)&&Zs.readFile(Zs.blobSlice.call(e,0,r),(function(e){if(e.target.error)return console.log(e.target.error),void t(n);var r,a,l,s,c=e.target.result,d=new DataView(c),u=2,p=d.byteLength-4,v=u;if(65496===d.getUint16(0)){for(;u<p&&((r=d.getUint16(u))>=65504&&r<=65519||65534===r);){if(u+(a=d.getUint16(u+2)+2)>d.byteLength){console.log("Invalid meta data: Invalid segment size.");break}if(l=Zs.metaDataParsers.jpeg[r])for(s=0;s<l.length;s+=1)l[s].call(o,d,u,a,n,i);v=u+=a}!i.disableImageHead&&v>6&&(c.slice?n.imageHead=c.slice(0,v):n.imageHead=new Uint8Array(c).subarray(0,v))}else console.log("Invalid JPEG file: Missing JPEG marker.");t(n)}),"readAsArrayBuffer")||t(n)},Zs.hasMetaOption=function(e){return e&&e.meta};var Qs=Zs.transform;Zs.transform=function(e,t,i,n,o){Zs.hasMetaOption(t)?Zs.parseMetaData(n,(function(o){Qs.call(Zs,e,t,i,n,o)}),t,o):Qs.apply(Zs,arguments)},Zs.ExifMap=function(){return this},Zs.ExifMap.prototype.map={Orientation:274},Zs.ExifMap.prototype.get=function(e){return this[e]||this[this.map[e]]},Zs.getExifThumbnail=function(e,t,i){if(i&&!(t+i>e.byteLength))return Zs.createObjectURL(new Blob([e.buffer.slice(t,t+i)]));console.log("Invalid Exif data: Invalid thumbnLine truncated
|
||||
@@ -0,0 +1,204 @@
|
||||
var _txt = new Array();
|
||||
_txt["Bold"] = "Bold";
|
||||
_txt["Italic"] = "Italic";
|
||||
_txt["Hyperlink"] = "Hyperlink";
|
||||
_txt["Align"] = "Align";
|
||||
_txt["Paragraph"] = "Paragraph";
|
||||
_txt["Color"] = "Color";
|
||||
_txt["Formatting"] = "Formatting";
|
||||
_txt["List"] = "List";
|
||||
_txt["Text Settings"] = "Text Settings";
|
||||
_txt["Icon"] = "Icon";
|
||||
_txt["Clean"] = "Clean";
|
||||
_txt["Font"] = "Font";
|
||||
_txt["Previous"] = "Previous";
|
||||
_txt["Next"] = "Next";
|
||||
_txt["More"] = "More";
|
||||
_txt["Move Up"] = "Move Up";
|
||||
_txt["Move Down"] = "Move Down";
|
||||
_txt["Move Left"] = "Move Left";
|
||||
_txt["Move Right"] = "Move Right";
|
||||
_txt["Delete"] = "Delete";
|
||||
_txt["Add"] = "Add";
|
||||
_txt["Move"] = "Move";
|
||||
_txt["Duplicate"] = "Duplicate";
|
||||
_txt["Decrease"] = "Decrease";
|
||||
_txt["Increase"] = "Increase";
|
||||
_txt["HTML"] = "HTML";
|
||||
_txt["Headline"] = "Headline";
|
||||
_txt["Image"] = "Image";
|
||||
_txt["Heading 1"] = "Heading 1";
|
||||
_txt["Heading 2"] = "Heading 2";
|
||||
_txt["Heading 3"] = "Heading 3";
|
||||
_txt["Quote"] = "Quote";
|
||||
_txt["Preformatted"] = "Preformatted";
|
||||
_txt["Table"] = "Table";
|
||||
_txt["Spacer"] = "Spacer";
|
||||
_txt["Horizontal Line"] = "Horizontal Line";
|
||||
_txt["More..."] = "More...";
|
||||
_txt["Enlarge"] = "Enlarge";
|
||||
_txt["Ok"] = "Ok";
|
||||
_txt["Align Left"] = "Align Left";
|
||||
_txt["Align Center"] = "Align Center";
|
||||
_txt["Align Right"] = "Align Right";
|
||||
_txt["Align Full"] = "Align Full";
|
||||
_txt["Bullets"] = "Bullets";
|
||||
_txt["Numbering"] = "Numbering";
|
||||
_txt["Indent"] = "Indent";
|
||||
_txt["Outdent"] = "Outdent";
|
||||
_txt["Heading 4"] = "Heading 4";
|
||||
_txt["Underline"] = "Underline";
|
||||
_txt["Strikethrough"] = "Strikethrough";
|
||||
_txt["Superscript"] = "Superscript";
|
||||
_txt["Subscript"] = "Subscript";
|
||||
_txt["Uppercase"] = "Uppercase";
|
||||
_txt["Clear"] = "Clear";
|
||||
_txt["Choose.."] = "Choose..";
|
||||
_txt["Forecolor"] = "Forecolor";
|
||||
_txt["Backcolor"] = "Backcolor";
|
||||
_txt["Apply"] = "Apply";
|
||||
_txt["Cancel"] = "Cancel";
|
||||
_txt["Change Image"] = "Change Image";
|
||||
_txt["Link"] = "Link";
|
||||
_txt["Edit"] = "Edit";
|
||||
_txt["Source"] = "Source";
|
||||
_txt["Settings"] = "Settings";
|
||||
_txt["Change Icon"] = "Change Icon";
|
||||
_txt["Edit Table"] = "Edit Table";
|
||||
_txt["Select"] = "Select";
|
||||
_txt["Open New Window"] = "Open New Window";
|
||||
_txt["Text"] = "Text";
|
||||
_txt["Title"] = "Title";
|
||||
_txt["Free"] = "Free";
|
||||
_txt["Style"] = "Style";
|
||||
_txt["Layout"] = "Layout";
|
||||
_txt["Background"] = "Background";
|
||||
_txt["Select Color"] = "Select Color";
|
||||
_txt["Text Color"] = "Text Color";
|
||||
_txt["Border Thickness"] = "Border Thickness";
|
||||
_txt["Border Color"] = "Border Color";
|
||||
_txt["Apply To"] = "Apply To";
|
||||
_txt["Current Row"] = "Current Row";
|
||||
_txt["Current Column"] = "Current Column";
|
||||
_txt["Even Rows"] = "Even Rows";
|
||||
_txt["Odd Rows"] = "Odd Rows";
|
||||
_txt["Current Cell"] = "Current Cell";
|
||||
_txt["Insert Row"] = "Insert Row";
|
||||
_txt["Above"] = "Above";
|
||||
_txt["Below"] = "Below";
|
||||
_txt["Left"] = "Left";
|
||||
_txt["Right"] = "Right";
|
||||
_txt["Row"] = "Row";
|
||||
_txt["Column"] = "Column";
|
||||
_txt["Merge"] = "Merge";
|
||||
_txt["Merge Cell"] = "Merge Cell";
|
||||
_txt["css"] = "css";
|
||||
_txt["Class"] = "Class";
|
||||
_txt["Box"] = "Box";
|
||||
_txt["Spacing"] = "Spacing";
|
||||
_txt["Border"] = "Border";
|
||||
_txt["Corners"] = "Corners";
|
||||
_txt["Shadow"] = "Shadow";
|
||||
_txt["Display"] = "Display";
|
||||
_txt["Position"] = "Position";
|
||||
_txt["Effects"] = "Effects";
|
||||
_txt["Attributes"] = "Attributes";
|
||||
_txt["Animation"] = "Animation";
|
||||
_txt["Background Color"] = "Background Color";
|
||||
_txt["Gradient"] = "Gradient";
|
||||
_txt["Dimension"] = "Dimension";
|
||||
_txt["Responsive Positioning"] = "Responsive Positioning";
|
||||
_txt["Reset margin left on small screen"] = "Reset margin left on small screen";
|
||||
_txt["Reset margin right on small screen"] = "Reset margin right on small screen";
|
||||
_txt["Individual Sides"] = "Individual Sides";
|
||||
_txt["Select Font"] = "Select Font";
|
||||
_txt["Animate"] = "Animate";
|
||||
_txt["Delay"] = "Delay";
|
||||
_txt["Duration"] = "Duration";
|
||||
_txt["Animate Once"] = "Animate Once";
|
||||
_txt["Test"] = "Test";
|
||||
_txt["TEST"] = "TEST";
|
||||
_txt["Custom"] = "Custom";
|
||||
_txt["Custom Code (Javascript Allowed)"] = "Custom Code (Javascript Allowed)";
|
||||
_txt["Module Settings"] = "Module Settings";
|
||||
_txt["Drag and drop an image or click to browse."] = "Drag and drop an image or click to browse.";
|
||||
_txt["Are you sure you want to delete this block?"] = "Are you sure you want to delete this block?";
|
||||
_txt["Back"] = "Back";
|
||||
_txt["Or Specify Image Source"] = "Or Specify Image Source";
|
||||
_txt["Preferences"] = "Preferences";
|
||||
_txt["Hide element tool"] = "Hide element tool";
|
||||
_txt["Hide column tool"] = "Hide column tool";
|
||||
_txt["Line"] = "Line";
|
||||
_txt["Hide column HTML editor"] = "Hide column HTML editor";
|
||||
_txt["Hide row HTML editor"] = "Hide row HTML editor";
|
||||
_txt["Hide row move (up/down) buttons"] = "Hide row move (up/down) buttons";
|
||||
_txt["HTML syntax highlighting"] = "HTML syntax highlighting";
|
||||
_txt["Scrollable Editing Toolbar"] = "Scrollable Editing Toolbar";
|
||||
_txt["Toolbar position"] = "Toolbar position";
|
||||
_txt["Top"] = "Top";
|
||||
_txt["Left"] = "Left";
|
||||
_txt["Right"] = "Right";
|
||||
_txt["Toolbar visibility"] = "Toolbar visibility";
|
||||
_txt["Auto"] = "Auto";
|
||||
_txt["Always Visible"] = "Always Visible";
|
||||
_txt["Paste result"] = "Paste result";
|
||||
_txt["HTML (without styles)"] = "HTML (without styles)";
|
||||
_txt["HTML (with styles)"] = "HTML (with styles)";
|
||||
_txt["Text only"] = "Text only";
|
||||
_txt["Add Snippet"] = "Add Snippet";
|
||||
_txt["Grid Tool"] = "Grid Tool";
|
||||
_txt["Element Tool"] = "Element Tool";
|
||||
_txt["Builder Mode"] = "Builder Mode";
|
||||
_txt["Default"] = "Default";
|
||||
_txt["Minimal"] = "Minimal";
|
||||
_txt["Hide outline"] = "Hide outline";
|
||||
_txt["Hide element highlight"] = "Hide element highlight";
|
||||
_txt["Row tool position"] = "Row tool position";
|
||||
_txt["Add (+) button placement"] = "Add (+) button placement";
|
||||
_txt["Between Blocks (left)"] = "Between Blocks (left)";
|
||||
_txt["Between Blocks (center)"] = "Between Blocks (center)";
|
||||
_txt["Outline Mode"] = "Outline Mode";
|
||||
_txt["Row & column"] = "Row & column";
|
||||
_txt["Row only"] = "Row only";
|
||||
_txt["Draggable blocks without handle"] = "Draggable blocks without handle";
|
||||
_txt["Animated drag to sort"] = "Animated drag to sort";
|
||||
_txt["Open snippets sidebar on start"] = "Open snippets sidebar on start";
|
||||
_txt["Scrollable toolbar (top only)"] = "Scrollable toolbar (top only)";
|
||||
_txt["Please select a block"] = "Please select a block";
|
||||
_txt["Open snippet sidebar on start"] = "Open snippet sidebar on start";
|
||||
_txt["Hide snippet handle"] = "Hide snippet handle";
|
||||
_txt["Undo"] = "Undo";
|
||||
_txt["Redo"] = "Redo";
|
||||
_txt["Empty"] = "Empty";
|
||||
_txt["+ Click to add content"] = "+ Click to add content";
|
||||
_txt["B"] = "B";
|
||||
_txt["W"] = "W";
|
||||
_txt["Outline Style"] = "Outline Style";
|
||||
_txt["Colored"] = "Colored";
|
||||
_txt["Gray"] = "Gray";
|
||||
_txt["Hide Outline"] = "Hide Outline";
|
||||
_txt["Hide Column Tool"] = "Hide Column Tool";
|
||||
_txt["Row Tool Position"] = "Row Tool Position";
|
||||
_txt["Tool Style"] = "Tool Style";
|
||||
_txt["Hide Snippet (+) Tool"] = "Hide Snippet (+) Tool";
|
||||
_txt["Tool Outline"] = "Tool Outline";
|
||||
_txt["Button"] = "Button";
|
||||
_txt["Button Editor"] = "Button Editor";
|
||||
_txt["Edit Button"] = "Edit Button";
|
||||
_txt["Grid Editor"] = "Grid Editor";
|
||||
_txt["Outline"] = "Outline";
|
||||
_txt["Font Size"] = "Font Size";
|
||||
_txt["Line Spacing"] = "Line Spacing";
|
||||
_txt["Letter Spacing"] = "Letter Spacing";
|
||||
_txt["Close"] = "Close";
|
||||
_txt["Search & Replace"] = "Search & Replace";
|
||||
_txt["Word Count"] = "Word Count";
|
||||
_txt["Add to Left"] = "Add to Left";
|
||||
_txt["Add to Right"] = "Add to Right";
|
||||
_txt["Border Top Color"] = "Border Top Color";
|
||||
_txt["Border Bottom Color"] = "Border Bottom Color";
|
||||
_txt["Border Left Color"] = "Border Left Color";
|
||||
_txt["Border Right Color"] = "Border Right Color";
|
||||
_txt["Snippets sidebar visibility"] = "Snippets sidebar visibility";
|
||||
_txt["You have reached the maximum number of columns"] = "You have reached the maximum number of columns";
|
||||
|
||||
@@ -0,0 +1,204 @@
|
||||
var _txt = new Array();
|
||||
_txt["Bold"] = "Bold";
|
||||
_txt["Italic"] = "Italic";
|
||||
_txt["Hyperlink"] = "Lien internet";
|
||||
_txt["Align"] = "Alignement";
|
||||
_txt["Paragraph"] = "Paragraphe";
|
||||
_txt["Color"] = "Couleur";
|
||||
_txt["Formatting"] = "Formatage";
|
||||
_txt["List"] = "Liste";
|
||||
_txt["Text Settings"] = "Paramètres texte";
|
||||
_txt["Icon"] = "Icône";
|
||||
_txt["Clean"] = "Clean";
|
||||
_txt["Font"] = "Police de caractère";
|
||||
_txt["Previous"] = "Précédent";
|
||||
_txt["Next"] = "Suivant";
|
||||
_txt["More"] = "Plus";
|
||||
_txt["Move Up"] = "Vers le haut";
|
||||
_txt["Move Down"] = "Vers le bas";
|
||||
_txt["Move Left"] = "Vers la gauche";
|
||||
_txt["Move Right"] = "Vers la droite";
|
||||
_txt["Delete"] = "Effacer";
|
||||
_txt["Add"] = "Ajouter";
|
||||
_txt["Move"] = "Déplacer";
|
||||
_txt["Duplicate"] = "Copier";
|
||||
_txt["Decrease"] = "Diminuer";
|
||||
_txt["Increase"] = "Augmenter";
|
||||
_txt["HTML"] = "HTML";
|
||||
_txt["Headline"] = "Titre";
|
||||
_txt["Image"] = "Image";
|
||||
_txt["Heading 1"] = "Titre 1";
|
||||
_txt["Heading 2"] = "Titre 2";
|
||||
_txt["Heading 3"] = "Titre 3";
|
||||
_txt["Quote"] = "Quote";
|
||||
_txt["Preformatted"] = "Preformaté";
|
||||
_txt["Table"] = "Table";
|
||||
_txt["Spacer"] = "Espace";
|
||||
_txt["Horizontal Line"] = "Ligne horizontale";
|
||||
_txt["More..."] = "Plus...";
|
||||
_txt["Enlarge"] = "Agrandir";
|
||||
_txt["Ok"] = "Ok";
|
||||
_txt["Align Left"] = "Alignement à Gauche";
|
||||
_txt["Align Center"] = "Alignement au Centre";
|
||||
_txt["Align Right"] = "Alignement à Droite";
|
||||
_txt["Align Full"] = "Justifier";
|
||||
_txt["Bullets"] = "Boules";
|
||||
_txt["Numbering"] = "Numbres";
|
||||
_txt["Indent"] = "Indentation";
|
||||
_txt["Outdent"] = "Outdent";
|
||||
_txt["Heading 4"] = "Titre 4";
|
||||
_txt["Underline"] = "Souligner";
|
||||
_txt["Strikethrough"] = "Barrer";
|
||||
_txt["Superscript"] = "Superscript";
|
||||
_txt["Subscript"] = "Subscript";
|
||||
_txt["Uppercase"] = "Majuscule";
|
||||
_txt["Clear"] = "Effacer";
|
||||
_txt["Choose.."] = "Choisir..";
|
||||
_txt["Forecolor"] = "Couleur 1er plan";
|
||||
_txt["Backcolor"] = "Couleur arrière plan";
|
||||
_txt["Apply"] = "Appliquer";
|
||||
_txt["Cancel"] = "Annuler";
|
||||
_txt["Change Image"] = "Changer Image";
|
||||
_txt["Link"] = "Lien";
|
||||
_txt["Edit"] = "Editer";
|
||||
_txt["Source"] = "Source";
|
||||
_txt["Settings"] = "Paramètres";
|
||||
_txt["Change Icon"] = "Changer Icône";
|
||||
_txt["Edit Table"] = "Editer Table";
|
||||
_txt["Select"] = "Selectionner";
|
||||
_txt["Open New Window"] = "Ouvrir nouvelle fenêtre";
|
||||
_txt["Text"] = "Texte";
|
||||
_txt["Title"] = "Titre";
|
||||
_txt["Free"] = "Free";
|
||||
_txt["Style"] = "Style";
|
||||
_txt["Layout"] = "Disposition";
|
||||
_txt["Background"] = "Fond";
|
||||
_txt["Select Color"] = "Selectionner Couleur";
|
||||
_txt["Text Color"] = "Couleur Texte";
|
||||
_txt["Border Thickness"] = "Epaisseur Bordure";
|
||||
_txt["Border Color"] = "Couleur Bordure";
|
||||
_txt["Apply To"] = "Appliquer à";
|
||||
_txt["Current Row"] = "Ligne en cours";
|
||||
_txt["Current Column"] = "Colonne en cours";
|
||||
_txt["Even Rows"] = "Lignes paires";
|
||||
_txt["Odd Rows"] = "Lignes impaires";
|
||||
_txt["Current Cell"] = "Cellule sélectionnée";
|
||||
_txt["Insert Row"] = "Insérer ligne";
|
||||
_txt["Above"] = "Au-dessus";
|
||||
_txt["Below"] = "En-dessous";
|
||||
_txt["Left"] = "Gauche";
|
||||
_txt["Right"] = "Droite";
|
||||
_txt["Row"] = "Ligne";
|
||||
_txt["Column"] = "Colonne";
|
||||
_txt["Merge"] = "Fusionner";
|
||||
_txt["Merge Cell"] = "Fusionner cellules";
|
||||
_txt["css"] = "css";
|
||||
_txt["Class"] = "Class";
|
||||
_txt["Box"] = "Box";
|
||||
_txt["Spacing"] = "Espacement";
|
||||
_txt["Border"] = "Bordure";
|
||||
_txt["Corners"] = "Coins";
|
||||
_txt["Shadow"] = "Ombre";
|
||||
_txt["Display"] = "Affichage";
|
||||
_txt["Position"] = "Position";
|
||||
_txt["Effects"] = "Effets";
|
||||
_txt["Attributes"] = "Attribus";
|
||||
_txt["Animation"] = "Animation";
|
||||
_txt["Background Color"] = "Couleur de fond";
|
||||
_txt["Gradient"] = "Gradient";
|
||||
_txt["Dimension"] = "Dimension";
|
||||
_txt["Responsive Positioning"] = "Positionnement responsif";
|
||||
_txt["Reset margin left on small screen"] = "Reset marge de gauche sur petit écran";
|
||||
_txt["Reset margin right on small screen"] = "Reset marge de droite sur petit écran";
|
||||
_txt["Individual Sides"] = "Individual Sides";
|
||||
_txt["Select Font"] = "Selectionner Police de caractère";
|
||||
_txt["Animate"] = "Animer";
|
||||
_txt["Delay"] = "Retard";
|
||||
_txt["Duration"] = "Durée";
|
||||
_txt["Animate Once"] = "Animer une fois";
|
||||
_txt["Test"] = "Teste";
|
||||
_txt["TEST"] = "TESTE";
|
||||
_txt["Custom"] = "Custom";
|
||||
_txt["Custom Code (Javascript Allowed)"] = "Custom Code (Javascript Accepté)";
|
||||
_txt["Module Settings"] = "Paramètres module";
|
||||
_txt["Drag and drop an image or click to browse."] = "Glisser - déposer une image ou cliquer pour parcourir.";
|
||||
_txt["Are you sure you want to delete this block?"] = "Etes vous sûre de vouloir effacer ce block ?";
|
||||
_txt["Back"] = "Retour";
|
||||
_txt["Or Specify Image Source"] = "Ou spécifier Image Source";
|
||||
_txt["Preferences"] = "Préférences";
|
||||
_txt["Hide element tool"] = "Masquer outil élément";
|
||||
_txt["Hide column tool"] = "Masquer outil colonne";
|
||||
_txt["Line"] = "Ligne";
|
||||
_txt["Hide column HTML editor"] = "Masquer éditeur HTML de colonne";
|
||||
_txt["Hide row HTML editor"] = "Masquer éditeur HTML de ligne";
|
||||
_txt["Hide row move (up/down) buttons"] = "Masquer boutons de déplacement de ligne (haut/bas)";
|
||||
_txt["HTML syntax highlighting"] = "syntaxe HTML colorisé";
|
||||
_txt["Scrollable Editing Toolbar"] = "Barre d'outils Scrollable";
|
||||
_txt["Toolbar position"] = "Position Barre d'outils";
|
||||
_txt["Top"] = "Top";
|
||||
_txt["Left"] = "Gauche";
|
||||
_txt["Right"] = "Droite";
|
||||
_txt["Toolbar visibility"] = "Visibilité barre d'outils";
|
||||
_txt["Auto"] = "Auto";
|
||||
_txt["Always Visible"] = "Toujours Visible";
|
||||
_txt["Paste result"] = "Coller résultat";
|
||||
_txt["HTML (without styles)"] = "HTML (sans styles)";
|
||||
_txt["HTML (with styles)"] = "HTML (avec styles)";
|
||||
_txt["Text only"] = "Texte seulement";
|
||||
_txt["Add Snippet"] = "Ajouter Module";
|
||||
_txt["You can add max 4 column in a row"] = "Vous pouvez ajouter max 4 colonnes dans une ligne";
|
||||
_txt["Grid Tool"] = "Outil grille";
|
||||
_txt["Element Tool"] = "Outil Elément";
|
||||
_txt["Builder Mode"] = "Mode Builder";
|
||||
_txt["Default"] = "Défaut";
|
||||
_txt["Minimal"] = "Minimal";
|
||||
_txt["Hide outline"] = "Masquer contour";
|
||||
_txt["Hide element highlight"] = "Masquer élément surbrillance";
|
||||
_txt["Row tool position"] = "Outil position ligne";
|
||||
_txt["Add (+) button placement"] = "Ajouter (+) emplacement bouton";
|
||||
_txt["Between Blocks (left)"] = "Entre Blocks (gauche)";
|
||||
_txt["Between Blocks (center)"] = "Entre Blocks (centré)";
|
||||
_txt["Outline Mode"] = "Mode Contour";
|
||||
_txt["Row & column"] = "Ligne & colonne";
|
||||
_txt["Row only"] = "Ligne seulement";
|
||||
_txt["Draggable blocks without handle"] = "Déplacement des blocks sans poignée";
|
||||
_txt["Animated drag to sort"] = "Animation Glisser-déposer de tri";
|
||||
_txt["Open snippets sidebar on start"] = "Ouvrir barre de modules au démarrage";
|
||||
_txt["Scrollable toolbar (top only)"] = "Barre d'outils Scrollable (top seulement)";
|
||||
_txt["Please select a block"] = "Merci de sélectionner un block";
|
||||
_txt["Open snippet sidebar on start"] = "Ouvrir barre de modules au démarrage";
|
||||
_txt["Hide snippet handle"] = "Masquer poignée du module";
|
||||
_txt["Undo"] = "Annuler";
|
||||
_txt["Redo"] = "Refaire";
|
||||
_txt["Empty"] = "Vider";
|
||||
_txt["+ Click to add content"] = "+ Click pour ajouter du contenu";
|
||||
_txt["B"] = "B";
|
||||
_txt["W"] = "W";
|
||||
_txt["Outline Style"] = "Style de contour";
|
||||
_txt["Colored"] = "Coloré";
|
||||
_txt["Gray"] = "Gris";
|
||||
_txt["Hide Outline"] = "Masquer contour";
|
||||
_txt["Hide Column Tool"] = "Masquer outil de colonne";
|
||||
_txt["Row Tool Position"] = "Outil position de ligne";
|
||||
_txt["Tool Style"] = "Outil de style";
|
||||
_txt["Hide Snippet (+) Tool"] = "Masquer Outil de module (+)";
|
||||
_txt["Tool Outline"] = "Contour de module";
|
||||
_txt["Button"] = "Bouton";
|
||||
_txt["Button Editor"] = "Editeur de bouton";
|
||||
_txt["Edit Button"] = "Editer Bouton";
|
||||
_txt["Grid Editor"] = "Editeur de grille";
|
||||
_txt["Outline"] = "Contour";
|
||||
_txt["Font Size"] = "Taille Police de caractère";
|
||||
_txt["Line Spacing"] = "Espacement de ligne";
|
||||
_txt["Letter Spacing"] = "Espacement de caractère";
|
||||
_txt["Close"] = "Fermer";
|
||||
_txt["Search & Replace"] = "Chercher & remplacer";
|
||||
_txt["Word Count"] = "Compteur de mots";
|
||||
_txt["Add to Left"] = "Ajouter à gauche";
|
||||
_txt["Add to Right"] = "Ajouter à droite";
|
||||
_txt["Border Top Color"] = "Couleur de bordure haute";
|
||||
_txt["Border Bottom Color"] = "Couleur de bordure basse";
|
||||
_txt["Border Left Color"] = "Couleur de bordure gauche";
|
||||
_txt["Border Right Color"] = "Couleur de bordure droite";
|
||||
_txt["Snippets sidebar visibility"] = "Visibilité Barre de modules";
|
||||
|
||||
@@ -0,0 +1,204 @@
|
||||
var _txt = new Array();
|
||||
_txt["Bold"] = "粗體";
|
||||
_txt["Italic"] = "斜體";
|
||||
_txt["Hyperlink"] = "連結";
|
||||
_txt["Align"] = "對齊";
|
||||
_txt["Paragraph"] = "段落";
|
||||
_txt["Color"] = "顏色";
|
||||
_txt["Formatting"] = "格式";
|
||||
_txt["List"] = "列表";
|
||||
_txt["Text Settings"] = "文字設定";
|
||||
_txt["Icon"] = "圖示";
|
||||
_txt["Clean"] = "Clean";
|
||||
_txt["Font"] = "字型";
|
||||
_txt["Previous"] = "向前";
|
||||
_txt["Next"] = "向後";
|
||||
_txt["More"] = "查看更多";
|
||||
_txt["Move Up"] = "上移";
|
||||
_txt["Move Down"] = "下移";
|
||||
_txt["Move Left"] = "左移";
|
||||
_txt["Move Right"] = "右移";
|
||||
_txt["Delete"] = "刪除";
|
||||
_txt["Add"] = "新增";
|
||||
_txt["Move"] = "移動";
|
||||
_txt["Duplicate"] = "重製";
|
||||
_txt["Decrease"] = "減小";
|
||||
_txt["Increase"] = "加大";
|
||||
_txt["HTML"] = "HTML";
|
||||
_txt["Headline"] = "標題";
|
||||
_txt["Image"] = "影像";
|
||||
_txt["Heading 1"] = "標題1";
|
||||
_txt["Heading 2"] = "標題2";
|
||||
_txt["Heading 3"] = "標題3";
|
||||
_txt["Heading 4"] = "標題4";
|
||||
_txt["Quote"] = "引言";
|
||||
_txt["Preformatted"] = "預設格式";
|
||||
_txt["Table"] = "表格";
|
||||
_txt["Spacer"] = "間隔";
|
||||
_txt["Horizontal Line"] = "橫線";
|
||||
_txt["More..."] = "更多...";
|
||||
_txt["Enlarge"] = "加大";
|
||||
_txt["Ok"] = "Ok";
|
||||
_txt["Align Left"] = "靠左";
|
||||
_txt["Align Center"] = "靠中";
|
||||
_txt["Align Right"] = "靠右";
|
||||
_txt["Align Full"] = "左右靠齊";
|
||||
_txt["Bullets"] = "符號清單";
|
||||
_txt["Numbering"] = "編號清單";
|
||||
_txt["Indent"] = "內縮";
|
||||
_txt["Outdent"] = "外凸";
|
||||
_txt["Underline"] = "底線";
|
||||
_txt["Strikethrough"] = "刪除線";
|
||||
_txt["Superscript"] = "上標字";
|
||||
_txt["Subscript"] = "下標字";
|
||||
_txt["Uppercase"] = "大寫";
|
||||
_txt["Clear"] = "清除";
|
||||
_txt["Choose.."] = "選取..";
|
||||
_txt["Forecolor"] = "前景色彩";
|
||||
_txt["Backcolor"] = "背景色彩";
|
||||
_txt["Apply"] = "套用";
|
||||
_txt["Cancel"] = "取消";
|
||||
_txt["Change Image"] = "更換圖片";
|
||||
_txt["Link"] = "連結";
|
||||
_txt["Edit"] = "編輯";
|
||||
_txt["Source"] = "原始檔";
|
||||
_txt["Settings"] = "設定";
|
||||
_txt["Change Icon"] = "更換圖示";
|
||||
_txt["Edit Table"] = "編輯表格";
|
||||
_txt["Select"] = "選取 Select";
|
||||
_txt["Open New Window"] = "開新視窗";
|
||||
_txt["Text"] = "文字";
|
||||
_txt["Title"] = "標題";
|
||||
_txt["Free"] = "任意";
|
||||
_txt["Style"] = "樣式";
|
||||
_txt["Layout"] = "編排";
|
||||
_txt["Background"] = "背景";
|
||||
_txt["Select Color"] = "選取顏色";
|
||||
_txt["Text Color"] = "文字顏色";
|
||||
_txt["Border Thickness"] = "邊框粗細";
|
||||
_txt["Border Color"] = "邊框顏色";
|
||||
_txt["Apply To"] = "套用到";
|
||||
_txt["Current Row"] = "目前列";
|
||||
_txt["Current Column"] = "目前欄";
|
||||
_txt["Even Rows"] = "偶數列";
|
||||
_txt["Odd Rows"] = "奇數列";
|
||||
_txt["Current Cell"] = "目前儲存格";
|
||||
_txt["Insert Row"] = "插入列";
|
||||
_txt["Above"] = "上方";
|
||||
_txt["Below"] = "下方";
|
||||
_txt["Left"] = "左";
|
||||
_txt["Right"] = "右";
|
||||
_txt["Row"] = "列Row";
|
||||
_txt["Column"] = "欄Column";
|
||||
_txt["Merge"] = "合併";
|
||||
_txt["Merge Cell"] = "合併儲存格";
|
||||
_txt["css"] = "css";
|
||||
_txt["Class"] = "類別Class";
|
||||
_txt["Box"] = "區塊";
|
||||
_txt["Spacing"] = "間隔";
|
||||
_txt["Border"] = "邊框";
|
||||
_txt["Corners"] = "圓角";
|
||||
_txt["Shadow"] = "陰影";
|
||||
_txt["Display"] = "顯示";
|
||||
_txt["Position"] = "定位";
|
||||
_txt["Effects"] = "效果";
|
||||
_txt["Attributes"] = "屬性";
|
||||
_txt["Animation"] = "動畫";
|
||||
_txt["Background Color"] = "背景色彩";
|
||||
_txt["Gradient"] = "漸層";
|
||||
_txt["Dimension"] = "尺寸";
|
||||
_txt["Responsive Positioning"] = "響應定位*";
|
||||
_txt["Reset margin left on small screen"] = "重設小螢幕的左邊界*";
|
||||
_txt["Reset margin right on small screen"] = "重設小螢幕的右邊界*";
|
||||
_txt["Individual Sides"] = "各側邊框";
|
||||
_txt["Select Font"] = "選取字型";
|
||||
_txt["Animate"] = "動畫 Animate";
|
||||
_txt["Delay"] = "延遲 Delay";
|
||||
_txt["Duration"] = "期間 Duration";
|
||||
_txt["Animate Once"] = "播放一次 Animate Once";
|
||||
_txt["Test"] = "測試";
|
||||
_txt["TEST"] = "測試";
|
||||
_txt["Custom"] = "自訂";
|
||||
_txt["Custom Code (Javascript Allowed)"] = "自訂指令碼 (支援Javascript)";
|
||||
_txt["Module Settings"] = "模組設定";
|
||||
_txt["Drag and drop an image or click to browse."] = "將影像拖到這裡或點選瀏覽";
|
||||
_txt["Are you sure you want to delete this block?"] = "您確定要刪除這個區塊嗎?";
|
||||
_txt["Back"] = "返回";
|
||||
_txt["Or Specify Image Source"] = "或指定影像來源";
|
||||
_txt["Preferences"] = "偏好設定";
|
||||
_txt["Hide element tool"] = "隱藏元素工具element tool";
|
||||
_txt["Hide column tool"] = "隱藏欄工具column tool";
|
||||
_txt["Line"] = "直線Line";
|
||||
_txt["Hide column HTML editor"] = "隱藏欄HTML編輯器";
|
||||
_txt["Hide row HTML editor"] = "隱藏列HTML編輯器";
|
||||
_txt["Hide row move (up/down) buttons"] = "隱藏列移動(上/下)按鈕";
|
||||
_txt["HTML syntax highlighting"] = "HTML語法標示";
|
||||
_txt["Scrollable Editing Toolbar"] = "可捲動編輯工具列";
|
||||
_txt["Toolbar position"] = "工具列位置";
|
||||
_txt["Top"] = "上";
|
||||
_txt["Left"] = "左";
|
||||
_txt["Right"] = "右";
|
||||
_txt["Toolbar visibility"] = "是否顯示工具列";
|
||||
_txt["Auto"] = "自動";
|
||||
_txt["Always Visible"] = "始終顯示";
|
||||
_txt["Paste result"] = "貼上結果";
|
||||
_txt["HTML (without styles)"] = "HTML (無樣式)";
|
||||
_txt["HTML (with styles)"] = "HTML (有樣式)";
|
||||
_txt["Text only"] = "只有文字";
|
||||
_txt["Add Snippet"] = "加入片段指令碼";
|
||||
_txt["Grid Tool"] = "網格工具";
|
||||
_txt["Element Tool"] = "元素工具";
|
||||
_txt["Builder Mode"] = "建構模式";
|
||||
_txt["Default"] = "預設";
|
||||
_txt["Minimal"] = "最小";
|
||||
_txt["Hide outline"] = "隱藏大綱";
|
||||
_txt["Hide element highlight"] = "隱藏元素標示";
|
||||
_txt["Row tool position"] = "列工具位置";
|
||||
_txt["Add (+) button placement"] = "加入按鈕 (+) 位置";
|
||||
_txt["Between Blocks (left)"] = "區塊之間 (左)";
|
||||
_txt["Between Blocks (center)"] = "區塊之間 (中)";
|
||||
_txt["Outline Mode"] = "大綱模式";
|
||||
_txt["Row & column"] = "列/欄";
|
||||
_txt["Row only"] = "只有列";
|
||||
_txt["Draggable blocks without handle"] = "不需把手也可拖移區塊";
|
||||
_txt["Animated drag to sort"] = "動態拖移排序";
|
||||
_txt["Open snippets sidebar on start"] = "一開始就打開指令碼片段側邊欄";
|
||||
_txt["Scrollable toolbar (top only)"] = "可捲動工具列(只有上方)";
|
||||
_txt["Please select a block"] = "請選擇區塊";
|
||||
_txt["Open snippet sidebar on start"] = "一開始就打開指令碼片段工具列";
|
||||
_txt["Hide snippet handle"] = "穩藏指令碼片段把手";
|
||||
_txt["Undo"] = "還原";
|
||||
_txt["Redo"] = "重作";
|
||||
_txt["Empty"] = "清空";
|
||||
_txt["+ Click to add content"] = "+ 點選加入內容";
|
||||
_txt["B"] = "B";
|
||||
_txt["W"] = "W";
|
||||
_txt["Outline Style"] = "大綱模式";
|
||||
_txt["Colored"] = "彩色";
|
||||
_txt["Gray"] = "灰色";
|
||||
_txt["Hide Outline"] = "隱藏大綱";
|
||||
_txt["Hide Column Tool"] = "隱藏欄工具";
|
||||
_txt["Row Tool Position"] = "列工具位置";
|
||||
_txt["Tool Style"] = "工具樣式";
|
||||
_txt["Hide Snippet (+) Tool"] = "隱藏指令碼片段工具 (+) ";
|
||||
_txt["Tool Outline"] = "工具大綱";
|
||||
_txt["Button"] = "按鈕";
|
||||
_txt["Button Editor"] = "按鈕編輯器";
|
||||
_txt["Edit Button"] = "編輯按鈕";
|
||||
_txt["Grid Editor"] = "網格編輯器";
|
||||
_txt["Outline"] = "大綱";
|
||||
_txt["Font Size"] = "字型大小";
|
||||
_txt["Line Spacing"] = "列間距";
|
||||
_txt["Letter Spacing"] = "字元間距";
|
||||
_txt["Close"] = "關閉";
|
||||
_txt["Search & Replace"] = "搜尋取代";
|
||||
_txt["Word Count"] = "字數計算";
|
||||
_txt["Add to Left"] = "加到左方";
|
||||
_txt["Add to Right"] = "加到右方";
|
||||
_txt["Border Top Color"] = "上邊框色彩";
|
||||
_txt["Border Bottom Color"] = "下邊框色彩";
|
||||
_txt["Border Left Color"] = "左邊框色彩";
|
||||
_txt["Border Right Color"] = "右邊框色彩";
|
||||
_txt["Snippets sidebar visibility"] = "是否顯示指令碼片段側邊欄";
|
||||
_txt["You have reached the maximum number of columns"] = "己達最大欄數上限";
|
||||
|
||||
Binary file not shown.
Binary file not shown.
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,69 @@
|
||||
/*
|
||||
Button Editor Plugin
|
||||
*/
|
||||
|
||||
(function () {
|
||||
var html = '<div class="is-modal buttoneditor">' +
|
||||
'<div style="width:505px;height:620px;background:#fff;position: relative;display: flex;flex-direction: column;align-items: center;padding: 0px;background:#f8f8f8;">' +
|
||||
'<div class="is-modal-bar is-draggable" style="position: absolute;top: 0;left: 0;width: 100%;z-index:1;line-height:32px;height:32px;background:#f9f9f9;">' + _cb.out('Button Editor') +
|
||||
'<div class="is-modal-close" style="z-index:1;width:32px;height:32px;position:absolute;top:0px;right:0px;box-sizing:border-box;padding:0;line-height:32px;font-size: 12px;color:#777;text-align:center;cursor:pointer;">✕</div>' +
|
||||
'</div>' +
|
||||
'<iframe data-width="1440" style="width:100%;height:100%;max-width:1440px;border:none;border-top:32px solid transparent;margin:0;box-sizing:border-box;background:#fff;" src="about:blank"></iframe>' +
|
||||
'</div>' +
|
||||
'</div>';
|
||||
|
||||
_cb.addHtml(html);
|
||||
|
||||
var html_button = '<button title="' + _cb.out('Edit Button') + '" data-title="' + _cb.out('Edit Button') + '" class="button-edit" style="display:none;"><svg class="is-icon-flex" style="width:13px;height:13px;"><use xlink:href="#ion-android-create"></use></svg></button>';
|
||||
var linkTool = document.querySelector('#divLinkTool');
|
||||
|
||||
linkTool.insertAdjacentHTML('afterBegin', html_button); //add button to existing #divLinkTool
|
||||
|
||||
var buttonEdit = linkTool.querySelector('.button-edit');
|
||||
|
||||
//Extend onContentClick
|
||||
var oldget = _cb.opts.onContentClick;
|
||||
_cb.opts.onContentClick = function (e) {
|
||||
|
||||
let elm = e.target;
|
||||
|
||||
var ret = oldget.apply(this, arguments);
|
||||
var elmDisplay = getStyle(elm, 'display');
|
||||
if((elm.tagName.toLowerCase() === 'a' && elmDisplay === 'inline-block')) {
|
||||
|
||||
|
||||
buttonEdit.style.display = 'block';
|
||||
|
||||
|
||||
} else {
|
||||
|
||||
buttonEdit.style.display = 'none';
|
||||
|
||||
}
|
||||
|
||||
return ret;
|
||||
};
|
||||
|
||||
buttonEdit.addEventListener('click', function(){
|
||||
|
||||
var modal = document.querySelector('.is-modal.buttoneditor');
|
||||
_cb.showModal(modal);
|
||||
|
||||
_cb.saveForUndo(true); // checkLater = true
|
||||
|
||||
var btnClose = modal.querySelector('.is-modal-close');
|
||||
btnClose.addEventListener('click', function(e){
|
||||
_cb.hideModal(modal);
|
||||
});
|
||||
|
||||
var scriptPath = _cb.getScriptPath();
|
||||
modal.querySelector('iframe').src = scriptPath + 'plugins/buttoneditor/buttoneditor.html';
|
||||
|
||||
});
|
||||
|
||||
var getStyle = function(element, property) {
|
||||
return window.getComputedStyle ? window.getComputedStyle(element, null).getPropertyValue(property) : element.style[property.replace(/-([a-z])/g, function (g) { return g[1].toUpperCase(); })];
|
||||
}
|
||||
|
||||
})();
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
Preview Plugin
|
||||
|
||||
To install the plugin, modify config file (contentbuilder\config.js) as follow:
|
||||
|
||||
_cb.settings.plugins = ['buttoneditor'];
|
||||
|
||||
When you click a button, there will be an 'Edit' icon displayed.
|
||||
@@ -0,0 +1,15 @@
|
||||
/*
|
||||
Hello World Plugin
|
||||
*/
|
||||
|
||||
(function () {
|
||||
|
||||
var button_html = '<button id="my_helloworld_button" title="Hello World" style="text-transform:none">hello</button>';
|
||||
|
||||
_cb.addButton('helloworld', button_html, '#my_helloworld_button', function () {
|
||||
|
||||
alert('Hello World');
|
||||
|
||||
});
|
||||
|
||||
})();
|
||||
@@ -0,0 +1,23 @@
|
||||
Hello World Plugin
|
||||
|
||||
To install the plugin, modify config file (contentbuilder\config.js) as follow:
|
||||
|
||||
_cb.settings.plugins = ['helloworld'];
|
||||
|
||||
This plugin will add a 'Hello World' button on the 'More' popup on toolbar (click the 'More' button).
|
||||
|
||||
You can also add the "helloworld" button on the buttons or buttonsMore parameters:
|
||||
|
||||
var obj = $.contentbuilder({
|
||||
...
|
||||
buttons: [..., "helloworld", ...]
|
||||
});
|
||||
|
||||
or
|
||||
|
||||
var obj = $.contentbuilder({
|
||||
...
|
||||
buttonsMore: [..., "helloworld", ...]
|
||||
});
|
||||
|
||||
For more info about buttons or buttonsMore parameters, please check the ContentBuilder.js readme.txt.
|
||||
Binary file not shown.
@@ -0,0 +1,257 @@
|
||||
/*
|
||||
Preview Plugin
|
||||
*/
|
||||
|
||||
(function () {
|
||||
|
||||
var _screenwidth = window.innerWidth;
|
||||
if (_screenwidth <= 640) return;
|
||||
|
||||
var html =
|
||||
'<div class="is-modal previewcontent" style="z-index:10004">' +
|
||||
'<div style="width:100%;height:100%;background:#fff;position: relative;display: flex;flex-direction: column;align-items: center;padding: 0px;background:#f8f8f8;">' +
|
||||
'<div class="is-modal-bar" style="position: absolute;top: 0;left: 0;width: 100%;z-index:1;line-height:1.5;height:32px;padding:0;">' +
|
||||
'<div style="width:100%;height:100%;display:flex;justify-content:center;">' +
|
||||
'<div class="size-control" data-width="1440" style="width:1440px;">' +
|
||||
'<div class="size-control" data-width="1024" style="width:1024px;">' +
|
||||
'<div class="size-control" data-width="768" style="width:768px;">' +
|
||||
'<div class="size-control" data-width="425" style="width:425px;">' +
|
||||
'<div class="size-control" data-width="375" style="width:375px;">' +
|
||||
'<div class="size-control" data-width="320" style="width:320px;">' +
|
||||
'<div class="size-control-info" style="line-height:32px;">1440px</div>' +
|
||||
"</div>" +
|
||||
"</div>" +
|
||||
"</div>" +
|
||||
"</div>" +
|
||||
"</div>" +
|
||||
"</div>" +
|
||||
"</div>" +
|
||||
'<div class="is-modal-close" style="z-index:1;width:30px;height:30px;position:absolute;top:0px;right:0px;box-sizing:border-box;padding:0;line-height:30px;font-size: 12px;color:#777;text-align:center;cursor:pointer;"><svg class="is-icon-flex" style="fill:rgba(0, 0, 0, 0.47);width:30px;height:30px;"><use xlink:href="#ion-ios-close-empty"></use></svg></div>' +
|
||||
"</div>" +
|
||||
'<iframe data-width="1440" style="width:100%;height:100%;max-width:1440px;border:none;border-top:32px solid transparent;margin:0;box-sizing:border-box;background:#fff;" src="about:blank"></iframe>' +
|
||||
"</div>" +
|
||||
"</div>" +
|
||||
'<svg width="0" height="0" style="position:absolute;display:none;">' +
|
||||
"<defs>" +
|
||||
'<symbol viewBox="0 0 512 512" id="ion-ios-close-empty"><path d="M340.2 160l-84.4 84.3-84-83.9-11.8 11.8 84 83.8-84 83.9 11.8 11.7 84-83.8 84.4 84.2 11.8-11.7-84.4-84.3 84.4-84.2z"></path></symbol>' +
|
||||
'<symbol viewBox="0 0 512 512" id="ion-ios-search-strong"><path d="M344.5 298c15-23.6 23.8-51.6 23.8-81.7 0-84.1-68.1-152.3-152.1-152.3C132.1 64 64 132.2 64 216.3c0 84.1 68.1 152.3 152.1 152.3 30.5 0 58.9-9 82.7-24.4l6.9-4.8L414.3 448l33.7-34.3-108.5-108.6 5-7.1zm-43.1-166.8c22.7 22.7 35.2 52.9 35.2 85s-12.5 62.3-35.2 85c-22.7 22.7-52.9 35.2-85 35.2s-62.3-12.5-85-35.2c-22.7-22.7-35.2-52.9-35.2-85s12.5-62.3 35.2-85c22.7-22.7 52.9-35.2 85-35.2s62.3 12.5 85 35.2z"></path></symbol>' +
|
||||
"</defs>" +
|
||||
"</svg>";
|
||||
|
||||
_cb.addHtml(html);
|
||||
|
||||
var css =
|
||||
"<style>" +
|
||||
".size-control {cursor:pointer;background:#ddd;border-left:#fff 2px solid;border-right:#fff 2px solid;height:100%;display:flex;justify-content:center;}" +
|
||||
".size-control-info {text-align:center;color:#000;}" +
|
||||
"</style>";
|
||||
|
||||
_cb.addCss(css);
|
||||
|
||||
var button_html =
|
||||
'<button class="previewcontent-button" title="Preview" style="font-size:15px;vertical-align:bottom;">' +
|
||||
'<svg class="is-icon-flex" style="fill:rgba(0,0,0,0.7);width:19px;height:19px;"><use xlink:href="#ion-eye"></use></svg>' +
|
||||
"</button>";
|
||||
|
||||
var modal = document.querySelector(".is-modal.previewcontent");
|
||||
_cb.addButton('preview', button_html, '.previewcontent-button', function (e) {
|
||||
|
||||
_cb.showModal(modal);
|
||||
|
||||
|
||||
//check if builder is inside iframe
|
||||
if(window.frameElement) {
|
||||
var c = getFramedWindow(window.frameElement);
|
||||
var doc = c.document;
|
||||
} else {
|
||||
var doc = parent.document;
|
||||
}
|
||||
|
||||
var basehref = "";
|
||||
var base = doc.querySelectorAll("base[href]");
|
||||
if (base.length > 0) {
|
||||
basehref = '<base href="' + base[0].href + '" />';
|
||||
}
|
||||
|
||||
var csslinks = "";
|
||||
var styles = doc.querySelectorAll("link[href]");
|
||||
for (var i = 0; i < styles.length; i++) {
|
||||
if (
|
||||
styles[i].href.indexOf(".css") != -1 &&
|
||||
styles[i].href.indexOf("contentbox.css") == -1 &&
|
||||
styles[i].href.indexOf("contentbuilder.css") == -1
|
||||
) {
|
||||
csslinks +=
|
||||
'<link href="' +
|
||||
styles[i].href +
|
||||
'" rel="stylesheet" type="text/css" />';
|
||||
}
|
||||
}
|
||||
|
||||
var jsincludes = "";
|
||||
var scripts = doc.querySelectorAll("script[src]");
|
||||
for (var i = 0; i < scripts.length; i++) {
|
||||
if (
|
||||
scripts[i].src.indexOf(".js") != -1 &&
|
||||
scripts[i].src.indexOf("index.js") == -1 &&
|
||||
scripts[i].src.indexOf("contentbox.js") == -1 &&
|
||||
scripts[i].src.indexOf("contentbox.min.js") == -1 &&
|
||||
scripts[i].src.indexOf("contentbuilder.js") == -1 &&
|
||||
scripts[i].src.indexOf("contentbuilder.min.js") == -1 &&
|
||||
scripts[i].src.indexOf("plugin.js") == -1 &&
|
||||
scripts[i].src.indexOf("config.js") == -1 &&
|
||||
scripts[i].src.indexOf("en.js") == -1 &&
|
||||
scripts[i].src.indexOf("minimalist-blocks") == -1
|
||||
) {
|
||||
jsincludes +=
|
||||
'<script src="' +
|
||||
scripts[i].src +
|
||||
'" type="text/javascript"></script>';
|
||||
}
|
||||
}
|
||||
|
||||
// No script
|
||||
jsincludes = '';
|
||||
|
||||
/* Get Page */
|
||||
if (!document.querySelector(".is-wrapper")) {
|
||||
var maxwidth = "800px";
|
||||
var maxw = window.getComputedStyle(document.querySelector(".is-builder")).getPropertyValue('max-width');
|
||||
if (!isNaN(parseInt(maxw))) maxwidth = maxw;
|
||||
|
||||
var content = _cb.html();
|
||||
|
||||
var doc = modal.querySelector('iframe').contentWindow.document;
|
||||
doc.open();
|
||||
doc.write(
|
||||
"<html>" +
|
||||
"<head>" +
|
||||
basehref +
|
||||
'<meta charset="utf-8">' +
|
||||
"<title></title>" +
|
||||
csslinks +
|
||||
"<style>" +
|
||||
".slider-image { display:block !important; }" +
|
||||
".container {margin:35px auto 0; max-width: " +
|
||||
maxwidth +
|
||||
"; width:100%; padding:0 35px; box-sizing: border-box;}" +
|
||||
"</style>" +
|
||||
'<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>' +
|
||||
"</head>" +
|
||||
"<body>" +
|
||||
'<div class="container">' +
|
||||
content +
|
||||
"</div>" +
|
||||
jsincludes +
|
||||
"</body>" +
|
||||
"</html>"
|
||||
);
|
||||
doc.close();
|
||||
|
||||
} else {
|
||||
// ContentBox
|
||||
var content = jQuery(".is-wrapper")
|
||||
.data("contentbox")
|
||||
.html();
|
||||
|
||||
var doc = modal.querySelector('iframe').contentWindow.document;
|
||||
doc.open();
|
||||
doc.write(
|
||||
"<html>" +
|
||||
"<head>" +
|
||||
basehref +
|
||||
'<meta charset="utf-8">' +
|
||||
"<title></title>" +
|
||||
csslinks +
|
||||
"<style>" +
|
||||
".slider-image { display:block !important; }" +
|
||||
"</style>" +
|
||||
'<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>' +
|
||||
"</head>" +
|
||||
"<body>" +
|
||||
'<div class="is-wrapper">' +
|
||||
content +
|
||||
"</div>" +
|
||||
jsincludes +
|
||||
"</body>" +
|
||||
"</html>"
|
||||
);
|
||||
doc.close();
|
||||
|
||||
}
|
||||
//Or you can specify your custom preview page:
|
||||
//modal.find('iframe').attr('src','preview.html');
|
||||
|
||||
e.preventDefault();
|
||||
|
||||
});
|
||||
|
||||
var btnClose = modal.querySelector('.is-modal-close');
|
||||
btnClose.addEventListener('click', function(e){
|
||||
_cb.hideModal(modal);
|
||||
});
|
||||
|
||||
|
||||
var sizeControls = modal.querySelectorAll(".size-control");
|
||||
Array.prototype.forEach.call(sizeControls, function(sizeControl){
|
||||
|
||||
sizeControl.addEventListener('mouseover', function(e) {
|
||||
|
||||
var elms = modal.querySelectorAll(".size-control");
|
||||
Array.prototype.forEach.call(elms, function(elm){
|
||||
elm.style.background = "#ddd";
|
||||
});
|
||||
sizeControl.style.background = "#aaa";
|
||||
|
||||
elms = sizeControl.querySelectorAll(".size-control");
|
||||
Array.prototype.forEach.call(elms, function(elm){
|
||||
elm.style.background = "#aaa";
|
||||
});
|
||||
|
||||
modal.querySelector(".size-control-info").style.color = '#fff';
|
||||
|
||||
var w = sizeControl.getAttribute('data-width');
|
||||
modal.querySelector(".size-control-info").innerHTML = w + 'px';
|
||||
e.preventDefault();
|
||||
e.stopImmediatePropagation();
|
||||
|
||||
});
|
||||
|
||||
sizeControl.addEventListener('mouseout', function(e) {
|
||||
|
||||
var elms = modal.querySelectorAll(".size-control");
|
||||
Array.prototype.forEach.call(elms, function(elm){
|
||||
elm.style.background = "#ddd";
|
||||
});
|
||||
modal.querySelector(".size-control-info").style.color = '#000';
|
||||
|
||||
var currW = modal.querySelector("iframe").getAttribute('data-width');
|
||||
modal.querySelector(".size-control-info").innerText = currW + 'px';
|
||||
|
||||
});
|
||||
|
||||
sizeControl.addEventListener('click', function(e) {
|
||||
|
||||
var w = sizeControl.getAttribute('data-width');
|
||||
|
||||
modal.querySelector("iframe").style.maxWidth = w + 'px';
|
||||
modal.querySelector("iframe").setAttribute('data-width', w);
|
||||
|
||||
e.preventDefault();
|
||||
e.stopImmediatePropagation();
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
})();
|
||||
|
||||
|
||||
function getFramedWindow(f) {
|
||||
if(f.parentNode == null)
|
||||
f = document.body.appendChild(f);
|
||||
var w = (f.contentWindow || f.contentDocument);
|
||||
if(w && w.nodeType && w.nodeType==9)
|
||||
w = (w.defaultView || w.parentWindow);
|
||||
return w;
|
||||
}
|
||||
@@ -0,0 +1,23 @@
|
||||
Preview Plugin
|
||||
|
||||
To install the plugin, modify config file (contentbuilder\config.js) as follow:
|
||||
|
||||
_cb.settings.plugins = ['preview'];
|
||||
|
||||
This plugin will add a 'Preview' button on the 'More' popup on the toolbar (click the 'More' button).
|
||||
|
||||
You can also add the "preview" button on the toolbar as follow:
|
||||
|
||||
var obj = $.contentbuilder({
|
||||
...
|
||||
buttons: [..., "preview", ...]
|
||||
});
|
||||
|
||||
or
|
||||
|
||||
var obj = $.contentbuilder({
|
||||
...
|
||||
buttonsMore: [..., "preview", ...]
|
||||
});
|
||||
|
||||
(For more info about buttons or buttonsMore parameters, please check the ContentBuilder.js readme.txt)
|
||||
@@ -0,0 +1,128 @@
|
||||
/*
|
||||
Search & Replace Plugin
|
||||
*/
|
||||
|
||||
(function () {
|
||||
var js1 = 'https://cdnjs.cloudflare.com/ajax/libs/rangy/1.3.0/rangy-core.min.js';
|
||||
var js2 = 'https://cdnjs.cloudflare.com/ajax/libs/rangy/1.3.0/rangy-textrange.min.js'
|
||||
|
||||
// _cb.getScript(js1);
|
||||
// _cb.getScript(js2);
|
||||
_cb.getScripts([js1,js2]); //Get js1 first, then after loaded, get js2
|
||||
|
||||
var html = '<div class="is-modal searchreplace" style="z-index:10004;position:fixed;width:500px;height:280px;top:50%;left:50%;margin-top:-155px;margin-left:-250px;background:#fff;border: 1px solid rgb(199, 199, 199);box-shadow: 0px 5px 5px 5px rgba(0, 0, 0, 0.02);">' +
|
||||
'<div class="is-modal-bar is-draggable" style="position: absolute;top: 0;left: 0;width: 100%;z-index:1;line-height:32px;height:32px;">' + _cb.out('Search & Replace') +
|
||||
'<div class="is-modal-close" style="z-index:1;width:32px;height:32px;position:absolute;top:0px;right:0px;box-sizing:border-box;padding:0;line-height:32px;font-size: 12px;color:#777;text-align:center;cursor:pointer;">✕</div>' +
|
||||
'</div>' +
|
||||
'<iframe style="position: absolute;top: 0;left: 0;width:100%;height:100%;border:none;border-top:32px solid transparent;margin:0;box-sizing:border-box;" src="about:blank"></iframe>' +
|
||||
'</div>' +
|
||||
'<svg width="0" height="0" style="position:absolute;display:none;">' +
|
||||
'<defs>' +
|
||||
'<symbol viewBox="0 0 512 512" id="ion-ios-search-strong"><path d="M344.5 298c15-23.6 23.8-51.6 23.8-81.7 0-84.1-68.1-152.3-152.1-152.3C132.1 64 64 132.2 64 216.3c0 84.1 68.1 152.3 152.1 152.3 30.5 0 58.9-9 82.7-24.4l6.9-4.8L414.3 448l33.7-34.3-108.5-108.6 5-7.1zm-43.1-166.8c22.7 22.7 35.2 52.9 35.2 85s-12.5 62.3-35.2 85c-22.7 22.7-52.9 35.2-85 35.2s-62.3-12.5-85-35.2c-22.7-22.7-35.2-52.9-35.2-85s12.5-62.3 35.2-85c22.7-22.7 52.9-35.2 85-35.2s62.3 12.5 85 35.2z"></path></symbol>' +
|
||||
'</defs>' +
|
||||
'</svg>';
|
||||
|
||||
_cb.addHtml(html);
|
||||
|
||||
var button = '<button class="searchreplace-button" title="Search & Replace" style="font-size:15px;vertical-align:bottom;">' +
|
||||
'<svg class="is-icon-flex" style="width:17px;height:17px;"><use xlink:href="#ion-ios-search-strong"></use></svg>' +
|
||||
'</button>';
|
||||
|
||||
_cb.addButton('searchreplace', button, '.searchreplace-button', function () {
|
||||
|
||||
|
||||
var modal = document.querySelector(".is-modal.searchreplace");
|
||||
modal.className = modal.className + ' active';
|
||||
|
||||
var btnClose = modal.querySelector('.is-modal-close');
|
||||
btnClose.addEventListener('click', function(e){
|
||||
_cb.hideModal(modal);
|
||||
});
|
||||
|
||||
var scriptPath = _cb.getScriptPath();
|
||||
modal.querySelector('iframe').src = scriptPath + 'plugins/searchreplace/searchreplace.html';
|
||||
|
||||
// var wraper = _cb.getScope();
|
||||
// $wraper.focusEnd();
|
||||
|
||||
});
|
||||
|
||||
})();
|
||||
|
||||
// https://stackoverflow.com/questions/32192664/how-to-select-a-given-string-repeatedly-within-the-text-of-a-contenteditable-ele
|
||||
function findOne(target, caseSensitive, within, startNode, startPos) {
|
||||
if (rangy.supported) {
|
||||
var range = rangy.createRange();
|
||||
var searchScopeRange = rangy.createRange();
|
||||
|
||||
searchScopeRange.selectNodeContents(within);
|
||||
|
||||
if (startNode != null && startPos != null) {
|
||||
searchScopeRange.setStart(startNode, startPos);
|
||||
}
|
||||
|
||||
var options = {
|
||||
caseSensitive: caseSensitive,
|
||||
wholeWordsOnly: true,
|
||||
withinRange: searchScopeRange
|
||||
};
|
||||
|
||||
if (target !== "") {
|
||||
range.findText(target, options);
|
||||
|
||||
selectRange(range.startContainer, range.endContainer, range.startOffset, range.endOffset);
|
||||
|
||||
var text = getSelected(parent);
|
||||
if (text != '') {
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function selectRange(startNode, endNode, startPos, endPos) {
|
||||
var range = document.createRange()
|
||||
range.setStart(startNode, startPos);
|
||||
range.setEnd(endNode, endPos);
|
||||
|
||||
var sel = window.getSelection();
|
||||
sel.removeAllRanges();
|
||||
sel.addRange(range);
|
||||
}
|
||||
|
||||
function getSelected(window) {
|
||||
if (window.getSelection) { return window.getSelection(); }
|
||||
else if (document.getSelection) { return document.getSelection(); }
|
||||
else {
|
||||
var selection = document.selection && document.selection.createRange();
|
||||
if (selection.text) { return selection.text; }
|
||||
return false;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
// https://stackoverflow.com/questions/1181700/set-cursor-position-on-contenteditable-div/3323835
|
||||
// $.fn.focusEnd = function () {
|
||||
// $(this).focus();
|
||||
// var tmp = $('<span />').appendTo($(this)),
|
||||
// node = tmp.get(0),
|
||||
// range = null,
|
||||
// sel = null;
|
||||
|
||||
// if (document.selection) {
|
||||
// range = document.body.createTextRange();
|
||||
// range.moveToElementText(node);
|
||||
// range.select();
|
||||
// } else if (window.getSelection) {
|
||||
// range = document.createRange();
|
||||
// range.selectNode(node);
|
||||
// sel = window.getSelection();
|
||||
// sel.removeAllRanges();
|
||||
// sel.addRange(range);
|
||||
// }
|
||||
// tmp.remove();
|
||||
// return this;
|
||||
// }
|
||||
@@ -0,0 +1,23 @@
|
||||
Search & Replace Plugin
|
||||
|
||||
To install the plugin, modify config file (contentbuilder\config.js) as follow:
|
||||
|
||||
_cb.settings.plugins = ['searchreplace'];
|
||||
|
||||
This plugin will add a 'Search & Replace' button on the 'More' popup on toolbar (click the 'More' button).
|
||||
|
||||
You can also add the "searchreplace" button on the buttons or buttonsMore parameters:
|
||||
|
||||
var obj = $.contentbuilder({
|
||||
...
|
||||
buttons: [..., "searchreplace", ...]
|
||||
});
|
||||
|
||||
or
|
||||
|
||||
var obj = $.contentbuilder({
|
||||
...
|
||||
buttonsMore: [..., "searchreplace", ...]
|
||||
});
|
||||
|
||||
For more info about buttons or buttonsMore parameters, please check the ContentBuilder.js readme.txt.
|
||||
+253
@@ -0,0 +1,253 @@
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title></title>
|
||||
<style>
|
||||
body {margin:20px 20px 0;overflow-x:hidden;overflow-y:auto;font-family:sans-serif}
|
||||
.container {}
|
||||
.container > div {text-align:center;font-size:24px;cursor:pointer;margin: 0;display:inline-block;float:left;width:25%;height:80px;line-height:80px;border:#eee 1px solid;box-sizing:border-box;}
|
||||
.clearfix:before, .clearfix:after {content: " ";display: table;}
|
||||
.clearfix:after {clear: both;}
|
||||
.clearfix {*zoom: 1;}
|
||||
|
||||
.inptext {width:90%;font-size:17px;letter-spacing:1px;border:none;padding:10px;border:rgba(127, 127, 127, 0.32) 1px solid;}
|
||||
button {
|
||||
width: 55px;
|
||||
height: 50px;
|
||||
line-height: 1;
|
||||
display: inline-block;
|
||||
box-sizing: border-box;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
cursor: pointer;
|
||||
background-color: #fff;
|
||||
color: #4a4a4a;
|
||||
border: 1px solid transparent;
|
||||
font-family: sans-serif;
|
||||
letter-spacing: 1px;
|
||||
font-size: 12px;
|
||||
font-weight: normal;
|
||||
text-transform: uppercase;
|
||||
text-align: center;
|
||||
position: relative;
|
||||
border-radius: 0;
|
||||
transition: all ease 0.3s
|
||||
}
|
||||
.inptext:focus {outline:none}
|
||||
button:focus {outline:none;}
|
||||
|
||||
button.classic-primary {
|
||||
display: inline-block;
|
||||
width: auto;
|
||||
height: 50px;
|
||||
padding-left: 10px;
|
||||
padding-right: 10px;
|
||||
min-width: 135px;
|
||||
background: #f7f7f7;
|
||||
}
|
||||
button.classic-secondary {
|
||||
display: inline-block;
|
||||
width: auto;
|
||||
height: 50px;
|
||||
padding-left: 10px;
|
||||
padding-right: 10px;
|
||||
background: transparent;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div style="display:flex;justify-content:space-between;">
|
||||
<input id="txtSearch" tabindex="1" class="inptext" type="text" style="width:100%;" value="" />
|
||||
<button class="input-search classic-primary" style="border:rgba(127, 127, 127, 0.32) 1px solid;border-left:none;width:130px;">Search Next</button>
|
||||
</div>
|
||||
<div style="margin:10px 0">
|
||||
<label for="txtReplaceWith">Replace with:</label>
|
||||
</div>
|
||||
<div style="display:flex;justify-content:space-between;">
|
||||
<input id="txtReplaceWith" tabindex="2" class="inptext" type="text" style="width:100%;" value="" />
|
||||
<button class="input-replace classic-primary" style="border:rgba(127, 127, 127, 0.32) 1px solid;border-left:none;width:130px;">Replace</button>
|
||||
</div>
|
||||
<div style="display:flex;justify-content:space-between;margin:17px 0;">
|
||||
<div>
|
||||
<label id="lblMatchCase" for="chkMatchCase">
|
||||
<input type="checkbox" name="chkMatchCase" id="chkMatchCase"> Match case
|
||||
</label>
|
||||
<div id="divStatus" style="margin-top:12px;"></div>
|
||||
</div>
|
||||
<button class="input-replaceall classic-primary" style="border:rgba(127, 127, 127, 0.32) 1px solid;width:130px;">Replace All</button>
|
||||
</div>
|
||||
|
||||
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
|
||||
<script>
|
||||
var nReplaceCount = 0;
|
||||
|
||||
jQuery(document).ready(function () {
|
||||
|
||||
jQuery('#txtSearch').focus();
|
||||
|
||||
jQuery('.input-replaceall').click(function () {
|
||||
jQuery('#divStatus').html('');
|
||||
|
||||
var target = jQuery('#txtSearch').val();
|
||||
var replaceWith = jQuery('#txtReplaceWith').val();
|
||||
if (jQuery("#chkMatchCase").prop("checked")) {
|
||||
var bMatchCase = true;
|
||||
} else {
|
||||
var bMatchCase = false;
|
||||
}
|
||||
|
||||
var within = parent._cb.getScope();
|
||||
|
||||
var sel = parent.getSelection();
|
||||
|
||||
var r1 = parent.document.createRange();
|
||||
r1.selectNodeContents(within);
|
||||
|
||||
// https://stackoverflow.com/questions/32192664/how-to-select-a-given-string-repeatedly-within-the-text-of-a-contenteditable-ele
|
||||
if (sel.toString().search(target) > -1) {
|
||||
var ok = parent.findOne(target, bMatchCase, within, sel.focusNode, sel.focusOffset);
|
||||
if (ok) {
|
||||
var rng = parent.getSelection().getRangeAt(0);
|
||||
rng.deleteContents();
|
||||
rng.insertNode(document.createTextNode(replaceWith));
|
||||
nReplaceCount++;
|
||||
}
|
||||
jQuery('.input-replaceall').trigger('click');
|
||||
} else if (sel.toString().length > 0) {
|
||||
var ok = parent.findOne(target, bMatchCase, within, sel.focusNode, sel.focusOffset);
|
||||
if (ok) {
|
||||
var rng = parent.getSelection().getRangeAt(0);
|
||||
rng.deleteContents();
|
||||
rng.insertNode(document.createTextNode(replaceWith));
|
||||
nReplaceCount++;
|
||||
}
|
||||
jQuery('.input-replaceall').trigger('click');
|
||||
} else if (sel.rangeCount) {
|
||||
var ok = parent.findOne(target, bMatchCase, within, r1.commonAncestorContainer, r1.startOffset);
|
||||
if (ok) {
|
||||
var rng = parent.getSelection().getRangeAt(0);
|
||||
rng.deleteContents();
|
||||
rng.insertNode(document.createTextNode(replaceWith));
|
||||
nReplaceCount++;
|
||||
jQuery('.input-replaceall').trigger('click');
|
||||
} else {
|
||||
jQuery('#divStatus').html(nReplaceCount + ' occurrence(s) replaced.');
|
||||
nReplaceCount = 0;
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
jQuery('.input-search').click(function () {
|
||||
|
||||
var target = jQuery('#txtSearch').val();
|
||||
var replaceWith = jQuery('#txtReplaceWith').val();
|
||||
if (jQuery("#chkMatchCase").prop("checked")) {
|
||||
var bMatchCase = true;
|
||||
} else {
|
||||
var bMatchCase = false;
|
||||
}
|
||||
|
||||
var within = parent._cb.getScope();
|
||||
|
||||
var sel = parent.getSelection();
|
||||
|
||||
var r1 = parent.document.createRange();
|
||||
r1.selectNodeContents(within);
|
||||
|
||||
if (sel.toString().search(target) > -1) {
|
||||
var ok = parent.findOne(target, bMatchCase, within, sel.focusNode, sel.focusOffset);
|
||||
if (ok) {
|
||||
jQuery('#divStatus').html('');
|
||||
} else {
|
||||
|
||||
}
|
||||
} else if (sel.toString().length > 0) {
|
||||
var ok = parent.findOne(target, bMatchCase, within, sel.focusNode, sel.focusOffset);
|
||||
if (ok) {
|
||||
jQuery('#divStatus').html('');
|
||||
} else {
|
||||
jQuery('#divStatus').html('Passed the end of the content.');
|
||||
var ok = parent.findOne(target, bMatchCase, within, r1.commonAncestorContainer, r1.startOffset);
|
||||
if (ok) {
|
||||
jQuery('#divStatus').html('');
|
||||
} else {
|
||||
jQuery('#divStatus').html('The specified text was not found.');
|
||||
}
|
||||
}
|
||||
} else if (sel.rangeCount) {
|
||||
var ok = parent.findOne(target, bMatchCase, within, sel.anchorNode, sel.anchorOffset);
|
||||
if (ok) {
|
||||
jQuery('#divStatus').html('');
|
||||
} else {
|
||||
var ok = parent.findOne(target, bMatchCase, within, r1.commonAncestorContainer, r1.startOffset);
|
||||
if (ok) {
|
||||
jQuery('#divStatus').html('');
|
||||
} else {
|
||||
jQuery('#divStatus').html('The specified text was not found.');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
jQuery('.input-replace').click(function () {
|
||||
|
||||
var target = jQuery('#txtSearch').val();
|
||||
var replaceWith = jQuery('#txtReplaceWith').val();
|
||||
if (jQuery("#chkMatchCase").prop("checked")) {
|
||||
var bMatchCase = true;
|
||||
} else {
|
||||
var bMatchCase = false;
|
||||
}
|
||||
|
||||
var within = parent._cb.getScope();
|
||||
|
||||
var sel = parent.getSelection();
|
||||
|
||||
var r1 = parent.document.createRange();
|
||||
r1.selectNodeContents(within);
|
||||
|
||||
var text = getSelected(parent);
|
||||
if (text) {
|
||||
if ((((text + '').toLowerCase() == target.toLowerCase()) && bMatchCase==false) ||
|
||||
((text == target) && bMatchCase == true)) {
|
||||
var rng = parent.getSelection().getRangeAt(0);
|
||||
rng.deleteContents();
|
||||
rng.insertNode(document.createTextNode(replaceWith));
|
||||
}
|
||||
}
|
||||
|
||||
if (sel.rangeCount) {
|
||||
var ok = parent.findOne(target, bMatchCase, within, sel.anchorNode, sel.anchorOffset);
|
||||
if (ok) {
|
||||
jQuery('#divStatus').html('');
|
||||
} else {
|
||||
var ok = parent.findOne(target, bMatchCase, within, r1.commonAncestorContainer, r1.startOffset);
|
||||
if (ok) {
|
||||
jQuery('#divStatus').html('');
|
||||
} else {
|
||||
jQuery('#divStatus').html('The specified text was not found.');
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
function getSelected(window) {
|
||||
if (window.getSelection) { return window.getSelection(); }
|
||||
else if (document.getSelection) { return document.getSelection(); }
|
||||
else {
|
||||
var selection = document.selection && document.selection.createRange();
|
||||
if (selection.text) { return selection.text; }
|
||||
return false;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,67 @@
|
||||
/*
|
||||
Show Grid Plugin
|
||||
*/
|
||||
|
||||
(function () {
|
||||
|
||||
var icon_html = '<svg width="0" height="0" style="position:absolute;display:none;">' +
|
||||
'<defs>' +
|
||||
'<symbol viewBox="0 0 512 512" id="ion-ios-grid-view-outline"><path d="M448 192v-16H336V64h-16v112H192V64h-16v112H64v16h112v128H64v16h112v112h16V336h128v112h16V336h112v-16H336V192h112zM320 320H192V192h128v128z"></path></symbol>' +
|
||||
'</defs>' +
|
||||
'</svg>';
|
||||
|
||||
_cb.addHtml(icon_html);
|
||||
|
||||
var css = '<style>' +
|
||||
'.container.showgrid > div > div {outline: 1px solid rgba(132, 132, 132, 0.27); outline-offset: 1px;}' +
|
||||
'</style>';
|
||||
|
||||
_cb.addCss(css);
|
||||
|
||||
var button_html = '<button id="btnShowGrid" title="Grid Outline">' +
|
||||
'<svg class="is-icon-flex" style="fill:rgba(0, 0, 0, 0.7);width:14px;height:14px;"><use xlink:href="#ion-ios-grid-view-outline"></use></svg>' +
|
||||
'</button>';
|
||||
|
||||
_cb.addButton('showgrid', button_html, '#btnShowGrid', function () {
|
||||
|
||||
showGrid();
|
||||
|
||||
});
|
||||
|
||||
function showGrid() {
|
||||
|
||||
// Get all editable areas
|
||||
const areas = document.querySelectorAll('.container');
|
||||
Array.prototype.forEach.call(areas, function(area){
|
||||
|
||||
if(hasClass(area,'showgrid')){
|
||||
removeClass(area, 'showgrid');
|
||||
} else {
|
||||
addClass(area, 'showgrid');
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function addClass(element, classname) {
|
||||
if(!element) return;
|
||||
if(hasClass(element,classname)) return;
|
||||
if(element.classList.length===0) element.className = classname;
|
||||
else element.className = element.className + ' ' + classname;
|
||||
element.className = element.className.replace(/ +/g, ' ');
|
||||
}
|
||||
|
||||
function removeClass(element, classname) {
|
||||
if(!element) return;
|
||||
if(element.classList.length>0) {
|
||||
element.className = element.className.replace(new RegExp('\\b'+ classname+'\\b', 'g'), '');
|
||||
element.className = element.className.replace(/ +/g, ' ');
|
||||
}
|
||||
}
|
||||
|
||||
function hasClass(element, classname) {
|
||||
if(!element) return false;
|
||||
return element.classList ? element.classList.contains(classname) : new RegExp('\\b'+ classname+'\\b').test(element.className);
|
||||
}
|
||||
|
||||
})();
|
||||
|
||||
@@ -0,0 +1,23 @@
|
||||
Show Grid Plugin
|
||||
|
||||
To install the plugin, modify config file (contentbuilder\config.js) as follow:
|
||||
|
||||
_cb.settings.plugins = ['showgrid'];
|
||||
|
||||
This plugin will add a 'show grid outline' button on the 'More' popup on toolbar (click the 'More' button).
|
||||
|
||||
You can also add the "showgrid" button on the buttons or buttonsMore parameters:
|
||||
|
||||
var obj = $.contentbuilder({
|
||||
...
|
||||
buttons: [..., "showgrid", ...]
|
||||
});
|
||||
|
||||
or
|
||||
|
||||
var obj = $.contentbuilder({
|
||||
...
|
||||
buttonsMore: [..., "showgrid", ...]
|
||||
});
|
||||
|
||||
For more info about buttons or buttonsMore parameters, please check the ContentBuilder.js readme.txt.
|
||||
@@ -0,0 +1,36 @@
|
||||
/*
|
||||
Insert HTML Symbols Plugin
|
||||
*/
|
||||
|
||||
(function () {
|
||||
|
||||
var html = '<div class="is-modal is-side' + (_cb.settings.sidePanel == 'right' ? '' : ' fromleft') + ' viewsymbols" style="width:280px;z-index:10004;">' +
|
||||
'<button title="' + _cb.out('Close') + '" class="is-side-close" style="z-index:1;width:25px;height:25px;position:absolute;top:10px;right:13px;box-sizing:border-box;padding:0;line-height:25px;font-size: 12px;text-align:center;cursor:pointer;background:transparent"><svg class="is-icon-flex" style="width:25px;height:25px;"><use xlink:href="#ion-ios-close-empty"></use></svg></button>' +
|
||||
|
||||
'' +
|
||||
'<iframe src="about:blank" style="width:100%;height:100%;position:absolute;top:0;left:0;border: none;"></iframe>' +
|
||||
'' +
|
||||
'</div>';
|
||||
|
||||
_cb.addHtml(html);
|
||||
|
||||
var button = '<button class="insertsymbol-button" title="Symbol" style="font-size:14px;vertical-align:bottom;">' +
|
||||
'Ω' +
|
||||
'</button>';
|
||||
|
||||
_cb.addButton('symbols', button, '.insertsymbol-button', function () {
|
||||
|
||||
var modal = document.querySelector('.is-side.viewsymbols');
|
||||
_cb.showSidePanel(modal);
|
||||
var btnClose = modal.querySelector('.is-side-close');
|
||||
btnClose.addEventListener('click', function(e){
|
||||
_cb.hideSidePanel(modal);
|
||||
});
|
||||
|
||||
var scriptPath = _cb.getScriptPath();
|
||||
modal.querySelector('iframe').src = scriptPath + 'plugins/symbols/symbols.html';
|
||||
|
||||
|
||||
});
|
||||
|
||||
})();
|
||||
@@ -0,0 +1,23 @@
|
||||
Insert Symbols Plugin
|
||||
|
||||
To install the plugin, modify config file (contentbuilder\config.js) as follow:
|
||||
|
||||
_cb.settings.plugins = ['symbols'];
|
||||
|
||||
This plugin will add an 'Insert Symbols' button on the 'More' popup on toolbar (click the 'More' button).
|
||||
|
||||
You can also add the "symbols" button on the buttons or buttonsMore parameters:
|
||||
|
||||
var obj = $.contentbuilder({
|
||||
...
|
||||
buttons: [..., "symbols", ...]
|
||||
});
|
||||
|
||||
or
|
||||
|
||||
var obj = $.contentbuilder({
|
||||
...
|
||||
buttonsMore: [..., "symbols", ...]
|
||||
});
|
||||
|
||||
For more info about buttons or buttonsMore parameters, please check the ContentBuilder.js readme.txt.
|
||||
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,66 @@
|
||||
/*
|
||||
Word Count Plugin
|
||||
*/
|
||||
|
||||
(function () {
|
||||
|
||||
var html = '<div class="is-modal wordcount" style="z-index:10005">' +
|
||||
'<div style="max-width:300px;height:200px;padding:0;">' +
|
||||
'<div class="is-modal-bar is-draggable" style="height:32px;line-height:32px;">' +
|
||||
_cb.out('Word Count') +
|
||||
'<div class="is-modal-close">✕</div>' +
|
||||
'</div>' +
|
||||
'<div style="padding:19px 20px 0;">' +
|
||||
'<div style="line-height:1"><span id="spanWords" style="font-size:60px;font-weight:700;color:#333"></span> <span style="letter-spacing: 1px;color: #333;font-size:15px;">words</span></div>' +
|
||||
'<div style="padding:8px 0 0 5px;letter-spacing: 1px;color: #333;font-size:15px;">' +
|
||||
'Characters: <span id="spanChars"></span><br>' +
|
||||
'Characters (no spaces): <span id="spanCharsNoSpaces"></span>' +
|
||||
'</div>' +
|
||||
'<div id="tmp_wordcount" style="width:1px;height:1px;visibility:hidden;""></div>' +
|
||||
'</div>' +
|
||||
'</div>' +
|
||||
'</div>' +
|
||||
'<svg width="0" height="0" style="display:none;">' +
|
||||
'<defs>' +
|
||||
'<symbol viewBox="0 0 512 512" id="ion-information"><path d="M288 448V192h-96v16h32v240h-32v16h128v-16zM255.8 144.5c26.6 0 48.2-21.6 48.2-48.2s-21.6-48.2-48.2-48.2-48.2 21.6-48.2 48.2 21.6 48.2 48.2 48.2z"></path></symbol>' +
|
||||
'</defs>' +
|
||||
'</svg>';
|
||||
|
||||
_cb.addHtml(html);
|
||||
|
||||
var css = '' +
|
||||
'' +
|
||||
'';
|
||||
|
||||
_cb.addCss(css);
|
||||
|
||||
var button = '<button class="wordcount-button" title="Word Count" style="font-size:15px;vertical-align:bottom;">' +
|
||||
'<svg class="is-icon-flex" style="margin-top:-1px"><use xlink:href="#ion-information"></use></svg>' +
|
||||
'</button>';
|
||||
|
||||
_cb.addButton('wordcount', button, '.wordcount-button', function () {
|
||||
|
||||
var modal = document.querySelector(".is-modal.wordcount");
|
||||
_cb.showModal(modal, true);
|
||||
|
||||
|
||||
modal.querySelector('#tmp_wordcount').innerHTML = _cb.html();
|
||||
var txt = modal.querySelector('#tmp_wordcount').textContent;
|
||||
modal.querySelector('#tmp_wordcount').innerHTML = '';
|
||||
// https://stackoverflow.com/questions/9864644/jquery-character-and-word-count
|
||||
var chars = txt.length;
|
||||
var charsnospaces = txt.replace(/\s/g, "").length;
|
||||
var words = txt.replace(/[^\w ]/g, "").split(/\s+/).length;
|
||||
|
||||
modal.querySelector('#spanWords').innerText = words;
|
||||
modal.querySelector('#spanChars').innerText = chars;
|
||||
modal.querySelector('#spanCharsNoSpaces').innerText = charsnospaces;
|
||||
|
||||
var btnClose = modal.querySelector('.is-modal-close');
|
||||
btnClose.addEventListener('click', function(e){
|
||||
_cb.hideModal(modal);
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
})();
|
||||
@@ -0,0 +1,23 @@
|
||||
Word Count Plugin
|
||||
|
||||
To install the plugin, modify config file (contentbuilder\config.js) as follow:
|
||||
|
||||
_cb.settings.plugins = ['wordcount'];
|
||||
|
||||
This plugin will add a 'Word Count' button on the 'More' popup on toolbar (click the 'More' button).
|
||||
|
||||
You can also add the "showgrid" button on the buttons or buttonsMore parameters:
|
||||
|
||||
var obj = $.contentbuilder({
|
||||
...
|
||||
buttons: [..., "wordcount", ...]
|
||||
});
|
||||
|
||||
or
|
||||
|
||||
var obj = $.contentbuilder({
|
||||
...
|
||||
buttonsMore: [..., "wordcount", ...]
|
||||
});
|
||||
|
||||
For more info about buttons or buttonsMore parameters, please check the ContentBuilder.js readme.txt.
|
||||
Reference in new issue
Block a user