MailPoet Newsletters (New) - Version 3.4.0

Version Description

  • 2018-01-30 =
  • Added: choices of templates are now categorized for clarity;
  • Fixed: plugin activation to be able to create all plugin tables with MySQL strict mode enabled. Thank you @deltafactory!
  • Fixed: importing subscribers with custom fields. Thanks again @deltafactory!
Download this release

Release Info

Developer wysija
Plugin Icon 128x128 MailPoet Newsletters (New)
Version 3.4.0
Comparing to
See all releases

Code changes from version 3.3.6 to 3.4.0

assets/css/{admin.666d9203.css → admin.622ede62.css} RENAMED
@@ -1827,7 +1827,7 @@ div.CodeMirror span.CodeMirror-nonmatchingbracket {color: #a22;}
1827
  .CodeMirror-linewidget {
1828
  position: relative;
1829
  z-index: 2;
1830
- overflow: auto;
1831
  }
1832
 
1833
  .CodeMirror-widget {}
@@ -3399,3 +3399,9 @@ textarea.parsley-error {
3399
  }
3400
  }
3401
 
 
 
 
 
 
 
1827
  .CodeMirror-linewidget {
1828
  position: relative;
1829
  z-index: 2;
1830
+ padding: 0.1px; /* Force widget margins to stay inside of the container */
1831
  }
1832
 
1833
  .CodeMirror-widget {}
3399
  }
3400
  }
3401
 
3402
+ .mailpoet_template_iframe {
3403
+ position: absolute;
3404
+ z-index: -9999;
3405
+ width: 660px;
3406
+ max-width: 660px;
3407
+ }
assets/css/manifest.json CHANGED
@@ -1,6 +1,6 @@
1
  {
2
  "admin-global.css": "admin-global.673373a1.css",
3
- "admin.css": "admin.666d9203.css",
4
  "importExport.css": "importExport.b3745466.css",
5
  "newsletter_editor.css": "newsletter_editor.9cb620b4.css",
6
  "public.css": "public.cae357df.css",
1
  {
2
  "admin-global.css": "admin-global.673373a1.css",
3
+ "admin.css": "admin.622ede62.css",
4
  "importExport.css": "importExport.b3745466.css",
5
  "newsletter_editor.css": "newsletter_editor.9cb620b4.css",
6
  "public.css": "public.cae357df.css",
assets/js/{admin.d5dc3994.js → admin.aaa81cde.js} RENAMED
@@ -1,37 +1,57 @@
1
  webpackJsonp([0],{
2
 
3
- /***/ 495:
4
- /***/ function(module, exports) {
5
 
6
- //Types of elements found in the DOM
7
- module.exports = {
8
- Text: "text", //Text
9
- Directive: "directive", //<? ... ?>
10
- Comment: "comment", //<!-- ... -->
11
- Script: "script", //<script> tags
12
- Style: "style", //<style> tags
13
- Tag: "tag", //Any tag
14
- CDATA: "cdata", //<![CDATA[ ... ]]>
15
 
16
- isTag: function(elem){
17
- return elem.type === "tag" || elem.type === "script" || elem.type === "style";
18
- }
 
 
 
 
 
 
 
19
  };
20
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
21
  /***/ },
22
 
23
  /***/ 0:
24
  /***/ function(module, exports, __webpack_require__) {
25
 
26
  __webpack_require__(1);
27
- __webpack_require__(428);
28
- __webpack_require__(537);
29
- __webpack_require__(541);
30
- __webpack_require__(543);
31
  __webpack_require__(546);
32
- __webpack_require__(551);
33
- __webpack_require__(552);
34
- module.exports = __webpack_require__(556);
 
35
 
36
 
37
  /***/ },
@@ -447,7 +467,7 @@ webpackJsonp([0],{
447
 
448
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
449
 
450
- !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(181), __webpack_require__(276), __webpack_require__(292), __webpack_require__(422)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, Router, MailPoet, Form, ReactStringReplace) {
451
  var fields = [{
452
  name: 'email',
453
  label: MailPoet.I18n.t('email'),
@@ -647,7 +667,7 @@ webpackJsonp([0],{
647
 
648
  /***/ },
649
 
650
- /***/ 428:
651
  /***/ function(module, exports, __webpack_require__) {
652
 
653
  'use strict';
@@ -666,43 +686,43 @@ webpackJsonp([0],{
666
 
667
  var _history = __webpack_require__(244);
668
 
669
- var _wpJsHooks = __webpack_require__(429);
670
 
671
  var _wpJsHooks2 = _interopRequireDefault(_wpJsHooks);
672
 
673
- var _newslettersTypesJsx = __webpack_require__(431);
674
 
675
  var _newslettersTypesJsx2 = _interopRequireDefault(_newslettersTypesJsx);
676
 
677
- var _newslettersTemplatesJsx = __webpack_require__(434);
678
 
679
  var _newslettersTemplatesJsx2 = _interopRequireDefault(_newslettersTemplatesJsx);
680
 
681
- var _newslettersSendJsx = __webpack_require__(518);
682
 
683
  var _newslettersSendJsx2 = _interopRequireDefault(_newslettersSendJsx);
684
 
685
- var _newslettersTypesStandardJsx = __webpack_require__(526);
686
 
687
  var _newslettersTypesStandardJsx2 = _interopRequireDefault(_newslettersTypesStandardJsx);
688
 
689
- var _newslettersTypesNotificationNotificationJsx = __webpack_require__(527);
690
 
691
  var _newslettersTypesNotificationNotificationJsx2 = _interopRequireDefault(_newslettersTypesNotificationNotificationJsx);
692
 
693
- var _newslettersListingsStandardJsx = __webpack_require__(528);
694
 
695
  var _newslettersListingsStandardJsx2 = _interopRequireDefault(_newslettersListingsStandardJsx);
696
 
697
- var _newslettersListingsWelcomeJsx = __webpack_require__(534);
698
 
699
  var _newslettersListingsWelcomeJsx2 = _interopRequireDefault(_newslettersListingsWelcomeJsx);
700
 
701
- var _newslettersListingsNotificationJsx = __webpack_require__(535);
702
 
703
  var _newslettersListingsNotificationJsx2 = _interopRequireDefault(_newslettersListingsNotificationJsx);
704
 
705
- var _newslettersListingsNotification_historyJsx = __webpack_require__(536);
706
 
707
  var _newslettersListingsNotification_historyJsx2 = _interopRequireDefault(_newslettersListingsNotification_historyJsx);
708
 
@@ -751,12 +771,12 @@ webpackJsonp([0],{
751
 
752
  /***/ },
753
 
754
- /***/ 431:
755
  /***/ function(module, exports, __webpack_require__) {
756
 
757
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
758
 
759
- !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(276), __webpack_require__(429), __webpack_require__(181), __webpack_require__(432)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, MailPoet, Hooks, Router, Breadcrumb) {
760
  var NewsletterTypes = React.createClass({
761
  displayName: 'NewsletterTypes',
762
 
@@ -895,7 +915,7 @@ webpackJsonp([0],{
895
 
896
  /***/ },
897
 
898
- /***/ 434:
899
  /***/ function(module, exports, __webpack_require__) {
900
 
901
  'use strict';
@@ -918,17 +938,17 @@ webpackJsonp([0],{
918
 
919
  var _mailpoet2 = _interopRequireDefault(_mailpoet);
920
 
921
- var _reactConfirmAlert = __webpack_require__(435);
922
 
923
  var _classnames = __webpack_require__(277);
924
 
925
  var _classnames2 = _interopRequireDefault(_classnames);
926
 
927
- var _newslettersBreadcrumbJsx = __webpack_require__(432);
928
 
929
  var _newslettersBreadcrumbJsx2 = _interopRequireDefault(_newslettersBreadcrumbJsx);
930
 
931
- var _helpTooltipJsx = __webpack_require__(436);
932
 
933
  var _helpTooltipJsx2 = _interopRequireDefault(_helpTooltipJsx);
934
 
@@ -945,6 +965,9 @@ webpackJsonp([0],{
945
  template.body = JSON.stringify(template.body);
946
  }
947
 
 
 
 
948
  _mailpoet2['default'].Modal.loading(true);
949
 
950
  _mailpoet2['default'].Ajax.post({
@@ -1019,13 +1042,60 @@ webpackJsonp([0],{
1019
  }
1020
  });
1021
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1022
  var NewsletterTemplates = _react2['default'].createClass({
1023
  displayName: 'NewsletterTemplates',
1024
 
1025
  getInitialState: function getInitialState() {
1026
  return {
1027
  loading: false,
1028
- templates: []
 
1029
  };
1030
  },
1031
  componentDidMount: function componentDidMount() {
@@ -1042,22 +1112,61 @@ webpackJsonp([0],{
1042
  api_version: window.mailpoet_api_version,
1043
  endpoint: 'newsletterTemplates',
1044
  action: 'getAll'
1045
- }).always(function () {
1046
- _mailpoet2['default'].Modal.loading(false);
1047
  }).done(function (response) {
1048
  if (_this2.isMounted()) {
1049
  if (response.data.length === 0) {
1050
  response.data = [{
1051
  name: _mailpoet2['default'].I18n.t('mailpoetGuideTemplateTitle'),
1052
  description: _mailpoet2['default'].I18n.t('mailpoetGuideTemplateDescription'),
 
1053
  readonly: '1'
1054
  }];
1055
  }
1056
- _this2.setState({
1057
- templates: response.data,
1058
- loading: false
1059
- });
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1060
  }
 
 
 
 
 
 
 
 
1061
  }).fail(function (response) {
1062
  if (response.errors.length > 0) {
1063
  _mailpoet2['default'].Notice.error(response.errors.map(function (error) {
@@ -1099,7 +1208,7 @@ webpackJsonp([0],{
1099
  });
1100
  },
1101
  handleDeleteTemplate: function handleDeleteTemplate(template) {
1102
- var _this3 = this;
1103
 
1104
  this.setState({ loading: true });
1105
  var onConfirm = function onConfirm() {
@@ -1111,7 +1220,7 @@ webpackJsonp([0],{
1111
  id: template.id
1112
  }
1113
  }).done(function () {
1114
- _this3.getTemplates();
1115
  }).fail(function (response) {
1116
  if (response.errors.length > 0) {
1117
  _mailpoet2['default'].Notice.error(response.errors.map(function (error) {
@@ -1121,7 +1230,7 @@ webpackJsonp([0],{
1121
  });
1122
  };
1123
  var onCancel = function onCancel() {
1124
- _this3.setState({ loading: false });
1125
  };
1126
  (0, _reactConfirmAlert.confirmAlert)({
1127
  title: _mailpoet2['default'].I18n.t('confirmTitle'),
@@ -1143,9 +1252,11 @@ webpackJsonp([0],{
1143
  this.getTemplates();
1144
  },
1145
  render: function render() {
1146
- var _this4 = this;
1147
 
1148
- var templates = this.state.templates.map(function (template, index) {
 
 
1149
  var deleteLink = _react2['default'].createElement(
1150
  'div',
1151
  { className: 'mailpoet_delete' },
@@ -1153,7 +1264,7 @@ webpackJsonp([0],{
1153
  'a',
1154
  {
1155
  href: 'javascript:;',
1156
- onClick: _this4.handleDeleteTemplate.bind(null, template)
1157
  },
1158
  _mailpoet2['default'].I18n.t('delete')
1159
  )
@@ -1163,7 +1274,7 @@ webpackJsonp([0],{
1163
  if (typeof template.thumbnail === 'string' && template.thumbnail.length > 0) {
1164
  thumbnail = _react2['default'].createElement(
1165
  'a',
1166
- { href: 'javascript:;', onClick: _this4.handleShowTemplate.bind(null, template) },
1167
  _react2['default'].createElement('img', { src: template.thumbnail }),
1168
  _react2['default'].createElement('div', { className: 'mailpoet_overlay' })
1169
  );
@@ -1198,7 +1309,7 @@ webpackJsonp([0],{
1198
  'a',
1199
  {
1200
  className: 'button button-secondary',
1201
- onClick: _this4.handleShowTemplate.bind(null, template)
1202
  },
1203
  _mailpoet2['default'].I18n.t('preview')
1204
  ),
@@ -1208,7 +1319,7 @@ webpackJsonp([0],{
1208
  {
1209
  className: 'button button-primary',
1210
  'data-automation-id': 'select_template_' + index,
1211
- onClick: _this4.handleSelectTemplate.bind(null, template)
1212
  },
1213
  _mailpoet2['default'].I18n.t('select')
1214
  )
@@ -1217,6 +1328,14 @@ webpackJsonp([0],{
1217
  );
1218
  });
1219
 
 
 
 
 
 
 
 
 
1220
  var boxClasses = (0, _classnames2['default'])('mailpoet_boxes', 'clearfix', { mailpoet_boxes_loading: this.state.loading });
1221
 
1222
  return _react2['default'].createElement(
@@ -1228,6 +1347,26 @@ webpackJsonp([0],{
1228
  _mailpoet2['default'].I18n.t('selectTemplateTitle')
1229
  ),
1230
  _react2['default'].createElement(_newslettersBreadcrumbJsx2['default'], { step: 'template' }),
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1231
  _react2['default'].createElement(
1232
  'ul',
1233
  { className: boxClasses },
@@ -1243,7 +1382,7 @@ webpackJsonp([0],{
1243
 
1244
  /***/ },
1245
 
1246
- /***/ 435:
1247
  /***/ function(module, exports, __webpack_require__) {
1248
 
1249
  'use strict';
@@ -1420,7 +1559,7 @@ webpackJsonp([0],{
1420
 
1421
  /***/ },
1422
 
1423
- /***/ 436:
1424
  /***/ function(module, exports, __webpack_require__) {
1425
 
1426
  'use strict';
@@ -1431,11 +1570,11 @@ webpackJsonp([0],{
1431
 
1432
  var _react2 = _interopRequireDefault(_react);
1433
 
1434
- var _reactTooltip = __webpack_require__(437);
1435
 
1436
  var _reactTooltip2 = _interopRequireDefault(_reactTooltip);
1437
 
1438
- var _reactHtmlParser = __webpack_require__(450);
1439
 
1440
  var _reactHtmlParser2 = _interopRequireDefault(_reactHtmlParser);
1441
 
@@ -1504,7 +1643,7 @@ webpackJsonp([0],{
1504
 
1505
  /***/ },
1506
 
1507
- /***/ 450:
1508
  /***/ function(module, exports, __webpack_require__) {
1509
 
1510
  'use strict';
@@ -1513,7 +1652,7 @@ webpackJsonp([0],{
1513
  value: true
1514
  });
1515
 
1516
- var _HtmlParser = __webpack_require__(451);
1517
 
1518
  var _HtmlParser2 = _interopRequireDefault(_HtmlParser);
1519
 
@@ -1523,7 +1662,7 @@ webpackJsonp([0],{
1523
 
1524
  /***/ },
1525
 
1526
- /***/ 451:
1527
  /***/ function(module, exports, __webpack_require__) {
1528
 
1529
  'use strict';
@@ -1533,11 +1672,11 @@ webpackJsonp([0],{
1533
  });
1534
  exports.default = HtmlParser;
1535
 
1536
- var _htmlparser = __webpack_require__(452);
1537
 
1538
  var _htmlparser2 = _interopRequireDefault(_htmlparser);
1539
 
1540
- var _ProcessNodes = __webpack_require__(505);
1541
 
1542
  var _ProcessNodes2 = _interopRequireDefault(_ProcessNodes);
1543
 
@@ -1556,11 +1695,11 @@ webpackJsonp([0],{
1556
 
1557
  /***/ },
1558
 
1559
- /***/ 452:
1560
  /***/ function(module, exports, __webpack_require__) {
1561
 
1562
- var Parser = __webpack_require__(453),
1563
- DomHandler = __webpack_require__(462);
1564
 
1565
  function defineProp(name, value){
1566
  delete module.exports[name];
@@ -1570,26 +1709,26 @@ webpackJsonp([0],{
1570
 
1571
  module.exports = {
1572
  Parser: Parser,
1573
- Tokenizer: __webpack_require__(454),
1574
- ElementType: __webpack_require__(463),
1575
  DomHandler: DomHandler,
1576
  get FeedHandler(){
1577
- return defineProp("FeedHandler", __webpack_require__(466));
1578
  },
1579
  get Stream(){
1580
- return defineProp("Stream", __webpack_require__(467));
1581
  },
1582
  get WritableStream(){
1583
- return defineProp("WritableStream", __webpack_require__(468));
1584
  },
1585
  get ProxyHandler(){
1586
- return defineProp("ProxyHandler", __webpack_require__(491));
1587
  },
1588
  get DomUtils(){
1589
- return defineProp("DomUtils", __webpack_require__(492));
1590
  },
1591
  get CollectingHandler(){
1592
- return defineProp("CollectingHandler", __webpack_require__(504));
1593
  },
1594
  // For legacy support
1595
  DefaultHandler: DomHandler,
@@ -1631,10 +1770,10 @@ webpackJsonp([0],{
1631
 
1632
  /***/ },
1633
 
1634
- /***/ 453:
1635
  /***/ function(module, exports, __webpack_require__) {
1636
 
1637
- var Tokenizer = __webpack_require__(454);
1638
 
1639
  /*
1640
  Options:
@@ -1756,7 +1895,7 @@ webpackJsonp([0],{
1756
  if(this._cbs.onparserinit) this._cbs.onparserinit(this);
1757
  }
1758
 
1759
- __webpack_require__(460)(Parser, __webpack_require__(461).EventEmitter);
1760
 
1761
  Parser.prototype._updatePosition = function(initialOffset){
1762
  if(this.endIndex === null){
@@ -1991,15 +2130,15 @@ webpackJsonp([0],{
1991
 
1992
  /***/ },
1993
 
1994
- /***/ 454:
1995
  /***/ function(module, exports, __webpack_require__) {
1996
 
1997
  module.exports = Tokenizer;
1998
 
1999
- var decodeCodePoint = __webpack_require__(455),
2000
- entityMap = __webpack_require__(457),
2001
- legacyMap = __webpack_require__(458),
2002
- xmlMap = __webpack_require__(459),
2003
 
2004
  i = 0,
2005
 
@@ -2904,10 +3043,10 @@ webpackJsonp([0],{
2904
 
2905
  /***/ },
2906
 
2907
- /***/ 455:
2908
  /***/ function(module, exports, __webpack_require__) {
2909
 
2910
- var decodeMap = __webpack_require__(456);
2911
 
2912
  module.exports = decodeCodePoint;
2913
 
@@ -2937,35 +3076,35 @@ webpackJsonp([0],{
2937
 
2938
  /***/ },
2939
 
2940
- /***/ 456:
2941
  /***/ function(module, exports) {
2942
 
2943
  module.exports = {"0":65533,"128":8364,"130":8218,"131":402,"132":8222,"133":8230,"134":8224,"135":8225,"136":710,"137":8240,"138":352,"139":8249,"140":338,"142":381,"145":8216,"146":8217,"147":8220,"148":8221,"149":8226,"150":8211,"151":8212,"152":732,"153":8482,"154":353,"155":8250,"156":339,"158":382,"159":376}
2944
 
2945
  /***/ },
2946
 
2947
- /***/ 457:
2948
  /***/ function(module, exports) {
2949
 
2950
  module.exports = {"Aacute":"Á","aacute":"á","Abreve":"Ă","abreve":"ă","ac":"∾","acd":"∿","acE":"∾̳","Acirc":"Â","acirc":"â","acute":"´","Acy":"А","acy":"а","AElig":"Æ","aelig":"æ","af":"⁡","Afr":"𝔄","afr":"𝔞","Agrave":"À","agrave":"à","alefsym":"ℵ","aleph":"ℵ","Alpha":"Α","alpha":"α","Amacr":"Ā","amacr":"ā","amalg":"⨿","amp":"&","AMP":"&","andand":"⩕","And":"⩓","and":"∧","andd":"⩜","andslope":"⩘","andv":"⩚","ang":"∠","ange":"⦤","angle":"∠","angmsdaa":"⦨","angmsdab":"⦩","angmsdac":"⦪","angmsdad":"⦫","angmsdae":"⦬","angmsdaf":"⦭","angmsdag":"⦮","angmsdah":"⦯","angmsd":"∡","angrt":"∟","angrtvb":"⊾","angrtvbd":"⦝","angsph":"∢","angst":"Å","angzarr":"⍼","Aogon":"Ą","aogon":"ą","Aopf":"𝔸","aopf":"𝕒","apacir":"⩯","ap":"≈","apE":"⩰","ape":"≊","apid":"≋","apos":"'","ApplyFunction":"⁡","approx":"≈","approxeq":"≊","Aring":"Å","aring":"å","Ascr":"𝒜","ascr":"𝒶","Assign":"≔","ast":"*","asymp":"≈","asympeq":"≍","Atilde":"Ã","atilde":"ã","Auml":"Ä","auml":"ä","awconint":"∳","awint":"⨑","backcong":"≌","backepsilon":"϶","backprime":"‵","backsim":"∽","backsimeq":"⋍","Backslash":"∖","Barv":"⫧","barvee":"⊽","barwed":"⌅","Barwed":"⌆","barwedge":"⌅","bbrk":"⎵","bbrktbrk":"⎶","bcong":"≌","Bcy":"Б","bcy":"б","bdquo":"„","becaus":"∵","because":"∵","Because":"∵","bemptyv":"⦰","bepsi":"϶","bernou":"ℬ","Bernoullis":"ℬ","Beta":"Β","beta":"β","beth":"ℶ","between":"≬","Bfr":"𝔅","bfr":"𝔟","bigcap":"⋂","bigcirc":"◯","bigcup":"⋃","bigodot":"⨀","bigoplus":"⨁","bigotimes":"⨂","bigsqcup":"⨆","bigstar":"★","bigtriangledown":"▽","bigtriangleup":"△","biguplus":"⨄","bigvee":"⋁","bigwedge":"⋀","bkarow":"⤍","blacklozenge":"⧫","blacksquare":"▪","blacktriangle":"▴","blacktriangledown":"▾","blacktriangleleft":"◂","blacktriangleright":"▸","blank":"␣","blk12":"▒","blk14":"░","blk34":"▓","block":"█","bne":"=⃥","bnequiv":"≡⃥","bNot":"⫭","bnot":"⌐","Bopf":"𝔹","bopf":"𝕓","bot":"⊥","bottom":"⊥","bowtie":"⋈","boxbox":"⧉","boxdl":"┐","boxdL":"╕","boxDl":"╖","boxDL":"╗","boxdr":"┌","boxdR":"╒","boxDr":"╓","boxDR":"╔","boxh":"─","boxH":"═","boxhd":"┬","boxHd":"╤","boxhD":"╥","boxHD":"╦","boxhu":"┴","boxHu":"╧","boxhU":"╨","boxHU":"╩","boxminus":"⊟","boxplus":"⊞","boxtimes":"⊠","boxul":"┘","boxuL":"╛","boxUl":"╜","boxUL":"╝","boxur":"└","boxuR":"╘","boxUr":"╙","boxUR":"╚","boxv":"│","boxV":"║","boxvh":"┼","boxvH":"╪","boxVh":"╫","boxVH":"╬","boxvl":"┤","boxvL":"╡","boxVl":"╢","boxVL":"╣","boxvr":"├","boxvR":"╞","boxVr":"╟","boxVR":"╠","bprime":"‵","breve":"˘","Breve":"˘","brvbar":"¦","bscr":"𝒷","Bscr":"ℬ","bsemi":"⁏","bsim":"∽","bsime":"⋍","bsolb":"⧅","bsol":"\\","bsolhsub":"⟈","bull":"•","bullet":"•","bump":"≎","bumpE":"⪮","bumpe":"≏","Bumpeq":"≎","bumpeq":"≏","Cacute":"Ć","cacute":"ć","capand":"⩄","capbrcup":"⩉","capcap":"⩋","cap":"∩","Cap":"⋒","capcup":"⩇","capdot":"⩀","CapitalDifferentialD":"ⅅ","caps":"∩︀","caret":"⁁","caron":"ˇ","Cayleys":"ℭ","ccaps":"⩍","Ccaron":"Č","ccaron":"č","Ccedil":"Ç","ccedil":"ç","Ccirc":"Ĉ","ccirc":"ĉ","Cconint":"∰","ccups":"⩌","ccupssm":"⩐","Cdot":"Ċ","cdot":"ċ","cedil":"¸","Cedilla":"¸","cemptyv":"⦲","cent":"¢","centerdot":"·","CenterDot":"·","cfr":"𝔠","Cfr":"ℭ","CHcy":"Ч","chcy":"ч","check":"✓","checkmark":"✓","Chi":"Χ","chi":"χ","circ":"ˆ","circeq":"≗","circlearrowleft":"↺","circlearrowright":"↻","circledast":"⊛","circledcirc":"⊚","circleddash":"⊝","CircleDot":"⊙","circledR":"®","circledS":"Ⓢ","CircleMinus":"⊖","CirclePlus":"⊕","CircleTimes":"⊗","cir":"○","cirE":"⧃","cire":"≗","cirfnint":"⨐","cirmid":"⫯","cirscir":"⧂","ClockwiseContourIntegral":"∲","CloseCurlyDoubleQuote":"”","CloseCurlyQuote":"’","clubs":"♣","clubsuit":"♣","colon":":","Colon":"∷","Colone":"⩴","colone":"≔","coloneq":"≔","comma":",","commat":"@","comp":"∁","compfn":"∘","complement":"∁","complexes":"ℂ","cong":"≅","congdot":"⩭","Congruent":"≡","conint":"∮","Conint":"∯","ContourIntegral":"∮","copf":"𝕔","Copf":"ℂ","coprod":"∐","Coproduct":"∐","copy":"©","COPY":"©","copysr":"℗","CounterClockwiseContourIntegral":"∳","crarr":"↵","cross":"✗","Cross":"⨯","Cscr":"𝒞","cscr":"𝒸","csub":"⫏","csube":"⫑","csup":"⫐","csupe":"⫒","ctdot":"⋯","cudarrl":"⤸","cudarrr":"⤵","cuepr":"⋞","cuesc":"⋟","cularr":"↶","cularrp":"⤽","cupbrcap":"⩈","cupcap":"⩆","CupCap":"≍","cup":"∪","Cup":"⋓","cupcup":"⩊","cupdot":"⊍","cupor":"⩅","cups":"∪︀","curarr":"↷","curarrm":"⤼","curlyeqprec":"⋞","curlyeqsucc":"⋟","curlyvee":"⋎","curlywedge":"⋏","curren":"¤","curvearrowleft":"↶","curvearrowright":"↷","cuvee":"⋎","cuwed":"⋏","cwconint":"∲","cwint":"∱","cylcty":"⌭","dagger":"†","Dagger":"‡","daleth":"ℸ","darr":"↓","Darr":"↡","dArr":"⇓","dash":"‐","Dashv":"⫤","dashv":"⊣","dbkarow":"⤏","dblac":"˝","Dcaron":"Ď","dcaron":"ď","Dcy":"Д","dcy":"д","ddagger":"‡","ddarr":"⇊","DD":"ⅅ","dd":"ⅆ","DDotrahd":"⤑","ddotseq":"⩷","deg":"°","Del":"∇","Delta":"Δ","delta":"δ","demptyv":"⦱","dfisht":"⥿","Dfr":"𝔇","dfr":"𝔡","dHar":"⥥","dharl":"⇃","dharr":"⇂","DiacriticalAcute":"´","DiacriticalDot":"˙","DiacriticalDoubleAcute":"˝","DiacriticalGrave":"`","DiacriticalTilde":"˜","diam":"⋄","diamond":"⋄","Diamond":"⋄","diamondsuit":"♦","diams":"♦","die":"¨","DifferentialD":"ⅆ","digamma":"ϝ","disin":"⋲","div":"÷","divide":"÷","divideontimes":"⋇","divonx":"⋇","DJcy":"Ђ","djcy":"ђ","dlcorn":"⌞","dlcrop":"⌍","dollar":"$","Dopf":"𝔻","dopf":"𝕕","Dot":"¨","dot":"˙","DotDot":"⃜","doteq":"≐","doteqdot":"≑","DotEqual":"≐","dotminus":"∸","dotplus":"∔","dotsquare":"⊡","doublebarwedge":"⌆","DoubleContourIntegral":"∯","DoubleDot":"¨","DoubleDownArrow":"⇓","DoubleLeftArrow":"⇐","DoubleLeftRightArrow":"⇔","DoubleLeftTee":"⫤","DoubleLongLeftArrow":"⟸","DoubleLongLeftRightArrow":"⟺","DoubleLongRightArrow":"⟹","DoubleRightArrow":"⇒","DoubleRightTee":"⊨","DoubleUpArrow":"⇑","DoubleUpDownArrow":"⇕","DoubleVerticalBar":"∥","DownArrowBar":"⤓","downarrow":"↓","DownArrow":"↓","Downarrow":"⇓","DownArrowUpArrow":"⇵","DownBreve":"̑","downdownarrows":"⇊","downharpoonleft":"⇃","downharpoonright":"⇂","DownLeftRightVector":"⥐","DownLeftTeeVector":"⥞","DownLeftVectorBar":"⥖","DownLeftVector":"↽","DownRightTeeVector":"⥟","DownRightVectorBar":"⥗","DownRightVector":"⇁","DownTeeArrow":"↧","DownTee":"⊤","drbkarow":"⤐","drcorn":"⌟","drcrop":"⌌","Dscr":"𝒟","dscr":"𝒹","DScy":"Ѕ","dscy":"ѕ","dsol":"⧶","Dstrok":"Đ","dstrok":"đ","dtdot":"⋱","dtri":"▿","dtrif":"▾","duarr":"⇵","duhar":"⥯","dwangle":"⦦","DZcy":"Џ","dzcy":"џ","dzigrarr":"⟿","Eacute":"É","eacute":"é","easter":"⩮","Ecaron":"Ě","ecaron":"ě","Ecirc":"Ê","ecirc":"ê","ecir":"≖","ecolon":"≕","Ecy":"Э","ecy":"э","eDDot":"⩷","Edot":"Ė","edot":"ė","eDot":"≑","ee":"ⅇ","efDot":"≒","Efr":"𝔈","efr":"𝔢","eg":"⪚","Egrave":"È","egrave":"è","egs":"⪖","egsdot":"⪘","el":"⪙","Element":"∈","elinters":"⏧","ell":"ℓ","els":"⪕","elsdot":"⪗","Emacr":"Ē","emacr":"ē","empty":"∅","emptyset":"∅","EmptySmallSquare":"◻","emptyv":"∅","EmptyVerySmallSquare":"▫","emsp13":" ","emsp14":" ","emsp":" ","ENG":"Ŋ","eng":"ŋ","ensp":" ","Eogon":"Ę","eogon":"ę","Eopf":"𝔼","eopf":"𝕖","epar":"⋕","eparsl":"⧣","eplus":"⩱","epsi":"ε","Epsilon":"Ε","epsilon":"ε","epsiv":"ϵ","eqcirc":"≖","eqcolon":"≕","eqsim":"≂","eqslantgtr":"⪖","eqslantless":"⪕","Equal":"⩵","equals":"=","EqualTilde":"≂","equest":"≟","Equilibrium":"⇌","equiv":"≡","equivDD":"⩸","eqvparsl":"⧥","erarr":"⥱","erDot":"≓","escr":"ℯ","Escr":"ℰ","esdot":"≐","Esim":"⩳","esim":"≂","Eta":"Η","eta":"η","ETH":"Ð","eth":"ð","Euml":"Ë","euml":"ë","euro":"€","excl":"!","exist":"∃","Exists":"∃","expectation":"ℰ","exponentiale":"ⅇ","ExponentialE":"ⅇ","fallingdotseq":"≒","Fcy":"Ф","fcy":"ф","female":"♀","ffilig":"ffi","fflig":"ff","ffllig":"ffl","Ffr":"𝔉","ffr":"𝔣","filig":"fi","FilledSmallSquare":"◼","FilledVerySmallSquare":"▪","fjlig":"fj","flat":"♭","fllig":"fl","fltns":"▱","fnof":"ƒ","Fopf":"𝔽","fopf":"𝕗","forall":"∀","ForAll":"∀","fork":"⋔","forkv":"⫙","Fouriertrf":"ℱ","fpartint":"⨍","frac12":"½","frac13":"⅓","frac14":"¼","frac15":"⅕","frac16":"⅙","frac18":"⅛","frac23":"⅔","frac25":"⅖","frac34":"¾","frac35":"⅗","frac38":"⅜","frac45":"⅘","frac56":"⅚","frac58":"⅝","frac78":"⅞","frasl":"⁄","frown":"⌢","fscr":"𝒻","Fscr":"ℱ","gacute":"ǵ","Gamma":"Γ","gamma":"γ","Gammad":"Ϝ","gammad":"ϝ","gap":"⪆","Gbreve":"Ğ","gbreve":"ğ","Gcedil":"Ģ","Gcirc":"Ĝ","gcirc":"ĝ","Gcy":"Г","gcy":"г","Gdot":"Ġ","gdot":"ġ","ge":"≥","gE":"≧","gEl":"⪌","gel":"⋛","geq":"≥","geqq":"≧","geqslant":"⩾","gescc":"⪩","ges":"⩾","gesdot":"⪀","gesdoto":"⪂","gesdotol":"⪄","gesl":"⋛︀","gesles":"⪔","Gfr":"𝔊","gfr":"𝔤","gg":"≫","Gg":"⋙","ggg":"⋙","gimel":"ℷ","GJcy":"Ѓ","gjcy":"ѓ","gla":"⪥","gl":"≷","glE":"⪒","glj":"⪤","gnap":"⪊","gnapprox":"⪊","gne":"⪈","gnE":"≩","gneq":"⪈","gneqq":"≩","gnsim":"⋧","Gopf":"𝔾","gopf":"𝕘","grave":"`","GreaterEqual":"≥","GreaterEqualLess":"⋛","GreaterFullEqual":"≧","GreaterGreater":"⪢","GreaterLess":"≷","GreaterSlantEqual":"⩾","GreaterTilde":"≳","Gscr":"𝒢","gscr":"ℊ","gsim":"≳","gsime":"⪎","gsiml":"⪐","gtcc":"⪧","gtcir":"⩺","gt":">","GT":">","Gt":"≫","gtdot":"⋗","gtlPar":"⦕","gtquest":"⩼","gtrapprox":"⪆","gtrarr":"⥸","gtrdot":"⋗","gtreqless":"⋛","gtreqqless":"⪌","gtrless":"≷","gtrsim":"≳","gvertneqq":"≩︀","gvnE":"≩︀","Hacek":"ˇ","hairsp":" ","half":"½","hamilt":"ℋ","HARDcy":"Ъ","hardcy":"ъ","harrcir":"⥈","harr":"↔","hArr":"⇔","harrw":"↭","Hat":"^","hbar":"ℏ","Hcirc":"Ĥ","hcirc":"ĥ","hearts":"♥","heartsuit":"♥","hellip":"…","hercon":"⊹","hfr":"𝔥","Hfr":"ℌ","HilbertSpace":"ℋ","hksearow":"⤥","hkswarow":"⤦","hoarr":"⇿","homtht":"∻","hookleftarrow":"↩","hookrightarrow":"↪","hopf":"𝕙","Hopf":"ℍ","horbar":"―","HorizontalLine":"─","hscr":"𝒽","Hscr":"ℋ","hslash":"ℏ","Hstrok":"Ħ","hstrok":"ħ","HumpDownHump":"≎","HumpEqual":"≏","hybull":"⁃","hyphen":"‐","Iacute":"Í","iacute":"í","ic":"⁣","Icirc":"Î","icirc":"î","Icy":"И","icy":"и","Idot":"İ","IEcy":"Е","iecy":"е","iexcl":"¡","iff":"⇔","ifr":"𝔦","Ifr":"ℑ","Igrave":"Ì","igrave":"ì","ii":"ⅈ","iiiint":"⨌","iiint":"∭","iinfin":"⧜","iiota":"℩","IJlig":"IJ","ijlig":"ij","Imacr":"Ī","imacr":"ī","image":"ℑ","ImaginaryI":"ⅈ","imagline":"ℐ","imagpart":"ℑ","imath":"ı","Im":"ℑ","imof":"⊷","imped":"Ƶ","Implies":"⇒","incare":"℅","in":"∈","infin":"∞","infintie":"⧝","inodot":"ı","intcal":"⊺","int":"∫","Int":"∬","integers":"ℤ","Integral":"∫","intercal":"⊺","Intersection":"⋂","intlarhk":"⨗","intprod":"⨼","InvisibleComma":"⁣","InvisibleTimes":"⁢","IOcy":"Ё","iocy":"ё","Iogon":"Į","iogon":"į","Iopf":"𝕀","iopf":"𝕚","Iota":"Ι","iota":"ι","iprod":"⨼","iquest":"¿","iscr":"𝒾","Iscr":"ℐ","isin":"∈","isindot":"⋵","isinE":"⋹","isins":"⋴","isinsv":"⋳","isinv":"∈","it":"⁢","Itilde":"Ĩ","itilde":"ĩ","Iukcy":"І","iukcy":"і","Iuml":"Ï","iuml":"ï","Jcirc":"Ĵ","jcirc":"ĵ","Jcy":"Й","jcy":"й","Jfr":"𝔍","jfr":"𝔧","jmath":"ȷ","Jopf":"𝕁","jopf":"𝕛","Jscr":"𝒥","jscr":"𝒿","Jsercy":"Ј","jsercy":"ј","Jukcy":"Є","jukcy":"є","Kappa":"Κ","kappa":"κ","kappav":"ϰ","Kcedil":"Ķ","kcedil":"ķ","Kcy":"К","kcy":"к","Kfr":"𝔎","kfr":"𝔨","kgreen":"ĸ","KHcy":"Х","khcy":"х","KJcy":"Ќ","kjcy":"ќ","Kopf":"𝕂","kopf":"𝕜","Kscr":"𝒦","kscr":"𝓀","lAarr":"⇚","Lacute":"Ĺ","lacute":"ĺ","laemptyv":"⦴","lagran":"ℒ","Lambda":"Λ","lambda":"λ","lang":"⟨","Lang":"⟪","langd":"⦑","langle":"⟨","lap":"⪅","Laplacetrf":"ℒ","laquo":"«","larrb":"⇤","larrbfs":"⤟","larr":"←","Larr":"↞","lArr":"⇐","larrfs":"⤝","larrhk":"↩","larrlp":"↫","larrpl":"⤹","larrsim":"⥳","larrtl":"↢","latail":"⤙","lAtail":"⤛","lat":"⪫","late":"⪭","lates":"⪭︀","lbarr":"⤌","lBarr":"⤎","lbbrk":"❲","lbrace":"{","lbrack":"[","lbrke":"⦋","lbrksld":"⦏","lbrkslu":"⦍","Lcaron":"Ľ","lcaron":"ľ","Lcedil":"Ļ","lcedil":"ļ","lceil":"⌈","lcub":"{","Lcy":"Л","lcy":"л","ldca":"⤶","ldquo":"“","ldquor":"„","ldrdhar":"⥧","ldrushar":"⥋","ldsh":"↲","le":"≤","lE":"≦","LeftAngleBracket":"⟨","LeftArrowBar":"⇤","leftarrow":"←","LeftArrow":"←","Leftarrow":"⇐","LeftArrowRightArrow":"⇆","leftarrowtail":"↢","LeftCeiling":"⌈","LeftDoubleBracket":"⟦","LeftDownTeeVector":"⥡","LeftDownVectorBar":"⥙","LeftDownVector":"⇃","LeftFloor":"⌊","leftharpoondown":"↽","leftharpoonup":"↼","leftleftarrows":"⇇","leftrightarrow":"↔","LeftRightArrow":"↔","Leftrightarrow":"⇔","leftrightarrows":"⇆","leftrightharpoons":"⇋","leftrightsquigarrow":"↭","LeftRightVector":"⥎","LeftTeeArrow":"↤","LeftTee":"⊣","LeftTeeVector":"⥚","leftthreetimes":"⋋","LeftTriangleBar":"⧏","LeftTriangle":"⊲","LeftTriangleEqual":"⊴","LeftUpDownVector":"⥑","LeftUpTeeVector":"⥠","LeftUpVectorBar":"⥘","LeftUpVector":"↿","LeftVectorBar":"⥒","LeftVector":"↼","lEg":"⪋","leg":"⋚","leq":"≤","leqq":"≦","leqslant":"⩽","lescc":"⪨","les":"⩽","lesdot":"⩿","lesdoto":"⪁","lesdotor":"⪃","lesg":"⋚︀","lesges":"⪓","lessapprox":"⪅","lessdot":"⋖","lesseqgtr":"⋚","lesseqqgtr":"⪋","LessEqualGreater":"⋚","LessFullEqual":"≦","LessGreater":"≶","lessgtr":"≶","LessLess":"⪡","lesssim":"≲","LessSlantEqual":"⩽","LessTilde":"≲","lfisht":"⥼","lfloor":"⌊","Lfr":"𝔏","lfr":"𝔩","lg":"≶","lgE":"⪑","lHar":"⥢","lhard":"↽","lharu":"↼","lharul":"⥪","lhblk":"▄","LJcy":"Љ","ljcy":"љ","llarr":"⇇","ll":"≪","Ll":"⋘","llcorner":"⌞","Lleftarrow":"⇚","llhard":"⥫","lltri":"◺","Lmidot":"Ŀ","lmidot":"ŀ","lmoustache":"⎰","lmoust":"⎰","lnap":"⪉","lnapprox":"⪉","lne":"⪇","lnE":"≨","lneq":"⪇","lneqq":"≨","lnsim":"⋦","loang":"⟬","loarr":"⇽","lobrk":"⟦","longleftarrow":"⟵","LongLeftArrow":"⟵","Longleftarrow":"⟸","longleftrightarrow":"⟷","LongLeftRightArrow":"⟷","Longleftrightarrow":"⟺","longmapsto":"⟼","longrightarrow":"⟶","LongRightArrow":"⟶","Longrightarrow":"⟹","looparrowleft":"↫","looparrowright":"↬","lopar":"⦅","Lopf":"𝕃","lopf":"𝕝","loplus":"⨭","lotimes":"⨴","lowast":"∗","lowbar":"_","LowerLeftArrow":"↙","LowerRightArrow":"↘","loz":"◊","lozenge":"◊","lozf":"⧫","lpar":"(","lparlt":"⦓","lrarr":"⇆","lrcorner":"⌟","lrhar":"⇋","lrhard":"⥭","lrm":"‎","lrtri":"⊿","lsaquo":"‹","lscr":"𝓁","Lscr":"ℒ","lsh":"↰","Lsh":"↰","lsim":"≲","lsime":"⪍","lsimg":"⪏","lsqb":"[","lsquo":"‘","lsquor":"‚","Lstrok":"Ł","lstrok":"ł","ltcc":"⪦","ltcir":"⩹","lt":"<","LT":"<","Lt":"≪","ltdot":"⋖","lthree":"⋋","ltimes":"⋉","ltlarr":"⥶","ltquest":"⩻","ltri":"◃","ltrie":"⊴","ltrif":"◂","ltrPar":"⦖","lurdshar":"⥊","luruhar":"⥦","lvertneqq":"≨︀","lvnE":"≨︀","macr":"¯","male":"♂","malt":"✠","maltese":"✠","Map":"⤅","map":"↦","mapsto":"↦","mapstodown":"↧","mapstoleft":"↤","mapstoup":"↥","marker":"▮","mcomma":"⨩","Mcy":"М","mcy":"м","mdash":"—","mDDot":"∺","measuredangle":"∡","MediumSpace":" ","Mellintrf":"ℳ","Mfr":"𝔐","mfr":"𝔪","mho":"℧","micro":"µ","midast":"*","midcir":"⫰","mid":"∣","middot":"·","minusb":"⊟","minus":"−","minusd":"∸","minusdu":"⨪","MinusPlus":"∓","mlcp":"⫛","mldr":"…","mnplus":"∓","models":"⊧","Mopf":"𝕄","mopf":"𝕞","mp":"∓","mscr":"𝓂","Mscr":"ℳ","mstpos":"∾","Mu":"Μ","mu":"μ","multimap":"⊸","mumap":"⊸","nabla":"∇","Nacute":"Ń","nacute":"ń","nang":"∠⃒","nap":"≉","napE":"⩰̸","napid":"≋̸","napos":"ʼn","napprox":"≉","natural":"♮","naturals":"ℕ","natur":"♮","nbsp":" ","nbump":"≎̸","nbumpe":"≏̸","ncap":"⩃","Ncaron":"Ň","ncaron":"ň","Ncedil":"Ņ","ncedil":"ņ","ncong":"≇","ncongdot":"⩭̸","ncup":"⩂","Ncy":"Н","ncy":"н","ndash":"–","nearhk":"⤤","nearr":"↗","neArr":"⇗","nearrow":"↗","ne":"≠","nedot":"≐̸","NegativeMediumSpace":"​","NegativeThickSpace":"​","NegativeThinSpace":"​","NegativeVeryThinSpace":"​","nequiv":"≢","nesear":"⤨","nesim":"≂̸","NestedGreaterGreater":"≫","NestedLessLess":"≪","NewLine":"\n","nexist":"∄","nexists":"∄","Nfr":"𝔑","nfr":"𝔫","ngE":"≧̸","nge":"≱","ngeq":"≱","ngeqq":"≧̸","ngeqslant":"⩾̸","nges":"⩾̸","nGg":"⋙̸","ngsim":"≵","nGt":"≫⃒","ngt":"≯","ngtr":"≯","nGtv":"≫̸","nharr":"↮","nhArr":"⇎","nhpar":"⫲","ni":"∋","nis":"⋼","nisd":"⋺","niv":"∋","NJcy":"Њ","njcy":"њ","nlarr":"↚","nlArr":"⇍","nldr":"‥","nlE":"≦̸","nle":"≰","nleftarrow":"↚","nLeftarrow":"⇍","nleftrightarrow":"↮","nLeftrightarrow":"⇎","nleq":"≰","nleqq":"≦̸","nleqslant":"⩽̸","nles":"⩽̸","nless":"≮","nLl":"⋘̸","nlsim":"≴","nLt":"≪⃒","nlt":"≮","nltri":"⋪","nltrie":"⋬","nLtv":"≪̸","nmid":"∤","NoBreak":"⁠","NonBreakingSpace":" ","nopf":"𝕟","Nopf":"ℕ","Not":"⫬","not":"¬","NotCongruent":"≢","NotCupCap":"≭","NotDoubleVerticalBar":"∦","NotElement":"∉","NotEqual":"≠","NotEqualTilde":"≂̸","NotExists":"∄","NotGreater":"≯","NotGreaterEqual":"≱","NotGreaterFullEqual":"≧̸","NotGreaterGreater":"≫̸","NotGreaterLess":"≹","NotGreaterSlantEqual":"⩾̸","NotGreaterTilde":"≵","NotHumpDownHump":"≎̸","NotHumpEqual":"≏̸","notin":"∉","notindot":"⋵̸","notinE":"⋹̸","notinva":"∉","notinvb":"⋷","notinvc":"⋶","NotLeftTriangleBar":"⧏̸","NotLeftTriangle":"⋪","NotLeftTriangleEqual":"⋬","NotLess":"≮","NotLessEqual":"≰","NotLessGreater":"≸","NotLessLess":"≪̸","NotLessSlantEqual":"⩽̸","NotLessTilde":"≴","NotNestedGreaterGreater":"⪢̸","NotNestedLessLess":"⪡̸","notni":"∌","notniva":"∌","notnivb":"⋾","notnivc":"⋽","NotPrecedes":"⊀","NotPrecedesEqual":"⪯̸","NotPrecedesSlantEqual":"⋠","NotReverseElement":"∌","NotRightTriangleBar":"⧐̸","NotRightTriangle":"⋫","NotRightTriangleEqual":"⋭","NotSquareSubset":"⊏̸","NotSquareSubsetEqual":"⋢","NotSquareSuperset":"⊐̸","NotSquareSupersetEqual":"⋣","NotSubset":"⊂⃒","NotSubsetEqual":"⊈","NotSucceeds":"⊁","NotSucceedsEqual":"⪰̸","NotSucceedsSlantEqual":"⋡","NotSucceedsTilde":"≿̸","NotSuperset":"⊃⃒","NotSupersetEqual":"⊉","NotTilde":"≁","NotTildeEqual":"≄","NotTildeFullEqual":"≇","NotTildeTilde":"≉","NotVerticalBar":"∤","nparallel":"∦","npar":"∦","nparsl":"⫽⃥","npart":"∂̸","npolint":"⨔","npr":"⊀","nprcue":"⋠","nprec":"⊀","npreceq":"⪯̸","npre":"⪯̸","nrarrc":"⤳̸","nrarr":"↛","nrArr":"⇏","nrarrw":"↝̸","nrightarrow":"↛","nRightarrow":"⇏","nrtri":"⋫","nrtrie":"⋭","nsc":"⊁","nsccue":"⋡","nsce":"⪰̸","Nscr":"𝒩","nscr":"𝓃","nshortmid":"∤","nshortparallel":"∦","nsim":"≁","nsime":"≄","nsimeq":"≄","nsmid":"∤","nspar":"∦","nsqsube":"⋢","nsqsupe":"⋣","nsub":"⊄","nsubE":"⫅̸","nsube":"⊈","nsubset":"⊂⃒","nsubseteq":"⊈","nsubseteqq":"⫅̸","nsucc":"⊁","nsucceq":"⪰̸","nsup":"⊅","nsupE":"⫆̸","nsupe":"⊉","nsupset":"⊃⃒","nsupseteq":"⊉","nsupseteqq":"⫆̸","ntgl":"≹","Ntilde":"Ñ","ntilde":"ñ","ntlg":"≸","ntriangleleft":"⋪","ntrianglelefteq":"⋬","ntriangleright":"⋫","ntrianglerighteq":"⋭","Nu":"Ν","nu":"ν","num":"#","numero":"№","numsp":" ","nvap":"≍⃒","nvdash":"⊬","nvDash":"⊭","nVdash":"⊮","nVDash":"⊯","nvge":"≥⃒","nvgt":">⃒","nvHarr":"⤄","nvinfin":"⧞","nvlArr":"⤂","nvle":"≤⃒","nvlt":"<⃒","nvltrie":"⊴⃒","nvrArr":"⤃","nvrtrie":"⊵⃒","nvsim":"∼⃒","nwarhk":"⤣","nwarr":"↖","nwArr":"⇖","nwarrow":"↖","nwnear":"⤧","Oacute":"Ó","oacute":"ó","oast":"⊛","Ocirc":"Ô","ocirc":"ô","ocir":"⊚","Ocy":"О","ocy":"о","odash":"⊝","Odblac":"Ő","odblac":"ő","odiv":"⨸","odot":"⊙","odsold":"⦼","OElig":"Œ","oelig":"œ","ofcir":"⦿","Ofr":"𝔒","ofr":"𝔬","ogon":"˛","Ograve":"Ò","ograve":"ò","ogt":"⧁","ohbar":"⦵","ohm":"Ω","oint":"∮","olarr":"↺","olcir":"⦾","olcross":"⦻","oline":"‾","olt":"⧀","Omacr":"Ō","omacr":"ō","Omega":"Ω","omega":"ω","Omicron":"Ο","omicron":"ο","omid":"⦶","ominus":"⊖","Oopf":"𝕆","oopf":"𝕠","opar":"⦷","OpenCurlyDoubleQuote":"“","OpenCurlyQuote":"‘","operp":"⦹","oplus":"⊕","orarr":"↻","Or":"⩔","or":"∨","ord":"⩝","order":"ℴ","orderof":"ℴ","ordf":"ª","ordm":"º","origof":"⊶","oror":"⩖","orslope":"⩗","orv":"⩛","oS":"Ⓢ","Oscr":"𝒪","oscr":"ℴ","Oslash":"Ø","oslash":"ø","osol":"⊘","Otilde":"Õ","otilde":"õ","otimesas":"⨶","Otimes":"⨷","otimes":"⊗","Ouml":"Ö","ouml":"ö","ovbar":"⌽","OverBar":"‾","OverBrace":"⏞","OverBracket":"⎴","OverParenthesis":"⏜","para":"¶","parallel":"∥","par":"∥","parsim":"⫳","parsl":"⫽","part":"∂","PartialD":"∂","Pcy":"П","pcy":"п","percnt":"%","period":".","permil":"‰","perp":"⊥","pertenk":"‱","Pfr":"𝔓","pfr":"𝔭","Phi":"Φ","phi":"φ","phiv":"ϕ","phmmat":"ℳ","phone":"☎","Pi":"Π","pi":"π","pitchfork":"⋔","piv":"ϖ","planck":"ℏ","planckh":"ℎ","plankv":"ℏ","plusacir":"⨣","plusb":"⊞","pluscir":"⨢","plus":"+","plusdo":"∔","plusdu":"⨥","pluse":"⩲","PlusMinus":"±","plusmn":"±","plussim":"⨦","plustwo":"⨧","pm":"±","Poincareplane":"ℌ","pointint":"⨕","popf":"𝕡","Popf":"ℙ","pound":"£","prap":"⪷","Pr":"⪻","pr":"≺","prcue":"≼","precapprox":"⪷","prec":"≺","preccurlyeq":"≼","Precedes":"≺","PrecedesEqual":"⪯","PrecedesSlantEqual":"≼","PrecedesTilde":"≾","preceq":"⪯","precnapprox":"⪹","precneqq":"⪵","precnsim":"⋨","pre":"⪯","prE":"⪳","precsim":"≾","prime":"′","Prime":"″","primes":"ℙ","prnap":"⪹","prnE":"⪵","prnsim":"⋨","prod":"∏","Product":"∏","profalar":"⌮","profline":"⌒","profsurf":"⌓","prop":"∝","Proportional":"∝","Proportion":"∷","propto":"∝","prsim":"≾","prurel":"⊰","Pscr":"𝒫","pscr":"𝓅","Psi":"Ψ","psi":"ψ","puncsp":" ","Qfr":"𝔔","qfr":"𝔮","qint":"⨌","qopf":"𝕢","Qopf":"ℚ","qprime":"⁗","Qscr":"𝒬","qscr":"𝓆","quaternions":"ℍ","quatint":"⨖","quest":"?","questeq":"≟","quot":"\"","QUOT":"\"","rAarr":"⇛","race":"∽̱","Racute":"Ŕ","racute":"ŕ","radic":"√","raemptyv":"⦳","rang":"⟩","Rang":"⟫","rangd":"⦒","range":"⦥","rangle":"⟩","raquo":"»","rarrap":"⥵","rarrb":"⇥","rarrbfs":"⤠","rarrc":"⤳","rarr":"→","Rarr":"↠","rArr":"⇒","rarrfs":"⤞","rarrhk":"↪","rarrlp":"↬","rarrpl":"⥅","rarrsim":"⥴","Rarrtl":"⤖","rarrtl":"↣","rarrw":"↝","ratail":"⤚","rAtail":"⤜","ratio":"∶","rationals":"ℚ","rbarr":"⤍","rBarr":"⤏","RBarr":"⤐","rbbrk":"❳","rbrace":"}","rbrack":"]","rbrke":"⦌","rbrksld":"⦎","rbrkslu":"⦐","Rcaron":"Ř","rcaron":"ř","Rcedil":"Ŗ","rcedil":"ŗ","rceil":"⌉","rcub":"}","Rcy":"Р","rcy":"р","rdca":"⤷","rdldhar":"⥩","rdquo":"”","rdquor":"”","rdsh":"↳","real":"ℜ","realine":"ℛ","realpart":"ℜ","reals":"ℝ","Re":"ℜ","rect":"▭","reg":"®","REG":"®","ReverseElement":"∋","ReverseEquilibrium":"⇋","ReverseUpEquilibrium":"⥯","rfisht":"⥽","rfloor":"⌋","rfr":"𝔯","Rfr":"ℜ","rHar":"⥤","rhard":"⇁","rharu":"⇀","rharul":"⥬","Rho":"Ρ","rho":"ρ","rhov":"ϱ","RightAngleBracket":"⟩","RightArrowBar":"⇥","rightarrow":"→","RightArrow":"→","Rightarrow":"⇒","RightArrowLeftArrow":"⇄","rightarrowtail":"↣","RightCeiling":"⌉","RightDoubleBracket":"⟧","RightDownTeeVector":"⥝","RightDownVectorBar":"⥕","RightDownVector":"⇂","RightFloor":"⌋","rightharpoondown":"⇁","rightharpoonup":"⇀","rightleftarrows":"⇄","rightleftharpoons":"⇌","rightrightarrows":"⇉","rightsquigarrow":"↝","RightTeeArrow":"↦","RightTee":"⊢","RightTeeVector":"⥛","rightthreetimes":"⋌","RightTriangleBar":"⧐","RightTriangle":"⊳","RightTriangleEqual":"⊵","RightUpDownVector":"⥏","RightUpTeeVector":"⥜","RightUpVectorBar":"⥔","RightUpVector":"↾","RightVectorBar":"⥓","RightVector":"⇀","ring":"˚","risingdotseq":"≓","rlarr":"⇄","rlhar":"⇌","rlm":"‏","rmoustache":"⎱","rmoust":"⎱","rnmid":"⫮","roang":"⟭","roarr":"⇾","robrk":"⟧","ropar":"⦆","ropf":"𝕣","Ropf":"ℝ","roplus":"⨮","rotimes":"⨵","RoundImplies":"⥰","rpar":")","rpargt":"⦔","rppolint":"⨒","rrarr":"⇉","Rrightarrow":"⇛","rsaquo":"›","rscr":"𝓇","Rscr":"ℛ","rsh":"↱","Rsh":"↱","rsqb":"]","rsquo":"’","rsquor":"’","rthree":"⋌","rtimes":"⋊","rtri":"▹","rtrie":"⊵","rtrif":"▸","rtriltri":"⧎","RuleDelayed":"⧴","ruluhar":"⥨","rx":"℞","Sacute":"Ś","sacute":"ś","sbquo":"‚","scap":"⪸","Scaron":"Š","scaron":"š","Sc":"⪼","sc":"≻","sccue":"≽","sce":"⪰","scE":"⪴","Scedil":"Ş","scedil":"ş","Scirc":"Ŝ","scirc":"ŝ","scnap":"⪺","scnE":"⪶","scnsim":"⋩","scpolint":"⨓","scsim":"≿","Scy":"С","scy":"с","sdotb":"⊡","sdot":"⋅","sdote":"⩦","searhk":"⤥","searr":"↘","seArr":"⇘","searrow":"↘","sect":"§","semi":";","seswar":"⤩","setminus":"∖","setmn":"∖","sext":"✶","Sfr":"𝔖","sfr":"𝔰","sfrown":"⌢","sharp":"♯","SHCHcy":"Щ","shchcy":"щ","SHcy":"Ш","shcy":"ш","ShortDownArrow":"↓","ShortLeftArrow":"←","shortmid":"∣","shortparallel":"∥","ShortRightArrow":"→","ShortUpArrow":"↑","shy":"­","Sigma":"Σ","sigma":"σ","sigmaf":"ς","sigmav":"ς","sim":"∼","simdot":"⩪","sime":"≃","simeq":"≃","simg":"⪞","simgE":"⪠","siml":"⪝","simlE":"⪟","simne":"≆","simplus":"⨤","simrarr":"⥲","slarr":"←","SmallCircle":"∘","smallsetminus":"∖","smashp":"⨳","smeparsl":"⧤","smid":"∣","smile":"⌣","smt":"⪪","smte":"⪬","smtes":"⪬︀","SOFTcy":"Ь","softcy":"ь","solbar":"⌿","solb":"⧄","sol":"/","Sopf":"𝕊","sopf":"𝕤","spades":"♠","spadesuit":"♠","spar":"∥","sqcap":"⊓","sqcaps":"⊓︀","sqcup":"⊔","sqcups":"⊔︀","Sqrt":"√","sqsub":"⊏","sqsube":"⊑","sqsubset":"⊏","sqsubseteq":"⊑","sqsup":"⊐","sqsupe":"⊒","sqsupset":"⊐","sqsupseteq":"⊒","square":"□","Square":"□","SquareIntersection":"⊓","SquareSubset":"⊏","SquareSubsetEqual":"⊑","SquareSuperset":"⊐","SquareSupersetEqual":"⊒","SquareUnion":"⊔","squarf":"▪","squ":"□","squf":"▪","srarr":"→","Sscr":"𝒮","sscr":"𝓈","ssetmn":"∖","ssmile":"⌣","sstarf":"⋆","Star":"⋆","star":"☆","starf":"★","straightepsilon":"ϵ","straightphi":"ϕ","strns":"¯","sub":"⊂","Sub":"⋐","subdot":"⪽","subE":"⫅","sube":"⊆","subedot":"⫃","submult":"⫁","subnE":"⫋","subne":"⊊","subplus":"⪿","subrarr":"⥹","subset":"⊂","Subset":"⋐","subseteq":"⊆","subseteqq":"⫅","SubsetEqual":"⊆","subsetneq":"⊊","subsetneqq":"⫋","subsim":"⫇","subsub":"⫕","subsup":"⫓","succapprox":"⪸","succ":"≻","succcurlyeq":"≽","Succeeds":"≻","SucceedsEqual":"⪰","SucceedsSlantEqual":"≽","SucceedsTilde":"≿","succeq":"⪰","succnapprox":"⪺","succneqq":"⪶","succnsim":"⋩","succsim":"≿","SuchThat":"∋","sum":"∑","Sum":"∑","sung":"♪","sup1":"¹","sup2":"²","sup3":"³","sup":"⊃","Sup":"⋑","supdot":"⪾","supdsub":"⫘","supE":"⫆","supe":"⊇","supedot":"⫄","Superset":"⊃","SupersetEqual":"⊇","suphsol":"⟉","suphsub":"⫗","suplarr":"⥻","supmult":"⫂","supnE":"⫌","supne":"⊋","supplus":"⫀","supset":"⊃","Supset":"⋑","supseteq":"⊇","supseteqq":"⫆","supsetneq":"⊋","supsetneqq":"⫌","supsim":"⫈","supsub":"⫔","supsup":"⫖","swarhk":"⤦","swarr":"↙","swArr":"⇙","swarrow":"↙","swnwar":"⤪","szlig":"ß","Tab":"\t","target":"⌖","Tau":"Τ","tau":"τ","tbrk":"⎴","Tcaron":"Ť","tcaron":"ť","Tcedil":"Ţ","tcedil":"ţ","Tcy":"Т","tcy":"т","tdot":"⃛","telrec":"⌕","Tfr":"𝔗","tfr":"𝔱","there4":"∴","therefore":"∴","Therefore":"∴","Theta":"Θ","theta":"θ","thetasym":"ϑ","thetav":"ϑ","thickapprox":"≈","thicksim":"∼","ThickSpace":"  ","ThinSpace":" ","thinsp":" ","thkap":"≈","thksim":"∼","THORN":"Þ","thorn":"þ","tilde":"˜","Tilde":"∼","TildeEqual":"≃","TildeFullEqual":"≅","TildeTilde":"≈","timesbar":"⨱","timesb":"⊠","times":"×","timesd":"⨰","tint":"∭","toea":"⤨","topbot":"⌶","topcir":"⫱","top":"⊤","Topf":"𝕋","topf":"𝕥","topfork":"⫚","tosa":"⤩","tprime":"‴","trade":"™","TRADE":"™","triangle":"▵","triangledown":"▿","triangleleft":"◃","trianglelefteq":"⊴","triangleq":"≜","triangleright":"▹","trianglerighteq":"⊵","tridot":"◬","trie":"≜","triminus":"⨺","TripleDot":"⃛","triplus":"⨹","trisb":"⧍","tritime":"⨻","trpezium":"⏢","Tscr":"𝒯","tscr":"𝓉","TScy":"Ц","tscy":"ц","TSHcy":"Ћ","tshcy":"ћ","Tstrok":"Ŧ","tstrok":"ŧ","twixt":"≬","twoheadleftarrow":"↞","twoheadrightarrow":"↠","Uacute":"Ú","uacute":"ú","uarr":"↑","Uarr":"↟","uArr":"⇑","Uarrocir":"⥉","Ubrcy":"Ў","ubrcy":"ў","Ubreve":"Ŭ","ubreve":"ŭ","Ucirc":"Û","ucirc":"û","Ucy":"У","ucy":"у","udarr":"⇅","Udblac":"Ű","udblac":"ű","udhar":"⥮","ufisht":"⥾","Ufr":"𝔘","ufr":"𝔲","Ugrave":"Ù","ugrave":"ù","uHar":"⥣","uharl":"↿","uharr":"↾","uhblk":"▀","ulcorn":"⌜","ulcorner":"⌜","ulcrop":"⌏","ultri":"◸","Umacr":"Ū","umacr":"ū","uml":"¨","UnderBar":"_","UnderBrace":"⏟","UnderBracket":"⎵","UnderParenthesis":"⏝","Union":"⋃","UnionPlus":"⊎","Uogon":"Ų","uogon":"ų","Uopf":"𝕌","uopf":"𝕦","UpArrowBar":"⤒","uparrow":"↑","UpArrow":"↑","Uparrow":"⇑","UpArrowDownArrow":"⇅","updownarrow":"↕","UpDownArrow":"↕","Updownarrow":"⇕","UpEquilibrium":"⥮","upharpoonleft":"↿","upharpoonright":"↾","uplus":"⊎","UpperLeftArrow":"↖","UpperRightArrow":"↗","upsi":"υ","Upsi":"ϒ","upsih":"ϒ","Upsilon":"Υ","upsilon":"υ","UpTeeArrow":"↥","UpTee":"⊥","upuparrows":"⇈","urcorn":"⌝","urcorner":"⌝","urcrop":"⌎","Uring":"Ů","uring":"ů","urtri":"◹","Uscr":"𝒰","uscr":"𝓊","utdot":"⋰","Utilde":"Ũ","utilde":"ũ","utri":"▵","utrif":"▴","uuarr":"⇈","Uuml":"Ü","uuml":"ü","uwangle":"⦧","vangrt":"⦜","varepsilon":"ϵ","varkappa":"ϰ","varnothing":"∅","varphi":"ϕ","varpi":"ϖ","varpropto":"∝","varr":"↕","vArr":"⇕","varrho":"ϱ","varsigma":"ς","varsubsetneq":"⊊︀","varsubsetneqq":"⫋︀","varsupsetneq":"⊋︀","varsupsetneqq":"⫌︀","vartheta":"ϑ","vartriangleleft":"⊲","vartriangleright":"⊳","vBar":"⫨","Vbar":"⫫","vBarv":"⫩","Vcy":"В","vcy":"в","vdash":"⊢","vDash":"⊨","Vdash":"⊩","VDash":"⊫","Vdashl":"⫦","veebar":"⊻","vee":"∨","Vee":"⋁","veeeq":"≚","vellip":"⋮","verbar":"|","Verbar":"‖","vert":"|","Vert":"‖","VerticalBar":"∣","VerticalLine":"|","VerticalSeparator":"❘","VerticalTilde":"≀","VeryThinSpace":" ","Vfr":"𝔙","vfr":"𝔳","vltri":"⊲","vnsub":"⊂⃒","vnsup":"⊃⃒","Vopf":"𝕍","vopf":"𝕧","vprop":"∝","vrtri":"⊳","Vscr":"𝒱","vscr":"𝓋","vsubnE":"⫋︀","vsubne":"⊊︀","vsupnE":"⫌︀","vsupne":"⊋︀","Vvdash":"⊪","vzigzag":"⦚","Wcirc":"Ŵ","wcirc":"ŵ","wedbar":"⩟","wedge":"∧","Wedge":"⋀","wedgeq":"≙","weierp":"℘","Wfr":"𝔚","wfr":"𝔴","Wopf":"𝕎","wopf":"𝕨","wp":"℘","wr":"≀","wreath":"≀","Wscr":"𝒲","wscr":"𝓌","xcap":"⋂","xcirc":"◯","xcup":"⋃","xdtri":"▽","Xfr":"𝔛","xfr":"𝔵","xharr":"⟷","xhArr":"⟺","Xi":"Ξ","xi":"ξ","xlarr":"⟵","xlArr":"⟸","xmap":"⟼","xnis":"⋻","xodot":"⨀","Xopf":"𝕏","xopf":"𝕩","xoplus":"⨁","xotime":"⨂","xrarr":"⟶","xrArr":"⟹","Xscr":"𝒳","xscr":"𝓍","xsqcup":"⨆","xuplus":"⨄","xutri":"△","xvee":"⋁","xwedge":"⋀","Yacute":"Ý","yacute":"ý","YAcy":"Я","yacy":"я","Ycirc":"Ŷ","ycirc":"ŷ","Ycy":"Ы","ycy":"ы","yen":"¥","Yfr":"𝔜","yfr":"𝔶","YIcy":"Ї","yicy":"ї","Yopf":"𝕐","yopf":"𝕪","Yscr":"𝒴","yscr":"𝓎","YUcy":"Ю","yucy":"ю","yuml":"ÿ","Yuml":"Ÿ","Zacute":"Ź","zacute":"ź","Zcaron":"Ž","zcaron":"ž","Zcy":"З","zcy":"з","Zdot":"Ż","zdot":"ż","zeetrf":"ℨ","ZeroWidthSpace":"​","Zeta":"Ζ","zeta":"ζ","zfr":"𝔷","Zfr":"ℨ","ZHcy":"Ж","zhcy":"ж","zigrarr":"⇝","zopf":"𝕫","Zopf":"ℤ","Zscr":"𝒵","zscr":"𝓏","zwj":"‍","zwnj":"‌"}
2951
 
2952
  /***/ },
2953
 
2954
- /***/ 458:
2955
  /***/ function(module, exports) {
2956
 
2957
  module.exports = {"Aacute":"Á","aacute":"á","Acirc":"Â","acirc":"â","acute":"´","AElig":"Æ","aelig":"æ","Agrave":"À","agrave":"à","amp":"&","AMP":"&","Aring":"Å","aring":"å","Atilde":"Ã","atilde":"ã","Auml":"Ä","auml":"ä","brvbar":"¦","Ccedil":"Ç","ccedil":"ç","cedil":"¸","cent":"¢","copy":"©","COPY":"©","curren":"¤","deg":"°","divide":"÷","Eacute":"É","eacute":"é","Ecirc":"Ê","ecirc":"ê","Egrave":"È","egrave":"è","ETH":"Ð","eth":"ð","Euml":"Ë","euml":"ë","frac12":"½","frac14":"¼","frac34":"¾","gt":">","GT":">","Iacute":"Í","iacute":"í","Icirc":"Î","icirc":"î","iexcl":"¡","Igrave":"Ì","igrave":"ì","iquest":"¿","Iuml":"Ï","iuml":"ï","laquo":"«","lt":"<","LT":"<","macr":"¯","micro":"µ","middot":"·","nbsp":" ","not":"¬","Ntilde":"Ñ","ntilde":"ñ","Oacute":"Ó","oacute":"ó","Ocirc":"Ô","ocirc":"ô","Ograve":"Ò","ograve":"ò","ordf":"ª","ordm":"º","Oslash":"Ø","oslash":"ø","Otilde":"Õ","otilde":"õ","Ouml":"Ö","ouml":"ö","para":"¶","plusmn":"±","pound":"£","quot":"\"","QUOT":"\"","raquo":"»","reg":"®","REG":"®","sect":"§","shy":"­","sup1":"¹","sup2":"²","sup3":"³","szlig":"ß","THORN":"Þ","thorn":"þ","times":"×","Uacute":"Ú","uacute":"ú","Ucirc":"Û","ucirc":"û","Ugrave":"Ù","ugrave":"ù","uml":"¨","Uuml":"Ü","uuml":"ü","Yacute":"Ý","yacute":"ý","yen":"¥","yuml":"ÿ"}
2958
 
2959
  /***/ },
2960
 
2961
- /***/ 459:
2962
  /***/ function(module, exports) {
2963
 
2964
  module.exports = {"amp":"&","apos":"'","gt":">","lt":"<","quot":"\""}
2965
 
2966
  /***/ },
2967
 
2968
- /***/ 460:
2969
  /***/ function(module, exports) {
2970
 
2971
  if (typeof Object.create === 'function') {
@@ -2995,7 +3134,7 @@ webpackJsonp([0],{
2995
 
2996
  /***/ },
2997
 
2998
- /***/ 461:
2999
  /***/ function(module, exports) {
3000
 
3001
  // Copyright Joyent, Inc. and other Node contributors.
@@ -3304,14 +3443,14 @@ webpackJsonp([0],{
3304
 
3305
  /***/ },
3306
 
3307
- /***/ 462:
3308
  /***/ function(module, exports, __webpack_require__) {
3309
 
3310
- var ElementType = __webpack_require__(463);
3311
 
3312
  var re_whitespace = /\s+/g;
3313
- var NodePrototype = __webpack_require__(464);
3314
- var ElementPrototype = __webpack_require__(465);
3315
 
3316
  function DomHandler(callback, options, elementCB){
3317
  if(typeof callback === "object"){
@@ -3528,7 +3667,7 @@ webpackJsonp([0],{
3528
 
3529
  /***/ },
3530
 
3531
- /***/ 463:
3532
  /***/ function(module, exports) {
3533
 
3534
  //Types of elements found in the DOM
@@ -3550,7 +3689,7 @@ webpackJsonp([0],{
3550
 
3551
  /***/ },
3552
 
3553
- /***/ 464:
3554
  /***/ function(module, exports) {
3555
 
3556
  // This object will be used as the prototype for Nodes when creating a
@@ -3601,11 +3740,11 @@ webpackJsonp([0],{
3601
 
3602
  /***/ },
3603
 
3604
- /***/ 465:
3605
  /***/ function(module, exports, __webpack_require__) {
3606
 
3607
  // DOM-Level-1-compliant structure
3608
- var NodePrototype = __webpack_require__(464);
3609
  var ElementPrototype = module.exports = Object.create(NodePrototype);
3610
 
3611
  var domLvl1 = {
@@ -3628,10 +3767,10 @@ webpackJsonp([0],{
3628
 
3629
  /***/ },
3630
 
3631
- /***/ 466:
3632
  /***/ function(module, exports, __webpack_require__) {
3633
 
3634
- var index = __webpack_require__(452),
3635
  DomHandler = index.DomHandler,
3636
  DomUtils = index.DomUtils;
3637
 
@@ -3640,7 +3779,7 @@ webpackJsonp([0],{
3640
  this.init(callback, options);
3641
  }
3642
 
3643
- __webpack_require__(460)(FeedHandler, DomHandler);
3644
 
3645
  FeedHandler.prototype.init = DomHandler;
3646
 
@@ -3730,18 +3869,18 @@ webpackJsonp([0],{
3730
 
3731
  /***/ },
3732
 
3733
- /***/ 467:
3734
  /***/ function(module, exports, __webpack_require__) {
3735
 
3736
  module.exports = Stream;
3737
 
3738
- var Parser = __webpack_require__(468);
3739
 
3740
  function Stream(options){
3741
  Parser.call(this, new Cbs(this), options);
3742
  }
3743
 
3744
- __webpack_require__(460)(Stream, Parser);
3745
 
3746
  Stream.prototype.readable = true;
3747
 
@@ -3749,7 +3888,7 @@ webpackJsonp([0],{
3749
  this.scope = scope;
3750
  }
3751
 
3752
- var EVENTS = __webpack_require__(452).EVENTS;
3753
 
3754
  Object.keys(EVENTS).forEach(function(name){
3755
  if(EVENTS[name] === 0){
@@ -3771,15 +3910,15 @@ webpackJsonp([0],{
3771
 
3772
  /***/ },
3773
 
3774
- /***/ 468:
3775
  /***/ function(module, exports, __webpack_require__) {
3776
 
3777
  module.exports = Stream;
3778
 
3779
- var Parser = __webpack_require__(453),
3780
- WritableStream = __webpack_require__(469).Writable || __webpack_require__(488).Writable,
3781
- StringDecoder = __webpack_require__(489).StringDecoder,
3782
- Buffer = __webpack_require__(473).Buffer;
3783
 
3784
  function Stream(cbs, options){
3785
  var parser = this._parser = new Parser(cbs, options);
@@ -3792,7 +3931,7 @@ webpackJsonp([0],{
3792
  });
3793
  }
3794
 
3795
- __webpack_require__(460)(Stream, WritableStream);
3796
 
3797
  WritableStream.prototype._write = function(chunk, encoding, cb){
3798
  if(chunk instanceof Buffer) chunk = this._decoder.write(chunk);
@@ -3802,7 +3941,7 @@ webpackJsonp([0],{
3802
 
3803
  /***/ },
3804
 
3805
- /***/ 469:
3806
  /***/ function(module, exports, __webpack_require__) {
3807
 
3808
  // Copyright Joyent, Inc. and other Node contributors.
@@ -3828,15 +3967,15 @@ webpackJsonp([0],{
3828
 
3829
  module.exports = Stream;
3830
 
3831
- var EE = __webpack_require__(461).EventEmitter;
3832
- var inherits = __webpack_require__(460);
3833
 
3834
  inherits(Stream, EE);
3835
- Stream.Readable = __webpack_require__(470);
3836
- Stream.Writable = __webpack_require__(484);
3837
- Stream.Duplex = __webpack_require__(485);
3838
- Stream.Transform = __webpack_require__(486);
3839
- Stream.PassThrough = __webpack_require__(487);
3840
 
3841
  // Backwards-compat with node 0.4.x
3842
  Stream.Stream = Stream;
@@ -3936,25 +4075,25 @@ webpackJsonp([0],{
3936
 
3937
  /***/ },
3938
 
3939
- /***/ 470:
3940
  /***/ function(module, exports, __webpack_require__) {
3941
 
3942
- /* WEBPACK VAR INJECTION */(function(process) {exports = module.exports = __webpack_require__(471);
3943
- exports.Stream = __webpack_require__(469);
3944
  exports.Readable = exports;
3945
- exports.Writable = __webpack_require__(480);
3946
- exports.Duplex = __webpack_require__(479);
3947
- exports.Transform = __webpack_require__(482);
3948
- exports.PassThrough = __webpack_require__(483);
3949
  if (!process.browser && process.env.READABLE_STREAM === 'disable') {
3950
- module.exports = __webpack_require__(469);
3951
  }
3952
 
3953
  /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
3954
 
3955
  /***/ },
3956
 
3957
- /***/ 471:
3958
  /***/ function(module, exports, __webpack_require__) {
3959
 
3960
  /* WEBPACK VAR INJECTION */(function(process) {// Copyright Joyent, Inc. and other Node contributors.
@@ -3981,17 +4120,17 @@ webpackJsonp([0],{
3981
  module.exports = Readable;
3982
 
3983
  /*<replacement>*/
3984
- var isArray = __webpack_require__(472);
3985
  /*</replacement>*/
3986
 
3987
 
3988
  /*<replacement>*/
3989
- var Buffer = __webpack_require__(473).Buffer;
3990
  /*</replacement>*/
3991
 
3992
  Readable.ReadableState = ReadableState;
3993
 
3994
- var EE = __webpack_require__(461).EventEmitter;
3995
 
3996
  /*<replacement>*/
3997
  if (!EE.listenerCount) EE.listenerCount = function(emitter, type) {
@@ -3999,18 +4138,18 @@ webpackJsonp([0],{
3999
  };
4000
  /*</replacement>*/
4001
 
4002
- var Stream = __webpack_require__(469);
4003
 
4004
  /*<replacement>*/
4005
- var util = __webpack_require__(477);
4006
- util.inherits = __webpack_require__(460);
4007
  /*</replacement>*/
4008
 
4009
  var StringDecoder;
4010
 
4011
 
4012
  /*<replacement>*/
4013
- var debug = __webpack_require__(478);
4014
  if (debug && debug.debuglog) {
4015
  debug = debug.debuglog('stream');
4016
  } else {
@@ -4022,7 +4161,7 @@ webpackJsonp([0],{
4022
  util.inherits(Readable, Stream);
4023
 
4024
  function ReadableState(options, stream) {
4025
- var Duplex = __webpack_require__(479);
4026
 
4027
  options = options || {};
4028
 
@@ -4083,14 +4222,14 @@ webpackJsonp([0],{
4083
  this.encoding = null;
4084
  if (options.encoding) {
4085
  if (!StringDecoder)
4086
- StringDecoder = __webpack_require__(481).StringDecoder;
4087
  this.decoder = new StringDecoder(options.encoding);
4088
  this.encoding = options.encoding;
4089
  }
4090
  }
4091
 
4092
  function Readable(options) {
4093
- var Duplex = __webpack_require__(479);
4094
 
4095
  if (!(this instanceof Readable))
4096
  return new Readable(options);
@@ -4193,7 +4332,7 @@ webpackJsonp([0],{
4193
  // backwards compatibility.
4194
  Readable.prototype.setEncoding = function(enc) {
4195
  if (!StringDecoder)
4196
- StringDecoder = __webpack_require__(481).StringDecoder;
4197
  this._readableState.decoder = new StringDecoder(enc);
4198
  this._readableState.encoding = enc;
4199
  return this;
@@ -4913,7 +5052,7 @@ webpackJsonp([0],{
4913
 
4914
  /***/ },
4915
 
4916
- /***/ 472:
4917
  /***/ function(module, exports) {
4918
 
4919
  module.exports = Array.isArray || function (arr) {
@@ -4923,7 +5062,7 @@ webpackJsonp([0],{
4923
 
4924
  /***/ },
4925
 
4926
- /***/ 473:
4927
  /***/ function(module, exports, __webpack_require__) {
4928
 
4929
  /* WEBPACK VAR INJECTION */(function(Buffer, global) {/*!
@@ -4936,9 +5075,9 @@ webpackJsonp([0],{
4936
 
4937
  'use strict'
4938
 
4939
- var base64 = __webpack_require__(474)
4940
- var ieee754 = __webpack_require__(475)
4941
- var isArray = __webpack_require__(476)
4942
 
4943
  exports.Buffer = Buffer
4944
  exports.SlowBuffer = SlowBuffer
@@ -6716,11 +6855,11 @@ webpackJsonp([0],{
6716
  return val !== val // eslint-disable-line no-self-compare
6717
  }
6718
 
6719
- /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(473).Buffer, (function() { return this; }())))
6720
 
6721
  /***/ },
6722
 
6723
- /***/ 474:
6724
  /***/ function(module, exports) {
6725
 
6726
  'use strict'
@@ -6841,7 +6980,7 @@ webpackJsonp([0],{
6841
 
6842
  /***/ },
6843
 
6844
- /***/ 475:
6845
  /***/ function(module, exports) {
6846
 
6847
  exports.read = function (buffer, offset, isLE, mLen, nBytes) {
@@ -6932,7 +7071,7 @@ webpackJsonp([0],{
6932
 
6933
  /***/ },
6934
 
6935
- /***/ 476:
6936
  /***/ function(module, exports) {
6937
 
6938
  var toString = {}.toString;
@@ -6944,7 +7083,7 @@ webpackJsonp([0],{
6944
 
6945
  /***/ },
6946
 
6947
- /***/ 477:
6948
  /***/ function(module, exports, __webpack_require__) {
6949
 
6950
  /* WEBPACK VAR INJECTION */(function(Buffer) {// Copyright Joyent, Inc. and other Node contributors.
@@ -7055,18 +7194,18 @@ webpackJsonp([0],{
7055
  return Object.prototype.toString.call(o);
7056
  }
7057
 
7058
- /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(473).Buffer))
7059
 
7060
  /***/ },
7061
 
7062
- /***/ 478:
7063
  /***/ function(module, exports) {
7064
 
7065
  /* (ignored) */
7066
 
7067
  /***/ },
7068
 
7069
- /***/ 479:
7070
  /***/ function(module, exports, __webpack_require__) {
7071
 
7072
  /* WEBPACK VAR INJECTION */(function(process) {// Copyright Joyent, Inc. and other Node contributors.
@@ -7107,12 +7246,12 @@ webpackJsonp([0],{
7107
 
7108
 
7109
  /*<replacement>*/
7110
- var util = __webpack_require__(477);
7111
- util.inherits = __webpack_require__(460);
7112
  /*</replacement>*/
7113
 
7114
- var Readable = __webpack_require__(471);
7115
- var Writable = __webpack_require__(480);
7116
 
7117
  util.inherits(Duplex, Readable);
7118
 
@@ -7163,7 +7302,7 @@ webpackJsonp([0],{
7163
 
7164
  /***/ },
7165
 
7166
- /***/ 480:
7167
  /***/ function(module, exports, __webpack_require__) {
7168
 
7169
  /* WEBPACK VAR INJECTION */(function(process) {// Copyright Joyent, Inc. and other Node contributors.
@@ -7194,18 +7333,18 @@ webpackJsonp([0],{
7194
  module.exports = Writable;
7195
 
7196
  /*<replacement>*/
7197
- var Buffer = __webpack_require__(473).Buffer;
7198
  /*</replacement>*/
7199
 
7200
  Writable.WritableState = WritableState;
7201
 
7202
 
7203
  /*<replacement>*/
7204
- var util = __webpack_require__(477);
7205
- util.inherits = __webpack_require__(460);
7206
  /*</replacement>*/
7207
 
7208
- var Stream = __webpack_require__(469);
7209
 
7210
  util.inherits(Writable, Stream);
7211
 
@@ -7216,7 +7355,7 @@ webpackJsonp([0],{
7216
  }
7217
 
7218
  function WritableState(options, stream) {
7219
- var Duplex = __webpack_require__(479);
7220
 
7221
  options = options || {};
7222
 
@@ -7304,7 +7443,7 @@ webpackJsonp([0],{
7304
  }
7305
 
7306
  function Writable(options) {
7307
- var Duplex = __webpack_require__(479);
7308
 
7309
  // Writable ctor is applied to Duplexes, though they're not
7310
  // instanceof Writable, they're instanceof Readable.
@@ -7648,7 +7787,7 @@ webpackJsonp([0],{
7648
 
7649
  /***/ },
7650
 
7651
- /***/ 481:
7652
  /***/ function(module, exports, __webpack_require__) {
7653
 
7654
  // Copyright Joyent, Inc. and other Node contributors.
@@ -7672,7 +7811,7 @@ webpackJsonp([0],{
7672
  // OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
7673
  // USE OR OTHER DEALINGS IN THE SOFTWARE.
7674
 
7675
- var Buffer = __webpack_require__(473).Buffer;
7676
 
7677
  var isBufferEncoding = Buffer.isEncoding
7678
  || function(encoding) {
@@ -7876,7 +8015,7 @@ webpackJsonp([0],{
7876
 
7877
  /***/ },
7878
 
7879
- /***/ 482:
7880
  /***/ function(module, exports, __webpack_require__) {
7881
 
7882
  // Copyright Joyent, Inc. and other Node contributors.
@@ -7945,11 +8084,11 @@ webpackJsonp([0],{
7945
 
7946
  module.exports = Transform;
7947
 
7948
- var Duplex = __webpack_require__(479);
7949
 
7950
  /*<replacement>*/
7951
- var util = __webpack_require__(477);
7952
- util.inherits = __webpack_require__(460);
7953
  /*</replacement>*/
7954
 
7955
  util.inherits(Transform, Duplex);
@@ -8092,7 +8231,7 @@ webpackJsonp([0],{
8092
 
8093
  /***/ },
8094
 
8095
- /***/ 483:
8096
  /***/ function(module, exports, __webpack_require__) {
8097
 
8098
  // Copyright Joyent, Inc. and other Node contributors.
@@ -8122,11 +8261,11 @@ webpackJsonp([0],{
8122
 
8123
  module.exports = PassThrough;
8124
 
8125
- var Transform = __webpack_require__(482);
8126
 
8127
  /*<replacement>*/
8128
- var util = __webpack_require__(477);
8129
- util.inherits = __webpack_require__(460);
8130
  /*</replacement>*/
8131
 
8132
  util.inherits(PassThrough, Transform);
@@ -8145,51 +8284,51 @@ webpackJsonp([0],{
8145
 
8146
  /***/ },
8147
 
8148
- /***/ 484:
8149
  /***/ function(module, exports, __webpack_require__) {
8150
 
8151
- module.exports = __webpack_require__(480)
8152
 
8153
 
8154
  /***/ },
8155
 
8156
- /***/ 485:
8157
  /***/ function(module, exports, __webpack_require__) {
8158
 
8159
- module.exports = __webpack_require__(479)
8160
 
8161
 
8162
  /***/ },
8163
 
8164
- /***/ 486:
8165
  /***/ function(module, exports, __webpack_require__) {
8166
 
8167
- module.exports = __webpack_require__(482)
8168
 
8169
 
8170
  /***/ },
8171
 
8172
- /***/ 487:
8173
  /***/ function(module, exports, __webpack_require__) {
8174
 
8175
- module.exports = __webpack_require__(483)
8176
 
8177
 
8178
  /***/ },
8179
 
8180
- /***/ 488:
8181
  /***/ function(module, exports) {
8182
 
8183
  /* (ignored) */
8184
 
8185
  /***/ },
8186
 
8187
- /***/ 489:
8188
  /***/ function(module, exports, __webpack_require__) {
8189
 
8190
  'use strict';
8191
 
8192
- var Buffer = __webpack_require__(490).Buffer;
8193
 
8194
  var isEncoding = Buffer.isEncoding || function (encoding) {
8195
  encoding = '' + encoding;
@@ -8462,11 +8601,11 @@ webpackJsonp([0],{
8462
 
8463
  /***/ },
8464
 
8465
- /***/ 490:
8466
  /***/ function(module, exports, __webpack_require__) {
8467
 
8468
  /* eslint-disable node/no-deprecated-api */
8469
- var buffer = __webpack_require__(473)
8470
  var Buffer = buffer.Buffer
8471
 
8472
  // alternative to using Object.keys for old browsers
@@ -8531,7 +8670,7 @@ webpackJsonp([0],{
8531
 
8532
  /***/ },
8533
 
8534
- /***/ 491:
8535
  /***/ function(module, exports, __webpack_require__) {
8536
 
8537
  module.exports = ProxyHandler;
@@ -8540,7 +8679,7 @@ webpackJsonp([0],{
8540
  this._cbs = cbs || {};
8541
  }
8542
 
8543
- var EVENTS = __webpack_require__(452).EVENTS;
8544
  Object.keys(EVENTS).forEach(function(name){
8545
  if(EVENTS[name] === 0){
8546
  name = "on" + name;
@@ -8564,18 +8703,18 @@ webpackJsonp([0],{
8564
 
8565
  /***/ },
8566
 
8567
- /***/ 492:
8568
  /***/ function(module, exports, __webpack_require__) {
8569
 
8570
  var DomUtils = module.exports;
8571
 
8572
  [
8573
- __webpack_require__(493),
8574
- __webpack_require__(499),
8575
  __webpack_require__(500),
8576
  __webpack_require__(501),
8577
  __webpack_require__(502),
8578
- __webpack_require__(503)
 
8579
  ].forEach(function(ext){
8580
  Object.keys(ext).forEach(function(key){
8581
  DomUtils[key] = ext[key].bind(DomUtils);
@@ -8585,11 +8724,11 @@ webpackJsonp([0],{
8585
 
8586
  /***/ },
8587
 
8588
- /***/ 493:
8589
  /***/ function(module, exports, __webpack_require__) {
8590
 
8591
- var ElementType = __webpack_require__(463),
8592
- getOuterHTML = __webpack_require__(494),
8593
  isTag = ElementType.isTag;
8594
 
8595
  module.exports = {
@@ -8615,14 +8754,14 @@ webpackJsonp([0],{
8615
 
8616
  /***/ },
8617
 
8618
- /***/ 494:
8619
  /***/ function(module, exports, __webpack_require__) {
8620
 
8621
  /*
8622
  Module dependencies
8623
  */
8624
- var ElementType = __webpack_require__(495);
8625
- var entities = __webpack_require__(496);
8626
 
8627
  /*
8628
  Boolean Attributes
@@ -8800,6 +8939,26 @@ webpackJsonp([0],{
8800
 
8801
  /***/ },
8802
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
8803
  /***/ 1:
8804
  /***/ function(module, exports, __webpack_require__) {
8805
 
@@ -8856,65 +9015,25 @@ webpackJsonp([0],{
8856
 
8857
  /***/ },
8858
 
8859
- /***/ 496:
8860
  /***/ function(module, exports, __webpack_require__) {
8861
 
8862
- var encode = __webpack_require__(497),
8863
- decode = __webpack_require__(498);
8864
-
8865
- exports.decode = function(data, level){
8866
- return (!level || level <= 0 ? decode.XML : decode.HTML)(data);
8867
- };
8868
 
8869
- exports.decodeStrict = function(data, level){
8870
- return (!level || level <= 0 ? decode.XML : decode.HTMLStrict)(data);
8871
- };
8872
 
8873
- exports.encode = function(data, level){
8874
- return (!level || level <= 0 ? encode.XML : encode.HTML)(data);
8875
- };
8876
 
8877
- exports.encodeXML = encode.XML;
8878
 
8879
- exports.encodeHTML4 =
8880
- exports.encodeHTML5 =
8881
- exports.encodeHTML = encode.HTML;
8882
-
8883
- exports.decodeXML =
8884
- exports.decodeXMLStrict = decode.XML;
8885
-
8886
- exports.decodeHTML4 =
8887
- exports.decodeHTML5 =
8888
- exports.decodeHTML = decode.HTML;
8889
-
8890
- exports.decodeHTML4Strict =
8891
- exports.decodeHTML5Strict =
8892
- exports.decodeHTMLStrict = decode.HTMLStrict;
8893
-
8894
- exports.escape = encode.escape;
8895
-
8896
-
8897
- /***/ },
8898
-
8899
- /***/ 497:
8900
- /***/ function(module, exports, __webpack_require__) {
8901
-
8902
- var inverseXML = getInverseObj(__webpack_require__(459)),
8903
- xmlReplacer = getInverseReplacer(inverseXML);
8904
-
8905
- exports.XML = getInverse(inverseXML, xmlReplacer);
8906
-
8907
- var inverseHTML = getInverseObj(__webpack_require__(457)),
8908
- htmlReplacer = getInverseReplacer(inverseHTML);
8909
-
8910
- exports.HTML = getInverse(inverseHTML, htmlReplacer);
8911
-
8912
- function getInverseObj(obj){
8913
- return Object.keys(obj).sort().reduce(function(inverse, name){
8914
- inverse[obj[name]] = "&" + name + ";";
8915
- return inverse;
8916
- }, {});
8917
- }
8918
 
8919
  function getInverseReplacer(inverse){
8920
  var single = [],
@@ -8976,13 +9095,13 @@ webpackJsonp([0],{
8976
 
8977
  /***/ },
8978
 
8979
- /***/ 498:
8980
  /***/ function(module, exports, __webpack_require__) {
8981
 
8982
- var entityMap = __webpack_require__(457),
8983
- legacyMap = __webpack_require__(458),
8984
- xmlMap = __webpack_require__(459),
8985
- decodeCodePoint = __webpack_require__(455);
8986
 
8987
  var decodeXMLStrict = getStrictDecoder(xmlMap),
8988
  decodeHTMLStrict = getStrictDecoder(entityMap);
@@ -9054,7 +9173,7 @@ webpackJsonp([0],{
9054
 
9055
  /***/ },
9056
 
9057
- /***/ 499:
9058
  /***/ function(module, exports) {
9059
 
9060
  var getChildren = exports.getChildren = function(elem){
@@ -9085,7 +9204,7 @@ webpackJsonp([0],{
9085
 
9086
  /***/ },
9087
 
9088
- /***/ 500:
9089
  /***/ function(module, exports) {
9090
 
9091
  exports.removeElement = function(elem){
@@ -9169,10 +9288,10 @@ webpackJsonp([0],{
9169
 
9170
  /***/ },
9171
 
9172
- /***/ 501:
9173
  /***/ function(module, exports, __webpack_require__) {
9174
 
9175
- var isTag = __webpack_require__(463).isTag;
9176
 
9177
  module.exports = {
9178
  filter: filter,
@@ -9275,10 +9394,10 @@ webpackJsonp([0],{
9275
 
9276
  /***/ },
9277
 
9278
- /***/ 502:
9279
  /***/ function(module, exports, __webpack_require__) {
9280
 
9281
- var ElementType = __webpack_require__(463);
9282
  var isTag = exports.isTag = ElementType.isTag;
9283
 
9284
  exports.testElement = function(options, element){
@@ -9369,7 +9488,7 @@ webpackJsonp([0],{
9369
 
9370
  /***/ },
9371
 
9372
- /***/ 503:
9373
  /***/ function(module, exports) {
9374
 
9375
  // removeSubsets
@@ -9517,7 +9636,7 @@ webpackJsonp([0],{
9517
 
9518
  /***/ },
9519
 
9520
- /***/ 504:
9521
  /***/ function(module, exports, __webpack_require__) {
9522
 
9523
  module.exports = CollectingHandler;
@@ -9527,7 +9646,7 @@ webpackJsonp([0],{
9527
  this.events = [];
9528
  }
9529
 
9530
- var EVENTS = __webpack_require__(452).EVENTS;
9531
  Object.keys(EVENTS).forEach(function(name){
9532
  if(EVENTS[name] === 0){
9533
  name = "on" + name;
@@ -9579,7 +9698,7 @@ webpackJsonp([0],{
9579
 
9580
  /***/ },
9581
 
9582
- /***/ 505:
9583
  /***/ function(module, exports, __webpack_require__) {
9584
 
9585
  'use strict';
@@ -9589,7 +9708,7 @@ webpackJsonp([0],{
9589
  });
9590
  exports.default = ProcessNodes;
9591
 
9592
- var _elementTypes = __webpack_require__(506);
9593
 
9594
  var _elementTypes2 = _interopRequireDefault(_elementTypes);
9595
 
@@ -9633,7 +9752,7 @@ webpackJsonp([0],{
9633
 
9634
  /***/ },
9635
 
9636
- /***/ 506:
9637
  /***/ function(module, exports, __webpack_require__) {
9638
 
9639
  'use strict';
@@ -9644,21 +9763,21 @@ webpackJsonp([0],{
9644
 
9645
  var _ElementType$Text$Ele;
9646
 
9647
- var _htmlparser = __webpack_require__(452);
9648
 
9649
- var _TextElementType = __webpack_require__(507);
9650
 
9651
  var _TextElementType2 = _interopRequireDefault(_TextElementType);
9652
 
9653
- var _TagElementType = __webpack_require__(508);
9654
 
9655
  var _TagElementType2 = _interopRequireDefault(_TagElementType);
9656
 
9657
- var _StyleElementType = __webpack_require__(516);
9658
 
9659
  var _StyleElementType2 = _interopRequireDefault(_StyleElementType);
9660
 
9661
- var _UnsupportedElementType = __webpack_require__(517);
9662
 
9663
  var _UnsupportedElementType2 = _interopRequireDefault(_UnsupportedElementType);
9664
 
@@ -9674,7 +9793,7 @@ webpackJsonp([0],{
9674
 
9675
  /***/ },
9676
 
9677
- /***/ 507:
9678
  /***/ function(module, exports) {
9679
 
9680
  "use strict";
@@ -9697,7 +9816,7 @@ webpackJsonp([0],{
9697
 
9698
  /***/ },
9699
 
9700
- /***/ 508:
9701
  /***/ function(module, exports, __webpack_require__) {
9702
 
9703
  'use strict';
@@ -9711,19 +9830,19 @@ webpackJsonp([0],{
9711
 
9712
  var _react2 = _interopRequireDefault(_react);
9713
 
9714
- var _ProcessNodes = __webpack_require__(505);
9715
 
9716
  var _ProcessNodes2 = _interopRequireDefault(_ProcessNodes);
9717
 
9718
- var _GeneratePropsFromAttributes = __webpack_require__(509);
9719
 
9720
  var _GeneratePropsFromAttributes2 = _interopRequireDefault(_GeneratePropsFromAttributes);
9721
 
9722
- var _TransformTagName = __webpack_require__(514);
9723
 
9724
  var _TransformTagName2 = _interopRequireDefault(_TransformTagName);
9725
 
9726
- var _VoidElements = __webpack_require__(515);
9727
 
9728
  var _VoidElements2 = _interopRequireDefault(_VoidElements);
9729
 
@@ -9756,7 +9875,7 @@ webpackJsonp([0],{
9756
 
9757
  /***/ },
9758
 
9759
- /***/ 509:
9760
  /***/ function(module, exports, __webpack_require__) {
9761
 
9762
  'use strict';
@@ -9769,11 +9888,11 @@ webpackJsonp([0],{
9769
 
9770
  exports.default = GeneratePropsFromAttributes;
9771
 
9772
- var _HtmlAttributesToReact = __webpack_require__(510);
9773
 
9774
  var _HtmlAttributesToReact2 = _interopRequireDefault(_HtmlAttributesToReact);
9775
 
9776
- var _InlineStyleToObject = __webpack_require__(513);
9777
 
9778
  var _InlineStyleToObject2 = _interopRequireDefault(_InlineStyleToObject);
9779
 
@@ -9800,7 +9919,7 @@ webpackJsonp([0],{
9800
 
9801
  /***/ },
9802
 
9803
- /***/ 510:
9804
  /***/ function(module, exports, __webpack_require__) {
9805
 
9806
  'use strict';
@@ -9810,11 +9929,11 @@ webpackJsonp([0],{
9810
  });
9811
  exports.default = HtmlAttributesToReact;
9812
 
9813
- var _BooleanAttributes = __webpack_require__(511);
9814
 
9815
  var _BooleanAttributes2 = _interopRequireDefault(_BooleanAttributes);
9816
 
9817
- var _ReactAttributes = __webpack_require__(512);
9818
 
9819
  var _ReactAttributes2 = _interopRequireDefault(_ReactAttributes);
9820
 
@@ -9867,7 +9986,7 @@ webpackJsonp([0],{
9867
 
9868
  /***/ },
9869
 
9870
- /***/ 511:
9871
  /***/ function(module, exports) {
9872
 
9873
  'use strict';
@@ -9887,7 +10006,7 @@ webpackJsonp([0],{
9887
 
9888
  /***/ },
9889
 
9890
- /***/ 512:
9891
  /***/ function(module, exports) {
9892
 
9893
  'use strict';
@@ -10056,7 +10175,7 @@ webpackJsonp([0],{
10056
 
10057
  /***/ },
10058
 
10059
- /***/ 513:
10060
  /***/ function(module, exports) {
10061
 
10062
  'use strict';
@@ -10120,7 +10239,7 @@ webpackJsonp([0],{
10120
 
10121
  /***/ },
10122
 
10123
- /***/ 514:
10124
  /***/ function(module, exports) {
10125
 
10126
  'use strict';
@@ -10151,7 +10270,7 @@ webpackJsonp([0],{
10151
 
10152
  /***/ },
10153
 
10154
- /***/ 515:
10155
  /***/ function(module, exports) {
10156
 
10157
  'use strict';
@@ -10168,7 +10287,7 @@ webpackJsonp([0],{
10168
 
10169
  /***/ },
10170
 
10171
- /***/ 516:
10172
  /***/ function(module, exports, __webpack_require__) {
10173
 
10174
  'use strict';
@@ -10182,7 +10301,7 @@ webpackJsonp([0],{
10182
 
10183
  var _react2 = _interopRequireDefault(_react);
10184
 
10185
- var _GeneratePropsFromAttributes = __webpack_require__(509);
10186
 
10187
  var _GeneratePropsFromAttributes2 = _interopRequireDefault(_GeneratePropsFromAttributes);
10188
 
@@ -10213,7 +10332,7 @@ webpackJsonp([0],{
10213
 
10214
  /***/ },
10215
 
10216
- /***/ 517:
10217
  /***/ function(module, exports) {
10218
 
10219
  "use strict";
@@ -10235,14 +10354,14 @@ webpackJsonp([0],{
10235
 
10236
  /***/ },
10237
 
10238
- /***/ 518:
10239
  /***/ function(module, exports, __webpack_require__) {
10240
 
10241
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
10242
 
10243
  var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
10244
 
10245
- !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(181), __webpack_require__(280), __webpack_require__(276), __webpack_require__(292), __webpack_require__(522), __webpack_require__(519), __webpack_require__(523), __webpack_require__(432), __webpack_require__(436), __webpack_require__(275)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, Router, _, MailPoet, Form, StandardNewsletterFields, NotificationNewsletterFields, WelcomeNewsletterFields, Breadcrumb, HelpTooltip, jQuery) {
10246
  var NewsletterSend = React.createClass({
10247
  displayName: 'NewsletterSend',
10248
 
@@ -10313,16 +10432,44 @@ webpackJsonp([0],{
10313
  });
10314
  });
10315
  },
10316
- handleSend: function handleSend(e) {
10317
  var _this2 = this;
10318
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
10319
  e.preventDefault();
10320
 
10321
  if (!this.isValid()) {
10322
  jQuery('#mailpoet_newsletter').parsley().validate();
10323
  } else {
 
10324
  this.saveNewsletter(e).done(function () {
10325
- _this2.setState({ loading: true });
10326
  }).done(function (response) {
10327
  switch (response.data.type) {
10328
  case 'notification':
@@ -10332,81 +10479,99 @@ webpackJsonp([0],{
10332
  endpoint: 'newsletters',
10333
  action: 'setStatus',
10334
  data: {
10335
- id: _this2.props.params.id,
10336
  status: 'active'
10337
  }
10338
  }).done(function (response2) {
10339
- // redirect to listing based on newsletter type
10340
- _this2.context.router.push('/' + (_this2.state.item.type || ''));
10341
- var opts = _this2.state.item.options;
10342
- // display success message depending on newsletter type
10343
- if (response2.data.type === 'welcome') {
10344
- MailPoet.Notice.success(MailPoet.I18n.t('welcomeEmailActivated'));
10345
- MailPoet.trackEvent('Emails > Welcome email activated', {
10346
- 'MailPoet Free version': window.mailpoet_version,
10347
- 'List type': opts.event,
10348
- Delay: opts.afterTimeNumber + ' ' + opts.afterTimeType
10349
- });
10350
- } else if (response2.data.type === 'notification') {
10351
- MailPoet.Notice.success(MailPoet.I18n.t('postNotificationActivated'));
10352
- MailPoet.trackEvent('Emails > Post notifications activated', {
10353
- 'MailPoet Free version': window.mailpoet_version,
10354
- Frequency: opts.intervalType
10355
- });
10356
- }
10357
- }).fail(_this2.showError);
 
 
 
 
 
 
 
 
10358
  default:
10359
  return MailPoet.Ajax.post({
10360
  api_version: window.mailpoet_api_version,
10361
  endpoint: 'sendingQueue',
10362
  action: 'add',
10363
  data: {
10364
- newsletter_id: _this2.props.params.id
10365
  }
10366
  }).done(function (response2) {
10367
- // redirect to listing based on newsletter type
10368
- _this2.context.router.push('/' + (_this2.state.item.type || ''));
10369
-
10370
- if (response2.data.status === 'scheduled') {
10371
- MailPoet.Notice.success(MailPoet.I18n.t('newsletterHasBeenScheduled'));
10372
- MailPoet.trackEvent('Emails > Newsletter sent', {
10373
- scheduled: true,
10374
- 'MailPoet Free version': window.mailpoet_version
10375
- });
10376
- } else {
10377
- MailPoet.Notice.success(MailPoet.I18n.t('newsletterBeingSent'));
10378
- MailPoet.trackEvent('Emails > Newsletter sent', {
10379
- scheduled: false,
10380
- 'MailPoet Free version': window.mailpoet_version
10381
- });
10382
- }
10383
- }).fail(_this2.showError);
 
 
 
 
 
 
 
 
10384
  }
10385
- }).fail(this.showError).always(function () {
10386
- _this2.setState({ loading: false });
 
 
10387
  });
10388
  }
10389
  return false;
10390
  },
10391
  handleResume: function handleResume(e) {
10392
- var _this3 = this;
10393
 
10394
  e.preventDefault();
10395
  if (!this.isValid()) {
10396
  jQuery('#mailpoet_newsletter').parsley().validate();
10397
  } else {
10398
  this.saveNewsletter(e).done(function () {
10399
- _this3.setState({ loading: true });
10400
  }).done(function () {
10401
  MailPoet.Ajax.post({
10402
  api_version: window.mailpoet_api_version,
10403
  endpoint: 'sendingQueue',
10404
  action: 'resume',
10405
  data: {
10406
- newsletter_id: _this3.state.item.id
10407
  }
10408
  }).done(function () {
10409
- _this3.context.router.push('/' + (_this3.state.item.type || ''));
10410
  MailPoet.Notice.success(MailPoet.I18n.t('newsletterSendingHasBeenResumed'));
10411
  }).fail(function (response) {
10412
  if (response.errors.length > 0) {
@@ -10416,20 +10581,20 @@ webpackJsonp([0],{
10416
  }
10417
  });
10418
  }).fail(this.showError).always(function () {
10419
- _this3.setState({ loading: false });
10420
  });
10421
  }
10422
  return false;
10423
  },
10424
  handleSave: function handleSave(e) {
10425
- var _this4 = this;
10426
 
10427
  e.preventDefault();
10428
 
10429
  this.saveNewsletter(e).done(function () {
10430
  MailPoet.Notice.success(MailPoet.I18n.t('newsletterUpdated'));
10431
  }).done(function () {
10432
- _this4.context.router.push('/' + (_this4.state.item.type || ''));
10433
  }).fail(this.showError);
10434
  },
10435
  handleRedirectToDesign: function handleRedirectToDesign(e) {
@@ -10443,7 +10608,7 @@ webpackJsonp([0],{
10443
  }).fail(this.showError);
10444
  },
10445
  saveNewsletter: function saveNewsletter() {
10446
- var _this5 = this;
10447
 
10448
  var data = this.state.item;
10449
  data.queue = undefined;
@@ -10459,7 +10624,7 @@ webpackJsonp([0],{
10459
  action: 'save',
10460
  data: newsletterData
10461
  }).always(function () {
10462
- _this5.setState({ loading: false });
10463
  });
10464
  },
10465
  showError: function showError(response) {
@@ -10553,12 +10718,12 @@ webpackJsonp([0],{
10553
 
10554
  /***/ },
10555
 
10556
- /***/ 519:
10557
  /***/ function(module, exports, __webpack_require__) {
10558
 
10559
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
10560
 
10561
- !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(276), __webpack_require__(429), __webpack_require__(520), __webpack_require__(280)], __WEBPACK_AMD_DEFINE_RESULT__ = function (MailPoet, Hooks, Scheduling, _) {
10562
  var fields = [{
10563
  name: 'subject',
10564
  label: MailPoet.I18n.t('subjectLine'),
@@ -10653,7 +10818,7 @@ webpackJsonp([0],{
10653
 
10654
  /***/ },
10655
 
10656
- /***/ 520:
10657
  /***/ function(module, exports, __webpack_require__) {
10658
 
10659
  'use strict';
@@ -10672,7 +10837,7 @@ webpackJsonp([0],{
10672
 
10673
  var _formFieldsSelectJsx2 = _interopRequireDefault(_formFieldsSelectJsx);
10674
 
10675
- var _newslettersSchedulingCommonJsx = __webpack_require__(521);
10676
 
10677
  var intervalField = {
10678
  name: 'intervalType',
@@ -10787,7 +10952,7 @@ webpackJsonp([0],{
10787
 
10788
  /***/ },
10789
 
10790
- /***/ 522:
10791
  /***/ function(module, exports, __webpack_require__) {
10792
 
10793
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
@@ -10796,7 +10961,7 @@ webpackJsonp([0],{
10796
 
10797
  var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
10798
 
10799
- !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(275), __webpack_require__(280), __webpack_require__(276), __webpack_require__(429)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, jq, _, MailPoet, Hooks) {
10800
  var jQuery = jq;
10801
 
10802
  var currentTime = window.mailpoet_current_time || '00:00';
@@ -11151,109 +11316,4658 @@ webpackJsonp([0],{
11151
  component: StandardScheduling
11152
  }];
11153
 
11154
- fields = Hooks.applyFilters('mailpoet_newsletters_3rd_step_fields', fields);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
11155
 
11156
- return {
11157
- getFields: function getFields() {
11158
- return fields;
11159
- },
11160
- getSendButtonOptions: function getSendButtonOptions(newsletter) {
11161
- var newsletterOptions = newsletter || {};
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
11162
 
11163
- var isScheduled = typeof newsletterOptions.options === 'object' && newsletterOptions.options.isScheduled === '1';
11164
- var options = {
11165
- value: isScheduled ? MailPoet.I18n.t('schedule') : MailPoet.I18n.t('send')
11166
- };
11167
 
11168
- if (newsletterOptions.status === 'sent' || newsletterOptions.status === 'sending') {
11169
- options.disabled = 'disabled';
11170
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
11171
 
11172
- return options;
11173
- }
11174
- };
11175
- }.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
11176
 
11177
- /***/ },
 
 
 
 
 
 
 
11178
 
11179
- /***/ 523:
11180
- /***/ function(module, exports, __webpack_require__) {
11181
 
11182
- var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
 
 
11183
 
11184
- !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(276), __webpack_require__(429), __webpack_require__(524)], __WEBPACK_AMD_DEFINE_RESULT__ = function (MailPoet, Hooks, Scheduling) {
11185
- var fields = [{
11186
- name: 'subject',
11187
- label: MailPoet.I18n.t('subjectLine'),
11188
- tip: MailPoet.I18n.t('subjectLineTip'),
11189
- type: 'text',
11190
- validation: {
11191
- 'data-parsley-required': true,
11192
- 'data-parsley-required-message': MailPoet.I18n.t('emptySubjectLineError')
11193
- }
11194
- }, {
11195
- name: 'options',
11196
- label: MailPoet.I18n.t('sendWelcomeEmailWhen'),
11197
- type: 'reactComponent',
11198
- component: Scheduling
11199
- }, {
11200
- name: 'sender',
11201
- label: MailPoet.I18n.t('sender'),
11202
- tip: MailPoet.I18n.t('senderTip'),
11203
- fields: [{
11204
- name: 'sender_name',
11205
- type: 'text',
11206
- placeholder: MailPoet.I18n.t('senderNamePlaceholder'),
11207
- validation: {
11208
- 'data-parsley-required': true
11209
  }
11210
- }, {
11211
- name: 'sender_address',
11212
- type: 'text',
11213
- placeholder: MailPoet.I18n.t('senderAddressPlaceholder'),
11214
- validation: {
11215
- 'data-parsley-required': true,
11216
- 'data-parsley-type': 'email'
11217
  }
11218
- }]
11219
- }, {
11220
- name: 'reply-to',
11221
- label: MailPoet.I18n.t('replyTo'),
11222
- tip: MailPoet.I18n.t('replyToTip'),
11223
- inline: true,
11224
- fields: [{
11225
- name: 'reply_to_name',
11226
- type: 'text',
11227
- placeholder: MailPoet.I18n.t('replyToNamePlaceholder')
11228
- }, {
11229
- name: 'reply_to_address',
11230
- type: 'text',
11231
- placeholder: MailPoet.I18n.t('replyToAddressPlaceholder')
11232
- }]
11233
- }];
11234
 
11235
- fields = Hooks.applyFilters('mailpoet_newsletters_3rd_step_fields', fields);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
11236
 
11237
- return {
11238
- getFields: function getFields() {
11239
- return fields;
11240
- },
11241
- getSendButtonOptions: function getSendButtonOptions() {
11242
- return {
11243
- value: MailPoet.I18n.t('activate')
11244
- };
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
11245
  }
11246
- };
11247
- }.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
11248
 
11249
  /***/ },
11250
 
11251
- /***/ 526:
11252
  /***/ function(module, exports, __webpack_require__) {
11253
 
11254
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
11255
 
11256
- !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(181), __webpack_require__(276), __webpack_require__(432)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, Router, MailPoet, Breadcrumb) {
11257
  var NewsletterStandard = React.createClass({
11258
  displayName: 'NewsletterStandard',
11259
 
@@ -11303,12 +16017,12 @@ webpackJsonp([0],{
11303
 
11304
  /***/ },
11305
 
11306
- /***/ 527:
11307
  /***/ function(module, exports, __webpack_require__) {
11308
 
11309
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
11310
 
11311
- !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(280), __webpack_require__(2), __webpack_require__(181), __webpack_require__(276), __webpack_require__(520), __webpack_require__(432)], __WEBPACK_AMD_DEFINE_RESULT__ = function (_, React, Router, MailPoet, Scheduling, Breadcrumb) {
11312
  var field = {
11313
  name: 'options',
11314
  type: 'reactComponent',
@@ -11398,7 +16112,7 @@ webpackJsonp([0],{
11398
 
11399
  /***/ },
11400
 
11401
- /***/ 528:
11402
  /***/ function(module, exports, __webpack_require__) {
11403
 
11404
  'use strict';
@@ -11411,7 +16125,7 @@ webpackJsonp([0],{
11411
 
11412
  var _reactRouter = __webpack_require__(181);
11413
 
11414
- var _reactConfirmAlert = __webpack_require__(435);
11415
 
11416
  var _classnames = __webpack_require__(277);
11417
 
@@ -11421,7 +16135,7 @@ webpackJsonp([0],{
11421
 
11422
  var _mailpoet2 = _interopRequireDefault(_mailpoet);
11423
 
11424
- var _wpJsHooks = __webpack_require__(429);
11425
 
11426
  var _wpJsHooks2 = _interopRequireDefault(_wpJsHooks);
11427
 
@@ -11429,11 +16143,11 @@ webpackJsonp([0],{
11429
 
11430
  var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
11431
 
11432
- var _newslettersListingsTabsJsx = __webpack_require__(529);
11433
 
11434
  var _newslettersListingsTabsJsx2 = _interopRequireDefault(_newslettersListingsTabsJsx);
11435
 
11436
- var _newslettersListingsMixinsJsx = __webpack_require__(530);
11437
 
11438
  var mailpoetTrackingEnabled = !!window.mailpoet_tracking_enabled;
11439
 
@@ -11663,7 +16377,7 @@ webpackJsonp([0],{
11663
 
11664
  /***/ },
11665
 
11666
- /***/ 529:
11667
  /***/ function(module, exports, __webpack_require__) {
11668
 
11669
  'use strict';
@@ -11737,7 +16451,7 @@ webpackJsonp([0],{
11737
 
11738
  /***/ },
11739
 
11740
- /***/ 530:
11741
  /***/ function(module, exports, __webpack_require__) {
11742
 
11743
  'use strict';
@@ -11756,7 +16470,7 @@ webpackJsonp([0],{
11756
 
11757
  var _reactDom2 = _interopRequireDefault(_reactDom);
11758
 
11759
- var _reactStringReplace = __webpack_require__(422);
11760
 
11761
  var _reactStringReplace2 = _interopRequireDefault(_reactStringReplace);
11762
 
@@ -11778,11 +16492,11 @@ webpackJsonp([0],{
11778
 
11779
  var _jquery2 = _interopRequireDefault(_jquery);
11780
 
11781
- var _wpJsHooks = __webpack_require__(429);
11782
 
11783
  var _wpJsHooks2 = _interopRequireDefault(_wpJsHooks);
11784
 
11785
- var _newslettersBadgesStatsJsx = __webpack_require__(531);
11786
 
11787
  var _newslettersBadgesStatsJsx2 = _interopRequireDefault(_newslettersBadgesStatsJsx);
11788
 
@@ -12246,7 +16960,7 @@ webpackJsonp([0],{
12246
 
12247
  /***/ },
12248
 
12249
- /***/ 534:
12250
  /***/ function(module, exports, __webpack_require__) {
12251
 
12252
  'use strict';
@@ -12263,11 +16977,11 @@ webpackJsonp([0],{
12263
 
12264
  var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
12265
 
12266
- var _newslettersListingsTabsJsx = __webpack_require__(529);
12267
 
12268
  var _newslettersListingsTabsJsx2 = _interopRequireDefault(_newslettersListingsTabsJsx);
12269
 
12270
- var _newslettersListingsMixinsJsx = __webpack_require__(530);
12271
 
12272
  var _classnames = __webpack_require__(277);
12273
 
@@ -12281,7 +16995,7 @@ webpackJsonp([0],{
12281
 
12282
  var _underscore2 = _interopRequireDefault(_underscore);
12283
 
12284
- var _wpJsHooks = __webpack_require__(429);
12285
 
12286
  var _wpJsHooks2 = _interopRequireDefault(_wpJsHooks);
12287
 
@@ -12600,7 +17314,7 @@ webpackJsonp([0],{
12600
 
12601
  /***/ },
12602
 
12603
- /***/ 535:
12604
  /***/ function(module, exports, __webpack_require__) {
12605
 
12606
  'use strict';
@@ -12617,11 +17331,11 @@ webpackJsonp([0],{
12617
 
12618
  var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
12619
 
12620
- var _newslettersListingsTabsJsx = __webpack_require__(529);
12621
 
12622
  var _newslettersListingsTabsJsx2 = _interopRequireDefault(_newslettersListingsTabsJsx);
12623
 
12624
- var _newslettersListingsMixinsJsx = __webpack_require__(530);
12625
 
12626
  var _classnames = __webpack_require__(277);
12627
 
@@ -12631,7 +17345,7 @@ webpackJsonp([0],{
12631
 
12632
  var _mailpoet2 = _interopRequireDefault(_mailpoet);
12633
 
12634
- var _newslettersSchedulingCommonJsx = __webpack_require__(521);
12635
 
12636
  var messages = {
12637
  onTrash: function onTrash(response) {
@@ -12948,7 +17662,7 @@ webpackJsonp([0],{
12948
 
12949
  /***/ },
12950
 
12951
- /***/ 536:
12952
  /***/ function(module, exports, __webpack_require__) {
12953
 
12954
  'use strict';
@@ -12969,7 +17683,7 @@ webpackJsonp([0],{
12969
 
12970
  var _mailpoet2 = _interopRequireDefault(_mailpoet);
12971
 
12972
- var _wpJsHooks = __webpack_require__(429);
12973
 
12974
  var _wpJsHooks2 = _interopRequireDefault(_wpJsHooks);
12975
 
@@ -12977,11 +17691,11 @@ webpackJsonp([0],{
12977
 
12978
  var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
12979
 
12980
- var _newslettersListingsTabsJsx = __webpack_require__(529);
12981
 
12982
  var _newslettersListingsTabsJsx2 = _interopRequireDefault(_newslettersListingsTabsJsx);
12983
 
12984
- var _newslettersListingsMixinsJsx = __webpack_require__(530);
12985
 
12986
  var mailpoetTrackingEnabled = !!window.mailpoet_tracking_enabled;
12987
 
@@ -13117,7 +17831,7 @@ webpackJsonp([0],{
13117
 
13118
  /***/ },
13119
 
13120
- /***/ 537:
13121
  /***/ function(module, exports, __webpack_require__) {
13122
 
13123
  'use strict';
@@ -13136,11 +17850,11 @@ webpackJsonp([0],{
13136
 
13137
  var _history = __webpack_require__(244);
13138
 
13139
- var _segmentsListJsx = __webpack_require__(538);
13140
 
13141
  var _segmentsListJsx2 = _interopRequireDefault(_segmentsListJsx);
13142
 
13143
- var _segmentsFormJsx = __webpack_require__(539);
13144
 
13145
  var _segmentsFormJsx2 = _interopRequireDefault(_segmentsFormJsx);
13146
 
@@ -13173,7 +17887,7 @@ webpackJsonp([0],{
13173
 
13174
  /***/ },
13175
 
13176
- /***/ 538:
13177
  /***/ function(module, exports, __webpack_require__) {
13178
 
13179
  'use strict';
@@ -13493,18 +18207,18 @@ webpackJsonp([0],{
13493
 
13494
  /***/ },
13495
 
13496
- /***/ 539:
13497
  /***/ function(module, exports, __webpack_require__) {
13498
 
13499
  /* WEBPACK VAR INJECTION */(function(global) {"use strict";
13500
 
13501
  if (!global["MailPoetLib"]) global["MailPoetLib"] = {};
13502
- module.exports = global["MailPoetLib"]["Form"] = __webpack_require__(540);
13503
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
13504
 
13505
  /***/ },
13506
 
13507
- /***/ 540:
13508
  /***/ function(module, exports, __webpack_require__) {
13509
 
13510
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
@@ -13567,7 +18281,7 @@ webpackJsonp([0],{
13567
 
13568
  /***/ },
13569
 
13570
- /***/ 541:
13571
  /***/ function(module, exports, __webpack_require__) {
13572
 
13573
  'use strict';
@@ -13586,7 +18300,7 @@ webpackJsonp([0],{
13586
 
13587
  var _history = __webpack_require__(244);
13588
 
13589
- var _listJsx = __webpack_require__(542);
13590
 
13591
  var _listJsx2 = _interopRequireDefault(_listJsx);
13592
 
@@ -13617,7 +18331,7 @@ webpackJsonp([0],{
13617
 
13618
  /***/ },
13619
 
13620
- /***/ 542:
13621
  /***/ function(module, exports, __webpack_require__) {
13622
 
13623
  'use strict';
@@ -13849,11 +18563,11 @@ webpackJsonp([0],{
13849
 
13850
  /***/ },
13851
 
13852
- /***/ 543:
13853
  /***/ function(module, exports, __webpack_require__) {
13854
 
13855
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
13856
- __webpack_require__(544),
13857
  __webpack_require__(275),
13858
  __webpack_require__(276)
13859
  ], __WEBPACK_AMD_DEFINE_RESULT__ = function ( // eslint-disable-line func-names
@@ -13942,15 +18656,15 @@ webpackJsonp([0],{
13942
 
13943
  /***/ },
13944
 
13945
- /***/ 544:
13946
  /***/ function(module, exports, __webpack_require__) {
13947
 
13948
- /* WEBPACK VAR INJECTION */(function(global) {module.exports = global["Backbone"] = __webpack_require__(545);
13949
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
13950
 
13951
  /***/ },
13952
 
13953
- /***/ 545:
13954
  /***/ function(module, exports, __webpack_require__) {
13955
 
13956
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/* WEBPACK VAR INJECTION */(function(global) {// Backbone.js 1.3.3
@@ -15878,7 +20592,7 @@ webpackJsonp([0],{
15878
 
15879
  /***/ },
15880
 
15881
- /***/ 546:
15882
  /***/ function(module, exports, __webpack_require__) {
15883
 
15884
  'use strict';
@@ -15897,15 +20611,15 @@ webpackJsonp([0],{
15897
 
15898
  var _history = __webpack_require__(244);
15899
 
15900
- var _helpSystem_statusJsx = __webpack_require__(547);
15901
 
15902
  var _helpSystem_statusJsx2 = _interopRequireDefault(_helpSystem_statusJsx);
15903
 
15904
- var _helpSystem_infoJsx = __webpack_require__(549);
15905
 
15906
  var _helpSystem_infoJsx2 = _interopRequireDefault(_helpSystem_infoJsx);
15907
 
15908
- var _helpKnowledge_baseJsx = __webpack_require__(550);
15909
 
15910
  var _helpKnowledge_baseJsx2 = _interopRequireDefault(_helpKnowledge_baseJsx);
15911
 
@@ -15939,7 +20653,7 @@ webpackJsonp([0],{
15939
 
15940
  /***/ },
15941
 
15942
- /***/ 547:
15943
  /***/ function(module, exports, __webpack_require__) {
15944
 
15945
  'use strict';
@@ -15954,11 +20668,11 @@ webpackJsonp([0],{
15954
 
15955
  var _react2 = _interopRequireDefault(_react);
15956
 
15957
- var _reactStringReplace = __webpack_require__(422);
15958
 
15959
  var _reactStringReplace2 = _interopRequireDefault(_reactStringReplace);
15960
 
15961
- var _tabsJsx = __webpack_require__(548);
15962
 
15963
  var _tabsJsx2 = _interopRequireDefault(_tabsJsx);
15964
 
@@ -16053,7 +20767,7 @@ webpackJsonp([0],{
16053
 
16054
  /***/ },
16055
 
16056
- /***/ 548:
16057
  /***/ function(module, exports, __webpack_require__) {
16058
 
16059
  'use strict';
@@ -16117,7 +20831,7 @@ webpackJsonp([0],{
16117
 
16118
  /***/ },
16119
 
16120
- /***/ 549:
16121
  /***/ function(module, exports, __webpack_require__) {
16122
 
16123
  'use strict';
@@ -16136,7 +20850,7 @@ webpackJsonp([0],{
16136
 
16137
  var _underscore2 = _interopRequireDefault(_underscore);
16138
 
16139
- var _tabsJsx = __webpack_require__(548);
16140
 
16141
  var _tabsJsx2 = _interopRequireDefault(_tabsJsx);
16142
 
@@ -16190,7 +20904,7 @@ webpackJsonp([0],{
16190
 
16191
  /***/ },
16192
 
16193
- /***/ 550:
16194
  /***/ function(module, exports, __webpack_require__) {
16195
 
16196
  'use strict';
@@ -16205,7 +20919,7 @@ webpackJsonp([0],{
16205
 
16206
  var _mailpoet2 = _interopRequireDefault(_mailpoet);
16207
 
16208
- var _tabsJsx = __webpack_require__(548);
16209
 
16210
  var _tabsJsx2 = _interopRequireDefault(_tabsJsx);
16211
 
@@ -16307,7 +21021,7 @@ webpackJsonp([0],{
16307
 
16308
  /***/ },
16309
 
16310
- /***/ 551:
16311
  /***/ function(module, exports, __webpack_require__) {
16312
 
16313
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
@@ -16355,18 +21069,18 @@ webpackJsonp([0],{
16355
 
16356
  /***/ },
16357
 
16358
- /***/ 552:
16359
  /***/ function(module, exports, __webpack_require__) {
16360
 
16361
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/* eslint-disable func-names */
16362
  !(__WEBPACK_AMD_DEFINE_ARRAY__ = [
16363
- __webpack_require__(544),
16364
  __webpack_require__(280),
16365
  __webpack_require__(275),
16366
  __webpack_require__(276),
16367
- __webpack_require__(553),
16368
- __webpack_require__(554),
16369
- __webpack_require__(555),
16370
  __webpack_require__(301)
16371
  ], __WEBPACK_AMD_DEFINE_RESULT__ = function (
16372
  Backbone,
@@ -17529,7 +22243,7 @@ webpackJsonp([0],{
17529
 
17530
  /***/ },
17531
 
17532
- /***/ 554:
17533
  /***/ function(module, exports) {
17534
 
17535
  /*!
@@ -17541,7 +22255,7 @@ webpackJsonp([0],{
17541
 
17542
  /***/ },
17543
 
17544
- /***/ 555:
17545
  /***/ function(module, exports) {
17546
 
17547
  /*
@@ -17627,14 +22341,14 @@ webpackJsonp([0],{
17627
 
17628
  /***/ },
17629
 
17630
- /***/ 556:
17631
  /***/ function(module, exports, __webpack_require__) {
17632
 
17633
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
17634
  __webpack_require__(280),
17635
  __webpack_require__(275),
17636
  __webpack_require__(276),
17637
- __webpack_require__(553)
17638
  ], __WEBPACK_AMD_DEFINE_RESULT__ = function (// eslint-disable-line func-names
17639
  _,
17640
  jQuery,
1
  webpackJsonp([0],{
2
 
3
+ /***/ 497:
4
+ /***/ function(module, exports, __webpack_require__) {
5
 
6
+ var encode = __webpack_require__(498),
7
+ decode = __webpack_require__(499);
 
 
 
 
 
 
 
8
 
9
+ exports.decode = function(data, level){
10
+ return (!level || level <= 0 ? decode.XML : decode.HTML)(data);
11
+ };
12
+
13
+ exports.decodeStrict = function(data, level){
14
+ return (!level || level <= 0 ? decode.XML : decode.HTMLStrict)(data);
15
+ };
16
+
17
+ exports.encode = function(data, level){
18
+ return (!level || level <= 0 ? encode.XML : encode.HTML)(data);
19
  };
20
 
21
+ exports.encodeXML = encode.XML;
22
+
23
+ exports.encodeHTML4 =
24
+ exports.encodeHTML5 =
25
+ exports.encodeHTML = encode.HTML;
26
+
27
+ exports.decodeXML =
28
+ exports.decodeXMLStrict = decode.XML;
29
+
30
+ exports.decodeHTML4 =
31
+ exports.decodeHTML5 =
32
+ exports.decodeHTML = decode.HTML;
33
+
34
+ exports.decodeHTML4Strict =
35
+ exports.decodeHTML5Strict =
36
+ exports.decodeHTMLStrict = decode.HTMLStrict;
37
+
38
+ exports.escape = encode.escape;
39
+
40
+
41
  /***/ },
42
 
43
  /***/ 0:
44
  /***/ function(module, exports, __webpack_require__) {
45
 
46
  __webpack_require__(1);
47
+ __webpack_require__(429);
48
+ __webpack_require__(540);
49
+ __webpack_require__(544);
 
50
  __webpack_require__(546);
51
+ __webpack_require__(549);
52
+ __webpack_require__(554);
53
+ __webpack_require__(555);
54
+ module.exports = __webpack_require__(559);
55
 
56
 
57
  /***/ },
467
 
468
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
469
 
470
+ !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(181), __webpack_require__(276), __webpack_require__(292), __webpack_require__(423)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, Router, MailPoet, Form, ReactStringReplace) {
471
  var fields = [{
472
  name: 'email',
473
  label: MailPoet.I18n.t('email'),
667
 
668
  /***/ },
669
 
670
+ /***/ 429:
671
  /***/ function(module, exports, __webpack_require__) {
672
 
673
  'use strict';
686
 
687
  var _history = __webpack_require__(244);
688
 
689
+ var _wpJsHooks = __webpack_require__(430);
690
 
691
  var _wpJsHooks2 = _interopRequireDefault(_wpJsHooks);
692
 
693
+ var _newslettersTypesJsx = __webpack_require__(432);
694
 
695
  var _newslettersTypesJsx2 = _interopRequireDefault(_newslettersTypesJsx);
696
 
697
+ var _newslettersTemplatesJsx = __webpack_require__(435);
698
 
699
  var _newslettersTemplatesJsx2 = _interopRequireDefault(_newslettersTemplatesJsx);
700
 
701
+ var _newslettersSendJsx = __webpack_require__(519);
702
 
703
  var _newslettersSendJsx2 = _interopRequireDefault(_newslettersSendJsx);
704
 
705
+ var _newslettersTypesStandardJsx = __webpack_require__(529);
706
 
707
  var _newslettersTypesStandardJsx2 = _interopRequireDefault(_newslettersTypesStandardJsx);
708
 
709
+ var _newslettersTypesNotificationNotificationJsx = __webpack_require__(530);
710
 
711
  var _newslettersTypesNotificationNotificationJsx2 = _interopRequireDefault(_newslettersTypesNotificationNotificationJsx);
712
 
713
+ var _newslettersListingsStandardJsx = __webpack_require__(531);
714
 
715
  var _newslettersListingsStandardJsx2 = _interopRequireDefault(_newslettersListingsStandardJsx);
716
 
717
+ var _newslettersListingsWelcomeJsx = __webpack_require__(537);
718
 
719
  var _newslettersListingsWelcomeJsx2 = _interopRequireDefault(_newslettersListingsWelcomeJsx);
720
 
721
+ var _newslettersListingsNotificationJsx = __webpack_require__(538);
722
 
723
  var _newslettersListingsNotificationJsx2 = _interopRequireDefault(_newslettersListingsNotificationJsx);
724
 
725
+ var _newslettersListingsNotification_historyJsx = __webpack_require__(539);
726
 
727
  var _newslettersListingsNotification_historyJsx2 = _interopRequireDefault(_newslettersListingsNotification_historyJsx);
728
 
771
 
772
  /***/ },
773
 
774
+ /***/ 432:
775
  /***/ function(module, exports, __webpack_require__) {
776
 
777
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
778
 
779
+ !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(276), __webpack_require__(430), __webpack_require__(181), __webpack_require__(433)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, MailPoet, Hooks, Router, Breadcrumb) {
780
  var NewsletterTypes = React.createClass({
781
  displayName: 'NewsletterTypes',
782
 
915
 
916
  /***/ },
917
 
918
+ /***/ 435:
919
  /***/ function(module, exports, __webpack_require__) {
920
 
921
  'use strict';
938
 
939
  var _mailpoet2 = _interopRequireDefault(_mailpoet);
940
 
941
+ var _reactConfirmAlert = __webpack_require__(436);
942
 
943
  var _classnames = __webpack_require__(277);
944
 
945
  var _classnames2 = _interopRequireDefault(_classnames);
946
 
947
+ var _newslettersBreadcrumbJsx = __webpack_require__(433);
948
 
949
  var _newslettersBreadcrumbJsx2 = _interopRequireDefault(_newslettersBreadcrumbJsx);
950
 
951
+ var _helpTooltipJsx = __webpack_require__(437);
952
 
953
  var _helpTooltipJsx2 = _interopRequireDefault(_helpTooltipJsx);
954
 
965
  template.body = JSON.stringify(template.body);
966
  }
967
 
968
+ if (undefined === template.categories) {
969
+ template.categories = '["saved"]';
970
+ }
971
  _mailpoet2['default'].Modal.loading(true);
972
 
973
  _mailpoet2['default'].Ajax.post({
1042
  }
1043
  });
1044
 
1045
+ var templatesCategories = [{
1046
+ name: 'standard',
1047
+ label: _mailpoet2['default'].I18n.t('tabStandardTitle')
1048
+ }, {
1049
+ name: 'welcome',
1050
+ label: _mailpoet2['default'].I18n.t('tabWelcomeTitle')
1051
+ }, {
1052
+ name: 'notification',
1053
+ label: _mailpoet2['default'].I18n.t('tabNotificationTitle')
1054
+ }, {
1055
+ name: 'sample',
1056
+ label: _mailpoet2['default'].I18n.t('sample')
1057
+ }, {
1058
+ name: 'blank',
1059
+ label: _mailpoet2['default'].I18n.t('blank')
1060
+ }, {
1061
+ name: 'recent',
1062
+ label: _mailpoet2['default'].I18n.t('recentlySent')
1063
+ }, {
1064
+ name: 'saved',
1065
+ label: _mailpoet2['default'].I18n.t('savedTemplates')
1066
+ }];
1067
+
1068
+ var CategoryTab = function CategoryTab(_ref) {
1069
+ var name = _ref.name;
1070
+ var label = _ref.label;
1071
+ var selected = _ref.selected;
1072
+ var select = _ref.select;
1073
+ return _react2['default'].createElement(
1074
+ 'li',
1075
+ null,
1076
+ _react2['default'].createElement(
1077
+ 'a',
1078
+ {
1079
+ href: 'javascript:',
1080
+ className: selected === name ? 'current' : '',
1081
+ onClick: function () {
1082
+ return select(name);
1083
+ }
1084
+ },
1085
+ ' ',
1086
+ label
1087
+ )
1088
+ );
1089
+ };
1090
+
1091
  var NewsletterTemplates = _react2['default'].createClass({
1092
  displayName: 'NewsletterTemplates',
1093
 
1094
  getInitialState: function getInitialState() {
1095
  return {
1096
  loading: false,
1097
+ templates: {},
1098
+ selectedCategory: ''
1099
  };
1100
  },
1101
  componentDidMount: function componentDidMount() {
1112
  api_version: window.mailpoet_api_version,
1113
  endpoint: 'newsletterTemplates',
1114
  action: 'getAll'
 
 
1115
  }).done(function (response) {
1116
  if (_this2.isMounted()) {
1117
  if (response.data.length === 0) {
1118
  response.data = [{
1119
  name: _mailpoet2['default'].I18n.t('mailpoetGuideTemplateTitle'),
1120
  description: _mailpoet2['default'].I18n.t('mailpoetGuideTemplateDescription'),
1121
+ categories: '["welcome", "notification", "standard"]',
1122
  readonly: '1'
1123
  }];
1124
  }
1125
+
1126
+ var templates = templatesCategories.reduce(function (result, _ref2) {
1127
+ var name = _ref2.name;
1128
+
1129
+ var obj = result;
1130
+ obj[name] = [];
1131
+ return obj;
1132
+ }, {});
1133
+
1134
+ templates = response.data.reduce(function (result, item) {
1135
+ JSON.parse(item.categories).forEach(function (category) {
1136
+ result[category].push(item);
1137
+ });
1138
+ return result;
1139
+ }, templates);
1140
+
1141
+ _this2.selectInitialCategory(templates);
1142
+ }
1143
+ }).fail(function (response) {
1144
+ if (response.errors.length > 0) {
1145
+ _mailpoet2['default'].Notice.error(response.errors.map(function (error) {
1146
+ return error.message;
1147
+ }), { scroll: true });
1148
+ }
1149
+ _mailpoet2['default'].Modal.loading(false);
1150
+ });
1151
+ },
1152
+ selectInitialCategory: function selectInitialCategory(templates) {
1153
+ var _this3 = this;
1154
+
1155
+ _mailpoet2['default'].Ajax.post({
1156
+ api_version: window.mailpoet_api_version,
1157
+ endpoint: 'newsletters',
1158
+ action: 'get',
1159
+ data: {
1160
+ id: this.props.params.id
1161
  }
1162
+ }).always(function () {
1163
+ _mailpoet2['default'].Modal.loading(false);
1164
+ }).done(function (response) {
1165
+ _this3.setState({
1166
+ templates: templates,
1167
+ selectedCategory: response.data.type,
1168
+ loading: false
1169
+ });
1170
  }).fail(function (response) {
1171
  if (response.errors.length > 0) {
1172
  _mailpoet2['default'].Notice.error(response.errors.map(function (error) {
1208
  });
1209
  },
1210
  handleDeleteTemplate: function handleDeleteTemplate(template) {
1211
+ var _this4 = this;
1212
 
1213
  this.setState({ loading: true });
1214
  var onConfirm = function onConfirm() {
1220
  id: template.id
1221
  }
1222
  }).done(function () {
1223
+ _this4.getTemplates();
1224
  }).fail(function (response) {
1225
  if (response.errors.length > 0) {
1226
  _mailpoet2['default'].Notice.error(response.errors.map(function (error) {
1230
  });
1231
  };
1232
  var onCancel = function onCancel() {
1233
+ _this4.setState({ loading: false });
1234
  };
1235
  (0, _reactConfirmAlert.confirmAlert)({
1236
  title: _mailpoet2['default'].I18n.t('confirmTitle'),
1252
  this.getTemplates();
1253
  },
1254
  render: function render() {
1255
+ var _this5 = this;
1256
 
1257
+ var templates = this.state.templates[this.state.selectedCategory] || [];
1258
+
1259
+ templates = templates.map(function (template, index) {
1260
  var deleteLink = _react2['default'].createElement(
1261
  'div',
1262
  { className: 'mailpoet_delete' },
1264
  'a',
1265
  {
1266
  href: 'javascript:;',
1267
+ onClick: _this5.handleDeleteTemplate.bind(null, template)
1268
  },
1269
  _mailpoet2['default'].I18n.t('delete')
1270
  )
1274
  if (typeof template.thumbnail === 'string' && template.thumbnail.length > 0) {
1275
  thumbnail = _react2['default'].createElement(
1276
  'a',
1277
+ { href: 'javascript:;', onClick: _this5.handleShowTemplate.bind(null, template) },
1278
  _react2['default'].createElement('img', { src: template.thumbnail }),
1279
  _react2['default'].createElement('div', { className: 'mailpoet_overlay' })
1280
  );
1309
  'a',
1310
  {
1311
  className: 'button button-secondary',
1312
+ onClick: _this5.handleShowTemplate.bind(null, template)
1313
  },
1314
  _mailpoet2['default'].I18n.t('preview')
1315
  ),
1319
  {
1320
  className: 'button button-primary',
1321
  'data-automation-id': 'select_template_' + index,
1322
+ onClick: _this5.handleSelectTemplate.bind(null, template)
1323
  },
1324
  _mailpoet2['default'].I18n.t('select')
1325
  )
1328
  );
1329
  });
1330
 
1331
+ if (templates.length === 0) {
1332
+ templates = _react2['default'].createElement(
1333
+ 'p',
1334
+ null,
1335
+ _mailpoet2['default'].I18n.t('noTemplates')
1336
+ );
1337
+ }
1338
+
1339
  var boxClasses = (0, _classnames2['default'])('mailpoet_boxes', 'clearfix', { mailpoet_boxes_loading: this.state.loading });
1340
 
1341
  return _react2['default'].createElement(
1347
  _mailpoet2['default'].I18n.t('selectTemplateTitle')
1348
  ),
1349
  _react2['default'].createElement(_newslettersBreadcrumbJsx2['default'], { step: 'template' }),
1350
+ _react2['default'].createElement(
1351
+ 'div',
1352
+ { className: 'wp-filter hide-if-no-js' },
1353
+ _react2['default'].createElement(
1354
+ 'ul',
1355
+ { className: 'filter-links' },
1356
+ templatesCategories.map(function (_ref3) {
1357
+ var name = _ref3.name;
1358
+ var label = _ref3.label;
1359
+ return _react2['default'].createElement(CategoryTab, {
1360
+ key: name,
1361
+ name: name,
1362
+ label: label,
1363
+ selected: _this5.state.selectedCategory,
1364
+ select: function (category) {
1365
+ return _this5.setState({ selectedCategory: category });
1366
+ } });
1367
+ })
1368
+ )
1369
+ ),
1370
  _react2['default'].createElement(
1371
  'ul',
1372
  { className: boxClasses },
1382
 
1383
  /***/ },
1384
 
1385
+ /***/ 436:
1386
  /***/ function(module, exports, __webpack_require__) {
1387
 
1388
  'use strict';
1559
 
1560
  /***/ },
1561
 
1562
+ /***/ 437:
1563
  /***/ function(module, exports, __webpack_require__) {
1564
 
1565
  'use strict';
1570
 
1571
  var _react2 = _interopRequireDefault(_react);
1572
 
1573
+ var _reactTooltip = __webpack_require__(438);
1574
 
1575
  var _reactTooltip2 = _interopRequireDefault(_reactTooltip);
1576
 
1577
+ var _reactHtmlParser = __webpack_require__(451);
1578
 
1579
  var _reactHtmlParser2 = _interopRequireDefault(_reactHtmlParser);
1580
 
1643
 
1644
  /***/ },
1645
 
1646
+ /***/ 451:
1647
  /***/ function(module, exports, __webpack_require__) {
1648
 
1649
  'use strict';
1652
  value: true
1653
  });
1654
 
1655
+ var _HtmlParser = __webpack_require__(452);
1656
 
1657
  var _HtmlParser2 = _interopRequireDefault(_HtmlParser);
1658
 
1662
 
1663
  /***/ },
1664
 
1665
+ /***/ 452:
1666
  /***/ function(module, exports, __webpack_require__) {
1667
 
1668
  'use strict';
1672
  });
1673
  exports.default = HtmlParser;
1674
 
1675
+ var _htmlparser = __webpack_require__(453);
1676
 
1677
  var _htmlparser2 = _interopRequireDefault(_htmlparser);
1678
 
1679
+ var _ProcessNodes = __webpack_require__(506);
1680
 
1681
  var _ProcessNodes2 = _interopRequireDefault(_ProcessNodes);
1682
 
1695
 
1696
  /***/ },
1697
 
1698
+ /***/ 453:
1699
  /***/ function(module, exports, __webpack_require__) {
1700
 
1701
+ var Parser = __webpack_require__(454),
1702
+ DomHandler = __webpack_require__(463);
1703
 
1704
  function defineProp(name, value){
1705
  delete module.exports[name];
1709
 
1710
  module.exports = {
1711
  Parser: Parser,
1712
+ Tokenizer: __webpack_require__(455),
1713
+ ElementType: __webpack_require__(464),
1714
  DomHandler: DomHandler,
1715
  get FeedHandler(){
1716
+ return defineProp("FeedHandler", __webpack_require__(467));
1717
  },
1718
  get Stream(){
1719
+ return defineProp("Stream", __webpack_require__(468));
1720
  },
1721
  get WritableStream(){
1722
+ return defineProp("WritableStream", __webpack_require__(469));
1723
  },
1724
  get ProxyHandler(){
1725
+ return defineProp("ProxyHandler", __webpack_require__(492));
1726
  },
1727
  get DomUtils(){
1728
+ return defineProp("DomUtils", __webpack_require__(493));
1729
  },
1730
  get CollectingHandler(){
1731
+ return defineProp("CollectingHandler", __webpack_require__(505));
1732
  },
1733
  // For legacy support
1734
  DefaultHandler: DomHandler,
1770
 
1771
  /***/ },
1772
 
1773
+ /***/ 454:
1774
  /***/ function(module, exports, __webpack_require__) {
1775
 
1776
+ var Tokenizer = __webpack_require__(455);
1777
 
1778
  /*
1779
  Options:
1895
  if(this._cbs.onparserinit) this._cbs.onparserinit(this);
1896
  }
1897
 
1898
+ __webpack_require__(461)(Parser, __webpack_require__(462).EventEmitter);
1899
 
1900
  Parser.prototype._updatePosition = function(initialOffset){
1901
  if(this.endIndex === null){
2130
 
2131
  /***/ },
2132
 
2133
+ /***/ 455:
2134
  /***/ function(module, exports, __webpack_require__) {
2135
 
2136
  module.exports = Tokenizer;
2137
 
2138
+ var decodeCodePoint = __webpack_require__(456),
2139
+ entityMap = __webpack_require__(458),
2140
+ legacyMap = __webpack_require__(459),
2141
+ xmlMap = __webpack_require__(460),
2142
 
2143
  i = 0,
2144
 
3043
 
3044
  /***/ },
3045
 
3046
+ /***/ 456:
3047
  /***/ function(module, exports, __webpack_require__) {
3048
 
3049
+ var decodeMap = __webpack_require__(457);
3050
 
3051
  module.exports = decodeCodePoint;
3052
 
3076
 
3077
  /***/ },
3078
 
3079
+ /***/ 457:
3080
  /***/ function(module, exports) {
3081
 
3082
  module.exports = {"0":65533,"128":8364,"130":8218,"131":402,"132":8222,"133":8230,"134":8224,"135":8225,"136":710,"137":8240,"138":352,"139":8249,"140":338,"142":381,"145":8216,"146":8217,"147":8220,"148":8221,"149":8226,"150":8211,"151":8212,"152":732,"153":8482,"154":353,"155":8250,"156":339,"158":382,"159":376}
3083
 
3084
  /***/ },
3085
 
3086
+ /***/ 458:
3087
  /***/ function(module, exports) {
3088
 
3089
  module.exports = {"Aacute":"Á","aacute":"á","Abreve":"Ă","abreve":"ă","ac":"∾","acd":"∿","acE":"∾̳","Acirc":"Â","acirc":"â","acute":"´","Acy":"А","acy":"а","AElig":"Æ","aelig":"æ","af":"⁡","Afr":"𝔄","afr":"𝔞","Agrave":"À","agrave":"à","alefsym":"ℵ","aleph":"ℵ","Alpha":"Α","alpha":"α","Amacr":"Ā","amacr":"ā","amalg":"⨿","amp":"&","AMP":"&","andand":"⩕","And":"⩓","and":"∧","andd":"⩜","andslope":"⩘","andv":"⩚","ang":"∠","ange":"⦤","angle":"∠","angmsdaa":"⦨","angmsdab":"⦩","angmsdac":"⦪","angmsdad":"⦫","angmsdae":"⦬","angmsdaf":"⦭","angmsdag":"⦮","angmsdah":"⦯","angmsd":"∡","angrt":"∟","angrtvb":"⊾","angrtvbd":"⦝","angsph":"∢","angst":"Å","angzarr":"⍼","Aogon":"Ą","aogon":"ą","Aopf":"𝔸","aopf":"𝕒","apacir":"⩯","ap":"≈","apE":"⩰","ape":"≊","apid":"≋","apos":"'","ApplyFunction":"⁡","approx":"≈","approxeq":"≊","Aring":"Å","aring":"å","Ascr":"𝒜","ascr":"𝒶","Assign":"≔","ast":"*","asymp":"≈","asympeq":"≍","Atilde":"Ã","atilde":"ã","Auml":"Ä","auml":"ä","awconint":"∳","awint":"⨑","backcong":"≌","backepsilon":"϶","backprime":"‵","backsim":"∽","backsimeq":"⋍","Backslash":"∖","Barv":"⫧","barvee":"⊽","barwed":"⌅","Barwed":"⌆","barwedge":"⌅","bbrk":"⎵","bbrktbrk":"⎶","bcong":"≌","Bcy":"Б","bcy":"б","bdquo":"„","becaus":"∵","because":"∵","Because":"∵","bemptyv":"⦰","bepsi":"϶","bernou":"ℬ","Bernoullis":"ℬ","Beta":"Β","beta":"β","beth":"ℶ","between":"≬","Bfr":"𝔅","bfr":"𝔟","bigcap":"⋂","bigcirc":"◯","bigcup":"⋃","bigodot":"⨀","bigoplus":"⨁","bigotimes":"⨂","bigsqcup":"⨆","bigstar":"★","bigtriangledown":"▽","bigtriangleup":"△","biguplus":"⨄","bigvee":"⋁","bigwedge":"⋀","bkarow":"⤍","blacklozenge":"⧫","blacksquare":"▪","blacktriangle":"▴","blacktriangledown":"▾","blacktriangleleft":"◂","blacktriangleright":"▸","blank":"␣","blk12":"▒","blk14":"░","blk34":"▓","block":"█","bne":"=⃥","bnequiv":"≡⃥","bNot":"⫭","bnot":"⌐","Bopf":"𝔹","bopf":"𝕓","bot":"⊥","bottom":"⊥","bowtie":"⋈","boxbox":"⧉","boxdl":"┐","boxdL":"╕","boxDl":"╖","boxDL":"╗","boxdr":"┌","boxdR":"╒","boxDr":"╓","boxDR":"╔","boxh":"─","boxH":"═","boxhd":"┬","boxHd":"╤","boxhD":"╥","boxHD":"╦","boxhu":"┴","boxHu":"╧","boxhU":"╨","boxHU":"╩","boxminus":"⊟","boxplus":"⊞","boxtimes":"⊠","boxul":"┘","boxuL":"╛","boxUl":"╜","boxUL":"╝","boxur":"└","boxuR":"╘","boxUr":"╙","boxUR":"╚","boxv":"│","boxV":"║","boxvh":"┼","boxvH":"╪","boxVh":"╫","boxVH":"╬","boxvl":"┤","boxvL":"╡","boxVl":"╢","boxVL":"╣","boxvr":"├","boxvR":"╞","boxVr":"╟","boxVR":"╠","bprime":"‵","breve":"˘","Breve":"˘","brvbar":"¦","bscr":"𝒷","Bscr":"ℬ","bsemi":"⁏","bsim":"∽","bsime":"⋍","bsolb":"⧅","bsol":"\\","bsolhsub":"⟈","bull":"•","bullet":"•","bump":"≎","bumpE":"⪮","bumpe":"≏","Bumpeq":"≎","bumpeq":"≏","Cacute":"Ć","cacute":"ć","capand":"⩄","capbrcup":"⩉","capcap":"⩋","cap":"∩","Cap":"⋒","capcup":"⩇","capdot":"⩀","CapitalDifferentialD":"ⅅ","caps":"∩︀","caret":"⁁","caron":"ˇ","Cayleys":"ℭ","ccaps":"⩍","Ccaron":"Č","ccaron":"č","Ccedil":"Ç","ccedil":"ç","Ccirc":"Ĉ","ccirc":"ĉ","Cconint":"∰","ccups":"⩌","ccupssm":"⩐","Cdot":"Ċ","cdot":"ċ","cedil":"¸","Cedilla":"¸","cemptyv":"⦲","cent":"¢","centerdot":"·","CenterDot":"·","cfr":"𝔠","Cfr":"ℭ","CHcy":"Ч","chcy":"ч","check":"✓","checkmark":"✓","Chi":"Χ","chi":"χ","circ":"ˆ","circeq":"≗","circlearrowleft":"↺","circlearrowright":"↻","circledast":"⊛","circledcirc":"⊚","circleddash":"⊝","CircleDot":"⊙","circledR":"®","circledS":"Ⓢ","CircleMinus":"⊖","CirclePlus":"⊕","CircleTimes":"⊗","cir":"○","cirE":"⧃","cire":"≗","cirfnint":"⨐","cirmid":"⫯","cirscir":"⧂","ClockwiseContourIntegral":"∲","CloseCurlyDoubleQuote":"”","CloseCurlyQuote":"’","clubs":"♣","clubsuit":"♣","colon":":","Colon":"∷","Colone":"⩴","colone":"≔","coloneq":"≔","comma":",","commat":"@","comp":"∁","compfn":"∘","complement":"∁","complexes":"ℂ","cong":"≅","congdot":"⩭","Congruent":"≡","conint":"∮","Conint":"∯","ContourIntegral":"∮","copf":"𝕔","Copf":"ℂ","coprod":"∐","Coproduct":"∐","copy":"©","COPY":"©","copysr":"℗","CounterClockwiseContourIntegral":"∳","crarr":"↵","cross":"✗","Cross":"⨯","Cscr":"𝒞","cscr":"𝒸","csub":"⫏","csube":"⫑","csup":"⫐","csupe":"⫒","ctdot":"⋯","cudarrl":"⤸","cudarrr":"⤵","cuepr":"⋞","cuesc":"⋟","cularr":"↶","cularrp":"⤽","cupbrcap":"⩈","cupcap":"⩆","CupCap":"≍","cup":"∪","Cup":"⋓","cupcup":"⩊","cupdot":"⊍","cupor":"⩅","cups":"∪︀","curarr":"↷","curarrm":"⤼","curlyeqprec":"⋞","curlyeqsucc":"⋟","curlyvee":"⋎","curlywedge":"⋏","curren":"¤","curvearrowleft":"↶","curvearrowright":"↷","cuvee":"⋎","cuwed":"⋏","cwconint":"∲","cwint":"∱","cylcty":"⌭","dagger":"†","Dagger":"‡","daleth":"ℸ","darr":"↓","Darr":"↡","dArr":"⇓","dash":"‐","Dashv":"⫤","dashv":"⊣","dbkarow":"⤏","dblac":"˝","Dcaron":"Ď","dcaron":"ď","Dcy":"Д","dcy":"д","ddagger":"‡","ddarr":"⇊","DD":"ⅅ","dd":"ⅆ","DDotrahd":"⤑","ddotseq":"⩷","deg":"°","Del":"∇","Delta":"Δ","delta":"δ","demptyv":"⦱","dfisht":"⥿","Dfr":"𝔇","dfr":"𝔡","dHar":"⥥","dharl":"⇃","dharr":"⇂","DiacriticalAcute":"´","DiacriticalDot":"˙","DiacriticalDoubleAcute":"˝","DiacriticalGrave":"`","DiacriticalTilde":"˜","diam":"⋄","diamond":"⋄","Diamond":"⋄","diamondsuit":"♦","diams":"♦","die":"¨","DifferentialD":"ⅆ","digamma":"ϝ","disin":"⋲","div":"÷","divide":"÷","divideontimes":"⋇","divonx":"⋇","DJcy":"Ђ","djcy":"ђ","dlcorn":"⌞","dlcrop":"⌍","dollar":"$","Dopf":"𝔻","dopf":"𝕕","Dot":"¨","dot":"˙","DotDot":"⃜","doteq":"≐","doteqdot":"≑","DotEqual":"≐","dotminus":"∸","dotplus":"∔","dotsquare":"⊡","doublebarwedge":"⌆","DoubleContourIntegral":"∯","DoubleDot":"¨","DoubleDownArrow":"⇓","DoubleLeftArrow":"⇐","DoubleLeftRightArrow":"⇔","DoubleLeftTee":"⫤","DoubleLongLeftArrow":"⟸","DoubleLongLeftRightArrow":"⟺","DoubleLongRightArrow":"⟹","DoubleRightArrow":"⇒","DoubleRightTee":"⊨","DoubleUpArrow":"⇑","DoubleUpDownArrow":"⇕","DoubleVerticalBar":"∥","DownArrowBar":"⤓","downarrow":"↓","DownArrow":"↓","Downarrow":"⇓","DownArrowUpArrow":"⇵","DownBreve":"̑","downdownarrows":"⇊","downharpoonleft":"⇃","downharpoonright":"⇂","DownLeftRightVector":"⥐","DownLeftTeeVector":"⥞","DownLeftVectorBar":"⥖","DownLeftVector":"↽","DownRightTeeVector":"⥟","DownRightVectorBar":"⥗","DownRightVector":"⇁","DownTeeArrow":"↧","DownTee":"⊤","drbkarow":"⤐","drcorn":"⌟","drcrop":"⌌","Dscr":"𝒟","dscr":"𝒹","DScy":"Ѕ","dscy":"ѕ","dsol":"⧶","Dstrok":"Đ","dstrok":"đ","dtdot":"⋱","dtri":"▿","dtrif":"▾","duarr":"⇵","duhar":"⥯","dwangle":"⦦","DZcy":"Џ","dzcy":"џ","dzigrarr":"⟿","Eacute":"É","eacute":"é","easter":"⩮","Ecaron":"Ě","ecaron":"ě","Ecirc":"Ê","ecirc":"ê","ecir":"≖","ecolon":"≕","Ecy":"Э","ecy":"э","eDDot":"⩷","Edot":"Ė","edot":"ė","eDot":"≑","ee":"ⅇ","efDot":"≒","Efr":"𝔈","efr":"𝔢","eg":"⪚","Egrave":"È","egrave":"è","egs":"⪖","egsdot":"⪘","el":"⪙","Element":"∈","elinters":"⏧","ell":"ℓ","els":"⪕","elsdot":"⪗","Emacr":"Ē","emacr":"ē","empty":"∅","emptyset":"∅","EmptySmallSquare":"◻","emptyv":"∅","EmptyVerySmallSquare":"▫","emsp13":" ","emsp14":" ","emsp":" ","ENG":"Ŋ","eng":"ŋ","ensp":" ","Eogon":"Ę","eogon":"ę","Eopf":"𝔼","eopf":"𝕖","epar":"⋕","eparsl":"⧣","eplus":"⩱","epsi":"ε","Epsilon":"Ε","epsilon":"ε","epsiv":"ϵ","eqcirc":"≖","eqcolon":"≕","eqsim":"≂","eqslantgtr":"⪖","eqslantless":"⪕","Equal":"⩵","equals":"=","EqualTilde":"≂","equest":"≟","Equilibrium":"⇌","equiv":"≡","equivDD":"⩸","eqvparsl":"⧥","erarr":"⥱","erDot":"≓","escr":"ℯ","Escr":"ℰ","esdot":"≐","Esim":"⩳","esim":"≂","Eta":"Η","eta":"η","ETH":"Ð","eth":"ð","Euml":"Ë","euml":"ë","euro":"€","excl":"!","exist":"∃","Exists":"∃","expectation":"ℰ","exponentiale":"ⅇ","ExponentialE":"ⅇ","fallingdotseq":"≒","Fcy":"Ф","fcy":"ф","female":"♀","ffilig":"ffi","fflig":"ff","ffllig":"ffl","Ffr":"𝔉","ffr":"𝔣","filig":"fi","FilledSmallSquare":"◼","FilledVerySmallSquare":"▪","fjlig":"fj","flat":"♭","fllig":"fl","fltns":"▱","fnof":"ƒ","Fopf":"𝔽","fopf":"𝕗","forall":"∀","ForAll":"∀","fork":"⋔","forkv":"⫙","Fouriertrf":"ℱ","fpartint":"⨍","frac12":"½","frac13":"⅓","frac14":"¼","frac15":"⅕","frac16":"⅙","frac18":"⅛","frac23":"⅔","frac25":"⅖","frac34":"¾","frac35":"⅗","frac38":"⅜","frac45":"⅘","frac56":"⅚","frac58":"⅝","frac78":"⅞","frasl":"⁄","frown":"⌢","fscr":"𝒻","Fscr":"ℱ","gacute":"ǵ","Gamma":"Γ","gamma":"γ","Gammad":"Ϝ","gammad":"ϝ","gap":"⪆","Gbreve":"Ğ","gbreve":"ğ","Gcedil":"Ģ","Gcirc":"Ĝ","gcirc":"ĝ","Gcy":"Г","gcy":"г","Gdot":"Ġ","gdot":"ġ","ge":"≥","gE":"≧","gEl":"⪌","gel":"⋛","geq":"≥","geqq":"≧","geqslant":"⩾","gescc":"⪩","ges":"⩾","gesdot":"⪀","gesdoto":"⪂","gesdotol":"⪄","gesl":"⋛︀","gesles":"⪔","Gfr":"𝔊","gfr":"𝔤","gg":"≫","Gg":"⋙","ggg":"⋙","gimel":"ℷ","GJcy":"Ѓ","gjcy":"ѓ","gla":"⪥","gl":"≷","glE":"⪒","glj":"⪤","gnap":"⪊","gnapprox":"⪊","gne":"⪈","gnE":"≩","gneq":"⪈","gneqq":"≩","gnsim":"⋧","Gopf":"𝔾","gopf":"𝕘","grave":"`","GreaterEqual":"≥","GreaterEqualLess":"⋛","GreaterFullEqual":"≧","GreaterGreater":"⪢","GreaterLess":"≷","GreaterSlantEqual":"⩾","GreaterTilde":"≳","Gscr":"𝒢","gscr":"ℊ","gsim":"≳","gsime":"⪎","gsiml":"⪐","gtcc":"⪧","gtcir":"⩺","gt":">","GT":">","Gt":"≫","gtdot":"⋗","gtlPar":"⦕","gtquest":"⩼","gtrapprox":"⪆","gtrarr":"⥸","gtrdot":"⋗","gtreqless":"⋛","gtreqqless":"⪌","gtrless":"≷","gtrsim":"≳","gvertneqq":"≩︀","gvnE":"≩︀","Hacek":"ˇ","hairsp":" ","half":"½","hamilt":"ℋ","HARDcy":"Ъ","hardcy":"ъ","harrcir":"⥈","harr":"↔","hArr":"⇔","harrw":"↭","Hat":"^","hbar":"ℏ","Hcirc":"Ĥ","hcirc":"ĥ","hearts":"♥","heartsuit":"♥","hellip":"…","hercon":"⊹","hfr":"𝔥","Hfr":"ℌ","HilbertSpace":"ℋ","hksearow":"⤥","hkswarow":"⤦","hoarr":"⇿","homtht":"∻","hookleftarrow":"↩","hookrightarrow":"↪","hopf":"𝕙","Hopf":"ℍ","horbar":"―","HorizontalLine":"─","hscr":"𝒽","Hscr":"ℋ","hslash":"ℏ","Hstrok":"Ħ","hstrok":"ħ","HumpDownHump":"≎","HumpEqual":"≏","hybull":"⁃","hyphen":"‐","Iacute":"Í","iacute":"í","ic":"⁣","Icirc":"Î","icirc":"î","Icy":"И","icy":"и","Idot":"İ","IEcy":"Е","iecy":"е","iexcl":"¡","iff":"⇔","ifr":"𝔦","Ifr":"ℑ","Igrave":"Ì","igrave":"ì","ii":"ⅈ","iiiint":"⨌","iiint":"∭","iinfin":"⧜","iiota":"℩","IJlig":"IJ","ijlig":"ij","Imacr":"Ī","imacr":"ī","image":"ℑ","ImaginaryI":"ⅈ","imagline":"ℐ","imagpart":"ℑ","imath":"ı","Im":"ℑ","imof":"⊷","imped":"Ƶ","Implies":"⇒","incare":"℅","in":"∈","infin":"∞","infintie":"⧝","inodot":"ı","intcal":"⊺","int":"∫","Int":"∬","integers":"ℤ","Integral":"∫","intercal":"⊺","Intersection":"⋂","intlarhk":"⨗","intprod":"⨼","InvisibleComma":"⁣","InvisibleTimes":"⁢","IOcy":"Ё","iocy":"ё","Iogon":"Į","iogon":"į","Iopf":"𝕀","iopf":"𝕚","Iota":"Ι","iota":"ι","iprod":"⨼","iquest":"¿","iscr":"𝒾","Iscr":"ℐ","isin":"∈","isindot":"⋵","isinE":"⋹","isins":"⋴","isinsv":"⋳","isinv":"∈","it":"⁢","Itilde":"Ĩ","itilde":"ĩ","Iukcy":"І","iukcy":"і","Iuml":"Ï","iuml":"ï","Jcirc":"Ĵ","jcirc":"ĵ","Jcy":"Й","jcy":"й","Jfr":"𝔍","jfr":"𝔧","jmath":"ȷ","Jopf":"𝕁","jopf":"𝕛","Jscr":"𝒥","jscr":"𝒿","Jsercy":"Ј","jsercy":"ј","Jukcy":"Є","jukcy":"є","Kappa":"Κ","kappa":"κ","kappav":"ϰ","Kcedil":"Ķ","kcedil":"ķ","Kcy":"К","kcy":"к","Kfr":"𝔎","kfr":"𝔨","kgreen":"ĸ","KHcy":"Х","khcy":"х","KJcy":"Ќ","kjcy":"ќ","Kopf":"𝕂","kopf":"𝕜","Kscr":"𝒦","kscr":"𝓀","lAarr":"⇚","Lacute":"Ĺ","lacute":"ĺ","laemptyv":"⦴","lagran":"ℒ","Lambda":"Λ","lambda":"λ","lang":"⟨","Lang":"⟪","langd":"⦑","langle":"⟨","lap":"⪅","Laplacetrf":"ℒ","laquo":"«","larrb":"⇤","larrbfs":"⤟","larr":"←","Larr":"↞","lArr":"⇐","larrfs":"⤝","larrhk":"↩","larrlp":"↫","larrpl":"⤹","larrsim":"⥳","larrtl":"↢","latail":"⤙","lAtail":"⤛","lat":"⪫","late":"⪭","lates":"⪭︀","lbarr":"⤌","lBarr":"⤎","lbbrk":"❲","lbrace":"{","lbrack":"[","lbrke":"⦋","lbrksld":"⦏","lbrkslu":"⦍","Lcaron":"Ľ","lcaron":"ľ","Lcedil":"Ļ","lcedil":"ļ","lceil":"⌈","lcub":"{","Lcy":"Л","lcy":"л","ldca":"⤶","ldquo":"“","ldquor":"„","ldrdhar":"⥧","ldrushar":"⥋","ldsh":"↲","le":"≤","lE":"≦","LeftAngleBracket":"⟨","LeftArrowBar":"⇤","leftarrow":"←","LeftArrow":"←","Leftarrow":"⇐","LeftArrowRightArrow":"⇆","leftarrowtail":"↢","LeftCeiling":"⌈","LeftDoubleBracket":"⟦","LeftDownTeeVector":"⥡","LeftDownVectorBar":"⥙","LeftDownVector":"⇃","LeftFloor":"⌊","leftharpoondown":"↽","leftharpoonup":"↼","leftleftarrows":"⇇","leftrightarrow":"↔","LeftRightArrow":"↔","Leftrightarrow":"⇔","leftrightarrows":"⇆","leftrightharpoons":"⇋","leftrightsquigarrow":"↭","LeftRightVector":"⥎","LeftTeeArrow":"↤","LeftTee":"⊣","LeftTeeVector":"⥚","leftthreetimes":"⋋","LeftTriangleBar":"⧏","LeftTriangle":"⊲","LeftTriangleEqual":"⊴","LeftUpDownVector":"⥑","LeftUpTeeVector":"⥠","LeftUpVectorBar":"⥘","LeftUpVector":"↿","LeftVectorBar":"⥒","LeftVector":"↼","lEg":"⪋","leg":"⋚","leq":"≤","leqq":"≦","leqslant":"⩽","lescc":"⪨","les":"⩽","lesdot":"⩿","lesdoto":"⪁","lesdotor":"⪃","lesg":"⋚︀","lesges":"⪓","lessapprox":"⪅","lessdot":"⋖","lesseqgtr":"⋚","lesseqqgtr":"⪋","LessEqualGreater":"⋚","LessFullEqual":"≦","LessGreater":"≶","lessgtr":"≶","LessLess":"⪡","lesssim":"≲","LessSlantEqual":"⩽","LessTilde":"≲","lfisht":"⥼","lfloor":"⌊","Lfr":"𝔏","lfr":"𝔩","lg":"≶","lgE":"⪑","lHar":"⥢","lhard":"↽","lharu":"↼","lharul":"⥪","lhblk":"▄","LJcy":"Љ","ljcy":"љ","llarr":"⇇","ll":"≪","Ll":"⋘","llcorner":"⌞","Lleftarrow":"⇚","llhard":"⥫","lltri":"◺","Lmidot":"Ŀ","lmidot":"ŀ","lmoustache":"⎰","lmoust":"⎰","lnap":"⪉","lnapprox":"⪉","lne":"⪇","lnE":"≨","lneq":"⪇","lneqq":"≨","lnsim":"⋦","loang":"⟬","loarr":"⇽","lobrk":"⟦","longleftarrow":"⟵","LongLeftArrow":"⟵","Longleftarrow":"⟸","longleftrightarrow":"⟷","LongLeftRightArrow":"⟷","Longleftrightarrow":"⟺","longmapsto":"⟼","longrightarrow":"⟶","LongRightArrow":"⟶","Longrightarrow":"⟹","looparrowleft":"↫","looparrowright":"↬","lopar":"⦅","Lopf":"𝕃","lopf":"𝕝","loplus":"⨭","lotimes":"⨴","lowast":"∗","lowbar":"_","LowerLeftArrow":"↙","LowerRightArrow":"↘","loz":"◊","lozenge":"◊","lozf":"⧫","lpar":"(","lparlt":"⦓","lrarr":"⇆","lrcorner":"⌟","lrhar":"⇋","lrhard":"⥭","lrm":"‎","lrtri":"⊿","lsaquo":"‹","lscr":"𝓁","Lscr":"ℒ","lsh":"↰","Lsh":"↰","lsim":"≲","lsime":"⪍","lsimg":"⪏","lsqb":"[","lsquo":"‘","lsquor":"‚","Lstrok":"Ł","lstrok":"ł","ltcc":"⪦","ltcir":"⩹","lt":"<","LT":"<","Lt":"≪","ltdot":"⋖","lthree":"⋋","ltimes":"⋉","ltlarr":"⥶","ltquest":"⩻","ltri":"◃","ltrie":"⊴","ltrif":"◂","ltrPar":"⦖","lurdshar":"⥊","luruhar":"⥦","lvertneqq":"≨︀","lvnE":"≨︀","macr":"¯","male":"♂","malt":"✠","maltese":"✠","Map":"⤅","map":"↦","mapsto":"↦","mapstodown":"↧","mapstoleft":"↤","mapstoup":"↥","marker":"▮","mcomma":"⨩","Mcy":"М","mcy":"м","mdash":"—","mDDot":"∺","measuredangle":"∡","MediumSpace":" ","Mellintrf":"ℳ","Mfr":"𝔐","mfr":"𝔪","mho":"℧","micro":"µ","midast":"*","midcir":"⫰","mid":"∣","middot":"·","minusb":"⊟","minus":"−","minusd":"∸","minusdu":"⨪","MinusPlus":"∓","mlcp":"⫛","mldr":"…","mnplus":"∓","models":"⊧","Mopf":"𝕄","mopf":"𝕞","mp":"∓","mscr":"𝓂","Mscr":"ℳ","mstpos":"∾","Mu":"Μ","mu":"μ","multimap":"⊸","mumap":"⊸","nabla":"∇","Nacute":"Ń","nacute":"ń","nang":"∠⃒","nap":"≉","napE":"⩰̸","napid":"≋̸","napos":"ʼn","napprox":"≉","natural":"♮","naturals":"ℕ","natur":"♮","nbsp":" ","nbump":"≎̸","nbumpe":"≏̸","ncap":"⩃","Ncaron":"Ň","ncaron":"ň","Ncedil":"Ņ","ncedil":"ņ","ncong":"≇","ncongdot":"⩭̸","ncup":"⩂","Ncy":"Н","ncy":"н","ndash":"–","nearhk":"⤤","nearr":"↗","neArr":"⇗","nearrow":"↗","ne":"≠","nedot":"≐̸","NegativeMediumSpace":"​","NegativeThickSpace":"​","NegativeThinSpace":"​","NegativeVeryThinSpace":"​","nequiv":"≢","nesear":"⤨","nesim":"≂̸","NestedGreaterGreater":"≫","NestedLessLess":"≪","NewLine":"\n","nexist":"∄","nexists":"∄","Nfr":"𝔑","nfr":"𝔫","ngE":"≧̸","nge":"≱","ngeq":"≱","ngeqq":"≧̸","ngeqslant":"⩾̸","nges":"⩾̸","nGg":"⋙̸","ngsim":"≵","nGt":"≫⃒","ngt":"≯","ngtr":"≯","nGtv":"≫̸","nharr":"↮","nhArr":"⇎","nhpar":"⫲","ni":"∋","nis":"⋼","nisd":"⋺","niv":"∋","NJcy":"Њ","njcy":"њ","nlarr":"↚","nlArr":"⇍","nldr":"‥","nlE":"≦̸","nle":"≰","nleftarrow":"↚","nLeftarrow":"⇍","nleftrightarrow":"↮","nLeftrightarrow":"⇎","nleq":"≰","nleqq":"≦̸","nleqslant":"⩽̸","nles":"⩽̸","nless":"≮","nLl":"⋘̸","nlsim":"≴","nLt":"≪⃒","nlt":"≮","nltri":"⋪","nltrie":"⋬","nLtv":"≪̸","nmid":"∤","NoBreak":"⁠","NonBreakingSpace":" ","nopf":"𝕟","Nopf":"ℕ","Not":"⫬","not":"¬","NotCongruent":"≢","NotCupCap":"≭","NotDoubleVerticalBar":"∦","NotElement":"∉","NotEqual":"≠","NotEqualTilde":"≂̸","NotExists":"∄","NotGreater":"≯","NotGreaterEqual":"≱","NotGreaterFullEqual":"≧̸","NotGreaterGreater":"≫̸","NotGreaterLess":"≹","NotGreaterSlantEqual":"⩾̸","NotGreaterTilde":"≵","NotHumpDownHump":"≎̸","NotHumpEqual":"≏̸","notin":"∉","notindot":"⋵̸","notinE":"⋹̸","notinva":"∉","notinvb":"⋷","notinvc":"⋶","NotLeftTriangleBar":"⧏̸","NotLeftTriangle":"⋪","NotLeftTriangleEqual":"⋬","NotLess":"≮","NotLessEqual":"≰","NotLessGreater":"≸","NotLessLess":"≪̸","NotLessSlantEqual":"⩽̸","NotLessTilde":"≴","NotNestedGreaterGreater":"⪢̸","NotNestedLessLess":"⪡̸","notni":"∌","notniva":"∌","notnivb":"⋾","notnivc":"⋽","NotPrecedes":"⊀","NotPrecedesEqual":"⪯̸","NotPrecedesSlantEqual":"⋠","NotReverseElement":"∌","NotRightTriangleBar":"⧐̸","NotRightTriangle":"⋫","NotRightTriangleEqual":"⋭","NotSquareSubset":"⊏̸","NotSquareSubsetEqual":"⋢","NotSquareSuperset":"⊐̸","NotSquareSupersetEqual":"⋣","NotSubset":"⊂⃒","NotSubsetEqual":"⊈","NotSucceeds":"⊁","NotSucceedsEqual":"⪰̸","NotSucceedsSlantEqual":"⋡","NotSucceedsTilde":"≿̸","NotSuperset":"⊃⃒","NotSupersetEqual":"⊉","NotTilde":"≁","NotTildeEqual":"≄","NotTildeFullEqual":"≇","NotTildeTilde":"≉","NotVerticalBar":"∤","nparallel":"∦","npar":"∦","nparsl":"⫽⃥","npart":"∂̸","npolint":"⨔","npr":"⊀","nprcue":"⋠","nprec":"⊀","npreceq":"⪯̸","npre":"⪯̸","nrarrc":"⤳̸","nrarr":"↛","nrArr":"⇏","nrarrw":"↝̸","nrightarrow":"↛","nRightarrow":"⇏","nrtri":"⋫","nrtrie":"⋭","nsc":"⊁","nsccue":"⋡","nsce":"⪰̸","Nscr":"𝒩","nscr":"𝓃","nshortmid":"∤","nshortparallel":"∦","nsim":"≁","nsime":"≄","nsimeq":"≄","nsmid":"∤","nspar":"∦","nsqsube":"⋢","nsqsupe":"⋣","nsub":"⊄","nsubE":"⫅̸","nsube":"⊈","nsubset":"⊂⃒","nsubseteq":"⊈","nsubseteqq":"⫅̸","nsucc":"⊁","nsucceq":"⪰̸","nsup":"⊅","nsupE":"⫆̸","nsupe":"⊉","nsupset":"⊃⃒","nsupseteq":"⊉","nsupseteqq":"⫆̸","ntgl":"≹","Ntilde":"Ñ","ntilde":"ñ","ntlg":"≸","ntriangleleft":"⋪","ntrianglelefteq":"⋬","ntriangleright":"⋫","ntrianglerighteq":"⋭","Nu":"Ν","nu":"ν","num":"#","numero":"№","numsp":" ","nvap":"≍⃒","nvdash":"⊬","nvDash":"⊭","nVdash":"⊮","nVDash":"⊯","nvge":"≥⃒","nvgt":">⃒","nvHarr":"⤄","nvinfin":"⧞","nvlArr":"⤂","nvle":"≤⃒","nvlt":"<⃒","nvltrie":"⊴⃒","nvrArr":"⤃","nvrtrie":"⊵⃒","nvsim":"∼⃒","nwarhk":"⤣","nwarr":"↖","nwArr":"⇖","nwarrow":"↖","nwnear":"⤧","Oacute":"Ó","oacute":"ó","oast":"⊛","Ocirc":"Ô","ocirc":"ô","ocir":"⊚","Ocy":"О","ocy":"о","odash":"⊝","Odblac":"Ő","odblac":"ő","odiv":"⨸","odot":"⊙","odsold":"⦼","OElig":"Œ","oelig":"œ","ofcir":"⦿","Ofr":"𝔒","ofr":"𝔬","ogon":"˛","Ograve":"Ò","ograve":"ò","ogt":"⧁","ohbar":"⦵","ohm":"Ω","oint":"∮","olarr":"↺","olcir":"⦾","olcross":"⦻","oline":"‾","olt":"⧀","Omacr":"Ō","omacr":"ō","Omega":"Ω","omega":"ω","Omicron":"Ο","omicron":"ο","omid":"⦶","ominus":"⊖","Oopf":"𝕆","oopf":"𝕠","opar":"⦷","OpenCurlyDoubleQuote":"“","OpenCurlyQuote":"‘","operp":"⦹","oplus":"⊕","orarr":"↻","Or":"⩔","or":"∨","ord":"⩝","order":"ℴ","orderof":"ℴ","ordf":"ª","ordm":"º","origof":"⊶","oror":"⩖","orslope":"⩗","orv":"⩛","oS":"Ⓢ","Oscr":"𝒪","oscr":"ℴ","Oslash":"Ø","oslash":"ø","osol":"⊘","Otilde":"Õ","otilde":"õ","otimesas":"⨶","Otimes":"⨷","otimes":"⊗","Ouml":"Ö","ouml":"ö","ovbar":"⌽","OverBar":"‾","OverBrace":"⏞","OverBracket":"⎴","OverParenthesis":"⏜","para":"¶","parallel":"∥","par":"∥","parsim":"⫳","parsl":"⫽","part":"∂","PartialD":"∂","Pcy":"П","pcy":"п","percnt":"%","period":".","permil":"‰","perp":"⊥","pertenk":"‱","Pfr":"𝔓","pfr":"𝔭","Phi":"Φ","phi":"φ","phiv":"ϕ","phmmat":"ℳ","phone":"☎","Pi":"Π","pi":"π","pitchfork":"⋔","piv":"ϖ","planck":"ℏ","planckh":"ℎ","plankv":"ℏ","plusacir":"⨣","plusb":"⊞","pluscir":"⨢","plus":"+","plusdo":"∔","plusdu":"⨥","pluse":"⩲","PlusMinus":"±","plusmn":"±","plussim":"⨦","plustwo":"⨧","pm":"±","Poincareplane":"ℌ","pointint":"⨕","popf":"𝕡","Popf":"ℙ","pound":"£","prap":"⪷","Pr":"⪻","pr":"≺","prcue":"≼","precapprox":"⪷","prec":"≺","preccurlyeq":"≼","Precedes":"≺","PrecedesEqual":"⪯","PrecedesSlantEqual":"≼","PrecedesTilde":"≾","preceq":"⪯","precnapprox":"⪹","precneqq":"⪵","precnsim":"⋨","pre":"⪯","prE":"⪳","precsim":"≾","prime":"′","Prime":"″","primes":"ℙ","prnap":"⪹","prnE":"⪵","prnsim":"⋨","prod":"∏","Product":"∏","profalar":"⌮","profline":"⌒","profsurf":"⌓","prop":"∝","Proportional":"∝","Proportion":"∷","propto":"∝","prsim":"≾","prurel":"⊰","Pscr":"𝒫","pscr":"𝓅","Psi":"Ψ","psi":"ψ","puncsp":" ","Qfr":"𝔔","qfr":"𝔮","qint":"⨌","qopf":"𝕢","Qopf":"ℚ","qprime":"⁗","Qscr":"𝒬","qscr":"𝓆","quaternions":"ℍ","quatint":"⨖","quest":"?","questeq":"≟","quot":"\"","QUOT":"\"","rAarr":"⇛","race":"∽̱","Racute":"Ŕ","racute":"ŕ","radic":"√","raemptyv":"⦳","rang":"⟩","Rang":"⟫","rangd":"⦒","range":"⦥","rangle":"⟩","raquo":"»","rarrap":"⥵","rarrb":"⇥","rarrbfs":"⤠","rarrc":"⤳","rarr":"→","Rarr":"↠","rArr":"⇒","rarrfs":"⤞","rarrhk":"↪","rarrlp":"↬","rarrpl":"⥅","rarrsim":"⥴","Rarrtl":"⤖","rarrtl":"↣","rarrw":"↝","ratail":"⤚","rAtail":"⤜","ratio":"∶","rationals":"ℚ","rbarr":"⤍","rBarr":"⤏","RBarr":"⤐","rbbrk":"❳","rbrace":"}","rbrack":"]","rbrke":"⦌","rbrksld":"⦎","rbrkslu":"⦐","Rcaron":"Ř","rcaron":"ř","Rcedil":"Ŗ","rcedil":"ŗ","rceil":"⌉","rcub":"}","Rcy":"Р","rcy":"р","rdca":"⤷","rdldhar":"⥩","rdquo":"”","rdquor":"”","rdsh":"↳","real":"ℜ","realine":"ℛ","realpart":"ℜ","reals":"ℝ","Re":"ℜ","rect":"▭","reg":"®","REG":"®","ReverseElement":"∋","ReverseEquilibrium":"⇋","ReverseUpEquilibrium":"⥯","rfisht":"⥽","rfloor":"⌋","rfr":"𝔯","Rfr":"ℜ","rHar":"⥤","rhard":"⇁","rharu":"⇀","rharul":"⥬","Rho":"Ρ","rho":"ρ","rhov":"ϱ","RightAngleBracket":"⟩","RightArrowBar":"⇥","rightarrow":"→","RightArrow":"→","Rightarrow":"⇒","RightArrowLeftArrow":"⇄","rightarrowtail":"↣","RightCeiling":"⌉","RightDoubleBracket":"⟧","RightDownTeeVector":"⥝","RightDownVectorBar":"⥕","RightDownVector":"⇂","RightFloor":"⌋","rightharpoondown":"⇁","rightharpoonup":"⇀","rightleftarrows":"⇄","rightleftharpoons":"⇌","rightrightarrows":"⇉","rightsquigarrow":"↝","RightTeeArrow":"↦","RightTee":"⊢","RightTeeVector":"⥛","rightthreetimes":"⋌","RightTriangleBar":"⧐","RightTriangle":"⊳","RightTriangleEqual":"⊵","RightUpDownVector":"⥏","RightUpTeeVector":"⥜","RightUpVectorBar":"⥔","RightUpVector":"↾","RightVectorBar":"⥓","RightVector":"⇀","ring":"˚","risingdotseq":"≓","rlarr":"⇄","rlhar":"⇌","rlm":"‏","rmoustache":"⎱","rmoust":"⎱","rnmid":"⫮","roang":"⟭","roarr":"⇾","robrk":"⟧","ropar":"⦆","ropf":"𝕣","Ropf":"ℝ","roplus":"⨮","rotimes":"⨵","RoundImplies":"⥰","rpar":")","rpargt":"⦔","rppolint":"⨒","rrarr":"⇉","Rrightarrow":"⇛","rsaquo":"›","rscr":"𝓇","Rscr":"ℛ","rsh":"↱","Rsh":"↱","rsqb":"]","rsquo":"’","rsquor":"’","rthree":"⋌","rtimes":"⋊","rtri":"▹","rtrie":"⊵","rtrif":"▸","rtriltri":"⧎","RuleDelayed":"⧴","ruluhar":"⥨","rx":"℞","Sacute":"Ś","sacute":"ś","sbquo":"‚","scap":"⪸","Scaron":"Š","scaron":"š","Sc":"⪼","sc":"≻","sccue":"≽","sce":"⪰","scE":"⪴","Scedil":"Ş","scedil":"ş","Scirc":"Ŝ","scirc":"ŝ","scnap":"⪺","scnE":"⪶","scnsim":"⋩","scpolint":"⨓","scsim":"≿","Scy":"С","scy":"с","sdotb":"⊡","sdot":"⋅","sdote":"⩦","searhk":"⤥","searr":"↘","seArr":"⇘","searrow":"↘","sect":"§","semi":";","seswar":"⤩","setminus":"∖","setmn":"∖","sext":"✶","Sfr":"𝔖","sfr":"𝔰","sfrown":"⌢","sharp":"♯","SHCHcy":"Щ","shchcy":"щ","SHcy":"Ш","shcy":"ш","ShortDownArrow":"↓","ShortLeftArrow":"←","shortmid":"∣","shortparallel":"∥","ShortRightArrow":"→","ShortUpArrow":"↑","shy":"­","Sigma":"Σ","sigma":"σ","sigmaf":"ς","sigmav":"ς","sim":"∼","simdot":"⩪","sime":"≃","simeq":"≃","simg":"⪞","simgE":"⪠","siml":"⪝","simlE":"⪟","simne":"≆","simplus":"⨤","simrarr":"⥲","slarr":"←","SmallCircle":"∘","smallsetminus":"∖","smashp":"⨳","smeparsl":"⧤","smid":"∣","smile":"⌣","smt":"⪪","smte":"⪬","smtes":"⪬︀","SOFTcy":"Ь","softcy":"ь","solbar":"⌿","solb":"⧄","sol":"/","Sopf":"𝕊","sopf":"𝕤","spades":"♠","spadesuit":"♠","spar":"∥","sqcap":"⊓","sqcaps":"⊓︀","sqcup":"⊔","sqcups":"⊔︀","Sqrt":"√","sqsub":"⊏","sqsube":"⊑","sqsubset":"⊏","sqsubseteq":"⊑","sqsup":"⊐","sqsupe":"⊒","sqsupset":"⊐","sqsupseteq":"⊒","square":"□","Square":"□","SquareIntersection":"⊓","SquareSubset":"⊏","SquareSubsetEqual":"⊑","SquareSuperset":"⊐","SquareSupersetEqual":"⊒","SquareUnion":"⊔","squarf":"▪","squ":"□","squf":"▪","srarr":"→","Sscr":"𝒮","sscr":"𝓈","ssetmn":"∖","ssmile":"⌣","sstarf":"⋆","Star":"⋆","star":"☆","starf":"★","straightepsilon":"ϵ","straightphi":"ϕ","strns":"¯","sub":"⊂","Sub":"⋐","subdot":"⪽","subE":"⫅","sube":"⊆","subedot":"⫃","submult":"⫁","subnE":"⫋","subne":"⊊","subplus":"⪿","subrarr":"⥹","subset":"⊂","Subset":"⋐","subseteq":"⊆","subseteqq":"⫅","SubsetEqual":"⊆","subsetneq":"⊊","subsetneqq":"⫋","subsim":"⫇","subsub":"⫕","subsup":"⫓","succapprox":"⪸","succ":"≻","succcurlyeq":"≽","Succeeds":"≻","SucceedsEqual":"⪰","SucceedsSlantEqual":"≽","SucceedsTilde":"≿","succeq":"⪰","succnapprox":"⪺","succneqq":"⪶","succnsim":"⋩","succsim":"≿","SuchThat":"∋","sum":"∑","Sum":"∑","sung":"♪","sup1":"¹","sup2":"²","sup3":"³","sup":"⊃","Sup":"⋑","supdot":"⪾","supdsub":"⫘","supE":"⫆","supe":"⊇","supedot":"⫄","Superset":"⊃","SupersetEqual":"⊇","suphsol":"⟉","suphsub":"⫗","suplarr":"⥻","supmult":"⫂","supnE":"⫌","supne":"⊋","supplus":"⫀","supset":"⊃","Supset":"⋑","supseteq":"⊇","supseteqq":"⫆","supsetneq":"⊋","supsetneqq":"⫌","supsim":"⫈","supsub":"⫔","supsup":"⫖","swarhk":"⤦","swarr":"↙","swArr":"⇙","swarrow":"↙","swnwar":"⤪","szlig":"ß","Tab":"\t","target":"⌖","Tau":"Τ","tau":"τ","tbrk":"⎴","Tcaron":"Ť","tcaron":"ť","Tcedil":"Ţ","tcedil":"ţ","Tcy":"Т","tcy":"т","tdot":"⃛","telrec":"⌕","Tfr":"𝔗","tfr":"𝔱","there4":"∴","therefore":"∴","Therefore":"∴","Theta":"Θ","theta":"θ","thetasym":"ϑ","thetav":"ϑ","thickapprox":"≈","thicksim":"∼","ThickSpace":"  ","ThinSpace":" ","thinsp":" ","thkap":"≈","thksim":"∼","THORN":"Þ","thorn":"þ","tilde":"˜","Tilde":"∼","TildeEqual":"≃","TildeFullEqual":"≅","TildeTilde":"≈","timesbar":"⨱","timesb":"⊠","times":"×","timesd":"⨰","tint":"∭","toea":"⤨","topbot":"⌶","topcir":"⫱","top":"⊤","Topf":"𝕋","topf":"𝕥","topfork":"⫚","tosa":"⤩","tprime":"‴","trade":"™","TRADE":"™","triangle":"▵","triangledown":"▿","triangleleft":"◃","trianglelefteq":"⊴","triangleq":"≜","triangleright":"▹","trianglerighteq":"⊵","tridot":"◬","trie":"≜","triminus":"⨺","TripleDot":"⃛","triplus":"⨹","trisb":"⧍","tritime":"⨻","trpezium":"⏢","Tscr":"𝒯","tscr":"𝓉","TScy":"Ц","tscy":"ц","TSHcy":"Ћ","tshcy":"ћ","Tstrok":"Ŧ","tstrok":"ŧ","twixt":"≬","twoheadleftarrow":"↞","twoheadrightarrow":"↠","Uacute":"Ú","uacute":"ú","uarr":"↑","Uarr":"↟","uArr":"⇑","Uarrocir":"⥉","Ubrcy":"Ў","ubrcy":"ў","Ubreve":"Ŭ","ubreve":"ŭ","Ucirc":"Û","ucirc":"û","Ucy":"У","ucy":"у","udarr":"⇅","Udblac":"Ű","udblac":"ű","udhar":"⥮","ufisht":"⥾","Ufr":"𝔘","ufr":"𝔲","Ugrave":"Ù","ugrave":"ù","uHar":"⥣","uharl":"↿","uharr":"↾","uhblk":"▀","ulcorn":"⌜","ulcorner":"⌜","ulcrop":"⌏","ultri":"◸","Umacr":"Ū","umacr":"ū","uml":"¨","UnderBar":"_","UnderBrace":"⏟","UnderBracket":"⎵","UnderParenthesis":"⏝","Union":"⋃","UnionPlus":"⊎","Uogon":"Ų","uogon":"ų","Uopf":"𝕌","uopf":"𝕦","UpArrowBar":"⤒","uparrow":"↑","UpArrow":"↑","Uparrow":"⇑","UpArrowDownArrow":"⇅","updownarrow":"↕","UpDownArrow":"↕","Updownarrow":"⇕","UpEquilibrium":"⥮","upharpoonleft":"↿","upharpoonright":"↾","uplus":"⊎","UpperLeftArrow":"↖","UpperRightArrow":"↗","upsi":"υ","Upsi":"ϒ","upsih":"ϒ","Upsilon":"Υ","upsilon":"υ","UpTeeArrow":"↥","UpTee":"⊥","upuparrows":"⇈","urcorn":"⌝","urcorner":"⌝","urcrop":"⌎","Uring":"Ů","uring":"ů","urtri":"◹","Uscr":"𝒰","uscr":"𝓊","utdot":"⋰","Utilde":"Ũ","utilde":"ũ","utri":"▵","utrif":"▴","uuarr":"⇈","Uuml":"Ü","uuml":"ü","uwangle":"⦧","vangrt":"⦜","varepsilon":"ϵ","varkappa":"ϰ","varnothing":"∅","varphi":"ϕ","varpi":"ϖ","varpropto":"∝","varr":"↕","vArr":"⇕","varrho":"ϱ","varsigma":"ς","varsubsetneq":"⊊︀","varsubsetneqq":"⫋︀","varsupsetneq":"⊋︀","varsupsetneqq":"⫌︀","vartheta":"ϑ","vartriangleleft":"⊲","vartriangleright":"⊳","vBar":"⫨","Vbar":"⫫","vBarv":"⫩","Vcy":"В","vcy":"в","vdash":"⊢","vDash":"⊨","Vdash":"⊩","VDash":"⊫","Vdashl":"⫦","veebar":"⊻","vee":"∨","Vee":"⋁","veeeq":"≚","vellip":"⋮","verbar":"|","Verbar":"‖","vert":"|","Vert":"‖","VerticalBar":"∣","VerticalLine":"|","VerticalSeparator":"❘","VerticalTilde":"≀","VeryThinSpace":" ","Vfr":"𝔙","vfr":"𝔳","vltri":"⊲","vnsub":"⊂⃒","vnsup":"⊃⃒","Vopf":"𝕍","vopf":"𝕧","vprop":"∝","vrtri":"⊳","Vscr":"𝒱","vscr":"𝓋","vsubnE":"⫋︀","vsubne":"⊊︀","vsupnE":"⫌︀","vsupne":"⊋︀","Vvdash":"⊪","vzigzag":"⦚","Wcirc":"Ŵ","wcirc":"ŵ","wedbar":"⩟","wedge":"∧","Wedge":"⋀","wedgeq":"≙","weierp":"℘","Wfr":"𝔚","wfr":"𝔴","Wopf":"𝕎","wopf":"𝕨","wp":"℘","wr":"≀","wreath":"≀","Wscr":"𝒲","wscr":"𝓌","xcap":"⋂","xcirc":"◯","xcup":"⋃","xdtri":"▽","Xfr":"𝔛","xfr":"𝔵","xharr":"⟷","xhArr":"⟺","Xi":"Ξ","xi":"ξ","xlarr":"⟵","xlArr":"⟸","xmap":"⟼","xnis":"⋻","xodot":"⨀","Xopf":"𝕏","xopf":"𝕩","xoplus":"⨁","xotime":"⨂","xrarr":"⟶","xrArr":"⟹","Xscr":"𝒳","xscr":"𝓍","xsqcup":"⨆","xuplus":"⨄","xutri":"△","xvee":"⋁","xwedge":"⋀","Yacute":"Ý","yacute":"ý","YAcy":"Я","yacy":"я","Ycirc":"Ŷ","ycirc":"ŷ","Ycy":"Ы","ycy":"ы","yen":"¥","Yfr":"𝔜","yfr":"𝔶","YIcy":"Ї","yicy":"ї","Yopf":"𝕐","yopf":"𝕪","Yscr":"𝒴","yscr":"𝓎","YUcy":"Ю","yucy":"ю","yuml":"ÿ","Yuml":"Ÿ","Zacute":"Ź","zacute":"ź","Zcaron":"Ž","zcaron":"ž","Zcy":"З","zcy":"з","Zdot":"Ż","zdot":"ż","zeetrf":"ℨ","ZeroWidthSpace":"​","Zeta":"Ζ","zeta":"ζ","zfr":"𝔷","Zfr":"ℨ","ZHcy":"Ж","zhcy":"ж","zigrarr":"⇝","zopf":"𝕫","Zopf":"ℤ","Zscr":"𝒵","zscr":"𝓏","zwj":"‍","zwnj":"‌"}
3090
 
3091
  /***/ },
3092
 
3093
+ /***/ 459:
3094
  /***/ function(module, exports) {
3095
 
3096
  module.exports = {"Aacute":"Á","aacute":"á","Acirc":"Â","acirc":"â","acute":"´","AElig":"Æ","aelig":"æ","Agrave":"À","agrave":"à","amp":"&","AMP":"&","Aring":"Å","aring":"å","Atilde":"Ã","atilde":"ã","Auml":"Ä","auml":"ä","brvbar":"¦","Ccedil":"Ç","ccedil":"ç","cedil":"¸","cent":"¢","copy":"©","COPY":"©","curren":"¤","deg":"°","divide":"÷","Eacute":"É","eacute":"é","Ecirc":"Ê","ecirc":"ê","Egrave":"È","egrave":"è","ETH":"Ð","eth":"ð","Euml":"Ë","euml":"ë","frac12":"½","frac14":"¼","frac34":"¾","gt":">","GT":">","Iacute":"Í","iacute":"í","Icirc":"Î","icirc":"î","iexcl":"¡","Igrave":"Ì","igrave":"ì","iquest":"¿","Iuml":"Ï","iuml":"ï","laquo":"«","lt":"<","LT":"<","macr":"¯","micro":"µ","middot":"·","nbsp":" ","not":"¬","Ntilde":"Ñ","ntilde":"ñ","Oacute":"Ó","oacute":"ó","Ocirc":"Ô","ocirc":"ô","Ograve":"Ò","ograve":"ò","ordf":"ª","ordm":"º","Oslash":"Ø","oslash":"ø","Otilde":"Õ","otilde":"õ","Ouml":"Ö","ouml":"ö","para":"¶","plusmn":"±","pound":"£","quot":"\"","QUOT":"\"","raquo":"»","reg":"®","REG":"®","sect":"§","shy":"­","sup1":"¹","sup2":"²","sup3":"³","szlig":"ß","THORN":"Þ","thorn":"þ","times":"×","Uacute":"Ú","uacute":"ú","Ucirc":"Û","ucirc":"û","Ugrave":"Ù","ugrave":"ù","uml":"¨","Uuml":"Ü","uuml":"ü","Yacute":"Ý","yacute":"ý","yen":"¥","yuml":"ÿ"}
3097
 
3098
  /***/ },
3099
 
3100
+ /***/ 460:
3101
  /***/ function(module, exports) {
3102
 
3103
  module.exports = {"amp":"&","apos":"'","gt":">","lt":"<","quot":"\""}
3104
 
3105
  /***/ },
3106
 
3107
+ /***/ 461:
3108
  /***/ function(module, exports) {
3109
 
3110
  if (typeof Object.create === 'function') {
3134
 
3135
  /***/ },
3136
 
3137
+ /***/ 462:
3138
  /***/ function(module, exports) {
3139
 
3140
  // Copyright Joyent, Inc. and other Node contributors.
3443
 
3444
  /***/ },
3445
 
3446
+ /***/ 463:
3447
  /***/ function(module, exports, __webpack_require__) {
3448
 
3449
+ var ElementType = __webpack_require__(464);
3450
 
3451
  var re_whitespace = /\s+/g;
3452
+ var NodePrototype = __webpack_require__(465);
3453
+ var ElementPrototype = __webpack_require__(466);
3454
 
3455
  function DomHandler(callback, options, elementCB){
3456
  if(typeof callback === "object"){
3667
 
3668
  /***/ },
3669
 
3670
+ /***/ 464:
3671
  /***/ function(module, exports) {
3672
 
3673
  //Types of elements found in the DOM
3689
 
3690
  /***/ },
3691
 
3692
+ /***/ 465:
3693
  /***/ function(module, exports) {
3694
 
3695
  // This object will be used as the prototype for Nodes when creating a
3740
 
3741
  /***/ },
3742
 
3743
+ /***/ 466:
3744
  /***/ function(module, exports, __webpack_require__) {
3745
 
3746
  // DOM-Level-1-compliant structure
3747
+ var NodePrototype = __webpack_require__(465);
3748
  var ElementPrototype = module.exports = Object.create(NodePrototype);
3749
 
3750
  var domLvl1 = {
3767
 
3768
  /***/ },
3769
 
3770
+ /***/ 467:
3771
  /***/ function(module, exports, __webpack_require__) {
3772
 
3773
+ var index = __webpack_require__(453),
3774
  DomHandler = index.DomHandler,
3775
  DomUtils = index.DomUtils;
3776
 
3779
  this.init(callback, options);
3780
  }
3781
 
3782
+ __webpack_require__(461)(FeedHandler, DomHandler);
3783
 
3784
  FeedHandler.prototype.init = DomHandler;
3785
 
3869
 
3870
  /***/ },
3871
 
3872
+ /***/ 468:
3873
  /***/ function(module, exports, __webpack_require__) {
3874
 
3875
  module.exports = Stream;
3876
 
3877
+ var Parser = __webpack_require__(469);
3878
 
3879
  function Stream(options){
3880
  Parser.call(this, new Cbs(this), options);
3881
  }
3882
 
3883
+ __webpack_require__(461)(Stream, Parser);
3884
 
3885
  Stream.prototype.readable = true;
3886
 
3888
  this.scope = scope;
3889
  }
3890
 
3891
+ var EVENTS = __webpack_require__(453).EVENTS;
3892
 
3893
  Object.keys(EVENTS).forEach(function(name){
3894
  if(EVENTS[name] === 0){
3910
 
3911
  /***/ },
3912
 
3913
+ /***/ 469:
3914
  /***/ function(module, exports, __webpack_require__) {
3915
 
3916
  module.exports = Stream;
3917
 
3918
+ var Parser = __webpack_require__(454),
3919
+ WritableStream = __webpack_require__(470).Writable || __webpack_require__(489).Writable,
3920
+ StringDecoder = __webpack_require__(490).StringDecoder,
3921
+ Buffer = __webpack_require__(474).Buffer;
3922
 
3923
  function Stream(cbs, options){
3924
  var parser = this._parser = new Parser(cbs, options);
3931
  });
3932
  }
3933
 
3934
+ __webpack_require__(461)(Stream, WritableStream);
3935
 
3936
  WritableStream.prototype._write = function(chunk, encoding, cb){
3937
  if(chunk instanceof Buffer) chunk = this._decoder.write(chunk);
3941
 
3942
  /***/ },
3943
 
3944
+ /***/ 470:
3945
  /***/ function(module, exports, __webpack_require__) {
3946
 
3947
  // Copyright Joyent, Inc. and other Node contributors.
3967
 
3968
  module.exports = Stream;
3969
 
3970
+ var EE = __webpack_require__(462).EventEmitter;
3971
+ var inherits = __webpack_require__(461);
3972
 
3973
  inherits(Stream, EE);
3974
+ Stream.Readable = __webpack_require__(471);
3975
+ Stream.Writable = __webpack_require__(485);
3976
+ Stream.Duplex = __webpack_require__(486);
3977
+ Stream.Transform = __webpack_require__(487);
3978
+ Stream.PassThrough = __webpack_require__(488);
3979
 
3980
  // Backwards-compat with node 0.4.x
3981
  Stream.Stream = Stream;
4075
 
4076
  /***/ },
4077
 
4078
+ /***/ 471:
4079
  /***/ function(module, exports, __webpack_require__) {
4080
 
4081
+ /* WEBPACK VAR INJECTION */(function(process) {exports = module.exports = __webpack_require__(472);
4082
+ exports.Stream = __webpack_require__(470);
4083
  exports.Readable = exports;
4084
+ exports.Writable = __webpack_require__(481);
4085
+ exports.Duplex = __webpack_require__(480);
4086
+ exports.Transform = __webpack_require__(483);
4087
+ exports.PassThrough = __webpack_require__(484);
4088
  if (!process.browser && process.env.READABLE_STREAM === 'disable') {
4089
+ module.exports = __webpack_require__(470);
4090
  }
4091
 
4092
  /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
4093
 
4094
  /***/ },
4095
 
4096
+ /***/ 472:
4097
  /***/ function(module, exports, __webpack_require__) {
4098
 
4099
  /* WEBPACK VAR INJECTION */(function(process) {// Copyright Joyent, Inc. and other Node contributors.
4120
  module.exports = Readable;
4121
 
4122
  /*<replacement>*/
4123
+ var isArray = __webpack_require__(473);
4124
  /*</replacement>*/
4125
 
4126
 
4127
  /*<replacement>*/
4128
+ var Buffer = __webpack_require__(474).Buffer;
4129
  /*</replacement>*/
4130
 
4131
  Readable.ReadableState = ReadableState;
4132
 
4133
+ var EE = __webpack_require__(462).EventEmitter;
4134
 
4135
  /*<replacement>*/
4136
  if (!EE.listenerCount) EE.listenerCount = function(emitter, type) {
4138
  };
4139
  /*</replacement>*/
4140
 
4141
+ var Stream = __webpack_require__(470);
4142
 
4143
  /*<replacement>*/
4144
+ var util = __webpack_require__(478);
4145
+ util.inherits = __webpack_require__(461);
4146
  /*</replacement>*/
4147
 
4148
  var StringDecoder;
4149
 
4150
 
4151
  /*<replacement>*/
4152
+ var debug = __webpack_require__(479);
4153
  if (debug && debug.debuglog) {
4154
  debug = debug.debuglog('stream');
4155
  } else {
4161
  util.inherits(Readable, Stream);
4162
 
4163
  function ReadableState(options, stream) {
4164
+ var Duplex = __webpack_require__(480);
4165
 
4166
  options = options || {};
4167
 
4222
  this.encoding = null;
4223
  if (options.encoding) {
4224
  if (!StringDecoder)
4225
+ StringDecoder = __webpack_require__(482).StringDecoder;
4226
  this.decoder = new StringDecoder(options.encoding);
4227
  this.encoding = options.encoding;
4228
  }
4229
  }
4230
 
4231
  function Readable(options) {
4232
+ var Duplex = __webpack_require__(480);
4233
 
4234
  if (!(this instanceof Readable))
4235
  return new Readable(options);
4332
  // backwards compatibility.
4333
  Readable.prototype.setEncoding = function(enc) {
4334
  if (!StringDecoder)
4335
+ StringDecoder = __webpack_require__(482).StringDecoder;
4336
  this._readableState.decoder = new StringDecoder(enc);
4337
  this._readableState.encoding = enc;
4338
  return this;
5052
 
5053
  /***/ },
5054
 
5055
+ /***/ 473:
5056
  /***/ function(module, exports) {
5057
 
5058
  module.exports = Array.isArray || function (arr) {
5062
 
5063
  /***/ },
5064
 
5065
+ /***/ 474:
5066
  /***/ function(module, exports, __webpack_require__) {
5067
 
5068
  /* WEBPACK VAR INJECTION */(function(Buffer, global) {/*!
5075
 
5076
  'use strict'
5077
 
5078
+ var base64 = __webpack_require__(475)
5079
+ var ieee754 = __webpack_require__(476)
5080
+ var isArray = __webpack_require__(477)
5081
 
5082
  exports.Buffer = Buffer
5083
  exports.SlowBuffer = SlowBuffer
6855
  return val !== val // eslint-disable-line no-self-compare
6856
  }
6857
 
6858
+ /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(474).Buffer, (function() { return this; }())))
6859
 
6860
  /***/ },
6861
 
6862
+ /***/ 475:
6863
  /***/ function(module, exports) {
6864
 
6865
  'use strict'
6980
 
6981
  /***/ },
6982
 
6983
+ /***/ 476:
6984
  /***/ function(module, exports) {
6985
 
6986
  exports.read = function (buffer, offset, isLE, mLen, nBytes) {
7071
 
7072
  /***/ },
7073
 
7074
+ /***/ 477:
7075
  /***/ function(module, exports) {
7076
 
7077
  var toString = {}.toString;
7083
 
7084
  /***/ },
7085
 
7086
+ /***/ 478:
7087
  /***/ function(module, exports, __webpack_require__) {
7088
 
7089
  /* WEBPACK VAR INJECTION */(function(Buffer) {// Copyright Joyent, Inc. and other Node contributors.
7194
  return Object.prototype.toString.call(o);
7195
  }
7196
 
7197
+ /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(474).Buffer))
7198
 
7199
  /***/ },
7200
 
7201
+ /***/ 479:
7202
  /***/ function(module, exports) {
7203
 
7204
  /* (ignored) */
7205
 
7206
  /***/ },
7207
 
7208
+ /***/ 480:
7209
  /***/ function(module, exports, __webpack_require__) {
7210
 
7211
  /* WEBPACK VAR INJECTION */(function(process) {// Copyright Joyent, Inc. and other Node contributors.
7246
 
7247
 
7248
  /*<replacement>*/
7249
+ var util = __webpack_require__(478);
7250
+ util.inherits = __webpack_require__(461);
7251
  /*</replacement>*/
7252
 
7253
+ var Readable = __webpack_require__(472);
7254
+ var Writable = __webpack_require__(481);
7255
 
7256
  util.inherits(Duplex, Readable);
7257
 
7302
 
7303
  /***/ },
7304
 
7305
+ /***/ 481:
7306
  /***/ function(module, exports, __webpack_require__) {
7307
 
7308
  /* WEBPACK VAR INJECTION */(function(process) {// Copyright Joyent, Inc. and other Node contributors.
7333
  module.exports = Writable;
7334
 
7335
  /*<replacement>*/
7336
+ var Buffer = __webpack_require__(474).Buffer;
7337
  /*</replacement>*/
7338
 
7339
  Writable.WritableState = WritableState;
7340
 
7341
 
7342
  /*<replacement>*/
7343
+ var util = __webpack_require__(478);
7344
+ util.inherits = __webpack_require__(461);
7345
  /*</replacement>*/
7346
 
7347
+ var Stream = __webpack_require__(470);
7348
 
7349
  util.inherits(Writable, Stream);
7350
 
7355
  }
7356
 
7357
  function WritableState(options, stream) {
7358
+ var Duplex = __webpack_require__(480);
7359
 
7360
  options = options || {};
7361
 
7443
  }
7444
 
7445
  function Writable(options) {
7446
+ var Duplex = __webpack_require__(480);
7447
 
7448
  // Writable ctor is applied to Duplexes, though they're not
7449
  // instanceof Writable, they're instanceof Readable.
7787
 
7788
  /***/ },
7789
 
7790
+ /***/ 482:
7791
  /***/ function(module, exports, __webpack_require__) {
7792
 
7793
  // Copyright Joyent, Inc. and other Node contributors.
7811
  // OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
7812
  // USE OR OTHER DEALINGS IN THE SOFTWARE.
7813
 
7814
+ var Buffer = __webpack_require__(474).Buffer;
7815
 
7816
  var isBufferEncoding = Buffer.isEncoding
7817
  || function(encoding) {
8015
 
8016
  /***/ },
8017
 
8018
+ /***/ 483:
8019
  /***/ function(module, exports, __webpack_require__) {
8020
 
8021
  // Copyright Joyent, Inc. and other Node contributors.
8084
 
8085
  module.exports = Transform;
8086
 
8087
+ var Duplex = __webpack_require__(480);
8088
 
8089
  /*<replacement>*/
8090
+ var util = __webpack_require__(478);
8091
+ util.inherits = __webpack_require__(461);
8092
  /*</replacement>*/
8093
 
8094
  util.inherits(Transform, Duplex);
8231
 
8232
  /***/ },
8233
 
8234
+ /***/ 484:
8235
  /***/ function(module, exports, __webpack_require__) {
8236
 
8237
  // Copyright Joyent, Inc. and other Node contributors.
8261
 
8262
  module.exports = PassThrough;
8263
 
8264
+ var Transform = __webpack_require__(483);
8265
 
8266
  /*<replacement>*/
8267
+ var util = __webpack_require__(478);
8268
+ util.inherits = __webpack_require__(461);
8269
  /*</replacement>*/
8270
 
8271
  util.inherits(PassThrough, Transform);
8284
 
8285
  /***/ },
8286
 
8287
+ /***/ 485:
8288
  /***/ function(module, exports, __webpack_require__) {
8289
 
8290
+ module.exports = __webpack_require__(481)
8291
 
8292
 
8293
  /***/ },
8294
 
8295
+ /***/ 486:
8296
  /***/ function(module, exports, __webpack_require__) {
8297
 
8298
+ module.exports = __webpack_require__(480)
8299
 
8300
 
8301
  /***/ },
8302
 
8303
+ /***/ 487:
8304
  /***/ function(module, exports, __webpack_require__) {
8305
 
8306
+ module.exports = __webpack_require__(483)
8307
 
8308
 
8309
  /***/ },
8310
 
8311
+ /***/ 488:
8312
  /***/ function(module, exports, __webpack_require__) {
8313
 
8314
+ module.exports = __webpack_require__(484)
8315
 
8316
 
8317
  /***/ },
8318
 
8319
+ /***/ 489:
8320
  /***/ function(module, exports) {
8321
 
8322
  /* (ignored) */
8323
 
8324
  /***/ },
8325
 
8326
+ /***/ 490:
8327
  /***/ function(module, exports, __webpack_require__) {
8328
 
8329
  'use strict';
8330
 
8331
+ var Buffer = __webpack_require__(491).Buffer;
8332
 
8333
  var isEncoding = Buffer.isEncoding || function (encoding) {
8334
  encoding = '' + encoding;
8601
 
8602
  /***/ },
8603
 
8604
+ /***/ 491:
8605
  /***/ function(module, exports, __webpack_require__) {
8606
 
8607
  /* eslint-disable node/no-deprecated-api */
8608
+ var buffer = __webpack_require__(474)
8609
  var Buffer = buffer.Buffer
8610
 
8611
  // alternative to using Object.keys for old browsers
8670
 
8671
  /***/ },
8672
 
8673
+ /***/ 492:
8674
  /***/ function(module, exports, __webpack_require__) {
8675
 
8676
  module.exports = ProxyHandler;
8679
  this._cbs = cbs || {};
8680
  }
8681
 
8682
+ var EVENTS = __webpack_require__(453).EVENTS;
8683
  Object.keys(EVENTS).forEach(function(name){
8684
  if(EVENTS[name] === 0){
8685
  name = "on" + name;
8703
 
8704
  /***/ },
8705
 
8706
+ /***/ 493:
8707
  /***/ function(module, exports, __webpack_require__) {
8708
 
8709
  var DomUtils = module.exports;
8710
 
8711
  [
8712
+ __webpack_require__(494),
 
8713
  __webpack_require__(500),
8714
  __webpack_require__(501),
8715
  __webpack_require__(502),
8716
+ __webpack_require__(503),
8717
+ __webpack_require__(504)
8718
  ].forEach(function(ext){
8719
  Object.keys(ext).forEach(function(key){
8720
  DomUtils[key] = ext[key].bind(DomUtils);
8724
 
8725
  /***/ },
8726
 
8727
+ /***/ 494:
8728
  /***/ function(module, exports, __webpack_require__) {
8729
 
8730
+ var ElementType = __webpack_require__(464),
8731
+ getOuterHTML = __webpack_require__(495),
8732
  isTag = ElementType.isTag;
8733
 
8734
  module.exports = {
8754
 
8755
  /***/ },
8756
 
8757
+ /***/ 495:
8758
  /***/ function(module, exports, __webpack_require__) {
8759
 
8760
  /*
8761
  Module dependencies
8762
  */
8763
+ var ElementType = __webpack_require__(496);
8764
+ var entities = __webpack_require__(497);
8765
 
8766
  /*
8767
  Boolean Attributes
8939
 
8940
  /***/ },
8941
 
8942
+ /***/ 496:
8943
+ /***/ function(module, exports) {
8944
+
8945
+ //Types of elements found in the DOM
8946
+ module.exports = {
8947
+ Text: "text", //Text
8948
+ Directive: "directive", //<? ... ?>
8949
+ Comment: "comment", //<!-- ... -->
8950
+ Script: "script", //<script> tags
8951
+ Style: "style", //<style> tags
8952
+ Tag: "tag", //Any tag
8953
+ CDATA: "cdata", //<![CDATA[ ... ]]>
8954
+
8955
+ isTag: function(elem){
8956
+ return elem.type === "tag" || elem.type === "script" || elem.type === "style";
8957
+ }
8958
+ };
8959
+
8960
+ /***/ },
8961
+
8962
  /***/ 1:
8963
  /***/ function(module, exports, __webpack_require__) {
8964
 
9015
 
9016
  /***/ },
9017
 
9018
+ /***/ 498:
9019
  /***/ function(module, exports, __webpack_require__) {
9020
 
9021
+ var inverseXML = getInverseObj(__webpack_require__(460)),
9022
+ xmlReplacer = getInverseReplacer(inverseXML);
 
 
 
 
9023
 
9024
+ exports.XML = getInverse(inverseXML, xmlReplacer);
 
 
9025
 
9026
+ var inverseHTML = getInverseObj(__webpack_require__(458)),
9027
+ htmlReplacer = getInverseReplacer(inverseHTML);
 
9028
 
9029
+ exports.HTML = getInverse(inverseHTML, htmlReplacer);
9030
 
9031
+ function getInverseObj(obj){
9032
+ return Object.keys(obj).sort().reduce(function(inverse, name){
9033
+ inverse[obj[name]] = "&" + name + ";";
9034
+ return inverse;
9035
+ }, {});
9036
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9037
 
9038
  function getInverseReplacer(inverse){
9039
  var single = [],
9095
 
9096
  /***/ },
9097
 
9098
+ /***/ 499:
9099
  /***/ function(module, exports, __webpack_require__) {
9100
 
9101
+ var entityMap = __webpack_require__(458),
9102
+ legacyMap = __webpack_require__(459),
9103
+ xmlMap = __webpack_require__(460),
9104
+ decodeCodePoint = __webpack_require__(456);
9105
 
9106
  var decodeXMLStrict = getStrictDecoder(xmlMap),
9107
  decodeHTMLStrict = getStrictDecoder(entityMap);
9173
 
9174
  /***/ },
9175
 
9176
+ /***/ 500:
9177
  /***/ function(module, exports) {
9178
 
9179
  var getChildren = exports.getChildren = function(elem){
9204
 
9205
  /***/ },
9206
 
9207
+ /***/ 501:
9208
  /***/ function(module, exports) {
9209
 
9210
  exports.removeElement = function(elem){
9288
 
9289
  /***/ },
9290
 
9291
+ /***/ 502:
9292
  /***/ function(module, exports, __webpack_require__) {
9293
 
9294
+ var isTag = __webpack_require__(464).isTag;
9295
 
9296
  module.exports = {
9297
  filter: filter,
9394
 
9395
  /***/ },
9396
 
9397
+ /***/ 503:
9398
  /***/ function(module, exports, __webpack_require__) {
9399
 
9400
+ var ElementType = __webpack_require__(464);
9401
  var isTag = exports.isTag = ElementType.isTag;
9402
 
9403
  exports.testElement = function(options, element){
9488
 
9489
  /***/ },
9490
 
9491
+ /***/ 504:
9492
  /***/ function(module, exports) {
9493
 
9494
  // removeSubsets
9636
 
9637
  /***/ },
9638
 
9639
+ /***/ 505:
9640
  /***/ function(module, exports, __webpack_require__) {
9641
 
9642
  module.exports = CollectingHandler;
9646
  this.events = [];
9647
  }
9648
 
9649
+ var EVENTS = __webpack_require__(453).EVENTS;
9650
  Object.keys(EVENTS).forEach(function(name){
9651
  if(EVENTS[name] === 0){
9652
  name = "on" + name;
9698
 
9699
  /***/ },
9700
 
9701
+ /***/ 506:
9702
  /***/ function(module, exports, __webpack_require__) {
9703
 
9704
  'use strict';
9708
  });
9709
  exports.default = ProcessNodes;
9710
 
9711
+ var _elementTypes = __webpack_require__(507);
9712
 
9713
  var _elementTypes2 = _interopRequireDefault(_elementTypes);
9714
 
9752
 
9753
  /***/ },
9754
 
9755
+ /***/ 507:
9756
  /***/ function(module, exports, __webpack_require__) {
9757
 
9758
  'use strict';
9763
 
9764
  var _ElementType$Text$Ele;
9765
 
9766
+ var _htmlparser = __webpack_require__(453);
9767
 
9768
+ var _TextElementType = __webpack_require__(508);
9769
 
9770
  var _TextElementType2 = _interopRequireDefault(_TextElementType);
9771
 
9772
+ var _TagElementType = __webpack_require__(509);
9773
 
9774
  var _TagElementType2 = _interopRequireDefault(_TagElementType);
9775
 
9776
+ var _StyleElementType = __webpack_require__(517);
9777
 
9778
  var _StyleElementType2 = _interopRequireDefault(_StyleElementType);
9779
 
9780
+ var _UnsupportedElementType = __webpack_require__(518);
9781
 
9782
  var _UnsupportedElementType2 = _interopRequireDefault(_UnsupportedElementType);
9783
 
9793
 
9794
  /***/ },
9795
 
9796
+ /***/ 508:
9797
  /***/ function(module, exports) {
9798
 
9799
  "use strict";
9816
 
9817
  /***/ },
9818
 
9819
+ /***/ 509:
9820
  /***/ function(module, exports, __webpack_require__) {
9821
 
9822
  'use strict';
9830
 
9831
  var _react2 = _interopRequireDefault(_react);
9832
 
9833
+ var _ProcessNodes = __webpack_require__(506);
9834
 
9835
  var _ProcessNodes2 = _interopRequireDefault(_ProcessNodes);
9836
 
9837
+ var _GeneratePropsFromAttributes = __webpack_require__(510);
9838
 
9839
  var _GeneratePropsFromAttributes2 = _interopRequireDefault(_GeneratePropsFromAttributes);
9840
 
9841
+ var _TransformTagName = __webpack_require__(515);
9842
 
9843
  var _TransformTagName2 = _interopRequireDefault(_TransformTagName);
9844
 
9845
+ var _VoidElements = __webpack_require__(516);
9846
 
9847
  var _VoidElements2 = _interopRequireDefault(_VoidElements);
9848
 
9875
 
9876
  /***/ },
9877
 
9878
+ /***/ 510:
9879
  /***/ function(module, exports, __webpack_require__) {
9880
 
9881
  'use strict';
9888
 
9889
  exports.default = GeneratePropsFromAttributes;
9890
 
9891
+ var _HtmlAttributesToReact = __webpack_require__(511);
9892
 
9893
  var _HtmlAttributesToReact2 = _interopRequireDefault(_HtmlAttributesToReact);
9894
 
9895
+ var _InlineStyleToObject = __webpack_require__(514);
9896
 
9897
  var _InlineStyleToObject2 = _interopRequireDefault(_InlineStyleToObject);
9898
 
9919
 
9920
  /***/ },
9921
 
9922
+ /***/ 511:
9923
  /***/ function(module, exports, __webpack_require__) {
9924
 
9925
  'use strict';
9929
  });
9930
  exports.default = HtmlAttributesToReact;
9931
 
9932
+ var _BooleanAttributes = __webpack_require__(512);
9933
 
9934
  var _BooleanAttributes2 = _interopRequireDefault(_BooleanAttributes);
9935
 
9936
+ var _ReactAttributes = __webpack_require__(513);
9937
 
9938
  var _ReactAttributes2 = _interopRequireDefault(_ReactAttributes);
9939
 
9986
 
9987
  /***/ },
9988
 
9989
+ /***/ 512:
9990
  /***/ function(module, exports) {
9991
 
9992
  'use strict';
10006
 
10007
  /***/ },
10008
 
10009
+ /***/ 513:
10010
  /***/ function(module, exports) {
10011
 
10012
  'use strict';
10175
 
10176
  /***/ },
10177
 
10178
+ /***/ 514:
10179
  /***/ function(module, exports) {
10180
 
10181
  'use strict';
10239
 
10240
  /***/ },
10241
 
10242
+ /***/ 515:
10243
  /***/ function(module, exports) {
10244
 
10245
  'use strict';
10270
 
10271
  /***/ },
10272
 
10273
+ /***/ 516:
10274
  /***/ function(module, exports) {
10275
 
10276
  'use strict';
10287
 
10288
  /***/ },
10289
 
10290
+ /***/ 517:
10291
  /***/ function(module, exports, __webpack_require__) {
10292
 
10293
  'use strict';
10301
 
10302
  var _react2 = _interopRequireDefault(_react);
10303
 
10304
+ var _GeneratePropsFromAttributes = __webpack_require__(510);
10305
 
10306
  var _GeneratePropsFromAttributes2 = _interopRequireDefault(_GeneratePropsFromAttributes);
10307
 
10332
 
10333
  /***/ },
10334
 
10335
+ /***/ 518:
10336
  /***/ function(module, exports) {
10337
 
10338
  "use strict";
10354
 
10355
  /***/ },
10356
 
10357
+ /***/ 519:
10358
  /***/ function(module, exports, __webpack_require__) {
10359
 
10360
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
10361
 
10362
  var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
10363
 
10364
+ !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(181), __webpack_require__(280), __webpack_require__(276), __webpack_require__(292), __webpack_require__(523), __webpack_require__(520), __webpack_require__(524), __webpack_require__(433), __webpack_require__(437), __webpack_require__(275), __webpack_require__(527)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, Router, _, MailPoet, Form, StandardNewsletterFields, NotificationNewsletterFields, WelcomeNewsletterFields, Breadcrumb, HelpTooltip, jQuery, html2canvas) {
10365
  var NewsletterSend = React.createClass({
10366
  displayName: 'NewsletterSend',
10367
 
10432
  });
10433
  });
10434
  },
10435
+ saveTemplate: function saveTemplate(response, done) {
10436
  var _this2 = this;
10437
 
10438
+ var iframe = document.createElement('iframe');
10439
+ iframe.src = response.meta.preview_url;
10440
+ iframe.onload = function () {
10441
+ html2canvas(iframe.contentDocument.documentElement).then(function (thumbnail) {
10442
+ document.body.removeChild(iframe);
10443
+ MailPoet.Ajax.post({
10444
+ api_version: window.mailpoet_api_version,
10445
+ endpoint: 'newsletterTemplates',
10446
+ action: 'save',
10447
+ data: {
10448
+ newsletter_id: response.data.id,
10449
+ name: response.data.subject,
10450
+ description: response.data.preheader,
10451
+ thumbnail: thumbnail.toDataURL('image/jpeg'),
10452
+ body: JSON.stringify(response.data.body),
10453
+ categories: '["recent"]'
10454
+ }
10455
+ }).then(done).fail(_this2.showError);
10456
+ });
10457
+ };
10458
+ // just to hide the iframe
10459
+ iframe.className = 'mailpoet_template_iframe';
10460
+ document.body.appendChild(iframe);
10461
+ },
10462
+ handleSend: function handleSend(e) {
10463
+ var _this3 = this;
10464
+
10465
  e.preventDefault();
10466
 
10467
  if (!this.isValid()) {
10468
  jQuery('#mailpoet_newsletter').parsley().validate();
10469
  } else {
10470
+ MailPoet.Modal.loading(true);
10471
  this.saveNewsletter(e).done(function () {
10472
+ _this3.setState({ loading: true });
10473
  }).done(function (response) {
10474
  switch (response.data.type) {
10475
  case 'notification':
10479
  endpoint: 'newsletters',
10480
  action: 'setStatus',
10481
  data: {
10482
+ id: _this3.props.params.id,
10483
  status: 'active'
10484
  }
10485
  }).done(function (response2) {
10486
+ // save template in recently sent category
10487
+ _this3.saveTemplate(response, function () {
10488
+ // redirect to listing based on newsletter type
10489
+ _this3.context.router.push('/' + (_this3.state.item.type || ''));
10490
+ var opts = _this3.state.item.options;
10491
+ // display success message depending on newsletter type
10492
+ if (response2.data.type === 'welcome') {
10493
+ MailPoet.Notice.success(MailPoet.I18n.t('welcomeEmailActivated'));
10494
+ MailPoet.trackEvent('Emails > Welcome email activated', {
10495
+ 'MailPoet Free version': window.mailpoet_version,
10496
+ 'List type': opts.event,
10497
+ Delay: opts.afterTimeNumber + ' ' + opts.afterTimeType
10498
+ });
10499
+ } else if (response2.data.type === 'notification') {
10500
+ MailPoet.Notice.success(MailPoet.I18n.t('postNotificationActivated'));
10501
+ MailPoet.trackEvent('Emails > Post notifications activated', {
10502
+ 'MailPoet Free version': window.mailpoet_version,
10503
+ Frequency: opts.intervalType
10504
+ });
10505
+ }
10506
+ MailPoet.Modal.loading(false);
10507
+ });
10508
+ }).fail(function (err) {
10509
+ _this3.showError(err);
10510
+ _this3.setState({ loading: false });
10511
+ MailPoet.Modal.loading(false);
10512
+ });
10513
  default:
10514
  return MailPoet.Ajax.post({
10515
  api_version: window.mailpoet_api_version,
10516
  endpoint: 'sendingQueue',
10517
  action: 'add',
10518
  data: {
10519
+ newsletter_id: _this3.props.params.id
10520
  }
10521
  }).done(function (response2) {
10522
+ // save template in recently sent category
10523
+ _this3.saveTemplate(response, function () {
10524
+ // redirect to listing based on newsletter type
10525
+ _this3.context.router.push('/' + (_this3.state.item.type || ''));
10526
+
10527
+ if (response2.data.status === 'scheduled') {
10528
+ MailPoet.Notice.success(MailPoet.I18n.t('newsletterHasBeenScheduled'));
10529
+ MailPoet.trackEvent('Emails > Newsletter sent', {
10530
+ scheduled: true,
10531
+ 'MailPoet Free version': window.mailpoet_version
10532
+ });
10533
+ } else {
10534
+ MailPoet.Notice.success(MailPoet.I18n.t('newsletterBeingSent'));
10535
+ MailPoet.trackEvent('Emails > Newsletter sent', {
10536
+ scheduled: false,
10537
+ 'MailPoet Free version': window.mailpoet_version
10538
+ });
10539
+ }
10540
+ MailPoet.Modal.loading(false);
10541
+ });
10542
+ }).fail(function (err) {
10543
+ _this3.showError(err);
10544
+ _this3.setState({ loading: false });
10545
+ MailPoet.Modal.loading(false);
10546
+ });
10547
  }
10548
+ }).fail(function (err) {
10549
+ _this3.showError(err);
10550
+ _this3.setState({ loading: false });
10551
+ MailPoet.Modal.loading(false);
10552
  });
10553
  }
10554
  return false;
10555
  },
10556
  handleResume: function handleResume(e) {
10557
+ var _this4 = this;
10558
 
10559
  e.preventDefault();
10560
  if (!this.isValid()) {
10561
  jQuery('#mailpoet_newsletter').parsley().validate();
10562
  } else {
10563
  this.saveNewsletter(e).done(function () {
10564
+ _this4.setState({ loading: true });
10565
  }).done(function () {
10566
  MailPoet.Ajax.post({
10567
  api_version: window.mailpoet_api_version,
10568
  endpoint: 'sendingQueue',
10569
  action: 'resume',
10570
  data: {
10571
+ newsletter_id: _this4.state.item.id
10572
  }
10573
  }).done(function () {
10574
+ _this4.context.router.push('/' + (_this4.state.item.type || ''));
10575
  MailPoet.Notice.success(MailPoet.I18n.t('newsletterSendingHasBeenResumed'));
10576
  }).fail(function (response) {
10577
  if (response.errors.length > 0) {
10581
  }
10582
  });
10583
  }).fail(this.showError).always(function () {
10584
+ _this4.setState({ loading: false });
10585
  });
10586
  }
10587
  return false;
10588
  },
10589
  handleSave: function handleSave(e) {
10590
+ var _this5 = this;
10591
 
10592
  e.preventDefault();
10593
 
10594
  this.saveNewsletter(e).done(function () {
10595
  MailPoet.Notice.success(MailPoet.I18n.t('newsletterUpdated'));
10596
  }).done(function () {
10597
+ _this5.context.router.push('/' + (_this5.state.item.type || ''));
10598
  }).fail(this.showError);
10599
  },
10600
  handleRedirectToDesign: function handleRedirectToDesign(e) {
10608
  }).fail(this.showError);
10609
  },
10610
  saveNewsletter: function saveNewsletter() {
10611
+ var _this6 = this;
10612
 
10613
  var data = this.state.item;
10614
  data.queue = undefined;
10624
  action: 'save',
10625
  data: newsletterData
10626
  }).always(function () {
10627
+ _this6.setState({ loading: false });
10628
  });
10629
  },
10630
  showError: function showError(response) {
10718
 
10719
  /***/ },
10720
 
10721
+ /***/ 520:
10722
  /***/ function(module, exports, __webpack_require__) {
10723
 
10724
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
10725
 
10726
+ !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(276), __webpack_require__(430), __webpack_require__(521), __webpack_require__(280)], __WEBPACK_AMD_DEFINE_RESULT__ = function (MailPoet, Hooks, Scheduling, _) {
10727
  var fields = [{
10728
  name: 'subject',
10729
  label: MailPoet.I18n.t('subjectLine'),
10818
 
10819
  /***/ },
10820
 
10821
+ /***/ 521:
10822
  /***/ function(module, exports, __webpack_require__) {
10823
 
10824
  'use strict';
10837
 
10838
  var _formFieldsSelectJsx2 = _interopRequireDefault(_formFieldsSelectJsx);
10839
 
10840
+ var _newslettersSchedulingCommonJsx = __webpack_require__(522);
10841
 
10842
  var intervalField = {
10843
  name: 'intervalType',
10952
 
10953
  /***/ },
10954
 
10955
+ /***/ 523:
10956
  /***/ function(module, exports, __webpack_require__) {
10957
 
10958
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
10961
 
10962
  var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
10963
 
10964
+ !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(275), __webpack_require__(280), __webpack_require__(276), __webpack_require__(430)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, jq, _, MailPoet, Hooks) {
10965
  var jQuery = jq;
10966
 
10967
  var currentTime = window.mailpoet_current_time || '00:00';
11316
  component: StandardScheduling
11317
  }];
11318
 
11319
+ fields = Hooks.applyFilters('mailpoet_newsletters_3rd_step_fields', fields);
11320
+
11321
+ return {
11322
+ getFields: function getFields() {
11323
+ return fields;
11324
+ },
11325
+ getSendButtonOptions: function getSendButtonOptions(newsletter) {
11326
+ var newsletterOptions = newsletter || {};
11327
+
11328
+ var isScheduled = typeof newsletterOptions.options === 'object' && newsletterOptions.options.isScheduled === '1';
11329
+ var options = {
11330
+ value: isScheduled ? MailPoet.I18n.t('schedule') : MailPoet.I18n.t('send')
11331
+ };
11332
+
11333
+ if (newsletterOptions.status === 'sent' || newsletterOptions.status === 'sending') {
11334
+ options.disabled = 'disabled';
11335
+ }
11336
+
11337
+ return options;
11338
+ }
11339
+ };
11340
+ }.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
11341
+
11342
+ /***/ },
11343
+
11344
+ /***/ 524:
11345
+ /***/ function(module, exports, __webpack_require__) {
11346
+
11347
+ var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
11348
+
11349
+ !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(276), __webpack_require__(430), __webpack_require__(525)], __WEBPACK_AMD_DEFINE_RESULT__ = function (MailPoet, Hooks, Scheduling) {
11350
+ var fields = [{
11351
+ name: 'subject',
11352
+ label: MailPoet.I18n.t('subjectLine'),
11353
+ tip: MailPoet.I18n.t('subjectLineTip'),
11354
+ type: 'text',
11355
+ validation: {
11356
+ 'data-parsley-required': true,
11357
+ 'data-parsley-required-message': MailPoet.I18n.t('emptySubjectLineError')
11358
+ }
11359
+ }, {
11360
+ name: 'options',
11361
+ label: MailPoet.I18n.t('sendWelcomeEmailWhen'),
11362
+ type: 'reactComponent',
11363
+ component: Scheduling
11364
+ }, {
11365
+ name: 'sender',
11366
+ label: MailPoet.I18n.t('sender'),
11367
+ tip: MailPoet.I18n.t('senderTip'),
11368
+ fields: [{
11369
+ name: 'sender_name',
11370
+ type: 'text',
11371
+ placeholder: MailPoet.I18n.t('senderNamePlaceholder'),
11372
+ validation: {
11373
+ 'data-parsley-required': true
11374
+ }
11375
+ }, {
11376
+ name: 'sender_address',
11377
+ type: 'text',
11378
+ placeholder: MailPoet.I18n.t('senderAddressPlaceholder'),
11379
+ validation: {
11380
+ 'data-parsley-required': true,
11381
+ 'data-parsley-type': 'email'
11382
+ }
11383
+ }]
11384
+ }, {
11385
+ name: 'reply-to',
11386
+ label: MailPoet.I18n.t('replyTo'),
11387
+ tip: MailPoet.I18n.t('replyToTip'),
11388
+ inline: true,
11389
+ fields: [{
11390
+ name: 'reply_to_name',
11391
+ type: 'text',
11392
+ placeholder: MailPoet.I18n.t('replyToNamePlaceholder')
11393
+ }, {
11394
+ name: 'reply_to_address',
11395
+ type: 'text',
11396
+ placeholder: MailPoet.I18n.t('replyToAddressPlaceholder')
11397
+ }]
11398
+ }];
11399
+
11400
+ fields = Hooks.applyFilters('mailpoet_newsletters_3rd_step_fields', fields);
11401
+
11402
+ return {
11403
+ getFields: function getFields() {
11404
+ return fields;
11405
+ },
11406
+ getSendButtonOptions: function getSendButtonOptions() {
11407
+ return {
11408
+ value: MailPoet.I18n.t('activate')
11409
+ };
11410
+ }
11411
+ };
11412
+ }.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
11413
+
11414
+ /***/ },
11415
+
11416
+ /***/ 527:
11417
+ /***/ function(module, exports, __webpack_require__) {
11418
+
11419
+ /* WEBPACK VAR INJECTION */(function(global) {module.exports = global["html2canvas"] = __webpack_require__(528);
11420
+ /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
11421
+
11422
+ /***/ },
11423
+
11424
+ /***/ 528:
11425
+ /***/ function(module, exports, __webpack_require__) {
11426
+
11427
+ var require;var require;/* WEBPACK VAR INJECTION */(function(global) {/*
11428
+ html2canvas 0.5.0-alpha2 <http://html2canvas.hertzen.com>
11429
+ Copyright (c) 2015 Niklas von Hertzen
11430
+
11431
+ Released under MIT License
11432
+ */
11433
+
11434
+ !function(e){if(true)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var f;"undefined"!=typeof window?f=window:"undefined"!=typeof global?f=global:"undefined"!=typeof self&&(f=self),f.html2canvas=e()}}(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return require(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
11435
+ (function (process,global){
11436
+ /*!
11437
+ * @overview es6-promise - a tiny implementation of Promises/A+.
11438
+ * @copyright Copyright (c) 2014 Yehuda Katz, Tom Dale, Stefan Penner and contributors (Conversion to ES6 API by Jake Archibald)
11439
+ * @license Licensed under MIT license
11440
+ * See https://raw.githubusercontent.com/jakearchibald/es6-promise/master/LICENSE
11441
+ * @version 2.0.1
11442
+ */
11443
+
11444
+ (function() {
11445
+ "use strict";
11446
+
11447
+ function $$utils$$objectOrFunction(x) {
11448
+ return typeof x === 'function' || (typeof x === 'object' && x !== null);
11449
+ }
11450
+
11451
+ function $$utils$$isFunction(x) {
11452
+ return typeof x === 'function';
11453
+ }
11454
+
11455
+ function $$utils$$isMaybeThenable(x) {
11456
+ return typeof x === 'object' && x !== null;
11457
+ }
11458
+
11459
+ var $$utils$$_isArray;
11460
+
11461
+ if (!Array.isArray) {
11462
+ $$utils$$_isArray = function (x) {
11463
+ return Object.prototype.toString.call(x) === '[object Array]';
11464
+ };
11465
+ } else {
11466
+ $$utils$$_isArray = Array.isArray;
11467
+ }
11468
+
11469
+ var $$utils$$isArray = $$utils$$_isArray;
11470
+ var $$utils$$now = Date.now || function() { return new Date().getTime(); };
11471
+ function $$utils$$F() { }
11472
+
11473
+ var $$utils$$o_create = (Object.create || function (o) {
11474
+ if (arguments.length > 1) {
11475
+ throw new Error('Second argument not supported');
11476
+ }
11477
+ if (typeof o !== 'object') {
11478
+ throw new TypeError('Argument must be an object');
11479
+ }
11480
+ $$utils$$F.prototype = o;
11481
+ return new $$utils$$F();
11482
+ });
11483
+
11484
+ var $$asap$$len = 0;
11485
+
11486
+ var $$asap$$default = function asap(callback, arg) {
11487
+ $$asap$$queue[$$asap$$len] = callback;
11488
+ $$asap$$queue[$$asap$$len + 1] = arg;
11489
+ $$asap$$len += 2;
11490
+ if ($$asap$$len === 2) {
11491
+ // If len is 1, that means that we need to schedule an async flush.
11492
+ // If additional callbacks are queued before the queue is flushed, they
11493
+ // will be processed by this flush that we are scheduling.
11494
+ $$asap$$scheduleFlush();
11495
+ }
11496
+ };
11497
+
11498
+ var $$asap$$browserGlobal = (typeof window !== 'undefined') ? window : {};
11499
+ var $$asap$$BrowserMutationObserver = $$asap$$browserGlobal.MutationObserver || $$asap$$browserGlobal.WebKitMutationObserver;
11500
+
11501
+ // test for web worker but not in IE10
11502
+ var $$asap$$isWorker = typeof Uint8ClampedArray !== 'undefined' &&
11503
+ typeof importScripts !== 'undefined' &&
11504
+ typeof MessageChannel !== 'undefined';
11505
+
11506
+ // node
11507
+ function $$asap$$useNextTick() {
11508
+ return function() {
11509
+ process.nextTick($$asap$$flush);
11510
+ };
11511
+ }
11512
+
11513
+ function $$asap$$useMutationObserver() {
11514
+ var iterations = 0;
11515
+ var observer = new $$asap$$BrowserMutationObserver($$asap$$flush);
11516
+ var node = document.createTextNode('');
11517
+ observer.observe(node, { characterData: true });
11518
+
11519
+ return function() {
11520
+ node.data = (iterations = ++iterations % 2);
11521
+ };
11522
+ }
11523
+
11524
+ // web worker
11525
+ function $$asap$$useMessageChannel() {
11526
+ var channel = new MessageChannel();
11527
+ channel.port1.onmessage = $$asap$$flush;
11528
+ return function () {
11529
+ channel.port2.postMessage(0);
11530
+ };
11531
+ }
11532
+
11533
+ function $$asap$$useSetTimeout() {
11534
+ return function() {
11535
+ setTimeout($$asap$$flush, 1);
11536
+ };
11537
+ }
11538
+
11539
+ var $$asap$$queue = new Array(1000);
11540
+
11541
+ function $$asap$$flush() {
11542
+ for (var i = 0; i < $$asap$$len; i+=2) {
11543
+ var callback = $$asap$$queue[i];
11544
+ var arg = $$asap$$queue[i+1];
11545
+
11546
+ callback(arg);
11547
+
11548
+ $$asap$$queue[i] = undefined;
11549
+ $$asap$$queue[i+1] = undefined;
11550
+ }
11551
+
11552
+ $$asap$$len = 0;
11553
+ }
11554
+
11555
+ var $$asap$$scheduleFlush;
11556
+
11557
+ // Decide what async method to use to triggering processing of queued callbacks:
11558
+ if (typeof process !== 'undefined' && {}.toString.call(process) === '[object process]') {
11559
+ $$asap$$scheduleFlush = $$asap$$useNextTick();
11560
+ } else if ($$asap$$BrowserMutationObserver) {
11561
+ $$asap$$scheduleFlush = $$asap$$useMutationObserver();
11562
+ } else if ($$asap$$isWorker) {
11563
+ $$asap$$scheduleFlush = $$asap$$useMessageChannel();
11564
+ } else {
11565
+ $$asap$$scheduleFlush = $$asap$$useSetTimeout();
11566
+ }
11567
+
11568
+ function $$$internal$$noop() {}
11569
+ var $$$internal$$PENDING = void 0;
11570
+ var $$$internal$$FULFILLED = 1;
11571
+ var $$$internal$$REJECTED = 2;
11572
+ var $$$internal$$GET_THEN_ERROR = new $$$internal$$ErrorObject();
11573
+
11574
+ function $$$internal$$selfFullfillment() {
11575
+ return new TypeError("You cannot resolve a promise with itself");
11576
+ }
11577
+
11578
+ function $$$internal$$cannotReturnOwn() {
11579
+ return new TypeError('A promises callback cannot return that same promise.')
11580
+ }
11581
+
11582
+ function $$$internal$$getThen(promise) {
11583
+ try {
11584
+ return promise.then;
11585
+ } catch(error) {
11586
+ $$$internal$$GET_THEN_ERROR.error = error;
11587
+ return $$$internal$$GET_THEN_ERROR;
11588
+ }
11589
+ }
11590
+
11591
+ function $$$internal$$tryThen(then, value, fulfillmentHandler, rejectionHandler) {
11592
+ try {
11593
+ then.call(value, fulfillmentHandler, rejectionHandler);
11594
+ } catch(e) {
11595
+ return e;
11596
+ }
11597
+ }
11598
+
11599
+ function $$$internal$$handleForeignThenable(promise, thenable, then) {
11600
+ $$asap$$default(function(promise) {
11601
+ var sealed = false;
11602
+ var error = $$$internal$$tryThen(then, thenable, function(value) {
11603
+ if (sealed) { return; }
11604
+ sealed = true;
11605
+ if (thenable !== value) {
11606
+ $$$internal$$resolve(promise, value);
11607
+ } else {
11608
+ $$$internal$$fulfill(promise, value);
11609
+ }
11610
+ }, function(reason) {
11611
+ if (sealed) { return; }
11612
+ sealed = true;
11613
+
11614
+ $$$internal$$reject(promise, reason);
11615
+ }, 'Settle: ' + (promise._label || ' unknown promise'));
11616
+
11617
+ if (!sealed && error) {
11618
+ sealed = true;
11619
+ $$$internal$$reject(promise, error);
11620
+ }
11621
+ }, promise);
11622
+ }
11623
+
11624
+ function $$$internal$$handleOwnThenable(promise, thenable) {
11625
+ if (thenable._state === $$$internal$$FULFILLED) {
11626
+ $$$internal$$fulfill(promise, thenable._result);
11627
+ } else if (promise._state === $$$internal$$REJECTED) {
11628
+ $$$internal$$reject(promise, thenable._result);
11629
+ } else {
11630
+ $$$internal$$subscribe(thenable, undefined, function(value) {
11631
+ $$$internal$$resolve(promise, value);
11632
+ }, function(reason) {
11633
+ $$$internal$$reject(promise, reason);
11634
+ });
11635
+ }
11636
+ }
11637
+
11638
+ function $$$internal$$handleMaybeThenable(promise, maybeThenable) {
11639
+ if (maybeThenable.constructor === promise.constructor) {
11640
+ $$$internal$$handleOwnThenable(promise, maybeThenable);
11641
+ } else {
11642
+ var then = $$$internal$$getThen(maybeThenable);
11643
+
11644
+ if (then === $$$internal$$GET_THEN_ERROR) {
11645
+ $$$internal$$reject(promise, $$$internal$$GET_THEN_ERROR.error);
11646
+ } else if (then === undefined) {
11647
+ $$$internal$$fulfill(promise, maybeThenable);
11648
+ } else if ($$utils$$isFunction(then)) {
11649
+ $$$internal$$handleForeignThenable(promise, maybeThenable, then);
11650
+ } else {
11651
+ $$$internal$$fulfill(promise, maybeThenable);
11652
+ }
11653
+ }
11654
+ }
11655
+
11656
+ function $$$internal$$resolve(promise, value) {
11657
+ if (promise === value) {
11658
+ $$$internal$$reject(promise, $$$internal$$selfFullfillment());
11659
+ } else if ($$utils$$objectOrFunction(value)) {
11660
+ $$$internal$$handleMaybeThenable(promise, value);
11661
+ } else {
11662
+ $$$internal$$fulfill(promise, value);
11663
+ }
11664
+ }
11665
+
11666
+ function $$$internal$$publishRejection(promise) {
11667
+ if (promise._onerror) {
11668
+ promise._onerror(promise._result);
11669
+ }
11670
+
11671
+ $$$internal$$publish(promise);
11672
+ }
11673
+
11674
+ function $$$internal$$fulfill(promise, value) {
11675
+ if (promise._state !== $$$internal$$PENDING) { return; }
11676
+
11677
+ promise._result = value;
11678
+ promise._state = $$$internal$$FULFILLED;
11679
+
11680
+ if (promise._subscribers.length === 0) {
11681
+ } else {
11682
+ $$asap$$default($$$internal$$publish, promise);
11683
+ }
11684
+ }
11685
+
11686
+ function $$$internal$$reject(promise, reason) {
11687
+ if (promise._state !== $$$internal$$PENDING) { return; }
11688
+ promise._state = $$$internal$$REJECTED;
11689
+ promise._result = reason;
11690
+
11691
+ $$asap$$default($$$internal$$publishRejection, promise);
11692
+ }
11693
+
11694
+ function $$$internal$$subscribe(parent, child, onFulfillment, onRejection) {
11695
+ var subscribers = parent._subscribers;
11696
+ var length = subscribers.length;
11697
+
11698
+ parent._onerror = null;
11699
+
11700
+ subscribers[length] = child;
11701
+ subscribers[length + $$$internal$$FULFILLED] = onFulfillment;
11702
+ subscribers[length + $$$internal$$REJECTED] = onRejection;
11703
+
11704
+ if (length === 0 && parent._state) {
11705
+ $$asap$$default($$$internal$$publish, parent);
11706
+ }
11707
+ }
11708
+
11709
+ function $$$internal$$publish(promise) {
11710
+ var subscribers = promise._subscribers;
11711
+ var settled = promise._state;
11712
+
11713
+ if (subscribers.length === 0) { return; }
11714
+
11715
+ var child, callback, detail = promise._result;
11716
+
11717
+ for (var i = 0; i < subscribers.length; i += 3) {
11718
+ child = subscribers[i];
11719
+ callback = subscribers[i + settled];
11720
+
11721
+ if (child) {
11722
+ $$$internal$$invokeCallback(settled, child, callback, detail);
11723
+ } else {
11724
+ callback(detail);
11725
+ }
11726
+ }
11727
+
11728
+ promise._subscribers.length = 0;
11729
+ }
11730
+
11731
+ function $$$internal$$ErrorObject() {
11732
+ this.error = null;
11733
+ }
11734
+
11735
+ var $$$internal$$TRY_CATCH_ERROR = new $$$internal$$ErrorObject();
11736
+
11737
+ function $$$internal$$tryCatch(callback, detail) {
11738
+ try {
11739
+ return callback(detail);
11740
+ } catch(e) {
11741
+ $$$internal$$TRY_CATCH_ERROR.error = e;
11742
+ return $$$internal$$TRY_CATCH_ERROR;
11743
+ }
11744
+ }
11745
+
11746
+ function $$$internal$$invokeCallback(settled, promise, callback, detail) {
11747
+ var hasCallback = $$utils$$isFunction(callback),
11748
+ value, error, succeeded, failed;
11749
+
11750
+ if (hasCallback) {
11751
+ value = $$$internal$$tryCatch(callback, detail);
11752
+
11753
+ if (value === $$$internal$$TRY_CATCH_ERROR) {
11754
+ failed = true;
11755
+ error = value.error;
11756
+ value = null;
11757
+ } else {
11758
+ succeeded = true;
11759
+ }
11760
+
11761
+ if (promise === value) {
11762
+ $$$internal$$reject(promise, $$$internal$$cannotReturnOwn());
11763
+ return;
11764
+ }
11765
+
11766
+ } else {
11767
+ value = detail;
11768
+ succeeded = true;
11769
+ }
11770
+
11771
+ if (promise._state !== $$$internal$$PENDING) {
11772
+ // noop
11773
+ } else if (hasCallback && succeeded) {
11774
+ $$$internal$$resolve(promise, value);
11775
+ } else if (failed) {
11776
+ $$$internal$$reject(promise, error);
11777
+ } else if (settled === $$$internal$$FULFILLED) {
11778
+ $$$internal$$fulfill(promise, value);
11779
+ } else if (settled === $$$internal$$REJECTED) {
11780
+ $$$internal$$reject(promise, value);
11781
+ }
11782
+ }
11783
+
11784
+ function $$$internal$$initializePromise(promise, resolver) {
11785
+ try {
11786
+ resolver(function resolvePromise(value){
11787
+ $$$internal$$resolve(promise, value);
11788
+ }, function rejectPromise(reason) {
11789
+ $$$internal$$reject(promise, reason);
11790
+ });
11791
+ } catch(e) {
11792
+ $$$internal$$reject(promise, e);
11793
+ }
11794
+ }
11795
+
11796
+ function $$$enumerator$$makeSettledResult(state, position, value) {
11797
+ if (state === $$$internal$$FULFILLED) {
11798
+ return {
11799
+ state: 'fulfilled',
11800
+ value: value
11801
+ };
11802
+ } else {
11803
+ return {
11804
+ state: 'rejected',
11805
+ reason: value
11806
+ };
11807
+ }
11808
+ }
11809
+
11810
+ function $$$enumerator$$Enumerator(Constructor, input, abortOnReject, label) {
11811
+ this._instanceConstructor = Constructor;
11812
+ this.promise = new Constructor($$$internal$$noop, label);
11813
+ this._abortOnReject = abortOnReject;
11814
+
11815
+ if (this._validateInput(input)) {
11816
+ this._input = input;
11817
+ this.length = input.length;
11818
+ this._remaining = input.length;
11819
+
11820
+ this._init();
11821
+
11822
+ if (this.length === 0) {
11823
+ $$$internal$$fulfill(this.promise, this._result);
11824
+ } else {
11825
+ this.length = this.length || 0;
11826
+ this._enumerate();
11827
+ if (this._remaining === 0) {
11828
+ $$$internal$$fulfill(this.promise, this._result);
11829
+ }
11830
+ }
11831
+ } else {
11832
+ $$$internal$$reject(this.promise, this._validationError());
11833
+ }
11834
+ }
11835
+
11836
+ $$$enumerator$$Enumerator.prototype._validateInput = function(input) {
11837
+ return $$utils$$isArray(input);
11838
+ };
11839
+
11840
+ $$$enumerator$$Enumerator.prototype._validationError = function() {
11841
+ return new Error('Array Methods must be provided an Array');
11842
+ };
11843
+
11844
+ $$$enumerator$$Enumerator.prototype._init = function() {
11845
+ this._result = new Array(this.length);
11846
+ };
11847
+
11848
+ var $$$enumerator$$default = $$$enumerator$$Enumerator;
11849
+
11850
+ $$$enumerator$$Enumerator.prototype._enumerate = function() {
11851
+ var length = this.length;
11852
+ var promise = this.promise;
11853
+ var input = this._input;
11854
+
11855
+ for (var i = 0; promise._state === $$$internal$$PENDING && i < length; i++) {
11856
+ this._eachEntry(input[i], i);
11857
+ }
11858
+ };
11859
+
11860
+ $$$enumerator$$Enumerator.prototype._eachEntry = function(entry, i) {
11861
+ var c = this._instanceConstructor;
11862
+ if ($$utils$$isMaybeThenable(entry)) {
11863
+ if (entry.constructor === c && entry._state !== $$$internal$$PENDING) {
11864
+ entry._onerror = null;
11865
+ this._settledAt(entry._state, i, entry._result);
11866
+ } else {
11867
+ this._willSettleAt(c.resolve(entry), i);
11868
+ }
11869
+ } else {
11870
+ this._remaining--;
11871
+ this._result[i] = this._makeResult($$$internal$$FULFILLED, i, entry);
11872
+ }
11873
+ };
11874
+
11875
+ $$$enumerator$$Enumerator.prototype._settledAt = function(state, i, value) {
11876
+ var promise = this.promise;
11877
+
11878
+ if (promise._state === $$$internal$$PENDING) {
11879
+ this._remaining--;
11880
+
11881
+ if (this._abortOnReject && state === $$$internal$$REJECTED) {
11882
+ $$$internal$$reject(promise, value);
11883
+ } else {
11884
+ this._result[i] = this._makeResult(state, i, value);
11885
+ }
11886
+ }
11887
+
11888
+ if (this._remaining === 0) {
11889
+ $$$internal$$fulfill(promise, this._result);
11890
+ }
11891
+ };
11892
+
11893
+ $$$enumerator$$Enumerator.prototype._makeResult = function(state, i, value) {
11894
+ return value;
11895
+ };
11896
+
11897
+ $$$enumerator$$Enumerator.prototype._willSettleAt = function(promise, i) {
11898
+ var enumerator = this;
11899
+
11900
+ $$$internal$$subscribe(promise, undefined, function(value) {
11901
+ enumerator._settledAt($$$internal$$FULFILLED, i, value);
11902
+ }, function(reason) {
11903
+ enumerator._settledAt($$$internal$$REJECTED, i, reason);
11904
+ });
11905
+ };
11906
+
11907
+ var $$promise$all$$default = function all(entries, label) {
11908
+ return new $$$enumerator$$default(this, entries, true /* abort on reject */, label).promise;
11909
+ };
11910
+
11911
+ var $$promise$race$$default = function race(entries, label) {
11912
+ /*jshint validthis:true */
11913
+ var Constructor = this;
11914
+
11915
+ var promise = new Constructor($$$internal$$noop, label);
11916
+
11917
+ if (!$$utils$$isArray(entries)) {
11918
+ $$$internal$$reject(promise, new TypeError('You must pass an array to race.'));
11919
+ return promise;
11920
+ }
11921
+
11922
+ var length = entries.length;
11923
+
11924
+ function onFulfillment(value) {
11925
+ $$$internal$$resolve(promise, value);
11926
+ }
11927
+
11928
+ function onRejection(reason) {
11929
+ $$$internal$$reject(promise, reason);
11930
+ }
11931
+
11932
+ for (var i = 0; promise._state === $$$internal$$PENDING && i < length; i++) {
11933
+ $$$internal$$subscribe(Constructor.resolve(entries[i]), undefined, onFulfillment, onRejection);
11934
+ }
11935
+
11936
+ return promise;
11937
+ };
11938
+
11939
+ var $$promise$resolve$$default = function resolve(object, label) {
11940
+ /*jshint validthis:true */
11941
+ var Constructor = this;
11942
+
11943
+ if (object && typeof object === 'object' && object.constructor === Constructor) {
11944
+ return object;
11945
+ }
11946
+
11947
+ var promise = new Constructor($$$internal$$noop, label);
11948
+ $$$internal$$resolve(promise, object);
11949
+ return promise;
11950
+ };
11951
+
11952
+ var $$promise$reject$$default = function reject(reason, label) {
11953
+ /*jshint validthis:true */
11954
+ var Constructor = this;
11955
+ var promise = new Constructor($$$internal$$noop, label);
11956
+ $$$internal$$reject(promise, reason);
11957
+ return promise;
11958
+ };
11959
+
11960
+ var $$es6$promise$promise$$counter = 0;
11961
+
11962
+ function $$es6$promise$promise$$needsResolver() {
11963
+ throw new TypeError('You must pass a resolver function as the first argument to the promise constructor');
11964
+ }
11965
+
11966
+ function $$es6$promise$promise$$needsNew() {
11967
+ throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.");
11968
+ }
11969
+
11970
+ var $$es6$promise$promise$$default = $$es6$promise$promise$$Promise;
11971
+
11972
+ /**
11973
+ Promise objects represent the eventual result of an asynchronous operation. The
11974
+ primary way of interacting with a promise is through its `then` method, which
11975
+ registers callbacks to receive either a promise’s eventual value or the reason
11976
+ why the promise cannot be fulfilled.
11977
+
11978
+ Terminology
11979
+ -----------
11980
+
11981
+ - `promise` is an object or function with a `then` method whose behavior conforms to this specification.
11982
+ - `thenable` is an object or function that defines a `then` method.
11983
+ - `value` is any legal JavaScript value (including undefined, a thenable, or a promise).
11984
+ - `exception` is a value that is thrown using the throw statement.
11985
+ - `reason` is a value that indicates why a promise was rejected.
11986
+ - `settled` the final resting state of a promise, fulfilled or rejected.
11987
+
11988
+ A promise can be in one of three states: pending, fulfilled, or rejected.
11989
+
11990
+ Promises that are fulfilled have a fulfillment value and are in the fulfilled
11991
+ state. Promises that are rejected have a rejection reason and are in the
11992
+ rejected state. A fulfillment value is never a thenable.
11993
+
11994
+ Promises can also be said to *resolve* a value. If this value is also a
11995
+ promise, then the original promise's settled state will match the value's
11996
+ settled state. So a promise that *resolves* a promise that rejects will
11997
+ itself reject, and a promise that *resolves* a promise that fulfills will
11998
+ itself fulfill.
11999
+
12000
+
12001
+ Basic Usage:
12002
+ ------------
12003
+
12004
+ ```js
12005
+ var promise = new Promise(function(resolve, reject) {
12006
+ // on success
12007
+ resolve(value);
12008
+
12009
+ // on failure
12010
+ reject(reason);
12011
+ });
12012
+
12013
+ promise.then(function(value) {
12014
+ // on fulfillment
12015
+ }, function(reason) {
12016
+ // on rejection
12017
+ });
12018
+ ```
12019
+
12020
+ Advanced Usage:
12021
+ ---------------
12022
+
12023
+ Promises shine when abstracting away asynchronous interactions such as
12024
+ `XMLHttpRequest`s.
12025
+
12026
+ ```js
12027
+ function getJSON(url) {
12028
+ return new Promise(function(resolve, reject){
12029
+ var xhr = new XMLHttpRequest();
12030
+
12031
+ xhr.open('GET', url);
12032
+ xhr.onreadystatechange = handler;
12033
+ xhr.responseType = 'json';
12034
+ xhr.setRequestHeader('Accept', 'application/json');
12035
+ xhr.send();
12036
+
12037
+ function handler() {
12038
+ if (this.readyState === this.DONE) {
12039
+ if (this.status === 200) {
12040
+ resolve(this.response);
12041
+ } else {
12042
+ reject(new Error('getJSON: `' + url + '` failed with status: [' + this.status + ']'));
12043
+ }
12044
+ }
12045
+ };
12046
+ });
12047
+ }
12048
+
12049
+ getJSON('/posts.json').then(function(json) {
12050
+ // on fulfillment
12051
+ }, function(reason) {
12052
+ // on rejection
12053
+ });
12054
+ ```
12055
+
12056
+ Unlike callbacks, promises are great composable primitives.
12057
+
12058
+ ```js
12059
+ Promise.all([
12060
+ getJSON('/posts'),
12061
+ getJSON('/comments')
12062
+ ]).then(function(values){
12063
+ values[0] // => postsJSON
12064
+ values[1] // => commentsJSON
12065
+
12066
+ return values;
12067
+ });
12068
+ ```
12069
+
12070
+ @class Promise
12071
+ @param {function} resolver
12072
+ Useful for tooling.
12073
+ @constructor
12074
+ */
12075
+ function $$es6$promise$promise$$Promise(resolver) {
12076
+ this._id = $$es6$promise$promise$$counter++;
12077
+ this._state = undefined;
12078
+ this._result = undefined;
12079
+ this._subscribers = [];
12080
+
12081
+ if ($$$internal$$noop !== resolver) {
12082
+ if (!$$utils$$isFunction(resolver)) {
12083
+ $$es6$promise$promise$$needsResolver();
12084
+ }
12085
+
12086
+ if (!(this instanceof $$es6$promise$promise$$Promise)) {
12087
+ $$es6$promise$promise$$needsNew();
12088
+ }
12089
+
12090
+ $$$internal$$initializePromise(this, resolver);
12091
+ }
12092
+ }
12093
+
12094
+ $$es6$promise$promise$$Promise.all = $$promise$all$$default;
12095
+ $$es6$promise$promise$$Promise.race = $$promise$race$$default;
12096
+ $$es6$promise$promise$$Promise.resolve = $$promise$resolve$$default;
12097
+ $$es6$promise$promise$$Promise.reject = $$promise$reject$$default;
12098
+
12099
+ $$es6$promise$promise$$Promise.prototype = {
12100
+ constructor: $$es6$promise$promise$$Promise,
12101
+
12102
+ /**
12103
+ The primary way of interacting with a promise is through its `then` method,
12104
+ which registers callbacks to receive either a promise's eventual value or the
12105
+ reason why the promise cannot be fulfilled.
12106
+
12107
+ ```js
12108
+ findUser().then(function(user){
12109
+ // user is available
12110
+ }, function(reason){
12111
+ // user is unavailable, and you are given the reason why
12112
+ });
12113
+ ```
12114
+
12115
+ Chaining
12116
+ --------
12117
+
12118
+ The return value of `then` is itself a promise. This second, 'downstream'
12119
+ promise is resolved with the return value of the first promise's fulfillment
12120
+ or rejection handler, or rejected if the handler throws an exception.
12121
+
12122
+ ```js
12123
+ findUser().then(function (user) {
12124
+ return user.name;
12125
+ }, function (reason) {
12126
+ return 'default name';
12127
+ }).then(function (userName) {
12128
+ // If `findUser` fulfilled, `userName` will be the user's name, otherwise it
12129
+ // will be `'default name'`
12130
+ });
12131
+
12132
+ findUser().then(function (user) {
12133
+ throw new Error('Found user, but still unhappy');
12134
+ }, function (reason) {
12135
+ throw new Error('`findUser` rejected and we're unhappy');
12136
+ }).then(function (value) {
12137
+ // never reached
12138
+ }, function (reason) {
12139
+ // if `findUser` fulfilled, `reason` will be 'Found user, but still unhappy'.
12140
+ // If `findUser` rejected, `reason` will be '`findUser` rejected and we're unhappy'.
12141
+ });
12142
+ ```
12143
+ If the downstream promise does not specify a rejection handler, rejection reasons will be propagated further downstream.
12144
+
12145
+ ```js
12146
+ findUser().then(function (user) {
12147
+ throw new PedagogicalException('Upstream error');
12148
+ }).then(function (value) {
12149
+ // never reached
12150
+ }).then(function (value) {
12151
+ // never reached
12152
+ }, function (reason) {
12153
+ // The `PedgagocialException` is propagated all the way down to here
12154
+ });
12155
+ ```
12156
+
12157
+ Assimilation
12158
+ ------------
12159
+
12160
+ Sometimes the value you want to propagate to a downstream promise can only be
12161
+ retrieved asynchronously. This can be achieved by returning a promise in the
12162
+ fulfillment or rejection handler. The downstream promise will then be pending
12163
+ until the returned promise is settled. This is called *assimilation*.
12164
+
12165
+ ```js
12166
+ findUser().then(function (user) {
12167
+ return findCommentsByAuthor(user);
12168
+ }).then(function (comments) {
12169
+ // The user's comments are now available
12170
+ });
12171
+ ```
12172
+
12173
+ If the assimliated promise rejects, then the downstream promise will also reject.
12174
+
12175
+ ```js
12176
+ findUser().then(function (user) {
12177
+ return findCommentsByAuthor(user);
12178
+ }).then(function (comments) {
12179
+ // If `findCommentsByAuthor` fulfills, we'll have the value here
12180
+ }, function (reason) {
12181
+ // If `findCommentsByAuthor` rejects, we'll have the reason here
12182
+ });
12183
+ ```
12184
+
12185
+ Simple Example
12186
+ --------------
12187
+
12188
+ Synchronous Example
12189
+
12190
+ ```javascript
12191
+ var result;
12192
+
12193
+ try {
12194
+ result = findResult();
12195
+ // success
12196
+ } catch(reason) {
12197
+ // failure
12198
+ }
12199
+ ```
12200
+
12201
+ Errback Example
12202
+
12203
+ ```js
12204
+ findResult(function(result, err){
12205
+ if (err) {
12206
+ // failure
12207
+ } else {
12208
+ // success
12209
+ }
12210
+ });
12211
+ ```
12212
+
12213
+ Promise Example;
12214
+
12215
+ ```javascript
12216
+ findResult().then(function(result){
12217
+ // success
12218
+ }, function(reason){
12219
+ // failure
12220
+ });
12221
+ ```
12222
+
12223
+ Advanced Example
12224
+ --------------
12225
+
12226
+ Synchronous Example
12227
+
12228
+ ```javascript
12229
+ var author, books;
12230
+
12231
+ try {
12232
+ author = findAuthor();
12233
+ books = findBooksByAuthor(author);
12234
+ // success
12235
+ } catch(reason) {
12236
+ // failure
12237
+ }
12238
+ ```
12239
+
12240
+ Errback Example
12241
+
12242
+ ```js
12243
+
12244
+ function foundBooks(books) {
12245
+
12246
+ }
12247
+
12248
+ function failure(reason) {
12249
+
12250
+ }
12251
 
12252
+ findAuthor(function(author, err){
12253
+ if (err) {
12254
+ failure(err);
12255
+ // failure
12256
+ } else {
12257
+ try {
12258
+ findBoooksByAuthor(author, function(books, err) {
12259
+ if (err) {
12260
+ failure(err);
12261
+ } else {
12262
+ try {
12263
+ foundBooks(books);
12264
+ } catch(reason) {
12265
+ failure(reason);
12266
+ }
12267
+ }
12268
+ });
12269
+ } catch(error) {
12270
+ failure(err);
12271
+ }
12272
+ // success
12273
+ }
12274
+ });
12275
+ ```
12276
 
12277
+ Promise Example;
 
 
 
12278
 
12279
+ ```javascript
12280
+ findAuthor().
12281
+ then(findBooksByAuthor).
12282
+ then(function(books){
12283
+ // found books
12284
+ }).catch(function(reason){
12285
+ // something went wrong
12286
+ });
12287
+ ```
12288
+
12289
+ @method then
12290
+ @param {Function} onFulfilled
12291
+ @param {Function} onRejected
12292
+ Useful for tooling.
12293
+ @return {Promise}
12294
+ */
12295
+ then: function(onFulfillment, onRejection) {
12296
+ var parent = this;
12297
+ var state = parent._state;
12298
+
12299
+ if (state === $$$internal$$FULFILLED && !onFulfillment || state === $$$internal$$REJECTED && !onRejection) {
12300
+ return this;
12301
+ }
12302
 
12303
+ var child = new this.constructor($$$internal$$noop);
12304
+ var result = parent._result;
 
 
12305
 
12306
+ if (state) {
12307
+ var callback = arguments[state - 1];
12308
+ $$asap$$default(function(){
12309
+ $$$internal$$invokeCallback(state, child, callback, result);
12310
+ });
12311
+ } else {
12312
+ $$$internal$$subscribe(parent, child, onFulfillment, onRejection);
12313
+ }
12314
 
12315
+ return child;
12316
+ },
12317
 
12318
+ /**
12319
+ `catch` is simply sugar for `then(undefined, onRejection)` which makes it the same
12320
+ as the catch block of a try/catch statement.
12321
 
12322
+ ```js
12323
+ function findAuthor(){
12324
+ throw new Error('couldn't find that author');
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
12325
  }
12326
+
12327
+ // synchronous
12328
+ try {
12329
+ findAuthor();
12330
+ } catch(reason) {
12331
+ // something went wrong
 
12332
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
12333
 
12334
+ // async with promises
12335
+ findAuthor().catch(function(reason){
12336
+ // something went wrong
12337
+ });
12338
+ ```
12339
+
12340
+ @method catch
12341
+ @param {Function} onRejection
12342
+ Useful for tooling.
12343
+ @return {Promise}
12344
+ */
12345
+ 'catch': function(onRejection) {
12346
+ return this.then(null, onRejection);
12347
+ }
12348
+ };
12349
 
12350
+ var $$es6$promise$polyfill$$default = function polyfill() {
12351
+ var local;
12352
+
12353
+ if (typeof global !== 'undefined') {
12354
+ local = global;
12355
+ } else if (typeof window !== 'undefined' && window.document) {
12356
+ local = window;
12357
+ } else {
12358
+ local = self;
12359
+ }
12360
+
12361
+ var es6PromiseSupport =
12362
+ "Promise" in local &&
12363
+ // Some of these methods are missing from
12364
+ // Firefox/Chrome experimental implementations
12365
+ "resolve" in local.Promise &&
12366
+ "reject" in local.Promise &&
12367
+ "all" in local.Promise &&
12368
+ "race" in local.Promise &&
12369
+ // Older version of the spec had a resolver object
12370
+ // as the arg rather than a function
12371
+ (function() {
12372
+ var resolve;
12373
+ new local.Promise(function(r) { resolve = r; });
12374
+ return $$utils$$isFunction(resolve);
12375
+ }());
12376
+
12377
+ if (!es6PromiseSupport) {
12378
+ local.Promise = $$es6$promise$promise$$default;
12379
+ }
12380
+ };
12381
+
12382
+ var es6$promise$umd$$ES6Promise = {
12383
+ 'Promise': $$es6$promise$promise$$default,
12384
+ 'polyfill': $$es6$promise$polyfill$$default
12385
+ };
12386
+
12387
+ /* global define:true module:true window: true */
12388
+ if (typeof define === 'function' && define['amd']) {
12389
+ define(function() { return es6$promise$umd$$ES6Promise; });
12390
+ } else if (typeof module !== 'undefined' && module['exports']) {
12391
+ module['exports'] = es6$promise$umd$$ES6Promise;
12392
+ } else if (typeof this !== 'undefined') {
12393
+ this['ES6Promise'] = es6$promise$umd$$ES6Promise;
12394
  }
12395
+ }).call(this);
12396
+ }).call(this,require('_process'),typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
12397
+ },{"_process":2}],2:[function(require,module,exports){
12398
+ // shim for using process in browser
12399
+
12400
+ var process = module.exports = {};
12401
+ var queue = [];
12402
+ var draining = false;
12403
+
12404
+ function drainQueue() {
12405
+ if (draining) {
12406
+ return;
12407
+ }
12408
+ draining = true;
12409
+ var currentQueue;
12410
+ var len = queue.length;
12411
+ while(len) {
12412
+ currentQueue = queue;
12413
+ queue = [];
12414
+ var i = -1;
12415
+ while (++i < len) {
12416
+ currentQueue[i]();
12417
+ }
12418
+ len = queue.length;
12419
+ }
12420
+ draining = false;
12421
+ }
12422
+ process.nextTick = function (fun) {
12423
+ queue.push(fun);
12424
+ if (!draining) {
12425
+ setTimeout(drainQueue, 0);
12426
+ }
12427
+ };
12428
+
12429
+ process.title = 'browser';
12430
+ process.browser = true;
12431
+ process.env = {};
12432
+ process.argv = [];
12433
+ process.version = ''; // empty string to avoid regexp issues
12434
+
12435
+ function noop() {}
12436
+
12437
+ process.on = noop;
12438
+ process.addListener = noop;
12439
+ process.once = noop;
12440
+ process.off = noop;
12441
+ process.removeListener = noop;
12442
+ process.removeAllListeners = noop;
12443
+ process.emit = noop;
12444
+
12445
+ process.binding = function (name) {
12446
+ throw new Error('process.binding is not supported');
12447
+ };
12448
+
12449
+ // TODO(shtylman)
12450
+ process.cwd = function () { return '/' };
12451
+ process.chdir = function (dir) {
12452
+ throw new Error('process.chdir is not supported');
12453
+ };
12454
+ process.umask = function() { return 0; };
12455
+
12456
+ },{}],3:[function(require,module,exports){
12457
+ (function (global){
12458
+ /*! http://mths.be/punycode v1.2.4 by @mathias */
12459
+ ;(function(root) {
12460
+
12461
+ /** Detect free variables */
12462
+ var freeExports = typeof exports == 'object' && exports;
12463
+ var freeModule = typeof module == 'object' && module &&
12464
+ module.exports == freeExports && module;
12465
+ var freeGlobal = typeof global == 'object' && global;
12466
+ if (freeGlobal.global === freeGlobal || freeGlobal.window === freeGlobal) {
12467
+ root = freeGlobal;
12468
+ }
12469
+
12470
+ /**
12471
+ * The `punycode` object.
12472
+ * @name punycode
12473
+ * @type Object
12474
+ */
12475
+ var punycode,
12476
+
12477
+ /** Highest positive signed 32-bit float value */
12478
+ maxInt = 2147483647, // aka. 0x7FFFFFFF or 2^31-1
12479
+
12480
+ /** Bootstring parameters */
12481
+ base = 36,
12482
+ tMin = 1,
12483
+ tMax = 26,
12484
+ skew = 38,
12485
+ damp = 700,
12486
+ initialBias = 72,
12487
+ initialN = 128, // 0x80
12488
+ delimiter = '-', // '\x2D'
12489
+
12490
+ /** Regular expressions */
12491
+ regexPunycode = /^xn--/,
12492
+ regexNonASCII = /[^ -~]/, // unprintable ASCII chars + non-ASCII chars
12493
+ regexSeparators = /\x2E|\u3002|\uFF0E|\uFF61/g, // RFC 3490 separators
12494
+
12495
+ /** Error messages */
12496
+ errors = {
12497
+ 'overflow': 'Overflow: input needs wider integers to process',
12498
+ 'not-basic': 'Illegal input >= 0x80 (not a basic code point)',
12499
+ 'invalid-input': 'Invalid input'
12500
+ },
12501
+
12502
+ /** Convenience shortcuts */
12503
+ baseMinusTMin = base - tMin,
12504
+ floor = Math.floor,
12505
+ stringFromCharCode = String.fromCharCode,
12506
+
12507
+ /** Temporary variable */
12508
+ key;
12509
+
12510
+ /*--------------------------------------------------------------------------*/
12511
+
12512
+ /**
12513
+ * A generic error utility function.
12514
+ * @private
12515
+ * @param {String} type The error type.
12516
+ * @returns {Error} Throws a `RangeError` with the applicable error message.
12517
+ */
12518
+ function error(type) {
12519
+ throw RangeError(errors[type]);
12520
+ }
12521
+
12522
+ /**
12523
+ * A generic `Array#map` utility function.
12524
+ * @private
12525
+ * @param {Array} array The array to iterate over.
12526
+ * @param {Function} callback The function that gets called for every array
12527
+ * item.
12528
+ * @returns {Array} A new array of values returned by the callback function.
12529
+ */
12530
+ function map(array, fn) {
12531
+ var length = array.length;
12532
+ while (length--) {
12533
+ array[length] = fn(array[length]);
12534
+ }
12535
+ return array;
12536
+ }
12537
+
12538
+ /**
12539
+ * A simple `Array#map`-like wrapper to work with domain name strings.
12540
+ * @private
12541
+ * @param {String} domain The domain name.
12542
+ * @param {Function} callback The function that gets called for every
12543
+ * character.
12544
+ * @returns {Array} A new string of characters returned by the callback
12545
+ * function.
12546
+ */
12547
+ function mapDomain(string, fn) {
12548
+ return map(string.split(regexSeparators), fn).join('.');
12549
+ }
12550
+
12551
+ /**
12552
+ * Creates an array containing the numeric code points of each Unicode
12553
+ * character in the string. While JavaScript uses UCS-2 internally,
12554
+ * this function will convert a pair of surrogate halves (each of which
12555
+ * UCS-2 exposes as separate characters) into a single code point,
12556
+ * matching UTF-16.
12557
+ * @see `punycode.ucs2.encode`
12558
+ * @see <http://mathiasbynens.be/notes/javascript-encoding>
12559
+ * @memberOf punycode.ucs2
12560
+ * @name decode
12561
+ * @param {String} string The Unicode input string (UCS-2).
12562
+ * @returns {Array} The new array of code points.
12563
+ */
12564
+ function ucs2decode(string) {
12565
+ var output = [],
12566
+ counter = 0,
12567
+ length = string.length,
12568
+ value,
12569
+ extra;
12570
+ while (counter < length) {
12571
+ value = string.charCodeAt(counter++);
12572
+ if (value >= 0xD800 && value <= 0xDBFF && counter < length) {
12573
+ // high surrogate, and there is a next character
12574
+ extra = string.charCodeAt(counter++);
12575
+ if ((extra & 0xFC00) == 0xDC00) { // low surrogate
12576
+ output.push(((value & 0x3FF) << 10) + (extra & 0x3FF) + 0x10000);
12577
+ } else {
12578
+ // unmatched surrogate; only append this code unit, in case the next
12579
+ // code unit is the high surrogate of a surrogate pair
12580
+ output.push(value);
12581
+ counter--;
12582
+ }
12583
+ } else {
12584
+ output.push(value);
12585
+ }
12586
+ }
12587
+ return output;
12588
+ }
12589
+
12590
+ /**
12591
+ * Creates a string based on an array of numeric code points.
12592
+ * @see `punycode.ucs2.decode`
12593
+ * @memberOf punycode.ucs2
12594
+ * @name encode
12595
+ * @param {Array} codePoints The array of numeric code points.
12596
+ * @returns {String} The new Unicode string (UCS-2).
12597
+ */
12598
+ function ucs2encode(array) {
12599
+ return map(array, function(value) {
12600
+ var output = '';
12601
+ if (value > 0xFFFF) {
12602
+ value -= 0x10000;
12603
+ output += stringFromCharCode(value >>> 10 & 0x3FF | 0xD800);
12604
+ value = 0xDC00 | value & 0x3FF;
12605
+ }
12606
+ output += stringFromCharCode(value);
12607
+ return output;
12608
+ }).join('');
12609
+ }
12610
+
12611
+ /**
12612
+ * Converts a basic code point into a digit/integer.
12613
+ * @see `digitToBasic()`
12614
+ * @private
12615
+ * @param {Number} codePoint The basic numeric code point value.
12616
+ * @returns {Number} The numeric value of a basic code point (for use in
12617
+ * representing integers) in the range `0` to `base - 1`, or `base` if
12618
+ * the code point does not represent a value.
12619
+ */
12620
+ function basicToDigit(codePoint) {
12621
+ if (codePoint - 48 < 10) {
12622
+ return codePoint - 22;
12623
+ }
12624
+ if (codePoint - 65 < 26) {
12625
+ return codePoint - 65;
12626
+ }
12627
+ if (codePoint - 97 < 26) {
12628
+ return codePoint - 97;
12629
+ }
12630
+ return base;
12631
+ }
12632
+
12633
+ /**
12634
+ * Converts a digit/integer into a basic code point.
12635
+ * @see `basicToDigit()`
12636
+ * @private
12637
+ * @param {Number} digit The numeric value of a basic code point.
12638
+ * @returns {Number} The basic code point whose value (when used for
12639
+ * representing integers) is `digit`, which needs to be in the range
12640
+ * `0` to `base - 1`. If `flag` is non-zero, the uppercase form is
12641
+ * used; else, the lowercase form is used. The behavior is undefined
12642
+ * if `flag` is non-zero and `digit` has no uppercase form.
12643
+ */
12644
+ function digitToBasic(digit, flag) {
12645
+ // 0..25 map to ASCII a..z or A..Z
12646
+ // 26..35 map to ASCII 0..9
12647
+ return digit + 22 + 75 * (digit < 26) - ((flag != 0) << 5);
12648
+ }
12649
+
12650
+ /**
12651
+ * Bias adaptation function as per section 3.4 of RFC 3492.
12652
+ * http://tools.ietf.org/html/rfc3492#section-3.4
12653
+ * @private
12654
+ */
12655
+ function adapt(delta, numPoints, firstTime) {
12656
+ var k = 0;
12657
+ delta = firstTime ? floor(delta / damp) : delta >> 1;
12658
+ delta += floor(delta / numPoints);
12659
+ for (/* no initialization */; delta > baseMinusTMin * tMax >> 1; k += base) {
12660
+ delta = floor(delta / baseMinusTMin);
12661
+ }
12662
+ return floor(k + (baseMinusTMin + 1) * delta / (delta + skew));
12663
+ }
12664
+
12665
+ /**
12666
+ * Converts a Punycode string of ASCII-only symbols to a string of Unicode
12667
+ * symbols.
12668
+ * @memberOf punycode
12669
+ * @param {String} input The Punycode string of ASCII-only symbols.
12670
+ * @returns {String} The resulting string of Unicode symbols.
12671
+ */
12672
+ function decode(input) {
12673
+ // Don't use UCS-2
12674
+ var output = [],
12675
+ inputLength = input.length,
12676
+ out,
12677
+ i = 0,
12678
+ n = initialN,
12679
+ bias = initialBias,
12680
+ basic,
12681
+ j,
12682
+ index,
12683
+ oldi,
12684
+ w,
12685
+ k,
12686
+ digit,
12687
+ t,
12688
+ /** Cached calculation results */
12689
+ baseMinusT;
12690
+
12691
+ // Handle the basic code points: let `basic` be the number of input code
12692
+ // points before the last delimiter, or `0` if there is none, then copy
12693
+ // the first basic code points to the output.
12694
+
12695
+ basic = input.lastIndexOf(delimiter);
12696
+ if (basic < 0) {
12697
+ basic = 0;
12698
+ }
12699
+
12700
+ for (j = 0; j < basic; ++j) {
12701
+ // if it's not a basic code point
12702
+ if (input.charCodeAt(j) >= 0x80) {
12703
+ error('not-basic');
12704
+ }
12705
+ output.push(input.charCodeAt(j));
12706
+ }
12707
+
12708
+ // Main decoding loop: start just after the last delimiter if any basic code
12709
+ // points were copied; start at the beginning otherwise.
12710
+
12711
+ for (index = basic > 0 ? basic + 1 : 0; index < inputLength; /* no final expression */) {
12712
+
12713
+ // `index` is the index of the next character to be consumed.
12714
+ // Decode a generalized variable-length integer into `delta`,
12715
+ // which gets added to `i`. The overflow checking is easier
12716
+ // if we increase `i` as we go, then subtract off its starting
12717
+ // value at the end to obtain `delta`.
12718
+ for (oldi = i, w = 1, k = base; /* no condition */; k += base) {
12719
+
12720
+ if (index >= inputLength) {
12721
+ error('invalid-input');
12722
+ }
12723
+
12724
+ digit = basicToDigit(input.charCodeAt(index++));
12725
+
12726
+ if (digit >= base || digit > floor((maxInt - i) / w)) {
12727
+ error('overflow');
12728
+ }
12729
+
12730
+ i += digit * w;
12731
+ t = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);
12732
+
12733
+ if (digit < t) {
12734
+ break;
12735
+ }
12736
+
12737
+ baseMinusT = base - t;
12738
+ if (w > floor(maxInt / baseMinusT)) {
12739
+ error('overflow');
12740
+ }
12741
+
12742
+ w *= baseMinusT;
12743
+
12744
+ }
12745
+
12746
+ out = output.length + 1;
12747
+ bias = adapt(i - oldi, out, oldi == 0);
12748
+
12749
+ // `i` was supposed to wrap around from `out` to `0`,
12750
+ // incrementing `n` each time, so we'll fix that now:
12751
+ if (floor(i / out) > maxInt - n) {
12752
+ error('overflow');
12753
+ }
12754
+
12755
+ n += floor(i / out);
12756
+ i %= out;
12757
+
12758
+ // Insert `n` at position `i` of the output
12759
+ output.splice(i++, 0, n);
12760
+
12761
+ }
12762
+
12763
+ return ucs2encode(output);
12764
+ }
12765
+
12766
+ /**
12767
+ * Converts a string of Unicode symbols to a Punycode string of ASCII-only
12768
+ * symbols.
12769
+ * @memberOf punycode
12770
+ * @param {String} input The string of Unicode symbols.
12771
+ * @returns {String} The resulting Punycode string of ASCII-only symbols.
12772
+ */
12773
+ function encode(input) {
12774
+ var n,
12775
+ delta,
12776
+ handledCPCount,
12777
+ basicLength,
12778
+ bias,
12779
+ j,
12780
+ m,
12781
+ q,
12782
+ k,
12783
+ t,
12784
+ currentValue,
12785
+ output = [],
12786
+ /** `inputLength` will hold the number of code points in `input`. */
12787
+ inputLength,
12788
+ /** Cached calculation results */
12789
+ handledCPCountPlusOne,
12790
+ baseMinusT,
12791
+ qMinusT;
12792
+
12793
+ // Convert the input in UCS-2 to Unicode
12794
+ input = ucs2decode(input);
12795
+
12796
+ // Cache the length
12797
+ inputLength = input.length;
12798
+
12799
+ // Initialize the state
12800
+ n = initialN;
12801
+ delta = 0;
12802
+ bias = initialBias;
12803
+
12804
+ // Handle the basic code points
12805
+ for (j = 0; j < inputLength; ++j) {
12806
+ currentValue = input[j];
12807
+ if (currentValue < 0x80) {
12808
+ output.push(stringFromCharCode(currentValue));
12809
+ }
12810
+ }
12811
+
12812
+ handledCPCount = basicLength = output.length;
12813
+
12814
+ // `handledCPCount` is the number of code points that have been handled;
12815
+ // `basicLength` is the number of basic code points.
12816
+
12817
+ // Finish the basic string - if it is not empty - with a delimiter
12818
+ if (basicLength) {
12819
+ output.push(delimiter);
12820
+ }
12821
+
12822
+ // Main encoding loop:
12823
+ while (handledCPCount < inputLength) {
12824
+
12825
+ // All non-basic code points < n have been handled already. Find the next
12826
+ // larger one:
12827
+ for (m = maxInt, j = 0; j < inputLength; ++j) {
12828
+ currentValue = input[j];
12829
+ if (currentValue >= n && currentValue < m) {
12830
+ m = currentValue;
12831
+ }
12832
+ }
12833
+
12834
+ // Increase `delta` enough to advance the decoder's <n,i> state to <m,0>,
12835
+ // but guard against overflow
12836
+ handledCPCountPlusOne = handledCPCount + 1;
12837
+ if (m - n > floor((maxInt - delta) / handledCPCountPlusOne)) {
12838
+ error('overflow');
12839
+ }
12840
+
12841
+ delta += (m - n) * handledCPCountPlusOne;
12842
+ n = m;
12843
+
12844
+ for (j = 0; j < inputLength; ++j) {
12845
+ currentValue = input[j];
12846
+
12847
+ if (currentValue < n && ++delta > maxInt) {
12848
+ error('overflow');
12849
+ }
12850
+
12851
+ if (currentValue == n) {
12852
+ // Represent delta as a generalized variable-length integer
12853
+ for (q = delta, k = base; /* no condition */; k += base) {
12854
+ t = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);
12855
+ if (q < t) {
12856
+ break;
12857
+ }
12858
+ qMinusT = q - t;
12859
+ baseMinusT = base - t;
12860
+ output.push(
12861
+ stringFromCharCode(digitToBasic(t + qMinusT % baseMinusT, 0))
12862
+ );
12863
+ q = floor(qMinusT / baseMinusT);
12864
+ }
12865
+
12866
+ output.push(stringFromCharCode(digitToBasic(q, 0)));
12867
+ bias = adapt(delta, handledCPCountPlusOne, handledCPCount == basicLength);
12868
+ delta = 0;
12869
+ ++handledCPCount;
12870
+ }
12871
+ }
12872
+
12873
+ ++delta;
12874
+ ++n;
12875
+
12876
+ }
12877
+ return output.join('');
12878
+ }
12879
+
12880
+ /**
12881
+ * Converts a Punycode string representing a domain name to Unicode. Only the
12882
+ * Punycoded parts of the domain name will be converted, i.e. it doesn't
12883
+ * matter if you call it on a string that has already been converted to
12884
+ * Unicode.
12885
+ * @memberOf punycode
12886
+ * @param {String} domain The Punycode domain name to convert to Unicode.
12887
+ * @returns {String} The Unicode representation of the given Punycode
12888
+ * string.
12889
+ */
12890
+ function toUnicode(domain) {
12891
+ return mapDomain(domain, function(string) {
12892
+ return regexPunycode.test(string)
12893
+ ? decode(string.slice(4).toLowerCase())
12894
+ : string;
12895
+ });
12896
+ }
12897
+
12898
+ /**
12899
+ * Converts a Unicode string representing a domain name to Punycode. Only the
12900
+ * non-ASCII parts of the domain name will be converted, i.e. it doesn't
12901
+ * matter if you call it with a domain that's already in ASCII.
12902
+ * @memberOf punycode
12903
+ * @param {String} domain The domain name to convert, as a Unicode string.
12904
+ * @returns {String} The Punycode representation of the given domain name.
12905
+ */
12906
+ function toASCII(domain) {
12907
+ return mapDomain(domain, function(string) {
12908
+ return regexNonASCII.test(string)
12909
+ ? 'xn--' + encode(string)
12910
+ : string;
12911
+ });
12912
+ }
12913
+
12914
+ /*--------------------------------------------------------------------------*/
12915
+
12916
+ /** Define the public API */
12917
+ punycode = {
12918
+ /**
12919
+ * A string representing the current Punycode.js version number.
12920
+ * @memberOf punycode
12921
+ * @type String
12922
+ */
12923
+ 'version': '1.2.4',
12924
+ /**
12925
+ * An object of methods to convert from JavaScript's internal character
12926
+ * representation (UCS-2) to Unicode code points, and back.
12927
+ * @see <http://mathiasbynens.be/notes/javascript-encoding>
12928
+ * @memberOf punycode
12929
+ * @type Object
12930
+ */
12931
+ 'ucs2': {
12932
+ 'decode': ucs2decode,
12933
+ 'encode': ucs2encode
12934
+ },
12935
+ 'decode': decode,
12936
+ 'encode': encode,
12937
+ 'toASCII': toASCII,
12938
+ 'toUnicode': toUnicode
12939
+ };
12940
+
12941
+ /** Expose `punycode` */
12942
+ // Some AMD build optimizers, like r.js, check for specific condition patterns
12943
+ // like the following:
12944
+ if (
12945
+ typeof define == 'function' &&
12946
+ typeof define.amd == 'object' &&
12947
+ define.amd
12948
+ ) {
12949
+ define('punycode', function() {
12950
+ return punycode;
12951
+ });
12952
+ } else if (freeExports && !freeExports.nodeType) {
12953
+ if (freeModule) { // in Node.js or RingoJS v0.8.0+
12954
+ freeModule.exports = punycode;
12955
+ } else { // in Narwhal or RingoJS v0.7.0-
12956
+ for (key in punycode) {
12957
+ punycode.hasOwnProperty(key) && (freeExports[key] = punycode[key]);
12958
+ }
12959
+ }
12960
+ } else { // in Rhino or a web browser
12961
+ root.punycode = punycode;
12962
+ }
12963
+
12964
+ }(this));
12965
+
12966
+ }).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
12967
+ },{}],4:[function(require,module,exports){
12968
+ var log = require('./log');
12969
+ var Promise = require('./promise');
12970
+
12971
+ var html2canvasCanvasCloneAttribute = "data-html2canvas-canvas-clone";
12972
+ var html2canvasCanvasCloneIndex = 0;
12973
+
12974
+ function cloneNodeValues(document, clone, nodeName) {
12975
+ var originalNodes = document.getElementsByTagName(nodeName);
12976
+ var clonedNodes = clone.getElementsByTagName(nodeName);
12977
+ var count = originalNodes.length;
12978
+ for (var i = 0; i < count; i++) {
12979
+ clonedNodes[i].value = originalNodes[i].value;
12980
+ }
12981
+ }
12982
+
12983
+ function restoreOwnerScroll(ownerDocument, x, y) {
12984
+ if (ownerDocument.defaultView && (x !== ownerDocument.defaultView.pageXOffset || y !== ownerDocument.defaultView.pageYOffset)) {
12985
+ ownerDocument.defaultView.scrollTo(x, y);
12986
+ }
12987
+ }
12988
+
12989
+ function labelCanvasElements(ownerDocument) {
12990
+ [].slice.call(ownerDocument.querySelectorAll("canvas"), 0).forEach(function(canvas) {
12991
+ canvas.setAttribute(html2canvasCanvasCloneAttribute, "canvas-" + html2canvasCanvasCloneIndex++);
12992
+ });
12993
+ }
12994
+
12995
+ function cloneCanvasContents(ownerDocument, documentClone) {
12996
+ [].slice.call(ownerDocument.querySelectorAll("[" + html2canvasCanvasCloneAttribute + "]"), 0).forEach(function(canvas) {
12997
+ try {
12998
+ var clonedCanvas = documentClone.querySelector('[' + html2canvasCanvasCloneAttribute + '="' + canvas.getAttribute(html2canvasCanvasCloneAttribute) + '"]');
12999
+ if (clonedCanvas) {
13000
+ clonedCanvas.width = canvas.width;
13001
+ clonedCanvas.height = canvas.height;
13002
+ clonedCanvas.getContext("2d").putImageData(canvas.getContext("2d").getImageData(0, 0, canvas.width, canvas.height), 0, 0);
13003
+ }
13004
+ } catch(e) {
13005
+ log("Unable to copy canvas content from", canvas, e);
13006
+ }
13007
+ canvas.removeAttribute(html2canvasCanvasCloneAttribute);
13008
+ });
13009
+ }
13010
+
13011
+ function removeScriptNodes(parent) {
13012
+ [].slice.call(parent.childNodes, 0).filter(isElementNode).forEach(function(node) {
13013
+ if (node.tagName === "SCRIPT") {
13014
+ parent.removeChild(node);
13015
+ } else {
13016
+ removeScriptNodes(node);
13017
+ }
13018
+ });
13019
+ return parent;
13020
+ }
13021
+
13022
+ function isIE9() {
13023
+ return document.documentMode && document.documentMode <= 9;
13024
+ }
13025
+
13026
+ // https://github.com/niklasvh/html2canvas/issues/503
13027
+ function cloneNodeIE9(node, javascriptEnabled) {
13028
+ var clone = node.nodeType === 3 ? document.createTextNode(node.nodeValue) : node.cloneNode(false);
13029
+
13030
+ var child = node.firstChild;
13031
+ while(child) {
13032
+ if (javascriptEnabled === true || child.nodeType !== 1 || child.nodeName !== 'SCRIPT') {
13033
+ clone.appendChild(cloneNodeIE9(child, javascriptEnabled));
13034
+ }
13035
+ child = child.nextSibling;
13036
+ }
13037
+
13038
+ return clone;
13039
+ }
13040
+
13041
+
13042
+
13043
+ function isElementNode(node) {
13044
+ return node.nodeType === Node.ELEMENT_NODE;
13045
+ }
13046
+
13047
+ module.exports = function(ownerDocument, containerDocument, width, height, options, x ,y) {
13048
+ labelCanvasElements(ownerDocument);
13049
+ var documentElement = isIE9() ? cloneNodeIE9(ownerDocument.documentElement, options.javascriptEnabled) : ownerDocument.documentElement.cloneNode(true);
13050
+ var container = containerDocument.createElement("iframe");
13051
+
13052
+ container.className = "html2canvas-container";
13053
+ container.style.visibility = "hidden";
13054
+ container.style.position = "fixed";
13055
+ container.style.left = "-10000px";
13056
+ container.style.top = "0px";
13057
+ container.style.border = "0";
13058
+ container.width = width;
13059
+ container.height = height;
13060
+ container.scrolling = "no"; // ios won't scroll without it
13061
+ containerDocument.body.appendChild(container);
13062
+
13063
+ return new Promise(function(resolve) {
13064
+ var documentClone = container.contentWindow.document;
13065
+
13066
+ cloneNodeValues(ownerDocument.documentElement, documentElement, "textarea");
13067
+ cloneNodeValues(ownerDocument.documentElement, documentElement, "select");
13068
+
13069
+ /* Chrome doesn't detect relative background-images assigned in inline <style> sheets when fetched through getComputedStyle
13070
+ if window url is about:blank, we can assign the url to current by writing onto the document
13071
+ */
13072
+ container.contentWindow.onload = container.onload = function() {
13073
+ var interval = setInterval(function() {
13074
+ if (documentClone.body.childNodes.length > 0) {
13075
+ cloneCanvasContents(ownerDocument, documentClone);
13076
+ clearInterval(interval);
13077
+ if (options.type === "view") {
13078
+ container.contentWindow.scrollTo(x, y);
13079
+ }
13080
+ resolve(container);
13081
+ }
13082
+ }, 50);
13083
+ };
13084
+
13085
+ documentClone.open();
13086
+ documentClone.write("<!DOCTYPE html><html></html>");
13087
+ // Chrome scrolls the parent document for some reason after the write to the cloned window???
13088
+ restoreOwnerScroll(ownerDocument, x, y);
13089
+ documentClone.replaceChild(options.javascriptEnabled === true ? documentClone.adoptNode(documentElement) : removeScriptNodes(documentClone.adoptNode(documentElement)), documentClone.documentElement);
13090
+ documentClone.close();
13091
+ });
13092
+ };
13093
+
13094
+ },{"./log":15,"./promise":18}],5:[function(require,module,exports){
13095
+ // http://dev.w3.org/csswg/css-color/
13096
+
13097
+ function Color(value) {
13098
+ this.r = 0;
13099
+ this.g = 0;
13100
+ this.b = 0;
13101
+ this.a = null;
13102
+ var result = this.fromArray(value) ||
13103
+ this.namedColor(value) ||
13104
+ this.rgb(value) ||
13105
+ this.rgba(value) ||
13106
+ this.hex6(value) ||
13107
+ this.hex3(value);
13108
+ }
13109
+
13110
+ Color.prototype.darken = function(amount) {
13111
+ var a = 1 - amount;
13112
+ return new Color([
13113
+ Math.round(this.r * a),
13114
+ Math.round(this.g * a),
13115
+ Math.round(this.b * a),
13116
+ this.a
13117
+ ]);
13118
+ };
13119
+
13120
+ Color.prototype.isTransparent = function() {
13121
+ return this.a === 0;
13122
+ };
13123
+
13124
+ Color.prototype.isBlack = function() {
13125
+ return this.r === 0 && this.g === 0 && this.b === 0;
13126
+ };
13127
+
13128
+ Color.prototype.fromArray = function(array) {
13129
+ if (Array.isArray(array)) {
13130
+ this.r = Math.min(array[0], 255);
13131
+ this.g = Math.min(array[1], 255);
13132
+ this.b = Math.min(array[2], 255);
13133
+ if (array.length > 3) {
13134
+ this.a = array[3];
13135
+ }
13136
+ }
13137
+
13138
+ return (Array.isArray(array));
13139
+ };
13140
+
13141
+ var _hex3 = /^#([a-f0-9]{3})$/i;
13142
+
13143
+ Color.prototype.hex3 = function(value) {
13144
+ var match = null;
13145
+ if ((match = value.match(_hex3)) !== null) {
13146
+ this.r = parseInt(match[1][0] + match[1][0], 16);
13147
+ this.g = parseInt(match[1][1] + match[1][1], 16);
13148
+ this.b = parseInt(match[1][2] + match[1][2], 16);
13149
+ }
13150
+ return match !== null;
13151
+ };
13152
+
13153
+ var _hex6 = /^#([a-f0-9]{6})$/i;
13154
+
13155
+ Color.prototype.hex6 = function(value) {
13156
+ var match = null;
13157
+ if ((match = value.match(_hex6)) !== null) {
13158
+ this.r = parseInt(match[1].substring(0, 2), 16);
13159
+ this.g = parseInt(match[1].substring(2, 4), 16);
13160
+ this.b = parseInt(match[1].substring(4, 6), 16);
13161
+ }
13162
+ return match !== null;
13163
+ };
13164
+
13165
+
13166
+ var _rgb = /^rgb\((\d{1,3}) *, *(\d{1,3}) *, *(\d{1,3})\)$/;
13167
+
13168
+ Color.prototype.rgb = function(value) {
13169
+ var match = null;
13170
+ if ((match = value.match(_rgb)) !== null) {
13171
+ this.r = Number(match[1]);
13172
+ this.g = Number(match[2]);
13173
+ this.b = Number(match[3]);
13174
+ }
13175
+ return match !== null;
13176
+ };
13177
+
13178
+ var _rgba = /^rgba\((\d{1,3}) *, *(\d{1,3}) *, *(\d{1,3}) *, *(\d+\.?\d*)\)$/;
13179
+
13180
+ Color.prototype.rgba = function(value) {
13181
+ var match = null;
13182
+ if ((match = value.match(_rgba)) !== null) {
13183
+ this.r = Number(match[1]);
13184
+ this.g = Number(match[2]);
13185
+ this.b = Number(match[3]);
13186
+ this.a = Number(match[4]);
13187
+ }
13188
+ return match !== null;
13189
+ };
13190
+
13191
+ Color.prototype.toString = function() {
13192
+ return this.a !== null && this.a !== 1 ?
13193
+ "rgba(" + [this.r, this.g, this.b, this.a].join(",") + ")" :
13194
+ "rgb(" + [this.r, this.g, this.b].join(",") + ")";
13195
+ };
13196
+
13197
+ Color.prototype.namedColor = function(value) {
13198
+ var color = colors[value.toLowerCase()];
13199
+ if (color) {
13200
+ this.r = color[0];
13201
+ this.g = color[1];
13202
+ this.b = color[2];
13203
+ } else if (value.toLowerCase() === "transparent") {
13204
+ this.r = this.g = this.b = this.a = 0;
13205
+ return true;
13206
+ }
13207
+
13208
+ return !!color;
13209
+ };
13210
+
13211
+ Color.prototype.isColor = true;
13212
+
13213
+ // JSON.stringify([].slice.call($$('.named-color-table tr'), 1).map(function(row) { return [row.childNodes[3].textContent, row.childNodes[5].textContent.trim().split(",").map(Number)] }).reduce(function(data, row) {data[row[0]] = row[1]; return data}, {}))
13214
+ var colors = {
13215
+ "aliceblue": [240, 248, 255],
13216
+ "antiquewhite": [250, 235, 215],
13217
+ "aqua": [0, 255, 255],
13218
+ "aquamarine": [127, 255, 212],
13219
+ "azure": [240, 255, 255],
13220
+ "beige": [245, 245, 220],
13221
+ "bisque": [255, 228, 196],
13222
+ "black": [0, 0, 0],
13223
+ "blanchedalmond": [255, 235, 205],
13224
+ "blue": [0, 0, 255],
13225
+ "blueviolet": [138, 43, 226],
13226
+ "brown": [165, 42, 42],
13227
+ "burlywood": [222, 184, 135],
13228
+ "cadetblue": [95, 158, 160],
13229
+ "chartreuse": [127, 255, 0],
13230
+ "chocolate": [210, 105, 30],
13231
+ "coral": [255, 127, 80],
13232
+ "cornflowerblue": [100, 149, 237],
13233
+ "cornsilk": [255, 248, 220],
13234
+ "crimson": [220, 20, 60],
13235
+ "cyan": [0, 255, 255],
13236
+ "darkblue": [0, 0, 139],
13237
+ "darkcyan": [0, 139, 139],
13238
+ "darkgoldenrod": [184, 134, 11],
13239
+ "darkgray": [169, 169, 169],
13240
+ "darkgreen": [0, 100, 0],
13241
+ "darkgrey": [169, 169, 169],
13242
+ "darkkhaki": [189, 183, 107],
13243
+ "darkmagenta": [139, 0, 139],
13244
+ "darkolivegreen": [85, 107, 47],
13245
+ "darkorange": [255, 140, 0],
13246
+ "darkorchid": [153, 50, 204],
13247
+ "darkred": [139, 0, 0],
13248
+ "darksalmon": [233, 150, 122],
13249
+ "darkseagreen": [143, 188, 143],
13250
+ "darkslateblue": [72, 61, 139],
13251
+ "darkslategray": [47, 79, 79],
13252
+ "darkslategrey": [47, 79, 79],
13253
+ "darkturquoise": [0, 206, 209],
13254
+ "darkviolet": [148, 0, 211],
13255
+ "deeppink": [255, 20, 147],
13256
+ "deepskyblue": [0, 191, 255],
13257
+ "dimgray": [105, 105, 105],
13258
+ "dimgrey": [105, 105, 105],
13259
+ "dodgerblue": [30, 144, 255],
13260
+ "firebrick": [178, 34, 34],
13261
+ "floralwhite": [255, 250, 240],
13262
+ "forestgreen": [34, 139, 34],
13263
+ "fuchsia": [255, 0, 255],
13264
+ "gainsboro": [220, 220, 220],
13265
+ "ghostwhite": [248, 248, 255],
13266
+ "gold": [255, 215, 0],
13267
+ "goldenrod": [218, 165, 32],
13268
+ "gray": [128, 128, 128],
13269
+ "green": [0, 128, 0],
13270
+ "greenyellow": [173, 255, 47],
13271
+ "grey": [128, 128, 128],
13272
+ "honeydew": [240, 255, 240],
13273
+ "hotpink": [255, 105, 180],
13274
+ "indianred": [205, 92, 92],
13275
+ "indigo": [75, 0, 130],
13276
+ "ivory": [255, 255, 240],
13277
+ "khaki": [240, 230, 140],
13278
+ "lavender": [230, 230, 250],
13279
+ "lavenderblush": [255, 240, 245],
13280
+ "lawngreen": [124, 252, 0],
13281
+ "lemonchiffon": [255, 250, 205],
13282
+ "lightblue": [173, 216, 230],
13283
+ "lightcoral": [240, 128, 128],
13284
+ "lightcyan": [224, 255, 255],
13285
+ "lightgoldenrodyellow": [250, 250, 210],
13286
+ "lightgray": [211, 211, 211],
13287
+ "lightgreen": [144, 238, 144],
13288
+ "lightgrey": [211, 211, 211],
13289
+ "lightpink": [255, 182, 193],
13290
+ "lightsalmon": [255, 160, 122],
13291
+ "lightseagreen": [32, 178, 170],
13292
+ "lightskyblue": [135, 206, 250],
13293
+ "lightslategray": [119, 136, 153],
13294
+ "lightslategrey": [119, 136, 153],
13295
+ "lightsteelblue": [176, 196, 222],
13296
+ "lightyellow": [255, 255, 224],
13297
+ "lime": [0, 255, 0],
13298
+ "limegreen": [50, 205, 50],
13299
+ "linen": [250, 240, 230],
13300
+ "magenta": [255, 0, 255],
13301
+ "maroon": [128, 0, 0],
13302
+ "mediumaquamarine": [102, 205, 170],
13303
+ "mediumblue": [0, 0, 205],
13304
+ "mediumorchid": [186, 85, 211],
13305
+ "mediumpurple": [147, 112, 219],
13306
+ "mediumseagreen": [60, 179, 113],
13307
+ "mediumslateblue": [123, 104, 238],
13308
+ "mediumspringgreen": [0, 250, 154],
13309
+ "mediumturquoise": [72, 209, 204],
13310
+ "mediumvioletred": [199, 21, 133],
13311
+ "midnightblue": [25, 25, 112],
13312
+ "mintcream": [245, 255, 250],
13313
+ "mistyrose": [255, 228, 225],
13314
+ "moccasin": [255, 228, 181],
13315
+ "navajowhite": [255, 222, 173],
13316
+ "navy": [0, 0, 128],
13317
+ "oldlace": [253, 245, 230],
13318
+ "olive": [128, 128, 0],
13319
+ "olivedrab": [107, 142, 35],
13320
+ "orange": [255, 165, 0],
13321
+ "orangered": [255, 69, 0],
13322
+ "orchid": [218, 112, 214],
13323
+ "palegoldenrod": [238, 232, 170],
13324
+ "palegreen": [152, 251, 152],
13325
+ "paleturquoise": [175, 238, 238],
13326
+ "palevioletred": [219, 112, 147],
13327
+ "papayawhip": [255, 239, 213],
13328
+ "peachpuff": [255, 218, 185],
13329
+ "peru": [205, 133, 63],
13330
+ "pink": [255, 192, 203],
13331
+ "plum": [221, 160, 221],
13332
+ "powderblue": [176, 224, 230],
13333
+ "purple": [128, 0, 128],
13334
+ "rebeccapurple": [102, 51, 153],
13335
+ "red": [255, 0, 0],
13336
+ "rosybrown": [188, 143, 143],
13337
+ "royalblue": [65, 105, 225],
13338
+ "saddlebrown": [139, 69, 19],
13339
+ "salmon": [250, 128, 114],
13340
+ "sandybrown": [244, 164, 96],
13341
+ "seagreen": [46, 139, 87],
13342
+ "seashell": [255, 245, 238],
13343
+ "sienna": [160, 82, 45],
13344
+ "silver": [192, 192, 192],
13345
+ "skyblue": [135, 206, 235],
13346
+ "slateblue": [106, 90, 205],
13347
+ "slategray": [112, 128, 144],
13348
+ "slategrey": [112, 128, 144],
13349
+ "snow": [255, 250, 250],
13350
+ "springgreen": [0, 255, 127],
13351
+ "steelblue": [70, 130, 180],
13352
+ "tan": [210, 180, 140],
13353
+ "teal": [0, 128, 128],
13354
+ "thistle": [216, 191, 216],
13355
+ "tomato": [255, 99, 71],
13356
+ "turquoise": [64, 224, 208],
13357
+ "violet": [238, 130, 238],
13358
+ "wheat": [245, 222, 179],
13359
+ "white": [255, 255, 255],
13360
+ "whitesmoke": [245, 245, 245],
13361
+ "yellow": [255, 255, 0],
13362
+ "yellowgreen": [154, 205, 50]
13363
+ };
13364
+
13365
+ module.exports = Color;
13366
+
13367
+ },{}],6:[function(require,module,exports){
13368
+ var Promise = require('./promise');
13369
+ var Support = require('./support');
13370
+ var CanvasRenderer = require('./renderers/canvas');
13371
+ var ImageLoader = require('./imageloader');
13372
+ var NodeParser = require('./nodeparser');
13373
+ var NodeContainer = require('./nodecontainer');
13374
+ var log = require('./log');
13375
+ var utils = require('./utils');
13376
+ var createWindowClone = require('./clone');
13377
+ var loadUrlDocument = require('./proxy').loadUrlDocument;
13378
+ var getBounds = utils.getBounds;
13379
+
13380
+ var html2canvasNodeAttribute = "data-html2canvas-node";
13381
+ var html2canvasCloneIndex = 0;
13382
+
13383
+ function html2canvas(nodeList, options) {
13384
+ var index = html2canvasCloneIndex++;
13385
+ options = options || {};
13386
+ if (options.logging) {
13387
+ window.html2canvas.logging = true;
13388
+ window.html2canvas.start = Date.now();
13389
+ }
13390
+
13391
+ options.async = typeof(options.async) === "undefined" ? true : options.async;
13392
+ options.allowTaint = typeof(options.allowTaint) === "undefined" ? false : options.allowTaint;
13393
+ options.removeContainer = typeof(options.removeContainer) === "undefined" ? true : options.removeContainer;
13394
+ options.javascriptEnabled = typeof(options.javascriptEnabled) === "undefined" ? false : options.javascriptEnabled;
13395
+ options.imageTimeout = typeof(options.imageTimeout) === "undefined" ? 10000 : options.imageTimeout;
13396
+ options.renderer = typeof(options.renderer) === "function" ? options.renderer : CanvasRenderer;
13397
+ options.strict = !!options.strict;
13398
+
13399
+ if (typeof(nodeList) === "string") {
13400
+ if (typeof(options.proxy) !== "string") {
13401
+ return Promise.reject("Proxy must be used when rendering url");
13402
+ }
13403
+ var width = options.width != null ? options.width : window.innerWidth;
13404
+ var height = options.height != null ? options.height : window.innerHeight;
13405
+ return loadUrlDocument(absoluteUrl(nodeList), options.proxy, document, width, height, options).then(function(container) {
13406
+ return renderWindow(container.contentWindow.document.documentElement, container, options, width, height);
13407
+ });
13408
+ }
13409
+
13410
+ var node = ((nodeList === undefined) ? [document.documentElement] : ((nodeList.length) ? nodeList : [nodeList]))[0];
13411
+ node.setAttribute(html2canvasNodeAttribute + index, index);
13412
+ return renderDocument(node.ownerDocument, options, node.ownerDocument.defaultView.innerWidth, node.ownerDocument.defaultView.innerHeight, index).then(function(canvas) {
13413
+ if (typeof(options.onrendered) === "function") {
13414
+ log("options.onrendered is deprecated, html2canvas returns a Promise containing the canvas");
13415
+ options.onrendered(canvas);
13416
+ }
13417
+ return canvas;
13418
+ });
13419
+ }
13420
+
13421
+ html2canvas.Promise = Promise;
13422
+ html2canvas.CanvasRenderer = CanvasRenderer;
13423
+ html2canvas.NodeContainer = NodeContainer;
13424
+ html2canvas.log = log;
13425
+ html2canvas.utils = utils;
13426
+
13427
+ module.exports = (typeof(document) === "undefined" || typeof(Object.create) !== "function" || typeof(document.createElement("canvas").getContext) !== "function") ? function() {
13428
+ return Promise.reject("No canvas support");
13429
+ } : html2canvas;
13430
+
13431
+ function renderDocument(document, options, windowWidth, windowHeight, html2canvasIndex) {
13432
+ return createWindowClone(document, document, windowWidth, windowHeight, options, document.defaultView.pageXOffset, document.defaultView.pageYOffset).then(function(container) {
13433
+ log("Document cloned");
13434
+ var attributeName = html2canvasNodeAttribute + html2canvasIndex;
13435
+ var selector = "[" + attributeName + "='" + html2canvasIndex + "']";
13436
+ document.querySelector(selector).removeAttribute(attributeName);
13437
+ var clonedWindow = container.contentWindow;
13438
+ var node = clonedWindow.document.querySelector(selector);
13439
+ var oncloneHandler = (typeof(options.onclone) === "function") ? Promise.resolve(options.onclone(clonedWindow.document)) : Promise.resolve(true);
13440
+ return oncloneHandler.then(function() {
13441
+ return renderWindow(node, container, options, windowWidth, windowHeight);
13442
+ });
13443
+ });
13444
+ }
13445
+
13446
+ function renderWindow(node, container, options, windowWidth, windowHeight) {
13447
+ var clonedWindow = container.contentWindow;
13448
+ var support = new Support(clonedWindow.document);
13449
+ var imageLoader = new ImageLoader(options, support);
13450
+ var bounds = getBounds(node);
13451
+ var width = options.type === "view" ? windowWidth : documentWidth(clonedWindow.document);
13452
+ var height = options.type === "view" ? windowHeight : documentHeight(clonedWindow.document);
13453
+ var renderer = new options.renderer(width, height, imageLoader, options, document);
13454
+ var parser = new NodeParser(node, renderer, support, imageLoader, options);
13455
+ return parser.ready.then(function() {
13456
+ log("Finished rendering");
13457
+ var canvas;
13458
+
13459
+ if (options.type === "view") {
13460
+ canvas = crop(renderer.canvas, {width: renderer.canvas.width, height: renderer.canvas.height, top: 0, left: 0, x: 0, y: 0});
13461
+ } else if (node === clonedWindow.document.body || node === clonedWindow.document.documentElement || options.canvas != null) {
13462
+ canvas = renderer.canvas;
13463
+ } else {
13464
+ canvas = crop(renderer.canvas, {width: options.width != null ? options.width : bounds.width, height: options.height != null ? options.height : bounds.height, top: bounds.top, left: bounds.left, x: clonedWindow.pageXOffset, y: clonedWindow.pageYOffset});
13465
+ }
13466
+
13467
+ cleanupContainer(container, options);
13468
+ return canvas;
13469
+ });
13470
+ }
13471
+
13472
+ function cleanupContainer(container, options) {
13473
+ if (options.removeContainer) {
13474
+ container.parentNode.removeChild(container);
13475
+ log("Cleaned up container");
13476
+ }
13477
+ }
13478
+
13479
+ function crop(canvas, bounds) {
13480
+ var croppedCanvas = document.createElement("canvas");
13481
+ var x1 = Math.min(canvas.width - 1, Math.max(0, bounds.left));
13482
+ var x2 = Math.min(canvas.width, Math.max(1, bounds.left + bounds.width));
13483
+ var y1 = Math.min(canvas.height - 1, Math.max(0, bounds.top));
13484
+ var y2 = Math.min(canvas.height, Math.max(1, bounds.top + bounds.height));
13485
+ croppedCanvas.width = bounds.width;
13486
+ croppedCanvas.height = bounds.height;
13487
+ log("Cropping canvas at:", "left:", bounds.left, "top:", bounds.top, "width:", (x2-x1), "height:", (y2-y1));
13488
+ log("Resulting crop with width", bounds.width, "and height", bounds.height, " with x", x1, "and y", y1);
13489
+ croppedCanvas.getContext("2d").drawImage(canvas, x1, y1, x2-x1, y2-y1, bounds.x, bounds.y, x2-x1, y2-y1);
13490
+ return croppedCanvas;
13491
+ }
13492
+
13493
+ function documentWidth (doc) {
13494
+ return Math.max(
13495
+ Math.max(doc.body.scrollWidth, doc.documentElement.scrollWidth),
13496
+ Math.max(doc.body.offsetWidth, doc.documentElement.offsetWidth),
13497
+ Math.max(doc.body.clientWidth, doc.documentElement.clientWidth)
13498
+ );
13499
+ }
13500
+
13501
+ function documentHeight (doc) {
13502
+ return Math.max(
13503
+ Math.max(doc.body.scrollHeight, doc.documentElement.scrollHeight),
13504
+ Math.max(doc.body.offsetHeight, doc.documentElement.offsetHeight),
13505
+ Math.max(doc.body.clientHeight, doc.documentElement.clientHeight)
13506
+ );
13507
+ }
13508
+
13509
+ function absoluteUrl(url) {
13510
+ var link = document.createElement("a");
13511
+ link.href = url;
13512
+ link.href = link.href;
13513
+ return link;
13514
+ }
13515
+
13516
+ },{"./clone":4,"./imageloader":13,"./log":15,"./nodecontainer":16,"./nodeparser":17,"./promise":18,"./proxy":19,"./renderers/canvas":23,"./support":25,"./utils":29}],7:[function(require,module,exports){
13517
+ var Promise = require('./promise');
13518
+ var log = require('./log');
13519
+ var smallImage = require('./utils').smallImage;
13520
+
13521
+ function DummyImageContainer(src) {
13522
+ this.src = src;
13523
+ log("DummyImageContainer for", src);
13524
+ if (!this.promise || !this.image) {
13525
+ log("Initiating DummyImageContainer");
13526
+ DummyImageContainer.prototype.image = new Image();
13527
+ var image = this.image;
13528
+ DummyImageContainer.prototype.promise = new Promise(function(resolve, reject) {
13529
+ image.onload = resolve;
13530
+ image.onerror = reject;
13531
+ image.src = smallImage();
13532
+ if (image.complete === true) {
13533
+ resolve(image);
13534
+ }
13535
+ });
13536
+ }
13537
+ }
13538
+
13539
+ module.exports = DummyImageContainer;
13540
+
13541
+ },{"./log":15,"./promise":18,"./utils":29}],8:[function(require,module,exports){
13542
+ var smallImage = require('./utils').smallImage;
13543
+
13544
+ function Font(family, size) {
13545
+ var container = document.createElement('div'),
13546
+ img = document.createElement('img'),
13547
+ span = document.createElement('span'),
13548
+ sampleText = 'Hidden Text',
13549
+ baseline,
13550
+ middle;
13551
+
13552
+ container.style.visibility = "hidden";
13553
+ container.style.fontFamily = family;
13554
+ container.style.fontSize = size;
13555
+ container.style.margin = 0;
13556
+ container.style.padding = 0;
13557
+
13558
+ document.body.appendChild(container);
13559
+
13560
+ img.src = smallImage();
13561
+ img.width = 1;
13562
+ img.height = 1;
13563
+
13564
+ img.style.margin = 0;
13565
+ img.style.padding = 0;
13566
+ img.style.verticalAlign = "baseline";
13567
+
13568
+ span.style.fontFamily = family;
13569
+ span.style.fontSize = size;
13570
+ span.style.margin = 0;
13571
+ span.style.padding = 0;
13572
+
13573
+ span.appendChild(document.createTextNode(sampleText));
13574
+ container.appendChild(span);
13575
+ container.appendChild(img);
13576
+ baseline = (img.offsetTop - span.offsetTop) + 1;
13577
+
13578
+ container.removeChild(span);
13579
+ container.appendChild(document.createTextNode(sampleText));
13580
+
13581
+ container.style.lineHeight = "normal";
13582
+ img.style.verticalAlign = "super";
13583
+
13584
+ middle = (img.offsetTop-container.offsetTop) + 1;
13585
+
13586
+ document.body.removeChild(container);
13587
+
13588
+ this.baseline = baseline;
13589
+ this.lineWidth = 1;
13590
+ this.middle = middle;
13591
+ }
13592
+
13593
+ module.exports = Font;
13594
+
13595
+ },{"./utils":29}],9:[function(require,module,exports){
13596
+ var Font = require('./font');
13597
+
13598
+ function FontMetrics() {
13599
+ this.data = {};
13600
+ }
13601
+
13602
+ FontMetrics.prototype.getMetrics = function(family, size) {
13603
+ if (this.data[family + "-" + size] === undefined) {
13604
+ this.data[family + "-" + size] = new Font(family, size);
13605
+ }
13606
+ return this.data[family + "-" + size];
13607
+ };
13608
+
13609
+ module.exports = FontMetrics;
13610
+
13611
+ },{"./font":8}],10:[function(require,module,exports){
13612
+ var utils = require('./utils');
13613
+ var Promise = require('./promise');
13614
+ var getBounds = utils.getBounds;
13615
+ var loadUrlDocument = require('./proxy').loadUrlDocument;
13616
+
13617
+ function FrameContainer(container, sameOrigin, options) {
13618
+ this.image = null;
13619
+ this.src = container;
13620
+ var self = this;
13621
+ var bounds = getBounds(container);
13622
+ this.promise = (!sameOrigin ? this.proxyLoad(options.proxy, bounds, options) : new Promise(function(resolve) {
13623
+ if (container.contentWindow.document.URL === "about:blank" || container.contentWindow.document.documentElement == null) {
13624
+ container.contentWindow.onload = container.onload = function() {
13625
+ resolve(container);
13626
+ };
13627
+ } else {
13628
+ resolve(container);
13629
+ }
13630
+ })).then(function(container) {
13631
+ var html2canvas = require('./core');
13632
+ return html2canvas(container.contentWindow.document.documentElement, {type: 'view', width: container.width, height: container.height, proxy: options.proxy, javascriptEnabled: options.javascriptEnabled, removeContainer: options.removeContainer, allowTaint: options.allowTaint, imageTimeout: options.imageTimeout / 2});
13633
+ }).then(function(canvas) {
13634
+ return self.image = canvas;
13635
+ });
13636
+ }
13637
+
13638
+ FrameContainer.prototype.proxyLoad = function(proxy, bounds, options) {
13639
+ var container = this.src;
13640
+ return loadUrlDocument(container.src, proxy, container.ownerDocument, bounds.width, bounds.height, options);
13641
+ };
13642
+
13643
+ module.exports = FrameContainer;
13644
+
13645
+ },{"./core":6,"./promise":18,"./proxy":19,"./utils":29}],11:[function(require,module,exports){
13646
+ var Promise = require('./promise');
13647
+
13648
+ function GradientContainer(imageData) {
13649
+ this.src = imageData.value;
13650
+ this.colorStops = [];
13651
+ this.type = null;
13652
+ this.x0 = 0.5;
13653
+ this.y0 = 0.5;
13654
+ this.x1 = 0.5;
13655
+ this.y1 = 0.5;
13656
+ this.promise = Promise.resolve(true);
13657
+ }
13658
+
13659
+ GradientContainer.prototype.TYPES = {
13660
+ LINEAR: 1,
13661
+ RADIAL: 2
13662
+ };
13663
+
13664
+ module.exports = GradientContainer;
13665
+
13666
+ },{"./promise":18}],12:[function(require,module,exports){
13667
+ var Promise = require('./promise');
13668
+
13669
+ function ImageContainer(src, cors) {
13670
+ this.src = src;
13671
+ this.image = new Image();
13672
+ var self = this;
13673
+ this.tainted = null;
13674
+ this.promise = new Promise(function(resolve, reject) {
13675
+ self.image.onload = resolve;
13676
+ self.image.onerror = reject;
13677
+ if (cors) {
13678
+ self.image.crossOrigin = "anonymous";
13679
+ }
13680
+ self.image.src = src;
13681
+ if (self.image.complete === true) {
13682
+ resolve(self.image);
13683
+ }
13684
+ });
13685
+ }
13686
+
13687
+ module.exports = ImageContainer;
13688
+
13689
+ },{"./promise":18}],13:[function(require,module,exports){
13690
+ var Promise = require('./promise');
13691
+ var log = require('./log');
13692
+ var ImageContainer = require('./imagecontainer');
13693
+ var DummyImageContainer = require('./dummyimagecontainer');
13694
+ var ProxyImageContainer = require('./proxyimagecontainer');
13695
+ var FrameContainer = require('./framecontainer');
13696
+ var SVGContainer = require('./svgcontainer');
13697
+ var SVGNodeContainer = require('./svgnodecontainer');
13698
+ var LinearGradientContainer = require('./lineargradientcontainer');
13699
+ var WebkitGradientContainer = require('./webkitgradientcontainer');
13700
+ var bind = require('./utils').bind;
13701
+
13702
+ function ImageLoader(options, support) {
13703
+ this.link = null;
13704
+ this.options = options;
13705
+ this.support = support;
13706
+ this.origin = this.getOrigin(window.location.href);
13707
+ }
13708
+
13709
+ ImageLoader.prototype.findImages = function(nodes) {
13710
+ var images = [];
13711
+ nodes.reduce(function(imageNodes, container) {
13712
+ switch(container.node.nodeName) {
13713
+ case "IMG":
13714
+ return imageNodes.concat([{
13715
+ args: [container.node.src],
13716
+ method: "url"
13717
+ }]);
13718
+ case "svg":
13719
+ case "IFRAME":
13720
+ return imageNodes.concat([{
13721
+ args: [container.node],
13722
+ method: container.node.nodeName
13723
+ }]);
13724
+ }
13725
+ return imageNodes;
13726
+ }, []).forEach(this.addImage(images, this.loadImage), this);
13727
+ return images;
13728
+ };
13729
+
13730
+ ImageLoader.prototype.findBackgroundImage = function(images, container) {
13731
+ container.parseBackgroundImages().filter(this.hasImageBackground).forEach(this.addImage(images, this.loadImage), this);
13732
+ return images;
13733
+ };
13734
+
13735
+ ImageLoader.prototype.addImage = function(images, callback) {
13736
+ return function(newImage) {
13737
+ newImage.args.forEach(function(image) {
13738
+ if (!this.imageExists(images, image)) {
13739
+ images.splice(0, 0, callback.call(this, newImage));
13740
+ log('Added image #' + (images.length), typeof(image) === "string" ? image.substring(0, 100) : image);
13741
+ }
13742
+ }, this);
13743
+ };
13744
+ };
13745
+
13746
+ ImageLoader.prototype.hasImageBackground = function(imageData) {
13747
+ return imageData.method !== "none";
13748
+ };
13749
+
13750
+ ImageLoader.prototype.loadImage = function(imageData) {
13751
+ if (imageData.method === "url") {
13752
+ var src = imageData.args[0];
13753
+ if (this.isSVG(src) && !this.support.svg && !this.options.allowTaint) {
13754
+ return new SVGContainer(src);
13755
+ } else if (src.match(/data:image\/.*;base64,/i)) {
13756
+ return new ImageContainer(src.replace(/url\(['"]{0,}|['"]{0,}\)$/ig, ''), false);
13757
+ } else if (this.isSameOrigin(src) || this.options.allowTaint === true || this.isSVG(src)) {
13758
+ return new ImageContainer(src, false);
13759
+ } else if (this.support.cors && !this.options.allowTaint && this.options.useCORS) {
13760
+ return new ImageContainer(src, true);
13761
+ } else if (this.options.proxy) {
13762
+ return new ProxyImageContainer(src, this.options.proxy);
13763
+ } else {
13764
+ return new DummyImageContainer(src);
13765
+ }
13766
+ } else if (imageData.method === "linear-gradient") {
13767
+ return new LinearGradientContainer(imageData);
13768
+ } else if (imageData.method === "gradient") {
13769
+ return new WebkitGradientContainer(imageData);
13770
+ } else if (imageData.method === "svg") {
13771
+ return new SVGNodeContainer(imageData.args[0], this.support.svg);
13772
+ } else if (imageData.method === "IFRAME") {
13773
+ return new FrameContainer(imageData.args[0], this.isSameOrigin(imageData.args[0].src), this.options);
13774
+ } else {
13775
+ return new DummyImageContainer(imageData);
13776
+ }
13777
+ };
13778
+
13779
+ ImageLoader.prototype.isSVG = function(src) {
13780
+ return src.substring(src.length - 3).toLowerCase() === "svg" || SVGContainer.prototype.isInline(src);
13781
+ };
13782
+
13783
+ ImageLoader.prototype.imageExists = function(images, src) {
13784
+ return images.some(function(image) {
13785
+ return image.src === src;
13786
+ });
13787
+ };
13788
+
13789
+ ImageLoader.prototype.isSameOrigin = function(url) {
13790
+ return (this.getOrigin(url) === this.origin);
13791
+ };
13792
+
13793
+ ImageLoader.prototype.getOrigin = function(url) {
13794
+ var link = this.link || (this.link = document.createElement("a"));
13795
+ link.href = url;
13796
+ link.href = link.href; // IE9, LOL! - http://jsfiddle.net/niklasvh/2e48b/
13797
+ return link.protocol + link.hostname + link.port;
13798
+ };
13799
+
13800
+ ImageLoader.prototype.getPromise = function(container) {
13801
+ return this.timeout(container, this.options.imageTimeout)['catch'](function() {
13802
+ var dummy = new DummyImageContainer(container.src);
13803
+ return dummy.promise.then(function(image) {
13804
+ container.image = image;
13805
+ });
13806
+ });
13807
+ };
13808
+
13809
+ ImageLoader.prototype.get = function(src) {
13810
+ var found = null;
13811
+ return this.images.some(function(img) {
13812
+ return (found = img).src === src;
13813
+ }) ? found : null;
13814
+ };
13815
+
13816
+ ImageLoader.prototype.fetch = function(nodes) {
13817
+ this.images = nodes.reduce(bind(this.findBackgroundImage, this), this.findImages(nodes));
13818
+ this.images.forEach(function(image, index) {
13819
+ image.promise.then(function() {
13820
+ log("Succesfully loaded image #"+ (index+1), image);
13821
+ }, function(e) {
13822
+ log("Failed loading image #"+ (index+1), image, e);
13823
+ });
13824
+ });
13825
+ this.ready = Promise.all(this.images.map(this.getPromise, this));
13826
+ log("Finished searching images");
13827
+ return this;
13828
+ };
13829
+
13830
+ ImageLoader.prototype.timeout = function(container, timeout) {
13831
+ var timer;
13832
+ var promise = Promise.race([container.promise, new Promise(function(res, reject) {
13833
+ timer = setTimeout(function() {
13834
+ log("Timed out loading image", container);
13835
+ reject(container);
13836
+ }, timeout);
13837
+ })]).then(function(container) {
13838
+ clearTimeout(timer);
13839
+ return container;
13840
+ });
13841
+ promise['catch'](function() {
13842
+ clearTimeout(timer);
13843
+ });
13844
+ return promise;
13845
+ };
13846
+
13847
+ module.exports = ImageLoader;
13848
+
13849
+ },{"./dummyimagecontainer":7,"./framecontainer":10,"./imagecontainer":12,"./lineargradientcontainer":14,"./log":15,"./promise":18,"./proxyimagecontainer":20,"./svgcontainer":26,"./svgnodecontainer":27,"./utils":29,"./webkitgradientcontainer":30}],14:[function(require,module,exports){
13850
+ var GradientContainer = require('./gradientcontainer');
13851
+ var Color = require('./color');
13852
+
13853
+ function LinearGradientContainer(imageData) {
13854
+ GradientContainer.apply(this, arguments);
13855
+ this.type = this.TYPES.LINEAR;
13856
+
13857
+ var hasDirection = imageData.args[0].match(this.stepRegExp) === null;
13858
+
13859
+ if (hasDirection) {
13860
+ imageData.args[0].split(" ").reverse().forEach(function(position) {
13861
+ switch(position) {
13862
+ case "left":
13863
+ this.x0 = 0;
13864
+ this.x1 = 1;
13865
+ break;
13866
+ case "top":
13867
+ this.y0 = 0;
13868
+ this.y1 = 1;
13869
+ break;
13870
+ case "right":
13871
+ this.x0 = 1;
13872
+ this.x1 = 0;
13873
+ break;
13874
+ case "bottom":
13875
+ this.y0 = 1;
13876
+ this.y1 = 0;
13877
+ break;
13878
+ case "to":
13879
+ var y0 = this.y0;
13880
+ var x0 = this.x0;
13881
+ this.y0 = this.y1;
13882
+ this.x0 = this.x1;
13883
+ this.x1 = x0;
13884
+ this.y1 = y0;
13885
+ break;
13886
+ }
13887
+ }, this);
13888
+ } else {
13889
+ this.y0 = 0;
13890
+ this.y1 = 1;
13891
+ }
13892
+
13893
+ this.colorStops = imageData.args.slice(hasDirection ? 1 : 0).map(function(colorStop) {
13894
+ var colorStopMatch = colorStop.match(this.stepRegExp);
13895
+ return {
13896
+ color: new Color(colorStopMatch[1]),
13897
+ stop: colorStopMatch[3] === "%" ? colorStopMatch[2] / 100 : null
13898
+ };
13899
+ }, this);
13900
+
13901
+ if (this.colorStops[0].stop === null) {
13902
+ this.colorStops[0].stop = 0;
13903
+ }
13904
+
13905
+ if (this.colorStops[this.colorStops.length - 1].stop === null) {
13906
+ this.colorStops[this.colorStops.length - 1].stop = 1;
13907
+ }
13908
+
13909
+ this.colorStops.forEach(function(colorStop, index) {
13910
+ if (colorStop.stop === null) {
13911
+ this.colorStops.slice(index).some(function(find, count) {
13912
+ if (find.stop !== null) {
13913
+ colorStop.stop = ((find.stop - this.colorStops[index - 1].stop) / (count + 1)) + this.colorStops[index - 1].stop;
13914
+ return true;
13915
+ } else {
13916
+ return false;
13917
+ }
13918
+ }, this);
13919
+ }
13920
+ }, this);
13921
+ }
13922
+
13923
+ LinearGradientContainer.prototype = Object.create(GradientContainer.prototype);
13924
+
13925
+ LinearGradientContainer.prototype.stepRegExp = /((?:rgb|rgba)\(\d{1,3},\s\d{1,3},\s\d{1,3}(?:,\s[0-9\.]+)?\))\s*(\d{1,3})?(%|px)?/;
13926
+
13927
+ module.exports = LinearGradientContainer;
13928
+
13929
+ },{"./color":5,"./gradientcontainer":11}],15:[function(require,module,exports){
13930
+ module.exports = function() {
13931
+ if (window.html2canvas.logging && window.console && window.console.log) {
13932
+ Function.prototype.bind.call(window.console.log, (window.console)).apply(window.console, [(Date.now() - window.html2canvas.start) + "ms", "html2canvas:"].concat([].slice.call(arguments, 0)));
13933
+ }
13934
+ };
13935
+
13936
+ },{}],16:[function(require,module,exports){
13937
+ var Color = require('./color');
13938
+ var utils = require('./utils');
13939
+ var getBounds = utils.getBounds;
13940
+ var parseBackgrounds = utils.parseBackgrounds;
13941
+ var offsetBounds = utils.offsetBounds;
13942
+
13943
+ function NodeContainer(node, parent) {
13944
+ this.node = node;
13945
+ this.parent = parent;
13946
+ this.stack = null;
13947
+ this.bounds = null;
13948
+ this.borders = null;
13949
+ this.clip = [];
13950
+ this.backgroundClip = [];
13951
+ this.offsetBounds = null;
13952
+ this.visible = null;
13953
+ this.computedStyles = null;
13954
+ this.colors = {};
13955
+ this.styles = {};
13956
+ this.backgroundImages = null;
13957
+ this.transformData = null;
13958
+ this.transformMatrix = null;
13959
+ this.isPseudoElement = false;
13960
+ this.opacity = null;
13961
+ }
13962
+
13963
+ NodeContainer.prototype.cloneTo = function(stack) {
13964
+ stack.visible = this.visible;
13965
+ stack.borders = this.borders;
13966
+ stack.bounds = this.bounds;
13967
+ stack.clip = this.clip;
13968
+ stack.backgroundClip = this.backgroundClip;
13969
+ stack.computedStyles = this.computedStyles;
13970
+ stack.styles = this.styles;
13971
+ stack.backgroundImages = this.backgroundImages;
13972
+ stack.opacity = this.opacity;
13973
+ };
13974
+
13975
+ NodeContainer.prototype.getOpacity = function() {
13976
+ return this.opacity === null ? (this.opacity = this.cssFloat('opacity')) : this.opacity;
13977
+ };
13978
+
13979
+ NodeContainer.prototype.assignStack = function(stack) {
13980
+ this.stack = stack;
13981
+ stack.children.push(this);
13982
+ };
13983
+
13984
+ NodeContainer.prototype.isElementVisible = function() {
13985
+ return this.node.nodeType === Node.TEXT_NODE ? this.parent.visible : (
13986
+ this.css('display') !== "none" &&
13987
+ this.css('visibility') !== "hidden" &&
13988
+ !this.node.hasAttribute("data-html2canvas-ignore") &&
13989
+ (this.node.nodeName !== "INPUT" || this.node.getAttribute("type") !== "hidden")
13990
+ );
13991
+ };
13992
+
13993
+ NodeContainer.prototype.css = function(attribute) {
13994
+ if (!this.computedStyles) {
13995
+ this.computedStyles = this.isPseudoElement ? this.parent.computedStyle(this.before ? ":before" : ":after") : this.computedStyle(null);
13996
+ }
13997
+
13998
+ return this.styles[attribute] || (this.styles[attribute] = this.computedStyles[attribute]);
13999
+ };
14000
+
14001
+ NodeContainer.prototype.prefixedCss = function(attribute) {
14002
+ var prefixes = ["webkit", "moz", "ms", "o"];
14003
+ var value = this.css(attribute);
14004
+ if (value === undefined) {
14005
+ prefixes.some(function(prefix) {
14006
+ value = this.css(prefix + attribute.substr(0, 1).toUpperCase() + attribute.substr(1));
14007
+ return value !== undefined;
14008
+ }, this);
14009
+ }
14010
+ return value === undefined ? null : value;
14011
+ };
14012
+
14013
+ NodeContainer.prototype.computedStyle = function(type) {
14014
+ return this.node.ownerDocument.defaultView.getComputedStyle(this.node, type);
14015
+ };
14016
+
14017
+ NodeContainer.prototype.cssInt = function(attribute) {
14018
+ var value = parseInt(this.css(attribute), 10);
14019
+ return (isNaN(value)) ? 0 : value; // borders in old IE are throwing 'medium' for demo.html
14020
+ };
14021
+
14022
+ NodeContainer.prototype.color = function(attribute) {
14023
+ return this.colors[attribute] || (this.colors[attribute] = new Color(this.css(attribute)));
14024
+ };
14025
+
14026
+ NodeContainer.prototype.cssFloat = function(attribute) {
14027
+ var value = parseFloat(this.css(attribute));
14028
+ return (isNaN(value)) ? 0 : value;
14029
+ };
14030
+
14031
+ NodeContainer.prototype.fontWeight = function() {
14032
+ var weight = this.css("fontWeight");
14033
+ switch(parseInt(weight, 10)){
14034
+ case 401:
14035
+ weight = "bold";
14036
+ break;
14037
+ case 400:
14038
+ weight = "normal";
14039
+ break;
14040
+ }
14041
+ return weight;
14042
+ };
14043
+
14044
+ NodeContainer.prototype.parseClip = function() {
14045
+ var matches = this.css('clip').match(this.CLIP);
14046
+ if (matches) {
14047
+ return {
14048
+ top: parseInt(matches[1], 10),
14049
+ right: parseInt(matches[2], 10),
14050
+ bottom: parseInt(matches[3], 10),
14051
+ left: parseInt(matches[4], 10)
14052
+ };
14053
+ }
14054
+ return null;
14055
+ };
14056
+
14057
+ NodeContainer.prototype.parseBackgroundImages = function() {
14058
+ return this.backgroundImages || (this.backgroundImages = parseBackgrounds(this.css("backgroundImage")));
14059
+ };
14060
+
14061
+ NodeContainer.prototype.cssList = function(property, index) {
14062
+ var value = (this.css(property) || '').split(',');
14063
+ value = value[index || 0] || value[0] || 'auto';
14064
+ value = value.trim().split(' ');
14065
+ if (value.length === 1) {
14066
+ value = [value[0], isPercentage(value[0]) ? 'auto' : value[0]];
14067
+ }
14068
+ return value;
14069
+ };
14070
+
14071
+ NodeContainer.prototype.parseBackgroundSize = function(bounds, image, index) {
14072
+ var size = this.cssList("backgroundSize", index);
14073
+ var width, height;
14074
+
14075
+ if (isPercentage(size[0])) {
14076
+ width = bounds.width * parseFloat(size[0]) / 100;
14077
+ } else if (/contain|cover/.test(size[0])) {
14078
+ var targetRatio = bounds.width / bounds.height, currentRatio = image.width / image.height;
14079
+ return (targetRatio < currentRatio ^ size[0] === 'contain') ? {width: bounds.height * currentRatio, height: bounds.height} : {width: bounds.width, height: bounds.width / currentRatio};
14080
+ } else {
14081
+ width = parseInt(size[0], 10);
14082
+ }
14083
+
14084
+ if (size[0] === 'auto' && size[1] === 'auto') {
14085
+ height = image.height;
14086
+ } else if (size[1] === 'auto') {
14087
+ height = width / image.width * image.height;
14088
+ } else if (isPercentage(size[1])) {
14089
+ height = bounds.height * parseFloat(size[1]) / 100;
14090
+ } else {
14091
+ height = parseInt(size[1], 10);
14092
+ }
14093
+
14094
+ if (size[0] === 'auto') {
14095
+ width = height / image.height * image.width;
14096
+ }
14097
+
14098
+ return {width: width, height: height};
14099
+ };
14100
+
14101
+ NodeContainer.prototype.parseBackgroundPosition = function(bounds, image, index, backgroundSize) {
14102
+ var position = this.cssList('backgroundPosition', index);
14103
+ var left, top;
14104
+
14105
+ if (isPercentage(position[0])){
14106
+ left = (bounds.width - (backgroundSize || image).width) * (parseFloat(position[0]) / 100);
14107
+ } else {
14108
+ left = parseInt(position[0], 10);
14109
+ }
14110
+
14111
+ if (position[1] === 'auto') {
14112
+ top = left / image.width * image.height;
14113
+ } else if (isPercentage(position[1])){
14114
+ top = (bounds.height - (backgroundSize || image).height) * parseFloat(position[1]) / 100;
14115
+ } else {
14116
+ top = parseInt(position[1], 10);
14117
+ }
14118
+
14119
+ if (position[0] === 'auto') {
14120
+ left = top / image.height * image.width;
14121
+ }
14122
+
14123
+ return {left: left, top: top};
14124
+ };
14125
+
14126
+ NodeContainer.prototype.parseBackgroundRepeat = function(index) {
14127
+ return this.cssList("backgroundRepeat", index)[0];
14128
+ };
14129
+
14130
+ NodeContainer.prototype.parseTextShadows = function() {
14131
+ var textShadow = this.css("textShadow");
14132
+ var results = [];
14133
+
14134
+ if (textShadow && textShadow !== 'none') {
14135
+ var shadows = textShadow.match(this.TEXT_SHADOW_PROPERTY);
14136
+ for (var i = 0; shadows && (i < shadows.length); i++) {
14137
+ var s = shadows[i].match(this.TEXT_SHADOW_VALUES);
14138
+ results.push({
14139
+ color: new Color(s[0]),
14140
+ offsetX: s[1] ? parseFloat(s[1].replace('px', '')) : 0,
14141
+ offsetY: s[2] ? parseFloat(s[2].replace('px', '')) : 0,
14142
+ blur: s[3] ? s[3].replace('px', '') : 0
14143
+ });
14144
+ }
14145
+ }
14146
+ return results;
14147
+ };
14148
+
14149
+ NodeContainer.prototype.parseTransform = function() {
14150
+ if (!this.transformData) {
14151
+ if (this.hasTransform()) {
14152
+ var offset = this.parseBounds();
14153
+ var origin = this.prefixedCss("transformOrigin").split(" ").map(removePx).map(asFloat);
14154
+ origin[0] += offset.left;
14155
+ origin[1] += offset.top;
14156
+ this.transformData = {
14157
+ origin: origin,
14158
+ matrix: this.parseTransformMatrix()
14159
+ };
14160
+ } else {
14161
+ this.transformData = {
14162
+ origin: [0, 0],
14163
+ matrix: [1, 0, 0, 1, 0, 0]
14164
+ };
14165
+ }
14166
+ }
14167
+ return this.transformData;
14168
+ };
14169
+
14170
+ NodeContainer.prototype.parseTransformMatrix = function() {
14171
+ if (!this.transformMatrix) {
14172
+ var transform = this.prefixedCss("transform");
14173
+ var matrix = transform ? parseMatrix(transform.match(this.MATRIX_PROPERTY)) : null;
14174
+ this.transformMatrix = matrix ? matrix : [1, 0, 0, 1, 0, 0];
14175
+ }
14176
+ return this.transformMatrix;
14177
+ };
14178
+
14179
+ NodeContainer.prototype.parseBounds = function() {
14180
+ return this.bounds || (this.bounds = this.hasTransform() ? offsetBounds(this.node) : getBounds(this.node));
14181
+ };
14182
+
14183
+ NodeContainer.prototype.hasTransform = function() {
14184
+ return this.parseTransformMatrix().join(",") !== "1,0,0,1,0,0" || (this.parent && this.parent.hasTransform());
14185
+ };
14186
+
14187
+ NodeContainer.prototype.getValue = function() {
14188
+ var value = this.node.value || "";
14189
+ if (this.node.tagName === "SELECT") {
14190
+ value = selectionValue(this.node);
14191
+ } else if (this.node.type === "password") {
14192
+ value = Array(value.length + 1).join('\u2022'); // jshint ignore:line
14193
+ }
14194
+ return value.length === 0 ? (this.node.placeholder || "") : value;
14195
+ };
14196
+
14197
+ NodeContainer.prototype.MATRIX_PROPERTY = /(matrix)\((.+)\)/;
14198
+ NodeContainer.prototype.TEXT_SHADOW_PROPERTY = /((rgba|rgb)\([^\)]+\)(\s-?\d+px){0,})/g;
14199
+ NodeContainer.prototype.TEXT_SHADOW_VALUES = /(-?\d+px)|(#.+)|(rgb\(.+\))|(rgba\(.+\))/g;
14200
+ NodeContainer.prototype.CLIP = /^rect\((\d+)px,? (\d+)px,? (\d+)px,? (\d+)px\)$/;
14201
+
14202
+ function selectionValue(node) {
14203
+ var option = node.options[node.selectedIndex || 0];
14204
+ return option ? (option.text || "") : "";
14205
+ }
14206
+
14207
+ function parseMatrix(match) {
14208
+ if (match && match[1] === "matrix") {
14209
+ return match[2].split(",").map(function(s) {
14210
+ return parseFloat(s.trim());
14211
+ });
14212
+ }
14213
+ }
14214
+
14215
+ function isPercentage(value) {
14216
+ return value.toString().indexOf("%") !== -1;
14217
+ }
14218
+
14219
+ function removePx(str) {
14220
+ return str.replace("px", "");
14221
+ }
14222
+
14223
+ function asFloat(str) {
14224
+ return parseFloat(str);
14225
+ }
14226
+
14227
+ module.exports = NodeContainer;
14228
+
14229
+ },{"./color":5,"./utils":29}],17:[function(require,module,exports){
14230
+ var log = require('./log');
14231
+ var punycode = require('punycode');
14232
+ var NodeContainer = require('./nodecontainer');
14233
+ var TextContainer = require('./textcontainer');
14234
+ var PseudoElementContainer = require('./pseudoelementcontainer');
14235
+ var FontMetrics = require('./fontmetrics');
14236
+ var Color = require('./color');
14237
+ var Promise = require('./promise');
14238
+ var StackingContext = require('./stackingcontext');
14239
+ var utils = require('./utils');
14240
+ var bind = utils.bind;
14241
+ var getBounds = utils.getBounds;
14242
+ var parseBackgrounds = utils.parseBackgrounds;
14243
+ var offsetBounds = utils.offsetBounds;
14244
+
14245
+ function NodeParser(element, renderer, support, imageLoader, options) {
14246
+ log("Starting NodeParser");
14247
+ this.renderer = renderer;
14248
+ this.options = options;
14249
+ this.range = null;
14250
+ this.support = support;
14251
+ this.renderQueue = [];
14252
+ this.stack = new StackingContext(true, 1, element.ownerDocument, null);
14253
+ var parent = new NodeContainer(element, null);
14254
+ if (options.background) {
14255
+ renderer.rectangle(0, 0, renderer.width, renderer.height, new Color(options.background));
14256
+ }
14257
+ if (element === element.ownerDocument.documentElement) {
14258
+ // http://www.w3.org/TR/css3-background/#special-backgrounds
14259
+ var canvasBackground = new NodeContainer(parent.color('backgroundColor').isTransparent() ? element.ownerDocument.body : element.ownerDocument.documentElement, null);
14260
+ renderer.rectangle(0, 0, renderer.width, renderer.height, canvasBackground.color('backgroundColor'));
14261
+ }
14262
+ parent.visibile = parent.isElementVisible();
14263
+ this.createPseudoHideStyles(element.ownerDocument);
14264
+ this.disableAnimations(element.ownerDocument);
14265
+ this.nodes = flatten([parent].concat(this.getChildren(parent)).filter(function(container) {
14266
+ return container.visible = container.isElementVisible();
14267
+ }).map(this.getPseudoElements, this));
14268
+ this.fontMetrics = new FontMetrics();
14269
+ log("Fetched nodes, total:", this.nodes.length);
14270
+ log("Calculate overflow clips");
14271
+ this.calculateOverflowClips();
14272
+ log("Start fetching images");
14273
+ this.images = imageLoader.fetch(this.nodes.filter(isElement));
14274
+ this.ready = this.images.ready.then(bind(function() {
14275
+ log("Images loaded, starting parsing");
14276
+ log("Creating stacking contexts");
14277
+ this.createStackingContexts();
14278
+ log("Sorting stacking contexts");
14279
+ this.sortStackingContexts(this.stack);
14280
+ this.parse(this.stack);
14281
+ log("Render queue created with " + this.renderQueue.length + " items");
14282
+ return new Promise(bind(function(resolve) {
14283
+ if (!options.async) {
14284
+ this.renderQueue.forEach(this.paint, this);
14285
+ resolve();
14286
+ } else if (typeof(options.async) === "function") {
14287
+ options.async.call(this, this.renderQueue, resolve);
14288
+ } else if (this.renderQueue.length > 0){
14289
+ this.renderIndex = 0;
14290
+ this.asyncRenderer(this.renderQueue, resolve);
14291
+ } else {
14292
+ resolve();
14293
+ }
14294
+ }, this));
14295
+ }, this));
14296
+ }
14297
+
14298
+ NodeParser.prototype.calculateOverflowClips = function() {
14299
+ this.nodes.forEach(function(container) {
14300
+ if (isElement(container)) {
14301
+ if (isPseudoElement(container)) {
14302
+ container.appendToDOM();
14303
+ }
14304
+ container.borders = this.parseBorders(container);
14305
+ var clip = (container.css('overflow') === "hidden") ? [container.borders.clip] : [];
14306
+ var cssClip = container.parseClip();
14307
+ if (cssClip && ["absolute", "fixed"].indexOf(container.css('position')) !== -1) {
14308
+ clip.push([["rect",
14309
+ container.bounds.left + cssClip.left,
14310
+ container.bounds.top + cssClip.top,
14311
+ cssClip.right - cssClip.left,
14312
+ cssClip.bottom - cssClip.top
14313
+ ]]);
14314
+ }
14315
+ container.clip = hasParentClip(container) ? container.parent.clip.concat(clip) : clip;
14316
+ container.backgroundClip = (container.css('overflow') !== "hidden") ? container.clip.concat([container.borders.clip]) : container.clip;
14317
+ if (isPseudoElement(container)) {
14318
+ container.cleanDOM();
14319
+ }
14320
+ } else if (isTextNode(container)) {
14321
+ container.clip = hasParentClip(container) ? container.parent.clip : [];
14322
+ }
14323
+ if (!isPseudoElement(container)) {
14324
+ container.bounds = null;
14325
+ }
14326
+ }, this);
14327
+ };
14328
+
14329
+ function hasParentClip(container) {
14330
+ return container.parent && container.parent.clip.length;
14331
+ }
14332
+
14333
+ NodeParser.prototype.asyncRenderer = function(queue, resolve, asyncTimer) {
14334
+ asyncTimer = asyncTimer || Date.now();
14335
+ this.paint(queue[this.renderIndex++]);
14336
+ if (queue.length === this.renderIndex) {
14337
+ resolve();
14338
+ } else if (asyncTimer + 20 > Date.now()) {
14339
+ this.asyncRenderer(queue, resolve, asyncTimer);
14340
+ } else {
14341
+ setTimeout(bind(function() {
14342
+ this.asyncRenderer(queue, resolve);
14343
+ }, this), 0);
14344
+ }
14345
+ };
14346
+
14347
+ NodeParser.prototype.createPseudoHideStyles = function(document) {
14348
+ this.createStyles(document, '.' + PseudoElementContainer.prototype.PSEUDO_HIDE_ELEMENT_CLASS_BEFORE + ':before { content: "" !important; display: none !important; }' +
14349
+ '.' + PseudoElementContainer.prototype.PSEUDO_HIDE_ELEMENT_CLASS_AFTER + ':after { content: "" !important; display: none !important; }');
14350
+ };
14351
+
14352
+ NodeParser.prototype.disableAnimations = function(document) {
14353
+ this.createStyles(document, '* { -webkit-animation: none !important; -moz-animation: none !important; -o-animation: none !important; animation: none !important; ' +
14354
+ '-webkit-transition: none !important; -moz-transition: none !important; -o-transition: none !important; transition: none !important;}');
14355
+ };
14356
+
14357
+ NodeParser.prototype.createStyles = function(document, styles) {
14358
+ var hidePseudoElements = document.createElement('style');
14359
+ hidePseudoElements.innerHTML = styles;
14360
+ document.body.appendChild(hidePseudoElements);
14361
+ };
14362
+
14363
+ NodeParser.prototype.getPseudoElements = function(container) {
14364
+ var nodes = [[container]];
14365
+ if (container.node.nodeType === Node.ELEMENT_NODE) {
14366
+ var before = this.getPseudoElement(container, ":before");
14367
+ var after = this.getPseudoElement(container, ":after");
14368
+
14369
+ if (before) {
14370
+ nodes.push(before);
14371
+ }
14372
+
14373
+ if (after) {
14374
+ nodes.push(after);
14375
+ }
14376
+ }
14377
+ return flatten(nodes);
14378
+ };
14379
+
14380
+ function toCamelCase(str) {
14381
+ return str.replace(/(\-[a-z])/g, function(match){
14382
+ return match.toUpperCase().replace('-','');
14383
+ });
14384
+ }
14385
+
14386
+ NodeParser.prototype.getPseudoElement = function(container, type) {
14387
+ var style = container.computedStyle(type);
14388
+ if(!style || !style.content || style.content === "none" || style.content === "-moz-alt-content" || style.display === "none") {
14389
+ return null;
14390
+ }
14391
+
14392
+ var content = stripQuotes(style.content);
14393
+ var isImage = content.substr(0, 3) === 'url';
14394
+ var pseudoNode = document.createElement(isImage ? 'img' : 'html2canvaspseudoelement');
14395
+ var pseudoContainer = new PseudoElementContainer(pseudoNode, container, type);
14396
+
14397
+ for (var i = style.length-1; i >= 0; i--) {
14398
+ var property = toCamelCase(style.item(i));
14399
+ pseudoNode.style[property] = style[property];
14400
+ }
14401
+
14402
+ pseudoNode.className = PseudoElementContainer.prototype.PSEUDO_HIDE_ELEMENT_CLASS_BEFORE + " " + PseudoElementContainer.prototype.PSEUDO_HIDE_ELEMENT_CLASS_AFTER;
14403
+
14404
+ if (isImage) {
14405
+ pseudoNode.src = parseBackgrounds(content)[0].args[0];
14406
+ return [pseudoContainer];
14407
+ } else {
14408
+ var text = document.createTextNode(content);
14409
+ pseudoNode.appendChild(text);
14410
+ return [pseudoContainer, new TextContainer(text, pseudoContainer)];
14411
+ }
14412
+ };
14413
+
14414
+
14415
+ NodeParser.prototype.getChildren = function(parentContainer) {
14416
+ return flatten([].filter.call(parentContainer.node.childNodes, renderableNode).map(function(node) {
14417
+ var container = [node.nodeType === Node.TEXT_NODE ? new TextContainer(node, parentContainer) : new NodeContainer(node, parentContainer)].filter(nonIgnoredElement);
14418
+ return node.nodeType === Node.ELEMENT_NODE && container.length && node.tagName !== "TEXTAREA" ? (container[0].isElementVisible() ? container.concat(this.getChildren(container[0])) : []) : container;
14419
+ }, this));
14420
+ };
14421
+
14422
+ NodeParser.prototype.newStackingContext = function(container, hasOwnStacking) {
14423
+ var stack = new StackingContext(hasOwnStacking, container.getOpacity(), container.node, container.parent);
14424
+ container.cloneTo(stack);
14425
+ var parentStack = hasOwnStacking ? stack.getParentStack(this) : stack.parent.stack;
14426
+ parentStack.contexts.push(stack);
14427
+ container.stack = stack;
14428
+ };
14429
+
14430
+ NodeParser.prototype.createStackingContexts = function() {
14431
+ this.nodes.forEach(function(container) {
14432
+ if (isElement(container) && (this.isRootElement(container) || hasOpacity(container) || isPositionedForStacking(container) || this.isBodyWithTransparentRoot(container) || container.hasTransform())) {
14433
+ this.newStackingContext(container, true);
14434
+ } else if (isElement(container) && ((isPositioned(container) && zIndex0(container)) || isInlineBlock(container) || isFloating(container))) {
14435
+ this.newStackingContext(container, false);
14436
+ } else {
14437
+ container.assignStack(container.parent.stack);
14438
+ }
14439
+ }, this);
14440
+ };
14441
+
14442
+ NodeParser.prototype.isBodyWithTransparentRoot = function(container) {
14443
+ return container.node.nodeName === "BODY" && container.parent.color('backgroundColor').isTransparent();
14444
+ };
14445
+
14446
+ NodeParser.prototype.isRootElement = function(container) {
14447
+ return container.parent === null;
14448
+ };
14449
+
14450
+ NodeParser.prototype.sortStackingContexts = function(stack) {
14451
+ stack.contexts.sort(zIndexSort(stack.contexts.slice(0)));
14452
+ stack.contexts.forEach(this.sortStackingContexts, this);
14453
+ };
14454
+
14455
+ NodeParser.prototype.parseTextBounds = function(container) {
14456
+ return function(text, index, textList) {
14457
+ if (container.parent.css("textDecoration").substr(0, 4) !== "none" || text.trim().length !== 0) {
14458
+ if (this.support.rangeBounds && !container.parent.hasTransform()) {
14459
+ var offset = textList.slice(0, index).join("").length;
14460
+ return this.getRangeBounds(container.node, offset, text.length);
14461
+ } else if (container.node && typeof(container.node.data) === "string") {
14462
+ var replacementNode = container.node.splitText(text.length);
14463
+ var bounds = this.getWrapperBounds(container.node, container.parent.hasTransform());
14464
+ container.node = replacementNode;
14465
+ return bounds;
14466
+ }
14467
+ } else if(!this.support.rangeBounds || container.parent.hasTransform()){
14468
+ container.node = container.node.splitText(text.length);
14469
+ }
14470
+ return {};
14471
+ };
14472
+ };
14473
+
14474
+ NodeParser.prototype.getWrapperBounds = function(node, transform) {
14475
+ var wrapper = node.ownerDocument.createElement('html2canvaswrapper');
14476
+ var parent = node.parentNode,
14477
+ backupText = node.cloneNode(true);
14478
+
14479
+ wrapper.appendChild(node.cloneNode(true));
14480
+ parent.replaceChild(wrapper, node);
14481
+ var bounds = transform ? offsetBounds(wrapper) : getBounds(wrapper);
14482
+ parent.replaceChild(backupText, wrapper);
14483
+ return bounds;
14484
+ };
14485
+
14486
+ NodeParser.prototype.getRangeBounds = function(node, offset, length) {
14487
+ var range = this.range || (this.range = node.ownerDocument.createRange());
14488
+ range.setStart(node, offset);
14489
+ range.setEnd(node, offset + length);
14490
+ return range.getBoundingClientRect();
14491
+ };
14492
+
14493
+ function ClearTransform() {}
14494
+
14495
+ NodeParser.prototype.parse = function(stack) {
14496
+ // http://www.w3.org/TR/CSS21/visuren.html#z-index
14497
+ var negativeZindex = stack.contexts.filter(negativeZIndex); // 2. the child stacking contexts with negative stack levels (most negative first).
14498
+ var descendantElements = stack.children.filter(isElement);
14499
+ var descendantNonFloats = descendantElements.filter(not(isFloating));
14500
+ var nonInlineNonPositionedDescendants = descendantNonFloats.filter(not(isPositioned)).filter(not(inlineLevel)); // 3 the in-flow, non-inline-level, non-positioned descendants.
14501
+ var nonPositionedFloats = descendantElements.filter(not(isPositioned)).filter(isFloating); // 4. the non-positioned floats.
14502
+ var inFlow = descendantNonFloats.filter(not(isPositioned)).filter(inlineLevel); // 5. the in-flow, inline-level, non-positioned descendants, including inline tables and inline blocks.
14503
+ var stackLevel0 = stack.contexts.concat(descendantNonFloats.filter(isPositioned)).filter(zIndex0); // 6. the child stacking contexts with stack level 0 and the positioned descendants with stack level 0.
14504
+ var text = stack.children.filter(isTextNode).filter(hasText);
14505
+ var positiveZindex = stack.contexts.filter(positiveZIndex); // 7. the child stacking contexts with positive stack levels (least positive first).
14506
+ negativeZindex.concat(nonInlineNonPositionedDescendants).concat(nonPositionedFloats)
14507
+ .concat(inFlow).concat(stackLevel0).concat(text).concat(positiveZindex).forEach(function(container) {
14508
+ this.renderQueue.push(container);
14509
+ if (isStackingContext(container)) {
14510
+ this.parse(container);
14511
+ this.renderQueue.push(new ClearTransform());
14512
+ }
14513
+ }, this);
14514
+ };
14515
+
14516
+ NodeParser.prototype.paint = function(container) {
14517
+ try {
14518
+ if (container instanceof ClearTransform) {
14519
+ this.renderer.ctx.restore();
14520
+ } else if (isTextNode(container)) {
14521
+ if (isPseudoElement(container.parent)) {
14522
+ container.parent.appendToDOM();
14523
+ }
14524
+ this.paintText(container);
14525
+ if (isPseudoElement(container.parent)) {
14526
+ container.parent.cleanDOM();
14527
+ }
14528
+ } else {
14529
+ this.paintNode(container);
14530
+ }
14531
+ } catch(e) {
14532
+ log(e);
14533
+ if (this.options.strict) {
14534
+ throw e;
14535
+ }
14536
+ }
14537
+ };
14538
+
14539
+ NodeParser.prototype.paintNode = function(container) {
14540
+ if (isStackingContext(container)) {
14541
+ this.renderer.setOpacity(container.opacity);
14542
+ this.renderer.ctx.save();
14543
+ if (container.hasTransform()) {
14544
+ this.renderer.setTransform(container.parseTransform());
14545
+ }
14546
+ }
14547
+
14548
+ if (container.node.nodeName === "INPUT" && container.node.type === "checkbox") {
14549
+ this.paintCheckbox(container);
14550
+ } else if (container.node.nodeName === "INPUT" && container.node.type === "radio") {
14551
+ this.paintRadio(container);
14552
+ } else {
14553
+ this.paintElement(container);
14554
+ }
14555
+ };
14556
+
14557
+ NodeParser.prototype.paintElement = function(container) {
14558
+ var bounds = container.parseBounds();
14559
+ this.renderer.clip(container.backgroundClip, function() {
14560
+ this.renderer.renderBackground(container, bounds, container.borders.borders.map(getWidth));
14561
+ }, this);
14562
+
14563
+ this.renderer.clip(container.clip, function() {
14564
+ this.renderer.renderBorders(container.borders.borders);
14565
+ }, this);
14566
+
14567
+ this.renderer.clip(container.backgroundClip, function() {
14568
+ switch (container.node.nodeName) {
14569
+ case "svg":
14570
+ case "IFRAME":
14571
+ var imgContainer = this.images.get(container.node);
14572
+ if (imgContainer) {
14573
+ this.renderer.renderImage(container, bounds, container.borders, imgContainer);
14574
+ } else {
14575
+ log("Error loading <" + container.node.nodeName + ">", container.node);
14576
+ }
14577
+ break;
14578
+ case "IMG":
14579
+ var imageContainer = this.images.get(container.node.src);
14580
+ if (imageContainer) {
14581
+ this.renderer.renderImage(container, bounds, container.borders, imageContainer);
14582
+ } else {
14583
+ log("Error loading <img>", container.node.src);
14584
+ }
14585
+ break;
14586
+ case "CANVAS":
14587
+ this.renderer.renderImage(container, bounds, container.borders, {image: container.node});
14588
+ break;
14589
+ case "SELECT":
14590
+ case "INPUT":
14591
+ case "TEXTAREA":
14592
+ this.paintFormValue(container);
14593
+ break;
14594
+ }
14595
+ }, this);
14596
+ };
14597
+
14598
+ NodeParser.prototype.paintCheckbox = function(container) {
14599
+ var b = container.parseBounds();
14600
+
14601
+ var size = Math.min(b.width, b.height);
14602
+ var bounds = {width: size - 1, height: size - 1, top: b.top, left: b.left};
14603
+ var r = [3, 3];
14604
+ var radius = [r, r, r, r];
14605
+ var borders = [1,1,1,1].map(function(w) {
14606
+ return {color: new Color('#A5A5A5'), width: w};
14607
+ });
14608
+
14609
+ var borderPoints = calculateCurvePoints(bounds, radius, borders);
14610
+
14611
+ this.renderer.clip(container.backgroundClip, function() {
14612
+ this.renderer.rectangle(bounds.left + 1, bounds.top + 1, bounds.width - 2, bounds.height - 2, new Color("#DEDEDE"));
14613
+ this.renderer.renderBorders(calculateBorders(borders, bounds, borderPoints, radius));
14614
+ if (container.node.checked) {
14615
+ this.renderer.font(new Color('#424242'), 'normal', 'normal', 'bold', (size - 3) + "px", 'arial');
14616
+ this.renderer.text("\u2714", bounds.left + size / 6, bounds.top + size - 1);
14617
+ }
14618
+ }, this);
14619
+ };
14620
+
14621
+ NodeParser.prototype.paintRadio = function(container) {
14622
+ var bounds = container.parseBounds();
14623
+
14624
+ var size = Math.min(bounds.width, bounds.height) - 2;
14625
+
14626
+ this.renderer.clip(container.backgroundClip, function() {
14627
+ this.renderer.circleStroke(bounds.left + 1, bounds.top + 1, size, new Color('#DEDEDE'), 1, new Color('#A5A5A5'));
14628
+ if (container.node.checked) {
14629
+ this.renderer.circle(Math.ceil(bounds.left + size / 4) + 1, Math.ceil(bounds.top + size / 4) + 1, Math.floor(size / 2), new Color('#424242'));
14630
+ }
14631
+ }, this);
14632
+ };
14633
+
14634
+ NodeParser.prototype.paintFormValue = function(container) {
14635
+ var value = container.getValue();
14636
+ if (value.length > 0) {
14637
+ var document = container.node.ownerDocument;
14638
+ var wrapper = document.createElement('html2canvaswrapper');
14639
+ var properties = ['lineHeight', 'textAlign', 'fontFamily', 'fontWeight', 'fontSize', 'color',
14640
+ 'paddingLeft', 'paddingTop', 'paddingRight', 'paddingBottom',
14641
+ 'width', 'height', 'borderLeftStyle', 'borderTopStyle', 'borderLeftWidth', 'borderTopWidth',
14642
+ 'boxSizing', 'whiteSpace', 'wordWrap'];
14643
+
14644
+ properties.forEach(function(property) {
14645
+ try {
14646
+ wrapper.style[property] = container.css(property);
14647
+ } catch(e) {
14648
+ // Older IE has issues with "border"
14649
+ log("html2canvas: Parse: Exception caught in renderFormValue: " + e.message);
14650
+ }
14651
+ });
14652
+ var bounds = container.parseBounds();
14653
+ wrapper.style.position = "fixed";
14654
+ wrapper.style.left = bounds.left + "px";
14655
+ wrapper.style.top = bounds.top + "px";
14656
+ wrapper.textContent = value;
14657
+ document.body.appendChild(wrapper);
14658
+ this.paintText(new TextContainer(wrapper.firstChild, container));
14659
+ document.body.removeChild(wrapper);
14660
+ }
14661
+ };
14662
+
14663
+ NodeParser.prototype.paintText = function(container) {
14664
+ container.applyTextTransform();
14665
+ var characters = punycode.ucs2.decode(container.node.data);
14666
+ var textList = (!this.options.letterRendering || noLetterSpacing(container)) && !hasUnicode(container.node.data) ? getWords(characters) : characters.map(function(character) {
14667
+ return punycode.ucs2.encode([character]);
14668
+ });
14669
+
14670
+ var weight = container.parent.fontWeight();
14671
+ var size = container.parent.css('fontSize');
14672
+ var family = container.parent.css('fontFamily');
14673
+ var shadows = container.parent.parseTextShadows();
14674
+
14675
+ this.renderer.font(container.parent.color('color'), container.parent.css('fontStyle'), container.parent.css('fontVariant'), weight, size, family);
14676
+ if (shadows.length) {
14677
+ // TODO: support multiple text shadows
14678
+ this.renderer.fontShadow(shadows[0].color, shadows[0].offsetX, shadows[0].offsetY, shadows[0].blur);
14679
+ } else {
14680
+ this.renderer.clearShadow();
14681
+ }
14682
+
14683
+ this.renderer.clip(container.parent.clip, function() {
14684
+ textList.map(this.parseTextBounds(container), this).forEach(function(bounds, index) {
14685
+ if (bounds) {
14686
+ this.renderer.text(textList[index], bounds.left, bounds.bottom);
14687
+ this.renderTextDecoration(container.parent, bounds, this.fontMetrics.getMetrics(family, size));
14688
+ }
14689
+ }, this);
14690
+ }, this);
14691
+ };
14692
+
14693
+ NodeParser.prototype.renderTextDecoration = function(container, bounds, metrics) {
14694
+ switch(container.css("textDecoration").split(" ")[0]) {
14695
+ case "underline":
14696
+ // Draws a line at the baseline of the font
14697
+ // TODO As some browsers display the line as more than 1px if the font-size is big, need to take that into account both in position and size
14698
+ this.renderer.rectangle(bounds.left, Math.round(bounds.top + metrics.baseline + metrics.lineWidth), bounds.width, 1, container.color("color"));
14699
+ break;
14700
+ case "overline":
14701
+ this.renderer.rectangle(bounds.left, Math.round(bounds.top), bounds.width, 1, container.color("color"));
14702
+ break;
14703
+ case "line-through":
14704
+ // TODO try and find exact position for line-through
14705
+ this.renderer.rectangle(bounds.left, Math.ceil(bounds.top + metrics.middle + metrics.lineWidth), bounds.width, 1, container.color("color"));
14706
+ break;
14707
+ }
14708
+ };
14709
+
14710
+ var borderColorTransforms = {
14711
+ inset: [
14712
+ ["darken", 0.60],
14713
+ ["darken", 0.10],
14714
+ ["darken", 0.10],
14715
+ ["darken", 0.60]
14716
+ ]
14717
+ };
14718
+
14719
+ NodeParser.prototype.parseBorders = function(container) {
14720
+ var nodeBounds = container.parseBounds();
14721
+ var radius = getBorderRadiusData(container);
14722
+ var borders = ["Top", "Right", "Bottom", "Left"].map(function(side, index) {
14723
+ var style = container.css('border' + side + 'Style');
14724
+ var color = container.color('border' + side + 'Color');
14725
+ if (style === "inset" && color.isBlack()) {
14726
+ color = new Color([255, 255, 255, color.a]); // this is wrong, but
14727
+ }
14728
+ var colorTransform = borderColorTransforms[style] ? borderColorTransforms[style][index] : null;
14729
+ return {
14730
+ width: container.cssInt('border' + side + 'Width'),
14731
+ color: colorTransform ? color[colorTransform[0]](colorTransform[1]) : color,
14732
+ args: null
14733
+ };
14734
+ });
14735
+ var borderPoints = calculateCurvePoints(nodeBounds, radius, borders);
14736
+
14737
+ return {
14738
+ clip: this.parseBackgroundClip(container, borderPoints, borders, radius, nodeBounds),
14739
+ borders: calculateBorders(borders, nodeBounds, borderPoints, radius)
14740
+ };
14741
+ };
14742
+
14743
+ function calculateBorders(borders, nodeBounds, borderPoints, radius) {
14744
+ return borders.map(function(border, borderSide) {
14745
+ if (border.width > 0) {
14746
+ var bx = nodeBounds.left;
14747
+ var by = nodeBounds.top;
14748
+ var bw = nodeBounds.width;
14749
+ var bh = nodeBounds.height - (borders[2].width);
14750
+
14751
+ switch(borderSide) {
14752
+ case 0:
14753
+ // top border
14754
+ bh = borders[0].width;
14755
+ border.args = drawSide({
14756
+ c1: [bx, by],
14757
+ c2: [bx + bw, by],
14758
+ c3: [bx + bw - borders[1].width, by + bh],
14759
+ c4: [bx + borders[3].width, by + bh]
14760
+ }, radius[0], radius[1],
14761
+ borderPoints.topLeftOuter, borderPoints.topLeftInner, borderPoints.topRightOuter, borderPoints.topRightInner);
14762
+ break;
14763
+ case 1:
14764
+ // right border
14765
+ bx = nodeBounds.left + nodeBounds.width - (borders[1].width);
14766
+ bw = borders[1].width;
14767
+
14768
+ border.args = drawSide({
14769
+ c1: [bx + bw, by],
14770
+ c2: [bx + bw, by + bh + borders[2].width],
14771
+ c3: [bx, by + bh],
14772
+ c4: [bx, by + borders[0].width]
14773
+ }, radius[1], radius[2],
14774
+ borderPoints.topRightOuter, borderPoints.topRightInner, borderPoints.bottomRightOuter, borderPoints.bottomRightInner);
14775
+ break;
14776
+ case 2:
14777
+ // bottom border
14778
+ by = (by + nodeBounds.height) - (borders[2].width);
14779
+ bh = borders[2].width;
14780
+ border.args = drawSide({
14781
+ c1: [bx + bw, by + bh],
14782
+ c2: [bx, by + bh],
14783
+ c3: [bx + borders[3].width, by],
14784
+ c4: [bx + bw - borders[3].width, by]
14785
+ }, radius[2], radius[3],
14786
+ borderPoints.bottomRightOuter, borderPoints.bottomRightInner, borderPoints.bottomLeftOuter, borderPoints.bottomLeftInner);
14787
+ break;
14788
+ case 3:
14789
+ // left border
14790
+ bw = borders[3].width;
14791
+ border.args = drawSide({
14792
+ c1: [bx, by + bh + borders[2].width],
14793
+ c2: [bx, by],
14794
+ c3: [bx + bw, by + borders[0].width],
14795
+ c4: [bx + bw, by + bh]
14796
+ }, radius[3], radius[0],
14797
+ borderPoints.bottomLeftOuter, borderPoints.bottomLeftInner, borderPoints.topLeftOuter, borderPoints.topLeftInner);
14798
+ break;
14799
+ }
14800
+ }
14801
+ return border;
14802
+ });
14803
+ }
14804
+
14805
+ NodeParser.prototype.parseBackgroundClip = function(container, borderPoints, borders, radius, bounds) {
14806
+ var backgroundClip = container.css('backgroundClip'),
14807
+ borderArgs = [];
14808
+
14809
+ switch(backgroundClip) {
14810
+ case "content-box":
14811
+ case "padding-box":
14812
+ parseCorner(borderArgs, radius[0], radius[1], borderPoints.topLeftInner, borderPoints.topRightInner, bounds.left + borders[3].width, bounds.top + borders[0].width);
14813
+ parseCorner(borderArgs, radius[1], radius[2], borderPoints.topRightInner, borderPoints.bottomRightInner, bounds.left + bounds.width - borders[1].width, bounds.top + borders[0].width);
14814
+ parseCorner(borderArgs, radius[2], radius[3], borderPoints.bottomRightInner, borderPoints.bottomLeftInner, bounds.left + bounds.width - borders[1].width, bounds.top + bounds.height - borders[2].width);
14815
+ parseCorner(borderArgs, radius[3], radius[0], borderPoints.bottomLeftInner, borderPoints.topLeftInner, bounds.left + borders[3].width, bounds.top + bounds.height - borders[2].width);
14816
+ break;
14817
+
14818
+ default:
14819
+ parseCorner(borderArgs, radius[0], radius[1], borderPoints.topLeftOuter, borderPoints.topRightOuter, bounds.left, bounds.top);
14820
+ parseCorner(borderArgs, radius[1], radius[2], borderPoints.topRightOuter, borderPoints.bottomRightOuter, bounds.left + bounds.width, bounds.top);
14821
+ parseCorner(borderArgs, radius[2], radius[3], borderPoints.bottomRightOuter, borderPoints.bottomLeftOuter, bounds.left + bounds.width, bounds.top + bounds.height);
14822
+ parseCorner(borderArgs, radius[3], radius[0], borderPoints.bottomLeftOuter, borderPoints.topLeftOuter, bounds.left, bounds.top + bounds.height);
14823
+ break;
14824
+ }
14825
+
14826
+ return borderArgs;
14827
+ };
14828
+
14829
+ function getCurvePoints(x, y, r1, r2) {
14830
+ var kappa = 4 * ((Math.sqrt(2) - 1) / 3);
14831
+ var ox = (r1) * kappa, // control point offset horizontal
14832
+ oy = (r2) * kappa, // control point offset vertical
14833
+ xm = x + r1, // x-middle
14834
+ ym = y + r2; // y-middle
14835
+ return {
14836
+ topLeft: bezierCurve({x: x, y: ym}, {x: x, y: ym - oy}, {x: xm - ox, y: y}, {x: xm, y: y}),
14837
+ topRight: bezierCurve({x: x, y: y}, {x: x + ox,y: y}, {x: xm, y: ym - oy}, {x: xm, y: ym}),
14838
+ bottomRight: bezierCurve({x: xm, y: y}, {x: xm, y: y + oy}, {x: x + ox, y: ym}, {x: x, y: ym}),
14839
+ bottomLeft: bezierCurve({x: xm, y: ym}, {x: xm - ox, y: ym}, {x: x, y: y + oy}, {x: x, y:y})
14840
+ };
14841
+ }
14842
+
14843
+ function calculateCurvePoints(bounds, borderRadius, borders) {
14844
+ var x = bounds.left,
14845
+ y = bounds.top,
14846
+ width = bounds.width,
14847
+ height = bounds.height,
14848
+
14849
+ tlh = borderRadius[0][0],
14850
+ tlv = borderRadius[0][1],
14851
+ trh = borderRadius[1][0],
14852
+ trv = borderRadius[1][1],
14853
+ brh = borderRadius[2][0],
14854
+ brv = borderRadius[2][1],
14855
+ blh = borderRadius[3][0],
14856
+ blv = borderRadius[3][1];
14857
+
14858
+ var topWidth = width - trh,
14859
+ rightHeight = height - brv,
14860
+ bottomWidth = width - brh,
14861
+ leftHeight = height - blv;
14862
+
14863
+ return {
14864
+ topLeftOuter: getCurvePoints(x, y, tlh, tlv).topLeft.subdivide(0.5),
14865
+ topLeftInner: getCurvePoints(x + borders[3].width, y + borders[0].width, Math.max(0, tlh - borders[3].width), Math.max(0, tlv - borders[0].width)).topLeft.subdivide(0.5),
14866
+ topRightOuter: getCurvePoints(x + topWidth, y, trh, trv).topRight.subdivide(0.5),
14867
+ topRightInner: getCurvePoints(x + Math.min(topWidth, width + borders[3].width), y + borders[0].width, (topWidth > width + borders[3].width) ? 0 :trh - borders[3].width, trv - borders[0].width).topRight.subdivide(0.5),
14868
+ bottomRightOuter: getCurvePoints(x + bottomWidth, y + rightHeight, brh, brv).bottomRight.subdivide(0.5),
14869
+ bottomRightInner: getCurvePoints(x + Math.min(bottomWidth, width - borders[3].width), y + Math.min(rightHeight, height + borders[0].width), Math.max(0, brh - borders[1].width), brv - borders[2].width).bottomRight.subdivide(0.5),
14870
+ bottomLeftOuter: getCurvePoints(x, y + leftHeight, blh, blv).bottomLeft.subdivide(0.5),
14871
+ bottomLeftInner: getCurvePoints(x + borders[3].width, y + leftHeight, Math.max(0, blh - borders[3].width), blv - borders[2].width).bottomLeft.subdivide(0.5)
14872
+ };
14873
+ }
14874
+
14875
+ function bezierCurve(start, startControl, endControl, end) {
14876
+ var lerp = function (a, b, t) {
14877
+ return {
14878
+ x: a.x + (b.x - a.x) * t,
14879
+ y: a.y + (b.y - a.y) * t
14880
+ };
14881
+ };
14882
+
14883
+ return {
14884
+ start: start,
14885
+ startControl: startControl,
14886
+ endControl: endControl,
14887
+ end: end,
14888
+ subdivide: function(t) {
14889
+ var ab = lerp(start, startControl, t),
14890
+ bc = lerp(startControl, endControl, t),
14891
+ cd = lerp(endControl, end, t),
14892
+ abbc = lerp(ab, bc, t),
14893
+ bccd = lerp(bc, cd, t),
14894
+ dest = lerp(abbc, bccd, t);
14895
+ return [bezierCurve(start, ab, abbc, dest), bezierCurve(dest, bccd, cd, end)];
14896
+ },
14897
+ curveTo: function(borderArgs) {
14898
+ borderArgs.push(["bezierCurve", startControl.x, startControl.y, endControl.x, endControl.y, end.x, end.y]);
14899
+ },
14900
+ curveToReversed: function(borderArgs) {
14901
+ borderArgs.push(["bezierCurve", endControl.x, endControl.y, startControl.x, startControl.y, start.x, start.y]);
14902
+ }
14903
+ };
14904
+ }
14905
+
14906
+ function drawSide(borderData, radius1, radius2, outer1, inner1, outer2, inner2) {
14907
+ var borderArgs = [];
14908
+
14909
+ if (radius1[0] > 0 || radius1[1] > 0) {
14910
+ borderArgs.push(["line", outer1[1].start.x, outer1[1].start.y]);
14911
+ outer1[1].curveTo(borderArgs);
14912
+ } else {
14913
+ borderArgs.push([ "line", borderData.c1[0], borderData.c1[1]]);
14914
+ }
14915
+
14916
+ if (radius2[0] > 0 || radius2[1] > 0) {
14917
+ borderArgs.push(["line", outer2[0].start.x, outer2[0].start.y]);
14918
+ outer2[0].curveTo(borderArgs);
14919
+ borderArgs.push(["line", inner2[0].end.x, inner2[0].end.y]);
14920
+ inner2[0].curveToReversed(borderArgs);
14921
+ } else {
14922
+ borderArgs.push(["line", borderData.c2[0], borderData.c2[1]]);
14923
+ borderArgs.push(["line", borderData.c3[0], borderData.c3[1]]);
14924
+ }
14925
+
14926
+ if (radius1[0] > 0 || radius1[1] > 0) {
14927
+ borderArgs.push(["line", inner1[1].end.x, inner1[1].end.y]);
14928
+ inner1[1].curveToReversed(borderArgs);
14929
+ } else {
14930
+ borderArgs.push(["line", borderData.c4[0], borderData.c4[1]]);
14931
+ }
14932
+
14933
+ return borderArgs;
14934
+ }
14935
+
14936
+ function parseCorner(borderArgs, radius1, radius2, corner1, corner2, x, y) {
14937
+ if (radius1[0] > 0 || radius1[1] > 0) {
14938
+ borderArgs.push(["line", corner1[0].start.x, corner1[0].start.y]);
14939
+ corner1[0].curveTo(borderArgs);
14940
+ corner1[1].curveTo(borderArgs);
14941
+ } else {
14942
+ borderArgs.push(["line", x, y]);
14943
+ }
14944
+
14945
+ if (radius2[0] > 0 || radius2[1] > 0) {
14946
+ borderArgs.push(["line", corner2[0].start.x, corner2[0].start.y]);
14947
+ }
14948
+ }
14949
+
14950
+ function negativeZIndex(container) {
14951
+ return container.cssInt("zIndex") < 0;
14952
+ }
14953
+
14954
+ function positiveZIndex(container) {
14955
+ return container.cssInt("zIndex") > 0;
14956
+ }
14957
+
14958
+ function zIndex0(container) {
14959
+ return container.cssInt("zIndex") === 0;
14960
+ }
14961
+
14962
+ function inlineLevel(container) {
14963
+ return ["inline", "inline-block", "inline-table"].indexOf(container.css("display")) !== -1;
14964
+ }
14965
+
14966
+ function isStackingContext(container) {
14967
+ return (container instanceof StackingContext);
14968
+ }
14969
+
14970
+ function hasText(container) {
14971
+ return container.node.data.trim().length > 0;
14972
+ }
14973
+
14974
+ function noLetterSpacing(container) {
14975
+ return (/^(normal|none|0px)$/.test(container.parent.css("letterSpacing")));
14976
+ }
14977
+
14978
+ function getBorderRadiusData(container) {
14979
+ return ["TopLeft", "TopRight", "BottomRight", "BottomLeft"].map(function(side) {
14980
+ var value = container.css('border' + side + 'Radius');
14981
+ var arr = value.split(" ");
14982
+ if (arr.length <= 1) {
14983
+ arr[1] = arr[0];
14984
+ }
14985
+ return arr.map(asInt);
14986
+ });
14987
+ }
14988
+
14989
+ function renderableNode(node) {
14990
+ return (node.nodeType === Node.TEXT_NODE || node.nodeType === Node.ELEMENT_NODE);
14991
+ }
14992
+
14993
+ function isPositionedForStacking(container) {
14994
+ var position = container.css("position");
14995
+ var zIndex = (["absolute", "relative", "fixed"].indexOf(position) !== -1) ? container.css("zIndex") : "auto";
14996
+ return zIndex !== "auto";
14997
+ }
14998
+
14999
+ function isPositioned(container) {
15000
+ return container.css("position") !== "static";
15001
+ }
15002
+
15003
+ function isFloating(container) {
15004
+ return container.css("float") !== "none";
15005
+ }
15006
+
15007
+ function isInlineBlock(container) {
15008
+ return ["inline-block", "inline-table"].indexOf(container.css("display")) !== -1;
15009
+ }
15010
+
15011
+ function not(callback) {
15012
+ var context = this;
15013
+ return function() {
15014
+ return !callback.apply(context, arguments);
15015
+ };
15016
+ }
15017
+
15018
+ function isElement(container) {
15019
+ return container.node.nodeType === Node.ELEMENT_NODE;
15020
+ }
15021
+
15022
+ function isPseudoElement(container) {
15023
+ return container.isPseudoElement === true;
15024
+ }
15025
+
15026
+ function isTextNode(container) {
15027
+ return container.node.nodeType === Node.TEXT_NODE;
15028
+ }
15029
+
15030
+ function zIndexSort(contexts) {
15031
+ return function(a, b) {
15032
+ return (a.cssInt("zIndex") + (contexts.indexOf(a) / contexts.length)) - (b.cssInt("zIndex") + (contexts.indexOf(b) / contexts.length));
15033
+ };
15034
+ }
15035
+
15036
+ function hasOpacity(container) {
15037
+ return container.getOpacity() < 1;
15038
+ }
15039
+
15040
+ function asInt(value) {
15041
+ return parseInt(value, 10);
15042
+ }
15043
+
15044
+ function getWidth(border) {
15045
+ return border.width;
15046
+ }
15047
+
15048
+ function nonIgnoredElement(nodeContainer) {
15049
+ return (nodeContainer.node.nodeType !== Node.ELEMENT_NODE || ["SCRIPT", "HEAD", "TITLE", "OBJECT", "BR", "OPTION"].indexOf(nodeContainer.node.nodeName) === -1);
15050
+ }
15051
+
15052
+ function flatten(arrays) {
15053
+ return [].concat.apply([], arrays);
15054
+ }
15055
+
15056
+ function stripQuotes(content) {
15057
+ var first = content.substr(0, 1);
15058
+ return (first === content.substr(content.length - 1) && first.match(/'|"/)) ? content.substr(1, content.length - 2) : content;
15059
+ }
15060
+
15061
+ function getWords(characters) {
15062
+ var words = [], i = 0, onWordBoundary = false, word;
15063
+ while(characters.length) {
15064
+ if (isWordBoundary(characters[i]) === onWordBoundary) {
15065
+ word = characters.splice(0, i);
15066
+ if (word.length) {
15067
+ words.push(punycode.ucs2.encode(word));
15068
+ }
15069
+ onWordBoundary =! onWordBoundary;
15070
+ i = 0;
15071
+ } else {
15072
+ i++;
15073
+ }
15074
+
15075
+ if (i >= characters.length) {
15076
+ word = characters.splice(0, i);
15077
+ if (word.length) {
15078
+ words.push(punycode.ucs2.encode(word));
15079
+ }
15080
+ }
15081
+ }
15082
+ return words;
15083
+ }
15084
+
15085
+ function isWordBoundary(characterCode) {
15086
+ return [
15087
+ 32, // <space>
15088
+ 13, // \r
15089
+ 10, // \n
15090
+ 9, // \t
15091
+ 45 // -
15092
+ ].indexOf(characterCode) !== -1;
15093
+ }
15094
+
15095
+ function hasUnicode(string) {
15096
+ return (/[^\u0000-\u00ff]/).test(string);
15097
+ }
15098
+
15099
+ module.exports = NodeParser;
15100
+
15101
+ },{"./color":5,"./fontmetrics":9,"./log":15,"./nodecontainer":16,"./promise":18,"./pseudoelementcontainer":21,"./stackingcontext":24,"./textcontainer":28,"./utils":29,"punycode":3}],18:[function(require,module,exports){
15102
+ module.exports = require('es6-promise').Promise;
15103
+
15104
+ },{"es6-promise":1}],19:[function(require,module,exports){
15105
+ var Promise = require('./promise');
15106
+ var XHR = require('./xhr');
15107
+ var utils = require('./utils');
15108
+ var log = require('./log');
15109
+ var createWindowClone = require('./clone');
15110
+ var decode64 = utils.decode64;
15111
+
15112
+ function Proxy(src, proxyUrl, document) {
15113
+ var supportsCORS = ('withCredentials' in new XMLHttpRequest());
15114
+ if (!proxyUrl) {
15115
+ return Promise.reject("No proxy configured");
15116
+ }
15117
+ var callback = createCallback(supportsCORS);
15118
+ var url = createProxyUrl(proxyUrl, src, callback);
15119
+
15120
+ return supportsCORS ? XHR(url) : (jsonp(document, url, callback).then(function(response) {
15121
+ return decode64(response.content);
15122
+ }));
15123
+ }
15124
+ var proxyCount = 0;
15125
+
15126
+ function ProxyURL(src, proxyUrl, document) {
15127
+ var supportsCORSImage = ('crossOrigin' in new Image());
15128
+ var callback = createCallback(supportsCORSImage);
15129
+ var url = createProxyUrl(proxyUrl, src, callback);
15130
+ return (supportsCORSImage ? Promise.resolve(url) : jsonp(document, url, callback).then(function(response) {
15131
+ return "data:" + response.type + ";base64," + response.content;
15132
+ }));
15133
+ }
15134
+
15135
+ function jsonp(document, url, callback) {
15136
+ return new Promise(function(resolve, reject) {
15137
+ var s = document.createElement("script");
15138
+ var cleanup = function() {
15139
+ delete window.html2canvas.proxy[callback];
15140
+ document.body.removeChild(s);
15141
+ };
15142
+ window.html2canvas.proxy[callback] = function(response) {
15143
+ cleanup();
15144
+ resolve(response);
15145
+ };
15146
+ s.src = url;
15147
+ s.onerror = function(e) {
15148
+ cleanup();
15149
+ reject(e);
15150
+ };
15151
+ document.body.appendChild(s);
15152
+ });
15153
+ }
15154
+
15155
+ function createCallback(useCORS) {
15156
+ return !useCORS ? "html2canvas_" + Date.now() + "_" + (++proxyCount) + "_" + Math.round(Math.random() * 100000) : "";
15157
+ }
15158
+
15159
+ function createProxyUrl(proxyUrl, src, callback) {
15160
+ return proxyUrl + "?url=" + encodeURIComponent(src) + (callback.length ? "&callback=html2canvas.proxy." + callback : "");
15161
+ }
15162
+
15163
+ function documentFromHTML(src) {
15164
+ return function(html) {
15165
+ var parser = new DOMParser(), doc;
15166
+ try {
15167
+ doc = parser.parseFromString(html, "text/html");
15168
+ } catch(e) {
15169
+ log("DOMParser not supported, falling back to createHTMLDocument");
15170
+ doc = document.implementation.createHTMLDocument("");
15171
+ try {
15172
+ doc.open();
15173
+ doc.write(html);
15174
+ doc.close();
15175
+ } catch(ee) {
15176
+ log("createHTMLDocument write not supported, falling back to document.body.innerHTML");
15177
+ doc.body.innerHTML = html; // ie9 doesnt support writing to documentElement
15178
+ }
15179
+ }
15180
+
15181
+ var b = doc.querySelector("base");
15182
+ if (!b || !b.href.host) {
15183
+ var base = doc.createElement("base");
15184
+ base.href = src;
15185
+ doc.head.insertBefore(base, doc.head.firstChild);
15186
+ }
15187
+
15188
+ return doc;
15189
+ };
15190
+ }
15191
+
15192
+ function loadUrlDocument(src, proxy, document, width, height, options) {
15193
+ return new Proxy(src, proxy, window.document).then(documentFromHTML(src)).then(function(doc) {
15194
+ return createWindowClone(doc, document, width, height, options, 0, 0);
15195
+ });
15196
+ }
15197
+
15198
+ exports.Proxy = Proxy;
15199
+ exports.ProxyURL = ProxyURL;
15200
+ exports.loadUrlDocument = loadUrlDocument;
15201
+
15202
+ },{"./clone":4,"./log":15,"./promise":18,"./utils":29,"./xhr":31}],20:[function(require,module,exports){
15203
+ var ProxyURL = require('./proxy').ProxyURL;
15204
+ var Promise = require('./promise');
15205
+
15206
+ function ProxyImageContainer(src, proxy) {
15207
+ var link = document.createElement("a");
15208
+ link.href = src;
15209
+ src = link.href;
15210
+ this.src = src;
15211
+ this.image = new Image();
15212
+ var self = this;
15213
+ this.promise = new Promise(function(resolve, reject) {
15214
+ self.image.crossOrigin = "Anonymous";
15215
+ self.image.onload = resolve;
15216
+ self.image.onerror = reject;
15217
+
15218
+ new ProxyURL(src, proxy, document).then(function(url) {
15219
+ self.image.src = url;
15220
+ })['catch'](reject);
15221
+ });
15222
+ }
15223
+
15224
+ module.exports = ProxyImageContainer;
15225
+
15226
+ },{"./promise":18,"./proxy":19}],21:[function(require,module,exports){
15227
+ var NodeContainer = require('./nodecontainer');
15228
+
15229
+ function PseudoElementContainer(node, parent, type) {
15230
+ NodeContainer.call(this, node, parent);
15231
+ this.isPseudoElement = true;
15232
+ this.before = type === ":before";
15233
+ }
15234
+
15235
+ PseudoElementContainer.prototype.cloneTo = function(stack) {
15236
+ PseudoElementContainer.prototype.cloneTo.call(this, stack);
15237
+ stack.isPseudoElement = true;
15238
+ stack.before = this.before;
15239
+ };
15240
+
15241
+ PseudoElementContainer.prototype = Object.create(NodeContainer.prototype);
15242
+
15243
+ PseudoElementContainer.prototype.appendToDOM = function() {
15244
+ if (this.before) {
15245
+ this.parent.node.insertBefore(this.node, this.parent.node.firstChild);
15246
+ } else {
15247
+ this.parent.node.appendChild(this.node);
15248
+ }
15249
+ this.parent.node.className += " " + this.getHideClass();
15250
+ };
15251
+
15252
+ PseudoElementContainer.prototype.cleanDOM = function() {
15253
+ this.node.parentNode.removeChild(this.node);
15254
+ this.parent.node.className = this.parent.node.className.replace(this.getHideClass(), "");
15255
+ };
15256
+
15257
+ PseudoElementContainer.prototype.getHideClass = function() {
15258
+ return this["PSEUDO_HIDE_ELEMENT_CLASS_" + (this.before ? "BEFORE" : "AFTER")];
15259
+ };
15260
+
15261
+ PseudoElementContainer.prototype.PSEUDO_HIDE_ELEMENT_CLASS_BEFORE = "___html2canvas___pseudoelement_before";
15262
+ PseudoElementContainer.prototype.PSEUDO_HIDE_ELEMENT_CLASS_AFTER = "___html2canvas___pseudoelement_after";
15263
+
15264
+ module.exports = PseudoElementContainer;
15265
+
15266
+ },{"./nodecontainer":16}],22:[function(require,module,exports){
15267
+ var log = require('./log');
15268
+
15269
+ function Renderer(width, height, images, options, document) {
15270
+ this.width = width;
15271
+ this.height = height;
15272
+ this.images = images;
15273
+ this.options = options;
15274
+ this.document = document;
15275
+ }
15276
+
15277
+ Renderer.prototype.renderImage = function(container, bounds, borderData, imageContainer) {
15278
+ var paddingLeft = container.cssInt('paddingLeft'),
15279
+ paddingTop = container.cssInt('paddingTop'),
15280
+ paddingRight = container.cssInt('paddingRight'),
15281
+ paddingBottom = container.cssInt('paddingBottom'),
15282
+ borders = borderData.borders;
15283
+
15284
+ var width = bounds.width - (borders[1].width + borders[3].width + paddingLeft + paddingRight);
15285
+ var height = bounds.height - (borders[0].width + borders[2].width + paddingTop + paddingBottom);
15286
+ this.drawImage(
15287
+ imageContainer,
15288
+ 0,
15289
+ 0,
15290
+ imageContainer.image.width || width,
15291
+ imageContainer.image.height || height,
15292
+ bounds.left + paddingLeft + borders[3].width,
15293
+ bounds.top + paddingTop + borders[0].width,
15294
+ width,
15295
+ height
15296
+ );
15297
+ };
15298
+
15299
+ Renderer.prototype.renderBackground = function(container, bounds, borderData) {
15300
+ if (bounds.height > 0 && bounds.width > 0) {
15301
+ this.renderBackgroundColor(container, bounds);
15302
+ this.renderBackgroundImage(container, bounds, borderData);
15303
+ }
15304
+ };
15305
+
15306
+ Renderer.prototype.renderBackgroundColor = function(container, bounds) {
15307
+ var color = container.color("backgroundColor");
15308
+ if (!color.isTransparent()) {
15309
+ this.rectangle(bounds.left, bounds.top, bounds.width, bounds.height, color);
15310
+ }
15311
+ };
15312
+
15313
+ Renderer.prototype.renderBorders = function(borders) {
15314
+ borders.forEach(this.renderBorder, this);
15315
+ };
15316
+
15317
+ Renderer.prototype.renderBorder = function(data) {
15318
+ if (!data.color.isTransparent() && data.args !== null) {
15319
+ this.drawShape(data.args, data.color);
15320
+ }
15321
+ };
15322
+
15323
+ Renderer.prototype.renderBackgroundImage = function(container, bounds, borderData) {
15324
+ var backgroundImages = container.parseBackgroundImages();
15325
+ backgroundImages.reverse().forEach(function(backgroundImage, index, arr) {
15326
+ switch(backgroundImage.method) {
15327
+ case "url":
15328
+ var image = this.images.get(backgroundImage.args[0]);
15329
+ if (image) {
15330
+ this.renderBackgroundRepeating(container, bounds, image, arr.length - (index+1), borderData);
15331
+ } else {
15332
+ log("Error loading background-image", backgroundImage.args[0]);
15333
+ }
15334
+ break;
15335
+ case "linear-gradient":
15336
+ case "gradient":
15337
+ var gradientImage = this.images.get(backgroundImage.value);
15338
+ if (gradientImage) {
15339
+ this.renderBackgroundGradient(gradientImage, bounds, borderData);
15340
+ } else {
15341
+ log("Error loading background-image", backgroundImage.args[0]);
15342
+ }
15343
+ break;
15344
+ case "none":
15345
+ break;
15346
+ default:
15347
+ log("Unknown background-image type", backgroundImage.args[0]);
15348
+ }
15349
+ }, this);
15350
+ };
15351
+
15352
+ Renderer.prototype.renderBackgroundRepeating = function(container, bounds, imageContainer, index, borderData) {
15353
+ var size = container.parseBackgroundSize(bounds, imageContainer.image, index);
15354
+ var position = container.parseBackgroundPosition(bounds, imageContainer.image, index, size);
15355
+ var repeat = container.parseBackgroundRepeat(index);
15356
+ switch (repeat) {
15357
+ case "repeat-x":
15358
+ case "repeat no-repeat":
15359
+ this.backgroundRepeatShape(imageContainer, position, size, bounds, bounds.left + borderData[3], bounds.top + position.top + borderData[0], 99999, size.height, borderData);
15360
+ break;
15361
+ case "repeat-y":
15362
+ case "no-repeat repeat":
15363
+ this.backgroundRepeatShape(imageContainer, position, size, bounds, bounds.left + position.left + borderData[3], bounds.top + borderData[0], size.width, 99999, borderData);
15364
+ break;
15365
+ case "no-repeat":
15366
+ this.backgroundRepeatShape(imageContainer, position, size, bounds, bounds.left + position.left + borderData[3], bounds.top + position.top + borderData[0], size.width, size.height, borderData);
15367
+ break;
15368
+ default:
15369
+ this.renderBackgroundRepeat(imageContainer, position, size, {top: bounds.top, left: bounds.left}, borderData[3], borderData[0]);
15370
+ break;
15371
+ }
15372
+ };
15373
+
15374
+ module.exports = Renderer;
15375
+
15376
+ },{"./log":15}],23:[function(require,module,exports){
15377
+ var Renderer = require('../renderer');
15378
+ var LinearGradientContainer = require('../lineargradientcontainer');
15379
+ var log = require('../log');
15380
+
15381
+ function CanvasRenderer(width, height) {
15382
+ Renderer.apply(this, arguments);
15383
+ this.canvas = this.options.canvas || this.document.createElement("canvas");
15384
+ if (!this.options.canvas) {
15385
+ this.canvas.width = width;
15386
+ this.canvas.height = height;
15387
+ }
15388
+ this.ctx = this.canvas.getContext("2d");
15389
+ this.taintCtx = this.document.createElement("canvas").getContext("2d");
15390
+ this.ctx.textBaseline = "bottom";
15391
+ this.variables = {};
15392
+ log("Initialized CanvasRenderer with size", width, "x", height);
15393
+ }
15394
+
15395
+ CanvasRenderer.prototype = Object.create(Renderer.prototype);
15396
+
15397
+ CanvasRenderer.prototype.setFillStyle = function(fillStyle) {
15398
+ this.ctx.fillStyle = typeof(fillStyle) === "object" && !!fillStyle.isColor ? fillStyle.toString() : fillStyle;
15399
+ return this.ctx;
15400
+ };
15401
+
15402
+ CanvasRenderer.prototype.rectangle = function(left, top, width, height, color) {
15403
+ this.setFillStyle(color).fillRect(left, top, width, height);
15404
+ };
15405
+
15406
+ CanvasRenderer.prototype.circle = function(left, top, size, color) {
15407
+ this.setFillStyle(color);
15408
+ this.ctx.beginPath();
15409
+ this.ctx.arc(left + size / 2, top + size / 2, size / 2, 0, Math.PI*2, true);
15410
+ this.ctx.closePath();
15411
+ this.ctx.fill();
15412
+ };
15413
+
15414
+ CanvasRenderer.prototype.circleStroke = function(left, top, size, color, stroke, strokeColor) {
15415
+ this.circle(left, top, size, color);
15416
+ this.ctx.strokeStyle = strokeColor.toString();
15417
+ this.ctx.stroke();
15418
+ };
15419
+
15420
+ CanvasRenderer.prototype.drawShape = function(shape, color) {
15421
+ this.shape(shape);
15422
+ this.setFillStyle(color).fill();
15423
+ };
15424
+
15425
+ CanvasRenderer.prototype.taints = function(imageContainer) {
15426
+ if (imageContainer.tainted === null) {
15427
+ this.taintCtx.drawImage(imageContainer.image, 0, 0);
15428
+ try {
15429
+ this.taintCtx.getImageData(0, 0, 1, 1);
15430
+ imageContainer.tainted = false;
15431
+ } catch(e) {
15432
+ this.taintCtx = document.createElement("canvas").getContext("2d");
15433
+ imageContainer.tainted = true;
15434
+ }
15435
+ }
15436
+
15437
+ return imageContainer.tainted;
15438
+ };
15439
+
15440
+ CanvasRenderer.prototype.drawImage = function(imageContainer, sx, sy, sw, sh, dx, dy, dw, dh) {
15441
+ if (!this.taints(imageContainer) || this.options.allowTaint) {
15442
+ this.ctx.drawImage(imageContainer.image, sx, sy, sw, sh, dx, dy, dw, dh);
15443
+ }
15444
+ };
15445
+
15446
+ CanvasRenderer.prototype.clip = function(shapes, callback, context) {
15447
+ this.ctx.save();
15448
+ shapes.filter(hasEntries).forEach(function(shape) {
15449
+ this.shape(shape).clip();
15450
+ }, this);
15451
+ callback.call(context);
15452
+ this.ctx.restore();
15453
+ };
15454
+
15455
+ CanvasRenderer.prototype.shape = function(shape) {
15456
+ this.ctx.beginPath();
15457
+ shape.forEach(function(point, index) {
15458
+ if (point[0] === "rect") {
15459
+ this.ctx.rect.apply(this.ctx, point.slice(1));
15460
+ } else {
15461
+ this.ctx[(index === 0) ? "moveTo" : point[0] + "To" ].apply(this.ctx, point.slice(1));
15462
+ }
15463
+ }, this);
15464
+ this.ctx.closePath();
15465
+ return this.ctx;
15466
+ };
15467
+
15468
+ CanvasRenderer.prototype.font = function(color, style, variant, weight, size, family) {
15469
+ this.setFillStyle(color).font = [style, variant, weight, size, family].join(" ").split(",")[0];
15470
+ };
15471
+
15472
+ CanvasRenderer.prototype.fontShadow = function(color, offsetX, offsetY, blur) {
15473
+ this.setVariable("shadowColor", color.toString())
15474
+ .setVariable("shadowOffsetY", offsetX)
15475
+ .setVariable("shadowOffsetX", offsetY)
15476
+ .setVariable("shadowBlur", blur);
15477
+ };
15478
+
15479
+ CanvasRenderer.prototype.clearShadow = function() {
15480
+ this.setVariable("shadowColor", "rgba(0,0,0,0)");
15481
+ };
15482
+
15483
+ CanvasRenderer.prototype.setOpacity = function(opacity) {
15484
+ this.ctx.globalAlpha = opacity;
15485
+ };
15486
+
15487
+ CanvasRenderer.prototype.setTransform = function(transform) {
15488
+ this.ctx.translate(transform.origin[0], transform.origin[1]);
15489
+ this.ctx.transform.apply(this.ctx, transform.matrix);
15490
+ this.ctx.translate(-transform.origin[0], -transform.origin[1]);
15491
+ };
15492
+
15493
+ CanvasRenderer.prototype.setVariable = function(property, value) {
15494
+ if (this.variables[property] !== value) {
15495
+ this.variables[property] = this.ctx[property] = value;
15496
+ }
15497
+
15498
+ return this;
15499
+ };
15500
+
15501
+ CanvasRenderer.prototype.text = function(text, left, bottom) {
15502
+ this.ctx.fillText(text, left, bottom);
15503
+ };
15504
+
15505
+ CanvasRenderer.prototype.backgroundRepeatShape = function(imageContainer, backgroundPosition, size, bounds, left, top, width, height, borderData) {
15506
+ var shape = [
15507
+ ["line", Math.round(left), Math.round(top)],
15508
+ ["line", Math.round(left + width), Math.round(top)],
15509
+ ["line", Math.round(left + width), Math.round(height + top)],
15510
+ ["line", Math.round(left), Math.round(height + top)]
15511
+ ];
15512
+ this.clip([shape], function() {
15513
+ this.renderBackgroundRepeat(imageContainer, backgroundPosition, size, bounds, borderData[3], borderData[0]);
15514
+ }, this);
15515
+ };
15516
+
15517
+ CanvasRenderer.prototype.renderBackgroundRepeat = function(imageContainer, backgroundPosition, size, bounds, borderLeft, borderTop) {
15518
+ var offsetX = Math.round(bounds.left + backgroundPosition.left + borderLeft), offsetY = Math.round(bounds.top + backgroundPosition.top + borderTop);
15519
+ this.setFillStyle(this.ctx.createPattern(this.resizeImage(imageContainer, size), "repeat"));
15520
+ this.ctx.translate(offsetX, offsetY);
15521
+ this.ctx.fill();
15522
+ this.ctx.translate(-offsetX, -offsetY);
15523
+ };
15524
+
15525
+ CanvasRenderer.prototype.renderBackgroundGradient = function(gradientImage, bounds) {
15526
+ if (gradientImage instanceof LinearGradientContainer) {
15527
+ var gradient = this.ctx.createLinearGradient(
15528
+ bounds.left + bounds.width * gradientImage.x0,
15529
+ bounds.top + bounds.height * gradientImage.y0,
15530
+ bounds.left + bounds.width * gradientImage.x1,
15531
+ bounds.top + bounds.height * gradientImage.y1);
15532
+ gradientImage.colorStops.forEach(function(colorStop) {
15533
+ gradient.addColorStop(colorStop.stop, colorStop.color.toString());
15534
+ });
15535
+ this.rectangle(bounds.left, bounds.top, bounds.width, bounds.height, gradient);
15536
+ }
15537
+ };
15538
+
15539
+ CanvasRenderer.prototype.resizeImage = function(imageContainer, size) {
15540
+ var image = imageContainer.image;
15541
+ if(image.width === size.width && image.height === size.height) {
15542
+ return image;
15543
+ }
15544
+
15545
+ var ctx, canvas = document.createElement('canvas');
15546
+ canvas.width = size.width;
15547
+ canvas.height = size.height;
15548
+ ctx = canvas.getContext("2d");
15549
+ ctx.drawImage(image, 0, 0, image.width, image.height, 0, 0, size.width, size.height );
15550
+ return canvas;
15551
+ };
15552
+
15553
+ function hasEntries(array) {
15554
+ return array.length > 0;
15555
+ }
15556
+
15557
+ module.exports = CanvasRenderer;
15558
+
15559
+ },{"../lineargradientcontainer":14,"../log":15,"../renderer":22}],24:[function(require,module,exports){
15560
+ var NodeContainer = require('./nodecontainer');
15561
+
15562
+ function StackingContext(hasOwnStacking, opacity, element, parent) {
15563
+ NodeContainer.call(this, element, parent);
15564
+ this.ownStacking = hasOwnStacking;
15565
+ this.contexts = [];
15566
+ this.children = [];
15567
+ this.opacity = (this.parent ? this.parent.stack.opacity : 1) * opacity;
15568
+ }
15569
+
15570
+ StackingContext.prototype = Object.create(NodeContainer.prototype);
15571
+
15572
+ StackingContext.prototype.getParentStack = function(context) {
15573
+ var parentStack = (this.parent) ? this.parent.stack : null;
15574
+ return parentStack ? (parentStack.ownStacking ? parentStack : parentStack.getParentStack(context)) : context.stack;
15575
+ };
15576
+
15577
+ module.exports = StackingContext;
15578
+
15579
+ },{"./nodecontainer":16}],25:[function(require,module,exports){
15580
+ function Support(document) {
15581
+ this.rangeBounds = this.testRangeBounds(document);
15582
+ this.cors = this.testCORS();
15583
+ this.svg = this.testSVG();
15584
+ }
15585
+
15586
+ Support.prototype.testRangeBounds = function(document) {
15587
+ var range, testElement, rangeBounds, rangeHeight, support = false;
15588
+
15589
+ if (document.createRange) {
15590
+ range = document.createRange();
15591
+ if (range.getBoundingClientRect) {
15592
+ testElement = document.createElement('boundtest');
15593
+ testElement.style.height = "123px";
15594
+ testElement.style.display = "block";
15595
+ document.body.appendChild(testElement);
15596
+
15597
+ range.selectNode(testElement);
15598
+ rangeBounds = range.getBoundingClientRect();
15599
+ rangeHeight = rangeBounds.height;
15600
+
15601
+ if (rangeHeight === 123) {
15602
+ support = true;
15603
+ }
15604
+ document.body.removeChild(testElement);
15605
+ }
15606
+ }
15607
+
15608
+ return support;
15609
+ };
15610
+
15611
+ Support.prototype.testCORS = function() {
15612
+ return typeof((new Image()).crossOrigin) !== "undefined";
15613
+ };
15614
+
15615
+ Support.prototype.testSVG = function() {
15616
+ var img = new Image();
15617
+ var canvas = document.createElement("canvas");
15618
+ var ctx = canvas.getContext("2d");
15619
+ img.src = "data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg'></svg>";
15620
+
15621
+ try {
15622
+ ctx.drawImage(img, 0, 0);
15623
+ canvas.toDataURL();
15624
+ } catch(e) {
15625
+ return false;
15626
+ }
15627
+ return true;
15628
+ };
15629
+
15630
+ module.exports = Support;
15631
+
15632
+ },{}],26:[function(require,module,exports){
15633
+ var Promise = require('./promise');
15634
+ var XHR = require('./xhr');
15635
+ var decode64 = require('./utils').decode64;
15636
+
15637
+ function SVGContainer(src) {
15638
+ this.src = src;
15639
+ this.image = null;
15640
+ var self = this;
15641
+
15642
+ this.promise = this.hasFabric().then(function() {
15643
+ return (self.isInline(src) ? Promise.resolve(self.inlineFormatting(src)) : XHR(src));
15644
+ }).then(function(svg) {
15645
+ return new Promise(function(resolve) {
15646
+ window.html2canvas.svg.fabric.loadSVGFromString(svg, self.createCanvas.call(self, resolve));
15647
+ });
15648
+ });
15649
+ }
15650
+
15651
+ SVGContainer.prototype.hasFabric = function() {
15652
+ return !window.html2canvas.svg || !window.html2canvas.svg.fabric ? Promise.reject(new Error("html2canvas.svg.js is not loaded, cannot render svg")) : Promise.resolve();
15653
+ };
15654
+
15655
+ SVGContainer.prototype.inlineFormatting = function(src) {
15656
+ return (/^data:image\/svg\+xml;base64,/.test(src)) ? this.decode64(this.removeContentType(src)) : this.removeContentType(src);
15657
+ };
15658
+
15659
+ SVGContainer.prototype.removeContentType = function(src) {
15660
+ return src.replace(/^data:image\/svg\+xml(;base64)?,/,'');
15661
+ };
15662
+
15663
+ SVGContainer.prototype.isInline = function(src) {
15664
+ return (/^data:image\/svg\+xml/i.test(src));
15665
+ };
15666
+
15667
+ SVGContainer.prototype.createCanvas = function(resolve) {
15668
+ var self = this;
15669
+ return function (objects, options) {
15670
+ var canvas = new window.html2canvas.svg.fabric.StaticCanvas('c');
15671
+ self.image = canvas.lowerCanvasEl;
15672
+ canvas
15673
+ .setWidth(options.width)
15674
+ .setHeight(options.height)
15675
+ .add(window.html2canvas.svg.fabric.util.groupSVGElements(objects, options))
15676
+ .renderAll();
15677
+ resolve(canvas.lowerCanvasEl);
15678
+ };
15679
+ };
15680
+
15681
+ SVGContainer.prototype.decode64 = function(str) {
15682
+ return (typeof(window.atob) === "function") ? window.atob(str) : decode64(str);
15683
+ };
15684
+
15685
+ module.exports = SVGContainer;
15686
+
15687
+ },{"./promise":18,"./utils":29,"./xhr":31}],27:[function(require,module,exports){
15688
+ var SVGContainer = require('./svgcontainer');
15689
+ var Promise = require('./promise');
15690
+
15691
+ function SVGNodeContainer(node, _native) {
15692
+ this.src = node;
15693
+ this.image = null;
15694
+ var self = this;
15695
+
15696
+ this.promise = _native ? new Promise(function(resolve, reject) {
15697
+ self.image = new Image();
15698
+ self.image.onload = resolve;
15699
+ self.image.onerror = reject;
15700
+ self.image.src = "data:image/svg+xml," + (new XMLSerializer()).serializeToString(node);
15701
+ if (self.image.complete === true) {
15702
+ resolve(self.image);
15703
+ }
15704
+ }) : this.hasFabric().then(function() {
15705
+ return new Promise(function(resolve) {
15706
+ window.html2canvas.svg.fabric.parseSVGDocument(node, self.createCanvas.call(self, resolve));
15707
+ });
15708
+ });
15709
+ }
15710
+
15711
+ SVGNodeContainer.prototype = Object.create(SVGContainer.prototype);
15712
+
15713
+ module.exports = SVGNodeContainer;
15714
+
15715
+ },{"./promise":18,"./svgcontainer":26}],28:[function(require,module,exports){
15716
+ var NodeContainer = require('./nodecontainer');
15717
+
15718
+ function TextContainer(node, parent) {
15719
+ NodeContainer.call(this, node, parent);
15720
+ }
15721
+
15722
+ TextContainer.prototype = Object.create(NodeContainer.prototype);
15723
+
15724
+ TextContainer.prototype.applyTextTransform = function() {
15725
+ this.node.data = this.transform(this.parent.css("textTransform"));
15726
+ };
15727
+
15728
+ TextContainer.prototype.transform = function(transform) {
15729
+ var text = this.node.data;
15730
+ switch(transform){
15731
+ case "lowercase":
15732
+ return text.toLowerCase();
15733
+ case "capitalize":
15734
+ return text.replace(/(^|\s|:|-|\(|\))([a-z])/g, capitalize);
15735
+ case "uppercase":
15736
+ return text.toUpperCase();
15737
+ default:
15738
+ return text;
15739
+ }
15740
+ };
15741
+
15742
+ function capitalize(m, p1, p2) {
15743
+ if (m.length > 0) {
15744
+ return p1 + p2.toUpperCase();
15745
+ }
15746
+ }
15747
+
15748
+ module.exports = TextContainer;
15749
+
15750
+ },{"./nodecontainer":16}],29:[function(require,module,exports){
15751
+ exports.smallImage = function smallImage() {
15752
+ return "data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7";
15753
+ };
15754
+
15755
+ exports.bind = function(callback, context) {
15756
+ return function() {
15757
+ return callback.apply(context, arguments);
15758
+ };
15759
+ };
15760
+
15761
+ /*
15762
+ * base64-arraybuffer
15763
+ * https://github.com/niklasvh/base64-arraybuffer
15764
+ *
15765
+ * Copyright (c) 2012 Niklas von Hertzen
15766
+ * Licensed under the MIT license.
15767
+ */
15768
+
15769
+ exports.decode64 = function(base64) {
15770
+ var chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
15771
+ var len = base64.length, i, encoded1, encoded2, encoded3, encoded4, byte1, byte2, byte3;
15772
+
15773
+ var output = "";
15774
+
15775
+ for (i = 0; i < len; i+=4) {
15776
+ encoded1 = chars.indexOf(base64[i]);
15777
+ encoded2 = chars.indexOf(base64[i+1]);
15778
+ encoded3 = chars.indexOf(base64[i+2]);
15779
+ encoded4 = chars.indexOf(base64[i+3]);
15780
+
15781
+ byte1 = (encoded1 << 2) | (encoded2 >> 4);
15782
+ byte2 = ((encoded2 & 15) << 4) | (encoded3 >> 2);
15783
+ byte3 = ((encoded3 & 3) << 6) | encoded4;
15784
+ if (encoded3 === 64) {
15785
+ output += String.fromCharCode(byte1);
15786
+ } else if (encoded4 === 64 || encoded4 === -1) {
15787
+ output += String.fromCharCode(byte1, byte2);
15788
+ } else{
15789
+ output += String.fromCharCode(byte1, byte2, byte3);
15790
+ }
15791
+ }
15792
+
15793
+ return output;
15794
+ };
15795
+
15796
+ exports.getBounds = function(node) {
15797
+ if (node.getBoundingClientRect) {
15798
+ var clientRect = node.getBoundingClientRect();
15799
+ var width = node.offsetWidth == null ? clientRect.width : node.offsetWidth;
15800
+ return {
15801
+ top: clientRect.top,
15802
+ bottom: clientRect.bottom || (clientRect.top + clientRect.height),
15803
+ right: clientRect.left + width,
15804
+ left: clientRect.left,
15805
+ width: width,
15806
+ height: node.offsetHeight == null ? clientRect.height : node.offsetHeight
15807
+ };
15808
+ }
15809
+ return {};
15810
+ };
15811
+
15812
+ exports.offsetBounds = function(node) {
15813
+ var parent = node.offsetParent ? exports.offsetBounds(node.offsetParent) : {top: 0, left: 0};
15814
+
15815
+ return {
15816
+ top: node.offsetTop + parent.top,
15817
+ bottom: node.offsetTop + node.offsetHeight + parent.top,
15818
+ right: node.offsetLeft + parent.left + node.offsetWidth,
15819
+ left: node.offsetLeft + parent.left,
15820
+ width: node.offsetWidth,
15821
+ height: node.offsetHeight
15822
+ };
15823
+ };
15824
+
15825
+ exports.parseBackgrounds = function(backgroundImage) {
15826
+ var whitespace = ' \r\n\t',
15827
+ method, definition, prefix, prefix_i, block, results = [],
15828
+ mode = 0, numParen = 0, quote, args;
15829
+ var appendResult = function() {
15830
+ if(method) {
15831
+ if (definition.substr(0, 1) === '"') {
15832
+ definition = definition.substr(1, definition.length - 2);
15833
+ }
15834
+ if (definition) {
15835
+ args.push(definition);
15836
+ }
15837
+ if (method.substr(0, 1) === '-' && (prefix_i = method.indexOf('-', 1 ) + 1) > 0) {
15838
+ prefix = method.substr(0, prefix_i);
15839
+ method = method.substr(prefix_i);
15840
+ }
15841
+ results.push({
15842
+ prefix: prefix,
15843
+ method: method.toLowerCase(),
15844
+ value: block,
15845
+ args: args,
15846
+ image: null
15847
+ });
15848
+ }
15849
+ args = [];
15850
+ method = prefix = definition = block = '';
15851
+ };
15852
+ args = [];
15853
+ method = prefix = definition = block = '';
15854
+ backgroundImage.split("").forEach(function(c) {
15855
+ if (mode === 0 && whitespace.indexOf(c) > -1) {
15856
+ return;
15857
+ }
15858
+ switch(c) {
15859
+ case '"':
15860
+ if(!quote) {
15861
+ quote = c;
15862
+ } else if(quote === c) {
15863
+ quote = null;
15864
+ }
15865
+ break;
15866
+ case '(':
15867
+ if(quote) {
15868
+ break;
15869
+ } else if(mode === 0) {
15870
+ mode = 1;
15871
+ block += c;
15872
+ return;
15873
+ } else {
15874
+ numParen++;
15875
+ }
15876
+ break;
15877
+ case ')':
15878
+ if (quote) {
15879
+ break;
15880
+ } else if(mode === 1) {
15881
+ if(numParen === 0) {
15882
+ mode = 0;
15883
+ block += c;
15884
+ appendResult();
15885
+ return;
15886
+ } else {
15887
+ numParen--;
15888
+ }
15889
+ }
15890
+ break;
15891
+
15892
+ case ',':
15893
+ if (quote) {
15894
+ break;
15895
+ } else if(mode === 0) {
15896
+ appendResult();
15897
+ return;
15898
+ } else if (mode === 1) {
15899
+ if (numParen === 0 && !method.match(/^url$/i)) {
15900
+ args.push(definition);
15901
+ definition = '';
15902
+ block += c;
15903
+ return;
15904
+ }
15905
+ }
15906
+ break;
15907
+ }
15908
+
15909
+ block += c;
15910
+ if (mode === 0) {
15911
+ method += c;
15912
+ } else {
15913
+ definition += c;
15914
+ }
15915
+ });
15916
+
15917
+ appendResult();
15918
+ return results;
15919
+ };
15920
+
15921
+ },{}],30:[function(require,module,exports){
15922
+ var GradientContainer = require('./gradientcontainer');
15923
+
15924
+ function WebkitGradientContainer(imageData) {
15925
+ GradientContainer.apply(this, arguments);
15926
+ this.type = (imageData.args[0] === "linear") ? this.TYPES.LINEAR : this.TYPES.RADIAL;
15927
+ }
15928
+
15929
+ WebkitGradientContainer.prototype = Object.create(GradientContainer.prototype);
15930
+
15931
+ module.exports = WebkitGradientContainer;
15932
+
15933
+ },{"./gradientcontainer":11}],31:[function(require,module,exports){
15934
+ var Promise = require('./promise');
15935
+
15936
+ function XHR(url) {
15937
+ return new Promise(function(resolve, reject) {
15938
+ var xhr = new XMLHttpRequest();
15939
+ xhr.open('GET', url);
15940
+
15941
+ xhr.onload = function() {
15942
+ if (xhr.status === 200) {
15943
+ resolve(xhr.responseText);
15944
+ } else {
15945
+ reject(new Error(xhr.statusText));
15946
+ }
15947
+ };
15948
+
15949
+ xhr.onerror = function() {
15950
+ reject(new Error("Network Error"));
15951
+ };
15952
+
15953
+ xhr.send();
15954
+ });
15955
+ }
15956
+
15957
+ module.exports = XHR;
15958
+
15959
+ },{"./promise":18}]},{},[6])(6)
15960
+ });
15961
+ /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
15962
 
15963
  /***/ },
15964
 
15965
+ /***/ 529:
15966
  /***/ function(module, exports, __webpack_require__) {
15967
 
15968
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
15969
 
15970
+ !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(2), __webpack_require__(181), __webpack_require__(276), __webpack_require__(433)], __WEBPACK_AMD_DEFINE_RESULT__ = function (React, Router, MailPoet, Breadcrumb) {
15971
  var NewsletterStandard = React.createClass({
15972
  displayName: 'NewsletterStandard',
15973
 
16017
 
16018
  /***/ },
16019
 
16020
+ /***/ 530:
16021
  /***/ function(module, exports, __webpack_require__) {
16022
 
16023
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
16024
 
16025
+ !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(280), __webpack_require__(2), __webpack_require__(181), __webpack_require__(276), __webpack_require__(521), __webpack_require__(433)], __WEBPACK_AMD_DEFINE_RESULT__ = function (_, React, Router, MailPoet, Scheduling, Breadcrumb) {
16026
  var field = {
16027
  name: 'options',
16028
  type: 'reactComponent',
16112
 
16113
  /***/ },
16114
 
16115
+ /***/ 531:
16116
  /***/ function(module, exports, __webpack_require__) {
16117
 
16118
  'use strict';
16125
 
16126
  var _reactRouter = __webpack_require__(181);
16127
 
16128
+ var _reactConfirmAlert = __webpack_require__(436);
16129
 
16130
  var _classnames = __webpack_require__(277);
16131
 
16135
 
16136
  var _mailpoet2 = _interopRequireDefault(_mailpoet);
16137
 
16138
+ var _wpJsHooks = __webpack_require__(430);
16139
 
16140
  var _wpJsHooks2 = _interopRequireDefault(_wpJsHooks);
16141
 
16143
 
16144
  var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
16145
 
16146
+ var _newslettersListingsTabsJsx = __webpack_require__(532);
16147
 
16148
  var _newslettersListingsTabsJsx2 = _interopRequireDefault(_newslettersListingsTabsJsx);
16149
 
16150
+ var _newslettersListingsMixinsJsx = __webpack_require__(533);
16151
 
16152
  var mailpoetTrackingEnabled = !!window.mailpoet_tracking_enabled;
16153
 
16377
 
16378
  /***/ },
16379
 
16380
+ /***/ 532:
16381
  /***/ function(module, exports, __webpack_require__) {
16382
 
16383
  'use strict';
16451
 
16452
  /***/ },
16453
 
16454
+ /***/ 533:
16455
  /***/ function(module, exports, __webpack_require__) {
16456
 
16457
  'use strict';
16470
 
16471
  var _reactDom2 = _interopRequireDefault(_reactDom);
16472
 
16473
+ var _reactStringReplace = __webpack_require__(423);
16474
 
16475
  var _reactStringReplace2 = _interopRequireDefault(_reactStringReplace);
16476
 
16492
 
16493
  var _jquery2 = _interopRequireDefault(_jquery);
16494
 
16495
+ var _wpJsHooks = __webpack_require__(430);
16496
 
16497
  var _wpJsHooks2 = _interopRequireDefault(_wpJsHooks);
16498
 
16499
+ var _newslettersBadgesStatsJsx = __webpack_require__(534);
16500
 
16501
  var _newslettersBadgesStatsJsx2 = _interopRequireDefault(_newslettersBadgesStatsJsx);
16502
 
16960
 
16961
  /***/ },
16962
 
16963
+ /***/ 537:
16964
  /***/ function(module, exports, __webpack_require__) {
16965
 
16966
  'use strict';
16977
 
16978
  var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
16979
 
16980
+ var _newslettersListingsTabsJsx = __webpack_require__(532);
16981
 
16982
  var _newslettersListingsTabsJsx2 = _interopRequireDefault(_newslettersListingsTabsJsx);
16983
 
16984
+ var _newslettersListingsMixinsJsx = __webpack_require__(533);
16985
 
16986
  var _classnames = __webpack_require__(277);
16987
 
16995
 
16996
  var _underscore2 = _interopRequireDefault(_underscore);
16997
 
16998
+ var _wpJsHooks = __webpack_require__(430);
16999
 
17000
  var _wpJsHooks2 = _interopRequireDefault(_wpJsHooks);
17001
 
17314
 
17315
  /***/ },
17316
 
17317
+ /***/ 538:
17318
  /***/ function(module, exports, __webpack_require__) {
17319
 
17320
  'use strict';
17331
 
17332
  var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
17333
 
17334
+ var _newslettersListingsTabsJsx = __webpack_require__(532);
17335
 
17336
  var _newslettersListingsTabsJsx2 = _interopRequireDefault(_newslettersListingsTabsJsx);
17337
 
17338
+ var _newslettersListingsMixinsJsx = __webpack_require__(533);
17339
 
17340
  var _classnames = __webpack_require__(277);
17341
 
17345
 
17346
  var _mailpoet2 = _interopRequireDefault(_mailpoet);
17347
 
17348
+ var _newslettersSchedulingCommonJsx = __webpack_require__(522);
17349
 
17350
  var messages = {
17351
  onTrash: function onTrash(response) {
17662
 
17663
  /***/ },
17664
 
17665
+ /***/ 539:
17666
  /***/ function(module, exports, __webpack_require__) {
17667
 
17668
  'use strict';
17683
 
17684
  var _mailpoet2 = _interopRequireDefault(_mailpoet);
17685
 
17686
+ var _wpJsHooks = __webpack_require__(430);
17687
 
17688
  var _wpJsHooks2 = _interopRequireDefault(_wpJsHooks);
17689
 
17691
 
17692
  var _listingListingJsx2 = _interopRequireDefault(_listingListingJsx);
17693
 
17694
+ var _newslettersListingsTabsJsx = __webpack_require__(532);
17695
 
17696
  var _newslettersListingsTabsJsx2 = _interopRequireDefault(_newslettersListingsTabsJsx);
17697
 
17698
+ var _newslettersListingsMixinsJsx = __webpack_require__(533);
17699
 
17700
  var mailpoetTrackingEnabled = !!window.mailpoet_tracking_enabled;
17701
 
17831
 
17832
  /***/ },
17833
 
17834
+ /***/ 540:
17835
  /***/ function(module, exports, __webpack_require__) {
17836
 
17837
  'use strict';
17850
 
17851
  var _history = __webpack_require__(244);
17852
 
17853
+ var _segmentsListJsx = __webpack_require__(541);
17854
 
17855
  var _segmentsListJsx2 = _interopRequireDefault(_segmentsListJsx);
17856
 
17857
+ var _segmentsFormJsx = __webpack_require__(542);
17858
 
17859
  var _segmentsFormJsx2 = _interopRequireDefault(_segmentsFormJsx);
17860
 
17887
 
17888
  /***/ },
17889
 
17890
+ /***/ 541:
17891
  /***/ function(module, exports, __webpack_require__) {
17892
 
17893
  'use strict';
18207
 
18208
  /***/ },
18209
 
18210
+ /***/ 542:
18211
  /***/ function(module, exports, __webpack_require__) {
18212
 
18213
  /* WEBPACK VAR INJECTION */(function(global) {"use strict";
18214
 
18215
  if (!global["MailPoetLib"]) global["MailPoetLib"] = {};
18216
+ module.exports = global["MailPoetLib"]["Form"] = __webpack_require__(543);
18217
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
18218
 
18219
  /***/ },
18220
 
18221
+ /***/ 543:
18222
  /***/ function(module, exports, __webpack_require__) {
18223
 
18224
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
18281
 
18282
  /***/ },
18283
 
18284
+ /***/ 544:
18285
  /***/ function(module, exports, __webpack_require__) {
18286
 
18287
  'use strict';
18300
 
18301
  var _history = __webpack_require__(244);
18302
 
18303
+ var _listJsx = __webpack_require__(545);
18304
 
18305
  var _listJsx2 = _interopRequireDefault(_listJsx);
18306
 
18331
 
18332
  /***/ },
18333
 
18334
+ /***/ 545:
18335
  /***/ function(module, exports, __webpack_require__) {
18336
 
18337
  'use strict';
18563
 
18564
  /***/ },
18565
 
18566
+ /***/ 546:
18567
  /***/ function(module, exports, __webpack_require__) {
18568
 
18569
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
18570
+ __webpack_require__(547),
18571
  __webpack_require__(275),
18572
  __webpack_require__(276)
18573
  ], __WEBPACK_AMD_DEFINE_RESULT__ = function ( // eslint-disable-line func-names
18656
 
18657
  /***/ },
18658
 
18659
+ /***/ 547:
18660
  /***/ function(module, exports, __webpack_require__) {
18661
 
18662
+ /* WEBPACK VAR INJECTION */(function(global) {module.exports = global["Backbone"] = __webpack_require__(548);
18663
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
18664
 
18665
  /***/ },
18666
 
18667
+ /***/ 548:
18668
  /***/ function(module, exports, __webpack_require__) {
18669
 
18670
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/* WEBPACK VAR INJECTION */(function(global) {// Backbone.js 1.3.3
20592
 
20593
  /***/ },
20594
 
20595
+ /***/ 549:
20596
  /***/ function(module, exports, __webpack_require__) {
20597
 
20598
  'use strict';
20611
 
20612
  var _history = __webpack_require__(244);
20613
 
20614
+ var _helpSystem_statusJsx = __webpack_require__(550);
20615
 
20616
  var _helpSystem_statusJsx2 = _interopRequireDefault(_helpSystem_statusJsx);
20617
 
20618
+ var _helpSystem_infoJsx = __webpack_require__(552);
20619
 
20620
  var _helpSystem_infoJsx2 = _interopRequireDefault(_helpSystem_infoJsx);
20621
 
20622
+ var _helpKnowledge_baseJsx = __webpack_require__(553);
20623
 
20624
  var _helpKnowledge_baseJsx2 = _interopRequireDefault(_helpKnowledge_baseJsx);
20625
 
20653
 
20654
  /***/ },
20655
 
20656
+ /***/ 550:
20657
  /***/ function(module, exports, __webpack_require__) {
20658
 
20659
  'use strict';
20668
 
20669
  var _react2 = _interopRequireDefault(_react);
20670
 
20671
+ var _reactStringReplace = __webpack_require__(423);
20672
 
20673
  var _reactStringReplace2 = _interopRequireDefault(_reactStringReplace);
20674
 
20675
+ var _tabsJsx = __webpack_require__(551);
20676
 
20677
  var _tabsJsx2 = _interopRequireDefault(_tabsJsx);
20678
 
20767
 
20768
  /***/ },
20769
 
20770
+ /***/ 551:
20771
  /***/ function(module, exports, __webpack_require__) {
20772
 
20773
  'use strict';
20831
 
20832
  /***/ },
20833
 
20834
+ /***/ 552:
20835
  /***/ function(module, exports, __webpack_require__) {
20836
 
20837
  'use strict';
20850
 
20851
  var _underscore2 = _interopRequireDefault(_underscore);
20852
 
20853
+ var _tabsJsx = __webpack_require__(551);
20854
 
20855
  var _tabsJsx2 = _interopRequireDefault(_tabsJsx);
20856
 
20904
 
20905
  /***/ },
20906
 
20907
+ /***/ 553:
20908
  /***/ function(module, exports, __webpack_require__) {
20909
 
20910
  'use strict';
20919
 
20920
  var _mailpoet2 = _interopRequireDefault(_mailpoet);
20921
 
20922
+ var _tabsJsx = __webpack_require__(551);
20923
 
20924
  var _tabsJsx2 = _interopRequireDefault(_tabsJsx);
20925
 
21021
 
21022
  /***/ },
21023
 
21024
+ /***/ 554:
21025
  /***/ function(module, exports, __webpack_require__) {
21026
 
21027
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
21069
 
21070
  /***/ },
21071
 
21072
+ /***/ 555:
21073
  /***/ function(module, exports, __webpack_require__) {
21074
 
21075
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/* eslint-disable func-names */
21076
  !(__WEBPACK_AMD_DEFINE_ARRAY__ = [
21077
+ __webpack_require__(547),
21078
  __webpack_require__(280),
21079
  __webpack_require__(275),
21080
  __webpack_require__(276),
21081
+ __webpack_require__(556),
21082
+ __webpack_require__(557),
21083
+ __webpack_require__(558),
21084
  __webpack_require__(301)
21085
  ], __WEBPACK_AMD_DEFINE_RESULT__ = function (
21086
  Backbone,
22243
 
22244
  /***/ },
22245
 
22246
+ /***/ 557:
22247
  /***/ function(module, exports) {
22248
 
22249
  /*!
22255
 
22256
  /***/ },
22257
 
22258
+ /***/ 558:
22259
  /***/ function(module, exports) {
22260
 
22261
  /*
22341
 
22342
  /***/ },
22343
 
22344
+ /***/ 559:
22345
  /***/ function(module, exports, __webpack_require__) {
22346
 
22347
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
22348
  __webpack_require__(280),
22349
  __webpack_require__(275),
22350
  __webpack_require__(276),
22351
+ __webpack_require__(556)
22352
  ], __WEBPACK_AMD_DEFINE_RESULT__ = function (// eslint-disable-line func-names
22353
  _,
22354
  jQuery,
assets/js/{admin_vendor.2bc811e8.js → admin_vendor.1b9d5c2b.js} RENAMED
@@ -5,12 +5,12 @@ webpackJsonp([1],[
5
  __webpack_require__(2);
6
  __webpack_require__(34);
7
  __webpack_require__(181);
8
- __webpack_require__(422);
9
  __webpack_require__(278);
10
  __webpack_require__(292);
11
- __webpack_require__(531);
12
- __webpack_require__(432);
13
- __webpack_require__(524);
14
  module.exports = __webpack_require__(244);
15
 
16
 
@@ -40835,7 +40835,7 @@ webpackJsonp([1],[
40835
  /***/ function(module, exports, __webpack_require__) {
40836
 
40837
  var require;/* WEBPACK VAR INJECTION */(function(module) {//! moment.js
40838
- //! version : 2.19.3
40839
  //! authors : Tim Wood, Iskren Chernev, Moment.js contributors
40840
  //! license : MIT
40841
  //! momentjs.com
@@ -41495,7 +41495,7 @@ webpackJsonp([1],[
41495
 
41496
  // any word (or two) characters or numbers including two/three word month in arabic.
41497
  // includes scottish gaelic two word and hyphenated months
41498
- var matchWord = /[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i;
41499
 
41500
 
41501
  var regexes = {};
@@ -42865,7 +42865,7 @@ webpackJsonp([1],[
42865
  // note: all values past the year are optional and will default to the lowest possible value.
42866
  // [year, month, day , hour, minute, second, millisecond]
42867
  function configFromArray (config) {
42868
- var i, date, input = [], currentDate, yearToUse;
42869
 
42870
  if (config._d) {
42871
  return;
@@ -42915,6 +42915,8 @@ webpackJsonp([1],[
42915
  }
42916
 
42917
  config._d = (config._useUTC ? createUTCDate : createDate).apply(null, input);
 
 
42918
  // Apply timezone offset from input. The actual utcOffset can be changed
42919
  // with parseZone.
42920
  if (config._tzm != null) {
@@ -42926,7 +42928,7 @@ webpackJsonp([1],[
42926
  }
42927
 
42928
  // check for mismatching day of week
42929
- if (config._w && typeof config._w.d !== 'undefined' && config._w.d !== config._d.getDay()) {
42930
  getParsingFlags(config).weekdayMismatch = true;
42931
  }
42932
  }
@@ -44134,19 +44136,24 @@ webpackJsonp([1],[
44134
  return this.clone().locale('en').format('ddd MMM DD YYYY HH:mm:ss [GMT]ZZ');
44135
  }
44136
 
44137
- function toISOString() {
44138
  if (!this.isValid()) {
44139
  return null;
44140
  }
44141
- var m = this.clone().utc();
 
44142
  if (m.year() < 0 || m.year() > 9999) {
44143
- return formatMoment(m, 'YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]');
44144
  }
44145
  if (isFunction(Date.prototype.toISOString)) {
44146
  // native implementation is ~50x faster, use it when we can
44147
- return this.toDate().toISOString();
 
 
 
 
44148
  }
44149
- return formatMoment(m, 'YYYY-MM-DD[T]HH:mm:ss.SSS[Z]');
44150
  }
44151
 
44152
  /**
@@ -44502,7 +44509,7 @@ webpackJsonp([1],[
44502
 
44503
  addParseToken(['D', 'DD'], DATE);
44504
  addParseToken('Do', function (input, array) {
44505
- array[DATE] = toInt(input.match(match1to2)[0], 10);
44506
  });
44507
 
44508
  // MOMENTS
@@ -45314,7 +45321,7 @@ webpackJsonp([1],[
45314
  // Side effect imports
45315
 
45316
 
45317
- hooks.version = '2.19.3';
45318
 
45319
  setHookCallback(createLocal);
45320
 
@@ -45346,6 +45353,19 @@ webpackJsonp([1],[
45346
  hooks.calendarFormat = getCalendarFormat;
45347
  hooks.prototype = proto;
45348
 
 
 
 
 
 
 
 
 
 
 
 
 
 
45349
  return hooks;
45350
 
45351
  })));
@@ -45523,92 +45543,94 @@ webpackJsonp([1],[
45523
  "./ms-my": 378,
45524
  "./ms-my.js": 378,
45525
  "./ms.js": 377,
45526
- "./my": 379,
45527
- "./my.js": 379,
45528
- "./nb": 380,
45529
- "./nb.js": 380,
45530
- "./ne": 381,
45531
- "./ne.js": 381,
45532
- "./nl": 382,
45533
- "./nl-be": 383,
45534
- "./nl-be.js": 383,
45535
- "./nl.js": 382,
45536
- "./nn": 384,
45537
- "./nn.js": 384,
45538
- "./pa-in": 385,
45539
- "./pa-in.js": 385,
45540
- "./pl": 386,
45541
- "./pl.js": 386,
45542
- "./pt": 387,
45543
- "./pt-br": 388,
45544
- "./pt-br.js": 388,
45545
- "./pt.js": 387,
45546
- "./ro": 389,
45547
- "./ro.js": 389,
45548
- "./ru": 390,
45549
- "./ru.js": 390,
45550
- "./sd": 391,
45551
- "./sd.js": 391,
45552
- "./se": 392,
45553
- "./se.js": 392,
45554
- "./si": 393,
45555
- "./si.js": 393,
45556
- "./sk": 394,
45557
- "./sk.js": 394,
45558
- "./sl": 395,
45559
- "./sl.js": 395,
45560
- "./sq": 396,
45561
- "./sq.js": 396,
45562
- "./sr": 397,
45563
- "./sr-cyrl": 398,
45564
- "./sr-cyrl.js": 398,
45565
- "./sr.js": 397,
45566
- "./ss": 399,
45567
- "./ss.js": 399,
45568
- "./sv": 400,
45569
- "./sv.js": 400,
45570
- "./sw": 401,
45571
- "./sw.js": 401,
45572
- "./ta": 402,
45573
- "./ta.js": 402,
45574
- "./te": 403,
45575
- "./te.js": 403,
45576
- "./tet": 404,
45577
- "./tet.js": 404,
45578
- "./th": 405,
45579
- "./th.js": 405,
45580
- "./tl-ph": 406,
45581
- "./tl-ph.js": 406,
45582
- "./tlh": 407,
45583
- "./tlh.js": 407,
45584
- "./tr": 408,
45585
- "./tr.js": 408,
45586
- "./tzl": 409,
45587
- "./tzl.js": 409,
45588
- "./tzm": 410,
45589
- "./tzm-latn": 411,
45590
- "./tzm-latn.js": 411,
45591
- "./tzm.js": 410,
45592
- "./uk": 412,
45593
- "./uk.js": 412,
45594
- "./ur": 413,
45595
- "./ur.js": 413,
45596
- "./uz": 414,
45597
- "./uz-latn": 415,
45598
- "./uz-latn.js": 415,
45599
- "./uz.js": 414,
45600
- "./vi": 416,
45601
- "./vi.js": 416,
45602
- "./x-pseudo": 417,
45603
- "./x-pseudo.js": 417,
45604
- "./yo": 418,
45605
- "./yo.js": 418,
45606
- "./zh-cn": 419,
45607
- "./zh-cn.js": 419,
45608
- "./zh-hk": 420,
45609
- "./zh-hk.js": 420,
45610
- "./zh-tw": 421,
45611
- "./zh-tw.js": 421
 
 
45612
  };
45613
  function webpackContext(req) {
45614
  return __webpack_require__(webpackContextResolve(req));
@@ -45676,6 +45698,7 @@ webpackJsonp([1],[
45676
  future : 'oor %s',
45677
  past : '%s gelede',
45678
  s : '\'n paar sekondes',
 
45679
  m : '\'n minuut',
45680
  mm : '%d minute',
45681
  h : '\'n uur',
@@ -45765,18 +45788,18 @@ webpackJsonp([1],[
45765
  };
45766
  };
45767
  var months = [
45768
- 'كانون الثاني يناير',
45769
- 'شباط فبراير',
45770
- 'آذار مارس',
45771
- 'نيسان أبريل',
45772
- 'أيار مايو',
45773
- 'حزيران يونيو',
45774
- 'تموز يوليو',
45775
- 'آب أغسطس',
45776
- 'أيلول سبتمبر',
45777
- 'تشرين الأول أكتوبر',
45778
- 'تشرين الثاني نوفمبر',
45779
- 'كانون الأول ديسمبر'
45780
  ];
45781
 
45782
  var ar = moment.defineLocale('ar', {
@@ -45817,6 +45840,7 @@ webpackJsonp([1],[
45817
  future : 'بعد %s',
45818
  past : 'منذ %s',
45819
  s : pluralize('s'),
 
45820
  m : pluralize('m'),
45821
  mm : pluralize('m'),
45822
  h : pluralize('h'),
@@ -45891,6 +45915,7 @@ webpackJsonp([1],[
45891
  future : 'في %s',
45892
  past : 'منذ %s',
45893
  s : 'ثوان',
 
45894
  m : 'دقيقة',
45895
  mm : '%d دقائق',
45896
  h : 'ساعة',
@@ -45955,6 +45980,7 @@ webpackJsonp([1],[
45955
  future : 'في %s',
45956
  past : 'منذ %s',
45957
  s : 'ثوان',
 
45958
  m : 'دقيقة',
45959
  mm : '%d دقائق',
45960
  h : 'ساعة',
@@ -46078,6 +46104,7 @@ webpackJsonp([1],[
46078
  future : 'بعد %s',
46079
  past : 'منذ %s',
46080
  s : pluralize('s'),
 
46081
  m : pluralize('m'),
46082
  mm : pluralize('m'),
46083
  h : pluralize('h'),
@@ -46151,6 +46178,7 @@ webpackJsonp([1],[
46151
  future : 'في %s',
46152
  past : 'منذ %s',
46153
  s : 'ثوان',
 
46154
  m : 'دقيقة',
46155
  mm : '%d دقائق',
46156
  h : 'ساعة',
@@ -46251,6 +46279,7 @@ webpackJsonp([1],[
46251
  future : 'في %s',
46252
  past : 'منذ %s',
46253
  s : 'ثوان',
 
46254
  m : 'دقيقة',
46255
  mm : '%d دقائق',
46256
  h : 'ساعة',
@@ -46325,6 +46354,7 @@ webpackJsonp([1],[
46325
  future: 'في %s',
46326
  past: 'منذ %s',
46327
  s: 'ثوان',
 
46328
  m: 'دقيقة',
46329
  mm: '%d دقائق',
46330
  h: 'ساعة',
@@ -46410,6 +46440,7 @@ webpackJsonp([1],[
46410
  future : '%s sonra',
46411
  past : '%s əvvəl',
46412
  s : 'birneçə saniyyə',
 
46413
  m : 'bir dəqiqə',
46414
  mm : '%d dəqiqə',
46415
  h : 'bir saat',
@@ -46480,6 +46511,7 @@ webpackJsonp([1],[
46480
  }
46481
  function relativeTimeWithPlural(number, withoutSuffix, key) {
46482
  var format = {
 
46483
  'mm': withoutSuffix ? 'хвіліна_хвіліны_хвілін' : 'хвіліну_хвіліны_хвілін',
46484
  'hh': withoutSuffix ? 'гадзіна_гадзіны_гадзін' : 'гадзіну_гадзіны_гадзін',
46485
  'dd': 'дзень_дні_дзён',
@@ -46649,6 +46681,7 @@ webpackJsonp([1],[
46649
  future : 'след %s',
46650
  past : 'преди %s',
46651
  s : 'няколко секунди',
 
46652
  m : 'минута',
46653
  mm : '%d минути',
46654
  h : 'час',
@@ -46733,6 +46766,7 @@ webpackJsonp([1],[
46733
  future : '%s kɔnɔ',
46734
  past : 'a bɛ %s bɔ',
46735
  s : 'sanga dama dama',
 
46736
  m : 'miniti kelen',
46737
  mm : 'miniti %d',
46738
  h : 'lɛrɛ kelen',
@@ -46821,6 +46855,7 @@ webpackJsonp([1],[
46821
  future : '%s পরে',
46822
  past : '%s আগে',
46823
  s : 'কয়েক সেকেন্ড',
 
46824
  m : 'এক মিনিট',
46825
  mm : '%d মিনিট',
46826
  h : 'এক ঘন্টা',
@@ -46945,6 +46980,7 @@ webpackJsonp([1],[
46945
  future : '%s ལ་',
46946
  past : '%s སྔན་ལ',
46947
  s : 'ལམ་སང',
 
46948
  m : 'སྐར་མ་གཅིག',
46949
  mm : '%d སྐར་མ',
46950
  h : 'ཆུ་ཚོད་གཅིག',
@@ -47089,6 +47125,7 @@ webpackJsonp([1],[
47089
  future : 'a-benn %s',
47090
  past : '%s \'zo',
47091
  s : 'un nebeud segondennoù',
 
47092
  m : 'ur vunutenn',
47093
  mm : relativeTimeWithMutation,
47094
  h : 'un eur',
@@ -47135,6 +47172,15 @@ webpackJsonp([1],[
47135
  function translate(number, withoutSuffix, key) {
47136
  var result = number + ' ';
47137
  switch (key) {
 
 
 
 
 
 
 
 
 
47138
  case 'm':
47139
  return withoutSuffix ? 'jedna minuta' : 'jedne minute';
47140
  case 'mm':
@@ -47240,6 +47286,7 @@ webpackJsonp([1],[
47240
  future : 'za %s',
47241
  past : 'prije %s',
47242
  s : 'par sekundi',
 
47243
  m : translate,
47244
  mm : translate,
47245
  h : translate,
@@ -47324,6 +47371,7 @@ webpackJsonp([1],[
47324
  future : 'd\'aquí %s',
47325
  past : 'fa %s',
47326
  s : 'uns segons',
 
47327
  m : 'un minut',
47328
  mm : '%d minuts',
47329
  h : 'una hora',
@@ -47382,6 +47430,13 @@ webpackJsonp([1],[
47382
  switch (key) {
47383
  case 's': // a few seconds / in a few seconds / a few seconds ago
47384
  return (withoutSuffix || isFuture) ? 'pár sekund' : 'pár sekundami';
 
 
 
 
 
 
 
47385
  case 'm': // a minute / in a minute / a minute ago
47386
  return withoutSuffix ? 'minuta' : (isFuture ? 'minutu' : 'minutou');
47387
  case 'mm': // 9 minutes / in 9 minutes / 9 minutes ago
@@ -47510,6 +47565,7 @@ webpackJsonp([1],[
47510
  future : 'za %s',
47511
  past : 'před %s',
47512
  s : translate,
 
47513
  m : translate,
47514
  mm : translate,
47515
  h : translate,
@@ -47578,6 +47634,7 @@ webpackJsonp([1],[
47578
  },
47579
  past : '%s каялла',
47580
  s : 'пӗр-ик ҫеккунт',
 
47581
  m : 'пӗр минут',
47582
  mm : '%d минут',
47583
  h : 'пӗр сехет',
@@ -47646,6 +47703,7 @@ webpackJsonp([1],[
47646
  future: 'mewn %s',
47647
  past: '%s yn ôl',
47648
  s: 'ychydig eiliadau',
 
47649
  m: 'munud',
47650
  mm: '%d munud',
47651
  h: 'awr',
@@ -47729,6 +47787,7 @@ webpackJsonp([1],[
47729
  future : 'om %s',
47730
  past : '%s siden',
47731
  s : 'få sekunder',
 
47732
  m : 'et minut',
47733
  mm : '%d minutter',
47734
  h : 'en time',
@@ -47812,6 +47871,7 @@ webpackJsonp([1],[
47812
  future : 'in %s',
47813
  past : 'vor %s',
47814
  s : 'ein paar Sekunden',
 
47815
  m : processRelativeTime,
47816
  mm : '%d Minuten',
47817
  h : processRelativeTime,
@@ -47896,6 +47956,7 @@ webpackJsonp([1],[
47896
  future : 'in %s',
47897
  past : 'vor %s',
47898
  s : 'ein paar Sekunden',
 
47899
  m : processRelativeTime,
47900
  mm : '%d Minuten',
47901
  h : processRelativeTime,
@@ -47960,12 +48021,12 @@ webpackJsonp([1],[
47960
  weekdaysMin : 'So_Mo_Di_Mi_Do_Fr_Sa'.split('_'),
47961
  weekdaysParseExact : true,
47962
  longDateFormat : {
47963
- LT: 'HH.mm',
47964
- LTS: 'HH.mm.ss',
47965
  L : 'DD.MM.YYYY',
47966
  LL : 'D. MMMM YYYY',
47967
- LLL : 'D. MMMM YYYY HH.mm',
47968
- LLLL : 'dddd, D. MMMM YYYY HH.mm'
47969
  },
47970
  calendar : {
47971
  sameDay: '[heute um] LT [Uhr]',
@@ -47979,6 +48040,7 @@ webpackJsonp([1],[
47979
  future : 'in %s',
47980
  past : 'vor %s',
47981
  s : 'ein paar Sekunden',
 
47982
  m : processRelativeTime,
47983
  mm : '%d Minuten',
47984
  h : processRelativeTime,
@@ -48080,6 +48142,7 @@ webpackJsonp([1],[
48080
  future : 'ތެރޭގައި %s',
48081
  past : 'ކުރިން %s',
48082
  s : 'ސިކުންތުކޮޅެއް',
 
48083
  m : 'މިނިޓެއް',
48084
  mm : 'މިނިޓު %d',
48085
  h : 'ގަޑިއިރެއް',
@@ -48189,6 +48252,7 @@ webpackJsonp([1],[
48189
  future : 'σε %s',
48190
  past : '%s πριν',
48191
  s : 'λίγα δευτερόλεπτα',
 
48192
  m : 'ένα λεπτό',
48193
  mm : '%d λεπτά',
48194
  h : 'μία ώρα',
@@ -48254,6 +48318,7 @@ webpackJsonp([1],[
48254
  future : 'in %s',
48255
  past : '%s ago',
48256
  s : 'a few seconds',
 
48257
  m : 'a minute',
48258
  mm : '%d minutes',
48259
  h : 'an hour',
@@ -48326,6 +48391,7 @@ webpackJsonp([1],[
48326
  future : 'in %s',
48327
  past : '%s ago',
48328
  s : 'a few seconds',
 
48329
  m : 'a minute',
48330
  mm : '%d minutes',
48331
  h : 'an hour',
@@ -48394,6 +48460,7 @@ webpackJsonp([1],[
48394
  future : 'in %s',
48395
  past : '%s ago',
48396
  s : 'a few seconds',
 
48397
  m : 'a minute',
48398
  mm : '%d minutes',
48399
  h : 'an hour',
@@ -48466,6 +48533,7 @@ webpackJsonp([1],[
48466
  future : 'in %s',
48467
  past : '%s ago',
48468
  s : 'a few seconds',
 
48469
  m : 'a minute',
48470
  mm : '%d minutes',
48471
  h : 'an hour',
@@ -48538,6 +48606,7 @@ webpackJsonp([1],[
48538
  future : 'in %s',
48539
  past : '%s ago',
48540
  s : 'a few seconds',
 
48541
  m : 'a minute',
48542
  mm : '%d minutes',
48543
  h : 'an hour',
@@ -48623,6 +48692,7 @@ webpackJsonp([1],[
48623
  future : 'post %s',
48624
  past : 'antaŭ %s',
48625
  s : 'sekundoj',
 
48626
  m : 'minuto',
48627
  mm : '%d minutoj',
48628
  h : 'horo',
@@ -48720,6 +48790,7 @@ webpackJsonp([1],[
48720
  future : 'en %s',
48721
  past : 'hace %s',
48722
  s : 'unos segundos',
 
48723
  m : 'un minuto',
48724
  mm : '%d minutos',
48725
  h : 'una hora',
@@ -48816,6 +48887,7 @@ webpackJsonp([1],[
48816
  future : 'en %s',
48817
  past : 'hace %s',
48818
  s : 'unos segundos',
 
48819
  m : 'un minuto',
48820
  mm : '%d minutos',
48821
  h : 'una hora',
@@ -48875,12 +48947,12 @@ webpackJsonp([1],[
48875
  weekdaysMin : 'do_lu_ma_mi_ju_vi_sá'.split('_'),
48876
  weekdaysParseExact : true,
48877
  longDateFormat : {
48878
- LT : 'H:mm',
48879
- LTS : 'H:mm:ss',
48880
  L : 'MM/DD/YYYY',
48881
  LL : 'MMMM [de] D [de] YYYY',
48882
- LLL : 'MMMM [de] D [de] YYYY H:mm',
48883
- LLLL : 'dddd, MMMM [de] D [de] YYYY H:mm'
48884
  },
48885
  calendar : {
48886
  sameDay : function () {
@@ -48904,6 +48976,7 @@ webpackJsonp([1],[
48904
  future : 'en %s',
48905
  past : 'hace %s',
48906
  s : 'unos segundos',
 
48907
  m : 'un minuto',
48908
  mm : '%d minutos',
48909
  h : 'una hora',
@@ -48947,6 +49020,7 @@ webpackJsonp([1],[
48947
  function processRelativeTime(number, withoutSuffix, key, isFuture) {
48948
  var format = {
48949
  's' : ['mõne sekundi', 'mõni sekund', 'paar sekundit'],
 
48950
  'm' : ['ühe minuti', 'üks minut'],
48951
  'mm': [number + ' minuti', number + ' minutit'],
48952
  'h' : ['ühe tunni', 'tund aega', 'üks tund'],
@@ -48989,6 +49063,7 @@ webpackJsonp([1],[
48989
  future : '%s pärast',
48990
  past : '%s tagasi',
48991
  s : processRelativeTime,
 
48992
  m : processRelativeTime,
48993
  mm : processRelativeTime,
48994
  h : processRelativeTime,
@@ -49060,6 +49135,7 @@ webpackJsonp([1],[
49060
  future : '%s barru',
49061
  past : 'duela %s',
49062
  s : 'segundo batzuk',
 
49063
  m : 'minutu bat',
49064
  mm : '%d minutu',
49065
  h : 'ordu bat',
@@ -49162,6 +49238,7 @@ webpackJsonp([1],[
49162
  future : 'در %s',
49163
  past : '%s پیش',
49164
  s : 'چند ثانیه',
 
49165
  m : 'یک دقیقه',
49166
  mm : '%d دقیقه',
49167
  h : 'یک ساعت',
@@ -49221,6 +49298,8 @@ webpackJsonp([1],[
49221
  switch (key) {
49222
  case 's':
49223
  return isFuture ? 'muutaman sekunnin' : 'muutama sekunti';
 
 
49224
  case 'm':
49225
  return isFuture ? 'minuutin' : 'minuutti';
49226
  case 'mm':
@@ -49284,6 +49363,7 @@ webpackJsonp([1],[
49284
  future : '%s päästä',
49285
  past : '%s sitten',
49286
  s : translate,
 
49287
  m : translate,
49288
  mm : translate,
49289
  h : translate,
@@ -49349,6 +49429,7 @@ webpackJsonp([1],[
49349
  future : 'um %s',
49350
  past : '%s síðani',
49351
  s : 'fá sekund',
 
49352
  m : 'ein minutt',
49353
  mm : '%d minuttir',
49354
  h : 'ein tími',
@@ -49394,7 +49475,7 @@ webpackJsonp([1],[
49394
  monthsParseExact : true,
49395
  weekdays : 'dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi'.split('_'),
49396
  weekdaysShort : 'dim._lun._mar._mer._jeu._ven._sam.'.split('_'),
49397
- weekdaysMin : 'Di_Lu_Ma_Me_Je_Ve_Sa'.split('_'),
49398
  weekdaysParseExact : true,
49399
  longDateFormat : {
49400
  LT : 'HH:mm',
@@ -49416,6 +49497,7 @@ webpackJsonp([1],[
49416
  future : 'dans %s',
49417
  past : 'il y a %s',
49418
  s : 'quelques secondes',
 
49419
  m : 'une minute',
49420
  mm : '%d minutes',
49421
  h : 'une heure',
@@ -49482,7 +49564,7 @@ webpackJsonp([1],[
49482
  monthsParseExact : true,
49483
  weekdays : 'dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi'.split('_'),
49484
  weekdaysShort : 'dim._lun._mar._mer._jeu._ven._sam.'.split('_'),
49485
- weekdaysMin : 'Di_Lu_Ma_Me_Je_Ve_Sa'.split('_'),
49486
  weekdaysParseExact : true,
49487
  longDateFormat : {
49488
  LT : 'HH:mm',
@@ -49504,6 +49586,7 @@ webpackJsonp([1],[
49504
  future : 'dans %s',
49505
  past : 'il y a %s',
49506
  s : 'quelques secondes',
 
49507
  m : 'une minute',
49508
  mm : '%d minutes',
49509
  h : 'une heure',
@@ -49561,7 +49644,7 @@ webpackJsonp([1],[
49561
  monthsParseExact : true,
49562
  weekdays : 'dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi'.split('_'),
49563
  weekdaysShort : 'dim._lun._mar._mer._jeu._ven._sam.'.split('_'),
49564
- weekdaysMin : 'Di_Lu_Ma_Me_Je_Ve_Sa'.split('_'),
49565
  weekdaysParseExact : true,
49566
  longDateFormat : {
49567
  LT : 'HH:mm',
@@ -49583,6 +49666,7 @@ webpackJsonp([1],[
49583
  future : 'dans %s',
49584
  past : 'il y a %s',
49585
  s : 'quelques secondes',
 
49586
  m : 'une minute',
49587
  mm : '%d minutes',
49588
  h : 'une heure',
@@ -49677,6 +49761,7 @@ webpackJsonp([1],[
49677
  future : 'oer %s',
49678
  past : '%s lyn',
49679
  s : 'in pear sekonden',
 
49680
  m : 'ien minút',
49681
  mm : '%d minuten',
49682
  h : 'ien oere',
@@ -49757,6 +49842,7 @@ webpackJsonp([1],[
49757
  future : 'ann an %s',
49758
  past : 'bho chionn %s',
49759
  s : 'beagan diogan',
 
49760
  m : 'mionaid',
49761
  mm : '%d mionaidean',
49762
  h : 'uair',
@@ -49842,6 +49928,7 @@ webpackJsonp([1],[
49842
  },
49843
  past : 'hai %s',
49844
  s : 'uns segundos',
 
49845
  m : 'un minuto',
49846
  mm : '%d minutos',
49847
  h : 'unha hora',
@@ -49884,6 +49971,7 @@ webpackJsonp([1],[
49884
  function processRelativeTime(number, withoutSuffix, key, isFuture) {
49885
  var format = {
49886
  's': ['thodde secondanim', 'thodde second'],
 
49887
  'm': ['eka mintan', 'ek minute'],
49888
  'mm': [number + ' mintanim', number + ' mintam'],
49889
  'h': ['eka horan', 'ek hor'],
@@ -49927,6 +50015,7 @@ webpackJsonp([1],[
49927
  future : '%s',
49928
  past : '%s adim',
49929
  s : processRelativeTime,
 
49930
  m : processRelativeTime,
49931
  mm : processRelativeTime,
49932
  h : processRelativeTime,
@@ -50060,6 +50149,7 @@ webpackJsonp([1],[
50060
  future: '%s મા',
50061
  past: '%s પેહલા',
50062
  s: 'અમુક પળો',
 
50063
  m: 'એક મિનિટ',
50064
  mm: '%d મિનિટ',
50065
  h: 'એક કલાક',
@@ -50169,6 +50259,7 @@ webpackJsonp([1],[
50169
  future : 'בעוד %s',
50170
  past : 'לפני %s',
50171
  s : 'מספר שניות',
 
50172
  m : 'דקה',
50173
  mm : '%d דקות',
50174
  h : 'שעה',
@@ -50293,6 +50384,7 @@ webpackJsonp([1],[
50293
  future : '%s में',
50294
  past : '%s पहले',
50295
  s : 'कुछ ही क्षण',
 
50296
  m : 'एक मिनट',
50297
  mm : '%d मिनट',
50298
  h : 'एक घंटा',
@@ -50373,6 +50465,15 @@ webpackJsonp([1],[
50373
  function translate(number, withoutSuffix, key) {
50374
  var result = number + ' ';
50375
  switch (key) {
 
 
 
 
 
 
 
 
 
50376
  case 'm':
50377
  return withoutSuffix ? 'jedna minuta' : 'jedne minute';
50378
  case 'mm':
@@ -50481,6 +50582,7 @@ webpackJsonp([1],[
50481
  future : 'za %s',
50482
  past : 'prije %s',
50483
  s : 'par sekundi',
 
50484
  m : translate,
50485
  mm : translate,
50486
  h : translate,
@@ -50526,6 +50628,8 @@ webpackJsonp([1],[
50526
  switch (key) {
50527
  case 's':
50528
  return (isFuture || withoutSuffix) ? 'néhány másodperc' : 'néhány másodperce';
 
 
50529
  case 'm':
50530
  return 'egy' + (isFuture || withoutSuffix ? ' perc' : ' perce');
50531
  case 'mm':
@@ -50594,6 +50698,7 @@ webpackJsonp([1],[
50594
  future : '%s múlva',
50595
  past : '%s',
50596
  s : translate,
 
50597
  m : translate,
50598
  mm : translate,
50599
  h : translate,
@@ -50666,6 +50771,7 @@ webpackJsonp([1],[
50666
  future : '%s հետո',
50667
  past : '%s առաջ',
50668
  s : 'մի քանի վայրկյան',
 
50669
  m : 'րոպե',
50670
  mm : '%d րոպե',
50671
  h : 'ժամ',
@@ -50784,6 +50890,7 @@ webpackJsonp([1],[
50784
  future : 'dalam %s',
50785
  past : '%s yang lalu',
50786
  s : 'beberapa detik',
 
50787
  m : 'semenit',
50788
  mm : '%d menit',
50789
  h : 'sejam',
@@ -50834,6 +50941,11 @@ webpackJsonp([1],[
50834
  switch (key) {
50835
  case 's':
50836
  return withoutSuffix || isFuture ? 'nokkrar sekúndur' : 'nokkrum sekúndum';
 
 
 
 
 
50837
  case 'm':
50838
  return withoutSuffix ? 'mínúta' : 'mínútu';
50839
  case 'mm':
@@ -50914,6 +51026,7 @@ webpackJsonp([1],[
50914
  future : 'eftir %s',
50915
  past : 'fyrir %s síðan',
50916
  s : translate,
 
50917
  m : translate,
50918
  mm : translate,
50919
  h : 'klukkustund',
@@ -50966,7 +51079,7 @@ webpackJsonp([1],[
50966
  L : 'DD/MM/YYYY',
50967
  LL : 'D MMMM YYYY',
50968
  LLL : 'D MMMM YYYY HH:mm',
50969
- LLLL : 'dddd, D MMMM YYYY HH:mm'
50970
  },
50971
  calendar : {
50972
  sameDay: '[Oggi alle] LT',
@@ -50989,6 +51102,7 @@ webpackJsonp([1],[
50989
  },
50990
  past : '%s fa',
50991
  s : 'alcuni secondi',
 
50992
  m : 'un minuto',
50993
  mm : '%d minuti',
50994
  h : 'un\'ora',
@@ -51080,6 +51194,7 @@ webpackJsonp([1],[
51080
  future : '%s後',
51081
  past : '%s前',
51082
  s : '数秒',
 
51083
  m : '1分',
51084
  mm : '%d分',
51085
  h : '1時間',
@@ -51164,6 +51279,7 @@ webpackJsonp([1],[
51164
  future : 'wonten ing %s',
51165
  past : '%s ingkang kepengker',
51166
  s : 'sawetawis detik',
 
51167
  m : 'setunggal menit',
51168
  mm : '%d menit',
51169
  h : 'setunggal jam',
@@ -51245,6 +51361,7 @@ webpackJsonp([1],[
51245
  }
51246
  },
51247
  s : 'რამდენიმე წამი',
 
51248
  m : 'წუთი',
51249
  mm : '%d წუთი',
51250
  h : 'საათი',
@@ -51344,6 +51461,7 @@ webpackJsonp([1],[
51344
  future : '%s ішінде',
51345
  past : '%s бұрын',
51346
  s : 'бірнеше секунд',
 
51347
  m : 'бір минут',
51348
  mm : '%d минут',
51349
  h : 'бір сағат',
@@ -51413,6 +51531,7 @@ webpackJsonp([1],[
51413
  future: '%sទៀត',
51414
  past: '%sមុន',
51415
  s: 'ប៉ុន្មានវិនាទី',
 
51416
  m: 'មួយនាទី',
51417
  mm: '%d នាទី',
51418
  h: 'មួយម៉ោង',
@@ -51502,6 +51621,7 @@ webpackJsonp([1],[
51502
  future : '%s ನಂತರ',
51503
  past : '%s ಹಿಂದೆ',
51504
  s : 'ಕೆಲವು ಕ್ಷಣಗಳು',
 
51505
  m : 'ಒಂದು ನಿಮಿಷ',
51506
  mm : '%d ನಿಮಿಷ',
51507
  h : 'ಒಂದು ಗಂಟೆ',
@@ -51719,6 +51839,7 @@ webpackJsonp([1],[
51719
  future : '%s ичинде',
51720
  past : '%s мурун',
51721
  s : 'бирнече секунд',
 
51722
  m : 'бир мүнөт',
51723
  mm : '%d мүнөт',
51724
  h : 'бир саат',
@@ -51865,6 +51986,7 @@ webpackJsonp([1],[
51865
  future : processFutureTime,
51866
  past : processPastTime,
51867
  s : 'e puer Sekonnen',
 
51868
  m : processRelativeTime,
51869
  mm : '%d Minutten',
51870
  h : processRelativeTime,
@@ -51942,6 +52064,7 @@ webpackJsonp([1],[
51942
  future : 'ອີກ %s',
51943
  past : '%sຜ່ານມາ',
51944
  s : 'ບໍ່ເທົ່າໃດວິນາທີ',
 
51945
  m : '1 ນາທີ',
51946
  mm : '%d ນາທີ',
51947
  h : '1 ຊົ່ວໂມງ',
@@ -51980,6 +52103,7 @@ webpackJsonp([1],[
51980
 
51981
 
51982
  var units = {
 
51983
  'm' : 'minutė_minutės_minutę',
51984
  'mm': 'minutės_minučių_minutes',
51985
  'h' : 'valanda_valandos_valandą',
@@ -52060,6 +52184,7 @@ webpackJsonp([1],[
52060
  future : 'po %s',
52061
  past : 'prieš %s',
52062
  s : translateSeconds,
 
52063
  m : translateSingular,
52064
  mm : translate,
52065
  h : translateSingular,
@@ -52103,6 +52228,7 @@ webpackJsonp([1],[
52103
 
52104
 
52105
  var units = {
 
52106
  'm': 'minūtes_minūtēm_minūte_minūtes'.split('_'),
52107
  'mm': 'minūtes_minūtēm_minūte_minūtes'.split('_'),
52108
  'h': 'stundas_stundām_stunda_stundas'.split('_'),
@@ -52164,6 +52290,7 @@ webpackJsonp([1],[
52164
  future : 'pēc %s',
52165
  past : 'pirms %s',
52166
  s : relativeSeconds,
 
52167
  m : relativeTimeWithSingular,
52168
  mm : relativeTimeWithPlural,
52169
  h : relativeTimeWithSingular,
@@ -52205,6 +52332,7 @@ webpackJsonp([1],[
52205
 
52206
  var translator = {
52207
  words: { //Different grammatical cases
 
52208
  m: ['jedan minut', 'jednog minuta'],
52209
  mm: ['minut', 'minuta', 'minuta'],
52210
  h: ['jedan sat', 'jednog sata'],
@@ -52280,6 +52408,7 @@ webpackJsonp([1],[
52280
  future : 'za %s',
52281
  past : 'prije %s',
52282
  s : 'nekoliko sekundi',
 
52283
  m : translator.translate,
52284
  mm : translator.translate,
52285
  h : translator.translate,
@@ -52349,6 +52478,7 @@ webpackJsonp([1],[
52349
  future: 'i roto i %s',
52350
  past: '%s i mua',
52351
  s: 'te hēkona ruarua',
 
52352
  m: 'he meneti',
52353
  mm: '%d meneti',
52354
  h: 'te haora',
@@ -52426,6 +52556,7 @@ webpackJsonp([1],[
52426
  future : 'после %s',
52427
  past : 'пред %s',
52428
  s : 'неколку секунди',
 
52429
  m : 'минута',
52430
  mm : '%d минути',
52431
  h : 'час',
@@ -52510,6 +52641,7 @@ webpackJsonp([1],[
52510
  future : '%s കഴിഞ്ഞ്',
52511
  past : '%s മുൻപ്',
52512
  s : 'അൽപ നിമിഷങ്ങൾ',
 
52513
  m : 'ഒരു മിനിറ്റ്',
52514
  mm : '%d മിനിറ്റ്',
52515
  h : 'ഒരു മണിക്കൂർ',
@@ -52601,6 +52733,7 @@ webpackJsonp([1],[
52601
  if (withoutSuffix) {
52602
  switch (string) {
52603
  case 's': output = 'काही सेकंद'; break;
 
52604
  case 'm': output = 'एक मिनिट'; break;
52605
  case 'mm': output = '%d मिनिटे'; break;
52606
  case 'h': output = 'एक तास'; break;
@@ -52616,6 +52749,7 @@ webpackJsonp([1],[
52616
  else {
52617
  switch (string) {
52618
  case 's': output = 'काही सेकंदां'; break;
 
52619
  case 'm': output = 'एका मिनिटा'; break;
52620
  case 'mm': output = '%d मिनिटां'; break;
52621
  case 'h': output = 'एका तासा'; break;
@@ -52658,6 +52792,7 @@ webpackJsonp([1],[
52658
  future: '%sमध्ये',
52659
  past: '%sपूर्वी',
52660
  s: relativeTimeMr,
 
52661
  m: relativeTimeMr,
52662
  mm: relativeTimeMr,
52663
  h: relativeTimeMr,
@@ -52783,6 +52918,7 @@ webpackJsonp([1],[
52783
  future : 'dalam %s',
52784
  past : '%s yang lepas',
52785
  s : 'beberapa saat',
 
52786
  m : 'seminit',
52787
  mm : '%d minit',
52788
  h : 'sejam',
@@ -52871,6 +53007,7 @@ webpackJsonp([1],[
52871
  future : 'dalam %s',
52872
  past : '%s yang lepas',
52873
  s : 'beberapa saat',
 
52874
  m : 'seminit',
52875
  mm : '%d minit',
52876
  h : 'sejam',
@@ -52895,6 +53032,72 @@ webpackJsonp([1],[
52895
 
52896
  /***/ },
52897
  /* 379 */
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
52898
  /***/ function(module, exports, __webpack_require__) {
52899
 
52900
  //! moment.js locale configuration
@@ -52962,6 +53165,7 @@ webpackJsonp([1],[
52962
  future: 'လာမည့် %s မှာ',
52963
  past: 'လွန်ခဲ့သော %s က',
52964
  s: 'စက္ကန်.အနည်းငယ်',
 
52965
  m: 'တစ်မိနစ်',
52966
  mm: '%d မိနစ်',
52967
  h: 'တစ်နာရီ',
@@ -52995,7 +53199,7 @@ webpackJsonp([1],[
52995
 
52996
 
52997
  /***/ },
52998
- /* 380 */
52999
  /***/ function(module, exports, __webpack_require__) {
53000
 
53001
  //! moment.js locale configuration
@@ -53038,6 +53242,7 @@ webpackJsonp([1],[
53038
  future : 'om %s',
53039
  past : '%s siden',
53040
  s : 'noen sekunder',
 
53041
  m : 'ett minutt',
53042
  mm : '%d minutter',
53043
  h : 'en time',
@@ -53063,7 +53268,7 @@ webpackJsonp([1],[
53063
 
53064
 
53065
  /***/ },
53066
- /* 381 */
53067
  /***/ function(module, exports, __webpack_require__) {
53068
 
53069
  //! moment.js locale configuration
@@ -53168,6 +53373,7 @@ webpackJsonp([1],[
53168
  future : '%sमा',
53169
  past : '%s अगाडि',
53170
  s : 'केही क्षण',
 
53171
  m : 'एक मिनेट',
53172
  mm : '%d मिनेट',
53173
  h : 'एक घण्टा',
@@ -53191,7 +53397,7 @@ webpackJsonp([1],[
53191
 
53192
 
53193
  /***/ },
53194
- /* 382 */
53195
  /***/ function(module, exports, __webpack_require__) {
53196
 
53197
  //! moment.js locale configuration
@@ -53257,6 +53463,7 @@ webpackJsonp([1],[
53257
  future : 'over %s',
53258
  past : '%s geleden',
53259
  s : 'een paar seconden',
 
53260
  m : 'één minuut',
53261
  mm : '%d minuten',
53262
  h : 'één uur',
@@ -53284,7 +53491,7 @@ webpackJsonp([1],[
53284
 
53285
 
53286
  /***/ },
53287
- /* 383 */
53288
  /***/ function(module, exports, __webpack_require__) {
53289
 
53290
  //! moment.js locale configuration
@@ -53350,6 +53557,7 @@ webpackJsonp([1],[
53350
  future : 'over %s',
53351
  past : '%s geleden',
53352
  s : 'een paar seconden',
 
53353
  m : 'één minuut',
53354
  mm : '%d minuten',
53355
  h : 'één uur',
@@ -53377,7 +53585,7 @@ webpackJsonp([1],[
53377
 
53378
 
53379
  /***/ },
53380
- /* 384 */
53381
  /***/ function(module, exports, __webpack_require__) {
53382
 
53383
  //! moment.js locale configuration
@@ -53417,6 +53625,7 @@ webpackJsonp([1],[
53417
  future : 'om %s',
53418
  past : '%s sidan',
53419
  s : 'nokre sekund',
 
53420
  m : 'eit minutt',
53421
  mm : '%d minutt',
53422
  h : 'ein time',
@@ -53442,7 +53651,7 @@ webpackJsonp([1],[
53442
 
53443
 
53444
  /***/ },
53445
- /* 385 */
53446
  /***/ function(module, exports, __webpack_require__) {
53447
 
53448
  //! moment.js locale configuration
@@ -53508,6 +53717,7 @@ webpackJsonp([1],[
53508
  future : '%s ਵਿੱਚ',
53509
  past : '%s ਪਿਛਲੇ',
53510
  s : 'ਕੁਝ ਸਕਿੰਟ',
 
53511
  m : 'ਇਕ ਮਿੰਟ',
53512
  mm : '%d ਮਿੰਟ',
53513
  h : 'ਇੱਕ ਘੰਟਾ',
@@ -53571,7 +53781,7 @@ webpackJsonp([1],[
53571
 
53572
 
53573
  /***/ },
53574
- /* 386 */
53575
  /***/ function(module, exports, __webpack_require__) {
53576
 
53577
  //! moment.js locale configuration
@@ -53593,6 +53803,8 @@ webpackJsonp([1],[
53593
  function translate(number, withoutSuffix, key) {
53594
  var result = number + ' ';
53595
  switch (key) {
 
 
53596
  case 'm':
53597
  return withoutSuffix ? 'minuta' : 'minutę';
53598
  case 'mm':
@@ -53675,6 +53887,7 @@ webpackJsonp([1],[
53675
  future : 'za %s',
53676
  past : '%s temu',
53677
  s : 'kilka sekund',
 
53678
  m : translate,
53679
  mm : translate,
53680
  h : translate,
@@ -53700,7 +53913,7 @@ webpackJsonp([1],[
53700
 
53701
 
53702
  /***/ },
53703
- /* 387 */
53704
  /***/ function(module, exports, __webpack_require__) {
53705
 
53706
  //! moment.js locale configuration
@@ -53745,6 +53958,7 @@ webpackJsonp([1],[
53745
  future : 'em %s',
53746
  past : 'há %s',
53747
  s : 'segundos',
 
53748
  m : 'um minuto',
53749
  mm : '%d minutos',
53750
  h : 'uma hora',
@@ -53770,7 +53984,7 @@ webpackJsonp([1],[
53770
 
53771
 
53772
  /***/ },
53773
- /* 388 */
53774
  /***/ function(module, exports, __webpack_require__) {
53775
 
53776
  //! moment.js locale configuration
@@ -53837,7 +54051,7 @@ webpackJsonp([1],[
53837
 
53838
 
53839
  /***/ },
53840
- /* 389 */
53841
  /***/ function(module, exports, __webpack_require__) {
53842
 
53843
  //! moment.js locale configuration
@@ -53854,6 +54068,7 @@ webpackJsonp([1],[
53854
 
53855
  function relativeTimeWithPlural(number, withoutSuffix, key) {
53856
  var format = {
 
53857
  'mm': 'minute',
53858
  'hh': 'ore',
53859
  'dd': 'zile',
@@ -53894,6 +54109,7 @@ webpackJsonp([1],[
53894
  future : 'peste %s',
53895
  past : '%s în urmă',
53896
  s : 'câteva secunde',
 
53897
  m : 'un minut',
53898
  mm : relativeTimeWithPlural,
53899
  h : 'o oră',
@@ -53917,7 +54133,7 @@ webpackJsonp([1],[
53917
 
53918
 
53919
  /***/ },
53920
- /* 390 */
53921
  /***/ function(module, exports, __webpack_require__) {
53922
 
53923
  //! moment.js locale configuration
@@ -53939,6 +54155,7 @@ webpackJsonp([1],[
53939
  }
53940
  function relativeTimeWithPlural(number, withoutSuffix, key) {
53941
  var format = {
 
53942
  'mm': withoutSuffix ? 'минута_минуты_минут' : 'минуту_минуты_минут',
53943
  'hh': 'час_часа_часов',
53944
  'dd': 'день_дня_дней',
@@ -53990,12 +54207,12 @@ webpackJsonp([1],[
53990
  // Выражение, которое соотвествует только сокращённым формам
53991
  monthsShortStrictRegex: /^(янв\.|февр?\.|мар[т.]|апр\.|ма[яй]|июн[ья.]|июл[ья.]|авг\.|сент?\.|окт\.|нояб?\.|дек\.)/i,
53992
  longDateFormat : {
53993
- LT : 'HH:mm',
53994
- LTS : 'HH:mm:ss',
53995
  L : 'DD.MM.YYYY',
53996
  LL : 'D MMMM YYYY г.',
53997
- LLL : 'D MMMM YYYY г., HH:mm',
53998
- LLLL : 'dddd, D MMMM YYYY г., HH:mm'
53999
  },
54000
  calendar : {
54001
  sameDay: '[Сегодня в] LT',
@@ -54051,6 +54268,7 @@ webpackJsonp([1],[
54051
  future : 'через %s',
54052
  past : '%s назад',
54053
  s : 'несколько секунд',
 
54054
  m : relativeTimeWithPlural,
54055
  mm : relativeTimeWithPlural,
54056
  h : 'час',
@@ -54105,7 +54323,7 @@ webpackJsonp([1],[
54105
 
54106
 
54107
  /***/ },
54108
- /* 391 */
54109
  /***/ function(module, exports, __webpack_require__) {
54110
 
54111
  //! moment.js locale configuration
@@ -54179,6 +54397,7 @@ webpackJsonp([1],[
54179
  future : '%s پوء',
54180
  past : '%s اڳ',
54181
  s : 'چند سيڪنڊ',
 
54182
  m : 'هڪ منٽ',
54183
  mm : '%d منٽ',
54184
  h : 'هڪ ڪلاڪ',
@@ -54208,7 +54427,7 @@ webpackJsonp([1],[
54208
 
54209
 
54210
  /***/ },
54211
- /* 392 */
54212
  /***/ function(module, exports, __webpack_require__) {
54213
 
54214
  //! moment.js locale configuration
@@ -54249,6 +54468,7 @@ webpackJsonp([1],[
54249
  future : '%s geažes',
54250
  past : 'maŋit %s',
54251
  s : 'moadde sekunddat',
 
54252
  m : 'okta minuhta',
54253
  mm : '%d minuhtat',
54254
  h : 'okta diimmu',
@@ -54274,7 +54494,7 @@ webpackJsonp([1],[
54274
 
54275
 
54276
  /***/ },
54277
- /* 393 */
54278
  /***/ function(module, exports, __webpack_require__) {
54279
 
54280
  //! moment.js locale configuration
@@ -54316,6 +54536,7 @@ webpackJsonp([1],[
54316
  future : '%sකින්',
54317
  past : '%sකට පෙර',
54318
  s : 'තත්පර කිහිපය',
 
54319
  m : 'මිනිත්තුව',
54320
  mm : 'මිනිත්තු %d',
54321
  h : 'පැය',
@@ -54350,7 +54571,7 @@ webpackJsonp([1],[
54350
 
54351
 
54352
  /***/ },
54353
- /* 394 */
54354
  /***/ function(module, exports, __webpack_require__) {
54355
 
54356
  //! moment.js locale configuration
@@ -54375,6 +54596,13 @@ webpackJsonp([1],[
54375
  switch (key) {
54376
  case 's': // a few seconds / in a few seconds / a few seconds ago
54377
  return (withoutSuffix || isFuture) ? 'pár sekúnd' : 'pár sekundami';
 
 
 
 
 
 
 
54378
  case 'm': // a minute / in a minute / a minute ago
54379
  return withoutSuffix ? 'minúta' : (isFuture ? 'minútu' : 'minútou');
54380
  case 'mm': // 9 minutes / in 9 minutes / 9 minutes ago
@@ -54480,6 +54708,7 @@ webpackJsonp([1],[
54480
  future : 'za %s',
54481
  past : 'pred %s',
54482
  s : translate,
 
54483
  m : translate,
54484
  mm : translate,
54485
  h : translate,
@@ -54505,7 +54734,7 @@ webpackJsonp([1],[
54505
 
54506
 
54507
  /***/ },
54508
- /* 395 */
54509
  /***/ function(module, exports, __webpack_require__) {
54510
 
54511
  //! moment.js locale configuration
@@ -54524,6 +54753,17 @@ webpackJsonp([1],[
54524
  switch (key) {
54525
  case 's':
54526
  return withoutSuffix || isFuture ? 'nekaj sekund' : 'nekaj sekundami';
 
 
 
 
 
 
 
 
 
 
 
54527
  case 'm':
54528
  return withoutSuffix ? 'ena minuta' : 'eno minuto';
54529
  case 'mm':
@@ -54647,6 +54887,7 @@ webpackJsonp([1],[
54647
  future : 'čez %s',
54648
  past : 'pred %s',
54649
  s : processRelativeTime,
 
54650
  m : processRelativeTime,
54651
  mm : processRelativeTime,
54652
  h : processRelativeTime,
@@ -54672,7 +54913,7 @@ webpackJsonp([1],[
54672
 
54673
 
54674
  /***/ },
54675
- /* 396 */
54676
  /***/ function(module, exports, __webpack_require__) {
54677
 
54678
  //! moment.js locale configuration
@@ -54722,6 +54963,7 @@ webpackJsonp([1],[
54722
  future : 'në %s',
54723
  past : '%s më parë',
54724
  s : 'disa sekonda',
 
54725
  m : 'një minutë',
54726
  mm : '%d minuta',
54727
  h : 'një orë',
@@ -54747,7 +54989,7 @@ webpackJsonp([1],[
54747
 
54748
 
54749
  /***/ },
54750
- /* 397 */
54751
  /***/ function(module, exports, __webpack_require__) {
54752
 
54753
  //! moment.js locale configuration
@@ -54763,6 +55005,7 @@ webpackJsonp([1],[
54763
 
54764
  var translator = {
54765
  words: { //Different grammatical cases
 
54766
  m: ['jedan minut', 'jedne minute'],
54767
  mm: ['minut', 'minute', 'minuta'],
54768
  h: ['jedan sat', 'jednog sata'],
@@ -54837,6 +55080,7 @@ webpackJsonp([1],[
54837
  future : 'za %s',
54838
  past : 'pre %s',
54839
  s : 'nekoliko sekundi',
 
54840
  m : translator.translate,
54841
  mm : translator.translate,
54842
  h : translator.translate,
@@ -54862,7 +55106,7 @@ webpackJsonp([1],[
54862
 
54863
 
54864
  /***/ },
54865
- /* 398 */
54866
  /***/ function(module, exports, __webpack_require__) {
54867
 
54868
  //! moment.js locale configuration
@@ -54878,6 +55122,7 @@ webpackJsonp([1],[
54878
 
54879
  var translator = {
54880
  words: { //Different grammatical cases
 
54881
  m: ['један минут', 'једне минуте'],
54882
  mm: ['минут', 'минуте', 'минута'],
54883
  h: ['један сат', 'једног сата'],
@@ -54952,6 +55197,7 @@ webpackJsonp([1],[
54952
  future : 'за %s',
54953
  past : 'пре %s',
54954
  s : 'неколико секунди',
 
54955
  m : translator.translate,
54956
  mm : translator.translate,
54957
  h : translator.translate,
@@ -54977,7 +55223,7 @@ webpackJsonp([1],[
54977
 
54978
 
54979
  /***/ },
54980
- /* 399 */
54981
  /***/ function(module, exports, __webpack_require__) {
54982
 
54983
  //! moment.js locale configuration
@@ -55019,6 +55265,7 @@ webpackJsonp([1],[
55019
  future : 'nga %s',
55020
  past : 'wenteka nga %s',
55021
  s : 'emizuzwana lomcane',
 
55022
  m : 'umzuzu',
55023
  mm : '%d emizuzu',
55024
  h : 'lihora',
@@ -55071,7 +55318,7 @@ webpackJsonp([1],[
55071
 
55072
 
55073
  /***/ },
55074
- /* 400 */
55075
  /***/ function(module, exports, __webpack_require__) {
55076
 
55077
  //! moment.js locale configuration
@@ -55113,6 +55360,7 @@ webpackJsonp([1],[
55113
  future : 'om %s',
55114
  past : 'för %s sedan',
55115
  s : 'några sekunder',
 
55116
  m : 'en minut',
55117
  mm : '%d minuter',
55118
  h : 'en timme',
@@ -55145,7 +55393,7 @@ webpackJsonp([1],[
55145
 
55146
 
55147
  /***/ },
55148
- /* 401 */
55149
  /***/ function(module, exports, __webpack_require__) {
55150
 
55151
  //! moment.js locale configuration
@@ -55186,6 +55434,7 @@ webpackJsonp([1],[
55186
  future : '%s baadaye',
55187
  past : 'tokea %s',
55188
  s : 'hivi punde',
 
55189
  m : 'dakika moja',
55190
  mm : 'dakika %d',
55191
  h : 'saa limoja',
@@ -55209,7 +55458,7 @@ webpackJsonp([1],[
55209
 
55210
 
55211
  /***/ },
55212
- /* 402 */
55213
  /***/ function(module, exports, __webpack_require__) {
55214
 
55215
  //! moment.js locale configuration
@@ -55274,6 +55523,7 @@ webpackJsonp([1],[
55274
  future : '%s இல்',
55275
  past : '%s முன்',
55276
  s : 'ஒரு சில விநாடிகள்',
 
55277
  m : 'ஒரு நிமிடம்',
55278
  mm : '%d நிமிடங்கள்',
55279
  h : 'ஒரு மணி நேரம்',
@@ -55344,7 +55594,7 @@ webpackJsonp([1],[
55344
 
55345
 
55346
  /***/ },
55347
- /* 403 */
55348
  /***/ function(module, exports, __webpack_require__) {
55349
 
55350
  //! moment.js locale configuration
@@ -55385,6 +55635,7 @@ webpackJsonp([1],[
55385
  future : '%s లో',
55386
  past : '%s క్రితం',
55387
  s : 'కొన్ని క్షణాలు',
 
55388
  m : 'ఒక నిమిషం',
55389
  mm : '%d నిమిషాలు',
55390
  h : 'ఒక గంట',
@@ -55438,7 +55689,7 @@ webpackJsonp([1],[
55438
 
55439
 
55440
  /***/ },
55441
- /* 404 */
55442
  /***/ function(module, exports, __webpack_require__) {
55443
 
55444
  //! moment.js locale configuration
@@ -55479,6 +55730,7 @@ webpackJsonp([1],[
55479
  future : 'iha %s',
55480
  past : '%s liuba',
55481
  s : 'minutu balun',
 
55482
  m : 'minutu ida',
55483
  mm : 'minutus %d',
55484
  h : 'horas ida',
@@ -55511,7 +55763,7 @@ webpackJsonp([1],[
55511
 
55512
 
55513
  /***/ },
55514
- /* 405 */
55515
  /***/ function(module, exports, __webpack_require__) {
55516
 
55517
  //! moment.js locale configuration
@@ -55564,6 +55816,7 @@ webpackJsonp([1],[
55564
  future : 'อีก %s',
55565
  past : '%sที่แล้ว',
55566
  s : 'ไม่กี่วินาที',
 
55567
  m : '1 นาที',
55568
  mm : '%d นาที',
55569
  h : '1 ชั่วโมง',
@@ -55583,7 +55836,7 @@ webpackJsonp([1],[
55583
 
55584
 
55585
  /***/ },
55586
- /* 406 */
55587
  /***/ function(module, exports, __webpack_require__) {
55588
 
55589
  //! moment.js locale configuration
@@ -55623,6 +55876,7 @@ webpackJsonp([1],[
55623
  future : 'sa loob ng %s',
55624
  past : '%s ang nakalipas',
55625
  s : 'ilang segundo',
 
55626
  m : 'isang minuto',
55627
  mm : '%d minuto',
55628
  h : 'isang oras',
@@ -55650,7 +55904,7 @@ webpackJsonp([1],[
55650
 
55651
 
55652
  /***/ },
55653
- /* 407 */
55654
  /***/ function(module, exports, __webpack_require__) {
55655
 
55656
  //! moment.js locale configuration
@@ -55693,6 +55947,8 @@ webpackJsonp([1],[
55693
  function translate(number, withoutSuffix, string, isFuture) {
55694
  var numberNoun = numberAsNoun(number);
55695
  switch (string) {
 
 
55696
  case 'mm':
55697
  return numberNoun + ' tup';
55698
  case 'hh':
@@ -55750,6 +56006,7 @@ webpackJsonp([1],[
55750
  future : translateFuture,
55751
  past : translatePast,
55752
  s : 'puS lup',
 
55753
  m : 'wa’ tup',
55754
  mm : translate,
55755
  h : 'wa’ rep',
@@ -55775,7 +56032,7 @@ webpackJsonp([1],[
55775
 
55776
 
55777
  /***/ },
55778
- /* 408 */
55779
  /***/ function(module, exports, __webpack_require__) {
55780
 
55781
  //! moment.js locale configuration
@@ -55837,6 +56094,7 @@ webpackJsonp([1],[
55837
  future : '%s sonra',
55838
  past : '%s önce',
55839
  s : 'birkaç saniye',
 
55840
  m : 'bir dakika',
55841
  mm : '%d dakika',
55842
  h : 'bir saat',
@@ -55870,7 +56128,7 @@ webpackJsonp([1],[
55870
 
55871
 
55872
  /***/ },
55873
- /* 409 */
55874
  /***/ function(module, exports, __webpack_require__) {
55875
 
55876
  //! moment.js locale configuration
@@ -55924,6 +56182,7 @@ webpackJsonp([1],[
55924
  future : 'osprei %s',
55925
  past : 'ja%s',
55926
  s : processRelativeTime,
 
55927
  m : processRelativeTime,
55928
  mm : processRelativeTime,
55929
  h : processRelativeTime,
@@ -55946,6 +56205,7 @@ webpackJsonp([1],[
55946
  function processRelativeTime(number, withoutSuffix, key, isFuture) {
55947
  var format = {
55948
  's': ['viensas secunds', '\'iensas secunds'],
 
55949
  'm': ['\'n míut', '\'iens míut'],
55950
  'mm': [number + ' míuts', '' + number + ' míuts'],
55951
  'h': ['\'n þora', '\'iensa þora'],
@@ -55966,7 +56226,7 @@ webpackJsonp([1],[
55966
 
55967
 
55968
  /***/ },
55969
- /* 410 */
55970
  /***/ function(module, exports, __webpack_require__) {
55971
 
55972
  //! moment.js locale configuration
@@ -56006,6 +56266,7 @@ webpackJsonp([1],[
56006
  future : 'ⴷⴰⴷⵅ ⵙ ⵢⴰⵏ %s',
56007
  past : 'ⵢⴰⵏ %s',
56008
  s : 'ⵉⵎⵉⴽ',
 
56009
  m : 'ⵎⵉⵏⵓⴺ',
56010
  mm : '%d ⵎⵉⵏⵓⴺ',
56011
  h : 'ⵙⴰⵄⴰ',
@@ -56029,7 +56290,7 @@ webpackJsonp([1],[
56029
 
56030
 
56031
  /***/ },
56032
- /* 411 */
56033
  /***/ function(module, exports, __webpack_require__) {
56034
 
56035
  //! moment.js locale configuration
@@ -56069,6 +56330,7 @@ webpackJsonp([1],[
56069
  future : 'dadkh s yan %s',
56070
  past : 'yan %s',
56071
  s : 'imik',
 
56072
  m : 'minuḍ',
56073
  mm : '%d minuḍ',
56074
  h : 'saɛa',
@@ -56092,7 +56354,7 @@ webpackJsonp([1],[
56092
 
56093
 
56094
  /***/ },
56095
- /* 412 */
56096
  /***/ function(module, exports, __webpack_require__) {
56097
 
56098
  //! moment.js locale configuration
@@ -56113,6 +56375,7 @@ webpackJsonp([1],[
56113
  }
56114
  function relativeTimeWithPlural(number, withoutSuffix, key) {
56115
  var format = {
 
56116
  'mm': withoutSuffix ? 'хвилина_хвилини_хвилин' : 'хвилину_хвилини_хвилин',
56117
  'hh': withoutSuffix ? 'година_години_годин' : 'годину_години_годин',
56118
  'dd': 'день_дні_днів',
@@ -56194,6 +56457,7 @@ webpackJsonp([1],[
56194
  future : 'за %s',
56195
  past : '%s тому',
56196
  s : 'декілька секунд',
 
56197
  m : relativeTimeWithPlural,
56198
  mm : relativeTimeWithPlural,
56199
  h : 'годину',
@@ -56248,7 +56512,7 @@ webpackJsonp([1],[
56248
 
56249
 
56250
  /***/ },
56251
- /* 413 */
56252
  /***/ function(module, exports, __webpack_require__) {
56253
 
56254
  //! moment.js locale configuration
@@ -56323,6 +56587,7 @@ webpackJsonp([1],[
56323
  future : '%s بعد',
56324
  past : '%s قبل',
56325
  s : 'چند سیکنڈ',
 
56326
  m : 'ایک منٹ',
56327
  mm : '%d منٹ',
56328
  h : 'ایک گھنٹہ',
@@ -56352,7 +56617,7 @@ webpackJsonp([1],[
56352
 
56353
 
56354
  /***/ },
56355
- /* 414 */
56356
  /***/ function(module, exports, __webpack_require__) {
56357
 
56358
  //! moment.js locale configuration
@@ -56392,6 +56657,7 @@ webpackJsonp([1],[
56392
  future : 'Якин %s ичида',
56393
  past : 'Бир неча %s олдин',
56394
  s : 'фурсат',
 
56395
  m : 'бир дакика',
56396
  mm : '%d дакика',
56397
  h : 'бир соат',
@@ -56415,7 +56681,7 @@ webpackJsonp([1],[
56415
 
56416
 
56417
  /***/ },
56418
- /* 415 */
56419
  /***/ function(module, exports, __webpack_require__) {
56420
 
56421
  //! moment.js locale configuration
@@ -56455,6 +56721,7 @@ webpackJsonp([1],[
56455
  future : 'Yaqin %s ichida',
56456
  past : 'Bir necha %s oldin',
56457
  s : 'soniya',
 
56458
  m : 'bir daqiqa',
56459
  mm : '%d daqiqa',
56460
  h : 'bir soat',
@@ -56478,7 +56745,7 @@ webpackJsonp([1],[
56478
 
56479
 
56480
  /***/ },
56481
- /* 416 */
56482
  /***/ function(module, exports, __webpack_require__) {
56483
 
56484
  //! moment.js locale configuration
@@ -56535,6 +56802,7 @@ webpackJsonp([1],[
56535
  future : '%s tới',
56536
  past : '%s trước',
56537
  s : 'vài giây',
 
56538
  m : 'một phút',
56539
  mm : '%d phút',
56540
  h : 'một giờ',
@@ -56562,7 +56830,7 @@ webpackJsonp([1],[
56562
 
56563
 
56564
  /***/ },
56565
- /* 417 */
56566
  /***/ function(module, exports, __webpack_require__) {
56567
 
56568
  //! moment.js locale configuration
@@ -56603,6 +56871,7 @@ webpackJsonp([1],[
56603
  future : 'í~ñ %s',
56604
  past : '%s á~gó',
56605
  s : 'á ~féw ~sécó~ñds',
 
56606
  m : 'á ~míñ~úté',
56607
  mm : '%d m~íñú~tés',
56608
  h : 'á~ñ hó~úr',
@@ -56635,7 +56904,7 @@ webpackJsonp([1],[
56635
 
56636
 
56637
  /***/ },
56638
- /* 418 */
56639
  /***/ function(module, exports, __webpack_require__) {
56640
 
56641
  //! moment.js locale configuration
@@ -56675,6 +56944,7 @@ webpackJsonp([1],[
56675
  future : 'ní %s',
56676
  past : '%s kọjá',
56677
  s : 'ìsẹjú aayá die',
 
56678
  m : 'ìsẹjú kan',
56679
  mm : 'ìsẹjú %d',
56680
  h : 'wákati kan',
@@ -56700,7 +56970,7 @@ webpackJsonp([1],[
56700
 
56701
 
56702
  /***/ },
56703
- /* 419 */
56704
  /***/ function(module, exports, __webpack_require__) {
56705
 
56706
  //! moment.js locale configuration
@@ -56724,14 +56994,14 @@ webpackJsonp([1],[
56724
  longDateFormat : {
56725
  LT : 'HH:mm',
56726
  LTS : 'HH:mm:ss',
56727
- L : 'YYYY年MMMD日',
56728
- LL : 'YYYY年MMMD日',
56729
- LLL : 'YYYY年MMMD日Ah点mm分',
56730
- LLLL : 'YYYY年MMMD日ddddAh点mm分',
56731
- l : 'YYYY年MMMD日',
56732
- ll : 'YYYY年MMMD日',
56733
- lll : 'YYYY年MMMD日 HH:mm',
56734
- llll : 'YYYY年MMMD日dddd HH:mm'
56735
  },
56736
  meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
56737
  meridiemHour: function (hour, meridiem) {
@@ -56792,6 +57062,7 @@ webpackJsonp([1],[
56792
  future : '%s内',
56793
  past : '%s前',
56794
  s : '几秒',
 
56795
  m : '1 分钟',
56796
  mm : '%d 分钟',
56797
  h : '1 小时',
@@ -56816,7 +57087,7 @@ webpackJsonp([1],[
56816
 
56817
 
56818
  /***/ },
56819
- /* 420 */
56820
  /***/ function(module, exports, __webpack_require__) {
56821
 
56822
  //! moment.js locale configuration
@@ -56841,14 +57112,14 @@ webpackJsonp([1],[
56841
  longDateFormat : {
56842
  LT : 'HH:mm',
56843
  LTS : 'HH:mm:ss',
56844
- L : 'YYYY年MMMD日',
56845
- LL : 'YYYY年MMMD日',
56846
- LLL : 'YYYY年MMMD日 HH:mm',
56847
- LLLL : 'YYYY年MMMD日dddd HH:mm',
56848
- l : 'YYYY年MMMD日',
56849
- ll : 'YYYY年MMMD日',
56850
- lll : 'YYYY年MMMD日 HH:mm',
56851
- llll : 'YYYY年MMMD日dddd HH:mm'
56852
  },
56853
  meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
56854
  meridiemHour : function (hour, meridiem) {
@@ -56907,6 +57178,7 @@ webpackJsonp([1],[
56907
  future : '%s內',
56908
  past : '%s前',
56909
  s : '幾秒',
 
56910
  m : '1 分鐘',
56911
  mm : '%d 分鐘',
56912
  h : '1 小時',
@@ -56926,7 +57198,7 @@ webpackJsonp([1],[
56926
 
56927
 
56928
  /***/ },
56929
- /* 421 */
56930
  /***/ function(module, exports, __webpack_require__) {
56931
 
56932
  //! moment.js locale configuration
@@ -56950,14 +57222,14 @@ webpackJsonp([1],[
56950
  longDateFormat : {
56951
  LT : 'HH:mm',
56952
  LTS : 'HH:mm:ss',
56953
- L : 'YYYY年MMMD日',
56954
- LL : 'YYYY年MMMD日',
56955
- LLL : 'YYYY年MMMD日 HH:mm',
56956
- LLLL : 'YYYY年MMMD日dddd HH:mm',
56957
- l : 'YYYY年MMMD日',
56958
- ll : 'YYYY年MMMD日',
56959
- lll : 'YYYY年MMMD日 HH:mm',
56960
- llll : 'YYYY年MMMD日dddd HH:mm'
56961
  },
56962
  meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
56963
  meridiemHour : function (hour, meridiem) {
@@ -57016,6 +57288,7 @@ webpackJsonp([1],[
57016
  future : '%s內',
57017
  past : '%s前',
57018
  s : '幾秒',
 
57019
  m : '1 分鐘',
57020
  mm : '%d 分鐘',
57021
  h : '1 小時',
@@ -57035,22 +57308,22 @@ webpackJsonp([1],[
57035
 
57036
 
57037
  /***/ },
57038
- /* 422 */
57039
  /***/ function(module, exports, __webpack_require__) {
57040
 
57041
  /* WEBPACK VAR INJECTION */(function(global) {if(!global["MailPoetLib"]) global["MailPoetLib"] = {};
57042
- module.exports = global["MailPoetLib"]["ReactStringReplace"] = __webpack_require__(423);
57043
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
57044
 
57045
  /***/ },
57046
- /* 423 */
57047
  /***/ function(module, exports, __webpack_require__) {
57048
 
57049
  /* eslint-disable vars-on-top, no-var, prefer-template */
57050
- var isRegExp = __webpack_require__(424);
57051
- var escapeRegExp = __webpack_require__(425);
57052
- var isString = __webpack_require__(426);
57053
- var flatten = __webpack_require__(427);
57054
 
57055
  /**
57056
  * Given a string, replace every substring that is matched by the `match` regex
@@ -57108,7 +57381,7 @@ webpackJsonp([1],[
57108
 
57109
 
57110
  /***/ },
57111
- /* 424 */
57112
  /***/ function(module, exports, __webpack_require__) {
57113
 
57114
  /* WEBPACK VAR INJECTION */(function(global, module) {/**
@@ -57236,7 +57509,7 @@ webpackJsonp([1],[
57236
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }()), __webpack_require__(302)(module)))
57237
 
57238
  /***/ },
57239
- /* 425 */
57240
  /***/ function(module, exports) {
57241
 
57242
  /* WEBPACK VAR INJECTION */(function(global) {/**
@@ -57409,7 +57682,7 @@ webpackJsonp([1],[
57409
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
57410
 
57411
  /***/ },
57412
- /* 426 */
57413
  /***/ function(module, exports) {
57414
 
57415
  /**
@@ -57510,7 +57783,7 @@ webpackJsonp([1],[
57510
 
57511
 
57512
  /***/ },
57513
- /* 427 */
57514
  /***/ function(module, exports) {
57515
 
57516
  /* WEBPACK VAR INJECTION */(function(global) {/**
@@ -57866,21 +58139,21 @@ webpackJsonp([1],[
57866
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
57867
 
57868
  /***/ },
57869
- /* 428 */,
57870
  /* 429 */,
57871
  /* 430 */,
57872
  /* 431 */,
57873
- /* 432 */
 
57874
  /***/ function(module, exports, __webpack_require__) {
57875
 
57876
  /* WEBPACK VAR INJECTION */(function(global) {"use strict";
57877
 
57878
  if (!global["MailPoetLib"]) global["MailPoetLib"] = {};
57879
- module.exports = global["MailPoetLib"]["NewsletterCreationBreadcrumb"] = __webpack_require__(433);
57880
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
57881
 
57882
  /***/ },
57883
- /* 433 */
57884
  /***/ function(module, exports, __webpack_require__) {
57885
 
57886
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
@@ -57950,10 +58223,10 @@ webpackJsonp([1],[
57950
  }.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
57951
 
57952
  /***/ },
57953
- /* 434 */,
57954
  /* 435 */,
57955
  /* 436 */,
57956
- /* 437 */
 
57957
  /***/ function(module, exports, __webpack_require__) {
57958
 
57959
  'use strict';
@@ -57989,45 +58262,45 @@ webpackJsonp([1],[
57989
 
57990
  var _classnames2 = _interopRequireDefault(_classnames);
57991
 
57992
- var _staticMethods = __webpack_require__(438);
57993
 
57994
  var _staticMethods2 = _interopRequireDefault(_staticMethods);
57995
 
57996
- var _windowListener = __webpack_require__(440);
57997
 
57998
  var _windowListener2 = _interopRequireDefault(_windowListener);
57999
 
58000
- var _customEvent = __webpack_require__(441);
58001
 
58002
  var _customEvent2 = _interopRequireDefault(_customEvent);
58003
 
58004
- var _isCapture = __webpack_require__(442);
58005
 
58006
  var _isCapture2 = _interopRequireDefault(_isCapture);
58007
 
58008
- var _getEffect = __webpack_require__(443);
58009
 
58010
  var _getEffect2 = _interopRequireDefault(_getEffect);
58011
 
58012
- var _trackRemoval = __webpack_require__(444);
58013
 
58014
  var _trackRemoval2 = _interopRequireDefault(_trackRemoval);
58015
 
58016
- var _getPosition = __webpack_require__(445);
58017
 
58018
  var _getPosition2 = _interopRequireDefault(_getPosition);
58019
 
58020
- var _getTipContent = __webpack_require__(446);
58021
 
58022
  var _getTipContent2 = _interopRequireDefault(_getTipContent);
58023
 
58024
- var _aria = __webpack_require__(447);
58025
 
58026
- var _nodeListToArray = __webpack_require__(448);
58027
 
58028
  var _nodeListToArray2 = _interopRequireDefault(_nodeListToArray);
58029
 
58030
- var _style = __webpack_require__(449);
58031
 
58032
  var _style2 = _interopRequireDefault(_style);
58033
 
@@ -58552,7 +58825,7 @@ webpackJsonp([1],[
58552
  module.exports = ReactTooltip;
58553
 
58554
  /***/ },
58555
- /* 438 */
58556
  /***/ function(module, exports, __webpack_require__) {
58557
 
58558
  'use strict';
@@ -58610,7 +58883,7 @@ webpackJsonp([1],[
58610
  };
58611
  };
58612
 
58613
- var _constant = __webpack_require__(439);
58614
 
58615
  var _constant2 = _interopRequireDefault(_constant);
58616
 
@@ -58635,7 +58908,7 @@ webpackJsonp([1],[
58635
  */
58636
 
58637
  /***/ },
58638
- /* 439 */
58639
  /***/ function(module, exports) {
58640
 
58641
  'use strict';
@@ -58653,7 +58926,7 @@ webpackJsonp([1],[
58653
  };
58654
 
58655
  /***/ },
58656
- /* 440 */
58657
  /***/ function(module, exports, __webpack_require__) {
58658
 
58659
  'use strict';
@@ -58699,14 +58972,14 @@ webpackJsonp([1],[
58699
  };
58700
  };
58701
 
58702
- var _constant = __webpack_require__(439);
58703
 
58704
  var _constant2 = _interopRequireDefault(_constant);
58705
 
58706
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
58707
 
58708
  /***/ },
58709
- /* 441 */
58710
  /***/ function(module, exports) {
58711
 
58712
  'use strict';
@@ -58799,7 +59072,7 @@ webpackJsonp([1],[
58799
  var customListener = void 0;
58800
 
58801
  /***/ },
58802
- /* 442 */
58803
  /***/ function(module, exports) {
58804
 
58805
  'use strict';
@@ -58816,7 +59089,7 @@ webpackJsonp([1],[
58816
  };
58817
 
58818
  /***/ },
58819
- /* 443 */
58820
  /***/ function(module, exports) {
58821
 
58822
  'use strict';
@@ -58833,7 +59106,7 @@ webpackJsonp([1],[
58833
  };
58834
 
58835
  /***/ },
58836
- /* 444 */
58837
  /***/ function(module, exports) {
58838
 
58839
  "use strict";
@@ -58929,7 +59202,7 @@ webpackJsonp([1],[
58929
  };
58930
 
58931
  /***/ },
58932
- /* 445 */
58933
  /***/ function(module, exports) {
58934
 
58935
  'use strict';
@@ -59243,7 +59516,7 @@ webpackJsonp([1],[
59243
  };
59244
 
59245
  /***/ },
59246
- /* 446 */
59247
  /***/ function(module, exports, __webpack_require__) {
59248
 
59249
  'use strict';
@@ -59280,7 +59553,7 @@ webpackJsonp([1],[
59280
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
59281
 
59282
  /***/ },
59283
- /* 447 */
59284
  /***/ function(module, exports) {
59285
 
59286
  "use strict";
@@ -59309,7 +59582,7 @@ webpackJsonp([1],[
59309
  }
59310
 
59311
  /***/ },
59312
- /* 448 */
59313
  /***/ function(module, exports) {
59314
 
59315
  "use strict";
@@ -59329,7 +59602,7 @@ webpackJsonp([1],[
59329
  };
59330
 
59331
  /***/ },
59332
- /* 449 */
59333
  /***/ function(module, exports) {
59334
 
59335
  'use strict';
@@ -59340,7 +59613,6 @@ webpackJsonp([1],[
59340
  exports.default = '.__react_component_tooltip{border-radius:3px;display:inline-block;font-size:13px;left:-999em;opacity:0;padding:8px 21px;position:fixed;pointer-events:none;transition:opacity 0.3s ease-out;top:-999em;visibility:hidden;z-index:999}.__react_component_tooltip:before,.__react_component_tooltip:after{content:"";width:0;height:0;position:absolute}.__react_component_tooltip.show{opacity:0.9;margin-top:0px;margin-left:0px;visibility:visible}.__react_component_tooltip.type-dark{color:#fff;background-color:#222}.__react_component_tooltip.type-dark.place-top:after{border-top-color:#222;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-dark.place-bottom:after{border-bottom-color:#222;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-dark.place-left:after{border-left-color:#222;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-dark.place-right:after{border-right-color:#222;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-dark.border{border:1px solid #fff}.__react_component_tooltip.type-dark.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-dark.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-dark.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-dark.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-success{color:#fff;background-color:#8DC572}.__react_component_tooltip.type-success.place-top:after{border-top-color:#8DC572;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-success.place-bottom:after{border-bottom-color:#8DC572;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-success.place-left:after{border-left-color:#8DC572;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-success.place-right:after{border-right-color:#8DC572;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-success.border{border:1px solid #fff}.__react_component_tooltip.type-success.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-success.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-success.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-success.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-warning{color:#fff;background-color:#F0AD4E}.__react_component_tooltip.type-warning.place-top:after{border-top-color:#F0AD4E;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-warning.place-bottom:after{border-bottom-color:#F0AD4E;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-warning.place-left:after{border-left-color:#F0AD4E;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-warning.place-right:after{border-right-color:#F0AD4E;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-warning.border{border:1px solid #fff}.__react_component_tooltip.type-warning.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-warning.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-warning.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-warning.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-error{color:#fff;background-color:#BE6464}.__react_component_tooltip.type-error.place-top:after{border-top-color:#BE6464;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-error.place-bottom:after{border-bottom-color:#BE6464;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-error.place-left:after{border-left-color:#BE6464;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-error.place-right:after{border-right-color:#BE6464;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-error.border{border:1px solid #fff}.__react_component_tooltip.type-error.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-error.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-error.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-error.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-info{color:#fff;background-color:#337AB7}.__react_component_tooltip.type-info.place-top:after{border-top-color:#337AB7;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-info.place-bottom:after{border-bottom-color:#337AB7;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-info.place-left:after{border-left-color:#337AB7;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-info.place-right:after{border-right-color:#337AB7;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-info.border{border:1px solid #fff}.__react_component_tooltip.type-info.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-info.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-info.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-info.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-light{color:#222;background-color:#fff}.__react_component_tooltip.type-light.place-top:after{border-top-color:#fff;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-light.place-bottom:after{border-bottom-color:#fff;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-light.place-left:after{border-left-color:#fff;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-light.place-right:after{border-right-color:#fff;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-light.border{border:1px solid #222}.__react_component_tooltip.type-light.border.place-top:before{border-top:8px solid #222}.__react_component_tooltip.type-light.border.place-bottom:before{border-bottom:8px solid #222}.__react_component_tooltip.type-light.border.place-left:before{border-left:8px solid #222}.__react_component_tooltip.type-light.border.place-right:before{border-right:8px solid #222}.__react_component_tooltip.place-top{margin-top:-10px}.__react_component_tooltip.place-top:before{border-left:10px solid transparent;border-right:10px solid transparent;bottom:-8px;left:50%;margin-left:-10px}.__react_component_tooltip.place-top:after{border-left:8px solid transparent;border-right:8px solid transparent;bottom:-6px;left:50%;margin-left:-8px}.__react_component_tooltip.place-bottom{margin-top:10px}.__react_component_tooltip.place-bottom:before{border-left:10px solid transparent;border-right:10px solid transparent;top:-8px;left:50%;margin-left:-10px}.__react_component_tooltip.place-bottom:after{border-left:8px solid transparent;border-right:8px solid transparent;top:-6px;left:50%;margin-left:-8px}.__react_component_tooltip.place-left{margin-left:-10px}.__react_component_tooltip.place-left:before{border-top:6px solid transparent;border-bottom:6px solid transparent;right:-8px;top:50%;margin-top:-5px}.__react_component_tooltip.place-left:after{border-top:5px solid transparent;border-bottom:5px solid transparent;right:-6px;top:50%;margin-top:-4px}.__react_component_tooltip.place-right{margin-left:10px}.__react_component_tooltip.place-right:before{border-top:6px solid transparent;border-bottom:6px solid transparent;left:-8px;top:50%;margin-top:-5px}.__react_component_tooltip.place-right:after{border-top:5px solid transparent;border-bottom:5px solid transparent;left:-6px;top:50%;margin-top:-4px}.__react_component_tooltip .multi-line{display:block;padding:2px 0px;text-align:center}';
59341
 
59342
  /***/ },
59343
- /* 450 */,
59344
  /* 451 */,
59345
  /* 452 */,
59346
  /* 453 */,
@@ -59411,7 +59683,8 @@ webpackJsonp([1],[
59411
  /* 518 */,
59412
  /* 519 */,
59413
  /* 520 */,
59414
- /* 521 */
 
59415
  /***/ function(module, exports, __webpack_require__) {
59416
 
59417
  'use strict';
@@ -59505,19 +59778,19 @@ webpackJsonp([1],[
59505
  exports.nthWeekDayValues = nthWeekDayValues;
59506
 
59507
  /***/ },
59508
- /* 522 */,
59509
  /* 523 */,
59510
- /* 524 */
 
59511
  /***/ function(module, exports, __webpack_require__) {
59512
 
59513
  /* WEBPACK VAR INJECTION */(function(global) {"use strict";
59514
 
59515
  if (!global["MailPoetLib"]) global["MailPoetLib"] = {};
59516
- module.exports = global["MailPoetLib"]["NewsletterWelcomeNotificationScheduling"] = __webpack_require__(525);
59517
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
59518
 
59519
  /***/ },
59520
- /* 525 */
59521
  /***/ function(module, exports, __webpack_require__) {
59522
 
59523
  'use strict';
@@ -59544,7 +59817,7 @@ webpackJsonp([1],[
59544
 
59545
  var _formFieldsTextJsx2 = _interopRequireDefault(_formFieldsTextJsx);
59546
 
59547
- var _newslettersSchedulingCommonJsx = __webpack_require__(521);
59548
 
59549
  var availableRoles = window.mailpoet_roles || {};
59550
  var availableSegments = _underscore2['default'].filter(window.mailpoet_segments || [], function (segment) {
@@ -59690,22 +59963,24 @@ webpackJsonp([1],[
59690
  module.exports = WelcomeScheduling;
59691
 
59692
  /***/ },
59693
- /* 526 */,
59694
  /* 527 */,
59695
  /* 528 */,
59696
  /* 529 */,
59697
  /* 530 */,
59698
- /* 531 */
 
 
 
59699
  /***/ function(module, exports, __webpack_require__) {
59700
 
59701
  /* WEBPACK VAR INJECTION */(function(global) {"use strict";
59702
 
59703
  if (!global["MailPoetLib"]) global["MailPoetLib"] = {};
59704
- module.exports = global["MailPoetLib"]["StatsBadge"] = __webpack_require__(532);
59705
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
59706
 
59707
  /***/ },
59708
- /* 532 */
59709
  /***/ function(module, exports, __webpack_require__) {
59710
 
59711
  'use strict';
@@ -59732,7 +60007,7 @@ webpackJsonp([1],[
59732
 
59733
  var _react2 = _interopRequireDefault(_react);
59734
 
59735
- var _badgeJsx = __webpack_require__(533);
59736
 
59737
  var _badgeJsx2 = _interopRequireDefault(_badgeJsx);
59738
 
@@ -59844,7 +60119,7 @@ webpackJsonp([1],[
59844
  module.exports = exports['default'];
59845
 
59846
  /***/ },
59847
- /* 533 */
59848
  /***/ function(module, exports, __webpack_require__) {
59849
 
59850
  'use strict';
@@ -59871,7 +60146,7 @@ webpackJsonp([1],[
59871
 
59872
  var _classnames2 = _interopRequireDefault(_classnames);
59873
 
59874
- var _reactTooltip = __webpack_require__(437);
59875
 
59876
  var _reactTooltip2 = _interopRequireDefault(_reactTooltip);
59877
 
5
  __webpack_require__(2);
6
  __webpack_require__(34);
7
  __webpack_require__(181);
8
+ __webpack_require__(423);
9
  __webpack_require__(278);
10
  __webpack_require__(292);
11
+ __webpack_require__(534);
12
+ __webpack_require__(433);
13
+ __webpack_require__(525);
14
  module.exports = __webpack_require__(244);
15
 
16
 
40835
  /***/ function(module, exports, __webpack_require__) {
40836
 
40837
  var require;/* WEBPACK VAR INJECTION */(function(module) {//! moment.js
40838
+ //! version : 2.20.1
40839
  //! authors : Tim Wood, Iskren Chernev, Moment.js contributors
40840
  //! license : MIT
40841
  //! momentjs.com
41495
 
41496
  // any word (or two) characters or numbers including two/three word month in arabic.
41497
  // includes scottish gaelic two word and hyphenated months
41498
+ var matchWord = /[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i;
41499
 
41500
 
41501
  var regexes = {};
42865
  // note: all values past the year are optional and will default to the lowest possible value.
42866
  // [year, month, day , hour, minute, second, millisecond]
42867
  function configFromArray (config) {
42868
+ var i, date, input = [], currentDate, expectedWeekday, yearToUse;
42869
 
42870
  if (config._d) {
42871
  return;
42915
  }
42916
 
42917
  config._d = (config._useUTC ? createUTCDate : createDate).apply(null, input);
42918
+ expectedWeekday = config._useUTC ? config._d.getUTCDay() : config._d.getDay();
42919
+
42920
  // Apply timezone offset from input. The actual utcOffset can be changed
42921
  // with parseZone.
42922
  if (config._tzm != null) {
42928
  }
42929
 
42930
  // check for mismatching day of week
42931
+ if (config._w && typeof config._w.d !== 'undefined' && config._w.d !== expectedWeekday) {
42932
  getParsingFlags(config).weekdayMismatch = true;
42933
  }
42934
  }
44136
  return this.clone().locale('en').format('ddd MMM DD YYYY HH:mm:ss [GMT]ZZ');
44137
  }
44138
 
44139
+ function toISOString(keepOffset) {
44140
  if (!this.isValid()) {
44141
  return null;
44142
  }
44143
+ var utc = keepOffset !== true;
44144
+ var m = utc ? this.clone().utc() : this;
44145
  if (m.year() < 0 || m.year() > 9999) {
44146
+ return formatMoment(m, utc ? 'YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]' : 'YYYYYY-MM-DD[T]HH:mm:ss.SSSZ');
44147
  }
44148
  if (isFunction(Date.prototype.toISOString)) {
44149
  // native implementation is ~50x faster, use it when we can
44150
+ if (utc) {
44151
+ return this.toDate().toISOString();
44152
+ } else {
44153
+ return new Date(this._d.valueOf()).toISOString().replace('Z', formatMoment(m, 'Z'));
44154
+ }
44155
  }
44156
+ return formatMoment(m, utc ? 'YYYY-MM-DD[T]HH:mm:ss.SSS[Z]' : 'YYYY-MM-DD[T]HH:mm:ss.SSSZ');
44157
  }
44158
 
44159
  /**
44509
 
44510
  addParseToken(['D', 'DD'], DATE);
44511
  addParseToken('Do', function (input, array) {
44512
+ array[DATE] = toInt(input.match(match1to2)[0]);
44513
  });
44514
 
44515
  // MOMENTS
45321
  // Side effect imports
45322
 
45323
 
45324
+ hooks.version = '2.20.1';
45325
 
45326
  setHookCallback(createLocal);
45327
 
45353
  hooks.calendarFormat = getCalendarFormat;
45354
  hooks.prototype = proto;
45355
 
45356
+ // currently HTML5 input type only supports 24-hour formats
45357
+ hooks.HTML5_FMT = {
45358
+ DATETIME_LOCAL: 'YYYY-MM-DDTHH:mm', // <input type="datetime-local" />
45359
+ DATETIME_LOCAL_SECONDS: 'YYYY-MM-DDTHH:mm:ss', // <input type="datetime-local" step="1" />
45360
+ DATETIME_LOCAL_MS: 'YYYY-MM-DDTHH:mm:ss.SSS', // <input type="datetime-local" step="0.001" />
45361
+ DATE: 'YYYY-MM-DD', // <input type="date" />
45362
+ TIME: 'HH:mm', // <input type="time" />
45363
+ TIME_SECONDS: 'HH:mm:ss', // <input type="time" step="1" />
45364
+ TIME_MS: 'HH:mm:ss.SSS', // <input type="time" step="0.001" />
45365
+ WEEK: 'YYYY-[W]WW', // <input type="week" />
45366
+ MONTH: 'YYYY-MM' // <input type="month" />
45367
+ };
45368
+
45369
  return hooks;
45370
 
45371
  })));
45543
  "./ms-my": 378,
45544
  "./ms-my.js": 378,
45545
  "./ms.js": 377,
45546
+ "./mt": 379,
45547
+ "./mt.js": 379,
45548
+ "./my": 380,
45549
+ "./my.js": 380,
45550
+ "./nb": 381,
45551
+ "./nb.js": 381,
45552
+ "./ne": 382,
45553
+ "./ne.js": 382,
45554
+ "./nl": 383,
45555
+ "./nl-be": 384,
45556
+ "./nl-be.js": 384,
45557
+ "./nl.js": 383,
45558
+ "./nn": 385,
45559
+ "./nn.js": 385,
45560
+ "./pa-in": 386,
45561
+ "./pa-in.js": 386,
45562
+ "./pl": 387,
45563
+ "./pl.js": 387,
45564
+ "./pt": 388,
45565
+ "./pt-br": 389,
45566
+ "./pt-br.js": 389,
45567
+ "./pt.js": 388,
45568
+ "./ro": 390,
45569
+ "./ro.js": 390,
45570
+ "./ru": 391,
45571
+ "./ru.js": 391,
45572
+ "./sd": 392,
45573
+ "./sd.js": 392,
45574
+ "./se": 393,
45575
+ "./se.js": 393,
45576
+ "./si": 394,
45577
+ "./si.js": 394,
45578
+ "./sk": 395,
45579
+ "./sk.js": 395,
45580
+ "./sl": 396,
45581
+ "./sl.js": 396,
45582
+ "./sq": 397,
45583
+ "./sq.js": 397,
45584
+ "./sr": 398,
45585
+ "./sr-cyrl": 399,
45586
+ "./sr-cyrl.js": 399,
45587
+ "./sr.js": 398,
45588
+ "./ss": 400,
45589
+ "./ss.js": 400,
45590
+ "./sv": 401,
45591
+ "./sv.js": 401,
45592
+ "./sw": 402,
45593
+ "./sw.js": 402,
45594
+ "./ta": 403,
45595
+ "./ta.js": 403,
45596
+ "./te": 404,
45597
+ "./te.js": 404,
45598
+ "./tet": 405,
45599
+ "./tet.js": 405,
45600
+ "./th": 406,
45601
+ "./th.js": 406,
45602
+ "./tl-ph": 407,
45603
+ "./tl-ph.js": 407,
45604
+ "./tlh": 408,
45605
+ "./tlh.js": 408,
45606
+ "./tr": 409,
45607
+ "./tr.js": 409,
45608
+ "./tzl": 410,
45609
+ "./tzl.js": 410,
45610
+ "./tzm": 411,
45611
+ "./tzm-latn": 412,
45612
+ "./tzm-latn.js": 412,
45613
+ "./tzm.js": 411,
45614
+ "./uk": 413,
45615
+ "./uk.js": 413,
45616
+ "./ur": 414,
45617
+ "./ur.js": 414,
45618
+ "./uz": 415,
45619
+ "./uz-latn": 416,
45620
+ "./uz-latn.js": 416,
45621
+ "./uz.js": 415,
45622
+ "./vi": 417,
45623
+ "./vi.js": 417,
45624
+ "./x-pseudo": 418,
45625
+ "./x-pseudo.js": 418,
45626
+ "./yo": 419,
45627
+ "./yo.js": 419,
45628
+ "./zh-cn": 420,
45629
+ "./zh-cn.js": 420,
45630
+ "./zh-hk": 421,
45631
+ "./zh-hk.js": 421,
45632
+ "./zh-tw": 422,
45633
+ "./zh-tw.js": 422
45634
  };
45635
  function webpackContext(req) {
45636
  return __webpack_require__(webpackContextResolve(req));
45698
  future : 'oor %s',
45699
  past : '%s gelede',
45700
  s : '\'n paar sekondes',
45701
+ ss : '%d sekondes',
45702
  m : '\'n minuut',
45703
  mm : '%d minute',
45704
  h : '\'n uur',
45788
  };
45789
  };
45790
  var months = [
45791
+ 'يناير',
45792
+ 'فبراير',
45793
+ 'مارس',
45794
+ 'أبريل',
45795
+ 'مايو',
45796
+ 'يونيو',
45797
+ 'يوليو',
45798
+ 'أغسطس',
45799
+ 'سبتمبر',
45800
+ 'أكتوبر',
45801
+ 'نوفمبر',
45802
+ 'ديسمبر'
45803
  ];
45804
 
45805
  var ar = moment.defineLocale('ar', {
45840
  future : 'بعد %s',
45841
  past : 'منذ %s',
45842
  s : pluralize('s'),
45843
+ ss : pluralize('s'),
45844
  m : pluralize('m'),
45845
  mm : pluralize('m'),
45846
  h : pluralize('h'),
45915
  future : 'في %s',
45916
  past : 'منذ %s',
45917
  s : 'ثوان',
45918
+ ss : '%d ثانية',
45919
  m : 'دقيقة',
45920
  mm : '%d دقائق',
45921
  h : 'ساعة',
45980
  future : 'في %s',
45981
  past : 'منذ %s',
45982
  s : 'ثوان',
45983
+ ss : '%d ثانية',
45984
  m : 'دقيقة',
45985
  mm : '%d دقائق',
45986
  h : 'ساعة',
46104
  future : 'بعد %s',
46105
  past : 'منذ %s',
46106
  s : pluralize('s'),
46107
+ ss : pluralize('s'),
46108
  m : pluralize('m'),
46109
  mm : pluralize('m'),
46110
  h : pluralize('h'),
46178
  future : 'في %s',
46179
  past : 'منذ %s',
46180
  s : 'ثوان',
46181
+ ss : '%d ثانية',
46182
  m : 'دقيقة',
46183
  mm : '%d دقائق',
46184
  h : 'ساعة',
46279
  future : 'في %s',
46280
  past : 'منذ %s',
46281
  s : 'ثوان',
46282
+ ss : '%d ثانية',
46283
  m : 'دقيقة',
46284
  mm : '%d دقائق',
46285
  h : 'ساعة',
46354
  future: 'في %s',
46355
  past: 'منذ %s',
46356
  s: 'ثوان',
46357
+ ss : '%d ثانية',
46358
  m: 'دقيقة',
46359
  mm: '%d دقائق',
46360
  h: 'ساعة',
46440
  future : '%s sonra',
46441
  past : '%s əvvəl',
46442
  s : 'birneçə saniyyə',
46443
+ ss : '%d saniyə',
46444
  m : 'bir dəqiqə',
46445
  mm : '%d dəqiqə',
46446
  h : 'bir saat',
46511
  }
46512
  function relativeTimeWithPlural(number, withoutSuffix, key) {
46513
  var format = {
46514
+ 'ss': withoutSuffix ? 'секунда_секунды_секунд' : 'секунду_секунды_секунд',
46515
  'mm': withoutSuffix ? 'хвіліна_хвіліны_хвілін' : 'хвіліну_хвіліны_хвілін',
46516
  'hh': withoutSuffix ? 'гадзіна_гадзіны_гадзін' : 'гадзіну_гадзіны_гадзін',
46517
  'dd': 'дзень_дні_дзён',
46681
  future : 'след %s',
46682
  past : 'преди %s',
46683
  s : 'няколко секунди',
46684
+ ss : '%d секунди',
46685
  m : 'минута',
46686
  mm : '%d минути',
46687
  h : 'час',
46766
  future : '%s kɔnɔ',
46767
  past : 'a bɛ %s bɔ',
46768
  s : 'sanga dama dama',
46769
+ ss : 'sekondi %d',
46770
  m : 'miniti kelen',
46771
  mm : 'miniti %d',
46772
  h : 'lɛrɛ kelen',
46855
  future : '%s পরে',
46856
  past : '%s আগে',
46857
  s : 'কয়েক সেকেন্ড',
46858
+ ss : '%d সেকেন্ড',
46859
  m : 'এক মিনিট',
46860
  mm : '%d মিনিট',
46861
  h : 'এক ঘন্টা',
46980
  future : '%s ལ་',
46981
  past : '%s སྔན་ལ',
46982
  s : 'ལམ་སང',
46983
+ ss : '%d སྐར་ཆ།',
46984
  m : 'སྐར་མ་གཅིག',
46985
  mm : '%d སྐར་མ',
46986
  h : 'ཆུ་ཚོད་གཅིག',
47125
  future : 'a-benn %s',
47126
  past : '%s \'zo',
47127
  s : 'un nebeud segondennoù',
47128
+ ss : '%d eilenn',
47129
  m : 'ur vunutenn',
47130
  mm : relativeTimeWithMutation,
47131
  h : 'un eur',
47172
  function translate(number, withoutSuffix, key) {
47173
  var result = number + ' ';
47174
  switch (key) {
47175
+ case 'ss':
47176
+ if (number === 1) {
47177
+ result += 'sekunda';
47178
+ } else if (number === 2 || number === 3 || number === 4) {
47179
+ result += 'sekunde';
47180
+ } else {
47181
+ result += 'sekundi';
47182
+ }
47183
+ return result;
47184
  case 'm':
47185
  return withoutSuffix ? 'jedna minuta' : 'jedne minute';
47186
  case 'mm':
47286
  future : 'za %s',
47287
  past : 'prije %s',
47288
  s : 'par sekundi',
47289
+ ss : translate,
47290
  m : translate,
47291
  mm : translate,
47292
  h : translate,
47371
  future : 'd\'aquí %s',
47372
  past : 'fa %s',
47373
  s : 'uns segons',
47374
+ ss : '%d segons',
47375
  m : 'un minut',
47376
  mm : '%d minuts',
47377
  h : 'una hora',
47430
  switch (key) {
47431
  case 's': // a few seconds / in a few seconds / a few seconds ago
47432
  return (withoutSuffix || isFuture) ? 'pár sekund' : 'pár sekundami';
47433
+ case 'ss': // 9 seconds / in 9 seconds / 9 seconds ago
47434
+ if (withoutSuffix || isFuture) {
47435
+ return result + (plural(number) ? 'sekundy' : 'sekund');
47436
+ } else {
47437
+ return result + 'sekundami';
47438
+ }
47439
+ break;
47440
  case 'm': // a minute / in a minute / a minute ago
47441
  return withoutSuffix ? 'minuta' : (isFuture ? 'minutu' : 'minutou');
47442
  case 'mm': // 9 minutes / in 9 minutes / 9 minutes ago
47565
  future : 'za %s',
47566
  past : 'před %s',
47567
  s : translate,
47568
+ ss : translate,
47569
  m : translate,
47570
  mm : translate,
47571
  h : translate,
47634
  },
47635
  past : '%s каялла',
47636
  s : 'пӗр-ик ҫеккунт',
47637
+ ss : '%d ҫеккунт',
47638
  m : 'пӗр минут',
47639
  mm : '%d минут',
47640
  h : 'пӗр сехет',
47703
  future: 'mewn %s',
47704
  past: '%s yn ôl',
47705
  s: 'ychydig eiliadau',
47706
+ ss: '%d eiliad',
47707
  m: 'munud',
47708
  mm: '%d munud',
47709
  h: 'awr',
47787
  future : 'om %s',
47788
  past : '%s siden',
47789
  s : 'få sekunder',
47790
+ ss : '%d sekunder',
47791
  m : 'et minut',
47792
  mm : '%d minutter',
47793
  h : 'en time',
47871
  future : 'in %s',
47872
  past : 'vor %s',
47873
  s : 'ein paar Sekunden',
47874
+ ss : '%d Sekunden',
47875
  m : processRelativeTime,
47876
  mm : '%d Minuten',
47877
  h : processRelativeTime,
47956
  future : 'in %s',
47957
  past : 'vor %s',
47958
  s : 'ein paar Sekunden',
47959
+ ss : '%d Sekunden',
47960
  m : processRelativeTime,
47961
  mm : '%d Minuten',
47962
  h : processRelativeTime,
48021
  weekdaysMin : 'So_Mo_Di_Mi_Do_Fr_Sa'.split('_'),
48022
  weekdaysParseExact : true,
48023
  longDateFormat : {
48024
+ LT: 'HH:mm',
48025
+ LTS: 'HH:mm:ss',
48026
  L : 'DD.MM.YYYY',
48027
  LL : 'D. MMMM YYYY',
48028
+ LLL : 'D. MMMM YYYY HH:mm',
48029
+ LLLL : 'dddd, D. MMMM YYYY HH:mm'
48030
  },
48031
  calendar : {
48032
  sameDay: '[heute um] LT [Uhr]',
48040
  future : 'in %s',
48041
  past : 'vor %s',
48042
  s : 'ein paar Sekunden',
48043
+ ss : '%d Sekunden',
48044
  m : processRelativeTime,
48045
  mm : '%d Minuten',
48046
  h : processRelativeTime,
48142
  future : 'ތެރޭގައި %s',
48143
  past : 'ކުރިން %s',
48144
  s : 'ސިކުންތުކޮޅެއް',
48145
+ ss : 'd% ސިކުންތު',
48146
  m : 'މިނިޓެއް',
48147
  mm : 'މިނިޓު %d',
48148
  h : 'ގަޑިއިރެއް',
48252
  future : 'σε %s',
48253
  past : '%s πριν',
48254
  s : 'λίγα δευτερόλεπτα',
48255
+ ss : '%d δευτερόλεπτα',
48256
  m : 'ένα λεπτό',
48257
  mm : '%d λεπτά',
48258
  h : 'μία ώρα',
48318
  future : 'in %s',
48319
  past : '%s ago',
48320
  s : 'a few seconds',
48321
+ ss : '%d seconds',
48322
  m : 'a minute',
48323
  mm : '%d minutes',
48324
  h : 'an hour',
48391
  future : 'in %s',
48392
  past : '%s ago',
48393
  s : 'a few seconds',
48394
+ ss : '%d seconds',
48395
  m : 'a minute',
48396
  mm : '%d minutes',
48397
  h : 'an hour',
48460
  future : 'in %s',
48461
  past : '%s ago',
48462
  s : 'a few seconds',
48463
+ ss : '%d seconds',
48464
  m : 'a minute',
48465
  mm : '%d minutes',
48466
  h : 'an hour',
48533
  future : 'in %s',
48534
  past : '%s ago',
48535
  s : 'a few seconds',
48536
+ ss : '%d seconds',
48537
  m : 'a minute',
48538
  mm : '%d minutes',
48539
  h : 'an hour',
48606
  future : 'in %s',
48607
  past : '%s ago',
48608
  s : 'a few seconds',
48609
+ ss : '%d seconds',
48610
  m : 'a minute',
48611
  mm : '%d minutes',
48612
  h : 'an hour',
48692
  future : 'post %s',
48693
  past : 'antaŭ %s',
48694
  s : 'sekundoj',
48695
+ ss : '%d sekundoj',
48696
  m : 'minuto',
48697
  mm : '%d minutoj',
48698
  h : 'horo',
48790
  future : 'en %s',
48791
  past : 'hace %s',
48792
  s : 'unos segundos',
48793
+ ss : '%d segundos',
48794
  m : 'un minuto',
48795
  mm : '%d minutos',
48796
  h : 'una hora',
48887
  future : 'en %s',
48888
  past : 'hace %s',
48889
  s : 'unos segundos',
48890
+ ss : '%d segundos',
48891
  m : 'un minuto',
48892
  mm : '%d minutos',
48893
  h : 'una hora',
48947
  weekdaysMin : 'do_lu_ma_mi_ju_vi_sá'.split('_'),
48948
  weekdaysParseExact : true,
48949
  longDateFormat : {
48950
+ LT : 'h:mm A',
48951
+ LTS : 'h:mm:ss A',
48952
  L : 'MM/DD/YYYY',
48953
  LL : 'MMMM [de] D [de] YYYY',
48954
+ LLL : 'MMMM [de] D [de] YYYY h:mm A',
48955
+ LLLL : 'dddd, MMMM [de] D [de] YYYY h:mm A'
48956
  },
48957
  calendar : {
48958
  sameDay : function () {
48976
  future : 'en %s',
48977
  past : 'hace %s',
48978
  s : 'unos segundos',
48979
+ ss : '%d segundos',
48980
  m : 'un minuto',
48981
  mm : '%d minutos',
48982
  h : 'una hora',
49020
  function processRelativeTime(number, withoutSuffix, key, isFuture) {
49021
  var format = {
49022
  's' : ['mõne sekundi', 'mõni sekund', 'paar sekundit'],
49023
+ 'ss': [number + 'sekundi', number + 'sekundit'],
49024
  'm' : ['ühe minuti', 'üks minut'],
49025
  'mm': [number + ' minuti', number + ' minutit'],
49026
  'h' : ['ühe tunni', 'tund aega', 'üks tund'],
49063
  future : '%s pärast',
49064
  past : '%s tagasi',
49065
  s : processRelativeTime,
49066
+ ss : processRelativeTime,
49067
  m : processRelativeTime,
49068
  mm : processRelativeTime,
49069
  h : processRelativeTime,
49135
  future : '%s barru',
49136
  past : 'duela %s',
49137
  s : 'segundo batzuk',
49138
+ ss : '%d segundo',
49139
  m : 'minutu bat',
49140
  mm : '%d minutu',
49141
  h : 'ordu bat',
49238
  future : 'در %s',
49239
  past : '%s پیش',
49240
  s : 'چند ثانیه',
49241
+ ss : 'ثانیه d%',
49242
  m : 'یک دقیقه',
49243
  mm : '%d دقیقه',
49244
  h : 'یک ساعت',
49298
  switch (key) {
49299
  case 's':
49300
  return isFuture ? 'muutaman sekunnin' : 'muutama sekunti';
49301
+ case 'ss':
49302
+ return isFuture ? 'sekunnin' : 'sekuntia';
49303
  case 'm':
49304
  return isFuture ? 'minuutin' : 'minuutti';
49305
  case 'mm':
49363
  future : '%s päästä',
49364
  past : '%s sitten',
49365
  s : translate,
49366
+ ss : translate,
49367
  m : translate,
49368
  mm : translate,
49369
  h : translate,
49429
  future : 'um %s',
49430
  past : '%s síðani',
49431
  s : 'fá sekund',
49432
+ ss : '%d sekundir',
49433
  m : 'ein minutt',
49434
  mm : '%d minuttir',
49435
  h : 'ein tími',
49475
  monthsParseExact : true,
49476
  weekdays : 'dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi'.split('_'),
49477
  weekdaysShort : 'dim._lun._mar._mer._jeu._ven._sam.'.split('_'),
49478
+ weekdaysMin : 'di_lu_ma_me_je_ve_sa'.split('_'),
49479
  weekdaysParseExact : true,
49480
  longDateFormat : {
49481
  LT : 'HH:mm',
49497
  future : 'dans %s',
49498
  past : 'il y a %s',
49499
  s : 'quelques secondes',
49500
+ ss : '%d secondes',
49501
  m : 'une minute',
49502
  mm : '%d minutes',
49503
  h : 'une heure',
49564
  monthsParseExact : true,
49565
  weekdays : 'dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi'.split('_'),
49566
  weekdaysShort : 'dim._lun._mar._mer._jeu._ven._sam.'.split('_'),
49567
+ weekdaysMin : 'di_lu_ma_me_je_ve_sa'.split('_'),
49568
  weekdaysParseExact : true,
49569
  longDateFormat : {
49570
  LT : 'HH:mm',
49586
  future : 'dans %s',
49587
  past : 'il y a %s',
49588
  s : 'quelques secondes',
49589
+ ss : '%d secondes',
49590
  m : 'une minute',
49591
  mm : '%d minutes',
49592
  h : 'une heure',
49644
  monthsParseExact : true,
49645
  weekdays : 'dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi'.split('_'),
49646
  weekdaysShort : 'dim._lun._mar._mer._jeu._ven._sam.'.split('_'),
49647
+ weekdaysMin : 'di_lu_ma_me_je_ve_sa'.split('_'),
49648
  weekdaysParseExact : true,
49649
  longDateFormat : {
49650
  LT : 'HH:mm',
49666
  future : 'dans %s',
49667
  past : 'il y a %s',
49668
  s : 'quelques secondes',
49669
+ ss : '%d secondes',
49670
  m : 'une minute',
49671
  mm : '%d minutes',
49672
  h : 'une heure',
49761
  future : 'oer %s',
49762
  past : '%s lyn',
49763
  s : 'in pear sekonden',
49764
+ ss : '%d sekonden',
49765
  m : 'ien minút',
49766
  mm : '%d minuten',
49767
  h : 'ien oere',
49842
  future : 'ann an %s',
49843
  past : 'bho chionn %s',
49844
  s : 'beagan diogan',
49845
+ ss : '%d diogan',
49846
  m : 'mionaid',
49847
  mm : '%d mionaidean',
49848
  h : 'uair',
49928
  },
49929
  past : 'hai %s',
49930
  s : 'uns segundos',
49931
+ ss : '%d segundos',
49932
  m : 'un minuto',
49933
  mm : '%d minutos',
49934
  h : 'unha hora',
49971
  function processRelativeTime(number, withoutSuffix, key, isFuture) {
49972
  var format = {
49973
  's': ['thodde secondanim', 'thodde second'],
49974
+ 'ss': [number + ' secondanim', number + ' second'],
49975
  'm': ['eka mintan', 'ek minute'],
49976
  'mm': [number + ' mintanim', number + ' mintam'],
49977
  'h': ['eka horan', 'ek hor'],
50015
  future : '%s',
50016
  past : '%s adim',
50017
  s : processRelativeTime,
50018
+ ss : processRelativeTime,
50019
  m : processRelativeTime,
50020
  mm : processRelativeTime,
50021
  h : processRelativeTime,
50149
  future: '%s મા',
50150
  past: '%s પેહલા',
50151
  s: 'અમુક પળો',
50152
+ ss: '%d સેકંડ',
50153
  m: 'એક મિનિટ',
50154
  mm: '%d મિનિટ',
50155
  h: 'એક કલાક',
50259
  future : 'בעוד %s',
50260
  past : 'לפני %s',
50261
  s : 'מספר שניות',
50262
+ ss : '%d שניות',
50263
  m : 'דקה',
50264
  mm : '%d דקות',
50265
  h : 'שעה',
50384
  future : '%s में',
50385
  past : '%s पहले',
50386
  s : 'कुछ ही क्षण',
50387
+ ss : '%d सेकंड',
50388
  m : 'एक मिनट',
50389
  mm : '%d मिनट',
50390
  h : 'एक घंटा',
50465
  function translate(number, withoutSuffix, key) {
50466
  var result = number + ' ';
50467
  switch (key) {
50468
+ case 'ss':
50469
+ if (number === 1) {
50470
+ result += 'sekunda';
50471
+ } else if (number === 2 || number === 3 || number === 4) {
50472
+ result += 'sekunde';
50473
+ } else {
50474
+ result += 'sekundi';
50475
+ }
50476
+ return result;
50477
  case 'm':
50478
  return withoutSuffix ? 'jedna minuta' : 'jedne minute';
50479
  case 'mm':
50582
  future : 'za %s',
50583
  past : 'prije %s',
50584
  s : 'par sekundi',
50585
+ ss : translate,
50586
  m : translate,
50587
  mm : translate,
50588
  h : translate,
50628
  switch (key) {
50629
  case 's':
50630
  return (isFuture || withoutSuffix) ? 'néhány másodperc' : 'néhány másodperce';
50631
+ case 'ss':
50632
+ return num + (isFuture || withoutSuffix) ? ' másodperc' : ' másodperce';
50633
  case 'm':
50634
  return 'egy' + (isFuture || withoutSuffix ? ' perc' : ' perce');
50635
  case 'mm':
50698
  future : '%s múlva',
50699
  past : '%s',
50700
  s : translate,
50701
+ ss : translate,
50702
  m : translate,
50703
  mm : translate,
50704
  h : translate,
50771
  future : '%s հետո',
50772
  past : '%s առաջ',
50773
  s : 'մի քանի վայրկյան',
50774
+ ss : '%d վայրկյան',
50775
  m : 'րոպե',
50776
  mm : '%d րոպե',
50777
  h : 'ժամ',
50890
  future : 'dalam %s',
50891
  past : '%s yang lalu',
50892
  s : 'beberapa detik',
50893
+ ss : '%d detik',
50894
  m : 'semenit',
50895
  mm : '%d menit',
50896
  h : 'sejam',
50941
  switch (key) {
50942
  case 's':
50943
  return withoutSuffix || isFuture ? 'nokkrar sekúndur' : 'nokkrum sekúndum';
50944
+ case 'ss':
50945
+ if (plural(number)) {
50946
+ return result + (withoutSuffix || isFuture ? 'sekúndur' : 'sekúndum');
50947
+ }
50948
+ return result + 'sekúnda';
50949
  case 'm':
50950
  return withoutSuffix ? 'mínúta' : 'mínútu';
50951
  case 'mm':
51026
  future : 'eftir %s',
51027
  past : 'fyrir %s síðan',
51028
  s : translate,
51029
+ ss : translate,
51030
  m : translate,
51031
  mm : translate,
51032
  h : 'klukkustund',
51079
  L : 'DD/MM/YYYY',
51080
  LL : 'D MMMM YYYY',
51081
  LLL : 'D MMMM YYYY HH:mm',
51082
+ LLLL : 'dddd D MMMM YYYY HH:mm'
51083
  },
51084
  calendar : {
51085
  sameDay: '[Oggi alle] LT',
51102
  },
51103
  past : '%s fa',
51104
  s : 'alcuni secondi',
51105
+ ss : '%d secondi',
51106
  m : 'un minuto',
51107
  mm : '%d minuti',
51108
  h : 'un\'ora',
51194
  future : '%s後',
51195
  past : '%s前',
51196
  s : '数秒',
51197
+ ss : '%d秒',
51198
  m : '1分',
51199
  mm : '%d分',
51200
  h : '1時間',
51279
  future : 'wonten ing %s',
51280
  past : '%s ingkang kepengker',
51281
  s : 'sawetawis detik',
51282
+ ss : '%d detik',
51283
  m : 'setunggal menit',
51284
  mm : '%d menit',
51285
  h : 'setunggal jam',
51361
  }
51362
  },
51363
  s : 'რამდენიმე წამი',
51364
+ ss : '%d წამი',
51365
  m : 'წუთი',
51366
  mm : '%d წუთი',
51367
  h : 'საათი',
51461
  future : '%s ішінде',
51462
  past : '%s бұрын',
51463
  s : 'бірнеше секунд',
51464
+ ss : '%d секунд',
51465
  m : 'бір минут',
51466
  mm : '%d минут',
51467
  h : 'бір сағат',
51531
  future: '%sទៀត',
51532
  past: '%sមុន',
51533
  s: 'ប៉ុន្មានវិនាទី',
51534
+ ss: '%d វិនាទី',
51535
  m: 'មួយនាទី',
51536
  mm: '%d នាទី',
51537
  h: 'មួយម៉ោង',
51621
  future : '%s ನಂತರ',
51622
  past : '%s ಹಿಂದೆ',
51623
  s : 'ಕೆಲವು ಕ್ಷಣಗಳು',
51624
+ ss : '%d ಸೆಕೆಂಡುಗಳು',
51625
  m : 'ಒಂದು ನಿಮಿಷ',
51626
  mm : '%d ನಿಮಿಷ',
51627
  h : 'ಒಂದು ಗಂಟೆ',
51839
  future : '%s ичинде',
51840
  past : '%s мурун',
51841
  s : 'бирнече секунд',
51842
+ ss : '%d секунд',
51843
  m : 'бир мүнөт',
51844
  mm : '%d мүнөт',
51845
  h : 'бир саат',
51986
  future : processFutureTime,
51987
  past : processPastTime,
51988
  s : 'e puer Sekonnen',
51989
+ ss : '%d Sekonnen',
51990
  m : processRelativeTime,
51991
  mm : '%d Minutten',
51992
  h : processRelativeTime,
52064
  future : 'ອີກ %s',
52065
  past : '%sຜ່ານມາ',
52066
  s : 'ບໍ່ເທົ່າໃດວິນາທີ',
52067
+ ss : '%d ວິນາທີ' ,
52068
  m : '1 ນາທີ',
52069
  mm : '%d ນາທີ',
52070
  h : '1 ຊົ່ວໂມງ',
52103
 
52104
 
52105
  var units = {
52106
+ 'ss' : 'sekundė_sekundžių_sekundes',
52107
  'm' : 'minutė_minutės_minutę',
52108
  'mm': 'minutės_minučių_minutes',
52109
  'h' : 'valanda_valandos_valandą',
52184
  future : 'po %s',
52185
  past : 'prieš %s',
52186
  s : translateSeconds,
52187
+ ss : translate,
52188
  m : translateSingular,
52189
  mm : translate,
52190
  h : translateSingular,
52228
 
52229
 
52230
  var units = {
52231
+ 'ss': 'sekundes_sekundēm_sekunde_sekundes'.split('_'),
52232
  'm': 'minūtes_minūtēm_minūte_minūtes'.split('_'),
52233
  'mm': 'minūtes_minūtēm_minūte_minūtes'.split('_'),
52234
  'h': 'stundas_stundām_stunda_stundas'.split('_'),
52290
  future : 'pēc %s',
52291
  past : 'pirms %s',
52292
  s : relativeSeconds,
52293
+ ss : relativeTimeWithPlural,
52294
  m : relativeTimeWithSingular,
52295
  mm : relativeTimeWithPlural,
52296
  h : relativeTimeWithSingular,
52332
 
52333
  var translator = {
52334
  words: { //Different grammatical cases
52335
+ ss: ['sekund', 'sekunda', 'sekundi'],
52336
  m: ['jedan minut', 'jednog minuta'],
52337
  mm: ['minut', 'minuta', 'minuta'],
52338
  h: ['jedan sat', 'jednog sata'],
52408
  future : 'za %s',
52409
  past : 'prije %s',
52410
  s : 'nekoliko sekundi',
52411
+ ss : translator.translate,
52412
  m : translator.translate,
52413
  mm : translator.translate,
52414
  h : translator.translate,
52478
  future: 'i roto i %s',
52479
  past: '%s i mua',
52480
  s: 'te hēkona ruarua',
52481
+ ss: '%d hēkona',
52482
  m: 'he meneti',
52483
  mm: '%d meneti',
52484
  h: 'te haora',
52556
  future : 'после %s',
52557
  past : 'пред %s',
52558
  s : 'неколку секунди',
52559
+ ss : '%d секунди',
52560
  m : 'минута',
52561
  mm : '%d минути',
52562
  h : 'час',
52641
  future : '%s കഴിഞ്ഞ്',
52642
  past : '%s മുൻപ്',
52643
  s : 'അൽപ നിമിഷങ്ങൾ',
52644
+ ss : '%d സെക്കൻഡ്',
52645
  m : 'ഒരു മിനിറ്റ്',
52646
  mm : '%d മിനിറ്റ്',
52647
  h : 'ഒരു മണിക്കൂർ',
52733
  if (withoutSuffix) {
52734
  switch (string) {
52735
  case 's': output = 'काही सेकंद'; break;
52736
+ case 'ss': output = '%d सेकंद'; break;
52737
  case 'm': output = 'एक मिनिट'; break;
52738
  case 'mm': output = '%d मिनिटे'; break;
52739
  case 'h': output = 'एक तास'; break;
52749
  else {
52750
  switch (string) {
52751
  case 's': output = 'काही सेकंदां'; break;
52752
+ case 'ss': output = '%d सेकंदां'; break;
52753
  case 'm': output = 'एका मिनिटा'; break;
52754
  case 'mm': output = '%d मिनिटां'; break;
52755
  case 'h': output = 'एका तासा'; break;
52792
  future: '%sमध्ये',
52793
  past: '%sपूर्वी',
52794
  s: relativeTimeMr,
52795
+ ss: relativeTimeMr,
52796
  m: relativeTimeMr,
52797
  mm: relativeTimeMr,
52798
  h: relativeTimeMr,
52918
  future : 'dalam %s',
52919
  past : '%s yang lepas',
52920
  s : 'beberapa saat',
52921
+ ss : '%d saat',
52922
  m : 'seminit',
52923
  mm : '%d minit',
52924
  h : 'sejam',
53007
  future : 'dalam %s',
53008
  past : '%s yang lepas',
53009
  s : 'beberapa saat',
53010
+ ss : '%d saat',
53011
  m : 'seminit',
53012
  mm : '%d minit',
53013
  h : 'sejam',
53032
 
53033
  /***/ },
53034
  /* 379 */
53035
+ /***/ function(module, exports, __webpack_require__) {
53036
+
53037
+ //! moment.js locale configuration
53038
+ //! locale : Maltese (Malta) [mt]
53039
+ //! author : Alessandro Maruccia : https://github.com/alesma
53040
+
53041
+ ;(function (global, factory) {
53042
+ true ? factory(__webpack_require__(301)) :
53043
+ typeof define === 'function' && define.amd ? define(['../moment'], factory) :
53044
+ factory(global.moment)
53045
+ }(this, (function (moment) { 'use strict';
53046
+
53047
+
53048
+ var mt = moment.defineLocale('mt', {
53049
+ months : 'Jannar_Frar_Marzu_April_Mejju_Ġunju_Lulju_Awwissu_Settembru_Ottubru_Novembru_Diċembru'.split('_'),
53050
+ monthsShort : 'Jan_Fra_Mar_Apr_Mej_Ġun_Lul_Aww_Set_Ott_Nov_Diċ'.split('_'),
53051
+ weekdays : 'Il-Ħadd_It-Tnejn_It-Tlieta_L-Erbgħa_Il-Ħamis_Il-Ġimgħa_Is-Sibt'.split('_'),
53052
+ weekdaysShort : 'Ħad_Tne_Tli_Erb_Ħam_Ġim_Sib'.split('_'),
53053
+ weekdaysMin : 'Ħa_Tn_Tl_Er_Ħa_Ġi_Si'.split('_'),
53054
+ longDateFormat : {
53055
+ LT : 'HH:mm',
53056
+ LTS : 'HH:mm:ss',
53057
+ L : 'DD/MM/YYYY',
53058
+ LL : 'D MMMM YYYY',
53059
+ LLL : 'D MMMM YYYY HH:mm',
53060
+ LLLL : 'dddd, D MMMM YYYY HH:mm'
53061
+ },
53062
+ calendar : {
53063
+ sameDay : '[Illum fil-]LT',
53064
+ nextDay : '[Għada fil-]LT',
53065
+ nextWeek : 'dddd [fil-]LT',
53066
+ lastDay : '[Il-bieraħ fil-]LT',
53067
+ lastWeek : 'dddd [li għadda] [fil-]LT',
53068
+ sameElse : 'L'
53069
+ },
53070
+ relativeTime : {
53071
+ future : 'f’ %s',
53072
+ past : '%s ilu',
53073
+ s : 'ftit sekondi',
53074
+ ss : '%d sekondi',
53075
+ m : 'minuta',
53076
+ mm : '%d minuti',
53077
+ h : 'siegħa',
53078
+ hh : '%d siegħat',
53079
+ d : 'ġurnata',
53080
+ dd : '%d ġranet',
53081
+ M : 'xahar',
53082
+ MM : '%d xhur',
53083
+ y : 'sena',
53084
+ yy : '%d sni'
53085
+ },
53086
+ dayOfMonthOrdinalParse : /\d{1,2}º/,
53087
+ ordinal: '%dº',
53088
+ week : {
53089
+ dow : 1, // Monday is the first day of the week.
53090
+ doy : 4 // The week that contains Jan 4th is the first week of the year.
53091
+ }
53092
+ });
53093
+
53094
+ return mt;
53095
+
53096
+ })));
53097
+
53098
+
53099
+ /***/ },
53100
+ /* 380 */
53101
  /***/ function(module, exports, __webpack_require__) {
53102
 
53103
  //! moment.js locale configuration
53165
  future: 'လာမည့် %s မှာ',
53166
  past: 'လွန်ခဲ့သော %s က',
53167
  s: 'စက္ကန်.အနည်းငယ်',
53168
+ ss : '%d စက္ကန့်',
53169
  m: 'တစ်မိနစ်',
53170
  mm: '%d မိနစ်',
53171
  h: 'တစ်နာရီ',
53199
 
53200
 
53201
  /***/ },
53202
+ /* 381 */
53203
  /***/ function(module, exports, __webpack_require__) {
53204
 
53205
  //! moment.js locale configuration
53242
  future : 'om %s',
53243
  past : '%s siden',
53244
  s : 'noen sekunder',
53245
+ ss : '%d sekunder',
53246
  m : 'ett minutt',
53247
  mm : '%d minutter',
53248
  h : 'en time',
53268
 
53269
 
53270
  /***/ },
53271
+ /* 382 */
53272
  /***/ function(module, exports, __webpack_require__) {
53273
 
53274
  //! moment.js locale configuration
53373
  future : '%sमा',
53374
  past : '%s अगाडि',
53375
  s : 'केही क्षण',
53376
+ ss : '%d सेकेण्ड',
53377
  m : 'एक मिनेट',
53378
  mm : '%d मिनेट',
53379
  h : 'एक घण्टा',
53397
 
53398
 
53399
  /***/ },
53400
+ /* 383 */
53401
  /***/ function(module, exports, __webpack_require__) {
53402
 
53403
  //! moment.js locale configuration
53463
  future : 'over %s',
53464
  past : '%s geleden',
53465
  s : 'een paar seconden',
53466
+ ss : '%d seconden',
53467
  m : 'één minuut',
53468
  mm : '%d minuten',
53469
  h : 'één uur',
53491
 
53492
 
53493
  /***/ },
53494
+ /* 384 */
53495
  /***/ function(module, exports, __webpack_require__) {
53496
 
53497
  //! moment.js locale configuration
53557
  future : 'over %s',
53558
  past : '%s geleden',
53559
  s : 'een paar seconden',
53560
+ ss : '%d seconden',
53561
  m : 'één minuut',
53562
  mm : '%d minuten',
53563
  h : 'één uur',
53585
 
53586
 
53587
  /***/ },
53588
+ /* 385 */
53589
  /***/ function(module, exports, __webpack_require__) {
53590
 
53591
  //! moment.js locale configuration
53625
  future : 'om %s',
53626
  past : '%s sidan',
53627
  s : 'nokre sekund',
53628
+ ss : '%d sekund',
53629
  m : 'eit minutt',
53630
  mm : '%d minutt',
53631
  h : 'ein time',
53651
 
53652
 
53653
  /***/ },
53654
+ /* 386 */
53655
  /***/ function(module, exports, __webpack_require__) {
53656
 
53657
  //! moment.js locale configuration
53717
  future : '%s ਵਿੱਚ',
53718
  past : '%s ਪਿਛਲੇ',
53719
  s : 'ਕੁਝ ਸਕਿੰਟ',
53720
+ ss : '%d ਸਕਿੰਟ',
53721
  m : 'ਇਕ ਮਿੰਟ',
53722
  mm : '%d ਮਿੰਟ',
53723
  h : 'ਇੱਕ ਘੰਟਾ',
53781
 
53782
 
53783
  /***/ },
53784
+ /* 387 */
53785
  /***/ function(module, exports, __webpack_require__) {
53786
 
53787
  //! moment.js locale configuration
53803
  function translate(number, withoutSuffix, key) {
53804
  var result = number + ' ';
53805
  switch (key) {
53806
+ case 'ss':
53807
+ return result + (plural(number) ? 'sekundy' : 'sekund');
53808
  case 'm':
53809
  return withoutSuffix ? 'minuta' : 'minutę';
53810
  case 'mm':
53887
  future : 'za %s',
53888
  past : '%s temu',
53889
  s : 'kilka sekund',
53890
+ ss : translate,
53891
  m : translate,
53892
  mm : translate,
53893
  h : translate,
53913
 
53914
 
53915
  /***/ },
53916
+ /* 388 */
53917
  /***/ function(module, exports, __webpack_require__) {
53918
 
53919
  //! moment.js locale configuration
53958
  future : 'em %s',
53959
  past : 'há %s',
53960
  s : 'segundos',
53961
+ ss : '%d segundos',
53962
  m : 'um minuto',
53963
  mm : '%d minutos',
53964
  h : 'uma hora',
53984
 
53985
 
53986
  /***/ },
53987
+ /* 389 */
53988
  /***/ function(module, exports, __webpack_require__) {
53989
 
53990
  //! moment.js locale configuration
54051
 
54052
 
54053
  /***/ },
54054
+ /* 390 */
54055
  /***/ function(module, exports, __webpack_require__) {
54056
 
54057
  //! moment.js locale configuration
54068
 
54069
  function relativeTimeWithPlural(number, withoutSuffix, key) {
54070
  var format = {
54071
+ 'ss': 'secunde',
54072
  'mm': 'minute',
54073
  'hh': 'ore',
54074
  'dd': 'zile',
54109
  future : 'peste %s',
54110
  past : '%s în urmă',
54111
  s : 'câteva secunde',
54112
+ ss : relativeTimeWithPlural,
54113
  m : 'un minut',
54114
  mm : relativeTimeWithPlural,
54115
  h : 'o oră',
54133
 
54134
 
54135
  /***/ },
54136
+ /* 391 */
54137
  /***/ function(module, exports, __webpack_require__) {
54138
 
54139
  //! moment.js locale configuration
54155
  }
54156
  function relativeTimeWithPlural(number, withoutSuffix, key) {
54157
  var format = {
54158
+ 'ss': withoutSuffix ? 'секунда_секунды_секунд' : 'секунду_секунды_секунд',
54159
  'mm': withoutSuffix ? 'минута_минуты_минут' : 'минуту_минуты_минут',
54160
  'hh': 'час_часа_часов',
54161
  'dd': 'день_дня_дней',
54207
  // Выражение, которое соотвествует только сокращённым формам
54208
  monthsShortStrictRegex: /^(янв\.|февр?\.|мар[т.]|апр\.|ма[яй]|июн[ья.]|июл[ья.]|авг\.|сент?\.|окт\.|нояб?\.|дек\.)/i,
54209
  longDateFormat : {
54210
+ LT : 'H:mm',
54211
+ LTS : 'H:mm:ss',
54212
  L : 'DD.MM.YYYY',
54213
  LL : 'D MMMM YYYY г.',
54214
+ LLL : 'D MMMM YYYY г., H:mm',
54215
+ LLLL : 'dddd, D MMMM YYYY г., H:mm'
54216
  },
54217
  calendar : {
54218
  sameDay: '[Сегодня в] LT',
54268
  future : 'через %s',
54269
  past : '%s назад',
54270
  s : 'несколько секунд',
54271
+ ss : relativeTimeWithPlural,
54272
  m : relativeTimeWithPlural,
54273
  mm : relativeTimeWithPlural,
54274
  h : 'час',
54323
 
54324
 
54325
  /***/ },
54326
+ /* 392 */
54327
  /***/ function(module, exports, __webpack_require__) {
54328
 
54329
  //! moment.js locale configuration
54397
  future : '%s پوء',
54398
  past : '%s اڳ',
54399
  s : 'چند سيڪنڊ',
54400
+ ss : '%d سيڪنڊ',
54401
  m : 'هڪ منٽ',
54402
  mm : '%d منٽ',
54403
  h : 'هڪ ڪلاڪ',
54427
 
54428
 
54429
  /***/ },
54430
+ /* 393 */
54431
  /***/ function(module, exports, __webpack_require__) {
54432
 
54433
  //! moment.js locale configuration
54468
  future : '%s geažes',
54469
  past : 'maŋit %s',
54470
  s : 'moadde sekunddat',
54471
+ ss: '%d sekunddat',
54472
  m : 'okta minuhta',
54473
  mm : '%d minuhtat',
54474
  h : 'okta diimmu',
54494
 
54495
 
54496
  /***/ },
54497
+ /* 394 */
54498
  /***/ function(module, exports, __webpack_require__) {
54499
 
54500
  //! moment.js locale configuration
54536
  future : '%sකින්',
54537
  past : '%sකට පෙර',
54538
  s : 'තත්පර කිහිපය',
54539
+ ss : 'තත්පර %d',
54540
  m : 'මිනිත්තුව',
54541
  mm : 'මිනිත්තු %d',
54542
  h : 'පැය',
54571
 
54572
 
54573
  /***/ },
54574
+ /* 395 */
54575
  /***/ function(module, exports, __webpack_require__) {
54576
 
54577
  //! moment.js locale configuration
54596
  switch (key) {
54597
  case 's': // a few seconds / in a few seconds / a few seconds ago
54598
  return (withoutSuffix || isFuture) ? 'pár sekúnd' : 'pár sekundami';
54599
+ case 'ss': // 9 seconds / in 9 seconds / 9 seconds ago
54600
+ if (withoutSuffix || isFuture) {
54601
+ return result + (plural(number) ? 'sekundy' : 'sekúnd');
54602
+ } else {
54603
+ return result + 'sekundami';
54604
+ }
54605
+ break;
54606
  case 'm': // a minute / in a minute / a minute ago
54607
  return withoutSuffix ? 'minúta' : (isFuture ? 'minútu' : 'minútou');
54608
  case 'mm': // 9 minutes / in 9 minutes / 9 minutes ago
54708
  future : 'za %s',
54709
  past : 'pred %s',
54710
  s : translate,
54711
+ ss : translate,
54712
  m : translate,
54713
  mm : translate,
54714
  h : translate,
54734
 
54735
 
54736
  /***/ },
54737
+ /* 396 */
54738
  /***/ function(module, exports, __webpack_require__) {
54739
 
54740
  //! moment.js locale configuration
54753
  switch (key) {
54754
  case 's':
54755
  return withoutSuffix || isFuture ? 'nekaj sekund' : 'nekaj sekundami';
54756
+ case 'ss':
54757
+ if (number === 1) {
54758
+ result += withoutSuffix ? 'sekundo' : 'sekundi';
54759
+ } else if (number === 2) {
54760
+ result += withoutSuffix || isFuture ? 'sekundi' : 'sekundah';
54761
+ } else if (number < 5) {
54762
+ result += withoutSuffix || isFuture ? 'sekunde' : 'sekundah';
54763
+ } else {
54764
+ result += withoutSuffix || isFuture ? 'sekund' : 'sekund';
54765
+ }
54766
+ return result;
54767
  case 'm':
54768
  return withoutSuffix ? 'ena minuta' : 'eno minuto';
54769
  case 'mm':
54887
  future : 'čez %s',
54888
  past : 'pred %s',
54889
  s : processRelativeTime,
54890
+ ss : processRelativeTime,
54891
  m : processRelativeTime,
54892
  mm : processRelativeTime,
54893
  h : processRelativeTime,
54913
 
54914
 
54915
  /***/ },
54916
+ /* 397 */
54917
  /***/ function(module, exports, __webpack_require__) {
54918
 
54919
  //! moment.js locale configuration
54963
  future : 'në %s',
54964
  past : '%s më parë',
54965
  s : 'disa sekonda',
54966
+ ss : '%d sekonda',
54967
  m : 'një minutë',
54968
  mm : '%d minuta',
54969
  h : 'një orë',
54989
 
54990
 
54991
  /***/ },
54992
+ /* 398 */
54993
  /***/ function(module, exports, __webpack_require__) {
54994
 
54995
  //! moment.js locale configuration
55005
 
55006
  var translator = {
55007
  words: { //Different grammatical cases
55008
+ ss: ['sekunda', 'sekunde', 'sekundi'],
55009
  m: ['jedan minut', 'jedne minute'],
55010
  mm: ['minut', 'minute', 'minuta'],
55011
  h: ['jedan sat', 'jednog sata'],
55080
  future : 'za %s',
55081
  past : 'pre %s',
55082
  s : 'nekoliko sekundi',
55083
+ ss : translator.translate,
55084
  m : translator.translate,
55085
  mm : translator.translate,
55086
  h : translator.translate,
55106
 
55107
 
55108
  /***/ },
55109
+ /* 399 */
55110
  /***/ function(module, exports, __webpack_require__) {
55111
 
55112
  //! moment.js locale configuration
55122
 
55123
  var translator = {
55124
  words: { //Different grammatical cases
55125
+ ss: ['секунда', 'секунде', 'секунди'],
55126
  m: ['један минут', 'једне минуте'],
55127
  mm: ['минут', 'минуте', 'минута'],
55128
  h: ['један сат', 'једног сата'],
55197
  future : 'за %s',
55198
  past : 'пре %s',
55199
  s : 'неколико секунди',
55200
+ ss : translator.translate,
55201
  m : translator.translate,
55202
  mm : translator.translate,
55203
  h : translator.translate,
55223
 
55224
 
55225
  /***/ },
55226
+ /* 400 */
55227
  /***/ function(module, exports, __webpack_require__) {
55228
 
55229
  //! moment.js locale configuration
55265
  future : 'nga %s',
55266
  past : 'wenteka nga %s',
55267
  s : 'emizuzwana lomcane',
55268
+ ss : '%d mzuzwana',
55269
  m : 'umzuzu',
55270
  mm : '%d emizuzu',
55271
  h : 'lihora',
55318
 
55319
 
55320
  /***/ },
55321
+ /* 401 */
55322
  /***/ function(module, exports, __webpack_require__) {
55323
 
55324
  //! moment.js locale configuration
55360
  future : 'om %s',
55361
  past : 'för %s sedan',
55362
  s : 'några sekunder',
55363
+ ss : '%d sekunder',
55364
  m : 'en minut',
55365
  mm : '%d minuter',
55366
  h : 'en timme',
55393
 
55394
 
55395
  /***/ },
55396
+ /* 402 */
55397
  /***/ function(module, exports, __webpack_require__) {
55398
 
55399
  //! moment.js locale configuration
55434
  future : '%s baadaye',
55435
  past : 'tokea %s',
55436
  s : 'hivi punde',
55437
+ ss : 'sekunde %d',
55438
  m : 'dakika moja',
55439
  mm : 'dakika %d',
55440
  h : 'saa limoja',
55458
 
55459
 
55460
  /***/ },
55461
+ /* 403 */
55462
  /***/ function(module, exports, __webpack_require__) {
55463
 
55464
  //! moment.js locale configuration
55523
  future : '%s இல்',
55524
  past : '%s முன்',
55525
  s : 'ஒரு சில விநாடிகள்',
55526
+ ss : '%d விநாடிகள்',
55527
  m : 'ஒரு நிமிடம்',
55528
  mm : '%d நிமிடங்கள்',
55529
  h : 'ஒரு மணி நேரம்',
55594
 
55595
 
55596
  /***/ },
55597
+ /* 404 */
55598
  /***/ function(module, exports, __webpack_require__) {
55599
 
55600
  //! moment.js locale configuration
55635
  future : '%s లో',
55636
  past : '%s క్రితం',
55637
  s : 'కొన్ని క్షణాలు',
55638
+ ss : '%d సెకన్లు',
55639
  m : 'ఒక నిమిషం',
55640
  mm : '%d నిమిషాలు',
55641
  h : 'ఒక గంట',
55689
 
55690
 
55691
  /***/ },
55692
+ /* 405 */
55693
  /***/ function(module, exports, __webpack_require__) {
55694
 
55695
  //! moment.js locale configuration
55730
  future : 'iha %s',
55731
  past : '%s liuba',
55732
  s : 'minutu balun',
55733
+ ss : 'minutu %d',
55734
  m : 'minutu ida',
55735
  mm : 'minutus %d',
55736
  h : 'horas ida',
55763
 
55764
 
55765
  /***/ },
55766
+ /* 406 */
55767
  /***/ function(module, exports, __webpack_require__) {
55768
 
55769
  //! moment.js locale configuration
55816
  future : 'อีก %s',
55817
  past : '%sที่แล้ว',
55818
  s : 'ไม่กี่วินาที',
55819
+ ss : '%d วินาที',
55820
  m : '1 นาที',
55821
  mm : '%d นาที',
55822
  h : '1 ชั่วโมง',
55836
 
55837
 
55838
  /***/ },
55839
+ /* 407 */
55840
  /***/ function(module, exports, __webpack_require__) {
55841
 
55842
  //! moment.js locale configuration
55876
  future : 'sa loob ng %s',
55877
  past : '%s ang nakalipas',
55878
  s : 'ilang segundo',
55879
+ ss : '%d segundo',
55880
  m : 'isang minuto',
55881
  mm : '%d minuto',
55882
  h : 'isang oras',
55904
 
55905
 
55906
  /***/ },
55907
+ /* 408 */
55908
  /***/ function(module, exports, __webpack_require__) {
55909
 
55910
  //! moment.js locale configuration
55947
  function translate(number, withoutSuffix, string, isFuture) {
55948
  var numberNoun = numberAsNoun(number);
55949
  switch (string) {
55950
+ case 'ss':
55951
+ return numberNoun + ' lup';
55952
  case 'mm':
55953
  return numberNoun + ' tup';
55954
  case 'hh':
56006
  future : translateFuture,
56007
  past : translatePast,
56008
  s : 'puS lup',
56009
+ ss : translate,
56010
  m : 'wa’ tup',
56011
  mm : translate,
56012
  h : 'wa’ rep',
56032
 
56033
 
56034
  /***/ },
56035
+ /* 409 */
56036
  /***/ function(module, exports, __webpack_require__) {
56037
 
56038
  //! moment.js locale configuration
56094
  future : '%s sonra',
56095
  past : '%s önce',
56096
  s : 'birkaç saniye',
56097
+ ss : '%d saniye',
56098
  m : 'bir dakika',
56099
  mm : '%d dakika',
56100
  h : 'bir saat',
56128
 
56129
 
56130
  /***/ },
56131
+ /* 410 */
56132
  /***/ function(module, exports, __webpack_require__) {
56133
 
56134
  //! moment.js locale configuration
56182
  future : 'osprei %s',
56183
  past : 'ja%s',
56184
  s : processRelativeTime,
56185
+ ss : processRelativeTime,
56186
  m : processRelativeTime,
56187
  mm : processRelativeTime,
56188
  h : processRelativeTime,
56205
  function processRelativeTime(number, withoutSuffix, key, isFuture) {
56206
  var format = {
56207
  's': ['viensas secunds', '\'iensas secunds'],
56208
+ 'ss': [number + ' secunds', '' + number + ' secunds'],
56209
  'm': ['\'n míut', '\'iens míut'],
56210
  'mm': [number + ' míuts', '' + number + ' míuts'],
56211
  'h': ['\'n þora', '\'iensa þora'],
56226
 
56227
 
56228
  /***/ },
56229
+ /* 411 */
56230
  /***/ function(module, exports, __webpack_require__) {
56231
 
56232
  //! moment.js locale configuration
56266
  future : 'ⴷⴰⴷⵅ ⵙ ⵢⴰⵏ %s',
56267
  past : 'ⵢⴰⵏ %s',
56268
  s : 'ⵉⵎⵉⴽ',
56269
+ ss : '%d ⵉⵎⵉⴽ',
56270
  m : 'ⵎⵉⵏⵓⴺ',
56271
  mm : '%d ⵎⵉⵏⵓⴺ',
56272
  h : 'ⵙⴰⵄⴰ',
56290
 
56291
 
56292
  /***/ },
56293
+ /* 412 */
56294
  /***/ function(module, exports, __webpack_require__) {
56295
 
56296
  //! moment.js locale configuration
56330
  future : 'dadkh s yan %s',
56331
  past : 'yan %s',
56332
  s : 'imik',
56333
+ ss : '%d imik',
56334
  m : 'minuḍ',
56335
  mm : '%d minuḍ',
56336
  h : 'saɛa',
56354
 
56355
 
56356
  /***/ },
56357
+ /* 413 */
56358
  /***/ function(module, exports, __webpack_require__) {
56359
 
56360
  //! moment.js locale configuration
56375
  }
56376
  function relativeTimeWithPlural(number, withoutSuffix, key) {
56377
  var format = {
56378
+ 'ss': withoutSuffix ? 'секунда_секунди_секунд' : 'секунду_секунди_секунд',
56379
  'mm': withoutSuffix ? 'хвилина_хвилини_хвилин' : 'хвилину_хвилини_хвилин',
56380
  'hh': withoutSuffix ? 'година_години_годин' : 'годину_години_годин',
56381
  'dd': 'день_дні_днів',
56457
  future : 'за %s',
56458
  past : '%s тому',
56459
  s : 'декілька секунд',
56460
+ ss : relativeTimeWithPlural,
56461
  m : relativeTimeWithPlural,
56462
  mm : relativeTimeWithPlural,
56463
  h : 'годину',
56512
 
56513
 
56514
  /***/ },
56515
+ /* 414 */
56516
  /***/ function(module, exports, __webpack_require__) {
56517
 
56518
  //! moment.js locale configuration
56587
  future : '%s بعد',
56588
  past : '%s قبل',
56589
  s : 'چند سیکنڈ',
56590
+ ss : '%d سیکنڈ',
56591
  m : 'ایک منٹ',
56592
  mm : '%d منٹ',
56593
  h : 'ایک گھنٹہ',
56617
 
56618
 
56619
  /***/ },
56620
+ /* 415 */
56621
  /***/ function(module, exports, __webpack_require__) {
56622
 
56623
  //! moment.js locale configuration
56657
  future : 'Якин %s ичида',
56658
  past : 'Бир неча %s олдин',
56659
  s : 'фурсат',
56660
+ ss : '%d фурсат',
56661
  m : 'бир дакика',
56662
  mm : '%d дакика',
56663
  h : 'бир соат',
56681
 
56682
 
56683
  /***/ },
56684
+ /* 416 */
56685
  /***/ function(module, exports, __webpack_require__) {
56686
 
56687
  //! moment.js locale configuration
56721
  future : 'Yaqin %s ichida',
56722
  past : 'Bir necha %s oldin',
56723
  s : 'soniya',
56724
+ ss : '%d soniya',
56725
  m : 'bir daqiqa',
56726
  mm : '%d daqiqa',
56727
  h : 'bir soat',
56745
 
56746
 
56747
  /***/ },
56748
+ /* 417 */
56749
  /***/ function(module, exports, __webpack_require__) {
56750
 
56751
  //! moment.js locale configuration
56802
  future : '%s tới',
56803
  past : '%s trước',
56804
  s : 'vài giây',
56805
+ ss : '%d giây' ,
56806
  m : 'một phút',
56807
  mm : '%d phút',
56808
  h : 'một giờ',
56830
 
56831
 
56832
  /***/ },
56833
+ /* 418 */
56834
  /***/ function(module, exports, __webpack_require__) {
56835
 
56836
  //! moment.js locale configuration
56871
  future : 'í~ñ %s',
56872
  past : '%s á~gó',
56873
  s : 'á ~féw ~sécó~ñds',
56874
+ ss : '%d s~écóñ~ds',
56875
  m : 'á ~míñ~úté',
56876
  mm : '%d m~íñú~tés',
56877
  h : 'á~ñ hó~úr',
56904
 
56905
 
56906
  /***/ },
56907
+ /* 419 */
56908
  /***/ function(module, exports, __webpack_require__) {
56909
 
56910
  //! moment.js locale configuration
56944
  future : 'ní %s',
56945
  past : '%s kọjá',
56946
  s : 'ìsẹjú aayá die',
56947
+ ss :'aayá %d',
56948
  m : 'ìsẹjú kan',
56949
  mm : 'ìsẹjú %d',
56950
  h : 'wákati kan',
56970
 
56971
 
56972
  /***/ },
56973
+ /* 420 */
56974
  /***/ function(module, exports, __webpack_require__) {
56975
 
56976
  //! moment.js locale configuration
56994
  longDateFormat : {
56995
  LT : 'HH:mm',
56996
  LTS : 'HH:mm:ss',
56997
+ L : 'YYYY/MM/DD',
56998
+ LL : 'YYYY年M月D日',
56999
+ LLL : 'YYYY年M月D日Ah点mm分',
57000
+ LLLL : 'YYYY年M月D日ddddAh点mm分',
57001
+ l : 'YYYY/M/D',
57002
+ ll : 'YYYY年M月D日',
57003
+ lll : 'YYYY年M月D日 HH:mm',
57004
+ llll : 'YYYY年M月D日dddd HH:mm'
57005
  },
57006
  meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
57007
  meridiemHour: function (hour, meridiem) {
57062
  future : '%s内',
57063
  past : '%s前',
57064
  s : '几秒',
57065
+ ss : '%d 秒',
57066
  m : '1 分钟',
57067
  mm : '%d 分钟',
57068
  h : '1 小时',
57087
 
57088
 
57089
  /***/ },
57090
+ /* 421 */
57091
  /***/ function(module, exports, __webpack_require__) {
57092
 
57093
  //! moment.js locale configuration
57112
  longDateFormat : {
57113
  LT : 'HH:mm',
57114
  LTS : 'HH:mm:ss',
57115
+ L : 'YYYY/MM/DD',
57116
+ LL : 'YYYY年M月D日',
57117
+ LLL : 'YYYY年M月D日 HH:mm',
57118
+ LLLL : 'YYYY年M月D日dddd HH:mm',
57119
+ l : 'YYYY/M/D',
57120
+ ll : 'YYYY年M月D日',
57121
+ lll : 'YYYY年M月D日 HH:mm',
57122
+ llll : 'YYYY年M月D日dddd HH:mm'
57123
  },
57124
  meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
57125
  meridiemHour : function (hour, meridiem) {
57178
  future : '%s內',
57179
  past : '%s前',
57180
  s : '幾秒',
57181
+ ss : '%d 秒',
57182
  m : '1 分鐘',
57183
  mm : '%d 分鐘',
57184
  h : '1 小時',
57198
 
57199
 
57200
  /***/ },
57201
+ /* 422 */
57202
  /***/ function(module, exports, __webpack_require__) {
57203
 
57204
  //! moment.js locale configuration
57222
  longDateFormat : {
57223
  LT : 'HH:mm',
57224
  LTS : 'HH:mm:ss',
57225
+ L : 'YYYY/MM/DD',
57226
+ LL : 'YYYY年M月D日',
57227
+ LLL : 'YYYY年M月D日 HH:mm',
57228
+ LLLL : 'YYYY年M月D日dddd HH:mm',
57229
+ l : 'YYYY/M/D',
57230
+ ll : 'YYYY年M月D日',
57231
+ lll : 'YYYY年M月D日 HH:mm',
57232
+ llll : 'YYYY年M月D日dddd HH:mm'
57233
  },
57234
  meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
57235
  meridiemHour : function (hour, meridiem) {
57288
  future : '%s內',
57289
  past : '%s前',
57290
  s : '幾秒',
57291
+ ss : '%d 秒',
57292
  m : '1 分鐘',
57293
  mm : '%d 分鐘',
57294
  h : '1 小時',
57308
 
57309
 
57310
  /***/ },
57311
+ /* 423 */
57312
  /***/ function(module, exports, __webpack_require__) {
57313
 
57314
  /* WEBPACK VAR INJECTION */(function(global) {if(!global["MailPoetLib"]) global["MailPoetLib"] = {};
57315
+ module.exports = global["MailPoetLib"]["ReactStringReplace"] = __webpack_require__(424);
57316
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
57317
 
57318
  /***/ },
57319
+ /* 424 */
57320
  /***/ function(module, exports, __webpack_require__) {
57321
 
57322
  /* eslint-disable vars-on-top, no-var, prefer-template */
57323
+ var isRegExp = __webpack_require__(425);
57324
+ var escapeRegExp = __webpack_require__(426);
57325
+ var isString = __webpack_require__(427);
57326
+ var flatten = __webpack_require__(428);
57327
 
57328
  /**
57329
  * Given a string, replace every substring that is matched by the `match` regex
57381
 
57382
 
57383
  /***/ },
57384
+ /* 425 */
57385
  /***/ function(module, exports, __webpack_require__) {
57386
 
57387
  /* WEBPACK VAR INJECTION */(function(global, module) {/**
57509
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }()), __webpack_require__(302)(module)))
57510
 
57511
  /***/ },
57512
+ /* 426 */
57513
  /***/ function(module, exports) {
57514
 
57515
  /* WEBPACK VAR INJECTION */(function(global) {/**
57682
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
57683
 
57684
  /***/ },
57685
+ /* 427 */
57686
  /***/ function(module, exports) {
57687
 
57688
  /**
57783
 
57784
 
57785
  /***/ },
57786
+ /* 428 */
57787
  /***/ function(module, exports) {
57788
 
57789
  /* WEBPACK VAR INJECTION */(function(global) {/**
58139
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
58140
 
58141
  /***/ },
 
58142
  /* 429 */,
58143
  /* 430 */,
58144
  /* 431 */,
58145
+ /* 432 */,
58146
+ /* 433 */
58147
  /***/ function(module, exports, __webpack_require__) {
58148
 
58149
  /* WEBPACK VAR INJECTION */(function(global) {"use strict";
58150
 
58151
  if (!global["MailPoetLib"]) global["MailPoetLib"] = {};
58152
+ module.exports = global["MailPoetLib"]["NewsletterCreationBreadcrumb"] = __webpack_require__(434);
58153
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
58154
 
58155
  /***/ },
58156
+ /* 434 */
58157
  /***/ function(module, exports, __webpack_require__) {
58158
 
58159
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
58223
  }.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
58224
 
58225
  /***/ },
 
58226
  /* 435 */,
58227
  /* 436 */,
58228
+ /* 437 */,
58229
+ /* 438 */
58230
  /***/ function(module, exports, __webpack_require__) {
58231
 
58232
  'use strict';
58262
 
58263
  var _classnames2 = _interopRequireDefault(_classnames);
58264
 
58265
+ var _staticMethods = __webpack_require__(439);
58266
 
58267
  var _staticMethods2 = _interopRequireDefault(_staticMethods);
58268
 
58269
+ var _windowListener = __webpack_require__(441);
58270
 
58271
  var _windowListener2 = _interopRequireDefault(_windowListener);
58272
 
58273
+ var _customEvent = __webpack_require__(442);
58274
 
58275
  var _customEvent2 = _interopRequireDefault(_customEvent);
58276
 
58277
+ var _isCapture = __webpack_require__(443);
58278
 
58279
  var _isCapture2 = _interopRequireDefault(_isCapture);
58280
 
58281
+ var _getEffect = __webpack_require__(444);
58282
 
58283
  var _getEffect2 = _interopRequireDefault(_getEffect);
58284
 
58285
+ var _trackRemoval = __webpack_require__(445);
58286
 
58287
  var _trackRemoval2 = _interopRequireDefault(_trackRemoval);
58288
 
58289
+ var _getPosition = __webpack_require__(446);
58290
 
58291
  var _getPosition2 = _interopRequireDefault(_getPosition);
58292
 
58293
+ var _getTipContent = __webpack_require__(447);
58294
 
58295
  var _getTipContent2 = _interopRequireDefault(_getTipContent);
58296
 
58297
+ var _aria = __webpack_require__(448);
58298
 
58299
+ var _nodeListToArray = __webpack_require__(449);
58300
 
58301
  var _nodeListToArray2 = _interopRequireDefault(_nodeListToArray);
58302
 
58303
+ var _style = __webpack_require__(450);
58304
 
58305
  var _style2 = _interopRequireDefault(_style);
58306
 
58825
  module.exports = ReactTooltip;
58826
 
58827
  /***/ },
58828
+ /* 439 */
58829
  /***/ function(module, exports, __webpack_require__) {
58830
 
58831
  'use strict';
58883
  };
58884
  };
58885
 
58886
+ var _constant = __webpack_require__(440);
58887
 
58888
  var _constant2 = _interopRequireDefault(_constant);
58889
 
58908
  */
58909
 
58910
  /***/ },
58911
+ /* 440 */
58912
  /***/ function(module, exports) {
58913
 
58914
  'use strict';
58926
  };
58927
 
58928
  /***/ },
58929
+ /* 441 */
58930
  /***/ function(module, exports, __webpack_require__) {
58931
 
58932
  'use strict';
58972
  };
58973
  };
58974
 
58975
+ var _constant = __webpack_require__(440);
58976
 
58977
  var _constant2 = _interopRequireDefault(_constant);
58978
 
58979
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
58980
 
58981
  /***/ },
58982
+ /* 442 */
58983
  /***/ function(module, exports) {
58984
 
58985
  'use strict';
59072
  var customListener = void 0;
59073
 
59074
  /***/ },
59075
+ /* 443 */
59076
  /***/ function(module, exports) {
59077
 
59078
  'use strict';
59089
  };
59090
 
59091
  /***/ },
59092
+ /* 444 */
59093
  /***/ function(module, exports) {
59094
 
59095
  'use strict';
59106
  };
59107
 
59108
  /***/ },
59109
+ /* 445 */
59110
  /***/ function(module, exports) {
59111
 
59112
  "use strict";
59202
  };
59203
 
59204
  /***/ },
59205
+ /* 446 */
59206
  /***/ function(module, exports) {
59207
 
59208
  'use strict';
59516
  };
59517
 
59518
  /***/ },
59519
+ /* 447 */
59520
  /***/ function(module, exports, __webpack_require__) {
59521
 
59522
  'use strict';
59553
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
59554
 
59555
  /***/ },
59556
+ /* 448 */
59557
  /***/ function(module, exports) {
59558
 
59559
  "use strict";
59582
  }
59583
 
59584
  /***/ },
59585
+ /* 449 */
59586
  /***/ function(module, exports) {
59587
 
59588
  "use strict";
59602
  };
59603
 
59604
  /***/ },
59605
+ /* 450 */
59606
  /***/ function(module, exports) {
59607
 
59608
  'use strict';
59613
  exports.default = '.__react_component_tooltip{border-radius:3px;display:inline-block;font-size:13px;left:-999em;opacity:0;padding:8px 21px;position:fixed;pointer-events:none;transition:opacity 0.3s ease-out;top:-999em;visibility:hidden;z-index:999}.__react_component_tooltip:before,.__react_component_tooltip:after{content:"";width:0;height:0;position:absolute}.__react_component_tooltip.show{opacity:0.9;margin-top:0px;margin-left:0px;visibility:visible}.__react_component_tooltip.type-dark{color:#fff;background-color:#222}.__react_component_tooltip.type-dark.place-top:after{border-top-color:#222;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-dark.place-bottom:after{border-bottom-color:#222;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-dark.place-left:after{border-left-color:#222;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-dark.place-right:after{border-right-color:#222;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-dark.border{border:1px solid #fff}.__react_component_tooltip.type-dark.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-dark.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-dark.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-dark.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-success{color:#fff;background-color:#8DC572}.__react_component_tooltip.type-success.place-top:after{border-top-color:#8DC572;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-success.place-bottom:after{border-bottom-color:#8DC572;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-success.place-left:after{border-left-color:#8DC572;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-success.place-right:after{border-right-color:#8DC572;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-success.border{border:1px solid #fff}.__react_component_tooltip.type-success.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-success.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-success.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-success.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-warning{color:#fff;background-color:#F0AD4E}.__react_component_tooltip.type-warning.place-top:after{border-top-color:#F0AD4E;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-warning.place-bottom:after{border-bottom-color:#F0AD4E;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-warning.place-left:after{border-left-color:#F0AD4E;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-warning.place-right:after{border-right-color:#F0AD4E;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-warning.border{border:1px solid #fff}.__react_component_tooltip.type-warning.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-warning.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-warning.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-warning.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-error{color:#fff;background-color:#BE6464}.__react_component_tooltip.type-error.place-top:after{border-top-color:#BE6464;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-error.place-bottom:after{border-bottom-color:#BE6464;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-error.place-left:after{border-left-color:#BE6464;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-error.place-right:after{border-right-color:#BE6464;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-error.border{border:1px solid #fff}.__react_component_tooltip.type-error.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-error.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-error.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-error.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-info{color:#fff;background-color:#337AB7}.__react_component_tooltip.type-info.place-top:after{border-top-color:#337AB7;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-info.place-bottom:after{border-bottom-color:#337AB7;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-info.place-left:after{border-left-color:#337AB7;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-info.place-right:after{border-right-color:#337AB7;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-info.border{border:1px solid #fff}.__react_component_tooltip.type-info.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-info.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-info.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-info.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-light{color:#222;background-color:#fff}.__react_component_tooltip.type-light.place-top:after{border-top-color:#fff;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-light.place-bottom:after{border-bottom-color:#fff;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-light.place-left:after{border-left-color:#fff;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-light.place-right:after{border-right-color:#fff;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-light.border{border:1px solid #222}.__react_component_tooltip.type-light.border.place-top:before{border-top:8px solid #222}.__react_component_tooltip.type-light.border.place-bottom:before{border-bottom:8px solid #222}.__react_component_tooltip.type-light.border.place-left:before{border-left:8px solid #222}.__react_component_tooltip.type-light.border.place-right:before{border-right:8px solid #222}.__react_component_tooltip.place-top{margin-top:-10px}.__react_component_tooltip.place-top:before{border-left:10px solid transparent;border-right:10px solid transparent;bottom:-8px;left:50%;margin-left:-10px}.__react_component_tooltip.place-top:after{border-left:8px solid transparent;border-right:8px solid transparent;bottom:-6px;left:50%;margin-left:-8px}.__react_component_tooltip.place-bottom{margin-top:10px}.__react_component_tooltip.place-bottom:before{border-left:10px solid transparent;border-right:10px solid transparent;top:-8px;left:50%;margin-left:-10px}.__react_component_tooltip.place-bottom:after{border-left:8px solid transparent;border-right:8px solid transparent;top:-6px;left:50%;margin-left:-8px}.__react_component_tooltip.place-left{margin-left:-10px}.__react_component_tooltip.place-left:before{border-top:6px solid transparent;border-bottom:6px solid transparent;right:-8px;top:50%;margin-top:-5px}.__react_component_tooltip.place-left:after{border-top:5px solid transparent;border-bottom:5px solid transparent;right:-6px;top:50%;margin-top:-4px}.__react_component_tooltip.place-right{margin-left:10px}.__react_component_tooltip.place-right:before{border-top:6px solid transparent;border-bottom:6px solid transparent;left:-8px;top:50%;margin-top:-5px}.__react_component_tooltip.place-right:after{border-top:5px solid transparent;border-bottom:5px solid transparent;left:-6px;top:50%;margin-top:-4px}.__react_component_tooltip .multi-line{display:block;padding:2px 0px;text-align:center}';
59614
 
59615
  /***/ },
 
59616
  /* 451 */,
59617
  /* 452 */,
59618
  /* 453 */,
59683
  /* 518 */,
59684
  /* 519 */,
59685
  /* 520 */,
59686
+ /* 521 */,
59687
+ /* 522 */
59688
  /***/ function(module, exports, __webpack_require__) {
59689
 
59690
  'use strict';
59778
  exports.nthWeekDayValues = nthWeekDayValues;
59779
 
59780
  /***/ },
 
59781
  /* 523 */,
59782
+ /* 524 */,
59783
+ /* 525 */
59784
  /***/ function(module, exports, __webpack_require__) {
59785
 
59786
  /* WEBPACK VAR INJECTION */(function(global) {"use strict";
59787
 
59788
  if (!global["MailPoetLib"]) global["MailPoetLib"] = {};
59789
+ module.exports = global["MailPoetLib"]["NewsletterWelcomeNotificationScheduling"] = __webpack_require__(526);
59790
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
59791
 
59792
  /***/ },
59793
+ /* 526 */
59794
  /***/ function(module, exports, __webpack_require__) {
59795
 
59796
  'use strict';
59817
 
59818
  var _formFieldsTextJsx2 = _interopRequireDefault(_formFieldsTextJsx);
59819
 
59820
+ var _newslettersSchedulingCommonJsx = __webpack_require__(522);
59821
 
59822
  var availableRoles = window.mailpoet_roles || {};
59823
  var availableSegments = _underscore2['default'].filter(window.mailpoet_segments || [], function (segment) {
59963
  module.exports = WelcomeScheduling;
59964
 
59965
  /***/ },
 
59966
  /* 527 */,
59967
  /* 528 */,
59968
  /* 529 */,
59969
  /* 530 */,
59970
+ /* 531 */,
59971
+ /* 532 */,
59972
+ /* 533 */,
59973
+ /* 534 */
59974
  /***/ function(module, exports, __webpack_require__) {
59975
 
59976
  /* WEBPACK VAR INJECTION */(function(global) {"use strict";
59977
 
59978
  if (!global["MailPoetLib"]) global["MailPoetLib"] = {};
59979
+ module.exports = global["MailPoetLib"]["StatsBadge"] = __webpack_require__(535);
59980
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
59981
 
59982
  /***/ },
59983
+ /* 535 */
59984
  /***/ function(module, exports, __webpack_require__) {
59985
 
59986
  'use strict';
60007
 
60008
  var _react2 = _interopRequireDefault(_react);
60009
 
60010
+ var _badgeJsx = __webpack_require__(536);
60011
 
60012
  var _badgeJsx2 = _interopRequireDefault(_badgeJsx);
60013
 
60119
  module.exports = exports['default'];
60120
 
60121
  /***/ },
60122
+ /* 536 */
60123
  /***/ function(module, exports, __webpack_require__) {
60124
 
60125
  'use strict';
60146
 
60147
  var _classnames2 = _interopRequireDefault(_classnames);
60148
 
60149
+ var _reactTooltip = __webpack_require__(438);
60150
 
60151
  var _reactTooltip2 = _interopRequireDefault(_reactTooltip);
60152
 
assets/js/{form_editor.13982476.js → form_editor.901a1d16.js} RENAMED
@@ -3,22 +3,22 @@ webpackJsonp([2],{
3
  /***/ 0:
4
  /***/ function(module, exports, __webpack_require__) {
5
 
6
- __webpack_require__(557);
7
- __webpack_require__(559);
8
- module.exports = __webpack_require__(561);
9
 
10
 
11
  /***/ },
12
 
13
- /***/ 557:
14
  /***/ function(module, exports, __webpack_require__) {
15
 
16
- /* WEBPACK VAR INJECTION */(function(global) {module.exports = global["WysijaForm"] = __webpack_require__(558);
17
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
18
 
19
  /***/ },
20
 
21
- /***/ 558:
22
  /***/ function(module, exports) {
23
 
24
  /* eslint-disable func-names */
@@ -1121,15 +1121,15 @@ webpackJsonp([2],{
1121
 
1122
  /***/ },
1123
 
1124
- /***/ 559:
1125
  /***/ function(module, exports, __webpack_require__) {
1126
 
1127
- /* WEBPACK VAR INJECTION */(function(global) {module.exports = global["CodeMirror"] = __webpack_require__(560);
1128
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
1129
 
1130
  /***/ },
1131
 
1132
- /***/ 560:
1133
  /***/ function(module, exports, __webpack_require__) {
1134
 
1135
  // CodeMirror, copyright (c) by Marijn Haverbeke and others
@@ -7719,11 +7719,11 @@ webpackJsonp([2],{
7719
  }
7720
 
7721
  var keyNames = {
7722
- 3: "Enter", 8: "Backspace", 9: "Tab", 13: "Enter", 16: "Shift", 17: "Ctrl", 18: "Alt",
7723
  19: "Pause", 20: "CapsLock", 27: "Esc", 32: "Space", 33: "PageUp", 34: "PageDown", 35: "End",
7724
  36: "Home", 37: "Left", 38: "Up", 39: "Right", 40: "Down", 44: "PrintScrn", 45: "Insert",
7725
  46: "Delete", 59: ";", 61: "=", 91: "Mod", 92: "Mod", 93: "Mod",
7726
- 106: "*", 107: "=", 109: "-", 110: ".", 111: "/", 127: "Delete",
7727
  173: "-", 186: ";", 187: "=", 188: ",", 189: "-", 190: ".", 191: "/", 192: "`", 219: "[", 220: "\\",
7728
  221: "]", 222: "'", 63232: "Up", 63233: "Down", 63234: "Left", 63235: "Right", 63272: "Delete",
7729
  63273: "Home", 63275: "End", 63276: "PageUp", 63277: "PageDown", 63302: "Insert"
@@ -7870,6 +7870,9 @@ webpackJsonp([2],{
7870
  if (presto && event.keyCode == 34 && event["char"]) { return false }
7871
  var name = keyNames[event.keyCode];
7872
  if (name == null || event.altGraphKey) { return false }
 
 
 
7873
  return addModifierNames(name, event, noShift)
7874
  }
7875
 
@@ -8752,6 +8755,7 @@ webpackJsonp([2],{
8752
  clearCaches(cm);
8753
  regChange(cm);
8754
  }, true);
 
8755
  option("lineSeparator", null, function (cm, val) {
8756
  cm.doc.lineSep = val;
8757
  if (!val) { return }
@@ -9158,7 +9162,7 @@ webpackJsonp([2],{
9158
 
9159
  var paste = cm.state.pasteIncoming || origin == "paste";
9160
  var textLines = splitLinesAuto(inserted), multiPaste = null;
9161
- // When pasing N lines into N selections, insert one line per selection
9162
  if (paste && sel.ranges.length > 1) {
9163
  if (lastCopied && lastCopied.text.join("\n") == inserted) {
9164
  if (sel.ranges.length % lastCopied.text.length == 0) {
@@ -10792,7 +10796,7 @@ webpackJsonp([2],{
10792
 
10793
  addLegacyProps(CodeMirror$1);
10794
 
10795
- CodeMirror$1.version = "5.32.0";
10796
 
10797
  return CodeMirror$1;
10798
 
@@ -10801,7 +10805,7 @@ webpackJsonp([2],{
10801
 
10802
  /***/ },
10803
 
10804
- /***/ 561:
10805
  /***/ function(module, exports, __webpack_require__) {
10806
 
10807
  // CodeMirror, copyright (c) by Marijn Haverbeke and others
@@ -10809,7 +10813,7 @@ webpackJsonp([2],{
10809
 
10810
  (function(mod) {
10811
  if (true) // CommonJS
10812
- mod(__webpack_require__(559));
10813
  else if (typeof define == "function" && define.amd) // AMD
10814
  define(["../../lib/codemirror"], mod);
10815
  else // Plain browser env
@@ -10883,9 +10887,9 @@ webpackJsonp([2],{
10883
  return ret("qualifier", "qualifier");
10884
  } else if (/[:;{}\[\]\(\)]/.test(ch)) {
10885
  return ret(null, ch);
10886
- } else if ((ch == "u" && stream.match(/rl(-prefix)?\(/)) ||
10887
- (ch == "d" && stream.match("omain(")) ||
10888
- (ch == "r" && stream.match("egexp("))) {
10889
  stream.backUp(1);
10890
  state.tokenize = tokenParenthesized;
10891
  return ret("property", "word");
@@ -10968,16 +10972,16 @@ webpackJsonp([2],{
10968
  return pushContext(state, stream, "block");
10969
  } else if (type == "}" && state.context.prev) {
10970
  return popContext(state);
10971
- } else if (supportsAtComponent && /@component/.test(type)) {
10972
  return pushContext(state, stream, "atComponentBlock");
10973
- } else if (/^@(-moz-)?document$/.test(type)) {
10974
  return pushContext(state, stream, "documentTypes");
10975
- } else if (/^@(media|supports|(-moz-)?document|import)$/.test(type)) {
10976
  return pushContext(state, stream, "atBlock");
10977
- } else if (/^@(font-face|counter-style)/.test(type)) {
10978
  state.stateArg = type;
10979
  return "restricted_atBlock_before";
10980
- } else if (/^@(-(moz|ms|o|webkit)-)?keyframes$/.test(type)) {
10981
  return "keyframes";
10982
  } else if (type && type.charAt(0) == "@") {
10983
  return pushContext(state, stream, "at");
@@ -11599,7 +11603,7 @@ webpackJsonp([2],{
11599
  },
11600
  "@": function(stream) {
11601
  if (stream.eat("{")) return [null, "interpolation"];
11602
- if (stream.match(/^(charset|document|font-face|import|(-(moz|ms|o|webkit)-)?keyframes|media|namespace|page|supports)\b/, false)) return false;
11603
  stream.eatWhile(/[\w\\\-]/);
11604
  if (stream.match(/^\s*:/, false))
11605
  return ["variable-2", "variable-definition"];
3
  /***/ 0:
4
  /***/ function(module, exports, __webpack_require__) {
5
 
6
+ __webpack_require__(560);
7
+ __webpack_require__(562);
8
+ module.exports = __webpack_require__(564);
9
 
10
 
11
  /***/ },
12
 
13
+ /***/ 560:
14
  /***/ function(module, exports, __webpack_require__) {
15
 
16
+ /* WEBPACK VAR INJECTION */(function(global) {module.exports = global["WysijaForm"] = __webpack_require__(561);
17
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
18
 
19
  /***/ },
20
 
21
+ /***/ 561:
22
  /***/ function(module, exports) {
23
 
24
  /* eslint-disable func-names */
1121
 
1122
  /***/ },
1123
 
1124
+ /***/ 562:
1125
  /***/ function(module, exports, __webpack_require__) {
1126
 
1127
+ /* WEBPACK VAR INJECTION */(function(global) {module.exports = global["CodeMirror"] = __webpack_require__(563);
1128
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
1129
 
1130
  /***/ },
1131
 
1132
+ /***/ 563:
1133
  /***/ function(module, exports, __webpack_require__) {
1134
 
1135
  // CodeMirror, copyright (c) by Marijn Haverbeke and others
7719
  }
7720
 
7721
  var keyNames = {
7722
+ 3: "Pause", 8: "Backspace", 9: "Tab", 13: "Enter", 16: "Shift", 17: "Ctrl", 18: "Alt",
7723
  19: "Pause", 20: "CapsLock", 27: "Esc", 32: "Space", 33: "PageUp", 34: "PageDown", 35: "End",
7724
  36: "Home", 37: "Left", 38: "Up", 39: "Right", 40: "Down", 44: "PrintScrn", 45: "Insert",
7725
  46: "Delete", 59: ";", 61: "=", 91: "Mod", 92: "Mod", 93: "Mod",
7726
+ 106: "*", 107: "=", 109: "-", 110: ".", 111: "/", 127: "Delete", 145: "ScrollLock",
7727
  173: "-", 186: ";", 187: "=", 188: ",", 189: "-", 190: ".", 191: "/", 192: "`", 219: "[", 220: "\\",
7728
  221: "]", 222: "'", 63232: "Up", 63233: "Down", 63234: "Left", 63235: "Right", 63272: "Delete",
7729
  63273: "Home", 63275: "End", 63276: "PageUp", 63277: "PageDown", 63302: "Insert"
7870
  if (presto && event.keyCode == 34 && event["char"]) { return false }
7871
  var name = keyNames[event.keyCode];
7872
  if (name == null || event.altGraphKey) { return false }
7873
+ // Ctrl-ScrollLock has keyCode 3, same as Ctrl-Pause,
7874
+ // so we'll use event.code when available (Chrome 48+, FF 38+, Safari 10.1+)
7875
+ if (event.keyCode == 3 && event.code) { name = event.code; }
7876
  return addModifierNames(name, event, noShift)
7877
  }
7878
 
8755
  clearCaches(cm);
8756
  regChange(cm);
8757
  }, true);
8758
+
8759
  option("lineSeparator", null, function (cm, val) {
8760
  cm.doc.lineSep = val;
8761
  if (!val) { return }
9162
 
9163
  var paste = cm.state.pasteIncoming || origin == "paste";
9164
  var textLines = splitLinesAuto(inserted), multiPaste = null;
9165
+ // When pasting N lines into N selections, insert one line per selection
9166
  if (paste && sel.ranges.length > 1) {
9167
  if (lastCopied && lastCopied.text.join("\n") == inserted) {
9168
  if (sel.ranges.length % lastCopied.text.length == 0) {
10796
 
10797
  addLegacyProps(CodeMirror$1);
10798
 
10799
+ CodeMirror$1.version = "5.34.0";
10800
 
10801
  return CodeMirror$1;
10802
 
10805
 
10806
  /***/ },
10807
 
10808
+ /***/ 564:
10809
  /***/ function(module, exports, __webpack_require__) {
10810
 
10811
  // CodeMirror, copyright (c) by Marijn Haverbeke and others
10813
 
10814
  (function(mod) {
10815
  if (true) // CommonJS
10816
+ mod(__webpack_require__(562));
10817
  else if (typeof define == "function" && define.amd) // AMD
10818
  define(["../../lib/codemirror"], mod);
10819
  else // Plain browser env
10887
  return ret("qualifier", "qualifier");
10888
  } else if (/[:;{}\[\]\(\)]/.test(ch)) {
10889
  return ret(null, ch);
10890
+ } else if (((ch == "u" || ch == "U") && stream.match(/rl(-prefix)?\(/i)) ||
10891
+ ((ch == "d" || ch == "D") && stream.match("omain(", true, true)) ||
10892
+ ((ch == "r" || ch == "R") && stream.match("egexp(", true, true))) {
10893
  stream.backUp(1);
10894
  state.tokenize = tokenParenthesized;
10895
  return ret("property", "word");
10972
  return pushContext(state, stream, "block");
10973
  } else if (type == "}" && state.context.prev) {
10974
  return popContext(state);
10975
+ } else if (supportsAtComponent && /@component/i.test(type)) {
10976
  return pushContext(state, stream, "atComponentBlock");
10977
+ } else if (/^@(-moz-)?document$/i.test(type)) {
10978
  return pushContext(state, stream, "documentTypes");
10979
+ } else if (/^@(media|supports|(-moz-)?document|import)$/i.test(type)) {
10980
  return pushContext(state, stream, "atBlock");
10981
+ } else if (/^@(font-face|counter-style)/i.test(type)) {
10982
  state.stateArg = type;
10983
  return "restricted_atBlock_before";
10984
+ } else if (/^@(-(moz|ms|o|webkit)-)?keyframes$/i.test(type)) {
10985
  return "keyframes";
10986
  } else if (type && type.charAt(0) == "@") {
10987
  return pushContext(state, stream, "at");
11603
  },
11604
  "@": function(stream) {
11605
  if (stream.eat("{")) return [null, "interpolation"];
11606
+ if (stream.match(/^(charset|document|font-face|import|(-(moz|ms|o|webkit)-)?keyframes|media|namespace|page|supports)\b/i, false)) return false;
11607
  stream.eatWhile(/[\w\\\-]/);
11608
  if (stream.match(/^\s*:/, false))
11609
  return ["variable-2", "variable-definition"];
assets/js/{mailpoet.a55b11ee.js → mailpoet.5afefe4c.js} RENAMED
@@ -3,17 +3,17 @@ webpackJsonp([3],[
3
  /***/ function(module, exports, __webpack_require__) {
4
 
5
  __webpack_require__(276);
6
- __webpack_require__(562);
7
- __webpack_require__(563);
8
- __webpack_require__(564);
9
  __webpack_require__(565);
10
  __webpack_require__(566);
11
  __webpack_require__(567);
12
  __webpack_require__(568);
13
  __webpack_require__(569);
14
  __webpack_require__(570);
15
- __webpack_require__(436);
16
- module.exports = __webpack_require__(571);
 
 
 
17
 
18
 
19
  /***/ },
@@ -23905,7 +23905,7 @@ webpackJsonp([3],[
23905
  /***/ function(module, exports, __webpack_require__) {
23906
 
23907
  var require;/* WEBPACK VAR INJECTION */(function(module) {//! moment.js
23908
- //! version : 2.19.3
23909
  //! authors : Tim Wood, Iskren Chernev, Moment.js contributors
23910
  //! license : MIT
23911
  //! momentjs.com
@@ -24565,7 +24565,7 @@ webpackJsonp([3],[
24565
 
24566
  // any word (or two) characters or numbers including two/three word month in arabic.
24567
  // includes scottish gaelic two word and hyphenated months
24568
- var matchWord = /[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i;
24569
 
24570
 
24571
  var regexes = {};
@@ -25935,7 +25935,7 @@ webpackJsonp([3],[
25935
  // note: all values past the year are optional and will default to the lowest possible value.
25936
  // [year, month, day , hour, minute, second, millisecond]
25937
  function configFromArray (config) {
25938
- var i, date, input = [], currentDate, yearToUse;
25939
 
25940
  if (config._d) {
25941
  return;
@@ -25985,6 +25985,8 @@ webpackJsonp([3],[
25985
  }
25986
 
25987
  config._d = (config._useUTC ? createUTCDate : createDate).apply(null, input);
 
 
25988
  // Apply timezone offset from input. The actual utcOffset can be changed
25989
  // with parseZone.
25990
  if (config._tzm != null) {
@@ -25996,7 +25998,7 @@ webpackJsonp([3],[
25996
  }
25997
 
25998
  // check for mismatching day of week
25999
- if (config._w && typeof config._w.d !== 'undefined' && config._w.d !== config._d.getDay()) {
26000
  getParsingFlags(config).weekdayMismatch = true;
26001
  }
26002
  }
@@ -27204,19 +27206,24 @@ webpackJsonp([3],[
27204
  return this.clone().locale('en').format('ddd MMM DD YYYY HH:mm:ss [GMT]ZZ');
27205
  }
27206
 
27207
- function toISOString() {
27208
  if (!this.isValid()) {
27209
  return null;
27210
  }
27211
- var m = this.clone().utc();
 
27212
  if (m.year() < 0 || m.year() > 9999) {
27213
- return formatMoment(m, 'YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]');
27214
  }
27215
  if (isFunction(Date.prototype.toISOString)) {
27216
  // native implementation is ~50x faster, use it when we can
27217
- return this.toDate().toISOString();
 
 
 
 
27218
  }
27219
- return formatMoment(m, 'YYYY-MM-DD[T]HH:mm:ss.SSS[Z]');
27220
  }
27221
 
27222
  /**
@@ -27572,7 +27579,7 @@ webpackJsonp([3],[
27572
 
27573
  addParseToken(['D', 'DD'], DATE);
27574
  addParseToken('Do', function (input, array) {
27575
- array[DATE] = toInt(input.match(match1to2)[0], 10);
27576
  });
27577
 
27578
  // MOMENTS
@@ -28384,7 +28391,7 @@ webpackJsonp([3],[
28384
  // Side effect imports
28385
 
28386
 
28387
- hooks.version = '2.19.3';
28388
 
28389
  setHookCallback(createLocal);
28390
 
@@ -28416,6 +28423,19 @@ webpackJsonp([3],[
28416
  hooks.calendarFormat = getCalendarFormat;
28417
  hooks.prototype = proto;
28418
 
 
 
 
 
 
 
 
 
 
 
 
 
 
28419
  return hooks;
28420
 
28421
  })));
@@ -28593,92 +28613,94 @@ webpackJsonp([3],[
28593
  "./ms-my": 378,
28594
  "./ms-my.js": 378,
28595
  "./ms.js": 377,
28596
- "./my": 379,
28597
- "./my.js": 379,
28598
- "./nb": 380,
28599
- "./nb.js": 380,
28600
- "./ne": 381,
28601
- "./ne.js": 381,
28602
- "./nl": 382,
28603
- "./nl-be": 383,
28604
- "./nl-be.js": 383,
28605
- "./nl.js": 382,
28606
- "./nn": 384,
28607
- "./nn.js": 384,
28608
- "./pa-in": 385,
28609
- "./pa-in.js": 385,
28610
- "./pl": 386,
28611
- "./pl.js": 386,
28612
- "./pt": 387,
28613
- "./pt-br": 388,
28614
- "./pt-br.js": 388,
28615
- "./pt.js": 387,
28616
- "./ro": 389,
28617
- "./ro.js": 389,
28618
- "./ru": 390,
28619
- "./ru.js": 390,
28620
- "./sd": 391,
28621
- "./sd.js": 391,
28622
- "./se": 392,
28623
- "./se.js": 392,
28624
- "./si": 393,
28625
- "./si.js": 393,
28626
- "./sk": 394,
28627
- "./sk.js": 394,
28628
- "./sl": 395,
28629
- "./sl.js": 395,
28630
- "./sq": 396,
28631
- "./sq.js": 396,
28632
- "./sr": 397,
28633
- "./sr-cyrl": 398,
28634
- "./sr-cyrl.js": 398,
28635
- "./sr.js": 397,
28636
- "./ss": 399,
28637
- "./ss.js": 399,
28638
- "./sv": 400,
28639
- "./sv.js": 400,
28640
- "./sw": 401,
28641
- "./sw.js": 401,
28642
- "./ta": 402,
28643
- "./ta.js": 402,
28644
- "./te": 403,
28645
- "./te.js": 403,
28646
- "./tet": 404,
28647
- "./tet.js": 404,
28648
- "./th": 405,
28649
- "./th.js": 405,
28650
- "./tl-ph": 406,
28651
- "./tl-ph.js": 406,
28652
- "./tlh": 407,
28653
- "./tlh.js": 407,
28654
- "./tr": 408,
28655
- "./tr.js": 408,
28656
- "./tzl": 409,
28657
- "./tzl.js": 409,
28658
- "./tzm": 410,
28659
- "./tzm-latn": 411,
28660
- "./tzm-latn.js": 411,
28661
- "./tzm.js": 410,
28662
- "./uk": 412,
28663
- "./uk.js": 412,
28664
- "./ur": 413,
28665
- "./ur.js": 413,
28666
- "./uz": 414,
28667
- "./uz-latn": 415,
28668
- "./uz-latn.js": 415,
28669
- "./uz.js": 414,
28670
- "./vi": 416,
28671
- "./vi.js": 416,
28672
- "./x-pseudo": 417,
28673
- "./x-pseudo.js": 417,
28674
- "./yo": 418,
28675
- "./yo.js": 418,
28676
- "./zh-cn": 419,
28677
- "./zh-cn.js": 419,
28678
- "./zh-hk": 420,
28679
- "./zh-hk.js": 420,
28680
- "./zh-tw": 421,
28681
- "./zh-tw.js": 421
 
 
28682
  };
28683
  function webpackContext(req) {
28684
  return __webpack_require__(webpackContextResolve(req));
@@ -28746,6 +28768,7 @@ webpackJsonp([3],[
28746
  future : 'oor %s',
28747
  past : '%s gelede',
28748
  s : '\'n paar sekondes',
 
28749
  m : '\'n minuut',
28750
  mm : '%d minute',
28751
  h : '\'n uur',
@@ -28835,18 +28858,18 @@ webpackJsonp([3],[
28835
  };
28836
  };
28837
  var months = [
28838
- 'كانون الثاني يناير',
28839
- 'شباط فبراير',
28840
- 'آذار مارس',
28841
- 'نيسان أبريل',
28842
- 'أيار مايو',
28843
- 'حزيران يونيو',
28844
- 'تموز يوليو',
28845
- 'آب أغسطس',
28846
- 'أيلول سبتمبر',
28847
- 'تشرين الأول أكتوبر',
28848
- 'تشرين الثاني نوفمبر',
28849
- 'كانون الأول ديسمبر'
28850
  ];
28851
 
28852
  var ar = moment.defineLocale('ar', {
@@ -28887,6 +28910,7 @@ webpackJsonp([3],[
28887
  future : 'بعد %s',
28888
  past : 'منذ %s',
28889
  s : pluralize('s'),
 
28890
  m : pluralize('m'),
28891
  mm : pluralize('m'),
28892
  h : pluralize('h'),
@@ -28961,6 +28985,7 @@ webpackJsonp([3],[
28961
  future : 'في %s',
28962
  past : 'منذ %s',
28963
  s : 'ثوان',
 
28964
  m : 'دقيقة',
28965
  mm : '%d دقائق',
28966
  h : 'ساعة',
@@ -29025,6 +29050,7 @@ webpackJsonp([3],[
29025
  future : 'في %s',
29026
  past : 'منذ %s',
29027
  s : 'ثوان',
 
29028
  m : 'دقيقة',
29029
  mm : '%d دقائق',
29030
  h : 'ساعة',
@@ -29148,6 +29174,7 @@ webpackJsonp([3],[
29148
  future : 'بعد %s',
29149
  past : 'منذ %s',
29150
  s : pluralize('s'),
 
29151
  m : pluralize('m'),
29152
  mm : pluralize('m'),
29153
  h : pluralize('h'),
@@ -29221,6 +29248,7 @@ webpackJsonp([3],[
29221
  future : 'في %s',
29222
  past : 'منذ %s',
29223
  s : 'ثوان',
 
29224
  m : 'دقيقة',
29225
  mm : '%d دقائق',
29226
  h : 'ساعة',
@@ -29321,6 +29349,7 @@ webpackJsonp([3],[
29321
  future : 'في %s',
29322
  past : 'منذ %s',
29323
  s : 'ثوان',
 
29324
  m : 'دقيقة',
29325
  mm : '%d دقائق',
29326
  h : 'ساعة',
@@ -29395,6 +29424,7 @@ webpackJsonp([3],[
29395
  future: 'في %s',
29396
  past: 'منذ %s',
29397
  s: 'ثوان',
 
29398
  m: 'دقيقة',
29399
  mm: '%d دقائق',
29400
  h: 'ساعة',
@@ -29480,6 +29510,7 @@ webpackJsonp([3],[
29480
  future : '%s sonra',
29481
  past : '%s əvvəl',
29482
  s : 'birneçə saniyyə',
 
29483
  m : 'bir dəqiqə',
29484
  mm : '%d dəqiqə',
29485
  h : 'bir saat',
@@ -29550,6 +29581,7 @@ webpackJsonp([3],[
29550
  }
29551
  function relativeTimeWithPlural(number, withoutSuffix, key) {
29552
  var format = {
 
29553
  'mm': withoutSuffix ? 'хвіліна_хвіліны_хвілін' : 'хвіліну_хвіліны_хвілін',
29554
  'hh': withoutSuffix ? 'гадзіна_гадзіны_гадзін' : 'гадзіну_гадзіны_гадзін',
29555
  'dd': 'дзень_дні_дзён',
@@ -29719,6 +29751,7 @@ webpackJsonp([3],[
29719
  future : 'след %s',
29720
  past : 'преди %s',
29721
  s : 'няколко секунди',
 
29722
  m : 'минута',
29723
  mm : '%d минути',
29724
  h : 'час',
@@ -29803,6 +29836,7 @@ webpackJsonp([3],[
29803
  future : '%s kɔnɔ',
29804
  past : 'a bɛ %s bɔ',
29805
  s : 'sanga dama dama',
 
29806
  m : 'miniti kelen',
29807
  mm : 'miniti %d',
29808
  h : 'lɛrɛ kelen',
@@ -29891,6 +29925,7 @@ webpackJsonp([3],[
29891
  future : '%s পরে',
29892
  past : '%s আগে',
29893
  s : 'কয়েক সেকেন্ড',
 
29894
  m : 'এক মিনিট',
29895
  mm : '%d মিনিট',
29896
  h : 'এক ঘন্টা',
@@ -30015,6 +30050,7 @@ webpackJsonp([3],[
30015
  future : '%s ལ་',
30016
  past : '%s སྔན་ལ',
30017
  s : 'ལམ་སང',
 
30018
  m : 'སྐར་མ་གཅིག',
30019
  mm : '%d སྐར་མ',
30020
  h : 'ཆུ་ཚོད་གཅིག',
@@ -30159,6 +30195,7 @@ webpackJsonp([3],[
30159
  future : 'a-benn %s',
30160
  past : '%s \'zo',
30161
  s : 'un nebeud segondennoù',
 
30162
  m : 'ur vunutenn',
30163
  mm : relativeTimeWithMutation,
30164
  h : 'un eur',
@@ -30205,6 +30242,15 @@ webpackJsonp([3],[
30205
  function translate(number, withoutSuffix, key) {
30206
  var result = number + ' ';
30207
  switch (key) {
 
 
 
 
 
 
 
 
 
30208
  case 'm':
30209
  return withoutSuffix ? 'jedna minuta' : 'jedne minute';
30210
  case 'mm':
@@ -30310,6 +30356,7 @@ webpackJsonp([3],[
30310
  future : 'za %s',
30311
  past : 'prije %s',
30312
  s : 'par sekundi',
 
30313
  m : translate,
30314
  mm : translate,
30315
  h : translate,
@@ -30394,6 +30441,7 @@ webpackJsonp([3],[
30394
  future : 'd\'aquí %s',
30395
  past : 'fa %s',
30396
  s : 'uns segons',
 
30397
  m : 'un minut',
30398
  mm : '%d minuts',
30399
  h : 'una hora',
@@ -30452,6 +30500,13 @@ webpackJsonp([3],[
30452
  switch (key) {
30453
  case 's': // a few seconds / in a few seconds / a few seconds ago
30454
  return (withoutSuffix || isFuture) ? 'pár sekund' : 'pár sekundami';
 
 
 
 
 
 
 
30455
  case 'm': // a minute / in a minute / a minute ago
30456
  return withoutSuffix ? 'minuta' : (isFuture ? 'minutu' : 'minutou');
30457
  case 'mm': // 9 minutes / in 9 minutes / 9 minutes ago
@@ -30580,6 +30635,7 @@ webpackJsonp([3],[
30580
  future : 'za %s',
30581
  past : 'před %s',
30582
  s : translate,
 
30583
  m : translate,
30584
  mm : translate,
30585
  h : translate,
@@ -30648,6 +30704,7 @@ webpackJsonp([3],[
30648
  },
30649
  past : '%s каялла',
30650
  s : 'пӗр-ик ҫеккунт',
 
30651
  m : 'пӗр минут',
30652
  mm : '%d минут',
30653
  h : 'пӗр сехет',
@@ -30716,6 +30773,7 @@ webpackJsonp([3],[
30716
  future: 'mewn %s',
30717
  past: '%s yn ôl',
30718
  s: 'ychydig eiliadau',
 
30719
  m: 'munud',
30720
  mm: '%d munud',
30721
  h: 'awr',
@@ -30799,6 +30857,7 @@ webpackJsonp([3],[
30799
  future : 'om %s',
30800
  past : '%s siden',
30801
  s : 'få sekunder',
 
30802
  m : 'et minut',
30803
  mm : '%d minutter',
30804
  h : 'en time',
@@ -30882,6 +30941,7 @@ webpackJsonp([3],[
30882
  future : 'in %s',
30883
  past : 'vor %s',
30884
  s : 'ein paar Sekunden',
 
30885
  m : processRelativeTime,
30886
  mm : '%d Minuten',
30887
  h : processRelativeTime,
@@ -30966,6 +31026,7 @@ webpackJsonp([3],[
30966
  future : 'in %s',
30967
  past : 'vor %s',
30968
  s : 'ein paar Sekunden',
 
30969
  m : processRelativeTime,
30970
  mm : '%d Minuten',
30971
  h : processRelativeTime,
@@ -31030,12 +31091,12 @@ webpackJsonp([3],[
31030
  weekdaysMin : 'So_Mo_Di_Mi_Do_Fr_Sa'.split('_'),
31031
  weekdaysParseExact : true,
31032
  longDateFormat : {
31033
- LT: 'HH.mm',
31034
- LTS: 'HH.mm.ss',
31035
  L : 'DD.MM.YYYY',
31036
  LL : 'D. MMMM YYYY',
31037
- LLL : 'D. MMMM YYYY HH.mm',
31038
- LLLL : 'dddd, D. MMMM YYYY HH.mm'
31039
  },
31040
  calendar : {
31041
  sameDay: '[heute um] LT [Uhr]',
@@ -31049,6 +31110,7 @@ webpackJsonp([3],[
31049
  future : 'in %s',
31050
  past : 'vor %s',
31051
  s : 'ein paar Sekunden',
 
31052
  m : processRelativeTime,
31053
  mm : '%d Minuten',
31054
  h : processRelativeTime,
@@ -31150,6 +31212,7 @@ webpackJsonp([3],[
31150
  future : 'ތެރޭގައި %s',
31151
  past : 'ކުރިން %s',
31152
  s : 'ސިކުންތުކޮޅެއް',
 
31153
  m : 'މިނިޓެއް',
31154
  mm : 'މިނިޓު %d',
31155
  h : 'ގަޑިއިރެއް',
@@ -31259,6 +31322,7 @@ webpackJsonp([3],[
31259
  future : 'σε %s',
31260
  past : '%s πριν',
31261
  s : 'λίγα δευτερόλεπτα',
 
31262
  m : 'ένα λεπτό',
31263
  mm : '%d λεπτά',
31264
  h : 'μία ώρα',
@@ -31324,6 +31388,7 @@ webpackJsonp([3],[
31324
  future : 'in %s',
31325
  past : '%s ago',
31326
  s : 'a few seconds',
 
31327
  m : 'a minute',
31328
  mm : '%d minutes',
31329
  h : 'an hour',
@@ -31396,6 +31461,7 @@ webpackJsonp([3],[
31396
  future : 'in %s',
31397
  past : '%s ago',
31398
  s : 'a few seconds',
 
31399
  m : 'a minute',
31400
  mm : '%d minutes',
31401
  h : 'an hour',
@@ -31464,6 +31530,7 @@ webpackJsonp([3],[
31464
  future : 'in %s',
31465
  past : '%s ago',
31466
  s : 'a few seconds',
 
31467
  m : 'a minute',
31468
  mm : '%d minutes',
31469
  h : 'an hour',
@@ -31536,6 +31603,7 @@ webpackJsonp([3],[
31536
  future : 'in %s',
31537
  past : '%s ago',
31538
  s : 'a few seconds',
 
31539
  m : 'a minute',
31540
  mm : '%d minutes',
31541
  h : 'an hour',
@@ -31608,6 +31676,7 @@ webpackJsonp([3],[
31608
  future : 'in %s',
31609
  past : '%s ago',
31610
  s : 'a few seconds',
 
31611
  m : 'a minute',
31612
  mm : '%d minutes',
31613
  h : 'an hour',
@@ -31693,6 +31762,7 @@ webpackJsonp([3],[
31693
  future : 'post %s',
31694
  past : 'antaŭ %s',
31695
  s : 'sekundoj',
 
31696
  m : 'minuto',
31697
  mm : '%d minutoj',
31698
  h : 'horo',
@@ -31790,6 +31860,7 @@ webpackJsonp([3],[
31790
  future : 'en %s',
31791
  past : 'hace %s',
31792
  s : 'unos segundos',
 
31793
  m : 'un minuto',
31794
  mm : '%d minutos',
31795
  h : 'una hora',
@@ -31886,6 +31957,7 @@ webpackJsonp([3],[
31886
  future : 'en %s',
31887
  past : 'hace %s',
31888
  s : 'unos segundos',
 
31889
  m : 'un minuto',
31890
  mm : '%d minutos',
31891
  h : 'una hora',
@@ -31945,12 +32017,12 @@ webpackJsonp([3],[
31945
  weekdaysMin : 'do_lu_ma_mi_ju_vi_sá'.split('_'),
31946
  weekdaysParseExact : true,
31947
  longDateFormat : {
31948
- LT : 'H:mm',
31949
- LTS : 'H:mm:ss',
31950
  L : 'MM/DD/YYYY',
31951
  LL : 'MMMM [de] D [de] YYYY',
31952
- LLL : 'MMMM [de] D [de] YYYY H:mm',
31953
- LLLL : 'dddd, MMMM [de] D [de] YYYY H:mm'
31954
  },
31955
  calendar : {
31956
  sameDay : function () {
@@ -31974,6 +32046,7 @@ webpackJsonp([3],[
31974
  future : 'en %s',
31975
  past : 'hace %s',
31976
  s : 'unos segundos',
 
31977
  m : 'un minuto',
31978
  mm : '%d minutos',
31979
  h : 'una hora',
@@ -32017,6 +32090,7 @@ webpackJsonp([3],[
32017
  function processRelativeTime(number, withoutSuffix, key, isFuture) {
32018
  var format = {
32019
  's' : ['mõne sekundi', 'mõni sekund', 'paar sekundit'],
 
32020
  'm' : ['ühe minuti', 'üks minut'],
32021
  'mm': [number + ' minuti', number + ' minutit'],
32022
  'h' : ['ühe tunni', 'tund aega', 'üks tund'],
@@ -32059,6 +32133,7 @@ webpackJsonp([3],[
32059
  future : '%s pärast',
32060
  past : '%s tagasi',
32061
  s : processRelativeTime,
 
32062
  m : processRelativeTime,
32063
  mm : processRelativeTime,
32064
  h : processRelativeTime,
@@ -32130,6 +32205,7 @@ webpackJsonp([3],[
32130
  future : '%s barru',
32131
  past : 'duela %s',
32132
  s : 'segundo batzuk',
 
32133
  m : 'minutu bat',
32134
  mm : '%d minutu',
32135
  h : 'ordu bat',
@@ -32232,6 +32308,7 @@ webpackJsonp([3],[
32232
  future : 'در %s',
32233
  past : '%s پیش',
32234
  s : 'چند ثانیه',
 
32235
  m : 'یک دقیقه',
32236
  mm : '%d دقیقه',
32237
  h : 'یک ساعت',
@@ -32291,6 +32368,8 @@ webpackJsonp([3],[
32291
  switch (key) {
32292
  case 's':
32293
  return isFuture ? 'muutaman sekunnin' : 'muutama sekunti';
 
 
32294
  case 'm':
32295
  return isFuture ? 'minuutin' : 'minuutti';
32296
  case 'mm':
@@ -32354,6 +32433,7 @@ webpackJsonp([3],[
32354
  future : '%s päästä',
32355
  past : '%s sitten',
32356
  s : translate,
 
32357
  m : translate,
32358
  mm : translate,
32359
  h : translate,
@@ -32419,6 +32499,7 @@ webpackJsonp([3],[
32419
  future : 'um %s',
32420
  past : '%s síðani',
32421
  s : 'fá sekund',
 
32422
  m : 'ein minutt',
32423
  mm : '%d minuttir',
32424
  h : 'ein tími',
@@ -32464,7 +32545,7 @@ webpackJsonp([3],[
32464
  monthsParseExact : true,
32465
  weekdays : 'dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi'.split('_'),
32466
  weekdaysShort : 'dim._lun._mar._mer._jeu._ven._sam.'.split('_'),
32467
- weekdaysMin : 'Di_Lu_Ma_Me_Je_Ve_Sa'.split('_'),
32468
  weekdaysParseExact : true,
32469
  longDateFormat : {
32470
  LT : 'HH:mm',
@@ -32486,6 +32567,7 @@ webpackJsonp([3],[
32486
  future : 'dans %s',
32487
  past : 'il y a %s',
32488
  s : 'quelques secondes',
 
32489
  m : 'une minute',
32490
  mm : '%d minutes',
32491
  h : 'une heure',
@@ -32552,7 +32634,7 @@ webpackJsonp([3],[
32552
  monthsParseExact : true,
32553
  weekdays : 'dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi'.split('_'),
32554
  weekdaysShort : 'dim._lun._mar._mer._jeu._ven._sam.'.split('_'),
32555
- weekdaysMin : 'Di_Lu_Ma_Me_Je_Ve_Sa'.split('_'),
32556
  weekdaysParseExact : true,
32557
  longDateFormat : {
32558
  LT : 'HH:mm',
@@ -32574,6 +32656,7 @@ webpackJsonp([3],[
32574
  future : 'dans %s',
32575
  past : 'il y a %s',
32576
  s : 'quelques secondes',
 
32577
  m : 'une minute',
32578
  mm : '%d minutes',
32579
  h : 'une heure',
@@ -32631,7 +32714,7 @@ webpackJsonp([3],[
32631
  monthsParseExact : true,
32632
  weekdays : 'dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi'.split('_'),
32633
  weekdaysShort : 'dim._lun._mar._mer._jeu._ven._sam.'.split('_'),
32634
- weekdaysMin : 'Di_Lu_Ma_Me_Je_Ve_Sa'.split('_'),
32635
  weekdaysParseExact : true,
32636
  longDateFormat : {
32637
  LT : 'HH:mm',
@@ -32653,6 +32736,7 @@ webpackJsonp([3],[
32653
  future : 'dans %s',
32654
  past : 'il y a %s',
32655
  s : 'quelques secondes',
 
32656
  m : 'une minute',
32657
  mm : '%d minutes',
32658
  h : 'une heure',
@@ -32747,6 +32831,7 @@ webpackJsonp([3],[
32747
  future : 'oer %s',
32748
  past : '%s lyn',
32749
  s : 'in pear sekonden',
 
32750
  m : 'ien minút',
32751
  mm : '%d minuten',
32752
  h : 'ien oere',
@@ -32827,6 +32912,7 @@ webpackJsonp([3],[
32827
  future : 'ann an %s',
32828
  past : 'bho chionn %s',
32829
  s : 'beagan diogan',
 
32830
  m : 'mionaid',
32831
  mm : '%d mionaidean',
32832
  h : 'uair',
@@ -32912,6 +32998,7 @@ webpackJsonp([3],[
32912
  },
32913
  past : 'hai %s',
32914
  s : 'uns segundos',
 
32915
  m : 'un minuto',
32916
  mm : '%d minutos',
32917
  h : 'unha hora',
@@ -32954,6 +33041,7 @@ webpackJsonp([3],[
32954
  function processRelativeTime(number, withoutSuffix, key, isFuture) {
32955
  var format = {
32956
  's': ['thodde secondanim', 'thodde second'],
 
32957
  'm': ['eka mintan', 'ek minute'],
32958
  'mm': [number + ' mintanim', number + ' mintam'],
32959
  'h': ['eka horan', 'ek hor'],
@@ -32997,6 +33085,7 @@ webpackJsonp([3],[
32997
  future : '%s',
32998
  past : '%s adim',
32999
  s : processRelativeTime,
 
33000
  m : processRelativeTime,
33001
  mm : processRelativeTime,
33002
  h : processRelativeTime,
@@ -33130,6 +33219,7 @@ webpackJsonp([3],[
33130
  future: '%s મા',
33131
  past: '%s પેહલા',
33132
  s: 'અમુક પળો',
 
33133
  m: 'એક મિનિટ',
33134
  mm: '%d મિનિટ',
33135
  h: 'એક કલાક',
@@ -33239,6 +33329,7 @@ webpackJsonp([3],[
33239
  future : 'בעוד %s',
33240
  past : 'לפני %s',
33241
  s : 'מספר שניות',
 
33242
  m : 'דקה',
33243
  mm : '%d דקות',
33244
  h : 'שעה',
@@ -33363,6 +33454,7 @@ webpackJsonp([3],[
33363
  future : '%s में',
33364
  past : '%s पहले',
33365
  s : 'कुछ ही क्षण',
 
33366
  m : 'एक मिनट',
33367
  mm : '%d मिनट',
33368
  h : 'एक घंटा',
@@ -33443,6 +33535,15 @@ webpackJsonp([3],[
33443
  function translate(number, withoutSuffix, key) {
33444
  var result = number + ' ';
33445
  switch (key) {
 
 
 
 
 
 
 
 
 
33446
  case 'm':
33447
  return withoutSuffix ? 'jedna minuta' : 'jedne minute';
33448
  case 'mm':
@@ -33551,6 +33652,7 @@ webpackJsonp([3],[
33551
  future : 'za %s',
33552
  past : 'prije %s',
33553
  s : 'par sekundi',
 
33554
  m : translate,
33555
  mm : translate,
33556
  h : translate,
@@ -33596,6 +33698,8 @@ webpackJsonp([3],[
33596
  switch (key) {
33597
  case 's':
33598
  return (isFuture || withoutSuffix) ? 'néhány másodperc' : 'néhány másodperce';
 
 
33599
  case 'm':
33600
  return 'egy' + (isFuture || withoutSuffix ? ' perc' : ' perce');
33601
  case 'mm':
@@ -33664,6 +33768,7 @@ webpackJsonp([3],[
33664
  future : '%s múlva',
33665
  past : '%s',
33666
  s : translate,
 
33667
  m : translate,
33668
  mm : translate,
33669
  h : translate,
@@ -33736,6 +33841,7 @@ webpackJsonp([3],[
33736
  future : '%s հետո',
33737
  past : '%s առաջ',
33738
  s : 'մի քանի վայրկյան',
 
33739
  m : 'րոպե',
33740
  mm : '%d րոպե',
33741
  h : 'ժամ',
@@ -33854,6 +33960,7 @@ webpackJsonp([3],[
33854
  future : 'dalam %s',
33855
  past : '%s yang lalu',
33856
  s : 'beberapa detik',
 
33857
  m : 'semenit',
33858
  mm : '%d menit',
33859
  h : 'sejam',
@@ -33904,6 +34011,11 @@ webpackJsonp([3],[
33904
  switch (key) {
33905
  case 's':
33906
  return withoutSuffix || isFuture ? 'nokkrar sekúndur' : 'nokkrum sekúndum';
 
 
 
 
 
33907
  case 'm':
33908
  return withoutSuffix ? 'mínúta' : 'mínútu';
33909
  case 'mm':
@@ -33984,6 +34096,7 @@ webpackJsonp([3],[
33984
  future : 'eftir %s',
33985
  past : 'fyrir %s síðan',
33986
  s : translate,
 
33987
  m : translate,
33988
  mm : translate,
33989
  h : 'klukkustund',
@@ -34036,7 +34149,7 @@ webpackJsonp([3],[
34036
  L : 'DD/MM/YYYY',
34037
  LL : 'D MMMM YYYY',
34038
  LLL : 'D MMMM YYYY HH:mm',
34039
- LLLL : 'dddd, D MMMM YYYY HH:mm'
34040
  },
34041
  calendar : {
34042
  sameDay: '[Oggi alle] LT',
@@ -34059,6 +34172,7 @@ webpackJsonp([3],[
34059
  },
34060
  past : '%s fa',
34061
  s : 'alcuni secondi',
 
34062
  m : 'un minuto',
34063
  mm : '%d minuti',
34064
  h : 'un\'ora',
@@ -34150,6 +34264,7 @@ webpackJsonp([3],[
34150
  future : '%s後',
34151
  past : '%s前',
34152
  s : '数秒',
 
34153
  m : '1分',
34154
  mm : '%d分',
34155
  h : '1時間',
@@ -34234,6 +34349,7 @@ webpackJsonp([3],[
34234
  future : 'wonten ing %s',
34235
  past : '%s ingkang kepengker',
34236
  s : 'sawetawis detik',
 
34237
  m : 'setunggal menit',
34238
  mm : '%d menit',
34239
  h : 'setunggal jam',
@@ -34315,6 +34431,7 @@ webpackJsonp([3],[
34315
  }
34316
  },
34317
  s : 'რამდენიმე წამი',
 
34318
  m : 'წუთი',
34319
  mm : '%d წუთი',
34320
  h : 'საათი',
@@ -34414,6 +34531,7 @@ webpackJsonp([3],[
34414
  future : '%s ішінде',
34415
  past : '%s бұрын',
34416
  s : 'бірнеше секунд',
 
34417
  m : 'бір минут',
34418
  mm : '%d минут',
34419
  h : 'бір сағат',
@@ -34483,6 +34601,7 @@ webpackJsonp([3],[
34483
  future: '%sទៀត',
34484
  past: '%sមុន',
34485
  s: 'ប៉ុន្មានវិនាទី',
 
34486
  m: 'មួយនាទី',
34487
  mm: '%d នាទី',
34488
  h: 'មួយម៉ោង',
@@ -34572,6 +34691,7 @@ webpackJsonp([3],[
34572
  future : '%s ನಂತರ',
34573
  past : '%s ಹಿಂದೆ',
34574
  s : 'ಕೆಲವು ಕ್ಷಣಗಳು',
 
34575
  m : 'ಒಂದು ನಿಮಿಷ',
34576
  mm : '%d ನಿಮಿಷ',
34577
  h : 'ಒಂದು ಗಂಟೆ',
@@ -34789,6 +34909,7 @@ webpackJsonp([3],[
34789
  future : '%s ичинде',
34790
  past : '%s мурун',
34791
  s : 'бирнече секунд',
 
34792
  m : 'бир мүнөт',
34793
  mm : '%d мүнөт',
34794
  h : 'бир саат',
@@ -34935,6 +35056,7 @@ webpackJsonp([3],[
34935
  future : processFutureTime,
34936
  past : processPastTime,
34937
  s : 'e puer Sekonnen',
 
34938
  m : processRelativeTime,
34939
  mm : '%d Minutten',
34940
  h : processRelativeTime,
@@ -35012,6 +35134,7 @@ webpackJsonp([3],[
35012
  future : 'ອີກ %s',
35013
  past : '%sຜ່ານມາ',
35014
  s : 'ບໍ່ເທົ່າໃດວິນາທີ',
 
35015
  m : '1 ນາທີ',
35016
  mm : '%d ນາທີ',
35017
  h : '1 ຊົ່ວໂມງ',
@@ -35050,6 +35173,7 @@ webpackJsonp([3],[
35050
 
35051
 
35052
  var units = {
 
35053
  'm' : 'minutė_minutės_minutę',
35054
  'mm': 'minutės_minučių_minutes',
35055
  'h' : 'valanda_valandos_valandą',
@@ -35130,6 +35254,7 @@ webpackJsonp([3],[
35130
  future : 'po %s',
35131
  past : 'prieš %s',
35132
  s : translateSeconds,
 
35133
  m : translateSingular,
35134
  mm : translate,
35135
  h : translateSingular,
@@ -35173,6 +35298,7 @@ webpackJsonp([3],[
35173
 
35174
 
35175
  var units = {
 
35176
  'm': 'minūtes_minūtēm_minūte_minūtes'.split('_'),
35177
  'mm': 'minūtes_minūtēm_minūte_minūtes'.split('_'),
35178
  'h': 'stundas_stundām_stunda_stundas'.split('_'),
@@ -35234,6 +35360,7 @@ webpackJsonp([3],[
35234
  future : 'pēc %s',
35235
  past : 'pirms %s',
35236
  s : relativeSeconds,
 
35237
  m : relativeTimeWithSingular,
35238
  mm : relativeTimeWithPlural,
35239
  h : relativeTimeWithSingular,
@@ -35275,6 +35402,7 @@ webpackJsonp([3],[
35275
 
35276
  var translator = {
35277
  words: { //Different grammatical cases
 
35278
  m: ['jedan minut', 'jednog minuta'],
35279
  mm: ['minut', 'minuta', 'minuta'],
35280
  h: ['jedan sat', 'jednog sata'],
@@ -35350,6 +35478,7 @@ webpackJsonp([3],[
35350
  future : 'za %s',
35351
  past : 'prije %s',
35352
  s : 'nekoliko sekundi',
 
35353
  m : translator.translate,
35354
  mm : translator.translate,
35355
  h : translator.translate,
@@ -35419,6 +35548,7 @@ webpackJsonp([3],[
35419
  future: 'i roto i %s',
35420
  past: '%s i mua',
35421
  s: 'te hēkona ruarua',
 
35422
  m: 'he meneti',
35423
  mm: '%d meneti',
35424
  h: 'te haora',
@@ -35496,6 +35626,7 @@ webpackJsonp([3],[
35496
  future : 'после %s',
35497
  past : 'пред %s',
35498
  s : 'неколку секунди',
 
35499
  m : 'минута',
35500
  mm : '%d минути',
35501
  h : 'час',
@@ -35580,6 +35711,7 @@ webpackJsonp([3],[
35580
  future : '%s കഴിഞ്ഞ്',
35581
  past : '%s മുൻപ്',
35582
  s : 'അൽപ നിമിഷങ്ങൾ',
 
35583
  m : 'ഒരു മിനിറ്റ്',
35584
  mm : '%d മിനിറ്റ്',
35585
  h : 'ഒരു മണിക്കൂർ',
@@ -35671,6 +35803,7 @@ webpackJsonp([3],[
35671
  if (withoutSuffix) {
35672
  switch (string) {
35673
  case 's': output = 'काही सेकंद'; break;
 
35674
  case 'm': output = 'एक मिनिट'; break;
35675
  case 'mm': output = '%d मिनिटे'; break;
35676
  case 'h': output = 'एक तास'; break;
@@ -35686,6 +35819,7 @@ webpackJsonp([3],[
35686
  else {
35687
  switch (string) {
35688
  case 's': output = 'काही सेकंदां'; break;
 
35689
  case 'm': output = 'एका मिनिटा'; break;
35690
  case 'mm': output = '%d मिनिटां'; break;
35691
  case 'h': output = 'एका तासा'; break;
@@ -35728,6 +35862,7 @@ webpackJsonp([3],[
35728
  future: '%sमध्ये',
35729
  past: '%sपूर्वी',
35730
  s: relativeTimeMr,
 
35731
  m: relativeTimeMr,
35732
  mm: relativeTimeMr,
35733
  h: relativeTimeMr,
@@ -35853,6 +35988,7 @@ webpackJsonp([3],[
35853
  future : 'dalam %s',
35854
  past : '%s yang lepas',
35855
  s : 'beberapa saat',
 
35856
  m : 'seminit',
35857
  mm : '%d minit',
35858
  h : 'sejam',
@@ -35941,6 +36077,7 @@ webpackJsonp([3],[
35941
  future : 'dalam %s',
35942
  past : '%s yang lepas',
35943
  s : 'beberapa saat',
 
35944
  m : 'seminit',
35945
  mm : '%d minit',
35946
  h : 'sejam',
@@ -35965,6 +36102,72 @@ webpackJsonp([3],[
35965
 
35966
  /***/ },
35967
  /* 379 */
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
35968
  /***/ function(module, exports, __webpack_require__) {
35969
 
35970
  //! moment.js locale configuration
@@ -36032,6 +36235,7 @@ webpackJsonp([3],[
36032
  future: 'လာမည့် %s မှာ',
36033
  past: 'လွန်ခဲ့သော %s က',
36034
  s: 'စက္ကန်.အနည်းငယ်',
 
36035
  m: 'တစ်မိနစ်',
36036
  mm: '%d မိနစ်',
36037
  h: 'တစ်နာရီ',
@@ -36065,7 +36269,7 @@ webpackJsonp([3],[
36065
 
36066
 
36067
  /***/ },
36068
- /* 380 */
36069
  /***/ function(module, exports, __webpack_require__) {
36070
 
36071
  //! moment.js locale configuration
@@ -36108,6 +36312,7 @@ webpackJsonp([3],[
36108
  future : 'om %s',
36109
  past : '%s siden',
36110
  s : 'noen sekunder',
 
36111
  m : 'ett minutt',
36112
  mm : '%d minutter',
36113
  h : 'en time',
@@ -36133,7 +36338,7 @@ webpackJsonp([3],[
36133
 
36134
 
36135
  /***/ },
36136
- /* 381 */
36137
  /***/ function(module, exports, __webpack_require__) {
36138
 
36139
  //! moment.js locale configuration
@@ -36238,6 +36443,7 @@ webpackJsonp([3],[
36238
  future : '%sमा',
36239
  past : '%s अगाडि',
36240
  s : 'केही क्षण',
 
36241
  m : 'एक मिनेट',
36242
  mm : '%d मिनेट',
36243
  h : 'एक घण्टा',
@@ -36261,7 +36467,7 @@ webpackJsonp([3],[
36261
 
36262
 
36263
  /***/ },
36264
- /* 382 */
36265
  /***/ function(module, exports, __webpack_require__) {
36266
 
36267
  //! moment.js locale configuration
@@ -36327,6 +36533,7 @@ webpackJsonp([3],[
36327
  future : 'over %s',
36328
  past : '%s geleden',
36329
  s : 'een paar seconden',
 
36330
  m : 'één minuut',
36331
  mm : '%d minuten',
36332
  h : 'één uur',
@@ -36354,7 +36561,7 @@ webpackJsonp([3],[
36354
 
36355
 
36356
  /***/ },
36357
- /* 383 */
36358
  /***/ function(module, exports, __webpack_require__) {
36359
 
36360
  //! moment.js locale configuration
@@ -36420,6 +36627,7 @@ webpackJsonp([3],[
36420
  future : 'over %s',
36421
  past : '%s geleden',
36422
  s : 'een paar seconden',
 
36423
  m : 'één minuut',
36424
  mm : '%d minuten',
36425
  h : 'één uur',
@@ -36447,7 +36655,7 @@ webpackJsonp([3],[
36447
 
36448
 
36449
  /***/ },
36450
- /* 384 */
36451
  /***/ function(module, exports, __webpack_require__) {
36452
 
36453
  //! moment.js locale configuration
@@ -36487,6 +36695,7 @@ webpackJsonp([3],[
36487
  future : 'om %s',
36488
  past : '%s sidan',
36489
  s : 'nokre sekund',
 
36490
  m : 'eit minutt',
36491
  mm : '%d minutt',
36492
  h : 'ein time',
@@ -36512,7 +36721,7 @@ webpackJsonp([3],[
36512
 
36513
 
36514
  /***/ },
36515
- /* 385 */
36516
  /***/ function(module, exports, __webpack_require__) {
36517
 
36518
  //! moment.js locale configuration
@@ -36578,6 +36787,7 @@ webpackJsonp([3],[
36578
  future : '%s ਵਿੱਚ',
36579
  past : '%s ਪਿਛਲੇ',
36580
  s : 'ਕੁਝ ਸਕਿੰਟ',
 
36581
  m : 'ਇਕ ਮਿੰਟ',
36582
  mm : '%d ਮਿੰਟ',
36583
  h : 'ਇੱਕ ਘੰਟਾ',
@@ -36641,7 +36851,7 @@ webpackJsonp([3],[
36641
 
36642
 
36643
  /***/ },
36644
- /* 386 */
36645
  /***/ function(module, exports, __webpack_require__) {
36646
 
36647
  //! moment.js locale configuration
@@ -36663,6 +36873,8 @@ webpackJsonp([3],[
36663
  function translate(number, withoutSuffix, key) {
36664
  var result = number + ' ';
36665
  switch (key) {
 
 
36666
  case 'm':
36667
  return withoutSuffix ? 'minuta' : 'minutę';
36668
  case 'mm':
@@ -36745,6 +36957,7 @@ webpackJsonp([3],[
36745
  future : 'za %s',
36746
  past : '%s temu',
36747
  s : 'kilka sekund',
 
36748
  m : translate,
36749
  mm : translate,
36750
  h : translate,
@@ -36770,7 +36983,7 @@ webpackJsonp([3],[
36770
 
36771
 
36772
  /***/ },
36773
- /* 387 */
36774
  /***/ function(module, exports, __webpack_require__) {
36775
 
36776
  //! moment.js locale configuration
@@ -36815,6 +37028,7 @@ webpackJsonp([3],[
36815
  future : 'em %s',
36816
  past : 'há %s',
36817
  s : 'segundos',
 
36818
  m : 'um minuto',
36819
  mm : '%d minutos',
36820
  h : 'uma hora',
@@ -36840,7 +37054,7 @@ webpackJsonp([3],[
36840
 
36841
 
36842
  /***/ },
36843
- /* 388 */
36844
  /***/ function(module, exports, __webpack_require__) {
36845
 
36846
  //! moment.js locale configuration
@@ -36907,7 +37121,7 @@ webpackJsonp([3],[
36907
 
36908
 
36909
  /***/ },
36910
- /* 389 */
36911
  /***/ function(module, exports, __webpack_require__) {
36912
 
36913
  //! moment.js locale configuration
@@ -36924,6 +37138,7 @@ webpackJsonp([3],[
36924
 
36925
  function relativeTimeWithPlural(number, withoutSuffix, key) {
36926
  var format = {
 
36927
  'mm': 'minute',
36928
  'hh': 'ore',
36929
  'dd': 'zile',
@@ -36964,6 +37179,7 @@ webpackJsonp([3],[
36964
  future : 'peste %s',
36965
  past : '%s în urmă',
36966
  s : 'câteva secunde',
 
36967
  m : 'un minut',
36968
  mm : relativeTimeWithPlural,
36969
  h : 'o oră',
@@ -36987,7 +37203,7 @@ webpackJsonp([3],[
36987
 
36988
 
36989
  /***/ },
36990
- /* 390 */
36991
  /***/ function(module, exports, __webpack_require__) {
36992
 
36993
  //! moment.js locale configuration
@@ -37009,6 +37225,7 @@ webpackJsonp([3],[
37009
  }
37010
  function relativeTimeWithPlural(number, withoutSuffix, key) {
37011
  var format = {
 
37012
  'mm': withoutSuffix ? 'минута_минуты_минут' : 'минуту_минуты_минут',
37013
  'hh': 'час_часа_часов',
37014
  'dd': 'день_дня_дней',
@@ -37060,12 +37277,12 @@ webpackJsonp([3],[
37060
  // Выражение, которое соотвествует только сокращённым формам
37061
  monthsShortStrictRegex: /^(янв\.|февр?\.|мар[т.]|апр\.|ма[яй]|июн[ья.]|июл[ья.]|авг\.|сент?\.|окт\.|нояб?\.|дек\.)/i,
37062
  longDateFormat : {
37063
- LT : 'HH:mm',
37064
- LTS : 'HH:mm:ss',
37065
  L : 'DD.MM.YYYY',
37066
  LL : 'D MMMM YYYY г.',
37067
- LLL : 'D MMMM YYYY г., HH:mm',
37068
- LLLL : 'dddd, D MMMM YYYY г., HH:mm'
37069
  },
37070
  calendar : {
37071
  sameDay: '[Сегодня в] LT',
@@ -37121,6 +37338,7 @@ webpackJsonp([3],[
37121
  future : 'через %s',
37122
  past : '%s назад',
37123
  s : 'несколько секунд',
 
37124
  m : relativeTimeWithPlural,
37125
  mm : relativeTimeWithPlural,
37126
  h : 'час',
@@ -37175,7 +37393,7 @@ webpackJsonp([3],[
37175
 
37176
 
37177
  /***/ },
37178
- /* 391 */
37179
  /***/ function(module, exports, __webpack_require__) {
37180
 
37181
  //! moment.js locale configuration
@@ -37249,6 +37467,7 @@ webpackJsonp([3],[
37249
  future : '%s پوء',
37250
  past : '%s اڳ',
37251
  s : 'چند سيڪنڊ',
 
37252
  m : 'هڪ منٽ',
37253
  mm : '%d منٽ',
37254
  h : 'هڪ ڪلاڪ',
@@ -37278,7 +37497,7 @@ webpackJsonp([3],[
37278
 
37279
 
37280
  /***/ },
37281
- /* 392 */
37282
  /***/ function(module, exports, __webpack_require__) {
37283
 
37284
  //! moment.js locale configuration
@@ -37319,6 +37538,7 @@ webpackJsonp([3],[
37319
  future : '%s geažes',
37320
  past : 'maŋit %s',
37321
  s : 'moadde sekunddat',
 
37322
  m : 'okta minuhta',
37323
  mm : '%d minuhtat',
37324
  h : 'okta diimmu',
@@ -37344,7 +37564,7 @@ webpackJsonp([3],[
37344
 
37345
 
37346
  /***/ },
37347
- /* 393 */
37348
  /***/ function(module, exports, __webpack_require__) {
37349
 
37350
  //! moment.js locale configuration
@@ -37386,6 +37606,7 @@ webpackJsonp([3],[
37386
  future : '%sකින්',
37387
  past : '%sකට පෙර',
37388
  s : 'තත්පර කිහිපය',
 
37389
  m : 'මිනිත්තුව',
37390
  mm : 'මිනිත්තු %d',
37391
  h : 'පැය',
@@ -37420,7 +37641,7 @@ webpackJsonp([3],[
37420
 
37421
 
37422
  /***/ },
37423
- /* 394 */
37424
  /***/ function(module, exports, __webpack_require__) {
37425
 
37426
  //! moment.js locale configuration
@@ -37445,6 +37666,13 @@ webpackJsonp([3],[
37445
  switch (key) {
37446
  case 's': // a few seconds / in a few seconds / a few seconds ago
37447
  return (withoutSuffix || isFuture) ? 'pár sekúnd' : 'pár sekundami';
 
 
 
 
 
 
 
37448
  case 'm': // a minute / in a minute / a minute ago
37449
  return withoutSuffix ? 'minúta' : (isFuture ? 'minútu' : 'minútou');
37450
  case 'mm': // 9 minutes / in 9 minutes / 9 minutes ago
@@ -37550,6 +37778,7 @@ webpackJsonp([3],[
37550
  future : 'za %s',
37551
  past : 'pred %s',
37552
  s : translate,
 
37553
  m : translate,
37554
  mm : translate,
37555
  h : translate,
@@ -37575,7 +37804,7 @@ webpackJsonp([3],[
37575
 
37576
 
37577
  /***/ },
37578
- /* 395 */
37579
  /***/ function(module, exports, __webpack_require__) {
37580
 
37581
  //! moment.js locale configuration
@@ -37594,6 +37823,17 @@ webpackJsonp([3],[
37594
  switch (key) {
37595
  case 's':
37596
  return withoutSuffix || isFuture ? 'nekaj sekund' : 'nekaj sekundami';
 
 
 
 
 
 
 
 
 
 
 
37597
  case 'm':
37598
  return withoutSuffix ? 'ena minuta' : 'eno minuto';
37599
  case 'mm':
@@ -37717,6 +37957,7 @@ webpackJsonp([3],[
37717
  future : 'čez %s',
37718
  past : 'pred %s',
37719
  s : processRelativeTime,
 
37720
  m : processRelativeTime,
37721
  mm : processRelativeTime,
37722
  h : processRelativeTime,
@@ -37742,7 +37983,7 @@ webpackJsonp([3],[
37742
 
37743
 
37744
  /***/ },
37745
- /* 396 */
37746
  /***/ function(module, exports, __webpack_require__) {
37747
 
37748
  //! moment.js locale configuration
@@ -37792,6 +38033,7 @@ webpackJsonp([3],[
37792
  future : 'në %s',
37793
  past : '%s më parë',
37794
  s : 'disa sekonda',
 
37795
  m : 'një minutë',
37796
  mm : '%d minuta',
37797
  h : 'një orë',
@@ -37817,7 +38059,7 @@ webpackJsonp([3],[
37817
 
37818
 
37819
  /***/ },
37820
- /* 397 */
37821
  /***/ function(module, exports, __webpack_require__) {
37822
 
37823
  //! moment.js locale configuration
@@ -37833,6 +38075,7 @@ webpackJsonp([3],[
37833
 
37834
  var translator = {
37835
  words: { //Different grammatical cases
 
37836
  m: ['jedan minut', 'jedne minute'],
37837
  mm: ['minut', 'minute', 'minuta'],
37838
  h: ['jedan sat', 'jednog sata'],
@@ -37907,6 +38150,7 @@ webpackJsonp([3],[
37907
  future : 'za %s',
37908
  past : 'pre %s',
37909
  s : 'nekoliko sekundi',
 
37910
  m : translator.translate,
37911
  mm : translator.translate,
37912
  h : translator.translate,
@@ -37932,7 +38176,7 @@ webpackJsonp([3],[
37932
 
37933
 
37934
  /***/ },
37935
- /* 398 */
37936
  /***/ function(module, exports, __webpack_require__) {
37937
 
37938
  //! moment.js locale configuration
@@ -37948,6 +38192,7 @@ webpackJsonp([3],[
37948
 
37949
  var translator = {
37950
  words: { //Different grammatical cases
 
37951
  m: ['један минут', 'једне минуте'],
37952
  mm: ['минут', 'минуте', 'минута'],
37953
  h: ['један сат', 'једног сата'],
@@ -38022,6 +38267,7 @@ webpackJsonp([3],[
38022
  future : 'за %s',
38023
  past : 'пре %s',
38024
  s : 'неколико секунди',
 
38025
  m : translator.translate,
38026
  mm : translator.translate,
38027
  h : translator.translate,
@@ -38047,7 +38293,7 @@ webpackJsonp([3],[
38047
 
38048
 
38049
  /***/ },
38050
- /* 399 */
38051
  /***/ function(module, exports, __webpack_require__) {
38052
 
38053
  //! moment.js locale configuration
@@ -38089,6 +38335,7 @@ webpackJsonp([3],[
38089
  future : 'nga %s',
38090
  past : 'wenteka nga %s',
38091
  s : 'emizuzwana lomcane',
 
38092
  m : 'umzuzu',
38093
  mm : '%d emizuzu',
38094
  h : 'lihora',
@@ -38141,7 +38388,7 @@ webpackJsonp([3],[
38141
 
38142
 
38143
  /***/ },
38144
- /* 400 */
38145
  /***/ function(module, exports, __webpack_require__) {
38146
 
38147
  //! moment.js locale configuration
@@ -38183,6 +38430,7 @@ webpackJsonp([3],[
38183
  future : 'om %s',
38184
  past : 'för %s sedan',
38185
  s : 'några sekunder',
 
38186
  m : 'en minut',
38187
  mm : '%d minuter',
38188
  h : 'en timme',
@@ -38215,7 +38463,7 @@ webpackJsonp([3],[
38215
 
38216
 
38217
  /***/ },
38218
- /* 401 */
38219
  /***/ function(module, exports, __webpack_require__) {
38220
 
38221
  //! moment.js locale configuration
@@ -38256,6 +38504,7 @@ webpackJsonp([3],[
38256
  future : '%s baadaye',
38257
  past : 'tokea %s',
38258
  s : 'hivi punde',
 
38259
  m : 'dakika moja',
38260
  mm : 'dakika %d',
38261
  h : 'saa limoja',
@@ -38279,7 +38528,7 @@ webpackJsonp([3],[
38279
 
38280
 
38281
  /***/ },
38282
- /* 402 */
38283
  /***/ function(module, exports, __webpack_require__) {
38284
 
38285
  //! moment.js locale configuration
@@ -38344,6 +38593,7 @@ webpackJsonp([3],[
38344
  future : '%s இல்',
38345
  past : '%s முன்',
38346
  s : 'ஒரு சில விநாடிகள்',
 
38347
  m : 'ஒரு நிமிடம்',
38348
  mm : '%d நிமிடங்கள்',
38349
  h : 'ஒரு மணி நேரம்',
@@ -38414,7 +38664,7 @@ webpackJsonp([3],[
38414
 
38415
 
38416
  /***/ },
38417
- /* 403 */
38418
  /***/ function(module, exports, __webpack_require__) {
38419
 
38420
  //! moment.js locale configuration
@@ -38455,6 +38705,7 @@ webpackJsonp([3],[
38455
  future : '%s లో',
38456
  past : '%s క్రితం',
38457
  s : 'కొన్ని క్షణాలు',
 
38458
  m : 'ఒక నిమిషం',
38459
  mm : '%d నిమిషాలు',
38460
  h : 'ఒక గంట',
@@ -38508,7 +38759,7 @@ webpackJsonp([3],[
38508
 
38509
 
38510
  /***/ },
38511
- /* 404 */
38512
  /***/ function(module, exports, __webpack_require__) {
38513
 
38514
  //! moment.js locale configuration
@@ -38549,6 +38800,7 @@ webpackJsonp([3],[
38549
  future : 'iha %s',
38550
  past : '%s liuba',
38551
  s : 'minutu balun',
 
38552
  m : 'minutu ida',
38553
  mm : 'minutus %d',
38554
  h : 'horas ida',
@@ -38581,7 +38833,7 @@ webpackJsonp([3],[
38581
 
38582
 
38583
  /***/ },
38584
- /* 405 */
38585
  /***/ function(module, exports, __webpack_require__) {
38586
 
38587
  //! moment.js locale configuration
@@ -38634,6 +38886,7 @@ webpackJsonp([3],[
38634
  future : 'อีก %s',
38635
  past : '%sที่แล้ว',
38636
  s : 'ไม่กี่วินาที',
 
38637
  m : '1 นาที',
38638
  mm : '%d นาที',
38639
  h : '1 ชั่วโมง',
@@ -38653,7 +38906,7 @@ webpackJsonp([3],[
38653
 
38654
 
38655
  /***/ },
38656
- /* 406 */
38657
  /***/ function(module, exports, __webpack_require__) {
38658
 
38659
  //! moment.js locale configuration
@@ -38693,6 +38946,7 @@ webpackJsonp([3],[
38693
  future : 'sa loob ng %s',
38694
  past : '%s ang nakalipas',
38695
  s : 'ilang segundo',
 
38696
  m : 'isang minuto',
38697
  mm : '%d minuto',
38698
  h : 'isang oras',
@@ -38720,7 +38974,7 @@ webpackJsonp([3],[
38720
 
38721
 
38722
  /***/ },
38723
- /* 407 */
38724
  /***/ function(module, exports, __webpack_require__) {
38725
 
38726
  //! moment.js locale configuration
@@ -38763,6 +39017,8 @@ webpackJsonp([3],[
38763
  function translate(number, withoutSuffix, string, isFuture) {
38764
  var numberNoun = numberAsNoun(number);
38765
  switch (string) {
 
 
38766
  case 'mm':
38767
  return numberNoun + ' tup';
38768
  case 'hh':
@@ -38820,6 +39076,7 @@ webpackJsonp([3],[
38820
  future : translateFuture,
38821
  past : translatePast,
38822
  s : 'puS lup',
 
38823
  m : 'wa’ tup',
38824
  mm : translate,
38825
  h : 'wa’ rep',
@@ -38845,7 +39102,7 @@ webpackJsonp([3],[
38845
 
38846
 
38847
  /***/ },
38848
- /* 408 */
38849
  /***/ function(module, exports, __webpack_require__) {
38850
 
38851
  //! moment.js locale configuration
@@ -38907,6 +39164,7 @@ webpackJsonp([3],[
38907
  future : '%s sonra',
38908
  past : '%s önce',
38909
  s : 'birkaç saniye',
 
38910
  m : 'bir dakika',
38911
  mm : '%d dakika',
38912
  h : 'bir saat',
@@ -38940,7 +39198,7 @@ webpackJsonp([3],[
38940
 
38941
 
38942
  /***/ },
38943
- /* 409 */
38944
  /***/ function(module, exports, __webpack_require__) {
38945
 
38946
  //! moment.js locale configuration
@@ -38994,6 +39252,7 @@ webpackJsonp([3],[
38994
  future : 'osprei %s',
38995
  past : 'ja%s',
38996
  s : processRelativeTime,
 
38997
  m : processRelativeTime,
38998
  mm : processRelativeTime,
38999
  h : processRelativeTime,
@@ -39016,6 +39275,7 @@ webpackJsonp([3],[
39016
  function processRelativeTime(number, withoutSuffix, key, isFuture) {
39017
  var format = {
39018
  's': ['viensas secunds', '\'iensas secunds'],
 
39019
  'm': ['\'n míut', '\'iens míut'],
39020
  'mm': [number + ' míuts', '' + number + ' míuts'],
39021
  'h': ['\'n þora', '\'iensa þora'],
@@ -39036,7 +39296,7 @@ webpackJsonp([3],[
39036
 
39037
 
39038
  /***/ },
39039
- /* 410 */
39040
  /***/ function(module, exports, __webpack_require__) {
39041
 
39042
  //! moment.js locale configuration
@@ -39076,6 +39336,7 @@ webpackJsonp([3],[
39076
  future : 'ⴷⴰⴷⵅ ⵙ ⵢⴰⵏ %s',
39077
  past : 'ⵢⴰⵏ %s',
39078
  s : 'ⵉⵎⵉⴽ',
 
39079
  m : 'ⵎⵉⵏⵓⴺ',
39080
  mm : '%d ⵎⵉⵏⵓⴺ',
39081
  h : 'ⵙⴰⵄⴰ',
@@ -39099,7 +39360,7 @@ webpackJsonp([3],[
39099
 
39100
 
39101
  /***/ },
39102
- /* 411 */
39103
  /***/ function(module, exports, __webpack_require__) {
39104
 
39105
  //! moment.js locale configuration
@@ -39139,6 +39400,7 @@ webpackJsonp([3],[
39139
  future : 'dadkh s yan %s',
39140
  past : 'yan %s',
39141
  s : 'imik',
 
39142
  m : 'minuḍ',
39143
  mm : '%d minuḍ',
39144
  h : 'saɛa',
@@ -39162,7 +39424,7 @@ webpackJsonp([3],[
39162
 
39163
 
39164
  /***/ },
39165
- /* 412 */
39166
  /***/ function(module, exports, __webpack_require__) {
39167
 
39168
  //! moment.js locale configuration
@@ -39183,6 +39445,7 @@ webpackJsonp([3],[
39183
  }
39184
  function relativeTimeWithPlural(number, withoutSuffix, key) {
39185
  var format = {
 
39186
  'mm': withoutSuffix ? 'хвилина_хвилини_хвилин' : 'хвилину_хвилини_хвилин',
39187
  'hh': withoutSuffix ? 'година_години_годин' : 'годину_години_годин',
39188
  'dd': 'день_дні_днів',
@@ -39264,6 +39527,7 @@ webpackJsonp([3],[
39264
  future : 'за %s',
39265
  past : '%s тому',
39266
  s : 'декілька секунд',
 
39267
  m : relativeTimeWithPlural,
39268
  mm : relativeTimeWithPlural,
39269
  h : 'годину',
@@ -39318,7 +39582,7 @@ webpackJsonp([3],[
39318
 
39319
 
39320
  /***/ },
39321
- /* 413 */
39322
  /***/ function(module, exports, __webpack_require__) {
39323
 
39324
  //! moment.js locale configuration
@@ -39393,6 +39657,7 @@ webpackJsonp([3],[
39393
  future : '%s بعد',
39394
  past : '%s قبل',
39395
  s : 'چند سیکنڈ',
 
39396
  m : 'ایک منٹ',
39397
  mm : '%d منٹ',
39398
  h : 'ایک گھنٹہ',
@@ -39422,7 +39687,7 @@ webpackJsonp([3],[
39422
 
39423
 
39424
  /***/ },
39425
- /* 414 */
39426
  /***/ function(module, exports, __webpack_require__) {
39427
 
39428
  //! moment.js locale configuration
@@ -39462,6 +39727,7 @@ webpackJsonp([3],[
39462
  future : 'Якин %s ичида',
39463
  past : 'Бир неча %s олдин',
39464
  s : 'фурсат',
 
39465
  m : 'бир дакика',
39466
  mm : '%d дакика',
39467
  h : 'бир соат',
@@ -39485,7 +39751,7 @@ webpackJsonp([3],[
39485
 
39486
 
39487
  /***/ },
39488
- /* 415 */
39489
  /***/ function(module, exports, __webpack_require__) {
39490
 
39491
  //! moment.js locale configuration
@@ -39525,6 +39791,7 @@ webpackJsonp([3],[
39525
  future : 'Yaqin %s ichida',
39526
  past : 'Bir necha %s oldin',
39527
  s : 'soniya',
 
39528
  m : 'bir daqiqa',
39529
  mm : '%d daqiqa',
39530
  h : 'bir soat',
@@ -39548,7 +39815,7 @@ webpackJsonp([3],[
39548
 
39549
 
39550
  /***/ },
39551
- /* 416 */
39552
  /***/ function(module, exports, __webpack_require__) {
39553
 
39554
  //! moment.js locale configuration
@@ -39605,6 +39872,7 @@ webpackJsonp([3],[
39605
  future : '%s tới',
39606
  past : '%s trước',
39607
  s : 'vài giây',
 
39608
  m : 'một phút',
39609
  mm : '%d phút',
39610
  h : 'một giờ',
@@ -39632,7 +39900,7 @@ webpackJsonp([3],[
39632
 
39633
 
39634
  /***/ },
39635
- /* 417 */
39636
  /***/ function(module, exports, __webpack_require__) {
39637
 
39638
  //! moment.js locale configuration
@@ -39673,6 +39941,7 @@ webpackJsonp([3],[
39673
  future : 'í~ñ %s',
39674
  past : '%s á~gó',
39675
  s : 'á ~féw ~sécó~ñds',
 
39676
  m : 'á ~míñ~úté',
39677
  mm : '%d m~íñú~tés',
39678
  h : 'á~ñ hó~úr',
@@ -39705,7 +39974,7 @@ webpackJsonp([3],[
39705
 
39706
 
39707
  /***/ },
39708
- /* 418 */
39709
  /***/ function(module, exports, __webpack_require__) {
39710
 
39711
  //! moment.js locale configuration
@@ -39745,6 +40014,7 @@ webpackJsonp([3],[
39745
  future : 'ní %s',
39746
  past : '%s kọjá',
39747
  s : 'ìsẹjú aayá die',
 
39748
  m : 'ìsẹjú kan',
39749
  mm : 'ìsẹjú %d',
39750
  h : 'wákati kan',
@@ -39770,7 +40040,7 @@ webpackJsonp([3],[
39770
 
39771
 
39772
  /***/ },
39773
- /* 419 */
39774
  /***/ function(module, exports, __webpack_require__) {
39775
 
39776
  //! moment.js locale configuration
@@ -39794,14 +40064,14 @@ webpackJsonp([3],[
39794
  longDateFormat : {
39795
  LT : 'HH:mm',
39796
  LTS : 'HH:mm:ss',
39797
- L : 'YYYY年MMMD日',
39798
- LL : 'YYYY年MMMD日',
39799
- LLL : 'YYYY年MMMD日Ah点mm分',
39800
- LLLL : 'YYYY年MMMD日ddddAh点mm分',
39801
- l : 'YYYY年MMMD日',
39802
- ll : 'YYYY年MMMD日',
39803
- lll : 'YYYY年MMMD日 HH:mm',
39804
- llll : 'YYYY年MMMD日dddd HH:mm'
39805
  },
39806
  meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
39807
  meridiemHour: function (hour, meridiem) {
@@ -39862,6 +40132,7 @@ webpackJsonp([3],[
39862
  future : '%s内',
39863
  past : '%s前',
39864
  s : '几秒',
 
39865
  m : '1 分钟',
39866
  mm : '%d 分钟',
39867
  h : '1 小时',
@@ -39886,7 +40157,7 @@ webpackJsonp([3],[
39886
 
39887
 
39888
  /***/ },
39889
- /* 420 */
39890
  /***/ function(module, exports, __webpack_require__) {
39891
 
39892
  //! moment.js locale configuration
@@ -39911,14 +40182,14 @@ webpackJsonp([3],[
39911
  longDateFormat : {
39912
  LT : 'HH:mm',
39913
  LTS : 'HH:mm:ss',
39914
- L : 'YYYY年MMMD日',
39915
- LL : 'YYYY年MMMD日',
39916
- LLL : 'YYYY年MMMD日 HH:mm',
39917
- LLLL : 'YYYY年MMMD日dddd HH:mm',
39918
- l : 'YYYY年MMMD日',
39919
- ll : 'YYYY年MMMD日',
39920
- lll : 'YYYY年MMMD日 HH:mm',
39921
- llll : 'YYYY年MMMD日dddd HH:mm'
39922
  },
39923
  meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
39924
  meridiemHour : function (hour, meridiem) {
@@ -39977,6 +40248,7 @@ webpackJsonp([3],[
39977
  future : '%s內',
39978
  past : '%s前',
39979
  s : '幾秒',
 
39980
  m : '1 分鐘',
39981
  mm : '%d 分鐘',
39982
  h : '1 小時',
@@ -39996,7 +40268,7 @@ webpackJsonp([3],[
39996
 
39997
 
39998
  /***/ },
39999
- /* 421 */
40000
  /***/ function(module, exports, __webpack_require__) {
40001
 
40002
  //! moment.js locale configuration
@@ -40020,14 +40292,14 @@ webpackJsonp([3],[
40020
  longDateFormat : {
40021
  LT : 'HH:mm',
40022
  LTS : 'HH:mm:ss',
40023
- L : 'YYYY年MMMD日',
40024
- LL : 'YYYY年MMMD日',
40025
- LLL : 'YYYY年MMMD日 HH:mm',
40026
- LLLL : 'YYYY年MMMD日dddd HH:mm',
40027
- l : 'YYYY年MMMD日',
40028
- ll : 'YYYY年MMMD日',
40029
- lll : 'YYYY年MMMD日 HH:mm',
40030
- llll : 'YYYY年MMMD日dddd HH:mm'
40031
  },
40032
  meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
40033
  meridiemHour : function (hour, meridiem) {
@@ -40086,6 +40358,7 @@ webpackJsonp([3],[
40086
  future : '%s內',
40087
  past : '%s前',
40088
  s : '幾秒',
 
40089
  m : '1 分鐘',
40090
  mm : '%d 分鐘',
40091
  h : '1 小時',
@@ -40105,7 +40378,6 @@ webpackJsonp([3],[
40105
 
40106
 
40107
  /***/ },
40108
- /* 422 */,
40109
  /* 423 */,
40110
  /* 424 */,
40111
  /* 425 */,
@@ -40119,7 +40391,8 @@ webpackJsonp([3],[
40119
  /* 433 */,
40120
  /* 434 */,
40121
  /* 435 */,
40122
- /* 436 */
 
40123
  /***/ function(module, exports, __webpack_require__) {
40124
 
40125
  'use strict';
@@ -40130,11 +40403,11 @@ webpackJsonp([3],[
40130
 
40131
  var _react2 = _interopRequireDefault(_react);
40132
 
40133
- var _reactTooltip = __webpack_require__(437);
40134
 
40135
  var _reactTooltip2 = _interopRequireDefault(_reactTooltip);
40136
 
40137
- var _reactHtmlParser = __webpack_require__(450);
40138
 
40139
  var _reactHtmlParser2 = _interopRequireDefault(_reactHtmlParser);
40140
 
@@ -40202,7 +40475,7 @@ webpackJsonp([3],[
40202
  module.exports = Tooltip;
40203
 
40204
  /***/ },
40205
- /* 437 */
40206
  /***/ function(module, exports, __webpack_require__) {
40207
 
40208
  'use strict';
@@ -40238,45 +40511,45 @@ webpackJsonp([3],[
40238
 
40239
  var _classnames2 = _interopRequireDefault(_classnames);
40240
 
40241
- var _staticMethods = __webpack_require__(438);
40242
 
40243
  var _staticMethods2 = _interopRequireDefault(_staticMethods);
40244
 
40245
- var _windowListener = __webpack_require__(440);
40246
 
40247
  var _windowListener2 = _interopRequireDefault(_windowListener);
40248
 
40249
- var _customEvent = __webpack_require__(441);
40250
 
40251
  var _customEvent2 = _interopRequireDefault(_customEvent);
40252
 
40253
- var _isCapture = __webpack_require__(442);
40254
 
40255
  var _isCapture2 = _interopRequireDefault(_isCapture);
40256
 
40257
- var _getEffect = __webpack_require__(443);
40258
 
40259
  var _getEffect2 = _interopRequireDefault(_getEffect);
40260
 
40261
- var _trackRemoval = __webpack_require__(444);
40262
 
40263
  var _trackRemoval2 = _interopRequireDefault(_trackRemoval);
40264
 
40265
- var _getPosition = __webpack_require__(445);
40266
 
40267
  var _getPosition2 = _interopRequireDefault(_getPosition);
40268
 
40269
- var _getTipContent = __webpack_require__(446);
40270
 
40271
  var _getTipContent2 = _interopRequireDefault(_getTipContent);
40272
 
40273
- var _aria = __webpack_require__(447);
40274
 
40275
- var _nodeListToArray = __webpack_require__(448);
40276
 
40277
  var _nodeListToArray2 = _interopRequireDefault(_nodeListToArray);
40278
 
40279
- var _style = __webpack_require__(449);
40280
 
40281
  var _style2 = _interopRequireDefault(_style);
40282
 
@@ -40801,7 +41074,7 @@ webpackJsonp([3],[
40801
  module.exports = ReactTooltip;
40802
 
40803
  /***/ },
40804
- /* 438 */
40805
  /***/ function(module, exports, __webpack_require__) {
40806
 
40807
  'use strict';
@@ -40859,7 +41132,7 @@ webpackJsonp([3],[
40859
  };
40860
  };
40861
 
40862
- var _constant = __webpack_require__(439);
40863
 
40864
  var _constant2 = _interopRequireDefault(_constant);
40865
 
@@ -40884,7 +41157,7 @@ webpackJsonp([3],[
40884
  */
40885
 
40886
  /***/ },
40887
- /* 439 */
40888
  /***/ function(module, exports) {
40889
 
40890
  'use strict';
@@ -40902,7 +41175,7 @@ webpackJsonp([3],[
40902
  };
40903
 
40904
  /***/ },
40905
- /* 440 */
40906
  /***/ function(module, exports, __webpack_require__) {
40907
 
40908
  'use strict';
@@ -40948,14 +41221,14 @@ webpackJsonp([3],[
40948
  };
40949
  };
40950
 
40951
- var _constant = __webpack_require__(439);
40952
 
40953
  var _constant2 = _interopRequireDefault(_constant);
40954
 
40955
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
40956
 
40957
  /***/ },
40958
- /* 441 */
40959
  /***/ function(module, exports) {
40960
 
40961
  'use strict';
@@ -41048,7 +41321,7 @@ webpackJsonp([3],[
41048
  var customListener = void 0;
41049
 
41050
  /***/ },
41051
- /* 442 */
41052
  /***/ function(module, exports) {
41053
 
41054
  'use strict';
@@ -41065,7 +41338,7 @@ webpackJsonp([3],[
41065
  };
41066
 
41067
  /***/ },
41068
- /* 443 */
41069
  /***/ function(module, exports) {
41070
 
41071
  'use strict';
@@ -41082,7 +41355,7 @@ webpackJsonp([3],[
41082
  };
41083
 
41084
  /***/ },
41085
- /* 444 */
41086
  /***/ function(module, exports) {
41087
 
41088
  "use strict";
@@ -41178,7 +41451,7 @@ webpackJsonp([3],[
41178
  };
41179
 
41180
  /***/ },
41181
- /* 445 */
41182
  /***/ function(module, exports) {
41183
 
41184
  'use strict';
@@ -41492,7 +41765,7 @@ webpackJsonp([3],[
41492
  };
41493
 
41494
  /***/ },
41495
- /* 446 */
41496
  /***/ function(module, exports, __webpack_require__) {
41497
 
41498
  'use strict';
@@ -41529,7 +41802,7 @@ webpackJsonp([3],[
41529
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
41530
 
41531
  /***/ },
41532
- /* 447 */
41533
  /***/ function(module, exports) {
41534
 
41535
  "use strict";
@@ -41558,7 +41831,7 @@ webpackJsonp([3],[
41558
  }
41559
 
41560
  /***/ },
41561
- /* 448 */
41562
  /***/ function(module, exports) {
41563
 
41564
  "use strict";
@@ -41578,7 +41851,7 @@ webpackJsonp([3],[
41578
  };
41579
 
41580
  /***/ },
41581
- /* 449 */
41582
  /***/ function(module, exports) {
41583
 
41584
  'use strict';
@@ -41589,7 +41862,7 @@ webpackJsonp([3],[
41589
  exports.default = '.__react_component_tooltip{border-radius:3px;display:inline-block;font-size:13px;left:-999em;opacity:0;padding:8px 21px;position:fixed;pointer-events:none;transition:opacity 0.3s ease-out;top:-999em;visibility:hidden;z-index:999}.__react_component_tooltip:before,.__react_component_tooltip:after{content:"";width:0;height:0;position:absolute}.__react_component_tooltip.show{opacity:0.9;margin-top:0px;margin-left:0px;visibility:visible}.__react_component_tooltip.type-dark{color:#fff;background-color:#222}.__react_component_tooltip.type-dark.place-top:after{border-top-color:#222;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-dark.place-bottom:after{border-bottom-color:#222;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-dark.place-left:after{border-left-color:#222;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-dark.place-right:after{border-right-color:#222;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-dark.border{border:1px solid #fff}.__react_component_tooltip.type-dark.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-dark.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-dark.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-dark.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-success{color:#fff;background-color:#8DC572}.__react_component_tooltip.type-success.place-top:after{border-top-color:#8DC572;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-success.place-bottom:after{border-bottom-color:#8DC572;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-success.place-left:after{border-left-color:#8DC572;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-success.place-right:after{border-right-color:#8DC572;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-success.border{border:1px solid #fff}.__react_component_tooltip.type-success.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-success.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-success.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-success.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-warning{color:#fff;background-color:#F0AD4E}.__react_component_tooltip.type-warning.place-top:after{border-top-color:#F0AD4E;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-warning.place-bottom:after{border-bottom-color:#F0AD4E;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-warning.place-left:after{border-left-color:#F0AD4E;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-warning.place-right:after{border-right-color:#F0AD4E;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-warning.border{border:1px solid #fff}.__react_component_tooltip.type-warning.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-warning.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-warning.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-warning.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-error{color:#fff;background-color:#BE6464}.__react_component_tooltip.type-error.place-top:after{border-top-color:#BE6464;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-error.place-bottom:after{border-bottom-color:#BE6464;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-error.place-left:after{border-left-color:#BE6464;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-error.place-right:after{border-right-color:#BE6464;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-error.border{border:1px solid #fff}.__react_component_tooltip.type-error.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-error.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-error.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-error.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-info{color:#fff;background-color:#337AB7}.__react_component_tooltip.type-info.place-top:after{border-top-color:#337AB7;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-info.place-bottom:after{border-bottom-color:#337AB7;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-info.place-left:after{border-left-color:#337AB7;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-info.place-right:after{border-right-color:#337AB7;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-info.border{border:1px solid #fff}.__react_component_tooltip.type-info.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-info.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-info.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-info.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-light{color:#222;background-color:#fff}.__react_component_tooltip.type-light.place-top:after{border-top-color:#fff;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-light.place-bottom:after{border-bottom-color:#fff;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-light.place-left:after{border-left-color:#fff;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-light.place-right:after{border-right-color:#fff;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-light.border{border:1px solid #222}.__react_component_tooltip.type-light.border.place-top:before{border-top:8px solid #222}.__react_component_tooltip.type-light.border.place-bottom:before{border-bottom:8px solid #222}.__react_component_tooltip.type-light.border.place-left:before{border-left:8px solid #222}.__react_component_tooltip.type-light.border.place-right:before{border-right:8px solid #222}.__react_component_tooltip.place-top{margin-top:-10px}.__react_component_tooltip.place-top:before{border-left:10px solid transparent;border-right:10px solid transparent;bottom:-8px;left:50%;margin-left:-10px}.__react_component_tooltip.place-top:after{border-left:8px solid transparent;border-right:8px solid transparent;bottom:-6px;left:50%;margin-left:-8px}.__react_component_tooltip.place-bottom{margin-top:10px}.__react_component_tooltip.place-bottom:before{border-left:10px solid transparent;border-right:10px solid transparent;top:-8px;left:50%;margin-left:-10px}.__react_component_tooltip.place-bottom:after{border-left:8px solid transparent;border-right:8px solid transparent;top:-6px;left:50%;margin-left:-8px}.__react_component_tooltip.place-left{margin-left:-10px}.__react_component_tooltip.place-left:before{border-top:6px solid transparent;border-bottom:6px solid transparent;right:-8px;top:50%;margin-top:-5px}.__react_component_tooltip.place-left:after{border-top:5px solid transparent;border-bottom:5px solid transparent;right:-6px;top:50%;margin-top:-4px}.__react_component_tooltip.place-right{margin-left:10px}.__react_component_tooltip.place-right:before{border-top:6px solid transparent;border-bottom:6px solid transparent;left:-8px;top:50%;margin-top:-5px}.__react_component_tooltip.place-right:after{border-top:5px solid transparent;border-bottom:5px solid transparent;left:-6px;top:50%;margin-top:-4px}.__react_component_tooltip .multi-line{display:block;padding:2px 0px;text-align:center}';
41590
 
41591
  /***/ },
41592
- /* 450 */
41593
  /***/ function(module, exports, __webpack_require__) {
41594
 
41595
  'use strict';
@@ -41598,7 +41871,7 @@ webpackJsonp([3],[
41598
  value: true
41599
  });
41600
 
41601
- var _HtmlParser = __webpack_require__(451);
41602
 
41603
  var _HtmlParser2 = _interopRequireDefault(_HtmlParser);
41604
 
@@ -41607,7 +41880,7 @@ webpackJsonp([3],[
41607
  exports.default = _HtmlParser2.default;
41608
 
41609
  /***/ },
41610
- /* 451 */
41611
  /***/ function(module, exports, __webpack_require__) {
41612
 
41613
  'use strict';
@@ -41617,11 +41890,11 @@ webpackJsonp([3],[
41617
  });
41618
  exports.default = HtmlParser;
41619
 
41620
- var _htmlparser = __webpack_require__(452);
41621
 
41622
  var _htmlparser2 = _interopRequireDefault(_htmlparser);
41623
 
41624
- var _ProcessNodes = __webpack_require__(505);
41625
 
41626
  var _ProcessNodes2 = _interopRequireDefault(_ProcessNodes);
41627
 
@@ -41639,11 +41912,11 @@ webpackJsonp([3],[
41639
  }
41640
 
41641
  /***/ },
41642
- /* 452 */
41643
  /***/ function(module, exports, __webpack_require__) {
41644
 
41645
- var Parser = __webpack_require__(453),
41646
- DomHandler = __webpack_require__(462);
41647
 
41648
  function defineProp(name, value){
41649
  delete module.exports[name];
@@ -41653,26 +41926,26 @@ webpackJsonp([3],[
41653
 
41654
  module.exports = {
41655
  Parser: Parser,
41656
- Tokenizer: __webpack_require__(454),
41657
- ElementType: __webpack_require__(463),
41658
  DomHandler: DomHandler,
41659
  get FeedHandler(){
41660
- return defineProp("FeedHandler", __webpack_require__(466));
41661
  },
41662
  get Stream(){
41663
- return defineProp("Stream", __webpack_require__(467));
41664
  },
41665
  get WritableStream(){
41666
- return defineProp("WritableStream", __webpack_require__(468));
41667
  },
41668
  get ProxyHandler(){
41669
- return defineProp("ProxyHandler", __webpack_require__(491));
41670
  },
41671
  get DomUtils(){
41672
- return defineProp("DomUtils", __webpack_require__(492));
41673
  },
41674
  get CollectingHandler(){
41675
- return defineProp("CollectingHandler", __webpack_require__(504));
41676
  },
41677
  // For legacy support
41678
  DefaultHandler: DomHandler,
@@ -41713,10 +41986,10 @@ webpackJsonp([3],[
41713
 
41714
 
41715
  /***/ },
41716
- /* 453 */
41717
  /***/ function(module, exports, __webpack_require__) {
41718
 
41719
- var Tokenizer = __webpack_require__(454);
41720
 
41721
  /*
41722
  Options:
@@ -41838,7 +42111,7 @@ webpackJsonp([3],[
41838
  if(this._cbs.onparserinit) this._cbs.onparserinit(this);
41839
  }
41840
 
41841
- __webpack_require__(460)(Parser, __webpack_require__(461).EventEmitter);
41842
 
41843
  Parser.prototype._updatePosition = function(initialOffset){
41844
  if(this.endIndex === null){
@@ -42072,15 +42345,15 @@ webpackJsonp([3],[
42072
 
42073
 
42074
  /***/ },
42075
- /* 454 */
42076
  /***/ function(module, exports, __webpack_require__) {
42077
 
42078
  module.exports = Tokenizer;
42079
 
42080
- var decodeCodePoint = __webpack_require__(455),
42081
- entityMap = __webpack_require__(457),
42082
- legacyMap = __webpack_require__(458),
42083
- xmlMap = __webpack_require__(459),
42084
 
42085
  i = 0,
42086
 
@@ -42984,10 +43257,10 @@ webpackJsonp([3],[
42984
 
42985
 
42986
  /***/ },
42987
- /* 455 */
42988
  /***/ function(module, exports, __webpack_require__) {
42989
 
42990
- var decodeMap = __webpack_require__(456);
42991
 
42992
  module.exports = decodeCodePoint;
42993
 
@@ -43016,31 +43289,31 @@ webpackJsonp([3],[
43016
 
43017
 
43018
  /***/ },
43019
- /* 456 */
43020
  /***/ function(module, exports) {
43021
 
43022
  module.exports = {"0":65533,"128":8364,"130":8218,"131":402,"132":8222,"133":8230,"134":8224,"135":8225,"136":710,"137":8240,"138":352,"139":8249,"140":338,"142":381,"145":8216,"146":8217,"147":8220,"148":8221,"149":8226,"150":8211,"151":8212,"152":732,"153":8482,"154":353,"155":8250,"156":339,"158":382,"159":376}
43023
 
43024
  /***/ },
43025
- /* 457 */
43026
  /***/ function(module, exports) {
43027
 
43028
  module.exports = {"Aacute":"Á","aacute":"á","Abreve":"Ă","abreve":"ă","ac":"∾","acd":"∿","acE":"∾̳","Acirc":"Â","acirc":"â","acute":"´","Acy":"А","acy":"а","AElig":"Æ","aelig":"æ","af":"⁡","Afr":"𝔄","afr":"𝔞","Agrave":"À","agrave":"à","alefsym":"ℵ","aleph":"ℵ","Alpha":"Α","alpha":"α","Amacr":"Ā","amacr":"ā","amalg":"⨿","amp":"&","AMP":"&","andand":"⩕","And":"⩓","and":"∧","andd":"⩜","andslope":"⩘","andv":"⩚","ang":"∠","ange":"⦤","angle":"∠","angmsdaa":"⦨","angmsdab":"⦩","angmsdac":"⦪","angmsdad":"⦫","angmsdae":"⦬","angmsdaf":"⦭","angmsdag":"⦮","angmsdah":"⦯","angmsd":"∡","angrt":"∟","angrtvb":"⊾","angrtvbd":"⦝","angsph":"∢","angst":"Å","angzarr":"⍼","Aogon":"Ą","aogon":"ą","Aopf":"𝔸","aopf":"𝕒","apacir":"⩯","ap":"≈","apE":"⩰","ape":"≊","apid":"≋","apos":"'","ApplyFunction":"⁡","approx":"≈","approxeq":"≊","Aring":"Å","aring":"å","Ascr":"𝒜","ascr":"𝒶","Assign":"≔","ast":"*","asymp":"≈","asympeq":"≍","Atilde":"Ã","atilde":"ã","Auml":"Ä","auml":"ä","awconint":"∳","awint":"⨑","backcong":"≌","backepsilon":"϶","backprime":"‵","backsim":"∽","backsimeq":"⋍","Backslash":"∖","Barv":"⫧","barvee":"⊽","barwed":"⌅","Barwed":"⌆","barwedge":"⌅","bbrk":"⎵","bbrktbrk":"⎶","bcong":"≌","Bcy":"Б","bcy":"б","bdquo":"„","becaus":"∵","because":"∵","Because":"∵","bemptyv":"⦰","bepsi":"϶","bernou":"ℬ","Bernoullis":"ℬ","Beta":"Β","beta":"β","beth":"ℶ","between":"≬","Bfr":"𝔅","bfr":"𝔟","bigcap":"⋂","bigcirc":"◯","bigcup":"⋃","bigodot":"⨀","bigoplus":"⨁","bigotimes":"⨂","bigsqcup":"⨆","bigstar":"★","bigtriangledown":"▽","bigtriangleup":"△","biguplus":"⨄","bigvee":"⋁","bigwedge":"⋀","bkarow":"⤍","blacklozenge":"⧫","blacksquare":"▪","blacktriangle":"▴","blacktriangledown":"▾","blacktriangleleft":"◂","blacktriangleright":"▸","blank":"␣","blk12":"▒","blk14":"░","blk34":"▓","block":"█","bne":"=⃥","bnequiv":"≡⃥","bNot":"⫭","bnot":"⌐","Bopf":"𝔹","bopf":"𝕓","bot":"⊥","bottom":"⊥","bowtie":"⋈","boxbox":"⧉","boxdl":"┐","boxdL":"╕","boxDl":"╖","boxDL":"╗","boxdr":"┌","boxdR":"╒","boxDr":"╓","boxDR":"╔","boxh":"─","boxH":"═","boxhd":"┬","boxHd":"╤","boxhD":"╥","boxHD":"╦","boxhu":"┴","boxHu":"╧","boxhU":"╨","boxHU":"╩","boxminus":"⊟","boxplus":"⊞","boxtimes":"⊠","boxul":"┘","boxuL":"╛","boxUl":"╜","boxUL":"╝","boxur":"└","boxuR":"╘","boxUr":"╙","boxUR":"╚","boxv":"│","boxV":"║","boxvh":"┼","boxvH":"╪","boxVh":"╫","boxVH":"╬","boxvl":"┤","boxvL":"╡","boxVl":"╢","boxVL":"╣","boxvr":"├","boxvR":"╞","boxVr":"╟","boxVR":"╠","bprime":"‵","breve":"˘","Breve":"˘","brvbar":"¦","bscr":"𝒷","Bscr":"ℬ","bsemi":"⁏","bsim":"∽","bsime":"⋍","bsolb":"⧅","bsol":"\\","bsolhsub":"⟈","bull":"•","bullet":"•","bump":"≎","bumpE":"⪮","bumpe":"≏","Bumpeq":"≎","bumpeq":"≏","Cacute":"Ć","cacute":"ć","capand":"⩄","capbrcup":"⩉","capcap":"⩋","cap":"∩","Cap":"⋒","capcup":"⩇","capdot":"⩀","CapitalDifferentialD":"ⅅ","caps":"∩︀","caret":"⁁","caron":"ˇ","Cayleys":"ℭ","ccaps":"⩍","Ccaron":"Č","ccaron":"č","Ccedil":"Ç","ccedil":"ç","Ccirc":"Ĉ","ccirc":"ĉ","Cconint":"∰","ccups":"⩌","ccupssm":"⩐","Cdot":"Ċ","cdot":"ċ","cedil":"¸","Cedilla":"¸","cemptyv":"⦲","cent":"¢","centerdot":"·","CenterDot":"·","cfr":"𝔠","Cfr":"ℭ","CHcy":"Ч","chcy":"ч","check":"✓","checkmark":"✓","Chi":"Χ","chi":"χ","circ":"ˆ","circeq":"≗","circlearrowleft":"↺","circlearrowright":"↻","circledast":"⊛","circledcirc":"⊚","circleddash":"⊝","CircleDot":"⊙","circledR":"®","circledS":"Ⓢ","CircleMinus":"⊖","CirclePlus":"⊕","CircleTimes":"⊗","cir":"○","cirE":"⧃","cire":"≗","cirfnint":"⨐","cirmid":"⫯","cirscir":"⧂","ClockwiseContourIntegral":"∲","CloseCurlyDoubleQuote":"”","CloseCurlyQuote":"’","clubs":"♣","clubsuit":"♣","colon":":","Colon":"∷","Colone":"⩴","colone":"≔","coloneq":"≔","comma":",","commat":"@","comp":"∁","compfn":"∘","complement":"∁","complexes":"ℂ","cong":"≅","congdot":"⩭","Congruent":"≡","conint":"∮","Conint":"∯","ContourIntegral":"∮","copf":"𝕔","Copf":"ℂ","coprod":"∐","Coproduct":"∐","copy":"©","COPY":"©","copysr":"℗","CounterClockwiseContourIntegral":"∳","crarr":"↵","cross":"✗","Cross":"⨯","Cscr":"𝒞","cscr":"𝒸","csub":"⫏","csube":"⫑","csup":"⫐","csupe":"⫒","ctdot":"⋯","cudarrl":"⤸","cudarrr":"⤵","cuepr":"⋞","cuesc":"⋟","cularr":"↶","cularrp":"⤽","cupbrcap":"⩈","cupcap":"⩆","CupCap":"≍","cup":"∪","Cup":"⋓","cupcup":"⩊","cupdot":"⊍","cupor":"⩅","cups":"∪︀","curarr":"↷","curarrm":"⤼","curlyeqprec":"⋞","curlyeqsucc":"⋟","curlyvee":"⋎","curlywedge":"⋏","curren":"¤","curvearrowleft":"↶","curvearrowright":"↷","cuvee":"⋎","cuwed":"⋏","cwconint":"∲","cwint":"∱","cylcty":"⌭","dagger":"†","Dagger":"‡","daleth":"ℸ","darr":"↓","Darr":"↡","dArr":"⇓","dash":"‐","Dashv":"⫤","dashv":"⊣","dbkarow":"⤏","dblac":"˝","Dcaron":"Ď","dcaron":"ď","Dcy":"Д","dcy":"д","ddagger":"‡","ddarr":"⇊","DD":"ⅅ","dd":"ⅆ","DDotrahd":"⤑","ddotseq":"⩷","deg":"°","Del":"∇","Delta":"Δ","delta":"δ","demptyv":"⦱","dfisht":"⥿","Dfr":"𝔇","dfr":"𝔡","dHar":"⥥","dharl":"⇃","dharr":"⇂","DiacriticalAcute":"´","DiacriticalDot":"˙","DiacriticalDoubleAcute":"˝","DiacriticalGrave":"`","DiacriticalTilde":"˜","diam":"⋄","diamond":"⋄","Diamond":"⋄","diamondsuit":"♦","diams":"♦","die":"¨","DifferentialD":"ⅆ","digamma":"ϝ","disin":"⋲","div":"÷","divide":"÷","divideontimes":"⋇","divonx":"⋇","DJcy":"Ђ","djcy":"ђ","dlcorn":"⌞","dlcrop":"⌍","dollar":"$","Dopf":"𝔻","dopf":"𝕕","Dot":"¨","dot":"˙","DotDot":"⃜","doteq":"≐","doteqdot":"≑","DotEqual":"≐","dotminus":"∸","dotplus":"∔","dotsquare":"⊡","doublebarwedge":"⌆","DoubleContourIntegral":"∯","DoubleDot":"¨","DoubleDownArrow":"⇓","DoubleLeftArrow":"⇐","DoubleLeftRightArrow":"⇔","DoubleLeftTee":"⫤","DoubleLongLeftArrow":"⟸","DoubleLongLeftRightArrow":"⟺","DoubleLongRightArrow":"⟹","DoubleRightArrow":"⇒","DoubleRightTee":"⊨","DoubleUpArrow":"⇑","DoubleUpDownArrow":"⇕","DoubleVerticalBar":"∥","DownArrowBar":"⤓","downarrow":"↓","DownArrow":"↓","Downarrow":"⇓","DownArrowUpArrow":"⇵","DownBreve":"̑","downdownarrows":"⇊","downharpoonleft":"⇃","downharpoonright":"⇂","DownLeftRightVector":"⥐","DownLeftTeeVector":"⥞","DownLeftVectorBar":"⥖","DownLeftVector":"↽","DownRightTeeVector":"⥟","DownRightVectorBar":"⥗","DownRightVector":"⇁","DownTeeArrow":"↧","DownTee":"⊤","drbkarow":"⤐","drcorn":"⌟","drcrop":"⌌","Dscr":"𝒟","dscr":"𝒹","DScy":"Ѕ","dscy":"ѕ","dsol":"⧶","Dstrok":"Đ","dstrok":"đ","dtdot":"⋱","dtri":"▿","dtrif":"▾","duarr":"⇵","duhar":"⥯","dwangle":"⦦","DZcy":"Џ","dzcy":"џ","dzigrarr":"⟿","Eacute":"É","eacute":"é","easter":"⩮","Ecaron":"Ě","ecaron":"ě","Ecirc":"Ê","ecirc":"ê","ecir":"≖","ecolon":"≕","Ecy":"Э","ecy":"э","eDDot":"⩷","Edot":"Ė","edot":"ė","eDot":"≑","ee":"ⅇ","efDot":"≒","Efr":"𝔈","efr":"𝔢","eg":"⪚","Egrave":"È","egrave":"è","egs":"⪖","egsdot":"⪘","el":"⪙","Element":"∈","elinters":"⏧","ell":"ℓ","els":"⪕","elsdot":"⪗","Emacr":"Ē","emacr":"ē","empty":"∅","emptyset":"∅","EmptySmallSquare":"◻","emptyv":"∅","EmptyVerySmallSquare":"▫","emsp13":" ","emsp14":" ","emsp":" ","ENG":"Ŋ","eng":"ŋ","ensp":" ","Eogon":"Ę","eogon":"ę","Eopf":"𝔼","eopf":"𝕖","epar":"⋕","eparsl":"⧣","eplus":"⩱","epsi":"ε","Epsilon":"Ε","epsilon":"ε","epsiv":"ϵ","eqcirc":"≖","eqcolon":"≕","eqsim":"≂","eqslantgtr":"⪖","eqslantless":"⪕","Equal":"⩵","equals":"=","EqualTilde":"≂","equest":"≟","Equilibrium":"⇌","equiv":"≡","equivDD":"⩸","eqvparsl":"⧥","erarr":"⥱","erDot":"≓","escr":"ℯ","Escr":"ℰ","esdot":"≐","Esim":"⩳","esim":"≂","Eta":"Η","eta":"η","ETH":"Ð","eth":"ð","Euml":"Ë","euml":"ë","euro":"€","excl":"!","exist":"∃","Exists":"∃","expectation":"ℰ","exponentiale":"ⅇ","ExponentialE":"ⅇ","fallingdotseq":"≒","Fcy":"Ф","fcy":"ф","female":"♀","ffilig":"ffi","fflig":"ff","ffllig":"ffl","Ffr":"𝔉","ffr":"𝔣","filig":"fi","FilledSmallSquare":"◼","FilledVerySmallSquare":"▪","fjlig":"fj","flat":"♭","fllig":"fl","fltns":"▱","fnof":"ƒ","Fopf":"𝔽","fopf":"𝕗","forall":"∀","ForAll":"∀","fork":"⋔","forkv":"⫙","Fouriertrf":"ℱ","fpartint":"⨍","frac12":"½","frac13":"⅓","frac14":"¼","frac15":"⅕","frac16":"⅙","frac18":"⅛","frac23":"⅔","frac25":"⅖","frac34":"¾","frac35":"⅗","frac38":"⅜","frac45":"⅘","frac56":"⅚","frac58":"⅝","frac78":"⅞","frasl":"⁄","frown":"⌢","fscr":"𝒻","Fscr":"ℱ","gacute":"ǵ","Gamma":"Γ","gamma":"γ","Gammad":"Ϝ","gammad":"ϝ","gap":"⪆","Gbreve":"Ğ","gbreve":"ğ","Gcedil":"Ģ","Gcirc":"Ĝ","gcirc":"ĝ","Gcy":"Г","gcy":"г","Gdot":"Ġ","gdot":"ġ","ge":"≥","gE":"≧","gEl":"⪌","gel":"⋛","geq":"≥","geqq":"≧","geqslant":"⩾","gescc":"⪩","ges":"⩾","gesdot":"⪀","gesdoto":"⪂","gesdotol":"⪄","gesl":"⋛︀","gesles":"⪔","Gfr":"𝔊","gfr":"𝔤","gg":"≫","Gg":"⋙","ggg":"⋙","gimel":"ℷ","GJcy":"Ѓ","gjcy":"ѓ","gla":"⪥","gl":"≷","glE":"⪒","glj":"⪤","gnap":"⪊","gnapprox":"⪊","gne":"⪈","gnE":"≩","gneq":"⪈","gneqq":"≩","gnsim":"⋧","Gopf":"𝔾","gopf":"𝕘","grave":"`","GreaterEqual":"≥","GreaterEqualLess":"⋛","GreaterFullEqual":"≧","GreaterGreater":"⪢","GreaterLess":"≷","GreaterSlantEqual":"⩾","GreaterTilde":"≳","Gscr":"𝒢","gscr":"ℊ","gsim":"≳","gsime":"⪎","gsiml":"⪐","gtcc":"⪧","gtcir":"⩺","gt":">","GT":">","Gt":"≫","gtdot":"⋗","gtlPar":"⦕","gtquest":"⩼","gtrapprox":"⪆","gtrarr":"⥸","gtrdot":"⋗","gtreqless":"⋛","gtreqqless":"⪌","gtrless":"≷","gtrsim":"≳","gvertneqq":"≩︀","gvnE":"≩︀","Hacek":"ˇ","hairsp":" ","half":"½","hamilt":"ℋ","HARDcy":"Ъ","hardcy":"ъ","harrcir":"⥈","harr":"↔","hArr":"⇔","harrw":"↭","Hat":"^","hbar":"ℏ","Hcirc":"Ĥ","hcirc":"ĥ","hearts":"♥","heartsuit":"♥","hellip":"…","hercon":"⊹","hfr":"𝔥","Hfr":"ℌ","HilbertSpace":"ℋ","hksearow":"⤥","hkswarow":"⤦","hoarr":"⇿","homtht":"∻","hookleftarrow":"↩","hookrightarrow":"↪","hopf":"𝕙","Hopf":"ℍ","horbar":"―","HorizontalLine":"─","hscr":"𝒽","Hscr":"ℋ","hslash":"ℏ","Hstrok":"Ħ","hstrok":"ħ","HumpDownHump":"≎","HumpEqual":"≏","hybull":"⁃","hyphen":"‐","Iacute":"Í","iacute":"í","ic":"⁣","Icirc":"Î","icirc":"î","Icy":"И","icy":"и","Idot":"İ","IEcy":"Е","iecy":"е","iexcl":"¡","iff":"⇔","ifr":"𝔦","Ifr":"ℑ","Igrave":"Ì","igrave":"ì","ii":"ⅈ","iiiint":"⨌","iiint":"∭","iinfin":"⧜","iiota":"℩","IJlig":"IJ","ijlig":"ij","Imacr":"Ī","imacr":"ī","image":"ℑ","ImaginaryI":"ⅈ","imagline":"ℐ","imagpart":"ℑ","imath":"ı","Im":"ℑ","imof":"⊷","imped":"Ƶ","Implies":"⇒","incare":"℅","in":"∈","infin":"∞","infintie":"⧝","inodot":"ı","intcal":"⊺","int":"∫","Int":"∬","integers":"ℤ","Integral":"∫","intercal":"⊺","Intersection":"⋂","intlarhk":"⨗","intprod":"⨼","InvisibleComma":"⁣","InvisibleTimes":"⁢","IOcy":"Ё","iocy":"ё","Iogon":"Į","iogon":"į","Iopf":"𝕀","iopf":"𝕚","Iota":"Ι","iota":"ι","iprod":"⨼","iquest":"¿","iscr":"𝒾","Iscr":"ℐ","isin":"∈","isindot":"⋵","isinE":"⋹","isins":"⋴","isinsv":"⋳","isinv":"∈","it":"⁢","Itilde":"Ĩ","itilde":"ĩ","Iukcy":"І","iukcy":"і","Iuml":"Ï","iuml":"ï","Jcirc":"Ĵ","jcirc":"ĵ","Jcy":"Й","jcy":"й","Jfr":"𝔍","jfr":"𝔧","jmath":"ȷ","Jopf":"𝕁","jopf":"𝕛","Jscr":"𝒥","jscr":"𝒿","Jsercy":"Ј","jsercy":"ј","Jukcy":"Є","jukcy":"є","Kappa":"Κ","kappa":"κ","kappav":"ϰ","Kcedil":"Ķ","kcedil":"ķ","Kcy":"К","kcy":"к","Kfr":"𝔎","kfr":"𝔨","kgreen":"ĸ","KHcy":"Х","khcy":"х","KJcy":"Ќ","kjcy":"ќ","Kopf":"𝕂","kopf":"𝕜","Kscr":"𝒦","kscr":"𝓀","lAarr":"⇚","Lacute":"Ĺ","lacute":"ĺ","laemptyv":"⦴","lagran":"ℒ","Lambda":"Λ","lambda":"λ","lang":"⟨","Lang":"⟪","langd":"⦑","langle":"⟨","lap":"⪅","Laplacetrf":"ℒ","laquo":"«","larrb":"⇤","larrbfs":"⤟","larr":"←","Larr":"↞","lArr":"⇐","larrfs":"⤝","larrhk":"↩","larrlp":"↫","larrpl":"⤹","larrsim":"⥳","larrtl":"↢","latail":"⤙","lAtail":"⤛","lat":"⪫","late":"⪭","lates":"⪭︀","lbarr":"⤌","lBarr":"⤎","lbbrk":"❲","lbrace":"{","lbrack":"[","lbrke":"⦋","lbrksld":"⦏","lbrkslu":"⦍","Lcaron":"Ľ","lcaron":"ľ","Lcedil":"Ļ","lcedil":"ļ","lceil":"⌈","lcub":"{","Lcy":"Л","lcy":"л","ldca":"⤶","ldquo":"“","ldquor":"„","ldrdhar":"⥧","ldrushar":"⥋","ldsh":"↲","le":"≤","lE":"≦","LeftAngleBracket":"⟨","LeftArrowBar":"⇤","leftarrow":"←","LeftArrow":"←","Leftarrow":"⇐","LeftArrowRightArrow":"⇆","leftarrowtail":"↢","LeftCeiling":"⌈","LeftDoubleBracket":"⟦","LeftDownTeeVector":"⥡","LeftDownVectorBar":"⥙","LeftDownVector":"⇃","LeftFloor":"⌊","leftharpoondown":"↽","leftharpoonup":"↼","leftleftarrows":"⇇","leftrightarrow":"↔","LeftRightArrow":"↔","Leftrightarrow":"⇔","leftrightarrows":"⇆","leftrightharpoons":"⇋","leftrightsquigarrow":"↭","LeftRightVector":"⥎","LeftTeeArrow":"↤","LeftTee":"⊣","LeftTeeVector":"⥚","leftthreetimes":"⋋","LeftTriangleBar":"⧏","LeftTriangle":"⊲","LeftTriangleEqual":"⊴","LeftUpDownVector":"⥑","LeftUpTeeVector":"⥠","LeftUpVectorBar":"⥘","LeftUpVector":"↿","LeftVectorBar":"⥒","LeftVector":"↼","lEg":"⪋","leg":"⋚","leq":"≤","leqq":"≦","leqslant":"⩽","lescc":"⪨","les":"⩽","lesdot":"⩿","lesdoto":"⪁","lesdotor":"⪃","lesg":"⋚︀","lesges":"⪓","lessapprox":"⪅","lessdot":"⋖","lesseqgtr":"⋚","lesseqqgtr":"⪋","LessEqualGreater":"⋚","LessFullEqual":"≦","LessGreater":"≶","lessgtr":"≶","LessLess":"⪡","lesssim":"≲","LessSlantEqual":"⩽","LessTilde":"≲","lfisht":"⥼","lfloor":"⌊","Lfr":"𝔏","lfr":"𝔩","lg":"≶","lgE":"⪑","lHar":"⥢","lhard":"↽","lharu":"↼","lharul":"⥪","lhblk":"▄","LJcy":"Љ","ljcy":"љ","llarr":"⇇","ll":"≪","Ll":"⋘","llcorner":"⌞","Lleftarrow":"⇚","llhard":"⥫","lltri":"◺","Lmidot":"Ŀ","lmidot":"ŀ","lmoustache":"⎰","lmoust":"⎰","lnap":"⪉","lnapprox":"⪉","lne":"⪇","lnE":"≨","lneq":"⪇","lneqq":"≨","lnsim":"⋦","loang":"⟬","loarr":"⇽","lobrk":"⟦","longleftarrow":"⟵","LongLeftArrow":"⟵","Longleftarrow":"⟸","longleftrightarrow":"⟷","LongLeftRightArrow":"⟷","Longleftrightarrow":"⟺","longmapsto":"⟼","longrightarrow":"⟶","LongRightArrow":"⟶","Longrightarrow":"⟹","looparrowleft":"↫","looparrowright":"↬","lopar":"⦅","Lopf":"𝕃","lopf":"𝕝","loplus":"⨭","lotimes":"⨴","lowast":"∗","lowbar":"_","LowerLeftArrow":"↙","LowerRightArrow":"↘","loz":"◊","lozenge":"◊","lozf":"⧫","lpar":"(","lparlt":"⦓","lrarr":"⇆","lrcorner":"⌟","lrhar":"⇋","lrhard":"⥭","lrm":"‎","lrtri":"⊿","lsaquo":"‹","lscr":"𝓁","Lscr":"ℒ","lsh":"↰","Lsh":"↰","lsim":"≲","lsime":"⪍","lsimg":"⪏","lsqb":"[","lsquo":"‘","lsquor":"‚","Lstrok":"Ł","lstrok":"ł","ltcc":"⪦","ltcir":"⩹","lt":"<","LT":"<","Lt":"≪","ltdot":"⋖","lthree":"⋋","ltimes":"⋉","ltlarr":"⥶","ltquest":"⩻","ltri":"◃","ltrie":"⊴","ltrif":"◂","ltrPar":"⦖","lurdshar":"⥊","luruhar":"⥦","lvertneqq":"≨︀","lvnE":"≨︀","macr":"¯","male":"♂","malt":"✠","maltese":"✠","Map":"⤅","map":"↦","mapsto":"↦","mapstodown":"↧","mapstoleft":"↤","mapstoup":"↥","marker":"▮","mcomma":"⨩","Mcy":"М","mcy":"м","mdash":"—","mDDot":"∺","measuredangle":"∡","MediumSpace":" ","Mellintrf":"ℳ","Mfr":"𝔐","mfr":"𝔪","mho":"℧","micro":"µ","midast":"*","midcir":"⫰","mid":"∣","middot":"·","minusb":"⊟","minus":"−","minusd":"∸","minusdu":"⨪","MinusPlus":"∓","mlcp":"⫛","mldr":"…","mnplus":"∓","models":"⊧","Mopf":"𝕄","mopf":"𝕞","mp":"∓","mscr":"𝓂","Mscr":"ℳ","mstpos":"∾","Mu":"Μ","mu":"μ","multimap":"⊸","mumap":"⊸","nabla":"∇","Nacute":"Ń","nacute":"ń","nang":"∠⃒","nap":"≉","napE":"⩰̸","napid":"≋̸","napos":"ʼn","napprox":"≉","natural":"♮","naturals":"ℕ","natur":"♮","nbsp":" ","nbump":"≎̸","nbumpe":"≏̸","ncap":"⩃","Ncaron":"Ň","ncaron":"ň","Ncedil":"Ņ","ncedil":"ņ","ncong":"≇","ncongdot":"⩭̸","ncup":"⩂","Ncy":"Н","ncy":"н","ndash":"–","nearhk":"⤤","nearr":"↗","neArr":"⇗","nearrow":"↗","ne":"≠","nedot":"≐̸","NegativeMediumSpace":"​","NegativeThickSpace":"​","NegativeThinSpace":"​","NegativeVeryThinSpace":"​","nequiv":"≢","nesear":"⤨","nesim":"≂̸","NestedGreaterGreater":"≫","NestedLessLess":"≪","NewLine":"\n","nexist":"∄","nexists":"∄","Nfr":"𝔑","nfr":"𝔫","ngE":"≧̸","nge":"≱","ngeq":"≱","ngeqq":"≧̸","ngeqslant":"⩾̸","nges":"⩾̸","nGg":"⋙̸","ngsim":"≵","nGt":"≫⃒","ngt":"≯","ngtr":"≯","nGtv":"≫̸","nharr":"↮","nhArr":"⇎","nhpar":"⫲","ni":"∋","nis":"⋼","nisd":"⋺","niv":"∋","NJcy":"Њ","njcy":"њ","nlarr":"↚","nlArr":"⇍","nldr":"‥","nlE":"≦̸","nle":"≰","nleftarrow":"↚","nLeftarrow":"⇍","nleftrightarrow":"↮","nLeftrightarrow":"⇎","nleq":"≰","nleqq":"≦̸","nleqslant":"⩽̸","nles":"⩽̸","nless":"≮","nLl":"⋘̸","nlsim":"≴","nLt":"≪⃒","nlt":"≮","nltri":"⋪","nltrie":"⋬","nLtv":"≪̸","nmid":"∤","NoBreak":"⁠","NonBreakingSpace":" ","nopf":"𝕟","Nopf":"ℕ","Not":"⫬","not":"¬","NotCongruent":"≢","NotCupCap":"≭","NotDoubleVerticalBar":"∦","NotElement":"∉","NotEqual":"≠","NotEqualTilde":"≂̸","NotExists":"∄","NotGreater":"≯","NotGreaterEqual":"≱","NotGreaterFullEqual":"≧̸","NotGreaterGreater":"≫̸","NotGreaterLess":"≹","NotGreaterSlantEqual":"⩾̸","NotGreaterTilde":"≵","NotHumpDownHump":"≎̸","NotHumpEqual":"≏̸","notin":"∉","notindot":"⋵̸","notinE":"⋹̸","notinva":"∉","notinvb":"⋷","notinvc":"⋶","NotLeftTriangleBar":"⧏̸","NotLeftTriangle":"⋪","NotLeftTriangleEqual":"⋬","NotLess":"≮","NotLessEqual":"≰","NotLessGreater":"≸","NotLessLess":"≪̸","NotLessSlantEqual":"⩽̸","NotLessTilde":"≴","NotNestedGreaterGreater":"⪢̸","NotNestedLessLess":"⪡̸","notni":"∌","notniva":"∌","notnivb":"⋾","notnivc":"⋽","NotPrecedes":"⊀","NotPrecedesEqual":"⪯̸","NotPrecedesSlantEqual":"⋠","NotReverseElement":"∌","NotRightTriangleBar":"⧐̸","NotRightTriangle":"⋫","NotRightTriangleEqual":"⋭","NotSquareSubset":"⊏̸","NotSquareSubsetEqual":"⋢","NotSquareSuperset":"⊐̸","NotSquareSupersetEqual":"⋣","NotSubset":"⊂⃒","NotSubsetEqual":"⊈","NotSucceeds":"⊁","NotSucceedsEqual":"⪰̸","NotSucceedsSlantEqual":"⋡","NotSucceedsTilde":"≿̸","NotSuperset":"⊃⃒","NotSupersetEqual":"⊉","NotTilde":"≁","NotTildeEqual":"≄","NotTildeFullEqual":"≇","NotTildeTilde":"≉","NotVerticalBar":"∤","nparallel":"∦","npar":"∦","nparsl":"⫽⃥","npart":"∂̸","npolint":"⨔","npr":"⊀","nprcue":"⋠","nprec":"⊀","npreceq":"⪯̸","npre":"⪯̸","nrarrc":"⤳̸","nrarr":"↛","nrArr":"⇏","nrarrw":"↝̸","nrightarrow":"↛","nRightarrow":"⇏","nrtri":"⋫","nrtrie":"⋭","nsc":"⊁","nsccue":"⋡","nsce":"⪰̸","Nscr":"𝒩","nscr":"𝓃","nshortmid":"∤","nshortparallel":"∦","nsim":"≁","nsime":"≄","nsimeq":"≄","nsmid":"∤","nspar":"∦","nsqsube":"⋢","nsqsupe":"⋣","nsub":"⊄","nsubE":"⫅̸","nsube":"⊈","nsubset":"⊂⃒","nsubseteq":"⊈","nsubseteqq":"⫅̸","nsucc":"⊁","nsucceq":"⪰̸","nsup":"⊅","nsupE":"⫆̸","nsupe":"⊉","nsupset":"⊃⃒","nsupseteq":"⊉","nsupseteqq":"⫆̸","ntgl":"≹","Ntilde":"Ñ","ntilde":"ñ","ntlg":"≸","ntriangleleft":"⋪","ntrianglelefteq":"⋬","ntriangleright":"⋫","ntrianglerighteq":"⋭","Nu":"Ν","nu":"ν","num":"#","numero":"№","numsp":" ","nvap":"≍⃒","nvdash":"⊬","nvDash":"⊭","nVdash":"⊮","nVDash":"⊯","nvge":"≥⃒","nvgt":">⃒","nvHarr":"⤄","nvinfin":"⧞","nvlArr":"⤂","nvle":"≤⃒","nvlt":"<⃒","nvltrie":"⊴⃒","nvrArr":"⤃","nvrtrie":"⊵⃒","nvsim":"∼⃒","nwarhk":"⤣","nwarr":"↖","nwArr":"⇖","nwarrow":"↖","nwnear":"⤧","Oacute":"Ó","oacute":"ó","oast":"⊛","Ocirc":"Ô","ocirc":"ô","ocir":"⊚","Ocy":"О","ocy":"о","odash":"⊝","Odblac":"Ő","odblac":"ő","odiv":"⨸","odot":"⊙","odsold":"⦼","OElig":"Œ","oelig":"œ","ofcir":"⦿","Ofr":"𝔒","ofr":"𝔬","ogon":"˛","Ograve":"Ò","ograve":"ò","ogt":"⧁","ohbar":"⦵","ohm":"Ω","oint":"∮","olarr":"↺","olcir":"⦾","olcross":"⦻","oline":"‾","olt":"⧀","Omacr":"Ō","omacr":"ō","Omega":"Ω","omega":"ω","Omicron":"Ο","omicron":"ο","omid":"⦶","ominus":"⊖","Oopf":"𝕆","oopf":"𝕠","opar":"⦷","OpenCurlyDoubleQuote":"“","OpenCurlyQuote":"‘","operp":"⦹","oplus":"⊕","orarr":"↻","Or":"⩔","or":"∨","ord":"⩝","order":"ℴ","orderof":"ℴ","ordf":"ª","ordm":"º","origof":"⊶","oror":"⩖","orslope":"⩗","orv":"⩛","oS":"Ⓢ","Oscr":"𝒪","oscr":"ℴ","Oslash":"Ø","oslash":"ø","osol":"⊘","Otilde":"Õ","otilde":"õ","otimesas":"⨶","Otimes":"⨷","otimes":"⊗","Ouml":"Ö","ouml":"ö","ovbar":"⌽","OverBar":"‾","OverBrace":"⏞","OverBracket":"⎴","OverParenthesis":"⏜","para":"¶","parallel":"∥","par":"∥","parsim":"⫳","parsl":"⫽","part":"∂","PartialD":"∂","Pcy":"П","pcy":"п","percnt":"%","period":".","permil":"‰","perp":"⊥","pertenk":"‱","Pfr":"𝔓","pfr":"𝔭","Phi":"Φ","phi":"φ","phiv":"ϕ","phmmat":"ℳ","phone":"☎","Pi":"Π","pi":"π","pitchfork":"⋔","piv":"ϖ","planck":"ℏ","planckh":"ℎ","plankv":"ℏ","plusacir":"⨣","plusb":"⊞","pluscir":"⨢","plus":"+","plusdo":"∔","plusdu":"⨥","pluse":"⩲","PlusMinus":"±","plusmn":"±","plussim":"⨦","plustwo":"⨧","pm":"±","Poincareplane":"ℌ","pointint":"⨕","popf":"𝕡","Popf":"ℙ","pound":"£","prap":"⪷","Pr":"⪻","pr":"≺","prcue":"≼","precapprox":"⪷","prec":"≺","preccurlyeq":"≼","Precedes":"≺","PrecedesEqual":"⪯","PrecedesSlantEqual":"≼","PrecedesTilde":"≾","preceq":"⪯","precnapprox":"⪹","precneqq":"⪵","precnsim":"⋨","pre":"⪯","prE":"⪳","precsim":"≾","prime":"′","Prime":"″","primes":"ℙ","prnap":"⪹","prnE":"⪵","prnsim":"⋨","prod":"∏","Product":"∏","profalar":"⌮","profline":"⌒","profsurf":"⌓","prop":"∝","Proportional":"∝","Proportion":"∷","propto":"∝","prsim":"≾","prurel":"⊰","Pscr":"𝒫","pscr":"𝓅","Psi":"Ψ","psi":"ψ","puncsp":" ","Qfr":"𝔔","qfr":"𝔮","qint":"⨌","qopf":"𝕢","Qopf":"ℚ","qprime":"⁗","Qscr":"𝒬","qscr":"𝓆","quaternions":"ℍ","quatint":"⨖","quest":"?","questeq":"≟","quot":"\"","QUOT":"\"","rAarr":"⇛","race":"∽̱","Racute":"Ŕ","racute":"ŕ","radic":"√","raemptyv":"⦳","rang":"⟩","Rang":"⟫","rangd":"⦒","range":"⦥","rangle":"⟩","raquo":"»","rarrap":"⥵","rarrb":"⇥","rarrbfs":"⤠","rarrc":"⤳","rarr":"→","Rarr":"↠","rArr":"⇒","rarrfs":"⤞","rarrhk":"↪","rarrlp":"↬","rarrpl":"⥅","rarrsim":"⥴","Rarrtl":"⤖","rarrtl":"↣","rarrw":"↝","ratail":"⤚","rAtail":"⤜","ratio":"∶","rationals":"ℚ","rbarr":"⤍","rBarr":"⤏","RBarr":"⤐","rbbrk":"❳","rbrace":"}","rbrack":"]","rbrke":"⦌","rbrksld":"⦎","rbrkslu":"⦐","Rcaron":"Ř","rcaron":"ř","Rcedil":"Ŗ","rcedil":"ŗ","rceil":"⌉","rcub":"}","Rcy":"Р","rcy":"р","rdca":"⤷","rdldhar":"⥩","rdquo":"”","rdquor":"”","rdsh":"↳","real":"ℜ","realine":"ℛ","realpart":"ℜ","reals":"ℝ","Re":"ℜ","rect":"▭","reg":"®","REG":"®","ReverseElement":"∋","ReverseEquilibrium":"⇋","ReverseUpEquilibrium":"⥯","rfisht":"⥽","rfloor":"⌋","rfr":"𝔯","Rfr":"ℜ","rHar":"⥤","rhard":"⇁","rharu":"⇀","rharul":"⥬","Rho":"Ρ","rho":"ρ","rhov":"ϱ","RightAngleBracket":"⟩","RightArrowBar":"⇥","rightarrow":"→","RightArrow":"→","Rightarrow":"⇒","RightArrowLeftArrow":"⇄","rightarrowtail":"↣","RightCeiling":"⌉","RightDoubleBracket":"⟧","RightDownTeeVector":"⥝","RightDownVectorBar":"⥕","RightDownVector":"⇂","RightFloor":"⌋","rightharpoondown":"⇁","rightharpoonup":"⇀","rightleftarrows":"⇄","rightleftharpoons":"⇌","rightrightarrows":"⇉","rightsquigarrow":"↝","RightTeeArrow":"↦","RightTee":"⊢","RightTeeVector":"⥛","rightthreetimes":"⋌","RightTriangleBar":"⧐","RightTriangle":"⊳","RightTriangleEqual":"⊵","RightUpDownVector":"⥏","RightUpTeeVector":"⥜","RightUpVectorBar":"⥔","RightUpVector":"↾","RightVectorBar":"⥓","RightVector":"⇀","ring":"˚","risingdotseq":"≓","rlarr":"⇄","rlhar":"⇌","rlm":"‏","rmoustache":"⎱","rmoust":"⎱","rnmid":"⫮","roang":"⟭","roarr":"⇾","robrk":"⟧","ropar":"⦆","ropf":"𝕣","Ropf":"ℝ","roplus":"⨮","rotimes":"⨵","RoundImplies":"⥰","rpar":")","rpargt":"⦔","rppolint":"⨒","rrarr":"⇉","Rrightarrow":"⇛","rsaquo":"›","rscr":"𝓇","Rscr":"ℛ","rsh":"↱","Rsh":"↱","rsqb":"]","rsquo":"’","rsquor":"’","rthree":"⋌","rtimes":"⋊","rtri":"▹","rtrie":"⊵","rtrif":"▸","rtriltri":"⧎","RuleDelayed":"⧴","ruluhar":"⥨","rx":"℞","Sacute":"Ś","sacute":"ś","sbquo":"‚","scap":"⪸","Scaron":"Š","scaron":"š","Sc":"⪼","sc":"≻","sccue":"≽","sce":"⪰","scE":"⪴","Scedil":"Ş","scedil":"ş","Scirc":"Ŝ","scirc":"ŝ","scnap":"⪺","scnE":"⪶","scnsim":"⋩","scpolint":"⨓","scsim":"≿","Scy":"С","scy":"с","sdotb":"⊡","sdot":"⋅","sdote":"⩦","searhk":"⤥","searr":"↘","seArr":"⇘","searrow":"↘","sect":"§","semi":";","seswar":"⤩","setminus":"∖","setmn":"∖","sext":"✶","Sfr":"𝔖","sfr":"𝔰","sfrown":"⌢","sharp":"♯","SHCHcy":"Щ","shchcy":"щ","SHcy":"Ш","shcy":"ш","ShortDownArrow":"↓","ShortLeftArrow":"←","shortmid":"∣","shortparallel":"∥","ShortRightArrow":"→","ShortUpArrow":"↑","shy":"­","Sigma":"Σ","sigma":"σ","sigmaf":"ς","sigmav":"ς","sim":"∼","simdot":"⩪","sime":"≃","simeq":"≃","simg":"⪞","simgE":"⪠","siml":"⪝","simlE":"⪟","simne":"≆","simplus":"⨤","simrarr":"⥲","slarr":"←","SmallCircle":"∘","smallsetminus":"∖","smashp":"⨳","smeparsl":"⧤","smid":"∣","smile":"⌣","smt":"⪪","smte":"⪬","smtes":"⪬︀","SOFTcy":"Ь","softcy":"ь","solbar":"⌿","solb":"⧄","sol":"/","Sopf":"𝕊","sopf":"𝕤","spades":"♠","spadesuit":"♠","spar":"∥","sqcap":"⊓","sqcaps":"⊓︀","sqcup":"⊔","sqcups":"⊔︀","Sqrt":"√","sqsub":"⊏","sqsube":"⊑","sqsubset":"⊏","sqsubseteq":"⊑","sqsup":"⊐","sqsupe":"⊒","sqsupset":"⊐","sqsupseteq":"⊒","square":"□","Square":"□","SquareIntersection":"⊓","SquareSubset":"⊏","SquareSubsetEqual":"⊑","SquareSuperset":"⊐","SquareSupersetEqual":"⊒","SquareUnion":"⊔","squarf":"▪","squ":"□","squf":"▪","srarr":"→","Sscr":"𝒮","sscr":"𝓈","ssetmn":"∖","ssmile":"⌣","sstarf":"⋆","Star":"⋆","star":"☆","starf":"★","straightepsilon":"ϵ","straightphi":"ϕ","strns":"¯","sub":"⊂","Sub":"⋐","subdot":"⪽","subE":"⫅","sube":"⊆","subedot":"⫃","submult":"⫁","subnE":"⫋","subne":"⊊","subplus":"⪿","subrarr":"⥹","subset":"⊂","Subset":"⋐","subseteq":"⊆","subseteqq":"⫅","SubsetEqual":"⊆","subsetneq":"⊊","subsetneqq":"⫋","subsim":"⫇","subsub":"⫕","subsup":"⫓","succapprox":"⪸","succ":"≻","succcurlyeq":"≽","Succeeds":"≻","SucceedsEqual":"⪰","SucceedsSlantEqual":"≽","SucceedsTilde":"≿","succeq":"⪰","succnapprox":"⪺","succneqq":"⪶","succnsim":"⋩","succsim":"≿","SuchThat":"∋","sum":"∑","Sum":"∑","sung":"♪","sup1":"¹","sup2":"²","sup3":"³","sup":"⊃","Sup":"⋑","supdot":"⪾","supdsub":"⫘","supE":"⫆","supe":"⊇","supedot":"⫄","Superset":"⊃","SupersetEqual":"⊇","suphsol":"⟉","suphsub":"⫗","suplarr":"⥻","supmult":"⫂","supnE":"⫌","supne":"⊋","supplus":"⫀","supset":"⊃","Supset":"⋑","supseteq":"⊇","supseteqq":"⫆","supsetneq":"⊋","supsetneqq":"⫌","supsim":"⫈","supsub":"⫔","supsup":"⫖","swarhk":"⤦","swarr":"↙","swArr":"⇙","swarrow":"↙","swnwar":"⤪","szlig":"ß","Tab":"\t","target":"⌖","Tau":"Τ","tau":"τ","tbrk":"⎴","Tcaron":"Ť","tcaron":"ť","Tcedil":"Ţ","tcedil":"ţ","Tcy":"Т","tcy":"т","tdot":"⃛","telrec":"⌕","Tfr":"𝔗","tfr":"𝔱","there4":"∴","therefore":"∴","Therefore":"∴","Theta":"Θ","theta":"θ","thetasym":"ϑ","thetav":"ϑ","thickapprox":"≈","thicksim":"∼","ThickSpace":"  ","ThinSpace":" ","thinsp":" ","thkap":"≈","thksim":"∼","THORN":"Þ","thorn":"þ","tilde":"˜","Tilde":"∼","TildeEqual":"≃","TildeFullEqual":"≅","TildeTilde":"≈","timesbar":"⨱","timesb":"⊠","times":"×","timesd":"⨰","tint":"∭","toea":"⤨","topbot":"⌶","topcir":"⫱","top":"⊤","Topf":"𝕋","topf":"𝕥","topfork":"⫚","tosa":"⤩","tprime":"‴","trade":"™","TRADE":"™","triangle":"▵","triangledown":"▿","triangleleft":"◃","trianglelefteq":"⊴","triangleq":"≜","triangleright":"▹","trianglerighteq":"⊵","tridot":"◬","trie":"≜","triminus":"⨺","TripleDot":"⃛","triplus":"⨹","trisb":"⧍","tritime":"⨻","trpezium":"⏢","Tscr":"𝒯","tscr":"𝓉","TScy":"Ц","tscy":"ц","TSHcy":"Ћ","tshcy":"ћ","Tstrok":"Ŧ","tstrok":"ŧ","twixt":"≬","twoheadleftarrow":"↞","twoheadrightarrow":"↠","Uacute":"Ú","uacute":"ú","uarr":"↑","Uarr":"↟","uArr":"⇑","Uarrocir":"⥉","Ubrcy":"Ў","ubrcy":"ў","Ubreve":"Ŭ","ubreve":"ŭ","Ucirc":"Û","ucirc":"û","Ucy":"У","ucy":"у","udarr":"⇅","Udblac":"Ű","udblac":"ű","udhar":"⥮","ufisht":"⥾","Ufr":"𝔘","ufr":"𝔲","Ugrave":"Ù","ugrave":"ù","uHar":"⥣","uharl":"↿","uharr":"↾","uhblk":"▀","ulcorn":"⌜","ulcorner":"⌜","ulcrop":"⌏","ultri":"◸","Umacr":"Ū","umacr":"ū","uml":"¨","UnderBar":"_","UnderBrace":"⏟","UnderBracket":"⎵","UnderParenthesis":"⏝","Union":"⋃","UnionPlus":"⊎","Uogon":"Ų","uogon":"ų","Uopf":"𝕌","uopf":"𝕦","UpArrowBar":"⤒","uparrow":"↑","UpArrow":"↑","Uparrow":"⇑","UpArrowDownArrow":"⇅","updownarrow":"↕","UpDownArrow":"↕","Updownarrow":"⇕","UpEquilibrium":"⥮","upharpoonleft":"↿","upharpoonright":"↾","uplus":"⊎","UpperLeftArrow":"↖","UpperRightArrow":"↗","upsi":"υ","Upsi":"ϒ","upsih":"ϒ","Upsilon":"Υ","upsilon":"υ","UpTeeArrow":"↥","UpTee":"⊥","upuparrows":"⇈","urcorn":"⌝","urcorner":"⌝","urcrop":"⌎","Uring":"Ů","uring":"ů","urtri":"◹","Uscr":"𝒰","uscr":"𝓊","utdot":"⋰","Utilde":"Ũ","utilde":"ũ","utri":"▵","utrif":"▴","uuarr":"⇈","Uuml":"Ü","uuml":"ü","uwangle":"⦧","vangrt":"⦜","varepsilon":"ϵ","varkappa":"ϰ","varnothing":"∅","varphi":"ϕ","varpi":"ϖ","varpropto":"∝","varr":"↕","vArr":"⇕","varrho":"ϱ","varsigma":"ς","varsubsetneq":"⊊︀","varsubsetneqq":"⫋︀","varsupsetneq":"⊋︀","varsupsetneqq":"⫌︀","vartheta":"ϑ","vartriangleleft":"⊲","vartriangleright":"⊳","vBar":"⫨","Vbar":"⫫","vBarv":"⫩","Vcy":"В","vcy":"в","vdash":"⊢","vDash":"⊨","Vdash":"⊩","VDash":"⊫","Vdashl":"⫦","veebar":"⊻","vee":"∨","Vee":"⋁","veeeq":"≚","vellip":"⋮","verbar":"|","Verbar":"‖","vert":"|","Vert":"‖","VerticalBar":"∣","VerticalLine":"|","VerticalSeparator":"❘","VerticalTilde":"≀","VeryThinSpace":" ","Vfr":"𝔙","vfr":"𝔳","vltri":"⊲","vnsub":"⊂⃒","vnsup":"⊃⃒","Vopf":"𝕍","vopf":"𝕧","vprop":"∝","vrtri":"⊳","Vscr":"𝒱","vscr":"𝓋","vsubnE":"⫋︀","vsubne":"⊊︀","vsupnE":"⫌︀","vsupne":"⊋︀","Vvdash":"⊪","vzigzag":"⦚","Wcirc":"Ŵ","wcirc":"ŵ","wedbar":"⩟","wedge":"∧","Wedge":"⋀","wedgeq":"≙","weierp":"℘","Wfr":"𝔚","wfr":"𝔴","Wopf":"𝕎","wopf":"𝕨","wp":"℘","wr":"≀","wreath":"≀","Wscr":"𝒲","wscr":"𝓌","xcap":"⋂","xcirc":"◯","xcup":"⋃","xdtri":"▽","Xfr":"𝔛","xfr":"𝔵","xharr":"⟷","xhArr":"⟺","Xi":"Ξ","xi":"ξ","xlarr":"⟵","xlArr":"⟸","xmap":"⟼","xnis":"⋻","xodot":"⨀","Xopf":"𝕏","xopf":"𝕩","xoplus":"⨁","xotime":"⨂","xrarr":"⟶","xrArr":"⟹","Xscr":"𝒳","xscr":"𝓍","xsqcup":"⨆","xuplus":"⨄","xutri":"△","xvee":"⋁","xwedge":"⋀","Yacute":"Ý","yacute":"ý","YAcy":"Я","yacy":"я","Ycirc":"Ŷ","ycirc":"ŷ","Ycy":"Ы","ycy":"ы","yen":"¥","Yfr":"𝔜","yfr":"𝔶","YIcy":"Ї","yicy":"ї","Yopf":"𝕐","yopf":"𝕪","Yscr":"𝒴","yscr":"𝓎","YUcy":"Ю","yucy":"ю","yuml":"ÿ","Yuml":"Ÿ","Zacute":"Ź","zacute":"ź","Zcaron":"Ž","zcaron":"ž","Zcy":"З","zcy":"з","Zdot":"Ż","zdot":"ż","zeetrf":"ℨ","ZeroWidthSpace":"​","Zeta":"Ζ","zeta":"ζ","zfr":"𝔷","Zfr":"ℨ","ZHcy":"Ж","zhcy":"ж","zigrarr":"⇝","zopf":"𝕫","Zopf":"ℤ","Zscr":"𝒵","zscr":"𝓏","zwj":"‍","zwnj":"‌"}
43029
 
43030
  /***/ },
43031
- /* 458 */
43032
  /***/ function(module, exports) {
43033
 
43034
  module.exports = {"Aacute":"Á","aacute":"á","Acirc":"Â","acirc":"â","acute":"´","AElig":"Æ","aelig":"æ","Agrave":"À","agrave":"à","amp":"&","AMP":"&","Aring":"Å","aring":"å","Atilde":"Ã","atilde":"ã","Auml":"Ä","auml":"ä","brvbar":"¦","Ccedil":"Ç","ccedil":"ç","cedil":"¸","cent":"¢","copy":"©","COPY":"©","curren":"¤","deg":"°","divide":"÷","Eacute":"É","eacute":"é","Ecirc":"Ê","ecirc":"ê","Egrave":"È","egrave":"è","ETH":"Ð","eth":"ð","Euml":"Ë","euml":"ë","frac12":"½","frac14":"¼","frac34":"¾","gt":">","GT":">","Iacute":"Í","iacute":"í","Icirc":"Î","icirc":"î","iexcl":"¡","Igrave":"Ì","igrave":"ì","iquest":"¿","Iuml":"Ï","iuml":"ï","laquo":"«","lt":"<","LT":"<","macr":"¯","micro":"µ","middot":"·","nbsp":" ","not":"¬","Ntilde":"Ñ","ntilde":"ñ","Oacute":"Ó","oacute":"ó","Ocirc":"Ô","ocirc":"ô","Ograve":"Ò","ograve":"ò","ordf":"ª","ordm":"º","Oslash":"Ø","oslash":"ø","Otilde":"Õ","otilde":"õ","Ouml":"Ö","ouml":"ö","para":"¶","plusmn":"±","pound":"£","quot":"\"","QUOT":"\"","raquo":"»","reg":"®","REG":"®","sect":"§","shy":"­","sup1":"¹","sup2":"²","sup3":"³","szlig":"ß","THORN":"Þ","thorn":"þ","times":"×","Uacute":"Ú","uacute":"ú","Ucirc":"Û","ucirc":"û","Ugrave":"Ù","ugrave":"ù","uml":"¨","Uuml":"Ü","uuml":"ü","Yacute":"Ý","yacute":"ý","yen":"¥","yuml":"ÿ"}
43035
 
43036
  /***/ },
43037
- /* 459 */
43038
  /***/ function(module, exports) {
43039
 
43040
  module.exports = {"amp":"&","apos":"'","gt":">","lt":"<","quot":"\""}
43041
 
43042
  /***/ },
43043
- /* 460 */
43044
  /***/ function(module, exports) {
43045
 
43046
  if (typeof Object.create === 'function') {
@@ -43069,7 +43342,7 @@ webpackJsonp([3],[
43069
 
43070
 
43071
  /***/ },
43072
- /* 461 */
43073
  /***/ function(module, exports) {
43074
 
43075
  // Copyright Joyent, Inc. and other Node contributors.
@@ -43377,14 +43650,14 @@ webpackJsonp([3],[
43377
 
43378
 
43379
  /***/ },
43380
- /* 462 */
43381
  /***/ function(module, exports, __webpack_require__) {
43382
 
43383
- var ElementType = __webpack_require__(463);
43384
 
43385
  var re_whitespace = /\s+/g;
43386
- var NodePrototype = __webpack_require__(464);
43387
- var ElementPrototype = __webpack_require__(465);
43388
 
43389
  function DomHandler(callback, options, elementCB){
43390
  if(typeof callback === "object"){
@@ -43600,7 +43873,7 @@ webpackJsonp([3],[
43600
 
43601
 
43602
  /***/ },
43603
- /* 463 */
43604
  /***/ function(module, exports) {
43605
 
43606
  //Types of elements found in the DOM
@@ -43621,7 +43894,7 @@ webpackJsonp([3],[
43621
 
43622
 
43623
  /***/ },
43624
- /* 464 */
43625
  /***/ function(module, exports) {
43626
 
43627
  // This object will be used as the prototype for Nodes when creating a
@@ -43671,11 +43944,11 @@ webpackJsonp([3],[
43671
 
43672
 
43673
  /***/ },
43674
- /* 465 */
43675
  /***/ function(module, exports, __webpack_require__) {
43676
 
43677
  // DOM-Level-1-compliant structure
43678
- var NodePrototype = __webpack_require__(464);
43679
  var ElementPrototype = module.exports = Object.create(NodePrototype);
43680
 
43681
  var domLvl1 = {
@@ -43697,10 +43970,10 @@ webpackJsonp([3],[
43697
 
43698
 
43699
  /***/ },
43700
- /* 466 */
43701
  /***/ function(module, exports, __webpack_require__) {
43702
 
43703
- var index = __webpack_require__(452),
43704
  DomHandler = index.DomHandler,
43705
  DomUtils = index.DomUtils;
43706
 
@@ -43709,7 +43982,7 @@ webpackJsonp([3],[
43709
  this.init(callback, options);
43710
  }
43711
 
43712
- __webpack_require__(460)(FeedHandler, DomHandler);
43713
 
43714
  FeedHandler.prototype.init = DomHandler;
43715
 
@@ -43798,18 +44071,18 @@ webpackJsonp([3],[
43798
 
43799
 
43800
  /***/ },
43801
- /* 467 */
43802
  /***/ function(module, exports, __webpack_require__) {
43803
 
43804
  module.exports = Stream;
43805
 
43806
- var Parser = __webpack_require__(468);
43807
 
43808
  function Stream(options){
43809
  Parser.call(this, new Cbs(this), options);
43810
  }
43811
 
43812
- __webpack_require__(460)(Stream, Parser);
43813
 
43814
  Stream.prototype.readable = true;
43815
 
@@ -43817,7 +44090,7 @@ webpackJsonp([3],[
43817
  this.scope = scope;
43818
  }
43819
 
43820
- var EVENTS = __webpack_require__(452).EVENTS;
43821
 
43822
  Object.keys(EVENTS).forEach(function(name){
43823
  if(EVENTS[name] === 0){
@@ -43838,15 +44111,15 @@ webpackJsonp([3],[
43838
  });
43839
 
43840
  /***/ },
43841
- /* 468 */
43842
  /***/ function(module, exports, __webpack_require__) {
43843
 
43844
  module.exports = Stream;
43845
 
43846
- var Parser = __webpack_require__(453),
43847
- WritableStream = __webpack_require__(469).Writable || __webpack_require__(488).Writable,
43848
- StringDecoder = __webpack_require__(489).StringDecoder,
43849
- Buffer = __webpack_require__(473).Buffer;
43850
 
43851
  function Stream(cbs, options){
43852
  var parser = this._parser = new Parser(cbs, options);
@@ -43859,7 +44132,7 @@ webpackJsonp([3],[
43859
  });
43860
  }
43861
 
43862
- __webpack_require__(460)(Stream, WritableStream);
43863
 
43864
  WritableStream.prototype._write = function(chunk, encoding, cb){
43865
  if(chunk instanceof Buffer) chunk = this._decoder.write(chunk);
@@ -43868,7 +44141,7 @@ webpackJsonp([3],[
43868
  };
43869
 
43870
  /***/ },
43871
- /* 469 */
43872
  /***/ function(module, exports, __webpack_require__) {
43873
 
43874
  // Copyright Joyent, Inc. and other Node contributors.
@@ -43894,15 +44167,15 @@ webpackJsonp([3],[
43894
 
43895
  module.exports = Stream;
43896
 
43897
- var EE = __webpack_require__(461).EventEmitter;
43898
- var inherits = __webpack_require__(460);
43899
 
43900
  inherits(Stream, EE);
43901
- Stream.Readable = __webpack_require__(470);
43902
- Stream.Writable = __webpack_require__(484);
43903
- Stream.Duplex = __webpack_require__(485);
43904
- Stream.Transform = __webpack_require__(486);
43905
- Stream.PassThrough = __webpack_require__(487);
43906
 
43907
  // Backwards-compat with node 0.4.x
43908
  Stream.Stream = Stream;
@@ -44001,24 +44274,24 @@ webpackJsonp([3],[
44001
 
44002
 
44003
  /***/ },
44004
- /* 470 */
44005
  /***/ function(module, exports, __webpack_require__) {
44006
 
44007
- /* WEBPACK VAR INJECTION */(function(process) {exports = module.exports = __webpack_require__(471);
44008
- exports.Stream = __webpack_require__(469);
44009
  exports.Readable = exports;
44010
- exports.Writable = __webpack_require__(480);
44011
- exports.Duplex = __webpack_require__(479);
44012
- exports.Transform = __webpack_require__(482);
44013
- exports.PassThrough = __webpack_require__(483);
44014
  if (!process.browser && process.env.READABLE_STREAM === 'disable') {
44015
- module.exports = __webpack_require__(469);
44016
  }
44017
 
44018
  /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
44019
 
44020
  /***/ },
44021
- /* 471 */
44022
  /***/ function(module, exports, __webpack_require__) {
44023
 
44024
  /* WEBPACK VAR INJECTION */(function(process) {// Copyright Joyent, Inc. and other Node contributors.
@@ -44045,17 +44318,17 @@ webpackJsonp([3],[
44045
  module.exports = Readable;
44046
 
44047
  /*<replacement>*/
44048
- var isArray = __webpack_require__(472);
44049
  /*</replacement>*/
44050
 
44051
 
44052
  /*<replacement>*/
44053
- var Buffer = __webpack_require__(473).Buffer;
44054
  /*</replacement>*/
44055
 
44056
  Readable.ReadableState = ReadableState;
44057
 
44058
- var EE = __webpack_require__(461).EventEmitter;
44059
 
44060
  /*<replacement>*/
44061
  if (!EE.listenerCount) EE.listenerCount = function(emitter, type) {
@@ -44063,18 +44336,18 @@ webpackJsonp([3],[
44063
  };
44064
  /*</replacement>*/
44065
 
44066
- var Stream = __webpack_require__(469);
44067
 
44068
  /*<replacement>*/
44069
- var util = __webpack_require__(477);
44070
- util.inherits = __webpack_require__(460);
44071
  /*</replacement>*/
44072
 
44073
  var StringDecoder;
44074
 
44075
 
44076
  /*<replacement>*/
44077
- var debug = __webpack_require__(478);
44078
  if (debug && debug.debuglog) {
44079
  debug = debug.debuglog('stream');
44080
  } else {
@@ -44086,7 +44359,7 @@ webpackJsonp([3],[
44086
  util.inherits(Readable, Stream);
44087
 
44088
  function ReadableState(options, stream) {
44089
- var Duplex = __webpack_require__(479);
44090
 
44091
  options = options || {};
44092
 
@@ -44147,14 +44420,14 @@ webpackJsonp([3],[
44147
  this.encoding = null;
44148
  if (options.encoding) {
44149
  if (!StringDecoder)
44150
- StringDecoder = __webpack_require__(481).StringDecoder;
44151
  this.decoder = new StringDecoder(options.encoding);
44152
  this.encoding = options.encoding;
44153
  }
44154
  }
44155
 
44156
  function Readable(options) {
44157
- var Duplex = __webpack_require__(479);
44158
 
44159
  if (!(this instanceof Readable))
44160
  return new Readable(options);
@@ -44257,7 +44530,7 @@ webpackJsonp([3],[
44257
  // backwards compatibility.
44258
  Readable.prototype.setEncoding = function(enc) {
44259
  if (!StringDecoder)
44260
- StringDecoder = __webpack_require__(481).StringDecoder;
44261
  this._readableState.decoder = new StringDecoder(enc);
44262
  this._readableState.encoding = enc;
44263
  return this;
@@ -44976,7 +45249,7 @@ webpackJsonp([3],[
44976
  /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
44977
 
44978
  /***/ },
44979
- /* 472 */
44980
  /***/ function(module, exports) {
44981
 
44982
  module.exports = Array.isArray || function (arr) {
@@ -44985,7 +45258,7 @@ webpackJsonp([3],[
44985
 
44986
 
44987
  /***/ },
44988
- /* 473 */
44989
  /***/ function(module, exports, __webpack_require__) {
44990
 
44991
  /* WEBPACK VAR INJECTION */(function(Buffer, global) {/*!
@@ -44998,9 +45271,9 @@ webpackJsonp([3],[
44998
 
44999
  'use strict'
45000
 
45001
- var base64 = __webpack_require__(474)
45002
- var ieee754 = __webpack_require__(475)
45003
- var isArray = __webpack_require__(476)
45004
 
45005
  exports.Buffer = Buffer
45006
  exports.SlowBuffer = SlowBuffer
@@ -46778,10 +47051,10 @@ webpackJsonp([3],[
46778
  return val !== val // eslint-disable-line no-self-compare
46779
  }
46780
 
46781
- /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(473).Buffer, (function() { return this; }())))
46782
 
46783
  /***/ },
46784
- /* 474 */
46785
  /***/ function(module, exports) {
46786
 
46787
  'use strict'
@@ -46901,7 +47174,7 @@ webpackJsonp([3],[
46901
 
46902
 
46903
  /***/ },
46904
- /* 475 */
46905
  /***/ function(module, exports) {
46906
 
46907
  exports.read = function (buffer, offset, isLE, mLen, nBytes) {
@@ -46991,7 +47264,7 @@ webpackJsonp([3],[
46991
 
46992
 
46993
  /***/ },
46994
- /* 476 */
46995
  /***/ function(module, exports) {
46996
 
46997
  var toString = {}.toString;
@@ -47002,7 +47275,7 @@ webpackJsonp([3],[
47002
 
47003
 
47004
  /***/ },
47005
- /* 477 */
47006
  /***/ function(module, exports, __webpack_require__) {
47007
 
47008
  /* WEBPACK VAR INJECTION */(function(Buffer) {// Copyright Joyent, Inc. and other Node contributors.
@@ -47113,16 +47386,16 @@ webpackJsonp([3],[
47113
  return Object.prototype.toString.call(o);
47114
  }
47115
 
47116
- /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(473).Buffer))
47117
 
47118
  /***/ },
47119
- /* 478 */
47120
  /***/ function(module, exports) {
47121
 
47122
  /* (ignored) */
47123
 
47124
  /***/ },
47125
- /* 479 */
47126
  /***/ function(module, exports, __webpack_require__) {
47127
 
47128
  /* WEBPACK VAR INJECTION */(function(process) {// Copyright Joyent, Inc. and other Node contributors.
@@ -47163,12 +47436,12 @@ webpackJsonp([3],[
47163
 
47164
 
47165
  /*<replacement>*/
47166
- var util = __webpack_require__(477);
47167
- util.inherits = __webpack_require__(460);
47168
  /*</replacement>*/
47169
 
47170
- var Readable = __webpack_require__(471);
47171
- var Writable = __webpack_require__(480);
47172
 
47173
  util.inherits(Duplex, Readable);
47174
 
@@ -47218,7 +47491,7 @@ webpackJsonp([3],[
47218
  /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
47219
 
47220
  /***/ },
47221
- /* 480 */
47222
  /***/ function(module, exports, __webpack_require__) {
47223
 
47224
  /* WEBPACK VAR INJECTION */(function(process) {// Copyright Joyent, Inc. and other Node contributors.
@@ -47249,18 +47522,18 @@ webpackJsonp([3],[
47249
  module.exports = Writable;
47250
 
47251
  /*<replacement>*/
47252
- var Buffer = __webpack_require__(473).Buffer;
47253
  /*</replacement>*/
47254
 
47255
  Writable.WritableState = WritableState;
47256
 
47257
 
47258
  /*<replacement>*/
47259
- var util = __webpack_require__(477);
47260
- util.inherits = __webpack_require__(460);
47261
  /*</replacement>*/
47262
 
47263
- var Stream = __webpack_require__(469);
47264
 
47265
  util.inherits(Writable, Stream);
47266
 
@@ -47271,7 +47544,7 @@ webpackJsonp([3],[
47271
  }
47272
 
47273
  function WritableState(options, stream) {
47274
- var Duplex = __webpack_require__(479);
47275
 
47276
  options = options || {};
47277
 
@@ -47359,7 +47632,7 @@ webpackJsonp([3],[
47359
  }
47360
 
47361
  function Writable(options) {
47362
- var Duplex = __webpack_require__(479);
47363
 
47364
  // Writable ctor is applied to Duplexes, though they're not
47365
  // instanceof Writable, they're instanceof Readable.
@@ -47702,7 +47975,7 @@ webpackJsonp([3],[
47702
  /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
47703
 
47704
  /***/ },
47705
- /* 481 */
47706
  /***/ function(module, exports, __webpack_require__) {
47707
 
47708
  // Copyright Joyent, Inc. and other Node contributors.
@@ -47726,7 +47999,7 @@ webpackJsonp([3],[
47726
  // OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
47727
  // USE OR OTHER DEALINGS IN THE SOFTWARE.
47728
 
47729
- var Buffer = __webpack_require__(473).Buffer;
47730
 
47731
  var isBufferEncoding = Buffer.isEncoding
47732
  || function(encoding) {
@@ -47929,7 +48202,7 @@ webpackJsonp([3],[
47929
 
47930
 
47931
  /***/ },
47932
- /* 482 */
47933
  /***/ function(module, exports, __webpack_require__) {
47934
 
47935
  // Copyright Joyent, Inc. and other Node contributors.
@@ -47998,11 +48271,11 @@ webpackJsonp([3],[
47998
 
47999
  module.exports = Transform;
48000
 
48001
- var Duplex = __webpack_require__(479);
48002
 
48003
  /*<replacement>*/
48004
- var util = __webpack_require__(477);
48005
- util.inherits = __webpack_require__(460);
48006
  /*</replacement>*/
48007
 
48008
  util.inherits(Transform, Duplex);
@@ -48144,7 +48417,7 @@ webpackJsonp([3],[
48144
 
48145
 
48146
  /***/ },
48147
- /* 483 */
48148
  /***/ function(module, exports, __webpack_require__) {
48149
 
48150
  // Copyright Joyent, Inc. and other Node contributors.
@@ -48174,11 +48447,11 @@ webpackJsonp([3],[
48174
 
48175
  module.exports = PassThrough;
48176
 
48177
- var Transform = __webpack_require__(482);
48178
 
48179
  /*<replacement>*/
48180
- var util = __webpack_require__(477);
48181
- util.inherits = __webpack_require__(460);
48182
  /*</replacement>*/
48183
 
48184
  util.inherits(PassThrough, Transform);
@@ -48195,25 +48468,18 @@ webpackJsonp([3],[
48195
  };
48196
 
48197
 
48198
- /***/ },
48199
- /* 484 */
48200
- /***/ function(module, exports, __webpack_require__) {
48201
-
48202
- module.exports = __webpack_require__(480)
48203
-
48204
-
48205
  /***/ },
48206
  /* 485 */
48207
  /***/ function(module, exports, __webpack_require__) {
48208
 
48209
- module.exports = __webpack_require__(479)
48210
 
48211
 
48212
  /***/ },
48213
  /* 486 */
48214
  /***/ function(module, exports, __webpack_require__) {
48215
 
48216
- module.exports = __webpack_require__(482)
48217
 
48218
 
48219
  /***/ },
@@ -48225,17 +48491,24 @@ webpackJsonp([3],[
48225
 
48226
  /***/ },
48227
  /* 488 */
 
 
 
 
 
 
 
48228
  /***/ function(module, exports) {
48229
 
48230
  /* (ignored) */
48231
 
48232
  /***/ },
48233
- /* 489 */
48234
  /***/ function(module, exports, __webpack_require__) {
48235
 
48236
  'use strict';
48237
 
48238
- var Buffer = __webpack_require__(490).Buffer;
48239
 
48240
  var isEncoding = Buffer.isEncoding || function (encoding) {
48241
  encoding = '' + encoding;
@@ -48507,11 +48780,11 @@ webpackJsonp([3],[
48507
  }
48508
 
48509
  /***/ },
48510
- /* 490 */
48511
  /***/ function(module, exports, __webpack_require__) {
48512
 
48513
  /* eslint-disable node/no-deprecated-api */
48514
- var buffer = __webpack_require__(473)
48515
  var Buffer = buffer.Buffer
48516
 
48517
  // alternative to using Object.keys for old browsers
@@ -48575,7 +48848,7 @@ webpackJsonp([3],[
48575
 
48576
 
48577
  /***/ },
48578
- /* 491 */
48579
  /***/ function(module, exports, __webpack_require__) {
48580
 
48581
  module.exports = ProxyHandler;
@@ -48584,7 +48857,7 @@ webpackJsonp([3],[
48584
  this._cbs = cbs || {};
48585
  }
48586
 
48587
- var EVENTS = __webpack_require__(452).EVENTS;
48588
  Object.keys(EVENTS).forEach(function(name){
48589
  if(EVENTS[name] === 0){
48590
  name = "on" + name;
@@ -48607,18 +48880,18 @@ webpackJsonp([3],[
48607
  });
48608
 
48609
  /***/ },
48610
- /* 492 */
48611
  /***/ function(module, exports, __webpack_require__) {
48612
 
48613
  var DomUtils = module.exports;
48614
 
48615
  [
48616
- __webpack_require__(493),
48617
- __webpack_require__(499),
48618
  __webpack_require__(500),
48619
  __webpack_require__(501),
48620
  __webpack_require__(502),
48621
- __webpack_require__(503)
 
48622
  ].forEach(function(ext){
48623
  Object.keys(ext).forEach(function(key){
48624
  DomUtils[key] = ext[key].bind(DomUtils);
@@ -48627,11 +48900,11 @@ webpackJsonp([3],[
48627
 
48628
 
48629
  /***/ },
48630
- /* 493 */
48631
  /***/ function(module, exports, __webpack_require__) {
48632
 
48633
- var ElementType = __webpack_require__(463),
48634
- getOuterHTML = __webpack_require__(494),
48635
  isTag = ElementType.isTag;
48636
 
48637
  module.exports = {
@@ -48656,14 +48929,14 @@ webpackJsonp([3],[
48656
 
48657
 
48658
  /***/ },
48659
- /* 494 */
48660
  /***/ function(module, exports, __webpack_require__) {
48661
 
48662
  /*
48663
  Module dependencies
48664
  */
48665
- var ElementType = __webpack_require__(495);
48666
- var entities = __webpack_require__(496);
48667
 
48668
  /*
48669
  Boolean Attributes
@@ -48840,7 +49113,7 @@ webpackJsonp([3],[
48840
 
48841
 
48842
  /***/ },
48843
- /* 495 */
48844
  /***/ function(module, exports) {
48845
 
48846
  //Types of elements found in the DOM
@@ -48859,11 +49132,11 @@ webpackJsonp([3],[
48859
  };
48860
 
48861
  /***/ },
48862
- /* 496 */
48863
  /***/ function(module, exports, __webpack_require__) {
48864
 
48865
- var encode = __webpack_require__(497),
48866
- decode = __webpack_require__(498);
48867
 
48868
  exports.decode = function(data, level){
48869
  return (!level || level <= 0 ? decode.XML : decode.HTML)(data);
@@ -48898,15 +49171,15 @@ webpackJsonp([3],[
48898
 
48899
 
48900
  /***/ },
48901
- /* 497 */
48902
  /***/ function(module, exports, __webpack_require__) {
48903
 
48904
- var inverseXML = getInverseObj(__webpack_require__(459)),
48905
  xmlReplacer = getInverseReplacer(inverseXML);
48906
 
48907
  exports.XML = getInverse(inverseXML, xmlReplacer);
48908
 
48909
- var inverseHTML = getInverseObj(__webpack_require__(457)),
48910
  htmlReplacer = getInverseReplacer(inverseHTML);
48911
 
48912
  exports.HTML = getInverse(inverseHTML, htmlReplacer);
@@ -48977,13 +49250,13 @@ webpackJsonp([3],[
48977
 
48978
 
48979
  /***/ },
48980
- /* 498 */
48981
  /***/ function(module, exports, __webpack_require__) {
48982
 
48983
- var entityMap = __webpack_require__(457),
48984
- legacyMap = __webpack_require__(458),
48985
- xmlMap = __webpack_require__(459),
48986
- decodeCodePoint = __webpack_require__(455);
48987
 
48988
  var decodeXMLStrict = getStrictDecoder(xmlMap),
48989
  decodeHTMLStrict = getStrictDecoder(entityMap);
@@ -49054,7 +49327,7 @@ webpackJsonp([3],[
49054
  };
49055
 
49056
  /***/ },
49057
- /* 499 */
49058
  /***/ function(module, exports) {
49059
 
49060
  var getChildren = exports.getChildren = function(elem){
@@ -49084,7 +49357,7 @@ webpackJsonp([3],[
49084
 
49085
 
49086
  /***/ },
49087
- /* 500 */
49088
  /***/ function(module, exports) {
49089
 
49090
  exports.removeElement = function(elem){
@@ -49167,10 +49440,10 @@ webpackJsonp([3],[
49167
 
49168
 
49169
  /***/ },
49170
- /* 501 */
49171
  /***/ function(module, exports, __webpack_require__) {
49172
 
49173
- var isTag = __webpack_require__(463).isTag;
49174
 
49175
  module.exports = {
49176
  filter: filter,
@@ -49272,10 +49545,10 @@ webpackJsonp([3],[
49272
 
49273
 
49274
  /***/ },
49275
- /* 502 */
49276
  /***/ function(module, exports, __webpack_require__) {
49277
 
49278
- var ElementType = __webpack_require__(463);
49279
  var isTag = exports.isTag = ElementType.isTag;
49280
 
49281
  exports.testElement = function(options, element){
@@ -49365,7 +49638,7 @@ webpackJsonp([3],[
49365
 
49366
 
49367
  /***/ },
49368
- /* 503 */
49369
  /***/ function(module, exports) {
49370
 
49371
  // removeSubsets
@@ -49512,7 +49785,7 @@ webpackJsonp([3],[
49512
 
49513
 
49514
  /***/ },
49515
- /* 504 */
49516
  /***/ function(module, exports, __webpack_require__) {
49517
 
49518
  module.exports = CollectingHandler;
@@ -49522,7 +49795,7 @@ webpackJsonp([3],[
49522
  this.events = [];
49523
  }
49524
 
49525
- var EVENTS = __webpack_require__(452).EVENTS;
49526
  Object.keys(EVENTS).forEach(function(name){
49527
  if(EVENTS[name] === 0){
49528
  name = "on" + name;
@@ -49573,7 +49846,7 @@ webpackJsonp([3],[
49573
 
49574
 
49575
  /***/ },
49576
- /* 505 */
49577
  /***/ function(module, exports, __webpack_require__) {
49578
 
49579
  'use strict';
@@ -49583,7 +49856,7 @@ webpackJsonp([3],[
49583
  });
49584
  exports.default = ProcessNodes;
49585
 
49586
- var _elementTypes = __webpack_require__(506);
49587
 
49588
  var _elementTypes2 = _interopRequireDefault(_elementTypes);
49589
 
@@ -49626,7 +49899,7 @@ webpackJsonp([3],[
49626
  }
49627
 
49628
  /***/ },
49629
- /* 506 */
49630
  /***/ function(module, exports, __webpack_require__) {
49631
 
49632
  'use strict';
@@ -49637,21 +49910,21 @@ webpackJsonp([3],[
49637
 
49638
  var _ElementType$Text$Ele;
49639
 
49640
- var _htmlparser = __webpack_require__(452);
49641
 
49642
- var _TextElementType = __webpack_require__(507);
49643
 
49644
  var _TextElementType2 = _interopRequireDefault(_TextElementType);
49645
 
49646
- var _TagElementType = __webpack_require__(508);
49647
 
49648
  var _TagElementType2 = _interopRequireDefault(_TagElementType);
49649
 
49650
- var _StyleElementType = __webpack_require__(516);
49651
 
49652
  var _StyleElementType2 = _interopRequireDefault(_StyleElementType);
49653
 
49654
- var _UnsupportedElementType = __webpack_require__(517);
49655
 
49656
  var _UnsupportedElementType2 = _interopRequireDefault(_UnsupportedElementType);
49657
 
@@ -49666,7 +49939,7 @@ webpackJsonp([3],[
49666
  exports.default = (_ElementType$Text$Ele = {}, _defineProperty(_ElementType$Text$Ele, _htmlparser.ElementType.Text, _TextElementType2.default), _defineProperty(_ElementType$Text$Ele, _htmlparser.ElementType.Tag, _TagElementType2.default), _defineProperty(_ElementType$Text$Ele, _htmlparser.ElementType.Style, _StyleElementType2.default), _defineProperty(_ElementType$Text$Ele, _htmlparser.ElementType.Directive, _UnsupportedElementType2.default), _defineProperty(_ElementType$Text$Ele, _htmlparser.ElementType.Comment, _UnsupportedElementType2.default), _defineProperty(_ElementType$Text$Ele, _htmlparser.ElementType.Script, _UnsupportedElementType2.default), _defineProperty(_ElementType$Text$Ele, _htmlparser.ElementType.CDATA, _UnsupportedElementType2.default), _defineProperty(_ElementType$Text$Ele, _htmlparser.ElementType.Doctype, _UnsupportedElementType2.default), _ElementType$Text$Ele);
49667
 
49668
  /***/ },
49669
- /* 507 */
49670
  /***/ function(module, exports) {
49671
 
49672
  "use strict";
@@ -49688,7 +49961,7 @@ webpackJsonp([3],[
49688
  }
49689
 
49690
  /***/ },
49691
- /* 508 */
49692
  /***/ function(module, exports, __webpack_require__) {
49693
 
49694
  'use strict';
@@ -49702,19 +49975,19 @@ webpackJsonp([3],[
49702
 
49703
  var _react2 = _interopRequireDefault(_react);
49704
 
49705
- var _ProcessNodes = __webpack_require__(505);
49706
 
49707
  var _ProcessNodes2 = _interopRequireDefault(_ProcessNodes);
49708
 
49709
- var _GeneratePropsFromAttributes = __webpack_require__(509);
49710
 
49711
  var _GeneratePropsFromAttributes2 = _interopRequireDefault(_GeneratePropsFromAttributes);
49712
 
49713
- var _TransformTagName = __webpack_require__(514);
49714
 
49715
  var _TransformTagName2 = _interopRequireDefault(_TransformTagName);
49716
 
49717
- var _VoidElements = __webpack_require__(515);
49718
 
49719
  var _VoidElements2 = _interopRequireDefault(_VoidElements);
49720
 
@@ -49746,7 +50019,7 @@ webpackJsonp([3],[
49746
  }
49747
 
49748
  /***/ },
49749
- /* 509 */
49750
  /***/ function(module, exports, __webpack_require__) {
49751
 
49752
  'use strict';
@@ -49759,11 +50032,11 @@ webpackJsonp([3],[
49759
 
49760
  exports.default = GeneratePropsFromAttributes;
49761
 
49762
- var _HtmlAttributesToReact = __webpack_require__(510);
49763
 
49764
  var _HtmlAttributesToReact2 = _interopRequireDefault(_HtmlAttributesToReact);
49765
 
49766
- var _InlineStyleToObject = __webpack_require__(513);
49767
 
49768
  var _InlineStyleToObject2 = _interopRequireDefault(_InlineStyleToObject);
49769
 
@@ -49789,7 +50062,7 @@ webpackJsonp([3],[
49789
  }
49790
 
49791
  /***/ },
49792
- /* 510 */
49793
  /***/ function(module, exports, __webpack_require__) {
49794
 
49795
  'use strict';
@@ -49799,11 +50072,11 @@ webpackJsonp([3],[
49799
  });
49800
  exports.default = HtmlAttributesToReact;
49801
 
49802
- var _BooleanAttributes = __webpack_require__(511);
49803
 
49804
  var _BooleanAttributes2 = _interopRequireDefault(_BooleanAttributes);
49805
 
49806
- var _ReactAttributes = __webpack_require__(512);
49807
 
49808
  var _ReactAttributes2 = _interopRequireDefault(_ReactAttributes);
49809
 
@@ -49855,7 +50128,7 @@ webpackJsonp([3],[
49855
  }
49856
 
49857
  /***/ },
49858
- /* 511 */
49859
  /***/ function(module, exports) {
49860
 
49861
  'use strict';
@@ -49874,7 +50147,7 @@ webpackJsonp([3],[
49874
  exports.default = ['allowfullScreen', 'async', 'autoplay', 'capture', 'checked', 'controls', 'default', 'defer', 'disabled', 'formnovalidate', 'hidden', 'loop', 'multiple', 'muted', 'novalidate', 'open', 'readonly', 'required', 'reversed', 'scoped', 'seamless', 'selected', 'itemscope'];
49875
 
49876
  /***/ },
49877
- /* 512 */
49878
  /***/ function(module, exports) {
49879
 
49880
  'use strict';
@@ -50042,7 +50315,7 @@ webpackJsonp([3],[
50042
  };
50043
 
50044
  /***/ },
50045
- /* 513 */
50046
  /***/ function(module, exports) {
50047
 
50048
  'use strict';
@@ -50105,7 +50378,7 @@ webpackJsonp([3],[
50105
  }
50106
 
50107
  /***/ },
50108
- /* 514 */
50109
  /***/ function(module, exports) {
50110
 
50111
  'use strict';
@@ -50135,7 +50408,7 @@ webpackJsonp([3],[
50135
  }
50136
 
50137
  /***/ },
50138
- /* 515 */
50139
  /***/ function(module, exports) {
50140
 
50141
  'use strict';
@@ -50151,7 +50424,7 @@ webpackJsonp([3],[
50151
  exports.default = ['area', 'base', 'br', 'col', 'command', 'embed', 'hr', 'img', 'input', 'keygen', 'link', 'meta', 'param', 'source', 'track', 'wbr'];
50152
 
50153
  /***/ },
50154
- /* 516 */
50155
  /***/ function(module, exports, __webpack_require__) {
50156
 
50157
  'use strict';
@@ -50165,7 +50438,7 @@ webpackJsonp([3],[
50165
 
50166
  var _react2 = _interopRequireDefault(_react);
50167
 
50168
- var _GeneratePropsFromAttributes = __webpack_require__(509);
50169
 
50170
  var _GeneratePropsFromAttributes2 = _interopRequireDefault(_GeneratePropsFromAttributes);
50171
 
@@ -50195,7 +50468,7 @@ webpackJsonp([3],[
50195
  }
50196
 
50197
  /***/ },
50198
- /* 517 */
50199
  /***/ function(module, exports) {
50200
 
50201
  "use strict";
@@ -50216,7 +50489,6 @@ webpackJsonp([3],[
50216
  }
50217
 
50218
  /***/ },
50219
- /* 518 */,
50220
  /* 519 */,
50221
  /* 520 */,
50222
  /* 521 */,
@@ -50260,7 +50532,10 @@ webpackJsonp([3],[
50260
  /* 559 */,
50261
  /* 560 */,
50262
  /* 561 */,
50263
- /* 562 */
 
 
 
50264
  /***/ function(module, exports, __webpack_require__) {
50265
 
50266
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;function requestFailed(errorMessage, xhr) {
@@ -50353,7 +50628,7 @@ webpackJsonp([3],[
50353
 
50354
 
50355
  /***/ },
50356
- /* 563 */
50357
  /***/ function(module, exports, __webpack_require__) {
50358
 
50359
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
@@ -50532,7 +50807,7 @@ webpackJsonp([3],[
50532
 
50533
 
50534
  /***/ },
50535
- /* 564 */
50536
  /***/ function(module, exports, __webpack_require__) {
50537
 
50538
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
@@ -50561,7 +50836,7 @@ webpackJsonp([3],[
50561
 
50562
 
50563
  /***/ },
50564
- /* 565 */
50565
  /***/ function(module, exports, __webpack_require__) {
50566
 
50567
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/* eslint-disable func-names */
@@ -51206,7 +51481,7 @@ webpackJsonp([3],[
51206
 
51207
 
51208
  /***/ },
51209
- /* 566 */
51210
  /***/ function(module, exports, __webpack_require__) {
51211
 
51212
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
@@ -51429,7 +51704,7 @@ webpackJsonp([3],[
51429
 
51430
 
51431
  /***/ },
51432
- /* 567 */
51433
  /***/ function(module, exports, __webpack_require__) {
51434
 
51435
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
@@ -51455,7 +51730,7 @@ webpackJsonp([3],[
51455
 
51456
 
51457
  /***/ },
51458
- /* 568 */
51459
  /***/ function(module, exports, __webpack_require__) {
51460
 
51461
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
@@ -51564,7 +51839,7 @@ webpackJsonp([3],[
51564
 
51565
 
51566
  /***/ },
51567
- /* 569 */
51568
  /***/ function(module, exports, __webpack_require__) {
51569
 
51570
  /* WEBPACK VAR INJECTION */(function(global) {/*!
@@ -54063,7 +54338,7 @@ webpackJsonp([3],[
54063
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
54064
 
54065
  /***/ },
54066
- /* 570 */
54067
  /***/ function(module, exports, __webpack_require__) {
54068
 
54069
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*
@@ -54139,10 +54414,10 @@ webpackJsonp([3],[
54139
 
54140
 
54141
  /***/ },
54142
- /* 571 */
54143
  /***/ function(module, exports, __webpack_require__) {
54144
 
54145
- var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(276), __webpack_require__(2), __webpack_require__(34), __webpack_require__(436)], __WEBPACK_AMD_DEFINE_RESULT__ = function helpTooltip(mp, React, ReactDOM, TooltipComponent) {
54146
  'use strict';
54147
 
54148
  var MailPoet = mp;
3
  /***/ function(module, exports, __webpack_require__) {
4
 
5
  __webpack_require__(276);
 
 
 
6
  __webpack_require__(565);
7
  __webpack_require__(566);
8
  __webpack_require__(567);
9
  __webpack_require__(568);
10
  __webpack_require__(569);
11
  __webpack_require__(570);
12
+ __webpack_require__(571);
13
+ __webpack_require__(572);
14
+ __webpack_require__(573);
15
+ __webpack_require__(437);
16
+ module.exports = __webpack_require__(574);
17
 
18
 
19
  /***/ },
23905
  /***/ function(module, exports, __webpack_require__) {
23906
 
23907
  var require;/* WEBPACK VAR INJECTION */(function(module) {//! moment.js
23908
+ //! version : 2.20.1
23909
  //! authors : Tim Wood, Iskren Chernev, Moment.js contributors
23910
  //! license : MIT
23911
  //! momentjs.com
24565
 
24566
  // any word (or two) characters or numbers including two/three word month in arabic.
24567
  // includes scottish gaelic two word and hyphenated months
24568
+ var matchWord = /[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i;
24569
 
24570
 
24571
  var regexes = {};
25935
  // note: all values past the year are optional and will default to the lowest possible value.
25936
  // [year, month, day , hour, minute, second, millisecond]
25937
  function configFromArray (config) {
25938
+ var i, date, input = [], currentDate, expectedWeekday, yearToUse;
25939
 
25940
  if (config._d) {
25941
  return;
25985
  }
25986
 
25987
  config._d = (config._useUTC ? createUTCDate : createDate).apply(null, input);
25988
+ expectedWeekday = config._useUTC ? config._d.getUTCDay() : config._d.getDay();
25989
+
25990
  // Apply timezone offset from input. The actual utcOffset can be changed
25991
  // with parseZone.
25992
  if (config._tzm != null) {
25998
  }
25999
 
26000
  // check for mismatching day of week
26001
+ if (config._w && typeof config._w.d !== 'undefined' && config._w.d !== expectedWeekday) {
26002
  getParsingFlags(config).weekdayMismatch = true;
26003
  }
26004
  }
27206
  return this.clone().locale('en').format('ddd MMM DD YYYY HH:mm:ss [GMT]ZZ');
27207
  }
27208
 
27209
+ function toISOString(keepOffset) {
27210
  if (!this.isValid()) {
27211
  return null;
27212
  }
27213
+ var utc = keepOffset !== true;
27214
+ var m = utc ? this.clone().utc() : this;
27215
  if (m.year() < 0 || m.year() > 9999) {
27216
+ return formatMoment(m, utc ? 'YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]' : 'YYYYYY-MM-DD[T]HH:mm:ss.SSSZ');
27217
  }
27218
  if (isFunction(Date.prototype.toISOString)) {
27219
  // native implementation is ~50x faster, use it when we can
27220
+ if (utc) {
27221
+ return this.toDate().toISOString();
27222
+ } else {
27223
+ return new Date(this._d.valueOf()).toISOString().replace('Z', formatMoment(m, 'Z'));
27224
+ }
27225
  }
27226
+ return formatMoment(m, utc ? 'YYYY-MM-DD[T]HH:mm:ss.SSS[Z]' : 'YYYY-MM-DD[T]HH:mm:ss.SSSZ');
27227
  }
27228
 
27229
  /**
27579
 
27580
  addParseToken(['D', 'DD'], DATE);
27581
  addParseToken('Do', function (input, array) {
27582
+ array[DATE] = toInt(input.match(match1to2)[0]);
27583
  });
27584
 
27585
  // MOMENTS
28391
  // Side effect imports
28392
 
28393
 
28394
+ hooks.version = '2.20.1';
28395
 
28396
  setHookCallback(createLocal);
28397
 
28423
  hooks.calendarFormat = getCalendarFormat;
28424
  hooks.prototype = proto;
28425
 
28426
+ // currently HTML5 input type only supports 24-hour formats
28427
+ hooks.HTML5_FMT = {
28428
+ DATETIME_LOCAL: 'YYYY-MM-DDTHH:mm', // <input type="datetime-local" />
28429
+ DATETIME_LOCAL_SECONDS: 'YYYY-MM-DDTHH:mm:ss', // <input type="datetime-local" step="1" />
28430
+ DATETIME_LOCAL_MS: 'YYYY-MM-DDTHH:mm:ss.SSS', // <input type="datetime-local" step="0.001" />
28431
+ DATE: 'YYYY-MM-DD', // <input type="date" />
28432
+ TIME: 'HH:mm', // <input type="time" />
28433
+ TIME_SECONDS: 'HH:mm:ss', // <input type="time" step="1" />
28434
+ TIME_MS: 'HH:mm:ss.SSS', // <input type="time" step="0.001" />
28435
+ WEEK: 'YYYY-[W]WW', // <input type="week" />
28436
+ MONTH: 'YYYY-MM' // <input type="month" />
28437
+ };
28438
+
28439
  return hooks;
28440
 
28441
  })));
28613
  "./ms-my": 378,
28614
  "./ms-my.js": 378,
28615
  "./ms.js": 377,
28616
+ "./mt": 379,
28617
+ "./mt.js": 379,
28618
+ "./my": 380,
28619
+ "./my.js": 380,
28620
+ "./nb": 381,
28621
+ "./nb.js": 381,
28622
+ "./ne": 382,
28623
+ "./ne.js": 382,
28624
+ "./nl": 383,
28625
+ "./nl-be": 384,
28626
+ "./nl-be.js": 384,
28627
+ "./nl.js": 383,
28628
+ "./nn": 385,
28629
+ "./nn.js": 385,
28630
+ "./pa-in": 386,
28631
+ "./pa-in.js": 386,
28632
+ "./pl": 387,
28633
+ "./pl.js": 387,
28634
+ "./pt": 388,
28635
+ "./pt-br": 389,
28636
+ "./pt-br.js": 389,
28637
+ "./pt.js": 388,
28638
+ "./ro": 390,
28639
+ "./ro.js": 390,
28640
+ "./ru": 391,
28641
+ "./ru.js": 391,
28642
+ "./sd": 392,
28643
+ "./sd.js": 392,
28644
+ "./se": 393,
28645
+ "./se.js": 393,
28646
+ "./si": 394,
28647
+ "./si.js": 394,
28648
+ "./sk": 395,
28649
+ "./sk.js": 395,
28650
+ "./sl": 396,
28651
+ "./sl.js": 396,
28652
+ "./sq": 397,
28653
+ "./sq.js": 397,
28654
+ "./sr": 398,
28655
+ "./sr-cyrl": 399,
28656
+ "./sr-cyrl.js": 399,
28657
+ "./sr.js": 398,
28658
+ "./ss": 400,
28659
+ "./ss.js": 400,
28660
+ "./sv": 401,
28661
+ "./sv.js": 401,
28662
+ "./sw": 402,
28663
+ "./sw.js": 402,
28664
+ "./ta": 403,
28665
+ "./ta.js": 403,
28666
+ "./te": 404,
28667
+ "./te.js": 404,
28668
+ "./tet": 405,
28669
+ "./tet.js": 405,
28670
+ "./th": 406,
28671
+ "./th.js": 406,
28672
+ "./tl-ph": 407,
28673
+ "./tl-ph.js": 407,
28674
+ "./tlh": 408,
28675
+ "./tlh.js": 408,
28676
+ "./tr": 409,
28677
+ "./tr.js": 409,
28678
+ "./tzl": 410,
28679
+ "./tzl.js": 410,
28680
+ "./tzm": 411,
28681
+ "./tzm-latn": 412,
28682
+ "./tzm-latn.js": 412,
28683
+ "./tzm.js": 411,
28684
+ "./uk": 413,
28685
+ "./uk.js": 413,
28686
+ "./ur": 414,
28687
+ "./ur.js": 414,
28688
+ "./uz": 415,
28689
+ "./uz-latn": 416,
28690
+ "./uz-latn.js": 416,
28691
+ "./uz.js": 415,
28692
+ "./vi": 417,
28693
+ "./vi.js": 417,
28694
+ "./x-pseudo": 418,
28695
+ "./x-pseudo.js": 418,
28696
+ "./yo": 419,
28697
+ "./yo.js": 419,
28698
+ "./zh-cn": 420,
28699
+ "./zh-cn.js": 420,
28700
+ "./zh-hk": 421,
28701
+ "./zh-hk.js": 421,
28702
+ "./zh-tw": 422,
28703
+ "./zh-tw.js": 422
28704
  };
28705
  function webpackContext(req) {
28706
  return __webpack_require__(webpackContextResolve(req));
28768
  future : 'oor %s',
28769
  past : '%s gelede',
28770
  s : '\'n paar sekondes',
28771
+ ss : '%d sekondes',
28772
  m : '\'n minuut',
28773
  mm : '%d minute',
28774
  h : '\'n uur',
28858
  };
28859
  };
28860
  var months = [
28861
+ 'يناير',
28862
+ 'فبراير',
28863
+ 'مارس',
28864
+ 'أبريل',
28865
+ 'مايو',
28866
+ 'يونيو',
28867
+ 'يوليو',
28868
+ 'أغسطس',
28869
+ 'سبتمبر',
28870
+ 'أكتوبر',
28871
+ 'نوفمبر',
28872
+ 'ديسمبر'
28873
  ];
28874
 
28875
  var ar = moment.defineLocale('ar', {
28910
  future : 'بعد %s',
28911
  past : 'منذ %s',
28912
  s : pluralize('s'),
28913
+ ss : pluralize('s'),
28914
  m : pluralize('m'),
28915
  mm : pluralize('m'),
28916
  h : pluralize('h'),
28985
  future : 'في %s',
28986
  past : 'منذ %s',
28987
  s : 'ثوان',
28988
+ ss : '%d ثانية',
28989
  m : 'دقيقة',
28990
  mm : '%d دقائق',
28991
  h : 'ساعة',
29050
  future : 'في %s',
29051
  past : 'منذ %s',
29052
  s : 'ثوان',
29053
+ ss : '%d ثانية',
29054
  m : 'دقيقة',
29055
  mm : '%d دقائق',
29056
  h : 'ساعة',
29174
  future : 'بعد %s',
29175
  past : 'منذ %s',
29176
  s : pluralize('s'),
29177
+ ss : pluralize('s'),
29178
  m : pluralize('m'),
29179
  mm : pluralize('m'),
29180
  h : pluralize('h'),
29248
  future : 'في %s',
29249
  past : 'منذ %s',
29250
  s : 'ثوان',
29251
+ ss : '%d ثانية',
29252
  m : 'دقيقة',
29253
  mm : '%d دقائق',
29254
  h : 'ساعة',
29349
  future : 'في %s',
29350
  past : 'منذ %s',
29351
  s : 'ثوان',
29352
+ ss : '%d ثانية',
29353
  m : 'دقيقة',
29354
  mm : '%d دقائق',
29355
  h : 'ساعة',
29424
  future: 'في %s',
29425
  past: 'منذ %s',
29426
  s: 'ثوان',
29427
+ ss : '%d ثانية',
29428
  m: 'دقيقة',
29429
  mm: '%d دقائق',
29430
  h: 'ساعة',
29510
  future : '%s sonra',
29511
  past : '%s əvvəl',
29512
  s : 'birneçə saniyyə',
29513
+ ss : '%d saniyə',
29514
  m : 'bir dəqiqə',
29515
  mm : '%d dəqiqə',
29516
  h : 'bir saat',
29581
  }
29582
  function relativeTimeWithPlural(number, withoutSuffix, key) {
29583
  var format = {
29584
+ 'ss': withoutSuffix ? 'секунда_секунды_секунд' : 'секунду_секунды_секунд',
29585
  'mm': withoutSuffix ? 'хвіліна_хвіліны_хвілін' : 'хвіліну_хвіліны_хвілін',
29586
  'hh': withoutSuffix ? 'гадзіна_гадзіны_гадзін' : 'гадзіну_гадзіны_гадзін',
29587
  'dd': 'дзень_дні_дзён',
29751
  future : 'след %s',
29752
  past : 'преди %s',
29753
  s : 'няколко секунди',
29754
+ ss : '%d секунди',
29755
  m : 'минута',
29756
  mm : '%d минути',
29757
  h : 'час',
29836
  future : '%s kɔnɔ',
29837
  past : 'a bɛ %s bɔ',
29838
  s : 'sanga dama dama',
29839
+ ss : 'sekondi %d',
29840
  m : 'miniti kelen',
29841
  mm : 'miniti %d',
29842
  h : 'lɛrɛ kelen',
29925
  future : '%s পরে',
29926
  past : '%s আগে',
29927
  s : 'কয়েক সেকেন্ড',
29928
+ ss : '%d সেকেন্ড',
29929
  m : 'এক মিনিট',
29930
  mm : '%d মিনিট',
29931
  h : 'এক ঘন্টা',
30050
  future : '%s ལ་',
30051
  past : '%s སྔན་ལ',
30052
  s : 'ལམ་སང',
30053
+ ss : '%d སྐར་ཆ།',
30054
  m : 'སྐར་མ་གཅིག',
30055
  mm : '%d སྐར་མ',
30056
  h : 'ཆུ་ཚོད་གཅིག',
30195
  future : 'a-benn %s',
30196
  past : '%s \'zo',
30197
  s : 'un nebeud segondennoù',
30198
+ ss : '%d eilenn',
30199
  m : 'ur vunutenn',
30200
  mm : relativeTimeWithMutation,
30201
  h : 'un eur',
30242
  function translate(number, withoutSuffix, key) {
30243
  var result = number + ' ';
30244
  switch (key) {
30245
+ case 'ss':
30246
+ if (number === 1) {
30247
+ result += 'sekunda';
30248
+ } else if (number === 2 || number === 3 || number === 4) {
30249
+ result += 'sekunde';
30250
+ } else {
30251
+ result += 'sekundi';
30252
+ }
30253
+ return result;
30254
  case 'm':
30255
  return withoutSuffix ? 'jedna minuta' : 'jedne minute';
30256
  case 'mm':
30356
  future : 'za %s',
30357
  past : 'prije %s',
30358
  s : 'par sekundi',
30359
+ ss : translate,
30360
  m : translate,
30361
  mm : translate,
30362
  h : translate,
30441
  future : 'd\'aquí %s',
30442
  past : 'fa %s',
30443
  s : 'uns segons',
30444
+ ss : '%d segons',
30445
  m : 'un minut',
30446
  mm : '%d minuts',
30447
  h : 'una hora',
30500
  switch (key) {
30501
  case 's': // a few seconds / in a few seconds / a few seconds ago
30502
  return (withoutSuffix || isFuture) ? 'pár sekund' : 'pár sekundami';
30503
+ case 'ss': // 9 seconds / in 9 seconds / 9 seconds ago
30504
+ if (withoutSuffix || isFuture) {
30505
+ return result + (plural(number) ? 'sekundy' : 'sekund');
30506
+ } else {
30507
+ return result + 'sekundami';
30508
+ }
30509
+ break;
30510
  case 'm': // a minute / in a minute / a minute ago
30511
  return withoutSuffix ? 'minuta' : (isFuture ? 'minutu' : 'minutou');
30512
  case 'mm': // 9 minutes / in 9 minutes / 9 minutes ago
30635
  future : 'za %s',
30636
  past : 'před %s',
30637
  s : translate,
30638
+ ss : translate,
30639
  m : translate,
30640
  mm : translate,
30641
  h : translate,
30704
  },
30705
  past : '%s каялла',
30706
  s : 'пӗр-ик ҫеккунт',
30707
+ ss : '%d ҫеккунт',
30708
  m : 'пӗр минут',
30709
  mm : '%d минут',
30710
  h : 'пӗр сехет',
30773
  future: 'mewn %s',
30774
  past: '%s yn ôl',
30775
  s: 'ychydig eiliadau',
30776
+ ss: '%d eiliad',
30777
  m: 'munud',
30778
  mm: '%d munud',
30779
  h: 'awr',
30857
  future : 'om %s',
30858
  past : '%s siden',
30859
  s : 'få sekunder',
30860
+ ss : '%d sekunder',
30861
  m : 'et minut',
30862
  mm : '%d minutter',
30863
  h : 'en time',
30941
  future : 'in %s',
30942
  past : 'vor %s',
30943
  s : 'ein paar Sekunden',
30944
+ ss : '%d Sekunden',
30945
  m : processRelativeTime,
30946
  mm : '%d Minuten',
30947
  h : processRelativeTime,
31026
  future : 'in %s',
31027
  past : 'vor %s',
31028
  s : 'ein paar Sekunden',
31029
+ ss : '%d Sekunden',
31030
  m : processRelativeTime,
31031
  mm : '%d Minuten',
31032
  h : processRelativeTime,
31091
  weekdaysMin : 'So_Mo_Di_Mi_Do_Fr_Sa'.split('_'),
31092
  weekdaysParseExact : true,
31093
  longDateFormat : {
31094
+ LT: 'HH:mm',
31095
+ LTS: 'HH:mm:ss',
31096
  L : 'DD.MM.YYYY',
31097
  LL : 'D. MMMM YYYY',
31098
+ LLL : 'D. MMMM YYYY HH:mm',
31099
+ LLLL : 'dddd, D. MMMM YYYY HH:mm'
31100
  },
31101
  calendar : {
31102
  sameDay: '[heute um] LT [Uhr]',
31110
  future : 'in %s',
31111
  past : 'vor %s',
31112
  s : 'ein paar Sekunden',
31113
+ ss : '%d Sekunden',
31114
  m : processRelativeTime,
31115
  mm : '%d Minuten',
31116
  h : processRelativeTime,
31212
  future : 'ތެރޭގައި %s',
31213
  past : 'ކުރިން %s',
31214
  s : 'ސިކުންތުކޮޅެއް',
31215
+ ss : 'd% ސިކުންތު',
31216
  m : 'މިނިޓެއް',
31217
  mm : 'މިނިޓު %d',
31218
  h : 'ގަޑިއިރެއް',
31322
  future : 'σε %s',
31323
  past : '%s πριν',
31324
  s : 'λίγα δευτερόλεπτα',
31325
+ ss : '%d δευτερόλεπτα',
31326
  m : 'ένα λεπτό',
31327
  mm : '%d λεπτά',
31328
  h : 'μία ώρα',
31388
  future : 'in %s',
31389
  past : '%s ago',
31390
  s : 'a few seconds',
31391
+ ss : '%d seconds',
31392
  m : 'a minute',
31393
  mm : '%d minutes',
31394
  h : 'an hour',
31461
  future : 'in %s',
31462
  past : '%s ago',
31463
  s : 'a few seconds',
31464
+ ss : '%d seconds',
31465
  m : 'a minute',
31466
  mm : '%d minutes',
31467
  h : 'an hour',
31530
  future : 'in %s',
31531
  past : '%s ago',
31532
  s : 'a few seconds',
31533
+ ss : '%d seconds',
31534
  m : 'a minute',
31535
  mm : '%d minutes',
31536
  h : 'an hour',
31603
  future : 'in %s',
31604
  past : '%s ago',
31605
  s : 'a few seconds',
31606
+ ss : '%d seconds',
31607
  m : 'a minute',
31608
  mm : '%d minutes',
31609
  h : 'an hour',
31676
  future : 'in %s',
31677
  past : '%s ago',
31678
  s : 'a few seconds',
31679
+ ss : '%d seconds',
31680
  m : 'a minute',
31681
  mm : '%d minutes',
31682
  h : 'an hour',
31762
  future : 'post %s',
31763
  past : 'antaŭ %s',
31764
  s : 'sekundoj',
31765
+ ss : '%d sekundoj',
31766
  m : 'minuto',
31767
  mm : '%d minutoj',
31768
  h : 'horo',
31860
  future : 'en %s',
31861
  past : 'hace %s',
31862
  s : 'unos segundos',
31863
+ ss : '%d segundos',
31864
  m : 'un minuto',
31865
  mm : '%d minutos',
31866
  h : 'una hora',
31957
  future : 'en %s',
31958
  past : 'hace %s',
31959
  s : 'unos segundos',
31960
+ ss : '%d segundos',
31961
  m : 'un minuto',
31962
  mm : '%d minutos',
31963
  h : 'una hora',
32017
  weekdaysMin : 'do_lu_ma_mi_ju_vi_sá'.split('_'),
32018
  weekdaysParseExact : true,
32019
  longDateFormat : {
32020
+ LT : 'h:mm A',
32021
+ LTS : 'h:mm:ss A',
32022
  L : 'MM/DD/YYYY',
32023
  LL : 'MMMM [de] D [de] YYYY',
32024
+ LLL : 'MMMM [de] D [de] YYYY h:mm A',
32025
+ LLLL : 'dddd, MMMM [de] D [de] YYYY h:mm A'
32026
  },
32027
  calendar : {
32028
  sameDay : function () {
32046
  future : 'en %s',
32047
  past : 'hace %s',
32048
  s : 'unos segundos',
32049
+ ss : '%d segundos',
32050
  m : 'un minuto',
32051
  mm : '%d minutos',
32052
  h : 'una hora',
32090
  function processRelativeTime(number, withoutSuffix, key, isFuture) {
32091
  var format = {
32092
  's' : ['mõne sekundi', 'mõni sekund', 'paar sekundit'],
32093
+ 'ss': [number + 'sekundi', number + 'sekundit'],
32094
  'm' : ['ühe minuti', 'üks minut'],
32095
  'mm': [number + ' minuti', number + ' minutit'],
32096
  'h' : ['ühe tunni', 'tund aega', 'üks tund'],
32133
  future : '%s pärast',
32134
  past : '%s tagasi',
32135
  s : processRelativeTime,
32136
+ ss : processRelativeTime,
32137
  m : processRelativeTime,
32138
  mm : processRelativeTime,
32139
  h : processRelativeTime,
32205
  future : '%s barru',
32206
  past : 'duela %s',
32207
  s : 'segundo batzuk',
32208
+ ss : '%d segundo',
32209
  m : 'minutu bat',
32210
  mm : '%d minutu',
32211
  h : 'ordu bat',
32308
  future : 'در %s',
32309
  past : '%s پیش',
32310
  s : 'چند ثانیه',
32311
+ ss : 'ثانیه d%',
32312
  m : 'یک دقیقه',
32313
  mm : '%d دقیقه',
32314
  h : 'یک ساعت',
32368
  switch (key) {
32369
  case 's':
32370
  return isFuture ? 'muutaman sekunnin' : 'muutama sekunti';
32371
+ case 'ss':
32372
+ return isFuture ? 'sekunnin' : 'sekuntia';
32373
  case 'm':
32374
  return isFuture ? 'minuutin' : 'minuutti';
32375
  case 'mm':
32433
  future : '%s päästä',
32434
  past : '%s sitten',
32435
  s : translate,
32436
+ ss : translate,
32437
  m : translate,
32438
  mm : translate,
32439
  h : translate,
32499
  future : 'um %s',
32500
  past : '%s síðani',
32501
  s : 'fá sekund',
32502
+ ss : '%d sekundir',
32503
  m : 'ein minutt',
32504
  mm : '%d minuttir',
32505
  h : 'ein tími',
32545
  monthsParseExact : true,
32546
  weekdays : 'dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi'.split('_'),
32547
  weekdaysShort : 'dim._lun._mar._mer._jeu._ven._sam.'.split('_'),
32548
+ weekdaysMin : 'di_lu_ma_me_je_ve_sa'.split('_'),
32549
  weekdaysParseExact : true,
32550
  longDateFormat : {
32551
  LT : 'HH:mm',
32567
  future : 'dans %s',
32568
  past : 'il y a %s',
32569
  s : 'quelques secondes',
32570
+ ss : '%d secondes',
32571
  m : 'une minute',
32572
  mm : '%d minutes',
32573
  h : 'une heure',
32634
  monthsParseExact : true,
32635
  weekdays : 'dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi'.split('_'),
32636
  weekdaysShort : 'dim._lun._mar._mer._jeu._ven._sam.'.split('_'),
32637
+ weekdaysMin : 'di_lu_ma_me_je_ve_sa'.split('_'),
32638
  weekdaysParseExact : true,
32639
  longDateFormat : {
32640
  LT : 'HH:mm',
32656
  future : 'dans %s',
32657
  past : 'il y a %s',
32658
  s : 'quelques secondes',
32659
+ ss : '%d secondes',
32660
  m : 'une minute',
32661
  mm : '%d minutes',
32662
  h : 'une heure',
32714
  monthsParseExact : true,
32715
  weekdays : 'dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi'.split('_'),
32716
  weekdaysShort : 'dim._lun._mar._mer._jeu._ven._sam.'.split('_'),
32717
+ weekdaysMin : 'di_lu_ma_me_je_ve_sa'.split('_'),
32718
  weekdaysParseExact : true,
32719
  longDateFormat : {
32720
  LT : 'HH:mm',
32736
  future : 'dans %s',
32737
  past : 'il y a %s',
32738
  s : 'quelques secondes',
32739
+ ss : '%d secondes',
32740
  m : 'une minute',
32741
  mm : '%d minutes',
32742
  h : 'une heure',
32831
  future : 'oer %s',
32832
  past : '%s lyn',
32833
  s : 'in pear sekonden',
32834
+ ss : '%d sekonden',
32835
  m : 'ien minút',
32836
  mm : '%d minuten',
32837
  h : 'ien oere',
32912
  future : 'ann an %s',
32913
  past : 'bho chionn %s',
32914
  s : 'beagan diogan',
32915
+ ss : '%d diogan',
32916
  m : 'mionaid',
32917
  mm : '%d mionaidean',
32918
  h : 'uair',
32998
  },
32999
  past : 'hai %s',
33000
  s : 'uns segundos',
33001
+ ss : '%d segundos',
33002
  m : 'un minuto',
33003
  mm : '%d minutos',
33004
  h : 'unha hora',
33041
  function processRelativeTime(number, withoutSuffix, key, isFuture) {
33042
  var format = {
33043
  's': ['thodde secondanim', 'thodde second'],
33044
+ 'ss': [number + ' secondanim', number + ' second'],
33045
  'm': ['eka mintan', 'ek minute'],
33046
  'mm': [number + ' mintanim', number + ' mintam'],
33047
  'h': ['eka horan', 'ek hor'],
33085
  future : '%s',
33086
  past : '%s adim',
33087
  s : processRelativeTime,
33088
+ ss : processRelativeTime,
33089
  m : processRelativeTime,
33090
  mm : processRelativeTime,
33091
  h : processRelativeTime,
33219
  future: '%s મા',
33220
  past: '%s પેહલા',
33221
  s: 'અમુક પળો',
33222
+ ss: '%d સેકંડ',
33223
  m: 'એક મિનિટ',
33224
  mm: '%d મિનિટ',
33225
  h: 'એક કલાક',
33329
  future : 'בעוד %s',
33330
  past : 'לפני %s',
33331
  s : 'מספר שניות',
33332
+ ss : '%d שניות',
33333
  m : 'דקה',
33334
  mm : '%d דקות',
33335
  h : 'שעה',
33454
  future : '%s में',
33455
  past : '%s पहले',
33456
  s : 'कुछ ही क्षण',
33457
+ ss : '%d सेकंड',
33458
  m : 'एक मिनट',
33459
  mm : '%d मिनट',
33460
  h : 'एक घंटा',
33535
  function translate(number, withoutSuffix, key) {
33536
  var result = number + ' ';
33537
  switch (key) {
33538
+ case 'ss':
33539
+ if (number === 1) {
33540
+ result += 'sekunda';
33541
+ } else if (number === 2 || number === 3 || number === 4) {
33542
+ result += 'sekunde';
33543
+ } else {
33544
+ result += 'sekundi';
33545
+ }
33546
+ return result;
33547
  case 'm':
33548
  return withoutSuffix ? 'jedna minuta' : 'jedne minute';
33549
  case 'mm':
33652
  future : 'za %s',
33653
  past : 'prije %s',
33654
  s : 'par sekundi',
33655
+ ss : translate,
33656
  m : translate,
33657
  mm : translate,
33658
  h : translate,
33698
  switch (key) {
33699
  case 's':
33700
  return (isFuture || withoutSuffix) ? 'néhány másodperc' : 'néhány másodperce';
33701
+ case 'ss':
33702
+ return num + (isFuture || withoutSuffix) ? ' másodperc' : ' másodperce';
33703
  case 'm':
33704
  return 'egy' + (isFuture || withoutSuffix ? ' perc' : ' perce');
33705
  case 'mm':
33768
  future : '%s múlva',
33769
  past : '%s',
33770
  s : translate,
33771
+ ss : translate,
33772
  m : translate,
33773
  mm : translate,
33774
  h : translate,
33841
  future : '%s հետո',
33842
  past : '%s առաջ',
33843
  s : 'մի քանի վայրկյան',
33844
+ ss : '%d վայրկյան',
33845
  m : 'րոպե',
33846
  mm : '%d րոպե',
33847
  h : 'ժամ',
33960
  future : 'dalam %s',
33961
  past : '%s yang lalu',
33962
  s : 'beberapa detik',
33963
+ ss : '%d detik',
33964
  m : 'semenit',
33965
  mm : '%d menit',
33966
  h : 'sejam',
34011
  switch (key) {
34012
  case 's':
34013
  return withoutSuffix || isFuture ? 'nokkrar sekúndur' : 'nokkrum sekúndum';
34014
+ case 'ss':
34015
+ if (plural(number)) {
34016
+ return result + (withoutSuffix || isFuture ? 'sekúndur' : 'sekúndum');
34017
+ }
34018
+ return result + 'sekúnda';
34019
  case 'm':
34020
  return withoutSuffix ? 'mínúta' : 'mínútu';
34021
  case 'mm':
34096
  future : 'eftir %s',
34097
  past : 'fyrir %s síðan',
34098
  s : translate,
34099
+ ss : translate,
34100
  m : translate,
34101
  mm : translate,
34102
  h : 'klukkustund',
34149
  L : 'DD/MM/YYYY',
34150
  LL : 'D MMMM YYYY',
34151
  LLL : 'D MMMM YYYY HH:mm',
34152
+ LLLL : 'dddd D MMMM YYYY HH:mm'
34153
  },
34154
  calendar : {
34155
  sameDay: '[Oggi alle] LT',
34172
  },
34173
  past : '%s fa',
34174
  s : 'alcuni secondi',
34175
+ ss : '%d secondi',
34176
  m : 'un minuto',
34177
  mm : '%d minuti',
34178
  h : 'un\'ora',
34264
  future : '%s後',
34265
  past : '%s前',
34266
  s : '数秒',
34267
+ ss : '%d秒',
34268
  m : '1分',
34269
  mm : '%d分',
34270
  h : '1時間',
34349
  future : 'wonten ing %s',
34350
  past : '%s ingkang kepengker',
34351
  s : 'sawetawis detik',
34352
+ ss : '%d detik',
34353
  m : 'setunggal menit',
34354
  mm : '%d menit',
34355
  h : 'setunggal jam',
34431
  }
34432
  },
34433
  s : 'რამდენიმე წამი',
34434
+ ss : '%d წამი',
34435
  m : 'წუთი',
34436
  mm : '%d წუთი',
34437
  h : 'საათი',
34531
  future : '%s ішінде',
34532
  past : '%s бұрын',
34533
  s : 'бірнеше секунд',
34534
+ ss : '%d секунд',
34535
  m : 'бір минут',
34536
  mm : '%d минут',
34537
  h : 'бір сағат',
34601
  future: '%sទៀត',
34602
  past: '%sមុន',
34603
  s: 'ប៉ុន្មានវិនាទី',
34604
+ ss: '%d វិនាទី',
34605
  m: 'មួយនាទី',
34606
  mm: '%d នាទី',
34607
  h: 'មួយម៉ោង',
34691
  future : '%s ನಂತರ',
34692
  past : '%s ಹಿಂದೆ',
34693
  s : 'ಕೆಲವು ಕ್ಷಣಗಳು',
34694
+ ss : '%d ಸೆಕೆಂಡುಗಳು',
34695
  m : 'ಒಂದು ನಿಮಿಷ',
34696
  mm : '%d ನಿಮಿಷ',
34697
  h : 'ಒಂದು ಗಂಟೆ',
34909
  future : '%s ичинде',
34910
  past : '%s мурун',
34911
  s : 'бирнече секунд',
34912
+ ss : '%d секунд',
34913
  m : 'бир мүнөт',
34914
  mm : '%d мүнөт',
34915
  h : 'бир саат',
35056
  future : processFutureTime,
35057
  past : processPastTime,
35058
  s : 'e puer Sekonnen',
35059
+ ss : '%d Sekonnen',
35060
  m : processRelativeTime,
35061
  mm : '%d Minutten',
35062
  h : processRelativeTime,
35134
  future : 'ອີກ %s',
35135
  past : '%sຜ່ານມາ',
35136
  s : 'ບໍ່ເທົ່າໃດວິນາທີ',
35137
+ ss : '%d ວິນາທີ' ,
35138
  m : '1 ນາທີ',
35139
  mm : '%d ນາທີ',
35140
  h : '1 ຊົ່ວໂມງ',
35173
 
35174
 
35175
  var units = {
35176
+ 'ss' : 'sekundė_sekundžių_sekundes',
35177
  'm' : 'minutė_minutės_minutę',
35178
  'mm': 'minutės_minučių_minutes',
35179
  'h' : 'valanda_valandos_valandą',
35254
  future : 'po %s',
35255
  past : 'prieš %s',
35256
  s : translateSeconds,
35257
+ ss : translate,
35258
  m : translateSingular,
35259
  mm : translate,
35260
  h : translateSingular,
35298
 
35299
 
35300
  var units = {
35301
+ 'ss': 'sekundes_sekundēm_sekunde_sekundes'.split('_'),
35302
  'm': 'minūtes_minūtēm_minūte_minūtes'.split('_'),
35303
  'mm': 'minūtes_minūtēm_minūte_minūtes'.split('_'),
35304
  'h': 'stundas_stundām_stunda_stundas'.split('_'),
35360
  future : 'pēc %s',
35361
  past : 'pirms %s',
35362
  s : relativeSeconds,
35363
+ ss : relativeTimeWithPlural,
35364
  m : relativeTimeWithSingular,
35365
  mm : relativeTimeWithPlural,
35366
  h : relativeTimeWithSingular,
35402
 
35403
  var translator = {
35404
  words: { //Different grammatical cases
35405
+ ss: ['sekund', 'sekunda', 'sekundi'],
35406
  m: ['jedan minut', 'jednog minuta'],
35407
  mm: ['minut', 'minuta', 'minuta'],
35408
  h: ['jedan sat', 'jednog sata'],
35478
  future : 'za %s',
35479
  past : 'prije %s',
35480
  s : 'nekoliko sekundi',
35481
+ ss : translator.translate,
35482
  m : translator.translate,
35483
  mm : translator.translate,
35484
  h : translator.translate,
35548
  future: 'i roto i %s',
35549
  past: '%s i mua',
35550
  s: 'te hēkona ruarua',
35551
+ ss: '%d hēkona',
35552
  m: 'he meneti',
35553
  mm: '%d meneti',
35554
  h: 'te haora',
35626
  future : 'после %s',
35627
  past : 'пред %s',
35628
  s : 'неколку секунди',
35629
+ ss : '%d секунди',
35630
  m : 'минута',
35631
  mm : '%d минути',
35632
  h : 'час',
35711
  future : '%s കഴിഞ്ഞ്',
35712
  past : '%s മുൻപ്',
35713
  s : 'അൽപ നിമിഷങ്ങൾ',
35714
+ ss : '%d സെക്കൻഡ്',
35715
  m : 'ഒരു മിനിറ്റ്',
35716
  mm : '%d മിനിറ്റ്',
35717
  h : 'ഒരു മണിക്കൂർ',
35803
  if (withoutSuffix) {
35804
  switch (string) {
35805
  case 's': output = 'काही सेकंद'; break;
35806
+ case 'ss': output = '%d सेकंद'; break;
35807
  case 'm': output = 'एक मिनिट'; break;
35808
  case 'mm': output = '%d मिनिटे'; break;
35809
  case 'h': output = 'एक तास'; break;
35819
  else {
35820
  switch (string) {
35821
  case 's': output = 'काही सेकंदां'; break;
35822
+ case 'ss': output = '%d सेकंदां'; break;
35823
  case 'm': output = 'एका मिनिटा'; break;
35824
  case 'mm': output = '%d मिनिटां'; break;
35825
  case 'h': output = 'एका तासा'; break;
35862
  future: '%sमध्ये',
35863
  past: '%sपूर्वी',
35864
  s: relativeTimeMr,
35865
+ ss: relativeTimeMr,
35866
  m: relativeTimeMr,
35867
  mm: relativeTimeMr,
35868
  h: relativeTimeMr,
35988
  future : 'dalam %s',
35989
  past : '%s yang lepas',
35990
  s : 'beberapa saat',
35991
+ ss : '%d saat',
35992
  m : 'seminit',
35993
  mm : '%d minit',
35994
  h : 'sejam',
36077
  future : 'dalam %s',
36078
  past : '%s yang lepas',
36079
  s : 'beberapa saat',
36080
+ ss : '%d saat',
36081
  m : 'seminit',
36082
  mm : '%d minit',
36083
  h : 'sejam',
36102
 
36103
  /***/ },
36104
  /* 379 */
36105
+ /***/ function(module, exports, __webpack_require__) {
36106
+
36107
+ //! moment.js locale configuration
36108
+ //! locale : Maltese (Malta) [mt]
36109
+ //! author : Alessandro Maruccia : https://github.com/alesma
36110
+
36111
+ ;(function (global, factory) {
36112
+ true ? factory(__webpack_require__(301)) :
36113
+ typeof define === 'function' && define.amd ? define(['../moment'], factory) :
36114
+ factory(global.moment)
36115
+ }(this, (function (moment) { 'use strict';
36116
+
36117
+
36118
+ var mt = moment.defineLocale('mt', {
36119
+ months : 'Jannar_Frar_Marzu_April_Mejju_Ġunju_Lulju_Awwissu_Settembru_Ottubru_Novembru_Diċembru'.split('_'),
36120
+ monthsShort : 'Jan_Fra_Mar_Apr_Mej_Ġun_Lul_Aww_Set_Ott_Nov_Diċ'.split('_'),
36121
+ weekdays : 'Il-Ħadd_It-Tnejn_It-Tlieta_L-Erbgħa_Il-Ħamis_Il-Ġimgħa_Is-Sibt'.split('_'),
36122
+ weekdaysShort : 'Ħad_Tne_Tli_Erb_Ħam_Ġim_Sib'.split('_'),
36123
+ weekdaysMin : 'Ħa_Tn_Tl_Er_Ħa_Ġi_Si'.split('_'),
36124
+ longDateFormat : {
36125
+ LT : 'HH:mm',
36126
+ LTS : 'HH:mm:ss',
36127
+ L : 'DD/MM/YYYY',
36128
+ LL : 'D MMMM YYYY',
36129
+ LLL : 'D MMMM YYYY HH:mm',
36130
+ LLLL : 'dddd, D MMMM YYYY HH:mm'
36131
+ },
36132
+ calendar : {
36133
+ sameDay : '[Illum fil-]LT',
36134
+ nextDay : '[Għada fil-]LT',
36135
+ nextWeek : 'dddd [fil-]LT',
36136
+ lastDay : '[Il-bieraħ fil-]LT',
36137
+ lastWeek : 'dddd [li għadda] [fil-]LT',
36138
+ sameElse : 'L'
36139
+ },
36140
+ relativeTime : {
36141
+ future : 'f’ %s',
36142
+ past : '%s ilu',
36143
+ s : 'ftit sekondi',
36144
+ ss : '%d sekondi',
36145
+ m : 'minuta',
36146
+ mm : '%d minuti',
36147
+ h : 'siegħa',
36148
+ hh : '%d siegħat',
36149
+ d : 'ġurnata',
36150
+ dd : '%d ġranet',
36151
+ M : 'xahar',
36152
+ MM : '%d xhur',
36153
+ y : 'sena',
36154
+ yy : '%d sni'
36155
+ },
36156
+ dayOfMonthOrdinalParse : /\d{1,2}º/,
36157
+ ordinal: '%dº',
36158
+ week : {
36159
+ dow : 1, // Monday is the first day of the week.
36160
+ doy : 4 // The week that contains Jan 4th is the first week of the year.
36161
+ }
36162
+ });
36163
+
36164
+ return mt;
36165
+
36166
+ })));
36167
+
36168
+
36169
+ /***/ },
36170
+ /* 380 */
36171
  /***/ function(module, exports, __webpack_require__) {
36172
 
36173
  //! moment.js locale configuration
36235
  future: 'လာမည့် %s မှာ',
36236
  past: 'လွန်ခဲ့သော %s က',
36237
  s: 'စက္ကန်.အနည်းငယ်',
36238
+ ss : '%d စက္ကန့်',
36239
  m: 'တစ်မိနစ်',
36240
  mm: '%d မိနစ်',
36241
  h: 'တစ်နာရီ',
36269
 
36270
 
36271
  /***/ },
36272
+ /* 381 */
36273
  /***/ function(module, exports, __webpack_require__) {
36274
 
36275
  //! moment.js locale configuration
36312
  future : 'om %s',
36313
  past : '%s siden',
36314
  s : 'noen sekunder',
36315
+ ss : '%d sekunder',
36316
  m : 'ett minutt',
36317
  mm : '%d minutter',
36318
  h : 'en time',
36338
 
36339
 
36340
  /***/ },
36341
+ /* 382 */
36342
  /***/ function(module, exports, __webpack_require__) {
36343
 
36344
  //! moment.js locale configuration
36443
  future : '%sमा',
36444
  past : '%s अगाडि',
36445
  s : 'केही क्षण',
36446
+ ss : '%d सेकेण्ड',
36447
  m : 'एक मिनेट',
36448
  mm : '%d मिनेट',
36449
  h : 'एक घण्टा',
36467
 
36468
 
36469
  /***/ },
36470
+ /* 383 */
36471
  /***/ function(module, exports, __webpack_require__) {
36472
 
36473
  //! moment.js locale configuration
36533
  future : 'over %s',
36534
  past : '%s geleden',
36535
  s : 'een paar seconden',
36536
+ ss : '%d seconden',
36537
  m : 'één minuut',
36538
  mm : '%d minuten',
36539
  h : 'één uur',
36561
 
36562
 
36563
  /***/ },
36564
+ /* 384 */
36565
  /***/ function(module, exports, __webpack_require__) {
36566
 
36567
  //! moment.js locale configuration
36627
  future : 'over %s',
36628
  past : '%s geleden',
36629
  s : 'een paar seconden',
36630
+ ss : '%d seconden',
36631
  m : 'één minuut',
36632
  mm : '%d minuten',
36633
  h : 'één uur',
36655
 
36656
 
36657
  /***/ },
36658
+ /* 385 */
36659
  /***/ function(module, exports, __webpack_require__) {
36660
 
36661
  //! moment.js locale configuration
36695
  future : 'om %s',
36696
  past : '%s sidan',
36697
  s : 'nokre sekund',
36698
+ ss : '%d sekund',
36699
  m : 'eit minutt',
36700
  mm : '%d minutt',
36701
  h : 'ein time',
36721
 
36722
 
36723
  /***/ },
36724
+ /* 386 */
36725
  /***/ function(module, exports, __webpack_require__) {
36726
 
36727
  //! moment.js locale configuration
36787
  future : '%s ਵਿੱਚ',
36788
  past : '%s ਪਿਛਲੇ',
36789
  s : 'ਕੁਝ ਸਕਿੰਟ',
36790
+ ss : '%d ਸਕਿੰਟ',
36791
  m : 'ਇਕ ਮਿੰਟ',
36792
  mm : '%d ਮਿੰਟ',
36793
  h : 'ਇੱਕ ਘੰਟਾ',
36851
 
36852
 
36853
  /***/ },
36854
+ /* 387 */
36855
  /***/ function(module, exports, __webpack_require__) {
36856
 
36857
  //! moment.js locale configuration
36873
  function translate(number, withoutSuffix, key) {
36874
  var result = number + ' ';
36875
  switch (key) {
36876
+ case 'ss':
36877
+ return result + (plural(number) ? 'sekundy' : 'sekund');
36878
  case 'm':
36879
  return withoutSuffix ? 'minuta' : 'minutę';
36880
  case 'mm':
36957
  future : 'za %s',
36958
  past : '%s temu',
36959
  s : 'kilka sekund',
36960
+ ss : translate,
36961
  m : translate,
36962
  mm : translate,
36963
  h : translate,
36983
 
36984
 
36985
  /***/ },
36986
+ /* 388 */
36987
  /***/ function(module, exports, __webpack_require__) {
36988
 
36989
  //! moment.js locale configuration
37028
  future : 'em %s',
37029
  past : 'há %s',
37030
  s : 'segundos',
37031
+ ss : '%d segundos',
37032
  m : 'um minuto',
37033
  mm : '%d minutos',
37034
  h : 'uma hora',
37054
 
37055
 
37056
  /***/ },
37057
+ /* 389 */
37058
  /***/ function(module, exports, __webpack_require__) {
37059
 
37060
  //! moment.js locale configuration
37121
 
37122
 
37123
  /***/ },
37124
+ /* 390 */
37125
  /***/ function(module, exports, __webpack_require__) {
37126
 
37127
  //! moment.js locale configuration
37138
 
37139
  function relativeTimeWithPlural(number, withoutSuffix, key) {
37140
  var format = {
37141
+ 'ss': 'secunde',
37142
  'mm': 'minute',
37143
  'hh': 'ore',
37144
  'dd': 'zile',
37179
  future : 'peste %s',
37180
  past : '%s în urmă',
37181
  s : 'câteva secunde',
37182
+ ss : relativeTimeWithPlural,
37183
  m : 'un minut',
37184
  mm : relativeTimeWithPlural,
37185
  h : 'o oră',
37203
 
37204
 
37205
  /***/ },
37206
+ /* 391 */
37207
  /***/ function(module, exports, __webpack_require__) {
37208
 
37209
  //! moment.js locale configuration
37225
  }
37226
  function relativeTimeWithPlural(number, withoutSuffix, key) {
37227
  var format = {
37228
+ 'ss': withoutSuffix ? 'секунда_секунды_секунд' : 'секунду_секунды_секунд',
37229
  'mm': withoutSuffix ? 'минута_минуты_минут' : 'минуту_минуты_минут',
37230
  'hh': 'час_часа_часов',
37231
  'dd': 'день_дня_дней',
37277
  // Выражение, которое соотвествует только сокращённым формам
37278
  monthsShortStrictRegex: /^(янв\.|февр?\.|мар[т.]|апр\.|ма[яй]|июн[ья.]|июл[ья.]|авг\.|сент?\.|окт\.|нояб?\.|дек\.)/i,
37279
  longDateFormat : {
37280
+ LT : 'H:mm',
37281
+ LTS : 'H:mm:ss',
37282
  L : 'DD.MM.YYYY',
37283
  LL : 'D MMMM YYYY г.',
37284
+ LLL : 'D MMMM YYYY г., H:mm',
37285
+ LLLL : 'dddd, D MMMM YYYY г., H:mm'
37286
  },
37287
  calendar : {
37288
  sameDay: '[Сегодня в] LT',
37338
  future : 'через %s',
37339
  past : '%s назад',
37340
  s : 'несколько секунд',
37341
+ ss : relativeTimeWithPlural,
37342
  m : relativeTimeWithPlural,
37343
  mm : relativeTimeWithPlural,
37344
  h : 'час',
37393
 
37394
 
37395
  /***/ },
37396
+ /* 392 */
37397
  /***/ function(module, exports, __webpack_require__) {
37398
 
37399
  //! moment.js locale configuration
37467
  future : '%s پوء',
37468
  past : '%s اڳ',
37469
  s : 'چند سيڪنڊ',
37470
+ ss : '%d سيڪنڊ',
37471
  m : 'هڪ منٽ',
37472
  mm : '%d منٽ',
37473
  h : 'هڪ ڪلاڪ',
37497
 
37498
 
37499
  /***/ },
37500
+ /* 393 */
37501
  /***/ function(module, exports, __webpack_require__) {
37502
 
37503
  //! moment.js locale configuration
37538
  future : '%s geažes',
37539
  past : 'maŋit %s',
37540
  s : 'moadde sekunddat',
37541
+ ss: '%d sekunddat',
37542
  m : 'okta minuhta',
37543
  mm : '%d minuhtat',
37544
  h : 'okta diimmu',
37564
 
37565
 
37566
  /***/ },
37567
+ /* 394 */
37568
  /***/ function(module, exports, __webpack_require__) {
37569
 
37570
  //! moment.js locale configuration
37606
  future : '%sකින්',
37607
  past : '%sකට පෙර',
37608
  s : 'තත්පර කිහිපය',
37609
+ ss : 'තත්පර %d',
37610
  m : 'මිනිත්තුව',
37611
  mm : 'මිනිත්තු %d',
37612
  h : 'පැය',
37641
 
37642
 
37643
  /***/ },
37644
+ /* 395 */
37645
  /***/ function(module, exports, __webpack_require__) {
37646
 
37647
  //! moment.js locale configuration
37666
  switch (key) {
37667
  case 's': // a few seconds / in a few seconds / a few seconds ago
37668
  return (withoutSuffix || isFuture) ? 'pár sekúnd' : 'pár sekundami';
37669
+ case 'ss': // 9 seconds / in 9 seconds / 9 seconds ago
37670
+ if (withoutSuffix || isFuture) {
37671
+ return result + (plural(number) ? 'sekundy' : 'sekúnd');
37672
+ } else {
37673
+ return result + 'sekundami';
37674
+ }
37675
+ break;
37676
  case 'm': // a minute / in a minute / a minute ago
37677
  return withoutSuffix ? 'minúta' : (isFuture ? 'minútu' : 'minútou');
37678
  case 'mm': // 9 minutes / in 9 minutes / 9 minutes ago
37778
  future : 'za %s',
37779
  past : 'pred %s',
37780
  s : translate,
37781
+ ss : translate,
37782
  m : translate,
37783
  mm : translate,
37784
  h : translate,
37804
 
37805
 
37806
  /***/ },
37807
+ /* 396 */
37808
  /***/ function(module, exports, __webpack_require__) {
37809
 
37810
  //! moment.js locale configuration
37823
  switch (key) {
37824
  case 's':
37825
  return withoutSuffix || isFuture ? 'nekaj sekund' : 'nekaj sekundami';
37826
+ case 'ss':
37827
+ if (number === 1) {
37828
+ result += withoutSuffix ? 'sekundo' : 'sekundi';
37829
+ } else if (number === 2) {
37830
+ result += withoutSuffix || isFuture ? 'sekundi' : 'sekundah';
37831
+ } else if (number < 5) {
37832
+ result += withoutSuffix || isFuture ? 'sekunde' : 'sekundah';
37833
+ } else {
37834
+ result += withoutSuffix || isFuture ? 'sekund' : 'sekund';
37835
+ }
37836
+ return result;
37837
  case 'm':
37838
  return withoutSuffix ? 'ena minuta' : 'eno minuto';
37839
  case 'mm':
37957
  future : 'čez %s',
37958
  past : 'pred %s',
37959
  s : processRelativeTime,
37960
+ ss : processRelativeTime,
37961
  m : processRelativeTime,
37962
  mm : processRelativeTime,
37963
  h : processRelativeTime,
37983
 
37984
 
37985
  /***/ },
37986
+ /* 397 */
37987
  /***/ function(module, exports, __webpack_require__) {
37988
 
37989
  //! moment.js locale configuration
38033
  future : 'në %s',
38034
  past : '%s më parë',
38035
  s : 'disa sekonda',
38036
+ ss : '%d sekonda',
38037
  m : 'një minutë',
38038
  mm : '%d minuta',
38039
  h : 'një orë',
38059
 
38060
 
38061
  /***/ },
38062
+ /* 398 */
38063
  /***/ function(module, exports, __webpack_require__) {
38064
 
38065
  //! moment.js locale configuration
38075
 
38076
  var translator = {
38077
  words: { //Different grammatical cases
38078
+ ss: ['sekunda', 'sekunde', 'sekundi'],
38079
  m: ['jedan minut', 'jedne minute'],
38080
  mm: ['minut', 'minute', 'minuta'],
38081
  h: ['jedan sat', 'jednog sata'],
38150
  future : 'za %s',
38151
  past : 'pre %s',
38152
  s : 'nekoliko sekundi',
38153
+ ss : translator.translate,
38154
  m : translator.translate,
38155
  mm : translator.translate,
38156
  h : translator.translate,
38176
 
38177
 
38178
  /***/ },
38179
+ /* 399 */
38180
  /***/ function(module, exports, __webpack_require__) {
38181
 
38182
  //! moment.js locale configuration
38192
 
38193
  var translator = {
38194
  words: { //Different grammatical cases
38195
+ ss: ['секунда', 'секунде', 'секунди'],
38196
  m: ['један минут', 'једне минуте'],
38197
  mm: ['минут', 'минуте', 'минута'],
38198
  h: ['један сат', 'једног сата'],
38267
  future : 'за %s',
38268
  past : 'пре %s',
38269
  s : 'неколико секунди',
38270
+ ss : translator.translate,
38271
  m : translator.translate,
38272
  mm : translator.translate,
38273
  h : translator.translate,
38293
 
38294
 
38295
  /***/ },
38296
+ /* 400 */
38297
  /***/ function(module, exports, __webpack_require__) {
38298
 
38299
  //! moment.js locale configuration
38335
  future : 'nga %s',
38336
  past : 'wenteka nga %s',
38337
  s : 'emizuzwana lomcane',
38338
+ ss : '%d mzuzwana',
38339
  m : 'umzuzu',
38340
  mm : '%d emizuzu',
38341
  h : 'lihora',
38388
 
38389
 
38390
  /***/ },
38391
+ /* 401 */
38392
  /***/ function(module, exports, __webpack_require__) {
38393
 
38394
  //! moment.js locale configuration
38430
  future : 'om %s',
38431
  past : 'för %s sedan',
38432
  s : 'några sekunder',
38433
+ ss : '%d sekunder',
38434
  m : 'en minut',
38435
  mm : '%d minuter',
38436
  h : 'en timme',
38463
 
38464
 
38465
  /***/ },
38466
+ /* 402 */
38467
  /***/ function(module, exports, __webpack_require__) {
38468
 
38469
  //! moment.js locale configuration
38504
  future : '%s baadaye',
38505
  past : 'tokea %s',
38506
  s : 'hivi punde',
38507
+ ss : 'sekunde %d',
38508
  m : 'dakika moja',
38509
  mm : 'dakika %d',
38510
  h : 'saa limoja',
38528
 
38529
 
38530
  /***/ },
38531
+ /* 403 */
38532
  /***/ function(module, exports, __webpack_require__) {
38533
 
38534
  //! moment.js locale configuration
38593
  future : '%s இல்',
38594
  past : '%s முன்',
38595
  s : 'ஒரு சில விநாடிகள்',
38596
+ ss : '%d விநாடிகள்',
38597
  m : 'ஒரு நிமிடம்',
38598
  mm : '%d நிமிடங்கள்',
38599
  h : 'ஒரு மணி நேரம்',
38664
 
38665
 
38666
  /***/ },
38667
+ /* 404 */
38668
  /***/ function(module, exports, __webpack_require__) {
38669
 
38670
  //! moment.js locale configuration
38705
  future : '%s లో',
38706
  past : '%s క్రితం',
38707
  s : 'కొన్ని క్షణాలు',
38708
+ ss : '%d సెకన్లు',
38709
  m : 'ఒక నిమిషం',
38710
  mm : '%d నిమిషాలు',
38711
  h : 'ఒక గంట',
38759
 
38760
 
38761
  /***/ },
38762
+ /* 405 */
38763
  /***/ function(module, exports, __webpack_require__) {
38764
 
38765
  //! moment.js locale configuration
38800
  future : 'iha %s',
38801
  past : '%s liuba',
38802
  s : 'minutu balun',
38803
+ ss : 'minutu %d',
38804
  m : 'minutu ida',
38805
  mm : 'minutus %d',
38806
  h : 'horas ida',
38833
 
38834
 
38835
  /***/ },
38836
+ /* 406 */
38837
  /***/ function(module, exports, __webpack_require__) {
38838
 
38839
  //! moment.js locale configuration
38886
  future : 'อีก %s',
38887
  past : '%sที่แล้ว',
38888
  s : 'ไม่กี่วินาที',
38889
+ ss : '%d วินาที',
38890
  m : '1 นาที',
38891
  mm : '%d นาที',
38892
  h : '1 ชั่วโมง',
38906
 
38907
 
38908
  /***/ },
38909
+ /* 407 */
38910
  /***/ function(module, exports, __webpack_require__) {
38911
 
38912
  //! moment.js locale configuration
38946
  future : 'sa loob ng %s',
38947
  past : '%s ang nakalipas',
38948
  s : 'ilang segundo',
38949
+ ss : '%d segundo',
38950
  m : 'isang minuto',
38951
  mm : '%d minuto',
38952
  h : 'isang oras',
38974
 
38975
 
38976
  /***/ },
38977
+ /* 408 */
38978
  /***/ function(module, exports, __webpack_require__) {
38979
 
38980
  //! moment.js locale configuration
39017
  function translate(number, withoutSuffix, string, isFuture) {
39018
  var numberNoun = numberAsNoun(number);
39019
  switch (string) {
39020
+ case 'ss':
39021
+ return numberNoun + ' lup';
39022
  case 'mm':
39023
  return numberNoun + ' tup';
39024
  case 'hh':
39076
  future : translateFuture,
39077
  past : translatePast,
39078
  s : 'puS lup',
39079
+ ss : translate,
39080
  m : 'wa’ tup',
39081
  mm : translate,
39082
  h : 'wa’ rep',
39102
 
39103
 
39104
  /***/ },
39105
+ /* 409 */
39106
  /***/ function(module, exports, __webpack_require__) {
39107
 
39108
  //! moment.js locale configuration
39164
  future : '%s sonra',
39165
  past : '%s önce',
39166
  s : 'birkaç saniye',
39167
+ ss : '%d saniye',
39168
  m : 'bir dakika',
39169
  mm : '%d dakika',
39170
  h : 'bir saat',
39198
 
39199
 
39200
  /***/ },
39201
+ /* 410 */
39202
  /***/ function(module, exports, __webpack_require__) {
39203
 
39204
  //! moment.js locale configuration
39252
  future : 'osprei %s',
39253
  past : 'ja%s',
39254
  s : processRelativeTime,
39255
+ ss : processRelativeTime,
39256
  m : processRelativeTime,
39257
  mm : processRelativeTime,
39258
  h : processRelativeTime,
39275
  function processRelativeTime(number, withoutSuffix, key, isFuture) {
39276
  var format = {
39277
  's': ['viensas secunds', '\'iensas secunds'],
39278
+ 'ss': [number + ' secunds', '' + number + ' secunds'],
39279
  'm': ['\'n míut', '\'iens míut'],
39280
  'mm': [number + ' míuts', '' + number + ' míuts'],
39281
  'h': ['\'n þora', '\'iensa þora'],
39296
 
39297
 
39298
  /***/ },
39299
+ /* 411 */
39300
  /***/ function(module, exports, __webpack_require__) {
39301
 
39302
  //! moment.js locale configuration
39336
  future : 'ⴷⴰⴷⵅ ⵙ ⵢⴰⵏ %s',
39337
  past : 'ⵢⴰⵏ %s',
39338
  s : 'ⵉⵎⵉⴽ',
39339
+ ss : '%d ⵉⵎⵉⴽ',
39340
  m : 'ⵎⵉⵏⵓⴺ',
39341
  mm : '%d ⵎⵉⵏⵓⴺ',
39342
  h : 'ⵙⴰⵄⴰ',
39360
 
39361
 
39362
  /***/ },
39363
+ /* 412 */
39364
  /***/ function(module, exports, __webpack_require__) {
39365
 
39366
  //! moment.js locale configuration
39400
  future : 'dadkh s yan %s',
39401
  past : 'yan %s',
39402
  s : 'imik',
39403
+ ss : '%d imik',
39404
  m : 'minuḍ',
39405
  mm : '%d minuḍ',
39406
  h : 'saɛa',
39424
 
39425
 
39426
  /***/ },
39427
+ /* 413 */
39428
  /***/ function(module, exports, __webpack_require__) {
39429
 
39430
  //! moment.js locale configuration
39445
  }
39446
  function relativeTimeWithPlural(number, withoutSuffix, key) {
39447
  var format = {
39448
+ 'ss': withoutSuffix ? 'секунда_секунди_секунд' : 'секунду_секунди_секунд',
39449
  'mm': withoutSuffix ? 'хвилина_хвилини_хвилин' : 'хвилину_хвилини_хвилин',
39450
  'hh': withoutSuffix ? 'година_години_годин' : 'годину_години_годин',
39451
  'dd': 'день_дні_днів',
39527
  future : 'за %s',
39528
  past : '%s тому',
39529
  s : 'декілька секунд',
39530
+ ss : relativeTimeWithPlural,
39531
  m : relativeTimeWithPlural,
39532
  mm : relativeTimeWithPlural,
39533
  h : 'годину',
39582
 
39583
 
39584
  /***/ },
39585
+ /* 414 */
39586
  /***/ function(module, exports, __webpack_require__) {
39587
 
39588
  //! moment.js locale configuration
39657
  future : '%s بعد',
39658
  past : '%s قبل',
39659
  s : 'چند سیکنڈ',
39660
+ ss : '%d سیکنڈ',
39661
  m : 'ایک منٹ',
39662
  mm : '%d منٹ',
39663
  h : 'ایک گھنٹہ',
39687
 
39688
 
39689
  /***/ },
39690
+ /* 415 */
39691
  /***/ function(module, exports, __webpack_require__) {
39692
 
39693
  //! moment.js locale configuration
39727
  future : 'Якин %s ичида',
39728
  past : 'Бир неча %s олдин',
39729
  s : 'фурсат',
39730
+ ss : '%d фурсат',
39731
  m : 'бир дакика',
39732
  mm : '%d дакика',
39733
  h : 'бир соат',
39751
 
39752
 
39753
  /***/ },
39754
+ /* 416 */
39755
  /***/ function(module, exports, __webpack_require__) {
39756
 
39757
  //! moment.js locale configuration
39791
  future : 'Yaqin %s ichida',
39792
  past : 'Bir necha %s oldin',
39793
  s : 'soniya',
39794
+ ss : '%d soniya',
39795
  m : 'bir daqiqa',
39796
  mm : '%d daqiqa',
39797
  h : 'bir soat',
39815
 
39816
 
39817
  /***/ },
39818
+ /* 417 */
39819
  /***/ function(module, exports, __webpack_require__) {
39820
 
39821
  //! moment.js locale configuration
39872
  future : '%s tới',
39873
  past : '%s trước',
39874
  s : 'vài giây',
39875
+ ss : '%d giây' ,
39876
  m : 'một phút',
39877
  mm : '%d phút',
39878
  h : 'một giờ',
39900
 
39901
 
39902
  /***/ },
39903
+ /* 418 */
39904
  /***/ function(module, exports, __webpack_require__) {
39905
 
39906
  //! moment.js locale configuration
39941
  future : 'í~ñ %s',
39942
  past : '%s á~gó',
39943
  s : 'á ~féw ~sécó~ñds',
39944
+ ss : '%d s~écóñ~ds',
39945
  m : 'á ~míñ~úté',
39946
  mm : '%d m~íñú~tés',
39947
  h : 'á~ñ hó~úr',
39974
 
39975
 
39976
  /***/ },
39977
+ /* 419 */
39978
  /***/ function(module, exports, __webpack_require__) {
39979
 
39980
  //! moment.js locale configuration
40014
  future : 'ní %s',
40015
  past : '%s kọjá',
40016
  s : 'ìsẹjú aayá die',
40017
+ ss :'aayá %d',
40018
  m : 'ìsẹjú kan',
40019
  mm : 'ìsẹjú %d',
40020
  h : 'wákati kan',
40040
 
40041
 
40042
  /***/ },
40043
+ /* 420 */
40044
  /***/ function(module, exports, __webpack_require__) {
40045
 
40046
  //! moment.js locale configuration
40064
  longDateFormat : {
40065
  LT : 'HH:mm',
40066
  LTS : 'HH:mm:ss',
40067
+ L : 'YYYY/MM/DD',
40068
+ LL : 'YYYY年M月D日',
40069
+ LLL : 'YYYY年M月D日Ah点mm分',
40070
+ LLLL : 'YYYY年M月D日ddddAh点mm分',
40071
+ l : 'YYYY/M/D',
40072
+ ll : 'YYYY年M月D日',
40073
+ lll : 'YYYY年M月D日 HH:mm',
40074
+ llll : 'YYYY年M月D日dddd HH:mm'
40075
  },
40076
  meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
40077
  meridiemHour: function (hour, meridiem) {
40132
  future : '%s内',
40133
  past : '%s前',
40134
  s : '几秒',
40135
+ ss : '%d 秒',
40136
  m : '1 分钟',
40137
  mm : '%d 分钟',
40138
  h : '1 小时',
40157
 
40158
 
40159
  /***/ },
40160
+ /* 421 */
40161
  /***/ function(module, exports, __webpack_require__) {
40162
 
40163
  //! moment.js locale configuration
40182
  longDateFormat : {
40183
  LT : 'HH:mm',
40184
  LTS : 'HH:mm:ss',
40185
+ L : 'YYYY/MM/DD',
40186
+ LL : 'YYYY年M月D日',
40187
+ LLL : 'YYYY年M月D日 HH:mm',
40188
+ LLLL : 'YYYY年M月D日dddd HH:mm',
40189
+ l : 'YYYY/M/D',
40190
+ ll : 'YYYY年M月D日',
40191
+ lll : 'YYYY年M月D日 HH:mm',
40192
+ llll : 'YYYY年M月D日dddd HH:mm'
40193
  },
40194
  meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
40195
  meridiemHour : function (hour, meridiem) {
40248
  future : '%s內',
40249
  past : '%s前',
40250
  s : '幾秒',
40251
+ ss : '%d 秒',
40252
  m : '1 分鐘',
40253
  mm : '%d 分鐘',
40254
  h : '1 小時',
40268
 
40269
 
40270
  /***/ },
40271
+ /* 422 */
40272
  /***/ function(module, exports, __webpack_require__) {
40273
 
40274
  //! moment.js locale configuration
40292
  longDateFormat : {
40293
  LT : 'HH:mm',
40294
  LTS : 'HH:mm:ss',
40295
+ L : 'YYYY/MM/DD',
40296
+ LL : 'YYYY年M月D日',
40297
+ LLL : 'YYYY年M月D日 HH:mm',
40298
+ LLLL : 'YYYY年M月D日dddd HH:mm',
40299
+ l : 'YYYY/M/D',
40300
+ ll : 'YYYY年M月D日',
40301
+ lll : 'YYYY年M月D日 HH:mm',
40302
+ llll : 'YYYY年M月D日dddd HH:mm'
40303
  },
40304
  meridiemParse: /凌晨|早上|上午|中午|下午|晚上/,
40305
  meridiemHour : function (hour, meridiem) {
40358
  future : '%s內',
40359
  past : '%s前',
40360
  s : '幾秒',
40361
+ ss : '%d 秒',
40362
  m : '1 分鐘',
40363
  mm : '%d 分鐘',
40364
  h : '1 小時',
40378
 
40379
 
40380
  /***/ },
 
40381
  /* 423 */,
40382
  /* 424 */,
40383
  /* 425 */,
40391
  /* 433 */,
40392
  /* 434 */,
40393
  /* 435 */,
40394
+ /* 436 */,
40395
+ /* 437 */
40396
  /***/ function(module, exports, __webpack_require__) {
40397
 
40398
  'use strict';
40403
 
40404
  var _react2 = _interopRequireDefault(_react);
40405
 
40406
+ var _reactTooltip = __webpack_require__(438);
40407
 
40408
  var _reactTooltip2 = _interopRequireDefault(_reactTooltip);
40409
 
40410
+ var _reactHtmlParser = __webpack_require__(451);
40411
 
40412
  var _reactHtmlParser2 = _interopRequireDefault(_reactHtmlParser);
40413
 
40475
  module.exports = Tooltip;
40476
 
40477
  /***/ },
40478
+ /* 438 */
40479
  /***/ function(module, exports, __webpack_require__) {
40480
 
40481
  'use strict';
40511
 
40512
  var _classnames2 = _interopRequireDefault(_classnames);
40513
 
40514
+ var _staticMethods = __webpack_require__(439);
40515
 
40516
  var _staticMethods2 = _interopRequireDefault(_staticMethods);
40517
 
40518
+ var _windowListener = __webpack_require__(441);
40519
 
40520
  var _windowListener2 = _interopRequireDefault(_windowListener);
40521
 
40522
+ var _customEvent = __webpack_require__(442);
40523
 
40524
  var _customEvent2 = _interopRequireDefault(_customEvent);
40525
 
40526
+ var _isCapture = __webpack_require__(443);
40527
 
40528
  var _isCapture2 = _interopRequireDefault(_isCapture);
40529
 
40530
+ var _getEffect = __webpack_require__(444);
40531
 
40532
  var _getEffect2 = _interopRequireDefault(_getEffect);
40533
 
40534
+ var _trackRemoval = __webpack_require__(445);
40535
 
40536
  var _trackRemoval2 = _interopRequireDefault(_trackRemoval);
40537
 
40538
+ var _getPosition = __webpack_require__(446);
40539
 
40540
  var _getPosition2 = _interopRequireDefault(_getPosition);
40541
 
40542
+ var _getTipContent = __webpack_require__(447);
40543
 
40544
  var _getTipContent2 = _interopRequireDefault(_getTipContent);
40545
 
40546
+ var _aria = __webpack_require__(448);
40547
 
40548
+ var _nodeListToArray = __webpack_require__(449);
40549
 
40550
  var _nodeListToArray2 = _interopRequireDefault(_nodeListToArray);
40551
 
40552
+ var _style = __webpack_require__(450);
40553
 
40554
  var _style2 = _interopRequireDefault(_style);
40555
 
41074
  module.exports = ReactTooltip;
41075
 
41076
  /***/ },
41077
+ /* 439 */
41078
  /***/ function(module, exports, __webpack_require__) {
41079
 
41080
  'use strict';
41132
  };
41133
  };
41134
 
41135
+ var _constant = __webpack_require__(440);
41136
 
41137
  var _constant2 = _interopRequireDefault(_constant);
41138
 
41157
  */
41158
 
41159
  /***/ },
41160
+ /* 440 */
41161
  /***/ function(module, exports) {
41162
 
41163
  'use strict';
41175
  };
41176
 
41177
  /***/ },
41178
+ /* 441 */
41179
  /***/ function(module, exports, __webpack_require__) {
41180
 
41181
  'use strict';
41221
  };
41222
  };
41223
 
41224
+ var _constant = __webpack_require__(440);
41225
 
41226
  var _constant2 = _interopRequireDefault(_constant);
41227
 
41228
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
41229
 
41230
  /***/ },
41231
+ /* 442 */
41232
  /***/ function(module, exports) {
41233
 
41234
  'use strict';
41321
  var customListener = void 0;
41322
 
41323
  /***/ },
41324
+ /* 443 */
41325
  /***/ function(module, exports) {
41326
 
41327
  'use strict';
41338
  };
41339
 
41340
  /***/ },
41341
+ /* 444 */
41342
  /***/ function(module, exports) {
41343
 
41344
  'use strict';
41355
  };
41356
 
41357
  /***/ },
41358
+ /* 445 */
41359
  /***/ function(module, exports) {
41360
 
41361
  "use strict";
41451
  };
41452
 
41453
  /***/ },
41454
+ /* 446 */
41455
  /***/ function(module, exports) {
41456
 
41457
  'use strict';
41765
  };
41766
 
41767
  /***/ },
41768
+ /* 447 */
41769
  /***/ function(module, exports, __webpack_require__) {
41770
 
41771
  'use strict';
41802
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
41803
 
41804
  /***/ },
41805
+ /* 448 */
41806
  /***/ function(module, exports) {
41807
 
41808
  "use strict";
41831
  }
41832
 
41833
  /***/ },
41834
+ /* 449 */
41835
  /***/ function(module, exports) {
41836
 
41837
  "use strict";
41851
  };
41852
 
41853
  /***/ },
41854
+ /* 450 */
41855
  /***/ function(module, exports) {
41856
 
41857
  'use strict';
41862
  exports.default = '.__react_component_tooltip{border-radius:3px;display:inline-block;font-size:13px;left:-999em;opacity:0;padding:8px 21px;position:fixed;pointer-events:none;transition:opacity 0.3s ease-out;top:-999em;visibility:hidden;z-index:999}.__react_component_tooltip:before,.__react_component_tooltip:after{content:"";width:0;height:0;position:absolute}.__react_component_tooltip.show{opacity:0.9;margin-top:0px;margin-left:0px;visibility:visible}.__react_component_tooltip.type-dark{color:#fff;background-color:#222}.__react_component_tooltip.type-dark.place-top:after{border-top-color:#222;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-dark.place-bottom:after{border-bottom-color:#222;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-dark.place-left:after{border-left-color:#222;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-dark.place-right:after{border-right-color:#222;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-dark.border{border:1px solid #fff}.__react_component_tooltip.type-dark.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-dark.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-dark.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-dark.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-success{color:#fff;background-color:#8DC572}.__react_component_tooltip.type-success.place-top:after{border-top-color:#8DC572;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-success.place-bottom:after{border-bottom-color:#8DC572;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-success.place-left:after{border-left-color:#8DC572;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-success.place-right:after{border-right-color:#8DC572;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-success.border{border:1px solid #fff}.__react_component_tooltip.type-success.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-success.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-success.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-success.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-warning{color:#fff;background-color:#F0AD4E}.__react_component_tooltip.type-warning.place-top:after{border-top-color:#F0AD4E;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-warning.place-bottom:after{border-bottom-color:#F0AD4E;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-warning.place-left:after{border-left-color:#F0AD4E;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-warning.place-right:after{border-right-color:#F0AD4E;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-warning.border{border:1px solid #fff}.__react_component_tooltip.type-warning.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-warning.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-warning.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-warning.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-error{color:#fff;background-color:#BE6464}.__react_component_tooltip.type-error.place-top:after{border-top-color:#BE6464;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-error.place-bottom:after{border-bottom-color:#BE6464;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-error.place-left:after{border-left-color:#BE6464;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-error.place-right:after{border-right-color:#BE6464;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-error.border{border:1px solid #fff}.__react_component_tooltip.type-error.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-error.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-error.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-error.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-info{color:#fff;background-color:#337AB7}.__react_component_tooltip.type-info.place-top:after{border-top-color:#337AB7;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-info.place-bottom:after{border-bottom-color:#337AB7;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-info.place-left:after{border-left-color:#337AB7;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-info.place-right:after{border-right-color:#337AB7;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-info.border{border:1px solid #fff}.__react_component_tooltip.type-info.border.place-top:before{border-top:8px solid #fff}.__react_component_tooltip.type-info.border.place-bottom:before{border-bottom:8px solid #fff}.__react_component_tooltip.type-info.border.place-left:before{border-left:8px solid #fff}.__react_component_tooltip.type-info.border.place-right:before{border-right:8px solid #fff}.__react_component_tooltip.type-light{color:#222;background-color:#fff}.__react_component_tooltip.type-light.place-top:after{border-top-color:#fff;border-top-style:solid;border-top-width:6px}.__react_component_tooltip.type-light.place-bottom:after{border-bottom-color:#fff;border-bottom-style:solid;border-bottom-width:6px}.__react_component_tooltip.type-light.place-left:after{border-left-color:#fff;border-left-style:solid;border-left-width:6px}.__react_component_tooltip.type-light.place-right:after{border-right-color:#fff;border-right-style:solid;border-right-width:6px}.__react_component_tooltip.type-light.border{border:1px solid #222}.__react_component_tooltip.type-light.border.place-top:before{border-top:8px solid #222}.__react_component_tooltip.type-light.border.place-bottom:before{border-bottom:8px solid #222}.__react_component_tooltip.type-light.border.place-left:before{border-left:8px solid #222}.__react_component_tooltip.type-light.border.place-right:before{border-right:8px solid #222}.__react_component_tooltip.place-top{margin-top:-10px}.__react_component_tooltip.place-top:before{border-left:10px solid transparent;border-right:10px solid transparent;bottom:-8px;left:50%;margin-left:-10px}.__react_component_tooltip.place-top:after{border-left:8px solid transparent;border-right:8px solid transparent;bottom:-6px;left:50%;margin-left:-8px}.__react_component_tooltip.place-bottom{margin-top:10px}.__react_component_tooltip.place-bottom:before{border-left:10px solid transparent;border-right:10px solid transparent;top:-8px;left:50%;margin-left:-10px}.__react_component_tooltip.place-bottom:after{border-left:8px solid transparent;border-right:8px solid transparent;top:-6px;left:50%;margin-left:-8px}.__react_component_tooltip.place-left{margin-left:-10px}.__react_component_tooltip.place-left:before{border-top:6px solid transparent;border-bottom:6px solid transparent;right:-8px;top:50%;margin-top:-5px}.__react_component_tooltip.place-left:after{border-top:5px solid transparent;border-bottom:5px solid transparent;right:-6px;top:50%;margin-top:-4px}.__react_component_tooltip.place-right{margin-left:10px}.__react_component_tooltip.place-right:before{border-top:6px solid transparent;border-bottom:6px solid transparent;left:-8px;top:50%;margin-top:-5px}.__react_component_tooltip.place-right:after{border-top:5px solid transparent;border-bottom:5px solid transparent;left:-6px;top:50%;margin-top:-4px}.__react_component_tooltip .multi-line{display:block;padding:2px 0px;text-align:center}';
41863
 
41864
  /***/ },
41865
+ /* 451 */
41866
  /***/ function(module, exports, __webpack_require__) {
41867
 
41868
  'use strict';
41871
  value: true
41872
  });
41873
 
41874
+ var _HtmlParser = __webpack_require__(452);
41875
 
41876
  var _HtmlParser2 = _interopRequireDefault(_HtmlParser);
41877
 
41880
  exports.default = _HtmlParser2.default;
41881
 
41882
  /***/ },
41883
+ /* 452 */
41884
  /***/ function(module, exports, __webpack_require__) {
41885
 
41886
  'use strict';
41890
  });
41891
  exports.default = HtmlParser;
41892
 
41893
+ var _htmlparser = __webpack_require__(453);
41894
 
41895
  var _htmlparser2 = _interopRequireDefault(_htmlparser);
41896
 
41897
+ var _ProcessNodes = __webpack_require__(506);
41898
 
41899
  var _ProcessNodes2 = _interopRequireDefault(_ProcessNodes);
41900
 
41912
  }
41913
 
41914
  /***/ },
41915
+ /* 453 */
41916
  /***/ function(module, exports, __webpack_require__) {
41917
 
41918
+ var Parser = __webpack_require__(454),
41919
+ DomHandler = __webpack_require__(463);
41920
 
41921
  function defineProp(name, value){
41922
  delete module.exports[name];
41926
 
41927
  module.exports = {
41928
  Parser: Parser,
41929
+ Tokenizer: __webpack_require__(455),
41930
+ ElementType: __webpack_require__(464),
41931
  DomHandler: DomHandler,
41932
  get FeedHandler(){
41933
+ return defineProp("FeedHandler", __webpack_require__(467));
41934
  },
41935
  get Stream(){
41936
+ return defineProp("Stream", __webpack_require__(468));
41937
  },
41938
  get WritableStream(){
41939
+ return defineProp("WritableStream", __webpack_require__(469));
41940
  },
41941
  get ProxyHandler(){
41942
+ return defineProp("ProxyHandler", __webpack_require__(492));
41943
  },
41944
  get DomUtils(){
41945
+ return defineProp("DomUtils", __webpack_require__(493));
41946
  },
41947
  get CollectingHandler(){
41948
+ return defineProp("CollectingHandler", __webpack_require__(505));
41949
  },
41950
  // For legacy support
41951
  DefaultHandler: DomHandler,
41986
 
41987
 
41988
  /***/ },
41989
+ /* 454 */
41990
  /***/ function(module, exports, __webpack_require__) {
41991
 
41992
+ var Tokenizer = __webpack_require__(455);
41993
 
41994
  /*
41995
  Options:
42111
  if(this._cbs.onparserinit) this._cbs.onparserinit(this);
42112
  }
42113
 
42114
+ __webpack_require__(461)(Parser, __webpack_require__(462).EventEmitter);
42115
 
42116
  Parser.prototype._updatePosition = function(initialOffset){
42117
  if(this.endIndex === null){
42345
 
42346
 
42347
  /***/ },
42348
+ /* 455 */
42349
  /***/ function(module, exports, __webpack_require__) {
42350
 
42351
  module.exports = Tokenizer;
42352
 
42353
+ var decodeCodePoint = __webpack_require__(456),
42354
+ entityMap = __webpack_require__(458),
42355
+ legacyMap = __webpack_require__(459),
42356
+ xmlMap = __webpack_require__(460),
42357
 
42358
  i = 0,
42359
 
43257
 
43258
 
43259
  /***/ },
43260
+ /* 456 */
43261
  /***/ function(module, exports, __webpack_require__) {
43262
 
43263
+ var decodeMap = __webpack_require__(457);
43264
 
43265
  module.exports = decodeCodePoint;
43266
 
43289
 
43290
 
43291
  /***/ },
43292
+ /* 457 */
43293
  /***/ function(module, exports) {
43294
 
43295
  module.exports = {"0":65533,"128":8364,"130":8218,"131":402,"132":8222,"133":8230,"134":8224,"135":8225,"136":710,"137":8240,"138":352,"139":8249,"140":338,"142":381,"145":8216,"146":8217,"147":8220,"148":8221,"149":8226,"150":8211,"151":8212,"152":732,"153":8482,"154":353,"155":8250,"156":339,"158":382,"159":376}
43296
 
43297
  /***/ },
43298
+ /* 458 */
43299
  /***/ function(module, exports) {
43300
 
43301
  module.exports = {"Aacute":"Á","aacute":"á","Abreve":"Ă","abreve":"ă","ac":"∾","acd":"∿","acE":"∾̳","Acirc":"Â","acirc":"â","acute":"´","Acy":"А","acy":"а","AElig":"Æ","aelig":"æ","af":"⁡","Afr":"𝔄","afr":"𝔞","Agrave":"À","agrave":"à","alefsym":"ℵ","aleph":"ℵ","Alpha":"Α","alpha":"α","Amacr":"Ā","amacr":"ā","amalg":"⨿","amp":"&","AMP":"&","andand":"⩕","And":"⩓","and":"∧","andd":"⩜","andslope":"⩘","andv":"⩚","ang":"∠","ange":"⦤","angle":"∠","angmsdaa":"⦨","angmsdab":"⦩","angmsdac":"⦪","angmsdad":"⦫","angmsdae":"⦬","angmsdaf":"⦭","angmsdag":"⦮","angmsdah":"⦯","angmsd":"∡","angrt":"∟","angrtvb":"⊾","angrtvbd":"⦝","angsph":"∢","angst":"Å","angzarr":"⍼","Aogon":"Ą","aogon":"ą","Aopf":"𝔸","aopf":"𝕒","apacir":"⩯","ap":"≈","apE":"⩰","ape":"≊","apid":"≋","apos":"'","ApplyFunction":"⁡","approx":"≈","approxeq":"≊","Aring":"Å","aring":"å","Ascr":"𝒜","ascr":"𝒶","Assign":"≔","ast":"*","asymp":"≈","asympeq":"≍","Atilde":"Ã","atilde":"ã","Auml":"Ä","auml":"ä","awconint":"∳","awint":"⨑","backcong":"≌","backepsilon":"϶","backprime":"‵","backsim":"∽","backsimeq":"⋍","Backslash":"∖","Barv":"⫧","barvee":"⊽","barwed":"⌅","Barwed":"⌆","barwedge":"⌅","bbrk":"⎵","bbrktbrk":"⎶","bcong":"≌","Bcy":"Б","bcy":"б","bdquo":"„","becaus":"∵","because":"∵","Because":"∵","bemptyv":"⦰","bepsi":"϶","bernou":"ℬ","Bernoullis":"ℬ","Beta":"Β","beta":"β","beth":"ℶ","between":"≬","Bfr":"𝔅","bfr":"𝔟","bigcap":"⋂","bigcirc":"◯","bigcup":"⋃","bigodot":"⨀","bigoplus":"⨁","bigotimes":"⨂","bigsqcup":"⨆","bigstar":"★","bigtriangledown":"▽","bigtriangleup":"△","biguplus":"⨄","bigvee":"⋁","bigwedge":"⋀","bkarow":"⤍","blacklozenge":"⧫","blacksquare":"▪","blacktriangle":"▴","blacktriangledown":"▾","blacktriangleleft":"◂","blacktriangleright":"▸","blank":"␣","blk12":"▒","blk14":"░","blk34":"▓","block":"█","bne":"=⃥","bnequiv":"≡⃥","bNot":"⫭","bnot":"⌐","Bopf":"𝔹","bopf":"𝕓","bot":"⊥","bottom":"⊥","bowtie":"⋈","boxbox":"⧉","boxdl":"┐","boxdL":"╕","boxDl":"╖","boxDL":"╗","boxdr":"┌","boxdR":"╒","boxDr":"╓","boxDR":"╔","boxh":"─","boxH":"═","boxhd":"┬","boxHd":"╤","boxhD":"╥","boxHD":"╦","boxhu":"┴","boxHu":"╧","boxhU":"╨","boxHU":"╩","boxminus":"⊟","boxplus":"⊞","boxtimes":"⊠","boxul":"┘","boxuL":"╛","boxUl":"╜","boxUL":"╝","boxur":"└","boxuR":"╘","boxUr":"╙","boxUR":"╚","boxv":"│","boxV":"║","boxvh":"┼","boxvH":"╪","boxVh":"╫","boxVH":"╬","boxvl":"┤","boxvL":"╡","boxVl":"╢","boxVL":"╣","boxvr":"├","boxvR":"╞","boxVr":"╟","boxVR":"╠","bprime":"‵","breve":"˘","Breve":"˘","brvbar":"¦","bscr":"𝒷","Bscr":"ℬ","bsemi":"⁏","bsim":"∽","bsime":"⋍","bsolb":"⧅","bsol":"\\","bsolhsub":"⟈","bull":"•","bullet":"•","bump":"≎","bumpE":"⪮","bumpe":"≏","Bumpeq":"≎","bumpeq":"≏","Cacute":"Ć","cacute":"ć","capand":"⩄","capbrcup":"⩉","capcap":"⩋","cap":"∩","Cap":"⋒","capcup":"⩇","capdot":"⩀","CapitalDifferentialD":"ⅅ","caps":"∩︀","caret":"⁁","caron":"ˇ","Cayleys":"ℭ","ccaps":"⩍","Ccaron":"Č","ccaron":"č","Ccedil":"Ç","ccedil":"ç","Ccirc":"Ĉ","ccirc":"ĉ","Cconint":"∰","ccups":"⩌","ccupssm":"⩐","Cdot":"Ċ","cdot":"ċ","cedil":"¸","Cedilla":"¸","cemptyv":"⦲","cent":"¢","centerdot":"·","CenterDot":"·","cfr":"𝔠","Cfr":"ℭ","CHcy":"Ч","chcy":"ч","check":"✓","checkmark":"✓","Chi":"Χ","chi":"χ","circ":"ˆ","circeq":"≗","circlearrowleft":"↺","circlearrowright":"↻","circledast":"⊛","circledcirc":"⊚","circleddash":"⊝","CircleDot":"⊙","circledR":"®","circledS":"Ⓢ","CircleMinus":"⊖","CirclePlus":"⊕","CircleTimes":"⊗","cir":"○","cirE":"⧃","cire":"≗","cirfnint":"⨐","cirmid":"⫯","cirscir":"⧂","ClockwiseContourIntegral":"∲","CloseCurlyDoubleQuote":"”","CloseCurlyQuote":"’","clubs":"♣","clubsuit":"♣","colon":":","Colon":"∷","Colone":"⩴","colone":"≔","coloneq":"≔","comma":",","commat":"@","comp":"∁","compfn":"∘","complement":"∁","complexes":"ℂ","cong":"≅","congdot":"⩭","Congruent":"≡","conint":"∮","Conint":"∯","ContourIntegral":"∮","copf":"𝕔","Copf":"ℂ","coprod":"∐","Coproduct":"∐","copy":"©","COPY":"©","copysr":"℗","CounterClockwiseContourIntegral":"∳","crarr":"↵","cross":"✗","Cross":"⨯","Cscr":"𝒞","cscr":"𝒸","csub":"⫏","csube":"⫑","csup":"⫐","csupe":"⫒","ctdot":"⋯","cudarrl":"⤸","cudarrr":"⤵","cuepr":"⋞","cuesc":"⋟","cularr":"↶","cularrp":"⤽","cupbrcap":"⩈","cupcap":"⩆","CupCap":"≍","cup":"∪","Cup":"⋓","cupcup":"⩊","cupdot":"⊍","cupor":"⩅","cups":"∪︀","curarr":"↷","curarrm":"⤼","curlyeqprec":"⋞","curlyeqsucc":"⋟","curlyvee":"⋎","curlywedge":"⋏","curren":"¤","curvearrowleft":"↶","curvearrowright":"↷","cuvee":"⋎","cuwed":"⋏","cwconint":"∲","cwint":"∱","cylcty":"⌭","dagger":"†","Dagger":"‡","daleth":"ℸ","darr":"↓","Darr":"↡","dArr":"⇓","dash":"‐","Dashv":"⫤","dashv":"⊣","dbkarow":"⤏","dblac":"˝","Dcaron":"Ď","dcaron":"ď","Dcy":"Д","dcy":"д","ddagger":"‡","ddarr":"⇊","DD":"ⅅ","dd":"ⅆ","DDotrahd":"⤑","ddotseq":"⩷","deg":"°","Del":"∇","Delta":"Δ","delta":"δ","demptyv":"⦱","dfisht":"⥿","Dfr":"𝔇","dfr":"𝔡","dHar":"⥥","dharl":"⇃","dharr":"⇂","DiacriticalAcute":"´","DiacriticalDot":"˙","DiacriticalDoubleAcute":"˝","DiacriticalGrave":"`","DiacriticalTilde":"˜","diam":"⋄","diamond":"⋄","Diamond":"⋄","diamondsuit":"♦","diams":"♦","die":"¨","DifferentialD":"ⅆ","digamma":"ϝ","disin":"⋲","div":"÷","divide":"÷","divideontimes":"⋇","divonx":"⋇","DJcy":"Ђ","djcy":"ђ","dlcorn":"⌞","dlcrop":"⌍","dollar":"$","Dopf":"𝔻","dopf":"𝕕","Dot":"¨","dot":"˙","DotDot":"⃜","doteq":"≐","doteqdot":"≑","DotEqual":"≐","dotminus":"∸","dotplus":"∔","dotsquare":"⊡","doublebarwedge":"⌆","DoubleContourIntegral":"∯","DoubleDot":"¨","DoubleDownArrow":"⇓","DoubleLeftArrow":"⇐","DoubleLeftRightArrow":"⇔","DoubleLeftTee":"⫤","DoubleLongLeftArrow":"⟸","DoubleLongLeftRightArrow":"⟺","DoubleLongRightArrow":"⟹","DoubleRightArrow":"⇒","DoubleRightTee":"⊨","DoubleUpArrow":"⇑","DoubleUpDownArrow":"⇕","DoubleVerticalBar":"∥","DownArrowBar":"⤓","downarrow":"↓","DownArrow":"↓","Downarrow":"⇓","DownArrowUpArrow":"⇵","DownBreve":"̑","downdownarrows":"⇊","downharpoonleft":"⇃","downharpoonright":"⇂","DownLeftRightVector":"⥐","DownLeftTeeVector":"⥞","DownLeftVectorBar":"⥖","DownLeftVector":"↽","DownRightTeeVector":"⥟","DownRightVectorBar":"⥗","DownRightVector":"⇁","DownTeeArrow":"↧","DownTee":"⊤","drbkarow":"⤐","drcorn":"⌟","drcrop":"⌌","Dscr":"𝒟","dscr":"𝒹","DScy":"Ѕ","dscy":"ѕ","dsol":"⧶","Dstrok":"Đ","dstrok":"đ","dtdot":"⋱","dtri":"▿","dtrif":"▾","duarr":"⇵","duhar":"⥯","dwangle":"⦦","DZcy":"Џ","dzcy":"џ","dzigrarr":"⟿","Eacute":"É","eacute":"é","easter":"⩮","Ecaron":"Ě","ecaron":"ě","Ecirc":"Ê","ecirc":"ê","ecir":"≖","ecolon":"≕","Ecy":"Э","ecy":"э","eDDot":"⩷","Edot":"Ė","edot":"ė","eDot":"≑","ee":"ⅇ","efDot":"≒","Efr":"𝔈","efr":"𝔢","eg":"⪚","Egrave":"È","egrave":"è","egs":"⪖","egsdot":"⪘","el":"⪙","Element":"∈","elinters":"⏧","ell":"ℓ","els":"⪕","elsdot":"⪗","Emacr":"Ē","emacr":"ē","empty":"∅","emptyset":"∅","EmptySmallSquare":"◻","emptyv":"∅","EmptyVerySmallSquare":"▫","emsp13":" ","emsp14":" ","emsp":" ","ENG":"Ŋ","eng":"ŋ","ensp":" ","Eogon":"Ę","eogon":"ę","Eopf":"𝔼","eopf":"𝕖","epar":"⋕","eparsl":"⧣","eplus":"⩱","epsi":"ε","Epsilon":"Ε","epsilon":"ε","epsiv":"ϵ","eqcirc":"≖","eqcolon":"≕","eqsim":"≂","eqslantgtr":"⪖","eqslantless":"⪕","Equal":"⩵","equals":"=","EqualTilde":"≂","equest":"≟","Equilibrium":"⇌","equiv":"≡","equivDD":"⩸","eqvparsl":"⧥","erarr":"⥱","erDot":"≓","escr":"ℯ","Escr":"ℰ","esdot":"≐","Esim":"⩳","esim":"≂","Eta":"Η","eta":"η","ETH":"Ð","eth":"ð","Euml":"Ë","euml":"ë","euro":"€","excl":"!","exist":"∃","Exists":"∃","expectation":"ℰ","exponentiale":"ⅇ","ExponentialE":"ⅇ","fallingdotseq":"≒","Fcy":"Ф","fcy":"ф","female":"♀","ffilig":"ffi","fflig":"ff","ffllig":"ffl","Ffr":"𝔉","ffr":"𝔣","filig":"fi","FilledSmallSquare":"◼","FilledVerySmallSquare":"▪","fjlig":"fj","flat":"♭","fllig":"fl","fltns":"▱","fnof":"ƒ","Fopf":"𝔽","fopf":"𝕗","forall":"∀","ForAll":"∀","fork":"⋔","forkv":"⫙","Fouriertrf":"ℱ","fpartint":"⨍","frac12":"½","frac13":"⅓","frac14":"¼","frac15":"⅕","frac16":"⅙","frac18":"⅛","frac23":"⅔","frac25":"⅖","frac34":"¾","frac35":"⅗","frac38":"⅜","frac45":"⅘","frac56":"⅚","frac58":"⅝","frac78":"⅞","frasl":"⁄","frown":"⌢","fscr":"𝒻","Fscr":"ℱ","gacute":"ǵ","Gamma":"Γ","gamma":"γ","Gammad":"Ϝ","gammad":"ϝ","gap":"⪆","Gbreve":"Ğ","gbreve":"ğ","Gcedil":"Ģ","Gcirc":"Ĝ","gcirc":"ĝ","Gcy":"Г","gcy":"г","Gdot":"Ġ","gdot":"ġ","ge":"≥","gE":"≧","gEl":"⪌","gel":"⋛","geq":"≥","geqq":"≧","geqslant":"⩾","gescc":"⪩","ges":"⩾","gesdot":"⪀","gesdoto":"⪂","gesdotol":"⪄","gesl":"⋛︀","gesles":"⪔","Gfr":"𝔊","gfr":"𝔤","gg":"≫","Gg":"⋙","ggg":"⋙","gimel":"ℷ","GJcy":"Ѓ","gjcy":"ѓ","gla":"⪥","gl":"≷","glE":"⪒","glj":"⪤","gnap":"⪊","gnapprox":"⪊","gne":"⪈","gnE":"≩","gneq":"⪈","gneqq":"≩","gnsim":"⋧","Gopf":"𝔾","gopf":"𝕘","grave":"`","GreaterEqual":"≥","GreaterEqualLess":"⋛","GreaterFullEqual":"≧","GreaterGreater":"⪢","GreaterLess":"≷","GreaterSlantEqual":"⩾","GreaterTilde":"≳","Gscr":"𝒢","gscr":"ℊ","gsim":"≳","gsime":"⪎","gsiml":"⪐","gtcc":"⪧","gtcir":"⩺","gt":">","GT":">","Gt":"≫","gtdot":"⋗","gtlPar":"⦕","gtquest":"⩼","gtrapprox":"⪆","gtrarr":"⥸","gtrdot":"⋗","gtreqless":"⋛","gtreqqless":"⪌","gtrless":"≷","gtrsim":"≳","gvertneqq":"≩︀","gvnE":"≩︀","Hacek":"ˇ","hairsp":" ","half":"½","hamilt":"ℋ","HARDcy":"Ъ","hardcy":"ъ","harrcir":"⥈","harr":"↔","hArr":"⇔","harrw":"↭","Hat":"^","hbar":"ℏ","Hcirc":"Ĥ","hcirc":"ĥ","hearts":"♥","heartsuit":"♥","hellip":"…","hercon":"⊹","hfr":"𝔥","Hfr":"ℌ","HilbertSpace":"ℋ","hksearow":"⤥","hkswarow":"⤦","hoarr":"⇿","homtht":"∻","hookleftarrow":"↩","hookrightarrow":"↪","hopf":"𝕙","Hopf":"ℍ","horbar":"―","HorizontalLine":"─","hscr":"𝒽","Hscr":"ℋ","hslash":"ℏ","Hstrok":"Ħ","hstrok":"ħ","HumpDownHump":"≎","HumpEqual":"≏","hybull":"⁃","hyphen":"‐","Iacute":"Í","iacute":"í","ic":"⁣","Icirc":"Î","icirc":"î","Icy":"И","icy":"и","Idot":"İ","IEcy":"Е","iecy":"е","iexcl":"¡","iff":"⇔","ifr":"𝔦","Ifr":"ℑ","Igrave":"Ì","igrave":"ì","ii":"ⅈ","iiiint":"⨌","iiint":"∭","iinfin":"⧜","iiota":"℩","IJlig":"IJ","ijlig":"ij","Imacr":"Ī","imacr":"ī","image":"ℑ","ImaginaryI":"ⅈ","imagline":"ℐ","imagpart":"ℑ","imath":"ı","Im":"ℑ","imof":"⊷","imped":"Ƶ","Implies":"⇒","incare":"℅","in":"∈","infin":"∞","infintie":"⧝","inodot":"ı","intcal":"⊺","int":"∫","Int":"∬","integers":"ℤ","Integral":"∫","intercal":"⊺","Intersection":"⋂","intlarhk":"⨗","intprod":"⨼","InvisibleComma":"⁣","InvisibleTimes":"⁢","IOcy":"Ё","iocy":"ё","Iogon":"Į","iogon":"į","Iopf":"𝕀","iopf":"𝕚","Iota":"Ι","iota":"ι","iprod":"⨼","iquest":"¿","iscr":"𝒾","Iscr":"ℐ","isin":"∈","isindot":"⋵","isinE":"⋹","isins":"⋴","isinsv":"⋳","isinv":"∈","it":"⁢","Itilde":"Ĩ","itilde":"ĩ","Iukcy":"І","iukcy":"і","Iuml":"Ï","iuml":"ï","Jcirc":"Ĵ","jcirc":"ĵ","Jcy":"Й","jcy":"й","Jfr":"𝔍","jfr":"𝔧","jmath":"ȷ","Jopf":"𝕁","jopf":"𝕛","Jscr":"𝒥","jscr":"𝒿","Jsercy":"Ј","jsercy":"ј","Jukcy":"Є","jukcy":"є","Kappa":"Κ","kappa":"κ","kappav":"ϰ","Kcedil":"Ķ","kcedil":"ķ","Kcy":"К","kcy":"к","Kfr":"𝔎","kfr":"𝔨","kgreen":"ĸ","KHcy":"Х","khcy":"х","KJcy":"Ќ","kjcy":"ќ","Kopf":"𝕂","kopf":"𝕜","Kscr":"𝒦","kscr":"𝓀","lAarr":"⇚","Lacute":"Ĺ","lacute":"ĺ","laemptyv":"⦴","lagran":"ℒ","Lambda":"Λ","lambda":"λ","lang":"⟨","Lang":"⟪","langd":"⦑","langle":"⟨","lap":"⪅","Laplacetrf":"ℒ","laquo":"«","larrb":"⇤","larrbfs":"⤟","larr":"←","Larr":"↞","lArr":"⇐","larrfs":"⤝","larrhk":"↩","larrlp":"↫","larrpl":"⤹","larrsim":"⥳","larrtl":"↢","latail":"⤙","lAtail":"⤛","lat":"⪫","late":"⪭","lates":"⪭︀","lbarr":"⤌","lBarr":"⤎","lbbrk":"❲","lbrace":"{","lbrack":"[","lbrke":"⦋","lbrksld":"⦏","lbrkslu":"⦍","Lcaron":"Ľ","lcaron":"ľ","Lcedil":"Ļ","lcedil":"ļ","lceil":"⌈","lcub":"{","Lcy":"Л","lcy":"л","ldca":"⤶","ldquo":"“","ldquor":"„","ldrdhar":"⥧","ldrushar":"⥋","ldsh":"↲","le":"≤","lE":"≦","LeftAngleBracket":"⟨","LeftArrowBar":"⇤","leftarrow":"←","LeftArrow":"←","Leftarrow":"⇐","LeftArrowRightArrow":"⇆","leftarrowtail":"↢","LeftCeiling":"⌈","LeftDoubleBracket":"⟦","LeftDownTeeVector":"⥡","LeftDownVectorBar":"⥙","LeftDownVector":"⇃","LeftFloor":"⌊","leftharpoondown":"↽","leftharpoonup":"↼","leftleftarrows":"⇇","leftrightarrow":"↔","LeftRightArrow":"↔","Leftrightarrow":"⇔","leftrightarrows":"⇆","leftrightharpoons":"⇋","leftrightsquigarrow":"↭","LeftRightVector":"⥎","LeftTeeArrow":"↤","LeftTee":"⊣","LeftTeeVector":"⥚","leftthreetimes":"⋋","LeftTriangleBar":"⧏","LeftTriangle":"⊲","LeftTriangleEqual":"⊴","LeftUpDownVector":"⥑","LeftUpTeeVector":"⥠","LeftUpVectorBar":"⥘","LeftUpVector":"↿","LeftVectorBar":"⥒","LeftVector":"↼","lEg":"⪋","leg":"⋚","leq":"≤","leqq":"≦","leqslant":"⩽","lescc":"⪨","les":"⩽","lesdot":"⩿","lesdoto":"⪁","lesdotor":"⪃","lesg":"⋚︀","lesges":"⪓","lessapprox":"⪅","lessdot":"⋖","lesseqgtr":"⋚","lesseqqgtr":"⪋","LessEqualGreater":"⋚","LessFullEqual":"≦","LessGreater":"≶","lessgtr":"≶","LessLess":"⪡","lesssim":"≲","LessSlantEqual":"⩽","LessTilde":"≲","lfisht":"⥼","lfloor":"⌊","Lfr":"𝔏","lfr":"𝔩","lg":"≶","lgE":"⪑","lHar":"⥢","lhard":"↽","lharu":"↼","lharul":"⥪","lhblk":"▄","LJcy":"Љ","ljcy":"љ","llarr":"⇇","ll":"≪","Ll":"⋘","llcorner":"⌞","Lleftarrow":"⇚","llhard":"⥫","lltri":"◺","Lmidot":"Ŀ","lmidot":"ŀ","lmoustache":"⎰","lmoust":"⎰","lnap":"⪉","lnapprox":"⪉","lne":"⪇","lnE":"≨","lneq":"⪇","lneqq":"≨","lnsim":"⋦","loang":"⟬","loarr":"⇽","lobrk":"⟦","longleftarrow":"⟵","LongLeftArrow":"⟵","Longleftarrow":"⟸","longleftrightarrow":"⟷","LongLeftRightArrow":"⟷","Longleftrightarrow":"⟺","longmapsto":"⟼","longrightarrow":"⟶","LongRightArrow":"⟶","Longrightarrow":"⟹","looparrowleft":"↫","looparrowright":"↬","lopar":"⦅","Lopf":"𝕃","lopf":"𝕝","loplus":"⨭","lotimes":"⨴","lowast":"∗","lowbar":"_","LowerLeftArrow":"↙","LowerRightArrow":"↘","loz":"◊","lozenge":"◊","lozf":"⧫","lpar":"(","lparlt":"⦓","lrarr":"⇆","lrcorner":"⌟","lrhar":"⇋","lrhard":"⥭","lrm":"‎","lrtri":"⊿","lsaquo":"‹","lscr":"𝓁","Lscr":"ℒ","lsh":"↰","Lsh":"↰","lsim":"≲","lsime":"⪍","lsimg":"⪏","lsqb":"[","lsquo":"‘","lsquor":"‚","Lstrok":"Ł","lstrok":"ł","ltcc":"⪦","ltcir":"⩹","lt":"<","LT":"<","Lt":"≪","ltdot":"⋖","lthree":"⋋","ltimes":"⋉","ltlarr":"⥶","ltquest":"⩻","ltri":"◃","ltrie":"⊴","ltrif":"◂","ltrPar":"⦖","lurdshar":"⥊","luruhar":"⥦","lvertneqq":"≨︀","lvnE":"≨︀","macr":"¯","male":"♂","malt":"✠","maltese":"✠","Map":"⤅","map":"↦","mapsto":"↦","mapstodown":"↧","mapstoleft":"↤","mapstoup":"↥","marker":"▮","mcomma":"⨩","Mcy":"М","mcy":"м","mdash":"—","mDDot":"∺","measuredangle":"∡","MediumSpace":" ","Mellintrf":"ℳ","Mfr":"𝔐","mfr":"𝔪","mho":"℧","micro":"µ","midast":"*","midcir":"⫰","mid":"∣","middot":"·","minusb":"⊟","minus":"−","minusd":"∸","minusdu":"⨪","MinusPlus":"∓","mlcp":"⫛","mldr":"…","mnplus":"∓","models":"⊧","Mopf":"𝕄","mopf":"𝕞","mp":"∓","mscr":"𝓂","Mscr":"ℳ","mstpos":"∾","Mu":"Μ","mu":"μ","multimap":"⊸","mumap":"⊸","nabla":"∇","Nacute":"Ń","nacute":"ń","nang":"∠⃒","nap":"≉","napE":"⩰̸","napid":"≋̸","napos":"ʼn","napprox":"≉","natural":"♮","naturals":"ℕ","natur":"♮","nbsp":" ","nbump":"≎̸","nbumpe":"≏̸","ncap":"⩃","Ncaron":"Ň","ncaron":"ň","Ncedil":"Ņ","ncedil":"ņ","ncong":"≇","ncongdot":"⩭̸","ncup":"⩂","Ncy":"Н","ncy":"н","ndash":"–","nearhk":"⤤","nearr":"↗","neArr":"⇗","nearrow":"↗","ne":"≠","nedot":"≐̸","NegativeMediumSpace":"​","NegativeThickSpace":"​","NegativeThinSpace":"​","NegativeVeryThinSpace":"​","nequiv":"≢","nesear":"⤨","nesim":"≂̸","NestedGreaterGreater":"≫","NestedLessLess":"≪","NewLine":"\n","nexist":"∄","nexists":"∄","Nfr":"𝔑","nfr":"𝔫","ngE":"≧̸","nge":"≱","ngeq":"≱","ngeqq":"≧̸","ngeqslant":"⩾̸","nges":"⩾̸","nGg":"⋙̸","ngsim":"≵","nGt":"≫⃒","ngt":"≯","ngtr":"≯","nGtv":"≫̸","nharr":"↮","nhArr":"⇎","nhpar":"⫲","ni":"∋","nis":"⋼","nisd":"⋺","niv":"∋","NJcy":"Њ","njcy":"њ","nlarr":"↚","nlArr":"⇍","nldr":"‥","nlE":"≦̸","nle":"≰","nleftarrow":"↚","nLeftarrow":"⇍","nleftrightarrow":"↮","nLeftrightarrow":"⇎","nleq":"≰","nleqq":"≦̸","nleqslant":"⩽̸","nles":"⩽̸","nless":"≮","nLl":"⋘̸","nlsim":"≴","nLt":"≪⃒","nlt":"≮","nltri":"⋪","nltrie":"⋬","nLtv":"≪̸","nmid":"∤","NoBreak":"⁠","NonBreakingSpace":" ","nopf":"𝕟","Nopf":"ℕ","Not":"⫬","not":"¬","NotCongruent":"≢","NotCupCap":"≭","NotDoubleVerticalBar":"∦","NotElement":"∉","NotEqual":"≠","NotEqualTilde":"≂̸","NotExists":"∄","NotGreater":"≯","NotGreaterEqual":"≱","NotGreaterFullEqual":"≧̸","NotGreaterGreater":"≫̸","NotGreaterLess":"≹","NotGreaterSlantEqual":"⩾̸","NotGreaterTilde":"≵","NotHumpDownHump":"≎̸","NotHumpEqual":"≏̸","notin":"∉","notindot":"⋵̸","notinE":"⋹̸","notinva":"∉","notinvb":"⋷","notinvc":"⋶","NotLeftTriangleBar":"⧏̸","NotLeftTriangle":"⋪","NotLeftTriangleEqual":"⋬","NotLess":"≮","NotLessEqual":"≰","NotLessGreater":"≸","NotLessLess":"≪̸","NotLessSlantEqual":"⩽̸","NotLessTilde":"≴","NotNestedGreaterGreater":"⪢̸","NotNestedLessLess":"⪡̸","notni":"∌","notniva":"∌","notnivb":"⋾","notnivc":"⋽","NotPrecedes":"⊀","NotPrecedesEqual":"⪯̸","NotPrecedesSlantEqual":"⋠","NotReverseElement":"∌","NotRightTriangleBar":"⧐̸","NotRightTriangle":"⋫","NotRightTriangleEqual":"⋭","NotSquareSubset":"⊏̸","NotSquareSubsetEqual":"⋢","NotSquareSuperset":"⊐̸","NotSquareSupersetEqual":"⋣","NotSubset":"⊂⃒","NotSubsetEqual":"⊈","NotSucceeds":"⊁","NotSucceedsEqual":"⪰̸","NotSucceedsSlantEqual":"⋡","NotSucceedsTilde":"≿̸","NotSuperset":"⊃⃒","NotSupersetEqual":"⊉","NotTilde":"≁","NotTildeEqual":"≄","NotTildeFullEqual":"≇","NotTildeTilde":"≉","NotVerticalBar":"∤","nparallel":"∦","npar":"∦","nparsl":"⫽⃥","npart":"∂̸","npolint":"⨔","npr":"⊀","nprcue":"⋠","nprec":"⊀","npreceq":"⪯̸","npre":"⪯̸","nrarrc":"⤳̸","nrarr":"↛","nrArr":"⇏","nrarrw":"↝̸","nrightarrow":"↛","nRightarrow":"⇏","nrtri":"⋫","nrtrie":"⋭","nsc":"⊁","nsccue":"⋡","nsce":"⪰̸","Nscr":"𝒩","nscr":"𝓃","nshortmid":"∤","nshortparallel":"∦","nsim":"≁","nsime":"≄","nsimeq":"≄","nsmid":"∤","nspar":"∦","nsqsube":"⋢","nsqsupe":"⋣","nsub":"⊄","nsubE":"⫅̸","nsube":"⊈","nsubset":"⊂⃒","nsubseteq":"⊈","nsubseteqq":"⫅̸","nsucc":"⊁","nsucceq":"⪰̸","nsup":"⊅","nsupE":"⫆̸","nsupe":"⊉","nsupset":"⊃⃒","nsupseteq":"⊉","nsupseteqq":"⫆̸","ntgl":"≹","Ntilde":"Ñ","ntilde":"ñ","ntlg":"≸","ntriangleleft":"⋪","ntrianglelefteq":"⋬","ntriangleright":"⋫","ntrianglerighteq":"⋭","Nu":"Ν","nu":"ν","num":"#","numero":"№","numsp":" ","nvap":"≍⃒","nvdash":"⊬","nvDash":"⊭","nVdash":"⊮","nVDash":"⊯","nvge":"≥⃒","nvgt":">⃒","nvHarr":"⤄","nvinfin":"⧞","nvlArr":"⤂","nvle":"≤⃒","nvlt":"<⃒","nvltrie":"⊴⃒","nvrArr":"⤃","nvrtrie":"⊵⃒","nvsim":"∼⃒","nwarhk":"⤣","nwarr":"↖","nwArr":"⇖","nwarrow":"↖","nwnear":"⤧","Oacute":"Ó","oacute":"ó","oast":"⊛","Ocirc":"Ô","ocirc":"ô","ocir":"⊚","Ocy":"О","ocy":"о","odash":"⊝","Odblac":"Ő","odblac":"ő","odiv":"⨸","odot":"⊙","odsold":"⦼","OElig":"Œ","oelig":"œ","ofcir":"⦿","Ofr":"𝔒","ofr":"𝔬","ogon":"˛","Ograve":"Ò","ograve":"ò","ogt":"⧁","ohbar":"⦵","ohm":"Ω","oint":"∮","olarr":"↺","olcir":"⦾","olcross":"⦻","oline":"‾","olt":"⧀","Omacr":"Ō","omacr":"ō","Omega":"Ω","omega":"ω","Omicron":"Ο","omicron":"ο","omid":"⦶","ominus":"⊖","Oopf":"𝕆","oopf":"𝕠","opar":"⦷","OpenCurlyDoubleQuote":"“","OpenCurlyQuote":"‘","operp":"⦹","oplus":"⊕","orarr":"↻","Or":"⩔","or":"∨","ord":"⩝","order":"ℴ","orderof":"ℴ","ordf":"ª","ordm":"º","origof":"⊶","oror":"⩖","orslope":"⩗","orv":"⩛","oS":"Ⓢ","Oscr":"𝒪","oscr":"ℴ","Oslash":"Ø","oslash":"ø","osol":"⊘","Otilde":"Õ","otilde":"õ","otimesas":"⨶","Otimes":"⨷","otimes":"⊗","Ouml":"Ö","ouml":"ö","ovbar":"⌽","OverBar":"‾","OverBrace":"⏞","OverBracket":"⎴","OverParenthesis":"⏜","para":"¶","parallel":"∥","par":"∥","parsim":"⫳","parsl":"⫽","part":"∂","PartialD":"∂","Pcy":"П","pcy":"п","percnt":"%","period":".","permil":"‰","perp":"⊥","pertenk":"‱","Pfr":"𝔓","pfr":"𝔭","Phi":"Φ","phi":"φ","phiv":"ϕ","phmmat":"ℳ","phone":"☎","Pi":"Π","pi":"π","pitchfork":"⋔","piv":"ϖ","planck":"ℏ","planckh":"ℎ","plankv":"ℏ","plusacir":"⨣","plusb":"⊞","pluscir":"⨢","plus":"+","plusdo":"∔","plusdu":"⨥","pluse":"⩲","PlusMinus":"±","plusmn":"±","plussim":"⨦","plustwo":"⨧","pm":"±","Poincareplane":"ℌ","pointint":"⨕","popf":"𝕡","Popf":"ℙ","pound":"£","prap":"⪷","Pr":"⪻","pr":"≺","prcue":"≼","precapprox":"⪷","prec":"≺","preccurlyeq":"≼","Precedes":"≺","PrecedesEqual":"⪯","PrecedesSlantEqual":"≼","PrecedesTilde":"≾","preceq":"⪯","precnapprox":"⪹","precneqq":"⪵","precnsim":"⋨","pre":"⪯","prE":"⪳","precsim":"≾","prime":"′","Prime":"″","primes":"ℙ","prnap":"⪹","prnE":"⪵","prnsim":"⋨","prod":"∏","Product":"∏","profalar":"⌮","profline":"⌒","profsurf":"⌓","prop":"∝","Proportional":"∝","Proportion":"∷","propto":"∝","prsim":"≾","prurel":"⊰","Pscr":"𝒫","pscr":"𝓅","Psi":"Ψ","psi":"ψ","puncsp":" ","Qfr":"𝔔","qfr":"𝔮","qint":"⨌","qopf":"𝕢","Qopf":"ℚ","qprime":"⁗","Qscr":"𝒬","qscr":"𝓆","quaternions":"ℍ","quatint":"⨖","quest":"?","questeq":"≟","quot":"\"","QUOT":"\"","rAarr":"⇛","race":"∽̱","Racute":"Ŕ","racute":"ŕ","radic":"√","raemptyv":"⦳","rang":"⟩","Rang":"⟫","rangd":"⦒","range":"⦥","rangle":"⟩","raquo":"»","rarrap":"⥵","rarrb":"⇥","rarrbfs":"⤠","rarrc":"⤳","rarr":"→","Rarr":"↠","rArr":"⇒","rarrfs":"⤞","rarrhk":"↪","rarrlp":"↬","rarrpl":"⥅","rarrsim":"⥴","Rarrtl":"⤖","rarrtl":"↣","rarrw":"↝","ratail":"⤚","rAtail":"⤜","ratio":"∶","rationals":"ℚ","rbarr":"⤍","rBarr":"⤏","RBarr":"⤐","rbbrk":"❳","rbrace":"}","rbrack":"]","rbrke":"⦌","rbrksld":"⦎","rbrkslu":"⦐","Rcaron":"Ř","rcaron":"ř","Rcedil":"Ŗ","rcedil":"ŗ","rceil":"⌉","rcub":"}","Rcy":"Р","rcy":"р","rdca":"⤷","rdldhar":"⥩","rdquo":"”","rdquor":"”","rdsh":"↳","real":"ℜ","realine":"ℛ","realpart":"ℜ","reals":"ℝ","Re":"ℜ","rect":"▭","reg":"®","REG":"®","ReverseElement":"∋","ReverseEquilibrium":"⇋","ReverseUpEquilibrium":"⥯","rfisht":"⥽","rfloor":"⌋","rfr":"𝔯","Rfr":"ℜ","rHar":"⥤","rhard":"⇁","rharu":"⇀","rharul":"⥬","Rho":"Ρ","rho":"ρ","rhov":"ϱ","RightAngleBracket":"⟩","RightArrowBar":"⇥","rightarrow":"→","RightArrow":"→","Rightarrow":"⇒","RightArrowLeftArrow":"⇄","rightarrowtail":"↣","RightCeiling":"⌉","RightDoubleBracket":"⟧","RightDownTeeVector":"⥝","RightDownVectorBar":"⥕","RightDownVector":"⇂","RightFloor":"⌋","rightharpoondown":"⇁","rightharpoonup":"⇀","rightleftarrows":"⇄","rightleftharpoons":"⇌","rightrightarrows":"⇉","rightsquigarrow":"↝","RightTeeArrow":"↦","RightTee":"⊢","RightTeeVector":"⥛","rightthreetimes":"⋌","RightTriangleBar":"⧐","RightTriangle":"⊳","RightTriangleEqual":"⊵","RightUpDownVector":"⥏","RightUpTeeVector":"⥜","RightUpVectorBar":"⥔","RightUpVector":"↾","RightVectorBar":"⥓","RightVector":"⇀","ring":"˚","risingdotseq":"≓","rlarr":"⇄","rlhar":"⇌","rlm":"‏","rmoustache":"⎱","rmoust":"⎱","rnmid":"⫮","roang":"⟭","roarr":"⇾","robrk":"⟧","ropar":"⦆","ropf":"𝕣","Ropf":"ℝ","roplus":"⨮","rotimes":"⨵","RoundImplies":"⥰","rpar":")","rpargt":"⦔","rppolint":"⨒","rrarr":"⇉","Rrightarrow":"⇛","rsaquo":"›","rscr":"𝓇","Rscr":"ℛ","rsh":"↱","Rsh":"↱","rsqb":"]","rsquo":"’","rsquor":"’","rthree":"⋌","rtimes":"⋊","rtri":"▹","rtrie":"⊵","rtrif":"▸","rtriltri":"⧎","RuleDelayed":"⧴","ruluhar":"⥨","rx":"℞","Sacute":"Ś","sacute":"ś","sbquo":"‚","scap":"⪸","Scaron":"Š","scaron":"š","Sc":"⪼","sc":"≻","sccue":"≽","sce":"⪰","scE":"⪴","Scedil":"Ş","scedil":"ş","Scirc":"Ŝ","scirc":"ŝ","scnap":"⪺","scnE":"⪶","scnsim":"⋩","scpolint":"⨓","scsim":"≿","Scy":"С","scy":"с","sdotb":"⊡","sdot":"⋅","sdote":"⩦","searhk":"⤥","searr":"↘","seArr":"⇘","searrow":"↘","sect":"§","semi":";","seswar":"⤩","setminus":"∖","setmn":"∖","sext":"✶","Sfr":"𝔖","sfr":"𝔰","sfrown":"⌢","sharp":"♯","SHCHcy":"Щ","shchcy":"щ","SHcy":"Ш","shcy":"ш","ShortDownArrow":"↓","ShortLeftArrow":"←","shortmid":"∣","shortparallel":"∥","ShortRightArrow":"→","ShortUpArrow":"↑","shy":"­","Sigma":"Σ","sigma":"σ","sigmaf":"ς","sigmav":"ς","sim":"∼","simdot":"⩪","sime":"≃","simeq":"≃","simg":"⪞","simgE":"⪠","siml":"⪝","simlE":"⪟","simne":"≆","simplus":"⨤","simrarr":"⥲","slarr":"←","SmallCircle":"∘","smallsetminus":"∖","smashp":"⨳","smeparsl":"⧤","smid":"∣","smile":"⌣","smt":"⪪","smte":"⪬","smtes":"⪬︀","SOFTcy":"Ь","softcy":"ь","solbar":"⌿","solb":"⧄","sol":"/","Sopf":"𝕊","sopf":"𝕤","spades":"♠","spadesuit":"♠","spar":"∥","sqcap":"⊓","sqcaps":"⊓︀","sqcup":"⊔","sqcups":"⊔︀","Sqrt":"√","sqsub":"⊏","sqsube":"⊑","sqsubset":"⊏","sqsubseteq":"⊑","sqsup":"⊐","sqsupe":"⊒","sqsupset":"⊐","sqsupseteq":"⊒","square":"□","Square":"□","SquareIntersection":"⊓","SquareSubset":"⊏","SquareSubsetEqual":"⊑","SquareSuperset":"⊐","SquareSupersetEqual":"⊒","SquareUnion":"⊔","squarf":"▪","squ":"□","squf":"▪","srarr":"→","Sscr":"𝒮","sscr":"𝓈","ssetmn":"∖","ssmile":"⌣","sstarf":"⋆","Star":"⋆","star":"☆","starf":"★","straightepsilon":"ϵ","straightphi":"ϕ","strns":"¯","sub":"⊂","Sub":"⋐","subdot":"⪽","subE":"⫅","sube":"⊆","subedot":"⫃","submult":"⫁","subnE":"⫋","subne":"⊊","subplus":"⪿","subrarr":"⥹","subset":"⊂","Subset":"⋐","subseteq":"⊆","subseteqq":"⫅","SubsetEqual":"⊆","subsetneq":"⊊","subsetneqq":"⫋","subsim":"⫇","subsub":"⫕","subsup":"⫓","succapprox":"⪸","succ":"≻","succcurlyeq":"≽","Succeeds":"≻","SucceedsEqual":"⪰","SucceedsSlantEqual":"≽","SucceedsTilde":"≿","succeq":"⪰","succnapprox":"⪺","succneqq":"⪶","succnsim":"⋩","succsim":"≿","SuchThat":"∋","sum":"∑","Sum":"∑","sung":"♪","sup1":"¹","sup2":"²","sup3":"³","sup":"⊃","Sup":"⋑","supdot":"⪾","supdsub":"⫘","supE":"⫆","supe":"⊇","supedot":"⫄","Superset":"⊃","SupersetEqual":"⊇","suphsol":"⟉","suphsub":"⫗","suplarr":"⥻","supmult":"⫂","supnE":"⫌","supne":"⊋","supplus":"⫀","supset":"⊃","Supset":"⋑","supseteq":"⊇","supseteqq":"⫆","supsetneq":"⊋","supsetneqq":"⫌","supsim":"⫈","supsub":"⫔","supsup":"⫖","swarhk":"⤦","swarr":"↙","swArr":"⇙","swarrow":"↙","swnwar":"⤪","szlig":"ß","Tab":"\t","target":"⌖","Tau":"Τ","tau":"τ","tbrk":"⎴","Tcaron":"Ť","tcaron":"ť","Tcedil":"Ţ","tcedil":"ţ","Tcy":"Т","tcy":"т","tdot":"⃛","telrec":"⌕","Tfr":"𝔗","tfr":"𝔱","there4":"∴","therefore":"∴","Therefore":"∴","Theta":"Θ","theta":"θ","thetasym":"ϑ","thetav":"ϑ","thickapprox":"≈","thicksim":"∼","ThickSpace":"  ","ThinSpace":" ","thinsp":" ","thkap":"≈","thksim":"∼","THORN":"Þ","thorn":"þ","tilde":"˜","Tilde":"∼","TildeEqual":"≃","TildeFullEqual":"≅","TildeTilde":"≈","timesbar":"⨱","timesb":"⊠","times":"×","timesd":"⨰","tint":"∭","toea":"⤨","topbot":"⌶","topcir":"⫱","top":"⊤","Topf":"𝕋","topf":"𝕥","topfork":"⫚","tosa":"⤩","tprime":"‴","trade":"™","TRADE":"™","triangle":"▵","triangledown":"▿","triangleleft":"◃","trianglelefteq":"⊴","triangleq":"≜","triangleright":"▹","trianglerighteq":"⊵","tridot":"◬","trie":"≜","triminus":"⨺","TripleDot":"⃛","triplus":"⨹","trisb":"⧍","tritime":"⨻","trpezium":"⏢","Tscr":"𝒯","tscr":"𝓉","TScy":"Ц","tscy":"ц","TSHcy":"Ћ","tshcy":"ћ","Tstrok":"Ŧ","tstrok":"ŧ","twixt":"≬","twoheadleftarrow":"↞","twoheadrightarrow":"↠","Uacute":"Ú","uacute":"ú","uarr":"↑","Uarr":"↟","uArr":"⇑","Uarrocir":"⥉","Ubrcy":"Ў","ubrcy":"ў","Ubreve":"Ŭ","ubreve":"ŭ","Ucirc":"Û","ucirc":"û","Ucy":"У","ucy":"у","udarr":"⇅","Udblac":"Ű","udblac":"ű","udhar":"⥮","ufisht":"⥾","Ufr":"𝔘","ufr":"𝔲","Ugrave":"Ù","ugrave":"ù","uHar":"⥣","uharl":"↿","uharr":"↾","uhblk":"▀","ulcorn":"⌜","ulcorner":"⌜","ulcrop":"⌏","ultri":"◸","Umacr":"Ū","umacr":"ū","uml":"¨","UnderBar":"_","UnderBrace":"⏟","UnderBracket":"⎵","UnderParenthesis":"⏝","Union":"⋃","UnionPlus":"⊎","Uogon":"Ų","uogon":"ų","Uopf":"𝕌","uopf":"𝕦","UpArrowBar":"⤒","uparrow":"↑","UpArrow":"↑","Uparrow":"⇑","UpArrowDownArrow":"⇅","updownarrow":"↕","UpDownArrow":"↕","Updownarrow":"⇕","UpEquilibrium":"⥮","upharpoonleft":"↿","upharpoonright":"↾","uplus":"⊎","UpperLeftArrow":"↖","UpperRightArrow":"↗","upsi":"υ","Upsi":"ϒ","upsih":"ϒ","Upsilon":"Υ","upsilon":"υ","UpTeeArrow":"↥","UpTee":"⊥","upuparrows":"⇈","urcorn":"⌝","urcorner":"⌝","urcrop":"⌎","Uring":"Ů","uring":"ů","urtri":"◹","Uscr":"𝒰","uscr":"𝓊","utdot":"⋰","Utilde":"Ũ","utilde":"ũ","utri":"▵","utrif":"▴","uuarr":"⇈","Uuml":"Ü","uuml":"ü","uwangle":"⦧","vangrt":"⦜","varepsilon":"ϵ","varkappa":"ϰ","varnothing":"∅","varphi":"ϕ","varpi":"ϖ","varpropto":"∝","varr":"↕","vArr":"⇕","varrho":"ϱ","varsigma":"ς","varsubsetneq":"⊊︀","varsubsetneqq":"⫋︀","varsupsetneq":"⊋︀","varsupsetneqq":"⫌︀","vartheta":"ϑ","vartriangleleft":"⊲","vartriangleright":"⊳","vBar":"⫨","Vbar":"⫫","vBarv":"⫩","Vcy":"В","vcy":"в","vdash":"⊢","vDash":"⊨","Vdash":"⊩","VDash":"⊫","Vdashl":"⫦","veebar":"⊻","vee":"∨","Vee":"⋁","veeeq":"≚","vellip":"⋮","verbar":"|","Verbar":"‖","vert":"|","Vert":"‖","VerticalBar":"∣","VerticalLine":"|","VerticalSeparator":"❘","VerticalTilde":"≀","VeryThinSpace":" ","Vfr":"𝔙","vfr":"𝔳","vltri":"⊲","vnsub":"⊂⃒","vnsup":"⊃⃒","Vopf":"𝕍","vopf":"𝕧","vprop":"∝","vrtri":"⊳","Vscr":"𝒱","vscr":"𝓋","vsubnE":"⫋︀","vsubne":"⊊︀","vsupnE":"⫌︀","vsupne":"⊋︀","Vvdash":"⊪","vzigzag":"⦚","Wcirc":"Ŵ","wcirc":"ŵ","wedbar":"⩟","wedge":"∧","Wedge":"⋀","wedgeq":"≙","weierp":"℘","Wfr":"𝔚","wfr":"𝔴","Wopf":"𝕎","wopf":"𝕨","wp":"℘","wr":"≀","wreath":"≀","Wscr":"𝒲","wscr":"𝓌","xcap":"⋂","xcirc":"◯","xcup":"⋃","xdtri":"▽","Xfr":"𝔛","xfr":"𝔵","xharr":"⟷","xhArr":"⟺","Xi":"Ξ","xi":"ξ","xlarr":"⟵","xlArr":"⟸","xmap":"⟼","xnis":"⋻","xodot":"⨀","Xopf":"𝕏","xopf":"𝕩","xoplus":"⨁","xotime":"⨂","xrarr":"⟶","xrArr":"⟹","Xscr":"𝒳","xscr":"𝓍","xsqcup":"⨆","xuplus":"⨄","xutri":"△","xvee":"⋁","xwedge":"⋀","Yacute":"Ý","yacute":"ý","YAcy":"Я","yacy":"я","Ycirc":"Ŷ","ycirc":"ŷ","Ycy":"Ы","ycy":"ы","yen":"¥","Yfr":"𝔜","yfr":"𝔶","YIcy":"Ї","yicy":"ї","Yopf":"𝕐","yopf":"𝕪","Yscr":"𝒴","yscr":"𝓎","YUcy":"Ю","yucy":"ю","yuml":"ÿ","Yuml":"Ÿ","Zacute":"Ź","zacute":"ź","Zcaron":"Ž","zcaron":"ž","Zcy":"З","zcy":"з","Zdot":"Ż","zdot":"ż","zeetrf":"ℨ","ZeroWidthSpace":"​","Zeta":"Ζ","zeta":"ζ","zfr":"𝔷","Zfr":"ℨ","ZHcy":"Ж","zhcy":"ж","zigrarr":"⇝","zopf":"𝕫","Zopf":"ℤ","Zscr":"𝒵","zscr":"𝓏","zwj":"‍","zwnj":"‌"}
43302
 
43303
  /***/ },
43304
+ /* 459 */
43305
  /***/ function(module, exports) {
43306
 
43307
  module.exports = {"Aacute":"Á","aacute":"á","Acirc":"Â","acirc":"â","acute":"´","AElig":"Æ","aelig":"æ","Agrave":"À","agrave":"à","amp":"&","AMP":"&","Aring":"Å","aring":"å","Atilde":"Ã","atilde":"ã","Auml":"Ä","auml":"ä","brvbar":"¦","Ccedil":"Ç","ccedil":"ç","cedil":"¸","cent":"¢","copy":"©","COPY":"©","curren":"¤","deg":"°","divide":"÷","Eacute":"É","eacute":"é","Ecirc":"Ê","ecirc":"ê","Egrave":"È","egrave":"è","ETH":"Ð","eth":"ð","Euml":"Ë","euml":"ë","frac12":"½","frac14":"¼","frac34":"¾","gt":">","GT":">","Iacute":"Í","iacute":"í","Icirc":"Î","icirc":"î","iexcl":"¡","Igrave":"Ì","igrave":"ì","iquest":"¿","Iuml":"Ï","iuml":"ï","laquo":"«","lt":"<","LT":"<","macr":"¯","micro":"µ","middot":"·","nbsp":" ","not":"¬","Ntilde":"Ñ","ntilde":"ñ","Oacute":"Ó","oacute":"ó","Ocirc":"Ô","ocirc":"ô","Ograve":"Ò","ograve":"ò","ordf":"ª","ordm":"º","Oslash":"Ø","oslash":"ø","Otilde":"Õ","otilde":"õ","Ouml":"Ö","ouml":"ö","para":"¶","plusmn":"±","pound":"£","quot":"\"","QUOT":"\"","raquo":"»","reg":"®","REG":"®","sect":"§","shy":"­","sup1":"¹","sup2":"²","sup3":"³","szlig":"ß","THORN":"Þ","thorn":"þ","times":"×","Uacute":"Ú","uacute":"ú","Ucirc":"Û","ucirc":"û","Ugrave":"Ù","ugrave":"ù","uml":"¨","Uuml":"Ü","uuml":"ü","Yacute":"Ý","yacute":"ý","yen":"¥","yuml":"ÿ"}
43308
 
43309
  /***/ },
43310
+ /* 460 */
43311
  /***/ function(module, exports) {
43312
 
43313
  module.exports = {"amp":"&","apos":"'","gt":">","lt":"<","quot":"\""}
43314
 
43315
  /***/ },
43316
+ /* 461 */
43317
  /***/ function(module, exports) {
43318
 
43319
  if (typeof Object.create === 'function') {
43342
 
43343
 
43344
  /***/ },
43345
+ /* 462 */
43346
  /***/ function(module, exports) {
43347
 
43348
  // Copyright Joyent, Inc. and other Node contributors.
43650
 
43651
 
43652
  /***/ },
43653
+ /* 463 */
43654
  /***/ function(module, exports, __webpack_require__) {
43655
 
43656
+ var ElementType = __webpack_require__(464);
43657
 
43658
  var re_whitespace = /\s+/g;
43659
+ var NodePrototype = __webpack_require__(465);
43660
+ var ElementPrototype = __webpack_require__(466);
43661
 
43662
  function DomHandler(callback, options, elementCB){
43663
  if(typeof callback === "object"){
43873
 
43874
 
43875
  /***/ },
43876
+ /* 464 */
43877
  /***/ function(module, exports) {
43878
 
43879
  //Types of elements found in the DOM
43894
 
43895
 
43896
  /***/ },
43897
+ /* 465 */
43898
  /***/ function(module, exports) {
43899
 
43900
  // This object will be used as the prototype for Nodes when creating a
43944
 
43945
 
43946
  /***/ },
43947
+ /* 466 */
43948
  /***/ function(module, exports, __webpack_require__) {
43949
 
43950
  // DOM-Level-1-compliant structure
43951
+ var NodePrototype = __webpack_require__(465);
43952
  var ElementPrototype = module.exports = Object.create(NodePrototype);
43953
 
43954
  var domLvl1 = {
43970
 
43971
 
43972
  /***/ },
43973
+ /* 467 */
43974
  /***/ function(module, exports, __webpack_require__) {
43975
 
43976
+ var index = __webpack_require__(453),
43977
  DomHandler = index.DomHandler,
43978
  DomUtils = index.DomUtils;
43979
 
43982
  this.init(callback, options);
43983
  }
43984
 
43985
+ __webpack_require__(461)(FeedHandler, DomHandler);
43986
 
43987
  FeedHandler.prototype.init = DomHandler;
43988
 
44071
 
44072
 
44073
  /***/ },
44074
+ /* 468 */
44075
  /***/ function(module, exports, __webpack_require__) {
44076
 
44077
  module.exports = Stream;
44078
 
44079
+ var Parser = __webpack_require__(469);
44080
 
44081
  function Stream(options){
44082
  Parser.call(this, new Cbs(this), options);
44083
  }
44084
 
44085
+ __webpack_require__(461)(Stream, Parser);
44086
 
44087
  Stream.prototype.readable = true;
44088
 
44090
  this.scope = scope;
44091
  }
44092
 
44093
+ var EVENTS = __webpack_require__(453).EVENTS;
44094
 
44095
  Object.keys(EVENTS).forEach(function(name){
44096
  if(EVENTS[name] === 0){
44111
  });
44112
 
44113
  /***/ },
44114
+ /* 469 */
44115
  /***/ function(module, exports, __webpack_require__) {
44116
 
44117
  module.exports = Stream;
44118
 
44119
+ var Parser = __webpack_require__(454),
44120
+ WritableStream = __webpack_require__(470).Writable || __webpack_require__(489).Writable,
44121
+ StringDecoder = __webpack_require__(490).StringDecoder,
44122
+ Buffer = __webpack_require__(474).Buffer;
44123
 
44124
  function Stream(cbs, options){
44125
  var parser = this._parser = new Parser(cbs, options);
44132
  });
44133
  }
44134
 
44135
+ __webpack_require__(461)(Stream, WritableStream);
44136
 
44137
  WritableStream.prototype._write = function(chunk, encoding, cb){
44138
  if(chunk instanceof Buffer) chunk = this._decoder.write(chunk);
44141
  };
44142
 
44143
  /***/ },
44144
+ /* 470 */
44145
  /***/ function(module, exports, __webpack_require__) {
44146
 
44147
  // Copyright Joyent, Inc. and other Node contributors.
44167
 
44168
  module.exports = Stream;
44169
 
44170
+ var EE = __webpack_require__(462).EventEmitter;
44171
+ var inherits = __webpack_require__(461);
44172
 
44173
  inherits(Stream, EE);
44174
+ Stream.Readable = __webpack_require__(471);
44175
+ Stream.Writable = __webpack_require__(485);
44176
+ Stream.Duplex = __webpack_require__(486);
44177
+ Stream.Transform = __webpack_require__(487);
44178
+ Stream.PassThrough = __webpack_require__(488);
44179
 
44180
  // Backwards-compat with node 0.4.x
44181
  Stream.Stream = Stream;
44274
 
44275
 
44276
  /***/ },
44277
+ /* 471 */
44278
  /***/ function(module, exports, __webpack_require__) {
44279
 
44280
+ /* WEBPACK VAR INJECTION */(function(process) {exports = module.exports = __webpack_require__(472);
44281
+ exports.Stream = __webpack_require__(470);
44282
  exports.Readable = exports;
44283
+ exports.Writable = __webpack_require__(481);
44284
+ exports.Duplex = __webpack_require__(480);
44285
+ exports.Transform = __webpack_require__(483);
44286
+ exports.PassThrough = __webpack_require__(484);
44287
  if (!process.browser && process.env.READABLE_STREAM === 'disable') {
44288
+ module.exports = __webpack_require__(470);
44289
  }
44290
 
44291
  /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
44292
 
44293
  /***/ },
44294
+ /* 472 */
44295
  /***/ function(module, exports, __webpack_require__) {
44296
 
44297
  /* WEBPACK VAR INJECTION */(function(process) {// Copyright Joyent, Inc. and other Node contributors.
44318
  module.exports = Readable;
44319
 
44320
  /*<replacement>*/
44321
+ var isArray = __webpack_require__(473);
44322
  /*</replacement>*/
44323
 
44324
 
44325
  /*<replacement>*/
44326
+ var Buffer = __webpack_require__(474).Buffer;
44327
  /*</replacement>*/
44328
 
44329
  Readable.ReadableState = ReadableState;
44330
 
44331
+ var EE = __webpack_require__(462).EventEmitter;
44332
 
44333
  /*<replacement>*/
44334
  if (!EE.listenerCount) EE.listenerCount = function(emitter, type) {
44336
  };
44337
  /*</replacement>*/
44338
 
44339
+ var Stream = __webpack_require__(470);
44340
 
44341
  /*<replacement>*/
44342
+ var util = __webpack_require__(478);
44343
+ util.inherits = __webpack_require__(461);
44344
  /*</replacement>*/
44345
 
44346
  var StringDecoder;
44347
 
44348
 
44349
  /*<replacement>*/
44350
+ var debug = __webpack_require__(479);
44351
  if (debug && debug.debuglog) {
44352
  debug = debug.debuglog('stream');
44353
  } else {
44359
  util.inherits(Readable, Stream);
44360
 
44361
  function ReadableState(options, stream) {
44362
+ var Duplex = __webpack_require__(480);
44363
 
44364
  options = options || {};
44365
 
44420
  this.encoding = null;
44421
  if (options.encoding) {
44422
  if (!StringDecoder)
44423
+ StringDecoder = __webpack_require__(482).StringDecoder;
44424
  this.decoder = new StringDecoder(options.encoding);
44425
  this.encoding = options.encoding;
44426
  }
44427
  }
44428
 
44429
  function Readable(options) {
44430
+ var Duplex = __webpack_require__(480);
44431
 
44432
  if (!(this instanceof Readable))
44433
  return new Readable(options);
44530
  // backwards compatibility.
44531
  Readable.prototype.setEncoding = function(enc) {
44532
  if (!StringDecoder)
44533
+ StringDecoder = __webpack_require__(482).StringDecoder;
44534
  this._readableState.decoder = new StringDecoder(enc);
44535
  this._readableState.encoding = enc;
44536
  return this;
45249
  /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
45250
 
45251
  /***/ },
45252
+ /* 473 */
45253
  /***/ function(module, exports) {
45254
 
45255
  module.exports = Array.isArray || function (arr) {
45258
 
45259
 
45260
  /***/ },
45261
+ /* 474 */
45262
  /***/ function(module, exports, __webpack_require__) {
45263
 
45264
  /* WEBPACK VAR INJECTION */(function(Buffer, global) {/*!
45271
 
45272
  'use strict'
45273
 
45274
+ var base64 = __webpack_require__(475)
45275
+ var ieee754 = __webpack_require__(476)
45276
+ var isArray = __webpack_require__(477)
45277
 
45278
  exports.Buffer = Buffer
45279
  exports.SlowBuffer = SlowBuffer
47051
  return val !== val // eslint-disable-line no-self-compare
47052
  }
47053
 
47054
+ /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(474).Buffer, (function() { return this; }())))
47055
 
47056
  /***/ },
47057
+ /* 475 */
47058
  /***/ function(module, exports) {
47059
 
47060
  'use strict'
47174
 
47175
 
47176
  /***/ },
47177
+ /* 476 */
47178
  /***/ function(module, exports) {
47179
 
47180
  exports.read = function (buffer, offset, isLE, mLen, nBytes) {
47264
 
47265
 
47266
  /***/ },
47267
+ /* 477 */
47268
  /***/ function(module, exports) {
47269
 
47270
  var toString = {}.toString;
47275
 
47276
 
47277
  /***/ },
47278
+ /* 478 */
47279
  /***/ function(module, exports, __webpack_require__) {
47280
 
47281
  /* WEBPACK VAR INJECTION */(function(Buffer) {// Copyright Joyent, Inc. and other Node contributors.
47386
  return Object.prototype.toString.call(o);
47387
  }
47388
 
47389
+ /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(474).Buffer))
47390
 
47391
  /***/ },
47392
+ /* 479 */
47393
  /***/ function(module, exports) {
47394
 
47395
  /* (ignored) */
47396
 
47397
  /***/ },
47398
+ /* 480 */
47399
  /***/ function(module, exports, __webpack_require__) {
47400
 
47401
  /* WEBPACK VAR INJECTION */(function(process) {// Copyright Joyent, Inc. and other Node contributors.
47436
 
47437
 
47438
  /*<replacement>*/
47439
+ var util = __webpack_require__(478);
47440
+ util.inherits = __webpack_require__(461);
47441
  /*</replacement>*/
47442
 
47443
+ var Readable = __webpack_require__(472);
47444
+ var Writable = __webpack_require__(481);
47445
 
47446
  util.inherits(Duplex, Readable);
47447
 
47491
  /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
47492
 
47493
  /***/ },
47494
+ /* 481 */
47495
  /***/ function(module, exports, __webpack_require__) {
47496
 
47497
  /* WEBPACK VAR INJECTION */(function(process) {// Copyright Joyent, Inc. and other Node contributors.
47522
  module.exports = Writable;
47523
 
47524
  /*<replacement>*/
47525
+ var Buffer = __webpack_require__(474).Buffer;
47526
  /*</replacement>*/
47527
 
47528
  Writable.WritableState = WritableState;
47529
 
47530
 
47531
  /*<replacement>*/
47532
+ var util = __webpack_require__(478);
47533
+ util.inherits = __webpack_require__(461);
47534
  /*</replacement>*/
47535
 
47536
+ var Stream = __webpack_require__(470);
47537
 
47538
  util.inherits(Writable, Stream);
47539
 
47544
  }
47545
 
47546
  function WritableState(options, stream) {
47547
+ var Duplex = __webpack_require__(480);
47548
 
47549
  options = options || {};
47550
 
47632
  }
47633
 
47634
  function Writable(options) {
47635
+ var Duplex = __webpack_require__(480);
47636
 
47637
  // Writable ctor is applied to Duplexes, though they're not
47638
  // instanceof Writable, they're instanceof Readable.
47975
  /* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(5)))
47976
 
47977
  /***/ },
47978
+ /* 482 */
47979
  /***/ function(module, exports, __webpack_require__) {
47980
 
47981
  // Copyright Joyent, Inc. and other Node contributors.
47999
  // OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
48000
  // USE OR OTHER DEALINGS IN THE SOFTWARE.
48001
 
48002
+ var Buffer = __webpack_require__(474).Buffer;
48003
 
48004
  var isBufferEncoding = Buffer.isEncoding
48005
  || function(encoding) {
48202
 
48203
 
48204
  /***/ },
48205
+ /* 483 */
48206
  /***/ function(module, exports, __webpack_require__) {
48207
 
48208
  // Copyright Joyent, Inc. and other Node contributors.
48271
 
48272
  module.exports = Transform;
48273
 
48274
+ var Duplex = __webpack_require__(480);
48275
 
48276
  /*<replacement>*/
48277
+ var util = __webpack_require__(478);
48278
+ util.inherits = __webpack_require__(461);
48279
  /*</replacement>*/
48280
 
48281
  util.inherits(Transform, Duplex);
48417
 
48418
 
48419
  /***/ },
48420
+ /* 484 */
48421
  /***/ function(module, exports, __webpack_require__) {
48422
 
48423
  // Copyright Joyent, Inc. and other Node contributors.
48447
 
48448
  module.exports = PassThrough;
48449
 
48450
+ var Transform = __webpack_require__(483);
48451
 
48452
  /*<replacement>*/
48453
+ var util = __webpack_require__(478);
48454
+ util.inherits = __webpack_require__(461);
48455
  /*</replacement>*/
48456
 
48457
  util.inherits(PassThrough, Transform);
48468
  };
48469
 
48470
 
 
 
 
 
 
 
 
48471
  /***/ },
48472
  /* 485 */
48473
  /***/ function(module, exports, __webpack_require__) {
48474
 
48475
+ module.exports = __webpack_require__(481)
48476
 
48477
 
48478
  /***/ },
48479
  /* 486 */
48480
  /***/ function(module, exports, __webpack_require__) {
48481
 
48482
+ module.exports = __webpack_require__(480)
48483
 
48484
 
48485
  /***/ },
48491
 
48492
  /***/ },
48493
  /* 488 */
48494
+ /***/ function(module, exports, __webpack_require__) {
48495
+
48496
+ module.exports = __webpack_require__(484)
48497
+
48498
+
48499
+ /***/ },
48500
+ /* 489 */
48501
  /***/ function(module, exports) {
48502
 
48503
  /* (ignored) */
48504
 
48505
  /***/ },
48506
+ /* 490 */
48507
  /***/ function(module, exports, __webpack_require__) {
48508
 
48509
  'use strict';
48510
 
48511
+ var Buffer = __webpack_require__(491).Buffer;
48512
 
48513
  var isEncoding = Buffer.isEncoding || function (encoding) {
48514
  encoding = '' + encoding;
48780
  }
48781
 
48782
  /***/ },
48783
+ /* 491 */
48784
  /***/ function(module, exports, __webpack_require__) {
48785
 
48786
  /* eslint-disable node/no-deprecated-api */
48787
+ var buffer = __webpack_require__(474)
48788
  var Buffer = buffer.Buffer
48789
 
48790
  // alternative to using Object.keys for old browsers
48848
 
48849
 
48850
  /***/ },
48851
+ /* 492 */
48852
  /***/ function(module, exports, __webpack_require__) {
48853
 
48854
  module.exports = ProxyHandler;
48857
  this._cbs = cbs || {};
48858
  }
48859
 
48860
+ var EVENTS = __webpack_require__(453).EVENTS;
48861
  Object.keys(EVENTS).forEach(function(name){
48862
  if(EVENTS[name] === 0){
48863
  name = "on" + name;
48880
  });
48881
 
48882
  /***/ },
48883
+ /* 493 */
48884
  /***/ function(module, exports, __webpack_require__) {
48885
 
48886
  var DomUtils = module.exports;
48887
 
48888
  [
48889
+ __webpack_require__(494),
 
48890
  __webpack_require__(500),
48891
  __webpack_require__(501),
48892
  __webpack_require__(502),
48893
+ __webpack_require__(503),
48894
+ __webpack_require__(504)
48895
  ].forEach(function(ext){
48896
  Object.keys(ext).forEach(function(key){
48897
  DomUtils[key] = ext[key].bind(DomUtils);
48900
 
48901
 
48902
  /***/ },
48903
+ /* 494 */
48904
  /***/ function(module, exports, __webpack_require__) {
48905
 
48906
+ var ElementType = __webpack_require__(464),
48907
+ getOuterHTML = __webpack_require__(495),
48908
  isTag = ElementType.isTag;
48909
 
48910
  module.exports = {
48929
 
48930
 
48931
  /***/ },
48932
+ /* 495 */
48933
  /***/ function(module, exports, __webpack_require__) {
48934
 
48935
  /*
48936
  Module dependencies
48937
  */
48938
+ var ElementType = __webpack_require__(496);
48939
+ var entities = __webpack_require__(497);
48940
 
48941
  /*
48942
  Boolean Attributes
49113
 
49114
 
49115
  /***/ },
49116
+ /* 496 */
49117
  /***/ function(module, exports) {
49118
 
49119
  //Types of elements found in the DOM
49132
  };
49133
 
49134
  /***/ },
49135
+ /* 497 */
49136
  /***/ function(module, exports, __webpack_require__) {
49137
 
49138
+ var encode = __webpack_require__(498),
49139
+ decode = __webpack_require__(499);
49140
 
49141
  exports.decode = function(data, level){
49142
  return (!level || level <= 0 ? decode.XML : decode.HTML)(data);
49171
 
49172
 
49173
  /***/ },
49174
+ /* 498 */
49175
  /***/ function(module, exports, __webpack_require__) {
49176
 
49177
+ var inverseXML = getInverseObj(__webpack_require__(460)),
49178
  xmlReplacer = getInverseReplacer(inverseXML);
49179
 
49180
  exports.XML = getInverse(inverseXML, xmlReplacer);
49181
 
49182
+ var inverseHTML = getInverseObj(__webpack_require__(458)),
49183
  htmlReplacer = getInverseReplacer(inverseHTML);
49184
 
49185
  exports.HTML = getInverse(inverseHTML, htmlReplacer);
49250
 
49251
 
49252
  /***/ },
49253
+ /* 499 */
49254
  /***/ function(module, exports, __webpack_require__) {
49255
 
49256
+ var entityMap = __webpack_require__(458),
49257
+ legacyMap = __webpack_require__(459),
49258
+ xmlMap = __webpack_require__(460),
49259
+ decodeCodePoint = __webpack_require__(456);
49260
 
49261
  var decodeXMLStrict = getStrictDecoder(xmlMap),
49262
  decodeHTMLStrict = getStrictDecoder(entityMap);
49327
  };
49328
 
49329
  /***/ },
49330
+ /* 500 */
49331
  /***/ function(module, exports) {
49332
 
49333
  var getChildren = exports.getChildren = function(elem){
49357
 
49358
 
49359
  /***/ },
49360
+ /* 501 */
49361
  /***/ function(module, exports) {
49362
 
49363
  exports.removeElement = function(elem){
49440
 
49441
 
49442
  /***/ },
49443
+ /* 502 */
49444
  /***/ function(module, exports, __webpack_require__) {
49445
 
49446
+ var isTag = __webpack_require__(464).isTag;
49447
 
49448
  module.exports = {
49449
  filter: filter,
49545
 
49546
 
49547
  /***/ },
49548
+ /* 503 */
49549
  /***/ function(module, exports, __webpack_require__) {
49550
 
49551
+ var ElementType = __webpack_require__(464);
49552
  var isTag = exports.isTag = ElementType.isTag;
49553
 
49554
  exports.testElement = function(options, element){
49638
 
49639
 
49640
  /***/ },
49641
+ /* 504 */
49642
  /***/ function(module, exports) {
49643
 
49644
  // removeSubsets
49785
 
49786
 
49787
  /***/ },
49788
+ /* 505 */
49789
  /***/ function(module, exports, __webpack_require__) {
49790
 
49791
  module.exports = CollectingHandler;
49795
  this.events = [];
49796
  }
49797
 
49798
+ var EVENTS = __webpack_require__(453).EVENTS;
49799
  Object.keys(EVENTS).forEach(function(name){
49800
  if(EVENTS[name] === 0){
49801
  name = "on" + name;
49846
 
49847
 
49848
  /***/ },
49849
+ /* 506 */
49850
  /***/ function(module, exports, __webpack_require__) {
49851
 
49852
  'use strict';
49856
  });
49857
  exports.default = ProcessNodes;
49858
 
49859
+ var _elementTypes = __webpack_require__(507);
49860
 
49861
  var _elementTypes2 = _interopRequireDefault(_elementTypes);
49862
 
49899
  }
49900
 
49901
  /***/ },
49902
+ /* 507 */
49903
  /***/ function(module, exports, __webpack_require__) {
49904
 
49905
  'use strict';
49910
 
49911
  var _ElementType$Text$Ele;
49912
 
49913
+ var _htmlparser = __webpack_require__(453);
49914
 
49915
+ var _TextElementType = __webpack_require__(508);
49916
 
49917
  var _TextElementType2 = _interopRequireDefault(_TextElementType);
49918
 
49919
+ var _TagElementType = __webpack_require__(509);
49920
 
49921
  var _TagElementType2 = _interopRequireDefault(_TagElementType);
49922
 
49923
+ var _StyleElementType = __webpack_require__(517);
49924
 
49925
  var _StyleElementType2 = _interopRequireDefault(_StyleElementType);
49926
 
49927
+ var _UnsupportedElementType = __webpack_require__(518);
49928
 
49929
  var _UnsupportedElementType2 = _interopRequireDefault(_UnsupportedElementType);
49930
 
49939
  exports.default = (_ElementType$Text$Ele = {}, _defineProperty(_ElementType$Text$Ele, _htmlparser.ElementType.Text, _TextElementType2.default), _defineProperty(_ElementType$Text$Ele, _htmlparser.ElementType.Tag, _TagElementType2.default), _defineProperty(_ElementType$Text$Ele, _htmlparser.ElementType.Style, _StyleElementType2.default), _defineProperty(_ElementType$Text$Ele, _htmlparser.ElementType.Directive, _UnsupportedElementType2.default), _defineProperty(_ElementType$Text$Ele, _htmlparser.ElementType.Comment, _UnsupportedElementType2.default), _defineProperty(_ElementType$Text$Ele, _htmlparser.ElementType.Script, _UnsupportedElementType2.default), _defineProperty(_ElementType$Text$Ele, _htmlparser.ElementType.CDATA, _UnsupportedElementType2.default), _defineProperty(_ElementType$Text$Ele, _htmlparser.ElementType.Doctype, _UnsupportedElementType2.default), _ElementType$Text$Ele);
49940
 
49941
  /***/ },
49942
+ /* 508 */
49943
  /***/ function(module, exports) {
49944
 
49945
  "use strict";
49961
  }
49962
 
49963
  /***/ },
49964
+ /* 509 */
49965
  /***/ function(module, exports, __webpack_require__) {
49966
 
49967
  'use strict';
49975
 
49976
  var _react2 = _interopRequireDefault(_react);
49977
 
49978
+ var _ProcessNodes = __webpack_require__(506);
49979
 
49980
  var _ProcessNodes2 = _interopRequireDefault(_ProcessNodes);
49981
 
49982
+ var _GeneratePropsFromAttributes = __webpack_require__(510);
49983
 
49984
  var _GeneratePropsFromAttributes2 = _interopRequireDefault(_GeneratePropsFromAttributes);
49985
 
49986
+ var _TransformTagName = __webpack_require__(515);
49987
 
49988
  var _TransformTagName2 = _interopRequireDefault(_TransformTagName);
49989
 
49990
+ var _VoidElements = __webpack_require__(516);
49991
 
49992
  var _VoidElements2 = _interopRequireDefault(_VoidElements);
49993
 
50019
  }
50020
 
50021
  /***/ },
50022
+ /* 510 */
50023
  /***/ function(module, exports, __webpack_require__) {
50024
 
50025
  'use strict';
50032
 
50033
  exports.default = GeneratePropsFromAttributes;
50034
 
50035
+ var _HtmlAttributesToReact = __webpack_require__(511);
50036
 
50037
  var _HtmlAttributesToReact2 = _interopRequireDefault(_HtmlAttributesToReact);
50038
 
50039
+ var _InlineStyleToObject = __webpack_require__(514);
50040
 
50041
  var _InlineStyleToObject2 = _interopRequireDefault(_InlineStyleToObject);
50042
 
50062
  }
50063
 
50064
  /***/ },
50065
+ /* 511 */
50066
  /***/ function(module, exports, __webpack_require__) {
50067
 
50068
  'use strict';
50072
  });
50073
  exports.default = HtmlAttributesToReact;
50074
 
50075
+ var _BooleanAttributes = __webpack_require__(512);
50076
 
50077
  var _BooleanAttributes2 = _interopRequireDefault(_BooleanAttributes);
50078
 
50079
+ var _ReactAttributes = __webpack_require__(513);
50080
 
50081
  var _ReactAttributes2 = _interopRequireDefault(_ReactAttributes);
50082
 
50128
  }
50129
 
50130
  /***/ },
50131
+ /* 512 */
50132
  /***/ function(module, exports) {
50133
 
50134
  'use strict';
50147
  exports.default = ['allowfullScreen', 'async', 'autoplay', 'capture', 'checked', 'controls', 'default', 'defer', 'disabled', 'formnovalidate', 'hidden', 'loop', 'multiple', 'muted', 'novalidate', 'open', 'readonly', 'required', 'reversed', 'scoped', 'seamless', 'selected', 'itemscope'];
50148
 
50149
  /***/ },
50150
+ /* 513 */
50151
  /***/ function(module, exports) {
50152
 
50153
  'use strict';
50315
  };
50316
 
50317
  /***/ },
50318
+ /* 514 */
50319
  /***/ function(module, exports) {
50320
 
50321
  'use strict';
50378
  }
50379
 
50380
  /***/ },
50381
+ /* 515 */
50382
  /***/ function(module, exports) {
50383
 
50384
  'use strict';
50408
  }
50409
 
50410
  /***/ },
50411
+ /* 516 */
50412
  /***/ function(module, exports) {
50413
 
50414
  'use strict';
50424
  exports.default = ['area', 'base', 'br', 'col', 'command', 'embed', 'hr', 'img', 'input', 'keygen', 'link', 'meta', 'param', 'source', 'track', 'wbr'];
50425
 
50426
  /***/ },
50427
+ /* 517 */
50428
  /***/ function(module, exports, __webpack_require__) {
50429
 
50430
  'use strict';
50438
 
50439
  var _react2 = _interopRequireDefault(_react);
50440
 
50441
+ var _GeneratePropsFromAttributes = __webpack_require__(510);
50442
 
50443
  var _GeneratePropsFromAttributes2 = _interopRequireDefault(_GeneratePropsFromAttributes);
50444
 
50468
  }
50469
 
50470
  /***/ },
50471
+ /* 518 */
50472
  /***/ function(module, exports) {
50473
 
50474
  "use strict";
50489
  }
50490
 
50491
  /***/ },
 
50492
  /* 519 */,
50493
  /* 520 */,
50494
  /* 521 */,
50532
  /* 559 */,
50533
  /* 560 */,
50534
  /* 561 */,
50535
+ /* 562 */,
50536
+ /* 563 */,
50537
+ /* 564 */,
50538
+ /* 565 */
50539
  /***/ function(module, exports, __webpack_require__) {
50540
 
50541
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;function requestFailed(errorMessage, xhr) {
50628
 
50629
 
50630
  /***/ },
50631
+ /* 566 */
50632
  /***/ function(module, exports, __webpack_require__) {
50633
 
50634
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
50807
 
50808
 
50809
  /***/ },
50810
+ /* 567 */
50811
  /***/ function(module, exports, __webpack_require__) {
50812
 
50813
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
50836
 
50837
 
50838
  /***/ },
50839
+ /* 568 */
50840
  /***/ function(module, exports, __webpack_require__) {
50841
 
50842
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/* eslint-disable func-names */
51481
 
51482
 
51483
  /***/ },
51484
+ /* 569 */
51485
  /***/ function(module, exports, __webpack_require__) {
51486
 
51487
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
51704
 
51705
 
51706
  /***/ },
51707
+ /* 570 */
51708
  /***/ function(module, exports, __webpack_require__) {
51709
 
51710
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
51730
 
51731
 
51732
  /***/ },
51733
+ /* 571 */
51734
  /***/ function(module, exports, __webpack_require__) {
51735
 
51736
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [
51839
 
51840
 
51841
  /***/ },
51842
+ /* 572 */
51843
  /***/ function(module, exports, __webpack_require__) {
51844
 
51845
  /* WEBPACK VAR INJECTION */(function(global) {/*!
54338
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
54339
 
54340
  /***/ },
54341
+ /* 573 */
54342
  /***/ function(module, exports, __webpack_require__) {
54343
 
54344
  var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*
54414
 
54415
 
54416
  /***/ },
54417
+ /* 574 */
54418
  /***/ function(module, exports, __webpack_require__) {
54419
 
54420
+ var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;!(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(276), __webpack_require__(2), __webpack_require__(34), __webpack_require__(437)], __WEBPACK_AMD_DEFINE_RESULT__ = function helpTooltip(mp, React, ReactDOM, TooltipComponent) {
54421
  'use strict';
54422
 
54423
  var MailPoet = mp;
assets/js/manifest.json CHANGED
@@ -1,10 +1,10 @@
1
  {
2
  "mp2migrator.js": "mp2migrator.dc0d6e2b.js",
3
  "public.js": "public.ea9ffa3f.js",
4
- "admin.js": "admin.d5dc3994.js",
5
- "admin_vendor.js": "admin_vendor.2bc811e8.js",
6
- "form_editor.js": "form_editor.13982476.js",
7
- "mailpoet.js": "mailpoet.a55b11ee.js",
8
- "newsletter_editor.js": "newsletter_editor.1de7c9b5.js",
9
- "vendor.js": "vendor.e3b41dc0.js"
10
  }
1
  {
2
  "mp2migrator.js": "mp2migrator.dc0d6e2b.js",
3
  "public.js": "public.ea9ffa3f.js",
4
+ "admin.js": "admin.aaa81cde.js",
5
+ "admin_vendor.js": "admin_vendor.1b9d5c2b.js",
6
+ "form_editor.js": "form_editor.901a1d16.js",
7
+ "mailpoet.js": "mailpoet.5afefe4c.js",
8
+ "newsletter_editor.js": "newsletter_editor.6416262e.js",
9
+ "vendor.js": "vendor.c171af1b.js"
10
  }
assets/js/{newsletter_editor.1de7c9b5.js → newsletter_editor.6416262e.js} RENAMED
@@ -1,111 +1,96 @@
1
  webpackJsonp([4],{
2
 
3
- /***/ 588:
4
  /***/ function(module, exports, __webpack_require__) {
5
 
6
- var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/* eslint-disable func-names */
 
 
7
  !(__WEBPACK_AMD_DEFINE_ARRAY__ = [
8
- __webpack_require__(584),
9
- __webpack_require__(280),
10
- __webpack_require__(276),
11
- __webpack_require__(562)
12
- ], __WEBPACK_AMD_DEFINE_RESULT__ = function (App, _, MailPoet) {
13
  var Module = {};
14
 
15
- Module._query = function (args) {
16
- return MailPoet.Ajax.post({
17
- api_version: window.mailpoet_api_version,
18
- endpoint: 'automatedLatestContent',
19
- action: args.action,
20
- data: args.options || {}
21
- });
22
- };
23
- Module._cachedQuery = _.memoize(Module._query, JSON.stringify);
24
-
25
- Module.getNewsletter = function (options) {
26
- return Module._query({
27
- action: 'get',
28
- options: options
29
- });
30
- };
31
-
32
- Module.getPostTypes = function () {
33
- return Module._cachedQuery({
34
- action: 'getPostTypes',
35
- options: {}
36
- }).then(function (response) {
37
- return _.values(response.data);
38
- });
39
- };
40
-
41
- Module.getTaxonomies = function (postType) {
42
- return Module._cachedQuery({
43
- action: 'getTaxonomies',
44
- options: {
45
- postType: postType
46
  }
47
- }).then(function (response) {
48
- return response.data;
49
- });
50
- };
 
51
 
52
- Module.getTerms = function (options) {
53
- return Module._cachedQuery({
54
- action: 'getTerms',
55
- options: options
56
- }).then(function (response) {
57
- return response.data;
58
- });
59
- };
 
60
 
61
- Module.getPosts = function (options) {
62
- return Module._cachedQuery({
63
- action: 'getPosts',
64
- options: options
65
- }).then(function (response) {
66
- return response.data;
67
- });
68
  };
69
-
70
- Module.getTransformedPosts = function (options) {
71
- return Module._cachedQuery({
72
- action: 'getTransformedPosts',
73
- options: options
74
- }).then(function (response) {
75
- return response.data;
76
- });
77
  };
78
-
79
- Module.getBulkTransformedPosts = function (options) {
80
- return Module._query({
81
- action: 'getBulkTransformedPosts',
82
- options: options
83
- }).then(function (response) {
84
- return response.data;
85
- });
86
  };
87
 
88
- Module.saveNewsletter = function (options) {
89
- return MailPoet.Ajax.post({
90
- api_version: window.mailpoet_api_version,
91
- endpoint: 'newsletters',
92
- action: 'save',
93
- data: options || {}
94
- });
95
- };
96
 
97
- Module.previewNewsletter = function (options) {
98
- return MailPoet.Ajax.post({
99
- api_version: window.mailpoet_api_version,
100
- endpoint: 'newsletters',
101
- action: 'sendPreview',
102
- data: options || {}
103
- });
104
- };
105
 
106
- App.on('start', function () {
107
- // Prefetch post types
108
- Module.getPostTypes();
109
  });
110
 
111
  return Module;
@@ -118,27 +103,26 @@ webpackJsonp([4],{
118
  /***/ function(module, exports, __webpack_require__) {
119
 
120
  __webpack_require__(280);
121
- __webpack_require__(544);
122
- __webpack_require__(572);
123
- __webpack_require__(574);
124
  __webpack_require__(575);
125
- __webpack_require__(573);
126
- __webpack_require__(289);
127
- __webpack_require__(576);
128
  __webpack_require__(577);
129
  __webpack_require__(578);
 
 
130
  __webpack_require__(579);
 
 
131
  __webpack_require__(582);
132
- __webpack_require__(583);
133
- __webpack_require__(584);
134
  __webpack_require__(585);
135
  __webpack_require__(586);
136
  __webpack_require__(587);
 
137
  __webpack_require__(589);
138
  __webpack_require__(590);
139
- __webpack_require__(591);
140
- __webpack_require__(588);
141
  __webpack_require__(594);
 
142
  __webpack_require__(595);
143
  __webpack_require__(596);
144
  __webpack_require__(597);
@@ -159,7 +143,8 @@ webpackJsonp([4],{
159
  __webpack_require__(612);
160
  __webpack_require__(613);
161
  __webpack_require__(614);
162
- module.exports = __webpack_require__(615);
 
163
 
164
 
165
  /***/ },
@@ -7496,25815 +7481,25835 @@ webpackJsonp([4],{
7496
 
7497
  /***/ },
7498
 
7499
- /***/ 544:
7500
  /***/ function(module, exports, __webpack_require__) {
7501
 
7502
- /* WEBPACK VAR INJECTION */(function(global) {module.exports = global["Backbone"] = __webpack_require__(545);
7503
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
7504
 
7505
  /***/ },
7506
 
7507
- /***/ 545:
7508
  /***/ function(module, exports, __webpack_require__) {
7509
 
7510
- var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/* WEBPACK VAR INJECTION */(function(global) {// Backbone.js 1.3.3
 
 
 
 
 
7511
 
7512
- // (c) 2010-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
7513
- // Backbone may be freely distributed under the MIT license.
7514
- // For all details and documentation:
7515
- // http://backbonejs.org
 
 
 
 
 
7516
 
7517
- (function(factory) {
 
7518
 
7519
- // Establish the root object, `window` (`self`) in the browser, or `global` on the server.
7520
- // We use `self` instead of `window` for `WebWorker` support.
7521
- var root = (typeof self == 'object' && self.self === self && self) ||
7522
- (typeof global == 'object' && global.global === global && global);
7523
 
7524
- // Set up Backbone appropriately for the environment. Start with AMD.
7525
- if (true) {
7526
- !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(280), __webpack_require__(275), exports], __WEBPACK_AMD_DEFINE_RESULT__ = function(_, $, exports) {
7527
- // Export global even in AMD case in case this script is loaded with
7528
- // others that may still expect a global Backbone.
7529
- root.Backbone = factory(root, exports, _, $);
7530
- }.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
7531
 
7532
- // Next for Node.js or CommonJS. jQuery may not be needed as a module.
7533
- } else if (typeof exports !== 'undefined') {
7534
- var _ = require('underscore'), $;
7535
- try { $ = require('jquery'); } catch (e) {}
7536
- factory(root, exports, _, $);
7537
 
7538
- // Finally, as a browser global.
7539
- } else {
7540
- root.Backbone = factory(root, {}, root._, (root.jQuery || root.Zepto || root.ender || root.$));
7541
- }
7542
 
7543
- })(function(root, Backbone, _, $) {
 
 
 
 
 
 
7544
 
7545
- // Initial Setup
7546
- // -------------
 
7547
 
7548
- // Save the previous value of the `Backbone` variable, so that it can be
7549
- // restored later on, if `noConflict` is used.
7550
- var previousBackbone = root.Backbone;
 
 
 
 
 
 
 
7551
 
7552
- // Create a local reference to a common array method we'll want to use later.
7553
- var slice = Array.prototype.slice;
7554
 
7555
- // Current version of the library. Keep in sync with `package.json`.
7556
- Backbone.VERSION = '1.3.3';
 
 
 
 
 
 
 
 
 
7557
 
7558
- // For Backbone's purposes, jQuery, Zepto, Ender, or My Library (kidding) owns
7559
- // the `$` variable.
7560
- Backbone.$ = $;
7561
 
7562
- // Runs Backbone.js in *noConflict* mode, returning the `Backbone` variable
7563
- // to its previous owner. Returns a reference to this Backbone object.
7564
- Backbone.noConflict = function() {
7565
- root.Backbone = previousBackbone;
7566
- return this;
7567
- };
7568
 
7569
- // Turn on `emulateHTTP` to support legacy HTTP servers. Setting this option
7570
- // will fake `"PATCH"`, `"PUT"` and `"DELETE"` requests via the `_method` parameter and
7571
- // set a `X-Http-Method-Override` header.
7572
- Backbone.emulateHTTP = false;
 
 
7573
 
7574
- // Turn on `emulateJSON` to support legacy servers that can't deal with direct
7575
- // `application/json` requests ... this will encode the body as
7576
- // `application/x-www-form-urlencoded` instead and will send the model in a
7577
- // form param named `model`.
7578
- Backbone.emulateJSON = false;
7579
 
7580
- // Proxy Backbone class methods to Underscore functions, wrapping the model's
7581
- // `attributes` object or collection's `models` array behind the scenes.
7582
- //
7583
- // collection.filter(function(model) { return model.get('age') > 10 });
7584
- // collection.each(this.addView);
7585
- //
7586
- // `Function#apply` can be slow so we use the method's arg count, if we know it.
7587
- var addMethod = function(length, method, attribute) {
7588
- switch (length) {
7589
- case 1: return function() {
7590
- return _[method](this[attribute]);
7591
- };
7592
- case 2: return function(value) {
7593
- return _[method](this[attribute], value);
7594
- };
7595
- case 3: return function(iteratee, context) {
7596
- return _[method](this[attribute], cb(iteratee, this), context);
7597
- };
7598
- case 4: return function(iteratee, defaultVal, context) {
7599
- return _[method](this[attribute], cb(iteratee, this), defaultVal, context);
7600
  };
7601
- default: return function() {
7602
- var args = slice.call(arguments);
7603
- args.unshift(this[attribute]);
7604
- return _[method].apply(_, args);
 
 
 
 
7605
  };
7606
  }
7607
- };
7608
- var addUnderscoreMethods = function(Class, methods, attribute) {
7609
- _.each(methods, function(length, method) {
7610
- if (_[method]) Class.prototype[method] = addMethod(length, method, attribute);
7611
- });
7612
- };
7613
 
7614
- // Support `collection.sortBy('attr')` and `collection.findWhere({id: 1})`.
7615
- var cb = function(iteratee, instance) {
7616
- if (_.isFunction(iteratee)) return iteratee;
7617
- if (_.isObject(iteratee) && !instance._isModel(iteratee)) return modelMatcher(iteratee);
7618
- if (_.isString(iteratee)) return function(model) { return model.get(iteratee); };
7619
- return iteratee;
7620
- };
7621
- var modelMatcher = function(attrs) {
7622
- var matcher = _.matches(attrs);
7623
- return function(model) {
7624
- return matcher(model.attributes);
7625
- };
7626
- };
7627
 
7628
- // Backbone.Events
7629
- // ---------------
7630
 
7631
- // A module that can be mixed in to *any object* in order to provide it with
7632
- // a custom event channel. You may bind a callback to an event with `on` or
7633
- // remove with `off`; `trigger`-ing an event fires all callbacks in
7634
- // succession.
7635
- //
7636
- // var object = {};
7637
- // _.extend(object, Backbone.Events);
7638
- // object.on('expand', function(){ alert('expanded'); });
7639
- // object.trigger('expand');
7640
- //
7641
- var Events = Backbone.Events = {};
7642
 
7643
- // Regular expression used to split event strings.
7644
- var eventSplitter = /\s+/;
7645
 
7646
- // Iterates over the standard `event, callback` (as well as the fancy multiple
7647
- // space-separated events `"change blur", callback` and jQuery-style event
7648
- // maps `{event: callback}`).
7649
- var eventsApi = function(iteratee, events, name, callback, opts) {
7650
- var i = 0, names;
7651
- if (name && typeof name === 'object') {
7652
- // Handle event maps.
7653
- if (callback !== void 0 && 'context' in opts && opts.context === void 0) opts.context = callback;
7654
- for (names = _.keys(name); i < names.length ; i++) {
7655
- events = eventsApi(iteratee, events, names[i], name[names[i]], opts);
7656
- }
7657
- } else if (name && eventSplitter.test(name)) {
7658
- // Handle space-separated event names by delegating them individually.
7659
- for (names = name.split(eventSplitter); i < names.length; i++) {
7660
- events = iteratee(events, names[i], callback, opts);
7661
  }
7662
- } else {
7663
- // Finally, standard events.
7664
- events = iteratee(events, name, callback, opts);
7665
  }
7666
- return events;
7667
- };
7668
 
7669
- // Bind an event to a `callback` function. Passing `"all"` will bind
7670
- // the callback to all events fired.
7671
- Events.on = function(name, callback, context) {
7672
- return internalOn(this, name, callback, context);
7673
- };
7674
 
7675
- // Guard the `listening` argument from the public API.
7676
- var internalOn = function(obj, name, callback, context, listening) {
7677
- obj._events = eventsApi(onApi, obj._events || {}, name, callback, {
7678
- context: context,
7679
- ctx: obj,
7680
- listening: listening
7681
- });
 
 
 
7682
 
7683
- if (listening) {
7684
- var listeners = obj._listeners || (obj._listeners = {});
7685
- listeners[listening.id] = listening;
 
 
 
 
 
7686
  }
7687
 
7688
- return obj;
7689
- };
 
7690
 
7691
- // Inversion-of-control versions of `on`. Tell *this* object to listen to
7692
- // an event in another object... keeping track of what it's listening to
7693
- // for easier unbinding later.
7694
- Events.listenTo = function(obj, name, callback) {
7695
- if (!obj) return this;
7696
- var id = obj._listenId || (obj._listenId = _.uniqueId('l'));
7697
- var listeningTo = this._listeningTo || (this._listeningTo = {});
7698
- var listening = listeningTo[id];
7699
 
7700
- // This object is not listening to any other events on `obj` yet.
7701
- // Setup the necessary references to track the listening callbacks.
7702
- if (!listening) {
7703
- var thisId = this._listenId || (this._listenId = _.uniqueId('l'));
7704
- listening = listeningTo[id] = {obj: obj, objId: id, id: thisId, listeningTo: listeningTo, count: 0};
 
7705
  }
7706
 
7707
- // Bind callbacks on obj, and keep track of them on listening.
7708
- internalOn(obj, name, callback, this, listening);
7709
- return this;
7710
- };
 
 
 
 
 
 
 
 
 
 
7711
 
7712
- // The reducing API that adds a callback to the `events` object.
7713
- var onApi = function(events, name, callback, options) {
7714
- if (callback) {
7715
- var handlers = events[name] || (events[name] = []);
7716
- var context = options.context, ctx = options.ctx, listening = options.listening;
7717
- if (listening) listening.count++;
7718
 
7719
- handlers.push({callback: callback, context: context, ctx: context || ctx, listening: listening});
 
 
 
 
7720
  }
7721
- return events;
7722
- };
7723
 
7724
- // Remove one or many callbacks. If `context` is null, removes all
7725
- // callbacks with that function. If `callback` is null, removes all
7726
- // callbacks for the event. If `name` is null, removes all bound
7727
- // callbacks for all events.
7728
- Events.off = function(name, callback, context) {
7729
- if (!this._events) return this;
7730
- this._events = eventsApi(offApi, this._events, name, callback, {
7731
- context: context,
7732
- listeners: this._listeners
7733
- });
7734
- return this;
7735
- };
 
7736
 
7737
- // Tell this object to stop listening to either specific events ... or
7738
- // to every object it's currently listening to.
7739
- Events.stopListening = function(obj, name, callback) {
7740
- var listeningTo = this._listeningTo;
7741
- if (!listeningTo) return this;
7742
 
7743
- var ids = obj ? [obj._listenId] : _.keys(listeningTo);
 
 
 
 
 
 
 
 
 
 
7744
 
7745
- for (var i = 0; i < ids.length; i++) {
7746
- var listening = listeningTo[ids[i]];
 
 
 
 
 
 
 
7747
 
7748
- // If listening doesn't exist, this object is not currently
7749
- // listening to obj. Break out early.
7750
- if (!listening) break;
 
7751
 
7752
- listening.obj.off(name, callback, this);
7753
  }
7754
 
7755
- return this;
7756
- };
7757
 
7758
- // The reducing API that removes a callback from the `events` object.
7759
- var offApi = function(events, name, callback, options) {
7760
- if (!events) return;
7761
 
7762
- var i = 0, listening;
7763
- var context = options.context, listeners = options.listeners;
 
 
 
7764
 
7765
- // Delete all events listeners and "drop" events.
7766
- if (!name && !callback && !context) {
7767
- var ids = _.keys(listeners);
7768
- for (; i < ids.length; i++) {
7769
- listening = listeners[ids[i]];
7770
- delete listeners[listening.id];
7771
- delete listening.listeningTo[listening.objId];
 
 
 
 
 
 
 
 
 
 
 
 
 
7772
  }
7773
- return;
7774
  }
7775
 
7776
- var names = name ? [name] : _.keys(events);
7777
- for (; i < names.length; i++) {
7778
- name = names[i];
7779
- var handlers = events[name];
7780
 
7781
- // Bail out if there are no events stored.
7782
- if (!handlers) break;
7783
 
7784
- // Replace events if there are any remaining. Otherwise, clean up.
7785
- var remaining = [];
7786
- for (var j = 0; j < handlers.length; j++) {
7787
- var handler = handlers[j];
7788
- if (
7789
- callback && callback !== handler.callback &&
7790
- callback !== handler.callback._callback ||
7791
- context && context !== handler.context
7792
- ) {
7793
- remaining.push(handler);
7794
  } else {
7795
- listening = handler.listening;
7796
- if (listening && --listening.count === 0) {
7797
- delete listeners[listening.id];
7798
- delete listening.listeningTo[listening.objId];
7799
- }
7800
  }
7801
  }
7802
 
7803
- // Update tail event if the list has any events. Otherwise, clean up.
7804
- if (remaining.length) {
7805
- events[name] = remaining;
7806
- } else {
7807
- delete events[name];
7808
- }
7809
  }
7810
- return events;
7811
- };
7812
 
7813
- // Bind an event to only be triggered a single time. After the first time
7814
- // the callback is invoked, its listener will be removed. If multiple events
7815
- // are passed in using the space-separated syntax, the handler will fire
7816
- // once for each event, not once for a combination of all events.
7817
- Events.once = function(name, callback, context) {
7818
- // Map the event into a `{event: once}` object.
7819
- var events = eventsApi(onceMap, {}, name, callback, _.bind(this.off, this));
7820
- if (typeof name === 'string' && context == null) callback = void 0;
7821
- return this.on(events, callback, context);
7822
- };
7823
 
7824
- // Inversion-of-control versions of `once`.
7825
- Events.listenToOnce = function(obj, name, callback) {
7826
- // Map the event into a `{event: once}` object.
7827
- var events = eventsApi(onceMap, {}, name, callback, _.bind(this.stopListening, this, obj));
7828
- return this.listenTo(obj, events);
7829
- };
7830
 
7831
- // Reduces the event callbacks into a map of `{event: onceWrapper}`.
7832
- // `offer` unbinds the `onceWrapper` after it has been called.
7833
- var onceMap = function(map, name, callback, offer) {
7834
- if (callback) {
7835
- var once = map[name] = _.once(function() {
7836
- offer(name, once);
7837
- callback.apply(this, arguments);
7838
- });
7839
- once._callback = callback;
7840
  }
7841
- return map;
7842
- };
7843
 
7844
- // Trigger one or many events, firing all bound callbacks. Callbacks are
7845
- // passed the same arguments as `trigger` is, apart from the event name
7846
- // (unless you're listening on `"all"`, which will cause your callback to
7847
- // receive the true name of the event as the first argument).
7848
- Events.trigger = function(name) {
7849
- if (!this._events) return this;
7850
 
7851
- var length = Math.max(0, arguments.length - 1);
7852
- var args = Array(length);
7853
- for (var i = 0; i < length; i++) args[i] = arguments[i + 1];
7854
 
7855
- eventsApi(triggerApi, this._events, name, void 0, args);
7856
- return this;
7857
- };
 
 
 
 
7858
 
7859
- // Handles triggering the appropriate event callbacks.
7860
- var triggerApi = function(objEvents, name, callback, args) {
7861
- if (objEvents) {
7862
- var events = objEvents[name];
7863
- var allEvents = objEvents.all;
7864
- if (events && allEvents) allEvents = allEvents.slice();
7865
- if (events) triggerEvents(events, args);
7866
- if (allEvents) triggerEvents(allEvents, [name].concat(args));
 
 
 
 
 
 
 
 
 
 
 
 
 
7867
  }
7868
- return objEvents;
7869
- };
7870
 
7871
- // A difficult-to-believe, but optimized internal dispatch function for
7872
- // triggering events. Tries to keep the usual cases speedy (most internal
7873
- // Backbone events have 3 arguments).
7874
- var triggerEvents = function(events, args) {
7875
- var ev, i = -1, l = events.length, a1 = args[0], a2 = args[1], a3 = args[2];
7876
- switch (args.length) {
7877
- case 0: while (++i < l) (ev = events[i]).callback.call(ev.ctx); return;
7878
- case 1: while (++i < l) (ev = events[i]).callback.call(ev.ctx, a1); return;
7879
- case 2: while (++i < l) (ev = events[i]).callback.call(ev.ctx, a1, a2); return;
7880
- case 3: while (++i < l) (ev = events[i]).callback.call(ev.ctx, a1, a2, a3); return;
7881
- default: while (++i < l) (ev = events[i]).callback.apply(ev.ctx, args); return;
7882
  }
7883
- };
7884
 
7885
- // Aliases for backwards compatibility.
7886
- Events.bind = Events.on;
7887
- Events.unbind = Events.off;
 
 
 
 
 
 
 
 
 
 
7888
 
7889
- // Allow the `Backbone` object to serve as a global event bus, for folks who
7890
- // want global "pubsub" in a convenient place.
7891
- _.extend(Backbone, Events);
 
7892
 
7893
- // Backbone.Model
7894
- // --------------
 
 
7895
 
7896
- // Backbone **Models** are the basic data object in the framework --
7897
- // frequently representing a row in a table in a database on your server.
7898
- // A discrete chunk of data and a bunch of useful, related methods for
7899
- // performing computations and transformations on that data.
7900
 
7901
- // Create a new model with the specified attributes. A client id (`cid`)
7902
- // is automatically generated and assigned for you.
7903
- var Model = Backbone.Model = function(attributes, options) {
7904
- var attrs = attributes || {};
7905
- options || (options = {});
7906
- this.cid = _.uniqueId(this.cidPrefix);
7907
- this.attributes = {};
7908
- if (options.collection) this.collection = options.collection;
7909
- if (options.parse) attrs = this.parse(attrs, options) || {};
7910
- var defaults = _.result(this, 'defaults');
7911
- attrs = _.defaults(_.extend({}, defaults, attrs), defaults);
7912
- this.set(attrs, options);
7913
- this.changed = {};
7914
- this.initialize.apply(this, arguments);
7915
- };
7916
 
7917
- // Attach all inheritable methods to the Model prototype.
7918
- _.extend(Model.prototype, Events, {
 
7919
 
7920
- // A hash of attributes whose current and previous value differ.
7921
- changed: null,
 
7922
 
7923
- // The value returned during the last failed validation.
7924
- validationError: null,
 
7925
 
7926
- // The default name for the JSON `id` attribute is `"id"`. MongoDB and
7927
- // CouchDB users may want to set this to `"_id"`.
7928
- idAttribute: 'id',
7929
 
7930
- // The prefix is used to create the client id which is used to identify models locally.
7931
- // You may want to override this if you're experiencing name clashes with model ids.
7932
- cidPrefix: 'c',
 
7933
 
7934
- // Initialize is an empty function by default. Override it with your own
7935
- // initialization logic.
7936
- initialize: function(){},
 
7937
 
7938
- // Return a copy of the model's `attributes` object.
7939
- toJSON: function(options) {
7940
- return _.clone(this.attributes);
7941
- },
 
 
 
 
 
 
 
 
 
 
7942
 
7943
- // Proxy `Backbone.sync` by default -- but override this if you need
7944
- // custom syncing semantics for *this* particular model.
7945
- sync: function() {
7946
- return Backbone.sync.apply(this, arguments);
7947
- },
7948
 
7949
- // Get the value of an attribute.
7950
- get: function(attr) {
7951
- return this.attributes[attr];
7952
- },
7953
 
7954
- // Get the HTML-escaped value of an attribute.
7955
- escape: function(attr) {
7956
- return _.escape(this.get(attr));
7957
- },
 
 
7958
 
7959
- // Returns `true` if the attribute contains a value that is not null
7960
- // or undefined.
7961
- has: function(attr) {
7962
- return this.get(attr) != null;
7963
- },
7964
 
7965
- // Special-cased proxy to underscore's `_.matches` method.
7966
- matches: function(attrs) {
7967
- return !!_.iteratee(attrs, this)(this.attributes);
7968
- },
7969
 
7970
- // Set a hash of model attributes on the object, firing `"change"`. This is
7971
- // the core primitive operation of a model, updating the data and notifying
7972
- // anyone who needs to know about the change in state. The heart of the beast.
7973
- set: function(key, val, options) {
7974
- if (key == null) return this;
7975
 
7976
- // Handle both `"key", value` and `{key: value}` -style arguments.
7977
- var attrs;
7978
- if (typeof key === 'object') {
7979
- attrs = key;
7980
- options = val;
7981
- } else {
7982
- (attrs = {})[key] = val;
7983
- }
7984
 
7985
- options || (options = {});
 
 
7986
 
7987
- // Run validation.
7988
- if (!this._validate(attrs, options)) return false;
 
7989
 
7990
- // Extract attributes and options.
7991
- var unset = options.unset;
7992
- var silent = options.silent;
7993
- var changes = [];
7994
- var changing = this._changing;
7995
- this._changing = true;
7996
 
7997
- if (!changing) {
7998
- this._previousAttributes = _.clone(this.attributes);
7999
- this.changed = {};
8000
  }
8001
 
8002
- var current = this.attributes;
8003
- var changed = this.changed;
8004
- var prev = this._previousAttributes;
8005
 
8006
- // For each `set` attribute, update or delete the current value.
8007
- for (var attr in attrs) {
8008
- val = attrs[attr];
8009
- if (!_.isEqual(current[attr], val)) changes.push(attr);
8010
- if (!_.isEqual(prev[attr], val)) {
8011
- changed[attr] = val;
8012
- } else {
8013
- delete changed[attr];
8014
- }
8015
- unset ? delete current[attr] : current[attr] = val;
8016
  }
8017
 
8018
- // Update the `id`.
8019
- if (this.idAttribute in attrs) this.id = this.get(this.idAttribute);
8020
-
8021
- // Trigger all relevant attribute changes.
8022
- if (!silent) {
8023
- if (changes.length) this._pending = options;
8024
- for (var i = 0; i < changes.length; i++) {
8025
- this.trigger('change:' + changes[i], this, current[changes[i]], options);
8026
- }
8027
  }
8028
 
8029
- // You might be wondering why there's a `while` loop here. Changes can
8030
- // be recursively nested within `"change"` events.
8031
- if (changing) return this;
8032
- if (!silent) {
8033
- while (this._pending) {
8034
- options = this._pending;
8035
- this._pending = false;
8036
- this.trigger('change', this, options);
8037
- }
8038
  }
8039
- this._pending = false;
8040
- this._changing = false;
8041
- return this;
8042
- },
8043
 
8044
- // Remove an attribute from the model, firing `"change"`. `unset` is a noop
8045
- // if the attribute doesn't exist.
8046
- unset: function(attr, options) {
8047
- return this.set(attr, void 0, _.extend({}, options, {unset: true}));
8048
- },
8049
 
8050
- // Clear all attributes on the model, firing `"change"`.
8051
- clear: function(options) {
8052
- var attrs = {};
8053
- for (var key in this.attributes) attrs[key] = void 0;
8054
- return this.set(attrs, _.extend({}, options, {unset: true}));
8055
- },
8056
-
8057
- // Determine if the model has changed since the last `"change"` event.
8058
- // If you specify an attribute name, determine if that attribute has changed.
8059
- hasChanged: function(attr) {
8060
- if (attr == null) return !_.isEmpty(this.changed);
8061
- return _.has(this.changed, attr);
8062
- },
8063
 
8064
- // Return an object containing all the attributes that have changed, or
8065
- // false if there are no changed attributes. Useful for determining what
8066
- // parts of a view need to be updated and/or what attributes need to be
8067
- // persisted to the server. Unset attributes will be set to undefined.
8068
- // You can also pass an attributes object to diff against the model,
8069
- // determining if there *would be* a change.
8070
- changedAttributes: function(diff) {
8071
- if (!diff) return this.hasChanged() ? _.clone(this.changed) : false;
8072
- var old = this._changing ? this._previousAttributes : this.attributes;
8073
- var changed = {};
8074
- for (var attr in diff) {
8075
- var val = diff[attr];
8076
- if (_.isEqual(old[attr], val)) continue;
8077
- changed[attr] = val;
8078
  }
8079
- return _.size(changed) ? changed : false;
8080
- },
8081
 
8082
- // Get the previous value of an attribute, recorded at the time the last
8083
- // `"change"` event was fired.
8084
- previous: function(attr) {
8085
- if (attr == null || !this._previousAttributes) return null;
8086
- return this._previousAttributes[attr];
8087
- },
8088
 
8089
- // Get all of the attributes of the model at the time of the previous
8090
- // `"change"` event.
8091
- previousAttributes: function() {
8092
- return _.clone(this._previousAttributes);
8093
- },
 
 
8094
 
8095
- // Fetch the model from the server, merging the response with the model's
8096
- // local attributes. Any changed attributes will trigger a "change" event.
8097
- fetch: function(options) {
8098
- options = _.extend({parse: true}, options);
8099
- var model = this;
8100
- var success = options.success;
8101
- options.success = function(resp) {
8102
- var serverAttrs = options.parse ? model.parse(resp, options) : resp;
8103
- if (!model.set(serverAttrs, options)) return false;
8104
- if (success) success.call(options.context, model, resp, options);
8105
- model.trigger('sync', model, resp, options);
8106
- };
8107
- wrapError(this, options);
8108
- return this.sync('read', this, options);
8109
- },
8110
 
8111
- // Set a hash of model attributes, and sync the model to the server.
8112
- // If the server returns an attributes hash that differs, the model's
8113
- // state will be `set` again.
8114
- save: function(key, val, options) {
8115
- // Handle both `"key", value` and `{key: value}` -style arguments.
8116
- var attrs;
8117
- if (key == null || typeof key === 'object') {
8118
- attrs = key;
8119
- options = val;
8120
- } else {
8121
- (attrs = {})[key] = val;
8122
- }
8123
 
8124
- options = _.extend({validate: true, parse: true}, options);
8125
- var wait = options.wait;
 
8126
 
8127
- // If we're not waiting and attributes exist, save acts as
8128
- // `set(attr).save(null, opts)` with validation. Otherwise, check if
8129
- // the model will be valid when the attributes, if any, are set.
8130
- if (attrs && !wait) {
8131
- if (!this.set(attrs, options)) return false;
8132
- } else if (!this._validate(attrs, options)) {
8133
- return false;
8134
- }
8135
 
8136
- // After a successful server-side save, the client is (optionally)
8137
- // updated with the server-side state.
8138
- var model = this;
8139
- var success = options.success;
8140
- var attributes = this.attributes;
8141
- options.success = function(resp) {
8142
- // Ensure attributes are restored during synchronous saves.
8143
- model.attributes = attributes;
8144
- var serverAttrs = options.parse ? model.parse(resp, options) : resp;
8145
- if (wait) serverAttrs = _.extend({}, attrs, serverAttrs);
8146
- if (serverAttrs && !model.set(serverAttrs, options)) return false;
8147
- if (success) success.call(options.context, model, resp, options);
8148
- model.trigger('sync', model, resp, options);
8149
- };
8150
- wrapError(this, options);
8151
 
8152
- // Set temporary attributes if `{wait: true}` to properly find new ids.
8153
- if (attrs && wait) this.attributes = _.extend({}, attributes, attrs);
8154
 
8155
- var method = this.isNew() ? 'create' : (options.patch ? 'patch' : 'update');
8156
- if (method === 'patch' && !options.attrs) options.attrs = attrs;
8157
- var xhr = this.sync(method, this, options);
 
 
 
8158
 
8159
- // Restore attributes.
8160
- this.attributes = attributes;
8161
 
8162
- return xhr;
8163
- },
 
8164
 
8165
- // Destroy this model on the server if it was already persisted.
8166
- // Optimistically removes the model from its collection, if it has one.
8167
- // If `wait: true` is passed, waits for the server to respond before removal.
8168
- destroy: function(options) {
8169
- options = options ? _.clone(options) : {};
8170
- var model = this;
8171
- var success = options.success;
8172
- var wait = options.wait;
8173
 
8174
- var destroy = function() {
8175
- model.stopListening();
8176
- model.trigger('destroy', model, model.collection, options);
8177
- };
8178
 
8179
- options.success = function(resp) {
8180
- if (wait) destroy();
8181
- if (success) success.call(options.context, model, resp, options);
8182
- if (!model.isNew()) model.trigger('sync', model, resp, options);
8183
- };
8184
 
8185
- var xhr = false;
8186
- if (this.isNew()) {
8187
- _.defer(options.success);
8188
- } else {
8189
- wrapError(this, options);
8190
- xhr = this.sync('delete', this, options);
8191
- }
8192
- if (!wait) destroy();
8193
- return xhr;
8194
- },
8195
 
8196
- // Default URL for the model's representation on the server -- if you're
8197
- // using Backbone's restful methods, override this to change the endpoint
8198
- // that will be called.
8199
- url: function() {
8200
- var base =
8201
- _.result(this, 'urlRoot') ||
8202
- _.result(this.collection, 'url') ||
8203
- urlError();
8204
- if (this.isNew()) return base;
8205
- var id = this.get(this.idAttribute);
8206
- return base.replace(/[^\/]$/, '$&/') + encodeURIComponent(id);
8207
- },
8208
 
8209
- // **parse** converts a response into the hash of attributes to be `set` on
8210
- // the model. The default implementation is just to pass the response along.
8211
- parse: function(resp, options) {
8212
- return resp;
8213
- },
 
8214
 
8215
- // Create a new model with identical attributes to this one.
8216
- clone: function() {
8217
- return new this.constructor(this.attributes);
8218
- },
8219
 
8220
- // A model is new if it has never been saved to the server, and lacks an id.
8221
- isNew: function() {
8222
- return !this.has(this.idAttribute);
8223
- },
8224
 
8225
- // Check if the model is currently in a valid state.
8226
- isValid: function(options) {
8227
- return this._validate({}, _.extend({}, options, {validate: true}));
8228
- },
8229
 
8230
- // Run validation against the next complete set of model attributes,
8231
- // returning `true` if all is well. Otherwise, fire an `"invalid"` event.
8232
- _validate: function(attrs, options) {
8233
- if (!options.validate || !this.validate) return true;
8234
- attrs = _.extend({}, this.attributes, attrs);
8235
- var error = this.validationError = this.validate(attrs, options) || null;
8236
- if (!error) return true;
8237
- this.trigger('invalid', this, error, _.extend(options, {validationError: error}));
8238
- return false;
8239
- }
8240
 
8241
- });
 
 
 
 
 
 
 
 
 
 
8242
 
8243
- // Underscore methods that we want to implement on the Model, mapped to the
8244
- // number of arguments they take.
8245
- var modelMethods = {keys: 1, values: 1, pairs: 1, invert: 1, pick: 0,
8246
- omit: 0, chain: 1, isEmpty: 1};
 
 
8247
 
8248
- // Mix in each Underscore method as a proxy to `Model#attributes`.
8249
- addUnderscoreMethods(Model, modelMethods, 'attributes');
8250
 
8251
- // Backbone.Collection
8252
- // -------------------
 
 
 
 
 
8253
 
8254
- // If models tend to represent a single row of data, a Backbone Collection is
8255
- // more analogous to a table full of data ... or a small slice or page of that
8256
- // table, or a collection of rows that belong together for a particular reason
8257
- // -- all of the messages in this particular folder, all of the documents
8258
- // belonging to this particular author, and so on. Collections maintain
8259
- // indexes of their models, both in order, and for lookup by `id`.
8260
 
8261
- // Create a new **Collection**, perhaps to contain a specific type of `model`.
8262
- // If a `comparator` is specified, the Collection will maintain
8263
- // its models in sort order, as they're added and removed.
8264
- var Collection = Backbone.Collection = function(models, options) {
8265
- options || (options = {});
8266
- if (options.model) this.model = options.model;
8267
- if (options.comparator !== void 0) this.comparator = options.comparator;
8268
- this._reset();
8269
- this.initialize.apply(this, arguments);
8270
- if (models) this.reset(models, _.extend({silent: true}, options));
8271
- };
8272
 
8273
- // Default options for `Collection#set`.
8274
- var setOptions = {add: true, remove: true, merge: true};
8275
- var addOptions = {add: true, remove: false};
 
8276
 
8277
- // Splices `insert` into `array` at index `at`.
8278
- var splice = function(array, insert, at) {
8279
- at = Math.min(Math.max(at, 0), array.length);
8280
- var tail = Array(array.length - at);
8281
- var length = insert.length;
8282
- var i;
8283
- for (i = 0; i < tail.length; i++) tail[i] = array[i + at];
8284
- for (i = 0; i < length; i++) array[i + at] = insert[i];
8285
- for (i = 0; i < tail.length; i++) array[i + length + at] = tail[i];
8286
- };
8287
 
8288
- // Define the Collection's inheritable methods.
8289
- _.extend(Collection.prototype, Events, {
 
8290
 
8291
- // The default model for a collection is just a **Backbone.Model**.
8292
- // This should be overridden in most cases.
8293
- model: Model,
 
8294
 
8295
- // Initialize is an empty function by default. Override it with your own
8296
- // initialization logic.
8297
- initialize: function(){},
8298
 
8299
- // The JSON representation of a Collection is an array of the
8300
- // models' attributes.
8301
- toJSON: function(options) {
8302
- return this.map(function(model) { return model.toJSON(options); });
8303
- },
8304
 
8305
- // Proxy `Backbone.sync` by default.
8306
- sync: function() {
8307
- return Backbone.sync.apply(this, arguments);
8308
- },
 
 
 
8309
 
8310
- // Add a model, or list of models to the set. `models` may be Backbone
8311
- // Models or raw JavaScript objects to be converted to Models, or any
8312
- // combination of the two.
8313
- add: function(models, options) {
8314
- return this.set(models, _.extend({merge: false}, options, addOptions));
8315
- },
8316
 
8317
- // Remove a model, or a list of models from the set.
8318
- remove: function(models, options) {
8319
- options = _.extend({}, options);
8320
- var singular = !_.isArray(models);
8321
- models = singular ? [models] : models.slice();
8322
- var removed = this._removeModels(models, options);
8323
- if (!options.silent && removed.length) {
8324
- options.changes = {added: [], merged: [], removed: removed};
8325
- this.trigger('update', this, options);
8326
- }
8327
- return singular ? removed[0] : removed;
8328
- },
8329
 
8330
- // Update a collection by `set`-ing a new list of models, adding new ones,
8331
- // removing models that are no longer present, and merging models that
8332
- // already exist in the collection, as necessary. Similar to **Model#set**,
8333
- // the core operation for updating the data contained by the collection.
8334
- set: function(models, options) {
8335
- if (models == null) return;
 
 
 
8336
 
8337
- options = _.extend({}, setOptions, options);
8338
- if (options.parse && !this._isModel(models)) {
8339
- models = this.parse(models, options) || [];
8340
- }
 
 
 
 
 
 
 
 
8341
 
8342
- var singular = !_.isArray(models);
8343
- models = singular ? [models] : models.slice();
 
 
 
 
 
 
 
 
 
8344
 
8345
- var at = options.at;
8346
- if (at != null) at = +at;
8347
- if (at > this.length) at = this.length;
8348
- if (at < 0) at += this.length + 1;
8349
 
8350
- var set = [];
8351
- var toAdd = [];
8352
- var toMerge = [];
8353
- var toRemove = [];
8354
- var modelMap = {};
8355
 
8356
- var add = options.add;
8357
- var merge = options.merge;
8358
- var remove = options.remove;
 
 
 
 
8359
 
8360
- var sort = false;
8361
- var sortable = this.comparator && at == null && options.sort !== false;
8362
- var sortAttr = _.isString(this.comparator) ? this.comparator : null;
8363
 
8364
- // Turn bare objects into model references, and prevent invalid models
8365
- // from being added.
8366
- var model, i;
8367
- for (i = 0; i < models.length; i++) {
8368
- model = models[i];
 
 
 
 
8369
 
8370
- // If a duplicate is found, prevent it from being added and
8371
- // optionally merge it into the existing model.
8372
- var existing = this.get(model);
8373
- if (existing) {
8374
- if (merge && model !== existing) {
8375
- var attrs = this._isModel(model) ? model.attributes : model;
8376
- if (options.parse) attrs = existing.parse(attrs, options);
8377
- existing.set(attrs, options);
8378
- toMerge.push(existing);
8379
- if (sortable && !sort) sort = existing.hasChanged(sortAttr);
8380
- }
8381
- if (!modelMap[existing.cid]) {
8382
- modelMap[existing.cid] = true;
8383
- set.push(existing);
8384
- }
8385
- models[i] = existing;
8386
 
8387
- // If this is a new, valid model, push it to the `toAdd` list.
8388
- } else if (add) {
8389
- model = models[i] = this._prepareModel(model, options);
8390
- if (model) {
8391
- toAdd.push(model);
8392
- this._addReference(model, options);
8393
- modelMap[model.cid] = true;
8394
- set.push(model);
8395
- }
8396
- }
8397
- }
8398
 
8399
- // Remove stale models.
8400
- if (remove) {
8401
- for (i = 0; i < this.length; i++) {
8402
- model = this.models[i];
8403
- if (!modelMap[model.cid]) toRemove.push(model);
8404
- }
8405
- if (toRemove.length) this._removeModels(toRemove, options);
 
8406
  }
 
8407
 
8408
- // See if sorting is needed, update `length` and splice in new models.
8409
- var orderChanged = false;
8410
- var replace = !sortable && add && remove;
8411
- if (set.length && replace) {
8412
- orderChanged = this.length !== set.length || _.some(this.models, function(m, index) {
8413
- return m !== set[index];
8414
- });
8415
- this.models.length = 0;
8416
- splice(this.models, set, 0);
8417
- this.length = this.models.length;
8418
- } else if (toAdd.length) {
8419
- if (sortable) sort = true;
8420
- splice(this.models, toAdd, at == null ? this.length : at);
8421
- this.length = this.models.length;
8422
- }
8423
-
8424
- // Silently sort the collection if appropriate.
8425
- if (sort) this.sort({silent: true});
8426
 
8427
- // Unless silenced, it's time to fire all appropriate add/sort/update events.
8428
- if (!options.silent) {
8429
- for (i = 0; i < toAdd.length; i++) {
8430
- if (at != null) options.index = at + i;
8431
- model = toAdd[i];
8432
- model.trigger('add', model, this, options);
8433
- }
8434
- if (sort || orderChanged) this.trigger('sort', this, options);
8435
- if (toAdd.length || toRemove.length || toMerge.length) {
8436
- options.changes = {
8437
- added: toAdd,
8438
- removed: toRemove,
8439
- merged: toMerge
8440
- };
8441
- this.trigger('update', this, options);
8442
  }
8443
- }
 
8444
 
8445
- // Return the added (or merged) model (or models).
8446
- return singular ? models[0] : models;
8447
- },
8448
 
8449
- // When you have more items than you want to add or remove individually,
8450
- // you can reset the entire set with a new list of models, without firing
8451
- // any granular `add` or `remove` events. Fires `reset` when finished.
8452
- // Useful for bulk operations and optimizations.
8453
- reset: function(models, options) {
8454
- options = options ? _.clone(options) : {};
8455
- for (var i = 0; i < this.models.length; i++) {
8456
- this._removeReference(this.models[i], options);
8457
- }
8458
- options.previousModels = this.models;
8459
- this._reset();
8460
- models = this.add(models, _.extend({silent: true}, options));
8461
- if (!options.silent) this.trigger('reset', this, options);
8462
- return models;
8463
- },
8464
 
8465
- // Add a model to the end of the collection.
8466
- push: function(model, options) {
8467
- return this.add(model, _.extend({at: this.length}, options));
8468
- },
8469
 
8470
- // Remove a model from the end of the collection.
8471
- pop: function(options) {
8472
- var model = this.at(this.length - 1);
8473
- return this.remove(model, options);
8474
- },
8475
 
8476
- // Add a model to the beginning of the collection.
8477
- unshift: function(model, options) {
8478
- return this.add(model, _.extend({at: 0}, options));
8479
- },
8480
 
8481
- // Remove a model from the beginning of the collection.
8482
- shift: function(options) {
8483
- var model = this.at(0);
8484
- return this.remove(model, options);
8485
- },
 
 
 
8486
 
8487
- // Slice out a sub-array of models from the collection.
8488
- slice: function() {
8489
- return slice.apply(this.models, arguments);
8490
- },
8491
 
8492
- // Get a model from the set by id, cid, model object with id or cid
8493
- // properties, or an attributes object that is transformed through modelId.
8494
- get: function(obj) {
8495
- if (obj == null) return void 0;
8496
- return this._byId[obj] ||
8497
- this._byId[this.modelId(obj.attributes || obj)] ||
8498
- obj.cid && this._byId[obj.cid];
8499
- },
8500
 
8501
- // Returns `true` if the model is in the collection.
8502
- has: function(obj) {
8503
- return this.get(obj) != null;
8504
- },
8505
 
8506
- // Get the model at the given index.
8507
- at: function(index) {
8508
- if (index < 0) index += this.length;
8509
- return this.models[index];
8510
- },
8511
 
8512
- // Return models with matching attributes. Useful for simple cases of
8513
- // `filter`.
8514
- where: function(attrs, first) {
8515
- return this[first ? 'find' : 'filter'](attrs);
8516
- },
8517
 
8518
- // Return the first model with matching attributes. Useful for simple cases
8519
- // of `find`.
8520
- findWhere: function(attrs) {
8521
- return this.where(attrs, true);
8522
- },
8523
 
8524
- // Force the collection to re-sort itself. You don't need to call this under
8525
- // normal circumstances, as the set will maintain sort order as each item
8526
- // is added.
8527
- sort: function(options) {
8528
- var comparator = this.comparator;
8529
- if (!comparator) throw new Error('Cannot sort a set without a comparator');
8530
- options || (options = {});
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
8531
 
8532
- var length = comparator.length;
8533
- if (_.isFunction(comparator)) comparator = _.bind(comparator, this);
8534
 
8535
- // Run sort based on type of `comparator`.
8536
- if (length === 1 || _.isString(comparator)) {
8537
- this.models = this.sortBy(comparator);
8538
- } else {
8539
- this.models.sort(comparator);
8540
- }
8541
- if (!options.silent) this.trigger('sort', this, options);
8542
- return this;
8543
- },
8544
 
8545
- // Pluck an attribute from each model in the collection.
8546
- pluck: function(attr) {
8547
- return this.map(attr + '');
8548
- },
 
 
 
 
 
8549
 
8550
- // Fetch the default set of models for this collection, resetting the
8551
- // collection when they arrive. If `reset: true` is passed, the response
8552
- // data will be passed through the `reset` method instead of `set`.
8553
- fetch: function(options) {
8554
- options = _.extend({parse: true}, options);
8555
- var success = options.success;
8556
- var collection = this;
8557
- options.success = function(resp) {
8558
- var method = options.reset ? 'reset' : 'set';
8559
- collection[method](resp, options);
8560
- if (success) success.call(options.context, collection, resp, options);
8561
- collection.trigger('sync', collection, resp, options);
8562
- };
8563
- wrapError(this, options);
8564
- return this.sync('read', this, options);
8565
- },
8566
 
8567
- // Create a new instance of a model in this collection. Add the model to the
8568
- // collection immediately, unless `wait: true` is passed, in which case we
8569
- // wait for the server to agree.
8570
- create: function(model, options) {
8571
- options = options ? _.clone(options) : {};
8572
- var wait = options.wait;
8573
- model = this._prepareModel(model, options);
8574
- if (!model) return false;
8575
- if (!wait) this.add(model, options);
8576
- var collection = this;
8577
- var success = options.success;
8578
- options.success = function(m, resp, callbackOpts) {
8579
- if (wait) collection.add(m, callbackOpts);
8580
- if (success) success.call(callbackOpts.context, m, resp, callbackOpts);
8581
- };
8582
- model.save(null, options);
8583
- return model;
8584
- },
8585
 
8586
- // **parse** converts a response into a list of models to be added to the
8587
- // collection. The default implementation is just to pass it through.
8588
- parse: function(resp, options) {
8589
- return resp;
8590
- },
 
 
 
8591
 
8592
- // Create a new collection with an identical list of models as this one.
8593
- clone: function() {
8594
- return new this.constructor(this.models, {
8595
- model: this.model,
8596
- comparator: this.comparator
8597
- });
8598
- },
8599
 
8600
- // Define how to uniquely identify models in the collection.
8601
- modelId: function(attrs) {
8602
- return attrs[this.model.prototype.idAttribute || 'id'];
8603
- },
8604
 
8605
- // Private method to reset all internal state. Called when the collection
8606
- // is first initialized or reset.
8607
- _reset: function() {
8608
- this.length = 0;
8609
- this.models = [];
8610
- this._byId = {};
8611
- },
8612
 
8613
- // Prepare a hash of attributes (or other model) to be added to this
8614
- // collection.
8615
- _prepareModel: function(attrs, options) {
8616
- if (this._isModel(attrs)) {
8617
- if (!attrs.collection) attrs.collection = this;
8618
- return attrs;
8619
  }
8620
- options = options ? _.clone(options) : {};
8621
- options.collection = this;
8622
- var model = new this.model(attrs, options);
8623
- if (!model.validationError) return model;
8624
- this.trigger('invalid', this, model.validationError, options);
8625
- return false;
8626
- },
8627
 
8628
- // Internal method called by both remove and set.
8629
- _removeModels: function(models, options) {
8630
- var removed = [];
8631
- for (var i = 0; i < models.length; i++) {
8632
- var model = this.get(models[i]);
8633
- if (!model) continue;
8634
 
8635
- var index = this.indexOf(model);
8636
- this.models.splice(index, 1);
8637
- this.length--;
 
 
 
 
 
 
8638
 
8639
- // Remove references before triggering 'remove' event to prevent an
8640
- // infinite loop. #3693
8641
- delete this._byId[model.cid];
8642
- var id = this.modelId(model.attributes);
8643
- if (id != null) delete this._byId[id];
8644
 
8645
- if (!options.silent) {
8646
- options.index = index;
8647
- model.trigger('remove', model, this, options);
8648
- }
 
 
 
8649
 
8650
- removed.push(model);
8651
- this._removeReference(model, options);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
8652
  }
8653
- return removed;
8654
- },
8655
 
8656
- // Method for checking whether an object should be considered a model for
8657
- // the purposes of adding to the collection.
8658
- _isModel: function(model) {
8659
- return model instanceof Model;
8660
- },
8661
 
8662
- // Internal method to create a model's ties to a collection.
8663
- _addReference: function(model, options) {
8664
- this._byId[model.cid] = model;
8665
- var id = this.modelId(model.attributes);
8666
- if (id != null) this._byId[id] = model;
8667
- model.on('all', this._onModelEvent, this);
8668
- },
 
 
 
 
 
8669
 
8670
- // Internal method to sever a model's ties to a collection.
8671
- _removeReference: function(model, options) {
8672
- delete this._byId[model.cid];
8673
- var id = this.modelId(model.attributes);
8674
- if (id != null) delete this._byId[id];
8675
- if (this === model.collection) delete model.collection;
8676
- model.off('all', this._onModelEvent, this);
8677
- },
8678
 
8679
- // Internal method called every time a model in the set fires an event.
8680
- // Sets need to update their indexes when models change ids. All other
8681
- // events simply proxy through. "add" and "remove" events that originate
8682
- // in other collections are ignored.
8683
- _onModelEvent: function(event, model, collection, options) {
8684
- if (model) {
8685
- if ((event === 'add' || event === 'remove') && collection !== this) return;
8686
- if (event === 'destroy') this.remove(model, options);
8687
- if (event === 'change') {
8688
- var prevId = this.modelId(model.previousAttributes());
8689
- var id = this.modelId(model.attributes);
8690
- if (prevId !== id) {
8691
- if (prevId != null) delete this._byId[prevId];
8692
- if (id != null) this._byId[id] = model;
8693
- }
8694
  }
8695
- }
8696
- this.trigger.apply(this, arguments);
8697
  }
 
 
 
 
 
 
 
 
8698
 
8699
- });
8700
-
8701
- // Underscore methods that we want to implement on the Collection.
8702
- // 90% of the core usefulness of Backbone Collections is actually implemented
8703
- // right here:
8704
- var collectionMethods = {forEach: 3, each: 3, map: 3, collect: 3, reduce: 0,
8705
- foldl: 0, inject: 0, reduceRight: 0, foldr: 0, find: 3, detect: 3, filter: 3,
8706
- select: 3, reject: 3, every: 3, all: 3, some: 3, any: 3, include: 3, includes: 3,
8707
- contains: 3, invoke: 0, max: 3, min: 3, toArray: 1, size: 1, first: 3,
8708
- head: 3, take: 3, initial: 3, rest: 3, tail: 3, drop: 3, last: 3,
8709
- without: 0, difference: 0, indexOf: 3, shuffle: 1, lastIndexOf: 3,
8710
- isEmpty: 1, chain: 1, sample: 3, partition: 3, groupBy: 3, countBy: 3,
8711
- sortBy: 3, indexBy: 3, findIndex: 3, findLastIndex: 3};
8712
 
8713
- // Mix in each Underscore method as a proxy to `Collection#models`.
8714
- addUnderscoreMethods(Collection, collectionMethods, 'models');
8715
 
8716
- // Backbone.View
8717
- // -------------
 
 
 
 
 
8718
 
8719
- // Backbone Views are almost more convention than they are actual code. A View
8720
- // is simply a JavaScript object that represents a logical chunk of UI in the
8721
- // DOM. This might be a single item, an entire list, a sidebar or panel, or
8722
- // even the surrounding frame which wraps your whole app. Defining a chunk of
8723
- // UI as a **View** allows you to define your DOM events declaratively, without
8724
- // having to worry about render order ... and makes it easy for the view to
8725
- // react to specific changes in the state of your models.
8726
 
8727
- // Creating a Backbone.View creates its initial element outside of the DOM,
8728
- // if an existing element is not provided...
8729
- var View = Backbone.View = function(options) {
8730
- this.cid = _.uniqueId('view');
8731
- _.extend(this, _.pick(options, viewOptions));
8732
- this._ensureElement();
8733
- this.initialize.apply(this, arguments);
8734
- };
8735
 
8736
- // Cached regex to split keys for `delegate`.
8737
- var delegateEventSplitter = /^(\S+)\s*(.*)$/;
 
 
8738
 
8739
- // List of view options to be set as properties.
8740
- var viewOptions = ['model', 'collection', 'el', 'id', 'attributes', 'className', 'tagName', 'events'];
 
 
 
 
 
 
8741
 
8742
- // Set up all inheritable **Backbone.View** properties and methods.
8743
- _.extend(View.prototype, Events, {
 
 
 
 
8744
 
8745
- // The default `tagName` of a View's element is `"div"`.
8746
- tagName: 'div',
8747
 
8748
- // jQuery delegate for element lookup, scoped to DOM elements within the
8749
- // current view. This should be preferred to global lookups where possible.
8750
- $: function(selector) {
8751
- return this.$el.find(selector);
8752
- },
 
 
 
 
8753
 
8754
- // Initialize is an empty function by default. Override it with your own
8755
- // initialization logic.
8756
- initialize: function(){},
 
8757
 
8758
- // **render** is the core function that your view should override, in order
8759
- // to populate its element (`this.el`), with the appropriate HTML. The
8760
- // convention is for **render** to always return `this`.
8761
- render: function() {
8762
- return this;
8763
- },
8764
 
8765
- // Remove this view by taking the element out of the DOM, and removing any
8766
- // applicable Backbone.Events listeners.
8767
- remove: function() {
8768
- this._removeElement();
8769
- this.stopListening();
8770
- return this;
8771
- },
8772
 
8773
- // Remove this view's element from the document and all event listeners
8774
- // attached to it. Exposed for subclasses using an alternative DOM
8775
- // manipulation API.
8776
- _removeElement: function() {
8777
- this.$el.remove();
8778
- },
8779
 
8780
- // Change the view's element (`this.el` property) and re-delegate the
8781
- // view's events on the new element.
8782
- setElement: function(element) {
8783
- this.undelegateEvents();
8784
- this._setElement(element);
8785
- this.delegateEvents();
8786
- return this;
8787
- },
8788
 
8789
- // Creates the `this.el` and `this.$el` references for this view using the
8790
- // given `el`. `el` can be a CSS selector or an HTML string, a jQuery
8791
- // context or an element. Subclasses can override this to utilize an
8792
- // alternative DOM manipulation API and are only required to set the
8793
- // `this.el` property.
8794
- _setElement: function(el) {
8795
- this.$el = el instanceof Backbone.$ ? el : Backbone.$(el);
8796
- this.el = this.$el[0];
8797
- },
8798
 
8799
- // Set callbacks, where `this.events` is a hash of
8800
- //
8801
- // *{"event selector": "callback"}*
8802
- //
8803
- // {
8804
- // 'mousedown .title': 'edit',
8805
- // 'click .button': 'save',
8806
- // 'click .open': function(e) { ... }
8807
- // }
8808
- //
8809
- // pairs. Callbacks will be bound to the view, with `this` set properly.
8810
- // Uses event delegation for efficiency.
8811
- // Omitting the selector binds the event to `this.el`.
8812
- delegateEvents: function(events) {
8813
- events || (events = _.result(this, 'events'));
8814
- if (!events) return this;
8815
- this.undelegateEvents();
8816
- for (var key in events) {
8817
- var method = events[key];
8818
- if (!_.isFunction(method)) method = this[method];
8819
- if (!method) continue;
8820
- var match = key.match(delegateEventSplitter);
8821
- this.delegate(match[1], match[2], _.bind(method, this));
8822
- }
8823
- return this;
8824
- },
8825
 
8826
- // Add a single event listener to the view's element (or a child element
8827
- // using `selector`). This only works for delegate-able events: not `focus`,
8828
- // `blur`, and not `change`, `submit`, and `reset` in Internet Explorer.
8829
- delegate: function(eventName, selector, listener) {
8830
- this.$el.on(eventName + '.delegateEvents' + this.cid, selector, listener);
8831
- return this;
8832
- },
 
 
 
 
 
8833
 
8834
- // Clears all callbacks previously bound to the view by `delegateEvents`.
8835
- // You usually don't need to use this, but may wish to if you have multiple
8836
- // Backbone views attached to the same DOM element.
8837
- undelegateEvents: function() {
8838
- if (this.$el) this.$el.off('.delegateEvents' + this.cid);
8839
- return this;
8840
- },
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
8841
 
8842
- // A finer-grained `undelegateEvents` for removing a single delegated event.
8843
- // `selector` and `listener` are both optional.
8844
- undelegate: function(eventName, selector, listener) {
8845
- this.$el.off(eventName + '.delegateEvents' + this.cid, selector, listener);
8846
- return this;
8847
- },
 
 
 
 
 
 
 
 
 
 
 
 
 
 
8848
 
8849
- // Produces a DOM element to be assigned to your view. Exposed for
8850
- // subclasses using an alternative DOM manipulation API.
8851
- _createElement: function(tagName) {
8852
- return document.createElement(tagName);
8853
- },
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
8854
 
8855
- // Ensure that the View has a DOM element to render into.
8856
- // If `this.el` is a string, pass it through `$()`, take the first
8857
- // matching element, and re-assign it to `el`. Otherwise, create
8858
- // an element from the `id`, `className` and `tagName` properties.
8859
- _ensureElement: function() {
8860
- if (!this.el) {
8861
- var attrs = _.extend({}, _.result(this, 'attributes'));
8862
- if (this.id) attrs.id = _.result(this, 'id');
8863
- if (this.className) attrs['class'] = _.result(this, 'className');
8864
- this.setElement(this._createElement(_.result(this, 'tagName')));
8865
- this._setAttributes(attrs);
8866
- } else {
8867
- this.setElement(_.result(this, 'el'));
8868
- }
8869
- },
 
8870
 
8871
- // Set attributes from a hash on this view's element. Exposed for
8872
- // subclasses using an alternative DOM manipulation API.
8873
- _setAttributes: function(attributes) {
8874
- this.$el.attr(attributes);
8875
- }
 
 
 
 
 
 
 
 
 
8876
 
8877
- });
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
8878
 
8879
- // Backbone.sync
8880
- // -------------
 
8881
 
8882
- // Override this function to change the manner in which Backbone persists
8883
- // models to the server. You will be passed the type of request, and the
8884
- // model in question. By default, makes a RESTful Ajax request
8885
- // to the model's `url()`. Some possible customizations could be:
8886
- //
8887
- // * Use `setTimeout` to batch rapid-fire updates into a single request.
8888
- // * Send up the models as XML instead of JSON.
8889
- // * Persist models via WebSockets instead of Ajax.
8890
- //
8891
- // Turn on `Backbone.emulateHTTP` in order to send `PUT` and `DELETE` requests
8892
- // as `POST`, with a `_method` parameter containing the true HTTP method,
8893
- // as well as all requests with the body as `application/x-www-form-urlencoded`
8894
- // instead of `application/json` with the model in a param named `model`.
8895
- // Useful when interfacing with server-side languages like **PHP** that make
8896
- // it difficult to read the body of `PUT` requests.
8897
- Backbone.sync = function(method, model, options) {
8898
- var type = methodMap[method];
8899
 
8900
- // Default options, unless specified.
8901
- _.defaults(options || (options = {}), {
8902
- emulateHTTP: Backbone.emulateHTTP,
8903
- emulateJSON: Backbone.emulateJSON
8904
- });
 
 
8905
 
8906
- // Default JSON-request options.
8907
- var params = {type: type, dataType: 'json'};
8908
 
8909
- // Ensure that we have a URL.
8910
- if (!options.url) {
8911
- params.url = _.result(model, 'url') || urlError();
8912
- }
8913
 
8914
- // Ensure that we have the appropriate request data.
8915
- if (options.data == null && model && (method === 'create' || method === 'update' || method === 'patch')) {
8916
- params.contentType = 'application/json';
8917
- params.data = JSON.stringify(options.attrs || model.toJSON(options));
8918
- }
 
8919
 
8920
- // For older servers, emulate JSON by encoding the request into an HTML-form.
8921
- if (options.emulateJSON) {
8922
- params.contentType = 'application/x-www-form-urlencoded';
8923
- params.data = params.data ? {model: params.data} : {};
8924
- }
8925
 
8926
- // For older servers, emulate HTTP by mimicking the HTTP method with `_method`
8927
- // And an `X-HTTP-Method-Override` header.
8928
- if (options.emulateHTTP && (type === 'PUT' || type === 'DELETE' || type === 'PATCH')) {
8929
- params.type = 'POST';
8930
- if (options.emulateJSON) params.data._method = type;
8931
- var beforeSend = options.beforeSend;
8932
- options.beforeSend = function(xhr) {
8933
- xhr.setRequestHeader('X-HTTP-Method-Override', type);
8934
- if (beforeSend) return beforeSend.apply(this, arguments);
8935
- };
8936
- }
8937
 
8938
- // Don't process data on a non-GET request.
8939
- if (params.type !== 'GET' && !options.emulateJSON) {
8940
- params.processData = false;
8941
- }
8942
 
8943
- // Pass along `textStatus` and `errorThrown` from jQuery.
8944
- var error = options.error;
8945
- options.error = function(xhr, textStatus, errorThrown) {
8946
- options.textStatus = textStatus;
8947
- options.errorThrown = errorThrown;
8948
- if (error) error.call(options.context, xhr, textStatus, errorThrown);
8949
- };
8950
 
8951
- // Make the request, allowing the user to override any Ajax options.
8952
- var xhr = options.xhr = Backbone.ajax(_.extend(params, options));
8953
- model.trigger('request', model, xhr, options);
8954
- return xhr;
8955
- };
8956
 
8957
- // Map from CRUD to HTTP for our default `Backbone.sync` implementation.
8958
- var methodMap = {
8959
- 'create': 'POST',
8960
- 'update': 'PUT',
8961
- 'patch': 'PATCH',
8962
- 'delete': 'DELETE',
8963
- 'read': 'GET'
8964
- };
8965
 
8966
- // Set the default implementation of `Backbone.ajax` to proxy through to `$`.
8967
- // Override this if you'd like to use a different library.
8968
- Backbone.ajax = function() {
8969
- return Backbone.$.ajax.apply(Backbone.$, arguments);
8970
- };
8971
 
8972
- // Backbone.Router
8973
- // ---------------
8974
 
8975
- // Routers map faux-URLs to actions, and fire events when routes are
8976
- // matched. Creating a new one sets its `routes` hash, if not set statically.
8977
- var Router = Backbone.Router = function(options) {
8978
- options || (options = {});
8979
- if (options.routes) this.routes = options.routes;
8980
- this._bindRoutes();
8981
- this.initialize.apply(this, arguments);
8982
- };
8983
 
8984
- // Cached regular expressions for matching named param parts and splatted
8985
- // parts of route strings.
8986
- var optionalParam = /\((.*?)\)/g;
8987
- var namedParam = /(\(\?)?:\w+/g;
8988
- var splatParam = /\*\w+/g;
8989
- var escapeRegExp = /[\-{}\[\]+?.,\\\^$|#\s]/g;
8990
 
8991
- // Set up all inheritable **Backbone.Router** properties and methods.
8992
- _.extend(Router.prototype, Events, {
8993
 
8994
- // Initialize is an empty function by default. Override it with your own
8995
- // initialization logic.
8996
- initialize: function(){},
8997
 
8998
- // Manually bind a single named route to a callback. For example:
8999
- //
9000
- // this.route('search/:query/p:num', 'search', function(query, num) {
9001
- // ...
9002
- // });
9003
- //
9004
- route: function(route, name, callback) {
9005
- if (!_.isRegExp(route)) route = this._routeToRegExp(route);
9006
- if (_.isFunction(name)) {
9007
- callback = name;
9008
- name = '';
9009
- }
9010
- if (!callback) callback = this[name];
9011
- var router = this;
9012
- Backbone.history.route(route, function(fragment) {
9013
- var args = router._extractParameters(route, fragment);
9014
- if (router.execute(callback, args, name) !== false) {
9015
- router.trigger.apply(router, ['route:' + name].concat(args));
9016
- router.trigger('route', name, args);
9017
- Backbone.history.trigger('route', router, name, args);
9018
- }
9019
- });
9020
- return this;
9021
- },
9022
 
9023
- // Execute a route handler with the provided parameters. This is an
9024
- // excellent place to do pre-route setup or post-route cleanup.
9025
- execute: function(callback, args, name) {
9026
- if (callback) callback.apply(this, args);
9027
- },
9028
 
9029
- // Simple proxy to `Backbone.history` to save a fragment into the history.
9030
- navigate: function(fragment, options) {
9031
- Backbone.history.navigate(fragment, options);
9032
- return this;
9033
- },
9034
-
9035
- // Bind all defined routes to `Backbone.history`. We have to reverse the
9036
- // order of the routes here to support behavior where the most general
9037
- // routes can be defined at the bottom of the route map.
9038
- _bindRoutes: function() {
9039
- if (!this.routes) return;
9040
- this.routes = _.result(this, 'routes');
9041
- var route, routes = _.keys(this.routes);
9042
- while ((route = routes.pop()) != null) {
9043
- this.route(route, this.routes[route]);
9044
- }
9045
- },
9046
-
9047
- // Convert a route string into a regular expression, suitable for matching
9048
- // against the current location hash.
9049
- _routeToRegExp: function(route) {
9050
- route = route.replace(escapeRegExp, '\\$&')
9051
- .replace(optionalParam, '(?:$1)?')
9052
- .replace(namedParam, function(match, optional) {
9053
- return optional ? match : '([^/?]+)';
9054
- })
9055
- .replace(splatParam, '([^?]*?)');
9056
- return new RegExp('^' + route + '(?:\\?([\\s\\S]*))?$');
9057
- },
9058
-
9059
- // Given a route, and a URL fragment that it matches, return the array of
9060
- // extracted decoded parameters. Empty or unmatched parameters will be
9061
- // treated as `null` to normalize cross-browser behavior.
9062
- _extractParameters: function(route, fragment) {
9063
- var params = route.exec(fragment).slice(1);
9064
- return _.map(params, function(param, i) {
9065
- // Don't decode the search params.
9066
- if (i === params.length - 1) return param || null;
9067
- return param ? decodeURIComponent(param) : null;
9068
- });
9069
- }
9070
-
9071
- });
9072
-
9073
- // Backbone.History
9074
- // ----------------
9075
-
9076
- // Handles cross-browser history management, based on either
9077
- // [pushState](http://diveintohtml5.info/history.html) and real URLs, or
9078
- // [onhashchange](https://developer.mozilla.org/en-US/docs/DOM/window.onhashchange)
9079
- // and URL fragments. If the browser supports neither (old IE, natch),
9080
- // falls back to polling.
9081
- var History = Backbone.History = function() {
9082
- this.handlers = [];
9083
- this.checkUrl = _.bind(this.checkUrl, this);
9084
-
9085
- // Ensure that `History` can be used outside of the browser.
9086
- if (typeof window !== 'undefined') {
9087
- this.location = window.location;
9088
- this.history = window.history;
9089
- }
9090
- };
9091
-
9092
- // Cached regex for stripping a leading hash/slash and trailing space.
9093
- var routeStripper = /^[#\/]|\s+$/g;
9094
-
9095
- // Cached regex for stripping leading and trailing slashes.
9096
- var rootStripper = /^\/+|\/+$/g;
9097
-
9098
- // Cached regex for stripping urls of hash.
9099
- var pathStripper = /#.*$/;
9100
-
9101
- // Has the history handling already been started?
9102
- History.started = false;
9103
 
9104
- // Set up all inheritable **Backbone.History** properties and methods.
9105
- _.extend(History.prototype, Events, {
9106
 
9107
- // The default interval to poll for hash changes, if necessary, is
9108
- // twenty times a second.
9109
- interval: 50,
9110
 
9111
- // Are we at the app root?
9112
- atRoot: function() {
9113
- var path = this.location.pathname.replace(/[^\/]$/, '$&/');
9114
- return path === this.root && !this.getSearch();
9115
- },
9116
 
9117
- // Does the pathname match the root?
9118
- matchRoot: function() {
9119
- var path = this.decodeFragment(this.location.pathname);
9120
- var rootPath = path.slice(0, this.root.length - 1) + '/';
9121
- return rootPath === this.root;
9122
- },
 
9123
 
9124
- // Unicode characters in `location.pathname` are percent encoded so they're
9125
- // decoded for comparison. `%25` should not be decoded since it may be part
9126
- // of an encoded parameter.
9127
- decodeFragment: function(fragment) {
9128
- return decodeURI(fragment.replace(/%25/g, '%2525'));
9129
- },
9130
 
9131
- // In IE6, the hash fragment and search params are incorrect if the
9132
- // fragment contains `?`.
9133
- getSearch: function() {
9134
- var match = this.location.href.replace(/#.*/, '').match(/\?.+/);
9135
- return match ? match[0] : '';
9136
- },
9137
 
9138
- // Gets the true hash value. Cannot use location.hash directly due to bug
9139
- // in Firefox where location.hash will always be decoded.
9140
- getHash: function(window) {
9141
- var match = (window || this).location.href.match(/#(.*)$/);
9142
- return match ? match[1] : '';
9143
- },
9144
 
9145
- // Get the pathname and search params, without the root.
9146
- getPath: function() {
9147
- var path = this.decodeFragment(
9148
- this.location.pathname + this.getSearch()
9149
- ).slice(this.root.length - 1);
9150
- return path.charAt(0) === '/' ? path.slice(1) : path;
9151
- },
9152
 
9153
- // Get the cross-browser normalized URL fragment from the path or hash.
9154
- getFragment: function(fragment) {
9155
- if (fragment == null) {
9156
- if (this._usePushState || !this._wantsHashChange) {
9157
- fragment = this.getPath();
9158
- } else {
9159
- fragment = this.getHash();
9160
- }
9161
- }
9162
- return fragment.replace(routeStripper, '');
9163
- },
9164
 
9165
- // Start the hash change handling, returning `true` if the current URL matches
9166
- // an existing route, and `false` otherwise.
9167
- start: function(options) {
9168
- if (History.started) throw new Error('Backbone.history has already been started');
9169
- History.started = true;
 
9170
 
9171
- // Figure out the initial configuration. Do we need an iframe?
9172
- // Is pushState desired ... is it available?
9173
- this.options = _.extend({root: '/'}, this.options, options);
9174
- this.root = this.options.root;
9175
- this._wantsHashChange = this.options.hashChange !== false;
9176
- this._hasHashChange = 'onhashchange' in window && (document.documentMode === void 0 || document.documentMode > 7);
9177
- this._useHashChange = this._wantsHashChange && this._hasHashChange;
9178
- this._wantsPushState = !!this.options.pushState;
9179
- this._hasPushState = !!(this.history && this.history.pushState);
9180
- this._usePushState = this._wantsPushState && this._hasPushState;
9181
- this.fragment = this.getFragment();
9182
 
9183
- // Normalize root to always include a leading and trailing slash.
9184
- this.root = ('/' + this.root + '/').replace(rootStripper, '/');
9185
 
9186
- // Transition from hashChange to pushState or vice versa if both are
9187
- // requested.
9188
- if (this._wantsHashChange && this._wantsPushState) {
9189
 
9190
- // If we've started off with a route from a `pushState`-enabled
9191
- // browser, but we're currently in a browser that doesn't support it...
9192
- if (!this._hasPushState && !this.atRoot()) {
9193
- var rootPath = this.root.slice(0, -1) || '/';
9194
- this.location.replace(rootPath + '#' + this.getPath());
9195
- // Return immediately as browser will do redirect to new url
9196
- return true;
 
 
 
 
 
 
 
9197
 
9198
- // Or if we've started out with a hash-based route, but we're currently
9199
- // in a browser where it could be `pushState`-based instead...
9200
- } else if (this._hasPushState && this.atRoot()) {
9201
- this.navigate(this.getHash(), {replace: true});
9202
- }
 
9203
 
9204
- }
 
9205
 
9206
- // Proxy an iframe to handle location events if the browser doesn't
9207
- // support the `hashchange` event, HTML5 history, or the user wants
9208
- // `hashChange` but not `pushState`.
9209
- if (!this._hasHashChange && this._wantsHashChange && !this._usePushState) {
9210
- this.iframe = document.createElement('iframe');
9211
- this.iframe.src = 'javascript:0';
9212
- this.iframe.style.display = 'none';
9213
- this.iframe.tabIndex = -1;
9214
- var body = document.body;
9215
- // Using `appendChild` will throw on IE < 9 if the document is not ready.
9216
- var iWindow = body.insertBefore(this.iframe, body.firstChild).contentWindow;
9217
- iWindow.document.open();
9218
- iWindow.document.close();
9219
- iWindow.location.hash = '#' + this.fragment;
9220
- }
9221
 
9222
- // Add a cross-platform `addEventListener` shim for older browsers.
9223
- var addEventListener = window.addEventListener || function(eventName, listener) {
9224
- return attachEvent('on' + eventName, listener);
9225
- };
 
 
 
 
 
 
 
 
 
 
 
 
 
9226
 
9227
- // Depending on whether we're using pushState or hashes, and whether
9228
- // 'onhashchange' is supported, determine how we check the URL state.
9229
- if (this._usePushState) {
9230
- addEventListener('popstate', this.checkUrl, false);
9231
- } else if (this._useHashChange && !this.iframe) {
9232
- addEventListener('hashchange', this.checkUrl, false);
9233
- } else if (this._wantsHashChange) {
9234
- this._checkUrlInterval = setInterval(this.checkUrl, this.interval);
9235
- }
 
 
 
 
 
 
9236
 
9237
- if (!this.options.silent) return this.loadUrl();
9238
- },
9239
 
9240
- // Disable Backbone.history, perhaps temporarily. Not useful in a real app,
9241
- // but possibly useful for unit testing Routers.
9242
- stop: function() {
9243
- // Add a cross-platform `removeEventListener` shim for older browsers.
9244
- var removeEventListener = window.removeEventListener || function(eventName, listener) {
9245
- return detachEvent('on' + eventName, listener);
9246
- };
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9247
 
9248
- // Remove window listeners.
9249
- if (this._usePushState) {
9250
- removeEventListener('popstate', this.checkUrl, false);
9251
- } else if (this._useHashChange && !this.iframe) {
9252
- removeEventListener('hashchange', this.checkUrl, false);
9253
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9254
 
9255
- // Clean up the iframe if necessary.
9256
- if (this.iframe) {
9257
- document.body.removeChild(this.iframe);
9258
- this.iframe = null;
9259
- }
9260
 
9261
- // Some environments will throw when clearing an undefined interval.
9262
- if (this._checkUrlInterval) clearInterval(this._checkUrlInterval);
9263
- History.started = false;
9264
- },
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9265
 
9266
- // Add a route to be tested when the fragment changes. Routes added later
9267
- // may override previous routes.
9268
- route: function(route, callback) {
9269
- this.handlers.unshift({route: route, callback: callback});
9270
- },
9271
-
9272
- // Checks the current URL to see if it has changed, and if it has,
9273
- // calls `loadUrl`, normalizing across the hidden iframe.
9274
- checkUrl: function(e) {
9275
- var current = this.getFragment();
9276
-
9277
- // If the user pressed the back button, the iframe's hash will have
9278
- // changed and we should use that for comparison.
9279
- if (current === this.fragment && this.iframe) {
9280
- current = this.getHash(this.iframe.contentWindow);
9281
- }
9282
-
9283
- if (current === this.fragment) return false;
9284
- if (this.iframe) this.navigate(current);
9285
- this.loadUrl();
9286
- },
9287
-
9288
- // Attempt to load the current URL fragment. If a route succeeds with a
9289
- // match, returns `true`. If no defined routes matches the fragment,
9290
- // returns `false`.
9291
- loadUrl: function(fragment) {
9292
- // If the root doesn't match, no routes can match either.
9293
- if (!this.matchRoot()) return false;
9294
- fragment = this.fragment = this.getFragment(fragment);
9295
- return _.some(this.handlers, function(handler) {
9296
- if (handler.route.test(fragment)) {
9297
- handler.callback(fragment);
9298
- return true;
9299
- }
9300
- });
9301
- },
9302
-
9303
- // Save a fragment into the hash history, or replace the URL state if the
9304
- // 'replace' option is passed. You are responsible for properly URL-encoding
9305
- // the fragment in advance.
9306
- //
9307
- // The options object can contain `trigger: true` if you wish to have the
9308
- // route callback be fired (not usually desirable), or `replace: true`, if
9309
- // you wish to modify the current URL without adding an entry to the history.
9310
- navigate: function(fragment, options) {
9311
- if (!History.started) return false;
9312
- if (!options || options === true) options = {trigger: !!options};
9313
-
9314
- // Normalize the fragment.
9315
- fragment = this.getFragment(fragment || '');
9316
-
9317
- // Don't include a trailing slash on the root.
9318
- var rootPath = this.root;
9319
- if (fragment === '' || fragment.charAt(0) === '?') {
9320
- rootPath = rootPath.slice(0, -1) || '/';
9321
- }
9322
- var url = rootPath + fragment;
9323
-
9324
- // Strip the hash and decode for matching.
9325
- fragment = this.decodeFragment(fragment.replace(pathStripper, ''));
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9326
 
9327
- if (this.fragment === fragment) return;
9328
- this.fragment = fragment;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9329
 
9330
- // If pushState is available, we use it to set the fragment as a real URL.
9331
- if (this._usePushState) {
9332
- this.history[options.replace ? 'replaceState' : 'pushState']({}, document.title, url);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9333
 
9334
- // If hash changes haven't been explicitly disabled, update the hash
9335
- // fragment to store history.
9336
- } else if (this._wantsHashChange) {
9337
- this._updateHash(this.location, fragment, options.replace);
9338
- if (this.iframe && fragment !== this.getHash(this.iframe.contentWindow)) {
9339
- var iWindow = this.iframe.contentWindow;
9340
-
9341
- // Opening and closing the iframe tricks IE7 and earlier to push a
9342
- // history entry on hash-tag change. When replace is true, we don't
9343
- // want this.
9344
- if (!options.replace) {
9345
- iWindow.document.open();
9346
- iWindow.document.close();
9347
- }
9348
-
9349
- this._updateHash(iWindow.location, fragment, options.replace);
9350
- }
9351
-
9352
- // If you've told us that you explicitly don't want fallback hashchange-
9353
- // based history, then `navigate` becomes a page refresh.
9354
- } else {
9355
- return this.location.assign(url);
9356
- }
9357
- if (options.trigger) return this.loadUrl(fragment);
9358
- },
9359
-
9360
- // Update the hash location, either replacing the current entry, or adding
9361
- // a new one to the browser history.
9362
- _updateHash: function(location, fragment, replace) {
9363
- if (replace) {
9364
- var href = location.href.replace(/(javascript:|#).*$/, '');
9365
- location.replace(href + '#' + fragment);
9366
- } else {
9367
- // Some browsers require that `hash` contains a leading #.
9368
- location.hash = '#' + fragment;
9369
- }
9370
- }
9371
-
9372
- });
9373
-
9374
- // Create the default Backbone.history.
9375
- Backbone.history = new History;
9376
-
9377
- // Helpers
9378
- // -------
9379
-
9380
- // Helper function to correctly set up the prototype chain for subclasses.
9381
- // Similar to `goog.inherits`, but uses a hash of prototype properties and
9382
- // class properties to be extended.
9383
- var extend = function(protoProps, staticProps) {
9384
- var parent = this;
9385
- var child;
9386
-
9387
- // The constructor function for the new subclass is either defined by you
9388
- // (the "constructor" property in your `extend` definition), or defaulted
9389
- // by us to simply call the parent constructor.
9390
- if (protoProps && _.has(protoProps, 'constructor')) {
9391
- child = protoProps.constructor;
9392
- } else {
9393
- child = function(){ return parent.apply(this, arguments); };
9394
- }
9395
-
9396
- // Add static properties to the constructor function, if supplied.
9397
- _.extend(child, parent, staticProps);
9398
-
9399
- // Set the prototype chain to inherit from `parent`, without calling
9400
- // `parent`'s constructor function and add the prototype properties.
9401
- child.prototype = _.create(parent.prototype, protoProps);
9402
- child.prototype.constructor = child;
9403
-
9404
- // Set a convenience property in case the parent's prototype is needed
9405
- // later.
9406
- child.__super__ = parent.prototype;
9407
-
9408
- return child;
9409
- };
9410
-
9411
- // Set up inheritance for the model, collection, router, view and history.
9412
- Model.extend = Collection.extend = Router.extend = View.extend = History.extend = extend;
9413
-
9414
- // Throw an error when a URL is needed, and none is supplied.
9415
- var urlError = function() {
9416
- throw new Error('A "url" property or function must be specified');
9417
- };
9418
-
9419
- // Wrap an optional error callback with a fallback error event.
9420
- var wrapError = function(model, options) {
9421
- var error = options.error;
9422
- options.error = function(resp) {
9423
- if (error) error.call(options.context, model, resp, options);
9424
- model.trigger('error', model, resp, options);
9425
- };
9426
- };
9427
 
9428
- return Backbone;
9429
- });
 
 
 
 
 
 
 
 
 
 
 
 
 
9430
 
9431
- /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9432
 
9433
- /***/ },
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9434
 
9435
- /***/ 562:
9436
- /***/ function(module, exports, __webpack_require__) {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9437
 
9438
- var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;function requestFailed(errorMessage, xhr) {
9439
- if (xhr.responseJSON) {
9440
- return xhr.responseJSON;
9441
- }
9442
- return {
9443
- errors: [
9444
- {
9445
- message: errorMessage.replace('%d', xhr.status)
9446
- }
9447
- ]
9448
- };
9449
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9450
 
9451
- !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(276), __webpack_require__(275), __webpack_require__(280)], __WEBPACK_AMD_DEFINE_RESULT__ = function ajax(mp, jQuery, _) {
9452
- var MailPoet = mp;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9453
 
9454
- MailPoet.Ajax = {
9455
- version: 0.5,
9456
- options: {},
9457
- defaults: {
9458
- url: null,
9459
- api_version: null,
9460
- endpoint: null,
9461
- action: null,
9462
- token: null,
9463
- data: {}
9464
- },
9465
- post: function post(options) {
9466
- return this.request('post', options);
9467
- },
9468
- init: function init(options) {
9469
- // merge options
9470
- this.options = jQuery.extend({}, this.defaults, options);
9471
 
9472
- // set default url
9473
- if (this.options.url === null) {
9474
- this.options.url = window.ajaxurl;
9475
- }
9476
-
9477
- // set default token
9478
- if (this.options.token === null) {
9479
- this.options.token = window.mailpoet_token;
9480
- }
9481
- },
9482
- getParams: function getParams() {
9483
- return {
9484
- action: 'mailpoet',
9485
- api_version: this.options.api_version,
9486
- token: this.options.token,
9487
- endpoint: this.options.endpoint,
9488
- method: this.options.action,
9489
- data: this.options.data || {}
9490
- };
9491
- },
9492
- request: function request(method, options) {
9493
- var params;
9494
- var deferred;
9495
- // set options
9496
- this.init(options);
9497
-
9498
- // set request params
9499
- params = this.getParams();
9500
-
9501
- // remove null values from the data object
9502
- if (_.isObject(params.data)) {
9503
- params.data = _.pick(params.data, function isNotNull(value) {
9504
- return (value !== null);
9505
- });
9506
- }
9507
-
9508
- // ajax request
9509
- deferred = jQuery.post(
9510
- this.options.url,
9511
- params,
9512
- null,
9513
- 'json'
9514
- ).then(function resultHandler(data) {
9515
- return data;
9516
- }, _.partial(requestFailed, MailPoet.I18n.t('ajaxFailedErrorMessage')));
9517
-
9518
- // clear options
9519
- this.options = {};
9520
-
9521
- return deferred;
9522
- }
9523
- };
9524
- }.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
9525
-
9526
-
9527
- /***/ },
9528
-
9529
- /***/ 565:
9530
- /***/ function(module, exports, __webpack_require__) {
9531
-
9532
- var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/* eslint-disable func-names */
9533
- !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(276), __webpack_require__(275)], __WEBPACK_AMD_DEFINE_RESULT__ = function (mp, jQuery) {
9534
- 'use strict';
9535
-
9536
- var MailPoet = mp;
9537
- /** *************************************************************************
9538
- MailPoet Modal:
9539
-
9540
- version: 0.9
9541
- author: Jonathan Labreuille
9542
- company: Wysija
9543
- dependencies: jQuery
9544
-
9545
- Usage:
9546
- // popup mode
9547
- MailPoet.Modal.popup(options);
9548
-
9549
- // panel mode
9550
- MailPoet.Modal.panel(options);
9551
-
9552
- // loading mode
9553
- MailPoet.Modal.loading(bool);
9554
- ************************************************************************** */
9555
-
9556
- MailPoet.Modal = {
9557
- version: 0.9,
9558
-
9559
- // flags
9560
- initialized: false,
9561
- opened: false,
9562
- locked: false,
9563
-
9564
- // previously focused element
9565
- prevFocus: null,
9566
-
9567
- // sub panels
9568
- subpanels: [],
9569
-
9570
- // default values
9571
- defaults: {
9572
- // title
9573
- title: null,
9574
-
9575
- // type
9576
- type: null,
9577
-
9578
- // positionning
9579
- position: 'right',
9580
-
9581
- // data sources
9582
- data: {},
9583
- url: null,
9584
- method: 'get',
9585
- params: {},
9586
-
9587
- // template
9588
- template: null,
9589
- body_template: null,
9590
-
9591
- // dimensions
9592
- width: 'auto',
9593
- height: 'auto',
9594
-
9595
- // display overlay
9596
- overlay: false,
9597
-
9598
- // focus upon displaying
9599
- focus: true,
9600
-
9601
- // highlighted elements
9602
- highlight: null,
9603
-
9604
- // callbacks
9605
- onInit: null,
9606
- onSuccess: null,
9607
- onCancel: null
9608
- },
9609
- renderer: 'html',
9610
- options: {},
9611
- templates: {
9612
- overlay: '<div id="mailpoet_modal_overlay" style="display:none;"></div>',
9613
- popup: '<div id="mailpoet_popup" tabindex="-1">' +
9614
- '<div class="mailpoet_popup_wrapper">' +
9615
- '<a href="javascript:;" id="mailpoet_modal_close"></a>' +
9616
- '<div id="mailpoet_popup_title"><h2></h2></div>' +
9617
- '<div class="mailpoet_popup_body clearfix"></div>' +
9618
- '</div>' +
9619
- '</div>',
9620
- loading: '<div id="mailpoet_loading" style="display:none;">' +
9621
- '<div id="mailpoet_modal_loading_1" class="mailpoet_modal_loading"></div>' +
9622
- '<div id="mailpoet_modal_loading_2" class="mailpoet_modal_loading"></div>' +
9623
- '<div id="mailpoet_modal_loading_3" class="mailpoet_modal_loading"></div>' +
9624
- '</div>',
9625
- panel: '<div id="mailpoet_panel">' +
9626
- '<a href="javascript:;" id="mailpoet_modal_close"></a>' +
9627
- '<div class="mailpoet_panel_wrapper" tabindex="-1">' +
9628
- '<div class="mailpoet_panel_body clearfix"></div>' +
9629
- '</div>' +
9630
- '</div>',
9631
- subpanel: '<div class="mailpoet_panel_wrapper" tabindex="-1">' +
9632
- '<div class="mailpoet_panel_body clearfix"></div>' +
9633
- '</div>'
9634
- },
9635
- getContentContainer: function () {
9636
- return jQuery('.mailpoet_' + this.options.type + '_body');
9637
- },
9638
- setRenderer: function (renderer) {
9639
- this.renderer = renderer;
9640
- return this;
9641
- },
9642
- compileTemplate: function (template) {
9643
- if (this.renderer === 'html') {
9644
- return function () { return template; };
9645
- }
9646
- return window.Handlebars.compile(template);
9647
- },
9648
- init: function (options) {
9649
- var modal;
9650
- if (this.initialized === true) {
9651
- this.close();
9652
- }
9653
- // merge options
9654
- this.options = jQuery.extend({}, this.defaults, options);
9655
-
9656
- // set renderer
9657
- this.setRenderer(this.options.renderer);
9658
-
9659
- // init overlay
9660
- this.initOverlay();
9661
-
9662
- // toggle overlay
9663
- this.toggleOverlay(this.options.overlay);
9664
-
9665
- if (this.options.type !== null) {
9666
- // insert modal depending on its type
9667
- if (this.options.type === 'popup') {
9668
- modal = this.compileTemplate(
9669
- this.templates[this.options.type]
9670
- );
9671
- // create modal
9672
- jQuery('#mailpoet_modal_overlay')
9673
- .append(modal(this.options));
9674
- // set title
9675
- jQuery('#mailpoet_popup_title h2')
9676
- .html(this.options.title);
9677
- } else if (this.options.type === 'panel') {
9678
- // create panel
9679
- jQuery('#mailpoet_modal_overlay')
9680
- .after(this.templates[this.options.type]);
9681
- }
9682
-
9683
- // add proper overlay class
9684
- jQuery('#mailpoet_modal_overlay')
9685
- .removeClass('mailpoet_popup_overlay mailpoet_panel_overlay')
9686
- .addClass('mailpoet_' + this.options.type + '_overlay');
9687
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9688
 
9689
- // set "success" callback if specified
9690
- if (options.onSuccess !== undefined) {
9691
- this.options.onSuccess = options.onSuccess;
9692
- }
9693
-
9694
- // set "cancel" callback if specified
9695
- if (options.onCancel !== undefined) {
9696
- this.options.onCancel = options.onCancel;
9697
- }
9698
-
9699
- // compile template
9700
- this.options.body_template = this.compileTemplate(
9701
- this.options.template
9702
- );
9703
-
9704
- // setup events
9705
- this.setupEvents();
9706
-
9707
- // set popup as initialized
9708
- this.initialized = true;
9709
-
9710
- return this;
9711
- },
9712
- initOverlay: function () {
9713
- if (jQuery('#mailpoet_modal_overlay').length === 0) {
9714
- // insert overlay into the DOM
9715
- jQuery('body').append(this.templates.overlay);
9716
- // insert loading indicator into overlay
9717
- jQuery('#mailpoet_modal_overlay').append(this.templates.loading);
9718
- }
9719
- return this;
9720
- },
9721
- toggleOverlay: function (toggle) {
9722
- if (toggle === true) {
9723
- jQuery('#mailpoet_modal_overlay')
9724
- .removeClass('mailpoet_overlay_hidden');
9725
- } else {
9726
- jQuery('#mailpoet_modal_overlay')
9727
- .addClass('mailpoet_overlay_hidden');
9728
- }
9729
-
9730
- return this;
9731
- },
9732
- setupEvents: function () {
9733
- // close popup when user clicks on close button
9734
- jQuery('#mailpoet_modal_close').on('click', this.cancel.bind(this));
9735
-
9736
- // close popup when user clicks on overlay
9737
- jQuery('#mailpoet_modal_overlay').on('click', function (e) {
9738
- // we need to make sure that we are actually clicking on the overlay
9739
- // because when clicking on the popup content, it will trigger
9740
- // the click event on the overlay
9741
- if (e.target.id === 'mailpoet_modal_overlay') { this.cancel(); }
9742
- }.bind(this));
9743
-
9744
- // close popup when user presses ESC key
9745
- jQuery(document).on('keyup.mailpoet_modal', function (e) {
9746
- if (this.opened === false) { return false; }
9747
- if (e.keyCode === 27) { this.cancel(); }
9748
- return true;
9749
- }.bind(this));
9750
-
9751
- // make sure the popup is repositioned when the window is resized
9752
- jQuery(window).on('resize.mailpoet_modal', function () {
9753
- this.setPosition();
9754
- }.bind(this));
9755
-
9756
- return this;
9757
- },
9758
- removeEvents: function () {
9759
- jQuery(document).unbind('keyup.mailpoet_modal');
9760
- jQuery(window).unbind('resize.mailpoet_modal');
9761
- jQuery('#mailpoet_modal_close').off('click');
9762
- if (this.options.overlay === true) {
9763
- jQuery('#mailpoet_modal_overlay').off('click');
9764
- }
9765
-
9766
- return this;
9767
- },
9768
- lock: function () {
9769
- this.locked = true;
9770
-
9771
- return this;
9772
- },
9773
- unlock: function () {
9774
- this.locked = false;
9775
-
9776
- return this;
9777
- },
9778
- isLocked: function () {
9779
- return this.locked;
9780
- },
9781
- loadTemplate: function () {
9782
- if (this.subpanels.length > 0) {
9783
- // hide panel
9784
- jQuery('.mailpoet_' + this.options.type + '_wrapper').hide();
9785
-
9786
- // add sub panel wrapper
9787
- jQuery('#mailpoet_' + this.options.type)
9788
- .append(this.templates.subpanel);
9789
-
9790
- // add sub panel content
9791
- jQuery('.mailpoet_' + this.options.type + '_body').last()
9792
- .html(this.subpanels[(this.subpanels.length - 1)].element);
9793
-
9794
- // focus on sub panel
9795
- if (this.options.focus) {
9796
- this.focus();
9797
- }
9798
- } else if (this.options.element) {
9799
- jQuery('.mailpoet_' + this.options.type + '_body').empty();
9800
- jQuery('.mailpoet_' + this.options.type + '_body')
9801
- .append(this.options.element);
9802
- } else {
9803
- jQuery('.mailpoet_' + this.options.type + '_body')
9804
- .html(
9805
- this.options.body_template(
9806
- this.options.data
9807
- )
9808
- );
9809
- }
9810
-
9811
- return this;
9812
- },
9813
- loadUrl: function () {
9814
- if (this.options.method === 'get') {
9815
- // make ajax request
9816
- jQuery.getJSON(this.options.url,
9817
- function (data) {
9818
- this.options.data = jQuery.extend({}, this.options.data, data);
9819
- // load template using fetched data
9820
- this.loadTemplate();
9821
- // show modal window
9822
- this.showModal();
9823
- }.bind(this)
9824
- );
9825
- } else if (this.options.method === 'post') {
9826
- // make ajax request
9827
- jQuery.post(this.options.url, JSON.stringify(this.options.params),
9828
- function (data) {
9829
- this.options.data = jQuery.extend({}, this.options.data, data);
9830
- // load template using fetched data
9831
- this.loadTemplate();
9832
- // show modal window
9833
- this.showModal();
9834
- }.bind(this),
9835
- 'json'
9836
- );
9837
- }
9838
-
9839
- return this;
9840
- },
9841
- setDimensions: function () {
9842
- switch (this.options.type) {
9843
- case 'popup':
9844
- // set popup dimensions
9845
- jQuery('#mailpoet_popup').css({
9846
- width: this.options.width,
9847
- height: this.options.height
9848
- });
9849
- // set popup wrapper height
9850
- jQuery('#mailpoet_popup_wrapper').css({
9851
- height: this.options.height
9852
- });
9853
- break;
9854
- case 'panel':
9855
- // set dimensions
9856
- if (this.options.position === 'right') {
9857
- jQuery('#mailpoet_panel').css({
9858
- width: this.options.width,
9859
- right: 0,
9860
- marginRight: '-' + this.options.width,
9861
- left: 'auto'
9862
- });
9863
- } else if (this.options.position === 'left') {
9864
- jQuery('#mailpoet_panel').css({
9865
- width: this.options.width,
9866
- left: 0,
9867
- marginLeft: '-' + this.options.width,
9868
- right: 'auto'
9869
- });
9870
- }
9871
- jQuery('#mailpoet_panel').css({ minHeight: 'auto' });
9872
- break;
9873
- }
9874
-
9875
- return this;
9876
- },
9877
- setPosition: function () {
9878
- var screenWidth;
9879
- var screenHeight;
9880
- var modalWidth;
9881
- var modalHeight;
9882
- switch (this.options.type) {
9883
- case 'popup':
9884
- screenWidth = jQuery(window).width();
9885
- screenHeight = jQuery(window).height();
9886
- modalWidth = jQuery('.mailpoet_'+ this.options.type +'_wrapper').width();
9887
- modalHeight = jQuery('.mailpoet_'+ this.options.type +'_wrapper').height();
9888
-
9889
- // set position of popup depending on screen dimensions.
9890
- jQuery('#mailpoet_popup').css({
9891
- top: Math.max(48, parseInt((screenHeight / 2) - (modalHeight / 2))),
9892
- left: Math.max(0, parseInt((screenWidth / 2) - (modalWidth / 2)))
9893
- });
9894
- break;
9895
- case 'panel':
9896
- setTimeout(function () {
9897
- // set position of popup depending on screen dimensions.
9898
- if (this.options.position === 'right') {
9899
- jQuery('#mailpoet_panel').css({
9900
- marginRight: 0
9901
- });
9902
- } else if (this.options.position === 'left') {
9903
- jQuery('#mailpoet_panel').css({
9904
- marginLeft: 0
9905
- });
9906
- }
9907
- }.bind(this), 0);
9908
- break;
9909
- }
9910
-
9911
- return this;
9912
- },
9913
- showModal: function () {
9914
- // set modal dimensions
9915
- this.setDimensions();
9916
-
9917
- // remember the previously focused element
9918
- this.prevFocus = jQuery(':focus');
9919
-
9920
- // show popup
9921
- jQuery('#mailpoet_' + this.options.type).show();
9922
-
9923
- // display overlay
9924
- this.showOverlay();
9925
-
9926
- // set modal position
9927
- this.setPosition();
9928
-
9929
- // add class on highlighted elements
9930
- if (this.options.highlight !== null) {
9931
- if (this.options.highlight.length > 0) {
9932
- this.highlightOn(this.options.highlight);
9933
- }
9934
- }
9935
-
9936
- if (this.options.focus) {
9937
- this.focus();
9938
- }
9939
-
9940
- // set popup as opened
9941
- this.opened = true;
9942
-
9943
- // trigger init event if specified
9944
- if (this.options.onInit !== null) {
9945
- this.options.onInit(this);
9946
- }
9947
-
9948
- return this;
9949
- },
9950
- focus: function () {
9951
- if (this.options.type == 'popup') {
9952
- jQuery('#mailpoet_' + this.options.type).focus();
9953
- } else {
9954
- // panel and subpanel
9955
- jQuery('#mailpoet_' + this.options.type + ' .mailpoet_panel_wrapper')
9956
- .filter(':visible').focus();
9957
- }
9958
- return this;
9959
- },
9960
- highlightOn: function (element) {
9961
- jQuery(element).addClass('mailpoet_modal_highlight');
9962
- return this;
9963
- },
9964
- highlightOff: function () {
9965
- jQuery('.mailpoet_modal_highlight')
9966
- .removeClass('mailpoet_modal_highlight');
9967
- return this;
9968
- },
9969
- hideModal: function () {
9970
- // set modal as closed
9971
- this.opened = false;
9972
-
9973
- // hide modal
9974
- jQuery('#mailpoet_' + this.options.type).hide();
9975
-
9976
- // remove class on highlighted elements
9977
- this.highlightOff();
9978
-
9979
- return this;
9980
- },
9981
- showOverlay: function () {
9982
- jQuery('#mailpoet_modal_overlay').show();
9983
- return this;
9984
- },
9985
- hideOverlay: function () {
9986
- jQuery('#mailpoet_modal_overlay').hide();
9987
- return this;
9988
- },
9989
- popup: function (opts) {
9990
- // get options
9991
- var options = opts || {};
9992
- // set modal type
9993
- options.type = 'popup';
9994
- // set overlay state
9995
- options.overlay = options.overlay || true;
9996
- // initialize modal
9997
- this.init(options);
9998
- // open modal
9999
- this.open();
10000
-
10001
- return this;
10002
- },
10003
- panel: function (opts) {
10004
- // get options
10005
- var options = opts || {};
10006
- // reset subpanels
10007
- this.subpanels = [];
10008
- // set modal type
10009
- options.type = 'panel';
10010
- // set overlay state
10011
- options.overlay = options.overlay || false;
10012
- // set highlighted element
10013
- options.highlight = options.highlight || null;
10014
- // set modal dimensions
10015
- options.width = options.width || '40%';
10016
- options.height = options.height || 'auto';
10017
- // initialize modal
10018
- this.init(options);
10019
- // open modal
10020
- this.open();
10021
-
10022
- return this;
10023
- },
10024
- subpanel: function (options) {
10025
- if (this.opened === false) {
10026
- // if no panel is already opened, let's create one instead
10027
- this.panel(options);
10028
- } else {
10029
- // if a panel is already opened, add a sub panel to it
10030
- this.subpanels.push(options);
10031
- this.loadTemplate();
10032
- }
10033
-
10034
- return this;
10035
- },
10036
- loading: function (toggle) {
10037
- // make sure the overlay is initialized and that it's visible
10038
- this.initOverlay(true);
10039
-
10040
- if (toggle === true) {
10041
- this.showLoading();
10042
- } else {
10043
- this.hideLoading();
10044
- }
10045
-
10046
- return this;
10047
- },
10048
- showLoading: function () {
10049
- jQuery('#mailpoet_loading').show();
10050
-
10051
- // add loading class to overlay
10052
- jQuery('#mailpoet_modal_overlay')
10053
- .addClass('mailpoet_overlay_loading');
10054
-
10055
- return this;
10056
- },
10057
- hideLoading: function () {
10058
- jQuery('#mailpoet_loading').hide();
10059
-
10060
- // remove loading class from overlay
10061
- jQuery('#mailpoet_modal_overlay')
10062
- .removeClass('mailpoet_overlay_loading');
10063
-
10064
- return this;
10065
- },
10066
- open: function () {
10067
- // load template if specified
10068
- if (this.options.template !== null) {
10069
- // check if a url was specified to get extra data
10070
- if (this.options.url !== null) {
10071
- this.loadUrl();
10072
- } else {
10073
- // load template
10074
- this.loadTemplate();
10075
-
10076
- // show modal window
10077
- this.showModal();
10078
- }
10079
- } else {
10080
- this.cancel();
10081
- }
10082
-
10083
- return this;
10084
- },
10085
- success: function () {
10086
- if (this.subpanels.length > 0) {
10087
- if (this.subpanels[(this.subpanels.length - 1)].onSuccess !== undefined) {
10088
- this.subpanels[(this.subpanels.length - 1)].onSuccess(this.subpanels[(this.subpanels.length - 1)].data);
10089
- }
10090
- } else {
10091
- if (this.options.onSuccess !== null) {
10092
- this.options.onSuccess(this.options.data);
10093
- }
10094
- }
10095
- this.close();
10096
-
10097
- return this;
10098
- },
10099
- cancel: function () {
10100
- if (this.subpanels.length > 0) {
10101
- if (this.subpanels[(this.subpanels.length - 1)].onCancel !== undefined) {
10102
- this.subpanels[(this.subpanels.length - 1)].onCancel(this.subpanels[(this.subpanels.length - 1)].data);
10103
- }
10104
- } else {
10105
- if (this.options.onCancel !== null) {
10106
- this.options.onCancel(this.options.data);
10107
- }
10108
- }
10109
- this.close();
10110
-
10111
- return this;
10112
- },
10113
- destroy: function () {
10114
- this.hideOverlay();
10115
-
10116
- // remove extra modal
10117
- if (jQuery('#mailpoet_' + this.options.type).length > 0) {
10118
- jQuery('#mailpoet_' + this.options.type).remove();
10119
- }
10120
-
10121
- this.initialized = false;
10122
-
10123
- return this;
10124
- },
10125
- close: function () {
10126
- if (this.isLocked() === true) { return this; }
10127
-
10128
- if (this.subpanels.length > 0) {
10129
- // close subpanel
10130
- jQuery('.mailpoet_' + this.options.type + '_wrapper').last().remove();
10131
-
10132
- // show previous panel
10133
- jQuery('.mailpoet_' + this.options.type + '_wrapper').last().show();
10134
-
10135
- // remove last subpanels
10136
- this.subpanels.pop();
10137
-
10138
- // focus on previous panel
10139
- if (this.options.focus) {
10140
- this.focus();
10141
- }
10142
-
10143
- return this;
10144
- }
10145
-
10146
- // remove event handlers
10147
- this.removeEvents();
10148
-
10149
- // hide modal window
10150
- this.hideModal();
10151
-
10152
- // destroy modal element
10153
- this.destroy();
10154
-
10155
- // restore the previously focused element
10156
- if (this.prevFocus !== undefined) {
10157
- this.prevFocus.focus();
10158
- }
10159
-
10160
- // reset options
10161
- this.options = {
10162
- onSuccess: null,
10163
- onCancel: null
10164
- };
10165
-
10166
- return this;
10167
- }
10168
- };
10169
- }.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
10170
-
10171
-
10172
-
10173
- /***/ },
10174
-
10175
- /***/ 566:
10176
- /***/ function(module, exports, __webpack_require__) {
10177
-
10178
- var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
10179
-
10180
- !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(276), __webpack_require__(275)], __WEBPACK_AMD_DEFINE_RESULT__ = function (mp, jQuery) { // eslint-disable-line func-names
10181
- /*= =================================================================================================
10182
-
10183
- MailPoet Notice:
10184
-
10185
- description: Handles notices
10186
- version: 1.0
10187
- author: Jonathan Labreuille
10188
- company: Wysija
10189
- dependencies: jQuery
10190
-
10191
- Usage:
10192
-
10193
- // success message (static: false)
10194
- MailPoet.Notice.success('Yatta!');
10195
-
10196
- // error message (static: false)
10197
- MailPoet.Notice.error('Boo!');
10198
-
10199
- // system message (static: true)
10200
- MailPoet.Notice.system('You need to updated ASAP!');
10201
-
10202
- ================================================================================================== */
10203
- var MailPoet = mp;
10204
- MailPoet.Notice = {
10205
- version: 1.0,
10206
- // default options
10207
- defaults: {
10208
- type: 'success',
10209
- message: '',
10210
- static: false,
10211
- hideClose: false,
10212
- id: null,
10213
- positionAfter: false,
10214
- scroll: false,
10215
- timeout: 5000,
10216
- onOpen: null,
10217
- onClose: null
10218
- },
10219
- options: {},
10220
- init: function init(options) {
10221
- // set options
10222
- this.options = jQuery.extend({}, this.defaults, options);
10223
-
10224
- return this;
10225
- },
10226
- createNotice: function createNotice() {
10227
- var onClose;
10228
- var positionAfter;
10229
- // clone element
10230
- this.element = jQuery('#mailpoet_notice_' + this.options.type).clone();
10231
-
10232
- // add data-id to the element
10233
- if (this.options.id) {
10234
- this.element.attr(
10235
- 'data-id',
10236
- this.options.id
10237
- );
10238
- }
10239
-
10240
- // remove id from clone
10241
- this.element.removeAttr('id');
10242
-
10243
- // insert notice after its parent
10244
- if (typeof this.options.positionAfter === 'object') {
10245
- positionAfter = this.options.positionAfter;
10246
- } else if (typeof this.options.positionAfter === 'string') {
10247
- positionAfter = jQuery(this.options.positionAfter);
10248
- } else {
10249
- positionAfter = jQuery('#mailpoet_notice_' + this.options.type);
10250
- }
10251
- positionAfter.after(this.element);
10252
-
10253
- // setup onClose callback
10254
- onClose = null;
10255
- if (this.options.onClose !== null) {
10256
- onClose = this.options.onClose;
10257
- }
10258
-
10259
- // listen to remove event
10260
- jQuery(this.element).on('close', function () { // eslint-disable-line func-names
10261
- jQuery(this).fadeOut(200, function () { // eslint-disable-line func-names
10262
- // on close callback
10263
- if (onClose !== null) {
10264
- onClose();
10265
- }
10266
- // remove notice
10267
- jQuery(this).remove();
10268
- });
10269
- }.bind(this.element));
10270
-
10271
- // listen to message event
10272
- jQuery(this.element).on('setMessage', function (e, message) { // eslint-disable-line func-names
10273
- MailPoet.Notice.setMessage(message);
10274
- }.bind(this.element));
10275
-
10276
- return this;
10277
- },
10278
- updateNotice: function updateNotice() {
10279
- // update notice's message
10280
- jQuery('[data-id="' + this.options.id + '"').first().trigger(
10281
- 'setMessage', this.options.message
10282
- );
10283
- },
10284
- setMessage: function setMessage(message) {
10285
- var formattedMessage = this.formatMessage(message);
10286
-
10287
- // let's sugar coat the message with a fancy <p>
10288
- formattedMessage = '<p>' + formattedMessage + '</p>';
10289
- // set message
10290
- return this.element.html(formattedMessage);
10291
- },
10292
- formatMessage: function formatMessage(message) {
10293
- if (Array.isArray(message)) {
10294
- return message.join('<br />');
10295
- }
10296
- return message;
10297
- },
10298
- show: function show(options) {
10299
- // initialize
10300
- this.init(options);
10301
-
10302
- if (
10303
- this.options.id !== null
10304
- &&
10305
- jQuery('[data-id="' + this.options.id + '"]').length > 0
10306
- ) {
10307
- this.updateNotice();
10308
- } else {
10309
- this.createNotice();
10310
- }
10311
- this.showNotice();
10312
- },
10313
- showNotice: function showNotice() {
10314
- // set message
10315
- this.setMessage(this.options.message);
10316
-
10317
- // position notice
10318
- this.element.insertAfter(jQuery('h2.title'));
10319
-
10320
- // set class name
10321
- switch (this.options.type) {
10322
- case 'success':
10323
- this.element.addClass('notice notice-success');
10324
- break;
10325
- case 'system':
10326
- this.element.addClass('notice notice-warning');
10327
- break;
10328
- case 'error':
10329
- this.element.addClass('notice notice-error');
10330
- break;
10331
- }
10332
-
10333
- // make the notice appear
10334
- this.element.fadeIn(200);
10335
-
10336
- // if scroll option is enabled, scroll to the notice
10337
- if (this.options.scroll === true) {
10338
- this.element.get(0).scrollIntoView(false);
10339
- }
10340
-
10341
- // if the notice is not static, it has to disappear after a timeout
10342
- if (this.options.static === false) {
10343
- this.element.delay(this.options.timeout).trigger('close');
10344
- } else if (this.options.hideClose === false) {
10345
- this.element.append('<a href="javascript:;" class="mailpoet_notice_close"><span class="dashicons dashicons-dismiss"></span></a>');
10346
- this.element.find('.mailpoet_notice_close').on('click', function () { // eslint-disable-line func-names
10347
- jQuery(this).trigger('close');
10348
- });
10349
- }
10350
-
10351
- // call onOpen callback
10352
- if (this.options.onOpen !== null) {
10353
- this.options.onOpen(this.element);
10354
- }
10355
- },
10356
- hide: function hide(all) {
10357
- var id;
10358
- if (all !== undefined && all === true) {
10359
- // all notices
10360
- jQuery('.mailpoet_notice:not([id])').trigger('close');
10361
- } else if (all !== undefined && jQuery.isArray(all)) {
10362
- // array of ids
10363
- for (id in all) {
10364
- jQuery('[data-id="' + all[id] + '"]').trigger('close');
10365
- }
10366
- } if (all !== undefined) {
10367
- // single id
10368
- jQuery('[data-id="' + all + '"]').trigger('close');
10369
- } else {
10370
- jQuery('.mailpoet_notice.notice-success:not([id]), .mailpoet_notice.notice-error:not([id])')
10371
- .trigger('close');
10372
- }
10373
- },
10374
- error: function error(message, options) {
10375
- this.show(jQuery.extend({}, {
10376
- type: 'error',
10377
- message: message
10378
- }, options));
10379
- },
10380
- success: function success(message, options) {
10381
- this.show(jQuery.extend({}, {
10382
- type: 'success',
10383
- message: message
10384
- }, options));
10385
- },
10386
- system: function system(message, options) {
10387
- this.show(jQuery.extend({}, {
10388
- type: 'system',
10389
- static: true,
10390
- message: message
10391
- }, options));
10392
- }
10393
- };
10394
- }.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
10395
-
10396
-
10397
- /***/ },
10398
-
10399
- /***/ 572:
10400
- /***/ function(module, exports, __webpack_require__) {
10401
-
10402
- // MarionetteJS (Backbone.Marionette)
10403
- // ----------------------------------
10404
- // v3.2.0
10405
- //
10406
- // Copyright (c)2017 Derick Bailey, Muted Solutions, LLC.
10407
- // Distributed under MIT license
10408
- //
10409
- // http://marionettejs.com
10410
-
10411
-
10412
- (function (global, factory) {
10413
- true ? module.exports = factory(__webpack_require__(544), __webpack_require__(280), __webpack_require__(573)) :
10414
- typeof define === 'function' && define.amd ? define(['backbone', 'underscore', 'backbone.radio'], factory) :
10415
- (global.Marionette = global['Mn'] = factory(global.Backbone,global._,global.Backbone.Radio));
10416
- }(this, (function (Backbone,_,Radio) { 'use strict';
10417
-
10418
- Backbone = 'default' in Backbone ? Backbone['default'] : Backbone;
10419
- _ = 'default' in _ ? _['default'] : _;
10420
- Radio = 'default' in Radio ? Radio['default'] : Radio;
10421
-
10422
- var version = "3.2.0";
10423
-
10424
- //Internal utility for creating context style global utils
10425
- var proxy = function proxy(method) {
10426
- return function (context) {
10427
- for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
10428
- args[_key - 1] = arguments[_key];
10429
- }
10430
-
10431
- return method.apply(context, args);
10432
- };
10433
- };
10434
-
10435
- // Marionette.extend
10436
- // -----------------
10437
-
10438
- // Borrow the Backbone `extend` method so we can use it as needed
10439
- var extend = Backbone.Model.extend;
10440
-
10441
- /* global console */
10442
-
10443
- var deprecate = function deprecate(message, test) {
10444
- if (_.isObject(message)) {
10445
- message = message.prev + ' is going to be removed in the future. ' + 'Please use ' + message.next + ' instead.' + (message.url ? ' See: ' + message.url : '');
10446
- }
10447
-
10448
- if (!Marionette.DEV_MODE) {
10449
- return;
10450
- }
10451
-
10452
- if ((test === undefined || !test) && !deprecate._cache[message]) {
10453
- deprecate._warn('Deprecation warning: ' + message);
10454
- deprecate._cache[message] = true;
10455
- }
10456
- };
10457
-
10458
- deprecate._console = typeof console !== 'undefined' ? console : {};
10459
- deprecate._warn = function () {
10460
- var warn = deprecate._console.warn || deprecate._console.log || _.noop;
10461
- return warn.apply(deprecate._console, arguments);
10462
- };
10463
- deprecate._cache = {};
10464
-
10465
- // Marionette.isNodeAttached
10466
- // -------------------------
10467
-
10468
- // Determine if `el` is a child of the document
10469
- var isNodeAttached = function isNodeAttached(el) {
10470
- return document.documentElement.contains(el && el.parentNode);
10471
- };
10472
-
10473
- // Merge `keys` from `options` onto `this`
10474
- var mergeOptions = function mergeOptions(options, keys) {
10475
- var _this = this;
10476
-
10477
- if (!options) {
10478
- return;
10479
- }
10480
-
10481
- _.each(keys, function (key) {
10482
- var option = options[key];
10483
- if (option !== undefined) {
10484
- _this[key] = option;
10485
- }
10486
- });
10487
- };
10488
-
10489
- // Marionette.getOption
10490
- // --------------------
10491
-
10492
- // Retrieve an object, function or other value from the
10493
- // object or its `options`, with `options` taking precedence.
10494
- var getOption = function getOption(optionName) {
10495
- if (!optionName) {
10496
- return;
10497
- }
10498
- if (this.options && this.options[optionName] !== undefined) {
10499
- return this.options[optionName];
10500
- } else {
10501
- return this[optionName];
10502
- }
10503
- };
10504
-
10505
- // Marionette.normalizeMethods
10506
- // ----------------------
10507
-
10508
- // Pass in a mapping of events => functions or function names
10509
- // and return a mapping of events => functions
10510
- var normalizeMethods = function normalizeMethods(hash) {
10511
- var _this = this;
10512
-
10513
- return _.reduce(hash, function (normalizedHash, method, name) {
10514
- if (!_.isFunction(method)) {
10515
- method = _this[method];
10516
- }
10517
- if (method) {
10518
- normalizedHash[name] = method;
10519
- }
10520
- return normalizedHash;
10521
- }, {});
10522
- };
10523
-
10524
- // Trigger Method
10525
- // --------------
10526
-
10527
- // split the event name on the ":"
10528
- var splitter = /(^|:)(\w)/gi;
10529
-
10530
- // take the event section ("section1:section2:section3")
10531
- // and turn it in to uppercase name onSection1Section2Section3
10532
- function getEventName(match, prefix, eventName) {
10533
- return eventName.toUpperCase();
10534
- }
10535
-
10536
- var getOnMethodName = _.memoize(function (event) {
10537
- return 'on' + event.replace(splitter, getEventName);
10538
- });
10539
-
10540
- // Trigger an event and/or a corresponding method name. Examples:
10541
- //
10542
- // `this.triggerMethod("foo")` will trigger the "foo" event and
10543
- // call the "onFoo" method.
10544
- //
10545
- // `this.triggerMethod("foo:bar")` will trigger the "foo:bar" event and
10546
- // call the "onFooBar" method.
10547
- function triggerMethod$1(event) {
10548
- for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
10549
- args[_key - 1] = arguments[_key];
10550
- }
10551
-
10552
- // get the method name from the event name
10553
- var methodName = getOnMethodName(event);
10554
- var method = getOption.call(this, methodName);
10555
- var result = void 0;
10556
-
10557
- // call the onMethodName if it exists
10558
- if (_.isFunction(method)) {
10559
- // pass all args, except the event name
10560
- result = method.apply(this, args);
10561
- }
10562
-
10563
- // trigger the event
10564
- this.trigger.apply(this, arguments);
10565
-
10566
- return result;
10567
- }
10568
-
10569
- // triggerMethodOn invokes triggerMethod on a specific context
10570
- //
10571
- // e.g. `Marionette.triggerMethodOn(view, 'show')`
10572
- // will trigger a "show" event or invoke onShow the view.
10573
- function triggerMethodOn(context) {
10574
- for (var _len2 = arguments.length, args = Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
10575
- args[_key2 - 1] = arguments[_key2];
10576
- }
10577
-
10578
- if (_.isFunction(context.triggerMethod)) {
10579
- return context.triggerMethod.apply(context, args);
10580
- }
10581
-
10582
- return triggerMethod$1.apply(context, args);
10583
- }
10584
-
10585
- // DOM Refresh
10586
- // -----------
10587
-
10588
- // Trigger method on children unless a pure Backbone.View
10589
- function triggerMethodChildren(view, event, shouldTrigger) {
10590
- if (!view._getImmediateChildren) {
10591
- return;
10592
- }
10593
- _.each(view._getImmediateChildren(), function (child) {
10594
- if (!shouldTrigger(child)) {
10595
- return;
10596
- }
10597
- triggerMethodOn(child, event, child);
10598
- });
10599
- }
10600
-
10601
- function shouldTriggerAttach(view) {
10602
- return !view._isAttached;
10603
- }
10604
-
10605
- function shouldAttach(view) {
10606
- if (!shouldTriggerAttach(view)) {
10607
- return false;
10608
- }
10609
- view._isAttached = true;
10610
- return true;
10611
- }
10612
-
10613
- function shouldTriggerDetach(view) {
10614
- return view._isAttached;
10615
- }
10616
-
10617
- function shouldDetach(view) {
10618
- if (!shouldTriggerDetach(view)) {
10619
- return false;
10620
- }
10621
- view._isAttached = false;
10622
- return true;
10623
- }
10624
-
10625
- function triggerDOMRefresh(view) {
10626
- if (view._isAttached && view._isRendered) {
10627
- triggerMethodOn(view, 'dom:refresh', view);
10628
- }
10629
- }
10630
-
10631
- function handleBeforeAttach() {
10632
- triggerMethodChildren(this, 'before:attach', shouldTriggerAttach);
10633
- }
10634
-
10635
- function handleAttach() {
10636
- triggerMethodChildren(this, 'attach', shouldAttach);
10637
- triggerDOMRefresh(this);
10638
- }
10639
-
10640
- function handleBeforeDetach() {
10641
- triggerMethodChildren(this, 'before:detach', shouldTriggerDetach);
10642
- }
10643
-
10644
- function handleDetach() {
10645
- triggerMethodChildren(this, 'detach', shouldDetach);
10646
- }
10647
-
10648
- function handleRender() {
10649
- triggerDOMRefresh(this);
10650
- }
10651
-
10652
- // Monitor a view's state, propagating attach/detach events to children and firing dom:refresh
10653
- // whenever a rendered view is attached or an attached view is rendered.
10654
- function monitorViewEvents(view) {
10655
- if (view._areViewEventsMonitored) {
10656
- return;
10657
- }
10658
-
10659
- view._areViewEventsMonitored = true;
10660
-
10661
- view.on({
10662
- 'before:attach': handleBeforeAttach,
10663
- 'attach': handleAttach,
10664
- 'before:detach': handleBeforeDetach,
10665
- 'detach': handleDetach,
10666
- 'render': handleRender
10667
- });
10668
- }
10669
-
10670
- // Error
10671
- // -----
10672
-
10673
- var errorProps = ['description', 'fileName', 'lineNumber', 'name', 'message', 'number'];
10674
-
10675
- var MarionetteError = extend.call(Error, {
10676
- urlRoot: 'http://marionettejs.com/docs/v' + version + '/',
10677
-
10678
- constructor: function constructor(message, options) {
10679
- if (_.isObject(message)) {
10680
- options = message;
10681
- message = options.message;
10682
- } else if (!options) {
10683
- options = {};
10684
- }
10685
-
10686
- var error = Error.call(this, message);
10687
- _.extend(this, _.pick(error, errorProps), _.pick(options, errorProps));
10688
-
10689
- this.captureStackTrace();
10690
-
10691
- if (options.url) {
10692
- this.url = this.urlRoot + options.url;
10693
- }
10694
- },
10695
- captureStackTrace: function captureStackTrace() {
10696
- if (Error.captureStackTrace) {
10697
- Error.captureStackTrace(this, MarionetteError);
10698
- }
10699
- },
10700
- toString: function toString() {
10701
- return this.name + ': ' + this.message + (this.url ? ' See: ' + this.url : '');
10702
- }
10703
- });
10704
-
10705
- MarionetteError.extend = extend;
10706
-
10707
- // Bind Entity Events & Unbind Entity Events
10708
- // -----------------------------------------
10709
- //
10710
- // These methods are used to bind/unbind a backbone "entity" (e.g. collection/model)
10711
- // to methods on a target object.
10712
- //
10713
- // The first parameter, `target`, must have the Backbone.Events module mixed in.
10714
- //
10715
- // The second parameter is the `entity` (Backbone.Model, Backbone.Collection or
10716
- // any object that has Backbone.Events mixed in) to bind the events from.
10717
- //
10718
- // The third parameter is a hash of { "event:name": "eventHandler" }
10719
- // configuration. Multiple handlers can be separated by a space. A
10720
- // function can be supplied instead of a string handler name.
10721
-
10722
- // Bind/unbind the event to handlers specified as a string of
10723
- // handler names on the target object
10724
- function bindFromStrings(target, entity, evt, methods, actionName) {
10725
- var methodNames = methods.split(/\s+/);
10726
-
10727
- _.each(methodNames, function (methodName) {
10728
- var method = target[methodName];
10729
- if (!method) {
10730
- throw new MarionetteError('Method "' + methodName + '" was configured as an event handler, but does not exist.');
10731
- }
10732
-
10733
- target[actionName](entity, evt, method);
10734
- });
10735
- }
10736
-
10737
- // generic looping function
10738
- function iterateEvents(target, entity, bindings, actionName) {
10739
- if (!entity || !bindings) {
10740
- return;
10741
- }
10742
-
10743
- // type-check bindings
10744
- if (!_.isObject(bindings)) {
10745
- throw new MarionetteError({
10746
- message: 'Bindings must be an object.',
10747
- url: 'marionette.functions.html#marionettebindevents'
10748
- });
10749
- }
10750
-
10751
- // iterate the bindings and bind/unbind them
10752
- _.each(bindings, function (method, evt) {
10753
-
10754
- // allow for a list of method names as a string
10755
- if (_.isString(method)) {
10756
- bindFromStrings(target, entity, evt, method, actionName);
10757
- return;
10758
- }
10759
-
10760
- target[actionName](entity, evt, method);
10761
- });
10762
- }
10763
-
10764
- function bindEvents(entity, bindings) {
10765
- iterateEvents(this, entity, bindings, 'listenTo');
10766
- return this;
10767
- }
10768
-
10769
- function unbindEvents(entity, bindings) {
10770
- iterateEvents(this, entity, bindings, 'stopListening');
10771
- return this;
10772
- }
10773
-
10774
- // Bind/Unbind Radio Requests
10775
- // -----------------------------------------
10776
- //
10777
- // These methods are used to bind/unbind a backbone.radio request
10778
- // to methods on a target object.
10779
- //
10780
- // The first parameter, `target`, will set the context of the reply method
10781
- //
10782
- // The second parameter is the `Radio.channel` to bind the reply to.
10783
- //
10784
- // The third parameter is a hash of { "request:name": "replyHandler" }
10785
- // configuration. A function can be supplied instead of a string handler name.
10786
-
10787
- function iterateReplies(target, channel, bindings, actionName) {
10788
- if (!channel || !bindings) {
10789
- return;
10790
- }
10791
-
10792
- // type-check bindings
10793
- if (!_.isObject(bindings)) {
10794
- throw new MarionetteError({
10795
- message: 'Bindings must be an object.',
10796
- url: 'marionette.functions.html#marionettebindrequests'
10797
- });
10798
- }
10799
-
10800
- var normalizedRadioRequests = normalizeMethods.call(target, bindings);
10801
-
10802
- channel[actionName](normalizedRadioRequests, target);
10803
- }
10804
-
10805
- function bindRequests(channel, bindings) {
10806
- iterateReplies(this, channel, bindings, 'reply');
10807
- return this;
10808
- }
10809
-
10810
- function unbindRequests(channel, bindings) {
10811
- iterateReplies(this, channel, bindings, 'stopReplying');
10812
- return this;
10813
- }
10814
-
10815
- // Internal utility for setting options consistently across Mn
10816
- var setOptions = function setOptions() {
10817
- for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
10818
- args[_key] = arguments[_key];
10819
- }
10820
-
10821
- this.options = _.extend.apply(_, [{}, _.result(this, 'options')].concat(args));
10822
- };
10823
-
10824
- var CommonMixin = {
10825
-
10826
- // Imports the "normalizeMethods" to transform hashes of
10827
- // events=>function references/names to a hash of events=>function references
10828
- normalizeMethods: normalizeMethods,
10829
-
10830
- _setOptions: setOptions,
10831
-
10832
- // A handy way to merge passed-in options onto the instance
10833
- mergeOptions: mergeOptions,
10834
-
10835
- // Enable getting options from this or this.options by name.
10836
- getOption: getOption,
10837
-
10838
- // Enable binding view's events from another entity.
10839
- bindEvents: bindEvents,
10840
-
10841
- // Enable unbinding view's events from another entity.
10842
- unbindEvents: unbindEvents
10843
- };
10844
-
10845
- // MixinOptions
10846
- // - channelName
10847
- // - radioEvents
10848
- // - radioRequests
10849
-
10850
- var RadioMixin = {
10851
- _initRadio: function _initRadio() {
10852
- var channelName = _.result(this, 'channelName');
10853
-
10854
- if (!channelName) {
10855
- return;
10856
- }
10857
-
10858
- /* istanbul ignore next */
10859
- if (!Radio) {
10860
- throw new MarionetteError({
10861
- name: 'BackboneRadioMissing',
10862
- message: 'The dependency "backbone.radio" is missing.'
10863
- });
10864
- }
10865
-
10866
- var channel = this._channel = Radio.channel(channelName);
10867
-
10868
- var radioEvents = _.result(this, 'radioEvents');
10869
- this.bindEvents(channel, radioEvents);
10870
-
10871
- var radioRequests = _.result(this, 'radioRequests');
10872
- this.bindRequests(channel, radioRequests);
10873
-
10874
- this.on('destroy', this._destroyRadio);
10875
- },
10876
- _destroyRadio: function _destroyRadio() {
10877
- this._channel.stopReplying(null, null, this);
10878
- },
10879
- getChannel: function getChannel() {
10880
- return this._channel;
10881
- },
10882
-
10883
-
10884
- // Proxy `bindEvents`
10885
- bindEvents: bindEvents,
10886
-
10887
- // Proxy `unbindEvents`
10888
- unbindEvents: unbindEvents,
10889
-
10890
- // Proxy `bindRequests`
10891
- bindRequests: bindRequests,
10892
-
10893
- // Proxy `unbindRequests`
10894
- unbindRequests: unbindRequests
10895
-
10896
- };
10897
-
10898
- // Object
10899
- // ------
10900
-
10901
- var ClassOptions = ['channelName', 'radioEvents', 'radioRequests'];
10902
-
10903
- // A Base Class that other Classes should descend from.
10904
- // Object borrows many conventions and utilities from Backbone.
10905
- var MarionetteObject = function MarionetteObject(options) {
10906
- this._setOptions(options);
10907
- this.mergeOptions(options, ClassOptions);
10908
- this.cid = _.uniqueId(this.cidPrefix);
10909
- this._initRadio();
10910
- this.initialize.apply(this, arguments);
10911
- };
10912
-
10913
- MarionetteObject.extend = extend;
10914
-
10915
- // Object Methods
10916
- // --------------
10917
-
10918
- // Ensure it can trigger events with Backbone.Events
10919
- _.extend(MarionetteObject.prototype, Backbone.Events, CommonMixin, RadioMixin, {
10920
- cidPrefix: 'mno',
10921
-
10922
- // for parity with Marionette.AbstractView lifecyle
10923
- _isDestroyed: false,
10924
-
10925
- isDestroyed: function isDestroyed() {
10926
- return this._isDestroyed;
10927
- },
10928
-
10929
-
10930
- //this is a noop method intended to be overridden by classes that extend from this base
10931
- initialize: function initialize() {},
10932
- destroy: function destroy() {
10933
- if (this._isDestroyed) {
10934
- return this;
10935
- }
10936
-
10937
- for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
10938
- args[_key] = arguments[_key];
10939
- }
10940
-
10941
- this.triggerMethod.apply(this, ['before:destroy', this].concat(args));
10942
-
10943
- this._isDestroyed = true;
10944
- this.triggerMethod.apply(this, ['destroy', this].concat(args));
10945
- this.stopListening();
10946
-
10947
- return this;
10948
- },
10949
-
10950
-
10951
- triggerMethod: triggerMethod$1
10952
- });
10953
-
10954
- // DomMixin
10955
- // ---------
10956
-
10957
- var DomMixin = {
10958
- createBuffer: function createBuffer() {
10959
- return document.createDocumentFragment();
10960
- },
10961
- appendChildren: function appendChildren(el, children) {
10962
- Backbone.$(el).append(children);
10963
- },
10964
- beforeEl: function beforeEl(el, sibling) {
10965
- Backbone.$(el).before(sibling);
10966
- },
10967
- replaceEl: function replaceEl(newEl, oldEl) {
10968
- if (newEl === oldEl) {
10969
- return;
10970
- }
10971
-
10972
- var parent = oldEl.parentNode;
10973
-
10974
- if (!parent) {
10975
- return;
10976
- }
10977
-
10978
- parent.replaceChild(newEl, oldEl);
10979
- },
10980
- detachContents: function detachContents(el) {
10981
- Backbone.$(el).contents().detach();
10982
- },
10983
- setInnerContent: function setInnerContent(el, html) {
10984
- Backbone.$(el).html(html);
10985
- },
10986
- removeEl: function removeEl(el) {
10987
- Backbone.$(el).remove();
10988
- },
10989
- findEls: function findEls(selector, context) {
10990
- return Backbone.$(selector, context);
10991
- }
10992
- };
10993
-
10994
- // Template Cache
10995
- // --------------
10996
-
10997
- // Manage templates stored in `<script>` blocks,
10998
- // caching them for faster access.
10999
- var TemplateCache = function TemplateCache(templateId) {
11000
- this.templateId = templateId;
11001
- };
11002
-
11003
- // TemplateCache object-level methods. Manage the template
11004
- // caches from these method calls instead of creating
11005
- // your own TemplateCache instances
11006
- _.extend(TemplateCache, {
11007
- templateCaches: {},
11008
-
11009
- // Get the specified template by id. Either
11010
- // retrieves the cached version, or loads it
11011
- // from the DOM.
11012
- get: function get(templateId, options) {
11013
- var cachedTemplate = this.templateCaches[templateId];
11014
-
11015
- if (!cachedTemplate) {
11016
- cachedTemplate = new TemplateCache(templateId);
11017
- this.templateCaches[templateId] = cachedTemplate;
11018
- }
11019
-
11020
- return cachedTemplate.load(options);
11021
- },
11022
-
11023
-
11024
- // Clear templates from the cache. If no arguments
11025
- // are specified, clears all templates:
11026
- // `clear()`
11027
- //
11028
- // If arguments are specified, clears each of the
11029
- // specified templates from the cache:
11030
- // `clear("#t1", "#t2", "...")`
11031
- clear: function clear() {
11032
- var i = void 0;
11033
-
11034
- for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
11035
- args[_key] = arguments[_key];
11036
- }
11037
-
11038
- var length = args.length;
11039
-
11040
- if (length > 0) {
11041
- for (i = 0; i < length; i++) {
11042
- delete this.templateCaches[args[i]];
11043
- }
11044
- } else {
11045
- this.templateCaches = {};
11046
- }
11047
- }
11048
- });
11049
-
11050
- // TemplateCache instance methods, allowing each
11051
- // template cache object to manage its own state
11052
- // and know whether or not it has been loaded
11053
- _.extend(TemplateCache.prototype, DomMixin, {
11054
-
11055
- // Internal method to load the template
11056
- load: function load(options) {
11057
- // Guard clause to prevent loading this template more than once
11058
- if (this.compiledTemplate) {
11059
- return this.compiledTemplate;
11060
- }
11061
-
11062
- // Load the template and compile it
11063
- var template = this.loadTemplate(this.templateId, options);
11064
- this.compiledTemplate = this.compileTemplate(template, options);
11065
-
11066
- return this.compiledTemplate;
11067
- },
11068
-
11069
-
11070
- // Load a template from the DOM, by default. Override
11071
- // this method to provide your own template retrieval
11072
- // For asynchronous loading with AMD/RequireJS, consider
11073
- // using a template-loader plugin as described here:
11074
- // https://github.com/marionettejs/backbone.marionette/wiki/Using-marionette-with-requirejs
11075
- loadTemplate: function loadTemplate(templateId, options) {
11076
- var $template = this.findEls(templateId);
11077
-
11078
- if (!$template.length) {
11079
- throw new MarionetteError({
11080
- name: 'NoTemplateError',
11081
- message: 'Could not find template: "' + templateId + '"'
11082
- });
11083
- }
11084
- return $template.html();
11085
- },
11086
-
11087
-
11088
- // Pre-compile the template before caching it. Override
11089
- // this method if you do not need to pre-compile a template
11090
- // (JST / RequireJS for example) or if you want to change
11091
- // the template engine used (Handebars, etc).
11092
- compileTemplate: function compileTemplate(rawTemplate, options) {
11093
- return _.template(rawTemplate, options);
11094
- }
11095
- });
11096
-
11097
- // Implementation of the invoke method (http://underscorejs.org/#invoke) with support for
11098
- // lodash v3, v4, and underscore.js
11099
- var _invoke = _.invokeMap || _.invoke;
11100
-
11101
- function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } }
11102
-
11103
- // MixinOptions
11104
- // - behaviors
11105
-
11106
- // Takes care of getting the behavior class
11107
- // given options and a key.
11108
- // If a user passes in options.behaviorClass
11109
- // default to using that.
11110
- // If a user passes in a Behavior Class directly, use that
11111
- // Otherwise delegate the lookup to the users `behaviorsLookup` implementation.
11112
- function getBehaviorClass(options, key) {
11113
- if (options.behaviorClass) {
11114
- return options.behaviorClass;
11115
- //treat functions as a Behavior constructor
11116
- } else if (_.isFunction(options)) {
11117
- return options;
11118
- }
11119
-
11120
- // behaviorsLookup can be either a flat object or a method
11121
- if (_.isFunction(Marionette.Behaviors.behaviorsLookup)) {
11122
- return Marionette.Behaviors.behaviorsLookup(options, key)[key];
11123
- }
11124
-
11125
- return Marionette.Behaviors.behaviorsLookup[key];
11126
- }
11127
-
11128
- // Iterate over the behaviors object, for each behavior
11129
- // instantiate it and get its grouped behaviors.
11130
- // This accepts a list of behaviors in either an object or array form
11131
- function parseBehaviors(view, behaviors) {
11132
- return _.chain(behaviors).map(function (options, key) {
11133
- var BehaviorClass = getBehaviorClass(options, key);
11134
- //if we're passed a class directly instead of an object
11135
- var _options = options === BehaviorClass ? {} : options;
11136
- var behavior = new BehaviorClass(_options, view);
11137
- var nestedBehaviors = parseBehaviors(view, _.result(behavior, 'behaviors'));
11138
-
11139
- return [behavior].concat(nestedBehaviors);
11140
- }).flatten().value();
11141
- }
11142
-
11143
- var BehaviorsMixin = {
11144
- _initBehaviors: function _initBehaviors() {
11145
- this._behaviors = this._getBehaviors();
11146
- },
11147
- _getBehaviors: function _getBehaviors() {
11148
- var behaviors = _.result(this, 'behaviors');
11149
-
11150
- // Behaviors defined on a view can be a flat object literal
11151
- // or it can be a function that returns an object.
11152
- return _.isObject(behaviors) ? parseBehaviors(this, behaviors) : {};
11153
- },
11154
- _getBehaviorTriggers: function _getBehaviorTriggers() {
11155
- var triggers = _invoke(this._behaviors, 'getTriggers');
11156
- return _.extend.apply(_, [{}].concat(_toConsumableArray(triggers)));
11157
- },
11158
- _getBehaviorEvents: function _getBehaviorEvents() {
11159
- var events = _invoke(this._behaviors, 'getEvents');
11160
- return _.extend.apply(_, [{}].concat(_toConsumableArray(events)));
11161
- },
11162
-
11163
-
11164
- // proxy behavior $el to the view's $el.
11165
- _proxyBehaviorViewProperties: function _proxyBehaviorViewProperties() {
11166
- _invoke(this._behaviors, 'proxyViewProperties');
11167
- },
11168
-
11169
-
11170
- // delegate modelEvents and collectionEvents
11171
- _delegateBehaviorEntityEvents: function _delegateBehaviorEntityEvents() {
11172
- _invoke(this._behaviors, 'delegateEntityEvents');
11173
- },
11174
-
11175
-
11176
- // undelegate modelEvents and collectionEvents
11177
- _undelegateBehaviorEntityEvents: function _undelegateBehaviorEntityEvents() {
11178
- _invoke(this._behaviors, 'undelegateEntityEvents');
11179
- },
11180
- _destroyBehaviors: function _destroyBehaviors(args) {
11181
- // Call destroy on each behavior after
11182
- // destroying the view.
11183
- // This unbinds event listeners
11184
- // that behaviors have registered for.
11185
- _invoke.apply(undefined, [this._behaviors, 'destroy'].concat(_toConsumableArray(args)));
11186
- },
11187
- _bindBehaviorUIElements: function _bindBehaviorUIElements() {
11188
- _invoke(this._behaviors, 'bindUIElements');
11189
- },
11190
- _unbindBehaviorUIElements: function _unbindBehaviorUIElements() {
11191
- _invoke(this._behaviors, 'unbindUIElements');
11192
- },
11193
- _triggerEventOnBehaviors: function _triggerEventOnBehaviors() {
11194
- var behaviors = this._behaviors;
11195
- // Use good ol' for as this is a very hot function
11196
- for (var i = 0, length = behaviors && behaviors.length; i < length; i++) {
11197
- triggerMethod$1.apply(behaviors[i], arguments);
11198
- }
11199
- }
11200
- };
11201
-
11202
- // MixinOptions
11203
- // - collectionEvents
11204
- // - modelEvents
11205
-
11206
- var DelegateEntityEventsMixin = {
11207
- // Handle `modelEvents`, and `collectionEvents` configuration
11208
- _delegateEntityEvents: function _delegateEntityEvents(model, collection) {
11209
- this._undelegateEntityEvents(model, collection);
11210
-
11211
- var modelEvents = _.result(this, 'modelEvents');
11212
- bindEvents.call(this, model, modelEvents);
11213
-
11214
- var collectionEvents = _.result(this, 'collectionEvents');
11215
- bindEvents.call(this, collection, collectionEvents);
11216
- },
11217
- _undelegateEntityEvents: function _undelegateEntityEvents(model, collection) {
11218
- var modelEvents = _.result(this, 'modelEvents');
11219
- unbindEvents.call(this, model, modelEvents);
11220
-
11221
- var collectionEvents = _.result(this, 'collectionEvents');
11222
- unbindEvents.call(this, collection, collectionEvents);
11223
- }
11224
- };
11225
-
11226
- // Borrow event splitter from Backbone
11227
- var delegateEventSplitter = /^(\S+)\s*(.*)$/;
11228
-
11229
- function uniqueName(eventName, selector) {
11230
- return [eventName + _.uniqueId('.evt'), selector].join(' ');
11231
- }
11232
-
11233
- // Set event name to be namespaced using a unique index
11234
- // to generate a non colliding event namespace
11235
- // http://api.jquery.com/event.namespace/
11236
- var getUniqueEventName = function getUniqueEventName(eventName) {
11237
- var match = eventName.match(delegateEventSplitter);
11238
- return uniqueName(match[1], match[2]);
11239
- };
11240
-
11241
- // Add Feature flags here
11242
- // e.g. 'class' => false
11243
- var FEATURES = {
11244
- triggersStopPropagation: true,
11245
- triggersPreventDefault: true
11246
- };
11247
-
11248
- function isEnabled(name) {
11249
- return !!FEATURES[name];
11250
- }
11251
-
11252
- function setEnabled(name, state) {
11253
- return FEATURES[name] = state;
11254
- }
11255
-
11256
- // Internal method to create an event handler for a given `triggerDef` like
11257
- // 'click:foo'
11258
- function buildViewTrigger(view, triggerDef) {
11259
- if (_.isString(triggerDef)) {
11260
- triggerDef = { event: triggerDef };
11261
- }
11262
-
11263
- var eventName = triggerDef.event;
11264
-
11265
- var shouldPreventDefault = !!triggerDef.preventDefault;
11266
-
11267
- if (isEnabled('triggersPreventDefault')) {
11268
- shouldPreventDefault = triggerDef.preventDefault !== false;
11269
- }
11270
-
11271
- var shouldStopPropagation = !!triggerDef.stopPropagation;
11272
-
11273
- if (isEnabled('triggersStopPropagation')) {
11274
- shouldStopPropagation = triggerDef.stopPropagation !== false;
11275
- }
11276
-
11277
- return function (event) {
11278
- if (shouldPreventDefault) {
11279
- event.preventDefault();
11280
- }
11281
-
11282
- if (shouldStopPropagation) {
11283
- event.stopPropagation();
11284
- }
11285
-
11286
- view.triggerMethod(eventName, view, event);
11287
- };
11288
- }
11289
-
11290
- var TriggersMixin = {
11291
-
11292
- // Configure `triggers` to forward DOM events to view
11293
- // events. `triggers: {"click .foo": "do:foo"}`
11294
- _getViewTriggers: function _getViewTriggers(view, triggers) {
11295
- // Configure the triggers, prevent default
11296
- // action and stop propagation of DOM events
11297
- return _.reduce(triggers, function (events, value, key) {
11298
- key = getUniqueEventName(key);
11299
- events[key] = buildViewTrigger(view, value);
11300
- return events;
11301
- }, {});
11302
- }
11303
- };
11304
-
11305
- // allows for the use of the @ui. syntax within
11306
- // a given key for triggers and events
11307
- // swaps the @ui with the associated selector.
11308
- // Returns a new, non-mutated, parsed events hash.
11309
- var _normalizeUIKeys = function _normalizeUIKeys(hash, ui) {
11310
- return _.reduce(hash, function (memo, val, key) {
11311
- var normalizedKey = _normalizeUIString(key, ui);
11312
- memo[normalizedKey] = val;
11313
- return memo;
11314
- }, {});
11315
- };
11316
-
11317
- // utility method for parsing @ui. syntax strings
11318
- // into associated selector
11319
- var _normalizeUIString = function _normalizeUIString(uiString, ui) {
11320
- return uiString.replace(/@ui\.[a-zA-Z-_$0-9]*/g, function (r) {
11321
- return ui[r.slice(4)];
11322
- });
11323
- };
11324
-
11325
- // allows for the use of the @ui. syntax within
11326
- // a given value for regions
11327
- // swaps the @ui with the associated selector
11328
- var _normalizeUIValues = function _normalizeUIValues(hash, ui, properties) {
11329
- _.each(hash, function (val, key) {
11330
- if (_.isString(val)) {
11331
- hash[key] = _normalizeUIString(val, ui);
11332
- } else if (_.isObject(val) && _.isArray(properties)) {
11333
- _.extend(val, _normalizeUIValues(_.pick(val, properties), ui));
11334
- /* Value is an object, and we got an array of embedded property names to normalize. */
11335
- _.each(properties, function (property) {
11336
- var propertyVal = val[property];
11337
- if (_.isString(propertyVal)) {
11338
- val[property] = _normalizeUIString(propertyVal, ui);
11339
- }
11340
- });
11341
- }
11342
- });
11343
- return hash;
11344
- };
11345
-
11346
- var UIMixin = {
11347
-
11348
- // normalize the keys of passed hash with the views `ui` selectors.
11349
- // `{"@ui.foo": "bar"}`
11350
- normalizeUIKeys: function normalizeUIKeys(hash) {
11351
- var uiBindings = this._getUIBindings();
11352
- return _normalizeUIKeys(hash, uiBindings);
11353
- },
11354
-
11355
-
11356
- // normalize the passed string with the views `ui` selectors.
11357
- // `"@ui.bar"`
11358
- normalizeUIString: function normalizeUIString(uiString) {
11359
- var uiBindings = this._getUIBindings();
11360
- return _normalizeUIString(uiString, uiBindings);
11361
- },
11362
-
11363
-
11364
- // normalize the values of passed hash with the views `ui` selectors.
11365
- // `{foo: "@ui.bar"}`
11366
- normalizeUIValues: function normalizeUIValues(hash, properties) {
11367
- var uiBindings = this._getUIBindings();
11368
- return _normalizeUIValues(hash, uiBindings, properties);
11369
- },
11370
- _getUIBindings: function _getUIBindings() {
11371
- var uiBindings = _.result(this, '_uiBindings');
11372
- var ui = _.result(this, 'ui');
11373
- return uiBindings || ui;
11374
- },
11375
-
11376
-
11377
- // This method binds the elements specified in the "ui" hash inside the view's code with
11378
- // the associated jQuery selectors.
11379
- _bindUIElements: function _bindUIElements() {
11380
- var _this = this;
11381
-
11382
- if (!this.ui) {
11383
- return;
11384
- }
11385
-
11386
- // store the ui hash in _uiBindings so they can be reset later
11387
- // and so re-rendering the view will be able to find the bindings
11388
- if (!this._uiBindings) {
11389
- this._uiBindings = this.ui;
11390
- }
11391
-
11392
- // get the bindings result, as a function or otherwise
11393
- var bindings = _.result(this, '_uiBindings');
11394
-
11395
- // empty the ui so we don't have anything to start with
11396
- this._ui = {};
11397
-
11398
- // bind each of the selectors
11399
- _.each(bindings, function (selector, key) {
11400
- _this._ui[key] = _this.$(selector);
11401
- });
11402
-
11403
- this.ui = this._ui;
11404
- },
11405
- _unbindUIElements: function _unbindUIElements() {
11406
- var _this2 = this;
11407
-
11408
- if (!this.ui || !this._uiBindings) {
11409
- return;
11410
- }
11411
-
11412
- // delete all of the existing ui bindings
11413
- _.each(this.ui, function ($el, name) {
11414
- delete _this2.ui[name];
11415
- });
11416
-
11417
- // reset the ui element to the original bindings configuration
11418
- this.ui = this._uiBindings;
11419
- delete this._uiBindings;
11420
- delete this._ui;
11421
- },
11422
- _getUI: function _getUI(name) {
11423
- return this._ui[name];
11424
- }
11425
- };
11426
-
11427
- // ViewMixin
11428
- // ---------
11429
-
11430
- // MixinOptions
11431
- // - behaviors
11432
- // - childViewEventPrefix
11433
- // - childViewEvents
11434
- // - childViewTriggers
11435
- // - collectionEvents
11436
- // - modelEvents
11437
- // - triggers
11438
- // - ui
11439
-
11440
-
11441
- var ViewMixin = {
11442
- supportsRenderLifecycle: true,
11443
- supportsDestroyLifecycle: true,
11444
-
11445
- _isDestroyed: false,
11446
-
11447
- isDestroyed: function isDestroyed() {
11448
- return !!this._isDestroyed;
11449
- },
11450
-
11451
-
11452
- _isRendered: false,
11453
-
11454
- isRendered: function isRendered() {
11455
- return !!this._isRendered;
11456
- },
11457
-
11458
-
11459
- _isAttached: false,
11460
-
11461
- isAttached: function isAttached() {
11462
- return !!this._isAttached;
11463
- },
11464
-
11465
-
11466
- // Overriding Backbone.View's `delegateEvents` to handle
11467
- // `events` and `triggers`
11468
- delegateEvents: function delegateEvents(eventsArg) {
11469
-
11470
- this._proxyBehaviorViewProperties();
11471
- this._buildEventProxies();
11472
-
11473
- var viewEvents = this._getEvents(eventsArg);
11474
-
11475
- if (typeof eventsArg === 'undefined') {
11476
- this.events = viewEvents;
11477
- }
11478
-
11479
- var combinedEvents = _.extend({}, this._getBehaviorEvents(), viewEvents, this._getBehaviorTriggers(), this.getTriggers());
11480
-
11481
- Backbone.View.prototype.delegateEvents.call(this, combinedEvents);
11482
-
11483
- return this;
11484
- },
11485
- _getEvents: function _getEvents(eventsArg) {
11486
- var events = eventsArg || this.events;
11487
-
11488
- if (_.isFunction(events)) {
11489
- return this.normalizeUIKeys(events.call(this));
11490
- }
11491
-
11492
- return this.normalizeUIKeys(events);
11493
- },
11494
-
11495
-
11496
- // Configure `triggers` to forward DOM events to view
11497
- // events. `triggers: {"click .foo": "do:foo"}`
11498
- getTriggers: function getTriggers() {
11499
- if (!this.triggers) {
11500
- return;
11501
- }
11502
-
11503
- // Allow `triggers` to be configured as a function
11504
- var triggers = this.normalizeUIKeys(_.result(this, 'triggers'));
11505
-
11506
- // Configure the triggers, prevent default
11507
- // action and stop propagation of DOM events
11508
- return this._getViewTriggers(this, triggers);
11509
- },
11510
-
11511
-
11512
- // Handle `modelEvents`, and `collectionEvents` configuration
11513
- delegateEntityEvents: function delegateEntityEvents() {
11514
- this._delegateEntityEvents(this.model, this.collection);
11515
-
11516
- // bind each behaviors model and collection events
11517
- this._delegateBehaviorEntityEvents();
11518
-
11519
- return this;
11520
- },
11521
-
11522
-
11523
- // Handle unbinding `modelEvents`, and `collectionEvents` configuration
11524
- undelegateEntityEvents: function undelegateEntityEvents() {
11525
- this._undelegateEntityEvents(this.model, this.collection);
11526
-
11527
- // unbind each behaviors model and collection events
11528
- this._undelegateBehaviorEntityEvents();
11529
-
11530
- return this;
11531
- },
11532
-
11533
-
11534
- // Handle destroying the view and its children.
11535
- destroy: function destroy() {
11536
- if (this._isDestroyed) {
11537
- return this;
11538
- }
11539
- var shouldTriggerDetach = !!this._isAttached;
11540
-
11541
- for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
11542
- args[_key] = arguments[_key];
11543
- }
11544
-
11545
- this.triggerMethod.apply(this, ['before:destroy', this].concat(args));
11546
- if (shouldTriggerDetach) {
11547
- this.triggerMethod('before:detach', this);
11548
- }
11549
-
11550
- // unbind UI elements
11551
- this.unbindUIElements();
11552
-
11553
- // remove the view from the DOM
11554
- this.removeEl(this.el);
11555
-
11556
- if (shouldTriggerDetach) {
11557
- this._isAttached = false;
11558
- this.triggerMethod('detach', this);
11559
- }
11560
-
11561
- // remove children after the remove to prevent extra paints
11562
- this._removeChildren();
11563
-
11564
- this._destroyBehaviors(args);
11565
-
11566
- this._isDestroyed = true;
11567
- this._isRendered = false;
11568
- this.triggerMethod.apply(this, ['destroy', this].concat(args));
11569
-
11570
- this.stopListening();
11571
-
11572
- return this;
11573
- },
11574
- bindUIElements: function bindUIElements() {
11575
- this._bindUIElements();
11576
- this._bindBehaviorUIElements();
11577
-
11578
- return this;
11579
- },
11580
-
11581
-
11582
- // This method unbinds the elements specified in the "ui" hash
11583
- unbindUIElements: function unbindUIElements() {
11584
- this._unbindUIElements();
11585
- this._unbindBehaviorUIElements();
11586
-
11587
- return this;
11588
- },
11589
- getUI: function getUI(name) {
11590
- return this._getUI(name);
11591
- },
11592
-
11593
-
11594
- // used as the prefix for child view events
11595
- // that are forwarded through the layoutview
11596
- childViewEventPrefix: 'childview',
11597
-
11598
- // import the `triggerMethod` to trigger events with corresponding
11599
- // methods if the method exists
11600
- triggerMethod: function triggerMethod() {
11601
- var ret = triggerMethod$1.apply(this, arguments);
11602
-
11603
- this._triggerEventOnBehaviors.apply(this, arguments);
11604
-
11605
- return ret;
11606
- },
11607
-
11608
-
11609
- // Cache `childViewEvents` and `childViewTriggers`
11610
- _buildEventProxies: function _buildEventProxies() {
11611
- this._childViewEvents = _.result(this, 'childViewEvents');
11612
- this._childViewTriggers = _.result(this, 'childViewTriggers');
11613
- },
11614
- _proxyChildViewEvents: function _proxyChildViewEvents(view) {
11615
- this.listenTo(view, 'all', this._childViewEventHandler);
11616
- },
11617
- _childViewEventHandler: function _childViewEventHandler(eventName) {
11618
- var childViewEvents = this.normalizeMethods(this._childViewEvents);
11619
-
11620
- // call collectionView childViewEvent if defined
11621
-
11622
- for (var _len2 = arguments.length, args = Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
11623
- args[_key2 - 1] = arguments[_key2];
11624
- }
11625
-
11626
- if (typeof childViewEvents !== 'undefined' && _.isFunction(childViewEvents[eventName])) {
11627
- childViewEvents[eventName].apply(this, args);
11628
- }
11629
-
11630
- // use the parent view's proxyEvent handlers
11631
- var childViewTriggers = this._childViewTriggers;
11632
-
11633
- // Call the event with the proxy name on the parent layout
11634
- if (childViewTriggers && _.isString(childViewTriggers[eventName])) {
11635
- this.triggerMethod.apply(this, [childViewTriggers[eventName]].concat(args));
11636
- }
11637
-
11638
- var prefix = _.result(this, 'childViewEventPrefix');
11639
-
11640
- if (prefix !== false) {
11641
- var childEventName = prefix + ':' + eventName;
11642
-
11643
- this.triggerMethod.apply(this, [childEventName].concat(args));
11644
- }
11645
- }
11646
- };
11647
-
11648
- _.extend(ViewMixin, DomMixin, BehaviorsMixin, CommonMixin, DelegateEntityEventsMixin, TriggersMixin, UIMixin);
11649
-
11650
- function destroyBackboneView(view) {
11651
- if (!view.supportsDestroyLifecycle) {
11652
- triggerMethodOn(view, 'before:destroy', view);
11653
- }
11654
-
11655
- var shouldTriggerDetach = !!view._isAttached;
11656
-
11657
- if (shouldTriggerDetach) {
11658
- triggerMethodOn(view, 'before:detach', view);
11659
- }
11660
-
11661
- view.remove();
11662
-
11663
- if (shouldTriggerDetach) {
11664
- view._isAttached = false;
11665
- triggerMethodOn(view, 'detach', view);
11666
- }
11667
-
11668
- view._isDestroyed = true;
11669
-
11670
- if (!view.supportsDestroyLifecycle) {
11671
- triggerMethodOn(view, 'destroy', view);
11672
- }
11673
- }
11674
-
11675
- // Region
11676
- // ------
11677
-
11678
- var ClassOptions$2 = ['allowMissingEl', 'parentEl', 'replaceElement'];
11679
-
11680
- var Region = MarionetteObject.extend({
11681
- cidPrefix: 'mnr',
11682
- replaceElement: false,
11683
- _isReplaced: false,
11684
-
11685
- constructor: function constructor(options) {
11686
- this._setOptions(options);
11687
-
11688
- this.mergeOptions(options, ClassOptions$2);
11689
-
11690
- // getOption necessary because options.el may be passed as undefined
11691
- this._initEl = this.el = this.getOption('el');
11692
-
11693
- // Handle when this.el is passed in as a $ wrapped element.
11694
- this.el = this.el instanceof Backbone.$ ? this.el[0] : this.el;
11695
-
11696
- if (!this.el) {
11697
- throw new MarionetteError({
11698
- name: 'NoElError',
11699
- message: 'An "el" must be specified for a region.'
11700
- });
11701
- }
11702
-
11703
- this.$el = this.getEl(this.el);
11704
- MarionetteObject.call(this, options);
11705
- },
11706
-
11707
-
11708
- // Displays a backbone view instance inside of the region. Handles calling the `render`
11709
- // method for you. Reads content directly from the `el` attribute. The `preventDestroy`
11710
- // option can be used to prevent a view from the old view being destroyed on show.
11711
- show: function show(view, options) {
11712
- if (!this._ensureElement(options)) {
11713
- return;
11714
- }
11715
-
11716
- view = this._getView(view, options);
11717
-
11718
- if (view === this.currentView) {
11719
- return this;
11720
- }
11721
-
11722
- this.triggerMethod('before:show', this, view, options);
11723
-
11724
- // Assume an attached view is already in the region for pre-existing DOM
11725
- if (!view._isAttached) {
11726
- this.empty(options);
11727
- }
11728
-
11729
- this._setupChildView(view);
11730
-
11731
- this._renderView(view);
11732
-
11733
- this._attachView(view, options);
11734
-
11735
- this.currentView = view;
11736
-
11737
- this.triggerMethod('show', this, view, options);
11738
- return this;
11739
- },
11740
- _setupChildView: function _setupChildView(view) {
11741
- monitorViewEvents(view);
11742
-
11743
- this._proxyChildViewEvents(view);
11744
-
11745
- // We need to listen for if a view is destroyed in a way other than through the region.
11746
- // If this happens we need to remove the reference to the currentView since once a view
11747
- // has been destroyed we can not reuse it.
11748
- view.on('destroy', this._empty, this);
11749
- },
11750
- _proxyChildViewEvents: function _proxyChildViewEvents(view) {
11751
- var parentView = this._parentView;
11752
-
11753
- if (!parentView) {
11754
- return;
11755
- }
11756
-
11757
- parentView._proxyChildViewEvents(view);
11758
- },
11759
- _renderView: function _renderView(view) {
11760
- if (view._isRendered) {
11761
- return;
11762
- }
11763
-
11764
- if (!view.supportsRenderLifecycle) {
11765
- triggerMethodOn(view, 'before:render', view);
11766
- }
11767
-
11768
- view.render();
11769
-
11770
- if (!view.supportsRenderLifecycle) {
11771
- view._isRendered = true;
11772
- triggerMethodOn(view, 'render', view);
11773
- }
11774
- },
11775
- _attachView: function _attachView(view) {
11776
- var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
11777
-
11778
- var shouldTriggerAttach = !view._isAttached && isNodeAttached(this.el);
11779
- var shouldReplaceEl = typeof options.replaceElement === 'undefined' ? !!_.result(this, 'replaceElement') : !!options.replaceElement;
11780
-
11781
- if (shouldTriggerAttach) {
11782
- triggerMethodOn(view, 'before:attach', view);
11783
- }
11784
-
11785
- if (shouldReplaceEl) {
11786
- this._replaceEl(view);
11787
- } else {
11788
- this.attachHtml(view);
11789
- }
11790
-
11791
- if (shouldTriggerAttach) {
11792
- view._isAttached = true;
11793
- triggerMethodOn(view, 'attach', view);
11794
- }
11795
- },
11796
- _ensureElement: function _ensureElement() {
11797
- var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
11798
-
11799
- if (!_.isObject(this.el)) {
11800
- this.$el = this.getEl(this.el);
11801
- this.el = this.$el[0];
11802
- }
11803
-
11804
- if (!this.$el || this.$el.length === 0) {
11805
- var allowMissingEl = typeof options.allowMissingEl === 'undefined' ? !!_.result(this, 'allowMissingEl') : !!options.allowMissingEl;
11806
-
11807
- if (allowMissingEl) {
11808
- return false;
11809
- } else {
11810
- throw new MarionetteError('An "el" must exist in DOM for this region ' + this.cid);
11811
- }
11812
- }
11813
- return true;
11814
- },
11815
- _getView: function _getView(view) {
11816
- if (!view) {
11817
- throw new MarionetteError({
11818
- name: 'ViewNotValid',
11819
- message: 'The view passed is undefined and therefore invalid. You must pass a view instance to show.'
11820
- });
11821
- }
11822
-
11823
- if (view._isDestroyed) {
11824
- throw new MarionetteError({
11825
- name: 'ViewDestroyedError',
11826
- message: 'View (cid: "' + view.cid + '") has already been destroyed and cannot be used.'
11827
- });
11828
- }
11829
-
11830
- if (view instanceof Backbone.View) {
11831
- return view;
11832
- }
11833
-
11834
- var viewOptions = this._getViewOptions(view);
11835
-
11836
- return new View(viewOptions);
11837
- },
11838
-
11839
-
11840
- // This allows for a template or a static string to be
11841
- // used as a template
11842
- _getViewOptions: function _getViewOptions(viewOptions) {
11843
- if (_.isFunction(viewOptions)) {
11844
- return { template: viewOptions };
11845
- }
11846
-
11847
- if (_.isObject(viewOptions)) {
11848
- return viewOptions;
11849
- }
11850
-
11851
- var template = function template() {
11852
- return viewOptions;
11853
- };
11854
-
11855
- return { template: template };
11856
- },
11857
-
11858
-
11859
- // Override this method to change how the region finds the DOM element that it manages. Return
11860
- // a jQuery selector object scoped to a provided parent el or the document if none exists.
11861
- getEl: function getEl(el) {
11862
- return this.findEls(el, _.result(this, 'parentEl'));
11863
- },
11864
- _replaceEl: function _replaceEl(view) {
11865
- // always restore the el to ensure the regions el is present before replacing
11866
- this._restoreEl();
11867
-
11868
- view.on('before:destroy', this._restoreEl, this);
11869
-
11870
- this.replaceEl(view.el, this.el);
11871
-
11872
- this._isReplaced = true;
11873
- },
11874
-
11875
-
11876
- // Restore the region's element in the DOM.
11877
- _restoreEl: function _restoreEl() {
11878
- // There is nothing to replace
11879
- if (!this._isReplaced) {
11880
- return;
11881
- }
11882
-
11883
- var view = this.currentView;
11884
-
11885
- if (!view) {
11886
- return;
11887
- }
11888
-
11889
- this.replaceEl(this.el, view.el);
11890
-
11891
- this._isReplaced = false;
11892
- },
11893
-
11894
-
11895
- // Check to see if the region's el was replaced.
11896
- isReplaced: function isReplaced() {
11897
- return !!this._isReplaced;
11898
- },
11899
-
11900
-
11901
- // Override this method to change how the new view is appended to the `$el` that the
11902
- // region is managing
11903
- attachHtml: function attachHtml(view) {
11904
- this.appendChildren(this.el, view.el);
11905
- },
11906
-
11907
-
11908
- // Destroy the current view, if there is one. If there is no current view, it does
11909
- // nothing and returns immediately.
11910
- empty: function empty() {
11911
- var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : { allowMissingEl: true };
11912
-
11913
- var view = this.currentView;
11914
-
11915
- // If there is no view in the region we should only detach current html
11916
- if (!view) {
11917
- if (this._ensureElement(options)) {
11918
- this.detachHtml();
11919
- }
11920
- return this;
11921
- }
11922
-
11923
- var shouldDestroy = !options.preventDestroy;
11924
-
11925
- if (!shouldDestroy) {
11926
- deprecate('The preventDestroy option is deprecated. Use Region#detachView');
11927
- }
11928
-
11929
- this._empty(view, shouldDestroy);
11930
- return this;
11931
- },
11932
- _empty: function _empty(view, shouldDestroy) {
11933
- view.off('destroy', this._empty, this);
11934
- this.triggerMethod('before:empty', this, view);
11935
-
11936
- this._restoreEl();
11937
-
11938
- delete this.currentView;
11939
-
11940
- if (!view._isDestroyed) {
11941
- this._removeView(view, shouldDestroy);
11942
- this._stopChildViewEvents(view);
11943
- }
11944
-
11945
- this.triggerMethod('empty', this, view);
11946
- },
11947
- _stopChildViewEvents: function _stopChildViewEvents(view) {
11948
- var parentView = this._parentView;
11949
-
11950
- if (!parentView) {
11951
- return;
11952
- }
11953
-
11954
- this._parentView.stopListening(view);
11955
- },
11956
- _removeView: function _removeView(view, shouldDestroy) {
11957
- if (!shouldDestroy) {
11958
- this._detachView(view);
11959
- return;
11960
- }
11961
-
11962
- if (view.destroy) {
11963
- view.destroy();
11964
- } else {
11965
- destroyBackboneView(view);
11966
- }
11967
- },
11968
- detachView: function detachView() {
11969
- var view = this.currentView;
11970
-
11971
- if (!view) {
11972
- return;
11973
- }
11974
-
11975
- this._empty(view);
11976
-
11977
- return view;
11978
- },
11979
- _detachView: function _detachView(view) {
11980
- var shouldTriggerDetach = !!view._isAttached;
11981
- if (shouldTriggerDetach) {
11982
- triggerMethodOn(view, 'before:detach', view);
11983
- }
11984
-
11985
- this.detachHtml();
11986
-
11987
- if (shouldTriggerDetach) {
11988
- view._isAttached = false;
11989
- triggerMethodOn(view, 'detach', view);
11990
- }
11991
- },
11992
-
11993
-
11994
- // Override this method to change how the region detaches current content
11995
- detachHtml: function detachHtml() {
11996
- this.detachContents(this.el);
11997
- },
11998
-
11999
-
12000
- // Checks whether a view is currently present within the region. Returns `true` if there is
12001
- // and `false` if no view is present.
12002
- hasView: function hasView() {
12003
- return !!this.currentView;
12004
- },
12005
-
12006
-
12007
- // Reset the region by destroying any existing view and clearing out the cached `$el`.
12008
- // The next time a view is shown via this region, the region will re-query the DOM for
12009
- // the region's `el`.
12010
- reset: function reset(options) {
12011
- this.empty(options);
12012
-
12013
- if (this.$el) {
12014
- this.el = this._initEl;
12015
- }
12016
-
12017
- delete this.$el;
12018
- return this;
12019
- },
12020
- destroy: function destroy(options) {
12021
- this.reset(options);
12022
- return MarionetteObject.prototype.destroy.apply(this, arguments);
12023
- }
12024
- });
12025
-
12026
- _.extend(Region.prototype, DomMixin);
12027
-
12028
- // return the region instance from the definition
12029
- var buildRegion = function (definition, defaults) {
12030
- if (definition instanceof Region) {
12031
- return definition;
12032
- }
12033
-
12034
- return buildRegionFromDefinition(definition, defaults);
12035
- };
12036
-
12037
- function buildRegionFromDefinition(definition, defaults) {
12038
- var opts = _.extend({}, defaults);
12039
-
12040
- if (_.isString(definition)) {
12041
- _.extend(opts, { el: definition });
12042
-
12043
- return buildRegionFromObject(opts);
12044
- }
12045
-
12046
- if (_.isFunction(definition)) {
12047
- _.extend(opts, { regionClass: definition });
12048
-
12049
- return buildRegionFromObject(opts);
12050
- }
12051
-
12052
- if (_.isObject(definition)) {
12053
- if (definition.selector) {
12054
- deprecate('The selector option on a Region definition object is deprecated. Use el to pass a selector string');
12055
- }
12056
-
12057
- _.extend(opts, { el: definition.selector }, definition);
12058
-
12059
- return buildRegionFromObject(opts);
12060
- }
12061
-
12062
- throw new MarionetteError({
12063
- message: 'Improper region configuration type.',
12064
- url: 'marionette.region.html#region-configuration-types'
12065
- });
12066
- }
12067
-
12068
- function buildRegionFromObject(definition) {
12069
- var RegionClass = definition.regionClass;
12070
-
12071
- var options = _.omit(definition, 'regionClass');
12072
-
12073
- return new RegionClass(options);
12074
- }
12075
-
12076
- // MixinOptions
12077
- // - regions
12078
- // - regionClass
12079
-
12080
- var RegionsMixin = {
12081
- regionClass: Region,
12082
-
12083
- // Internal method to initialize the regions that have been defined in a
12084
- // `regions` attribute on this View.
12085
- _initRegions: function _initRegions() {
12086
-
12087
- // init regions hash
12088
- this.regions = this.regions || {};
12089
- this._regions = {};
12090
-
12091
- this.addRegions(_.result(this, 'regions'));
12092
- },
12093
-
12094
-
12095
- // Internal method to re-initialize all of the regions by updating
12096
- // the `el` that they point to
12097
- _reInitRegions: function _reInitRegions() {
12098
- _invoke(this._regions, 'reset');
12099
- },
12100
-
12101
-
12102
- // Add a single region, by name, to the View
12103
- addRegion: function addRegion(name, definition) {
12104
- var regions = {};
12105
- regions[name] = definition;
12106
- return this.addRegions(regions)[name];
12107
- },
12108
-
12109
-
12110
- // Add multiple regions as a {name: definition, name2: def2} object literal
12111
- addRegions: function addRegions(regions) {
12112
- // If there's nothing to add, stop here.
12113
- if (_.isEmpty(regions)) {
12114
- return;
12115
- }
12116
-
12117
- // Normalize region selectors hash to allow
12118
- // a user to use the @ui. syntax.
12119
- regions = this.normalizeUIValues(regions, ['selector', 'el']);
12120
-
12121
- // Add the regions definitions to the regions property
12122
- this.regions = _.extend({}, this.regions, regions);
12123
-
12124
- return this._addRegions(regions);
12125
- },
12126
-
12127
-
12128
- // internal method to build and add regions
12129
- _addRegions: function _addRegions(regionDefinitions) {
12130
- var _this = this;
12131
-
12132
- var defaults = {
12133
- regionClass: this.regionClass,
12134
- parentEl: _.partial(_.result, this, 'el')
12135
- };
12136
-
12137
- return _.reduce(regionDefinitions, function (regions, definition, name) {
12138
- regions[name] = buildRegion(definition, defaults);
12139
- _this._addRegion(regions[name], name);
12140
- return regions;
12141
- }, {});
12142
- },
12143
- _addRegion: function _addRegion(region, name) {
12144
- this.triggerMethod('before:add:region', this, name, region);
12145
-
12146
- region._parentView = this;
12147
-
12148
- this._regions[name] = region;
12149
-
12150
- this.triggerMethod('add:region', this, name, region);
12151
- },
12152
-
12153
-
12154
- // Remove a single region from the View, by name
12155
- removeRegion: function removeRegion(name) {
12156
- var region = this._regions[name];
12157
-
12158
- this._removeRegion(region, name);
12159
-
12160
- return region;
12161
- },
12162
-
12163
-
12164
- // Remove all regions from the View
12165
- removeRegions: function removeRegions() {
12166
- var regions = this.getRegions();
12167
-
12168
- _.each(this._regions, _.bind(this._removeRegion, this));
12169
-
12170
- return regions;
12171
- },
12172
- _removeRegion: function _removeRegion(region, name) {
12173
- this.triggerMethod('before:remove:region', this, name, region);
12174
-
12175
- region.destroy();
12176
-
12177
- delete this.regions[name];
12178
- delete this._regions[name];
12179
-
12180
- this.triggerMethod('remove:region', this, name, region);
12181
- },
12182
-
12183
-
12184
- // Empty all regions in the region manager, but
12185
- // leave them attached
12186
- emptyRegions: function emptyRegions() {
12187
- var regions = this.getRegions();
12188
- _invoke(regions, 'empty');
12189
- return regions;
12190
- },
12191
-
12192
-
12193
- // Checks to see if view contains region
12194
- // Accepts the region name
12195
- // hasRegion('main')
12196
- hasRegion: function hasRegion(name) {
12197
- return !!this.getRegion(name);
12198
- },
12199
-
12200
-
12201
- // Provides access to regions
12202
- // Accepts the region name
12203
- // getRegion('main')
12204
- getRegion: function getRegion(name) {
12205
- return this._regions[name];
12206
- },
12207
-
12208
-
12209
- // Get all regions
12210
- getRegions: function getRegions() {
12211
- return _.clone(this._regions);
12212
- },
12213
- showChildView: function showChildView(name, view) {
12214
- var region = this.getRegion(name);
12215
-
12216
- for (var _len = arguments.length, args = Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) {
12217
- args[_key - 2] = arguments[_key];
12218
- }
12219
-
12220
- return region.show.apply(region, [view].concat(args));
12221
- },
12222
- detachChildView: function detachChildView(name) {
12223
- return this.getRegion(name).detachView();
12224
- },
12225
- getChildView: function getChildView(name) {
12226
- return this.getRegion(name).currentView;
12227
- }
12228
- };
12229
-
12230
- // Renderer
12231
- // --------
12232
-
12233
- // Render a template with data by passing in the template
12234
- // selector and the data to render.
12235
- var Renderer = {
12236
-
12237
- // Render a template with data. The `template` parameter is
12238
- // passed to the `TemplateCache` object to retrieve the
12239
- // template function. Override this method to provide your own
12240
- // custom rendering and template handling for all of Marionette.
12241
- render: function render(template, data) {
12242
- if (!template) {
12243
- throw new MarionetteError({
12244
- name: 'TemplateNotFoundError',
12245
- message: 'Cannot render the template since its false, null or undefined.'
12246
- });
12247
- }
12248
-
12249
- var templateFunc = _.isFunction(template) ? template : TemplateCache.get(template);
12250
-
12251
- return templateFunc(data);
12252
- }
12253
- };
12254
-
12255
- // View
12256
- // ---------
12257
-
12258
- var ClassOptions$1 = ['behaviors', 'childViewEventPrefix', 'childViewEvents', 'childViewTriggers', 'collectionEvents', 'events', 'modelEvents', 'regionClass', 'regions', 'template', 'templateContext', 'triggers', 'ui'];
12259
-
12260
- // The standard view. Includes view events, automatic rendering
12261
- // of Underscore templates, nested views, and more.
12262
- var View = Backbone.View.extend({
12263
- constructor: function constructor(options) {
12264
- this.render = _.bind(this.render, this);
12265
-
12266
- this._setOptions(options);
12267
-
12268
- this.mergeOptions(options, ClassOptions$1);
12269
-
12270
- monitorViewEvents(this);
12271
-
12272
- this._initBehaviors();
12273
- this._initRegions();
12274
-
12275
- var args = Array.prototype.slice.call(arguments);
12276
- args[0] = this.options;
12277
- Backbone.View.prototype.constructor.apply(this, args);
12278
-
12279
- this.delegateEntityEvents();
12280
- },
12281
-
12282
-
12283
- // Serialize the view's model *or* collection, if
12284
- // it exists, for the template
12285
- serializeData: function serializeData() {
12286
- if (!this.model && !this.collection) {
12287
- return {};
12288
- }
12289
-
12290
- // If we have a model, we serialize that
12291
- if (this.model) {
12292
- return this.serializeModel();
12293
- }
12294
-
12295
- // Otherwise, we serialize the collection,
12296
- // making it available under the `items` property
12297
- return {
12298
- items: this.serializeCollection()
12299
- };
12300
- },
12301
-
12302
-
12303
- // Prepares the special `model` property of a view
12304
- // for being displayed in the template. By default
12305
- // we simply clone the attributes. Override this if
12306
- // you need a custom transformation for your view's model
12307
- serializeModel: function serializeModel() {
12308
- if (!this.model) {
12309
- return {};
12310
- }
12311
- return _.clone(this.model.attributes);
12312
- },
12313
-
12314
-
12315
- // Serialize a collection by cloning each of
12316
- // its model's attributes
12317
- serializeCollection: function serializeCollection() {
12318
- if (!this.collection) {
12319
- return {};
12320
- }
12321
- return this.collection.map(function (model) {
12322
- return _.clone(model.attributes);
12323
- });
12324
- },
12325
-
12326
-
12327
- // Overriding Backbone.View's `setElement` to handle
12328
- // if an el was previously defined. If so, the view might be
12329
- // rendered or attached on setElement.
12330
- setElement: function setElement() {
12331
- var hasEl = !!this.el;
12332
-
12333
- Backbone.View.prototype.setElement.apply(this, arguments);
12334
-
12335
- if (hasEl) {
12336
- this._isRendered = !!this.$el.length;
12337
- this._isAttached = isNodeAttached(this.el);
12338
- }
12339
-
12340
- if (this._isRendered) {
12341
- this.bindUIElements();
12342
- }
12343
-
12344
- return this;
12345
- },
12346
-
12347
-
12348
- // Render the view, defaulting to underscore.js templates.
12349
- // You can override this in your view definition to provide
12350
- // a very specific rendering for your view. In general, though,
12351
- // you should override the `Marionette.Renderer` object to
12352
- // change how Marionette renders views.
12353
- // Subsequent renders after the first will re-render all nested
12354
- // views.
12355
- render: function render() {
12356
- if (this._isDestroyed) {
12357
- return this;
12358
- }
12359
-
12360
- this.triggerMethod('before:render', this);
12361
-
12362
- // If this is not the first render call, then we need to
12363
- // re-initialize the `el` for each region
12364
- if (this._isRendered) {
12365
- this._reInitRegions();
12366
- }
12367
-
12368
- this._renderTemplate();
12369
- this.bindUIElements();
12370
-
12371
- this._isRendered = true;
12372
- this.triggerMethod('render', this);
12373
-
12374
- return this;
12375
- },
12376
-
12377
-
12378
- // Internal method to render the template with the serialized data
12379
- // and template context via the `Marionette.Renderer` object.
12380
- _renderTemplate: function _renderTemplate() {
12381
- var template = this.getTemplate();
12382
-
12383
- // Allow template-less views
12384
- if (template === false) {
12385
- return;
12386
- }
12387
-
12388
- // Add in entity data and template context
12389
- var data = this.mixinTemplateContext(this.serializeData());
12390
-
12391
- // Render and add to el
12392
- var html = Renderer.render(template, data, this);
12393
- this.attachElContent(html);
12394
- },
12395
-
12396
-
12397
- // Get the template for this view
12398
- // instance. You can set a `template` attribute in the view
12399
- // definition or pass a `template: "whatever"` parameter in
12400
- // to the constructor options.
12401
- getTemplate: function getTemplate() {
12402
- return this.template;
12403
- },
12404
-
12405
-
12406
- // Mix in template context methods. Looks for a
12407
- // `templateContext` attribute, which can either be an
12408
- // object literal, or a function that returns an object
12409
- // literal. All methods and attributes from this object
12410
- // are copies to the object passed in.
12411
- mixinTemplateContext: function mixinTemplateContext() {
12412
- var target = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
12413
-
12414
- var templateContext = _.result(this, 'templateContext');
12415
- return _.extend(target, templateContext);
12416
- },
12417
-
12418
-
12419
- // Attaches the content of a given view.
12420
- // This method can be overridden to optimize rendering,
12421
- // or to render in a non standard way.
12422
- //
12423
- // For example, using `innerHTML` instead of `$el.html`
12424
- //
12425
- // ```js
12426
- // attachElContent(html) {
12427
- // this.el.innerHTML = html;
12428
- // return this;
12429
- // }
12430
- // ```
12431
- attachElContent: function attachElContent(html) {
12432
- this.setInnerContent(this.el, html);
12433
-
12434
- return this;
12435
- },
12436
-
12437
-
12438
- // called by ViewMixin destroy
12439
- _removeChildren: function _removeChildren() {
12440
- this.removeRegions();
12441
- },
12442
- _getImmediateChildren: function _getImmediateChildren() {
12443
- return _.chain(this.getRegions()).map('currentView').compact().value();
12444
- }
12445
- });
12446
-
12447
- _.extend(View.prototype, ViewMixin, RegionsMixin);
12448
-
12449
- // Mix in methods from Underscore, for iteration, and other
12450
- // collection related features.
12451
- // Borrowing this code from Backbone.Collection:
12452
- // https://github.com/jashkenas/backbone/blob/1.1.2/backbone.js#L962
12453
-
12454
- var methods = ['forEach', 'each', 'map', 'find', 'detect', 'filter', 'select', 'reject', 'every', 'all', 'some', 'any', 'include', 'contains', 'invoke', 'toArray', 'first', 'initial', 'rest', 'last', 'without', 'isEmpty', 'pluck', 'reduce'];
12455
-
12456
- var emulateCollection = function emulateCollection(object, listProperty) {
12457
- _.each(methods, function (method) {
12458
- object[method] = function () {
12459
- var list = _.values(_.result(this, listProperty));
12460
- var args = [list].concat(_.toArray(arguments));
12461
- return _[method].apply(_, args);
12462
- };
12463
- });
12464
- };
12465
-
12466
- // Provide a container to store, retrieve and
12467
- // shut down child views.
12468
- var Container = function Container(views) {
12469
- this._views = {};
12470
- this._indexByModel = {};
12471
- this._indexByCustom = {};
12472
- this._updateLength();
12473
-
12474
- _.each(views, _.bind(this.add, this));
12475
- };
12476
-
12477
- emulateCollection(Container.prototype, '_views');
12478
-
12479
- // Container Methods
12480
- // -----------------
12481
-
12482
- _.extend(Container.prototype, {
12483
-
12484
- // Add a view to this container. Stores the view
12485
- // by `cid` and makes it searchable by the model
12486
- // cid (and model itself). Optionally specify
12487
- // a custom key to store an retrieve the view.
12488
- add: function add(view, customIndex) {
12489
- return this._add(view, customIndex)._updateLength();
12490
- },
12491
-
12492
-
12493
- // To be used when avoiding call _updateLength
12494
- // When you are done adding all your new views
12495
- // call _updateLength
12496
- _add: function _add(view, customIndex) {
12497
- var viewCid = view.cid;
12498
-
12499
- // store the view
12500
- this._views[viewCid] = view;
12501
-
12502
- // index it by model
12503
- if (view.model) {
12504
- this._indexByModel[view.model.cid] = viewCid;
12505
- }
12506
-
12507
- // index by custom
12508
- if (customIndex) {
12509
- this._indexByCustom[customIndex] = viewCid;
12510
- }
12511
-
12512
- return this;
12513
- },
12514
-
12515
-
12516
- // Find a view by the model that was attached to
12517
- // it. Uses the model's `cid` to find it.
12518
- findByModel: function findByModel(model) {
12519
- return this.findByModelCid(model.cid);
12520
- },
12521
-
12522
-
12523
- // Find a view by the `cid` of the model that was attached to
12524
- // it. Uses the model's `cid` to find the view `cid` and
12525
- // retrieve the view using it.
12526
- findByModelCid: function findByModelCid(modelCid) {
12527
- var viewCid = this._indexByModel[modelCid];
12528
- return this.findByCid(viewCid);
12529
- },
12530
-
12531
-
12532
- // Find a view by a custom indexer.
12533
- findByCustom: function findByCustom(index) {
12534
- var viewCid = this._indexByCustom[index];
12535
- return this.findByCid(viewCid);
12536
- },
12537
-
12538
-
12539
- // Find by index. This is not guaranteed to be a
12540
- // stable index.
12541
- findByIndex: function findByIndex(index) {
12542
- return _.values(this._views)[index];
12543
- },
12544
-
12545
-
12546
- // retrieve a view by its `cid` directly
12547
- findByCid: function findByCid(cid) {
12548
- return this._views[cid];
12549
- },
12550
-
12551
-
12552
- // Remove a view
12553
- remove: function remove(view) {
12554
- return this._remove(view)._updateLength();
12555
- },
12556
-
12557
-
12558
- // To be used when avoiding call _updateLength
12559
- // When you are done adding all your new views
12560
- // call _updateLength
12561
- _remove: function _remove(view) {
12562
- var viewCid = view.cid;
12563
-
12564
- // delete model index
12565
- if (view.model) {
12566
- delete this._indexByModel[view.model.cid];
12567
- }
12568
-
12569
- // delete custom index
12570
- _.some(this._indexByCustom, _.bind(function (cid, key) {
12571
- if (cid === viewCid) {
12572
- delete this._indexByCustom[key];
12573
- return true;
12574
- }
12575
- }, this));
12576
-
12577
- // remove the view from the container
12578
- delete this._views[viewCid];
12579
-
12580
- return this;
12581
- },
12582
-
12583
-
12584
- // Update the `.length` attribute on this container
12585
- _updateLength: function _updateLength() {
12586
- this.length = _.size(this._views);
12587
-
12588
- return this;
12589
- }
12590
- });
12591
-
12592
- // Collection View
12593
- // ---------------
12594
-
12595
- var ClassOptions$3 = ['behaviors', 'childView', 'childViewEventPrefix', 'childViewEvents', 'childViewOptions', 'childViewTriggers', 'collectionEvents', 'events', 'filter', 'emptyView', 'emptyViewOptions', 'modelEvents', 'reorderOnSort', 'sort', 'triggers', 'ui', 'viewComparator'];
12596
-
12597
- // A view that iterates over a Backbone.Collection
12598
- // and renders an individual child view for each model.
12599
- var CollectionView = Backbone.View.extend({
12600
-
12601
- // flag for maintaining the sorted order of the collection
12602
- sort: true,
12603
-
12604
- // constructor
12605
- // option to pass `{sort: false}` to prevent the `CollectionView` from
12606
- // maintaining the sorted order of the collection.
12607
- // This will fallback onto appending childView's to the end.
12608
- //
12609
- // option to pass `{viewComparator: compFunction()}` to allow the `CollectionView`
12610
- // to use a custom sort order for the collection.
12611
- constructor: function constructor(options) {
12612
- this.render = _.bind(this.render, this);
12613
-
12614
- this._setOptions(options);
12615
-
12616
- this.mergeOptions(options, ClassOptions$3);
12617
-
12618
- monitorViewEvents(this);
12619
-
12620
- this._initBehaviors();
12621
- this.once('render', this._initialEvents);
12622
- this._initChildViewStorage();
12623
- this._bufferedChildren = [];
12624
-
12625
- var args = Array.prototype.slice.call(arguments);
12626
- args[0] = this.options;
12627
- Backbone.View.prototype.constructor.apply(this, args);
12628
-
12629
- this.delegateEntityEvents();
12630
- },
12631
-
12632
-
12633
- // Instead of inserting elements one by one into the page, it's much more performant to insert
12634
- // elements into a document fragment and then insert that document fragment into the page
12635
- _startBuffering: function _startBuffering() {
12636
- this._isBuffering = true;
12637
- },
12638
- _endBuffering: function _endBuffering() {
12639
- var shouldTriggerAttach = !!this._isAttached;
12640
- var triggerOnChildren = shouldTriggerAttach ? this._getImmediateChildren() : [];
12641
-
12642
- this._isBuffering = false;
12643
-
12644
- _.each(triggerOnChildren, function (child) {
12645
- triggerMethodOn(child, 'before:attach', child);
12646
- });
12647
-
12648
- this.attachBuffer(this, this._createBuffer());
12649
-
12650
- _.each(triggerOnChildren, function (child) {
12651
- child._isAttached = true;
12652
- triggerMethodOn(child, 'attach', child);
12653
- });
12654
-
12655
- this._bufferedChildren = [];
12656
- },
12657
- _getImmediateChildren: function _getImmediateChildren() {
12658
- return _.values(this.children._views);
12659
- },
12660
-
12661
-
12662
- // Configured the initial events that the collection view binds to.
12663
- _initialEvents: function _initialEvents() {
12664
- if (this.collection) {
12665
- this.listenTo(this.collection, 'add', this._onCollectionAdd);
12666
- this.listenTo(this.collection, 'update', this._onCollectionUpdate);
12667
- this.listenTo(this.collection, 'reset', this.render);
12668
-
12669
- if (this.sort) {
12670
- this.listenTo(this.collection, 'sort', this._sortViews);
12671
- }
12672
- }
12673
- },
12674
-
12675
-
12676
- // Handle a child added to the collection
12677
- _onCollectionAdd: function _onCollectionAdd(child, collection, opts) {
12678
- // `index` is present when adding with `at` since BB 1.2; indexOf fallback for < 1.2
12679
- var index = opts.at !== undefined && (opts.index || collection.indexOf(child));
12680
-
12681
- // When filtered or when there is no initial index, calculate index.
12682
- if (this.filter || index === false) {
12683
- index = _.indexOf(this._filteredSortedModels(index), child);
12684
- }
12685
-
12686
- if (this._shouldAddChild(child, index)) {
12687
- this._destroyEmptyView();
12688
- this._addChild(child, index);
12689
- }
12690
- },
12691
-
12692
-
12693
- // Handle collection update model removals
12694
- _onCollectionUpdate: function _onCollectionUpdate(collection, options) {
12695
- var changes = options.changes;
12696
- this._removeChildModels(changes.removed);
12697
- },
12698
-
12699
-
12700
- // Remove the child views and destroy them.
12701
- // This function also updates the indices of later views
12702
- // in the collection in order to keep the children in sync with the collection.
12703
- // "models" is an array of models and the corresponding views
12704
- // will be removed and destroyed from the CollectionView
12705
- _removeChildModels: function _removeChildModels(models) {
12706
- // Used to determine where to update the remaining
12707
- // sibling view indices after these views are removed.
12708
- var removedViews = this._getRemovedViews(models);
12709
-
12710
- if (!removedViews.length) {
12711
- return;
12712
- }
12713
-
12714
- this.children._updateLength();
12715
-
12716
- // decrement the index of views after this one
12717
- this._updateIndices(removedViews, false);
12718
-
12719
- if (this.isEmpty()) {
12720
- this._showEmptyView();
12721
- }
12722
- },
12723
-
12724
-
12725
- // Returns the views that will be used for re-indexing
12726
- // through CollectionView#_updateIndices.
12727
- _getRemovedViews: function _getRemovedViews(models) {
12728
- var _this = this;
12729
-
12730
- // Returning a view means something was removed.
12731
- return _.reduce(models, function (removingViews, model) {
12732
- var view = model && _this.children.findByModel(model);
12733
-
12734
- if (!view || view._isDestroyed) {
12735
- return removingViews;
12736
- }
12737
-
12738
- _this._removeChildView(view);
12739
-
12740
- removingViews.push(view);
12741
-
12742
- return removingViews;
12743
- }, []);
12744
- },
12745
- _removeChildView: function _removeChildView(view) {
12746
- this.triggerMethod('before:remove:child', this, view);
12747
-
12748
- this.children._remove(view);
12749
- if (view.destroy) {
12750
- view.destroy();
12751
- } else {
12752
- destroyBackboneView(view);
12753
- }
12754
-
12755
- this.stopListening(view);
12756
- this.triggerMethod('remove:child', this, view);
12757
- },
12758
-
12759
-
12760
- // Overriding Backbone.View's `setElement` to handle
12761
- // if an el was previously defined. If so, the view might be
12762
- // attached on setElement.
12763
- setElement: function setElement() {
12764
- var hasEl = !!this.el;
12765
-
12766
- Backbone.View.prototype.setElement.apply(this, arguments);
12767
-
12768
- if (hasEl) {
12769
- this._isAttached = isNodeAttached(this.el);
12770
- }
12771
-
12772
- return this;
12773
- },
12774
-
12775
-
12776
- // Render children views. Override this method to provide your own implementation of a
12777
- // render function for the collection view.
12778
- render: function render() {
12779
- if (this._isDestroyed) {
12780
- return this;
12781
- }
12782
- this.triggerMethod('before:render', this);
12783
- this._renderChildren();
12784
- this._isRendered = true;
12785
- this.triggerMethod('render', this);
12786
- return this;
12787
- },
12788
-
12789
-
12790
- // An efficient rendering used for filtering. Instead of modifying the whole DOM for the
12791
- // collection view, we are only adding or removing the related childrenViews.
12792
- setFilter: function setFilter(filter) {
12793
- var _ref = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {},
12794
- preventRender = _ref.preventRender;
12795
-
12796
- var canBeRendered = this._isRendered && !this._isDestroyed;
12797
- var filterChanged = this.filter !== filter;
12798
- var shouldRender = canBeRendered && filterChanged && !preventRender;
12799
-
12800
- if (shouldRender) {
12801
- var previousModels = this._filteredSortedModels();
12802
- this.filter = filter;
12803
- var models = this._filteredSortedModels();
12804
- this._applyModelDeltas(models, previousModels);
12805
- } else {
12806
- this.filter = filter;
12807
- }
12808
-
12809
- return this;
12810
- },
12811
-
12812
-
12813
- // `removeFilter` is actually an alias for removing filters.
12814
- removeFilter: function removeFilter(options) {
12815
- return this.setFilter(null, options);
12816
- },
12817
-
12818
-
12819
- // Calculate and apply difference by cid between `models` and `previousModels`.
12820
- _applyModelDeltas: function _applyModelDeltas(models, previousModels) {
12821
- var _this2 = this;
12822
-
12823
- var currentIds = {};
12824
- _.each(models, function (model, index) {
12825
- var addedChildNotExists = !_this2.children.findByModel(model);
12826
- if (addedChildNotExists) {
12827
- _this2._onCollectionAdd(model, _this2.collection, { at: index });
12828
- }
12829
- currentIds[model.cid] = true;
12830
- });
12831
-
12832
- var removeModels = _.filter(previousModels, function (prevModel) {
12833
- return !currentIds[prevModel.cid] && _this2.children.findByModel(prevModel);
12834
- });
12835
-
12836
- this._removeChildModels(removeModels);
12837
- },
12838
-
12839
-
12840
- // Reorder DOM after sorting. When your element's rendering do not use their index,
12841
- // you can pass reorderOnSort: true to only reorder the DOM after a sort instead of
12842
- // rendering all the collectionView.
12843
- reorder: function reorder() {
12844
- var _this3 = this;
12845
-
12846
- var children = this.children;
12847
- var models = this._filteredSortedModels();
12848
-
12849
- if (!models.length && this._showingEmptyView) {
12850
- return this;
12851
- }
12852
-
12853
- var anyModelsAdded = _.some(models, function (model) {
12854
- return !children.findByModel(model);
12855
- });
12856
-
12857
- // If there are any new models added due to filtering we need to add child views,
12858
- // so render as normal.
12859
- if (anyModelsAdded) {
12860
- this.render();
12861
- } else {
12862
- (function () {
12863
-
12864
- var filteredOutModels = [];
12865
-
12866
- // Get the DOM nodes in the same order as the models and
12867
- // find the model that were children before but aren't in this new order.
12868
- var elsToReorder = children.reduce(function (viewEls, view) {
12869
- var index = _.indexOf(models, view.model);
12870
-
12871
- if (index === -1) {
12872
- filteredOutModels.push(view.model);
12873
- return viewEls;
12874
- }
12875
-
12876
- view._index = index;
12877
-
12878
- viewEls[index] = view.el;
12879
-
12880
- return viewEls;
12881
- }, new Array(models.length));
12882
-
12883
- _this3.triggerMethod('before:reorder', _this3);
12884
-
12885
- // Since append moves elements that are already in the DOM, appending the elements
12886
- // will effectively reorder them.
12887
- _this3._appendReorderedChildren(elsToReorder);
12888
-
12889
- // remove any views that have been filtered out
12890
- _this3._removeChildModels(filteredOutModels);
12891
-
12892
- _this3.triggerMethod('reorder', _this3);
12893
- })();
12894
- }
12895
- return this;
12896
- },
12897
-
12898
-
12899
- // Render view after sorting. Override this method to change how the view renders
12900
- // after a `sort` on the collection.
12901
- resortView: function resortView() {
12902
- if (this.reorderOnSort) {
12903
- this.reorder();
12904
- } else {
12905
- this._renderChildren();
12906
- }
12907
- return this;
12908
- },
12909
-
12910
-
12911
- // Internal method. This checks for any changes in the order of the collection.
12912
- // If the index of any view doesn't match, it will render.
12913
- _sortViews: function _sortViews() {
12914
- var _this4 = this;
12915
-
12916
- var models = this._filteredSortedModels();
12917
-
12918
- // check for any changes in sort order of views
12919
- var orderChanged = _.find(models, function (item, index) {
12920
- var view = _this4.children.findByModel(item);
12921
- return !view || view._index !== index;
12922
- });
12923
-
12924
- if (orderChanged) {
12925
- this.resortView();
12926
- }
12927
- },
12928
-
12929
-
12930
- // Internal reference to what index a `emptyView` is.
12931
- _emptyViewIndex: -1,
12932
-
12933
- // Internal method. Separated so that CompositeView can append to the childViewContainer
12934
- // if necessary
12935
- _appendReorderedChildren: function _appendReorderedChildren(children) {
12936
- this.appendChildren(this.el, children);
12937
- },
12938
-
12939
-
12940
- // Internal method. Separated so that CompositeView can have more control over events
12941
- // being triggered, around the rendering process
12942
- _renderChildren: function _renderChildren() {
12943
- if (this._isRendered) {
12944
- this._destroyEmptyView();
12945
- this._destroyChildren();
12946
- }
12947
-
12948
- var models = this._filteredSortedModels();
12949
- if (this.isEmpty({ processedModels: models })) {
12950
- this._showEmptyView();
12951
- } else {
12952
- this.triggerMethod('before:render:children', this);
12953
- this._startBuffering();
12954
- this._showCollection(models);
12955
- this._endBuffering();
12956
- this.triggerMethod('render:children', this);
12957
- }
12958
- },
12959
- _createView: function _createView(model, index) {
12960
- var ChildView = this._getChildView(model);
12961
- var childViewOptions = this._getChildViewOptions(model, index);
12962
- var view = this.buildChildView(model, ChildView, childViewOptions);
12963
- return view;
12964
- },
12965
- _setupChildView: function _setupChildView(view, index) {
12966
- monitorViewEvents(view);
12967
-
12968
- // set up the child view event forwarding
12969
- this._proxyChildViewEvents(view);
12970
-
12971
- if (this.sort) {
12972
- view._index = index;
12973
- }
12974
- },
12975
-
12976
-
12977
- // Internal method to loop through collection and show each child view.
12978
- _showCollection: function _showCollection(models) {
12979
- _.each(models, _.bind(this._addChild, this));
12980
- this.children._updateLength();
12981
- },
12982
-
12983
-
12984
- // Allow the collection to be sorted by a custom view comparator
12985
- _filteredSortedModels: function _filteredSortedModels(addedAt) {
12986
- if (!this.collection || !this.collection.length) {
12987
- return [];
12988
- }
12989
-
12990
- var viewComparator = this.getViewComparator();
12991
- var models = this.collection.models;
12992
- addedAt = Math.min(Math.max(addedAt, 0), models.length - 1);
12993
-
12994
- if (viewComparator) {
12995
- var addedModel = void 0;
12996
- // Preserve `at` location, even for a sorted view
12997
- if (addedAt) {
12998
- addedModel = models[addedAt];
12999
- models = models.slice(0, addedAt).concat(models.slice(addedAt + 1));
13000
- }
13001
- models = this._sortModelsBy(models, viewComparator);
13002
- if (addedModel) {
13003
- models.splice(addedAt, 0, addedModel);
13004
- }
13005
- }
13006
-
13007
- // Filter after sorting in case the filter uses the index
13008
- models = this._filterModels(models);
13009
-
13010
- return models;
13011
- },
13012
- getViewComparator: function getViewComparator() {
13013
- return this.viewComparator;
13014
- },
13015
-
13016
-
13017
- // Filter an array of models, if a filter exists
13018
- _filterModels: function _filterModels(models) {
13019
- var _this5 = this;
13020
-
13021
- if (this.filter) {
13022
- models = _.filter(models, function (model, index) {
13023
- return _this5._shouldAddChild(model, index);
13024
- });
13025
- }
13026
- return models;
13027
- },
13028
- _sortModelsBy: function _sortModelsBy(models, comparator) {
13029
- if (typeof comparator === 'string') {
13030
- return _.sortBy(models, function (model) {
13031
- return model.get(comparator);
13032
- });
13033
- } else if (comparator.length === 1) {
13034
- return _.sortBy(models, _.bind(comparator, this));
13035
- } else {
13036
- return _.clone(models).sort(_.bind(comparator, this));
13037
- }
13038
- },
13039
-
13040
-
13041
- // Internal method to show an empty view in place of a collection of child views,
13042
- // when the collection is empty
13043
- _showEmptyView: function _showEmptyView() {
13044
- var EmptyView = this._getEmptyView();
13045
-
13046
- if (EmptyView && !this._showingEmptyView) {
13047
- this._showingEmptyView = true;
13048
-
13049
- var model = new Backbone.Model();
13050
- var emptyViewOptions = this.emptyViewOptions || this.childViewOptions;
13051
- if (_.isFunction(emptyViewOptions)) {
13052
- emptyViewOptions = emptyViewOptions.call(this, model, this._emptyViewIndex);
13053
- }
13054
-
13055
- var view = this.buildChildView(model, EmptyView, emptyViewOptions);
13056
-
13057
- this.triggerMethod('before:render:empty', this, view);
13058
- this.addChildView(view, 0);
13059
- this.triggerMethod('render:empty', this, view);
13060
- }
13061
- },
13062
-
13063
-
13064
- // Internal method to destroy an existing emptyView instance if one exists. Called when
13065
- // a collection view has been rendered empty, and then a child is added to the collection.
13066
- _destroyEmptyView: function _destroyEmptyView() {
13067
- if (this._showingEmptyView) {
13068
- this.triggerMethod('before:remove:empty', this);
13069
-
13070
- this._destroyChildren();
13071
- delete this._showingEmptyView;
13072
-
13073
- this.triggerMethod('remove:empty', this);
13074
- }
13075
- },
13076
-
13077
-
13078
- // Retrieve the empty view class
13079
- _getEmptyView: function _getEmptyView() {
13080
- var emptyView = this.emptyView;
13081
-
13082
- if (!emptyView) {
13083
- return;
13084
- }
13085
-
13086
- return this._getView(emptyView);
13087
- },
13088
-
13089
-
13090
- // Retrieve the `childView` class
13091
- // The `childView` property can be either a view class or a function that
13092
- // returns a view class. If it is a function, it will receive the model that
13093
- // will be passed to the view instance (created from the returned view class)
13094
- _getChildView: function _getChildView(child) {
13095
- var childView = this.childView;
13096
-
13097
- if (!childView) {
13098
- throw new MarionetteError({
13099
- name: 'NoChildViewError',
13100
- message: 'A "childView" must be specified'
13101
- });
13102
- }
13103
-
13104
- childView = this._getView(childView, child);
13105
-
13106
- if (!childView) {
13107
- throw new MarionetteError({
13108
- name: 'InvalidChildViewError',
13109
- message: '"childView" must be a view class or a function that returns a view class'
13110
- });
13111
- }
13112
-
13113
- return childView;
13114
- },
13115
-
13116
-
13117
- // First check if the `view` is a view class (the common case)
13118
- // Then check if it's a function (which we assume that returns a view class)
13119
- _getView: function _getView(view, child) {
13120
- if (view.prototype instanceof Backbone.View || view === Backbone.View) {
13121
- return view;
13122
- } else if (_.isFunction(view)) {
13123
- return view.call(this, child);
13124
- }
13125
- },
13126
-
13127
-
13128
- // Internal method for building and adding a child view
13129
- _addChild: function _addChild(child, index) {
13130
- var view = this._createView(child, index);
13131
- this.addChildView(view, index);
13132
-
13133
- return view;
13134
- },
13135
- _getChildViewOptions: function _getChildViewOptions(child, index) {
13136
- if (_.isFunction(this.childViewOptions)) {
13137
- return this.childViewOptions(child, index);
13138
- }
13139
-
13140
- return this.childViewOptions;
13141
- },
13142
-
13143
-
13144
- // Render the child's view and add it to the HTML for the collection view at a given index.
13145
- // This will also update the indices of later views in the collection in order to keep the
13146
- // children in sync with the collection.
13147
- addChildView: function addChildView(view, index) {
13148
- this.triggerMethod('before:add:child', this, view);
13149
- this._setupChildView(view, index);
13150
-
13151
- // Store the child view itself so we can properly remove and/or destroy it later
13152
- if (this._isBuffering) {
13153
- // Add to children, but don't update children's length.
13154
- this.children._add(view);
13155
- } else {
13156
- // increment indices of views after this one
13157
- this._updateIndices(view, true);
13158
- this.children.add(view);
13159
- }
13160
-
13161
- this._renderView(view);
13162
-
13163
- this._attachView(view, index);
13164
-
13165
- this.triggerMethod('add:child', this, view);
13166
-
13167
- return view;
13168
- },
13169
-
13170
-
13171
- // Internal method. This decrements or increments the indices of views after the added/removed
13172
- // view to keep in sync with the collection.
13173
- _updateIndices: function _updateIndices(views, increment) {
13174
- if (!this.sort) {
13175
- return;
13176
- }
13177
-
13178
- if (!increment) {
13179
- _.each(_.sortBy(this.children._views, '_index'), function (view, index) {
13180
- view._index = index;
13181
- });
13182
-
13183
- return;
13184
- }
13185
-
13186
- var view = _.isArray(views) ? _.max(views, '_index') : views;
13187
-
13188
- if (_.isObject(view)) {
13189
- // update the indexes of views after this one
13190
- this.children.each(function (laterView) {
13191
- if (laterView._index >= view._index) {
13192
- laterView._index += 1;
13193
- }
13194
- });
13195
- }
13196
- },
13197
- _renderView: function _renderView(view) {
13198
- if (view._isRendered) {
13199
- return;
13200
- }
13201
-
13202
- if (!view.supportsRenderLifecycle) {
13203
- triggerMethodOn(view, 'before:render', view);
13204
- }
13205
-
13206
- view.render();
13207
-
13208
- if (!view.supportsRenderLifecycle) {
13209
- view._isRendered = true;
13210
- triggerMethodOn(view, 'render', view);
13211
- }
13212
- },
13213
- _attachView: function _attachView(view, index) {
13214
- // Only trigger attach if already attached and not buffering,
13215
- // otherwise _endBuffering() or Region#show() handles this.
13216
- var shouldTriggerAttach = !view._isAttached && !this._isBuffering && this._isAttached;
13217
-
13218
- if (shouldTriggerAttach) {
13219
- triggerMethodOn(view, 'before:attach', view);
13220
- }
13221
-
13222
- this.attachHtml(this, view, index);
13223
-
13224
- if (shouldTriggerAttach) {
13225
- view._isAttached = true;
13226
- triggerMethodOn(view, 'attach', view);
13227
- }
13228
- },
13229
-
13230
-
13231
- // Build a `childView` for a model in the collection.
13232
- buildChildView: function buildChildView(child, ChildViewClass, childViewOptions) {
13233
- var options = _.extend({ model: child }, childViewOptions);
13234
- return new ChildViewClass(options);
13235
- },
13236
-
13237
-
13238
- // Remove the child view and destroy it. This function also updates the indices of later views
13239
- // in the collection in order to keep the children in sync with the collection.
13240
- removeChildView: function removeChildView(view) {
13241
- if (!view || view._isDestroyed) {
13242
- return view;
13243
- }
13244
-
13245
- this._removeChildView(view);
13246
- this.children._updateLength();
13247
- // decrement the index of views after this one
13248
- this._updateIndices(view, false);
13249
- return view;
13250
- },
13251
-
13252
-
13253
- // check if the collection is empty or optionally whether an array of pre-processed models is empty
13254
- isEmpty: function isEmpty(options) {
13255
- var models = void 0;
13256
- if (_.result(options, 'processedModels')) {
13257
- models = options.processedModels;
13258
- } else {
13259
- models = this.collection ? this.collection.models : [];
13260
- models = this._filterModels(models);
13261
- }
13262
- return models.length === 0;
13263
- },
13264
-
13265
-
13266
- // You might need to override this if you've overridden attachHtml
13267
- attachBuffer: function attachBuffer(collectionView, buffer) {
13268
- this.appendChildren(collectionView.el, buffer);
13269
- },
13270
-
13271
-
13272
- // Create a fragment buffer from the currently buffered children
13273
- _createBuffer: function _createBuffer() {
13274
- var _this6 = this;
13275
-
13276
- var elBuffer = this.createBuffer();
13277
- _.each(this._bufferedChildren, function (b) {
13278
- _this6.appendChildren(elBuffer, b.el);
13279
- });
13280
- return elBuffer;
13281
- },
13282
-
13283
-
13284
- // Append the HTML to the collection's `el`. Override this method to do something other
13285
- // than `.append`.
13286
- attachHtml: function attachHtml(collectionView, childView, index) {
13287
- if (collectionView._isBuffering) {
13288
- // buffering happens on reset events and initial renders
13289
- // in order to reduce the number of inserts into the
13290
- // document, which are expensive.
13291
- collectionView._bufferedChildren.splice(index, 0, childView);
13292
- } else {
13293
- // If we've already rendered the main collection, append
13294
- // the new child into the correct order if we need to. Otherwise
13295
- // append to the end.
13296
- if (!collectionView._insertBefore(childView, index)) {
13297
- collectionView._insertAfter(childView);
13298
- }
13299
- }
13300
- },
13301
-
13302
-
13303
- // Internal method. Check whether we need to insert the view into the correct position.
13304
- _insertBefore: function _insertBefore(childView, index) {
13305
- var currentView = void 0;
13306
- var findPosition = this.sort && index < this.children.length - 1;
13307
- if (findPosition) {
13308
- // Find the view after this one
13309
- currentView = this.children.find(function (view) {
13310
- return view._index === index + 1;
13311
- });
13312
- }
13313
-
13314
- if (currentView) {
13315
- this.beforeEl(currentView.el, childView.el);
13316
- return true;
13317
- }
13318
-
13319
- return false;
13320
- },
13321
-
13322
-
13323
- // Internal method. Append a view to the end of the $el
13324
- _insertAfter: function _insertAfter(childView) {
13325
- this.appendChildren(this.el, childView.el);
13326
- },
13327
-
13328
-
13329
- // Internal method to set up the `children` object for storing all of the child views
13330
- _initChildViewStorage: function _initChildViewStorage() {
13331
- this.children = new Container();
13332
- },
13333
-
13334
-
13335
- // called by ViewMixin destroy
13336
- _removeChildren: function _removeChildren() {
13337
- this._destroyChildren();
13338
- },
13339
-
13340
-
13341
- // Destroy the child views that this collection view is holding on to, if any
13342
- _destroyChildren: function _destroyChildren(options) {
13343
- if (!this.children.length) {
13344
- return;
13345
- }
13346
-
13347
- this.triggerMethod('before:destroy:children', this);
13348
- this.children.each(_.bind(this._removeChildView, this));
13349
- this.children._updateLength();
13350
- this.triggerMethod('destroy:children', this);
13351
- },
13352
-
13353
-
13354
- // Return true if the given child should be shown. Return false otherwise.
13355
- // The filter will be passed (child, index, collection), where
13356
- // 'child' is the given model
13357
- // 'index' is the index of that model in the collection
13358
- // 'collection' is the collection referenced by this CollectionView
13359
- _shouldAddChild: function _shouldAddChild(child, index) {
13360
- var filter = this.filter;
13361
- return !_.isFunction(filter) || filter.call(this, child, index, this.collection);
13362
- }
13363
- });
13364
-
13365
- _.extend(CollectionView.prototype, ViewMixin);
13366
-
13367
- // Composite View
13368
- // --------------
13369
-
13370
- var ClassOptions$4 = ['childViewContainer', 'template', 'templateContext'];
13371
-
13372
- // Used for rendering a branch-leaf, hierarchical structure.
13373
- // Extends directly from CollectionView
13374
- // @deprecated
13375
- var CompositeView = CollectionView.extend({
13376
-
13377
- // Setting up the inheritance chain which allows changes to
13378
- // Marionette.CollectionView.prototype.constructor which allows overriding
13379
- // option to pass '{sort: false}' to prevent the CompositeView from
13380
- // maintaining the sorted order of the collection.
13381
- // This will fallback onto appending childView's to the end.
13382
- constructor: function constructor(options) {
13383
- deprecate('CompositeView is deprecated. Convert to View at your earliest convenience');
13384
-
13385
- this.mergeOptions(options, ClassOptions$4);
13386
-
13387
- CollectionView.prototype.constructor.apply(this, arguments);
13388
- },
13389
-
13390
-
13391
- // Configured the initial events that the composite view
13392
- // binds to. Override this method to prevent the initial
13393
- // events, or to add your own initial events.
13394
- _initialEvents: function _initialEvents() {
13395
-
13396
- // Bind only after composite view is rendered to avoid adding child views
13397
- // to nonexistent childViewContainer
13398
-
13399
- if (this.collection) {
13400
- this.listenTo(this.collection, 'add', this._onCollectionAdd);
13401
- this.listenTo(this.collection, 'update', this._onCollectionUpdate);
13402
- this.listenTo(this.collection, 'reset', this.renderChildren);
13403
-
13404
- if (this.sort) {
13405
- this.listenTo(this.collection, 'sort', this._sortViews);
13406
- }
13407
- }
13408
- },
13409
-
13410
-
13411
- // Retrieve the `childView` to be used when rendering each of
13412
- // the items in the collection. The default is to return
13413
- // `this.childView` or Marionette.CompositeView if no `childView`
13414
- // has been defined. As happens in CollectionView, `childView` can
13415
- // be a function (which should return a view class).
13416
- _getChildView: function _getChildView(child) {
13417
- var childView = this.childView;
13418
-
13419
- // for CompositeView, if `childView` is not specified, we'll get the same
13420
- // composite view class rendered for each child in the collection
13421
- // then check if the `childView` is a view class (the common case)
13422
- // finally check if it's a function (which we assume that returns a view class)
13423
- if (!childView) {
13424
- return this.constructor;
13425
- }
13426
-
13427
- childView = this._getView(childView, child);
13428
-
13429
- if (!childView) {
13430
- throw new MarionetteError({
13431
- name: 'InvalidChildViewError',
13432
- message: '"childView" must be a view class or a function that returns a view class'
13433
- });
13434
- }
13435
-
13436
- return childView;
13437
- },
13438
-
13439
-
13440
- // Return the serialized model
13441
- serializeData: function serializeData() {
13442
- return this.serializeModel();
13443
- },
13444
-
13445
-
13446
- // Renders the model and the collection.
13447
- render: function render() {
13448
- if (this._isDestroyed) {
13449
- return this;
13450
- }
13451
- this._isRendering = true;
13452
- this.resetChildViewContainer();
13453
-
13454
- this.triggerMethod('before:render', this);
13455
-
13456
- this._renderTemplate();
13457
- this.bindUIElements();
13458
- this.renderChildren();
13459
-
13460
- this._isRendering = false;
13461
- this._isRendered = true;
13462
- this.triggerMethod('render', this);
13463
- return this;
13464
- },
13465
- renderChildren: function renderChildren() {
13466
- if (this._isRendered || this._isRendering) {
13467
- CollectionView.prototype._renderChildren.call(this);
13468
- }
13469
- },
13470
-
13471
-
13472
- // You might need to override this if you've overridden attachHtml
13473
- attachBuffer: function attachBuffer(compositeView, buffer) {
13474
- var $container = this.getChildViewContainer(compositeView);
13475
- this.appendChildren($container, buffer);
13476
- },
13477
-
13478
-
13479
- // Internal method. Append a view to the end of the $el.
13480
- // Overidden from CollectionView to ensure view is appended to
13481
- // childViewContainer
13482
- _insertAfter: function _insertAfter(childView) {
13483
- var $container = this.getChildViewContainer(this, childView);
13484
- this.appendChildren($container, childView.el);
13485
- },
13486
-
13487
-
13488
- // Internal method. Append reordered childView'.
13489
- // Overidden from CollectionView to ensure reordered views
13490
- // are appended to childViewContainer
13491
- _appendReorderedChildren: function _appendReorderedChildren(children) {
13492
- var $container = this.getChildViewContainer(this);
13493
- this.appendChildren($container, children);
13494
- },
13495
-
13496
-
13497
- // Internal method to ensure an `$childViewContainer` exists, for the
13498
- // `attachHtml` method to use.
13499
- getChildViewContainer: function getChildViewContainer(containerView, childView) {
13500
- if (!!containerView.$childViewContainer) {
13501
- return containerView.$childViewContainer;
13502
- }
13503
-
13504
- var container = void 0;
13505
- var childViewContainer = containerView.childViewContainer;
13506
- if (childViewContainer) {
13507
-
13508
- var selector = _.result(containerView, 'childViewContainer');
13509
-
13510
- if (selector.charAt(0) === '@' && containerView.ui) {
13511
- container = containerView.ui[selector.substr(4)];
13512
- } else {
13513
- container = this.findEls(selector, containerView.$el);
13514
- }
13515
-
13516
- if (container.length <= 0) {
13517
- throw new MarionetteError({
13518
- name: 'ChildViewContainerMissingError',
13519
- message: 'The specified "childViewContainer" was not found: ' + containerView.childViewContainer
13520
- });
13521
- }
13522
- } else {
13523
- container = containerView.$el;
13524
- }
13525
-
13526
- containerView.$childViewContainer = container;
13527
- return container;
13528
- },
13529
-
13530
-
13531
- // Internal method to reset the `$childViewContainer` on render
13532
- resetChildViewContainer: function resetChildViewContainer() {
13533
- if (this.$childViewContainer) {
13534
- this.$childViewContainer = undefined;
13535
- }
13536
- }
13537
- });
13538
-
13539
- // To prevent duplication but allow the best View organization
13540
- // Certain View methods are mixed directly into the deprecated CompositeView
13541
- var MixinFromView = _.pick(View.prototype, 'serializeModel', 'getTemplate', '_renderTemplate', 'mixinTemplateContext', 'attachElContent');
13542
- _.extend(CompositeView.prototype, MixinFromView);
13543
-
13544
- // Behavior
13545
- // --------
13546
-
13547
- // A Behavior is an isolated set of DOM /
13548
- // user interactions that can be mixed into any View.
13549
- // Behaviors allow you to blackbox View specific interactions
13550
- // into portable logical chunks, keeping your views simple and your code DRY.
13551
-
13552
- var ClassOptions$5 = ['collectionEvents', 'events', 'modelEvents', 'triggers', 'ui'];
13553
-
13554
- var Behavior = MarionetteObject.extend({
13555
- cidPrefix: 'mnb',
13556
-
13557
- constructor: function constructor(options, view) {
13558
- // Setup reference to the view.
13559
- // this comes in handle when a behavior
13560
- // wants to directly talk up the chain
13561
- // to the view.
13562
- this.view = view;
13563
- this.defaults = _.clone(_.result(this, 'defaults', {}));
13564
- this._setOptions(this.defaults, options);
13565
- this.mergeOptions(this.options, ClassOptions$5);
13566
-
13567
- // Construct an internal UI hash using
13568
- // the behaviors UI hash and then the view UI hash.
13569
- // This allows the user to use UI hash elements
13570
- // defined in the parent view as well as those
13571
- // defined in the given behavior.
13572
- // This order will help the reuse and share of a behavior
13573
- // between multiple views, while letting a view override a
13574
- // selector under an UI key.
13575
- this.ui = _.extend({}, _.result(this, 'ui'), _.result(view, 'ui'));
13576
-
13577
- MarionetteObject.apply(this, arguments);
13578
- },
13579
-
13580
-
13581
- // proxy behavior $ method to the view
13582
- // this is useful for doing jquery DOM lookups
13583
- // scoped to behaviors view.
13584
- $: function $() {
13585
- return this.view.$.apply(this.view, arguments);
13586
- },
13587
-
13588
-
13589
- // Stops the behavior from listening to events.
13590
- // Overrides Object#destroy to prevent additional events from being triggered.
13591
- destroy: function destroy() {
13592
- this.stopListening();
13593
-
13594
- return this;
13595
- },
13596
- proxyViewProperties: function proxyViewProperties() {
13597
- this.$el = this.view.$el;
13598
- this.el = this.view.el;
13599
-
13600
- return this;
13601
- },
13602
- bindUIElements: function bindUIElements() {
13603
- this._bindUIElements();
13604
-
13605
- return this;
13606
- },
13607
- unbindUIElements: function unbindUIElements() {
13608
- this._unbindUIElements();
13609
-
13610
- return this;
13611
- },
13612
- getUI: function getUI(name) {
13613
- return this._getUI(name);
13614
- },
13615
-
13616
-
13617
- // Handle `modelEvents`, and `collectionEvents` configuration
13618
- delegateEntityEvents: function delegateEntityEvents() {
13619
- this._delegateEntityEvents(this.view.model, this.view.collection);
13620
-
13621
- return this;
13622
- },
13623
- undelegateEntityEvents: function undelegateEntityEvents() {
13624
- this._undelegateEntityEvents(this.view.model, this.view.collection);
13625
-
13626
- return this;
13627
- },
13628
- getEvents: function getEvents() {
13629
- var _this = this;
13630
-
13631
- // Normalize behavior events hash to allow
13632
- // a user to use the @ui. syntax.
13633
- var behaviorEvents = this.normalizeUIKeys(_.result(this, 'events'));
13634
-
13635
- // binds the handler to the behavior and builds a unique eventName
13636
- return _.reduce(behaviorEvents, function (events, behaviorHandler, key) {
13637
- if (!_.isFunction(behaviorHandler)) {
13638
- behaviorHandler = _this[behaviorHandler];
13639
- }
13640
- if (!behaviorHandler) {
13641
- return;
13642
- }
13643
- key = getUniqueEventName(key);
13644
- events[key] = _.bind(behaviorHandler, _this);
13645
- return events;
13646
- }, {});
13647
- },
13648
-
13649
-
13650
- // Internal method to build all trigger handlers for a given behavior
13651
- getTriggers: function getTriggers() {
13652
- if (!this.triggers) {
13653
- return;
13654
- }
13655
-
13656
- // Normalize behavior triggers hash to allow
13657
- // a user to use the @ui. syntax.
13658
- var behaviorTriggers = this.normalizeUIKeys(_.result(this, 'triggers'));
13659
-
13660
- return this._getViewTriggers(this.view, behaviorTriggers);
13661
- }
13662
- });
13663
-
13664
- _.extend(Behavior.prototype, DelegateEntityEventsMixin, TriggersMixin, UIMixin);
13665
-
13666
- // Application
13667
- // -----------
13668
- var ClassOptions$6 = ['region', 'regionClass'];
13669
-
13670
- // A container for a Marionette application.
13671
- var Application = MarionetteObject.extend({
13672
- cidPrefix: 'mna',
13673
-
13674
- constructor: function constructor(options) {
13675
- this._setOptions(options);
13676
-
13677
- this.mergeOptions(options, ClassOptions$6);
13678
-
13679
- this._initRegion();
13680
-
13681
- MarionetteObject.prototype.constructor.apply(this, arguments);
13682
- },
13683
-
13684
-
13685
- regionClass: Region,
13686
-
13687
- _initRegion: function _initRegion() {
13688
- var region = this.region;
13689
-
13690
- if (!region) {
13691
- return;
13692
- }
13693
-
13694
- var defaults = {
13695
- regionClass: this.regionClass
13696
- };
13697
-
13698
- this._region = buildRegion(region, defaults);
13699
- },
13700
- getRegion: function getRegion() {
13701
- return this._region;
13702
- },
13703
- showView: function showView(view) {
13704
- var region = this.getRegion();
13705
-
13706
- for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
13707
- args[_key - 1] = arguments[_key];
13708
- }
13709
-
13710
- return region.show.apply(region, [view].concat(args));
13711
- },
13712
- getView: function getView() {
13713
- return this.getRegion().currentView;
13714
- },
13715
-
13716
-
13717
- // kick off all of the application's processes.
13718
- start: function start(options) {
13719
- this.triggerMethod('before:start', this, options);
13720
- this.triggerMethod('start', this, options);
13721
- return this;
13722
- }
13723
- });
13724
-
13725
- // App Router
13726
- // ----------
13727
-
13728
- // Reduce the boilerplate code of handling route events
13729
- // and then calling a single method on another object,
13730
- // called a controller.
13731
- // Have your routers configured to call the method on
13732
- // your controller, directly.
13733
- //
13734
- // Configure an AppRouter with `appRoutes`.
13735
- //
13736
- // App routers can only take one `controller` object.
13737
- // It is recommended that you divide your controller
13738
- // objects in to smaller pieces of related functionality
13739
- // and have multiple routers / controllers, instead of
13740
- // just one giant router and controller.
13741
- //
13742
- // You can also add standard routes to an AppRouter.
13743
-
13744
- var ClassOptions$7 = ['appRoutes', 'controller'];
13745
-
13746
- var AppRouter = Backbone.Router.extend({
13747
- constructor: function constructor(options) {
13748
- this._setOptions(options);
13749
-
13750
- this.mergeOptions(options, ClassOptions$7);
13751
-
13752
- Backbone.Router.apply(this, arguments);
13753
-
13754
- var appRoutes = this.appRoutes;
13755
- var controller = this._getController();
13756
- this.processAppRoutes(controller, appRoutes);
13757
- this.on('route', this._processOnRoute, this);
13758
- },
13759
-
13760
-
13761
- // Similar to route method on a Backbone Router but
13762
- // method is called on the controller
13763
- appRoute: function appRoute(route, methodName) {
13764
- var controller = this._getController();
13765
- this._addAppRoute(controller, route, methodName);
13766
- return this;
13767
- },
13768
-
13769
-
13770
- // process the route event and trigger the onRoute
13771
- // method call, if it exists
13772
- _processOnRoute: function _processOnRoute(routeName, routeArgs) {
13773
- // make sure an onRoute before trying to call it
13774
- if (_.isFunction(this.onRoute)) {
13775
- // find the path that matches the current route
13776
- var routePath = _.invert(this.appRoutes)[routeName];
13777
- this.onRoute(routeName, routePath, routeArgs);
13778
- }
13779
- },
13780
-
13781
-
13782
- // Internal method to process the `appRoutes` for the
13783
- // router, and turn them in to routes that trigger the
13784
- // specified method on the specified `controller`.
13785
- processAppRoutes: function processAppRoutes(controller, appRoutes) {
13786
- var _this = this;
13787
-
13788
- if (!appRoutes) {
13789
- return this;
13790
- }
13791
-
13792
- var routeNames = _.keys(appRoutes).reverse(); // Backbone requires reverted order of routes
13793
-
13794
- _.each(routeNames, function (route) {
13795
- _this._addAppRoute(controller, route, appRoutes[route]);
13796
- });
13797
-
13798
- return this;
13799
- },
13800
- _getController: function _getController() {
13801
- return this.controller;
13802
- },
13803
- _addAppRoute: function _addAppRoute(controller, route, methodName) {
13804
- var method = controller[methodName];
13805
-
13806
- if (!method) {
13807
- throw new MarionetteError('Method "' + methodName + '" was not found on the controller');
13808
- }
13809
-
13810
- this.route(route, methodName, _.bind(method, controller));
13811
- },
13812
-
13813
-
13814
- triggerMethod: triggerMethod$1
13815
- });
13816
-
13817
- _.extend(AppRouter.prototype, CommonMixin);
13818
-
13819
- // Placeholder method to be extended by the user.
13820
- // The method should define the object that stores the behaviors.
13821
- // i.e.
13822
- //
13823
- // ```js
13824
- // Marionette.Behaviors.behaviorsLookup: function() {
13825
- // return App.Behaviors
13826
- // }
13827
- // ```
13828
- function behaviorsLookup() {
13829
- throw new MarionetteError({
13830
- message: 'You must define where your behaviors are stored.',
13831
- url: 'marionette.behaviors.md#behaviorslookup'
13832
- });
13833
- }
13834
-
13835
- var previousMarionette = Backbone.Marionette;
13836
- var Marionette = Backbone.Marionette = {};
13837
-
13838
- // This allows you to run multiple instances of Marionette on the same
13839
- // webapp. After loading the new version, call `noConflict()` to
13840
- // get a reference to it. At the same time the old version will be
13841
- // returned to Backbone.Marionette.
13842
- Marionette.noConflict = function () {
13843
- Backbone.Marionette = previousMarionette;
13844
- return this;
13845
- };
13846
-
13847
- // Utilities
13848
- Marionette.bindEvents = proxy(bindEvents);
13849
- Marionette.unbindEvents = proxy(unbindEvents);
13850
- Marionette.bindRequests = proxy(bindRequests);
13851
- Marionette.unbindRequests = proxy(unbindRequests);
13852
- Marionette.mergeOptions = proxy(mergeOptions);
13853
- Marionette.getOption = proxy(getOption);
13854
- Marionette.normalizeMethods = proxy(normalizeMethods);
13855
- Marionette.extend = extend;
13856
- Marionette.isNodeAttached = isNodeAttached;
13857
- Marionette.deprecate = deprecate;
13858
- Marionette.triggerMethod = proxy(triggerMethod$1);
13859
- Marionette.triggerMethodOn = triggerMethodOn;
13860
- Marionette.isEnabled = isEnabled;
13861
- Marionette.setEnabled = setEnabled;
13862
- Marionette.monitorViewEvents = monitorViewEvents;
13863
-
13864
- Marionette.Behaviors = {};
13865
- Marionette.Behaviors.behaviorsLookup = behaviorsLookup;
13866
-
13867
- // Classes
13868
- Marionette.Application = Application;
13869
- Marionette.AppRouter = AppRouter;
13870
- Marionette.Renderer = Renderer;
13871
- Marionette.TemplateCache = TemplateCache;
13872
- Marionette.View = View;
13873
- Marionette.CollectionView = CollectionView;
13874
- Marionette.CompositeView = CompositeView;
13875
- Marionette.Behavior = Behavior;
13876
- Marionette.Region = Region;
13877
- Marionette.Error = MarionetteError;
13878
- Marionette.Object = MarionetteObject;
13879
-
13880
- // Configuration
13881
- Marionette.DEV_MODE = false;
13882
- Marionette.FEATURES = FEATURES;
13883
- Marionette.VERSION = version;
13884
-
13885
- return Marionette;
13886
-
13887
- })));
13888
-
13889
- //# sourceMappingURL=backbone.marionette.js.map
13890
-
13891
-
13892
- /***/ },
13893
-
13894
- /***/ 573:
13895
- /***/ function(module, exports, __webpack_require__) {
13896
-
13897
- // Backbone.Radio v2.0.0
13898
-
13899
- (function (global, factory) {
13900
- true ? module.exports = factory(__webpack_require__(280), __webpack_require__(544)) :
13901
- typeof define === 'function' && define.amd ? define(['underscore', 'backbone'], factory) :
13902
- (global.Backbone = global.Backbone || {}, global.Backbone.Radio = factory(global._,global.Backbone));
13903
- }(this, function (_,Backbone) { 'use strict';
13904
-
13905
- _ = 'default' in _ ? _['default'] : _;
13906
- Backbone = 'default' in Backbone ? Backbone['default'] : Backbone;
13907
-
13908
- var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) {
13909
- return typeof obj;
13910
- } : function (obj) {
13911
- return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj;
13912
- };
13913
-
13914
- var previousRadio = Backbone.Radio;
13915
-
13916
- var Radio = Backbone.Radio = {};
13917
-
13918
- Radio.VERSION = '2.0.0';
13919
-
13920
- // This allows you to run multiple instances of Radio on the same
13921
- // webapp. After loading the new version, call `noConflict()` to
13922
- // get a reference to it. At the same time the old version will be
13923
- // returned to Backbone.Radio.
13924
- Radio.noConflict = function () {
13925
- Backbone.Radio = previousRadio;
13926
- return this;
13927
- };
13928
-
13929
- // Whether or not we're in DEBUG mode or not. DEBUG mode helps you
13930
- // get around the issues of lack of warnings when events are mis-typed.
13931
- Radio.DEBUG = false;
13932
-
13933
- // Format debug text.
13934
- Radio._debugText = function (warning, eventName, channelName) {
13935
- return warning + (channelName ? ' on the ' + channelName + ' channel' : '') + ': "' + eventName + '"';
13936
- };
13937
-
13938
- // This is the method that's called when an unregistered event was called.
13939
- // By default, it logs warning to the console. By overriding this you could
13940
- // make it throw an Error, for instance. This would make firing a nonexistent event
13941
- // have the same consequence as firing a nonexistent method on an Object.
13942
- Radio.debugLog = function (warning, eventName, channelName) {
13943
- if (Radio.DEBUG && console && console.warn) {
13944
- console.warn(Radio._debugText(warning, eventName, channelName));
13945
- }
13946
- };
13947
-
13948
- var eventSplitter = /\s+/;
13949
-
13950
- // An internal method used to handle Radio's method overloading for Requests.
13951
- // It's borrowed from Backbone.Events. It differs from Backbone's overload
13952
- // API (which is used in Backbone.Events) in that it doesn't support space-separated
13953
- // event names.
13954
- Radio._eventsApi = function (obj, action, name, rest) {
13955
- if (!name) {
13956
- return false;
13957
- }
13958
-
13959
- var results = {};
13960
-
13961
- // Handle event maps.
13962
- if ((typeof name === 'undefined' ? 'undefined' : _typeof(name)) === 'object') {
13963
- for (var key in name) {
13964
- var result = obj[action].apply(obj, [key, name[key]].concat(rest));
13965
- eventSplitter.test(key) ? _.extend(results, result) : results[key] = result;
13966
- }
13967
- return results;
13968
- }
13969
-
13970
- // Handle space separated event names.
13971
- if (eventSplitter.test(name)) {
13972
- var names = name.split(eventSplitter);
13973
- for (var i = 0, l = names.length; i < l; i++) {
13974
- results[names[i]] = obj[action].apply(obj, [names[i]].concat(rest));
13975
- }
13976
- return results;
13977
- }
13978
-
13979
- return false;
13980
- };
13981
-
13982
- // An optimized way to execute callbacks.
13983
- Radio._callHandler = function (callback, context, args) {
13984
- var a1 = args[0],
13985
- a2 = args[1],
13986
- a3 = args[2];
13987
- switch (args.length) {
13988
- case 0:
13989
- return callback.call(context);
13990
- case 1:
13991
- return callback.call(context, a1);
13992
- case 2:
13993
- return callback.call(context, a1, a2);
13994
- case 3:
13995
- return callback.call(context, a1, a2, a3);
13996
- default:
13997
- return callback.apply(context, args);
13998
- }
13999
- };
14000
-
14001
- // A helper used by `off` methods to the handler from the store
14002
- function removeHandler(store, name, callback, context) {
14003
- var event = store[name];
14004
- if ((!callback || callback === event.callback || callback === event.callback._callback) && (!context || context === event.context)) {
14005
- delete store[name];
14006
- return true;
14007
- }
14008
- }
14009
-
14010
- function removeHandlers(store, name, callback, context) {
14011
- store || (store = {});
14012
- var names = name ? [name] : _.keys(store);
14013
- var matched = false;
14014
-
14015
- for (var i = 0, length = names.length; i < length; i++) {
14016
- name = names[i];
14017
-
14018
- // If there's no event by this name, log it and continue
14019
- // with the loop
14020
- if (!store[name]) {
14021
- continue;
14022
- }
14023
-
14024
- if (removeHandler(store, name, callback, context)) {
14025
- matched = true;
14026
- }
14027
- }
14028
-
14029
- return matched;
14030
- }
14031
-
14032
- /*
14033
- * tune-in
14034
- * -------
14035
- * Get console logs of a channel's activity
14036
- *
14037
- */
14038
-
14039
- var _logs = {};
14040
-
14041
- // This is to produce an identical function in both tuneIn and tuneOut,
14042
- // so that Backbone.Events unregisters it.
14043
- function _partial(channelName) {
14044
- return _logs[channelName] || (_logs[channelName] = _.bind(Radio.log, Radio, channelName));
14045
- }
14046
-
14047
- _.extend(Radio, {
14048
-
14049
- // Log information about the channel and event
14050
- log: function log(channelName, eventName) {
14051
- if (typeof console === 'undefined') {
14052
- return;
14053
- }
14054
- var args = _.toArray(arguments).slice(2);
14055
- console.log('[' + channelName + '] "' + eventName + '"', args);
14056
- },
14057
-
14058
- // Logs all events on this channel to the console. It sets an
14059
- // internal value on the channel telling it we're listening,
14060
- // then sets a listener on the Backbone.Events
14061
- tuneIn: function tuneIn(channelName) {
14062
- var channel = Radio.channel(channelName);
14063
- channel._tunedIn = true;
14064
- channel.on('all', _partial(channelName));
14065
- return this;
14066
- },
14067
-
14068
- // Stop logging all of the activities on this channel to the console
14069
- tuneOut: function tuneOut(channelName) {
14070
- var channel = Radio.channel(channelName);
14071
- channel._tunedIn = false;
14072
- channel.off('all', _partial(channelName));
14073
- delete _logs[channelName];
14074
- return this;
14075
- }
14076
- });
14077
-
14078
- /*
14079
- * Backbone.Radio.Requests
14080
- * -----------------------
14081
- * A messaging system for requesting data.
14082
- *
14083
- */
14084
-
14085
- function makeCallback(callback) {
14086
- return _.isFunction(callback) ? callback : function () {
14087
- return callback;
14088
- };
14089
- }
14090
-
14091
- Radio.Requests = {
14092
-
14093
- // Make a request
14094
- request: function request(name) {
14095
- var args = _.toArray(arguments).slice(1);
14096
- var results = Radio._eventsApi(this, 'request', name, args);
14097
- if (results) {
14098
- return results;
14099
- }
14100
- var channelName = this.channelName;
14101
- var requests = this._requests;
14102
-
14103
- // Check if we should log the request, and if so, do it
14104
- if (channelName && this._tunedIn) {
14105
- Radio.log.apply(this, [channelName, name].concat(args));
14106
- }
14107
-
14108
- // If the request isn't handled, log it in DEBUG mode and exit
14109
- if (requests && (requests[name] || requests['default'])) {
14110
- var handler = requests[name] || requests['default'];
14111
- args = requests[name] ? args : arguments;
14112
- return Radio._callHandler(handler.callback, handler.context, args);
14113
- } else {
14114
- Radio.debugLog('An unhandled request was fired', name, channelName);
14115
- }
14116
- },
14117
-
14118
- // Set up a handler for a request
14119
- reply: function reply(name, callback, context) {
14120
- if (Radio._eventsApi(this, 'reply', name, [callback, context])) {
14121
- return this;
14122
- }
14123
-
14124
- this._requests || (this._requests = {});
14125
-
14126
- if (this._requests[name]) {
14127
- Radio.debugLog('A request was overwritten', name, this.channelName);
14128
- }
14129
-
14130
- this._requests[name] = {
14131
- callback: makeCallback(callback),
14132
- context: context || this
14133
- };
14134
-
14135
- return this;
14136
- },
14137
-
14138
- // Set up a handler that can only be requested once
14139
- replyOnce: function replyOnce(name, callback, context) {
14140
- if (Radio._eventsApi(this, 'replyOnce', name, [callback, context])) {
14141
- return this;
14142
- }
14143
-
14144
- var self = this;
14145
-
14146
- var once = _.once(function () {
14147
- self.stopReplying(name);
14148
- return makeCallback(callback).apply(this, arguments);
14149
- });
14150
-
14151
- return this.reply(name, once, context);
14152
- },
14153
-
14154
- // Remove handler(s)
14155
- stopReplying: function stopReplying(name, callback, context) {
14156
- if (Radio._eventsApi(this, 'stopReplying', name)) {
14157
- return this;
14158
- }
14159
-
14160
- // Remove everything if there are no arguments passed
14161
- if (!name && !callback && !context) {
14162
- delete this._requests;
14163
- } else if (!removeHandlers(this._requests, name, callback, context)) {
14164
- Radio.debugLog('Attempted to remove the unregistered request', name, this.channelName);
14165
- }
14166
-
14167
- return this;
14168
- }
14169
- };
14170
-
14171
- /*
14172
- * Backbone.Radio.channel
14173
- * ----------------------
14174
- * Get a reference to a channel by name.
14175
- *
14176
- */
14177
-
14178
- Radio._channels = {};
14179
-
14180
- Radio.channel = function (channelName) {
14181
- if (!channelName) {
14182
- throw new Error('You must provide a name for the channel.');
14183
- }
14184
-
14185
- if (Radio._channels[channelName]) {
14186
- return Radio._channels[channelName];
14187
- } else {
14188
- return Radio._channels[channelName] = new Radio.Channel(channelName);
14189
- }
14190
- };
14191
-
14192
- /*
14193
- * Backbone.Radio.Channel
14194
- * ----------------------
14195
- * A Channel is an object that extends from Backbone.Events,
14196
- * and Radio.Requests.
14197
- *
14198
- */
14199
-
14200
- Radio.Channel = function (channelName) {
14201
- this.channelName = channelName;
14202
- };
14203
-
14204
- _.extend(Radio.Channel.prototype, Backbone.Events, Radio.Requests, {
14205
-
14206
- // Remove all handlers from the messaging systems of this channel
14207
- reset: function reset() {
14208
- this.off();
14209
- this.stopListening();
14210
- this.stopReplying();
14211
- return this;
14212
- }
14213
- });
14214
-
14215
- /*
14216
- * Top-level API
14217
- * -------------
14218
- * Supplies the 'top-level API' for working with Channels directly
14219
- * from Backbone.Radio.
14220
- *
14221
- */
14222
-
14223
- var channel;
14224
- var args;
14225
- var systems = [Backbone.Events, Radio.Requests];
14226
- _.each(systems, function (system) {
14227
- _.each(system, function (method, methodName) {
14228
- Radio[methodName] = function (channelName) {
14229
- args = _.toArray(arguments).slice(1);
14230
- channel = this.channel(channelName);
14231
- return channel[methodName].apply(channel, args);
14232
- };
14233
- });
14234
- });
14235
-
14236
- Radio.reset = function (channelName) {
14237
- var channels = !channelName ? this._channels : [this._channels[channelName]];
14238
- _.each(channels, function (channel) {
14239
- channel.reset();
14240
- });
14241
- };
14242
-
14243
- return Radio;
14244
-
14245
- }));
14246
- //# sourceMappingURL=./backbone.radio.js.map
14247
-
14248
- /***/ },
14249
-
14250
- /***/ 574:
14251
- /***/ function(module, exports) {
14252
-
14253
- Backbone.SuperModel = (function(_, Backbone){
14254
- var _triggerNestedChanges = function(path) {
14255
- for (var m = path.length - 1; m >= 0; m--) {
14256
- // splits the path into 2 different array
14257
- var p = path.slice(0, m); // the target path of the events
14258
- var q = path.slice(m); // an array of the remaining paths which will be used to form events
14259
-
14260
- if (q.length == 1) {
14261
- // this case has been handled by the normal set
14262
- continue;
14263
- }
14264
-
14265
- // identifies the target
14266
- p = p.join('.');
14267
- var target = this;
14268
- if (p.length > 0) {
14269
- target = this.get(p);
14270
- }
14271
-
14272
- // based on the remaining paths, form an array of all possible events
14273
- // ['a', 'b', 'c'] results in 3 possible events a, a.b, a.b.c
14274
- var tmp = _.first(q);
14275
- var rest = _.rest(q);
14276
- var paths = [tmp];
14277
- for (var n = 0; n < rest.length; n++) {
14278
- tmp = [tmp, rest[n]].join('.');
14279
- paths.push(tmp);
14280
- }
14281
-
14282
- for (var l = 0; l < paths.length; l++) {
14283
- var _p = paths[l];
14284
- var trigger = target.trigger;
14285
-
14286
- if (trigger && _.isFunction(trigger)) {
14287
- trigger.call(target, 'change:'+_p, target, target.get(_p));
14288
- }
14289
- }
14290
- }
14291
- };
14292
-
14293
- var processKeyPath = function(keyPath) {
14294
- if (_.isString(keyPath)) {
14295
- keyPath = keyPath.split('.');
14296
- }
14297
- return keyPath;
14298
- };
14299
-
14300
- // http://stackoverflow.com/a/16190716/386378
14301
- var getObjectValue = function(obj, path, def){
14302
- path = processKeyPath(path);
14303
-
14304
- var len = path.length;
14305
- for(var i = 0; i < len; i++){
14306
- if(!obj || typeof obj !== 'object') return def;
14307
- obj = obj[path[i]];
14308
- }
14309
-
14310
- if(obj === undefined) return def;
14311
- return obj;
14312
- };
14313
-
14314
- // based on the concept of // http://stackoverflow.com/a/5484764/386378
14315
- // not recursively walk through the keyPath of obj
14316
- // when reaching the end call doThing
14317
- // and pass the last obj and last key
14318
- var walkObject = function(obj, keyPath, doThing) {
14319
- keyPath = processKeyPath(keyPath);
14320
-
14321
- lastKeyIndex = keyPath.length-1;
14322
- for (var i = 0; i < lastKeyIndex; ++ i) {
14323
- key = keyPath[i];
14324
- if (!(key in obj))
14325
- obj[key] = {};
14326
- obj = obj[key];
14327
- }
14328
- doThing(obj, keyPath[lastKeyIndex]);
14329
- };
14330
-
14331
- var setObjectValue = function(obj, keyPath, value) {
14332
- walkObject(obj, keyPath, function(destination, lastKey){
14333
- destination[lastKey] = value;
14334
- });
14335
- };
14336
-
14337
- var deleteObjectKey = function(obj, keyPath) {
14338
- walkObject(obj, keyPath, function(destination, lastKey){
14339
- delete destination[lastKey];
14340
- });
14341
- };
14342
-
14343
- var hasObjectKey = function(obj, keyPath) {
14344
- var hasKey = false;
14345
- walkObject(obj, keyPath, function(destination, lastKey){
14346
- hasKey = _.has(destination, lastKey);
14347
- });
14348
- return hasKey;
14349
- };
14350
-
14351
- // recursively walk through a Backbone.Model model
14352
- // using keyPath
14353
- // when reaching the end, call doThing
14354
- // and pass the last model and last key
14355
- var walkNestedAttributes = function(model, keyPath, doThing) {
14356
- keyPath = processKeyPath(keyPath);
14357
-
14358
- var first = _.first(keyPath);
14359
- var nestedModel = model.get(first);
14360
-
14361
- if (nestedModel instanceof Backbone.Model) {
14362
- walkNestedAttributes(nestedModel, _.rest(keyPath), doThing);
14363
- }
14364
- doThing(model, keyPath);
14365
- };
14366
-
14367
- var getRelation = function(obj, attr, value) {
14368
- var relation;
14369
-
14370
- if (attr) {
14371
- var relations = _.result(obj, 'relations');
14372
- relation = relations[attr];
14373
- }
14374
-
14375
- if (value && !relation) {
14376
- relation = Model;
14377
- }
14378
-
14379
- // catch all the weird stuff
14380
- if (relation == void 0) {
14381
- relation = Model;
14382
- }
14383
-
14384
- return relation;
14385
- };
14386
-
14387
- var setupBackref = function(obj, instance, options) {
14388
- var name = _.result(obj, 'name');
14389
- // respect the attribute with the same name in relation
14390
- if (name && !instance[name]) {
14391
- instance[name] = obj;
14392
- }
14393
- return instance;
14394
- };
14395
-
14396
- // a simple object is an object that does not come from "new"
14397
- var isSimpleObject = function(value) {
14398
- return value.constructor === Object;
14399
- };
14400
-
14401
- var Model = Backbone.Model.extend({
14402
- relations: {},
14403
- unsafeAttributes: [],
14404
- name: null, // set name so that children can refer back to
14405
-
14406
- _valueForCollection: function(value) {
14407
- if (_.isArray(value)) {
14408
- if (value.length >= 1) {
14409
- return _.isObject(value[0]);
14410
- }
14411
- return true;
14412
- }
14413
-
14414
- return false;
14415
- },
14416
-
14417
- _nestedSet: function(path, value, options) {
14418
- path = path.split('.');
14419
-
14420
- var lastKeyIndex = path.length - 1;
14421
- var obj = this;
14422
- var previousObj = null;
14423
- var previousKey = null;
14424
-
14425
- for (var i = 0; i < lastKeyIndex; ++i) {
14426
- var key = path[i];
14427
-
14428
- var check = obj.attributes[key];
14429
- if (!check) {
14430
- // initiate the relationship here
14431
- //var relation = Backbone.Model;
14432
- var relation = getRelation(obj, key, value);
14433
- var instance = new relation();
14434
- obj.attributes[key] = setupBackref(obj, instance, options);
14435
- }
14436
- obj = obj.attributes[key];
14437
- }
14438
-
14439
- var finalPath = path[lastKeyIndex];
14440
-
14441
- if (!_.isArray(value) && _.isObject(value) && isSimpleObject(value)) {
14442
- // special case when the object value is empty, just set it to an empty model
14443
- if (_.size(value) === 0) {
14444
- obj.attributes[finalPath] = new Model();
14445
- } else {
14446
- for (var j in value) {
14447
- var newPath = finalPath + '.' + j;
14448
- // let _nestedSet do its things
14449
- obj._nestedSet(newPath, value[j], options);
14450
- }
14451
- }
14452
- } else {
14453
- if (this._valueForCollection(value)) {
14454
- // here we need to initiate the collection manually
14455
- var _relation = getRelation(obj, finalPath, value);
14456
-
14457
- if (_relation.prototype instanceof Backbone.Model) {
14458
- // if we dont have the Collection relation for this, use custom Collection
14459
- // because "value" should be used with a Collection
14460
- _relation = Collection;
14461
- }
14462
- var collection = new _relation(value);
14463
- collection = setupBackref(obj, collection, options);
14464
- obj.attributes[finalPath] = collection;
14465
- } else {
14466
- // prevent duplicated events due to "set"
14467
- if (path.length == 1) {
14468
- obj.attributes[finalPath] = value;
14469
- } else {
14470
- obj.set(finalPath, value, _.extend({skipNested: true, forceChange: true}, options));
14471
- }
14472
- }
14473
- }
14474
-
14475
- if (!options.silent) {
14476
- _triggerNestedChanges.call(this, path);
14477
- }
14478
- },
14479
-
14480
- _setChanging: function() {
14481
- this._previousAttributes = this.toJSON();
14482
- this.changed = {};
14483
- },
14484
-
14485
- _triggerChanges: function(changes, options, changeValue) {
14486
- if (changes.length) this._pending = true;
14487
- for (var i = 0, l = changes.length; i < l; i++) {
14488
- if (!changeValue) {
14489
- changeValue = this.get(changes[i]);
14490
- }
14491
-
14492
- // should only handle single attribute change event here
14493
- // change events for nested attributes should be handled by
14494
- // _triggerNestedChanges
14495
- if (changes[i].split('.').length == 1) {
14496
- this.trigger('change:' + changes[i], this, changeValue, options);
14497
- }
14498
- }
14499
- },
14500
-
14501
- _setChange: function(attr, val, options) {
14502
- var currentValue = this.get(attr);
14503
- attr = attr.split('.');
14504
- if (!_.isEqual(currentValue, val) || options.forceChange) {
14505
- setObjectValue(this.changed, attr, val);
14506
- return true;
14507
- } else {
14508
- deleteObjectKey(this.changed, attr);
14509
- return false;
14510
- }
14511
- },
14512
-
14513
- set: function(key, val, options) {
14514
- var attr, attrs, unset, changes, silent, changing, prev, current, skipNested;
14515
- if (key == null) return this;
14516
-
14517
- // Handle both `"key", value` and `{key: value}` -style arguments.
14518
- if (typeof key === 'object') {
14519
- attrs = key;
14520
- options = val;
14521
- } else {
14522
- attrs = {};
14523
- attrs[key] = val;
14524
- }
14525
-
14526
- options = options || {};
14527
-
14528
- // Run validation.
14529
- // TODO: Need to work on this so that we can validate nested models
14530
- if (!this._validate(attrs, options)) return false;
14531
-
14532
- // Extract attributes and options.
14533
- unset = options.unset;
14534
- silent = options.silent;
14535
- changes = [];
14536
- changing = this._changing;
14537
- skipNested = options.skipNested;
14538
- this._changing = true;
14539
-
14540
- if (!changing) {
14541
- this._setChanging();
14542
- }
14543
-
14544
- // Check for changes of `id`.
14545
- if (this.idAttribute in attrs) this.id = attrs[this.idAttribute];
14546
-
14547
- // For each `set` attribute, update or delete the current value.
14548
- var unsetAttribute = function(destination, realKey){
14549
- delete destination.attributes[realKey];
14550
- };
14551
-
14552
- for (attr in attrs) {
14553
- val = attrs[attr];
14554
-
14555
- if (this._setChange(attr, val, options)) {
14556
- changes.push(attr);
14557
- }
14558
-
14559
- if (unset) {
14560
- walkNestedAttributes(this, attr, unsetAttribute);
14561
- } else {
14562
- if (skipNested) {
14563
- this.attributes[attr] = val;
14564
- } else {
14565
- this._nestedSet(attr, val, options);
14566
- }
14567
- }
14568
- }
14569
-
14570
- // Trigger all relevant attribute changes.
14571
- if (!silent) {
14572
- this._triggerChanges(changes, options);
14573
- }
14574
-
14575
- // You might be wondering why there's a `while` loop here. Changes can
14576
- // be recursively nested within `"change"` events.
14577
- if (changing) return this;
14578
- if (!silent) {
14579
- while (this._pending) {
14580
- this._pending = false;
14581
- this.trigger('change', this, options);
14582
- }
14583
- }
14584
- this._pending = false;
14585
- this._changing = false;
14586
- return this;
14587
- },
14588
-
14589
- get: function(attr) {
14590
- var nestedAttrs = attr ? attr.split('.') : [];
14591
-
14592
- if (nestedAttrs.length > 1) {
14593
- var nestedAttr = this.attributes[_.first(nestedAttrs)];
14594
- if (!nestedAttr) {
14595
- return;
14596
- }
14597
-
14598
- var rest = _.rest(nestedAttrs).join('.');
14599
-
14600
- if (_.isFunction(nestedAttr.get)) {
14601
- return nestedAttr.get(rest);
14602
- }
14603
-
14604
- return nestedAttr[rest];
14605
- }
14606
- return this.attributes[attr];
14607
- },
14608
-
14609
- toJSON: function(options) {
14610
- options = options || {};
14611
- var unsafeAttributes = _.result(this, 'unsafeAttributes');
14612
-
14613
- if (options.except) {
14614
- unsafeAttributes = _.union(unsafeAttributes, options.except);
14615
- }
14616
-
14617
- var attributes = _.clone(this.attributes);
14618
- _.each(unsafeAttributes, function(attr){
14619
- delete attributes[attr];
14620
- });
14621
-
14622
- _.each(attributes, function(val, key){
14623
- if (val && _.isFunction(val.toJSON)) {
14624
- attributes[key] = val.toJSON();
14625
- }
14626
- });
14627
-
14628
- return attributes;
14629
- },
14630
-
14631
- hasChanged: function(attr) {
14632
- if (attr == null) return !_.isEmpty(this.changed);
14633
- return hasObjectKey(this.changed, attr);
14634
- },
14635
-
14636
- previous: function(attr) {
14637
- if (attr == null || !this._previousAttributes) return null;
14638
- return getObjectValue(this._previousAttributes, attr);
14639
- },
14640
-
14641
- // Clear all attributes on the model, firing `"change"`.
14642
- clear: function(options) {
14643
- var attrs = {};
14644
- this.id = void 0;
14645
-
14646
- for (var key in this.attributes) {
14647
- var val = this.attributes[key];
14648
- if (val instanceof Backbone.Model) {
14649
- val.clear();
14650
- } else if (val instanceof Backbone.Collection) {
14651
- val.reset();
14652
- } else {
14653
- this.unset(key);
14654
- }
14655
- }
14656
- return this;
14657
- }
14658
- });
14659
-
14660
- var Collection = Backbone.Collection.extend({
14661
- model: Model
14662
- });
14663
-
14664
- return Model;
14665
- })(_, Backbone);
14666
-
14667
-
14668
- /*** EXPORTS FROM exports-loader ***/
14669
- module.exports = Backbone.SuperModel;
14670
-
14671
- /***/ },
14672
-
14673
- /***/ 575:
14674
- /***/ function(module, exports, __webpack_require__) {
14675
-
14676
- /**
14677
- * interact.js v1.2.8
14678
- *
14679
- * Copyright (c) 2012-2015 Taye Adeyemi <dev@taye.me>
14680
- * Open source under the MIT License.
14681
- * https://raw.github.com/taye/interact.js/master/LICENSE
14682
- */
14683
- (function (realWindow) {
14684
- 'use strict';
14685
-
14686
- // return early if there's no window to work with (eg. Node.js)
14687
- if (!realWindow) { return; }
14688
-
14689
- var // get wrapped window if using Shadow DOM polyfill
14690
- window = (function () {
14691
- // create a TextNode
14692
- var el = realWindow.document.createTextNode('');
14693
-
14694
- // check if it's wrapped by a polyfill
14695
- if (el.ownerDocument !== realWindow.document
14696
- && typeof realWindow.wrap === 'function'
14697
- && realWindow.wrap(el) === el) {
14698
- // return wrapped window
14699
- return realWindow.wrap(realWindow);
14700
- }
14701
-
14702
- // no Shadow DOM polyfil or native implementation
14703
- return realWindow;
14704
- }()),
14705
-
14706
- document = window.document,
14707
- DocumentFragment = window.DocumentFragment || blank,
14708
- SVGElement = window.SVGElement || blank,
14709
- SVGSVGElement = window.SVGSVGElement || blank,
14710
- SVGElementInstance = window.SVGElementInstance || blank,
14711
- HTMLElement = window.HTMLElement || window.Element,
14712
-
14713
- PointerEvent = (window.PointerEvent || window.MSPointerEvent),
14714
- pEventTypes,
14715
-
14716
- hypot = Math.hypot || function (x, y) { return Math.sqrt(x * x + y * y); },
14717
-
14718
- tmpXY = {}, // reduce object creation in getXY()
14719
-
14720
- documents = [], // all documents being listened to
14721
-
14722
- interactables = [], // all set interactables
14723
- interactions = [], // all interactions
14724
-
14725
- dynamicDrop = false,
14726
-
14727
- // {
14728
- // type: {
14729
- // selectors: ['selector', ...],
14730
- // contexts : [document, ...],
14731
- // listeners: [[listener, useCapture], ...]
14732
- // }
14733
- // }
14734
- delegatedEvents = {},
14735
-
14736
- defaultOptions = {
14737
- base: {
14738
- accept : null,
14739
- actionChecker : null,
14740
- styleCursor : true,
14741
- preventDefault: 'auto',
14742
- origin : { x: 0, y: 0 },
14743
- deltaSource : 'page',
14744
- allowFrom : null,
14745
- ignoreFrom : null,
14746
- _context : document,
14747
- dropChecker : null
14748
- },
14749
-
14750
- drag: {
14751
- enabled: false,
14752
- manualStart: true,
14753
- max: Infinity,
14754
- maxPerElement: 1,
14755
-
14756
- snap: null,
14757
- restrict: null,
14758
- inertia: null,
14759
- autoScroll: null,
14760
-
14761
- axis: 'xy'
14762
- },
14763
-
14764
- drop: {
14765
- enabled: false,
14766
- accept: null,
14767
- overlap: 'pointer'
14768
- },
14769
-
14770
- resize: {
14771
- enabled: false,
14772
- manualStart: false,
14773
- max: Infinity,
14774
- maxPerElement: 1,
14775
-
14776
- snap: null,
14777
- restrict: null,
14778
- inertia: null,
14779
- autoScroll: null,
14780
-
14781
- square: false,
14782
- preserveAspectRatio: false,
14783
- axis: 'xy',
14784
-
14785
- // use default margin
14786
- margin: NaN,
14787
-
14788
- // object with props left, right, top, bottom which are
14789
- // true/false values to resize when the pointer is over that edge,
14790
- // CSS selectors to match the handles for each direction
14791
- // or the Elements for each handle
14792
- edges: null,
14793
-
14794
- // a value of 'none' will limit the resize rect to a minimum of 0x0
14795
- // 'negate' will alow the rect to have negative width/height
14796
- // 'reposition' will keep the width/height positive by swapping
14797
- // the top and bottom edges and/or swapping the left and right edges
14798
- invert: 'none'
14799
- },
14800
-
14801
- gesture: {
14802
- manualStart: false,
14803
- enabled: false,
14804
- max: Infinity,
14805
- maxPerElement: 1,
14806
-
14807
- restrict: null
14808
- },
14809
-
14810
- perAction: {
14811
- manualStart: false,
14812
- max: Infinity,
14813
- maxPerElement: 1,
14814
-
14815
- snap: {
14816
- enabled : false,
14817
- endOnly : false,
14818
- range : Infinity,
14819
- targets : null,
14820
- offsets : null,
14821
-
14822
- relativePoints: null
14823
- },
14824
-
14825
- restrict: {
14826
- enabled: false,
14827
- endOnly: false
14828
- },
14829
-
14830
- autoScroll: {
14831
- enabled : false,
14832
- container : null, // the item that is scrolled (Window or HTMLElement)
14833
- margin : 60,
14834
- speed : 300 // the scroll speed in pixels per second
14835
- },
14836
-
14837
- inertia: {
14838
- enabled : false,
14839
- resistance : 10, // the lambda in exponential decay
14840
- minSpeed : 100, // target speed must be above this for inertia to start
14841
- endSpeed : 10, // the speed at which inertia is slow enough to stop
14842
- allowResume : true, // allow resuming an action in inertia phase
14843
- zeroResumeDelta : true, // if an action is resumed after launch, set dx/dy to 0
14844
- smoothEndDuration: 300 // animate to snap/restrict endOnly if there's no inertia
14845
- }
14846
- },
14847
-
14848
- _holdDuration: 600
14849
- },
14850
-
14851
- // Things related to autoScroll
14852
- autoScroll = {
14853
- interaction: null,
14854
- i: null, // the handle returned by window.setInterval
14855
- x: 0, y: 0, // Direction each pulse is to scroll in
14856
-
14857
- // scroll the window by the values in scroll.x/y
14858
- scroll: function () {
14859
- var options = autoScroll.interaction.target.options[autoScroll.interaction.prepared.name].autoScroll,
14860
- container = options.container || getWindow(autoScroll.interaction.element),
14861
- now = new Date().getTime(),
14862
- // change in time in seconds
14863
- dtx = (now - autoScroll.prevTimeX) / 1000,
14864
- dty = (now - autoScroll.prevTimeY) / 1000,
14865
- vx, vy, sx, sy;
14866
-
14867
- // displacement
14868
- if (options.velocity) {
14869
- vx = options.velocity.x;
14870
- vy = options.velocity.y;
14871
- }
14872
- else {
14873
- vx = vy = options.speed
14874
- }
14875
-
14876
- sx = vx * dtx;
14877
- sy = vy * dty;
14878
-
14879
- if (sx >= 1 || sy >= 1) {
14880
- if (isWindow(container)) {
14881
- container.scrollBy(autoScroll.x * sx, autoScroll.y * sy);
14882
- }
14883
- else if (container) {
14884
- container.scrollLeft += autoScroll.x * sx;
14885
- container.scrollTop += autoScroll.y * sy;
14886
- }
14887
-
14888
- if (sx >=1) autoScroll.prevTimeX = now;
14889
- if (sy >= 1) autoScroll.prevTimeY = now;
14890
- }
14891
-
14892
- if (autoScroll.isScrolling) {
14893
- cancelFrame(autoScroll.i);
14894
- autoScroll.i = reqFrame(autoScroll.scroll);
14895
- }
14896
- },
14897
-
14898
- isScrolling: false,
14899
- prevTimeX: 0,
14900
- prevTimeY: 0,
14901
-
14902
- start: function (interaction) {
14903
- autoScroll.isScrolling = true;
14904
- cancelFrame(autoScroll.i);
14905
-
14906
- autoScroll.interaction = interaction;
14907
- autoScroll.prevTimeX = new Date().getTime();
14908
- autoScroll.prevTimeY = new Date().getTime();
14909
- autoScroll.i = reqFrame(autoScroll.scroll);
14910
- },
14911
-
14912
- stop: function () {
14913
- autoScroll.isScrolling = false;
14914
- cancelFrame(autoScroll.i);
14915
- }
14916
- },
14917
-
14918
- // Does the browser support touch input?
14919
- supportsTouch = (('ontouchstart' in window) || window.DocumentTouch && document instanceof window.DocumentTouch),
14920
-
14921
- // Does the browser support PointerEvents
14922
- // Avoid PointerEvent bugs introduced in Chrome 55
14923
- supportsPointerEvent = PointerEvent && !/Chrome/.test(navigator.userAgent),
14924
-
14925
- // Less Precision with touch input
14926
- margin = supportsTouch || supportsPointerEvent? 20: 10,
14927
-
14928
- pointerMoveTolerance = 1,
14929
-
14930
- // for ignoring browser's simulated mouse events
14931
- prevTouchTime = 0,
14932
-
14933
- // Allow this many interactions to happen simultaneously
14934
- maxInteractions = Infinity,
14935
-
14936
- // Check if is IE9 or older
14937
- actionCursors = (document.all && !window.atob) ? {
14938
- drag : 'move',
14939
- resizex : 'e-resize',
14940
- resizey : 's-resize',
14941
- resizexy: 'se-resize',
14942
-
14943
- resizetop : 'n-resize',
14944
- resizeleft : 'w-resize',
14945
- resizebottom : 's-resize',
14946
- resizeright : 'e-resize',
14947
- resizetopleft : 'se-resize',
14948
- resizebottomright: 'se-resize',
14949
- resizetopright : 'ne-resize',
14950
- resizebottomleft : 'ne-resize',
14951
-
14952
- gesture : ''
14953
- } : {
14954
- drag : 'move',
14955
- resizex : 'ew-resize',
14956
- resizey : 'ns-resize',
14957
- resizexy: 'nwse-resize',
14958
-
14959
- resizetop : 'ns-resize',
14960
- resizeleft : 'ew-resize',
14961
- resizebottom : 'ns-resize',
14962
- resizeright : 'ew-resize',
14963
- resizetopleft : 'nwse-resize',
14964
- resizebottomright: 'nwse-resize',
14965
- resizetopright : 'nesw-resize',
14966
- resizebottomleft : 'nesw-resize',
14967
-
14968
- gesture : ''
14969
- },
14970
-
14971
- actionIsEnabled = {
14972
- drag : true,
14973
- resize : true,
14974
- gesture: true
14975
- },
14976
-
14977
- // because Webkit and Opera still use 'mousewheel' event type
14978
- wheelEvent = 'onmousewheel' in document? 'mousewheel': 'wheel',
14979
-
14980
- eventTypes = [
14981
- 'dragstart',
14982
- 'dragmove',
14983
- 'draginertiastart',
14984
- 'dragend',
14985
- 'dragenter',
14986
- 'dragleave',
14987
- 'dropactivate',
14988
- 'dropdeactivate',
14989
- 'dropmove',
14990
- 'drop',
14991
- 'resizestart',
14992
- 'resizemove',
14993
- 'resizeinertiastart',
14994
- 'resizeend',
14995
- 'gesturestart',
14996
- 'gesturemove',
14997
- 'gestureinertiastart',
14998
- 'gestureend',
14999
-
15000
- 'down',
15001
- 'move',
15002
- 'up',
15003
- 'cancel',
15004
- 'tap',
15005
- 'doubletap',
15006
- 'hold'
15007
- ],
15008
-
15009
- globalEvents = {},
15010
-
15011
- // Opera Mobile must be handled differently
15012
- isOperaMobile = navigator.appName == 'Opera' &&
15013
- supportsTouch &&
15014
- navigator.userAgent.match('Presto'),
15015
-
15016
- // scrolling doesn't change the result of getClientRects on iOS 7
15017
- isIOS7 = (/iP(hone|od|ad)/.test(navigator.platform)
15018
- && /OS 7[^\d]/.test(navigator.appVersion)),
15019
-
15020
- // prefix matchesSelector
15021
- prefixedMatchesSelector = 'matches' in Element.prototype?
15022
- 'matches': 'webkitMatchesSelector' in Element.prototype?
15023
- 'webkitMatchesSelector': 'mozMatchesSelector' in Element.prototype?
15024
- 'mozMatchesSelector': 'oMatchesSelector' in Element.prototype?
15025
- 'oMatchesSelector': 'msMatchesSelector',
15026
-
15027
- // will be polyfill function if browser is IE8
15028
- ie8MatchesSelector,
15029
-
15030
- // native requestAnimationFrame or polyfill
15031
- reqFrame = realWindow.requestAnimationFrame,
15032
- cancelFrame = realWindow.cancelAnimationFrame,
15033
-
15034
- // Events wrapper
15035
- events = (function () {
15036
- var useAttachEvent = ('attachEvent' in window) && !('addEventListener' in window),
15037
- addEvent = useAttachEvent? 'attachEvent': 'addEventListener',
15038
- removeEvent = useAttachEvent? 'detachEvent': 'removeEventListener',
15039
- on = useAttachEvent? 'on': '',
15040
-
15041
- elements = [],
15042
- targets = [],
15043
- attachedListeners = [];
15044
-
15045
- function add (element, type, listener, useCapture) {
15046
- var elementIndex = indexOf(elements, element),
15047
- target = targets[elementIndex];
15048
-
15049
- if (!target) {
15050
- target = {
15051
- events: {},
15052
- typeCount: 0
15053
- };
15054
-
15055
- elementIndex = elements.push(element) - 1;
15056
- targets.push(target);
15057
-
15058
- attachedListeners.push((useAttachEvent ? {
15059
- supplied: [],
15060
- wrapped : [],
15061
- useCount: []
15062
- } : null));
15063
- }
15064
-
15065
- if (!target.events[type]) {
15066
- target.events[type] = [];
15067
- target.typeCount++;
15068
- }
15069
-
15070
- if (!contains(target.events[type], listener)) {
15071
- var ret;
15072
-
15073
- if (useAttachEvent) {
15074
- var listeners = attachedListeners[elementIndex],
15075
- listenerIndex = indexOf(listeners.supplied, listener);
15076
-
15077
- var wrapped = listeners.wrapped[listenerIndex] || function (event) {
15078
- if (!event.immediatePropagationStopped) {
15079
- event.target = event.srcElement;
15080
- event.currentTarget = element;
15081
-
15082
- event.preventDefault = event.preventDefault || preventDef;
15083
- event.stopPropagation = event.stopPropagation || stopProp;
15084
- event.stopImmediatePropagation = event.stopImmediatePropagation || stopImmProp;
15085
-
15086
- if (/mouse|click/.test(event.type)) {
15087
- event.pageX = event.clientX + getWindow(element).document.documentElement.scrollLeft;
15088
- event.pageY = event.clientY + getWindow(element).document.documentElement.scrollTop;
15089
- }
15090
-
15091
- listener(event);
15092
- }
15093
- };
15094
-
15095
- ret = element[addEvent](on + type, wrapped, Boolean(useCapture));
15096
-
15097
- if (listenerIndex === -1) {
15098
- listeners.supplied.push(listener);
15099
- listeners.wrapped.push(wrapped);
15100
- listeners.useCount.push(1);
15101
- }
15102
- else {
15103
- listeners.useCount[listenerIndex]++;
15104
- }
15105
- }
15106
- else {
15107
- ret = element[addEvent](type, listener, useCapture || false);
15108
- }
15109
- target.events[type].push(listener);
15110
-
15111
- return ret;
15112
- }
15113
- }
15114
-
15115
- function remove (element, type, listener, useCapture) {
15116
- var i,
15117
- elementIndex = indexOf(elements, element),
15118
- target = targets[elementIndex],
15119
- listeners,
15120
- listenerIndex,
15121
- wrapped = listener;
15122
-
15123
- if (!target || !target.events) {
15124
- return;
15125
- }
15126
-
15127
- if (useAttachEvent) {
15128
- listeners = attachedListeners[elementIndex];
15129
- listenerIndex = indexOf(listeners.supplied, listener);
15130
- wrapped = listeners.wrapped[listenerIndex];
15131
- }
15132
-
15133
- if (type === 'all') {
15134
- for (type in target.events) {
15135
- if (target.events.hasOwnProperty(type)) {
15136
- remove(element, type, 'all');
15137
- }
15138
- }
15139
- return;
15140
- }
15141
-
15142
- if (target.events[type]) {
15143
- var len = target.events[type].length;
15144
-
15145
- if (listener === 'all') {
15146
- for (i = 0; i < len; i++) {
15147
- remove(element, type, target.events[type][i], Boolean(useCapture));
15148
- }
15149
- return;
15150
- } else {
15151
- for (i = 0; i < len; i++) {
15152
- if (target.events[type][i] === listener) {
15153
- element[removeEvent](on + type, wrapped, useCapture || false);
15154
- target.events[type].splice(i, 1);
15155
-
15156
- if (useAttachEvent && listeners) {
15157
- listeners.useCount[listenerIndex]--;
15158
- if (listeners.useCount[listenerIndex] === 0) {
15159
- listeners.supplied.splice(listenerIndex, 1);
15160
- listeners.wrapped.splice(listenerIndex, 1);
15161
- listeners.useCount.splice(listenerIndex, 1);
15162
- }
15163
- }
15164
-
15165
- break;
15166
- }
15167
- }
15168
- }
15169
-
15170
- if (target.events[type] && target.events[type].length === 0) {
15171
- target.events[type] = null;
15172
- target.typeCount--;
15173
- }
15174
- }
15175
-
15176
- if (!target.typeCount) {
15177
- targets.splice(elementIndex, 1);
15178
- elements.splice(elementIndex, 1);
15179
- attachedListeners.splice(elementIndex, 1);
15180
- }
15181
- }
15182
-
15183
- function preventDef () {
15184
- this.returnValue = false;
15185
- }
15186
-
15187
- function stopProp () {
15188
- this.cancelBubble = true;
15189
- }
15190
-
15191
- function stopImmProp () {
15192
- this.cancelBubble = true;
15193
- this.immediatePropagationStopped = true;
15194
- }
15195
-
15196
- return {
15197
- add: add,
15198
- remove: remove,
15199
- useAttachEvent: useAttachEvent,
15200
-
15201
- _elements: elements,
15202
- _targets: targets,
15203
- _attachedListeners: attachedListeners
15204
- };
15205
- }());
15206
-
15207
- function blank () {}
15208
-
15209
- function isElement (o) {
15210
- if (!o || (typeof o !== 'object')) { return false; }
15211
-
15212
- var _window = getWindow(o) || window;
15213
-
15214
- return (/object|function/.test(typeof _window.Element)
15215
- ? o instanceof _window.Element //DOM2
15216
- : o.nodeType === 1 && typeof o.nodeName === "string");
15217
- }
15218
- function isWindow (thing) { return thing === window || !!(thing && thing.Window) && (thing instanceof thing.Window); }
15219
- function isDocFrag (thing) { return !!thing && thing instanceof DocumentFragment; }
15220
- function isArray (thing) {
15221
- return isObject(thing)
15222
- && (typeof thing.length !== undefined)
15223
- && isFunction(thing.splice);
15224
- }
15225
- function isObject (thing) { return !!thing && (typeof thing === 'object'); }
15226
- function isFunction (thing) { return typeof thing === 'function'; }
15227
- function isNumber (thing) { return typeof thing === 'number' ; }
15228
- function isBool (thing) { return typeof thing === 'boolean' ; }
15229
- function isString (thing) { return typeof thing === 'string' ; }
15230
-
15231
- function trySelector (value) {
15232
- if (!isString(value)) { return false; }
15233
-
15234
- // an exception will be raised if it is invalid
15235
- document.querySelector(value);
15236
- return true;
15237
- }
15238
-
15239
- function extend (dest, source) {
15240
- for (var prop in source) {
15241
- dest[prop] = source[prop];
15242
- }
15243
- return dest;
15244
- }
15245
-
15246
- var prefixedPropREs = {
15247
- webkit: /(Movement[XY]|Radius[XY]|RotationAngle|Force)$/
15248
- };
15249
-
15250
- function pointerExtend (dest, source) {
15251
- for (var prop in source) {
15252
- var deprecated = false;
15253
-
15254
- // skip deprecated prefixed properties
15255
- for (var vendor in prefixedPropREs) {
15256
- if (prop.indexOf(vendor) === 0 && prefixedPropREs[vendor].test(prop)) {
15257
- deprecated = true;
15258
- break;
15259
- }
15260
- }
15261
-
15262
- if (!deprecated) {
15263
- dest[prop] = source[prop];
15264
- }
15265
- }
15266
- return dest;
15267
- }
15268
-
15269
- function copyCoords (dest, src) {
15270
- dest.page = dest.page || {};
15271
- dest.page.x = src.page.x;
15272
- dest.page.y = src.page.y;
15273
-
15274
- dest.client = dest.client || {};
15275
- dest.client.x = src.client.x;
15276
- dest.client.y = src.client.y;
15277
-
15278
- dest.timeStamp = src.timeStamp;
15279
- }
15280
-
15281
- function setEventXY (targetObj, pointers, interaction) {
15282
- var pointer = (pointers.length > 1
15283
- ? pointerAverage(pointers)
15284
- : pointers[0]);
15285
-
15286
- getPageXY(pointer, tmpXY, interaction);
15287
- targetObj.page.x = tmpXY.x;
15288
- targetObj.page.y = tmpXY.y;
15289
-
15290
- getClientXY(pointer, tmpXY, interaction);
15291
- targetObj.client.x = tmpXY.x;
15292
- targetObj.client.y = tmpXY.y;
15293
-
15294
- targetObj.timeStamp = new Date().getTime();
15295
- }
15296
-
15297
- function setEventDeltas (targetObj, prev, cur) {
15298
- targetObj.page.x = cur.page.x - prev.page.x;
15299
- targetObj.page.y = cur.page.y - prev.page.y;
15300
- targetObj.client.x = cur.client.x - prev.client.x;
15301
- targetObj.client.y = cur.client.y - prev.client.y;
15302
- targetObj.timeStamp = new Date().getTime() - prev.timeStamp;
15303
-
15304
- // set pointer velocity
15305
- var dt = Math.max(targetObj.timeStamp / 1000, 0.001);
15306
- targetObj.page.speed = hypot(targetObj.page.x, targetObj.page.y) / dt;
15307
- targetObj.page.vx = targetObj.page.x / dt;
15308
- targetObj.page.vy = targetObj.page.y / dt;
15309
-
15310
- targetObj.client.speed = hypot(targetObj.client.x, targetObj.page.y) / dt;
15311
- targetObj.client.vx = targetObj.client.x / dt;
15312
- targetObj.client.vy = targetObj.client.y / dt;
15313
- }
15314
-
15315
- function isNativePointer (pointer) {
15316
- return (pointer instanceof window.Event
15317
- || (supportsTouch && window.Touch && pointer instanceof window.Touch));
15318
- }
15319
-
15320
- // Get specified X/Y coords for mouse or event.touches[0]
15321
- function getXY (type, pointer, xy) {
15322
- xy = xy || {};
15323
- type = type || 'page';
15324
-
15325
- xy.x = pointer[type + 'X'];
15326
- xy.y = pointer[type + 'Y'];
15327
-
15328
- return xy;
15329
- }
15330
-
15331
- function getPageXY (pointer, page) {
15332
- page = page || {};
15333
-
15334
- // Opera Mobile handles the viewport and scrolling oddly
15335
- if (isOperaMobile && isNativePointer(pointer)) {
15336
- getXY('screen', pointer, page);
15337
-
15338
- page.x += window.scrollX;
15339
- page.y += window.scrollY;
15340
- }
15341
- else {
15342
- getXY('page', pointer, page);
15343
- }
15344
-
15345
- return page;
15346
- }
15347
-
15348
- function getClientXY (pointer, client) {
15349
- client = client || {};
15350
-
15351
- if (isOperaMobile && isNativePointer(pointer)) {
15352
- // Opera Mobile handles the viewport and scrolling oddly
15353
- getXY('screen', pointer, client);
15354
- }
15355
- else {
15356
- getXY('client', pointer, client);
15357
- }
15358
-
15359
- return client;
15360
- }
15361
-
15362
- function getScrollXY (win) {
15363
- win = win || window;
15364
- return {
15365
- x: win.scrollX || win.document.documentElement.scrollLeft,
15366
- y: win.scrollY || win.document.documentElement.scrollTop
15367
- };
15368
- }
15369
-
15370
- function getPointerId (pointer) {
15371
- return isNumber(pointer.pointerId)? pointer.pointerId : pointer.identifier;
15372
- }
15373
-
15374
- function getActualElement (element) {
15375
- return (element instanceof SVGElementInstance
15376
- ? element.correspondingUseElement
15377
- : element);
15378
- }
15379
-
15380
- function getWindow (node) {
15381
- if (isWindow(node)) {
15382
- return node;
15383
- }
15384
-
15385
- var rootNode = (node.ownerDocument || node);
15386
-
15387
- return rootNode.defaultView || rootNode.parentWindow || window;
15388
- }
15389
-
15390
- function getElementClientRect (element) {
15391
- var clientRect = (element instanceof SVGElement
15392
- ? element.getBoundingClientRect()
15393
- : element.getClientRects()[0]);
15394
-
15395
- return clientRect && {
15396
- left : clientRect.left,
15397
- right : clientRect.right,
15398
- top : clientRect.top,
15399
- bottom: clientRect.bottom,
15400
- width : clientRect.width || clientRect.right - clientRect.left,
15401
- height: clientRect.height || clientRect.bottom - clientRect.top
15402
- };
15403
- }
15404
-
15405
- function getElementRect (element) {
15406
- var clientRect = getElementClientRect(element);
15407
-
15408
- if (!isIOS7 && clientRect) {
15409
- var scroll = getScrollXY(getWindow(element));
15410
-
15411
- clientRect.left += scroll.x;
15412
- clientRect.right += scroll.x;
15413
- clientRect.top += scroll.y;
15414
- clientRect.bottom += scroll.y;
15415
- }
15416
-
15417
- return clientRect;
15418
- }
15419
-
15420
- function getTouchPair (event) {
15421
- var touches = [];
15422
-
15423
- // array of touches is supplied
15424
- if (isArray(event)) {
15425
- touches[0] = event[0];
15426
- touches[1] = event[1];
15427
- }
15428
- // an event
15429
- else {
15430
- if (event.type === 'touchend') {
15431
- if (event.touches.length === 1) {
15432
- touches[0] = event.touches[0];
15433
- touches[1] = event.changedTouches[0];
15434
- }
15435
- else if (event.touches.length === 0) {
15436
- touches[0] = event.changedTouches[0];
15437
- touches[1] = event.changedTouches[1];
15438
- }
15439
- }
15440
- else {
15441
- touches[0] = event.touches[0];
15442
- touches[1] = event.touches[1];
15443
- }
15444
- }
15445
-
15446
- return touches;
15447
- }
15448
-
15449
- function pointerAverage (pointers) {
15450
- var average = {
15451
- pageX : 0,
15452
- pageY : 0,
15453
- clientX: 0,
15454
- clientY: 0,
15455
- screenX: 0,
15456
- screenY: 0
15457
- };
15458
- var prop;
15459
-
15460
- for (var i = 0; i < pointers.length; i++) {
15461
- for (prop in average) {
15462
- average[prop] += pointers[i][prop];
15463
- }
15464
- }
15465
- for (prop in average) {
15466
- average[prop] /= pointers.length;
15467
- }
15468
-
15469
- return average;
15470
- }
15471
-
15472
- function touchBBox (event) {
15473
- if (!event.length && !(event.touches && event.touches.length > 1)) {
15474
- return;
15475
- }
15476
-
15477
- var touches = getTouchPair(event),
15478
- minX = Math.min(touches[0].pageX, touches[1].pageX),
15479
- minY = Math.min(touches[0].pageY, touches[1].pageY),
15480
- maxX = Math.max(touches[0].pageX, touches[1].pageX),
15481
- maxY = Math.max(touches[0].pageY, touches[1].pageY);
15482
-
15483
- return {
15484
- x: minX,
15485
- y: minY,
15486
- left: minX,
15487
- top: minY,
15488
- width: maxX - minX,
15489
- height: maxY - minY
15490
- };
15491
- }
15492
-
15493
- function touchDistance (event, deltaSource) {
15494
- deltaSource = deltaSource || defaultOptions.deltaSource;
15495
-
15496
- var sourceX = deltaSource + 'X',
15497
- sourceY = deltaSource + 'Y',
15498
- touches = getTouchPair(event);
15499
-
15500
-
15501
- var dx = touches[0][sourceX] - touches[1][sourceX],
15502
- dy = touches[0][sourceY] - touches[1][sourceY];
15503
-
15504
- return hypot(dx, dy);
15505
- }
15506
-
15507
- function touchAngle (event, prevAngle, deltaSource) {
15508
- deltaSource = deltaSource || defaultOptions.deltaSource;
15509
-
15510
- var sourceX = deltaSource + 'X',
15511
- sourceY = deltaSource + 'Y',
15512
- touches = getTouchPair(event),
15513
- dx = touches[0][sourceX] - touches[1][sourceX],
15514
- dy = touches[0][sourceY] - touches[1][sourceY],
15515
- angle = 180 * Math.atan(dy / dx) / Math.PI;
15516
-
15517
- if (isNumber(prevAngle)) {
15518
- var dr = angle - prevAngle,
15519
- drClamped = dr % 360;
15520
-
15521
- if (drClamped > 315) {
15522
- angle -= 360 + (angle / 360)|0 * 360;
15523
- }
15524
- else if (drClamped > 135) {
15525
- angle -= 180 + (angle / 360)|0 * 360;
15526
- }
15527
- else if (drClamped < -315) {
15528
- angle += 360 + (angle / 360)|0 * 360;
15529
- }
15530
- else if (drClamped < -135) {
15531
- angle += 180 + (angle / 360)|0 * 360;
15532
- }
15533
- }
15534
-
15535
- return angle;
15536
- }
15537
-
15538
- function getOriginXY (interactable, element) {
15539
- var origin = interactable
15540
- ? interactable.options.origin
15541
- : defaultOptions.origin;
15542
-
15543
- if (origin === 'parent') {
15544
- origin = parentElement(element);
15545
- }
15546
- else if (origin === 'self') {
15547
- origin = interactable.getRect(element);
15548
- }
15549
- else if (trySelector(origin)) {
15550
- origin = closest(element, origin) || { x: 0, y: 0 };
15551
- }
15552
-
15553
- if (isFunction(origin)) {
15554
- origin = origin(interactable && element);
15555
- }
15556
-
15557
- if (isElement(origin)) {
15558
- origin = getElementRect(origin);
15559
- }
15560
-
15561
- origin.x = ('x' in origin)? origin.x : origin.left;
15562
- origin.y = ('y' in origin)? origin.y : origin.top;
15563
-
15564
- return origin;
15565
- }
15566
-
15567
- // http://stackoverflow.com/a/5634528/2280888
15568
- function _getQBezierValue(t, p1, p2, p3) {
15569
- var iT = 1 - t;
15570
- return iT * iT * p1 + 2 * iT * t * p2 + t * t * p3;
15571
- }
15572
-
15573
- function getQuadraticCurvePoint(startX, startY, cpX, cpY, endX, endY, position) {
15574
- return {
15575
- x: _getQBezierValue(position, startX, cpX, endX),
15576
- y: _getQBezierValue(position, startY, cpY, endY)
15577
- };
15578
- }
15579
-
15580
- // http://gizma.com/easing/
15581
- function easeOutQuad (t, b, c, d) {
15582
- t /= d;
15583
- return -c * t*(t-2) + b;
15584
- }
15585
-
15586
- function nodeContains (parent, child) {
15587
- while (child) {
15588
- if (child === parent) {
15589
- return true;
15590
- }
15591
-
15592
- child = child.parentNode;
15593
- }
15594
-
15595
- return false;
15596
- }
15597
-
15598
- function closest (child, selector) {
15599
- var parent = parentElement(child);
15600
-
15601
- while (isElement(parent)) {
15602
- if (matchesSelector(parent, selector)) { return parent; }
15603
-
15604
- parent = parentElement(parent);
15605
- }
15606
-
15607
- return null;
15608
- }
15609
-
15610
- function parentElement (node) {
15611
- var parent = node.parentNode;
15612
-
15613
- if (isDocFrag(parent)) {
15614
- // skip past #shado-root fragments
15615
- while ((parent = parent.host) && isDocFrag(parent)) {}
15616
-
15617
- return parent;
15618
- }
15619
-
15620
- return parent;
15621
- }
15622
-
15623
- function inContext (interactable, element) {
15624
- return interactable._context === element.ownerDocument
15625
- || nodeContains(interactable._context, element);
15626
- }
15627
-
15628
- function testIgnore (interactable, interactableElement, element) {
15629
- var ignoreFrom = interactable.options.ignoreFrom;
15630
-
15631
- if (!ignoreFrom || !isElement(element)) { return false; }
15632
-
15633
- if (isString(ignoreFrom)) {
15634
- return matchesUpTo(element, ignoreFrom, interactableElement);
15635
- }
15636
- else if (isElement(ignoreFrom)) {
15637
- return nodeContains(ignoreFrom, element);
15638
- }
15639
-
15640
- return false;
15641
- }
15642
-
15643
- function testAllow (interactable, interactableElement, element) {
15644
- var allowFrom = interactable.options.allowFrom;
15645
-
15646
- if (!allowFrom) { return true; }
15647
-
15648
- if (!isElement(element)) { return false; }
15649
-
15650
- if (isString(allowFrom)) {
15651
- return matchesUpTo(element, allowFrom, interactableElement);
15652
- }
15653
- else if (isElement(allowFrom)) {
15654
- return nodeContains(allowFrom, element);
15655
- }
15656
-
15657
- return false;
15658
- }
15659
-
15660
- function checkAxis (axis, interactable) {
15661
- if (!interactable) { return false; }
15662
-
15663
- var thisAxis = interactable.options.drag.axis;
15664
-
15665
- return (axis === 'xy' || thisAxis === 'xy' || thisAxis === axis);
15666
- }
15667
-
15668
- function checkSnap (interactable, action) {
15669
- var options = interactable.options;
15670
-
15671
- if (/^resize/.test(action)) {
15672
- action = 'resize';
15673
- }
15674
-
15675
- return options[action].snap && options[action].snap.enabled;
15676
- }
15677
-
15678
- function checkRestrict (interactable, action) {
15679
- var options = interactable.options;
15680
-
15681
- if (/^resize/.test(action)) {
15682
- action = 'resize';
15683
- }
15684
-
15685
- return options[action].restrict && options[action].restrict.enabled;
15686
- }
15687
-
15688
- function checkAutoScroll (interactable, action) {
15689
- var options = interactable.options;
15690
-
15691
- if (/^resize/.test(action)) {
15692
- action = 'resize';
15693
- }
15694
-
15695
- return options[action].autoScroll && options[action].autoScroll.enabled;
15696
- }
15697
-
15698
- function withinInteractionLimit (interactable, element, action) {
15699
- var options = interactable.options,
15700
- maxActions = options[action.name].max,
15701
- maxPerElement = options[action.name].maxPerElement,
15702
- activeInteractions = 0,
15703
- targetCount = 0,
15704
- targetElementCount = 0;
15705
-
15706
- for (var i = 0, len = interactions.length; i < len; i++) {
15707
- var interaction = interactions[i],
15708
- otherAction = interaction.prepared.name,
15709
- active = interaction.interacting();
15710
-
15711
- if (!active) { continue; }
15712
-
15713
- activeInteractions++;
15714
-
15715
- if (activeInteractions >= maxInteractions) {
15716
- return false;
15717
- }
15718
-
15719
- if (interaction.target !== interactable) { continue; }
15720
-
15721
- targetCount += (otherAction === action.name)|0;
15722
-
15723
- if (targetCount >= maxActions) {
15724
- return false;
15725
- }
15726
-
15727
- if (interaction.element === element) {
15728
- targetElementCount++;
15729
-
15730
- if (otherAction !== action.name || targetElementCount >= maxPerElement) {
15731
- return false;
15732
- }
15733
- }
15734
- }
15735
-
15736
- return maxInteractions > 0;
15737
- }
15738
-
15739
- // Test for the element that's "above" all other qualifiers
15740
- function indexOfDeepestElement (elements) {
15741
- var dropzone,
15742
- deepestZone = elements[0],
15743
- index = deepestZone? 0: -1,
15744
- parent,
15745
- deepestZoneParents = [],
15746
- dropzoneParents = [],
15747
- child,
15748
- i,
15749
- n;
15750
-
15751
- for (i = 1; i < elements.length; i++) {
15752
- dropzone = elements[i];
15753
-
15754
- // an element might belong to multiple selector dropzones
15755
- if (!dropzone || dropzone === deepestZone) {
15756
- continue;
15757
- }
15758
-
15759
- if (!deepestZone) {
15760
- deepestZone = dropzone;
15761
- index = i;
15762
- continue;
15763
- }
15764
-
15765
- // check if the deepest or current are document.documentElement or document.rootElement
15766
- // - if the current dropzone is, do nothing and continue
15767
- if (dropzone.parentNode === dropzone.ownerDocument) {
15768
- continue;
15769
- }
15770
- // - if deepest is, update with the current dropzone and continue to next
15771
- else if (deepestZone.parentNode === dropzone.ownerDocument) {
15772
- deepestZone = dropzone;
15773
- index = i;
15774
- continue;
15775
- }
15776
-
15777
- if (!deepestZoneParents.length) {
15778
- parent = deepestZone;
15779
- while (parent.parentNode && parent.parentNode !== parent.ownerDocument) {
15780
- deepestZoneParents.unshift(parent);
15781
- parent = parent.parentNode;
15782
- }
15783
- }
15784
-
15785
- // if this element is an svg element and the current deepest is
15786
- // an HTMLElement
15787
- if (deepestZone instanceof HTMLElement
15788
- && dropzone instanceof SVGElement
15789
- && !(dropzone instanceof SVGSVGElement)) {
15790
-
15791
- if (dropzone === deepestZone.parentNode) {
15792
- continue;
15793
- }
15794
-
15795
- parent = dropzone.ownerSVGElement;
15796
- }
15797
- else {
15798
- parent = dropzone;
15799
- }
15800
-
15801
- dropzoneParents = [];
15802
-
15803
- while (parent.parentNode !== parent.ownerDocument) {
15804
- dropzoneParents.unshift(parent);
15805
- parent = parent.parentNode;
15806
- }
15807
-
15808
- n = 0;
15809
-
15810
- // get (position of last common ancestor) + 1
15811
- while (dropzoneParents[n] && dropzoneParents[n] === deepestZoneParents[n]) {
15812
- n++;
15813
- }
15814
-
15815
- var parents = [
15816
- dropzoneParents[n - 1],
15817
- dropzoneParents[n],
15818
- deepestZoneParents[n]
15819
- ];
15820
-
15821
- child = parents[0].lastChild;
15822
-
15823
- while (child) {
15824
- if (child === parents[1]) {
15825
- deepestZone = dropzone;
15826
- index = i;
15827
- deepestZoneParents = [];
15828
-
15829
- break;
15830
- }
15831
- else if (child === parents[2]) {
15832
- break;
15833
- }
15834
-
15835
- child = child.previousSibling;
15836
- }
15837
- }
15838
-
15839
- return index;
15840
- }
15841
-
15842
- function Interaction () {
15843
- this.target = null; // current interactable being interacted with
15844
- this.element = null; // the target element of the interactable
15845
- this.dropTarget = null; // the dropzone a drag target might be dropped into
15846
- this.dropElement = null; // the element at the time of checking
15847
- this.prevDropTarget = null; // the dropzone that was recently dragged away from
15848
- this.prevDropElement = null; // the element at the time of checking
15849
-
15850
- this.prepared = { // action that's ready to be fired on next move event
15851
- name : null,
15852
- axis : null,
15853
- edges: null
15854
- };
15855
-
15856
- this.matches = []; // all selectors that are matched by target element
15857
- this.matchElements = []; // corresponding elements
15858
-
15859
- this.inertiaStatus = {
15860
- active : false,
15861
- smoothEnd : false,
15862
- ending : false,
15863
-
15864
- startEvent: null,
15865
- upCoords: {},
15866
-
15867
- xe: 0, ye: 0,
15868
- sx: 0, sy: 0,
15869
-
15870
- t0: 0,
15871
- vx0: 0, vys: 0,
15872
- duration: 0,
15873
-
15874
- resumeDx: 0,
15875
- resumeDy: 0,
15876
-
15877
- lambda_v0: 0,
15878
- one_ve_v0: 0,
15879
- i : null
15880
- };
15881
-
15882
- if (isFunction(Function.prototype.bind)) {
15883
- this.boundInertiaFrame = this.inertiaFrame.bind(this);
15884
- this.boundSmoothEndFrame = this.smoothEndFrame.bind(this);
15885
- }
15886
- else {
15887
- var that = this;
15888
-
15889
- this.boundInertiaFrame = function () { return that.inertiaFrame(); };
15890
- this.boundSmoothEndFrame = function () { return that.smoothEndFrame(); };
15891
- }
15892
-
15893
- this.activeDrops = {
15894
- dropzones: [], // the dropzones that are mentioned below
15895
- elements : [], // elements of dropzones that accept the target draggable
15896
- rects : [] // the rects of the elements mentioned above
15897
- };
15898
-
15899
- // keep track of added pointers
15900
- this.pointers = [];
15901
- this.pointerIds = [];
15902
- this.downTargets = [];
15903
- this.downTimes = [];
15904
- this.holdTimers = [];
15905
-
15906
- // Previous native pointer move event coordinates
15907
- this.prevCoords = {
15908
- page : { x: 0, y: 0 },
15909
- client : { x: 0, y: 0 },
15910
- timeStamp: 0
15911
- };
15912
- // current native pointer move event coordinates
15913
- this.curCoords = {
15914
- page : { x: 0, y: 0 },
15915
- client : { x: 0, y: 0 },
15916
- timeStamp: 0
15917
- };
15918
-
15919
- // Starting InteractEvent pointer coordinates
15920
- this.startCoords = {
15921
- page : { x: 0, y: 0 },
15922
- client : { x: 0, y: 0 },
15923
- timeStamp: 0
15924
- };
15925
-
15926
- // Change in coordinates and time of the pointer
15927
- this.pointerDelta = {
15928
- page : { x: 0, y: 0, vx: 0, vy: 0, speed: 0 },
15929
- client : { x: 0, y: 0, vx: 0, vy: 0, speed: 0 },
15930
- timeStamp: 0
15931
- };
15932
-
15933
- this.downEvent = null; // pointerdown/mousedown/touchstart event
15934
- this.downPointer = {};
15935
-
15936
- this._eventTarget = null;
15937
- this._curEventTarget = null;
15938
-
15939
- this.prevEvent = null; // previous action event
15940
- this.tapTime = 0; // time of the most recent tap event
15941
- this.prevTap = null;
15942
-
15943
- this.startOffset = { left: 0, right: 0, top: 0, bottom: 0 };
15944
- this.restrictOffset = { left: 0, right: 0, top: 0, bottom: 0 };
15945
- this.snapOffsets = [];
15946
-
15947
- this.gesture = {
15948
- start: { x: 0, y: 0 },
15949
-
15950
- startDistance: 0, // distance between two touches of touchStart
15951
- prevDistance : 0,
15952
- distance : 0,
15953
-
15954
- scale: 1, // gesture.distance / gesture.startDistance
15955
-
15956
- startAngle: 0, // angle of line joining two touches
15957
- prevAngle : 0 // angle of the previous gesture event
15958
- };
15959
-
15960
- this.snapStatus = {
15961
- x : 0, y : 0,
15962
- dx : 0, dy : 0,
15963
- realX : 0, realY : 0,
15964
- snappedX: 0, snappedY: 0,
15965
- targets : [],
15966
- locked : false,
15967
- changed : false
15968
- };
15969
-
15970
- this.restrictStatus = {
15971
- dx : 0, dy : 0,
15972
- restrictedX: 0, restrictedY: 0,
15973
- snap : null,
15974
- restricted : false,
15975
- changed : false
15976
- };
15977
-
15978
- this.restrictStatus.snap = this.snapStatus;
15979
-
15980
- this.pointerIsDown = false;
15981
- this.pointerWasMoved = false;
15982
- this.gesturing = false;
15983
- this.dragging = false;
15984
- this.resizing = false;
15985
- this.resizeAxes = 'xy';
15986
-
15987
- this.mouse = false;
15988
-
15989
- interactions.push(this);
15990
- }
15991
-
15992
- Interaction.prototype = {
15993
- getPageXY : function (pointer, xy) { return getPageXY(pointer, xy, this); },
15994
- getClientXY: function (pointer, xy) { return getClientXY(pointer, xy, this); },
15995
- setEventXY : function (target, ptr) { return setEventXY(target, ptr, this); },
15996
-
15997
- pointerOver: function (pointer, event, eventTarget) {
15998
- if (this.prepared.name || !this.mouse) { return; }
15999
-
16000
- var curMatches = [],
16001
- curMatchElements = [],
16002
- prevTargetElement = this.element;
16003
-
16004
- this.addPointer(pointer);
16005
-
16006
- if (this.target
16007
- && (testIgnore(this.target, this.element, eventTarget)
16008
- || !testAllow(this.target, this.element, eventTarget))) {
16009
- // if the eventTarget should be ignored or shouldn't be allowed
16010
- // clear the previous target
16011
- this.target = null;
16012
- this.element = null;
16013
- this.matches = [];
16014
- this.matchElements = [];
16015
- }
16016
-
16017
- var elementInteractable = interactables.get(eventTarget),
16018
- elementAction = (elementInteractable
16019
- && !testIgnore(elementInteractable, eventTarget, eventTarget)
16020
- && testAllow(elementInteractable, eventTarget, eventTarget)
16021
- && validateAction(
16022
- elementInteractable.getAction(pointer, event, this, eventTarget),
16023
- elementInteractable));
16024
-
16025
- if (elementAction && !withinInteractionLimit(elementInteractable, eventTarget, elementAction)) {
16026
- elementAction = null;
16027
- }
16028
-
16029
- function pushCurMatches (interactable, selector) {
16030
- if (interactable
16031
- && inContext(interactable, eventTarget)
16032
- && !testIgnore(interactable, eventTarget, eventTarget)
16033
- && testAllow(interactable, eventTarget, eventTarget)
16034
- && matchesSelector(eventTarget, selector)) {
16035
-
16036
- curMatches.push(interactable);
16037
- curMatchElements.push(eventTarget);
16038
- }
16039
- }
16040
-
16041
- if (elementAction) {
16042
- this.target = elementInteractable;
16043
- this.element = eventTarget;
16044
- this.matches = [];
16045
- this.matchElements = [];
16046
- }
16047
- else {
16048
- interactables.forEachSelector(pushCurMatches);
16049
-
16050
- if (this.validateSelector(pointer, event, curMatches, curMatchElements)) {
16051
- this.matches = curMatches;
16052
- this.matchElements = curMatchElements;
16053
-
16054
- this.pointerHover(pointer, event, this.matches, this.matchElements);
16055
- events.add(eventTarget,
16056
- supportsPointerEvent? pEventTypes.move : 'mousemove',
16057
- listeners.pointerHover);
16058
- }
16059
- else if (this.target) {
16060
- if (nodeContains(prevTargetElement, eventTarget)) {
16061
- this.pointerHover(pointer, event, this.matches, this.matchElements);
16062
- events.add(this.element,
16063
- supportsPointerEvent? pEventTypes.move : 'mousemove',
16064
- listeners.pointerHover);
16065
- }
16066
- else {
16067
- this.target = null;
16068
- this.element = null;
16069
- this.matches = [];
16070
- this.matchElements = [];
16071
- }
16072
- }
16073
- }
16074
- },
16075
-
16076
- // Check what action would be performed on pointerMove target if a mouse
16077
- // button were pressed and change the cursor accordingly
16078
- pointerHover: function (pointer, event, eventTarget, curEventTarget, matches, matchElements) {
16079
- var target = this.target;
16080
-
16081
- if (!this.prepared.name && this.mouse) {
16082
-
16083
- var action;
16084
-
16085
- // update pointer coords for defaultActionChecker to use
16086
- this.setEventXY(this.curCoords, [pointer]);
16087
-
16088
- if (matches) {
16089
- action = this.validateSelector(pointer, event, matches, matchElements);
16090
- }
16091
- else if (target) {
16092
- action = validateAction(target.getAction(this.pointers[0], event, this, this.element), this.target);
16093
- }
16094
-
16095
- if (target && target.options.styleCursor) {
16096
- if (action) {
16097
- target._doc.documentElement.style.cursor = getActionCursor(action);
16098
- }
16099
- else {
16100
- target._doc.documentElement.style.cursor = '';
16101
- }
16102
- }
16103
- }
16104
- else if (this.prepared.name) {
16105
- this.checkAndPreventDefault(event, target, this.element);
16106
- }
16107
- },
16108
-
16109
- pointerOut: function (pointer, event, eventTarget) {
16110
- if (this.prepared.name) { return; }
16111
-
16112
- // Remove temporary event listeners for selector Interactables
16113
- if (!interactables.get(eventTarget)) {
16114
- events.remove(eventTarget,
16115
- supportsPointerEvent? pEventTypes.move : 'mousemove',
16116
- listeners.pointerHover);
16117
- }
16118
-
16119
- if (this.target && this.target.options.styleCursor && !this.interacting()) {
16120
- this.target._doc.documentElement.style.cursor = '';
16121
- }
16122
- },
16123
-
16124
- selectorDown: function (pointer, event, eventTarget, curEventTarget) {
16125
- var that = this,
16126
- // copy event to be used in timeout for IE8
16127
- eventCopy = events.useAttachEvent? extend({}, event) : event,
16128
- element = eventTarget,
16129
- pointerIndex = this.addPointer(pointer),
16130
- action;
16131
-
16132
- this.holdTimers[pointerIndex] = setTimeout(function () {
16133
- that.pointerHold(events.useAttachEvent? eventCopy : pointer, eventCopy, eventTarget, curEventTarget);
16134
- }, defaultOptions._holdDuration);
16135
-
16136
- this.pointerIsDown = true;
16137
-
16138
- // Check if the down event hits the current inertia target
16139
- if (this.inertiaStatus.active && this.target.selector) {
16140
- // climb up the DOM tree from the event target
16141
- while (isElement(element)) {
16142
-
16143
- // if this element is the current inertia target element
16144
- if (element === this.element
16145
- // and the prospective action is the same as the ongoing one
16146
- && validateAction(this.target.getAction(pointer, event, this, this.element), this.target).name === this.prepared.name) {
16147
-
16148
- // stop inertia so that the next move will be a normal one
16149
- cancelFrame(this.inertiaStatus.i);
16150
- this.inertiaStatus.active = false;
16151
-
16152
- this.collectEventTargets(pointer, event, eventTarget, 'down');
16153
- return;
16154
- }
16155
- element = parentElement(element);
16156
- }
16157
- }
16158
-
16159
- // do nothing if interacting
16160
- if (this.interacting()) {
16161
- this.collectEventTargets(pointer, event, eventTarget, 'down');
16162
- return;
16163
- }
16164
-
16165
- function pushMatches (interactable, selector, context) {
16166
- var elements = ie8MatchesSelector
16167
- ? context.querySelectorAll(selector)
16168
- : undefined;
16169
-
16170
- if (inContext(interactable, element)
16171
- && !testIgnore(interactable, element, eventTarget)
16172
- && testAllow(interactable, element, eventTarget)
16173
- && matchesSelector(element, selector, elements)) {
16174
-
16175
- that.matches.push(interactable);
16176
- that.matchElements.push(element);
16177
- }
16178
- }
16179
-
16180
- // update pointer coords for defaultActionChecker to use
16181
- this.setEventXY(this.curCoords, [pointer]);
16182
- this.downEvent = event;
16183
-
16184
- while (isElement(element) && !action) {
16185
- this.matches = [];
16186
- this.matchElements = [];
16187
-
16188
- interactables.forEachSelector(pushMatches);
16189
-
16190
- action = this.validateSelector(pointer, event, this.matches, this.matchElements);
16191
- element = parentElement(element);
16192
- }
16193
-
16194
- if (action) {
16195
- this.prepared.name = action.name;
16196
- this.prepared.axis = action.axis;
16197
- this.prepared.edges = action.edges;
16198
-
16199
- this.collectEventTargets(pointer, event, eventTarget, 'down');
16200
-
16201
- return this.pointerDown(pointer, event, eventTarget, curEventTarget, action);
16202
- }
16203
- else {
16204
- // do these now since pointerDown isn't being called from here
16205
- this.downTimes[pointerIndex] = new Date().getTime();
16206
- this.downTargets[pointerIndex] = eventTarget;
16207
- pointerExtend(this.downPointer, pointer);
16208
-
16209
- copyCoords(this.prevCoords, this.curCoords);
16210
- this.pointerWasMoved = false;
16211
- }
16212
-
16213
- this.collectEventTargets(pointer, event, eventTarget, 'down');
16214
- },
16215
-
16216
- // Determine action to be performed on next pointerMove and add appropriate
16217
- // style and event Listeners
16218
- pointerDown: function (pointer, event, eventTarget, curEventTarget, forceAction) {
16219
- if (!forceAction && !this.inertiaStatus.active && this.pointerWasMoved && this.prepared.name) {
16220
- this.checkAndPreventDefault(event, this.target, this.element);
16221
-
16222
- return;
16223
- }
16224
-
16225
- this.pointerIsDown = true;
16226
- this.downEvent = event;
16227
-
16228
- var pointerIndex = this.addPointer(pointer),
16229
- action;
16230
-
16231
- // If it is the second touch of a multi-touch gesture, keep the
16232
- // target the same and get a new action if a target was set by the
16233
- // first touch
16234
- if (this.pointerIds.length > 1 && this.target._element === this.element) {
16235
- var newAction = validateAction(forceAction || this.target.getAction(pointer, event, this, this.element), this.target);
16236
-
16237
- if (withinInteractionLimit(this.target, this.element, newAction)) {
16238
- action = newAction;
16239
- }
16240
-
16241
- this.prepared.name = null;
16242
- }
16243
- // Otherwise, set the target if there is no action prepared
16244
- else if (!this.prepared.name) {
16245
- var interactable = interactables.get(curEventTarget);
16246
-
16247
- if (interactable
16248
- && !testIgnore(interactable, curEventTarget, eventTarget)
16249
- && testAllow(interactable, curEventTarget, eventTarget)
16250
- && (action = validateAction(forceAction || interactable.getAction(pointer, event, this, curEventTarget), interactable, eventTarget))
16251
- && withinInteractionLimit(interactable, curEventTarget, action)) {
16252
- this.target = interactable;
16253
- this.element = curEventTarget;
16254
- }
16255
- }
16256
-
16257
- var target = this.target,
16258
- options = target && target.options;
16259
-
16260
- if (target && (forceAction || !this.prepared.name)) {
16261
- action = action || validateAction(forceAction || target.getAction(pointer, event, this, curEventTarget), target, this.element);
16262
-
16263
- this.setEventXY(this.startCoords, this.pointers);
16264
-
16265
- if (!action) { return; }
16266
-
16267
- if (options.styleCursor) {
16268
- target._doc.documentElement.style.cursor = getActionCursor(action);
16269
- }
16270
-
16271
- this.resizeAxes = action.name === 'resize'? action.axis : null;
16272
-
16273
- if (action === 'gesture' && this.pointerIds.length < 2) {
16274
- action = null;
16275
- }
16276
-
16277
- this.prepared.name = action.name;
16278
- this.prepared.axis = action.axis;
16279
- this.prepared.edges = action.edges;
16280
-
16281
- this.snapStatus.snappedX = this.snapStatus.snappedY =
16282
- this.restrictStatus.restrictedX = this.restrictStatus.restrictedY = NaN;
16283
-
16284
- this.downTimes[pointerIndex] = new Date().getTime();
16285
- this.downTargets[pointerIndex] = eventTarget;
16286
- pointerExtend(this.downPointer, pointer);
16287
-
16288
- copyCoords(this.prevCoords, this.startCoords);
16289
- this.pointerWasMoved = false;
16290
-
16291
- this.checkAndPreventDefault(event, target, this.element);
16292
- }
16293
- // if inertia is active try to resume action
16294
- else if (this.inertiaStatus.active
16295
- && curEventTarget === this.element
16296
- && validateAction(target.getAction(pointer, event, this, this.element), target).name === this.prepared.name) {
16297
-
16298
- cancelFrame(this.inertiaStatus.i);
16299
- this.inertiaStatus.active = false;
16300
-
16301
- this.checkAndPreventDefault(event, target, this.element);
16302
- }
16303
- },
16304
-
16305
- setModifications: function (coords, preEnd) {
16306
- var target = this.target,
16307
- shouldMove = true,
16308
- shouldSnap = checkSnap(target, this.prepared.name) && (!target.options[this.prepared.name].snap.endOnly || preEnd),
16309
- shouldRestrict = checkRestrict(target, this.prepared.name) && (!target.options[this.prepared.name].restrict.endOnly || preEnd);
16310
-
16311
- if (shouldSnap ) { this.setSnapping (coords); } else { this.snapStatus .locked = false; }
16312
- if (shouldRestrict) { this.setRestriction(coords); } else { this.restrictStatus.restricted = false; }
16313
-
16314
- if (shouldSnap && this.snapStatus.locked && !this.snapStatus.changed) {
16315
- shouldMove = shouldRestrict && this.restrictStatus.restricted && this.restrictStatus.changed;
16316
- }
16317
- else if (shouldRestrict && this.restrictStatus.restricted && !this.restrictStatus.changed) {
16318
- shouldMove = false;
16319
- }
16320
-
16321
- return shouldMove;
16322
- },
16323
-
16324
- setStartOffsets: function (action, interactable, element) {
16325
- var rect = interactable.getRect(element),
16326
- origin = getOriginXY(interactable, element),
16327
- snap = interactable.options[this.prepared.name].snap,
16328
- restrict = interactable.options[this.prepared.name].restrict,
16329
- width, height;
16330
-
16331
- if (rect) {
16332
- this.startOffset.left = this.startCoords.page.x - rect.left;
16333
- this.startOffset.top = this.startCoords.page.y - rect.top;
16334
-
16335
- this.startOffset.right = rect.right - this.startCoords.page.x;
16336
- this.startOffset.bottom = rect.bottom - this.startCoords.page.y;
16337
-
16338
- if ('width' in rect) { width = rect.width; }
16339
- else { width = rect.right - rect.left; }
16340
- if ('height' in rect) { height = rect.height; }
16341
- else { height = rect.bottom - rect.top; }
16342
- }
16343
- else {
16344
- this.startOffset.left = this.startOffset.top = this.startOffset.right = this.startOffset.bottom = 0;
16345
- }
16346
-
16347
- this.snapOffsets.splice(0);
16348
-
16349
- var snapOffset = snap && snap.offset === 'startCoords'
16350
- ? {
16351
- x: this.startCoords.page.x - origin.x,
16352
- y: this.startCoords.page.y - origin.y
16353
- }
16354
- : snap && snap.offset || { x: 0, y: 0 };
16355
-
16356
- if (rect && snap && snap.relativePoints && snap.relativePoints.length) {
16357
- for (var i = 0; i < snap.relativePoints.length; i++) {
16358
- this.snapOffsets.push({
16359
- x: this.startOffset.left - (width * snap.relativePoints[i].x) + snapOffset.x,
16360
- y: this.startOffset.top - (height * snap.relativePoints[i].y) + snapOffset.y
16361
- });
16362
- }
16363
- }
16364
- else {
16365
- this.snapOffsets.push(snapOffset);
16366
- }
16367
-
16368
- if (rect && restrict.elementRect) {
16369
- this.restrictOffset.left = this.startOffset.left - (width * restrict.elementRect.left);
16370
- this.restrictOffset.top = this.startOffset.top - (height * restrict.elementRect.top);
16371
-
16372
- this.restrictOffset.right = this.startOffset.right - (width * (1 - restrict.elementRect.right));
16373
- this.restrictOffset.bottom = this.startOffset.bottom - (height * (1 - restrict.elementRect.bottom));
16374
- }
16375
- else {
16376
- this.restrictOffset.left = this.restrictOffset.top = this.restrictOffset.right = this.restrictOffset.bottom = 0;
16377
- }
16378
- },
16379
-
16380
- /*\
16381
- * Interaction.start
16382
- [ method ]
16383
- *
16384
- * Start an action with the given Interactable and Element as tartgets. The
16385
- * action must be enabled for the target Interactable and an appropriate number
16386
- * of pointers must be held down – 1 for drag/resize, 2 for gesture.
16387
- *
16388
- * Use it with `interactable.<action>able({ manualStart: false })` to always
16389
- * [start actions manually](https://github.com/taye/interact.js/issues/114)
16390
- *
16391
- - action (object) The action to be performed - drag, resize, etc.
16392
- - interactable (Interactable) The Interactable to target
16393
- - element (Element) The DOM Element to target
16394
- = (object) interact
16395
- **
16396
- | interact(target)
16397
- | .draggable({
16398
- | // disable the default drag start by down->move
16399
- | manualStart: true
16400
- | })
16401
- | // start dragging after the user holds the pointer down
16402
- | .on('hold', function (event) {
16403
- | var interaction = event.interaction;
16404
- |
16405
- | if (!interaction.interacting()) {
16406
- | interaction.start({ name: 'drag' },
16407
- | event.interactable,
16408
- | event.currentTarget);
16409
- | }
16410
- | });
16411
- \*/
16412
- start: function (action, interactable, element) {
16413
- if (this.interacting()
16414
- || !this.pointerIsDown
16415
- || this.pointerIds.length < (action.name === 'gesture'? 2 : 1)) {
16416
- return;
16417
- }
16418
-
16419
- // if this interaction had been removed after stopping
16420
- // add it back
16421
- if (indexOf(interactions, this) === -1) {
16422
- interactions.push(this);
16423
- }
16424
-
16425
- // set the startCoords if there was no prepared action
16426
- if (!this.prepared.name) {
16427
- this.setEventXY(this.startCoords, this.pointers);
16428
- }
16429
-
16430
- this.prepared.name = action.name;
16431
- this.prepared.axis = action.axis;
16432
- this.prepared.edges = action.edges;
16433
- this.target = interactable;
16434
- this.element = element;
16435
-
16436
- this.setStartOffsets(action.name, interactable, element);
16437
- this.setModifications(this.startCoords.page);
16438
-
16439
- this.prevEvent = this[this.prepared.name + 'Start'](this.downEvent);
16440
- },
16441
-
16442
- pointerMove: function (pointer, event, eventTarget, curEventTarget, preEnd) {
16443
- if (this.inertiaStatus.active) {
16444
- var pageUp = this.inertiaStatus.upCoords.page;
16445
- var clientUp = this.inertiaStatus.upCoords.client;
16446
-
16447
- var inertiaPosition = {
16448
- pageX : pageUp.x + this.inertiaStatus.sx,
16449
- pageY : pageUp.y + this.inertiaStatus.sy,
16450
- clientX: clientUp.x + this.inertiaStatus.sx,
16451
- clientY: clientUp.y + this.inertiaStatus.sy
16452
- };
16453
-
16454
- this.setEventXY(this.curCoords, [inertiaPosition]);
16455
- }
16456
- else {
16457
- this.recordPointer(pointer);
16458
- this.setEventXY(this.curCoords, this.pointers);
16459
- }
16460
-
16461
- var duplicateMove = (this.curCoords.page.x === this.prevCoords.page.x
16462
- && this.curCoords.page.y === this.prevCoords.page.y
16463
- && this.curCoords.client.x === this.prevCoords.client.x
16464
- && this.curCoords.client.y === this.prevCoords.client.y);
16465
-
16466
- var dx, dy,
16467
- pointerIndex = this.mouse? 0 : indexOf(this.pointerIds, getPointerId(pointer));
16468
-
16469
- // register movement greater than pointerMoveTolerance
16470
- if (this.pointerIsDown && !this.pointerWasMoved) {
16471
- dx = this.curCoords.client.x - this.startCoords.client.x;
16472
- dy = this.curCoords.client.y - this.startCoords.client.y;
16473
-
16474
- this.pointerWasMoved = hypot(dx, dy) > pointerMoveTolerance;
16475
- }
16476
-
16477
- if (!duplicateMove && (!this.pointerIsDown || this.pointerWasMoved)) {
16478
- if (this.pointerIsDown) {
16479
- clearTimeout(this.holdTimers[pointerIndex]);
16480
- }
16481
-
16482
- this.collectEventTargets(pointer, event, eventTarget, 'move');
16483
- }
16484
-
16485
- if (!this.pointerIsDown) { return; }
16486
-
16487
- if (duplicateMove && this.pointerWasMoved && !preEnd) {
16488
- this.checkAndPreventDefault(event, this.target, this.element);
16489
- return;
16490
- }
16491
-
16492
- // set pointer coordinate, time changes and speeds
16493
- setEventDeltas(this.pointerDelta, this.prevCoords, this.curCoords);
16494
-
16495
- if (!this.prepared.name) { return; }
16496
-
16497
- if (this.pointerWasMoved
16498
- // ignore movement while inertia is active
16499
- && (!this.inertiaStatus.active || (pointer instanceof InteractEvent && /inertiastart/.test(pointer.type)))) {
16500
-
16501
- // if just starting an action, calculate the pointer speed now
16502
- if (!this.interacting()) {
16503
- setEventDeltas(this.pointerDelta, this.prevCoords, this.curCoords);
16504
-
16505
- // check if a drag is in the correct axis
16506
- if (this.prepared.name === 'drag') {
16507
- var absX = Math.abs(dx),
16508
- absY = Math.abs(dy),
16509
- targetAxis = this.target.options.drag.axis,
16510
- axis = (absX > absY ? 'x' : absX < absY ? 'y' : 'xy');
16511
-
16512
- // if the movement isn't in the axis of the interactable
16513
- if (axis !== 'xy' && targetAxis !== 'xy' && targetAxis !== axis) {
16514
- // cancel the prepared action
16515
- this.prepared.name = null;
16516
-
16517
- // then try to get a drag from another ineractable
16518
-
16519
- var element = eventTarget;
16520
-
16521
- // check element interactables
16522
- while (isElement(element)) {
16523
- var elementInteractable = interactables.get(element);
16524
-
16525
- if (elementInteractable
16526
- && elementInteractable !== this.target
16527
- && !elementInteractable.options.drag.manualStart
16528
- && elementInteractable.getAction(this.downPointer, this.downEvent, this, element).name === 'drag'
16529
- && checkAxis(axis, elementInteractable)) {
16530
-
16531
- this.prepared.name = 'drag';
16532
- this.target = elementInteractable;
16533
- this.element = element;
16534
- break;
16535
- }
16536
-
16537
- element = parentElement(element);
16538
- }
16539
-
16540
- // if there's no drag from element interactables,
16541
- // check the selector interactables
16542
- if (!this.prepared.name) {
16543
- var thisInteraction = this;
16544
-
16545
- var getDraggable = function (interactable, selector, context) {
16546
- var elements = ie8MatchesSelector
16547
- ? context.querySelectorAll(selector)
16548
- : undefined;
16549
-
16550
- if (interactable === thisInteraction.target) { return; }
16551
-
16552
- if (inContext(interactable, eventTarget)
16553
- && !interactable.options.drag.manualStart
16554
- && !testIgnore(interactable, element, eventTarget)
16555
- && testAllow(interactable, element, eventTarget)
16556
- && matchesSelector(element, selector, elements)
16557
- && interactable.getAction(thisInteraction.downPointer, thisInteraction.downEvent, thisInteraction, element).name === 'drag'
16558
- && checkAxis(axis, interactable)
16559
- && withinInteractionLimit(interactable, element, 'drag')) {
16560
-
16561
- return interactable;
16562
- }
16563
- };
16564
-
16565
- element = eventTarget;
16566
-
16567
- while (isElement(element)) {
16568
- var selectorInteractable = interactables.forEachSelector(getDraggable);
16569
-
16570
- if (selectorInteractable) {
16571
- this.prepared.name = 'drag';
16572
- this.target = selectorInteractable;
16573
- this.element = element;
16574
- break;
16575
- }
16576
-
16577
- element = parentElement(element);
16578
- }
16579
- }
16580
- }
16581
- }
16582
- }
16583
-
16584
- var starting = !!this.prepared.name && !this.interacting();
16585
-
16586
- if (starting
16587
- && (this.target.options[this.prepared.name].manualStart
16588
- || !withinInteractionLimit(this.target, this.element, this.prepared))) {
16589
- this.stop(event);
16590
- return;
16591
- }
16592
-
16593
- if (this.prepared.name && this.target) {
16594
- if (starting) {
16595
- this.start(this.prepared, this.target, this.element);
16596
- }
16597
-
16598
- var shouldMove = this.setModifications(this.curCoords.page, preEnd);
16599
-
16600
- // move if snapping or restriction doesn't prevent it
16601
- if (shouldMove || starting) {
16602
- this.prevEvent = this[this.prepared.name + 'Move'](event);
16603
- }
16604
-
16605
- this.checkAndPreventDefault(event, this.target, this.element);
16606
- }
16607
- }
16608
-
16609
- copyCoords(this.prevCoords, this.curCoords);
16610
-
16611
- if (this.dragging || this.resizing) {
16612
- this.autoScrollMove(pointer);
16613
- }
16614
- },
16615
-
16616
- dragStart: function (event) {
16617
- var dragEvent = new InteractEvent(this, event, 'drag', 'start', this.element);
16618
-
16619
- this.dragging = true;
16620
- this.target.fire(dragEvent);
16621
-
16622
- // reset active dropzones
16623
- this.activeDrops.dropzones = [];
16624
- this.activeDrops.elements = [];
16625
- this.activeDrops.rects = [];
16626
-
16627
- if (!this.dynamicDrop) {
16628
- this.setActiveDrops(this.element);
16629
- }
16630
-
16631
- var dropEvents = this.getDropEvents(event, dragEvent);
16632
-
16633
- if (dropEvents.activate) {
16634
- this.fireActiveDrops(dropEvents.activate);
16635
- }
16636
-
16637
- return dragEvent;
16638
- },
16639
-
16640
- dragMove: function (event) {
16641
- var target = this.target,
16642
- dragEvent = new InteractEvent(this, event, 'drag', 'move', this.element),
16643
- draggableElement = this.element,
16644
- drop = this.getDrop(dragEvent, event, draggableElement);
16645
-
16646
- this.dropTarget = drop.dropzone;
16647
- this.dropElement = drop.element;
16648
-
16649
- var dropEvents = this.getDropEvents(event, dragEvent);
16650
-
16651
- target.fire(dragEvent);
16652
-
16653
- if (dropEvents.leave) { this.prevDropTarget.fire(dropEvents.leave); }
16654
- if (dropEvents.enter) { this.dropTarget.fire(dropEvents.enter); }
16655
- if (dropEvents.move ) { this.dropTarget.fire(dropEvents.move ); }
16656
-
16657
- this.prevDropTarget = this.dropTarget;
16658
- this.prevDropElement = this.dropElement;
16659
-
16660
- return dragEvent;
16661
- },
16662
-
16663
- resizeStart: function (event) {
16664
- var resizeEvent = new InteractEvent(this, event, 'resize', 'start', this.element);
16665
-
16666
- if (this.prepared.edges) {
16667
- var startRect = this.target.getRect(this.element);
16668
-
16669
- /*
16670
- * When using the `resizable.square` or `resizable.preserveAspectRatio` options, resizing from one edge
16671
- * will affect another. E.g. with `resizable.square`, resizing to make the right edge larger will make
16672
- * the bottom edge larger by the same amount. We call these 'linked' edges. Any linked edges will depend
16673
- * on the active edges and the edge being interacted with.
16674
- */
16675
- if (this.target.options.resize.square || this.target.options.resize.preserveAspectRatio) {
16676
- var linkedEdges = extend({}, this.prepared.edges);
16677
-
16678
- linkedEdges.top = linkedEdges.top || (linkedEdges.left && !linkedEdges.bottom);
16679
- linkedEdges.left = linkedEdges.left || (linkedEdges.top && !linkedEdges.right );
16680
- linkedEdges.bottom = linkedEdges.bottom || (linkedEdges.right && !linkedEdges.top );
16681
- linkedEdges.right = linkedEdges.right || (linkedEdges.bottom && !linkedEdges.left );
16682
-
16683
- this.prepared._linkedEdges = linkedEdges;
16684
- }
16685
- else {
16686
- this.prepared._linkedEdges = null;
16687
- }
16688
-
16689
- // if using `resizable.preserveAspectRatio` option, record aspect ratio at the start of the resize
16690
- if (this.target.options.resize.preserveAspectRatio) {
16691
- this.resizeStartAspectRatio = startRect.width / startRect.height;
16692
- }
16693
-
16694
- this.resizeRects = {
16695
- start : startRect,
16696
- current : extend({}, startRect),
16697
- restricted: extend({}, startRect),
16698
- previous : extend({}, startRect),
16699
- delta : {
16700
- left: 0, right : 0, width : 0,
16701
- top : 0, bottom: 0, height: 0
16702
- }
16703
- };
16704
-
16705
- resizeEvent.rect = this.resizeRects.restricted;
16706
- resizeEvent.deltaRect = this.resizeRects.delta;
16707
- }
16708
-
16709
- this.target.fire(resizeEvent);
16710
-
16711
- this.resizing = true;
16712
-
16713
- return resizeEvent;
16714
- },
16715
-
16716
- resizeMove: function (event) {
16717
- var resizeEvent = new InteractEvent(this, event, 'resize', 'move', this.element);
16718
-
16719
- var edges = this.prepared.edges,
16720
- invert = this.target.options.resize.invert,
16721
- invertible = invert === 'reposition' || invert === 'negate';
16722
-
16723
- if (edges) {
16724
- var dx = resizeEvent.dx,
16725
- dy = resizeEvent.dy,
16726
-
16727
- start = this.resizeRects.start,
16728
- current = this.resizeRects.current,
16729
- restricted = this.resizeRects.restricted,
16730
- delta = this.resizeRects.delta,
16731
- previous = extend(this.resizeRects.previous, restricted),
16732
-
16733
- originalEdges = edges;
16734
-
16735
- // `resize.preserveAspectRatio` takes precedence over `resize.square`
16736
- if (this.target.options.resize.preserveAspectRatio) {
16737
- var resizeStartAspectRatio = this.resizeStartAspectRatio;
16738
-
16739
- edges = this.prepared._linkedEdges;
16740
-
16741
- if ((originalEdges.left && originalEdges.bottom)
16742
- || (originalEdges.right && originalEdges.top)) {
16743
- dy = -dx / resizeStartAspectRatio;
16744
- }
16745
- else if (originalEdges.left || originalEdges.right) { dy = dx / resizeStartAspectRatio; }
16746
- else if (originalEdges.top || originalEdges.bottom) { dx = dy * resizeStartAspectRatio; }
16747
- }
16748
- else if (this.target.options.resize.square) {
16749
- edges = this.prepared._linkedEdges;
16750
-
16751
- if ((originalEdges.left && originalEdges.bottom)
16752
- || (originalEdges.right && originalEdges.top)) {
16753
- dy = -dx;
16754
- }
16755
- else if (originalEdges.left || originalEdges.right) { dy = dx; }
16756
- else if (originalEdges.top || originalEdges.bottom) { dx = dy; }
16757
- }
16758
-
16759
- // update the 'current' rect without modifications
16760
- if (edges.top ) { current.top += dy; }
16761
- if (edges.bottom) { current.bottom += dy; }
16762
- if (edges.left ) { current.left += dx; }
16763
- if (edges.right ) { current.right += dx; }
16764
-
16765
- if (invertible) {
16766
- // if invertible, copy the current rect
16767
- extend(restricted, current);
16768
-
16769
- if (invert === 'reposition') {
16770
- // swap edge values if necessary to keep width/height positive
16771
- var swap;
16772
-
16773
- if (restricted.top > restricted.bottom) {
16774
- swap = restricted.top;
16775
-
16776
- restricted.top = restricted.bottom;
16777
- restricted.bottom = swap;
16778
- }
16779
- if (restricted.left > restricted.right) {
16780
- swap = restricted.left;
16781
-
16782
- restricted.left = restricted.right;
16783
- restricted.right = swap;
16784
- }
16785
- }
16786
- }
16787
- else {
16788
- // if not invertible, restrict to minimum of 0x0 rect
16789
- restricted.top = Math.min(current.top, start.bottom);
16790
- restricted.bottom = Math.max(current.bottom, start.top);
16791
- restricted.left = Math.min(current.left, start.right);
16792
- restricted.right = Math.max(current.right, start.left);
16793
- }
16794
-
16795
- restricted.width = restricted.right - restricted.left;
16796
- restricted.height = restricted.bottom - restricted.top ;
16797
-
16798
- for (var edge in restricted) {
16799
- delta[edge] = restricted[edge] - previous[edge];
16800
- }
16801
-
16802
- resizeEvent.edges = this.prepared.edges;
16803
- resizeEvent.rect = restricted;
16804
- resizeEvent.deltaRect = delta;
16805
- }
16806
-
16807
- this.target.fire(resizeEvent);
16808
-
16809
- return resizeEvent;
16810
- },
16811
-
16812
- gestureStart: function (event) {
16813
- var gestureEvent = new InteractEvent(this, event, 'gesture', 'start', this.element);
16814
-
16815
- gestureEvent.ds = 0;
16816
-
16817
- this.gesture.startDistance = this.gesture.prevDistance = gestureEvent.distance;
16818
- this.gesture.startAngle = this.gesture.prevAngle = gestureEvent.angle;
16819
- this.gesture.scale = 1;
16820
-
16821
- this.gesturing = true;
16822
-
16823
- this.target.fire(gestureEvent);
16824
-
16825
- return gestureEvent;
16826
- },
16827
-
16828
- gestureMove: function (event) {
16829
- if (!this.pointerIds.length) {
16830
- return this.prevEvent;
16831
- }
16832
-
16833
- var gestureEvent;
16834
-
16835
- gestureEvent = new InteractEvent(this, event, 'gesture', 'move', this.element);
16836
- gestureEvent.ds = gestureEvent.scale - this.gesture.scale;
16837
-
16838
- this.target.fire(gestureEvent);
16839
-
16840
- this.gesture.prevAngle = gestureEvent.angle;
16841
- this.gesture.prevDistance = gestureEvent.distance;
16842
-
16843
- if (gestureEvent.scale !== Infinity &&
16844
- gestureEvent.scale !== null &&
16845
- gestureEvent.scale !== undefined &&
16846
- !isNaN(gestureEvent.scale)) {
16847
-
16848
- this.gesture.scale = gestureEvent.scale;
16849
- }
16850
-
16851
- return gestureEvent;
16852
- },
16853
-
16854
- pointerHold: function (pointer, event, eventTarget) {
16855
- this.collectEventTargets(pointer, event, eventTarget, 'hold');
16856
- },
16857
-
16858
- pointerUp: function (pointer, event, eventTarget, curEventTarget) {
16859
- var pointerIndex = this.mouse? 0 : indexOf(this.pointerIds, getPointerId(pointer));
16860
-
16861
- clearTimeout(this.holdTimers[pointerIndex]);
16862
-
16863
- this.collectEventTargets(pointer, event, eventTarget, 'up' );
16864
- this.collectEventTargets(pointer, event, eventTarget, 'tap');
16865
-
16866
- this.pointerEnd(pointer, event, eventTarget, curEventTarget);
16867
-
16868
- this.removePointer(pointer);
16869
- },
16870
-
16871
- pointerCancel: function (pointer, event, eventTarget, curEventTarget) {
16872
- var pointerIndex = this.mouse? 0 : indexOf(this.pointerIds, getPointerId(pointer));
16873
-
16874
- clearTimeout(this.holdTimers[pointerIndex]);
16875
-
16876
- this.collectEventTargets(pointer, event, eventTarget, 'cancel');
16877
- this.pointerEnd(pointer, event, eventTarget, curEventTarget);
16878
-
16879
- this.removePointer(pointer);
16880
- },
16881
-
16882
- // http://www.quirksmode.org/dom/events/click.html
16883
- // >Events leading to dblclick
16884
- //
16885
- // IE8 doesn't fire down event before dblclick.
16886
- // This workaround tries to fire a tap and doubletap after dblclick
16887
- ie8Dblclick: function (pointer, event, eventTarget) {
16888
- if (this.prevTap
16889
- && event.clientX === this.prevTap.clientX
16890
- && event.clientY === this.prevTap.clientY
16891
- && eventTarget === this.prevTap.target) {
16892
-
16893
- this.downTargets[0] = eventTarget;
16894
- this.downTimes[0] = new Date().getTime();
16895
- this.collectEventTargets(pointer, event, eventTarget, 'tap');
16896
- }
16897
- },
16898
-
16899
- // End interact move events and stop auto-scroll unless inertia is enabled
16900
- pointerEnd: function (pointer, event, eventTarget, curEventTarget) {
16901
- var endEvent,
16902
- target = this.target,
16903
- options = target && target.options,
16904
- inertiaOptions = options && this.prepared.name && options[this.prepared.name].inertia,
16905
- inertiaStatus = this.inertiaStatus;
16906
-
16907
- if (this.interacting()) {
16908
-
16909
- if (inertiaStatus.active && !inertiaStatus.ending) { return; }
16910
-
16911
- var pointerSpeed,
16912
- now = new Date().getTime(),
16913
- inertiaPossible = false,
16914
- inertia = false,
16915
- smoothEnd = false,
16916
- endSnap = checkSnap(target, this.prepared.name) && options[this.prepared.name].snap.endOnly,
16917
- endRestrict = checkRestrict(target, this.prepared.name) && options[this.prepared.name].restrict.endOnly,
16918
- dx = 0,
16919
- dy = 0,
16920
- startEvent;
16921
-
16922
- if (this.dragging) {
16923
- if (options.drag.axis === 'x' ) { pointerSpeed = Math.abs(this.pointerDelta.client.vx); }
16924
- else if (options.drag.axis === 'y' ) { pointerSpeed = Math.abs(this.pointerDelta.client.vy); }
16925
- else /*options.drag.axis === 'xy'*/{ pointerSpeed = this.pointerDelta.client.speed; }
16926
- }
16927
- else {
16928
- pointerSpeed = this.pointerDelta.client.speed;
16929
- }
16930
-
16931
- // check if inertia should be started
16932
- inertiaPossible = (inertiaOptions && inertiaOptions.enabled
16933
- && this.prepared.name !== 'gesture'
16934
- && event !== inertiaStatus.startEvent);
16935
-
16936
- inertia = (inertiaPossible
16937
- && (now - this.curCoords.timeStamp) < 50
16938
- && pointerSpeed > inertiaOptions.minSpeed
16939
- && pointerSpeed > inertiaOptions.endSpeed);
16940
-
16941
- if (inertiaPossible && !inertia && (endSnap || endRestrict)) {
16942
-
16943
- var snapRestrict = {};
16944
-
16945
- snapRestrict.snap = snapRestrict.restrict = snapRestrict;
16946
-
16947
- if (endSnap) {
16948
- this.setSnapping(this.curCoords.page, snapRestrict);
16949
- if (snapRestrict.locked) {
16950
- dx += snapRestrict.dx;
16951
- dy += snapRestrict.dy;
16952
- }
16953
- }
16954
-
16955
- if (endRestrict) {
16956
- this.setRestriction(this.curCoords.page, snapRestrict);
16957
- if (snapRestrict.restricted) {
16958
- dx += snapRestrict.dx;
16959
- dy += snapRestrict.dy;
16960
- }
16961
- }
16962
-
16963
- if (dx || dy) {
16964
- smoothEnd = true;
16965
- }
16966
- }
16967
-
16968
- if (inertia || smoothEnd) {
16969
- copyCoords(inertiaStatus.upCoords, this.curCoords);
16970
-
16971
- this.pointers[0] = inertiaStatus.startEvent = startEvent =
16972
- new InteractEvent(this, event, this.prepared.name, 'inertiastart', this.element);
16973
-
16974
- inertiaStatus.t0 = now;
16975
-
16976
- target.fire(inertiaStatus.startEvent);
16977
-
16978
- if (inertia) {
16979
- inertiaStatus.vx0 = this.pointerDelta.client.vx;
16980
- inertiaStatus.vy0 = this.pointerDelta.client.vy;
16981
- inertiaStatus.v0 = pointerSpeed;
16982
-
16983
- this.calcInertia(inertiaStatus);
16984
-
16985
- var page = extend({}, this.curCoords.page),
16986
- origin = getOriginXY(target, this.element),
16987
- statusObject;
16988
-
16989
- page.x = page.x + inertiaStatus.xe - origin.x;
16990
- page.y = page.y + inertiaStatus.ye - origin.y;
16991
-
16992
- statusObject = {
16993
- useStatusXY: true,
16994
- x: page.x,
16995
- y: page.y,
16996
- dx: 0,
16997
- dy: 0,
16998
- snap: null
16999
- };
17000
-
17001
- statusObject.snap = statusObject;
17002
-
17003
- dx = dy = 0;
17004
-
17005
- if (endSnap) {
17006
- var snap = this.setSnapping(this.curCoords.page, statusObject);
17007
-
17008
- if (snap.locked) {
17009
- dx += snap.dx;
17010
- dy += snap.dy;
17011
- }
17012
- }
17013
-
17014
- if (endRestrict) {
17015
- var restrict = this.setRestriction(this.curCoords.page, statusObject);
17016
-
17017
- if (restrict.restricted) {
17018
- dx += restrict.dx;
17019
- dy += restrict.dy;
17020
- }
17021
- }
17022
-
17023
- inertiaStatus.modifiedXe += dx;
17024
- inertiaStatus.modifiedYe += dy;
17025
-
17026
- inertiaStatus.i = reqFrame(this.boundInertiaFrame);
17027
- }
17028
- else {
17029
- inertiaStatus.smoothEnd = true;
17030
- inertiaStatus.xe = dx;
17031
- inertiaStatus.ye = dy;
17032
-
17033
- inertiaStatus.sx = inertiaStatus.sy = 0;
17034
-
17035
- inertiaStatus.i = reqFrame(this.boundSmoothEndFrame);
17036
- }
17037
-
17038
- inertiaStatus.active = true;
17039
- return;
17040
- }
17041
-
17042
- if (endSnap || endRestrict) {
17043
- // fire a move event at the snapped coordinates
17044
- this.pointerMove(pointer, event, eventTarget, curEventTarget, true);
17045
- }
17046
- }
17047
-
17048
- if (this.dragging) {
17049
- endEvent = new InteractEvent(this, event, 'drag', 'end', this.element);
17050
-
17051
- var draggableElement = this.element,
17052
- drop = this.getDrop(endEvent, event, draggableElement);
17053
-
17054
- this.dropTarget = drop.dropzone;
17055
- this.dropElement = drop.element;
17056
-
17057
- var dropEvents = this.getDropEvents(event, endEvent);
17058
-
17059
- if (dropEvents.leave) { this.prevDropTarget.fire(dropEvents.leave); }
17060
- if (dropEvents.enter) { this.dropTarget.fire(dropEvents.enter); }
17061
- if (dropEvents.drop ) { this.dropTarget.fire(dropEvents.drop ); }
17062
- if (dropEvents.deactivate) {
17063
- this.fireActiveDrops(dropEvents.deactivate);
17064
- }
17065
-
17066
- target.fire(endEvent);
17067
- }
17068
- else if (this.resizing) {
17069
- endEvent = new InteractEvent(this, event, 'resize', 'end', this.element);
17070
- target.fire(endEvent);
17071
- }
17072
- else if (this.gesturing) {
17073
- endEvent = new InteractEvent(this, event, 'gesture', 'end', this.element);
17074
- target.fire(endEvent);
17075
- }
17076
-
17077
- this.stop(event);
17078
- },
17079
-
17080
- collectDrops: function (element) {
17081
- var drops = [],
17082
- elements = [],
17083
- i;
17084
-
17085
- element = element || this.element;
17086
-
17087
- // collect all dropzones and their elements which qualify for a drop
17088
- for (i = 0; i < interactables.length; i++) {
17089
- if (!interactables[i].options.drop.enabled) { continue; }
17090
-
17091
- var current = interactables[i],
17092
- accept = current.options.drop.accept;
17093
-
17094
- // test the draggable element against the dropzone's accept setting
17095
- if ((isElement(accept) && accept !== element)
17096
- || (isString(accept)
17097
- && !matchesSelector(element, accept))) {
17098
-
17099
- continue;
17100
- }
17101
-
17102
- // query for new elements if necessary
17103
- var dropElements = current.selector? current._context.querySelectorAll(current.selector) : [current._element];
17104
-
17105
- for (var j = 0, len = dropElements.length; j < len; j++) {
17106
- var currentElement = dropElements[j];
17107
-
17108
- if (currentElement === element) {
17109
- continue;
17110
- }
17111
-
17112
- drops.push(current);
17113
- elements.push(currentElement);
17114
- }
17115
- }
17116
-
17117
- return {
17118
- dropzones: drops,
17119
- elements: elements
17120
- };
17121
- },
17122
-
17123
- fireActiveDrops: function (event) {
17124
- var i,
17125
- current,
17126
- currentElement,
17127
- prevElement;
17128
-
17129
- // loop through all active dropzones and trigger event
17130
- for (i = 0; i < this.activeDrops.dropzones.length; i++) {
17131
- current = this.activeDrops.dropzones[i];
17132
- currentElement = this.activeDrops.elements [i];
17133
-
17134
- // prevent trigger of duplicate events on same element
17135
- if (currentElement !== prevElement) {
17136
- // set current element as event target
17137
- event.target = currentElement;
17138
- current.fire(event);
17139
- }
17140
- prevElement = currentElement;
17141
- }
17142
- },
17143
-
17144
- // Collect a new set of possible drops and save them in activeDrops.
17145
- // setActiveDrops should always be called when a drag has just started or a
17146
- // drag event happens while dynamicDrop is true
17147
- setActiveDrops: function (dragElement) {
17148
- // get dropzones and their elements that could receive the draggable
17149
- var possibleDrops = this.collectDrops(dragElement, true);
17150
-
17151
- this.activeDrops.dropzones = possibleDrops.dropzones;
17152
- this.activeDrops.elements = possibleDrops.elements;
17153
- this.activeDrops.rects = [];
17154
-
17155
- for (var i = 0; i < this.activeDrops.dropzones.length; i++) {
17156
- this.activeDrops.rects[i] = this.activeDrops.dropzones[i].getRect(this.activeDrops.elements[i]);
17157
- }
17158
- },
17159
-
17160
- getDrop: function (dragEvent, event, dragElement) {
17161
- var validDrops = [];
17162
-
17163
- if (dynamicDrop) {
17164
- this.setActiveDrops(dragElement);
17165
- }
17166
-
17167
- // collect all dropzones and their elements which qualify for a drop
17168
- for (var j = 0; j < this.activeDrops.dropzones.length; j++) {
17169
- var current = this.activeDrops.dropzones[j],
17170
- currentElement = this.activeDrops.elements [j],
17171
- rect = this.activeDrops.rects [j];
17172
-
17173
- validDrops.push(current.dropCheck(dragEvent, event, this.target, dragElement, currentElement, rect)
17174
- ? currentElement
17175
- : null);
17176
- }
17177
-
17178
- // get the most appropriate dropzone based on DOM depth and order
17179
- var dropIndex = indexOfDeepestElement(validDrops),
17180
- dropzone = this.activeDrops.dropzones[dropIndex] || null,
17181
- element = this.activeDrops.elements [dropIndex] || null;
17182
-
17183
- return {
17184
- dropzone: dropzone,
17185
- element: element
17186
- };
17187
- },
17188
-
17189
- getDropEvents: function (pointerEvent, dragEvent) {
17190
- var dropEvents = {
17191
- enter : null,
17192
- leave : null,
17193
- activate : null,
17194
- deactivate: null,
17195
- move : null,
17196
- drop : null
17197
- };
17198
-
17199
- if (this.dropElement !== this.prevDropElement) {
17200
- // if there was a prevDropTarget, create a dragleave event
17201
- if (this.prevDropTarget) {
17202
- dropEvents.leave = {
17203
- target : this.prevDropElement,
17204
- dropzone : this.prevDropTarget,
17205
- relatedTarget: dragEvent.target,
17206
- draggable : dragEvent.interactable,
17207
- dragEvent : dragEvent,
17208
- interaction : this,
17209
- timeStamp : dragEvent.timeStamp,
17210
- type : 'dragleave'
17211
- };
17212
-
17213
- dragEvent.dragLeave = this.prevDropElement;
17214
- dragEvent.prevDropzone = this.prevDropTarget;
17215
- }
17216
- // if the dropTarget is not null, create a dragenter event
17217
- if (this.dropTarget) {
17218
- dropEvents.enter = {
17219
- target : this.dropElement,
17220
- dropzone : this.dropTarget,
17221
- relatedTarget: dragEvent.target,
17222
- draggable : dragEvent.interactable,
17223
- dragEvent : dragEvent,
17224
- interaction : this,
17225
- timeStamp : dragEvent.timeStamp,
17226
- type : 'dragenter'
17227
- };
17228
-
17229
- dragEvent.dragEnter = this.dropElement;
17230
- dragEvent.dropzone = this.dropTarget;
17231
- }
17232
- }
17233
-
17234
- if (dragEvent.type === 'dragend' && this.dropTarget) {
17235
- dropEvents.drop = {
17236
- target : this.dropElement,
17237
- dropzone : this.dropTarget,
17238
- relatedTarget: dragEvent.target,
17239
- draggable : dragEvent.interactable,
17240
- dragEvent : dragEvent,
17241
- interaction : this,
17242
- timeStamp : dragEvent.timeStamp,
17243
- type : 'drop'
17244
- };
17245
-
17246
- dragEvent.dropzone = this.dropTarget;
17247
- }
17248
- if (dragEvent.type === 'dragstart') {
17249
- dropEvents.activate = {
17250
- target : null,
17251
- dropzone : null,
17252
- relatedTarget: dragEvent.target,
17253
- draggable : dragEvent.interactable,
17254
- dragEvent : dragEvent,
17255
- interaction : this,
17256
- timeStamp : dragEvent.timeStamp,
17257
- type : 'dropactivate'
17258
- };
17259
- }
17260
- if (dragEvent.type === 'dragend') {
17261
- dropEvents.deactivate = {
17262
- target : null,
17263
- dropzone : null,
17264
- relatedTarget: dragEvent.target,
17265
- draggable : dragEvent.interactable,
17266
- dragEvent : dragEvent,
17267
- interaction : this,
17268
- timeStamp : dragEvent.timeStamp,
17269
- type : 'dropdeactivate'
17270
- };
17271
- }
17272
- if (dragEvent.type === 'dragmove' && this.dropTarget) {
17273
- dropEvents.move = {
17274
- target : this.dropElement,
17275
- dropzone : this.dropTarget,
17276
- relatedTarget: dragEvent.target,
17277
- draggable : dragEvent.interactable,
17278
- dragEvent : dragEvent,
17279
- interaction : this,
17280
- dragmove : dragEvent,
17281
- timeStamp : dragEvent.timeStamp,
17282
- type : 'dropmove'
17283
- };
17284
- dragEvent.dropzone = this.dropTarget;
17285
- }
17286
-
17287
- return dropEvents;
17288
- },
17289
-
17290
- currentAction: function () {
17291
- return (this.dragging && 'drag') || (this.resizing && 'resize') || (this.gesturing && 'gesture') || null;
17292
- },
17293
-
17294
- interacting: function () {
17295
- return this.dragging || this.resizing || this.gesturing;
17296
- },
17297
-
17298
- clearTargets: function () {
17299
- this.target = this.element = null;
17300
-
17301
- this.dropTarget = this.dropElement = this.prevDropTarget = this.prevDropElement = null;
17302
- },
17303
-
17304
- stop: function (event) {
17305
- if (this.interacting()) {
17306
- autoScroll.stop();
17307
- this.matches = [];
17308
- this.matchElements = [];
17309
-
17310
- var target = this.target;
17311
-
17312
- if (target.options.styleCursor) {
17313
- target._doc.documentElement.style.cursor = '';
17314
- }
17315
-
17316
- // prevent Default only if were previously interacting
17317
- if (event && isFunction(event.preventDefault)) {
17318
- this.checkAndPreventDefault(event, target, this.element);
17319
- }
17320
-
17321
- if (this.dragging) {
17322
- this.activeDrops.dropzones = this.activeDrops.elements = this.activeDrops.rects = null;
17323
- }
17324
- }
17325
-
17326
- this.clearTargets();
17327
-
17328
- this.pointerIsDown = this.snapStatus.locked = this.dragging = this.resizing = this.gesturing = false;
17329
- this.prepared.name = this.prevEvent = null;
17330
- this.inertiaStatus.resumeDx = this.inertiaStatus.resumeDy = 0;
17331
-
17332
- // remove pointers if their ID isn't in this.pointerIds
17333
- for (var i = 0; i < this.pointers.length; i++) {
17334
- if (indexOf(this.pointerIds, getPointerId(this.pointers[i])) === -1) {
17335
- this.pointers.splice(i, 1);
17336
- }
17337
- }
17338
- },
17339
-
17340
- inertiaFrame: function () {
17341
- var inertiaStatus = this.inertiaStatus,
17342
- options = this.target.options[this.prepared.name].inertia,
17343
- lambda = options.resistance,
17344
- t = new Date().getTime() / 1000 - inertiaStatus.t0;
17345
-
17346
- if (t < inertiaStatus.te) {
17347
-
17348
- var progress = 1 - (Math.exp(-lambda * t) - inertiaStatus.lambda_v0) / inertiaStatus.one_ve_v0;
17349
-
17350
- if (inertiaStatus.modifiedXe === inertiaStatus.xe && inertiaStatus.modifiedYe === inertiaStatus.ye) {
17351
- inertiaStatus.sx = inertiaStatus.xe * progress;
17352
- inertiaStatus.sy = inertiaStatus.ye * progress;
17353
- }
17354
- else {
17355
- var quadPoint = getQuadraticCurvePoint(
17356
- 0, 0,
17357
- inertiaStatus.xe, inertiaStatus.ye,
17358
- inertiaStatus.modifiedXe, inertiaStatus.modifiedYe,
17359
- progress);
17360
-
17361
- inertiaStatus.sx = quadPoint.x;
17362
- inertiaStatus.sy = quadPoint.y;
17363
- }
17364
-
17365
- this.pointerMove(inertiaStatus.startEvent, inertiaStatus.startEvent);
17366
-
17367
- inertiaStatus.i = reqFrame(this.boundInertiaFrame);
17368
- }
17369
- else {
17370
- inertiaStatus.ending = true;
17371
-
17372
- inertiaStatus.sx = inertiaStatus.modifiedXe;
17373
- inertiaStatus.sy = inertiaStatus.modifiedYe;
17374
-
17375
- this.pointerMove(inertiaStatus.startEvent, inertiaStatus.startEvent);
17376
- this.pointerEnd(inertiaStatus.startEvent, inertiaStatus.startEvent);
17377
-
17378
- inertiaStatus.active = inertiaStatus.ending = false;
17379
- }
17380
- },
17381
-
17382
- smoothEndFrame: function () {
17383
- var inertiaStatus = this.inertiaStatus,
17384
- t = new Date().getTime() - inertiaStatus.t0,
17385
- duration = this.target.options[this.prepared.name].inertia.smoothEndDuration;
17386
-
17387
- if (t < duration) {
17388
- inertiaStatus.sx = easeOutQuad(t, 0, inertiaStatus.xe, duration);
17389
- inertiaStatus.sy = easeOutQuad(t, 0, inertiaStatus.ye, duration);
17390
-
17391
- this.pointerMove(inertiaStatus.startEvent, inertiaStatus.startEvent);
17392
-
17393
- inertiaStatus.i = reqFrame(this.boundSmoothEndFrame);
17394
- }
17395
- else {
17396
- inertiaStatus.ending = true;
17397
-
17398
- inertiaStatus.sx = inertiaStatus.xe;
17399
- inertiaStatus.sy = inertiaStatus.ye;
17400
-
17401
- this.pointerMove(inertiaStatus.startEvent, inertiaStatus.startEvent);
17402
- this.pointerEnd(inertiaStatus.startEvent, inertiaStatus.startEvent);
17403
-
17404
- inertiaStatus.smoothEnd =
17405
- inertiaStatus.active = inertiaStatus.ending = false;
17406
- }
17407
- },
17408
-
17409
- addPointer: function (pointer) {
17410
- var id = getPointerId(pointer),
17411
- index = this.mouse? 0 : indexOf(this.pointerIds, id);
17412
-
17413
- if (index === -1) {
17414
- index = this.pointerIds.length;
17415
- }
17416
-
17417
- this.pointerIds[index] = id;
17418
- this.pointers[index] = pointer;
17419
-
17420
- return index;
17421
- },
17422
-
17423
- removePointer: function (pointer) {
17424
- var id = getPointerId(pointer),
17425
- index = this.mouse? 0 : indexOf(this.pointerIds, id);
17426
-
17427
- if (index === -1) { return; }
17428
-
17429
- this.pointers .splice(index, 1);
17430
- this.pointerIds .splice(index, 1);
17431
- this.downTargets.splice(index, 1);
17432
- this.downTimes .splice(index, 1);
17433
- this.holdTimers .splice(index, 1);
17434
- },
17435
-
17436
- recordPointer: function (pointer) {
17437
- var index = this.mouse? 0: indexOf(this.pointerIds, getPointerId(pointer));
17438
-
17439
- if (index === -1) { return; }
17440
-
17441
- this.pointers[index] = pointer;
17442
- },
17443
-
17444
- collectEventTargets: function (pointer, event, eventTarget, eventType) {
17445
- var pointerIndex = this.mouse? 0 : indexOf(this.pointerIds, getPointerId(pointer));
17446
-
17447
- // do not fire a tap event if the pointer was moved before being lifted
17448
- if (eventType === 'tap' && (this.pointerWasMoved
17449
- // or if the pointerup target is different to the pointerdown target
17450
- || !(this.downTargets[pointerIndex] && this.downTargets[pointerIndex] === eventTarget))) {
17451
- return;
17452
- }
17453
-
17454
- var targets = [],
17455
- elements = [],
17456
- element = eventTarget;
17457
-
17458
- function collectSelectors (interactable, selector, context) {
17459
- var els = ie8MatchesSelector
17460
- ? context.querySelectorAll(selector)
17461
- : undefined;
17462
-
17463
- if (interactable._iEvents[eventType]
17464
- && isElement(element)
17465
- && inContext(interactable, element)
17466
- && !testIgnore(interactable, element, eventTarget)
17467
- && testAllow(interactable, element, eventTarget)
17468
- && matchesSelector(element, selector, els)) {
17469
-
17470
- targets.push(interactable);
17471
- elements.push(element);
17472
- }
17473
- }
17474
-
17475
- while (element) {
17476
- if (interact.isSet(element) && interact(element)._iEvents[eventType]) {
17477
- targets.push(interact(element));
17478
- elements.push(element);
17479
- }
17480
-
17481
- interactables.forEachSelector(collectSelectors);
17482
-
17483
- element = parentElement(element);
17484
- }
17485
-
17486
- // create the tap event even if there are no listeners so that
17487
- // doubletap can still be created and fired
17488
- if (targets.length || eventType === 'tap') {
17489
- this.firePointers(pointer, event, eventTarget, targets, elements, eventType);
17490
- }
17491
- },
17492
-
17493
- firePointers: function (pointer, event, eventTarget, targets, elements, eventType) {
17494
- var pointerIndex = this.mouse? 0 : indexOf(this.pointerIds, getPointerId(pointer)),
17495
- pointerEvent = {},
17496
- i,
17497
- // for tap events
17498
- interval, createNewDoubleTap;
17499
-
17500
- // if it's a doubletap then the event properties would have been
17501
- // copied from the tap event and provided as the pointer argument
17502
- if (eventType === 'doubletap') {
17503
- pointerEvent = pointer;
17504
- }
17505
- else {
17506
- pointerExtend(pointerEvent, event);
17507
- if (event !== pointer) {
17508
- pointerExtend(pointerEvent, pointer);
17509
- }
17510
-
17511
- pointerEvent.preventDefault = preventOriginalDefault;
17512
- pointerEvent.stopPropagation = InteractEvent.prototype.stopPropagation;
17513
- pointerEvent.stopImmediatePropagation = InteractEvent.prototype.stopImmediatePropagation;
17514
- pointerEvent.interaction = this;
17515
-
17516
- pointerEvent.timeStamp = new Date().getTime();
17517
- pointerEvent.originalEvent = event;
17518
- pointerEvent.originalPointer = pointer;
17519
- pointerEvent.type = eventType;
17520
- pointerEvent.pointerId = getPointerId(pointer);
17521
- pointerEvent.pointerType = this.mouse? 'mouse' : !supportsPointerEvent? 'touch'
17522
- : isString(pointer.pointerType)
17523
- ? pointer.pointerType
17524
- : [,,'touch', 'pen', 'mouse'][pointer.pointerType];
17525
- }
17526
-
17527
- if (eventType === 'tap') {
17528
- pointerEvent.dt = pointerEvent.timeStamp - this.downTimes[pointerIndex];
17529
-
17530
- interval = pointerEvent.timeStamp - this.tapTime;
17531
- createNewDoubleTap = !!(this.prevTap && this.prevTap.type !== 'doubletap'
17532
- && this.prevTap.target === pointerEvent.target
17533
- && interval < 500);
17534
-
17535
- pointerEvent.double = createNewDoubleTap;
17536
-
17537
- this.tapTime = pointerEvent.timeStamp;
17538
- }
17539
-
17540
- for (i = 0; i < targets.length; i++) {
17541
- pointerEvent.currentTarget = elements[i];
17542
- pointerEvent.interactable = targets[i];
17543
- targets[i].fire(pointerEvent);
17544
-
17545
- if (pointerEvent.immediatePropagationStopped
17546
- ||(pointerEvent.propagationStopped && elements[i + 1] !== pointerEvent.currentTarget)) {
17547
- break;
17548
- }
17549
- }
17550
-
17551
- if (createNewDoubleTap) {
17552
- var doubleTap = {};
17553
-
17554
- extend(doubleTap, pointerEvent);
17555
-
17556
- doubleTap.dt = interval;
17557
- doubleTap.type = 'doubletap';
17558
-
17559
- this.collectEventTargets(doubleTap, event, eventTarget, 'doubletap');
17560
-
17561
- this.prevTap = doubleTap;
17562
- }
17563
- else if (eventType === 'tap') {
17564
- this.prevTap = pointerEvent;
17565
- }
17566
- },
17567
-
17568
- validateSelector: function (pointer, event, matches, matchElements) {
17569
- for (var i = 0, len = matches.length; i < len; i++) {
17570
- var match = matches[i],
17571
- matchElement = matchElements[i],
17572
- action = validateAction(match.getAction(pointer, event, this, matchElement), match);
17573
-
17574
- if (action && withinInteractionLimit(match, matchElement, action)) {
17575
- this.target = match;
17576
- this.element = matchElement;
17577
-
17578
- return action;
17579
- }
17580
- }
17581
- },
17582
-
17583
- setSnapping: function (pageCoords, status) {
17584
- var snap = this.target.options[this.prepared.name].snap,
17585
- targets = [],
17586
- target,
17587
- page,
17588
- i;
17589
-
17590
- status = status || this.snapStatus;
17591
-
17592
- if (status.useStatusXY) {
17593
- page = { x: status.x, y: status.y };
17594
- }
17595
- else {
17596
- var origin = getOriginXY(this.target, this.element);
17597
-
17598
- page = extend({}, pageCoords);
17599
-
17600
- page.x -= origin.x;
17601
- page.y -= origin.y;
17602
- }
17603
-
17604
- status.realX = page.x;
17605
- status.realY = page.y;
17606
-
17607
- page.x = page.x - this.inertiaStatus.resumeDx;
17608
- page.y = page.y - this.inertiaStatus.resumeDy;
17609
-
17610
- var len = snap.targets? snap.targets.length : 0;
17611
-
17612
- for (var relIndex = 0; relIndex < this.snapOffsets.length; relIndex++) {
17613
- var relative = {
17614
- x: page.x - this.snapOffsets[relIndex].x,
17615
- y: page.y - this.snapOffsets[relIndex].y
17616
- };
17617
-
17618
- for (i = 0; i < len; i++) {
17619
- if (isFunction(snap.targets[i])) {
17620
- target = snap.targets[i](relative.x, relative.y, this);
17621
- }
17622
- else {
17623
- target = snap.targets[i];
17624
- }
17625
-
17626
- if (!target) { continue; }
17627
-
17628
- targets.push({
17629
- x: isNumber(target.x) ? (target.x + this.snapOffsets[relIndex].x) : relative.x,
17630
- y: isNumber(target.y) ? (target.y + this.snapOffsets[relIndex].y) : relative.y,
17631
-
17632
- range: isNumber(target.range)? target.range: snap.range
17633
- });
17634
- }
17635
- }
17636
-
17637
- var closest = {
17638
- target: null,
17639
- inRange: false,
17640
- distance: 0,
17641
- range: 0,
17642
- dx: 0,
17643
- dy: 0
17644
- };
17645
-
17646
- for (i = 0, len = targets.length; i < len; i++) {
17647
- target = targets[i];
17648
-
17649
- var range = target.range,
17650
- dx = target.x - page.x,
17651
- dy = target.y - page.y,
17652
- distance = hypot(dx, dy),
17653
- inRange = distance <= range;
17654
-
17655
- // Infinite targets count as being out of range
17656
- // compared to non infinite ones that are in range
17657
- if (range === Infinity && closest.inRange && closest.range !== Infinity) {
17658
- inRange = false;
17659
- }
17660
-
17661
- if (!closest.target || (inRange
17662
- // is the closest target in range?
17663
- ? (closest.inRange && range !== Infinity
17664
- // the pointer is relatively deeper in this target
17665
- ? distance / range < closest.distance / closest.range
17666
- // this target has Infinite range and the closest doesn't
17667
- : (range === Infinity && closest.range !== Infinity)
17668
- // OR this target is closer that the previous closest
17669
- || distance < closest.distance)
17670
- // The other is not in range and the pointer is closer to this target
17671
- : (!closest.inRange && distance < closest.distance))) {
17672
-
17673
- if (range === Infinity) {
17674
- inRange = true;
17675
- }
17676
-
17677
- closest.target = target;
17678
- closest.distance = distance;
17679
- closest.range = range;
17680
- closest.inRange = inRange;
17681
- closest.dx = dx;
17682
- closest.dy = dy;
17683
-
17684
- status.range = range;
17685
- }
17686
- }
17687
-
17688
- var snapChanged;
17689
-
17690
- if (closest.target) {
17691
- snapChanged = (status.snappedX !== closest.target.x || status.snappedY !== closest.target.y);
17692
-
17693
- status.snappedX = closest.target.x;
17694
- status.snappedY = closest.target.y;
17695
- }
17696
- else {
17697
- snapChanged = true;
17698
-
17699
- status.snappedX = NaN;
17700
- status.snappedY = NaN;
17701
- }
17702
-
17703
- status.dx = closest.dx;
17704
- status.dy = closest.dy;
17705
-
17706
- status.changed = (snapChanged || (closest.inRange && !status.locked));
17707
- status.locked = closest.inRange;
17708
-
17709
- return status;
17710
- },
17711
-
17712
- setRestriction: function (pageCoords, status) {
17713
- var target = this.target,
17714
- restrict = target && target.options[this.prepared.name].restrict,
17715
- restriction = restrict && restrict.restriction,
17716
- page;
17717
-
17718
- if (!restriction) {
17719
- return status;
17720
- }
17721
-
17722
- status = status || this.restrictStatus;
17723
-
17724
- page = status.useStatusXY
17725
- ? page = { x: status.x, y: status.y }
17726
- : page = extend({}, pageCoords);
17727
-
17728
- if (status.snap && status.snap.locked) {
17729
- page.x += status.snap.dx || 0;
17730
- page.y += status.snap.dy || 0;
17731
- }
17732
-
17733
- page.x -= this.inertiaStatus.resumeDx;
17734
- page.y -= this.inertiaStatus.resumeDy;
17735
-
17736
- status.dx = 0;
17737
- status.dy = 0;
17738
- status.restricted = false;
17739
-
17740
- var rect, restrictedX, restrictedY;
17741
-
17742
- if (isString(restriction)) {
17743
- if (restriction === 'parent') {
17744
- restriction = parentElement(this.element);
17745
- }
17746
- else if (restriction === 'self') {
17747
- restriction = target.getRect(this.element);
17748
- }
17749
- else {
17750
- restriction = closest(this.element, restriction);
17751
- }
17752
-
17753
- if (!restriction) { return status; }
17754
- }
17755
-
17756
- if (isFunction(restriction)) {
17757
- restriction = restriction(page.x, page.y, this.element);
17758
- }
17759
-
17760
- if (isElement(restriction)) {
17761
- restriction = getElementRect(restriction);
17762
- }
17763
-
17764
- rect = restriction;
17765
-
17766
- if (!restriction) {
17767
- restrictedX = page.x;
17768
- restrictedY = page.y;
17769
- }
17770
- // object is assumed to have
17771
- // x, y, width, height or
17772
- // left, top, right, bottom
17773
- else if ('x' in restriction && 'y' in restriction) {
17774
- restrictedX = Math.max(Math.min(rect.x + rect.width - this.restrictOffset.right , page.x), rect.x + this.restrictOffset.left);
17775
- restrictedY = Math.max(Math.min(rect.y + rect.height - this.restrictOffset.bottom, page.y), rect.y + this.restrictOffset.top );
17776
- }
17777
- else {
17778
- restrictedX = Math.max(Math.min(rect.right - this.restrictOffset.right , page.x), rect.left + this.restrictOffset.left);
17779
- restrictedY = Math.max(Math.min(rect.bottom - this.restrictOffset.bottom, page.y), rect.top + this.restrictOffset.top );
17780
- }
17781
-
17782
- status.dx = restrictedX - page.x;
17783
- status.dy = restrictedY - page.y;
17784
-
17785
- status.changed = status.restrictedX !== restrictedX || status.restrictedY !== restrictedY;
17786
- status.restricted = !!(status.dx || status.dy);
17787
-
17788
- status.restrictedX = restrictedX;
17789
- status.restrictedY = restrictedY;
17790
-
17791
- return status;
17792
- },
17793
-
17794
- checkAndPreventDefault: function (event, interactable, element) {
17795
- if (!(interactable = interactable || this.target)) { return; }
17796
-
17797
- var options = interactable.options,
17798
- prevent = options.preventDefault;
17799
-
17800
- if (prevent === 'auto' && element && !/^(input|select|textarea)$/i.test(event.target.nodeName)) {
17801
- // do not preventDefault on pointerdown if the prepared action is a drag
17802
- // and dragging can only start from a certain direction - this allows
17803
- // a touch to pan the viewport if a drag isn't in the right direction
17804
- if (/down|start/i.test(event.type)
17805
- && this.prepared.name === 'drag' && options.drag.axis !== 'xy') {
17806
-
17807
- return;
17808
- }
17809
-
17810
- // with manualStart, only preventDefault while interacting
17811
- if (options[this.prepared.name] && options[this.prepared.name].manualStart
17812
- && !this.interacting()) {
17813
- return;
17814
- }
17815
-
17816
- event.preventDefault();
17817
- return;
17818
- }
17819
-
17820
- if (prevent === 'always') {
17821
- event.preventDefault();
17822
- return;
17823
- }
17824
- },
17825
-
17826
- calcInertia: function (status) {
17827
- var inertiaOptions = this.target.options[this.prepared.name].inertia,
17828
- lambda = inertiaOptions.resistance,
17829
- inertiaDur = -Math.log(inertiaOptions.endSpeed / status.v0) / lambda;
17830
-
17831
- status.x0 = this.prevEvent.pageX;
17832
- status.y0 = this.prevEvent.pageY;
17833
- status.t0 = status.startEvent.timeStamp / 1000;
17834
- status.sx = status.sy = 0;
17835
-
17836
- status.modifiedXe = status.xe = (status.vx0 - inertiaDur) / lambda;
17837
- status.modifiedYe = status.ye = (status.vy0 - inertiaDur) / lambda;
17838
- status.te = inertiaDur;
17839
-
17840
- status.lambda_v0 = lambda / status.v0;
17841
- status.one_ve_v0 = 1 - inertiaOptions.endSpeed / status.v0;
17842
- },
17843
-
17844
- autoScrollMove: function (pointer) {
17845
- if (!(this.interacting()
17846
- && checkAutoScroll(this.target, this.prepared.name))) {
17847
- return;
17848
- }
17849
-
17850
- if (this.inertiaStatus.active) {
17851
- autoScroll.x = autoScroll.y = 0;
17852
- return;
17853
- }
17854
-
17855
- var top,
17856
- right,
17857
- bottom,
17858
- left,
17859
- options = this.target.options[this.prepared.name].autoScroll,
17860
- container = options.container || getWindow(this.element);
17861
-
17862
- if (isWindow(container)) {
17863
- left = pointer.clientX < autoScroll.margin;
17864
- top = pointer.clientY < autoScroll.margin;
17865
- right = pointer.clientX > container.innerWidth - autoScroll.margin;
17866
- bottom = pointer.clientY > container.innerHeight - autoScroll.margin;
17867
- }
17868
- else {
17869
- var rect = getElementClientRect(container);
17870
-
17871
- left = pointer.clientX < rect.left + autoScroll.margin;
17872
- top = pointer.clientY < rect.top + autoScroll.margin;
17873
- right = pointer.clientX > rect.right - autoScroll.margin;
17874
- bottom = pointer.clientY > rect.bottom - autoScroll.margin;
17875
- }
17876
-
17877
- autoScroll.x = (right ? 1: left? -1: 0);
17878
- autoScroll.y = (bottom? 1: top? -1: 0);
17879
-
17880
- if (!autoScroll.isScrolling) {
17881
- // set the autoScroll properties to those of the target
17882
- autoScroll.margin = options.margin;
17883
- autoScroll.speed = options.speed;
17884
-
17885
- autoScroll.start(this);
17886
- }
17887
- },
17888
-
17889
- _updateEventTargets: function (target, currentTarget) {
17890
- this._eventTarget = target;
17891
- this._curEventTarget = currentTarget;
17892
- }
17893
-
17894
- };
17895
-
17896
- function getInteractionFromPointer (pointer, eventType, eventTarget) {
17897
- var i = 0, len = interactions.length,
17898
- mouseEvent = (/mouse/i.test(pointer.pointerType || eventType)
17899
- // MSPointerEvent.MSPOINTER_TYPE_MOUSE
17900
- || pointer.pointerType === 4),
17901
- interaction;
17902
-
17903
- var id = getPointerId(pointer);
17904
-
17905
- // try to resume inertia with a new pointer
17906
- if (/down|start/i.test(eventType)) {
17907
- for (i = 0; i < len; i++) {
17908
- interaction = interactions[i];
17909
-
17910
- var element = eventTarget;
17911
-
17912
- if (interaction.inertiaStatus.active && interaction.target.options[interaction.prepared.name].inertia.allowResume
17913
- && (interaction.mouse === mouseEvent)) {
17914
- while (element) {
17915
- // if the element is the interaction element
17916
- if (element === interaction.element) {
17917
- return interaction;
17918
- }
17919
- element = parentElement(element);
17920
- }
17921
- }
17922
- }
17923
- }
17924
-
17925
- // if it's a mouse interaction
17926
- if (mouseEvent || !(supportsTouch || supportsPointerEvent)) {
17927
-
17928
- // find a mouse interaction that's not in inertia phase
17929
- for (i = 0; i < len; i++) {
17930
- if (interactions[i].mouse && !interactions[i].inertiaStatus.active) {
17931
- return interactions[i];
17932
- }
17933
- }
17934
-
17935
- // find any interaction specifically for mouse.
17936
- // if the eventType is a mousedown, and inertia is active
17937
- // ignore the interaction
17938
- for (i = 0; i < len; i++) {
17939
- if (interactions[i].mouse && !(/down/.test(eventType) && interactions[i].inertiaStatus.active)) {
17940
- return interaction;
17941
- }
17942
- }
17943
-
17944
- // create a new interaction for mouse
17945
- interaction = new Interaction();
17946
- interaction.mouse = true;
17947
-
17948
- return interaction;
17949
- }
17950
-
17951
- // get interaction that has this pointer
17952
- for (i = 0; i < len; i++) {
17953
- if (contains(interactions[i].pointerIds, id)) {
17954
- return interactions[i];
17955
- }
17956
- }
17957
-
17958
- // at this stage, a pointerUp should not return an interaction
17959
- if (/up|end|out/i.test(eventType)) {
17960
- return null;
17961
- }
17962
-
17963
- // get first idle interaction
17964
- for (i = 0; i < len; i++) {
17965
- interaction = interactions[i];
17966
-
17967
- if ((!interaction.prepared.name || (interaction.target.options.gesture.enabled))
17968
- && !interaction.interacting()
17969
- && !(!mouseEvent && interaction.mouse)) {
17970
-
17971
- return interaction;
17972
- }
17973
- }
17974
-
17975
- return new Interaction();
17976
- }
17977
-
17978
- function doOnInteractions (method) {
17979
- return (function (event) {
17980
- var interaction,
17981
- eventTarget = getActualElement(event.path
17982
- ? event.path[0]
17983
- : event.target),
17984
- curEventTarget = getActualElement(event.currentTarget),
17985
- i;
17986
-
17987
- if (supportsTouch && /touch/.test(event.type)) {
17988
- prevTouchTime = new Date().getTime();
17989
-
17990
- for (i = 0; i < event.changedTouches.length; i++) {
17991
- var pointer = event.changedTouches[i];
17992
-
17993
- interaction = getInteractionFromPointer(pointer, event.type, eventTarget);
17994
-
17995
- if (!interaction) { continue; }
17996
-
17997
- interaction._updateEventTargets(eventTarget, curEventTarget);
17998
-
17999
- interaction[method](pointer, event, eventTarget, curEventTarget);
18000
- }
18001
- }
18002
- else {
18003
- if (!supportsPointerEvent && /mouse/.test(event.type)) {
18004
- // ignore mouse events while touch interactions are active
18005
- for (i = 0; i < interactions.length; i++) {
18006
- if (!interactions[i].mouse && interactions[i].pointerIsDown) {
18007
- return;
18008
- }
18009
- }
18010
-
18011
- // try to ignore mouse events that are simulated by the browser
18012
- // after a touch event
18013
- if (new Date().getTime() - prevTouchTime < 500) {
18014
- return;
18015
- }
18016
- }
18017
-
18018
- interaction = getInteractionFromPointer(event, event.type, eventTarget);
18019
-
18020
- if (!interaction) { return; }
18021
-
18022
- interaction._updateEventTargets(eventTarget, curEventTarget);
18023
-
18024
- interaction[method](event, event, eventTarget, curEventTarget);
18025
- }
18026
- });
18027
- }
18028
-
18029
- function InteractEvent (interaction, event, action, phase, element, related) {
18030
- var client,
18031
- page,
18032
- target = interaction.target,
18033
- snapStatus = interaction.snapStatus,
18034
- restrictStatus = interaction.restrictStatus,
18035
- pointers = interaction.pointers,
18036
- deltaSource = (target && target.options || defaultOptions).deltaSource,
18037
- sourceX = deltaSource + 'X',
18038
- sourceY = deltaSource + 'Y',
18039
- options = target? target.options: defaultOptions,
18040
- origin = getOriginXY(target, element),
18041
- starting = phase === 'start',
18042
- ending = phase === 'end',
18043
- coords = starting? interaction.startCoords : interaction.curCoords;
18044
-
18045
- element = element || interaction.element;
18046
-
18047
- page = extend({}, coords.page);
18048
- client = extend({}, coords.client);
18049
-
18050
- page.x -= origin.x;
18051
- page.y -= origin.y;
18052
-
18053
- client.x -= origin.x;
18054
- client.y -= origin.y;
18055
-
18056
- var relativePoints = options[action].snap && options[action].snap.relativePoints ;
18057
-
18058
- if (checkSnap(target, action) && !(starting && relativePoints && relativePoints.length)) {
18059
- this.snap = {
18060
- range : snapStatus.range,
18061
- locked : snapStatus.locked,
18062
- x : snapStatus.snappedX,
18063
- y : snapStatus.snappedY,
18064
- realX : snapStatus.realX,
18065
- realY : snapStatus.realY,
18066
- dx : snapStatus.dx,
18067
- dy : snapStatus.dy
18068
- };
18069
-
18070
- if (snapStatus.locked) {
18071
- page.x += snapStatus.dx;
18072
- page.y += snapStatus.dy;
18073
- client.x += snapStatus.dx;
18074
- client.y += snapStatus.dy;
18075
- }
18076
- }
18077
-
18078
- if (checkRestrict(target, action) && !(starting && options[action].restrict.elementRect) && restrictStatus.restricted) {
18079
- page.x += restrictStatus.dx;
18080
- page.y += restrictStatus.dy;
18081
- client.x += restrictStatus.dx;
18082
- client.y += restrictStatus.dy;
18083
-
18084
- this.restrict = {
18085
- dx: restrictStatus.dx,
18086
- dy: restrictStatus.dy
18087
- };
18088
- }
18089
-
18090
- this.pageX = page.x;
18091
- this.pageY = page.y;
18092
- this.clientX = client.x;
18093
- this.clientY = client.y;
18094
-
18095
- this.x0 = interaction.startCoords.page.x - origin.x;
18096
- this.y0 = interaction.startCoords.page.y - origin.y;
18097
- this.clientX0 = interaction.startCoords.client.x - origin.x;
18098
- this.clientY0 = interaction.startCoords.client.y - origin.y;
18099
- this.ctrlKey = event.ctrlKey;
18100
- this.altKey = event.altKey;
18101
- this.shiftKey = event.shiftKey;
18102
- this.metaKey = event.metaKey;
18103
- this.button = event.button;
18104
- this.buttons = event.buttons;
18105
- this.target = element;
18106
- this.t0 = interaction.downTimes[0];
18107
- this.type = action + (phase || '');
18108
-
18109
- this.interaction = interaction;
18110
- this.interactable = target;
18111
-
18112
- var inertiaStatus = interaction.inertiaStatus;
18113
-
18114
- if (inertiaStatus.active) {
18115
- this.detail = 'inertia';
18116
- }
18117
-
18118
- if (related) {
18119
- this.relatedTarget = related;
18120
- }
18121
-
18122
- // end event dx, dy is difference between start and end points
18123
- if (ending) {
18124
- if (deltaSource === 'client') {
18125
- this.dx = client.x - interaction.startCoords.client.x;
18126
- this.dy = client.y - interaction.startCoords.client.y;
18127
- }
18128
- else {
18129
- this.dx = page.x - interaction.startCoords.page.x;
18130
- this.dy = page.y - interaction.startCoords.page.y;
18131
- }
18132
- }
18133
- else if (starting) {
18134
- this.dx = 0;
18135
- this.dy = 0;
18136
- }
18137
- // copy properties from previousmove if starting inertia
18138
- else if (phase === 'inertiastart') {
18139
- this.dx = interaction.prevEvent.dx;
18140
- this.dy = interaction.prevEvent.dy;
18141
- }
18142
- else {
18143
- if (deltaSource === 'client') {
18144
- this.dx = client.x - interaction.prevEvent.clientX;
18145
- this.dy = client.y - interaction.prevEvent.clientY;
18146
- }
18147
- else {
18148
- this.dx = page.x - interaction.prevEvent.pageX;
18149
- this.dy = page.y - interaction.prevEvent.pageY;
18150
- }
18151
- }
18152
- if (interaction.prevEvent && interaction.prevEvent.detail === 'inertia'
18153
- && !inertiaStatus.active
18154
- && options[action].inertia && options[action].inertia.zeroResumeDelta) {
18155
-
18156
- inertiaStatus.resumeDx += this.dx;
18157
- inertiaStatus.resumeDy += this.dy;
18158
-
18159
- this.dx = this.dy = 0;
18160
- }
18161
-
18162
- if (action === 'resize' && interaction.resizeAxes) {
18163
- if (options.resize.square) {
18164
- if (interaction.resizeAxes === 'y') {
18165
- this.dx = this.dy;
18166
- }
18167
- else {
18168
- this.dy = this.dx;
18169
- }
18170
- this.axes = 'xy';
18171
- }
18172
- else {
18173
- this.axes = interaction.resizeAxes;
18174
-
18175
- if (interaction.resizeAxes === 'x') {
18176
- this.dy = 0;
18177
- }
18178
- else if (interaction.resizeAxes === 'y') {
18179
- this.dx = 0;
18180
- }
18181
- }
18182
- }
18183
- else if (action === 'gesture') {
18184
- this.touches = [pointers[0], pointers[1]];
18185
-
18186
- if (starting) {
18187
- this.distance = touchDistance(pointers, deltaSource);
18188
- this.box = touchBBox(pointers);
18189
- this.scale = 1;
18190
- this.ds = 0;
18191
- this.angle = touchAngle(pointers, undefined, deltaSource);
18192
- this.da = 0;
18193
- }
18194
- else if (ending || event instanceof InteractEvent) {
18195
- this.distance = interaction.prevEvent.distance;
18196
- this.box = interaction.prevEvent.box;
18197
- this.scale = interaction.prevEvent.scale;
18198
- this.ds = this.scale - 1;
18199
- this.angle = interaction.prevEvent.angle;
18200
- this.da = this.angle - interaction.gesture.startAngle;
18201
- }
18202
- else {
18203
- this.distance = touchDistance(pointers, deltaSource);
18204
- this.box = touchBBox(pointers);
18205
- this.scale = this.distance / interaction.gesture.startDistance;
18206
- this.angle = touchAngle(pointers, interaction.gesture.prevAngle, deltaSource);
18207
-
18208
- this.ds = this.scale - interaction.gesture.prevScale;
18209
- this.da = this.angle - interaction.gesture.prevAngle;
18210
- }
18211
- }
18212
-
18213
- if (starting) {
18214
- this.timeStamp = interaction.downTimes[0];
18215
- this.dt = 0;
18216
- this.duration = 0;
18217
- this.speed = 0;
18218
- this.velocityX = 0;
18219
- this.velocityY = 0;
18220
- }
18221
- else if (phase === 'inertiastart') {
18222
- this.timeStamp = interaction.prevEvent.timeStamp;
18223
- this.dt = interaction.prevEvent.dt;
18224
- this.duration = interaction.prevEvent.duration;
18225
- this.speed = interaction.prevEvent.speed;
18226
- this.velocityX = interaction.prevEvent.velocityX;
18227
- this.velocityY = interaction.prevEvent.velocityY;
18228
- }
18229
- else {
18230
- this.timeStamp = new Date().getTime();
18231
- this.dt = this.timeStamp - interaction.prevEvent.timeStamp;
18232
- this.duration = this.timeStamp - interaction.downTimes[0];
18233
-
18234
- if (event instanceof InteractEvent) {
18235
- var dx = this[sourceX] - interaction.prevEvent[sourceX],
18236
- dy = this[sourceY] - interaction.prevEvent[sourceY],
18237
- dt = this.dt / 1000;
18238
-
18239
- this.speed = hypot(dx, dy) / dt;
18240
- this.velocityX = dx / dt;
18241
- this.velocityY = dy / dt;
18242
- }
18243
- // if normal move or end event, use previous user event coords
18244
- else {
18245
- // speed and velocity in pixels per second
18246
- this.speed = interaction.pointerDelta[deltaSource].speed;
18247
- this.velocityX = interaction.pointerDelta[deltaSource].vx;
18248
- this.velocityY = interaction.pointerDelta[deltaSource].vy;
18249
- }
18250
- }
18251
-
18252
- if ((ending || phase === 'inertiastart')
18253
- && interaction.prevEvent.speed > 600 && this.timeStamp - interaction.prevEvent.timeStamp < 150) {
18254
-
18255
- var angle = 180 * Math.atan2(interaction.prevEvent.velocityY, interaction.prevEvent.velocityX) / Math.PI,
18256
- overlap = 22.5;
18257
-
18258
- if (angle < 0) {
18259
- angle += 360;
18260
- }
18261
-
18262
- var left = 135 - overlap <= angle && angle < 225 + overlap,
18263
- up = 225 - overlap <= angle && angle < 315 + overlap,
18264
-
18265
- right = !left && (315 - overlap <= angle || angle < 45 + overlap),
18266
- down = !up && 45 - overlap <= angle && angle < 135 + overlap;
18267
-
18268
- this.swipe = {
18269
- up : up,
18270
- down : down,
18271
- left : left,
18272
- right: right,
18273
- angle: angle,
18274
- speed: interaction.prevEvent.speed,
18275
- velocity: {
18276
- x: interaction.prevEvent.velocityX,
18277
- y: interaction.prevEvent.velocityY
18278
- }
18279
- };
18280
- }
18281
- }
18282
-
18283
- InteractEvent.prototype = {
18284
- preventDefault: blank,
18285
- stopImmediatePropagation: function () {
18286
- this.immediatePropagationStopped = this.propagationStopped = true;
18287
- },
18288
- stopPropagation: function () {
18289
- this.propagationStopped = true;
18290
- }
18291
- };
18292
-
18293
- function preventOriginalDefault () {
18294
- this.originalEvent.preventDefault();
18295
- }
18296
-
18297
- function getActionCursor (action) {
18298
- var cursor = '';
18299
-
18300
- if (action.name === 'drag') {
18301
- cursor = actionCursors.drag;
18302
- }
18303
- if (action.name === 'resize') {
18304
- if (action.axis) {
18305
- cursor = actionCursors[action.name + action.axis];
18306
- }
18307
- else if (action.edges) {
18308
- var cursorKey = 'resize',
18309
- edgeNames = ['top', 'bottom', 'left', 'right'];
18310
-
18311
- for (var i = 0; i < 4; i++) {
18312
- if (action.edges[edgeNames[i]]) {
18313
- cursorKey += edgeNames[i];
18314
- }
18315
- }
18316
-
18317
- cursor = actionCursors[cursorKey];
18318
- }
18319
- }
18320
-
18321
- return cursor;
18322
- }
18323
-
18324
- function checkResizeEdge (name, value, page, element, interactableElement, rect, margin) {
18325
- // false, '', undefined, null
18326
- if (!value) { return false; }
18327
-
18328
- // true value, use pointer coords and element rect
18329
- if (value === true) {
18330
- // if dimensions are negative, "switch" edges
18331
- var width = isNumber(rect.width)? rect.width : rect.right - rect.left,
18332
- height = isNumber(rect.height)? rect.height : rect.bottom - rect.top;
18333
-
18334
- if (width < 0) {
18335
- if (name === 'left' ) { name = 'right'; }
18336
- else if (name === 'right') { name = 'left' ; }
18337
- }
18338
- if (height < 0) {
18339
- if (name === 'top' ) { name = 'bottom'; }
18340
- else if (name === 'bottom') { name = 'top' ; }
18341
- }
18342
-
18343
- if (name === 'left' ) { return page.x < ((width >= 0? rect.left: rect.right ) + margin); }
18344
- if (name === 'top' ) { return page.y < ((height >= 0? rect.top : rect.bottom) + margin); }
18345
-
18346
- if (name === 'right' ) { return page.x > ((width >= 0? rect.right : rect.left) - margin); }
18347
- if (name === 'bottom') { return page.y > ((height >= 0? rect.bottom: rect.top ) - margin); }
18348
- }
18349
-
18350
- // the remaining checks require an element
18351
- if (!isElement(element)) { return false; }
18352
-
18353
- return isElement(value)
18354
- // the value is an element to use as a resize handle
18355
- ? value === element
18356
- // otherwise check if element matches value as selector
18357
- : matchesUpTo(element, value, interactableElement);
18358
- }
18359
-
18360
- function defaultActionChecker (pointer, interaction, element) {
18361
- var rect = this.getRect(element),
18362
- shouldResize = false,
18363
- action = null,
18364
- resizeAxes = null,
18365
- resizeEdges,
18366
- page = extend({}, interaction.curCoords.page),
18367
- options = this.options;
18368
-
18369
- if (!rect) { return null; }
18370
-
18371
- if (actionIsEnabled.resize && options.resize.enabled) {
18372
- var resizeOptions = options.resize;
18373
-
18374
- resizeEdges = {
18375
- left: false, right: false, top: false, bottom: false
18376
- };
18377
-
18378
- // if using resize.edges
18379
- if (isObject(resizeOptions.edges)) {
18380
- for (var edge in resizeEdges) {
18381
- resizeEdges[edge] = checkResizeEdge(edge,
18382
- resizeOptions.edges[edge],
18383
- page,
18384
- interaction._eventTarget,
18385
- element,
18386
- rect,
18387
- resizeOptions.margin || margin);
18388
- }
18389
-
18390
- resizeEdges.left = resizeEdges.left && !resizeEdges.right;
18391
- resizeEdges.top = resizeEdges.top && !resizeEdges.bottom;
18392
-
18393
- shouldResize = resizeEdges.left || resizeEdges.right || resizeEdges.top || resizeEdges.bottom;
18394
- }
18395
- else {
18396
- var right = options.resize.axis !== 'y' && page.x > (rect.right - margin),
18397
- bottom = options.resize.axis !== 'x' && page.y > (rect.bottom - margin);
18398
-
18399
- shouldResize = right || bottom;
18400
- resizeAxes = (right? 'x' : '') + (bottom? 'y' : '');
18401
- }
18402
- }
18403
-
18404
- action = shouldResize
18405
- ? 'resize'
18406
- : actionIsEnabled.drag && options.drag.enabled
18407
- ? 'drag'
18408
- : null;
18409
-
18410
- if (actionIsEnabled.gesture
18411
- && interaction.pointerIds.length >=2
18412
- && !(interaction.dragging || interaction.resizing)) {
18413
- action = 'gesture';
18414
- }
18415
-
18416
- if (action) {
18417
- return {
18418
- name: action,
18419
- axis: resizeAxes,
18420
- edges: resizeEdges
18421
- };
18422
- }
18423
-
18424
- return null;
18425
- }
18426
-
18427
- // Check if action is enabled globally and the current target supports it
18428
- // If so, return the validated action. Otherwise, return null
18429
- function validateAction (action, interactable) {
18430
- if (!isObject(action)) { return null; }
18431
-
18432
- var actionName = action.name,
18433
- options = interactable.options;
18434
-
18435
- if (( (actionName === 'resize' && options.resize.enabled )
18436
- || (actionName === 'drag' && options.drag.enabled )
18437
- || (actionName === 'gesture' && options.gesture.enabled))
18438
- && actionIsEnabled[actionName]) {
18439
-
18440
- if (actionName === 'resize' || actionName === 'resizeyx') {
18441
- actionName = 'resizexy';
18442
- }
18443
-
18444
- return action;
18445
- }
18446
- return null;
18447
- }
18448
-
18449
- var listeners = {},
18450
- interactionListeners = [
18451
- 'dragStart', 'dragMove', 'resizeStart', 'resizeMove', 'gestureStart', 'gestureMove',
18452
- 'pointerOver', 'pointerOut', 'pointerHover', 'selectorDown',
18453
- 'pointerDown', 'pointerMove', 'pointerUp', 'pointerCancel', 'pointerEnd',
18454
- 'addPointer', 'removePointer', 'recordPointer', 'autoScrollMove'
18455
- ];
18456
-
18457
- for (var i = 0, len = interactionListeners.length; i < len; i++) {
18458
- var name = interactionListeners[i];
18459
-
18460
- listeners[name] = doOnInteractions(name);
18461
- }
18462
-
18463
- // bound to the interactable context when a DOM event
18464
- // listener is added to a selector interactable
18465
- function delegateListener (event, useCapture) {
18466
- var fakeEvent = {},
18467
- delegated = delegatedEvents[event.type],
18468
- eventTarget = getActualElement(event.path
18469
- ? event.path[0]
18470
- : event.target),
18471
- element = eventTarget;
18472
-
18473
- useCapture = useCapture? true: false;
18474
-
18475
- // duplicate the event so that currentTarget can be changed
18476
- for (var prop in event) {
18477
- fakeEvent[prop] = event[prop];
18478
- }
18479
-
18480
- fakeEvent.originalEvent = event;
18481
- fakeEvent.preventDefault = preventOriginalDefault;
18482
-
18483
- // climb up document tree looking for selector matches
18484
- while (isElement(element)) {
18485
- for (var i = 0; i < delegated.selectors.length; i++) {
18486
- var selector = delegated.selectors[i],
18487
- context = delegated.contexts[i];
18488
-
18489
- if (matchesSelector(element, selector)
18490
- && nodeContains(context, eventTarget)
18491
- && nodeContains(context, element)) {
18492
-
18493
- var listeners = delegated.listeners[i];
18494
-
18495
- fakeEvent.currentTarget = element;
18496
-
18497
- for (var j = 0; j < listeners.length; j++) {
18498
- if (listeners[j][1] === useCapture) {
18499
- listeners[j][0](fakeEvent);
18500
- }
18501
- }
18502
- }
18503
- }
18504
-
18505
- element = parentElement(element);
18506
- }
18507
- }
18508
-
18509
- function delegateUseCapture (event) {
18510
- return delegateListener.call(this, event, true);
18511
- }
18512
-
18513
- interactables.indexOfElement = function indexOfElement (element, context) {
18514
- context = context || document;
18515
-
18516
- for (var i = 0; i < this.length; i++) {
18517
- var interactable = this[i];
18518
-
18519
- if ((interactable.selector === element
18520
- && (interactable._context === context))
18521
- || (!interactable.selector && interactable._element === element)) {
18522
-
18523
- return i;
18524
- }
18525
- }
18526
- return -1;
18527
- };
18528
-
18529
- interactables.get = function interactableGet (element, options) {
18530
- return this[this.indexOfElement(element, options && options.context)];
18531
- };
18532
-
18533
- interactables.forEachSelector = function (callback) {
18534
- for (var i = 0; i < this.length; i++) {
18535
- var interactable = this[i];
18536
-
18537
- if (!interactable.selector) {
18538
- continue;
18539
- }
18540
-
18541
- var ret = callback(interactable, interactable.selector, interactable._context, i, this);
18542
-
18543
- if (ret !== undefined) {
18544
- return ret;
18545
- }
18546
- }
18547
- };
18548
-
18549
- /*\
18550
- * interact
18551
- [ method ]
18552
- *
18553
- * The methods of this variable can be used to set elements as
18554
- * interactables and also to change various default settings.
18555
- *
18556
- * Calling it as a function and passing an element or a valid CSS selector
18557
- * string returns an Interactable object which has various methods to
18558
- * configure it.
18559
- *
18560
- - element (Element | string) The HTML or SVG Element to interact with or CSS selector
18561
- = (object) An @Interactable
18562
- *
18563
- > Usage
18564
- | interact(document.getElementById('draggable')).draggable(true);
18565
- |
18566
- | var rectables = interact('rect');
18567
- | rectables
18568
- | .gesturable(true)
18569
- | .on('gesturemove', function (event) {
18570
- | // something cool...
18571
- | })
18572
- | .autoScroll(true);
18573
- \*/
18574
- function interact (element, options) {
18575
- return interactables.get(element, options) || new Interactable(element, options);
18576
- }
18577
-
18578
- /*\
18579
- * Interactable
18580
- [ property ]
18581
- **
18582
- * Object type returned by @interact
18583
- \*/
18584
- function Interactable (element, options) {
18585
- this._element = element;
18586
- this._iEvents = this._iEvents || {};
18587
-
18588
- var _window;
18589
-
18590
- if (trySelector(element)) {
18591
- this.selector = element;
18592
-
18593
- var context = options && options.context;
18594
-
18595
- _window = context? getWindow(context) : window;
18596
-
18597
- if (context && (_window.Node
18598
- ? context instanceof _window.Node
18599
- : (isElement(context) || context === _window.document))) {
18600
-
18601
- this._context = context;
18602
- }
18603
- }
18604
- else {
18605
- _window = getWindow(element);
18606
-
18607
- if (isElement(element, _window)) {
18608
-
18609
- if (supportsPointerEvent) {
18610
- events.add(this._element, pEventTypes.down, listeners.pointerDown );
18611
- events.add(this._element, pEventTypes.move, listeners.pointerHover);
18612
- }
18613
- else {
18614
- events.add(this._element, 'mousedown' , listeners.pointerDown );
18615
- events.add(this._element, 'mousemove' , listeners.pointerHover);
18616
- events.add(this._element, 'touchstart', listeners.pointerDown );
18617
- events.add(this._element, 'touchmove' , listeners.pointerHover);
18618
- }
18619
- }
18620
- }
18621
-
18622
- this._doc = _window.document;
18623
-
18624
- if (!contains(documents, this._doc)) {
18625
- listenToDocument(this._doc);
18626
- }
18627
-
18628
- interactables.push(this);
18629
-
18630
- this.set(options);
18631
- }
18632
-
18633
- Interactable.prototype = {
18634
- setOnEvents: function (action, phases) {
18635
- if (action === 'drop') {
18636
- if (isFunction(phases.ondrop) ) { this.ondrop = phases.ondrop ; }
18637
- if (isFunction(phases.ondropactivate) ) { this.ondropactivate = phases.ondropactivate ; }
18638
- if (isFunction(phases.ondropdeactivate)) { this.ondropdeactivate = phases.ondropdeactivate; }
18639
- if (isFunction(phases.ondragenter) ) { this.ondragenter = phases.ondragenter ; }
18640
- if (isFunction(phases.ondragleave) ) { this.ondragleave = phases.ondragleave ; }
18641
- if (isFunction(phases.ondropmove) ) { this.ondropmove = phases.ondropmove ; }
18642
- }
18643
- else {
18644
- action = 'on' + action;
18645
-
18646
- if (isFunction(phases.onstart) ) { this[action + 'start' ] = phases.onstart ; }
18647
- if (isFunction(phases.onmove) ) { this[action + 'move' ] = phases.onmove ; }
18648
- if (isFunction(phases.onend) ) { this[action + 'end' ] = phases.onend ; }
18649
- if (isFunction(phases.oninertiastart)) { this[action + 'inertiastart' ] = phases.oninertiastart ; }
18650
- }
18651
-
18652
- return this;
18653
- },
18654
-
18655
- /*\
18656
- * Interactable.draggable
18657
- [ method ]
18658
- *
18659
- * Gets or sets whether drag actions can be performed on the
18660
- * Interactable
18661
- *
18662
- = (boolean) Indicates if this can be the target of drag events
18663
- | var isDraggable = interact('ul li').draggable();
18664
- * or
18665
- - options (boolean | object) #optional true/false or An object with event listeners to be fired on drag events (object makes the Interactable draggable)
18666
- = (object) This Interactable
18667
- | interact(element).draggable({
18668
- | onstart: function (event) {},
18669
- | onmove : function (event) {},
18670
- | onend : function (event) {},
18671
- |
18672
- | // the axis in which the first movement must be
18673
- | // for the drag sequence to start
18674
- | // 'xy' by default - any direction
18675
- | axis: 'x' || 'y' || 'xy',
18676
- |
18677
- | // max number of drags that can happen concurrently
18678
- | // with elements of this Interactable. Infinity by default
18679
- | max: Infinity,
18680
- |
18681
- | // max number of drags that can target the same element+Interactable
18682
- | // 1 by default
18683
- | maxPerElement: 2
18684
- | });
18685
- \*/
18686
- draggable: function (options) {
18687
- if (isObject(options)) {
18688
- this.options.drag.enabled = options.enabled === false? false: true;
18689
- this.setPerAction('drag', options);
18690
- this.setOnEvents('drag', options);
18691
-
18692
- if (/^x$|^y$|^xy$/.test(options.axis)) {
18693
- this.options.drag.axis = options.axis;
18694
- }
18695
- else if (options.axis === null) {
18696
- delete this.options.drag.axis;
18697
- }
18698
-
18699
- return this;
18700
- }
18701
-
18702
- if (isBool(options)) {
18703
- this.options.drag.enabled = options;
18704
-
18705
- return this;
18706
- }
18707
-
18708
- return this.options.drag;
18709
- },
18710
-
18711
- setPerAction: function (action, options) {
18712
- // for all the default per-action options
18713
- for (var option in options) {
18714
- // if this option exists for this action
18715
- if (option in defaultOptions[action]) {
18716
- // if the option in the options arg is an object value
18717
- if (isObject(options[option])) {
18718
- // duplicate the object
18719
- this.options[action][option] = extend(this.options[action][option] || {}, options[option]);
18720
-
18721
- if (isObject(defaultOptions.perAction[option]) && 'enabled' in defaultOptions.perAction[option]) {
18722
- this.options[action][option].enabled = options[option].enabled === false? false : true;
18723
- }
18724
- }
18725
- else if (isBool(options[option]) && isObject(defaultOptions.perAction[option])) {
18726
- this.options[action][option].enabled = options[option];
18727
- }
18728
- else if (options[option] !== undefined) {
18729
- // or if it's not undefined, do a plain assignment
18730
- this.options[action][option] = options[option];
18731
- }
18732
- }
18733
- }
18734
- },
18735
-
18736
- /*\
18737
- * Interactable.dropzone
18738
- [ method ]
18739
- *
18740
- * Returns or sets whether elements can be dropped onto this
18741
- * Interactable to trigger drop events
18742
- *
18743
- * Dropzones can receive the following events:
18744
- * - `dropactivate` and `dropdeactivate` when an acceptable drag starts and ends
18745
- * - `dragenter` and `dragleave` when a draggable enters and leaves the dropzone
18746
- * - `dragmove` when a draggable that has entered the dropzone is moved
18747
- * - `drop` when a draggable is dropped into this dropzone
18748
- *
18749
- * Use the `accept` option to allow only elements that match the given CSS selector or element.
18750
- *
18751
- * Use the `overlap` option to set how drops are checked for. The allowed values are:
18752
- * - `'pointer'`, the pointer must be over the dropzone (default)
18753
- * - `'center'`, the draggable element's center must be over the dropzone
18754
- * - a number from 0-1 which is the `(intersection area) / (draggable area)`.
18755
- * e.g. `0.5` for drop to happen when half of the area of the
18756
- * draggable is over the dropzone
18757
- *
18758
- - options (boolean | object | null) #optional The new value to be set.
18759
- | interact('.drop').dropzone({
18760
- | accept: '.can-drop' || document.getElementById('single-drop'),
18761
- | overlap: 'pointer' || 'center' || zeroToOne
18762
- | }
18763
- = (boolean | object) The current setting or this Interactable
18764
- \*/
18765
- dropzone: function (options) {
18766
- if (isObject(options)) {
18767
- this.options.drop.enabled = options.enabled === false? false: true;
18768
- this.setOnEvents('drop', options);
18769
-
18770
- if (/^(pointer|center)$/.test(options.overlap)) {
18771
- this.options.drop.overlap = options.overlap;
18772
- }
18773
- else if (isNumber(options.overlap)) {
18774
- this.options.drop.overlap = Math.max(Math.min(1, options.overlap), 0);
18775
- }
18776
- if ('accept' in options) {
18777
- this.options.drop.accept = options.accept;
18778
- }
18779
- if ('checker' in options) {
18780
- this.options.drop.checker = options.checker;
18781
- }
18782
-
18783
- return this;
18784
- }
18785
-
18786
- if (isBool(options)) {
18787
- this.options.drop.enabled = options;
18788
-
18789
- return this;
18790
- }
18791
-
18792
- return this.options.drop;
18793
- },
18794
-
18795
- dropCheck: function (dragEvent, event, draggable, draggableElement, dropElement, rect) {
18796
- var dropped = false;
18797
-
18798
- // if the dropzone has no rect (eg. display: none)
18799
- // call the custom dropChecker or just return false
18800
- if (!(rect = rect || this.getRect(dropElement))) {
18801
- return (this.options.drop.checker
18802
- ? this.options.drop.checker(dragEvent, event, dropped, this, dropElement, draggable, draggableElement)
18803
- : false);
18804
- }
18805
-
18806
- var dropOverlap = this.options.drop.overlap;
18807
-
18808
- if (dropOverlap === 'pointer') {
18809
- var page = getPageXY(dragEvent),
18810
- origin = getOriginXY(draggable, draggableElement),
18811
- horizontal,
18812
- vertical;
18813
-
18814
- page.x += origin.x;
18815
- page.y += origin.y;
18816
-
18817
- horizontal = (page.x > rect.left) && (page.x < rect.right);
18818
- vertical = (page.y > rect.top ) && (page.y < rect.bottom);
18819
-
18820
- dropped = horizontal && vertical;
18821
- }
18822
-
18823
- var dragRect = draggable.getRect(draggableElement);
18824
-
18825
- if (dropOverlap === 'center') {
18826
- var cx = dragRect.left + dragRect.width / 2,
18827
- cy = dragRect.top + dragRect.height / 2;
18828
-
18829
- dropped = cx >= rect.left && cx <= rect.right && cy >= rect.top && cy <= rect.bottom;
18830
- }
18831
-
18832
- if (isNumber(dropOverlap)) {
18833
- var overlapArea = (Math.max(0, Math.min(rect.right , dragRect.right ) - Math.max(rect.left, dragRect.left))
18834
- * Math.max(0, Math.min(rect.bottom, dragRect.bottom) - Math.max(rect.top , dragRect.top ))),
18835
- overlapRatio = overlapArea / (dragRect.width * dragRect.height);
18836
-
18837
- dropped = overlapRatio >= dropOverlap;
18838
- }
18839
-
18840
- if (this.options.drop.checker) {
18841
- dropped = this.options.drop.checker(dragEvent, event, dropped, this, dropElement, draggable, draggableElement);
18842
- }
18843
-
18844
- return dropped;
18845
- },
18846
-
18847
- /*\
18848
- * Interactable.dropChecker
18849
- [ method ]
18850
- *
18851
- * DEPRECATED. Use interactable.dropzone({ checker: function... }) instead.
18852
- *
18853
- * Gets or sets the function used to check if a dragged element is
18854
- * over this Interactable.
18855
- *
18856
- - checker (function) #optional The function that will be called when checking for a drop
18857
- = (Function | Interactable) The checker function or this Interactable
18858
- *
18859
- * The checker function takes the following arguments:
18860
- *
18861
- - dragEvent (InteractEvent) The related dragmove or dragend event
18862
- - event (TouchEvent | PointerEvent | MouseEvent) The user move/up/end Event related to the dragEvent
18863
- - dropped (boolean) The value from the default drop checker
18864
- - dropzone (Interactable) The dropzone interactable
18865
- - dropElement (Element) The dropzone element
18866
- - draggable (Interactable) The Interactable being dragged
18867
- - draggableElement (Element) The actual element that's being dragged
18868
- *
18869
- > Usage:
18870
- | interact(target)
18871
- | .dropChecker(function(dragEvent, // related dragmove or dragend event
18872
- | event, // TouchEvent/PointerEvent/MouseEvent
18873
- | dropped, // bool result of the default checker
18874
- | dropzone, // dropzone Interactable
18875
- | dropElement, // dropzone elemnt
18876
- | draggable, // draggable Interactable
18877
- | draggableElement) {// draggable element
18878
- |
18879
- | return dropped && event.target.hasAttribute('allow-drop');
18880
- | }
18881
- \*/
18882
- dropChecker: function (checker) {
18883
- if (isFunction(checker)) {
18884
- this.options.drop.checker = checker;
18885
-
18886
- return this;
18887
- }
18888
- if (checker === null) {
18889
- delete this.options.getRect;
18890
-
18891
- return this;
18892
- }
18893
-
18894
- return this.options.drop.checker;
18895
- },
18896
-
18897
- /*\
18898
- * Interactable.accept
18899
- [ method ]
18900
- *
18901
- * Deprecated. add an `accept` property to the options object passed to
18902
- * @Interactable.dropzone instead.
18903
- *
18904
- * Gets or sets the Element or CSS selector match that this
18905
- * Interactable accepts if it is a dropzone.
18906
- *
18907
- - newValue (Element | string | null) #optional
18908
- * If it is an Element, then only that element can be dropped into this dropzone.
18909
- * If it is a string, the element being dragged must match it as a selector.
18910
- * If it is null, the accept options is cleared - it accepts any element.
18911
- *
18912
- = (string | Element | null | Interactable) The current accept option if given `undefined` or this Interactable
18913
- \*/
18914
- accept: function (newValue) {
18915
- if (isElement(newValue)) {
18916
- this.options.drop.accept = newValue;
18917
-
18918
- return this;
18919
- }
18920
-
18921
- // test if it is a valid CSS selector
18922
- if (trySelector(newValue)) {
18923
- this.options.drop.accept = newValue;
18924
-
18925
- return this;
18926
- }
18927
-
18928
- if (newValue === null) {
18929
- delete this.options.drop.accept;
18930
-
18931
- return this;
18932
- }
18933
-
18934
- return this.options.drop.accept;
18935
- },
18936
-
18937
- /*\
18938
- * Interactable.resizable
18939
- [ method ]
18940
- *
18941
- * Gets or sets whether resize actions can be performed on the
18942
- * Interactable
18943
- *
18944
- = (boolean) Indicates if this can be the target of resize elements
18945
- | var isResizeable = interact('input[type=text]').resizable();
18946
- * or
18947
- - options (boolean | object) #optional true/false or An object with event listeners to be fired on resize events (object makes the Interactable resizable)
18948
- = (object) This Interactable
18949
- | interact(element).resizable({
18950
- | onstart: function (event) {},
18951
- | onmove : function (event) {},
18952
- | onend : function (event) {},
18953
- |
18954
- | edges: {
18955
- | top : true, // Use pointer coords to check for resize.
18956
- | left : false, // Disable resizing from left edge.
18957
- | bottom: '.resize-s',// Resize if pointer target matches selector
18958
- | right : handleEl // Resize if pointer target is the given Element
18959
- | },
18960
- |
18961
- | // Width and height can be adjusted independently. When `true`, width and
18962
- | // height are adjusted at a 1:1 ratio.
18963
- | square: false,
18964
- |
18965
- | // Width and height can be adjusted independently. When `true`, width and
18966
- | // height maintain the aspect ratio they had when resizing started.
18967
- | preserveAspectRatio: false,
18968
- |
18969
- | // a value of 'none' will limit the resize rect to a minimum of 0x0
18970
- | // 'negate' will allow the rect to have negative width/height
18971
- | // 'reposition' will keep the width/height positive by swapping
18972
- | // the top and bottom edges and/or swapping the left and right edges
18973
- | invert: 'none' || 'negate' || 'reposition'
18974
- |
18975
- | // limit multiple resizes.
18976
- | // See the explanation in the @Interactable.draggable example
18977
- | max: Infinity,
18978
- | maxPerElement: 1,
18979
- | });
18980
- \*/
18981
- resizable: function (options) {
18982
- if (isObject(options)) {
18983
- this.options.resize.enabled = options.enabled === false? false: true;
18984
- this.setPerAction('resize', options);
18985
- this.setOnEvents('resize', options);
18986
-
18987
- if (/^x$|^y$|^xy$/.test(options.axis)) {
18988
- this.options.resize.axis = options.axis;
18989
- }
18990
- else if (options.axis === null) {
18991
- this.options.resize.axis = defaultOptions.resize.axis;
18992
- }
18993
-
18994
- if (isBool(options.preserveAspectRatio)) {
18995
- this.options.resize.preserveAspectRatio = options.preserveAspectRatio;
18996
- }
18997
- else if (isBool(options.square)) {
18998
- this.options.resize.square = options.square;
18999
- }
19000
-
19001
- return this;
19002
- }
19003
- if (isBool(options)) {
19004
- this.options.resize.enabled = options;
19005
-
19006
- return this;
19007
- }
19008
- return this.options.resize;
19009
- },
19010
-
19011
- /*\
19012
- * Interactable.squareResize
19013
- [ method ]
19014
- *
19015
- * Deprecated. Add a `square: true || false` property to @Interactable.resizable instead
19016
- *
19017
- * Gets or sets whether resizing is forced 1:1 aspect
19018
- *
19019
- = (boolean) Current setting
19020
- *
19021
- * or
19022
- *
19023
- - newValue (boolean) #optional
19024
- = (object) this Interactable
19025
- \*/
19026
- squareResize: function (newValue) {
19027
- if (isBool(newValue)) {
19028
- this.options.resize.square = newValue;
19029
-
19030
- return this;
19031
- }
19032
-
19033
- if (newValue === null) {
19034
- delete this.options.resize.square;
19035
-
19036
- return this;
19037
- }
19038
-
19039
- return this.options.resize.square;
19040
- },
19041
-
19042
- /*\
19043
- * Interactable.gesturable
19044
- [ method ]
19045
- *
19046
- * Gets or sets whether multitouch gestures can be performed on the
19047
- * Interactable's element
19048
- *
19049
- = (boolean) Indicates if this can be the target of gesture events
19050
- | var isGestureable = interact(element).gesturable();
19051
- * or
19052
- - options (boolean | object) #optional true/false or An object with event listeners to be fired on gesture events (makes the Interactable gesturable)
19053
- = (object) this Interactable
19054
- | interact(element).gesturable({
19055
- | onstart: function (event) {},
19056
- | onmove : function (event) {},
19057
- | onend : function (event) {},
19058
- |
19059
- | // limit multiple gestures.
19060
- | // See the explanation in @Interactable.draggable example
19061
- | max: Infinity,
19062
- | maxPerElement: 1,
19063
- | });
19064
- \*/
19065
- gesturable: function (options) {
19066
- if (isObject(options)) {
19067
- this.options.gesture.enabled = options.enabled === false? false: true;
19068
- this.setPerAction('gesture', options);
19069
- this.setOnEvents('gesture', options);
19070
-
19071
- return this;
19072
- }
19073
-
19074
- if (isBool(options)) {
19075
- this.options.gesture.enabled = options;
19076
-
19077
- return this;
19078
- }
19079
-
19080
- return this.options.gesture;
19081
- },
19082
-
19083
- /*\
19084
- * Interactable.autoScroll
19085
- [ method ]
19086
- **
19087
- * Deprecated. Add an `autoscroll` property to the options object
19088
- * passed to @Interactable.draggable or @Interactable.resizable instead.
19089
- *
19090
- * Returns or sets whether dragging and resizing near the edges of the
19091
- * window/container trigger autoScroll for this Interactable
19092
- *
19093
- = (object) Object with autoScroll properties
19094
- *
19095
- * or
19096
- *
19097
- - options (object | boolean) #optional
19098
- * options can be:
19099
- * - an object with margin, distance and interval properties,
19100
- * - true or false to enable or disable autoScroll or
19101
- = (Interactable) this Interactable
19102
- \*/
19103
- autoScroll: function (options) {
19104
- if (isObject(options)) {
19105
- options = extend({ actions: ['drag', 'resize']}, options);
19106
- }
19107
- else if (isBool(options)) {
19108
- options = { actions: ['drag', 'resize'], enabled: options };
19109
- }
19110
-
19111
- return this.setOptions('autoScroll', options);
19112
- },
19113
-
19114
- /*\
19115
- * Interactable.snap
19116
- [ method ]
19117
- **
19118
- * Deprecated. Add a `snap` property to the options object passed
19119
- * to @Interactable.draggable or @Interactable.resizable instead.
19120
- *
19121
- * Returns or sets if and how action coordinates are snapped. By
19122
- * default, snapping is relative to the pointer coordinates. You can
19123
- * change this by setting the
19124
- * [`elementOrigin`](https://github.com/taye/interact.js/pull/72).
19125
- **
19126
- = (boolean | object) `false` if snap is disabled; object with snap properties if snap is enabled
19127
- **
19128
- * or
19129
- **
19130
- - options (object | boolean | null) #optional
19131
- = (Interactable) this Interactable
19132
- > Usage
19133
- | interact(document.querySelector('#thing')).snap({
19134
- | targets: [
19135
- | // snap to this specific point
19136
- | {
19137
- | x: 100,
19138
- | y: 100,
19139
- | range: 25
19140
- | },
19141
- | // give this function the x and y page coords and snap to the object returned
19142
- | function (x, y) {
19143
- | return {
19144
- | x: x,
19145
- | y: (75 + 50 * Math.sin(x * 0.04)),
19146
- | range: 40
19147
- | };
19148
- | },
19149
- | // create a function that snaps to a grid
19150
- | interact.createSnapGrid({
19151
- | x: 50,
19152
- | y: 50,
19153
- | range: 10, // optional
19154
- | offset: { x: 5, y: 10 } // optional
19155
- | })
19156
- | ],
19157
- | // do not snap during normal movement.
19158
- | // Instead, trigger only one snapped move event
19159
- | // immediately before the end event.
19160
- | endOnly: true,
19161
- |
19162
- | relativePoints: [
19163
- | { x: 0, y: 0 }, // snap relative to the top left of the element
19164
- | { x: 1, y: 1 }, // and also to the bottom right
19165
- | ],
19166
- |
19167
- | // offset the snap target coordinates
19168
- | // can be an object with x/y or 'startCoords'
19169
- | offset: { x: 50, y: 50 }
19170
- | }
19171
- | });
19172
- \*/
19173
- snap: function (options) {
19174
- var ret = this.setOptions('snap', options);
19175
-
19176
- if (ret === this) { return this; }
19177
-
19178
- return ret.drag;
19179
- },
19180
-
19181
- setOptions: function (option, options) {
19182
- var actions = options && isArray(options.actions)
19183
- ? options.actions
19184
- : ['drag'];
19185
-
19186
- var i;
19187
-
19188
- if (isObject(options) || isBool(options)) {
19189
- for (i = 0; i < actions.length; i++) {
19190
- var action = /resize/.test(actions[i])? 'resize' : actions[i];
19191
-
19192
- if (!isObject(this.options[action])) { continue; }
19193
-
19194
- var thisOption = this.options[action][option];
19195
-
19196
- if (isObject(options)) {
19197
- extend(thisOption, options);
19198
- thisOption.enabled = options.enabled === false? false: true;
19199
-
19200
- if (option === 'snap') {
19201
- if (thisOption.mode === 'grid') {
19202
- thisOption.targets = [
19203
- interact.createSnapGrid(extend({
19204
- offset: thisOption.gridOffset || { x: 0, y: 0 }
19205
- }, thisOption.grid || {}))
19206
- ];
19207
- }
19208
- else if (thisOption.mode === 'anchor') {
19209
- thisOption.targets = thisOption.anchors;
19210
- }
19211
- else if (thisOption.mode === 'path') {
19212
- thisOption.targets = thisOption.paths;
19213
- }
19214
-
19215
- if ('elementOrigin' in options) {
19216
- thisOption.relativePoints = [options.elementOrigin];
19217
- }
19218
- }
19219
- }
19220
- else if (isBool(options)) {
19221
- thisOption.enabled = options;
19222
- }
19223
- }
19224
-
19225
- return this;
19226
- }
19227
-
19228
- var ret = {},
19229
- allActions = ['drag', 'resize', 'gesture'];
19230
-
19231
- for (i = 0; i < allActions.length; i++) {
19232
- if (option in defaultOptions[allActions[i]]) {
19233
- ret[allActions[i]] = this.options[allActions[i]][option];
19234
- }
19235
- }
19236
-
19237
- return ret;
19238
- },
19239
-
19240
-
19241
- /*\
19242
- * Interactable.inertia
19243
- [ method ]
19244
- **
19245
- * Deprecated. Add an `inertia` property to the options object passed
19246
- * to @Interactable.draggable or @Interactable.resizable instead.
19247
- *
19248
- * Returns or sets if and how events continue to run after the pointer is released
19249
- **
19250
- = (boolean | object) `false` if inertia is disabled; `object` with inertia properties if inertia is enabled
19251
- **
19252
- * or
19253
- **
19254
- - options (object | boolean | null) #optional
19255
- = (Interactable) this Interactable
19256
- > Usage
19257
- | // enable and use default settings
19258
- | interact(element).inertia(true);
19259
- |
19260
- | // enable and use custom settings
19261
- | interact(element).inertia({
19262
- | // value greater than 0
19263
- | // high values slow the object down more quickly
19264
- | resistance : 16,
19265
- |
19266
- | // the minimum launch speed (pixels per second) that results in inertia start
19267
- | minSpeed : 200,
19268
- |
19269
- | // inertia will stop when the object slows down to this speed
19270
- | endSpeed : 20,
19271
- |
19272
- | // boolean; should actions be resumed when the pointer goes down during inertia
19273
- | allowResume : true,
19274
- |
19275
- | // boolean; should the jump when resuming from inertia be ignored in event.dx/dy
19276
- | zeroResumeDelta: false,
19277
- |
19278
- | // if snap/restrict are set to be endOnly and inertia is enabled, releasing
19279
- | // the pointer without triggering inertia will animate from the release
19280
- | // point to the snaped/restricted point in the given amount of time (ms)
19281
- | smoothEndDuration: 300,
19282
- |
19283
- | // an array of action types that can have inertia (no gesture)
19284
- | actions : ['drag', 'resize']
19285
- | });
19286
- |
19287
- | // reset custom settings and use all defaults
19288
- | interact(element).inertia(null);
19289
- \*/
19290
- inertia: function (options) {
19291
- var ret = this.setOptions('inertia', options);
19292
-
19293
- if (ret === this) { return this; }
19294
-
19295
- return ret.drag;
19296
- },
19297
-
19298
- getAction: function (pointer, event, interaction, element) {
19299
- var action = this.defaultActionChecker(pointer, interaction, element);
19300
-
19301
- if (this.options.actionChecker) {
19302
- return this.options.actionChecker(pointer, event, action, this, element, interaction);
19303
- }
19304
-
19305
- return action;
19306
- },
19307
-
19308
- defaultActionChecker: defaultActionChecker,
19309
-
19310
- /*\
19311
- * Interactable.actionChecker
19312
- [ method ]
19313
- *
19314
- * Gets or sets the function used to check action to be performed on
19315
- * pointerDown
19316
- *
19317
- - checker (function | null) #optional A function which takes a pointer event, defaultAction string, interactable, element and interaction as parameters and returns an object with name property 'drag' 'resize' or 'gesture' and optionally an `edges` object with boolean 'top', 'left', 'bottom' and right props.
19318
- = (Function | Interactable) The checker function or this Interactable
19319
- *
19320
- | interact('.resize-drag')
19321
- | .resizable(true)
19322
- | .draggable(true)
19323
- | .actionChecker(function (pointer, event, action, interactable, element, interaction) {
19324
- |
19325
- | if (interact.matchesSelector(event.target, '.drag-handle') {
19326
- | // force drag with handle target
19327
- | action.name = drag;
19328
- | }
19329
- | else {
19330
- | // resize from the top and right edges
19331
- | action.name = 'resize';
19332
- | action.edges = { top: true, right: true };
19333
- | }
19334
- |
19335
- | return action;
19336
- | });
19337
- \*/
19338
- actionChecker: function (checker) {
19339
- if (isFunction(checker)) {
19340
- this.options.actionChecker = checker;
19341
-
19342
- return this;
19343
- }
19344
-
19345
- if (checker === null) {
19346
- delete this.options.actionChecker;
19347
-
19348
- return this;
19349
- }
19350
-
19351
- return this.options.actionChecker;
19352
- },
19353
-
19354
- /*\
19355
- * Interactable.getRect
19356
- [ method ]
19357
- *
19358
- * The default function to get an Interactables bounding rect. Can be
19359
- * overridden using @Interactable.rectChecker.
19360
- *
19361
- - element (Element) #optional The element to measure.
19362
- = (object) The object's bounding rectangle.
19363
- o {
19364
- o top : 0,
19365
- o left : 0,
19366
- o bottom: 0,
19367
- o right : 0,
19368
- o width : 0,
19369
- o height: 0
19370
- o }
19371
- \*/
19372
- getRect: function rectCheck (element) {
19373
- element = element || this._element;
19374
-
19375
- if (this.selector && !(isElement(element))) {
19376
- element = this._context.querySelector(this.selector);
19377
- }
19378
-
19379
- return getElementRect(element);
19380
- },
19381
-
19382
- /*\
19383
- * Interactable.rectChecker
19384
- [ method ]
19385
- *
19386
- * Returns or sets the function used to calculate the interactable's
19387
- * element's rectangle
19388
- *
19389
- - checker (function) #optional A function which returns this Interactable's bounding rectangle. See @Interactable.getRect
19390
- = (function | object) The checker function or this Interactable
19391
- \*/
19392
- rectChecker: function (checker) {
19393
- if (isFunction(checker)) {
19394
- this.getRect = checker;
19395
-
19396
- return this;
19397
- }
19398
-
19399
- if (checker === null) {
19400
- delete this.options.getRect;
19401
-
19402
- return this;
19403
- }
19404
-
19405
- return this.getRect;
19406
- },
19407
-
19408
- /*\
19409
- * Interactable.styleCursor
19410
- [ method ]
19411
- *
19412
- * Returns or sets whether the action that would be performed when the
19413
- * mouse on the element are checked on `mousemove` so that the cursor
19414
- * may be styled appropriately
19415
- *
19416
- - newValue (boolean) #optional
19417
- = (boolean | Interactable) The current setting or this Interactable
19418
- \*/
19419
- styleCursor: function (newValue) {
19420
- if (isBool(newValue)) {
19421
- this.options.styleCursor = newValue;
19422
-
19423
- return this;
19424
- }
19425
-
19426
- if (newValue === null) {
19427
- delete this.options.styleCursor;
19428
-
19429
- return this;
19430
- }
19431
-
19432
- return this.options.styleCursor;
19433
- },
19434
-
19435
- /*\
19436
- * Interactable.preventDefault
19437
- [ method ]
19438
- *
19439
- * Returns or sets whether to prevent the browser's default behaviour
19440
- * in response to pointer events. Can be set to:
19441
- * - `'always'` to always prevent
19442
- * - `'never'` to never prevent
19443
- * - `'auto'` to let interact.js try to determine what would be best
19444
- *
19445
- - newValue (string) #optional `true`, `false` or `'auto'`
19446
- = (string | Interactable) The current setting or this Interactable
19447
- \*/
19448
- preventDefault: function (newValue) {
19449
- if (/^(always|never|auto)$/.test(newValue)) {
19450
- this.options.preventDefault = newValue;
19451
- return this;
19452
- }
19453
-
19454
- if (isBool(newValue)) {
19455
- this.options.preventDefault = newValue? 'always' : 'never';
19456
- return this;
19457
- }
19458
-
19459
- return this.options.preventDefault;
19460
- },
19461
-
19462
- /*\
19463
- * Interactable.origin
19464
- [ method ]
19465
- *
19466
- * Gets or sets the origin of the Interactable's element. The x and y
19467
- * of the origin will be subtracted from action event coordinates.
19468
- *
19469
- - origin (object | string) #optional An object eg. { x: 0, y: 0 } or string 'parent', 'self' or any CSS selector
19470
- * OR
19471
- - origin (Element) #optional An HTML or SVG Element whose rect will be used
19472
- **
19473
- = (object) The current origin or this Interactable
19474
- \*/
19475
- origin: function (newValue) {
19476
- if (trySelector(newValue)) {
19477
- this.options.origin = newValue;
19478
- return this;
19479
- }
19480
- else if (isObject(newValue)) {
19481
- this.options.origin = newValue;
19482
- return this;
19483
- }
19484
-
19485
- return this.options.origin;
19486
- },
19487
-
19488
- /*\
19489
- * Interactable.deltaSource
19490
- [ method ]
19491
- *
19492
- * Returns or sets the mouse coordinate types used to calculate the
19493
- * movement of the pointer.
19494
- *
19495
- - newValue (string) #optional Use 'client' if you will be scrolling while interacting; Use 'page' if you want autoScroll to work
19496
- = (string | object) The current deltaSource or this Interactable
19497
- \*/
19498
- deltaSource: function (newValue) {
19499
- if (newValue === 'page'
1
  webpackJsonp([4],{
2
 
3
+ /***/ 589:
4
  /***/ function(module, exports, __webpack_require__) {
5
 
6
+ var __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;
7
+ 'use strict';
8
+
9
  !(__WEBPACK_AMD_DEFINE_ARRAY__ = [
10
+ __webpack_require__(587),
11
+ __webpack_require__(575),
12
+ __webpack_require__(577),
13
+ __webpack_require__(280)
14
+ ], __WEBPACK_AMD_DEFINE_RESULT__ = function (App, Marionette, SuperModel, _) { // eslint-disable-line func-names
15
  var Module = {};
16
 
17
+ Module.StylesModel = SuperModel.extend({
18
+ defaults: {
19
+ text: {
20
+ fontColor: '#000000',
21
+ fontFamily: 'Arial',
22
+ fontSize: '16px'
23
+ },
24
+ h1: {
25
+ fontColor: '#111111',
26
+ fontFamily: 'Arial',
27
+ fontSize: '40px'
28
+ },
29
+ h2: {
30
+ fontColor: '#222222',
31
+ fontFamily: 'Tahoma',
32
+ fontSize: '32px'
33
+ },
34
+ h3: {
35
+ fontColor: '#333333',
36
+ fontFamily: 'Verdana',
37
+ fontSize: '24px'
38
+ },
39
+ link: {
40
+ fontColor: '#21759B',
41
+ textDecoration: 'underline'
42
+ },
43
+ wrapper: {
44
+ backgroundColor: '#ffffff'
45
+ },
46
+ body: {
47
+ backgroundColor: '#cccccc'
48
  }
49
+ },
50
+ initialize: function () { // eslint-disable-line func-names
51
+ this.on('change', function () { App.getChannel().trigger('autoSave'); }); // eslint-disable-line func-names
52
+ }
53
+ });
54
 
55
+ Module.StylesView = Marionette.View.extend({
56
+ getTemplate: function () { return window.templates.styles; }, // eslint-disable-line func-names
57
+ modelEvents: {
58
+ change: 'render'
59
+ },
60
+ serializeData: function () { // eslint-disable-line func-names
61
+ return this.model.toJSON();
62
+ }
63
+ });
64
 
65
+ Module._globalStyles = new SuperModel();
66
+ Module.getGlobalStyles = function () { // eslint-disable-line func-names
67
+ return Module._globalStyles;
 
 
 
 
68
  };
69
+ Module.setGlobalStyles = function (options) { // eslint-disable-line func-names
70
+ Module._globalStyles = new Module.StylesModel(options);
71
+ return Module._globalStyles;
 
 
 
 
 
72
  };
73
+ Module.getAvailableStyles = function () { // eslint-disable-line func-names
74
+ return App.getConfig().get('availableStyles');
 
 
 
 
 
 
75
  };
76
 
77
+ App.on('before:start', function (BeforeStartApp, options) { // eslint-disable-line func-names
78
+ var Application = BeforeStartApp;
79
+ var body;
80
+ var globalStyles;
81
+ // Expose style methods to global application
82
+ Application.getGlobalStyles = Module.getGlobalStyles;
83
+ Application.setGlobalStyles = Module.setGlobalStyles;
84
+ Application.getAvailableStyles = Module.getAvailableStyles;
85
 
86
+ body = options.newsletter.body;
87
+ globalStyles = (_.has(body, 'globalStyles')) ? body.globalStyles : {};
88
+ this.setGlobalStyles(globalStyles);
89
+ });
 
 
 
 
90
 
91
+ App.on('start', function (StartApp) { // eslint-disable-line func-names
92
+ var stylesView = new Module.StylesView({ model: StartApp.getGlobalStyles() });
93
+ StartApp._appView.showChildView('stylesRegion', stylesView);
94
  });
95
 
96
  return Module;
103
  /***/ function(module, exports, __webpack_require__) {
104
 
105
  __webpack_require__(280);
106
+ __webpack_require__(547);
 
 
107
  __webpack_require__(575);
 
 
 
108
  __webpack_require__(577);
109
  __webpack_require__(578);
110
+ __webpack_require__(576);
111
+ __webpack_require__(289);
112
  __webpack_require__(579);
113
+ __webpack_require__(580);
114
+ __webpack_require__(581);
115
  __webpack_require__(582);
 
 
116
  __webpack_require__(585);
117
  __webpack_require__(586);
118
  __webpack_require__(587);
119
+ __webpack_require__(588);
120
  __webpack_require__(589);
121
  __webpack_require__(590);
122
+ __webpack_require__(592);
123
+ __webpack_require__(593);
124
  __webpack_require__(594);
125
+ __webpack_require__(591);
126
  __webpack_require__(595);
127
  __webpack_require__(596);
128
  __webpack_require__(597);
143
  __webpack_require__(612);
144
  __webpack_require__(613);
145
  __webpack_require__(614);
146
+ __webpack_require__(615);
147
+ module.exports = __webpack_require__(616);
148
 
149
 
150
  /***/ },
7481
 
7482
  /***/ },
7483
 
7484
+ /***/ 527:
7485
  /***/ function(module, exports, __webpack_require__) {
7486
 
7487
+ /* WEBPACK VAR INJECTION */(function(global) {module.exports = global["html2canvas"] = __webpack_require__(528);
7488
  /* WEBPACK VAR INJECTION */}.call(exports, (function() { return this; }())))
7489
 
7490
  /***/ },
7491
 
7492
+ /***/ 528:
7493
  /***/ function(module, exports, __webpack_require__) {
7494
 
7495
+ var require;var require;/* WEBPACK VAR INJECTION */(function(global) {/*
7496
+ html2canvas 0.5.0-alpha2 <http://html2canvas.hertzen.com>
7497
+ Copyright (c) 2015 Niklas von Hertzen
7498
+
7499
+ Released under MIT License
7500
+ */
7501
 
7502
+ !function(e){if(true)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var f;"undefined"!=typeof window?f=window:"undefined"!=typeof global?f=global:"undefined"!=typeof self&&(f=self),f.html2canvas=e()}}(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return require(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
7503
+ (function (process,global){
7504
+ /*!
7505
+ * @overview es6-promise - a tiny implementation of Promises/A+.
7506
+ * @copyright Copyright (c) 2014 Yehuda Katz, Tom Dale, Stefan Penner and contributors (Conversion to ES6 API by Jake Archibald)
7507
+ * @license Licensed under MIT license
7508
+ * See https://raw.githubusercontent.com/jakearchibald/es6-promise/master/LICENSE
7509
+ * @version 2.0.1
7510
+ */
7511
 
7512
+ (function() {
7513
+ "use strict";
7514
 
7515
+ function $$utils$$objectOrFunction(x) {
7516
+ return typeof x === 'function' || (typeof x === 'object' && x !== null);
7517
+ }
 
7518
 
7519
+ function $$utils$$isFunction(x) {
7520
+ return typeof x === 'function';
7521
+ }
 
 
 
 
7522
 
7523
+ function $$utils$$isMaybeThenable(x) {
7524
+ return typeof x === 'object' && x !== null;
7525
+ }
 
 
7526
 
7527
+ var $$utils$$_isArray;
 
 
 
7528
 
7529
+ if (!Array.isArray) {
7530
+ $$utils$$_isArray = function (x) {
7531
+ return Object.prototype.toString.call(x) === '[object Array]';
7532
+ };
7533
+ } else {
7534
+ $$utils$$_isArray = Array.isArray;
7535
+ }
7536
 
7537
+ var $$utils$$isArray = $$utils$$_isArray;
7538
+ var $$utils$$now = Date.now || function() { return new Date().getTime(); };
7539
+ function $$utils$$F() { }
7540
 
7541
+ var $$utils$$o_create = (Object.create || function (o) {
7542
+ if (arguments.length > 1) {
7543
+ throw new Error('Second argument not supported');
7544
+ }
7545
+ if (typeof o !== 'object') {
7546
+ throw new TypeError('Argument must be an object');
7547
+ }
7548
+ $$utils$$F.prototype = o;
7549
+ return new $$utils$$F();
7550
+ });
7551
 
7552
+ var $$asap$$len = 0;
 
7553
 
7554
+ var $$asap$$default = function asap(callback, arg) {
7555
+ $$asap$$queue[$$asap$$len] = callback;
7556
+ $$asap$$queue[$$asap$$len + 1] = arg;
7557
+ $$asap$$len += 2;
7558
+ if ($$asap$$len === 2) {
7559
+ // If len is 1, that means that we need to schedule an async flush.
7560
+ // If additional callbacks are queued before the queue is flushed, they
7561
+ // will be processed by this flush that we are scheduling.
7562
+ $$asap$$scheduleFlush();
7563
+ }
7564
+ };
7565
 
7566
+ var $$asap$$browserGlobal = (typeof window !== 'undefined') ? window : {};
7567
+ var $$asap$$BrowserMutationObserver = $$asap$$browserGlobal.MutationObserver || $$asap$$browserGlobal.WebKitMutationObserver;
 
7568
 
7569
+ // test for web worker but not in IE10
7570
+ var $$asap$$isWorker = typeof Uint8ClampedArray !== 'undefined' &&
7571
+ typeof importScripts !== 'undefined' &&
7572
+ typeof MessageChannel !== 'undefined';
 
 
7573
 
7574
+ // node
7575
+ function $$asap$$useNextTick() {
7576
+ return function() {
7577
+ process.nextTick($$asap$$flush);
7578
+ };
7579
+ }
7580
 
7581
+ function $$asap$$useMutationObserver() {
7582
+ var iterations = 0;
7583
+ var observer = new $$asap$$BrowserMutationObserver($$asap$$flush);
7584
+ var node = document.createTextNode('');
7585
+ observer.observe(node, { characterData: true });
7586
 
7587
+ return function() {
7588
+ node.data = (iterations = ++iterations % 2);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
7589
  };
7590
+ }
7591
+
7592
+ // web worker
7593
+ function $$asap$$useMessageChannel() {
7594
+ var channel = new MessageChannel();
7595
+ channel.port1.onmessage = $$asap$$flush;
7596
+ return function () {
7597
+ channel.port2.postMessage(0);
7598
  };
7599
  }
 
 
 
 
 
 
7600
 
7601
+ function $$asap$$useSetTimeout() {
7602
+ return function() {
7603
+ setTimeout($$asap$$flush, 1);
7604
+ };
7605
+ }
 
 
 
 
 
 
 
 
7606
 
7607
+ var $$asap$$queue = new Array(1000);
 
7608
 
7609
+ function $$asap$$flush() {
7610
+ for (var i = 0; i < $$asap$$len; i+=2) {
7611
+ var callback = $$asap$$queue[i];
7612
+ var arg = $$asap$$queue[i+1];
 
 
 
 
 
 
 
7613
 
7614
+ callback(arg);
 
7615
 
7616
+ $$asap$$queue[i] = undefined;
7617
+ $$asap$$queue[i+1] = undefined;
 
 
 
 
 
 
 
 
 
 
 
 
 
7618
  }
7619
+
7620
+ $$asap$$len = 0;
 
7621
  }
 
 
7622
 
7623
+ var $$asap$$scheduleFlush;
 
 
 
 
7624
 
7625
+ // Decide what async method to use to triggering processing of queued callbacks:
7626
+ if (typeof process !== 'undefined' && {}.toString.call(process) === '[object process]') {
7627
+ $$asap$$scheduleFlush = $$asap$$useNextTick();
7628
+ } else if ($$asap$$BrowserMutationObserver) {
7629
+ $$asap$$scheduleFlush = $$asap$$useMutationObserver();
7630
+ } else if ($$asap$$isWorker) {
7631
+ $$asap$$scheduleFlush = $$asap$$useMessageChannel();
7632
+ } else {
7633
+ $$asap$$scheduleFlush = $$asap$$useSetTimeout();
7634
+ }
7635
 
7636
+ function $$$internal$$noop() {}
7637
+ var $$$internal$$PENDING = void 0;
7638
+ var $$$internal$$FULFILLED = 1;
7639
+ var $$$internal$$REJECTED = 2;
7640
+ var $$$internal$$GET_THEN_ERROR = new $$$internal$$ErrorObject();
7641
+
7642
+ function $$$internal$$selfFullfillment() {
7643
+ return new TypeError("You cannot resolve a promise with itself");
7644
  }
7645
 
7646
+ function $$$internal$$cannotReturnOwn() {
7647
+ return new TypeError('A promises callback cannot return that same promise.')
7648
+ }
7649
 
7650
+ function $$$internal$$getThen(promise) {
7651
+ try {
7652
+ return promise.then;
7653
+ } catch(error) {
7654
+ $$$internal$$GET_THEN_ERROR.error = error;
7655
+ return $$$internal$$GET_THEN_ERROR;
7656
+ }
7657
+ }
7658
 
7659
+ function $$$internal$$tryThen(then, value, fulfillmentHandler, rejectionHandler) {
7660
+ try {
7661
+ then.call(value, fulfillmentHandler, rejectionHandler);
7662
+ } catch(e) {
7663
+ return e;
7664
+ }
7665
  }
7666
 
7667
+ function $$$internal$$handleForeignThenable(promise, thenable, then) {
7668
+ $$asap$$default(function(promise) {
7669
+ var sealed = false;
7670
+ var error = $$$internal$$tryThen(then, thenable, function(value) {
7671
+ if (sealed) { return; }
7672
+ sealed = true;
7673
+ if (thenable !== value) {
7674
+ $$$internal$$resolve(promise, value);
7675
+ } else {
7676
+ $$$internal$$fulfill(promise, value);
7677
+ }
7678
+ }, function(reason) {
7679
+ if (sealed) { return; }
7680
+ sealed = true;
7681
 
7682
+ $$$internal$$reject(promise, reason);
7683
+ }, 'Settle: ' + (promise._label || ' unknown promise'));
 
 
 
 
7684
 
7685
+ if (!sealed && error) {
7686
+ sealed = true;
7687
+ $$$internal$$reject(promise, error);
7688
+ }
7689
+ }, promise);
7690
  }
 
 
7691
 
7692
+ function $$$internal$$handleOwnThenable(promise, thenable) {
7693
+ if (thenable._state === $$$internal$$FULFILLED) {
7694
+ $$$internal$$fulfill(promise, thenable._result);
7695
+ } else if (promise._state === $$$internal$$REJECTED) {
7696
+ $$$internal$$reject(promise, thenable._result);
7697
+ } else {
7698
+ $$$internal$$subscribe(thenable, undefined, function(value) {
7699
+ $$$internal$$resolve(promise, value);
7700
+ }, function(reason) {
7701
+ $$$internal$$reject(promise, reason);
7702
+ });
7703
+ }
7704
+ }
7705
 
7706
+ function $$$internal$$handleMaybeThenable(promise, maybeThenable) {
7707
+ if (maybeThenable.constructor === promise.constructor) {
7708
+ $$$internal$$handleOwnThenable(promise, maybeThenable);
7709
+ } else {
7710
+ var then = $$$internal$$getThen(maybeThenable);
7711
 
7712
+ if (then === $$$internal$$GET_THEN_ERROR) {
7713
+ $$$internal$$reject(promise, $$$internal$$GET_THEN_ERROR.error);
7714
+ } else if (then === undefined) {
7715
+ $$$internal$$fulfill(promise, maybeThenable);
7716
+ } else if ($$utils$$isFunction(then)) {
7717
+ $$$internal$$handleForeignThenable(promise, maybeThenable, then);
7718
+ } else {
7719
+ $$$internal$$fulfill(promise, maybeThenable);
7720
+ }
7721
+ }
7722
+ }
7723
 
7724
+ function $$$internal$$resolve(promise, value) {
7725
+ if (promise === value) {
7726
+ $$$internal$$reject(promise, $$$internal$$selfFullfillment());
7727
+ } else if ($$utils$$objectOrFunction(value)) {
7728
+ $$$internal$$handleMaybeThenable(promise, value);
7729
+ } else {
7730
+ $$$internal$$fulfill(promise, value);
7731
+ }
7732
+ }
7733
 
7734
+ function $$$internal$$publishRejection(promise) {
7735
+ if (promise._onerror) {
7736
+ promise._onerror(promise._result);
7737
+ }
7738
 
7739
+ $$$internal$$publish(promise);
7740
  }
7741
 
7742
+ function $$$internal$$fulfill(promise, value) {
7743
+ if (promise._state !== $$$internal$$PENDING) { return; }
7744
 
7745
+ promise._result = value;
7746
+ promise._state = $$$internal$$FULFILLED;
 
7747
 
7748
+ if (promise._subscribers.length === 0) {
7749
+ } else {
7750
+ $$asap$$default($$$internal$$publish, promise);
7751
+ }
7752
+ }
7753
 
7754
+ function $$$internal$$reject(promise, reason) {
7755
+ if (promise._state !== $$$internal$$PENDING) { return; }
7756
+ promise._state = $$$internal$$REJECTED;
7757
+ promise._result = reason;
7758
+
7759
+ $$asap$$default($$$internal$$publishRejection, promise);
7760
+ }
7761
+
7762
+ function $$$internal$$subscribe(parent, child, onFulfillment, onRejection) {
7763
+ var subscribers = parent._subscribers;
7764
+ var length = subscribers.length;
7765
+
7766
+ parent._onerror = null;
7767
+
7768
+ subscribers[length] = child;
7769
+ subscribers[length + $$$internal$$FULFILLED] = onFulfillment;
7770
+ subscribers[length + $$$internal$$REJECTED] = onRejection;
7771
+
7772
+ if (length === 0 && parent._state) {
7773
+ $$asap$$default($$$internal$$publish, parent);
7774
  }
 
7775
  }
7776
 
7777
+ function $$$internal$$publish(promise) {
7778
+ var subscribers = promise._subscribers;
7779
+ var settled = promise._state;
 
7780
 
7781
+ if (subscribers.length === 0) { return; }
 
7782
 
7783
+ var child, callback, detail = promise._result;
7784
+
7785
+ for (var i = 0; i < subscribers.length; i += 3) {
7786
+ child = subscribers[i];
7787
+ callback = subscribers[i + settled];
7788
+
7789
+ if (child) {
7790
+ $$$internal$$invokeCallback(settled, child, callback, detail);
 
 
7791
  } else {
7792
+ callback(detail);
 
 
 
 
7793
  }
7794
  }
7795
 
7796
+ promise._subscribers.length = 0;
 
 
 
 
 
7797
  }
 
 
7798
 
7799
+ function $$$internal$$ErrorObject() {
7800
+ this.error = null;
7801
+ }
 
 
 
 
 
 
 
7802
 
7803
+ var $$$internal$$TRY_CATCH_ERROR = new $$$internal$$ErrorObject();
 
 
 
 
 
7804
 
7805
+ function $$$internal$$tryCatch(callback, detail) {
7806
+ try {
7807
+ return callback(detail);
7808
+ } catch(e) {
7809
+ $$$internal$$TRY_CATCH_ERROR.error = e;
7810
+ return $$$internal$$TRY_CATCH_ERROR;
7811
+ }
 
 
7812
  }
 
 
7813
 
7814
+ function $$$internal$$invokeCallback(settled, promise, callback, detail) {
7815
+ var hasCallback = $$utils$$isFunction(callback),
7816
+ value, error, succeeded, failed;
 
 
 
7817
 
7818
+ if (hasCallback) {
7819
+ value = $$$internal$$tryCatch(callback, detail);
 
7820
 
7821
+ if (value === $$$internal$$TRY_CATCH_ERROR) {
7822
+ failed = true;
7823
+ error = value.error;
7824
+ value = null;
7825
+ } else {
7826
+ succeeded = true;
7827
+ }
7828
 
7829
+ if (promise === value) {
7830
+ $$$internal$$reject(promise, $$$internal$$cannotReturnOwn());
7831
+ return;
7832
+ }
7833
+
7834
+ } else {
7835
+ value = detail;
7836
+ succeeded = true;
7837
+ }
7838
+
7839
+ if (promise._state !== $$$internal$$PENDING) {
7840
+ // noop
7841
+ } else if (hasCallback && succeeded) {
7842
+ $$$internal$$resolve(promise, value);
7843
+ } else if (failed) {
7844
+ $$$internal$$reject(promise, error);
7845
+ } else if (settled === $$$internal$$FULFILLED) {
7846
+ $$$internal$$fulfill(promise, value);
7847
+ } else if (settled === $$$internal$$REJECTED) {
7848
+ $$$internal$$reject(promise, value);
7849
+ }
7850
  }
 
 
7851
 
7852
+ function $$$internal$$initializePromise(promise, resolver) {
7853
+ try {
7854
+ resolver(function resolvePromise(value){
7855
+ $$$internal$$resolve(promise, value);
7856
+ }, function rejectPromise(reason) {
7857
+ $$$internal$$reject(promise, reason);
7858
+ });
7859
+ } catch(e) {
7860
+ $$$internal$$reject(promise, e);
7861
+ }
 
7862
  }
 
7863
 
7864
+ function $$$enumerator$$makeSettledResult(state, position, value) {
7865
+ if (state === $$$internal$$FULFILLED) {
7866
+ return {
7867
+ state: 'fulfilled',
7868
+ value: value
7869
+ };
7870
+ } else {
7871
+ return {
7872
+ state: 'rejected',
7873
+ reason: value
7874
+ };
7875
+ }
7876
+ }
7877
 
7878
+ function $$$enumerator$$Enumerator(Constructor, input, abortOnReject, label) {
7879
+ this._instanceConstructor = Constructor;
7880
+ this.promise = new Constructor($$$internal$$noop, label);
7881
+ this._abortOnReject = abortOnReject;
7882
 
7883
+ if (this._validateInput(input)) {
7884
+ this._input = input;
7885
+ this.length = input.length;
7886
+ this._remaining = input.length;
7887
 
7888
+ this._init();
 
 
 
7889
 
7890
+ if (this.length === 0) {
7891
+ $$$internal$$fulfill(this.promise, this._result);
7892
+ } else {
7893
+ this.length = this.length || 0;
7894
+ this._enumerate();
7895
+ if (this._remaining === 0) {
7896
+ $$$internal$$fulfill(this.promise, this._result);
7897
+ }
7898
+ }
7899
+ } else {
7900
+ $$$internal$$reject(this.promise, this._validationError());
7901
+ }
7902
+ }
 
 
7903
 
7904
+ $$$enumerator$$Enumerator.prototype._validateInput = function(input) {
7905
+ return $$utils$$isArray(input);
7906
+ };
7907
 
7908
+ $$$enumerator$$Enumerator.prototype._validationError = function() {
7909
+ return new Error('Array Methods must be provided an Array');
7910
+ };
7911
 
7912
+ $$$enumerator$$Enumerator.prototype._init = function() {
7913
+ this._result = new Array(this.length);
7914
+ };
7915
 
7916
+ var $$$enumerator$$default = $$$enumerator$$Enumerator;
 
 
7917
 
7918
+ $$$enumerator$$Enumerator.prototype._enumerate = function() {
7919
+ var length = this.length;
7920
+ var promise = this.promise;
7921
+ var input = this._input;
7922
 
7923
+ for (var i = 0; promise._state === $$$internal$$PENDING && i < length; i++) {
7924
+ this._eachEntry(input[i], i);
7925
+ }
7926
+ };
7927
 
7928
+ $$$enumerator$$Enumerator.prototype._eachEntry = function(entry, i) {
7929
+ var c = this._instanceConstructor;
7930
+ if ($$utils$$isMaybeThenable(entry)) {
7931
+ if (entry.constructor === c && entry._state !== $$$internal$$PENDING) {
7932
+ entry._onerror = null;
7933
+ this._settledAt(entry._state, i, entry._result);
7934
+ } else {
7935
+ this._willSettleAt(c.resolve(entry), i);
7936
+ }
7937
+ } else {
7938
+ this._remaining--;
7939
+ this._result[i] = this._makeResult($$$internal$$FULFILLED, i, entry);
7940
+ }
7941
+ };
7942
 
7943
+ $$$enumerator$$Enumerator.prototype._settledAt = function(state, i, value) {
7944
+ var promise = this.promise;
 
 
 
7945
 
7946
+ if (promise._state === $$$internal$$PENDING) {
7947
+ this._remaining--;
 
 
7948
 
7949
+ if (this._abortOnReject && state === $$$internal$$REJECTED) {
7950
+ $$$internal$$reject(promise, value);
7951
+ } else {
7952
+ this._result[i] = this._makeResult(state, i, value);
7953
+ }
7954
+ }
7955
 
7956
+ if (this._remaining === 0) {
7957
+ $$$internal$$fulfill(promise, this._result);
7958
+ }
7959
+ };
 
7960
 
7961
+ $$$enumerator$$Enumerator.prototype._makeResult = function(state, i, value) {
7962
+ return value;
7963
+ };
 
7964
 
7965
+ $$$enumerator$$Enumerator.prototype._willSettleAt = function(promise, i) {
7966
+ var enumerator = this;
 
 
 
7967
 
7968
+ $$$internal$$subscribe(promise, undefined, function(value) {
7969
+ enumerator._settledAt($$$internal$$FULFILLED, i, value);
7970
+ }, function(reason) {
7971
+ enumerator._settledAt($$$internal$$REJECTED, i, reason);
7972
+ });
7973
+ };
 
 
7974
 
7975
+ var $$promise$all$$default = function all(entries, label) {
7976
+ return new $$$enumerator$$default(this, entries, true /* abort on reject */, label).promise;
7977
+ };
7978
 
7979
+ var $$promise$race$$default = function race(entries, label) {
7980
+ /*jshint validthis:true */
7981
+ var Constructor = this;
7982
 
7983
+ var promise = new Constructor($$$internal$$noop, label);
 
 
 
 
 
7984
 
7985
+ if (!$$utils$$isArray(entries)) {
7986
+ $$$internal$$reject(promise, new TypeError('You must pass an array to race.'));
7987
+ return promise;
7988
  }
7989
 
7990
+ var length = entries.length;
 
 
7991
 
7992
+ function onFulfillment(value) {
7993
+ $$$internal$$resolve(promise, value);
 
 
 
 
 
 
 
 
7994
  }
7995
 
7996
+ function onRejection(reason) {
7997
+ $$$internal$$reject(promise, reason);
 
 
 
 
 
 
 
7998
  }
7999
 
8000
+ for (var i = 0; promise._state === $$$internal$$PENDING && i < length; i++) {
8001
+ $$$internal$$subscribe(Constructor.resolve(entries[i]), undefined, onFulfillment, onRejection);
 
 
 
 
 
 
 
8002
  }
 
 
 
 
8003
 
8004
+ return promise;
8005
+ };
 
 
 
8006
 
8007
+ var $$promise$resolve$$default = function resolve(object, label) {
8008
+ /*jshint validthis:true */
8009
+ var Constructor = this;
 
 
 
 
 
 
 
 
 
 
8010
 
8011
+ if (object && typeof object === 'object' && object.constructor === Constructor) {
8012
+ return object;
 
 
 
 
 
 
 
 
 
 
 
 
8013
  }
 
 
8014
 
8015
+ var promise = new Constructor($$$internal$$noop, label);
8016
+ $$$internal$$resolve(promise, object);
8017
+ return promise;
8018
+ };
 
 
8019
 
8020
+ var $$promise$reject$$default = function reject(reason, label) {
8021
+ /*jshint validthis:true */
8022
+ var Constructor = this;
8023
+ var promise = new Constructor($$$internal$$noop, label);
8024
+ $$$internal$$reject(promise, reason);
8025
+ return promise;
8026
+ };
8027
 
8028
+ var $$es6$promise$promise$$counter = 0;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
8029
 
8030
+ function $$es6$promise$promise$$needsResolver() {
8031
+ throw new TypeError('You must pass a resolver function as the first argument to the promise constructor');
8032
+ }
 
 
 
 
 
 
 
 
 
8033
 
8034
+ function $$es6$promise$promise$$needsNew() {
8035
+ throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.");
8036
+ }
8037
 
8038
+ var $$es6$promise$promise$$default = $$es6$promise$promise$$Promise;
 
 
 
 
 
 
 
8039
 
8040
+ /**
8041
+ Promise objects represent the eventual result of an asynchronous operation. The
8042
+ primary way of interacting with a promise is through its `then` method, which
8043
+ registers callbacks to receive either a promise’s eventual value or the reason
8044
+ why the promise cannot be fulfilled.
 
 
 
 
 
 
 
 
 
 
8045
 
8046
+ Terminology
8047
+ -----------
8048
 
8049
+ - `promise` is an object or function with a `then` method whose behavior conforms to this specification.
8050
+ - `thenable` is an object or function that defines a `then` method.
8051
+ - `value` is any legal JavaScript value (including undefined, a thenable, or a promise).
8052
+ - `exception` is a value that is thrown using the throw statement.
8053
+ - `reason` is a value that indicates why a promise was rejected.
8054
+ - `settled` the final resting state of a promise, fulfilled or rejected.
8055
 
8056
+ A promise can be in one of three states: pending, fulfilled, or rejected.
 
8057
 
8058
+ Promises that are fulfilled have a fulfillment value and are in the fulfilled
8059
+ state. Promises that are rejected have a rejection reason and are in the
8060
+ rejected state. A fulfillment value is never a thenable.
8061
 
8062
+ Promises can also be said to *resolve* a value. If this value is also a
8063
+ promise, then the original promise's settled state will match the value's
8064
+ settled state. So a promise that *resolves* a promise that rejects will
8065
+ itself reject, and a promise that *resolves* a promise that fulfills will
8066
+ itself fulfill.
 
 
 
8067
 
 
 
 
 
8068
 
8069
+ Basic Usage:
8070
+ ------------
 
 
 
8071
 
8072
+ ```js
8073
+ var promise = new Promise(function(resolve, reject) {
8074
+ // on success
8075
+ resolve(value);
 
 
 
 
 
 
8076
 
8077
+ // on failure
8078
+ reject(reason);
8079
+ });
 
 
 
 
 
 
 
 
 
8080
 
8081
+ promise.then(function(value) {
8082
+ // on fulfillment
8083
+ }, function(reason) {
8084
+ // on rejection
8085
+ });
8086
+ ```
8087
 
8088
+ Advanced Usage:
8089
+ ---------------
 
 
8090
 
8091
+ Promises shine when abstracting away asynchronous interactions such as
8092
+ `XMLHttpRequest`s.
 
 
8093
 
8094
+ ```js
8095
+ function getJSON(url) {
8096
+ return new Promise(function(resolve, reject){
8097
+ var xhr = new XMLHttpRequest();
8098
 
8099
+ xhr.open('GET', url);
8100
+ xhr.onreadystatechange = handler;
8101
+ xhr.responseType = 'json';
8102
+ xhr.setRequestHeader('Accept', 'application/json');
8103
+ xhr.send();
 
 
 
 
 
8104
 
8105
+ function handler() {
8106
+ if (this.readyState === this.DONE) {
8107
+ if (this.status === 200) {
8108
+ resolve(this.response);
8109
+ } else {
8110
+ reject(new Error('getJSON: `' + url + '` failed with status: [' + this.status + ']'));
8111
+ }
8112
+ }
8113
+ };
8114
+ });
8115
+ }
8116
 
8117
+ getJSON('/posts.json').then(function(json) {
8118
+ // on fulfillment
8119
+ }, function(reason) {
8120
+ // on rejection
8121
+ });
8122
+ ```
8123
 
8124
+ Unlike callbacks, promises are great composable primitives.
 
8125
 
8126
+ ```js
8127
+ Promise.all([
8128
+ getJSON('/posts'),
8129
+ getJSON('/comments')
8130
+ ]).then(function(values){
8131
+ values[0] // => postsJSON
8132
+ values[1] // => commentsJSON
8133
 
8134
+ return values;
8135
+ });
8136
+ ```
 
 
 
8137
 
8138
+ @class Promise
8139
+ @param {function} resolver
8140
+ Useful for tooling.
8141
+ @constructor
8142
+ */
8143
+ function $$es6$promise$promise$$Promise(resolver) {
8144
+ this._id = $$es6$promise$promise$$counter++;
8145
+ this._state = undefined;
8146
+ this._result = undefined;
8147
+ this._subscribers = [];
 
8148
 
8149
+ if ($$$internal$$noop !== resolver) {
8150
+ if (!$$utils$$isFunction(resolver)) {
8151
+ $$es6$promise$promise$$needsResolver();
8152
+ }
8153
 
8154
+ if (!(this instanceof $$es6$promise$promise$$Promise)) {
8155
+ $$es6$promise$promise$$needsNew();
8156
+ }
 
 
 
 
 
 
 
8157
 
8158
+ $$$internal$$initializePromise(this, resolver);
8159
+ }
8160
+ }
8161
 
8162
+ $$es6$promise$promise$$Promise.all = $$promise$all$$default;
8163
+ $$es6$promise$promise$$Promise.race = $$promise$race$$default;
8164
+ $$es6$promise$promise$$Promise.resolve = $$promise$resolve$$default;
8165
+ $$es6$promise$promise$$Promise.reject = $$promise$reject$$default;
8166
 
8167
+ $$es6$promise$promise$$Promise.prototype = {
8168
+ constructor: $$es6$promise$promise$$Promise,
 
8169
 
8170
+ /**
8171
+ The primary way of interacting with a promise is through its `then` method,
8172
+ which registers callbacks to receive either a promise's eventual value or the
8173
+ reason why the promise cannot be fulfilled.
 
8174
 
8175
+ ```js
8176
+ findUser().then(function(user){
8177
+ // user is available
8178
+ }, function(reason){
8179
+ // user is unavailable, and you are given the reason why
8180
+ });
8181
+ ```
8182
 
8183
+ Chaining
8184
+ --------
 
 
 
 
8185
 
8186
+ The return value of `then` is itself a promise. This second, 'downstream'
8187
+ promise is resolved with the return value of the first promise's fulfillment
8188
+ or rejection handler, or rejected if the handler throws an exception.
 
 
 
 
 
 
 
 
 
8189
 
8190
+ ```js
8191
+ findUser().then(function (user) {
8192
+ return user.name;
8193
+ }, function (reason) {
8194
+ return 'default name';
8195
+ }).then(function (userName) {
8196
+ // If `findUser` fulfilled, `userName` will be the user's name, otherwise it
8197
+ // will be `'default name'`
8198
+ });
8199
 
8200
+ findUser().then(function (user) {
8201
+ throw new Error('Found user, but still unhappy');
8202
+ }, function (reason) {
8203
+ throw new Error('`findUser` rejected and we're unhappy');
8204
+ }).then(function (value) {
8205
+ // never reached
8206
+ }, function (reason) {
8207
+ // if `findUser` fulfilled, `reason` will be 'Found user, but still unhappy'.
8208
+ // If `findUser` rejected, `reason` will be '`findUser` rejected and we're unhappy'.
8209
+ });
8210
+ ```
8211
+ If the downstream promise does not specify a rejection handler, rejection reasons will be propagated further downstream.
8212
 
8213
+ ```js
8214
+ findUser().then(function (user) {
8215
+ throw new PedagogicalException('Upstream error');
8216
+ }).then(function (value) {
8217
+ // never reached
8218
+ }).then(function (value) {
8219
+ // never reached
8220
+ }, function (reason) {
8221
+ // The `PedgagocialException` is propagated all the way down to here
8222
+ });
8223
+ ```
8224
 
8225
+ Assimilation
8226
+ ------------
 
 
8227
 
8228
+ Sometimes the value you want to propagate to a downstream promise can only be
8229
+ retrieved asynchronously. This can be achieved by returning a promise in the
8230
+ fulfillment or rejection handler. The downstream promise will then be pending
8231
+ until the returned promise is settled. This is called *assimilation*.
 
8232
 
8233
+ ```js
8234
+ findUser().then(function (user) {
8235
+ return findCommentsByAuthor(user);
8236
+ }).then(function (comments) {
8237
+ // The user's comments are now available
8238
+ });
8239
+ ```
8240
 
8241
+ If the assimliated promise rejects, then the downstream promise will also reject.
 
 
8242
 
8243
+ ```js
8244
+ findUser().then(function (user) {
8245
+ return findCommentsByAuthor(user);
8246
+ }).then(function (comments) {
8247
+ // If `findCommentsByAuthor` fulfills, we'll have the value here
8248
+ }, function (reason) {
8249
+ // If `findCommentsByAuthor` rejects, we'll have the reason here
8250
+ });
8251
+ ```
8252
 
8253
+ Simple Example
8254
+ --------------
 
 
 
 
 
 
 
 
 
 
 
 
 
 
8255
 
8256
+ Synchronous Example
 
 
 
 
 
 
 
 
 
 
8257
 
8258
+ ```javascript
8259
+ var result;
8260
+
8261
+ try {
8262
+ result = findResult();
8263
+ // success
8264
+ } catch(reason) {
8265
+ // failure
8266
  }
8267
+ ```
8268
 
8269
+ Errback Example
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
8270
 
8271
+ ```js
8272
+ findResult(function(result, err){
8273
+ if (err) {
8274
+ // failure
8275
+ } else {
8276
+ // success
 
 
 
 
 
 
 
 
 
8277
  }
8278
+ });
8279
+ ```
8280
 
8281
+ Promise Example;
 
 
8282
 
8283
+ ```javascript
8284
+ findResult().then(function(result){
8285
+ // success
8286
+ }, function(reason){
8287
+ // failure
8288
+ });
8289
+ ```
 
 
 
 
 
 
 
 
8290
 
8291
+ Advanced Example
8292
+ --------------
 
 
8293
 
8294
+ Synchronous Example
 
 
 
 
8295
 
8296
+ ```javascript
8297
+ var author, books;
 
 
8298
 
8299
+ try {
8300
+ author = findAuthor();
8301
+ books = findBooksByAuthor(author);
8302
+ // success
8303
+ } catch(reason) {
8304
+ // failure
8305
+ }
8306
+ ```
8307
 
8308
+ Errback Example
 
 
 
8309
 
8310
+ ```js
 
 
 
 
 
 
 
8311
 
8312
+ function foundBooks(books) {
 
 
 
8313
 
8314
+ }
 
 
 
 
8315
 
8316
+ function failure(reason) {
 
 
 
 
8317
 
8318
+ }
 
 
 
 
8319
 
8320
+ findAuthor(function(author, err){
8321
+ if (err) {
8322
+ failure(err);
8323
+ // failure
8324
+ } else {
8325
+ try {
8326
+ findBoooksByAuthor(author, function(books, err) {
8327
+ if (err) {
8328
+ failure(err);
8329
+ } else {
8330
+ try {
8331
+ foundBooks(books);
8332
+ } catch(reason) {
8333
+ failure(reason);
8334
+ }
8335
+ }
8336
+ });
8337
+ } catch(error) {
8338
+ failure(err);
8339
+ }
8340
+ // success
8341
+ }
8342
+ });
8343
+ ```
8344
 
8345
+ Promise Example;
 
8346
 
8347
+ ```javascript
8348
+ findAuthor().
8349
+ then(findBooksByAuthor).
8350
+ then(function(books){
8351
+ // found books
8352
+ }).catch(function(reason){
8353
+ // something went wrong
8354
+ });
8355
+ ```
8356
 
8357
+ @method then
8358
+ @param {Function} onFulfilled
8359
+ @param {Function} onRejected
8360
+ Useful for tooling.
8361
+ @return {Promise}
8362
+ */
8363
+ then: function(onFulfillment, onRejection) {
8364
+ var parent = this;
8365
+ var state = parent._state;
8366
 
8367
+ if (state === $$$internal$$FULFILLED && !onFulfillment || state === $$$internal$$REJECTED && !onRejection) {
8368
+ return this;
8369
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
8370
 
8371
+ var child = new this.constructor($$$internal$$noop);
8372
+ var result = parent._result;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
8373
 
8374
+ if (state) {
8375
+ var callback = arguments[state - 1];
8376
+ $$asap$$default(function(){
8377
+ $$$internal$$invokeCallback(state, child, callback, result);
8378
+ });
8379
+ } else {
8380
+ $$$internal$$subscribe(parent, child, onFulfillment, onRejection);
8381
+ }
8382
 
8383
+ return child;
8384
+ },
 
 
 
 
 
8385
 
8386
+ /**
8387
+ `catch` is simply sugar for `then(undefined, onRejection)` which makes it the same
8388
+ as the catch block of a try/catch statement.
 
8389
 
8390
+ ```js
8391
+ function findAuthor(){
8392
+ throw new Error('couldn't find that author');
8393
+ }
 
 
 
8394
 
8395
+ // synchronous
8396
+ try {
8397
+ findAuthor();
8398
+ } catch(reason) {
8399
+ // something went wrong
 
8400
  }
 
 
 
 
 
 
 
8401
 
8402
+ // async with promises
8403
+ findAuthor().catch(function(reason){
8404
+ // something went wrong
8405
+ });
8406
+ ```
 
8407
 
8408
+ @method catch
8409
+ @param {Function} onRejection
8410
+ Useful for tooling.
8411
+ @return {Promise}
8412
+ */
8413
+ 'catch': function(onRejection) {
8414
+ return this.then(null, onRejection);
8415
+ }
8416
+ };
8417
 
8418
+ var $$es6$promise$polyfill$$default = function polyfill() {
8419
+ var local;
 
 
 
8420
 
8421
+ if (typeof global !== 'undefined') {
8422
+ local = global;
8423
+ } else if (typeof window !== 'undefined' && window.document) {
8424
+ local = window;
8425
+ } else {
8426
+ local = self;
8427
+ }
8428
 
8429
+ var es6PromiseSupport =
8430
+ "Promise" in local &&
8431
+ // Some of these methods are missing from
8432
+ // Firefox/Chrome experimental implementations
8433
+ "resolve" in local.Promise &&
8434
+ "reject" in local.Promise &&
8435
+ "all" in local.Promise &&
8436
+ "race" in local.Promise &&
8437
+ // Older version of the spec had a resolver object
8438
+ // as the arg rather than a function
8439
+ (function() {
8440
+ var resolve;
8441
+ new local.Promise(function(r) { resolve = r; });
8442
+ return $$utils$$isFunction(resolve);
8443
+ }());
8444
+
8445
+ if (!es6PromiseSupport) {
8446
+ local.Promise = $$es6$promise$promise$$default;
8447
  }
8448
+ };
 
8449
 
8450
+ var es6$promise$umd$$ES6Promise = {
8451
+ 'Promise': $$es6$promise$promise$$default,
8452
+ 'polyfill': $$es6$promise$polyfill$$default
8453
+ };
 
8454
 
8455
+ /* global define:true module:true window: true */
8456
+ if (typeof define === 'function' && define['amd']) {
8457
+ define(function() { return es6$promise$umd$$ES6Promise; });
8458
+ } else if (typeof module !== 'undefined' && module['exports']) {
8459
+ module['exports'] = es6$promise$umd$$ES6Promise;
8460
+ } else if (typeof this !== 'undefined') {
8461
+ this['ES6Promise'] = es6$promise$umd$$ES6Promise;
8462
+ }
8463
+ }).call(this);
8464
+ }).call(this,require('_process'),typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
8465
+ },{"_process":2}],2:[function(require,module,exports){
8466
+ // shim for using process in browser
8467
 
8468
+ var process = module.exports = {};
8469
+ var queue = [];
8470
+ var draining = false;
 
 
 
 
 
8471
 
8472
+ function drainQueue() {
8473
+ if (draining) {
8474
+ return;
8475
+ }
8476
+ draining = true;
8477
+ var currentQueue;
8478
+ var len = queue.length;
8479
+ while(len) {
8480
+ currentQueue = queue;
8481
+ queue = [];
8482
+ var i = -1;
8483
+ while (++i < len) {
8484
+ currentQueue[i]();
 
 
8485
  }
8486
+ len = queue.length;
 
8487
  }
8488
+ draining = false;
8489
+ }
8490
+ process.nextTick = function (fun) {
8491
+ queue.push(fun);
8492
+ if (!draining) {
8493
+ setTimeout(drainQueue, 0);
8494
+ }
8495
+ };
8496
 
8497
+ process.title = 'browser';
8498
+ process.browser = true;
8499
+ process.env = {};
8500
+ process.argv = [];
8501
+ process.version = ''; // empty string to avoid regexp issues
 
 
 
 
 
 
 
 
8502
 
8503
+ function noop() {}
 
8504
 
8505
+ process.on = noop;
8506
+ process.addListener = noop;
8507
+ process.once = noop;
8508
+ process.off = noop;
8509
+ process.removeListener = noop;
8510
+ process.removeAllListeners = noop;
8511
+ process.emit = noop;
8512
 
8513
+ process.binding = function (name) {
8514
+ throw new Error('process.binding is not supported');
8515
+ };
 
 
 
 
8516
 
8517
+ // TODO(shtylman)
8518
+ process.cwd = function () { return '/' };
8519
+ process.chdir = function (dir) {
8520
+ throw new Error('process.chdir is not supported');
8521
+ };
8522
+ process.umask = function() { return 0; };
 
 
8523
 
8524
+ },{}],3:[function(require,module,exports){
8525
+ (function (global){
8526
+ /*! http://mths.be/punycode v1.2.4 by @mathias */
8527
+ ;(function(root) {
8528
 
8529
+ /** Detect free variables */
8530
+ var freeExports = typeof exports == 'object' && exports;
8531
+ var freeModule = typeof module == 'object' && module &&
8532
+ module.exports == freeExports && module;
8533
+ var freeGlobal = typeof global == 'object' && global;
8534
+ if (freeGlobal.global === freeGlobal || freeGlobal.window === freeGlobal) {
8535
+ root = freeGlobal;
8536
+ }
8537
 
8538
+ /**
8539
+ * The `punycode` object.
8540
+ * @name punycode
8541
+ * @type Object
8542
+ */
8543
+ var punycode,
8544
 
8545
+ /** Highest positive signed 32-bit float value */
8546
+ maxInt = 2147483647, // aka. 0x7FFFFFFF or 2^31-1
8547
 
8548
+ /** Bootstring parameters */
8549
+ base = 36,
8550
+ tMin = 1,
8551
+ tMax = 26,
8552
+ skew = 38,
8553
+ damp = 700,
8554
+ initialBias = 72,
8555
+ initialN = 128, // 0x80
8556
+ delimiter = '-', // '\x2D'
8557
 
8558
+ /** Regular expressions */
8559
+ regexPunycode = /^xn--/,
8560
+ regexNonASCII = /[^ -~]/, // unprintable ASCII chars + non-ASCII chars
8561
+ regexSeparators = /\x2E|\u3002|\uFF0E|\uFF61/g, // RFC 3490 separators
8562
 
8563
+ /** Error messages */
8564
+ errors = {
8565
+ 'overflow': 'Overflow: input needs wider integers to process',
8566
+ 'not-basic': 'Illegal input >= 0x80 (not a basic code point)',
8567
+ 'invalid-input': 'Invalid input'
8568
+ },
8569
 
8570
+ /** Convenience shortcuts */
8571
+ baseMinusTMin = base - tMin,
8572
+ floor = Math.floor,
8573
+ stringFromCharCode = String.fromCharCode,
 
 
 
8574
 
8575
+ /** Temporary variable */
8576
+ key;
 
 
 
 
8577
 
8578
+ /*--------------------------------------------------------------------------*/
 
 
 
 
 
 
 
8579
 
8580
+ /**
8581
+ * A generic error utility function.
8582
+ * @private
8583
+ * @param {String} type The error type.
8584
+ * @returns {Error} Throws a `RangeError` with the applicable error message.
8585
+ */
8586
+ function error(type) {
8587
+ throw RangeError(errors[type]);
8588
+ }
8589
 
8590
+ /**
8591
+ * A generic `Array#map` utility function.
8592
+ * @private
8593
+ * @param {Array} array The array to iterate over.
8594
+ * @param {Function} callback The function that gets called for every array
8595
+ * item.
8596
+ * @returns {Array} A new array of values returned by the callback function.
8597
+ */
8598
+ function map(array, fn) {
8599
+ var length = array.length;
8600
+ while (length--) {
8601
+ array[length] = fn(array[length]);
8602
+ }
8603
+ return array;
8604
+ }
 
 
 
 
 
 
 
 
 
 
 
8605
 
8606
+ /**
8607
+ * A simple `Array#map`-like wrapper to work with domain name strings.
8608
+ * @private
8609
+ * @param {String} domain The domain name.
8610
+ * @param {Function} callback The function that gets called for every
8611
+ * character.
8612
+ * @returns {Array} A new string of characters returned by the callback
8613
+ * function.
8614
+ */
8615
+ function mapDomain(string, fn) {
8616
+ return map(string.split(regexSeparators), fn).join('.');
8617
+ }
8618
 
8619
+ /**
8620
+ * Creates an array containing the numeric code points of each Unicode
8621
+ * character in the string. While JavaScript uses UCS-2 internally,
8622
+ * this function will convert a pair of surrogate halves (each of which
8623
+ * UCS-2 exposes as separate characters) into a single code point,
8624
+ * matching UTF-16.
8625
+ * @see `punycode.ucs2.encode`
8626
+ * @see <http://mathiasbynens.be/notes/javascript-encoding>
8627
+ * @memberOf punycode.ucs2
8628
+ * @name decode
8629
+ * @param {String} string The Unicode input string (UCS-2).
8630
+ * @returns {Array} The new array of code points.
8631
+ */
8632
+ function ucs2decode(string) {
8633
+ var output = [],
8634
+ counter = 0,
8635
+ length = string.length,
8636
+ value,
8637
+ extra;
8638
+ while (counter < length) {
8639
+ value = string.charCodeAt(counter++);
8640
+ if (value >= 0xD800 && value <= 0xDBFF && counter < length) {
8641
+ // high surrogate, and there is a next character
8642
+ extra = string.charCodeAt(counter++);
8643
+ if ((extra & 0xFC00) == 0xDC00) { // low surrogate
8644
+ output.push(((value & 0x3FF) << 10) + (extra & 0x3FF) + 0x10000);
8645
+ } else {
8646
+ // unmatched surrogate; only append this code unit, in case the next
8647
+ // code unit is the high surrogate of a surrogate pair
8648
+ output.push(value);
8649
+ counter--;
8650
+ }
8651
+ } else {
8652
+ output.push(value);
8653
+ }
8654
+ }
8655
+ return output;
8656
+ }
8657
 
8658
+ /**
8659
+ * Creates a string based on an array of numeric code points.
8660
+ * @see `punycode.ucs2.decode`
8661
+ * @memberOf punycode.ucs2
8662
+ * @name encode
8663
+ * @param {Array} codePoints The array of numeric code points.
8664
+ * @returns {String} The new Unicode string (UCS-2).
8665
+ */
8666
+ function ucs2encode(array) {
8667
+ return map(array, function(value) {
8668
+ var output = '';
8669
+ if (value > 0xFFFF) {
8670
+ value -= 0x10000;
8671
+ output += stringFromCharCode(value >>> 10 & 0x3FF | 0xD800);
8672
+ value = 0xDC00 | value & 0x3FF;
8673
+ }
8674
+ output += stringFromCharCode(value);
8675
+ return output;
8676
+ }).join('');
8677
+ }
8678
 
8679
+ /**
8680
+ * Converts a basic code point into a digit/integer.
8681
+ * @see `digitToBasic()`
8682
+ * @private
8683
+ * @param {Number} codePoint The basic numeric code point value.
8684
+ * @returns {Number} The numeric value of a basic code point (for use in
8685
+ * representing integers) in the range `0` to `base - 1`, or `base` if
8686
+ * the code point does not represent a value.
8687
+ */
8688
+ function basicToDigit(codePoint) {
8689
+ if (codePoint - 48 < 10) {
8690
+ return codePoint - 22;
8691
+ }
8692
+ if (codePoint - 65 < 26) {
8693
+ return codePoint - 65;
8694
+ }
8695
+ if (codePoint - 97 < 26) {
8696
+ return codePoint - 97;
8697
+ }
8698
+ return base;
8699
+ }
8700
 
8701
+ /**
8702
+ * Converts a digit/integer into a basic code point.
8703
+ * @see `basicToDigit()`
8704
+ * @private
8705
+ * @param {Number} digit The numeric value of a basic code point.
8706
+ * @returns {Number} The basic code point whose value (when used for
8707
+ * representing integers) is `digit`, which needs to be in the range
8708
+ * `0` to `base - 1`. If `flag` is non-zero, the uppercase form is
8709
+ * used; else, the lowercase form is used. The behavior is undefined
8710
+ * if `flag` is non-zero and `digit` has no uppercase form.
8711
+ */
8712
+ function digitToBasic(digit, flag) {
8713
+ // 0..25 map to ASCII a..z or A..Z
8714
+ // 26..35 map to ASCII 0..9
8715
+ return digit + 22 + 75 * (digit < 26) - ((flag != 0) << 5);
8716
+ }
8717
 
8718
+ /**
8719
+ * Bias adaptation function as per section 3.4 of RFC 3492.
8720
+ * http://tools.ietf.org/html/rfc3492#section-3.4
8721
+ * @private
8722
+ */
8723
+ function adapt(delta, numPoints, firstTime) {
8724
+ var k = 0;
8725
+ delta = firstTime ? floor(delta / damp) : delta >> 1;
8726
+ delta += floor(delta / numPoints);
8727
+ for (/* no initialization */; delta > baseMinusTMin * tMax >> 1; k += base) {
8728
+ delta = floor(delta / baseMinusTMin);
8729
+ }
8730
+ return floor(k + (baseMinusTMin + 1) * delta / (delta + skew));
8731
+ }
8732
 
8733
+ /**
8734
+ * Converts a Punycode string of ASCII-only symbols to a string of Unicode
8735
+ * symbols.
8736
+ * @memberOf punycode
8737
+ * @param {String} input The Punycode string of ASCII-only symbols.
8738
+ * @returns {String} The resulting string of Unicode symbols.
8739
+ */
8740
+ function decode(input) {
8741
+ // Don't use UCS-2
8742
+ var output = [],
8743
+ inputLength = input.length,
8744
+ out,
8745
+ i = 0,
8746
+ n = initialN,
8747
+ bias = initialBias,
8748
+ basic,
8749
+ j,
8750
+ index,
8751
+ oldi,
8752
+ w,
8753
+ k,
8754
+ digit,
8755
+ t,
8756
+ /** Cached calculation results */
8757
+ baseMinusT;
8758
 
8759
+ // Handle the basic code points: let `basic` be the number of input code
8760
+ // points before the last delimiter, or `0` if there is none, then copy
8761
+ // the first basic code points to the output.
8762
 
8763
+ basic = input.lastIndexOf(delimiter);
8764
+ if (basic < 0) {
8765
+ basic = 0;
8766
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
8767
 
8768
+ for (j = 0; j < basic; ++j) {
8769
+ // if it's not a basic code point
8770
+ if (input.charCodeAt(j) >= 0x80) {
8771
+ error('not-basic');
8772
+ }
8773
+ output.push(input.charCodeAt(j));
8774
+ }
8775
 
8776
+ // Main decoding loop: start just after the last delimiter if any basic code
8777
+ // points were copied; start at the beginning otherwise.
8778
 
8779
+ for (index = basic > 0 ? basic + 1 : 0; index < inputLength; /* no final expression */) {
 
 
 
8780
 
8781
+ // `index` is the index of the next character to be consumed.
8782
+ // Decode a generalized variable-length integer into `delta`,
8783
+ // which gets added to `i`. The overflow checking is easier
8784
+ // if we increase `i` as we go, then subtract off its starting
8785
+ // value at the end to obtain `delta`.
8786
+ for (oldi = i, w = 1, k = base; /* no condition */; k += base) {
8787
 
8788
+ if (index >= inputLength) {
8789
+ error('invalid-input');
8790
+ }
 
 
8791
 
8792
+ digit = basicToDigit(input.charCodeAt(index++));
 
 
 
 
 
 
 
 
 
 
8793
 
8794
+ if (digit >= base || digit > floor((maxInt - i) / w)) {
8795
+ error('overflow');
8796
+ }
 
8797
 
8798
+ i += digit * w;
8799
+ t = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);
 
 
 
 
 
8800
 
8801
+ if (digit < t) {
8802
+ break;
8803
+ }
 
 
8804
 
8805
+ baseMinusT = base - t;
8806
+ if (w > floor(maxInt / baseMinusT)) {
8807
+ error('overflow');
8808
+ }
 
 
 
 
8809
 
8810
+ w *= baseMinusT;
 
 
 
 
8811
 
8812
+ }
 
8813
 
8814
+ out = output.length + 1;
8815
+ bias = adapt(i - oldi, out, oldi == 0);
 
 
 
 
 
 
8816
 
8817
+ // `i` was supposed to wrap around from `out` to `0`,
8818
+ // incrementing `n` each time, so we'll fix that now:
8819
+ if (floor(i / out) > maxInt - n) {
8820
+ error('overflow');
8821
+ }
 
8822
 
8823
+ n += floor(i / out);
8824
+ i %= out;
8825
 
8826
+ // Insert `n` at position `i` of the output
8827
+ output.splice(i++, 0, n);
 
8828
 
8829
+ }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
8830
 
8831
+ return ucs2encode(output);
8832
+ }
 
 
 
8833
 
8834
+ /**
8835
+ * Converts a string of Unicode symbols to a Punycode string of ASCII-only
8836
+ * symbols.
8837
+ * @memberOf punycode
8838
+ * @param {String} input The string of Unicode symbols.
8839
+ * @returns {String} The resulting Punycode string of ASCII-only symbols.
8840
+ */
8841
+ function encode(input) {
8842
+ var n,
8843
+ delta,
8844
+ handledCPCount,
8845
+ basicLength,
8846
+ bias,
8847
+ j,
8848
+ m,
8849
+ q,
8850
+ k,
8851
+ t,
8852
+ currentValue,
8853
+ output = [],
8854
+ /** `inputLength` will hold the number of code points in `input`. */
8855
+ inputLength,
8856
+ /** Cached calculation results */
8857
+ handledCPCountPlusOne,
8858
+ baseMinusT,
8859
+ qMinusT;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
8860
 
8861
+ // Convert the input in UCS-2 to Unicode
8862
+ input = ucs2decode(input);
8863
 
8864
+ // Cache the length
8865
+ inputLength = input.length;
 
8866
 
8867
+ // Initialize the state
8868
+ n = initialN;
8869
+ delta = 0;
8870
+ bias = initialBias;
 
8871
 
8872
+ // Handle the basic code points
8873
+ for (j = 0; j < inputLength; ++j) {
8874
+ currentValue = input[j];
8875
+ if (currentValue < 0x80) {
8876
+ output.push(stringFromCharCode(currentValue));
8877
+ }
8878
+ }
8879
 
8880
+ handledCPCount = basicLength = output.length;
 
 
 
 
 
8881
 
8882
+ // `handledCPCount` is the number of code points that have been handled;
8883
+ // `basicLength` is the number of basic code points.
 
 
 
 
8884
 
8885
+ // Finish the basic string - if it is not empty - with a delimiter
8886
+ if (basicLength) {
8887
+ output.push(delimiter);
8888
+ }
 
 
8889
 
8890
+ // Main encoding loop:
8891
+ while (handledCPCount < inputLength) {
 
 
 
 
 
8892
 
8893
+ // All non-basic code points < n have been handled already. Find the next
8894
+ // larger one:
8895
+ for (m = maxInt, j = 0; j < inputLength; ++j) {
8896
+ currentValue = input[j];
8897
+ if (currentValue >= n && currentValue < m) {
8898
+ m = currentValue;
8899
+ }
8900
+ }
 
 
 
8901
 
8902
+ // Increase `delta` enough to advance the decoder's <n,i> state to <m,0>,
8903
+ // but guard against overflow
8904
+ handledCPCountPlusOne = handledCPCount + 1;
8905
+ if (m - n > floor((maxInt - delta) / handledCPCountPlusOne)) {
8906
+ error('overflow');
8907
+ }
8908
 
8909
+ delta += (m - n) * handledCPCountPlusOne;
8910
+ n = m;
 
 
 
 
 
 
 
 
 
8911
 
8912
+ for (j = 0; j < inputLength; ++j) {
8913
+ currentValue = input[j];
8914
 
8915
+ if (currentValue < n && ++delta > maxInt) {
8916
+ error('overflow');
8917
+ }
8918
 
8919
+ if (currentValue == n) {
8920
+ // Represent delta as a generalized variable-length integer
8921
+ for (q = delta, k = base; /* no condition */; k += base) {
8922
+ t = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);
8923
+ if (q < t) {
8924
+ break;
8925
+ }
8926
+ qMinusT = q - t;
8927
+ baseMinusT = base - t;
8928
+ output.push(
8929
+ stringFromCharCode(digitToBasic(t + qMinusT % baseMinusT, 0))
8930
+ );
8931
+ q = floor(qMinusT / baseMinusT);
8932
+ }
8933
 
8934
+ output.push(stringFromCharCode(digitToBasic(q, 0)));
8935
+ bias = adapt(delta, handledCPCountPlusOne, handledCPCount == basicLength);
8936
+ delta = 0;
8937
+ ++handledCPCount;
8938
+ }
8939
+ }
8940
 
8941
+ ++delta;
8942
+ ++n;
8943
 
8944
+ }
8945
+ return output.join('');
8946
+ }
 
 
 
 
 
 
 
 
 
 
 
 
8947
 
8948
+ /**
8949
+ * Converts a Punycode string representing a domain name to Unicode. Only the
8950
+ * Punycoded parts of the domain name will be converted, i.e. it doesn't
8951
+ * matter if you call it on a string that has already been converted to
8952
+ * Unicode.
8953
+ * @memberOf punycode
8954
+ * @param {String} domain The Punycode domain name to convert to Unicode.
8955
+ * @returns {String} The Unicode representation of the given Punycode
8956
+ * string.
8957
+ */
8958
+ function toUnicode(domain) {
8959
+ return mapDomain(domain, function(string) {
8960
+ return regexPunycode.test(string)
8961
+ ? decode(string.slice(4).toLowerCase())
8962
+ : string;
8963
+ });
8964
+ }
8965
 
8966
+ /**
8967
+ * Converts a Unicode string representing a domain name to Punycode. Only the
8968
+ * non-ASCII parts of the domain name will be converted, i.e. it doesn't
8969
+ * matter if you call it with a domain that's already in ASCII.
8970
+ * @memberOf punycode
8971
+ * @param {String} domain The domain name to convert, as a Unicode string.
8972
+ * @returns {String} The Punycode representation of the given domain name.
8973
+ */
8974
+ function toASCII(domain) {
8975
+ return mapDomain(domain, function(string) {
8976
+ return regexNonASCII.test(string)
8977
+ ? 'xn--' + encode(string)
8978
+ : string;
8979
+ });
8980
+ }
8981
 
8982
+ /*--------------------------------------------------------------------------*/
 
8983
 
8984
+ /** Define the public API */
8985
+ punycode = {
8986
+ /**
8987
+ * A string representing the current Punycode.js version number.
8988
+ * @memberOf punycode
8989
+ * @type String
8990
+ */
8991
+ 'version': '1.2.4',
8992
+ /**
8993
+ * An object of methods to convert from JavaScript's internal character
8994
+ * representation (UCS-2) to Unicode code points, and back.
8995
+ * @see <http://mathiasbynens.be/notes/javascript-encoding>
8996
+ * @memberOf punycode
8997
+ * @type Object
8998
+ */
8999
+ 'ucs2': {
9000
+ 'decode': ucs2decode,
9001
+ 'encode': ucs2encode
9002
+ },
9003
+ 'decode': decode,
9004
+ 'encode': encode,
9005
+ 'toASCII': toASCII,
9006
+ 'toUnicode': toUnicode
9007
+ };
9008
 
9009
+ /** Expose `punycode` */
9010
+ // Some AMD build optimizers, like r.js, check for specific condition patterns
9011
+ // like the following:
9012
+ if (
9013
+ typeof define == 'function' &&
9014
+ typeof define.amd == 'object' &&
9015
+ define.amd
9016
+ ) {
9017
+ define('punycode', function() {
9018
+ return punycode;
9019
+ });
9020
+ } else if (freeExports && !freeExports.nodeType) {
9021
+ if (freeModule) { // in Node.js or RingoJS v0.8.0+
9022
+ freeModule.exports = punycode;
9023
+ } else { // in Narwhal or RingoJS v0.7.0-
9024
+ for (key in punycode) {
9025
+ punycode.hasOwnProperty(key) && (freeExports[key] = punycode[key]);
9026
+ }
9027
+ }
9028
+ } else { // in Rhino or a web browser
9029
+ root.punycode = punycode;
9030
+ }
9031
 
9032
+ }(this));
 
 
 
 
9033
 
9034
+ }).call(this,typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})
9035
+ },{}],4:[function(require,module,exports){
9036
+ var log = require('./log');
9037
+ var Promise = require('./promise');
9038
+
9039
+ var html2canvasCanvasCloneAttribute = "data-html2canvas-canvas-clone";
9040
+ var html2canvasCanvasCloneIndex = 0;
9041
+
9042
+ function cloneNodeValues(document, clone, nodeName) {
9043
+ var originalNodes = document.getElementsByTagName(nodeName);
9044
+ var clonedNodes = clone.getElementsByTagName(nodeName);
9045
+ var count = originalNodes.length;
9046
+ for (var i = 0; i < count; i++) {
9047
+ clonedNodes[i].value = originalNodes[i].value;
9048
+ }
9049
+ }
9050
+
9051
+ function restoreOwnerScroll(ownerDocument, x, y) {
9052
+ if (ownerDocument.defaultView && (x !== ownerDocument.defaultView.pageXOffset || y !== ownerDocument.defaultView.pageYOffset)) {
9053
+ ownerDocument.defaultView.scrollTo(x, y);
9054
+ }
9055
+ }
9056
+
9057
+ function labelCanvasElements(ownerDocument) {
9058
+ [].slice.call(ownerDocument.querySelectorAll("canvas"), 0).forEach(function(canvas) {
9059
+ canvas.setAttribute(html2canvasCanvasCloneAttribute, "canvas-" + html2canvasCanvasCloneIndex++);
9060
+ });
9061
+ }
9062
+
9063
+ function cloneCanvasContents(ownerDocument, documentClone) {
9064
+ [].slice.call(ownerDocument.querySelectorAll("[" + html2canvasCanvasCloneAttribute + "]"), 0).forEach(function(canvas) {
9065
+ try {
9066
+ var clonedCanvas = documentClone.querySelector('[' + html2canvasCanvasCloneAttribute + '="' + canvas.getAttribute(html2canvasCanvasCloneAttribute) + '"]');
9067
+ if (clonedCanvas) {
9068
+ clonedCanvas.width = canvas.width;
9069
+ clonedCanvas.height = canvas.height;
9070
+ clonedCanvas.getContext("2d").putImageData(canvas.getContext("2d").getImageData(0, 0, canvas.width, canvas.height), 0, 0);
9071
+ }
9072
+ } catch(e) {
9073
+ log("Unable to copy canvas content from", canvas, e);
9074
+ }
9075
+ canvas.removeAttribute(html2canvasCanvasCloneAttribute);
9076
+ });
9077
+ }
9078
+
9079
+ function removeScriptNodes(parent) {
9080
+ [].slice.call(parent.childNodes, 0).filter(isElementNode).forEach(function(node) {
9081
+ if (node.tagName === "SCRIPT") {
9082
+ parent.removeChild(node);
9083
+ } else {
9084
+ removeScriptNodes(node);
9085
+ }
9086
+ });
9087
+ return parent;
9088
+ }
9089
+
9090
+ function isIE9() {
9091
+ return document.documentMode && document.documentMode <= 9;
9092
+ }
9093
+
9094
+ // https://github.com/niklasvh/html2canvas/issues/503
9095
+ function cloneNodeIE9(node, javascriptEnabled) {
9096
+ var clone = node.nodeType === 3 ? document.createTextNode(node.nodeValue) : node.cloneNode(false);
9097
+
9098
+ var child = node.firstChild;
9099
+ while(child) {
9100
+ if (javascriptEnabled === true || child.nodeType !== 1 || child.nodeName !== 'SCRIPT') {
9101
+ clone.appendChild(cloneNodeIE9(child, javascriptEnabled));
9102
+ }
9103
+ child = child.nextSibling;
9104
+ }
9105
+
9106
+ return clone;
9107
+ }
9108
+
9109
+
9110
+
9111
+ function isElementNode(node) {
9112
+ return node.nodeType === Node.ELEMENT_NODE;
9113
+ }
9114
+
9115
+ module.exports = function(ownerDocument, containerDocument, width, height, options, x ,y) {
9116
+ labelCanvasElements(ownerDocument);
9117
+ var documentElement = isIE9() ? cloneNodeIE9(ownerDocument.documentElement, options.javascriptEnabled) : ownerDocument.documentElement.cloneNode(true);
9118
+ var container = containerDocument.createElement("iframe");
9119
+
9120
+ container.className = "html2canvas-container";
9121
+ container.style.visibility = "hidden";
9122
+ container.style.position = "fixed";
9123
+ container.style.left = "-10000px";
9124
+ container.style.top = "0px";
9125
+ container.style.border = "0";
9126
+ container.width = width;
9127
+ container.height = height;
9128
+ container.scrolling = "no"; // ios won't scroll without it
9129
+ containerDocument.body.appendChild(container);
9130
+
9131
+ return new Promise(function(resolve) {
9132
+ var documentClone = container.contentWindow.document;
9133
+
9134
+ cloneNodeValues(ownerDocument.documentElement, documentElement, "textarea");
9135
+ cloneNodeValues(ownerDocument.documentElement, documentElement, "select");
9136
+
9137
+ /* Chrome doesn't detect relative background-images assigned in inline <style> sheets when fetched through getComputedStyle
9138
+ if window url is about:blank, we can assign the url to current by writing onto the document
9139
+ */
9140
+ container.contentWindow.onload = container.onload = function() {
9141
+ var interval = setInterval(function() {
9142
+ if (documentClone.body.childNodes.length > 0) {
9143
+ cloneCanvasContents(ownerDocument, documentClone);
9144
+ clearInterval(interval);
9145
+ if (options.type === "view") {
9146
+ container.contentWindow.scrollTo(x, y);
9147
+ }
9148
+ resolve(container);
9149
+ }
9150
+ }, 50);
9151
+ };
9152
+
9153
+ documentClone.open();
9154
+ documentClone.write("<!DOCTYPE html><html></html>");
9155
+ // Chrome scrolls the parent document for some reason after the write to the cloned window???
9156
+ restoreOwnerScroll(ownerDocument, x, y);
9157
+ documentClone.replaceChild(options.javascriptEnabled === true ? documentClone.adoptNode(documentElement) : removeScriptNodes(documentClone.adoptNode(documentElement)), documentClone.documentElement);
9158
+ documentClone.close();
9159
+ });
9160
+ };
9161
 
9162
+ },{"./log":15,"./promise":18}],5:[function(require,module,exports){
9163
+ // http://dev.w3.org/csswg/css-color/
9164
+
9165
+ function Color(value) {
9166
+ this.r = 0;
9167
+ this.g = 0;
9168
+ this.b = 0;
9169
+ this.a = null;
9170
+ var result = this.fromArray(value) ||
9171
+ this.namedColor(value) ||
9172
+ this.rgb(value) ||
9173
+ this.rgba(value) ||
9174
+ this.hex6(value) ||
9175
+ this.hex3(value);
9176
+ }
9177
+
9178
+ Color.prototype.darken = function(amount) {
9179
+ var a = 1 - amount;
9180
+ return new Color([
9181
+ Math.round(this.r * a),
9182
+ Math.round(this.g * a),
9183
+ Math.round(this.b * a),
9184
+ this.a
9185
+ ]);
9186
+ };
9187
+
9188
+ Color.prototype.isTransparent = function() {
9189
+ return this.a === 0;
9190
+ };
9191
+
9192
+ Color.prototype.isBlack = function() {
9193
+ return this.r === 0 && this.g === 0 && this.b === 0;
9194
+ };
9195
+
9196
+ Color.prototype.fromArray = function(array) {
9197
+ if (Array.isArray(array)) {
9198
+ this.r = Math.min(array[0], 255);
9199
+ this.g = Math.min(array[1], 255);
9200
+ this.b = Math.min(array[2], 255);
9201
+ if (array.length > 3) {
9202
+ this.a = array[3];
9203
+ }
9204
+ }
9205
+
9206
+ return (Array.isArray(array));
9207
+ };
9208
+
9209
+ var _hex3 = /^#([a-f0-9]{3})$/i;
9210
+
9211
+ Color.prototype.hex3 = function(value) {
9212
+ var match = null;
9213
+ if ((match = value.match(_hex3)) !== null) {
9214
+ this.r = parseInt(match[1][0] + match[1][0], 16);
9215
+ this.g = parseInt(match[1][1] + match[1][1], 16);
9216
+ this.b = parseInt(match[1][2] + match[1][2], 16);
9217
+ }
9218
+ return match !== null;
9219
+ };
9220
+
9221
+ var _hex6 = /^#([a-f0-9]{6})$/i;
9222
+
9223
+ Color.prototype.hex6 = function(value) {
9224
+ var match = null;
9225
+ if ((match = value.match(_hex6)) !== null) {
9226
+ this.r = parseInt(match[1].substring(0, 2), 16);
9227
+ this.g = parseInt(match[1].substring(2, 4), 16);
9228
+ this.b = parseInt(match[1].substring(4, 6), 16);
9229
+ }
9230
+ return match !== null;
9231
+ };
9232
+
9233
+
9234
+ var _rgb = /^rgb\((\d{1,3}) *, *(\d{1,3}) *, *(\d{1,3})\)$/;
9235
+
9236
+ Color.prototype.rgb = function(value) {
9237
+ var match = null;
9238
+ if ((match = value.match(_rgb)) !== null) {
9239
+ this.r = Number(match[1]);
9240
+ this.g = Number(match[2]);
9241
+ this.b = Number(match[3]);
9242
+ }
9243
+ return match !== null;
9244
+ };
9245
+
9246
+ var _rgba = /^rgba\((\d{1,3}) *, *(\d{1,3}) *, *(\d{1,3}) *, *(\d+\.?\d*)\)$/;
9247
+
9248
+ Color.prototype.rgba = function(value) {
9249
+ var match = null;
9250
+ if ((match = value.match(_rgba)) !== null) {
9251
+ this.r = Number(match[1]);
9252
+ this.g = Number(match[2]);
9253
+ this.b = Number(match[3]);
9254
+ this.a = Number(match[4]);
9255
+ }
9256
+ return match !== null;
9257
+ };
9258
+
9259
+ Color.prototype.toString = function() {
9260
+ return this.a !== null && this.a !== 1 ?
9261
+ "rgba(" + [this.r, this.g, this.b, this.a].join(",") + ")" :
9262
+ "rgb(" + [this.r, this.g, this.b].join(",") + ")";
9263
+ };
9264
+
9265
+ Color.prototype.namedColor = function(value) {
9266
+ var color = colors[value.toLowerCase()];
9267
+ if (color) {
9268
+ this.r = color[0];
9269
+ this.g = color[1];
9270
+ this.b = color[2];
9271
+ } else if (value.toLowerCase() === "transparent") {
9272
+ this.r = this.g = this.b = this.a = 0;
9273
+ return true;
9274
+ }
9275
+
9276
+ return !!color;
9277
+ };
9278
+
9279
+ Color.prototype.isColor = true;
9280
+
9281
+ // JSON.stringify([].slice.call($$('.named-color-table tr'), 1).map(function(row) { return [row.childNodes[3].textContent, row.childNodes[5].textContent.trim().split(",").map(Number)] }).reduce(function(data, row) {data[row[0]] = row[1]; return data}, {}))
9282
+ var colors = {
9283
+ "aliceblue": [240, 248, 255],
9284
+ "antiquewhite": [250, 235, 215],
9285
+ "aqua": [0, 255, 255],
9286
+ "aquamarine": [127, 255, 212],
9287
+ "azure": [240, 255, 255],
9288
+ "beige": [245, 245, 220],
9289
+ "bisque": [255, 228, 196],
9290
+ "black": [0, 0, 0],
9291
+ "blanchedalmond": [255, 235, 205],
9292
+ "blue": [0, 0, 255],
9293
+ "blueviolet": [138, 43, 226],
9294
+ "brown": [165, 42, 42],
9295
+ "burlywood": [222, 184, 135],
9296
+ "cadetblue": [95, 158, 160],
9297
+ "chartreuse": [127, 255, 0],
9298
+ "chocolate": [210, 105, 30],
9299
+ "coral": [255, 127, 80],
9300
+ "cornflowerblue": [100, 149, 237],
9301
+ "cornsilk": [255, 248, 220],
9302
+ "crimson": [220, 20, 60],
9303
+ "cyan": [0, 255, 255],
9304
+ "darkblue": [0, 0, 139],
9305
+ "darkcyan": [0, 139, 139],
9306
+ "darkgoldenrod": [184, 134, 11],
9307
+ "darkgray": [169, 169, 169],
9308
+ "darkgreen": [0, 100, 0],
9309
+ "darkgrey": [169, 169, 169],
9310
+ "darkkhaki": [189, 183, 107],
9311
+ "darkmagenta": [139, 0, 139],
9312
+ "darkolivegreen": [85, 107, 47],
9313
+ "darkorange": [255, 140, 0],
9314
+ "darkorchid": [153, 50, 204],
9315
+ "darkred": [139, 0, 0],
9316
+ "darksalmon": [233, 150, 122],
9317
+ "darkseagreen": [143, 188, 143],
9318
+ "darkslateblue": [72, 61, 139],
9319
+ "darkslategray": [47, 79, 79],
9320
+ "darkslategrey": [47, 79, 79],
9321
+ "darkturquoise": [0, 206, 209],
9322
+ "darkviolet": [148, 0, 211],
9323
+ "deeppink": [255, 20, 147],
9324
+ "deepskyblue": [0, 191, 255],
9325
+ "dimgray": [105, 105, 105],
9326
+ "dimgrey": [105, 105, 105],
9327
+ "dodgerblue": [30, 144, 255],
9328
+ "firebrick": [178, 34, 34],
9329
+ "floralwhite": [255, 250, 240],
9330
+ "forestgreen": [34, 139, 34],
9331
+ "fuchsia": [255, 0, 255],
9332
+ "gainsboro": [220, 220, 220],
9333
+ "ghostwhite": [248, 248, 255],
9334
+ "gold": [255, 215, 0],
9335
+ "goldenrod": [218, 165, 32],
9336
+ "gray": [128, 128, 128],
9337
+ "green": [0, 128, 0],
9338
+ "greenyellow": [173, 255, 47],
9339
+ "grey": [128, 128, 128],
9340
+ "honeydew": [240, 255, 240],
9341
+ "hotpink": [255, 105, 180],
9342
+ "indianred": [205, 92, 92],
9343
+ "indigo": [75, 0, 130],
9344
+ "ivory": [255, 255, 240],
9345
+ "khaki": [240, 230, 140],
9346
+ "lavender": [230, 230, 250],
9347
+ "lavenderblush": [255, 240, 245],
9348
+ "lawngreen": [124, 252, 0],
9349
+ "lemonchiffon": [255, 250, 205],
9350
+ "lightblue": [173, 216, 230],
9351
+ "lightcoral": [240, 128, 128],
9352
+ "lightcyan": [224, 255, 255],
9353
+ "lightgoldenrodyellow": [250, 250, 210],
9354
+ "lightgray": [211, 211, 211],
9355
+ "lightgreen": [144, 238, 144],
9356
+ "lightgrey": [211, 211, 211],
9357
+ "lightpink": [255, 182, 193],
9358
+ "lightsalmon": [255, 160, 122],
9359
+ "lightseagreen": [32, 178, 170],
9360
+ "lightskyblue": [135, 206, 250],
9361
+ "lightslategray": [119, 136, 153],
9362
+ "lightslategrey": [119, 136, 153],
9363
+ "lightsteelblue": [176, 196, 222],
9364
+ "lightyellow": [255, 255, 224],
9365
+ "lime": [0, 255, 0],
9366
+ "limegreen": [50, 205, 50],
9367
+ "linen": [250, 240, 230],
9368
+ "magenta": [255, 0, 255],
9369
+ "maroon": [128, 0, 0],
9370
+ "mediumaquamarine": [102, 205, 170],
9371
+ "mediumblue": [0, 0, 205],
9372
+ "mediumorchid": [186, 85, 211],
9373
+ "mediumpurple": [147, 112, 219],
9374
+ "mediumseagreen": [60, 179, 113],
9375
+ "mediumslateblue": [123, 104, 238],
9376
+ "mediumspringgreen": [0, 250, 154],
9377
+ "mediumturquoise": [72, 209, 204],
9378
+ "mediumvioletred": [199, 21, 133],
9379
+ "midnightblue": [25, 25, 112],
9380
+ "mintcream": [245, 255, 250],
9381
+ "mistyrose": [255, 228, 225],
9382
+ "moccasin": [255, 228, 181],
9383
+ "navajowhite": [255, 222, 173],
9384
+ "navy": [0, 0, 128],
9385
+ "oldlace": [253, 245, 230],
9386
+ "olive": [128, 128, 0],
9387
+ "olivedrab": [107, 142, 35],
9388
+ "orange": [255, 165, 0],
9389
+ "orangered": [255, 69, 0],
9390
+ "orchid": [218, 112, 214],
9391
+ "palegoldenrod": [238, 232, 170],
9392
+ "palegreen": [152, 251, 152],
9393
+ "paleturquoise": [175, 238, 238],
9394
+ "palevioletred": [219, 112, 147],
9395
+ "papayawhip": [255, 239, 213],
9396
+ "peachpuff": [255, 218, 185],
9397
+ "peru": [205, 133, 63],
9398
+ "pink": [255, 192, 203],
9399
+ "plum": [221, 160, 221],
9400
+ "powderblue": [176, 224, 230],
9401
+ "purple": [128, 0, 128],
9402
+ "rebeccapurple": [102, 51, 153],
9403
+ "red": [255, 0, 0],
9404
+ "rosybrown": [188, 143, 143],
9405
+ "royalblue": [65, 105, 225],
9406
+ "saddlebrown": [139, 69, 19],
9407
+ "salmon": [250, 128, 114],
9408
+ "sandybrown": [244, 164, 96],
9409
+ "seagreen": [46, 139, 87],
9410
+ "seashell": [255, 245, 238],
9411
+ "sienna": [160, 82, 45],
9412
+ "silver": [192, 192, 192],
9413
+ "skyblue": [135, 206, 235],
9414
+ "slateblue": [106, 90, 205],
9415
+ "slategray": [112, 128, 144],
9416
+ "slategrey": [112, 128, 144],
9417
+ "snow": [255, 250, 250],
9418
+ "springgreen": [0, 255, 127],
9419
+ "steelblue": [70, 130, 180],
9420
+ "tan": [210, 180, 140],
9421
+ "teal": [0, 128, 128],
9422
+ "thistle": [216, 191, 216],
9423
+ "tomato": [255, 99, 71],
9424
+ "turquoise": [64, 224, 208],
9425
+ "violet": [238, 130, 238],
9426
+ "wheat": [245, 222, 179],
9427
+ "white": [255, 255, 255],
9428
+ "whitesmoke": [245, 245, 245],
9429
+ "yellow": [255, 255, 0],
9430
+ "yellowgreen": [154, 205, 50]
9431
+ };
9432
+
9433
+ module.exports = Color;
9434
 
9435
+ },{}],6:[function(require,module,exports){
9436
+ var Promise = require('./promise');
9437
+ var Support = require('./support');
9438
+ var CanvasRenderer = require('./renderers/canvas');
9439
+ var ImageLoader = require('./imageloader');
9440
+ var NodeParser = require('./nodeparser');
9441
+ var NodeContainer = require('./nodecontainer');
9442
+ var log = require('./log');
9443
+ var utils = require('./utils');
9444
+ var createWindowClone = require('./clone');
9445
+ var loadUrlDocument = require('./proxy').loadUrlDocument;
9446
+ var getBounds = utils.getBounds;
9447
+
9448
+ var html2canvasNodeAttribute = "data-html2canvas-node";
9449
+ var html2canvasCloneIndex = 0;
9450
+
9451
+ function html2canvas(nodeList, options) {
9452
+ var index = html2canvasCloneIndex++;
9453
+ options = options || {};
9454
+ if (options.logging) {
9455
+ window.html2canvas.logging = true;
9456
+ window.html2canvas.start = Date.now();
9457
+ }
9458
+
9459
+ options.async = typeof(options.async) === "undefined" ? true : options.async;
9460
+ options.allowTaint = typeof(options.allowTaint) === "undefined" ? false : options.allowTaint;
9461
+ options.removeContainer = typeof(options.removeContainer) === "undefined" ? true : options.removeContainer;
9462
+ options.javascriptEnabled = typeof(options.javascriptEnabled) === "undefined" ? false : options.javascriptEnabled;
9463
+ options.imageTimeout = typeof(options.imageTimeout) === "undefined" ? 10000 : options.imageTimeout;
9464
+ options.renderer = typeof(options.renderer) === "function" ? options.renderer : CanvasRenderer;
9465
+ options.strict = !!options.strict;
9466
+
9467
+ if (typeof(nodeList) === "string") {
9468
+ if (typeof(options.proxy) !== "string") {
9469
+ return Promise.reject("Proxy must be used when rendering url");
9470
+ }
9471
+ var width = options.width != null ? options.width : window.innerWidth;
9472
+ var height = options.height != null ? options.height : window.innerHeight;
9473
+ return loadUrlDocument(absoluteUrl(nodeList), options.proxy, document, width, height, options).then(function(container) {
9474
+ return renderWindow(container.contentWindow.document.documentElement, container, options, width, height);
9475
+ });
9476
+ }
9477
+
9478
+ var node = ((nodeList === undefined) ? [document.documentElement] : ((nodeList.length) ? nodeList : [nodeList]))[0];
9479
+ node.setAttribute(html2canvasNodeAttribute + index, index);
9480
+ return renderDocument(node.ownerDocument, options, node.ownerDocument.defaultView.innerWidth, node.ownerDocument.defaultView.innerHeight, index).then(function(canvas) {
9481
+ if (typeof(options.onrendered) === "function") {
9482
+ log("options.onrendered is deprecated, html2canvas returns a Promise containing the canvas");
9483
+ options.onrendered(canvas);
9484
+ }
9485
+ return canvas;
9486
+ });
9487
+ }
9488
+
9489
+ html2canvas.Promise = Promise;
9490
+ html2canvas.CanvasRenderer = CanvasRenderer;
9491
+ html2canvas.NodeContainer = NodeContainer;
9492
+ html2canvas.log = log;
9493
+ html2canvas.utils = utils;
9494
+
9495
+ module.exports = (typeof(document) === "undefined" || typeof(Object.create) !== "function" || typeof(document.createElement("canvas").getContext) !== "function") ? function() {
9496
+ return Promise.reject("No canvas support");
9497
+ } : html2canvas;
9498
+
9499
+ function renderDocument(document, options, windowWidth, windowHeight, html2canvasIndex) {
9500
+ return createWindowClone(document, document, windowWidth, windowHeight, options, document.defaultView.pageXOffset, document.defaultView.pageYOffset).then(function(container) {
9501
+ log("Document cloned");
9502
+ var attributeName = html2canvasNodeAttribute + html2canvasIndex;
9503
+ var selector = "[" + attributeName + "='" + html2canvasIndex + "']";
9504
+ document.querySelector(selector).removeAttribute(attributeName);
9505
+ var clonedWindow = container.contentWindow;
9506
+ var node = clonedWindow.document.querySelector(selector);
9507
+ var oncloneHandler = (typeof(options.onclone) === "function") ? Promise.resolve(options.onclone(clonedWindow.document)) : Promise.resolve(true);
9508
+ return oncloneHandler.then(function() {
9509
+ return renderWindow(node, container, options, windowWidth, windowHeight);
9510
+ });
9511
+ });
9512
+ }
9513
+
9514
+ function renderWindow(node, container, options, windowWidth, windowHeight) {
9515
+ var clonedWindow = container.contentWindow;
9516
+ var support = new Support(clonedWindow.document);
9517
+ var imageLoader = new ImageLoader(options, support);
9518
+ var bounds = getBounds(node);
9519
+ var width = options.type === "view" ? windowWidth : documentWidth(clonedWindow.document);
9520
+ var height = options.type === "view" ? windowHeight : documentHeight(clonedWindow.document);
9521
+ var renderer = new options.renderer(width, height, imageLoader, options, document);
9522
+ var parser = new NodeParser(node, renderer, support, imageLoader, options);
9523
+ return parser.ready.then(function() {
9524
+ log("Finished rendering");
9525
+ var canvas;
9526
+
9527
+ if (options.type === "view") {
9528
+ canvas = crop(renderer.canvas, {width: renderer.canvas.width, height: renderer.canvas.height, top: 0, left: 0, x: 0, y: 0});
9529
+ } else if (node === clonedWindow.document.body || node === clonedWindow.document.documentElement || options.canvas != null) {
9530
+ canvas = renderer.canvas;
9531
+ } else {
9532
+ canvas = crop(renderer.canvas, {width: options.width != null ? options.width : bounds.width, height: options.height != null ? options.height : bounds.height, top: bounds.top, left: bounds.left, x: clonedWindow.pageXOffset, y: clonedWindow.pageYOffset});
9533
+ }
9534
+
9535
+ cleanupContainer(container, options);
9536
+ return canvas;
9537
+ });
9538
+ }
9539
+
9540
+ function cleanupContainer(container, options) {
9541
+ if (options.removeContainer) {
9542
+ container.parentNode.removeChild(container);
9543
+ log("Cleaned up container");
9544
+ }
9545
+ }
9546
+
9547
+ function crop(canvas, bounds) {
9548
+ var croppedCanvas = document.createElement("canvas");
9549
+ var x1 = Math.min(canvas.width - 1, Math.max(0, bounds.left));
9550
+ var x2 = Math.min(canvas.width, Math.max(1, bounds.left + bounds.width));
9551
+ var y1 = Math.min(canvas.height - 1, Math.max(0, bounds.top));
9552
+ var y2 = Math.min(canvas.height, Math.max(1, bounds.top + bounds.height));
9553
+ croppedCanvas.width = bounds.width;
9554
+ croppedCanvas.height = bounds.height;
9555
+ log("Cropping canvas at:", "left:", bounds.left, "top:", bounds.top, "width:", (x2-x1), "height:", (y2-y1));
9556
+ log("Resulting crop with width", bounds.width, "and height", bounds.height, " with x", x1, "and y", y1);
9557
+ croppedCanvas.getContext("2d").drawImage(canvas, x1, y1, x2-x1, y2-y1, bounds.x, bounds.y, x2-x1, y2-y1);
9558
+ return croppedCanvas;
9559
+ }
9560
+
9561
+ function documentWidth (doc) {
9562
+ return Math.max(
9563
+ Math.max(doc.body.scrollWidth, doc.documentElement.scrollWidth),
9564
+ Math.max(doc.body.offsetWidth, doc.documentElement.offsetWidth),
9565
+ Math.max(doc.body.clientWidth, doc.documentElement.clientWidth)
9566
+ );
9567
+ }
9568
+
9569
+ function documentHeight (doc) {
9570
+ return Math.max(
9571
+ Math.max(doc.body.scrollHeight, doc.documentElement.scrollHeight),
9572
+ Math.max(doc.body.offsetHeight, doc.documentElement.offsetHeight),
9573
+ Math.max(doc.body.clientHeight, doc.documentElement.clientHeight)
9574
+ );
9575
+ }
9576
+
9577
+ function absoluteUrl(url) {
9578
+ var link = document.createElement("a");
9579
+ link.href = url;
9580
+ link.href = link.href;
9581
+ return link;
9582
+ }
9583
 
9584
+ },{"./clone":4,"./imageloader":13,"./log":15,"./nodecontainer":16,"./nodeparser":17,"./promise":18,"./proxy":19,"./renderers/canvas":23,"./support":25,"./utils":29}],7:[function(require,module,exports){
9585
+ var Promise = require('./promise');
9586
+ var log = require('./log');
9587
+ var smallImage = require('./utils').smallImage;
9588
+
9589
+ function DummyImageContainer(src) {
9590
+ this.src = src;
9591
+ log("DummyImageContainer for", src);
9592
+ if (!this.promise || !this.image) {
9593
+ log("Initiating DummyImageContainer");
9594
+ DummyImageContainer.prototype.image = new Image();
9595
+ var image = this.image;
9596
+ DummyImageContainer.prototype.promise = new Promise(function(resolve, reject) {
9597
+ image.onload = resolve;
9598
+ image.onerror = reject;
9599
+ image.src = smallImage();
9600
+ if (image.complete === true) {
9601
+ resolve(image);
9602
+ }
9603
+ });
9604
+ }
9605
+ }
9606
+
9607
+ module.exports = DummyImageContainer;
9608
 
9609
+ },{"./log":15,"./promise":18,"./utils":29}],8:[function(require,module,exports){
9610
+ var smallImage = require('./utils').smallImage;
9611
+
9612
+ function Font(family, size) {
9613
+ var container = document.createElement('div'),
9614
+ img = document.createElement('img'),
9615
+ span = document.createElement('span'),
9616
+ sampleText = 'Hidden Text',
9617
+ baseline,
9618
+ middle;
9619
+
9620
+ container.style.visibility = "hidden";
9621
+ container.style.fontFamily = family;
9622
+ container.style.fontSize = size;
9623
+ container.style.margin = 0;
9624
+ container.style.padding = 0;
9625
+
9626
+ document.body.appendChild(container);
9627
+
9628
+ img.src = smallImage();
9629
+ img.width = 1;
9630
+ img.height = 1;
9631
+
9632
+ img.style.margin = 0;
9633
+ img.style.padding = 0;
9634
+ img.style.verticalAlign = "baseline";
9635
+
9636
+ span.style.fontFamily = family;
9637
+ span.style.fontSize = size;
9638
+ span.style.margin = 0;
9639
+ span.style.padding = 0;
9640
+
9641
+ span.appendChild(document.createTextNode(sampleText));
9642
+ container.appendChild(span);
9643
+ container.appendChild(img);
9644
+ baseline = (img.offsetTop - span.offsetTop) + 1;
9645
+
9646
+ container.removeChild(span);
9647
+ container.appendChild(document.createTextNode(sampleText));
9648
+
9649
+ container.style.lineHeight = "normal";
9650
+ img.style.verticalAlign = "super";
9651
+
9652
+ middle = (img.offsetTop-container.offsetTop) + 1;
9653
+
9654
+ document.body.removeChild(container);
9655
+
9656
+ this.baseline = baseline;
9657
+ this.lineWidth = 1;
9658
+ this.middle = middle;
9659
+ }
9660
+
9661
+ module.exports = Font;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9662
 
9663
+ },{"./utils":29}],9:[function(require,module,exports){
9664
+ var Font = require('./font');
9665
+
9666
+ function FontMetrics() {
9667
+ this.data = {};
9668
+ }
9669
+
9670
+ FontMetrics.prototype.getMetrics = function(family, size) {
9671
+ if (this.data[family + "-" + size] === undefined) {
9672
+ this.data[family + "-" + size] = new Font(family, size);
9673
+ }
9674
+ return this.data[family + "-" + size];
9675
+ };
9676
+
9677
+ module.exports = FontMetrics;
9678
 
9679
+ },{"./font":8}],10:[function(require,module,exports){
9680
+ var utils = require('./utils');
9681
+ var Promise = require('./promise');
9682
+ var getBounds = utils.getBounds;
9683
+ var loadUrlDocument = require('./proxy').loadUrlDocument;
9684
+
9685
+ function FrameContainer(container, sameOrigin, options) {
9686
+ this.image = null;
9687
+ this.src = container;
9688
+ var self = this;
9689
+ var bounds = getBounds(container);
9690
+ this.promise = (!sameOrigin ? this.proxyLoad(options.proxy, bounds, options) : new Promise(function(resolve) {
9691
+ if (container.contentWindow.document.URL === "about:blank" || container.contentWindow.document.documentElement == null) {
9692
+ container.contentWindow.onload = container.onload = function() {
9693
+ resolve(container);
9694
+ };
9695
+ } else {
9696
+ resolve(container);
9697
+ }
9698
+ })).then(function(container) {
9699
+ var html2canvas = require('./core');
9700
+ return html2canvas(container.contentWindow.document.documentElement, {type: 'view', width: container.width, height: container.height, proxy: options.proxy, javascriptEnabled: options.javascriptEnabled, removeContainer: options.removeContainer, allowTaint: options.allowTaint, imageTimeout: options.imageTimeout / 2});
9701
+ }).then(function(canvas) {
9702
+ return self.image = canvas;
9703
+ });
9704
+ }
9705
+
9706
+ FrameContainer.prototype.proxyLoad = function(proxy, bounds, options) {
9707
+ var container = this.src;
9708
+ return loadUrlDocument(container.src, proxy, container.ownerDocument, bounds.width, bounds.height, options);
9709
+ };
9710
+
9711
+ module.exports = FrameContainer;
9712
 
9713
+ },{"./core":6,"./promise":18,"./proxy":19,"./utils":29}],11:[function(require,module,exports){
9714
+ var Promise = require('./promise');
9715
+
9716
+ function GradientContainer(imageData) {
9717
+ this.src = imageData.value;
9718
+ this.colorStops = [];
9719
+ this.type = null;
9720
+ this.x0 = 0.5;
9721
+ this.y0 = 0.5;
9722
+ this.x1 = 0.5;
9723
+ this.y1 = 0.5;
9724
+ this.promise = Promise.resolve(true);
9725
+ }
9726
+
9727
+ GradientContainer.prototype.TYPES = {
9728
+ LINEAR: 1,
9729
+ RADIAL: 2
9730
+ };
9731
+
9732
+ module.exports = GradientContainer;
9733
 
9734
+ },{"./promise":18}],12:[function(require,module,exports){
9735
+ var Promise = require('./promise');
9736
+
9737
+ function ImageContainer(src, cors) {
9738
+ this.src = src;
9739
+ this.image = new Image();
9740
+ var self = this;
9741
+ this.tainted = null;
9742
+ this.promise = new Promise(function(resolve, reject) {
9743
+ self.image.onload = resolve;
9744
+ self.image.onerror = reject;
9745
+ if (cors) {
9746
+ self.image.crossOrigin = "anonymous";
9747
+ }
9748
+ self.image.src = src;
9749
+ if (self.image.complete === true) {
9750
+ resolve(self.image);
9751
+ }
9752
+ });
9753
+ }
9754
+
9755
+ module.exports = ImageContainer;
9756
 
9757
+ },{"./promise":18}],13:[function(require,module,exports){
9758
+ var Promise = require('./promise');
9759
+ var log = require('./log');
9760
+ var ImageContainer = require('./imagecontainer');
9761
+ var DummyImageContainer = require('./dummyimagecontainer');
9762
+ var ProxyImageContainer = require('./proxyimagecontainer');
9763
+ var FrameContainer = require('./framecontainer');
9764
+ var SVGContainer = require('./svgcontainer');
9765
+ var SVGNodeContainer = require('./svgnodecontainer');
9766
+ var LinearGradientContainer = require('./lineargradientcontainer');
9767
+ var WebkitGradientContainer = require('./webkitgradientcontainer');
9768
+ var bind = require('./utils').bind;
9769
+
9770
+ function ImageLoader(options, support) {
9771
+ this.link = null;
9772
+ this.options = options;
9773
+ this.support = support;
9774
+ this.origin = this.getOrigin(window.location.href);
9775
+ }
9776
+
9777
+ ImageLoader.prototype.findImages = function(nodes) {
9778
+ var images = [];
9779
+ nodes.reduce(function(imageNodes, container) {
9780
+ switch(container.node.nodeName) {
9781
+ case "IMG":
9782
+ return imageNodes.concat([{
9783
+ args: [container.node.src],
9784
+ method: "url"
9785
+ }]);
9786
+ case "svg":
9787
+ case "IFRAME":
9788
+ return imageNodes.concat([{
9789
+ args: [container.node],
9790
+ method: container.node.nodeName
9791
+ }]);
9792
+ }
9793
+ return imageNodes;
9794
+ }, []).forEach(this.addImage(images, this.loadImage), this);
9795
+ return images;
9796
+ };
9797
+
9798
+ ImageLoader.prototype.findBackgroundImage = function(images, container) {
9799
+ container.parseBackgroundImages().filter(this.hasImageBackground).forEach(this.addImage(images, this.loadImage), this);
9800
+ return images;
9801
+ };
9802
+
9803
+ ImageLoader.prototype.addImage = function(images, callback) {
9804
+ return function(newImage) {
9805
+ newImage.args.forEach(function(image) {
9806
+ if (!this.imageExists(images, image)) {
9807
+ images.splice(0, 0, callback.call(this, newImage));
9808
+ log('Added image #' + (images.length), typeof(image) === "string" ? image.substring(0, 100) : image);
9809
+ }
9810
+ }, this);
9811
+ };
9812
+ };
9813
+
9814
+ ImageLoader.prototype.hasImageBackground = function(imageData) {
9815
+ return imageData.method !== "none";
9816
+ };
9817
+
9818
+ ImageLoader.prototype.loadImage = function(imageData) {
9819
+ if (imageData.method === "url") {
9820
+ var src = imageData.args[0];
9821
+ if (this.isSVG(src) && !this.support.svg && !this.options.allowTaint) {
9822
+ return new SVGContainer(src);
9823
+ } else if (src.match(/data:image\/.*;base64,/i)) {
9824
+ return new ImageContainer(src.replace(/url\(['"]{0,}|['"]{0,}\)$/ig, ''), false);
9825
+ } else if (this.isSameOrigin(src) || this.options.allowTaint === true || this.isSVG(src)) {
9826
+ return new ImageContainer(src, false);
9827
+ } else if (this.support.cors && !this.options.allowTaint && this.options.useCORS) {
9828
+ return new ImageContainer(src, true);
9829
+ } else if (this.options.proxy) {
9830
+ return new ProxyImageContainer(src, this.options.proxy);
9831
+ } else {
9832
+ return new DummyImageContainer(src);
9833
+ }
9834
+ } else if (imageData.method === "linear-gradient") {
9835
+ return new LinearGradientContainer(imageData);
9836
+ } else if (imageData.method === "gradient") {
9837
+ return new WebkitGradientContainer(imageData);
9838
+ } else if (imageData.method === "svg") {
9839
+ return new SVGNodeContainer(imageData.args[0], this.support.svg);
9840
+ } else if (imageData.method === "IFRAME") {
9841
+ return new FrameContainer(imageData.args[0], this.isSameOrigin(imageData.args[0].src), this.options);
9842
+ } else {
9843
+ return new DummyImageContainer(imageData);
9844
+ }
9845
+ };
9846
+
9847
+ ImageLoader.prototype.isSVG = function(src) {
9848
+ return src.substring(src.length - 3).toLowerCase() === "svg" || SVGContainer.prototype.isInline(src);
9849
+ };
9850
+
9851
+ ImageLoader.prototype.imageExists = function(images, src) {
9852
+ return images.some(function(image) {
9853
+ return image.src === src;
9854
+ });
9855
+ };
9856
+
9857
+ ImageLoader.prototype.isSameOrigin = function(url) {
9858
+ return (this.getOrigin(url) === this.origin);
9859
+ };
9860
+
9861
+ ImageLoader.prototype.getOrigin = function(url) {
9862
+ var link = this.link || (this.link = document.createElement("a"));
9863
+ link.href = url;
9864
+ link.href = link.href; // IE9, LOL! - http://jsfiddle.net/niklasvh/2e48b/
9865
+ return link.protocol + link.hostname + link.port;
9866
+ };
9867
+
9868
+ ImageLoader.prototype.getPromise = function(container) {
9869
+ return this.timeout(container, this.options.imageTimeout)['catch'](function() {
9870
+ var dummy = new DummyImageContainer(container.src);
9871
+ return dummy.promise.then(function(image) {
9872
+ container.image = image;
9873
+ });
9874
+ });
9875
+ };
9876
+
9877
+ ImageLoader.prototype.get = function(src) {
9878
+ var found = null;
9879
+ return this.images.some(function(img) {
9880
+ return (found = img).src === src;
9881
+ }) ? found : null;
9882
+ };
9883
+
9884
+ ImageLoader.prototype.fetch = function(nodes) {
9885
+ this.images = nodes.reduce(bind(this.findBackgroundImage, this), this.findImages(nodes));
9886
+ this.images.forEach(function(image, index) {
9887
+ image.promise.then(function() {
9888
+ log("Succesfully loaded image #"+ (index+1), image);
9889
+ }, function(e) {
9890
+ log("Failed loading image #"+ (index+1), image, e);
9891
+ });
9892
+ });
9893
+ this.ready = Promise.all(this.images.map(this.getPromise, this));
9894
+ log("Finished searching images");
9895
+ return this;
9896
+ };
9897
+
9898
+ ImageLoader.prototype.timeout = function(container, timeout) {
9899
+ var timer;
9900
+ var promise = Promise.race([container.promise, new Promise(function(res, reject) {
9901
+ timer = setTimeout(function() {
9902
+ log("Timed out loading image", container);
9903
+ reject(container);
9904
+ }, timeout);
9905
+ })]).then(function(container) {
9906
+ clearTimeout(timer);
9907
+ return container;
9908
+ });
9909
+ promise['catch'](function() {
9910
+ clearTimeout(timer);
9911
+ });
9912
+ return promise;
9913
+ };
9914
+
9915
+ module.exports = ImageLoader;
9916
 
9917
+ },{"./dummyimagecontainer":7,"./framecontainer":10,"./imagecontainer":12,"./lineargradientcontainer":14,"./log":15,"./promise":18,"./proxyimagecontainer":20,"./svgcontainer":26,"./svgnodecontainer":27,"./utils":29,"./webkitgradientcontainer":30}],14:[function(require,module,exports){
9918
+ var GradientContainer = require('./gradientcontainer');
9919
+ var Color = require('./color');
9920
+
9921
+ function LinearGradientContainer(imageData) {
9922
+ GradientContainer.apply(this, arguments);
9923
+ this.type = this.TYPES.LINEAR;
9924
+
9925
+ var hasDirection = imageData.args[0].match(this.stepRegExp) === null;
9926
+
9927
+ if (hasDirection) {
9928
+ imageData.args[0].split(" ").reverse().forEach(function(position) {
9929
+ switch(position) {
9930
+ case "left":
9931
+ this.x0 = 0;
9932
+ this.x1 = 1;
9933
+ break;
9934
+ case "top":
9935
+ this.y0 = 0;
9936
+ this.y1 = 1;
9937
+ break;
9938
+ case "right":
9939
+ this.x0 = 1;
9940
+ this.x1 = 0;
9941
+ break;
9942
+ case "bottom":
9943
+ this.y0 = 1;
9944
+ this.y1 = 0;
9945
+ break;
9946
+ case "to":
9947
+ var y0 = this.y0;
9948
+ var x0 = this.x0;
9949
+ this.y0 = this.y1;
9950
+ this.x0 = this.x1;
9951
+ this.x1 = x0;
9952
+ this.y1 = y0;
9953
+ break;
9954
+ }
9955
+ }, this);
9956
+ } else {
9957
+ this.y0 = 0;
9958
+ this.y1 = 1;
9959
+ }
9960
+
9961
+ this.colorStops = imageData.args.slice(hasDirection ? 1 : 0).map(function(colorStop) {
9962
+ var colorStopMatch = colorStop.match(this.stepRegExp);
9963
+ return {
9964
+ color: new Color(colorStopMatch[1]),
9965
+ stop: colorStopMatch[3] === "%" ? colorStopMatch[2] / 100 : null
9966
+ };
9967
+ }, this);
9968
+
9969
+ if (this.colorStops[0].stop === null) {
9970
+ this.colorStops[0].stop = 0;
9971
+ }
9972
+
9973
+ if (this.colorStops[this.colorStops.length - 1].stop === null) {
9974
+ this.colorStops[this.colorStops.length - 1].stop = 1;
9975
+ }
9976
+
9977
+ this.colorStops.forEach(function(colorStop, index) {
9978
+ if (colorStop.stop === null) {
9979
+ this.colorStops.slice(index).some(function(find, count) {
9980
+ if (find.stop !== null) {
9981
+ colorStop.stop = ((find.stop - this.colorStops[index - 1].stop) / (count + 1)) + this.colorStops[index - 1].stop;
9982
+ return true;
9983
+ } else {
9984
+ return false;
9985
+ }
9986
+ }, this);
9987
+ }
9988
+ }, this);
9989
+ }
9990
+
9991
+ LinearGradientContainer.prototype = Object.create(GradientContainer.prototype);
9992
+
9993
+ LinearGradientContainer.prototype.stepRegExp = /((?:rgb|rgba)\(\d{1,3},\s\d{1,3},\s\d{1,3}(?:,\s[0-9\.]+)?\))\s*(\d{1,3})?(%|px)?/;
9994
+
9995
+ module.exports = LinearGradientContainer;
9996
 
9997
+ },{"./color":5,"./gradientcontainer":11}],15:[function(require,module,exports){
9998
+ module.exports = function() {
9999
+ if (window.html2canvas.logging && window.console && window.console.log) {
10000
+ Function.prototype.bind.call(window.console.log, (window.console)).apply(window.console, [(Date.now() - window.html2canvas.start) + "ms", "html2canvas:"].concat([].slice.call(arguments, 0)));
10001
+ }
10002
+ };
 
 
 
 
 
 
 
 
 
 
 
10003
 
10004
+ },{}],16:[function(require,module,exports){
10005
+ var Color = require('./color');
10006
+ var utils = require('./utils');
10007
+ var getBounds = utils.getBounds;
10008
+ var parseBackgrounds = utils.parseBackgrounds;
10009
+ var offsetBounds = utils.offsetBounds;
10010
+
10011
+ function NodeContainer(node, parent) {
10012
+ this.node = node;
10013
+ this.parent = parent;
10014
+ this.stack = null;
10015
+ this.bounds = null;
10016
+ this.borders = null;
10017
+ this.clip = [];
10018
+ this.backgroundClip = [];
10019
+ this.offsetBounds = null;
10020
+ this.visible = null;
10021
+ this.computedStyles = null;
10022
+ this.colors = {};
10023
+ this.styles = {};
10024
+ this.backgroundImages = null;
10025
+ this.transformData = null;
10026
+ this.transformMatrix = null;
10027
+ this.isPseudoElement = false;
10028
+ this.opacity = null;
10029
+ }
10030
+
10031
+ NodeContainer.prototype.cloneTo = function(stack) {
10032
+ stack.visible = this.visible;
10033
+ stack.borders = this.borders;
10034
+ stack.bounds = this.bounds;
10035
+ stack.clip = this.clip;
10036
+ stack.backgroundClip = this.backgroundClip;
10037
+ stack.computedStyles = this.computedStyles;
10038
+ stack.styles = this.styles;
10039
+ stack.backgroundImages = this.backgroundImages;
10040
+ stack.opacity = this.opacity;
10041
+ };
10042
+
10043
+ NodeContainer.prototype.getOpacity = function() {
10044
+ return this.opacity === null ? (this.opacity = this.cssFloat('opacity')) : this.opacity;
10045
+ };
10046
+
10047
+ NodeContainer.prototype.assignStack = function(stack) {
10048
+ this.stack = stack;
10049
+ stack.children.push(this);
10050
+ };
10051
+
10052
+ NodeContainer.prototype.isElementVisible = function() {
10053
+ return this.node.nodeType === Node.TEXT_NODE ? this.parent.visible : (
10054
+ this.css('display') !== "none" &&
10055
+ this.css('visibility') !== "hidden" &&
10056
+ !this.node.hasAttribute("data-html2canvas-ignore") &&
10057
+ (this.node.nodeName !== "INPUT" || this.node.getAttribute("type") !== "hidden")
10058
+ );
10059
+ };
10060
+
10061
+ NodeContainer.prototype.css = function(attribute) {
10062
+ if (!this.computedStyles) {
10063
+ this.computedStyles = this.isPseudoElement ? this.parent.computedStyle(this.before ? ":before" : ":after") : this.computedStyle(null);
10064
+ }
10065
+
10066
+ return this.styles[attribute] || (this.styles[attribute] = this.computedStyles[attribute]);
10067
+ };
10068
+
10069
+ NodeContainer.prototype.prefixedCss = function(attribute) {
10070
+ var prefixes = ["webkit", "moz", "ms", "o"];
10071
+ var value = this.css(attribute);
10072
+ if (value === undefined) {
10073
+ prefixes.some(function(prefix) {
10074
+ value = this.css(prefix + attribute.substr(0, 1).toUpperCase() + attribute.substr(1));
10075
+ return value !== undefined;
10076
+ }, this);
10077
+ }
10078
+ return value === undefined ? null : value;
10079
+ };
10080
+
10081
+ NodeContainer.prototype.computedStyle = function(type) {
10082
+ return this.node.ownerDocument.defaultView.getComputedStyle(this.node, type);
10083
+ };
10084
+
10085
+ NodeContainer.prototype.cssInt = function(attribute) {
10086
+ var value = parseInt(this.css(attribute), 10);
10087
+ return (isNaN(value)) ? 0 : value; // borders in old IE are throwing 'medium' for demo.html
10088
+ };
10089
+
10090
+ NodeContainer.prototype.color = function(attribute) {
10091
+ return this.colors[attribute] || (this.colors[attribute] = new Color(this.css(attribute)));
10092
+ };
10093
+
10094
+ NodeContainer.prototype.cssFloat = function(attribute) {
10095
+ var value = parseFloat(this.css(attribute));
10096
+ return (isNaN(value)) ? 0 : value;
10097
+ };
10098
+
10099
+ NodeContainer.prototype.fontWeight = function() {
10100
+ var weight = this.css("fontWeight");
10101
+ switch(parseInt(weight, 10)){
10102
+ case 401:
10103
+ weight = "bold";
10104
+ break;
10105
+ case 400:
10106
+ weight = "normal";
10107
+ break;
10108
+ }
10109
+ return weight;
10110
+ };
10111
+
10112
+ NodeContainer.prototype.parseClip = function() {
10113
+ var matches = this.css('clip').match(this.CLIP);
10114
+ if (matches) {
10115
+ return {
10116
+ top: parseInt(matches[1], 10),
10117
+ right: parseInt(matches[2], 10),
10118
+ bottom: parseInt(matches[3], 10),
10119
+ left: parseInt(matches[4], 10)
10120
+ };
10121
+ }
10122
+ return null;
10123
+ };
10124
+
10125
+ NodeContainer.prototype.parseBackgroundImages = function() {
10126
+ return this.backgroundImages || (this.backgroundImages = parseBackgrounds(this.css("backgroundImage")));
10127
+ };
10128
+
10129
+ NodeContainer.prototype.cssList = function(property, index) {
10130
+ var value = (this.css(property) || '').split(',');
10131
+ value = value[index || 0] || value[0] || 'auto';
10132
+ value = value.trim().split(' ');
10133
+ if (value.length === 1) {
10134
+ value = [value[0], isPercentage(value[0]) ? 'auto' : value[0]];
10135
+ }
10136
+ return value;
10137
+ };
10138
+
10139
+ NodeContainer.prototype.parseBackgroundSize = function(bounds, image, index) {
10140
+ var size = this.cssList("backgroundSize", index);
10141
+ var width, height;
10142
+
10143
+ if (isPercentage(size[0])) {
10144
+ width = bounds.width * parseFloat(size[0]) / 100;
10145
+ } else if (/contain|cover/.test(size[0])) {
10146
+ var targetRatio = bounds.width / bounds.height, currentRatio = image.width / image.height;
10147
+ return (targetRatio < currentRatio ^ size[0] === 'contain') ? {width: bounds.height * currentRatio, height: bounds.height} : {width: bounds.width, height: bounds.width / currentRatio};
10148
+ } else {
10149
+ width = parseInt(size[0], 10);
10150
+ }
10151
+
10152
+ if (size[0] === 'auto' && size[1] === 'auto') {
10153
+ height = image.height;
10154
+ } else if (size[1] === 'auto') {
10155
+ height = width / image.width * image.height;
10156
+ } else if (isPercentage(size[1])) {
10157
+ height = bounds.height * parseFloat(size[1]) / 100;
10158
+ } else {
10159
+ height = parseInt(size[1], 10);
10160
+ }
10161
+
10162
+ if (size[0] === 'auto') {
10163
+ width = height / image.height * image.width;
10164
+ }
10165
+
10166
+ return {width: width, height: height};
10167
+ };
10168
+
10169
+ NodeContainer.prototype.parseBackgroundPosition = function(bounds, image, index, backgroundSize) {
10170
+ var position = this.cssList('backgroundPosition', index);
10171
+ var left, top;
10172
+
10173
+ if (isPercentage(position[0])){
10174
+ left = (bounds.width - (backgroundSize || image).width) * (parseFloat(position[0]) / 100);
10175
+ } else {
10176
+ left = parseInt(position[0], 10);
10177
+ }
10178
+
10179
+ if (position[1] === 'auto') {
10180
+ top = left / image.width * image.height;
10181
+ } else if (isPercentage(position[1])){
10182
+ top = (bounds.height - (backgroundSize || image).height) * parseFloat(position[1]) / 100;
10183
+ } else {
10184
+ top = parseInt(position[1], 10);
10185
+ }
10186
+
10187
+ if (position[0] === 'auto') {
10188
+ left = top / image.height * image.width;
10189
+ }
10190
+
10191
+ return {left: left, top: top};
10192
+ };
10193
+
10194
+ NodeContainer.prototype.parseBackgroundRepeat = function(index) {
10195
+ return this.cssList("backgroundRepeat", index)[0];
10196
+ };
10197
+
10198
+ NodeContainer.prototype.parseTextShadows = function() {
10199
+ var textShadow = this.css("textShadow");
10200
+ var results = [];
10201
+
10202
+ if (textShadow && textShadow !== 'none') {
10203
+ var shadows = textShadow.match(this.TEXT_SHADOW_PROPERTY);
10204
+ for (var i = 0; shadows && (i < shadows.length); i++) {
10205
+ var s = shadows[i].match(this.TEXT_SHADOW_VALUES);
10206
+ results.push({
10207
+ color: new Color(s[0]),
10208
+ offsetX: s[1] ? parseFloat(s[1].replace('px', '')) : 0,
10209
+ offsetY: s[2] ? parseFloat(s[2].replace('px', '')) : 0,
10210
+ blur: s[3] ? s[3].replace('px', '') : 0
10211
+ });
10212
+ }
10213
+ }
10214
+ return results;
10215
+ };
10216
+
10217
+ NodeContainer.prototype.parseTransform = function() {
10218
+ if (!this.transformData) {
10219
+ if (this.hasTransform()) {
10220
+ var offset = this.parseBounds();
10221
+ var origin = this.prefixedCss("transformOrigin").split(" ").map(removePx).map(asFloat);
10222
+ origin[0] += offset.left;
10223
+ origin[1] += offset.top;
10224
+ this.transformData = {
10225
+ origin: origin,
10226
+ matrix: this.parseTransformMatrix()
10227
+ };
10228
+ } else {
10229
+ this.transformData = {
10230
+ origin: [0, 0],
10231
+ matrix: [1, 0, 0, 1, 0, 0]
10232
+ };
10233
+ }
10234
+ }
10235
+ return this.transformData;
10236
+ };
10237
+
10238
+ NodeContainer.prototype.parseTransformMatrix = function() {
10239
+ if (!this.transformMatrix) {
10240
+ var transform = this.prefixedCss("transform");
10241
+ var matrix = transform ? parseMatrix(transform.match(this.MATRIX_PROPERTY)) : null;
10242
+ this.transformMatrix = matrix ? matrix : [1, 0, 0, 1, 0, 0];
10243
+ }
10244
+ return this.transformMatrix;
10245
+ };
10246
+
10247
+ NodeContainer.prototype.parseBounds = function() {
10248
+ return this.bounds || (this.bounds = this.hasTransform() ? offsetBounds(this.node) : getBounds(this.node));
10249
+ };
10250
+
10251
+ NodeContainer.prototype.hasTransform = function() {
10252
+ return this.parseTransformMatrix().join(",") !== "1,0,0,1,0,0" || (this.parent && this.parent.hasTransform());
10253
+ };
10254
+
10255
+ NodeContainer.prototype.getValue = function() {
10256
+ var value = this.node.value || "";
10257
+ if (this.node.tagName === "SELECT") {
10258
+ value = selectionValue(this.node);
10259
+ } else if (this.node.type === "password") {
10260
+ value = Array(value.length + 1).join('\u2022'); // jshint ignore:line
10261
+ }
10262
+ return value.length === 0 ? (this.node.placeholder || "") : value;
10263
+ };
10264
+
10265
+ NodeContainer.prototype.MATRIX_PROPERTY = /(matrix)\((.+)\)/;
10266
+ NodeContainer.prototype.TEXT_SHADOW_PROPERTY = /((rgba|rgb)\([^\)]+\)(\s-?\d+px){0,})/g;
10267
+ NodeContainer.prototype.TEXT_SHADOW_VALUES = /(-?\d+px)|(#.+)|(rgb\(.+\))|(rgba\(.+\))/g;
10268
+ NodeContainer.prototype.CLIP = /^rect\((\d+)px,? (\d+)px,? (\d+)px,? (\d+)px\)$/;
10269
+
10270
+ function selectionValue(node) {
10271
+ var option = node.options[node.selectedIndex || 0];
10272
+ return option ? (option.text || "") : "";
10273
+ }
10274
+
10275
+ function parseMatrix(match) {
10276
+ if (match && match[1] === "matrix") {
10277
+ return match[2].split(",").map(function(s) {
10278
+ return parseFloat(s.trim());
10279
+ });
10280
+ }
10281
+ }
10282
+
10283
+ function isPercentage(value) {
10284
+ return value.toString().indexOf("%") !== -1;
10285
+ }
10286
+
10287
+ function removePx(str) {
10288
+ return str.replace("px", "");
10289
+ }
10290
+
10291
+ function asFloat(str) {
10292
+ return parseFloat(str);
10293
+ }
10294
+
10295
+ module.exports = NodeContainer;
10296