Data Tables Generator by Supsystic - Version 1.9.80

Version Description

/ 18.09.2019 = * Fixed maps shortcodes * Fixed admin paging * Formulas fix * Update Handsontable to 7.1.1 and switch formula parser to RuleJS * Fixed edit link localize script * Fixed translation bug with loco * Fixed pdf|print exporter * Fixed invisible cells * Fix for woo attributes * Minor issues fix

Download this release

Release Info

Developer supsystic.com
Plugin Icon 128x128 Data Tables Generator by Supsystic
Version 1.9.80
Comparing to
See all releases

Code changes from version 1.9.77 to 1.9.80

Files changed (29) hide show
  1. app/SupsysticTables.php +1 -1
  2. app/assets/css/supsystic-ui.css +14 -0
  3. app/assets/js/supsystic.ui.js +3 -2
  4. app/langs/default.po +5 -5
  5. index.php +3 -1
  6. readme.txt +112 -9
  7. src/SupsysticTables/Core/Module.php +1 -1
  8. src/SupsysticTables/Core/assets/js/core.js +136 -15
  9. src/SupsysticTables/Core/assets/js/lib/dataTables.customExtensions.js +16 -5
  10. src/SupsysticTables/Overview/Module.php +11 -0
  11. src/SupsysticTables/Overview/assets/js/jquery.slimscroll.js +443 -440
  12. src/SupsysticTables/Promo/Module.php +1 -0
  13. src/SupsysticTables/Promo/assets/css/tutorial.css +15 -0
  14. src/SupsysticTables/Promo/assets/js/tutorial.js +6 -3
  15. src/SupsysticTables/Promo/views/pluginDeactivation.twig +70 -70
  16. src/SupsysticTables/Settings/views/index.twig +21 -1
  17. src/SupsysticTables/Tables/Controller.php +9 -2
  18. src/SupsysticTables/Tables/Model/Tables.php +10 -0
  19. src/SupsysticTables/Tables/Module.php +184 -27
  20. src/SupsysticTables/Tables/assets/css/tables.editor.css +12 -2
  21. src/SupsysticTables/Tables/assets/css/tables.shortcode.css +18 -0
  22. src/SupsysticTables/Tables/assets/css/tables.view.css +13 -2
  23. src/SupsysticTables/Tables/assets/js/editor/tables.editor.formula.js +8 -6
  24. src/SupsysticTables/Tables/assets/js/editor/tables.editor.js +46 -20
  25. src/SupsysticTables/Tables/assets/js/editor/tables.editor.toolbar.js +82 -25
  26. src/SupsysticTables/Tables/assets/js/tables.model.js +17 -12
  27. src/SupsysticTables/Tables/assets/js/tables.view.js +59 -32
  28. src/SupsysticTables/Tables/assets/libraries/handsontable/handsontable.full.min.css +50 -29
  29. src/SupsysticTables/Tables/assets/libraries/handsontable/handsontable.full.min.js +33 -51
app/SupsysticTables.php CHANGED
@@ -18,7 +18,7 @@ class SupsysticTables
18
 
19
  $menuSlug = 'supsystic-tables';
20
  $pluginPath = dirname(dirname(__FILE__));
21
- $environment = new Rsc_Environment('st', '1.9.77', $pluginPath);
22
 
23
  /* Configure */
24
  $environment->configure(
18
 
19
  $menuSlug = 'supsystic-tables';
20
  $pluginPath = dirname(dirname(__FILE__));
21
+ $environment = new Rsc_Environment('st', '1.9.80', $pluginPath);
22
 
23
  /* Configure */
24
  $environment->configure(
app/assets/css/supsystic-ui.css CHANGED
@@ -522,6 +522,20 @@ h3.nav-tab-wrapper {
522
 
523
  .fa.supsystic-tooltip {
524
  color:#52bac5;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
525
  }
526
 
527
  /*sticky items*/
522
 
523
  .fa.supsystic-tooltip {
524
  color:#52bac5;
525
+ position: relative;
526
+ }
527
+ .fa.supsystic-tooltip:after{
528
+ content: '';
529
+ display: block;
530
+ position: absolute;
531
+ width: 25px;
532
+ height: 35px;
533
+ top: -13px;
534
+ left: -7px;
535
+ }
536
+ .fa.supsystic-tooltip:hover:after{
537
+ width: 200px;
538
+ transition: all 0.1s ease;
539
  }
540
 
541
  /*sticky items*/
app/assets/js/supsystic.ui.js CHANGED
@@ -50,11 +50,12 @@
50
  delay: 1000,
51
  updateAnimation: false,
52
  animation: '',
53
- functionReady: function(origin) {
54
  $('img').load(function(){
55
  origin.tooltipster('reposition');
56
  });
57
- }
 
58
  });
59
 
60
  $('[data-target-toggle]').on('click change ifChanged', function(event) {
50
  delay: 1000,
51
  updateAnimation: false,
52
  animation: '',
53
+ functionReady: function(origin,e) {
54
  $('img').load(function(){
55
  origin.tooltipster('reposition');
56
  });
57
+ },
58
+ hideOnClick: 1
59
  });
60
 
61
  $('[data-target-toggle]').on('click change ifChanged', function(event) {
app/langs/default.po CHANGED
@@ -59,8 +59,8 @@ msgstr ""
59
 
60
  msgid ""
61
  "A stacked column chart is a column chart that places related values atop one another.<br /><br />\n"
62
- " "Relative Mode" formats each value as a fraction of 1.<br /><br />\n"
63
- " "Percent Mode" formats each value as a percentage of 100%. "
64
  msgstr ""
65
 
66
  msgid "A0"
@@ -175,7 +175,7 @@ msgid "Allows export to PDF file the fonts, which were set for table content via
175
  msgstr ""
176
 
177
  msgid ""
178
- "Allows to <a href="%s" target="_blank">use frontend fields only for logged in users</a>. See the next buttons on the editor toolbar:<br />\n"
179
  " Add editable field<br />\n"
180
  " Add dropdown list"
181
  msgstr ""
@@ -919,8 +919,8 @@ msgid ""
919
  "If checked - width of table columns will be calculated automatically for table width 100%.<br /><br />\n"
920
  " Otherwise - you can set table width manually: columns width will be get from Fixed Table Width option\n"
921
  " (toolbar on Editor tab) or calculated depending on the columns width in the table editor.<br /><br />\n"
922
- " If you do not want to apply columns width at all - you should uncheck "Auto Table Width" option, set "Fixed Table Width"\n"
923
- " option to "auto" and check "Compact Table" option."
924
  msgstr ""
925
 
926
  msgid "If multiple sorting for columns is not set - the table will be sorted in the specified order by the column set in the table settings: Settings-> Features-> Sorting Order / Sorting Column. Otherwise - table will be sorted by the specified custom columns in sequense, in which they are listed."
59
 
60
  msgid ""
61
  "A stacked column chart is a column chart that places related values atop one another.<br /><br />\n"
62
+ " \"Relative Mode\" formats each value as a fraction of 1.<br /><br />\n"
63
+ " \"Percent Mode\" formats each value as a percentage of 100%. "
64
  msgstr ""
65
 
66
  msgid "A0"
175
  msgstr ""
176
 
177
  msgid ""
178
+ "Allows to <a href=\"%s\" target=\"_blank\">use frontend fields only for logged in users</a>. See the next buttons on the editor toolbar:<br />\n"
179
  " Add editable field<br />\n"
180
  " Add dropdown list"
181
  msgstr ""
919
  "If checked - width of table columns will be calculated automatically for table width 100%.<br /><br />\n"
920
  " Otherwise - you can set table width manually: columns width will be get from Fixed Table Width option\n"
921
  " (toolbar on Editor tab) or calculated depending on the columns width in the table editor.<br /><br />\n"
922
+ " If you do not want to apply columns width at all - you should uncheck \"Auto Table Width\" option, set \"Fixed Table Width\"\n"
923
+ " option to \"auto\" and check \"Compact Table\" option."
924
  msgstr ""
925
 
926
  msgid "If multiple sorting for columns is not set - the table will be sorted in the specified order by the column set in the table settings: Settings-> Features-> Sorting Order / Sorting Column. Otherwise - table will be sorted by the specified custom columns in sequense, in which they are listed."
index.php CHANGED
@@ -4,9 +4,11 @@
4
  * Plugin Name: Data Tables Generator by Supsystic
5
  * Plugin URI: http://supsystic.com
6
  * Description: Create and manage beautiful data tables with custom design. No HTML knowledge is required
7
- * Version: 1.9.77
8
  * Author: supsystic.com
9
  * Author URI: http://supsystic.com
 
 
10
  */
11
 
12
  include dirname(__FILE__) . '/app/SupsysticTables.php';
4
  * Plugin Name: Data Tables Generator by Supsystic
5
  * Plugin URI: http://supsystic.com
6
  * Description: Create and manage beautiful data tables with custom design. No HTML knowledge is required
7
+ * Version: 1.9.80
8
  * Author: supsystic.com
9
  * Author URI: http://supsystic.com
10
+ * Text Domain: supsystic_tables
11
+ * Domain Path: /app/langs
12
  */
13
 
14
  include dirname(__FILE__) . '/app/SupsysticTables.php';
readme.txt CHANGED
@@ -1,8 +1,8 @@
1
  === Data Tables Generator by Supsystic ===
2
  Contributors: supsystic.com
3
- Tags: csv, excel, table, tablesorter,data table, table, database, table generator, builder, generator, cells, chart, charting, charts, column chart, gauge chart, graph, graphs, html5, line chart, pie chart, scatter chart, spreadsheet, visualise data, Woo, Woo Commerce, WooCommerce, product table, woocommerce product, product tables, catalog, product catalog, price list, pricing list, order forms, woocommerce tables, wholesale
4
- Tested up to: 5.2.1
5
- Stable tag: 1.9.77
6
 
7
  Create data tables with charts and graphs. Custom design, navigation, searching and ordering functions. Export to PDF, CSV, Print. Excel spreadsheet. WooCommerce Integration.
8
 
@@ -13,15 +13,15 @@ Create responsive data tables with sorting, searching, pagination, filtering and
13
  [Data Tables WordPress plugin](http://supsystic.com/plugins/data-tables-generator-plugin?utm_source=wordpress&utm_medium=description&utm_campaign=datatables "Data Tables WordPress plugin") features:
14
 
15
  * [Responsive Modes](https://supsystic.com/feature/responsive-modes-feature/?utm_source=wordpress&utm_medium=responsivemodes&utm_campaign=datatables "Responsive Modes") and [Large Tables](https://supsystic.com/example/tables-with-server-side-processing-example/ "Large Tables") support
16
- * [Diagrams, Charts and Graphs](https://supsystic.com/example/table-with-diagram-example/?utm_source=wordpress&utm_medium=screenshotscharts&utm_campaign=datatables "Data Table With Google Charts")
17
  * [Formulas and HTML support](https://supsystic.com/example/table-with-calculations-example?utm_source=wordpress&utm_medium=calculations&utm_campaign=datatables "Formulas and HTML support")
18
  * [Filters, Search, Sorting and Pagination](https://supsystic.com/example/table-with-sorting-and-search-example?utm_source=wordpress&utm_medium=tablenavigation&utm_campaign=datatables "Data Table navigation with Searching and Ordering functions")
19
- * [FrontEnd Table Editing](https://supsystic.com/example/drop-down-bar/?utm_source=wordpress&utm_medium=frontendediting&utm_campaign=datatables "FrontEnd Data Table Editing Example")
20
- * [Table export and import from CSV, Excel, PDF](https://supsystic.com/example/export-import-of-tables?utm_source=wordpress&utm_medium=export&utm_campaign=datatables "Export & Import of Tables")
21
  * [Images, Links & Video support](https://supsystic.com/example/table-with-pictures-and-links-example?utm_source=wordpress&utm_medium=vedeo&utm_campaign=datatables "Images, Links & Video support")
22
- * [WooCommerce Product Table](https://supsystic.com/plugins/woocommerce-product-table?utm_source=wordpress&utm_medium=description&utm_campaign=woocommercedatatable "WooCommerce Product Table")
23
- * [Automatic import from Google Sheets](https://supsystic.com/documentation/synchronization-table-google-sheet?utm_source=wordpress&utm_medium=featuresgoogle&utm_campaign=datatables "Autoupdates from Google Sheets")
24
- * [Database Source](https://supsystic.com/feature/database-source?utm_source=wordpress&utm_medium=featuresgoogle&utm_campaign=datatables "Database Source")
25
 
26
  [youtube https://www.youtube.com/watch?v=RZ2I-aCiLZE]
27
 
@@ -210,10 +210,113 @@ It's perfect for product [Price List](http://woo.supsystic.com/price-list "Price
210
  * All necessary settings to set the table appearance. Customize the **[Table design](https://supsystic.com/documentation/product-table-design?utm_source=wordpress&utm_medium=design&utm_campaign=woocommercedatatable "Table Design")** and make it more attractive for customers.
211
  * Works perfectly with hundreds of products and a huge amount of rows by virtue of using **[server-side processing technology](https://supsystic.com/example/tables-with-server-side-processing-example?utm_source=wordpress&utm_medium=serversideprocessing&utm_campaign=datatables "server-side processing").**
212
 
 
213
  Create custom order forms which increase your conversion rate!
214
 
215
  == Changelog ==
216
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
217
  = 1.9.77 / 11.06.2019 =
218
  * Small fix for Edit link on frontend
219
 
1
  === Data Tables Generator by Supsystic ===
2
  Contributors: supsystic.com
3
+ Tags: data table, spreadsheet, table builder, charts, graphs, wordpress table plugin, excel, line chart, pie chart, visualise data
4
+ Tested up to: 5.2
5
+ Stable tag: 1.9.80
6
 
7
  Create data tables with charts and graphs. Custom design, navigation, searching and ordering functions. Export to PDF, CSV, Print. Excel spreadsheet. WooCommerce Integration.
8
 
13
  [Data Tables WordPress plugin](http://supsystic.com/plugins/data-tables-generator-plugin?utm_source=wordpress&utm_medium=description&utm_campaign=datatables "Data Tables WordPress plugin") features:
14
 
15
  * [Responsive Modes](https://supsystic.com/feature/responsive-modes-feature/?utm_source=wordpress&utm_medium=responsivemodes&utm_campaign=datatables "Responsive Modes") and [Large Tables](https://supsystic.com/example/tables-with-server-side-processing-example/ "Large Tables") support
16
+ * [Diagrams, Charts and Graphs](https://supsystic.com/example/table-with-diagram-example/?utm_source=wordpress&utm_medium=screenshotscharts&utm_campaign=datatables "Data Table With Google Charts")*
17
  * [Formulas and HTML support](https://supsystic.com/example/table-with-calculations-example?utm_source=wordpress&utm_medium=calculations&utm_campaign=datatables "Formulas and HTML support")
18
  * [Filters, Search, Sorting and Pagination](https://supsystic.com/example/table-with-sorting-and-search-example?utm_source=wordpress&utm_medium=tablenavigation&utm_campaign=datatables "Data Table navigation with Searching and Ordering functions")
19
+ * [FrontEnd Table Editing](https://supsystic.com/example/drop-down-bar/?utm_source=wordpress&utm_medium=frontendediting&utm_campaign=datatables "FrontEnd Data Table Editing Example")*
20
+ * [Table export and import from CSV, Excel, PDF, Google Sheets](https://supsystic.com/example/export-import-of-tables?utm_source=wordpress&utm_medium=export&utm_campaign=datatables "Export & Import of Tables")*
21
  * [Images, Links & Video support](https://supsystic.com/example/table-with-pictures-and-links-example?utm_source=wordpress&utm_medium=vedeo&utm_campaign=datatables "Images, Links & Video support")
22
+ * [WooCommerce Product Table](https://supsystic.com/plugins/woocommerce-product-table?utm_source=wordpress&utm_medium=description&utm_campaign=woocommercedatatable "WooCommerce Product Table")*
23
+ * [Database Source](https://supsystic.com/feature/database-source?utm_source=wordpress&utm_medium=featuresgoogle&utm_campaign=datatables "Database Source")*
24
+ *Pro version
25
 
26
  [youtube https://www.youtube.com/watch?v=RZ2I-aCiLZE]
27
 
210
  * All necessary settings to set the table appearance. Customize the **[Table design](https://supsystic.com/documentation/product-table-design?utm_source=wordpress&utm_medium=design&utm_campaign=woocommercedatatable "Table Design")** and make it more attractive for customers.
211
  * Works perfectly with hundreds of products and a huge amount of rows by virtue of using **[server-side processing technology](https://supsystic.com/example/tables-with-server-side-processing-example?utm_source=wordpress&utm_medium=serversideprocessing&utm_campaign=datatables "server-side processing").**
212
 
213
+
214
  Create custom order forms which increase your conversion rate!
215
 
216
  == Changelog ==
217
 
218
+ = 1.9.80 / 18.09.2019 =
219
+ * Fixed maps shortcodes
220
+ * Fixed admin paging
221
+ * Formulas fix
222
+ * Update Handsontable to 7.1.1 and switch formula parser to RuleJS
223
+ * Fixed edit link localize script
224
+ * Fixed translation bug with loco
225
+ * Fixed pdf|print exporter
226
+ * Fixed invisible cells
227
+ * Fix for woo attributes
228
+ * Minor issues fix
229
+
230
+ = 1.9.79 / 28.08.2019 =
231
+ * Fixed pasted formulas
232
+ * Fixed row sorting problem
233
+ * Add external database host for SQL tables
234
+ * Fix code for merged cells in header
235
+ * Fixed export with merged cells
236
+ * Fixed single hidden cell error
237
+ * Fix for jupiter theme
238
+ * Fix for new table popup
239
+
240
+ = 1.9.78 / 31.07.2019 =
241
+ * Add label into bar diagram
242
+ * Fix for Auto Column Hiding and merged cells
243
+ * Fix for undo column delete
244
+ * Rename Fixed Column Width, add option Fit to data
245
+ * Fix Export fonts to Pdf
246
+ * Added option Load by AJAX
247
+ * Update handsontable
248
+ * Add admin head row menu, some changes
249
+ * Change styles for tooltip
250
+ * Remove Resize Column error
251
+ * Remove comment after insert row
252
+ * Remove error when contact form not installed
253
+ * Add style to global search field
254
+ * Hide search form when active global and table search not active
255
+ * Added new features to Woo-addon
256
+ * Added Load by Ajax for diagrams
257
+ * Add sorting to context menu
258
+ * Add Edit Column Header option
259
+ * Fix importer
260
+ * Add editable file fields type
261
+ * Fix error after table create
262
+ * Fix formulas, edit editable file field functionality
263
+ * Fix problem after insert row/col, create conditions
264
+ * Fix problem with diagram after reload page
265
+ * Fix special-cell icon
266
+ * Edit upload frontend file functionals
267
+ * Fix recursive shortcodes in Data Source mode
268
+ * Fix for special chars in dropdown lists
269
+ * Update slimscroll version
270
+ * Fix tutorial
271
+ * Fix import/export btns in free
272
+ * Fix undo/redo
273
+ * Fix custom font family
274
+ * Fix formulas
275
+ * Fix frontend problem with ssp
276
+ * Fix editfile field in core js
277
+ * Fix notice after change cell format
278
+ * Fix diagram notice after creation
279
+ * Fix fixed columns preview problems
280
+ * Fix pagination and collapse problem
281
+ * Fix delete files after download
282
+ * Fix download editable file on front
283
+ * Fix allowed upload file types
284
+ * Fix frontendMethods
285
+ * Collapsed and merged fix, problem with dblclick on create diagram fixed
286
+ * Remove scroll from editable cell
287
+ * Fixed tooltip cells and paging
288
+ * Fixed autoindex with edit cols headers
289
+ * Fixed doubled data at cell after paging
290
+ * Fixed problem with merge and fixed header
291
+ * Fixed autoIndex with invisible cells
292
+ * Fixed pagination with merged cells export
293
+ * Detect responsive mode from 475px
294
+ * Fixed trigger resize poblem
295
+ * Replace other trigger resize code
296
+ * Fixed formats in value shortcode
297
+ * Fixes collapsible row
298
+ * Add enum and set types in data source as dropdown
299
+ * Fixed woo attibute filter
300
+ * Fixed preview after pdf export
301
+ * Fixed edit link and lightbox for unautorized
302
+ * Fixed video on print
303
+ * Fixed table link duplicates on page and in pdf/print export
304
+ * Fixed xls export from admin
305
+ * Add tooltip to variation chekbox
306
+ * Fixed update cell where column name have space
307
+ * Add checking for the presence of the woocommerce
308
+ * Disable table admin settings before render
309
+ * Fixed source editable fields
310
+ * Add ssp to dbsource
311
+ * Fixed after upload file row height, fixed merged with auto hidding, other
312
+ * Add search and sorting with datasource ssp
313
+ * Fixed woo ssp
314
+ * Fixed auto column hide and column search, auto hide and marge
315
+ * Fixed db source and autoindex
316
+ * Fixed column resize bug
317
+ * Fixed column search/ssp, editor link bug
318
+ * Fixed cyrillic bug in PHP 5.6
319
+
320
  = 1.9.77 / 11.06.2019 =
321
  * Small fix for Edit link on frontend
322
 
src/SupsysticTables/Core/Module.php CHANGED
@@ -16,7 +16,7 @@ class SupsysticTables_Core_Module extends SupsysticTables_Core_BaseModule
16
 
17
  private $frontendMethods = array(
18
  'ajax' => array(
19
- 'tables' => array('saveEditableFields', 'getPageRows'),
20
  'woocommerce' => array('productsAddToCart')
21
  ),
22
  'post' => array(
16
 
17
  private $frontendMethods = array(
18
  'ajax' => array(
19
+ 'tables' => array('saveEditableFields', 'getPageRows', 'saveEditableFieldsFile', 'deleteEditableFieldsFile'),
20
  'woocommerce' => array('productsAddToCart')
21
  ),
22
  'post' => array(
src/SupsysticTables/Core/assets/js/core.js CHANGED
@@ -181,11 +181,15 @@ var g_stbServerSideProcessingIsActive = false;
181
  });
182
  });
183
 
184
- vendor[appName].initTablesOnPage = (function() {
185
- this._initTablesOnPage();
186
  });
187
 
188
- vendor[appName]._initTablesOnPage = (function() {
 
 
 
 
189
  var self = this,
190
  firstTableId = '',
191
  firstTableViewId = '',
@@ -196,7 +200,8 @@ var g_stbServerSideProcessingIsActive = false;
196
  if($(window).width() <= 991) {
197
  self.setTableMobileWidth();
198
  }
199
- $('.supsystic-table').each(function () {
 
200
  self.initializeTable(this, self.showTable, function(table) {
201
  // This is used when table is hidden in tabs and can't calculate itself width to adjust on small screens
202
  if (table.is(':visible')) {
@@ -250,15 +255,73 @@ var g_stbServerSideProcessingIsActive = false;
250
  self.setCellAttributes(table.parents('.supsystic-tables-wrap:first').find('.DTFC_LeftWrapper, DTFC_RightWrapper, .dataTables_scrollHead, .dataTables_scrollFoot').find('th, td'));
251
  }
252
  if(typeof self.getTableInstanceById(table.data('id')).fnAdjustColumnSizing == 'function' ) {
 
253
  setTimeout(function(){
254
  table.trigger('responsive-resize.dt');
255
  self.getTableInstanceById(table.data('id')).fnAdjustColumnSizing(false);
256
  }, 350);
257
  }
 
258
  });
 
259
  });
260
  });
261
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
262
  vendor[appName]._getOriginalImageSizes = (function(img) {
263
  var tempImage = new Image(),
264
  width,
@@ -381,7 +444,7 @@ var g_stbServerSideProcessingIsActive = false;
381
  for(var j = colIndex + 1; j <= colIndex + colspan; j++) {
382
  var hiddenCell = table.find('tbody tr:nth-child(' + i + ') td:nth-child(' + j + ')');
383
 
384
- if(hiddenCell.data('hide')) {
385
  hiddenCell.html(cellData);
386
  hiddenCell.data('original-value', cellOrValue);
387
  hiddenCell.attr('data-original-value', cellOrValue);
@@ -405,6 +468,9 @@ var g_stbServerSideProcessingIsActive = false;
405
  if($table.data('search-value') && !config['searching']) {
406
  config['searching'] = true;
407
  }
 
 
 
408
  if (toeInArray('searching', features) != -1 && searchingSettings) {
409
  if (searchingSettings.minChars > 0 ||
410
  searchingSettings.resultOnly ||
@@ -490,7 +556,7 @@ var g_stbServerSideProcessingIsActive = false;
490
  if(cellItem.hasClass('invisibleCell')){
491
  cellClass = ' class="invisibleCell"'
492
  }
493
- searchRow += '<th ' + cellClass + cellStyle + '><input class="search-column" type="text" /></th>';
494
  }
495
  searchRow += '</tr>';
496
  if($table.find(tPosition).length == 0) {
@@ -575,7 +641,7 @@ var g_stbServerSideProcessingIsActive = false;
575
  labelStyles += '</style>';
576
  $table.append(labelStyles);
577
 
578
- $(window).on('resize', $table, function(event) {
579
  event.preventDefault();
580
  clearTimeout($table.data('resizeTimer'));
581
 
@@ -584,7 +650,7 @@ var g_stbServerSideProcessingIsActive = false;
584
  $table.css('width', '100%');
585
  var tableWidth = $table.width(),
586
  wrapperWidth = $table.closest('.supsystic-tables-wrap').width();
587
- if (tableWidth > wrapperWidth) {
588
  $table.addClass('oneColumn');
589
 
590
  if ($table.data('head') == 'on') {
@@ -597,7 +663,7 @@ var g_stbServerSideProcessingIsActive = false;
597
  $(this).css({'width': '','min-width': ''});
598
  });
599
  }
600
- }).trigger('resize');
601
  } else if (responsiveMode === 1) {
602
  // Responsive Mode: Automatic Column Hiding
603
  config.responsive = {
@@ -611,7 +677,8 @@ var g_stbServerSideProcessingIsActive = false;
611
  var $cell = $(api.cell(col.rowIndex, col.columnIndex).node()).clone(),
612
  markup = '<tr data-dt-row="'+col.rowIndex+'" data-dt-column="'+col.columnIndex+'">';
613
  if ($table.data('head') == 'on') {
614
- var $headerContent = $(api.table().header()).find('th').eq(col.columnIndex).html();
 
615
  markup += '<td>';
616
  if ($headerContent) {
617
  markup += $headerContent;
@@ -643,6 +710,21 @@ var g_stbServerSideProcessingIsActive = false;
643
  columns = typeof columns != 'undefined' ? columns : instance.api().columns();
644
  }
645
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
646
  if ($table.width() > $table.parent().width()) {
647
  $table.css('width', '100%');
648
  $table.css('max-width', '100%');
@@ -665,10 +747,16 @@ var g_stbServerSideProcessingIsActive = false;
665
  });
666
  }
667
  }
 
 
 
 
 
668
  });
669
  } else if (responsiveMode === 2) {
670
  // Responsive Mode: Horizontal Scroll
671
  config.scrollX = true;
 
672
  var firstRow = $table.find('tbody tr:first-child td');
673
  if(firstRow.length) {
674
  var cntCols = firstRow.length;
@@ -711,6 +799,8 @@ var g_stbServerSideProcessingIsActive = false;
711
  }
712
  }
713
 
 
 
714
  // Add translation
715
  var langData = typeof g_stbTblLangData != 'undefined' ? JSON.parse(g_stbTblLangData) : $table.data('translation'),
716
  translation = langData || {},
@@ -863,7 +953,18 @@ var g_stbServerSideProcessingIsActive = false;
863
  if(!g_stbServerSideProcessing && $table.data('merged')) {
864
  tableInstance.fnResetFakeRowspan();
865
  }
 
866
  });
 
 
 
 
 
 
 
 
 
 
867
  if(addInstance) {
868
  this.setTableInstance(tableInstance);
869
  }
@@ -934,11 +1035,15 @@ var g_stbServerSideProcessingIsActive = false;
934
  scrollTop: table.closest('.dataTables_wrapper').offset().top
935
  }, 100);
936
  }
 
 
 
937
  });
938
 
939
  // Frontend fields
940
  if (typeof(self.createEditableFields) == 'function') { // for compatibility with old pro versions
941
  var $editableFields = $tableWrap.find('.editable'),
 
942
  $selectableFields = $tableWrap.find('.selectable'),
943
  $tableId = $table.data('id'),
944
  useEditableFields = typeof(useEdit) != 'undefined' && typeof(useEdit[$tableId]) != 'undefined'
@@ -952,10 +1057,12 @@ var g_stbServerSideProcessingIsActive = false;
952
  self.setAllFields($table, $editableFields, $selectableFields);
953
  } else {
954
  self.createEditableFields($table, $editableFields);
 
955
  }
956
  $table.on('init.dt', function() {
957
  $table.on('responsive-resize.dt responsive-display.dt draw.dt', function() {
958
  $editableFields.off('click.sup'); // for compatibility with old pro versions
 
959
  self.updateAfterRedraw($table);
960
  });
961
  });
@@ -985,7 +1092,7 @@ var g_stbServerSideProcessingIsActive = false;
985
 
986
  if(responsiveMode === 2 || fixedHeader || fixedFooter) {
987
  // Responsive Mode: Horizontal Scroll
988
- $(window).on('resize', $table, function(event) {
989
  var tBody = $tableWrap.find('.dataTables_scrollBody'),
990
  tBodyTable = tBody.find('.supsystic-table');
991
 
@@ -1008,7 +1115,7 @@ var g_stbServerSideProcessingIsActive = false;
1008
  table.fnAdjustColumnSizing(false);
1009
  }, 350);
1010
  }
1011
- }).trigger('resize');
1012
 
1013
  // need resize twice to get better frontend view
1014
  var tBody = $tableWrap.find('.dataTables_scrollBody'),
@@ -1016,7 +1123,7 @@ var g_stbServerSideProcessingIsActive = false;
1016
 
1017
  if(tBodyTable.is(":visible")){
1018
  setTimeout(function() {
1019
- $(window).trigger('resize');
1020
  }, 200);
1021
  }
1022
  var $tHeadTable = $tableWrap.find('.dataTables_scrollHead .supsystic-table');
@@ -1106,11 +1213,18 @@ var g_stbServerSideProcessingIsActive = false;
1106
  }
1107
  self.getTableInstanceByViewId(viewId).fnFakeRowspan();
1108
  if(responsiveMode === 0 || responsiveMode === 2) {
1109
- $(window).trigger('resize');
1110
  }
1111
  }).trigger('draw.dt');
1112
  }
1113
 
 
 
 
 
 
 
 
1114
  function b64DecodeUnicode(str) {
1115
  return decodeURIComponent(Array.prototype.map.call(atob(str), function(c) {
1116
  return '%' + ('00' + c.charCodeAt(0).toString(16)).slice(-2);
@@ -1149,6 +1263,7 @@ var g_stbServerSideProcessingIsActive = false;
1149
  tableWrapper.find('td, th').on('click', this.applyMobileTableComments);
1150
  }
1151
  tableWrapper.find('td, th').each(this._contactFormBtnCellClb);
 
1152
  });
1153
 
1154
  vendor[appName].fixHeaderOfHiddenColumns = (function($table) {
@@ -1234,7 +1349,10 @@ var g_stbServerSideProcessingIsActive = false;
1234
  });
1235
 
1236
  vendor[appName].setColumnSearch = (function(table) {
1237
- var searchingSettings = table.data('searching-settings'),
 
 
 
1238
  inputs = table.parents('.dataTables_wrapper:first').find('.stbColumnsSearchWrapper .search-column');
1239
  if(inputs.length == 0) {
1240
  return;
@@ -1246,6 +1364,7 @@ var g_stbServerSideProcessingIsActive = false;
1246
  position = input.parents('th:first').index(),
1247
  value = this.value,
1248
  column = table.api().column(position);
 
1249
  if (column.search() !== value) {
1250
  column.search(value.replace(/;/g, "|"), true, false).draw();
1251
  setTimeout(function() {
@@ -1330,6 +1449,8 @@ var g_stbServerSideProcessingIsActive = false;
1330
  if((table.data('auto-index') != 'off' && $this.is(':first-child'))
1331
  || (table.data('responsive-mode') == 1 && table.hasClass('collapsed') && $this.hasClass('child'))
1332
  || $this.find('.search-column').length
 
 
1333
  ) {
1334
  // Break current .each iteration
1335
  return;
181
  });
182
  });
183
 
184
+ vendor[appName].initTablesOnPage = (function(id) {
185
+ this._initTablesOnPage(id);
186
  });
187
 
188
+ vendor[appName]._initTablesOnPage = (function(id) {
189
+ var tables = $(typeof id != 'undefined' ? '#supsystic-table-'+id+':not(.dataTable)' : '.supsystic-table');
190
+ if(tables.length == 0) return;
191
+ if(typeof this._initTablesOnPageWoo === 'function') this._initTablesOnPageWoo(id);
192
+
193
  var self = this,
194
  firstTableId = '',
195
  firstTableViewId = '',
200
  if($(window).width() <= 991) {
201
  self.setTableMobileWidth();
202
  }
203
+
204
+ tables.each(function () {
205
  self.initializeTable(this, self.showTable, function(table) {
206
  // This is used when table is hidden in tabs and can't calculate itself width to adjust on small screens
207
  if (table.is(':visible')) {
255
  self.setCellAttributes(table.parents('.supsystic-tables-wrap:first').find('.DTFC_LeftWrapper, DTFC_RightWrapper, .dataTables_scrollHead, .dataTables_scrollFoot').find('th, td'));
256
  }
257
  if(typeof self.getTableInstanceById(table.data('id')).fnAdjustColumnSizing == 'function' ) {
258
+ table.trigger('responsive-resize.dt');
259
  setTimeout(function(){
260
  table.trigger('responsive-resize.dt');
261
  self.getTableInstanceById(table.data('id')).fnAdjustColumnSizing(false);
262
  }, 350);
263
  }
264
+ self.initShortcodesInTable(table);
265
  });
266
+ //self.initShortcodesInTable($(this));
267
  });
268
  });
269
 
270
+ vendor[appName].initShortcodesInTable = (function(table) {
271
+ var tableViewId = table.data('view-id');
272
+ //google-maps-easy
273
+ if(typeof(gmpAllMapsInfo) !== 'undefined' && gmpAllMapsInfo && gmpAllMapsInfo.length) {
274
+ for(var i = 0; i < gmpAllMapsInfo.length; i++) {
275
+ var mapData = gmpAllMapsInfo[i],
276
+ map = $('#'+ mapData.view_html_id);
277
+ if(map.length && map.closest('#supsystic-table-'+tableViewId).length) {
278
+ var mapViewId = mapData.view_id;
279
+ setTimeout(function(mapData, mapViewId){
280
+ g_gmpAllMaps = $.grep(g_gmpAllMaps, function(value) {
281
+ if(value.getViewId() == mapViewId) {
282
+ if(mapData.heatmap && mapData.heatmap.coords) {
283
+ var coord = [],
284
+ oldCoord = mapData.heatmap.coords;
285
+ for(var c = 0; c < oldCoord.length; c++) {
286
+ var data = oldCoord[c];
287
+ coord.push(typeof data == 'object' ? data.join(',') : data);
288
+ }
289
+ mapData.heatmap.coords = coord;
290
+ }
291
+ if(value._mapParams.simple_slider_id) {
292
+ $('#'+value._mapParams.simple_slider_id).html(value._mapParams.original_slider_html);
293
+ }
294
+ }
295
+ return value.getViewId() != mapViewId;
296
+ });
297
+ gmpInitMapOnPage(mapData);
298
+ }, 50, mapData, mapViewId);
299
+ }
300
+ }
301
+ $(document).trigger('gmpAmiVarInited');
302
+ }
303
+ //ultimate-maps
304
+ if(typeof(umsAllMapsInfo) !== 'undefined' && umsAllMapsInfo && umsAllMapsInfo.length) {
305
+ for(var i = 0; i < umsAllMapsInfo.length; i++) {
306
+ var mapData = umsAllMapsInfo[i],
307
+ map = $('#'+ mapData.view_html_id);
308
+ if(map.length && map.closest('#supsystic-table-'+tableViewId).length) {
309
+ var mapViewId = mapData.view_id;
310
+ setTimeout(function(mapData, mapViewId){
311
+ g_umsAllMaps = $.grep(g_umsAllMaps, function(value) {
312
+ if(value.getViewId() == mapViewId) {
313
+ value._mapObj.remove();
314
+ }
315
+ return value.getViewId() != mapViewId;
316
+ });
317
+ umsInitMapOnPage(mapData);
318
+ }, 600, mapData, mapViewId);
319
+ }
320
+ }
321
+ $(document).trigger('umsAmiVarInited');
322
+ }
323
+ });
324
+
325
  vendor[appName]._getOriginalImageSizes = (function(img) {
326
  var tempImage = new Image(),
327
  width,
444
  for(var j = colIndex + 1; j <= colIndex + colspan; j++) {
445
  var hiddenCell = table.find('tbody tr:nth-child(' + i + ') td:nth-child(' + j + ')');
446
 
447
+ if(hiddenCell.data('hide') && !$table.data('merged')) {
448
  hiddenCell.html(cellData);
449
  hiddenCell.data('original-value', cellOrValue);
450
  hiddenCell.attr('data-original-value', cellOrValue);
468
  if($table.data('search-value') && !config['searching']) {
469
  config['searching'] = true;
470
  }
471
+ if(!config['searching'] && (typeof this.setTableAddSearching === 'function')) {
472
+ config['searching'] = this.setTableAddSearching($table);
473
+ }
474
  if (toeInArray('searching', features) != -1 && searchingSettings) {
475
  if (searchingSettings.minChars > 0 ||
476
  searchingSettings.resultOnly ||
556
  if(cellItem.hasClass('invisibleCell')){
557
  cellClass = ' class="invisibleCell"'
558
  }
559
+ searchRow += '<th ' + cellClass + cellStyle + '><input class="search-column" type="text" data-column-num="'+i+'"/></th>';
560
  }
561
  searchRow += '</tr>';
562
  if($table.find(tPosition).length == 0) {
641
  labelStyles += '</style>';
642
  $table.append(labelStyles);
643
 
644
+ $(window).on('load resize orientationchange', $table, function(event) {
645
  event.preventDefault();
646
  clearTimeout($table.data('resizeTimer'));
647
 
650
  $table.css('width', '100%');
651
  var tableWidth = $table.width(),
652
  wrapperWidth = $table.closest('.supsystic-tables-wrap').width();
653
+ if (tableWidth > wrapperWidth || $(window).width() <= 475) {
654
  $table.addClass('oneColumn');
655
 
656
  if ($table.data('head') == 'on') {
663
  $(this).css({'width': '','min-width': ''});
664
  });
665
  }
666
+ });
667
  } else if (responsiveMode === 1) {
668
  // Responsive Mode: Automatic Column Hiding
669
  config.responsive = {
677
  var $cell = $(api.cell(col.rowIndex, col.columnIndex).node()).clone(),
678
  markup = '<tr data-dt-row="'+col.rowIndex+'" data-dt-column="'+col.columnIndex+'">';
679
  if ($table.data('head') == 'on') {
680
+ var tableHeadTr = $(api.table().header()).find('tr:not(.stbColumnsSearchWrapper)').eq(0);
681
+ var $headerContent = tableHeadTr.find('th').eq(col.columnIndex).html();
682
  markup += '<td>';
683
  if ($headerContent) {
684
  markup += $headerContent;
710
  columns = typeof columns != 'undefined' ? columns : instance.api().columns();
711
  }
712
  }
713
+ var autoHiding = [],
714
+ searchColumn = $table.find('.stbColumnsSearchWrapper input.search-column');
715
+ for (var i = 0, len = columns.length; i < len; i++) {
716
+ autoHiding[i] = columns[i] ? 1 : 0;
717
+ }
718
+ $table.find('th input.search-column').each(function() {
719
+ var th = $(this).parents('th:first'),
720
+ i = th.index();
721
+ if(columns.length > i) {
722
+ th.css('display', columns[i] ? '' : 'none');
723
+ }
724
+ });
725
+ if(typeof columns[0] == 'boolean') {
726
+ $table.attr('data-auto-hiding', autoHiding.join());
727
+ }
728
  if ($table.width() > $table.parent().width()) {
729
  $table.css('width', '100%');
730
  $table.css('max-width', '100%');
747
  });
748
  }
749
  }
750
+ if ($table.data('merged')) {
751
+ // if has merged cells remove them, with autohidding they not working
752
+ $table.find('td[data-hide]').show();
753
+ $table.find('td[data-rowspan]').attr({'data-rowspan':1,rowspan:1,'data-colspan':1,colspan:1});
754
+ }
755
  });
756
  } else if (responsiveMode === 2) {
757
  // Responsive Mode: Horizontal Scroll
758
  config.scrollX = true;
759
+ config.bAutoWidth = false;
760
  var firstRow = $table.find('tbody tr:first-child td');
761
  if(firstRow.length) {
762
  var cntCols = firstRow.length;
799
  }
800
  }
801
 
802
+ $table.find('.invisibleCell').siblings('td').addClass('invisibleCell');
803
+
804
  // Add translation
805
  var langData = typeof g_stbTblLangData != 'undefined' ? JSON.parse(g_stbTblLangData) : $table.data('translation'),
806
  translation = langData || {},
953
  if(!g_stbServerSideProcessing && $table.data('merged')) {
954
  tableInstance.fnResetFakeRowspan();
955
  }
956
+ self.initShortcodesInTable($table);
957
  });
958
+ if(responsiveMode === 1) {
959
+ $table.on('responsive-resize.dt', function(event, api, columns) {
960
+ if(!g_stbServerSideProcessing && $table.data('merged')) {
961
+ tableInstance.fnResetFakeRowspan();
962
+ }
963
+ });
964
+ }
965
+ if (typeof $table.data('fixed-cols') !== 'undefined') {
966
+ tableInstance.api().fixedColumns().update();
967
+ }
968
  if(addInstance) {
969
  this.setTableInstance(tableInstance);
970
  }
1035
  scrollTop: table.closest('.dataTables_wrapper').offset().top
1036
  }, 100);
1037
  }
1038
+ if(typeof(self.setImgLightbox) == 'function'){
1039
+ self.setImgLightbox($table);
1040
+ }
1041
  });
1042
 
1043
  // Frontend fields
1044
  if (typeof(self.createEditableFields) == 'function') { // for compatibility with old pro versions
1045
  var $editableFields = $tableWrap.find('.editable'),
1046
+ $editfileFields = $tableWrap.find('.editfile'),
1047
  $selectableFields = $tableWrap.find('.selectable'),
1048
  $tableId = $table.data('id'),
1049
  useEditableFields = typeof(useEdit) != 'undefined' && typeof(useEdit[$tableId]) != 'undefined'
1057
  self.setAllFields($table, $editableFields, $selectableFields);
1058
  } else {
1059
  self.createEditableFields($table, $editableFields);
1060
+ self.createEditableFileFields($table, $editfileFields);
1061
  }
1062
  $table.on('init.dt', function() {
1063
  $table.on('responsive-resize.dt responsive-display.dt draw.dt', function() {
1064
  $editableFields.off('click.sup'); // for compatibility with old pro versions
1065
+ $editfileFields.off('click.sup');
1066
  self.updateAfterRedraw($table);
1067
  });
1068
  });
1092
 
1093
  if(responsiveMode === 2 || fixedHeader || fixedFooter) {
1094
  // Responsive Mode: Horizontal Scroll
1095
+ $(window).on('load resize orientationchange', $table, function(event) {
1096
  var tBody = $tableWrap.find('.dataTables_scrollBody'),
1097
  tBodyTable = tBody.find('.supsystic-table');
1098
 
1115
  table.fnAdjustColumnSizing(false);
1116
  }, 350);
1117
  }
1118
+ });
1119
 
1120
  // need resize twice to get better frontend view
1121
  var tBody = $tableWrap.find('.dataTables_scrollBody'),
1123
 
1124
  if(tBodyTable.is(":visible")){
1125
  setTimeout(function() {
1126
+ $(window).trigger('load');
1127
  }, 200);
1128
  }
1129
  var $tHeadTable = $tableWrap.find('.dataTables_scrollHead .supsystic-table');
1213
  }
1214
  self.getTableInstanceByViewId(viewId).fnFakeRowspan();
1215
  if(responsiveMode === 0 || responsiveMode === 2) {
1216
+ $(window).trigger('load');
1217
  }
1218
  }).trigger('draw.dt');
1219
  }
1220
 
1221
+ var tblEditLink = 'g_stbTblEditLink_'+ $table.data('id'),
1222
+ showTblEditLink = eval("typeof "+ tblEditLink) !== 'undefined' ? jQuery(window.atob(eval(tblEditLink))) : false;
1223
+
1224
+ if (showTblEditLink && jQuery(tableSelector).closest('.supsystic-tables-wrap').find('.tblEditLink').length === 0) {
1225
+ jQuery(tableSelector).closest('.supsystic-tables-wrap').append(showTblEditLink);
1226
+ }
1227
+
1228
  function b64DecodeUnicode(str) {
1229
  return decodeURIComponent(Array.prototype.map.call(atob(str), function(c) {
1230
  return '%' + ('00' + c.charCodeAt(0).toString(16)).slice(-2);
1263
  tableWrapper.find('td, th').on('click', this.applyMobileTableComments);
1264
  }
1265
  tableWrapper.find('td, th').each(this._contactFormBtnCellClb);
1266
+ this.initShortcodesInTable(table);
1267
  });
1268
 
1269
  vendor[appName].fixHeaderOfHiddenColumns = (function($table) {
1349
  });
1350
 
1351
  vendor[appName].setColumnSearch = (function(table) {
1352
+ if(typeof this.setTableAddFilters === 'function') this.setTableAddFilters(table);
1353
+
1354
+ var self = this,
1355
+ searchingSettings = table.data('searching-settings'),
1356
  inputs = table.parents('.dataTables_wrapper:first').find('.stbColumnsSearchWrapper .search-column');
1357
  if(inputs.length == 0) {
1358
  return;
1364
  position = input.parents('th:first').index(),
1365
  value = this.value,
1366
  column = table.api().column(position);
1367
+ if(typeof self.resetTableAddFilters === 'function') self.resetTableAddFilters(table);
1368
  if (column.search() !== value) {
1369
  column.search(value.replace(/;/g, "|"), true, false).draw();
1370
  setTimeout(function() {
1449
  if((table.data('auto-index') != 'off' && $this.is(':first-child'))
1450
  || (table.data('responsive-mode') == 1 && table.hasClass('collapsed') && $this.hasClass('child'))
1451
  || $this.find('.search-column').length
1452
+ || $this.hasClass('tooltipCell')
1453
+ || $this.data('hide')
1454
  ) {
1455
  // Break current .each iteration
1456
  return;
src/SupsysticTables/Core/assets/js/lib/dataTables.customExtensions.js CHANGED
@@ -97,12 +97,19 @@
97
  if(!mergedData || mergedData.length == 0 || displayRows.length == 0) return this;
98
 
99
  var rows = oSettings.aoData,
100
- rowNums = {};
 
 
 
 
 
101
  $.each(displayRows, function(index, rowNum) {
102
  var cells = rows[rowNum].anCells;
103
- rowNums[cells[0].getAttribute('data-y')] = rowNum;
104
  for(var i = 0; i < cells.length; i++) {
105
- $(cells[i]).css('display', '');
 
 
106
  cells[i].setAttribute('rowspan', 1);
107
  cells[i].setAttribute('colspan', 1);
108
  }
@@ -111,7 +118,7 @@
111
  var firstRow = Number(value.row) + 1,
112
  lastRow = firstRow + Number(value.rowspan) - 1,
113
  colspan = Number(value.colspan),
114
- firstCol = Number(value.col),
115
  lastCol = firstCol + colspan - 1,
116
  rowspan = 0;
117
  for(var r = firstRow; r <= lastRow; r++) {
@@ -120,7 +127,11 @@
120
  firstRow = r;
121
  }
122
  for(var c = firstCol + (firstRow == r ? 1 : 0); c <= lastCol; c++) {
123
- rows[rowNums[r]].anCells[c].style.display = 'none';
 
 
 
 
124
  }
125
  rowspan++;
126
  }
97
  if(!mergedData || mergedData.length == 0 || displayRows.length == 0) return this;
98
 
99
  var rows = oSettings.aoData,
100
+ table = $(oSettings.nTable),
101
+ autoHiding = table.attr('data-auto-hiding'),
102
+ rowNums = {},
103
+ first = table.attr('data-auto-index') == 'new' ? 1 : 0;
104
+ autoHiding = (typeof(autoHiding) != 'undefined' && autoHiding.length > 0) ? autoHiding.split(',').map(Number) : [];
105
+
106
  $.each(displayRows, function(index, rowNum) {
107
  var cells = rows[rowNum].anCells;
108
+ rowNums[cells[first].getAttribute('data-y')] = rowNum;
109
  for(var i = 0; i < cells.length; i++) {
110
+ if(cells[i].getAttribute('data-hide') == "true" && (autoHiding.length <= i || autoHiding[i] == 1)) {
111
+ $(cells[i]).css('display', '');
112
+ }
113
  cells[i].setAttribute('rowspan', 1);
114
  cells[i].setAttribute('colspan', 1);
115
  }
118
  var firstRow = Number(value.row) + 1,
119
  lastRow = firstRow + Number(value.rowspan) - 1,
120
  colspan = Number(value.colspan),
121
+ firstCol = Number(value.col) + first,
122
  lastCol = firstCol + colspan - 1,
123
  rowspan = 0;
124
  for(var r = firstRow; r <= lastRow; r++) {
127
  firstRow = r;
128
  }
129
  for(var c = firstCol + (firstRow == r ? 1 : 0); c <= lastCol; c++) {
130
+ var cell = rows[rowNums[r]].anCells[c];
131
+ cell.style.display = 'none';
132
+ if(autoHiding[c] === 0) {
133
+ colspan--;
134
+ }
135
  }
136
  rowspan++;
137
  }
src/SupsysticTables/Overview/Module.php CHANGED
@@ -46,6 +46,17 @@ class SupsysticTables_Overview_Module extends SupsysticTables_Core_BaseModule
46
  $hook
47
  )->setModuleSource($this, 'js/jquery.slimscroll.js')
48
  );
 
 
 
 
 
 
 
 
 
 
 
49
  }
50
 
51
  private function registerMenu()
46
  $hook
47
  )->setModuleSource($this, 'js/jquery.slimscroll.js')
48
  );
49
+ $environment = $this->getEnvironment();
50
+ $version = $environment->getConfig()->get('plugin_version');
51
+ $cachingAllowed = $environment->isProd();
52
+
53
+ $ui->add(
54
+ $ui->createStyle('jquery-ui-min')
55
+ ->setHookName($hook)
56
+ ->setLocalSource('css/jquery-ui.min.css')
57
+ ->setCachingAllowed($cachingAllowed)
58
+ ->setVersion($version)
59
+ );
60
  }
61
 
62
  private function registerMenu()
src/SupsysticTables/Overview/assets/js/jquery.slimscroll.js CHANGED
@@ -2,470 +2,473 @@
2
  * Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php)
3
  * and GPL (http://www.opensource.org/licenses/gpl-license.php) licenses.
4
  *
5
- * Version: 1.3.3
6
  *
7
  */
8
  (function($) {
9
 
10
- $.fn.extend({
11
- slimScroll: function(options) {
12
 
13
- var defaults = {
14
 
15
- // width in pixels of the visible scroll area
16
- width : 'auto',
17
 
18
- // height in pixels of the visible scroll area
19
- height : '250px',
20
 
21
- // width in pixels of the scrollbar and rail
22
- size : '7px',
23
 
24
- // scrollbar color, accepts any hex/color value
25
- color: '#000',
26
 
27
- // scrollbar position - left/right
28
- position : 'right',
29
 
30
- // distance in pixels between the side edge and the scrollbar
31
- distance : '1px',
32
 
33
- // default scroll position on load - top / bottom / $('selector')
34
- start : 'top',
35
 
36
- // sets scrollbar opacity
37
- opacity : .4,
38
 
39
- // enables always-on mode for the scrollbar
40
- alwaysVisible : false,
41
 
42
- // check if we should hide the scrollbar when user is hovering over
43
- disableFadeOut : false,
44
 
45
- // sets visibility of the rail
46
- railVisible : false,
47
 
48
- // sets rail color
49
- railColor : '#333',
50
 
51
- // sets rail opacity
52
- railOpacity : .2,
53
 
54
- // whether we should use jQuery UI Draggable to enable bar dragging
55
- railDraggable : true,
56
 
57
- // defautlt CSS class of the slimscroll rail
58
- railClass : 'slimScrollRail',
59
 
60
- // defautlt CSS class of the slimscroll bar
61
- barClass : 'slimScrollBar',
62
-
63
- // defautlt CSS class of the slimscroll wrapper
64
- wrapperClass : 'slimScrollDiv',
65
-
66
- // check if mousewheel should scroll the window if we reach top/bottom
67
- allowPageScroll : false,
68
-
69
- // scroll amount applied to each mouse wheel step
70
- wheelStep : 20,
71
-
72
- // scroll amount applied when user is using gestures
73
- touchScrollStep : 200,
74
-
75
- // sets border radius
76
- borderRadius: '7px',
77
-
78
- // sets border radius of the rail
79
- railBorderRadius : '7px'
80
- };
81
-
82
- var o = $.extend(defaults, options);
83
-
84
- // do it for every element that matches selector
85
- this.each(function(){
86
-
87
- var isOverPanel, isOverBar, isDragg, queueHide, touchDif,
88
- barHeight, percentScroll, lastScroll,
89
- divS = '<div></div>',
90
- minBarHeight = 30,
91
- releaseScroll = false;
92
-
93
- // used in event handlers and for better minification
94
- var me = $(this);
95
-
96
- // ensure we are not binding it again
97
- if (me.parent().hasClass(o.wrapperClass))
98
- {
99
- // start from last bar position
100
- var offset = me.scrollTop();
101
-
102
- // find bar and rail
103
- bar = me.parent().find('.' + o.barClass);
104
- rail = me.parent().find('.' + o.railClass);
105
-
106
- getBarHeight();
107
-
108
- // check if we should scroll existing instance
109
- if ($.isPlainObject(options))
110
- {
111
- // Pass height: auto to an existing slimscroll object to force a resize after contents have changed
112
- if ( 'height' in options && options.height == 'auto' ) {
113
- me.parent().css('height', 'auto');
114
- me.css('height', 'auto');
115
- var height = me.parent().parent().height();
116
- me.parent().css('height', height);
117
- me.css('height', height);
118
- }
119
-
120
- if ('scrollTo' in options)
121
- {
122
- // jump to a static point
123
- offset = parseInt(o.scrollTo);
124
- }
125
- else if ('scrollBy' in options)
126
- {
127
- // jump by value pixels
128
- offset += parseInt(o.scrollBy);
129
- }
130
- else if ('destroy' in options)
131
- {
132
- // remove slimscroll elements
133
- bar.remove();
134
- rail.remove();
135
- me.unwrap();
136
- return;
137
- }
138
-
139
- // scroll content by the given offset
140
- scrollContent(offset, false, true);
141
- }
142
-
143
- return;
144
- }
145
- else if ($.isPlainObject(options))
146
- {
147
- if ('destroy' in options)
148
- {
149
- return;
150
- }
151
- }
152
-
153
- // optionally set height to the parent's height
154
- o.height = (o.height == 'auto') ? me.parent().height() : o.height;
155
-
156
- // wrap content
157
- var wrapper = $(divS)
158
- .addClass(o.wrapperClass)
159
- .css({
160
- position: 'relative',
161
- overflow: 'hidden',
162
- width: o.width,
163
- height: o.height
164
- });
165
-
166
- // update style for the div
167
- me.css({
168
- overflow: 'hidden',
169
- width: o.width,
170
- height: o.height
171
- });
172
-
173
- // create scrollbar rail
174
- var rail = $(divS)
175
- .addClass(o.railClass)
176
- .css({
177
- width: o.size,
178
- height: '100%',
179
- position: 'absolute',
180
- top: 0,
181
- display: (o.alwaysVisible && o.railVisible) ? 'block' : 'none',
182
- 'border-radius': o.railBorderRadius,
183
- background: o.railColor,
184
- opacity: o.railOpacity,
185
- zIndex: 90
186
- });
187
-
188
- // create scrollbar
189
- var bar = $(divS)
190
- .addClass(o.barClass)
191
- .css({
192
- background: o.color,
193
- width: o.size,
194
- position: 'absolute',
195
- top: 0,
196
- opacity: o.opacity,
197
- display: o.alwaysVisible ? 'block' : 'none',
198
- 'border-radius' : o.borderRadius,
199
- BorderRadius: o.borderRadius,
200
- MozBorderRadius: o.borderRadius,
201
- WebkitBorderRadius: o.borderRadius,
202
- zIndex: 99
203
- });
204
-
205
- // set position
206
- var posCss = (o.position == 'right') ? { right: o.distance } : { left: o.distance };
207
- rail.css(posCss);
208
- bar.css(posCss);
209
-
210
- // wrap it
211
- me.wrap(wrapper);
212
-
213
- // append to parent div
214
- me.parent().append(bar);
215
- me.parent().append(rail);
216
-
217
- // make it draggable and no longer dependent on the jqueryUI
218
- if (o.railDraggable){
219
- bar.bind("mousedown", function(e) {
220
- var $doc = $(document);
221
- isDragg = true;
222
- t = parseFloat(bar.css('top'));
223
- pageY = e.pageY;
224
-
225
- $doc.bind("mousemove.slimscroll", function(e){
226
- currTop = t + e.pageY - pageY;
227
- bar.css('top', currTop);
228
- scrollContent(0, bar.position().top, false);// scroll content
229
- });
230
-
231
- $doc.bind("mouseup.slimscroll", function(e) {
232
- isDragg = false;hideBar();
233
- $doc.unbind('.slimscroll');
234
- });
235
- return false;
236
- }).bind("selectstart.slimscroll", function(e){
237
- e.stopPropagation();
238
- e.preventDefault();
239
- return false;
240
- });
241
- }
242
-
243
- // on rail over
244
- rail.hover(function(){
245
- showBar();
246
- }, function(){
247
- hideBar();
248
- });
249
-
250
- // on bar over
251
- bar.hover(function(){
252
- isOverBar = true;
253
- }, function(){
254
- isOverBar = false;
255
- });
256
-
257
- // show on parent mouseover
258
- me.hover(function(){
259
- isOverPanel = true;
260
- showBar();
261
- hideBar();
262
- }, function(){
263
- isOverPanel = false;
264
- hideBar();
265
- });
266
-
267
- // support for mobile
268
- me.bind('touchstart', function(e,b){
269
- if (e.originalEvent.touches.length)
270
- {
271
- // record where touch started
272
- touchDif = e.originalEvent.touches[0].pageY;
273
- }
274
- });
275
-
276
- me.bind('touchmove', function(e){
277
- // prevent scrolling the page if necessary
278
- if(!releaseScroll)
279
- {
280
- e.originalEvent.preventDefault();
281
- }
282
- if (e.originalEvent.touches.length)
283
- {
284
- // see how far user swiped
285
- var diff = (touchDif - e.originalEvent.touches[0].pageY) / o.touchScrollStep;
286
- // scroll content
287
- scrollContent(diff, true);
288
- touchDif = e.originalEvent.touches[0].pageY;
289
- }
290
- });
291
-
292
- // set up initial height
293
- getBarHeight();
294
-
295
- // check start position
296
- if (o.start === 'bottom')
297
- {
298
- // scroll content to bottom
299
- bar.css({ top: me.outerHeight() - bar.outerHeight() });
300
- scrollContent(0, true);
301
- }
302
- else if (o.start !== 'top')
303
- {
304
- // assume jQuery selector
305
- scrollContent($(o.start).position().top, null, true);
306
-
307
- // make sure bar stays hidden
308
- if (!o.alwaysVisible) { bar.hide(); }
309
- }
310
-
311
- // attach scroll events
312
- attachWheel();
313
-
314
- function _onWheel(e)
315
- {
316
- // use mouse wheel only when mouse is over
317
- if (!isOverPanel) { return; }
318
-
319
- var e = e || window.event;
320
-
321
- var delta = 0;
322
- if (e.wheelDelta) { delta = -e.wheelDelta/120; }
323
- if (e.detail) { delta = e.detail / 3; }
324
-
325
- var target = e.target || e.srcTarget || e.srcElement;
326
- if ($(target).closest('.' + o.wrapperClass).is(me.parent())) {
327
- // scroll content
328
- scrollContent(delta, true);
329
- }
330
-
331
- // stop window scroll
332
- if (e.preventDefault && !releaseScroll) { e.preventDefault(); }
333
- if (!releaseScroll) { e.returnValue = false; }
334
- }
335
-
336
- function scrollContent(y, isWheel, isJump)
337
- {
338
- releaseScroll = false;
339
- var delta = y;
340
- var maxTop = me.outerHeight() - bar.outerHeight();
341
-
342
- if (isWheel)
343
- {
344
- // move bar with mouse wheel
345
- delta = parseInt(bar.css('top')) + y * parseInt(o.wheelStep) / 100 * bar.outerHeight();
346
-
347
- // move bar, make sure it doesn't go out
348
- delta = Math.min(Math.max(delta, 0), maxTop);
349
-
350
- // if scrolling down, make sure a fractional change to the
351
- // scroll position isn't rounded away when the scrollbar's CSS is set
352
- // this flooring of delta would happened automatically when
353
- // bar.css is set below, but we floor here for clarity
354
- delta = (y > 0) ? Math.ceil(delta) : Math.floor(delta);
355
-
356
- // scroll the scrollbar
357
- bar.css({ top: delta + 'px' });
358
- }
359
-
360
- // calculate actual scroll amount
361
- percentScroll = parseInt(bar.css('top')) / (me.outerHeight() - bar.outerHeight());
362
- delta = percentScroll * (me[0].scrollHeight - me.outerHeight());
363
-
364
- if (isJump)
365
- {
366
- delta = y;
367
- var offsetTop = delta / me[0].scrollHeight * me.outerHeight();
368
- offsetTop = Math.min(Math.max(offsetTop, 0), maxTop);
369
- bar.css({ top: offsetTop + 'px' });
370
- }
371
-
372
- // scroll content
373
- me.scrollTop(delta);
374
-
375
- // fire scrolling event
376
- me.trigger('slimscrolling', ~~delta);
377
-
378
- // ensure bar is visible
379
- showBar();
380
-
381
- // trigger hide when scroll is stopped
382
- hideBar();
383
- }
384
-
385
- function attachWheel()
386
- {
387
- if (window.addEventListener)
388
- {
389
- this.addEventListener('DOMMouseScroll', _onWheel, false );
390
- this.addEventListener('mousewheel', _onWheel, false );
391
- }
392
- else
393
- {
394
- document.attachEvent("onmousewheel", _onWheel)
395
- }
396
- }
397
-
398
- function getBarHeight()
399
- {
400
- // calculate scrollbar height and make sure it is not too small
401
- barHeight = Math.max((me.outerHeight() / me[0].scrollHeight) * me.outerHeight(), minBarHeight);
402
- bar.css({ height: barHeight + 'px' });
403
-
404
- // hide scrollbar if content is not long enough
405
- var display = barHeight == me.outerHeight() ? 'none' : 'block';
406
- bar.css({ display: display });
407
- rail.css({ display: display });
408
- }
409
-
410
- function showBar()
411
- {
412
- // recalculate bar height
413
- getBarHeight();
414
- clearTimeout(queueHide);
415
-
416
- // when bar reached top or bottom
417
- if (percentScroll == ~~percentScroll)
418
- {
419
- //release wheel
420
- releaseScroll = o.allowPageScroll;
421
-
422
- // publish approporiate event
423
- if (lastScroll != percentScroll)
424
- {
425
- var msg = (~~percentScroll == 0) ? 'top' : 'bottom';
426
- me.trigger('slimscroll', msg);
427
- }
428
- }
429
- else
430
- {
431
- releaseScroll = false;
432
- }
433
- lastScroll = percentScroll;
434
-
435
- // show only when required
436
- if(barHeight >= me.outerHeight()) {
437
- //allow window scroll
438
- releaseScroll = true;
439
- return;
440
- }
441
- bar.stop(true,true).fadeIn('fast');
442
- if (o.railVisible) { rail.stop(true,true).fadeIn('fast'); }
443
- }
444
-
445
- function hideBar()
446
- {
447
- // only hide when options allow it
448
- if (!o.alwaysVisible)
449
- {
450
- queueHide = setTimeout(function(){
451
- if (!(o.disableFadeOut && isOverPanel) && !isOverBar && !isDragg)
452
- {
453
- bar.fadeOut('slow');
454
- rail.fadeOut('slow');
455
- }
456
- }, 1000);
457
- }
458
- }
459
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
460
  });
461
 
462
- // maintain chainability
463
- return this;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
464
  }
465
- });
466
 
467
- $.fn.extend({
468
- slimscroll: $.fn.slimScroll
469
- });
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
470
 
471
- })(jQuery);
2
  * Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php)
3
  * and GPL (http://www.opensource.org/licenses/gpl-license.php) licenses.
4
  *
5
+ * Version: 1.3.8
6
  *
7
  */
8
  (function($) {
9
 
10
+ $.fn.extend({
11
+ slimScroll: function(options) {
12
 
13
+ var defaults = {
14
 
15
+ // width in pixels of the visible scroll area
16
+ width : 'auto',
17
 
18
+ // height in pixels of the visible scroll area
19
+ height : '250px',
20
 
21
+ // width in pixels of the scrollbar and rail
22
+ size : '7px',
23
 
24
+ // scrollbar color, accepts any hex/color value
25
+ color: '#000',
26
 
27
+ // scrollbar position - left/right
28
+ position : 'right',
29
 
30
+ // distance in pixels between the side edge and the scrollbar
31
+ distance : '1px',
32
 
33
+ // default scroll position on load - top / bottom / $('selector')
34
+ start : 'top',
35
 
36
+ // sets scrollbar opacity
37
+ opacity : .4,
38
 
39
+ // enables always-on mode for the scrollbar
40
+ alwaysVisible : false,
41
 
42
+ // check if we should hide the scrollbar when user is hovering over
43
+ disableFadeOut : false,
44
 
45
+ // sets visibility of the rail
46
+ railVisible : false,
47
 
48
+ // sets rail color
49
+ railColor : '#333',
50
 
51
+ // sets rail opacity
52
+ railOpacity : .2,
53
 
54
+ // whether we should use jQuery UI Draggable to enable bar dragging
55
+ railDraggable : true,
56
 
57
+ // defautlt CSS class of the slimscroll rail
58
+ railClass : 'slimScrollRail',
59
 
60
+ // defautlt CSS class of the slimscroll bar
61
+ barClass : 'slimScrollBar',
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
62
 
63
+ // defautlt CSS class of the slimscroll wrapper
64
+ wrapperClass : 'slimScrollDiv',
65
+
66
+ // check if mousewheel should scroll the window if we reach top/bottom
67
+ allowPageScroll : false,
68
+
69
+ // scroll amount applied to each mouse wheel step
70
+ wheelStep : 20,
71
+
72
+ // scroll amount applied when user is using gestures
73
+ touchScrollStep : 200,
74
+
75
+ // sets border radius
76
+ borderRadius: '7px',
77
+
78
+ // sets border radius of the rail
79
+ railBorderRadius : '7px'
80
+ };
81
+
82
+ var o = $.extend(defaults, options);
83
+
84
+ // do it for every element that matches selector
85
+ this.each(function(){
86
+
87
+ var isOverPanel, isOverBar, isDragg, queueHide, touchDif,
88
+ barHeight, percentScroll, lastScroll,
89
+ divS = '<div></div>',
90
+ minBarHeight = 30,
91
+ releaseScroll = false;
92
+
93
+ // used in event handlers and for better minification
94
+ var me = $(this);
95
+
96
+ // ensure we are not binding it again
97
+ if (me.parent().hasClass(o.wrapperClass))
98
+ {
99
+ // start from last bar position
100
+ var offset = me.scrollTop();
101
+
102
+ // find bar and rail
103
+ bar = me.siblings('.' + o.barClass);
104
+ rail = me.siblings('.' + o.railClass);
105
+
106
+ getBarHeight();
107
+
108
+ // check if we should scroll existing instance
109
+ if ($.isPlainObject(options))
110
+ {
111
+ // Pass height: auto to an existing slimscroll object to force a resize after contents have changed
112
+ if ( 'height' in options && options.height == 'auto' ) {
113
+ me.parent().css('height', 'auto');
114
+ me.css('height', 'auto');
115
+ var height = me.parent().parent().height();
116
+ me.parent().css('height', height);
117
+ me.css('height', height);
118
+ } else if ('height' in options) {
119
+ var h = options.height;
120
+ me.parent().css('height', h);
121
+ me.css('height', h);
122
+ }
123
+
124
+ if ('scrollTo' in options)
125
+ {
126
+ // jump to a static point
127
+ offset = parseInt(o.scrollTo);
128
+ }
129
+ else if ('scrollBy' in options)
130
+ {
131
+ // jump by value pixels
132
+ offset += parseInt(o.scrollBy);
133
+ }
134
+ else if ('destroy' in options)
135
+ {
136
+ // remove slimscroll elements
137
+ bar.remove();
138
+ rail.remove();
139
+ me.unwrap();
140
+ return;
141
+ }
142
+
143
+ // scroll content by the given offset
144
+ scrollContent(offset, false, true);
145
+ }
146
+
147
+ return;
148
+ }
149
+ else if ($.isPlainObject(options))
150
+ {
151
+ if ('destroy' in options)
152
+ {
153
+ return;
154
+ }
155
+ }
156
+
157
+ // optionally set height to the parent's height
158
+ o.height = (o.height == 'auto') ? me.parent().height() : o.height;
159
+
160
+ // wrap content
161
+ var wrapper = $(divS)
162
+ .addClass(o.wrapperClass)
163
+ .css({
164
+ position: 'relative',
165
+ overflow: 'hidden',
166
+ width: o.width,
167
+ height: o.height
168
+ });
169
+
170
+ // update style for the div
171
+ me.css({
172
+ overflow: 'hidden',
173
+ width: o.width,
174
+ height: o.height
175
+ });
176
+
177
+ // create scrollbar rail
178
+ var rail = $(divS)
179
+ .addClass(o.railClass)
180
+ .css({
181
+ width: o.size,
182
+ height: '100%',
183
+ position: 'absolute',
184
+ top: 0,
185
+ display: (o.alwaysVisible && o.railVisible) ? 'block' : 'none',
186
+ 'border-radius': o.railBorderRadius,
187
+ background: o.railColor,
188
+ opacity: o.railOpacity,
189
+ zIndex: 90
190
+ });
191
+
192
+ // create scrollbar
193
+ var bar = $(divS)
194
+ .addClass(o.barClass)
195
+ .css({
196
+ background: o.color,
197
+ width: o.size,
198
+ position: 'absolute',
199
+ top: 0,
200
+ opacity: o.opacity,
201
+ display: o.alwaysVisible ? 'block' : 'none',
202
+ 'border-radius' : o.borderRadius,
203
+ BorderRadius: o.borderRadius,
204
+ MozBorderRadius: o.borderRadius,
205
+ WebkitBorderRadius: o.borderRadius,
206
+ zIndex: 99
207
+ });
208
+
209
+ // set position
210
+ var posCss = (o.position == 'right') ? { right: o.distance } : { left: o.distance };
211
+ rail.css(posCss);
212
+ bar.css(posCss);
213
+
214
+ // wrap it
215
+ me.wrap(wrapper);
216
+
217
+ // append to parent div
218
+ me.parent().append(bar);
219
+ me.parent().append(rail);
220
+
221
+ // make it draggable and no longer dependent on the jqueryUI
222
+ if (o.railDraggable){
223
+ bar.bind("mousedown", function(e) {
224
+ var $doc = $(document);
225
+ isDragg = true;
226
+ t = parseFloat(bar.css('top'));
227
+ pageY = e.pageY;
228
+
229
+ $doc.bind("mousemove.slimscroll", function(e){
230
+ currTop = t + e.pageY - pageY;
231
+ bar.css('top', currTop);
232
+ scrollContent(0, bar.position().top, false);// scroll content
233
  });
234
 
235
+ $doc.bind("mouseup.slimscroll", function(e) {
236
+ isDragg = false;hideBar();
237
+ $doc.unbind('.slimscroll');
238
+ });
239
+ return false;
240
+ }).bind("selectstart.slimscroll", function(e){
241
+ e.stopPropagation();
242
+ e.preventDefault();
243
+ return false;
244
+ });
245
+ }
246
+
247
+ // on rail over
248
+ rail.hover(function(){
249
+ showBar();
250
+ }, function(){
251
+ hideBar();
252
+ });
253
+
254
+ // on bar over
255
+ bar.hover(function(){
256
+ isOverBar = true;
257
+ }, function(){
258
+ isOverBar = false;
259
+ });
260
+
261
+ // show on parent mouseover
262
+ me.hover(function(){
263
+ isOverPanel = true;
264
+ showBar();
265
+ hideBar();
266
+ }, function(){
267
+ isOverPanel = false;
268
+ hideBar();
269
+ });
270
+
271
+ // support for mobile
272
+ me.bind('touchstart', function(e,b){
273
+ if (e.originalEvent.touches.length)
274
+ {
275
+ // record where touch started
276
+ touchDif = e.originalEvent.touches[0].pageY;
277
+ }
278
+ });
279
+
280
+ me.bind('touchmove', function(e){
281
+ // prevent scrolling the page if necessary
282
+ if(!releaseScroll)
283
+ {
284
+ e.originalEvent.preventDefault();
285
+ }
286
+ if (e.originalEvent.touches.length)
287
+ {
288
+ // see how far user swiped
289
+ var diff = (touchDif - e.originalEvent.touches[0].pageY) / o.touchScrollStep;
290
+ // scroll content
291
+ scrollContent(diff, true);
292
+ touchDif = e.originalEvent.touches[0].pageY;
293
+ }
294
+ });
295
+
296
+ // set up initial height
297
+ getBarHeight();
298
+
299
+ // check start position
300
+ if (o.start === 'bottom')
301
+ {
302
+ // scroll content to bottom
303
+ bar.css({ top: me.outerHeight() - bar.outerHeight() });
304
+ scrollContent(0, true);
305
+ }
306
+ else if (o.start !== 'top')
307
+ {
308
+ // assume jQuery selector
309
+ scrollContent($(o.start).position().top, null, true);
310
+
311
+ // make sure bar stays hidden
312
+ if (!o.alwaysVisible) { bar.hide(); }
313
  }
 
314
 
315
+ // attach scroll events
316
+ attachWheel(this);
317
+
318
+ function _onWheel(e)
319
+ {
320
+ // use mouse wheel only when mouse is over
321
+ if (!isOverPanel) { return; }
322
+
323
+ var e = e || window.event;
324
+
325
+ var delta = 0;
326
+ if (e.wheelDelta) { delta = -e.wheelDelta/120; }
327
+ if (e.detail) { delta = e.detail / 3; }
328
+
329
+ var target = e.target || e.srcTarget || e.srcElement;
330
+ if ($(target).closest('.' + o.wrapperClass).is(me.parent())) {
331
+ // scroll content
332
+ scrollContent(delta, true);
333
+ }
334
+
335
+ // stop window scroll
336
+ if (e.preventDefault && !releaseScroll) { e.preventDefault(); }
337
+ if (!releaseScroll) { e.returnValue = false; }
338
+ }
339
+
340
+ function scrollContent(y, isWheel, isJump)
341
+ {
342
+ releaseScroll = false;
343
+ var delta = y;
344
+ var maxTop = me.outerHeight() - bar.outerHeight();
345
+
346
+ if (isWheel)
347
+ {
348
+ // move bar with mouse wheel
349
+ delta = parseInt(bar.css('top')) + y * parseInt(o.wheelStep) / 100 * bar.outerHeight();
350
+
351
+ // move bar, make sure it doesn't go out
352
+ delta = Math.min(Math.max(delta, 0), maxTop);
353
+
354
+ // if scrolling down, make sure a fractional change to the
355
+ // scroll position isn't rounded away when the scrollbar's CSS is set
356
+ // this flooring of delta would happened automatically when
357
+ // bar.css is set below, but we floor here for clarity
358
+ delta = (y > 0) ? Math.ceil(delta) : Math.floor(delta);
359
+
360
+ // scroll the scrollbar
361
+ bar.css({ top: delta + 'px' });
362
+ }
363
+
364
+ // calculate actual scroll amount
365
+ percentScroll = parseInt(bar.css('top')) / (me.outerHeight() - bar.outerHeight());
366
+ delta = percentScroll * (me[0].scrollHeight - me.outerHeight());
367
+
368
+ if (isJump)
369
+ {
370
+ delta = y;
371
+ var offsetTop = delta / me[0].scrollHeight * me.outerHeight();
372
+ offsetTop = Math.min(Math.max(offsetTop, 0), maxTop);
373
+ bar.css({ top: offsetTop + 'px' });
374
+ }
375
+
376
+ // scroll content
377
+ me.scrollTop(delta);
378
+
379
+ // fire scrolling event
380
+ me.trigger('slimscrolling', ~~delta);
381
+
382
+ // ensure bar is visible
383
+ showBar();
384
+
385
+ // trigger hide when scroll is stopped
386
+ hideBar();
387
+ }
388
+
389
+ function attachWheel(target)
390
+ {
391
+ if (window.addEventListener)
392
+ {
393
+ target.addEventListener('DOMMouseScroll', _onWheel, false );
394
+ target.addEventListener('mousewheel', _onWheel, false );
395
+ }
396
+ else
397
+ {
398
+ document.attachEvent("onmousewheel", _onWheel)
399
+ }
400
+ }
401
+
402
+ function getBarHeight()
403
+ {
404
+ // calculate scrollbar height and make sure it is not too small
405
+ barHeight = Math.max((me.outerHeight() / me[0].scrollHeight) * me.outerHeight(), minBarHeight);
406
+ bar.css({ height: barHeight + 'px' });
407
+
408
+ // hide scrollbar if content is not long enough
409
+ var display = barHeight == me.outerHeight() ? 'none' : 'block';
410
+ bar.css({ display: display });
411
+ }
412
+
413
+ function showBar()
414
+ {
415
+ // recalculate bar height
416
+ getBarHeight();
417
+ clearTimeout(queueHide);
418
+
419
+ // when bar reached top or bottom
420
+ if (percentScroll == ~~percentScroll)
421
+ {
422
+ //release wheel
423
+ releaseScroll = o.allowPageScroll;
424
+
425
+ // publish approporiate event
426
+ if (lastScroll != percentScroll)
427
+ {
428
+ var msg = (~~percentScroll == 0) ? 'top' : 'bottom';
429
+ me.trigger('slimscroll', msg);
430
+ }
431
+ }
432
+ else
433
+ {
434
+ releaseScroll = false;
435
+ }
436
+ lastScroll = percentScroll;
437
+
438
+ // show only when required
439
+ if(barHeight >= me.outerHeight()) {
440
+ //allow window scroll
441
+ releaseScroll = true;
442
+ return;
443
+ }
444
+ bar.stop(true,true).fadeIn('fast');
445
+ if (o.railVisible) { rail.stop(true,true).fadeIn('fast'); }
446
+ }
447
+
448
+ function hideBar()
449
+ {
450
+ // only hide when options allow it
451
+ if (!o.alwaysVisible)
452
+ {
453
+ queueHide = setTimeout(function(){
454
+ if (!(o.disableFadeOut && isOverPanel) && !isOverBar && !isDragg)
455
+ {
456
+ bar.fadeOut('slow');
457
+ rail.fadeOut('slow');
458
+ }
459
+ }, 1000);
460
+ }
461
+ }
462
+
463
+ });
464
+
465
+ // maintain chainability
466
+ return this;
467
+ }
468
+ });
469
+
470
+ $.fn.extend({
471
+ slimscroll: $.fn.slimScroll
472
+ });
473
 
474
+ })(jQuery);
src/SupsysticTables/Promo/Module.php CHANGED
@@ -56,6 +56,7 @@ class SupsysticTables_Promo_Module extends SupsysticTables_Core_BaseModule
56
  array('wp-pointer')
57
  );
58
  wp_enqueue_style('wp-pointer');
 
59
 
60
  $data = array(
61
  'next' => $this->translate('Next'),
56
  array('wp-pointer')
57
  );
58
  wp_enqueue_style('wp-pointer');
59
+ wp_enqueue_style('supsystic-tables-pointers', $modulePath . '/assets/css/tutorial.css');
60
 
61
  $data = array(
62
  'next' => $this->translate('Next'),
src/SupsysticTables/Promo/assets/css/tutorial.css ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ .wp-pointer-buttons{
2
+ display: -ms-flexbox;
3
+ display: flex;
4
+ -ms-flex-pack: justify;
5
+ justify-content: space-between;
6
+ -ms-flex-align: center;
7
+ align-items: center;
8
+ }
9
+ .wp-pointer-buttons.reversed{
10
+ -ms-flex-direction:row-reverse;
11
+ flex-direction:row-reverse;
12
+ }
13
+ .wp-pointer-buttons a{
14
+ float: none;
15
+ }
src/SupsysticTables/Promo/assets/js/tutorial.js CHANGED
@@ -63,9 +63,7 @@
63
  sessionStorage.setItem('supsystic-tables-tutorial-step', pointers.stepNumber);
64
 
65
  if (pointerData.nextURL && window.location.href !== pointerData.nextURL) {
66
- window.location.replace(pointerData.nextURL).done(function() {
67
- pointers.setPointer();
68
- });
69
  } else {
70
  pointers.setPointer();
71
  }
@@ -179,6 +177,11 @@
179
 
180
  $(document).ready(function() {
181
  pointers.init();
 
 
 
 
 
182
  });
183
 
184
  })(jQuery, DataTablesPromoPointers);
63
  sessionStorage.setItem('supsystic-tables-tutorial-step', pointers.stepNumber);
64
 
65
  if (pointerData.nextURL && window.location.href !== pointerData.nextURL) {
66
+ window.location.replace(pointerData.nextURL);
 
 
67
  } else {
68
  pointers.setPointer();
69
  }
177
 
178
  $(document).ready(function() {
179
  pointers.init();
180
+ if ($('[class*="supsystic-tables-tutorial-step"] .wp-pointer-buttons').find('a').length > 1) {
181
+ $('[class*="supsystic-tables-tutorial-step"] .wp-pointer-buttons').addClass('reversed');
182
+ } else {
183
+ $('[class*="supsystic-tables-tutorial-step"] .wp-pointer-buttons').removeClass('reversed');
184
+ }
185
  });
186
 
187
  })(jQuery, DataTablesPromoPointers);
src/SupsysticTables/Promo/views/pluginDeactivation.twig CHANGED
@@ -1,70 +1,70 @@
1
- <style type="text/css">
2
- .dtsDeactivateDescShell {
3
- display: none;
4
- margin-left: 25px;
5
- margin-top: 5px;
6
- }
7
- .dtsDeactivateReasonShell {
8
- display: block;
9
- margin-bottom: 10px;
10
- }
11
- #dtsDeactivateWnd input[type="text"],
12
- #dtsDeactivateWnd textarea {
13
- width: 100%;
14
- }
15
- #dtsDeactivateWnd h4 {
16
- line-height: 1.53em;
17
- }
18
- #dtsDeactivateWnd + .ui-dialog-buttonpane .ui-dialog-buttonset {
19
- float: none;
20
- }
21
- .dtsDeactivateSkipDataBtn {
22
- float: right;
23
- margin-top: 7px;
24
- text-decoration: none;
25
- color: #777 !important;
26
- }
27
-
28
- .dtsDeactivateReasonShell input[type="radio"]:checked::before {
29
- width: 6px !important;
30
- }
31
- .ui-widget-content .dtsDeactivateReasonShell input[type="radio"] {
32
- width: 16px;
33
- height: 16px;
34
- }
35
- </style>
36
- <div id="dtsDeactivateWnd" style="display: none;" title="{{ environment.translate('Your Feedback') }}">
37
- <h4>{{ environment.translate('If you have a moment, please share why you are deactivating %s')|format(pluginName) }}</h4>
38
- <form id="dtsDeactivateForm">
39
- <label class="dtsDeactivateReasonShell">
40
- <input type="radio" name="deactivate_reason" value="not_working" />
41
- {{ environment.translate("Couldn\'t get the plugin to work") }}
42
- <div class="dtsDeactivateDescShell">
43
- {{ environment.translate('If you have a question, <a href="%s" target="_blank">contact us</a> and will do our best to help you')|format('https://supsystic.com/contact-us/')|raw }}
44
- </div>
45
- </label>
46
- <label class="dtsDeactivateReasonShell">
47
- <input type="radio" name="deactivate_reason" value="found_better" />
48
- {{ environment.translate('I found a better plugin') }}
49
- <div class="dtsDeactivateDescShell">
50
- <input type="text" name="better_plugin" placeholder="{{ environment.translate("If it\'s possible, specify plugin name") }}">
51
- </div>
52
- </label>
53
- <label class="dtsDeactivateReasonShell">
54
- <input type="radio" name="deactivate_reason" value="not_need" />
55
- {{ environment.translate('I no longer need the plugin') }}
56
- </label>
57
- <label class="dtsDeactivateReasonShell">
58
- <input type="radio" name="deactivate_reason" value="temporary" />
59
- {{ environment.translate("It\'s a temporary deactivation") }}
60
- </label>
61
- <label class="dtsDeactivateReasonShell">
62
- <input type="radio" name="deactivate_reason" value="other" />
63
- {{ environment.translate('Other') }}
64
- <div class="dtsDeactivateDescShell">
65
- <input type="text" name="other" placeholder="{{ environment.translate('What is the reason?') }}">
66
- </div>
67
- </label>
68
- </form>
69
- <a href="" class="dtsDeactivateSkipDataBtn">{{ environment.translate('Skip & Deactivate') }}</a>
70
- </div>
1
+ <style type="text/css">
2
+ .dtsDeactivateDescShell {
3
+ display: none;
4
+ margin-left: 25px;
5
+ margin-top: 5px;
6
+ }
7
+ .dtsDeactivateReasonShell {
8
+ display: block;
9
+ margin-bottom: 10px;
10
+ }
11
+ #dtsDeactivateWnd input[type="text"],
12
+ #dtsDeactivateWnd textarea {
13
+ width: 100%;
14
+ }
15
+ #dtsDeactivateWnd h4 {
16
+ line-height: 1.53em;
17
+ }
18
+ #dtsDeactivateWnd + .ui-dialog-buttonpane .ui-dialog-buttonset {
19
+ float: none;
20
+ }
21
+ .dtsDeactivateSkipDataBtn {
22
+ float: right;
23
+ margin-top: 7px;
24
+ text-decoration: none;
25
+ color: #777 !important;
26
+ }
27
+
28
+ .dtsDeactivateReasonShell input[type="radio"]:checked::before {
29
+ width: 6px !important;
30
+ }
31
+ .ui-widget-content .dtsDeactivateReasonShell input[type="radio"] {
32
+ width: 16px;
33
+ height: 16px;
34
+ }
35
+ </style>
36
+ <div id="dtsDeactivateWnd" style="display: none;" title="{{ environment.translate('Your Feedback') }}">
37
+ <h4>{{ environment.translate('If you have a moment, please share why you are deactivating %s')|format(pluginName) }}</h4>
38
+ <form id="dtsDeactivateForm">
39
+ <label class="dtsDeactivateReasonShell">
40
+ <input type="radio" name="deactivate_reason" value="not_working" />
41
+ {{ environment.translate("Couldn\'t get the plugin to work") }}
42
+ <div class="dtsDeactivateDescShell">
43
+ {{ environment.translate('If you have a question, <a href="%s" target="_blank">contact us</a> and will do our best to help you')|format('https://supsystic.com/contact-us/')|raw }}
44
+ </div>
45
+ </label>
46
+ <label class="dtsDeactivateReasonShell">
47
+ <input type="radio" name="deactivate_reason" value="found_better" />
48
+ {{ environment.translate('I found a better plugin') }}
49
+ <div class="dtsDeactivateDescShell">
50
+ <input type="text" name="better_plugin" placeholder="{{ environment.translate("If it\'s possible, specify plugin name") }}">
51
+ </div>
52
+ </label>
53
+ <label class="dtsDeactivateReasonShell">
54
+ <input type="radio" name="deactivate_reason" value="not_need" />
55
+ {{ environment.translate('I no longer need the plugin') }}
56
+ </label>
57
+ <label class="dtsDeactivateReasonShell">
58
+ <input type="radio" name="deactivate_reason" value="temporary" />
59
+ {{ environment.translate("It\'s a temporary deactivation") }}
60
+ </label>
61
+ <label class="dtsDeactivateReasonShell">
62
+ <input type="radio" name="deactivate_reason" value="other" />
63
+ {{ environment.translate('Other') }}
64
+ <div class="dtsDeactivateDescShell">
65
+ <input type="text" name="other" placeholder="{{ environment.translate('What is the reason?') }}">
66
+ </div>
67
+ </label>
68
+ </form>
69
+ <a href="" class="dtsDeactivateSkipDataBtn">{{ environment.translate('Skip & Deactivate') }}</a>
70
+ </div>
src/SupsysticTables/Settings/views/index.twig CHANGED
@@ -57,7 +57,7 @@
57
  <div class="table-step-option table-option">
58
  <div class="setting-description">
59
  <label>{{ environment.translate('Rows Count per Request') }}</label>
60
- {{ tooltip.icon(environment.translate('Set the count of table rows, which will be put into the one saving request. If your table has more rows - as many requests will be sent as need to completely save all table data.<br /><br /> It can be useful if you have a large table and can not improuve your server settings to save the table per single request.<br /><br /> If you do not have problems with saving of tables it is better to left the default value - 400.'), 'top', true) }} </label>
61
  </div>
62
  <div class="setting-control">
63
  <input type="text" name="settings[table_step]" value="{{ settings.table_step | default(400) }}">
@@ -78,6 +78,26 @@
78
  <input type="text" value="{{ '[supsystic-tables-global-page-search]' }}" class="stbCopyTextCode" readonly="readonly" />
79
  </div>
80
  </div>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
81
  <div class="table-roles-option table-option">
82
  <div class="setting-description">
83
  <label>{{ environment.translate('Roles') }}</label>
57
  <div class="table-step-option table-option">
58
  <div class="setting-description">
59
  <label>{{ environment.translate('Rows Count per Request') }}</label>
60
+ {{ tooltip.icon(environment.translate('Set the count of table rows, which will be put into the one saving request. If your table has more rows - as many requests will be sent as need to completely save all table data.<br /><br /> It can be useful if you have a large table and can not improuve your server settings to save the table per single request.<br /><br /> If you do not have problems with saving of tables it is better to left the default value - 400. <a href="https://supsystic.com/documentation/rows-per-request-feature-solution-large-tables/" target="_blank">Read more</a>'), 'top', true) }} </label>
61
  </div>
62
  <div class="setting-control">
63
  <input type="text" name="settings[table_step]" value="{{ settings.table_step | default(400) }}">
78
  <input type="text" value="{{ '[supsystic-tables-global-page-search]' }}" class="stbCopyTextCode" readonly="readonly" />
79
  </div>
80
  </div>
81
+ <div class="table-load-ajax-enabled table-option">
82
+ <div class="setting-description">
83
+ <label>{{ environment.translate('Load by AJAX enable') }}</label>
84
+ {{ tooltip.icon(environment.translate('Allow loading posts/pages with tables through AJAX. Important: the assets-shortcode must be specified in the parent page.'), 'top', true) }}
85
+
86
+ {% if environment.isPro() == false %}
87
+ <a target="_blank" href="{{ build_pro_url({ 'utm_medium': 'load_by_ajax_enabled' }) }}">
88
+ {{ environment.translate('PRO option') }}
89
+ </a>
90
+ {% endif %}
91
+ </div>
92
+ <div class="setting-control">
93
+ {% if environment.isPro() == false %}
94
+ <input type="checkbox" disabled value=""/>
95
+ {% else %}
96
+ <input type="checkbox" name="settings[load_by_ajax_enabled]" {% if settings.load_by_ajax_enabled == 'on' %} checked {% endif %}>
97
+ <input type="text" value="{{ '[supsystic-tables-assets]' }}" class="stbCopyTextCode" readonly="readonly" style="width:250px"/>
98
+ {% endif %}
99
+ </div>
100
+ </div>
101
  <div class="table-roles-option table-option">
102
  <div class="setting-description">
103
  <label>{{ environment.translate('Roles') }}</label>
src/SupsysticTables/Tables/Controller.php CHANGED
@@ -194,6 +194,7 @@ class SupsysticTables_Tables_Controller extends SupsysticTables_Core_BaseControl
194
  $tables = $this->getModel('tables');
195
 
196
  try {
 
197
  $this->getEnvironment()->getModule('tables')->setIniLimits();
198
  $start = $request->post->get('start');
199
  $length = $request->post->get('length');
@@ -205,6 +206,9 @@ class SupsysticTables_Tables_Controller extends SupsysticTables_Core_BaseControl
205
  $searchAll['value'] = $searchValue;
206
  }
207
  $searchCols = array();
 
 
 
208
  foreach ($columns as $j => $column) {
209
  if (isset($column['search']) && isset($column['search']['value'])) {
210
  $search = $column['search']['value'];
@@ -221,11 +225,14 @@ class SupsysticTables_Tables_Controller extends SupsysticTables_Core_BaseControl
221
  $orderAsc = (isset($order[0]) && isset($order[0]['dir']) && $order[0]['dir'] == 'asc');
222
  $header = (int)$request->post->get('header');
223
  $footer = (int)$request->post->get('footer');
224
- $table = $tables->getById($id);
225
 
226
  if($this->getEnvironment()->isWooPro() && isset($table->woo_settings) && isset($table->woo_settings['woocommerce']['enable']) && $table->woo_settings['woocommerce']['enable'] === 'on'){
227
  $rows = $this->getEnvironment()->getModule('woocommerce')->getController()->getRowsByPart($id, array(), $start, $length, $searchAll['value']);
228
- }else{
 
 
 
 
229
  $rows = $tables->getRowsByPart($id, ($searchAll['value'] == '' ? false : $searchAll['value']), $searchCols, $orderCol, $orderAsc, $start, $length, $header, $footer, $searchParams, $table);
230
  }
231
  $table->rows = $rows['data'];
194
  $tables = $this->getModel('tables');
195
 
196
  try {
197
+ $table = $tables->getById($id);
198
  $this->getEnvironment()->getModule('tables')->setIniLimits();
199
  $start = $request->post->get('start');
200
  $length = $request->post->get('length');
206
  $searchAll['value'] = $searchValue;
207
  }
208
  $searchCols = array();
209
+ if ($table->settings['autoIndex'] == 'new' && $this->getEnvironment()->isPro() && isset($table->settings['source']) && isset($table->settings['source']['database']) && $table->settings['source']['database'] == 'on'){
210
+ $columns = array_slice($columns, 1);
211
+ }
212
  foreach ($columns as $j => $column) {
213
  if (isset($column['search']) && isset($column['search']['value'])) {
214
  $search = $column['search']['value'];
225
  $orderAsc = (isset($order[0]) && isset($order[0]['dir']) && $order[0]['dir'] == 'asc');
226
  $header = (int)$request->post->get('header');
227
  $footer = (int)$request->post->get('footer');
 
228
 
229
  if($this->getEnvironment()->isWooPro() && isset($table->woo_settings) && isset($table->woo_settings['woocommerce']['enable']) && $table->woo_settings['woocommerce']['enable'] === 'on'){
230
  $rows = $this->getEnvironment()->getModule('woocommerce')->getController()->getRowsByPart($id, array(), $start, $length, $searchAll['value']);
231
+ }elseif($this->getEnvironment()->isPro() && isset($table->settings['source']) && isset($table->settings['source']['database']) && $table->settings['source']['database'] == 'on'){
232
+ $core = $this->getEnvironment()->getModule('core');
233
+ $dbTableModel = $core->getModelsFactory()->get('DBTables', 'tables');
234
+ $rows = $dbTableModel->getRowsByPart($table->settings, $orderCol, $orderAsc, $start, $length, ($searchAll['value'] == '' ? false : $searchAll['value']), $searchCols, $searchParams);
235
+ }else{
236
  $rows = $tables->getRowsByPart($id, ($searchAll['value'] == '' ? false : $searchAll['value']), $searchCols, $orderCol, $orderAsc, $start, $length, $header, $footer, $searchParams, $table);
237
  }
238
  $table->rows = $rows['data'];
src/SupsysticTables/Tables/Model/Tables.php CHANGED
@@ -291,6 +291,11 @@ class SupsysticTables_Tables_Model_Tables extends SupsysticTables_Core_BaseModel
291
  $cell['formattedValue'] = htmlspecialchars((string)$cell['formattedValue'], ENT_QUOTES);
292
  }
293
  $cell['data'] = htmlspecialchars((string)$cell['data'], ENT_QUOTES);
 
 
 
 
 
294
  }
295
  foreach ($data['cells'] as &$cell) {
296
  foreach ($keys as $key => $val) {
@@ -320,6 +325,11 @@ class SupsysticTables_Tables_Model_Tables extends SupsysticTables_Core_BaseModel
320
  $cell['formattedValue'] = htmlspecialchars_decode((string)$cell['formattedValue'], ENT_QUOTES);
321
  }
322
  $cell['data'] = htmlspecialchars_decode($cell['data'], ENT_QUOTES);
 
 
 
 
 
323
  }
324
  }
325
  } else {
291
  $cell['formattedValue'] = htmlspecialchars((string)$cell['formattedValue'], ENT_QUOTES);
292
  }
293
  $cell['data'] = htmlspecialchars((string)$cell['data'], ENT_QUOTES);
294
+ if (isset($cell['source']) && is_array($cell['source'])) {
295
+ foreach ($cell['source'] as $i => $v) {
296
+ $cell['source'][$i] = htmlspecialchars((string)$v, ENT_QUOTES);
297
+ }
298
+ }
299
  }
300
  foreach ($data['cells'] as &$cell) {
301
  foreach ($keys as $key => $val) {
325
  $cell['formattedValue'] = htmlspecialchars_decode((string)$cell['formattedValue'], ENT_QUOTES);
326
  }
327
  $cell['data'] = htmlspecialchars_decode($cell['data'], ENT_QUOTES);
328
+ if (isset($cell['source']) && is_array($cell['source'])) {
329
+ foreach ($cell['source'] as $i => $v) {
330
+ $cell['source'][$i] = htmlspecialchars_decode((string)$v, ENT_QUOTES);
331
+ }
332
+ }
333
  }
334
  }
335
  } else {
src/SupsysticTables/Tables/Module.php CHANGED
@@ -409,7 +409,11 @@ class SupsysticTables_Tables_Module extends SupsysticTables_Core_BaseModule
409
  $table->rows[$key]['cells'][$index]['calculatedValue'] = $this->isFromHistory[$key]['cells'][$index]['calculatedValue'];
410
  }
411
  }
412
- $table->rows[$key]['cells'][$index]['data'] = do_shortcode($table->rows[$key]['cells'][$index]['data']);
 
 
 
 
413
  }
414
  }
415
  }
@@ -438,29 +442,11 @@ class SupsysticTables_Tables_Module extends SupsysticTables_Core_BaseModule
438
  $this->tableSearch = '';
439
  }
440
 
441
- $show_edit_link = '';
442
- if( is_user_logged_in() ) {
443
- $user = wp_get_current_user();
444
- $roles = is_array($user->roles) ? $user->roles : array($user->roles);
445
- $pluginSettings = get_option($this->getController()->getConfig()->get('db_prefix') . 'settings', 'access_roles');
446
- if (!empty($roles) && !empty($pluginSettings)) {
447
- foreach ($roles as $role) {
448
- if (in_array($role, $pluginSettings)) {
449
- $show_edit_link = $this->_getTblLink($id);
450
- break;
451
- }
452
- }
453
- }
454
 
455
- if (current_user_can('manage_options')) {
456
- $show_edit_link = $this->_getTblLink($id);
457
- }
458
- }
459
-
460
- $renderData = $twig->render($this->getShortcodeTemplate(), array('table' => $table, 'is_feed' => is_feed(), 'show_edit_link' => $show_edit_link));
461
- $renderData = preg_replace('/\s+/', ' ', trim($renderData));
462
-
463
- if(!$table->isSSP && !in_array($table->view_id, $this->_tablesStyles)) {
464
  $renderData = $this->addDataTableStyles($table) . $renderData;
465
  }
466
  if (!$this->isSingleCell && !$this->isTablePart && !$this->checkSpreadsheet && !$this->isFromHistory && isset($this->cacheDirectory)) {
@@ -474,7 +460,7 @@ class SupsysticTables_Tables_Module extends SupsysticTables_Core_BaseModule
474
  }
475
 
476
  private function _getTblLink($id) {
477
- return "<a href=".$this->getController()->generateUrl('tables', 'view', array( 'id' => $id ) ).">". $this->getEnvironment()->translate('Edit'). " <i class='fa fa-fw fa-pencil'></i></a>";
478
  }
479
 
480
  public function getMirrorFooter($table) {
@@ -511,6 +497,121 @@ class SupsysticTables_Tables_Module extends SupsysticTables_Core_BaseModule
511
  return $footer;
512
  }
513
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
514
  /**
515
  * Renders the value of single cell
516
  * @param int $tableId
@@ -524,6 +625,9 @@ class SupsysticTables_Tables_Module extends SupsysticTables_Core_BaseModule
524
  $environment = $this->getEnvironment();
525
  $core = $environment->getModule('core');
526
  $tables = $core->getModelsFactory()->get('tables');
 
 
 
527
 
528
  try {
529
  $rows = $tables->getRows($tableId);
@@ -544,6 +648,32 @@ class SupsysticTables_Tables_Module extends SupsysticTables_Core_BaseModule
544
  } else {
545
  $value = $rows[$key]['cells'][$index]['data'];
546
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
547
  }
548
  }
549
  }
@@ -585,6 +715,31 @@ class SupsysticTables_Tables_Module extends SupsysticTables_Core_BaseModule
585
  add_action('wp_footer', array($asset, 'load'));
586
  }
587
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
588
  $this->shortAttributes = $attributes;
589
  return $this->render((int)$attributes['id']);
590
  }
@@ -1120,7 +1275,7 @@ class SupsysticTables_Tables_Module extends SupsysticTables_Core_BaseModule
1120
  //->setExternalSource('https://cdnjs.cloudflare.com/ajax/libs/handsontable/0.31.1/handsontable.full.min.css')
1121
  ->setModuleSource($this, 'libraries/handsontable/handsontable.full.min.css')
1122
  ->setCachingAllowed(true)
1123
- ->setVersion('0.31.1')
1124
  );
1125
 
1126
  $ui->add(
@@ -1134,10 +1289,12 @@ class SupsysticTables_Tables_Module extends SupsysticTables_Core_BaseModule
1134
  $ui->createScript('supsystic-tables-handsontable-js')
1135
  ->setHookName($hookName)
1136
  //->setExternalSource('https://cdnjs.cloudflare.com/ajax/libs/handsontable/0.31.1/handsontable.full.min.js')
1137
- ->setModuleSource($this, 'libraries/handsontable/handsontable.full.min.js')
 
1138
  ->setCachingAllowed(true)
1139
- ->setVersion('0.31.1')
1140
  );
 
1141
 
1142
  $ui->add(
1143
  $ui->createScript('supsystic-tables-rulejs-hot-js')
409
  $table->rows[$key]['cells'][$index]['calculatedValue'] = $this->isFromHistory[$key]['cells'][$index]['calculatedValue'];
410
  }
411
  }
412
+ if (strpos($table->rows[$key]['cells'][$index]['data'], '%3C') !== false) {
413
+ $table->rows[$key]['cells'][$index]['data'] = do_shortcode(urldecode($table->rows[$key]['cells'][$index]['data']));
414
+ } else {
415
+ $table->rows[$key]['cells'][$index]['data'] = do_shortcode($table->rows[$key]['cells'][$index]['data']);
416
+ }
417
  }
418
  }
419
  }
442
  $this->tableSearch = '';
443
  }
444
 
445
+ $renderData = $twig->render($this->getShortcodeTemplate(), array('table' => $table, 'is_feed' => is_feed()));
446
+ $renderData = preg_replace('/\s+/iu', ' ', trim($renderData));
 
 
 
 
 
 
 
 
 
 
 
447
 
448
+ $tablesStyles = is_array($this->_tablesStyles) ? $this->_tablesStyles : array($this->_tablesStyles);
449
+ if(!$table->isSSP && !in_array($table->view_id, $tablesStyles)) {
 
 
 
 
 
 
 
450
  $renderData = $this->addDataTableStyles($table) . $renderData;
451
  }
452
  if (!$this->isSingleCell && !$this->isTablePart && !$this->checkSpreadsheet && !$this->isFromHistory && isset($this->cacheDirectory)) {
460
  }
461
 
462
  private function _getTblLink($id) {
463
+ return "<a class='tblEditLink' href=".$this->getController()->generateUrl('tables', 'view', array( 'id' => $id ) )." style='display:inline-block;'>". $this->getEnvironment()->translate('Edit Table'). "</a>";
464
  }
465
 
466
  public function getMirrorFooter($table) {
497
  return $footer;
498
  }
499
 
500
+ private function _getTypeFormats($table)
501
+ {
502
+ $formats = array(
503
+ 'number' => array(
504
+ 'decimals' => array(
505
+ 'count' => 0,
506
+ 'sep' => ''
507
+ ),
508
+ 'thousands' => array(
509
+ 'sep' => ','
510
+ )
511
+ ),
512
+ 'currency' => array(
513
+ 'decimals' => array(
514
+ 'count' => 2,
515
+ 'sep' => '.'
516
+ ),
517
+ 'thousands' => array(
518
+ 'sep' => ''
519
+ )
520
+ ),
521
+ 'percent' => array(
522
+ 'decimals' => array(
523
+ 'count' => 0,
524
+ 'sep' => ''
525
+ )
526
+ ),
527
+ 'date' => array(
528
+ 'format' => 'd.m.Y'
529
+ ),
530
+ 'time' => array(
531
+ 'format' => 'H:i'
532
+ )
533
+ );
534
+
535
+ if ($table->settings['useNumberFormat']) {
536
+ $numberFormat = $table->settings['numberFormat'];
537
+ $percentFormat = $table->settings['percentFormat'];
538
+ $currencyFormat = $table->settings['currencyFormat'];
539
+ $dateFormat = $table->settings['dateFormat'];
540
+ $timeDurationFormat = $table->settings['timeDurationFormat'];
541
+
542
+ // number format
543
+ if (strpos($numberFormat, '.') !== false) {
544
+ $aNumberFormat = explode('.', $numberFormat);
545
+ $formats['number'] = array(
546
+ 'decimals' => array(
547
+ 'count' => strlen(end($aNumberFormat)),
548
+ 'sep' => '.'
549
+ )
550
+ );
551
+ }
552
+ if (strpos($numberFormat, ',') !== false) {
553
+ $formats['number']['thousands'] = array(
554
+ 'sep' => ','
555
+ );
556
+ }
557
+
558
+ // currency format
559
+ if (strpos($currencyFormat, '.') !== false) {
560
+ $aNumberFormat = explode('.', $currencyFormat);
561
+ $formats['currency'] = array(
562
+ 'decimals' => array(
563
+ 'count' => strlen(end($aNumberFormat)),
564
+ 'sep' => '.'
565
+ )
566
+ );
567
+ }
568
+ if (strpos($currencyFormat, ',') !== false) {
569
+ $formats['currency']['thousands'] = array(
570
+ 'sep' => ','
571
+ );
572
+ }
573
+
574
+ // percent format
575
+ if (strpos($percentFormat, '.') !== false) {
576
+ $aPercentFormat = explode('.', str_replace('%', '', $percentFormat));
577
+ $formats['percent'] = array(
578
+ 'decimals' => array(
579
+ 'count' => strlen(end($aPercentFormat)),
580
+ 'sep' => '.'
581
+ )
582
+ );
583
+ } elseif (strpos($percentFormat, ',') !== false) {
584
+ $aPercentFormat = explode(',', $percentFormat);
585
+ $formats['percent'] = array(
586
+ 'decimals' => array(
587
+ 'count' => strlen(end($aPercentFormat)),
588
+ 'sep' => ','
589
+ )
590
+ );
591
+ }
592
+
593
+ // date format
594
+ if ($dateFormat) {
595
+ $formats['date']['format'] = strtr($dateFormat, array(
596
+ 'YYYY-MM-DD' => 'Y-m-d',
597
+ 'DD.MM.YYYY' => 'd.m.Y',
598
+ 'HH:mm' => 'H:i',
599
+ 'hh:mm a' => 'h:i a'
600
+ ));
601
+ }
602
+
603
+ // time duration format
604
+ if ($timeDurationFormat) {
605
+ $formats['time']['format'] = strtr($timeDurationFormat, array(
606
+ 'HH:mm' => 'H:i',
607
+ 'hh:mm a' => 'h:i a'
608
+ ));
609
+ }
610
+ }
611
+
612
+ return $formats;
613
+ }
614
+
615
  /**
616
  * Renders the value of single cell
617
  * @param int $tableId
625
  $environment = $this->getEnvironment();
626
  $core = $environment->getModule('core');
627
  $tables = $core->getModelsFactory()->get('tables');
628
+ $table = $tables->getById($tableId);
629
+ $formats = $this->_getTypeFormats($table);
630
+ $table = null;
631
 
632
  try {
633
  $rows = $tables->getRows($tableId);
648
  } else {
649
  $value = $rows[$key]['cells'][$index]['data'];
650
  }
651
+ if ($cell['formatType']) {
652
+ switch ($cell['formatType']){
653
+ case 'date':
654
+ $value = date($formats['date']['format'], strtotime($value));
655
+ break;
656
+ case 'percent':
657
+ case 'percent-convert':
658
+ $value = number_format($value * 100, $formats['percent']['decimals']['count'], $formats['percent']['decimals']['sep'], ''). '%';
659
+ break;
660
+ case 'currency':
661
+ $value = number_format($value, $formats['currency']['decimals']['count'], $formats['currency']['decimals']['sep'], $formats['currency']['thousands']['sep']);
662
+ break;
663
+ case 'time_duration':
664
+ $value = date($formats['time']['format'], strtotime($value));
665
+ break;
666
+ default:
667
+ if (is_numeric($value)) {
668
+ $value = number_format($value, $formats['number']['decimals']['count'], $formats['number']['decimals']['sep'], $formats['number']['thousands']['sep']);
669
+ }
670
+ break;
671
+ }
672
+ } else {
673
+ if (is_numeric($value)) {
674
+ $value = number_format($value, $formats['number']['decimals']['count'], $formats['number']['decimals']['sep'], $formats['number']['thousands']['sep']);
675
+ }
676
+ }
677
  }
678
  }
679
  }
715
  add_action('wp_footer', array($asset, 'load'));
716
  }
717
  }
718
+
719
+ if (!is_admin() && is_user_logged_in()){
720
+ $show_edit_link = false;
721
+ $user = wp_get_current_user();
722
+ $roles = is_array($user->roles) ? $user->roles : array($user->roles);
723
+ $pluginSettings = get_option($this->getController()->getConfig()->get('db_prefix') . 'settings', 'access_roles');
724
+ if (!empty($roles) && !empty($pluginSettings)) {
725
+ !is_array($pluginSettings) && $pluginSettings = array($pluginSettings);
726
+ foreach ($roles as $role) {
727
+ if (in_array($role, $pluginSettings)) {
728
+ $show_edit_link = $this->_getTblLink((int)$attributes['id']);
729
+ break;
730
+ }
731
+ }
732
+ }
733
+
734
+ if (!$show_edit_link && current_user_can('manage_options')) {
735
+ $show_edit_link = $this->_getTblLink((int)$attributes['id']);
736
+ }
737
+
738
+ if ($show_edit_link) {
739
+ wp_localize_script('tables-core', 'g_stbTblEditLink_' . $attributes['id'], base64_encode($show_edit_link));
740
+ }
741
+ }
742
+
743
  $this->shortAttributes = $attributes;
744
  return $this->render((int)$attributes['id']);
745
  }
1275
  //->setExternalSource('https://cdnjs.cloudflare.com/ajax/libs/handsontable/0.31.1/handsontable.full.min.css')
1276
  ->setModuleSource($this, 'libraries/handsontable/handsontable.full.min.css')
1277
  ->setCachingAllowed(true)
1278
+ ->setVersion('7.1.1')
1279
  );
1280
 
1281
  $ui->add(
1289
  $ui->createScript('supsystic-tables-handsontable-js')
1290
  ->setHookName($hookName)
1291
  //->setExternalSource('https://cdnjs.cloudflare.com/ajax/libs/handsontable/0.31.1/handsontable.full.min.js')
1292
+ //->setModuleSource($this, 'libraries/handsontable/handsontable.full.min.js')
1293
+ ->setModuleSource($this, 'libraries/handsontable/handsontable.min.js')
1294
  ->setCachingAllowed(true)
1295
+ ->setVersion('7.1.1')
1296
  );
1297
+
1298
 
1299
  $ui->add(
1300
  $ui->createScript('supsystic-tables-rulejs-hot-js')
src/SupsysticTables/Tables/assets/css/tables.editor.css CHANGED
@@ -152,7 +152,7 @@ i.toolbar-word-wrap.word-wrap-visible {
152
  max-width: 0;
153
  }
154
 
155
- #tableEditor .editable, #tableEditor .selectable, #tableEditor .datefield, #tableEditor .unescapeHTML,
156
  #tableEditor .hiddenCell, #tableEditor .invisibleCell, #tableEditor .collapsibleCell, #tableEditor .tooltipCell, #tableEditor .formatedCell {
157
  position: relative;
158
  }
@@ -165,13 +165,15 @@ i.toolbar-word-wrap.word-wrap-visible {
165
  left: 0;
166
  width: 0;
167
  height: 0;
 
168
  border-top: 7px solid #000;
169
  border-left: 0 solid transparent;
170
  border-right: 7px solid transparent;
171
  border-bottom: 0 solid transparent;
172
  }
173
 
174
- #tableEditor .editable:after {
 
175
  content: '';
176
  display: block;
177
  position: absolute;
@@ -179,6 +181,7 @@ i.toolbar-word-wrap.word-wrap-visible {
179
  right: 0;
180
  width: 0;
181
  height: 0;
 
182
  border-top: 0 solid transparent;
183
  border-left: 0 solid transparent;
184
  border-right: 7px solid #029A0E;
@@ -193,6 +196,7 @@ i.toolbar-word-wrap.word-wrap-visible {
193
  right: 0;
194
  width: 0;
195
  height: 0;
 
196
  border-top: 0 solid transparent;
197
  border-left: 0 solid transparent;
198
  border-right: 7px solid #0000ff;
@@ -207,6 +211,7 @@ i.toolbar-word-wrap.word-wrap-visible {
207
  right: 0;
208
  width: 0;
209
  height: 0;
 
210
  border-top: 0 solid transparent;
211
  border-left: 0 solid transparent;
212
  border-right: 7px solid #ff9406;
@@ -221,6 +226,7 @@ i.toolbar-word-wrap.word-wrap-visible {
221
  left: 0;
222
  width: 0;
223
  height: 0;
 
224
  border-top: 7px solid #FF0000;
225
  border-left: 0 solid transparent;
226
  border-right: 7px solid transparent;
@@ -235,6 +241,7 @@ i.toolbar-word-wrap.word-wrap-visible {
235
  left: 0;
236
  width: 0;
237
  height: 0;
 
238
  border-top: 7px solid #aa44ff;
239
  border-left: 0 solid transparent;
240
  border-right: 7px solid transparent;
@@ -249,6 +256,7 @@ i.toolbar-word-wrap.word-wrap-visible {
249
  left: 0;
250
  width: 0;
251
  height: 0;
 
252
  border-top: 7px solid #95109a;
253
  border-left: 0 solid transparent;
254
  border-right: 7px solid transparent;
@@ -267,6 +275,7 @@ i.toolbar-word-wrap.word-wrap-visible {
267
  left: 0;
268
  width: 0;
269
  height: 0;
 
270
  border-top: 7px solid #f03cf0;
271
  border-left: 0 solid transparent;
272
  border-right: 7px solid transparent;
@@ -281,6 +290,7 @@ i.toolbar-word-wrap.word-wrap-visible {
281
  left: 0;
282
  width: 0;
283
  height: 0;
 
284
  border-top: 7px solid #50CDFE;
285
  border-left: 0 solid transparent;
286
  border-right: 7px solid transparent;
152
  max-width: 0;
153
  }
154
 
155
+ #tableEditor .editable, #tableEditor .editfile, #tableEditor .selectable, #tableEditor .datefield, #tableEditor .unescapeHTML,
156
  #tableEditor .hiddenCell, #tableEditor .invisibleCell, #tableEditor .collapsibleCell, #tableEditor .tooltipCell, #tableEditor .formatedCell {
157
  position: relative;
158
  }
165
  left: 0;
166
  width: 0;
167
  height: 0;
168
+ opacity: 1;
169
  border-top: 7px solid #000;
170
  border-left: 0 solid transparent;
171
  border-right: 7px solid transparent;
172
  border-bottom: 0 solid transparent;
173
  }
174
 
175
+ #tableEditor .editable:after,
176
+ #tableEditor .editfile:after{
177
  content: '';
178
  display: block;
179
  position: absolute;
181
  right: 0;
182
  width: 0;
183
  height: 0;
184
+ opacity: 1;
185
  border-top: 0 solid transparent;
186
  border-left: 0 solid transparent;
187
  border-right: 7px solid #029A0E;
196
  right: 0;
197
  width: 0;
198
  height: 0;
199
+ opacity: 1;
200
  border-top: 0 solid transparent;
201
  border-left: 0 solid transparent;
202
  border-right: 7px solid #0000ff;
211
  right: 0;
212
  width: 0;
213
  height: 0;
214
+ opacity: 1;
215
  border-top: 0 solid transparent;
216
  border-left: 0 solid transparent;
217
  border-right: 7px solid #ff9406;
226
  left: 0;
227
  width: 0;
228
  height: 0;
229
+ opacity: 1;
230
  border-top: 7px solid #FF0000;
231
  border-left: 0 solid transparent;
232
  border-right: 7px solid transparent;
241
  left: 0;
242
  width: 0;
243
  height: 0;
244
+ opacity: 1;
245
  border-top: 7px solid #aa44ff;
246
  border-left: 0 solid transparent;
247
  border-right: 7px solid transparent;
256
  left: 0;
257
  width: 0;
258
  height: 0;
259
+ opacity: 1;
260
  border-top: 7px solid #95109a;
261
  border-left: 0 solid transparent;
262
  border-right: 7px solid transparent;
275
  left: 0;
276
  width: 0;
277
  height: 0;
278
+ opacity: 1;
279
  border-top: 7px solid #f03cf0;
280
  border-left: 0 solid transparent;
281
  border-right: 7px solid transparent;
290
  left: 0;
291
  width: 0;
292
  height: 0;
293
+ opacity: 1;
294
  border-top: 7px solid #50CDFE;
295
  border-left: 0 solid transparent;
296
  border-right: 7px solid transparent;
src/SupsysticTables/Tables/assets/css/tables.shortcode.css CHANGED
@@ -225,6 +225,10 @@ table.oneColumnWithLabels tr:not(.haveMergedCell) td:after {
225
  padding: 4px;
226
  }
227
 
 
 
 
 
228
  /* For of applying unneeded scroll to fixed columns */
229
  .supsystic-tables-wrap .DTFC_LeftWrapper .supsystic-table, .supsystic-tables-wrap .DTFC_RightWrapper .supsystic-table {
230
  border-right: none;
@@ -278,7 +282,21 @@ table.dataTable input.search-column {
278
  .supsystic-tables-wrap table.supsystic-table.stripe, .supsystic-tables-wrap table.supsystic-table.hover td {
279
  background-color: inherit;
280
  }
 
 
 
 
 
 
 
281
  /*Disable Edit Link that was placed wrong in plugin before*/
282
  .supsystic-tables-wrap > a {
283
  display: none;
 
 
 
 
 
 
 
284
  }
225
  padding: 4px;
226
  }
227
 
228
+ .supsystic-tables-wrap .DTFC_ScrollWrapper{
229
+ height: auto!important;
230
+ }
231
+
232
  /* For of applying unneeded scroll to fixed columns */
233
  .supsystic-tables-wrap .DTFC_LeftWrapper .supsystic-table, .supsystic-tables-wrap .DTFC_RightWrapper .supsystic-table {
234
  border-right: none;
282
  .supsystic-tables-wrap table.supsystic-table.stripe, .supsystic-tables-wrap table.supsystic-table.hover td {
283
  background-color: inherit;
284
  }
285
+ .supsystic-tables-global-page-search-wrapper{
286
+ margin-bottom: 10px;
287
+ margin-top: 10px;
288
+ }
289
+ .supsystic-tables-wrap .supsystic-table .editfile .delete-upload-file{
290
+ display: none;
291
+ }
292
  /*Disable Edit Link that was placed wrong in plugin before*/
293
  .supsystic-tables-wrap > a {
294
  display: none;
295
+ }
296
+ .inputArea {
297
+ -ms-overflow-style: none;
298
+ scrollbar-width: none;
299
+ }
300
+ .inputArea::-webkit-scrollbar {
301
+ display: none;
302
  }
src/SupsysticTables/Tables/assets/css/tables.view.css CHANGED
@@ -65,10 +65,10 @@
65
  .tables-view .table-title-wrap .table-buttons .button {
66
  margin-left: 5px;
67
  }
68
- .tables-view .table-title-wrap .table-buttons > .table-buttons-left {
69
  float: left;
70
  }
71
- .tables-view .table-title-wrap .table-buttons > .table-buttons-right {
72
  float: right;
73
  }
74
  .tables-view .form-table label i.fa-question-circle {
@@ -94,6 +94,7 @@
94
  position: relative;
95
  }
96
  .tables-view .subsubsub.control-buttons {
 
97
  float: right;
98
  margin: 0;
99
  border-bottom: none !important;
@@ -671,3 +672,13 @@
671
  #language-file {
672
  width:96px !important;
673
  }
 
 
 
 
 
 
 
 
 
 
65
  .tables-view .table-title-wrap .table-buttons .button {
66
  margin-left: 5px;
67
  }
68
+ .tables-view .table-title-wrap .table-buttons > .table-buttons-left {
69
  float: left;
70
  }
71
+ .tables-view .table-title-wrap .table-buttons > .table-buttons-right {
72
  float: right;
73
  }
74
  .tables-view .form-table label i.fa-question-circle {
94
  position: relative;
95
  }
96
  .tables-view .subsubsub.control-buttons {
97
+ margin-top: 26px;
98
  float: right;
99
  margin: 0;
100
  border-bottom: none !important;
672
  #language-file {
673
  width:96px !important;
674
  }
675
+
676
+ .tables-view table .relative .changeType{
677
+ opacity: 0;
678
+ transition: all 0.3s ease;
679
+ }
680
+ .tables-view table .relative:hover .changeType,
681
+ .tables-view table .current .relative .changeType{
682
+ opacity: 1;
683
+ transition: all 0.3s ease;
684
+ }
src/SupsysticTables/Tables/assets/js/editor/tables.editor.formula.js CHANGED
@@ -49,13 +49,15 @@
49
 
50
  Formula.prototype.subscribe = function () {
51
  this.getEditor().addHook('afterSelection', $.proxy(function () {
52
- var range = this.getEditor().getSelectedRange();
 
 
 
 
 
53
 
54
  this.setValue(
55
- this.getEditor().getDataAtCell(
56
- range.highlight.row,
57
- range.highlight.col
58
- )
59
  );
60
  }, this));
61
 
@@ -70,7 +72,7 @@
70
  if (toeInArray((e.keyCode || e.which), [13, 9, 37, 38, 39, 40]) != -1) return false;
71
 
72
  var self = this,
73
- range = self.getEditor().getSelectedRange();
74
 
75
  self.setInputData({
76
  row: range.highlight.row,
49
 
50
  Formula.prototype.subscribe = function () {
51
  this.getEditor().addHook('afterSelection', $.proxy(function () {
52
+ var range = this.getEditor().getSelectedRangeLast()
53
+ , row = editor.toPhysicalRow(range.highlight.row)
54
+ , sourceDataAtCell = this.getEditor().getSourceDataAtCell(
55
+ row,
56
+ range.highlight.col
57
+ );
58
 
59
  this.setValue(
60
+ sourceDataAtCell
 
 
 
61
  );
62
  }, this));
63
 
72
  if (toeInArray((e.keyCode || e.which), [13, 9, 37, 38, 39, 40]) != -1) return false;
73
 
74
  var self = this,
75
+ range = self.getEditor().getSelectedRangeLast();
76
 
77
  self.setInputData({
78
  row: range.highlight.row,
src/SupsysticTables/Tables/assets/js/editor/tables.editor.js CHANGED
@@ -18,6 +18,7 @@ var g_stbIsDataEdited = {'settings': false, 'source': false, 'history': false, '
18
  var tableId = app.getParameterByName('id'),
19
  tablesModel = app.Models.Tables,
20
  editor = new Handsontable(document.getElementById('tableEditor'), {
 
21
  height: g_stbWindowHeight,
22
  renderAllRows: g_stbPagination, // To prevent losing of rows for huge tables (need to check in future is it all right now?)
23
  colWidths: 100,
@@ -60,7 +61,7 @@ var g_stbIsDataEdited = {'settings': false, 'source': false, 'history': false, '
60
 
61
  // Custom Handsontabe Renderer
62
  Handsontable.renderers.DefaultRenderer = function(instance,td,row,col,prop,value,cellProperties) {
63
- value = Handsontable.TextCell.renderer.call(this,instance,td,row,col,prop,value,cellProperties);
64
 
65
  if(cellProperties && cellProperties.formatType == 'currency') {
66
  value = tablesModel.setCellFormat(value,'currency');
@@ -69,7 +70,7 @@ var g_stbIsDataEdited = {'settings': false, 'source': false, 'history': false, '
69
  } else if(instance.useNumberFormat && (app.isNumber(value) || cellProperties.formatType == 'number')) {
70
  value = tablesModel.setCellFormat(value,'number');
71
  }
72
- Handsontable.TextCell.renderer.call(this,instance,td,row,col,prop,value,cellProperties);
73
  };
74
  Handsontable.editors.TextEditor.prototype.focus = function() {
75
  this.TEXTAREA.select();
@@ -202,6 +203,7 @@ var g_stbIsDataEdited = {'settings': false, 'source': false, 'history': false, '
202
  editor.addHook('afterLoadData', function () {
203
  generateWidthData();
204
  generateHeightData();
 
205
  });
206
  editor.addHook('afterCreateRow', function(insertRowIndex, amount, source) {
207
  var selectedCell = editor.getSelected(),
@@ -218,13 +220,8 @@ var g_stbIsDataEdited = {'settings': false, 'source': false, 'history': false, '
218
  data = editor.getData();
219
 
220
  setTimeout(function() {
221
- for(var j = 0; j < data[insertRowIndex].length; j++) {
222
- for(var n = 0; n < amount; n++) {
223
- editor.setCellMetaObject(insertRowIndex + n, j, editor.getCellMeta(i, j));
224
- }
225
- }
226
  if (amount > 1) {
227
- var merge = editor.mergeCells.mergedCellInfoCollection;
228
  for (var c = 0; c < merge.length; c++) {
229
  if (merge[c].row >= insertRowIndex) {
230
  merge[c].row += amount - 1;
@@ -278,16 +275,14 @@ var g_stbIsDataEdited = {'settings': false, 'source': false, 'history': false, '
278
  selectedColumnIndex = selectedCell[(isMin == 1 ? 3 : 1)];
279
  }
280
  }
 
 
 
 
281
  var j = (insertColumnIndex <= selectedColumnIndex ? insertColumnIndex + amount : selectedColumnIndex);
282
  setTimeout(function() {
283
- var countRows = editor.getData().length;
284
- for(var i = 0; i < countRows; i++) {
285
- for(var n = 0; n < amount; n++) {
286
- editor.setCellMetaObject(i, insertColumnIndex + n, editor.getCellMeta(i, j));
287
- }
288
- }
289
  if (amount > 1) {
290
- var merge = editor.mergeCells.mergedCellInfoCollection;
291
  for (var i = 0; i < merge.length; i++) {
292
  if (merge[i].col >= insertColumnIndex) {
293
  merge[i].col += amount - 1;
@@ -326,7 +321,7 @@ var g_stbIsDataEdited = {'settings': false, 'source': false, 'history': false, '
326
  updateUndoRedoBtns();
327
  });
328
  editor.addHook('beforeRemoveRow', function (from, amount) {
329
- var merge = editor.mergeCells.mergedCellInfoCollection,
330
  to = from + amount - 1,
331
  cntMerge = merge.length;
332
  for (var i = cntMerge - 1; i >= 0; i--) {
@@ -395,7 +390,7 @@ var g_stbIsDataEdited = {'settings': false, 'source': false, 'history': false, '
395
  updateUndoRedoBtns();
396
  });
397
  editor.addHook('beforeRemoveCol', function (from, amount) {
398
- var merge = editor.mergeCells.mergedCellInfoCollection,
399
  to = from + amount - 1,
400
  cntMerge = merge.length;
401
  for (var i = cntMerge - 1; i >= 0; i--) {
@@ -510,8 +505,7 @@ var g_stbIsDataEdited = {'settings': false, 'source': false, 'history': false, '
510
  j = 0;
511
  }
512
  if(g_stbCopyPasteCellsMetaData[j]) {
513
- var value = editor.getDataAtCell(row, col);
514
-
515
  if(value && value[0] == '=') {
516
  var deltaRow = row - g_stbCopyPasteCellsMetaData[j].row,
517
  deltaCol = col - g_stbCopyPasteCellsMetaData[j].col,
@@ -577,6 +571,38 @@ var g_stbIsDataEdited = {'settings': false, 'source': false, 'history': false, '
577
  editor.allWidths = typeof(editor.getSettings().colWidths) == 'object' ? editor.getSettings().colWidths : [];
578
  }
579
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
580
  function updateUndoRedoBtns() {
581
  if(editor.undoRedo) {
582
  var undo = $('[data-method="undo"]'),
@@ -730,7 +756,7 @@ var g_stbIsDataEdited = {'settings': false, 'source': false, 'history': false, '
730
  start = this.pageStart,
731
  stop = this.pageStop,
732
  data = this.getData(),
733
- merge = this.mergeCells.mergedCellInfoCollection;
734
  real = 0;
735
 
736
  for (var row = 0; row < countRows; row++) {
18
  var tableId = app.getParameterByName('id'),
19
  tablesModel = app.Models.Tables,
20
  editor = new Handsontable(document.getElementById('tableEditor'), {
21
+ licenseKey: 'non-commercial-and-evaluation',
22
  height: g_stbWindowHeight,
23
  renderAllRows: g_stbPagination, // To prevent losing of rows for huge tables (need to check in future is it all right now?)
24
  colWidths: 100,
61
 
62
  // Custom Handsontabe Renderer
63
  Handsontable.renderers.DefaultRenderer = function(instance,td,row,col,prop,value,cellProperties) {
64
+ value = Handsontable.cellTypes.text.renderer.call(this,instance,td,row,col,prop,value,cellProperties);
65
 
66
  if(cellProperties && cellProperties.formatType == 'currency') {
67
  value = tablesModel.setCellFormat(value,'currency');
70
  } else if(instance.useNumberFormat && (app.isNumber(value) || cellProperties.formatType == 'number')) {
71
  value = tablesModel.setCellFormat(value,'number');
72
  }
73
+ Handsontable.cellTypes.text.renderer.call(this,instance,td,row,col,prop,value,cellProperties);
74
  };
75
  Handsontable.editors.TextEditor.prototype.focus = function() {
76
  this.TEXTAREA.select();
203
  editor.addHook('afterLoadData', function () {
204
  generateWidthData();
205
  generateHeightData();
206
+ checkEditfileCells();
207
  });
208
  editor.addHook('afterCreateRow', function(insertRowIndex, amount, source) {
209
  var selectedCell = editor.getSelected(),
220
  data = editor.getData();
221
 
222
  setTimeout(function() {
 
 
 
 
 
223
  if (amount > 1) {
224
+ var merge = editor.getPlugin('mergeCells').mergedCellsCollection.mergedCells;
225
  for (var c = 0; c < merge.length; c++) {
226
  if (merge[c].row >= insertRowIndex) {
227
  merge[c].row += amount - 1;
275
  selectedColumnIndex = selectedCell[(isMin == 1 ? 3 : 1)];
276
  }
277
  }
278
+ if(source == 'UndoRedo.undo') {
279
+ amount = amount - insertColumnIndex + 1;
280
+ if(amount <= 0) amount = 1;
281
+ }
282
  var j = (insertColumnIndex <= selectedColumnIndex ? insertColumnIndex + amount : selectedColumnIndex);
283
  setTimeout(function() {
 
 
 
 
 
 
284
  if (amount > 1) {
285
+ var merge = editor.getPlugin('mergeCells').mergedCellsCollection.mergedCells;
286
  for (var i = 0; i < merge.length; i++) {
287
  if (merge[i].col >= insertColumnIndex) {
288
  merge[i].col += amount - 1;
321
  updateUndoRedoBtns();
322
  });
323
  editor.addHook('beforeRemoveRow', function (from, amount) {
324
+ var merge = editor.getPlugin('mergeCells').mergedCellsCollection.mergedCells,
325
  to = from + amount - 1,
326
  cntMerge = merge.length;
327
  for (var i = cntMerge - 1; i >= 0; i--) {
390
  updateUndoRedoBtns();
391
  });
392
  editor.addHook('beforeRemoveCol', function (from, amount) {
393
+ var merge = editor.getPlugin('mergeCells').mergedCellsCollection.mergedCells,
394
  to = from + amount - 1,
395
  cntMerge = merge.length;
396
  for (var i = cntMerge - 1; i >= 0; i--) {
505
  j = 0;
506
  }
507
  if(g_stbCopyPasteCellsMetaData[j]) {
508
+ var value = editor.getSourceDataAtCell(g_stbCopyPasteCellsMetaData[j].row, g_stbCopyPasteCellsMetaData[j].col);
 
509
  if(value && value[0] == '=') {
510
  var deltaRow = row - g_stbCopyPasteCellsMetaData[j].row,
511
  deltaCol = col - g_stbCopyPasteCellsMetaData[j].col,
571
  editor.allWidths = typeof(editor.getSettings().colWidths) == 'object' ? editor.getSettings().colWidths : [];
572
  }
573
  }
574
+ function checkEditfileCells(){
575
+ setTimeout(function(){
576
+ var needRecalc = false;
577
+ editor.selectCell(0,0, editor.countRows() - 1, editor.countCols() - 1);
578
+ var range = editor.getSelectedRangeLast();
579
+ if (range === undefined) {
580
+ return;
581
+ }
582
+ for(var i = range.from.row; i <= range.to.row; i++) {
583
+ for(var j = range.from.col; j <= range.to.col; j++) {
584
+ var value = editor.getDataAtCell(i, j)
585
+ , td = editor.getCell(i, j);
586
+ if ($(td).hasClass('editfile') && value.indexOf('%3C') > -1) {
587
+ editor.setDataAtCell(i, j, decodeURI(value));
588
+ needRecalc = true;
589
+ }
590
+ }
591
+ }
592
+ editor.deselectCell();
593
+ if (needRecalc) {
594
+ setTimeout(function(){
595
+ editor.updateSettings({
596
+ manualRowResize: true,
597
+ colHeaders: true
598
+ });
599
+ editor.renderWithRecalc();
600
+ },10);
601
+ } else {
602
+ editor.render();
603
+ }
604
+ },1000);
605
+ }
606
  function updateUndoRedoBtns() {
607
  if(editor.undoRedo) {
608
  var undo = $('[data-method="undo"]'),
756
  start = this.pageStart,
757
  stop = this.pageStop,
758
  data = this.getData(),
759
+ merge = this.getPlugin('mergeCells').mergedCellsCollection.mergedCells;
760
  real = 0;
761
 
762
  for (var row = 0; row < countRows; row++) {
src/SupsysticTables/Tables/assets/js/editor/tables.editor.toolbar.js CHANGED
@@ -17,6 +17,26 @@ var g_stbCellBgColorTimeoutSet = false,
17
 
18
  // Toolbar methods
19
  var methods = {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
20
  bold: function () {
21
  this.toggleClass('bold');
22
  this.getEditor().render();
@@ -78,57 +98,66 @@ var g_stbCellBgColorTimeoutSet = false,
78
  var classNames = this.getCellsClassNames();
79
  this.replaceClass('htLeft', ['htLeft', 'htCenter', 'htRight']);
80
  //run hook for correct work of undo/redo actions instead of use editor.getPlugin("contextMenu").executeCommand();
81
- this.getEditor().runHooks('beforeCellAlignment', classNames, this.getEditor().getSelectedRange(), 'horizontal', 'htLeft');
82
  this.getEditor().render();
83
  },
84
  right: function () {
85
  var classNames = this.getCellsClassNames();
86
  this.replaceClass('htRight', ['htLeft', 'htCenter', 'htRight']);
87
  //run hook for correct work of undo/redo actions instead of use editor.getPlugin("contextMenu").executeCommand();
88
- this.getEditor().runHooks('beforeCellAlignment', classNames, this.getEditor().getSelectedRange(), 'horizontal', 'htRight');
89
  this.getEditor().render();
90
  },
91
  center: function () {
92
  var classNames = this.getCellsClassNames();
93
  this.replaceClass('htCenter', ['htLeft', 'htCenter', 'htRight']);
94
  //run hook for correct work of undo/redo actions instead of use editor.getPlugin("contextMenu").executeCommand();
95
- this.getEditor().runHooks('beforeCellAlignment', classNames, this.getEditor().getSelectedRange(), 'horizontal', 'htCenter');
96
  this.getEditor().render();
97
  },
98
  top: function () {
99
  var classNames = this.getCellsClassNames();
100
  this.replaceClass('htTop', ['htTop', 'htMiddle', 'htBottom']);
101
  //run hook for correct work of undo/redo actions instead of use editor.getPlugin("contextMenu").executeCommand();
102
- this.getEditor().runHooks('beforeCellAlignment', classNames, this.getEditor().getSelectedRange(), 'vertical', 'htTop');
103
  this.getEditor().render();
104
  },
105
  middle: function () {
106
  var classNames = this.getCellsClassNames();
107
  this.replaceClass('htMiddle', ['htTop', 'htMiddle', 'htBottom']);
108
  //run hook for correct work of undo/redo actions instead of use editor.getPlugin("contextMenu").executeCommand();
109
- this.getEditor().runHooks('beforeCellAlignment', classNames, this.getEditor().getSelectedRange(), 'vertical', 'htMiddle');
110
  this.getEditor().render();
111
  },
112
  bottom: function () {
113
  var classNames = this.getCellsClassNames();
114
  this.replaceClass('htBottom', ['htTop', 'htMiddle', 'htBottom']);
115
  //run hook for correct work of undo/redo actions instead of use editor.getPlugin("contextMenu").executeCommand();
116
- this.getEditor().runHooks('beforeCellAlignment', classNames, this.getEditor().getSelectedRange(), 'vertical', 'htBottom');
117
  this.getEditor().render();
118
  },
119
  row: function () {
120
  var editor = this.getEditor(),
121
- selection = editor.getSelectedRange();
122
 
123
  if (selection === undefined) {
124
  editor.alter('insert_row', editor.countRows(), 1);
 
125
  } else {
126
  editor.alter('insert_row', selection.from.row, selection.to.row - selection.from.row + 1);
 
127
  }
 
 
 
 
 
 
 
128
  },
129
  column: function () {
130
  var editor = this.getEditor(),
131
- selection = editor.getSelectedRange();
132
 
133
  if (selection === undefined) {
134
  editor.alter('insert_col', editor.countCols(), 1);
@@ -137,7 +166,7 @@ var g_stbCellBgColorTimeoutSet = false,
137
  }
138
  },
139
  remove_row: function () {
140
- var selection = this.getEditor().getSelectedRange();
141
 
142
  if (selection === undefined) {
143
  return;
@@ -155,7 +184,7 @@ var g_stbCellBgColorTimeoutSet = false,
155
  this.getEditor().alter('remove_row', selection.from.row, amount);
156
  },
157
  remove_col: function () {
158
- var selection = this.getEditor().getSelectedRange();
159
 
160
  if (selection === undefined) {
161
  return;
@@ -171,11 +200,14 @@ var g_stbCellBgColorTimeoutSet = false,
171
  }
172
 
173
  this.getEditor().alter("remove_col", selection.from.col, amount);
 
 
 
174
  },
175
  link: function () {
176
  var toolbar = this,
177
  editor = this.getEditor(),
178
- selection = editor.getSelectedRange();
179
 
180
  if (!selection) {
181
  alert('You must select a cell to insert link.');
@@ -193,6 +225,9 @@ var g_stbCellBgColorTimeoutSet = false,
193
 
194
  textForPopup = $('<div>' + textForPopup + '</div>').html();
195
  $(this).find('.link-text').val(textForPopup);
 
 
 
196
  },
197
  close: function() {
198
  var $this = $(this);
@@ -228,7 +263,7 @@ var g_stbCellBgColorTimeoutSet = false,
228
  media: function (event) {
229
  var self = this,
230
  editor = this.getEditor(),
231
- selection = editor.getSelectedRange(),
232
  highlighted = selection === undefined ? { col: 0, row: 0 } : selection.highlight,
233
  url;
234
 
@@ -257,21 +292,28 @@ var g_stbCellBgColorTimeoutSet = false,
257
  },
258
  addEditComment: function () {
259
  var e = this.getEditor(),
260
- coords = e.getSelectedRange(),
261
  comments = e.getPlugin('comments');
262
 
 
 
263
  if (coords) {
264
  e.deselectCell();
265
  comments.contextMenuEvent = true;
266
  comments.setRange({ from: coords.from });
267
- comments.show();
268
- comments.editor.focus();
 
 
 
 
 
269
  }
270
  },
271
  removeComment: function () {
272
  var e = this.getEditor(),
273
  comments = e.getPlugin('comments'),
274
- selection = this.getValidRange(e.getSelectedRange());
275
 
276
  if (selection) {
277
  comments.contextMenuEvent = true;
@@ -280,8 +322,20 @@ var g_stbCellBgColorTimeoutSet = false,
280
  },
281
  merge: function () {
282
  var e = this.getEditor();
283
- e.mergeCells.mergeOrUnmergeSelection(e.getSelectedRange());
 
284
  e.render();
 
 
 
 
 
 
 
 
 
 
 
285
  },
286
  'word-wrap-default': function() {
287
  this.replaceClass('', ['ww-v', 'ww-h']);
@@ -402,7 +456,7 @@ var g_stbCellBgColorTimeoutSet = false,
402
  };
403
  Toolbar.prototype.toggleClass = function (className) {
404
  var editor = this.getEditor(),
405
- range = this.getValidRange(editor.getSelectedRange());
406
 
407
  if (range === undefined) {
408
  return;
@@ -471,7 +525,7 @@ var g_stbCellBgColorTimeoutSet = false,
471
  };
472
  Toolbar.prototype.replaceClass = function (className, replace, highlight) {
473
  var editor = this.getEditor(),
474
- range = this.getValidRange(editor.getSelectedRange()),
475
  replPattern;
476
 
477
  if (range === undefined) {
@@ -527,7 +581,7 @@ var g_stbCellBgColorTimeoutSet = false,
527
  };
528
  Toolbar.prototype.removeClass = function (className, highlight) {
529
  var editor = this.getEditor(),
530
- range = this.getValidRange(editor.getSelectedRange());
531
 
532
  if (range === undefined) {
533
  return;
@@ -663,7 +717,7 @@ var g_stbCellBgColorTimeoutSet = false,
663
  Toolbar.prototype.setFormat = function (formatType, format) {
664
  var tablesModel = app.Models.Tables,
665
  editor = this.getEditor(),
666
- range = this.getValidRange(editor.getSelectedRange());
667
 
668
  if (range === undefined) {
669
  return;
@@ -671,7 +725,8 @@ var g_stbCellBgColorTimeoutSet = false,
671
  for (var row = range.from.row; row <= range.to.row; row++) {
672
  for (var col = range.from.col; col <= range.to.col; col++) {
673
  var cell = editor.getCellMeta(row, col),
674
- data = editor.getDataAtCell(row, col),
 
675
  cellType = !cell.type || cell.type != 'dropdown' ? 'text' : cell.type,
676
  cellFormat = format || '',
677
  cellFormatType = formatType;
@@ -681,9 +736,10 @@ var g_stbCellBgColorTimeoutSet = false,
681
  delete cell.validator;
682
 
683
  // Fix cell value if we switch cell type from Percent to Another One
684
- if (formatType != 'percent' && cell.formatType == 'percent') {
685
  if (!tablesModel.isFormula(data)) {
686
- data = data * 100;
 
687
  }
688
  }
689
  switch(formatType) {
@@ -777,6 +833,7 @@ var g_stbCellBgColorTimeoutSet = false,
777
  methods[method].apply(self, [e]);
778
  // Close toolbar
779
  $('body').trigger('click');
 
780
  });
781
  }
782
 
@@ -875,7 +932,7 @@ var g_stbCellBgColorTimeoutSet = false,
875
  };
876
  Toolbar.prototype.getCellsClassNames = function() {
877
  var editor = this.getEditor(),
878
- range = this.getValidRange(editor.getSelectedRange()),
879
  classNames = [];
880
 
881
  if (range === undefined) {
17
 
18
  // Toolbar methods
19
  var methods = {
20
+ updateUndoRedoToolbarBtns: function(){
21
+ var editor = this.getEditor();
22
+ if(editor.undoRedo) {
23
+ var undo = $('[data-method="undo"]'),
24
+ redo = $('[data-method="redo"]');
25
+
26
+ setTimeout(function() {
27
+ if(editor.undoRedo.isUndoAvailable()) {
28
+ undo.removeClass('inactive');
29
+ } else {
30
+ undo.addClass('inactive');
31
+ }
32
+ if(editor.undoRedo.isRedoAvailable()) {
33
+ redo.removeClass('inactive');
34
+ } else {
35
+ redo.addClass('inactive');
36
+ }
37
+ }, 100);
38
+ }
39
+ },
40
  bold: function () {
41
  this.toggleClass('bold');
42
  this.getEditor().render();
98
  var classNames = this.getCellsClassNames();
99
  this.replaceClass('htLeft', ['htLeft', 'htCenter', 'htRight']);
100
  //run hook for correct work of undo/redo actions instead of use editor.getPlugin("contextMenu").executeCommand();
101
+ this.getEditor().runHooks('beforeCellAlignment', classNames, this.getEditor().getSelectedRange()[0], 'horizontal', 'htLeft');
102
  this.getEditor().render();
103
  },
104
  right: function () {
105
  var classNames = this.getCellsClassNames();
106
  this.replaceClass('htRight', ['htLeft', 'htCenter', 'htRight']);
107
  //run hook for correct work of undo/redo actions instead of use editor.getPlugin("contextMenu").executeCommand();
108
+ this.getEditor().runHooks('beforeCellAlignment', classNames, this.getEditor().getSelectedRange()[0], 'horizontal', 'htRight');
109
  this.getEditor().render();
110
  },
111
  center: function () {
112
  var classNames = this.getCellsClassNames();
113
  this.replaceClass('htCenter', ['htLeft', 'htCenter', 'htRight']);
114
  //run hook for correct work of undo/redo actions instead of use editor.getPlugin("contextMenu").executeCommand();
115
+ this.getEditor().runHooks('beforeCellAlignment', classNames, this.getEditor().getSelectedRange()[0], 'horizontal', 'htCenter');
116
  this.getEditor().render();
117
  },
118
  top: function () {
119
  var classNames = this.getCellsClassNames();
120
  this.replaceClass('htTop', ['htTop', 'htMiddle', 'htBottom']);
121
  //run hook for correct work of undo/redo actions instead of use editor.getPlugin("contextMenu").executeCommand();
122
+ this.getEditor().runHooks('beforeCellAlignment', classNames, this.getEditor().getSelectedRange()[0], 'vertical', 'htTop');
123
  this.getEditor().render();
124
  },
125
  middle: function () {
126
  var classNames = this.getCellsClassNames();
127
  this.replaceClass('htMiddle', ['htTop', 'htMiddle', 'htBottom']);
128
  //run hook for correct work of undo/redo actions instead of use editor.getPlugin("contextMenu").executeCommand();
129
+ this.getEditor().runHooks('beforeCellAlignment', classNames, this.getEditor().getSelectedRange()[0], 'vertical', 'htMiddle');
130
  this.getEditor().render();
131
  },
132
  bottom: function () {
133
  var classNames = this.getCellsClassNames();
134
  this.replaceClass('htBottom', ['htTop', 'htMiddle', 'htBottom']);
135
  //run hook for correct work of undo/redo actions instead of use editor.getPlugin("contextMenu").executeCommand();
136
+ this.getEditor().runHooks('beforeCellAlignment', classNames, this.getEditor().getSelectedRange()[0], 'vertical', 'htBottom');
137
  this.getEditor().render();
138
  },
139
  row: function () {
140
  var editor = this.getEditor(),
141
+ selection = editor.getSelectedRangeLast();
142
 
143
  if (selection === undefined) {
144
  editor.alter('insert_row', editor.countRows(), 1);
145
+ var startRow = editor.countRows() - 1;
146
  } else {
147
  editor.alter('insert_row', selection.from.row, selection.to.row - selection.from.row + 1);
148
+ var startRow = selection.from.row - 1;
149
  }
150
+
151
+ setTimeout(function(){
152
+ editor.getPlugin('comments').contextMenuEvent = true;
153
+ for (var i = 0, n = editor.countCols(); i < n; i++) {
154
+ editor.getPlugin('comments').removeCommentAtCell(startRow, i);
155
+ }
156
+ },500);
157
  },
158
  column: function () {
159
  var editor = this.getEditor(),
160
+ selection = editor.getSelectedRangeLast();
161
 
162
  if (selection === undefined) {
163
  editor.alter('insert_col', editor.countCols(), 1);
166
  }
167
  },
168
  remove_row: function () {
169
+ var selection = this.getEditor().getSelectedRangeLast();
170
 
171
  if (selection === undefined) {
172
  return;
184
  this.getEditor().alter('remove_row', selection.from.row, amount);
185
  },
186
  remove_col: function () {
187
+ var selection = this.getEditor().getSelectedRangeLast();
188
 
189
  if (selection === undefined) {
190
  return;
200
  }
201
 
202
  this.getEditor().alter("remove_col", selection.from.col, amount);
203
+ this.getEditor().updateSettings({
204
+ height: $('.ht_master .wtHider').height()
205
+ });
206
  },
207
  link: function () {
208
  var toolbar = this,
209
  editor = this.getEditor(),
210
+ selection = editor.getSelectedRange()[0];
211
 
212
  if (!selection) {
213
  alert('You must select a cell to insert link.');
225
 
226
  textForPopup = $('<div>' + textForPopup + '</div>').html();
227
  $(this).find('.link-text').val(textForPopup);
228
+ setTimeout(function(){
229
+ $('#insertUrlDialog').find('.link-target').focus();
230
+ },50);
231
  },
232
  close: function() {
233
  var $this = $(this);
263
  media: function (event) {
264
  var self = this,
265
  editor = this.getEditor(),
266
+ selection = editor.getSelectedRange()[0],
267
  highlighted = selection === undefined ? { col: 0, row: 0 } : selection.highlight,
268
  url;
269
 
292
  },
293
  addEditComment: function () {
294
  var e = this.getEditor(),
295
+ coords = e.getSelectedRangeLast(),
296
  comments = e.getPlugin('comments');
297
 
298
+ $('#row-tab-editor').css({'pointer-events': 'none'});
299
+
300
  if (coords) {
301
  e.deselectCell();
302
  comments.contextMenuEvent = true;
303
  comments.setRange({ from: coords.from });
304
+ setTimeout(function(){
305
+ comments.showAtCell(coords.from.row, coords.from.col);
306
+ comments.editor.focus();
307
+ $('#row-tab-editor').css({'pointer-events': ''});
308
+ },1000);
309
+ } else {
310
+ $('#row-tab-editor').css({'pointer-events': ''});
311
  }
312
  },
313
  removeComment: function () {
314
  var e = this.getEditor(),
315
  comments = e.getPlugin('comments'),
316
+ selection = this.getValidRange(e.getSelectedRangeLast());
317
 
318
  if (selection) {
319
  comments.contextMenuEvent = true;
322
  },
323
  merge: function () {
324
  var e = this.getEditor();
325
+ e.getPlugin('mergeCells').toggleMergeOnSelection(e.getSelectedRange());
326
+
327
  e.render();
328
+ var aMergeCells = e.getPlugin('mergeCells').mergedCellsCollection.mergedCells;
329
+ if (aMergeCells) {
330
+ var tmpMergeCells = aMergeCells.map(function(item){
331
+ delete item.removed;
332
+ return item;
333
+ });
334
+
335
+ e.updateSettings({
336
+ mergeCells: tmpMergeCells
337
+ });
338
+ }
339
  },
340
  'word-wrap-default': function() {
341
  this.replaceClass('', ['ww-v', 'ww-h']);
456
  };
457
  Toolbar.prototype.toggleClass = function (className) {
458
  var editor = this.getEditor(),
459
+ range = this.getValidRange(editor.getSelectedRange()[0]);
460
 
461
  if (range === undefined) {
462
  return;
525
  };
526
  Toolbar.prototype.replaceClass = function (className, replace, highlight) {
527
  var editor = this.getEditor(),
528
+ range = this.getValidRange(editor.getSelectedRange()[0]),
529
  replPattern;
530
 
531
  if (range === undefined) {
581
  };
582
  Toolbar.prototype.removeClass = function (className, highlight) {
583
  var editor = this.getEditor(),
584
+ range = this.getValidRange(editor.getSelectedRange()[0]);
585
 
586
  if (range === undefined) {
587
  return;
717
  Toolbar.prototype.setFormat = function (formatType, format) {
718
  var tablesModel = app.Models.Tables,
719
  editor = this.getEditor(),
720
+ range = this.getValidRange(editor.getSelectedRangeLast());
721
 
722
  if (range === undefined) {
723
  return;
725
  for (var row = range.from.row; row <= range.to.row; row++) {
726
  for (var col = range.from.col; col <= range.to.col; col++) {
727
  var cell = editor.getCellMeta(row, col),
728
+ //data = editor.getDataAtCell(row, col),
729
+ data = editor.getSourceDataAtCell(row, col),
730
  cellType = !cell.type || cell.type != 'dropdown' ? 'text' : cell.type,
731
  cellFormat = format || '',
732
  cellFormatType = formatType;
736
  delete cell.validator;
737
 
738
  // Fix cell value if we switch cell type from Percent to Another One
739
+ if (formatType != 'percent' && cell.formatType == 'percent' && formatType != 'currency' && cell.formatType == 'currency') {
740
  if (!tablesModel.isFormula(data)) {
741
+ data += "";
742
+ data = data.indexOf('.') > -1 ? data * 100 : data;
743
  }
744
  }
745
  switch(formatType) {
833
  methods[method].apply(self, [e]);
834
  // Close toolbar
835
  $('body').trigger('click');
836
+ methods['updateUndoRedoToolbarBtns'].apply(self, [e]);
837
  });
838
  }
839
 
932
  };
933
  Toolbar.prototype.getCellsClassNames = function() {
934
  var editor = this.getEditor(),
935
+ range = this.getValidRange(editor.getSelectedRangeLast()),
936
  classNames = [];
937
 
938
  if (range === undefined) {
src/SupsysticTables/Tables/assets/js/tables.model.js CHANGED
@@ -470,6 +470,7 @@ var g_stbPreviewTimeoutSet = false;
470
  if(lastSave == false && !rerender && !g_stbNeedPreview) return;
471
  //g_stbPreviewTable = '';
472
  $table.find('.dataTables_processing').css('display', 'block');
 
473
  }
474
  else {
475
  $(preview).html($('<i/>', { class: 'fa fa-spinner fa-spin' }).attr('style','font-size: 2em !important')).prepend('<label> Table generate in process.... </label>');
@@ -498,9 +499,11 @@ var g_stbPreviewTimeoutSet = false;
498
  var currentRow = { cells: [] };
499
  rowCounter++;
500
 
501
- $.each(row, function (y, cell) {
502
  var meta = (pagination ? bufferMeta[x * countCols + y] : editor.getCellMeta(x, y)),
503
- metaClasses = meta.className;
 
 
504
 
505
  if (typeof(metaClasses) != 'undefined' && metaClasses.indexOf(svlFormatsClass) !== -1) {
506
  metaClasses = metaClasses.replace(svlFormatsClass, '').trim();
@@ -513,6 +516,7 @@ var g_stbPreviewTimeoutSet = false;
513
  }
514
  }
515
  }
 
516
  var cellHtml = (pagination ? bufferData[x][y] : $(editor.getCell(x, y))),
517
  classes = [],
518
  cellData = {
@@ -523,10 +527,10 @@ var g_stbPreviewTimeoutSet = false;
523
  hiddenCell: metaClasses && metaClasses.match('hiddenCell') !== null,
524
  invisibleCell: metaClasses && metaClasses.match('invisibleCell') !== null
525
  },
526
- mergeCell = (pagination ? editor.mergeGetInfo(x, y) : editor.mergeCells.mergedCellInfoCollection.getInfo(x, y));
527
 
528
  // set merged params
529
- if(mergeCell !== undefined) {
530
  cellData.hidden = true;
531
  }
532
  if(!pagination)
@@ -643,9 +647,9 @@ var g_stbPreviewTimeoutSet = false;
643
  if(pagination) {
644
  mergeData = bufferMerge;
645
  } else {
646
- if(editor.mergeCells.mergedCellInfoCollection.length) {
647
- for(var i = 0; i < editor.mergeCells.mergedCellInfoCollection.length; i++) {
648
- mergeData.push(editor.mergeCells.mergedCellInfoCollection[i]);
649
  }
650
  }
651
  }
@@ -790,10 +794,11 @@ var g_stbPreviewTimeoutSet = false;
790
  tableInstance.api().destroy();
791
  app.removeTableInstanceByViewId(tableInstance.data('view-id'));
792
  }
793
- //previewContainer.empty().append($(g_stbPreviewTable));
794
  table = preview.find('table');
795
  if(table.length == 0) return;
796
-
 
 
797
  app.setTableMobileWidth(g_stbMobilePreview);
798
 
799
  app.initializeTable(table, app.showTable, function(table) {
@@ -807,7 +812,7 @@ var g_stbPreviewTimeoutSet = false;
807
  app.initExportTable();
808
  }
809
  });
810
- }
811
 
812
  TablesModel.prototype.getCssText = function(rule) {
813
  var value = rule.cssText ? rule.cssText : rule.style.cssText;
@@ -963,7 +968,7 @@ var g_stbPreviewTimeoutSet = false;
963
  if (isNaN(id = parseInt(id))) {
964
  throw new Error('Invalid table id.');
965
  }
966
- return this.request('render', { id: id, settings: typeof(settings) == 'undefined' ? false : settings, preview: '1' });
967
  };
968
 
969
  TablesModel.prototype.renderFromHistory = function (userId, tableId, period) {
@@ -1022,7 +1027,7 @@ var g_stbPreviewTimeoutSet = false;
1022
  TablesModel.prototype.getFormulaResult = function (value, row, col) {
1023
  var instance = app.Editor.Hot;
1024
 
1025
- if (instance.formulasEnabled && this.isFormula(value)) {
1026
  // translate coordinates into cellId
1027
  var cellId = instance.plugin.utils.translateCellCoords({row: row, col: col}),
1028
  prevFormula = null,
470
  if(lastSave == false && !rerender && !g_stbNeedPreview) return;
471
  //g_stbPreviewTable = '';
472
  $table.find('.dataTables_processing').css('display', 'block');
473
+ $('#settings').css({pointerEvents:'none'});
474
  }
475
  else {
476
  $(preview).html($('<i/>', { class: 'fa fa-spinner fa-spin' }).attr('style','font-size: 2em !important')).prepend('<label> Table generate in process.... </label>');
499
  var currentRow = { cells: [] };
500
  rowCounter++;
501
 
502
+ $.each(row, function (y) {
503
  var meta = (pagination ? bufferMeta[x * countCols + y] : editor.getCellMeta(x, y)),
504
+ metaClasses = meta.className,
505
+ row = editor.toPhysicalRow(x),
506
+ cell = (pagination ? bufferData[x][y] : editor.getSourceDataAtCell(row,y));
507
 
508
  if (typeof(metaClasses) != 'undefined' && metaClasses.indexOf(svlFormatsClass) !== -1) {
509
  metaClasses = metaClasses.replace(svlFormatsClass, '').trim();
516
  }
517
  }
518
  }
519
+
520
  var cellHtml = (pagination ? bufferData[x][y] : $(editor.getCell(x, y))),
521
  classes = [],
522
  cellData = {
527
  hiddenCell: metaClasses && metaClasses.match('hiddenCell') !== null,
528
  invisibleCell: metaClasses && metaClasses.match('invisibleCell') !== null
529
  },
530
+ mergeCell = (pagination ? editor.mergeGetInfo(x, y) : editor.getPlugin('mergeCells').mergedCellsCollection.get(x, y));
531
 
532
  // set merged params
533
+ if(mergeCell !== undefined && mergeCell !== false) {
534
  cellData.hidden = true;
535
  }
536
  if(!pagination)
647
  if(pagination) {
648
  mergeData = bufferMerge;
649
  } else {
650
+ if(editor.getPlugin('mergeCells').mergedCellsCollection.mergedCells.length) {
651
+ for(var i = 0; i < editor.getPlugin('mergeCells').mergedCellsCollection.mergedCells.length; i++) {
652
+ mergeData.push(editor.getPlugin('mergeCells').mergedCellsCollection.mergedCells[i]);
653
  }
654
  }
655
  }
794
  tableInstance.api().destroy();
795
  app.removeTableInstanceByViewId(tableInstance.data('view-id'));
796
  }
 
797
  table = preview.find('table');
798
  if(table.length == 0) return;
799
+ if(g_stbServerSideProcessing) {
800
+ table.find('tbody').empty();
801
+ }
802
  app.setTableMobileWidth(g_stbMobilePreview);
803
 
804
  app.initializeTable(table, app.showTable, function(table) {
812
  app.initExportTable();
813
  }
814
  });
815
+ };
816
 
817
  TablesModel.prototype.getCssText = function(rule) {
818
  var value = rule.cssText ? rule.cssText : rule.style.cssText;
968
  if (isNaN(id = parseInt(id))) {
969
  throw new Error('Invalid table id.');
970
  }
971
+ return this.request('render', { id: id, settings: typeof(settings) == 'undefined' ? false : settings, preview: '1' }).done(function(){setTimeout(function(){$('#settings').css({pointerEvents:'auto'});},700)});
972
  };
973
 
974
  TablesModel.prototype.renderFromHistory = function (userId, tableId, period) {
1027
  TablesModel.prototype.getFormulaResult = function (value, row, col) {
1028
  var instance = app.Editor.Hot;
1029
 
1030
+ if (instance.getPlugin('Formulas').isEnabled() && this.isFormula(value)) {
1031
  // translate coordinates into cellId
1032
  var cellId = instance.plugin.utils.translateCellCoords({row: row, col: col}),
1033
  prevFormula = null,
src/SupsysticTables/Tables/assets/js/tables.view.js CHANGED
@@ -57,6 +57,12 @@ var g_stbCopyPasteColsCount = [];
57
  }
58
  });
59
 
 
 
 
 
 
 
60
  // Initialize Sub Tabs
61
  var linksOyPositions = [],
62
  settingsSection = $('.settings-section');
@@ -211,6 +217,16 @@ var g_stbCopyPasteColsCount = [];
211
  }
212
  });
213
 
 
 
 
 
 
 
 
 
 
 
214
  // Dialog Windows
215
  g_stbColumnWidthDialog = $('#setColumnWidthDialog').dialog({
216
  autoOpen: false,
@@ -232,6 +248,9 @@ var g_stbCopyPasteColsCount = [];
232
  $this.find('.fixedColumnWidthDataLabel').show();
233
  }
234
  $this.find('#fixedColumnWidthData').html(fixedColumnWidthData);
 
 
 
235
  },
236
  close: function() {
237
  var $this = $(this);
@@ -241,13 +260,17 @@ var g_stbCopyPasteColsCount = [];
241
  Apply: function () {
242
  var $this = $(this),
243
  editor = window.editor,
244
- selection = editor.getSelectedRange(),
245
  value = $this.find('input[name="columnWidth"]').val(),
246
  valueType = $this.find('input[name="columnWidthType"]:checked').val();
247
  if(value) {
248
  for(var i = selection.from.col; i <= selection.to.col; i++) {
249
- g_stbFixedColumnsWidth[i] = value + valueType;
250
  }
 
 
 
 
251
  }
252
  $(this).dialog('close');
253
  },
@@ -300,7 +323,7 @@ var g_stbCopyPasteColsCount = [];
300
  Apply: function () {
301
  var $this = $(this),
302
  editor = window.editor,
303
- selection = editor.getSelectedRange(),
304
  order = $this.find('input[name="columnSortOrder"]:checked').val(),
305
  exists = false;
306
  for(var i = selection.from.col; i <= selection.to.col; i++) {
@@ -415,40 +438,44 @@ var g_stbCopyPasteColsCount = [];
415
  buttons: {
416
  'Add Button': function (e) {
417
  var editor = app.Editor.Hot,
418
- range = editor.getSelectedRange();
419
 
420
  if (range === undefined) {
421
  return;
422
  }
423
- var shell = $('#addContactFormBtnDialog'),
424
- url = shell.find('[name="posts_list"]').val(),
425
- urlArr = url.split('?'),
426
- text = shell.find('[name="btn_text"]').val() || 'Button',
427
- classes = shell.find('[name="btn_class"]').val(),
428
- styles = shell.find('[name="btn_style"]').val(),
429
- target = shell.find('[name="btn_target"]').is(':checked'),
430
- fields = shell.find('.contactFormFieldsShell .columnName'),
431
- symbol = urlArr.length > 1 ? '&' : '?',
432
- link = url+symbol+'cfsPreFill=1',
433
- btn = '';
434
- for(var i = 0; i < fields.length; i++) {
435
- var f = $(fields[i]);
436
- if(f.val()) {
437
- var label = f.parents('.contactFormFieldRow').find('[name="field_name"]').val();
438
- link += '&cfs_'+label+'='+f.val();
439
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
440
  }
441
- btn += '<a href="'+link+'"';
442
- btn += target ? ' target="_blank"' : '';
443
- btn += classes ? ' class="'+classes+'"' : '';
444
- btn += styles ? ' style="'+styles+'"' : '';
445
- btn += '>'+text+'</a>';
446
- for(var row = range.from.row; row <= range.to.row; row++) {
447
- for (var col = range.from.col; col <= range.to.col; col++) {
448
- editor.setDataAtCell(row, col, btn);
449
- }
450
- }
451
- $(this).dialog('close');
452
  },
453
  Cancel: function () {
454
  $(this).dialog('close');
57
  }
58
  });
59
 
60
+ editor.addHook('afterLoadData', function () {
61
+ editor.updateSettings({
62
+ dropdownMenu: true,
63
+ });
64
+ });
65
+
66
  // Initialize Sub Tabs
67
  var linksOyPositions = [],
68
  settingsSection = $('.settings-section');
217
  }
218
  });
219
 
220
+ // Fit to data option
221
+ $('input[name="columnWidthType"]').on('change ifChanged', function(){
222
+ var valueType = $(this).find('input[name="columnWidthType"]:checked').val();
223
+ if (valueType == 'auto') {
224
+ $('input[name="columnWidth"]').prop('disabled',true);
225
+ } else {
226
+ $('input[name="columnWidth"]').removeAttr('disabled');
227
+ }
228
+ });
229
+
230
  // Dialog Windows
231
  g_stbColumnWidthDialog = $('#setColumnWidthDialog').dialog({
232
  autoOpen: false,
248
  $this.find('.fixedColumnWidthDataLabel').show();
249
  }
250
  $this.find('#fixedColumnWidthData').html(fixedColumnWidthData);
251
+ setTimeout(function(){
252
+ $this.find('#fixed-column-width-type-percent').focus();
253
+ },50);
254
  },
255
  close: function() {
256
  var $this = $(this);
260
  Apply: function () {
261
  var $this = $(this),
262
  editor = window.editor,
263
+ selection = editor.getSelectedRange()[0],
264
  value = $this.find('input[name="columnWidth"]').val(),
265
  valueType = $this.find('input[name="columnWidthType"]:checked').val();
266
  if(value) {
267
  for(var i = selection.from.col; i <= selection.to.col; i++) {
268
+ g_stbFixedColumnsWidth[i] = (valueType === 'auto') ? valueType : value + valueType;
269
  }
270
+ } else if (valueType === 'auto') {
271
+ for(var i = selection.from.col; i <= selection.to.col; i++) {
272
+ g_stbFixedColumnsWidth[i] = valueType;
273
+ }
274
  }
275
  $(this).dialog('close');
276
  },
323
  Apply: function () {
324
  var $this = $(this),
325
  editor = window.editor,
326
+ selection = editor.getSelectedRange()[0],
327
  order = $this.find('input[name="columnSortOrder"]:checked').val(),
328
  exists = false;
329
  for(var i = selection.from.col; i <= selection.to.col; i++) {
438
  buttons: {
439
  'Add Button': function (e) {
440
  var editor = app.Editor.Hot,
441
+ range = editor.getSelectedRangeLast();
442
 
443
  if (range === undefined) {
444
  return;
445
  }
446
+ if ($('#addContactFormBtnDialog').find('[name="posts_list"]').length) {
447
+ var shell = $('#addContactFormBtnDialog'),
448
+ url = shell.find('[name="posts_list"]').val(),
449
+ urlArr = url.split('?'),
450
+ text = shell.find('[name="btn_text"]').val() || 'Button',
451
+ classes = shell.find('[name="btn_class"]').val(),
452
+ styles = shell.find('[name="btn_style"]').val(),
453
+ target = shell.find('[name="btn_target"]').is(':checked'),
454
+ fields = shell.find('.contactFormFieldsShell .columnName'),
455
+ symbol = urlArr.length > 1 ? '&' : '?',
456
+ link = url + symbol + 'cfsPreFill=1',
457
+ btn = '';
458
+ for (var i = 0; i < fields.length; i++) {
459
+ var f = $(fields[i]);
460
+ if (f.val()) {
461
+ var label = f.parents('.contactFormFieldRow').find('[name="field_name"]').val();
462
+ link += '&cfs_' + label + '=' + f.val();
463
+ }
464
+ }
465
+ btn += '<a href="' + link + '"';
466
+ btn += target ? ' target="_blank"' : '';
467
+ btn += classes ? ' class="' + classes + '"' : '';
468
+ btn += styles ? ' style="' + styles + '"' : '';
469
+ btn += '>' + text + '</a>';
470
+ for (var row = range.from.row; row <= range.to.row; row++) {
471
+ for (var col = range.from.col; col <= range.to.col; col++) {
472
+ editor.setDataAtCell(row, col, btn);
473
+ }
474
+ }
475
+ $(this).dialog('close');
476
+ } else {
477
+ window.open('https://supsystic.com/plugins/contact-form-plugin/','_blank');
478
  }
 
 
 
 
 
 
 
 
 
 
 
479
  },
480
  Cancel: function () {
481
  $(this).dialog('close');
src/SupsysticTables/Tables/assets/libraries/handsontable/handsontable.full.min.css CHANGED
@@ -1,34 +1,55 @@
1
- @charset "UTF-8";/*!
2
- (The MIT License)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3
 
4
- Handsontable 0.31.1
5
- Handsontable is a JavaScript library for editable tables with basic copy-paste compatibility with Excel and Google Docs
6
-
7
- Copyright (c) 2012-2014 Marcin Warpechowski
8
- Copyright (c) 2015 Handsoncode sp. z o.o. <hello@handsoncode.net>
9
 
10
- Permission is hereby granted, free of charge, to any person obtaining
11
- a copy of this software and associated documentation files (the
12
- 'Software'), to deal in the Software without restriction, including
13
- without limitation the rights to use, copy, modify, merge, publish,
14
- distribute, sublicense, and/or sell copies of the Software, and to
15
- permit persons to whom the Software is furnished to do so, subject to
16
- the following conditions:
17
 
18
- The above copyright notice and this permission notice shall be
19
- included in all copies or substantial portions of the Software.
 
20
 
21
- THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
22
- EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
23
- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
24
- IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
25
- CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
26
- TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
27
- SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
28
 
29
- */.handsontable{position:relative}.handsontable .hide{display:none}.handsontable .relative{position:relative}.handsontable.htAutoSize{visibility:hidden;left:-99000px;position:absolute;top:-99000px}.handsontable .wtHider{width:0}.handsontable .wtSpreader{position:relative;width:0;height:auto}.handsontable table,.handsontable tbody,.handsontable thead,.handsontable td,.handsontable th,.handsontable input,.handsontable textarea,.handsontable div{box-sizing:content-box;-webkit-box-sizing:content-box;-moz-box-sizing:content-box}.handsontable input,.handsontable textarea{min-height:initial}.handsontable table.htCore{border-collapse:separate;border-spacing:0;margin:0;border-width:0;table-layout:fixed;width:0;outline-width:0;max-width:none;max-height:none}.handsontable col{width:50px}.handsontable col.rowHeader{width:50px}.handsontable th,.handsontable td{border-top-width:0;border-left-width:0;border-right:1px solid #CCC;border-bottom:1px solid #CCC;height:22px;empty-cells:show;line-height:21px;padding:0 4px 0 4px;background-color:#FFF;vertical-align:top;overflow:hidden;outline-width:0;white-space:pre-line;background-clip:padding-box}.handsontable td.htInvalid{background-color:#ff4c42!important}.handsontable td.htNoWrap{white-space:nowrap}.handsontable th:last-child{border-right:1px solid #CCC;border-bottom:1px solid #CCC}.handsontable tr:first-child th.htNoFrame,.handsontable th:first-child.htNoFrame,.handsontable th.htNoFrame{border-left-width:0;background-color:white;border-color:#FFF}.handsontable th:first-child,.handsontable th:nth-child(2),.handsontable td:first-of-type,.handsontable .htNoFrame+th,.handsontable .htNoFrame+td{border-left:1px solid #CCC}.handsontable.htRowHeaders thead tr th:nth-child(2){border-left:1px solid #CCC}.handsontable tr:first-child th,.handsontable tr:first-child td{border-top:1px solid #CCC}.ht_master:not(.innerBorderLeft):not(.emptyColumns) ~ .handsontable tbody tr th,.ht_master:not(.innerBorderLeft):not(.emptyColumns) ~ .handsontable:not(.ht_clone_top) thead tr th:first-child{border-right-width:0}.ht_master:not(.innerBorderTop) thead tr:last-child th,.ht_master:not(.innerBorderTop) ~ .handsontable thead tr:last-child th,.ht_master:not(.innerBorderTop) thead tr.lastChild th,.ht_master:not(.innerBorderTop) ~ .handsontable thead tr.lastChild th{border-bottom-width:0}.handsontable th{background-color:#f3f3f3;color:#222;text-align:center;font-weight:normal;white-space:nowrap}.handsontable thead th{padding:0}.handsontable th.active{background-color:#CCC}.handsontable thead th .relative{padding:2px 4px}.handsontable tbody th.ht__highlight,.handsontable thead th.ht__highlight{background-color:#dcdcdc}.handsontable.ht__selection--columns thead th.ht__highlight,.handsontable.ht__selection--rows tbody th.ht__highlight{background-color:#8eb0e7;color:#000}.handsontable .manualColumnResizer{position:fixed;top:0;cursor:col-resize;z-index:110;width:5px;height:25px}.handsontable .manualRowResizer{position:fixed;left:0;cursor:row-resize;z-index:110;height:5px;width:50px}.handsontable .manualColumnResizer:hover,.handsontable .manualColumnResizer.active,.handsontable .manualRowResizer:hover,.handsontable .manualRowResizer.active{background-color:#AAB}.handsontable .manualColumnResizerGuide{position:fixed;right:0;top:0;background-color:#AAB;display:none;width:0;border-right:1px dashed #777;margin-left:5px}.handsontable .manualRowResizerGuide{position:fixed;left:0;bottom:0;background-color:#AAB;display:none;height:0;border-bottom:1px dashed #777;margin-top:5px}.handsontable .manualColumnResizerGuide.active,.handsontable .manualRowResizerGuide.active{display:block;z-index:199}.handsontable .columnSorting{position:relative}.handsontable .columnSorting:hover{text-decoration:underline;cursor:pointer}.handsontable .columnSorting.ascending::after{content:'\25B2';color:#5f5f5f;position:absolute;right:-15px}.handsontable .columnSorting.descending::after{content:'\25BC';color:#5f5f5f;position:absolute;right:-15px}.handsontable .wtBorder{position:absolute;font-size:0}.handsontable .wtBorder.hidden{display:none!important}.handsontable td.area{background:-moz-linear-gradient(top,rgba(181,209,255,0.34) 0,rgba(181,209,255,0.34) 100%);background:-webkit-gradient(linear,left top,left bottom,color-stop(0%,rgba(181,209,255,0.34)),color-stop(100%,rgba(181,209,255,0.34)));background:-webkit-linear-gradient(top,rgba(181,209,255,0.34) 0,rgba(181,209,255,0.34) 100%);background:-o-linear-gradient(top,rgba(181,209,255,0.34) 0,rgba(181,209,255,0.34) 100%);background:-ms-linear-gradient(top,rgba(181,209,255,0.34) 0,rgba(181,209,255,0.34) 100%);background:linear-gradient(to bottom,rgba(181,209,255,0.34) 0,rgba(181,209,255,0.34) 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#57b5d1ff',endColorstr='#57b5d1ff',GradientType=0);background-color:#fff}.handsontable .wtBorder.corner{font-size:0;cursor:crosshair}.handsontable .htBorder.htFillBorder{background:red;width:1px;height:1px}.handsontableInput{border:0;outline-width:0;margin:0;padding:1px 5px 0 5px;font-family:inherit;line-height:21px;font-size:inherit;box-shadow:0 0 0 2px #5292f7 inset;resize:none;display:inline-block;color:#000;border-radius:0;background-color:#FFF}.handsontableInputHolder{position:absolute;top:0;left:0;z-index:100}.htSelectEditor{-webkit-appearance:menulist-button!important;position:absolute;width:auto}.handsontable .htDimmed{color:#777}.handsontable .htSubmenu{position:relative}.handsontable .htSubmenu :after{content:'▶';color:#777;position:absolute;right:5px}.handsontable .htLeft{text-align:left}.handsontable .htCenter{text-align:center}.handsontable .htRight{text-align:right}.handsontable .htJustify{text-align:justify}.handsontable .htTop{vertical-align:top}.handsontable .htMiddle{vertical-align:middle}.handsontable .htBottom{vertical-align:bottom}.handsontable .htPlaceholder{color:#999}.handsontable .htAutocompleteArrow{float:right;font-size:10px;color:#EEE;cursor:default;width:16px;text-align:center}.handsontable td .htAutocompleteArrow:hover{color:#777}.handsontable td.area .htAutocompleteArrow{color:#d3d3d3}.handsontable .htCheckboxRendererInput{display:inline-block;vertical-align:middle}.handsontable .htCheckboxRendererInput.noValue{opacity:.5}.handsontable .htCheckboxRendererLabel{cursor:pointer;display:inline-block;width:100%}@-webkit-keyframes opacity-hide{from{opacity:1}to{opacity:0}}@keyframes opacity-hide{from{opacity:1}to{opacity:0}}@-webkit-keyframes opacity-show{from{opacity:0}to{opacity:1}}@keyframes opacity-show{from{opacity:0}to{opacity:1}}.handsontable .handsontable.ht_clone_top .wtHider{padding:0 0 5px 0}.handsontable .autocompleteEditor.handsontable{padding-right:17px}.handsontable .autocompleteEditor.handsontable.htMacScroll{padding-right:15px}.handsontable.listbox{margin:0}.handsontable.listbox .ht_master table{border:1px solid #ccc;border-collapse:separate;background:white}.handsontable.listbox th,.handsontable.listbox tr:first-child th,.handsontable.listbox tr:last-child th,.handsontable.listbox tr:first-child td,.handsontable.listbox td{border-color:transparent}.handsontable.listbox th,.handsontable.listbox td{white-space:nowrap;text-overflow:ellipsis}.handsontable.listbox td.htDimmed{cursor:default;color:inherit;font-style:inherit}.handsontable.listbox .wtBorder{visibility:hidden}.handsontable.listbox tr td.current,.handsontable.listbox tr:hover td{background:#eee}.ht_clone_top{z-index:101}.ht_clone_left{z-index:102}.ht_clone_top_left_corner,.ht_clone_bottom_left_corner{z-index:103}.ht_clone_debug{z-index:103}.handsontable td.htSearchResult{background:#fcedd9;color:#583707}.htBordered{border-width:1px}.htBordered.htTopBorderSolid{border-top-style:solid;border-top-color:#000}.htBordered.htRightBorderSolid{border-right-style:solid;border-right-color:#000}.htBordered.htBottomBorderSolid{border-bottom-style:solid;border-bottom-color:#000}.htBordered.htLeftBorderSolid{border-left-style:solid;border-left-color:#000}.handsontable tbody tr th:nth-last-child(2){border-right:1px solid #CCC}.handsontable thead tr:nth-last-child(2) th.htGroupIndicatorContainer{border-bottom:1px solid #CCC;padding-bottom:5px}.ht_clone_top_left_corner thead tr th:nth-last-child(2){border-right:1px solid #CCC}.htCollapseButton{width:10px;height:10px;line-height:10px;text-align:center;border-radius:5px;border:1px solid #f3f3f3;-webkit-box-shadow:1px 1px 3px rgba(0,0,0,0.4);box-shadow:1px 1px 3px rgba(0,0,0,0.4);cursor:pointer;margin-bottom:3px;position:relative}.htCollapseButton:after{content:"";height:300%;width:1px;display:block;background:#ccc;margin-left:4px;position:absolute;bottom:10px}thead .htCollapseButton{right:5px;position:absolute;top:5px;background:#fff}thead .htCollapseButton:after{height:1px;width:700%;right:10px;top:4px}.handsontable tr th .htExpandButton{position:absolute;width:10px;height:10px;line-height:10px;text-align:center;border-radius:5px;border:1px solid #f3f3f3;-webkit-box-shadow:1px 1px 3px rgba(0,0,0,0.4);box-shadow:1px 1px 3px rgba(0,0,0,0.4);cursor:pointer;top:0;display:none}.handsontable thead tr th .htExpandButton{top:5px}.handsontable tr th .htExpandButton.clickable{display:block}.collapsibleIndicator{position:absolute;top:50%;transform:translate(0%,-50%);right:5px;border:1px solid #a6a6a6;line-height:10px;color:#222;border-radius:10px;font-size:10px;width:10px;height:10px;cursor:pointer;-webkit-box-shadow:0 0 0 6px rgba(238,238,238,1);-moz-box-shadow:0 0 0 6px rgba(238,238,238,1);box-shadow:0 0 0 6px rgba(238,238,238,1);background:#eee}.handsontable col.hidden{width:0!important}.handsontable table tr th.lightRightBorder{border-right:1px solid #e6e6e6}.handsontable tr.hidden,.handsontable tr.hidden td,.handsontable tr.hidden th{display:none}.ht_master,.ht_clone_left,.ht_clone_top,.ht_clone_bottom{overflow:hidden}.ht_master .wtHolder{overflow:auto}.ht_clone_left .wtHolder{overflow-x:hidden;overflow-y:auto}.ht_clone_top .wtHolder,.ht_clone_bottom .wtHolder{overflow-x:auto;overflow-y:hidden}.wtDebugHidden{display:none}.wtDebugVisible{display:block;-webkit-animation-duration:.5s;-webkit-animation-name:wtFadeInFromNone;animation-duration:.5s;animation-name:wtFadeInFromNone}@keyframes wtFadeInFromNone{0%{display:none;opacity:0}1%{display:block;opacity:0}100%{display:block;opacity:1}}@-webkit-keyframes wtFadeInFromNone{0%{display:none;opacity:0}1%{display:block;opacity:0}100%{display:block;opacity:1}}.handsontable.mobile,.handsontable.mobile .wtHolder{-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-tap-highlight-color:rgba(0,0,0,0);-webkit-overflow-scrolling:touch}.htMobileEditorContainer{display:none;position:absolute;top:0;width:70%;height:54pt;background:#f8f8f8;border-radius:20px;border:1px solid #ebebeb;z-index:999;box-sizing:border-box;-webkit-box-sizing:border-box;-webkit-text-size-adjust:none}.topLeftSelectionHandle:not(.ht_master .topLeftSelectionHandle),.topLeftSelectionHandle-HitArea:not(.ht_master .topLeftSelectionHandle-HitArea){z-index:9999}.topLeftSelectionHandle,.topLeftSelectionHandle-HitArea,.bottomRightSelectionHandle,.bottomRightSelectionHandle-HitArea{left:-10000px;top:-10000px}.htMobileEditorContainer.active{display:block}.htMobileEditorContainer .inputs{position:absolute;right:210pt;bottom:10pt;top:10pt;left:14px;height:34pt}.htMobileEditorContainer .inputs textarea{font-size:13pt;border:1px solid #a1a1a1;-webkit-appearance:none;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;position:absolute;left:14px;right:14px;top:0;bottom:0;padding:7pt}.htMobileEditorContainer .cellPointer{position:absolute;top:-13pt;height:0;width:0;left:30px;border-left:13pt solid transparent;border-right:13pt solid transparent;border-bottom:13pt solid #ebebeb}.htMobileEditorContainer .cellPointer.hidden{display:none}.htMobileEditorContainer .cellPointer:before{content:'';display:block;position:absolute;top:2px;height:0;width:0;left:-13pt;border-left:13pt solid transparent;border-right:13pt solid transparent;border-bottom:13pt solid #f8f8f8}.htMobileEditorContainer .moveHandle{position:absolute;top:10pt;left:5px;width:30px;bottom:0;cursor:move;z-index:9999}.htMobileEditorContainer .moveHandle:after{content:"..\a..\a..\a..";white-space:pre;line-height:10px;font-size:20pt;display:inline-block;margin-top:-8px;color:#ebebeb}.htMobileEditorContainer .positionControls{width:205pt;position:absolute;right:5pt;top:0;bottom:0}.htMobileEditorContainer .positionControls>div{width:50pt;height:100%;float:left}.htMobileEditorContainer .positionControls>div:after{content:" ";display:block;width:15pt;height:15pt;text-align:center;line-height:50pt}.htMobileEditorContainer .leftButton:after,.htMobileEditorContainer .rightButton:after,.htMobileEditorContainer .upButton:after,.htMobileEditorContainer .downButton:after{transform-origin:5pt 5pt;-webkit-transform-origin:5pt 5pt;margin:21pt 0 0 21pt}.htMobileEditorContainer .leftButton:after{border-top:2px solid #288ffe;border-left:2px solid #288ffe;-webkit-transform:rotate(-45deg)}.htMobileEditorContainer .leftButton:active:after{border-color:#cfcfcf}.htMobileEditorContainer .rightButton:after{border-top:2px solid #288ffe;border-left:2px solid #288ffe;-webkit-transform:rotate(135deg)}.htMobileEditorContainer .rightButton:active:after{border-color:#cfcfcf}.htMobileEditorContainer .upButton:after{border-top:2px solid #288ffe;border-left:2px solid #288ffe;-webkit-transform:rotate(45deg)}.htMobileEditorContainer .upButton:active:after{border-color:#cfcfcf}.htMobileEditorContainer .downButton:after{border-top:2px solid #288ffe;border-left:2px solid #288ffe;-webkit-transform:rotate(225deg)}.htMobileEditorContainer .downButton:active:after{border-color:#cfcfcf}.handsontable.hide-tween{-webkit-animation:opacity-hide .3s;animation:opacity-hide .3s;animation-fill-mode:forwards;-webkit-animation-fill-mode:forwards}.handsontable.show-tween{-webkit-animation:opacity-show .3s;animation:opacity-show .3s;animation-fill-mode:forwards;-webkit-animation-fill-mode:forwards}.htCommentCell{position:relative}.htCommentCell:after{content:'';position:absolute;top:0;right:0;border-left:6px solid transparent;border-top:6px solid black}.htComments{display:none;z-index:1059;position:absolute}.htCommentTextArea{box-shadow:rgba(0,0,0,0.117647) 0 1px 3px,rgba(0,0,0,0.239216) 0 1px 2px;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;border:0;border-left:3px solid #ccc;background-color:#fff;width:215px;height:90px;font-size:12px;padding:5px;outline:0!important;-webkit-appearance:none}.htCommentTextArea:focus{box-shadow:rgba(0,0,0,0.117647) 0 1px 3px,rgba(0,0,0,0.239216) 0 1px 2px,inset 0 0 0 1px #5292f7;border-left:3px solid #5292f7}/*!
30
- * Handsontable ContextMenu
31
- */.htContextMenu{display:none;position:absolute;z-index:1060}.htContextMenu .ht_clone_top,.htContextMenu .ht_clone_left,.htContextMenu .ht_clone_corner,.htContextMenu .ht_clone_debug{display:none}.htContextMenu table.htCore{border:1px solid #ccc;border-bottom-width:2px;border-right-width:2px}.htContextMenu .wtBorder{visibility:hidden}.htContextMenu table tbody tr td{background:white;border-width:0;padding:4px 6px 0 6px;cursor:pointer;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.htContextMenu table tbody tr td:first-child{border:0}.htContextMenu table tbody tr td.htDimmed{font-style:normal;color:#323232}.htContextMenu table tbody tr td.current,.htContextMenu table tbody tr td.zeroclipboard-is-hover{background:#f3f3f3}.htContextMenu table tbody tr td.htSeparator{border-top:1px solid #bbb;height:0;padding:0;cursor:default}.htContextMenu table tbody tr td.htDisabled{color:#999;cursor:default}.htContextMenu table tbody tr td.htDisabled:hover{background:#fff;color:#999;cursor:default}.htContextMenu table tbody tr.htHidden{display:none}.htContextMenu table tbody tr td .htItemWrapper{margin-left:10px;margin-right:6px}.htContextMenu table tbody tr td div span.selected{margin-top:-2px;position:absolute;left:4px}.htContextMenu .ht_master .wtHolder{overflow:hidden}.htRowHeaders .ht_master.innerBorderLeft ~ .ht_clone_top_left_corner th:nth-child(2),.htRowHeaders .ht_master.innerBorderLeft ~ .ht_clone_left td:first-of-type{border-left:0 none}.handsontable .wtHider{position:relative}.handsontable.ht__manualColumnMove.after-selection--columns thead th.ht__highlight{cursor:move;cursor:-moz-grab;cursor:-webkit-grab;cursor:grab}.handsontable.ht__manualColumnMove.on-moving--columns,.handsontable.ht__manualColumnMove.on-moving--columns thead th.ht__highlight{cursor:move;cursor:-moz-grabbing;cursor:-webkit-grabbing;cursor:grabbing}.handsontable.ht__manualColumnMove.on-moving--columns .manualColumnResizer{display:none}.handsontable .ht__manualColumnMove--guideline,.handsontable .ht__manualColumnMove--backlight{position:absolute;height:100%;display:none}.handsontable .ht__manualColumnMove--guideline{background:#757575;width:2px;top:0;margin-left:-1px;z-index:105}.handsontable .ht__manualColumnMove--backlight{background:#343434;background:rgba(52,52,52,0.25);display:none;z-index:105;pointer-events:none}.handsontable.on-moving--columns.show-ui .ht__manualColumnMove--guideline,.handsontable.on-moving--columns .ht__manualColumnMove--backlight{display:block}.handsontable .wtHider{position:relative}.handsontable.ht__manualRowMove.after-selection--rows tbody th.ht__highlight{cursor:move;cursor:-moz-grab;cursor:-webkit-grab;cursor:grab}.handsontable.ht__manualRowMove.on-moving--rows,.handsontable.ht__manualRowMove.on-moving--rows tbody th.ht__highlight{cursor:move;cursor:-moz-grabbing;cursor:-webkit-grabbing;cursor:grabbing}.handsontable.ht__manualRowMove.on-moving--rows .manualRowResizer{display:none}.handsontable .ht__manualRowMove--guideline,.handsontable .ht__manualRowMove--backlight{position:absolute;width:100%;display:none}.handsontable .ht__manualRowMove--guideline{background:#757575;height:2px;left:0;margin-top:-1px;z-index:105}.handsontable .ht__manualRowMove--backlight{background:#343434;background:rgba(52,52,52,0.25);display:none;z-index:105;pointer-events:none}.handsontable.on-moving--rows.show-ui .ht__manualRowMove--guideline,.handsontable.on-moving--rows .ht__manualRowMove--backlight{display:block}/*!
32
- * Pikaday
33
- * Copyright © 2014 David Bushell | BSD & MIT license | http://dbushell.com/
34
- */.pika-single{z-index:9999;display:block;position:relative;color:#333;background:#fff;border:1px solid #ccc;border-bottom-color:#bbb;font-family:"Helvetica Neue",Helvetica,Arial,sans-serif}.pika-single:before,.pika-single:after{content:" ";display:table}.pika-single:after{clear:both}.pika-single{*zoom:1}.pika-single.is-hidden{display:none}.pika-single.is-bound{position:absolute;box-shadow:0 5px 15px -5px rgba(0,0,0,.5)}.pika-lendar{float:left;width:240px;margin:8px}.pika-title{position:relative;text-align:center}.pika-label{display:inline-block;*display:inline;position:relative;z-index:9999;overflow:hidden;margin:0;padding:5px 3px;font-size:14px;line-height:20px;font-weight:bold;background-color:#fff}.pika-title select{cursor:pointer;position:absolute;z-index:9998;margin:0;left:0;top:5px;filter:alpha(opacity=0);opacity:0}.pika-prev,.pika-next{display:block;cursor:pointer;position:relative;outline:0;border:0;padding:0;width:20px;height:30px;text-indent:20px;white-space:nowrap;overflow:hidden;background-color:transparent;background-position:center center;background-repeat:no-repeat;background-size:75% 75%;opacity:.5;*position:absolute;*top:0}.pika-prev:hover,.pika-next:hover{opacity:1}.pika-prev,.is-rtl .pika-next{float:left;background-image:url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAeCAYAAAAsEj5rAAAAUklEQVR42u3VMQoAIBADQf8Pgj+OD9hG2CtONJB2ymQkKe0HbwAP0xucDiQWARITIDEBEnMgMQ8S8+AqBIl6kKgHiXqQqAeJepBo/z38J/U0uAHlaBkBl9I4GwAAAABJRU5ErkJggg==');*left:0}.pika-next,.is-rtl .pika-prev{float:right;background-image:url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAeCAYAAAAsEj5rAAAAU0lEQVR42u3VOwoAMAgE0dwfAnNjU26bYkBCFGwfiL9VVWoO+BJ4Gf3gtsEKKoFBNTCoCAYVwaAiGNQGMUHMkjGbgjk2mIONuXo0nC8XnCf1JXgArVIZAQh5TKYAAAAASUVORK5CYII=');*right:0}.pika-prev.is-disabled,.pika-next.is-disabled{cursor:default;opacity:.2}.pika-select{display:inline-block;*display:inline}.pika-table{width:100%;border-collapse:collapse;border-spacing:0;border:0}.pika-table th,.pika-table td{width:14.285714285714286%;padding:0}.pika-table th{color:#999;font-size:12px;line-height:25px;font-weight:bold;text-align:center}.pika-button{cursor:pointer;display:block;box-sizing:border-box;-moz-box-sizing:border-box;outline:0;border:0;margin:0;width:100%;padding:5px;color:#666;font-size:12px;line-height:15px;text-align:right;background:#f5f5f5}.pika-week{font-size:11px;color:#999}.is-today .pika-button{color:#3af;font-weight:bold}.is-selected .pika-button{color:#fff;font-weight:bold;background:#3af;box-shadow:inset 0 1px 3px #178fe5;border-radius:3px}.is-inrange .pika-button{background:#d5e9f7}.is-startrange .pika-button{color:#fff;background:#6cb31d;box-shadow:none;border-radius:3px}.is-endrange .pika-button{color:#fff;background:#3af;box-shadow:none;border-radius:3px}.is-disabled .pika-button,.is-outside-current-month .pika-button{pointer-events:none;cursor:default;color:#999;opacity:.3}.pika-button:hover{color:#fff;background:#ff8000;box-shadow:none;border-radius:3px}.pika-table abbr{border-bottom:0;cursor:help}
1
+ @charset "UTF-8";
2
+ /*!
3
+ * Copyright (c) HANDSONCODE sp. z o. o.
4
+ *
5
+ * HANDSONTABLE is a software distributed by HANDSONCODE sp. z o. o.,
6
+ * a Polish corporation, based in Gdynia, Poland, at 96/98 Aleja Zwycięstwa,
7
+ * registered with the National Court Register under number 538651,
8
+ * EU tax ID number: PL5862294002, share capital: PLN 62,800.00.
9
+ *
10
+ * This software is protected by applicable copyright laws, including
11
+ * international treaties, and dual-licensed – depending on whether
12
+ * your use is intended for or may result in commercial advantage
13
+ * or monetary compensation (commercial purposes), or not.
14
+ *
15
+ * If your use involves only such purposes as research, private study,
16
+ * evaluation and the like, you agree to be bound by the terms included
17
+ * in the "handsontable-non-commercial-license.pdf" file, available
18
+ * in the main directory of this software repository.
19
+ *
20
+ * By installing, copying, or otherwise using this software for
21
+ * commercial purposes, you agree to be bound by the terms included
22
+ * in the "handsontable-general-terms.pdf" file, available in the main
23
+ * directory of this software repository.
24
+ *
25
+ * HANDSONCODE PROVIDES THIS SOFTWARE ON AN "AS IS" BASIS,
26
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND. IN NO EVENT
27
+ * AND UNDER NO LEGAL THEORY, SHALL HANDSONCODE BE LIABLE
28
+ * TO YOU FOR DAMAGES, INCLUDING ANY DIRECT, INDIRECT, SPECIAL,
29
+ * INCIDENTAL, OR CONSEQUENTIAL DAMAGES OF ANY CHARACTER ARISING
30
+ * FROM USE OR INABILITY TO USE THIS SOFTWARE.
31
+ *
32
+ * Version: 7.1.1
33
+ * Release date: 12/08/2019 (built at 02/08/2019 13:05:27)
34
+ */.handsontable .table td,.handsontable .table th{border-top:none}.handsontable tr{background:#fff}.handsontable td{background-color:inherit}.handsontable .table caption+thead tr:first-child td,.handsontable .table caption+thead tr:first-child th,.handsontable .table colgroup+thead tr:first-child td,.handsontable .table colgroup+thead tr:first-child th,.handsontable .table thead:first-child tr:first-child td,.handsontable .table thead:first-child tr:first-child th{border-top:1px solid #ccc}.handsontable .table-bordered{border:0;border-collapse:separate}.handsontable .table-bordered td,.handsontable .table-bordered th{border-left:none}.handsontable .table-bordered td:first-child,.handsontable .table-bordered th:first-child{border-left:1px solid #ccc}.handsontable .table>tbody>tr>td,.handsontable .table>tbody>tr>th,.handsontable .table>tfoot>tr>td,.handsontable .table>tfoot>tr>th,.handsontable .table>thead>tr>td,.handsontable .table>thead>tr>th{line-height:21px;padding:0 4px}.col-lg-1.handsontable,.col-lg-2.handsontable,.col-lg-3.handsontable,.col-lg-4.handsontable,.col-lg-5.handsontable,.col-lg-6.handsontable,.col-lg-7.handsontable,.col-lg-8.handsontable,.col-lg-9.handsontable,.col-lg-10.handsontable,.col-lg-11.handsontable,.col-lg-12.handsontable,.col-md-1.handsontable,.col-md-2.handsontable,.col-md-3.handsontable,.col-md-4.handsontable,.col-md-5.handsontable,.col-md-6.handsontable,.col-md-7.handsontable,.col-md-8.handsontable,.col-md-9.handsontable .col-sm-1.handsontable,.col-md-10.handsontable,.col-md-11.handsontable,.col-md-12.handsontable,.col-sm-2.handsontable,.col-sm-3.handsontable,.col-sm-4.handsontable,.col-sm-5.handsontable,.col-sm-6.handsontable,.col-sm-7.handsontable,.col-sm-8.handsontable,.col-sm-9.handsontable .col-xs-1.handsontable,.col-sm-10.handsontable,.col-sm-11.handsontable,.col-sm-12.handsontable,.col-xs-2.handsontable,.col-xs-3.handsontable,.col-xs-4.handsontable,.col-xs-5.handsontable,.col-xs-6.handsontable,.col-xs-7.handsontable,.col-xs-8.handsontable,.col-xs-9.handsontable,.col-xs-10.handsontable,.col-xs-11.handsontable,.col-xs-12.handsontable{padding-left:0;padding-right:0}.handsontable .table-striped>tbody>tr:nth-of-type(2n){background-color:#fff}.handsontable{position:relative}.handsontable .hide{display:none}.handsontable .relative{position:relative}.handsontable.htAutoSize{visibility:hidden;left:-99000px;position:absolute;top:-99000px}.handsontable .wtHider{width:0}.handsontable .wtSpreader{position:relative;width:0;height:auto}.handsontable div,.handsontable input,.handsontable table,.handsontable tbody,.handsontable td,.handsontable textarea,.handsontable th,.handsontable thead{box-sizing:content-box;-webkit-box-sizing:content-box;-moz-box-sizing:content-box}.handsontable input,.handsontable textarea{min-height:0}.handsontable table.htCore{border-collapse:separate;border-spacing:0;margin:0;border-width:0;table-layout:fixed;width:0;outline-width:0;cursor:default;max-width:none;max-height:none}.handsontable col,.handsontable col.rowHeader{width:50px}.handsontable td,.handsontable th{border-top-width:0;border-left-width:0;border-right:1px solid #ccc;border-bottom:1px solid #ccc;height:22px;empty-cells:show;line-height:21px;padding:0 4px;background-color:#fff;vertical-align:top;overflow:hidden;outline-width:0;white-space:pre-line;background-clip:padding-box}.handsontable td.htInvalid{background-color:#ff4c42!important}.handsontable td.htNoWrap{white-space:nowrap}.handsontable th:last-child{border-right:1px solid #ccc;border-bottom:1px solid #ccc}.handsontable th.htNoFrame,.handsontable th:first-child.htNoFrame,.handsontable tr:first-child th.htNoFrame{border-left-width:0;background-color:#fff;border-color:#fff}.handsontable .htNoFrame+td,.handsontable .htNoFrame+th,.handsontable td:first-of-type,.handsontable th:first-child,.handsontable th:nth-child(2){border-left:1px solid #ccc}.handsontable.htRowHeaders thead tr th:nth-child(2){border-left:1px solid #ccc}.handsontable tr:first-child td,.handsontable tr:first-child th{border-top:1px solid #ccc}.ht_master:not(.innerBorderLeft):not(.emptyColumns)~.handsontable:not(.ht_clone_top) thead tr th:first-child,.ht_master:not(.innerBorderLeft):not(.emptyColumns)~.handsontable tbody tr th{border-right-width:0}.ht_master:not(.innerBorderTop) thead tr.lastChild th,.ht_master:not(.innerBorderTop) thead tr:last-child th,.ht_master:not(.innerBorderTop)~.handsontable thead tr.lastChild th,.ht_master:not(.innerBorderTop)~.handsontable thead tr:last-child th{border-bottom-width:0}.handsontable th{background-color:#f0f0f0;color:#222;text-align:center;font-weight:400;white-space:nowrap}.handsontable thead th{padding:0}.handsontable th.active{background-color:#ccc}.handsontable thead th .relative{padding:2px 4px}#hot-display-license-info{font-size:10px;color:#323232;padding:5px 0 3px;font-family:Helvetica,Arial,sans-serif;text-align:left}#hot-display-license-info a{font-size:10px}.handsontable .manualColumnResizer{position:absolute;top:0;cursor:col-resize;z-index:110;width:5px;height:25px}.handsontable .manualRowResizer{position:absolute;left:0;cursor:row-resize;z-index:110;height:5px;width:50px}.handsontable .manualColumnResizer.active,.handsontable .manualColumnResizer:hover,.handsontable .manualRowResizer.active,.handsontable .manualRowResizer:hover{background-color:#34a9db}.handsontable .manualColumnResizerGuide{position:absolute;right:0;top:0;background-color:#34a9db;display:none;width:0;border-right:1px dashed #777;margin-left:5px}.handsontable .manualRowResizerGuide{position:absolute;left:0;bottom:0;background-color:#34a9db;display:none;height:0;border-bottom:1px dashed #777;margin-top:5px}.handsontable .manualColumnResizerGuide.active,.handsontable .manualRowResizerGuide.active{display:block;z-index:199}.handsontable .columnSorting{position:relative}.handsontable .columnSorting.sortAction:hover{text-decoration:underline;cursor:pointer}.handsontable span.colHeader{display:inline-block;line-height:1.1}.handsontable span.colHeader.columnSorting:before{top:50%;margin-top:-6px;padding-left:8px;position:absolute;right:-9px;content:"";height:10px;width:5px;background-size:contain;background-repeat:no-repeat;background-position-x:right}.handsontable span.colHeader.columnSorting.ascending:before{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAoCAMAAADJ7yrpAAAAKlBMVEUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAKE86IAAAADXRSTlMABBEmRGprlJW72e77tTkTKwAAAFNJREFUeAHtzjkSgCAUBNHPgsoy97+ulGXRqJE5L+xkxoYt2UdsLb5bqFINz+aLuuLn5rIu2RkO3fZpWENimNgiw6iBYRTPMLJjGFxQZ1hxxb/xBI1qC8k39CdKAAAAAElFTkSuQmCC")}.handsontable span.colHeader.columnSorting.descending:before{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAoCAMAAADJ7yrpAAAAKlBMVEUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAKE86IAAAADXRSTlMABBEmRGprlJW72e77tTkTKwAAAFJJREFUeAHtzjkSgCAQRNFmQYUZ7n9dKUvru0TmvPAn3br0QfgdZ5xx6x+rQn23GqTYnq1FDcnuzZIO2WmedVqIRVxgGKEyjNgYRjKGkZ1hFIZ3I70LyM0VtU8AAAAASUVORK5CYII=")}.htGhostTable .htCore span.colHeader.columnSorting:not(.indicatorDisabled):after{content:"*";display:inline-block;position:relative;padding-right:20px}.handsontable .wtBorder{position:absolute;font-size:0}.handsontable .wtBorder.hidden{display:none!important}.handsontable .wtBorder.current{z-index:10}.handsontable .wtBorder.area{z-index:8}.handsontable .wtBorder.fill{z-index:6}.handsontable td.area,.handsontable td.area-1,.handsontable td.area-2,.handsontable td.area-3,.handsontable td.area-4,.handsontable td.area-5,.handsontable td.area-6,.handsontable td.area-7{position:relative}.handsontable td.area-1:before,.handsontable td.area-2:before,.handsontable td.area-3:before,.handsontable td.area-4:before,.handsontable td.area-5:before,.handsontable td.area-6:before,.handsontable td.area-7:before,.handsontable td.area:before{content:"";position:absolute;top:0;left:0;right:0;bottom:0;bottom:-100%\9;background:#005eff}@media (-ms-high-contrast:none),screen and (-ms-high-contrast:active){.handsontable td.area-1:before,.handsontable td.area-2:before,.handsontable td.area-3:before,.handsontable td.area-4:before,.handsontable td.area-5:before,.handsontable td.area-6:before,.handsontable td.area-7:before,.handsontable td.area:before{bottom:-100%}}.handsontable td.area:before{opacity:.1}.handsontable td.area-1:before{opacity:.2}.handsontable td.area-2:before{opacity:.27}.handsontable td.area-3:before{opacity:.35}.handsontable td.area-4:before{opacity:.41}.handsontable td.area-5:before{opacity:.47}.handsontable td.area-6:before{opacity:.54}.handsontable td.area-7:before{opacity:.58}.handsontable tbody th.ht__highlight,.handsontable thead th.ht__highlight{background-color:#dcdcdc}.handsontable tbody th.ht__active_highlight,.handsontable thead th.ht__active_highlight{background-color:#8eb0e7;color:#000}.handsontable .wtBorder.corner{font-size:0;cursor:crosshair}.handsontable .htBorder.htFillBorder{background:red;width:1px;height:1px}.handsontableInput{border:none;outline-width:0;margin:0;padding:1px 5px 0;font-family:inherit;line-height:21px;font-size:inherit;box-shadow:inset 0 0 0 2px #5292f7;resize:none;display:block;color:#000;border-radius:0;background-color:#fff}.handsontableInputHolder{position:absolute;top:0;left:0;z-index:104}.htSelectEditor{-webkit-appearance:menulist-button!important;position:absolute;width:auto}.handsontable .htDimmed{color:#777}.handsontable .htSubmenu{position:relative}.handsontable .htSubmenu :after{content:"\25B6";color:#777;position:absolute;right:5px;font-size:9px}.handsontable .htLeft{text-align:left}.handsontable .htCenter{text-align:center}.handsontable .htRight{text-align:right}.handsontable .htJustify{text-align:justify}.handsontable .htTop{vertical-align:top}.handsontable .htMiddle{vertical-align:middle}.handsontable .htBottom{vertical-align:bottom}.handsontable .htPlaceholder{color:#999}.handsontable .htAutocompleteArrow{float:right;font-size:10px;color:#eee;cursor:default;width:16px;text-align:center}.handsontable td .htAutocompleteArrow:hover{color:#777}.handsontable td.area .htAutocompleteArrow{color:#d3d3d3}.handsontable .htCheckboxRendererInput{display:inline-block}.handsontable .htCheckboxRendererInput.noValue{opacity:.5}.handsontable .htCheckboxRendererLabel{font-size:inherit;vertical-align:middle;cursor:pointer;display:inline-block;width:100%}.handsontable .handsontable.ht_clone_top .wtHider{padding:0 0 5px}.handsontable .autocompleteEditor.handsontable{padding-right:17px}.handsontable .autocompleteEditor.handsontable.htMacScroll{padding-right:15px}.handsontable.listbox{margin:0}.handsontable.listbox .ht_master table{border:1px solid #ccc;border-collapse:separate;background:#fff}.handsontable.listbox td,.handsontable.listbox th,.handsontable.listbox tr:first-child td,.handsontable.listbox tr:first-child th,.handsontable.listbox tr:last-child th{border-color:transparent}.handsontable.listbox td,.handsontable.listbox th{white-space:nowrap;text-overflow:ellipsis}.handsontable.listbox td.htDimmed{cursor:default;color:inherit;font-style:inherit}.handsontable.listbox .wtBorder{visibility:hidden}.handsontable.listbox tr:hover td,.handsontable.listbox tr td.current{background:#eee}.ht_clone_top{z-index:101}.ht_clone_left{z-index:102}.ht_clone_bottom_left_corner,.ht_clone_debug,.ht_clone_top_left_corner{z-index:103}.handsontable td.htSearchResult{background:#fcedd9;color:#583707}.htBordered{border-width:1px}.htBordered.htTopBorderSolid{border-top-style:solid;border-top-color:#000}.htBordered.htRightBorderSolid{border-right-style:solid;border-right-color:#000}.htBordered.htBottomBorderSolid{border-bottom-style:solid;border-bottom-color:#000}.htBordered.htLeftBorderSolid{border-left-style:solid;border-left-color:#000}.handsontable tbody tr th:nth-last-child(2){border-right:1px solid #ccc}.handsontable thead tr:nth-last-child(2) th.htGroupIndicatorContainer{border-bottom:1px solid #ccc;padding-bottom:5px}.ht_clone_top_left_corner thead tr th:nth-last-child(2){border-right:1px solid #ccc}.htCollapseButton{width:10px;height:10px;line-height:10px;text-align:center;border-radius:5px;border:1px solid #f3f3f3;-webkit-box-shadow:1px 1px 3px rgba(0,0,0,.4);box-shadow:1px 1px 3px rgba(0,0,0,.4);cursor:pointer;margin-bottom:3px;position:relative}.htCollapseButton:after{content:"";height:300%;width:1px;display:block;background:#ccc;margin-left:4px;position:absolute;bottom:10px}thead .htCollapseButton{right:5px;position:absolute;top:5px;background:#fff}thead .htCollapseButton:after{height:1px;width:700%;right:10px;top:4px}.handsontable tr th .htExpandButton{position:absolute;width:10px;height:10px;line-height:10px;text-align:center;border-radius:5px;border:1px solid #f3f3f3;-webkit-box-shadow:1px 1px 3px rgba(0,0,0,.4);box-shadow:1px 1px 3px rgba(0,0,0,.4);cursor:pointer;top:0;display:none}.handsontable thead tr th .htExpandButton{top:5px}.handsontable tr th .htExpandButton.clickable{display:block}.collapsibleIndicator{position:absolute;top:50%;transform:translateY(-50%);right:5px;border:1px solid #a6a6a6;line-height:10px;color:#222;border-radius:10px;font-size:10px;width:10px;height:10px;cursor:pointer;-webkit-box-shadow:0 0 0 6px #eee;-moz-box-shadow:0 0 0 6px #eee;box-shadow:0 0 0 6px #eee;background:#eee}.handsontable col.hidden{width:0!important}.handsontable table tr th.lightRightBorder{border-right:1px solid #e6e6e6}.handsontable tr.hidden,.handsontable tr.hidden td,.handsontable tr.hidden th{display:none}.ht_clone_bottom,.ht_clone_left,.ht_clone_top,.ht_master{overflow:hidden}.ht_master .wtHolder{overflow:auto}.handsontable .ht_clone_left thead,.handsontable .ht_master thead,.handsontable .ht_master tr th{visibility:hidden}.ht_clone_bottom .wtHolder,.ht_clone_left .wtHolder,.ht_clone_top .wtHolder{overflow:hidden}.handsontable.mobile,.handsontable.mobile .wtHolder{-webkit-touch-callout:none;-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-tap-highlight-color:rgba(0,0,0,0);-webkit-overflow-scrolling:touch}.htMobileEditorContainer{display:none;position:absolute;top:0;width:70%;height:54pt;background:#f8f8f8;border-radius:20px;border:1px solid #ebebeb;z-index:999;box-sizing:border-box;-webkit-box-sizing:border-box;-webkit-text-size-adjust:none}.topLeftSelectionHandle-HitArea:not(.ht_master .topLeftSelectionHandle-HitArea),.topLeftSelectionHandle:not(.ht_master .topLeftSelectionHandle){z-index:9999}.bottomRightSelectionHandle,.bottomRightSelectionHandle-HitArea,.topLeftSelectionHandle,.topLeftSelectionHandle-HitArea{left:-10000px;top:-10000px}.htMobileEditorContainer.active{display:block}.htMobileEditorContainer .inputs{position:absolute;right:210pt;bottom:10pt;top:10pt;left:14px;height:34pt}.htMobileEditorContainer .inputs textarea{font-size:13pt;border:1px solid #a1a1a1;-webkit-appearance:none;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;position:absolute;left:14px;right:14px;top:0;bottom:0;padding:7pt}.htMobileEditorContainer .cellPointer{position:absolute;top:-13pt;height:0;width:0;left:30px;border-left:13pt solid transparent;border-right:13pt solid transparent;border-bottom:13pt solid #ebebeb}.htMobileEditorContainer .cellPointer.hidden{display:none}.htMobileEditorContainer .cellPointer:before{content:"";display:block;position:absolute;top:2px;height:0;width:0;left:-13pt;border-left:13pt solid transparent;border-right:13pt solid transparent;border-bottom:13pt solid #f8f8f8}.htMobileEditorContainer .moveHandle{position:absolute;top:10pt;left:5px;width:30px;bottom:0;cursor:move;z-index:9999}.htMobileEditorContainer .moveHandle:after{content:"..\a..\a..\a..";white-space:pre;line-height:10px;font-size:20pt;display:inline-block;margin-top:-8px;color:#ebebeb}.htMobileEditorContainer .positionControls{width:205pt;position:absolute;right:5pt;top:0;bottom:0}.htMobileEditorContainer .positionControls>div{width:50pt;height:100%;float:left}.htMobileEditorContainer .positionControls>div:after{content:" ";display:block;width:15pt;height:15pt;text-align:center;line-height:50pt}.htMobileEditorContainer .downButton:after,.htMobileEditorContainer .leftButton:after,.htMobileEditorContainer .rightButton:after,.htMobileEditorContainer .upButton:after{transform-origin:5pt 5pt;-webkit-transform-origin:5pt 5pt;margin:21pt 0 0 21pt}.htMobileEditorContainer .leftButton:after{border-top:2px solid #288ffe;border-left:2px solid #288ffe;-webkit-transform:rotate(-45deg)}.htMobileEditorContainer .leftButton:active:after{border-color:#cfcfcf}.htMobileEditorContainer .rightButton:after{border-top:2px solid #288ffe;border-left:2px solid #288ffe;-webkit-transform:rotate(135deg)}.htMobileEditorContainer .rightButton:active:after{border-color:#cfcfcf}.htMobileEditorContainer .upButton:after{border-top:2px solid #288ffe;border-left:2px solid #288ffe;-webkit-transform:rotate(45deg)}.htMobileEditorContainer .upButton:active:after{border-color:#cfcfcf}.htMobileEditorContainer .downButton:after{border-top:2px solid #288ffe;border-left:2px solid #288ffe;-webkit-transform:rotate(225deg)}.htMobileEditorContainer .downButton:active:after{border-color:#cfcfcf}.handsontable.hide-tween{-webkit-animation:opacity-hide .3s;animation:opacity-hide .3s;animation-fill-mode:forwards;-webkit-animation-fill-mode:forwards}.handsontable.show-tween{-webkit-animation:opacity-show .3s;animation:opacity-show .3s;animation-fill-mode:forwards;-webkit-animation-fill-mode:forwards}
35
 
36
+ /*!
37
+ * Pikaday
38
+ * Copyright © 2014 David Bushell | BSD & MIT license | http://dbushell.com/
39
+ */.pika-single{z-index:9999;display:block;position:relative;color:#333;background:#fff;border:1px solid;border-color:#ccc #ccc #bbb;font-family:Helvetica Neue,Helvetica,Arial,sans-serif}.pika-single:after,.pika-single:before{content:" ";display:table}.pika-single:after{clear:both}.pika-single{*zoom:1}.pika-single.is-hidden{display:none}.pika-single.is-bound{position:absolute;box-shadow:0 5px 15px -5px rgba(0,0,0,.5)}.pika-lendar{float:left;width:240px;margin:8px}.pika-title{position:relative;text-align:center}.pika-label{display:inline-block;*display:inline;position:relative;z-index:9999;overflow:hidden;margin:0;padding:5px 3px;font-size:14px;line-height:20px;font-weight:700;background-color:#fff}.pika-title select{cursor:pointer;position:absolute;z-index:9998;margin:0;left:0;top:5px;filter:alpha(opacity=0);opacity:0}.pika-next,.pika-prev{display:block;cursor:pointer;position:relative;outline:none;border:0;padding:0;width:20px;height:30px;text-indent:20px;white-space:nowrap;overflow:hidden;background-color:transparent;background-position:50%;background-repeat:no-repeat;background-size:75% 75%;opacity:.5;*position:absolute;*top:0}.pika-next:hover,.pika-prev:hover{opacity:1}.is-rtl .pika-next,.pika-prev{float:left;background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAeCAYAAAAsEj5rAAAAUklEQVR42u3VMQoAIBADQf8Pgj+OD9hG2CtONJB2ymQkKe0HbwAP0xucDiQWARITIDEBEnMgMQ8S8+AqBIl6kKgHiXqQqAeJepBo/z38J/U0uAHlaBkBl9I4GwAAAABJRU5ErkJggg==");*left:0}.is-rtl .pika-prev,.pika-next{float:right;background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAeCAYAAAAsEj5rAAAAU0lEQVR42u3VOwoAMAgE0dwfAnNjU26bYkBCFGwfiL9VVWoO+BJ4Gf3gtsEKKoFBNTCoCAYVwaAiGNQGMUHMkjGbgjk2mIONuXo0nC8XnCf1JXgArVIZAQh5TKYAAAAASUVORK5CYII=");*right:0}.pika-next.is-disabled,.pika-prev.is-disabled{cursor:default;opacity:.2}.pika-select{display:inline-block;*display:inline}.pika-table{width:100%;border-collapse:collapse;border-spacing:0;border:0}.pika-table td,.pika-table th{width:14.285714285714286%;padding:0}.pika-table th{color:#999;font-size:12px;line-height:25px;font-weight:700;text-align:center}.pika-button{cursor:pointer;display:block;box-sizing:border-box;-moz-box-sizing:border-box;outline:none;border:0;margin:0;width:100%;padding:5px;color:#666;font-size:12px;line-height:15px;text-align:right;background:#f5f5f5}.pika-week{font-size:11px;color:#999}.is-today .pika-button{color:#3af;font-weight:700}.is-selected .pika-button{color:#fff;font-weight:700;background:#3af;box-shadow:inset 0 1px 3px #178fe5;border-radius:3px}.is-inrange .pika-button{background:#d5e9f7}.is-startrange .pika-button{color:#fff;background:#6cb31d;box-shadow:none;border-radius:3px}.is-endrange .pika-button{color:#fff;background:#3af;box-shadow:none;border-radius:3px}.is-disabled .pika-button,.is-outside-current-month .pika-button{pointer-events:none;cursor:default;color:#999;opacity:.3}.pika-button:hover{color:#fff;background:#ff8000;box-shadow:none;border-radius:3px}.pika-table abbr{border-bottom:none;cursor:help}.htCommentCell{position:relative}.htCommentCell:after{content:"";position:absolute;top:0;right:0;border-left:6px solid transparent;border-top:6px solid #000}.htComments{display:none;z-index:1059;position:absolute}.htCommentTextArea{box-shadow:0 1px 3px rgba(0,0,0,.117647),0 1px 2px rgba(0,0,0,.239216);-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;border:none;border-left:3px solid #ccc;background-color:#fff;width:215px;height:90px;font-size:12px;padding:5px;outline:0!important;-webkit-appearance:none}.htCommentTextArea:focus{box-shadow:0 1px 3px rgba(0,0,0,.117647),0 1px 2px rgba(0,0,0,.239216),inset 0 0 0 1px #5292f7;border-left:3px solid #5292f7}
 
40
 
41
+ /*!
42
+ * Handsontable ContextMenu
43
+ */.htContextMenu:not(.htGhostTable){display:none;position:absolute;z-index:1060}.htContextMenu .ht_clone_corner,.htContextMenu .ht_clone_debug,.htContextMenu .ht_clone_left,.htContextMenu .ht_clone_top{display:none}.htContextMenu table.htCore{border-color:#ccc;border-style:solid;border-width:1px 2px 2px 1px}.htContextMenu .wtBorder{visibility:hidden}.htContextMenu table tbody tr td{background:#fff;border-width:0;padding:4px 6px 0;cursor:pointer;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.htContextMenu table tbody tr td:first-child{border:0}.htContextMenu table tbody tr td.htDimmed{font-style:normal;color:#323232}.htContextMenu table tbody tr td.current,.htContextMenu table tbody tr td.zeroclipboard-is-hover{background:#f3f3f3}.htContextMenu table tbody tr td.htSeparator{border-top:1px solid #e6e6e6;height:0;padding:0;cursor:default}.htContextMenu table tbody tr td.htDisabled{color:#999;cursor:default}.htContextMenu table tbody tr td.htDisabled:hover{background:#fff;color:#999;cursor:default}.htContextMenu table tbody tr.htHidden{display:none}.htContextMenu table tbody tr td .htItemWrapper{margin-left:10px;margin-right:6px}.htContextMenu table tbody tr td div span.selected{margin-top:-2px;position:absolute;left:4px}.htContextMenu .ht_master .wtHolder{overflow:hidden}textarea#HandsontableCopyPaste{position:fixed!important;top:0!important;right:100%!important;overflow:hidden;opacity:0;outline:0 none!important}.htRowHeaders .ht_master.innerBorderLeft~.ht_clone_left td:first-of-type,.htRowHeaders .ht_master.innerBorderLeft~.ht_clone_top_left_corner th:nth-child(2){border-left:0}.handsontable.ht__manualColumnMove.after-selection--columns thead th.ht__highlight{cursor:move;cursor:-moz-grab;cursor:-webkit-grab;cursor:grab}.handsontable.ht__manualColumnMove.on-moving--columns,.handsontable.ht__manualColumnMove.on-moving--columns thead th.ht__highlight{cursor:move;cursor:-moz-grabbing;cursor:-webkit-grabbing;cursor:grabbing}.handsontable.ht__manualColumnMove.on-moving--columns .manualColumnResizer{display:none}.handsontable .ht__manualColumnMove--backlight,.handsontable .ht__manualColumnMove--guideline{position:absolute;height:100%;display:none}.handsontable .ht__manualColumnMove--guideline{background:#757575;width:2px;top:0;margin-left:-1px;z-index:105}.handsontable .ht__manualColumnMove--backlight{background:#343434;background:rgba(52,52,52,.25);display:none;z-index:105;pointer-events:none}.handsontable.on-moving--columns .ht__manualColumnMove--backlight,.handsontable.on-moving--columns.show-ui .ht__manualColumnMove--guideline{display:block}.handsontable .wtHider{position:relative}.handsontable.ht__manualRowMove.after-selection--rows tbody th.ht__highlight{cursor:move;cursor:-moz-grab;cursor:-webkit-grab;cursor:grab}.handsontable.ht__manualRowMove.on-moving--rows,.handsontable.ht__manualRowMove.on-moving--rows tbody th.ht__highlight{cursor:move;cursor:-moz-grabbing;cursor:-webkit-grabbing;cursor:grabbing}.handsontable.ht__manualRowMove.on-moving--rows .manualRowResizer{display:none}.handsontable .ht__manualRowMove--backlight,.handsontable .ht__manualRowMove--guideline{position:absolute;width:100%;display:none}.handsontable .ht__manualRowMove--guideline{background:#757575;height:2px;left:0;margin-top:-1px;z-index:105}.handsontable .ht__manualRowMove--backlight{background:#343434;background:rgba(52,52,52,.25);display:none;z-index:105;pointer-events:none}.handsontable.on-moving--rows .ht__manualRowMove--backlight,.handsontable.on-moving--rows.show-ui .ht__manualRowMove--guideline{display:block}.handsontable tbody td[rowspan][class*=area][class*=highlight]:not([class*=fullySelectedMergedCell]):before{opacity:0}.handsontable tbody td[rowspan][class*=area][class*=highlight][class*=fullySelectedMergedCell-multiple]:before{opacity:.1}.handsontable tbody td[rowspan][class*=area][class*=highlight][class*=fullySelectedMergedCell-0]:before{opacity:.1}.handsontable tbody td[rowspan][class*=area][class*=highlight][class*=fullySelectedMergedCell-1]:before{opacity:.2}.handsontable tbody td[rowspan][class*=area][class*=highlight][class*=fullySelectedMergedCell-2]:before{opacity:.27}.handsontable tbody td[rowspan][class*=area][class*=highlight][class*=fullySelectedMergedCell-3]:before{opacity:.35}.handsontable tbody td[rowspan][class*=area][class*=highlight][class*=fullySelectedMergedCell-4]:before{opacity:.41}.handsontable tbody td[rowspan][class*=area][class*=highlight][class*=fullySelectedMergedCell-5]:before{opacity:.47}.handsontable tbody td[rowspan][class*=area][class*=highlight][class*=fullySelectedMergedCell-6]:before{opacity:.54}.handsontable tbody td[rowspan][class*=area][class*=highlight][class*=fullySelectedMergedCell-7]:before{opacity:.58}
 
 
 
 
44
 
45
+ /*!
46
+ * Handsontable DropdownMenu
47
+ */.handsontable .changeType{background:#eee;border-radius:2px;border:1px solid #bbb;color:#bbb;font-size:9px;line-height:9px;padding:2px;margin:3px 1px 0 5px;float:right}.handsontable .changeType:before{content:"\25BC\ "}.handsontable .changeType:hover{border:1px solid #777;color:#777;cursor:pointer}.htDropdownMenu:not(.htGhostTable){display:none;position:absolute;z-index:1060}.htDropdownMenu .ht_clone_corner,.htDropdownMenu .ht_clone_debug,.htDropdownMenu .ht_clone_left,.htDropdownMenu .ht_clone_top{display:none}.htDropdownMenu table.htCore{border-color:#bbb;border-style:solid;border-width:1px 2px 2px 1px}.htDropdownMenu .wtBorder{visibility:hidden}.htDropdownMenu table tbody tr td{background:#fff;border-width:0;padding:4px 6px 0;cursor:pointer;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.htDropdownMenu table tbody tr td:first-child{border:0}.htDropdownMenu table tbody tr td.htDimmed{font-style:normal;color:#323232}.htDropdownMenu table tbody tr td.current,.htDropdownMenu table tbody tr td.zeroclipboard-is-hover{background:#e9e9e9}.htDropdownMenu table tbody tr td.htSeparator{border-top:1px solid #e6e6e6;height:0;padding:0;cursor:default}.htDropdownMenu table tbody tr td.htDisabled{color:#999}.htDropdownMenu table tbody tr td.htDisabled:hover{background:#fff;color:#999;cursor:default}.htDropdownMenu:not(.htGhostTable) table tbody tr.htHidden{display:none}.htDropdownMenu table tbody tr td .htItemWrapper{margin-left:10px;margin-right:10px}.htDropdownMenu table tbody tr td div span.selected{margin-top:-2px;position:absolute;left:4px}.htDropdownMenu .ht_master .wtHolder{overflow:hidden}.handsontable span.colHeader.columnSorting:after{top:50%;margin-top:-2px;position:absolute;right:-15px;padding-left:5px;font-size:8px;height:8px;line-height:1.1;text-decoration:underline}.handsontable span.colHeader.columnSorting:after{text-decoration:none}.handsontable span.colHeader.columnSorting[class*=" sort-"]:after,.handsontable span.colHeader.columnSorting[class^=sort-]:after{content:"+"}.handsontable span.colHeader.columnSorting.sort-1:after{content:"1"}.handsontable span.colHeader.columnSorting.sort-2:after{content:"2"}.handsontable span.colHeader.columnSorting.sort-3:after{content:"3"}.handsontable span.colHeader.columnSorting.sort-4:after{content:"4"}.handsontable span.colHeader.columnSorting.sort-5:after{content:"5"}.handsontable span.colHeader.columnSorting.sort-6:after{content:"6"}.handsontable span.colHeader.columnSorting.sort-7:after{content:"7"}.htGhostTable th div button.changeType+span.colHeader.columnSorting:not(.indicatorDisabled){padding-right:5px}
48
 
49
+ /*!
50
+ * Handsontable Filters
51
+ */.htFiltersConditionsMenu:not(.htGhostTable){display:none;position:absolute;z-index:1070}.htFiltersConditionsMenu .ht_clone_corner,.htFiltersConditionsMenu .ht_clone_debug,.htFiltersConditionsMenu .ht_clone_left,.htFiltersConditionsMenu .ht_clone_top{display:none}.htFiltersConditionsMenu table.htCore{border-color:#bbb;border-style:solid;border-width:1px 2px 2px 1px}.htFiltersConditionsMenu .wtBorder{visibility:hidden}.htFiltersConditionsMenu table tbody tr td{background:#fff;border-width:0;padding:4px 6px 0;cursor:pointer;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.htFiltersConditionsMenu table tbody tr td:first-child{border:0}.htFiltersConditionsMenu table tbody tr td.htDimmed{font-style:normal;color:#323232}.htFiltersConditionsMenu table tbody tr td.current,.htFiltersConditionsMenu table tbody tr td.zeroclipboard-is-hover{background:#e9e9e9}.htFiltersConditionsMenu table tbody tr td.htSeparator{border-top:1px solid #e6e6e6;height:0;padding:0}.htFiltersConditionsMenu table tbody tr td.htDisabled{color:#999}.htFiltersConditionsMenu table tbody tr td.htDisabled:hover{background:#fff;color:#999;cursor:default}.htFiltersConditionsMenu table tbody tr td .htItemWrapper{margin-left:10px;margin-right:10px}.htFiltersConditionsMenu table tbody tr td div span.selected{margin-top:-2px;position:absolute;left:4px}.htFiltersConditionsMenu .ht_master .wtHolder{overflow:hidden}.handsontable .htMenuFiltering{border-bottom:1px dotted #ccc;height:135px;overflow:hidden}.handsontable .ht_master table td.htCustomMenuRenderer{background-color:#fff;cursor:auto}.handsontable .htFiltersMenuLabel{font-size:.75em}.handsontable .htFiltersMenuActionBar{text-align:center;padding-top:10px;padding-bottom:3px}.handsontable .htFiltersMenuCondition.border{border-bottom:1px dotted #ccc!important}.handsontable .htFiltersMenuCondition .htUIInput{padding:0 0 5px}.handsontable .htFiltersMenuValue{border-bottom:1px dotted #ccc!important}.handsontable .htFiltersMenuValue .htUIMultipleSelectSearch{padding:0}.handsontable .htFiltersMenuCondition .htUIInput input,.handsontable .htFiltersMenuValue .htUIMultipleSelectSearch input{font-family:inherit;font-size:.75em;padding:4px;box-sizing:border-box;width:100%}.htUIMultipleSelect .ht_master .wtHolder{overflow-y:scroll}.handsontable .htFiltersActive .changeType{border:1px solid #509272;color:#18804e;background-color:#d2e0d9}.handsontable .htUISelectAll{margin-right:10px}.handsontable .htUIClearAll,.handsontable .htUISelectAll{display:inline-block}.handsontable .htUIClearAll a,.handsontable .htUISelectAll a{color:#3283d8;font-size:.75em}.handsontable .htUISelectionControls{text-align:right}.handsontable .htCheckboxRendererInput{margin:0 5px 0 0;vertical-align:middle;height:1em}.handsontable .htUIInput{padding:3px 0 7px;position:relative;text-align:center}.handsontable .htUIInput input{border-radius:2px;border:1px solid #d2d1d1}.handsontable .htUIInput input:focus{outline:0}.handsontable .htUIInputIcon{position:absolute}.handsontable .htUIInput.htUIButton{cursor:pointer;display:inline-block}.handsontable .htUIInput.htUIButton input{background-color:#eee;color:#000;cursor:pointer;font-family:inherit;font-size:.7em;font-weight:700;height:19px;min-width:64px}.handsontable .htUIInput.htUIButton input:hover{border-color:#b9b9b9}.handsontable .htUIInput.htUIButtonOK{margin-right:10px}.handsontable .htUIInput.htUIButtonOK input{background-color:#0f9d58;border-color:#18804e;color:#fff}.handsontable .htUIInput.htUIButtonOK input:hover{border-color:#1a6f46}.handsontable .htUISelect{cursor:pointer;margin-bottom:7px;position:relative}.handsontable .htUISelectCaption{background-color:#e8e8e8;border-radius:2px;border:1px solid #d2d1d1;font-family:inherit;font-size:.7em;font-weight:700;padding:3px 20px 3px 10px;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.handsontable .htUISelectCaption:hover{background-color:#e8e8e8;border:1px solid #b9b9b9}.handsontable .htUISelectDropdown:after{content:"\25B2";font-size:7px;position:absolute;right:10px;top:0}.handsontable .htUISelectDropdown:before{content:"\25BC";font-size:7px;position:absolute;right:10px;top:8px}.handsontable .htUIMultipleSelect .handsontable .htCore{border:none}.handsontable .htUIMultipleSelect .handsontable .htCore td:hover{background-color:#f5f5f5}.handsontable .htUIMultipleSelectSearch input{border-radius:2px;border:1px solid #d2d1d1;padding:3px}.handsontable .htUIRadio{display:inline-block;margin-right:5px;height:100%}.handsontable .htUIRadio:last-child{margin-right:0}.handsontable .htUIRadio>input[type=radio]{margin-right:.5ex}.handsontable .htUIRadio label{vertical-align:middle}.handsontable .htFiltersMenuOperators{padding-bottom:5px}.handsontable.ganttChart tr:first-child th div.relative{padding-right:21px}.handsontable.ganttChart .colHeader{display:block}.handsontable.ganttChart td.rangeBar{background:#48b703;border-right-width:0;position:relative;-webkit-box-shadow:inset 0 3px 0 #fff;-moz-box-shadow:inset 0 3px 0 #fff;box-shadow:inset 0 3px 0 #fff}.handsontable.ganttChart td.rangeBar.last{border-right-width:1px}.handsontable.ganttChart td.rangeBar.area{background:#7ec481}.handsontable.ganttChart td.rangeBar.partial{background:#8edf5a}.handsontable.ganttChart td.rangeBar.area.partial{background:#a1d8ad}.handsontable thead th.hiddenHeader:not(:first-of-type){display:none}.handsontable th.ht_nestingLevels{text-align:left;padding-left:7px}.handsontable th div.ht_nestingLevels{display:inline-block;position:absolute;left:11px}.handsontable.innerBorderLeft th div.ht_nestingLevels,.handsontable.innerBorderLeft~.handsontable th div.ht_nestingLevels{right:10px}.handsontable th span.ht_nestingLevel{display:inline-block}.handsontable th span.ht_nestingLevel_empty{display:inline-block;width:10px;height:1px;float:left}.handsontable th span.ht_nestingLevel:after{content:"\2510";font-size:9px;display:inline-block;position:relative;bottom:3px}.handsontable th div.ht_nestingButton{display:inline-block;position:absolute;right:-2px;cursor:pointer}.handsontable th div.ht_nestingButton.ht_nestingExpand:after{content:"\002B"}.handsontable th div.ht_nestingButton.ht_nestingCollapse:after{content:"\002D"}.handsontable.innerBorderLeft th div.ht_nestingButton,.handsontable.innerBorderLeft~.handsontable th div.ht_nestingButton{right:0}.handsontable th.beforeHiddenColumn{position:relative}.handsontable th.afterHiddenColumn:before,.handsontable th.beforeHiddenColumn:after{color:#bbb;position:absolute;top:50%;font-size:5pt;transform:translateY(-50%)}.handsontable th.afterHiddenColumn{position:relative}.handsontable th.beforeHiddenColumn:after{right:1px;content:"\25C0"}.handsontable th.afterHiddenColumn:before{left:1px;content:"\25B6"}.handsontable td.firstVisibleColumn,.handsontable th.firstVisibleColumn{border-left:1px solid #ccc}
 
 
 
 
52
 
53
+ /*!
54
+ * Handsontable HiddenRows
55
+ */.handsontable th.afterHiddenRow:after,.handsontable th.beforeHiddenRow:before{color:#bbb;font-size:6pt;line-height:6pt;position:absolute;left:2px}.handsontable th.afterHiddenRow,.handsontable th.beforeHiddenRow{position:relative}.handsontable th.beforeHiddenRow:before{content:"\25B2";bottom:2px}.handsontable th.afterHiddenRow:after{content:"\25BC";top:2px}.handsontable.ht__selection--rows tbody th.afterHiddenRow.ht__highlight:after,.handsontable.ht__selection--rows tbody th.beforeHiddenRow.ht__highlight:before{color:#eee}.handsontable td.afterHiddenRow.firstVisibleRow,.handsontable th.afterHiddenRow.firstVisibleRow{border-top:1px solid #ccc}
 
 
 
src/SupsysticTables/Tables/assets/libraries/handsontable/handsontable.full.min.js CHANGED
@@ -1,97 +1,46 @@
1
  /*!
2
- (The MIT License)
3
-
4
- Copyright (c) 2012-2014 Marcin Warpechowski
5
- Copyright (c) 2015 Handsoncode sp. z o.o. <hello@handsoncode.net>
6
-
7
- Permission is hereby granted, free of charge, to any person obtaining
8
- a copy of this software and associated documentation files (the
9
- 'Software'), to deal in the Software without restriction, including
10
- without limitation the rights to use, copy, modify, merge, publish,
11
- distribute, sublicense, and/or sell copies of the Software, and to
12
- permit persons to whom the Software is furnished to do so, subject to
13
- the following conditions:
14
-
15
- The above copyright notice and this permission notice shall be
16
- included in all copies or substantial portions of the Software.
17
-
18
- THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
19
- EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
20
- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
21
- IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
22
- CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
23
- TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
24
- SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
25
-
26
- */
27
- !function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var t;t="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this,t.Handsontable=e()}}(function(){var e;return function e(t,o,n){function r(a,l){if(!o[a]){if(!t[a]){var u="function"==typeof require&&require;if(!l&&u)return u(a,!0);if(i)return i(a,!0);if(s[a]&&void 0!==window[s[a]])return window[s[a]];var c=new Error("Cannot find module '"+a+"'");throw c.code="MODULE_NOT_FOUND",c}var d=o[a]={exports:{}};t[a][0].call(d.exports,function(e){var o=t[a][1][e];return r(o?o:e)},d,d.exports,e,t,o,n)}return o[a].exports}for(var i="function"==typeof require&&require,s=JSON.parse('{"zeroclipboard":"ZeroClipboard","moment":"moment","numbro":"numbro","pikaday":"Pikaday"}')||{},a=0;a<n.length;a++)r(n[a]);return r}({1:[function(e,t,o){},{}],2:[function(e,t,o){window.jQuery&&function(e){e.fn.handsontable=function(e){var t,o,n,r,i,s=this.first(),a=s.data("handsontable");if("string"!=typeof e)return i=e||{},a?a.updateSettings(i):(a=new Handsontable.Core(s[0],i),s.data("handsontable",a),a.init()),s;if(n=[],arguments.length>1)for(t=1,o=arguments.length;t<o;t++)n.push(arguments[t]);if(a){if(void 0===a[e])throw new Error("Handsontable do not provide action: "+e);r=a[e].apply(a,n),"destroy"===e&&s.removeData()}return r}}(window.jQuery)},{}],3:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableBorder:{get:function(){return C}},__esModule:{value:!0}});var n,r,i,s,a,l,u=(n=e("helpers/dom/element"))&&n.__esModule&&n||{default:n},c=u.getComputedStyle,d=u.getTrimmingContainer,h=u.innerWidth,f=u.innerHeight,p=u.offset,g=u.outerHeight,m=u.outerWidth,w=((r=e("helpers/dom/event"))&&r.__esModule&&r||{default:r}).stopImmediatePropagation,v=((i=e("helpers/browser"))&&i.__esModule&&i||{default:i}).isMobileBrowser,y=((s=e("eventManager"))&&s.__esModule&&s||{default:s}).EventManager,b=((a=e("cell/coords"))&&a.__esModule&&a||{default:a}).WalkontableCellCoords,C=(((l=e("overlay/_base.js"))&&l.__esModule&&l||{default:l}).WalkontableOverlay,function(e,t){t&&(this.eventManager=new y(e),this.instance=e,this.wot=e,this.settings=t,this.mouseDown=!1,this.main=null,this.top=null,this.left=null,this.bottom=null,this.right=null,this.topStyle=null,this.leftStyle=null,this.bottomStyle=null,this.rightStyle=null,this.cornerDefaultStyle={width:"5px",height:"5px",borderWidth:"2px",borderStyle:"solid",borderColor:"#FFF"},this.corner=null,this.cornerStyle=null,this.createBorders(t),this.registerListeners())});$traceurRuntime.createClass(C,{registerListeners:function(){var e=this;this.eventManager.addEventListener(document.body,"mousedown",function(){return e.onMouseDown()}),this.eventManager.addEventListener(document.body,"mouseup",function(){return e.onMouseUp()});for(var t=this,o=0,n=this.main.childNodes.length;o<n;o++)!function(o,n){t.eventManager.addEventListener(t.main.childNodes[o],"mouseenter",function(t){return e.onMouseEnter(t,e.main.childNodes[o])})}(o,n)},onMouseDown:function(){this.mouseDown=!0},onMouseUp:function(){this.mouseDown=!1},onMouseEnter:function(e,t){function o(e){return e.clientY<Math.floor(i.top)||(e.clientY>Math.ceil(i.top+i.height)||(e.clientX<Math.floor(i.left)||(e.clientX>Math.ceil(i.left+i.width)||void 0)))}function n(e){o(e)&&(r.eventManager.removeEventListener(document.body,"mousemove",n),t.style.display="block")}if(this.mouseDown&&this.wot.getSetting("hideBorderOnMouseDownOver")){e.preventDefault(),w(e);var r=this,i=t.getBoundingClientRect();t.style.display="none",this.eventManager.addEventListener(document.body,"mousemove",n)}},createBorders:function(e){this.main=document.createElement("div");var t=["top","left","bottom","right","corner"],o=this.main.style;o.position="absolute",o.top=0,o.left=0;for(var n=0;n<5;n++){var r=t[n],i=document.createElement("div");i.className="wtBorder "+(this.settings.className||""),this.settings[r]&&this.settings[r].hide&&(i.className+=" hidden"),o=i.style,o.backgroundColor=this.settings[r]&&this.settings[r].color?this.settings[r].color:e.border.color,o.height=this.settings[r]&&this.settings[r].width?this.settings[r].width+"px":e.border.width+"px",o.width=this.settings[r]&&this.settings[r].width?this.settings[r].width+"px":e.border.width+"px",this.main.appendChild(i)}this.top=this.main.childNodes[0],this.left=this.main.childNodes[1],this.bottom=this.main.childNodes[2],this.right=this.main.childNodes[3],this.topStyle=this.top.style,this.leftStyle=this.left.style,this.bottomStyle=this.bottom.style,this.rightStyle=this.right.style,this.corner=this.main.childNodes[4],this.corner.className+=" corner",this.cornerStyle=this.corner.style,this.cornerStyle.width=this.cornerDefaultStyle.width,this.cornerStyle.height=this.cornerDefaultStyle.height,this.cornerStyle.border=[this.cornerDefaultStyle.borderWidth,this.cornerDefaultStyle.borderStyle,this.cornerDefaultStyle.borderColor].join(" "),v()&&this.createMultipleSelectorHandles(),this.disappear(),this.wot.wtTable.bordersHolder||(this.wot.wtTable.bordersHolder=document.createElement("div"),this.wot.wtTable.bordersHolder.className="htBorders",this.wot.wtTable.spreader.appendChild(this.wot.wtTable.bordersHolder)),this.wot.wtTable.bordersHolder.insertBefore(this.main,this.wot.wtTable.bordersHolder.firstChild)},createMultipleSelectorHandles:function(){this.selectionHandles={topLeft:document.createElement("DIV"),topLeftHitArea:document.createElement("DIV"),bottomRight:document.createElement("DIV"),bottomRightHitArea:document.createElement("DIV")};this.selectionHandles.topLeft.className="topLeftSelectionHandle",this.selectionHandles.topLeftHitArea.className="topLeftSelectionHandle-HitArea",this.selectionHandles.bottomRight.className="bottomRightSelectionHandle",this.selectionHandles.bottomRightHitArea.className="bottomRightSelectionHandle-HitArea",this.selectionHandles.styles={topLeft:this.selectionHandles.topLeft.style,topLeftHitArea:this.selectionHandles.topLeftHitArea.style,bottomRight:this.selectionHandles.bottomRight.style,bottomRightHitArea:this.selectionHandles.bottomRightHitArea.style};var e={position:"absolute",height:"40px",width:"40px","border-radius":parseInt(40/1.5,10)+"px"};for(var t in e)e.hasOwnProperty(t)&&(this.selectionHandles.styles.bottomRightHitArea[t]=e[t],this.selectionHandles.styles.topLeftHitArea[t]=e[t]);var o={position:"absolute",height:"10px",width:"10px","border-radius":parseInt(10/1.5,10)+"px",background:"#F5F5FF",border:"1px solid #4285c8"};for(var n in o)o.hasOwnProperty(n)&&(this.selectionHandles.styles.bottomRight[n]=o[n],this.selectionHandles.styles.topLeft[n]=o[n]);this.main.appendChild(this.selectionHandles.topLeft),this.main.appendChild(this.selectionHandles.bottomRight),this.main.appendChild(this.selectionHandles.topLeftHitArea),this.main.appendChild(this.selectionHandles.bottomRightHitArea)},isPartRange:function(e,t){return!(!this.wot.selections.area.cellRange||e==this.wot.selections.area.cellRange.to.row&&t==this.wot.selections.area.cellRange.to.col)},updateMultipleSelectionHandlesPosition:function(e,t,o,n,r,i){var s=parseInt(this.selectionHandles.styles.topLeft.width,10),a=parseInt(this.selectionHandles.styles.topLeftHitArea.width,10);this.selectionHandles.styles.topLeft.top=parseInt(o-s,10)+"px",this.selectionHandles.styles.topLeft.left=parseInt(n-s,10)+"px",this.selectionHandles.styles.topLeftHitArea.top=parseInt(o-a/4*3,10)+"px",this.selectionHandles.styles.topLeftHitArea.left=parseInt(n-a/4*3,10)+"px",this.selectionHandles.styles.bottomRight.top=parseInt(o+i,10)+"px",this.selectionHandles.styles.bottomRight.left=parseInt(n+r,10)+"px",this.selectionHandles.styles.bottomRightHitArea.top=parseInt(o+i-a/4,10)+"px",this.selectionHandles.styles.bottomRightHitArea.left=parseInt(n+r-a/4,10)+"px",this.settings.border.multipleSelectionHandlesVisible&&this.settings.border.multipleSelectionHandlesVisible()?(this.selectionHandles.styles.topLeft.display="block",this.selectionHandles.styles.topLeftHitArea.display="block",this.isPartRange(e,t)?(this.selectionHandles.styles.bottomRight.display="none",this.selectionHandles.styles.bottomRightHitArea.display="none"):(this.selectionHandles.styles.bottomRight.display="block",this.selectionHandles.styles.bottomRightHitArea.display="block")):(this.selectionHandles.styles.topLeft.display="none",this.selectionHandles.styles.bottomRight.display="none",this.selectionHandles.styles.topLeftHitArea.display="none",this.selectionHandles.styles.bottomRightHitArea.display="none"),e==this.wot.wtSettings.getSetting("fixedRowsTop")||t==this.wot.wtSettings.getSetting("fixedColumnsLeft")?(this.selectionHandles.styles.topLeft.zIndex="9999",this.selectionHandles.styles.topLeftHitArea.zIndex="9999"):(this.selectionHandles.styles.topLeft.zIndex="",this.selectionHandles.styles.topLeftHitArea.zIndex="")},appear:function(e){if(!this.disabled){var t,o,n,r,i,s,a,l,u,w,y,C,_,R,M,S,E,O;O=this.wot.wtTable.getRenderedRowsCount();for(var T=0;T<O;T++){var k=this.wot.wtTable.rowFilter.renderedToSource(T);if(k>=e[0]&&k<=e[2]){_=k;break}}for(var x=O-1;x>=0;x--){var H=this.wot.wtTable.rowFilter.renderedToSource(x);if(H>=e[0]&&H<=e[2]){M=H;break}}O=this.wot.wtTable.getRenderedColumnsCount();for(var D=0;D<O;D++){var A=this.wot.wtTable.columnFilter.renderedToSource(D);if(A>=e[1]&&A<=e[3]){R=A;break}}for(var P=O-1;P>=0;P--){var L=this.wot.wtTable.columnFilter.renderedToSource(P);if(L>=e[1]&&L<=e[3]){S=L;break}}if(void 0===_||void 0===R)return void this.disappear();t=_!==M||R!==S,o=this.wot.wtTable.getCell(new b(_,R)),n=t?this.wot.wtTable.getCell(new b(M,S)):o,r=p(o),i=t?p(n):r,s=p(this.wot.wtTable.TABLE),l=r.top,y=i.top+g(n)-l,w=r.left,C=i.left+m(n)-w,a=l-s.top-1,u=w-s.left-1;var N=c(o);parseInt(N.borderTopWidth,10)>0&&(a+=1,y=y>0?y-1:0),parseInt(N.borderLeftWidth,10)>0&&(u+=1,C=C>0?C-1:0),this.topStyle.top=a+"px",this.topStyle.left=u+"px",this.topStyle.width=C+"px",this.topStyle.display="block",this.leftStyle.top=a+"px",this.leftStyle.left=u+"px",this.leftStyle.height=y+"px",this.leftStyle.display="block";var I=Math.floor(this.settings.border.width/2);this.bottomStyle.top=a+y-I+"px",this.bottomStyle.left=u+"px",this.bottomStyle.width=C+"px",this.bottomStyle.display="block",this.rightStyle.top=a+"px",this.rightStyle.left=u+C-I+"px",this.rightStyle.height=y+1+"px",this.rightStyle.display="block",v()||!this.hasSetting(this.settings.border.cornerVisible)||this.isPartRange(M,S)?this.cornerStyle.display="none":(this.cornerStyle.top=a+y-4+"px",this.cornerStyle.left=u+C-4+"px",this.cornerStyle.borderRightWidth=this.cornerDefaultStyle.borderWidth,this.cornerStyle.width=this.cornerDefaultStyle.width,this.cornerStyle.display="none",E=d(this.wot.wtTable.TABLE),S===this.wot.getSetting("totalColumns")-1&&n.offsetLeft+m(n)+parseInt(this.cornerDefaultStyle.width)/2>=h(E)&&(this.cornerStyle.left=Math.floor(u+C-3-parseInt(this.cornerDefaultStyle.width)/2)+"px",this.cornerStyle.borderRightWidth=0),M===this.wot.getSetting("totalRows")-1&&n.offsetTop+g(n)+parseInt(this.cornerDefaultStyle.height)/2>=f(E)&&(this.cornerStyle.top=Math.floor(a+y-3-parseInt(this.cornerDefaultStyle.height)/2)+"px",this.cornerStyle.borderBottomWidth=0),this.cornerStyle.display="block"),v()&&this.updateMultipleSelectionHandlesPosition(_,R,a,u,C,y)}},disappear:function(){this.topStyle.display="none",this.leftStyle.display="none",this.bottomStyle.display="none",this.rightStyle.display="none",this.cornerStyle.display="none",v()&&(this.selectionHandles.styles.topLeft.display="none",this.selectionHandles.styles.bottomRight.display="none")},hasSetting:function(e){return"function"==typeof e?e():!!e}},{}),window.WalkontableBorder=C},{"cell/coords":6,eventManager:42,"helpers/browser":44,"helpers/dom/element":47,"helpers/dom/event":48,"overlay/_base.js":12}],4:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableViewportColumnsCalculator:{get:function(){return r}},__esModule:{value:!0}});var n=new WeakMap,r=function(e,t,o,r,i,s,a){var l=void 0!==arguments[7]?arguments[7]:function(e){return e};n.set(this,{viewportWidth:e,scrollOffset:t,totalColumns:o,columnWidthFn:r,overrideFn:i,onlyFullyVisible:s,stretchingColumnWidthFn:l}),this.count=0,this.startColumn=null,this.endColumn=null,this.startPosition=null,this.stretchAllRatio=0,this.stretchLastWidth=0,this.stretch=a,this.totalTargetWidth=0,this.needVerifyLastColumnWidth=!0,this.stretchAllColumnsWidth=[],this.calculate()},i=r;$traceurRuntime.createClass(r,{calculate:function(){for(var e,t=0,o=!0,r=[],i=n.get(this),s=i.onlyFullyVisible,a=i.overrideFn,l=i.scrollOffset,u=i.totalColumns,c=i.viewportWidth,d=0;d<u;d++){e=this._getColumnWidth(d),t<=l&&!s&&(this.startColumn=d);var h=l>0?c+1:c;if(t>=l&&t+e<=l+h&&(null==this.startColumn&&(this.startColumn=d),this.endColumn=d),r.push(t),t+=e,s||(this.endColumn=d),t>=l+c){o=!1;break}}if(this.endColumn===u-1&&o)for(this.startColumn=this.endColumn;this.startColumn>0;){var f=r[this.endColumn]+e-r[this.startColumn-1];if((f<=c||!s)&&this.startColumn--,f>c)break}null!==this.startColumn&&a&&a(this),this.startPosition=r[this.startColumn],void 0==this.startPosition&&(this.startPosition=null),null!==this.startColumn&&(this.count=this.endColumn-this.startColumn+1)},refreshStretching:function(e){if("none"!==this.stretch){this.totalTargetWidth=e;for(var t=n.get(this),o=t.totalColumns,r=0,i=0;i<o;i++){var s=this._getColumnWidth(i),a=t.stretchingColumnWidthFn(void 0,i);"number"==typeof a?e-=a:r+=s}var l=e-r;if("all"===this.stretch&&l>0)this.stretchAllRatio=e/r,this.stretchAllColumnsWidth=[],this.needVerifyLastColumnWidth=!0;else if("last"===this.stretch&&e!==1/0){var u=this._getColumnWidth(o-1),c=l+u;this.stretchLastWidth=c>=0?c:u}}},getStretchedColumnWidth:function(e,t){var o=null;return"all"===this.stretch&&0!==this.stretchAllRatio?o=this._getStretchedAllColumnWidth(e,t):"last"===this.stretch&&0!==this.stretchLastWidth&&(o=this._getStretchedLastColumnWidth(e)),o},_getStretchedAllColumnWidth:function(e,t){var o=0,r=n.get(this),i=r.totalColumns;if(!this.stretchAllColumnsWidth[e]){var s=Math.round(t*this.stretchAllRatio),a=r.stretchingColumnWidthFn(s,e);this.stretchAllColumnsWidth[e]=void 0===a?s:isNaN(a)?this._getColumnWidth(e):a}if(this.stretchAllColumnsWidth.length===i&&this.needVerifyLastColumnWidth){this.needVerifyLastColumnWidth=!1;for(var l=0;l<this.stretchAllColumnsWidth.length;l++)o+=this.stretchAllColumnsWidth[l];o!==this.totalTargetWidth&&(this.stretchAllColumnsWidth[this.stretchAllColumnsWidth.length-1]+=this.totalTargetWidth-o)}return this.stretchAllColumnsWidth[e]},_getStretchedLastColumnWidth:function(e){return e===n.get(this).totalColumns-1?this.stretchLastWidth:null},_getColumnWidth:function(e){var t=n.get(this).columnWidthFn(e);return void 0===t&&(t=i.DEFAULT_WIDTH),t}},{get DEFAULT_WIDTH(){return 50}}),window.WalkontableViewportColumnsCalculator=r},{}],5:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableViewportRowsCalculator:{get:function(){return r}},__esModule:{value:!0}});var n=new WeakMap,r=function(e,t,o,r,i,s,a){n.set(this,{viewportHeight:e,scrollOffset:t,totalRows:o,rowHeightFn:r,overrideFn:i,onlyFullyVisible:s,horizontalScrollbarHeight:a}),this.count=0,this.startRow=null,this.endRow=null,this.startPosition=null,this.calculate()},i=r;$traceurRuntime.createClass(r,{calculate:function(){for(var e=0,t=!0,o=[],r=n.get(this),s=r.onlyFullyVisible,a=r.overrideFn,l=r.rowHeightFn,u=r.scrollOffset,c=r.totalRows,d=r.viewportHeight,h=r.horizontalScrollbarHeight||0,f=0;f<c;f++){var p=l(f);if(void 0===p&&(p=i.DEFAULT_HEIGHT),e<=u&&!s&&(this.startRow=f),e>=u&&e+p<=u+d-h&&(null===this.startRow&&(this.startRow=f),this.endRow=f),o.push(e),e+=p,s||(this.endRow=f),e>=u+d-h){t=!1;break}}if(this.endRow===c-1&&t)for(this.startRow=this.endRow;this.startRow>0;){var g=o[this.endRow]+p-o[this.startRow-1];if((g<=d-h||!s)&&this.startRow--,g>=d-h)break}null!==this.startRow&&a&&a(this),this.startPosition=o[this.startRow],void 0==this.startPosition&&(this.startPosition=null),null!==this.startRow&&(this.count=this.endRow-this.startRow+1)}},{get DEFAULT_HEIGHT(){return 23}}),window.WalkontableViewportRowsCalculator=r},{}],6:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableCellCoords:{get:function(){return n}},__esModule:{value:!0}});var n=function(e,t){void 0!==e&&void 0!==t?(this.row=e,this.col=t):(this.row=null,this.col=null)};$traceurRuntime.createClass(n,{isValid:function(e){return!(this.row<0||this.col<0)&&!(this.row>=e.getSetting("totalRows")||this.col>=e.getSetting("totalColumns"))},isEqual:function(e){return e===this||this.row===e.row&&this.col===e.col},isSouthEastOf:function(e){return this.row>=e.row&&this.col>=e.col},isNorthWestOf:function(e){return this.row<=e.row&&this.col<=e.col},isSouthWestOf:function(e){return this.row>=e.row&&this.col<=e.col},isNorthEastOf:function(e){return this.row<=e.row&&this.col>=e.col}},{}),window.WalkontableCellCoords=n},{}],7:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableCellRange:{get:function(){return i}},__esModule:{value:!0}});var n,r=((n=e("cell/coords"))&&n.__esModule&&n||{default:n}).WalkontableCellCoords,i=function(e,t,o){this.highlight=e,this.from=t,this.to=o},s=i;$traceurRuntime.createClass(i,{isValid:function(e){return this.from.isValid(e)&&this.to.isValid(e)},isSingle:function(){return this.from.row===this.to.row&&this.from.col===this.to.col},getHeight:function(){return Math.max(this.from.row,this.to.row)-Math.min(this.from.row,this.to.row)+1},getWidth:function(){return Math.max(this.from.col,this.to.col)-Math.min(this.from.col,this.to.col)+1},includes:function(e){var t=e,o=t.row,n=t.col,r=this.getTopLeftCorner(),i=this.getBottomRightCorner();return r.row<=o&&i.row>=o&&r.col<=n&&i.col>=n},includesRange:function(e){return this.includes(e.getTopLeftCorner())&&this.includes(e.getBottomRightCorner())},isEqual:function(e){return Math.min(this.from.row,this.to.row)==Math.min(e.from.row,e.to.row)&&Math.max(this.from.row,this.to.row)==Math.max(e.from.row,e.to.row)&&Math.min(this.from.col,this.to.col)==Math.min(e.from.col,e.to.col)&&Math.max(this.from.col,this.to.col)==Math.max(e.from.col,e.to.col)},overlaps:function(e){return e.isSouthEastOf(this.getTopLeftCorner())&&e.isNorthWestOf(this.getBottomRightCorner())},isSouthEastOf:function(e){return this.getTopLeftCorner().isSouthEastOf(e)||this.getBottomRightCorner().isSouthEastOf(e)},isNorthWestOf:function(e){return this.getTopLeftCorner().isNorthWestOf(e)||this.getBottomRightCorner().isNorthWestOf(e)},expand:function(e){var t=this.getTopLeftCorner(),o=this.getBottomRightCorner();return(e.row<t.row||e.col<t.col||e.row>o.row||e.col>o.col)&&(this.from=new r(Math.min(t.row,e.row),Math.min(t.col,e.col)),this.to=new r(Math.max(o.row,e.row),Math.max(o.col,e.col)),!0)},expandByRange:function(e){if(this.includesRange(e)||!this.overlaps(e))return!1;var t=this.getTopLeftCorner(),o=this.getBottomRightCorner(),n=(this.getTopRightCorner(),this.getBottomLeftCorner(),e.getTopLeftCorner()),i=e.getBottomRightCorner(),a=Math.min(t.row,n.row),l=Math.min(t.col,n.col),u=Math.max(o.row,i.row),c=Math.max(o.col,i.col),d=new r(a,l),h=new r(u,c),f=new s(d,d,h).isCorner(this.from,e),p=e.isEqual(new s(d,d,h));return f&&!p&&(this.from.col>d.col&&(d.col=c,h.col=l),this.from.row>d.row&&(d.row=u,h.row=a)),this.from=d,this.to=h,!0},getDirection:function(){return this.from.isNorthWestOf(this.to)?"NW-SE":this.from.isNorthEastOf(this.to)?"NE-SW":this.from.isSouthEastOf(this.to)?"SE-NW":this.from.isSouthWestOf(this.to)?"SW-NE":void 0},setDirection:function(e){var t,o,n,r;switch(e){case"NW-SE":t=[this.getTopLeftCorner(),this.getBottomRightCorner()],this.from=t[0],this.to=t[1];break;case"NE-SW":o=[this.getTopRightCorner(),this.getBottomLeftCorner()],this.from=o[0],this.to=o[1];break;case"SE-NW":n=[this.getBottomRightCorner(),this.getTopLeftCorner()],this.from=n[0],this.to=n[1];break;case"SW-NE":r=[this.getBottomLeftCorner(),this.getTopRightCorner()],this.from=r[0],this.to=r[1]}},getTopLeftCorner:function(){return new r(Math.min(this.from.row,this.to.row),Math.min(this.from.col,this.to.col))},getBottomRightCorner:function(){return new r(Math.max(this.from.row,this.to.row),Math.max(this.from.col,this.to.col))},getTopRightCorner:function(){return new r(Math.min(this.from.row,this.to.row),Math.max(this.from.col,this.to.col))},getBottomLeftCorner:function(){return new r(Math.max(this.from.row,this.to.row),Math.min(this.from.col,this.to.col))},isCorner:function(e,t){return!!(t&&t.includes(e)&&(this.getTopLeftCorner().isEqual(new r(t.from.row,t.from.col))||this.getTopRightCorner().isEqual(new r(t.from.row,t.to.col))||this.getBottomLeftCorner().isEqual(new r(t.to.row,t.from.col))||this.getBottomRightCorner().isEqual(new r(t.to.row,t.to.col))))||(e.isEqual(this.getTopLeftCorner())||e.isEqual(this.getTopRightCorner())||e.isEqual(this.getBottomLeftCorner())||e.isEqual(this.getBottomRightCorner()))},getOppositeCorner:function(e,t){if(!(e instanceof r))return!1;if(t&&t.includes(e)){if(this.getTopLeftCorner().isEqual(new r(t.from.row,t.from.col)))return this.getBottomRightCorner();if(this.getTopRightCorner().isEqual(new r(t.from.row,t.to.col)))return this.getBottomLeftCorner();if(this.getBottomLeftCorner().isEqual(new r(t.to.row,t.from.col)))return this.getTopRightCorner();if(this.getBottomRightCorner().isEqual(new r(t.to.row,t.to.col)))return this.getTopLeftCorner()}return e.isEqual(this.getBottomRightCorner())?this.getTopLeftCorner():e.isEqual(this.getTopLeftCorner())?this.getBottomRightCorner():e.isEqual(this.getTopRightCorner())?this.getBottomLeftCorner():e.isEqual(this.getBottomLeftCorner())?this.getTopRightCorner():void 0},getBordersSharedWith:function(e){if(!this.includesRange(e))return[];var t={top:Math.min(this.from.row,this.to.row),bottom:Math.max(this.from.row,this.to.row),left:Math.min(this.from.col,this.to.col),right:Math.max(this.from.col,this.to.col)},o={top:Math.min(e.from.row,e.to.row),bottom:Math.max(e.from.row,e.to.row),left:Math.min(e.from.col,e.to.col),right:Math.max(e.from.col,e.to.col)},n=[];return t.top==o.top&&n.push("top"),t.right==o.right&&n.push("right"),t.bottom==o.bottom&&n.push("bottom"),t.left==o.left&&n.push("left"),n},getInner:function(){for(var e=this.getTopLeftCorner(),t=this.getBottomRightCorner(),o=[],n=e.row;n<=t.row;n++)for(var i=e.col;i<=t.col;i++)this.from.row===n&&this.from.col===i||this.to.row===n&&this.to.col===i||o.push(new r(n,i));return o},getAll:function(){for(var e=this.getTopLeftCorner(),t=this.getBottomRightCorner(),o=[],n=e.row;n<=t.row;n++)for(var i=e.col;i<=t.col;i++)e.row===n&&e.col===i?o.push(e):t.row===n&&t.col===i?o.push(t):o.push(new r(n,i));return o},forAll:function(e){for(var t=this.getTopLeftCorner(),o=this.getBottomRightCorner(),n=t.row;n<=o.row;n++)for(var r=t.col;r<=o.col;r++){var i=e(n,r);if(i===!1)return}}},{}),window.WalkontableCellRange=i},{"cell/coords":6}],8:[function(e,t,o){"use strict";Object.defineProperties(o,{Walkontable:{get:function(){return D}},__esModule:{value:!0}});var n,r,i,s,a,l,u,c,d,h,f,p,g,m,w=(n=e("helpers/dom/element"))&&n.__esModule&&n||{default:n},v=w.addClass,y=w.fastInnerText,b=w.isVisible,C=w.removeClass,_=((r=e("helpers/object"))&&r.__esModule&&r||{default:r}).objectEach,R=(i=e("helpers/string"))&&i.__esModule&&i||{default:i},M=R.toUpperCaseFirst,S=R.randomString,E=((s=e("event"))&&s.__esModule&&s||{default:s}).WalkontableEvent,O=((a=e("overlays"))&&a.__esModule&&a||{default:a}).WalkontableOverlays,T=((l=e("scroll"))&&l.__esModule&&l||{default:l}).WalkontableScroll,k=((u=e("settings"))&&u.__esModule&&u||{default:u}).WalkontableSettings,x=((c=e("table"))&&c.__esModule&&c||{default:c}).WalkontableTable,H=((d=e("viewport"))&&d.__esModule&&d||{default:d}).WalkontableViewport,D=(((h=e("overlay/_base.js"))&&h.__esModule&&h||{default:h}).WalkontableOverlay,((f=e("overlay/top.js"))&&f.__esModule&&f||{default:f}).WalkontableTopOverlay,((p=e("overlay/left.js"))&&p.__esModule&&p||{default:p}).WalkontableLeftOverlay,((g=e("overlay/debug.js"))&&g.__esModule&&g||{default:g}).WalkontableDebugOverlay,((m=e("overlay/topLeftCorner.js"))&&m.__esModule&&m||{default:m}).WalkontableTopLeftCornerOverlay,function(e){var t=[];if(this.guid="wt_"+S(),e.cloneSource?(this.cloneSource=e.cloneSource,this.cloneOverlay=e.cloneOverlay,this.wtSettings=e.cloneSource.wtSettings,this.wtTable=new x(this,e.table,e.wtRootElement),this.wtScroll=new T(this),this.wtViewport=e.cloneSource.wtViewport,this.wtEvent=new E(this),this.selections=this.cloneSource.selections):(this.wtSettings=new k(this,e),this.wtTable=new x(this,e.table),this.wtScroll=new T(this),this.wtViewport=new H(this),this.wtEvent=new E(this),this.selections=this.getSetting("selections"),this.wtOverlays=new O(this),this.exportSettingsAsClassNames()),this.wtTable.THEAD.childNodes.length&&this.wtTable.THEAD.childNodes[0].childNodes.length){for(var o=0,n=this.wtTable.THEAD.childNodes[0].childNodes.length;o<n;o++)t.push(this.wtTable.THEAD.childNodes[0].childNodes[o].innerHTML);this.getSetting("columnHeaders").length||this.update("columnHeaders",[function(e,o){y(o,t[e])}])}this.drawn=!1,this.drawInterrupted=!1});$traceurRuntime.createClass(D,{draw:function(){var e=void 0!==arguments[0]&&arguments[0];return this.drawInterrupted=!1,e||b(this.wtTable.TABLE)?this.wtTable.draw(e):this.drawInterrupted=!0,this},getCell:function(e){if(void 0===arguments[1]||!arguments[1])return this.wtTable.getCell(e);var t=this.wtSettings.getSetting("totalRows"),o=this.wtSettings.getSetting("fixedRowsTop"),n=this.wtSettings.getSetting("fixedRowsBottom"),r=this.wtSettings.getSetting("fixedColumnsLeft");if(e.row<o&&e.col<r)return this.wtOverlays.topLeftCornerOverlay.clone.wtTable.getCell(e);if(e.row<o)return this.wtOverlays.topOverlay.clone.wtTable.getCell(e);if(e.col<r&&e.row>=t-n){if(this.wtOverlays.bottomLeftCornerOverlay&&this.wtOverlays.bottomLeftCornerOverlay.clone)return this.wtOverlays.bottomLeftCornerOverlay.clone.wtTable.getCell(e)}else{if(e.col<r)return this.wtOverlays.leftOverlay.clone.wtTable.getCell(e);if(e.row<t&&e.row>t-n&&this.wtOverlays.bottomOverlay&&this.wtOverlays.bottomOverlay.clone)return this.wtOverlays.bottomOverlay.clone.wtTable.getCell(e)}return this.wtTable.getCell(e)},update:function(e,t){return this.wtSettings.update(e,t)},scrollVertical:function(e){return this.wtOverlays.topOverlay.scrollTo(e),this.getSetting("onScrollVertically"),this},scrollHorizontal:function(e){return this.wtOverlays.leftOverlay.scrollTo(e),this.getSetting("onScrollHorizontally"),this},scrollViewport:function(e){return this.wtScroll.scrollViewport(e),this},getViewport:function(){return[this.wtTable.getFirstVisibleRow(),this.wtTable.getFirstVisibleColumn(),this.wtTable.getLastVisibleRow(),this.wtTable.getLastVisibleColumn()]},getOverlayName:function(){return this.cloneOverlay?this.cloneOverlay.type:"master"},isOverlayName:function(e){return!!this.cloneOverlay&&this.cloneOverlay.type===e},exportSettingsAsClassNames:function(){var e=this,t={rowHeaders:["array"],columnHeaders:["array"]},o=[],n=[];_(t,function(t,r){t.indexOf("array")>-1&&e.getSetting(r).length&&n.push("ht"+M(r)),o.push("ht"+M(r))}),C(this.wtTable.wtRootElement.parentNode,o),v(this.wtTable.wtRootElement.parentNode,n)},getSetting:function(e,t,o,n,r){return this.wtSettings.getSetting(e,t,o,n,r)},hasSetting:function(e){return this.wtSettings.has(e)},destroy:function(){this.wtOverlays.destroy(),this.wtEvent.destroy()}},{}),window.Walkontable=D},{event:9,"helpers/dom/element":47,"helpers/object":53,"helpers/string":55,"overlay/_base.js":12,"overlay/debug.js":13,"overlay/left.js":14,"overlay/top.js":15,"overlay/topLeftCorner.js":16,overlays:17,scroll:18,settings:20,table:21,viewport:23}],9:[function(e,t,o){"use strict";function n(e){var t=this,o=g(e);this.instance=e;var n=[null,null];this.dblClickTimeout=[null,null];var r=function(e){var o=document.activeElement,r=f(h,e.realTarget),i=e.realTarget;if(i!==o&&r(0)!==o&&r(1)!==o){var s=t.parentCell(i);c(i,"corner")?t.instance.getSetting("onCellCornerMouseDown",e,i):s.TD&&t.instance.hasSetting("onCellMouseDown")&&t.instance.getSetting("onCellMouseDown",e,s.coords,s.TD,t.instance),2!==e.button&&s.TD&&(n[0]=s.TD,clearTimeout(t.dblClickTimeout[0]),t.dblClickTimeout[0]=setTimeout(function(){n[0]=null},1e3))}},i=function(e){t.instance.touchMoving=!0},s=function(e){o.addEventListener(this,"touchmove",i),t.checkIfTouchMove=setTimeout(function(){if(t.instance.touchMoving===!0)return t.instance.touchMoving=void 0,void o.removeEventListener("touchmove",i,!1);r(e)},30)},a=function(e){var o,n,r;t.instance.hasSetting("onCellMouseOver")&&(o=t.instance.wtTable.TABLE,n=u(e.realTarget,["TD","TH"],o),r=t.instance.cloneSource||t.instance,n&&n!==r.lastMouseOver&&d(n,o)&&(r.lastMouseOver=n,t.instance.getSetting("onCellMouseOver",e,t.instance.wtTable.getCoords(n),n,t.instance)))},l=function(e){var o,n,r;t.instance.hasSetting("onCellMouseOut")&&(o=t.instance.wtTable.TABLE,n=u(e.realTarget,["TD","TH"],o),r=u(e.relatedTarget,["TD","TH"],o),n&&n!==r&&d(n,o)&&t.instance.getSetting("onCellMouseOut",e,t.instance.wtTable.getCoords(n),n,t.instance))},m=function(e){if(2!==e.button){var o=t.parentCell(e.realTarget);o.TD===n[0]&&o.TD===n[1]?(c(e.realTarget,"corner")?t.instance.getSetting("onCellCornerDblClick",e,o.coords,o.TD,t.instance):t.instance.getSetting("onCellDblClick",e,o.coords,o.TD,t.instance),n[0]=null,n[1]=null):o.TD===n[0]?(t.instance.getSetting("onCellMouseUp",e,o.coords,o.TD,t.instance),n[1]=o.TD,clearTimeout(t.dblClickTimeout[1]),t.dblClickTimeout[1]=setTimeout(function(){n[1]=null},500)):o.TD&&t.instance.hasSetting("onCellMouseUp")&&t.instance.getSetting("onCellMouseUp",e,o.coords,o.TD,t.instance)}},w=function(e){clearTimeout(void 0),e.preventDefault(),m(e)};if(o.addEventListener(this.instance.wtTable.holder,"mousedown",r),o.addEventListener(this.instance.wtTable.TABLE,"mouseover",a),o.addEventListener(this.instance.wtTable.TABLE,"mouseout",l),o.addEventListener(this.instance.wtTable.holder,"mouseup",m),this.instance.wtTable.holder.parentNode.parentNode&&p()&&!t.instance.wtTable.isWorkingOnClone()){var v="."+this.instance.wtTable.holder.parentNode.className.split(" ").join(".");o.addEventListener(this.instance.wtTable.holder,"touchstart",function(e){t.instance.touchApplied=!0,d(e.target,v)&&s.call(e.target,e)}),o.addEventListener(this.instance.wtTable.holder,"touchend",function(e){t.instance.touchApplied=!1,d(e.target,v)&&w.call(e.target,e)}),t.instance.momentumScrolling||(t.instance.momentumScrolling={}),o.addEventListener(this.instance.wtTable.holder,"scroll",function(e){clearTimeout(t.instance.momentumScrolling._timeout),t.instance.momentumScrolling.ongoing||t.instance.getSetting("onBeforeTouchScroll"),t.instance.momentumScrolling.ongoing=!0,t.instance.momentumScrolling._timeout=setTimeout(function(){t.instance.touchApplied||(t.instance.momentumScrolling.ongoing=!1,t.instance.getSetting("onAfterMomentumScroll"))},200)})}o.addEventListener(window,"resize",function(){"none"!==t.instance.getSetting("stretchH")&&t.instance.draw()}),this.destroy=function(){clearTimeout(this.dblClickTimeout[0]),clearTimeout(this.dblClickTimeout[1]),o.destroy()}}Object.defineProperties(o,{WalkontableEvent:{get:function(){return n}},__esModule:{value:!0}});var r,i,s,a,l=(r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r},u=l.closestDown,c=l.hasClass,d=l.isChildOf,h=l.getParent,f=((i=e("helpers/function"))&&i.__esModule&&i||{default:i}).partial,p=((s=e("helpers/browser"))&&s.__esModule&&s||{default:s}).isMobileBrowser,g=((a=e("eventManager"))&&a.__esModule&&a||{default:a}).eventManager;n.prototype.parentCell=function(e){var t={},o=this.instance.wtTable.TABLE,n=u(e,["TD","TH"],o);return n?(t.coords=this.instance.wtTable.getCoords(n),t.TD=n):c(e,"wtBorder")&&c(e,"current")?(t.coords=this.instance.selections.current.cellRange.highlight,t.TD=this.instance.wtTable.getCell(t.coords)):c(e,"wtBorder")&&c(e,"area")&&this.instance.selections.area.cellRange&&(t.coords=this.instance.selections.area.cellRange.to,
28
- t.TD=this.instance.wtTable.getCell(t.coords)),t},window.WalkontableEvent=n},{eventManager:42,"helpers/browser":44,"helpers/dom/element":47,"helpers/function":50}],10:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableColumnFilter:{get:function(){return n}},__esModule:{value:!0}});var n=function(e,t,o){this.offset=e,this.total=t,this.countTH=o};$traceurRuntime.createClass(n,{offsetted:function(e){return e+this.offset},unOffsetted:function(e){return e-this.offset},renderedToSource:function(e){return this.offsetted(e)},sourceToRendered:function(e){return this.unOffsetted(e)},offsettedTH:function(e){return e-this.countTH},unOffsettedTH:function(e){return e+this.countTH},visibleRowHeadedColumnToSourceColumn:function(e){return this.renderedToSource(this.offsettedTH(e))},sourceColumnToVisibleRowHeadedColumn:function(e){return this.unOffsettedTH(this.sourceToRendered(e))}},{}),window.WalkontableColumnFilter=n},{}],11:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableRowFilter:{get:function(){return n}},__esModule:{value:!0}});var n=function(e,t,o){this.offset=e,this.total=t,this.countTH=o};$traceurRuntime.createClass(n,{offsetted:function(e){return e+this.offset},unOffsetted:function(e){return e-this.offset},renderedToSource:function(e){return this.offsetted(e)},sourceToRendered:function(e){return this.unOffsetted(e)},offsettedTH:function(e){return e-this.countTH},unOffsettedTH:function(e){return e+this.countTH},visibleColHeadedRowToSourceRow:function(e){return this.renderedToSource(this.offsettedTH(e))},sourceRowToVisibleColHeadedRow:function(e){return this.unOffsettedTH(this.sourceToRendered(e))}},{}),window.WalkontableRowFilter=n},{}],12:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableOverlay:{get:function(){return p}},__esModule:{value:!0}});var n,r,i,s,a=(n=e("helpers/dom/element"))&&n.__esModule&&n||{default:n},l=a.getScrollableElement,u=a.getTrimmingContainer,c=((r=e("helpers/object"))&&r.__esModule&&r||{default:r}).defineGetter,d=((i=e("helpers/array"))&&i.__esModule&&i||{default:i}).arrayEach,h=((s=e("eventManager"))&&s.__esModule&&s||{default:s}).eventManager,f={},p=function(e){c(this,"wot",e,{writable:!1}),this.instance=this.wot,this.type="",this.mainTableScrollableElement=null,this.TABLE=this.wot.wtTable.TABLE,this.hider=this.wot.wtTable.hider,this.spreader=this.wot.wtTable.spreader,this.holder=this.wot.wtTable.holder,this.wtRootElement=this.wot.wtTable.wtRootElement,this.trimmingContainer=u(this.hider.parentNode.parentNode),this.areElementSizesAdjusted=!1,this.updateStateOfRendering()},g=p;$traceurRuntime.createClass(p,{updateStateOfRendering:function(){var e=this.needFullRender;this.needFullRender=this.shouldBeRendered();var t=e!==this.needFullRender;return t&&!this.needFullRender&&this.reset(),t},shouldBeRendered:function(){return!0},updateTrimmingContainer:function(){this.trimmingContainer=u(this.hider.parentNode.parentNode)},updateMainScrollableElement:function(){this.mainTableScrollableElement=l(this.wot.wtTable.TABLE)},makeClone:function(e){if(g.CLONE_TYPES.indexOf(e)===-1)throw new Error('Clone type "'+e+'" is not supported.');var t=document.createElement("DIV"),o=document.createElement("TABLE");t.className="ht_clone_"+e+" handsontable",t.style.position="absolute",t.style.top=0,t.style.left=0,t.style.overflow="hidden",o.className=this.wot.wtTable.TABLE.className,t.appendChild(o),this.type=e,this.wot.wtTable.wtRootElement.parentNode.appendChild(t);var n=this.wot.getSetting("preventOverflow");return n===!0||"horizontal"===n&&this.type===g.CLONE_TOP||"vertical"===n&&this.type===g.CLONE_LEFT?this.mainTableScrollableElement=window:this.mainTableScrollableElement=l(this.wot.wtTable.TABLE),new Walkontable({cloneSource:this.wot,cloneOverlay:this,table:o})},refresh:function(){var e=void 0!==arguments[0]&&arguments[0],t=this.shouldBeRendered();this.clone&&(this.needFullRender||t)&&this.clone.draw(e),this.needFullRender=t},reset:function(){if(this.clone){var e=this.clone.wtTable.holder,t=this.clone.wtTable.hider;d([e.style,t.style,e.parentNode.style],function(e){e.width="",e.height=""})}},destroy:function(){h(this.clone).destroy()}},{get CLONE_TOP(){return"top"},get CLONE_BOTTOM(){return"bottom"},get CLONE_LEFT(){return"left"},get CLONE_TOP_LEFT_CORNER(){return"top_left_corner"},get CLONE_BOTTOM_LEFT_CORNER(){return"bottom_left_corner"},get CLONE_DEBUG(){return"debug"},get CLONE_TYPES(){return[g.CLONE_TOP,g.CLONE_BOTTOM,g.CLONE_LEFT,g.CLONE_TOP_LEFT_CORNER,g.CLONE_BOTTOM_LEFT_CORNER,g.CLONE_DEBUG]},registerOverlay:function(e,t){if(g.CLONE_TYPES.indexOf(e)===-1)throw new Error("Unsupported overlay ("+e+").");f[e]=t},createOverlay:function(e,t){return new f[e](t)},isOverlayTypeOf:function(e,t){return!(!e||!f[t])&&e instanceof f[t]}}),window.WalkontableOverlay=p},{eventManager:42,"helpers/array":43,"helpers/dom/element":47,"helpers/object":53}],13:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableDebugOverlay:{get:function(){return a}},__esModule:{value:!0}});var n,r,i=((n=e("helpers/dom/element"))&&n.__esModule&&n||{default:n}).addClass,s=((r=e("_base"))&&r.__esModule&&r||{default:r}).WalkontableOverlay,a=function(e){$traceurRuntime.superConstructor(l).call(this,e),this.clone=this.makeClone(s.CLONE_DEBUG),this.clone.wtTable.holder.style.opacity=.4,this.clone.wtTable.holder.style.textShadow="0 0 2px #ff0000",i(this.clone.wtTable.holder.parentNode,"wtDebugVisible")},l=a;$traceurRuntime.createClass(a,{},{},s),window.WalkontableDebugOverlay=a,s.registerOverlay(s.CLONE_DEBUG,a)},{_base:12,"helpers/dom/element":47}],14:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableLeftOverlay:{get:function(){return w}},__esModule:{value:!0}});var n,r,i=(n=e("helpers/dom/element"))&&n.__esModule&&n||{default:n},s=i.addClass,a=i.getScrollbarWidth,l=i.getScrollLeft,u=i.getWindowScrollTop,c=i.hasClass,d=i.outerWidth,h=i.innerHeight,f=i.removeClass,p=i.setOverlayPosition,g=i.resetCssTransform,m=((r=e("_base"))&&r.__esModule&&r||{default:r}).WalkontableOverlay,w=function(e){$traceurRuntime.superConstructor(v).call(this,e),this.clone=this.makeClone(m.CLONE_LEFT)},v=w;$traceurRuntime.createClass(w,{shouldBeRendered:function(){return!(!this.wot.getSetting("fixedColumnsLeft")&&!this.wot.getSetting("rowHeaders").length)},resetFixedPosition:function(){if(this.needFullRender&&this.wot.wtTable.holder.parentNode){var e=this.clone.wtTable.holder.parentNode,t=0,o=this.wot.getSetting("preventOverflow");if(this.trimmingContainer!==window||o&&"horizontal"===o)t=this.getScrollPosition(),g(e);else{var n,r,i=this.wot.wtTable.hider.getBoundingClientRect(),s=Math.ceil(i.left),a=Math.ceil(i.right);r=this.wot.wtTable.hider.style.top,r=""===r?0:r,n=s<0&&a-e.offsetWidth>0?-s:0,t=n,n+="px",p(e,n,r)}this.adjustHeaderBordersPosition(t),this.adjustElementsSize()}},setScrollPosition:function(e){this.mainTableScrollableElement===window?window.scrollTo(e,u()):this.mainTableScrollableElement.scrollLeft=e},onScroll:function(){this.wot.getSetting("onScrollVertically")},sumCellSizes:function(e,t){for(var o=0,n=this.wot.wtSettings.defaultColumnWidth;e<t;)o+=this.wot.wtTable.getStretchedColumnWidth(e)||n,e++;return o},adjustElementsSize:function(){var e=void 0!==arguments[0]&&arguments[0];this.updateTrimmingContainer(),(this.needFullRender||e)&&(this.adjustRootElementSize(),this.adjustRootChildrenSize(),e||(this.areElementSizesAdjusted=!0))},adjustRootElementSize:function(){var e,t=this.wot.wtTable.holder,o=t.clientHeight===t.offsetHeight?0:a(),n=this.clone.wtTable.holder.parentNode,r=n.style,i=this.wot.getSetting("preventOverflow");if(this.trimmingContainer!==window||"vertical"===i){var s=this.wot.wtViewport.getWorkspaceHeight()-o;s=Math.min(s,h(this.wot.wtTable.wtRootElement)),r.height=s+"px"}else r.height="";this.clone.wtTable.holder.style.height=r.height,e=d(this.clone.wtTable.TABLE),r.width=(0===e?e:e+4)+"px"},adjustRootChildrenSize:function(){var e=a();this.clone.wtTable.hider.style.height=this.hider.style.height,this.clone.wtTable.holder.style.height=this.clone.wtTable.holder.parentNode.style.height,0===e&&(e=30),this.clone.wtTable.holder.style.width=parseInt(this.clone.wtTable.holder.parentNode.style.width,10)+e+"px"},applyToDOM:function(){var e=this.wot.getSetting("totalColumns");if(this.areElementSizesAdjusted||this.adjustElementsSize(),"number"==typeof this.wot.wtViewport.columnsRenderCalculator.startPosition)this.spreader.style.left=this.wot.wtViewport.columnsRenderCalculator.startPosition+"px";else{if(0!==e)throw new Error("Incorrect value of the columnsRenderCalculator");this.spreader.style.left="0"}this.spreader.style.right="",this.needFullRender&&this.syncOverlayOffset()},syncOverlayOffset:function(){"number"==typeof this.wot.wtViewport.rowsRenderCalculator.startPosition?this.clone.wtTable.spreader.style.top=this.wot.wtViewport.rowsRenderCalculator.startPosition+"px":this.clone.wtTable.spreader.style.top=""},scrollTo:function(e,t){var o=this.getTableParentOffset(),n=this.wot.cloneSource?this.wot.cloneSource:this.wot,r=n.wtTable.holder,i=0;t&&r.offsetWidth!==r.clientWidth&&(i=a()),t?(o+=this.sumCellSizes(0,e+1),o-=this.wot.wtViewport.getViewportWidth()):o+=this.sumCellSizes(this.wot.getSetting("fixedColumnsLeft"),e),o+=i,this.setScrollPosition(o)},getTableParentOffset:function(){var e=this.wot.getSetting("preventOverflow"),t=0;return e||this.trimmingContainer!==window||(t=this.wot.wtTable.holderOffset.left),t},getScrollPosition:function(){return l(this.mainTableScrollableElement)},adjustHeaderBordersPosition:function(e){var t=this.wot.wtTable.holder.parentNode,o=this.wot.getSetting("rowHeaders"),n=this.wot.getSetting("fixedColumnsLeft");if(this.wot.getSetting("totalRows")?f(t,"emptyRows"):s(t,"emptyRows"),n&&!o.length)s(t,"innerBorderLeft");else if(!n&&o.length){var r=c(t,"innerBorderLeft");e?s(t,"innerBorderLeft"):f(t,"innerBorderLeft"),(!r&&e||r&&!e)&&this.wot.wtOverlays.adjustElementsSize()}}},{},m),window.WalkontableLeftOverlay=w,m.registerOverlay(m.CLONE_LEFT,w)},{_base:12,"helpers/dom/element":47}],15:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableTopOverlay:{get:function(){return w}},__esModule:{value:!0}});var n,r,i=(n=e("helpers/dom/element"))&&n.__esModule&&n||{default:n},s=i.addClass,a=i.getScrollbarWidth,l=i.getScrollTop,u=i.getWindowScrollLeft,c=i.hasClass,d=i.outerHeight,h=i.innerWidth,f=i.removeClass,p=i.setOverlayPosition,g=i.resetCssTransform,m=((r=e("_base"))&&r.__esModule&&r||{default:r}).WalkontableOverlay,w=function(e){$traceurRuntime.superConstructor(v).call(this,e),this.clone=this.makeClone(m.CLONE_TOP)},v=w;$traceurRuntime.createClass(w,{shouldBeRendered:function(){return!(!this.wot.getSetting("fixedRowsTop")&&!this.wot.getSetting("columnHeaders").length)},resetFixedPosition:function(){if(this.needFullRender&&this.wot.wtTable.holder.parentNode){var e=this.clone.wtTable.holder.parentNode,t=0,o=this.wot.getSetting("preventOverflow");if(this.trimmingContainer!==window||o&&"vertical"===o)t=this.getScrollPosition(),g(e);else{var n,r,i=this.wot.wtTable.hider.getBoundingClientRect(),s=Math.ceil(i.top),a=Math.ceil(i.bottom);n=this.wot.wtTable.hider.style.left,n=""===n?0:n,r=s<0&&a-e.offsetHeight>0?-s:0,t=r,r+="px",p(e,n,r)}this.adjustHeaderBordersPosition(t),this.adjustElementsSize()}},setScrollPosition:function(e){this.mainTableScrollableElement===window?window.scrollTo(u(),e):this.mainTableScrollableElement.scrollTop=e},onScroll:function(){this.wot.getSetting("onScrollHorizontally")},sumCellSizes:function(e,t){for(var o=0,n=this.wot.wtSettings.settings.defaultRowHeight;e<t;){var r=this.wot.wtTable.getRowHeight(e);o+=void 0===r?n:r,e++}return o},adjustElementsSize:function(){var e=void 0!==arguments[0]&&arguments[0];this.updateTrimmingContainer(),(this.needFullRender||e)&&(this.adjustRootElementSize(),this.adjustRootChildrenSize(),e||(this.areElementSizesAdjusted=!0))},adjustRootElementSize:function(){var e,t=this.wot.wtTable.holder,o=t.clientWidth===t.offsetWidth?0:a(),n=this.clone.wtTable.holder.parentNode,r=n.style,i=this.wot.getSetting("preventOverflow");if(this.trimmingContainer!==window||"horizontal"===i){var s=this.wot.wtViewport.getWorkspaceWidth()-o;s=Math.min(s,h(this.wot.wtTable.wtRootElement)),r.width=s+"px"}else r.width="";this.clone.wtTable.holder.style.width=r.width,e=d(this.clone.wtTable.TABLE),r.height=(0===e?e:e+4)+"px"},adjustRootChildrenSize:function(){var e=a();this.clone.wtTable.hider.style.width=this.hider.style.width,this.clone.wtTable.holder.style.width=this.clone.wtTable.holder.parentNode.style.width,0===e&&(e=30),this.clone.wtTable.holder.style.height=parseInt(this.clone.wtTable.holder.parentNode.style.height,10)+e+"px"},applyToDOM:function(){var e=this.wot.getSetting("totalRows");if(this.areElementSizesAdjusted||this.adjustElementsSize(),"number"==typeof this.wot.wtViewport.rowsRenderCalculator.startPosition)this.spreader.style.top=this.wot.wtViewport.rowsRenderCalculator.startPosition+"px";else{if(0!==e)throw new Error("Incorrect value of the rowsRenderCalculator");this.spreader.style.top="0"}this.spreader.style.bottom="",this.needFullRender&&this.syncOverlayOffset()},syncOverlayOffset:function(){"number"==typeof this.wot.wtViewport.columnsRenderCalculator.startPosition?this.clone.wtTable.spreader.style.left=this.wot.wtViewport.columnsRenderCalculator.startPosition+"px":this.clone.wtTable.spreader.style.left=""},scrollTo:function(e,t){var o=this.getTableParentOffset(),n=this.wot.cloneSource?this.wot.cloneSource:this.wot,r=n.wtTable.holder,i=0;if(t&&r.offsetHeight!==r.clientHeight&&(i=a()),t){var s=this.wot.getSetting("fixedRowsBottom"),l=(this.wot.getSetting("fixedRowsTop"),this.wot.getSetting("totalRows"));o+=this.sumCellSizes(0,e+1),o-=this.wot.wtViewport.getViewportHeight()-this.sumCellSizes(l-s,l),o+=1}else o+=this.sumCellSizes(this.wot.getSetting("fixedRowsTop"),e);o+=i,this.setScrollPosition(o)},getTableParentOffset:function(){return this.mainTableScrollableElement===window?this.wot.wtTable.holderOffset.top:0},getScrollPosition:function(){return l(this.mainTableScrollableElement)},redrawSelectionBorders:function(e){if(e&&e.cellRange){var t=e.getBorder(this.wot);if(t){var o=e.getCorners();t.disappear(),t.appear(o)}}},redrawAllSelectionsBorders:function(){var e=this.wot.selections;this.redrawSelectionBorders(e.current),this.redrawSelectionBorders(e.area),this.redrawSelectionBorders(e.fill),this.wot.wtTable.wot.wtOverlays.leftOverlay.refresh()},adjustHeaderBordersPosition:function(e){var t=this.wot.wtTable.holder.parentNode;if(this.wot.getSetting("totalColumns")?f(t,"emptyColumns"):s(t,"emptyColumns"),0===this.wot.getSetting("fixedRowsTop")&&this.wot.getSetting("columnHeaders").length>0){var o=c(t,"innerBorderTop");e||0===this.wot.getSetting("totalRows")?s(t,"innerBorderTop"):f(t,"innerBorderTop"),(!o&&e||o&&!e)&&(this.wot.wtOverlays.adjustElementsSize(),this.redrawAllSelectionsBorders())}if(0===this.wot.getSetting("rowHeaders").length){var n=this.clone.wtTable.THEAD.querySelectorAll("th:nth-of-type(2)");if(n)for(var r=0;r<n.length;r++)n[r].style["border-left-width"]=0}}},{},m),window.WalkontableTopOverlay=w,m.registerOverlay(m.CLONE_TOP,w)},{_base:12,"helpers/dom/element":47}],16:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableTopLeftCornerOverlay:{get:function(){return d}},__esModule:{value:!0}});var n,r,i=(n=e("helpers/dom/element"))&&n.__esModule&&n||{default:n},s=i.outerHeight,a=i.outerWidth,l=i.setOverlayPosition,u=i.resetCssTransform,c=((r=e("_base"))&&r.__esModule&&r||{default:r}).WalkontableOverlay,d=function(e){$traceurRuntime.superConstructor(h).call(this,e),this.clone=this.makeClone(c.CLONE_TOP_LEFT_CORNER)},h=d;$traceurRuntime.createClass(d,{shouldBeRendered:function(){return!(!this.wot.getSetting("fixedRowsTop")&&!this.wot.getSetting("columnHeaders").length||!this.wot.getSetting("fixedColumnsLeft")&&!this.wot.getSetting("rowHeaders").length)},resetFixedPosition:function(){if(this.updateTrimmingContainer(),this.wot.wtTable.holder.parentNode){var e=this.clone.wtTable.holder.parentNode,t=s(this.clone.wtTable.TABLE),o=a(this.clone.wtTable.TABLE),n=this.wot.getSetting("preventOverflow");if(this.trimmingContainer===window){var r=this.wot.wtTable.hider.getBoundingClientRect(),i=Math.ceil(r.top),c=Math.ceil(r.left),d=Math.ceil(r.bottom),h=Math.ceil(r.right),f="0",p="0";n&&"vertical"!==n||c<0&&h-e.offsetWidth>0&&(f=-c+"px"),n&&"horizontal"!==n||i<0&&d-e.offsetHeight>0&&(p=-i+"px"),l(e,f,p)}else u(e);e.style.height=(0===t?t:t+4)+"px",e.style.width=(0===o?o:o+4)+"px"}}},{},c),window.WalkontableTopLeftCornerOverlay=d,c.registerOverlay(c.CLONE_TOP_LEFT_CORNER,d)},{_base:12,"helpers/dom/element":47}],17:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableOverlays:{get:function(){return w}},__esModule:{value:!0}});var n,r,i,s,a,l=(n=e("helpers/dom/element"))&&n.__esModule&&n||{default:n},u=l.getScrollableElement,c=l.getScrollbarWidth,d=l.getScrollLeft,h=l.getScrollTop,f=((r=e("helpers/array"))&&r.__esModule&&r||{default:r}).arrayEach,p=((i=e("helpers/unicode"))&&i.__esModule&&i||{default:i}).isKey,g=((s=e("helpers/browser"))&&s.__esModule&&s||{default:s}).isMobileBrowser,m=((a=e("eventManager"))&&a.__esModule&&a||{default:a}).EventManager,w=function(e){this.wot=e,this.instance=this.wot,this.eventManager=new m(this.wot),this.wot.update("scrollbarWidth",c()),this.wot.update("scrollbarHeight",c()),this.scrollableElement=u(this.wot.wtTable.TABLE),this.prepareOverlays(),this.destroyed=!1,this.keyPressed=!1,this.spreaderLastSize={width:null,height:null},this.overlayScrollPositions={master:{top:0,left:0},top:{top:null,left:0},bottom:{top:null,left:0},left:{top:0,left:null}},this.pendingScrollCallbacks={master:{top:0,left:0},top:{left:0},bottom:{left:0},left:{top:0}},this.verticalScrolling=!1,this.horizontalScrolling=!1,this.delegatedScrollCallback=!1,this.registeredListeners=[],this.registerListeners()};$traceurRuntime.createClass(w,{prepareOverlays:function(){var e=!1;return this.topOverlay?e=this.topOverlay.updateStateOfRendering()||e:this.topOverlay=WalkontableOverlay.createOverlay(WalkontableOverlay.CLONE_TOP,this.wot),"undefined"==typeof WalkontableBottomOverlay&&(this.bottomOverlay={needFullRender:!1,updateStateOfRendering:function(){return!1}}),"undefined"==typeof WalkontableBottomLeftCornerOverlay&&(this.bottomLeftCornerOverlay={needFullRender:!1,updateStateOfRendering:function(){return!1}}),this.bottomOverlay?e=this.bottomOverlay.updateStateOfRendering()||e:this.bottomOverlay=WalkontableOverlay.createOverlay(WalkontableOverlay.CLONE_BOTTOM,this.wot),this.leftOverlay?e=this.leftOverlay.updateStateOfRendering()||e:this.leftOverlay=WalkontableOverlay.createOverlay(WalkontableOverlay.CLONE_LEFT,this.wot),this.topOverlay.needFullRender&&this.leftOverlay.needFullRender&&(this.topLeftCornerOverlay?e=this.topLeftCornerOverlay.updateStateOfRendering()||e:this.topLeftCornerOverlay=WalkontableOverlay.createOverlay(WalkontableOverlay.CLONE_TOP_LEFT_CORNER,this.wot)),this.bottomOverlay.needFullRender&&this.leftOverlay.needFullRender&&(this.bottomLeftCornerOverlay?e=this.bottomLeftCornerOverlay.updateStateOfRendering()||e:this.bottomLeftCornerOverlay=WalkontableOverlay.createOverlay(WalkontableOverlay.CLONE_BOTTOM_LEFT_CORNER,this.wot)),this.wot.getSetting("debug")&&!this.debug&&(this.debug=WalkontableOverlay.createOverlay(WalkontableOverlay.CLONE_DEBUG,this.wot)),e},refreshAll:function(){if(this.wot.drawn){if(!this.wot.wtTable.holder.parentNode)return void this.destroy();this.wot.draw(!0),this.verticalScrolling&&this.leftOverlay.onScroll(),this.horizontalScrolling&&this.topOverlay.onScroll(),this.verticalScrolling=!1,this.horizontalScrolling=!1}},registerListeners:function(){var e=this,t=this.topOverlay.mainTableScrollableElement,o=this.leftOverlay.mainTableScrollableElement,n=[];for(n.push([document.documentElement,"keydown",function(t){return e.onKeyDown(t)}]),n.push([document.documentElement,"keyup",function(){return e.onKeyUp()}]),n.push([document,"visibilitychange",function(){return e.onKeyUp()}]),n.push([t,"scroll",function(t){return e.onTableScroll(t)}]),t!==o&&n.push([o,"scroll",function(t){return e.onTableScroll(t)}]),this.topOverlay.needFullRender&&(n.push([this.topOverlay.clone.wtTable.holder,"scroll",function(t){return e.onTableScroll(t)}]),n.push([this.topOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}])),this.bottomOverlay.needFullRender&&(n.push([this.bottomOverlay.clone.wtTable.holder,"scroll",function(t){return e.onTableScroll(t)}]),n.push([this.bottomOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}])),this.leftOverlay.needFullRender&&(n.push([this.leftOverlay.clone.wtTable.holder,"scroll",function(t){return e.onTableScroll(t)}]),n.push([this.leftOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}])),this.topLeftCornerOverlay&&this.topLeftCornerOverlay.needFullRender&&n.push([this.topLeftCornerOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}]),this.bottomLeftCornerOverlay&&this.bottomLeftCornerOverlay.needFullRender&&n.push([this.bottomLeftCornerOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}]),this.topOverlay.trimmingContainer!==window&&this.leftOverlay.trimmingContainer!==window&&n.push([window,"wheel",function(t){var o,n=t.wheelDeltaY||t.deltaY,r=t.wheelDeltaX||t.deltaX;e.topOverlay.clone.wtTable.holder.contains(t.realTarget)?o="top":e.bottomOverlay.clone&&e.bottomOverlay.clone.wtTable.holder.contains(t.realTarget)?o="bottom":e.leftOverlay.clone.wtTable.holder.contains(t.realTarget)?o="left":e.topLeftCornerOverlay&&e.topLeftCornerOverlay.clone&&e.topLeftCornerOverlay.clone.wtTable.holder.contains(t.realTarget)?o="topLeft":e.bottomLeftCornerOverlay&&e.bottomLeftCornerOverlay.clone&&e.bottomLeftCornerOverlay.clone.wtTable.holder.contains(t.realTarget)&&(o="bottomLeft"),("top"==o&&0!==n||"left"==o&&0!==r||"bottom"==o&&0!==n||("topLeft"===o||"bottomLeft"===o)&&(0!==n||0!==r))&&t.preventDefault()}]);n.length;){var r=n.pop();this.eventManager.addEventListener(r[0],r[1],r[2]),this.registeredListeners.push(r)}},deregisterListeners:function(){for(;this.registeredListeners.length;){var e=this.registeredListeners.pop();this.eventManager.removeEventListener(e[0],e[1],e[2])}},onTableScroll:function(e){if(!g()){var t=this.leftOverlay.mainTableScrollableElement,o=this.topOverlay.mainTableScrollableElement,n=e.target;this.keyPressed&&(o!==window&&n!==window&&!e.target.contains(o)||t!==window&&n!==window&&!e.target.contains(t))||("scroll"===e.type?this.syncScrollPositions(e):this.translateMouseWheelToScroll(e))}},onKeyDown:function(e){this.keyPressed=p(e.keyCode,"ARROW_UP|ARROW_RIGHT|ARROW_DOWN|ARROW_LEFT")},onKeyUp:function(){this.keyPressed=!1},translateMouseWheelToScroll:function(e){var t=this.topOverlay.clone.wtTable.holder,o=this.bottomOverlay.clone?this.bottomOverlay.clone.wtTable.holder:null,n=this.leftOverlay.clone.wtTable.holder,r=this.topLeftCornerOverlay&&this.topLeftCornerOverlay.clone?this.topLeftCornerOverlay.clone.wtTable.holder:null,i=this.bottomLeftCornerOverlay&&this.bottomLeftCornerOverlay.clone?this.bottomLeftCornerOverlay.clone.wtTable.holder:null,s=e.wheelDeltaY||-1*e.deltaY,a=e.wheelDeltaX||-1*e.deltaX,l=null,u={type:"wheel"},c=e.target,d=null;for(1===e.deltaMode&&(s*=120,a*=120);c!=document&&null!=c;){if(c.className.indexOf("wtHolder")>-1){l=c;break}c=c.parentNode}return u.target=l,l===r||l===i?(this.syncScrollPositions(u,-.2*a,"x"),this.syncScrollPositions(u,-.2*s,"y")):(l===t||l===o?d=s:l===n&&(d=a),this.syncScrollPositions(u,-.2*d)),!1},syncScrollPositions:function(e){var t=void 0!==arguments[1]?arguments[1]:null,o=void 0!==arguments[2]?arguments[2]:null;if(!this.destroyed){if(0===arguments.length)return void this.syncScrollWithMaster();var n,r,i,s,a,l=this.leftOverlay.mainTableScrollableElement,u=this.topOverlay.mainTableScrollableElement,c=e.target,f=0,p=!1,g=!1,m=this.wot.getSetting("preventOverflow");this.topOverlay.needFullRender&&(n=this.topOverlay.clone.wtTable.holder),this.bottomOverlay.needFullRender&&(a=this.bottomOverlay.clone.wtTable.holder),this.leftOverlay.needFullRender&&(r=this.leftOverlay.clone.wtTable.holder),this.leftOverlay.needFullRender&&this.topOverlay.needFullRender&&(i=this.topLeftCornerOverlay.clone.wtTable.holder),this.leftOverlay.needFullRender&&this.bottomOverlay.needFullRender&&(s=this.bottomLeftCornerOverlay.clone.wtTable.holder),c===document&&(c=window),c===l||c===u?(f=d(m?this.scrollableElement:c),this.horizontalScrolling=!0,this.overlayScrollPositions.master.left=f,p=!0,this.pendingScrollCallbacks.master.left>0?this.pendingScrollCallbacks.master.left--:(n&&n.scrollLeft!==f&&(null==t&&this.pendingScrollCallbacks.top.left++,n.scrollLeft=f,g=l!==window),a&&a.scrollLeft!==f&&(null==t&&this.pendingScrollCallbacks.bottom.left++,a.scrollLeft=f,g=l!==window)),f=h(c),this.verticalScrolling=!0,this.overlayScrollPositions.master.top=f,p=!0,this.pendingScrollCallbacks.master.top>0?this.pendingScrollCallbacks.master.top--:r&&r.scrollTop!==f&&(null==t&&this.pendingScrollCallbacks.left.top++,r.scrollTop=f,g=u!==window)):c===a?(f=d(c),this.horizontalScrolling=!0,this.overlayScrollPositions.bottom.left=f,p=!0,this.pendingScrollCallbacks.bottom.left>0?this.pendingScrollCallbacks.bottom.left--:(null==t&&this.pendingScrollCallbacks.master.left++,l.scrollLeft=f,n&&n.scrollLeft!==f&&(null==t&&this.pendingScrollCallbacks.top.left++,n.scrollLeft=f,g=u!==window)),null!==t&&(p=!0,u.scrollTop+=t)):c===n?(f=d(c),this.horizontalScrolling=!0,this.overlayScrollPositions.top.left=f,p=!0,this.pendingScrollCallbacks.top.left>0?this.pendingScrollCallbacks.top.left--:(null==t&&this.pendingScrollCallbacks.master.left++,l.scrollLeft=f),null!==t&&(p=!0,u.scrollTop+=t),a&&a.scrollLeft!==f&&(null==t&&this.pendingScrollCallbacks.bottom.left++,a.scrollLeft=f,g=u!==window)):c===r?(f=h(c),this.overlayScrollPositions.left.top!==f&&(this.verticalScrolling=!0,this.overlayScrollPositions.left.top=f,p=!0,this.pendingScrollCallbacks.left.top>0?this.pendingScrollCallbacks.left.top--:(null==t&&this.pendingScrollCallbacks.master.top++,u.scrollTop=f)),null!==t&&(p=!0,u.scrollLeft+=t)):c!==i&&c!==s||null!==t&&(p=!0,"x"===o?u.scrollLeft+=t:"y"===o&&(u.scrollTop+=t)),!this.keyPressed&&p&&"scroll"===e.type&&(this.delegatedScrollCallback?this.delegatedScrollCallback=!1:this.refreshAll(),g&&(this.delegatedScrollCallback=!0))}},syncScrollWithMaster:function(){var e=this.topOverlay.mainTableScrollableElement,t=e,o=t.scrollLeft,n=t.scrollTop;this.topOverlay.needFullRender&&(this.topOverlay.clone.wtTable.holder.scrollLeft=o),this.bottomOverlay.needFullRender&&(this.bottomOverlay.clone.wtTable.holder.scrollLeft=o),this.leftOverlay.needFullRender&&(this.leftOverlay.clone.wtTable.holder.scrollTop=n)},updateMainScrollableElements:function(){this.deregisterListeners(),this.leftOverlay.updateMainScrollableElement(),this.topOverlay.updateMainScrollableElement(),this.bottomOverlay.needFullRender&&this.bottomOverlay.updateMainScrollableElement(),this.scrollableElement=u(this.wot.wtTable.TABLE),this.registerListeners()},destroy:function(){this.eventManager.destroy(),this.topOverlay.destroy(),this.bottomOverlay.clone&&this.bottomOverlay.destroy(),this.leftOverlay.destroy(),this.topLeftCornerOverlay&&this.topLeftCornerOverlay.destroy(),this.bottomLeftCornerOverlay&&this.bottomLeftCornerOverlay.clone&&this.bottomLeftCornerOverlay.destroy(),this.debug&&this.debug.destroy(),this.destroyed=!0},refresh:function(){var e=void 0!==arguments[0]&&arguments[0];if(this.topOverlay.areElementSizesAdjusted&&this.leftOverlay.areElementSizesAdjusted){var t=this.wot.wtTable.wtRootElement.parentNode||this.wot.wtTable.wtRootElement,o=t.clientWidth,n=t.clientHeight;o===this.spreaderLastSize.width&&n===this.spreaderLastSize.height||(this.spreaderLastSize.width=o,this.spreaderLastSize.height=n,this.adjustElementsSize())}this.bottomOverlay.clone&&this.bottomOverlay.refresh(e),this.leftOverlay.refresh(e),this.topOverlay.refresh(e),this.topLeftCornerOverlay&&this.topLeftCornerOverlay.refresh(e),this.bottomLeftCornerOverlay&&this.bottomLeftCornerOverlay.clone&&this.bottomLeftCornerOverlay.refresh(e),this.debug&&this.debug.refresh(e)},adjustElementsSize:function(){var e=void 0!==arguments[0]&&arguments[0],t=this.wot.getSetting("totalColumns"),o=this.wot.getSetting("totalRows"),n=this.wot.wtViewport.getRowHeaderWidth(),r=this.wot.wtViewport.getColumnHeaderHeight(),i=this.wot.wtTable.hider.style;i.width=n+this.leftOverlay.sumCellSizes(0,t)+"px",i.height=r+this.topOverlay.sumCellSizes(0,o)+1+"px",this.topOverlay.adjustElementsSize(e),this.leftOverlay.adjustElementsSize(e),this.bottomOverlay.clone&&this.bottomOverlay.adjustElementsSize(e)},applyToDOM:function(){this.topOverlay.areElementSizesAdjusted&&this.leftOverlay.areElementSizesAdjusted||this.adjustElementsSize(),this.topOverlay.applyToDOM(),this.bottomOverlay.clone&&this.bottomOverlay.applyToDOM(),this.leftOverlay.applyToDOM()},getParentOverlay:function(e){if(!e)return null;var t=[this.topOverlay,this.leftOverlay,this.bottomOverlay,this.topLeftCornerOverlay,this.bottomLeftCornerOverlay],o=null;return f(t,function(t,n){t&&t.clone&&t.clone.wtTable.TABLE.contains(e)&&(o=t.clone)}),o}},{}),window.WalkontableOverlays=w},{eventManager:42,"helpers/array":43,"helpers/browser":44,"helpers/dom/element":47,"helpers/unicode":56}],18:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableScroll:{get:function(){return p}},__esModule:{value:!0}});var n,r,i=(n=e("helpers/dom/element"))&&n.__esModule&&n||{default:n},s=i.innerHeight,a=i.innerWidth,l=i.getScrollLeft,u=i.getScrollTop,c=i.offset,d=(r=e("helpers/number"))&&r.__esModule&&r||{default:r},h=d.rangeEach,f=d.rangeEachReverse,p=function(e){this.wot=e,this.instance=e};$traceurRuntime.createClass(p,{scrollViewport:function(e){if(this.wot.drawn){var t=this._getVariables(),o=t.topOverlay,n=t.leftOverlay,r=t.totalRows,i=t.totalColumns,s=t.fixedRowsTop,a=t.fixedRowsBottom,l=t.fixedColumnsLeft;if(e.row<0||e.row>Math.max(r-1,0))throw new Error("row "+e.row+" does not exist");if(e.col<0||e.col>Math.max(i-1,0))throw new Error("column "+e.col+" does not exist");e.row>=s&&e.row<this.getFirstVisibleRow()?o.scrollTo(e.row):e.row>this.getLastVisibleRow()&&e.row<r-a&&o.scrollTo(e.row,!0),e.col>=l&&e.col<this.getFirstVisibleColumn()?n.scrollTo(e.col):e.col>this.getLastVisibleColumn()&&n.scrollTo(e.col,!0)}},getFirstVisibleRow:function(){var e=this._getVariables(),t=e.topOverlay,o=e.wtTable,n=e.wtViewport,r=e.totalRows,i=e.fixedRowsTop,a=o.getFirstVisibleRow();if(t.mainTableScrollableElement===window){var l=c(o.wtRootElement),d=s(o.hider),h=s(window),p=u(window);if(l.top+d-h<=p){var g=n.getColumnHeaderHeight();g+=t.sumCellSizes(0,i),f(r,1,function(e){if(g+=t.sumCellSizes(e-1,e),l.top+d-g<=p)return a=e,!1})}}return a},getLastVisibleRow:function(){var e=this._getVariables(),t=e.topOverlay,o=e.wtTable,n=e.wtViewport,r=e.totalRows,i=o.getLastVisibleRow();if(t.mainTableScrollableElement===window){var a=c(o.wtRootElement),l=s(window),d=u(window);if(a.top>d){var f=n.getColumnHeaderHeight();h(1,r,function(e){if(f+=t.sumCellSizes(e-1,e),a.top+f-d>=l)return i=e-2,!1})}}return i},getFirstVisibleColumn:function(){var e=this._getVariables(),t=e.leftOverlay,o=e.wtTable,n=e.wtViewport,r=e.totalColumns,i=(e.fixedColumnsLeft,o.getFirstVisibleColumn());if(t.mainTableScrollableElement===window){var s=c(o.wtRootElement),u=a(o.hider),d=a(window),h=l(window);if(s.left+u-d<=h){var p=n.getRowHeaderWidth();f(r,1,function(e){if(p+=t.sumCellSizes(e-1,e),s.left+u-p<=h)return i=e,!1})}}return i},getLastVisibleColumn:function(){var e=this._getVariables(),t=e.leftOverlay,o=e.wtTable,n=e.wtViewport,r=e.totalColumns,i=o.getLastVisibleColumn();if(t.mainTableScrollableElement===window){var s=c(o.wtRootElement),u=a(window),d=l(window);if(s.left>d){var f=n.getRowHeaderWidth();h(1,r,function(e){if(f+=t.sumCellSizes(e-1,e),s.left+f-d>=u)return i=e-2,!1})}}return i},_getVariables:function(){var e=this.wot
29
- ;return{topOverlay:e.wtOverlays.topOverlay,leftOverlay:e.wtOverlays.leftOverlay,wtTable:e.wtTable,wtViewport:e.wtViewport,totalRows:e.getSetting("totalRows"),totalColumns:e.getSetting("totalColumns"),fixedRowsTop:e.getSetting("fixedRowsTop"),fixedRowsBottom:e.getSetting("fixedRowsBottom"),fixedColumnsLeft:e.getSetting("fixedColumnsLeft")}}},{}),window.WalkontableScroll=p},{"helpers/dom/element":47,"helpers/number":52}],19:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableSelection:{get:function(){return d}},__esModule:{value:!0}});var n,r,i,s,a=((n=e("helpers/dom/element"))&&n.__esModule&&n||{default:n}).addClass,l=((r=e("border"))&&r.__esModule&&r||{default:r}).WalkontableBorder,u=((i=e("cell/coords"))&&i.__esModule&&i||{default:i}).WalkontableCellCoords,c=((s=e("cell/range"))&&s.__esModule&&s||{default:s}).WalkontableCellRange,d=function(e,t){this.settings=e,this.cellRange=t||null,this.instanceBorders={}};$traceurRuntime.createClass(d,{getBorder:function(e){if(this.instanceBorders[e.guid])return this.instanceBorders[e.guid];this.instanceBorders[e.guid]=new l(e,this.settings)},isEmpty:function(){return null===this.cellRange},add:function(e){this.isEmpty()?this.cellRange=new c(e,e,e):this.cellRange.expand(e)},replace:function(e,t){if(!this.isEmpty()){if(this.cellRange.from.isEqual(e))return this.cellRange.from=t,!0;if(this.cellRange.to.isEqual(e))return this.cellRange.to=t,!0}return!1},clear:function(){this.cellRange=null},getCorners:function(){var e=this.cellRange.getTopLeftCorner(),t=this.cellRange.getBottomRightCorner();return[e.row,e.col,t.row,t.col]},addClassAtCoords:function(e,t,o,n){var r=e.wtTable.getCell(new u(t,o));"object"==typeof r&&a(r,n)},draw:function(e){if(this.isEmpty()){if(this.settings.border){var t=this.getBorder(e);t&&t.disappear()}}else{for(var o,n,r,i=e.wtTable.getRenderedRowsCount(),s=e.wtTable.getRenderedColumnsCount(),l=this.getCorners(),u=0;u<s;u++)if((n=e.wtTable.columnFilter.renderedToSource(u))>=l[1]&&n<=l[3]&&(r=e.wtTable.getColumnHeader(n))){var c=[];this.settings.highlightHeaderClassName&&c.push(this.settings.highlightHeaderClassName),this.settings.highlightColumnClassName&&c.push(this.settings.highlightColumnClassName),a(r,c)}for(var d=0;d<i;d++){if((o=e.wtTable.rowFilter.renderedToSource(d))>=l[0]&&o<=l[2]&&(r=e.wtTable.getRowHeader(o))){var h=[];this.settings.highlightHeaderClassName&&h.push(this.settings.highlightHeaderClassName),this.settings.highlightRowClassName&&h.push(this.settings.highlightRowClassName),a(r,h)}for(var f=0;f<s;f++)n=e.wtTable.columnFilter.renderedToSource(f),o>=l[0]&&o<=l[2]&&n>=l[1]&&n<=l[3]?this.settings.className&&this.addClassAtCoords(e,o,n,this.settings.className):o>=l[0]&&o<=l[2]?this.settings.highlightRowClassName&&this.addClassAtCoords(e,o,n,this.settings.highlightRowClassName):n>=l[1]&&n<=l[3]&&this.settings.highlightColumnClassName&&this.addClassAtCoords(e,o,n,this.settings.highlightColumnClassName)}if(e.getSetting("onBeforeDrawBorders",l,this.settings.className),this.settings.border){var p=this.getBorder(e);p&&p.appear(l)}}}},{}),window.WalkontableSelection=d},{border:3,"cell/coords":6,"cell/range":7,"helpers/dom/element":47}],20:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableSettings:{get:function(){return i}},__esModule:{value:!0}});var n,r=((n=e("helpers/dom/element"))&&n.__esModule&&n||{default:n}).fastInnerText,i=function(e,t){var o=this;this.wot=e,this.instance=e,this.defaults={table:void 0,debug:!1,externalRowCalculator:!1,stretchH:"none",currentRowClassName:null,currentColumnClassName:null,preventOverflow:function(){return!1},data:void 0,fixedColumnsLeft:0,fixedRowsTop:0,fixedRowsBottom:0,minSpareRows:0,rowHeaders:function(){return[]},columnHeaders:function(){return[]},totalRows:void 0,totalColumns:void 0,cellRenderer:function(e,t,n){var i=o.getSetting("data",e,t);r(n,void 0===i||null===i?"":i)},columnWidth:function(e){},rowHeight:function(e){},defaultRowHeight:23,defaultColumnWidth:50,selections:null,hideBorderOnMouseDownOver:!1,viewportRowCalculatorOverride:null,viewportColumnCalculatorOverride:null,onCellMouseDown:null,onCellMouseOver:null,onCellMouseOut:null,onCellMouseUp:null,onCellDblClick:null,onCellCornerMouseDown:null,onCellCornerDblClick:null,beforeDraw:null,onDraw:null,onBeforeDrawBorders:null,onScrollVertically:null,onScrollHorizontally:null,onBeforeTouchScroll:null,onAfterMomentumScroll:null,onBeforeStretchingColumnWidth:function(e){return e},onModifyRowHeaderWidth:null,scrollbarWidth:10,scrollbarHeight:10,renderAllRows:!1,groups:!1,rowHeaderWidth:null,columnHeaderHeight:null,headerClassName:null},this.settings={};for(var n in this.defaults)if(this.defaults.hasOwnProperty(n))if(void 0!==t[n])this.settings[n]=t[n];else{if(void 0===this.defaults[n])throw new Error('A required setting "'+n+'" was not provided');this.settings[n]=this.defaults[n]}};$traceurRuntime.createClass(i,{update:function(e,t){if(void 0===t)for(var o in e)e.hasOwnProperty(o)&&(this.settings[o]=e[o]);else this.settings[e]=t;return this.wot},getSetting:function(e,t,o,n,r){return"function"==typeof this.settings[e]?this.settings[e](t,o,n,r):void 0!==t&&Array.isArray(this.settings[e])?this.settings[e][t]:this.settings[e]},has:function(e){return!!this.settings[e]}},{}),window.WalkontableSettings=i},{"helpers/dom/element":47}],21:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableTable:{get:function(){return S}},__esModule:{value:!0}});var n,r,i,s,a,l,u,c=(n=e("helpers/dom/element"))&&n.__esModule&&n||{default:n},d=c.getStyle,h=c.getTrimmingContainer,f=c.hasClass,p=c.index,g=c.offset,m=c.removeClass,w=c.removeTextNodes,v=c.overlayContainsElement,y=c.closest,b=((r=e("helpers/function"))&&r.__esModule&&r||{default:r}).isFunction,C=((i=e("cell/coords"))&&i.__esModule&&i||{default:i}).WalkontableCellCoords,_=(((s=e("cell/range"))&&s.__esModule&&s||{default:s}).WalkontableCellRange,((a=e("filter/column"))&&a.__esModule&&a||{default:a}).WalkontableColumnFilter),R=((l=e("filter/row"))&&l.__esModule&&l||{default:l}).WalkontableRowFilter,M=((u=e("tableRenderer"))&&u.__esModule&&u||{default:u}).WalkontableTableRenderer,S=function(e,t){var o=this;this.wot=e,this.instance=this.wot,this.TABLE=t,this.TBODY=null,this.THEAD=null,this.COLGROUP=null,this.tableOffset=0,this.holderOffset=0,w(this.TABLE),this.spreader=this.createSpreader(this.TABLE),this.hider=this.createHider(this.spreader),this.holder=this.createHolder(this.hider),this.wtRootElement=this.holder.parentNode,this.alignOverlaysWithTrimmingContainer(),this.fixTableDomTree(),this.colgroupChildrenLength=this.COLGROUP.childNodes.length,this.theadChildrenLength=this.THEAD.firstChild?this.THEAD.firstChild.childNodes.length:0,this.tbodyChildrenLength=this.TBODY.childNodes.length,this.rowFilter=null,this.columnFilter=null,this.correctHeaderWidth=!1;var n=this.wot.wtSettings.settings.rowHeaderWidth;this.wot.wtSettings.settings.rowHeaderWidth=function(){return o._modifyRowHeaderWidth(n)}};$traceurRuntime.createClass(S,{fixTableDomTree:function(){this.TBODY=this.TABLE.querySelector("tbody"),this.TBODY||(this.TBODY=document.createElement("tbody"),this.TABLE.appendChild(this.TBODY)),this.THEAD=this.TABLE.querySelector("thead"),this.THEAD||(this.THEAD=document.createElement("thead"),this.TABLE.insertBefore(this.THEAD,this.TBODY)),this.COLGROUP=this.TABLE.querySelector("colgroup"),this.COLGROUP||(this.COLGROUP=document.createElement("colgroup"),this.TABLE.insertBefore(this.COLGROUP,this.THEAD)),this.wot.getSetting("columnHeaders").length&&!this.THEAD.childNodes.length&&this.THEAD.appendChild(document.createElement("TR"))},createSpreader:function(e){var t,o=e.parentNode;return o&&1===o.nodeType&&f(o,"wtHolder")||(t=document.createElement("div"),t.className="wtSpreader",o&&o.insertBefore(t,e),t.appendChild(e)),t.style.position="relative",t},createHider:function(e){var t,o=e.parentNode;return o&&1===o.nodeType&&f(o,"wtHolder")||(t=document.createElement("div"),t.className="wtHider",o&&o.insertBefore(t,e),t.appendChild(e)),t},createHolder:function(e){var t,o=e.parentNode;return o&&1===o.nodeType&&f(o,"wtHolder")||(t=document.createElement("div"),t.style.position="relative",t.className="wtHolder",o&&o.insertBefore(t,e),this.isWorkingOnClone()||(t.parentNode.className+="ht_master handsontable"),t.appendChild(e)),t},alignOverlaysWithTrimmingContainer:function(){var e=h(this.wtRootElement);if(!this.isWorkingOnClone())if(this.holder.parentNode.style.position="relative",e===window){var t=this.wot.getSetting("preventOverflow");t||(this.holder.style.overflow="visible",this.wtRootElement.style.overflow="visible")}else this.holder.style.width=d(e,"width"),this.holder.style.height=d(e,"height"),this.holder.style.overflow=""},isWorkingOnClone:function(){return!!this.wot.cloneSource},draw:function(e){var t=this.wot,o=t.wtOverlays,n=t.wtViewport,r=this.instance.getSetting("totalRows"),i=this.wot.getSetting("rowHeaders").length,s=this.wot.getSetting("columnHeaders").length,a=!1;if(!this.isWorkingOnClone()&&(this.holderOffset=g(this.holder),e=n.createRenderCalculators(e),i&&!this.wot.getSetting("fixedColumnsLeft"))){var l=o.leftOverlay.getScrollPosition(),u=this.correctHeaderWidth;this.correctHeaderWidth=l>0,u!==this.correctHeaderWidth&&(e=!1)}if(this.isWorkingOnClone()||(a=o.prepareOverlays()),e)this.isWorkingOnClone()||n.createVisibleCalculators(),o&&o.refresh(!0);else{this.isWorkingOnClone()?this.tableOffset=this.wot.cloneSource.wtTable.tableOffset:this.tableOffset=g(this.TABLE);var c;c=WalkontableOverlay.isOverlayTypeOf(this.wot.cloneOverlay,WalkontableOverlay.CLONE_DEBUG)||WalkontableOverlay.isOverlayTypeOf(this.wot.cloneOverlay,WalkontableOverlay.CLONE_TOP)||WalkontableOverlay.isOverlayTypeOf(this.wot.cloneOverlay,WalkontableOverlay.CLONE_TOP_LEFT_CORNER)?0:WalkontableOverlay.isOverlayTypeOf(this.instance.cloneOverlay,WalkontableOverlay.CLONE_BOTTOM)||WalkontableOverlay.isOverlayTypeOf(this.instance.cloneOverlay,WalkontableOverlay.CLONE_BOTTOM_LEFT_CORNER)?Math.max(r-this.wot.getSetting("fixedRowsBottom"),0):n.rowsRenderCalculator.startRow;var d;d=WalkontableOverlay.isOverlayTypeOf(this.wot.cloneOverlay,WalkontableOverlay.CLONE_DEBUG)||WalkontableOverlay.isOverlayTypeOf(this.wot.cloneOverlay,WalkontableOverlay.CLONE_LEFT)||WalkontableOverlay.isOverlayTypeOf(this.wot.cloneOverlay,WalkontableOverlay.CLONE_TOP_LEFT_CORNER)||WalkontableOverlay.isOverlayTypeOf(this.wot.cloneOverlay,WalkontableOverlay.CLONE_BOTTOM_LEFT_CORNER)?0:n.columnsRenderCalculator.startColumn,this.rowFilter=new R(c,r,s),this.columnFilter=new _(d,this.wot.getSetting("totalColumns"),i),this.alignOverlaysWithTrimmingContainer(),this._doDraw()}return this.refreshSelections(e),this.isWorkingOnClone()||(o.topOverlay.resetFixedPosition(),o.bottomOverlay.clone&&o.bottomOverlay.resetFixedPosition(),o.leftOverlay.resetFixedPosition(),o.topLeftCornerOverlay&&o.topLeftCornerOverlay.resetFixedPosition(),o.bottomLeftCornerOverlay&&o.bottomLeftCornerOverlay.clone&&o.bottomLeftCornerOverlay.resetFixedPosition()),a&&o.syncScrollWithMaster(),this.wot.drawn=!0,this},_doDraw:function(){new M(this).render()},removeClassFromCells:function(e){for(var t=this.TABLE.querySelectorAll("."+e),o=0,n=t.length;o<n;o++)m(t[o],e)},refreshSelections:function(e){if(this.wot.selections){var t=this.wot.selections.length;if(e)for(var o=0;o<t;o++)this.wot.selections[o].settings.className&&this.removeClassFromCells(this.wot.selections[o].settings.className),this.wot.selections[o].settings.highlightHeaderClassName&&this.removeClassFromCells(this.wot.selections[o].settings.highlightHeaderClassName),this.wot.selections[o].settings.highlightRowClassName&&this.removeClassFromCells(this.wot.selections[o].settings.highlightRowClassName),this.wot.selections[o].settings.highlightColumnClassName&&this.removeClassFromCells(this.wot.selections[o].settings.highlightColumnClassName);for(var n=0;n<t;n++)this.wot.selections[n].draw(this.wot,e)}},getCell:function(e){if(this.isRowBeforeRenderedRows(e.row))return-1;if(this.isRowAfterRenderedRows(e.row))return-2;var t=this.TBODY.childNodes[this.rowFilter.sourceToRendered(e.row)];return t?t.childNodes[this.columnFilter.sourceColumnToVisibleRowHeadedColumn(e.col)]:void 0},getColumnHeader:function(e){var t=void 0!==arguments[1]?arguments[1]:0,o=this.THEAD.childNodes[t];if(o)return o.childNodes[this.columnFilter.sourceColumnToVisibleRowHeadedColumn(e)]},getRowHeader:function(e){if(0===this.columnFilter.sourceColumnToVisibleRowHeadedColumn(0))return null;var t=this.TBODY.childNodes[this.rowFilter.sourceToRendered(e)];return t?t.childNodes[0]:void 0},getCoords:function(e){"TD"!==e.nodeName&&"TH"!==e.nodeName&&(e=y(e,["TD","TH"]));var t=e.parentNode,o=t.parentNode,n=p(t),r=e.cellIndex;return v(WalkontableOverlay.CLONE_TOP_LEFT_CORNER,e)||v(WalkontableOverlay.CLONE_TOP,e)?"THEAD"===o.nodeName&&(n-=o.childNodes.length):n=o===this.THEAD?this.rowFilter.visibleColHeadedRowToSourceRow(n):this.rowFilter.renderedToSource(n),r=v(WalkontableOverlay.CLONE_TOP_LEFT_CORNER,e)||v(WalkontableOverlay.CLONE_LEFT,e)?this.columnFilter.offsettedTH(r):this.columnFilter.visibleRowHeadedColumnToSourceColumn(r),new C(n,r)},getTrForRow:function(e){return this.TBODY.childNodes[this.rowFilter.sourceToRendered(e)]},getFirstRenderedRow:function(){return this.wot.wtViewport.rowsRenderCalculator.startRow},getFirstVisibleRow:function(){return this.wot.wtViewport.rowsVisibleCalculator.startRow},getFirstRenderedColumn:function(){return this.wot.wtViewport.columnsRenderCalculator.startColumn},getFirstVisibleColumn:function(){return this.wot.wtViewport.columnsVisibleCalculator.startColumn},getLastRenderedRow:function(){return this.wot.wtViewport.rowsRenderCalculator.endRow},getLastVisibleRow:function(){return this.wot.wtViewport.rowsVisibleCalculator.endRow},getLastRenderedColumn:function(){return this.wot.wtViewport.columnsRenderCalculator.endColumn},getLastVisibleColumn:function(){return this.wot.wtViewport.columnsVisibleCalculator.endColumn},isRowBeforeRenderedRows:function(e){return this.rowFilter&&this.rowFilter.sourceToRendered(e)<0&&e>=0},isRowAfterViewport:function(e){return this.rowFilter&&this.rowFilter.sourceToRendered(e)>this.getLastVisibleRow()},isRowAfterRenderedRows:function(e){return this.rowFilter&&this.rowFilter.sourceToRendered(e)>this.getLastRenderedRow()},isColumnBeforeViewport:function(e){return this.columnFilter&&this.columnFilter.sourceToRendered(e)<0&&e>=0},isColumnAfterViewport:function(e){return this.columnFilter&&this.columnFilter.sourceToRendered(e)>this.getLastVisibleColumn()},isLastRowFullyVisible:function(){return this.getLastVisibleRow()===this.getLastRenderedRow()},isLastColumnFullyVisible:function(){return this.getLastVisibleColumn()===this.getLastRenderedColumn()},getRenderedColumnsCount:function(){var e=this.wot.wtViewport.columnsRenderCalculator.count,t=this.wot.getSetting("totalColumns");if(this.wot.isOverlayName(WalkontableOverlay.CLONE_DEBUG))e=t;else if(this.wot.isOverlayName(WalkontableOverlay.CLONE_LEFT)||this.wot.isOverlayName(WalkontableOverlay.CLONE_TOP_LEFT_CORNER)||this.wot.isOverlayName(WalkontableOverlay.CLONE_BOTTOM_LEFT_CORNER))return Math.min(this.wot.getSetting("fixedColumnsLeft"),t);return e},getRenderedRowsCount:function(){var e=this.wot.wtViewport.rowsRenderCalculator.count,t=this.wot.getSetting("totalRows");return this.wot.isOverlayName(WalkontableOverlay.CLONE_DEBUG)?e=t:this.wot.isOverlayName(WalkontableOverlay.CLONE_TOP)||this.wot.isOverlayName(WalkontableOverlay.CLONE_TOP_LEFT_CORNER)?e=Math.min(this.wot.getSetting("fixedRowsTop"),t):(this.wot.isOverlayName(WalkontableOverlay.CLONE_BOTTOM)||this.wot.isOverlayName(WalkontableOverlay.CLONE_BOTTOM_LEFT_CORNER))&&(e=Math.min(this.wot.getSetting("fixedRowsBottom"),t)),e},getVisibleRowsCount:function(){return this.wot.wtViewport.rowsVisibleCalculator.count},allRowsInViewport:function(){return this.wot.getSetting("totalRows")==this.getVisibleRowsCount()},getRowHeight:function(e){var t=this.wot.wtSettings.settings.rowHeight(e),o=this.wot.wtViewport.oversizedRows[e];return void 0!==o&&(t=void 0===t?o:Math.max(t,o)),t},getColumnHeaderHeight:function(e){var t=this.wot.wtSettings.settings.defaultRowHeight,o=this.wot.wtViewport.oversizedColumnHeaders[e];return void 0!==o&&(t=t?Math.max(t,o):o),t},getVisibleColumnsCount:function(){return this.wot.wtViewport.columnsVisibleCalculator.count},allColumnsInViewport:function(){return this.wot.getSetting("totalColumns")==this.getVisibleColumnsCount()},getColumnWidth:function(e){var t=this.wot.wtSettings.settings.columnWidth;return"function"==typeof t?t=t(e):"object"==typeof t&&(t=t[e]),t||this.wot.wtSettings.settings.defaultColumnWidth},getStretchedColumnWidth:function(e){var t=this.getColumnWidth(e),o=null==t?this.instance.wtSettings.settings.defaultColumnWidth:t,n=this.wot.wtViewport.columnsRenderCalculator;if(n){var r=n.getStretchedColumnWidth(e,o);r&&(o=r)}return o},_modifyRowHeaderWidth:function(e){var t=b(e)?e():null;return Array.isArray(t)?(t=$traceurRuntime.spread(t),t[t.length-1]=this._correctRowHeaderWidth(t[t.length-1])):t=this._correctRowHeaderWidth(t),t},_correctRowHeaderWidth:function(e){return"number"!=typeof e&&(e=this.wot.getSetting("defaultColumnWidth")),this.correctHeaderWidth&&e++,e}},{}),window.WalkontableTable=S},{"cell/coords":6,"cell/range":7,"filter/column":10,"filter/row":11,"helpers/dom/element":47,"helpers/function":50,tableRenderer:22}],22:[function(e,t,o){"use strict";function n(e,t){var o=document.createElement("TH");return t.insertBefore(o,e),t.removeChild(e),o}function r(e,t){var o=document.createElement("TD");return t.insertBefore(o,e),t.removeChild(e),o}Object.defineProperties(o,{WalkontableTableRenderer:{get:function(){return p}},__esModule:{value:!0}});var i,s=(i=e("helpers/dom/element"))&&i.__esModule&&i||{default:i},a=s.addClass,l=s.empty,u=s.getScrollbarWidth,c=s.hasClass,d=s.innerHeight,h=s.outerWidth,f=!1,p=function(e){this.wtTable=e,this.wot=e.instance,this.instance=e.instance,this.rowFilter=e.rowFilter,this.columnFilter=e.columnFilter,this.TABLE=e.TABLE,this.THEAD=e.THEAD,this.TBODY=e.TBODY,this.COLGROUP=e.COLGROUP,this.rowHeaders=[],this.rowHeaderCount=0,this.columnHeaders=[],this.columnHeaderCount=0,this.fixedRowsTop=0,this.fixedRowsBottom=0};$traceurRuntime.createClass(p,{render:function(){if(!this.wtTable.isWorkingOnClone()){var e={};if(this.wot.getSetting("beforeDraw",!0,e),e.skipRender===!0)return}this.rowHeaders=this.wot.getSetting("rowHeaders"),this.rowHeaderCount=this.rowHeaders.length,this.fixedRowsTop=this.wot.getSetting("fixedRowsTop"),this.fixedRowsBottom=this.wot.getSetting("fixedRowsBottom"),this.columnHeaders=this.wot.getSetting("columnHeaders"),this.columnHeaderCount=this.columnHeaders.length;var t,o=this.wtTable.getRenderedColumnsCount(),n=this.wtTable.getRenderedRowsCount(),r=this.wot.getSetting("totalColumns"),i=this.wot.getSetting("totalRows"),s=!1;if((WalkontableOverlay.isOverlayTypeOf(this.wot.cloneOverlay,WalkontableOverlay.CLONE_BOTTOM)||WalkontableOverlay.isOverlayTypeOf(this.wot.cloneOverlay,WalkontableOverlay.CLONE_BOTTOM_LEFT_CORNER))&&(this.columnHeaders=[],this.columnHeaderCount=0),r>=0&&(this.adjustAvailableNodes(),s=!0,this.renderColumnHeaders(),this.renderRows(i,n,o),this.wtTable.isWorkingOnClone()||(t=this.wot.wtViewport.getWorkspaceWidth(),this.wot.wtViewport.containerWidth=null),this.adjustColumnWidths(o),this.markOversizedColumnHeaders(),this.adjustColumnHeaderHeights()),s||this.adjustAvailableNodes(),this.removeRedundantRows(n),this.wtTable.isWorkingOnClone()&&!this.wot.isOverlayName(WalkontableOverlay.CLONE_BOTTOM)||this.markOversizedRows(),this.wtTable.isWorkingOnClone())this.wot.isOverlayName(WalkontableOverlay.CLONE_BOTTOM)&&this.wot.cloneSource.wtOverlays.adjustElementsSize();else{this.wot.wtViewport.createVisibleCalculators(),this.wot.wtOverlays.refresh(!1),this.wot.wtOverlays.applyToDOM();var a=h(this.wtTable.hider),l=h(this.wtTable.TABLE);if(0!==a&&l!==a&&this.adjustColumnWidths(o),t!==this.wot.wtViewport.getWorkspaceWidth()){this.wot.wtViewport.containerWidth=null;var u=this.wtTable.getFirstRenderedColumn(),c=this.wtTable.getLastRenderedColumn(),d=this.wot.getSetting("defaultColumnWidth"),f=this.wot.getSetting("rowHeaderWidth");if(null!=(f=this.instance.getSetting("onModifyRowHeaderWidth",f)))for(var p=0;p<this.rowHeaderCount;p++){var g=Array.isArray(f)?f[p]:f;g=null==g?d:g,this.COLGROUP.childNodes[p].style.width=g+"px"}for(var m=u;m<c;m++){var w=this.wtTable.getStretchedColumnWidth(m),v=this.columnFilter.sourceToRendered(m);this.COLGROUP.childNodes[v+this.rowHeaderCount].style.width=w+"px"}}this.wot.getSetting("onDraw",!0)}},removeRedundantRows:function(e){for(;this.wtTable.tbodyChildrenLength>e;)this.TBODY.removeChild(this.TBODY.lastChild),this.wtTable.tbodyChildrenLength--},renderRows:function(e,t,o){for(var n,r=0,i=this.rowFilter.renderedToSource(r),s=this.wtTable.isWorkingOnClone();i<e&&i>=0&&(!f&&r>1e3&&(f=!0,console.warn('Performance tip: Handsontable rendered more than 1000 visible rows. Consider limiting the number of rendered rows by specifying the table height and/or turning off the "renderAllRows" option.')),void 0===t||r!==t);){if(n=this.getOrCreateTrForRow(r,n),this.renderRowHeaders(i,n),this.adjustColumns(n,o+this.rowHeaderCount),this.renderCells(i,n,o),s&&!this.wot.isOverlayName(WalkontableOverlay.CLONE_BOTTOM)||this.resetOversizedRow(i),n.firstChild){var a=this.wot.wtTable.getRowHeight(i);a?(a--,n.firstChild.style.height=a+"px"):n.firstChild.style.height=""}r++,i=this.rowFilter.renderedToSource(r)}},resetOversizedRow:function(e){this.wot.getSetting("externalRowCalculator")||this.wot.wtViewport.oversizedRows&&this.wot.wtViewport.oversizedRows[e]&&(this.wot.wtViewport.oversizedRows[e]=void 0)},markOversizedRows:function(){if(!this.wot.getSetting("externalRowCalculator")){var e,t,o,n,r,i=this.instance.wtTable.TBODY.childNodes.length,s=i*this.instance.wtSettings.settings.defaultRowHeight,a=d(this.instance.wtTable.TBODY)-1;this.instance.getSetting("totalRows");if(s!==a||this.instance.getSetting("fixedRowsBottom"))for(;i;)i--,o=this.instance.wtTable.rowFilter.renderedToSource(i),e=this.instance.wtTable.getRowHeight(o),n=this.instance.wtTable.getTrForRow(o),r=n.querySelector("th"),t=r?d(r):d(n)-1,(!e&&this.instance.wtSettings.settings.defaultRowHeight<t||e<t)&&(this.instance.wtViewport.oversizedRows[o]=++t)}},markOversizedColumnHeaders:function(){var e=this.wot.getOverlayName();if(this.columnHeaderCount&&!this.wot.wtViewport.hasOversizedColumnHeadersMarked[e]&&!this.wtTable.isWorkingOnClone()){for(var t=this.wtTable.getRenderedColumnsCount(),o=0;o<this.columnHeaderCount;o++)for(var n=-1*this.rowHeaderCount;n<t;n++)this.markIfOversizedColumnHeader(n);this.wot.wtViewport.hasOversizedColumnHeadersMarked[e]=!0}},adjustColumnHeaderHeights:function(){for(var e=this.wot.getSetting("columnHeaders"),t=this.wot.wtTable.THEAD.childNodes,o=this.wot.wtViewport.oversizedColumnHeaders,n=0,r=e.length;n<r;n++)if(o[n]){if(!t[n]||0===t[n].childNodes.length)return;t[n].childNodes[0].style.height=o[n]+"px"}},markIfOversizedColumnHeader:function(e){for(var t,o,n,r=this.wot.wtTable.columnFilter.renderedToSource(e),i=this.columnHeaderCount,s=this.wot.wtSettings.settings.defaultRowHeight,a=this.wot.getSetting("columnHeaderHeight")||[];i;)i--,t=this.wot.wtTable.getColumnHeaderHeight(i),(o=this.wot.wtTable.getColumnHeader(r,i))&&(n=d(o),(!t&&s<n||t<n)&&(this.wot.wtViewport.oversizedColumnHeaders[i]=n),Array.isArray(a)?null!=a[i]&&(this.wot.wtViewport.oversizedColumnHeaders[i]=a[i]):isNaN(a)||(this.wot.wtViewport.oversizedColumnHeaders[i]=a),this.wot.wtViewport.oversizedColumnHeaders[i]<(a[i]||a)&&(this.wot.wtViewport.oversizedColumnHeaders[i]=a[i]||a))},renderCells:function(e,t,o){for(var n,i,s=0;s<o;s++)i=this.columnFilter.renderedToSource(s),n=0===s?t.childNodes[this.columnFilter.sourceColumnToVisibleRowHeadedColumn(i)]:n.nextSibling,"TH"==n.nodeName&&(n=r(n,t)),c(n,"hide")||(n.className=""),n.removeAttribute("style"),this.wot.wtSettings.settings.cellRenderer(e,i,n);return n},adjustColumnWidths:function(e){var t=0,o=this.wot.cloneSource?this.wot.cloneSource:this.wot,n=o.wtTable.holder,r=this.wot.getSetting("defaultColumnWidth"),i=this.wot.getSetting("rowHeaderWidth");if(n.offsetHeight<n.scrollHeight&&(t=u()),this.wot.wtViewport.columnsRenderCalculator.refreshStretching(this.wot.wtViewport.getViewportWidth()-t),null!=(i=this.instance.getSetting("onModifyRowHeaderWidth",i)))for(var s=0;s<this.rowHeaderCount;s++){var a=Array.isArray(i)?i[s]:i;a=null==a?r:a,this.COLGROUP.childNodes[s].style.width=a+"px"}for(var l=0;l<e;l++){var c=this.wtTable.getStretchedColumnWidth(this.columnFilter.renderedToSource(l));this.COLGROUP.childNodes[l+this.rowHeaderCount].style.width=c+"px"}},appendToTbody:function(e){this.TBODY.appendChild(e),this.wtTable.tbodyChildrenLength++},getOrCreateTrForRow:function(e,t){var o;return e>=this.wtTable.tbodyChildrenLength?(o=this.createRow(),this.appendToTbody(o)):o=0===e?this.TBODY.firstChild:t.nextSibling,o.className&&o.removeAttribute("class"),o},createRow:function(){for(var e=document.createElement("TR"),t=0;t<this.rowHeaderCount;t++)e.appendChild(document.createElement("TH"));return e},renderRowHeader:function(e,t,o){o.className="",o.removeAttribute("style"),this.rowHeaders[t](e,o,t)},renderRowHeaders:function(e,t){for(var o=t.firstChild,r=0;r<this.rowHeaderCount;r++)o?"TD"==o.nodeName&&(o=n(o,t)):(o=document.createElement("TH"),t.appendChild(o)),this.renderRowHeader(e,r,o),o=o.nextSibling},adjustAvailableNodes:function(){this.adjustColGroups(),this.adjustThead()},renderColumnHeaders:function(){if(this.columnHeaderCount)for(var e=this.wtTable.getRenderedColumnsCount(),t=0;t<this.columnHeaderCount;t++)for(var o=this.getTrForColumnHeaders(t),n=-1*this.rowHeaderCount;n<e;n++){var r=this.columnFilter.renderedToSource(n);this.renderColumnHeader(t,r,o.childNodes[n+this.rowHeaderCount])}},adjustColGroups:function(){for(var e=this.wtTable.getRenderedColumnsCount();this.wtTable.colgroupChildrenLength<e+this.rowHeaderCount;)this.COLGROUP.appendChild(document.createElement("COL")),this.wtTable.colgroupChildrenLength++;for(;this.wtTable.colgroupChildrenLength>e+this.rowHeaderCount;)this.COLGROUP.removeChild(this.COLGROUP.lastChild),this.wtTable.colgroupChildrenLength--;this.rowHeaderCount&&a(this.COLGROUP.childNodes[0],"rowHeader")},adjustThead:function(){var e=this.wtTable.getRenderedColumnsCount(),t=this.THEAD.firstChild;if(this.columnHeaders.length){for(var o=0,n=this.columnHeaders.length;o<n;o++){for(t=this.THEAD.childNodes[o],t||(t=document.createElement("TR"),this.THEAD.appendChild(t)),this.theadChildrenLength=t.childNodes.length;this.theadChildrenLength<e+this.rowHeaderCount;)t.appendChild(document.createElement("TH")),this.theadChildrenLength++;for(;this.theadChildrenLength>e+this.rowHeaderCount;)t.removeChild(t.lastChild),this.theadChildrenLength--}var r=this.THEAD.childNodes.length;if(r>this.columnHeaders.length)for(var i=this.columnHeaders.length;i<r;i++)this.THEAD.removeChild(this.THEAD.lastChild)}else t&&l(t)},getTrForColumnHeaders:function(e){return this.THEAD.childNodes[e]},renderColumnHeader:function(e,t,o){return o.className="",o.removeAttribute("style"),this.columnHeaders[e](t,o,e)},adjustColumns:function(e,t){for(var o=e.childNodes.length;o<t;){var n=document.createElement("TD");e.appendChild(n),o++}for(;o>t;)e.removeChild(e.lastChild),o--},removeRedundantColumns:function(e){for(;this.wtTable.tbodyChildrenLength>e;)this.TBODY.removeChild(this.TBODY.lastChild),this.wtTable.tbodyChildrenLength--}},{}),window.WalkontableTableRenderer=p},{"helpers/dom/element":47}],23:[function(e,t,o){"use strict";Object.defineProperties(o,{WalkontableViewport:{get:function(){return b}},__esModule:{value:!0}});var n,r,i,s,a,l,u=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,c=(r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r},d=c.getScrollbarWidth,h=(c.getScrollTop,c.getStyle),f=c.offset,p=c.outerHeight,g=c.outerWidth,m=((i=e("helpers/object"))&&i.__esModule&&i||{default:i}).objectEach,w=((s=e("eventManager"))&&s.__esModule&&s||{default:s}).EventManager,v=((a=e("calculator/viewportColumns"))&&a.__esModule&&a||{default:a}).WalkontableViewportColumnsCalculator,y=((l=e("calculator/viewportRows"))&&l.__esModule&&l||{default:l}).WalkontableViewportRowsCalculator,b=function(e){var t=this;this.wot=e,this.instance=this.wot,this.oversizedRows=[],this.oversizedColumnHeaders=[],this.hasOversizedColumnHeadersMarked={},this.clientHeight=0,this.containerWidth=NaN,this.rowHeaderWidth=NaN,this.rowsVisibleCalculator=null,this.columnsVisibleCalculator=null,this.eventManager=new w(this.wot),this.eventManager.addEventListener(window,"resize",function(){t.clientHeight=t.getWorkspaceHeight()})};$traceurRuntime.createClass(b,{getWorkspaceHeight:function(){var e,t=this.instance.wtOverlays.topOverlay.trimmingContainer,o=0;return t===window?o=document.documentElement.clientHeight:(e=p(t),o=e>0&&t.clientHeight>0?t.clientHeight:1/0),o},getWorkspaceWidth:function(){var e,t,o=this.wot.getSetting("totalColumns"),n=this.instance.wtOverlays.leftOverlay.trimmingContainer,r=this.wot.getSetting("stretchH"),i=document.documentElement.offsetWidth;return this.wot.getSetting("preventOverflow")?g(this.instance.wtTable.wtRootElement):(e=u.freezeOverlays?Math.min(i-this.getWorkspaceOffset().left,i):Math.min(this.getContainerFillWidth(),i-this.getWorkspaceOffset().left,i),n===window&&o>0&&this.sumColumnWidths(0,o-1)>e?document.documentElement.clientWidth:n===window||"scroll"!=(t=h(this.instance.wtOverlays.leftOverlay.trimmingContainer,"overflow"))&&"hidden"!=t&&"auto"!=t?"none"!==r&&r?e:Math.max(e,g(this.instance.wtTable.TABLE)):Math.max(e,n.clientWidth))},hasVerticalScroll:function(){return this.getWorkspaceActualHeight()>this.getWorkspaceHeight()},hasHorizontalScroll:function(){return this.getWorkspaceActualWidth()>this.getWorkspaceWidth()},sumColumnWidths:function(e,t){for(var o=0;e<t;)o+=this.wot.wtTable.getColumnWidth(e),e++;return o},getContainerFillWidth:function(){if(this.containerWidth)return this.containerWidth;var e,t,o=this.instance.wtTable.holder;return t=document.createElement("div"),t.style.width="100%",t.style.height="1px",o.appendChild(t),e=t.offsetWidth,this.containerWidth=e,o.removeChild(t),e},getWorkspaceOffset:function(){return f(this.wot.wtTable.TABLE)},getWorkspaceActualHeight:function(){return p(this.wot.wtTable.TABLE)},getWorkspaceActualWidth:function(){return g(this.wot.wtTable.TABLE)||g(this.wot.wtTable.TBODY)||g(this.wot.wtTable.THEAD)},getColumnHeaderHeight:function(){return isNaN(this.columnHeaderHeight)&&(this.columnHeaderHeight=p(this.wot.wtTable.THEAD)),this.columnHeaderHeight},getViewportHeight:function(){var e,t=this.getWorkspaceHeight();return t===1/0?t:(e=this.getColumnHeaderHeight(),e>0&&(t-=e),t)},getRowHeaderWidth:function(){var e=this.instance.getSetting("rowHeaderWidth"),t=this.instance.getSetting("rowHeaders");if(e){this.rowHeaderWidth=0;for(var o=0,n=t.length;o<n;o++)this.rowHeaderWidth+=e[o]||e}if(this.wot.cloneSource)return this.wot.cloneSource.wtViewport.getRowHeaderWidth();if(isNaN(this.rowHeaderWidth))if(t.length){var r=this.instance.wtTable.TABLE.querySelector("TH");this.rowHeaderWidth=0;for(var i=0,s=t.length;i<s;i++)r?(this.rowHeaderWidth+=g(r),r=r.nextSibling):this.rowHeaderWidth+=50}else this.rowHeaderWidth=0;return this.rowHeaderWidth=this.instance.getSetting("onModifyRowHeaderWidth",this.rowHeaderWidth)||this.rowHeaderWidth,this.rowHeaderWidth},getViewportWidth:function(){var e,t=this.getWorkspaceWidth();return t===1/0?t:(e=this.getRowHeaderWidth(),e>0?t-e:t)},createRowsCalculator:function(){var e,t,o,n,r,i,s,a=void 0!==arguments[0]&&arguments[0],l=this;return this.rowHeaderWidth=NaN,e=this.wot.wtSettings.settings.renderAllRows?1/0:this.getViewportHeight(),t=this.wot.wtOverlays.topOverlay.getScrollPosition()-this.wot.wtOverlays.topOverlay.getTableParentOffset(),t<0&&(t=0),o=this.wot.getSetting("fixedRowsTop"),r=this.wot.getSetting("fixedRowsBottom"),s=this.wot.getSetting("totalRows"),
30
- o&&(i=this.wot.wtOverlays.topOverlay.sumCellSizes(0,o),t+=i,e-=i),r&&this.wot.wtOverlays.bottomOverlay.clone&&(i=this.wot.wtOverlays.bottomOverlay.sumCellSizes(s-r,s),e-=i),n=this.wot.wtTable.holder.clientHeight===this.wot.wtTable.holder.offsetHeight?0:d(),new y(e,t,this.wot.getSetting("totalRows"),function(e){return l.wot.wtTable.getRowHeight(e)},a?null:this.wot.wtSettings.settings.viewportRowCalculatorOverride,a,n)},createColumnsCalculator:function(){var e,t,o=void 0!==arguments[0]&&arguments[0],n=this,r=this.getViewportWidth();if(this.columnHeaderHeight=NaN,e=this.wot.wtOverlays.leftOverlay.getScrollPosition()-this.wot.wtOverlays.leftOverlay.getTableParentOffset(),e<0&&(e=0),t=this.wot.getSetting("fixedColumnsLeft")){var i=this.wot.wtOverlays.leftOverlay.sumCellSizes(0,t);e+=i,r-=i}return this.wot.wtTable.holder.clientWidth!==this.wot.wtTable.holder.offsetWidth&&(r-=d()),new v(r,e,this.wot.getSetting("totalColumns"),function(e){return n.wot.wtTable.getColumnWidth(e)},o?null:this.wot.wtSettings.settings.viewportColumnCalculatorOverride,o,this.wot.getSetting("stretchH"),function(e,t){return n.wot.getSetting("onBeforeStretchingColumnWidth",e,t)})},createRenderCalculators:function(){var e=void 0!==arguments[0]&&arguments[0];if(e){var t=this.createRowsCalculator(!0),o=this.createColumnsCalculator(!0);this.areAllProposedVisibleRowsAlreadyRendered(t)&&this.areAllProposedVisibleColumnsAlreadyRendered(o)||(e=!1)}return e||(this.rowsRenderCalculator=this.createRowsCalculator(),this.columnsRenderCalculator=this.createColumnsCalculator()),this.rowsVisibleCalculator=null,this.columnsVisibleCalculator=null,e},createVisibleCalculators:function(){this.rowsVisibleCalculator=this.createRowsCalculator(!0),this.columnsVisibleCalculator=this.createColumnsCalculator(!0)},areAllProposedVisibleRowsAlreadyRendered:function(e){return!!this.rowsVisibleCalculator&&(!(e.startRow<this.rowsRenderCalculator.startRow||e.startRow===this.rowsRenderCalculator.startRow&&e.startRow>0)&&!(e.endRow>this.rowsRenderCalculator.endRow||e.endRow===this.rowsRenderCalculator.endRow&&e.endRow<this.wot.getSetting("totalRows")-1))},areAllProposedVisibleColumnsAlreadyRendered:function(e){return!!this.columnsVisibleCalculator&&(!(e.startColumn<this.columnsRenderCalculator.startColumn||e.startColumn===this.columnsRenderCalculator.startColumn&&e.startColumn>0)&&!(e.endColumn>this.columnsRenderCalculator.endColumn||e.endColumn===this.columnsRenderCalculator.endColumn&&e.endColumn<this.wot.getSetting("totalColumns")-1))},resetHasOversizedColumnHeadersMarked:function(){m(this.hasOversizedColumnHeadersMarked,function(e,t,o){o[t]=void 0})}},{}),window.WalkontableViewport=b},{browser:24,"calculator/viewportColumns":4,"calculator/viewportRows":5,eventManager:42,"helpers/dom/element":47,"helpers/object":53}],24:[function(e,t,o){"use strict";function n(e,t){var o=new n.Core(e,t||{});return o.init(),o}var r,i,s,a,l,u,c,d,h,f,p,g,m,w,v,y,b,C,_,R,M,S,E,O;t.exports=n,n.utils={},(r=e("shims/runtime"))&&r.__esModule,(i=e("es6collections"))&&i.__esModule;var T=((s=e("pluginHooks"))&&s.__esModule&&s||{default:s}).Hooks,k=((a=e("numbro"))&&a.__esModule&&a||{default:a}).default,x=((l=e("moment"))&&l.__esModule&&l||{default:l}).default;"object"==typeof window&&(void 0===window.numbro&&(window.numbro=k),void 0===window.moment&&(window.moment=x)),n.hooks||(n.hooks=new T),n.utils.Hooks=T,(u=e("core"))&&u.__esModule,(c=e("renderers/_cellDecorator"))&&c.__esModule,(d=e("cellTypes"))&&d.__esModule,(h=e("plugins/jqueryHandsontable"))&&h.__esModule;var H=(f=e("helpers/array"))&&f.__esModule&&f||{default:f},D=(p=e("helpers/browser"))&&p.__esModule&&p||{default:p},A=(g=e("helpers/data"))&&g.__esModule&&g||{default:g},P=(m=e("helpers/date"))&&m.__esModule&&m||{default:m},L=(w=e("helpers/feature"))&&w.__esModule&&w||{default:w},N=(v=e("helpers/function"))&&v.__esModule&&v||{default:v},I=(y=e("helpers/mixed"))&&y.__esModule&&y||{default:y},W=(b=e("helpers/number"))&&b.__esModule&&b||{default:b},j=(C=e("helpers/object"))&&C.__esModule&&C||{default:C},V=(_=e("helpers/setting"))&&_.__esModule&&_||{default:_},B=(R=e("helpers/string"))&&R.__esModule&&R||{default:R},F=(M=e("helpers/unicode"))&&M.__esModule&&M||{default:M},z=(S=e("helpers/dom/element"))&&S.__esModule&&S||{default:S},Y=(E=e("helpers/dom/event"))&&E.__esModule&&E||{default:E},U=[H,D,A,P,L,N,I,W,j,V,B,F],G=[z,Y];n.buildDate="Tue Mar 07 2017 13:32:36 GMT+0100 (CET)",n.packageName="handsontable",n.version="0.31.1";/^@@/.test("@@baseVersion")||(n.baseVersion="@@baseVersion"),n.plugins={};var $=((O=e("plugins"))&&O.__esModule&&O||{default:O}).registerPlugin;n.plugins.registerPlugin=$,n.helper={},n.dom={},n.Dom=n.dom,H.arrayEach(U,function(e){H.arrayEach(Object.getOwnPropertyNames(e),function(t){"_"!==t.charAt(0)&&(n.helper[t]=e[t])})}),H.arrayEach(G,function(e){H.arrayEach(Object.getOwnPropertyNames(e),function(t){"_"!==t.charAt(0)&&(n.dom[t]=e[t])})})},{cellTypes:25,core:26,es6collections:"es6collections","helpers/array":43,"helpers/browser":44,"helpers/data":45,"helpers/date":46,"helpers/dom/element":47,"helpers/dom/event":48,"helpers/feature":49,"helpers/function":50,"helpers/mixed":51,"helpers/number":52,"helpers/object":53,"helpers/setting":54,"helpers/string":55,"helpers/unicode":56,moment:"moment",numbro:"numbro",pluginHooks:60,plugins:61,"plugins/jqueryHandsontable":2,"renderers/_cellDecorator":118,"shims/runtime":125}],25:[function(e,t,o){"use strict";var n,r,i,s,a,l,u,c,d,h,f,p,g,m,w,v,y,b,C,_,R,M,S,E,O=((n=e("helpers/browser"))&&n.__esModule&&n||{default:n}).isMobileBrowser,T=((r=e("editors"))&&r.__esModule&&r||{default:r}).getEditorConstructor,k=((i=e("renderers"))&&i.__esModule&&i||{default:i}).getRenderer,x=(((s=e("editors/autocompleteEditor"))&&s.__esModule&&s||{default:s}).AutocompleteEditor,((a=e("editors/checkboxEditor"))&&a.__esModule&&a||{default:a}).CheckboxEditor,((l=e("editors/dateEditor"))&&l.__esModule&&l||{default:l}).DateEditor,((u=e("editors/dropdownEditor"))&&u.__esModule&&u||{default:u}).DropdownEditor,((c=e("editors/handsontableEditor"))&&c.__esModule&&c||{default:c}).HandsontableEditor,((d=e("editors/mobileTextEditor"))&&d.__esModule&&d||{default:d}).MobileTextEditor,((h=e("editors/numericEditor"))&&h.__esModule&&h||{default:h}).NumericEditor,((f=e("editors/passwordEditor"))&&f.__esModule&&f||{default:f}).PasswordEditor,((p=e("editors/selectEditor"))&&p.__esModule&&p||{default:p}).SelectEditor,((g=e("editors/textEditor"))&&g.__esModule&&g||{default:g}).TextEditor,((m=e("renderers/autocompleteRenderer"))&&m.__esModule&&m||{default:m}).AutocompleteRenderer,((w=e("renderers/checkboxRenderer"))&&w.__esModule&&w||{default:w}).CheckboxRenderer,((v=e("renderers/htmlRenderer"))&&v.__esModule&&v||{default:v}).HtmlRenderer,((y=e("renderers/numericRenderer"))&&y.__esModule&&y||{default:y}).NumericRenderer,((b=e("renderers/passwordRenderer"))&&b.__esModule&&b||{default:b}).PasswordRenderer,((C=e("renderers/textRenderer"))&&C.__esModule&&C||{default:C}).TextRenderer,((_=e("validators/autocompleteValidator"))&&_.__esModule&&_||{default:_}).AutocompleteValidator,((R=e("validators/dateValidator"))&&R.__esModule&&R||{default:R}).DateValidator,((M=e("validators/timeValidator"))&&M.__esModule&&M||{default:M}).TimeValidator,((S=e("validators/numericValidator"))&&S.__esModule&&S||{default:S}).NumericValidator,((E=e("browser"))&&E.__esModule&&E||{default:E}).default);x.AutocompleteCell={editor:T("autocomplete"),renderer:k("autocomplete"),validator:x.AutocompleteValidator},x.CheckboxCell={editor:T("checkbox"),renderer:k("checkbox")},x.TextCell={editor:T(O()?"mobile":"text"),renderer:k("text")},x.NumericCell={editor:T("numeric"),renderer:k("numeric"),validator:x.NumericValidator,dataType:"number"},x.DateCell={editor:T("date"),validator:x.DateValidator,renderer:k("autocomplete")},x.TimeCell={editor:T("text"),validator:x.TimeValidator,renderer:k("text")},x.HandsontableCell={editor:T("handsontable"),renderer:k("autocomplete")},x.PasswordCell={editor:T("password"),renderer:k("password"),copyable:!1},x.DropdownCell={editor:T("dropdown"),renderer:k("autocomplete"),validator:x.AutocompleteValidator},x.cellTypes={text:x.TextCell,date:x.DateCell,time:x.TimeCell,numeric:x.NumericCell,checkbox:x.CheckboxCell,autocomplete:x.AutocompleteCell,handsontable:x.HandsontableCell,password:x.PasswordCell,dropdown:x.DropdownCell},x.cellLookup={validator:{numeric:x.NumericValidator,autocomplete:x.AutocompleteValidator}}},{browser:24,editors:30,"editors/autocompleteEditor":32,"editors/checkboxEditor":33,"editors/dateEditor":34,"editors/dropdownEditor":35,"editors/handsontableEditor":36,"editors/mobileTextEditor":37,"editors/numericEditor":38,"editors/passwordEditor":39,"editors/selectEditor":40,"editors/textEditor":41,"helpers/browser":44,renderers:117,"renderers/autocompleteRenderer":119,"renderers/checkboxRenderer":120,"renderers/htmlRenderer":121,"renderers/numericRenderer":122,"renderers/passwordRenderer":123,"renderers/textRenderer":124,"validators/autocompleteValidator":133,"validators/dateValidator":134,"validators/numericValidator":135,"validators/timeValidator":136}],26:[function(e,t,o){"use strict";var n,r,i,s,a,l,u,c,d,h,f,p,g,m,w,v,y,b,C,_,R,M,S,E=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,O=((r=e("numbro"))&&r.__esModule&&r||{default:r}).default,T=(i=e("helpers/dom/element"))&&i.__esModule&&i||{default:i},k=T.addClass,x=T.empty,H=T.isChildOfWebComponentTable,D=T.removeClass,A=((s=e("helpers/setting"))&&s.__esModule&&s||{default:s}).columnFactory,P=((a=e("helpers/function"))&&a.__esModule&&a||{default:a}).isFunction,L=(l=e("helpers/mixed"))&&l.__esModule&&l||{default:l},N=L.isDefined,I=L.isUndefined,W=((u=e("helpers/browser"))&&u.__esModule&&u||{default:u}).isMobileBrowser,j=((c=e("dataMap"))&&c.__esModule&&c||{default:c}).DataMap,V=((d=e("editorManager"))&&d.__esModule&&d||{default:d}).EditorManager,B=((h=e("eventManager"))&&h.__esModule&&h||{default:h}).eventManager,F=(f=e("helpers/object"))&&f.__esModule&&f||{default:f},z=F.deepClone,Y=F.duckSchema,U=F.extend,G=F.isObject,$=F.isObjectEquals,K=F.deepObjectSize,X=F.createObjectPropListener,q=(p=e("helpers/array"))&&p.__esModule&&p||{default:p},Z=q.arrayFlatten,J=q.arrayMap,Q=((g=e("plugins"))&&g.__esModule&&g||{default:g}).getPlugin,ee=((m=e("renderers"))&&m.__esModule&&m||{default:m}).getRenderer,te=((w=e("helpers/string"))&&w.__esModule&&w||{default:w}).randomString,oe=((v=e("helpers/number"))&&v.__esModule&&v||{default:v}).rangeEach,ne=((y=e("tableView"))&&y.__esModule&&y||{default:y}).TableView,re=((b=e("dataSource"))&&b.__esModule&&b||{default:b}).DataSource,ie=(C=e("helpers/data"))&&C.__esModule&&C||{default:C},se=ie.translateRowsToColumns,ae=ie.cellMethodLookupFactory,le=ie.spreadsheetColumnLabel,ue=((_=e("utils/recordTranslator"))&&_.__esModule&&_||{default:_}).getTranslator,ce=((R=e("3rdparty/walkontable/src/cell/coords"))&&R.__esModule&&R||{default:R}).WalkontableCellCoords,de=((M=e("3rdparty/walkontable/src/cell/range"))&&M.__esModule&&M||{default:M}).WalkontableCellRange,he=((S=e("3rdparty/walkontable/src/calculator/viewportColumns"))&&S.__esModule&&S||{default:S}).WalkontableViewportColumnsCalculator;E.activeGuid=null,E.Core=function(e,t){function o(){var e=!1;return{validatorsInQueue:0,valid:!0,addValidatorToQueue:function(){this.validatorsInQueue++,e=!1},removeValidatorFormQueue:function(){this.validatorsInQueue=this.validatorsInQueue-1<0?0:this.validatorsInQueue-1,this.checkIfQueueIsEmpty()},onQueueEmpty:function(e){},checkIfQueueIsEmpty:function(){0==this.validatorsInQueue&&0==e&&(e=!0,this.onQueueEmpty(this.valid))}}}function n(e,t,n){function r(){var o;e.length&&(o=E.hooks.run(p,"beforeChange",e,t),P(o)?console.warn("Your beforeChange callback returns a function. It's not supported since Handsontable 0.12.1 (and the returned function will not be executed)."):o===!1&&e.splice(0,e.length)),n()}var i=new o;i.onQueueEmpty=r;for(var s=e.length-1;s>=0;s--)if(null===e[s])e.splice(s,1);else{var a=e[s][0],l=u.propToCol(e[s][1]),c=p.getCellMeta(a,l);if("numeric"===c.type&&"string"==typeof e[s][3]&&e[s][3].length>0&&(/^-?[\d\s]*(\.|\,)?\d*$/.test(e[s][3])||c.format)){var d=e[s][3].length;I(c.language)?O.culture("en-US"):e[s][3].indexOf(".")===d-3&&e[s][3].indexOf(",")===-1?O.culture("en-US"):O.culture(c.language);O.cultureData(O.culture()).delimiters;O.validate(e[s][3])&&!isNaN(e[s][3])?e[s][3]=parseFloat(e[s][3]):e[s][3]=O().unformat(e[s][3])||e[s][3]}p.getCellValidator(c)&&(i.addValidatorToQueue(),p.validateCell(e[s][3],c,function(t,o){return function(n){if("boolean"!=typeof n)throw new Error("Validation error: result is not boolean");if(n===!1&&o.allowInvalid===!1){e.splice(t,1),o.valid=!0;D(p.getCell(o.row,o.col),p.getSettings().invalidCellClassName),--t}i.removeValidatorFormQueue()}}(s,c),t))}i.checkIfQueueIsEmpty()}function r(e,t){var o=e.length-1;if(!(o<0)){for(;0<=o;o--){var n=!1;if(null!==e[o]){if(null!=e[o][2]||null!=e[o][3]){if(l.settings.allowInsertRow)for(;e[o][0]>p.countRows()-1;){var r=u.createRow(void 0,void 0,t);if(0===r){n=!0;break}}if(!n){if("array"===p.dataType&&(!l.settings.columns||0===l.settings.columns.length)&&l.settings.allowInsertColumn)for(;u.propToCol(e[o][1])>p.countCols()-1;)u.createCol(void 0,void 0,t);u.set(e[o][0],e[o][1],e[o][3])}}}else e.splice(o,1)}p.forceFullRender=!0,d.adjustRowsAndCols(),E.hooks.run(p,"beforeChangeRender",e,t),h.refreshBorders(null,!0),p.view.wt.wtOverlays.adjustElementsSize(),E.hooks.run(p,"afterChange",e,t||"edit");var i=p.getActiveEditor();i&&N(i.refreshValue)&&i.refreshValue()}}function i(e,t,o){return"object"==typeof e?e:[[e,t,o]]}function s(e){if(e.hasOwnProperty("type")){var t,o={};if("object"==typeof e.type)t=e.type;else if("string"==typeof e.type&&void 0===(t=E.cellTypes[e.type]))throw new Error('You declared cell type "'+e.type+'" as a string that is not mapped to a known object. Cell type must be an object or a string mapped to an object in Handsontable.cellTypes');for(var n in t)t.hasOwnProperty(n)&&!e.hasOwnProperty(n)&&(o[n]=t[n]);return o}}function a(){throw new Error("This method cannot be called because this Handsontable instance has been destroyed")}var l,u,c,d,h,f,p=this,g=function(){},m=B(p),w=ue(p);U(g.prototype,fe.prototype),U(g.prototype,t),U(g.prototype,s(t)),this.rootElement=e,this.isHotTableEnv=H(this.rootElement),E.eventManager.isHotTableEnv=this.isHotTableEnv,this.container=document.createElement("DIV"),this.renderCall=!1,e.insertBefore(this.container,e.firstChild),this.guid="ht_"+te(),c=new re(p),this.rootElement.id&&"ht_"!==this.rootElement.id.substring(0,3)||(this.rootElement.id=this.guid),l={cellSettings:[],columnSettings:[],columnsSettingConflicts:["data","width"],settings:new g,selRange:null,isPopulated:null,scrollable:null,firstRun:!0},d={alter:function(e,t,o,n,r){function i(e,t,o,n){var r=function(){var e;return"array"===n?e=[]:"object"===n&&(e={}),e},i=J(new Array(o),function(){return r()});i.unshift(t,0),e.splice.apply(e,i)}var s;switch(o=o||1,e){case"insert_row":var a=p.countSourceRows();if(p.getSettings().maxRows===a)return;t=N(t)?t:a,s=u.createRow(t,o,n),i(l.cellSettings,t,o,"array"),s&&(h.isSelected()&&l.selRange.from.row>=t?(l.selRange.from.row=l.selRange.from.row+s,h.transformEnd(s,0)):h.refreshBorders());break;case"insert_col":s=u.createCol(t,o,n);for(var c=0,f=p.countSourceRows();c<f;c++)l.cellSettings[c]&&i(l.cellSettings[c],t,o);if(s){if(Array.isArray(p.getSettings().colHeaders)){var g=[t,0];g.length+=s,Array.prototype.splice.apply(p.getSettings().colHeaders,g)}h.isSelected()&&l.selRange.from.col>=t?(l.selRange.from.col=l.selRange.from.col+s,h.transformEnd(0,s)):h.refreshBorders()}break;case"remove_row":u.removeRow(t,o,n),l.cellSettings.splice(t,o);var m=p.countRows(),v=p.getSettings().fixedRowsTop;v>=t+1&&(p.getSettings().fixedRowsTop-=Math.min(o,v-t));var y=p.getSettings().fixedRowsBottom;y&&t>=m-y&&(p.getSettings().fixedRowsBottom-=Math.min(o,y)),d.adjustRowsAndCols(),h.refreshBorders();break;case"remove_col":var b=w.toPhysicalColumn(t);u.removeCol(t,o,n);for(var C=0,_=p.countSourceRows();C<_;C++)l.cellSettings[C]&&l.cellSettings[C].splice(b,o);var R=p.getSettings().fixedColumnsLeft;R>=t+1&&(p.getSettings().fixedColumnsLeft-=Math.min(o,R-t)),Array.isArray(p.getSettings().colHeaders)&&(void 0===b&&(b=-1),p.getSettings().colHeaders.splice(b,o)),d.adjustRowsAndCols(),h.refreshBorders();break;default:throw new Error('There is no such action "'+e+'"')}r||d.adjustRowsAndCols()},adjustRowsAndCols:function(){if(l.settings.minRows){var e=p.countRows();if(e<l.settings.minRows)for(var t=0,o=l.settings.minRows;t<o-e;t++)u.createRow(p.countRows(),1,"auto")}if(l.settings.minSpareRows){var n=p.countEmptyRows(!0);if(n<l.settings.minSpareRows)for(;n<l.settings.minSpareRows&&p.countSourceRows()<l.settings.maxRows;n++)u.createRow(p.countRows(),1,"auto")}var r;if((l.settings.minCols||l.settings.minSpareCols)&&(r=p.countEmptyCols(!0)),l.settings.minCols&&!l.settings.columns&&p.countCols()<l.settings.minCols)for(;p.countCols()<l.settings.minCols;r++)u.createCol(p.countCols(),1,"auto");if(l.settings.minSpareCols&&!l.settings.columns&&"array"===p.dataType&&r<l.settings.minSpareCols)for(;r<l.settings.minSpareCols&&p.countCols()<l.settings.maxCols;r++)u.createCol(p.countCols(),1,"auto");var i=p.countRows(),s=p.countCols();if(0!==i&&0!==s||h.deselect(),h.isSelected()){var a=!1,c=l.selRange.from.row,d=l.selRange.from.col,f=l.selRange.to.row,g=l.selRange.to.col;c>i-1?(c=i-1,a=!0,f>c&&(f=c)):f>i-1&&(f=i-1,a=!0,c>f&&(c=f)),d>s-1?(d=s-1,a=!0,g>d&&(g=d)):g>s-1&&(g=s-1,a=!0,d>g&&(d=g)),a&&p.selectCell(c,d,f,g)}p.view&&p.view.wt.wtOverlays.adjustElementsSize()},populateFromArray:function(e,t,o,n,r,i,s){var a,u,c,d,h=[],f={};if(0===(u=t.length))return!1;var g,m,w,v;null===o||o.row,null===o||o.col;switch(r){case"shift_down":for(g=o?o.col-e.col+1:0,m=o?o.row-e.row+1:0,t=se(t),c=0,d=t.length,w=Math.max(d,g);c<w;c++)if(c<d){for(a=0,u=t[c].length;a<m-u;a++)t[c].push(t[c][a%u]);t[c].unshift(e.col+c,e.row,0),p.spliceCol.apply(p,t[c])}else t[c%d][0]=e.col+c,p.spliceCol.apply(p,t[c%d]);break;case"shift_right":for(g=o?o.col-e.col+1:0,m=o?o.row-e.row+1:0,a=0,u=t.length,v=Math.max(u,m);a<v;a++)if(a<u){for(c=0,d=t[a].length;c<g-d;c++)t[a].push(t[a][c%d]);t[a].unshift(e.row+a,e.col,0),p.spliceRow.apply(p,t[a])}else t[a%u][0]=e.row+a,p.spliceRow.apply(p,t[a%u]);break;case"overwrite":default:f.row=e.row,f.col=e.col;var y,b={row:o&&e?o.row-e.row+1:1,col:o&&e?o.col-e.col+1:1},C=0,_=0,R=!0,M=function(e){var o=void 0!==arguments[1]?arguments[1]:null,n=t[e%t.length];return null!==o?n[o%n.length]:n},S=t.length,E=o?o.row-e.row+1:0;for(u=o?E:Math.max(S,E),a=0;a<u&&!(o&&f.row>o.row&&E>S||!l.settings.allowInsertRow&&f.row>p.countRows()-1||f.row>=l.settings.maxRows);a++){var O=a-C,T=M(O).length,k=o?o.col-e.col+1:0;if(d=o?k:Math.max(T,k),f.col=e.col,y=p.getCellMeta(f.row,f.col),"CopyPaste.paste"!==n&&"Autofill.autofill"!==n||!y.skipRowOnPaste){for(_=0,c=0;c<d&&!(o&&f.col>o.col&&k>T||!l.settings.allowInsertColumn&&f.col>p.countCols()-1||f.col>=l.settings.maxCols);c++)if(y=p.getCellMeta(f.row,f.col),"CopyPaste.paste"!==n&&"Autofill.fill"!==n||!y.skipColumnOnPaste)if(y.readOnly)f.col++;else{var x=c-_,H=M(O,x),D=p.getDataAtCell(f.row,f.col),A={row:O,col:x};if("Autofill.fill"===n){var P=p.runHooks("beforeAutofillInsidePopulate",A,i,t,s,{},b);P&&(H=I(P.value)?H:P.value)}if(null!==H&&"object"==typeof H)if(null===D||"object"!=typeof D)R=!1;else{var L=Y(D[0]||D),N=Y(H[0]||H);$(L,N)?H=z(H):R=!1}else null!==D&&"object"==typeof D&&(R=!1);R&&h.push([f.row,f.col,H]),R=!0,f.col++}else _++,f.col++,d++;f.row++}else C++,f.row++,u++}p.setDataAtCell(h,null,null,n||"populateFromArray")}}},this.selection=h={inProgress:!1,selectedHeader:{cols:!1,rows:!1},setSelectedHeaders:function(){var e=void 0!==arguments[0]&&arguments[0],t=void 0!==arguments[1]&&arguments[1],o=void 0!==arguments[2]&&arguments[2];p.selection.selectedHeader.rows=e,p.selection.selectedHeader.cols=t,p.selection.selectedHeader.corner=o},begin:function(){p.selection.inProgress=!0},finish:function(){var e=p.getSelected();E.hooks.run(p,"afterSelectionEnd",e[0],e[1],e[2],e[3]),E.hooks.run(p,"afterSelectionEndByProp",e[0],p.colToProp(e[1]),e[2],p.colToProp(e[3])),p.selection.inProgress=!1},isInProgress:function(){return p.selection.inProgress},setRangeStart:function(e,t){E.hooks.run(p,"beforeSetRangeStart",e),l.selRange=new de(e,e,e),h.setRangeEnd(e,null,t)},setRangeStartOnly:function(e){E.hooks.run(p,"beforeSetRangeStartOnly",e),l.selRange=new de(e,e,e)},setRangeEnd:function(e,t,o){if(null!==l.selRange){var n,r=!1,i=!0,s=p.view.wt.wtTable.getFirstVisibleRow(),a=p.view.wt.wtTable.getFirstVisibleColumn(),c={row:null,col:null};E.hooks.run(p,"beforeSetRangeEnd",e),p.selection.begin(),c.row=e.row<0?s:e.row,c.col=e.col<0?a:e.col,l.selRange.to=new ce(c.row,c.col),l.settings.multiSelect||(l.selRange.from=e),p.view.wt.selections.current.clear(),n=p.getCellMeta(l.selRange.highlight.row,l.selRange.highlight.col).disableVisualSelection,"string"==typeof n&&(n=[n]),(n===!1||Array.isArray(n)&&n.indexOf("current")===-1)&&p.view.wt.selections.current.add(l.selRange.highlight),p.view.wt.selections.area.clear(),(n===!1||Array.isArray(n)&&n.indexOf("area")===-1)&&h.isMultiple()&&(p.view.wt.selections.area.add(l.selRange.from),p.view.wt.selections.area.add(l.selRange.to)),(l.settings.currentHeaderClassName||l.settings.currentRowClassName||l.settings.currentColClassName)&&(p.view.wt.selections.highlight.clear(),p.view.wt.selections.highlight.add(l.selRange.from),p.view.wt.selections.highlight.add(l.selRange.to));var d=X("value");E.hooks.run(p,"afterSelection",l.selRange.from.row,l.selRange.from.col,l.selRange.to.row,l.selRange.to.col,d),E.hooks.run(p,"afterSelectionByProp",l.selRange.from.row,u.colToProp(l.selRange.from.col),l.selRange.to.row,u.colToProp(l.selRange.to.col),d),(0===l.selRange.from.row&&l.selRange.to.row===p.countRows()-1&&p.countRows()>1||0===l.selRange.from.col&&l.selRange.to.col===p.countCols()-1&&p.countCols()>1)&&(r=!0),(e.row<0||e.col<0)&&(i=!1),d.isTouched()&&(t=!d.value),t!==!1&&!r&&i&&(l.selRange.from&&!h.isMultiple()?p.view.scrollViewport(l.selRange.from):p.view.scrollViewport(e)),h.selectedHeader.rows&&h.selectedHeader.cols?k(p.rootElement,["ht__selection--rows","ht__selection--columns"]):h.selectedHeader.rows?(D(p.rootElement,"ht__selection--columns"),k(p.rootElement,"ht__selection--rows")):h.selectedHeader.cols?(D(p.rootElement,"ht__selection--rows"),k(p.rootElement,"ht__selection--columns")):D(p.rootElement,["ht__selection--rows","ht__selection--columns"]),h.refreshBorders(null,o)}},refreshBorders:function(e,t){t||f.destroyEditor(e),p.view.render(),h.isSelected()&&!t&&f.prepareEditor()},isMultiple:function(){var e=!(l.selRange.to.col===l.selRange.from.col&&l.selRange.to.row===l.selRange.from.row),t=E.hooks.run(p,"afterIsMultipleSelection",e);if(e)return t},transformStart:function(e,t,o,n){var r,i,s,a,u=new ce(e,t),c=0,d=0;p.runHooks("modifyTransformStart",u),r=p.countRows(),i=p.countCols(),a=p.getSettings().fixedRowsBottom,l.selRange.highlight.row+e>r-1?o&&l.settings.minSpareRows>0&&!(a&&l.selRange.highlight.row>=r-a-1)?(p.alter("insert_row",r),r=p.countRows()):l.settings.autoWrapCol&&(u.row=1-r,u.col=l.selRange.highlight.col+u.col==i-1?1-i:1):l.settings.autoWrapCol&&l.selRange.highlight.row+u.row<0&&l.selRange.highlight.col+u.col>=0&&(u.row=r-1,u.col=l.selRange.highlight.col+u.col==0?i-1:-1),l.selRange.highlight.col+u.col>i-1?o&&l.settings.minSpareCols>0?(p.alter("insert_col",i),i=p.countCols()):l.settings.autoWrapRow&&(u.row=l.selRange.highlight.row+u.row==r-1?1-r:1,u.col=1-i):l.settings.autoWrapRow&&l.selRange.highlight.col+u.col<0&&l.selRange.highlight.row+u.row>=0&&(u.row=l.selRange.highlight.row+u.row==0?r-1:-1,u.col=i-1),s=new ce(l.selRange.highlight.row+u.row,l.selRange.highlight.col+u.col),s.row<0?(c=-1,s.row=0):s.row>0&&s.row>=r&&(c=1,s.row=r-1),s.col<0?(d=-1,s.col=0):s.col>0&&s.col>=i&&(d=1,s.col=i-1),p.runHooks("afterModifyTransformStart",s,c,d),h.setRangeStart(s,n)},transformEnd:function(e,t){var o,n,r,i=new ce(e,t),s=0,a=0;p.runHooks("modifyTransformEnd",i),o=p.countRows(),n=p.countCols(),r=new ce(l.selRange.to.row+i.row,l.selRange.to.col+i.col),r.row<0?(s=-1,r.row=0):r.row>0&&r.row>=o&&(s=1,r.row=o-1),r.col<0?(a=-1,r.col=0):r.col>0&&r.col>=n&&(a=1,r.col=n-1),p.runHooks("afterModifyTransformEnd",r,s,a),h.setRangeEnd(r,!0)},isSelected:function(){return null!==l.selRange},inInSelection:function(e){return!!h.isSelected()&&l.selRange.includes(e)},deselect:function(){h.isSelected()&&(p.selection.inProgress=!1,l.selRange=null,p.view.wt.selections.current.clear(),p.view.wt.selections.area.clear(),(l.settings.currentHeaderClassName||l.settings.currentRowClassName||l.settings.currentColClassName)&&p.view.wt.selections.highlight.clear(),f.destroyEditor(),h.refreshBorders(),D(p.rootElement,["ht__selection--rows","ht__selection--columns"]),E.hooks.run(p,"afterDeselect"))},selectAll:function(){l.settings.multiSelect&&(h.setSelectedHeaders(!0,!0,!0),h.setRangeStart(new ce(0,0)),h.setRangeEnd(new ce(p.countRows()-1,p.countCols()-1),!1))},empty:function(){if(h.isSelected()){var e,t,o=l.selRange.getTopLeftCorner(),n=l.selRange.getBottomRightCorner(),r=[];for(e=o.row;e<=n.row;e++)for(t=o.col;t<=n.col;t++)p.getCellMeta(e,t).readOnly||r.push([e,t,""]);p.setDataAtCell(r)}}},this.init=function(){c.setData(l.settings.data),E.hooks.run(p,"beforeInit"),W()&&k(p.rootElement,"mobile"),this.updateSettings(l.settings,!0),this.view=new ne(this),f=new V(p,l,h,u),this.forceFullRender=!0,E.hooks.run(p,"init"),this.view.render(),"object"==typeof l.firstRun&&(E.hooks.run(p,"afterChange",l.firstRun[0],l.firstRun[1]),l.firstRun=!1),E.hooks.run(p,"afterInit")},this.validateCell=function(e,t,o,n){function r(e){var n=t.visualCol,r=t.visualRow,i=p.getCell(r,n,!0);i&&"TH"!=i.nodeName&&p.view.wt.wtSettings.settings.cellRenderer(r,n,i),o(e)}var i=p.getCellValidator(t);"[object RegExp]"===Object.prototype.toString.call(i)&&(i=function(e){return function(t,o){o(e.test(t))}}(i)),P(i)?(e=E.hooks.run(p,"beforeValidate",e,t.visualRow,t.prop,n),p._registerTimeout(setTimeout(function(){i.call(t,e,function(o){o=E.hooks.run(p,"afterValidate",o,e,t.visualRow,t.prop,n),t.valid=o,r(o),E.hooks.run(p,"postAfterValidate",o,e,t.visualRow,t.prop,n)})},0))):p._registerTimeout(setTimeout(function(){t.valid=!0,r(t.valid)},0))},this.setDataAtCell=function(e,t,o,s){var a,l,d,h=i(e,t,o),f=[];for(a=0,l=h.length;a<l;a++){if("object"!=typeof h[a])throw new Error("Method `setDataAtCell` accepts row number or changes array of arrays as its first parameter");if("number"!=typeof h[a][1])throw new Error("Method `setDataAtCell` accepts row and column number as its parameters. If you want to use object property name, use method `setDataAtRowProp`");d=u.colToProp(h[a][1]),f.push([h[a][0],d,c.getAtCell(w.toPhysicalRow(h[a][0]),h[a][1]),h[a][2]])}s||"object"!=typeof e||(s=t),p.runHooks("afterSetDataAtCell",f,s),n(f,s,function(){r(f,s)})},this.setDataAtRowProp=function(e,t,o,s){var a,l,u=i(e,t,o),d=[];for(a=0,l=u.length;a<l;a++)d.push([u[a][0],u[a][1],c.getAtCell(w.toPhysicalRow(u[a][0]),u[a][1]),u[a][2]]);s||"object"!=typeof e||(s=t),p.runHooks("afterSetDataAtRowProp",d,s),n(d,s,function(){r(d,s)})},this.listen=function(){E.activeGuid=p.guid},this.unlisten=function(){E.activeGuid=null},this.isListening=function(){return E.activeGuid===p.guid},this.destroyEditor=function(e){h.refreshBorders(e)},this.populateFromArray=function(e,t,o,n,r,i,s,a,l){var u;if("object"!=typeof o||"object"!=typeof o[0])throw new Error("populateFromArray parameter `input` must be an array of arrays");return u="number"==typeof n?new ce(n,r):null,d.populateFromArray(new ce(e,t),o,u,i,s,a,l)},this.spliceCol=function(e,t,o){return u.spliceCol.apply(u,arguments)},this.spliceRow=function(e,t,o){return u.spliceRow.apply(u,arguments)},this.getSelected=function(){if(h.isSelected())return[l.selRange.from.row,l.selRange.from.col,l.selRange.to.row,l.selRange.to.col]},this.getSelectedRange=function(){if(h.isSelected())return l.selRange},this.render=function(){p.view&&(p.renderCall=!0,p.forceFullRender=!0,h.refreshBorders(null,!0))},this.loadData=function(e){if(Array.isArray(l.settings.dataSchema)?p.dataType="array":P(l.settings.dataSchema)?p.dataType="function":p.dataType="object",u&&u.destroy(),u=new j(p,l,g),"object"==typeof e&&null!==e)e.push&&e.splice||(e=[e]);else{if(null!==e)throw new Error("loadData only accepts array of objects or array of arrays ("+typeof e+" given)");e=[];var t,o=0,n=0,r=u.getSchema();for(o=0,n=l.settings.startRows;o<n;o++)if("object"!==p.dataType&&"function"!==p.dataType||!l.settings.dataSchema)if("array"===p.dataType)t=z(r[0]),e.push(t);else{t=[];for(var i=0,s=l.settings.startCols;i<s;i++)t.push(null);e.push(t)}else t=z(r),e.push(t)}l.isPopulated=!1,g.prototype.data=e,Array.isArray(e[0])&&(p.dataType="array"),u.dataSource=e,c.data=e,c.dataType=p.dataType,c.colToProp=u.colToProp.bind(u),c.propToCol=u.propToCol.bind(u),function(){l.cellSettings.length=0}(),d.adjustRowsAndCols(),E.hooks.run(p,"afterLoadData",l.firstRun),l.firstRun?l.firstRun=[null,"loadData"]:(E.hooks.run(p,"afterChange",null,"loadData"),p.render()),l.isPopulated=!0},this.getData=function(e,t,o,n){return I(e)?u.getAll():u.getRange(new ce(e,t),new ce(o,n),u.DESTINATION_RENDERER)},this.getCopyableText=function(e,t,o,n){return u.getCopyableText(new ce(e,t),new ce(o,n))},this.getCopyableData=function(e,t){return u.getCopyable(e,u.colToProp(t))},this.getSchema=function(){return u.getSchema()},this.updateSettings=function(e,t){var o,n,r,i=!1;if(N(e.rows))throw new Error('"rows" setting is no longer supported. do you mean startRows, minRows or maxRows?');if(N(e.cols))throw new Error('"cols" setting is no longer supported. do you mean startCols, minCols or maxCols?');for(o in e)"data"!==o&&(E.hooks.getRegistered().indexOf(o)>-1?(P(e[o])||Array.isArray(e[o]))&&(e[o].initialHook=!0,p.addHook(o,e[o])):!t&&e.hasOwnProperty(o)&&(g.prototype[o]=e[o]));void 0===e.data&&void 0===l.settings.data?p.loadData(null):void 0!==e.data?p.loadData(e.data):void 0!==e.columns&&u.createMap(),r=p.countCols();var a=e.columns||g.prototype.columns;if(a&&P(a)&&(r=p.countSourceCols(),i=!0),void 0===e.cell&&void 0===e.cells&&void 0===e.columns||(l.cellSettings.length=0),r>0){var c,f;for(o=0,n=0;o<r;o++)i&&!a(o)||(l.columnSettings[n]=A(g,l.columnsSettingConflicts),c=l.columnSettings[n].prototype,a&&(f=i?a(o):a[n])&&(U(c,f),U(c,s(f))),n++)}if(N(e.cell))for(var m in e.cell)if(e.cell.hasOwnProperty(m)){var w=e.cell[m];p.setCellMetaObject(w.row,w.col,w)}E.hooks.run(p,"afterCellMetaReset"),N(e.className)&&(g.prototype.className&&D(p.rootElement,g.prototype.className),e.className&&k(p.rootElement,e.className));var v=p.rootElement.style.height;""!==v&&(v=parseInt(p.rootElement.style.height,10));var y=e.height;if(P(y)&&(y=y()),t){p.rootElement.getAttribute("style")&&p.rootElement.setAttribute("data-initialstyle",p.rootElement.getAttribute("style"))}if(null===y){var b=p.rootElement.getAttribute("data-initialstyle");b&&(b.indexOf("height")>-1||b.indexOf("overflow")>-1)?p.rootElement.setAttribute("style",b):(p.rootElement.style.height="",p.rootElement.style.overflow="")}else void 0!==y&&(p.rootElement.style.height=y+"px",p.rootElement.style.overflow="hidden");if(void 0!==e.width){var C=e.width;P(C)&&(C=C()),p.rootElement.style.width=C+"px"}t||(u.clearLengthCache(),p.view&&p.view.wt.wtViewport.resetHasOversizedColumnHeadersMarked(),E.hooks.run(p,"afterUpdateSettings")),d.adjustRowsAndCols(),p.view&&!l.firstRun&&(p.forceFullRender=!0,h.refreshBorders(null,!0)),t||!p.view||""!==v&&""!==y&&void 0!==y||v===y||p.view.wt.wtOverlays.updateMainScrollableElements()},this.getValue=function(){var e=p.getSelected();if(g.prototype.getValue){if(P(g.prototype.getValue))return g.prototype.getValue.call(p);if(e)return p.getData()[e[0]][g.prototype.getValue]}else if(e)return p.getDataAtCell(e[0],e[1])},this.getSettings=function(){return l.settings},this.clear=function(){h.selectAll(),h.empty()},this.alter=function(e,t,o,n,r){
31
- d.alter(e,t,o,n,r)},this.getCell=function(e,t,o){return p.view.getCellAtCoords(new ce(e,t),o)},this.getCoords=function(e){return this.view.wt.wtTable.getCoords.call(this.view.wt.wtTable,e)},this.colToProp=function(e){return u.colToProp(e)},this.propToCol=function(e){return u.propToCol(e)},this.toVisualRow=function(e){return w.toVisualRow(e)},this.toVisualColumn=function(e){return w.toVisualColumn(e)},this.toPhysicalRow=function(e){return w.toPhysicalRow(e)},this.toPhysicalColumn=function(e){return w.toPhysicalColumn(e)},this.getDataAtCell=function(e,t){return u.get(e,u.colToProp(t))},this.getDataAtRowProp=function(e,t){return u.get(e,t)},this.getDataAtCol=function(e){var t=[];return t.concat.apply(t,u.getRange(new ce(0,e),new ce(l.settings.data.length-1,e),u.DESTINATION_RENDERER))},this.getDataAtProp=function(e){var t,o=[];return t=u.getRange(new ce(0,u.propToCol(e)),new ce(l.settings.data.length-1,u.propToCol(e)),u.DESTINATION_RENDERER),o.concat.apply(o,t)},this.getSourceData=function(e,t,o,n){return void 0===e?c.getData():c.getByRange(new ce(e,t),new ce(o,n))},this.getSourceDataArray=function(e,t,o,n){return void 0===e?c.getData(!0):c.getByRange(new ce(e,t),new ce(o,n),!0)},this.getSourceDataAtCol=function(e){return c.getAtColumn(e)},this.getSourceDataAtRow=function(e){return c.getAtRow(e)},this.getSourceDataAtCell=function(e,t){return c.getAtCell(e,t)},this.getDataAtRow=function(e){return u.getRange(new ce(e,0),new ce(e,this.countCols()-1),u.DESTINATION_RENDERER)[0]},this.getDataType=function(e,t,o,n){var r=this,i=null,s=null;void 0===e&&(e=0,o=this.countRows(),t=0,n=this.countCols()),void 0===o&&(o=e),void 0===n&&(n=t);var a="mixed";return oe(Math.min(e,o),Math.max(e,o),function(e){var o=!0;return oe(Math.min(t,n),Math.max(t,n),function(t){return s=r.getCellMeta(e,t).type,i?o=i===s:i=s,o}),a=o?s:"mixed",o}),a},this.removeCellMeta=function(e,t,o){void 0!=p.getCellMeta(e,t)[o]&&delete l.cellSettings[e][t][o]},this.spliceCellsMeta=function(e,t){for(var o,n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];(o=l.cellSettings).splice.apply(o,$traceurRuntime.spread([e,t],n))},this.setCellMetaObject=function(e,t,o){if("object"==typeof o)for(var n in o)if(o.hasOwnProperty(n)){var r=o[n];this.setCellMeta(e,t,n,r)}},this.setCellMeta=function(e,t,o,n){var r;r=w.toPhysical(e,t),e=r[0],t=r[1],l.cellSettings[e]||(l.cellSettings[e]=[]),l.cellSettings[e][t]||(l.cellSettings[e][t]=new l.columnSettings[t]),l.cellSettings[e][t][o]=n,E.hooks.run(p,"afterSetCellMeta",e,t,o,n)},this.getCellsMeta=function(){return Z(l.cellSettings)},this.getCellMeta=function(e,t){var o,n,r=u.colToProp(t),i=e,a=t;if(o=w.toPhysical(e,t),e=o[0],t=o[1],l.columnSettings[t]||(l.columnSettings[t]=A(g,l.columnsSettingConflicts)),l.cellSettings[e]||(l.cellSettings[e]=[]),l.cellSettings[e][t]||(l.cellSettings[e][t]=new l.columnSettings[t]),n=l.cellSettings[e][t],n.row=e,n.col=t,n.visualRow=i,n.visualCol=a,n.prop=r,n.instance=p,E.hooks.run(p,"beforeGetCellMeta",e,t,n),U(n,s(n)),n.cells){var c=n.cells.call(n,e,t,r);c&&(U(n,c),U(n,s(c)))}return E.hooks.run(p,"afterGetCellMeta",e,t,n),n},this.getCellMetaAtRow=function(e){return l.cellSettings[e]},this.isColumnModificationAllowed=function(){return!("object"===p.dataType||p.getSettings().columns)};var v=ae("renderer");this.getCellRenderer=function(e,t){return ee(v.call(this,e,t))},this.getCellEditor=ae("editor"),this.getCellValidator=ae("validator"),this.validateCells=function(e){var t=new o;e&&(t.onQueueEmpty=e);for(var n=p.countRows()-1;n>=0;){for(var r=p.countCols()-1;r>=0;)t.addValidatorToQueue(),p.validateCell(p.getDataAtCell(n,r),p.getCellMeta(n,r),function(e){if("boolean"!=typeof e)throw new Error("Validation error: result is not boolean");e===!1&&(t.valid=!1),t.removeValidatorFormQueue()},"validateCells"),r--;n--}t.checkIfQueueIsEmpty()},this.getRowHeader=function(e){var t=l.settings.rowHeaders;return void 0!==e&&(e=E.hooks.run(p,"modifyRowHeader",e)),void 0===e?(t=[],oe(p.countRows()-1,function(e){t.push(p.getRowHeader(e))})):Array.isArray(t)&&void 0!==t[e]?t=t[e]:P(t)?t=t(e):t&&"string"!=typeof t&&"number"!=typeof t&&(t=e+1),t},this.hasRowHeaders=function(){return!!l.settings.rowHeaders},this.hasColHeaders=function(){if(void 0!==l.settings.colHeaders&&null!==l.settings.colHeaders)return!!l.settings.colHeaders;for(var e=0,t=p.countCols();e<t;e++)if(p.getColHeader(e))return!0;return!1},this.getColHeader=function(e){var t=l.settings.columns&&P(l.settings.columns),o=l.settings.colHeaders;if(void 0===(e=E.hooks.run(p,"modifyColHeader",e))){for(var n=[],r=t?p.countSourceCols():p.countCols(),i=0;i<r;i++)n.push(p.getColHeader(i));o=n}else{var s=e;e=E.hooks.run(p,"modifyCol",e);var a=function(e){for(var t=[],o=p.countSourceCols(),n=0;n<o;n++)P(p.getSettings().columns)&&p.getSettings().columns(n)&&t.push(n);return t[e]}(e);l.settings.columns&&P(l.settings.columns)&&l.settings.columns(a)&&l.settings.columns(a).title?o=l.settings.columns(a).title:l.settings.columns&&l.settings.columns[e]&&l.settings.columns[e].title?o=l.settings.columns[e].title:Array.isArray(l.settings.colHeaders)&&void 0!==l.settings.colHeaders[e]?o=l.settings.colHeaders[e]:P(l.settings.colHeaders)?o=l.settings.colHeaders(e):l.settings.colHeaders&&"string"!=typeof l.settings.colHeaders&&"number"!=typeof l.settings.colHeaders&&(o=le(s))}return o},this._getColWidthFromSettings=function(e){var t=p.getCellMeta(0,e),o=t.width;if(void 0!==o&&o!==l.settings.width||(o=t.colWidths),void 0!==o&&null!==o){switch(typeof o){case"object":o=o[e];break;case"function":o=o(e)}"string"==typeof o&&(o=parseInt(o,10))}return o},this.getColWidth=function(e){var t=p._getColWidthFromSettings(e);return t=E.hooks.run(p,"modifyColWidth",t,e),void 0===t&&(t=he.DEFAULT_WIDTH),t},this._getRowHeightFromSettings=function(e){var t=l.settings.rowHeights;if(void 0!==t&&null!==t){switch(typeof t){case"object":t=t[e];break;case"function":t=t(e)}"string"==typeof t&&(t=parseInt(t,10))}return t},this.getRowHeight=function(e){var t=p._getRowHeightFromSettings(e);return t=E.hooks.run(p,"modifyRowHeight",t,e)},this.countSourceRows=function(){return E.hooks.run(p,"modifySourceLength")||(p.getSourceData()?p.getSourceData().length:0)},this.countSourceCols=function(){var e=p.getSourceData()&&p.getSourceData()[0]?p.getSourceData()[0]:[];return G(e)?K(e):e.length||0},this.countRows=function(){return u.getLength()},this.countCols=function(){var e=!1,t=0;if("array"===p.dataType&&(e=l.settings.data&&l.settings.data[0]&&l.settings.data[0].length),e&&(t=l.settings.data[0].length),l.settings.columns){if(P(l.settings.columns))if("array"===p.dataType){for(var o=0,n=0;n<t;n++)l.settings.columns(n)&&o++;t=o}else"object"!==p.dataType&&"function"!==p.dataType||(t=u.colToPropCache.length);else t=l.settings.columns.length}else"object"!==p.dataType&&"function"!==p.dataType||(t=u.colToPropCache.length);return t},this.rowOffset=function(){return p.view.wt.wtTable.getFirstRenderedRow()},this.colOffset=function(){return p.view.wt.wtTable.getFirstRenderedColumn()},this.countRenderedRows=function(){return p.view.wt.drawn?p.view.wt.wtTable.getRenderedRowsCount():-1},this.countVisibleRows=function(){return p.view.wt.drawn?p.view.wt.wtTable.getVisibleRowsCount():-1},this.countRenderedCols=function(){return p.view.wt.drawn?p.view.wt.wtTable.getRenderedColumnsCount():-1},this.countVisibleCols=function(){return p.view.wt.drawn?p.view.wt.wtTable.getVisibleColumnsCount():-1},this.countEmptyRows=function(e){for(var t,o=p.countRows()-1,n=0;o>=0;){if(t=E.hooks.run(this,"modifyRow",o),p.isEmptyRow(t))n++;else if(e)break;o--}return n},this.countEmptyCols=function(e){if(p.countRows()<1)return 0;for(var t=p.countCols()-1,o=0;t>=0;){if(p.isEmptyCol(t))o++;else if(e)break;t--}return o},this.isEmptyRow=function(e){return l.settings.isEmptyRow.call(p,e)},this.isEmptyCol=function(e){return l.settings.isEmptyCol.call(p,e)},this.selectCell=function(e,t,o,n,r,i){var s;if(i=I(i)||i===!0,"number"!=typeof e||e<0||e>=p.countRows())return!1;if("number"!=typeof t||t<0||t>=p.countCols())return!1;if(N(o)){if("number"!=typeof o||o<0||o>=p.countRows())return!1;if("number"!=typeof n||n<0||n>=p.countCols())return!1}return s=new ce(e,t),l.selRange=new de(s,s,s),i&&p.listen(),I(o)?h.setRangeEnd(l.selRange.from,r):h.setRangeEnd(new ce(o,n),r),p.selection.finish(),!0},this.selectCellByProp=function(e,t,o,n,r){return arguments[1]=u.propToCol(arguments[1]),N(arguments[3])&&(arguments[3]=u.propToCol(arguments[3])),p.selectCell.apply(p,arguments)},this.deselectCell=function(){h.deselect()},this.scrollViewportTo=function(e,t){var o=void 0!==arguments[2]&&arguments[2],n=void 0!==arguments[3]&&arguments[3];if(void 0!==e&&(e<0||e>=p.countRows()))return!1;if(void 0!==t&&(t<0||t>=p.countCols()))return!1;var r=!1;return void 0!==e&&void 0!==t&&(p.view.wt.wtOverlays.topOverlay.scrollTo(e,o),p.view.wt.wtOverlays.leftOverlay.scrollTo(t,n),r=!0),"number"==typeof e&&"number"!=typeof t&&(p.view.wt.wtOverlays.topOverlay.scrollTo(e,o),r=!0),"number"==typeof t&&"number"!=typeof e&&(p.view.wt.wtOverlays.leftOverlay.scrollTo(t,n),r=!0),r},this.destroy=function(){p._clearTimeouts(),p.view&&p.view.destroy(),c&&c.destroy(),c=null,x(p.rootElement),m.destroy(),E.hooks.run(p,"afterDestroy"),E.hooks.destroy(p);for(var e in p)p.hasOwnProperty(e)&&(P(p[e])?p[e]=a:"guid"!==e&&(p[e]=null));u&&u.destroy(),u=null,l=null,d=null,h=null,f=null,p=null,g=null},this.getActiveEditor=function(){return f.getActiveEditor()},this.getPlugin=function(e){return Q(this,e)},this.getInstance=function(){return p},this.addHook=function(e,t){E.hooks.add(e,t,p)},this.hasHook=function(e){return E.hooks.has(e,p)},this.addHookOnce=function(e,t){E.hooks.once(e,t,p)},this.removeHook=function(e,t){E.hooks.remove(e,t,p)},this.runHooks=function(e,t,o,n,r,i,s){return E.hooks.run(p,e,t,o,n,r,i,s)},this.timeouts=[],this._registerTimeout=function(e){this.timeouts.push(e)},this._clearTimeouts=function(){for(var e=0,t=this.timeouts.length;e<t;e++)clearTimeout(this.timeouts[e])},this.version=E.version,E.hooks.run(p,"construct")};var fe=function(){};fe.prototype={data:void 0,dataSchema:void 0,width:void 0,height:void 0,startRows:5,startCols:5,rowHeaders:void 0,colHeaders:null,colWidths:void 0,rowHeights:void 0,columns:void 0,cells:void 0,cell:[],comments:!1,customBorders:!1,minRows:0,minCols:0,maxRows:1/0,maxCols:1/0,minSpareRows:0,minSpareCols:0,allowInsertRow:!0,allowInsertColumn:!0,allowRemoveRow:!0,allowRemoveColumn:!0,multiSelect:!0,fillHandle:!0,fixedRowsTop:0,fixedRowsBottom:0,fixedColumnsLeft:0,outsideClickDeselects:!0,enterBeginsEditing:!0,enterMoves:{row:1,col:0},tabMoves:{row:0,col:1},autoWrapRow:!1,autoWrapCol:!1,copyRowsLimit:1e3,copyColsLimit:1e3,pasteMode:"overwrite",persistentState:void 0,currentRowClassName:void 0,currentColClassName:void 0,currentHeaderClassName:"ht__highlight",className:void 0,tableClassName:void 0,stretchH:"none",isEmptyRow:function(e){var t,o,n,r;for(t=0,o=this.countCols();t<o;t++)if(""!==(n=this.getDataAtCell(e,t))&&null!==n&&N(n))return"object"==typeof n&&(r=this.getCellMeta(e,t),$(this.getSchema()[r.prop],n));return!0},isEmptyCol:function(e){var t,o,n;for(t=0,o=this.countRows();t<o;t++)if(""!==(n=this.getDataAtCell(t,e))&&null!==n&&N(n))return!1;return!0},observeDOMVisibility:!0,allowInvalid:!0,allowEmpty:!0,invalidCellClassName:"htInvalid",placeholder:!1,placeholderCellClassName:"htPlaceholder",readOnlyCellClassName:"htDimmed",renderer:void 0,commentedCellClassName:"htCommentCell",fragmentSelection:!1,readOnly:!1,skipColumnOnPaste:!1,search:!1,type:"text",copyable:!0,editor:void 0,autoComplete:void 0,visibleRows:10,trimDropdown:!0,debug:!1,wordWrap:!0,noWordWrapClassName:"htNoWrap",contextMenu:void 0,contextMenuCopyPaste:void 0,copyPaste:void 0,undo:void 0,columnSorting:void 0,manualColumnMove:void 0,manualColumnResize:void 0,manualRowMove:void 0,manualRowResize:void 0,mergeCells:!1,viewportRowRenderingOffset:"auto",viewportColumnRenderingOffset:"auto",validator:void 0,disableVisualSelection:!1,sortIndicator:void 0,manualColumnFreeze:void 0,trimWhitespace:!0,settings:void 0,source:void 0,title:void 0,checkedTemplate:void 0,uncheckedTemplate:void 0,label:void 0,format:void 0,language:void 0,selectOptions:void 0,autoColumnSize:void 0,autoRowSize:void 0,dateFormat:void 0,correctFormat:!1,defaultDate:void 0,strict:void 0,allowHtml:!1,renderAllRows:void 0,preventOverflow:!1,bindRowsWithHeaders:void 0,collapsibleColumns:void 0,columnSummary:void 0,dropdownMenu:void 0,filters:void 0,formulas:void 0,ganttChart:void 0,headerTooltips:void 0,hiddenColumns:void 0,hiddenRows:void 0,nestedHeaders:void 0,trimRows:void 0,rowHeaderWidth:void 0,columnHeaderHeight:void 0,observeChanges:void 0,sortFunction:void 0,sortByRelevance:!0,filter:!0,filteringCaseSensitive:!1},E.DefaultSettings=fe},{"3rdparty/walkontable/src/calculator/viewportColumns":4,"3rdparty/walkontable/src/cell/coords":6,"3rdparty/walkontable/src/cell/range":7,browser:24,dataMap:27,dataSource:28,editorManager:29,eventManager:42,"helpers/array":43,"helpers/browser":44,"helpers/data":45,"helpers/dom/element":47,"helpers/function":50,"helpers/mixed":51,"helpers/number":52,"helpers/object":53,"helpers/setting":54,"helpers/string":55,numbro:"numbro",plugins:61,renderers:117,tableView:126,"utils/recordTranslator":130}],27:[function(e,t,o){"use strict";function n(e,t,o){var n=this;this.instance=e,this.priv=t,this.GridSettings=o,this.dataSource=this.instance.getSettings().data,this.cachedLength=null,this.skipCache=!1,this.latestSourceRowsCount=0,this.dataSource&&this.dataSource[0]?this.duckSchema=this.recursiveDuckSchema(this.dataSource[0]):this.duckSchema={},this.createMap(),this.interval=O.create(function(){return n.clearLengthCache()},"15fps"),this.instance.addHook("skipLengthCache",function(e){return n.onSkipLengthCache(e)})}Object.defineProperties(o,{DataMap:{get:function(){return n}},__esModule:{value:!0}});var r,i,s,a,l,u,c,d,h,f=((r=e("browser"))&&r.__esModule&&r||{default:r}).default,p=((i=e("SheetClip"))&&i.__esModule&&i||{default:i}).default,g=((s=e("helpers/data"))&&s.__esModule&&s||{default:s}).cellMethodLookupFactory,m=((a=e("helpers/setting"))&&a.__esModule&&a||{default:a}).columnFactory,w=(l=e("helpers/object"))&&l.__esModule&&l||{default:l},v=w.createObjectPropListener,y=w.duckSchema,b=w.deepExtend,C=w.deepClone,_=w.isObject,R=w.deepObjectSize,M=(u=e("helpers/array"))&&u.__esModule&&u||{default:u},S=M.extendArray,E=M.to2dArray,O=((c=e("utils/interval"))&&c.__esModule&&c||{default:c}).Interval,T=((d=e("helpers/number"))&&d.__esModule&&d||{default:d}).rangeEach,k=((h=e("multiMap"))&&h.__esModule&&h||{default:h}).MultiMap;n.prototype.DESTINATION_RENDERER=1,n.prototype.DESTINATION_CLIPBOARD_GENERATOR=2,n.prototype.recursiveDuckSchema=function(e){return y(e)},n.prototype.recursiveDuckColumns=function(e,t,o){var n,r;if(void 0===t&&(t=0,o=""),"object"==typeof e&&!Array.isArray(e))for(r in e)e.hasOwnProperty(r)&&(null===e[r]?(n=o+r,this.colToPropCache.push(n),this.propToColCache.set(n,t),t++):t=this.recursiveDuckColumns(e[r],t,r+"."));return t},n.prototype.createMap=function(){var e,t=this.getSchema();if(void 0===t)throw new Error("trying to create `columns` definition but you didn't provide `schema` nor `data`");this.colToPropCache=[],this.propToColCache=new k;var o=this.instance.getSettings().columns;if(o){var n=o.length,r=0,i=!1,s=R(t);for("function"==typeof o&&(n=s>0?s:this.instance.countSourceCols(),i=!0),e=0;e<n;e++){var a=i?o(e):o[e];if(_(a)){if(void 0!==a.data){var l=i?r:e;this.colToPropCache[l]=a.data,this.propToColCache.set(a.data,l)}r++}}}else this.recursiveDuckColumns(t)},n.prototype.colToProp=function(e){return e=f.hooks.run(this.instance,"modifyCol",e),this.colToPropCache&&void 0!==this.colToPropCache[e]?this.colToPropCache[e]:e},n.prototype.propToCol=function(e){var t;return t=void 0===this.propToColCache.get(e)?e:this.propToColCache.get(e),t=f.hooks.run(this.instance,"unmodifyCol",t)},n.prototype.getSchema=function(){var e=this.instance.getSettings().dataSchema;return e?"function"==typeof e?e():e:this.duckSchema},n.prototype.createRow=function(e,t,o){var n,r,i=this.instance.countCols(),s=0;t||(t=1),("number"!=typeof e||e>=this.instance.countSourceRows())&&(e=this.instance.countSourceRows()),f.hooks.run(this.instance,"beforeCreateRow",e,t,o),r=e;for(var a=this.instance.getSettings().maxRows;s<t&&this.instance.countSourceRows()<a;)"array"===this.instance.dataType?this.instance.getSettings().dataSchema?n=C(this.getSchema()):(n=[],T(i-1,function(){return n.push(null)})):"function"===this.instance.dataType?n=this.instance.getSettings().dataSchema(e):(n={},b(n,this.getSchema())),e===this.instance.countSourceRows()?this.dataSource.push(n):this.spliceData(e,0,n),s++,r++;return f.hooks.run(this.instance,"afterCreateRow",e,s,o),this.instance.forceFullRender=!0,s},n.prototype.createCol=function(e,t,o){if(!this.instance.isColumnModificationAllowed())throw new Error("Cannot create new column. When data source in an object, you can only have as much columns as defined in first data row, data schema or in the 'columns' setting.If you want to be able to add new columns, you have to use array datasource.");var n,r,i=this.instance.countSourceRows(),s=this.dataSource,a=0;t||(t=1),("number"!=typeof e||e>=this.instance.countCols())&&(e=this.instance.countCols()),f.hooks.run(this.instance,"beforeCreateCol",e,t,o),r=e;for(var l=this.instance.getSettings().maxCols;a<t&&this.instance.countCols()<l;){if(n=m(this.GridSettings,this.priv.columnsSettingConflicts),"number"!=typeof e||e>=this.instance.countCols()){if(i>0)for(var u=0;u<i;u++)void 0===s[u]&&(s[u]=[]),s[u].push(null);else s.push([null]);this.priv.columnSettings.push(n)}else{for(var u=0;u<i;u++)s[u].splice(r,0,null);this.priv.columnSettings.splice(r,0,n)}a++,r++}return f.hooks.run(this.instance,"afterCreateCol",e,a,o),this.instance.forceFullRender=!0,a},n.prototype.removeRow=function(e,t,o){t||(t=1),"number"!=typeof e&&(e=-t),t=f.hooks.run(this.instance,"modifyRemovedAmount",t,e),e=(this.instance.countSourceRows()+e)%this.instance.countSourceRows();var n=this.physicalRowsToLogical(e,t);if(f.hooks.run(this.instance,"beforeRemoveRow",e,t,n,o)!==!1){var r,i=this.dataSource;r=this.filterData(e,t),r&&(i.length=0,Array.prototype.push.apply(i,r)),f.hooks.run(this.instance,"afterRemoveRow",e,t,n,o),this.instance.forceFullRender=!0}},n.prototype.removeCol=function(e,t,o){if("object"===this.instance.dataType||this.instance.getSettings().columns)throw new Error("cannot remove column with object data source or columns option specified");t||(t=1),"number"!=typeof e&&(e=-t),e=(this.instance.countCols()+e)%this.instance.countCols();var n=this.physicalColumnsToLogical(e,t),r=n.slice(0).sort(function(e,t){return t-e});if(f.hooks.run(this.instance,"beforeRemoveCol",e,t,n,o)!==!1){for(var i=!0,s=r.length,a=this.dataSource,l=0;l<s;l++)i&&n[0]!==n[l]-l&&(i=!1);if(i)for(var u=0,c=this.instance.countSourceRows();u<c;u++)a[u].splice(n[0],t);else{for(var d=0,h=this.instance.countSourceRows();d<h;d++)for(var p=0;p<s;p++)a[d].splice(r[p],1);for(var g=0;g<s;g++)this.priv.columnSettings.splice(n[g],1)}f.hooks.run(this.instance,"afterRemoveCol",e,t,n,o),this.instance.forceFullRender=!0}},n.prototype.spliceCol=function(e,t,o){var n=4<=arguments.length?[].slice.call(arguments,3):[],r=this.instance.getDataAtCol(e),i=r.slice(t,t+o);S(n,r.slice(t+o));for(var s=0;s<o;)n.push(null),s++;return E(n),this.instance.populateFromArray(t,e,n,null,null,"spliceCol"),i},n.prototype.spliceRow=function(e,t,o){var n=4<=arguments.length?[].slice.call(arguments,3):[],r=this.instance.getSourceDataAtRow(e),i=r.slice(t,t+o);S(n,r.slice(t+o));for(var s=0;s<o;)n.push(null),s++;return this.instance.populateFromArray(e,t,[n],null,null,"spliceRow"),i},n.prototype.spliceData=function(e,t,o){f.hooks.run(this.instance,"beforeDataSplice",e,t,o)!==!1&&this.dataSource.splice(e,t,o)},n.prototype.filterData=function(e,t){var o=this.physicalRowsToLogical(e,t);if(f.hooks.run(this.instance,"beforeDataFilter",e,t,o)!==!1)return this.dataSource.filter(function(e,t){return o.indexOf(t)==-1})},n.prototype.get=function(e,t){e=f.hooks.run(this.instance,"modifyRow",e);var o=this.dataSource[e],n=f.hooks.run(this.instance,"modifyRowData",e);o=isNaN(n)?n:o;var r=null;if(o&&o.hasOwnProperty&&o.hasOwnProperty(t))r=o[t];else if("string"==typeof t&&t.indexOf(".")>-1){var i=t.split("."),s=o;if(!s)return null;for(var a=0,l=i.length;a<l;a++)if(void 0===(s=s[i[a]]))return null;r=s}else"function"==typeof t&&(r=t(this.dataSource.slice(e,e+1)[0]));if(f.hooks.has("modifyData",this.instance)){var u=v(r);f.hooks.run(this.instance,"modifyData",e,this.propToCol(t),u,"get"),u.isTouched()&&(r=u.value)}return r};var x=g("copyable",!1);n.prototype.getCopyable=function(e,t){return x.call(this.instance,e,this.propToCol(t))?this.get(e,t):""},n.prototype.set=function(e,t,o,n){e=f.hooks.run(this.instance,"modifyRow",e,n||"datamapGet");var r=this.dataSource[e],i=f.hooks.run(this.instance,"modifyRowData",e);if(r=isNaN(i)?i:r,f.hooks.has("modifyData",this.instance)){var s=v(o);f.hooks.run(this.instance,"modifyData",e,this.propToCol(t),s,"set"),s.isTouched()&&(o=s.value)}if(r&&r.hasOwnProperty&&r.hasOwnProperty(t))r[t]=o;else if("string"==typeof t&&t.indexOf(".")>-1){for(var a=t.split("."),l=r,u=0,c=a.length-1;u<c;u++)void 0===l[a[u]]&&(l[a[u]]={}),l=l[a[u]];l[a[u]]=o}else"function"==typeof t?t(this.dataSource.slice(e,e+1)[0],o):r[t]=o},n.prototype.physicalRowsToLogical=function(e,t){for(var o,n=this.instance.countSourceRows(),r=(n+e)%n,i=[],s=t;r<n&&s;)o=f.hooks.run(this.instance,"modifyRow",r),i.push(o),s--,r++;return i},n.prototype.physicalColumnsToLogical=function(e,t){for(var o=this.instance.countCols(),n=(o+e)%o,r=[],i=t;n<o&&i;){var s=f.hooks.run(this.instance,"modifyCol",n);r.push(s),i--,n++}return r},n.prototype.clear=function(){for(var e=0;e<this.instance.countSourceRows();e++)for(var t=0;t<this.instance.countCols();t++)this.set(e,this.colToProp(t),"")},n.prototype.clearLengthCache=function(){this.cachedLength=null},n.prototype.getLength=function(){var e,t=this,o=this.instance.getSettings().maxRows;e=o<0||0===o?0:o||1/0;var n=this.instance.countSourceRows();if(f.hooks.has("modifyRow",this.instance)){var r=this.skipCache;this.interval.start(),n!==this.latestSourceRowsCount&&(r=!0),this.latestSourceRowsCount=n,null===this.cachedLength||r?(T(n-1,function(e){null===(e=f.hooks.run(t.instance,"modifyRow",e))&&--n}),this.cachedLength=n):n=this.cachedLength}else this.interval.stop();return Math.min(n,e)},n.prototype.getAll=function(){var e={row:0,col:0},t=this.instance.getSettings().maxRows;if(0===t)return[];var o={row:Math.min(Math.max(t-1,0),Math.max(this.instance.countSourceRows()-1,0)),col:Math.max(this.instance.countCols()-1,0)};return e.row-o.row!=0||this.instance.countSourceRows()?this.getRange(e,o,n.prototype.DESTINATION_RENDERER):[]},n.prototype.getRange=function(e,t,o){var n,r,i,s,a,l=[],u=o===this.DESTINATION_CLIPBOARD_GENERATOR?this.getCopyable:this.get;for(r=Math.max(e.row,t.row),s=Math.max(e.col,t.col),n=Math.min(e.row,t.row);n<=r;n++){a=[];var c=f.hooks.run(this.instance,"modifyRow",n);for(i=Math.min(e.col,t.col);i<=s&&null!==c;i++)a.push(u.call(this,n,this.colToProp(i)));null!==c&&l.push(a)}return l},n.prototype.getText=function(e,t){return p.stringify(this.getRange(e,t,this.DESTINATION_RENDERER))},n.prototype.getCopyableText=function(e,t){return p.stringify(this.getRange(e,t,this.DESTINATION_CLIPBOARD_GENERATOR))},n.prototype.onSkipLengthCache=function(e){var t=this;this.skipCache=!0,setTimeout(function(){t.skipCache=!1},e)},n.prototype.destroy=function(){this.interval.stop(),this.interval=null,this.instance=null,this.priv=null,this.GridSettings=null,this.dataSource=null,this.cachedLength=null,this.duckSchema=null}},{SheetClip:"SheetClip",browser:24,"helpers/array":43,"helpers/data":45,"helpers/number":52,"helpers/object":53,"helpers/setting":54,multiMap:59,"utils/interval":129}],28:[function(e,t,o){"use strict";Object.defineProperties(o,{DataSource:{get:function(){return u}},__esModule:{value:!0}});var n,r,i,s=((n=e("helpers/object"))&&n.__esModule&&n||{default:n}).getProperty,a=((r=e("helpers/array"))&&r.__esModule&&r||{default:r}).arrayEach,l=((i=e("helpers/number"))&&i.__esModule&&i||{default:i}).rangeEach,u=function(e){var t=void 0!==arguments[1]?arguments[1]:[];this.hot=e,this.data=t,this.dataType="array",this.colToProp=function(){},this.propToCol=function(){}};$traceurRuntime.createClass(u,{getData:function(){var e=void 0!==arguments[0]&&arguments[0],t=this.data;return e&&(t=this.getByRange({row:0,col:0},{row:Math.max(this.countRows()-1,0),col:Math.max(this.countColumns()-1,0)},!0)),t},setData:function(e){this.data=e},getAtColumn:function(e){var t=this,o=[];return a(this.data,function(n){var r=t.colToProp(e);n="string"==typeof r?s(n,r):n[r],o.push(n)}),o},getAtRow:function(e){return this.data[e]},getAtCell:function(e,t){var o=null,n=this.hot.runHooks("modifyRowData",e),r=isNaN(n)?n:this.data[e];if(r){var i=this.colToProp(t);o="string"==typeof i?s(r,i):"function"==typeof i?i(this.data.slice(e,e+1)[0]):r[i]}return o},getByRange:function(e,t){var o=void 0!==arguments[2]&&arguments[2],n=this,r=Math.min(e.row,t.row),i=Math.min(e.col,t.col),s=Math.max(e.row,t.row),a=Math.max(e.col,t.col),u=[];return l(r,s,function(e){var t,r=n.getAtRow(e);"array"===n.dataType?t=r.slice(i,a+1):"object"===n.dataType&&(t=o?[]:{},l(i,a,function(e){var i=n.colToProp(e);o?t.push(r[i]):t[i]=r[i]})),u.push(t)}),u},countRows:function(){return Array.isArray(this.data)?this.data.length:0},countColumns:function(){var e=0;return Array.isArray(this.data)&&("array"===this.dataType?e=this.data[0].length:"object"===this.dataType&&(e=Object.keys(this.data[0]).length)),e},destroy:function(){this.data=null,this.hot=null}},{})},{"helpers/array":43,"helpers/number":52,"helpers/object":53}],29:[function(e,t,o){"use strict";function n(e,t,o){function n(e){o.setSelectedHeaders(!1,!1,!1);var n="function"==typeof t.settings.enterMoves?t.settings.enterMoves(event):t.settings.enterMoves;e?o.transformStart(-n.row,-n.col):o.transformStart(n.row,n.col,!0)}function r(e){e?(o.selectedHeader.cols&&o.setSelectedHeaders(o.selectedHeader.rows,!1,!1),o.transformEnd(-1,0)):(o.setSelectedHeaders(!1,!1,!1),o.transformStart(-1,0))}function i(e){e?o.transformEnd(1,0):(o.setSelectedHeaders(!1,!1,!1),o.transformStart(1,0))}function s(e){e?o.transformEnd(0,1):(o.setSelectedHeaders(!1,!1,!1),o.transformStart(0,1))}function a(e){e?(o.selectedHeader.rows&&o.setSelectedHeaders(!1,o.selectedHeader.cols,!1),o.transformEnd(0,-1)):(o.setSelectedHeaders(!1,!1,!1),o.transformStart(0,-1))}function l(l){var u,b;if(e.isListening()&&(c.hooks.run(e,"beforeKeyDown",l),!C&&!y(l)&&(t.lastKeyCode=l.keyCode,o.isSelected()))){if(u=(l.ctrlKey||l.metaKey)&&!l.altKey,h&&!h.isWaiting()&&!(p(l.keyCode)||g(l.keyCode)||u||m.isEditorOpened()))return void m.openEditor("",l);switch(b=l.shiftKey?o.setRangeEnd:o.setRangeStart,l.keyCode){case f.A:!m.isEditorOpened()&&u&&(o.selectAll(),l.preventDefault(),w(l));break;case f.ARROW_UP:m.isEditorOpened()&&!h.isWaiting()&&m.closeEditorAndSaveChanges(u),r(l.shiftKey),l.preventDefault(),w(l);break;case f.ARROW_DOWN:m.isEditorOpened()&&!h.isWaiting()&&m.closeEditorAndSaveChanges(u),i(l.shiftKey),l.preventDefault(),w(l);break;case f.ARROW_RIGHT:m.isEditorOpened()&&!h.isWaiting()&&m.closeEditorAndSaveChanges(u),s(l.shiftKey),l.preventDefault(),w(l);break;case f.ARROW_LEFT:m.isEditorOpened()&&!h.isWaiting()&&m.closeEditorAndSaveChanges(u),a(l.shiftKey),l.preventDefault(),w(l);break;case f.TAB:o.setSelectedHeaders(!1,!1,!1);var _="function"==typeof t.settings.tabMoves?t.settings.tabMoves(l):t.settings.tabMoves;l.shiftKey?o.transformStart(-_.row,-_.col):o.transformStart(_.row,_.col,!0),l.preventDefault(),w(l);break;case f.BACKSPACE:case f.DELETE:o.empty(l),m.prepareEditor(),l.preventDefault();break;case f.F2:m.openEditor(null,l),h&&h.enableFullEditMode(),l.preventDefault();break;case f.ENTER:m.isEditorOpened()?(h&&h.state!==c.EditorState.WAITING&&m.closeEditorAndSaveChanges(u),n(l.shiftKey)):e.getSettings().enterBeginsEditing?(m.openEditor(null,l),h&&h.enableFullEditMode()):n(l.shiftKey),l.preventDefault(),v(l);break;case f.ESCAPE:m.isEditorOpened()&&m.closeEditorAndRestoreOriginalValue(u),l.preventDefault();break;case f.HOME:o.setSelectedHeaders(!1,!1,!1),b(l.ctrlKey||l.metaKey?new d(0,t.selRange.from.col):new d(t.selRange.from.row,0)),l.preventDefault(),w(l);break;case f.END:o.setSelectedHeaders(!1,!1,!1),b(l.ctrlKey||l.metaKey?new d(e.countRows()-1,t.selRange.from.col):new d(t.selRange.from.row,e.countCols()-1)),l.preventDefault(),w(l);break;case f.PAGE_UP:o.setSelectedHeaders(!1,!1,!1),o.transformStart(-e.countVisibleRows(),0),l.preventDefault(),w(l);break;case f.PAGE_DOWN:o.setSelectedHeaders(!1,!1,!1),o.transformStart(e.countVisibleRows(),0),l.preventDefault(),w(l)}}}var u,h,m=this,C=!1;u=b(e),this.destroyEditor=function(e){this.closeEditor(e)},this.getActiveEditor=function(){return h},this.prepareEditor=function(){var o,n,r,i,s,a,l;if(h&&h.isWaiting())return void this.closeEditor(!1,!1,function(e){e&&m.prepareEditor()});o=t.selRange.highlight.row,n=t.selRange.highlight.col,r=e.colToProp(n),i=e.getCell(o,n),s=e.getSourceDataAtCell(e.runHooks("modifyRow",o),n),a=e.getCellMeta(o,n),l=e.getCellEditor(a),l?(h=c.editors.getEditor(l,e),h.prepare(o,n,r,i,s,a)):h=void 0},this.isEditorOpened=function(){return h&&h.isOpened()},this.openEditor=function(e,t){h&&!h.cellProperties.readOnly?h.beginEditing(e,t):h&&h.cellProperties.readOnly&&t&&t.keyCode===f.ENTER&&n()},this.closeEditor=function(e,t,o){h?h.finishEditing(e,t,o):o&&o(!1)},this.closeEditorAndSaveChanges=function(e){return this.closeEditor(!1,e)},this.closeEditorAndRestoreOriginalValue=function(e){return this.closeEditor(!0,e)},function(){function t(e,t,o){"TD"==o.nodeName&&(m.openEditor(),h&&h.enableFullEditMode())}e.addHook("afterDocumentKeyDown",l),u.addEventListener(document.documentElement,"keydown",function(t){C||e.runHooks("afterDocumentKeyDown",t)}),e.view.wt.update("onCellDblClick",t),e.addHook("afterDestroy",function(){C=!0})}()}Object.defineProperties(o,{EditorManager:{get:function(){return n}},__esModule:{value:!0}});var r,i,s,a,l,u,c=((r=e("browser"))&&r.__esModule&&r||{default:r}).default,d=((i=e("3rdparty/walkontable/src/cell/coords"))&&i.__esModule&&i||{default:i}).WalkontableCellCoords,h=(s=e("helpers/unicode"))&&s.__esModule&&s||{default:s},f=h.KEY_CODES,p=h.isMetaKey,g=h.isCtrlKey,m=(a=e("helpers/dom/event"))&&a.__esModule&&a||{default:a},w=m.stopPropagation,v=m.stopImmediatePropagation,y=m.isImmediatePropagationStopped,b=(((l=e("editors"))&&l.__esModule&&l||{default:l}).getEditor,((u=e("eventManager"))&&u.__esModule&&u||{default:u}).eventManager);c.EditorManager=n},{"3rdparty/walkontable/src/cell/coords":6,browser:24,editors:30,eventManager:42,"helpers/dom/event":48,"helpers/unicode":56}],30:[function(e,t,o){"use strict";function n(e){var t,o;o={},t=e,this.getConstructor=function(){return e},this.getInstance=function(e){return e.guid in o||(o[e.guid]=new t(e)),o[e.guid]},c.hooks.add("afterDestroy",function(){o={}})}function r(e,t){var o=new n(t);"string"==typeof e&&(h[e]=o,c.editors[d(e)+"Editor"]=t),f.set(t,o)}function i(e,t){var o;if("function"==typeof e)f.get(e)||r(null,e),o=f.get(e);else{if("string"!=typeof e)throw Error('Only strings and functions can be passed as "editor" parameter ');o=h[e]}if(!o)throw Error('No editor registered under name "'+e+'"');return o.getInstance(t)}function s(e){var t;if("string"!=typeof e)throw Error('Only strings and functions can be passed as "editor" parameter ');if(!(t=h[e]))throw Error('No editor registered under name "'+e+'"');return t.getConstructor()}function a(e){return!!h[e]}Object.defineProperties(o,{registerEditor:{get:function(){return r}},getEditor:{get:function(){return i}},hasEditor:{get:function(){return a}},getEditorConstructor:{get:function(){return s}},__esModule:{value:!0}});var l,u,c=((l=e("browser"))&&l.__esModule&&l||{default:l
32
- }).default,d=((u=e("helpers/string"))&&u.__esModule&&u||{default:u}).toUpperCaseFirst,h={},f=new WeakMap;c.editors=c.editors||{},c.editors.registerEditor=r,c.editors.getEditor=i},{browser:24,"helpers/string":55}],31:[function(e,t,o){"use strict";function n(e){this.instance=e,this.state=a.EditorState.VIRGIN,this._opened=!1,this._fullEditMode=!1,this._closeCallback=null,this.init()}Object.defineProperties(o,{BaseEditor:{get:function(){return n}},__esModule:{value:!0}});var r,i,s,a=((r=e("browser"))&&r.__esModule&&r||{default:r}).default,l=((i=e("helpers/mixed"))&&i.__esModule&&i||{default:i}).stringify,u=((s=e("3rdparty/walkontable/src/cell/coords"))&&s.__esModule&&s||{default:s}).WalkontableCellCoords;a.editors=a.editors||{},a.editors.BaseEditor=n,a.EditorState={VIRGIN:"STATE_VIRGIN",EDITING:"STATE_EDITING",WAITING:"STATE_WAITING",FINISHED:"STATE_FINISHED"},n.prototype._fireCallbacks=function(e){this._closeCallback&&(this._closeCallback(e),this._closeCallback=null)},n.prototype.init=function(){},n.prototype.getValue=function(){throw Error("Editor getValue() method unimplemented")},n.prototype.setValue=function(e){throw Error("Editor setValue() method unimplemented")},n.prototype.open=function(){throw Error("Editor open() method unimplemented")},n.prototype.close=function(){throw Error("Editor close() method unimplemented")},n.prototype.prepare=function(e,t,o,n,r,i){this.TD=n,this.row=e,this.col=t,this.prop=o,this.originalValue=r,this.cellProperties=i;var s=!document.activeElement||document.activeElement&&void 0===document.activeElement.nodeName;this.instance.view.isMouseDown()&&document.activeElement&&document.activeElement!==document.body&&!s?document.activeElement.blur():s&&document.body.focus(),this.state=a.EditorState.VIRGIN},n.prototype.extend=function(){function e(){t.apply(this,arguments)}var t=this.constructor;return function(e,t){function o(){}return o.prototype=t.prototype,e.prototype=new o,e.prototype.constructor=e,e}(e,t)},n.prototype.saveValue=function(e,t){var o,n;t?(o=this.instance.getSelected(),o[0]>o[2]&&(n=o[0],o[0]=o[2],o[2]=n),o[1]>o[3]&&(n=o[1],o[1]=o[3],o[3]=n)):o=[this.row,this.col,null,null],this.instance.populateFromArray(o[0],o[1],e,o[2],o[3],"edit")},n.prototype.beginEditing=function(e,t){this.state==a.EditorState.VIRGIN&&(this.instance.view.scrollViewport(new u(this.row,this.col)),this.instance.view.render(),this.state=a.EditorState.EDITING,e="string"==typeof e?e:this.originalValue,this.setValue(l(e)),this.open(t),this._opened=!0,this.focus(),this.instance.view.render(),this.instance.runHooks("afterBeginEditing",this.row,this.col))},n.prototype.finishEditing=function(e,t,o){var n,r=this;if(o){var i=this._closeCallback;this._closeCallback=function(e){i&&i(e),o(e),r.instance.view.render()}}if(!this.isWaiting()){if(this.state==a.EditorState.VIRGIN)return void this.instance._registerTimeout(setTimeout(function(){r._fireCallbacks(!0)},0));if(this.state==a.EditorState.EDITING){if(e)return this.cancelChanges(),void this.instance.view.render();var s=this.getValue();n=this.instance.getSettings().trimWhitespace?[["string"==typeof s?String.prototype.trim.call(s||""):s]]:[[s]],this.state=a.EditorState.WAITING,this.saveValue(n,t),this.instance.getCellValidator(this.cellProperties)?this.instance.addHookOnce("postAfterValidate",function(e){r.state=a.EditorState.FINISHED,r.discardEditor(e)}):(this.state=a.EditorState.FINISHED,this.discardEditor(!0))}}},n.prototype.cancelChanges=function(){this.state=a.EditorState.FINISHED,this.discardEditor()},n.prototype.discardEditor=function(e){this.state===a.EditorState.FINISHED&&(e===!1&&this.cellProperties.allowInvalid!==!0?(this.instance.selectCell(this.row,this.col),this.focus(),this.state=a.EditorState.EDITING,this._fireCallbacks(!1)):(this.close(),this._opened=!1,this._fullEditMode=!1,this.state=a.EditorState.VIRGIN,this._fireCallbacks(!0)))},n.prototype.enableFullEditMode=function(){this._fullEditMode=!0},n.prototype.isInFullEditMode=function(){return this._fullEditMode},n.prototype.isOpened=function(){return this._opened},n.prototype.isWaiting=function(){return this.state===a.EditorState.WAITING},n.prototype.checkEditorSection=function(){var e=this.instance.countRows(),t="";return this.row<this.instance.getSettings().fixedRowsTop?t=this.col<this.instance.getSettings().fixedColumnsLeft?"top-left-corner":"top":this.instance.getSettings().fixedRowsBottom&&this.row>=e-this.instance.getSettings().fixedRowsBottom?t=this.col<this.instance.getSettings().fixedColumnsLeft?"bottom-left-corner":"bottom":this.col<this.instance.getSettings().fixedColumnsLeft&&(t="left"),t}},{"3rdparty/walkontable/src/cell/coords":6,browser:24,"helpers/mixed":51}],32:[function(e,t,o){"use strict";function n(e){D=!1;var t=this.getActiveEditor();if(f(e.keyCode)||e.keyCode===h.BACKSPACE||e.keyCode===h.DELETE||e.keyCode===h.INSERT){var o=0;if(e.keyCode===h.C&&(e.ctrlKey||e.metaKey))return;t.isOpened()||(o+=10),t.htEditor&&t.instance._registerTimeout(setTimeout(function(){t.queryChoices(t.TEXTAREA.value),D=!0},o))}}Object.defineProperties(o,{AutocompleteEditor:{get:function(){return H}},__esModule:{value:!0}});var r,i,s,a,l,u,c,d=(r=e("helpers/unicode"))&&r.__esModule&&r||{default:r},h=d.KEY_CODES,f=d.isPrintableChar,p=((i=e("helpers/mixed"))&&i.__esModule&&i||{default:i}).stringify,g=((s=e("helpers/string"))&&s.__esModule&&s||{default:s}).stripTags,m=(a=e("helpers/array"))&&a.__esModule&&a||{default:a},w=m.pivot,v=(m.arrayFilter,m.arrayMap),y=(l=e("helpers/dom/element"))&&l.__esModule&&l||{default:l},b=y.addClass,C=y.getCaretPosition,_=y.getScrollbarWidth,R=y.getSelectionEndPosition,M=y.outerWidth,S=y.outerHeight,E=y.offset,O=y.getTrimmingContainer,T=y.setCaretPosition,k=((u=e("editors"))&&u.__esModule&&u||{default:u}).registerEditor,x=((c=e("handsontableEditor"))&&c.__esModule&&c||{default:c}).HandsontableEditor,H=x.prototype.extend();H.prototype.init=function(){x.prototype.init.apply(this,arguments),this.query=null,this.choices=[]},H.prototype.createElements=function(){x.prototype.createElements.apply(this,arguments),b(this.htContainer,"autocompleteEditor"),b(this.htContainer,window.navigator.platform.indexOf("Mac")===-1?"":"htMacScroll")};var D=!1;H.prototype.prepare=function(){this.instance.addHook("beforeKeyDown",n),x.prototype.prepare.apply(this,arguments)},H.prototype.open=function(){this.TEXTAREA_PARENT.style.overflow="auto",x.prototype.open.apply(this,arguments),this.TEXTAREA_PARENT.style.overflow="";var e=this.htEditor.getInstance(),t=this,o=void 0===this.cellProperties.trimDropdown||this.cellProperties.trimDropdown;this.TEXTAREA.style.visibility="visible",this.focus(),e.updateSettings({colWidths:o?[M(this.TEXTAREA)-2]:void 0,width:o?M(this.TEXTAREA)+_()+2:void 0,afterRenderer:function(e,o,n,r,i,s){var a,l,u=t.cellProperties,c=u.filteringCaseSensitive,d=u.allowHtml;i=p(i),i&&!d&&(a=c===!0?i.indexOf(this.query):i.toLowerCase().indexOf(t.query.toLowerCase()))!==-1&&(l=i.substr(a,t.query.length),i=i.replace(l,"<strong>"+l+"</strong>")),e.innerHTML=i},autoColumnSize:!0,modifyColWidth:function(e,t){var n=this.getPlugin("autoColumnSize").widths;return n[t]&&(e=n[t]),o?e:e+15}}),this.htEditor.view.wt.wtTable.holder.parentNode.style["padding-right"]=_()+2+"px",D&&(D=!1),t.instance._registerTimeout(setTimeout(function(){t.queryChoices(t.TEXTAREA.value)},0))},H.prototype.close=function(){x.prototype.close.apply(this,arguments)},H.prototype.queryChoices=function(e){var t=this;this.query=e;var o=this.cellProperties,n=o.source,r=(o.filter,o.filteringCaseSensitive,o.allowHtml),i=function(e){return v(e,function(e){return g(e)})};"function"==typeof n?n.call(this.cellProperties,e,function(e){t.updateChoicesList(r?e:i(e))}):Array.isArray(n)?this.updateChoicesList(r?n:i(n)):this.updateChoicesList([])},H.prototype.updateChoicesList=function(e){var t=C(this.TEXTAREA),o=R(this.TEXTAREA),n=this.cellProperties.sortByRelevance,r=this.cellProperties.filter,i=null,s=null;n&&(i=H.sortByRelevance(this.getValue(),e,this.cellProperties.filteringCaseSensitive));var a=Array.isArray(i)?i.length:0;if(r===!1)a&&(s=i[0]);else{for(var l=[],u=0,c=e.length;u<c&&!(n&&a<=u);u++)a?l.push(e[i[u]]):l.push(e[u]);s=0,e=l}this.choices=e,this.htEditor.loadData(w([e])),this.updateDropdownHeight(),this.flipDropdownIfNeeded(),this.cellProperties.strict===!0&&this.highlightBestMatchingChoice(s),this.instance.listen(),this.TEXTAREA.focus(),T(this.TEXTAREA,t,t===o?void 0:o)},H.prototype.flipDropdownIfNeeded=function(){var e=E(this.TEXTAREA),t=S(this.TEXTAREA),o=this.getDropdownHeight(),n=O(this.instance.view.wt.wtTable.TABLE),r=n.scrollTop,i=S(this.instance.view.wt.wtTable.THEAD),s={row:0,col:0};n!==window&&(s=E(n));var a=e.top-s.top-i+r,l=n.scrollHeight-a-i-t,u=o>l&&a>l;return u?this.flipDropdown(o):this.unflipDropdown(),this.limitDropdownIfNeeded(u?a:l,o),u},H.prototype.limitDropdownIfNeeded=function(e,t){if(t>e){var o=0,n=0,r=0,i=null;do r=this.htEditor.getRowHeight(n)||this.htEditor.view.wt.wtSettings.settings.defaultRowHeight,o+=r,n++;while(o<e)i=o-r,this.htEditor.flipped&&(this.htEditor.rootElement.style.top=parseInt(this.htEditor.rootElement.style.top,10)+t-i+"px"),this.setDropdownHeight(o-r)}},H.prototype.flipDropdown=function(e){var t=this.htEditor.rootElement.style;t.position="absolute",t.top=-e+"px",this.htEditor.flipped=!0},H.prototype.unflipDropdown=function(){var e=this.htEditor.rootElement.style;"absolute"===e.position&&(e.position="",e.top=""),this.htEditor.flipped=void 0},H.prototype.updateDropdownHeight=function(){var e=this.htEditor.getColWidth(0)+_()+2,t=this.cellProperties.trimDropdown;this.htEditor.updateSettings({height:this.getDropdownHeight(),width:t?void 0:e}),this.htEditor.view.wt.wtTable.alignOverlaysWithTrimmingContainer()},H.prototype.setDropdownHeight=function(e){this.htEditor.updateSettings({height:e})},H.prototype.finishEditing=function(e){e||this.instance.removeHook("beforeKeyDown",n),x.prototype.finishEditing.apply(this,arguments)},H.prototype.highlightBestMatchingChoice=function(e){"number"==typeof e?this.htEditor.selectCell(e,0):this.htEditor.deselectCell()},H.sortByRelevance=function(e,t,o){var n,r,i,s,a=[],l=e.length,u=[],c=t.length;if(0===l){for(s=0;s<c;s++)u.push(s);return u}for(s=0;s<c;s++)n=g(p(t[s])),(r=o?n.indexOf(e):n.toLowerCase().indexOf(e.toLowerCase()))!=-1&&(i=n.length-r-l,a.push({baseIndex:s,index:r,charsLeft:i,value:n}));for(a.sort(function(e,t){return t.index===-1?-1:e.index===-1?1:e.index<t.index?-1:t.index<e.index?1:e.index===t.index?e.charsLeft<t.charsLeft?-1:e.charsLeft>t.charsLeft?1:0:void 0}),s=0,c=a.length;s<c;s++)u.push(a[s].baseIndex);return u},H.prototype.getDropdownHeight=function(){var e=this.htEditor.getInstance().getRowHeight(0)||23,t=this.cellProperties.visibleRows;return this.choices.length>=t?t*e:this.choices.length*e+8},H.prototype.allowKeyEventPropagation=function(e){var t={row:this.htEditor.getSelectedRange()?this.htEditor.getSelectedRange().from.row:-1},o=!1;return e===h.ARROW_DOWN&&t.row>0&&t.row<this.htEditor.countRows()-1&&(o=!0),e===h.ARROW_UP&&t.row>-1&&(o=!0),o},H.prototype.discardEditor=function(e){x.prototype.discardEditor.apply(this,arguments),this.instance.view.render()},k("autocomplete",H)},{editors:30,handsontableEditor:36,"helpers/array":43,"helpers/dom/element":47,"helpers/mixed":51,"helpers/string":55,"helpers/unicode":56}],33:[function(e,t,o){"use strict";Object.defineProperties(o,{CheckboxEditor:{get:function(){return u}},__esModule:{value:!0}});var n,r,i,s=((n=e("editors"))&&n.__esModule&&n||{default:n}).registerEditor,a=((r=e("_baseEditor"))&&r.__esModule&&r||{default:r}).BaseEditor,l=((i=e("helpers/dom/element"))&&i.__esModule&&i||{default:i}).hasClass,u=function(){$traceurRuntime.superConstructor(c).apply(this,arguments)},c=u;$traceurRuntime.createClass(u,{beginEditing:function(e,t){if(void 0===t){var o=this.TD.querySelector('input[type="checkbox"]');l(o,"htBadValue")||o.click()}},finishEditing:function(){},init:function(){},open:function(){},close:function(){},getValue:function(){},setValue:function(){},focus:function(){}},{},a),s("checkbox",u)},{_baseEditor:31,editors:30,"helpers/dom/element":47}],34:[function(e,t,o){"use strict";Object.defineProperties(o,{DateEditor:{get:function(){return E}},__esModule:{value:!0}});var n,r,i,s,a,l,u,c,d,h,f=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,p=(r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r},g=p.addClass,m=p.outerHeight,w=((i=e("helpers/object"))&&i.__esModule&&i||{default:i}).deepExtend,v=((s=e("eventManager"))&&s.__esModule&&s||{default:s}).EventManager,y=(a=e("editors"))&&a.__esModule&&a||{default:a},b=(y.getEditor,y.registerEditor),C=((l=e("helpers/unicode"))&&l.__esModule&&l||{default:l}).isMetaKey,_=((u=e("helpers/dom/event"))&&u.__esModule&&u||{default:u}).stopPropagation,R=((c=e("textEditor"))&&c.__esModule&&c||{default:c}).TextEditor,M=((d=e("moment"))&&d.__esModule&&d||{default:d}).default,S=((h=e("pikaday"))&&h.__esModule&&h||{default:h}).default,E=function(e){this.$datePicker=null,this.datePicker=null,this.datePickerStyle=null,this.defaultDateFormat="DD/MM/YYYY",this.isCellEdited=!1,this.parentDestroyed=!1,$traceurRuntime.superConstructor(O).call(this,e)},O=E;$traceurRuntime.createClass(E,{init:function(){var e=this;if("function"!=typeof M)throw new Error("You need to include moment.js to your project.");if("function"!=typeof S)throw new Error("You need to include Pikaday to your project.");$traceurRuntime.superGet(this,O.prototype,"init").call(this),this.instance.addHook("afterDestroy",function(){e.parentDestroyed=!0,e.destroyElements()})},createElements:function(){$traceurRuntime.superGet(this,O.prototype,"createElements").call(this),this.datePicker=document.createElement("DIV"),this.datePickerStyle=this.datePicker.style,this.datePickerStyle.position="absolute",this.datePickerStyle.top=0,this.datePickerStyle.left=0,this.datePickerStyle.zIndex=9999,g(this.datePicker,"htDatepickerHolder"),document.body.appendChild(this.datePicker),this.$datePicker=new S(this.getDatePickerConfig()),new v(this).addEventListener(this.datePicker,"mousedown",function(e){return _(e)}),this.hideDatepicker()},destroyElements:function(){this.$datePicker.destroy()},prepare:function(e,t,o,n,r,i){this._opened=!1,$traceurRuntime.superGet(this,O.prototype,"prepare").call(this,e,t,o,n,r,i)},open:function(){var e=void 0!==arguments[0]?arguments[0]:null;$traceurRuntime.superGet(this,O.prototype,"open").call(this),this.showDatepicker(e)},close:function(){var e=this;this._opened=!1,this.instance._registerTimeout(setTimeout(function(){e.instance.selection.refreshBorders()},0)),$traceurRuntime.superGet(this,O.prototype,"close").call(this)},finishEditing:function(){var e=void 0!==arguments[0]&&arguments[0],t=void 0!==arguments[1]&&arguments[1];if(e){var o=this.originalValue;void 0!==o&&this.setValue(o)}this.hideDatepicker(),$traceurRuntime.superGet(this,O.prototype,"finishEditing").call(this,e,t)},showDatepicker:function(e){this.$datePicker.config(this.getDatePickerConfig());var t,o=this.TD.getBoundingClientRect(),n=this.cellProperties.dateFormat||this.defaultDateFormat,r=this.$datePicker.config(),i=this.instance.view.isMouseDown(),s=!!e&&C(e.keyCode);this.datePickerStyle.top=window.pageYOffset+o.top+m(this.TD)+"px",this.datePickerStyle.left=window.pageXOffset+o.left+"px",this.$datePicker._onInputFocus=function(){},r.format=n,this.originalValue?(t=this.originalValue,M(t,n,!0).isValid()&&this.$datePicker.setMoment(M(t,n),!0),this.getValue()!==this.originalValue&&this.setValue(this.originalValue),s||i||this.setValue("")):this.cellProperties.defaultDate?(t=this.cellProperties.defaultDate,r.defaultDate=t,M(t,n,!0).isValid()&&this.$datePicker.setMoment(M(t,n),!0),s||i||this.setValue("")):this.$datePicker.gotoToday(),this.datePickerStyle.display="block",this.$datePicker.show()},hideDatepicker:function(){this.datePickerStyle.display="none",this.$datePicker.hide()},getDatePickerConfig:function(){var e=this,t=this.TEXTAREA,o={};this.cellProperties&&this.cellProperties.datePickerConfig&&w(o,this.cellProperties.datePickerConfig);var n=o.onSelect,r=o.onClose;return o.field=t,o.trigger=t,o.container=this.datePicker,o.bound=!1,o.format=o.format||this.defaultDateFormat,o.reposition=o.reposition||!1,o.onSelect=function(t){isNaN(t.getTime())||(t=M(t).format(e.cellProperties.dateFormat||e.defaultDateFormat)),e.setValue(t),e.hideDatepicker(),n&&n()},o.onClose=function(){e.parentDestroyed||e.finishEditing(!1),r&&r()},o}},{},R),f.editors=f.editors||{},f.editors.DateEditor=E,b("date",E)},{browser:24,editors:30,eventManager:42,"helpers/dom/element":47,"helpers/dom/event":48,"helpers/object":53,"helpers/unicode":56,moment:"moment",pikaday:"pikaday",textEditor:41}],35:[function(e,t,o){"use strict";Object.defineProperties(o,{DropdownEditor:{get:function(){return c}},__esModule:{value:!0}});var n,r,i,s=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,a=(r=e("editors"))&&r.__esModule&&r||{default:r},l=(a.getEditor,a.registerEditor),u=(a.getEditorConstructor,((i=e("autocompleteEditor"))&&i.__esModule&&i||{default:i}).AutocompleteEditor),c=function(){$traceurRuntime.superConstructor(d).apply(this,arguments)},d=c;$traceurRuntime.createClass(c,{prepare:function(e,t,o,n,r,i){$traceurRuntime.superGet(this,d.prototype,"prepare").call(this,e,t,o,n,r,i),this.cellProperties.filter=!1,this.cellProperties.strict=!0}},{},u),s.hooks.add("beforeValidate",function(e,t,o,n){var r=this.getCellMeta(t,this.propToCol(o));r.editor===s.editors.DropdownEditor&&void 0===r.strict&&(r.filter=!1,r.strict=!0)}),l("dropdown",c)},{autocompleteEditor:32,browser:24,editors:30}],36:[function(e,t,o){"use strict";Object.defineProperties(o,{HandsontableEditor:{get:function(){return b}},__esModule:{value:!0}});var n,r,i,s,a,l,u,c=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,d=((r=e("helpers/unicode"))&&r.__esModule&&r||{default:r}).KEY_CODES,h=((i=e("helpers/object"))&&i.__esModule&&i||{default:i}).extend,f=((s=e("helpers/dom/element"))&&s.__esModule&&s||{default:s}).setCaretPosition,p=(a=e("helpers/dom/event"))&&a.__esModule&&a||{default:a},g=p.stopImmediatePropagation,m=p.isImmediatePropagationStopped,w=(l=e("editors"))&&l.__esModule&&l||{default:l},v=(w.getEditor,w.registerEditor),y=((u=e("textEditor"))&&u.__esModule&&u||{default:u}).TextEditor,b=y.prototype.extend();b.prototype.createElements=function(){y.prototype.createElements.apply(this,arguments);var e=document.createElement("DIV");e.className="handsontableEditor",this.TEXTAREA_PARENT.appendChild(e),this.htContainer=e,this.assignHooks()},b.prototype.prepare=function(e,t,o,n,r,i){y.prototype.prepare.apply(this,arguments);var s=this,a={startRows:0,startCols:0,minRows:0,minCols:0,className:"listbox",copyPaste:!1,autoColumnSize:!1,autoRowSize:!1,readOnly:!0,fillHandle:!1,afterOnCellMouseDown:function(){var e=this.getValue();void 0!==e&&s.setValue(e),s.instance.destroyEditor()}};this.cellProperties.handsontable&&h(a,i.handsontable),this.htOptions=a};var C=function(e){if(!m(e)){var t,o=this.getActiveEditor(),n=o.htEditor.getInstance();if(e.keyCode==d.ARROW_DOWN)if(n.getSelected()||n.flipped){if(n.getSelected())if(n.flipped)t=n.getSelected()[0]+1;else if(!n.flipped){var r=n.getSelected()[0],i=n.countRows()-1;t=Math.min(i,r+1)}}else t=0;else if(e.keyCode==d.ARROW_UP)if(!n.getSelected()&&n.flipped)t=n.countRows()-1;else if(n.getSelected())if(n.flipped){var r=n.getSelected()[0];t=Math.max(0,r-1)}else{var r=n.getSelected()[0];t=r-1}void 0!==t&&(t<0||n.flipped&&t>n.countRows()-1?n.deselectCell():n.selectCell(t,0),n.getData().length&&(e.preventDefault(),g(e),o.instance.listen(),o.TEXTAREA.focus()))}};b.prototype.open=function(){this.instance.addHook("beforeKeyDown",C),y.prototype.open.apply(this,arguments),this.htEditor&&this.htEditor.destroy(),this.htEditor=new c(this.htContainer,this.htOptions),this.cellProperties.strict?(this.htEditor.selectCell(0,0),this.TEXTAREA.style.visibility="hidden"):(this.htEditor.deselectCell(),this.TEXTAREA.style.visibility="visible"),f(this.TEXTAREA,0,this.TEXTAREA.value.length)},b.prototype.close=function(){this.instance.removeHook("beforeKeyDown",C),this.instance.listen(),y.prototype.close.apply(this,arguments)},b.prototype.focus=function(){this.instance.listen(),y.prototype.focus.apply(this,arguments)},b.prototype.beginEditing=function(e){var t=this.instance.getSettings().onBeginEditing;t&&t()===!1||y.prototype.beginEditing.apply(this,arguments)},b.prototype.finishEditing=function(e,t){if(this.htEditor&&this.htEditor.isListening()&&this.instance.listen(),this.htEditor&&this.htEditor.getSelected()){var o=this.htEditor.getInstance().getValue();void 0!==o&&this.setValue(o)}return y.prototype.finishEditing.apply(this,arguments)},b.prototype.assignHooks=function(){var e=this;this.instance.addHook("afterDestroy",function(){e.htEditor&&e.htEditor.destroy()})},v("handsontable",b)},{browser:24,editors:30,"helpers/dom/element":47,"helpers/dom/event":48,"helpers/object":53,"helpers/unicode":56,textEditor:41}],37:[function(e,t,o){"use strict";Object.defineProperties(o,{MobileTextEditor:{get:function(){return k}},__esModule:{value:!0}});var n,r,i,s,a,l,u,c=(((n=e("browser"))&&n.__esModule&&n||{default:n}).default,((r=e("helpers/unicode"))&&r.__esModule&&r||{default:r}).KEY_CODES),d=(i=e("helpers/dom/event"))&&i.__esModule&&i||{default:i},h=d.stopImmediatePropagation,f=d.isImmediatePropagationStopped,p=(s=e("helpers/dom/element"))&&s.__esModule&&s||{default:s},g=p.addClass,m=p.getScrollLeft,w=p.getScrollTop,v=p.hasClass,y=p.isChildOf,b=p.offset,C=p.outerHeight,_=p.outerWidth,R=p.removeClass,M=p.setCaretPosition,S=(a=e("editors"))&&a.__esModule&&a||{default:a},E=(S.getEditor,S.registerEditor),O=((l=e("_baseEditor"))&&l.__esModule&&l||{default:l}).BaseEditor,T=((u=e("eventManager"))&&u.__esModule&&u||{default:u}).eventManager,k=O.prototype.extend(),x={},H=function(){this.controls={},this.controls.leftButton=document.createElement("DIV"),this.controls.leftButton.className="leftButton",this.controls.rightButton=document.createElement("DIV"),this.controls.rightButton.className="rightButton",this.controls.upButton=document.createElement("DIV"),this.controls.upButton.className="upButton",this.controls.downButton=document.createElement("DIV"),this.controls.downButton.className="downButton";for(var e in this.controls)this.controls.hasOwnProperty(e)&&this.positionControls.appendChild(this.controls[e])};k.prototype.valueChanged=function(){return this.initValue!=this.getValue()},k.prototype.init=function(){var e=this;this.eventManager=T(this.instance),this.createElements(),this.bindEvents(),this.instance.addHook("afterDestroy",function(){e.destroy()})},k.prototype.getValue=function(){return this.TEXTAREA.value},k.prototype.setValue=function(e){this.initValue=e,this.TEXTAREA.value=e},k.prototype.createElements=function(){this.editorContainer=document.createElement("DIV"),this.editorContainer.className="htMobileEditorContainer",this.cellPointer=document.createElement("DIV"),this.cellPointer.className="cellPointer",this.moveHandle=document.createElement("DIV"),this.moveHandle.className="moveHandle",this.inputPane=document.createElement("DIV"),this.inputPane.className="inputs",this.positionControls=document.createElement("DIV"),this.positionControls.className="positionControls",this.TEXTAREA=document.createElement("TEXTAREA"),g(this.TEXTAREA,"handsontableInput"),this.inputPane.appendChild(this.TEXTAREA),this.editorContainer.appendChild(this.cellPointer),this.editorContainer.appendChild(this.moveHandle),this.editorContainer.appendChild(this.inputPane),this.editorContainer.appendChild(this.positionControls),H.call(this),document.body.appendChild(this.editorContainer)},k.prototype.onBeforeKeyDown=function(e){var t=this,o=t.getActiveEditor();if(e.target===o.TEXTAREA&&!f(e))switch(e.keyCode){case c.ENTER:o.close(),e.preventDefault();break;case c.BACKSPACE:h(e)}},k.prototype.open=function(){this.instance.addHook("beforeKeyDown",this.onBeforeKeyDown),g(this.editorContainer,"active"),R(this.cellPointer,"hidden"),this.updateEditorPosition()},k.prototype.focus=function(){this.TEXTAREA.focus(),M(this.TEXTAREA,this.TEXTAREA.value.length)},k.prototype.close=function(){this.TEXTAREA.blur(),this.instance.removeHook("beforeKeyDown",this.onBeforeKeyDown),R(this.editorContainer,"active")},k.prototype.scrollToView=function(){var e=this.instance.getSelectedRange().highlight;this.instance.view.scrollViewport(e)},k.prototype.hideCellPointer=function(){v(this.cellPointer,"hidden")||g(this.cellPointer,"hidden")},k.prototype.updateEditorPosition=function(e,t){if(e&&t)e=parseInt(e,10),t=parseInt(t,10),this.editorContainer.style.top=t+"px",this.editorContainer.style.left=e+"px";else{var o=this.instance.getSelected(),n=this.instance.getCell(o[0],o[1]);if(x.cellPointer||(x.cellPointer={height:C(this.cellPointer),width:_(this.cellPointer)}),x.editorContainer||(x.editorContainer={width:_(this.editorContainer)}),void 0!==n){var r=this.instance.view.wt.wtOverlays.leftOverlay.trimmingContainer==window?0:m(this.instance.view.wt.wtOverlays.leftOverlay.holder),i=this.instance.view.wt.wtOverlays.topOverlay.trimmingContainer==window?0:w(this.instance.view.wt.wtOverlays.topOverlay.holder),s=b(n),a=_(n),l={x:r,y:i};this.editorContainer.style.top=parseInt(s.top+C(n)-l.y+x.cellPointer.height,10)+"px",this.editorContainer.style.left=parseInt(window.innerWidth/2-x.editorContainer.width/2,10)+"px",s.left+a/2>parseInt(this.editorContainer.style.left,10)+x.editorContainer.width?this.editorContainer.style.left=window.innerWidth-x.editorContainer.width+"px":s.left+a/2<parseInt(this.editorContainer.style.left,10)+20&&(this.editorContainer.style.left="0px"),this.cellPointer.style.left=parseInt(s.left-x.cellPointer.width/2-b(this.editorContainer).left+a/2-l.x,10)+"px"}}},k.prototype.updateEditorData=function(){var e=this.instance.getSelected(),t=this.instance.getDataAtCell(e[0],e[1]);this.row=e[0],this.col=e[1],this.setValue(t),this.updateEditorPosition()},k.prototype.prepareAndSave=function(){var e;if(!this.valueChanged())return!0;e=this.instance.getSettings().trimWhitespace?[[String.prototype.trim.call(this.getValue())]]:[[this.getValue()]],this.saveValue(e)},k.prototype.bindEvents=function(){var e=this;this.eventManager.addEventListener(this.controls.leftButton,"touchend",function(t){e.prepareAndSave(),e.instance.selection.transformStart(0,-1,null,!0),e.updateEditorData(),t.preventDefault()}),this.eventManager.addEventListener(this.controls.rightButton,"touchend",function(t){e.prepareAndSave(),e.instance.selection.transformStart(0,1,null,!0),e.updateEditorData(),t.preventDefault()}),this.eventManager.addEventListener(this.controls.upButton,"touchend",function(t){e.prepareAndSave(),e.instance.selection.transformStart(-1,0,null,!0),e.updateEditorData(),t.preventDefault()}),this.eventManager.addEventListener(this.controls.downButton,"touchend",function(t){e.prepareAndSave(),e.instance.selection.transformStart(1,0,null,!0),e.updateEditorData(),t.preventDefault()}),this.eventManager.addEventListener(this.moveHandle,"touchstart",function(t){if(1==t.touches.length){var o=t.touches[0],n={x:e.editorContainer.offsetLeft,y:e.editorContainer.offsetTop},r={x:o.pageX-n.x,y:o.pageY-n.y};e.eventManager.addEventListener(this,"touchmove",function(t){var o=t.touches[0];e.updateEditorPosition(o.pageX-r.x,o.pageY-r.y),e.hideCellPointer(),t.preventDefault()})}}),this.eventManager.addEventListener(document.body,"touchend",function(t){y(t.target,e.editorContainer)||y(t.target,e.instance.rootElement)||e.close()}),this.eventManager.addEventListener(this.instance.view.wt.wtOverlays.leftOverlay.holder,"scroll",function(t){e.instance.view.wt.wtOverlays.leftOverlay.trimmingContainer!=window&&e.hideCellPointer()}),this.eventManager.addEventListener(this.instance.view.wt.wtOverlays.topOverlay.holder,"scroll",function(t){e.instance.view.wt.wtOverlays.topOverlay.trimmingContainer!=window&&e.hideCellPointer()})},k.prototype.destroy=function(){this.eventManager.clear(),this.editorContainer.parentNode.removeChild(this.editorContainer)},E("mobile",k)},{_baseEditor:31,browser:24,editors:30,eventManager:42,"helpers/dom/element":47,"helpers/dom/event":48,"helpers/unicode":56}],38:[function(e,t,o){"use strict";Object.defineProperties(o,{NumericEditor:{get:function(){return u}},__esModule:{value:!0}});var n,r,i,s=((n=e("numbro"))&&n.__esModule&&n||{default:n}).default,a=((r=e("editors"))&&r.__esModule&&r||{default:r}).registerEditor,l=((i=e("textEditor"))&&i.__esModule&&i||{default:i}).TextEditor,u=function(){$traceurRuntime.superConstructor(c).apply(this,arguments)},c=u;$traceurRuntime.createClass(u,{beginEditing:function(e){if(void 0===e&&this.originalValue){void 0!==this.cellProperties.language&&s.culture(this.cellProperties.language);var t=s.cultureData().delimiters.decimal;e=(""+this.originalValue).replace(".",t)}$traceurRuntime.superGet(this,c.prototype,"beginEditing").call(this,e)}},{},l),a("numeric",u)},{editors:30,numbro:"numbro",textEditor:41}],39:[function(e,t,o){"use strict";Object.defineProperties(o,{PasswordEditor:{get:function(){return d}},__esModule:{value:!0}});var n,r,i,s,a=(((n=e("browser"))&&n.__esModule&&n||{default:n}).default,((r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r}).empty),l=(i=e("editors"))&&i.__esModule&&i||{default:i},u=(l.getEditor,l.registerEditor),c=((s=e("textEditor"))&&s.__esModule&&s||{default:s}).TextEditor,d=function(){$traceurRuntime.superConstructor(h).apply(this,arguments)},h=d;$traceurRuntime.createClass(d,{createElements:function(){$traceurRuntime.superGet(this,h.prototype,"createElements").call(this),this.TEXTAREA=document.createElement("input"),this.TEXTAREA.setAttribute("type","password"),this.TEXTAREA.className="handsontableInput",this.textareaStyle=this.TEXTAREA.style,this.textareaStyle.width=0,this.textareaStyle.height=0,a(this.TEXTAREA_PARENT),this.TEXTAREA_PARENT.appendChild(this.TEXTAREA)}},{},c),u("password",d)},{browser:24,editors:30,"helpers/dom/element":47,textEditor:41}],40:[function(e,t,o){"use strict";Object.defineProperties(o,{SelectEditor:{get:function(){return E}},__esModule:{value:!0}});var n,r,i,s,a,l,u=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,c=(r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r},d=c.addClass,h=c.empty,f=c.fastInnerHTML,p=c.getComputedStyle,g=c.getCssTransform,m=c.getScrollableElement,w=c.offset,v=c.outerHeight,y=c.outerWidth,b=c.resetCssTransform,C=((i=e("helpers/dom/event"))&&i.__esModule&&i||{default:i}).stopImmediatePropagation,_=((s=e("helpers/unicode"))&&s.__esModule&&s||{default:s}).KEY_CODES,R=(a=e("editors"))&&a.__esModule&&a||{default:a},M=(R.getEditor,R.registerEditor),S=((l=e("_baseEditor"))&&l.__esModule&&l||{default:l}).BaseEditor,E=S.prototype.extend();E.prototype.init=function(){this.select=document.createElement("SELECT"),d(this.select,"htSelectEditor"),this.select.style.display="none",this.instance.rootElement.appendChild(this.select),this.registerHooks()},E.prototype.registerHooks=function(){var e=this;this.instance.addHook("afterScrollHorizontally",function(){return e.refreshDimensions()}),this.instance.addHook("afterScrollVertically",function(){return e.refreshDimensions()}),this.instance.addHook("afterColumnResize",function(){return e.refreshDimensions()}),this.instance.addHook("afterRowResize",function(){return e.refreshDimensions()})},E.prototype.prepare=function(){S.prototype.prepare.apply(this,arguments);var e,t=this.cellProperties.selectOptions;e="function"==typeof t?this.prepareOptions(t(this.row,this.col,this.prop)):this.prepareOptions(t),h(this.select);for(var o in e)if(e.hasOwnProperty(o)){var n=document.createElement("OPTION");n.value=o,f(n,e[o]),this.select.appendChild(n)}},E.prototype.prepareOptions=function(e){var t={};if(Array.isArray(e))for(var o=0,n=e.length;o<n;o++)t[e[o]]=e[o];else"object"==typeof e&&(t=e);return t},E.prototype.getValue=function(){return this.select.value},E.prototype.setValue=function(e){this.select.value=e};var O=function(e){var t=this,o=t.getActiveEditor();switch(e.keyCode){
33
- case _.ARROW_UP:var n=o.select.selectedIndex-1;n>=0&&(o.select[n].selected=!0),C(e),e.preventDefault();break;case _.ARROW_DOWN:var r=o.select.selectedIndex+1;r<=o.select.length-1&&(o.select[r].selected=!0),C(e),e.preventDefault()}};E.prototype.open=function(){this._opened=!0,this.refreshDimensions(),this.select.style.display="",this.instance.addHook("beforeKeyDown",O)},E.prototype.close=function(){this._opened=!1,this.select.style.display="none",this.instance.removeHook("beforeKeyDown",O)},E.prototype.focus=function(){this.select.focus()},E.prototype.refreshValue=function(){var e=this.instance.getSourceDataAtCell(this.row,this.prop);this.originalValue=e,this.setValue(e),this.refreshDimensions()},E.prototype.refreshDimensions=function(){if(this.state===u.EditorState.EDITING){if(this.TD=this.getEditedCell(),!this.TD)return void this.close();var e,t=y(this.TD)+1,o=v(this.TD)+1,n=w(this.TD),r=w(this.instance.rootElement),i=m(this.TD),s=n.top-r.top-1-(i.scrollTop||0),a=n.left-r.left-1-(i.scrollLeft||0),l=this.checkEditorSection(),c=this.instance.getSettings();c.rowHeaders,c.colHeaders;switch(l){case"top":e=g(this.instance.view.wt.wtOverlays.topOverlay.clone.wtTable.holder.parentNode);break;case"left":e=g(this.instance.view.wt.wtOverlays.leftOverlay.clone.wtTable.holder.parentNode);break;case"top-left-corner":e=g(this.instance.view.wt.wtOverlays.topLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom-left-corner":e=g(this.instance.view.wt.wtOverlays.bottomLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom":e=g(this.instance.view.wt.wtOverlays.bottomOverlay.clone.wtTable.holder.parentNode)}0===this.instance.getSelected()[0]&&(s+=1),0===this.instance.getSelected()[1]&&(a+=1);var d=this.select.style;e&&e!=-1?d[e[0]]=e[1]:b(this.select);var h=p(this.TD);parseInt(h.borderTopWidth,10)>0&&(o-=1),parseInt(h.borderLeftWidth,10)>0&&(t-=1),d.height=o+"px",d.minWidth=t+"px",d.top=s+"px",d.left=a+"px",d.margin="0px"}},E.prototype.getEditedCell=function(){var e,t=this.checkEditorSection();switch(t){case"top":e=this.instance.view.wt.wtOverlays.topOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.select.style.zIndex=101;break;case"corner":e=this.instance.view.wt.wtOverlays.topLeftCornerOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.select.style.zIndex=103;break;case"left":e=this.instance.view.wt.wtOverlays.leftOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.select.style.zIndex=102;break;default:e=this.instance.getCell(this.row,this.col),this.select.style.zIndex=""}return e!=-1&&e!=-2?e:void 0},M("select",E)},{_baseEditor:31,browser:24,editors:30,"helpers/dom/element":47,"helpers/dom/event":48,"helpers/unicode":56}],41:[function(e,t,o){"use strict";Object.defineProperties(o,{TextEditor:{get:function(){return L}},__esModule:{value:!0}});var n,r,i,s,a,l,u,c,d=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,h=(r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r},f=h.addClass,p=h.getCaretPosition,g=h.getComputedStyle,m=h.getCssTransform,w=h.getScrollableElement,v=h.getScrollbarWidth,y=h.innerWidth,b=h.offset,C=h.resetCssTransform,_=h.setCaretPosition,R=h.hasVerticalScrollbar,M=h.hasHorizontalScrollbar,S=((i=e("autoResize"))&&i.__esModule&&i||{default:i}).default,E=((s=e("_baseEditor"))&&s.__esModule&&s||{default:s}).BaseEditor,O=((a=e("eventManager"))&&a.__esModule&&a||{default:a}).eventManager,T=(l=e("editors"))&&l.__esModule&&l||{default:l},k=(T.getEditor,T.registerEditor),x=((u=e("helpers/unicode"))&&u.__esModule&&u||{default:u}).KEY_CODES,H=(c=e("helpers/dom/event"))&&c.__esModule&&c||{default:c},D=H.stopPropagation,A=H.stopImmediatePropagation,P=H.isImmediatePropagationStopped,L=E.prototype.extend();L.prototype.init=function(){var e=this;this.createElements(),this.eventManager=O(this),this.bindEvents(),this.autoResize=S(),this.instance.addHook("afterDestroy",function(){e.destroy()})},L.prototype.getValue=function(){return this.TEXTAREA.value},L.prototype.setValue=function(e){this.TEXTAREA.value=e};var N=function(e){var t,o=this,n=o.getActiveEditor();if(t=(e.ctrlKey||e.metaKey)&&!e.altKey,e.target===n.TEXTAREA&&!P(e)){if(17===e.keyCode||224===e.keyCode||91===e.keyCode||93===e.keyCode)return void A(e);switch(e.keyCode){case x.ARROW_RIGHT:n.isInFullEditMode()&&(!n.isWaiting()&&!n.allowKeyEventPropagation||!n.isWaiting()&&n.allowKeyEventPropagation&&!n.allowKeyEventPropagation(e.keyCode))&&A(e);break;case x.ARROW_LEFT:n.isInFullEditMode()&&(!n.isWaiting()&&!n.allowKeyEventPropagation||!n.isWaiting()&&n.allowKeyEventPropagation&&!n.allowKeyEventPropagation(e.keyCode))&&A(e);break;case x.ARROW_UP:case x.ARROW_DOWN:n.isInFullEditMode()&&(!n.isWaiting()&&!n.allowKeyEventPropagation||!n.isWaiting()&&n.allowKeyEventPropagation&&!n.allowKeyEventPropagation(e.keyCode))&&A(e);break;case x.ENTER:var r=n.instance.getSelected(),i=!(r[0]===r[2]&&r[1]===r[3]);if(t&&!i||e.altKey){if(n.isOpened()){var s=p(n.TEXTAREA),a=n.getValue(),l=a.slice(0,s)+"\n"+a.slice(s);n.setValue(l),_(n.TEXTAREA,s+1)}else n.beginEditing(n.originalValue+"\n");A(e)}e.preventDefault();break;case x.A:case x.X:case x.C:case x.V:t&&A(e);break;case x.BACKSPACE:case x.DELETE:case x.HOME:case x.END:A(e)}[x.ARROW_UP,x.ARROW_RIGHT,x.ARROW_DOWN,x.ARROW_LEFT].indexOf(e.keyCode)===-1&&n.autoResize.resize(String.fromCharCode(e.keyCode))}};L.prototype.open=function(){this.refreshDimensions(),this.instance.addHook("beforeKeyDown",N)},L.prototype.close=function(e){this.textareaParentStyle.display="none",this.autoResize.unObserve(),document.activeElement===this.TEXTAREA&&this.instance.listen(),this.instance.removeHook("beforeKeyDown",N)},L.prototype.focus=function(){this.TEXTAREA.focus(),_(this.TEXTAREA,this.TEXTAREA.value.length)},L.prototype.createElements=function(){this.TEXTAREA=document.createElement("TEXTAREA"),f(this.TEXTAREA,"handsontableInput"),this.textareaStyle=this.TEXTAREA.style,this.textareaStyle.width=0,this.textareaStyle.height=0,this.TEXTAREA_PARENT=document.createElement("DIV"),f(this.TEXTAREA_PARENT,"handsontableInputHolder"),this.textareaParentStyle=this.TEXTAREA_PARENT.style,this.textareaParentStyle.top=0,this.textareaParentStyle.left=0,this.textareaParentStyle.display="none",this.TEXTAREA_PARENT.appendChild(this.TEXTAREA),this.instance.rootElement.appendChild(this.TEXTAREA_PARENT);var e=this;this.instance._registerTimeout(setTimeout(function(){e.refreshDimensions()},0))},L.prototype.getEditedCell=function(){var e,t=this.checkEditorSection();switch(t){case"top":e=this.instance.view.wt.wtOverlays.topOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=101;break;case"top-left-corner":e=this.instance.view.wt.wtOverlays.topLeftCornerOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=103;break;case"bottom-left-corner":e=this.instance.view.wt.wtOverlays.bottomLeftCornerOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=103;break;case"left":e=this.instance.view.wt.wtOverlays.leftOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=102;break;case"bottom":e=this.instance.view.wt.wtOverlays.bottomOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=102;break;default:e=this.instance.getCell(this.row,this.col),this.textareaParentStyle.zIndex=""}return e!=-1&&e!=-2?e:void 0},L.prototype.refreshValue=function(){var e=this.instance.getSourceDataAtCell(this.row,this.prop);this.originalValue=e,this.setValue(e),this.refreshDimensions()},L.prototype.refreshDimensions=function(){if(this.state===d.EditorState.EDITING){if(this.TD=this.getEditedCell(),!this.TD)return void this.close(!0);var e,t=b(this.TD),o=b(this.instance.rootElement),n=w(this.TD),r=this.instance.countRows(),i=t.top===o.top?0:1,s=t.top-o.top-i-(n.scrollTop||0),a=t.left-o.left-1-(n.scrollLeft||0),l=this.instance.getSettings(),u=(this.instance.hasRowHeaders(),this.instance.hasColHeaders()),c=this.checkEditorSection(),h=this.TD.style.backgroundColor;switch(c){case"top":e=m(this.instance.view.wt.wtOverlays.topOverlay.clone.wtTable.holder.parentNode);break;case"left":e=m(this.instance.view.wt.wtOverlays.leftOverlay.clone.wtTable.holder.parentNode);break;case"top-left-corner":e=m(this.instance.view.wt.wtOverlays.topLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom-left-corner":e=m(this.instance.view.wt.wtOverlays.bottomLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom":e=m(this.instance.view.wt.wtOverlays.bottomOverlay.clone.wtTable.holder.parentNode)}(u&&0===this.instance.getSelected()[0]||l.fixedRowsBottom&&this.instance.getSelected()[0]===r-l.fixedRowsBottom)&&(s+=1),0===this.instance.getSelected()[1]&&(a+=1),e&&e!=-1?this.textareaParentStyle[e[0]]=e[1]:C(this.TEXTAREA_PARENT),this.textareaParentStyle.top=s+"px",this.textareaParentStyle.left=a+"px";var f=this.instance.view.wt.wtViewport.rowsRenderCalculator.startPosition,p=this.instance.view.wt.wtViewport.columnsRenderCalculator.startPosition,_=this.instance.view.wt.wtOverlays.leftOverlay.getScrollPosition(),S=this.instance.view.wt.wtOverlays.topOverlay.getScrollPosition(),E=v(),O=this.TD.offsetTop+f-S,T=this.TD.offsetLeft+p-_,k=y(this.TD)-8,x=R(n)?E:0,H=M(n)?E:0,D=this.instance.view.maximumVisibleElementWidth(T)-9-x,A=this.TD.scrollHeight+1,P=Math.max(this.instance.view.maximumVisibleElementHeight(O)-H,23),L=g(this.TD);this.TEXTAREA.style.fontSize=L.fontSize,this.TEXTAREA.style.fontFamily=L.fontFamily,this.TEXTAREA.style.backgroundColor="",this.TEXTAREA.style.backgroundColor=h?h:g(this.TEXTAREA).backgroundColor,this.autoResize.init(this.TEXTAREA,{minHeight:Math.min(A,P),maxHeight:P,minWidth:Math.min(k,D),maxWidth:D},!0),this.textareaParentStyle.display="block"}},L.prototype.bindEvents=function(){var e=this;this.eventManager.addEventListener(this.TEXTAREA,"cut",function(e){D(e)}),this.eventManager.addEventListener(this.TEXTAREA,"paste",function(e){D(e)}),this.instance.addHook("afterScrollHorizontally",function(){e.refreshDimensions()}),this.instance.addHook("afterScrollVertically",function(){e.refreshDimensions()}),this.instance.addHook("afterColumnResize",function(){e.refreshDimensions(),e.focus()}),this.instance.addHook("afterRowResize",function(){e.refreshDimensions(),e.focus()}),this.instance.addHook("afterDestroy",function(){e.eventManager.destroy()})},L.prototype.destroy=function(){this.eventManager.destroy()},k("text",L)},{_baseEditor:31,autoResize:"autoResize",browser:24,editors:30,eventManager:42,"helpers/dom/element":47,"helpers/dom/event":48,"helpers/unicode":56}],42:[function(e,t,o){"use strict";function n(e,t){var o,n,r,i,s,a;if(t.isTargetWebComponent=!1,t.realTarget=t.target,a=t.stopImmediatePropagation,t.stopImmediatePropagation=function(){a.apply(this),p(this)},!u.eventManager.isHotTableEnv)return t;for(t=d(t),s=t.path?t.path.length:0;s--;){if("HOT-TABLE"===t.path[s].nodeName)o=!0;else if(o&&t.path[s].shadowRoot){i=t.path[s];break}0!==s||i||(i=t.path[s])}return i||(i=t.target),t.isTargetWebComponent=!0,f()?t.realTarget=t.srcElement||t.toElement:(e instanceof u.Core||e instanceof Walkontable)&&(e instanceof u.Core?n=e.view?e.view.wt.wtTable.TABLE:null:e instanceof Walkontable&&(n=e.wtTable.TABLE.parentNode.parentNode),r=h(t.target,["HOT-TABLE"],n),t.realTarget=r?n.querySelector("HOT-TABLE")||t.target:t.target),Object.defineProperty(t,"target",{get:function(){return d(i)},enumerable:!0,configurable:!0}),t}function r(e){return new g(e)}Object.defineProperties(o,{EventManager:{get:function(){return g}},eventManager:{get:function(){return r}},__esModule:{value:!0}});var i,s,a,l,u=((i=e("browser"))&&i.__esModule&&i||{default:i}).default,c=(s=e("helpers/dom/element"))&&s.__esModule&&s||{default:s},d=c.polymerWrap,h=c.closest,f=((a=e("helpers/feature"))&&a.__esModule&&a||{default:a}).isWebComponentSupportedNatively,p=((l=e("helpers/dom/event"))&&l.__esModule&&l||{default:l}).stopImmediatePropagation,g=function(){var e=void 0!==arguments[0]?arguments[0]:null;this.context=e||this,this.context.eventListeners||(this.context.eventListeners=[])};$traceurRuntime.createClass(g,{addEventListener:function(e,t,o){function r(e){e=n(s,e),o.call(this,e)}var i=this,s=this.context;return this.context.eventListeners.push({element:e,event:t,callback:o,callbackProxy:r}),window.addEventListener?e.addEventListener(t,r,!1):e.attachEvent("on"+t,r),u.countEventManagerListeners++,function(){i.removeEventListener(e,t,o)}},removeEventListener:function(e,t,o){for(var n,r=this.context.eventListeners.length;r--;)if(n=this.context.eventListeners[r],n.event==t&&n.element==e){if(o&&o!=n.callback)continue;this.context.eventListeners.splice(r,1),n.element.removeEventListener?n.element.removeEventListener(n.event,n.callbackProxy,!1):n.element.detachEvent("on"+n.event,n.callbackProxy),u.countEventManagerListeners--}},clearEvents:function(){if(this.context)for(var e=this.context.eventListeners.length;e--;){var t=this.context.eventListeners[e];t&&this.removeEventListener(t.element,t.event,t.callback)}},clear:function(){this.clearEvents()},destroy:function(){this.clearEvents(),this.context=null},fireEvent:function(e,t){var o,n={bubbles:!0,cancelable:"mousemove"!==t,view:window,detail:0,screenX:0,screenY:0,clientX:1,clientY:1,ctrlKey:!1,altKey:!1,shiftKey:!1,metaKey:!1,button:0,relatedTarget:void 0};document.createEvent?(o=document.createEvent("MouseEvents"),o.initMouseEvent(t,n.bubbles,n.cancelable,n.view,n.detail,n.screenX,n.screenY,n.clientX,n.clientY,n.ctrlKey,n.altKey,n.shiftKey,n.metaKey,n.button,n.relatedTarget||document.body.parentNode)):o=document.createEventObject(),e.dispatchEvent?e.dispatchEvent(o):e.fireEvent("on"+t,o)}},{}),u.countEventManagerListeners=0,u.eventManager=r},{browser:24,"helpers/dom/element":47,"helpers/dom/event":48,"helpers/feature":49}],43:[function(e,t,o){"use strict";function n(e){for(var t=0,o=e.length;t<o;)e[t]=[e[t]],t++}function r(e,t){for(var o=0,n=t.length;o<n;)e.push(t[o]),o++}function i(e){var t=[];if(!e||0===e.length||!e[0]||0===e[0].length)return t;for(var o=e.length,n=e[0].length,r=0;r<o;r++)for(var i=0;i<n;i++)t[i]||(t[i]=[]),t[i][r]=e[r][i];return t}function s(e,t,o,n){var r=-1,i=e.length;for(n&&i&&(o=e[++r]);++r<i;)o=t(o,e[r],r,e);return o}function a(e,t){for(var o=-1,n=e.length,r=-1,i=[];++o<n;){var s=e[o];t(s,o,e)&&(i[++r]=s)}return i}function l(e,t){for(var o=-1,n=e.length,r=-1,i=[];++o<n;){var s=e[o];i[++r]=t(s,o,e)}return i}function u(e,t){for(var o=-1,n=e.length;++o<n&&t(e[o],o,e)!==!1;);return e}function c(e){return s(e,function(e,t){return e+t},0)}function d(e){return s(e,function(e,t){return e>t?e:t},Array.isArray(e)?e[0]:void 0)}function h(e){return s(e,function(e,t){return e<t?e:t},Array.isArray(e)?e[0]:void 0)}function f(e){return e.length?c(e)/e.length:0}function p(e){return s(e,function(e,t){return e.concat(Array.isArray(t)?p(t):t)},[])}function g(e){var t=[];return u(e,function(e){t.indexOf(e)===-1&&t.push(e)}),t}function m(e,t,o){if(null==e)throw new TypeError('"array" is null or not defined');var n=Object(e),r=n.length>>>0;if(0===r)return!1;for(var i=0|o,s=Math.max(i>=0?i:r-Math.abs(i),0);s<r;){if(n[s]===t)return!0;s++}return!1}Object.defineProperties(o,{to2dArray:{get:function(){return n}},extendArray:{get:function(){return r}},pivot:{get:function(){return i}},arrayReduce:{get:function(){return s}},arrayFilter:{get:function(){return a}},arrayMap:{get:function(){return l}},arrayEach:{get:function(){return u}},arraySum:{get:function(){return c}},arrayMax:{get:function(){return d}},arrayMin:{get:function(){return h}},arrayAvg:{get:function(){return f}},arrayFlatten:{get:function(){return p}},arrayUnique:{get:function(){return g}},arrayIncludes:{get:function(){return m}},__esModule:{value:!0}})},{}],44:[function(e,t,o){"use strict";function n(){return l}function r(){return u}function i(){return c}function s(){return d}function a(e){return e||(e=navigator.userAgent),/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(e)}Object.defineProperties(o,{isIE8:{get:function(){return n}},isIE9:{get:function(){return r}},isSafari:{get:function(){return i}},isChrome:{get:function(){return s}},isMobileBrowser:{get:function(){return a}},__esModule:{value:!0}});var l=!document.createTextNode("test").textContent,u=!!document.documentMode,c=/Safari/.test(navigator.userAgent)&&/Apple Computer/.test(navigator.vendor),d=/Chrome/.test(navigator.userAgent)&&/Google/.test(navigator.vendor)},{}],45:[function(e,t,o){"use strict";function n(e){for(var t,o=e+1,n="";o>0;)t=(o-1)%g,n=String.fromCharCode(65+t)+n,o=parseInt((o-t)/g,10);return n}function r(e){var t=0;if(e)for(var o=0,n=e.length-1;o<e.length;o+=1,n-=1)t+=Math.pow(g,n)*(p.indexOf(e[o])+1);return--t}function i(){var e,t,o=void 0!==arguments[0]?arguments[0]:100,r=void 0!==arguments[1]?arguments[1]:4,i=[];for(e=0;e<o;e++){var s=[];for(t=0;t<r;t++)s.push(n(t)+(e+1));i.push(s)}return i}function s(){var e,t,o=void 0!==arguments[0]?arguments[0]:100,r=void 0!==arguments[1]?arguments[1]:4,i=[];for(e=0;e<o;e++){var s={};for(t=0;t<r;t++)s["prop"+t]=n(t)+(e+1);i.push(s)}return i}function a(e,t){for(var o,n=[],r=0;r<e;r++){o=[];for(var i=0;i<t;i++)o.push("");n.push(o)}return n}function l(e){var t,o,n,r,i=[],s=0;for(t=0,o=e.length;t<o;t++)for(n=0,r=e[t].length;n<r;n++)n==s&&(i.push([]),s++),i[n].push(e[t][n]);return i}function u(e,t){function o(e){var t=h.cellTypes[e];if(void 0===t)throw new Error('You declared cell type "'+e+'" as a string that is not mapped to a known object. Cell type must be an object or a string mapped to an object in Handsontable.cellTypes');return t}return t=void 0===t||t,function(n,r){return function n(r){if(r){if(r.hasOwnProperty(e)&&void 0!==r[e])return r[e];if(r.hasOwnProperty("type")&&r.type){var i;if("string"!=typeof r.type)throw new Error("Cell type must be a string ");if(i=o(r.type),i.hasOwnProperty(e))return i[e];if(t)return}return n(f(r))}}("number"==typeof n?this.getCellMeta(n,r):n)}}Object.defineProperties(o,{spreadsheetColumnLabel:{get:function(){return n}},spreadsheetColumnIndex:{get:function(){return r}},createSpreadsheetData:{get:function(){return i}},createSpreadsheetObjectData:{get:function(){return s}},createEmptySpreadsheetData:{get:function(){return a}},translateRowsToColumns:{get:function(){return l}},cellMethodLookupFactory:{get:function(){return u}},__esModule:{value:!0}});var c,d,h=((c=e("browser"))&&c.__esModule&&c||{default:c}).default,f=((d=e("object"))&&d.__esModule&&d||{default:d}).getPrototypeOf,p="ABCDEFGHIJKLMNOPQRSTUVWXYZ",g=p.length},{browser:24,object:53}],46:[function(e,t,o){"use strict";function n(e){var t=new Date(e);return isNaN(new Date(e+"T00:00").getDate())?t:new Date(t.getTime()+6e4*t.getTimezoneOffset())}Object.defineProperties(o,{getNormalizedDate:{get:function(){return n}},__esModule:{value:!0}})},{}],47:[function(e,t,o){"use strict";function n(e){for(var t=void 0!==arguments[1]?arguments[1]:0,o=-1,n=null;null!=e;){if(o===t){n=e;break}e.host&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e=e.host:(o++,e=e.parentNode)}return n}function r(e,t,o){for(;null!=e&&e!==o;){if(e.nodeType===Node.ELEMENT_NODE&&(t.indexOf(e.nodeName)>-1||t.indexOf(e)>-1))return e;e=e.host&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e.host:e.parentNode}return null}function i(e,t,o){for(var n=[];e&&((e=r(e,t,o))&&(!o||o.contains(e)));)n.push(e),e=e.host&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e.host:e.parentNode;var i=n.length;return i?n[i-1]:null}function s(e,t){var o=e.parentNode,n=[];for("string"==typeof t?n=Array.prototype.slice.call(document.querySelectorAll(t),0):n.push(t);null!=o;){if(n.indexOf(o)>-1)return!0;o=o.parentNode}return!1}function a(e){function t(e){return e.nodeType===Node.ELEMENT_NODE&&e.nodeName===n.toUpperCase()}var o,n="hot-table",r=!1;for(o=l(e);null!=o;){if(t(o)){r=!0;break}if(o.host&&o.nodeType===Node.DOCUMENT_FRAGMENT_NODE){if(r=t(o.host))break;o=o.host}o=o.parentNode}return r}function l(e){return"undefined"!=typeof Polymer&&"function"==typeof wrap?wrap(e):e}function u(e){return"undefined"!=typeof Polymer&&"function"==typeof unwrap?unwrap(e):e}function c(e){var t=0;if(e.previousSibling)for(;e=e.previousSibling;)++t;return t}function d(e,t){var o=document.querySelector(".ht_clone_"+e);return o?o.contains(t):null}function h(e){var t=0,o=[];if(!e||!e.length)return o;for(;e[t];)o.push(e[t]),t++;return o}function f(e,t){return Z(e,t)}function p(e,t){return J(e,t)}function g(e,t){return Q(e,t)}function m(e,t){if(3===e.nodeType)t.removeChild(e);else if(["TABLE","THEAD","TBODY","TFOOT","TR"].indexOf(e.nodeName)>-1)for(var o=e.childNodes,n=o.length-1;n>=0;n--)m(o[n],e)}function w(e){for(var t;t=e.lastChild;)e.removeChild(t)}function v(e,t){ue.test(t)?e.innerHTML=t:y(e,t)}function y(e,t){var o=e.firstChild;o&&3===o.nodeType&&null===o.nextSibling?ce?o.textContent=t:o.data=t:(w(e),e.appendChild(document.createTextNode(t)))}function b(e){for(var t=e;u(t)!==document.documentElement;){if(null===t)return!1;if(t.nodeType===Node.DOCUMENT_FRAGMENT_NODE){if(t.host){if(t.host.impl)return b(t.host.impl);if(t.host)return b(t.host);throw new Error("Lost in Web Components world")}return!1}if("none"===t.style.display)return!1;t=t.parentNode}return!0}function C(e){var t,o,n,r,i;if(r=document.documentElement,re()&&e.firstChild&&"CAPTION"===e.firstChild.nodeName)return i=e.getBoundingClientRect(),{top:i.top+(window.pageYOffset||r.scrollTop)-(r.clientTop||0),left:i.left+(window.pageXOffset||r.scrollLeft)-(r.clientLeft||0)};for(t=e.offsetLeft,o=e.offsetTop,n=e;(e=e.offsetParent)&&e!==document.body;)t+=e.offsetLeft,o+=e.offsetTop,n=e;return n&&"fixed"===n.style.position&&(t+=window.pageXOffset||r.scrollLeft,o+=window.pageYOffset||r.scrollTop),{left:t,top:o}}function _(){var e=window.scrollY;return void 0===e&&(e=document.documentElement.scrollTop),e}function R(){var e=window.scrollX;return void 0===e&&(e=document.documentElement.scrollLeft),e}function M(e){return e===window?_():e.scrollTop}function S(e){return e===window?R():e.scrollLeft}function E(e){for(var t,o,n,r=e.parentNode,i=["auto","scroll"],s="",a="",l="",u="";r&&r.style&&document.body!==r;){if(t=r.style.overflow,o=r.style.overflowX,n=r.style.overflowY,"scroll"==t||"scroll"==o||"scroll"==n)return r;if(window.getComputedStyle&&(s=window.getComputedStyle(r),a=s.getPropertyValue("overflow"),l=s.getPropertyValue("overflow-y"),u=s.getPropertyValue("overflow-x"),"scroll"===a||"scroll"===u||"scroll"===l))return r;if(r.clientHeight<=r.scrollHeight&&(i.indexOf(n)!==-1||i.indexOf(t)!==-1||i.indexOf(a)!==-1||i.indexOf(l)!==-1))return r;if(r.clientWidth<=r.scrollWidth&&(i.indexOf(o)!==-1||i.indexOf(t)!==-1||i.indexOf(a)!==-1||i.indexOf(u)!==-1))return r;r=r.parentNode}return window}function O(e){for(var t=e.parentNode;t&&t.style&&document.body!==t;){if("visible"!==t.style.overflow&&""!==t.style.overflow)return t;if(window.getComputedStyle){var o=window.getComputedStyle(t);if("visible"!==o.getPropertyValue("overflow")&&""!==o.getPropertyValue("overflow"))return t}t=t.parentNode}return window}function T(e,t){if(e){if(e!==window){var o,n=e.style[t];return""!==n&&void 0!==n?n:(o=k(e),""!==o[t]&&void 0!==o[t]?o[t]:void 0)}if("width"===t)return window.innerWidth+"px";if("height"===t)return window.innerHeight+"px"}}function k(e){return e.currentStyle||document.defaultView.getComputedStyle(e)}function x(e){return e.offsetWidth}function H(e){return re()&&e.firstChild&&"CAPTION"===e.firstChild.nodeName?e.offsetHeight+e.firstChild.offsetHeight:e.offsetHeight}function D(e){return e.clientHeight||e.innerHeight}function A(e){return e.clientWidth||e.innerWidth}function P(e,t,o){window.addEventListener?e.addEventListener(t,o,!1):e.attachEvent("on"+t,o)}function L(e,t,o){window.removeEventListener?e.removeEventListener(t,o,!1):e.detachEvent("on"+t,o)}function N(e){if(e.selectionStart)return e.selectionStart;if(document.selection){e.focus();var t=document.selection.createRange();if(null==t)return 0;var o=e.createTextRange(),n=o.duplicate();return o.moveToBookmark(t.getBookmark()),n.setEndPoint("EndToStart",o),n.text.length}return 0}function I(e){if(e.selectionEnd)return e.selectionEnd;if(document.selection){var t=document.selection.createRange();if(null==t)return 0;return e.createTextRange().text.indexOf(t.text)+t.text.length}}function W(){var e="";return window.getSelection?e=window.getSelection().toString():document.selection&&"Control"!==document.selection.type&&(e=document.selection.createRange().text),e}function j(e,t,o){if(void 0===o&&(o=t),e.setSelectionRange){e.focus();try{e.setSelectionRange(t,o)}catch(i){var n=e.parentNode,r=n.style.display;n.style.display="block",e.setSelectionRange(t,o),n.style.display=r}}else if(e.createTextRange){var i=e.createTextRange();i.collapse(!0),i.moveEnd("character",o),i.moveStart("character",t),i.select()}}function V(){var e=document.createElement("div");e.style.height="200px",e.style.width="100%";var t=document.createElement("div");t.style.boxSizing="content-box",t.style.height="150px",t.style.left="0px",t.style.overflow="hidden",t.style.position="absolute",t.style.top="0px",t.style.width="200px",t.style.visibility="hidden",t.appendChild(e),(document.body||document.documentElement).appendChild(t);var o=e.offsetWidth;t.style.overflow="scroll";var n=e.offsetWidth;return o==n&&(n=t.clientWidth),(document.body||document.documentElement).removeChild(t),o-n}function B(){return void 0===le&&(le=V()),le}function F(e){return e.offsetWidth!==e.clientWidth}function z(e){return e.offsetHeight!==e.clientHeight}function Y(e,t,o){te()||oe()?(e.style.top=o,e.style.left=t):ne()?e.style["-webkit-transform"]="translate3d("+t+","+o+",0)":e.style.transform="translate3d("+t+","+o+",0)"}function U(e){var t;return e.style.transform&&""!==(t=e.style.transform)?["transform",t]:e.style["-webkit-transform"]&&""!==(t=e.style["-webkit-transform"])?["-webkit-transform",t]:-1}function G(e){e.style.transform&&""!==e.style.transform?e.style.transform="":e.style["-webkit-transform"]&&""!==e.style["-webkit-transform"]&&(e.style["-webkit-transform"]="")}function $(e){var t=["INPUT","SELECT","TEXTAREA"];return e&&(t.indexOf(e.nodeName)>-1||"true"===e.contentEditable)}function K(e){return $(e)&&e.className.indexOf("handsontableInput")==-1&&e.className.indexOf("copyPaste")==-1}Object.defineProperties(o,{getParent:{get:function(){return n}},closest:{get:function(){return r}},closestDown:{get:function(){return i}},isChildOf:{get:function(){return s}},isChildOfWebComponentTable:{get:function(){return a}},polymerWrap:{get:function(){return l}},polymerUnwrap:{get:function(){return u}},index:{get:function(){return c}},overlayContainsElement:{get:function(){return d}},hasClass:{get:function(){return f}},addClass:{get:function(){return p}},removeClass:{get:function(){return g}},removeTextNodes:{get:function(){return m}},empty:{get:function(){return w}},HTML_CHARACTERS:{get:function(){return ue}},fastInnerHTML:{get:function(){return v}},fastInnerText:{get:function(){return y}},isVisible:{get:function(){return b}},offset:{get:function(){return C}},getWindowScrollTop:{get:function(){return _}},getWindowScrollLeft:{get:function(){return R}},getScrollTop:{get:function(){return M}},getScrollLeft:{get:function(){return S}},getScrollableElement:{get:function(){return E}},getTrimmingContainer:{get:function(){return O}},getStyle:{get:function(){return T}},getComputedStyle:{get:function(){return k}},outerWidth:{get:function(){return x}},outerHeight:{get:function(){return H}},innerHeight:{get:function(){return D}},innerWidth:{get:function(){return A}},addEvent:{get:function(){return P}},removeEvent:{get:function(){return L}},getCaretPosition:{get:function(){return N}},getSelectionEndPosition:{get:function(){return I}},getSelectionText:{get:function(){return W}},setCaretPosition:{get:function(){return j}},getScrollbarWidth:{get:function(){return B}},hasVerticalScrollbar:{get:function(){return F}},hasHorizontalScrollbar:{get:function(){return z}},setOverlayPosition:{get:function(){return Y}},getCssTransform:{get:function(){return U}},resetCssTransform:{get:function(){return G}},isInput:{get:function(){return $}},isOutsideInput:{get:function(){return K}},__esModule:{value:!0}});var X,q,Z,J,Q,ee=(X=e("../browser"))&&X.__esModule&&X||{default:X},te=ee.isIE8,oe=ee.isIE9,ne=ee.isSafari,re=((q=e("../feature"))&&q.__esModule&&q||{default:q}).hasCaptionProblem,ie=!!document.documentElement.classList;if(ie){var se=function(){var e=document.createElement("div");return e.classList.add("test","test2"),e.classList.contains("test2")}();Z=function(e,t){return""!==t&&e.classList.contains(t)},J=function(e,t){var o=0;if("string"==typeof t&&(t=t.split(" ")),t=h(t),se)e.classList.add.apply(e.classList,t);else for(;t&&t[o];)e.classList.add(t[o]),o++},Q=function(e,t){var o=0;if("string"==typeof t&&(t=t.split(" ")),t=h(t),se)e.classList.remove.apply(e.classList,t);else for(;t&&t[o];)e.classList.remove(t[o]),o++}}else{var ae=function(e){return new RegExp("(\\s|^)"+e+"(\\s|$)")};Z=function(e,t){return!!e.className.match(ae(t))},J=function(e,t){var o=0,n=e.className;if("string"==typeof t&&(t=t.split(" ")),""===n)n=t.join(" ");else for(;t&&t[o];)ae(t[o]).test(n)||(n+=" "+t[o]),o++;e.className=n},Q=function(e,t){var o=0,n=e.className;for("string"==typeof t&&(t=t.split(" "));t&&t[o];)n=n.replace(ae(t[o])," ").trim(),o++;e.className!==n&&(e.className=n)}}var le,ue=/(<(.*)>|&(.*);)/,ce=!!document.createTextNode("test").textContent},{"../browser":44,"../feature":49}],48:[function(e,t,o){"use strict";function n(e){e.isImmediatePropagationEnabled=!1,e.cancelBubble=!0}function r(e){return e.isImmediatePropagationEnabled===!1}function i(e){"function"==typeof e.stopPropagation?e.stopPropagation():e.cancelBubble=!0}function s(e){return e.pageX?e.pageX:e.clientX+f()}function a(e){return e.pageY?e.pageY:e.clientY+h()}function l(e){return 2===e.button}function u(e){return 0===e.button}Object.defineProperties(o,{stopImmediatePropagation:{get:function(){return n}},isImmediatePropagationStopped:{get:function(){return r}},stopPropagation:{get:function(){return i}},pageX:{get:function(){return s}},pageY:{get:function(){return a}},isRightClick:{get:function(){return l}},isLeftClick:{get:function(){return u}},__esModule:{value:!0}});var c,d=(c=e("element"))&&c.__esModule&&c||{default:c},h=d.getWindowScrollTop,f=d.getWindowScrollLeft},{element:47}],49:[function(e,t,o){"use strict";function n(e){return h.call(window,e)}function r(e){f.call(window,e)}function i(){return"ontouchstart"in window}function s(){var e=document.createElement("div");return!(!e.createShadowRoot||!e.createShadowRoot.toString().match(/\[native code\]/))}function a(){var e=document.createElement("TABLE");e.style.borderSpacing=0,e.style.borderWidth=0,e.style.padding=0;var t=document.createElement("TBODY");e.appendChild(t),t.appendChild(document.createElement("TR")),t.firstChild.appendChild(document.createElement("TD")),t.firstChild.firstChild.innerHTML="<tr><td>t<br>t</td></tr>";var o=document.createElement("CAPTION");o.innerHTML="c<br>c<br>c<br>c",o.style.padding=0,o.style.margin=0,e.insertBefore(o,t),document.body.appendChild(e),g=e.offsetHeight<2*e.lastChild.offsetHeight,document.body.removeChild(e)}function l(){return void 0===g&&a(),g}function u(e){var t=void 0!==arguments[1]?arguments[1]:{};return m?m:m="object"==typeof Intl?new Intl.Collator(e,t).compare:"function"==typeof String.prototype.localeCompare?function(e,t){return(e+"").localeCompare(t)}:function(e,t){return e===t?0:e>t?-1:1}}Object.defineProperties(o,{requestAnimationFrame:{get:function(){return n}},cancelAnimationFrame:{get:function(){return r}},isTouchSupported:{get:function(){return i}},isWebComponentSupportedNatively:{get:function(){return s}},hasCaptionProblem:{get:function(){return l}},getComparisonFunction:{get:function(){return u}},__esModule:{value:!0}});for(var c=0,d=["ms","moz","webkit","o"],h=window.requestAnimationFrame,f=window.cancelAnimationFrame,p=0;p<d.length&&!h;++p)h=window[d[p]+"RequestAnimationFrame"],
34
- f=window[d[p]+"CancelAnimationFrame"]||window[d[p]+"CancelRequestAnimationFrame"];h||(h=function(e){var t=(new Date).getTime(),o=Math.max(0,16-(t-c)),n=window.setTimeout(function(){e(t+o)},o);return c=t+o,n}),f||(f=function(e){clearTimeout(e)});var g,m},{}],50:[function(e,t,o){"use strict";function n(e){return"function"==typeof e}function r(e,t){return function(){return e.apply(t,arguments)}}function i(e){function t(){var t=this,s=arguments,a=Date.now(),l=!1;r.lastCallThrottled=!0,n||(n=a,l=!0);var u=o-(a-n);return l?(r.lastCallThrottled=!1,e.apply(this,s)):(i&&clearTimeout(i),i=setTimeout(function(){r.lastCallThrottled=!1,e.apply(t,s),n=0,i=void 0},u)),r}var o=void 0!==arguments[1]?arguments[1]:200,n=0,r={lastCallThrottled:!0},i=null;return t}function s(e){function t(){a=r}function o(){return a?(a--,e.apply(this,arguments)):s.apply(this,arguments)}var n=void 0!==arguments[1]?arguments[1]:200,r=void 0!==arguments[2]?arguments[2]:10,s=i(e,n),a=r;return o.clearHits=t,o}function a(e){function t(){var t=this,i=arguments;return r&&clearTimeout(r),r=setTimeout(function(){o=e.apply(t,i)},n),o}var o,n=void 0!==arguments[1]?arguments[1]:200,r=null;return t}function l(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var o=e,n=o[0],r=Array.prototype.slice.call(o,1);return function(){return f(r,function(e,t){return t(e)},n.apply(this,arguments))}}function u(e){for(var t=[],o=1;o<arguments.length;o++)t[o-1]=arguments[o];return function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return e.apply(this,t.concat(o))}}function c(e){function t(n){return function(){for(var r=[],i=0;i<arguments.length;i++)r[i]=arguments[i];var s=n.concat(r);return s.length>=o?e.apply(this,s):t(s)}}var o=e.length;return t([])}function d(e){function t(n){return function(){for(var r=[],i=0;i<arguments.length;i++)r[i]=arguments[i];var s=n.concat(r.reverse());return s.length>=o?e.apply(this,s):t(s)}}var o=e.length;return t([])}Object.defineProperties(o,{isFunction:{get:function(){return n}},proxy:{get:function(){return r}},throttle:{get:function(){return i}},throttleAfterHits:{get:function(){return s}},debounce:{get:function(){return a}},pipe:{get:function(){return l}},partial:{get:function(){return u}},curry:{get:function(){return c}},curryRight:{get:function(){return d}},__esModule:{value:!0}});var h,f=((h=e("array"))&&h.__esModule&&h||{default:h}).arrayReduce},{array:43}],51:[function(e,t,o){"use strict";function n(e){switch(typeof e){case"string":case"number":return e+"";case"object":return null===e?"":e.toString();case"undefined":return"";default:return e.toString()}}function r(e){return void 0!==e}function i(e){return void 0===e}function s(e){return null===e||""===e||i(e)}Object.defineProperties(o,{stringify:{get:function(){return n}},isDefined:{get:function(){return r}},isUndefined:{get:function(){return i}},isEmpty:{get:function(){return s}},__esModule:{value:!0}})},{}],52:[function(e,t,o){"use strict";function n(e){var t=typeof e;return"number"==t?!isNaN(e)&&isFinite(e):"string"==t?!!e.length&&(1==e.length?/\d/.test(e):/^\s*[+-]?\s*(?:(?:\d+(?:\.\d+)?(?:e[+-]?\d+)?)|(?:0x[a-f\d]+))\s*$/i.test(e)):"object"==t&&!(!e||"number"!=typeof e.valueOf()||e instanceof Date)}function r(e,t,o){var n=-1;for("function"==typeof t?(o=t,t=e):n=e-1;++n<=t&&o(n)!==!1;);}function i(e,t,o){var n=e+1;for("function"==typeof t&&(o=t,t=0);--n>=t&&o(n)!==!1;);}function s(e,t){return t=parseInt(t.toString().replace("%",""),10),t=parseInt(e*t/100)}Object.defineProperties(o,{isNumeric:{get:function(){return n}},rangeEach:{get:function(){return r}},rangeEachReverse:{get:function(){return i}},valueAccordingPercent:{get:function(){return s}},__esModule:{value:!0}})},{}],53:[function(e,t,o){"use strict";function n(e){var t;return Array.isArray(e)?t=[]:(t={},p(e,function(e,o){"__children"!==o&&(e&&"object"==typeof e&&!Array.isArray(e)?t[o]=n(e):Array.isArray(e)?e.length&&"object"==typeof e[0]&&!Array.isArray(e[0])?t[o]=[n(e[0])]:t[o]=[]:t[o]=null)})),t}function r(e,t){return t.prototype.constructor=t,e.prototype=new t,e.prototype.constructor=e,e}function i(e,t){return p(t,function(t,o){e[o]=t}),e}function s(e,t){p(t,function(o,n){t[n]&&"object"==typeof t[n]?(e[n]||(Array.isArray(t[n])?e[n]=[]:"[object Date]"===Object.prototype.toString.call(t[n])?e[n]=t[n]:e[n]={}),s(e[n],t[n])):e[n]=t[n]})}function a(e){return"object"==typeof e?JSON.parse(JSON.stringify(e)):e}function l(e){var t={};return p(e,function(e,o){t[o]=e}),t}function u(e){for(var t=[],o=1;o<arguments.length;o++)t[o-1]=arguments[o];return e.MIXINS||(e.MIXINS=[]),y(t,function(t){e.MIXINS.push(t.MIXIN_NAME),p(t,function(t,o){if(void 0!==e.prototype[o])throw new Error("Mixin conflict. Property '"+o+"' already exist and cannot be overwritten.");if("function"==typeof t)e.prototype[o]=t;else{Object.defineProperty(e.prototype,o,{get:function(e,t){e="_"+e;var o=function(e){return(Array.isArray(e)||d(e))&&(e=a(e)),e};return function(){return void 0===this[e]&&(this[e]=o(t)),this[e]}}(o,t),set:function(e){return e="_"+e,function(t){this[e]=t}}(o),configurable:!0})}})}),e}function c(e,t){return JSON.stringify(e)===JSON.stringify(t)}function d(e){return"[object Object]"==Object.prototype.toString.call(e)}function h(e){var t;if("object"==typeof e.__proto__)t=e.__proto__;else{var o,n=e.constructor;"function"==typeof e.constructor&&(o=n,delete e.constructor&&(n=e.constructor,e.constructor=o)),t=n?n.prototype:null}return t}function f(e,t,o,n){n.value=o,n.writable=n.writable!==!1,n.enumerable=n.enumerable!==!1,n.configurable=n.configurable!==!1,Object.defineProperty(e,t,n)}function p(e,t){for(var o in e)if((!e.hasOwnProperty||e.hasOwnProperty&&e.hasOwnProperty(o))&&t(e[o],o,e)===!1)break;return e}function g(e,t){var o=t.split("."),n=e;return p(o,function(e){if(void 0===(n=n[e]))return n=void 0,!1}),n}function m(e){if(!d(e))return 0;var t=function(e){var o=0;return d(e)?p(e,function(e){o+=t(e)}):o++,o};return t(e)}function w(e){var t,o=void 0!==arguments[1]?arguments[1]:"value",n="_"+o,r=(t={},Object.defineProperty(t,"_touched",{value:!1,configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(t,n,{value:e,configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(t,"isTouched",{value:function(){return this._touched},configurable:!0,enumerable:!0,writable:!0}),t);return Object.defineProperty(r,o,{get:function(){return this[n]},set:function(e){this._touched=!0,this[n]=e},enumerable:!0,configurable:!0}),r}Object.defineProperties(o,{duckSchema:{get:function(){return n}},inherit:{get:function(){return r}},extend:{get:function(){return i}},deepExtend:{get:function(){return s}},deepClone:{get:function(){return a}},clone:{get:function(){return l}},mixin:{get:function(){return u}},isObjectEquals:{get:function(){return c}},isObject:{get:function(){return d}},getPrototypeOf:{get:function(){return h}},defineGetter:{get:function(){return f}},objectEach:{get:function(){return p}},getProperty:{get:function(){return g}},deepObjectSize:{get:function(){return m}},createObjectPropListener:{get:function(){return w}},__esModule:{value:!0}});var v,y=((v=e("array"))&&v.__esModule&&v||{default:v}).arrayEach},{array:43}],54:[function(e,t,o){"use strict";function n(e,t){function o(){}i(o,e);for(var n=0,r=t.length;n<r;n++)o.prototype[t[n]]=void 0;return o}Object.defineProperties(o,{columnFactory:{get:function(){return n}},__esModule:{value:!0}});var r,i=((r=e("object"))&&r.__esModule&&r||{default:r}).inherit},{object:53}],55:[function(e,t,o){"use strict";function n(e){return e[0].toUpperCase()+e.substr(1)}function r(e,t){var o=!0;return g(t.length-1,function(n){if(e.charAt(n)!==t.charAt(n))return o=!1,!1}),o}function i(e,t){var o=!0,n=t.length-1,r=e.length-1;return g(n,function(i){var s=r-i,a=n-i;if(e.charAt(s)!==t.charAt(a))return o=!1,!1}),o}function s(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var o=[],n=e.length;n--;){var r=p(e[n]).toLowerCase();o.indexOf(r)===-1&&o.push(r)}return 1===o.length}function a(){function e(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)}return e()+e()+e()+e()}function l(e){return/^([0-9][0-9]?\%$)|(^100\%$)/.test(e)}function u(e){var t=void 0!==arguments[1]?arguments[1]:{};return(e+"").replace(/(?:\\)?\[([^\[\]]+)]/g,function(e,o){return"\\"===e.charAt(0)?e.substr(1,e.length-1):void 0===t[o]?"":t[o]})}function c(e,t){var o=void 0!==arguments[2]?arguments[2]:" ";if(e+="",e.length>=t)return e;o=String(o),o.length||(o=" ");var n=t-e.length,r=Math.ceil(n/o.length),i="";return g(r,function(e){i+=o}),(i=i.slice(0,n))+e}function d(e){return e+="",e.replace(m,"")}Object.defineProperties(o,{toUpperCaseFirst:{get:function(){return n}},startsWith:{get:function(){return r}},endsWith:{get:function(){return i}},equalsIgnoreCase:{get:function(){return s}},randomString:{get:function(){return a}},isPercentValue:{get:function(){return l}},substitute:{get:function(){return u}},padStart:{get:function(){return c}},stripTags:{get:function(){return d}},__esModule:{value:!0}});var h,f,p=((h=e("mixed"))&&h.__esModule&&h||{default:h}).stringify,g=((f=e("number"))&&f.__esModule&&f||{default:f}).rangeEach,m=/<\/?\w+\/?>|<\w+[\s|\/][^>]*>/gi},{mixed:51,number:52}],56:[function(e,t,o){"use strict";function n(e){return 32==e||e>=48&&e<=57||e>=96&&e<=111||e>=186&&e<=192||e>=219&&e<=222||e>=226||e>=65&&e<=90}function r(e){return[u.ARROW_DOWN,u.ARROW_UP,u.ARROW_LEFT,u.ARROW_RIGHT,u.HOME,u.END,u.DELETE,u.BACKSPACE,u.F1,u.F2,u.F3,u.F4,u.F5,u.F6,u.F7,u.F8,u.F9,u.F10,u.F11,u.F12,u.TAB,u.PAGE_DOWN,u.PAGE_UP,u.ENTER,u.ESCAPE,u.SHIFT,u.CAPS_LOCK,u.ALT].indexOf(e)!==-1}function i(e){return[u.CONTROL_LEFT,224,u.COMMAND_LEFT,u.COMMAND_RIGHT].indexOf(e)!==-1}function s(e,t){var o=t.split("|"),n=!1;return l(o,function(t){if(e===u[t])return n=!0,!1}),n}Object.defineProperties(o,{KEY_CODES:{get:function(){return u}},isPrintableChar:{get:function(){return n}},isMetaKey:{get:function(){return r}},isCtrlKey:{get:function(){return i}},isKey:{get:function(){return s}},__esModule:{value:!0}});var a,l=((a=e("array"))&&a.__esModule&&a||{default:a}).arrayEach,u={MOUSE_LEFT:1,MOUSE_RIGHT:3,MOUSE_MIDDLE:2,BACKSPACE:8,COMMA:188,INSERT:45,DELETE:46,END:35,ENTER:13,ESCAPE:27,CONTROL_LEFT:91,COMMAND_LEFT:17,COMMAND_RIGHT:93,ALT:18,HOME:36,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,SPACE:32,SHIFT:16,CAPS_LOCK:20,TAB:9,ARROW_RIGHT:39,ARROW_LEFT:37,ARROW_UP:38,ARROW_DOWN:40,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,A:65,X:88,C:67,V:86}},{array:43}],57:[function(e,t,o){"use strict";Object.defineProperties(o,{arrayMapper:{get:function(){return p}},__esModule:{value:!0}});var n,r,i,s,a=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,l=(r=e("helpers/array"))&&r.__esModule&&r||{default:r},u=(l.arrayEach,l.arrayReduce),c=l.arrayMap,d=l.arrayMax,h=((i=e("helpers/object"))&&i.__esModule&&i||{default:i}).defineGetter,f=((s=e("helpers/number"))&&s.__esModule&&s||{default:s}).rangeEach,p={_arrayMap:[],getValueByIndex:function(e){var t;return void 0===(t=this._arrayMap[e])?null:t},getIndexByValue:function(e){var t;return(t=this._arrayMap.indexOf(e))===-1?null:t},insertItems:function(e){var t=void 0!==arguments[1]?arguments[1]:1,o=this,n=d(this._arrayMap)+1,r=[];return f(t-1,function(t){r.push(o._arrayMap.splice(e+t,0,n+t))}),r},removeItems:function(e){var t=void 0!==arguments[1]?arguments[1]:1,o=this,n=[];if(Array.isArray(e)){var r=[].concat(this._arrayMap);e.sort(function(e,t){return t-e}),n=u(e,function(e,t){return o._arrayMap.splice(t,1),e.concat(r.slice(t,t+1))},[])}else n=this._arrayMap.splice(e,t);return n},unshiftItems:function(e){function t(e){return u(n,function(t,o){return e>o&&t++,t},0)}var o=void 0!==arguments[1]?arguments[1]:1,n=this.removeItems(e,o);this._arrayMap=c(this._arrayMap,function(e,o){var n=t(e);return n&&(e-=n),e})},shiftItems:function(e){var t=void 0!==arguments[1]?arguments[1]:1,o=this;this._arrayMap=c(this._arrayMap,function(o){return o>=e&&(o+=t),o}),f(t-1,function(t){o._arrayMap.splice(e+t,0,e+t)})},clearMap:function(){this._arrayMap.length=0}};h(p,"MIXIN_NAME","arrayMapper",{writable:!1,enumerable:!1}),a.utils.arrayMapper=p},{browser:24,"helpers/array":43,"helpers/number":52,"helpers/object":53}],58:[function(e,t,o){"use strict";Object.defineProperties(o,{localHooks:{get:function(){return u}},__esModule:{value:!0}});var n,r,i,s=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,a=((r=e("helpers/array"))&&r.__esModule&&r||{default:r}).arrayEach,l=((i=e("helpers/object"))&&i.__esModule&&i||{default:i}).defineGetter,u={_localHooks:Object.create(null),addLocalHook:function(e,t){this._localHooks[e]||(this._localHooks[e]=[]),this._localHooks[e].push(t)},runLocalHooks:function(e){for(var t=[],o=1;o<arguments.length;o++)t[o-1]=arguments[o];var n=this;this._localHooks[e]&&a(this._localHooks[e],function(e){return e.apply(n,t)})},clearLocalHooks:function(){this._localHooks={}}};l(u,"MIXIN_NAME","localHooks",{writable:!1,enumerable:!1}),s.utils.localHooks=u},{browser:24,"helpers/array":43,"helpers/object":53}],59:[function(e,t,o){"use strict";function n(){function e(e){return null!==e&&!o(e)&&("string"==typeof e||"number"==typeof e)}function t(e){return null!==e&&("object"==typeof e||"function"==typeof e)}function o(e){return e!==e}var n={arrayMap:[],weakMap:new WeakMap};return{get:function(o){return e(o)?n.arrayMap[o]:t(o)?n.weakMap.get(o):void 0},set:function(o,r){if(e(o))n.arrayMap[o]=r;else{if(!t(o))throw new Error("Invalid key type");n.weakMap.set(o,r)}},delete:function(o){e(o)?delete n.arrayMap[o]:t(o)&&n.weakMap.delete(o)}}}Object.defineProperties(o,{MultiMap:{get:function(){return n}},__esModule:{value:!0}}),window.MultiMap=n},{}],60:[function(e,t,o){"use strict";Object.defineProperties(o,{Hooks:{get:function(){return l}},__esModule:{value:!0}});var n,r,i=["afterCellMetaReset","afterChange","afterChangesObserved","afterContextMenuDefaultOptions","beforeContextMenuSetItems","afterDropdownMenuDefaultOptions","beforeDropdownMenuSetItems","afterContextMenuHide","afterContextMenuShow","afterCopyLimit","beforeCreateCol","afterCreateCol","beforeCreateRow","afterCreateRow","afterDeselect","afterDestroy","afterDocumentKeyDown","afterGetCellMeta","afterGetColHeader","afterGetRowHeader","afterInit","afterLoadData","afterMomentumScroll","afterOnCellCornerMouseDown","afterOnCellCornerDblClick","afterOnCellMouseDown","afterOnCellMouseOver","afterOnCellMouseOut","afterRemoveCol","afterRemoveRow","afterRender","beforeRenderer","afterRenderer","afterScrollHorizontally","afterScrollVertically","afterSelection","afterSelectionByProp","afterSelectionEnd","afterSelectionEndByProp","afterSetCellMeta","afterSetDataAtCell","afterSetDataAtRowProp","afterUpdateSettings","afterValidate","beforeAutofill","beforeCellAlignment","beforeChange","beforeChangeRender","beforeDrawBorders","beforeGetCellMeta","beforeInit","beforeInitWalkontable","beforeKeyDown","beforeOnCellMouseDown","beforeOnCellMouseOver","beforeOnCellMouseOut","beforeRemoveCol","beforeRemoveRow","beforeRender","beforeSetRangeStart","beforeSetRangeEnd","beforeTouchScroll","beforeValidate","beforeValueRender","construct","init","modifyCol","unmodifyCol","unmodifyRow","modifyColHeader","modifyColWidth","modifyRow","modifyRowHeader","modifyRowHeight","modifyData","modifyRowData","persistentStateLoad","persistentStateReset","persistentStateSave","beforeColumnSort","afterColumnSort","modifyAutofillRange","modifyCopyableRange","beforeCut","afterCut","beforeCopy","afterCopy","beforePaste","afterPaste","beforeColumnMove","afterColumnMove","beforeRowMove","afterRowMove","beforeColumnResize","afterColumnResize","beforeRowResize","afterRowResize","afterGetColumnHeaderRenderers","afterGetRowHeaderRenderers","beforeStretchingColumnWidth","beforeFilter","afterFilter","modifyColumnHeaderHeight","beforeUndo","afterUndo","beforeRedo","afterRedo","modifyRowHeaderWidth","beforeAutofillInsidePopulate","modifyTransformStart","modifyTransformEnd","afterModifyTransformStart","afterModifyTransformEnd","beforeValueRender","afterViewportRowCalculatorOverride","afterViewportColumnCalculatorOverride","afterPluginsInitialized","manualRowHeights","skipLengthCache","afterTrimRow","afterUntrimRow","afterDropdownMenuShow","afterDropdownMenuHide","hiddenRow","hiddenColumn","beforeAddChild","afterAddChild","beforeDetachChild","afterDetachChild","afterBeginEditing"],s=((n=e("helpers/array"))&&n.__esModule&&n||{default:n}).arrayEach,a=((r=e("helpers/object"))&&r.__esModule&&r||{default:r}).objectEach,l=function(){this.globalBucket=this.createEmptyBucket()};$traceurRuntime.createClass(l,{createEmptyBucket:function(){var e=Object.create(null);return s(i,function(t){return e[t]=[]}),e},getBucket:function(){var e=void 0!==arguments[0]?arguments[0]:null;return e?(e.pluginHookBucket||(e.pluginHookBucket=this.createEmptyBucket()),e.pluginHookBucket):this.globalBucket},add:function(e,t){var o=void 0!==arguments[2]?arguments[2]:null,n=this;if(Array.isArray(t))s(t,function(t){return n.add(e,t,o)});else{var r=this.getBucket(o);if(void 0===r[e]&&(this.register(e),r[e]=[]),t.skip=!1,r[e].indexOf(t)===-1){var i=!1;t.initialHook&&s(r[e],function(o,n){if(o.initialHook)return r[e][n]=t,i=!0,!1}),i||r[e].push(t)}}return this},once:function(e,t){var o=void 0!==arguments[2]?arguments[2]:null,n=this;Array.isArray(t)?s(t,function(t){return n.once(e,t,o)}):(t.runOnce=!0,this.add(e,t,o))},remove:function(e,t){var o=void 0!==arguments[2]?arguments[2]:null,n=this.getBucket(o);return void 0!==n[e]&&n[e].indexOf(t)>=0&&(t.skip=!0,!0)},has:function(e){var t=void 0!==arguments[1]?arguments[1]:null,o=this.getBucket(t);return!(void 0===o[e]||!o[e].length)},run:function(e,t,o,n,r,i,s,a){var l=this.globalBucket[t],u=-1,c=l?l.length:0;if(c)for(;++u<c;)if(l[u]&&!l[u].skip){var d=l[u].call(e,o,n,r,i,s,a);void 0!==d&&(o=d),l[u]&&l[u].runOnce&&this.remove(t,l[u])}var h=this.getBucket(e)[t],f=-1,p=h?h.length:0;if(p)for(;++f<p;)if(h[f]&&!h[f].skip){var g=h[f].call(e,o,n,r,i,s,a);void 0!==g&&(o=g),h[f]&&h[f].runOnce&&this.remove(t,h[f],e)}return o},destroy:function(){var e=void 0!==arguments[0]?arguments[0]:null;a(this.getBucket(e),function(e,t,o){return o[t].length=0})},register:function(e){this.isRegistered(e)||i.push(e)},deregister:function(e){this.isRegistered(e)&&i.splice(i.indexOf(e),1)},isRegistered:function(e){return i.indexOf(e)>=0},getRegistered:function(){return i}},{})},{"helpers/array":43,"helpers/object":53}],61:[function(e,t,o){"use strict";function n(e,t){e=h(e),c.plugins[e]=t,c.hooks.add("construct",function(){var o;f.has(this)||f.set(this,{}),o=f.get(this),o[e]||(o[e]=new t(this))}),c.hooks.add("afterDestroy",function(){if(f.has(this)){d(f.get(this),function(e){return e.destroy()}),f.delete(this)}})}function r(e,t){if("string"!=typeof t)throw Error('Only strings can be passed as "plugin" parameter');var o=h(t);if(f.has(e)&&f.get(e)[o])return f.get(e)[o]}function i(e){return f.has(e)?Object.keys(f.get(e)):[]}function s(e,t){var o=null;return f.has(e)&&d(f.get(e),function(e,n){e===t&&(o=n)}),o}Object.defineProperties(o,{registerPlugin:{get:function(){return n}},getPlugin:{get:function(){return r}},getRegistredPluginNames:{get:function(){return i}},getPluginName:{get:function(){return s}},__esModule:{value:!0}});var a,l,u,c=((a=e("browser"))&&a.__esModule&&a||{default:a}).default,d=((l=e("helpers/object"))&&l.__esModule&&l||{default:l}).objectEach,h=((u=e("helpers/string"))&&u.__esModule&&u||{default:u}).toUpperCaseFirst,f=new WeakMap},{browser:24,"helpers/object":53,"helpers/string":55}],62:[function(e,t,o){"use strict";Object.defineProperties(o,{default:{get:function(){return C}},__esModule:{value:!0}});var n,r,i,s,a,l=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,u=(r=e("helpers/object"))&&r.__esModule&&r||{default:r},c=u.defineGetter,d=u.objectEach,h=((i=e("helpers/array"))&&i.__esModule&&i||{default:i}).arrayEach,f=(s=e("utils/recordTranslator"))&&s.__esModule&&s||{default:s},p=(f.registerIdentity,f.getTranslator),g=(a=e("plugins"))&&a.__esModule&&a||{default:a},m=g.getRegistredPluginNames,w=g.getPluginName,v=new WeakMap,y=null,b=function(e){var t=this;c(this,"hot",e,{writable:!1}),c(this,"t",p(e),{writable:!1}),v.set(this,{hooks:{}}),y=null,this.pluginName=null,this.pluginsInitializedCallbacks=[],this.isPluginsReady=!1,this.enabled=!1,this.initialized=!1,this.hot.addHook("afterPluginsInitialized",function(){return t.onAfterPluginsInitialized()}),this.hot.addHook("afterUpdateSettings",function(){return t.onUpdateSettings()}),this.hot.addHook("beforeInit",function(){return t.init()})};$traceurRuntime.createClass(b,{init:function(){this.pluginName=w(this.hot,this),this.isEnabled&&this.isEnabled()&&this.enablePlugin(),y||(y=m(this.hot)),y.indexOf(this.pluginName)>=0&&y.splice(y.indexOf(this.pluginName),1),y.length||this.hot.runHooks("afterPluginsInitialized"),this.initialized=!0},enablePlugin:function(){this.enabled=!0},disablePlugin:function(){this.eventManager&&this.eventManager.clear(),this.clearHooks(),this.enabled=!1},addHook:function(e,t){var o=v.get(this).hooks[e]=v.get(this).hooks[e]||[];this.hot.addHook(e,t),o.push(t),v.get(this).hooks[e]=o},removeHooks:function(e){var t=this;h(v.get(this).hooks[e]||[],function(o){t.hot.removeHook(e,o)})},clearHooks:function(){var e=this,t=v.get(this).hooks;d(t,function(t,o){return e.removeHooks(o)}),t.length=0},callOnPluginsReady:function(e){this.isPluginsReady?e():this.pluginsInitializedCallbacks.push(e)},onAfterPluginsInitialized:function(){h(this.pluginsInitializedCallbacks,function(e){return e()}),this.pluginsInitializedCallbacks.length=0,this.isPluginsReady=!0},onUpdateSettings:function(){this.isEnabled&&(this.enabled&&!this.isEnabled()&&this.disablePlugin(),!this.enabled&&this.isEnabled()&&this.enablePlugin(),this.enabled&&this.isEnabled()&&this.updatePlugin())},updatePlugin:function(){},destroy:function(){var e=this;this.eventManager&&this.eventManager.destroy(),this.clearHooks(),d(this,function(t,o){"hot"!==o&&"t"!==o&&(e[o]=null)}),delete this.t,delete this.hot}},{});var C=b;l.plugins.BasePlugin=b},{browser:24,"helpers/array":43,"helpers/object":53,plugins:61,"utils/recordTranslator":130}],63:[function(e,t,o){"use strict";Object.defineProperties(o,{AutoColumnSize:{get:function(){return L}},__esModule:{value:!0}});var n,r,i,s,a,l,u,c,d,h,f,p=((n=e("_base"))&&n.__esModule&&n||{default:n}).default,g=(r=e("helpers/array"))&&r.__esModule&&r||{default:r},m=g.arrayEach,w=g.arrayFilter,v=g.arrayReduce,y=g.arrayMap,b=(i=e("helpers/feature"))&&i.__esModule&&i||{default:i},C=b.cancelAnimationFrame,_=b.requestAnimationFrame,R=((s=e("helpers/dom/element"))&&s.__esModule&&s||{default:s}).isVisible,M=((a=e("utils/ghostTable"))&&a.__esModule&&a||{default:a}).GhostTable,S=(l=e("helpers/object"))&&l.__esModule&&l||{default:l},E=S.isObject,O=(S.objectEach,(u=e("helpers/number"))&&u.__esModule&&u||{default:u}),T=O.valueAccordingPercent,k=O.rangeEach,x=((c=e("plugins"))&&c.__esModule&&c||{default:c}).registerPlugin,H=((d=e("utils/samplesGenerator"))&&d.__esModule&&d||{default:d}).SamplesGenerator,D=((h=e("helpers/string"))&&h.__esModule&&h||{default:h}).isPercentValue,A=((f=e("3rdparty/walkontable/src/calculator/viewportColumns"))&&f.__esModule&&f||{default:f}).WalkontableViewportColumnsCalculator,P=new WeakMap,L=function(e){var t=this;$traceurRuntime.superConstructor(N).call(this,e),P.set(this,{cachedColumnHeaders:[]}),this.widths=[],this.ghostTable=new M(this.hot),this.samplesGenerator=new H(function(e,o){return t.hot.getDataAtCell(e,o)}),this.firstCalculation=!0,this.inProgress=!1,this.addHook("beforeColumnResize",function(e,o,n){return t.onBeforeColumnResize(e,o,n)})},N=L;$traceurRuntime.createClass(L,{isEnabled:function(){return this.hot.getSettings().autoColumnSize!==!1&&!this.hot.getSettings().colWidths},enablePlugin:function(){var e=this;if(!this.enabled){var t=this.hot.getSettings().autoColumnSize;t&&null!=t.useHeaders&&this.ghostTable.setSetting("useHeaders",t.useHeaders),this.addHook("afterLoadData",function(){return e.onAfterLoadData()}),this.addHook("beforeChange",function(t){return e.onBeforeChange(t)}),this.addHook("beforeRender",function(t){return e.onBeforeRender(t)}),this.addHook("modifyColWidth",function(t,o){return e.getColumnWidth(o,t)}),this.addHook("afterInit",function(){return e.onAfterInit()}),$traceurRuntime.superGet(this,N.prototype,"enablePlugin").call(this)}},updatePlugin:function(){var e=this.findColumnsWhereHeaderWasChanged();e.length&&this.clearCache(e),$traceurRuntime.superGet(this,N.prototype,"updatePlugin").call(this)},disablePlugin:function(){$traceurRuntime.superGet(this,N.prototype,"disablePlugin").call(this)},calculateColumnsWidth:function(){var e=void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countCols()-1},t=void 0!==arguments[1]?arguments[1]:{from:0,to:this.hot.countRows()-1},o=void 0!==arguments[2]&&arguments[2],n=this;"number"==typeof e&&(e={from:e,to:e}),"number"==typeof t&&(t={from:t,to:t}),k(e.from,e.to,function(e){if(o||void 0===n.widths[e]&&!n.hot._getColWidthFromSettings(e)){n.samplesGenerator.generateColumnSamples(e,t).forEach(function(e,t){return n.ghostTable.addColumn(t,e)})}}),this.ghostTable.columns.length&&(this.ghostTable.getWidths(function(e,t){return n.widths[e]=t}),this.ghostTable.clean())},calculateAllColumnsWidth:function(){var e=void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countRows()-1},t=this,o=0,n=this.hot.countCols()-1,r=null;this.inProgress=!0;var i=function(){if(!t.hot)return C(r),void(t.inProgress=!1);t.calculateColumnsWidth({from:o,to:Math.min(o+N.CALCULATION_STEP,n)},e),o=o+N.CALCULATION_STEP+1,o<n?r=_(i):(C(r),t.inProgress=!1,t.hot.view.wt.wtOverlays.adjustElementsSize(!0),t.hot.view.wt.wtOverlays.leftOverlay.needFullRender&&t.hot.view.wt.wtOverlays.leftOverlay.clone.draw())};this.firstCalculation&&this.getSyncCalculationLimit()&&(this.calculateColumnsWidth({from:0,to:this.getSyncCalculationLimit()},e),this.firstCalculation=!1,o=this.getSyncCalculationLimit()+1),o<n?i():this.inProgress=!1},setSamplingOptions:function(){var e=this.hot.getSettings().autoColumnSize,t=e&&e.hasOwnProperty("samplingRatio")?this.hot.getSettings().autoColumnSize.samplingRatio:void 0,o=e&&e.hasOwnProperty("allowSampleDuplicates")?this.hot.getSettings().autoColumnSize.allowSampleDuplicates:void 0;t&&!isNaN(t)&&this.samplesGenerator.setSampleCount(parseInt(t,10)),o&&this.samplesGenerator.setAllowDuplicates(o)},recalculateAllColumnsWidth:function(){this.hot.view&&R(this.hot.view.wt.wtTable.TABLE)&&(this.clearCache(),this.calculateAllColumnsWidth())},getSyncCalculationLimit:function(){var e=N.SYNC_CALCULATION_LIMIT,t=this.hot.countCols()-1;return E(this.hot.getSettings().autoColumnSize)&&(e=this.hot.getSettings().autoColumnSize.syncLimit,D(e)?e=T(t,e):e>>=0),Math.min(e,t)},getColumnWidth:function(e){var t=arguments[1],o=void 0===arguments[2]||arguments[2],n=t;return void 0===n&&(n=this.widths[e],o&&"number"==typeof n&&(n=Math.max(n,A.DEFAULT_WIDTH))),n},getFirstVisibleColumn:function(){var e=this.hot.view.wt;return e.wtViewport.columnsVisibleCalculator?e.wtTable.getFirstVisibleColumn():e.wtViewport.columnsRenderCalculator?e.wtTable.getFirstRenderedColumn():-1},getLastVisibleColumn:function(){var e=this.hot.view.wt;return e.wtViewport.columnsVisibleCalculator?e.wtTable.getLastVisibleColumn():e.wtViewport.columnsRenderCalculator?e.wtTable.getLastRenderedColumn():-1},findColumnsWhereHeaderWasChanged:function(){var e=this.hot.getColHeader(),t=P.get(this).cachedColumnHeaders;return v(e,function(e,o,n){var r=t.length;return(r-1<n||t[n]!==o)&&e.push(n),r-1<n?t.push(o):t[n]=o,e},[])},clearCache:function(){var e=void 0!==arguments[0]?arguments[0]:[],t=this;e.length?m(e,function(e){return t.widths[e]=void 0}):this.widths.length=0},isNeedRecalculate:function(){return!!w(this.widths,function(e){return void 0===e}).length},onBeforeRender:function(){var e=this.hot.renderCall;this.hot.countRows()&&(this.calculateColumnsWidth({from:this.getFirstVisibleColumn(),to:this.getLastVisibleColumn()},void 0,e),this.isNeedRecalculate()&&!this.inProgress&&this.calculateAllColumnsWidth())},onAfterLoadData:function(){var e=this;this.hot.view?this.recalculateAllColumnsWidth():setTimeout(function(){e.hot&&e.recalculateAllColumnsWidth()},0)},onBeforeChange:function(e){var t=this,o=y(e,function(e){var o=e,n=(o[0],o[1]);return t.hot.propToCol(n)});this.clearCache(o)},onBeforeColumnResize:function(e,t,o){return o&&(this.calculateColumnsWidth(e,void 0,!0),t=this.getColumnWidth(e,void 0,!1)),t},onAfterInit:function(){P.get(this).cachedColumnHeaders=this.hot.getColHeader()},destroy:function(){this.ghostTable.clean(),$traceurRuntime.superGet(this,N.prototype,"destroy").call(this)}},{get CALCULATION_STEP(){return 50},get SYNC_CALCULATION_LIMIT(){return 50}},p),x("autoColumnSize",L)},{"3rdparty/walkontable/src/calculator/viewportColumns":4,_base:62,"helpers/array":43,"helpers/dom/element":47,"helpers/feature":49,"helpers/number":52,"helpers/object":53,"helpers/string":55,plugins:61,"utils/ghostTable":128,"utils/samplesGenerator":131}],64:[function(e,t,o){"use strict";Object.defineProperties(o,{AutoRowSize:{get:function(){return k}},__esModule:{value:!0}});var n,r,i,s,a,l,u,c,d,h,f=((n=e("_base"))&&n.__esModule&&n||{default:n}).default,p=(r=e("helpers/array"))&&r.__esModule&&r||{default:r},g=(p.arrayEach,p.arrayFilter),m=(i=e("helpers/feature"))&&i.__esModule&&i||{default:i},w=m.cancelAnimationFrame,v=m.requestAnimationFrame,y=((s=e("helpers/dom/element"))&&s.__esModule&&s||{default:s}).isVisible,b=((a=e("utils/ghostTable"))&&a.__esModule&&a||{default:a}).GhostTable,C=(l=e("helpers/object"))&&l.__esModule&&l||{default:l},_=C.isObject,R=(C.objectEach,(u=e("helpers/number"))&&u.__esModule&&u||{default:u}),M=R.valueAccordingPercent,S=R.rangeEach,E=((c=e("plugins"))&&c.__esModule&&c||{default:c}).registerPlugin,O=((d=e("utils/samplesGenerator"))&&d.__esModule&&d||{default:d}).SamplesGenerator,T=((h=e("helpers/string"))&&h.__esModule&&h||{default:h}).isPercentValue,k=function(e){var t=this;$traceurRuntime.superConstructor(x).call(this,e),this.heights=[],this.ghostTable=new b(this.hot),this.samplesGenerator=new O(function(e,o){return e>=0?t.hot.getDataAtCell(e,o):e===-1?t.hot.getColHeader(o):null}),this.firstCalculation=!0,this.inProgress=!1,this.addHook("beforeRowResize",function(e,o,n){return t.onBeforeRowResize(e,o,n)})},x=k;$traceurRuntime.createClass(k,{isEnabled:function(){return this.hot.getSettings().autoRowSize===!0||_(this.hot.getSettings().autoRowSize)},enablePlugin:function(){var e=this;this.enabled||(this.setSamplingOptions(),this.addHook("afterLoadData",function(){return e.onAfterLoadData()}),this.addHook("beforeChange",function(t){return e.onBeforeChange(t)}),this.addHook("beforeColumnMove",function(){return e.recalculateAllRowsHeight()}),this.addHook("beforeColumnResize",function(){return e.recalculateAllRowsHeight()}),this.addHook("beforeColumnSort",function(){return e.clearCache()}),this.addHook("beforeRender",function(t){return e.onBeforeRender(t)}),this.addHook("beforeRowMove",function(t,o){return e.onBeforeRowMove(t,o)}),this.addHook("modifyRowHeight",function(t,o){return e.getRowHeight(o,t)}),this.addHook("modifyColumnHeaderHeight",function(){return e.getColumnHeaderHeight()}),$traceurRuntime.superGet(this,x.prototype,"enablePlugin").call(this))},disablePlugin:function(){$traceurRuntime.superGet(this,x.prototype,"disablePlugin").call(this)},calculateRowsHeight:function(){var e=void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countRows()-1},t=void 0!==arguments[1]?arguments[1]:{from:0,to:this.hot.countCols()-1},o=void 0!==arguments[2]&&arguments[2],n=this;if("number"==typeof e&&(e={from:e,to:e}),"number"==typeof t&&(t={from:t,to:t}),null!==this.hot.getColHeader(0)){var r=this.samplesGenerator.generateRowSamples(-1,t);this.ghostTable.addColumnHeadersRow(r.get(-1))}S(e.from,e.to,function(e){if(o||void 0===n.heights[e]){n.samplesGenerator.generateRowSamples(e,t).forEach(function(e,t){return n.ghostTable.addRow(t,e)})}}),
35
- this.ghostTable.rows.length&&(this.ghostTable.getHeights(function(e,t){return n.heights[e]=t}),this.ghostTable.clean())},calculateAllRowsHeight:function(){var e=void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countCols()-1},t=this,o=0,n=this.hot.countRows()-1,r=null;this.inProgress=!0;var i=function(){if(!t.hot)return w(r),void(t.inProgress=!1);t.calculateRowsHeight({from:o,to:Math.min(o+x.CALCULATION_STEP,n)},e),o=o+x.CALCULATION_STEP+1,o<n?r=v(i):(w(r),t.inProgress=!1,t.hot.view.wt.wtOverlays.adjustElementsSize(!0),t.hot.view.wt.wtOverlays.leftOverlay.needFullRender&&t.hot.view.wt.wtOverlays.leftOverlay.clone.draw())};this.firstCalculation&&this.getSyncCalculationLimit()&&(this.calculateRowsHeight({from:0,to:this.getSyncCalculationLimit()},e),this.firstCalculation=!1,o=this.getSyncCalculationLimit()+1),o<n?i():(this.inProgress=!1,this.hot.view.wt.wtOverlays.adjustElementsSize(!1))},setSamplingOptions:function(){var e=this.hot.getSettings().autoRowSize,t=e&&e.hasOwnProperty("samplingRatio")?this.hot.getSettings().autoRowSize.samplingRatio:void 0,o=e&&e.hasOwnProperty("allowSampleDuplicates")?this.hot.getSettings().autoRowSize.allowSampleDuplicates:void 0;t&&!isNaN(t)&&this.samplesGenerator.setSampleCount(parseInt(t,10)),o&&this.samplesGenerator.setAllowDuplicates(o)},recalculateAllRowsHeight:function(){y(this.hot.view.wt.wtTable.TABLE)&&(this.clearCache(),this.calculateAllRowsHeight())},getSyncCalculationLimit:function(){var e=x.SYNC_CALCULATION_LIMIT,t=this.hot.countRows()-1;return _(this.hot.getSettings().autoRowSize)&&(e=this.hot.getSettings().autoRowSize.syncLimit,T(e)?e=M(t,e):e>>=0),Math.min(e,t)},getRowHeight:function(e){var t=arguments[1],o=t;return void 0!==this.heights[e]&&this.heights[e]>(t||0)&&(o=this.heights[e]),o},getColumnHeaderHeight:function(){return this.heights[-1]},getFirstVisibleRow:function(){var e=this.hot.view.wt;return e.wtViewport.rowsVisibleCalculator?e.wtTable.getFirstVisibleRow():e.wtViewport.rowsRenderCalculator?e.wtTable.getFirstRenderedRow():-1},getLastVisibleRow:function(){var e=this.hot.view.wt;return e.wtViewport.rowsVisibleCalculator?e.wtTable.getLastVisibleRow():e.wtViewport.rowsRenderCalculator?e.wtTable.getLastRenderedRow():-1},clearCache:function(){this.heights.length=0,this.heights[-1]=void 0},clearCacheByRange:function(e){var t=this;"number"==typeof e&&(e={from:e,to:e}),S(Math.min(e.from,e.to),Math.max(e.from,e.to),function(e){return t.heights[e]=void 0})},isNeedRecalculate:function(){return!!g(this.heights,function(e){return void 0===e}).length},onBeforeRender:function(){var e=this.hot.renderCall;this.calculateRowsHeight({from:this.getFirstVisibleRow(),to:this.getLastVisibleRow()},void 0,e);var t=this.hot.getSettings().fixedRowsBottom;if(t){var o=this.hot.countRows()-1;this.calculateRowsHeight({from:o-t,to:o})}this.isNeedRecalculate()&&!this.inProgress&&this.calculateAllRowsHeight()},onBeforeRowMove:function(e,t){this.clearCacheByRange({from:e,to:t}),this.calculateAllRowsHeight()},onBeforeRowResize:function(e,t,o){return o&&(this.calculateRowsHeight(e,void 0,!0),t=this.getRowHeight(e)),t},onAfterLoadData:function(){var e=this;this.hot.view?this.recalculateAllRowsHeight():setTimeout(function(){e.hot&&e.recalculateAllRowsHeight()},0)},onBeforeChange:function(e){var t=null;1===e.length?t=e[0][0]:e.length>1&&(t={from:e[0][0],to:e[e.length-1][0]}),null!==t&&this.clearCacheByRange(t)},destroy:function(){this.ghostTable.clean(),$traceurRuntime.superGet(this,x.prototype,"destroy").call(this)}},{get CALCULATION_STEP(){return 50},get SYNC_CALCULATION_LIMIT(){return 500}},f),E("autoRowSize",k)},{_base:62,"helpers/array":43,"helpers/dom/element":47,"helpers/feature":49,"helpers/number":52,"helpers/object":53,"helpers/string":55,plugins:61,"utils/ghostTable":128,"utils/samplesGenerator":131}],65:[function(e,t,o){"use strict";Object.defineProperties(o,{Autofill:{get:function(){return E}},__esModule:{value:!0}});var n,r,i,s,a,l,u,c,d=((n=e("_base"))&&n.__esModule&&n||{default:n}).default,h=((r=e("browser"))&&r.__esModule&&r||{default:r}).default,f=((i=e("helpers/array"))&&i.__esModule&&i||{default:i}).arrayIncludes,p=(s=e("helpers/dom/element"))&&s.__esModule&&s||{default:s},g=p.offset,m=p.outerHeight,w=p.outerWidth,v=((a=e("eventManager"))&&a.__esModule&&a||{default:a}).eventManager,y=((l=e("plugins"))&&l.__esModule&&l||{default:l}).registerPlugin,b=((u=e("3rdparty/walkontable/src/cell/coords"))&&u.__esModule&&u||{default:u}).WalkontableCellCoords,C=(c=e("utils"))&&c.__esModule&&c||{default:c},_=C.getDeltas,R=C.getDragDirectionAndRange,M=C.DIRECTIONS,S=C.getMappedFillHandleSetting,E=function(e){$traceurRuntime.superConstructor(O).call(this,e),this.eventManager=v(this),this.addingStarted=!1,this.mouseDownOnCellCorner=!1,this.mouseDragOutside=!1,this.handleDraggedCells=0,this.directions=[],this.autoInsertRow=!1},O=E;$traceurRuntime.createClass(E,{isEnabled:function(){return this.hot.getSettings().fillHandle},enablePlugin:function(){var e=this;this.enabled||(this.mapSettings(),this.registerEvents(),this.addHook("afterOnCellCornerMouseDown",function(t){return e.onAfterCellCornerMouseDown(t)}),this.addHook("afterOnCellCornerDblClick",function(t){return e.onCellCornerDblClick(t)}),this.addHook("beforeOnCellMouseOver",function(t,o,n){return e.onBeforeCellMouseOver(o)}),$traceurRuntime.superGet(this,O.prototype,"enablePlugin").call(this))},updatePlugin:function(){this.disablePlugin(),this.enablePlugin(),$traceurRuntime.superGet(this,O.prototype,"updatePlugin").call(this)},disablePlugin:function(){this.clearMappedSettings(),$traceurRuntime.superGet(this,O.prototype,"disablePlugin").call(this)},getSelectionData:function(){var e={from:this.hot.getSelectedRange().from,to:this.hot.getSelectedRange().to};return this.hot.getData(e.from.row,e.from.col,e.to.row,e.to.col)},fillIn:function(){if(this.hot.view.wt.selections.fill.isEmpty())return!1;var e=this.hot.view.wt.selections.fill.getCorners();this.resetSelectionOfDraggedArea();var t=this.getCornersOfSelectedCells(),o=R(t,e),n=o.directionOfDrag,r=o.startOfDragCoords,i=o.endOfDragCoords;if(this.hot.runHooks("modifyAutofillRange",t,e),r&&r.row>-1&&r.col>-1){var s=this.getSelectionData(),a=_(r,i,s,n);this.hot.runHooks("beforeAutofill",r,i,s),this.hot.populateFromArray(r.row,r.col,s,i.row,i.col,this.pluginName+".fill",null,n,a),this.setSelection(e)}else this.hot.selection.refreshBorders();return!0},reduceSelectionAreaIfNeeded:function(e){return e.row<0&&(e.row=0),e.col<0&&(e.col=0),e},getCoordsOfDragAndDropBorders:function(e){var t,o=this.hot.getSelectedRange().getTopLeftCorner(),n=this.hot.getSelectedRange().getBottomRightCorner();if(f(this.directions,M.vertical)&&(n.row<e.row||o.row>e.row))t=new b(e.row,n.col);else{if(!f(this.directions,M.horizontal))return;t=new b(n.row,e.col)}return this.reduceSelectionAreaIfNeeded(t)},showBorder:function(e){var t=this.getCoordsOfDragAndDropBorders(e);t&&this.redrawBorders(t)},addRow:function(){var e=this;this.hot._registerTimeout(setTimeout(function(){e.hot.alter("insert_row",void 0,1,e.pluginName+".fill"),e.addingStarted=!1},200))},addNewRowIfNeeded:function(){if(this.hot.view.wt.selections.fill.cellRange&&this.addingStarted===!1&&this.autoInsertRow){var e=this.hot.getSelected(),t=this.hot.view.wt.selections.fill.getCorners(),o=this.hot.countRows();e[2]<o-1&&t[2]===o-1&&(this.addingStarted=!0,this.addRow())}},getCornersOfSelectedCells:function(){return this.hot.selection.isMultiple()?this.hot.view.wt.selections.area.getCorners():this.hot.view.wt.selections.current.getCorners()},getIndexOfLastAdjacentFilledInRow:function(e){for(var t,o=this.hot.getData(),n=this.hot.countRows(),r=e[2]+1;r<n;r++){for(var i=e[1];i<=e[3];i++){if(o[r][i])return-1}var s=o[r][e[1]-1],a=o[r][e[3]+1];(s||a)&&(t=r)}return t},addSelectionFromStartAreaToSpecificRowIndex:function(e,t){this.hot.view.wt.selections.fill.clear(),this.hot.view.wt.selections.fill.add(new b(e[0],e[1])),this.hot.view.wt.selections.fill.add(new b(t,e[3]))},setSelection:function(e){this.hot.selection.setRangeStart(new b(e[0],e[1])),this.hot.selection.setRangeEnd(new b(e[2],e[3]))},selectAdjacent:function(){var e=this.getCornersOfSelectedCells(),t=this.getIndexOfLastAdjacentFilledInRow(e);return t!==-1&&(this.addSelectionFromStartAreaToSpecificRowIndex(e,t),!0)},resetSelectionOfDraggedArea:function(){this.handleDraggedCells=0,this.hot.view.wt.selections.fill.clear()},redrawBorders:function(e){this.hot.view.wt.selections.fill.clear(),this.hot.view.wt.selections.fill.add(this.hot.getSelectedRange().from),this.hot.view.wt.selections.fill.add(this.hot.getSelectedRange().to),this.hot.view.wt.selections.fill.add(e),this.hot.view.render()},getIfMouseWasDraggedOutside:function(e){var t=g(this.hot.table).top-(window.pageYOffset||document.documentElement.scrollTop)+m(this.hot.table),o=g(this.hot.table).left-(window.pageXOffset||document.documentElement.scrollLeft)+w(this.hot.table);return e.clientY>t&&e.clientX<=o},registerEvents:function(){var e=this;this.eventManager.addEventListener(document.documentElement,"mouseup",function(){return e.onMouseUp()}),this.eventManager.addEventListener(document.documentElement,"mousemove",function(t){return e.onMouseMove(t)})},onCellCornerDblClick:function(){this.selectAdjacent()&&this.fillIn()},onAfterCellCornerMouseDown:function(){this.handleDraggedCells=1,this.mouseDownOnCellCorner=!0},onBeforeCellMouseOver:function(e){this.mouseDownOnCellCorner&&!this.hot.view.isMouseDown()&&this.handleDraggedCells&&(this.handleDraggedCells++,this.showBorder(e),this.addNewRowIfNeeded())},onMouseUp:function(){this.handleDraggedCells&&(this.handleDraggedCells>1&&this.fillIn(),this.handleDraggedCells=0,this.mouseDownOnCellCorner=!1)},onMouseMove:function(e){var t=this.getIfMouseWasDraggedOutside(e);this.addingStarted===!1&&this.handleDraggedCells>0&&t?(this.mouseDragOutside=!0,this.addingStarted=!0):this.mouseDragOutside=!1,this.mouseDragOutside&&this.autoInsertRow&&this.addRow()},clearMappedSettings:function(){this.directions.length=0,this.autoInsertRow=!1},mapSettings:function(){var e=S(this.hot.getSettings().fillHandle);this.directions=e.directions,this.autoInsertRow=e.autoInsertRow},destroy:function(){$traceurRuntime.superGet(this,O.prototype,"destroy").call(this)}},{},d),y("autofill",E),h.hooks.register("modifyAutofillRange"),h.hooks.register("beforeAutofill")},{"3rdparty/walkontable/src/cell/coords":6,_base:62,browser:24,eventManager:42,"helpers/array":43,"helpers/dom/element":47,plugins:61,utils:66}],66:[function(e,t,o){"use strict";function n(e,t,o,n){var r=o.length,i=o?o[0].length:0,s=[],a=t.row-e.row,l=t.col-e.col;if(["down","up"].indexOf(n)!==-1){for(var u=[],c=0;c<=l;c++){var d=parseInt(o[0][c],10),h=parseInt(o[r-1][c],10),f=("down"===n?h-d:d-h)/(r-1)||0;u.push(f)}s.push(u)}if(["right","left"].indexOf(n)!==-1)for(var p=0;p<=a;p++){var g=parseInt(o[p][0],10),m=parseInt(o[p][i-1],10),w=("right"===n?m-g:g-m)/(i-1)||0;s.push([w])}return s}function r(e,t){var o,n,r;return t[0]===e[0]&&t[1]<e[1]?(r="left",o=new WalkontableCellCoords(t[0],t[1]),n=new WalkontableCellCoords(t[2],e[1]-1)):t[0]===e[0]&&t[3]>e[3]?(r="right",o=new WalkontableCellCoords(t[0],e[3]+1),n=new WalkontableCellCoords(t[2],t[3])):t[0]<e[0]&&t[1]===e[1]?(r="up",o=new WalkontableCellCoords(t[0],t[1]),n=new WalkontableCellCoords(e[0]-1,t[3])):t[2]>e[2]&&t[1]===e[1]&&(r="down",o=new WalkontableCellCoords(e[2]+1,t[1]),n=new WalkontableCellCoords(t[2],t[3])),{directionOfDrag:r,startOfDragCoords:o,endOfDragCoords:n}}function i(e){var t={};return e===!0?(t.directions=Object.keys(c),t.autoInsertRow=!0):l(e)?(u(e.autoInsertRow)?e.direction===c.horizontal?t.autoInsertRow=!1:t.autoInsertRow=e.autoInsertRow:t.autoInsertRow=!1,u(e.direction)?t.directions=[e.direction]:t.directions=Object.keys(c)):"string"==typeof e?(t.directions=[e],t.autoInsertRow=!0):(t.directions=[],t.autoInsertRow=!1),t}Object.defineProperties(o,{DIRECTIONS:{get:function(){return c}},getDeltas:{get:function(){return n}},getDragDirectionAndRange:{get:function(){return r}},getMappedFillHandleSetting:{get:function(){return i}},__esModule:{value:!0}});var s,a,l=((s=e("helpers/object"))&&s.__esModule&&s||{default:s}).isObject,u=((a=e("helpers/mixed"))&&a.__esModule&&a||{default:a}).isDefined,c={horizontal:"horizontal",vertical:"vertical"}},{"helpers/mixed":51,"helpers/object":53}],67:[function(e,t,o){"use strict";Object.defineProperties(o,{ColumnSorting:{get:function(){return M}},__esModule:{value:!0}});var n,r,i,s,a,l,u,c,d=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,h=((r=e("moment"))&&r.__esModule&&r||{default:r}).default,f=(i=e("helpers/dom/element"))&&i.__esModule&&i||{default:i},p=f.addClass,g=f.hasClass,m=f.removeClass,w=(s=e("helpers/array"))&&s.__esModule&&s||{default:s},v=w.arrayMap,y=w.arrayReduce,b=((a=e("helpers/mixed"))&&a.__esModule&&a||{default:a}).isEmpty,C=((l=e("_base"))&&l.__esModule&&l||{default:l}).default,_=((u=e("plugins"))&&u.__esModule&&u||{default:u}).registerPlugin,R=((c=e("utils/sortingAlgorithms/mergeSort"))&&c.__esModule&&c||{default:c}).mergeSort;d.hooks.register("beforeColumnSort"),d.hooks.register("afterColumnSort");var M=function(e){$traceurRuntime.superConstructor(S).call(this,e),this.sortIndicators=[],this.lastSortedColumn=null,this.sortEmptyCells=!1},S=M;$traceurRuntime.createClass(M,{isEnabled:function(){return!!this.hot.getSettings().columnSorting},enablePlugin:function(){var e=this;if(!this.enabled){this.setPluginOptions();var t=this;this.hot.sortIndex=[],this.hot.sort=function(){var e=Array.prototype.slice.call(arguments);return t.sortByColumn.apply(t,e)},void 0===this.hot.getSettings().observeChanges&&this.enableObserveChangesPlugin(),this.addHook("afterTrimRow",function(t){return e.sort()}),this.addHook("afterUntrimRow",function(t){return e.sort()}),this.addHook("modifyRow",function(t){return e.translateRow(t)}),this.addHook("unmodifyRow",function(t){return e.untranslateRow(t)}),this.addHook("afterUpdateSettings",function(){return e.onAfterUpdateSettings()}),this.addHook("afterGetColHeader",function(t,o){return e.getColHeader(t,o)}),this.addHook("afterOnCellMouseDown",function(t,o){return e.onAfterOnCellMouseDown(t,o)}),this.addHook("afterCreateRow",function(){t.afterCreateRow.apply(t,arguments)}),this.addHook("afterRemoveRow",function(){t.afterRemoveRow.apply(t,arguments)}),this.addHook("afterInit",function(){return e.sortBySettings()}),this.addHook("afterLoadData",function(){e.hot.sortIndex=[],e.hot.view&&e.sortBySettings()}),this.hot.view&&this.sortBySettings(),$traceurRuntime.superGet(this,S.prototype,"enablePlugin").call(this)}},disablePlugin:function(){this.hot.sort=void 0,$traceurRuntime.superGet(this,S.prototype,"disablePlugin").call(this)},onAfterUpdateSettings:function(){this.sortBySettings()},sortBySettings:function(){var e,t,o=this.hot.getSettings().columnSorting,n=this.loadSortingState();void 0===n?(e=o.column,t=o.sortOrder):(e=n.sortColumn,t=n.sortOrder),"number"==typeof e&&(this.lastSortedColumn=e,this.sortByColumn(e,t))},setSortingColumn:function(e,t){if(void 0===e)return this.hot.sortColumn=void 0,void(this.hot.sortOrder=void 0);this.hot.sortColumn===e&&void 0===t?this.hot.sortOrder===!1?this.hot.sortOrder=void 0:this.hot.sortOrder=!this.hot.sortOrder:this.hot.sortOrder=void 0===t||t,this.hot.sortColumn=e},sortByColumn:function(e,t){if(this.setSortingColumn(e,t),void 0!==this.hot.sortColumn){d.hooks.run(this.hot,"beforeColumnSort",this.hot.sortColumn,this.hot.sortOrder)!==!1&&this.sort(),this.updateOrderClass(),this.updateSortIndicator(),d.hooks.run(this.hot,"afterColumnSort",this.hot.sortColumn,this.hot.sortOrder),this.hot.render(),this.saveSortingState()}},saveSortingState:function(){var e={};void 0!==this.hot.sortColumn&&(e.sortColumn=this.hot.sortColumn),void 0!==this.hot.sortOrder&&(e.sortOrder=this.hot.sortOrder),(e.hasOwnProperty("sortColumn")||e.hasOwnProperty("sortOrder"))&&d.hooks.run(this.hot,"persistentStateSave","columnSorting",e)},loadSortingState:function(){var e={};return d.hooks.run(this.hot,"persistentStateLoad","columnSorting",e),e.value},updateOrderClass:function(){var e;this.hot.sortOrder===!0?e="ascending":this.hot.sortOrder===!1&&(e="descending"),this.sortOrderClass=e},enableObserveChangesPlugin:function(){var e=this;this.hot._registerTimeout(setTimeout(function(){e.hot.updateSettings({observeChanges:!0})},0))},defaultSort:function(e,t){return function(o,n){return"string"==typeof o[1]&&(o[1]=o[1].toLowerCase()),"string"==typeof n[1]&&(n[1]=n[1].toLowerCase()),o[1]===n[1]?0:b(o[1])?b(n[1])?0:t.columnSorting.sortEmptyCells&&e?-1:1:b(n[1])?b(o[1])?0:t.columnSorting.sortEmptyCells&&e?1:-1:isNaN(o[1])&&!isNaN(n[1])?e?1:-1:!isNaN(o[1])&&isNaN(n[1])?e?-1:1:(isNaN(o[1])||isNaN(n[1])||(o[1]=parseFloat(o[1]),n[1]=parseFloat(n[1])),o[1]<n[1]?e?-1:1:o[1]>n[1]?e?1:-1:0)}},dateSort:function(e,t){return function(o,n){if(o[1]===n[1])return 0;if(b(o[1]))return b(n[1])?0:t.columnSorting.sortEmptyCells&&e?-1:1;if(b(n[1]))return b(o[1])?0:t.columnSorting.sortEmptyCells&&e?1:-1;var r=h(o[1],t.dateFormat),i=h(n[1],t.dateFormat);return r.isValid()?i.isValid()?i.isAfter(r)?e?-1:1:i.isBefore(r)?e?1:-1:0:-1:1}},numericSort:function(e,t){return function(o,n){var r=parseFloat(o[1]),i=parseFloat(n[1]);if(r===i||isNaN(r)&&isNaN(i))return 0;if(t.columnSorting.sortEmptyCells){if(b(o[1]))return e?-1:1;if(b(n[1]))return e?1:-1}return isNaN(r)?1:isNaN(i)?-1:r<i?e?-1:1:r>i?e?1:-1:0}},sort:function(){if(void 0===this.hot.sortOrder)return void(this.hot.sortIndex.length=0);var e,t,o=this.hot.getCellMeta(0,this.hot.sortColumn),n=this.hot.countEmptyRows();this.hot.sortingEnabled=!1,this.hot.sortIndex.length=0,void 0===o.columnSorting.sortEmptyCells&&(o.columnSorting={sortEmptyCells:this.sortEmptyCells}),t=this.hot.getSettings().maxRows===Number.POSITIVE_INFINITY?this.hot.countRows()-this.hot.getSettings().minSpareRows:this.hot.countRows()-n;for(var r=0,i=t;r<i;r++)this.hot.sortIndex.push([r,this.hot.getDataAtCell(r,this.hot.sortColumn)]);if(o.sortFunction)e=o.sortFunction;else switch(o.type){case"date":e=this.dateSort;break;case"numeric":e=this.numericSort;break;default:e=this.defaultSort}R(this.hot.sortIndex,e(this.hot.sortOrder,o));for(var s=this.hot.sortIndex.length;s<this.hot.countRows();s++)this.hot.sortIndex.push([s,this.hot.getDataAtCell(s,this.hot.sortColumn)]);this.hot.sortingEnabled=!0},updateSortIndicator:function(){if(void 0!==this.hot.sortOrder){var e=this.hot.getCellMeta(0,this.hot.sortColumn);this.sortIndicators[this.hot.sortColumn]=e.sortIndicator}},translateRow:function(e){return this.hot.sortingEnabled&&void 0!==this.hot.sortOrder&&this.hot.sortIndex&&this.hot.sortIndex.length&&this.hot.sortIndex[e]?this.hot.sortIndex[e][0]:e},untranslateRow:function(e){if(this.hot.sortingEnabled&&this.hot.sortIndex&&this.hot.sortIndex.length)for(var t=0;t<this.hot.sortIndex.length;t++)if(this.hot.sortIndex[t][0]==e)return t},getColHeader:function(e,t){if(e<0||!t.parentNode)return!1;var o=t.querySelector(".colHeader"),n=(t.getAttribute("colspan"),t.parentNode.parentNode.childNodes),r=Array.prototype.indexOf.call(n,t.parentNode);r-=n.length,o&&(this.hot.getSettings().columnSorting&&e>=0&&r===-1&&p(o,"columnSorting"),m(o,"descending"),m(o,"ascending"),this.sortIndicators[e]&&e===this.hot.sortColumn&&("ascending"===this.sortOrderClass?p(o,"ascending"):"descending"===this.sortOrderClass&&p(o,"descending")))},isSorted:function(){return void 0!==this.hot.sortColumn},afterCreateRow:function(e,t){if(this.isSorted()){for(var o=0;o<this.hot.sortIndex.length;o++)this.hot.sortIndex[o][0]>=e&&(this.hot.sortIndex[o][0]+=t);for(var o=0;o<t;o++)this.hot.sortIndex.splice(e+o,0,[e+o,this.hot.getSourceData()[e+o][this.hot.sortColumn+this.hot.colOffset()]]);this.saveSortingState()}},afterRemoveRow:function(e,t){function o(e){return y(n,function(t,o){return e>o&&t++,t},0)}if(this.isSorted()){var n=this.hot.sortIndex.splice(e,t);n=v(n,function(e){return e[0]}),this.hot.sortIndex=v(this.hot.sortIndex,function(e,t){var n=o(e[0]);return n&&(e[0]-=n),e}),this.saveSortingState()}},setPluginOptions:function(){var e=this.hot.getSettings().columnSorting;this.sortEmptyCells="object"==typeof e&&(e.sortEmptyCells||!1)},onAfterOnCellMouseDown:function(e,t){t.row>-1||g(e.realTarget,"columnSorting")&&(t.col!==this.lastSortedColumn&&(this.hot.sortOrder=!0),this.lastSortedColumn=t.col,this.sortByColumn(t.col))}},{},C),_("columnSorting",M)},{_base:62,browser:24,"helpers/array":43,"helpers/dom/element":47,"helpers/mixed":51,moment:"moment",plugins:61,"utils/sortingAlgorithms/mergeSort":132}],68:[function(e,t,o){"use strict";Object.defineProperties(o,{CommentEditor:{get:function(){return i}},__esModule:{value:!0}});var n,r=((n=e("helpers/dom/element"))&&n.__esModule&&n||{default:n}).addClass,i=function(){this.editor=this.createEditor(),this.editorStyle=this.editor.style,this.hidden=!0,this.hide()},s=i;$traceurRuntime.createClass(i,{setPosition:function(e,t){this.editorStyle.left=e+"px",this.editorStyle.top=t+"px"},setSize:function(e,t){if(e&&t){var o=this.getInputElement();o.style.width=e+"px",o.style.height=t+"px"}},resetSize:function(){var e=this.getInputElement();e.style.width="",e.style.height=""},setReadOnlyState:function(e){this.getInputElement().readOnly=e},show:function(){this.editorStyle.display="block",this.hidden=!1},hide:function(){this.editorStyle.display="none",this.hidden=!0},isVisible:function(){return"block"===this.editorStyle.display},setValue:function(){var e=void 0!==arguments[0]?arguments[0]:"";e=e||"",this.getInputElement().value=e},getValue:function(){return this.getInputElement().value},isFocused:function(){return document.activeElement===this.getInputElement()},focus:function(){this.getInputElement().focus()},createEditor:function(){var e,t,o=document.querySelector("."+s.CLASS_EDITOR_CONTAINER);return o||(o=document.createElement("div"),r(o,s.CLASS_EDITOR_CONTAINER),document.body.appendChild(o)),e=document.createElement("div"),r(e,s.CLASS_EDITOR),t=document.createElement("textarea"),r(t,s.CLASS_INPUT),e.appendChild(t),o.appendChild(e),e},getInputElement:function(){return this.editor.querySelector("."+s.CLASS_INPUT)},destroy:function(){this.editor.parentNode.removeChild(this.editor),this.editor=null,this.editorStyle=null}},{get CLASS_EDITOR_CONTAINER(){return"htCommentsContainer"},get CLASS_EDITOR(){return"htComments"},get CLASS_INPUT(){return"htCommentTextArea"},get CLASS_CELL(){return"htCommentCell"}})},{"helpers/dom/element":47}],69:[function(e,t,o){"use strict";var n;Object.defineProperties(o,{Comments:{get:function(){return I}},__esModule:{value:!0}});var r,i,s,a,l,u,c,d,h,f,p=((r=e("browser"))&&r.__esModule&&r||{default:r}).default,g=(i=e("helpers/dom/element"))&&i.__esModule&&i||{default:i},m=g.addClass,w=g.closest,v=g.isChildOf,y=g.hasClass,b=g.offset,C=g.outerWidth,_=g.outerHeight,R=g.getScrollableElement,M=(s=e("helpers/object"))&&s.__esModule&&s||{default:s},S=M.deepClone,E=M.deepExtend,O=((a=e("helpers/function"))&&a.__esModule&&a||{default:a}).debounce,T=((l=e("eventManager"))&&l.__esModule&&l||{default:l}).EventManager,k=((u=e("3rdparty/walkontable/src/cell/coords"))&&u.__esModule&&u||{default:u}).WalkontableCellCoords,x=((c=e("plugins"))&&c.__esModule&&c||{default:c}).registerPlugin,H=((d=e("_base"))&&d.__esModule&&d||{default:d}).default,D=((h=e("commentEditor"))&&h.__esModule&&h||{default:h}).CommentEditor,A=(f=e("contextMenu/utils"))&&f.__esModule&&f||{default:f},P=A.checkSelectionConsistency,L=A.markLabelAsSelected,N=new WeakMap,I=function(e){$traceurRuntime.superConstructor(W).call(this,e),this.editor=null,this.eventManager=null,this.range={},this.mouseDown=!1,this.contextMenuEvent=!1,this.timer=null,this.displayDelay=250,N.set(this,{tempEditorDimensions:{},cellBelowCursor:null})},W=I;$traceurRuntime.createClass(I,(n={},Object.defineProperty(n,"isEnabled",{value:function(){return!!this.hot.getSettings().comments},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"enablePlugin",{value:function(){var e=this;this.enabled||(this.editor||(this.editor=new D),this.eventManager||(this.eventManager=new T(this)),this.addHook("afterContextMenuDefaultOptions",function(t){return e.addToContextMenu(t)}),this.addHook("afterRenderer",function(t,o,n,r,i,s){return e.onAfterRenderer(t,s)}),this.addHook("afterScrollHorizontally",function(){return e.hide()}),this.addHook("afterScrollVertically",function(){return e.hide()}),this.addHook("afterBeginEditing",function(t){return e.onAfterBeginEditing(t)}),this.registerListeners(),$traceurRuntime.superGet(this,W.prototype,"enablePlugin").call(this))},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"disablePlugin",{value:function(){$traceurRuntime.superGet(this,W.prototype,"disablePlugin").call(this)},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"registerListeners",{value:function(){var e=this;this.eventManager.addEventListener(document,"mouseover",function(t){return e.onMouseOver(t)}),this.eventManager.addEventListener(document,"mousedown",function(t){return e.onMouseDown(t)}),this.eventManager.addEventListener(document,"mouseup",function(t){return e.onMouseUp(t)}),this.eventManager.addEventListener(this.editor.getInputElement(),"blur",function(t){return e.onEditorBlur(t)}),this.eventManager.addEventListener(this.editor.getInputElement(),"mousedown",function(t){return e.onEditorMouseDown(t)}),this.eventManager.addEventListener(this.editor.getInputElement(),"mouseup",function(t){return e.onEditorMouseUp(t)})},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"setRange",{value:function(e){this.range=e},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"clearRange",{value:function(){this.range={}},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"targetIsCellWithComment",{value:function(e){var t=w(e.target,"TD","TBODY");return!!(t&&y(t,"htCommentCell")&&w(t,[this.hot.rootElement]))},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"targetIsCommentTextArea",{value:function(e){return this.editor.getInputElement()===e.target},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"setComment",{value:function(e){var t;if(!this.range.from)throw new Error('Before using this method, first set cell range (hot.getPlugin("comment").setRange())');var o=this.editor.getValue(),n="";null!=e?n=e:null!=o&&(n=o);var r=this.range.from.row,i=this.range.from.col;this.updateCommentMeta(r,i,(t={},Object.defineProperty(t,"value",{value:n,configurable:!0,enumerable:!0,writable:!0}),t)),this.hot.render()},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"setCommentAtCell",{value:function(e,t,o){this.setRange({from:new k(e,t)}),this.setComment(o)},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"removeComment",{value:function(){var e=void 0===arguments[0]||arguments[0];if(!this.range.from)throw new Error('Before using this method, first set cell range (hot.getPlugin("comment").setRange())');this.hot.setCellMeta(this.range.from.row,this.range.from.col,"comment",void 0),e&&this.hot.render(),this.hide()},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"removeCommentAtCell",{value:function(e,t){var o=void 0===arguments[2]||arguments[2];this.setRange({from:new k(e,t)}),this.removeComment(o)},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"getComment",{value:function(){var e=this.range.from.row,t=this.range.from.col;return this.getCommentMeta(e,t,"value")},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"getCommentAtCell",{value:function(e,t){return this.getCommentMeta(e,t,"value")},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"show",{value:function(){if(!this.range.from)throw new Error('Before using this method, first set cell range (hot.getPlugin("comment").setRange())');var e=this.hot.getCellMeta(this.range.from.row,this.range.from.col);return this.refreshEditor(!0),this.editor.setValue(e.comment?e.comment.value:""),this.editor.hidden&&this.editor.show(),!0},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"showAtCell",{value:function(e,t){return this.setRange({from:new k(e,t)}),this.show()},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"hide",{value:function(){this.editor.hidden||this.editor.hide()},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"refreshEditor",{value:function(){if(void 0!==arguments[0]&&arguments[0]||this.range.from&&this.editor.isVisible()){var e=R(this.hot.view.wt.wtTable.TABLE),t=this.hot.view.wt.wtTable.getCell(this.range.from),o=this.range.from.row,n=this.range.from.col,r=b(t),i=this.hot.view.wt.wtTable.getStretchedColumnWidth(n),s=r.top<0?0:r.top,a=r.left;this.hot.view.wt.wtViewport.hasVerticalScroll()&&e!==window&&(s-=this.hot.view.wt.wtOverlays.topOverlay.getScrollPosition()),this.hot.view.wt.wtViewport.hasHorizontalScroll()&&e!==window&&(a-=this.hot.view.wt.wtOverlays.leftOverlay.getScrollPosition());var l=a+i,u=s,c=this.getCommentMeta(o,n,"style"),d=this.getCommentMeta(o,n,"readOnly");c?this.editor.setSize(c.width,c.height):this.editor.resetSize(),this.editor.setReadOnlyState(d),this.editor.setPosition(l,u)}},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"checkSelectionCommentsConsistency",{value:function(){var e=this.hot.getSelectedRange();if(!e)return!1;var t=!1,o=e.from;return this.getCommentMeta(o.row,o.col,"value")&&(t=!0),t},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"updateCommentMeta",{value:function(e,t,o){var n,r=this.hot.getCellMeta(e,t).comment;r?(n=S(r),E(n,o)):n=o,this.hot.setCellMeta(e,t,"comment",n)},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"getCommentMeta",{value:function(e,t,o){var n=this.hot.getCellMeta(e,t);if(n.comment)return n.comment[o]},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"onMouseDown",{value:function(e){if(this.mouseDown=!0,this.hot.view&&this.hot.view.wt){if(!this.contextMenuEvent&&!this.targetIsCommentTextArea(e)){var t=w(e.target,"TD","TBODY"),o=null;t&&(o=this.hot.view.wt.wtTable.getCoords(t)),(!t||this.range.from&&o&&(this.range.from.row!==o.row||this.range.from.col!==o.col))&&this.hide()}this.contextMenuEvent=!1}},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"onMouseOver",{value:function(e){var t=this;if(!this.mouseDown&&!this.editor.isFocused()){var o=N.get(this);o.cellBelowCursor=document.elementFromPoint(e.clientX,e.clientY),O(function(){if(!y(e.target,"wtBorder")&&o.cellBelowCursor===e.target&&t.editor)if(t.targetIsCellWithComment(e)){var n=t.hot.view.wt.wtTable.getCoords(e.target),r={from:new k(n.row,n.col)};t.setRange(r),t.show()}else!v(e.target,document)||t.targetIsCommentTextArea(e)||t.editor.isFocused()||t.hide()},this.displayDelay)()}},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"onMouseUp",{value:function(e){this.mouseDown=!1},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"onAfterRenderer",{value:function(e,t){t.comment&&t.comment.value&&m(e,t.commentedCellClassName)},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"onEditorBlur",{value:function(e){this.setComment()},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"onEditorMouseDown",{value:function(e){N.get(this).tempEditorDimensions={width:C(e.target),height:_(e.target)}},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"onEditorMouseUp",{value:function(e){var t,o=N.get(this),n=C(e.target),r=_(e.target);n===o.tempEditorDimensions.width+1&&r===o.tempEditorDimensions.height+2||this.updateCommentMeta(this.range.from.row,this.range.from.col,(t={},Object.defineProperty(t,"style",{value:{width:n,height:r},configurable:!0,enumerable:!0,writable:!0}),t))},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"onContextMenuAddComment",{value:function(){var e=this,t=this.hot.getSelectedRange();this.contextMenuEvent=!0,this.setRange({from:t.from}),this.show(),
36
- setTimeout(function(){e.hot&&(e.hot.deselectCell(),e.editor.focus())},10)},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"onContextMenuRemoveComment",{value:function(e){this.contextMenuEvent=!0;for(var t=e.start.row;t<=e.end.row;t++)for(var o=e.start.col;o<=e.end.col;o++)this.removeCommentAtCell(t,o,!1);this.hot.render()},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"onContextMenuMakeReadOnly",{value:function(e){var t;this.contextMenuEvent=!0;for(var o=e.start.row;o<=e.end.row;o++)for(var n=e.start.col;n<=e.end.col;n++){var r=!!this.getCommentMeta(o,n,"readOnly");this.updateCommentMeta(o,n,(t={},Object.defineProperty(t,"readOnly",{value:!r,configurable:!0,enumerable:!0,writable:!0}),t))}},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"addToContextMenu",{value:function(e){var t=this;e.items.push(p.plugins.ContextMenu.SEPARATOR,{key:"commentsAddEdit",name:function(){return t.checkSelectionCommentsConsistency()?"Edit comment":"Add comment"},callback:function(){return t.onContextMenuAddComment()},disabled:function(){return!(this.getSelected()&&!this.selection.selectedHeader.corner)}},{key:"commentsRemove",name:function(){return"Delete comment"},callback:function(e,o){return t.onContextMenuRemoveComment(o)},disabled:function(){return t.hot.selection.selectedHeader.corner}},{key:"commentsReadOnly",name:function(){var e=this,t="Read only comment";return P(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).comment;if(n&&(n=n.readOnly),n)return!0})&&(t=L(t)),t},callback:function(e,o){return t.onContextMenuMakeReadOnly(o)},disabled:function(){return t.hot.selection.selectedHeader.corner||!t.checkSelectionCommentsConsistency()}})},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"onAfterBeginEditing",{value:function(e,t){this.hide()},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"destroy",{value:function(){this.editor&&this.editor.destroy(),$traceurRuntime.superGet(this,W.prototype,"destroy").call(this)},configurable:!0,enumerable:!0,writable:!0}),n),{},H),x("comments",I)},{"3rdparty/walkontable/src/cell/coords":6,_base:62,browser:24,commentEditor:68,"contextMenu/utils":88,eventManager:42,"helpers/dom/element":47,"helpers/function":50,"helpers/object":53,plugins:61}],70:[function(e,t,o){"use strict";function n(e,t){var o;return i(t,function(t){var n=t.key?t.key.split(":"):null;if(Array.isArray(n)&&n[1]===e)return o=t,!1}),o}Object.defineProperties(o,{CommandExecutor:{get:function(){return s}},__esModule:{value:!0}});var r,i=((r=e("helpers/array"))&&r.__esModule&&r||{default:r}).arrayEach,s=function(e){this.hot=e,this.commands={},this.commonCallback=null};$traceurRuntime.createClass(s,{registerCommand:function(e,t){this.commands[e]=t},setCommonCallback:function(e){this.commonCallback=e},execute:function(e){for(var t=[],o=1;o<arguments.length;o++)t[o-1]=arguments[o];var r=this,s=e.split(":");e=s[0];var a=2===s.length?s[1]:null,l=this.commands[e];if(!l)throw new Error("Menu command '"+e+"' not exists.");if(a&&l.submenu&&(l=n(a,l.submenu.items)),l.disabled!==!0&&("function"!=typeof l.disabled||l.disabled.call(this.hot)!==!0)&&!l.hasOwnProperty("submenu")){var u=[];"function"==typeof l.callback&&u.push(l.callback),"function"==typeof this.commonCallback&&u.push(this.commonCallback),t.unshift(s.join(":")),i(u,function(e){return e.apply(r.hot,t)})}}},{})},{"helpers/array":43}],71:[function(e,t,o){"use strict";Object.defineProperties(o,{ContextMenu:{get:function(){return F}},__esModule:{value:!0}});var n,r,i,s,a,l,u,c,d,h,l,f,p=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,g=((r=e("_base"))&&r.__esModule&&r||{default:r}).default,m=((i=e("helpers/array"))&&i.__esModule&&i||{default:i}).arrayEach,w=((s=e("commandExecutor"))&&s.__esModule&&s||{default:s}).CommandExecutor,v=((a=e("eventManager"))&&a.__esModule&&a||{default:a}).EventManager,y=((l=e("helpers/dom/element"))&&l.__esModule&&l||{default:l}).hasClass,b=((u=e("itemsFactory"))&&u.__esModule&&u||{default:u}).ItemsFactory,C=((c=e("menu"))&&c.__esModule&&c||{default:c}).Menu,_=((d=e("plugins"))&&d.__esModule&&d||{default:d}).registerPlugin,R=(h=e("helpers/dom/event"))&&h.__esModule&&h||{default:h},M=R.stopPropagation,S=R.pageX,E=R.pageY,O=(l=e("helpers/dom/element"))&&l.__esModule&&l||{default:l},T=O.getWindowScrollLeft,k=O.getWindowScrollTop,x=(f=e("predefinedItems"))&&f.__esModule&&f||{default:f},H=x.ROW_ABOVE,D=x.ROW_BELOW,A=x.COLUMN_LEFT,P=x.COLUMN_RIGHT,L=x.REMOVE_ROW,N=x.REMOVE_COLUMN,I=x.UNDO,W=x.REDO,j=x.READ_ONLY,V=x.ALIGNMENT,B=x.SEPARATOR,F=function(e){$traceurRuntime.superConstructor(z).call(this,e),this.eventManager=new v(this),this.commandExecutor=new w(this.hot),this.itemsFactory=null,this.menu=null},z=F;$traceurRuntime.createClass(F,{isEnabled:function(){return this.hot.getSettings().contextMenu},enablePlugin:function(){var e=this;if(!this.enabled){this.itemsFactory=new b(this.hot,z.DEFAULT_ITEMS);var t=this.hot.getSettings().contextMenu,o={items:this.itemsFactory.getItems(t)};this.registerEvents(),"function"==typeof t.callback&&this.commandExecutor.setCommonCallback(t.callback),$traceurRuntime.superGet(this,z.prototype,"enablePlugin").call(this),this.callOnPluginsReady(function(){e.hot.runHooks("afterContextMenuDefaultOptions",o),e.itemsFactory.setPredefinedItems(o.items);var n=e.itemsFactory.getItems(t);e.menu=new C(e.hot,{className:"htContextMenu",keepInViewport:!0}),e.hot.runHooks("beforeContextMenuSetItems",n),e.menu.setMenuItems(n),e.menu.addLocalHook("afterOpen",function(){return e.onMenuAfterOpen()}),e.menu.addLocalHook("afterClose",function(){return e.onMenuAfterClose()}),e.menu.addLocalHook("executeCommand",function(){for(var t=[],o=0;o<arguments.length;o++)t[o]=arguments[o];return e.executeCommand.apply(e,t)}),m(n,function(t){return e.commandExecutor.registerCommand(t.key,t)})})}},updatePlugin:function(){this.disablePlugin(),this.enablePlugin(),$traceurRuntime.superGet(this,z.prototype,"updatePlugin").call(this)},disablePlugin:function(){this.close(),this.menu&&(this.menu.destroy(),this.menu=null),$traceurRuntime.superGet(this,z.prototype,"disablePlugin").call(this)},registerEvents:function(){var e=this;this.eventManager.addEventListener(this.hot.rootElement,"contextmenu",function(t){return e.onContextMenu(t)})},open:function(e){this.menu&&(this.menu.open(),this.menu.setPosition({top:parseInt(E(e),10)-k(),left:parseInt(S(e),10)-T()}),this.menu.hotMenu.isHotTableEnv=this.hot.isHotTableEnv,p.eventManager.isHotTableEnv=this.hot.isHotTableEnv)},close:function(){this.menu&&this.menu.close()},executeCommand:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.commandExecutor.execute.apply(this.commandExecutor,e)},onContextMenu:function(e){var t=this.hot.getSettings(),o=t.rowHeaders,n=t.colHeaders,r=e.realTarget;this.close(),y(r,"handsontableInput")||(e.preventDefault(),M(e),(o||n||function(e){return"TD"===e.nodeName||"TD"===e.parentNode.nodeName}(r)||y(r,"current")&&y(r,"wtBorder"))&&this.open(e))},onMenuAfterOpen:function(){this.hot.runHooks("afterContextMenuShow",this)},onMenuAfterClose:function(){this.hot.listen(),this.hot.runHooks("afterContextMenuHide",this)},destroy:function(){this.close(),this.menu&&this.menu.destroy(),$traceurRuntime.superGet(this,z.prototype,"destroy").call(this)}},{get DEFAULT_ITEMS(){return[H,D,B,A,P,B,L,N,B,I,W,B,j,B,V]}},g),F.SEPARATOR={name:B},p.hooks.register("afterContextMenuDefaultOptions"),p.hooks.register("afterContextMenuShow"),p.hooks.register("afterContextMenuHide"),p.hooks.register("afterContextMenuExecute"),_("contextMenu",F)},{_base:62,browser:24,commandExecutor:70,eventManager:42,"helpers/array":43,"helpers/dom/element":47,"helpers/dom/event":48,itemsFactory:73,menu:74,plugins:61,predefinedItems:75}],72:[function(e,t,o){"use strict";Object.defineProperties(o,{Cursor:{get:function(){return f}},__esModule:{value:!0}});var n,r,i,s=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,a=(r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r},l=a.getWindowScrollLeft,u=a.getWindowScrollTop,c=(i=e("helpers/dom/event"))&&i.__esModule&&i||{default:i},d=c.pageX,h=c.pageY,f=function(e){var t,o,n,r,i,s,a=u(),c=l();this.type=this.getSourceType(e),"literal"===this.type?(t=parseInt(e.top,10),n=parseInt(e.left,10),i=e.height||0,s=e.width||0,o=t,r=n,t+=a,n+=c):"event"===this.type&&(t=parseInt(h(e),10),n=parseInt(d(e),10),i=e.target.clientHeight,s=e.target.clientWidth,o=t-a,r=n-c),this.top=t,this.topRelative=o,this.left=n,this.leftRelative=r,this.scrollTop=a,this.scrollLeft=c,this.cellHeight=i,this.cellWidth=s};$traceurRuntime.createClass(f,{getSourceType:function(e){var t="literal";return e instanceof Event&&(t="event"),t},fitsAbove:function(e){return this.topRelative>=e.offsetHeight},fitsBelow:function(e){var t=void 0!==arguments[1]?arguments[1]:window.innerHeight;return this.topRelative+e.offsetHeight<=t},fitsOnRight:function(e){var t=void 0!==arguments[1]?arguments[1]:window.innerWidth;return this.leftRelative+this.cellWidth+e.offsetWidth<=t},fitsOnLeft:function(e){return this.leftRelative>=e.offsetWidth}},{}),s.plugins.utils=s.plugins.utils||{},s.plugins.utils.Cursor=f},{browser:24,"helpers/dom/element":47,"helpers/dom/event":48}],73:[function(e,t,o){"use strict";function n(){var e=void 0!==arguments[0]?arguments[0]:null,t=void 0!==arguments[1]?arguments[1]:[],o=void 0!==arguments[2]?arguments[2]:{},n=[];return e&&e.items?e=e.items:Array.isArray(e)||(e=t),u(e)?l(e,function(e,t){var r=o["string"==typeof e?e:t];r||(r=e),u(e)?c(r,e):"string"==typeof r&&(r={name:r}),void 0===r.key&&(r.key=t),n.push(r)}):d(e,function(e,t){var r=o[e];!r&&p.indexOf(e)>=0||(r||(r={name:e,key:t+""}),u(e)&&c(r,e),void 0===r.key&&(r.key=t),n.push(r))}),n}Object.defineProperties(o,{ItemsFactory:{get:function(){return m}},__esModule:{value:!0}});var r,i,s,a=(r=e("helpers/object"))&&r.__esModule&&r||{default:r},l=a.objectEach,u=a.isObject,c=a.extend,d=((i=e("helpers/array"))&&i.__esModule&&i||{default:i}).arrayEach,h=(s=e("predefinedItems"))&&s.__esModule&&s||{default:s},f=h.SEPARATOR,p=h.ITEMS,g=h.predefinedItems,m=function(e){var t=void 0!==arguments[1]?arguments[1]:null;this.hot=e,this.predefinedItems=g(),this.defaultOrderPattern=t};$traceurRuntime.createClass(m,{setPredefinedItems:function(e){var t=this,o={};this.defaultOrderPattern.length=0,l(e,function(e,n){var r="";e.name===f?(o[f]=e,r=f):isNaN(parseInt(n,10))?(e.key=void 0===e.key?n:e.key,o[n]=e,r=e.key):(o[e.key]=e,r=e.key),t.defaultOrderPattern.push(r)}),this.predefinedItems=o},getItems:function(){return n(void 0!==arguments[0]?arguments[0]:null,this.defaultOrderPattern,this.predefinedItems)}},{})},{"helpers/array":43,"helpers/object":53,predefinedItems:75}],74:[function(e,t,o){"use strict";Object.defineProperties(o,{Menu:{get:function(){return z}},__esModule:{value:!0}});var n,r,i,s,a,l,u,c,d,h,f,p,g=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,m=(r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r},w=m.addClass,v=m.empty,y=m.fastInnerHTML,b=m.getScrollbarWidth,C=m.isChildOf,_=m.removeClass,R=(i=e("helpers/array"))&&i.__esModule&&i||{default:i},M=R.arrayEach,S=R.arrayFilter,E=R.arrayReduce,O=((s=e("cursor"))&&s.__esModule&&s||{default:s}).Cursor,T=((a=e("eventManager"))&&a.__esModule&&a||{default:a}).EventManager,k=((l=e("helpers/object"))&&l.__esModule&&l||{default:l}).mixin,x=((u=e("helpers/function"))&&u.__esModule&&u||{default:u}).debounce,H=(c=e("utils"))&&c.__esModule&&c||{default:c},D=H.filterSeparators,A=H.hasSubMenu,P=H.isDisabled,L=H.isItemHidden,N=H.isSeparator,I=H.isSelectionDisabled,W=H.normalizeSelection,j=((d=e("helpers/unicode"))&&d.__esModule&&d||{default:d}).KEY_CODES,V=((h=e("mixins/localHooks"))&&h.__esModule&&h||{default:h}).localHooks,B=((f=e("predefinedItems"))&&f.__esModule&&f||{default:f}).SEPARATOR,F=((p=e("helpers/dom/event"))&&p.__esModule&&p||{default:p}).stopImmediatePropagation,z=function(e,t){this.hot=e,this.options=t||{parent:null,name:null,className:"",keepInViewport:!0,standalone:!1},this.eventManager=new T(this),this.container=this.createContainer(this.options.name),this.hotMenu=null,this.hotSubMenus={},this.parentMenu=this.options.parent||null,this.menuItems=null,this.origOutsideClickDeselects=null,this.keyEvent=!1,this.offset={above:0,below:0,left:0,right:0},this._afterScrollCallback=null,this.registerEvents()},Y=z;$traceurRuntime.createClass(z,{registerEvents:function(){var e=this;this.eventManager.addEventListener(document.documentElement,"mousedown",function(t){return e.onDocumentMouseDown(t)})},setMenuItems:function(e){this.menuItems=e},setOffset:function(e){var t=void 0!==arguments[1]?arguments[1]:0;this.offset[e]=t},isSubMenu:function(){return null!==this.parentMenu},open:function(){var e=this;this.container.removeAttribute("style"),this.container.style.display="block";var t=x(function(t){return e.openSubMenu(t)},300),o=S(this.menuItems,function(t){return L(t,e.hot)});o=D(o,B);var n={data:o,colHeaders:!1,colWidths:[200],autoRowSize:!1,readOnly:!0,copyPaste:!1,columns:[{data:"name",renderer:function(t,o,n,r,i,s){return e.menuItemRenderer(t,o,n,r,i,s)}}],renderAllRows:!0,fragmentSelection:"cell",disableVisualSelection:"area",beforeKeyDown:function(t){return e.onBeforeKeyDown(t)},afterOnCellMouseOver:function(o,n,r){e.isAllSubMenusClosed()?t(n.row):e.openSubMenu(n.row)},rowHeights:function(e){return o[e].name===B?1:23}};this.origOutsideClickDeselects=this.hot.getSettings().outsideClickDeselects,this.hot.getSettings().outsideClickDeselects=!1,this.hotMenu=new g.Core(this.container,n),this.hotMenu.addHook("afterInit",function(){return e.onAfterInit()}),this.hotMenu.addHook("afterSelection",function(t,o,n,r,i){return e.onAfterSelection(t,o,n,r,i)}),this.hotMenu.init(),this.hotMenu.listen(),this.blockMainTableCallbacks(),this.runLocalHooks("afterOpen")},close:function(){var e=void 0!==arguments[0]&&arguments[0];this.isOpened()&&(e&&this.parentMenu?this.parentMenu.close():(this.closeAllSubMenus(),this.container.style.display="none",this.releaseMainTableCallbacks(),this.hotMenu.destroy(),this.hotMenu=null,this.hot.getSettings().outsideClickDeselects=this.origOutsideClickDeselects,this.runLocalHooks("afterClose"),this.parentMenu&&this.parentMenu.hotMenu.listen()))},openSubMenu:function(e){if(!this.hotMenu)return!1;var t=this.hotMenu.getCell(e,0);if(this.closeAllSubMenus(),!t||!A(t))return!1;var o=this.hotMenu.getSourceDataAtRow(e),n=new Y(this.hot,{parent:this,name:o.name,className:this.options.className,keepInViewport:!0});return n.setMenuItems(o.submenu.items),n.open(),n.setPosition(t.getBoundingClientRect()),this.hotSubMenus[o.key]=n,n},closeSubMenu:function(e){var t=this.hotMenu.getSourceDataAtRow(e),o=this.hotSubMenus[t.key];o&&(o.destroy(),delete this.hotSubMenus[t.key])},closeAllSubMenus:function(){var e=this;M(this.hotMenu.getData(),function(t,o){return e.closeSubMenu(o)})},isAllSubMenusClosed:function(){return 0===Object.keys(this.hotSubMenus).length},destroy:function(){this.clearLocalHooks(),this.close(),this.parentMenu=null,this.eventManager.destroy()},isOpened:function(){return null!==this.hotMenu},executeCommand:function(e){if(this.isOpened()&&this.hotMenu.getSelected()){var t=this.hotMenu.getSourceDataAtRow(this.hotMenu.getSelected()[0]);if(this.runLocalHooks("select",t,e),t.isCommand!==!1&&t.name!==B){var o=this.hot.getSelectedRange(),n=o?W(o):{},r=!0;(t.disabled===!0||"function"==typeof t.disabled&&t.disabled.call(this.hot)===!0||t.submenu)&&(r=!1),this.runLocalHooks("executeCommand",t.key,n,e),this.isSubMenu()&&this.parentMenu.runLocalHooks("executeCommand",t.key,n,e),r&&this.close(!0)}}},setPosition:function(e){var t=new O(e);this.options.keepInViewport?(t.fitsBelow(this.container)?this.setPositionBelowCursor(t):t.fitsAbove(this.container)?this.setPositionAboveCursor(t):this.setPositionBelowCursor(t),t.fitsOnRight(this.container)?this.setPositionOnRightOfCursor(t):this.setPositionOnLeftOfCursor(t)):(this.setPositionBelowCursor(t),this.setPositionOnRightOfCursor(t))},setPositionAboveCursor:function(e){var t=this.offset.above+e.top-this.container.offsetHeight;this.isSubMenu()&&(t=e.top+e.cellHeight-this.container.offsetHeight+3),this.container.style.top=t+"px"},setPositionBelowCursor:function(e){var t=this.offset.below+e.top;this.isSubMenu()&&(t=e.top-1),this.container.style.top=t+"px"},setPositionOnRightOfCursor:function(e){var t;t=this.isSubMenu()?1+e.left+e.cellWidth:this.offset.right+1+e.left,this.container.style.left=t+"px"},setPositionOnLeftOfCursor:function(e){var t=this.offset.left+e.left-this.container.offsetWidth+b()+4;this.container.style.left=t+"px"},selectFirstCell:function(){var e=this.hotMenu.getCell(0,0);N(e)||P(e)||I(e)?this.selectNextCell(0,0):this.hotMenu.selectCell(0,0)},selectLastCell:function(){var e=this.hotMenu.countRows()-1,t=this.hotMenu.getCell(e,0);N(t)||P(t)||I(t)?this.selectPrevCell(e,0):this.hotMenu.selectCell(e,0)},selectNextCell:function(e,t){var o=e+1,n=o<this.hotMenu.countRows()?this.hotMenu.getCell(o,t):null;n&&(N(n)||P(n)||I(n)?this.selectNextCell(o,t):this.hotMenu.selectCell(o,t))},selectPrevCell:function(e,t){var o=e-1,n=o>=0?this.hotMenu.getCell(o,t):null;n&&(N(n)||P(n)||I(n)?this.selectPrevCell(o,t):this.hotMenu.selectCell(o,t))},menuItemRenderer:function(e,t,o,n,r,i){var s=this,a=e.getSourceDataAtRow(o),l=document.createElement("div"),u=function(e){return e.disableSelection};"function"==typeof i&&(i=i.call(this.hot)),v(t),w(l,"htItemWrapper"),t.appendChild(l),!function(e){return new RegExp(B,"i").test(e.name)}(a)?"function"==typeof a.renderer?(w(t,"htCustomMenuRenderer"),t.appendChild(a.renderer(e,l,o,n,r,i))):y(l,i):w(t,"htSeparator"),!function(e){return e.disabled===!0||"function"==typeof e.disabled&&e.disabled.call(s.hot)===!0}(a)?u(a)?(w(t,"htSelectionDisabled"),this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()})):!function(e){return e.hasOwnProperty("submenu")}(a)?(_(t,"htSubmenu"),_(t,"htDisabled"),u(a)?this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()}):this.eventManager.addEventListener(t,"mouseenter",function(){return e.selectCell(o,n,void 0,void 0,!1,!1)})):(w(t,"htSubmenu"),u(a)?this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()}):this.eventManager.addEventListener(t,"mouseenter",function(){return e.selectCell(o,n,void 0,void 0,!1,!1)})):(w(t,"htDisabled"),this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()}))},createContainer:function(){var e=void 0!==arguments[0]?arguments[0]:null;e&&(e=e.replace(/ /g,"_"),e=this.options.className+"Sub_"+e);var t;return t=e?document.querySelector("."+this.options.className+"."+e):document.querySelector("."+this.options.className),t||(t=document.createElement("div"),w(t,"htMenu "+this.options.className),e&&w(t,e),document.getElementsByTagName("body")[0].appendChild(t)),t},blockMainTableCallbacks:function(){this._afterScrollCallback=function(){},this.hot.addHook("afterScrollVertically",this._afterScrollCallback),this.hot.addHook("afterScrollHorizontally",this._afterScrollCallback)},releaseMainTableCallbacks:function(){this._afterScrollCallback&&(this.hot.removeHook("afterScrollVertically",this._afterScrollCallback),this.hot.removeHook("afterScrollHorizontally",this._afterScrollCallback),this._afterScrollCallback=null)},onBeforeKeyDown:function(e){var t=this.hotMenu.getSelected(),o=!1;switch(this.keyEvent=!0,e.keyCode){case j.ESCAPE:this.close(),o=!0;break;case j.ENTER:t&&(this.hotMenu.getSourceDataAtRow(t[0]).submenu?o=!0:(this.executeCommand(e),this.close(!0)));break;case j.ARROW_DOWN:t?this.selectNextCell(t[0],t[1]):this.selectFirstCell(),o=!0;break;case j.ARROW_UP:t?this.selectPrevCell(t[0],t[1]):this.selectLastCell(),o=!0;break;case j.ARROW_RIGHT:if(t){var n=this.openSubMenu(t[0]);n&&n.selectFirstCell()}o=!0;break;case j.ARROW_LEFT:t&&this.isSubMenu()&&(this.close(),this.parentMenu&&this.parentMenu.hotMenu.listen(),o=!0)}o&&(e.preventDefault(),F(e)),this.keyEvent=!1},onAfterInit:function(){var e=this.hotMenu.getSettings().data,t=this.hotMenu.view.wt.wtTable.hider.style,o=this.hotMenu.view.wt.wtTable.holder.style,n=parseInt(t.width,10),r=E(e,function(e,t){return e+(t.name===B?1:26)},0);o.width=n+22+"px",o.height=r+4+"px",t.height=o.height},onAfterSelection:function(e,t,o,n,r){this.keyEvent===!1&&(r.value=!0)},onDocumentMouseDown:function(e){this.isOpened()&&(this.container&&C(e.target,this.container)&&this.executeCommand(e),this.options.standalone&&this.hotMenu&&!C(e.target,this.hotMenu.rootElement)?this.close(!0):(this.isAllSubMenusClosed()||this.isSubMenu())&&!C(e.target,".htMenu")&&C(e.target,document)&&this.close(!0))}},{}),k(z,V)},{browser:24,cursor:72,eventManager:42,"helpers/array":43,"helpers/dom/element":47,"helpers/dom/event":48,"helpers/function":50,"helpers/object":53,"helpers/unicode":56,"mixins/localHooks":58,predefinedItems:75,utils:88}],75:[function(e,t,o){"use strict";function n(){var e={};return y(ne,function(t,o){return e[o]=t()}),e}function r(e,t){oe.indexOf(e)===-1&&(ne[e]=t)}var i;Object.defineProperties(o,{ALIGNMENT:{get:function(){return a.KEY}},CLEAR_COLUMN:{get:function(){return l.KEY}},COLUMN_LEFT:{get:function(){return u.KEY}},COLUMN_RIGHT:{get:function(){return c.KEY}},READ_ONLY:{get:function(){return d.KEY}},REDO:{get:function(){return h.KEY}},REMOVE_COLUMN:{get:function(){return f.KEY}},REMOVE_ROW:{get:function(){return p.KEY}},ROW_ABOVE:{get:function(){return g.KEY}},ROW_BELOW:{get:function(){return m.KEY}},SEPARATOR:{get:function(){return w.KEY}},UNDO:{get:function(){return v.KEY}},ITEMS:{get:function(){return oe}},predefinedItems:{get:function(){return n}},addItem:{get:function(){return r}},__esModule:{value:!0}});var s,a,l,u,c,d,h,f,p,g,m,w,v,a,l,u,c,d,h,f,p,g,m,w,v,y=((s=e("helpers/object"))&&s.__esModule&&s||{default:s}).objectEach,b=(a=e("predefinedItems/alignment"))&&a.__esModule&&a||{default:a},C=b.alignmentItem,_=b.KEY,R=(l=e("predefinedItems/clearColumn"))&&l.__esModule&&l||{default:l},M=R.clearColumnItem,S=R.KEY,E=(u=e("predefinedItems/columnLeft"))&&u.__esModule&&u||{default:u},O=E.columnLeftItem,T=E.KEY,k=(c=e("predefinedItems/columnRight"))&&c.__esModule&&c||{default:c},x=k.columnRightItem,H=k.KEY,D=(d=e("predefinedItems/readOnly"))&&d.__esModule&&d||{default:d},A=D.readOnlyItem,P=D.KEY,L=(h=e("predefinedItems/redo"))&&h.__esModule&&h||{default:h},N=L.redoItem,I=L.KEY,W=(f=e("predefinedItems/removeColumn"))&&f.__esModule&&f||{default:f},j=W.removeColumnItem,V=W.KEY,B=(p=e("predefinedItems/removeRow"))&&p.__esModule&&p||{default:p},F=B.removeRowItem,z=B.KEY,Y=(g=e("predefinedItems/rowAbove"))&&g.__esModule&&g||{default:g},U=Y.rowAboveItem,G=Y.KEY,$=(m=e("predefinedItems/rowBelow"))&&m.__esModule&&m||{default:m},K=$.rowBelowItem,X=$.KEY,q=(w=e("predefinedItems/separator"))&&w.__esModule&&w||{default:w},Z=q.separatorItem,J=q.KEY,Q=(v=e("predefinedItems/undo"))&&v.__esModule&&v||{default:v},ee=Q.undoItem,te=Q.KEY,a=(a=e("predefinedItems/alignment"))&&a.__esModule&&a||{default:a},l=(l=e("predefinedItems/clearColumn"))&&l.__esModule&&l||{default:l},u=(u=e("predefinedItems/columnLeft"))&&u.__esModule&&u||{default:u},c=(c=e("predefinedItems/columnRight"))&&c.__esModule&&c||{default:c},d=(d=e("predefinedItems/readOnly"))&&d.__esModule&&d||{default:d},h=(h=e("predefinedItems/redo"))&&h.__esModule&&h||{default:h},f=(f=e("predefinedItems/removeColumn"))&&f.__esModule&&f||{default:f},p=(p=e("predefinedItems/removeRow"))&&p.__esModule&&p||{default:p},g=(g=e("predefinedItems/rowAbove"))&&g.__esModule&&g||{default:g},m=(m=e("predefinedItems/rowBelow"))&&m.__esModule&&m||{default:m},w=(w=e("predefinedItems/separator"))&&w.__esModule&&w||{default:w},v=(v=e("predefinedItems/undo"))&&v.__esModule&&v||{default:v},oe=[G,X,T,H,S,z,V,te,I,P,_,J],ne=(i={},Object.defineProperty(i,J,{value:Z,configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(i,G,{value:U,configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(i,X,{value:K,configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(i,T,{value:O,configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(i,H,{value:x,configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(i,S,{value:M,configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(i,z,{value:F,configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(i,V,{value:j,configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(i,te,{value:ee,configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(i,I,{value:N,configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(i,P,{value:A,configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(i,_,{value:C,configurable:!0,enumerable:!0,writable:!0}),i)},{"helpers/object":53,"predefinedItems/alignment":76,"predefinedItems/clearColumn":77,"predefinedItems/columnLeft":78,"predefinedItems/columnRight":79,"predefinedItems/readOnly":80,"predefinedItems/redo":81,"predefinedItems/removeColumn":82,"predefinedItems/removeRow":83,"predefinedItems/rowAbove":84,"predefinedItems/rowBelow":85,"predefinedItems/separator":86,"predefinedItems/undo":87}],76:[function(e,t,o){"use strict";function n(){return{key:h,name:"Alignment",disabled:function(){return!(this.getSelectedRange()&&!this.selection.selectedHeader.corner)},submenu:{items:[{key:h+":left",name:function(){var e=this,t="Left";return u(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&n.indexOf("htLeft")!==-1)return!0})&&(t=c(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=l(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"horizontal","htLeft"),a(t,"horizontal","htLeft",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{key:h+":center",name:function(){var e=this,t="Center";return u(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&n.indexOf("htCenter")!==-1)return!0})&&(t=c(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=l(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"horizontal","htCenter"),a(t,"horizontal","htCenter",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{key:h+":right",name:function(){var e=this,t="Right";return u(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&n.indexOf("htRight")!==-1)return!0})&&(t=c(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=l(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"horizontal","htRight"),a(t,"horizontal","htRight",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{key:h+":justify",name:function(){var e=this,t="Justify";return u(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&n.indexOf("htJustify")!==-1)return!0})&&(t=c(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=l(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"horizontal","htJustify"),a(t,"horizontal","htJustify",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{name:d},{key:h+":top",name:function(){var e=this,t="Top";return u(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&n.indexOf("htTop")!==-1)return!0})&&(t=c(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=l(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"vertical","htTop"),a(t,"vertical","htTop",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{key:h+":middle",name:function(){var e=this,t="Middle";return u(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&n.indexOf("htMiddle")!==-1)return!0})&&(t=c(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=l(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"vertical","htMiddle"),a(t,"vertical","htMiddle",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1},{key:h+":bottom",name:function(){var e=this,t="Bottom";return u(this.getSelectedRange(),function(t,o){var n=e.getCellMeta(t,o).className;if(n&&n.indexOf("htBottom")!==-1)return!0})&&(t=c(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=l(t,function(t,o){return e.getCellMeta(t,o).className});this.runHooks("beforeCellAlignment",o,t,"vertical","htBottom"),a(t,"vertical","htBottom",function(t,o){return e.getCellMeta(t,o)},function(t,o,n,r){return e.setCellMeta(t,o,n,r)}),this.render()},disabled:!1}]}}}Object.defineProperties(o,{KEY:{get:function(){return h}},alignmentItem:{get:function(){return n}},__esModule:{value:!0}});var r,i,s=(r=e("utils"))&&r.__esModule&&r||{default:r},a=s.align,l=s.getAlignmentClasses,u=s.checkSelectionConsistency,c=s.markLabelAsSelected,d=((i=e("separator"))&&i.__esModule&&i||{default:i}).KEY,h="alignment"},{separator:86,utils:88}],77:[function(e,t,o){"use strict";function n(){return{key:s,name:"Clear column",callback:function(e,t){var o=t.start.col;this.countRows()&&this.populateFromArray(0,o,[[null]],Math.max(t.start.row,t.end.row),o,"ContextMenu.clearColumn")},disabled:function(){var e=i(this);if(!e)return!0;var t=[e[0],0,e[0],this.countCols()-1],o=t.join(",")==e.join(",");return e[1]<0||this.countCols()>=this.getSettings().maxCols||o}}}Object.defineProperties(o,{KEY:{get:function(){return s}},clearColumnItem:{get:function(){return n}},__esModule:{value:!0}});var r,i=((r=e("utils"))&&r.__esModule&&r||{default:r}).getValidSelection,s="clear_column"},{utils:88}],78:[function(e,t,o){"use strict";function n(){return{key:s,name:"Insert column on the left",callback:function(e,t){this.alter("insert_col",t.start.col,1,"ContextMenu.columnLeft")},disabled:function(){var e=i(this);if(!e)return!0;if(!this.isColumnModificationAllowed())return!0;var t=[e[0],0,e[0],this.countCols()-1],o=t.join(",")==e.join(","),n=1===this.countCols();return e[1]<0||this.countCols()>=this.getSettings().maxCols||!n&&o},hidden:function(){return!this.getSettings().allowInsertColumn}}}Object.defineProperties(o,{KEY:{get:function(){return s}},columnLeftItem:{get:function(){return n}},__esModule:{value:!0}});var r,i=((r=e("utils"))&&r.__esModule&&r||{default:r}).getValidSelection,s="col_left"},{utils:88}],79:[function(e,t,o){"use strict";function n(){return{key:s,name:"Insert column on the right",callback:function(e,t){this.alter("insert_col",t.end.col+1,1,"ContextMenu.columnRight")},disabled:function(){var e=i(this);if(!e)return!0;if(!this.isColumnModificationAllowed())return!0;var t=[e[0],0,e[0],this.countCols()-1],o=t.join(",")==e.join(","),n=1===this.countCols();return e[1]<0||this.countCols()>=this.getSettings().maxCols||!n&&o},hidden:function(){return!this.getSettings().allowInsertColumn}}}Object.defineProperties(o,{KEY:{get:function(){return s}},columnRightItem:{get:function(){return n}},__esModule:{value:!0}});var r,i=((r=e("utils"))&&r.__esModule&&r||{default:r}).getValidSelection,s="col_right"},{utils:88}],80:[function(e,t,o){"use strict";function n(){return{key:l,name:function(){var e=this,t="Read only";return s(this.getSelectedRange(),function(t,o){return e.getCellMeta(t,o).readOnly})&&(t=a(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),o=s(t,function(t,o){return e.getCellMeta(t,o).readOnly});t.forAll(function(t,n){e.setCellMeta(t,n,"readOnly",!o)}),this.render()},disabled:function(){return!(this.getSelectedRange()&&!this.selection.selectedHeader.corner)}}}Object.defineProperties(o,{KEY:{get:function(){return l}},readOnlyItem:{get:function(){return n}},__esModule:{value:!0}})
37
- ;var r,i=(r=e("utils"))&&r.__esModule&&r||{default:r},s=i.checkSelectionConsistency,a=i.markLabelAsSelected,l="make_read_only"},{utils:88}],81:[function(e,t,o){"use strict";function n(){return{key:r,name:"Redo",callback:function(){this.redo()},disabled:function(){return this.undoRedo&&!this.undoRedo.isRedoAvailable()}}}Object.defineProperties(o,{KEY:{get:function(){return r}},redoItem:{get:function(){return n}},__esModule:{value:!0}});var r="redo"},{}],82:[function(e,t,o){"use strict";function n(){return{key:s,name:"Remove column",callback:function(e,t){var o=t.end.col-t.start.col+1;this.alter("remove_col",t.start.col,o,"ContextMenu.removeColumn")},disabled:function(){var e=i(this),t=this.countCols();return!e||this.selection.selectedHeader.rows||this.selection.selectedHeader.corner||!this.isColumnModificationAllowed()||!t},hidden:function(){return!this.getSettings().allowRemoveColumn}}}Object.defineProperties(o,{KEY:{get:function(){return s}},removeColumnItem:{get:function(){return n}},__esModule:{value:!0}});var r,i=((r=e("utils"))&&r.__esModule&&r||{default:r}).getValidSelection,s="remove_col"},{utils:88}],83:[function(e,t,o){"use strict";function n(){return{key:s,name:"Remove row",callback:function(e,t){var o=t.end.row-t.start.row+1;this.alter("remove_row",t.start.row,o,"ContextMenu.removeRow")},disabled:function(){var e=i(this),t=this.countRows();return!e||this.selection.selectedHeader.cols||this.selection.selectedHeader.corner||!t},hidden:function(){return!this.getSettings().allowRemoveRow}}}Object.defineProperties(o,{KEY:{get:function(){return s}},removeRowItem:{get:function(){return n}},__esModule:{value:!0}});var r,i=((r=e("utils"))&&r.__esModule&&r||{default:r}).getValidSelection,s="remove_row"},{utils:88}],84:[function(e,t,o){"use strict";function n(){return{key:s,name:"Insert row above",callback:function(e,t){this.alter("insert_row",t.start.row,1,"ContextMenu.rowAbove")},disabled:function(){return!i(this)||this.selection.selectedHeader.cols||this.countRows()>=this.getSettings().maxRows},hidden:function(){return!this.getSettings().allowInsertRow}}}Object.defineProperties(o,{KEY:{get:function(){return s}},rowAboveItem:{get:function(){return n}},__esModule:{value:!0}});var r,i=((r=e("utils"))&&r.__esModule&&r||{default:r}).getValidSelection,s="row_above"},{utils:88}],85:[function(e,t,o){"use strict";function n(){return{key:s,name:"Insert row below",callback:function(e,t){this.alter("insert_row",t.end.row+1,1,"ContextMenu.rowBelow")},disabled:function(){return!i(this)||this.selection.selectedHeader.cols||this.countRows()>=this.getSettings().maxRows},hidden:function(){return!this.getSettings().allowInsertRow}}}Object.defineProperties(o,{KEY:{get:function(){return s}},rowBelowItem:{get:function(){return n}},__esModule:{value:!0}});var r,i=((r=e("utils"))&&r.__esModule&&r||{default:r}).getValidSelection,s="row_below"},{utils:88}],86:[function(e,t,o){"use strict";function n(){return{name:r}}Object.defineProperties(o,{KEY:{get:function(){return r}},separatorItem:{get:function(){return n}},__esModule:{value:!0}});var r="---------"},{}],87:[function(e,t,o){"use strict";function n(){return{key:r,name:"Undo",callback:function(){this.undo()},disabled:function(){return this.undoRedo&&!this.undoRedo.isUndoAvailable()}}}Object.defineProperties(o,{KEY:{get:function(){return r}},undoItem:{get:function(){return n}},__esModule:{value:!0}});var r="undo"},{}],88:[function(e,t,o){"use strict";function n(e){return{start:e.getTopLeftCorner(),end:e.getBottomRightCorner()}}function r(e){return S(e,"htSeparator")}function i(e){return S(e,"htSubmenu")}function s(e){return S(e,"htDisabled")}function a(e){return S(e,"htSelectionDisabled")}function l(e){var t=e.getSelected();return t?t[0]<0?null:t:null}function u(e,t){return e.indexOf(t)!=-1?e:(e=e.replace("htTop","").replace("htMiddle","").replace("htBottom","").replace(" ",""),e+=" "+t)}function c(e,t){return e.indexOf(t)!=-1?e:(e=e.replace("htLeft","").replace("htCenter","").replace("htRight","").replace("htJustify","").replace(" ",""),e+=" "+t)}function d(e,t){for(var o={},n=e.from.row;n<=e.to.row;n++)for(var r=e.from.col;r<=e.to.col;r++)o[n]||(o[n]=[]),o[n][r]=t(n,r);return o}function h(e,t,o,n,r){if(e.from.row==e.to.row&&e.from.col==e.to.col)f(e.from.row,e.from.col,t,o,n,r);else for(var i=e.from.row;i<=e.to.row;i++)for(var s=e.from.col;s<=e.to.col;s++)f(i,s,t,o,n,r)}function f(e,t,o,n,r,i){var s=r(e,t),a=n;s.className&&(a="vertical"===o?u(s.className,n):c(s.className,n)),i(e,t,"className",a)}function p(e,t){var o=!1;return e&&e.forAll(function(e,n){if(t(e,n))return o=!0,!1}),o}function g(e){return'<span class="selected">'+String.fromCharCode(10003)+"</span>"+e}function m(e,t){return!e.hidden||!("function"==typeof e.hidden&&e.hidden.call(t))}function w(e,t){for(var o=e.slice(0);0<o.length&&o[0].name===t;)o.shift();return o}function v(e,t){var o=e.slice(0);return o.reverse(),o=w(o,t),o.reverse(),o}function y(e){var t=[];return M(e,function(e,o){o>0?t[t.length-1].name!==e.name&&t.push(e):t.push(e)}),t}function b(e){var t=void 0!==arguments[1]?arguments[1]:E,o=e.slice(0);return o=w(o,t),o=v(o,t),o=y(o)}Object.defineProperties(o,{normalizeSelection:{get:function(){return n}},isSeparator:{get:function(){return r}},hasSubMenu:{get:function(){return i}},isDisabled:{get:function(){return s}},isSelectionDisabled:{get:function(){return a}},getValidSelection:{get:function(){return l}},prepareVerticalAlignClass:{get:function(){return u}},prepareHorizontalAlignClass:{get:function(){return c}},getAlignmentClasses:{get:function(){return d}},align:{get:function(){return h}},checkSelectionConsistency:{get:function(){return p}},markLabelAsSelected:{get:function(){return g}},isItemHidden:{get:function(){return m}},filterSeparators:{get:function(){return b}},__esModule:{value:!0}});var C,_,R,M=((C=e("helpers/array"))&&C.__esModule&&C||{default:C}).arrayEach,S=((_=e("helpers/dom/element"))&&_.__esModule&&_||{default:_}).hasClass,E=((R=e("predefinedItems/separator"))&&R.__esModule&&R||{default:R}).KEY},{"helpers/array":43,"helpers/dom/element":47,"predefinedItems/separator":86}],89:[function(e,t,o){"use strict";Object.defineProperties(o,{ContextMenuCopyPaste:{get:function(){return w}},__esModule:{value:!0}});var n,r,i,s,a,l,u,c=((n=e("_base"))&&n.__esModule&&n||{default:n}).default,d=((r=e("zeroclipboard"))&&r.__esModule&&r||{default:r}).default,h=((i=e("helpers/dom/element"))&&i.__esModule&&i||{default:i}).removeClass,f=((s=e("helpers/array"))&&s.__esModule&&s||{default:s}).arrayEach,p=((a=e("eventManager"))&&a.__esModule&&a||{default:a}).EventManager,g=((l=e("plugins"))&&l.__esModule&&l||{default:l}).registerPlugin,m=((u=e("contextMenu/predefinedItems"))&&u.__esModule&&u||{default:u}).SEPARATOR,w=function(e){$traceurRuntime.superConstructor(v).call(this,e),this.eventManager=new p(this),this.swfPath=null,this.outsideClickDeselectsCache=null},v=w;$traceurRuntime.createClass(w,{isEnabled:function(){return this.hot.getSettings().contextMenuCopyPaste},enablePlugin:function(){var e=this;if(!this.enabled){"object"==typeof this.hot.getSettings().contextMenuCopyPaste&&(this.swfPath=this.hot.getSettings().contextMenuCopyPaste.swfPath),void 0===d&&console.error("To be able to use the Copy/Paste feature from the context menu, you need to manually include ZeroClipboard.js file to your website.");try{new ActiveXObject("ShockwaveFlash.ShockwaveFlash")}catch(e){void 0===navigator.mimeTypes["application/x-shockwave-flash"]&&console.error("To be able to use the Copy/Paste feature from the context menu, your browser needs to have Flash Plugin installed.")}this.swfPath&&d.config({swfPath:this.swfPath}),this.hot.addHook("afterContextMenuShow",function(){return e.onAfterContextMenuShow()}),this.hot.addHook("afterContextMenuDefaultOptions",function(t){return e.onAfterContextMenuDefaultOptions(t)}),this.registerEvents(),$traceurRuntime.superGet(this,v.prototype,"enablePlugin").call(this)}},disablePlugin:function(){$traceurRuntime.superGet(this,v.prototype,"disablePlugin").call(this)},registerEvents:function(){var e=this;this.eventManager.addEventListener(document,"mouseenter",function(){return e.removeCurrentClass()}),this.eventManager.addEventListener(document,"mouseleave",function(){return e.removeZeroClipboardClass()})},getCopyValue:function(){return this.hot.copyPaste.setCopyableText(),this.hot.copyPaste.copyPasteInstance.triggerCopy(),this.hot.copyPaste.copyPasteInstance.elTextarea.value},onAfterContextMenuDefaultOptions:function(e){e.items.unshift({key:"copy",name:"Copy",disabled:function(){return this.selection.selectedHeader.corner}},{key:"paste",name:"Paste",callback:function(){this.copyPaste.triggerPaste()},disabled:function(){return this.selection.selectedHeader.corner}},{name:m})},onAfterContextMenuShow:function(){var e=this,t=this.hot.getPlugin("contextMenu");f(t.menu.hotMenu.getSourceData(),function(o,n){if("copy"===o.key){var r=new d(t.menu.hotMenu.getCell(n,0));return r.off(),r.on("copy",function(t){t.clipboardData.setData("text/plain",e.getCopyValue()),e.hot.getSettings().outsideClickDeselects=e.outsideClickDeselectsCache}),!1}})},removeCurrentClass:function(){var e=this.hot.getPlugin("contextMenu");if(e.enabled){if(e.menu.isOpened()){var t=e.menu.hotMenu.rootElement.querySelector("td.current");t&&h(t,"current")}this.outsideClickDeselectsCache=this.hot.getSettings().outsideClickDeselects,this.hot.getSettings().outsideClickDeselects=!1}},removeZeroClipboardClass:function(){var e=this.hot.getPlugin("contextMenu");if(e.enabled){if(e.menu.isOpened()){var t=e.menu.hotMenu.rootElement.querySelector("td.zeroclipboard-is-hover");t&&h(t,"zeroclipboard-is-hover")}this.hot.getSettings().outsideClickDeselects=this.outsideClickDeselectsCache}}},{},c),g("contextMenuCopyPaste",w)},{_base:62,"contextMenu/predefinedItems":75,eventManager:42,"helpers/array":43,"helpers/dom/element":47,plugins:61,zeroclipboard:"zeroclipboard"}],90:[function(e,t,o){"use strict";function n(e){function t(){e.isListening()}function o(){var t=s.getRangedData(s.copyableRanges);if(!e.getSettings().fragmentSelection||v.stringify(t)==O()){!!e.runHooks("beforeCut",t,s.copyableRanges)?(e.copyPaste.copyPasteInstance.copyable(v.stringify(t)),e.selection.empty(),e.runHooks("afterCut",t,s.copyableRanges)):e.copyPaste.copyPasteInstance.copyable("")}}function n(){if(e.isListening()){var t=s.getRangedData(s.copyableRanges);if(!e.getSettings().fragmentSelection||v.stringify(t)==O()){!!e.runHooks("beforeCopy",t,s.copyableRanges)?(e.copyPaste.copyPasteInstance.copyable(v.stringify(t)),e.runHooks("afterCopy",t,s.copyableRanges)):e.copyPaste.copyPasteInstance.copyable("")}}}function r(t){var o,n,r,i,a,l,u,c,d,h;if(e.isListening()&&e.selection.isSelected()){o=t,n=v.parse(o),r=e.getSelected(),i=new k(r[0],r[1]),a=new k(r[2],r[3]),l=new x(i,i,a),u=l.getTopLeftCorner(),c=l.getBottomRightCorner(),d=u,h=new k(Math.max(c.row,n.length-1+u.row),Math.max(c.col,n[0].length-1+u.col));var f=a.row-i.row>=n.length-1,p=a.col-i.col>=n[0].length-1;e.addHookOnce("afterChange",function(t,o){var n=t?t.length:0;if(n){var r={row:0,col:0},i=-1;_(t,function(e,o){var s=n>o+1?t[o+1]:null;s&&(f||(r.row=r.row+Math.max(s[0]-e[0]-1,0)),!p&&e[1]>i&&(i=e[1],r.col=r.col+Math.max(s[1]-e[1]-1,0)))}),e.selectCell(d.row,d.col,h.row+r.row,h.col+r.col)}});!!e.runHooks("beforePaste",n,s.copyableRanges)&&(e.populateFromArray(d.row,d.col,n,h.row,h.col,"CopyPaste.paste",e.getSettings().pasteMode),e.runHooks("afterPaste",n,s.copyableRanges))}}function i(t){if(e.getSelected()&&!(e.getActiveEditor()&&e.getActiveEditor().isOpened()||E(t))){if(C(t.keyCode)){if(e.getSettings().fragmentSelection&&O())return;return s.setCopyableText(),void S(t)}(t.ctrlKey||t.metaKey)&&!t.altKey&&(t.keyCode==b.A&&e._registerTimeout(setTimeout(T(s.setCopyableText,s),0)),t.keyCode==b.X&&o(),t.keyCode==b.C&&n())}}var s=this;this.copyPasteInstance=w(),this.copyPasteInstance.onCut(t),this.copyPasteInstance.triggerCopy=n,this.copyPasteInstance.onPaste(r),this.onPaste=r,this.copyableRanges=[],e.addHook("beforeKeyDown",i),this.destroy=function(){this.copyPasteInstance&&(this.copyPasteInstance.removeCallback(t),this.copyPasteInstance.removeCallback(r),this.copyPasteInstance.destroy(),this.copyPasteInstance=null),e.removeHook("beforeKeyDown",i)},e.addHook("afterDestroy",T(this.destroy,this)),this.triggerPaste=T(this.copyPasteInstance.triggerPaste,this.copyPasteInstance),this.triggerCut=T(this.copyPasteInstance.triggerCut,this.copyPasteInstance),this.setCopyableText=function(){var t=e.getSettings(),o=t.copyRowsLimit,n=t.copyColsLimit,r=e.getSelectedRange(),i=r.getTopLeftCorner(),s=r.getBottomRightCorner(),a=i.row,l=i.col,u=s.row,c=s.col,d=Math.min(u,a+o-1),h=Math.min(c,l+n-1);this.copyableRanges.length=0,this.copyableRanges.push({startRow:a,startCol:l,endRow:d,endCol:h}),this.copyableRanges=e.runHooks("modifyCopyableRange",this.copyableRanges);var f=this.getRangedCopyableData(this.copyableRanges);e.copyPaste.copyPasteInstance.copyable(f),u===d&&c===h||m.hooks.run(e,"afterCopyLimit",u-a+1,c-l+1,o,n)},this.getRangedCopyableData=function(t){var o=[],n=[],r=[];return _(t,function(e){R(e.startRow,e.endRow,function(e){n.indexOf(e)===-1&&n.push(e)}),R(e.startCol,e.endCol,function(e){r.indexOf(e)===-1&&r.push(e)})}),_(n,function(t){var n=[];_(r,function(o){n.push(e.getCopyableData(t,o))}),o.push(n)}),v.stringify(o)},this.getRangedData=function(t){var o=[],n=[],r=[];return _(t,function(e){R(e.startRow,e.endRow,function(e){n.indexOf(e)===-1&&n.push(e)}),R(e.startCol,e.endCol,function(e){r.indexOf(e)===-1&&r.push(e)})}),_(n,function(t){var n=[];_(r,function(o){n.push(e.getCopyableData(t,o))}),o.push(n)}),o}}function r(){var e=this,t=e.getSettings().copyPaste!==!1;t&&!e.copyPaste?e.copyPaste=new n(e):!t&&e.copyPaste&&(e.copyPaste.destroy(),e.copyPaste=null)}Object.defineProperties(o,{CopyPastePlugin:{get:function(){return n}},__esModule:{value:!0}});var i,s,a,l,u,c,d,h,f,p,g,m=((i=e("browser"))&&i.__esModule&&i||{default:i}).default,w=((s=e("copyPaste"))&&s.__esModule&&s||{default:s}).default,v=((a=e("SheetClip"))&&a.__esModule&&a||{default:a}).default,y=(l=e("helpers/unicode"))&&l.__esModule&&l||{default:l},b=y.KEY_CODES,C=y.isCtrlKey,_=((u=e("helpers/array"))&&u.__esModule&&u||{default:u}).arrayEach,R=((c=e("helpers/number"))&&c.__esModule&&c||{default:c}).rangeEach,M=(d=e("helpers/dom/event"))&&d.__esModule&&d||{default:d},S=M.stopImmediatePropagation,E=M.isImmediatePropagationStopped,O=((h=e("helpers/dom/element"))&&h.__esModule&&h||{default:h}).getSelectionText,T=((f=e("helpers/function"))&&f.__esModule&&f||{default:f}).proxy,k=((p=e("3rdparty/walkontable/src/cell/coords"))&&p.__esModule&&p||{default:p}).WalkontableCellCoords,x=((g=e("3rdparty/walkontable/src/cell/range"))&&g.__esModule&&g||{default:g}).WalkontableCellRange;m.hooks.add("afterInit",r),m.hooks.add("afterUpdateSettings",r),m.hooks.register("afterCopyLimit"),m.hooks.register("modifyCopyableRange"),m.hooks.register("beforeCut"),m.hooks.register("afterCut"),m.hooks.register("beforePaste"),m.hooks.register("afterPaste"),m.hooks.register("beforeCopy"),m.hooks.register("afterCopy")},{"3rdparty/walkontable/src/cell/coords":6,"3rdparty/walkontable/src/cell/range":7,SheetClip:"SheetClip",browser:24,copyPaste:"copyPaste","helpers/array":43,"helpers/dom/element":47,"helpers/dom/event":48,"helpers/function":50,"helpers/number":52,"helpers/unicode":56}],91:[function(e,t,o){"use strict";function n(){}var r,i,s,a,l,u=((r=e("browser"))&&r.__esModule&&r||{default:r}).default,c=(((i=e("plugins"))&&i.__esModule&&i||{default:i}).registerPlugin,((s=e("3rdparty/walkontable/src/cell/range"))&&s.__esModule&&s||{default:s}).WalkontableCellRange),d=((a=e("3rdparty/walkontable/src/selection"))&&a.__esModule&&a||{default:a}).WalkontableSelection,h=function(e){return"boolean"==typeof e&&e===!0||"object"==typeof e&&e.length>0},f=function(){h(this.getSettings().customBorders)&&(this.customBorders||(l=this,this.customBorders=new n))},p=function(e){for(var t=0;t<l.view.wt.selections.length;t++)if(l.view.wt.selections[t].settings.className==e)return t;return-1},g=function(e){var t={row:e.row,col:e.col},o=new d(e,new c(t,t,t)),n=p(e.className);n>=0?l.view.wt.selections[n]=o:l.view.wt.selections.push(o)},m=function(e,t,o){var n=_(e,t);n=R(n,o),this.setCellMeta(e,t,"borders",n),g(n)},w=function(e){for(var t=e.range,o=t.from.row;o<=t.to.row;o++)for(var n=t.from.col;n<=t.to.col;n++){var r=_(o,n),i=0;o==t.from.row&&(i++,e.hasOwnProperty("top")&&(r.top=e.top)),o==t.to.row&&(i++,e.hasOwnProperty("bottom")&&(r.bottom=e.bottom)),n==t.from.col&&(i++,e.hasOwnProperty("left")&&(r.left=e.left)),n==t.to.col&&(i++,e.hasOwnProperty("right")&&(r.right=e.right)),i>0&&(this.setCellMeta(o,n,"borders",r),g(r))}},v=function(e,t){return"border_row"+e+"col"+t},y=function(){return{width:1,color:"#000"}},b=function(){return{hide:!0}},C=function(){return{width:1,color:"#000",cornerVisible:!1}},_=function(e,t){return{className:v(e,t),border:C(),row:e,col:t,top:b(),right:b(),bottom:b(),left:b()}},R=function(e,t){return t.hasOwnProperty("border")&&(e.border=t.border),t.hasOwnProperty("top")&&(e.top=t.top),t.hasOwnProperty("right")&&(e.right=t.right),t.hasOwnProperty("bottom")&&(e.bottom=t.bottom),t.hasOwnProperty("left")&&(e.left=t.left),e},M=function(e){for(var t=document.querySelectorAll("."+e),o=0;o<t.length;o++)if(t[o]&&"TD"!=t[o].nodeName){var n=t[o].parentNode;n.parentNode&&n.parentNode.removeChild(n)}},S=function(e,t){M(v(e,t)),this.removeCellMeta(e,t,"borders")},E=function(e,t,o,n){var r=this.getCellMeta(e,t).borders;r&&void 0!=r.border||(r=_(e,t)),r[o]=n?b():y(),this.setCellMeta(e,t,"borders",r),M(v(e,t)),g(r),this.render()},O=function(e,t,o){if(e.from.row==e.to.row&&e.from.col==e.to.col)"noBorders"==t?S.call(this,e.from.row,e.from.col):E.call(this,e.from.row,e.from.col,t,o);else switch(t){case"noBorders":for(var n=e.from.col;n<=e.to.col;n++)for(var r=e.from.row;r<=e.to.row;r++)S.call(this,r,n);break;case"top":for(var i=e.from.col;i<=e.to.col;i++)E.call(this,e.from.row,i,t,o);break;case"right":for(var s=e.from.row;s<=e.to.row;s++)E.call(this,s,e.to.col,t);break;case"bottom":for(var a=e.from.col;a<=e.to.col;a++)E.call(this,e.to.row,a,t);break;case"left":for(var l=e.from.row;l<=e.to.row;l++)E.call(this,l,e.from.col,t)}},T=function(e,t){var o=!1;return e.getSelectedRange().forAll(function(n,r){var i=e.getCellMeta(n,r).borders;if(i){if(!t)return o=!0,!1;if(!i[t].hasOwnProperty("hide"))return o=!0,!1}}),o},k=function(e){return'<span class="selected">'+String.fromCharCode(10003)+"</span>"+e},x=function(e){this.getSettings().customBorders&&(e.items.push(u.plugins.ContextMenu.SEPARATOR),e.items.push({key:"borders",name:"Borders",disabled:function(){return this.selection.selectedHeader.corner},submenu:{items:[{key:"borders:top",name:function(){var e="Top";return T(this,"top")&&(e=k(e)),e},callback:function(){var e=T(this,"top");O.call(this,this.getSelectedRange(),"top",e)}},{key:"borders:right",name:function(){var e="Right";return T(this,"right")&&(e=k(e)),e},callback:function(){var e=T(this,"right");O.call(this,this.getSelectedRange(),"right",e)}},{key:"borders:bottom",name:function(){var e="Bottom";return T(this,"bottom")&&(e=k(e)),e},callback:function(){var e=T(this,"bottom");O.call(this,this.getSelectedRange(),"bottom",e)}},{key:"borders:left",name:function(){var e="Left";return T(this,"left")&&(e=k(e)),e},callback:function(){var e=T(this,"left");O.call(this,this.getSelectedRange(),"left",e)}},{key:"borders:no_borders",name:"Remove border(s)",callback:function(){O.call(this,this.getSelectedRange(),"noBorders")},disabled:function(){return!T(this)}}]}}))};u.hooks.add("beforeInit",f),u.hooks.add("afterContextMenuDefaultOptions",x),u.hooks.add("afterInit",function(){var e=this.getSettings().customBorders;if(e){for(var t=0;t<e.length;t++)e[t].range?w.call(this,e[t]):m.call(this,e[t].row,e[t].col,e[t]);this.render(),this.view.wt.draw(!0)}}),u.CustomBorders=n},{"3rdparty/walkontable/src/cell/range":7,"3rdparty/walkontable/src/selection":19,browser:24,plugins:61}],92:[function(e,t,o){"use strict";function n(){this.boundaries=null,this.callback=null}Object.defineProperties(o,{DragToScroll:{get:function(){return n}},__esModule:{value:!0}});var r,i,s,a=((r=e("browser"))&&r.__esModule&&r||{default:r}).default,l=((i=e("eventManager"))&&i.__esModule&&i||{default:i}).eventManager;((s=e("plugins"))&&s.__esModule&&s||{default:s}).registerPlugin;a.plugins.DragToScroll=n,n.prototype.setBoundaries=function(e){this.boundaries=e},n.prototype.setCallback=function(e){this.callback=e},n.prototype.check=function(e,t){var o=0,n=0;t<this.boundaries.top?n=t-this.boundaries.top:t>this.boundaries.bottom&&(n=t-this.boundaries.bottom),e<this.boundaries.left?o=e-this.boundaries.left:e>this.boundaries.right&&(o=e-this.boundaries.right),this.callback(o,n)};var u,c=function(e){e.dragToScrollListening=!1;var t=e.view.wt.wtTable.holder;u=new n,t!==window&&(u.setBoundaries(t.getBoundingClientRect()),u.setCallback(function(e,o){e<0?t.scrollLeft-=50:e>0&&(t.scrollLeft+=50),o<0?t.scrollTop-=20:o>0&&(t.scrollTop+=20)}),e.dragToScrollListening=!0)};a.hooks.add("afterInit",function(){var e=this,t=l(this);t.addEventListener(document,"mouseup",function(){e.dragToScrollListening=!1}),t.addEventListener(document,"mousemove",function(t){e.dragToScrollListening&&u.check(t.clientX,t.clientY)})}),a.hooks.add("afterDestroy",function(){l(this).clear()}),a.hooks.add("afterOnCellMouseDown",function(){c(this)}),a.hooks.add("afterOnCellCornerMouseDown",function(){c(this)}),a.plugins.DragToScroll=n},{browser:24,eventManager:42,plugins:61}],93:[function(e,t,o){"use strict";function n(e){return{key:"freeze_column",name:"Freeze this column",callback:function(){var t=this.getSelectedRange().from.col;e.freezeColumn(t),this.render(),this.view.wt.wtOverlays.adjustElementsSize(!0)},hidden:function(){var e=this.getSelectedRange(),t=!1;return void 0===e?t=!0:(e.from.col!==e.to.col||e.from.col<=this.getSettings().fixedColumnsLeft-1)&&(t=!0),t}}}Object.defineProperties(o,{freezeColumnItem:{get:function(){return n}},__esModule:{value:!0}})},{}],94:[function(e,t,o){"use strict";function n(e){return{key:"unfreeze_column",name:"Unfreeze this column",callback:function(){var t=this.getSelectedRange().from.col;e.unfreezeColumn(t),this.render(),this.view.wt.wtOverlays.adjustElementsSize(!0)},hidden:function(){var e=this.getSelectedRange(),t=!1;return void 0===e?t=!0:(e.from.col!==e.to.col||e.from.col>=this.getSettings().fixedColumnsLeft)&&(t=!0),t}}}Object.defineProperties(o,{unfreezeColumnItem:{get:function(){return n}},__esModule:{value:!0}})},{}],95:[function(e,t,o){"use strict";Object.defineProperties(o,{ManualColumnFreeze:{get:function(){return m}},__esModule:{value:!0}});var n,r,i,s,a,l,u=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,c=((r=e("_base"))&&r.__esModule&&r||{default:r}).default,d=((i=e("plugins"))&&i.__esModule&&i||{default:i}).registerPlugin,h=((s=e("helpers/array"))&&s.__esModule&&s||{default:s}).arrayEach,f=((a=e("contextMenuItem/freezeColumn"))&&a.__esModule&&a||{default:a}).freezeColumnItem,p=((l=e("contextMenuItem/unfreezeColumn"))&&l.__esModule&&l||{default:l}).unfreezeColumnItem,g=new WeakMap,m=function(e){$traceurRuntime.superConstructor(w).call(this,e),g.set(this,{moveByFreeze:!1,afterFirstUse:!1}),this.frozenColumnsBasePositions=[],this.manualColumnMovePlugin=void 0},w=m;$traceurRuntime.createClass(m,{isEnabled:function(){return!!this.hot.getSettings().manualColumnFreeze},enablePlugin:function(){var e=this;this.enabled||(this.addHook("afterContextMenuDefaultOptions",function(t){return e.addContextMenuEntry(t)}),this.addHook("afterInit",function(){return e.onAfterInit()}),this.addHook("beforeColumnMove",function(t,o){return e.onBeforeColumnMove(t,o)}),$traceurRuntime.superGet(this,w.prototype,"enablePlugin").call(this))},disablePlugin:function(){var e=g.get(this);e.afterFirstUse=!1,e.moveByFreeze=!1,$traceurRuntime.superGet(this,w.prototype,"disablePlugin").call(this)},updatePlugin:function(){this.disablePlugin(),this.enablePlugin(),$traceurRuntime.superGet(this,w.prototype,"updatePlugin").call(this)},freezeColumn:function(e){var t=g.get(this),o=this.hot.getSettings();t.afterFirstUse||(t.afterFirstUse=!0),o.fixedColumnsLeft===this.hot.countCols()||e<=o.fixedColumnsLeft-1||(t.moveByFreeze=!0,e!==this.getMovePlugin().columnsMapper.getValueByIndex(e)&&(this.frozenColumnsBasePositions[o.fixedColumnsLeft]=e),this.getMovePlugin().moveColumn(e,o.fixedColumnsLeft++))},unfreezeColumn:function(e){var t=g.get(this),o=this.hot.getSettings();if(t.afterFirstUse||(t.afterFirstUse=!0),!(o.fixedColumnsLeft<=0||e>o.fixedColumnsLeft-1)){var n=this.getBestColumnReturnPosition(e);t.moveByFreeze=!0,o.fixedColumnsLeft--,this.getMovePlugin().moveColumn(e,n+1)}},getMovePlugin:function(){return this.manualColumnMovePlugin||(this.manualColumnMovePlugin=this.hot.getPlugin("manualColumnMove")),this.manualColumnMovePlugin},getBestColumnReturnPosition:function(e){var t,o=this.getMovePlugin(),n=this.hot.getSettings(),r=n.fixedColumnsLeft,i=o.columnsMapper.getValueByIndex(r);if(null==this.frozenColumnsBasePositions[e])for(t=o.columnsMapper.getValueByIndex(e);i<t;)r++,i=o.columnsMapper.getValueByIndex(r);else{for(t=this.frozenColumnsBasePositions[e],this.frozenColumnsBasePositions[e]=void 0;i<=t;)r++,i=o.columnsMapper.getValueByIndex(r);r=i}return r-1},addContextMenuEntry:function(e){e.items.push(u.plugins.ContextMenu.SEPARATOR,f(this),p(this))},onAfterInit:function(){this.getMovePlugin().isEnabled()||this.getMovePlugin().enablePlugin()},onBeforeColumnMove:function(e,t){var o=g.get(this);if(o.afterFirstUse&&!o.moveByFreeze){var n=this.hot.getSettings().fixedColumnsLeft,r=t<n;if(r||h(e,function(e,t,o){if(e<n)return r=!0,!1}),r)return!1}o.moveByFreeze&&(o.moveByFreeze=!1)},destroy:function(){$traceurRuntime.superGet(this,w.prototype,"destroy").call(this)}},{},c),d("manualColumnFreeze",m)},{_base:62,browser:24,"contextMenuItem/freezeColumn":93,"contextMenuItem/unfreezeColumn":94,"helpers/array":43,plugins:61}],96:[function(e,t,o){"use strict";Object.defineProperties(o,{ColumnsMapper:{get:function(){return f}},__esModule:{value:!0}});var n,r,i,s,a,l=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,u=((r=e("mixins/arrayMapper"))&&r.__esModule&&r||{default:r}).arrayMapper,c=((i=e("helpers/array"))&&i.__esModule&&i||{default:i}).arrayFilter,d=((s=e("helpers/object"))&&s.__esModule&&s||{default:s}).mixin,h=((a=e("helpers/number"))&&a.__esModule&&a||{default:a}).rangeEach,f=function(e){this.manualColumnMove=e};$traceurRuntime.createClass(f,{createMap:function(e){var t=this,o=void 0===e?this._arrayMap.length:e;this._arrayMap.length=0,h(o-1,function(e){t._arrayMap[e]=e})},destroy:function(){this._arrayMap=null},moveColumn:function(e,t){var o=this._arrayMap[e];this._arrayMap[e]=null,this._arrayMap.splice(t,0,o)},clearNull:function(){this._arrayMap=c(this._arrayMap,function(e){return null!==e})}},{}),d(f,u),l.utils.ManualColumnMoveColumnsMapper=f},{browser:24,"helpers/array":43,"helpers/number":52,"helpers/object":53,"mixins/arrayMapper":57}],97:[function(e,t,o){"use strict";Object.defineProperties(o,{ManualColumnMove:{get:function(){return O}},__esModule:{value:!0}});var n,r,i,s,a,l,u,c,d,h,f=((n=e("_base.js"))&&n.__esModule&&n||{default:n}).default,p=((r=e("browser"))&&r.__esModule&&r||{default:r}).default,g=((i=e("helpers/array"))&&i.__esModule&&i||{default:i}).arrayEach,m=(s=e("helpers/dom/element"))&&s.__esModule&&s||{default:s},w=m.addClass,v=m.removeClass,y=m.offset,b=((a=e("helpers/number"))&&a.__esModule&&a||{default:a}).rangeEach,C=((l=e("eventManager"))&&l.__esModule&&l||{default:l}).eventManager,_=((u=e("plugins"))&&u.__esModule&&u||{default:u}).registerPlugin,R=((c=e("columnsMapper"))&&c.__esModule&&c||{default:c}).ColumnsMapper,M=((d=e("ui/backlight"))&&d.__esModule&&d||{default:d}).BacklightUI,S=((h=e("ui/guideline"))&&h.__esModule&&h||{default:h}).GuidelineUI,E=new WeakMap,O=function(e){$traceurRuntime.superConstructor(T).call(this,e),E.set(this,{columnsToMove:[],countCols:0,fixedColumns:0,pressed:void 0,disallowMoving:void 0,target:{eventPageX:void 0,coords:void 0,TD:void 0,col:void 0}}),this.removedColumns=[],this.columnsMapper=new R(this),this.eventManager=C(this),this.backlight=new M(e),this.guideline=new S(e)},T=O;$traceurRuntime.createClass(O,{isEnabled:function(){return!!this.hot.getSettings().manualColumnMove},enablePlugin:function(){var e=this;this.enabled||(this.addHook("beforeOnCellMouseDown",function(t,o,n,r){return e.onBeforeOnCellMouseDown(t,o,n,r)}),this.addHook("beforeOnCellMouseOver",function(t,o,n,r){return e.onBeforeOnCellMouseOver(t,o,n,r)}),this.addHook("afterScrollVertically",function(){return e.onAfterScrollVertically()}),this.addHook("modifyCol",function(t,o){return e.onModifyCol(t,o)}),this.addHook("beforeRemoveCol",function(t,o){return e.onBeforeRemoveCol(t,o)}),this.addHook("afterRemoveCol",function(t,o){return e.onAfterRemoveCol(t,o)}),this.addHook("afterCreateCol",function(t,o){return e.onAfterCreateCol(t,o)}),this.addHook("afterLoadData",function(t){return e.onAfterLoadData(t)}),this.addHook("unmodifyCol",function(t){return e.onUnmodifyCol(t)}),this.registerEvents(),w(this.hot.rootElement,"ht__manualColumnMove"),$traceurRuntime.superGet(this,T.prototype,"enablePlugin").call(this))},updatePlugin:function(){this.disablePlugin(),this.enablePlugin(),this.onAfterPluginsInitialized(),$traceurRuntime.superGet(this,T.prototype,"updatePlugin").call(this)},disablePlugin:function(){var e=this.hot.getSettings().manualColumnMove;Array.isArray(e)&&this.columnsMapper.clearMap(),v(this.hot.rootElement,"ht__manualColumnMove"),this.unregisterEvents(),this.backlight.destroy(),this.guideline.destroy(),$traceurRuntime.superGet(this,T.prototype,"disablePlugin").call(this)},moveColumn:function(e,t){this.moveColumns([e],t)},moveColumns:function(e,t){var o=this,n=E.get(this),r=this.hot.runHooks("beforeColumnMove",e,t);n.disallowMoving=!r,r!==!1&&(g(e,function(e,t,n){n[t]=o.columnsMapper.getValueByIndex(e)}),g(e,function(e,n){var r=o.columnsMapper.getIndexByValue(e);r!==t&&o.columnsMapper.moveColumn(r,t+n)}),this.columnsMapper.clearNull()),this.hot.runHooks("afterColumnMove",e,t)},changeSelection:function(e,t){var o=this.hot.selection,n=this.hot.countRows()-1;o.setRangeStartOnly(new WalkontableCellCoords(0,e)),o.setRangeEnd(new WalkontableCellCoords(n,t),!1)},getColumnsWidth:function(e,t){for(var o=0,n=e;n<t;n++){var r=0;r=n<0?this.hot.view.wt.wtTable.getColumnWidth(n)||0:this.hot.view.wt.wtTable.getStretchedColumnWidth(n)||0,o+=r}return o},initialSettings:function(){var e=this.hot.getSettings().manualColumnMove;Array.isArray(e)?this.moveColumns(e,0):void 0!==e&&this.persistentStateLoad()},isFixedColumnsLeft:function(e){return e<this.hot.getSettings().fixedColumnsLeft},persistentStateSave:function(){p.hooks.run(this.hot,"persistentStateSave","manualColumnMove",this.columnsMapper._arrayMap)},persistentStateLoad:function(){var e={};p.hooks.run(this.hot,"persistentStateLoad","manualColumnMove",e),e.value&&(this.columnsMapper._arrayMap=e.value)},prepareColumnsToMoving:function(e,t){var o=[];return b(e,t,function(e){o.push(e)}),o},refreshPositions:function(){var e=E.get(this),t=this.hot.view.wt.wtTable.getFirstVisibleColumn(),o=this.hot.view.wt.wtTable.getLastVisibleColumn(),n=this.hot.view.wt.wtTable,r=this.hot.view.wt.wtOverlays.scrollableElement,i="number"==typeof r.scrollX?r.scrollX:r.scrollLeft,s=this.hot.view.THEAD.offsetLeft+this.getColumnsWidth(0,e.coordsColumn),a=e.target.eventPageX-(e.rootElementOffset-(void 0===r.scrollX?i:0)),l=n.hider.offsetWidth,u=n.TBODY.offsetLeft,c=this.backlight.getOffset().left,d=this.backlight.getSize().width,h=0;if(e.rootElementOffset+n.holder.offsetWidth+i<e.target.eventPageX&&e.coordsColumn<e.countCols&&e.coordsColumn++,e.hasRowHeaders&&(h=this.hot.view.wt.wtOverlays.leftOverlay.clone.wtTable.getColumnHeader(-1).offsetWidth),this.isFixedColumnsLeft(e.coordsColumn)&&(s+=i),s+=h,
38
- e.coordsColumn<0)e.fixedColumns>0?e.target.col=0:e.target.col=t>0?t-1:t;else if(e.target.TD.offsetWidth/2+s<=a){var f=e.coordsColumn>=e.countCols?e.countCols-1:e.coordsColumn;e.target.col=f+1,s+=e.target.TD.offsetWidth,e.target.col>o&&this.hot.scrollViewportTo(void 0,o+1,void 0,!0)}else e.target.col=e.coordsColumn,e.target.col<=t&&e.target.col>=e.fixedColumns&&this.hot.scrollViewportTo(void 0,t-1);e.target.col<=t&&e.target.col>=e.fixedColumns&&this.hot.scrollViewportTo(void 0,t-1);var p=a,g=s;a+d+c>=l?p=l-d-c:a+c<u+h&&(p=u+h+Math.abs(c)),s>=l-1?g=l-1:0===g?g=1:void 0!==r.scrollX&&e.coordsColumn<e.fixedColumns&&(g-=e.rootElementOffset<=r.scrollX?e.rootElementOffset:0),this.backlight.setPosition(null,p),this.guideline.setPosition(null,g)},updateColumnsMapper:function(){var e=this.hot.countSourceCols(),t=this.columnsMapper._arrayMap.length;if(0===t)this.columnsMapper.createMap(e||this.hot.getSettings().startCols);else if(t<e){var o=e-t;this.columnsMapper.insertItems(t,o)}else if(t>e){var n=e-1,r=[];g(this.columnsMapper._arrayMap,function(e,t,o){e>n&&r.push(t)}),this.columnsMapper.removeItems(r)}},registerEvents:function(){var e=this;this.eventManager.addEventListener(document.documentElement,"mousemove",function(t){return e.onMouseMove(t)}),this.eventManager.addEventListener(document.documentElement,"mouseup",function(){return e.onMouseUp()})},unregisterEvents:function(){this.eventManager.clear()},onBeforeOnCellMouseDown:function(e,t,o,n){var r=this.hot.view.wt.wtTable,i=this.hot.selection.selectedHeader.cols,s=this.hot.getSelectedRange(),a=E.get(this),l=e.realTarget.className.indexOf("columnSorting")>-1;if(!s||!i||a.pressed||0!==e.button||l)return a.pressed=!1,a.columnsToMove.length=0,void v(this.hot.rootElement,["on-moving--columns","show-ui"]);var u=this.guideline.isBuilt()&&!this.guideline.isAppended(),c=this.backlight.isBuilt()&&!this.backlight.isAppended();u&&c&&(this.guideline.appendTo(r.hider),this.backlight.appendTo(r.hider));var d=s,h=d.from,f=d.to,p=Math.min(h.col,f.col),g=Math.max(h.col,f.col);if(t.row<0&&t.col>=p&&t.col<=g){n.column=!0,a.pressed=!0,a.target.eventPageX=e.pageX,a.coordsColumn=t.col,a.target.TD=o,a.target.col=t.col,a.columnsToMove=this.prepareColumnsToMoving(p,g),a.hasRowHeaders=!!this.hot.getSettings().rowHeaders,a.countCols=this.hot.countCols(),a.fixedColumns=this.hot.getSettings().fixedColumnsLeft,a.rootElementOffset=y(this.hot.rootElement).left;var m=a.hasRowHeaders?-1:0,b=r.holder.scrollTop+r.getColumnHeaderHeight(0)+1,C=t.col<a.fixedColumns,_=this.hot.view.wt.wtOverlays.scrollableElement,R=_.scrollX?_.scrollX-a.rootElementOffset:0,M=e.layerX-(C?R:0),S=Math.abs(this.getColumnsWidth(p,t.col)+M);this.backlight.setPosition(b,this.getColumnsWidth(m,p)+S),this.backlight.setSize(this.getColumnsWidth(p,g+1),r.hider.offsetHeight-b),this.backlight.setOffset(null,S*-1),w(this.hot.rootElement,"on-moving--columns")}else v(this.hot.rootElement,"after-selection--columns"),a.pressed=!1,a.columnsToMove.length=0},onMouseMove:function(e){var t=E.get(this);if(t.pressed){if(e.realTarget===this.backlight.element){var o=this.backlight.getSize().width;this.backlight.setSize(0),setTimeout(function(){this.backlight.setPosition(o)})}t.target.eventPageX=e.pageX,this.refreshPositions()}},onBeforeOnCellMouseOver:function(e,t,o,n){var r=this.hot.getSelectedRange(),i=E.get(this);r&&i.pressed&&(i.columnsToMove.indexOf(t.col)>-1?v(this.hot.rootElement,"show-ui"):w(this.hot.rootElement,"show-ui"),n.row=!0,n.column=!0,n.cell=!0,i.coordsColumn=t.col,i.target.TD=o)},onMouseUp:function(){var e=E.get(this);if(e.coordsColumn=void 0,e.pressed=!1,e.backlightWidth=0,v(this.hot.rootElement,["on-moving--columns","show-ui","after-selection--columns"]),this.hot.selection.selectedHeader.cols&&w(this.hot.rootElement,"after-selection--columns"),!(e.columnsToMove.length<1||void 0===e.target.col||e.columnsToMove.indexOf(e.target.col)>-1)){if(this.moveColumns(e.columnsToMove,e.target.col),this.persistentStateSave(),this.hot.render(),this.hot.view.wt.wtOverlays.adjustElementsSize(!0),!e.disallowMoving){var t=this.columnsMapper.getIndexByValue(e.columnsToMove[0]),o=this.columnsMapper.getIndexByValue(e.columnsToMove[e.columnsToMove.length-1]);this.changeSelection(t,o)}e.columnsToMove.length=0}},onAfterScrollVertically:function(){var e=this.hot.view.wt.wtTable,t=e.getColumnHeaderHeight(0)+1,o=e.holder.scrollTop,n=t+o;this.backlight.setPosition(n),this.backlight.setSize(null,e.hider.offsetHeight-n)},onAfterCreateCol:function(e,t){this.columnsMapper.shiftItems(e,t)},onBeforeRemoveCol:function(e,t){var o=this;this.removedColumns.length=0,e!==!1&&b(e,e+t-1,function(e){o.removedColumns.push(o.hot.runHooks("modifyCol",e,o.pluginName))})},onAfterRemoveCol:function(e,t){this.columnsMapper.unshiftItems(this.removedColumns)},onAfterLoadData:function(e){this.updateColumnsMapper()},onModifyCol:function(e,t){if(t!==this.pluginName){var o=this.columnsMapper.getValueByIndex(e);e=null===o?e:o}return e},onUnmodifyCol:function(e){var t=this.columnsMapper.getIndexByValue(e);return null===t?e:t},onAfterPluginsInitialized:function(){this.updateColumnsMapper(),this.initialSettings(),this.backlight.build(),this.guideline.build()},destroy:function(){this.backlight.destroy(),this.guideline.destroy(),$traceurRuntime.superGet(this,T.prototype,"destroy").call(this)}},{},f),_("ManualColumnMove",O),p.hooks.register("beforeColumnMove"),p.hooks.register("afterColumnMove"),p.hooks.register("unmodifyCol")},{"_base.js":62,browser:24,columnsMapper:96,eventManager:42,"helpers/array":43,"helpers/dom/element":47,"helpers/number":52,plugins:61,"ui/backlight":99,"ui/guideline":100}],98:[function(e,t,o){"use strict";Object.defineProperties(o,{BaseUI:{get:function(){return i}},__esModule:{value:!0}});var n,r=((n=e("helpers/number"))&&n.__esModule&&n||{default:n}).isNumeric,i=function(e){this.hot=e,this._element=null,this.state=0};$traceurRuntime.createClass(i,{appendTo:function(e){e.appendChild(this._element),this.state=2},build:function(){this._element=document.createElement("div"),this.state=1},destroy:function(){this.isAppended()&&this._element.parentElement.removeChild(this._element),this._element=null,this.state=0},isAppended:function(){return 2===this.state},isBuilt:function(){return this.state>=1},setPosition:function(e,t){r(e)&&(this._element.style.top=e+"px"),r(t)&&(this._element.style.left=t+"px")},getPosition:function(){return{top:this._element.style.top?parseInt(this._element.style.top,10):0,left:this._element.style.left?parseInt(this._element.style.left,10):0}},setSize:function(e,t){r(e)&&(this._element.style.width=e+"px"),r(t)&&(this._element.style.height=t+"px")},getSize:function(){return{width:this._element.style.width?parseInt(this._element.style.width,10):0,height:this._element.style.height?parseInt(this._element.style.height,10):0}},setOffset:function(e,t){r(e)&&(this._element.style.marginTop=e+"px"),r(t)&&(this._element.style.marginLeft=t+"px")},getOffset:function(){return{top:this._element.style.marginTop?parseInt(this._element.style.marginTop,10):0,left:this._element.style.marginLeft?parseInt(this._element.style.marginLeft,10):0}}},{})},{"helpers/number":52}],99:[function(e,t,o){"use strict";Object.defineProperties(o,{BacklightUI:{get:function(){return a}},__esModule:{value:!0}});var n,r,i=((n=e("_base"))&&n.__esModule&&n||{default:n}).BaseUI,s=((r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r}).addClass,a=function(e){$traceurRuntime.superConstructor(l).call(this,e)},l=a;$traceurRuntime.createClass(a,{build:function(){$traceurRuntime.superGet(this,l.prototype,"build").call(this),s(this._element,"ht__manualColumnMove--backlight")}},{},i)},{_base:98,"helpers/dom/element":47}],100:[function(e,t,o){"use strict";Object.defineProperties(o,{GuidelineUI:{get:function(){return a}},__esModule:{value:!0}});var n,r,i=((n=e("_base"))&&n.__esModule&&n||{default:n}).BaseUI,s=((r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r}).addClass,a=function(e){$traceurRuntime.superConstructor(l).call(this,e)},l=a;$traceurRuntime.createClass(a,{build:function(){$traceurRuntime.superGet(this,l.prototype,"build").call(this),s(this._element,"ht__manualColumnMove--guideline")}},{},i)},{_base:98,"helpers/dom/element":47}],101:[function(e,t,o){"use strict";Object.defineProperties(o,{ManualColumnResize:{get:function(){return M}},__esModule:{value:!0}});var n,r,i,s,a,l,u,c,d=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,h=((r=e("_base.js"))&&r.__esModule&&r||{default:r}).default,f=(i=e("helpers/dom/element"))&&i.__esModule&&i||{default:i},p=f.addClass,g=f.hasClass,m=f.removeClass,w=f.outerHeight,v=((s=e("eventManager"))&&s.__esModule&&s||{default:s}).eventManager,y=(a=e("helpers/dom/event"))&&a.__esModule&&a||{default:a},b=y.pageX,C=(y.pageY,((l=e("helpers/array"))&&l.__esModule&&l||{default:l}).arrayEach),_=((u=e("helpers/number"))&&u.__esModule&&u||{default:u}).rangeEach,R=((c=e("plugins"))&&c.__esModule&&c||{default:c}).registerPlugin,M=function(e){$traceurRuntime.superConstructor(S).call(this,e),this.currentTH=null,this.currentCol=null,this.selectedCols=[],this.currentWidth=null,this.newSize=null,this.startY=null,this.startWidth=null,this.startOffset=null,this.handle=document.createElement("DIV"),this.guide=document.createElement("DIV"),this.eventManager=v(this),this.pressed=null,this.dblclick=0,this.autoresizeTimeout=null,this.manualColumnWidths=[],p(this.handle,"manualColumnResizer"),p(this.guide,"manualColumnResizerGuide")},S=M;$traceurRuntime.createClass(M,{isEnabled:function(){return this.hot.getSettings().manualColumnResize},enablePlugin:function(){var e=this;if(!this.enabled){this.manualColumnWidths=[];var t=this.hot.getSettings().manualColumnResize,o=this.loadManualColumnWidths();this.addHook("modifyColWidth",function(t,o){return e.onModifyColWidth(t,o)}),this.addHook("beforeStretchingColumnWidth",function(t,o){return e.onBeforeStretchingColumnWidth(t,o)}),this.addHook("beforeColumnResize",function(t,o,n){return e.onBeforeColumnResize(t,o,n)}),void 0!==o?this.manualColumnWidths=o:Array.isArray(t)?this.manualColumnWidths=t:this.manualColumnWidths=[],d.hooks.register("beforeColumnResize"),d.hooks.register("afterColumnResize"),this.bindEvents(),$traceurRuntime.superGet(this,S.prototype,"enablePlugin").call(this)}},updatePlugin:function(){var e=this.hot.getSettings().manualColumnResize;Array.isArray(e)?this.manualColumnWidths=e:e||(this.manualColumnWidths=[])},disablePlugin:function(){$traceurRuntime.superGet(this,S.prototype,"disablePlugin").call(this)},saveManualColumnWidths:function(){this.hot.runHooks("persistentStateSave","manualColumnWidths",this.manualColumnWidths)},loadManualColumnWidths:function(){var e={};return this.hot.runHooks("persistentStateLoad","manualColumnWidths",e),e.value},setupHandlePosition:function(e){var t=this;if(!e.parentNode)return!1;this.currentTH=e;var o=this.hot.view.wt.wtTable.getCoords(e).col,n=w(this.currentTH);if(o>=0){var r=this.currentTH.getBoundingClientRect();if(this.currentCol=o,this.selectedCols=[],this.hot.selection.isSelected()&&this.hot.selection.selectedHeader.cols){var i=this.hot.getSelectedRange(),s=i.from,a=i.to,l=s.col,u=a.col;l>=u&&(l=a.col,u=s.col),this.currentCol>=l&&this.currentCol<=u?_(l,u,function(e){return t.selectedCols.push(e)}):this.selectedCols.push(this.currentCol)}else this.selectedCols.push(this.currentCol);this.startOffset=r.left-6,this.startWidth=parseInt(r.width,10),this.handle.style.top=r.top+"px",this.handle.style.left=this.startOffset+this.startWidth+"px",this.handle.style.height=n+"px",this.hot.rootElement.appendChild(this.handle)}},refreshHandlePosition:function(){this.handle.style.left=this.startOffset+this.currentWidth+"px"},setupGuidePosition:function(){var e=parseInt(w(this.handle),10),t=parseInt(this.handle.style.top,10)+e,o=parseInt(this.hot.view.maximumVisibleElementHeight(0),10);p(this.handle,"active"),p(this.guide,"active"),this.guide.style.top=t+"px",this.guide.style.left=this.handle.style.left,this.guide.style.height=o-e+"px",this.hot.rootElement.appendChild(this.guide)},refreshGuidePosition:function(){this.guide.style.left=this.handle.style.left},hideHandleAndGuide:function(){m(this.handle,"active"),m(this.guide,"active")},checkIfColumnHeader:function(e){if(e!=this.hot.rootElement){var t=e.parentNode;return"THEAD"===t.tagName||this.checkIfColumnHeader(t)}return!1},getTHFromTargetElement:function(e){return"TABLE"!=e.tagName?"TH"==e.tagName?e:this.getTHFromTargetElement(e.parentNode):null},onMouseOver:function(e){if(this.checkIfColumnHeader(e.target)){var t=this.getTHFromTargetElement(e.target);if(!t)return;var o=t.getAttribute("colspan");!t||null!==o&&1!==o||this.pressed||this.setupHandlePosition(t)}},afterMouseDownTimeout:function(){var e=this,t=function(){e.hot.forceFullRender=!0,e.hot.view.render(),e.hot.view.wt.wtOverlays.adjustElementsSize(!0)},o=function(o,n){var r=e.hot.runHooks("beforeColumnResize",o,e.newSize,!0);void 0!==r&&(e.newSize=r),"all"===e.hot.getSettings().stretchH?e.clearManualSize(o):e.setManualSize(o,e.newSize),n&&t(),e.saveManualColumnWidths(),e.hot.runHooks("afterColumnResize",o,e.newSize,!0)};if(this.dblclick>=2){this.selectedCols.length>1?(C(this.selectedCols,function(e){o(e)}),t()):C(this.selectedCols,function(e){o(e,!0)})}this.dblclick=0,this.autoresizeTimeout=null},onMouseDown:function(e){var t=this;g(e.target,"manualColumnResizer")&&(this.setupGuidePosition(),this.pressed=this.hot,null===this.autoresizeTimeout&&(this.autoresizeTimeout=setTimeout(function(){return t.afterMouseDownTimeout()},500),this.hot._registerTimeout(this.autoresizeTimeout)),this.dblclick++,this.startX=b(e),this.newSize=this.startWidth)},onMouseMove:function(e){var t=this;this.pressed&&(this.currentWidth=this.startWidth+(b(e)-this.startX),C(this.selectedCols,function(e){t.newSize=t.setManualSize(e,t.currentWidth)}),this.refreshHandlePosition(),this.refreshGuidePosition())},onMouseUp:function(e){var t=this,o=function(){t.hot.forceFullRender=!0,t.hot.view.render(),t.hot.view.wt.wtOverlays.adjustElementsSize(!0)},n=function(e,n){t.hot.runHooks("beforeColumnResize",e,t.newSize),n&&o(),t.saveManualColumnWidths(),t.hot.runHooks("afterColumnResize",e,t.newSize)};if(this.pressed){if(this.hideHandleAndGuide(),this.pressed=!1,this.newSize!=this.startWidth){this.selectedCols.length>1?(C(this.selectedCols,function(e){n(e)}),o()):C(this.selectedCols,function(e){n(e,!0)})}this.setupHandlePosition(this.currentTH)}},bindEvents:function(){var e=this;this.eventManager.addEventListener(this.hot.rootElement,"mouseover",function(t){return e.onMouseOver(t)}),this.eventManager.addEventListener(this.hot.rootElement,"mousedown",function(t){return e.onMouseDown(t)}),this.eventManager.addEventListener(window,"mousemove",function(t){return e.onMouseMove(t)}),this.eventManager.addEventListener(window,"mouseup",function(t){return e.onMouseUp(t)})},setManualSize:function(e,t){return t=Math.max(t,20),e=this.hot.runHooks("modifyCol",e),this.manualColumnWidths[e]=t,t},clearManualSize:function(e){e=this.hot.runHooks("modifyCol",e),this.manualColumnWidths[e]=void 0},onModifyColWidth:function(e,t){return this.enabled&&(t=this.hot.runHooks("modifyCol",t),this.hot.getSettings().manualColumnResize&&this.manualColumnWidths[t])?this.manualColumnWidths[t]:e},onBeforeStretchingColumnWidth:function(e,t){var o=this.manualColumnWidths[t];return void 0===o&&(o=e),o},onBeforeColumnResize:function(){this.hot.view.wt.wtViewport.hasOversizedColumnHeadersMarked={}}},{},h),R("manualColumnResize",M)},{"_base.js":62,browser:24,eventManager:42,"helpers/array":43,"helpers/dom/element":47,"helpers/dom/event":48,"helpers/number":52,plugins:61}],102:[function(e,t,o){"use strict";Object.defineProperties(o,{ManualRowMove:{get:function(){return O}},__esModule:{value:!0}});var n,r,i,s,a,l,u,c,d,h,f=((n=e("_base.js"))&&n.__esModule&&n||{default:n}).default,p=((r=e("browser"))&&r.__esModule&&r||{default:r}).default,g=((i=e("helpers/array"))&&i.__esModule&&i||{default:i}).arrayEach,m=(s=e("helpers/dom/element"))&&s.__esModule&&s||{default:s},w=m.addClass,v=m.removeClass,y=m.offset,b=((a=e("helpers/number"))&&a.__esModule&&a||{default:a}).rangeEach,C=((l=e("eventManager"))&&l.__esModule&&l||{default:l}).eventManager,_=((u=e("plugins"))&&u.__esModule&&u||{default:u}).registerPlugin,R=((c=e("rowsMapper"))&&c.__esModule&&c||{default:c}).RowsMapper,M=((d=e("ui/backlight"))&&d.__esModule&&d||{default:d}).BacklightUI,S=((h=e("ui/guideline"))&&h.__esModule&&h||{default:h}).GuidelineUI,E=new WeakMap,O=function(e){$traceurRuntime.superConstructor(T).call(this,e),E.set(this,{rowsToMove:[],pressed:void 0,disallowMoving:void 0,target:{eventPageY:void 0,coords:void 0,TD:void 0,row:void 0}}),this.removedRows=[],this.rowsMapper=new R(this),this.eventManager=C(this),this.backlight=new M(e),this.guideline=new S(e)},T=O;$traceurRuntime.createClass(O,{isEnabled:function(){return!!this.hot.getSettings().manualRowMove},enablePlugin:function(){var e=this;this.enabled||(this.addHook("beforeOnCellMouseDown",function(t,o,n,r){return e.onBeforeOnCellMouseDown(t,o,n,r)}),this.addHook("beforeOnCellMouseOver",function(t,o,n,r){return e.onBeforeOnCellMouseOver(t,o,n,r)}),this.addHook("afterScrollHorizontally",function(){return e.onAfterScrollHorizontally()}),this.addHook("modifyRow",function(t,o){return e.onModifyRow(t,o)}),this.addHook("beforeRemoveRow",function(t,o){return e.onBeforeRemoveRow(t,o)}),this.addHook("afterRemoveRow",function(t,o){return e.onAfterRemoveRow(t,o)}),this.addHook("afterCreateRow",function(t,o){return e.onAfterCreateRow(t,o)}),this.addHook("afterLoadData",function(t){return e.onAfterLoadData(t)}),this.addHook("beforeColumnSort",function(t,o){return e.onBeforeColumnSort(t,o)}),this.addHook("unmodifyRow",function(t){return e.onUnmodifyRow(t)}),this.registerEvents(),w(this.hot.rootElement,"ht__manualRowMove"),$traceurRuntime.superGet(this,T.prototype,"enablePlugin").call(this))},updatePlugin:function(){this.disablePlugin(),this.enablePlugin(),this.onAfterPluginsInitialized(),$traceurRuntime.superGet(this,T.prototype,"updatePlugin").call(this)},disablePlugin:function(){var e=this.hot.getSettings().manualRowMove;Array.isArray(e)&&this.rowsMapper.clearMap(),v(this.hot.rootElement,"ht__manualRowMove"),this.unregisterEvents(),this.backlight.destroy(),this.guideline.destroy(),$traceurRuntime.superGet(this,T.prototype,"disablePlugin").call(this)},moveRow:function(e,t){this.moveRows([e],t)},moveRows:function(e,t){var o=this,n=E.get(this),r=this.hot.runHooks("beforeRowMove",e,t);n.disallowMoving=r===!1,n.disallowMoving||(g(e,function(e,t,n){n[t]=o.rowsMapper.getValueByIndex(e)}),g(e,function(e,n){var r=o.rowsMapper.getIndexByValue(e);r!==t&&o.rowsMapper.moveRow(r,t+n)}),this.rowsMapper.clearNull()),this.hot.runHooks("afterRowMove",e,t)},changeSelection:function(e,t){var o=this.hot.selection,n=this.hot.countCols()-1;o.setRangeStartOnly(new WalkontableCellCoords(e,0)),o.setRangeEnd(new WalkontableCellCoords(t,n),!1)},getRowsHeight:function(e,t){for(var o=0,n=e;n<t;n++){o+=this.hot.view.wt.wtTable.getRowHeight(n)||23}return o},initialSettings:function(){var e=this.hot.getSettings().manualRowMove;if(Array.isArray(e))this.moveRows(e,0);else if(void 0!==e){var t=this.persistentStateLoad();t.length&&this.moveRows(t,0)}},isFixedRowTop:function(e){return e<this.hot.getSettings().fixedRowsTop},isFixedRowBottom:function(e){return e>this.hot.getSettings().fixedRowsBottom},persistentStateSave:function(){p.hooks.run(this.hot,"persistentStateSave","manualRowMove",this.rowsMapper._arrayMap)},persistentStateLoad:function(){var e={};return p.hooks.run(this.hot,"persistentStateLoad","manualRowMove",e),e.value?e.value:[]},prepareRowsToMoving:function(){var e=this.hot.getSelectedRange(),t=[];if(!e)return t;var o=e,n=o.from,r=o.to;return b(Math.min(n.row,r.row),Math.max(n.row,r.row),function(e){t.push(e)}),t},refreshPositions:function(){var e=E.get(this),t=e.target.coords,o=this.hot.view.wt.wtTable.getFirstVisibleRow(),n=this.hot.view.wt.wtTable.getLastVisibleRow(),r=this.hot.getSettings().fixedRowsTop,i=this.hot.countRows();t.row<r&&o>0&&this.hot.scrollViewportTo(o-1),t.row>=n&&n<i&&this.hot.scrollViewportTo(n+1,void 0,!0);var s=this.hot.view.wt.wtTable,a=e.target.TD,l=y(this.hot.rootElement),u=this.hot.view.THEAD.offsetHeight+this.getRowsHeight(0,t.row),c=e.target.eventPageY-l.top+s.holder.scrollTop,d=s.hider.offsetHeight,h=s.TBODY.offsetTop,f=this.backlight.getOffset().top,p=this.backlight.getSize().height;l.top+s.holder.offsetHeight<e.target.eventPageY&&e.target.coords.row++,this.isFixedRowTop(t.row)&&(u+=s.holder.scrollTop),t.row<0?e.target.row=o>0?o-1:o:a.offsetHeight/2+u<=c?(e.target.row=t.row+1,u+=0===t.row?a.offsetHeight-1:a.offsetHeight):e.target.row=t.row;var g=c,m=u;c+p+f>=d?g=d-p-f:c+f<h&&(g=h+Math.abs(f)),u>=d-1&&(m=d-1);var w=0;this.hot.view.wt.wtOverlays.topOverlay&&(w=this.hot.view.wt.wtOverlays.topOverlay.clone.wtTable.TABLE.offsetHeight),t.row>=r&&m-s.holder.scrollTop<w&&this.hot.scrollViewportTo(t.row),this.backlight.setPosition(g),this.guideline.setPosition(m)},updateRowsMapper:function(){var e=this.hot.countSourceRows(),t=this.rowsMapper._arrayMap.length;if(0===t)this.rowsMapper.createMap(e||this.hot.getSettings().startRows);else if(t<e){var o=e-t;this.rowsMapper.insertItems(t,o)}else if(t>e){var n=e-1,r=[];g(this.rowsMapper._arrayMap,function(e,t,o){e>n&&r.push(t)}),this.rowsMapper.removeItems(r)}},registerEvents:function(){var e=this;this.eventManager.addEventListener(document.documentElement,"mousemove",function(t){return e.onMouseMove(t)}),this.eventManager.addEventListener(document.documentElement,"mouseup",function(){return e.onMouseUp()})},unregisterEvents:function(){this.eventManager.clear()},onBeforeColumnSort:function(e,t){E.get(this).disallowMoving=void 0!==t},onBeforeOnCellMouseDown:function(e,t,o,n){var r=this.hot.view.wt.wtTable,i=this.hot.selection.selectedHeader.rows,s=this.hot.getSelectedRange(),a=E.get(this);if(!s||!i||a.pressed||0!==e.button)return a.pressed=!1,a.rowsToMove.length=0,void v(this.hot.rootElement,["on-moving--rows","show-ui"]);var l=this.guideline.isBuilt()&&!this.guideline.isAppended(),u=this.backlight.isBuilt()&&!this.backlight.isAppended();l&&u&&(this.guideline.appendTo(r.hider),this.backlight.appendTo(r.hider));var c=s,d=c.from,h=c.to,f=Math.min(d.row,h.row),p=Math.max(d.row,h.row);if(t.col<0&&t.row>=f&&t.row<=p){n.row=!0,a.pressed=!0,a.target.eventPageY=e.pageY,a.target.coords=t,a.target.TD=o,a.rowsToMove=this.prepareRowsToMoving();var g=r.holder.scrollLeft+r.getColumnWidth(-1);this.backlight.setPosition(null,g),this.backlight.setSize(r.hider.offsetWidth-g,this.getRowsHeight(f,p+1)),this.backlight.setOffset((this.getRowsHeight(f,t.row)+e.layerY)*-1,null),w(this.hot.rootElement,"on-moving--rows"),this.refreshPositions()}else v(this.hot.rootElement,"after-selection--rows"),a.pressed=!1,a.rowsToMove.length=0},onMouseMove:function(e){var t=E.get(this);if(t.pressed){if(e.realTarget===this.backlight.element){var o=this.backlight.getSize().height;this.backlight.setSize(null,0),setTimeout(function(){this.backlight.setPosition(null,o)})}t.target.eventPageY=e.pageY,this.refreshPositions()}},onBeforeOnCellMouseOver:function(e,t,o,n){var r=this.hot.getSelectedRange(),i=E.get(this);r&&i.pressed&&(i.rowsToMove.indexOf(t.row)>-1?v(this.hot.rootElement,"show-ui"):w(this.hot.rootElement,"show-ui"),n.row=!0,n.column=!0,n.cell=!0,i.target.coords=t,i.target.TD=o)},onMouseUp:function(){var e=E.get(this),t=e.target.row,o=e.rowsToMove.length;if(e.pressed=!1,e.backlightHeight=0,v(this.hot.rootElement,["on-moving--rows","show-ui","after-selection--rows"]),this.hot.selection.selectedHeader.rows&&w(this.hot.rootElement,"after-selection--rows"),!(o<1||void 0===t||e.rowsToMove.indexOf(t)>-1||e.rowsToMove[o-1]===t-1)){if(this.moveRows(e.rowsToMove,t),this.persistentStateSave(),this.hot.render(),!e.disallowMoving){var n=this.rowsMapper.getIndexByValue(e.rowsToMove[0]),r=this.rowsMapper.getIndexByValue(e.rowsToMove[o-1]);this.changeSelection(n,r)}e.rowsToMove.length=0}},onAfterScrollHorizontally:function(){var e=this.hot.view.wt.wtTable,t=e.getColumnWidth(-1),o=e.holder.scrollLeft,n=t+o;this.backlight.setPosition(null,n),this.backlight.setSize(e.hider.offsetWidth-n)},onAfterCreateRow:function(e,t){this.rowsMapper.shiftItems(e,t)},onBeforeRemoveRow:function(e,t){var o=this;this.removedRows.length=0,e!==!1&&b(e,e+t-1,function(e){o.removedRows.push(o.hot.runHooks("modifyRow",e,o.pluginName))})},onAfterRemoveRow:function(e,t){this.rowsMapper.unshiftItems(this.removedRows)},onAfterLoadData:function(e){this.updateRowsMapper()},onModifyRow:function(e,t){if(t!==this.pluginName){var o=this.rowsMapper.getValueByIndex(e);e=null===o?e:o}return e},onUnmodifyRow:function(e){var t=this.rowsMapper.getIndexByValue(e);return null===t?e:t},onAfterPluginsInitialized:function(){this.updateRowsMapper(),this.initialSettings(),this.backlight.build(),this.guideline.build()},destroy:function(){this.backlight.destroy(),this.guideline.destroy(),$traceurRuntime.superGet(this,T.prototype,"destroy").call(this)}},{},f),_("ManualRowMove",O),p.hooks.register("beforeRowMove"),p.hooks.register("afterRowMove"),p.hooks.register("unmodifyRow")},{"_base.js":62,browser:24,eventManager:42,"helpers/array":43,"helpers/dom/element":47,"helpers/number":52,plugins:61,rowsMapper:103,"ui/backlight":105,"ui/guideline":106}],103:[function(e,t,o){"use strict";Object.defineProperties(o,{RowsMapper:{get:function(){return f}},__esModule:{value:!0}});var n,r,i,s,a,l=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,u=((r=e("mixins/arrayMapper"))&&r.__esModule&&r||{default:r}).arrayMapper,c=((i=e("helpers/array"))&&i.__esModule&&i||{default:i}).arrayFilter,d=((s=e("helpers/object"))&&s.__esModule&&s||{default:s}).mixin,h=((a=e("helpers/number"))&&a.__esModule&&a||{default:a}).rangeEach,f=function(e){this.manualRowMove=e};$traceurRuntime.createClass(f,{createMap:function(e){var t=this,o=void 0===e?this._arrayMap.length:e;this._arrayMap.length=0,h(o-1,function(e){t._arrayMap[e]=e})},destroy:function(){this._arrayMap=null},moveRow:function(e,t){var o=this._arrayMap[e];this._arrayMap[e]=null,this._arrayMap.splice(t,0,o)},clearNull:function(){this._arrayMap=c(this._arrayMap,function(e){return null!==e})}},{}),d(f,u),l.utils.ManualRowMoveRowsMapper=f},{browser:24,"helpers/array":43,"helpers/number":52,"helpers/object":53,"mixins/arrayMapper":57}],104:[function(e,t,o){"use strict";Object.defineProperties(o,{BaseUI:{get:function(){return n}},__esModule:{value:!0}});var n=function(e){this.hot=e,this._element=null,this.state=0};$traceurRuntime.createClass(n,{appendTo:function(e){e.appendChild(this._element),this.state=2},build:function(){this._element=document.createElement("div"),this.state=1},destroy:function(){this.isAppended()&&this._element.parentElement.removeChild(this._element),this._element=null,this.state=0},isAppended:function(){return 2===this.state},isBuilt:function(){return this.state>=1},setPosition:function(e,t){e&&(this._element.style.top=e+"px"),t&&(this._element.style.left=t+"px")},getPosition:function(){return{top:this._element.style.top?parseInt(this._element.style.top,10):0,left:this._element.style.left?parseInt(this._element.style.left,10):0}},setSize:function(e,t){e&&(this._element.style.width=e+"px"),t&&(this._element.style.height=t+"px")},getSize:function(){return{width:this._element.style.width?parseInt(this._element.style.width,10):0,height:this._element.style.height?parseInt(this._element.style.height,10):0}},setOffset:function(e,t){e&&(this._element.style.marginTop=e+"px"),t&&(this._element.style.marginLeft=t+"px")},getOffset:function(){return{top:this._element.style.marginTop?parseInt(this._element.style.marginTop,10):0,left:this._element.style.marginLeft?parseInt(this._element.style.marginLeft,10):0}}},{})},{}],105:[function(e,t,o){"use strict";Object.defineProperties(o,{BacklightUI:{get:function(){return a}},__esModule:{value:!0}});var n,r,i=((n=e("_base"))&&n.__esModule&&n||{default:n}).BaseUI,s=((r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r}).addClass,a=function(e){$traceurRuntime.superConstructor(l).call(this,e)},l=a;$traceurRuntime.createClass(a,{build:function(){$traceurRuntime.superGet(this,l.prototype,"build").call(this),s(this._element,"ht__manualRowMove--backlight")}},{},i)},{_base:104,"helpers/dom/element":47}],106:[function(e,t,o){"use strict";Object.defineProperties(o,{GuidelineUI:{get:function(){return a}},__esModule:{value:!0}});var n,r,i=((n=e("_base"))&&n.__esModule&&n||{default:n}).BaseUI,s=((r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r}).addClass,a=function(e){$traceurRuntime.superConstructor(l).call(this,e)},l=a;$traceurRuntime.createClass(a,{build:function(){$traceurRuntime.superGet(this,l.prototype,"build").call(this),s(this._element,"ht__manualRowMove--guideline")}},{},i)},{_base:104,"helpers/dom/element":47}],107:[function(e,t,o){"use strict";Object.defineProperties(o,{ManualRowResize:{get:function(){return M}},__esModule:{value:!0}});var n,r,i,s,a,l,u,c,d=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,h=((r=e("_base.js"))&&r.__esModule&&r||{default:r}).default,f=(i=e("helpers/dom/element"))&&i.__esModule&&i||{default:i},p=f.addClass,g=f.hasClass,m=f.removeClass,w=f.outerWidth,v=((s=e("eventManager"))&&s.__esModule&&s||{default:s}).eventManager,y=(a=e("helpers/dom/event"))&&a.__esModule&&a||{default:a},b=(y.pageX,y.pageY),C=((l=e("helpers/array"))&&l.__esModule&&l||{default:l}).arrayEach,_=((u=e("helpers/number"))&&u.__esModule&&u||{default:u}).rangeEach,R=((c=e("plugins"))&&c.__esModule&&c||{default:c}).registerPlugin,M=function(e){$traceurRuntime.superConstructor(S).call(this,e),this.currentTH=null,this.currentRow=null,this.selectedRows=[],this.currentHeight=null,this.newSize=null,this.startY=null,this.startHeight=null,this.startOffset=null,this.handle=document.createElement("DIV"),this.guide=document.createElement("DIV"),this.eventManager=v(this),this.pressed=null,this.dblclick=0,this.autoresizeTimeout=null,this.manualRowHeights=[],p(this.handle,"manualRowResizer"),p(this.guide,"manualRowResizerGuide")},S=M;$traceurRuntime.createClass(M,{isEnabled:function(){return this.hot.getSettings().manualRowResize},enablePlugin:function(){var e=this;if(!this.enabled){this.manualRowHeights=[];var t=this.hot.getSettings().manualRowResize,o=this.loadManualRowHeights();void 0!==o?this.manualRowHeights=o:Array.isArray(t)?this.manualRowHeights=t:this.manualRowHeights=[],this.addHook("modifyRowHeight",function(t,o){return e.onModifyRowHeight(t,o)}),d.hooks.register("beforeRowResize"),d.hooks.register("afterRowResize"),this.bindEvents(),$traceurRuntime.superGet(this,S.prototype,"enablePlugin").call(this)}},updatePlugin:function(){var e=this.hot.getSettings().manualRowResize;Array.isArray(e)?this.manualRowHeights=e:e||(this.manualRowHeights=[])},disablePlugin:function(){$traceurRuntime.superGet(this,S.prototype,"disablePlugin").call(this)},saveManualRowHeights:function(){this.hot.runHooks("persistentStateSave","manualRowHeights",this.manualRowHeights)},loadManualRowHeights:function(){var e={};return this.hot.runHooks("persistentStateLoad","manualRowHeights",e),e.value},setupHandlePosition:function(e){var t=this;this.currentTH=e;var o=this.hot.view.wt.wtTable.getCoords(e).row,n=w(this.currentTH);if(o>=0){var r=this.currentTH.getBoundingClientRect();if(this.currentRow=o,this.selectedRows=[],this.hot.selection.isSelected()&&this.hot.selection.selectedHeader.rows){var i=this.hot.getSelectedRange(),s=i.from,a=i.to,l=s.row,u=a.row;l>=u&&(l=a.row,u=s.row),this.currentRow>=l&&this.currentRow<=u?_(l,u,function(e){return t.selectedRows.push(e)}):this.selectedRows.push(this.currentRow)}else this.selectedRows.push(this.currentRow);this.startOffset=r.top-6,this.startHeight=parseInt(r.height,10),this.handle.style.left=r.left+"px",this.handle.style.top=this.startOffset+this.startHeight+"px",this.handle.style.width=n+"px",this.hot.rootElement.appendChild(this.handle)}},refreshHandlePosition:function(){
39
- this.handle.style.top=this.startOffset+this.currentHeight+"px"},setupGuidePosition:function(){var e=parseInt(w(this.handle),10),t=parseInt(this.handle.style.left,10)+e,o=parseInt(this.hot.view.maximumVisibleElementWidth(0),10);p(this.handle,"active"),p(this.guide,"active"),this.guide.style.top=this.handle.style.top,this.guide.style.left=t+"px",this.guide.style.width=o-e+"px",this.hot.rootElement.appendChild(this.guide)},refreshGuidePosition:function(){this.guide.style.top=this.handle.style.top},hideHandleAndGuide:function(){m(this.handle,"active"),m(this.guide,"active")},checkIfRowHeader:function(e){if(e!=this.hot.rootElement){var t=e.parentNode;return"TBODY"===t.tagName||this.checkIfRowHeader(t)}return!1},getTHFromTargetElement:function(e){return"TABLE"!=e.tagName?"TH"==e.tagName?e:this.getTHFromTargetElement(e.parentNode):null},onMouseOver:function(e){if(this.checkIfRowHeader(e.target)){var t=this.getTHFromTargetElement(e.target);t&&(this.pressed||this.setupHandlePosition(t))}},afterMouseDownTimeout:function(){var e=this,t=function(){e.hot.forceFullRender=!0,e.hot.view.render(),e.hot.view.wt.wtOverlays.adjustElementsSize(!0)},o=function(o,n){var r=e.hot.runHooks("beforeRowResize",o,e.newSize,!0);void 0!==r&&(e.newSize=r),e.setManualSize(o,e.newSize),n&&t(),e.hot.runHooks("afterRowResize",o,e.newSize,!0)};if(this.dblclick>=2){this.selectedRows.length>1?(C(this.selectedRows,function(e){o(e)}),t()):C(this.selectedRows,function(e){o(e,!0)})}this.dblclick=0,this.autoresizeTimeout=null},onMouseDown:function(e){var t=this;g(e.target,"manualRowResizer")&&(this.setupGuidePosition(),this.pressed=this.hot,null==this.autoresizeTimeout&&(this.autoresizeTimeout=setTimeout(function(){return t.afterMouseDownTimeout()},500),this.hot._registerTimeout(this.autoresizeTimeout)),this.dblclick++,this.startY=b(e),this.newSize=this.startHeight)},onMouseMove:function(e){var t=this;this.pressed&&(this.currentHeight=this.startHeight+(b(e)-this.startY),C(this.selectedRows,function(e){t.newSize=t.setManualSize(e,t.currentHeight)}),this.refreshHandlePosition(),this.refreshGuidePosition())},onMouseUp:function(e){var t=this,o=function(){t.hot.forceFullRender=!0,t.hot.view.render(),t.hot.view.wt.wtOverlays.adjustElementsSize(!0)},n=function(e,n){t.hot.runHooks("beforeRowResize",e,t.newSize),n&&o(),t.saveManualRowHeights(),t.hot.runHooks("afterRowResize",e,t.newSize)};if(this.pressed){if(this.hideHandleAndGuide(),this.pressed=!1,this.newSize!=this.startHeight){this.selectedRows.length>1?(C(this.selectedRows,function(e){n(e)}),o()):C(this.selectedRows,function(e){n(e,!0)})}this.setupHandlePosition(this.currentTH)}},bindEvents:function(){var e=this;this.eventManager.addEventListener(this.hot.rootElement,"mouseover",function(t){return e.onMouseOver(t)}),this.eventManager.addEventListener(this.hot.rootElement,"mousedown",function(t){return e.onMouseDown(t)}),this.eventManager.addEventListener(window,"mousemove",function(t){return e.onMouseMove(t)}),this.eventManager.addEventListener(window,"mouseup",function(t){return e.onMouseUp(t)})},setManualSize:function(e,t){return e=this.hot.runHooks("modifyRow",e),this.manualRowHeights[e]=t,t},onModifyRowHeight:function(e,t){if(this.enabled){var o=this.hot.getPlugin("autoRowSize"),n=o?o.heights[t]:null;t=this.hot.runHooks("modifyRow",t);var r=this.manualRowHeights[t];if(void 0!==r&&(r===n||r>(e||0)))return r}return e}},{},h),R("manualRowResize",M)},{"_base.js":62,browser:24,eventManager:42,"helpers/array":43,"helpers/dom/element":47,"helpers/dom/event":48,"helpers/number":52,plugins:61}],108:[function(e,t,o){"use strict";function n(){var e=[];return e.getInfo=function(e,t){for(var o=0,n=this.length;o<n;o++)if(this[o].row<=e&&this[o].row+this[o].rowspan-1>=e&&this[o].col<=t&&this[o].col+this[o].colspan-1>=t)return this[o]},e.setInfo=function(e){for(var t=0,o=this.length;t<o;t++)if(this[t].row===e.row&&this[t].col===e.col)return void(this[t]=e);this.push(e)},e.removeInfo=function(e,t){for(var o=0,n=this.length;o<n;o++)if(this[o].row===e&&this[o].col===t){this.splice(o,1);break}},e}function r(e){if(this.mergedCellInfoCollection=new n,Array.isArray(e))for(var t=0,o=e.length;t<o;t++)this.mergedCellInfoCollection.setInfo(e[t])}function i(e,t){if(this.getSettings().mergeCells&&!this.selection.isMultiple()){var o=this.mergeCells.mergedCellInfoCollection.getInfo(e[0],e[1]);o&&(e[0]=o.row,e[1]=o.col,e[2]=o.row+o.rowspan-1,e[3]=o.col+o.colspan-1)}}function s(e,t){this.mergeCells&&this.mergeCells.shiftCollection("right",e,t)}function a(e,t){this.mergeCells&&this.mergeCells.shiftCollection("left",e,t)}function l(e,t){this.mergeCells&&this.mergeCells.shiftCollection("down",e,t)}function u(e,t){this.mergeCells&&this.mergeCells.shiftCollection("up",e,t)}Object.defineProperties(o,{MergeCells:{get:function(){return r}},__esModule:{value:!0}});var c,d,h,f,p,g,m=((c=e("browser"))&&c.__esModule&&c||{default:c}).default,w=(((d=e("plugins"))&&d.__esModule&&d||{default:d}).registerPlugin,((h=e("helpers/dom/event"))&&h.__esModule&&h||{default:h}).stopImmediatePropagation),v=((f=e("3rdparty/walkontable/src/cell/coords"))&&f.__esModule&&f||{default:f}).WalkontableCellCoords,y=((p=e("3rdparty/walkontable/src/cell/range"))&&p.__esModule&&p||{default:p}).WalkontableCellRange,b=((g=e("3rdparty/walkontable/src/table"))&&g.__esModule&&g||{default:g}).WalkontableTable;r.prototype.canMergeRange=function(e){return!e.isSingle()},r.prototype.mergeRange=function(e){if(this.canMergeRange(e)){var t=e.getTopLeftCorner(),o=e.getBottomRightCorner(),n={};n.row=t.row,n.col=t.col,n.rowspan=o.row-t.row+1,n.colspan=o.col-t.col+1,this.mergedCellInfoCollection.setInfo(n)}},r.prototype.mergeOrUnmergeSelection=function(e){this.mergedCellInfoCollection.getInfo(e.from.row,e.from.col)?this.unmergeSelection(e.from):this.mergeSelection(e)},r.prototype.mergeSelection=function(e){this.mergeRange(e)},r.prototype.unmergeSelection=function(e){var t=this.mergedCellInfoCollection.getInfo(e.row,e.col);this.mergedCellInfoCollection.removeInfo(t.row,t.col)},r.prototype.applySpanProperties=function(e,t,o){var n=this.mergedCellInfoCollection.getInfo(t,o);n?n.row===t&&n.col===o?(e.setAttribute("rowspan",n.rowspan),e.setAttribute("colspan",n.colspan)):(e.removeAttribute("rowspan"),e.removeAttribute("colspan"),e.style.display="none"):(e.removeAttribute("rowspan"),e.removeAttribute("colspan"))},r.prototype.modifyTransform=function(e,t,o){var n={row:o.row,col:o.col};if("modifyTransformStart"==e){this.lastDesiredCoords||(this.lastDesiredCoords=new v(null,null));for(var r=new v(t.highlight.row,t.highlight.col),i=this.mergedCellInfoCollection.getInfo(r.row,r.col),s=0,a=this.mergedCellInfoCollection.length;s<a;s++){var l=this.mergedCellInfoCollection[s];if(l=new v(l.row+l.rowspan-1,l.col+l.colspan-1),t.includes(l)){!0;break}}if(i){var u=new v(i.row,i.col),c=new v(i.row+i.rowspan-1,i.col+i.colspan-1);new y(u,u,c).includes(this.lastDesiredCoords)||(this.lastDesiredCoords=new v(null,null)),n.row=this.lastDesiredCoords.row?this.lastDesiredCoords.row-r.row:n.row,n.col=this.lastDesiredCoords.col?this.lastDesiredCoords.col-r.col:n.col,o.row>0?n.row=i.row+i.rowspan-1-r.row+o.row:o.row<0&&(n.row=r.row-i.row+o.row),o.col>0?n.col=i.col+i.colspan-1-r.col+o.col:o.col<0&&(n.col=r.col-i.col+o.col)}var d=new v(t.highlight.row+n.row,t.highlight.col+n.col),h=this.mergedCellInfoCollection.getInfo(d.row,d.col);h&&(this.lastDesiredCoords=d,n={row:h.row-r.row,col:h.col-r.col})}else if("modifyTransformEnd"==e)for(var s=0,a=this.mergedCellInfoCollection.length;s<a;s++){var f=this.mergedCellInfoCollection[s],u=new v(f.row,f.col),c=new v(f.row+f.rowspan-1,f.col+f.colspan-1),p=new y(u,u,c),g=t.getBordersSharedWith(p);if(p.isEqual(t))t.setDirection("NW-SE");else if(g.length>0){var m=t.highlight.isEqual(p.from);g.indexOf("top")>-1?t.to.isSouthEastOf(p.from)&&m?t.setDirection("NW-SE"):t.to.isSouthWestOf(p.from)&&m&&t.setDirection("NE-SW"):g.indexOf("bottom")>-1&&(t.to.isNorthEastOf(p.from)&&m?t.setDirection("SW-NE"):t.to.isNorthWestOf(p.from)&&m&&t.setDirection("SE-NW"))}var d=function(e){return new v(t.to.row+e.row,t.to.col+e.col)}(n),w=function(e,t){return t.row>=e.row&&t.row<=e.row+e.rowspan-1}(f,d),b=function(e,t){return t.col>=e.col&&t.col<=e.col+e.colspan-1}(f,d);t.includesRange(p)&&(p.includes(d)||w||b)&&(w&&(n.row<0?n.row-=f.rowspan-1:n.row>0&&(n.row+=f.rowspan-1)),b&&(n.col<0?n.col-=f.colspan-1:n.col>0&&(n.col+=f.colspan-1)))}0!==n.row&&(o.row=n.row),0!==n.col&&(o.col=n.col)},r.prototype.shiftCollection=function(e,t,o){var n=[0,0];switch(e){case"right":n[0]+=1;break;case"left":n[0]-=1;break;case"down":n[1]+=1;break;case"up":n[1]-=1}for(var r=0;r<this.mergedCellInfoCollection.length;r++){var i=this.mergedCellInfoCollection[r];"right"===e||"left"===e?t<=i.col&&(i.col+=n[0]):t<=i.row&&(i.row+=n[1])}};var C=function(){var e=this,t=e.getSettings().mergeCells;t&&(e.mergeCells||(e.mergeCells=new r(t)))},_=function(){var e=this;e.mergeCells&&(e.view.wt.wtTable.getCell=function(t){if(e.getSettings().mergeCells){var o=e.mergeCells.mergedCellInfoCollection.getInfo(t.row,t.col);o&&(t=o)}return b.prototype.getCell.call(this,t)})},R=function(){var e=this,t=e.getSettings().mergeCells;if(t)if(e.mergeCells){if(e.mergeCells.mergedCellInfoCollection=new n,Array.isArray(t))for(var o=0,i=t.length;o<i;o++)e.mergeCells.mergedCellInfoCollection.setInfo(t[o])}else e.mergeCells=new r(t);else e.mergeCells&&(e.mergeCells.mergedCellInfoCollection=new n)},M=function(e){if(this.mergeCells){(e.ctrlKey||e.metaKey)&&!e.altKey&&77===e.keyCode&&(this.mergeCells.mergeOrUnmergeSelection(this.getSelectedRange()),this.render(),w(e))}},S=function(e){this.getSettings().mergeCells&&(e.items.push(m.plugins.ContextMenu.SEPARATOR),e.items.push({key:"mergeCells",name:function(){var e=this.getSelected();return this.mergeCells.mergedCellInfoCollection.getInfo(e[0],e[1])?"Unmerge cells":"Merge cells"},callback:function(){this.mergeCells.mergeOrUnmergeSelection(this.getSelectedRange()),this.render()},disabled:function(){return this.selection.selectedHeader.corner}}))},E=function(e,t,o,n,r,i){this.mergeCells&&this.mergeCells.applySpanProperties(e,t,o)},O=function(e){return function(t){if(this.getSettings().mergeCells){var o=this.getSelectedRange();if(this.mergeCells.modifyTransform(e,o,t),"modifyTransformEnd"===e){var n=this.countRows(),r=this.countCols();o.from.row<0?o.from.row=0:o.from.row>0&&o.from.row>=n&&(o.from.row=o.from-1),o.from.col<0?o.from.col=0:o.from.col>0&&o.from.col>=r&&(o.from.col=r-1)}}}},T=function(e){if(this.lastDesiredCoords=null,this.getSettings().mergeCells){var t=this.getSelectedRange();t.highlight=new v(t.highlight.row,t.highlight.col),t.to=e;var o=!1;do{o=!1;for(var n=0,r=this.mergeCells.mergedCellInfoCollection.length;n<r;n++){var i=this.mergeCells.mergedCellInfoCollection[n],s=new v(i.row,i.col),a=new v(i.row+i.rowspan-1,i.col+i.colspan-1),l=new y(s,s,a);t.expandByRange(l)&&(e.row=t.to.row,e.col=t.to.col,o=!0)}}while(o)}},k=function(e,t){if(t&&"area"==t){if(this.getSettings().mergeCells)for(var o=this.getSelectedRange(),n=new y(o.from,o.from,o.from),r=new y(o.to,o.to,o.to),i=0,s=this.mergeCells.mergedCellInfoCollection.length;i<s;i++){var a=this.mergeCells.mergedCellInfoCollection[i],l=new v(a.row,a.col),u=new v(a.row+a.rowspan-1,a.col+a.colspan-1),c=new y(l,l,u);n.expandByRange(c)&&(e[0]=n.from.row,e[1]=n.from.col),r.expandByRange(c)&&(e[2]=r.from.row,e[3]=r.from.col)}}},x=function(e,t,o){if(this.getSettings().mergeCells){var n=this.mergeCells.mergedCellInfoCollection.getInfo(e,t);!n||n.row==e&&n.col==t||(o.copyable=!1)}},H=function(e){if(this.getSettings().mergeCells)for(var t,o=this.countCols(),n=0;n<o;n++){if((t=this.mergeCells.mergedCellInfoCollection.getInfo(e.startRow,n))&&t.row<e.startRow)return e.startRow=t.row,H.call(this,e);if(t=this.mergeCells.mergedCellInfoCollection.getInfo(e.endRow,n)){var r=t.row+t.rowspan-1;if(r>e.endRow)return e.endRow=r,H.call(this,e)}}},D=function(e){if(this.getSettings().mergeCells)for(var t,o=this.countRows(),n=0;n<o;n++){if((t=this.mergeCells.mergedCellInfoCollection.getInfo(n,e.startColumn))&&t.col<e.startColumn)return e.startColumn=t.col,D.call(this,e);if(t=this.mergeCells.mergedCellInfoCollection.getInfo(n,e.endColumn)){var r=t.col+t.colspan-1;if(r>e.endColumn)return e.endColumn=r,D.call(this,e)}}},A=function(e){if(e&&this.mergeCells){var t=this.mergeCells.mergedCellInfoCollection,o=this.getSelectedRange();for(var n in t)if(o.highlight.row==t[n].row&&o.highlight.col==t[n].col&&o.to.row==t[n].row+t[n].rowspan-1&&o.to.col==t[n].col+t[n].colspan-1)return!1}return e};m.hooks.add("beforeInit",C),m.hooks.add("afterInit",_),m.hooks.add("afterUpdateSettings",R),m.hooks.add("beforeKeyDown",M),m.hooks.add("modifyTransformStart",O("modifyTransformStart")),m.hooks.add("modifyTransformEnd",O("modifyTransformEnd")),m.hooks.add("beforeSetRangeEnd",T),m.hooks.add("beforeDrawBorders",k),m.hooks.add("afterIsMultipleSelection",A),m.hooks.add("afterRenderer",E),m.hooks.add("afterContextMenuDefaultOptions",S),m.hooks.add("afterGetCellMeta",x),m.hooks.add("afterViewportRowCalculatorOverride",H),m.hooks.add("afterViewportColumnCalculatorOverride",D),m.hooks.add("modifyAutofillRange",i),m.hooks.add("afterCreateCol",s),m.hooks.add("afterRemoveCol",a),m.hooks.add("afterCreateRow",l),m.hooks.add("afterRemoveRow",u),m.MergeCells=r},{"3rdparty/walkontable/src/cell/coords":6,"3rdparty/walkontable/src/cell/range":7,"3rdparty/walkontable/src/table":21,browser:24,"helpers/dom/event":48,plugins:61}],109:[function(e,t,o){"use strict";Object.defineProperties(o,{MultipleSelectionHandles:{get:function(){return w}},__esModule:{value:!0}});var n,r,i,s,a,l,u=(((n=e("browser"))&&n.__esModule&&n||{default:n}).default,(r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r}),c=u.getWindowScrollTop,d=u.hasClass,h=u.getWindowScrollLeft,f=((i=e("helpers/browser"))&&i.__esModule&&i||{default:i}).isMobileBrowser,p=((s=e("_base"))&&s.__esModule&&s||{default:s}).default,g=((a=e("eventManager"))&&a.__esModule&&a||{default:a}).EventManager,m=((l=e("plugins"))&&l.__esModule&&l||{default:l}).registerPlugin,w=function(e){$traceurRuntime.superConstructor(v).call(this,e),this.dragged=[],this.eventManager=null,this.lastSetCell=null},v=w;$traceurRuntime.createClass(w,{isEnabled:function(){return f()},enablePlugin:function(){this.enabled||(this.eventManager||(this.eventManager=new g(this)),this.registerListeners(),$traceurRuntime.superGet(this,v.prototype,"enablePlugin").call(this))},registerListeners:function(){function e(e){if(1===t.dragged.length)return t.dragged.splice(0,t.dragged.length),!0;var o=t.dragged.indexOf(e);if(o==-1)return!1;0===o?t.dragged=t.dragged.slice(0,1):1==o&&(t.dragged=t.dragged.slice(-1))}var t=this;this.eventManager.addEventListener(this.hot.rootElement,"touchstart",function(e){var o;return d(e.target,"topLeftSelectionHandle-HitArea")?(o=t.hot.getSelectedRange(),t.dragged.push("topLeft"),t.touchStartRange={width:o.getWidth(),height:o.getHeight(),direction:o.getDirection()},e.preventDefault(),!1):d(e.target,"bottomRightSelectionHandle-HitArea")?(o=t.hot.getSelectedRange(),t.dragged.push("bottomRight"),t.touchStartRange={width:o.getWidth(),height:o.getHeight(),direction:o.getDirection()},e.preventDefault(),!1):void 0}),this.eventManager.addEventListener(this.hot.rootElement,"touchend",function(o){return d(o.target,"topLeftSelectionHandle-HitArea")?(e.call(t,"topLeft"),t.touchStartRange=void 0,o.preventDefault(),!1):d(o.target,"bottomRightSelectionHandle-HitArea")?(e.call(t,"bottomRight"),t.touchStartRange=void 0,o.preventDefault(),!1):void 0}),this.eventManager.addEventListener(this.hot.rootElement,"touchmove",function(e){var o,n,r,i,s,a,l,u=c(),d=h();0!==t.dragged.length&&(o=document.elementFromPoint(e.touches[0].screenX-d,e.touches[0].screenY-u))&&o!==t.lastSetCell&&("TD"!=o.nodeName&&"TH"!=o.nodeName||(n=t.hot.getCoords(o),n.col==-1&&(n.col=0),r=t.hot.getSelectedRange(),i=r.getWidth(),s=r.getHeight(),a=r.getDirection(),1==i&&1==s&&t.hot.selection.setRangeEnd(n),l=t.getCurrentRangeCoords(r,n,t.touchStartRange.direction,a,t.dragged[0]),null!==l.start&&t.hot.selection.setRangeStart(l.start),t.hot.selection.setRangeEnd(l.end),t.lastSetCell=o),e.preventDefault())})},getCurrentRangeCoords:function(e,t,o,n,r){var i=e.getTopLeftCorner(),s=e.getBottomRightCorner(),a=e.getBottomLeftCorner(),l=e.getTopRightCorner(),u={start:null,end:null};switch(o){case"NE-SW":switch(n){case"NE-SW":case"NW-SE":u="topLeft"==r?{start:new WalkontableCellCoords(t.row,e.highlight.col),end:new WalkontableCellCoords(a.row,t.col)}:{start:new WalkontableCellCoords(e.highlight.row,t.col),end:new WalkontableCellCoords(t.row,i.col)};break;case"SE-NW":"bottomRight"==r&&(u={start:new WalkontableCellCoords(s.row,t.col),end:new WalkontableCellCoords(t.row,i.col)})}break;case"NW-SE":switch(n){case"NE-SW":"topLeft"==r?u={start:t,end:a}:u.end=t;break;case"NW-SE":"topLeft"==r?u={start:t,end:s}:u.end=t;break;case"SE-NW":"topLeft"==r?u={start:t,end:i}:u.end=t;break;case"SW-NE":"topLeft"==r?u={start:t,end:l}:u.end=t}break;case"SW-NE":switch(n){case"NW-SE":u="bottomRight"==r?{start:new WalkontableCellCoords(t.row,i.col),end:new WalkontableCellCoords(a.row,t.col)}:{start:new WalkontableCellCoords(i.row,t.col),end:new WalkontableCellCoords(t.row,s.col)};break;case"SW-NE":u="topLeft"==r?{start:new WalkontableCellCoords(e.highlight.row,t.col),end:new WalkontableCellCoords(t.row,s.col)}:{start:new WalkontableCellCoords(t.row,i.col),end:new WalkontableCellCoords(i.row,t.col)};break;case"SE-NW":"bottomRight"==r?u={start:new WalkontableCellCoords(t.row,l.col),end:new WalkontableCellCoords(i.row,t.col)}:"topLeft"==r&&(u={start:a,end:t})}break;case"SE-NW":switch(n){case"NW-SE":case"NE-SW":case"SW-NE":"topLeft"==r&&(u.end=t);break;case"SE-NW":"topLeft"==r?u.end=t:u={start:t,end:i}}}return u},isDragged:function(){return this.dragged.length>0}},{},p),m("multipleSelectionHandles",w)},{_base:62,browser:24,eventManager:42,"helpers/browser":44,"helpers/dom/element":47,plugins:61}],110:[function(e,t,o){"use strict";Object.defineProperties(o,{DataObserver:{get:function(){return d}},__esModule:{value:!0}});var n,r,i,s,a=((n=e("jsonpatch"))&&n.__esModule&&n||{default:n}).default,l=((r=e("../../mixins/localHooks"))&&r.__esModule&&r||{default:r}).localHooks,u=((i=e("../../helpers/object"))&&i.__esModule&&i||{default:i}).mixin,c=((s=e("utils"))&&s.__esModule&&s||{default:s}).cleanPatches,d=function(e){this.observedData=null,this.observer=null,this.paused=!1,this.setObservedData(e)};$traceurRuntime.createClass(d,{setObservedData:function(e){var t=this;this.observer&&a.unobserve(this.observedData,this.observer),this.observedData=e,this.observer=a.observe(this.observedData,function(e){return t.onChange(e)})},isPaused:function(){return this.paused},pause:function(){this.paused=!0},resume:function(){this.paused=!1},onChange:function(e){this.runLocalHooks("change",c(e))},destroy:function(){a.unobserve(this.observedData,this.observer),this.observedData=null,this.observer=null}},{}),u(d,l)},{"../../helpers/object":53,"../../mixins/localHooks":58,jsonpatch:"jsonpatch",utils:112}],111:[function(e,t,o){"use strict";Object.defineProperties(o,{ObserveChanges:{get:function(){return p}},__esModule:{value:!0}});var n,r,i,s,a,l,u=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,c=((r=e("_base"))&&r.__esModule&&r||{default:r}).default,d=(((i=e("jsonpatch"))&&i.__esModule&&i||{default:i}).default,((s=e("dataObserver"))&&s.__esModule&&s||{default:s}).DataObserver),h=((a=e("helpers/array"))&&a.__esModule&&a||{default:a}).arrayEach,f=((l=e("plugins"))&&l.__esModule&&l||{default:l}).registerPlugin;u.hooks.register("afterChangesObserved");var p=function(e){$traceurRuntime.superConstructor(g).call(this,e),this.observer=null},g=p;$traceurRuntime.createClass(p,{isEnabled:function(){return this.hot.getSettings().observeChanges},enablePlugin:function(){var e=this;this.enabled||(this.observer||(this.observer=new d(this.hot.getSourceData()),this._exposePublicApi()),this.observer.addLocalHook("change",function(t){return e.onDataChange(t)}),this.addHook("afterCreateRow",function(){return e.onAfterTableAlter()}),this.addHook("afterRemoveRow",function(){return e.onAfterTableAlter()}),this.addHook("afterCreateCol",function(){return e.onAfterTableAlter()}),this.addHook("afterRemoveCol",function(){return e.onAfterTableAlter()}),this.addHook("afterChange",function(t,o){return e.onAfterTableAlter(o)}),this.addHook("afterLoadData",function(t){return e.onAfterLoadData(t)}),$traceurRuntime.superGet(this,g.prototype,"enablePlugin").call(this))},disablePlugin:function(){this.observer&&(this.observer.destroy(),this.observer=null,this._deletePublicApi()),$traceurRuntime.superGet(this,g.prototype,"disablePlugin").call(this)},onDataChange:function(e){var t=this;if(!this.observer.isPaused()){var o=this.pluginName+".change",n={add:function(e){isNaN(e.col)?t.hot.runHooks("afterCreateRow",e.row,1,o):t.hot.runHooks("afterCreateCol",e.col,1,o)},remove:function(e){isNaN(e.col)?t.hot.runHooks("afterRemoveRow",e.row,1,o):t.hot.runHooks("afterRemoveCol",e.col,1,o)},replace:function(e){t.hot.runHooks("afterChange",[e.row,e.col,null,e.value],o)}};h(e,function(e){n[e.op]&&n[e.op](e)}),this.hot.render()}this.hot.runHooks("afterChangesObserved")},onAfterTableAlter:function(e){var t=this;"loadData"!==e&&(this.observer.pause(),this.hot.addHookOnce("afterChangesObserved",function(){return t.observer.resume()}))},onAfterLoadData:function(e){e||this.observer.setObservedData(this.hot.getSourceData())},destroy:function(){this.observer&&(this.observer.destroy(),this._deletePublicApi()),$traceurRuntime.superGet(this,g.prototype,"destroy").call(this)},_exposePublicApi:function(){var e=this,t=this.hot;t.pauseObservingChanges=function(){return e.observer.pause()},t.resumeObservingChanges=function(){return e.observer.resume()},t.isPausedObservingChanges=function(){return e.observer.isPaused()}},_deletePublicApi:function(){var e=this.hot;delete e.pauseObservingChanges,delete e.resumeObservingChanges,delete e.isPausedObservingChanges}},{},c),f("observeChanges",p)},{_base:62,browser:24,dataObserver:110,"helpers/array":43,jsonpatch:"jsonpatch",plugins:61}],112:[function(e,t,o){"use strict";function n(e){var t=[];return e=a(e,function(e){return!/[\/]length/gi.test(e.path)&&!!r(e.path)}),e=l(e,function(e){var t=r(e.path);return e.row=t.row,e.col=t.col,e}),e=a(e,function(e){if(["add","remove"].indexOf(e.op)!==-1&&!isNaN(e.col)){if(t.indexOf(e.col)!==-1)return!1;t.push(e.col)}return!0}),t.length=0,e}function r(e){var t=e.match(/^\/(\d+)\/?(.*)?$/);if(!t)return null;var o=t,n=o[1],r=o[2];return{row:parseInt(n,10),col:/^\d*$/.test(r)?parseInt(r,10):r}}Object.defineProperties(o,{cleanPatches:{get:function(){return n}},parsePath:{get:function(){return r}},__esModule:{value:!0}});var i,s=(i=e("../../helpers/array"))&&i.__esModule&&i||{default:i},a=s.arrayFilter,l=s.arrayMap},{"../../helpers/array":43}],113:[function(e,t,o){"use strict";function n(e){var t,o=function(){window.localStorage[e+"__persistentStateKeys"]=JSON.stringify(t)},n=function(){t=[],o()};!function(){var o=window.localStorage[e+"__persistentStateKeys"],n="string"==typeof o?JSON.parse(o):void 0;t=n?n:[]}(),this.saveValue=function(n,r){window.localStorage[e+"_"+n]=JSON.stringify(r),t.indexOf(n)==-1&&(t.push(n),o())},this.loadValue=function(t,o){t=void 0===t?o:t;var n=window.localStorage[e+"_"+t];return void 0===n?void 0:JSON.parse(n)},this.reset=function(t){window.localStorage.removeItem(e+"_"+t)},this.resetAll=function(){for(var o=0;o<t.length;o++)window.localStorage.removeItem(e+"_"+t[o]);n()}}function r(){function e(){var e=this;for(var t in r)r.hasOwnProperty(t)&&e.addHook(t,r[t])}function t(){var e=this;for(var t in r)r.hasOwnProperty(t)&&e.removeHook(t,r[t])}var o=this;this.init=function(){var r=this,i=r.getSettings().persistentState;if(o.enabled=!!i,!o.enabled)return void t.call(r);r.storage||(r.storage=new n(r.rootElement.id)),r.resetState=o.resetValue,e.call(r)},this.saveValue=function(e,t){this.storage.saveValue(e,t)},this.loadValue=function(e,t){var o=this;t.value=o.storage.loadValue(e)},this.resetValue=function(e){var t=this;void 0===e?t.storage.resetAll():t.storage.reset(e)};var r={persistentStateSave:o.saveValue,persistentStateLoad:o.loadValue,persistentStateReset:o.resetValue};for(var i in r)r.hasOwnProperty(i)&&a.hooks.register(i)}Object.defineProperties(o,{HandsontablePersistentState:{get:function(){return r}},__esModule:{value:!0}});var i,s,a=((i=e("browser"))&&i.__esModule&&i||{default:i}).default,l=(((s=e("plugins"))&&s.__esModule&&s||{default:s}).registerPlugin,new r);a.hooks.add("beforeInit",l.init),a.hooks.add("afterUpdateSettings",l.init)},{browser:24,plugins:61}],114:[function(e,t,o){"use strict";function n(){var e=this;!e.getSettings().search?delete e.search:e.search=new a.Search(e)}var r,i,s,a=((r=e("browser"))&&r.__esModule&&r||{default:r}).default,l=(i=e("helpers/dom/element"))&&i.__esModule&&i||{default:i},u=l.addClass,c=l.removeClass,d=(s=e("renderers"))&&s.__esModule&&s||{default:s},h=d.registerRenderer,f=d.getRenderer;a.Search=function(e){this.query=function(t,o,n){var r=e.countRows(),i=e.countCols(),s=[];o||(o=a.Search.global.getDefaultCallback()),n||(n=a.Search.global.getDefaultQueryMethod());for(var l=0;l<r;l++)for(var u=0;u<i;u++){var c=e.getDataAtCell(l,u),d=e.getCellMeta(l,u),h=d.search.callback||o,f=d.search.queryMethod||n,p=f(t,c);if(p){var g={row:l,col:u,data:c};s.push(g)}h&&h(e,l,u,c,p)}return s}},a.Search.DEFAULT_CALLBACK=function(e,t,o,n,r){e.getCellMeta(t,o).isSearchResult=r},a.Search.DEFAULT_QUERY_METHOD=function(e,t){return!(void 0===e||null==e||!e.toLowerCase||0===e.length)&&(void 0!==t&&null!=t&&t.toString().toLowerCase().indexOf(e.toLowerCase())!=-1)},a.Search.DEFAULT_SEARCH_RESULT_CLASS="htSearchResult",a.Search.global=function(){var e=a.Search.DEFAULT_CALLBACK,t=a.Search.DEFAULT_QUERY_METHOD,o=a.Search.DEFAULT_SEARCH_RESULT_CLASS;return{getDefaultCallback:function(){return e},setDefaultCallback:function(t){e=t},getDefaultQueryMethod:function(){return t},setDefaultQueryMethod:function(e){t=e},getDefaultSearchResultClass:function(){return o},setDefaultSearchResultClass:function(e){o=e}}}(),a.SearchCellDecorator=function(e,t,o,n,r,i,s){var l=null!==s.search&&"object"==typeof s.search&&s.search.searchResultClass||a.Search.global.getDefaultSearchResultClass();s.isSearchResult?u(t,l):c(t,l)};var p=f("base");h("base",function(e,t,o,n,r,i,s){p.apply(this,arguments),a.SearchCellDecorator.apply(this,arguments)}),a.hooks.add("afterInit",n),a.hooks.add("afterUpdateSettings",n)},{browser:24,"helpers/dom/element":47,renderers:117}],115:[function(e,t,o){"use strict";Object.defineProperties(o,{TouchScroll:{get:function(){return w}},__esModule:{value:!0}});var n,r,i,s,a,l,u=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,c=(r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r},d=c.addClass,h=c.removeClass,f=((i=e("helpers/array"))&&i.__esModule&&i||{default:i}).arrayEach,p=((s=e("_base"))&&s.__esModule&&s||{default:s}).default,g=((a=e("plugins"))&&a.__esModule&&a||{default:a}).registerPlugin,m=((l=e("helpers/feature"))&&l.__esModule&&l||{default:l}).isTouchSupported,w=function(e){$traceurRuntime.superConstructor(v).call(this,e),this.scrollbars=[],this.clones=[],this.lockedCollection=!1},v=w;$traceurRuntime.createClass(w,{isEnabled:function(){return m()},enablePlugin:function(){var e=this;this.enabled||(this.addHook("afterRender",function(){return e.onAfterRender()}),this.registerEvents(),$traceurRuntime.superGet(this,v.prototype,"enablePlugin").call(this))},updatePlugin:function(){this.lockedCollection=!1,$traceurRuntime.superGet(this,v.prototype,"updatePlugin").call(this)},disablePlugin:function(){$traceurRuntime.superGet(this,v.prototype,"disablePlugin").call(this)},registerEvents:function(){var e=this;this.addHook("beforeTouchScroll",function(){return e.onBeforeTouchScroll()}),this.addHook("afterMomentumScroll",function(){return e.onAfterMomentumScroll()})},onAfterRender:function(){if(!this.lockedCollection){var e=this.hot.view.wt.wtOverlays,t=e.topOverlay,o=e.bottomOverlay,n=e.leftOverlay,r=e.topLeftCornerOverlay,i=e.bottomLeftCornerOverlay;this.lockedCollection=!0,this.scrollbars.length=0,this.scrollbars.push(t),o.clone&&this.scrollbars.push(o),this.scrollbars.push(n),r&&this.scrollbars.push(r),i&&i.clone&&this.scrollbars.push(i),this.clones.length=0,t.needFullRender&&this.clones.push(t.clone.wtTable.holder.parentNode),o.needFullRender&&this.clones.push(o.clone.wtTable.holder.parentNode),n.needFullRender&&this.clones.push(n.clone.wtTable.holder.parentNode),r&&this.clones.push(r.clone.wtTable.holder.parentNode),i&&i.clone&&this.clones.push(i.clone.wtTable.holder.parentNode)}},onBeforeTouchScroll:function(){u.freezeOverlays=!0,f(this.clones,function(e){d(e,"hide-tween")})},onAfterMomentumScroll:function(){var e=this;u.freezeOverlays=!1,f(this.clones,function(e){h(e,"hide-tween"),d(e,"show-tween")}),setTimeout(function(){f(e.clones,function(e){h(e,"show-tween")})},400),f(this.scrollbars,function(e){e.refresh(),e.resetFixedPosition()}),this.hot.view.wt.wtOverlays.syncScrollWithMaster()}},{},p),g("touchScroll",w)},{_base:62,browser:24,"helpers/array":43,"helpers/dom/element":47,"helpers/feature":49,plugins:61}],116:[function(e,t,o){"use strict";function n(){var e=this;void 0===e.getSettings().undo||e.getSettings().undo?e.undoRedo||(e.undoRedo=new f.UndoRedo(e),s(e),e.addHook("beforeKeyDown",r),e.addHook("afterChange",i)):e.undoRedo&&(delete e.undoRedo,a(e),e.removeHook("beforeKeyDown",r),e.removeHook("afterChange",i))}function r(e){var t=this;(e.ctrlKey||e.metaKey)&&!e.altKey&&(89===e.keyCode||e.shiftKey&&90===e.keyCode?(t.undoRedo.redo(),y(e)):90===e.keyCode&&(t.undoRedo.undo(),y(e)))}function i(e,t){var o=this;if("loadData"===t)return o.undoRedo.clear()}function s(e){e.undo=function(){return e.undoRedo.undo()},e.redo=function(){return e.undoRedo.redo()},e.isUndoAvailable=function(){return e.undoRedo.isUndoAvailable()},e.isRedoAvailable=function(){return e.undoRedo.isRedoAvailable()},e.clearUndo=function(){return e.undoRedo.clear()}}function a(e){delete e.undo,delete e.redo,delete e.isUndoAvailable,delete e.isRedoAvailable,delete e.clearUndo}var l,u,c,d,h,f=((l=e("browser"))&&l.__esModule&&l||{default:l}).default,p=((u=e("helpers/array"))&&u.__esModule&&u||{default:u}).arrayMap,g=((c=e("helpers/number"))&&c.__esModule&&c||{default:c}).rangeEach,m=(d=e("helpers/object"))&&d.__esModule&&d||{default:d},w=m.inherit,v=m.deepClone,y=((h=e("helpers/dom/event"))&&h.__esModule&&h||{default:h}).stopImmediatePropagation;f.UndoRedo=function(e){var t=this;this.instance=e,this.doneActions=[],this.undoneActions=[],this.ignoreNewActions=!1,e.addHook("afterChange",function(e,o){e&&"UndoRedo.undo"!==o&&"UndoRedo.redo"!==o&&t.done(new f.UndoRedo.ChangeAction(e))}),e.addHook("afterCreateRow",function(e,o,n){if("UndoRedo.undo"!==n&&"UndoRedo.undo"!==n&&"auto"!==n){var r=new f.UndoRedo.CreateRowAction(e,o);t.done(r)}}),e.addHook("beforeRemoveRow",function(e,o,n,r){if("UndoRedo.undo"!==r&&"UndoRedo.redo"!==r&&"auto"!==r){var i=t.instance.getSourceDataArray();e=(i.length+e)%i.length;var s=v(i.slice(e,e+o));t.done(new f.UndoRedo.RemoveRowAction(e,s))}}),e.addHook("afterCreateCol",function(e,o,n){"UndoRedo.undo"!==n&&"UndoRedo.redo"!==n&&"auto"!==n&&t.done(new f.UndoRedo.CreateColumnAction(e,o))}),e.addHook("beforeRemoveCol",function(o,n,r,i){if("UndoRedo.undo"!==i&&"UndoRedo.redo"!==i&&"auto"!==i){var s=t.instance.getSourceDataArray();o=(t.instance.countCols()+o)%t.instance.countCols();var a=[],l=[],u=[];g(s.length-1,function(t){var r=[],i=s[t];g(o,o+(n-1),function(t){r.push(i[e.runHooks("modifyCol",t)])}),a.push(r)}),g(n-1,function(t){u.push(e.runHooks("modifyCol",o+t))}),Array.isArray(e.getSettings().colHeaders)&&g(n-1,function(t){l.push(e.getSettings().colHeaders[e.runHooks("modifyCol",o+t)]||null)});var c=t.instance.getPlugin("manualColumnMove"),d=c.isEnabled()?c.columnsMapper.__arrayMap:[],h=new f.UndoRedo.RemoveColumnAction(o,u,a,l,d);t.done(h)}
40
- }),e.addHook("beforeCellAlignment",function(e,o,n,r){var i=new f.UndoRedo.CellAlignmentAction(e,o,n,r);t.done(i)}),e.addHook("beforeFilter",function(e){t.done(new f.UndoRedo.FiltersAction(e))}),e.addHook("beforeRowMove",function(e,o){e!==!1&&t.done(new f.UndoRedo.RowMoveAction(e,o))})},f.UndoRedo.prototype.done=function(e){this.ignoreNewActions||(this.doneActions.push(e),this.undoneActions.length=0)},f.UndoRedo.prototype.undo=function(){if(this.isUndoAvailable()){var e=this.doneActions.pop(),t=v(e),o=this.instance;if(o.runHooks("beforeUndo",t)===!1)return;this.ignoreNewActions=!0;var n=this;e.undo(this.instance,function(){n.ignoreNewActions=!1,n.undoneActions.push(e)}),o.runHooks("afterUndo",t)}},f.UndoRedo.prototype.redo=function(){if(this.isRedoAvailable()){var e=this.undoneActions.pop(),t=v(e),o=this.instance;if(o.runHooks("beforeRedo",t)===!1)return;this.ignoreNewActions=!0;var n=this;e.redo(this.instance,function(){n.ignoreNewActions=!1,n.doneActions.push(e)}),o.runHooks("afterRedo",t)}},f.UndoRedo.prototype.isUndoAvailable=function(){return this.doneActions.length>0},f.UndoRedo.prototype.isRedoAvailable=function(){return this.undoneActions.length>0},f.UndoRedo.prototype.clear=function(){this.doneActions.length=0,this.undoneActions.length=0},f.UndoRedo.Action=function(){},f.UndoRedo.Action.prototype.undo=function(){},f.UndoRedo.Action.prototype.redo=function(){},f.UndoRedo.ChangeAction=function(e){this.changes=e,this.actionType="change"},w(f.UndoRedo.ChangeAction,f.UndoRedo.Action),f.UndoRedo.ChangeAction.prototype.undo=function(e,t){for(var o=v(this.changes),n=e.countEmptyRows(!0),r=e.countEmptyCols(!0),i=0,s=o.length;i<s;i++)o[i].splice(3,1);e.addHookOnce("afterChange",t),e.setDataAtRowProp(o,null,null,"UndoRedo.undo");for(var a=0,l=o.length;a<l;a++)e.getSettings().minSpareRows&&o[a][0]+1+e.getSettings().minSpareRows===e.countRows()&&n==e.getSettings().minSpareRows&&(e.alter("remove_row",parseInt(o[a][0]+1,10),e.getSettings().minSpareRows),e.undoRedo.doneActions.pop()),e.getSettings().minSpareCols&&o[a][1]+1+e.getSettings().minSpareCols===e.countCols()&&r==e.getSettings().minSpareCols&&(e.alter("remove_col",parseInt(o[a][1]+1,10),e.getSettings().minSpareCols),e.undoRedo.doneActions.pop())},f.UndoRedo.ChangeAction.prototype.redo=function(e,t){for(var o=v(this.changes),n=0,r=o.length;n<r;n++)o[n].splice(2,1);e.addHookOnce("afterChange",t),e.setDataAtRowProp(o,null,null,"UndoRedo.redo")},f.UndoRedo.CreateRowAction=function(e,t){this.index=e,this.amount=t,this.actionType="insert_row"},w(f.UndoRedo.CreateRowAction,f.UndoRedo.Action),f.UndoRedo.CreateRowAction.prototype.undo=function(e,t){var o=e.countRows(),n=e.getSettings().minSpareRows;this.index>=o&&this.index-n<o&&(this.index-=n),e.addHookOnce("afterRemoveRow",t),e.alter("remove_row",this.index,this.amount,"UndoRedo.undo")},f.UndoRedo.CreateRowAction.prototype.redo=function(e,t){e.addHookOnce("afterCreateRow",t),e.alter("insert_row",this.index,this.amount,"UndoRedo.redo")},f.UndoRedo.RemoveRowAction=function(e,t){this.index=e,this.data=t,this.actionType="remove_row"},w(f.UndoRedo.RemoveRowAction,f.UndoRedo.Action),f.UndoRedo.RemoveRowAction.prototype.undo=function(e,t){e.alter("insert_row",this.index,this.data.length,"UndoRedo.undo"),e.addHookOnce("afterRender",t),e.populateFromArray(this.index,0,this.data,void 0,void 0,"UndoRedo.undo")},f.UndoRedo.RemoveRowAction.prototype.redo=function(e,t){e.addHookOnce("afterRemoveRow",t),e.alter("remove_row",this.index,this.data.length,"UndoRedo.redo")},f.UndoRedo.CreateColumnAction=function(e,t){this.index=e,this.amount=t,this.actionType="insert_col"},w(f.UndoRedo.CreateColumnAction,f.UndoRedo.Action),f.UndoRedo.CreateColumnAction.prototype.undo=function(e,t){e.addHookOnce("afterRemoveCol",t),e.alter("remove_col",this.index,this.amount,"UndoRedo.undo")},f.UndoRedo.CreateColumnAction.prototype.redo=function(e,t){e.addHookOnce("afterCreateCol",t),e.alter("insert_col",this.index,this.amount,"UndoRedo.redo")},f.UndoRedo.RemoveColumnAction=function(e,t,o,n,r){this.index=e,this.indexes=t,this.data=o,this.amount=this.data[0].length,this.headers=n,this.columnPositions=r.slice(0),this.actionType="remove_col"},w(f.UndoRedo.RemoveColumnAction,f.UndoRedo.Action),f.UndoRedo.RemoveColumnAction.prototype.undo=function(e,t){var o,n=this,r=this.indexes.slice(0).sort(),i=function(e,t,o){return o[n.indexes.indexOf(r[t])]},s=[];g(this.data.length-1,function(e){s[e]=p(n.data[e],i)});var a=[];a=p(this.headers,i);var l=[];f.hooks.run(e,"beforeCreateCol",this.indexes[0],this.indexes[this.indexes.length-1],"UndoRedo.undo"),g(this.data.length-1,function(t){o=e.getSourceDataAtRow(t),g(r.length-1,function(e){o.splice(r[e],0,s[t][e]),l.push([t,r[e],null,s[t][e]])})}),e.getPlugin("formulas")&&e.getPlugin("formulas").onAfterSetDataAtCell(l),void 0!==this.headers&&g(a.length-1,function(t){e.getSettings().colHeaders.splice(r[t],0,a[t])}),e.getPlugin("manualColumnMove")&&(e.getPlugin("manualColumnMove").columnsMapper.__arrayMap=this.columnPositions),e.addHookOnce("afterRender",t),f.hooks.run(e,"afterCreateCol",this.indexes[0],this.indexes[this.indexes.length-1],"UndoRedo.undo"),e.getPlugin("formulas")&&e.getPlugin("formulas").recalculateFull(),e.render()},f.UndoRedo.RemoveColumnAction.prototype.redo=function(e,t){e.addHookOnce("afterRemoveCol",t),e.alter("remove_col",this.index,this.amount,"UndoRedo.redo")},f.UndoRedo.CellAlignmentAction=function(e,t,o,n){this.stateBefore=e,this.range=t,this.type=o,this.alignment=n},f.UndoRedo.CellAlignmentAction.prototype.undo=function(e,t){if(e.getPlugin("contextMenu").isEnabled()){for(var o=this.range.from.row;o<=this.range.to.row;o++)for(var n=this.range.from.col;n<=this.range.to.col;n++)e.setCellMeta(o,n,"className",this.stateBefore[o][n]||" htLeft");e.addHookOnce("afterRender",t),e.render()}},f.UndoRedo.CellAlignmentAction.prototype.redo=function(e,t){e.getPlugin("contextMenu").isEnabled()&&(e.selectCell(this.range.from.row,this.range.from.col,this.range.to.row,this.range.to.col),e.getPlugin("contextMenu").executeCommand("alignment:"+this.alignment.replace("ht","").toLowerCase()),e.addHookOnce("afterRender",t),e.render())},f.UndoRedo.FiltersAction=function(e){this.formulaStacks=e,this.actionType="filter"},w(f.UndoRedo.FiltersAction,f.UndoRedo.Action),f.UndoRedo.FiltersAction.prototype.undo=function(e,t){var o=e.getPlugin("filters");e.addHookOnce("afterRender",t),o.formulaCollection.importAllFormulas(this.formulaStacks.slice(0,this.formulaStacks.length-1)),o.filter()},f.UndoRedo.FiltersAction.prototype.redo=function(e,t){var o=e.getPlugin("filters");e.addHookOnce("afterRender",t),o.formulaCollection.importAllFormulas(this.formulaStacks),o.filter()},f.UndoRedo.RowMoveAction=function(e,t){this.rows=e.slice(),this.target=t},w(f.UndoRedo.RowMoveAction,f.UndoRedo.Action),f.UndoRedo.RowMoveAction.prototype.undo=function(e,t){var o=e.getPlugin("manualRowMove");e.addHookOnce("afterRender",t);for(var n=this.rows[0]<this.target?-1*this.rows.length:0,r=this.rows[0]>this.target?this.rows[0]+this.rows.length:this.rows[0],i=[],s=this.rows.length+n,a=n;a<s;a++)i.push(this.target+a);o.moveRows(i.slice(),r),e.render(),e.selection.setRangeStartOnly(new WalkontableCellCoords(this.rows[0],0)),e.selection.setRangeEnd(new WalkontableCellCoords(this.rows[this.rows.length-1],e.countCols()-1))},f.UndoRedo.RowMoveAction.prototype.redo=function(e,t){var o=e.getPlugin("manualRowMove");e.addHookOnce("afterRender",t),o.moveRows(this.rows.slice(),this.target),e.render();var n=this.rows[0]<this.target?this.target-this.rows.length:this.target;e.selection.setRangeStartOnly(new WalkontableCellCoords(n,0)),e.selection.setRangeEnd(new WalkontableCellCoords(n+this.rows.length-1,e.countCols()-1))},f.hooks.add("afterInit",n),f.hooks.add("afterUpdateSettings",n),f.hooks.register("beforeUndo"),f.hooks.register("afterUndo"),f.hooks.register("beforeRedo"),f.hooks.register("afterRedo")},{browser:24,"helpers/array":43,"helpers/dom/event":48,"helpers/number":52,"helpers/object":53}],117:[function(e,t,o){"use strict";function n(e,t){var o;c[e]=t,o=u(e)+"Renderer",l.renderers[o]=t,l[o]=t,"base"===e&&(l.renderers.cellDecorator=t)}function r(e){if("function"==typeof e)return e;if("string"!=typeof e)throw Error('Only strings and functions can be passed as "renderer" parameter');if(!(e in c))throw Error('No editor registered under name "'+e+'"');return c[e]}function i(e){return e in c}Object.defineProperties(o,{registerRenderer:{get:function(){return n}},getRenderer:{get:function(){return r}},hasRenderer:{get:function(){return i}},__esModule:{value:!0}});var s,a,l=((s=e("browser"))&&s.__esModule&&s||{default:s}).default,u=((a=e("helpers/string"))&&a.__esModule&&a||{default:a}).toUpperCaseFirst,c={};l.renderers=l.renderers||{},l.renderers.registerRenderer=n,l.renderers.getRenderer=r},{browser:24,"helpers/string":55}],118:[function(e,t,o){"use strict";function n(e,t,o,n,r,i,s){s.className&&(t.className?t.className=t.className+" "+s.className:t.className=s.className),s.readOnly&&a(t,s.readOnlyCellClassName),s.valid===!1&&s.invalidCellClassName?a(t,s.invalidCellClassName):l(t,s.invalidCellClassName),s.wordWrap===!1&&s.noWordWrapClassName&&a(t,s.noWordWrapClassName),!i&&s.placeholder&&a(t,s.placeholderCellClassName)}Object.defineProperties(o,{cellDecorator:{get:function(){return n}},__esModule:{value:!0}});var r,i,s=(r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r},a=s.addClass,l=s.removeClass;(0,((i=e("renderers"))&&i.__esModule&&i||{default:i}).registerRenderer)("base",n)},{"helpers/dom/element":47,renderers:117}],119:[function(e,t,o){"use strict";function n(e,t,o,n,r,i,s){var a=(m.cloneNode(!0),w.cloneNode(!0));if(s.allowHtml?f("html").apply(this,arguments):f("text").apply(this,arguments),t.appendChild(a),u(t,"htAutocomplete"),t.firstChild||t.appendChild(document.createTextNode(String.fromCharCode(160))),!e.acArrowListener){var l=d(e);e.acArrowListener=function(r){c(r.target,"htAutocompleteArrow")&&e.view.wt.getSetting("onCellDblClick",null,new g(o,n),t)},l.addEventListener(e.rootElement,"mousedown",e.acArrowListener),e.addHookOnce("afterDestroy",function(){l.destroy()})}}Object.defineProperties(o,{autocompleteRenderer:{get:function(){return n}},__esModule:{value:!0}});var r,i,s,a,l=(r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r},u=l.addClass,c=l.hasClass,d=(l.empty,((i=e("eventManager"))&&i.__esModule&&i||{default:i}).eventManager),h=(s=e("renderers"))&&s.__esModule&&s||{default:s},f=h.getRenderer,p=h.registerRenderer,g=((a=e("3rdparty/walkontable/src/cell/coords"))&&a.__esModule&&a||{default:a}).WalkontableCellCoords,m=document.createElement("DIV");m.className="htAutocompleteWrapper";var w=document.createElement("DIV");w.className="htAutocompleteArrow",w.appendChild(document.createTextNode(String.fromCharCode(9660)));p("autocomplete",n)},{"3rdparty/walkontable/src/cell/coords":6,eventManager:42,"helpers/dom/element":47,renderers:117}],120:[function(e,t,o){"use strict";function n(e,t,o,n,a,l,u){function c(e){var t=O(E,e.keyCode);t("SPACE|ENTER|DELETE|BACKSPACE")&&!x(e)&&h(function(){k(e),e.preventDefault()}),t("SPACE|ENTER")&&d(),t("DELETE|BACKSPACE")&&d(!0)}function d(){var t=void 0!==arguments[0]&&arguments[0],o=e.getSelectedRange();if(o){for(var n=o.getTopLeftCorner(),r=o.getBottomRightCorner(),i=[],s=n.row;s<=r.row;s+=1)for(var a=n.col;a<=r.col;a+=1){var l=e.getCellMeta(s,a);if("checkbox"!==l.type)return;if(l.readOnly!==!0){void 0===l.checkedTemplate&&(l.checkedTemplate=!0),void 0===l.uncheckedTemplate&&(l.uncheckedTemplate=!1);var u=e.getDataAtCell(s,a);t===!1?u===l.checkedTemplate?i.push([s,a,l.uncheckedTemplate]):[l.uncheckedTemplate,null,void 0].indexOf(u)!==-1&&i.push([s,a,l.checkedTemplate]):i.push([s,a,l.uncheckedTemplate])}}i.length>0&&e.setDataAtCell(i)}}function h(t){var o=e.getSelectedRange();if(o)for(var n=o.getTopLeftCorner(),r=o.getBottomRightCorner(),i=n.row;i<=r.row;i++)for(var s=n.col;s<=r.col;s++){var a=e.getCellMeta(i,s);if("checkbox"!==a.type)return;var l=e.getCell(i,s);if(null==l)t(i,s,a);else{var u=l.querySelectorAll("input[type=checkbox]");u.length>0&&!a.readOnly&&t(u)}}}M("base").apply(this,arguments);var f=(r(e),i()),p=u.label,g=!1;if(void 0===u.checkedTemplate&&(u.checkedTemplate=!0),void 0===u.uncheckedTemplate&&(u.uncheckedTemplate=!1),y(t),l===u.checkedTemplate||C(l,u.checkedTemplate)?f.checked=!0:l===u.uncheckedTemplate||C(l,u.uncheckedTemplate)?f.checked=!1:null===l?b(f,"noValue"):(f.style.display="none",b(f,A),g=!0),f.setAttribute("data-row",o),f.setAttribute("data-col",n),!g&&p){var m="";p.value?m="function"==typeof p.value?p.value.call(this,o,n,a,l):p.value:p.property&&(m=e.getDataAtRowProp(o,p.property));var w=s(m);"before"===p.position?w.appendChild(f):w.insertBefore(f,w.firstChild),f=w}t.appendChild(f),g&&t.appendChild(document.createTextNode("#bad-value#")),H.has(e)||(H.set(e,!0),e.addHook("beforeKeyDown",c))}function r(e){var t=D.get(e);return t||(t=new _(e),t.addEventListener(e.rootElement,"click",function(t){return l(t,e)}),t.addEventListener(e.rootElement,"mouseup",function(t){return a(t,e)}),t.addEventListener(e.rootElement,"change",function(t){return u(t,e)}),D.set(e,t)),t}function i(){var e=document.createElement("input");return e.className="htCheckboxRendererInput",e.type="checkbox",e.setAttribute("autocomplete","off"),e.setAttribute("tabindex","-1"),e.cloneNode(!1)}function s(e){var t=document.createElement("label");return t.className="htCheckboxRendererLabel",t.appendChild(document.createTextNode(e)),t.cloneNode(!0)}function a(e,t){c(e.target)&&setTimeout(t.listen,10)}function l(e,t){if(!c(e.target))return!1;var o=parseInt(e.target.getAttribute("data-row"),10),n=parseInt(e.target.getAttribute("data-col"),10);t.getCellMeta(o,n).readOnly&&e.preventDefault()}function u(e,t){if(!c(e.target))return!1;var o=parseInt(e.target.getAttribute("data-row"),10),n=parseInt(e.target.getAttribute("data-col"),10),r=t.getCellMeta(o,n);if(!r.readOnly){var i=null;i=e.target.checked?void 0===r.checkedTemplate||r.checkedTemplate:void 0!==r.uncheckedTemplate&&r.uncheckedTemplate,t.setDataAtCell(o,n,i)}}function c(e){return"INPUT"===e.tagName&&"checkbox"===e.getAttribute("type")}Object.defineProperties(o,{checkboxRenderer:{get:function(){return n}},__esModule:{value:!0}});var d,h,f,p,g,m,w,v=(d=e("helpers/dom/element"))&&d.__esModule&&d||{default:d},y=v.empty,b=v.addClass,C=(v.hasClass,((h=e("helpers/string"))&&h.__esModule&&h||{default:h}).equalsIgnoreCase),_=((f=e("eventManager"))&&f.__esModule&&f||{default:f}).EventManager,R=(p=e("renderers"))&&p.__esModule&&p||{default:p},M=R.getRenderer,S=R.registerRenderer,E=((g=e("helpers/unicode"))&&g.__esModule&&g||{default:g}).isKey,O=((m=e("helpers/function"))&&m.__esModule&&m||{default:m}).partial,T=(w=e("helpers/dom/event"))&&w.__esModule&&w||{default:w},k=T.stopImmediatePropagation,x=T.isImmediatePropagationStopped,H=new WeakMap,D=new WeakMap,A="htBadValue";S("checkbox",n)},{eventManager:42,"helpers/dom/element":47,"helpers/dom/event":48,"helpers/function":50,"helpers/string":55,"helpers/unicode":56,renderers:117}],121:[function(e,t,o){"use strict";function n(e,t,o,n,r,i,a){l("base").apply(this,arguments),null!==i&&void 0!==i||(i=""),s(t,i)}Object.defineProperties(o,{htmlRenderer:{get:function(){return n}},__esModule:{value:!0}});var r,i,s=((r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r}).fastInnerHTML,a=(i=e("renderers"))&&i.__esModule&&i||{default:i},l=a.getRenderer;(0,a.registerRenderer)("html",n)},{"helpers/dom/element":47,renderers:117}],122:[function(e,t,o){"use strict";function n(e,t,o,n,r,i,s){if(d(i)){void 0!==s.language&&a.culture(s.language),i=a(i).format(s.format||"0");var l=s.className||"",c=l.length?l.split(" "):[];c.indexOf("htLeft")<0&&c.indexOf("htCenter")<0&&c.indexOf("htRight")<0&&c.indexOf("htJustify")<0&&c.push("htRight"),c.indexOf("htNumeric")<0&&c.push("htNumeric"),s.className=c.join(" ")}u("text")(e,t,o,n,r,i,s)}Object.defineProperties(o,{numericRenderer:{get:function(){return n}},__esModule:{value:!0}});var r,i,s,a=((r=e("numbro"))&&r.__esModule&&r||{default:r}).default,l=(i=e("renderers"))&&i.__esModule&&i||{default:i},u=l.getRenderer,c=l.registerRenderer,d=((s=e("helpers/number"))&&s.__esModule&&s||{default:s}).isNumeric;c("numeric",n)},{"helpers/number":52,numbro:"numbro",renderers:117}],123:[function(e,t,o){"use strict";function n(e,t,o,n,r,i,a){l("text").apply(this,arguments),i=t.innerHTML;var u,c=a.hashLength||i.length,d=a.hashSymbol||"*";for(u="";u.split(d).length-1<c;u+=d);s(t,u)}Object.defineProperties(o,{passwordRenderer:{get:function(){return n}},__esModule:{value:!0}});var r,i,s=((r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r}).fastInnerHTML,a=(i=e("renderers"))&&i.__esModule&&i||{default:i},l=a.getRenderer;(0,a.registerRenderer)("password",n)},{"helpers/dom/element":47,renderers:117}],124:[function(e,t,o){"use strict";function n(e,t,o,n,r,i,s){h("base").apply(this,arguments),!i&&s.placeholder&&(i=s.placeholder);var a=c(i);if(e.getSettings().trimWhitespace||(a=a.replace(/ /g,String.fromCharCode(160))),s.rendererTemplate){l(t);var d=document.createElement("TEMPLATE");d.setAttribute("bind","{{}}"),d.innerHTML=s.rendererTemplate,HTMLTemplateElement.decorate(d),d.model=e.getSourceDataAtRow(o),t.appendChild(d)}else u(t,a)}Object.defineProperties(o,{textRenderer:{get:function(){return n}},__esModule:{value:!0}});var r,i,s,a=(r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r},l=a.empty,u=a.fastInnerText,c=((i=e("helpers/mixed"))&&i.__esModule&&i||{default:i}).stringify,d=(s=e("renderers"))&&s.__esModule&&s||{default:s},h=d.getRenderer;(0,d.registerRenderer)("text",n)},{"helpers/dom/element":47,"helpers/mixed":51,renderers:117}],125:[function(e,t,o){!function(e){"use strict";function t(e){return{configurable:!0,enumerable:!1,value:e,writable:!0}}function o(){return"__$"+Math.floor(1e9*Math.random())+"$"+ ++D+"$__"}function n(e){return I[e]}function r(){var e=o();return I[e]=!0,e}function i(e){return"object"==typeof e&&e instanceof l}function s(e){return i(e)?"symbol":typeof e}function a(e){var t=new l(e);if(!(this instanceof a))return t;throw new TypeError("Symbol cannot be new'ed")}function l(e){var t=o();S(this,L,{value:this}),S(this,A,{value:t}),S(this,P,{value:e}),c(this),N[t]=this}function u(e){var t=e[W];return t&&t.self===e?t:x(e)?(V.hash.value=B++,V.self.value=e,j.value=R(null,V),S(e,W,j),j.value):void 0}function c(e){return u(e),E.apply(this,arguments)}function d(e){return N[e]||I[e]}function h(e){return i(e)?e[A]:e}function f(e){for(var t=[],o=T(e),n=0;n<o.length;n++){var r=N[o[n]];r&&t.push(r)}return t}function p(t){return e.traceur&&e.traceur.options[t]}function g(e){for(var t=1;t<arguments.length;t++)for(var o=T(arguments[t]),n=0;n<o.length;n++){var r=o[n];d(r)||function(t,o){S(e,o,{get:function(){return t[o]},enumerable:!0})}(arguments[t],o[n])}return e}function m(e){return null!=e&&("object"==typeof e||"function"==typeof e)}function w(e){if(null==e)throw _();return C(e)}function v(e){if(null==e)throw new TypeError("Value cannot be converted to an Object");return e}function y(e,t){e.Symbol||(e.Symbol=t,Object.getOwnPropertySymbols=f),e.Symbol.iterator||(e.Symbol.iterator=t("Symbol.iterator"))}function b(e){y(e,a),e.Reflect=e.Reflect||{},e.Reflect.global=e.Reflect.global||e}if(!e.$traceurRuntime){var C=Object,_=TypeError,R=C.create,M=C.defineProperties,S=C.defineProperty,E=C.freeze,O=C.getOwnPropertyDescriptor,T=C.getOwnPropertyNames,k=C.keys,x=Object.isExtensible,H=t,D=0,A=o(),P=o(),L=o(),N=R(null),I=R(null);S(a.prototype,"constructor",t(a)),S(a.prototype,"toString",H(function(){var e=this[L];if(!p("symbols"))return e[A];if(!e)throw TypeError("Conversion from symbol to string");var t=e[P];return void 0===t&&(t=""),"Symbol("+t+")"})),S(a.prototype,"valueOf",H(function(){var e=this[L];if(!e)throw TypeError("Conversion from symbol to string");return p("symbols")?e:e[A]})),S(l.prototype,"constructor",t(a)),S(l.prototype,"toString",{value:a.prototype.toString,enumerable:!1}),S(l.prototype,"valueOf",{value:a.prototype.valueOf,enumerable:!1});var W=r(),j={value:void 0},V={hash:{value:void 0},self:{value:void 0}},B=0;c(l.prototype),b(e),e.$traceurRuntime={checkObjectCoercible:v,createPrivateName:r,defineProperties:M,defineProperty:S,exportStar:g,getOwnHashObject:u,getOwnPropertyDescriptor:O,getOwnPropertyNames:T,isObject:m,isPrivateName:n,isSymbolString:d,keys:k,setupGlobals:b,toObject:w,toProperty:h,typeof:s}}}(window),function(){"use strict";function e(){for(var e,o=[],n=0,r=0;r<arguments.length;r++){var i=$traceurRuntime.checkObjectCoercible(arguments[r]);"function"!=typeof i[t(Symbol.iterator)]&&(i[t(Symbol.iterator)]=function(){var e=this,t=e.length,o=0;return{next:function(){var n={done:!0};return o<t&&(n.done=!1,n.value=e[o],++o),n}}});for(var s=i[t(Symbol.iterator)]();!(e=s.next()).done;)o[n++]=e.value}return o}var t=$traceurRuntime.toProperty;$traceurRuntime.spread=e}(),function(){"use strict";function e(e,t){var o=g(e);do{var n=p(o,t);if(n)return n;o=g(o)}while(o)}function t(e){return e.__proto__}function o(e,t,o,r){return n(e,t,o).apply(e,r)}function n(t,o,n){var r=e(o,n);if(r)return r.get?r.get.call(t):r.value}function r(t,o,n,r){var i=e(o,n);if(i&&i.set)return i.set.call(t,r),r;throw c("super has no setter '"+n+"'.")}function i(e){for(var t={},o=v(e),n=0;n<o.length;n++){var r=o[n];t[r]=p(e,r)}for(var i=y(e),n=0;n<i.length;n++){var s=i[n];t[m(s)]=p(e,m(s))}return t}function s(e,t,o,n){return f(t,"constructor",{value:e,configurable:!0,enumerable:!1,writable:!0}),arguments.length>3?("function"==typeof n&&(e.__proto__=n),e.prototype=d(a(n),i(t))):e.prototype=t,f(e,"prototype",{configurable:!1,writable:!1}),h(e,i(o))}function a(e){if("function"==typeof e){var t=e.prototype;if(u(t)===t||null===t)return e.prototype;throw new c("super prototype must be an Object or null")}if(null===e)return null;throw new c("Super expression must either be null or a function, not "+typeof e+".")}function l(e,t,n){null!==g(t)&&o(e,t,"constructor",n)}var u=Object,c=TypeError,d=u.create,h=$traceurRuntime.defineProperties,f=$traceurRuntime.defineProperty,p=$traceurRuntime.getOwnPropertyDescriptor,g=Object.getPrototypeOf,m=$traceurRuntime.toProperty,w=Object,v=w.getOwnPropertyNames,y=w.getOwnPropertySymbols;$traceurRuntime.createClass=s,$traceurRuntime.defaultSuperCall=l,$traceurRuntime.superCall=o,$traceurRuntime.superConstructor=t,$traceurRuntime.superGet=n,$traceurRuntime.superSet=r}()},{}],126:[function(e,t,o){"use strict";function n(e){var t=this,o=this;this.eventManager=R(e),this.instance=e,this.settings=e.getSettings(),this.selectionMouseDown=!1;var n=e.rootElement.getAttribute("style");n&&e.rootElement.setAttribute("data-originalstyle",n),p(e.rootElement,"handsontable");var r=document.createElement("TABLE");p(r,"htCore"),e.getSettings().tableClassName&&p(r,e.getSettings().tableClassName),this.THEAD=document.createElement("THEAD"),r.appendChild(this.THEAD),this.TBODY=document.createElement("TBODY"),r.appendChild(this.TBODY),e.table=r,e.container.insertBefore(r,e.container.firstChild),this.eventManager.addEventListener(e.rootElement,"mousedown",function(e){this.selectionMouseDown=!0,o.isTextSelectionAllowed(e.target)||(s(),e.preventDefault(),window.focus())}),this.eventManager.addEventListener(e.rootElement,"mouseup",function(e){this.selectionMouseDown=!1}),this.eventManager.addEventListener(e.rootElement,"mousemove",function(e){this.selectionMouseDown&&!o.isTextSelectionAllowed(e.target)&&(s(),e.preventDefault())}),this.eventManager.addEventListener(document.documentElement,"keyup",function(t){e.selection.isInProgress()&&!t.shiftKey&&e.selection.finish()});var i;this.isMouseDown=function(){return i},this.eventManager.addEventListener(document.documentElement,"mouseup",function(t){e.selection.isInProgress()&&1===t.which&&e.selection.finish(),i=!1,_(document.activeElement)&&e.unlisten()}),this.eventManager.addEventListener(document.documentElement,"mousedown",function(t){var n=t.target,r=t.target,s=t.x||t.clientX,a=t.y||t.clientY;if(!i&&e.rootElement){if(r===e.view.wt.wtTable.holder){var l=v();if(document.elementFromPoint(s+l,a)!==e.view.wt.wtTable.holder||document.elementFromPoint(s,a+l)!==e.view.wt.wtTable.holder)return}else for(;r!==document.documentElement;){if(null===r){if(t.isTargetWebComponent)break;return}if(r===e.rootElement)return;r=r.parentNode}("function"==typeof o.settings.outsideClickDeselects?o.settings.outsideClickDeselects(n):o.settings.outsideClickDeselects)?e.deselectCell():e.destroyEditor()}}),this.eventManager.addEventListener(r,"selectstart",function(e){o.settings.fragmentSelection||C(e.target)||e.preventDefault()});var s=function(){window.getSelection?window.getSelection().empty?window.getSelection().empty():window.getSelection().removeAllRanges&&window.getSelection().removeAllRanges():document.selection&&document.selection.empty()},a=[new x({className:"current",border:{width:2,color:"#5292F7",cornerVisible:function(){return o.settings.fillHandle&&!o.isCellEdited()&&!e.selection.isMultiple()},multipleSelectionHandlesVisible:function(){return!o.isCellEdited()&&!e.selection.isMultiple()}}}),new x({className:"area",border:{width:1,color:"#89AFF9",cornerVisible:function(){return o.settings.fillHandle&&!o.isCellEdited()&&e.selection.isMultiple()},multipleSelectionHandlesVisible:function(){return!o.isCellEdited()&&e.selection.isMultiple()}}}),new x({className:"highlight",highlightHeaderClassName:o.settings.currentHeaderClassName,highlightRowClassName:o.settings.currentRowClassName,highlightColumnClassName:o.settings.currentColClassName}),new x({className:"fill",border:{width:1,color:"red"}})];a.current=a[0],a.area=a[1],a.highlight=a[2],a.fill=a[3];var l={debug:function(){return o.settings.debug},externalRowCalculator:this.instance.getPlugin("autoRowSize")&&this.instance.getPlugin("autoRowSize").isEnabled(),table:r,preventOverflow:function(){return t.settings.preventOverflow},stretchH:function(){return o.settings.stretchH},data:e.getDataAtCell,totalRows:function(){return e.countRows()},totalColumns:function(){return e.countCols()},fixedColumnsLeft:function(){return o.settings.fixedColumnsLeft},fixedRowsTop:function(){return o.settings.fixedRowsTop},fixedRowsBottom:function(){return o.settings.fixedRowsBottom},minSpareRows:function(){return o.settings.minSpareRows},renderAllRows:o.settings.renderAllRows,rowHeaders:function(){var t=[];return e.hasRowHeaders()&&t.push(function(e,t){o.appendRowHeader(e,t)}),h.hooks.run(e,"afterGetRowHeaderRenderers",t),t},columnHeaders:function(){var t=[];return e.hasColHeaders()&&t.push(function(e,t){o.appendColHeader(e,t)}),h.hooks.run(e,"afterGetColumnHeaderRenderers",t),t},columnWidth:e.getColWidth,rowHeight:e.getRowHeight,cellRenderer:function(e,t,n){var r=o.instance.getCellMeta(e,t),i=o.instance.colToProp(t),s=o.instance.getDataAtRowProp(e,i);o.instance.hasHook("beforeValueRender")&&(s=o.instance.runHooks("beforeValueRender",s)),o.instance.runHooks("beforeRenderer",n,e,t,i,s,r),o.instance.getCellRenderer(r)(o.instance,n,e,t,i,s,r),o.instance.runHooks("afterRenderer",n,e,t,i,s,r)},selections:a,hideBorderOnMouseDownOver:function(){return o.settings.fragmentSelection},onCellMouseDown:function(t,n,r,s){var a={row:!1,column:!1,cells:!1};if(e.listen(),o.activeWt=s,i=!0,h.hooks.run(e,"beforeOnCellMouseDown",t,n,r,a),!E(t)){var l=e.getSelectedRange(),u=e.selection,c=u.selectedHeader;if(t.shiftKey&&l)n.row>=0&&n.col>=0&&!a.cells?(u.setSelectedHeaders(!1,!1),u.setRangeEnd(n)):(c.cols||c.rows)&&n.row>=0&&n.col>=0&&!a.cells?(u.setSelectedHeaders(!1,!1),u.setRangeEnd(new k(n.row,n.col))):c.cols&&n.row<0&&!a.column?u.setRangeEnd(new k(l.to.row,n.col)):c.rows&&n.col<0&&!a.row?u.setRangeEnd(new k(n.row,l.to.col)):(!c.cols&&!c.rows&&n.col<0||c.cols&&n.col<0)&&!a.row?(u.setSelectedHeaders(!0,!1),u.setRangeStartOnly(new k(l.from.row,0)),u.setRangeEnd(new k(n.row,e.countCols()-1))):(!c.cols&&!c.rows&&n.row<0||c.rows&&n.row<0)&&!a.column&&(u.setSelectedHeaders(!1,!0),u.setRangeStartOnly(new k(0,l.from.col)),u.setRangeEnd(new k(e.countRows()-1,n.col)));else{var d=!0;if(l){var f=l,p=f.from,g=f.to,m=!u.inInSelection(n);if(n.row<0&&c.cols){var w=Math.min(p.col,g.col),v=Math.max(p.col,g.col);d=n.col<w||n.col>v}else if(n.col<0&&c.rows){var y=Math.min(p.row,g.row),b=Math.max(p.row,g.row);d=n.row<y||n.row>b}else d=m}var C=O(t),_=T(t)||"touchstart"===t.type;n.row<0&&n.col>=0&&!a.column?(u.setSelectedHeaders(!1,!0),(_||C&&d)&&(u.setRangeStartOnly(new k(0,n.col)),u.setRangeEnd(new k(Math.max(e.countRows()-1,0),n.col),!1))):n.col<0&&n.row>=0&&!a.row?(u.setSelectedHeaders(!0,!1),(_||C&&d)&&(u.setRangeStartOnly(new k(n.row,0)),u.setRangeEnd(new k(n.row,Math.max(e.countCols()-1,0)),!1))):n.col>=0&&n.row>=0&&!a.cells?(_||C&&d)&&(u.setSelectedHeaders(!1,!1),u.setRangeStart(n)):n.col<0&&n.row<0&&(n.row=0,n.col=0,u.setSelectedHeaders(!1,!1,!0),u.setRangeStart(n))}h.hooks.run(e,"afterOnCellMouseDown",t,n,r),o.activeWt=o.wt}},onCellMouseOut:function(t,n,r,i){o.activeWt=i,h.hooks.run(e,"beforeOnCellMouseOut",t,n,r),E(t)||(h.hooks.run(e,"afterOnCellMouseOut",t,n,r),o.activeWt=o.wt)},onCellMouseOver:function(t,n,r,s){var a={row:!1,column:!1,cell:!1};o.activeWt=s,h.hooks.run(e,"beforeOnCellMouseOver",t,n,r,a),E(t)||(0===t.button&&i&&(n.row>=0&&n.col,e.selection.selectedHeader.cols&&!a.column?e.selection.setRangeEnd(new k(e.countRows()-1,n.col),!1):e.selection.selectedHeader.rows&&!a.row?e.selection.setRangeEnd(new k(n.row,e.countCols()-1),!1):a.cell||e.selection.setRangeEnd(n)),h.hooks.run(e,"afterOnCellMouseOver",t,n,r),o.activeWt=o.wt)},onCellMouseUp:function(t,n,r,i){o.activeWt=i,h.hooks.run(e,"beforeOnCellMouseUp",t,n,r),h.hooks.run(e,"afterOnCellMouseUp",t,n,r),o.activeWt=o.wt},onCellCornerMouseDown:function(t){t.preventDefault(),h.hooks.run(e,"afterOnCellCornerMouseDown",t)},onCellCornerDblClick:function(t){t.preventDefault(),h.hooks.run(e,"afterOnCellCornerDblClick",t)},beforeDraw:function(e,t){o.beforeRender(e,t)},onDraw:function(e){o.onDraw(e)},onScrollVertically:function(){e.runHooks("afterScrollVertically")},onScrollHorizontally:function(){e.runHooks("afterScrollHorizontally")},onBeforeDrawBorders:function(t,o){e.runHooks("beforeDrawBorders",t,o)},onBeforeTouchScroll:function(){e.runHooks("beforeTouchScroll")},onAfterMomentumScroll:function(){e.runHooks("afterMomentumScroll")},onBeforeStretchingColumnWidth:function(t,o){return e.runHooks("beforeStretchingColumnWidth",t,o)},onModifyRowHeaderWidth:function(t){return e.runHooks("modifyRowHeaderWidth",t)},viewportRowCalculatorOverride:function(t){var n=e.countRows(),r=o.settings.viewportRowRenderingOffset;if("auto"===r&&o.settings.fixedRowsTop&&(r=10),"number"==typeof r&&(t.startRow=Math.max(t.startRow-r,0),t.endRow=Math.min(t.endRow+r,n-1)),"auto"===r){var i=t.startRow+t.endRow-t.startRow,s=Math.ceil(i/n*12);t.startRow=Math.max(t.startRow-s,0),t.endRow=Math.min(t.endRow+s,n-1)}e.runHooks("afterViewportRowCalculatorOverride",t)},viewportColumnCalculatorOverride:function(t){var n=e.countCols(),r=o.settings.viewportColumnRenderingOffset;if("auto"===r&&o.settings.fixedColumnsLeft&&(r=10),"number"==typeof r&&(t.startColumn=Math.max(t.startColumn-r,0),t.endColumn=Math.min(t.endColumn+r,n-1)),"auto"===r){var i=t.startColumn+t.endColumn-t.startColumn,s=Math.ceil(i/n*12);t.startRow=Math.max(t.startColumn-s,0),t.endColumn=Math.min(t.endColumn+s,n-1)}e.runHooks("afterViewportColumnCalculatorOverride",t)},rowHeaderWidth:function(){return o.settings.rowHeaderWidth},columnHeaderHeight:function(){var t=e.runHooks("modifyColumnHeaderHeight");return o.settings.columnHeaderHeight||t}};h.hooks.run(e,"beforeInitWalkontable",l),this.wt=new H(l),this.activeWt=this.wt,this.eventManager.addEventListener(o.wt.wtTable.spreader,"mousedown",function(e){e.target===o.wt.wtTable.spreader&&3===e.which&&S(e)}),this.eventManager.addEventListener(o.wt.wtTable.spreader,"contextmenu",function(e){e.target===o.wt.wtTable.spreader&&3===e.which&&S(e)}),this.eventManager.addEventListener(document.documentElement,"click",function(){
41
- o.settings.observeDOMVisibility&&o.wt.drawInterrupted&&(o.instance.forceFullRender=!0,o.render())})}Object.defineProperties(o,{TableView:{get:function(){return n}},__esModule:{value:!0}});var r,i,s,a,l,u,c,d,h=((r=e("browser"))&&r.__esModule&&r||{default:r}).default,f=(i=e("helpers/dom/element"))&&i.__esModule&&i||{default:i},p=f.addClass,g=f.empty,m=f.fastInnerHTML,w=f.fastInnerText,v=f.getScrollbarWidth,y=f.hasClass,b=f.isChildOf,C=f.isInput,_=f.isOutsideInput,R=(f.removeClass,((s=e("helpers/object"))&&s.__esModule&&s||{default:s}).createObjectPropListener,((a=e("eventManager"))&&a.__esModule&&a||{default:a}).eventManager),M=(l=e("helpers/dom/event"))&&l.__esModule&&l||{default:l},S=M.stopPropagation,E=M.isImmediatePropagationStopped,O=M.isRightClick,T=M.isLeftClick,k=((u=e("3rdparty/walkontable/src/cell/coords"))&&u.__esModule&&u||{default:u}).WalkontableCellCoords,x=((c=e("3rdparty/walkontable/src/selection"))&&c.__esModule&&c||{default:c}).WalkontableSelection,H=((d=e("3rdparty/walkontable/src/core"))&&d.__esModule&&d||{default:d}).Walkontable;h.TableView=n,n.prototype.isTextSelectionAllowed=function(e){if(C(e))return!0;var t=b(e,this.instance.view.wt.wtTable.spreader);return!(this.settings.fragmentSelection!==!0||!t)||(!("cell"!==this.settings.fragmentSelection||!this.isSelectedOnlyCell()||!t)||!(this.settings.fragmentSelection||!this.isCellEdited()||!this.isSelectedOnlyCell()))},n.prototype.isSelectedOnlyCell=function(){var e=this.instance.getSelected()||[],t=e[0],o=e[1],n=e[2],r=e[3];return void 0!==t&&t===n&&o===r},n.prototype.isCellEdited=function(){var e=this.instance.getActiveEditor();return e&&e.isOpened()},n.prototype.beforeRender=function(e,t){e&&h.hooks.run(this.instance,"beforeRender",this.instance.forceFullRender,t)},n.prototype.onDraw=function(e){e&&h.hooks.run(this.instance,"afterRender",this.instance.forceFullRender)},n.prototype.render=function(){this.wt.draw(!this.instance.forceFullRender),this.instance.forceFullRender=!1,this.instance.renderCall=!1},n.prototype.getCellAtCoords=function(e,t){var o=this.wt.getCell(e,t);return o<0?null:o},n.prototype.scrollViewport=function(e){this.wt.scrollViewport(e)},n.prototype.appendRowHeader=function(e,t){if(t.firstChild){var o=t.firstChild;if(!y(o,"relative"))return g(t),void this.appendRowHeader(e,t);this.updateCellHeader(o.querySelector(".rowHeader"),e,this.instance.getRowHeader)}else{var n=document.createElement("div"),r=document.createElement("span");n.className="relative",r.className="rowHeader",this.updateCellHeader(r,e,this.instance.getRowHeader),n.appendChild(r),t.appendChild(n)}h.hooks.run(this.instance,"afterGetRowHeader",e,t)},n.prototype.appendColHeader=function(e,t){if(t.firstChild){var o=t.firstChild;y(o,"relative")?this.updateCellHeader(o.querySelector(".colHeader"),e,this.instance.getColHeader):(g(t),this.appendColHeader(e,t))}else{var n=document.createElement("div"),r=document.createElement("span");n.className="relative",r.className="colHeader",this.updateCellHeader(r,e,this.instance.getColHeader),n.appendChild(r),t.appendChild(n)}h.hooks.run(this.instance,"afterGetColHeader",e,t)},n.prototype.updateCellHeader=function(e,t,o){var n=t,r=this.wt.wtOverlays.getParentOverlay(e)||this.wt;e.parentNode&&(y(e,"colHeader")?n=r.wtTable.columnFilter.sourceToRendered(t):y(e,"rowHeader")&&(n=r.wtTable.rowFilter.sourceToRendered(t))),n>-1?m(e,o(t)):(w(e,String.fromCharCode(160)),p(e,"cornerHeader"))},n.prototype.maximumVisibleElementWidth=function(e){var t=this.wt.wtViewport.getWorkspaceWidth(),o=t-e;return o>0?o:0},n.prototype.maximumVisibleElementHeight=function(e){var t=this.wt.wtViewport.getWorkspaceHeight(),o=t-e;return o>0?o:0},n.prototype.mainViewIsActive=function(){return this.wt===this.activeWt},n.prototype.destroy=function(){this.wt.destroy(),this.eventManager.destroy()}},{"3rdparty/walkontable/src/cell/coords":6,"3rdparty/walkontable/src/core":8,"3rdparty/walkontable/src/selection":19,browser:24,eventManager:42,"helpers/dom/element":47,"helpers/dom/event":48,"helpers/object":53}],127:[function(e,t,o){"use strict";Object.defineProperties(o,{NodeStructure:{get:function(){return i}},LinkedList:{get:function(){return s}},__esModule:{value:!0}});var n,r=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,i=function(e){this.data=e,this.next=null,this.prev=null};$traceurRuntime.createClass(i,{},{});var s=function(){this.first=null,this.last=null};$traceurRuntime.createClass(s,{push:function(e){var t=new i(e);if(null===this.first)this.first=this.last=t;else{var o=this.last;this.last=t,t.prev=o,o.next=t}},unshift:function(e){var t=new i(e);if(null===this.first)this.first=this.last=t;else{var o=this.first;this.first=t,t.next=o,o.prev=t}},inorder:function(e){for(var t=this.first;t;)e(t),t=t.next},remove:function(e){if(null===this.first)return!1;for(var t,o,n=this.first;n;){if(n.data===e)return t=n.next,o=n.prev,t&&(t.prev=o),o&&(o.next=t),n===this.first&&(this.first=t),n===this.last&&(this.last=o),!0;n=n.next}return!1},hasCycle:function(){for(var e=this.first,t=this.first;;){if(null===e)return!1;if(null===(e=e.next))return!1;if(e=e.next,t=t.next,e===t)return!0}},pop:function(){if(null===this.last)return null;var e=this.last;return this.last=this.last.prev,e},shift:function(){if(null===this.first)return null;var e=this.first;return this.first=this.first.next,e},recursiveReverse:function(){function e(t,o){o&&(e(o,o.next),o.next=t)}if(this.first){e(this.first,this.first.next),this.first.next=null;var t=this.first;this.first=this.last,this.last=t}},reverse:function(){if(this.first&&this.first.next){for(var e,t=this.first.next,o=this.first;t;)e=t.next,t.next=o,o.prev=t,o=t,t=e;this.first.next=null,this.last.prev=null,e=this.first,this.first=o,this.last=e}}},{}),r.utils.NodeStructure=i,r.utils.LinkedList=s},{browser:24}],128:[function(e,t,o){"use strict";Object.defineProperties(o,{GhostTable:{get:function(){return g}},__esModule:{value:!0}});var n,r,i,s,a,l,u=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,c=(r=e("helpers/dom/element"))&&r.__esModule&&r||{default:r},d=c.addClass,h=c.outerHeight,f=c.outerWidth,p=((i=e("helpers/array"))&&i.__esModule&&i||{default:i}).arrayEach,g=(((s=e("helpers/object"))&&s.__esModule&&s||{default:s}).objectEach,((a=e("helpers/number"))&&a.__esModule&&a||{default:a}).rangeEach,((l=e("helpers/mixed"))&&l.__esModule&&l||{default:l}).stringify,function(e){this.hot=e,this.container=null,this.injected=!1,this.rows=[],this.columns=[],this.samples=null,this.settings={useHeaders:!0}});$traceurRuntime.createClass(g,{addRow:function(e,t){if(this.columns.length)throw new Error("Doesn't support multi-dimensional table");this.rows.length||(this.container=this.createContainer(this.hot.rootElement.className));var o={row:e};this.rows.push(o),this.samples=t,this.table=this.createTable(this.hot.table.className),this.table.colGroup.appendChild(this.createColGroupsCol()),this.table.tr.appendChild(this.createRow(e)),this.container.container.appendChild(this.table.fragment),o.table=this.table.table},addColumnHeadersRow:function(e){if(null!=this.hot.getColHeader(0)){var t={row:-1};this.rows.push(t),this.container=this.createContainer(this.hot.rootElement.className),this.samples=e,this.table=this.createTable(this.hot.table.className),this.table.colGroup.appendChild(this.createColGroupsCol()),this.table.tHead.appendChild(this.createColumnHeadersRow()),this.container.container.appendChild(this.table.fragment),t.table=this.table.table}},addColumn:function(e,t){if(this.rows.length)throw new Error("Doesn't support multi-dimensional table");this.columns.length||(this.container=this.createContainer(this.hot.rootElement.className));var o={col:e};this.columns.push(o),this.samples=t,this.table=this.createTable(this.hot.table.className),this.getSetting("useHeaders")&&null!==this.hot.getColHeader(e)&&this.hot.view.appendColHeader(e,this.table.th),this.table.tBody.appendChild(this.createCol(e)),this.container.container.appendChild(this.table.fragment),o.table=this.table.table},getHeights:function(e){this.injected||this.injectTable(),p(this.rows,function(t){e(t.row,h(t.table)-1)})},getWidths:function(e){this.injected||this.injectTable(),p(this.columns,function(t){e(t.col,f(t.table))})},setSettings:function(e){this.settings=e},setSetting:function(e,t){this.settings||(this.settings={}),this.settings[e]=t},getSettings:function(){return this.settings},getSetting:function(e){return this.settings?this.settings[e]:null},createColGroupsCol:function(){var e=this,t=document,o=t.createDocumentFragment();return this.hot.hasRowHeaders()&&o.appendChild(this.createColElement(-1)),this.samples.forEach(function(t){p(t.strings,function(t){o.appendChild(e.createColElement(t.col))})}),o},createRow:function(e){var t=this,o=document,n=o.createDocumentFragment(),r=o.createElement("th");return this.hot.hasRowHeaders()&&(this.hot.view.appendRowHeader(e,r),n.appendChild(r)),this.samples.forEach(function(r){p(r.strings,function(r){var i=r.col,s=t.hot.getCellMeta(e,i);s.col=i,s.row=e;var a=t.hot.getCellRenderer(s),l=o.createElement("td");a(t.hot,l,e,i,t.hot.colToProp(i),r.value,s),n.appendChild(l)})}),n},createColumnHeadersRow:function(){var e=this,t=document,o=t.createDocumentFragment();if(this.hot.hasRowHeaders()){var n=t.createElement("th");this.hot.view.appendColHeader(-1,n),o.appendChild(n)}return this.samples.forEach(function(n){p(n.strings,function(n){var r=n.col,i=t.createElement("th");e.hot.view.appendColHeader(r,i),o.appendChild(i)})}),o},createCol:function(e){var t=this,o=document,n=o.createDocumentFragment();return this.samples.forEach(function(r){p(r.strings,function(r){var i=r.row,s=t.hot.getCellMeta(i,e);s.col=e,s.row=i;var a=t.hot.getCellRenderer(s),l=o.createElement("td"),u=o.createElement("tr");a(t.hot,l,i,e,t.hot.colToProp(e),r.value,s),u.appendChild(l),n.appendChild(u)})}),n},clean:function(){this.rows.length=0,this.rows[-1]=void 0,this.columns.length=0,this.samples&&this.samples.clear(),this.samples=null,this.removeTable()},injectTable:function(){var e=void 0!==arguments[0]?arguments[0]:null;this.injected||((e||this.hot.rootElement).appendChild(this.container.fragment),this.injected=!0)},removeTable:function(){this.injected&&this.container.container.parentNode&&(this.container.container.parentNode.removeChild(this.container.container),this.container=null,this.injected=!1)},createColElement:function(e){var t=document,o=t.createElement("col");return o.style.width=this.hot.view.wt.wtTable.getStretchedColumnWidth(e)+"px",o},createTable:function(){var e=void 0!==arguments[0]?arguments[0]:"",t=document,o=t.createDocumentFragment(),n=t.createElement("table"),r=t.createElement("thead"),i=t.createElement("tbody"),s=t.createElement("colgroup"),a=t.createElement("tr"),l=t.createElement("th");return this.isVertical()&&n.appendChild(s),this.isHorizontal()&&(a.appendChild(l),r.appendChild(a),n.style.tableLayout="auto",n.style.width="auto"),n.appendChild(r),this.isVertical()&&i.appendChild(a),n.appendChild(i),d(n,e),o.appendChild(n),{fragment:o,table:n,tHead:r,tBody:i,colGroup:s,tr:a,th:l}},createContainer:function(){var e=void 0!==arguments[0]?arguments[0]:"",t=document,o=t.createDocumentFragment(),n=t.createElement("div");return e="htGhostTable htAutoSize "+e.trim(),d(n,e),o.appendChild(n),{fragment:o,container:n}},isVertical:function(){return!(!this.rows.length||this.columns.length)},isHorizontal:function(){return!(!this.columns.length||this.rows.length)}},{}),u.utils.GhostTable=g},{browser:24,"helpers/array":43,"helpers/dom/element":47,"helpers/mixed":51,"helpers/number":52,"helpers/object":53}],129:[function(e,t,o){"use strict";function n(e){return"string"==typeof e&&/fps$/.test(e)&&(e=1e3/parseInt(e.replace("fps","")||0,10)),e}Object.defineProperties(o,{Interval:{get:function(){return c}},__esModule:{value:!0}});var r,i,s=((r=e("browser"))&&r.__esModule&&r||{default:r}).default,a=(i=e("helpers/feature"))&&i.__esModule&&i||{default:i},l=a.requestAnimationFrame,u=a.cancelAnimationFrame,c=function(e,t){var o=this;this.timer=null,this.func=e,this.delay=n(t),this.stopped=!0,this._then=null,this._callback=function(){return o.__callback()}},d=c;$traceurRuntime.createClass(c,{start:function(){return this.stopped&&(this._then=Date.now(),this.stopped=!1,this.timer=l(this._callback)),this},stop:function(){return this.stopped||(this.stopped=!0,u(this.timer),this.timer=null),this},__callback:function(){if(this.timer=l(this._callback),this.delay){var e=Date.now(),t=e-this._then;t>this.delay&&(this._then=e-t%this.delay,this.func())}else this.func()}},{create:function(e,t){return new d(e,t)}}),s.utils.Interval=c},{browser:24,"helpers/feature":49}],130:[function(e,t,o){"use strict";function n(e,t){c.set(e,t)}function r(e){var t;if(!(e instanceof a.Core)){if(!c.has(e))throw Error("Record translator was not registered for this object identity");e=c.get(e)}return d.has(e)?t=d.get(e):(t=new u(e),d.set(e,t)),t}Object.defineProperties(o,{registerIdentity:{get:function(){return n}},getTranslator:{get:function(){return r}},__esModule:{value:!0}});var i,s,a=((i=e("browser"))&&i.__esModule&&i||{default:i}).default,l=((s=e("helpers/object"))&&s.__esModule&&s||{default:s}).isObject,u=function(e){this.hot=e};$traceurRuntime.createClass(u,{toVisualRow:function(e){return this.hot.runHooks("unmodifyRow",e)},toVisualColumn:function(e){return this.hot.runHooks("unmodifyCol",e)},toVisual:function(e,t){return l(e)?{row:this.toVisualRow(e.row),column:this.toVisualColumn(e.column)}:[this.toVisualRow(e),this.toVisualColumn(t)]},toPhysicalRow:function(e){return this.hot.runHooks("modifyRow",e)},toPhysicalColumn:function(e){return this.hot.runHooks("modifyCol",e)},toPhysical:function(e,t){return l(e)?{row:this.toPhysicalRow(e.row),column:this.toPhysicalColumn(e.column)}:[this.toPhysicalRow(e),this.toPhysicalColumn(t)]}},{});var c=new WeakMap,d=new WeakMap;a.utils.RecordTranslator=u,a.utils.RecordTranslatorUtils={registerIdentity:n,getTranslator:r}},{browser:24,"helpers/object":53}],131:[function(e,t,o){"use strict";var n;Object.defineProperties(o,{SamplesGenerator:{get:function(){return m}},__esModule:{value:!0}});var r,i,s,a,l,u,c=((r=e("browser"))&&r.__esModule&&r||{default:r}).default,d=(i=e("helpers/dom/element"))&&i.__esModule&&i||{default:i},h=(d.addClass,d.outerHeight,d.outerWidth,((s=e("helpers/array"))&&s.__esModule&&s||{default:s}).arrayEach,(a=e("helpers/object"))&&a.__esModule&&a||{default:a}),f=(h.objectEach,h.isObject),p=((l=e("helpers/number"))&&l.__esModule&&l||{default:l}).rangeEach,g=((u=e("helpers/mixed"))&&u.__esModule&&u||{default:u}).stringify,m=function(e){this.samples=null,this.dataFactory=e,this.customSampleCount=null,this.allowDuplicates=!1},w=m;$traceurRuntime.createClass(m,(n={},Object.defineProperty(n,"getSampleCount",{value:function(){return this.customSampleCount?this.customSampleCount:w.SAMPLE_COUNT},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"setSampleCount",{value:function(e){this.customSampleCount=e},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"setAllowDuplicates",{value:function(e){this.allowDuplicates=e},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"generateRowSamples",{value:function(e,t){return this.generateSamples("row",t,e)},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"generateColumnSamples",{value:function(e,t){return this.generateSamples("col",t,e)},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"generateSamples",{value:function(e,t,o){var n=this,r=new Map;return"number"==typeof o&&(o={from:o,to:o}),p(o.from,o.to,function(o){var i=n.generateSample(e,t,o);r.set(o,i)}),r},configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(n,"generateSample",{value:function(e,t,o){var n,r=this,i=new Map,s=[];return p(t.from,t.to,function(t){var a,l;if("row"===e)l=r.dataFactory(o,t);else{if("col"!==e)throw new Error("Unsupported sample type");l=r.dataFactory(t,o)}n=f(l)?Object.keys(l).length:Array.isArray(l)?l.length:g(l).length,i.has(n)||i.set(n,{needed:r.getSampleCount(),strings:[]});var u=i.get(n);if(u.needed){if(!(s.indexOf(l)>-1)||r.allowDuplicates){var c="row"===e?"col":"row";u.strings.push((a={},Object.defineProperty(a,"value",{value:l,configurable:!0,enumerable:!0,writable:!0}),Object.defineProperty(a,c,{value:t,configurable:!0,enumerable:!0,writable:!0}),a)),s.push(l),u.needed--}}}),i},configurable:!0,enumerable:!0,writable:!0}),n),{get SAMPLE_COUNT(){return 3}}),c.utils.SamplesGenerator=m},{browser:24,"helpers/array":43,"helpers/dom/element":47,"helpers/mixed":51,"helpers/number":52,"helpers/object":53}],132:[function(e,t,o){"use strict";function n(e){var t=void 0!==arguments[1]?arguments[1]:l,o=void 0!==arguments[2]?arguments[2]:0,i=void 0!==arguments[3]?arguments[3]:e.length;if(Math.abs(i-o)<=1)return[];var s=Math.ceil((o+i)/2);return n(e,t,o,s),n(e,t,s,i),r(e,t,o,s,i)}function r(e,t,o,n,r){for(var i=new a,s=new a,l=n-o,u=r-n,c=Math.max(l,u),d=r-o,h=0;h<c;h+=1)h<l&&i.push(e[o+h]),h<u&&s.push(e[n+h]);for(var f=0;f<d;)i.first&&s.first?t(i.first.data,s.first.data)>0?e[o+f]=s.shift().data:e[o+f]=i.shift().data:i.first?e[o+f]=i.shift().data:e[o+f]=s.shift().data,f+=1;return e}Object.defineProperties(o,{mergeSort:{get:function(){return n}},__esModule:{value:!0}});var i,s,a=((i=e("../dataStructures/linkedList"))&&i.__esModule&&i||{default:i}).LinkedList,l=function(e,t){var o=e.toString(),n=t.toString();return o===n?0:o<n?-1:1};((s=e("browser"))&&s.__esModule&&s||{default:s}).default.utils.mergeSort=n},{"../dataStructures/linkedList":127,browser:24}],133:[function(e,t,o){"use strict";function n(e,t){var o=e;return function(e){for(var n=!1,r=0,i=e.length;r<i;r++)if(o===e[r]){n=!0;break}t(n)}}var r,i,s=((r=e("browser"))&&r.__esModule&&r||{default:r}).default;((i=e("helpers/mixed"))&&i.__esModule&&i||{default:i}).stringify;s.AutocompleteValidator=function(e,t){if(null==e&&(e=""),this.allowEmpty&&""===e)return void t(!0);this.strict&&this.source?"function"==typeof this.source?this.source(e,n(e,t)):n(e,t)(this.source):t(!0)}},{browser:24,"helpers/mixed":51}],134:[function(e,t,o){"use strict";var n,r,i,s,a=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,l=((r=e("moment"))&&r.__esModule&&r||{default:r}).default,u=((i=e("../helpers/date"))&&i.__esModule&&i||{default:i}).getNormalizedDate,c=((s=e("editors"))&&s.__esModule&&s||{default:s}).getEditor;a.DateValidator=function(e,t){var o=!0,n=c("date",this.instance);null==e&&(e="");var r=l(new Date(e)).isValid()||l(e,n.defaultDateFormat).isValid(),i=l(e,this.dateFormat||n.defaultDateFormat,!0).isValid();if(this.allowEmpty&&""===e&&(r=!0,i=!0),r||(o=!1),!r&&i&&(o=!0),r&&!i)if(this.correctFormat===!0){var s=d(e,this.dateFormat),a=this.instance.runHooks("unmodifyRow",this.row),u=this.instance.runHooks("unmodifyCol",this.col);this.instance.setDataAtCell(a,u,s,"dateValidator"),o=!0}else o=!1;t(o)};var d=function(e,t){var o,n=l(u(e)),r=l(e,t),i=e.search(/[A-z]/g)>-1;return o=n.isValid()&&n.format("x")===r.format("x")||!r.isValid()||i?n:r,o.format(t)}},{"../helpers/date":46,browser:24,editors:30,moment:"moment"}],135:[function(e,t,o){"use strict";var n;((n=e("browser"))&&n.__esModule&&n||{default:n}).default.NumericValidator=function(e,t){null==e&&(e=""),t(!(!this.allowEmpty||""!==e)||""!==e&&/^-?\d*(\.|\,)?\d*$/.test(e))}},{browser:24}],136:[function(e,t,o){"use strict";var n,r,i=((n=e("browser"))&&n.__esModule&&n||{default:n}).default,s=((r=e("moment"))&&r.__esModule&&r||{default:r}).default,a=["YYYY-MM-DDTHH:mm:ss.SSSZ","X","x"];i.TimeValidator=function(e,t){var o=!0,n=this.timeFormat||"h:mm:ss a";null===e&&(e=""),e=/^\d{3,}$/.test(e)?parseInt(e,10):e;var r=/^\d{1,2}$/.test(e);r&&(e+=":00");var i=s(e,a,!0).isValid()?s(e):s(e,n),l=i.isValid(),u=s(e,n,!0).isValid()&&!r;if(this.allowEmpty&&""===e&&(l=!0,u=!0),l||(o=!1),!l&&u&&(o=!0),l&&!u)if(this.correctFormat===!0){var c=i.format(n),d=this.instance.runHooks("unmodifyRow",this.row),h=this.instance.runHooks("unmodifyCol",this.col);this.instance.setDataAtCell(d,h,c,"timeValidator"),o=!0}else o=!1;t(o)}},{browser:24,moment:"moment"}],SheetClip:[function(e,t,o){!function(e){"use strict";function t(e){return e.split('"').length-1}var n={parse:function(e){var o,n,r,i,s,a,l,u=[],c=0;for(r=e.split("\n"),r.length>1&&""===r[r.length-1]&&r.pop(),o=0,n=r.length;o<n;o+=1){for(r[o]=r[o].split("\t"),i=0,s=r[o].length;i<s;i+=1)u[c]||(u[c]=[]),a&&0===i?(l=u[c].length-1,u[c][l]=u[c][l]+"\n"+r[o][0],a&&1&t(r[o][0])&&(a=!1,u[c][l]=u[c][l].substring(0,u[c][l].length-1).replace(/""/g,'"'))):i===s-1&&0===r[o][i].indexOf('"')&&1&t(r[o][i])?(u[c].push(r[o][i].substring(1).replace(/""/g,'"')),a=!0):(u[c].push(r[o][i].replace(/""/g,'"')),a=!1);a||(c+=1)}return u},stringify:function(e){var t,o,n,r,i,s="";for(t=0,o=e.length;t<o;t+=1){for(r=e[t].length,n=0;n<r;n+=1)n>0&&(s+="\t"),i=e[t][n],s+="string"==typeof i?i.indexOf("\n")>-1?'"'+i.replace(/"/g,'""')+'"':i:null===i||void 0===i?"":i;s+="\n"}return s}};void 0!==o?(o.parse=n.parse,o.stringify=n.stringify):e.SheetClip=n}(window)},{}],autoResize:[function(e,t,o){function n(){function e(e){return e.currentStyle||document.defaultView.getComputedStyle(e)}var t,o={minHeight:200,maxHeight:300,minWidth:100,maxWidth:300},n=document.body,r=document.createTextNode(""),i=document.createElement("SPAN"),s=function(e,t,o){window.attachEvent?e.attachEvent("on"+t,o):e.addEventListener(t,o,!1)},a=function(e,t,o){window.removeEventListener?e.removeEventListener(t,o,!1):e.detachEvent("on"+t,o)},l=function(s){var a,l;s?/^[a-zA-Z \.,\\\/\|0-9]$/.test(s)||(s="."):s="",void 0!==r.textContent?r.textContent=t.value+s:r.data=t.value+s,i.style.fontSize=e(t).fontSize,i.style.fontFamily=e(t).fontFamily,i.style.whiteSpace="pre",n.appendChild(i),a=i.clientWidth+2,n.removeChild(i),t.style.height=o.minHeight+"px",o.minWidth>a?t.style.width=o.minWidth+"px":a>o.maxWidth?t.style.width=o.maxWidth+"px":t.style.width=a+"px",l=t.scrollHeight?t.scrollHeight-1:0,o.minHeight>l?t.style.height=o.minHeight+"px":o.maxHeight<l?(t.style.height=o.maxHeight+"px",t.style.overflowY="visible"):t.style.height=l+"px"},u=function(){window.setTimeout(l,0)},c=function(e){if(e&&e.minHeight)if("inherit"==e.minHeight)o.minHeight=t.clientHeight;else{var n=parseInt(e.minHeight);isNaN(n)||(o.minHeight=n)}if(e&&e.maxHeight)if("inherit"==e.maxHeight)o.maxHeight=t.clientHeight;else{var s=parseInt(e.maxHeight);isNaN(s)||(o.maxHeight=s)}if(e&&e.minWidth)if("inherit"==e.minWidth)o.minWidth=t.clientWidth;else{var a=parseInt(e.minWidth);isNaN(a)||(o.minWidth=a)}if(e&&e.maxWidth)if("inherit"==e.maxWidth)o.maxWidth=t.clientWidth;else{var l=parseInt(e.maxWidth);isNaN(l)||(o.maxWidth=l)}i.firstChild||(i.className="autoResize",i.style.display="inline-block",i.appendChild(r))},d=function(e,n,r){t=e,c(n),"TEXTAREA"==t.nodeName&&(t.style.resize="none",t.style.overflowY="",t.style.height=o.minHeight+"px",t.style.minWidth=o.minWidth+"px",t.style.maxWidth=o.maxWidth+"px",t.style.overflowY="hidden"),r&&(s(t,"change",l),s(t,"cut",u),s(t,"paste",u),s(t,"drop",u),s(t,"keydown",u),s(t,"focus",l)),l()};return{init:function(e,t,o){d(e,t,o)},unObserve:function(){a(t,"change",l),a(t,"cut",u),a(t,"paste",u),a(t,"drop",u),a(t,"keydown",u),a(t,"focus",l)},resize:l}}void 0!==o&&(t.exports=n)},{}],copyPaste:[function(e,t,o){function n(){return i?i.hasBeenDestroyed()&&i.init():i=new r,i.refCounter++,i}function r(){this.refCounter=0,this.init()}var i;void 0!==o&&(t.exports=n),r.prototype.init=function(){var e,t;this.copyCallbacks=[],this.cutCallbacks=[],this.pasteCallbacks=[],t=document.body,document.getElementById("CopyPasteDiv")?(this.elDiv=document.getElementById("CopyPasteDiv"),this.elTextarea=this.elDiv.firstChild):(this.elDiv=document.createElement("div"),this.elDiv.id="CopyPasteDiv",e=this.elDiv.style,e.position="fixed",e.top="-10000px",e.left="-10000px",t.appendChild(this.elDiv),this.elTextarea=document.createElement("textarea"),this.elTextarea.className="copyPaste",this.elTextarea.onpaste=function(e){var t,o;"WebkitAppearance"in document.documentElement.style&&(t=e.clipboardData.getData("Text"),navigator.userAgent.indexOf("Safari")!==-1&&navigator.userAgent.indexOf("Chrome")===-1&&(o=t.split("\n"),""===o[o.length-1]&&o.pop(),t=o.join("\n")),this.value=t,e.preventDefault())},e=this.elTextarea.style,e.width="10000px",e.height="10000px",e.overflow="hidden",this.elDiv.appendChild(this.elTextarea),void 0!==e.opacity&&(e.opacity=0)),this.onKeyDownRef=this.onKeyDown.bind(this),document.documentElement.addEventListener("keydown",this.onKeyDownRef,!1)},r.prototype.onKeyDown=function(e){var t=this,o=!1;if(e.metaKey?o=!0:e.ctrlKey&&navigator.userAgent.indexOf("Mac")===-1&&(o=!0),o){if(document.activeElement!==this.elTextarea&&(""!==this.getSelectionText()||function(){var e=document.activeElement;return e.shadowRoot&&e.shadowRoot.activeElement&&(e=e.shadowRoot.activeElement),["INPUT","SELECT","TEXTAREA"].indexOf(e.nodeName)>-1||"true"===e.contentEditable}()))return;this.selectNodeText(this.elTextarea),setTimeout(function(){document.activeElement!==t.elTextarea&&t.selectNodeText(t.elTextarea)},0)}e.isImmediatePropagationEnabled===!1||!o||67!==e.keyCode&&86!==e.keyCode&&88!==e.keyCode||(88===e.keyCode?setTimeout(function(){t.triggerCut(e)},0):86===e.keyCode&&setTimeout(function(){t.triggerPaste(e)},0))},r.prototype.selectNodeText=function(e){e&&e.select()},r.prototype.getSelectionText=function(){var e="";return window.getSelection?e=window.getSelection().toString():document.selection&&"Control"!==document.selection.type&&(e=document.selection.createRange().text),e},r.prototype.copyable=function(e){if("string"!=typeof e&&void 0===e.toString)throw new Error("copyable requires string parameter");this.elTextarea.value=e,this.selectNodeText(this.elTextarea)},r.prototype.onCut=function(e){this.cutCallbacks.push(e)},r.prototype.onPaste=function(e){this.pasteCallbacks.push(e)},r.prototype.removeCallback=function(e){var t,o;for(t=0,o=this.copyCallbacks.length;t<o;t++)if(this.copyCallbacks[t]===e)return this.copyCallbacks.splice(t,1),!0;for(t=0,o=this.cutCallbacks.length;t<o;t++)if(this.cutCallbacks[t]===e)return this.cutCallbacks.splice(t,1),!0;for(t=0,o=this.pasteCallbacks.length;t<o;t++)if(this.pasteCallbacks[t]===e)return this.pasteCallbacks.splice(t,1),!0;return!1},r.prototype.triggerCut=function(e){var t=this;t.cutCallbacks&&setTimeout(function(){for(var o=0,n=t.cutCallbacks.length;o<n;o++)t.cutCallbacks[o](e)},50)},r.prototype.triggerPaste=function(e,t){var o=this;o.pasteCallbacks&&setTimeout(function(){for(var n=t||o.elTextarea.value,r=0,i=o.pasteCallbacks.length;r<i;r++)o.pasteCallbacks[r](n,e)},50)},r.prototype.destroy=function(){this.hasBeenDestroyed()||0!=--this.refCounter||(this.elDiv&&this.elDiv.parentNode&&(this.elDiv.parentNode.removeChild(this.elDiv),this.elDiv=null,this.elTextarea=null),document.documentElement.removeEventListener("keydown",this.onKeyDownRef),this.onKeyDownRef=null)},r.prototype.hasBeenDestroyed=function(){return!this.refCounter}},{}],es6collections:[function(e,t,o){/*!
42
- * Copyright (C) 2011 by Andrea Giammarchi, @WebReflection
43
- *
44
- * Permission is hereby granted, free of charge, to any person obtaining a copy
45
- * of this software and associated documentation files (the "Software"), to deal
46
- * in the Software without restriction, including without limitation the rights
47
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
48
- * copies of the Software, and to permit persons to whom the Software is
49
- * furnished to do so, subject to the following conditions:
50
- *
51
- * The above copyright notice and this permission notice shall be included in
52
- * all copies or substantial portions of the Software.
1
  /*!
2
+ * Copyright (c) HANDSONCODE sp. z o. o.
3
+ *
4
+ * HANDSONTABLE is a software distributed by HANDSONCODE sp. z o. o.,
5
+ * a Polish corporation, based in Gdynia, Poland, at 96/98 Aleja Zwycięstwa,
6
+ * registered with the National Court Register under number 538651,
7
+ * EU tax ID number: PL5862294002, share capital: PLN 62,800.00.
8
+ *
9
+ * This software is protected by applicable copyright laws, including
10
+ * international treaties, and dual-licensed depending on whether
11
+ * your use is intended for or may result in commercial advantage
12
+ * or monetary compensation (commercial purposes), or not.
13
+ *
14
+ * If your use involves only such purposes as research, private study,
15
+ * evaluation and the like, you agree to be bound by the terms included
16
+ * in the “handsontable-non-commercial-license.pdf” file, available
17
+ * in the main directory of this software repository.
18
+ *
19
+ * By installing, copying, or otherwise using this software for
20
+ * commercial purposes, you agree to be bound by the terms included
21
+ * in the “handsontable-general-terms.pdf” file, available in the main
22
+ * directory of this software repository.
23
+ *
24
+ * HANDSONCODE PROVIDES THIS SOFTWARE ON AN “AS IS” BASIS,
25
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND. IN NO EVENT
26
+ * AND UNDER NO LEGAL THEORY, SHALL HANDSONCODE BE LIABLE
27
+ * TO YOU FOR DAMAGES, INCLUDING ANY DIRECT, INDIRECT, SPECIAL,
28
+ * INCIDENTAL, OR CONSEQUENTIAL DAMAGES OF ANY CHARACTER ARISING
29
+ * FROM USE OR INABILITY TO USE THIS SOFTWARE.
30
+ *
31
+ * Version: 7.0.2
32
+ * Release date: 09/04/2019 (built at 09/04/2019 12:57:40)
33
+ */
34
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("Handsontable",[],t):"object"==typeof exports?exports.Handsontable=t():e.Handsontable=t()}("undefined"!=typeof self?self:this,function(){return function(n){var r={};function o(e){if(r[e])return r[e].exports;var t=r[e]={i:e,l:!1,exports:{}};return n[e].call(t.exports,t,t.exports,o),t.l=!0,t.exports}return o.m=n,o.c=r,o.d=function(e,t,n){o.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},o.t=function(t,e){if(1&e&&(t=o(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(o.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var r in t)o.d(n,r,function(e){return t[e]}.bind(null,r));return n},o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,"a",t),t},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.p="",o(o.s=505)}([function(e,t){e.exports=function(e){return e&&e.__esModule?e:{default:e}}},function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}},function(e,t){function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e.exports=function(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}},function(e,t,n){"use strict";function r(e,t,n,r){var o=-1,i=e,a=n;Array.isArray(e)||(i=Array.from(e));var s=i.length;for(r&&s&&(a=i[o+=1]),o+=1;o<s;)a=t(a,i[o],o,i),o+=1;return a}function o(e,t){var n=0,r=e;Array.isArray(e)||(r=Array.from(e));for(var o=r.length;n<o&&!1!==t(r[n],n,r);)n+=1;return e}function i(e){return r(e,function(e,t){return e+t},0)}n(18),n(59),n(12),n(14),t.__esModule=!0,t.to2dArray=function(e){var t=e.length,n=0;for(;n<t;)e[n]=[e[n]],n+=1},t.extendArray=function(e,t){var n=t.length,r=0;for(;r<n;)e.push(t[r]),r+=1},t.pivot=function(e){var t=[];if(!e||0===e.length||!e[0]||0===e[0].length)return t;for(var n=e.length,r=e[0].length,o=0;o<n;o++)for(var i=0;i<r;i++)t[i]||(t[i]=[]),t[i][o]=e[o][i];return t},t.arrayReduce=r,t.arrayFilter=function(e,t){var n=0,r=e;Array.isArray(e)||(r=Array.from(e));var o=r.length,i=[],a=-1;for(;n<o;){var s=r[n];t(s,n,r)&&(i[a+=1]=s),n+=1}return i},t.arrayMap=function(e,t){var n=0,r=e;Array.isArray(e)||(r=Array.from(e));var o=r.length,i=[],a=-1;for(;n<o;){var s=r[n];i[a+=1]=t(s,n,r),n+=1}return i},t.arrayEach=o,t.arraySum=i,t.arrayMax=function(e){return r(e,function(e,t){return t<e?e:t},Array.isArray(e)?e[0]:void 0)},t.arrayMin=function(e){return r(e,function(e,t){return e<t?e:t},Array.isArray(e)?e[0]:void 0)},t.arrayAvg=function(e){return e.length?i(e)/e.length:0},t.arrayFlatten=function n(e){return r(e,function(e,t){return e.concat(Array.isArray(t)?n(t):t)},[])},t.arrayUnique=function(e){var t=[];return o(e,function(e){-1===t.indexOf(e)&&t.push(e)}),t}},function(e,t,n){"use strict";var r=n(0);n(10),n(36),n(46),t.__esModule=!0,t.duckSchema=function n(e){var r;Array.isArray(e)?r=[]:(r={},c(e,function(e,t){"__children"!==t&&(e&&"object"===(0,a.default)(e)&&!Array.isArray(e)?r[t]=n(e):Array.isArray(e)?e.length&&"object"===(0,a.default)(e[0])&&!Array.isArray(e[0])?r[t]=[n(e[0])]:r[t]=[]:r[t]=null)}));return r},t.inherit=function(e,t){return t.prototype.constructor=t,e.prototype=new t,e.prototype.constructor=e},t.extend=function(n,e){return c(e,function(e,t){n[t]=e}),n},t.deepExtend=function n(r,o){c(o,function(e,t){o[t]&&"object"===(0,a.default)(o[t])?(r[t]||(Array.isArray(o[t])?r[t]=[]:"[object Date]"===Object.prototype.toString.call(o[t])?r[t]=o[t]:r[t]={}),n(r[t],o[t])):r[t]=o[t]})},t.deepClone=l,t.clone=function(e){var n={};return c(e,function(e,t){n[t]=e}),n},t.mixin=function(s){s.MIXINS||(s.MIXINS=[]);for(var e=arguments.length,t=new Array(1<e?e-1:0),n=1;n<e;n++)t[n-1]=arguments[n];return(0,o.arrayEach)(t,function(e){s.MIXINS.push(e.MIXIN_NAME),c(e,function(e,t){if(void 0!==s.prototype[t])throw new Error("Mixin conflict. Property '".concat(t,"' already exist and cannot be overwritten."));var n,r,o,i,a;"function"==typeof e?s.prototype[t]=e:Object.defineProperty(s.prototype,t,{get:(o=t,i=e,a="_".concat(o),function(){return void 0===this[a]&&(this[a]=function(e){var t=e;return(Array.isArray(t)||u(t))&&(t=l(t)),t}(i)),this[a]}),set:(n=t,r="_".concat(n),function(e){this[r]=e}),configurable:!0})})}),s},t.isObjectEqual=function(e,t){return JSON.stringify(e)===JSON.stringify(t)},t.isObject=u,t.defineGetter=function(e,t,n,r){r.value=n,r.writable=!1!==r.writable,r.enumerable=!1!==r.enumerable,r.configurable=!1!==r.configurable,Object.defineProperty(e,t,r)},t.objectEach=c,t.getProperty=function(e,t){var n=t.split("."),r=e;return c(n,function(e){if(void 0===(r=r[e]))return r=void 0,!1}),r},t.deepObjectSize=function(e){return u(e)?function t(e){var n=0;return u(e)?c(e,function(e){n+=t(e)}):n+=1,n}(e):0},t.createObjectPropListener=function(e){var t,n=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"value",r="_".concat(n),o=(t={_touched:!1},(0,i.default)(t,r,e),(0,i.default)(t,"isTouched",function(){return this._touched}),t);return Object.defineProperty(o,n,{get:function(){return this[r]},set:function(e){this._touched=!0,this[r]=e},enumerable:!0,configurable:!0}),o},t.hasOwnProperty=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)};var i=r(n(71)),a=r(n(44)),o=n(3);function l(e){return"object"===(0,a.default)(e)?JSON.parse(JSON.stringify(e)):e}function u(e){return"[object Object]"===Object.prototype.toString.call(e)}function c(e,t){for(var n in e)if((!e.hasOwnProperty||e.hasOwnProperty&&Object.prototype.hasOwnProperty.call(e,n))&&!1===t(e[n],n,e))break;return e}},function(e,t,n){"use strict";var r=n(0);n(18),n(34),n(12),n(54),n(40),n(10),n(130),n(36),n(39),n(37),n(46),n(105),t.__esModule=!0,t.getParent=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0,n=-1,r=null,o=e;for(;null!==o;){if(n===t){r=o;break}o=o.host&&o.nodeType===Node.DOCUMENT_FRAGMENT_NODE?o.host:(n+=1,o.parentNode)}return r},t.closest=u,t.closestDown=function(e,t,n){var r=[],o=e;for(;o&&(o=u(o,t,n))&&(!n||n.contains(o));)r.push(o),o=o.host&&o.nodeType===Node.DOCUMENT_FRAGMENT_NODE?o.host:o.parentNode;var i=r.length;return i?r[i-1]:null},t.isChildOf=function(e,t){var n=e.parentNode,r=[];"string"==typeof t?r=Array.prototype.slice.call(e.ownerDocument.querySelectorAll(t),0):r.push(t);for(;null!==n;){if(-1<r.indexOf(n))return!0;n=n.parentNode}return!1},t.isChildOfWebComponentTable=function(e){var t="hot-table",n=!1,r=c(e);function o(e){return e.nodeType===Node.ELEMENT_NODE&&e.nodeName===t.toUpperCase()}for(;null!==r;){if(o(r)){n=!0;break}if(r.host&&r.nodeType===Node.DOCUMENT_FRAGMENT_NODE){if(n=o(r.host))break;r=r.host}r=r.parentNode}return n},t.polymerWrap=c,t.polymerUnwrap=d,t.index=function(e){var t=0,n=e;if(n.previousSibling)for(;n=n.previousSibling;)t+=1;return t},t.overlayContainsElement=function(e,t){var n=t.ownerDocument.querySelector(".ht_clone_".concat(e));return n?n.contains(t):null},t.hasClass=function(e,t){return o(e,t)},t.addClass=function(e,t){return i(e,t)},t.removeClass=function(e,t){return a(e,t)},t.removeTextNodes=function e(t,n){if(3===t.nodeType)n.removeChild(t);else if(-1<["TABLE","THEAD","TBODY","TFOOT","TR"].indexOf(t.nodeName))for(var r=t.childNodes,o=r.length-1;0<=o;o--)e(r[o],t)},t.empty=p,t.fastInnerHTML=function(e,t){y.test(t)?e.innerHTML=t:w(e,t)},t.fastInnerText=w,t.isVisible=function e(t){var n=t.ownerDocument.documentElement;var r=t;for(;d(r)!==n;){if(null===r)return!1;if(r.nodeType===Node.DOCUMENT_FRAGMENT_NODE){if(r.host){if(r.host.impl)return e(r.host.impl);if(r.host)return e(r.host);throw new Error("Lost in Web Components world")}return!1}if(r.style&&"none"===r.style.display)return!1;r=r.parentNode}return!0},t.offset=function(e){var t,n,r,o,i=e.ownerDocument,a=i.defaultView,s=i.documentElement,l=e;if((0,h.hasCaptionProblem)()&&l.firstChild&&"CAPTION"===l.firstChild.nodeName)return{top:(o=l.getBoundingClientRect()).top+(a.pageYOffset||s.scrollTop)-(s.clientTop||0),left:o.left+(a.pageXOffset||s.scrollLeft)-(s.clientLeft||0)};t=l.offsetLeft,n=l.offsetTop,r=l;for(;(l=l.offsetParent)&&l!==i.body;)t+=l.offsetLeft,n+=l.offsetTop,r=l;r&&"fixed"===r.style.position&&(t+=a.pageXOffset||s.scrollLeft,n+=a.pageYOffset||s.scrollTop);return{left:t,top:n}},t.getWindowScrollTop=C,t.getWindowScrollLeft=E,t.getScrollTop=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:window;return e!==t?e.scrollTop:C(t)},t.getScrollLeft=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:window;return e!==t?e.scrollLeft:E(t)},t.getScrollableElement=function(e){var t=e.ownerDocument,n=t?t.defaultView:void 0;t||(t=e.document?e.document:e,n=t.defaultView);var r=["auto","scroll"],o=(0,h.isGetComputedStyleSupported)(),i=e.parentNode;for(;i&&i.style&&t.body!==i;){var a=i.style,s=a.overflow,l=a.overflowX,u=a.overflowY;if([s,l,u].includes("scroll"))return i;if(o){var c=n.getComputedStyle(i);if(s=c.overflow,l=c.overflowX,u=c.overflowY,r.includes(s)||r.includes(l)||r.includes(u))return i}if(i.clientHeight<=i.scrollHeight+1&&(r.includes(u)||r.includes(s)))return i;if(i.clientWidth<=i.scrollWidth+1&&(r.includes(l)||r.includes(s)))return i;i=i.parentNode}return n},t.getTrimmingContainer=function(e){var t=e.ownerDocument,n=t.defaultView,r=e.parentNode;for(;r&&r.style&&t.body!==r;){if("visible"!==r.style.overflow&&""!==r.style.overflow)return r;var o=S(r,n),i=["scroll","hidden","auto"],a=o.getPropertyValue("overflow"),s=o.getPropertyValue("overflow-y"),l=o.getPropertyValue("overflow-x");if(i.includes(a)||i.includes(s)||i.includes(l))return r;r=r.parentNode}return n},t.getStyle=function(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:window;{if(!e)return;if(e===n)return"width"===t?"".concat(n.innerWidth,"px"):"height"===t?"".concat(n.innerHeight,"px"):void 0}var r=e.style[t];if(""!==r&&void 0!==r)return r;var o=S(e,n);if(""!==o[t]&&void 0!==o[t])return o[t]},t.getComputedStyle=S,t.outerWidth=function(e){return e.offsetWidth},t.outerHeight=function(e){if((0,h.hasCaptionProblem)()&&e.firstChild&&"CAPTION"===e.firstChild.nodeName)return e.offsetHeight+e.firstChild.offsetHeight;return e.offsetHeight},t.innerHeight=function(e){return e.clientHeight||e.innerHeight},t.innerWidth=function(e){return e.clientWidth||e.innerWidth},t.addEvent=function(e,t,n){var r=e.defaultView;r||(r=e.document?e:e.ownerDocument.defaultView);r.addEventListener?e.addEventListener(t,n,!1):e.attachEvent("on".concat(t),n)},t.removeEvent=function(e,t,n){var r=e.defaultView;r||(r=e.document?e:e.ownerDocument.defaultView);r.removeEventListener?e.removeEventListener(t,n,!1):e.detachEvent("on".concat(t),n)},t.getCaretPosition=function(e){var t=e.ownerDocument;{if(e.selectionStart)return e.selectionStart;if(t.selection){e.focus();var n=t.selection.createRange();if(null===n)return 0;var r=e.createTextRange(),o=r.duplicate();return r.moveToBookmark(n.getBookmark()),o.setEndPoint("EndToStart",r),o.text.length}}return 0},t.getSelectionEndPosition=function(e){var t=e.ownerDocument;{if(e.selectionEnd)return e.selectionEnd;if(t.selection){var n=t.selection.createRange();if(null===n)return 0;var r=e.createTextRange();return r.text.indexOf(n.text)+n.text.length}}return 0},t.getSelectionText=function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:window,t=e.document,n="";e.getSelection?n=e.getSelection().toString():t.selection&&"Control"!==t.selection.type&&(n=t.selection.createRange().text);return n},t.clearTextSelection=function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:window,t=e.document;e.getSelection?e.getSelection().empty?e.getSelection().empty():e.getSelection().removeAllRanges&&e.getSelection().removeAllRanges():t.selection&&t.selection.empty()},t.setCaretPosition=function(t,n,r){void 0===r&&(r=n);if(t.setSelectionRange){t.focus();try{t.setSelectionRange(n,r)}catch(e){var o=t.parentNode,i=o.style.display;o.style.display="block",t.setSelectionRange(n,r),o.style.display=i}}else if(t.createTextRange){var e=t.createTextRange();e.collapse(!0),e.moveEnd("character",r),e.moveStart("character",n),e.select()}},t.getScrollbarWidth=function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:document;void 0===m&&(m=function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:document,t=e.createElement("div");t.style.height="200px",t.style.width="100%";var n=e.createElement("div");n.style.boxSizing="content-box",n.style.height="150px",n.style.left="0px",n.style.overflow="hidden",n.style.position="absolute",n.style.top="0px",n.style.width="200px",n.style.visibility="hidden",n.appendChild(t),(e.body||e.documentElement).appendChild(n);var r=t.offsetWidth;n.style.overflow="scroll";var o=t.offsetWidth;r===o&&(o=n.clientWidth);return(e.body||e.documentElement).removeChild(n),r-o}(e));return m},t.hasVerticalScrollbar=function(e){return e.offsetWidth!==e.clientWidth},t.hasHorizontalScrollbar=function(e){return e.offsetHeight!==e.clientHeight},t.setOverlayPosition=function(e,t,n){(0,l.isIE8)()||(0,l.isIE9)()?(e.style.top=n,e.style.left=t):(0,l.isSafari)()?(e.style["-webkit-transform"]="translate3d(".concat(t,",").concat(n,",0)"),e.style["-webkit-transform"]="translate3d(".concat(t,",").concat(n,",0)")):e.style.transform="translate3d(".concat(t,",").concat(n,",0)")},t.getCssTransform=function(e){var t;{if(e.style.transform&&""!==(t=e.style.transform))return["transform",t];if(e.style["-webkit-transform"]&&""!==(t=e.style["-webkit-transform"]))return["-webkit-transform",t]}return-1},t.resetCssTransform=function(e){e.style.transform&&""!==e.style.transform?e.style.transform="":e.style["-webkit-transform"]&&""!==e.style["-webkit-transform"]&&(e.style["-webkit-transform"]="")},t.isInput=b,t.isOutsideInput=T,t.selectElementIfAllowed=function(e){T(e.ownerDocument.activeElement)||e.select()},t.HTML_CHARACTERS=void 0;var o,i,a,s=r(n(38)),l=n(72),h=n(73);function u(e,t,n){for(var r=e;null!==r&&r!==n;){if(r.nodeType===Node.ELEMENT_NODE&&(-1<t.indexOf(r.nodeName)||-1<t.indexOf(r)))return r;r=r.host&&r.nodeType===Node.DOCUMENT_FRAGMENT_NODE?r.host:r.parentNode}return null}function c(e){return"undefined"!=typeof Polymer&&"function"==typeof wrap?wrap(e):e}function d(e){return"undefined"!=typeof Polymer&&"function"==typeof unwrap?unwrap(e):e}function f(e){var t=[];if(!e||!e.length)return t;for(var n=0;e[n];)t.push(e[n]),n+=1;return t}if((0,h.isClassListSupported)()){var g=function(e){var t=e.createElement("div");return t.classList.add("test","test2"),t.classList.contains("test2")};o=function(e,t){return void 0!==e.classList&&"string"==typeof t&&""!==t&&e.classList.contains(t)},i=function(e,t){var n,r=e.ownerDocument,o=t;if("string"==typeof o&&(o=o.split(" ")),0<(o=f(o)).length)if(g(r))(n=e.classList).add.apply(n,(0,s.default)(o));else for(var i=0;o&&o[i];)e.classList.add(o[i]),i+=1},a=function(e,t){var n,r=t;("string"==typeof r&&(r=r.split(" ")),0<(r=f(r)).length)&&(n=e.classList).remove.apply(n,(0,s.default)(r))}}else{var v=function(e){return new RegExp("(\\s|^)".concat(e,"(\\s|$)"))};o=function(e,t){return void 0!==e.className&&v(t).test(e.className)},i=function(e,t){var n=0,r=e.className,o=t;if("string"==typeof o&&(o=o.split(" ")),""===r)r=o.join(" ");else for(;o&&o[n];)v(o[n]).test(r)||(r+=" ".concat(o[n])),n+=1;e.className=r},a=function(e,t){var n=0,r=e.className,o=t;for("string"==typeof o&&(o=o.split(" "));o&&o[n];)r=r.replace(v(o[n])," ").trim(),n+=1;e.className!==r&&(e.className=r)}}function p(e){for(var t;t=e.lastChild;)e.removeChild(t)}var m,y=/(<(.*)>|&(.*);)/;function w(e,t){var n=e.firstChild;n&&3===n.nodeType&&null===n.nextSibling?h.isTextContentSupported?n.textContent=t:n.data=t:(p(e),e.appendChild(e.ownerDocument.createTextNode(t)))}function C(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:window,t=e.scrollY;return void 0===t&&(t=e.document.documentElement.scrollTop),t}function E(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:window,t=e.scrollX;return void 0===t&&(t=e.document.documentElement.scrollLeft),t}function S(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:window;return e.currentStyle||t.getComputedStyle(e)}function b(e){return e&&(-1<["INPUT","SELECT","TEXTAREA"].indexOf(e.nodeName)||"true"===e.contentEditable)}function T(e){return b(e)&&-1===e.className.indexOf("handsontableInput")&&-1===e.className.indexOf("copyPaste")}t.HTML_CHARACTERS=y},function(t,e){function n(e){return t.exports=n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},n(e)}t.exports=n},function(e,t,n){var r=n(44),o=n(26);e.exports=function(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?o(e):t}},function(e,t,n){var r=n(522);e.exports=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&r(e,t)}},function(e,t){e.exports=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var r=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,n):{};r.get||r.set?Object.defineProperty(t,n,r):t[n]=e[n]}return t.default=e,t}},function(e,t,n){var r=n(514),o=Object.prototype;r!==o.toString&&n(65)(o,"toString",r,{unsafe:!0})},function(e,t,n){"use strict";t.__esModule=!0,t.FILTERS_BUTTONS_PLACEHOLDER_SECOND_VALUE=t.FILTERS_BUTTONS_PLACEHOLDER_VALUE=t.FILTERS_BUTTONS_PLACEHOLDER_SEARCH=t.FILTERS_BUTTONS_CANCEL=t.FILTERS_BUTTONS_OK=t.FILTERS_BUTTONS_CLEAR=t.FILTERS_BUTTONS_SELECT_ALL=t.FILTERS_VALUES_BLANK_CELLS=t.FILTERS_LABELS_DISJUNCTION=t.FILTERS_LABELS_CONJUNCTION=t.FILTERS_DIVS_FILTER_BY_VALUE=t.FILTERS_DIVS_FILTER_BY_CONDITION=t.FILTERS_CONDITIONS_YESTERDAY=t.FILTERS_CONDITIONS_TOMORROW=t.FILTERS_CONDITIONS_TODAY=t.FILTERS_CONDITIONS_BEFORE=t.FILTERS_CONDITIONS_AFTER=t.FILTERS_CONDITIONS_NOT_BETWEEN=t.FILTERS_CONDITIONS_BETWEEN=t.FILTERS_CONDITIONS_LESS_THAN_OR_EQUAL=t.FILTERS_CONDITIONS_LESS_THAN=t.FILTERS_CONDITIONS_GREATER_THAN_OR_EQUAL=t.FILTERS_CONDITIONS_GREATER_THAN=t.FILTERS_CONDITIONS_BY_VALUE=t.FILTERS_CONDITIONS_NOT_CONTAIN=t.FILTERS_CONDITIONS_CONTAINS=t.FILTERS_CONDITIONS_ENDS_WITH=t.FILTERS_CONDITIONS_BEGINS_WITH=t.FILTERS_CONDITIONS_NOT_EQUAL=t.FILTERS_CONDITIONS_EQUAL=t.FILTERS_CONDITIONS_NOT_EMPTY=t.FILTERS_CONDITIONS_EMPTY=t.FILTERS_CONDITIONS_NONE=t.FILTERS_CONDITIONS_NAMESPACE=t.FILTERS_NAMESPACE=t.CONTEXTMENU_ITEMS_SHOW_ROW=t.CONTEXTMENU_ITEMS_HIDE_ROW=t.CONTEXTMENU_ITEMS_SHOW_COLUMN=t.CONTEXTMENU_ITEMS_HIDE_COLUMN=t.CONTEXTMENU_ITEMS_NESTED_ROWS_DETACH_CHILD=t.CONTEXTMENU_ITEMS_NESTED_ROWS_INSERT_CHILD=t.CONTEXTMENU_ITEMS_REMOVE_BORDERS=t.CONTEXTMENU_ITEMS_BORDERS_LEFT=t.CONTEXTMENU_ITEMS_BORDERS_BOTTOM=t.CONTEXTMENU_ITEMS_BORDERS_RIGHT=t.CONTEXTMENU_ITEMS_BORDERS_TOP=t.CONTEXTMENU_ITEMS_BORDERS=t.CONTEXTMENU_ITEMS_ALIGNMENT_BOTTOM=t.CONTEXTMENU_ITEMS_ALIGNMENT_MIDDLE=t.CONTEXTMENU_ITEMS_ALIGNMENT_TOP=t.CONTEXTMENU_ITEMS_ALIGNMENT_JUSTIFY=t.CONTEXTMENU_ITEMS_ALIGNMENT_RIGHT=t.CONTEXTMENU_ITEMS_ALIGNMENT_CENTER=t.CONTEXTMENU_ITEMS_ALIGNMENT_LEFT=t.CONTEXTMENU_ITEMS_ALIGNMENT=t.CONTEXTMENU_ITEMS_READ_ONLY_COMMENT=t.CONTEXTMENU_ITEMS_REMOVE_COMMENT=t.CONTEXTMENU_ITEMS_EDIT_COMMENT=t.CONTEXTMENU_ITEMS_ADD_COMMENT=t.CONTEXTMENU_ITEMS_UNMERGE_CELLS=t.CONTEXTMENU_ITEMS_MERGE_CELLS=t.CONTEXTMENU_ITEMS_UNFREEZE_COLUMN=t.CONTEXTMENU_ITEMS_FREEZE_COLUMN=t.CONTEXTMENU_ITEMS_CUT=t.CONTEXTMENU_ITEMS_COPY=t.CONTEXTMENU_ITEMS_CLEAR_COLUMN=t.CONTEXTMENU_ITEMS_READ_ONLY=t.CONTEXTMENU_ITEMS_REDO=t.CONTEXTMENU_ITEMS_UNDO=t.CONTEXTMENU_ITEMS_REMOVE_COLUMN=t.CONTEXTMENU_ITEMS_REMOVE_ROW=t.CONTEXTMENU_ITEMS_INSERT_RIGHT=t.CONTEXTMENU_ITEMS_INSERT_LEFT=t.CONTEXTMENU_ITEMS_ROW_BELOW=t.CONTEXTMENU_ITEMS_ROW_ABOVE=t.CONTEXTMENU_ITEMS_NO_ITEMS=t.CONTEXT_MENU_ITEMS_NAMESPACE=void 0;var r="ContextMenu:items";t.CONTEXT_MENU_ITEMS_NAMESPACE=r;var o="".concat(r,".noItems");t.CONTEXTMENU_ITEMS_NO_ITEMS=o;var i="".concat(r,".insertRowAbove");t.CONTEXTMENU_ITEMS_ROW_ABOVE=i;var a="".concat(r,".insertRowBelow");t.CONTEXTMENU_ITEMS_ROW_BELOW=a;var s="".concat(r,".insertColumnOnTheLeft");t.CONTEXTMENU_ITEMS_INSERT_LEFT=s;var l="".concat(r,".insertColumnOnTheRight");t.CONTEXTMENU_ITEMS_INSERT_RIGHT=l;var u="".concat(r,".removeRow");t.CONTEXTMENU_ITEMS_REMOVE_ROW=u;var c="".concat(r,".removeColumn");t.CONTEXTMENU_ITEMS_REMOVE_COLUMN=c;var h="".concat(r,".undo");t.CONTEXTMENU_ITEMS_UNDO=h;var d="".concat(r,".redo");t.CONTEXTMENU_ITEMS_REDO=d;var f="".concat(r,".readOnly");t.CONTEXTMENU_ITEMS_READ_ONLY=f;var g="".concat(r,".clearColumn");t.CONTEXTMENU_ITEMS_CLEAR_COLUMN=g;var v="".concat(r,".copy");t.CONTEXTMENU_ITEMS_COPY=v;var p="".concat(r,".cut");t.CONTEXTMENU_ITEMS_CUT=p;var m="".concat(r,".freezeColumn");t.CONTEXTMENU_ITEMS_FREEZE_COLUMN=m;var y="".concat(r,".unfreezeColumn");t.CONTEXTMENU_ITEMS_UNFREEZE_COLUMN=y;var w="".concat(r,".mergeCells");t.CONTEXTMENU_ITEMS_MERGE_CELLS=w;var C="".concat(r,".unmergeCells");t.CONTEXTMENU_ITEMS_UNMERGE_CELLS=C;var E="".concat(r,".addComment");t.CONTEXTMENU_ITEMS_ADD_COMMENT=E;var S="".concat(r,".editComment");t.CONTEXTMENU_ITEMS_EDIT_COMMENT=S;var b="".concat(r,".removeComment");t.CONTEXTMENU_ITEMS_REMOVE_COMMENT=b;var T="".concat(r,".readOnlyComment");t.CONTEXTMENU_ITEMS_READ_ONLY_COMMENT=T;var R="".concat(r,".align");t.CONTEXTMENU_ITEMS_ALIGNMENT=R;var _="".concat(r,".align.left");t.CONTEXTMENU_ITEMS_ALIGNMENT_LEFT=_;var k="".concat(r,".align.center");t.CONTEXTMENU_ITEMS_ALIGNMENT_CENTER=k;var O="".concat(r,".align.right");t.CONTEXTMENU_ITEMS_ALIGNMENT_RIGHT=O;var M="".concat(r,".align.justify");t.CONTEXTMENU_ITEMS_ALIGNMENT_JUSTIFY=M;var N="".concat(r,".align.top");t.CONTEXTMENU_ITEMS_ALIGNMENT_TOP=N;var A="".concat(r,".align.middle");t.CONTEXTMENU_ITEMS_ALIGNMENT_MIDDLE=A;var I="".concat(r,".align.bottom");t.CONTEXTMENU_ITEMS_ALIGNMENT_BOTTOM=I;var D="".concat(r,".borders");t.CONTEXTMENU_ITEMS_BORDERS=D;var x="".concat(r,".borders.top");t.CONTEXTMENU_ITEMS_BORDERS_TOP=x;var L="".concat(r,".borders.right");t.CONTEXTMENU_ITEMS_BORDERS_RIGHT=L;var H="".concat(r,".borders.bottom");t.CONTEXTMENU_ITEMS_BORDERS_BOTTOM=H;var P="".concat(r,".borders.left");t.CONTEXTMENU_ITEMS_BORDERS_LEFT=P;var F="".concat(r,".borders.remove");t.CONTEXTMENU_ITEMS_REMOVE_BORDERS=F;var V="".concat(r,".nestedHeaders.insertChildRow");t.CONTEXTMENU_ITEMS_NESTED_ROWS_INSERT_CHILD=V;var B="".concat(r,".nestedHeaders.detachFromParent");t.CONTEXTMENU_ITEMS_NESTED_ROWS_DETACH_CHILD=B;var W="".concat(r,".hideColumn");t.CONTEXTMENU_ITEMS_HIDE_COLUMN=W;var U="".concat(r,".showColumn");t.CONTEXTMENU_ITEMS_SHOW_COLUMN=U;var j="".concat(r,".hideRow");t.CONTEXTMENU_ITEMS_HIDE_ROW=j;var Y="".concat(r,".showRow");t.CONTEXTMENU_ITEMS_SHOW_ROW=Y;var $="Filters:";t.FILTERS_NAMESPACE=$;var G="".concat($,"conditions");t.FILTERS_CONDITIONS_NAMESPACE=G;var z="".concat(G,".none");t.FILTERS_CONDITIONS_NONE=z;var X="".concat(G,".isEmpty");t.FILTERS_CONDITIONS_EMPTY=X;var K="".concat(G,".isNotEmpty");t.FILTERS_CONDITIONS_NOT_EMPTY=K;var q="".concat(G,".isEqualTo");t.FILTERS_CONDITIONS_EQUAL=q;var Z="".concat(G,".isNotEqualTo");t.FILTERS_CONDITIONS_NOT_EQUAL=Z;var Q="".concat(G,".beginsWith");t.FILTERS_CONDITIONS_BEGINS_WITH=Q;var J="".concat(G,".endsWith");t.FILTERS_CONDITIONS_ENDS_WITH=J;var ee="".concat(G,".contains");t.FILTERS_CONDITIONS_CONTAINS=ee;var te="".concat(G,".doesNotContain");t.FILTERS_CONDITIONS_NOT_CONTAIN=te;var ne="".concat(G,".byValue");t.FILTERS_CONDITIONS_BY_VALUE=ne;var re="".concat(G,".greaterThan");t.FILTERS_CONDITIONS_GREATER_THAN=re;var oe="".concat(G,".greaterThanOrEqualTo");t.FILTERS_CONDITIONS_GREATER_THAN_OR_EQUAL=oe;var ie="".concat(G,".lessThan");t.FILTERS_CONDITIONS_LESS_THAN=ie;var ae="".concat(G,".lessThanOrEqualTo");t.FILTERS_CONDITIONS_LESS_THAN_OR_EQUAL=ae;var se="".concat(G,".isBetween");t.FILTERS_CONDITIONS_BETWEEN=se;var le="".concat(G,".isNotBetween");t.FILTERS_CONDITIONS_NOT_BETWEEN=le;var ue="".concat(G,".after");t.FILTERS_CONDITIONS_AFTER=ue;var ce="".concat(G,".before");t.FILTERS_CONDITIONS_BEFORE=ce;var he="".concat(G,".today");t.FILTERS_CONDITIONS_TODAY=he;var de="".concat(G,".tomorrow");t.FILTERS_CONDITIONS_TOMORROW=de;var fe="".concat(G,".yesterday");t.FILTERS_CONDITIONS_YESTERDAY=fe;var ge="".concat($,"labels.filterByCondition");t.FILTERS_DIVS_FILTER_BY_CONDITION=ge;var ve="".concat($,"labels.filterByValue");t.FILTERS_DIVS_FILTER_BY_VALUE=ve;var pe="".concat($,"labels.conjunction");t.FILTERS_LABELS_CONJUNCTION=pe;var me="".concat($,"labels.disjunction");t.FILTERS_LABELS_DISJUNCTION=me;var ye="".concat($,"values.blankCells");t.FILTERS_VALUES_BLANK_CELLS=ye;var we="".concat($,"buttons.selectAll");t.FILTERS_BUTTONS_SELECT_ALL=we;var Ce="".concat($,"buttons.clear");t.FILTERS_BUTTONS_CLEAR=Ce;var Ee="".concat($,"buttons.ok");t.FILTERS_BUTTONS_OK=Ee;var Se="".concat($,"buttons.cancel");t.FILTERS_BUTTONS_CANCEL=Se;var be="".concat($,"buttons.placeholder.search");t.FILTERS_BUTTONS_PLACEHOLDER_SEARCH=be;var Te="".concat($,"buttons.placeholder.value");t.FILTERS_BUTTONS_PLACEHOLDER_VALUE=Te;var Re="".concat($,"buttons.placeholder.secondValue");t.FILTERS_BUTTONS_PLACEHOLDER_SECOND_VALUE=Re},function(e,t,n){"use strict";var r=n(140)(!1),o=[].indexOf,i=!!o&&1/[1].indexOf(1,-0)<0,a=n(126)("indexOf");n(22)({target:"Array",proto:!0,forced:i||a},{indexOf:function(e){return i?o.apply(this,arguments)||0:r(this,e,arguments[1])}})},function(r,e,t){t(6);var i=t(536);function o(e,t,n){return"undefined"!=typeof Reflect&&Reflect.get?r.exports=o=Reflect.get:r.exports=o=function(e,t,n){var r=i(e,t);if(r){var o=Object.getOwnPropertyDescriptor(r,t);return o.get?o.get.call(n):o.value}},o(e,t,n||e)}r.exports=o},function(e,t,n){"use strict";var o=n(146),r=n(87),i=n(144),a="String Iterator",s=r.set,l=r.getterFor(a);i(String,"String",function(e){s(this,{type:a,string:String(e),index:0})},function(){var e,t=l(this),n=t.string,r=t.index;return r>=n.length?{value:void 0,done:!0}:(e=o(n,r,!0),t.index+=e.length,{value:e,done:!1})})},function(e,t,n){"use strict";var r=n(0);n(10),n(36),n(37),t.__esModule=!0,t.isNumeric=function(e){var t=(0,o.default)(e);return"number"==t?!isNaN(e)&&isFinite(e):"string"==t?!!e.length&&(1==e.length?/\d/.test(e):/^\s*[+-]?\s*(?:(?:\d+(?:\.\d+)?(?:e[+-]?\d+)?)|(?:0x[a-f\d]+))\s*$/i.test(e)):"object"==t&&!(!e||"number"!=typeof e.valueOf()||e instanceof Date)},t.rangeEach=function(e,t,n){var r=-1;"function"==typeof t?(n=t,t=e):r=e-1;for(;++r<=t&&!1!==n(r););},t.rangeEachReverse=function(e,t,n){var r=e+1;"function"==typeof t&&(n=t,t=0);for(;--r>=t&&!1!==n(r););},t.valueAccordingPercent=function(e,t){return t=parseInt(t.toString().replace("%",""),10),t=parseInt(e*t/100,10)};var o=r(n(44))},function(e,t,n){"use strict";var r=n(69),o=n(121),i=n(100),a=n(87),s=n(144),l="Array Iterator",u=a.set,c=a.getterFor(l);e.exports=s(Array,"Array",function(e,t){u(this,{type:l,target:r(e),index:0,kind:t})},function(){var e=c(this),t=e.target,n=e.kind,r=e.index++;return!t||r>=t.length?{value:e.target=void 0,done:!0}:"keys"==n?{value:r,done:!1}:"values"==n?{value:t[r],done:!1}:{value:[r,t[r]],done:!1}},"values"),i.Arguments=i.Array,o("keys"),o("values"),o("entries")},function(e,t,n){var r=n(191),o=n(16),i=n(32),a=n(61),s=n(35),l=s("iterator"),u=s("toStringTag"),c=o.values;for(var h in r){var d=i[h],f=d&&d.prototype;if(f){if(f[l]!==c)try{a(f,l,c)}catch(e){f[l]=c}if(f[u]||a(f,u,h),r[h])for(var g in o)if(f[g]!==o[g])try{a(f,g,o[g])}catch(e){f[g]=o[g]}}}},function(e,t,n){"use strict";var r=n(124),o=n(42),u=n(62),c=n(48),h=n(127),d=n(151),i=n(35)("isConcatSpreadable"),f=9007199254740991,g="Maximum allowed index exceeded",a=!n(29)(function(){var e=[];return e[i]=!1,e.concat()[0]!==e}),s=n(103)("concat"),v=function(e){if(!o(e))return!1;var t=e[i];return void 0!==t?!!t:r(e)},l=!a||!s;n(22)({target:"Array",proto:!0,forced:l},{concat:function(e){var t,n,r,o,i,a=u(this),s=d(a,0),l=0;for(t=-1,r=arguments.length;t<r;t++)if(i=-1===t?a:arguments[t],v(i)){if(o=c(i.length),f<l+o)throw TypeError(g);for(n=0;n<o;n++,l++)n in i&&h(s,l,i[n])}else{if(f<=l)throw TypeError(g);h(s,l++,i)}return s.length=l,s}})},function(e,t,n){var r=n(332),o=n(528),i=n(333);e.exports=function(e,t){return r(e)||o(e,t)||i()}},function(e,t,n){"use strict";var r=n(0);n(16),n(76),n(10),n(14),n(24),n(17),t.__esModule=!0,t.registerPlugin=function(e,t){var n=(0,a.toUpperCaseFirst)(e);o.default.getSingleton().add("construct",function(){s.has(this)||s.set(this,{});var e=s.get(this);e[n]||(e[n]=new t(this))}),o.default.getSingleton().add("afterDestroy",function(){if(s.has(this)){var e=s.get(this);(0,i.objectEach)(e,function(e){return e.destroy()}),s.delete(this)}})},t.getPlugin=function(e,t){if("string"!=typeof t)throw Error('Only strings can be passed as "plugin" parameter');var n=(0,a.toUpperCaseFirst)(t);return s.has(e)&&s.get(e)[n]?s.get(e)[n]:void 0},t.getRegistredPluginNames=function(e){return s.has(e)?Object.keys(s.get(e)):[]},t.getPluginName=function(e,n){var r=null;s.has(e)&&(0,i.objectEach)(s.get(e),function(e,t){e===n&&(r=t)});return r};var o=r(n(43)),i=n(4),a=n(68),s=new WeakMap},function(e,t,n){"use strict";var r=n(0);n(12),n(16),n(33),n(10),n(14),n(24),n(17),t.__esModule=!0,t.default=void 0;var o=r(n(1)),i=r(n(2)),a=n(4),s=n(3),l=n(90),u=n(20),c=new WeakMap,h=null,d=function(){function n(e){var t=this;(0,o.default)(this,n),(0,a.defineGetter)(this,"hot",e,{writable:!1}),(0,a.defineGetter)(this,"t",(0,l.getTranslator)(e),{writable:!1}),c.set(this,{hooks:{}}),h=null,this.pluginName=null,this.pluginsInitializedCallbacks=[],this.isPluginsReady=!1,this.enabled=!1,this.initialized=!1,this.hot.addHook("afterPluginsInitialized",function(){return t.onAfterPluginsInitialized()}),this.hot.addHook("afterUpdateSettings",function(e){return t.onUpdateSettings(e)}),this.hot.addHook("beforeInit",function(){return t.init()})}return(0,i.default)(n,[{key:"init",value:function(){this.pluginName=(0,u.getPluginName)(this.hot,this),this.isEnabled&&this.isEnabled()&&this.enablePlugin(),h||(h=(0,u.getRegistredPluginNames)(this.hot)),0<=h.indexOf(this.pluginName)&&h.splice(h.indexOf(this.pluginName),1),h.length||this.hot.runHooks("afterPluginsInitialized"),this.initialized=!0}},{key:"enablePlugin",value:function(){this.enabled=!0}},{key:"disablePlugin",value:function(){this.eventManager&&this.eventManager.clear(),this.clearHooks(),this.enabled=!1}},{key:"addHook",value:function(e,t){c.get(this).hooks[e]=c.get(this).hooks[e]||[];var n=c.get(this).hooks[e];this.hot.addHook(e,t),n.push(t),c.get(this).hooks[e]=n}},{key:"removeHooks",value:function(t){var n=this;(0,s.arrayEach)(c.get(this).hooks[t]||[],function(e){n.hot.removeHook(t,e)})}},{key:"clearHooks",value:function(){var n=this,e=c.get(this).hooks;(0,a.objectEach)(e,function(e,t){return n.removeHooks(t)}),e.length=0}},{key:"callOnPluginsReady",value:function(e){this.isPluginsReady?e():this.pluginsInitializedCallbacks.push(e)}},{key:"onAfterPluginsInitialized",value:function(){(0,s.arrayEach)(this.pluginsInitializedCallbacks,function(e){return e()}),this.pluginsInitializedCallbacks.length=0,this.isPluginsReady=!0}},{key:"onUpdateSettings",value:function(){this.isEnabled&&(this.enabled&&!this.isEnabled()&&this.disablePlugin(),!this.enabled&&this.isEnabled()&&this.enablePlugin(),this.enabled&&this.isEnabled()&&this.updatePlugin())}},{key:"updatePlugin",value:function(){}},{key:"destroy",value:function(){var n=this;this.eventManager&&this.eventManager.destroy(),this.clearHooks(),(0,a.objectEach)(this,function(e,t){"hot"!==t&&"t"!==t&&(n[t]=null)}),delete this.t,delete this.hot}}]),n}();t.default=d},function(e,t,n){var c=n(32),h=n(115).f,d=n(61),f=n(65),g=n(143),v=n(179),p=n(120);e.exports=function(e,t){var n,r,o,i,a,s=e.target,l=e.global,u=e.stat;if(n=l?c:u?c[s]||g(s,{}):(c[s]||{}).prototype)for(r in t){if(i=t[r],o=e.noTargetGet?(a=h(n,r))&&a.value:n[r],!p(l?r:s+(u?".":"#")+r,e.forced)&&void 0!==o){if(typeof i==typeof o)continue;v(i,o)}(e.sham||o&&o.sham)&&d(i,"sham",!0),f(n,r,i,e)}}},function(e,t,n){"use strict";var r=n(0);n(33),t.__esModule=!0,t.getListenersCounter=function(){return s},t.default=void 0;var o=r(n(1)),i=r(n(2)),u=n(5),c=n(4),h=n(73),d=n(31),s=0,f=function(){function t(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;(0,o.default)(this,t),this.context=e||this,this.context.eventListeners||(this.context.eventListeners=[])}return(0,i.default)(t,[{key:"addEventListener",value:function(e,t,n){var r=this,o=3<arguments.length&&void 0!==arguments[3]&&arguments[3],i=this.context;function a(e){n.call(this,function(e,t){var n,r,o,i,a,s="HOT-TABLE";t.isTargetWebComponent=!1,t.realTarget=t.target;var l=t.stopImmediatePropagation;if(t.stopImmediatePropagation=function(){l.apply(this),(0,d.stopImmediatePropagation)(this)},!f.isHotTableEnv)return t;t=(0,u.polymerWrap)(t),a=t.path?t.path.length:0;for(;a;){if(a-=1,t.path[a].nodeName===s)n=!0;else if(n&&t.path[a].shadowRoot){i=t.path[a];break}0!==a||i||(i=t.path[a])}i||(i=t.target);t.isTargetWebComponent=!0,(0,h.isWebComponentSupportedNatively)()?t.realTarget=t.srcElement||t.toElement:((0,c.hasOwnProperty)(e,"hot")||e.isHotTableEnv||e.wtTable)&&((0,c.hasOwnProperty)(e,"hot")?r=e.hot?e.hot.view.wt.wtTable.TABLE:null:e.isHotTableEnv?r=e.view.activeWt.wtTable.TABLE.parentNode.parentNode:e.wtTable&&(r=e.wtTable.TABLE.parentNode.parentNode),o=(0,u.closest)(t.target,[s],r),t.realTarget=o&&r.querySelector(s)||t.target);return Object.defineProperty(t,"target",{get:function(){return(0,u.polymerWrap)(i)},enumerable:!0,configurable:!0}),t}(i,e))}return"boolean"==typeof o||(0,h.isPassiveEventSupported)()||(o=!1),this.context.eventListeners.push({element:e,event:t,callback:n,callbackProxy:a,options:o}),e.addEventListener(t,a,o),s+=1,function(){r.removeEventListener(e,t,n)}}},{key:"removeEventListener",value:function(e,t,n){for(var r,o=this.context.eventListeners.length;o;)if(o-=1,(r=this.context.eventListeners[o]).event===t&&r.element===e){if(n&&n!==r.callback)continue;this.context.eventListeners.splice(o,1),r.element.removeEventListener(r.event,r.callbackProxy,r.options),s-=1}}},{key:"clearEvents",value:function(){if(this.context)for(var e=this.context.eventListeners.length;e;){e-=1;var t=this.context.eventListeners[e];t&&this.removeEventListener(t.element,t.event,t.callback)}}},{key:"clear",value:function(){this.clearEvents()}},{key:"destroy",value:function(){this.clearEvents(),this.context=null}},{key:"fireEvent",value:function(e,t){var n=e.document,r=e;n||(r=(n=e.ownerDocument?e.ownerDocument:e).defaultView);var o,i={bubbles:!0,cancelable:"mousemove"!==t,view:r,detail:0,screenX:0,screenY:0,clientX:1,clientY:1,ctrlKey:!1,altKey:!1,shiftKey:!1,metaKey:!1,button:0,relatedTarget:void 0};n.createEvent?(o=n.createEvent("MouseEvents")).initMouseEvent(t,i.bubbles,i.cancelable,i.view,i.detail,i.screenX,i.screenY,i.clientX,i.clientY,i.ctrlKey,i.altKey,i.shiftKey,i.metaKey,i.button,i.relatedTarget||n.body.parentNode):o=n.createEventObject(),e.dispatchEvent?e.dispatchEvent(o):e.fireEvent("on".concat(t),o)}}]),t}();var a=f;t.default=a},function(e,t,n){"use strict";var r,o=n(32),i=n(147),a=n(123),s=n(186),l=n(42),u=n(87).enforce,c=n(178),h=!o.ActiveXObject&&"ActiveXObject"in o,d=Object.isExtensible,f=function(e){return function(){return e(this,0<arguments.length?arguments[0]:void 0)}},g=e.exports=n(125)("WeakMap",f,s,!0,!0);if(c&&h){r=s.getConstructor(f,"WeakMap",!0),a.REQUIRED=!0;var v=g.prototype,p=v.delete,m=v.has,y=v.get,w=v.set;i(v,{delete:function(e){if(!l(e)||d(e))return p.call(this,e);var t=u(this);return t.frozen||(t.frozen=new r),p.call(this,e)||t.frozen.delete(e)},has:function(e){if(!l(e)||d(e))return m.call(this,e);var t=u(this);return t.frozen||(t.frozen=new r),m.call(this,e)||t.frozen.has(e)},get:function(e){if(!l(e)||d(e))return y.call(this,e);var t=u(this);return t.frozen||(t.frozen=new r),m.call(this,e)?y.call(this,e):t.frozen.get(e)},set:function(e,t){if(l(e)&&!d(e)){var n=u(this);n.frozen||(n.frozen=new r),m.call(this,e)?w.call(this,e,t):n.frozen.set(e,t)}else w.call(this,e,t);return this}})}},function(e,t,n){"use strict";var r=n(0);t.__esModule=!0;var o=r(n(198));t.ViewportColumnsCalculator=o.default;var i=r(n(199));t.ViewportRowsCalculator=i.default;var a=r(n(106));t.CellCoords=a.default;var s=r(n(200));t.CellRange=s.default;var l=r(n(201));t.ColumnFilter=l.default;var u=r(n(202));t.RowFilter=u.default;var c=r(n(523));t.DebugOverlay=c.default;var h=r(n(529));t.LeftOverlay=h.default;var d=r(n(530));t.TopOverlay=d.default;var f=r(n(531));t.TopLeftCornerOverlay=f.default;var g=r(n(532));t.BottomOverlay=g.default;var v=r(n(533));t.BottomLeftCornerOverlay=v.default;var p=r(n(336));t.Border=p.default;var m=r(n(326));t.default=m.default,t.Core=m.default;var y=r(n(327));t.Event=y.default;var w=r(n(328));t.Overlays=w.default;var C=r(n(329));t.Scroll=C.default;var E=r(n(534));t.Selection=E.default;var S=r(n(330));t.Settings=S.default;var b=r(n(331));t.Table=b.default;var T=r(n(334));t.TableRenderer=T.default;var R=r(n(335));t.Viewport=R.default},function(e,t){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}},function(e,t,n){"use strict";var r=n(0);n(10),n(36),n(524),n(204),n(37),n(46),t.__esModule=!0,t.stringify=function(e){var t;switch((0,i.default)(e)){case"string":case"number":t="".concat(e);break;case"object":t=null===e?"":e.toString();break;case"undefined":t="";break;default:t=e.toString()}return t},t.isDefined=function(e){return void 0!==e},t.isUndefined=f,t.isEmpty=m,t.isRegExp=function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},t._injectProductInfo=function(e,t){var n,r=!m(e),o="string"==typeof e&&"non-commercial-and-evaluation"===e.toLowerCase(),i="7.0.2",a="invalid",s="invalid",l=function(e){var t=[][y],n=t;if(e[y]!==S("Z"))return!1;for(var r="",o="B<H4P+".split(""),i=S(o.shift());i;i=S(o.shift()||"A"))--i<""[y]?n|=(C("".concat(C(w(r)+(w(E(e,Math.abs(i),2))+[]).padStart(2,"0"))))%97||2)>>1:r=E(e,i,i?1===o[y]?9:8:6);return n===t}(e=b(e||""));if(r||o||l)if(l){var u=(0,p.default)("09/04/2019","DD/MM/YYYY"),c=Math.floor(u.toDate().getTime()/864e5),h=T(e);if(n=(0,p.default)(864e5*(h+1),"x").format("MMMM DD, YYYY"),h<c){var d=(0,p.default)().diff(u,"days");a=d<=1?"valid":"expired",s=d<=15?"valid":"expired"}else s=a="valid"}else s=o?(a="non_commercial","valid"):a="invalid";else s=a="missing";R()&&(s=a="valid");if(!_&&"valid"!==a){var f=k[a]({keyValidityDate:n,hotVersion:i});f&&console["non_commercial"===a?"info":"warn"](k[a]({keyValidityDate:n,hotVersion:i})),_=!0}if("valid"!==s&&t.parentNode){var g=O[s]({keyValidityDate:n,hotVersion:i});if(g){var v=document.createElement("div");v.id="hot-display-license-info",v.innerHTML=O[s]({keyValidityDate:n,hotVersion:i}),t.parentNode.insertBefore(v,t.nextSibling)}}};var o=r(n(66)),i=r(n(44)),p=r(n(63)),a=n(67);function s(){var e=(0,o.default)(['\n The license key for Handsontable is missing. Use your purchased key to activate the product. \n Alternatively, you can activate Handsontable to use for non-commercial purposes by \n passing the key: \'non-commercial-and-evaluation\'. \n <a href="https://handsontable.com/docs/tutorial-license-key.html" target="_blank">Read more</a> about it in \n the documentation or contact us at <a href="mailto:support@handsontable.com">support@handsontable.com</a>.'],['\n The license key for Handsontable is missing. Use your purchased key to activate the product.\\x20\n Alternatively, you can activate Handsontable to use for non-commercial purposes by\\x20\n passing the key: \'non-commercial-and-evaluation\'.\\x20\n <a href="https://handsontable.com/docs/tutorial-license-key.html" target="_blank">Read more</a> about it in\\x20\n the documentation or contact us at <a href="mailto:support@handsontable.com">support@handsontable.com</a>.']);return s=function(){return e},e}function l(){var e=(0,o.default)(["\n The license key for Handsontable expired on ",", and is not valid for the installed \n version ",'. <a href="https://handsontable.com/pricing" target="_blank">Renew</a> your \n license key or downgrade to a version released prior to ','. If you need any \n help, contact us at <a href="mailto:sales@handsontable.com">sales@handsontable.com</a>.'],["\n The license key for Handsontable expired on ",", and is not valid for the installed\\x20\n version ",'. <a href="https://handsontable.com/pricing" target="_blank">Renew</a> your\\x20\n license key or downgrade to a version released prior to ','. If you need any\\x20\n help, contact us at <a href="mailto:sales@handsontable.com">sales@handsontable.com</a>.']);return l=function(){return e},e}function u(){var e=(0,o.default)(['\n The license key for Handsontable is invalid. \n <a href="https://handsontable.com/docs/tutorial-license-key.html" target="_blank">Read more</a> on how to \n install it properly or contact us at <a href="mailto:support@handsontable.com">support@handsontable.com</a>.'],['\n The license key for Handsontable is invalid.\\x20\n <a href="https://handsontable.com/docs/tutorial-license-key.html" target="_blank">Read more</a> on how to\\x20\n install it properly or contact us at <a href="mailto:support@handsontable.com">support@handsontable.com</a>.']);return u=function(){return e},e}function c(){var e=(0,o.default)(["\n The license key for Handsontable is missing. Use your purchased key to activate the product. \n Alternatively, you can activate Handsontable to use for non-commercial purposes by \n passing the key: 'non-commercial-and-evaluation'. If you need any help, contact \n us at support@handsontable.com."],["\n The license key for Handsontable is missing. Use your purchased key to activate the product.\\x20\n Alternatively, you can activate Handsontable to use for non-commercial purposes by\\x20\n passing the key: 'non-commercial-and-evaluation'. If you need any help, contact\\x20\n us at support@handsontable.com."]);return c=function(){return e},e}function h(){var e=(0,o.default)(["\n The license key for Handsontable expired on ",", and is not valid for the installed \n version ",". Renew your license key at handsontable.com or downgrade to a version released prior \n to ",". If you need any help, contact us at sales@handsontable.com."],["\n The license key for Handsontable expired on ",", and is not valid for the installed\\x20\n version ",". Renew your license key at handsontable.com or downgrade to a version released prior\\x20\n to ",". If you need any help, contact us at sales@handsontable.com."]);return h=function(){return e},e}function d(){var e=(0,o.default)(["\n The license key for Handsontable is invalid. \n If you need any help, contact us at support@handsontable.com."],["\n The license key for Handsontable is invalid.\\x20\n If you need any help, contact us at support@handsontable.com."]);return d=function(){return e},e}function f(e){return void 0===e}function m(e){return null===e||""===e||f(e)}var y="length",w=function(e){return parseInt(e,16)},C=function(e){return parseInt(e,10)},E=function(e,t,n){return e.substr(t,n)},S=function(e){return e.codePointAt(0)-65},b=function(e){return"".concat(e).replace(/\-/g,"")},T=function(e){return w(E(b(e),w("12"),S("F")))/(w(E(b(e),S("B"),~~![][y]))||9)},R=function(){return"undefined"!=typeof location&&/^([a-z0-9\-]+\.)?\x68\x61\x6E\x64\x73\x6F\x6E\x74\x61\x62\x6C\x65\x2E\x63\x6F\x6D$/i.test(location.host)},_=!1,k={invalid:function(){return(0,a.toSingleLine)(d())},expired:function(e){var t=e.keyValidityDate,n=e.hotVersion;return(0,a.toSingleLine)(h(),t,n,t)},missing:function(){return(0,a.toSingleLine)(c())},non_commercial:function(){return""}},O={invalid:function(){return(0,a.toSingleLine)(u())},expired:function(e){var t=e.keyValidityDate,n=e.hotVersion;return(0,a.toSingleLine)(l(),t,n,t)},missing:function(){return(0,a.toSingleLine)(s())},non_commercial:function(){return""}}},function(e,t,n){"use strict";n(18),t.__esModule=!0,t.getCondition=function(e,t){if(!a[e])throw Error('Filter condition "'.concat(e,'" does not exist.'));var n=a[e],r=n.condition,o=n.descriptor,i=t;o.inputValuesDecorator&&(i=o.inputValuesDecorator(i));return function(e){return r.apply(e.meta.instance,[].concat([e],[i]))}},t.getConditionDescriptor=function(e){if(a[e])return a[e].descriptor;throw Error('Filter condition "'.concat(e,'" does not exist.'))},t.registerCondition=function(e,t,n){n.key=e,a[e]={condition:t,descriptor:n}},t.conditions=void 0;var a={};t.conditions=a},function(e,t){e.exports=function(e){try{return!!e()}catch(e){return!0}}},function(e,t,n){var r=n(32),o=n(203),i=[].slice,a=/MSIE .\./.test(o),s=function(o){return function(e,t){var n=2<arguments.length,r=n&&i.call(arguments,2);return o(n?function(){("function"==typeof e?e:Function(e)).apply(this,r)}:e,t)}};n(22)({global:!0,bind:!0,forced:a},{setTimeout:s(r.setTimeout),setInterval:s(r.setInterval)})},function(e,t,n){"use strict";t.__esModule=!0,t.stopImmediatePropagation=function(e){e.isImmediatePropagationEnabled=!1,e.cancelBubble=!0},t.isImmediatePropagationStopped=function(e){return!1===e.isImmediatePropagationEnabled},t.stopPropagation=function(e){"function"==typeof e.stopPropagation?e.stopPropagation():e.cancelBubble=!0},t.pageX=function(e){if(e.pageX)return e.pageX;var t=e.target.ownerDocument.defaultView;return e.clientX+(0,r.getWindowScrollLeft)(t)},t.pageY=function(e){if(e.pageY)return e.pageY;var t=e.target.ownerDocument.defaultView;return e.clientY+(0,r.getWindowScrollTop)(t)},t.isRightClick=function(e){return 2===e.button},t.isLeftClick=function(e){return 0===e.button};var r=n(5)},function(e,t){e.exports="object"==typeof window&&window&&window.Math==Math?window:"object"==typeof self&&self&&self.Math==Math?self:Function("return this")()},function(e,t,n){"use strict";var d=n(114),f=n(86),g=n(48),v=n(62),p=n(151),m=n(127),y=Math.max,w=Math.min,r=n(103)("splice");n(22)({target:"Array",proto:!0,forced:!r},{splice:function(e,t){var n,r,o,i,a,s,l=v(this),u=g(l.length),c=d(e,u),h=arguments.length;if(0===h?n=r=0:r=1===h?(n=0,u-c):(n=h-2,w(y(f(t),0),u-c)),9007199254740991<u+n-r)throw TypeError("Maximum allowed length exceeded");for(o=p(l,r),i=0;i<r;i++)(a=c+i)in l&&m(o,i,l[a]);if(n<(o.length=r)){for(i=c;i<u-r;i++)s=i+n,(a=i+r)in l?l[s]=l[a]:delete l[s];for(i=u;u-r+n<i;i--)delete l[i-1]}else if(r<n)for(i=u-r;c<i;i--)s=i+n-1,(a=i+r-1)in l?l[s]=l[a]:delete l[s];for(i=0;i<n;i++)l[i+c]=arguments[i+2];return l.length=u-r+n,o}})},function(e,t,n){"use strict";var r=n(140)(!0);n(22)({target:"Array",proto:!0},{includes:function(e){return r(this,e,1<arguments.length?arguments[1]:void 0)}}),n(121)("includes")},function(e,t,n){var r=n(98)("wks"),o=n(118),i=n(32).Symbol,a=n(180);e.exports=function(e){return r[e]||(r[e]=a&&i[e]||(a?i:o)("Symbol."+e))}},function(e,t,n){"use strict";var r=n(45),o=n(29),i=n(153),a=n(52),s="toString",l=/./[s],u=o(function(){return"/a/b"!=l.call({source:"a",flags:"b"})}),c=l.name!=s;(u||c)&&n(65)(RegExp.prototype,s,function(){var e=r(this);return"/".concat(e.source,"/","flags"in e?e.flags:!a&&e instanceof RegExp?i.call(e):void 0)},{unsafe:!0})},function(e,t,n){"use strict";var T=n(45),r=n(62),R=n(48),_=n(86),i=n(58),k=n(155),O=n(128),M=Math.max,N=Math.min,d=Math.floor,f=/\$([$&`']|\d\d?|<[^>]*>)/g,g=/\$([$&`']|\d\d?)/g;n(129)("replace",2,function(o,E,S){return[function(e,t){var n=i(this),r=null==e?void 0:e[o];return void 0!==r?r.call(e,n,t):E.call(String(n),e,t)},function(e,t){var n=S(E,e,this,t);if(n.done)return n.value;var r=T(e),o=String(this),i="function"==typeof t;i||(t=String(t));var a=r.global;if(a){var s=r.unicode;r.lastIndex=0}for(var l=[];;){var u=O(r,o);if(null===u)break;if(l.push(u),!a)break;""===String(u[0])&&(r.lastIndex=k(o,R(r.lastIndex),s))}for(var c,h="",d=0,f=0;f<l.length;f++){u=l[f];for(var g=String(u[0]),v=M(N(_(u.index),o.length),0),p=[],m=1;m<u.length;m++)p.push(void 0===(c=u[m])?c:String(c));var y=u.groups;if(i){var w=[g].concat(p,v,o);void 0!==y&&w.push(y);var C=String(t.apply(void 0,w))}else C=b(g,o,v,p,y,t);d<=v&&(h+=o.slice(d,v)+C,d=v+g.length)}return h+o.slice(d)}];function b(i,a,s,l,u,e){var c=s+i.length,h=l.length,t=g;return void 0!==u&&(u=r(u),t=f),E.call(e,t,function(e,t){var n;switch(t.charAt(0)){case"$":return"$";case"&":return i;case"`":return a.slice(0,s);case"'":return a.slice(c);case"<":n=u[t.slice(1,-1)];break;default:var r=+t;if(0==r)return e;if(h<r){var o=d(r/10);return 0===o?e:o<=h?void 0===l[o-1]?t.charAt(1):l[o-1]+t.charAt(1):e}n=l[r-1]}return void 0===n?"":n})}})},function(e,t,n){var r=n(517),o=n(195),i=n(518);e.exports=function(e){return r(e)||o(e)||i()}},function(e,t,n){"use strict";var r=n(157),o="includes",i=n(158)(o);n(22)({target:"String",proto:!0,forced:!i},{includes:function(e){return!!~r(this,e,o).indexOf(e,1<arguments.length?arguments[1]:void 0)}})},function(e,t,n){"use strict";var u=n(42),c=n(124),h=n(114),d=n(48),f=n(69),g=n(127),v=n(35)("species"),p=[].slice,m=Math.max,r=n(103)("slice");n(22)({target:"Array",proto:!0,forced:!r},{slice:function(e,t){var n,r,o,i=f(this),a=d(i.length),s=h(e,a),l=h(void 0===t?a:t,a);if(c(i)&&("function"!=typeof(n=i.constructor)||n!==Array&&!c(n.prototype)?u(n)&&null===(n=n[v])&&(n=void 0):n=void 0,n===Array||void 0===n))return p.call(i,s,l);for(r=new(void 0===n?Array:n)(m(l-s,0)),o=0;s<l;s++,o++)s in i&&g(r,o,i[s]);return r.length=o,r}})},function(e,t,n){"use strict";var r=n(0);t.__esModule=!0,t.getRenderer=function(e){if("function"==typeof e)return e;if(v(e))return g(e);throw Error('No registered renderer found under "'.concat(e,'" name'))},t.getRegisteredRenderers=t.getRegisteredRendererNames=t.hasRenderer=t.registerRenderer=void 0;var o=r(n(78)),i=r(n(548)),a=r(n(549)),s=r(n(550)),l=r(n(551)),u=r(n(552)),c=r(n(553)),h=r(n(554)),d=(0,o.default)("renderers"),f=d.register,g=d.getItem,v=d.hasItem,p=d.getNames,m=d.getValues;t.getRegisteredRenderers=m,t.getRegisteredRendererNames=p,t.hasRenderer=v,(t.registerRenderer=f)("base",i.default),f("autocomplete",a.default),f("checkbox",s.default),f("html",l.default),f("numeric",u.default),f("password",c.default),f("text",h.default)},function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},function(e,t,n){"use strict";var r=n(0);n(12),n(33),t.__esModule=!0,t.default=void 0;var o=r(n(1)),i=r(n(2)),s=n(3),a=n(4),l=["afterCellMetaReset","afterChange","afterChangesObserved","afterContextMenuDefaultOptions","beforeContextMenuSetItems","afterDropdownMenuDefaultOptions","beforeDropdownMenuSetItems","afterContextMenuHide","beforeContextMenuShow","afterContextMenuShow","afterCopyLimit","beforeCreateCol","afterCreateCol","beforeCreateRow","afterCreateRow","afterDeselect","afterDestroy","afterDocumentKeyDown","afterDrawSelection","beforeRemoveCellClassNames","afterGetCellMeta","afterGetColHeader","afterGetRowHeader","afterInit","afterLoadData","afterMomentumScroll","afterOnCellCornerMouseDown","afterOnCellCornerDblClick","afterOnCellMouseDown","afterOnCellMouseUp","afterOnCellContextMenu","afterOnCellMouseOver","afterOnCellMouseOut","afterRemoveCol","afterRemoveRow","afterRender","beforeRenderer","afterRenderer","afterScrollHorizontally","afterScrollVertically","afterSelection","afterSelectionByProp","afterSelectionEnd","afterSelectionEndByProp","afterSetCellMeta","afterRemoveCellMeta","afterSetDataAtCell","afterSetDataAtRowProp","afterUpdateSettings","afterValidate","beforeLanguageChange","afterLanguageChange","beforeAutofill","beforeCellAlignment","beforeChange","beforeChangeRender","beforeDrawBorders","beforeGetCellMeta","beforeRemoveCellMeta","beforeInit","beforeInitWalkontable","beforeKeyDown","beforeOnCellMouseDown","beforeOnCellMouseUp","beforeOnCellContextMenu","beforeOnCellMouseOver","beforeOnCellMouseOut","beforeRemoveCol","beforeRemoveRow","beforeRender","beforeSetRangeStartOnly","beforeSetRangeStart","beforeSetRangeEnd","beforeTouchScroll","beforeValidate","beforeValueRender","construct","init","modifyCol","unmodifyCol","unmodifyRow","modifyColHeader","modifyColWidth","modifyRow","modifyRowHeader","modifyRowHeight","modifyData","modifyRowData","modifyGetCellCoords","persistentStateLoad","persistentStateReset","persistentStateSave","beforeColumnSort","afterColumnSort","modifyAutofillRange","modifyCopyableRange","beforeCut","afterCut","beforeCopy","afterCopy","beforePaste","afterPaste","beforeColumnMove","afterColumnMove","beforeRowMove","afterRowMove","beforeColumnResize","afterColumnResize","beforeRowResize","afterRowResize","afterGetColumnHeaderRenderers","afterGetRowHeaderRenderers","beforeStretchingColumnWidth","beforeFilter","afterFilter","modifyColumnHeaderHeight","beforeUndo","afterUndo","beforeRedo","afterRedo","modifyRowHeaderWidth","beforeAutofillInsidePopulate","modifyTransformStart","modifyTransformEnd","afterModifyTransformStart","afterModifyTransformEnd","afterViewportRowCalculatorOverride","afterViewportColumnCalculatorOverride","afterPluginsInitialized","skipLengthCache","beforeHideRows","afterHideRows","beforeUnhideRows","afterUnhideRows","beforeHideColumns","afterHideColumns","beforeUnhideColumns","afterUnhideColumns","beforeTrimRow","afterTrimRow","beforeUntrimRow","afterUntrimRow","beforeDropdownMenuShow","afterDropdownMenuShow","afterDropdownMenuHide","hiddenRow","hiddenColumn","beforeAddChild","afterAddChild","beforeDetachChild","afterDetachChild","afterBeginEditing","beforeMergeCells","afterMergeCells","beforeUnmergeCells","afterUnmergeCells","afterListen","afterUnlisten","afterRefreshDimensions","beforeRefreshDimensions"],u=function(){function e(){(0,o.default)(this,e),this.globalBucket=this.createEmptyBucket()}return(0,i.default)(e,null,[{key:"getSingleton",value:function(){return c}}]),(0,i.default)(e,[{key:"createEmptyBucket",value:function(){var t=Object.create(null);return(0,s.arrayEach)(l,function(e){return t[e]=[]}),t}},{key:"getBucket",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;return e?(e.pluginHookBucket||(e.pluginHookBucket=this.createEmptyBucket()),e.pluginHookBucket):this.globalBucket}},{key:"add",value:function(n,r){var t=this,o=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;if(Array.isArray(r))(0,s.arrayEach)(r,function(e){return t.add(n,e,o)});else{var i=this.getBucket(o);if(void 0===i[n]&&(this.register(n),i[n]=[]),r.skip=!1,-1===i[n].indexOf(r)){var a=!1;r.initialHook&&(0,s.arrayEach)(i[n],function(e,t){if(e.initialHook)return i[n][t]=r,!(a=!0)}),a||i[n].push(r)}}return this}},{key:"once",value:function(t,e){var n=this,r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;Array.isArray(e)?(0,s.arrayEach)(e,function(e){return n.once(t,e,r)}):(e.runOnce=!0,this.add(t,e,r))}},{key:"remove",value:function(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null,r=this.getBucket(n);return void 0!==r[e]&&0<=r[e].indexOf(t)&&(t.skip=!0)}},{key:"has",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null,n=this.getBucket(t);return!(void 0===n[e]||!n[e].length)}},{key:"run",value:function(e,t,n,r,o,i,a,s){var l=this.globalBucket[t],u=l?l.length:0,c=0;if(u)for(;c<u;)if(l[c]&&!l[c].skip){var h=l[c].call(e,n,r,o,i,a,s);void 0!==h&&(n=h),l[c]&&l[c].runOnce&&this.remove(t,l[c]),c+=1}else c+=1;var d=this.getBucket(e)[t],f=d?d.length:0,g=0;if(f)for(;g<f;)if(d[g]&&!d[g].skip){var v=d[g].call(e,n,r,o,i,a,s);void 0!==v&&(n=v),d[g]&&d[g].runOnce&&this.remove(t,d[g],e),g+=1}else g+=1;return n}},{key:"destroy",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;(0,a.objectEach)(this.getBucket(e),function(e,t,n){return n[t].length=0})}},{key:"register",value:function(e){this.isRegistered(e)||l.push(e)}},{key:"deregister",value:function(e){this.isRegistered(e)&&l.splice(l.indexOf(e),1)}},{key:"isRegistered",value:function(e){return 0<=l.indexOf(e)}},{key:"getRegistered",value:function(){return l}}]),e}(),c=new u;var h=u;t.default=h},function(t,e){function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function r(e){return"function"==typeof Symbol&&"symbol"===n(Symbol.iterator)?t.exports=r=function(e){return n(e)}:t.exports=r=function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":n(e)},r(e)}t.exports=r},function(e,t,n){var r=n(42);e.exports=function(e){if(!r(e))throw TypeError(String(e)+" is not an object");return e}},function(e,t,n){"use strict";var h=n(154),w=n(45),d=n(58),C=n(520),E=n(155),S=n(48),b=n(128),f=n(156),r=n(29),g=[].push,T=Math.min,R=4294967295,_=!r(function(){return!RegExp(R,"y")});n(129)("split",2,function(o,p,m){var y;return y="c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1).length||2!="ab".split(/(?:ab)*/).length||4!=".".split(/(.?)(.?)/).length||1<".".split(/()()/).length||"".split(/.?/).length?function(e,t){var n=String(d(this)),r=void 0===t?R:t>>>0;if(0==r)return[];if(void 0===e)return[n];if(!h(e))return p.call(n,e,r);for(var o,i,a,s=[],l=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),u=0,c=new RegExp(e.source,l+"g");(o=f.call(c,n))&&!(u<(i=c.lastIndex)&&(s.push(n.slice(u,o.index)),1<o.length&&o.index<n.length&&g.apply(s,o.slice(1)),a=o[0].length,u=i,s.length>=r));)c.lastIndex===o.index&&c.lastIndex++;return u===n.length?!a&&c.test("")||s.push(""):s.push(n.slice(u)),s.length>r?s.slice(0,r):s}:"0".split(void 0,0).length?function(e,t){return void 0===e&&0===t?[]:p.call(this,e,t)}:p,[function(e,t){var n=d(this),r=null==e?void 0:e[o];return void 0!==r?r.call(e,n,t):y.call(String(n),e,t)},function(e,t){var n=m(y,e,this,t,y!==p);if(n.done)return n.value;var r=w(e),o=String(this),i=C(r,RegExp),a=r.unicode,s=(r.ignoreCase?"i":"")+(r.multiline?"m":"")+(r.unicode?"u":"")+(_?"y":"g"),l=new i(_?r:"^(?:"+r.source+")",s),u=void 0===t?R:t>>>0;if(0==u)return[];if(0===o.length)return null===b(l,o)?[o]:[];for(var c=0,h=0,d=[];h<o.length;){l.lastIndex=_?h:0;var f,g=b(l,_?o:o.slice(h));if(null===g||(f=T(S(l.lastIndex+(_?0:h)),o.length))===c)h=E(o,h,a);else{if(d.push(o.slice(c,h)),d.length===u)return d;for(var v=1;v<=g.length-1;v++)if(d.push(g[v]),d.length===u)return d;h=c=f}}return d.push(o.slice(c)),d}]},!_)},function(e,t){var n={}.hasOwnProperty;e.exports=function(e,t){return n.call(e,t)}},function(e,t,n){var r=n(86),o=Math.min;e.exports=function(e){return 0<e?o(r(e),9007199254740991):0}},function(e,t,n){var r=n(52),o=n(176),i=n(45),a=n(97),s=Object.defineProperty;t.f=r?s:function(e,t,n){if(i(e),t=a(t,!0),i(n),o)try{return s(e,t,n)}catch(e){}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(e[t]=n.value),e}},function(e,t,n){"use strict";n(34),n(12),n(39),n(46),t.__esModule=!0,t.isPrintableChar=function(e){return 32===e||48<=e&&e<=57||96<=e&&e<=111||186<=e&&e<=192||219<=e&&e<=222||226<=e||65<=e&&e<=90},t.isMetaKey=function(e){return-1!==[i.ARROW_DOWN,i.ARROW_UP,i.ARROW_LEFT,i.ARROW_RIGHT,i.HOME,i.END,i.DELETE,i.BACKSPACE,i.F1,i.F2,i.F3,i.F4,i.F5,i.F6,i.F7,i.F8,i.F9,i.F10,i.F11,i.F12,i.TAB,i.PAGE_DOWN,i.PAGE_UP,i.ENTER,i.ESCAPE,i.SHIFT,i.CAPS_LOCK,i.ALT].indexOf(e)},t.isCtrlKey=function(e){var t=[];navigator.platform.includes("Mac")?t.push(i.COMMAND_LEFT,i.COMMAND_RIGHT,i.COMMAND_FIREFOX):t.push(i.CONTROL);return t.includes(e)},t.isCtrlMetaKey=function(e){return[i.CONTROL,i.COMMAND_LEFT,i.COMMAND_RIGHT,i.COMMAND_FIREFOX].includes(e)},t.isKey=function(t,e){var n=e.split("|"),r=!1;return(0,o.arrayEach)(n,function(e){if(t===i[e])return!(r=!0)}),r},t.KEY_CODES=void 0;var o=n(3),i={MOUSE_LEFT:1,MOUSE_RIGHT:3,MOUSE_MIDDLE:2,BACKSPACE:8,COMMA:188,INSERT:45,DELETE:46,END:35,ENTER:13,ESCAPE:27,CONTROL:17,COMMAND_LEFT:91,COMMAND_RIGHT:93,COMMAND_FIREFOX:224,ALT:18,HOME:36,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,SPACE:32,SHIFT:16,CAPS_LOCK:20,TAB:9,ARROW_RIGHT:39,ARROW_LEFT:37,ARROW_UP:38,ARROW_DOWN:40,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,A:65,C:67,D:68,F:70,L:76,O:79,P:80,S:83,V:86,X:88};t.KEY_CODES=i},function(e,t,n){var r=n(52),o=n(49).f,i=Function.prototype,a=i.toString,s=/^\s*function ([^ (]*)/;!r||"name"in i||o(i,"name",{configurable:!0,get:function(){try{return a.call(this).match(s)[1]}catch(e){return""}}})},function(e,t,n){e.exports=!n(29)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(e,t,n){"use strict";var r=n(0);n(16),n(10),n(14),n(24),n(17),t.__esModule=!0,t.RegisteredEditor=b,t.getEditorInstance=t._getEditorInstance=function(e,t){var n;if("function"==typeof e)p.get(e)||T(null,e),n=p.get(e);else{if("string"!=typeof e)throw Error('Only strings and functions can be passed as "editor" parameter');n=w(e)}if(n)return n.getInstance(t);throw Error('No editor registered under name "'.concat(e,'"'))},t.registerEditor=T,t.getEditor=function(e){if(C(e))return w(e).getConstructor();throw Error('No registered editor found under "'.concat(e,'" name'))},t.getRegisteredEditors=t.getRegisteredEditorNames=t.hasEditor=void 0;var o=r(n(78)),i=r(n(43)),a=r(n(104)),s=r(n(337)),l=r(n(538)),u=r(n(539)),c=r(n(544)),h=r(n(338)),d=r(n(545)),f=r(n(546)),g=r(n(547)),v=r(n(107)),p=new WeakMap,m=(0,o.default)("editors"),y=m.register,w=m.getItem,C=m.hasItem,E=m.getNames,S=m.getValues;function b(e){var t={},n=e;this.getConstructor=function(){return e},this.getInstance=function(e){return e.guid in t||(t[e.guid]=new n(e)),t[e.guid]},i.default.getSingleton().add("afterDestroy",function(){t[this.guid]=null})}function T(e,t){var n=new b(t);"string"==typeof e&&y(e,n),p.set(t,n)}t.getRegisteredEditors=S,t.getRegisteredEditorNames=E,t.hasEditor=C,T("base",a.default),T("autocomplete",s.default),T("checkbox",l.default),T("date",u.default),T("dropdown",c.default),T("handsontable",h.default),T("numeric",d.default),T("password",f.default),T("select",g.default),T("text",v.default)},function(e,t,n){"use strict";var r=n(69),o=[].join,i=n(113)!=Object,a=n(126)("join",",");n(22)({target:"Array",proto:!0,forced:i||a},{join:function(e){return o.call(r(this),void 0===e?",":e)}})},function(e,t,n){"use strict";t.__esModule=!0,t.log=function(){var e;(0,r.isDefined)(console)&&(e=console).log.apply(e,arguments)},t.warn=function(){var e;(0,r.isDefined)(console)&&(e=console).warn.apply(e,arguments)},t.info=function(){var e;(0,r.isDefined)(console)&&(e=console).info.apply(e,arguments)},t.error=function(){var e;(0,r.isDefined)(console)&&(e=console).error.apply(e,arguments)};var r=n(27)},function(e,t,n){"use strict";var r=n(102)(2),o=n(103)("filter");n(22)({target:"Array",proto:!0,forced:!o},{filter:function(e){return r(this,e,arguments[1])}})},function(e,t,n){"use strict";t.__esModule=!0,t.default=void 0;var i=n(3),r=n(4),o={_localHooks:Object.create(null),addLocalHook:function(e,t){return this._localHooks[e]||(this._localHooks[e]=[]),this._localHooks[e].push(t),this},runLocalHooks:function(e){for(var t=this,n=arguments.length,r=new Array(1<n?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];this._localHooks[e]&&(0,i.arrayEach)(this._localHooks[e],function(e){return e.apply(t,r)})},clearLocalHooks:function(){return this._localHooks={},this}};(0,r.defineGetter)(o,"MIXIN_NAME","localHooks",{writable:!1,enumerable:!1});var a=o;t.default=a},function(e,t){e.exports=function(e){if(null==e)throw TypeError("Can't call method on "+e);return e}},function(e,t,n){var r=!n(190)(function(e){Array.from(e)});n(22)({target:"Array",stat:!0,forced:r},{from:n(519)})},function(e,t,n){"use strict";n(18),n(12),n(40),n(51),n(37),t.__esModule=!0,t.normalizeSelection=function(e){return(0,o.arrayMap)(e,function(e){return{start:e.getTopLeftCorner(),end:e.getBottomRightCorner()}})},t.isSeparator=function(e){return(0,r.hasClass)(e,"htSeparator")},t.hasSubMenu=function(e){return(0,r.hasClass)(e,"htSubmenu")},t.isDisabled=function(e){return(0,r.hasClass)(e,"htDisabled")},t.isSelectionDisabled=function(e){return(0,r.hasClass)(e,"htSelectionDisabled")},t.getValidSelection=function(e){var t=e.getSelected();if(!t)return null;if(t[0]<0)return null;return t},t.prepareVerticalAlignClass=l,t.prepareHorizontalAlignClass=u,t.getAlignmentClasses=function(e,i){var a={};return(0,o.arrayEach)(e,function(e){for(var t=e.from,n=e.to,r=t.row;r<=n.row;r++)for(var o=t.col;o<=n.col;o++)a[r]||(a[r]=[]),a[r][o]=i(r,o)}),a},t.align=function(e,i,a,s,l){(0,o.arrayEach)(e,function(e){var t=e.from,n=e.to;if(t.row===n.row&&t.col===n.col)c(t.row,t.col,i,a,s,l);else for(var r=t.row;r<=n.row;r++)for(var o=t.col;o<=n.col;o++)c(r,o,i,a,s,l)})},t.checkSelectionConsistency=function(e,n){var r=!1;Array.isArray(e)&&(0,o.arrayEach)(e,function(e){return e.forAll(function(e,t){if(n(e,t))return!(r=!0)}),r});return r},t.markLabelAsSelected=function(e){return'<span class="selected">'.concat(String.fromCharCode(10003),"</span>").concat(e)},t.isItemHidden=function(e,t){return!e.hidden||!("function"==typeof e.hidden&&e.hidden.call(t))},t.filterSeparators=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:i.KEY,n=e.slice(0);return n=function(e){var n=[];return(0,o.arrayEach)(e,function(e,t){0<t?n[n.length-1].name!==e.name&&n.push(e):n.push(e)}),n}(n=function(e,t){var n=e.slice(0);return n.reverse(),(n=a(n,t)).reverse(),n}(n=a(n,t),t))};var o=n(3),r=n(5),i=n(166);function l(e,t){if(-1!==e.indexOf(t))return e;var n=e.replace("htTop","").replace("htMiddle","").replace("htBottom","").replace(" ","");return"".concat(n," ").concat(t)}function u(e,t){if(-1!==e.indexOf(t))return e;var n=e.replace("htLeft","").replace("htCenter","").replace("htRight","").replace("htJustify","").replace(" ","");return"".concat(n," ").concat(t)}function c(e,t,n,r,o,i){var a=o(e,t),s=r;a.className&&(s="vertical"===n?l(a.className,r):u(a.className,r)),i(e,t,"className",s)}function a(e,t){for(var n=e.slice(0);0<n.length&&n[0].name===t;)n.shift();return n}},function(e,t,n){var r=n(49),o=n(96);e.exports=n(52)?function(e,t,n){return r.f(e,t,o(1,n))}:function(e,t,n){return e[t]=n,e}},function(e,t,n){var r=n(58);e.exports=function(e){return Object(r(e))}},function(e,t,Kn){(function(Xn){Xn.exports=function(){"use strict";var t,o;function u(){return t.apply(null,arguments)}function a(e){return e instanceof Array||"[object Array]"===Object.prototype.toString.call(e)}function s(e){return null!=e&&"[object Object]"===Object.prototype.toString.call(e)}function i(e){return void 0===e}function l(e){return"number"==typeof e||"[object Number]"===Object.prototype.toString.call(e)}function c(e){return e instanceof Date||"[object Date]"===Object.prototype.toString.call(e)}function r(e,t){var n,r=[];for(n=0;n<e.length;++n)r.push(t(e[n],n));return r}function h(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function d(e,t){for(var n in t)h(t,n)&&(e[n]=t[n]);return h(t,"toString")&&(e.toString=t.toString),h(t,"valueOf")&&(e.valueOf=t.valueOf),e}function f(e,t,n,r){return At(e,t,n,r,!0).utc()}function g(e){return null==e._pf&&(e._pf={empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],meridiem:null,rfc2822:!1,weekdayMismatch:!1}),e._pf}function v(e){if(null==e._isValid){var t=g(e),n=o.call(t.parsedDateParts,function(e){return null!=e}),r=!isNaN(e._d.getTime())&&t.overflow<0&&!t.empty&&!t.invalidMonth&&!t.invalidWeekday&&!t.weekdayMismatch&&!t.nullInput&&!t.invalidFormat&&!t.userInvalidated&&(!t.meridiem||t.meridiem&&n);if(e._strict&&(r=r&&0===t.charsLeftOver&&0===t.unusedTokens.length&&void 0===t.bigHour),null!=Object.isFrozen&&Object.isFrozen(e))return r;e._isValid=r}return e._isValid}function p(e){var t=f(NaN);return null!=e?d(g(t),e):g(t).userInvalidated=!0,t}o=Array.prototype.some?Array.prototype.some:function(e){for(var t=Object(this),n=t.length>>>0,r=0;r<n;r++)if(r in t&&e.call(this,t[r],r,t))return!0;return!1};var m=u.momentProperties=[];function y(e,t){var n,r,o;if(i(t._isAMomentObject)||(e._isAMomentObject=t._isAMomentObject),i(t._i)||(e._i=t._i),i(t._f)||(e._f=t._f),i(t._l)||(e._l=t._l),i(t._strict)||(e._strict=t._strict),i(t._tzm)||(e._tzm=t._tzm),i(t._isUTC)||(e._isUTC=t._isUTC),i(t._offset)||(e._offset=t._offset),i(t._pf)||(e._pf=g(t)),i(t._locale)||(e._locale=t._locale),0<m.length)for(n=0;n<m.length;n++)r=m[n],i(o=t[r])||(e[r]=o);return e}var n=!1;function w(e){y(this,e),this._d=new Date(null!=e._d?e._d.getTime():NaN),this.isValid()||(this._d=new Date(NaN)),!1===n&&(n=!0,u.updateOffset(this),n=!1)}function C(e){return e instanceof w||null!=e&&null!=e._isAMomentObject}function E(e){return e<0?Math.ceil(e)||0:Math.floor(e)}function S(e){var t=+e,n=0;return 0!=t&&isFinite(t)&&(n=E(t)),n}function b(e,t,n){var r,o=Math.min(e.length,t.length),i=Math.abs(e.length-t.length),a=0;for(r=0;r<o;r++)(n&&e[r]!==t[r]||!n&&S(e[r])!==S(t[r]))&&a++;return a+i}function T(e){!1===u.suppressDeprecationWarnings&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+e)}function e(o,i){var a=!0;return d(function(){if(null!=u.deprecationHandler&&u.deprecationHandler(null,o),a){for(var e,t=[],n=0;n<arguments.length;n++){if(e="","object"==typeof arguments[n]){for(var r in e+="\n["+n+"] ",arguments[0])e+=r+": "+arguments[0][r]+", ";e=e.slice(0,-2)}else e=arguments[n];t.push(e)}T(o+"\nArguments: "+Array.prototype.slice.call(t).join("")+"\n"+(new Error).stack),a=!1}return i.apply(this,arguments)},i)}var R,_={};function k(e,t){null!=u.deprecationHandler&&u.deprecationHandler(e,t),_[e]||(T(t),_[e]=!0)}function O(e){return e instanceof Function||"[object Function]"===Object.prototype.toString.call(e)}function M(e,t){var n,r=d({},e);for(n in t)h(t,n)&&(s(e[n])&&s(t[n])?(r[n]={},d(r[n],e[n]),d(r[n],t[n])):null!=t[n]?r[n]=t[n]:delete r[n]);for(n in e)h(e,n)&&!h(t,n)&&s(e[n])&&(r[n]=d({},r[n]));return r}function N(e){null!=e&&this.set(e)}u.suppressDeprecationWarnings=!1,u.deprecationHandler=null,R=Object.keys?Object.keys:function(e){var t,n=[];for(t in e)h(e,t)&&n.push(t);return n};var A={};function I(e,t){var n=e.toLowerCase();A[n]=A[n+"s"]=A[t]=e}function D(e){return"string"==typeof e?A[e]||A[e.toLowerCase()]:void 0}function x(e){var t,n,r={};for(n in e)h(e,n)&&(t=D(n))&&(r[t]=e[n]);return r}var L={};function H(e,t){L[e]=t}function P(e){var t=[];for(var n in e)t.push({unit:n,priority:L[n]});return t.sort(function(e,t){return e.priority-t.priority}),t}function F(e,t,n){var r=""+Math.abs(e),o=t-r.length,i=0<=e;return(i?n?"+":"":"-")+Math.pow(10,Math.max(0,o)).toString().substr(1)+r}var V=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,B=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,W={},U={};function j(e,t,n,r){var o=r;"string"==typeof r&&(o=function(){return this[r]()}),e&&(U[e]=o),t&&(U[t[0]]=function(){return F(o.apply(this,arguments),t[1],t[2])}),n&&(U[n]=function(){return this.localeData().ordinal(o.apply(this,arguments),e)})}function Y(e){return e.match(/\[[\s\S]/)?e.replace(/^\[|\]$/g,""):e.replace(/\\/g,"")}function $(e,t){return e.isValid()?(t=G(t,e.localeData()),W[t]=W[t]||function(r){var e,o,i=r.match(V);for(e=0,o=i.length;e<o;e++)U[i[e]]?i[e]=U[i[e]]:i[e]=Y(i[e]);return function(e){var t,n="";for(t=0;t<o;t++)n+=O(i[t])?i[t].call(e,r):i[t];return n}}(t),W[t](e)):e.localeData().invalidDate()}function G(e,t){var n=5;function r(e){return t.longDateFormat(e)||e}for(B.lastIndex=0;0<=n&&B.test(e);)e=e.replace(B,r),B.lastIndex=0,n-=1;return e}var z=/\d/,X=/\d\d/,K=/\d{3}/,q=/\d{4}/,Z=/[+-]?\d{6}/,Q=/\d\d?/,J=/\d\d\d\d?/,ee=/\d\d\d\d\d\d?/,te=/\d{1,3}/,ne=/\d{1,4}/,re=/[+-]?\d{1,6}/,oe=/\d+/,ie=/[+-]?\d+/,ae=/Z|[+-]\d\d:?\d\d/gi,se=/Z|[+-]\d\d(?::?\d\d)?/gi,le=/[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,ue={};function ce(e,n,r){ue[e]=O(n)?n:function(e,t){return e&&r?r:n}}function he(e,t){return h(ue,e)?ue[e](t._strict,t._locale):new RegExp(function(e){return de(e.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(e,t,n,r,o){return t||n||r||o}))}(e))}function de(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}var fe={};function ge(e,n){var t,r=n;for("string"==typeof e&&(e=[e]),l(n)&&(r=function(e,t){t[n]=S(e)}),t=0;t<e.length;t++)fe[e[t]]=r}function ve(e,o){ge(e,function(e,t,n,r){n._w=n._w||{},o(e,n._w,n,r)})}function pe(e,t,n){null!=t&&h(fe,e)&&fe[e](t,n._a,n,e)}var me=0,ye=1,we=2,Ce=3,Ee=4,Se=5,be=6,Te=7,Re=8;function _e(e){return ke(e)?366:365}function ke(e){return e%4==0&&e%100!=0||e%400==0}j("Y",0,0,function(){var e=this.year();return e<=9999?""+e:"+"+e}),j(0,["YY",2],0,function(){return this.year()%100}),j(0,["YYYY",4],0,"year"),j(0,["YYYYY",5],0,"year"),j(0,["YYYYYY",6,!0],0,"year"),I("year","y"),H("year",1),ce("Y",ie),ce("YY",Q,X),ce("YYYY",ne,q),ce("YYYYY",re,Z),ce("YYYYYY",re,Z),ge(["YYYYY","YYYYYY"],me),ge("YYYY",function(e,t){t[me]=2===e.length?u.parseTwoDigitYear(e):S(e)}),ge("YY",function(e,t){t[me]=u.parseTwoDigitYear(e)}),ge("Y",function(e,t){t[me]=parseInt(e,10)}),u.parseTwoDigitYear=function(e){return S(e)+(68<S(e)?1900:2e3)};var Oe,Me=Ne("FullYear",!0);function Ne(t,n){return function(e){return null!=e?(Ie(this,t,e),u.updateOffset(this,n),this):Ae(this,t)}}function Ae(e,t){return e.isValid()?e._d["get"+(e._isUTC?"UTC":"")+t]():NaN}function Ie(e,t,n){e.isValid()&&!isNaN(n)&&("FullYear"===t&&ke(e.year())&&1===e.month()&&29===e.date()?e._d["set"+(e._isUTC?"UTC":"")+t](n,e.month(),De(n,e.month())):e._d["set"+(e._isUTC?"UTC":"")+t](n))}function De(e,t){if(isNaN(e)||isNaN(t))return NaN;var n=function(e,t){return(e%t+t)%t}(t,12);return e+=(t-n)/12,1===n?ke(e)?29:28:31-n%7%2}Oe=Array.prototype.indexOf?Array.prototype.indexOf:function(e){var t;for(t=0;t<this.length;++t)if(this[t]===e)return t;return-1},j("M",["MM",2],"Mo",function(){return this.month()+1}),j("MMM",0,0,function(e){return this.localeData().monthsShort(this,e)}),j("MMMM",0,0,function(e){return this.localeData().months(this,e)}),I("month","M"),H("month",8),ce("M",Q),ce("MM",Q,X),ce("MMM",function(e,t){return t.monthsShortRegex(e)}),ce("MMMM",function(e,t){return t.monthsRegex(e)}),ge(["M","MM"],function(e,t){t[ye]=S(e)-1}),ge(["MMM","MMMM"],function(e,t,n,r){var o=n._locale.monthsParse(e,r,n._strict);null!=o?t[ye]=o:g(n).invalidMonth=e});var xe=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,Le="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),He="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_");function Pe(e,t,n){var r,o,i,a=e.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],r=0;r<12;++r)i=f([2e3,r]),this._shortMonthsParse[r]=this.monthsShort(i,"").toLocaleLowerCase(),this._longMonthsParse[r]=this.months(i,"").toLocaleLowerCase();return n?"MMM"===t?-1!==(o=Oe.call(this._shortMonthsParse,a))?o:null:-1!==(o=Oe.call(this._longMonthsParse,a))?o:null:"MMM"===t?-1!==(o=Oe.call(this._shortMonthsParse,a))?o:-1!==(o=Oe.call(this._longMonthsParse,a))?o:null:-1!==(o=Oe.call(this._longMonthsParse,a))?o:-1!==(o=Oe.call(this._shortMonthsParse,a))?o:null}function Fe(e,t){var n;if(!e.isValid())return e;if("string"==typeof t)if(/^\d+$/.test(t))t=S(t);else if(!l(t=e.localeData().monthsParse(t)))return e;return n=Math.min(e.date(),De(e.year(),t)),e._d["set"+(e._isUTC?"UTC":"")+"Month"](t,n),e}function Ve(e){return null!=e?(Fe(this,e),u.updateOffset(this,!0),this):Ae(this,"Month")}var Be=le,We=le;function Ue(){function e(e,t){return t.length-e.length}var t,n,r=[],o=[],i=[];for(t=0;t<12;t++)n=f([2e3,t]),r.push(this.monthsShort(n,"")),o.push(this.months(n,"")),i.push(this.months(n,"")),i.push(this.monthsShort(n,""));for(r.sort(e),o.sort(e),i.sort(e),t=0;t<12;t++)r[t]=de(r[t]),o[t]=de(o[t]);for(t=0;t<24;t++)i[t]=de(i[t]);this._monthsRegex=new RegExp("^("+i.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+o.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+r.join("|")+")","i")}function je(e){var t=new Date(Date.UTC.apply(null,arguments));return e<100&&0<=e&&isFinite(t.getUTCFullYear())&&t.setUTCFullYear(e),t}function Ye(e,t,n){var r=7+t-n,o=(7+je(e,0,r).getUTCDay()-t)%7;return r-o-1}function $e(e,t,n,r,o){var i,a,s=(7+n-r)%7,l=Ye(e,r,o),u=1+7*(t-1)+s+l;return a=u<=0?_e(i=e-1)+u:u>_e(e)?(i=e+1,u-_e(e)):(i=e,u),{year:i,dayOfYear:a}}function Ge(e,t,n){var r,o,i=Ye(e.year(),t,n),a=Math.floor((e.dayOfYear()-i-1)/7)+1;return a<1?(o=e.year()-1,r=a+ze(o,t,n)):a>ze(e.year(),t,n)?(r=a-ze(e.year(),t,n),o=e.year()+1):(o=e.year(),r=a),{week:r,year:o}}function ze(e,t,n){var r=Ye(e,t,n),o=Ye(e+1,t,n);return(_e(e)-r+o)/7}j("w",["ww",2],"wo","week"),j("W",["WW",2],"Wo","isoWeek"),I("week","w"),I("isoWeek","W"),H("week",5),H("isoWeek",5),ce("w",Q),ce("ww",Q,X),ce("W",Q),ce("WW",Q,X),ve(["w","ww","W","WW"],function(e,t,n,r){t[r.substr(0,1)]=S(e)}),j("d",0,"do","day"),j("dd",0,0,function(e){return this.localeData().weekdaysMin(this,e)}),j("ddd",0,0,function(e){return this.localeData().weekdaysShort(this,e)}),j("dddd",0,0,function(e){return this.localeData().weekdays(this,e)}),j("e",0,0,"weekday"),j("E",0,0,"isoWeekday"),I("day","d"),I("weekday","e"),I("isoWeekday","E"),H("day",11),H("weekday",11),H("isoWeekday",11),ce("d",Q),ce("e",Q),ce("E",Q),ce("dd",function(e,t){return t.weekdaysMinRegex(e)}),ce("ddd",function(e,t){return t.weekdaysShortRegex(e)}),ce("dddd",function(e,t){return t.weekdaysRegex(e)}),ve(["dd","ddd","dddd"],function(e,t,n,r){var o=n._locale.weekdaysParse(e,r,n._strict);null!=o?t.d=o:g(n).invalidWeekday=e}),ve(["d","e","E"],function(e,t,n,r){t[r]=S(e)});var Xe="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Ke="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),qe="Su_Mo_Tu_We_Th_Fr_Sa".split("_");function Ze(e,t,n){var r,o,i,a=e.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],r=0;r<7;++r)i=f([2e3,1]).day(r),this._minWeekdaysParse[r]=this.weekdaysMin(i,"").toLocaleLowerCase(),this._shortWeekdaysParse[r]=this.weekdaysShort(i,"").toLocaleLowerCase(),this._weekdaysParse[r]=this.weekdays(i,"").toLocaleLowerCase();return n?"dddd"===t?-1!==(o=Oe.call(this._weekdaysParse,a))?o:null:"ddd"===t?-1!==(o=Oe.call(this._shortWeekdaysParse,a))?o:null:-1!==(o=Oe.call(this._minWeekdaysParse,a))?o:null:"dddd"===t?-1!==(o=Oe.call(this._weekdaysParse,a))?o:-1!==(o=Oe.call(this._shortWeekdaysParse,a))?o:-1!==(o=Oe.call(this._minWeekdaysParse,a))?o:null:"ddd"===t?-1!==(o=Oe.call(this._shortWeekdaysParse,a))?o:-1!==(o=Oe.call(this._weekdaysParse,a))?o:-1!==(o=Oe.call(this._minWeekdaysParse,a))?o:null:-1!==(o=Oe.call(this._minWeekdaysParse,a))?o:-1!==(o=Oe.call(this._weekdaysParse,a))?o:-1!==(o=Oe.call(this._shortWeekdaysParse,a))?o:null}var Qe=le,Je=le,et=le;function tt(){function e(e,t){return t.length-e.length}var t,n,r,o,i,a=[],s=[],l=[],u=[];for(t=0;t<7;t++)n=f([2e3,1]).day(t),r=this.weekdaysMin(n,""),o=this.weekdaysShort(n,""),i=this.weekdays(n,""),a.push(r),s.push(o),l.push(i),u.push(r),u.push(o),u.push(i);for(a.sort(e),s.sort(e),l.sort(e),u.sort(e),t=0;t<7;t++)s[t]=de(s[t]),l[t]=de(l[t]),u[t]=de(u[t]);this._weekdaysRegex=new RegExp("^("+u.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+l.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+s.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+a.join("|")+")","i")}function nt(){return this.hours()%12||12}function rt(e,t){j(e,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),t)})}function ot(e,t){return t._meridiemParse}j("H",["HH",2],0,"hour"),j("h",["hh",2],0,nt),j("k",["kk",2],0,function(){return this.hours()||24}),j("hmm",0,0,function(){return""+nt.apply(this)+F(this.minutes(),2)}),j("hmmss",0,0,function(){return""+nt.apply(this)+F(this.minutes(),2)+F(this.seconds(),2)}),j("Hmm",0,0,function(){return""+this.hours()+F(this.minutes(),2)}),j("Hmmss",0,0,function(){return""+this.hours()+F(this.minutes(),2)+F(this.seconds(),2)}),rt("a",!0),rt("A",!1),I("hour","h"),H("hour",13),ce("a",ot),ce("A",ot),ce("H",Q),ce("h",Q),ce("k",Q),ce("HH",Q,X),ce("hh",Q,X),ce("kk",Q,X),ce("hmm",J),ce("hmmss",ee),ce("Hmm",J),ce("Hmmss",ee),ge(["H","HH"],Ce),ge(["k","kk"],function(e,t,n){var r=S(e);t[Ce]=24===r?0:r}),ge(["a","A"],function(e,t,n){n._isPm=n._locale.isPM(e),n._meridiem=e}),ge(["h","hh"],function(e,t,n){t[Ce]=S(e),g(n).bigHour=!0}),ge("hmm",function(e,t,n){var r=e.length-2;t[Ce]=S(e.substr(0,r)),t[Ee]=S(e.substr(r)),g(n).bigHour=!0}),ge("hmmss",function(e,t,n){var r=e.length-4,o=e.length-2;t[Ce]=S(e.substr(0,r)),t[Ee]=S(e.substr(r,2)),t[Se]=S(e.substr(o)),g(n).bigHour=!0}),ge("Hmm",function(e,t,n){var r=e.length-2;t[Ce]=S(e.substr(0,r)),t[Ee]=S(e.substr(r))}),ge("Hmmss",function(e,t,n){var r=e.length-4,o=e.length-2;t[Ce]=S(e.substr(0,r)),t[Ee]=S(e.substr(r,2)),t[Se]=S(e.substr(o))});var it,at=Ne("Hours",!0),st={calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},longDateFormat:{LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},invalidDate:"Invalid date",ordinal:"%d",dayOfMonthOrdinalParse:/\d{1,2}/,relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},months:Le,monthsShort:He,week:{dow:0,doy:6},weekdays:Xe,weekdaysMin:qe,weekdaysShort:Ke,meridiemParse:/[ap]\.?m?\.?/i},lt={},ut={};function ct(e){return e?e.toLowerCase().replace("_","-"):e}function ht(e){var t=null;if(!lt[e]&&void 0!==Xn&&Xn&&Xn.exports)try{t=it._abbr,Kn(527)("./"+e),dt(t)}catch(e){}return lt[e]}function dt(e,t){var n;return e&&(n=i(t)?gt(e):ft(e,t))&&(it=n),it._abbr}function ft(e,t){if(null===t)return delete lt[e],null;var n=st;if(t.abbr=e,null!=lt[e])k("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),n=lt[e]._config;else if(null!=t.parentLocale){if(null==lt[t.parentLocale])return ut[t.parentLocale]||(ut[t.parentLocale]=[]),ut[t.parentLocale].push({name:e,config:t}),null;n=lt[t.parentLocale]._config}return lt[e]=new N(M(n,t)),ut[e]&&ut[e].forEach(function(e){ft(e.name,e.config)}),dt(e),lt[e]}function gt(e){var t;if(e&&e._locale&&e._locale._abbr&&(e=e._locale._abbr),!e)return it;if(!a(e)){if(t=ht(e))return t;e=[e]}return function(e){for(var t,n,r,o,i=0;i<e.length;){for(o=ct(e[i]).split("-"),t=o.length,n=(n=ct(e[i+1]))?n.split("-"):null;0<t;){if(r=ht(o.slice(0,t).join("-")))return r;if(n&&n.length>=t&&b(o,n,!0)>=t-1)break;t--}i++}return null}(e)}function vt(e){var t,n=e._a;return n&&-2===g(e).overflow&&(t=n[ye]<0||11<n[ye]?ye:n[we]<1||n[we]>De(n[me],n[ye])?we:n[Ce]<0||24<n[Ce]||24===n[Ce]&&(0!==n[Ee]||0!==n[Se]||0!==n[be])?Ce:n[Ee]<0||59<n[Ee]?Ee:n[Se]<0||59<n[Se]?Se:n[be]<0||999<n[be]?be:-1,g(e)._overflowDayOfYear&&(t<me||we<t)&&(t=we),g(e)._overflowWeeks&&-1===t&&(t=Te),g(e)._overflowWeekday&&-1===t&&(t=Re),g(e).overflow=t),e}function pt(e,t,n){return null!=e?e:null!=t?t:n}function mt(e){var t,n,r,o,i,a=[];if(!e._d){for(r=function(e){var t=new Date(u.now());return e._useUTC?[t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate()]:[t.getFullYear(),t.getMonth(),t.getDate()]}(e),e._w&&null==e._a[we]&&null==e._a[ye]&&function(e){var t,n,r,o,i,a,s,l;if(null!=(t=e._w).GG||null!=t.W||null!=t.E)i=1,a=4,n=pt(t.GG,e._a[me],Ge(It(),1,4).year),r=pt(t.W,1),((o=pt(t.E,1))<1||7<o)&&(l=!0);else{i=e._locale._week.dow,a=e._locale._week.doy;var u=Ge(It(),i,a);n=pt(t.gg,e._a[me],u.year),r=pt(t.w,u.week),null!=t.d?((o=t.d)<0||6<o)&&(l=!0):null!=t.e?(o=t.e+i,(t.e<0||6<t.e)&&(l=!0)):o=i}r<1||r>ze(n,i,a)?g(e)._overflowWeeks=!0:null!=l?g(e)._overflowWeekday=!0:(s=$e(n,r,o,i,a),e._a[me]=s.year,e._dayOfYear=s.dayOfYear)}(e),null!=e._dayOfYear&&(i=pt(e._a[me],r[me]),(e._dayOfYear>_e(i)||0===e._dayOfYear)&&(g(e)._overflowDayOfYear=!0),n=je(i,0,e._dayOfYear),e._a[ye]=n.getUTCMonth(),e._a[we]=n.getUTCDate()),t=0;t<3&&null==e._a[t];++t)e._a[t]=a[t]=r[t];for(;t<7;t++)e._a[t]=a[t]=null==e._a[t]?2===t?1:0:e._a[t];24===e._a[Ce]&&0===e._a[Ee]&&0===e._a[Se]&&0===e._a[be]&&(e._nextDay=!0,e._a[Ce]=0),e._d=(e._useUTC?je:function(e,t,n,r,o,i,a){var s=new Date(e,t,n,r,o,i,a);return e<100&&0<=e&&isFinite(s.getFullYear())&&s.setFullYear(e),s}).apply(null,a),o=e._useUTC?e._d.getUTCDay():e._d.getDay(),null!=e._tzm&&e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),e._nextDay&&(e._a[Ce]=24),e._w&&void 0!==e._w.d&&e._w.d!==o&&(g(e).weekdayMismatch=!0)}}var yt=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,wt=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,Ct=/Z|[+-]\d\d(?::?\d\d)?/,Et=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/]],St=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],bt=/^\/?Date\((\-?\d+)/i;function Tt(e){var t,n,r,o,i,a,s=e._i,l=yt.exec(s)||wt.exec(s);if(l){for(g(e).iso=!0,t=0,n=Et.length;t<n;t++)if(Et[t][1].exec(l[1])){o=Et[t][0],r=!1!==Et[t][2];break}if(null==o)return void(e._isValid=!1);if(l[3]){for(t=0,n=St.length;t<n;t++)if(St[t][1].exec(l[3])){i=(l[2]||" ")+St[t][0];break}if(null==i)return void(e._isValid=!1)}if(!r&&null!=i)return void(e._isValid=!1);if(l[4]){if(!Ct.exec(l[4]))return void(e._isValid=!1);a="Z"}e._f=o+(i||"")+(a||""),Mt(e)}else e._isValid=!1}var Rt=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/;function _t(e,t,n,r,o,i){var a=[function(e){var t=parseInt(e,10);return t<=49?2e3+t:t<=999?1900+t:t}(e),He.indexOf(t),parseInt(n,10),parseInt(r,10),parseInt(o,10)];return i&&a.push(parseInt(i,10)),a}var kt={UT:0,GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function Ot(e){var t=Rt.exec(function(e){return e.replace(/\([^)]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}(e._i));if(t){var n=_t(t[4],t[3],t[2],t[5],t[6],t[7]);if(!function(e,t,n){if(e){var r=Ke.indexOf(e),o=new Date(t[0],t[1],t[2]).getDay();if(r!==o)return g(n).weekdayMismatch=!0,n._isValid=!1}return!0}(t[1],n,e))return;e._a=n,e._tzm=function(e,t,n){if(e)return kt[e];if(t)return 0;var r=parseInt(n,10),o=r%100,i=(r-o)/100;return 60*i+o}(t[8],t[9],t[10]),e._d=je.apply(null,e._a),e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),g(e).rfc2822=!0}else e._isValid=!1}function Mt(e){if(e._f!==u.ISO_8601)if(e._f!==u.RFC_2822){e._a=[],g(e).empty=!0;var t,n,r,o,i,a=""+e._i,s=a.length,l=0;for(r=G(e._f,e._locale).match(V)||[],t=0;t<r.length;t++)o=r[t],(n=(a.match(he(o,e))||[])[0])&&(0<(i=a.substr(0,a.indexOf(n))).length&&g(e).unusedInput.push(i),a=a.slice(a.indexOf(n)+n.length),l+=n.length),U[o]?(n?g(e).empty=!1:g(e).unusedTokens.push(o),pe(o,n,e)):e._strict&&!n&&g(e).unusedTokens.push(o);g(e).charsLeftOver=s-l,0<a.length&&g(e).unusedInput.push(a),e._a[Ce]<=12&&!0===g(e).bigHour&&0<e._a[Ce]&&(g(e).bigHour=void 0),g(e).parsedDateParts=e._a.slice(0),g(e).meridiem=e._meridiem,e._a[Ce]=function(e,t,n){var r;return null==n?t:null!=e.meridiemHour?e.meridiemHour(t,n):(null!=e.isPM&&((r=e.isPM(n))&&t<12&&(t+=12),r||12!==t||(t=0)),t)}(e._locale,e._a[Ce],e._meridiem),mt(e),vt(e)}else Ot(e);else Tt(e)}function Nt(e){var t=e._i,n=e._f;return e._locale=e._locale||gt(e._l),null===t||void 0===n&&""===t?p({nullInput:!0}):("string"==typeof t&&(e._i=t=e._locale.preparse(t)),C(t)?new w(vt(t)):(c(t)?e._d=t:a(n)?function(e){var t,n,r,o,i;if(0===e._f.length)return g(e).invalidFormat=!0,e._d=new Date(NaN);for(o=0;o<e._f.length;o++)i=0,t=y({},e),null!=e._useUTC&&(t._useUTC=e._useUTC),t._f=e._f[o],Mt(t),v(t)&&(i+=g(t).charsLeftOver,i+=10*g(t).unusedTokens.length,g(t).score=i,(null==r||i<r)&&(r=i,n=t));d(e,n||t)}(e):n?Mt(e):function(e){var t=e._i;i(t)?e._d=new Date(u.now()):c(t)?e._d=new Date(t.valueOf()):"string"==typeof t?function(e){var t=bt.exec(e._i);if(null!==t)return e._d=new Date(+t[1]);Tt(e),!1===e._isValid&&(delete e._isValid,Ot(e),!1===e._isValid&&(delete e._isValid,u.createFromInputFallback(e)))}(e):a(t)?(e._a=r(t.slice(0),function(e){return parseInt(e,10)}),mt(e)):s(t)?function(e){if(!e._d){var t=x(e._i);e._a=r([t.year,t.month,t.day||t.date,t.hour,t.minute,t.second,t.millisecond],function(e){return e&&parseInt(e,10)}),mt(e)}}(e):l(t)?e._d=new Date(t):u.createFromInputFallback(e)}(e),v(e)||(e._d=null),e))}function At(e,t,n,r,o){var i={};return!0!==n&&!1!==n||(r=n,n=void 0),(s(e)&&function(e){if(Object.getOwnPropertyNames)return 0===Object.getOwnPropertyNames(e).length;var t;for(t in e)if(e.hasOwnProperty(t))return!1;return!0}(e)||a(e)&&0===e.length)&&(e=void 0),i._isAMomentObject=!0,i._useUTC=i._isUTC=o,i._l=n,i._i=e,i._f=t,i._strict=r,function(e){var t=new w(vt(Nt(e)));return t._nextDay&&(t.add(1,"d"),t._nextDay=void 0),t}(i)}function It(e,t,n,r){return At(e,t,n,r,!1)}u.createFromInputFallback=e("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged and will be removed in an upcoming major release. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",function(e){e._d=new Date(e._i+(e._useUTC?" UTC":""))}),u.ISO_8601=function(){},u.RFC_2822=function(){};var Dt=e("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var e=It.apply(null,arguments);return this.isValid()&&e.isValid()?e<this?this:e:p()}),xt=e("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var e=It.apply(null,arguments);return this.isValid()&&e.isValid()?this<e?this:e:p()});function Lt(e,t){var n,r;if(1===t.length&&a(t[0])&&(t=t[0]),!t.length)return It();for(n=t[0],r=1;r<t.length;++r)t[r].isValid()&&!t[r][e](n)||(n=t[r]);return n}var Ht=["year","quarter","month","week","day","hour","minute","second","millisecond"];function Pt(e){var t=x(e),n=t.year||0,r=t.quarter||0,o=t.month||0,i=t.week||0,a=t.day||0,s=t.hour||0,l=t.minute||0,u=t.second||0,c=t.millisecond||0;this._isValid=function(e){for(var t in e)if(-1===Oe.call(Ht,t)||null!=e[t]&&isNaN(e[t]))return!1;for(var n=!1,r=0;r<Ht.length;++r)if(e[Ht[r]]){if(n)return!1;parseFloat(e[Ht[r]])!==S(e[Ht[r]])&&(n=!0)}return!0}(t),this._milliseconds=+c+1e3*u+6e4*l+1e3*s*60*60,this._days=+a+7*i,this._months=+o+3*r+12*n,this._data={},this._locale=gt(),this._bubble()}function Ft(e){return e instanceof Pt}function Vt(e){return e<0?-1*Math.round(-1*e):Math.round(e)}function Bt(e,n){j(e,0,0,function(){var e=this.utcOffset(),t="+";return e<0&&(e=-e,t="-"),t+F(~~(e/60),2)+n+F(~~e%60,2)})}Bt("Z",":"),Bt("ZZ",""),ce("Z",se),ce("ZZ",se),ge(["Z","ZZ"],function(e,t,n){n._useUTC=!0,n._tzm=Ut(se,e)});var Wt=/([\+\-]|\d\d)/gi;function Ut(e,t){var n=(t||"").match(e);if(null===n)return null;var r=n[n.length-1]||[],o=(r+"").match(Wt)||["-",0,0],i=60*o[1]+S(o[2]);return 0===i?0:"+"===o[0]?i:-i}function jt(e,t){var n,r;return t._isUTC?(n=t.clone(),r=(C(e)||c(e)?e.valueOf():It(e).valueOf())-n.valueOf(),n._d.setTime(n._d.valueOf()+r),u.updateOffset(n,!1),n):It(e).local()}function Yt(e){return 15*-Math.round(e._d.getTimezoneOffset()/15)}function $t(){return!!this.isValid()&&this._isUTC&&0===this._offset}u.updateOffset=function(){};var Gt=/^(\-|\+)?(?:(\d*)[. ])?(\d+)\:(\d+)(?:\:(\d+)(\.\d*)?)?$/,zt=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function Xt(e,t){var n,r,o,i=e,a=null;return Ft(e)?i={ms:e._milliseconds,d:e._days,M:e._months}:l(e)?(i={},t?i[t]=e:i.milliseconds=e):(a=Gt.exec(e))?(n="-"===a[1]?-1:1,i={y:0,d:S(a[we])*n,h:S(a[Ce])*n,m:S(a[Ee])*n,s:S(a[Se])*n,ms:S(Vt(1e3*a[be]))*n}):(a=zt.exec(e))?(n="-"===a[1]?-1:(a[1],1),i={y:Kt(a[2],n),M:Kt(a[3],n),w:Kt(a[4],n),d:Kt(a[5],n),h:Kt(a[6],n),m:Kt(a[7],n),s:Kt(a[8],n)}):null==i?i={}:"object"==typeof i&&("from"in i||"to"in i)&&(o=function(e,t){var n;return e.isValid()&&t.isValid()?(t=jt(t,e),e.isBefore(t)?n=qt(e,t):((n=qt(t,e)).milliseconds=-n.milliseconds,n.months=-n.months),n):{milliseconds:0,months:0}}(It(i.from),It(i.to)),(i={}).ms=o.milliseconds,i.M=o.months),r=new Pt(i),Ft(e)&&h(e,"_locale")&&(r._locale=e._locale),r}function Kt(e,t){var n=e&&parseFloat(e.replace(",","."));return(isNaN(n)?0:n)*t}function qt(e,t){var n={milliseconds:0,months:0};return n.months=t.month()-e.month()+12*(t.year()-e.year()),e.clone().add(n.months,"M").isAfter(t)&&--n.months,n.milliseconds=+t-+e.clone().add(n.months,"M"),n}function Zt(r,o){return function(e,t){var n;return null===t||isNaN(+t)||(k(o,"moment()."+o+"(period, number) is deprecated. Please use moment()."+o+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),n=e,e=t,t=n),Qt(this,Xt(e="string"==typeof e?+e:e,t),r),this}}function Qt(e,t,n,r){var o=t._milliseconds,i=Vt(t._days),a=Vt(t._months);e.isValid()&&(r=null==r||r,a&&Fe(e,Ae(e,"Month")+a*n),i&&Ie(e,"Date",Ae(e,"Date")+i*n),o&&e._d.setTime(e._d.valueOf()+o*n),r&&u.updateOffset(e,i||a))}Xt.fn=Pt.prototype,Xt.invalid=function(){return Xt(NaN)};var Jt=Zt(1,"add"),en=Zt(-1,"subtract");function tn(e,t){var n,r,o=12*(t.year()-e.year())+(t.month()-e.month()),i=e.clone().add(o,"months");return r=t-i<0?(n=e.clone().add(o-1,"months"),(t-i)/(i-n)):(n=e.clone().add(1+o,"months"),(t-i)/(n-i)),-(o+r)||0}function nn(e){var t;return void 0===e?this._locale._abbr:(null!=(t=gt(e))&&(this._locale=t),this)}u.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",u.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";var rn=e("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(e){return void 0===e?this.localeData():this.locale(e)});function on(){return this._locale}function an(e,t){j(0,[e,e.length],0,t)}function sn(e,t,n,r,o){var i;return null==e?Ge(this,r,o).year:((i=ze(e,r,o))<t&&(t=i),function(e,t,n,r,o){var i=$e(e,t,n,r,o),a=je(i.year,0,i.dayOfYear);return this.year(a.getUTCFullYear()),this.month(a.getUTCMonth()),this.date(a.getUTCDate()),this}.call(this,e,t,n,r,o))}j(0,["gg",2],0,function(){return this.weekYear()%100}),j(0,["GG",2],0,function(){return this.isoWeekYear()%100}),an("gggg","weekYear"),an("ggggg","weekYear"),an("GGGG","isoWeekYear"),an("GGGGG","isoWeekYear"),I("weekYear","gg"),I("isoWeekYear","GG"),H("weekYear",1),H("isoWeekYear",1),ce("G",ie),ce("g",ie),ce("GG",Q,X),ce("gg",Q,X),ce("GGGG",ne,q),ce("gggg",ne,q),ce("GGGGG",re,Z),ce("ggggg",re,Z),ve(["gggg","ggggg","GGGG","GGGGG"],function(e,t,n,r){t[r.substr(0,2)]=S(e)}),ve(["gg","GG"],function(e,t,n,r){t[r]=u.parseTwoDigitYear(e)}),j("Q",0,"Qo","quarter"),I("quarter","Q"),H("quarter",7),ce("Q",z),ge("Q",function(e,t){t[ye]=3*(S(e)-1)}),j("D",["DD",2],"Do","date"),I("date","D"),H("date",9),ce("D",Q),ce("DD",Q,X),ce("Do",function(e,t){return e?t._dayOfMonthOrdinalParse||t._ordinalParse:t._dayOfMonthOrdinalParseLenient}),ge(["D","DD"],we),ge("Do",function(e,t){t[we]=S(e.match(Q)[0])});var ln=Ne("Date",!0);j("DDD",["DDDD",3],"DDDo","dayOfYear"),I("dayOfYear","DDD"),H("dayOfYear",4),ce("DDD",te),ce("DDDD",K),ge(["DDD","DDDD"],function(e,t,n){n._dayOfYear=S(e)}),j("m",["mm",2],0,"minute"),I("minute","m"),H("minute",14),ce("m",Q),ce("mm",Q,X),ge(["m","mm"],Ee);var un=Ne("Minutes",!1);j("s",["ss",2],0,"second"),I("second","s"),H("second",15),ce("s",Q),ce("ss",Q,X),ge(["s","ss"],Se);var cn,hn=Ne("Seconds",!1);for(j("S",0,0,function(){return~~(this.millisecond()/100)}),j(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),j(0,["SSS",3],0,"millisecond"),j(0,["SSSS",4],0,function(){return 10*this.millisecond()}),j(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),j(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),j(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),j(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),j(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),I("millisecond","ms"),H("millisecond",16),ce("S",te,z),ce("SS",te,X),ce("SSS",te,K),cn="SSSS";cn.length<=9;cn+="S")ce(cn,oe);function dn(e,t){t[be]=S(1e3*("0."+e))}for(cn="S";cn.length<=9;cn+="S")ge(cn,dn);var fn=Ne("Milliseconds",!1);j("z",0,0,"zoneAbbr"),j("zz",0,0,"zoneName");var gn=w.prototype;function vn(e){return e}gn.add=Jt,gn.calendar=function(e,t){var n=e||It(),r=jt(n,this).startOf("day"),o=u.calendarFormat(this,r)||"sameElse",i=t&&(O(t[o])?t[o].call(this,n):t[o]);return this.format(i||this.localeData().calendar(o,this,It(n)))},gn.clone=function(){return new w(this)},gn.diff=function(e,t,n){var r,o,i;if(!this.isValid())return NaN;if(!(r=jt(e,this)).isValid())return NaN;switch(o=6e4*(r.utcOffset()-this.utcOffset()),t=D(t)){case"year":i=tn(this,r)/12;break;case"month":i=tn(this,r);break;case"quarter":i=tn(this,r)/3;break;case"second":i=(this-r)/1e3;break;case"minute":i=(this-r)/6e4;break;case"hour":i=(this-r)/36e5;break;case"day":i=(this-r-o)/864e5;break;case"week":i=(this-r-o)/6048e5;break;default:i=this-r}return n?i:E(i)},gn.endOf=function(e){return void 0===(e=D(e))||"millisecond"===e?this:("date"===e&&(e="day"),this.startOf(e).add(1,"isoWeek"===e?"week":e).subtract(1,"ms"))},gn.format=function(e){e||(e=this.isUtc()?u.defaultFormatUtc:u.defaultFormat);var t=$(this,e);return this.localeData().postformat(t)},gn.from=function(e,t){return this.isValid()&&(C(e)&&e.isValid()||It(e).isValid())?Xt({to:this,from:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()},gn.fromNow=function(e){return this.from(It(),e)},gn.to=function(e,t){return this.isValid()&&(C(e)&&e.isValid()||It(e).isValid())?Xt({from:this,to:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()},gn.toNow=function(e){return this.to(It(),e)},gn.get=function(e){return O(this[e=D(e)])?this[e]():this},gn.invalidAt=function(){return g(this).overflow},gn.isAfter=function(e,t){var n=C(e)?e:It(e);return!(!this.isValid()||!n.isValid())&&("millisecond"===(t=D(i(t)?"millisecond":t))?this.valueOf()>n.valueOf():n.valueOf()<this.clone().startOf(t).valueOf())},gn.isBefore=function(e,t){var n=C(e)?e:It(e);return!(!this.isValid()||!n.isValid())&&("millisecond"===(t=D(i(t)?"millisecond":t))?this.valueOf()<n.valueOf():this.clone().endOf(t).valueOf()<n.valueOf())},gn.isBetween=function(e,t,n,r){return("("===(r=r||"()")[0]?this.isAfter(e,n):!this.isBefore(e,n))&&(")"===r[1]?this.isBefore(t,n):!this.isAfter(t,n))},gn.isSame=function(e,t){var n,r=C(e)?e:It(e);return!(!this.isValid()||!r.isValid())&&("millisecond"===(t=D(t||"millisecond"))?this.valueOf()===r.valueOf():(n=r.valueOf(),this.clone().startOf(t).valueOf()<=n&&n<=this.clone().endOf(t).valueOf()))},gn.isSameOrAfter=function(e,t){return this.isSame(e,t)||this.isAfter(e,t)},gn.isSameOrBefore=function(e,t){return this.isSame(e,t)||this.isBefore(e,t)},gn.isValid=function(){return v(this)},gn.lang=rn,gn.locale=nn,gn.localeData=on,gn.max=xt,gn.min=Dt,gn.parsingFlags=function(){return d({},g(this))},gn.set=function(e,t){if("object"==typeof e)for(var n=P(e=x(e)),r=0;r<n.length;r++)this[n[r].unit](e[n[r].unit]);else if(O(this[e=D(e)]))return this[e](t);return this},gn.startOf=function(e){switch(e=D(e)){case"year":this.month(0);case"quarter":case"month":this.date(1);case"week":case"isoWeek":case"day":case"date":this.hours(0);case"hour":this.minutes(0);case"minute":this.seconds(0);case"second":this.milliseconds(0)}return"week"===e&&this.weekday(0),"isoWeek"===e&&this.isoWeekday(1),"quarter"===e&&this.month(3*Math.floor(this.month()/3)),this},gn.subtract=en,gn.toArray=function(){var e=this;return[e.year(),e.month(),e.date(),e.hour(),e.minute(),e.second(),e.millisecond()]},gn.toObject=function(){var e=this;return{years:e.year(),months:e.month(),date:e.date(),hours:e.hours(),minutes:e.minutes(),seconds:e.seconds(),milliseconds:e.milliseconds()}},gn.toDate=function(){return new Date(this.valueOf())},gn.toISOString=function(e){if(!this.isValid())return null;var t=!0!==e,n=t?this.clone().utc():this;return n.year()<0||9999<n.year()?$(n,t?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):O(Date.prototype.toISOString)?t?this.toDate().toISOString():new Date(this._d.valueOf()).toISOString().replace("Z",$(n,"Z")):$(n,t?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")},gn.inspect=function(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var e="moment",t="";this.isLocal()||(e=0===this.utcOffset()?"moment.utc":"moment.parseZone",t="Z");var n="["+e+'("]',r=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY",o=t+'[")]';return this.format(n+r+"-MM-DD[T]HH:mm:ss.SSS"+o)},gn.toJSON=function(){return this.isValid()?this.toISOString():null},gn.toString=function(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")},gn.unix=function(){return Math.floor(this.valueOf()/1e3)},gn.valueOf=function(){return this._d.valueOf()-6e4*(this._offset||0)},gn.creationData=function(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}},gn.year=Me,gn.isLeapYear=function(){return ke(this.year())},gn.weekYear=function(e){return sn.call(this,e,this.week(),this.weekday(),this.localeData()._week.dow,this.localeData()._week.doy)},gn.isoWeekYear=function(e){return sn.call(this,e,this.isoWeek(),this.isoWeekday(),1,4)},gn.quarter=gn.quarters=function(e){return null==e?Math.ceil((this.month()+1)/3):this.month(3*(e-1)+this.month()%3)},gn.month=Ve,gn.daysInMonth=function(){return De(this.year(),this.month())},gn.week=gn.weeks=function(e){var t=this.localeData().week(this);return null==e?t:this.add(7*(e-t),"d")},gn.isoWeek=gn.isoWeeks=function(e){var t=Ge(this,1,4).week;return null==e?t:this.add(7*(e-t),"d")},gn.weeksInYear=function(){var e=this.localeData()._week;return ze(this.year(),e.dow,e.doy)},gn.isoWeeksInYear=function(){return ze(this.year(),1,4)},gn.date=ln,gn.day=gn.days=function(e){if(!this.isValid())return null!=e?this:NaN;var t,n,r=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=e?(t=e,n=this.localeData(),e="string"==typeof t?isNaN(t)?"number"!=typeof(t=n.weekdaysParse(t))?null:t:parseInt(t,10):t,this.add(e-r,"d")):r},gn.weekday=function(e){if(!this.isValid())return null!=e?this:NaN;var t=(this.day()+7-this.localeData()._week.dow)%7;return null==e?t:this.add(e-t,"d")},gn.isoWeekday=function(e){if(!this.isValid())return null!=e?this:NaN;if(null==e)return this.day()||7;var t,n,r=(t=e,n=this.localeData(),"string"!=typeof t?isNaN(t)?null:t:n.weekdaysParse(t)%7||7);return this.day(this.day()%7?r:r-7)},gn.dayOfYear=function(e){var t=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==e?t:this.add(e-t,"d")},gn.hour=gn.hours=at,gn.minute=gn.minutes=un,gn.second=gn.seconds=hn,gn.millisecond=gn.milliseconds=fn,gn.utcOffset=function(e,t,n){var r,o=this._offset||0;if(!this.isValid())return null!=e?this:NaN;if(null==e)return this._isUTC?o:Yt(this);if("string"==typeof e){if(null===(e=Ut(se,e)))return this}else Math.abs(e)<16&&!n&&(e*=60);return!this._isUTC&&t&&(r=Yt(this)),this._offset=e,this._isUTC=!0,null!=r&&this.add(r,"m"),o!==e&&(!t||this._changeInProgress?Qt(this,Xt(e-o,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,u.updateOffset(this,!0),this._changeInProgress=null)),this},gn.utc=function(e){return this.utcOffset(0,e)},gn.local=function(e){return this._isUTC&&(this.utcOffset(0,e),this._isUTC=!1,e&&this.subtract(Yt(this),"m")),this},gn.parseZone=function(){if(null!=this._tzm)this.utcOffset(this._tzm,!1,!0);else if("string"==typeof this._i){var e=Ut(ae,this._i);null!=e?this.utcOffset(e):this.utcOffset(0,!0)}return this},gn.hasAlignedHourOffset=function(e){return!!this.isValid()&&(e=e?It(e).utcOffset():0,(this.utcOffset()-e)%60==0)},gn.isDST=function(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()},gn.isLocal=function(){return!!this.isValid()&&!this._isUTC},gn.isUtcOffset=function(){return!!this.isValid()&&this._isUTC},gn.isUtc=$t,gn.isUTC=$t,gn.zoneAbbr=function(){return this._isUTC?"UTC":""},gn.zoneName=function(){return this._isUTC?"Coordinated Universal Time":""},gn.dates=e("dates accessor is deprecated. Use date instead.",ln),gn.months=e("months accessor is deprecated. Use month instead",Ve),gn.years=e("years accessor is deprecated. Use year instead",Me),gn.zone=e("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",function(e,t){return null!=e?("string"!=typeof e&&(e=-e),this.utcOffset(e,t),this):-this.utcOffset()}),gn.isDSTShifted=e("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",function(){if(!i(this._isDSTShifted))return this._isDSTShifted;var e={};if(y(e,this),(e=Nt(e))._a){var t=e._isUTC?f(e._a):It(e._a);this._isDSTShifted=this.isValid()&&0<b(e._a,t.toArray())}else this._isDSTShifted=!1;return this._isDSTShifted});var pn=N.prototype;function mn(e,t,n,r){var o=gt(),i=f().set(r,t);return o[n](i,e)}function yn(e,t,n){if(l(e)&&(t=e,e=void 0),e=e||"",null!=t)return mn(e,t,n,"month");var r,o=[];for(r=0;r<12;r++)o[r]=mn(e,r,n,"month");return o}function wn(e,t,n,r){"boolean"==typeof e?l(t)&&(n=t,t=void 0):(t=e,e=!1,l(n=t)&&(n=t,t=void 0)),t=t||"";var o,i=gt(),a=e?i._week.dow:0;if(null!=n)return mn(t,(n+a)%7,r,"day");var s=[];for(o=0;o<7;o++)s[o]=mn(t,(o+a)%7,r,"day");return s}pn.calendar=function(e,t,n){var r=this._calendar[e]||this._calendar.sameElse;return O(r)?r.call(t,n):r},pn.longDateFormat=function(e){var t=this._longDateFormat[e],n=this._longDateFormat[e.toUpperCase()];return!t&&n?(this._longDateFormat[e]=n.replace(/MMMM|MM|DD|dddd/g,function(e){return e.slice(1)}),this._longDateFormat[e]):t},pn.invalidDate=function(){return this._invalidDate},pn.ordinal=function(e){return this._ordinal.replace("%d",e)},pn.preparse=vn,pn.postformat=vn,pn.relativeTime=function(e,t,n,r){var o=this._relativeTime[n];return O(o)?o(e,t,n,r):o.replace(/%d/i,e)},pn.pastFuture=function(e,t){var n=this._relativeTime[0<e?"future":"past"];return O(n)?n(t):n.replace(/%s/i,t)},pn.set=function(e){var t,n;for(n in e)O(t=e[n])?this[n]=t:this["_"+n]=t;this._config=e,this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)},pn.months=function(e,t){return e?a(this._months)?this._months[e.month()]:this._months[(this._months.isFormat||xe).test(t)?"format":"standalone"][e.month()]:a(this._months)?this._months:this._months.standalone},pn.monthsShort=function(e,t){return e?a(this._monthsShort)?this._monthsShort[e.month()]:this._monthsShort[xe.test(t)?"format":"standalone"][e.month()]:a(this._monthsShort)?this._monthsShort:this._monthsShort.standalone},pn.monthsParse=function(e,t,n){var r,o,i;if(this._monthsParseExact)return Pe.call(this,e,t,n);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),r=0;r<12;r++){if(o=f([2e3,r]),n&&!this._longMonthsParse[r]&&(this._longMonthsParse[r]=new RegExp("^"+this.months(o,"").replace(".","")+"$","i"),this._shortMonthsParse[r]=new RegExp("^"+this.monthsShort(o,"").replace(".","")+"$","i")),n||this._monthsParse[r]||(i="^"+this.months(o,"")+"|^"+this.monthsShort(o,""),this._monthsParse[r]=new RegExp(i.replace(".",""),"i")),n&&"MMMM"===t&&this._longMonthsParse[r].test(e))return r;if(n&&"MMM"===t&&this._shortMonthsParse[r].test(e))return r;if(!n&&this._monthsParse[r].test(e))return r}},pn.monthsRegex=function(e){return this._monthsParseExact?(h(this,"_monthsRegex")||Ue.call(this),e?this._monthsStrictRegex:this._monthsRegex):(h(this,"_monthsRegex")||(this._monthsRegex=We),this._monthsStrictRegex&&e?this._monthsStrictRegex:this._monthsRegex)},pn.monthsShortRegex=function(e){return this._monthsParseExact?(h(this,"_monthsRegex")||Ue.call(this),e?this._monthsShortStrictRegex:this._monthsShortRegex):(h(this,"_monthsShortRegex")||(this._monthsShortRegex=Be),this._monthsShortStrictRegex&&e?this._monthsShortStrictRegex:this._monthsShortRegex)},pn.week=function(e){return Ge(e,this._week.dow,this._week.doy).week},pn.firstDayOfYear=function(){return this._week.doy},pn.firstDayOfWeek=function(){return this._week.dow},pn.weekdays=function(e,t){return e?a(this._weekdays)?this._weekdays[e.day()]:this._weekdays[this._weekdays.isFormat.test(t)?"format":"standalone"][e.day()]:a(this._weekdays)?this._weekdays:this._weekdays.standalone},pn.weekdaysMin=function(e){return e?this._weekdaysMin[e.day()]:this._weekdaysMin},pn.weekdaysShort=function(e){return e?this._weekdaysShort[e.day()]:this._weekdaysShort},pn.weekdaysParse=function(e,t,n){var r,o,i;if(this._weekdaysParseExact)return Ze.call(this,e,t,n);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),r=0;r<7;r++){if(o=f([2e3,1]).day(r),n&&!this._fullWeekdaysParse[r]&&(this._fullWeekdaysParse[r]=new RegExp("^"+this.weekdays(o,"").replace(".",".?")+"$","i"),this._shortWeekdaysParse[r]=new RegExp("^"+this.weekdaysShort(o,"").replace(".",".?")+"$","i"),this._minWeekdaysParse[r]=new RegExp("^"+this.weekdaysMin(o,"").replace(".",".?")+"$","i")),this._weekdaysParse[r]||(i="^"+this.weekdays(o,"")+"|^"+this.weekdaysShort(o,"")+"|^"+this.weekdaysMin(o,""),this._weekdaysParse[r]=new RegExp(i.replace(".",""),"i")),n&&"dddd"===t&&this._fullWeekdaysParse[r].test(e))return r;if(n&&"ddd"===t&&this._shortWeekdaysParse[r].test(e))return r;if(n&&"dd"===t&&this._minWeekdaysParse[r].test(e))return r;if(!n&&this._weekdaysParse[r].test(e))return r}},pn.weekdaysRegex=function(e){return this._weekdaysParseExact?(h(this,"_weekdaysRegex")||tt.call(this),e?this._weekdaysStrictRegex:this._weekdaysRegex):(h(this,"_weekdaysRegex")||(this._weekdaysRegex=Qe),this._weekdaysStrictRegex&&e?this._weekdaysStrictRegex:this._weekdaysRegex)},pn.weekdaysShortRegex=function(e){return this._weekdaysParseExact?(h(this,"_weekdaysRegex")||tt.call(this),e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(h(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=Je),this._weekdaysShortStrictRegex&&e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)},pn.weekdaysMinRegex=function(e){return this._weekdaysParseExact?(h(this,"_weekdaysRegex")||tt.call(this),e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(h(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=et),this._weekdaysMinStrictRegex&&e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)},pn.isPM=function(e){return"p"===(e+"").toLowerCase().charAt(0)},pn.meridiem=function(e,t,n){return 11<e?n?"pm":"PM":n?"am":"AM"},dt("en",{dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10,n=1===S(e%100/10)?"th":1==t?"st":2==t?"nd":3==t?"rd":"th";return e+n}}),u.lang=e("moment.lang is deprecated. Use moment.locale instead.",dt),u.langData=e("moment.langData is deprecated. Use moment.localeData instead.",gt);var Cn=Math.abs;function En(e,t,n,r){var o=Xt(t,n);return e._milliseconds+=r*o._milliseconds,e._days+=r*o._days,e._months+=r*o._months,e._bubble()}function Sn(e){return e<0?Math.floor(e):Math.ceil(e)}function bn(e){return 4800*e/146097}function Tn(e){return 146097*e/4800}function Rn(e){return function(){return this.as(e)}}var _n=Rn("ms"),kn=Rn("s"),On=Rn("m"),Mn=Rn("h"),Nn=Rn("d"),An=Rn("w"),In=Rn("M"),Dn=Rn("y");function xn(e){return function(){return this.isValid()?this._data[e]:NaN}}var Ln=xn("milliseconds"),Hn=xn("seconds"),Pn=xn("minutes"),Fn=xn("hours"),Vn=xn("days"),Bn=xn("months"),Wn=xn("years"),Un=Math.round,jn={ss:44,s:45,m:45,h:22,d:26,M:11},Yn=Math.abs;function $n(e){return(0<e)-(e<0)||+e}function Gn(){if(!this.isValid())return this.localeData().invalidDate();var e,t,n=Yn(this._milliseconds)/1e3,r=Yn(this._days),o=Yn(this._months);e=E(n/60),t=E(e/60),n%=60,e%=60;var i=E(o/12),a=o%=12,s=r,l=t,u=e,c=n?n.toFixed(3).replace(/\.?0+$/,""):"",h=this.asSeconds();if(!h)return"P0D";var d=h<0?"-":"",f=$n(this._months)!==$n(h)?"-":"",g=$n(this._days)!==$n(h)?"-":"",v=$n(this._milliseconds)!==$n(h)?"-":"";return d+"P"+(i?f+i+"Y":"")+(a?f+a+"M":"")+(s?g+s+"D":"")+(l||u||c?"T":"")+(l?v+l+"H":"")+(u?v+u+"M":"")+(c?v+c+"S":"")}var zn=Pt.prototype;return zn.isValid=function(){return this._isValid},zn.abs=function(){var e=this._data;return this._milliseconds=Cn(this._milliseconds),this._days=Cn(this._days),this._months=Cn(this._months),e.milliseconds=Cn(e.milliseconds),e.seconds=Cn(e.seconds),e.minutes=Cn(e.minutes),e.hours=Cn(e.hours),e.months=Cn(e.months),e.years=Cn(e.years),this},zn.add=function(e,t){return En(this,e,t,1)},zn.subtract=function(e,t){return En(this,e,t,-1)},zn.as=function(e){if(!this.isValid())return NaN;var t,n,r=this._milliseconds;if("month"===(e=D(e))||"year"===e)return t=this._days+r/864e5,n=this._months+bn(t),"month"===e?n:n/12;switch(t=this._days+Math.round(Tn(this._months)),e){case"week":return t/7+r/6048e5;case"day":return t+r/864e5;case"hour":return 24*t+r/36e5;case"minute":return 1440*t+r/6e4;case"second":return 86400*t+r/1e3;case"millisecond":return Math.floor(864e5*t)+r;default:throw new Error("Unknown unit "+e)}},zn.asMilliseconds=_n,zn.asSeconds=kn,zn.asMinutes=On,zn.asHours=Mn,zn.asDays=Nn,zn.asWeeks=An,zn.asMonths=In,zn.asYears=Dn,zn.valueOf=function(){return this.isValid()?this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*S(this._months/12):NaN},zn._bubble=function(){var e,t,n,r,o,i=this._milliseconds,a=this._days,s=this._months,l=this._data;return 0<=i&&0<=a&&0<=s||i<=0&&a<=0&&s<=0||(i+=864e5*Sn(Tn(s)+a),s=a=0),l.milliseconds=i%1e3,e=E(i/1e3),l.seconds=e%60,t=E(e/60),l.minutes=t%60,n=E(t/60),l.hours=n%24,a+=E(n/24),o=E(bn(a)),s+=o,a-=Sn(Tn(o)),r=E(s/12),s%=12,l.days=a,l.months=s,l.years=r,this},zn.clone=function(){return Xt(this)},zn.get=function(e){return e=D(e),this.isValid()?this[e+"s"]():NaN},zn.milliseconds=Ln,zn.seconds=Hn,zn.minutes=Pn,zn.hours=Fn,zn.days=Vn,zn.weeks=function(){return E(this.days()/7)},zn.months=Bn,zn.years=Wn,zn.humanize=function(e){if(!this.isValid())return this.localeData().invalidDate();var t=this.localeData(),n=function(e,t,n){var r=Xt(e).abs(),o=Un(r.as("s")),i=Un(r.as("m")),a=Un(r.as("h")),s=Un(r.as("d")),l=Un(r.as("M")),u=Un(r.as("y")),c=o<=jn.ss&&["s",o]||o<jn.s&&["ss",o]||i<=1&&["m"]||i<jn.m&&["mm",i]||a<=1&&["h"]||a<jn.h&&["hh",a]||s<=1&&["d"]||s<jn.d&&["dd",s]||l<=1&&["M"]||l<jn.M&&["MM",l]||u<=1&&["y"]||["yy",u];return c[2]=t,c[3]=0<+e,c[4]=n,function(e,t,n,r,o){return o.relativeTime(t||1,!!n,e,r)}.apply(null,c)}(this,!e,t);return e&&(n=t.pastFuture(+this,n)),t.postformat(n)},zn.toISOString=Gn,zn.toString=Gn,zn.toJSON=Gn,zn.locale=nn,zn.localeData=on,zn.toIsoString=e("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Gn),zn.lang=rn,j("X",0,0,"unix"),j("x",0,0,"valueOf"),ce("x",ie),ce("X",/[+-]?\d+(\.\d{1,3})?/),ge("X",function(e,t,n){n._d=new Date(1e3*parseFloat(e,10))}),ge("x",function(e,t,n){n._d=new Date(S(e))}),u.version="2.20.1",function(e){t=e}(It),u.fn=gn,u.min=function(){return Lt("isBefore",[].slice.call(arguments,0))},u.max=function(){return Lt("isAfter",[].slice.call(arguments,0))},u.now=function(){return Date.now?Date.now():+new Date},u.utc=f,u.unix=function(e){return It(1e3*e)},u.months=function(e,t){return yn(e,t,"months")},u.isDate=c,u.locale=dt,u.invalid=p,u.duration=Xt,u.isMoment=C,u.weekdays=function(e,t,n){return wn(e,t,n,"weekdays")},u.parseZone=function(){return It.apply(null,arguments).parseZone()},u.localeData=gt,u.isDuration=Ft,u.monthsShort=function(e,t){return yn(e,t,"monthsShort")},u.weekdaysMin=function(e,t,n){return wn(e,t,n,"weekdaysMin")},u.defineLocale=ft,u.updateLocale=function(e,t){if(null!=t){var n,r,o=st;null!=(r=ht(e))&&(o=r._config),t=M(o,t),(n=new N(t)).parentLocale=lt[e],lt[e]=n,dt(e)}else null!=lt[e]&&(null!=lt[e].parentLocale?lt[e]=lt[e].parentLocale:null!=lt[e]&&delete lt[e]);return lt[e]},u.locales=function(){return R(lt)},u.weekdaysShort=function(e,t,n){return wn(e,t,n,"weekdaysShort")},u.normalizeUnits=D,u.relativeTimeRounding=function(e){return void 0!==e?"function"==typeof e&&(Un=e,!0):Un},u.relativeTimeThreshold=function(e,t){return void 0!==jn[e]&&(void 0===t?jn[e]:(jn[e]=t,"s"===e&&(jn.ss=t-1),!0))},u.calendarFormat=function(e,t){var n=e.diff(t,"days",!0);return n<-6?"sameElse":n<-1?"lastWeek":n<0?"lastDay":n<1?"sameDay":n<2?"nextDay":n<7?"nextWeek":"sameElse"},u.prototype=gn,u.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"YYYY-[W]WW",MONTH:"YYYY-MM"},u}(),window.moment=Kn(63)}).call(this,Kn(206)(e))},function(e,t,n){"use strict";var r=n(150),o=n(62),i=n(29),a=[].sort,s=[1,2,3],l=i(function(){s.sort(void 0)}),u=i(function(){s.sort(null)}),c=n(126)("sort"),h=l||!u||c;n(22)({target:"Array",proto:!0,forced:h},{sort:function(e){return void 0===e?a.call(o(this)):a.call(o(this),r(e))}})},function(e,t,n){var s=n(32),l=n(61),u=n(47),c=n(143),r=n(177),o=n(87),i=o.get,h=o.enforce,d=String(r).split("toString");n(98)("inspectSource",function(e){return r.call(e)}),(e.exports=function(e,t,n,r){var o=!!r&&!!r.unsafe,i=!!r&&!!r.enumerable,a=!!r&&!!r.noTargetGet;"function"==typeof n&&("string"!=typeof t||u(n,"name")||l(n,"name",t),h(n).source=d.join("string"==typeof t?t:"")),e!==s?(o?!a&&e[t]&&(i=!0):delete e[t],i?e[t]=n:l(e,t,n)):i?e[t]=n:c(t,n)})(Function.prototype,"toString",function(){return"function"==typeof this&&i(this).source||r.call(this)})},function(e,t){e.exports=function(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}},function(e,t,n){"use strict";n(37),n(105),t.__esModule=!0,t.toSingleLine=function(e){for(var t=arguments.length,i=new Array(1<t?t-1:0),n=1;n<t;n++)i[n-1]=arguments[n];return(0,r.arrayReduce)(e,function(e,t,n){var r=t.replace(/(?:\r?\n\s+)/g,""),o=i[n]?i[n]:"";return e+r+o},"").trim()};var r=n(3)},function(e,t,n){"use strict";n(12),n(10),n(36),n(37),t.__esModule=!0,t.toUpperCaseFirst=function(e){return e[0].toUpperCase()+e.substr(1)},t.equalsIgnoreCase=function(){for(var e=[],t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var o=n.length;for(;o;){o-=1;var i=(0,a.stringify)(n[o]).toLowerCase();-1===e.indexOf(i)&&e.push(i)}return 1===e.length},t.randomString=function(){function e(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)}return e()+e()+e()+e()},t.isPercentValue=function(e){return/^([0-9][0-9]?%$)|(^100%$)/.test(e)},t.substitute=function(e){var n=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};return"".concat(e).replace(/(?:\\)?\[([^[\]]+)]/g,function(e,t){return"\\"===e.charAt(0)?e.substr(1,e.length-1):void 0===n[t]?"":n[t]})},t.stripTags=function(e){return"".concat(e).replace(r,"")};var a=n(27);var r=/<\/?\w+\/?>|<\w+[\s|/][^>]*>/gi},function(e,t,n){var r=n(113),o=n(58);e.exports=function(e){return r(o(e))}},function(e,t,n){"use strict";e.exports=n(125)("Map",function(e){return function(){return e(this,0<arguments.length?arguments[0]:void 0)}},n(192),!0)},function(e,t){e.exports=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}},function(e,t,n){"use strict";t.__esModule=!0,t.setBrowserMeta=o,t.isChrome=function(){return a.chrome.value},t.isEdge=function(){return a.edge.value},t.isIE=function(){return a.ie.value},t.isIE8=function(){return a.ie8.value},t.isIE9=function(){return a.ie9.value},t.isMSBrowser=function(){return a.ie.value||a.edge.value},t.isMobileBrowser=function(){return a.mobile.value},t.isSafari=function(){return a.safari.value};var i=n(4),r=function(n){var r={value:!1,test:function(e,t){r.value=n(e,t)}};return r},a={chrome:r(function(e,t){return/Chrome/.test(e)&&/Google/.test(t)}),edge:r(function(e){return/Edge/.test(e)}),ie:r(function(e){return/Trident/.test(e)}),ie8:r(function(){return!document.createTextNode("test").textContent}),ie9:r(function(){return!!document.documentMode}),mobile:r(function(e){return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(e)}),safari:r(function(e,t){return/Safari/.test(e)&&/Apple Computer/.test(t)})};function o(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},t=e.userAgent,n=void 0===t?navigator.userAgent:t,r=e.vendor,o=void 0===r?navigator.vendor:r;(0,i.objectEach)(a,function(e){(0,e.test)(n,o)})}o()},function(e,t,n){"use strict";var r=n(0);n(10),n(36),n(131),n(30),t.__esModule=!0,t.requestAnimationFrame=function(e){return c.call(window,e)},t.isClassListSupported=function(){return!!document.documentElement.classList},t.isTextContentSupported=function(){return!!document.createTextNode("test").textContent},t.isGetComputedStyleSupported=function(){return!!window.getComputedStyle},t.cancelAnimationFrame=function(e){h.call(window,e)},t.isTouchSupported=function(){return"ontouchstart"in window},t.isWebComponentSupportedNatively=function(){var e=document.createElement("div");return!(!e.createShadowRoot||!e.createShadowRoot.toString().match(/\[native code\]/))},t.hasCaptionProblem=function(){void 0===o&&function(){var e=document.createElement("TABLE");e.style.borderSpacing="0",e.style.borderWidth="0",e.style.padding="0";var t=document.createElement("TBODY");e.appendChild(t),t.appendChild(document.createElement("TR")),t.firstChild.appendChild(document.createElement("TD")),t.firstChild.firstChild.innerHTML="<tr><td>t<br>t</td></tr>";var n=document.createElement("CAPTION");n.innerHTML="c<br>c<br>c<br>c",n.style.padding="0",n.style.margin="0",e.insertBefore(n,t),document.body.appendChild(e),o=e.offsetHeight<2*e.lastChild.offsetHeight,document.body.removeChild(e)}();return o},t.getComparisonFunction=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};if(i)return i;i="object"===("undefined"==typeof Intl?"undefined":(0,s.default)(Intl))?new Intl.Collator(e,t).compare:"function"==typeof String.prototype.localeCompare?function(e,t){return"".concat(e).localeCompare(t)}:function(e,t){return e===t?0:t<e?-1:1};return i},t.isPassiveEventSupported=function(){if(void 0!==a)return a;try{var e={get passive(){a=!0}};window.addEventListener("test",e,e),window.removeEventListener("test",e,e)}catch(e){a=!1}return a};for(var o,i,a,s=r(n(44)),l=0,u=["ms","moz","webkit","o"],c=window.requestAnimationFrame,h=window.cancelAnimationFrame,d=0;d<u.length&&!c;++d)c=window["".concat(u[d],"RequestAnimationFrame")],h=window["".concat(u[d],"CancelAnimationFrame")]||window["".concat(u[d],"CancelRequestAnimationFrame")];c||(c=function(e){var t=(new Date).getTime(),n=Math.max(0,16-(t-l)),r=window.setTimeout(function(){e(t+n)},n);return l=t+n,r}),h||(h=function(e){clearTimeout(e)})},function(e,t,n){"use strict";var r=n(0);n(12),t.__esModule=!0,t.default=void 0;var s=r(n(1)),o=r(n(2)),u=n(5),c=n(4),i=n(3),h=n(55),a=r(n(23)),d=r(n(326)),f={},l=function(){function l(e){(0,s.default)(this,l),(0,c.defineGetter)(this,"wot",e,{writable:!1});var t=this.wot.wtTable,n=t.TABLE,r=t.hider,o=t.spreader,i=t.holder,a=t.wtRootElement;this.instance=this.wot,this.type="",this.mainTableScrollableElement=null,this.TABLE=n,this.hider=r,this.spreader=o,this.holder=i,this.wtRootElement=a,this.trimmingContainer=(0,u.getTrimmingContainer)(this.hider.parentNode.parentNode),this.areElementSizesAdjusted=!1,this.updateStateOfRendering()}return(0,o.default)(l,null,[{key:"registerOverlay",value:function(e,t){if(-1===l.CLONE_TYPES.indexOf(e))throw new Error("Unsupported overlay (".concat(e,")."));f[e]=t}},{key:"createOverlay",value:function(e,t){return new f[e](t)}},{key:"hasOverlay",value:function(e){return void 0!==f[e]}},{key:"isOverlayTypeOf",value:function(e,t){return!(!e||!f[t])&&e instanceof f[t]}},{key:"CLONE_TOP",get:function(){return"top"}},{key:"CLONE_BOTTOM",get:function(){return"bottom"}},{key:"CLONE_LEFT",get:function(){return"left"}},{key:"CLONE_TOP_LEFT_CORNER",get:function(){return"top_left_corner"}},{key:"CLONE_BOTTOM_LEFT_CORNER",get:function(){return"bottom_left_corner"}},{key:"CLONE_DEBUG",get:function(){return"debug"}},{key:"CLONE_TYPES",get:function(){return[l.CLONE_TOP,l.CLONE_BOTTOM,l.CLONE_LEFT,l.CLONE_TOP_LEFT_CORNER,l.CLONE_BOTTOM_LEFT_CORNER,l.CLONE_DEBUG]}}]),(0,o.default)(l,[{key:"updateStateOfRendering",value:function(){var e=this.needFullRender;this.needFullRender=this.shouldBeRendered();var t=e!==this.needFullRender;return t&&!this.needFullRender&&this.reset(),t}},{key:"shouldBeRendered",value:function(){return!0}},{key:"updateTrimmingContainer",value:function(){this.trimmingContainer=(0,u.getTrimmingContainer)(this.hider.parentNode.parentNode)}},{key:"updateMainScrollableElement",value:function(){var e=this.wot,t=e.wtTable;"hidden"===e.rootWindow.getComputedStyle(t.wtRootElement.parentNode).getPropertyValue("overflow")?this.mainTableScrollableElement=this.wot.wtTable.holder:this.mainTableScrollableElement=(0,u.getScrollableElement)(t.TABLE)}},{key:"getRelativeCellPosition",value:function(e,t,n){if(!1!==this.clone.wtTable.holder.contains(e)){var r=this.mainTableScrollableElement===this.wot.rootWindow,o=n<this.wot.getSetting("fixedColumnsLeft"),i=t<this.wot.getSetting("fixedRowsTop"),a=t>=this.wot.getSetting("totalRows")-this.wot.getSetting("fixedRowsBottom"),s={left:this.clone.wtTable.spreader.offsetLeft,top:this.clone.wtTable.spreader.offsetTop},l={left:e.offsetLeft,top:e.offsetTop};return r?this.getRelativeCellPositionWithinWindow(i,o,l,s):this.getRelativeCellPositionWithinHolder(i,a,o,l,s)}(0,h.warn)("The provided element is not a child of the ".concat(this.type," overlay"))}},{key:"getRelativeCellPositionWithinWindow",value:function(e,t,n,r){var o=this.wot.wtTable.wtRootElement.getBoundingClientRect(),i=0,a=0;(i=t?o.left<=0?-1*o.left:0:r.left,e)?a=this.clone.wtTable.TABLE.getBoundingClientRect().top-o.top:a=r.top;return{left:n.left+i,top:n.top+a}}},{key:"getRelativeCellPositionWithinHolder",value:function(e,t,n,r,o){var i=this.clone.cloneSource.wtOverlays.leftOverlay.getScrollPosition(),a=this.clone.cloneSource.wtOverlays.topOverlay.getScrollPosition(),s=0,l=0;if(n||(s=i-o.left),t){var u=this.wot.wtTable.wtRootElement.getBoundingClientRect();l=-1*this.clone.wtTable.TABLE.getBoundingClientRect().top+u.top}else e||(l=a-o.top);return{left:r.left-s,top:r.top-l}}},{key:"makeClone",value:function(e){if(-1===l.CLONE_TYPES.indexOf(e))throw new Error('Clone type "'.concat(e,'" is not supported.'));var t=this.wot,n=t.wtTable,r=t.rootDocument,o=t.rootWindow,i=r.createElement("DIV"),a=r.createElement("TABLE");i.className="ht_clone_".concat(e," handsontable"),i.style.position="absolute",i.style.top=0,i.style.left=0,i.style.overflow="hidden",a.className=n.TABLE.className,i.appendChild(a),this.type=e,n.wtRootElement.parentNode.appendChild(i);var s=this.wot.getSetting("preventOverflow");return!0===s||"horizontal"===s&&this.type===l.CLONE_TOP||"vertical"===s&&this.type===l.CLONE_LEFT?this.mainTableScrollableElement=o:"hidden"===o.getComputedStyle(n.wtRootElement.parentNode).getPropertyValue("overflow")?this.mainTableScrollableElement=n.holder:this.mainTableScrollableElement=(0,u.getScrollableElement)(n.TABLE),new d.default({cloneSource:this.wot,cloneOverlay:this,table:a})}},{key:"refresh",value:function(){var e=0<arguments.length&&void 0!==arguments[0]&&arguments[0],t=this.shouldBeRendered();this.clone&&(this.needFullRender||t)&&this.clone.draw(e),this.needFullRender=t}},{key:"reset",value:function(){if(this.clone){var e=this.clone.wtTable.holder,t=this.clone.wtTable.hider,n=e.style,r=t.style,o=e.parentNode.style;(0,i.arrayEach)([n,r,o],function(e){e.width="",e.height=""})}}},{key:"destroy",value:function(){new a.default(this.clone).destroy()}}]),l}();t.default=l},function(e,t,n){"use strict";n(18),n(40),n(30),t.__esModule=!0,t.isFunction=function(e){return"function"==typeof e},t.throttle=a,t.throttleAfterHits=function(r){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:200,t=2<arguments.length&&void 0!==arguments[2]?arguments[2]:10,o=a(r,e),i=t;function n(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return i?(i-=1,r.apply(this,t)):o.apply(this,t)}return n.clearHits=function(){i=t},n},t.debounce=function(o){var i,a=1<arguments.length&&void 0!==arguments[1]?arguments[1]:200,s=null;return function(){for(var e=this,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];s&&clearTimeout(s);return s=setTimeout(function(){i=o.apply(e,n)},a),i}},t.pipe=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=t[0],o=t.slice(1);return function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return(0,i.arrayReduce)(o,function(e,t){return t(e)},r.apply(this,t))}},t.partial=function(r){for(var e=arguments.length,o=new Array(1<e?e-1:0),t=1;t<e;t++)o[t-1]=arguments[t];return function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return r.apply(this,o.concat(t))}},t.curry=function(a){var s=a.length;return function o(i){return function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=i.concat(t);return r.length>=s?a.apply(this,r):o(r)}}([])},t.curryRight=function(a){var s=a.length;return function o(i){return function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=i.concat(t.reverse());return r.length>=s?a.apply(this,r):o(r)}}([])};var i=n(3);function a(s){var l=1<arguments.length&&void 0!==arguments[1]?arguments[1]:200,u=0,c={lastCallThrottled:!0},h=null;return function(){for(var e=this,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var o=Date.now(),i=!1;c.lastCallThrottled=!0,u||(u=o,i=!0);var a=l-(o-u);return i?(c.lastCallThrottled=!1,s.apply(this,n)):(h&&clearTimeout(h),h=setTimeout(function(){c.lastCallThrottled=!1,s.apply(e,n),h=void(u=0)},a)),c}}},function(e,t,n){var r=n(62),o=n(89),i=n(29)(function(){o(1)});n(22)({target:"Object",stat:!0,forced:i},{keys:function(e){return o(r(e))}})},function(e,t){var n={}.toString;e.exports=function(e){return n.call(e).slice(8,-1)}},function(e,t,n){"use strict";var r=n(0);n(16),n(70),n(10),n(14),n(17),t.__esModule=!0,t.default=function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:"common";i.has(e)||i.set(e,new Map);var n=i.get(e);return{register:function(e,t){n.set(e,t)},getItem:function(e){return n.get(e)},hasItem:function(e){return n.has(e)},getNames:function(){return(0,o.default)(n.keys())},getValues:function(){return(0,o.default)(n.values())}}},t.collection=void 0;var o=r(n(38)),i=new Map;t.collection=i},function(e,t,n){"use strict";var r=n(0);t.__esModule=!0,t.getValidator=function(e){if("function"==typeof e)return e;if(d(e))return h(e);throw Error('No registered validator found under "'.concat(e,'" name'))},t.getRegisteredValidators=t.getRegisteredValidatorNames=t.hasValidator=t.registerValidator=void 0;var o=r(n(78)),i=r(n(555)),a=r(n(556)),s=r(n(558)),l=r(n(559)),u=(0,o.default)("validators"),c=u.register,h=u.getItem,d=u.hasItem,f=u.getNames,g=u.getValues;t.getRegisteredValidators=g,t.getRegisteredValidatorNames=f,t.hasValidator=d,(t.registerValidator=c)("autocomplete",i.default),c("date",a.default),c("numeric",s.default),c("time",l.default)},function(e,t,n){"use strict";var r=n(32),o=n(120),i=n(47),a=n(77),s=n(152),c=n(97),l=n(29),u=n(93).f,h=n(115).f,d=n(49).f,f=n(196),g="Number",v=r[g],p=v.prototype,m=a(n(99)(p))==g,y="trim"in String.prototype,w=function(e){var t,n,r,o,i,a,s,l,u=c(e,!1);if("string"==typeof u&&2<u.length)if(43===(t=(u=y?u.trim():f(u,3)).charCodeAt(0))||45===t){if(88===(n=u.charCodeAt(2))||120===n)return NaN}else if(48===t){switch(u.charCodeAt(1)){case 66:case 98:r=2,o=49;break;case 79:case 111:r=8,o=55;break;default:return+u}for(a=(i=u.slice(2)).length,s=0;s<a;s++)if((l=i.charCodeAt(s))<48||o<l)return NaN;return parseInt(i,r)}return+u};if(o(g,!v(" 0o1")||!v("0b1")||v("+0x1"))){for(var C,E=function(e){var t=arguments.length<1?0:e,n=this;return n instanceof E&&(m?l(function(){p.valueOf.call(n)}):a(n)!=g)?s(new v(w(t)),n,E):w(t)},S=n(52)?u(v):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger".split(","),b=0;S.length>b;b++)i(v,C=S[b])&&!i(E,C)&&d(E,C,h(v,C));(E.prototype=p).constructor=E,n(65)(r,g,E)}},function(e,t,n){n(22)({target:"Number",stat:!0},{isInteger:n(569)})},function(e,t,n){"use strict";e.exports=n(125)("Set",function(e){return function(){return e(this,0<arguments.length?arguments[0]:void 0)}},n(192))},function(e,t,n){"use strict";var r=n(0),o=n(9);n(12),t.__esModule=!0,t.predefinedItems=function(){var n={};return(0,a.objectEach)(S,function(e,t){n[t]=e()}),n},t.addItem=function(e,t){-1===E.indexOf(e)&&(S[e]=t)},t.ITEMS=t.UNDO=t.NO_ITEMS=t.SEPARATOR=t.ROW_BELOW=t.ROW_ABOVE=t.REMOVE_ROW=t.REMOVE_COLUMN=t.REDO=t.READ_ONLY=t.COLUMN_RIGHT=t.COLUMN_LEFT=t.CLEAR_COLUMN=t.ALIGNMENT=void 0;var i=r(n(71)),a=n(4),s=o(n(620));t.ALIGNMENT=s.KEY;var l=o(n(621));t.CLEAR_COLUMN=l.KEY;var u=o(n(622));t.COLUMN_LEFT=u.KEY;var c=o(n(623));t.COLUMN_RIGHT=c.KEY;var h=o(n(624));t.READ_ONLY=h.KEY;var d=o(n(625));t.REDO=d.KEY;var f=o(n(626));t.REMOVE_COLUMN=f.KEY;var g=o(n(627));t.REMOVE_ROW=g.KEY;var v=o(n(628));t.ROW_ABOVE=v.KEY;var p=o(n(629));t.ROW_BELOW=p.KEY;var m=o(n(166));t.SEPARATOR=m.KEY;var y=o(n(630));t.NO_ITEMS=y.KEY;var w,C=o(n(631));t.UNDO=C.KEY;var E=[v.KEY,p.KEY,u.KEY,c.KEY,l.KEY,g.KEY,f.KEY,C.KEY,d.KEY,h.KEY,s.KEY,m.KEY,y.KEY];t.ITEMS=E;var S=(w={},(0,i.default)(w,m.KEY,m.default),(0,i.default)(w,y.KEY,y.default),(0,i.default)(w,v.KEY,v.default),(0,i.default)(w,p.KEY,p.default),(0,i.default)(w,u.KEY,u.default),(0,i.default)(w,c.KEY,c.default),(0,i.default)(w,l.KEY,l.default),(0,i.default)(w,g.KEY,g.default),(0,i.default)(w,f.KEY,f.default),(0,i.default)(w,C.KEY,C.default),(0,i.default)(w,d.KEY,d.default),(0,i.default)(w,h.KEY,h.default),(0,i.default)(w,s.KEY,s.default),w)},function(e,t,n){"use strict";function r(e){return"string"==typeof e&&"'"===e.charAt(0)&&"="===e.charAt(1)}n(131),n(37),t.__esModule=!0,t.isFormulaExpression=function(e){return"string"==typeof e&&2<=e.length&&"="===e.charAt(0)},t.isFormulaExpressionEscaped=r,t.unescapeFormulaExpression=function(e){return r(e)?e.substr(1):e},t.toUpperCaseFormula=function(e){var t=/(\\"|"(?:\\"|[^"])*"|(\+))|(\\'|'(?:\\'|[^'])*'|(\+))/g,n=e.match(t)||[],r=-1;return e.toUpperCase().replace(t,function(){return n[r+=1]})},t.cellCoordFactory=function(t,n){return function(e){return{row:"row"===t?n:e.row,column:"column"===t?n:e.column}}}},function(e,t,n){"use strict";var r=n(0);n(12),t.__esModule=!0,t.default=void 0;var o=r(n(1)),i=r(n(7)),a=r(n(6)),s=r(n(2)),l=r(n(8)),u=n(111),c=n(3),h=r(n(503)),d=[1,2,3],f=function(e){function r(e,t){var n;return(0,o.default)(this,r),(n=(0,i.default)(this,(0,a.default)(r).call(this,e,t))).precedents=[],n.value=null,n.error=null,n.state=r.STATE_UP_TO_DATE,n}return(0,l.default)(r,e),(0,s.default)(r,null,[{key:"STATE_OUT_OFF_DATE",get:function(){return 1}},{key:"STATE_COMPUTING",get:function(){return 2}},{key:"STATE_UP_TO_DATE",get:function(){return 3}}]),(0,s.default)(r,[{key:"setValue",value:function(e){this.value=e}},{key:"getValue",value:function(){return this.value}},{key:"setError",value:function(e){this.error=e}},{key:"getError",value:function(){return this.error}},{key:"hasError",value:function(){return null!==this.error}},{key:"setState",value:function(e){if(-1===d.indexOf(e))throw Error("Unrecognized state: ".concat(e));this.state=e}},{key:"isState",value:function(e){return this.state===e}},{key:"addPrecedent",value:function(e){if(this.isEqual(e))throw Error(u.ERROR_REF);this.hasPrecedent(e)||this.precedents.push(e)}},{key:"removePrecedent",value:function(t){if(this.isEqual(t))throw Error(u.ERROR_REF);this.precedents=(0,c.arrayFilter)(this.precedents,function(e){return!e.isEqual(t)})}},{key:"clearPrecedents",value:function(){this.precedents.length=0}},{key:"getPrecedents",value:function(){return this.precedents}},{key:"hasPrecedents",value:function(){return 0<this.precedents.length}},{key:"hasPrecedent",value:function(t){return 0<(0,c.arrayFilter)(this.precedents,function(e){return e.isEqual(t)}).length}}]),r}(h.default);t.default=f},function(e,t){var n=Math.ceil,r=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(0<e?r:n)(e)}},function(e,t,n){var r,o,i,a=n(178),s=n(42),l=n(61),u=n(47),c=n(117),h=n(94),d=n(32).WeakMap;if(a){var f=new d,g=f.get,v=f.has,p=f.set;r=function(e,t){return p.call(f,e,t),t},o=function(e){return g.call(f,e)||{}},i=function(e){return v.call(f,e)}}else{var m=c("state");h[m]=!0,r=function(e,t){return l(e,m,t),t},o=function(e){return u(e,m)?e[m]:{}},i=function(e){return u(e,m)}}e.exports={set:r,get:o,has:i,enforce:function(e){return i(e)?o(e):r(e,{})},getterFor:function(n){return function(e){var t;if(!s(e)||(t=o(e)).type!==n)throw TypeError("Incompatible receiver, "+n+" required");return t}}}},function(e,t,n){"use strict";n(64),t.__esModule=!0;var r=n(487);t.registerRootComparator=r.registerRootComparator,t.getRootComparator=r.getRootComparator,t.getCompareFunctionFactory=r.getCompareFunctionFactory;var o=n(612);t.FIRST_AFTER_SECOND=o.FIRST_AFTER_SECOND,t.FIRST_BEFORE_SECOND=o.FIRST_BEFORE_SECOND,t.DO_NOT_SWAP=o.DO_NOT_SWAP,t.sort=o.sort},function(e,t,n){var r=n(175),o=n(141);e.exports=Object.keys||function(e){return r(e,o)}},function(e,t,n){"use strict";var r=n(0);n(16),n(10),n(14),n(24),n(17),t.__esModule=!0,t.registerIdentity=function(e,t){u.set(e,t)},t.getTranslator=function(e){var t,n=e instanceof a.default?e:h(e);c.has(n)?t=c.get(n):(t=new l(n),c.set(n,t));return t},t.getIdentity=h,t.RecordTranslator=void 0;var o=r(n(1)),i=r(n(2)),a=r(n(161)),s=n(4),l=function(){function t(e){(0,o.default)(this,t),this.hot=e}return(0,i.default)(t,[{key:"toVisualRow",value:function(e){return this.hot.runHooks("unmodifyRow",e)}},{key:"toVisualColumn",value:function(e){return this.hot.runHooks("unmodifyCol",e)}},{key:"toVisual",value:function(e,t){return(0,s.isObject)(e)?{row:this.toVisualRow(e.row),column:this.toVisualColumn(e.column)}:[this.toVisualRow(e),this.toVisualColumn(t)]}},{key:"toPhysicalRow",value:function(e){return this.hot.runHooks("modifyRow",e)}},{key:"toPhysicalColumn",value:function(e){return this.hot.runHooks("modifyCol",e)}},{key:"toPhysical",value:function(e,t){return(0,s.isObject)(e)?{row:this.toPhysicalRow(e.row),column:this.toPhysicalColumn(e.column)}:[this.toPhysicalRow(e),this.toPhysicalColumn(t)]}}]),t}();t.RecordTranslator=l;var u=new WeakMap,c=new WeakMap;function h(e){if(!u.has(e))throw Error("Record translator was not registered for this object identity");return u.get(e)}},function(e,t,n){"use strict";var r=n(0);n(18),n(12),n(64),n(33),t.__esModule=!0,t.default=void 0;var o=r(n(38)),i=n(3),a=n(4),s=n(15),l={_arrayMap:[],getValueByIndex:function(e){var t=null;return e<this._arrayMap.length&&(t=this._arrayMap[e]),t},getIndexByValue:function(e){var t;return-1===(t=this._arrayMap.indexOf(e))?null:t},insertItems:function(t){var n=this,e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:1,r=(0,i.arrayMax)(this._arrayMap)+1,o=[];return(0,s.rangeEach)(e-1,function(e){o.push(n._arrayMap.splice(t+e,0,r+e))}),o},removeItems:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:1,n=[];if(Array.isArray(e)){var r=[].concat(this._arrayMap);e.sort(function(e,t){return t-e});for(var o=0,i=e.length;o<i;o++){var a=e[o];this._arrayMap.splice(a,1),n.push(r[a])}}else n=this._arrayMap.splice(e,t);return n},unshiftItems:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:1,o=this.removeItems(e,t);this._arrayMap=(0,i.arrayMap)(this._arrayMap,function(e){var t=e,n=function(r){return(0,i.arrayReduce)(o,function(e,t){var n=e;return t<r&&(n+=1),n},0)}(t);return n&&(t-=n),t})},shiftItems:function(n){var t=this,r=1<arguments.length&&void 0!==arguments[1]?arguments[1]:1;this._arrayMap=(0,i.arrayMap)(this._arrayMap,function(e){var t=e;return n<=t&&(t+=r),t}),(0,s.rangeEach)(r-1,function(e){t._arrayMap.splice(n+e,0,n+e)})},swapIndexes:function(e,t){var n;(n=this._arrayMap).splice.apply(n,[t,0].concat((0,o.default)(this._arrayMap.splice(e,1))))},clearMap:function(){this._arrayMap.length=0}};(0,a.defineGetter)(l,"MIXIN_NAME","arrayMapper",{writable:!1,enumerable:!1});var u=l;t.default=u},function(e,t,n){"use strict";n(18),t.__esModule=!0,t.createId=r,t.createDefaultCustomBorder=o,t.createSingleEmptyBorder=i,t.createDefaultHtBorder=l,t.createEmptyBorders=function(e,t){return{id:r(e,t),border:{width:1,color:"#000",cornerVisible:!1},row:e,col:t,top:{hide:!0},right:{hide:!0},bottom:{hide:!0},left:{hide:!0}}},t.extendDefaultBorder=function(e,t){(0,a.hasOwnProperty)(t,"border")&&(e.border=t.border);(0,a.hasOwnProperty)(t,"top")&&(t.top?(0,a.isObject)(t.top)||(t.top={width:1,color:"#000"}):t.top={hide:!0},e.top=t.top);(0,a.hasOwnProperty)(t,"right")&&(t.right?(0,a.isObject)(t.right)||(t.right={width:1,color:"#000"}):t.right={hide:!0},e.right=t.right);(0,a.hasOwnProperty)(t,"bottom")&&(t.bottom?(0,a.isObject)(t.bottom)||(t.bottom={width:1,color:"#000"}):t.bottom={hide:!0},e.bottom=t.bottom);(0,a.hasOwnProperty)(t,"left")&&(t.left?(0,a.isObject)(t.left)||(t.left={width:1,color:"#000"}):t.left={hide:!0},e.left=t.left);return e},t.checkSelectionBorders=function(r,o){var i=!1;return(0,s.arrayEach)(r.getSelectedRange(),function(e){e.forAll(function(e,t){var n=r.getCellMeta(e,t).borders;if(n){if(!o)return!(i=!0);if(!(0,a.hasOwnProperty)(n[o],"hide")||!1===n[o].hide)return!(i=!0)}})}),i},t.markSelected=function(e){return'<span class="selected">'.concat(String.fromCharCode(10003),"</span>").concat(e)};var a=n(4),s=n(3);function r(e,t){return"border_row".concat(e,"col").concat(t)}function o(){return{width:1,color:"#000"}}function i(){return{hide:!0}}function l(){return{width:1,color:"#000",cornerVisible:!1}}},function(e,t,n){var r=n(175),o=n(141).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return r(e,o)}},function(e,t){e.exports={}},function(e,t,n){"use strict";var r={}.propertyIsEnumerable,o=Object.getOwnPropertyDescriptor,i=o&&!r.call({1:2},1);t.f=i?function(e){var t=o(this,e);return!!t&&t.enumerable}:r},function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},function(e,t,n){var o=n(42);e.exports=function(e,t){if(!o(e))return e;var n,r;if(t&&"function"==typeof(n=e.toString)&&!o(r=n.call(e)))return r;if("function"==typeof(n=e.valueOf)&&!o(r=n.call(e)))return r;if(!t&&"function"==typeof(n=e.toString)&&!o(r=n.call(e)))return r;throw TypeError("Can't convert object to primitive value")}},function(e,t,n){var r=n(32),o=n(143),i="__core-js_shared__",a=r[i]||o(i,{});(e.exports=function(e,t){return a[e]||(a[e]=void 0!==t?t:{})})("versions",[]).push({version:"3.0.1",mode:n(116)?"pure":"global",copyright:"© 2019 Denis Pushkarev (zloirock.ru)"})},function(e,t,n){var r=n(45),o=n(511),i=n(141),a=n(181),s=n(142),l=n(117)("IE_PROTO"),u="prototype",c=function(){},h=function(){var e,t=s("iframe"),n=i.length;for(t.style.display="none",a.appendChild(t),t.src=String("javascript:"),(e=t.contentWindow.document).open(),e.write("<script>document.F=Object<\/script>"),e.close(),h=e.F;n--;)delete h[u][i[n]];return h()};e.exports=Object.create||function(e,t){var n;return null!==e?(c[u]=r(e),n=new c,c[u]=null,n[l]=e):n=h(),void 0===t?n:o(n,t)},n(94)[l]=!0},function(e,t){e.exports={}},function(e,t,n){var i=n(150);e.exports=function(r,o,e){if(i(r),void 0===o)return r;switch(e){case 0:return function(){return r.call(o)};case 1:return function(e){return r.call(o,e)};case 2:return function(e,t){return r.call(o,e,t)};case 3:return function(e,t,n){return r.call(o,e,t,n)}}return function(){return r.apply(o,arguments)}}},function(e,t,n){var w=n(101),C=n(113),E=n(62),S=n(48),r=n(151);e.exports=function(h,e){var d=1==h,f=2==h,g=3==h,v=4==h,p=6==h,m=5==h||p,y=e||r;return function(e,t,n){for(var r,o,i=E(e),a=C(i),s=w(t,n,3),l=S(a.length),u=0,c=d?y(e,l):f?y(e,0):void 0;u<l;u++)if((m||u in a)&&(o=s(r=a[u],u,i),h))if(d)c[u]=o;else if(o)switch(h){case 3:return!0;case 5:return r;case 6:return u;case 2:c.push(r)}else if(v)return!1;return p?-1:g||v?v:c}}},function(e,t,n){var r=n(29),o=n(35)("species");e.exports=function(t){return!r(function(){var e=[];return(e.constructor={})[o]=function(){return{foo:1}},1!==e[t](Boolean).foo})}},function(e,t,n){"use strict";var r=n(0);n(105),t.__esModule=!0,t.default=t.EditorState=void 0;var o=r(n(7)),i=r(n(6)),a=r(n(8)),s=r(n(1)),l=r(n(2)),u=n(25),c=n(27),h=n(4),d=r(n(535)),f={VIRGIN:"STATE_VIRGIN",EDITING:"STATE_EDITING",WAITING:"STATE_WAITING",FINISHED:"STATE_FINISHED"};t.EditorState=f;var g=function(){function t(e){(0,s.default)(this,t),this.hot=e,this.instance=e,this.state=f.VIRGIN,this._opened=!1,this._fullEditMode=!1,this._closeCallback=null,this.TD=null,this.row=null,this.col=null,this.prop=null,this.originalValue=null,this.cellProperties=null,this.init()}return(0,l.default)(t,[{key:"_fireCallbacks",value:function(e){this._closeCallback&&(this._closeCallback(e),this._closeCallback=null)}},{key:"init",value:function(){}},{key:"getValue",value:function(){throw Error("Editor getValue() method unimplemented")}},{key:"setValue",value:function(){throw Error("Editor setValue() method unimplemented")}},{key:"open",value:function(){throw Error("Editor open() method unimplemented")}},{key:"close",value:function(){throw Error("Editor close() method unimplemented")}},{key:"prepare",value:function(e,t,n,r,o,i){this.TD=r,this.row=e,this.col=t,this.prop=n,this.originalValue=o,this.cellProperties=i,this.state=f.VIRGIN}},{key:"extend",value:function(){return function(e){function t(){return(0,s.default)(this,t),(0,o.default)(this,(0,i.default)(t).apply(this,arguments))}return(0,a.default)(t,e),t}(this.constructor)}},{key:"saveValue",value:function(e,t){var n,r;t?((n=this.hot.getSelectedLast())[0]>n[2]&&(r=n[0],n[0]=n[2],n[2]=r),n[1]>n[3]&&(r=n[1],n[1]=n[3],n[3]=r)):n=[this.row,this.col,null,null],this.hot.populateFromArray(n[0],n[1],e,n[2],n[3],"edit")}},{key:"beginEditing",value:function(e,t){if(this.state===f.VIRGIN){if(this.hot.view.scrollViewport(new u.CellCoords(this.row,this.col)),this.state=f.EDITING,this.isInFullEditMode()){var n="string"==typeof e?e:(0,c.stringify)(this.originalValue);this.setValue(n)}this.open(t),this._opened=!0,this.focus(),this.hot.view.render(),this.hot.runHooks("afterBeginEditing",this.row,this.col)}}},{key:"finishEditing",value:function(e,t,n){var r,o=this;if(n){var i=this._closeCallback;this._closeCallback=function(e){i&&i(e),n(e),o.hot.view.render()}}if(!this.isWaiting())if(this.state!==f.VIRGIN){if(this.state===f.EDITING){if(e)return this.cancelChanges(),void this.hot.view.render();var a=this.getValue();r=this.hot.getSettings().trimWhitespace?[["string"==typeof a?String.prototype.trim.call(a||""):a]]:[[a]],this.state=f.WAITING,this.saveValue(r,t),this.hot.getCellValidator(this.cellProperties)?this.hot.addHookOnce("postAfterValidate",function(e){o.state=f.FINISHED,o.discardEditor(e)}):(this.state=f.FINISHED,this.discardEditor(!0))}}else this.hot._registerTimeout(function(){o._fireCallbacks(!0)})}},{key:"cancelChanges",value:function(){this.state=f.FINISHED,this.discardEditor()}},{key:"discardEditor",value:function(e){this.state===f.FINISHED&&(!1===e&&!0!==this.cellProperties.allowInvalid?(this.hot.selectCell(this.row,this.col),this.focus(),this.state=f.EDITING,this._fireCallbacks(!1)):(this.close(),this._opened=!1,this._fullEditMode=!1,this.state=f.VIRGIN,this._fireCallbacks(!0)))}},{key:"enableFullEditMode",value:function(){this._fullEditMode=!0}},{key:"isInFullEditMode",value:function(){return this._fullEditMode}},{key:"isOpened",value:function(){return this._opened}},{key:"isWaiting",value:function(){return this.state===f.WAITING}},{key:"checkEditorSection",value:function(){var e=this.hot.countRows(),t="";return this.row<this.hot.getSettings().fixedRowsTop?t=this.col<this.hot.getSettings().fixedColumnsLeft?"top-left-corner":"top":this.hot.getSettings().fixedRowsBottom&&this.row>=e-this.hot.getSettings().fixedRowsBottom?t=this.col<this.hot.getSettings().fixedColumnsLeft?"bottom-left-corner":"bottom":this.col<this.hot.getSettings().fixedColumnsLeft&&(t="left"),t}}]),t}();(0,h.mixin)(g,d.default);var v=g;t.default=v},function(e,t,n){"use strict";var r=n(196),o=n(521)("trim");n(22)({target:"String",proto:!0,forced:o},{trim:function(){return r(this,3)}})},function(e,t,n){"use strict";var r=n(0);t.__esModule=!0,t.default=void 0;var o=r(n(1)),i=r(n(2)),a=function(){function n(e,t){(0,o.default)(this,n),this.row=null,this.col=null,void 0!==e&&void 0!==t&&(this.row=e,this.col=t)}return(0,i.default)(n,[{key:"isValid",value:function(e){return!(this.row<0||this.col<0)&&!(this.row>=e.getSetting("totalRows")||this.col>=e.getSetting("totalColumns"))}},{key:"isEqual",value:function(e){return e===this||this.row===e.row&&this.col===e.col}},{key:"isSouthEastOf",value:function(e){return this.row>=e.row&&this.col>=e.col}},{key:"isNorthWestOf",value:function(e){return this.row<=e.row&&this.col<=e.col}},{key:"isSouthWestOf",value:function(e){return this.row>=e.row&&this.col<=e.col}},{key:"isNorthEastOf",value:function(e){return this.row<=e.row&&this.col>=e.col}},{key:"toObject",value:function(){return{row:this.row,col:this.col}}}]),n}();t.default=a},function(e,t,n){"use strict";var r=n(9),o=n(0);n(18),n(34),n(12),n(40),t.__esModule=!0,t.default=void 0;var i=o(n(1)),a=o(n(2)),s=o(n(7)),l=o(n(26)),h=o(n(6)),d=o(n(13)),u=o(n(8)),L=n(5),f=o(n(537)),g=n(72),H=r(n(104)),v=o(n(23)),p=n(50),m=n(31),c=function(e){function c(e){var t;return(0,i.default)(this,c),(t=(0,s.default)(this,(0,h.default)(c).call(this,e))).eventManager=new v.default((0,l.default)(t)),t.autoResize=(0,f.default)(),t.holderZIndex=-1,t.TEXTAREA=void 0,t.textareaStyle=void 0,t.TEXTAREA_PARENT=void 0,t.textareaParentStyle=void 0,t.createElements(),t.bindEvents(),t.hot.addHookOnce("afterDestroy",function(){return t.destroy()}),t}return(0,u.default)(c,e),(0,a.default)(c,[{key:"getValue",value:function(){return this.TEXTAREA.value}},{key:"setValue",value:function(e){this.TEXTAREA.value=e}},{key:"open",value:function(){var t=this;this.refreshDimensions(),this.showEditableElement(),this.addHook("beforeKeyDown",function(e){return t.onBeforeKeyDown(e)})}},{key:"close",value:function(){this.autoResize.unObserve(),this.hot.rootDocument.activeElement===this.TEXTAREA&&this.hot.listen(),this.hideEditableElement(),this.removeHooksByKey("beforeKeyDown")}},{key:"prepare",value:function(e,t,n,r,o,i){var a=this,s=this.state;if((0,d.default)((0,h.default)(c.prototype),"prepare",this).call(this,e,t,n,r,o,i),!i.readOnly){this.refreshDimensions(!0);var l=i.allowInvalid,u=i.fragmentSelection;l&&(this.TEXTAREA.value=""),s!==H.EditorState.FINISHED&&this.hideEditableElement(),!u&&!(0,g.isMobileBrowser)()&&this.hot._registerImmediate(function(){return a.focus(!0)})}}},{key:"beginEditing",value:function(e,t){this.state===H.EditorState.VIRGIN&&(this.TEXTAREA.value="",(0,d.default)((0,h.default)(c.prototype),"beginEditing",this).call(this,e,t))}},{key:"focus",value:function(){0<arguments.length&&void 0!==arguments[0]&&arguments[0]?(0,L.selectElementIfAllowed)(this.TEXTAREA):(this.TEXTAREA.select(),(0,L.setCaretPosition)(this.TEXTAREA,this.TEXTAREA.value.length))}},{key:"createElements",value:function(){var e=this.hot.rootDocument;this.TEXTAREA=e.createElement("TEXTAREA"),this.TEXTAREA.tabIndex=-1,(0,L.addClass)(this.TEXTAREA,"handsontableInput"),this.textareaStyle=this.TEXTAREA.style,this.textareaStyle.width=0,this.textareaStyle.height=0,this.textareaStyle.overflowY="visible",this.TEXTAREA_PARENT=e.createElement("DIV"),(0,L.addClass)(this.TEXTAREA_PARENT,"handsontableInputHolder"),this.textareaParentStyle=this.TEXTAREA_PARENT.style,this.textareaParentStyle.zIndex="-1",this.TEXTAREA_PARENT.appendChild(this.TEXTAREA),this.hot.rootElement.appendChild(this.TEXTAREA_PARENT)}},{key:"getEditedCell",value:function(){var e;switch(this.checkEditorSection()){case"top":e=this.hot.view.wt.wtOverlays.topOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.holderZIndex=101;break;case"top-left-corner":e=this.hot.view.wt.wtOverlays.topLeftCornerOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.holderZIndex=103;break;case"bottom-left-corner":e=this.hot.view.wt.wtOverlays.bottomLeftCornerOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.holderZIndex=103;break;case"left":e=this.hot.view.wt.wtOverlays.leftOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.holderZIndex=102;break;case"bottom":e=this.hot.view.wt.wtOverlays.bottomOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.holderZIndex=102;break;default:e=this.hot.getCell(this.row,this.col),this.holderZIndex=-1}return e<0?void 0:e}},{key:"hideEditableElement",value:function(){((0,g.isIE)()||(0,g.isEdge)())&&(this.textareaStyle.textIndent="-99999px"),this.textareaStyle.overflowY="visible",this.textareaParentStyle.opacity="0",this.textareaParentStyle.height="1px",this.textareaParentStyle.zIndex="-1"}},{key:"showEditableElement",value:function(){this.textareaParentStyle.height="",this.textareaParentStyle.overflow="",this.textareaParentStyle.position="",this.textareaParentStyle.right="auto",this.textareaParentStyle.zIndex=0<=this.holderZIndex?this.holderZIndex:"",this.textareaParentStyle.opacity="1",this.textareaStyle.textIndent="",this.textareaStyle.overflowY="auto"}},{key:"refreshValue",value:function(){var e=this.hot.toPhysicalRow(this.row),t=this.hot.getSourceDataAtCell(e,this.col);this.originalValue=t,this.setValue(t),this.refreshDimensions()}},{key:"refreshDimensions",value:function(){var e=0<arguments.length&&void 0!==arguments[0]&&arguments[0];if(this.state===H.EditorState.EDITING||e)if(this.TD=this.getEditedCell(),this.TD){var t,n=this.hot.view.wt,r=n.wtOverlays,o=n.wtViewport,i=(0,L.offset)(this.TD),a=(0,L.offset)(this.hot.rootElement),s=r.topOverlay.holder,l=r.leftOverlay.holder,u=this.hot.countRows(),c=s!==this.hot.rootWindow?s.scrollTop:0,h=l!==this.hot.rootWindow?l.scrollLeft:0,d=this.checkEditorSection(),f=["","left"].includes(d)?c:0,g=["","top","bottom"].includes(d)?h:0,v=i.top===a.top?0:1,p=this.hot.getSettings(),m=this.hot.hasColHeaders(),y=this.TD.style.backgroundColor,w=i.top-a.top-v-f,C=i.left-a.left-1-g;switch(d){case"top":t=(0,L.getCssTransform)(r.topOverlay.clone.wtTable.holder.parentNode);break;case"left":t=(0,L.getCssTransform)(r.leftOverlay.clone.wtTable.holder.parentNode);break;case"top-left-corner":t=(0,L.getCssTransform)(r.topLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom-left-corner":t=(0,L.getCssTransform)(r.bottomLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom":t=(0,L.getCssTransform)(r.bottomOverlay.clone.wtTable.holder.parentNode)}(m&&0===this.hot.getSelectedLast()[0]||p.fixedRowsBottom&&this.hot.getSelectedLast()[0]===u-p.fixedRowsBottom)&&(w+=1),0===this.hot.getSelectedLast()[1]&&(C+=1),t&&-1!==t?this.textareaParentStyle[t[0]]=t[1]:(0,L.resetCssTransform)(this.TEXTAREA_PARENT),this.textareaParentStyle.top="".concat(w,"px"),this.textareaParentStyle.left="".concat(C,"px"),this.showEditableElement();var E=o.rowsRenderCalculator.startPosition,S=o.columnsRenderCalculator.startPosition,b=r.leftOverlay.getScrollPosition(),T=r.topOverlay.getScrollPosition(),R=(0,L.getScrollbarWidth)(this.hot.rootDocument),_=this.TD.offsetTop+E-T,k=this.TD.offsetLeft+S-b,O=(0,L.innerWidth)(this.TD)-8,M=(0,L.hasVerticalScrollbar)(s)?R:0,N=(0,L.hasHorizontalScrollbar)(l)?R:0,A=this.hot.view.maximumVisibleElementWidth(k)-9-M,I=this.TD.scrollHeight+1,D=Math.max(this.hot.view.maximumVisibleElementHeight(_)-N,23),x=(0,L.getComputedStyle)(this.TD,this.hot.rootWindow);this.TEXTAREA.style.fontSize=x.fontSize,this.TEXTAREA.style.fontFamily=x.fontFamily,this.TEXTAREA.style.backgroundColor=y,this.autoResize.init(this.TEXTAREA,{minHeight:Math.min(I,D),maxHeight:D,minWidth:Math.min(O,A),maxWidth:A},!0)}else e||this.close()}},{key:"bindEvents",value:function(){var e=this;this.eventManager.addEventListener(this.TEXTAREA,"cut",function(e){return(0,m.stopPropagation)(e)}),this.eventManager.addEventListener(this.TEXTAREA,"paste",function(e){return(0,m.stopPropagation)(e)}),this.addHook("afterScrollHorizontally",function(){return e.refreshDimensions()}),this.addHook("afterScrollVertically",function(){return e.refreshDimensions()}),this.addHook("afterColumnResize",function(){e.refreshDimensions(),e.focus()}),this.addHook("afterRowResize",function(){e.refreshDimensions(),e.focus()})}},{key:"allowKeyEventPropagation",value:function(){}},{key:"destroy",value:function(){this.eventManager.destroy(),this.clearHooks()}},{key:"onBeforeKeyDown",value:function(e){var t=(e.ctrlKey||e.metaKey)&&!e.altKey;if(e.target===this.TEXTAREA&&!(0,m.isImmediatePropagationStopped)(e)){switch(e.keyCode){case p.KEY_CODES.ARROW_RIGHT:case p.KEY_CODES.ARROW_LEFT:this.isInFullEditMode()&&(this.isWaiting()||this.allowKeyEventPropagation(e.keyCode)||(0,m.stopImmediatePropagation)(e));break;case p.KEY_CODES.ARROW_UP:case p.KEY_CODES.ARROW_DOWN:this.isInFullEditMode()&&(this.isWaiting()||this.allowKeyEventPropagation(e.keyCode)||(0,m.stopImmediatePropagation)(e));break;case p.KEY_CODES.ENTER:var n=this.hot.selection.isMultiple();if(t&&!n||e.altKey){if(this.isOpened()){var r=(0,L.getCaretPosition)(this.TEXTAREA),o=this.getValue(),i="".concat(o.slice(0,r),"\n").concat(o.slice(r));this.setValue(i),(0,L.setCaretPosition)(this.TEXTAREA,r+1)}else this.beginEditing("".concat(this.originalValue,"\n"));(0,m.stopImmediatePropagation)(e)}e.preventDefault();break;case p.KEY_CODES.BACKSPACE:case p.KEY_CODES.DELETE:case p.KEY_CODES.HOME:case p.KEY_CODES.END:(0,m.stopImmediatePropagation)(e)}-1===[p.KEY_CODES.ARROW_UP,p.KEY_CODES.ARROW_RIGHT,p.KEY_CODES.ARROW_DOWN,p.KEY_CODES.ARROW_LEFT].indexOf(e.keyCode)&&this.autoResize.resize(String.fromCharCode(e.keyCode))}}}]),c}(H.default);t.default=c},function(e,t,n){"use strict";n(59),n(12),n(16),n(64),n(10),n(82),n(14),n(17),t.__esModule=!0,t.sortComparison=function(e,t){return"number"!=typeof e||"number"!=typeof t?o(e,t):e-t},t.toVisualValue=u,t.createArrayAssertion=c,t.toEmptyString=function(e){return null==e?"":e},t.unifyColumnValues=function(e){var t=e;t=a?Array.from(new Set(t)):(0,l.arrayUnique)(t);return t=t.sort(function(e,t){return"number"==typeof e&&"number"==typeof t?e-t:e===t?0:t<e?1:-1})},t.intersectValues=function(e,t,r,o){var i,a=[],s=e===t;s||(i=c(t));return(0,l.arrayEach)(e,function(e){var t=!1;(s||i(e))&&(t=!0);var n={checked:t,value:e,visualValue:u(e,r)};o&&o(n),a.push(n)}),a};var r=n(73),l=n(3),o=(0,r.getComparisonFunction)();function u(e,t){var n=e;return""===n&&(n="(".concat(t,")")),n}var i=new Set([1]).has(1),a=i&&"function"==typeof Array.from;function c(e){var t=e;return i&&(t=new Set(t)),function(e){return i?t.has(e):!!~t.indexOf(e)}}},function(e,t,n){"use strict";n(51),t.__esModule=!0,t.getOperationFunc=function(e){if(!r[e])throw Error('Operation with id "'.concat(e,'" does not exist.'));var n=r[e].func;return function(e,t){return n(e,t)}},t.getOperationName=function(e){return r[e].name},t.registerOperation=function(e,t,n){r[e]={name:t,func:n}},t.operations=void 0;var r={};t.operations=r},function(e,t,n){"use strict";var r=n(9),o=n(0);n(138),t.__esModule=!0,t.default=void 0;var i=o(n(1)),a=o(n(2)),s=n(4),l=o(n(57)),u=o(n(23)),c=n(5),h=n(3),d=r(n(11)),f="building",g=["click","input","keydown","keypress","keyup","focus","blur","change"],v=function(){function n(e,t){(0,i.default)(this,n),this.hot=e,this.eventManager=new u.default(this),this.options=(0,s.extend)(n.DEFAULTS,t),this._element=this.hot.rootDocument.createElement(this.options.wrapIt?"div":this.options.tagName),this.buildState=!1}return(0,a.default)(n,null,[{key:"DEFAULTS",get:function(){return(0,s.clone)({className:"",value:"",tagName:"div",children:[],wrapIt:!0})}}]),(0,a.default)(n,[{key:"setValue",value:function(e){this.options.value=e,this.update()}},{key:"getValue",value:function(){return this.options.value}},{key:"isBuilt",value:function(){return"built"===this.buildState}},{key:"translateIfPossible",value:function(e){return"string"==typeof e&&e.startsWith(d.FILTERS_NAMESPACE)?this.hot.getTranslatedPhrase(e):e}},{key:"build",value:function(){var n=this,t=function(e,t){n.eventManager.addEventListener(e,t,function(e){return n.runLocalHooks(t,e,n)})};if(this.buildState||(this.buildState=f),this.options.className&&(0,c.addClass)(this._element,this.options.className),this.options.children.length)(0,h.arrayEach)(this.options.children,function(e){return n._element.appendChild(e.element)});else if(this.options.wrapIt){var r=this.hot.rootDocument.createElement(this.options.tagName);(0,s.objectEach)(this.options,function(e,t){void 0!==r[t]&&"className"!==t&&"tagName"!==t&&"children"!==t&&(r[t]=n.translateIfPossible(e))}),this._element.appendChild(r),(0,h.arrayEach)(g,function(e){return t(r,e)})}else(0,h.arrayEach)(g,function(e){return t(n._element,e)})}},{key:"update",value:function(){}},{key:"reset",value:function(){this.options.value="",this.update()}},{key:"show",value:function(){this.element.style.display=""}},{key:"hide",value:function(){this.element.style.display="none"}},{key:"focus",value:function(){}},{key:"destroy",value:function(){this.eventManager.destroy(),this.eventManager=null,this.hot=null,this._element.parentNode&&this._element.parentNode.removeChild(this._element),this._element=null}},{key:"element",get:function(){return this.buildState===f||("built"===this.buildState?this.update():(this.buildState=f,this.build(),this.buildState="built")),this._element}}]),n}();(0,s.mixin)(v,l.default);var p=v;t.default=p},function(module,exports,__webpack_require__){var Iia;"undefined"!=typeof self&&self,Iia=function(){return function(n){var r={};function o(e){if(r[e])return r[e].exports;var t=r[e]={i:e,l:!1,exports:{}};return n[e].call(t.exports,t,t.exports,o),t.l=!0,t.exports}return o.m=n,o.c=r,o.d=function(e,t,n){o.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:n})},o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,"a",t),t},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.p="",o(o.s=14)}([function(e,t){t.nil=new Error("#NULL!"),t.div0=new Error("#DIV/0!"),t.value=new Error("#VALUE!"),t.ref=new Error("#REF!"),t.name=new Error("#NAME?"),t.num=new Error("#NUM!"),t.na=new Error("#N/A"),t.error=new Error("#ERROR!"),t.data=new Error("#GETTING_DATA")},function(e,r,t){var o=t(0);r.flattenShallow=function(e){return e&&e.reduce?e.reduce(function(e,t){var n=Array.isArray(e),r=Array.isArray(t);return n&&r?e.concat(t):n?(e.push(t),e):r?[e].concat(t):[e,t]}):e},r.isFlat=function(e){if(!e)return!1;for(var t=0;t<e.length;++t)if(Array.isArray(e[t]))return!1;return!0},r.flatten=function(){for(var e=r.argsToArray.apply(null,arguments);!r.isFlat(e);)e=r.flattenShallow(e);return e},r.argsToArray=function(e){var t=[];return r.arrayEach(e,function(e){t.push(e)}),t},r.numbers=function(){return this.flatten.apply(null,arguments).filter(function(e){return"number"==typeof e})},r.cleanFloat=function(e){return Math.round(1e14*e)/1e14},r.parseBool=function(e){if("boolean"==typeof e)return e;if(e instanceof Error)return e;if("number"==typeof e)return 0!==e;if("string"==typeof e){var t=e.toUpperCase();if("TRUE"===t)return!0;if("FALSE"===t)return!1}return e instanceof Date&&!isNaN(e)||o.value},r.parseNumber=function(e){return void 0===e||""===e?o.value:isNaN(e)?o.value:parseFloat(e)},r.parseNumberArray=function(e){var t,n;if(!e||0===(t=e.length))return o.value;for(;t--;){if((n=r.parseNumber(e[t]))===o.value)return n;e[t]=n}return e},r.parseMatrix=function(e){var t;if(!e||0===e.length)return o.value;for(var n=0;n<e.length;n++)if(t=r.parseNumberArray(e[n]),(e[n]=t)instanceof Error)return t;return e};var n=new Date(Date.UTC(1900,0,1));r.parseDate=function(e){if(isNaN(e))return"string"!=typeof e||(e=new Date(e),isNaN(e))?o.value:e;if(e instanceof Date)return new Date(e);var t=parseInt(e,10);return t<0?o.num:t<=60?new Date(n.getTime()+864e5*(t-1)):new Date(n.getTime()+864e5*(t-2))},r.parseDateArray=function(e){for(var t,n=e.length;n--;){if((t=this.parseDate(e[n]))===o.value)return t;e[n]=t}return e},r.anyIsError=function(){for(var e=arguments.length;e--;)if(arguments[e]instanceof Error)return!0;return!1},r.arrayValuesToNumbers=function(e){for(var t,n=e.length;n--;)if("number"!=typeof(t=e[n]))if(!0!==t)if(!1!==t){if("string"==typeof t){var r=this.parseNumber(t);r instanceof Error?e[n]=0:e[n]=r}}else e[n]=0;else e[n]=1;return e},r.rest=function(e,t){return t=t||1,e&&"function"==typeof e.slice?e.slice(t):e},r.initial=function(e,t){return t=t||1,e&&"function"==typeof e.slice?e.slice(0,e.length-t):e},r.arrayEach=function(e,t){for(var n=-1,r=e.length;++n<r&&!1!==t(e[n],n,e););return e},r.transpose=function(n){return n?n[0].map(function(e,t){return n.map(function(e){return e[t]})}):o.value}},function(e,t,n){"use strict";var r;t.__esModule=!0,t.default=function(e){var t=void 0;e=(e+"").replace(/#|!|\?/g,""),d[e]&&(t=d[e]);return t||null},t.isValidStrict=function(e){var t=!1;for(var n in d)if(Object.prototype.hasOwnProperty.call(d,n)&&d[n]===e){t=!0;break}return t};var o=t.ERROR="ERROR",i=t.ERROR_DIV_ZERO="DIV/0",a=t.ERROR_NAME="NAME",s=t.ERROR_NOT_AVAILABLE="N/A",l=t.ERROR_NULL="NULL",u=t.ERROR_NUM="NUM",c=t.ERROR_REF="REF",h=t.ERROR_VALUE="VALUE",d=((r={})[o]="#ERROR!",r[i]="#DIV/0!",r[a]="#NAME?",r[s]="#N/A",r[l]="#NULL!",r[u]="#NUM!",r[c]="#REF!",r[h]="#VALUE!",r)},function(e,t,n){"use strict";function r(e){var t=void 0;return"number"==typeof e?t=e:"string"==typeof e&&(t=-1<e.indexOf(".")?parseFloat(e):parseInt(e,10)),t}t.__esModule=!0,t.toNumber=r,t.invertNumber=function(e){return-1*r(e)}},function(module,exports,__webpack_require__){var utils=__webpack_require__(1),error=__webpack_require__(0),statistical=__webpack_require__(5),information=__webpack_require__(7);exports.ABS=function(e){return(e=utils.parseNumber(e))instanceof Error?e:Math.abs(e)},exports.ACOS=function(e){if((e=utils.parseNumber(e))instanceof Error)return e;var t=Math.acos(e);return isNaN(t)&&(t=error.num),t},exports.ACOSH=function(e){if((e=utils.parseNumber(e))instanceof Error)return e;var t=Math.log(e+Math.sqrt(e*e-1));return isNaN(t)&&(t=error.num),t},exports.ACOT=function(e){return(e=utils.parseNumber(e))instanceof Error?e:Math.atan(1/e)},exports.ACOTH=function(e){if((e=utils.parseNumber(e))instanceof Error)return e;var t=.5*Math.log((e+1)/(e-1));return isNaN(t)&&(t=error.num),t},exports.AGGREGATE=function(e,t,n,r){if(e=utils.parseNumber(e),t=utils.parseNumber(e),utils.anyIsError(e,t))return error.value;switch(e){case 1:return statistical.AVERAGE(n);case 2:return statistical.COUNT(n);case 3:return statistical.COUNTA(n);case 4:return statistical.MAX(n);case 5:return statistical.MIN(n);case 6:return exports.PRODUCT(n);case 7:return statistical.STDEV.S(n);case 8:return statistical.STDEV.P(n);case 9:return exports.SUM(n);case 10:return statistical.VAR.S(n);case 11:return statistical.VAR.P(n);case 12:return statistical.MEDIAN(n);case 13:return statistical.MODE.SNGL(n);case 14:return statistical.LARGE(n,r);case 15:return statistical.SMALL(n,r);case 16:return statistical.PERCENTILE.INC(n,r);case 17:return statistical.QUARTILE.INC(n,r);case 18:return statistical.PERCENTILE.EXC(n,r);case 19:return statistical.QUARTILE.EXC(n,r)}},exports.ARABIC=function(e){if(!/^M*(?:D?C{0,3}|C[MD])(?:L?X{0,3}|X[CL])(?:V?I{0,3}|I[XV])$/.test(e))return error.value;var t=0;return e.replace(/[MDLV]|C[MD]?|X[CL]?|I[XV]?/g,function(e){t+={M:1e3,CM:900,D:500,CD:400,C:100,XC:90,L:50,XL:40,X:10,IX:9,V:5,IV:4,I:1}[e]}),t},exports.ASIN=function(e){if((e=utils.parseNumber(e))instanceof Error)return e;var t=Math.asin(e);return isNaN(t)&&(t=error.num),t},exports.ASINH=function(e){return(e=utils.parseNumber(e))instanceof Error?e:Math.log(e+Math.sqrt(e*e+1))},exports.ATAN=function(e){return(e=utils.parseNumber(e))instanceof Error?e:Math.atan(e)},exports.ATAN2=function(e,t){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:Math.atan2(e,t)},exports.ATANH=function(e){if((e=utils.parseNumber(e))instanceof Error)return e;var t=Math.log((1+e)/(1-e))/2;return isNaN(t)&&(t=error.num),t},exports.BASE=function(e,t,n){if(n=n||0,e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),utils.anyIsError(e,t,n))return error.value;n=void 0===n?0:n;var r=e.toString(t);return new Array(Math.max(n+1-r.length,0)).join("0")+r},exports.CEILING=function(e,t,n){if(t=void 0===t?1:Math.abs(t),n=n||0,e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),utils.anyIsError(e,t,n))return error.value;if(0===t)return 0;var r=-Math.floor(Math.log(t)/Math.log(10));return 0<=e?exports.ROUND(Math.ceil(e/t)*t,r):0===n?-exports.ROUND(Math.floor(Math.abs(e)/t)*t,r):-exports.ROUND(Math.ceil(Math.abs(e)/t)*t,r)},exports.CEILING.MATH=exports.CEILING,exports.CEILING.PRECISE=exports.CEILING,exports.COMBIN=function(e,t){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:exports.FACT(e)/(exports.FACT(t)*exports.FACT(e-t))},exports.COMBINA=function(e,t){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:0===e&&0===t?1:exports.COMBIN(e+t-1,e-1)},exports.COS=function(e){return(e=utils.parseNumber(e))instanceof Error?e:Math.cos(e)},exports.COSH=function(e){return(e=utils.parseNumber(e))instanceof Error?e:(Math.exp(e)+Math.exp(-e))/2},exports.COT=function(e){return(e=utils.parseNumber(e))instanceof Error?e:1/Math.tan(e)},exports.COTH=function(e){if((e=utils.parseNumber(e))instanceof Error)return e;var t=Math.exp(2*e);return(t+1)/(t-1)},exports.CSC=function(e){return(e=utils.parseNumber(e))instanceof Error?e:1/Math.sin(e)},exports.CSCH=function(e){return(e=utils.parseNumber(e))instanceof Error?e:2/(Math.exp(e)-Math.exp(-e))},exports.DECIMAL=function(e,t){return arguments.length<1?error.value:parseInt(e,t)},exports.DEGREES=function(e){return(e=utils.parseNumber(e))instanceof Error?e:180*e/Math.PI},exports.EVEN=function(e){return(e=utils.parseNumber(e))instanceof Error?e:exports.CEILING(e,-2,-1)},exports.EXP=function(e){return arguments.length<1?error.na:"number"!=typeof e||1<arguments.length?error.error:e=Math.exp(e)};var MEMOIZED_FACT=[];exports.FACT=function(e){if((e=utils.parseNumber(e))instanceof Error)return e;var t=Math.floor(e);return 0===t||1===t?1:(0<MEMOIZED_FACT[t]||(MEMOIZED_FACT[t]=exports.FACT(t-1)*t),MEMOIZED_FACT[t])},exports.FACTDOUBLE=function(e){if((e=utils.parseNumber(e))instanceof Error)return e;var t=Math.floor(e);return t<=0?1:t*exports.FACTDOUBLE(t-2)},exports.FLOOR=function(e,t){if(e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t))return error.value;if(0===t)return 0;if(!(0<e&&0<t||e<0&&t<0))return error.num;t=Math.abs(t);var n=-Math.floor(Math.log(t)/Math.log(10));return 0<=e?exports.ROUND(Math.floor(e/t)*t,n):-exports.ROUND(Math.ceil(Math.abs(e)/t),n)},exports.FLOOR.MATH=function(e,t,n){if(t=void 0===t?1:t,n=void 0===n?0:n,e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),utils.anyIsError(e,t,n))return error.value;if(0===t)return 0;t=t?Math.abs(t):1;var r=-Math.floor(Math.log(t)/Math.log(10));return 0<=e?exports.ROUND(Math.floor(e/t)*t,r):0===n||void 0===n?-exports.ROUND(Math.ceil(Math.abs(e)/t)*t,r):-exports.ROUND(Math.floor(Math.abs(e)/t)*t,r)},exports.FLOOR.PRECISE=exports.FLOOR.MATH,exports.GCD=function(){var e=utils.parseNumberArray(utils.flatten(arguments));if(e instanceof Error)return e;for(var t=e.length,n=e[0],r=n<0?-n:n,o=1;o<t;o++){for(var i=e[o],a=i<0?-i:i;r&&a;)a<r?r%=a:a%=r;r+=a}return r},exports.INT=function(e){return(e=utils.parseNumber(e))instanceof Error?e:Math.floor(e)},exports.ISO={CEILING:exports.CEILING},exports.LCM=function(){var e=utils.parseNumberArray(utils.flatten(arguments));if(e instanceof Error)return e;for(var t,n,r,o,i=1;void 0!==(r=e.pop());)for(;1<r;){if(r%2){for(t=3,n=Math.floor(Math.sqrt(r));t<=n&&r%t;t+=2);o=t<=n?t:r}else o=2;for(r/=o,i*=o,t=e.length;t;e[--t]%o==0&&1==(e[t]/=o)&&e.splice(t,1));}return i},exports.LN=function(e){return(e=utils.parseNumber(e))instanceof Error?e:Math.log(e)},exports.LN10=function(){return Math.log(10)},exports.LN2=function(){return Math.log(2)},exports.LOG10E=function(){return Math.LOG10E},exports.LOG2E=function(){return Math.LOG2E},exports.LOG=function(e,t){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:(t=void 0===t?10:t,Math.log(e)/Math.log(t))},exports.LOG10=function(e){return(e=utils.parseNumber(e))instanceof Error?e:Math.log(e)/Math.log(10)},exports.MOD=function(e,t){if(e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t))return error.value;if(0===t)return error.div0;var n=Math.abs(e%t);return 0<t?n:-n},exports.MROUND=function(e,t){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:e*t<0?error.num:Math.round(e/t)*t},exports.MULTINOMIAL=function(){var e=utils.parseNumberArray(utils.flatten(arguments));if(e instanceof Error)return e;for(var t=0,n=1,r=0;r<e.length;r++)t+=e[r],n*=exports.FACT(e[r]);return exports.FACT(t)/n},exports.ODD=function(e){if((e=utils.parseNumber(e))instanceof Error)return e;var t=Math.ceil(Math.abs(e));return t=1&t?t:t+1,0<e?t:-t},exports.PI=function(){return Math.PI},exports.E=function(){return Math.E},exports.POWER=function(e,t){if(e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t))return error.value;var n=Math.pow(e,t);return isNaN(n)?error.num:n},exports.PRODUCT=function(){var e=utils.parseNumberArray(utils.flatten(arguments));if(e instanceof Error)return e;for(var t=1,n=0;n<e.length;n++)t*=e[n];return t},exports.QUOTIENT=function(e,t){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:parseInt(e/t,10)},exports.RADIANS=function(e){return(e=utils.parseNumber(e))instanceof Error?e:e*Math.PI/180},exports.RAND=function(){return Math.random()},exports.RANDBETWEEN=function(e,t){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:e+Math.ceil((t-e+1)*Math.random())-1},exports.ROMAN=function(e){if((e=utils.parseNumber(e))instanceof Error)return e;for(var t=String(e).split(""),n=["","C","CC","CCC","CD","D","DC","DCC","DCCC","CM","","X","XX","XXX","XL","L","LX","LXX","LXXX","XC","","I","II","III","IV","V","VI","VII","VIII","IX"],r="",o=3;o--;)r=(n[+t.pop()+10*o]||"")+r;return new Array(+t.join("")+1).join("M")+r},exports.ROUND=function(e,t){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:Math.round(e*Math.pow(10,t))/Math.pow(10,t)},exports.ROUNDDOWN=function(e,t){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:(0<e?1:-1)*Math.floor(Math.abs(e)*Math.pow(10,t))/Math.pow(10,t)},exports.ROUNDUP=function(e,t){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:(0<e?1:-1)*Math.ceil(Math.abs(e)*Math.pow(10,t))/Math.pow(10,t)},exports.SEC=function(e){return(e=utils.parseNumber(e))instanceof Error?e:1/Math.cos(e)},exports.SECH=function(e){return(e=utils.parseNumber(e))instanceof Error?e:2/(Math.exp(e)+Math.exp(-e))},exports.SERIESSUM=function(e,t,n,r){if(e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),r=utils.parseNumberArray(r),utils.anyIsError(e,t,n,r))return error.value;for(var o=r[0]*Math.pow(e,t),i=1;i<r.length;i++)o+=r[i]*Math.pow(e,t+i*n);return o},exports.SIGN=function(e){return(e=utils.parseNumber(e))instanceof Error?e:e<0?-1:0===e?0:1},exports.SIN=function(e){return(e=utils.parseNumber(e))instanceof Error?e:Math.sin(e)},exports.SINH=function(e){return(e=utils.parseNumber(e))instanceof Error?e:(Math.exp(e)-Math.exp(-e))/2},exports.SQRT=function(e){return(e=utils.parseNumber(e))instanceof Error?e:e<0?error.num:Math.sqrt(e)},exports.SQRTPI=function(e){return(e=utils.parseNumber(e))instanceof Error?e:Math.sqrt(e*Math.PI)},exports.SQRT1_2=function(){return 1/Math.sqrt(2)},exports.SQRT2=function(){return Math.sqrt(2)},exports.SUBTOTAL=function(e,t){if((e=utils.parseNumber(e))instanceof Error)return e;switch(e){case 1:return statistical.AVERAGE(t);case 2:return statistical.COUNT(t);case 3:return statistical.COUNTA(t);case 4:return statistical.MAX(t);case 5:return statistical.MIN(t);case 6:return exports.PRODUCT(t);case 7:return statistical.STDEV.S(t);case 8:return statistical.STDEV.P(t);case 9:return exports.SUM(t);case 10:return statistical.VAR.S(t);case 11:return statistical.VAR.P(t);case 101:return statistical.AVERAGE(t);case 102:return statistical.COUNT(t);case 103:return statistical.COUNTA(t);case 104:return statistical.MAX(t);case 105:return statistical.MIN(t);case 106:return exports.PRODUCT(t);case 107:return statistical.STDEV.S(t);case 108:return statistical.STDEV.P(t);case 109:return exports.SUM(t);case 110:return statistical.VAR.S(t);case 111:return statistical.VAR.P(t)}},exports.ADD=function(e,t){return 2!==arguments.length?error.na:(e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:e+t)},exports.MINUS=function(e,t){return 2!==arguments.length?error.na:(e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:e-t)},exports.DIVIDE=function(e,t){return 2!==arguments.length?error.na:(e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:0===t?error.div0:e/t)},exports.MULTIPLY=function(e,t){return 2!==arguments.length?error.na:(e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:e*t)},exports.GTE=function(e,t){return 2!==arguments.length?error.na:(e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.error:t<=e)},exports.LT=function(e,t){return 2!==arguments.length?error.na:(e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.error:e<t)},exports.LTE=function(e,t){return 2!==arguments.length?error.na:(e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.error:e<=t)},exports.EQ=function(e,t){return 2!==arguments.length?error.na:e===t},exports.NE=function(e,t){return 2!==arguments.length?error.na:e!==t},exports.POW=function(e,t){return 2!==arguments.length?error.na:(e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.error:exports.POWER(e,t))},exports.SUM=function(){var n=0;return utils.arrayEach(utils.argsToArray(arguments),function(e){if("number"==typeof e)n+=e;else if("string"==typeof e){var t=parseFloat(e);!isNaN(t)&&(n+=t)}else Array.isArray(e)&&(n+=exports.SUM.apply(null,e))}),n},exports.SUMIF=function(range,criteria){if(range=utils.parseNumberArray(utils.flatten(range)),range instanceof Error)return range;for(var result=0,i=0;i<range.length;i++)result+=eval(range[i]+criteria)?range[i]:0;return result},exports.SUMIFS=function(){var args=utils.argsToArray(arguments),range=utils.parseNumberArray(utils.flatten(args.shift()));if(range instanceof Error)return range;for(var criteria=args,n_range_elements=range.length,n_criterias=criteria.length,result=0,i=0;i<n_range_elements;i++){for(var el=range[i],condition="",c=0;c<n_criterias;c++)condition+=el+criteria[c],c!==n_criterias-1&&(condition+="&&");eval(condition)&&(result+=el)}return result},exports.SUMPRODUCT=function(){if(!arguments||0===arguments.length)return error.value;for(var e,t,n,r,o=arguments.length+1,i=0,a=0;a<arguments[0].length;a++)if(arguments[0][a]instanceof Array)for(var s=0;s<arguments[0][a].length;s++){for(t=e=1;t<o;t++){if((r=utils.parseNumber(arguments[t-1][a][s]))instanceof Error)return r;e*=r}i+=e}else{for(t=e=1;t<o;t++){if((n=utils.parseNumber(arguments[t-1][a]))instanceof Error)return n;e*=n}i+=e}return i},exports.SUMSQ=function(){var e=utils.parseNumberArray(utils.flatten(arguments));if(e instanceof Error)return e;for(var t=0,n=e.length,r=0;r<n;r++)t+=information.ISNUMBER(e[r])?e[r]*e[r]:0;return t},exports.SUMX2MY2=function(e,t){if(e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumberArray(utils.flatten(t)),utils.anyIsError(e,t))return error.value;for(var n=0,r=0;r<e.length;r++)n+=e[r]*e[r]-t[r]*t[r];return n},exports.SUMX2PY2=function(e,t){if(e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumberArray(utils.flatten(t)),utils.anyIsError(e,t))return error.value;var n=0;e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumberArray(utils.flatten(t));for(var r=0;r<e.length;r++)n+=e[r]*e[r]+t[r]*t[r];return n},exports.SUMXMY2=function(e,t){if(e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumberArray(utils.flatten(t)),utils.anyIsError(e,t))return error.value;var n=0;e=utils.flatten(e),t=utils.flatten(t);for(var r=0;r<e.length;r++)n+=Math.pow(e[r]-t[r],2);return n},exports.TAN=function(e){return(e=utils.parseNumber(e))instanceof Error?e:Math.tan(e)},exports.TANH=function(e){if((e=utils.parseNumber(e))instanceof Error)return e;var t=Math.exp(2*e);return(t-1)/(t+1)},exports.TRUNC=function(e,t){return t=void 0===t?0:t,e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:(0<e?1:-1)*Math.floor(Math.abs(e)*Math.pow(10,t))/Math.pow(10,t)}},function(module,exports,__webpack_require__){var mathTrig=__webpack_require__(4),text=__webpack_require__(6),jStat=__webpack_require__(9).jStat,utils=__webpack_require__(1),error=__webpack_require__(0),misc=__webpack_require__(10),SQRT2PI=2.5066282746310002;exports.AVEDEV=function(){var e=utils.parseNumberArray(utils.flatten(arguments));return e instanceof Error?e:jStat.sum(jStat(e).subtract(jStat.mean(e)).abs()[0])/e.length},exports.AVERAGE=function(){for(var e,t=utils.numbers(utils.flatten(arguments)),n=t.length,r=0,o=0,i=0;i<n;i++)r+=t[i],o+=1;return e=r/o,isNaN(e)&&(e=error.num),e},exports.AVERAGEA=function(){for(var e,t=utils.flatten(arguments),n=t.length,r=0,o=0,i=0;i<n;i++){var a=t[i];"number"==typeof a&&(r+=a),!0===a&&r++,null!==a&&o++}return e=r/o,isNaN(e)&&(e=error.num),e},exports.AVERAGEIF=function(range,criteria,average_range){if(arguments.length<=1)return error.na;if(average_range=average_range||range,range=utils.flatten(range),average_range=utils.parseNumberArray(utils.flatten(average_range)),average_range instanceof Error)return average_range;for(var average_count=0,result=0,i=0;i<range.length;i++)eval(range[i]+criteria)&&(result+=average_range[i],average_count++);return result/average_count},exports.AVERAGEIFS=function(){for(var args=utils.argsToArray(arguments),criteria=(args.length-1)/2,range=utils.flatten(args[0]),count=0,result=0,i=0;i<range.length;i++){for(var condition="",j=0;j<criteria;j++)condition+=args[2*j+1][i]+args[2*j+2],j!==criteria-1&&(condition+="&&");eval(condition)&&(result+=range[i],count++)}var average=result/count;return isNaN(average)?0:average},exports.BETA={},exports.BETA.DIST=function(e,t,n,r,o,i){return arguments.length<4?error.value:(o=void 0===o?0:o,i=void 0===i?1:i,e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),o=utils.parseNumber(o),i=utils.parseNumber(i),utils.anyIsError(e,t,n,o,i)?error.value:(e=(e-o)/(i-o),r?jStat.beta.cdf(e,t,n):jStat.beta.pdf(e,t,n)))},exports.BETA.INV=function(e,t,n,r,o){return r=void 0===r?0:r,o=void 0===o?1:o,e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),r=utils.parseNumber(r),o=utils.parseNumber(o),utils.anyIsError(e,t,n,r,o)?error.value:jStat.beta.inv(e,t,n)*(o-r)+r},exports.BINOM={},exports.BINOM.DIST=function(e,t,n,r){return e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),r=utils.parseNumber(r),utils.anyIsError(e,t,n,r)?error.value:r?jStat.binomial.cdf(e,t,n):jStat.binomial.pdf(e,t,n)},exports.BINOM.DIST.RANGE=function(e,t,n,r){if(r=void 0===r?n:r,e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),r=utils.parseNumber(r),utils.anyIsError(e,t,n,r))return error.value;for(var o=0,i=n;i<=r;i++)o+=mathTrig.COMBIN(e,i)*Math.pow(t,i)*Math.pow(1-t,e-i);return o},exports.BINOM.INV=function(e,t,n){if(e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),utils.anyIsError(e,t,n))return error.value;for(var r=0;r<=e;){if(jStat.binomial.cdf(r,e,t)>=n)return r;r++}},exports.CHISQ={},exports.CHISQ.DIST=function(e,t,n){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:n?jStat.chisquare.cdf(e,t):jStat.chisquare.pdf(e,t)},exports.CHISQ.DIST.RT=function(e,t){return!e|!t?error.na:e<1||t>Math.pow(10,10)?error.num:"number"!=typeof e||"number"!=typeof t?error.value:1-jStat.chisquare.cdf(e,t)},exports.CHISQ.INV=function(e,t){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:jStat.chisquare.inv(e,t)},exports.CHISQ.INV.RT=function(e,t){return!e|!t?error.na:e<0||1<e||t<1||t>Math.pow(10,10)?error.num:"number"!=typeof e||"number"!=typeof t?error.value:jStat.chisquare.inv(1-e,t)},exports.CHISQ.TEST=function(e,t){if(2!==arguments.length)return error.na;if(!(e instanceof Array&&t instanceof Array))return error.value;if(e.length!==t.length)return error.value;if(e[0]&&t[0]&&e[0].length!==t[0].length)return error.value;var n,r,o,i=e.length;for(r=0;r<i;r++)e[r]instanceof Array||(n=e[r],e[r]=[],e[r].push(n)),t[r]instanceof Array||(n=t[r],t[r]=[],t[r].push(n));var a=e[0].length,s=1===a?i-1:(i-1)*(a-1),l=0,u=Math.PI;for(r=0;r<i;r++)for(o=0;o<a;o++)l+=Math.pow(e[r][o]-t[r][o],2)/t[r][o];return Math.round(1e6*function(e,t){var n=Math.exp(-.5*e);t%2==1&&(n*=Math.sqrt(2*e/u));for(var r=t;2<=r;)n=n*e/r,r-=2;for(var o=n,i=t;1e-10*n<o;)n+=o=o*e/(i+=2);return 1-n}(l,s))/1e6},exports.COLUMN=function(e,t){return 2!==arguments.length?error.na:t<0?error.num:e instanceof Array&&"number"==typeof t?0!==e.length?jStat.col(e,t):void 0:error.value},exports.COLUMNS=function(e){return 1!==arguments.length?error.na:e instanceof Array?0===e.length?0:jStat.cols(e):error.value},exports.CONFIDENCE={},exports.CONFIDENCE.NORM=function(e,t,n){return e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),utils.anyIsError(e,t,n)?error.value:jStat.normalci(1,e,t,n)[1]-1},exports.CONFIDENCE.T=function(e,t,n){return e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),utils.anyIsError(e,t,n)?error.value:jStat.tci(1,e,t,n)[1]-1},exports.CORREL=function(e,t){return e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumberArray(utils.flatten(t)),utils.anyIsError(e,t)?error.value:jStat.corrcoeff(e,t)},exports.COUNT=function(){return utils.numbers(utils.flatten(arguments)).length},exports.COUNTA=function(){var e=utils.flatten(arguments);return e.length-exports.COUNTBLANK(e)},exports.COUNTIN=function(e,t){var n=0;e=utils.flatten(e);for(var r=0;r<e.length;r++)e[r]===t&&n++;return n},exports.COUNTBLANK=function(){for(var e,t=utils.flatten(arguments),n=0,r=0;r<t.length;r++)null!==(e=t[r])&&""!==e||n++;return n},exports.COUNTIF=function(range,criteria){range=utils.flatten(range),/[<>=!]/.test(criteria)||(criteria='=="'+criteria+'"');for(var matches=0,i=0;i<range.length;i++)"string"!=typeof range[i]?eval(range[i]+criteria)&&matches++:eval('"'+range[i]+'"'+criteria)&&matches++;return matches},exports.COUNTIFS=function(){for(var args=utils.argsToArray(arguments),results=new Array(utils.flatten(args[0]).length),i=0;i<results.length;i++)results[i]=!0;for(i=0;i<args.length;i+=2){var range=utils.flatten(args[i]),criteria=args[i+1];/[<>=!]/.test(criteria)||(criteria='=="'+criteria+'"');for(var j=0;j<range.length;j++)"string"!=typeof range[j]?results[j]=results[j]&&eval(range[j]+criteria):results[j]=results[j]&&eval('"'+range[j]+'"'+criteria)}var result=0;for(i=0;i<results.length;i++)results[i]&&result++;return result},exports.COUNTUNIQUE=function(){return misc.UNIQUE.apply(null,utils.flatten(arguments)).length},exports.COVARIANCE={},exports.COVARIANCE.P=function(e,t){if(e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumberArray(utils.flatten(t)),utils.anyIsError(e,t))return error.value;for(var n=jStat.mean(e),r=jStat.mean(t),o=0,i=e.length,a=0;a<i;a++)o+=(e[a]-n)*(t[a]-r);return o/i},exports.COVARIANCE.S=function(e,t){return e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumberArray(utils.flatten(t)),utils.anyIsError(e,t)?error.value:jStat.covariance(e,t)},exports.DEVSQ=function(){var e=utils.parseNumberArray(utils.flatten(arguments));if(e instanceof Error)return e;for(var t=jStat.mean(e),n=0,r=0;r<e.length;r++)n+=Math.pow(e[r]-t,2);return n},exports.EXPON={},exports.EXPON.DIST=function(e,t,n){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:n?jStat.exponential.cdf(e,t):jStat.exponential.pdf(e,t)},exports.F={},exports.F.DIST=function(e,t,n,r){return e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),utils.anyIsError(e,t,n)?error.value:r?jStat.centralF.cdf(e,t,n):jStat.centralF.pdf(e,t,n)},exports.F.DIST.RT=function(e,t,n){return 3!==arguments.length?error.na:e<0||t<1||n<1?error.num:"number"!=typeof e||"number"!=typeof t||"number"!=typeof n?error.value:1-jStat.centralF.cdf(e,t,n)},exports.F.INV=function(e,t,n){return e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),utils.anyIsError(e,t,n)?error.value:e<=0||1<e?error.num:jStat.centralF.inv(e,t,n)},exports.F.INV.RT=function(e,t,n){return 3!==arguments.length?error.na:e<0||1<e||t<1||t>Math.pow(10,10)||n<1||n>Math.pow(10,10)?error.num:"number"!=typeof e||"number"!=typeof t||"number"!=typeof n?error.value:jStat.centralF.inv(1-e,t,n)},exports.F.TEST=function(e,t){if(!e||!t)return error.na;if(!(e instanceof Array&&t instanceof Array))return error.na;if(e.length<2||t.length<2)return error.div0;var n=function(e,t){for(var n=0,r=0;r<e.length;r++)n+=Math.pow(e[r]-t,2);return n},r=mathTrig.SUM(e)/e.length,o=mathTrig.SUM(t)/t.length;return n(e,r)/(e.length-1)/(n(t,o)/(t.length-1))},exports.FISHER=function(e){return(e=utils.parseNumber(e))instanceof Error?e:Math.log((1+e)/(1-e))/2},exports.FISHERINV=function(e){if((e=utils.parseNumber(e))instanceof Error)return e;var t=Math.exp(2*e);return(t-1)/(t+1)},exports.FORECAST=function(e,t,n){if(e=utils.parseNumber(e),t=utils.parseNumberArray(utils.flatten(t)),n=utils.parseNumberArray(utils.flatten(n)),utils.anyIsError(e,t,n))return error.value;for(var r=jStat.mean(n),o=jStat.mean(t),i=n.length,a=0,s=0,l=0;l<i;l++)a+=(n[l]-r)*(t[l]-o),s+=Math.pow(n[l]-r,2);var u=a/s;return o-u*r+u*e},exports.FREQUENCY=function(e,t){if(e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumberArray(utils.flatten(t)),utils.anyIsError(e,t))return error.value;for(var n=e.length,r=t.length,o=[],i=0;i<=r;i++)for(var a=o[i]=0;a<n;a++)0===i?e[a]<=t[0]&&(o[0]+=1):i<r?e[a]>t[i-1]&&e[a]<=t[i]&&(o[i]+=1):i===r&&e[a]>t[r-1]&&(o[r]+=1);return o},exports.GAMMA=function(e){return(e=utils.parseNumber(e))instanceof Error?e:0===e?error.num:parseInt(e,10)===e&&e<0?error.num:jStat.gammafn(e)},exports.GAMMA.DIST=function(e,t,n,r){return 4!==arguments.length?error.na:e<0||t<=0||n<=0?error.value:"number"!=typeof e||"number"!=typeof t||"number"!=typeof n?error.value:r?jStat.gamma.cdf(e,t,n,!0):jStat.gamma.pdf(e,t,n,!1)},exports.GAMMA.INV=function(e,t,n){return 3!==arguments.length?error.na:e<0||1<e||t<=0||n<=0?error.num:"number"!=typeof e||"number"!=typeof t||"number"!=typeof n?error.value:jStat.gamma.inv(e,t,n)},exports.GAMMALN=function(e){return(e=utils.parseNumber(e))instanceof Error?e:jStat.gammaln(e)},exports.GAMMALN.PRECISE=function(e){return 1!==arguments.length?error.na:e<=0?error.num:"number"!=typeof e?error.value:jStat.gammaln(e)},exports.GAUSS=function(e){return(e=utils.parseNumber(e))instanceof Error?e:jStat.normal.cdf(e,0,1)-.5},exports.GEOMEAN=function(){var e=utils.parseNumberArray(utils.flatten(arguments));return e instanceof Error?e:jStat.geomean(e)},exports.GROWTH=function(e,t,n,r){if((e=utils.parseNumberArray(e))instanceof Error)return e;var o;if(void 0===t)for(t=[],o=1;o<=e.length;o++)t.push(o);if(void 0===n)for(n=[],o=1;o<=e.length;o++)n.push(o);if(t=utils.parseNumberArray(t),n=utils.parseNumberArray(n),utils.anyIsError(t,n))return error.value;void 0===r&&(r=!0);var i,a,s=e.length,l=0,u=0,c=0,h=0;for(o=0;o<s;o++){var d=t[o],f=Math.log(e[o]);l+=d,u+=f,c+=d*f,h+=d*d}l/=s,u/=s,c/=s,h/=s,a=r?u-(i=(c-l*u)/(h-l*l))*l:(i=c/h,0);var g=[];for(o=0;o<n.length;o++)g.push(Math.exp(a+i*n[o]));return g},exports.HARMEAN=function(){var e=utils.parseNumberArray(utils.flatten(arguments));if(e instanceof Error)return e;for(var t=e.length,n=0,r=0;r<t;r++)n+=1/e[r];return t/n},exports.HYPGEOM={},exports.HYPGEOM.DIST=function(e,t,n,r,o){if(e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),r=utils.parseNumber(r),utils.anyIsError(e,t,n,r))return error.value;function a(e,t,n,r){return mathTrig.COMBIN(n,e)*mathTrig.COMBIN(r-n,t-e)/mathTrig.COMBIN(r,t)}return o?function(e,t,n,r){for(var o=0,i=0;i<=e;i++)o+=a(i,t,n,r);return o}(e,t,n,r):a(e,t,n,r)},exports.INTERCEPT=function(e,t){return e=utils.parseNumberArray(e),t=utils.parseNumberArray(t),utils.anyIsError(e,t)?error.value:e.length!==t.length?error.na:exports.FORECAST(0,e,t)},exports.KURT=function(){var e=utils.parseNumberArray(utils.flatten(arguments));if(e instanceof Error)return e;for(var t=jStat.mean(e),n=e.length,r=0,o=0;o<n;o++)r+=Math.pow(e[o]-t,4);return n*(n+1)/((n-1)*(n-2)*(n-3))*(r/=Math.pow(jStat.stdev(e,!0),4))-3*(n-1)*(n-1)/((n-2)*(n-3))},exports.LARGE=function(e,t){return e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumber(t),utils.anyIsError(e,t)?e:e.sort(function(e,t){return t-e})[t-1]},exports.LINEST=function(e,t){if(e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumberArray(utils.flatten(t)),utils.anyIsError(e,t))return error.value;for(var n=jStat.mean(e),r=jStat.mean(t),o=t.length,i=0,a=0,s=0;s<o;s++)i+=(t[s]-r)*(e[s]-n),a+=Math.pow(t[s]-r,2);var l=i/a;return[l,n-l*r]},exports.LOGEST=function(e,t){if(e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumberArray(utils.flatten(t)),utils.anyIsError(e,t))return error.value;for(var n=0;n<e.length;n++)e[n]=Math.log(e[n]);var r=exports.LINEST(e,t);return r[0]=Math.round(1e6*Math.exp(r[0]))/1e6,r[1]=Math.round(1e6*Math.exp(r[1]))/1e6,r},exports.LOGNORM={},exports.LOGNORM.DIST=function(e,t,n,r){return e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),utils.anyIsError(e,t,n)?error.value:r?jStat.lognormal.cdf(e,t,n):jStat.lognormal.pdf(e,t,n)},exports.LOGNORM.INV=function(e,t,n){return e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),utils.anyIsError(e,t,n)?error.value:jStat.lognormal.inv(e,t,n)},exports.MAX=function(){var e=utils.numbers(utils.flatten(arguments));return 0===e.length?0:Math.max.apply(Math,e)},exports.MAXA=function(){var e=utils.arrayValuesToNumbers(utils.flatten(arguments));return 0===e.length?0:Math.max.apply(Math,e)},exports.MEDIAN=function(){var e=utils.arrayValuesToNumbers(utils.flatten(arguments)),t=jStat.median(e);return isNaN(t)&&(t=error.num),t},exports.MIN=function(){var e=utils.numbers(utils.flatten(arguments));return 0===e.length?0:Math.min.apply(Math,e)},exports.MINA=function(){var e=utils.arrayValuesToNumbers(utils.flatten(arguments));return 0===e.length?0:Math.min.apply(Math,e)},exports.MODE={},exports.MODE.MULT=function(){var e=utils.parseNumberArray(utils.flatten(arguments));if(e instanceof Error)return e;for(var t,n=e.length,r={},o=[],i=0,a=0;a<n;a++)r[t=e[a]]=r[t]?r[t]+1:1,r[t]>i&&(i=r[t],o=[]),r[t]===i&&(o[o.length]=t);return o},exports.MODE.SNGL=function(){var e=utils.parseNumberArray(utils.flatten(arguments));return e instanceof Error?e:exports.MODE.MULT(e).sort(function(e,t){return e-t})[0]},exports.NEGBINOM={},exports.NEGBINOM.DIST=function(e,t,n,r){return e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),utils.anyIsError(e,t,n)?error.value:r?jStat.negbin.cdf(e,t,n):jStat.negbin.pdf(e,t,n)},exports.NORM={},exports.NORM.DIST=function(e,t,n,r){return e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),utils.anyIsError(e,t,n)?error.value:n<=0?error.num:r?jStat.normal.cdf(e,t,n):jStat.normal.pdf(e,t,n)},exports.NORM.INV=function(e,t,n){return e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),utils.anyIsError(e,t,n)?error.value:jStat.normal.inv(e,t,n)},exports.NORM.S={},exports.NORM.S.DIST=function(e,t){return(e=utils.parseNumber(e))instanceof Error?error.value:t?jStat.normal.cdf(e,0,1):jStat.normal.pdf(e,0,1)},exports.NORM.S.INV=function(e){return(e=utils.parseNumber(e))instanceof Error?error.value:jStat.normal.inv(e,0,1)},exports.PEARSON=function(e,t){if(t=utils.parseNumberArray(utils.flatten(t)),e=utils.parseNumberArray(utils.flatten(e)),utils.anyIsError(t,e))return error.value;for(var n=jStat.mean(e),r=jStat.mean(t),o=e.length,i=0,a=0,s=0,l=0;l<o;l++)i+=(e[l]-n)*(t[l]-r),a+=Math.pow(e[l]-n,2),s+=Math.pow(t[l]-r,2);return i/Math.sqrt(a*s)},exports.PERCENTILE={},exports.PERCENTILE.EXC=function(e,t){if(e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumber(t),utils.anyIsError(e,t))return error.value;var n=(e=e.sort(function(e,t){return e-t})).length;if(t<1/(n+1)||1-1/(n+1)<t)return error.num;var r=t*(n+1)-1,o=Math.floor(r);return utils.cleanFloat(r===o?e[r]:e[o]+(r-o)*(e[o+1]-e[o]))},exports.PERCENTILE.INC=function(e,t){if(e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumber(t),utils.anyIsError(e,t))return error.value;var n=t*((e=e.sort(function(e,t){return e-t})).length-1),r=Math.floor(n);return utils.cleanFloat(n===r?e[n]:e[r]+(n-r)*(e[r+1]-e[r]))},exports.PERCENTRANK={},exports.PERCENTRANK.EXC=function(e,t,n){if(n=void 0===n?3:n,e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumber(t),n=utils.parseNumber(n),utils.anyIsError(e,t,n))return error.value;e=e.sort(function(e,t){return e-t});for(var r=misc.UNIQUE.apply(null,e),o=e.length,i=r.length,a=Math.pow(10,n),s=0,l=!1,u=0;!l&&u<i;)t===r[u]?(s=(e.indexOf(r[u])+1)/(o+1),l=!0):t>=r[u]&&(t<r[u+1]||u===i-1)&&(s=(e.indexOf(r[u])+1+(t-r[u])/(r[u+1]-r[u]))/(o+1),l=!0),u++;return Math.floor(s*a)/a},exports.PERCENTRANK.INC=function(e,t,n){if(n=void 0===n?3:n,e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumber(t),n=utils.parseNumber(n),utils.anyIsError(e,t,n))return error.value;e=e.sort(function(e,t){return e-t});for(var r=misc.UNIQUE.apply(null,e),o=e.length,i=r.length,a=Math.pow(10,n),s=0,l=!1,u=0;!l&&u<i;)t===r[u]?(s=e.indexOf(r[u])/(o-1),l=!0):t>=r[u]&&(t<r[u+1]||u===i-1)&&(s=(e.indexOf(r[u])+(t-r[u])/(r[u+1]-r[u]))/(o-1),l=!0),u++;return Math.floor(s*a)/a},exports.PERMUT=function(e,t){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:mathTrig.FACT(e)/mathTrig.FACT(e-t)},exports.PERMUTATIONA=function(e,t){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:Math.pow(e,t)},exports.PHI=function(e){return(e=utils.parseNumber(e))instanceof Error?error.value:Math.exp(-.5*e*e)/SQRT2PI},exports.POISSON={},exports.POISSON.DIST=function(e,t,n){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:n?jStat.poisson.cdf(e,t):jStat.poisson.pdf(e,t)},exports.PROB=function(e,t,n,r){if(void 0===n)return 0;if(r=void 0===r?n:r,e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumberArray(utils.flatten(t)),n=utils.parseNumber(n),r=utils.parseNumber(r),utils.anyIsError(e,t,n,r))return error.value;if(n===r)return 0<=e.indexOf(n)?t[e.indexOf(n)]:0;for(var o=e.sort(function(e,t){return e-t}),i=o.length,a=0,s=0;s<i;s++)o[s]>=n&&o[s]<=r&&(a+=t[e.indexOf(o[s])]);return a},exports.QUARTILE={},exports.QUARTILE.EXC=function(e,t){if(e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumber(t),utils.anyIsError(e,t))return error.value;switch(t){case 1:return exports.PERCENTILE.EXC(e,.25);case 2:return exports.PERCENTILE.EXC(e,.5);case 3:return exports.PERCENTILE.EXC(e,.75);default:return error.num}},exports.QUARTILE.INC=function(e,t){if(e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumber(t),utils.anyIsError(e,t))return error.value;switch(t){case 1:return exports.PERCENTILE.INC(e,.25);case 2:return exports.PERCENTILE.INC(e,.5);case 3:return exports.PERCENTILE.INC(e,.75);default:return error.num}},exports.RANK={},exports.RANK.AVG=function(e,t,n){if(e=utils.parseNumber(e),t=utils.parseNumberArray(utils.flatten(t)),utils.anyIsError(e,t))return error.value;for(var r=(n=n||!1)?function(e,t){return e-t}:function(e,t){return t-e},o=(t=(t=utils.flatten(t)).sort(r)).length,i=0,a=0;a<o;a++)t[a]===e&&i++;return 1<i?(2*t.indexOf(e)+i+1)/2:t.indexOf(e)+1},exports.RANK.EQ=function(e,t,n){if(e=utils.parseNumber(e),t=utils.parseNumberArray(utils.flatten(t)),utils.anyIsError(e,t))return error.value;var r=(n=n||!1)?function(e,t){return e-t}:function(e,t){return t-e};return(t=t.sort(r)).indexOf(e)+1},exports.ROW=function(e,t){return 2!==arguments.length?error.na:t<0?error.num:e instanceof Array&&"number"==typeof t?0!==e.length?jStat.row(e,t):void 0:error.value},exports.ROWS=function(e){return 1!==arguments.length?error.na:e instanceof Array?0===e.length?0:jStat.rows(e):error.value},exports.RSQ=function(e,t){return e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumberArray(utils.flatten(t)),utils.anyIsError(e,t)?error.value:Math.pow(exports.PEARSON(e,t),2)},exports.SKEW=function(){var e=utils.parseNumberArray(utils.flatten(arguments));if(e instanceof Error)return e;for(var t=jStat.mean(e),n=e.length,r=0,o=0;o<n;o++)r+=Math.pow(e[o]-t,3);return n*r/((n-1)*(n-2)*Math.pow(jStat.stdev(e,!0),3))},exports.SKEW.P=function(){var e=utils.parseNumberArray(utils.flatten(arguments));if(e instanceof Error)return e;for(var t=jStat.mean(e),n=e.length,r=0,o=0,i=0;i<n;i++)o+=Math.pow(e[i]-t,3),r+=Math.pow(e[i]-t,2);return r/=n,(o/=n)/Math.pow(r,1.5)},exports.SLOPE=function(e,t){if(e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumberArray(utils.flatten(t)),utils.anyIsError(e,t))return error.value;for(var n=jStat.mean(t),r=jStat.mean(e),o=t.length,i=0,a=0,s=0;s<o;s++)i+=(t[s]-n)*(e[s]-r),a+=Math.pow(t[s]-n,2);return i/a},exports.SMALL=function(e,t){return e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumber(t),utils.anyIsError(e,t)?e:e.sort(function(e,t){return e-t})[t-1]},exports.STANDARDIZE=function(e,t,n){return e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),utils.anyIsError(e,t,n)?error.value:(e-t)/n},exports.STDEV={},exports.STDEV.P=function(){var e=exports.VAR.P.apply(this,arguments),t=Math.sqrt(e);return isNaN(t)&&(t=error.num),t},exports.STDEV.S=function(){var e=exports.VAR.S.apply(this,arguments);return Math.sqrt(e)},exports.STDEVA=function(){var e=exports.VARA.apply(this,arguments);return Math.sqrt(e)},exports.STDEVPA=function(){var e=exports.VARPA.apply(this,arguments),t=Math.sqrt(e);return isNaN(t)&&(t=error.num),t},exports.STEYX=function(e,t){if(e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumberArray(utils.flatten(t)),utils.anyIsError(e,t))return error.value;for(var n=jStat.mean(t),r=jStat.mean(e),o=t.length,i=0,a=0,s=0,l=0;l<o;l++)i+=Math.pow(e[l]-r,2),a+=(t[l]-n)*(e[l]-r),s+=Math.pow(t[l]-n,2);return Math.sqrt((i-a*a/s)/(o-2))},exports.TRANSPOSE=function(e){return e?jStat.transpose(e):error.na},exports.T=text.T,exports.T.DIST=function(e,t,n){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:n?jStat.studentt.cdf(e,t):jStat.studentt.pdf(e,t)},exports.T.DIST["2T"]=function(e,t){return 2!==arguments.length?error.na:e<0||t<1?error.num:"number"!=typeof e||"number"!=typeof t?error.value:2*(1-jStat.studentt.cdf(e,t))},exports.T.DIST.RT=function(e,t){return 2!==arguments.length?error.na:e<0||t<1?error.num:"number"!=typeof e||"number"!=typeof t?error.value:1-jStat.studentt.cdf(e,t)},exports.T.INV=function(e,t){return e=utils.parseNumber(e),t=utils.parseNumber(t),utils.anyIsError(e,t)?error.value:jStat.studentt.inv(e,t)},exports.T.INV["2T"]=function(e,t){return e=utils.parseNumber(e),t=utils.parseNumber(t),e<=0||1<e||t<1?error.num:utils.anyIsError(e,t)?error.value:Math.abs(jStat.studentt.inv(e/2,t))},exports.T.TEST=function(e,t){if(e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumberArray(utils.flatten(t)),utils.anyIsError(e,t))return error.value;var n,r=jStat.mean(e),o=jStat.mean(t),i=0,a=0;for(n=0;n<e.length;n++)i+=Math.pow(e[n]-r,2);for(n=0;n<t.length;n++)a+=Math.pow(t[n]-o,2);i/=e.length-1,a/=t.length-1;var s=Math.abs(r-o)/Math.sqrt(i/e.length+a/t.length);return exports.T.DIST["2T"](s,e.length+t.length-2)},exports.TREND=function(e,t,n){if(e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumberArray(utils.flatten(t)),n=utils.parseNumberArray(utils.flatten(n)),utils.anyIsError(e,t,n))return error.value;var r=exports.LINEST(e,t),o=r[0],i=r[1],a=[];return n.forEach(function(e){a.push(o*e+i)}),a},exports.TRIMMEAN=function(e,t){if(e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumber(t),utils.anyIsError(e,t))return error.value;var n=mathTrig.FLOOR(e.length*t,2)/2;return jStat.mean(utils.initial(utils.rest(e.sort(function(e,t){return e-t}),n),n))},exports.VAR={},exports.VAR.P=function(){for(var e,t=utils.numbers(utils.flatten(arguments)),n=t.length,r=0,o=exports.AVERAGE(t),i=0;i<n;i++)r+=Math.pow(t[i]-o,2);return e=r/n,isNaN(e)&&(e=error.num),e},exports.VAR.S=function(){for(var e=utils.numbers(utils.flatten(arguments)),t=e.length,n=0,r=exports.AVERAGE(e),o=0;o<t;o++)n+=Math.pow(e[o]-r,2);return n/(t-1)},exports.VARA=function(){for(var e=utils.flatten(arguments),t=e.length,n=0,r=0,o=exports.AVERAGEA(e),i=0;i<t;i++){var a=e[i];n+="number"==typeof a?Math.pow(a-o,2):!0===a?Math.pow(1-o,2):Math.pow(0-o,2),null!==a&&r++}return n/(r-1)},exports.VARPA=function(){for(var e,t=utils.flatten(arguments),n=t.length,r=0,o=0,i=exports.AVERAGEA(t),a=0;a<n;a++){var s=t[a];r+="number"==typeof s?Math.pow(s-i,2):!0===s?Math.pow(1-i,2):Math.pow(0-i,2),null!==s&&o++}return e=r/o,isNaN(e)&&(e=error.num),e},exports.WEIBULL={},exports.WEIBULL.DIST=function(e,t,n,r){return e=utils.parseNumber(e),t=utils.parseNumber(t),n=utils.parseNumber(n),utils.anyIsError(e,t,n)?error.value:r?1-Math.exp(-Math.pow(e/n,t)):Math.pow(e,t-1)*Math.exp(-Math.pow(e/n,t))*t/Math.pow(n,t)},exports.Z={},exports.Z.TEST=function(e,t,n){if(e=utils.parseNumberArray(utils.flatten(e)),t=utils.parseNumber(t),utils.anyIsError(e,t))return error.value;n=n||exports.STDEV.S(e);var r=e.length;return 1-exports.NORM.S.DIST((exports.AVERAGE(e)-t)/(n/Math.sqrt(r)),!0)}},function(e,t,n){var i=n(1),a=n(0);t.ASC=function(){throw new Error("ASC is not implemented")},t.BAHTTEXT=function(){throw new Error("BAHTTEXT is not implemented")},t.CHAR=function(e){return(e=i.parseNumber(e))instanceof Error?e:String.fromCharCode(e)},t.CLEAN=function(e){return(e=e||"").replace(/[\0-\x1F]/g,"")},t.CODE=function(e){var t=(e=e||"").charCodeAt(0);return isNaN(t)&&(t=a.na),t},t.CONCATENATE=function(){for(var e=i.flatten(arguments),t=0;-1<(t=e.indexOf(!0));)e[t]="TRUE";for(var n=0;-1<(n=e.indexOf(!1));)e[n]="FALSE";return e.join("")},t.DBCS=function(){throw new Error("DBCS is not implemented")},t.DOLLAR=function(){throw new Error("DOLLAR is not implemented")},t.EXACT=function(e,t){return 2!==arguments.length?a.na:e===t},t.FIND=function(e,t,n){return arguments.length<2?a.na:(n=void 0===n?0:n,t?t.indexOf(e,n-1)+1:null)},t.FIXED=function(){throw new Error("FIXED is not implemented")},t.HTML2TEXT=function(e){var t="";return e&&(e instanceof Array?e.forEach(function(e){""!==t&&(t+="\n"),t+=e.replace(/<(?:.|\n)*?>/gm,"")}):t=e.replace(/<(?:.|\n)*?>/gm,"")),t},t.LEFT=function(e,t){return t=void 0===t?1:t,(t=i.parseNumber(t))instanceof Error||"string"!=typeof e?a.value:e?e.substring(0,t):null},t.LEN=function(e){return 0===arguments.length?a.error:"string"==typeof e?e?e.length:0:e.length?e.length:a.value},t.LOWER=function(e){return"string"!=typeof e?a.value:e?e.toLowerCase():e},t.MID=function(e,t,n){if(t=i.parseNumber(t),n=i.parseNumber(n),i.anyIsError(t,n)||"string"!=typeof e)return n;var r=t-1,o=r+n;return e.substring(r,o)},t.NUMBERVALUE=function(e,t,n){return t=void 0===t?".":t,n=void 0===n?",":n,Number(e.replace(t,".").replace(n,""))},t.PRONETIC=function(){throw new Error("PRONETIC is not implemented")},t.PROPER=function(e){return void 0===e||0===e.length?a.value:(!0===e&&(e="TRUE"),!1===e&&(e="FALSE"),isNaN(e)&&"number"==typeof e?a.value:("number"==typeof e&&(e=""+e),e.replace(/\w\S*/g,function(e){return e.charAt(0).toUpperCase()+e.substr(1).toLowerCase()})))},t.REGEXEXTRACT=function(e,t){if(arguments.length<2)return a.na;var n=e.match(new RegExp(t));return n?n[1<n.length?n.length-1:0]:null},t.REGEXMATCH=function(e,t,n){if(arguments.length<2)return a.na;var r=e.match(new RegExp(t));return n?r:!!r},t.REGEXREPLACE=function(e,t,n){return arguments.length<3?a.na:e.replace(new RegExp(t),n)},t.REPLACE=function(e,t,n,r){return t=i.parseNumber(t),n=i.parseNumber(n),i.anyIsError(t,n)||"string"!=typeof e||"string"!=typeof r?a.value:e.substr(0,t-1)+r+e.substr(t-1+n)},t.REPT=function(e,t){return(t=i.parseNumber(t))instanceof Error?t:new Array(t+1).join(e)},t.RIGHT=function(e,t){return t=void 0===t?1:t,(t=i.parseNumber(t))instanceof Error?t:e?e.substring(e.length-t):a.na},t.SEARCH=function(e,t,n){var r;return"string"!=typeof e||"string"!=typeof t?a.value:(n=void 0===n?0:n,0===(r=t.toLowerCase().indexOf(e.toLowerCase(),n-1)+1)?a.value:r)},t.SPLIT=function(e,t){return e.split(t)},t.SUBSTITUTE=function(e,t,n,r){if(arguments.length<2)return a.na;if(!(e&&t&&n))return e;if(void 0===r)return e.replace(new RegExp(t,"g"),n);for(var o=0,i=0;0<e.indexOf(t,o);)if(o=e.indexOf(t,o+1),++i===r)return e.substring(0,o)+n+e.substring(o+t.length)},t.T=function(e){return"string"==typeof e?e:""},t.TEXT=function(){throw new Error("TEXT is not implemented")},t.TRIM=function(e){return"string"!=typeof e?a.value:e.replace(/ +/g," ").trim()},t.UNICHAR=t.CHAR,t.UNICODE=t.CODE,t.UPPER=function(e){return"string"!=typeof e?a.value:e.toUpperCase()},t.VALUE=function(){throw new Error("VALUE is not implemented")}},function(e,t,n){var r=n(0);t.CELL=function(){throw new Error("CELL is not implemented")},t.ERROR={},t.ERROR.TYPE=function(e){switch(e){case r.nil:return 1;case r.div0:return 2;case r.value:return 3;case r.ref:return 4;case r.name:return 5;case r.num:return 6;case r.na:return 7;case r.data:return 8}return r.na},t.INFO=function(){throw new Error("INFO is not implemented")},t.ISBLANK=function(e){return null===e},t.ISBINARY=function(e){return/^[01]{1,10}$/.test(e)},t.ISERR=function(e){return 0<=[r.value,r.ref,r.div0,r.num,r.name,r.nil].indexOf(e)||"number"==typeof e&&(isNaN(e)||!isFinite(e))},t.ISERROR=function(e){return t.ISERR(e)||e===r.na},t.ISEVEN=function(e){return!(1&Math.floor(Math.abs(e)))},t.ISFORMULA=function(){throw new Error("ISFORMULA is not implemented")},t.ISLOGICAL=function(e){return!0===e||!1===e},t.ISNA=function(e){return e===r.na},t.ISNONTEXT=function(e){return"string"!=typeof e},t.ISNUMBER=function(e){return"number"==typeof e&&!isNaN(e)&&isFinite(e)},t.ISODD=function(e){return!!(1&Math.floor(Math.abs(e)))},t.ISREF=function(){throw new Error("ISREF is not implemented")},t.ISTEXT=function(e){return"string"==typeof e},t.N=function(e){return this.ISNUMBER(e)?e:e instanceof Date?e.getTime():!0===e?1:!1===e?0:this.ISERROR(e)?e:0},t.NA=function(){return r.na},t.SHEET=function(){throw new Error("SHEET is not implemented")},t.SHEETS=function(){throw new Error("SHEETS is not implemented")},t.TYPE=function(e){return this.ISNUMBER(e)?1:this.ISTEXT(e)?2:this.ISLOGICAL(e)?4:this.ISERROR(e)?16:Array.isArray(e)?64:void 0}},function(e,t,n){var f=n(0),g=n(1),r=new Date(Date.UTC(1900,0,1)),i=[void 0,0,1,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,void 0,1,2,3,4,5,6,0],o=[[],[1,2,3,4,5,6,7],[7,1,2,3,4,5,6],[6,0,1,2,3,4,5],[],[],[],[],[],[],[],[7,1,2,3,4,5,6],[6,7,1,2,3,4,5],[5,6,7,1,2,3,4],[4,5,6,7,1,2,3],[3,4,5,6,7,1,2],[2,3,4,5,6,7,1],[1,2,3,4,5,6,7]],v=[[],[6,0],[0,1],[1,2],[2,3],[3,4],[4,5],[5,6],void 0,void 0,void 0,[0,0],[1,1],[2,2],[3,3],[4,4],[5,5],[6,6]];function d(e){return 1===new Date(e,1,29).getMonth()}function p(e,t){return Math.ceil((t-e)/1e3/60/60/24)}function a(e){var t=-22038912e5<e?2:1;return Math.ceil((e-r)/864e5)+t}t.DATE=function(e,t,n){return e=g.parseNumber(e),t=g.parseNumber(t),n=g.parseNumber(n),g.anyIsError(e,t,n)?f.value:e<0||t<0||n<0?f.num:new Date(e,t-1,n)},t.DATEVALUE=function(e){var t,n=2;return"string"!=typeof e?f.value:(t=Date.parse(e),isNaN(t)?f.value:(t<=-22038912e5&&(n=1),Math.ceil((t-r)/864e5)+n))},t.DAY=function(e){var t=g.parseDate(e);return t instanceof Error?t:t.getDate()},t.DAYS=function(e,t){return e=g.parseDate(e),t=g.parseDate(t),e instanceof Error?e:t instanceof Error?t:a(e)-a(t)},t.DAYS360=function(e,t,n){if(n=g.parseBool(n),e=g.parseDate(e),t=g.parseDate(t),e instanceof Error)return e;if(t instanceof Error)return t;if(n instanceof Error)return n;var r,o,i=e.getMonth(),a=t.getMonth();if(n)r=31===e.getDate()?30:e.getDate(),o=31===t.getDate()?30:t.getDate();else{var s=new Date(e.getFullYear(),i+1,0).getDate(),l=new Date(t.getFullYear(),a+1,0).getDate();r=e.getDate()===s?30:e.getDate(),o=t.getDate()===l?r<30?(a++,1):30:t.getDate()}return 360*(t.getFullYear()-e.getFullYear())+30*(a-i)+(o-r)},t.EDATE=function(e,t){return(e=g.parseDate(e))instanceof Error?e:isNaN(t)?f.value:(t=parseInt(t,10),e.setMonth(e.getMonth()+t),a(e))},t.EOMONTH=function(e,t){return(e=g.parseDate(e))instanceof Error?e:isNaN(t)?f.value:(t=parseInt(t,10),a(new Date(e.getFullYear(),e.getMonth()+t+1,0)))},t.HOUR=function(e){return(e=g.parseDate(e))instanceof Error?e:e.getHours()},t.INTERVAL=function(e){if("number"!=typeof e&&"string"!=typeof e)return f.value;e=parseInt(e,10);var t=Math.floor(e/94608e4);e%=94608e4;var n=Math.floor(e/2592e3);e%=2592e3;var r=Math.floor(e/86400);e%=86400;var o=Math.floor(e/3600);e%=3600;var i=Math.floor(e/60),a=e%=60;return"P"+(t=0<t?t+"Y":"")+(n=0<n?n+"M":"")+(r=0<r?r+"D":"")+"T"+(o=0<o?o+"H":"")+(i=0<i?i+"M":"")+(a=0<a?a+"S":"")},t.ISOWEEKNUM=function(e){if((e=g.parseDate(e))instanceof Error)return e;e.setHours(0,0,0),e.setDate(e.getDate()+4-(e.getDay()||7));var t=new Date(e.getFullYear(),0,1);return Math.ceil(((e-t)/864e5+1)/7)},t.MINUTE=function(e){return(e=g.parseDate(e))instanceof Error?e:e.getMinutes()},t.MONTH=function(e){return(e=g.parseDate(e))instanceof Error?e:e.getMonth()+1},t.NETWORKDAYS=function(e,t,n){return this.NETWORKDAYS.INTL(e,t,1,n)},t.NETWORKDAYS.INTL=function(e,t,n,r){if((e=g.parseDate(e))instanceof Error)return e;if((t=g.parseDate(t))instanceof Error)return t;if(!((n=void 0===n?v[1]:v[n])instanceof Array))return f.value;void 0===r?r=[]:r instanceof Array||(r=[r]);for(var o=0;o<r.length;o++){var i=g.parseDate(r[o]);if(i instanceof Error)return i;r[o]=i}var a=(t-e)/864e5+1,s=a,l=e;for(o=0;o<a;o++){var u=0<(new Date).getTimezoneOffset()?l.getUTCDay():l.getDay(),c=!1;u!==n[0]&&u!==n[1]||(c=!0);for(var h=0;h<r.length;h++){var d=r[h];if(d.getDate()===l.getDate()&&d.getMonth()===l.getMonth()&&d.getFullYear()===l.getFullYear()){c=!0;break}}c&&s--,l.setDate(l.getDate()+1)}return s},t.NOW=function(){return new Date},t.SECOND=function(e){return(e=g.parseDate(e))instanceof Error?e:e.getSeconds()},t.TIME=function(e,t,n){return e=g.parseNumber(e),t=g.parseNumber(t),n=g.parseNumber(n),g.anyIsError(e,t,n)?f.value:e<0||t<0||n<0?f.num:(3600*e+60*t+n)/86400},t.TIMEVALUE=function(e){return(e=g.parseDate(e))instanceof Error?e:(3600*e.getHours()+60*e.getMinutes()+e.getSeconds())/86400},t.TODAY=function(){return new Date},t.WEEKDAY=function(e,t){if((e=g.parseDate(e))instanceof Error)return e;void 0===t&&(t=1);var n=e.getDay();return o[t][n]},t.WEEKNUM=function(e,t){if((e=g.parseDate(e))instanceof Error)return e;if(void 0===t&&(t=1),21===t)return this.ISOWEEKNUM(e);var n=i[t],r=new Date(e.getFullYear(),0,1),o=r.getDay()<n?1:0;return r-=24*Math.abs(r.getDay()-n)*60*60*1e3,Math.floor((e-r)/864e5/7+1)+o},t.WORKDAY=function(e,t,n){return this.WORKDAY.INTL(e,t,1,n)},t.WORKDAY.INTL=function(e,t,n,r){if((e=g.parseDate(e))instanceof Error)return e;if((t=g.parseNumber(t))instanceof Error)return t;if(t<0)return f.num;if(!((n=void 0===n?v[1]:v[n])instanceof Array))return f.value;void 0===r?r=[]:r instanceof Array||(r=[r]);for(var o=0;o<r.length;o++){var i=g.parseDate(r[o]);if(i instanceof Error)return i;r[o]=i}for(var a=0;a<t;){e.setDate(e.getDate()+1);var s=e.getDay();if(s!==n[0]&&s!==n[1]){for(var l=0;l<r.length;l++){var u=r[l];if(u.getDate()===e.getDate()&&u.getMonth()===e.getMonth()&&u.getFullYear()===e.getFullYear()){a--;break}}a++}}return e},t.YEAR=function(e){return(e=g.parseDate(e))instanceof Error?e:e.getFullYear()},t.YEARFRAC=function(e,t,n){if((e=g.parseDate(e))instanceof Error)return e;if((t=g.parseDate(t))instanceof Error)return t;n=n||0;var r=e.getDate(),o=e.getMonth()+1,i=e.getFullYear(),a=t.getDate(),s=t.getMonth()+1,l=t.getFullYear();switch(n){case 0:return 31===r&&31===a?a=r=30:31===r?r=30:30===r&&31===a&&(a=30),(a+30*s+360*l-(r+30*o+360*i))/360;case 1:var u=365;if(i===l||i+1===l&&(s<o||o===s&&a<=r))return(i===l&&d(i)||function(e,t){var n=e.getFullYear(),r=new Date(n,2,1);if(d(n)&&e<r&&r<=t)return!0;var o=t.getFullYear(),i=new Date(o,2,1);return d(o)&&i<=t&&e<i}(e,t)||1===s&&29===a)&&(u=366),p(e,t)/u;var c=l-i+1,h=(new Date(l+1,0,1)-new Date(i,0,1))/1e3/60/60/24/c;return p(e,t)/h;case 2:return p(e,t)/360;case 3:return p(e,t)/365;case 4:return(a+30*s+360*l-(r+30*o+360*i))/360}}},function(e,t,n){var d;e.exports=(function(l,d){var u=l.utils.isFunction;function f(e,t){return e-t}function g(e,t,n){return d.max(t,d.min(e,n))}l.sum=function(e){for(var t=0,n=e.length;0<=--n;)t+=e[n];return t},l.sumsqrd=function(e){for(var t=0,n=e.length;0<=--n;)t+=e[n]*e[n];return t},l.sumsqerr=function(e){for(var t,n=l.mean(e),r=0,o=e.length;0<=--o;)r+=(t=e[o]-n)*t;return r},l.sumrow=function(e){for(var t=0,n=e.length;0<=--n;)t+=e[n];return t},l.product=function(e){for(var t=1,n=e.length;0<=--n;)t*=e[n];return t},l.min=function(e){for(var t=e[0],n=0;++n<e.length;)e[n]<t&&(t=e[n]);return t},l.max=function(e){for(var t=e[0],n=0;++n<e.length;)e[n]>t&&(t=e[n]);return t},l.unique=function(e){for(var t={},n=[],r=0;r<e.length;r++)t[e[r]]||(t[e[r]]=!0,n.push(e[r]));return n},l.mean=function(e){return l.sum(e)/e.length},l.meansqerr=function(e){return l.sumsqerr(e)/e.length},l.geomean=function(e){return d.pow(l.product(e),1/e.length)},l.median=function(e){var t=e.length,n=e.slice().sort(f);return 1&t?n[t/2|0]:(n[t/2-1]+n[t/2])/2},l.cumsum=function(e){return l.cumreduce(e,function(e,t){return e+t})},l.cumprod=function(e){return l.cumreduce(e,function(e,t){return e*t})},l.diff=function(e){for(var t=[],n=e.length,r=1;r<n;r++)t.push(e[r]-e[r-1]);return t},l.rank=function(e){for(var t=e.length,n=e.slice().sort(f),r=new Array(t),o=0;o<t;o++){var i=n.indexOf(e[o]),a=n.lastIndexOf(e[o]);if(i===a)var s=i;else s=(i+a)/2;r[o]=s+1}return r},l.mode=function(e){for(var t=e.length,n=e.slice().sort(f),r=1,o=0,i=0,a=[],s=0;s<t;s++)n[s]===n[s+1]?r++:(o<r?(a=[n[s]],o=r,i=0):r===o&&(a.push(n[s]),i++),r=1);return 0===i?a[0]:a},l.range=function(e){return l.max(e)-l.min(e)},l.variance=function(e,t){return l.sumsqerr(e)/(e.length-(t?1:0))},l.pooledvariance=function(e){return e.reduce(function(e,t){return e+l.sumsqerr(t)},0)/(e.reduce(function(e,t){return e+t.length},0)-e.length)},l.deviation=function(e){for(var t=l.mean(e),n=e.length,r=new Array(n),o=0;o<n;o++)r[o]=e[o]-t;return r},l.stdev=function(e,t){return d.sqrt(l.variance(e,t))},l.pooledstdev=function(e){return d.sqrt(l.pooledvariance(e))},l.meandev=function(e){for(var t=l.mean(e),n=[],r=e.length-1;0<=r;r--)n.push(d.abs(e[r]-t));return l.mean(n)},l.meddev=function(e){for(var t=l.median(e),n=[],r=e.length-1;0<=r;r--)n.push(d.abs(e[r]-t));return l.median(n)},l.coeffvar=function(e){return l.stdev(e)/l.mean(e)},l.quartiles=function(e){var t=e.length,n=e.slice().sort(f);return[n[d.round(t/4)-1],n[d.round(t/2)-1],n[d.round(3*t/4)-1]]},l.quantiles=function(e,t,n,r){var o,i,a,s,l=e.slice().sort(f),u=[t.length],c=e.length;void 0===n&&(n=3/8),void 0===r&&(r=3/8);for(var h=0;h<t.length;h++)s=g((i=c*(o=t[h])+(n+o*(1-n-r)))-(a=d.floor(g(i,1,c-1))),0,1),u[h]=(1-s)*l[a-1]+s*l[a];return u},l.percentile=function(e,t){var n=e.slice().sort(f),r=t*(n.length-1),o=parseInt(r),i=r-o;return o+1<n.length?n[o]*(1-i)+n[o+1]*i:n[o]},l.percentileOfScore=function(e,t,n){var r,o=0,i=e.length,a=!1;"strict"===n&&(a=!0);for(var s=0;s<i;s++)r=e[s],(a&&r<t||!a&&r<=t)&&o++;return o/i},l.histogram=function(e,t){for(var n=l.min(e),r=t||4,o=(l.max(e)-n)/r,i=e.length,a=(t=[],0);a<r;a++)t[a]=0;for(a=0;a<i;a++)t[d.min(d.floor((e[a]-n)/o),r-1)]+=1;return t},l.covariance=function(e,t){for(var n=l.mean(e),r=l.mean(t),o=e.length,i=new Array(o),a=0;a<o;a++)i[a]=(e[a]-n)*(t[a]-r);return l.sum(i)/(o-1)},l.corrcoeff=function(e,t){return l.covariance(e,t)/l.stdev(e,1)/l.stdev(t,1)},l.spearmancoeff=function(e,t){return e=l.rank(e),t=l.rank(t),l.corrcoeff(e,t)},l.stanMoment=function(e,t){for(var n=l.mean(e),r=l.stdev(e),o=e.length,i=0,a=0;a<o;a++)i+=d.pow((e[a]-n)/r,t);return i/e.length},l.skewness=function(e){return l.stanMoment(e,3)},l.kurtosis=function(e){return l.stanMoment(e,4)-3};var c=l.prototype;!function(e){for(var t=0;t<e.length;t++)!function(i){c[i]=function(e,t){var n=[],r=0,o=this;if(u(e)&&(t=e,e=!1),t)return setTimeout(function(){t.call(o,c[i].call(o,e))}),this;if(1<this.length){for(o=!0===e?this:this.transpose();r<o.length;r++)n[r]=l[i](o[r]);return n}return l[i](this[0],e)}}(e[t])}("cumsum cumprod".split(" ")),function(e){for(var t=0;t<e.length;t++)!function(i){c[i]=function(e,t){var n=[],r=0,o=this;if(u(e)&&(t=e,e=!1),t)return setTimeout(function(){t.call(o,c[i].call(o,e))}),this;if(1<this.length){for("sumrow"!==i&&(o=!0===e?this:this.transpose());r<o.length;r++)n[r]=l[i](o[r]);return!0===e?l[i](l.utils.toVector(n)):n}return l[i](this[0],e)}}(e[t])}("sum sumsqrd sumsqerr sumrow product min max unique mean meansqerr geomean median diff rank mode range variance deviation stdev meandev meddev coeffvar quartiles histogram skewness kurtosis".split(" ")),function(e){for(var t=0;t<e.length;t++)!function(s){c[s]=function(){var e=[],t=0,n=this,r=Array.prototype.slice.call(arguments);if(u(r[r.length-1])){var o=r[r.length-1],i=r.slice(0,r.length-1);return setTimeout(function(){o.call(n,c[s].apply(n,i))}),this}o=void 0;var a=function(e){return l[s].apply(n,[e].concat(r))};if(1<this.length){for(n=n.transpose();t<n.length;t++)e[t]=a(n[t]);return e}return a(this[0])}}(e[t])}("quantiles percentileOfScore".split(" "))}(d=function(s,l){var t=Array.prototype.concat,e=Array.prototype.slice,n=Object.prototype.toString;function u(e,t){var n=t<e?e:t;return s.pow(10,17-~~(s.log(0<n?n:-n)*s.LOG10E))}var c=Array.isArray||function(e){return"[object Array]"===n.call(e)};function h(e){return"[object Function]"===n.call(e)}function d(e){return"number"==typeof e&&e==e}function f(){return new f._init(arguments)}function r(){return 0}function o(){return 1}function a(e,t){return e===t?1:0}f.fn=f.prototype,(f._init=function(e){if(c(e[0]))if(c(e[0][0])){h(e[1])&&(e[0]=f.map(e[0],e[1]));for(var t=0;t<e[0].length;t++)this[t]=e[0][t];this.length=e[0].length}else this[0]=h(e[1])?f.map(e[0],e[1]):e[0],this.length=1;else if(d(e[0]))this[0]=f.seq.apply(null,e),this.length=1;else{if(e[0]instanceof f)return f(e[0].toArray());this[0]=[],this.length=1}return this}).prototype=f.prototype,(f._init.constructor=f).utils={calcRdx:u,isArray:c,isFunction:h,isNumber:d,toVector:function(e){return t.apply([],e)}},f.extend=function(e){var t;if(1===arguments.length){for(t in e)f[t]=e[t];return this}for(var n=1;n<arguments.length;n++)for(t in arguments[n])e[t]=arguments[n][t];return e},f.rows=function(e){return e.length||1},f.cols=function(e){return e[0].length||1},f.dimensions=function(e){return{rows:f.rows(e),cols:f.cols(e)}},f.row=function(t,e){return c(e)?e.map(function(e){return f.row(t,e)}):t[e]},f.rowa=function(e,t){return f.row(e,t)},f.col=function(r,t){if(c(t)){var o=f.arange(r.length).map(function(e){return new Array(t.length)});return t.forEach(function(t,n){f.arange(r.length).forEach(function(e){o[e][n]=r[e][t]})}),o}for(var e=new Array(r.length),n=0;n<r.length;n++)e[n]=[r[n][t]];return e},f.cola=function(e,t){return f.col(e,t).map(function(e){return e[0]})},f.diag=function(e){for(var t=f.rows(e),n=new Array(t),r=0;r<t;r++)n[r]=[e[r][r]];return n},f.antidiag=function(e){for(var t=f.rows(e)-1,n=new Array(t),r=0;0<=t;t--,r++)n[r]=[e[r][t]];return n},f.transpose=function(e){var t,n,r,o,i=[];c(e[0])||(e=[e]),n=e.length,r=e[0].length;for(var a=0;a<r;a++){for(t=new Array(n),o=0;o<n;o++)t[o]=e[o][a];i.push(t)}return 1===i.length?i[0]:i},f.map=function(e,t,n){var r,o,i,a,s;for(c(e[0])||(e=[e]),o=e.length,i=e[0].length,a=n?e:new Array(o),r=0;r<o;r++)for(a[r]||(a[r]=new Array(i)),s=0;s<i;s++)a[r][s]=t(e[r][s],r,s);return 1===a.length?a[0]:a},f.cumreduce=function(e,t,n){var r,o,i,a,s;for(c(e[0])||(e=[e]),o=e.length,i=e[0].length,a=n?e:new Array(o),r=0;r<o;r++)for(a[r]||(a[r]=new Array(i)),0<i&&(a[r][0]=e[r][0]),s=1;s<i;s++)a[r][s]=t(a[r][s-1],e[r][s]);return 1===a.length?a[0]:a},f.alter=function(e,t){return f.map(e,t,!0)},f.create=function(e,t,n){var r,o=new Array(e);h(t)&&(n=t,t=e);for(var i=0;i<e;i++)for(o[i]=new Array(t),r=0;r<t;r++)o[i][r]=n(i,r);return o},f.zeros=function(e,t){return d(t)||(t=e),f.create(e,t,r)},f.ones=function(e,t){return d(t)||(t=e),f.create(e,t,o)},f.rand=function(e,t){return d(t)||(t=e),f.create(e,t,s.random)},f.identity=function(e,t){return d(t)||(t=e),f.create(e,t,a)},f.symmetric=function(e){var t,n,r=e.length;if(e.length!==e[0].length)return!1;for(t=0;t<r;t++)for(n=0;n<r;n++)if(e[n][t]!==e[t][n])return!1;return!0},f.clear=function(e){return f.alter(e,r)},f.seq=function(e,t,n,r){h(r)||(r=!1);var o,i=[],a=u(e,t),s=(t*a-e*a)/((n-1)*a),l=e;for(o=0;l<=t&&o<n;l=(e*a+s*a*++o)/a)i.push(r?r(l,o):l);return i},f.arange=function(e,t,n){var r=[];if(n=n||1,t===l&&(t=e,e=0),e===t||0===n)return[];if(e<t&&n<0)return[];if(t<e&&0<n)return[];if(0<n)for(i=e;i<t;i+=n)r.push(i);else for(i=e;i>t;i+=n)r.push(i);return r},f.slice=function(){function a(e,t,n,r){var o,i=[],a=e.length;if(t===l&&n===l&&r===l)return f.copy(e);if(t=t||0,n=n||e.length,r=r||1,(t=0<=t?t:a+t)===(n=0<=n?n:a+n)||0===r)return[];if(t<n&&r<0)return[];if(n<t&&0<r)return[];if(0<r)for(o=t;o<n;o+=r)i.push(e[o]);else for(o=t;n<o;o+=r)i.push(e[o]);return i}return function(e,t){if(d((t=t||{}).row)){if(d(t.col))return e[t.row][t.col];var n=f.rowa(e,t.row),r=t.col||{};return a(n,r.start,r.end,r.step)}if(d(t.col)){var o=f.cola(e,t.col),i=t.row||{};return a(o,i.start,i.end,i.step)}var i=t.row||{},r=t.col||{};return a(e,i.start,i.end,i.step).map(function(e){return a(e,r.start,r.end,r.step)})}}(),f.sliceAssign=function(o,e,i){if(d(e.row)){if(d(e.col))return o[e.row][e.col]=i;e.col=e.col||{},e.col.start=e.col.start||0,e.col.end=e.col.end||o[0].length,e.col.step=e.col.step||1;var t=f.arange(e.col.start,s.min(o.length,e.col.end),e.col.step),n=e.row;return t.forEach(function(e,t){o[n][e]=i[t]}),o}if(d(e.col)){e.row=e.row||{},e.row.start=e.row.start||0,e.row.end=e.row.end||o.length,e.row.step=e.row.step||1;var r=f.arange(e.row.start,s.min(o[0].length,e.row.end),e.row.step),a=e.col;return r.forEach(function(e,t){o[e][a]=i[t]}),o}i[0].length===l&&(i=[i]),e.row.start=e.row.start||0,e.row.end=e.row.end||o.length,e.row.step=e.row.step||1,e.col.start=e.col.start||0,e.col.end=e.col.end||o[0].length,e.col.step=e.col.step||1;var r=f.arange(e.row.start,s.min(o.length,e.row.end),e.row.step),t=f.arange(e.col.start,s.min(o[0].length,e.col.end),e.col.step);return r.forEach(function(n,r){t.forEach(function(e,t){o[n][e]=i[r][t]})}),o},f.diagonal=function(e){var n=f.zeros(e.length,e.length);return e.forEach(function(e,t){n[t][t]=e}),n},f.copy=function(e){return e.map(function(e){return d(e)?e:e.map(function(e){return e})})};var g=f.prototype;return g.length=0,g.push=Array.prototype.push,g.sort=Array.prototype.sort,g.splice=Array.prototype.splice,g.slice=Array.prototype.slice,g.toArray=function(){return 1<this.length?e.call(this):e.call(this)[0]},g.map=function(e,t){return f(f.map(this,e,t))},g.cumreduce=function(e,t){return f(f.cumreduce(this,e,t))},g.alter=function(e){return f.alter(this,e),this},function(e){for(var t=0;t<e.length;t++)!function(r){g[r]=function(e){var t,n=this;return e?(setTimeout(function(){e.call(n,g[r].call(n))}),this):(t=f[r](this),c(t)?f(t):t)}}(e[t])}("transpose clear symmetric rows cols dimensions diag antidiag".split(" ")),function(e){for(var t=0;t<e.length;t++)!function(r){g[r]=function(e,t){var n=this;return t?(setTimeout(function(){t.call(n,g[r].call(n,e))}),this):f(f[r](this,e))}}(e[t])}("row col".split(" ")),function(e){for(var t=0;t<e.length;t++)!function(e){g[e]=new Function("return jStat(jStat."+e+".apply(null, arguments));")}(e[t])}("create zeros ones rand identity".split(" ")),f}(Math),Math),function(p,m){p.gammaln=function(e){var t,n,r,o=0,i=[76.18009172947146,-86.50532032941678,24.01409824083091,-1.231739572450155,.001208650973866179,-5395239384953e-18],a=1.000000000190015;for(r=(n=t=e)+5.5,r-=(t+.5)*m.log(r);o<6;o++)a+=i[o]/++n;return m.log(2.5066282746310007*a/t)-r},p.gammafn=function(e){var t,n,r,o=[-1.716185138865495,24.76565080557592,-379.80425647094563,629.3311553128184,866.9662027904133,-31451.272968848367,-36144.413418691176,66456.14382024054],i=[-30.8402300119739,315.35062697960416,-1015.1563674902192,-3107.771671572311,22538.11842098015,4755.846277527881,-134659.9598649693,-115132.2596755535],a=!1,s=0,l=0,u=0,c=e;if(c<=0){if(!(r=c%1+36e-17))return 1/0;a=(1&c?-1:1)*m.PI/m.sin(m.PI*r),c=1-c}t=(n=c)<1?c++:(c-=s=(0|c)-1)-1;for(var h=0;h<8;++h)u=(u+o[h])*t,l=l*t+i[h];if(r=u/l+1,n<c)r/=n;else if(c<n)for(h=0;h<s;++h)r*=c,c++;return a&&(r=a/r),r},p.gammap=function(e,t){return p.lowRegGamma(e,t)*p.gammafn(e)},p.lowRegGamma=function(e,t){var n,r=p.gammaln(e),o=e,i=1/e,a=i,s=t+1-e,l=1/1e-30,u=1/s,c=u,h=1,d=-~(8.5*m.log(1<=e?e:1/e)+.4*e+17);if(t<0||e<=0)return NaN;if(t<e+1){for(;h<=d;h++)i+=a*=t/++o;return i*m.exp(-t+e*m.log(t)-r)}for(;h<=d;h++)c*=(u=1/(u=(n=-h*(h-e))*u+(s+=2)))*(l=s+n/l);return 1-c*m.exp(-t+e*m.log(t)-r)},p.factorialln=function(e){return e<0?NaN:p.gammaln(e+1)},p.factorial=function(e){return e<0?NaN:p.gammafn(e+1)},p.combination=function(e,t){return 170<e||170<t?m.exp(p.combinationln(e,t)):p.factorial(e)/p.factorial(t)/p.factorial(e-t)},p.combinationln=function(e,t){return p.factorialln(e)-p.factorialln(t)-p.factorialln(e-t)},p.permutation=function(e,t){return p.factorial(e)/p.factorial(e-t)},p.betafn=function(e,t){if(!(e<=0||t<=0))return 170<e+t?m.exp(p.betaln(e,t)):p.gammafn(e)*p.gammafn(t)/p.gammafn(e+t)},p.betaln=function(e,t){return p.gammaln(e)+p.gammaln(t)-p.gammaln(e+t)},p.betacf=function(e,t,n){var r,o,i,a,s=1e-30,l=1,u=t+n,c=t+1,h=t-1,d=1,f=1-u*e/c;for(m.abs(f)<s&&(f=s),a=f=1/f;l<=100&&(f=1+(o=l*(n-l)*e/((h+(r=2*l))*(t+r)))*f,m.abs(f)<s&&(f=s),d=1+o/d,m.abs(d)<s&&(d=s),a*=(f=1/f)*d,f=1+(o=-(t+l)*(u+l)*e/((t+r)*(c+r)))*f,m.abs(f)<s&&(f=s),d=1+o/d,m.abs(d)<s&&(d=s),a*=i=(f=1/f)*d,!(m.abs(i-1)<3e-7));l++);return a},p.gammapinv=function(e,t){var n,r,o,i,a,s,l=0,u=t-1,c=p.gammaln(t);if(1<=e)return m.max(100,t+100*m.sqrt(t));if(e<=0)return 0;for(n=1<t?(a=m.log(u),s=m.exp(u*(a-1)-c),i=e<.5?e:1-e,n=(2.30753+.27061*(r=m.sqrt(-2*m.log(i))))/(1+r*(.99229+.04481*r))-r,e<.5&&(n=-n),m.max(.001,t*m.pow(1-1/(9*t)-n/(3*m.sqrt(t)),3))):e<(r=1-t*(.253+.12*t))?m.pow(e/r,1/t):1-m.log(1-(e-r)/(1-r));l<12;l++){if(n<=0)return 0;if((n-=r=(o=(p.lowRegGamma(t,n)-e)/(r=1<t?s*m.exp(-(n-u)+u*(m.log(n)-a)):m.exp(-n+u*m.log(n)-c)))/(1-.5*m.min(1,o*((t-1)/n-1))))<=0&&(n=.5*(n+r)),m.abs(r)<1e-8*n)break}return n},p.erf=function(e){var t,n,r,o,i=[-1.3026537197817094,.6419697923564902,.019476473204185836,-.00956151478680863,-.000946595344482036,.000366839497852761,42523324806907e-18,-20278578112534e-18,-1624290004647e-18,130365583558e-17,1.5626441722e-8,-8.5238095915e-8,6.529054439e-9,5.059343495e-9,-9.91364156e-10,-2.27365122e-10,96467911e-18,2394038e-18,-6886027e-18,894487e-18,313092e-18,-112708e-18,381e-18,7106e-18,-1523e-18,-94e-18,121e-18,-28e-18],a=i.length-1,s=!1,l=0,u=0;for(e<0&&(e=-e,s=!0),n=4*(t=2/(2+e))-2;0<a;a--)l=n*(r=l)-u+i[a],u=r;return o=t*m.exp(-e*e+.5*(i[0]+n*l)-u),s?o-1:1-o},p.erfc=function(e){return 1-p.erf(e)},p.erfcinv=function(e){var t,n,r,o,i=0;if(2<=e)return-100;if(e<=0)return 100;for(o=e<1?e:2-e,t=-.70711*((2.30753+.27061*(r=m.sqrt(-2*m.log(o/2))))/(1+r*(.99229+.04481*r))-r);i<2;i++)t+=(n=p.erfc(t)-o)/(1.1283791670955126*m.exp(-t*t)-t*n);return e<1?t:-t},p.ibetainv=function(e,t,n){var r,o,i,a,s,l,u,c,h,d,f=t-1,g=n-1,v=0;if(e<=0)return 0;if(1<=e)return 1;for(l=1<=t&&1<=n?(i=e<.5?e:1-e,l=(2.30753+.27061*(a=m.sqrt(-2*m.log(i))))/(1+a*(.99229+.04481*a))-a,e<.5&&(l=-l),u=(l*l-3)/6,c=2/(1/(2*t-1)+1/(2*n-1)),h=l*m.sqrt(u+c)/c-(1/(2*n-1)-1/(2*t-1))*(u+5/6-2/(3*c)),t/(t+n*m.exp(2*h))):(r=m.log(t/(t+n)),o=m.log(n/(t+n)),e<(a=m.exp(t*r)/t)/(h=a+(s=m.exp(n*o)/n))?m.pow(t*h*e,1/t):1-m.pow(n*h*(1-e),1/n)),d=-p.gammaln(t)-p.gammaln(n)+p.gammaln(t+n);v<10;v++){if(0===l||1===l)return l;if((l-=a=(s=(p.ibeta(l,t,n)-e)/(a=m.exp(f*m.log(l)+g*m.log(1-l)+d)))/(1-.5*m.min(1,s*(f/l-g/(1-l)))))<=0&&(l=.5*(l+a)),1<=l&&(l=.5*(l+a+1)),m.abs(a)<1e-8*l&&0<v)break}return l},p.ibeta=function(e,t,n){var r=0===e||1===e?0:m.exp(p.gammaln(t+n)-p.gammaln(t)-p.gammaln(n)+t*m.log(e)+n*m.log(1-e));return!(e<0||1<e)&&(e<(t+1)/(t+n+2)?r*p.betacf(e,t,n)/t:1-r*p.betacf(1-e,n,t)/n)},p.randn=function(e,t){var n,r,o,i,a;if(t||(t=e),e)return p.create(e,t,function(){return p.randn()});for(;n=m.random(),r=1.7156*(m.random()-.5),.27597<(a=(o=n-.449871)*o+(i=m.abs(r)+.386595)*(.196*i-.25472*o))&&(.27846<a||r*r>-4*m.log(n)*n*n););return r/n},p.randg=function(e,t,n){var r,o,i,a,s,l,u=e;if(n||(n=t),e||(e=1),t)return(l=p.zeros(t,n)).alter(function(){return p.randg(e)}),l;e<1&&(e+=1),r=e-1/3,o=1/m.sqrt(9*r);do{for(;(a=1+o*(s=p.randn()))<=0;);a*=a*a,i=m.random()}while(i>1-.331*m.pow(s,4)&&m.log(i)>.5*s*s+r*(1-a+m.log(a)));if(e==u)return r*a;for(;0===(i=m.random()););return m.pow(i,1/u)*r*a},function(e){for(var t=0;t<e.length;t++)!function(t){p.fn[t]=function(){return p(p.map(this,function(e){return p[t](e)}))}}(e[t])}("gammaln gammafn factorial factorialln".split(" ")),function(e){for(var t=0;t<e.length;t++)!function(e){p.fn[e]=function(){return p(p[e].apply(null,arguments))}}(e[t])}("randn".split(" "))}(d,Math),function(S,b){function y(e,t,n){var r=[.9815606342467192,.9041172563704749,.7699026741943047,.5873179542866175,.3678314989981802,.1252334085114689],o=[.04717533638651183,.10693932599531843,.16007832854334622,.20316742672306592,.2334925365383548,.24914704581340277],i=.5*e;if(8<=i)return 1;var a,s=2*S.normal.cdf(i,0,1,1,0)-1;s=s>=b.exp(-50/n)?b.pow(s,n):0;for(var l=i,u=(8-i)/(a=3<e?2:3),c=l+u,h=0,d=n-1,f=1;f<=a;f++){for(var g=0,v=.5*(c+l),p=.5*(c-l),m=1;m<=12;m++){var y,w=v+p*(6<m?r[(y=12-m+1)-1]:-r[(y=m)-1]),C=w*w;if(60<C)break;var E=2*S.normal.cdf(w,0,1,1,0)*.5-2*S.normal.cdf(w,e,1,1,0)*.5;E>=b.exp(-30/d)&&(g+=E=o[y-1]*b.exp(-.5*C)*b.pow(E,d))}h+=g*=2*p*n/b.sqrt(2*b.PI),l=c,c+=u}return(s+=h)<=b.exp(-30/t)?0:1<=(s=b.pow(s,t))?1:s}!function(e){for(var t=0;t<e.length;t++)!function(i){S[i]=function(e,t,n){return this instanceof arguments.callee?(this._a=e,this._b=t,this._c=n,this):new arguments.callee(e,t,n)},S.fn[i]=function(e,t,n){var r=S[i](e,t,n);return r.data=this,r},S[i].prototype.sample=function(e){var t=this._a,n=this._b,r=this._c;return e?S.alter(e,function(){return S[i].sample(t,n,r)}):S[i].sample(t,n,r)},function(e){for(var t=0;t<e.length;t++)!function(o){S[i].prototype[o]=function(e){var t=this._a,n=this._b,r=this._c;return e||0===e||(e=this.data),"number"!=typeof e?S.fn.map.call(e,function(e){return S[i][o](e,t,n,r)}):S[i][o](e,t,n,r)}}(e[t])}("pdf cdf inv".split(" ")),function(e){for(var t=0;t<e.length;t++)!function(e){S[i].prototype[e]=function(){return S[i][e](this._a,this._b,this._c)}}(e[t])}("mean median mode variance".split(" "))}(e[t])}("beta centralF cauchy chisquare exponential gamma invgamma kumaraswamy laplace lognormal noncentralt normal pareto studentt weibull uniform binomial negbin hypgeom poisson triangular tukey arcsine".split(" ")),S.extend(S.beta,{pdf:function(e,t,n){return 1<e||e<0?0:1==t&&1==n?1:t<512&&n<512?b.pow(e,t-1)*b.pow(1-e,n-1)/S.betafn(t,n):b.exp((t-1)*b.log(e)+(n-1)*b.log(1-e)-S.betaln(t,n))},cdf:function(e,t,n){return 1<e||e<0?1*(1<e):S.ibeta(e,t,n)},inv:function(e,t,n){return S.ibetainv(e,t,n)},mean:function(e,t){return e/(e+t)},median:function(e,t){return S.ibetainv(.5,e,t)},mode:function(e,t){return(e-1)/(e+t-2)},sample:function(e,t){var n=S.randg(e);return n/(n+S.randg(t))},variance:function(e,t){return e*t/(b.pow(e+t,2)*(e+t+1))}}),S.extend(S.centralF,{pdf:function(e,t,n){var r;return e<0?0:t<=2?0===e&&t<2?1/0:0===e&&2===t?1:1/S.betafn(t/2,n/2)*b.pow(t/n,t/2)*b.pow(e,t/2-1)*b.pow(1+t/n*e,-(t+n)/2):(r=t*e/(n+e*t),t*(n/(n+e*t))/2*S.binomial.pdf((t-2)/2,(t+n-2)/2,r))},cdf:function(e,t,n){return e<0?0:S.ibeta(t*e/(t*e+n),t/2,n/2)},inv:function(e,t,n){return n/(t*(1/S.ibetainv(e,t/2,n/2)-1))},mean:function(e,t){return 2<t?t/(t-2):void 0},mode:function(e,t){return 2<e?t*(e-2)/(e*(t+2)):void 0},sample:function(e,t){return 2*S.randg(e/2)/e/(2*S.randg(t/2)/t)},variance:function(e,t){if(!(t<=4))return 2*t*t*(e+t-2)/(e*(t-2)*(t-2)*(t-4))}}),S.extend(S.cauchy,{pdf:function(e,t,n){return n<0?0:n/(b.pow(e-t,2)+b.pow(n,2))/b.PI},cdf:function(e,t,n){return b.atan((e-t)/n)/b.PI+.5},inv:function(e,t,n){return t+n*b.tan(b.PI*(e-.5))},median:function(e,t){return e},mode:function(e,t){return e},sample:function(e,t){return S.randn()*b.sqrt(1/(2*S.randg(.5)))*t+e}}),S.extend(S.chisquare,{pdf:function(e,t){return e<0?0:0===e&&2===t?.5:b.exp((t/2-1)*b.log(e)-e/2-t/2*b.log(2)-S.gammaln(t/2))},cdf:function(e,t){return e<0?0:S.lowRegGamma(t/2,e/2)},inv:function(e,t){return 2*S.gammapinv(e,.5*t)},mean:function(e){return e},median:function(e){return e*b.pow(1-2/(9*e),3)},mode:function(e){return 0<e-2?e-2:0},sample:function(e){return 2*S.randg(e/2)},variance:function(e){return 2*e}}),S.extend(S.exponential,{pdf:function(e,t){return e<0?0:t*b.exp(-t*e)},cdf:function(e,t){return e<0?0:1-b.exp(-t*e)},inv:function(e,t){return-b.log(1-e)/t},mean:function(e){return 1/e},median:function(e){return 1/e*b.log(2)},mode:function(e){return 0},sample:function(e){return-1/e*b.log(b.random())},variance:function(e){return b.pow(e,-2)}}),S.extend(S.gamma,{pdf:function(e,t,n){return e<0?0:0===e&&1===t?1/n:b.exp((t-1)*b.log(e)-e/n-S.gammaln(t)-t*b.log(n))},cdf:function(e,t,n){return e<0?0:S.lowRegGamma(t,e/n)},inv:function(e,t,n){return S.gammapinv(e,t)*n},mean:function(e,t){return e*t},mode:function(e,t){if(1<e)return(e-1)*t},sample:function(e,t){return S.randg(e)*t},variance:function(e,t){return e*t*t}}),S.extend(S.invgamma,{pdf:function(e,t,n){return e<=0?0:b.exp(-(t+1)*b.log(e)-n/e-S.gammaln(t)+t*b.log(n))},cdf:function(e,t,n){return e<=0?0:1-S.lowRegGamma(t,n/e)},inv:function(e,t,n){return n/S.gammapinv(1-e,t)},mean:function(e,t){return 1<e?t/(e-1):void 0},mode:function(e,t){return t/(e+1)},sample:function(e,t){return t/S.randg(e)},variance:function(e,t){if(!(e<=2))return t*t/((e-1)*(e-1)*(e-2))}}),S.extend(S.kumaraswamy,{pdf:function(e,t,n){return 0===e&&1===t?n:1===e&&1===n?t:b.exp(b.log(t)+b.log(n)+(t-1)*b.log(e)+(n-1)*b.log(1-b.pow(e,t)))},cdf:function(e,t,n){return e<0?0:1<e?1:1-b.pow(1-b.pow(e,t),n)},inv:function(e,t,n){return b.pow(1-b.pow(1-e,1/n),1/t)},mean:function(e,t){return t*S.gammafn(1+1/e)*S.gammafn(t)/S.gammafn(1+1/e+t)},median:function(e,t){return b.pow(1-b.pow(2,-1/t),1/e)},mode:function(e,t){if(1<=e&&1<=t&&1!==e&&1!==t)return b.pow((e-1)/(e*t-1),1/e)},variance:function(e,t){throw new Error("variance not yet implemented")}}),S.extend(S.lognormal,{pdf:function(e,t,n){return e<=0?0:b.exp(-b.log(e)-.5*b.log(2*b.PI)-b.log(n)-b.pow(b.log(e)-t,2)/(2*n*n))},cdf:function(e,t,n){return e<0?0:.5+.5*S.erf((b.log(e)-t)/b.sqrt(2*n*n))},inv:function(e,t,n){return b.exp(-1.4142135623730951*n*S.erfcinv(2*e)+t)},mean:function(e,t){return b.exp(e+t*t/2)},median:function(e,t){return b.exp(e)},mode:function(e,t){return b.exp(e-t*t)},sample:function(e,t){return b.exp(S.randn()*t+e)},variance:function(e,t){return(b.exp(t*t)-1)*b.exp(2*e+t*t)}}),S.extend(S.noncentralt,{pdf:function(e,t,n){return b.abs(n)<1e-14?S.studentt.pdf(e,t):b.abs(e)<1e-14?b.exp(S.gammaln((t+1)/2)-n*n/2-.5*b.log(b.PI*t)-S.gammaln(t/2)):t/e*(S.noncentralt.cdf(e*b.sqrt(1+2/t),t+2,n)-S.noncentralt.cdf(e,t,n))},cdf:function(e,t,n){if(b.abs(n)<1e-14)return S.studentt.cdf(e,t);var r=!1;e<0&&(r=!0,n=-n);for(var o=S.normal.cdf(-n,0,1),i=1e-14+1,a=i,s=e*e/(e*e+t),l=0,u=b.exp(-n*n/2),c=b.exp(-n*n/2-.5*b.log(2)-S.gammaln(1.5))*n;l<200||1e-14<a||1e-14<i;)a=i,0<l&&(u*=n*n/(2*l),c*=n*n/(2*(l+.5))),o+=.5*(i=u*S.beta.cdf(s,l+.5,t/2)+c*S.beta.cdf(s,l+1,t/2)),l++;return r?1-o:o}}),S.extend(S.normal,{pdf:function(e,t,n){return b.exp(-.5*b.log(2*b.PI)-b.log(n)-b.pow(e-t,2)/(2*n*n))},cdf:function(e,t,n){return.5*(1+S.erf((e-t)/b.sqrt(2*n*n)))},inv:function(e,t,n){return-1.4142135623730951*n*S.erfcinv(2*e)+t},mean:function(e,t){return e},median:function(e,t){return e},mode:function(e,t){return e},sample:function(e,t){return S.randn()*t+e},variance:function(e,t){return t*t}}),S.extend(S.pareto,{pdf:function(e,t,n){return e<t?0:n*b.pow(t,n)/b.pow(e,n+1)},cdf:function(e,t,n){return e<t?0:1-b.pow(t/e,n)},inv:function(e,t,n){return t/b.pow(1-e,1/n)},mean:function(e,t){if(!(t<=1))return t*b.pow(e,t)/(t-1)},median:function(e,t){return e*(t*b.SQRT2)},mode:function(e,t){return e},variance:function(e,t){if(!(t<=2))return e*e*t/(b.pow(t-1,2)*(t-2))}}),S.extend(S.studentt,{pdf:function(e,t){return t=1e100<t?1e100:t,1/(b.sqrt(t)*S.betafn(.5,t/2))*b.pow(1+e*e/t,-(t+1)/2)},cdf:function(e,t){var n=t/2;return S.ibeta((e+b.sqrt(e*e+t))/(2*b.sqrt(e*e+t)),n,n)},inv:function(e,t){var n=S.ibetainv(2*b.min(e,1-e),.5*t,.5);return n=b.sqrt(t*(1-n)/n),.5<e?n:-n},mean:function(e){return 1<e?0:void 0},median:function(e){return 0},mode:function(e){return 0},sample:function(e){return S.randn()*b.sqrt(e/(2*S.randg(e/2)))},variance:function(e){return 2<e?e/(e-2):1<e?1/0:void 0}}),S.extend(S.weibull,{pdf:function(e,t,n){return e<0||t<0||n<0?0:n/t*b.pow(e/t,n-1)*b.exp(-b.pow(e/t,n))},cdf:function(e,t,n){return e<0?0:1-b.exp(-b.pow(e/t,n))},inv:function(e,t,n){return t*b.pow(-b.log(1-e),1/n)},mean:function(e,t){return e*S.gammafn(1+1/t)},median:function(e,t){return e*b.pow(b.log(2),1/t)},mode:function(e,t){return t<=1?0:e*b.pow((t-1)/t,1/t)},sample:function(e,t){return e*b.pow(-b.log(b.random()),1/t)},variance:function(e,t){return e*e*S.gammafn(1+2/t)-b.pow(S.weibull.mean(e,t),2)}}),S.extend(S.uniform,{pdf:function(e,t,n){return e<t||n<e?0:1/(n-t)},cdf:function(e,t,n){return e<t?0:e<n?(e-t)/(n-t):1},inv:function(e,t,n){return t+e*(n-t)},mean:function(e,t){return.5*(e+t)},median:function(e,t){return S.mean(e,t)},mode:function(e,t){throw new Error("mode is not yet implemented")},sample:function(e,t){return e/2+t/2+(t/2-e/2)*(2*b.random()-1)},variance:function(e,t){return b.pow(t-e,2)/12}}),S.extend(S.binomial,{pdf:function(e,t,n){return 0===n||1===n?t*n===e?1:0:S.combination(t,e)*b.pow(n,e)*b.pow(1-n,t-e)},cdf:function(e,t,n){var r=[],o=0;if(e<0)return 0;if(e<t){for(;o<=e;o++)r[o]=S.binomial.pdf(o,t,n);return S.sum(r)}return 1}}),S.extend(S.negbin,{pdf:function(e,t,n){return e===e>>>0&&(e<0?0:S.combination(e+t-1,t-1)*b.pow(1-n,e)*b.pow(n,t))},cdf:function(e,t,n){var r=0,o=0;if(e<0)return 0;for(;o<=e;o++)r+=S.negbin.pdf(o,t,n);return r}}),S.extend(S.hypgeom,{pdf:function(e,t,n,r){if(e!=e|0)return!1;if(e<0||e<n-(t-r))return 0;if(r<e||n<e)return 0;if(t<2*n)return t<2*r?S.hypgeom.pdf(t-n-r+e,t,t-n,t-r):S.hypgeom.pdf(r-e,t,t-n,r);if(t<2*r)return S.hypgeom.pdf(n-e,t,n,t-r);if(n<r)return S.hypgeom.pdf(e,t,r,n);for(var o=1,i=0,a=0;a<e;a++){for(;1<o&&i<r;)o*=1-n/(t-i),i++;o*=(r-a)*(n-a)/((a+1)*(t-n-r+a+1))}for(;i<r;i++)o*=1-n/(t-i);return b.min(1,b.max(0,o))},cdf:function(e,t,n,r){if(e<0||e<n-(t-r))return 0;if(r<=e||n<=e)return 1;if(t<2*n)return t<2*r?S.hypgeom.cdf(t-n-r+e,t,t-n,t-r):1-S.hypgeom.cdf(r-e-1,t,t-n,r);if(t<2*r)return 1-S.hypgeom.cdf(n-e-1,t,n,t-r);if(n<r)return S.hypgeom.cdf(e,t,r,n);for(var o=1,i=1,a=0,s=0;s<e;s++){for(;1<o&&a<r;){var l=1-n/(t-a);i*=l,o*=l,a++}o+=i*=(r-s)*(n-s)/((s+1)*(t-n-r+s+1))}for(;a<r;a++)o*=1-n/(t-a);return b.min(1,b.max(0,o))}}),S.extend(S.poisson,{pdf:function(e,t){return t<0||e%1!=0||e<0?0:b.pow(t,e)*b.exp(-t)/S.factorial(e)},cdf:function(e,t){var n=[],r=0;if(e<0)return 0;for(;r<=e;r++)n.push(S.poisson.pdf(r,t));return S.sum(n)},mean:function(e){return e},variance:function(e){return e},sample:function(e){for(var t=1,n=0,r=b.exp(-e);n++,r<(t*=b.random()););return n-1}}),S.extend(S.triangular,{pdf:function(e,t,n,r){return n<=t||r<t||n<r?NaN:e<t||n<e?0:e<r?2*(e-t)/((n-t)*(r-t)):e===r?2/(n-t):2*(n-e)/((n-t)*(n-r))},cdf:function(e,t,n,r){return n<=t||r<t||n<r?NaN:e<=t?0:n<=e?1:e<=r?b.pow(e-t,2)/((n-t)*(r-t)):1-b.pow(n-e,2)/((n-t)*(n-r))},inv:function(e,t,n,r){return n<=t||r<t||n<r?NaN:e<=(r-t)/(n-t)?t+(n-t)*b.sqrt(e*((r-t)/(n-t))):t+(n-t)*(1-b.sqrt((1-e)*(1-(r-t)/(n-t))))},mean:function(e,t,n){return(e+t+n)/3},median:function(e,t,n){return n<=(e+t)/2?t-b.sqrt((t-e)*(t-n))/b.sqrt(2):(e+t)/2<n?e+b.sqrt((t-e)*(n-e))/b.sqrt(2):void 0},mode:function(e,t,n){return n},sample:function(e,t,n){var r=b.random();return r<(n-e)/(t-e)?e+b.sqrt(r*(t-e)*(n-e)):t-b.sqrt((1-r)*(t-e)*(t-n))},variance:function(e,t,n){return(e*e+t*t+n*n-e*t-e*n-t*n)/18}}),S.extend(S.arcsine,{pdf:function(e,t,n){return n<=t?NaN:e<=t||n<=e?0:2/b.PI*b.pow(b.pow(n-t,2)-b.pow(2*e-t-n,2),-.5)},cdf:function(e,t,n){return e<t?0:e<n?2/b.PI*b.asin(b.sqrt((e-t)/(n-t))):1},inv:function(e,t,n){return t+(.5-.5*b.cos(b.PI*e))*(n-t)},mean:function(e,t){return t<=e?NaN:(e+t)/2},median:function(e,t){return t<=e?NaN:(e+t)/2},mode:function(e,t){throw new Error("mode is not yet implemented")},sample:function(e,t){return(e+t)/2+(t-e)/2*b.sin(2*b.PI*S.uniform.sample(0,1))},variance:function(e,t){return t<=e?NaN:b.pow(t-e,2)/8}}),S.extend(S.laplace,{pdf:function(e,t,n){return n<=0?0:b.exp(-b.abs(e-t)/n)/(2*n)},cdf:function(e,t,n){return n<=0?0:e<t?.5*b.exp((e-t)/n):1-.5*b.exp(-(e-t)/n)},mean:function(e,t){return e},median:function(e,t){return e},mode:function(e,t){return e},variance:function(e,t){return 2*t*t},sample:function(e,t){var n=b.random()-.5;return e-t*function(e){return e/b.abs(e)}(n)*b.log(1-2*b.abs(n))}}),S.extend(S.tukey,{cdf:function(e,t,n){var r=t,o=[.9894009349916499,.9445750230732326,.8656312023878318,.755404408355003,.6178762444026438,.45801677765722737,.2816035507792589,.09501250983763744],i=[.027152459411754096,.062253523938647894,.09515851168249279,.12462897125553388,.14959598881657674,.16915651939500254,.18260341504492358,.1894506104550685];if(e<=0)return 0;if(n<2||r<2)return NaN;if(!Number.isFinite(e))return 1;if(25e3<n)return y(e,1,r);var a,s=.5*n,l=s*b.log(n)-n*b.log(2)-S.gammaln(s),u=s-1,c=.25*n;a=n<=100?1:n<=800?.5:n<=5e3?.25:.125,l+=b.log(a);for(var h=0,d=1;d<=50;d++){for(var f=0,g=(2*d-1)*a,v=1;v<=16;v++){var p,m;-30<=(m=8<v?(p=v-8-1,l+u*b.log(g+o[p]*a)-(o[p]*a+g)*c):(p=v-1,l+u*b.log(g-o[p]*a)+(o[p]*a-g)*c))&&(f+=y(8<v?e*b.sqrt(.5*(o[p]*a+g)):e*b.sqrt(.5*(-o[p]*a+g)),1,r)*i[p]*b.exp(m))}if(1<=d*a&&f<=1e-14)break;h+=f}if(1e-14<f)throw new Error("tukey.cdf failed to converge");return 1<h&&(h=1),h},inv:function(e,t,n){if(n<2||t<2)return NaN;if(e<0||1<e)return NaN;if(0===e)return 0;if(1===e)return 1/0;var r,o=function(e,t,n){var r=.5-.5*e,o=b.sqrt(b.log(1/(r*r))),i=o+((((-453642210148e-16*o-.204231210125)*o-.342242088547)*o-1)*o+.322232421088)/((((.0038560700634*o+.10353775285)*o+.531103462366)*o+.588581570495)*o+.099348462606);n<120&&(i+=(i*i*i+i)/n/4);var a=.8832-.2368*i;return n<120&&(a+=-1.214/n+1.208*i/n),i*(a*b.log(t-1)+1.4142)}(e,t,n),i=S.tukey.cdf(o,t,n)-e;r=0<i?b.max(0,o-1):o+1;for(var a,s=S.tukey.cdf(r,t,n)-e,l=1;l<50;l++)if(a=r-s*(r-o)/(s-i),i=s,o=r,a<0&&(a=0,s=-e),s=S.tukey.cdf(a,t,n)-e,r=a,b.abs(r-o)<1e-4)return a;throw new Error("tukey.inv failed to converge")}})}(d,Math),function(p,v){var s,l,o=Array.prototype.push,t=p.utils.isArray;function c(e){return t(e)||e instanceof p}p.extend({add:function(e,r){return c(r)?(c(r[0])||(r=[r]),p.map(e,function(e,t,n){return e+r[t][n]})):p.map(e,function(e){return e+r})},subtract:function(e,r){return c(r)?(c(r[0])||(r=[r]),p.map(e,function(e,t,n){return e-r[t][n]||0})):p.map(e,function(e){return e-r})},divide:function(e,t){return c(t)?(c(t[0])||(t=[t]),p.multiply(e,p.inv(t))):p.map(e,function(e){return e/t})},multiply:function(e,t){var n,r,o,i,a,s,l,u;if(void 0===e.length&&void 0===t.length)return e*t;if(a=e.length,s=e[0].length,l=p.zeros(a,o=c(t)?t[0].length:s),u=0,c(t)){for(;u<o;u++)for(n=0;n<a;n++){for(r=i=0;r<s;r++)i+=e[n][r]*t[r][u];l[n][u]=i}return 1===a&&1===u?l[0][0]:l}return p.map(e,function(e){return e*t})},outer:function(e,t){return p.multiply(e.map(function(e){return[e]}),[t])},dot:function(e,t){c(e[0])||(e=[e]),c(t[0])||(t=[t]);for(var n,r,o=1===e[0].length&&1!==e.length?p.transpose(e):e,i=1===t[0].length&&1!==t.length?p.transpose(t):t,a=[],s=0,l=o.length,u=o[0].length;s<l;s++){for(a[s]=[],r=n=0;r<u;r++)n+=o[s][r]*i[s][r];a[s]=n}return 1===a.length?a[0]:a},pow:function(e,t){return p.map(e,function(e){return v.pow(e,t)})},exp:function(e){return p.map(e,function(e){return v.exp(e)})},log:function(e){return p.map(e,function(e){return v.log(e)})},abs:function(e){return p.map(e,function(e){return v.abs(e)})},norm:function(e,t){var n=0,r=0;for(isNaN(t)&&(t=2),c(e[0])&&(e=e[0]);r<e.length;r++)n+=v.pow(v.abs(e[r]),t);return v.pow(n,1/t)},angle:function(e,t){return v.acos(p.dot(e,t)/(p.norm(e)*p.norm(t)))},aug:function(e,t){for(var n=[],r=0;r<e.length;r++)n.push(e[r].slice());for(r=0;r<n.length;r++)o.apply(n[r],t[r]);return n},inv:function(e){for(var t,n=e.length,r=e[0].length,o=p.identity(n,r),i=p.gauss_jordan(e,o),a=[],s=0;s<n;s++)for(a[s]=[],t=r;t<i[0].length;t++)a[s][t-r]=i[s][t];return a},det:function(e){var t,n=e.length,r=2*n,o=new Array(r),i=n-1,a=r-1,s=i-n+1,l=a,u=0,c=0;if(2===n)return e[0][0]*e[1][1]-e[0][1]*e[1][0];for(;u<r;u++)o[u]=1;for(u=0;u<n;u++){for(t=0;t<n;t++)o[s<0?s+n:s]*=e[u][t],o[l<n?l+n:l]*=e[u][t],s++,l--;s=--i-n+1,l=--a}for(u=0;u<n;u++)c+=o[u];for(;u<r;u++)c-=o[u];return c},gauss_elimination:function(e,t){var n,r,o,i,a=0,s=0,l=e.length,u=e[0].length,c=1,h=0,d=[];for(n=(e=p.aug(e,t))[0].length,a=0;a<l;a++){for(r=e[a][a],i=(s=a)+1;i<u;i++)r<v.abs(e[i][a])&&(r=e[i][a],s=i);if(s!=a)for(i=0;i<n;i++)o=e[a][i],e[a][i]=e[s][i],e[s][i]=o;for(s=a+1;s<l;s++)for(c=e[s][a]/e[a][a],i=a;i<n;i++)e[s][i]=e[s][i]-c*e[a][i]}for(a=l-1;0<=a;a--){for(h=0,s=a+1;s<=l-1;s++)h+=d[s]*e[a][s];d[a]=(e[a][n-1]-h)/e[a][a]}return d},gauss_jordan:function(e,t){for(var n=p.aug(e,t),r=n.length,o=n[0].length,i=0,a=0;a<r;a++){for(var s=a,l=a+1;l<r;l++)v.abs(n[l][a])>v.abs(n[s][a])&&(s=l);var u=n[a];for(n[a]=n[s],n[s]=u,l=a+1;l<r;l++){i=n[l][a]/n[a][a];for(var c=a;c<o;c++)n[l][c]-=n[a][c]*i}}for(a=r-1;0<=a;a--){for(i=n[a][a],l=0;l<a;l++)for(c=o-1;a-1<c;c--)n[l][c]-=n[a][c]*n[l][a]/i;for(n[a][a]/=i,c=r;c<o;c++)n[a][c]/=i}return n},triaUpSolve:function(n,e){var r,o=n[0].length,i=p.zeros(1,o)[0],t=!1;return null!=e[0].length&&(e=e.map(function(e){return e[0]}),t=!0),p.arange(o-1,-1,-1).forEach(function(t){r=p.arange(t+1,o).map(function(e){return i[e]*n[t][e]}),i[t]=(e[t]-p.sum(r))/n[t][t]}),t?i.map(function(e){return[e]}):i},triaLowSolve:function(n,e){var r,t=n[0].length,o=p.zeros(1,t)[0],i=!1;return null!=e[0].length&&(e=e.map(function(e){return e[0]}),i=!0),p.arange(t).forEach(function(t){r=p.arange(t).map(function(e){return n[t][e]*o[e]}),o[t]=(e[t]-p.sum(r))/n[t][t]}),i?o.map(function(e){return[e]}):o},lu:function(r){var e,t=r.length,o=p.identity(t),a=p.zeros(r.length,r[0].length);return p.arange(t).forEach(function(e){a[0][e]=r[0][e]}),p.arange(1,t).forEach(function(n){p.arange(n).forEach(function(t){e=p.arange(t).map(function(e){return o[n][e]*a[e][t]}),o[n][t]=(r[n][t]-p.sum(e))/a[t][t]}),p.arange(n,t).forEach(function(t){e=p.arange(n).map(function(e){return o[n][e]*a[e][t]}),a[n][t]=r[i][t]-p.sum(e)})}),[o,a]},cholesky:function(e){var r,t=e.length,o=p.zeros(e.length,e[0].length);return p.arange(t).forEach(function(n){r=p.arange(n).map(function(e){return v.pow(o[n][e],2)}),o[n][n]=v.sqrt(e[n][n]-p.sum(r)),p.arange(n+1,t).forEach(function(t){r=p.arange(n).map(function(e){return o[n][e]*o[t][e]}),o[t][n]=(e[n][t]-p.sum(r))/o[n][n]})}),o},gauss_jacobi:function(e,t,n,r){for(var o,i,a,s,l=0,u=0,c=e.length,h=[],d=[],f=[];l<c;l++)for(h[l]=[],d[l]=[],f[l]=[],u=0;u<c;u++)u<l?(h[l][u]=e[l][u],d[l][u]=f[l][u]=0):l<u?(d[l][u]=e[l][u],h[l][u]=f[l][u]=0):(f[l][u]=e[l][u],h[l][u]=d[l][u]=0);for(a=p.multiply(p.multiply(p.inv(f),p.add(h,d)),-1),i=p.multiply(p.inv(f),t),o=n,s=p.add(p.multiply(a,n),i),l=2;v.abs(p.norm(p.subtract(s,o)))>r;)o=s,s=p.add(p.multiply(a,o),i),l++;return s},gauss_seidel:function(e,t,n,r){for(var o,i,a,s,l,u=0,c=e.length,h=[],d=[],f=[];u<c;u++)for(h[u]=[],d[u]=[],f[u]=[],o=0;o<c;o++)o<u?(h[u][o]=e[u][o],d[u][o]=f[u][o]=0):u<o?(d[u][o]=e[u][o],h[u][o]=f[u][o]=0):(f[u][o]=e[u][o],h[u][o]=d[u][o]=0);for(s=p.multiply(p.multiply(p.inv(p.add(f,h)),d),-1),a=p.multiply(p.inv(p.add(f,h)),t),i=n,l=p.add(p.multiply(s,n),a),u=2;v.abs(p.norm(p.subtract(l,i)))>r;)i=l,l=p.add(p.multiply(s,i),a),u+=1;return l},SOR:function(e,t,n,r,o){for(var i,a,s,l,u,c=0,h=e.length,d=[],f=[],g=[];c<h;c++)for(d[c]=[],f[c]=[],g[c]=[],i=0;i<h;i++)i<c?(d[c][i]=e[c][i],f[c][i]=g[c][i]=0):c<i?(f[c][i]=e[c][i],d[c][i]=g[c][i]=0):(g[c][i]=e[c][i],d[c][i]=f[c][i]=0);for(l=p.multiply(p.inv(p.add(g,p.multiply(d,o))),p.subtract(p.multiply(g,1-o),p.multiply(f,o))),s=p.multiply(p.multiply(p.inv(p.add(g,p.multiply(d,o))),t),o),a=n,u=p.add(p.multiply(l,n),s),c=2;v.abs(p.norm(p.subtract(u,a)))>r;)a=u,u=p.add(p.multiply(l,a),s),c++;return u},householder:function(e){for(var t,n,r,o,i=e.length,a=e[0].length,s=0,l=[],u=[];s<i-1;s++){for(t=0,o=s+1;o<a;o++)t+=e[o][s]*e[o][s];for(t=(0<e[s+1][s]?-1:1)*v.sqrt(t),n=v.sqrt((t*t-e[s+1][s]*t)/2),(l=p.zeros(i,1))[s+1][0]=(e[s+1][s]-t)/(2*n),r=s+2;r<i;r++)l[r][0]=e[r][s]/(2*n);u=p.subtract(p.identity(i,a),p.multiply(p.multiply(l,p.transpose(l)),2)),e=p.multiply(u,p.multiply(e,u))}return e},QR:(s=p.sum,l=p.arange,function(t){var e,n,o,i=t.length,a=t[0].length;for(t=p.copy(t),r=p.zeros(a,a),n=0;n<a;n++){for(r[n][n]=v.sqrt(s(l(i).map(function(e){return t[e][n]*t[e][n]}))),e=0;e<i;e++)t[e][n]=t[e][n]/r[n][n];for(o=n+1;o<a;o++)for(r[n][o]=s(l(i).map(function(e){return t[e][n]*t[e][o]})),e=0;e<i;e++)t[e][o]=t[e][o]-t[e][n]*r[n][o]}return[t,r]}),lstsq:function(e,t){var n=!1;void 0===t[0].length&&(t=t.map(function(e){return[e]}),n=!0);var r=p.QR(e),o=r[0],i=r[1],a=e[0].length,s=p.slice(o,{col:{end:a}}),l=function(s){var e=(s=p.copy(s)).length,l=p.identity(e);return p.arange(e-1,-1,-1).forEach(function(a){p.sliceAssign(l,{row:a},p.divide(p.slice(l,{row:a}),s[a][a])),p.sliceAssign(s,{row:a},p.divide(p.slice(s,{row:a}),s[a][a])),p.arange(a).forEach(function(e){var t=p.multiply(s[e][a],-1),n=p.slice(s,{row:e}),r=p.multiply(p.slice(s,{row:a}),t);p.sliceAssign(s,{row:e},p.add(n,r));var o=p.slice(l,{row:e}),i=p.multiply(p.slice(l,{row:a}),t);p.sliceAssign(l,{row:e},p.add(o,i))})}),l}(p.slice(i,{row:{end:a}})),u=p.transpose(s);void 0===u[0].length&&(u=[u]);var c=p.multiply(p.multiply(l,u),t);return void 0===c.length&&(c=[[c]]),n?c.map(function(e){return e[0]}):c},jacobi:function(e){for(var t,n,r,o,i,a,s=1,l=e.length,u=p.identity(l,l),c=[];1===s;){o=e[0][1],r=1;for(var h=n=0;h<l;h++)for(t=0;t<l;t++)h!=t&&o<v.abs(e[h][t])&&(o=v.abs(e[h][t]),n=h,r=t);for(i=e[n][n]===e[r][r]?0<e[n][r]?v.PI/4:-v.PI/4:v.atan(2*e[n][r]/(e[n][n]-e[r][r]))/2,(a=p.identity(l,l))[n][n]=v.cos(i),a[n][r]=-v.sin(i),a[r][n]=v.sin(i),a[r][r]=v.cos(i),u=p.multiply(u,a),e=p.multiply(p.multiply(p.inv(a),e),a),s=0,h=1;h<l;h++)for(t=1;t<l;t++)h!=t&&.001<v.abs(e[h][t])&&(s=1)}for(h=0;h<l;h++)c.push(e[h][h]);return[u,c]},rungekutta:function(e,t,n,r,o,i){var a,s,l;if(2===i)for(;r<=n;)o+=((a=t*e(r,o))+(s=t*e(r+t,o+a)))/2,r+=t;if(4===i)for(;r<=n;)o+=((a=t*e(r,o))+2*(s=t*e(r+t/2,o+a/2))+2*(l=t*e(r+t/2,o+s/2))+t*e(r+t,o+l))/6,r+=t;return o},romberg:function(e,t,n,r){for(var o,i,a,s,l,u=0,c=(n-t)/2,h=[],d=[],f=[];u<r/2;){for(l=e(t),a=t,s=0;a<=n;a+=c,s++)h[s]=a;for(o=h.length,a=1;a<o-1;a++)l+=(a%2!=0?4:2)*e(h[a]);l=c/3*(l+e(n)),f[u]=l,c/=2,u++}for(i=f.length,o=1;1!==i;){for(a=0;a<i-1;a++)d[a]=(v.pow(4,o)*f[a+1]-f[a])/(v.pow(4,o)-1);i=d.length,f=d,d=[],o++}return f},richardson:function(e,t,n,r){function o(e,t){for(var n,r=0,o=e.length;r<o;r++)e[r]===t&&(n=r);return n}e.length;for(var i,a,s,l,u,c=v.abs(n-e[o(e,n)+1]),h=0,d=[],f=[];c<=r;)i=o(e,n+r),a=o(e,n),d[h]=(t[i]-2*t[a]+t[2*a-i])/(r*r),r/=2,h++;for(l=d.length,s=1;1!=l;){for(u=0;u<l-1;u++)f[u]=(v.pow(4,s)*d[u+1]-d[u])/(v.pow(4,s)-1);l=f.length,d=f,f=[],s++}return d},simpson:function(e,t,n,r){for(var o,i=(n-t)/r,a=e(t),s=[],l=t,u=0,c=1;l<=n;l+=i,u++)s[u]=l;for(o=s.length;c<o-1;c++)a+=(c%2!=0?4:2)*e(s[c]);return i/3*(a+e(n))},hermite:function(e,t,n,r){for(var o,i=e.length,a=0,s=0,l=[],u=[],c=[],h=[];s<i;s++){for(l[s]=1,o=0;o<i;o++)s!=o&&(l[s]*=(r-e[o])/(e[s]-e[o]));for(o=u[s]=0;o<i;o++)s!=o&&(u[s]+=1/(e[s]-e[o]));c[s]=(1-2*(r-e[s])*u[s])*(l[s]*l[s]),h[s]=(r-e[s])*(l[s]*l[s]),a+=c[s]*t[s]+h[s]*n[s]}return a},lagrange:function(e,t,n){for(var r,o,i=0,a=0,s=e.length;a<s;a++){for(o=t[a],r=0;r<s;r++)a!=r&&(o*=(n-e[r])/(e[a]-e[r]));i+=o}return i},cubic_spline:function(e,t,n){for(var r,o,i=e.length,a=0,s=[],l=[],u=[],c=[],h=[],d=[];a<i-1;a++)c[a]=e[a+1]-e[a];for(u[0]=0,a=1;a<i-1;a++)u[a]=3/c[a]*(t[a+1]-t[a])-3/c[a-1]*(t[a]-t[a-1]);for(a=1;a<i-1;a++)s[a]=[],l[a]=[],s[a][a-1]=c[a-1],s[a][a]=2*(c[a-1]+c[a]),s[a][a+1]=c[a],l[a][0]=u[a];for(o=p.multiply(p.inv(s),l),r=0;r<i-1;r++)h[r]=(t[r+1]-t[r])/c[r]-c[r]*(o[r+1][0]+2*o[r][0])/3,d[r]=(o[r+1][0]-o[r][0])/(3*c[r]);for(r=0;r<i&&!(e[r]>n);r++);return t[r-=1]+(n-e[r])*h[r]+p.sq(n-e[r])*o[r]+(n-e[r])*p.sq(n-e[r])*d[r]},gauss_quadrature:function(){throw new Error("gauss_quadrature not yet implemented")},PCA:function(e){var t,n,r,o,i,a=e.length,s=e[0].length,l=0,u=[],c=[],h=[],d=[],f=[],g=[],v=[];for(l=0;l<a;l++)u[l]=p.sum(e[l])/s;for(l=0;l<s;l++)for(f[l]=[],t=0;t<a;t++)f[l][t]=e[t][l]-u[t];for(f=p.transpose(f),l=0;l<a;l++)for(g[l]=[],t=0;t<a;t++)g[l][t]=p.dot([f[l]],[f[t]])/(s-1);for(i=(r=p.jacobi(g))[0],c=r[1],v=p.transpose(i),l=0;l<c.length;l++)for(t=l;t<c.length;t++)c[l]<c[t]&&(n=c[l],c[l]=c[t],c[t]=n,h=v[l],v[l]=v[t],v[t]=h);for(o=p.transpose(f),l=0;l<a;l++)for(d[l]=[],t=0;t<o.length;t++)d[l][t]=p.dot([v[l]],[o[t]]);return[e,c,v,d]}}),function(e){for(var t=0;t<e.length;t++)!function(r){p.fn[r]=function(e,t){var n=this;return t?(setTimeout(function(){t.call(n,p.fn[r].call(n,e))},15),this):"number"==typeof p[r](this,e)?p[r](this,e):p(p[r](this,e))}}(e[t])}("add divide multiply subtract dot pow exp log abs norm angle".split(" "))}(d,Math),function(u,c){var h=[].slice,a=u.utils.isNumber,n=u.utils.isArray;function i(e,t,n,r){if(1<e||1<n||e<=0||n<=0)throw new Error("Proportions should be greater than 0 and less than 1");var o=(e*t+n*r)/(t+r);return(e-n)/c.sqrt(o*(1-o)*(1/t+1/r))}u.extend({zscore:function(){var e=h.call(arguments);return a(e[1])?(e[0]-e[1])/e[2]:(e[0]-u.mean(e[1]))/u.stdev(e[1],e[2])},ztest:function(){var e,t=h.call(arguments);return n(t[1])?(e=u.zscore(t[0],t[1],t[3]),1===t[2]?u.normal.cdf(-c.abs(e),0,1):2*u.normal.cdf(-c.abs(e),0,1)):2<t.length?(e=u.zscore(t[0],t[1],t[2]),1===t[3]?u.normal.cdf(-c.abs(e),0,1):2*u.normal.cdf(-c.abs(e),0,1)):(e=t[0],1===t[1]?u.normal.cdf(-c.abs(e),0,1):2*u.normal.cdf(-c.abs(e),0,1))}}),u.extend(u.fn,{zscore:function(e,t){return(e-this.mean())/this.stdev(t)},ztest:function(e,t,n){var r=c.abs(this.zscore(e,n));return 1===t?u.normal.cdf(-r,0,1):2*u.normal.cdf(-r,0,1)}}),u.extend({tscore:function(){var e=h.call(arguments);return 4===e.length?(e[0]-e[1])/(e[2]/c.sqrt(e[3])):(e[0]-u.mean(e[1]))/(u.stdev(e[1],!0)/c.sqrt(e[1].length))},ttest:function(){var e,t=h.call(arguments);return 5===t.length?(e=c.abs(u.tscore(t[0],t[1],t[2],t[3])),1===t[4]?u.studentt.cdf(-e,t[3]-1):2*u.studentt.cdf(-e,t[3]-1)):a(t[1])?(e=c.abs(t[0]),1==t[2]?u.studentt.cdf(-e,t[1]-1):2*u.studentt.cdf(-e,t[1]-1)):(e=c.abs(u.tscore(t[0],t[1])),1==t[2]?u.studentt.cdf(-e,t[1].length-1):2*u.studentt.cdf(-e,t[1].length-1))}}),u.extend(u.fn,{tscore:function(e){return(e-this.mean())/(this.stdev(!0)/c.sqrt(this.cols()))},ttest:function(e,t){return 1===t?1-u.studentt.cdf(c.abs(this.tscore(e)),this.cols()-1):2*u.studentt.cdf(-c.abs(this.tscore(e)),this.cols()-1)}}),u.extend({anovafscore:function(){var e,t,n,r,o,i,a,s=h.call(arguments);if(1===s.length){o=new Array(s[0].length);for(var l=0;l<s[0].length;l++)o[l]=s[0][l];s=o}if(2===s.length)return u.variance(s[0])/u.variance(s[1]);for(t=new Array,l=0;l<s.length;l++)t=t.concat(s[l]);for(n=u.mean(t),l=e=0;l<s.length;l++)e+=s[l].length*c.pow(u.mean(s[l])-n,2);for(e/=s.length-1,l=i=0;l<s.length;l++)for(r=u.mean(s[l]),a=0;a<s[l].length;a++)i+=c.pow(s[l][a]-r,2);return e/(i/=t.length-s.length)},anovaftest:function(){var e,t,n,r=h.call(arguments);if(a(r[0]))return 1-u.centralF.cdf(r[0],r[1],r[2]);anovafscore=u.anovafscore(r),e=r.length-1;for(var o=n=0;o<r.length;o++)n+=r[o].length;return t=n-e-1,1-u.centralF.cdf(anovafscore,e,t)},ftest:function(e,t,n){return 1-u.centralF.cdf(e,t,n)}}),u.extend(u.fn,{anovafscore:function(){return u.anovafscore(this.toArray())},anovaftes:function(){for(var e=0,t=0;t<this.length;t++)e+=this[t].length;return u.ftest(this.anovafscore(),this.length-1,e-this.length)}}),u.extend({qscore:function(){var e,t,n,r,o,i=h.call(arguments);return o=a(i[0])?(e=i[0],t=i[1],n=i[2],r=i[3],i[4]):(e=u.mean(i[0]),t=u.mean(i[1]),n=i[0].length,r=i[1].length,i[2]),c.abs(e-t)/(o*c.sqrt((1/n+1/r)/2))},qtest:function(){var e,t=h.call(arguments),n=(t=3===t.length?(e=t[0],t.slice(1)):7===t.length?(e=u.qscore(t[0],t[1],t[2],t[3],t[4]),t.slice(5)):(e=u.qscore(t[0],t[1],t[2]),t.slice(3)))[0],r=t[1];return 1-u.tukey.cdf(e,r,n-r)},tukeyhsd:function(e){for(var t=u.pooledstdev(e),n=e.map(function(e){return u.mean(e)}),r=e.reduce(function(e,t){return e+t.length},0),o=[],i=0;i<e.length;++i)for(var a=i+1;a<e.length;++a){var s=u.qtest(n[i],n[a],e[i].length,e[a].length,t,r,e.length);o.push([[i,a],s])}return o}}),u.extend({normalci:function(){var e,t=h.call(arguments),n=new Array(2);return e=4===t.length?c.abs(u.normal.inv(t[1]/2,0,1)*t[2]/c.sqrt(t[3])):c.abs(u.normal.inv(t[1]/2,0,1)*u.stdev(t[2])/c.sqrt(t[2].length)),n[0]=t[0]-e,n[1]=t[0]+e,n},tci:function(){var e,t=h.call(arguments),n=new Array(2);return e=4===t.length?c.abs(u.studentt.inv(t[1]/2,t[3]-1)*t[2]/c.sqrt(t[3])):c.abs(u.studentt.inv(t[1]/2,t[2].length-1)*u.stdev(t[2],!0)/c.sqrt(t[2].length)),n[0]=t[0]-e,n[1]=t[0]+e,n},significant:function(e,t){return e<t}}),u.extend(u.fn,{normalci:function(e,t){return u.normalci(e,t,this.toArray())},tci:function(e,t){return u.tci(e,t,this.toArray())}}),u.extend(u.fn,{oneSidedDifferenceOfProportions:function(e,t,n,r){var o=i(e,t,n,r);return u.ztest(o,1)},twoSidedDifferenceOfProportions:function(e,t,n,r){var o=i(e,t,n,r);return u.ztest(o,2)}})}(d,Math),d.models=function(){function l(e,t){var n=e.length,r=t[0].length-1,o=n-r-1,i=d.lstsq(t,e),a=d.multiply(t,i.map(function(e){return[e]})).map(function(e){return e[0]}),s=d.subtract(e,a),l=d.mean(e),u=d.sum(a.map(function(e){return Math.pow(e-l,2)})),c=d.sum(e.map(function(e,t){return Math.pow(e-a[t],2)})),h=u+c;return{exog:t,endog:e,nobs:n,df_model:r,df_resid:o,coef:i,predict:a,resid:s,ybar:l,SST:h,SSE:u,SSR:c,R2:u/h}}function a(n){var e=function(n){var r=n[0].length;return d.arange(r).map(function(t){var e=d.arange(r).filter(function(e){return e!==t});return l(d.col(n,t).map(function(e){return e[0]}),d.col(n,e))})}(n.exog),r=Math.sqrt(n.SSR/n.df_resid),o=e.map(function(e){var t=e.SST,n=e.R2;return r/Math.sqrt(t*(1-n))}),t=n.coef.map(function(e,t){return(e-0)/o[t]}),i=t.map(function(e){var t=d.studentt.cdf(e,n.df_resid);return 2*(.5<t?1-t:t)}),a=d.studentt.inv(.975,n.df_resid),s=n.coef.map(function(e,t){var n=a*o[t];return[e-n,e+n]});return{se:o,t:t,p:i,sigmaHat:r,interval95:s}}return{ols:function(e,t){var n=l(e,t),r=a(n),o=function(e){var t,n,r,o=e.R2/e.df_model/((1-e.R2)/e.df_resid);return{F_statistic:o,pvalue:1-(t=o,n=e.df_model,r=e.df_resid,d.beta.cdf(t/(r/n+t),n/2,r/2))}}(n),i=1-(1-n.R2)*((n.nobs-1)/n.df_resid);return n.t=r,n.f=o,n.adjust_R2=i,n}}}(),d.jStat=d)},function(e,t,n){var r=n(1),l=n(0);t.UNIQUE=function(){for(var e=[],t=0;t<arguments.length;++t){for(var n=!1,r=arguments[t],o=0;o<e.length&&!(n=e[o]===r);++o);n||e.push(r)}return e},t.FLATTEN=r.flatten,t.ARGS2ARRAY=function(){return Array.prototype.slice.call(arguments,0)},t.REFERENCE=function(e,t){if(!arguments.length)return l.error;try{for(var n=t.split("."),r=e,o=0;o<n.length;++o){var i=n[o];if("]"===i[i.length-1]){var a=i.indexOf("["),s=i.substring(a+1,i.length-1);r=r[i.substring(0,a)][s]}else r=r[i]}return r}catch(e){}},t.JOIN=function(e,t){return e.join(t)},t.NUMBERS=function(){return r.flatten(arguments).filter(function(e){return"number"==typeof e})}},function(e,c,t){var C=t(0),n=t(9).jStat,i=t(6),E=t(1),r=t(25);function o(e){return/^[01]{1,10}$/.test(e)}c.BESSELI=function(e,t){return e=E.parseNumber(e),t=E.parseNumber(t),E.anyIsError(e,t)?C.value:r.besseli(e,t)},c.BESSELJ=function(e,t){return e=E.parseNumber(e),t=E.parseNumber(t),E.anyIsError(e,t)?C.value:r.besselj(e,t)},c.BESSELK=function(e,t){return e=E.parseNumber(e),t=E.parseNumber(t),E.anyIsError(e,t)?C.value:r.besselk(e,t)},c.BESSELY=function(e,t){return e=E.parseNumber(e),t=E.parseNumber(t),E.anyIsError(e,t)?C.value:r.bessely(e,t)},c.BIN2DEC=function(e){if(!o(e))return C.num;var t=parseInt(e,2),n=e.toString();return 10===n.length&&"1"===n.substring(0,1)?parseInt(n.substring(1),2)-512:t},c.BIN2HEX=function(e,t){if(!o(e))return C.num;var n=e.toString();if(10===n.length&&"1"===n.substring(0,1))return(0xfffffffe00+parseInt(n.substring(1),2)).toString(16);var r=parseInt(e,2).toString(16);return void 0===t?r:isNaN(t)?C.value:t<0?C.num:(t=Math.floor(t))>=r.length?i.REPT("0",t-r.length)+r:C.num},c.BIN2OCT=function(e,t){if(!o(e))return C.num;var n=e.toString();if(10===n.length&&"1"===n.substring(0,1))return(1073741312+parseInt(n.substring(1),2)).toString(8);var r=parseInt(e,2).toString(8);return void 0===t?r:isNaN(t)?C.value:t<0?C.num:(t=Math.floor(t))>=r.length?i.REPT("0",t-r.length)+r:C.num},c.BITAND=function(e,t){return e=E.parseNumber(e),t=E.parseNumber(t),E.anyIsError(e,t)?C.value:e<0||t<0?C.num:Math.floor(e)!==e||Math.floor(t)!==t?C.num:0xffffffffffff<e||0xffffffffffff<t?C.num:e&t},c.BITLSHIFT=function(e,t){return e=E.parseNumber(e),t=E.parseNumber(t),E.anyIsError(e,t)?C.value:e<0?C.num:Math.floor(e)!==e?C.num:0xffffffffffff<e?C.num:53<Math.abs(t)?C.num:0<=t?e<<t:e>>-t},c.BITOR=function(e,t){return e=E.parseNumber(e),t=E.parseNumber(t),E.anyIsError(e,t)?C.value:e<0||t<0?C.num:Math.floor(e)!==e||Math.floor(t)!==t?C.num:0xffffffffffff<e||0xffffffffffff<t?C.num:e|t},c.BITRSHIFT=function(e,t){return e=E.parseNumber(e),t=E.parseNumber(t),E.anyIsError(e,t)?C.value:e<0?C.num:Math.floor(e)!==e?C.num:0xffffffffffff<e?C.num:53<Math.abs(t)?C.num:0<=t?e>>t:e<<-t},c.BITXOR=function(e,t){return e=E.parseNumber(e),t=E.parseNumber(t),E.anyIsError(e,t)?C.value:e<0||t<0?C.num:Math.floor(e)!==e||Math.floor(t)!==t?C.num:0xffffffffffff<e||0xffffffffffff<t?C.num:e^t},c.COMPLEX=function(e,t,n){if(e=E.parseNumber(e),t=E.parseNumber(t),E.anyIsError(e,t))return e;if("i"!==(n=void 0===n?"i":n)&&"j"!==n)return C.value;if(0===e&&0===t)return 0;if(0===e)return 1===t?n:t.toString()+n;if(0===t)return e.toString();var r=0<t?"+":"";return e.toString()+r+(1===t?n:t.toString()+n)},c.CONVERT=function(e,t,n){if((e=E.parseNumber(e))instanceof Error)return e;for(var r,o=[["a.u. of action","?",null,"action",!1,!1,105457168181818e-48],["a.u. of charge","e",null,"electric_charge",!1,!1,160217653141414e-33],["a.u. of energy","Eh",null,"energy",!1,!1,435974417757576e-32],["a.u. of length","a?",null,"length",!1,!1,529177210818182e-25],["a.u. of mass","m?",null,"mass",!1,!1,910938261616162e-45],["a.u. of time","?/Eh",null,"time",!1,!1,241888432650516e-31],["admiralty knot","admkn",null,"speed",!1,!0,.514773333],["ampere","A",null,"electric_current",!0,!1,1],["ampere per meter","A/m",null,"magnetic_field_intensity",!0,!1,1],["ångström","Å",["ang"],"length",!1,!0,1e-10],["are","ar",null,"area",!1,!0,100],["astronomical unit","ua",null,"length",!1,!1,149597870691667e-25],["bar","bar",null,"pressure",!1,!1,1e5],["barn","b",null,"area",!1,!1,1e-28],["becquerel","Bq",null,"radioactivity",!0,!1,1],["bit","bit",["b"],"information",!1,!0,1],["btu","BTU",["btu"],"energy",!1,!0,1055.05585262],["byte","byte",null,"information",!1,!0,8],["candela","cd",null,"luminous_intensity",!0,!1,1],["candela per square metre","cd/m?",null,"luminance",!0,!1,1],["coulomb","C",null,"electric_charge",!0,!1,1],["cubic ångström","ang3",["ang^3"],"volume",!1,!0,1e-30],["cubic foot","ft3",["ft^3"],"volume",!1,!0,.028316846592],["cubic inch","in3",["in^3"],"volume",!1,!0,16387064e-12],["cubic light-year","ly3",["ly^3"],"volume",!1,!0,846786664623715e-61],["cubic metre","m?",null,"volume",!0,!0,1],["cubic mile","mi3",["mi^3"],"volume",!1,!0,4168181825.44058],["cubic nautical mile","Nmi3",["Nmi^3"],"volume",!1,!0,6352182208],["cubic Pica","Pica3",["Picapt3","Pica^3","Picapt^3"],"volume",!1,!0,7.58660370370369e-8],["cubic yard","yd3",["yd^3"],"volume",!1,!0,.764554857984],["cup","cup",null,"volume",!1,!0,.0002365882365],["dalton","Da",["u"],"mass",!1,!1,166053886282828e-41],["day","d",["day"],"time",!1,!0,86400],["degree","°",null,"angle",!1,!1,.0174532925199433],["degrees Rankine","Rank",null,"temperature",!1,!0,.555555555555556],["dyne","dyn",["dy"],"force",!1,!0,1e-5],["electronvolt","eV",["ev"],"energy",!1,!0,1.60217656514141],["ell","ell",null,"length",!1,!0,1.143],["erg","erg",["e"],"energy",!1,!0,1e-7],["farad","F",null,"electric_capacitance",!0,!1,1],["fluid ounce","oz",null,"volume",!1,!0,295735295625e-16],["foot","ft",null,"length",!1,!0,.3048],["foot-pound","flb",null,"energy",!1,!0,1.3558179483314],["gal","Gal",null,"acceleration",!1,!1,.01],["gallon","gal",null,"volume",!1,!0,.003785411784],["gauss","G",["ga"],"magnetic_flux_density",!1,!0,1],["grain","grain",null,"mass",!1,!0,647989e-10],["gram","g",null,"mass",!1,!0,.001],["gray","Gy",null,"absorbed_dose",!0,!1,1],["gross registered ton","GRT",["regton"],"volume",!1,!0,2.8316846592],["hectare","ha",null,"area",!1,!0,1e4],["henry","H",null,"inductance",!0,!1,1],["hertz","Hz",null,"frequency",!0,!1,1],["horsepower","HP",["h"],"power",!1,!0,745.69987158227],["horsepower-hour","HPh",["hh","hph"],"energy",!1,!0,2684519.538],["hour","h",["hr"],"time",!1,!0,3600],["imperial gallon (U.K.)","uk_gal",null,"volume",!1,!0,.00454609],["imperial hundredweight","lcwt",["uk_cwt","hweight"],"mass",!1,!0,50.802345],["imperial quart (U.K)","uk_qt",null,"volume",!1,!0,.0011365225],["imperial ton","brton",["uk_ton","LTON"],"mass",!1,!0,1016.046909],["inch","in",null,"length",!1,!0,.0254],["international acre","uk_acre",null,"area",!1,!0,4046.8564224],["IT calorie","cal",null,"energy",!1,!0,4.1868],["joule","J",null,"energy",!0,!0,1],["katal","kat",null,"catalytic_activity",!0,!1,1],["kelvin","K",["kel"],"temperature",!0,!0,1],["kilogram","kg",null,"mass",!0,!0,1],["knot","kn",null,"speed",!1,!0,.514444444444444],["light-year","ly",null,"length",!1,!0,9460730472580800],["litre","L",["l","lt"],"volume",!1,!0,.001],["lumen","lm",null,"luminous_flux",!0,!1,1],["lux","lx",null,"illuminance",!0,!1,1],["maxwell","Mx",null,"magnetic_flux",!1,!1,1e-18],["measurement ton","MTON",null,"volume",!1,!0,1.13267386368],["meter per hour","m/h",["m/hr"],"speed",!1,!0,.00027777777777778],["meter per second","m/s",["m/sec"],"speed",!0,!0,1],["meter per second squared","m?s??",null,"acceleration",!0,!1,1],["parsec","pc",["parsec"],"length",!1,!0,0x6da012f958ee1c],["meter squared per second","m?/s",null,"kinematic_viscosity",!0,!1,1],["metre","m",null,"length",!0,!0,1],["miles per hour","mph",null,"speed",!1,!0,.44704],["millimetre of mercury","mmHg",null,"pressure",!1,!1,133.322],["minute","?",null,"angle",!1,!1,.000290888208665722],["minute","min",["mn"],"time",!1,!0,60],["modern teaspoon","tspm",null,"volume",!1,!0,5e-6],["mole","mol",null,"amount_of_substance",!0,!1,1],["morgen","Morgen",null,"area",!1,!0,2500],["n.u. of action","?",null,"action",!1,!1,105457168181818e-48],["n.u. of mass","m?",null,"mass",!1,!1,910938261616162e-45],["n.u. of speed","c?",null,"speed",!1,!1,299792458],["n.u. of time","?/(me?c??)",null,"time",!1,!1,128808866778687e-35],["nautical mile","M",["Nmi"],"length",!1,!0,1852],["newton","N",null,"force",!0,!0,1],["œrsted","Oe ",null,"magnetic_field_intensity",!1,!1,79.5774715459477],["ohm","Ω",null,"electric_resistance",!0,!1,1],["ounce mass","ozm",null,"mass",!1,!0,.028349523125],["pascal","Pa",null,"pressure",!0,!1,1],["pascal second","Pa?s",null,"dynamic_viscosity",!0,!1,1],["pferdestärke","PS",null,"power",!1,!0,735.49875],["phot","ph",null,"illuminance",!1,!1,1e-4],["pica (1/6 inch)","pica",null,"length",!1,!0,.00035277777777778],["pica (1/72 inch)","Pica",["Picapt"],"length",!1,!0,.00423333333333333],["poise","P",null,"dynamic_viscosity",!1,!1,.1],["pond","pond",null,"force",!1,!0,.00980665],["pound force","lbf",null,"force",!1,!0,4.4482216152605],["pound mass","lbm",null,"mass",!1,!0,.45359237],["quart","qt",null,"volume",!1,!0,.000946352946],["radian","rad",null,"angle",!0,!1,1],["second","?",null,"angle",!1,!1,484813681109536e-20],["second","s",["sec"],"time",!0,!0,1],["short hundredweight","cwt",["shweight"],"mass",!1,!0,45.359237],["siemens","S",null,"electrical_conductance",!0,!1,1],["sievert","Sv",null,"equivalent_dose",!0,!1,1],["slug","sg",null,"mass",!1,!0,14.59390294],["square ångström","ang2",["ang^2"],"area",!1,!0,1e-20],["square foot","ft2",["ft^2"],"area",!1,!0,.09290304],["square inch","in2",["in^2"],"area",!1,!0,64516e-8],["square light-year","ly2",["ly^2"],"area",!1,!0,895054210748189e17],["square meter","m?",null,"area",!0,!0,1],["square mile","mi2",["mi^2"],"area",!1,!0,2589988.110336],["square nautical mile","Nmi2",["Nmi^2"],"area",!1,!0,3429904],["square Pica","Pica2",["Picapt2","Pica^2","Picapt^2"],"area",!1,!0,1792111111111e-17],["square yard","yd2",["yd^2"],"area",!1,!0,.83612736],["statute mile","mi",null,"length",!1,!0,1609.344],["steradian","sr",null,"solid_angle",!0,!1,1],["stilb","sb",null,"luminance",!1,!1,1e-4],["stokes","St",null,"kinematic_viscosity",!1,!1,1e-4],["stone","stone",null,"mass",!1,!0,6.35029318],["tablespoon","tbs",null,"volume",!1,!0,147868e-10],["teaspoon","tsp",null,"volume",!1,!0,492892e-11],["tesla","T",null,"magnetic_flux_density",!0,!0,1],["thermodynamic calorie","c",null,"energy",!1,!0,4.184],["ton","ton",null,"mass",!1,!0,907.18474],["tonne","t",null,"mass",!1,!1,1e3],["U.K. pint","uk_pt",null,"volume",!1,!0,.00056826125],["U.S. bushel","bushel",null,"volume",!1,!0,.03523907],["U.S. oil barrel","barrel",null,"volume",!1,!0,.158987295],["U.S. pint","pt",["us_pt"],"volume",!1,!0,.000473176473],["U.S. survey mile","survey_mi",null,"length",!1,!0,1609.347219],["U.S. survey/statute acre","us_acre",null,"area",!1,!0,4046.87261],["volt","V",null,"voltage",!0,!1,1],["watt","W",null,"power",!0,!0,1],["watt-hour","Wh",["wh"],"energy",!1,!0,3600],["weber","Wb",null,"magnetic_flux",!0,!1,1],["yard","yd",null,"length",!1,!0,.9144],["year","yr",null,"time",!1,!0,31557600]],i={Yi:["yobi",80,12089258196146292e8,"Yi","yotta"],Zi:["zebi",70,11805916207174113e5,"Zi","zetta"],Ei:["exbi",60,0x1000000000000000,"Ei","exa"],Pi:["pebi",50,0x4000000000000,"Pi","peta"],Ti:["tebi",40,1099511627776,"Ti","tera"],Gi:["gibi",30,1073741824,"Gi","giga"],Mi:["mebi",20,1048576,"Mi","mega"],ki:["kibi",10,1024,"ki","kilo"]},a={Y:["yotta",1e24,"Y"],Z:["zetta",1e21,"Z"],E:["exa",1e18,"E"],P:["peta",1e15,"P"],T:["tera",1e12,"T"],G:["giga",1e9,"G"],M:["mega",1e6,"M"],k:["kilo",1e3,"k"],h:["hecto",100,"h"],e:["dekao",10,"e"],d:["deci",.1,"d"],c:["centi",.01,"c"],m:["milli",.001,"m"],u:["micro",1e-6,"u"],n:["nano",1e-9,"n"],p:["pico",1e-12,"p"],f:["femto",1e-15,"f"],a:["atto",1e-18,"a"],z:["zepto",1e-21,"z"],y:["yocto",1e-24,"y"]},s=null,l=null,u=t,c=n,h=1,d=1,f=0;f<o.length;f++)r=null===o[f][2]?[]:o[f][2],(o[f][1]===u||0<=r.indexOf(u))&&(s=o[f]),(o[f][1]===c||0<=r.indexOf(c))&&(l=o[f]);if(null===s){var g=i[t.substring(0,2)],v=a[t.substring(0,1)];"da"===t.substring(0,2)&&(v=["dekao",10,"da"]),g?(h=g[2],u=t.substring(2)):v&&(h=v[1],u=t.substring(v[2].length));for(var p=0;p<o.length;p++)r=null===o[p][2]?[]:o[p][2],(o[p][1]===u||0<=r.indexOf(u))&&(s=o[p])}if(null===l){var m=i[n.substring(0,2)],y=a[n.substring(0,1)];"da"===n.substring(0,2)&&(y=["dekao",10,"da"]),m?(d=m[2],c=n.substring(2)):y&&(d=y[1],c=n.substring(y[2].length));for(var w=0;w<o.length;w++)r=null===o[w][2]?[]:o[w][2],(o[w][1]===c||0<=r.indexOf(c))&&(l=o[w])}return null===s||null===l?C.na:s[3]!==l[3]?C.na:e*s[6]*h/(l[6]*d)},c.DEC2BIN=function(e,t){if((e=E.parseNumber(e))instanceof Error)return e;if(!/^-?[0-9]{1,3}$/.test(e)||e<-512||511<e)return C.num;if(e<0)return"1"+i.REPT("0",9-(512+e).toString(2).length)+(512+e).toString(2);var n=parseInt(e,10).toString(2);return void 0===t?n:isNaN(t)?C.value:t<0?C.num:(t=Math.floor(t))>=n.length?i.REPT("0",t-n.length)+n:C.num},c.DEC2HEX=function(e,t){if((e=E.parseNumber(e))instanceof Error)return e;if(!/^-?[0-9]{1,12}$/.test(e)||e<-549755813888||549755813887<e)return C.num;if(e<0)return(1099511627776+e).toString(16);var n=parseInt(e,10).toString(16);return void 0===t?n:isNaN(t)?C.value:t<0?C.num:(t=Math.floor(t))>=n.length?i.REPT("0",t-n.length)+n:C.num},c.DEC2OCT=function(e,t){if((e=E.parseNumber(e))instanceof Error)return e;if(!/^-?[0-9]{1,9}$/.test(e)||e<-536870912||536870911<e)return C.num;if(e<0)return(1073741824+e).toString(8);var n=parseInt(e,10).toString(8);return void 0===t?n:isNaN(t)?C.value:t<0?C.num:(t=Math.floor(t))>=n.length?i.REPT("0",t-n.length)+n:C.num},c.DELTA=function(e,t){return t=void 0===t?0:t,e=E.parseNumber(e),t=E.parseNumber(t),E.anyIsError(e,t)?C.value:e===t?1:0},c.ERF=function(e,t){return t=void 0===t?0:t,e=E.parseNumber(e),t=E.parseNumber(t),E.anyIsError(e,t)?C.value:n.erf(e)},c.ERF.PRECISE=function(){throw new Error("ERF.PRECISE is not implemented")},c.ERFC=function(e){return isNaN(e)?C.value:n.erfc(e)},c.ERFC.PRECISE=function(){throw new Error("ERFC.PRECISE is not implemented")},c.GESTEP=function(e,t){return t=t||0,e=E.parseNumber(e),E.anyIsError(t,e)?e:t<=e?1:0},c.HEX2BIN=function(e,t){if(!/^[0-9A-Fa-f]{1,10}$/.test(e))return C.num;var n=10===e.length&&"f"===e.substring(0,1).toLowerCase(),r=n?parseInt(e,16)-1099511627776:parseInt(e,16);if(r<-512||511<r)return C.num;if(n)return"1"+i.REPT("0",9-(512+r).toString(2).length)+(512+r).toString(2);var o=r.toString(2);return void 0===t?o:isNaN(t)?C.value:t<0?C.num:(t=Math.floor(t))>=o.length?i.REPT("0",t-o.length)+o:C.num},c.HEX2DEC=function(e){if(!/^[0-9A-Fa-f]{1,10}$/.test(e))return C.num;var t=parseInt(e,16);return 549755813888<=t?t-1099511627776:t},c.HEX2OCT=function(e,t){if(!/^[0-9A-Fa-f]{1,10}$/.test(e))return C.num;var n=parseInt(e,16);if(536870911<n&&n<0xffe0000000)return C.num;if(0xffe0000000<=n)return(n-0xffc0000000).toString(8);var r=n.toString(8);return void 0===t?r:isNaN(t)?C.value:t<0?C.num:(t=Math.floor(t))>=r.length?i.REPT("0",t-r.length)+r:C.num},c.IMABS=function(e){var t=c.IMREAL(e),n=c.IMAGINARY(e);return E.anyIsError(t,n)?C.value:Math.sqrt(Math.pow(t,2)+Math.pow(n,2))},c.IMAGINARY=function(e){if(void 0===e||!0===e||!1===e)return C.value;if(0===e||"0"===e)return 0;if(0<=["i","j"].indexOf(e))return 1;var t=(e=e.replace("+i","+1i").replace("-i","-1i").replace("+j","+1j").replace("-j","-1j")).indexOf("+"),n=e.indexOf("-");0===t&&(t=e.indexOf("+",1)),0===n&&(n=e.indexOf("-",1));var r=e.substring(e.length-1,e.length),o="i"===r||"j"===r;return 0<=t||0<=n?o?0<=t?isNaN(e.substring(0,t))||isNaN(e.substring(t+1,e.length-1))?C.num:Number(e.substring(t+1,e.length-1)):isNaN(e.substring(0,n))||isNaN(e.substring(n+1,e.length-1))?C.num:-Number(e.substring(n+1,e.length-1)):C.num:o?isNaN(e.substring(0,e.length-1))?C.num:e.substring(0,e.length-1):isNaN(e)?C.num:0},c.IMARGUMENT=function(e){var t=c.IMREAL(e),n=c.IMAGINARY(e);return E.anyIsError(t,n)?C.value:0===t&&0===n?C.div0:0===t&&0<n?Math.PI/2:0===t&&n<0?-Math.PI/2:0===n&&0<t?0:0===n&&t<0?-Math.PI:0<t?Math.atan(n/t):t<0&&0<=n?Math.atan(n/t)+Math.PI:Math.atan(n/t)-Math.PI},c.IMCONJUGATE=function(e){var t=c.IMREAL(e),n=c.IMAGINARY(e);if(E.anyIsError(t,n))return C.value;var r=e.substring(e.length-1);return r="i"===r||"j"===r?r:"i",0!==n?c.COMPLEX(t,-n,r):e},c.IMCOS=function(e){var t=c.IMREAL(e),n=c.IMAGINARY(e);if(E.anyIsError(t,n))return C.value;var r=e.substring(e.length-1);return r="i"===r||"j"===r?r:"i",c.COMPLEX(Math.cos(t)*(Math.exp(n)+Math.exp(-n))/2,-Math.sin(t)*(Math.exp(n)-Math.exp(-n))/2,r)},c.IMCOSH=function(e){var t=c.IMREAL(e),n=c.IMAGINARY(e);if(E.anyIsError(t,n))return C.value;var r=e.substring(e.length-1);return r="i"===r||"j"===r?r:"i",c.COMPLEX(Math.cos(n)*(Math.exp(t)+Math.exp(-t))/2,Math.sin(n)*(Math.exp(t)-Math.exp(-t))/2,r)},c.IMCOT=function(e){var t=c.IMREAL(e),n=c.IMAGINARY(e);return E.anyIsError(t,n)?C.value:c.IMDIV(c.IMCOS(e),c.IMSIN(e))},c.IMDIV=function(e,t){var n=c.IMREAL(e),r=c.IMAGINARY(e),o=c.IMREAL(t),i=c.IMAGINARY(t);if(E.anyIsError(n,r,o,i))return C.value;var a=e.substring(e.length-1),s=t.substring(t.length-1),l="i";if("j"===a?l="j":"j"===s&&(l="j"),0===o&&0===i)return C.num;var u=o*o+i*i;return c.COMPLEX((n*o+r*i)/u,(r*o-n*i)/u,l)},c.IMEXP=function(e){var t=c.IMREAL(e),n=c.IMAGINARY(e);if(E.anyIsError(t,n))return C.value;var r=e.substring(e.length-1);r="i"===r||"j"===r?r:"i";var o=Math.exp(t);return c.COMPLEX(o*Math.cos(n),o*Math.sin(n),r)},c.IMLN=function(e){var t=c.IMREAL(e),n=c.IMAGINARY(e);if(E.anyIsError(t,n))return C.value;var r=e.substring(e.length-1);return r="i"===r||"j"===r?r:"i",c.COMPLEX(Math.log(Math.sqrt(t*t+n*n)),Math.atan(n/t),r)},c.IMLOG10=function(e){var t=c.IMREAL(e),n=c.IMAGINARY(e);if(E.anyIsError(t,n))return C.value;var r=e.substring(e.length-1);return r="i"===r||"j"===r?r:"i",c.COMPLEX(Math.log(Math.sqrt(t*t+n*n))/Math.log(10),Math.atan(n/t)/Math.log(10),r)},c.IMLOG2=function(e){var t=c.IMREAL(e),n=c.IMAGINARY(e);if(E.anyIsError(t,n))return C.value;var r=e.substring(e.length-1);return r="i"===r||"j"===r?r:"i",c.COMPLEX(Math.log(Math.sqrt(t*t+n*n))/Math.log(2),Math.atan(n/t)/Math.log(2),r)},c.IMPOWER=function(e,t){t=E.parseNumber(t);var n=c.IMREAL(e),r=c.IMAGINARY(e);if(E.anyIsError(t,n,r))return C.value;var o=e.substring(e.length-1);o="i"===o||"j"===o?o:"i";var i=Math.pow(c.IMABS(e),t),a=c.IMARGUMENT(e);return c.COMPLEX(i*Math.cos(t*a),i*Math.sin(t*a),o)},c.IMPRODUCT=function(){var e=arguments[0];if(!arguments.length)return C.value;for(var t=1;t<arguments.length;t++){var n=c.IMREAL(e),r=c.IMAGINARY(e),o=c.IMREAL(arguments[t]),i=c.IMAGINARY(arguments[t]);if(E.anyIsError(n,r,o,i))return C.value;e=c.COMPLEX(n*o-r*i,n*i+r*o)}return e},c.IMREAL=function(e){if(void 0===e||!0===e||!1===e)return C.value;if(0===e||"0"===e)return 0;if(0<=["i","+i","1i","+1i","-i","-1i","j","+j","1j","+1j","-j","-1j"].indexOf(e))return 0;var t=e.indexOf("+"),n=e.indexOf("-");0===t&&(t=e.indexOf("+",1)),0===n&&(n=e.indexOf("-",1));var r=e.substring(e.length-1,e.length),o="i"===r||"j"===r;return 0<=t||0<=n?o?0<=t?isNaN(e.substring(0,t))||isNaN(e.substring(t+1,e.length-1))?C.num:Number(e.substring(0,t)):isNaN(e.substring(0,n))||isNaN(e.substring(n+1,e.length-1))?C.num:Number(e.substring(0,n)):C.num:o?isNaN(e.substring(0,e.length-1))?C.num:0:isNaN(e)?C.num:e},c.IMSEC=function(e){if(!0===e||!1===e)return C.value;var t=c.IMREAL(e),n=c.IMAGINARY(e);return E.anyIsError(t,n)?C.value:c.IMDIV("1",c.IMCOS(e))},c.IMSECH=function(e){var t=c.IMREAL(e),n=c.IMAGINARY(e);return E.anyIsError(t,n)?C.value:c.IMDIV("1",c.IMCOSH(e))},c.IMSIN=function(e){var t=c.IMREAL(e),n=c.IMAGINARY(e);if(E.anyIsError(t,n))return C.value;var r=e.substring(e.length-1);return r="i"===r||"j"===r?r:"i",c.COMPLEX(Math.sin(t)*(Math.exp(n)+Math.exp(-n))/2,Math.cos(t)*(Math.exp(n)-Math.exp(-n))/2,r)},c.IMSINH=function(e){var t=c.IMREAL(e),n=c.IMAGINARY(e);if(E.anyIsError(t,n))return C.value;var r=e.substring(e.length-1);return r="i"===r||"j"===r?r:"i",c.COMPLEX(Math.cos(n)*(Math.exp(t)-Math.exp(-t))/2,Math.sin(n)*(Math.exp(t)+Math.exp(-t))/2,r)},c.IMSQRT=function(e){var t=c.IMREAL(e),n=c.IMAGINARY(e);if(E.anyIsError(t,n))return C.value;var r=e.substring(e.length-1);r="i"===r||"j"===r?r:"i";var o=Math.sqrt(c.IMABS(e)),i=c.IMARGUMENT(e);return c.COMPLEX(o*Math.cos(i/2),o*Math.sin(i/2),r)},c.IMCSC=function(e){if(!0===e||!1===e)return C.value;var t=c.IMREAL(e),n=c.IMAGINARY(e);return E.anyIsError(t,n)?C.num:c.IMDIV("1",c.IMSIN(e))},c.IMCSCH=function(e){if(!0===e||!1===e)return C.value;var t=c.IMREAL(e),n=c.IMAGINARY(e);return E.anyIsError(t,n)?C.num:c.IMDIV("1",c.IMSINH(e))},c.IMSUB=function(e,t){var n=this.IMREAL(e),r=this.IMAGINARY(e),o=this.IMREAL(t),i=this.IMAGINARY(t);if(E.anyIsError(n,r,o,i))return C.value;var a=e.substring(e.length-1),s=t.substring(t.length-1),l="i";return"j"===a?l="j":"j"===s&&(l="j"),this.COMPLEX(n-o,r-i,l)},c.IMSUM=function(){if(!arguments.length)return C.value;for(var e=E.flatten(arguments),t=e[0],n=1;n<e.length;n++){var r=this.IMREAL(t),o=this.IMAGINARY(t),i=this.IMREAL(e[n]),a=this.IMAGINARY(e[n]);if(E.anyIsError(r,o,i,a))return C.value;t=this.COMPLEX(r+i,o+a)}return t},c.IMTAN=function(e){if(!0===e||!1===e)return C.value;var t=c.IMREAL(e),n=c.IMAGINARY(e);return E.anyIsError(t,n)?C.value:this.IMDIV(this.IMSIN(e),this.IMCOS(e))},c.OCT2BIN=function(e,t){if(!/^[0-7]{1,10}$/.test(e))return C.num;var n=10===e.length&&"7"===e.substring(0,1),r=n?parseInt(e,8)-1073741824:parseInt(e,8);if(r<-512||511<r)return C.num;if(n)return"1"+i.REPT("0",9-(512+r).toString(2).length)+(512+r).toString(2);var o=r.toString(2);return void 0===t?o:isNaN(t)?C.value:t<0?C.num:(t=Math.floor(t))>=o.length?i.REPT("0",t-o.length)+o:C.num},c.OCT2DEC=function(e){if(!/^[0-7]{1,10}$/.test(e))return C.num;var t=parseInt(e,8);return 536870912<=t?t-1073741824:t},c.OCT2HEX=function(e,t){if(!/^[0-7]{1,10}$/.test(e))return C.num;var n=parseInt(e,8);if(536870912<=n)return"ff"+(n+3221225472).toString(16);var r=n.toString(16);return void 0===t?r:isNaN(t)?C.value:t<0?C.num:(t=Math.floor(t))>=r.length?i.REPT("0",t-r.length)+r:C.num}},function(e,t,n){"use strict";t.__esModule=!0;t.default=["ABS","ACCRINT","ACOS","ACOSH","ACOT","ACOTH","ADD","AGGREGATE","AND","ARABIC","ARGS2ARRAY","ASIN","ASINH","ATAN","ATAN2","ATANH","AVEDEV","AVERAGE","AVERAGEA","AVERAGEIF","AVERAGEIFS","BASE","BESSELI","BESSELJ","BESSELK","BESSELY","BETA.DIST","BETA.INV","BETADIST","BETAINV","BIN2DEC","BIN2HEX","BIN2OCT","BINOM.DIST","BINOM.DIST.RANGE","BINOM.INV","BINOMDIST","BITAND","BITLSHIFT","BITOR","BITRSHIFT","BITXOR","CEILING","CEILINGMATH","CEILINGPRECISE","CHAR","CHISQ.DIST","CHISQ.DIST.RT","CHISQ.INV","CHISQ.INV.RT","CHOOSE","CHOOSE","CLEAN","CODE","COLUMN","COLUMNS","COMBIN","COMBINA","COMPLEX","CONCATENATE","CONFIDENCE","CONFIDENCE.NORM","CONFIDENCE.T","CONVERT","CORREL","COS","COSH","COT","COTH","COUNT","COUNTA","COUNTBLANK","COUNTIF","COUNTIFS","COUNTIN","COUNTUNIQUE","COVARIANCE.P","COVARIANCE.S","CSC","CSCH","CUMIPMT","CUMPRINC","DATE","DATEVALUE","DAY","DAYS","DAYS360","DB","DDB","DEC2BIN","DEC2HEX","DEC2OCT","DECIMAL","DEGREES","DELTA","DEVSQ","DIVIDE","DOLLARDE","DOLLARFR","E","EDATE","EFFECT","EOMONTH","EQ","ERF","ERFC","EVEN","EXACT","EXP","EXPON.DIST","EXPONDIST","F.DIST","F.DIST.RT","F.INV","F.INV.RT","FACT","FACTDOUBLE","FALSE","FDIST","FDISTRT","FIND","FINV","FINVRT","FISHER","FISHERINV","FLATTEN","FLOOR","FORECAST","FREQUENCY","FV","FVSCHEDULE","GAMMA","GAMMA.DIST","GAMMA.INV","GAMMADIST","GAMMAINV","GAMMALN","GAMMALN.PRECISE","GAUSS","GCD","GEOMEAN","GESTEP","GROWTH","GTE","HARMEAN","HEX2BIN","HEX2DEC","HEX2OCT","HOUR","HTML2TEXT","HYPGEOM.DIST","HYPGEOMDIST","IF","IMABS","IMAGINARY","IMARGUMENT","IMCONJUGATE","IMCOS","IMCOSH","IMCOT","IMCSC","IMCSCH","IMDIV","IMEXP","IMLN","IMLOG10","IMLOG2","IMPOWER","IMPRODUCT","IMREAL","IMSEC","IMSECH","IMSIN","IMSINH","IMSQRT","IMSUB","IMSUM","IMTAN","INT","INTERCEPT","INTERVAL","IPMT","IRR","ISBINARY","ISBLANK","ISEVEN","ISLOGICAL","ISNONTEXT","ISNUMBER","ISODD","ISODD","ISOWEEKNUM","ISPMT","ISTEXT","JOIN","KURT","LARGE","LCM","LEFT","LEN","LINEST","LN","LOG","LOG10","LOGEST","LOGNORM.DIST","LOGNORM.INV","LOGNORMDIST","LOGNORMINV","LOWER","LT","LTE","MATCH","MAX","MAXA","MEDIAN","MID","MIN","MINA","MINUS","MINUTE","MIRR","MOD","MODE.MULT","MODE.SNGL","MODEMULT","MODESNGL","MONTH","MROUND","MULTINOMIAL","MULTIPLY","NE","NEGBINOM.DIST","NEGBINOMDIST","NETWORKDAYS","NOMINAL","NORM.DIST","NORM.INV","NORM.S.DIST","NORM.S.INV","NORMDIST","NORMINV","NORMSDIST","NORMSINV","NOT","NOW","NPER","NPV","NUMBERS","OCT2BIN","OCT2DEC","OCT2HEX","ODD","OR","PDURATION","PEARSON","PERCENTILEEXC","PERCENTILEINC","PERCENTRANKEXC","PERCENTRANKINC","PERMUT","PERMUTATIONA","PHI","PI","PMT","POISSON.DIST","POISSONDIST","POW","POWER","PPMT","PROB","PRODUCT","PROPER","PV","QUARTILE.EXC","QUARTILE.INC","QUARTILEEXC","QUARTILEINC","QUOTIENT","RADIANS","RAND","RANDBETWEEN","RANK.AVG","RANK.EQ","RANKAVG","RANKEQ","RATE","REFERENCE","REGEXEXTRACT","REGEXMATCH","REGEXREPLACE","REPLACE","REPT","RIGHT","ROMAN","ROUND","ROUNDDOWN","ROUNDUP","ROW","ROWS","RRI","RSQ","SEARCH","SEC","SECH","SECOND","SERIESSUM","SIGN","SIN","SINH","SKEW","SKEW.P","SKEWP","SLN","SLOPE","SMALL","SPLIT","SPLIT","SQRT","SQRTPI","STANDARDIZE","STDEV.P","STDEV.S","STDEVA","STDEVP","STDEVPA","STDEVS","STEYX","SUBSTITUTE","SUBTOTAL","SUM","SUMIF","SUMIFS","SUMPRODUCT","SUMSQ","SUMX2MY2","SUMX2PY2","SUMXMY2","SWITCH","SYD","T","T.DIST","T.DIST.2T","T.DIST.RT","T.INV","T.INV.2T","TAN","TANH","TBILLEQ","TBILLPRICE","TBILLYIELD","TDIST","TDIST2T","TDISTRT","TIME","TIMEVALUE","TINV","TINV2T","TODAY","TRANSPOSE","TREND","TRIM","TRIMMEAN","TRUE","TRUNC","UNICHAR","UNICODE","UNIQUE","UPPER","VAR.P","VAR.S","VARA","VARP","VARPA","VARS","WEEKDAY","WEEKNUM","WEIBULL.DIST","WEIBULLDIST","WORKDAY","XIRR","XNPV","XOR","YEAR","YEARFRAC"]},function(e,t,n){"use strict";function a(e){var t=parseInt(e,10);return t=isNaN(t)?-1:Math.max(t-1,-1)}function r(e){var t="";return 0<=e&&(t=""+(e+1)),t}t.__esModule=!0,t.rowLabelToIndex=a,t.rowIndexToLabel=r,t.columnLabelToIndex=s,t.columnIndexToLabel=l,t.extractLabel=function(e){if("string"!=typeof e||!u.test(e))return[];var t=e.toUpperCase().match(u),n=t[1],r=t[2],o=t[3],i=t[4];return[{index:a(i),label:i,isAbsolute:"$"===o},{index:s(r),label:r,isAbsolute:"$"===n}]},t.toLabel=function(e,t){var n=(e.isAbsolute?"$":"")+r(e.index);return(t.isAbsolute?"$":"")+l(t.index)+n};var o="ABCDEFGHIJKLMNOPQRSTUVWXYZ",i=o.length;function s(e){var t=0;if("string"==typeof e)for(var n=0,r=(e=e.toUpperCase()).length-1;n<e.length;n+=1,r-=1)t+=Math.pow(i,r)*(o.indexOf(e[n])+1);return--t}function l(e){for(var t="";0<=e;)t=String.fromCharCode(e%i+97)+t,e=Math.floor(e/i)-1;return t.toUpperCase()}var u=/^([$])?([A-Za-z]+)([$])?([0-9]+)$/},function(e,t,n){"use strict";t.__esModule=!0,t.rowLabelToIndex=t.rowIndexToLabel=t.columnLabelToIndex=t.columnIndexToLabel=t.toLabel=t.extractLabel=t.error=t.Parser=t.ERROR_VALUE=t.ERROR_REF=t.ERROR_NUM=t.ERROR_NULL=t.ERROR_NOT_AVAILABLE=t.ERROR_NAME=t.ERROR_DIV_ZERO=t.ERROR=t.SUPPORTED_FORMULAS=void 0;var r=l(n(15)),o=l(n(12)),i=n(2),a=l(i),s=n(13);function l(e){return e&&e.__esModule?e:{default:e}}t.SUPPORTED_FORMULAS=o.default,t.ERROR=i.ERROR,t.ERROR_DIV_ZERO=i.ERROR_DIV_ZERO,t.ERROR_NAME=i.ERROR_NAME,t.ERROR_NOT_AVAILABLE=i.ERROR_NOT_AVAILABLE,t.ERROR_NULL=i.ERROR_NULL,t.ERROR_NUM=i.ERROR_NUM,t.ERROR_REF=i.ERROR_REF,t.ERROR_VALUE=i.ERROR_VALUE,t.Parser=r.default,t.error=a.default,t.extractLabel=s.extractLabel,t.toLabel=s.toLabel,t.columnIndexToLabel=s.columnIndexToLabel,t.columnLabelToIndex=s.columnLabelToIndex,t.rowIndexToLabel=s.rowIndexToLabel,t.rowLabelToIndex=s.rowLabelToIndex},function(e,t,n){"use strict";t.__esModule=!0;var r=c(n(16)),o=c(n(17)),i=n(38),a=n(41),s=n(3),l=n(2),u=c(l),h=n(13);function c(e){return e&&e.__esModule?e:{default:e}}var d=function(e){function t(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,e.call(this));return n.parser=new i.Parser,n.parser.yy={toNumber:s.toNumber,trimEdges:a.trimEdges,invertNumber:s.invertNumber,throwError:function(e){return n._throwError(e)},callVariable:function(e){return n._callVariable(e)},evaluateByOperator:o.default,callFunction:function(e,t){return n._callFunction(e,t)},cellValue:function(e){return n._callCellValue(e)},rangeValue:function(e,t){return n._callRangeValue(e,t)}},n.variables=Object.create(null),n.functions=Object.create(null),n.setVariable("TRUE",!0).setVariable("FALSE",!1).setVariable("NULL",null),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),t.prototype.parse=function(e){var t=null,n=null;try{t=""===e?"":this.parser.parse(e)}catch(e){var r=(0,u.default)(e.message);n=r||(0,u.default)(l.ERROR)}return t instanceof Error&&(n=(0,u.default)(t.message)||(0,u.default)(l.ERROR),t=null),{error:n,result:t}},t.prototype.setVariable=function(e,t){return this.variables[e]=t,this},t.prototype.getVariable=function(e){return this.variables[e]},t.prototype._callVariable=function(e){var t=this.getVariable(e);if(this.emit("callVariable",e,function(e){void 0!==e&&(t=e)}),void 0===t)throw Error(l.ERROR_NAME);return t},t.prototype.setFunction=function(e,t){return this.functions[e]=t,this},t.prototype.getFunction=function(e){return this.functions[e]},t.prototype._callFunction=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:[],n=this.getFunction(e),r=void 0;return n&&(r=n(t)),this.emit("callFunction",e,t,function(e){void 0!==e&&(r=e)}),void 0===r?(0,o.default)(e,t):r},t.prototype._callCellValue=function(e){e=e.toUpperCase();var t=(0,h.extractLabel)(e),n=t[0],r=t[1],o=void 0;return this.emit("callCellValue",{label:e,row:n,column:r},function(e){o=e}),o},t.prototype._callRangeValue=function(e,t){e=e.toUpperCase(),t=t.toUpperCase();var n=(0,h.extractLabel)(e),r=n[0],o=n[1],i=(0,h.extractLabel)(t),a=i[0],s=i[1],l={},u={};r.index<=a.index?(l.row=r,u.row=a):(l.row=a,u.row=r),o.index<=s.index?(l.column=o,u.column=s):(l.column=s,u.column=o),l.label=(0,h.toLabel)(l.row,l.column),u.label=(0,h.toLabel)(u.row,u.column);var c=[];return this.emit("callRangeValue",l,u,function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:[];c=e}),c},t.prototype._throwError=function(e){if((0,l.isValidStrict)(e))throw Error(e);throw Error(l.ERROR)},t}(r.default);t.default=d},function(e,t){function n(){}n.prototype={on:function(e,t,n){var r=this.e||(this.e={});return(r[e]||(r[e]=[])).push({fn:t,ctx:n}),this},once:function(e,t,n){var r=this;function o(){r.off(e,o),t.apply(n,arguments)}return o._=t,this.on(e,o,n)},emit:function(e){for(var t=[].slice.call(arguments,1),n=((this.e||(this.e={}))[e]||[]).slice(),r=0,o=n.length;r<o;r++)n[r].fn.apply(n[r].ctx,t);return this},off:function(e,t){var n=this.e||(this.e={}),r=n[e],o=[];if(r&&t)for(var i=0,a=r.length;i<a;i++)r[i].fn!==t&&r[i].fn._!==t&&o.push(r[i]);return o.length?n[e]=o:delete n[e],this}},e.exports=n},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:[];if(e=e.toUpperCase(),y[e])return y[e].apply(y,t);throw Error(p.ERROR_NAME)},t.registerOperation=w;var r=m(n(18)),o=m(n(19)),i=m(n(20)),a=m(n(21)),s=m(n(22)),l=m(n(30)),u=m(n(31)),c=m(n(32)),h=m(n(33)),d=m(n(34)),f=m(n(35)),g=m(n(36)),v=m(n(37)),p=n(2);function m(e){return e&&e.__esModule?e:{default:e}}var y=Object.create(null);function w(e,t){Array.isArray(e)||(e=[e.toUpperCase()]),e.forEach(function(e){t.isFactory?y[e]=t(e):y[e]=t})}w(r.default.SYMBOL,r.default),w(o.default.SYMBOL,o.default),w(i.default.SYMBOL,i.default),w(a.default.SYMBOL,a.default),w(v.default.SYMBOL,v.default),w(s.default.SYMBOL,s.default),w(l.default.SYMBOL,l.default),w(u.default.SYMBOL,u.default),w(c.default.SYMBOL,c.default),w(h.default.SYMBOL,h.default),w(f.default.SYMBOL,f.default),w(g.default.SYMBOL,g.default),w(d.default.SYMBOL,d.default)},function(e,t,n){"use strict";t.__esModule=!0,t.SYMBOL=void 0,t.default=o;var i=n(3),a=n(2),r=t.SYMBOL="+";function o(e){for(var t=arguments.length,n=Array(1<t?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var o=n.reduce(function(e,t){return e+(0,i.toNumber)(t)},(0,i.toNumber)(e));if(isNaN(o))throw Error(a.ERROR_VALUE);return o}o.SYMBOL=r},function(e,t,n){"use strict";t.__esModule=!0,t.default=o;var r=t.SYMBOL="&";function o(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return t.reduce(function(e,t){return e+t.toString()},"")}o.SYMBOL=r},function(e,t,n){"use strict";t.__esModule=!0,t.SYMBOL=void 0,t.default=o;var i=n(3),a=n(2),r=t.SYMBOL="/";function o(e){for(var t=arguments.length,n=Array(1<t?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var o=n.reduce(function(e,t){return e/(0,i.toNumber)(t)},(0,i.toNumber)(e));if(o===1/0)throw Error(a.ERROR_DIV_ZERO);if(isNaN(o))throw Error(a.ERROR_VALUE);return o}o.SYMBOL=r},function(e,t,n){"use strict";t.__esModule=!0,t.default=o;var r=t.SYMBOL="=";function o(e,t){return e===t}o.SYMBOL=r},function(e,t,n){"use strict";t.__esModule=!0,t.SYMBOL=void 0,t.default=u;var r,s=function(e){{if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}}(n(23)),o=n(12),i=(r=o)&&r.__esModule?r:{default:r},l=n(2);var a=t.SYMBOL=i.default;function u(a){return function(){var e=(a=a.toUpperCase()).split("."),t=!1,n=void 0;if(1===e.length)s[e[0]]&&(t=!0,n=s[e[0]].apply(s,arguments));else{for(var r=e.length,o=0,i=s;o<r;)if(i=i[e[o]],o++,!i){i=null;break}i&&(t=!0,n=i.apply(void 0,arguments))}if(!t)throw Error(l.ERROR_NAME);return n}}u.isFactory=!0,u.SYMBOL=a},function(e,t,n){var r=[n(24),n(26),n(11),n(27),n(4),n(6),n(8),n(28),n(7),n(29),n(5),n(10)];for(var o in r){var i=r[o];for(var a in i)t[a]=t[a]||i[a]}},function(e,t,n){var r=n(4),o=n(5),i=n(11),a=n(8);function s(e,t){if(t)for(var n in t)e[n]=t[n];return e}t.BETADIST=o.BETA.DIST,t.BETAINV=o.BETA.INV,t.BINOMDIST=o.BINOM.DIST,t.CEILING=t.ISOCEILING=s(r.CEILING.MATH,r.CEILING),t.CEILINGMATH=r.CEILING.MATH,t.CEILINGPRECISE=r.CEILING.PRECISE,t.CHIDIST=o.CHISQ.DIST,t.CHIDISTRT=o.CHISQ.DIST.RT,t.CHIINV=o.CHISQ.INV,t.CHIINVRT=o.CHISQ.INV.RT,t.CHITEST=o.CHISQ.TEST,t.CONFIDENCE=s(o.CONFIDENCE.NORM,o.CONFIDENCE),t.COVAR=o.COVARIANCE.P,t.COVARIANCEP=o.COVARIANCE.P,t.COVARIANCES=o.COVARIANCE.S,t.CRITBINOM=o.BINOM.INV,t.EXPONDIST=o.EXPON.DIST,t.ERFCPRECISE=i.ERFC.PRECISE,t.ERFPRECISE=i.ERF.PRECISE,t.FDIST=o.F.DIST,t.FDISTRT=o.F.DIST.RT,t.FINVRT=o.F.INV.RT,t.FINV=o.F.INV,t.FLOOR=s(r.FLOOR.MATH,r.FLOOR),t.FLOORMATH=r.FLOOR.MATH,t.FLOORPRECISE=r.FLOOR.PRECISE,t.FTEST=o.F.TEST,t.GAMMADIST=o.GAMMA.DIST,t.GAMMAINV=o.GAMMA.INV,t.GAMMALNPRECISE=o.GAMMALN.PRECISE,t.HYPGEOMDIST=o.HYPGEOM.DIST,t.LOGINV=o.LOGNORM.INV,t.LOGNORMINV=o.LOGNORM.INV,t.LOGNORMDIST=o.LOGNORM.DIST,t.MODE=s(o.MODE.SNGL,o.MODE),t.MODEMULT=o.MODE.MULT,t.MODESNGL=o.MODE.SNGL,t.NEGBINOMDIST=o.NEGBINOM.DIST,t.NETWORKDAYSINTL=a.NETWORKDAYS.INTL,t.NORMDIST=o.NORM.DIST,t.NORMINV=o.NORM.INV,t.NORMSDIST=o.NORM.S.DIST,t.NORMSINV=o.NORM.S.INV,t.PERCENTILE=s(o.PERCENTILE.EXC,o.PERCENTILE),t.PERCENTILEEXC=o.PERCENTILE.EXC,t.PERCENTILEINC=o.PERCENTILE.INC,t.PERCENTRANK=s(o.PERCENTRANK.INC,o.PERCENTRANK),t.PERCENTRANKEXC=o.PERCENTRANK.EXC,t.PERCENTRANKINC=o.PERCENTRANK.INC,t.POISSON=s(o.POISSON.DIST,o.POISSON),t.POISSONDIST=o.POISSON.DIST,t.QUARTILE=s(o.QUARTILE.INC,o.QUARTILE),t.QUARTILEEXC=o.QUARTILE.EXC,t.QUARTILEINC=o.QUARTILE.INC,t.RANK=s(o.RANK.EQ,o.RANK),t.RANKAVG=o.RANK.AVG,t.RANKEQ=o.RANK.EQ,t.SKEWP=o.SKEW.P,t.STDEV=s(o.STDEV.S,o.STDEV),t.STDEVP=o.STDEV.P,t.STDEVS=o.STDEV.S,t.TDIST=o.T.DIST,t.TDISTRT=o.T.DIST.RT,t.TINV=o.T.INV,t.TTEST=o.T.TEST,t.VAR=s(o.VAR.S,o.VAR),t.VARP=o.VAR.P,t.VARS=o.VAR.S,t.WEIBULL=s(o.WEIBULL.DIST,o.WEIBULL),t.WEIBULLDIST=o.WEIBULL.DIST,t.WORKDAYINTL=a.WORKDAY.INTL,t.ZTEST=o.Z.TEST},function(e,t,n){var v=Math;function p(e,n){return e.reduce(function(e,t){return n*e+t},0)}function m(e,t,n,r,o){o||(o=-1);var i,a=2/e;if(0===t)return n;if(1===t)return r;for(var s=1;s!=t;++s)i=r*s*a+o*n,n=r,r=i;return r}function r(n,r,o,i,a){return function(e,t){if(0===t)return n(e);if(1===t)return r(e);if(t<0)throw o+": Order ("+t+") must be nonnegative";if(1==i&&0===e)throw o+": Undefined when x == 0";if(2==i&&e<=0)throw o+": Undefined when x <= 0";return m(e,t,n(e),r(e),a)}}var i,a,s,l,u,c,h,d,f,g,y,w,C,o,E,S,b,T=function(){var i=[57568490574,-13362590354,651619640.7,-11214424.18,77392.33017,-184.9052456].reverse(),a=[57568490411,1029532985,9494680.718,59272.64853,267.8532712,1].reverse(),s=[1,-.001098628627,2734510407e-14,-2073370639e-15,2.093887211e-7].reverse(),l=[-.01562499995,.0001430488765,-6911147651e-15,7.621095161e-7,-9.34935152e-8].reverse();function c(e){var t,n,r=e*e,o=v.abs(e)-.785398164;return v.abs(e)<8?(t=p(i,r))/(n=p(a,r)):(t=p(s,r=64/r),n=p(l,r),v.sqrt(.636619772/v.abs(e))*(v.cos(o)*t-v.sin(o)*n*8/v.abs(e)))}var u=[72362614232,-7895059235,242396853.1,-2972611.439,15704.4826,-30.16036606].reverse(),h=[144725228442,2300535178,18583304.74,99447.43394,376.9991397,1].reverse(),d=[1,.00183105,-3516396496e-14,2457520174e-15,-2.40337019e-7].reverse(),f=[.04687499995,-.0002002690873,8449199096e-15,-8.8228987e-7,1.05787412e-7].reverse();function g(e){var t,n,r,o=e*e,i=v.abs(e)-2.356194491;return Math.abs(e)<8?t=(n=e*p(u,o))/(r=p(h,o)):(n=p(d,o=64/o),r=p(f,o),t=v.sqrt(.636619772/v.abs(e))*(v.cos(i)*n-v.sin(i)*r*8/v.abs(e)),e<0&&(t=-t)),t}return function(e,t){if(0===(t=Math.round(t)))return c(v.abs(e));if(1===t)return g(v.abs(e));if(t<0)throw"BESSELJ: Order ("+t+") must be nonnegative";if(0===v.abs(e))return 0;var n,r,o,i,a,s,l,u=2/v.abs(e);if(v.abs(e)>t)n=m(e,t,c(v.abs(e)),g(v.abs(e)),-1);else{for(a=n=i=o=0,s=1,r=2*v.floor((t+v.floor(v.sqrt(40*t)))/2);0<r;r--)l=r*u*s-a,a=s,s=l,1e10<v.abs(s)&&(s*=1e-10,a*=1e-10,n*=1e-10,i*=1e-10),o&&(i+=s),o=!o,r==t&&(n=a);n/=i=2*i-s}return e<0&&t%2?-n:n}}(),R=(i=[-2957821389,7062834065,-512359803.6,10879881.29,-86327.92757,228.4622733].reverse(),a=[40076544269,745249964.8,7189466.438,47447.2647,226.1030244,1].reverse(),s=[1,-.001098628627,2734510407e-14,-2073370639e-15,2.093887211e-7].reverse(),l=[-.01562499995,.0001430488765,-6911147651e-15,7.621095161e-7,-9.34945152e-8].reverse(),u=.636619772,c=[-4900604943e3,127527439e4,-51534381390,734926455.1,-4237922.726,8511.937935].reverse(),h=[249958057e5,424441966400,3733650367,22459040.02,102042.605,354.9632885,1].reverse(),d=[1,.00183105,-3516396496e-14,2457520174e-15,-2.40337019e-7].reverse(),f=[.04687499995,-.0002002690873,8449199096e-15,-8.8228987e-7,1.05787412e-7].reverse(),r(function(e){var t,n,r=e*e,o=e-.785398164;return e<8?(t=p(i,r))/(n=p(a,r))+u*T(e,0)*v.log(e):(t=p(s,r=64/r),n=p(l,r),v.sqrt(u/e)*(v.sin(o)*t+v.cos(o)*n*8/e))},function(e){var t,n,r=e*e,o=e-2.356194491;return e<8?(t=e*p(c,r))/(n=p(h,r))+u*(T(e,1)*v.log(e)-1/e):(t=p(d,r=64/r),n=p(f,r),v.sqrt(u/e)*(v.sin(o)*t+v.cos(o)*n*8/e))},"BESSELY",1,-1)),_=(g=[1,3.5156229,3.0899424,1.2067492,.2659732,.0360768,.0045813].reverse(),y=[.39894228,.01328592,.00225319,-.00157565,.00916281,-.02057706,.02635537,-.01647633,.00392377].reverse(),w=[.5,.87890594,.51498869,.15084934,.02658733,.00301532,32411e-8].reverse(),C=[.39894228,-.03988024,-.00362018,.00163801,-.01031555,.02282967,-.02895312,.01787654,-.00420059].reverse(),function e(t,n){if(0===(n=Math.round(n)))return function(e){return e<=3.75?p(g,e*e/14.0625):v.exp(v.abs(e))/v.sqrt(v.abs(e))*p(y,3.75/v.abs(e))}(t);if(1==n)return function(e){return e<3.75?e*p(w,e*e/14.0625):(e<0?-1:1)*v.exp(v.abs(e))/v.sqrt(v.abs(e))*p(C,3.75/v.abs(e))}(t);if(n<0)throw"BESSELI Order ("+n+") must be nonnegative";if(0===v.abs(t))return 0;var r,o,i,a,s,l=2/v.abs(t);for(i=r=0,a=1,o=2*v.round((n+v.round(v.sqrt(40*n)))/2);0<o;o--)s=o*l*a+i,i=a,a=s,1e10<v.abs(a)&&(a*=1e-10,i*=1e-10,r*=1e-10),o==n&&(r=i);return r*=e(t,0)/a,t<0&&n%2?-r:r}),k=(o=[-.57721566,.4227842,.23069756,.0348859,.00262698,1075e-7,74e-7].reverse(),E=[1.25331414,-.07832358,.02189568,-.01062446,.00587872,-.0025154,53208e-8].reverse(),S=[1,.15443144,-.67278579,-.18156897,-.01919402,-.00110404,-4686e-8].reverse(),b=[1.25331414,.23498619,-.0365562,.01504268,-.00780353,.00325614,-68245e-8].reverse(),r(function(e){return e<=2?-v.log(e/2)*_(e,0)+p(o,e*e/4):v.exp(-e)/v.sqrt(e)*p(E,2/e)},function(e){return e<=2?v.log(e/2)*_(e,1)+1/e*p(S,e*e/4):v.exp(-e)/v.sqrt(e)*p(b,2/e)},"BESSELK",2,1));t.besselj=T,t.bessely=R,t.besseli=_,t.besselk=k},function(module,exports,__webpack_require__){var error=__webpack_require__(0),stats=__webpack_require__(5),maths=__webpack_require__(4),utils=__webpack_require__(1);function compact(e){var t=[];return utils.arrayEach(e,function(e){e&&t.push(e)}),t}function findResultIndex(database,criterias){for(var matches={},i=1;i<database[0].length;++i)matches[i]=!0;var maxCriteriaLength=criterias[0].length;for(i=1;i<criterias.length;++i)criterias[i].length>maxCriteriaLength&&(maxCriteriaLength=criterias[i].length);for(var k=1;k<database.length;++k)for(var l=1;l<database[k].length;++l){for(var currentCriteriaResult=!1,hasMatchingCriteria=!1,j=0;j<criterias.length;++j){var criteria=criterias[j];if(!(criteria.length<maxCriteriaLength)){var criteriaField=criteria[0];if(database[k][0]===criteriaField){hasMatchingCriteria=!0;for(var p=1;p<criteria.length;++p)currentCriteriaResult=currentCriteriaResult||eval(database[k][l]+criteria[p])}}}hasMatchingCriteria&&(matches[l]=matches[l]&&currentCriteriaResult)}for(var result=[],n=0;n<database[0].length;++n)matches[n]&&result.push(n-1);return result}exports.FINDFIELD=function(e,n){var r=null;return utils.arrayEach(e,function(e,t){if(e[0]===n)return r=t,!1}),null==r?error.value:r},exports.DAVERAGE=function(e,t,n){if(isNaN(t)&&"string"!=typeof t)return error.value;var r=findResultIndex(e,n),o=[];if("string"==typeof t){var i=exports.FINDFIELD(e,t);o=utils.rest(e[i])}else o=utils.rest(e[t]);var a=0;return utils.arrayEach(r,function(e){a+=o[e]}),0===r.length?error.div0:a/r.length},exports.DCOUNT=function(e,t,n){if(isNaN(t)&&"string"!=typeof t)return error.value;var r=findResultIndex(e,n),o=[];if("string"==typeof t){var i=exports.FINDFIELD(e,t);o=utils.rest(e[i])}else o=utils.rest(e[t]);var a=[];return utils.arrayEach(r,function(e){a.push(o[e])}),stats.COUNT(a)},exports.DCOUNTA=function(e,t,n){if(isNaN(t)&&"string"!=typeof t)return error.value;var r=findResultIndex(e,n),o=[];if("string"==typeof t){var i=exports.FINDFIELD(e,t);o=utils.rest(e[i])}else o=utils.rest(e[t]);var a=[];return utils.arrayEach(r,function(e){a.push(o[e])}),stats.COUNTA(a)},exports.DGET=function(e,t,n){if(isNaN(t)&&"string"!=typeof t)return error.value;var r=findResultIndex(e,n),o=[];if("string"==typeof t){var i=exports.FINDFIELD(e,t);o=utils.rest(e[i])}else o=utils.rest(e[t]);return 0===r.length?error.value:1<r.length?error.num:o[r[0]]},exports.DMAX=function(e,t,n){if(isNaN(t)&&"string"!=typeof t)return error.value;var r=findResultIndex(e,n),o=[];if("string"==typeof t){var i=exports.FINDFIELD(e,t);o=utils.rest(e[i])}else o=utils.rest(e[t]);var a=o[r[0]];return utils.arrayEach(r,function(e){a<o[e]&&(a=o[e])}),a},exports.DMIN=function(e,t,n){if(isNaN(t)&&"string"!=typeof t)return error.value;var r=findResultIndex(e,n),o=[];if("string"==typeof t){var i=exports.FINDFIELD(e,t);o=utils.rest(e[i])}else o=utils.rest(e[t]);var a=o[r[0]];return utils.arrayEach(r,function(e){a>o[e]&&(a=o[e])}),a},exports.DPRODUCT=function(e,t,n){if(isNaN(t)&&"string"!=typeof t)return error.value;var r=findResultIndex(e,n),o=[];if("string"==typeof t){var i=exports.FINDFIELD(e,t);o=utils.rest(e[i])}else o=utils.rest(e[t]);var a=[];utils.arrayEach(r,function(e){a.push(o[e])}),a=compact(a);var s=1;return utils.arrayEach(a,function(e){s*=e}),s},exports.DSTDEV=function(e,t,n){if(isNaN(t)&&"string"!=typeof t)return error.value;var r=findResultIndex(e,n),o=[];if("string"==typeof t){var i=exports.FINDFIELD(e,t);o=utils.rest(e[i])}else o=utils.rest(e[t]);var a=[];return utils.arrayEach(r,function(e){a.push(o[e])}),a=compact(a),stats.STDEV.S(a)},exports.DSTDEVP=function(e,t,n){if(isNaN(t)&&"string"!=typeof t)return error.value;var r=findResultIndex(e,n),o=[];if("string"==typeof t){var i=exports.FINDFIELD(e,t);o=utils.rest(e[i])}else o=utils.rest(e[t]);var a=[];return utils.arrayEach(r,function(e){a.push(o[e])}),a=compact(a),stats.STDEV.P(a)},exports.DSUM=function(e,t,n){if(isNaN(t)&&"string"!=typeof t)return error.value;var r=findResultIndex(e,n),o=[];if("string"==typeof t){var i=exports.FINDFIELD(e,t);o=utils.rest(e[i])}else o=utils.rest(e[t]);var a=[];return utils.arrayEach(r,function(e){a.push(o[e])}),maths.SUM(a)},exports.DVAR=function(e,t,n){if(isNaN(t)&&"string"!=typeof t)return error.value;var r=findResultIndex(e,n),o=[];if("string"==typeof t){var i=exports.FINDFIELD(e,t);o=utils.rest(e[i])}else o=utils.rest(e[t]);var a=[];return utils.arrayEach(r,function(e){a.push(o[e])}),stats.VAR.S(a)},exports.DVARP=function(e,t,n){if(isNaN(t)&&"string"!=typeof t)return error.value;var r=findResultIndex(e,n),o=[];if("string"==typeof t){var i=exports.FINDFIELD(e,t);o=utils.rest(e[i])}else o=utils.rest(e[t]);var a=[];return utils.arrayEach(r,function(e){a.push(o[e])}),stats.VAR.P(a)}},function(e,t,n){var l=n(0),r=n(1),o=n(7);t.AND=function(){for(var e=r.flatten(arguments),t=!0,n=0;n<e.length;n++)e[n]||(t=!1);return t},t.CHOOSE=function(){if(arguments.length<2)return l.na;var e=arguments[0];return e<1||254<e?l.value:arguments.length<e+1?l.value:arguments[e]},t.FALSE=function(){return!1},t.IF=function(e,t,n){return e?t:n},t.IFERROR=function(e,t){return o.ISERROR(e)?t:e},t.IFNA=function(e,t){return e===l.na?t:e},t.NOT=function(e){return!e},t.OR=function(){for(var e=r.flatten(arguments),t=!1,n=0;n<e.length;n++)e[n]&&(t=!0);return t},t.TRUE=function(){return!0},t.XOR=function(){for(var e=r.flatten(arguments),t=0,n=0;n<e.length;n++)e[n]&&t++;return!!(1&Math.floor(Math.abs(t)))},t.SWITCH=function(){var e;if(0<arguments.length){var t=arguments[0],n=arguments.length-1,r=Math.floor(n/2),o=!1,i=n%2!=0,a=n%2==0?null:arguments[arguments.length-1];if(r)for(var s=0;s<r;s++)if(t===arguments[2*s+1]){e=arguments[2*s+2],o=!0;break}o||(e=i?a:l.na)}else e=l.value;return e}},function(e,u,t){var f=t(0),s=t(8),g=t(1);function l(e){return e&&e.getTime&&!isNaN(e.getTime())}function c(e){return e instanceof Date?e:new Date(e)}u.ACCRINT=function(e,t,n,r,o,i,a){return e=c(e),t=c(t),n=c(n),l(e)&&l(t)&&l(n)?r<=0||o<=0?f.num:-1===[1,2,4].indexOf(i)?f.num:-1===[0,1,2,3,4].indexOf(a)?f.num:n<=e?f.num:(a=a||0,(o=o||0)*r*s.YEARFRAC(e,n,a)):f.value},u.ACCRINTM=function(){throw new Error("ACCRINTM is not implemented")},u.AMORDEGRC=function(){throw new Error("AMORDEGRC is not implemented")},u.AMORLINC=function(){throw new Error("AMORLINC is not implemented")},u.COUPDAYBS=function(){throw new Error("COUPDAYBS is not implemented")},u.COUPDAYS=function(){throw new Error("COUPDAYS is not implemented")},u.COUPDAYSNC=function(){throw new Error("COUPDAYSNC is not implemented")},u.COUPNCD=function(){throw new Error("COUPNCD is not implemented")},u.COUPNUM=function(){throw new Error("COUPNUM is not implemented")},u.COUPPCD=function(){throw new Error("COUPPCD is not implemented")},u.CUMIPMT=function(e,t,n,r,o,i){if(e=g.parseNumber(e),t=g.parseNumber(t),n=g.parseNumber(n),g.anyIsError(e,t,n))return f.value;if(e<=0||t<=0||n<=0)return f.num;if(r<1||o<1||o<r)return f.num;if(0!==i&&1!==i)return f.num;var a=u.PMT(e,t,n,0,i),s=0;1===r&&0===i&&(s=-n,r++);for(var l=r;l<=o;l++)s+=1===i?u.FV(e,l-2,a,n,1)-a:u.FV(e,l-1,a,n,0);return s*=e},u.CUMPRINC=function(e,t,n,r,o,i){if(e=g.parseNumber(e),t=g.parseNumber(t),n=g.parseNumber(n),g.anyIsError(e,t,n))return f.value;if(e<=0||t<=0||n<=0)return f.num;if(r<1||o<1||o<r)return f.num;if(0!==i&&1!==i)return f.num;var a=u.PMT(e,t,n,0,i),s=0;1===r&&(s=0===i?a+n*e:a,r++);for(var l=r;l<=o;l++)s+=0<i?a-(u.FV(e,l-2,a,n,1)-a)*e:a-u.FV(e,l-1,a,n,0)*e;return s},u.DB=function(e,t,n,r,o){if(o=void 0===o?12:o,e=g.parseNumber(e),t=g.parseNumber(t),n=g.parseNumber(n),r=g.parseNumber(r),o=g.parseNumber(o),g.anyIsError(e,t,n,r,o))return f.value;if(e<0||t<0||n<0||r<0)return f.num;if(-1===[1,2,3,4,5,6,7,8,9,10,11,12].indexOf(o))return f.num;if(n<r)return f.num;if(e<=t)return 0;for(var i=(1-Math.pow(t/e,1/n)).toFixed(3),a=e*i*o/12,s=a,l=0,u=r===n?n-1:r,c=2;c<=u;c++)s+=l=(e-s)*i;return 1===r?a:r===n?(e-s)*i:l},u.DDB=function(e,t,n,r,o){if(o=void 0===o?2:o,e=g.parseNumber(e),t=g.parseNumber(t),n=g.parseNumber(n),r=g.parseNumber(r),o=g.parseNumber(o),g.anyIsError(e,t,n,r,o))return f.value;if(e<0||t<0||n<0||r<0||o<=0)return f.num;if(n<r)return f.num;if(e<=t)return 0;for(var i=0,a=0,s=1;s<=r;s++)i+=a=Math.min(o/n*(e-i),e-t-i);return a},u.DISC=function(){throw new Error("DISC is not implemented")},u.DOLLARDE=function(e,t){if(e=g.parseNumber(e),t=g.parseNumber(t),g.anyIsError(e,t))return f.value;if(t<0)return f.num;if(0<=t&&t<1)return f.div0;t=parseInt(t,10);var n=parseInt(e,10);n+=e%1*Math.pow(10,Math.ceil(Math.log(t)/Math.LN10))/t;var r=Math.pow(10,Math.ceil(Math.log(t)/Math.LN2)+1);return n=Math.round(n*r)/r},u.DOLLARFR=function(e,t){if(e=g.parseNumber(e),t=g.parseNumber(t),g.anyIsError(e,t))return f.value;if(t<0)return f.num;if(0<=t&&t<1)return f.div0;t=parseInt(t,10);var n=parseInt(e,10);return n+=e%1*Math.pow(10,-Math.ceil(Math.log(t)/Math.LN10))*t},u.DURATION=function(){throw new Error("DURATION is not implemented")},u.EFFECT=function(e,t){return e=g.parseNumber(e),t=g.parseNumber(t),g.anyIsError(e,t)?f.value:e<=0||t<1?f.num:(t=parseInt(t,10),Math.pow(1+e/t,t)-1)},u.FV=function(e,t,n,r,o){if(r=r||0,o=o||0,e=g.parseNumber(e),t=g.parseNumber(t),n=g.parseNumber(n),r=g.parseNumber(r),o=g.parseNumber(o),g.anyIsError(e,t,n,r,o))return f.value;var i;if(0===e)i=r+n*t;else{var a=Math.pow(1+e,t);i=1===o?r*a+n*(1+e)*(a-1)/e:r*a+n*(a-1)/e}return-i},u.FVSCHEDULE=function(e,t){if(e=g.parseNumber(e),t=g.parseNumberArray(g.flatten(t)),g.anyIsError(e,t))return f.value;for(var n=t.length,r=e,o=0;o<n;o++)r*=1+t[o];return r},u.INTRATE=function(){throw new Error("INTRATE is not implemented")},u.IPMT=function(e,t,n,r,o,i){if(o=o||0,i=i||0,e=g.parseNumber(e),t=g.parseNumber(t),n=g.parseNumber(n),r=g.parseNumber(r),o=g.parseNumber(o),i=g.parseNumber(i),g.anyIsError(e,t,n,r,o,i))return f.value;var a=u.PMT(e,n,r,o,i);return(1===t?1===i?0:-r:1===i?u.FV(e,t-2,a,r,1)-a:u.FV(e,t-1,a,r,0))*e},u.IRR=function(e,t){if(t=t||0,e=g.parseNumberArray(g.flatten(e)),t=g.parseNumber(t),g.anyIsError(e,t))return f.value;for(var n=function(e,t,n){for(var r=n+1,o=e[0],i=1;i<e.length;i++)o+=e[i]/Math.pow(r,(t[i]-t[0])/365);return o},r=function(e,t,n){for(var r=n+1,o=0,i=1;i<e.length;i++){var a=(t[i]-t[0])/365;o-=a*e[i]/Math.pow(r,1+a)}return o},o=[],i=!1,a=!1,s=0;s<e.length;s++)o[s]=0===s?0:o[s-1]+365,0<e[s]&&(i=!0),e[s]<0&&(a=!0);if(!i||!a)return f.num;for(var l,u,c,h=t=void 0===t?.1:t;l=h-(c=n(e,o,h))/r(e,o,h),u=Math.abs(l-h),h=l,1e-10<u&&1e-10<Math.abs(c););return h},u.ISPMT=function(e,t,n,r){return e=g.parseNumber(e),t=g.parseNumber(t),n=g.parseNumber(n),r=g.parseNumber(r),g.anyIsError(e,t,n,r)?f.value:r*e*(t/n-1)},u.MDURATION=function(){throw new Error("MDURATION is not implemented")},u.MIRR=function(e,t,n){if(e=g.parseNumberArray(g.flatten(e)),t=g.parseNumber(t),n=g.parseNumber(n),g.anyIsError(e,t,n))return f.value;for(var r=e.length,o=[],i=[],a=0;a<r;a++)e[a]<0?o.push(e[a]):i.push(e[a]);var s=-u.NPV(n,i)*Math.pow(1+n,r-1),l=u.NPV(t,o)*(1+t);return Math.pow(s/l,1/(r-1))-1},u.NOMINAL=function(e,t){return e=g.parseNumber(e),t=g.parseNumber(t),g.anyIsError(e,t)?f.value:e<=0||t<1?f.num:(t=parseInt(t,10),(Math.pow(e+1,1/t)-1)*t)},u.NPER=function(e,t,n,r,o){if(o=void 0===o?0:o,r=void 0===r?0:r,e=g.parseNumber(e),t=g.parseNumber(t),n=g.parseNumber(n),r=g.parseNumber(r),o=g.parseNumber(o),g.anyIsError(e,t,n,r,o))return f.value;var i=t*(1+e*o)-r*e,a=n*e+t*(1+e*o);return Math.log(i/a)/Math.log(1+e)},u.NPV=function(){var e=g.parseNumberArray(g.flatten(arguments));if(e instanceof Error)return e;for(var t=e[0],n=0,r=1;r<e.length;r++)n+=e[r]/Math.pow(1+t,r);return n},u.ODDFPRICE=function(){throw new Error("ODDFPRICE is not implemented")},u.ODDFYIELD=function(){throw new Error("ODDFYIELD is not implemented")},u.ODDLPRICE=function(){throw new Error("ODDLPRICE is not implemented")},u.ODDLYIELD=function(){throw new Error("ODDLYIELD is not implemented")},u.PDURATION=function(e,t,n){return e=g.parseNumber(e),t=g.parseNumber(t),n=g.parseNumber(n),g.anyIsError(e,t,n)?f.value:e<=0?f.num:(Math.log(n)-Math.log(t))/Math.log(1+e)},u.PMT=function(e,t,n,r,o){if(r=r||0,o=o||0,e=g.parseNumber(e),t=g.parseNumber(t),n=g.parseNumber(n),r=g.parseNumber(r),o=g.parseNumber(o),g.anyIsError(e,t,n,r,o))return f.value;var i;if(0===e)i=(n+r)/t;else{var a=Math.pow(1+e,t);i=1===o?(r*e/(a-1)+n*e/(1-1/a))/(1+e):r*e/(a-1)+n*e/(1-1/a)}return-i},u.PPMT=function(e,t,n,r,o,i){return o=o||0,i=i||0,e=g.parseNumber(e),n=g.parseNumber(n),r=g.parseNumber(r),o=g.parseNumber(o),i=g.parseNumber(i),g.anyIsError(e,n,r,o,i)?f.value:u.PMT(e,n,r,o,i)-u.IPMT(e,t,n,r,o,i)},u.PRICE=function(){throw new Error("PRICE is not implemented")},u.PRICEDISC=function(){throw new Error("PRICEDISC is not implemented")},u.PRICEMAT=function(){throw new Error("PRICEMAT is not implemented")},u.PV=function(e,t,n,r,o){return r=r||0,o=o||0,e=g.parseNumber(e),t=g.parseNumber(t),n=g.parseNumber(n),r=g.parseNumber(r),o=g.parseNumber(o),g.anyIsError(e,t,n,r,o)?f.value:0===e?-n*t-r:((1-Math.pow(1+e,t))/e*n*(1+e*o)-r)/Math.pow(1+e,t)},u.RATE=function(e,t,n,r,o,i){if(i=void 0===i?.01:i,r=void 0===r?0:r,o=void 0===o?0:o,e=g.parseNumber(e),t=g.parseNumber(t),n=g.parseNumber(n),r=g.parseNumber(r),o=g.parseNumber(o),i=g.parseNumber(i),g.anyIsError(e,t,n,r,o,i))return f.value;var a,s,l,u=0,c=0,h=0,d=i;for(Math.abs(d)<1e-10?n*(1+e*d)+t*(1+d*o)*e+r:n*(c=Math.exp(e*Math.log(1+d)))+t*(1/d+o)*(c-1)+r,a=n+t*e+r,s=n*c+t*(1/d+o)*(c-1)+r,h=l=0,u=d;1e-10<Math.abs(a-s)&&h<50;)d=(s*l-a*u)/(s-a),l=u,u=d,a=s,s=Math.abs(d)<1e-10?n*(1+e*d)+t*(1+d*o)*e+r:n*(c=Math.exp(e*Math.log(1+d)))+t*(1/d+o)*(c-1)+r,++h;return d},u.RECEIVED=function(){throw new Error("RECEIVED is not implemented")},u.RRI=function(e,t,n){return e=g.parseNumber(e),t=g.parseNumber(t),n=g.parseNumber(n),g.anyIsError(e,t,n)?f.value:0===e||0===t?f.num:Math.pow(n/t,1/e)-1},u.SLN=function(e,t,n){return e=g.parseNumber(e),t=g.parseNumber(t),n=g.parseNumber(n),g.anyIsError(e,t,n)?f.value:0===n?f.num:(e-t)/n},u.SYD=function(e,t,n,r){return e=g.parseNumber(e),t=g.parseNumber(t),n=g.parseNumber(n),r=g.parseNumber(r),g.anyIsError(e,t,n,r)?f.value:0===n?f.num:r<1||n<r?f.num:(e-t)*(n-(r=parseInt(r,10))+1)*2/(n*(n+1))},u.TBILLEQ=function(e,t,n){return e=g.parseDate(e),t=g.parseDate(t),n=g.parseNumber(n),g.anyIsError(e,t,n)?f.value:n<=0?f.num:t<e?f.num:31536e6<t-e?f.num:365*n/(360-n*s.DAYS360(e,t,!1))},u.TBILLPRICE=function(e,t,n){return e=g.parseDate(e),t=g.parseDate(t),n=g.parseNumber(n),g.anyIsError(e,t,n)?f.value:n<=0?f.num:t<e?f.num:31536e6<t-e?f.num:100*(1-n*s.DAYS360(e,t,!1)/360)},u.TBILLYIELD=function(e,t,n){return e=g.parseDate(e),t=g.parseDate(t),n=g.parseNumber(n),g.anyIsError(e,t,n)?f.value:n<=0?f.num:t<e?f.num:31536e6<t-e?f.num:360*(100-n)/(n*s.DAYS360(e,t,!1))},u.VDB=function(){throw new Error("VDB is not implemented")},u.XNPV=function(e,t,n){if(e=g.parseNumber(e),t=g.parseNumberArray(g.flatten(t)),n=g.parseDateArray(g.flatten(n)),g.anyIsError(e,t,n))return f.value;for(var r=0,o=0;o<t.length;o++)r+=t[o]/Math.pow(1+e,s.DAYS(n[o],n[0])/365);return r},u.YIELD=function(){throw new Error("YIELD is not implemented")},u.YIELDDISC=function(){throw new Error("YIELDDISC is not implemented")},u.YIELDMAT=function(){throw new Error("YIELDMAT is not implemented")}},function(e,t,n){var s=n(0),l=n(1);t.MATCH=function(e,t,n){if(!e&&!t)return s.na;if(2===arguments.length&&(n=1),!(t instanceof Array))return s.na;if(-1!==n&&0!==n&&1!==n)return s.na;for(var r,o,i=0;i<t.length;i++)if(1===n){if(t[i]===e)return i+1;t[i]<e&&(o?t[i]>o&&(r=i+1,o=t[i]):(r=i+1,o=t[i]))}else if(0===n){if("string"==typeof e){if(e=e.replace(/\?/g,"."),t[i].toLowerCase().match(e.toLowerCase()))return i+1}else if(t[i]===e)return i+1}else if(-1===n){if(t[i]===e)return i+1;t[i]>e&&(o?t[i]<o&&(r=i+1,o=t[i]):(r=i+1,o=t[i]))}return r||s.na},t.VLOOKUP=function(e,t,n,r){if(!e||!t||!n)return s.na;r=r||!1;for(var o=0;o<t.length;o++){var i=t[o];if(!r&&i[0]===e||i[0]===e||r&&"string"==typeof i[0]&&-1!==i[0].toLowerCase().indexOf(e.toLowerCase()))return n<i.length+1?i[n-1]:s.ref}return s.na},t.HLOOKUP=function(e,t,n,r){if(!e||!t||!n)return s.na;r=r||!1;for(var o=l.transpose(t),i=0;i<o.length;i++){var a=o[i];if(!r&&a[0]===e||a[0]===e||r&&"string"==typeof a[0]&&-1!==a[0].toLowerCase().indexOf(e.toLowerCase()))return n<a.length+1?a[n-1]:s.ref}return s.na}},function(e,t,n){"use strict";t.__esModule=!0,t.default=o;var r=t.SYMBOL=">";function o(e,t){return t<e}o.SYMBOL=r},function(e,t,n){"use strict";t.__esModule=!0,t.default=o;var r=t.SYMBOL=">=";function o(e,t){return t<=e}o.SYMBOL=r},function(e,t,n){"use strict";t.__esModule=!0,t.default=o;var r=t.SYMBOL="<";function o(e,t){return e<t}o.SYMBOL=r},function(e,t,n){"use strict";t.__esModule=!0,t.default=o;var r=t.SYMBOL="<=";function o(e,t){return e<=t}o.SYMBOL=r},function(e,t,n){"use strict";t.__esModule=!0,t.SYMBOL=void 0,t.default=o;var i=n(3),a=n(2),r=t.SYMBOL="-";function o(e){for(var t=arguments.length,n=Array(1<t?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var o=n.reduce(function(e,t){return e-(0,i.toNumber)(t)},(0,i.toNumber)(e));if(isNaN(o))throw Error(a.ERROR_VALUE);return o}o.SYMBOL=r},function(e,t,n){"use strict";t.__esModule=!0,t.SYMBOL=void 0,t.default=o;var i=n(3),a=n(2),r=t.SYMBOL="*";function o(e){for(var t=arguments.length,n=Array(1<t?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var o=n.reduce(function(e,t){return e*(0,i.toNumber)(t)},(0,i.toNumber)(e));if(isNaN(o))throw Error(a.ERROR_VALUE);return o}o.SYMBOL=r},function(e,t,n){"use strict";t.__esModule=!0,t.default=o;var r=t.SYMBOL="<>";function o(e,t){return e!==t}o.SYMBOL=r},function(e,t,n){"use strict";t.__esModule=!0,t.SYMBOL=void 0,t.default=a;var r=n(3),o=n(2),i=t.SYMBOL="^";function a(e,t){var n=Math.pow((0,r.toNumber)(e),(0,r.toNumber)(t));if(isNaN(n))throw Error(o.ERROR_VALUE);return n}a.SYMBOL=i},function(module,exports,__webpack_require__){(function(module,process){var grammarParser=function(){var o=function(e,t,n,r){for(n=n||{},r=e.length;r--;n[e[r]]=t);return n},$V0=[1,5],$V1=[1,8],$V2=[1,6],$V3=[1,7],$V4=[1,9],$V5=[1,14],$V6=[1,15],$V7=[1,16],$V8=[1,12],$V9=[1,13],$Va=[1,17],$Vb=[1,19],$Vc=[1,20],$Vd=[1,21],$Ve=[1,22],$Vf=[1,23],$Vg=[1,24],$Vh=[1,25],$Vi=[1,26],$Vj=[1,27],$Vk=[1,28],$Vl=[5,9,10,11,13,14,15,16,17,18,19,20,29,30],$Vm=[5,9,10,11,13,14,15,16,17,18,19,20,29,30,32],$Vn=[5,9,10,11,13,14,15,16,17,18,19,20,29,30,34],$Vo=[5,10,11,13,14,15,16,17,29,30],$Vp=[5,10,13,14,15,16,29,30],$Vq=[5,10,11,13,14,15,16,17,18,19,29,30],$Vr=[13,29,30],parser={trace:function(){},yy:{},symbols_:{error:2,expressions:3,expression:4,EOF:5,variableSequence:6,number:7,STRING:8,"&":9,"=":10,"+":11,"(":12,")":13,"<":14,">":15,NOT:16,"-":17,"*":18,"/":19,"^":20,FUNCTION:21,expseq:22,cell:23,ABSOLUTE_CELL:24,RELATIVE_CELL:25,MIXED_CELL:26,":":27,ARRAY:28,";":29,",":30,VARIABLE:31,DECIMAL:32,NUMBER:33,"%":34,ERROR:35,$accept:0,$end:1},terminals_:{5:"EOF",8:"STRING",9:"&",10:"=",11:"+",12:"(",13:")",14:"<",15:">",16:"NOT",17:"-",18:"*",19:"/",20:"^",21:"FUNCTION",24:"ABSOLUTE_CELL",25:"RELATIVE_CELL",26:"MIXED_CELL",27:":",28:"ARRAY",29:";",30:",",31:"VARIABLE",32:"DECIMAL",33:"NUMBER",34:"%",35:"ERROR"},productions_:[0,[3,2],[4,1],[4,1],[4,1],[4,3],[4,3],[4,3],[4,3],[4,4],[4,4],[4,4],[4,3],[4,3],[4,3],[4,3],[4,3],[4,3],[4,3],[4,2],[4,2],[4,3],[4,4],[4,1],[4,1],[4,2],[23,1],[23,1],[23,1],[23,3],[23,3],[23,3],[23,3],[23,3],[23,3],[23,3],[23,3],[23,3],[22,1],[22,1],[22,3],[22,3],[6,1],[6,3],[7,1],[7,3],[7,2],[2,1]],performAction:function anonymous(yytext,yyleng,yylineno,yy,yystate,$$,_$){var $0=$$.length-1;switch(yystate){case 1:return $$[$0-1];case 2:this.$=yy.callVariable($$[$0][0]);break;case 3:this.$=yy.toNumber($$[$0]);break;case 4:this.$=yy.trimEdges($$[$0]);break;case 5:this.$=yy.evaluateByOperator("&",[$$[$0-2],$$[$0]]);break;case 6:this.$=yy.evaluateByOperator("=",[$$[$0-2],$$[$0]]);break;case 7:this.$=yy.evaluateByOperator("+",[$$[$0-2],$$[$0]]);break;case 8:this.$=$$[$0-1];break;case 9:this.$=yy.evaluateByOperator("<=",[$$[$0-3],$$[$0]]);break;case 10:this.$=yy.evaluateByOperator(">=",[$$[$0-3],$$[$0]]);break;case 11:this.$=yy.evaluateByOperator("<>",[$$[$0-3],$$[$0]]);break;case 12:this.$=yy.evaluateByOperator("NOT",[$$[$0-2],$$[$0]]);break;case 13:this.$=yy.evaluateByOperator(">",[$$[$0-2],$$[$0]]);break;case 14:this.$=yy.evaluateByOperator("<",[$$[$0-2],$$[$0]]);break;case 15:this.$=yy.evaluateByOperator("-",[$$[$0-2],$$[$0]]);break;case 16:this.$=yy.evaluateByOperator("*",[$$[$0-2],$$[$0]]);break;case 17:this.$=yy.evaluateByOperator("/",[$$[$0-2],$$[$0]]);break;case 18:this.$=yy.evaluateByOperator("^",[$$[$0-2],$$[$0]]);break;case 19:var n1=yy.invertNumber($$[$0]);this.$=n1,isNaN(this.$)&&(this.$=0);break;case 20:var n1=yy.toNumber($$[$0]);this.$=n1,isNaN(this.$)&&(this.$=0);break;case 21:this.$=yy.callFunction($$[$0-2]);break;case 22:this.$=yy.callFunction($$[$0-3],$$[$0-1]);break;case 26:case 27:case 28:this.$=yy.cellValue($$[$0]);break;case 29:case 30:case 31:case 32:case 33:case 34:case 35:case 36:case 37:this.$=yy.rangeValue($$[$0-2],$$[$0]);break;case 38:case 42:this.$=[$$[$0]];break;case 39:var result=[],arr=eval("["+yytext+"]");arr.forEach(function(e){result.push(e)}),this.$=result;break;case 40:case 41:$$[$0-2].push($$[$0]),this.$=$$[$0-2];break;case 43:this.$=Array.isArray($$[$0-2])?$$[$0-2]:[$$[$0-2]],this.$.push($$[$0]);break;case 44:this.$=$$[$0];break;case 45:this.$=1*($$[$0-2]+"."+$$[$0]);break;case 46:this.$=.01*$$[$0-1];break;case 47:this.$=yy.throwError($$[$0])}},table:[{2:11,3:1,4:2,6:3,7:4,8:$V0,11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},{1:[3]},{5:[1,18],9:$Vb,10:$Vc,11:$Vd,14:$Ve,15:$Vf,16:$Vg,17:$Vh,18:$Vi,19:$Vj,20:$Vk},o($Vl,[2,2],{32:[1,29]}),o($Vl,[2,3],{34:[1,30]}),o($Vl,[2,4]),{2:11,4:31,6:3,7:4,8:$V0,11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},{2:11,4:32,6:3,7:4,8:$V0,11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},{2:11,4:33,6:3,7:4,8:$V0,11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},{12:[1,34]},o($Vl,[2,23]),o($Vl,[2,24],{2:35,35:$Va}),o($Vm,[2,42]),o($Vn,[2,44],{32:[1,36]}),o($Vl,[2,26],{27:[1,37]}),o($Vl,[2,27],{27:[1,38]}),o($Vl,[2,28],{27:[1,39]}),o([5,9,10,11,13,14,15,16,17,18,19,20,29,30,35],[2,47]),{1:[2,1]},{2:11,4:40,6:3,7:4,8:$V0,11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},{2:11,4:41,6:3,7:4,8:$V0,11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},{2:11,4:42,6:3,7:4,8:$V0,11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},{2:11,4:45,6:3,7:4,8:$V0,10:[1,43],11:$V1,12:$V2,15:[1,44],17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},{2:11,4:47,6:3,7:4,8:$V0,10:[1,46],11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},{2:11,4:48,6:3,7:4,8:$V0,11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},{2:11,4:49,6:3,7:4,8:$V0,11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},{2:11,4:50,6:3,7:4,8:$V0,11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},{2:11,4:51,6:3,7:4,8:$V0,11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},{2:11,4:52,6:3,7:4,8:$V0,11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},{31:[1,53]},o($Vn,[2,46]),{9:$Vb,10:$Vc,11:$Vd,13:[1,54],14:$Ve,15:$Vf,16:$Vg,17:$Vh,18:$Vi,19:$Vj,20:$Vk},o($Vo,[2,19],{9:$Vb,18:$Vi,19:$Vj,20:$Vk}),o($Vo,[2,20],{9:$Vb,18:$Vi,19:$Vj,20:$Vk}),{2:11,4:57,6:3,7:4,8:$V0,11:$V1,12:$V2,13:[1,55],17:$V3,21:$V4,22:56,23:10,24:$V5,25:$V6,26:$V7,28:[1,58],31:$V8,33:$V9,35:$Va},o($Vl,[2,25]),{33:[1,59]},{24:[1,60],25:[1,61],26:[1,62]},{24:[1,63],25:[1,64],26:[1,65]},{24:[1,66],25:[1,67],26:[1,68]},o($Vl,[2,5]),o([5,10,13,29,30],[2,6],{9:$Vb,11:$Vd,14:$Ve,15:$Vf,16:$Vg,17:$Vh,18:$Vi,19:$Vj,20:$Vk}),o($Vo,[2,7],{9:$Vb,18:$Vi,19:$Vj,20:$Vk}),{2:11,4:69,6:3,7:4,8:$V0,11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},{2:11,4:70,6:3,7:4,8:$V0,11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},o($Vp,[2,14],{9:$Vb,11:$Vd,17:$Vh,18:$Vi,19:$Vj,20:$Vk}),{2:11,4:71,6:3,7:4,8:$V0,11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},o($Vp,[2,13],{9:$Vb,11:$Vd,17:$Vh,18:$Vi,19:$Vj,20:$Vk}),o([5,10,13,16,29,30],[2,12],{9:$Vb,11:$Vd,14:$Ve,15:$Vf,17:$Vh,18:$Vi,19:$Vj,20:$Vk}),o($Vo,[2,15],{9:$Vb,18:$Vi,19:$Vj,20:$Vk}),o($Vq,[2,16],{9:$Vb,20:$Vk}),o($Vq,[2,17],{9:$Vb,20:$Vk}),o([5,10,11,13,14,15,16,17,18,19,20,29,30],[2,18],{9:$Vb}),o($Vm,[2,43]),o($Vl,[2,8]),o($Vl,[2,21]),{13:[1,72],29:[1,73],30:[1,74]},o($Vr,[2,38],{9:$Vb,10:$Vc,11:$Vd,14:$Ve,15:$Vf,16:$Vg,17:$Vh,18:$Vi,19:$Vj,20:$Vk}),o($Vr,[2,39]),o($Vn,[2,45]),o($Vl,[2,29]),o($Vl,[2,30]),o($Vl,[2,31]),o($Vl,[2,32]),o($Vl,[2,33]),o($Vl,[2,34]),o($Vl,[2,35]),o($Vl,[2,36]),o($Vl,[2,37]),o($Vp,[2,9],{9:$Vb,11:$Vd,17:$Vh,18:$Vi,19:$Vj,20:$Vk}),o($Vp,[2,11],{9:$Vb,11:$Vd,17:$Vh,18:$Vi,19:$Vj,20:$Vk}),o($Vp,[2,10],{9:$Vb,11:$Vd,17:$Vh,18:$Vi,19:$Vj,20:$Vk}),o($Vl,[2,22]),{2:11,4:75,6:3,7:4,8:$V0,11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},{2:11,4:76,6:3,7:4,8:$V0,11:$V1,12:$V2,17:$V3,21:$V4,23:10,24:$V5,25:$V6,26:$V7,31:$V8,33:$V9,35:$Va},o($Vr,[2,40],{9:$Vb,10:$Vc,11:$Vd,14:$Ve,15:$Vf,16:$Vg,17:$Vh,18:$Vi,19:$Vj,20:$Vk}),o($Vr,[2,41],{9:$Vb,10:$Vc,11:$Vd,14:$Ve,15:$Vf,16:$Vg,17:$Vh,18:$Vi,19:$Vj,20:$Vk})],defaultActions:{18:[2,1]},parseError:function(e,t){if(!t.recoverable){function n(e,t){this.message=e,this.hash=t}throw n.prototype=Error,new n(e,t)}this.trace(e)},parse:function(e){var t=this,r=[0],n=[null],o=[],i=this.table,a="",s=0,l=0,u=0,c=2,h=o.slice.call(arguments,1),d=Object.create(this.lexer),f={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(f.yy[g]=this.yy[g]);d.setInput(e,f.yy),f.yy.lexer=d,f.yy.parser=this,void 0===d.yylloc&&(d.yylloc={});var v=d.yylloc;o.push(v);var p=d.options&&d.options.ranges;"function"==typeof f.yy.parseError?this.parseError=f.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var m,y,w,C,E,S,b,T,R,_,k=function(){var e;return"number"!=typeof(e=d.lex()||1)&&(e=t.symbols_[e]||e),e},O={};;){if(w=r[r.length-1],void 0===(C=this.defaultActions[w]?this.defaultActions[w]:(null==m&&(m=k()),i[w]&&i[w][m]))||!C.length||!C[0]){var M,N="";function A(e){for(var t=r.length-1,n=0;;){if(c.toString()in i[e])return n;if(0===e||t<2)return!1;e=r[t-=2],++n}}if(u)1!==y&&(M=A(w));else{for(S in M=A(w),R=[],i[w])this.terminals_[S]&&c<S&&R.push("'"+this.terminals_[S]+"'");N=d.showPosition?"Parse error on line "+(s+1)+":\n"+d.showPosition()+"\nExpecting "+R.join(", ")+", got '"+(this.terminals_[m]||m)+"'":"Parse error on line "+(s+1)+": Unexpected "+(1==m?"end of input":"'"+(this.terminals_[m]||m)+"'"),this.parseError(N,{text:d.match,token:this.terminals_[m]||m,line:d.yylineno,loc:v,expected:R,recoverable:!1!==M})}if(3==u){if(1===m||1===y)throw new Error(N||"Parsing halted while starting to recover from another error.");l=d.yyleng,a=d.yytext,s=d.yylineno,v=d.yylloc,m=k()}if(!1===M)throw new Error(N||"Parsing halted. No suitable error recovery rule available.");_=M,r.length=r.length-2*_,n.length=n.length-_,o.length=o.length-_,y=m==c?null:m,m=c,w=r[r.length-1],C=i[w]&&i[w][c],u=3}if(C[0]instanceof Array&&1<C.length)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+m);switch(C[0]){case 1:r.push(m),n.push(d.yytext),o.push(d.yylloc),r.push(C[1]),m=null,y?(m=y,y=null):(l=d.yyleng,a=d.yytext,s=d.yylineno,v=d.yylloc,0<u&&u--);break;case 2:if(b=this.productions_[C[1]][1],O.$=n[n.length-b],O._$={first_line:o[o.length-(b||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(b||1)].first_column,last_column:o[o.length-1].last_column},p&&(O._$.range=[o[o.length-(b||1)].range[0],o[o.length-1].range[1]]),void 0!==(E=this.performAction.apply(O,[a,l,s,f.yy,C[1],n,o].concat(h))))return E;b&&(r=r.slice(0,-1*b*2),n=n.slice(0,-1*b),o=o.slice(0,-1*b)),r.push(this.productions_[C[1]][0]),n.push(O.$),o.push(O._$),T=i[r[r.length-2]][r[r.length-1]],r.push(T);break;case 3:return!0}}return!0}},lexer={EOF:1,parseError:function(e,t){if(!this.yy.parser)throw new Error(e);this.yy.parser.parseError(e,t)},setInput:function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},unput:function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var o=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[o[0],o[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(e){this.unput(this.match.slice(e))},pastInput:function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(20<e.length?"...":"")+e.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(20<e.length?"...":"")).replace(/\n/g,"")},showPosition:function(){var e=this.pastInput(),t=new Array(e.length+1).join("-");return e+this.upcomingInput()+"\n"+t+"^"},test_match:function(e,t){var n,r,o;if(this.options.backtrack_lexer&&(o={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(o.yylloc.range=this.yylloc.range.slice(0))),(r=e[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var i in o)this[i]=o[i];return!1}return!1},next:function(){if(this.done)return this.EOF;var e,t,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var o=this._currentRules(),i=0;i<o.length;i++)if((n=this._input.match(this.rules[o[i]]))&&(!t||n[0].length>t[0].length)){if(t=n,r=i,this.options.backtrack_lexer){if(!1!==(e=this.test_match(n,o[i])))return e;if(this._backtrack){t=!1;continue}return!1}if(!this.options.flex)break}return t?!1!==(e=this.test_match(t,o[r]))&&e:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var e=this.next();return e||this.lex()},begin:function(e){this.conditionStack.push(e)},popState:function(){return 0<this.conditionStack.length-1?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(e){return 0<=(e=this.conditionStack.length-1-Math.abs(e||0))?this.conditionStack[e]:"INITIAL"},pushState:function(e){this.begin(e)},stateStackSize:function(){return this.conditionStack.length},options:{},performAction:function(e,t,n,r){switch(n){case 0:break;case 1:case 2:return 8;case 3:return 21;case 4:return 35;case 5:return 24;case 6:case 7:return 26;case 8:return 25;case 9:return 21;case 10:case 11:return 31;case 12:return 33;case 13:return 28;case 14:return 9;case 15:return" ";case 16:return 32;case 17:return 27;case 18:return 29;case 19:return 30;case 20:return 18;case 21:return 19;case 22:return 17;case 23:return 11;case 24:return 20;case 25:return 12;case 26:return 13;case 27:return 15;case 28:return 14;case 29:return 16;case 30:return'"';case 31:return"'";case 32:return"!";case 33:return 10;case 34:return 34;case 35:return"#";case 36:return 5}},rules:[/^(?:\s+)/,/^(?:"(\\["]|[^"])*")/,/^(?:'(\\[']|[^'])*')/,/^(?:[A-Za-z]{1,}[A-Za-z_0-9\.]+(?=[(]))/,/^(?:#[A-Z0-9\/]+(!|\?)?)/,/^(?:\$[A-Za-z]+\$[0-9]+)/,/^(?:\$[A-Za-z]+[0-9]+)/,/^(?:[A-Za-z]+\$[0-9]+)/,/^(?:[A-Za-z]+[0-9]+)/,/^(?:[A-Za-z\.]+(?=[(]))/,/^(?:[A-Za-z]{1,}[A-Za-z_0-9]+)/,/^(?:[A-Za-z_]+)/,/^(?:[0-9]+)/,/^(?:\[(.*)?\])/,/^(?:&)/,/^(?: )/,/^(?:[.])/,/^(?::)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:\/)/,/^(?:-)/,/^(?:\+)/,/^(?:\^)/,/^(?:\()/,/^(?:\))/,/^(?:>)/,/^(?:<)/,/^(?:NOT\b)/,/^(?:")/,/^(?:')/,/^(?:!)/,/^(?:=)/,/^(?:%)/,/^(?:[#])/,/^(?:$)/],conditions:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36],inclusive:!0}}};function Parser(){this.yy={}}return parser.lexer=lexer,Parser.prototype=parser,parser.Parser=Parser,new Parser}();exports.parser=grammarParser,exports.Parser=grammarParser.Parser,exports.parse=function(){return grammarParser.parse.apply(grammarParser,arguments)},void 0!==module&&__webpack_require__.c[__webpack_require__.s]===module&&exports.main(process.argv.slice(1))}).call(exports,__webpack_require__(39)(module),__webpack_require__(40))},function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},function(e,t){var n,r,o=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function s(t){if(n===setTimeout)return setTimeout(t,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(e){n=i}try{r="function"==typeof clearTimeout?clearTimeout:a}catch(e){r=a}}();var l,u=[],c=!1,h=-1;function d(){c&&l&&(c=!1,l.length?u=l.concat(u):h=-1,u.length&&f())}function f(){if(!c){var e=s(d);c=!0;for(var t=u.length;t;){for(l=u,u=[];++h<t;)l&&l[h].run();h=-1,t=u.length}l=null,c=!1,function(t){if(r===clearTimeout)return clearTimeout(t);if((r===a||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(t);try{r(t)}catch(e){try{return r.call(null,t)}catch(e){return r.call(this,t)}}}(e)}}function g(e,t){this.fun=e,this.array=t}function v(){}o.nextTick=function(e){var t=new Array(arguments.length-1);if(1<arguments.length)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];u.push(new g(e,t)),1!==u.length||c||s(f)},g.prototype.run=function(){this.fun.apply(null,this.array)},o.title="browser",o.browser=!0,o.env={},o.argv=[],o.version="",o.versions={},o.on=v,o.addListener=v,o.once=v,o.off=v,o.removeListener=v,o.removeAllListeners=v,o.emit=v,o.prependListener=v,o.prependOnceListener=v,o.listeners=function(e){return[]},o.binding=function(e){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(e){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},function(e,t,n){"use strict";t.__esModule=!0,t.trimEdges=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:1;return e=e.substring(t,e.length-t)}}])},module.exports=Iia()},function(e,t,n){"use strict";var r=n(0);n(12),n(131),n(37),n(46),n(138),t.__esModule=!0,t.default=void 0;var g=r(n(19)),o=r(n(1)),i=r(n(2)),v=n(111),s=n(3),a=n(4),l=r(n(57)),u=n(84),c=/^\$?[A-Z]+\$?\d+$/,h=/\$?[A-Z]+\$?\d+/,d=/(?:[^0-9A-Z$: ]|^)\s*(\$?[A-Z]+\$?\d+)\s*(?![0-9A-Z_: ])/g,p=/\$?[A-Z]+\$?\d+\s*:\s*\$?[A-Z]+\$?\d+/g,f=/((?:[^0-9A-Z$: ]|^)\s*(\$?[A-Z]+\$?\d+)\s*(?![0-9A-Z_: ]))|(\$?[A-Z]+\$?\d+\s*:\s*\$?[A-Z]+\$?\d+)/g,m=function(){function t(e){(0,o.default)(this,t),this.expression="",this.cells=[],this.customModifier=null,"string"==typeof e&&this.setExpression(e)}return(0,i.default)(t,[{key:"setExpression",value:function(e){return this.cells.length=0,this.expression=(0,u.toUpperCaseFormula)(e),this._extractCells(),this._extractCellsRange(),this}},{key:"useCustomModifier",value:function(e){this.customModifier=e}},{key:"translate",value:function(e){var t=this,n=e.row,r=e.column,o=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};return(0,s.arrayEach)(this.cells,function(e){null!=n&&t._translateCell(e,"row",n,o.row),null!=r&&t._translateCell(e,"column",r,o.column)}),this}},{key:"toString",value:function(){var l=this,e=this.expression.replace(f,function(e,t,n){var r=-1===e.indexOf(":"),o=e,i=e,a=null;r&&(i=c.test(t)?t:n);var s=l._searchCell(i);return s&&(a=s.refError?(0,v.error)(v.ERROR_REF):s.toLabel(),o=r?e.replace(i,a):a),o});return e.startsWith("=")||(e="=".concat(e)),e}},{key:"_translateCell",value:function(e,t,n,r){var o=e.start,i=e.end,a=o[t].index,s=i[t].index,l=n,u=n,c=!1;if(this.customModifier){var h=this.customModifier(e,t,n,r),d=(0,g.default)(h,3);l=d[0],u=d[1],c=d[2]}else o[t].isAbsolute&&(l=0),i[t].isAbsolute&&(u=0);l&&!c&&(a+l<0&&(c=!0),o[t].index=Math.max(a+l,0)),u&&!c&&(s+u<0&&(c=!0),i[t].index=Math.max(s+u,0)),c&&(e.refError=!0)}},{key:"_extractCells",value:function(){var a=this,e=this.expression.match(d);e&&(0,s.arrayEach)(e,function(e){var t=e.match(h);if(t){var n=(0,v.extractLabel)(t[0]),r=(0,g.default)(n,2),o=r[0],i=r[1];a.cells.push(a._createCell({row:o,column:i},{row:o,column:i},t[0]))}})}},{key:"_extractCellsRange",value:function(){var f=this,e=this.expression.match(p);e&&(0,s.arrayEach)(e,function(e){var t=e.split(":"),n=(0,g.default)(t,2),r=n[0],o=n[1],i=(0,v.extractLabel)(r),a=(0,g.default)(i,2),s=a[0],l=a[1],u=(0,v.extractLabel)(o),c=(0,g.default)(u,2),h={row:s,column:l},d={row:c[0],column:c[1]};f.cells.push(f._createCell(h,d,e))})}},{key:"_searchCell",value:function(t){var e=(0,s.arrayFilter)(this.cells,function(e){return e.origLabel===t});return(0,g.default)(e,1)[0]||null}},{key:"_createCell",value:function(e,t,n){return{start:e,end:t,origLabel:n,type:-1===n.indexOf(":")?"cell":"range",refError:!1,toLabel:function(){var e=(0,v.toLabel)(this.start.row,this.start.column);return"range"===this.type&&(e+=":".concat((0,v.toLabel)(this.end.row,this.end.column))),e}}}}]),t}();(0,a.mixin)(m,l.default);var y=m;t.default=y},function(e,t,n){var r=n(29),o=n(77),i="".split;e.exports=r(function(){return!Object("z").propertyIsEnumerable(0)})?function(e){return"String"==o(e)?i.call(e,""):Object(e)}:Object},function(e,t,n){var r=n(86),o=Math.max,i=Math.min;e.exports=function(e,t){var n=r(e);return n<0?o(n+t,0):i(n,t)}},function(e,t,n){var r=n(52),o=n(95),i=n(96),a=n(69),s=n(97),l=n(47),u=n(176),c=Object.getOwnPropertyDescriptor;t.f=r?c:function(e,t){if(e=a(e),t=s(t,!0),u)try{return c(e,t)}catch(e){}if(l(e,t))return i(!o.f.call(e,t),e[t])}},function(e,t){e.exports=!1},function(e,t,n){var r=n(98)("keys"),o=n(118);e.exports=function(e){return r[e]||(r[e]=o(e))}},function(e,t){var n=0,r=Math.random();e.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++n+r).toString(36))}},function(e,t){t.f=Object.getOwnPropertySymbols},function(e,t,n){var r=n(29),o=/#|\.prototype\./,i=function(e,t){var n=s[a(e)];return n==u||n!=l&&("function"==typeof t?r(t):!!t)},a=i.normalize=function(e){return String(e).replace(o,".").toLowerCase()},s=i.data={},l=i.NATIVE="N",u=i.POLYFILL="P";e.exports=i},function(e,t,n){var r=n(35)("unscopables"),o=n(99),i=n(61),a=Array.prototype;null==a[r]&&i(a,r,o(null)),e.exports=function(e){a[r][e]=!0}},function(e,t,n){var r=n(49).f,o=n(47),i=n(35)("toStringTag");e.exports=function(e,t,n){e&&!o(e=n?e:e.prototype,i)&&r(e,i,{configurable:!0,value:t})}},function(e,t,n){var r=n(118)("meta"),o=n(515),i=n(42),a=n(47),s=n(49).f,l=0,u=Object.isExtensible||function(){return!0},c=function(e){s(e,r,{value:{objectID:"O"+ ++l,weakData:{}}})},h=e.exports={REQUIRED:!1,fastKey:function(e,t){if(!i(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!a(e,r)){if(!u(e))return"F";if(!t)return"E";c(e)}return e[r].objectID},getWeakData:function(e,t){if(!a(e,r)){if(!u(e))return!0;if(!t)return!1;c(e)}return e[r].weakData},onFreeze:function(e){return o&&h.REQUIRED&&u(e)&&!a(e,r)&&c(e),e}};n(94)[r]=!0},function(e,t,n){var r=n(77);e.exports=Array.isArray||function(e){return"Array"==r(e)}},function(e,t,n){"use strict";var p=n(32),m=n(120),y=n(22),w=n(65),C=n(123),E=n(149),S=n(148),b=n(42),T=n(29),R=n(190),_=n(122),k=n(152);e.exports=function(r,e,t,o,i){var a=p[r],s=a&&a.prototype,l=a,u=o?"set":"add",n={},c=function(e){var n=s[e];w(s,e,"add"==e?function(e){return n.call(this,0===e?0:e),this}:"delete"==e?function(e){return!(i&&!b(e))&&n.call(this,0===e?0:e)}:"get"==e?function(e){return i&&!b(e)?void 0:n.call(this,0===e?0:e)}:"has"==e?function(e){return!(i&&!b(e))&&n.call(this,0===e?0:e)}:function(e,t){return n.call(this,0===e?0:e,t),this})};if(m(r,"function"!=typeof a||!(i||s.forEach&&!T(function(){(new a).entries().next()}))))l=t.getConstructor(e,r,o,u),C.REQUIRED=!0;else if(m(r,!0)){var h=new l,d=h[u](i?{}:-0,1)!=h,f=T(function(){h.has(1)}),g=R(function(e){new a(e)}),v=!i&&T(function(){for(var e=new a,t=5;t--;)e[u](t,t);return!e.has(-0)});g||(((l=e(function(e,t){S(e,l,r);var n=k(new a,e,l);return null!=t&&E(t,n[u],n,o),n})).prototype=s).constructor=l),(f||v)&&(c("delete"),c("has"),o&&c("get")),(v||d)&&c(u),i&&s.clear&&delete s.clear}return n[r]=l,y({global:!0,forced:l!=a},n),_(l,r),i||t.setStrong(l,r,o),l}},function(e,t,n){"use strict";var r=n(29);e.exports=function(e,t){var n=[][e];return!n||!r(function(){n.call(null,t||function(){throw 1},1)})}},function(e,t,n){"use strict";var o=n(97),i=n(49),a=n(96);e.exports=function(e,t,n){var r=o(t);r in e?i.f(e,r,a(0,n)):e[r]=n}},function(e,t,n){var o=n(77),i=n(156);e.exports=function(e,t){var n=e.exec;if("function"==typeof n){var r=n.call(e,t);if("object"!=typeof r)throw TypeError("RegExp exec method returned something other than an Object or null");return r}if("RegExp"!==o(e))throw TypeError("RegExp#exec called on incompatible receiver");return i.call(e,t)}},function(e,t,n){"use strict";var h=n(61),d=n(65),f=n(29),g=n(35),v=n(156),p=g("species"),m=!f(function(){var e=/./;return e.exec=function(){var e=[];return e.groups={a:"7"},e},"7"!=="".replace(e,"$<a>")}),y=!f(function(){var e=/(?:)/,t=e.exec;e.exec=function(){return t.apply(this,arguments)};var n="ab".split(e);return 2!==n.length||"a"!==n[0]||"b"!==n[1]});e.exports=function(n,e,t,r){var o=g(n),i=!f(function(){var e={};return e[o]=function(){return 7},7!=""[n](e)}),a=i&&!f(function(){var e=!1,t=/a/;return t.exec=function(){return e=!0,null},"split"===n&&(t.constructor={},t.constructor[p]=function(){return t}),t[o](""),!e});if(!i||!a||"replace"===n&&!m||"split"===n&&!y){var s=/./[o],l=t(o,""[n],function(e,t,n,r,o){return t.exec===v?i&&!o?{done:!0,value:s.call(t,n,r)}:{done:!0,value:e.call(n,t,r)}:{done:!1}}),u=l[0],c=l[1];d(String.prototype,n,u),d(RegExp.prototype,o,2==e?function(e,t){return c.call(e,this,t)}:function(e){return c.call(e,this)}),r&&h(RegExp.prototype[o],"sham",!0)}}},function(e,t,n){var r=n(52),o=n(35)("match"),i=n(32),a=n(120),s=n(152),l=n(49).f,u=n(93).f,c=n(154),h=n(153),d=n(65),f=n(29),g=i.RegExp,v=g.prototype,p=/a/g,m=/a/g,y=new g(p)!==p;if(a("RegExp",r&&(!y||f(function(){return m[o]=!1,g(p)!=p||g(m)==m||"/a/i"!=g(p,"i")})))){for(var w=function(e,t){var n=this instanceof w,r=c(e),o=void 0===t;return!n&&r&&e.constructor===w&&o?e:s(y?new g(r&&!o?e.source:e,t):g((r=e instanceof w)?e.source:e,r&&o?h.call(e):t),n?this:v,w)},C=function(t){t in w||l(w,t,{configurable:!0,get:function(){return g[t]},set:function(e){g[t]=e}})},E=u(g),S=0;S<E.length;)C(E[S++]);(v.constructor=w).prototype=v,d(i,"RegExp",w)}n(193)("RegExp")},function(e,t,n){"use strict";var h=n(45),d=n(48),o=n(58),f=n(155),g=n(128);n(129)("match",1,function(r,u,c){return[function(e){var t=o(this),n=null==e?void 0:e[r];return void 0!==n?n.call(e,t):new RegExp(e)[r](String(t))},function(e){var t=c(u,e,this);if(t.done)return t.value;var n=h(e),r=String(this);if(!n.global)return g(n,r);for(var o,i=n.unicode,a=[],s=n.lastIndex=0;null!==(o=g(n,r));){var l=String(o[0]);""===(a[s]=l)&&(n.lastIndex=f(r,d(n.lastIndex),i)),s++}return 0===s?null:a}]})},function(e,t,n){"use strict";n(470),t.__esModule=!0,t.spreadsheetColumnLabel=l,t.spreadsheetColumnIndex=function(e){var t=0;if(e)for(var n=0,r=e.length-1;n<e.length;n+=1,r-=1)t+=Math.pow(s,r)*(o.indexOf(e[n])+1);return t-=1},t.createSpreadsheetData=function(){var e,t,n=0<arguments.length&&void 0!==arguments[0]?arguments[0]:100,r=1<arguments.length&&void 0!==arguments[1]?arguments[1]:4,o=[];for(e=0;e<n;e++){var i=[];for(t=0;t<r;t++)i.push(l(t)+(e+1));o.push(i)}return o},t.createSpreadsheetObjectData=function(){var e,t,n=0<arguments.length&&void 0!==arguments[0]?arguments[0]:100,r=1<arguments.length&&void 0!==arguments[1]?arguments[1]:4,o=[];for(e=0;e<n;e++){var i={};for(t=0;t<r;t++)i["prop".concat(t)]=l(t)+(e+1);o.push(i)}return o},t.createEmptySpreadsheetData=function(e,t){for(var n,r=[],o=0;o<e;o++){n=[];for(var i=0;i<t;i++)n.push("");r.push(n)}return r},t.translateRowsToColumns=function(e){var t,n,r,o,i=[],a=0;for(t=0,n=e.length;t<n;t++)for(r=0,o=e[t].length;r<o;r++)r===a&&(i.push([]),a+=1),i[r].push(e[t][r]);return i},t.cellMethodLookupFactory=function(r,e){var o=void 0===e||e;return function(e,t){return function e(t){if(t){if((0,a.hasOwnProperty)(t,r)&&void 0!==t[r])return t[r];if((0,a.hasOwnProperty)(t,"type")&&t.type){if("string"!=typeof t.type)throw new Error("Cell type must be a string ");var n=(0,i.getCellType)(t.type);if((0,a.hasOwnProperty)(n,r))return n[r];if(o)return}return e(Object.getPrototypeOf(t))}}("number"==typeof e?this.getCellMeta(e,t):e)}};var i=n(160),a=n(4),o="ABCDEFGHIJKLMNOPQRSTUVWXYZ",s=o.length;function l(e){for(var t,n=e+1,r="";0<n;)t=(n-1)%s,r=String.fromCharCode(65+t)+r,n=parseInt((n-t)/s,10);return r}},function(e,t,n){"use strict";var r=n(32),a=n(47),o=n(52),i=n(116),s=n(22),l=n(65),u=n(94),c=n(29),h=n(98),d=n(122),f=n(118),g=n(35),v=n(473),p=n(474),m=n(577),y=n(124),w=n(45),C=n(42),E=n(69),S=n(97),b=n(96),T=n(99),R=n(174),_=n(115),k=n(49),O=n(95),M=n(61),N=n(89),A=n(117)("hidden"),I=n(87),D="Symbol",x=I.set,L=I.getterFor(D),H=_.f,P=k.f,F=R.f,V=r.Symbol,B=r.JSON,W=B&&B.stringify,U="prototype",j=g("toPrimitive"),Y=O.f,$=h("symbol-registry"),G=h("symbols"),z=h("op-symbols"),X=h("wks"),K=Object[U],q=r.QObject,Z=n(180),Q=!q||!q[U]||!q[U].findChild,J=o&&c(function(){return 7!=T(P({},"a",{get:function(){return P(this,"a",{value:7}).a}})).a})?function(e,t,n){var r=H(K,t);r&&delete K[t],P(e,t,n),r&&e!==K&&P(K,t,r)}:P,ee=function(e,t){var n=G[e]=T(V[U]);return x(n,{type:D,tag:e,description:t}),o||(n.description=t),n},te=Z&&"symbol"==typeof V.iterator?function(e){return"symbol"==typeof e}:function(e){return Object(e)instanceof V},ne=function(e,t,n){return e===K&&ne(z,t,n),w(e),t=S(t,!0),w(n),a(G,t)?(n.enumerable?(a(e,A)&&e[A][t]&&(e[A][t]=!1),n=T(n,{enumerable:b(0,!1)})):(a(e,A)||P(e,A,b(1,{})),e[A][t]=!0),J(e,t,n)):P(e,t,n)},re=function(e,t){w(e);for(var n,r=m(t=E(t)),o=0,i=r.length;o<i;)ne(e,n=r[o++],t[n]);return e},oe=function(e){var t=Y.call(this,e=S(e,!0));return!(this===K&&a(G,e)&&!a(z,e))&&(!(t||!a(this,e)||!a(G,e)||a(this,A)&&this[A][e])||t)},ie=function(e,t){if(e=E(e),t=S(t,!0),e!==K||!a(G,t)||a(z,t)){var n=H(e,t);return!n||!a(G,t)||a(e,A)&&e[A][t]||(n.enumerable=!0),n}},ae=function(e){for(var t,n=F(E(e)),r=[],o=0;n.length>o;)a(G,t=n[o++])||a(u,t)||r.push(t);return r},se=function(e){for(var t,n=e===K,r=F(n?z:E(e)),o=[],i=0;r.length>i;)!a(G,t=r[i++])||n&&!a(K,t)||o.push(G[t]);return o};Z||(l((V=function(){if(this instanceof V)throw TypeError("Symbol is not a constructor");var e=void 0===arguments[0]?void 0:String(arguments[0]),t=f(e),n=function(e){this===K&&n.call(z,e),a(this,A)&&a(this[A],t)&&(this[A][t]=!1),J(this,t,b(1,e))};return o&&Q&&J(K,t,{configurable:!0,set:n}),ee(t,e)})[U],"toString",function(){return L(this).tag}),O.f=oe,k.f=ne,_.f=ie,n(93).f=R.f=ae,n(119).f=se,o&&(P(V[U],"description",{configurable:!0,get:function(){return L(this).description}}),i||l(K,"propertyIsEnumerable",oe,{unsafe:!0})),v.f=function(e){return ee(g(e),e)}),s({global:!0,wrap:!0,forced:!Z,sham:!Z},{Symbol:V});for(var le=N(X),ue=0;le.length>ue;)p(le[ue++]);s({target:D,stat:!0,forced:!Z},{for:function(e){return a($,e+="")?$[e]:$[e]=V(e)},keyFor:function(e){if(!te(e))throw TypeError(e+" is not a symbol");for(var t in $)if($[t]===e)return t},useSetter:function(){Q=!0},useSimple:function(){Q=!1}}),s({target:"Object",stat:!0,forced:!Z,sham:!o},{create:function(e,t){return void 0===t?T(e):re(T(e),t)},defineProperty:ne,defineProperties:re,getOwnPropertyDescriptor:ie}),s({target:"Object",stat:!0,forced:!Z},{getOwnPropertyNames:ae,getOwnPropertySymbols:se}),B&&s({target:"JSON",stat:!0,forced:!Z||c(function(){var e=V();return"[null]"!=W([e])||"{}"!=W({a:e})||"{}"!=W(Object(e))})},{stringify:function(e){for(var t,n,r=[e],o=1;arguments.length>o;)r.push(arguments[o++]);if(n=t=r[1],(C(t)||void 0!==e)&&!te(e))return y(t)||(t=function(e,t){if("function"==typeof n&&(t=n.call(this,e,t)),!te(t))return t}),r[1]=t,W.apply(B,r)}}),V[U][j]||M(V[U],j,V[U].valueOf),d(V,D),u[A]=!0},function(e,t,n){"use strict";var r=n(52),o=n(47),i=n(42),a=n(49).f,s=n(179),l=n(32).Symbol;if(r&&"function"==typeof l&&(!("description"in l.prototype)||void 0!==l().description)){var u={},c=function(){var e=arguments.length<1||void 0===arguments[0]?void 0:String(arguments[0]),t=this instanceof c?new l(e):void 0===e?l():l(e);return""===e&&(u[t]=!0),t};s(c,l);var h=c.prototype=l.prototype;h.constructor=c;var d=h.toString,f="Symbol(test)"==String(l("test")),g=/^Symbol\((.*)\)[^)]+$/;a(h,"description",{configurable:!0,get:function(){var e=i(this)?this.valueOf():this,t=d.call(e);if(o(u,e))return"";var n=f?t.slice(7,-1):t.replace(g,"$1");return""===n?void 0:n}}),n(22)({global:!0,forced:!0},{Symbol:c})}},function(e,t,n){"use strict";var r=n(0);t.__esModule=!0,t.registerLanguageDictionary=g,t.getLanguageDictionary=function(e){return v(e)?(0,o.deepClone)(h(e)):null},t.hasLanguageDictionary=v,t.getDefaultLanguageDictionary=function(){return s.default},t.getLanguagesDictionaries=function(){return f()},t.DEFAULT_LANGUAGE_CODE=void 0;var o=n(4),i=n(477),a=r(n(78)),s=r(n(578)),l=s.default.languageCode;t.DEFAULT_LANGUAGE_CODE=l;var u=(0,a.default)("languagesDictionaries"),c=u.register,h=u.getItem,d=u.hasItem,f=u.getValues;function g(e,t){var n=e,r=t;return(0,o.isObject)(e)&&(n=(r=e).languageCode),function(e,t){e!==l&&(0,i.extendNotExistingKeys)(t,h(l))}(n,r),c(n,(0,o.deepClone)(r)),(0,o.deepClone)(r)}function v(e){return d(e)}g(s.default)},function(e,t,n){"use strict";var r=n(0);n(59),n(16),n(10),n(82),n(14),n(17),t.__esModule=!0,t._getRefCount=function(){return l},t._resetState=u,t.isPressed=function(t){return Array.from(s.values()).some(function(e){return(0,i.isKey)(e,t)})},t.isPressedCtrlKey=function(){return Array.from(s.values()).some(function(e){return(0,i.isCtrlMetaKey)(e)})},t.startObserving=function(e){0===l&&(a.addEventListener(e,"keydown",function(e){s.has(e.keyCode)||s.add(e.keyCode)}),a.addEventListener(e,"keyup",function(e){s.has(e.keyCode)&&s.delete(e.keyCode)}),a.addEventListener(e,"visibilitychange",function(){e.hidden&&s.clear()}),a.addEventListener(e.defaultView,"blur",function(){s.clear()}));l+=1},t.stopObserving=function(){0<l&&(l-=1);0===l&&u()};var o=r(n(23)),i=n(50),a=new o.default,s=new Set,l=0;function u(){a.clearEvents(),s.clear(),l=0}},function(e,t,n){"use strict";var r=n(0);n(133),n(134),n(59),n(34),n(16),n(64),n(10),n(82),n(39),n(14),n(17),t.__esModule=!0,t.detectSelectionType=y,t.normalizeSelectionFactory=i,t.transformSelectionToColumnDistance=function(e){var t=y(e);if(t===c||t===h)return[];var a=i(t),s=new Set;(0,u.arrayEach)(e,function(e){var t=a(e),n=(0,l.default)(t,4),r=n[1],o=n[3],i=o-r+1;(0,u.arrayEach)(Array.from(new Array(i),function(e,t){return r+t}),function(e){s.has(e)||s.add(e)})});var n=Array.from(s).sort(function(e,t){return e-t});return(0,u.arrayReduce)(n,function(e,t,n,r){return 0!==n&&t===r[n-1]+1?e[e.length-1][1]+=1:e.push([t,1]),e},[])},t.transformSelectionToRowDistance=function(e){var t=y(e);if(t===c||t===h)return[];var a=i(t),s=new Set;(0,u.arrayEach)(e,function(e){var t=a(e),n=(0,l.default)(t,3),r=n[0],o=n[2],i=o-r+1;(0,u.arrayEach)(Array.from(new Array(i),function(e,t){return r+t}),function(e){s.has(e)||s.add(e)})});var n=Array.from(s).sort(function(e,t){return e-t});return(0,u.arrayReduce)(n,function(e,t,n,r){return 0!==n&&t===r[n-1]+1?e[e.length-1][1]+=1:e.push([t,1]),e},[])},t.isValidCoord=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:1/0;return"number"==typeof e&&0<=e&&e<t},t.SELECTION_TYPES=t.SELECTION_TYPE_OBJECT=t.SELECTION_TYPE_ARRAY=t.SELECTION_TYPE_EMPTY=t.SELECTION_TYPE_UNRECOGNIZED=void 0;var l=r(n(19)),a=r(n(44)),s=n(25),u=n(3),f=n(27),c=0;t.SELECTION_TYPE_UNRECOGNIZED=c;var h=1;t.SELECTION_TYPE_EMPTY=h;var d=2;t.SELECTION_TYPE_ARRAY=d;var g=3,o=[t.SELECTION_TYPE_OBJECT=g,d];t.SELECTION_TYPES=o;var v=[["number"],["number","string"],["number","undefined"],["number","string","undefined"]],p=Symbol("root"),m=Symbol("child");function y(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:p;if(t!==p&&t!==m)throw new Error("The second argument is used internally only and cannot be overwritten.");var n=Array.isArray(e),r=t===p,o=c;if(n){var i=e[0];if(0===e.length)o=h;else if(r&&i instanceof s.CellRange)o=g;else if(r&&Array.isArray(i))o=y(i,m);else if(2<=e.length&&e.length<=4){!e.some(function(e,t){return!v[t].includes((0,a.default)(e))})&&(o=d)}}return o}function i(c){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{},t=e.keepDirection,h=void 0!==t&&t,d=e.propToCol;if(!o.includes(c))throw new Error("Unsupported selection ranges schema type was provided.");return function(e){var t=c===g,n=t?e.from.row:e[0],r=t?e.from.col:e[1],o=t?e.to.row:e[2],i=t?e.to.col:e[3];if("function"==typeof d&&("string"==typeof r&&(r=d(r)),"string"==typeof i&&(i=d(i))),(0,f.isUndefined)(o)&&(o=n),(0,f.isUndefined)(i)&&(i=r),!h){var a=n,s=r,l=o,u=i;n=Math.min(a,l),r=Math.min(s,u),o=Math.max(a,l),i=Math.max(s,u)}return[n,r,o,i]}}},function(e,t,n){"use strict";var o=n(48),i=n(157),a="startsWith",r=n(158)(a),s=""[a];n(22)({target:"String",proto:!0,forced:!r},{startsWith:function(e){var t=i(this,e,a),n=o(Math.min(1<arguments.length?arguments[1]:void 0,t.length)),r=String(e);return s?s.call(t,r,n):t.slice(n,n+r.length)===r}})},function(e,t,n){"use strict";var r=n(0);t.__esModule=!0,t.default=void 0;var o=r(n(1)),i=r(n(2)),a=n(3),s=n(4),l=r(n(57)),u=r(n(707)),c=function(){function t(e){(0,o.default)(this,t),this.hot=e,this.elements=[],this.hidden=!1}return(0,i.default)(t,[{key:"reset",value:function(){(0,a.arrayEach)(this.elements,function(e){return e.reset()})}},{key:"hide",value:function(){this.hidden=!0}},{key:"show",value:function(){this.hidden=!1}},{key:"isHidden",value:function(){return this.hidden}},{key:"destroy",value:function(){this.clearLocalHooks(),(0,a.arrayEach)(this.elements,function(e){return e.destroy()}),this.elements=null,this.hot=null}}]),t}();(0,s.mixin)(c,l.default),(0,s.mixin)(c,u.default);var h=c;t.default=h},function(e,t,n){var l=n(69),u=n(48),c=n(114);e.exports=function(s){return function(e,t,n){var r,o=l(e),i=u(o.length),a=c(n,i);if(s&&t!=t){for(;a<i;)if((r=o[a++])!=r)return!0}else for(;a<i;a++)if((s||a in o)&&o[a]===t)return s||a||0;return!s&&-1}}},function(e,t){e.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},function(e,t,n){var r=n(42),o=n(32).document,i=r(o)&&r(o.createElement);e.exports=function(e){return i?o.createElement(e):{}}},function(e,t,n){var r=n(32),o=n(61);e.exports=function(t,n){try{o(r,t,n)}catch(e){r[t]=n}return n}},function(e,t,n){"use strict";var m=n(22),y=n(512),w=n(145),C=n(184),E=n(122),S=n(61),b=n(65),T=n(116),R=n(35)("iterator"),_=n(100),r=n(182),k=r.IteratorPrototype,O=r.BUGGY_SAFARI_ITERATORS,M="values",N=function(){return this};e.exports=function(e,t,n,r,o,i,a){y(n,t,r);var s,l,u,c=function(e){if(e===o&&v)return v;if(!O&&e in f)return f[e];switch(e){case"keys":case M:case"entries":return function(){return new n(this,e)}}return function(){return new n(this)}},h=t+" Iterator",d=!1,f=e.prototype,g=f[R]||f["@@iterator"]||o&&f[o],v=!O&&g||c(o),p="Array"==t&&f.entries||g;if(p&&(s=w(p.call(new e)),k!==Object.prototype&&s.next&&(T||w(s)===k||(C?C(s,k):"function"!=typeof s[R]&&S(s,R,N)),E(s,h,!0,!0),T&&(_[h]=N))),o==M&&g&&g.name!==M&&(d=!0,v=function(){return g.call(this)}),T&&!a||f[R]===v||S(f,R,v),_[t]=v,o)if(l={values:c(M),keys:i?v:c("keys"),entries:c("entries")},a)for(u in l)!O&&!d&&u in f||b(f,u,l[u]);else m({target:t,proto:!0,forced:O||d},l);return l}},function(e,t,n){var r=n(47),o=n(62),i=n(117)("IE_PROTO"),a=n(183),s=Object.prototype;e.exports=a?Object.getPrototypeOf:function(e){return e=o(e),r(e,i)?e[i]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?s:null}},function(e,t,n){var l=n(86),u=n(58);e.exports=function(e,t,n){var r,o,i=String(u(e)),a=l(t),s=i.length;return a<0||s<=a?n?"":void 0:(r=i.charCodeAt(a))<55296||56319<r||a+1===s||(o=i.charCodeAt(a+1))<56320||57343<o?n?i.charAt(a):r:n?i.slice(a,a+2):o-56320+(r-55296<<10)+65536}},function(e,t,n){var o=n(65);e.exports=function(e,t,n){for(var r in t)o(e,r,t[r],n);return e}},function(e,t){e.exports=function(e,t,n){if(!(e instanceof t))throw TypeError("Incorrect "+(n?n+" ":"")+"invocation");return e}},function(e,t,n){var h=n(45),d=n(187),f=n(48),g=n(101),v=n(188),p=n(189),m={};(e.exports=function(e,t,n,r,o){var i,a,s,l,u,c=g(t,n,r?2:1);if(o)i=e;else{if("function"!=typeof(a=v(e)))throw TypeError("Target is not iterable");if(d(a)){for(s=0,l=f(e.length);s<l;s++)if((r?c(h(u=e[s])[0],u[1]):c(e[s]))===m)return m;return}i=a.call(e)}for(;!(u=i.next()).done;)if(p(i,c,u.value,r)===m)return m}).BREAK=m},function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(String(e)+" is not a function");return e}},function(e,t,n){var r=n(42),o=n(124),i=n(35)("species");e.exports=function(e,t){var n;return o(e)&&("function"!=typeof(n=e.constructor)||n!==Array&&!o(n.prototype)?r(n)&&null===(n=n[i])&&(n=void 0):n=void 0),new(void 0===n?Array:n)(0===t?0:t)}},function(e,t,n){var i=n(42),a=n(184);e.exports=function(e,t,n){var r,o=t.constructor;return o!==n&&"function"==typeof o&&(r=o.prototype)!==n.prototype&&i(r)&&a&&a(e,r),e}},function(e,t,n){"use strict";var r=n(45);e.exports=function(){var e=r(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},function(e,t,n){var r=n(42),o=n(77),i=n(35)("match");e.exports=function(e){var t;return r(e)&&(void 0!==(t=e[i])?!!t:"RegExp"==o(e))}},function(e,t,n){"use strict";var r=n(146);e.exports=function(e,t,n){return t+(n?r(e,t,!0).length:1)}},function(e,t,n){"use strict";var r,o,i=n(153),a=RegExp.prototype.exec,s=String.prototype.replace,l=a,u=(r=/a/,o=/b*/g,a.call(r,"a"),a.call(o,"a"),0!==r.lastIndex||0!==o.lastIndex),c=void 0!==/()??/.exec("")[1];(u||c)&&(l=function(e){var t,n,r,o;return c&&(n=new RegExp("^"+this.source+"$(?!\\s)",i.call(this))),u&&(t=this.lastIndex),r=a.call(this,e),u&&r&&(this.lastIndex=this.global?r.index+r[0].length:t),c&&r&&1<r.length&&s.call(r[0],n,function(){for(o=1;o<arguments.length-2;o++)void 0===arguments[o]&&(r[o]=void 0)}),r}),e.exports=l},function(e,t,n){var r=n(154),o=n(58);e.exports=function(e,t,n){if(r(t))throw TypeError("String.prototype."+n+" doesn't accept regex");return String(o(e))}},function(e,t,n){var r=n(35)("match");e.exports=function(t){var n=/./;try{"/./"[t](n)}catch(e){try{return n[r]=!1,"/./"[t](n)}catch(e){}}return!1}},function(e,t,n){"use strict";var r=n(102)(5),o=!0;"find"in[]&&Array(1).find(function(){o=!1}),n(22)({target:"Array",proto:!0,forced:o},{find:function(e){return r(this,e,1<arguments.length?arguments[1]:void 0)}}),n(121)("find")},function(e,t,n){"use strict";var r=n(0);t.__esModule=!0,t.registerCellType=b,t.getCellType=function(e){if(C(e))return w(e);throw Error('You declared cell type "'.concat(e,'" as a string that is not mapped to a known object.\n Cell type must be an object or a string mapped to an object registered by "Handsontable.cellTypes.registerCellType" method'))},t.getRegisteredCellTypes=t.getRegisteredCellTypeNames=t.hasCellType=void 0;var o=r(n(78)),i=n(53),a=n(41),s=n(79),l=r(n(560)),u=r(n(561)),c=r(n(562)),h=r(n(563)),d=r(n(564)),f=r(n(565)),g=r(n(566)),v=r(n(567)),p=r(n(568)),m=(0,o.default)("cellTypes"),y=m.register,w=m.getItem,C=m.hasItem,E=m.getNames,S=m.getValues;function b(e,t){var n=t.editor,r=t.renderer,o=t.validator;n&&(0,i.registerEditor)(e,n),r&&(0,a.registerRenderer)(e,r),o&&(0,s.registerValidator)(e,o),y(e,t)}t.getRegisteredCellTypes=S,t.getRegisteredCellTypeNames=E,t.hasCellType=C,b("autocomplete",l.default),b("checkbox",u.default),b("date",c.default),b("dropdown",h.default),b("handsontable",d.default),b("numeric",f.default),b("password",g.default),b("text",v.default),b("time",p.default)},function(e,t,n){"use strict";var r=n(0);n(18),n(59),n(12),n(64),n(33),n(80),n(81),n(14),n(37),n(570),n(30),t.__esModule=!0,t.default=function(e,t){var V,g,c,v,p,d=this,n=2<arguments.length&&void 0!==arguments[2]&&arguments[2],f=!1,B=this,m=function(){},r=new u.default(B);(0,Y.extend)(m.prototype,q.default.prototype),(0,Y.extend)(m.prototype,t),(0,Y.extend)(m.prototype,R(t)),(0,ee.applyLanguageSetting)(m.prototype,t.language),(0,z.hasValidParameter)(n)&&(0,z.registerAsRootInstance)(this);this.rootElement=e,this.rootDocument=e.ownerDocument,this.rootWindow=this.rootDocument.defaultView,(0,te.startObserving)(this.rootDocument),this.isDestroyed=!1,this.isHotTableEnv=(0,k.isChildOfWebComponentTable)(this.rootElement),u.default.isHotTableEnv=this.isHotTableEnv,this.container=this.rootDocument.createElement("div"),this.renderCall=!1,e.insertBefore(this.container,e.firstChild),(0,z.isRootInstance)(this)&&(0,j._injectProductInfo)(t.licenseKey,e);this.guid="ht_".concat((0,L.randomString)());var y=(0,G.getTranslator)(B);c=new F.default(B),this.rootElement.id&&"ht_"!==this.rootElement.id.substring(0,3)||(this.rootElement.id=this.guid);V={cellSettings:[],columnSettings:[],columnsSettingConflicts:["data","width","language"],settings:new m,selRange:null,isPopulated:null,scrollable:null,firstRun:!0};var w=new ne.Selection(V.settings,{countCols:function(){return B.countCols()},countRows:function(){return B.countRows()},propToCol:function(e){return g.propToCol(e)},isEditorOpened:function(){return!!B.getActiveEditor()&&B.getActiveEditor().isOpened()}});function C(e){var t=(0,ee.normalizeLanguageCode)(e);(0,J.hasLanguageDictionary)(t)?(B.runHooks("beforeLanguageChange",t),m.prototype.language=t,B.runHooks("afterLanguageChange",t)):(0,ee.warnUserAboutLanguageRegistration)(e)}function E(){var e=!1;return{validatorsInQueue:0,valid:!0,addValidatorToQueue:function(){this.validatorsInQueue+=1,e=!1},removeValidatorFormQueue:function(){this.validatorsInQueue=this.validatorsInQueue-1<0?0:this.validatorsInQueue-1,this.checkIfQueueIsEmpty()},onQueueEmpty:function(){},checkIfQueueIsEmpty:function(){0===this.validatorsInQueue&&!1===e&&(e=!0,this.onQueueEmpty(this.valid))}}}function S(e){var t=e.replace(",",".");return!1===isNaN(parseFloat(t))?parseFloat(t):e}function h(o,e,t){if(o.length){var n=B.runHooks("beforeChange",o,e||"edit");if((0,M.isFunction)(n))(0,N.warn)("Your beforeChange callback returns a function. It's not supported since Handsontable 0.12.1 (and the returned function will not be executed).");else if(!1===n){var r=B.getActiveEditor();return void(r&&r.cancelChanges())}var i=new E,a=function(e){return 0<e.length&&/^\s*[+-.]?\s*(?:(?:\d+(?:(\.|,)\d+)?(?:e[+-]?\d+)?)|(?:0x[a-f\d]+))\s*$/.test(e)};i.onQueueEmpty=t;for(var s=o.length-1;0<=s;s--)if(null===o[s])o.splice(s,1);else{var l=(0,_.default)(o[s],4),u=l[0],c=l[1],h=l[3],d=g.propToCol(c),f=B.getCellMeta(u,d);"numeric"===f.type&&"string"==typeof h&&a(h)&&(o[s][3]=S(h)),B.getCellValidator(f)&&(i.addValidatorToQueue(),B.validateCell(o[s][3],f,function(n,r){return function(e){if("boolean"!=typeof e)throw new Error("Validation error: result is not boolean");if(!1===e&&!1===r.allowInvalid){o.splice(n,1),r.valid=!0;var t=B.getCell(r.visualRow,r.visualCol);null!==t&&(0,k.removeClass)(t,B.getSettings().invalidCellClassName)}i.removeValidatorFormQueue()}}(s,f),e))}i.checkIfQueueIsEmpty()}}function b(e,t){var n=e.length-1;if(!(n<0)){for(;0<=n;n--){var r=!1;if(null!==e[n]){if(null!==e[n][2]&&void 0!==e[n][2]||null!==e[n][3]&&void 0!==e[n][3]){if(V.settings.allowInsertRow)for(;e[n][0]>B.countRows()-1;){var o=g.createRow(void 0,void 0,t);if(0===o){r=!0;break}}if(!r){if("array"===B.dataType&&(!V.settings.columns||0===V.settings.columns.length)&&V.settings.allowInsertColumn)for(;g.propToCol(e[n][1])>B.countCols()-1;)g.createCol(void 0,void 0,t);g.set(e[n][0],e[n][1],e[n][3])}}}else e.splice(n,1)}B.forceFullRender=!0,v.adjustRowsAndCols(),B.runHooks("beforeChangeRender",e,t),p.lockEditor(),B._refreshBorders(null),p.unlockEditor(),B.view.wt.wtOverlays.adjustElementsSize(),B.runHooks("afterChange",e,t||"edit");var i=B.getActiveEditor();i&&(0,j.isDefined)(i.refreshValue)&&i.refreshValue()}}function T(e,t,n){return"object"===(0,W.default)(e)?e:[[e,t,n]]}function R(e){if((0,Y.hasOwnProperty)(e,"type")){var t,n={};for(var r in"object"===(0,W.default)(e.type)?t=e.type:"string"==typeof e.type&&(t=(0,Z.getCellType)(e.type)),t)(0,Y.hasOwnProperty)(t,r)&&!(0,Y.hasOwnProperty)(e,r)&&(n[r]=t[r]);return n}}this.selection=w,this.selection.addLocalHook("beforeSetRangeStart",function(e){d.runHooks("beforeSetRangeStart",e)}),this.selection.addLocalHook("beforeSetRangeStartOnly",function(e){d.runHooks("beforeSetRangeStartOnly",e)}),this.selection.addLocalHook("beforeSetRangeEnd",function(e){d.runHooks("beforeSetRangeEnd",e),e.row<0&&(e.row=d.view.wt.wtTable.getFirstVisibleRow()),e.col<0&&(e.col=d.view.wt.wtTable.getFirstVisibleColumn())}),this.selection.addLocalHook("afterSetRangeEnd",function(e){var t=(0,Y.createObjectPropListener)(!1),n=d.selection.getSelectedRange(),r=n.current(),o=r.from,i=r.to,a=n.size()-1;d.runHooks("afterSelection",o.row,o.col,i.row,i.col,t,a),d.runHooks("afterSelectionByProp",o.row,B.colToProp(o.col),i.row,B.colToProp(i.col),t,a);var s=d.selection.isSelectedByAnyHeader(),l=d.selection.selectedRange.current(),u=!0;f&&(u=!1),t.isTouched()&&(u=!t.value);var c=d.selection.isSelectedByRowHeader(),h=d.selection.isSelectedByColumnHeader();!1!==u&&(s?c?d.view.scrollViewportVertically(e.row):h&&d.view.scrollViewportHorizontally(e.col):l&&!d.selection.isMultiple()?d.view.scrollViewport(l.from):d.view.scrollViewport(e)),c&&h?(0,k.addClass)(d.rootElement,["ht__selection--rows","ht__selection--columns"]):c?((0,k.removeClass)(d.rootElement,"ht__selection--columns"),(0,k.addClass)(d.rootElement,"ht__selection--rows")):h?((0,k.removeClass)(d.rootElement,"ht__selection--rows"),(0,k.addClass)(d.rootElement,"ht__selection--columns")):(0,k.removeClass)(d.rootElement,["ht__selection--rows","ht__selection--columns"]),d._refreshBorders(null)}),this.selection.addLocalHook("afterSelectionFinished",function(e){var t=e.length-1,n=e[t],r=n.from,o=n.to;d.runHooks("afterSelectionEnd",r.row,r.col,o.row,o.col,t),d.runHooks("afterSelectionEndByProp",r.row,B.colToProp(r.col),o.row,B.colToProp(o.col),t)}),this.selection.addLocalHook("afterIsMultipleSelection",function(e){var t=d.runHooks("afterIsMultipleSelection",e.value);e.value&&(e.value=t)}),this.selection.addLocalHook("beforeModifyTransformStart",function(e){d.runHooks("modifyTransformStart",e)}),this.selection.addLocalHook("afterModifyTransformStart",function(e,t,n){d.runHooks("afterModifyTransformStart",e,t,n)}),this.selection.addLocalHook("beforeModifyTransformEnd",function(e){d.runHooks("modifyTransformEnd",e)}),this.selection.addLocalHook("afterModifyTransformEnd",function(e,t,n){d.runHooks("afterModifyTransformEnd",e,t,n)}),this.selection.addLocalHook("afterDeselect",function(){p.destroyEditor(),d._refreshBorders(),(0,k.removeClass)(d.rootElement,["ht__selection--rows","ht__selection--columns"]),d.runHooks("afterDeselect")}),this.selection.addLocalHook("insertRowRequire",function(e){d.alter("insert_row",e,1,"auto")}),this.selection.addLocalHook("insertColRequire",function(e){d.alter("insert_col",e,1,"auto")}),v={alter:function(e,t){var n,u=2<arguments.length&&void 0!==arguments[2]?arguments[2]:1,c=3<arguments.length?arguments[3]:void 0,r=4<arguments.length?arguments[4]:void 0;function o(e,t,n,r){var o=(0,A.arrayMap)(new Array(n),function(){return function(){var e;"array"===r?e=[]:"object"===r&&(e={});return e}()});o.unshift(t,0),e.splice.apply(e,(0,U.default)(o))}var i=function(e){if(0===e.length)return[];var t=(0,U.default)(e);t.sort(function(e,t){var n=(0,_.default)(e,1),r=n[0],o=(0,_.default)(t,1),i=o[0];return r===i?0:i<r?1:-1});var n=(0,A.arrayReduce)(t,function(e,t){var n=(0,_.default)(t,2),r=n[0],o=n[1],i=e[e.length-1],a=(0,_.default)(i,2),s=a[0],l=a[1],u=s+l;if(r<=u){var c=Math.max(o-(u-r),0);i[1]+=c}else e.push([r,o]);return e},[t[0]]);return n};switch(e){case"insert_row":var a=B.countSourceRows();if(B.getSettings().maxRows===a)return;t=(0,j.isDefined)(t)?t:a,n=g.createRow(t,u,c),o(V.cellSettings,t,u,"array"),n&&(w.isSelected()&&w.selectedRange.current().from.row>=t?(w.selectedRange.current().from.row+=n,w.transformEnd(n,0)):B._refreshBorders());break;case"insert_col":n=g.createCol(t,u,c);for(var s=0,l=B.countSourceRows();s<l;s++)V.cellSettings[s]&&o(V.cellSettings[s],t,u);if(n){if(Array.isArray(B.getSettings().colHeaders)){var h=[t,0];h.length+=n,Array.prototype.splice.apply(B.getSettings().colHeaders,h)}w.isSelected()&&w.selectedRange.current().from.col>=t?(w.selectedRange.current().from.col+=n,w.transformEnd(0,n)):B._refreshBorders()}break;case"remove_row":var d=function(e){var l=0;(0,A.arrayEach)(e,function(e){var t=(0,_.default)(e,2),n=t[0],r=t[1],o=(0,j.isEmpty)(n)?B.countRows()-1:Math.max(n-l,0);Number.isInteger(n)&&(n=Math.max(n-l,0)),g.removeRow(n,r,c),V.cellSettings.splice(o,u);var i=B.countRows(),a=B.getSettings().fixedRowsTop;o+1<=a&&(B.getSettings().fixedRowsTop-=Math.min(r,a-o));var s=B.getSettings().fixedRowsBottom;s&&i-s<=o&&(B.getSettings().fixedRowsBottom-=Math.min(r,s)),l+=r})};Array.isArray(t)?d(i(t)):d([[t,u]]),v.adjustRowsAndCols(),B._refreshBorders();break;case"remove_col":var f=function(e){var u=0;(0,A.arrayEach)(e,function(e){var t=(0,_.default)(e,2),n=t[0],r=t[1],o=(0,j.isEmpty)(n)?B.countCols()-1:Math.max(n-u,0),i=y.toPhysicalColumn(o);Number.isInteger(n)&&(n=Math.max(n-u,0)),g.removeCol(n,r,c);for(var a=0,s=B.countSourceRows();a<s;a++)V.cellSettings[a]&&V.cellSettings[a].splice(i,r);var l=B.getSettings().fixedColumnsLeft;o+1<=l&&(B.getSettings().fixedColumnsLeft-=Math.min(r,l-o)),Array.isArray(B.getSettings().colHeaders)&&(void 0===i&&(i=-1),B.getSettings().colHeaders.splice(i,r)),u+=r})};Array.isArray(t)?f(i(t)):f([[t,u]]),v.adjustRowsAndCols(),B._refreshBorders();break;default:throw new Error('There is no such action "'.concat(e,'"'))}r||v.adjustRowsAndCols()},adjustRowsAndCols:function(){if(V.settings.minRows){var e=B.countRows();if(e<V.settings.minRows)for(var t=0,n=V.settings.minRows;t<n-e;t++)g.createRow(B.countRows(),1,"auto")}if(V.settings.minSpareRows){var r=B.countEmptyRows(!0);if(r<V.settings.minSpareRows)for(;r<V.settings.minSpareRows&&B.countSourceRows()<V.settings.maxRows;r++)g.createRow(B.countRows(),1,"auto")}var o;if((V.settings.minCols||V.settings.minSpareCols)&&(o=B.countEmptyCols(!0)),V.settings.minCols&&!V.settings.columns&&B.countCols()<V.settings.minCols)for(;B.countCols()<V.settings.minCols;o++)g.createCol(B.countCols(),1,"auto");if(V.settings.minSpareCols&&!V.settings.columns&&"array"===B.dataType&&o<V.settings.minSpareCols)for(;o<V.settings.minSpareCols&&B.countCols()<V.settings.maxCols;o++)g.createCol(B.countCols(),1,"auto");var a=B.countRows(),s=B.countCols();0!==a&&0!==s||w.deselect(),w.isSelected()&&(0,A.arrayEach)(w.selectedRange,function(e){var t=!1,n=e.from.row,r=e.from.col,o=e.to.row,i=e.to.col;a-1<n?(t=!0,(n=a-1)<o&&(o=n)):a-1<o&&(t=!0,(o=a-1)<n&&(n=o)),s-1<r?(t=!0,(r=s-1)<i&&(i=r)):s-1<i&&(t=!0,(i=s-1)<r&&(r=i)),t&&B.selectCell(n,r,o,i)}),B.view&&B.view.wt.wtOverlays.adjustElementsSize()},populateFromArray:function(e,r,t,n,o,i,a){var s,l,u,c,h,d,f,g,v=[],p={};if(0===(l=r.length))return!1;switch(o){case"shift_down":for(h=t?t.col-e.col+1:0,d=t?t.row-e.row+1:0,r=(0,$.translateRowsToColumns)(r),u=0,c=r.length,f=Math.max(c,h);u<f;u++)if(u<c){var m;for(s=0,l=r[u].length;s<d-l;s++)r[u].push(r[u][s%l]);r[u].unshift(e.col+u,e.row,0),(m=B).spliceCol.apply(m,(0,U.default)(r[u]))}else{var y;r[u%c][0]=e.col+u,(y=B).spliceCol.apply(y,(0,U.default)(r[u%c]))}break;case"shift_right":for(h=t?t.col-e.col+1:0,d=t?t.row-e.row+1:0,s=0,l=r.length,g=Math.max(l,d);s<g;s++)if(s<l){var w;for(u=0,c=r[s].length;u<h-c;u++)r[s].push(r[s][u%c]);r[s].unshift(e.row+s,e.col,0),(w=B).spliceRow.apply(w,(0,U.default)(r[s]))}else{var C;r[s%l][0]=e.row+s,(C=B).spliceRow.apply(C,(0,U.default)(r[s%l]))}break;case"overwrite":default:p.row=e.row,p.col=e.col;var E,S={row:t&&e?t.row-e.row+1:1,col:t&&e?t.col-e.col+1:1},b=0,T=0,R=!0,_=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:null,n=r[e%r.length];return null!==t?n[t%n.length]:n},k=r.length,O=t?t.row-e.row+1:0;for(l=t?O:Math.max(k,O),s=0;s<l&&!(t&&p.row>t.row&&k<O||!V.settings.allowInsertRow&&p.row>B.countRows()-1||p.row>=V.settings.maxRows);s++){var M=s-b,N=_(M).length,A=t?t.col-e.col+1:0;if(c=t?A:Math.max(N,A),p.col=e.col,E=B.getCellMeta(p.row,p.col),"CopyPaste.paste"!==n&&"Autofill.autofill"!==n||!E.skipRowOnPaste){for(u=T=0;u<c&&!(t&&p.col>t.col&&N<A||!V.settings.allowInsertColumn&&p.col>B.countCols()-1||p.col>=V.settings.maxCols);u++)if(E=B.getCellMeta(p.row,p.col),"CopyPaste.paste"!==n&&"Autofill.fill"!==n||!E.skipColumnOnPaste)if(E.readOnly)p.col+=1;else{var I=u-T,D=_(M,I),x=B.getDataAtCell(p.row,p.col),L={row:M,col:I};if("Autofill.fill"===n){var H=B.runHooks("beforeAutofillInsidePopulate",L,i,r,a,{},S);H&&(D=(0,j.isUndefined)(H.value)?D:H.value)}if(null!==D&&"object"===(0,W.default)(D))if(Array.isArray(D)&&null===x&&(x=[]),null===x||"object"!==(0,W.default)(x))R=!1;else{var P=(0,Y.duckSchema)(Array.isArray(x)?x:x[0]||x),F=(0,Y.duckSchema)(Array.isArray(D)?D:D[0]||D);(0,Y.isObjectEqual)(P,F)?D=(0,Y.deepClone)(D):R=!1}else null!==x&&"object"===(0,W.default)(x)&&(R=!1);R&&v.push([p.row,p.col,D]),R=!0,p.col+=1}else T+=1,p.col+=1,c+=1;p.row+=1}else b+=1,p.row+=1,l+=1}B.setDataAtCell(v,null,null,n||"populateFromArray")}}},this.init=function(){c.setData(V.settings.data),B.runHooks("beforeInit"),(0,a.isMobileBrowser)()&&(0,k.addClass)(B.rootElement,"mobile"),this.updateSettings(V.settings,!0),this.view=new P.default(this),p=l.default.getInstance(B,V,w,g),this.forceFullRender=!0,B.runHooks("init"),this.view.render(),"object"===(0,W.default)(V.firstRun)&&(B.runHooks("afterChange",V.firstRun[0],V.firstRun[1]),V.firstRun=!1),B.runHooks("afterInit")},this.validateCell=function(t,i,a,n){var e=B.getCellValidator(i);function r(e){var t=!(1<arguments.length&&void 0!==arguments[1])||arguments[1];if(t&&!0!==i.hidden){var n=i.visualCol,r=i.visualRow,o=B.getCell(r,n,!0);o&&"TH"!==o.nodeName&&B.view.wt.wtSettings.settings.cellRenderer(r,n,o),a(e)}else a(e)}(0,j.isRegExp)(e)&&(e=function(n){return function(e,t){t(n.test(e))}}(e)),(0,M.isFunction)(e)?(t=B.runHooks("beforeValidate",t,i.visualRow,i.prop,n),B._registerImmediate(function(){e.call(i,t,function(e){B&&(e=B.runHooks("afterValidate",e,t,i.visualRow,i.prop,n),r(i.valid=e),B.runHooks("postAfterValidate",e,t,i.visualRow,i.prop,n))})})):B._registerImmediate(function(){i.valid=!0,r(i.valid,!1)})},this.setDataAtCell=function(e,t,n,r){var o,i,a,s=T(e,t,n),l=[],u=r;for(o=0,i=s.length;o<i;o++){if("object"!==(0,W.default)(s[o]))throw new Error("Method `setDataAtCell` accepts row number or changes array of arrays as its first parameter");if("number"!=typeof s[o][1])throw new Error("Method `setDataAtCell` accepts row and column number as its parameters. If you want to use object property name, use method `setDataAtRowProp`");a=g.colToProp(s[o][1]),l.push([s[o][0],a,c.getAtCell(y.toPhysicalRow(s[o][0]),s[o][1]),s[o][2]])}u||"object"!==(0,W.default)(e)||(u=t),B.runHooks("afterSetDataAtCell",l,u),h(l,u,function(){b(l,u)})},this.setDataAtRowProp=function(e,t,n,r){var o,i,a=T(e,t,n),s=[],l=r;for(o=0,i=a.length;o<i;o++)s.push([a[o][0],a[o][1],c.getAtCell(y.toPhysicalRow(a[o][0]),a[o][1]),a[o][2]]);l||"object"!==(0,W.default)(e)||(l=t),B.runHooks("afterSetDataAtRowProp",s,l),h(s,l,function(){b(s,l)})},this.listen=function(){var e=!(0<arguments.length&&void 0!==arguments[0])||arguments[0],t=B,n=t.rootDocument;if(e){var r=!n.activeElement||n.activeElement&&void 0===n.activeElement.nodeName;n.activeElement&&n.activeElement!==n.body&&!r?n.activeElement.blur():r&&n.body.focus()}B&&!B.isListening()&&(re=B.guid,B.runHooks("afterListen"))},this.unlisten=function(){this.isListening()&&(re=null,B.runHooks("afterUnlisten"))},this.isListening=function(){return re===B.guid},this.destroyEditor=function(){var e=0<arguments.length&&void 0!==arguments[0]&&arguments[0],t=!(1<arguments.length&&void 0!==arguments[1])||arguments[1];B._refreshBorders(e,t)},this.populateFromArray=function(e,t,n,r,o,i,a,s,l){if("object"!==(0,W.default)(n)||"object"!==(0,W.default)(n[0]))throw new Error("populateFromArray parameter `input` must be an array of arrays");var u="number"==typeof r?new X.CellCoords(r,o):null;return v.populateFromArray(new X.CellCoords(e,t),n,u,i,a,s,l)},this.spliceCol=function(e,t,n){for(var r,o=arguments.length,i=new Array(3<o?o-3:0),a=3;a<o;a++)i[a-3]=arguments[a];return(r=g).spliceCol.apply(r,[e,t,n].concat(i))},this.spliceRow=function(e,t,n){for(var r,o=arguments.length,i=new Array(3<o?o-3:0),a=3;a<o;a++)i[a-3]=arguments[a];return(r=g).spliceRow.apply(r,[e,t,n].concat(i))},this.getSelected=function(){if(w.isSelected())return(0,A.arrayMap)(w.getSelectedRange(),function(e){var t=e.from,n=e.to;return[t.row,t.col,n.row,n.col]})},this.getSelectedLast=function(){var e,t=this.getSelected();return t&&0<t.length&&(e=t[t.length-1]),e},this.getSelectedRange=function(){if(w.isSelected())return Array.from(w.getSelectedRange())},this.getSelectedRangeLast=function(){var e,t=this.getSelectedRange();return t&&0<t.length&&(e=t[t.length-1]),e},this.emptySelectedCells=function(){var o=this;if(w.isSelected()){var i=[];(0,A.arrayEach)(w.getSelectedRange(),function(e){var n=e.getTopLeftCorner(),r=e.getBottomRightCorner();(0,H.rangeEach)(n.row,r.row,function(t){(0,H.rangeEach)(n.col,r.col,function(e){o.getCellMeta(t,e).readOnly||i.push([t,e,""])})})}),0<i.length&&this.setDataAtCell(i)}},this.render=function(){B.view&&(B.renderCall=!0,B.forceFullRender=!0,p.lockEditor(),B._refreshBorders(null),p.unlockEditor())},this.refreshDimensions=function(){if(B.view){var e=B.view.getLastSize(),t=e.width,n=e.height,r=B.rootElement.getBoundingClientRect(),o=r.width,i=r.height,a=o!==t||i!==n,s=!1===B.runHooks("beforeRefreshDimensions",{width:t,height:n},{width:o,height:i},a);s||((a||B.view.wt.wtOverlays.scrollableElement===B.rootWindow)&&(B.view.setLastSize(o,i),B.render()),B.runHooks("afterRefreshDimensions",{width:t,height:n},{width:o,height:i},a))}},this.loadData=function(e){if(Array.isArray(V.settings.dataSchema)?B.dataType="array":(0,M.isFunction)(V.settings.dataSchema)?B.dataType="function":B.dataType="object",g&&g.destroy(),g=new s.default(B,V,m),"object"===(0,W.default)(e)&&null!==e)e.push&&e.splice||(e=[e]);else{if(null!==e)throw new Error("loadData only accepts array of objects or array of arrays (".concat((0,W.default)(e)," given)"));var t,n=g.getSchema();e=[];var r=0,o=0;for(r=0,o=V.settings.startRows;r<o;r++)if("object"!==B.dataType&&"function"!==B.dataType||!V.settings.dataSchema)if("array"===B.dataType)t=(0,Y.deepClone)(n[0]),e.push(t);else{t=[];for(var i=0,a=V.settings.startCols;i<a;i++)t.push(null);e.push(t)}else t=(0,Y.deepClone)(n),e.push(t)}V.isPopulated=!1,m.prototype.data=e,Array.isArray(e[0])&&(B.dataType="array"),g.dataSource=e,c.data=e,c.dataType=B.dataType,c.colToProp=g.colToProp.bind(g),c.propToCol=g.propToCol.bind(g),V.cellSettings.length=0,v.adjustRowsAndCols(),B.runHooks("afterLoadData",V.firstRun),V.firstRun?V.firstRun=[null,"loadData"]:(B.runHooks("afterChange",null,"loadData"),B.render()),V.isPopulated=!0},this.getData=function(e,t,n,r){return(0,j.isUndefined)(e)?g.getAll():g.getRange(new X.CellCoords(e,t),new X.CellCoords(n,r),g.DESTINATION_RENDERER)},this.getCopyableText=function(e,t,n,r){return g.getCopyableText(new X.CellCoords(e,t),new X.CellCoords(n,r))},this.getCopyableData=function(e,t){return g.getCopyable(e,g.colToProp(t))},this.getSchema=function(){return g.getSchema()},this.updateSettings=function(e){var t,n,r,o=1<arguments.length&&void 0!==arguments[1]&&arguments[1],i=!1;if((0,j.isDefined)(e.rows))throw new Error('"rows" setting is no longer supported. do you mean startRows, minRows or maxRows?');if((0,j.isDefined)(e.cols))throw new Error('"cols" setting is no longer supported. do you mean startCols, minCols or maxCols?');for(t in e)"data"!==t&&("language"!==t?-1<K.default.getSingleton().getRegistered().indexOf(t)?((0,M.isFunction)(e[t])||Array.isArray(e[t]))&&(e[t].initialHook=!0,B.addHook(t,e[t])):!o&&(0,Y.hasOwnProperty)(e,t)&&(m.prototype[t]=e[t]):C(e.language));void 0===e.data&&void 0===V.settings.data?B.loadData(null):void 0!==e.data?B.loadData(e.data):void 0!==e.columns&&g.createMap(),r=B.countCols();var a,s,l=e.columns||m.prototype.columns;if(l&&(0,M.isFunction)(l)&&(r=B.countSourceCols(),i=!0),void 0===e.cell&&void 0===e.cells&&void 0===e.columns||(V.cellSettings.length=0),0<r)for(n=t=0;t<r;t++)i&&!l(t)||(V.columnSettings[n]=(0,O.columnFactory)(m,V.columnsSettingConflicts),a=V.columnSettings[n].prototype,l&&(s=i?l(t):l[n])&&((0,Y.extend)(a,s),(0,Y.extend)(a,R(s))),n+=1);(0,j.isDefined)(e.cell)&&(0,Y.objectEach)(e.cell,function(e){B.setCellMetaObject(e.row,e.col,e)}),B.runHooks("afterCellMetaReset"),(0,j.isDefined)(e.className)&&(m.prototype.className&&(0,k.removeClass)(B.rootElement,m.prototype.className),e.className&&(0,k.addClass)(B.rootElement,e.className));var u=B.rootElement.style.height;""!==u&&(u=parseInt(B.rootElement.style.height,10));var c=e.height;if((0,M.isFunction)(c)&&(c=c()),o){var h=B.rootElement.getAttribute("style");h&&B.rootElement.setAttribute("data-initialstyle",B.rootElement.getAttribute("style"))}if(null===c){var d=B.rootElement.getAttribute("data-initialstyle");d&&(-1<d.indexOf("height")||-1<d.indexOf("overflow"))?B.rootElement.setAttribute("style",d):(B.rootElement.style.height="",B.rootElement.style.overflow="")}else void 0!==c&&(B.rootElement.style.height=isNaN(c)?"".concat(c):"".concat(c,"px"),B.rootElement.style.overflow="hidden");if(void 0!==e.width){var f=e.width;(0,M.isFunction)(f)&&(f=f()),B.rootElement.style.width=isNaN(f)?"".concat(f):"".concat(f,"px")}o||(g.clearLengthCache(),B.view&&B.view.wt.wtViewport.resetHasOversizedColumnHeadersMarked(),B.runHooks("afterUpdateSettings",e)),v.adjustRowsAndCols(),B.view&&!V.firstRun&&(B.forceFullRender=!0,p.lockEditor(),B._refreshBorders(null),p.unlockEditor()),o||!B.view||""!==u&&""!==c&&void 0!==c||u===c||B.view.wt.wtOverlays.updateMainScrollableElements()},this.getValue=function(){var e=B.getSelectedLast();if(m.prototype.getValue){if((0,M.isFunction)(m.prototype.getValue))return m.prototype.getValue.call(B);if(e)return B.getData()[e[0][0]][m.prototype.getValue]}else if(e)return B.getDataAtCell(e[0],e[1])},this.getSettings=function(){return V.settings},this.clear=function(){this.selectAll(),this.emptySelectedCells()},this.alter=function(e,t,n,r,o){v.alter(e,t,n,r,o)},this.getCell=function(e,t){var n=2<arguments.length&&void 0!==arguments[2]&&arguments[2];return B.view.getCellAtCoords(new X.CellCoords(e,t),n)},this.getCoords=function(e){return this.view.wt.wtTable.getCoords.call(this.view.wt.wtTable,e)},this.colToProp=function(e){return g.colToProp(e)},this.propToCol=function(e){return g.propToCol(e)},this.toVisualRow=function(e){return y.toVisualRow(e)},this.toVisualColumn=function(e){return y.toVisualColumn(e)},this.toPhysicalRow=function(e){return y.toPhysicalRow(e)},this.toPhysicalColumn=function(e){return y.toPhysicalColumn(e)},this.getDataAtCell=function(e,t){return g.get(e,g.colToProp(t))},this.getDataAtRowProp=function(e,t){return g.get(e,t)},this.getDataAtCol=function(e){var t;return(t=[]).concat.apply(t,(0,U.default)(g.getRange(new X.CellCoords(0,e),new X.CellCoords(V.settings.data.length-1,e),g.DESTINATION_RENDERER)))},this.getDataAtProp=function(e){var t,n=g.getRange(new X.CellCoords(0,g.propToCol(e)),new X.CellCoords(V.settings.data.length-1,g.propToCol(e)),g.DESTINATION_RENDERER);return(t=[]).concat.apply(t,(0,U.default)(n))},this.getSourceData=function(e,t,n,r){return void 0===e?c.getData():c.getByRange(new X.CellCoords(e,t),new X.CellCoords(n,r))},this.getSourceDataArray=function(e,t,n,r){return void 0===e?c.getData(!0):c.getByRange(new X.CellCoords(e,t),new X.CellCoords(n,r),!0)},this.getSourceDataAtCol=function(e){return c.getAtColumn(e)},this.getSourceDataAtRow=function(e){return c.getAtRow(e)},this.getSourceDataAtCell=function(e,t){return c.getAtCell(e,t)},this.getDataAtRow=function(e){var t=g.getRange(new X.CellCoords(e,0),new X.CellCoords(e,this.countCols()-1),g.DESTINATION_RENDERER);return t[0]||[]},this.getDataType=function(e,t,n,r){var o=this,i=void 0===e?[0,0,this.countRows(),this.countCols()]:[e,t,n,r],a=i[0],s=i[1],l=i[2],u=i[3],c=null,h=null;void 0===l&&(l=a),void 0===u&&(u=s);var d="mixed";return(0,H.rangeEach)(Math.min(a,l),Math.max(a,l),function(n){var r=!0;return(0,H.rangeEach)(Math.min(s,u),Math.max(s,u),function(e){var t=o.getCellMeta(n,e);return h=t.type,c?r=c===h:c=h,r}),d=r?h:"mixed",r}),d},this.removeCellMeta=function(e,t,n){var r=y.toPhysical(e,t),o=(0,_.default)(r,2),i=o[0],a=o[1],s=V.cellSettings[i][a][n],l=B.runHooks("beforeRemoveCellMeta",e,t,n,s);!1!==l&&(delete V.cellSettings[i][a][n],B.runHooks("afterRemoveCellMeta",e,t,n,s)),s=null},this.spliceCellsMeta=function(e,t){for(var n,r=arguments.length,o=new Array(2<r?r-2:0),i=2;i<r;i++)o[i-2]=arguments[i];(n=V.cellSettings).splice.apply(n,[e,t].concat(o))},this.setCellMetaObject=function(n,r,e){var o=this;"object"===(0,W.default)(e)&&(0,Y.objectEach)(e,function(e,t){o.setCellMeta(n,r,t,e)})},this.setCellMeta=function(e,t,n,r){var o=y.toPhysical(e,t),i=(0,_.default)(o,2),a=i[0],s=i[1];V.columnSettings[s]||(V.columnSettings[s]=(0,O.columnFactory)(m,V.columnsSettingConflicts)),V.cellSettings[a]||(V.cellSettings[a]=[]),V.cellSettings[a][s]||(V.cellSettings[a][s]=new V.columnSettings[s]),V.cellSettings[a][s][n]=r,B.runHooks("afterSetCellMeta",e,t,n,r)},this.getCellsMeta=function(){return(0,A.arrayFlatten)(V.cellSettings)},this.getCellMeta=function(e,t){var n=g.colToProp(t),r=y.toPhysical(e,t),o=(0,_.default)(r,2),i=o[0],a=o[1],s=i;null===s&&(s=e),V.columnSettings[a]||(V.columnSettings[a]=(0,O.columnFactory)(m,V.columnsSettingConflicts)),V.cellSettings[s]||(V.cellSettings[s]=[]),V.cellSettings[s][a]||(V.cellSettings[s][a]=new V.columnSettings[a]);var l=V.cellSettings[s][a];if(l.row=s,l.col=a,l.visualRow=e,l.visualCol=t,l.prop=n,(l.instance=B).runHooks("beforeGetCellMeta",e,t,l),(0,Y.extend)(l,R(l)),l.cells){var u=l.cells.call(l,s,a,n);u&&((0,Y.extend)(l,u),(0,Y.extend)(l,R(u)))}return B.runHooks("afterGetCellMeta",e,t,l),l},this.getCellMetaAtRow=function(e){return V.cellSettings[e]},this.isColumnModificationAllowed=function(){return!("object"===B.dataType||B.getSettings().columns)};var o=(0,$.cellMethodLookupFactory)("renderer");this.getCellRenderer=function(e,t){return(0,D.getRenderer)(o.call(this,e,t))},this.getCellEditor=(0,$.cellMethodLookupFactory)("editor");var i=(0,$.cellMethodLookupFactory)("validator");this.getCellValidator=function(e,t){var n=i.call(this,e,t);return"string"==typeof n&&(n=(0,x.getValidator)(n)),n},this.validateCells=function(e){this._validateCells(e)},this.validateRows=function(e,t){if(!Array.isArray(e))throw new Error("validateRows parameter `rows` must be an array");this._validateCells(t,e)},this.validateColumns=function(e,t){if(!Array.isArray(e))throw new Error("validateColumns parameter `columns` must be an array");this._validateCells(t,void 0,e)},this._validateCells=function(e,t,n){var r=new E;e&&(r.onQueueEmpty=e);for(var o=B.countRows()-1;0<=o;)if(void 0===t||-1!==t.indexOf(o)){for(var i=B.countCols()-1;0<=i;)(void 0===n||-1!==n.indexOf(i))&&(r.addValidatorToQueue(),B.validateCell(B.getDataAtCell(o,i),B.getCellMeta(o,i),function(e){if("boolean"!=typeof e)throw new Error("Validation error: result is not boolean");!1===e&&(r.valid=!1),r.removeValidatorFormQueue()},"validateCells")),i-=1;o-=1}else o-=1;r.checkIfQueueIsEmpty()},this.getRowHeader=function(e){var t=V.settings.rowHeaders,n=e;return void 0!==n&&(n=B.runHooks("modifyRowHeader",n)),void 0===n?(t=[],(0,H.rangeEach)(B.countRows()-1,function(e){t.push(B.getRowHeader(e))})):Array.isArray(t)&&void 0!==t[n]?t=t[n]:(0,M.isFunction)(t)?t=t(n):t&&"string"!=typeof t&&"number"!=typeof t&&(t=n+1),t},this.hasRowHeaders=function(){return!!V.settings.rowHeaders},this.hasColHeaders=function(){if(void 0!==V.settings.colHeaders&&null!==V.settings.colHeaders)return!!V.settings.colHeaders;for(var e=0,t=B.countCols();e<t;e++)if(B.getColHeader(e))return!0;return!1},this.getColHeader=function(e){var t=V.settings.columns&&(0,M.isFunction)(V.settings.columns),n=B.runHooks("modifyColHeader",e),r=V.settings.colHeaders;if(void 0===n){for(var o=[],i=t?B.countSourceCols():B.countCols(),a=0;a<i;a++)o.push(B.getColHeader(a));r=o}else{var s=n,l=B.runHooks("modifyCol",s),u=function(e){for(var t=[],n=B.countSourceCols(),r=0;r<n;r++)(0,M.isFunction)(B.getSettings().columns)&&B.getSettings().columns(r)&&t.push(r);return t[e]}(l);!1===V.settings.colHeaders?r=null:V.settings.columns&&(0,M.isFunction)(V.settings.columns)&&V.settings.columns(u)&&V.settings.columns(u).title?r=V.settings.columns(u).title:V.settings.columns&&V.settings.columns[l]&&V.settings.columns[l].title?r=V.settings.columns[l].title:Array.isArray(V.settings.colHeaders)&&void 0!==V.settings.colHeaders[l]?r=V.settings.colHeaders[l]:(0,M.isFunction)(V.settings.colHeaders)?r=V.settings.colHeaders(l):V.settings.colHeaders&&"string"!=typeof V.settings.colHeaders&&"number"!=typeof V.settings.colHeaders&&(r=(0,$.spreadsheetColumnLabel)(s))}return r},this._getColWidthFromSettings=function(e){var t=B.getCellMeta(0,e),n=t.width;if(void 0!==n&&n!==V.settings.width||(n=t.colWidths),null!=n){switch((0,W.default)(n)){case"object":n=n[e];break;case"function":n=n(e)}"string"==typeof n&&(n=parseInt(n,10))}return n},this.getColWidth=function(e){var t=B._getColWidthFromSettings(e);return void 0===(t=B.runHooks("modifyColWidth",t,e))&&(t=X.ViewportColumnsCalculator.DEFAULT_WIDTH),t},this._getRowHeightFromSettings=function(e){var t=V.settings.rowHeights;if(null!=t){switch((0,W.default)(t)){case"object":t=t[e];break;case"function":t=t(e)}"string"==typeof t&&(t=parseInt(t,10))}return t},this.getRowHeight=function(e){var t=B._getRowHeightFromSettings(e);return t=B.runHooks("modifyRowHeight",t,e)},this.countSourceRows=function(){var e=B.runHooks("modifySourceLength");return e||(B.getSourceData()?B.getSourceData().length:0)},this.countSourceCols=function(){var e=B.getSourceData()&&B.getSourceData()[0]?B.getSourceData()[0]:[];return(0,Y.isObject)(e)?(0,Y.deepObjectSize)(e):e.length||0},this.countRows=function(){return g.getLength()},this.countCols=function(){var e=this.getSettings().maxCols,t=!1,n=0;if("array"===B.dataType&&(t=V.settings.data&&V.settings.data[0]&&V.settings.data[0].length),t&&(n=V.settings.data[0].length),V.settings.columns){var r=(0,M.isFunction)(V.settings.columns);if(r)if("array"===B.dataType){for(var o=0,i=0;i<n;i++)V.settings.columns(i)&&(o+=1);n=o}else"object"!==B.dataType&&"function"!==B.dataType||(n=g.colToPropCache.length);else n=V.settings.columns.length}else"object"!==B.dataType&&"function"!==B.dataType||(n=g.colToPropCache.length);return Math.min(e,n)},this.rowOffset=function(){return B.view.wt.wtTable.getFirstRenderedRow()},this.colOffset=function(){return B.view.wt.wtTable.getFirstRenderedColumn()},this.countRenderedRows=function(){return B.view.wt.drawn?B.view.wt.wtTable.getRenderedRowsCount():-1},this.countVisibleRows=function(){return B.view.wt.drawn?B.view.wt.wtTable.getVisibleRowsCount():-1},this.countRenderedCols=function(){return B.view.wt.drawn?B.view.wt.wtTable.getRenderedColumnsCount():-1},this.countVisibleCols=function(){return B.view.wt.drawn?B.view.wt.wtTable.getVisibleColumnsCount():-1},this.countEmptyRows=function(){var t=0<arguments.length&&void 0!==arguments[0]&&arguments[0],n=0;return(0,H.rangeEachReverse)(B.countRows()-1,function(e){if(B.isEmptyRow(e))n+=1;else if(!0===t)return!1}),n},this.countEmptyCols=function(){var t=0<arguments.length&&void 0!==arguments[0]&&arguments[0];if(B.countRows()<1)return 0;var n=0;return(0,H.rangeEachReverse)(B.countCols()-1,function(e){if(B.isEmptyCol(e))n+=1;else if(!0===t)return!1}),n},this.isEmptyRow=function(e){return V.settings.isEmptyRow.call(B,e)},this.isEmptyCol=function(e){return V.settings.isEmptyCol.call(B,e)},this.selectCell=function(e,t,n,r){var o=!(4<arguments.length&&void 0!==arguments[4])||arguments[4],i=!(5<arguments.length&&void 0!==arguments[5])||arguments[5];return!(0,j.isUndefined)(e)&&!(0,j.isUndefined)(t)&&this.selectCells([[e,t,n,r]],o,i)},this.selectCells=function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:[[]],t=!(1<arguments.length&&void 0!==arguments[1])||arguments[1],n=!(2<arguments.length&&void 0!==arguments[2])||arguments[2];!1===t&&(f=!0);var r=w.selectCells(e);return r&&n&&B.listen(),f=!1,r},this.selectColumns=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:e;return w.selectColumns(e,t)},this.selectRows=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:e;return w.selectRows(e,t)},this.deselectCell=function(){w.deselect()},this.selectAll=function(){f=!0,w.selectAll(),f=!1},this.scrollViewportTo=function(e,t){var n=2<arguments.length&&void 0!==arguments[2]&&arguments[2],r=3<arguments.length&&void 0!==arguments[3]&&arguments[3],o=!n,i=!r,a=!1;return void 0!==e&&void 0!==t&&(a=B.view.scrollViewport(new X.CellCoords(e,t),o,r,n,i)),"number"==typeof e&&"number"!=typeof t&&(a=B.view.scrollViewportVertically(e,o,n)),"number"==typeof t&&"number"!=typeof e&&(a=B.view.scrollViewportHorizontally(t,r,i)),a},this.destroy=function(){if(B._clearTimeouts(),B._clearImmediates(),B.view&&B.view.destroy(),c&&c.destroy(),c=null,(0,te.stopObserving)(),(0,z.isRootInstance)(B)){var e=this.rootDocument.querySelector("#hot-display-license-info");e&&e.parentNode.removeChild(e)}(0,k.empty)(B.rootElement),r.destroy(),p&&p.destroy(),B.runHooks("afterDestroy"),K.default.getSingleton().destroy(B),(0,Y.objectEach)(B,function(e,t,n){(0,M.isFunction)(e)?n[t]=function(e){return function(){throw new Error('The "'.concat(e,'" method cannot be called because this Handsontable instance has been destroyed'))}}(t):"guid"!==t&&(n[t]=null)}),B.isDestroyed=!0,g&&g.destroy(),m=B=p=w=v=V=g=null},this.getActiveEditor=function(){return p.getActiveEditor()},this.getPlugin=function(e){return(0,I.getPlugin)(this,e)},this.getInstance=function(){return B},this.addHook=function(e,t){K.default.getSingleton().add(e,t,B)},this.hasHook=function(e){return K.default.getSingleton().has(e,B)},this.addHookOnce=function(e,t){K.default.getSingleton().once(e,t,B)},this.removeHook=function(e,t){K.default.getSingleton().remove(e,t,B)},this.runHooks=function(e,t,n,r,o,i,a){return K.default.getSingleton().run(B,e,t,n,r,o,i,a)},this.getTranslatedPhrase=function(e,t){return(0,Q.getTranslatedPhrase)(V.settings.language,e,t)},this.timeouts=[],this._registerTimeout=function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0,n=e;"function"==typeof n&&(n=setTimeout(n,t)),this.timeouts.push(n)},this._clearTimeouts=function(){(0,A.arrayEach)(this.timeouts,function(e){clearTimeout(e)})},this.immediates=[],this._registerImmediate=function(e){this.immediates.push(setImmediate(e))},this._clearImmediates=function(){(0,A.arrayEach)(this.immediates,function(e){clearImmediate(e)})},this._refreshBorders=function(){var e=0<arguments.length&&void 0!==arguments[0]&&arguments[0],t=!(1<arguments.length&&void 0!==arguments[1])||arguments[1];p.destroyEditor(e),B.view.render(),t&&w.isSelected()&&p.prepareEditor()},K.default.getSingleton().run(B,"construct")};var W=r(n(44)),_=r(n(19)),U=r(n(38)),k=n(5),O=n(162),M=n(75),N=n(55),j=n(27),a=n(72),s=r(n(572)),l=r(n(574)),u=r(n(23)),Y=n(4),A=n(3),I=n(20),D=n(41),x=n(79),L=n(68),H=n(15),P=r(n(575)),F=r(n(576)),$=n(132),G=n(90),z=n(472),X=n(25),K=r(n(43)),q=r(n(475)),Z=n(160),Q=n(476),J=n(135),ee=n(477),te=n(136),ne=n(478),re=null},function(e,t,n){"use strict";t.__esModule=!0,t.columnFactory=function(e,t){function n(){}(0,i.inherit)(n,e);for(var r=0,o=t.length;r<o;r++)n.prototype[t[r]]=void 0;return n};var i=n(4)},function(e,t,n){"use strict";var r=n(0);n(105),n(482),t.__esModule=!0,t.default=void 0;var o=r(n(1)),i=r(n(2)),u=n(5),c=n(3),a=function(){function t(e){(0,o.default)(this,t),this.hot=e,this.container=null,this.injected=!1,this.rows=[],this.columns=[],this.samples=null,this.settings={useHeaders:!0}}return(0,i.default)(t,[{key:"addRow",value:function(e,t){if(this.columns.length)throw new Error("Doesn't support multi-dimensional table");this.rows.length||(this.container=this.createContainer(this.hot.rootElement.className));var n={row:e};this.rows.push(n),this.samples=t,this.table=this.createTable(this.hot.table.className),this.table.colGroup.appendChild(this.createColGroupsCol()),this.table.tr.appendChild(this.createRow(e)),this.container.container.appendChild(this.table.fragment),n.table=this.table.table}},{key:"addColumnHeadersRow",value:function(e){var t=this.hot.getColHeader(0);if(null!=t){var n={row:-1};this.rows.push(n),this.container=this.createContainer(this.hot.rootElement.className),this.samples=e,this.table=this.createTable(this.hot.table.className),this.table.colGroup.appendChild(this.createColGroupsCol()),this.table.tHead.appendChild(this.createColumnHeadersRow()),this.container.container.appendChild(this.table.fragment),n.table=this.table.table}}},{key:"addColumn",value:function(e,t){if(this.rows.length)throw new Error("Doesn't support multi-dimensional table");this.columns.length||(this.container=this.createContainer(this.hot.rootElement.className));var n={col:e};this.columns.push(n),this.samples=t,this.table=this.createTable(this.hot.table.className),this.getSetting("useHeaders")&&null!==this.hot.getColHeader(e)&&this.hot.view.appendColHeader(e,this.table.th),this.table.tBody.appendChild(this.createCol(e)),this.container.container.appendChild(this.table.fragment),n.table=this.table.table}},{key:"getHeights",value:function(t){this.injected||this.injectTable(),(0,c.arrayEach)(this.rows,function(e){t(e.row,(0,u.outerHeight)(e.table)-1)})}},{key:"getWidths",value:function(t){this.injected||this.injectTable(),(0,c.arrayEach)(this.columns,function(e){t(e.col,(0,u.outerWidth)(e.table))})}},{key:"setSettings",value:function(e){this.settings=e}},{key:"setSetting",value:function(e,t){this.settings||(this.settings={}),this.settings[e]=t}},{key:"getSettings",value:function(){return this.settings}},{key:"getSetting",value:function(e){return this.settings?this.settings[e]:null}},{key:"createColGroupsCol",value:function(){var t=this,n=this.hot.rootDocument.createDocumentFragment();return this.hot.hasRowHeaders()&&n.appendChild(this.createColElement(-1)),this.samples.forEach(function(e){(0,c.arrayEach)(e.strings,function(e){n.appendChild(t.createColElement(e.col))})}),n}},{key:"createRow",value:function(i){var a=this,s=this.hot.rootDocument,l=s.createDocumentFragment(),e=s.createElement("th");return this.hot.hasRowHeaders()&&(this.hot.view.appendRowHeader(i,e),l.appendChild(e)),this.samples.forEach(function(e){(0,c.arrayEach)(e.strings,function(e){var t=e.col,n=a.hot.getCellMeta(i,t);n.col=t,n.row=i;var r=a.hot.getCellRenderer(n),o=s.createElement("td");o.setAttribute("ghost-table",1),r(a.hot,o,i,t,a.hot.colToProp(t),e.value,n),l.appendChild(o)})}),l}},{key:"createColumnHeadersRow",value:function(){var r=this,o=this.hot.rootDocument,i=o.createDocumentFragment();if(this.hot.hasRowHeaders()){var e=o.createElement("th");this.hot.view.appendColHeader(-1,e),i.appendChild(e)}return this.samples.forEach(function(e){(0,c.arrayEach)(e.strings,function(e){var t=e.col,n=o.createElement("th");r.hot.view.appendColHeader(t,n),i.appendChild(n)})}),i}},{key:"createCol",value:function(a){var s=this,l=this.hot.rootDocument,u=l.createDocumentFragment();return this.samples.forEach(function(e){(0,c.arrayEach)(e.strings,function(e){var t=e.row,n=s.hot.getCellMeta(t,a);n.col=a,n.row=t;var r=s.hot.getCellRenderer(n),o=l.createElement("td"),i=l.createElement("tr");o.setAttribute("ghost-table",1),r(s.hot,o,t,a,s.hot.colToProp(a),e.value,n),i.appendChild(o),u.appendChild(i)})}),u}},{key:"clean",value:function(){this.rows.length=0,this.rows[-1]=void 0,this.columns.length=0,this.samples&&this.samples.clear(),this.samples=null,this.removeTable()}},{key:"injectTable",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null;this.injected||((e||this.hot.rootElement).appendChild(this.container.fragment),this.injected=!0)}},{key:"removeTable",value:function(){this.injected&&this.container.container.parentNode&&(this.container.container.parentNode.removeChild(this.container.container),this.container=null,this.injected=!1)}},{key:"createColElement",value:function(e){var t=this.hot.rootDocument.createElement("col");return t.style.width="".concat(this.hot.view.wt.wtTable.getStretchedColumnWidth(e),"px"),t}},{key:"createTable",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:"",t=this.hot.rootDocument,n=t.createDocumentFragment(),r=t.createElement("table"),o=t.createElement("thead"),i=t.createElement("tbody"),a=t.createElement("colgroup"),s=t.createElement("tr"),l=t.createElement("th");return this.isVertical()&&r.appendChild(a),this.isHorizontal()&&(s.appendChild(l),o.appendChild(s),r.style.tableLayout="auto",r.style.width="auto"),r.appendChild(o),this.isVertical()&&i.appendChild(s),r.appendChild(i),(0,u.addClass)(r,e),n.appendChild(r),{fragment:n,table:r,tHead:o,tBody:i,colGroup:a,tr:s,th:l}}},{key:"createContainer",value:function(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:"",t=this.hot.rootDocument,n=t.createDocumentFragment(),r=t.createElement("div"),o="htGhostTable htAutoSize ".concat(e.trim());return(0,u.addClass)(r,o),n.appendChild(r),{fragment:n,container:r}}},{key:"isVertical",value:function(){return!(!this.rows.length||this.columns.length)}},{key:"isHorizontal",value:function(){return!(!this.columns.length||this.rows.length)}}]),t}();t.default=a},function(e,t,n){"use strict";var r=n(102)(1),o=n(103)("map");n(22)({target:"Array",proto:!0,forced:!o},{map:function(e){return r(this,e,arguments[1])}})},function(e,t,n){"use strict";n(59),n(34),n(12),n(16),n(164),n(80),n(81),n(10),n(82),n(14),n(17),t.__esModule=!0,t.areValidSortStates=function(e){if(!1===Array.isArray(e)||!1===e.every(function(e){return(0,o.isObject)(e)}))return!1;var t=e.map(function(e){var t=e.column;return t});return new Set(t).size===t.length&&e.every(u)},t.getNextSortOrder=function(e){{if(e===s)return;if(e===a)return s}return a},t.getHeaderSpanElement=function(e){return e.querySelector(".".concat(l))},t.isFirstLevelColumnHeader=function(e,t){if(e<0||!t.parentNode)return!1;var n=t.parentNode.parentNode.childNodes;return-1==Array.from(n).indexOf(t.parentNode)-n.length},t.wasHeaderClickedProperly=function(e,t,n){return-1===e&&0<=t&&!1===(0,i.isRightClick)(n)},t.HEADER_SPAN_CLASS=t.DESC_SORT_STATE=t.ASC_SORT_STATE=void 0;var r=n(27),o=n(4),i=n(31),a="asc";t.ASC_SORT_STATE=a;var s="desc";t.DESC_SORT_STATE=s;var l="colHeader";function u(e){if((0,r.isUndefined)(e))return!1;var t=e.column,n=e.sortOrder;return Number.isInteger(t)&&[a,s].includes(n)}t.HEADER_SPAN_CLASS=l},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(){return{name:r}},t.KEY=void 0;var r="---------";t.KEY=r},function(e,t,n){"use strict";var r=n(0);n(18),n(51),n(76),n(10),n(130),n(36),n(37),t.__esModule=!0,t.default=void 0;var i=r(n(1)),a=r(n(2)),s=r(n(161)),g=n(5),l=n(3),u=r(n(632)),c=r(n(23)),v=n(4),h=n(27),d=n(75),f=n(60),p=n(50),o=r(n(57)),m=n(83),y=n(31),w=function(){function o(e,t){(0,i.default)(this,o),this.hot=e,this.options=t||{parent:null,name:null,className:"",keepInViewport:!0,standalone:!1,minWidth:215},this.eventManager=new c.default(this),this.container=this.createContainer(this.options.name),this.hotMenu=null,this.hotSubMenus={},this.parentMenu=this.options.parent||null,this.menuItems=null,this.origOutsideClickDeselects=null,this.keyEvent=!1,this.offset={above:0,below:0,left:0,right:0},this._afterScrollCallback=null,this.registerEvents()}return(0,a.default)(o,[{key:"registerEvents",value:function(){var t=this;this.eventManager.addEventListener(this.hot.rootDocument.documentElement,"mousedown",function(e){return t.onDocumentMouseDown(e)})}},{key:"setMenuItems",value:function(e){this.menuItems=e}},{key:"setOffset",value:function(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:0;this.offset[e]=t}},{key:"isSubMenu",value:function(){return null!==this.parentMenu}},{key:"open",value:function(){var a=this;this.runLocalHooks("beforeOpen"),this.container.removeAttribute("style"),this.container.style.display="block";var n=(0,d.debounce)(function(e){return a.openSubMenu(e)},300),t=this.options.minWidth||215,r=!1,o=(0,l.arrayFilter)(this.menuItems,function(e){return e.key===m.NO_ITEMS&&(r=!0),(0,f.isItemHidden)(e,a.hot)});if(o.length<1&&!r)o.push((0,m.predefinedItems)()[m.NO_ITEMS]);else if(0===o.length)return;var e={data:o=(0,f.filterSeparators)(o,m.SEPARATOR),colHeaders:!1,autoColumnSize:!0,modifyColWidth:function(e){return(0,h.isDefined)(e)&&e<t?t:e},autoRowSize:!1,readOnly:!0,copyPaste:!1,columns:[{data:"name",renderer:function(e,t,n,r,o,i){return a.menuItemRenderer(e,t,n,r,o,i)}}],renderAllRows:!0,fragmentSelection:"cell",disableVisualSelection:"area",beforeKeyDown:function(e){return a.onBeforeKeyDown(e)},afterOnCellMouseOver:function(e,t){a.isAllSubMenusClosed()?n(t.row):a.openSubMenu(t.row)},rowHeights:function(e){return o[e].name===m.SEPARATOR?1:23}};this.origOutsideClickDeselects=this.hot.getSettings().outsideClickDeselects,this.hot.getSettings().outsideClickDeselects=!1,this.hotMenu=new s.default(this.container,e),this.hotMenu.addHook("afterInit",function(){return a.onAfterInit()}),this.hotMenu.addHook("afterSelection",function(){return a.onAfterSelection.apply(a,arguments)}),this.hotMenu.init(),this.hotMenu.listen(),this.blockMainTableCallbacks(),this.runLocalHooks("afterOpen")}},{key:"close",value:function(){var e=0<arguments.length&&void 0!==arguments[0]&&arguments[0];this.isOpened()&&(e&&this.parentMenu?this.parentMenu.close():(this.closeAllSubMenus(),this.container.style.display="none",this.releaseMainTableCallbacks(),this.hotMenu.destroy(),this.hotMenu=null,this.hot.getSettings().outsideClickDeselects=this.origOutsideClickDeselects,this.runLocalHooks("afterClose"),this.parentMenu&&this.parentMenu.hotMenu.listen()))}},{key:"openSubMenu",value:function(e){if(!this.hotMenu)return!1;var t=this.hotMenu.getCell(e,0);if(this.closeAllSubMenus(),!t||!(0,f.hasSubMenu)(t))return!1;var n=this.hotMenu.getSourceDataAtRow(e),r=new o(this.hot,{parent:this,name:n.name,className:this.options.className,keepInViewport:!0});return r.setMenuItems(n.submenu.items),r.open(),r.setPosition(t.getBoundingClientRect()),this.hotSubMenus[n.key]=r}},{key:"closeSubMenu",value:function(e){var t=this.hotMenu.getSourceDataAtRow(e),n=this.hotSubMenus[t.key];n&&(n.destroy(),delete this.hotSubMenus[t.key])}},{key:"closeAllSubMenus",value:function(){var n=this;(0,l.arrayEach)(this.hotMenu.getData(),function(e,t){return n.closeSubMenu(t)})}},{key:"isAllSubMenusClosed",value:function(){return 0===Object.keys(this.hotSubMenus).length}},{key:"destroy",value:function(){this.clearLocalHooks(),this.close(),this.parentMenu=null,this.eventManager.destroy()}},{key:"isOpened",value:function(){return null!==this.hotMenu}},{key:"executeCommand",value:function(e){if(this.isOpened()&&this.hotMenu.getSelectedLast()){var t=this.hotMenu.getSourceDataAtRow(this.hotMenu.getSelectedLast()[0]);if(this.runLocalHooks("select",t,e),!1!==t.isCommand&&t.name!==m.SEPARATOR){var n=this.hot.getSelectedRange(),r=n?(0,f.normalizeSelection)(n):[],o=!0;(!0===t.disabled||"function"==typeof t.disabled&&!0===t.disabled.call(this.hot)||t.submenu)&&(o=!1),this.runLocalHooks("executeCommand",t.key,r,e),this.isSubMenu()&&this.parentMenu.runLocalHooks("executeCommand",t.key,r,e),o&&this.close(!0)}}}},{key:"setPosition",value:function(e){var t=new u.default(e,this.hot.rootWindow);this.options.keepInViewport?(t.fitsBelow(this.container)?this.setPositionBelowCursor(t):t.fitsAbove(this.container)?this.setPositionAboveCursor(t):this.setPositionBelowCursor(t),t.fitsOnRight(this.container)?this.setPositionOnRightOfCursor(t):this.setPositionOnLeftOfCursor(t)):(this.setPositionBelowCursor(t),this.setPositionOnRightOfCursor(t))}},{key:"setPositionAboveCursor",value:function(e){var t=this.offset.above+e.top-this.container.offsetHeight;this.isSubMenu()&&(t=e.top+e.cellHeight-this.container.offsetHeight+3),this.container.style.top="".concat(t,"px")}},{key:"setPositionBelowCursor",value:function(e){var t=this.offset.below+e.top;this.isSubMenu()&&(t=e.top-1),this.container.style.top="".concat(t,"px")}},{key:"setPositionOnRightOfCursor",value:function(e){var t;t=this.isSubMenu()?1+e.left+e.cellWidth:this.offset.right+1+e.left,this.container.style.left="".concat(t,"px")}},{key:"setPositionOnLeftOfCursor",value:function(e){var t=this.offset.left+e.left-this.container.offsetWidth+(0,g.getScrollbarWidth)(this.hot.rootDocument)+4;this.container.style.left="".concat(t,"px")}},{key:"selectFirstCell",value:function(){var e=this.hotMenu.getCell(0,0);(0,f.isSeparator)(e)||(0,f.isDisabled)(e)||(0,f.isSelectionDisabled)(e)?this.selectNextCell(0,0):this.hotMenu.selectCell(0,0)}},{key:"selectLastCell",value:function(){var e=this.hotMenu.countRows()-1,t=this.hotMenu.getCell(e,0);(0,f.isSeparator)(t)||(0,f.isDisabled)(t)||(0,f.isSelectionDisabled)(t)?this.selectPrevCell(e,0):this.hotMenu.selectCell(e,0)}},{key:"selectNextCell",value:function(e,t){var n=e+1,r=n<this.hotMenu.countRows()?this.hotMenu.getCell(n,t):null;r&&((0,f.isSeparator)(r)||(0,f.isDisabled)(r)||(0,f.isSelectionDisabled)(r)?this.selectNextCell(n,t):this.hotMenu.selectCell(n,t))}},{key:"selectPrevCell",value:function(e,t){var n=e-1,r=0<=n?this.hotMenu.getCell(n,t):null;r&&((0,f.isSeparator)(r)||(0,f.isDisabled)(r)||(0,f.isSelectionDisabled)(r)?this.selectPrevCell(n,t):this.hotMenu.selectCell(n,t))}},{key:"menuItemRenderer",value:function(e,t,n,r,o,i){var a,s,l,u=this,c=e.getSourceDataAtRow(n),h=this.hot.rootDocument.createElement("div"),d=function(e){return e.disableSelection},f=i;"function"==typeof f&&(f=f.call(this.hot)),(0,g.empty)(t),(0,g.addClass)(h,"htItemWrapper"),t.appendChild(h),a=c,new RegExp(m.SEPARATOR,"i").test(a.name)?(0,g.addClass)(t,"htSeparator"):"function"==typeof c.renderer?((0,g.addClass)(t,"htCustomMenuRenderer"),t.appendChild(c.renderer(e,h,n,r,o,f))):(0,g.fastInnerHTML)(h,f),!0===(l=c).disabled||"function"==typeof l.disabled&&!0===l.disabled.call(u.hot)?((0,g.addClass)(t,"htDisabled"),this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()})):d(c)?((0,g.addClass)(t,"htSelectionDisabled"),this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()})):(s=c,(0,v.hasOwnProperty)(s,"submenu")?(0,g.addClass)(t,"htSubmenu"):((0,g.removeClass)(t,"htSubmenu"),(0,g.removeClass)(t,"htDisabled")),d(c)?this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()}):this.eventManager.addEventListener(t,"mouseenter",function(){return e.selectCell(n,r,void 0,void 0,!1,!1)}))}},{key:"createContainer",value:function(){var e,t=0<arguments.length&&void 0!==arguments[0]?arguments[0]:null,n=this.hot.rootDocument,r=t;return(e=r?((0,d.isFunction)(r)&&(r=null===(r=r.call(this.hot))||(0,h.isUndefined)(r)?"":r.toString()),r=r.replace(/[^A-z0-9]/g,"_"),r="".concat(this.options.className,"Sub_").concat(r),n.querySelector(".".concat(this.options.className,".").concat(r))):n.querySelector(".".concat(this.options.className)))||(e=n.createElement("div"),(0,g.addClass)(e,"htMenu ".concat(this.options.className)),r&&(0,g.addClass)(e,r),n.getElementsByTagName("body")[0].appendChild(e)),e}},{key:"blockMainTableCallbacks",value:function(){this._afterScrollCallback=function(){},this.hot.addHook("afterScrollVertically",this._afterScrollCallback),this.hot.addHook("afterScrollHorizontally",this._afterScrollCallback)}},{key:"releaseMainTableCallbacks",value:function(){this._afterScrollCallback&&(this.hot.removeHook("afterScrollVertically",this._afterScrollCallback),this.hot.removeHook("afterScrollHorizontally",this._afterScrollCallback),this._afterScrollCallback=null)}},{key:"onBeforeKeyDown",value:function(e){var t=this.hotMenu.getSelectedLast(),n=!1;switch(this.keyEvent=!0,e.keyCode){case p.KEY_CODES.ESCAPE:this.close(),n=!0;break;case p.KEY_CODES.ENTER:t&&(this.hotMenu.getSourceDataAtRow(t[0]).submenu?n=!0:(this.executeCommand(e),this.close(!0)));break;case p.KEY_CODES.ARROW_DOWN:t?this.selectNextCell(t[0],t[1]):this.selectFirstCell(),n=!0;break;case p.KEY_CODES.ARROW_UP:t?this.selectPrevCell(t[0],t[1]):this.selectLastCell(),n=!0;break;case p.KEY_CODES.ARROW_RIGHT:if(t){var r=this.openSubMenu(t[0]);r&&r.selectFirstCell()}n=!0;break;case p.KEY_CODES.ARROW_LEFT:t&&this.isSubMenu()&&(this.close(),this.parentMenu&&this.parentMenu.hotMenu.listen(),n=!0)}n&&(e.preventDefault(),(0,y.stopImmediatePropagation)(e)),this.keyEvent=!1}},{key:"onAfterInit",value:function(){var e=this.hotMenu.view.wt.wtTable,t=this.hotMenu.getSettings().data,n=e.hider.style,r=e.holder.style,o=parseInt(n.width,10),i=(0,l.arrayReduce)(t,function(e,t){return e+(t.name===m.SEPARATOR?1:26)},0);r.width="".concat(o+22,"px"),r.height="".concat(i+4,"px"),n.height=r.height}},{key:"onAfterSelection",value:function(e,t,n,r,o){!1===this.keyEvent&&(o.value=!0)}},{key:"onDocumentMouseDown",value:function(e){this.isOpened()&&(this.container&&(0,g.isChildOf)(e.target,this.container)&&this.executeCommand(e),this.options.standalone&&this.hotMenu&&!(0,g.isChildOf)(e.target,this.hotMenu.rootElement)?this.close(!0):(this.isAllSubMenusClosed()||this.isSubMenu())&&!(0,g.isChildOf)(e.target,".htMenu")&&(0,g.isChildOf)(e.target,this.hot.rootDocument)&&this.close(!0))}}]),o}();(0,v.mixin)(w,o.default);var C=w;t.default=C},function(e,t,n){"use strict";var r=n(0);t.__esModule=!0,t.default=void 0;var o=r(n(66)),i=r(n(1)),a=r(n(2)),s=n(25),l=n(67);function u(){var e=(0,o.default)(["The merged cell declared at [",", ",'] has "rowspan" or "colspan" declared as \n "0", which is not supported. It cannot be added to the collection.']);return u=function(){return e},e}function c(){var e=(0,o.default)(["The merged cell declared at [",", ",'] has both "rowspan" \n and "colspan" declared as "1", which makes it a single cell. It cannot be added to the collection.']);return c=function(){return e},e}function h(){var e=(0,o.default)(["The merged cell declared at [",", ","] is positioned (or positioned partially) \n outside of the table range. It was not added to the table, please fix your setup."]);return h=function(){return e},e}function d(){var e=(0,o.default)(["The merged cell declared with {row: ",", col: ",", rowspan: \n ",", colspan: ","} contains negative values, which is not supported. It \n will not be added to the collection."]);return d=function(){return e},e}var f=function(){function o(e,t,n,r){(0,i.default)(this,o),this.row=e,this.col=t,this.rowspan=n,this.colspan=r,this.removed=!1}return(0,a.default)(o,[{key:"normalize",value:function(e){var t=e.countRows(),n=e.countCols();this.row<0?this.row=0:this.row>t-1&&(this.row=t-1),this.col<0?this.col=0:this.col>n-1&&(this.col=n-1),this.row+this.rowspan>t-1&&(this.rowspan=t-this.row),this.col+this.colspan>n-1&&(this.colspan=n-this.col)}},{key:"includes",value:function(e,t){return this.row<=e&&this.col<=t&&this.row+this.rowspan-1>=e&&this.col+this.colspan-1>=t}},{key:"includesHorizontally",value:function(e){return this.col<=e&&this.col+this.colspan-1>=e}},{key:"includesVertically",value:function(e){return this.row<=e&&this.row+this.rowspan-1>=e}},{key:"shift",value:function(e,t){var n=e[0]||e[1],r=t+Math.abs(e[0]||e[1])-1,o=e[0]?"colspan":"rowspan",i=e[0]?"col":"row",a=Math.min(t,r),s=Math.max(t,r),l=this[i],u=this[i]+this[o]-1;if(t<=l&&(this[i]+=n),0<n)t<=u&&l<t&&(this[o]+=n);else if(n<0){if(a<=l&&u<=s)return!(this.removed=!0);if(a<=l&&l<=s){var c=s-l+1,h=Math.abs(n)-c;this[i]-=h+n,this[o]-=c}else if(l<=a&&s<=u)this[o]+=n;else if(l<=a&&a<=u&&u<s){var d=u-a+1;this[o]-=d}}return!0}},{key:"isFarther",value:function(e,t){return!e||("down"===t?e.row+e.rowspan-1<this.row+this.rowspan-1:"up"===t?e.row>this.row:"right"===t?e.col+e.colspan-1<this.col+this.colspan-1:"left"===t?e.col>this.col:null)}},{key:"getLastRow",value:function(){return this.row+this.rowspan-1}},{key:"getLastColumn",value:function(){return this.col+this.colspan-1}},{key:"getRange",value:function(){return new s.CellRange(new s.CellCoords(this.row,this.col),new s.CellCoords(this.row,this.col),new s.CellCoords(this.getLastRow(),this.getLastColumn()))}}],[{key:"NEGATIVE_VALUES_WARNING",value:function(e){return(0,l.toSingleLine)(d(),e.row,e.col,e.rowspan,e.colspan)}},{key:"IS_OUT_OF_BOUNDS_WARNING",value:function(e){return(0,l.toSingleLine)(h(),e.row,e.col)}},{key:"IS_SINGLE_CELL",value:function(e){return(0,l.toSingleLine)(c(),e.row,e.col)}},{key:"ZERO_SPAN_WARNING",value:function(e){return(0,l.toSingleLine)(u(),e.row,e.col)}},{key:"containsNegativeValues",value:function(e){return e.row<0||e.col<0||e.rowspan<0||e.colspan<0}},{key:"isSingleCell",value:function(e){return 1===e.colspan&&1===e.rowspan}},{key:"containsZeroSpan",value:function(e){return 0===e.colspan||0===e.rowspan}},{key:"isOutOfBounds",value:function(e,t,n){return e.row<0||e.col<0||e.row>=t||e.row+e.rowspan-1>=t||e.col>=n||e.col+e.colspan-1>=n}}]),o}();t.default=f},function(e,t,n){"use strict";var r=n(0);t.__esModule=!0,t.default=function(e){var n=[],t=e;P[t]||(t=H);return(0,a.arrayEach)(P[t],function(e){var t;t=e===s.SEPARATOR?{name:s.SEPARATOR}:(0,i.clone)((0,l.getConditionDescriptor)(e)),n.push(t)}),n},t.TYPES=t.TYPE_DATE=t.TYPE_TEXT=t.TYPE_NUMERIC=void 0;var o=r(n(71)),i=n(4),a=n(3),s=n(83),l=n(28),u=n(708);t.CONDITION_NONE=u.CONDITION_NAME;var c=n(493);t.CONDITION_EMPTY=c.CONDITION_NAME;var h=n(709);t.CONDITION_NOT_EMPTY=h.CONDITION_NAME;var d=n(494);t.CONDITION_EQUAL=d.CONDITION_NAME;var f=n(710);t.CONDITION_NOT_EQUAL=f.CONDITION_NAME;var g=n(711);t.CONDITION_GREATER_THAN=g.CONDITION_NAME;var v=n(712);t.CONDITION_GREATER_THAN_OR_EQUAL=v.CONDITION_NAME;var p=n(713);t.CONDITION_LESS_THAN=p.CONDITION_NAME;var m=n(714);t.CONDITION_LESS_THAN_OR_EQUAL=m.CONDITION_NAME;var y=n(495);t.CONDITION_BETWEEN=y.CONDITION_NAME;var w=n(715);t.CONDITION_NOT_BETWEEN=w.CONDITION_NAME;var C=n(716);t.CONDITION_BEGINS_WITH=C.CONDITION_NAME;var E=n(717);t.CONDITION_ENDS_WITH=E.CONDITION_NAME;var S=n(498);t.CONDITION_CONTAINS=S.CONDITION_NAME;var b=n(719);t.CONDITION_NOT_CONTAINS=b.CONDITION_NAME;var T=n(497);t.CONDITION_DATE_BEFORE=T.CONDITION_NAME;var R=n(496);t.CONDITION_DATE_AFTER=R.CONDITION_NAME;var _=n(720);t.CONDITION_TOMORROW=_.CONDITION_NAME;var k=n(721);t.CONDITION_TODAY=k.CONDITION_NAME;var O=n(722);t.CONDITION_YESTERDAY=O.CONDITION_NAME;var M=n(723);t.CONDITION_BY_VALUE=M.CONDITION_NAME;var N=n(724);t.CONDITION_TRUE=N.CONDITION_NAME;var A=n(725);t.CONDITION_FALSE=A.CONDITION_NAME;var I=n(170);t.OPERATION_AND=I.OPERATION_ID;var D=n(499);t.OPERATION_OR=D.OPERATION_ID;var x,L=n(500);t.OPERATION_OR_THEN_VARIABLE=L.OPERATION_ID;t.TYPE_NUMERIC="numeric";var H="text";t.TYPE_TEXT=H;t.TYPE_DATE="date";var P=(x={},(0,o.default)(x,"numeric",[u.CONDITION_NAME,s.SEPARATOR,c.CONDITION_NAME,h.CONDITION_NAME,s.SEPARATOR,d.CONDITION_NAME,f.CONDITION_NAME,s.SEPARATOR,g.CONDITION_NAME,v.CONDITION_NAME,p.CONDITION_NAME,m.CONDITION_NAME,y.CONDITION_NAME,w.CONDITION_NAME]),(0,o.default)(x,H,[u.CONDITION_NAME,s.SEPARATOR,c.CONDITION_NAME,h.CONDITION_NAME,s.SEPARATOR,d.CONDITION_NAME,f.CONDITION_NAME,s.SEPARATOR,C.CONDITION_NAME,E.CONDITION_NAME,s.SEPARATOR,S.CONDITION_NAME,b.CONDITION_NAME]),(0,o.default)(x,"date",[u.CONDITION_NAME,s.SEPARATOR,c.CONDITION_NAME,h.CONDITION_NAME,s.SEPARATOR,d.CONDITION_NAME,f.CONDITION_NAME,s.SEPARATOR,T.CONDITION_NAME,R.CONDITION_NAME,y.CONDITION_NAME,s.SEPARATOR,_.CONDITION_NAME,k.CONDITION_NAME,O.CONDITION_NAME]),x);t.TYPES=P},function(e,t,n){"use strict";var r=n(9);t.__esModule=!0,t.operationResult=l,t.SHORT_NAME_FOR_COMPONENT=t.OPERATION_ID=void 0;var o=r(n(11)),i=n(109),a="conjunction";t.OPERATION_ID=a;var s=o.FILTERS_LABELS_CONJUNCTION;function l(e,t){return e.every(function(e){return e.func(t)})}t.SHORT_NAME_FOR_COMPONENT=s,(0,i.registerOperation)(a,s,l)},function(e,t,n){"use strict";var r=n(0);n(16),n(10),n(14),n(24),n(17),t.__esModule=!0,t.default=void 0;var o=r(n(1)),i=r(n(7)),a=r(n(26)),s=r(n(6)),l=r(n(13)),u=r(n(2)),c=r(n(8)),h=n(5),d=n(4),f=r(n(110)),g=new WeakMap,v=function(e){function r(e,t){var n;return(0,o.default)(this,r),n=(0,i.default)(this,(0,s.default)(r).call(this,e,(0,d.extend)(r.DEFAULTS,t))),g.set((0,a.default)(n),{}),n.registerHooks(),n}return(0,c.default)(r,e),(0,u.default)(r,null,[{key:"DEFAULTS",get:function(){return(0,d.clone)({placeholder:"",type:"text",tagName:"input"})}}]),(0,u.default)(r,[{key:"registerHooks",value:function(){var t=this;this.addLocalHook("click",function(){return t.onClick()}),this.addLocalHook("keyup",function(e){return t.onKeyup(e)})}},{key:"build",value:function(){(0,l.default)((0,s.default)(r.prototype),"build",this).call(this);var e=g.get(this),t=this.hot.rootDocument.createElement("div");e.input=this._element.firstChild,(0,h.addClass)(this._element,"htUIInput"),(0,h.addClass)(t,"htUIInputIcon"),this._element.appendChild(t),this.update()}},{key:"update",value:function(){if(this.isBuilt()){var e=g.get(this).input;e.type=this.options.type,e.placeholder=this.translateIfPossible(this.options.placeholder),e.value=this.translateIfPossible(this.options.value)}}},{key:"focus",value:function(){this.isBuilt()&&g.get(this).input.focus()}},{key:"onClick",value:function(){}},{key:"onKeyup",value:function(e){this.options.value=e.target.value}}]),r}(f.default);t.default=v},function(e,t,n){"use strict";n(18),n(51),n(10),n(36),t.__esModule=!0,t.getMixedMonthObject=function(e,t){return{name:e,days:r,daysBeforeFullWeeks:0,daysAfterFullWeeks:0,fullWeeks:1,index:t}},t.getMixedMonthName=function(e,t){var n=null,r=s(t[e].name),o=0<e?s(t[e-1].name):null,i=s(t[0].name),a=s(t[t.length-1].name);n=0<e?"".concat(o,"/").concat(r):e===t.length-1?"".concat(r,"/").concat(i):"".concat(a,"/").concat(r);return n},t.getShorthand=s,t.getStartDate=function(e){return o(Array.isArray(e)?e[1]:e.startDate)},t.getEndDate=function(e){return o(Array.isArray(e)?e[2]:e.endDate)},t.getAdditionalData=function(e){return Array.isArray(e)?e[3]:e.additionalData},t.setStartDate=function(e,t){Array.isArray(e)?e[1]=t:e.startDate=t},t.setEndDate=function(e,t){Array.isArray(e)?e[2]=t:e.endDate=t},t.parseDate=o,t.getDateYear=function(e){var t=o(e);return t?t.getFullYear():null},t.WEEK_LENGTH=t.DEC_LENGTH=void 0;t.DEC_LENGTH=31;var r=7;function s(e){return e.substring(0,3)}function o(e){var t=e;return null===t?null:t instanceof Date||"Invalid Date"!==(t=new Date(t)).toString()?t:null}t.WEEK_LENGTH=r},function(e,t,n){"use strict";var r=n(0);t.__esModule=!0,t.default=void 0;var o=r(n(1)),i=function e(t,n){(0,o.default)(this,e),this.hot=n,this.plugin=t};t.default=i},function(e,t,n){var r=n(69),o=n(93).f,i={}.toString,a="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];e.exports.f=function(e){return a&&"[object Window]"==i.call(e)?function(e){try{return o(e)}catch(e){return a.slice()}}(e):o(r(e))}},function(e,t,n){var a=n(47),s=n(69),l=n(140)(!1),u=n(94);e.exports=function(e,t){var n,r=s(e),o=0,i=[];for(n in r)!a(u,n)&&a(r,n)&&i.push(n);for(;t.length>o;)a(r,n=t[o++])&&(~l(i,n)||i.push(n));return i}},function(e,t,n){e.exports=!n(52)&&!n(29)(function(){return 7!=Object.defineProperty(n(142)("div"),"a",{get:function(){return 7}}).a})},function(e,t,n){e.exports=n(98)("native-function-to-string",Function.toString)},function(e,t,n){var r=n(177),o=n(32).WeakMap;e.exports="function"==typeof o&&/native code/.test(r.call(o))},function(e,t,n){var s=n(47),l=n(507),u=n(115),c=n(49);e.exports=function(e,t){for(var n=l(t),r=c.f,o=u.f,i=0;i<n.length;i++){var a=n[i];s(e,a)||r(e,a,o(t,a))}}},function(e,t,n){e.exports=!n(29)(function(){return!String(Symbol())})},function(e,t,n){var r=n(32).document;e.exports=r&&r.documentElement},function(e,t,n){"use strict";var r,o,i,a=n(145),s=n(61),l=n(47),u=n(116),c=n(35)("iterator"),h=!1;[].keys&&("next"in(i=[].keys())?(o=a(a(i)))!==Object.prototype&&(r=o):h=!0),null==r&&(r={}),u||l(r,c)||s(r,c,function(){return this}),e.exports={IteratorPrototype:r,BUGGY_SAFARI_ITERATORS:h}},function(e,t,n){e.exports=!n(29)(function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype})},function(e,t,n){var o=n(513);e.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var n,r=!1,e={};try{(n=Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set).call(e,[]),r=e instanceof Array}catch(e){}return function(e,t){return o(e,t),r?n.call(e,t):e.__proto__=t,e}}():void 0)},function(e,t,n){var o=n(77),i=n(35)("toStringTag"),a="Arguments"==o(function(){return arguments}());e.exports=function(e){var t,n,r;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=function(e,t){try{return e[t]}catch(e){}}(t=Object(e),i))?n:a?o(t):"Object"==(r=o(t))&&"function"==typeof t.callee?"Arguments":r}},function(e,t,n){"use strict";var l=n(147),u=n(123).getWeakData,c=n(45),h=n(42),d=n(148),f=n(149),r=n(102),g=n(47),o=n(87),v=o.set,p=o.getterFor,i=r(5),a=r(6),m=0,y=function(e){return e.frozen||(e.frozen=new s)},s=function(){this.entries=[]},w=function(e,t){return i(e.entries,function(e){return e[0]===t})};s.prototype={get:function(e){var t=w(this,e);if(t)return t[1]},has:function(e){return!!w(this,e)},set:function(e,t){var n=w(this,e);n?n[1]=t:this.entries.push([e,t])},delete:function(t){var e=a(this.entries,function(e){return e[0]===t});return~e&&this.entries.splice(e,1),!!~e}},e.exports={getConstructor:function(e,n,r,o){var i=e(function(e,t){d(e,i,n),v(e,{type:n,id:m++,frozen:void 0}),null!=t&&f(t,e[o],e,r)}),a=p(n),s=function(e,t,n){var r=a(e),o=u(c(t),!0);return!0===o?y(r).set(t,n):o[r.id]=n,e};return l(i.prototype,{delete:function(e){var t=a(this);if(!h(e))return!1;var n=u(e);return!0===n?y(t).delete(e):n&&g(n,t.id)&&delete n[t.id]},has:function(e){var t=a(this);if(!h(e))return!1;var n=u(e);return!0===n?y(t).has(e):n&&g(n,t.id)}}),l(i.prototype,r?{get:function(e){var t=a(this);if(h(e)){var n=u(e);return!0===n?y(t).get(e):n?n[t.id]:void 0}},set:function(e,t){return s(this,e,t)}}:{add:function(e){return s(this,e,!0)}}),i}}},function(e,t,n){var r=n(100),o=n(35)("iterator"),i=Array.prototype;e.exports=function(e){return void 0!==e&&(r.Array===e||i[o]===e)}},function(e,t,n){var r=n(185),o=n(35)("iterator"),i=n(100);e.exports=function(e){if(null!=e)return e[o]||e["@@iterator"]||i[r(e)]}},function(e,t,n){var i=n(45);e.exports=function(t,e,n,r){try{return r?e(i(n)[0],n[1]):e(n)}catch(e){var o=t.return;throw void 0!==o&&i(o.call(t)),e}}},function(e,t,n){var o=n(35)("iterator"),i=!1;try{var r=0,a={next:function(){return{done:!!r++}},return:function(){i=!0}};a[o]=function(){return this},Array.from(a,function(){throw 2})}catch(e){}e.exports=function(e,t){if(!t&&!i)return!1;var n=!1;try{var r={};r[o]=function(){return{next:function(){return{done:n=!0}}}},e(r)}catch(e){}return n}},function(e,t){e.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},function(e,t,n){"use strict";var u=n(49).f,c=n(99),h=n(147),d=n(101),f=n(148),g=n(149),a=n(144),s=n(193),v=n(52),p=n(123).fastKey,r=n(87),m=r.set,y=r.getterFor;e.exports={getConstructor:function(e,n,r,o){var i=e(function(e,t){f(e,i,n),m(e,{type:n,index:c(null),first:void 0,last:void 0,size:0}),v||(e.size=0),null!=t&&g(t,e[o],e,r)}),s=y(n),a=function(e,t,n){var r,o,i=s(e),a=l(e,t);return a?a.value=n:(i.last=a={index:o=p(t,!0),key:t,value:n,previous:r=i.last,next:void 0,removed:!1},i.first||(i.first=a),r&&(r.next=a),v?i.size++:e.size++,"F"!==o&&(i.index[o]=a)),e},l=function(e,t){var n,r=s(e),o=p(t);if("F"!==o)return r.index[o];for(n=r.first;n;n=n.next)if(n.key==t)return n};return h(i.prototype,{clear:function(){for(var e=s(this),t=e.index,n=e.first;n;)n.removed=!0,n.previous&&(n.previous=n.previous.next=void 0),delete t[n.index],n=n.next;e.first=e.last=void 0,v?e.size=0:this.size=0},delete:function(e){var t=s(this),n=l(this,e);if(n){var r=n.next,o=n.previous;delete t.index[n.index],n.removed=!0,o&&(o.next=r),r&&(r.previous=o),t.first==n&&(t.first=r),t.last==n&&(t.last=o),v?t.size--:this.size--}return!!n},forEach:function(e){for(var t,n=s(this),r=d(e,1<arguments.length?arguments[1]:void 0,3);t=t?t.next:n.first;)for(r(t.value,t.key,this);t&&t.removed;)t=t.previous},has:function(e){return!!l(this,e)}}),h(i.prototype,r?{get:function(e){var t=l(this,e);return t&&t.value},set:function(e,t){return a(this,0===e?0:e,t)}}:{add:function(e){return a(this,e=0===e?0:e,e)}}),v&&u(i.prototype,"size",{get:function(){return s(this).size}}),i},setStrong:function(e,t,n){var r=t+" Iterator",o=y(t),i=y(r);a(e,t,function(e,t){m(this,{type:r,target:e,state:o(e),kind:t,last:void 0})},function(){for(var e=i(this),t=e.kind,n=e.last;n&&n.removed;)n=n.previous;return e.target&&(e.last=n=n?n.next:e.state.first)?"keys"==t?{value:n.key,done:!1}:"values"==t?{value:n.value,done:!1}:{value:[n.key,n.value],done:!1}:{value:e.target=void 0,done:!0}},n?"entries":"values",!n,!0),s(t)}}},function(e,t,n){"use strict";var r=n(516),o=n(49),i=n(52),a=n(35)("species");e.exports=function(e){var t=r(e),n=o.f;i&&t&&!t[a]&&n(t,a,{confi