@progress/kendo-spreadsheet-common 1.1.3-develop.2 → 1.2.0-develop.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/dist/index-esm.js +586 -426
  2. package/dist/index.js +674 -424
  3. package/package.json +6 -5
package/dist/index.js CHANGED
@@ -1065,13 +1065,18 @@
1065
1065
  PAGEDOWN: 34,
1066
1066
  F2: 113,
1067
1067
  F10: 121,
1068
+ F11: 122,
1068
1069
  F12: 123,
1069
1070
  NUMPAD_PLUS: 107,
1070
1071
  NUMPAD_MINUS: 109,
1071
1072
  NUMPAD_DOT: 110,
1072
1073
  B: 66,
1073
1074
  I: 73,
1074
- U: 85
1075
+ U: 85,
1076
+ N: 78,
1077
+ H: 72,
1078
+ A: 65,
1079
+ R: 82
1075
1080
  };
1076
1081
 
1077
1082
  /* eslint-disable no-nested-ternary */
@@ -1166,66 +1171,36 @@
1166
1171
  }
1167
1172
  }
1168
1173
 
1169
- const wrapExpression = function(members, paramName) {
1170
- let result = paramName || "d",
1171
- index,
1172
- idx,
1173
- length,
1174
- member,
1175
- count = 1;
1176
-
1177
- for (idx = 0, length = members.length; idx < length; idx++) {
1178
- member = members[idx];
1179
- if (member !== "") {
1180
- index = member.indexOf("[");
1181
-
1182
- if (index !== 0) {
1183
- if (index === -1) {
1184
- member = "." + member;
1185
- } else {
1186
- count++;
1187
- member = "." + member.substring(0, index) + " || {})" + member.substring(index);
1188
- }
1189
- }
1190
-
1191
- count++;
1192
- result += member + ((idx < length - 1) ? " || {})" : ")");
1193
- }
1194
- }
1195
- return new Array(count).join("(") + result;
1196
- };
1197
-
1198
1174
  const getterCache = {};
1199
1175
 
