/******/ (function(modules) { // webpackBootstrap /******/ // The module cache /******/ var installedModules = {}; /******/ /******/ // The require function /******/ function __webpack_require__(moduleId) { /******/ /******/ // Check if module is in cache /******/ if(installedModules[moduleId]) { /******/ return installedModules[moduleId].exports; /******/ } /******/ // Create a new module (and put it into the cache) /******/ var module = installedModules[moduleId] = { /******/ i: moduleId, /******/ l: false, /******/ exports: {} /******/ }; /******/ /******/ // Execute the module function /******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); /******/ /******/ // Flag the module as loaded /******/ module.l = true; /******/ /******/ // Return the exports of the module /******/ return module.exports; /******/ } /******/ /******/ /******/ // expose the modules object (__webpack_modules__) /******/ __webpack_require__.m = modules; /******/ /******/ // expose the module cache /******/ __webpack_require__.c = installedModules; /******/ /******/ // define getter function for harmony exports /******/ __webpack_require__.d = function(exports, name, getter) { /******/ if(!__webpack_require__.o(exports, name)) { /******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); /******/ } /******/ }; /******/ /******/ // define __esModule on exports /******/ __webpack_require__.r = function(exports) { /******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { /******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); /******/ } /******/ Object.defineProperty(exports, '__esModule', { value: true }); /******/ }; /******/ /******/ // create a fake namespace object /******/ // mode & 1: value is a module id, require it /******/ // mode & 2: merge all properties of value into the ns /******/ // mode & 4: return value when already ns object /******/ // mode & 8|1: behave like require /******/ __webpack_require__.t = function(value, mode) { /******/ if(mode & 1) value = __webpack_require__(value); /******/ if(mode & 8) return value; /******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; /******/ var ns = Object.create(null); /******/ __webpack_require__.r(ns); /******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); /******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); /******/ return ns; /******/ }; /******/ /******/ // getDefaultExport function for compatibility with non-harmony modules /******/ __webpack_require__.n = function(module) { /******/ var getter = module && module.__esModule ? /******/ function getDefault() { return module['default']; } : /******/ function getModuleExports() { return module; }; /******/ __webpack_require__.d(getter, 'a', getter); /******/ return getter; /******/ }; /******/ /******/ // Object.prototype.hasOwnProperty.call /******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; /******/ /******/ // __webpack_public_path__ /******/ __webpack_require__.p = ""; /******/ /******/ /******/ // Load entry module and return exports /******/ return __webpack_require__(__webpack_require__.s = "./src/app.tsx"); /******/ }) /************************************************************************/ /******/ ({ /***/ "./modules/jquery-ui-1.12.1/jquery-ui.css": /*!************************************************!*\ !*** ./modules/jquery-ui-1.12.1/jquery-ui.css ***! \************************************************/ /*! no static exports found */ /***/ (function(module, exports) { // removed by extract-text-webpack-plugin /***/ }), /***/ "./modules/jquery-ui-1.12.1/jquery-ui.js": /*!***********************************************!*\ !*** ./modules/jquery-ui-1.12.1/jquery-ui.js ***! \***********************************************/ /*! no static exports found */ /***/ (function(module, exports, __webpack_require__) { var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;function _typeof(obj){"@babel/helpers - typeof";if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"){_typeof=function _typeof(obj){return typeof obj;};}else{_typeof=function _typeof(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":typeof obj;};}return _typeof(obj);}/*! jQuery UI - v1.12.1 - 2018-05-25 * http://jqueryui.com * Includes: widget.js, position.js, data.js, disable-selection.js, focusable.js, form-reset-mixin.js, jquery-1-7.js, keycode.js, labels.js, scroll-parent.js, tabbable.js, unique-id.js, widgets/draggable.js, widgets/droppable.js, widgets/resizable.js, widgets/selectable.js, widgets/sortable.js, widgets/accordion.js, widgets/autocomplete.js, widgets/button.js, widgets/checkboxradio.js, widgets/controlgroup.js, widgets/datepicker.js, widgets/dialog.js, widgets/menu.js, widgets/mouse.js, widgets/progressbar.js, widgets/selectmenu.js, widgets/slider.js, widgets/spinner.js, widgets/tabs.js, widgets/tooltip.js, effect.js, effects/effect-blind.js, effects/effect-bounce.js, effects/effect-clip.js, effects/effect-drop.js, effects/effect-explode.js, effects/effect-fade.js, effects/effect-fold.js, effects/effect-highlight.js, effects/effect-puff.js, effects/effect-pulsate.js, effects/effect-scale.js, effects/effect-shake.js, effects/effect-size.js, effects/effect-slide.js, effects/effect-transfer.js * Copyright jQuery Foundation and other contributors; Licensed MIT */(function(factory){if(true){// AMD. Register as an anonymous module. !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(/*! jquery */ "./node_modules/jquery/dist/jquery.js")], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory), __WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ? (__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));}else{}})(function($){$.ui=$.ui||{};var version=$.ui.version='1.12.1';/*! * jQuery UI Widget 1.12.1 * http://jqueryui.com * * Copyright jQuery Foundation and other contributors * Released under the MIT license. * http://jquery.org/license */ //>>label: Widget //>>group: Core //>>description: Provides a factory for creating stateful widgets with a common API. //>>docs: http://api.jqueryui.com/jQuery.widget/ //>>demos: http://jqueryui.com/widget/ var widgetUuid=0;var widgetSlice=Array.prototype.slice;$.cleanData=function(orig){return function(elems){var events,elem,i;for(i=0;(elem=elems[i])!=null;i++){try{// Only trigger remove when necessary to save time events=$._data(elem,'events');if(events&&events.remove){$(elem).triggerHandler('remove');}// Http://bugs.jquery.com/ticket/8235 }catch(e){}}orig(elems);};}($.cleanData);$.widget=function(name,base,prototype){var existingConstructor,constructor,basePrototype;// ProxiedPrototype allows the provided prototype to remain unmodified // so that it can be used as a mixin for multiple widgets (#8876) var proxiedPrototype={};var namespace=name.split('.')[0];name=name.split('.')[1];var fullName=namespace+'-'+name;if(!prototype){prototype=base;base=$.Widget;}if($.isArray(prototype)){prototype=$.extend.apply(null,[{}].concat(prototype));}// Create selector for plugin $.expr[':'][fullName.toLowerCase()]=function(elem){return!!$.data(elem,fullName);};$[namespace]=$[namespace]||{};existingConstructor=$[namespace][name];constructor=$[namespace][name]=function(options,element){// Allow instantiation without "new" keyword if(!this._createWidget){return new constructor(options,element);}// Allow instantiation without initializing for simple inheritance // must use "new" keyword (the code above always passes args) if(arguments.length){this._createWidget(options,element);}};// Extend with the existing constructor to carry over any static properties $.extend(constructor,existingConstructor,{version:prototype.version,// Copy the object used to create the prototype in case we need to // redefine the widget later _proto:$.extend({},prototype),// Track widgets that inherit from this widget in case this widget is // redefined after a widget inherits from it _childConstructors:[]});basePrototype=new base();// We need to make the options hash a property directly on the new instance // otherwise we'll modify the options hash on the prototype that we're // inheriting from basePrototype.options=$.widget.extend({},basePrototype.options);$.each(prototype,function(prop,value){if(!$.isFunction(value)){proxiedPrototype[prop]=value;return;}proxiedPrototype[prop]=function(){function _super(){return base.prototype[prop].apply(this,arguments);}function _superApply(args){return base.prototype[prop].apply(this,args);}return function(){var __super=this._super;var __superApply=this._superApply;var returnValue;this._super=_super;this._superApply=_superApply;returnValue=value.apply(this,arguments);this._super=__super;this._superApply=__superApply;return returnValue;};}();});constructor.prototype=$.widget.extend(basePrototype,{// TODO: remove support for widgetEventPrefix // always use the name + a colon as the prefix, e.g., draggable:start // don't prefix for widgets that aren't DOM-based widgetEventPrefix:existingConstructor?basePrototype.widgetEventPrefix||name:name},proxiedPrototype,{constructor:constructor,namespace:namespace,widgetName:name,widgetFullName:fullName});// If this widget is being redefined then we need to find all widgets that // are inheriting from it and redefine all of them so that they inherit from // the new version of this widget. We're essentially trying to replace one // level in the prototype chain. if(existingConstructor){$.each(existingConstructor._childConstructors,function(i,child){var childPrototype=child.prototype;// Redefine the child widget using the same prototype that was // originally used, but inherit from the new version of the base $.widget(childPrototype.namespace+'.'+childPrototype.widgetName,constructor,child._proto);});// Remove the list of existing child constructors from the old constructor // so the old child constructors can be garbage collected delete existingConstructor._childConstructors;}else{base._childConstructors.push(constructor);}$.widget.bridge(name,constructor);return constructor;};$.widget.extend=function(target){var input=widgetSlice.call(arguments,1);var inputIndex=0;var inputLength=input.length;var key;var value;for(;inputIndex',options:{classes:{},disabled:false,// Callbacks create:null},_createWidget:function _createWidget(options,element){element=$(element||this.defaultElement||this)[0];this.element=$(element);this.uuid=widgetUuid++;this.eventNamespace='.'+this.widgetName+this.uuid;this.bindings=$();this.hoverable=$();this.focusable=$();this.classesElementLookup={};if(element!==this){$.data(element,this.widgetFullName,this);this._on(true,this.element,{remove:function remove(event){if(event.target===element){this.destroy();}}});this.document=$(element.style?// Element within the document element.ownerDocument:// Element is window or document element.document||element);this.window=$(this.document[0].defaultView||this.document[0].parentWindow);}this.options=$.widget.extend({},this.options,this._getCreateOptions(),options);this._create();if(this.options.disabled){this._setOptionDisabled(this.options.disabled);}this._trigger('create',null,this._getCreateEventData());this._init();},_getCreateOptions:function _getCreateOptions(){return{};},_getCreateEventData:$.noop,_create:$.noop,_init:$.noop,destroy:function destroy(){var that=this;this._destroy();$.each(this.classesElementLookup,function(key,value){that._removeClass(value,key);});// We can probably remove the unbind calls in 2.0 // all event bindings should go through this._on() this.element.off(this.eventNamespace).removeData(this.widgetFullName);this.widget().off(this.eventNamespace).removeAttr('aria-disabled');// Clean up events and states this.bindings.off(this.eventNamespace);},_destroy:$.noop,widget:function widget(){return this.element;},option:function option(key,value){var options=key;var parts;var curOption;var i;if(arguments.length===0){// Don't return a reference to the internal hash return $.widget.extend({},this.options);}if(typeof key==='string'){// Handle nested keys, e.g., "foo.bar" => { foo: { bar: ___ } } options={};parts=key.split('.');key=parts.shift();if(parts.length){curOption=options[key]=$.widget.extend({},this.options[key]);for(i=0;i>label: Position //>>group: Core //>>description: Positions elements relative to other elements. //>>docs: http://api.jqueryui.com/position/ //>>demos: http://jqueryui.com/position/ (function(){var cachedScrollbarWidth,max=Math.max,abs=Math.abs,rhorizontal=/left|center|right/,rvertical=/top|center|bottom/,roffset=/[\+\-]\d+(\.[\d]+)?%?/,rposition=/^\w+/,rpercent=/%$/,_position=$.fn.position;function getOffsets(offsets,width,height){return[parseFloat(offsets[0])*(rpercent.test(offsets[0])?width/100:1),parseFloat(offsets[1])*(rpercent.test(offsets[1])?height/100:1)];}function parseCss(element,property){return parseInt($.css(element,property),10)||0;}function getDimensions(elem){var raw=elem[0];if(raw.nodeType===9){return{width:elem.width(),height:elem.height(),offset:{top:0,left:0}};}if($.isWindow(raw)){return{width:elem.width(),height:elem.height(),offset:{top:elem.scrollTop(),left:elem.scrollLeft()}};}if(raw.preventDefault){return{width:0,height:0,offset:{top:raw.pageY,left:raw.pageX}};}return{width:elem.outerWidth(),height:elem.outerHeight(),offset:elem.offset()};}$.position={scrollbarWidth:function scrollbarWidth(){if(cachedScrollbarWidth!==undefined){return cachedScrollbarWidth;}var w1,w2,div=$('
"+"
"),innerDiv=div.children()[0];$('body').append(div);w1=innerDiv.offsetWidth;div.css('overflow','scroll');w2=innerDiv.offsetWidth;if(w1===w2){w2=div[0].clientWidth;}div.remove();return cachedScrollbarWidth=w1-w2;},getScrollInfo:function getScrollInfo(within){var overflowX=within.isWindow||within.isDocument?'':within.element.css('overflow-x'),overflowY=within.isWindow||within.isDocument?'':within.element.css('overflow-y'),hasOverflowX=overflowX==='scroll'||overflowX==='auto'&&within.width0?'right':'center',vertical:bottom<0?'top':top>0?'bottom':'middle'};if(targetWidthmax(abs(top),abs(bottom))){feedback.important='horizontal';}else{feedback.important='vertical';}options.using.call(this,props,feedback);};}elem.offset($.extend(position,{using:using}));});};$.ui.position={fit:{left:function left(position,data){var within=data.within,withinOffset=within.isWindow?within.scrollLeft:within.offset.left,outerWidth=within.width,collisionPosLeft=position.left-data.collisionPosition.marginLeft,overLeft=withinOffset-collisionPosLeft,overRight=collisionPosLeft+data.collisionWidth-outerWidth-withinOffset,newOverRight;// Element is wider than within if(data.collisionWidth>outerWidth){// Element is initially over the left side of within if(overLeft>0&&overRight<=0){newOverRight=position.left+overLeft+data.collisionWidth-outerWidth-withinOffset;position.left+=overLeft-newOverRight;// Element is initially over right side of within }else if(overRight>0&&overLeft<=0){position.left=withinOffset;// Element is initially over both left and right sides of within }else{if(overLeft>overRight){position.left=withinOffset+outerWidth-data.collisionWidth;}else{position.left=withinOffset;}}// Too far left -> align with left edge }else if(overLeft>0){position.left+=overLeft;// Too far right -> align with right edge }else if(overRight>0){position.left-=overRight;// Adjust based on position and margin }else{position.left=max(position.left-collisionPosLeft,position.left);}},top:function top(position,data){var within=data.within,withinOffset=within.isWindow?within.scrollTop:within.offset.top,outerHeight=data.within.height,collisionPosTop=position.top-data.collisionPosition.marginTop,overTop=withinOffset-collisionPosTop,overBottom=collisionPosTop+data.collisionHeight-outerHeight-withinOffset,newOverBottom;// Element is taller than within if(data.collisionHeight>outerHeight){// Element is initially over the top of within if(overTop>0&&overBottom<=0){newOverBottom=position.top+overTop+data.collisionHeight-outerHeight-withinOffset;position.top+=overTop-newOverBottom;// Element is initially over bottom of within }else if(overBottom>0&&overTop<=0){position.top=withinOffset;// Element is initially over both top and bottom of within }else{if(overTop>overBottom){position.top=withinOffset+outerHeight-data.collisionHeight;}else{position.top=withinOffset;}}// Too far up -> align with top }else if(overTop>0){position.top+=overTop;// Too far down -> align with bottom edge }else if(overBottom>0){position.top-=overBottom;// Adjust based on position and margin }else{position.top=max(position.top-collisionPosTop,position.top);}}},flip:{left:function left(position,data){var within=data.within,withinOffset=within.offset.left+within.scrollLeft,outerWidth=within.width,offsetLeft=within.isWindow?within.scrollLeft:within.offset.left,collisionPosLeft=position.left-data.collisionPosition.marginLeft,overLeft=collisionPosLeft-offsetLeft,overRight=collisionPosLeft+data.collisionWidth-outerWidth-offsetLeft,myOffset=data.my[0]==='left'?-data.elemWidth:data.my[0]==='right'?data.elemWidth:0,atOffset=data.at[0]==='left'?data.targetWidth:data.at[0]==='right'?-data.targetWidth:0,offset=-2*data.offset[0],newOverRight,newOverLeft;if(overLeft<0){newOverRight=position.left+myOffset+atOffset+offset+data.collisionWidth-outerWidth-withinOffset;if(newOverRight<0||newOverRight0){newOverLeft=position.left-data.collisionPosition.marginLeft+myOffset+atOffset+offset-offsetLeft;if(newOverLeft>0||abs(newOverLeft)0){newOverTop=position.top-data.collisionPosition.marginTop+myOffset+atOffset+offset-offsetTop;if(newOverTop>0||abs(newOverTop)>label: :data Selector //>>group: Core //>>description: Selects elements which have data stored under the specified key. //>>docs: http://api.jqueryui.com/data-selector/ var data=$.extend($.expr[':'],{data:$.expr.createPseudo?$.expr.createPseudo(function(dataName){return function(elem){return!!$.data(elem,dataName);};}):// Support: jQuery <1.8 function(elem,i,match){return!!$.data(elem,match[3]);}});/*! * jQuery UI Disable Selection 1.12.1 * http://jqueryui.com * * Copyright jQuery Foundation and other contributors * Released under the MIT license. * http://jquery.org/license */ //>>label: disableSelection //>>group: Core //>>description: Disable selection of text content within the set of matched elements. //>>docs: http://api.jqueryui.com/disableSelection/ // This file is deprecated var disableSelection=$.fn.extend({disableSelection:function(){var eventType='onselectstart'in document.createElement('div')?'selectstart':'mousedown';return function(){return this.on(eventType+'.ui-disableSelection',function(event){event.preventDefault();});};}(),enableSelection:function enableSelection(){return this.off('.ui-disableSelection');}});/*! * jQuery UI Focusable 1.12.1 * http://jqueryui.com * * Copyright jQuery Foundation and other contributors * Released under the MIT license. * http://jquery.org/license */ //>>label: :focusable Selector //>>group: Core //>>description: Selects elements which can be focused. //>>docs: http://api.jqueryui.com/focusable-selector/ // Selectors $.ui.focusable=function(element,hasTabindex){var map,mapName,img,focusableIfVisible,fieldset,nodeName=element.nodeName.toLowerCase();if('area'===nodeName){map=element.parentNode;mapName=map.name;if(!element.href||!mapName||map.nodeName.toLowerCase()!=='map'){return false;}img=$("img[usemap='#"+mapName+"']");return img.length>0&&img.is(':visible');}if(/^(input|select|textarea|button|object)$/.test(nodeName)){focusableIfVisible=!element.disabled;if(focusableIfVisible){// Form controls within a disabled fieldset are disabled. // However, controls within the fieldset's legend do not get disabled. // Since controls generally aren't placed inside legends, we skip // this portion of the check. fieldset=$(element).closest('fieldset')[0];if(fieldset){focusableIfVisible=!fieldset.disabled;}}}else if('a'===nodeName){focusableIfVisible=element.href||hasTabindex;}else{focusableIfVisible=hasTabindex;}return focusableIfVisible&&$(element).is(':visible')&&visible($(element));};// Support: IE 8 only // IE 8 doesn't resolve inherit to visible/hidden for computed values function visible(element){var visibility=element.css('visibility');while(visibility==='inherit'){element=element.parent();visibility=element.css('visibility');}return visibility!=='hidden';}$.extend($.expr[':'],{focusable:function focusable(element){return $.ui.focusable(element,$.attr(element,'tabindex')!=null);}});var focusable=$.ui.focusable;// Support: IE8 Only // IE8 does not support the form attribute and when it is supplied. It overwrites the form prop // with a string, so we need to find the proper form. var form=$.fn.form=function(){return typeof this[0].form==='string'?this.closest('form'):$(this[0].form);};/*! * jQuery UI Form Reset Mixin 1.12.1 * http://jqueryui.com * * Copyright jQuery Foundation and other contributors * Released under the MIT license. * http://jquery.org/license */ //>>label: Form Reset Mixin //>>group: Core //>>description: Refresh input widgets when their form is reset //>>docs: http://api.jqueryui.com/form-reset-mixin/ var formResetMixin=$.ui.formResetMixin={_formResetHandler:function _formResetHandler(){var form=$(this);// Wait for the form reset to actually happen before refreshing setTimeout(function(){var instances=form.data('ui-form-reset-instances');$.each(instances,function(){this.refresh();});});},_bindFormResetHandler:function _bindFormResetHandler(){this.form=this.element.form();if(!this.form.length){return;}var instances=this.form.data('ui-form-reset-instances')||[];if(!instances.length){// We don't use _on() here because we use a single event handler per form this.form.on('reset.ui-form-reset',this._formResetHandler);}instances.push(this);this.form.data('ui-form-reset-instances',instances);},_unbindFormResetHandler:function _unbindFormResetHandler(){if(!this.form.length){return;}var instances=this.form.data('ui-form-reset-instances');instances.splice($.inArray(this,instances),1);if(instances.length){this.form.data('ui-form-reset-instances',instances);}else{this.form.removeData('ui-form-reset-instances').off('reset.ui-form-reset');}}};/*! * jQuery UI Support for jQuery core 1.7.x 1.12.1 * http://jqueryui.com * * Copyright jQuery Foundation and other contributors * Released under the MIT license. * http://jquery.org/license * */ //>>label: jQuery 1.7 Support //>>group: Core //>>description: Support version 1.7.x of jQuery core // Support: jQuery 1.7 only // Not a great way to check versions, but since we only support 1.7+ and only // need to detect <1.8, this is a simple check that should suffice. Checking // for "1.7." would be a bit safer, but the version string is 1.7, not 1.7.0 // and we'll never reach 1.70.0 (if we do, we certainly won't be supporting // 1.7 anymore). See #11197 for why we're not using feature detection. if($.fn.jquery.substring(0,3)==='1.7'){// Setters for .innerWidth(), .innerHeight(), .outerWidth(), .outerHeight() // Unlike jQuery Core 1.8+, these only support numeric values to set the // dimensions in pixels $.each(['Width','Height'],function(i,name){var side=name==='Width'?['Left','Right']:['Top','Bottom'],type=name.toLowerCase(),orig={innerWidth:$.fn.innerWidth,innerHeight:$.fn.innerHeight,outerWidth:$.fn.outerWidth,outerHeight:$.fn.outerHeight};function reduce(elem,size,border,margin){$.each(side,function(){size-=parseFloat($.css(elem,'padding'+this))||0;if(border){size-=parseFloat($.css(elem,'border'+this+'Width'))||0;}if(margin){size-=parseFloat($.css(elem,'margin'+this))||0;}});return size;}$.fn['inner'+name]=function(size){if(size===undefined){return orig['inner'+name].call(this);}return this.each(function(){$(this).css(type,reduce(this,size)+'px');});};$.fn['outer'+name]=function(size,margin){if(typeof size!=='number'){return orig['outer'+name].call(this,size);}return this.each(function(){$(this).css(type,reduce(this,size,true,margin)+'px');});};});$.fn.addBack=function(selector){return this.add(selector==null?this.prevObject:this.prevObject.filter(selector));};}/*! * jQuery UI Keycode 1.12.1 * http://jqueryui.com * * Copyright jQuery Foundation and other contributors * Released under the MIT license. * http://jquery.org/license */ //>>label: Keycode //>>group: Core //>>description: Provide keycodes as keynames //>>docs: http://api.jqueryui.com/jQuery.ui.keyCode/ var keycode=$.ui.keyCode={BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38};// Internal use only var escapeSelector=$.ui.escapeSelector=function(){var selectorEscape=/([!"#$%&'()*+,./:;<=>?@[\]^`{|}~])/g;return function(selector){return selector.replace(selectorEscape,'\\$1');};}();/*! * jQuery UI Labels 1.12.1 * http://jqueryui.com * * Copyright jQuery Foundation and other contributors * Released under the MIT license. * http://jquery.org/license */ //>>label: labels //>>group: Core //>>description: Find all the labels associated with a given input //>>docs: http://api.jqueryui.com/labels/ var labels=$.fn.labels=function(){var ancestor,selector,id,labels,ancestors;// Check control.labels first if(this[0].labels&&this[0].labels.length){return this.pushStack(this[0].labels);}// Support: IE <= 11, FF <= 37, Android <= 2.3 only // Above browsers do not support control.labels. Everything below is to support them // as well as document fragments. control.labels does not work on document fragments labels=this.eq(0).parents('label');// Look for the label based on the id id=this.attr('id');if(id){// We don't search against the document in case the element // is disconnected from the DOM ancestor=this.eq(0).parents().last();// Get a full set of top level ancestors ancestors=ancestor.add(ancestor.length?ancestor.siblings():this.siblings());// Create a selector for the label based on the id selector="label[for='"+$.ui.escapeSelector(id)+"']";labels=labels.add(ancestors.find(selector).addBack(selector));}// Return whatever we have found for labels return this.pushStack(labels);};/*! * jQuery UI Scroll Parent 1.12.1 * http://jqueryui.com * * Copyright jQuery Foundation and other contributors * Released under the MIT license. * http://jquery.org/license */ //>>label: scrollParent //>>group: Core //>>description: Get the closest ancestor element that is scrollable. //>>docs: http://api.jqueryui.com/scrollParent/ var scrollParent=$.fn.scrollParent=function(includeHidden){var position=this.css('position'),excludeStaticParent=position==='absolute',overflowRegex=includeHidden?/(auto|scroll|hidden)/:/(auto|scroll)/,scrollParent=this.parents().filter(function(){var parent=$(this);if(excludeStaticParent&&parent.css('position')==='static'){return false;}return overflowRegex.test(parent.css('overflow')+parent.css('overflow-y')+parent.css('overflow-x'));}).eq(0);return position==='fixed'||!scrollParent.length?$(this[0].ownerDocument||document):scrollParent;};/*! * jQuery UI Tabbable 1.12.1 * http://jqueryui.com * * Copyright jQuery Foundation and other contributors * Released under the MIT license. * http://jquery.org/license */ //>>label: :tabbable Selector //>>group: Core //>>description: Selects elements which can be tabbed to. //>>docs: http://api.jqueryui.com/tabbable-selector/ var tabbable=$.extend($.expr[':'],{tabbable:function tabbable(element){var tabIndex=$.attr(element,'tabindex'),hasTabindex=tabIndex!=null;return(!hasTabindex||tabIndex>=0)&&$.ui.focusable(element,hasTabindex);}});/*! * jQuery UI Unique ID 1.12.1 * http://jqueryui.com * * Copyright jQuery Foundation and other contributors * Released under the MIT license. * http://jquery.org/license */ //>>label: uniqueId //>>group: Core //>>description: Functions to generate and remove uniqueId's //>>docs: http://api.jqueryui.com/uniqueId/ var uniqueId=$.fn.extend({uniqueId:function(){var uuid=0;return function(){return this.each(function(){if(!this.id){this.id='ui-id-'+ ++uuid;}});};}(),removeUniqueId:function removeUniqueId(){return this.each(function(){if(/^ui-id-\d+$/.test(this.id)){$(this).removeAttr('id');}});}});// This file is deprecated var ie=$.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase());/*! * jQuery UI Mouse 1.12.1 * http://jqueryui.com * * Copyright jQuery Foundation and other contributors * Released under the MIT license. * http://jquery.org/license */ //>>label: Mouse //>>group: Widgets //>>description: Abstracts mouse-based interactions to assist in creating certain widgets. //>>docs: http://api.jqueryui.com/mouse/ var mouseHandled=false;$(document).on('mouseup',function(){mouseHandled=false;});var widgetsMouse=$.widget('ui.mouse',{version:'1.12.1',options:{cancel:'input, textarea, button, select, option',distance:1,delay:0},_mouseInit:function _mouseInit(){var that=this;this.element.on('mousedown.'+this.widgetName,function(event){return that._mouseDown(event);}).on('click.'+this.widgetName,function(event){if(true===$.data(event.target,that.widgetName+'.preventClickEvent')){$.removeData(event.target,that.widgetName+'.preventClickEvent');event.stopImmediatePropagation();return false;}});this.started=false;},// TODO: make sure destroying one instance of mouse doesn't mess with // other instances of mouse _mouseDestroy:function _mouseDestroy(){this.element.off('.'+this.widgetName);if(this._mouseMoveDelegate){this.document.off('mousemove.'+this.widgetName,this._mouseMoveDelegate).off('mouseup.'+this.widgetName,this._mouseUpDelegate);}},_mouseDown:function _mouseDown(event){// don't let more than one widget handle mouseStart if(mouseHandled){return;}this._mouseMoved=false;// We may have missed mouseup (out of window) this._mouseStarted&&this._mouseUp(event);this._mouseDownEvent=event;var that=this,btnIsLeft=event.which===1,// event.target.nodeName works around a bug in IE 8 with // disabled inputs (#7620) elIsCancel=typeof this.options.cancel==='string'&&event.target.nodeName?$(event.target).closest(this.options.cancel).length:false;if(!btnIsLeft||elIsCancel||!this._mouseCapture(event)){return true;}this.mouseDelayMet=!this.options.delay;if(!this.mouseDelayMet){this._mouseDelayTimer=setTimeout(function(){that.mouseDelayMet=true;},this.options.delay);}if(this._mouseDistanceMet(event)&&this._mouseDelayMet(event)){this._mouseStarted=this._mouseStart(event)!==false;if(!this._mouseStarted){event.preventDefault();return true;}}// Click event may never have fired (Gecko & Opera) if(true===$.data(event.target,this.widgetName+'.preventClickEvent')){$.removeData(event.target,this.widgetName+'.preventClickEvent');}// These delegates are required to keep context this._mouseMoveDelegate=function(event){return that._mouseMove(event);};this._mouseUpDelegate=function(event){return that._mouseUp(event);};this.document.on('mousemove.'+this.widgetName,this._mouseMoveDelegate).on('mouseup.'+this.widgetName,this._mouseUpDelegate);event.preventDefault();mouseHandled=true;return true;},_mouseMove:function _mouseMove(event){// Only check for mouseups outside the document if you've moved inside the document // at least once. This prevents the firing of mouseup in the case of IE<9, which will // fire a mousemove event if content is placed under the cursor. See #7778 // Support: IE <9 if(this._mouseMoved){// IE mouseup check - mouseup happened when mouse was out of window if($.ui.ie&&(!document.documentMode||document.documentMode<9)&&!event.button){return this._mouseUp(event);// Iframe mouseup check - mouseup occurred in another document }else if(!event.which){// Support: Safari <=8 - 9 // Safari sets which to 0 if you press any of the following keys // during a drag (#14461) if(event.originalEvent.altKey||event.originalEvent.ctrlKey||event.originalEvent.metaKey||event.originalEvent.shiftKey){this.ignoreMissingWhich=true;}else if(!this.ignoreMissingWhich){return this._mouseUp(event);}}}if(event.which||event.button){this._mouseMoved=true;}if(this._mouseStarted){this._mouseDrag(event);return event.preventDefault();}if(this._mouseDistanceMet(event)&&this._mouseDelayMet(event)){this._mouseStarted=this._mouseStart(this._mouseDownEvent,event)!==false;this._mouseStarted?this._mouseDrag(event):this._mouseUp(event);}return!this._mouseStarted;},_mouseUp:function _mouseUp(event){this.document.off('mousemove.'+this.widgetName,this._mouseMoveDelegate).off('mouseup.'+this.widgetName,this._mouseUpDelegate);if(this._mouseStarted){this._mouseStarted=false;if(event.target===this._mouseDownEvent.target){$.data(event.target,this.widgetName+'.preventClickEvent',true);}this._mouseStop(event);}if(this._mouseDelayTimer){clearTimeout(this._mouseDelayTimer);delete this._mouseDelayTimer;}this.ignoreMissingWhich=false;mouseHandled=false;event.preventDefault();},_mouseDistanceMet:function _mouseDistanceMet(event){return Math.max(Math.abs(this._mouseDownEvent.pageX-event.pageX),Math.abs(this._mouseDownEvent.pageY-event.pageY))>=this.options.distance;},_mouseDelayMet:function/* event */_mouseDelayMet(){return this.mouseDelayMet;},// These are placeholder methods, to be overriden by extending plugin _mouseStart:function/* event */_mouseStart(){},_mouseDrag:function/* event */_mouseDrag(){},_mouseStop:function/* event */_mouseStop(){},_mouseCapture:function/* event */_mouseCapture(){return true;}});// $.ui.plugin is deprecated. Use $.widget() extensions instead. var plugin=$.ui.plugin={add:function add(module,option,set){var i,proto=$.ui[module].prototype;for(i in set){proto.plugins[i]=proto.plugins[i]||[];proto.plugins[i].push([option,set[i]]);}},call:function call(instance,name,args,allowDisconnected){var i,set=instance.plugins[name];if(!set){return;}if(!allowDisconnected&&(!instance.element[0].parentNode||instance.element[0].parentNode.nodeType===11)){return;}for(i=0;i try{activeElement=document.activeElement;}catch(error){activeElement=document.body;}// Support: IE 9 - 11 only // IE may return null instead of an element // Interestingly, this only seems to occur when NOT in an iframe if(!activeElement){activeElement=document.body;}// Support: IE 11 only // IE11 returns a seemingly empty object in some cases when accessing // document.activeElement from an \n
\n ")); viewTemplate.html(contentIframe); var table = viewTemplate.find('table').first(); if (table.length && content.parent().length) { content.parent().css({ 'background-color': table.css('background-color') }); } }); content.append(viewTemplate); winDetails.setContent(content); winDetails.show(); }, icon: ' ' }); if (id_history > 0) div.append(view); div.append(details); div.append(button); return div; }, emails_count: function emails_count(item, value) { return '' + (parseInt(value) ? value : '0') + ''; }, emails_success: function emails_success(item, value) { return '' + (parseInt(value) ? value : '0') + ''; }, emails_error: function emails_error(item, value) { return '' + (parseInt(value) ? value : '0') + ''; }, unsubscribed: function unsubscribed(item, value) { var button = $(''); if (parseInt(value) <= 0) return value; var detailsContent = $('
'); function getDetail(id) { $.postAjax({ submit: 'getUnsubscribedDetails', id_newsletter: id }, 'html').done(function (response) { detailsContent.html(response); }); } button.css({ display: 'inline-block' }); button.on('click', function () { getDetail(item.data.id_newsletter_pro_tpl_history); var content = $('
'); var winDetails = ui.TaskWindow({ width: 1024, height: 800, className: 'gk-task-window-details', show: function show(win) {} }); winDetails.setHeader(l('unsubscribed')); content.append(detailsContent); winDetails.setContent(content); winDetails.show(); }); return button; }, fwd_unsubscribed: function fwd_unsubscribed(item, value) { var button = $(''); if (parseInt(value) <= 0) return value; var detailsContent = $('
'); function getDetail(id) { $.postAjax({ submit: 'getTaskFwdUnsubscribedDetails', id_newsletter: id }, 'html').done(function (response) { detailsContent.html(response); }); } button.css({ display: 'inline-block' }); button.on('click', function () { getDetail(item.data.id_newsletter_pro_tpl_history); var content = $('
'); var winDetails = ui.TaskWindow({ width: 1024, height: 800, className: 'gk-task-window-details', show: function show(win) {} }); winDetails.setHeader(l('unsubscribed')); content.append(detailsContent); winDetails.setContent(content); winDetails.show(); }); return button; }, error_msg: function error_msg(item, value) { var error_msg = $(''), messages = getMessage(value); function getMessage(obj) { if (_typeof(value) === 'object') { var arr = []; for (var i in obj) { arr.push(obj[i]); } if (arr.length > 0) return arr.join('
'); } else if (typeof value === 'string') { return value; } return false; } if (messages) { error_msg.css({ display: 'inline-block' }); error_msg.show(); error_msg.on('click', function () { var winMessage = ui.TaskWindow({ width: 425, className: 'gk-task-window', show: function show(win) {} }); winMessage.setHeader(l('errors')); winMessage.setContent('' + messages.replace(/\\'/g, '"') + ''); winMessage.show(); }); } return error_msg; } } }); var dataModelHistory = new gk.data.Model({ id: 'id_newsletter_pro_task' }); var dataSourceTaskHistory = new gk.data.DataSource({ pageSize: 10, transport: { read: { url: NewsletterPro.dataStorage.get('ajax_url') + '&submit=getTasksHistory', dataType: 'json' }, destroy: { url: NewsletterPro.dataStorage.get('ajax_url') + '&submit=deleteTask&deleteTask', type: 'DELETE', dateType: 'json', success: function success(response, itemData) { if (!response) alert(l('delete task')); }, error: function error(data, itemData) { alert(l('delete task')); }, complete: function complete(data, itemData) {} } }, schema: { model: dataModelHistory }, trySteps: 2, errors: { read: function read(xhr, ajaxOptions, thrownError) { dataSourceTaskHistory.syncStepAvailableAdd(3000, function () { dataSourceTaskHistory.sync(); }); } } }); dom.taskHistory.gkGrid({ dataSource: dataSourceTaskHistory, selectable: false, currentPage: 1, pageable: true, template: { actions: function actions(item, value) { var data = item.data, div = $('
'), steps = typeof item.data.steps !== 'undefined' ? item.data.steps.split(',') : null, detailsContent = $('
'), id_history = parseInt(item.data.id_newsletter_pro_tpl_history), stepsButtons; function getDetail(id) { $.postAjax({ submit: 'getTasksHistoryDetail', getTasksHistoryDetail: id }, 'html').done(function (response) { detailsContent.html(response); }); } function createButton(cfg) { var button = { id: null, instance: null, init: function init(cfg) { var self = this, id = cfg.step, count = cfg.count; self.id = id; self.instance = $('' + l('step') + ' ' + count + ''); if (count == 1) { getDetail(self.id); self.instance.addClass('selected'); } (function addEvents(instance) { instance.on('click', function (event) { click.call(instance, self, event); }); })(self.instance); function click(obj) { if (stepsButtons != null) { var buttons = stepsButtons.find('a.selected'); $.each(buttons, function (index, button) { $(button).removeClass('selected'); }); } this.addClass('selected'); getDetail(obj.id); } return self; }, getInstance: function getInstance() { return this.instance; } }.init(cfg); return button; } function createButtons() { var count = 0, buttons = $('
'); $.each(steps, function (index, step) { var button = createButton({ step: step, count: ++count }); buttons.append(button.getInstance()); }); return buttons; } var button = $('#task-history-delete').gkButton({ name: 'delete', title: l('delete'), className: 'btn btn-default btn-margin task-delete', item: item, command: 'delete', confirm: function (_confirm3) { function confirm() { return _confirm3.apply(this, arguments); } confirm.toString = function () { return _confirm3.toString(); }; return confirm; }(function () { return confirm(l('delete record')); }), icon: ' ' }); var details = $('#task-history-details').gkButton({ name: 'history-details', title: l('details'), className: 'btn-margin task-history-details', click: function click(event) { var content = $('
'); stepsButtons = createButtons(); var winDetails = ui.TaskWindow({ width: 1024, height: 800, className: 'gk-task-window-details', show: function show(win) {} }); winDetails.setHeader(l('details')); if (steps.length > 1) content.append(stepsButtons); content.append(detailsContent); winDetails.setContent(content); winDetails.show(); }, icon: ' ' }); var view = $('#task-history-view').gkButton({ name: 'history-view', title: l('view'), className: 'btn btn-default btn-margin task-history-view', click: function click(event) { var content = $('
'), open, viewTemplate; var winDetails = gkWindow({ width: 1024, height: 800, className: 'gk-task-window-view', show: function show(win) {} }); var header = $(''), title = l('view template'), open = $('' + l('veiw in a new window') + ''); header.append(title); header.append(open); winDetails.setHeader(header); viewTemplate = $('
'); $.postAjax({ submit: 'renderTemplateHistory', renderTemplateHistory: id_history }).done(function (response) { open.attr('href', response.url); var contentIframe = $("\n
\n \n \n
\n ")); viewTemplate.html(contentIframe); var table = viewTemplate.find('table').first(); if (table.length && content.parent().length) { content.parent().css({ 'background-color': table.css('background-color') }); } }); content.append(viewTemplate); winDetails.setContent(content); winDetails.show(); }, icon: ' ' }); if (id_history > 0) div.append(view); div.append(details); div.append(button); return div; }, emails_count: function emails_count(item, value) { return '' + (parseInt(value) ? value : '0') + ''; }, emails_success: function emails_success(item, value) { return '' + (parseInt(value) ? value : '0') + ''; }, emails_error: function emails_error(item, value) { return '' + (parseInt(value) ? value : '0') + ''; }, unsubscribed: function unsubscribed(item, value) { var button = $(''); if (parseInt(value) <= 0) return value; var detailsContent = $('
'); function getDetail(id) { $.postAjax({ submit: 'getTaskUnsubscribedDetails', id_newsletter: id }, 'html').done(function (response) { detailsContent.html(response); }); } button.css({ display: 'inline-block' }); button.on('click', function () { getDetail(item.data.id_newsletter_pro_tpl_history); var content = $('
'); var winDetails = ui.TaskWindow({ width: 1024, height: 800, className: 'gk-task-window-details', show: function show(win) {} }); winDetails.setHeader(l('unsubscribed')); content.append(detailsContent); winDetails.setContent(content); winDetails.show(); }); return button; }, fwd_unsubscribed: function fwd_unsubscribed(item, value) { var button = $(''); if (parseInt(value) <= 0) return value; var detailsContent = $('
'); function getDetail(id) { $.postAjax({ submit: 'getTaskFwdUnsubscribedDetails', id_newsletter: id }, 'html').done(function (response) { detailsContent.html(response); }); } button.css({ display: 'inline-block' }); button.on('click', function () { getDetail(item.data.id_newsletter_pro_tpl_history); var content = $('
'); var winDetails = ui.TaskWindow({ width: 1024, height: 800, className: 'gk-task-window-details', show: function show(win) {} }); winDetails.setHeader(l('unsubscribed')); content.append(detailsContent); winDetails.setContent(content); winDetails.show(); }); return button; }, error_msg: function error_msg(item, value) { var error_msg = $(''), messages = getMessage(value); function getMessage(obj) { if (_typeof(value) === 'object') { var arr = []; for (var i in obj) { arr.push(obj[i]); } if (arr.length > 0) return arr.join('
'); } else if (typeof value === 'string') { return value; } return false; } if (messages) { error_msg.css({ display: 'inline-block' }); error_msg.show(); error_msg.on('click', function () { var winMessage = ui.TaskWindow({ width: 425, className: 'gk-task-window', show: function show(win) {} }); winMessage.setHeader('Errors'); winMessage.setContent('' + messages.replace(/\\'/g, '"') + ''); winMessage.show(); }); } return error_msg; } } }); dom.clearTaskHistory.on('click', function () { $.postAjax({ submit: 'clearTaskHistory', clearTaskHistory: true }).done(function (response) { if (response.status) { var taskHistory = dataSourceTaskHistory || NewsletterPro.modules.task.ui.components.taskHistory; taskHistory.sync(); } else { alert(response.msg); } }); }); dom.clearSendHistory.on('click', function () { $.postAjax({ submit: 'clearSendHistory', clearSendHistory: true }).done(function (response) { if (response.status) { var sendHistory = dataSourceSendHistory || NewsletterPro.modules.task.ui.components.sendHistory; sendHistory.sync(); } else { alert(response.msg); } }); }); dom.clearSendDetails.on('click', function () { box.showAjaxLoader(dom.clearSendDetails); $.postAjax({ submit: 'clearSendHistoryDetails' }).done(function (response) { if (!response.status) box.alertErrors(response.errors); }).always(function () { box.hideAjaxLoader(dom.clearSendDetails); }); }); dom.clearTaskDetails.on('click', function () { box.showAjaxLoader(dom.clearTaskDetails); $.postAjax({ submit: 'clearTaskHistoryDetails' }).done(function (response) { if (!response.status) box.alertErrors(response.errors); }).always(function () { box.hideAjaxLoader(dom.clearTaskDetails); }); }); dom.taskMoreInfoButton.on('click', function (event) { dom.taskMoreInfo.toggle(); if (dom.taskMoreInfo.is(':visible')) { $(this).text(l('less info')); } else { $(this).text(l('more info')); } }); ui.add('taskList', dataSource); ui.add('taskHistory', dataSourceTaskHistory); ui.add('sendHistory', dataSourceSendHistory); ui.add('taskWindow', win); }); return self; }, initStorage: function initStorage() { var box = NewsletterPro; this.storage = { template: this.dom.taskTemplateSelect.val(), emails: [], mysql_date: '', smtp: '', id_lang: null, id_newsletter_pro_smtp: 0, sleep: parseInt(this.dom.taskSleep.val()) || 5, send_method: 'mail' }; }, setStorage: function setStorage(name, value) { this.storage[name] = value; }, ready: function ready(func) { var self = this; $(document).ready(function () { var template = $('#task-template'), templateHTML = $($.trim(template.html())); if (typeof templateHTML[1] !== 'undefined') templateHTML = $(templateHTML[1]); self.dom = { chooseNewsletterTemplate: $('#change-newsletter-template'), taskButton: $('#new-task'), testEmailInput: $('#test-email-input'), taskList: $('#task-list'), taskHistory: $('#task-history'), clearTaskHistory: $('#clear-task-history'), clearTaskDetails: $('#clear-task-details'), clearSendHistory: $('#clear-send-history'), clearSendDetails: $('#clear-send-details'), sendHistory: $('#send-history'), taskMoreInfo: $('#task-more-info'), taskMoreInfoButton: $('#task-more-info-button'), taskTemplate: templateHTML, datepicker: templateHTML.find('#task-datepicker'), emailsCount: templateHTML.find('#selected_emails_count'), taskSmptSelect: templateHTML.find('#task-smtp-select'), taskTemplateSelect: templateHTML.find('#task-select-template'), taskSmtpTest: templateHTML.find('#task-smtp-test'), taskSmtpTestMessage: templateHTML.find('#task-smtp-test-message'), taskEmailTest: templateHTML.find('#task-email-test'), addTask: templateHTML.find('#add-task'), taskSleep: templateHTML.find('#task-sleep'), btnTaskLangSelectTest: $('#task-test-email-lang-select'), mailMethod: templateHTML.find('#task-mail-method'), smtpMethod: templateHTML.find('#task-smtp-method'), smtpSelectContainer: templateHTML.find('#div-task-smtp-select') }; func(self.dom); }); }, getStorage: function getStorage() { return this.storage; }, taskClick: function taskClick(self) { var dom = self.dom; var emails = self.getEmails(); if (emails.length == 0) { alert(this.data('trans-noemail')); return false; } self.setStorage('emails', emails); var ui = self.ui, win = ui.components.taskWindow; win.show(); $.postAjax({ submit_template_controller: 'getNewsletterTemplates' }).done(function (response) { if (response.length) { dom.taskTemplateSelect.empty(); for (var i = 0; i < response.length; i++) { var template = response[i], option = ''; dom.taskTemplateSelect.append(option); } } }); var smtp = NewsletterPro.modules.smtp.ui.components.taskSmptSelect, selected = smtp.getSelected(); if (selected != null) self.setStorage('id_newsletter_pro_smtp', selected.data.id_newsletter_pro_smtp); }, getEmails: function getEmails() { return NewsletterProControllers.SendController.getSelectedEmails(); }, ui: { components: {}, init: function init() { return this; }, add: function add(name, value) { this.components[name] = value; }, TaskWindow: function TaskWindow(cfg) { if (!(this instanceof TaskWindow)) return new TaskWindow(cfg); var self = this; task = NewsletterPro.modules.task, l = NewsletterPro.translations.l(NewsletterPro.translations.modules.task); function setTemplate() { var background = $('
'), template = $('
'), body = $('body'), width = cfg.width || 0, height = cfg.height || 0; background.css({ width: '100%', height: '100%', top: 0, left: 0, position: 'fixed', display: 'none', 'z-index': '99999' }); background.appendTo(body); template.css({ width: cfg.width || 'auto', height: cfg.height || 'auto', position: 'fixed', left: width != 0 ? body.width() / 2 - width / 2 : body.width() / 2, top: height != 0 ? $(window).height() / 2 - height / 2 : $(window).height() / 2, display: 'none', 'z-index': '999999' }); template.header = template.find('.gk-header'); template.content = template.find('.gk-content'); template.close = template.find('.gk-close'); template.background = background; template.addClass('gk-task-window'); template.addClass(cfg.className); background.addClass(cfg.className + '-' + 'background'); template.appendTo(body); addEvents(template, background); return template; } function addEvents(template, background) { template.close.on('click', function (event) { self.hide(); }); background.on('click', function () { template.close.trigger('click'); }); $(window).resize(function (event) { self.resetPosition(); }); } this.template = setTemplate(); this.resetPosition = function () { self.template.css({ left: $('body').width() / 2 - self.template.width() / 2, top: $(window).height() / 2 - self.template.height() / 2 }); }; this.setHeader = function (value) { this.template.header.find('.gk-title').html(value); }; this.setContent = function (value) { this.template.content.html(value); }; this.hide = function () { this.template.fadeOut(200); return this.template.background.fadeOut(200).promise(); }; this.show = function () { this.resetPosition(); this.template.fadeIn(200); if (typeof cfg.show === 'function') cfg.show(self); return this.template.background.fadeIn(200).promise(); }; return this; } }.init() }.init(NewsletterPro); /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! jquery */ "./node_modules/jquery/dist/jquery.js"))) /***/ }), /***/ "./src/scss/app.scss": /*!***************************!*\ !*** ./src/scss/app.scss ***! \***************************/ /*! no static exports found */ /***/ (function(module, exports) { // removed by extract-text-webpack-plugin /***/ }), /***/ "./src/scss/bootstrap-datetimepicker.scss": /*!************************************************!*\ !*** ./src/scss/bootstrap-datetimepicker.scss ***! \************************************************/ /*! no static exports found */ /***/ (function(module, exports) { // removed by extract-text-webpack-plugin /***/ }), /***/ "./src/utils/storage.tsx": /*!*******************************!*\ !*** ./src/utils/storage.tsx ***! \*******************************/ /*! exports provided: storage */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; __webpack_require__.r(__webpack_exports__); /* WEBPACK VAR INJECTION */(function($) {/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "storage", function() { return storage; }); /* harmony import */ var _classes_storage__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../classes/storage */ "./src/classes/storage.tsx"); function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); } var storage = new _classes_storage__WEBPACK_IMPORTED_MODULE_0__["Storage"](); // for prestashop 1.6 if (_typeof(window.NewsletterProAppStorage) === 'object') { storage.setObject(window.NewsletterProAppStorage); } $(document).ready(function () { // for prestashop 1.5 if (storage.length() === 0) { storage.setObject(window.NewsletterProAppStorage); } }); /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! jquery */ "./node_modules/jquery/dist/jquery.js"))) /***/ }), /***/ "./src/utils/translate.tsx": /*!*********************************!*\ !*** ./src/utils/translate.tsx ***! \*********************************/ /*! exports provided: translate */ /***/ (function(module, __webpack_exports__, __webpack_require__) { "use strict"; __webpack_require__.r(__webpack_exports__); /* WEBPACK VAR INJECTION */(function($) {/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "translate", function() { return translate; }); /* harmony import */ var _classes_translate__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../classes/translate */ "./src/classes/translate.tsx"); function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); } var translate = new _classes_translate__WEBPACK_IMPORTED_MODULE_0__["Translate"](); // for prestashop 1.6 if (_typeof(window.NewsletterProAppTranslate) === 'object') { translate.setObject(window.NewsletterProAppTranslate, true); } $(document).ready(function () { // for prestashop 1.5 if (translate.length() === 0) { translate.setObject(window.NewsletterProAppTranslate, true); } }); /* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(/*! jquery */ "./node_modules/jquery/dist/jquery.js"))) /***/ }) /******/ }); //# sourceMappingURL=app.js.map