1200
- function expr(expression, safe, paramName) {
1201
- expression = expression || "";
1202
-
1203
- if (typeof safe == 'string') {
1204
- paramName = safe;
1205
- safe = false;
1206
- }
1176
+ getterCache["undefined"] = (obj) => obj;
1207
1177
 
1208
- paramName = paramName || "d";
1178
+ const FIELD_REGEX = /\[(?:(\d+)|['"](.*?)['"])\]|((?:(?!\[.*?\]|\.).)+)/g;
1179
+ function getter(field, safe) {
1180
+ const key = field + safe;
1209
1181
 
1210
- if (expression && expression.charAt(0) !== "[") {
1211
- expression = "." + expression;
1182
+ if (getterCache[key]) {
1183
+ return getterCache[key];
1212
1184
  }
1213
1185
 
1214
- if (safe) {
1215
- expression = expression.replace(/"([^.]*)\.([^"]*)"/g,'"$1_$DOT$_$2"');
1216
- expression = expression.replace(/'([^.]*)\.([^']*)'/g,"'$1_$DOT$_$2'");
1217
- expression = wrapExpression(expression.split("."), paramName);
1218
- expression = expression.replace(/_\$DOT\$_/g, ".");
1219
- } else {
1220
- expression = paramName + expression;
1221
- }
1186
+ const fields = [];
1187
+ field.replace(FIELD_REGEX, (_, index, indexAccessor, field) => {
1188
+ fields.push(isPresent(index) ? index : indexAccessor || field);
1189
+ return undefined;
1190
+ });
1222
1191
 
1223
- return expression;
1224
- }
1192
+ getterCache[key] = (obj) => {
1193
+ let result = obj;
1194
+ for (let idx = 0; idx < fields.length; idx++) {
1195
+ result = result[fields[idx]];
1196
+ if (!isPresent(result) && safe) {
1197
+ return result;
1198
+ }
1199
+ }
1200
+
1201
+ return result;
1202
+ };
1225
1203
 
1226
- function getter(expression, safe) {
1227
- let key = expression + safe;
1228
- getterCache[key] = getterCache[key] || new Function("d", "return " + expr(expression, safe));
1229
1204
  return getterCache[key];
1230
1205
  }
1231
1206
 
@@ -1240,15 +1215,10 @@
1240
1215
  return destination;
1241
1216
  }
1242
1217
 
1243
- function isFunction(fn) {
1244
- return typeof fn === "function";
1245
- }
1246
-
1247
1218
  function deepExtendOne(destination, source) {
1248
1219
  let property,
1249
1220
  propValue,
1250
1221
  propType,
1251
- propInit,
1252
1222
  destProp;
1253
1223
 
1254
1224
  for (property in source) {
@@ -1259,29 +1229,18 @@
1259
1229
  propValue = source[property];
1260
1230
  propType = typeof propValue;
1261
1231
 
1262
- if (propType === 'object' && propValue !== null) {
1263
- propInit = propValue.constructor;
1264
- } else {
1265
- propInit = null;
1266
- }
1267
-
1268
- if (propInit &&
1269
- propInit !== Array && propInit !== RegExp &&
1270
- (!isFunction(window.ArrayBuffer) || propInit !== ArrayBuffer) && !(propValue instanceof HTMLElement)) {
1271
-
1272
- if (propValue instanceof Date) {
1273
- destination[property] = new Date(propValue.getTime());
1274
- } else if (isFunction(propValue.clone)) {
1275
- destination[property] = propValue.clone();
1276
- } else {
1277
- destProp = destination[property];
1278
- if (typeof (destProp) === 'object') {
1279
- destination[property] = destProp || {};
1280
- } else {
1281
- destination[property] = {};
1282
- }
1283
- deepExtendOne(destination[property], propValue);
1232
+ if (propValue instanceof Date) {
1233
+ destination[property] = new Date(propValue.getTime());
1234
+ } else if (isFunction(propValue?.clone)) {
1235
+ destination[property] = propValue.clone();
1236
+ } else if (propType === 'object' && propValue !== null && isPlainObject(propValue)) {
1237
+ // Check if the property is a plain object before attempting to merge deeply
1238
+ destProp = destination[property];
1239
+ if (typeof destProp !== 'object' || destProp === null) {
1240
+ destination[property] = {};
1284
1241
  }
1242
+
1243
+ deepExtendOne(destination[property], propValue);
1285
1244
  } else if (propType !== 'undefined') {
1286
1245
  destination[property] = propValue;
1287
1246
  }
@@ -1317,7 +1276,12 @@
1317
1276
  let div = document.createElement("div"),
1318
1277
  result;
1319
1278
 
1320
- div.style.cssText = "overflow:scroll;overflow-x:hidden;zoom:1;clear:both;display:block";
1279
+ div.style.overflow = "scroll";
1280
+ div.style.overflowX = "hidden";
1281
+ div.style.zoom = "1";
1282
+ div.style.clear = "both";
1283
+ div.style.display = "block";
1284
+
1321
1285
  div.innerHTML = "&nbsp;";
1322
1286
  document.body.appendChild(div);
1323
1287
 
@@ -1392,6 +1356,21 @@
1392
1356
  }
1393
1357
  };
1394
1358
 
1359
+ const isPresent = (value) => value !== null && value !== undefined;
1360
+ const isBlank = (value) => !isPresent(value);
1361
+ const isDate = (value) => value && value.getTime;
1362
+ const isString = (value) => typeof value === "string";
1363
+ const isNumeric = (value) => !isNaN(value - parseFloat(value));
1364
+ const isFunction = (fn) => typeof fn === "function";
1365
+ const isPlainObject = function(obj) {
1366
+ if (!obj || toString.call(obj) !== "[object Object]") {
1367
+ return false;
1368
+ }
1369
+
1370
+ const proto = Object.getPrototypeOf(obj);
1371
+ return proto === null || proto.constructor === Object;
1372
+ };
1373
+
1395
1374
  class CalcError {
1396
1375
 
1397
1376
  constructor(code) {
@@ -1429,6 +1408,9 @@
1429
1408
  }
1430
1409
 
1431
1410
  /* eslint-disable max-params */
1411
+ /* eslint-disable complexity */
1412
+ /* eslint-disable no-unused-vars */
1413
+
1432
1414
 
1433
1415
  let calc = {
1434
1416
  runtime: {
@@ -2964,7 +2946,7 @@
2964
2946
  }
2965
2947
  Element.prototype = new Node();
2966
2948
  Element.prototype.appendTo = function(parent) {
2967
- let node = document.createElement(this.nodeName);
2949
+ let node = typeof(this.nodeName) === "string" ? document.createElement(this.nodeName) : this.nodeName;
2968
2950
  let children = this.children;
2969
2951
  for (let index = 0; index < children.length; index++) {
2970
2952
  children[index].render(node, NULL_NODE);
@@ -3185,6 +3167,7 @@
3185
3167
 
3186
3168
  //--------------------------------------------------- custom number format.
3187
3169
 
3170
+
3188
3171
  let RX_COLORS = /^\[(black|green|white|blue|magenta|yellow|cyan|red)\]/i;
3189
3172
  let RX_CONDITION = /^\[(<=|>=|<>|<|>|=)(-?[0-9.]+)\]/;
3190
3173
 
@@ -4150,6 +4133,28 @@
4150
4133
  };
4151
4134
 
4152
4135
  /* eslint-disable no-nested-ternary */
4136
+ /* eslint-disable space-infix-ops */
4137
+ /* eslint-disable indent */
4138
+ /* eslint-disable no-empty */
4139
+ /* eslint-disable no-loop-func */
4140
+ /* eslint-disable consistent-return */
4141
+ /* eslint-disable block-scoped-var */
4142
+ /* eslint-disable no-redeclare */
4143
+ /* eslint-disable no-var */
4144
+ /* eslint-disable eqeqeq */
4145
+ /* eslint-disable complexity */
4146
+ /* eslint-disable max-params */
4147
+ /* eslint-disable no-implicit-coercion */
4148
+ /* eslint-disable key-spacing */
4149
+ /* eslint-disable default-case */
4150
+ /* eslint-disable camelcase */
4151
+ /* eslint-disable brace-style */
4152
+ /* eslint-disable no-else-return */
4153
+ /* eslint-disable no-constant-condition */
4154
+ /* eslint-disable no-param-reassign */
4155
+ /* eslint-disable space-before-blocks */
4156
+ /* eslint-disable no-unused-labels */
4157
+
4153
4158
 
4154
4159
  const kendo = createKendoObj(calc, CalcError, Ref, CellRef, RangeRef);
4155
4160
  calc.kendo = kendo; // XXX
@@ -5955,6 +5960,12 @@
5955
5960
  }
5956
5961
 
5957
5962
  /* eslint-disable default-case */
5963
+ /* eslint-disable no-else-return */
5964
+ /* eslint-disable key-spacing */
5965
+ /* eslint-disable eqeqeq */
5966
+ /* eslint-disable brace-style */
5967
+ /* eslint-disable consistent-return */
5968
+
5958
5969
 
5959
5970
  let alphaNumRegExp = /:alphanum$/;
5960
5971
 
@@ -6580,6 +6591,7 @@
6580
6591
  this._workbook.trigger("contextmenu", {
6581
6592
  objectRef: object.ref,
6582
6593
  targetType: object.type,
6594
+ isComposite,
6583
6595
  showUnhide,
6584
6596
  showUnmerge,
6585
6597
  originalEvent: event
@@ -7094,7 +7106,7 @@
7094
7106
  this.clipboardElement.focus();
7095
7107
  this.navigator.navigateInSelection(ENTRY_ACTIONS[action]);
7096
7108
  }
7097
-
7109
+
7098
7110
  if (action === 'tab') {
7099
7111
  e.preventDefault();
7100
7112
  }
@@ -7797,6 +7809,9 @@
7797
7809
  }
7798
7810
 
7799
7811
  /* eslint-disable default-case */
7812
+ /* eslint-disable camelcase */
7813
+ /* eslint-disable no-param-reassign */
7814
+
7800
7815
 
7801
7816
  class Property {
7802
7817
  constructor(list) {
@@ -8120,6 +8135,10 @@
8120
8135
  }, [ "borderTop", "borderRight", "borderBottom", "borderLeft" ]);
8121
8136
 
8122
8137
  /* eslint-disable no-param-reassign */
8138
+ /* eslint-disable no-useless-call */
8139
+ /* eslint-disable camelcase */
8140
+ /* eslint-disable default-case */
8141
+
8123
8142
 
8124
8143
  let TRANSPOSE_FORMAT = "_matrix({0})";
8125
8144
  let DATE_FORMAT = 'DATEVALUE("{0}")';
@@ -8451,6 +8470,28 @@
8451
8470
  validationExport.Validation = Validation;
8452
8471
 
8453
8472
  /* eslint-disable no-nested-ternary */
8473
+ /* eslint-disable curly */
8474
+ /* eslint-disable space-infix-ops */
8475
+ /* eslint-disable indent */
8476
+ /* eslint-disable no-empty */
8477
+ /* eslint-disable no-loop-func */
8478
+ /* eslint-disable consistent-return */
8479
+ /* eslint-disable block-scoped-var */
8480
+ /* eslint-disable no-redeclare */
8481
+ /* eslint-disable no-var */
8482
+ /* eslint-disable eqeqeq */
8483
+ /* eslint-disable complexity */
8484
+ /* eslint-disable max-params */
8485
+ /* eslint-disable no-implicit-coercion */
8486
+ /* eslint-disable key-spacing */
8487
+ /* eslint-disable default-case */
8488
+ /* eslint-disable camelcase */
8489
+ /* eslint-disable brace-style */
8490
+ /* eslint-disable no-else-return */
8491
+ /* eslint-disable no-constant-condition */
8492
+ /* eslint-disable no-param-reassign */
8493
+ /* eslint-disable space-before-blocks */
8494
+
8454
8495
  const { measureText } = kendoDrawing.drawing.util;
8455
8496
 
8456
8497
  let PROPERTIES = [
@@ -9407,13 +9448,18 @@
9407
9448
 
9408
9449
  function getTextHeight(text, width, fontFamily, fontSize, wrap) {
9409
9450
  const measureBox = document.createElement("div");
9410
- measureBox.setAttribute(
9411
- "style",
9412
- "position: absolute !important; top: -4000px !important; height: auto !important;" +
9413
- "padding: 1px 3px !important; box-sizing: border-box; margin: 0 !important; border: 1px solid black !important;" +
9414
- "line-height: normal !important; visibility: hidden !important;" +
9415
- "white-space: pre-wrap;"
9416
- );
9451
+
9452
+ measureBox.style.setProperty('position', 'absolute', 'important');
9453
+ measureBox.style.setProperty('top', '-4000px', 'important');
9454
+ measureBox.style.setProperty('height', 'auto', 'important');
9455
+ measureBox.style.setProperty('padding', '1px 3px', 'important');
9456
+ measureBox.style.setProperty('box-sizing', 'border-box', 'important');
9457
+ measureBox.style.setProperty('margin', '0', 'important');
9458
+ measureBox.style.setProperty('border', '1px solid black', 'important');
9459
+ measureBox.style.setProperty('line-height', 'normal', 'important');
9460
+ measureBox.style.setProperty('visibility', 'hidden', 'important');
9461
+ measureBox.style.setProperty('white-space', 'pre-wrap');
9462
+
9417
9463
  let styles = {
9418
9464
  "baselineMarkerSize" : 0,
9419
9465
  "width" : (wrap === true) ? width + "px" : "auto",
@@ -10505,6 +10551,7 @@
10505
10551
  }
10506
10552
 
10507
10553
  /* eslint-disable no-param-reassign */
10554
+ /* eslint-disable camelcase */
10508
10555
 
10509
10556
  class Rectangle {
10510
10557
  constructor(left, top, width, height) {
@@ -10892,6 +10939,9 @@
10892
10939
  };
10893
10940
 
10894
10941
  /* eslint-disable no-constant-condition */
10942
+ /* eslint-disable key-spacing */
10943
+ /* eslint-disable no-param-reassign */
10944
+
10895
10945
 
10896
10946
  class AxisManager {
10897
10947
  constructor(sheet) {
@@ -11202,6 +11252,21 @@
11202
11252
  }
11203
11253
 
11204
11254
  /* eslint-disable max-params */
11255
+ /* eslint-disable no-empty */
11256
+ /* eslint-disable no-loop-func */
11257
+ /* eslint-disable consistent-return */
11258
+ /* eslint-disable block-scoped-var */
11259
+ /* eslint-disable no-redeclare */
11260
+ /* eslint-disable no-var */
11261
+ /* eslint-disable eqeqeq */
11262
+ /* eslint-disable complexity */
11263
+ /* eslint-disable no-implicit-coercion */
11264
+ /* eslint-disable brace-style */
11265
+ /* eslint-disable key-spacing */
11266
+ /* eslint-disable no-else-return */
11267
+ /* eslint-disable default-case */
11268
+ /* eslint-disable no-param-reassign */
11269
+
11205
11270
 
11206
11271
  class EdgeNavigator {
11207
11272
  constructor(field, axis, rangeGetter, union) {
@@ -11876,16 +11941,41 @@
11876
11941
  }
11877
11942
 
11878
11943
  /* eslint-disable max-params */
11944
+ /* eslint-disable no-empty */
11945
+ /* eslint-disable no-loop-func */
11946
+ /* eslint-disable consistent-return */
11947
+ /* eslint-disable block-scoped-var */
11948
+ /* eslint-disable no-redeclare */
11949
+ /* eslint-disable no-var */
11950
+ /* eslint-disable eqeqeq */
11951
+ /* eslint-disable complexity */
11952
+ /* eslint-disable no-implicit-coercion */
11953
+ /* eslint-disable brace-style */
11954
+ /* eslint-disable key-spacing */
11955
+ /* eslint-disable no-else-return */
11956
+ /* eslint-disable default-case */
11957
+ /* eslint-disable no-param-reassign */
11958
+
11879
11959
 
11880
11960
  function numberToDate(val) {
11881
11961
  return val == null ? null : calc.runtime.serialToDate(val);
11882
11962
  }
11883
11963
 
11884
- var identity = function(o) { return o; };
11964
+ function dateToNumber(val) {
11965
+ return val == null ? null : calc.runtime.dateToSerial(val);
11966
+ }
11967
+
11968
+ var identity = function (o) { return o; };
11885
11969
 
11886
11970
  class SheetDataSourceBinder {
11887
11971
  constructor(options) {
11888
- this.options = Object.assign({ columns: [] }, this.options, options);
11972
+ this.options = Object.assign({ columns: [] }, this.options,
11973
+ // skip undefined properties in options
11974
+ Object.keys(options).reduce((acc, key) => {
11975
+ if (options[key] !== undefined) acc[key] = options[key];
11976
+ return acc;
11977
+ }, {})
11978
+ );
11889
11979
 
11890
11980
  this.columns = this._normalizeColumns(this.options.columns);
11891
11981
 
@@ -11929,9 +12019,9 @@
11929
12019
  }
11930
12020
 
11931
12021
  _header() {
11932
- this.sheet.batch(function() {
11933
- this.columns.forEach(function(column, index) {
11934
- this.sheet.range(0,index).value(column.title);
12022
+ this.sheet.batch(function () {
12023
+ this.columns.forEach(function (column, index) {
12024
+ this.sheet.range(0, index).value(column.title);
11935
12025
  }.bind(this));
11936
12026
  }.bind(this));
11937
12027
  }
@@ -11949,7 +12039,7 @@
11949
12039
  var values = [];
11950
12040
  var sheet = this.sheet;
11951
12041
  var fields, getters, normalizedRef, i, rangeRef, normalizedRefs;
11952
- var setValues = function(ref) {
12042
+ var setValues = function (ref) {
11953
12043
  ref = ref.toRangeRef();
11954
12044
  var record;
11955
12045
  var valueIndex = 0;
@@ -11978,7 +12068,7 @@
11978
12068
  columns = Object.keys(data[0].toJSON());
11979
12069
  }
11980
12070
 
11981
- getters = columns.map(function(column) {
12071
+ getters = columns.map(function (column) {
11982
12072
  var field = column.field;
11983
12073
  if (field && fields && fields[field] && fields[field].type === "date") {
11984
12074
  return numberToDate;
@@ -11995,7 +12085,7 @@
11995
12085
 
11996
12086
  normalizedRefs = normalizedRef.refs;
11997
12087
 
11998
- normalizedRefs.forEach(function(ref) {
12088
+ normalizedRefs.forEach(function (ref) {
11999
12089
  values.push(sheet.range(ref).values());
12000
12090
  });
12001
12091
 
@@ -12011,7 +12101,7 @@
12011
12101
  }
12012
12102
 
12013
12103
  _normalizeColumns(columns) {
12014
- return columns.map(function(column) {
12104
+ return columns.map(function (column) {
12015
12105
  var field = column.field || column;
12016
12106
  return {
12017
12107
  field: field,
@@ -12023,23 +12113,23 @@
12023
12113
  _dataSource() {
12024
12114
  var options = this.options;
12025
12115
  var dataSource = options.dataSource;
12026
- this.dataSource = { data: dataSource };
12027
- // dataSource = Array.isArray(dataSource) ? { data: dataSource } : dataSource;
12028
-
12029
- // if (this.dataSource && this._changeHandler) {
12030
- // this.dataSource.unbind("change", this._changeHandler)
12031
- // .unbind("progress", this._progressHandler)
12032
- // .unbind("error", this._errorHandler);
12033
- // } else {
12034
- // this._changeHandler = this._change.bind(this);
12035
- // this._progressHandler = this._requestStart.bind(this);
12036
- // this._errorHandler = this._error.bind(this);
12037
- // }
12038
12116
 
12039
- // this.dataSource = kendo.data.DataSource.create(dataSource)
12040
- // .bind("change", this._changeHandler)
12041
- // .bind("progress", this._progressHandler)
12042
- // .bind("error", this._errorHandler);
12117
+ dataSource = Array.isArray(dataSource) ? { data: dataSource } : dataSource;
12118
+
12119
+ if (this.dataSource && this._changeHandler) {
12120
+ this.dataSource.unbind("change", this._changeHandler)
12121
+ .unbind("progress", this._progressHandler)
12122
+ .unbind("error", this._errorHandler);
12123
+ } else {
12124
+ this._changeHandler = this._change.bind(this);
12125
+ this._progressHandler = this._requestStart.bind(this);
12126
+ this._errorHandler = this._error.bind(this);
12127
+ }
12128
+
12129
+ this.dataSource = this.options.sheet.createSheetDataSource?.(dataSource)
12130
+ .bind("change", this._changeHandler)
12131
+ .bind("progress", this._progressHandler)
12132
+ .bind("error", this._errorHandler);
12043
12133
  }
12044
12134
 
12045
12135
  _error() {
@@ -12073,11 +12163,11 @@
12073
12163
  this._header();
12074
12164
  }
12075
12165
 
12076
- var getters = columns.map(function(column) {
12166
+ var getters = columns.map(function (column) {
12077
12167
  return getter(column.field);
12078
12168
  });
12079
12169
 
12080
- this.sheet.batch(function() {
12170
+ this.sheet.batch(function () {
12081
12171
  var length = Math.max(data.length, this._boundRowsCount, this.sheet._grid.rowCount - 1);
12082
12172
 
12083
12173
  for (var idx = 0; idx < length; idx++) {
@@ -12127,214 +12217,154 @@
12127
12217
  })();
12128
12218
 
12129
12219
  /* eslint-disable no-var */
12220
+ /* eslint-disable no-implicit-coercion */
12221
+ /* eslint-disable no-param-reassign */
12222
+ /* eslint-disable no-loop-func */
12130
12223
 
12131
- const dateRegExp = /^\/Date\((.*?)\)\/$/;
12132
12224
 
12133
- var operators = (function() {
12225
+ const logic = {
12226
+ or: {
12227
+ concat: (acc, fn) => (a) => acc(a) || fn(a),
12228
+ identity: () => false,
12229
+ },
12230
+ and: {
12231
+ concat: (acc, fn) => (a) => acc(a) && fn(a),
12232
+ identity: () => true,
12233
+ },
12234
+ };
12235
+
12236
+ const operatorsMap = {
12237
+ contains: (a, b) => (a || "").indexOf(b) >= 0,
12238
+ doesnotcontain: (a, b) => (a || "").indexOf(b) === -1,
12239
+ doesnotendwith: (a, b) =>
12240
+ (a || "").indexOf(b, (a || "").length - (b || "").length) < 0,
12241
+ doesnotstartwith: (a, b) => (a || "").lastIndexOf(b, 0) === -1,
12242
+ endswith: (a, b) =>
12243
+ (a || "").indexOf(b, (a || "").length - (b || "").length) >= 0,
12244
+ eq: (a, b) => a === b,
12245
+ gt: (a, b) => a > b,
12246
+ gte: (a, b) => a >= b,
12247
+ isempty: (a) => a === "",
12248
+ isnotempty: (a) => a !== "",
12249
+ isnotnull: (a) => isPresent(a),
12250
+ isnull: (a) => isBlank(a),
12251
+ lt: (a, b) => a < b,
12252
+ lte: (a, b) => a <= b,
12253
+ neq: (a, b) => a != b, // tslint:disable-line:triple-equals
12254
+ startswith: (a, b) => (a || "").lastIndexOf(b, 0) === 0,
12255
+ };
12256
+
12257
+ const dateRegExp = /^\/Date\((.*?)\)\/$/;
12134
12258
 
12135
- function quote(str) {
12136
- if (typeof str == "string") {
12137
- str = str.replace(/[\r\n]+/g, "");
12259
+ const convertValue = (value, ignoreCase, accentFoldingFiltering) => {
12260
+ if (value != null && isString(value)) {
12261
+ const date = dateRegExp.exec(value);
12262
+ if (date) {
12263
+ return new Date(+date[1]).getTime();
12264
+ } else if (ignoreCase) {
12265
+ return accentFoldingFiltering
12266
+ ? value.toLocaleLowerCase(accentFoldingFiltering)
12267
+ : value.toLowerCase();
12138
12268
  }
12139
- return JSON.stringify(str);
12269
+ } else if (value != null && isDate(value)) {
12270
+ return value.getTime();
12140
12271
  }
12272
+ return value;
12273
+ };
12141
12274
 
12142
- function textOp(impl) {
12143
- return function(a, b, ignore, accentFoldingFiltering) {
12144
- b += "";
12145
- if (ignore) {
12146
- a = "(" + a + " + '').toString()" + ((accentFoldingFiltering) ? ".toLocaleLowerCase('" + accentFoldingFiltering + "')" : ".toLowerCase()");
12147
- b = ((accentFoldingFiltering) ? b.toLocaleLowerCase(accentFoldingFiltering) : b.toLowerCase());
12148
- }
12149
- return impl(a, quote(b), ignore);
12150
- };
12151
- }
12275
+ const transformFilter = ({
12276
+ field,
12277
+ ignoreCase,
12278
+ value,
12279
+ operator,
12280
+ accentFoldingFiltering,
12281
+ }) => {
12282
+ field = !isPresent(field) ? (a) => a : field;
12283
+
12284
+ ignoreCase = isPresent(ignoreCase) ? ignoreCase : true;
12285
+
12286
+ const itemProp = typedGetter(
12287
+ isFunction(field) ? field : getter(field, true),
12288
+ value,
12289
+ ignoreCase,
12290
+ accentFoldingFiltering
12291
+ );
12152
12292
 
12153
- function operator(op, a, b, ignore, accentFoldingFiltering) {
12154
- if (b != null) {
12155
- if (typeof b === 'string') {
12156
- var date = dateRegExp.exec(b);
12157
- if (date) {
12158
- b = new Date(+date[1]);
12159
- } else if (ignore) {
12160
- b = quote(((accentFoldingFiltering) ? b.toLocaleLowerCase(accentFoldingFiltering) : b.toLowerCase()));
12161
- a = "((" + a + " || '')+'')" + ((accentFoldingFiltering) ? ".toLocaleLowerCase('" + accentFoldingFiltering + "')" : ".toLowerCase()");
12162
- } else {
12163
- b = quote(b);
12164
- }
12165
- }
12293
+ value = convertValue(value, ignoreCase, accentFoldingFiltering);
12166
12294
 
12167
- if (b.getTime) {
12168
- //b looks like a Date
12169
- a = "(" + a + "&&" + a + ".getTime?" + a + ".getTime():" + a + ")";
12170
- b = b.getTime();
12171
- }
12172
- }
12295
+ const op = isFunction(operator) ? operator : operatorsMap[operator];
12173
12296
 
12174
- return a + " " + op + " " + b;
12175
- }
12297
+ return (a) => op(itemProp(a), value, ignoreCase);
12298
+ };
12176
12299
 
12177
- function getMatchRegexp(pattern) {
12178
- // take a pattern, as supported by Excel match filter, and
12179
- // convert it to the equivalent JS regular expression.
12180
- // Excel patterns support:
12181
- //
12182
- // * - match any sequence of characters
12183
- // ? - match a single character
12184
- //
12185
- // to match a literal * or ?, they must be prefixed by a tilde (~)
12186
- var rx = "/^";
12187
- for (var esc = false, i = 0; i < pattern.length; ++i) {
12188
- var ch = pattern.charAt(i);
12189
- if (esc) {
12190
- rx += "\\" + ch;
12191
- } else if (ch === "~") {
12192
- esc = true;
12193
- continue;
12194
- } else if (ch === "*") {
12195
- rx += ".*";
12196
- } else if (ch === "?") {
12197
- rx += ".";
12198
- } else if (".+^$()[]{}|\\/\n\r\u2028\u2029\xA0".indexOf(ch) >= 0) {
12199
- rx += "\\" + ch;
12200
- } else {
12201
- rx += ch;
12202
- }
12203
- esc = false;
12204
- }
12205
- return rx + "$/";
12300
+ const typedGetter = (prop, value, ignoreCase, accentFoldingFiltering) => {
12301
+ if (!isPresent(value)) {
12302
+ return prop;
12206
12303
  }
12207
12304
 
12208
- return {
12209
- quote: function(value) {
12210
- if (value && value.getTime) {
12211
- return "new Date(" + value.getTime() + ")";
12212
- }
12213
- return quote(value);
12214
- },
12215
- eq: function(a, b, ignore, accentFoldingFiltering) {
12216
- return operator("==", a, b, ignore, accentFoldingFiltering);
12217
- },
12218
- neq: function(a, b, ignore, accentFoldingFiltering) {
12219
- return operator("!=", a, b, ignore, accentFoldingFiltering);
12220
- },
12221
- gt: function(a, b, ignore) {
12222
- return operator(">", a, b, ignore);
12223
- },
12224
- gte: function(a, b, ignore) {
12225
- return operator(">=", a, b, ignore);
12226
- },
12227
- lt: function(a, b, ignore) {
12228
- return operator("<", a, b, ignore);
12229
- },
12230
- lte: function(a, b, ignore) {
12231
- return operator("<=", a, b, ignore);
12232
- },
12233
- startswith: textOp(function(a, b) {
12234
- return a + ".lastIndexOf(" + b + ", 0) == 0";
12235
- }),
12236
- doesnotstartwith: textOp(function(a, b) {
12237
- return a + ".lastIndexOf(" + b + ", 0) == -1";
12238
- }),
12239
- endswith: textOp(function(a, b) {
12240
- var n = b ? b.length - 2 : 0;
12241
- return a + ".indexOf(" + b + ", " + a + ".length - " + n + ") >= 0";
12242
- }),
12243
- doesnotendwith: textOp(function(a, b) {
12244
- var n = b ? b.length - 2 : 0;
12245
- return a + ".indexOf(" + b + ", " + a + ".length - " + n + ") < 0";
12246
- }),
12247
- contains: textOp(function(a, b) {
12248
- return a + ".indexOf(" + b + ") >= 0";
12249
- }),
12250
- doesnotcontain: textOp(function(a, b) {
12251
- return a + ".indexOf(" + b + ") == -1";
12252
- }),
12253
- matches: textOp(function(a, b) {
12254
- b = b.substring(1, b.length - 1);
12255
- return getMatchRegexp(b) + ".test(" + a + ")";
12256
- }),
12257
- doesnotmatch: textOp(function(a, b) {
12258
- b = b.substring(1, b.length - 1);
12259
- return "!" + getMatchRegexp(b) + ".test(" + a + ")";
12260
- }),
12261
- isempty: function(a) {
12262
- return a + " === ''";
12263
- },
12264
- isnotempty: function(a) {
12265
- return a + " !== ''";
12266
- },
12267
- isnull: function(a) {
12268
- return "(" + a + " == null)";
12269
- },
12270
- isnotnull: function(a) {
12271
- return "(" + a + " != null)";
12272
- },
12273
- isnullorempty: function(a) {
12274
- return "(" + a + " === null) || (" + a + " === '')";
12275
- },
12276
- isnotnullorempty: function(a) {
12277
- return "(" + a + " !== null) && (" + a + " !== '')";
12278
- }
12279
- };
12280
- })();
12281
-
12282
- const filterExpr = function(expression) {
12283
- var expressions = [],
12284
- logic = { and: " && ", or: " || " },
12285
- idx,
12286
- length,
12287
- filter,
12288
- expr$1,
12289
- fieldFunctions = [],
12290
- operatorFunctions = [],
12291
- field,
12292
- operator,
12293
- filters = expression.filters;
12294
-
12295
- for (idx = 0, length = filters.length; idx < length; idx++) {
12296
- filter = filters[idx];
12297
- field = filter.field;
12298
- operator = filter.operator;
12299
-
12300
- if (filter.filters) {
12301
- expr$1 = filterExpr(filter);
12302
- //Nested function fields or operators - update their index e.g. __o[0] -> __o[1]
12303
- filter = expr$1.expression
12304
- .replace(/__o\[(\d+)\]/g, function(match, index) {
12305
- index = +index;
12306
- return "__o[" + (operatorFunctions.length + index) + "]";
12307
- })
12308
- .replace(/__f\[(\d+)\]/g, function(match, index) {
12309
- index = +index;
12310
- return "__f[" + (fieldFunctions.length + index) + "]";
12311
- });
12305
+ let acc = prop;
12312
12306
 
12313
- operatorFunctions.push.apply(operatorFunctions, expr$1.operators);
12314
- fieldFunctions.push.apply(fieldFunctions, expr$1.fields);
12307
+ if (isString(value)) {
12308
+ const date = dateRegExp.exec(value);
12309
+ if (date) {
12310
+ value = new Date(+date[1]);
12315
12311
  } else {
12316
- if (typeof field === 'function') {
12317
- expr$1 = "__f[" + fieldFunctions.length + "](d)";
12318
- fieldFunctions.push(field);
12319
- } else {
12320
- expr$1 = expr(field);
12321
- }
12322
-
12323
- if (typeof operator === 'function') {
12324
- filter = "__o[" + operatorFunctions.length + "](" + expr$1 + ", " + operators.quote(filter.value) + ")";
12325
- operatorFunctions.push(operator);
12326
- } else {
12327
- filter = operators[(operator || "eq").toLowerCase()](expr$1, filter.value, filter.ignoreCase !== undefined ? filter.ignoreCase : true, expression.accentFoldingFiltering);
12328
- }
12312
+ acc = (a) => {
12313
+ const x = prop(a);
12314
+ if (typeof x === "string" && ignoreCase) {
12315
+ return accentFoldingFiltering
12316
+ ? x.toLocaleLowerCase(accentFoldingFiltering)
12317
+ : x.toLowerCase();
12318
+ } else {
12319
+ return isNumeric(x) ? x + "" : x;
12320
+ }
12321
+ };
12329
12322
  }
12323
+ }
12330
12324
 
12331
- expressions.push(filter);
12325
+ if (isDate(value)) {
12326
+ return (a) => {
12327
+ const x = acc(a);
12328
+ return isDate(x) ? x.getTime() : x;
12329
+ };
12332
12330
  }
12331
+ return acc;
12332
+ };
12333
12333
 
12334
- return { expression: "(" + expressions.join(logic[expression.logic]) + ")", fields: fieldFunctions, operators: operatorFunctions };
12334
+ const transformCompositeFilter = function (filter) {
12335
+ const accentFoldingFiltering = filter.accentFoldingFiltering;
12336
+ const combiner = logic[filter.logic || "and"];
12337
+
12338
+ return filter.filters
12339
+ .filter(isPresent)
12340
+ .map((x) => {
12341
+ const extendedFilter = isPresent(accentFoldingFiltering)
12342
+ ? deepExtend({}, x, { accentFoldingFiltering })
12343
+ : x;
12344
+
12345
+ return isPresent(x.filters)
12346
+ ? transformCompositeFilter(extendedFilter)
12347
+ : transformFilter(extendedFilter);
12348
+ })
12349
+ .reduce(combiner.concat, combiner.identity);
12335
12350
  };
12336
12351
 
12337
12352
  /* eslint-disable max-params */
12353
+ /* eslint-disable no-empty */
12354
+ /* eslint-disable no-loop-func */
12355
+ /* eslint-disable consistent-return */
12356
+ /* eslint-disable block-scoped-var */
12357
+ /* eslint-disable no-redeclare */
12358
+ /* eslint-disable no-var */
12359
+ /* eslint-disable eqeqeq */
12360
+ /* eslint-disable complexity */
12361
+ /* eslint-disable no-implicit-coercion */
12362
+ /* eslint-disable brace-style */
12363
+ /* eslint-disable key-spacing */
12364
+ /* eslint-disable no-else-return */
12365
+ /* eslint-disable default-case */
12366
+ /* eslint-disable no-param-reassign */
12367
+
12338
12368
 
12339
12369
  let filtersObj = {};
12340
12370
  const dateToSerial$1 = calc.runtime.dateToSerial;
@@ -12446,13 +12476,11 @@
12446
12476
 
12447
12477
  this._criteria = options.criteria;
12448
12478
 
12449
- var expression = filterExpr({
12479
+ this._matches = transformCompositeFilter({
12450
12480
  logic: this._logic,
12451
12481
  filters: this._criteria,
12452
- accentFoldingFiltering: culture().name
12453
- }).expression;
12454
-
12455
- this._matches = new Function("d", "return " + expression);
12482
+ accentFoldingFiltering: culture().name,
12483
+ });
12456
12484
  }
12457
12485
  matches(value) {
12458
12486
  if (value === null) {
@@ -12787,6 +12815,21 @@
12787
12815
  }
12788
12816
 
12789
12817
  /* eslint-disable max-params */
12818
+ /* eslint-disable no-empty */
12819
+ /* eslint-disable no-loop-func */
12820
+ /* eslint-disable consistent-return */
12821
+ /* eslint-disable block-scoped-var */
12822
+ /* eslint-disable no-redeclare */
12823
+ /* eslint-disable no-var */
12824
+ /* eslint-disable eqeqeq */
12825
+ /* eslint-disable complexity */
12826
+ /* eslint-disable no-implicit-coercion */
12827
+ /* eslint-disable brace-style */
12828
+ /* eslint-disable key-spacing */
12829
+ /* eslint-disable no-else-return */
12830
+ /* eslint-disable default-case */
12831
+ /* eslint-disable no-param-reassign */
12832
+
12790
12833
 
12791
12834
  // This is a “dynamic variable” (see Greenspun's 10th rule). It's
12792
12835
  // bound to an array via sheet._saveModifiedFormulas (which see)
@@ -12928,6 +12971,12 @@
12928
12971
  }
12929
12972
  }
12930
12973
 
12974
+ let EDITORS = {};
12975
+
12976
+ function registerEditor(name, editor) {
12977
+ EDITORS[name] = editor;
12978
+ }
12979
+
12931
12980
  class Sheet extends Observable {
12932
12981
  constructor() {
12933
12982
  super();
@@ -12949,10 +12998,35 @@
12949
12998
  "dataBound",
12950
12999
  "progress"
12951
13000
  ];
13001
+
13002
+ this.createSheetDataSource = Array.from(arguments).pop();
13003
+
12952
13004
  this._reinit.apply(this, arguments);
12953
13005
  }
12954
13006
 
12955
- activeCellCustomEditor() {}
13007
+ activeCellCustomEditor() {
13008
+ let cell = this.activeCell().first();
13009
+
13010
+ if (this.range(cell).enable()) {
13011
+ let val = this.validation(cell);
13012
+ let key = this._properties.get("editor", this._grid.cellRefIndex(cell));
13013
+ let editor;
13014
+
13015
+ if (key != null) {
13016
+ editor = EDITORS[key];
13017
+ }
13018
+ else if (val && val.showButton) {
13019
+ key = "_validation_" + val.dataType;
13020
+ editor = EDITORS[key];
13021
+ }
13022
+
13023
+ if (typeof editor == "function") {
13024
+ editor = EDITORS[key] = editor();
13025
+ }
13026
+
13027
+ return editor;
13028
+ }
13029
+ }
12956
13030
 
12957
13031
  _reinit(rowCount, columnCount, rowHeight, columnWidth, headerHeight, headerWidth, defaultCellStyle) {
12958
13032
  defaultCellStyle = defaultCellStyle || {};
@@ -13154,7 +13228,8 @@
13154
13228
  this.dataSourceBinder = new SheetDataSourceBinder({
13155
13229
  dataSource: dataSource,
13156
13230
  sheet: this,
13157
- columns: columns
13231
+ columns: columns,
13232
+ createSheetDataSource: this.createSheetDataSource
13158
13233
  });
13159
13234
 
13160
13235
  this.dataSource = this.dataSourceBinder.dataSource;
@@ -14959,6 +15034,13 @@
14959
15034
  }
14960
15035
 
14961
15036
  /* eslint-disable no-nested-ternary */
15037
+ /* eslint-disable default-case */
15038
+ /* eslint-disable no-implicit-coercion */
15039
+ /* eslint-disable no-else-return */
15040
+ /* eslint-disable key-spacing */
15041
+ /* eslint-disable eqeqeq */
15042
+ /* eslint-disable no-param-reassign */
15043
+
14962
15044
 
14963
15045
  let GUIDELINE_WIDTH = 0.8;
14964
15046
 
@@ -15600,7 +15682,7 @@
15600
15682
  }
15601
15683
  if (vtrans < 0) { vtrans = 0; }
15602
15684
 
15603
- let textGroup = kendoDrawing.drawDOM.drawText(CONT);
15685
+ let textGroup = kendoDrawing.drawText(CONT);
15604
15686
  textGroup.transform(kendoDrawing.geometry.Matrix.translate(cell.left, cell.top + vtrans));
15605
15687
  group.append(textGroup);
15606
15688
  }
@@ -16003,7 +16085,7 @@
16003
16085
  horizontalResize: "k-horizontal-resize",
16004
16086
  verticalResize: "k-vertical-resize",
16005
16087
  icon: "k-icon",
16006
- iconFilterDefault: "k-i-arrow-60-down",
16088
+ iconFilterDefault: "k-i-caret-alt-down",
16007
16089
  sheetsBar: "k-spreadsheet-sheets-bar",
16008
16090
  sheetsBarActive: "k-spreadsheet-sheets-bar-active",
16009
16091
  sheetsBarInactive: "k-spreadsheet-sheets-bar-inactive",
@@ -16054,6 +16136,7 @@
16054
16136
 
16055
16137
  /* eslint-disable complexity */
16056
16138
 
16139
+
16057
16140
  function cellBorder(value) {
16058
16141
  return (value.size || 1) + "px solid " + (value.color || "#000");
16059
16142
  }
@@ -16265,9 +16348,10 @@
16265
16348
  }
16266
16349
 
16267
16350
  class Pane {
16268
- constructor(sheet, grid) {
16351
+ constructor(sheet, grid, getIconHTMLString) {
16269
16352
  this._sheet = sheet;
16270
16353
  this._grid = grid;
16354
+ this.getIconHTMLString = getIconHTMLString;
16271
16355
  }
16272
16356
 
16273
16357
  refresh(width, height) {
@@ -16623,18 +16707,23 @@
16623
16707
  );
16624
16708
  }
16625
16709
 
16710
+ icon(className) {
16711
+ if (typeof this.getIconHTMLString === "function") {
16712
+ return dom.element(this.getIconHTMLString(className));
16713
+ }
16714
+
16715
+ return dom.element("span", {
16716
+ className: viewClassNames.icon + " " + className
16717
+ });
16718
+ }
16719
+
16626
16720
  renderFilterHeaders() {
16721
+ let pane = this;
16627
16722
  let sheet = this._sheet;
16628
16723
  let children = [];
16629
16724
  let classNames = viewClassNames;
16630
16725
  let filter = sheet.filter();
16631
16726
 
16632
- function icon(className) {
16633
- return dom.element("span", {
16634
- className: classNames.icon + " " + className
16635
- });
16636
- }
16637
-
16638
16727
  function filterButton(classNames, position, index) {
16639
16728
  let style = {
16640
16729
  left: position.left + "px",
@@ -16652,7 +16741,7 @@
16652
16741
  let button = dom.element(
16653
16742
  "span",
16654
16743
  { className: classes, style: style },
16655
- [ icon(classNames.iconFilterDefault) ]
16744
+ [ pane.icon(classNames.iconFilterDefault) ]
16656
16745
  );
16657
16746
 
16658
16747
  return button;
@@ -16809,11 +16898,11 @@
16809
16898
  height : cell.height + "px"
16810
16899
  }
16811
16900
  });
16901
+
16812
16902
  if (ed.icon) {
16813
- btn.children.push(dom.element("span", {
16814
- className: "k-icon " + ed.icon
16815
- }));
16903
+ btn.children.push(self.icon(ed.icon));
16816
16904
  }
16905
+
16817
16906
  collection.push(btn);
16818
16907
  });
16819
16908
  }
@@ -16888,6 +16977,11 @@
16888
16977
  }
16889
16978
 
16890
16979
  /* eslint-disable no-unused-vars */
16980
+ /* eslint-disable no-param-reassign */
16981
+ /* eslint-disable no-else-return */
16982
+ /* eslint-disable no-multi-spaces */
16983
+ /* eslint-disable no-nested-ternary */
16984
+
16891
16985
 
16892
16986
  let styles = [
16893
16987
  "font-family",
@@ -17028,24 +17122,9 @@
17028
17122
  end = begin;
17029
17123
  }
17030
17124
  if (begin && end) {
17031
- let range = document.createRange();
17032
- range.setStart(begin.node, begin.pos);
17033
- range.setEnd(end.node, end.pos);
17034
- let sel = window.getSelection();
17035
- let currentRange = sel.getRangeAt(0);
17036
- if (differ(range, currentRange)) {
17037
- sel.removeAllRanges();
17038
- sel.addRange(range);
17039
- }
17040
- }
17041
- function differ(a, b) {
17042
- return (
17043
- a.startOffset !== b.startOffset ||
17044
- a.endOffset !== b.endOffset ||
17045
- a.startContainer !== b.endContainer ||
17046
- a.endContainer !== b.endContainer
17047
- );
17125
+ this._setRange(begin, end);
17048
17126
  }
17127
+
17049
17128
  function lookup(node, pos) {
17050
17129
  try {
17051
17130
  (function loop(node) {
@@ -17083,6 +17162,27 @@
17083
17162
  return this.value().length;
17084
17163
  }
17085
17164
 
17165
+ _setRange(begin, end) {
17166
+ let range = document.createRange();
17167
+ range.setStart(begin.node, begin.pos);
17168
+ range.setEnd(end.node, end.pos);
17169
+ let sel = window.getSelection();
17170
+ let currentRange = sel.getRangeAt(0);
17171
+ if (differ(range, currentRange)) {
17172
+ sel.removeAllRanges();
17173
+ sel.addRange(range);
17174
+ }
17175
+
17176
+ function differ(a, b) {
17177
+ return (
17178
+ a.startOffset !== b.startOffset ||
17179
+ a.endOffset !== b.endOffset ||
17180
+ a.startContainer !== b.endContainer ||
17181
+ a.endContainer !== b.endContainer
17182
+ );
17183
+ }
17184
+ }
17185
+
17086
17186
  _formulaSource() {
17087
17187
  let result = [];
17088
17188
  let value;
@@ -17213,8 +17313,9 @@
17213
17313
  return true;
17214
17314
  }
17215
17315
  if (key === keys.ENTER || key === keys.TAB) {
17216
- if (list.data()[list.focus()]) {
17217
- this._formulaListChange(list.data()[list.focus()].value);
17316
+ let focusIndex = typeof list.focusIndex === "function" ? list.focusIndex() : list.focus();
17317
+ if (list.data()[focusIndex]) {
17318
+ this._formulaListChange(list.data()[focusIndex].value);
17218
17319
  }
17219
17320
 
17220
17321
  popup.close();
@@ -17742,6 +17843,13 @@
17742
17843
  }
17743
17844
 
17744
17845
  /* eslint-disable complexity */
17846
+ /* eslint-disable consistent-return */
17847
+ /* eslint-disable default-case */
17848
+ /* eslint-disable no-implicit-coercion */
17849
+ /* eslint-disable no-nested-ternary */
17850
+ /* eslint-disable key-spacing */
17851
+ /* eslint-disable no-param-reassign */
17852
+
17745
17853
 
17746
17854
  function selectElementContents(el) {
17747
17855
  let sel = window.getSelection();
@@ -17845,7 +17953,7 @@
17845
17953
  break;
17846
17954
  case "boolean":
17847
17955
  style.textAlign = "center";
17848
- break;
17956
+ break;
17849
17957
  }
17850
17958
  }
17851
17959
 
@@ -17936,7 +18044,7 @@
17936
18044
  text = dom.text(text);
17937
18045
  }
17938
18046
 
17939
- let children = [ text ];
18047
+ let children = [text];
17940
18048
 
17941
18049
  if (validation && !validation.value) {
17942
18050
  children.push(dom.element("span", { className: "k-dirty" }));
@@ -17955,14 +18063,14 @@
17955
18063
  }
17956
18064
 
17957
18065
  toDomTree(x, y, className) {
17958
- this.trs = this.trs.filter(function(tr) {
18066
+ this.trs = this.trs.filter(function (tr) {
17959
18067
  return tr.visible;
17960
18068
  });
17961
18069
 
17962
18070
  let offset = 0;
17963
- this.cols = this.cols.filter(function(col, ci) {
18071
+ this.cols = this.cols.filter(function (col, ci) {
17964
18072
  if (!col.visible) {
17965
- this.trs.forEach(function(tr) {
18073
+ this.trs.forEach(function (tr) {
17966
18074
  tr.children.splice(ci - offset, 1);
17967
18075
  });
17968
18076
  offset++;
@@ -17975,7 +18083,7 @@
17975
18083
  style: { left: x + "px", top: y + "px", height: this._height + "px", width: this._width + "px" },
17976
18084
  className: className,
17977
18085
  role: "presentation"
17978
- },[
18086
+ }, [
17979
18087
  dom.element("colgroup", null, this.cols),
17980
18088
  dom.element("tbody", null, this.trs)
17981
18089
  ]);
@@ -18030,6 +18138,8 @@
18030
18138
  this.editor = new SheetEditor(this);
18031
18139
 
18032
18140
  this._sheetsbar();
18141
+
18142
+ this.options.createContextMenus?.();
18033
18143
  }
18034
18144
 
18035
18145
  enableClipboard(enable) {
@@ -18073,7 +18183,7 @@
18073
18183
  this.formulaBar = new FormulaBar(formulaBar, { input: this.options.formulaBarInputRef });
18074
18184
 
18075
18185
  // if (this.options.toolbar) {
18076
- // this._tabstrip();
18186
+ this._tabstrip();
18077
18187
  // }
18078
18188
  }
18079
18189
 
@@ -18089,10 +18199,12 @@
18089
18199
  _sheetsbar() {
18090
18200
  if (this.options.sheetsbar) {
18091
18201
  this.sheetsbar = new SheetsBar(this.element.querySelector(DOT + View.classNames.sheetsBar), this.options.sheetsbar);
18202
+ this.options.createSheetBar?.(this.options.openDialogCallback);
18092
18203
  }
18093
18204
  }
18094
18205
 
18095
18206
  _tabstrip() {
18207
+ this.tabstrip = this.options.createTabStrip?.();
18096
18208
  // let messages = this.options.messages.tabs;
18097
18209
  // let options = $.extend(true, { home: true, insert: true, data: true }, this.options.toolbar);
18098
18210
  // let tabs = [];
@@ -18151,7 +18263,7 @@
18151
18263
  x += this.scroller.scrollLeft;
18152
18264
  }
18153
18265
 
18154
- col = this._sheet._grid._columns.locate(0, col, function(w) {
18266
+ col = this._sheet._grid._columns.locate(0, col, function (w) {
18155
18267
  return Math.abs(x - w) <= RESIZE_HANDLE_WIDTH / 2;
18156
18268
  });
18157
18269
 
@@ -18167,7 +18279,7 @@
18167
18279
  y += this.scroller.scrollTop;
18168
18280
  }
18169
18281
 
18170
- row = this._sheet._grid._rows.locate(0, row, function(h) {
18282
+ row = this._sheet._grid._rows.locate(0, row, function (h) {
18171
18283
  return Math.abs(y - h) <= RESIZE_HANDLE_WIDTH / 2;
18172
18284
  });
18173
18285
 
@@ -18183,8 +18295,8 @@
18183
18295
  x -= self._sheet._grid._headerWidth - scrollLeft;
18184
18296
  y -= self._sheet._grid._headerHeight - scrollTop;
18185
18297
 
18186
- return withExit(function(exit) {
18187
- self._sheet.forEachFilterHeader(ref, function(ref) {
18298
+ return withExit(function (exit) {
18299
+ self._sheet.forEachFilterHeader(ref, function (ref) {
18188
18300
  let rect = self._rectangle(pane, ref);
18189
18301
  if (pane.filterIconRect(rect).intersects(x, y)) {
18190
18302
  exit(true);
@@ -18334,7 +18446,7 @@
18334
18446
  }
18335
18447
 
18336
18448
  containingPane(cell) {
18337
- return this.panes.filter(function(pane) {
18449
+ return this.panes.filter(function (pane) {
18338
18450
  if (pane._grid.contains(cell)) {
18339
18451
  return true;
18340
18452
  }
@@ -18359,7 +18471,7 @@
18359
18471
  // this.tabstrip.refreshTools(sheet.range(sheet.activeCell()));
18360
18472
  // }
18361
18473
 
18362
- this.trigger('update', { reason, range: sheet.range(sheet.activeCell()) });
18474
+ this.trigger('update', { reason, range: sheet.range(sheet.activeCell()), sheet });
18363
18475
 
18364
18476
  // if (reason.sheetSelection && this.sheetsbar) {
18365
18477
  // this.sheetsbar.renderSheets(this._workbook.sheets(), this._workbook.sheetIndex(this._sheet));
@@ -18376,7 +18488,7 @@
18376
18488
  let frozenRows = sheet.frozenRows();
18377
18489
 
18378
18490
  // main or bottom or right pane
18379
- this.panes = [ this._pane(frozenRows, frozenColumns) ];
18491
+ this.panes = [this._pane(frozenRows, frozenColumns)];
18380
18492
 
18381
18493
  // left pane
18382
18494
  if (frozenColumns > 0) {
@@ -18403,19 +18515,18 @@
18403
18515
  }
18404
18516
  }
18405
18517
 
18406
- createFilterMenu() { // createFilterMenu(column) {
18407
- // this._destroyFilterMenu();
18518
+ createFilterMenu(column) {
18519
+ this._destroyFilterMenu();
18408
18520
 
18409
- // let sheet = this._sheet;
18410
- // let ref = sheet.filter().ref;
18411
- // let range = new Range(ref, sheet);
18412
- // let element = $("<div />").appendTo(this.element);
18413
- // let options = { column: column, range: range };
18414
- // let filterMenu = new kendo.spreadsheet.FilterMenu(element, options);
18521
+ let sheet = this._sheet;
18522
+ let ref = sheet.filter().ref;
18523
+ let range = new Range$1(ref, sheet);
18415
18524
 
18416
- // this._filterMenu = filterMenu;
18525
+ let options = { column: column, range: range };
18417
18526
 
18418
- // return filterMenu;
18527
+ this._filterMenu = this.options.createFilterMenu(options);
18528
+
18529
+ return this._filterMenu;
18419
18530
  }
18420
18531
 
18421
18532
  selectClipboardContents() {
@@ -18468,11 +18579,11 @@
18468
18579
  let editor = self._sheet.activeCellCustomEditor();
18469
18580
  let range = self._sheet.range(cell);
18470
18581
  editor.edit({
18471
- range : range,
18472
- rect : self.activeCellRectangle(),
18473
- view : this,
18474
- validation : this._sheet.validation(cell),
18475
- callback : function(value, parse) {
18582
+ range: range,
18583
+ rect: self.activeCellRectangle(),
18584
+ view: this,
18585
+ validation: this._sheet.validation(cell),
18586
+ callback: function (value, parse) {
18476
18587
  self._executeCommand({
18477
18588
  command: "EditCommand",
18478
18589
  options: {
@@ -18488,10 +18599,12 @@
18488
18599
 
18489
18600
  openDialog(name, options) {
18490
18601
  let sheet = this._sheet;
18491
- return sheet.withCultureDecimals(function() {
18602
+ return sheet.withCultureDecimals(function () {
18492
18603
  let ref = sheet.activeCell();
18493
18604
  let range = new Range$1(ref, sheet);
18494
- this.trigger('message', { ...options, name, ref, range });
18605
+ let args = { ...options, name, ref, range };
18606
+ this.trigger('message', args);
18607
+ return args.dialog;
18495
18608
  }.bind(this));
18496
18609
  }
18497
18610
 
@@ -18503,7 +18616,7 @@
18503
18616
  return;
18504
18617
  }
18505
18618
 
18506
- let onClose = function() {
18619
+ let onClose = function () {
18507
18620
  currentDialogs.pop();
18508
18621
  // let dlg = e.sender;
18509
18622
  this.selectClipboardContents();
@@ -18549,19 +18662,18 @@
18549
18662
  // this.colHeaderContextMenu =
18550
18663
  // this.drawingContextMenu = null;
18551
18664
 
18552
- // if (this.tabstrip) {
18553
- // this.tabstrip.destroy();
18554
- // this.tabstrip = null;
18555
- // }
18665
+ if (this.tabstrip) {
18666
+ this.tabstrip.destroy();
18667
+ this.tabstrip = null;
18668
+ }
18556
18669
 
18557
- // this._destroyFilterMenu();
18670
+ this._destroyFilterMenu();
18558
18671
  }
18559
18672
 
18560
18673
  _destroyFilterMenu() {
18561
18674
  if (this._filterMenu) {
18562
18675
  this._filterMenu.destroy();
18563
18676
  this._filterMenu = undefined;
18564
- this._filterMenuColumn = undefined;
18565
18677
  }
18566
18678
  }
18567
18679
 
@@ -18581,8 +18693,8 @@
18581
18693
 
18582
18694
  let resizeDirection =
18583
18695
  !sheet.resizingInProgress() ? "none" :
18584
- sheet.resizeHandlePosition().col === -Infinity ? "column" :
18585
- "row";
18696
+ sheet.resizeHandlePosition().col === -Infinity ? "column" :
18697
+ "row";
18586
18698
 
18587
18699
  this.wrapper.classList.toggle(viewClassNames.editContainer, this.editor.isActive());
18588
18700
  this.wrapper.classList.toggle(viewClassNames.horizontalResize, resizeDirection === "row");
@@ -18596,7 +18708,7 @@
18596
18708
  contentWidth: contentWidth,
18597
18709
  contentHeight: contentHeight
18598
18710
  };
18599
- this.panes.forEach(function(pane) {
18711
+ this.panes.forEach(function (pane) {
18600
18712
  content.push(pane.render(args));
18601
18713
  });
18602
18714
 
@@ -18623,11 +18735,11 @@
18623
18735
  if (this.editor.isActive()) {
18624
18736
  this.editor.toggleTooltip(this.activeCellRectangle());
18625
18737
  } else if (!(reason.resize ||
18626
- reason.comment ||
18627
- sheet.selectionInProgress() ||
18628
- sheet.resizingInProgress() ||
18629
- sheet.draggingInProgress() ||
18630
- sheet.isInEditMode())) {
18738
+ reason.comment ||
18739
+ sheet.selectionInProgress() ||
18740
+ sheet.resizingInProgress() ||
18741
+ sheet.draggingInProgress() ||
18742
+ sheet.isInEditMode())) {
18631
18743
  this.renderClipboardContents();
18632
18744
  }
18633
18745
  }
@@ -18661,7 +18773,7 @@
18661
18773
  return dom.element("div", {
18662
18774
  className: classNames.resizeHint + (!horizontal ? " " + classNames.resizeHintVertical : ""),
18663
18775
  style: style
18664
- },[
18776
+ }, [
18665
18777
  dom.element("div", { className: classNames.resizeHintHandle }),
18666
18778
  dom.element("div", { className: classNames.resizeHintMarker })
18667
18779
  ]);
@@ -18699,11 +18811,11 @@
18699
18811
 
18700
18812
  let selectionView = grid.rangeDimensions(selection);
18701
18813
 
18702
- selectionView.rows.forEach(function(height) {
18814
+ selectionView.rows.forEach(function (height) {
18703
18815
  table.addRow(height);
18704
18816
  });
18705
18817
 
18706
- selectionView.columns.forEach(function(width) {
18818
+ selectionView.columns.forEach(function (width) {
18707
18819
  table.addColumn(width);
18708
18820
  });
18709
18821
 
@@ -18711,7 +18823,7 @@
18711
18823
  let primaryMergedCells = tmp.primary;
18712
18824
  let secondaryMergedCells = tmp.secondary;
18713
18825
 
18714
- sheet.forEach(selection, function(row, col, cell) {
18826
+ sheet.forEach(selection, function (row, col, cell) {
18715
18827
  let location = new CellRef(row, col).print();
18716
18828
 
18717
18829
  if (!secondaryMergedCells[location]) {
@@ -18726,13 +18838,13 @@
18726
18838
  }
18727
18839
  });
18728
18840
 
18729
- this.clipboardContents.render([ table.toDomTree(0, 0, "kendo-clipboard-" + this._workbook.clipboard()._uid) ]);
18841
+ this.clipboardContents.render([table.toDomTree(0, 0, "kendo-clipboard-" + this._workbook.clipboard()._uid)]);
18730
18842
 
18731
18843
  this.selectClipboardContents();
18732
18844
  }
18733
18845
 
18734
18846
  _pane(row, column, rowCount, columnCount) {
18735
- let pane = new Pane(this._sheet, this._sheet._grid.pane({ row: row, column: column, rowCount: rowCount, columnCount: columnCount }));
18847
+ let pane = new Pane(this._sheet, this._sheet._grid.pane({ row: row, column: column, rowCount: rowCount, columnCount: columnCount }), this.options.getIconHTMLString);
18736
18848
  pane.refresh(this.scroller.clientWidth, this.scroller.clientHeight);
18737
18849
  return pane;
18738
18850
  }
@@ -19130,6 +19242,10 @@
19130
19242
  }
19131
19243
 
19132
19244
  /* eslint-disable no-else-return */
19245
+ /* eslint-disable consistent-return */
19246
+ /* eslint-disable space-before-blocks */
19247
+ /* eslint-disable no-implicit-coercion */
19248
+
19133
19249
 
19134
19250
  let COMMAND_TYPES = {
19135
19251
  AUTO_FILL: "autoFill",
@@ -20945,6 +21061,13 @@
20945
21061
  }
20946
21062
 
20947
21063
  /* eslint-disable complexity */
21064
+ /* eslint-disable camelcase */
21065
+ /* eslint-disable key-spacing */
21066
+ /* eslint-disable no-nested-ternary */
21067
+ /* eslint-disable brace-style */
21068
+ /* eslint-disable no-implicit-coercion */
21069
+ /* eslint-disable no-loop-func */
21070
+ /* eslint-disable no-param-reassign */
20948
21071
 
20949
21072
  // WARNING: removing the following jshint declaration and turning
20950
21073
  // == into === to make JSHint happy will break functionality.
@@ -22314,6 +22437,11 @@
22314
22437
  }
22315
22438
 
22316
22439
  /* eslint-disable no-undef */
22440
+ /* eslint-disable no-nested-ternary */
22441
+ /* eslint-disable key-spacing */
22442
+ /* eslint-disable consistent-return */
22443
+ /* eslint-disable no-param-reassign */
22444
+
22317
22445
 
22318
22446
  const events$1 = [
22319
22447
  "cut",
@@ -22532,7 +22660,13 @@
22532
22660
 
22533
22661
  execute(options) {
22534
22662
  let commandOptions = Object.assign({}, { workbook: this }, options.options);
22535
- let command = new commands[options.command](commandOptions);
22663
+ let command;
22664
+
22665
+ if (this.options.getWorkbookCommand) {
22666
+ command = this.options.getWorkbookCommand(options.command, commandOptions);
22667
+ }
22668
+
22669
+ command = command || new commands[options.command](commandOptions);
22536
22670
  let sheet = this.activeSheet();
22537
22671
 
22538
22672
  if (commandOptions.origin) {
@@ -22651,7 +22785,8 @@
22651
22785
  options.columnWidth || this.options.columnWidth,
22652
22786
  options.headerHeight || this.options.headerHeight,
22653
22787
  options.headerWidth || this.options.headerWidth,
22654
- options.defaultCellStyle || this.options.defaultCellStyle
22788
+ options.defaultCellStyle || this.options.defaultCellStyle,
22789
+ options.createSheetDataSource || this.options.createSheetDataSource
22655
22790
  );
22656
22791
 
22657
22792
  sheet._workbook = this;
@@ -22975,12 +23110,16 @@
22975
23110
 
22976
23111
  if (file && !this.trigger("excelImport", { file, deferred })) {
22977
23112
  this._clearSheets();
22978
- readExcel(file, this, deferred);
23113
+ this._readExcel(file, this, deferred);
22979
23114
  }
22980
23115
 
22981
23116
  return deferred.promise;
22982
23117
  }
22983
23118
 
23119
+ _readExcel(file, workbook, deferred) {
23120
+ readExcel(file, workbook, deferred);
23121
+ }
23122
+
22984
23123
  saveAsExcel(options) {
22985
23124
  let self = this;
22986
23125
  options = deepExtend({}, self.options.excel, options);
@@ -23326,7 +23465,10 @@
23326
23465
  "select",
23327
23466
  "changeFormat",
23328
23467
  "dataBinding",
23329
- "dataBound"
23468
+ "dataBound",
23469
+ "update",
23470
+ "message",
23471
+ "contextmenu",
23330
23472
  ];
23331
23473
 
23332
23474
  class SpreadsheetWidget extends Widget {
@@ -23344,7 +23486,13 @@
23344
23486
  sheetsbar: this.options.sheetsbar,
23345
23487
  formulaBarInputRef: this.options.formulaBarInputRef,
23346
23488
  formulaCellInputRef: this.options.formulaCellInputRef,
23347
- nameBoxRef: this.options.nameBoxRef
23489
+ nameBoxRef: this.options.nameBoxRef,
23490
+ createTabStrip: this.options.createTabStrip,
23491
+ createFilterMenu: this.options.createFilterMenu,
23492
+ createContextMenus: this.options.createContextMenus,
23493
+ createSheetBar: this.options.createSheetBar,
23494
+ getIconHTMLString: this.options.getIconHTMLString,
23495
+ openDialogCallback: this.openDialog.bind(this),
23348
23496
  });
23349
23497
 
23350
23498
  this._workbook = new Workbook(this.options, this._view);
@@ -23354,6 +23502,7 @@
23354
23502
  this._autoRefresh = true;
23355
23503
 
23356
23504
  this._bindWorkbookEvents();
23505
+ this._bindViewEvents();
23357
23506
 
23358
23507
  this._view.workbook(this._workbook);
23359
23508
 
@@ -23383,35 +23532,29 @@
23383
23532
  this.trigger("keydown", e);
23384
23533
 
23385
23534
  if (key === keys.F11 && e.shiftKey) {
23386
- this._view.sheetsbar._onAddSelect();
23535
+ this._view.sheetsbar.onAddSelect();
23387
23536
  e.preventDefault();
23388
23537
  return;
23389
23538
  } else if (e.altKey && key === keys.PAGEDOWN) {
23390
- this._view.sheetsbar.trigger("select", {
23391
- name: this._view.sheetsbar._sheets[this._view.sheetsbar._selectedIndex + 1].name(),
23392
- isAddButton: false
23393
- });
23394
- } else if (e.altKey && key === keys.PAGEUP) {
23395
- this._view.sheetsbar.trigger("select", {
23396
- name: this._view.sheetsbar._sheets[this._view.sheetsbar._selectedIndex - 1].name(),
23397
- isAddButton: false
23398
- });
23399
- } else if (e.altKey && key === keys.DELETE) {
23400
- let closeCallback = function(e) {
23401
- let dlg = e.sender;
23539
+ let activeSheetIndex = this.sheetIndex(this.activeSheet());
23540
+ let nextSheetName = this.sheetByIndex(activeSheetIndex + 1)?.name();
23402
23541
 
23403
- if (dlg.isConfirmed()) {
23404
- this._view.sheetsbar.trigger("remove", { name: this.activeSheet()._name(), confirmation: true });
23405
- }
23406
- }.bind(this);
23542
+ if (nextSheetName){
23543
+ this._view.sheetsbar.onSheetSelect(nextSheetName);
23544
+ }
23545
+ } else if (e.altKey && key === keys.PAGEUP) {
23546
+ let activeSheetIndex = this.sheetIndex(this.activeSheet());
23547
+ let prevSheetName = this.sheetByIndex(activeSheetIndex - 1)?.name();
23407
23548
 
23408
- this._view.sheetsbar._openDialog("confirmation", {
23409
- close: closeCallback
23410
- });
23549
+ if (prevSheetName) {
23550
+ this._view.sheetsbar.onSheetSelect(prevSheetName);
23551
+ }
23552
+ } else if (e.altKey && key === keys.DELETE) {
23553
+ this._view.sheetsbar.onSheetRemove(this.activeSheet()._name());
23411
23554
  e.preventDefault();
23412
23555
  return;
23413
23556
  } else if (e.altKey && key === keys.R) {
23414
- this._view.sheetsbar._createEditor();
23557
+ this.options.createSheetEditor?.();
23415
23558
  e.preventDefault();
23416
23559
  return;
23417
23560
  } else if (controlKey && key === keys.B) {
@@ -23421,17 +23564,20 @@
23421
23564
  } else if (controlKey && key === keys.U) {
23422
23565
  this._handleTypographicalEmphasis('underline');
23423
23566
  } else if (e.altKey && key === keys.H) {
23424
- this._view.tabstrip.select(0);
23567
+ this._view.tabstrip?.select(0);
23425
23568
  e.preventDefault();
23426
23569
  return;
23427
23570
  } else if (e.altKey && key === keys.N) {
23428
- this._view.tabstrip.select(1);
23571
+ this._view.tabstrip?.select(1);
23429
23572
  e.preventDefault();
23430
23573
  return;
23431
23574
  } else if (e.altKey && key === keys.A) {
23432
- this._view.tabstrip.select(2);
23575
+ this._view.tabstrip?.select(2);
23433
23576
  e.preventDefault();
23434
23577
  return;
23578
+ } else if (key === keys.F10) {
23579
+ e.preventDefault();
23580
+ this._view.tabstrip?.wrapper?.find(".k-tabstrip-content.k-active .k-toolbar [tabindex=0]").trigger("focus");
23435
23581
  }
23436
23582
  }
23437
23583
 
@@ -23742,6 +23888,14 @@
23742
23888
  // kendo.ui.progress(this.element, e.toggle);
23743
23889
  }
23744
23890
 
23891
+ _viewUpdate(e) {
23892
+ this.trigger("update", e);
23893
+ }
23894
+
23895
+ _viewMessage(e) {
23896
+ this.trigger("message", e);
23897
+ }
23898
+
23745
23899
  _onContextMenu(e) {
23746
23900
  this.trigger("contextmenu", e);
23747
23901
  }
@@ -23775,6 +23929,11 @@
23775
23929
  this._workbook.bind("contextmenu", this._onContextMenu.bind(this));
23776
23930
  }
23777
23931
 
23932
+ _bindViewEvents() {
23933
+ this._view.bind("update", this._viewUpdate.bind(this));
23934
+ this._view.bind("message", this._viewMessage.bind(this));
23935
+ }
23936
+
23778
23937
  destroy() {
23779
23938
  window.removeEventListener('resize', this._resizeHandler);
23780
23939
  this.element.removeEventListener("keydown", this._keyDownHandler);
@@ -23825,6 +23984,7 @@
23825
23984
 
23826
23985
  /* -----[ Excel operators ]----- */
23827
23986
 
23987
+
23828
23988
  const {
23829
23989
  FUNCS,
23830
23990
  defineBuiltinFunction,
@@ -43972,29 +44132,119 @@
43972
44132
  defineAlias
43973
44133
  } = calc.runtime;
43974
44134
 
44135
+ exports.ALL_PROPERTIES = ALL_PROPERTIES;
44136
+ exports.ALL_REASONS = ALL_REASONS;
44137
+ exports.AddColumnCommand = AddColumnCommand;
44138
+ exports.AddCommand = AddCommand;
44139
+ exports.AddRowCommand = AddRowCommand;
44140
+ exports.AdjustDecimalsCommand = AdjustDecimalsCommand;
44141
+ exports.AdjustRowHeightCommand = AdjustRowHeightCommand;
44142
+ exports.ApplyFilterCommand = ApplyFilterCommand;
44143
+ exports.AutoFillCalculator = AutoFillCalculator;
44144
+ exports.AutoFillCommand = AutoFillCommand;
44145
+ exports.Axis = Axis;
44146
+ exports.AxisManager = AxisManager;
44147
+ exports.BorderChangeCommand = BorderChangeCommand;
44148
+ exports.BringToFrontCommand = BringToFrontCommand;
43975
44149
  exports.CalcError = CalcError;
43976
44150
  exports.CellRef = CellRef;
44151
+ exports.ClearContentCommand = ClearContentCommand;
44152
+ exports.ClearFilterCommand = ClearFilterCommand;
44153
+ exports.Clipboard = Clipboard;
44154
+ exports.ColumnWidthCommand = ColumnWidthCommand;
44155
+ exports.Command = Command;
43977
44156
  exports.Context = Context;
44157
+ exports.Controller = Controller;
44158
+ exports.CopyCommand = CopyCommand;
44159
+ exports.CustomFilter = CustomFilter;
44160
+ exports.CutCommand = CutCommand;
43978
44161
  exports.Deferred = Deferred;
44162
+ exports.DefineNameCommand = DefineNameCommand;
44163
+ exports.DeleteColumnCommand = DeleteColumnCommand;
44164
+ exports.DeleteCommand = DeleteCommand;
44165
+ exports.DeleteDrawingCommand = DeleteDrawingCommand;
44166
+ exports.DeleteNameCommand = DeleteNameCommand;
44167
+ exports.DeleteRowCommand = DeleteRowCommand;
44168
+ exports.Drawing = Drawing;
44169
+ exports.DrawingCommand = DrawingCommand;
44170
+ exports.DrawingUpdateCommand = DrawingUpdateCommand;
44171
+ exports.DynamicFilter = DynamicFilter;
44172
+ exports.EditCommand = EditCommand;
44173
+ exports.EditValidationCommand = EditValidationCommand;
44174
+ exports.EventListener = EventListener;
44175
+ exports.FIRSTREF = FIRSTREF;
44176
+ exports.Filter = Filter;
44177
+ exports.FilterCommand = FilterCommand;
44178
+ exports.FormulaBar = FormulaBar;
44179
+ exports.FormulaContext = FormulaContext;
44180
+ exports.FormulaInput = FormulaInput;
44181
+ exports.FreezePanesCommand = FreezePanesCommand;
44182
+ exports.Grid = Grid;
44183
+ exports.GridLinesChangeCommand = GridLinesChangeCommand;
44184
+ exports.HideLineCommand = HideLineCommand;
44185
+ exports.HyperlinkCommand = HyperlinkCommand;
44186
+ exports.InsertCommentCommand = InsertCommentCommand;
44187
+ exports.InsertImageCommand = InsertImageCommand;
43979
44188
  exports.Matrix = Matrix;
44189
+ exports.MergeCellCommand = MergeCellCommand;
43980
44190
  exports.NULLREF = NULLREF;
44191
+ exports.NameCommand = NameCommand;
44192
+ exports.NameEditor = NameEditor;
43981
44193
  exports.NameRef = NameRef;
44194
+ exports.OpenCommand = OpenCommand;
44195
+ exports.Pane = Pane;
44196
+ exports.PaneAxis = PaneAxis;
44197
+ exports.PaneGrid = PaneGrid;
44198
+ exports.PasteCommand = PasteCommand;
44199
+ exports.PropertyBag = PropertyBag;
44200
+ exports.PropertyChangeCommand = PropertyChangeCommand;
44201
+ exports.PropertyCleanCommand = PropertyCleanCommand;
43982
44202
  exports.Range = Range$1;
44203
+ exports.RangeList = RangeList;
43983
44204
  exports.RangeRef = RangeRef;
44205
+ exports.RangeTree = RangeTree;
43984
44206
  exports.Ref = Ref;
44207
+ exports.ReorderDrawingsCommand = ReorderDrawingsCommand;
44208
+ exports.RowHeightCommand = RowHeightCommand;
44209
+ exports.SHEETREF = SHEETREF;
44210
+ exports.SaveAsCommand = SaveAsCommand;
44211
+ exports.SendToBackCommand = SendToBackCommand;
43985
44212
  exports.Sheet = Sheet;
44213
+ exports.SheetDataSourceBinder = SheetDataSourceBinder;
44214
+ exports.SheetEditor = SheetEditor;
44215
+ exports.SheetNavigator = SheetNavigator;
44216
+ exports.SortCommand = SortCommand;
44217
+ exports.Sorter = Sorter;
43986
44218
  exports.SpreadsheetWidget = SpreadsheetWidget;
44219
+ exports.TargetValueCommand = TargetValueCommand;
44220
+ exports.TextWrapCommand = TextWrapCommand;
44221
+ exports.ToolbarCopyCommand = ToolbarCopyCommand;
44222
+ exports.ToolbarCutCommand = ToolbarCutCommand;
44223
+ exports.ToolbarPasteCommand = ToolbarPasteCommand;
44224
+ exports.TopFilter = TopFilter;
44225
+ exports.UnHideLineCommand = UnHideLineCommand;
43987
44226
  exports.UnionRef = UnionRef;
44227
+ exports.ValidationFormulaContext = ValidationFormulaContext;
44228
+ exports.ValueFilter = ValueFilter;
43988
44229
  exports.View = View;
43989
44230
  exports.Workbook = Workbook;
43990
44231
  exports.calc = calc;
44232
+ exports.dateToNumber = dateToNumber;
43991
44233
  exports.dateToSerial = dateToSerial;
43992
44234
  exports.defineAlias = defineAlias;
43993
44235
  exports.defineFunction = defineFunction;
44236
+ exports.draw = draw;
44237
+ exports.drawCell = drawCell;
44238
+ exports.formatting = formatting;
44239
+ exports.initDynamicFilter = initDynamicFilter;
44240
+ exports.intl = intl;
44241
+ exports.numberToDate = numberToDate;
43994
44242
  exports.packDate = packDate;
43995
44243
  exports.packTime = packTime;
44244
+ exports.registerEditor = registerEditor;
43996
44245
  exports.serialToDate = serialToDate;
43997
44246
  exports.unpackDate = unpackDate;
43998
44247
  exports.unpackTime = unpackTime;
44248
+ exports.validation = validationExport;
43999
44249
 
44000
44250
  }));