@syncfusion/ej2-base 31.1.22 → 31.2.4
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.
- package/bin/syncfusion-license.js +1 -1
- package/dist/ej2-base.min.js +2 -2
- package/dist/ej2-base.umd.min.js +2 -2
- package/dist/ej2-base.umd.min.js.map +1 -1
- package/dist/es6/ej2-base.es2015.js +24 -5
- package/dist/es6/ej2-base.es2015.js.map +1 -1
- package/dist/es6/ej2-base.es5.js +23 -4
- package/dist/es6/ej2-base.es5.js.map +1 -1
- package/dist/global/ej2-base.min.js +2 -2
- package/dist/global/ej2-base.min.js.map +1 -1
- package/dist/global/index.d.ts +1 -1
- package/package.json +2 -2
- package/src/intl/date-parser.d.ts +7 -0
- package/src/intl/date-parser.js +16 -1
- package/src/intl/number-formatter.js +3 -0
- package/src/sanitize-helper.js +1 -0
- package/src/validate-lic.js +3 -3
package/dist/es6/ej2-base.es5.js
CHANGED
|
@@ -6046,6 +6046,9 @@ var NumberFormat$1 = /** @__PURE__ @class */ (function () {
|
|
|
6046
6046
|
return (Math.round(value * factor) / factor).toFixed(digits);
|
|
6047
6047
|
};
|
|
6048
6048
|
NumberFormat.processFraction = function (value, min, max, option) {
|
|
6049
|
+
if (value != null && (value.toString().indexOf('e') !== -1 || value.toString().indexOf('E') !== -1)) {
|
|
6050
|
+
return value.toFixed(min);
|
|
6051
|
+
}
|
|
6049
6052
|
var temp = (value + '').split('.')[1];
|
|
6050
6053
|
var length = temp ? temp.length : 0;
|
|
6051
6054
|
if (min && length < min) {
|
|
@@ -6450,6 +6453,19 @@ var DateParser = /** @__PURE__ @class */ (function () {
|
|
|
6450
6453
|
}
|
|
6451
6454
|
return null;
|
|
6452
6455
|
};
|
|
6456
|
+
/**
|
|
6457
|
+
* Escapes all regex metacharacters in a string, preserving the {0} placeholder.
|
|
6458
|
+
*
|
|
6459
|
+
* @param {string} str ? - The input string to escape.
|
|
6460
|
+
* @returns {string} ? - The escaped string with {0} preserved.
|
|
6461
|
+
*/
|
|
6462
|
+
DateParser.escapeRegex = function (str) {
|
|
6463
|
+
var tempPlaceholder = '__TEMP__';
|
|
6464
|
+
var tempStr = str.replace('{0}', tempPlaceholder);
|
|
6465
|
+
var metaChars = /[.*+?^${}()|[\]\\]/g;
|
|
6466
|
+
var escapedStr = tempStr.replace(metaChars, '\\$&');
|
|
6467
|
+
return escapedStr.replace(tempPlaceholder, '{0}');
|
|
6468
|
+
};
|
|
6453
6469
|
/**
|
|
6454
6470
|
* Returns parsed time zone RegExp for provided hour format and time zone
|
|
6455
6471
|
*
|
|
@@ -6469,10 +6485,12 @@ var DateParser = /** @__PURE__ @class */ (function () {
|
|
|
6469
6485
|
else {
|
|
6470
6486
|
ret = ret.replace(/H|m/g, '(' + cRegex + '?)');
|
|
6471
6487
|
}
|
|
6488
|
+
pattern = this.escapeRegex(pattern);
|
|
6472
6489
|
var splitStr = (ret.split(';').map(function (str) {
|
|
6473
6490
|
return pattern.replace('{0}', str);
|
|
6474
6491
|
}));
|
|
6475
|
-
|
|
6492
|
+
var gmtZeroFormat = this.escapeRegex(tZone.gmtZeroFormat);
|
|
6493
|
+
ret = splitStr.join('|') + '|' + gmtZeroFormat;
|
|
6476
6494
|
return ret;
|
|
6477
6495
|
};
|
|
6478
6496
|
/**
|
|
@@ -6913,6 +6931,7 @@ var bypassKey = [115, 121, 110, 99, 102, 117, 115, 105,
|
|
|
6913
6931
|
111, 110, 46, 105, 115, 76, 105, 99, 86, 97, 108,
|
|
6914
6932
|
105, 100, 97, 116, 101, 100];
|
|
6915
6933
|
var accountURL;
|
|
6934
|
+
var banner = true;
|
|
6916
6935
|
/**
|
|
6917
6936
|
* License validation module
|
|
6918
6937
|
*
|
|
@@ -7091,15 +7110,14 @@ var LicenseValidator = /** @__PURE__ @class */ (function () {
|
|
|
7091
7110
|
}
|
|
7092
7111
|
}
|
|
7093
7112
|
if (validateMsg && typeof document !== 'undefined' && !isNullOrUndefined(document)) {
|
|
7094
|
-
|
|
7095
|
-
if (!existingErrorDiv) {
|
|
7113
|
+
if (banner) {
|
|
7096
7114
|
accountURL = (validateURL && validateURL !== '') ? validateURL : 'https://www.syncfusion.com/account/claim-license-key?pl=SmF2YVNjcmlwdA==&vs=MzE=&utm_source=es_license_validation_banner&utm_medium=listing&utm_campaign=license-information';
|
|
7097
7115
|
var errorDiv = createElement('div', {
|
|
7098
|
-
className: 'syncfusion-license-error',
|
|
7099
7116
|
innerHTML: "<img src='data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjQiIGhlaWdodD0iMjQiIHZpZXdCb3g9IjAgMCAyNCAyNCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPGcgY2xpcC1wYXRoPSJ1cmwoI2NsaXAwXzE5OV80KSI+CjxwYXRoIGQ9Ik0xMiAyMUMxNi45NzA2IDIxIDIxIDE2Ljk3MDYgMjEgMTJDMjEgNy4wMjk0NCAxNi45NzA2IDMgMTIgM0M3LjAyOTQ0IDMgMyA3LjAyOTQ0IDMgMTJDMyAxNi45NzA2IDcuMDI5NDQgMjEgMTIgMjFaIiBzdHJva2U9IiM3MzczNzMiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+CjxwYXRoIGQ9Ik0xMS4yNSAxMS4yNUgxMlYxNi41SDEyLjc1IiBmaWxsPSIjNjE2MDYzIi8+CjxwYXRoIGQ9Ik0xMS4yNSAxMS4yNUgxMlYxNi41SDEyLjc1IiBzdHJva2U9IiM3MzczNzMiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+CjxwYXRoIGQ9Ik0xMS44MTI1IDlDMTIuNDMzOCA5IDEyLjkzNzUgOC40OTYzMiAxMi45Mzc1IDcuODc1QzEyLjkzNzUgNy4yNTM2OCAxMi40MzM4IDYuNzUgMTEuODEyNSA2Ljc1QzExLjE5MTIgNi43NSAxMC42ODc1IDcuMjUzNjggMTAuNjg3NSA3Ljg3NUMxMC42ODc1IDguNDk2MzIgMTEuMTkxMiA5IDExLjgxMjUgOVoiIGZpbGw9IiM3MzczNzMiLz4KPC9nPgo8ZGVmcz4KPGNsaXBQYXRoIGlkPSJjbGlwMF8xOTlfNCI+CjxyZWN0IHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgZmlsbD0id2hpdGUiLz4KPC9jbGlwUGF0aD4KPC9kZWZzPgo8L3N2Zz4K' style=\"top: 6px;\n position: absolute;\n left: 16px;\n width: 24px;\n height: 24px;\"/>" + validateMsg + ' ' + '<a style="text-decoration: none;color: #0D6EFD;font-weight: 500;" href=' + accountURL + '>Claim your free account</a>'
|
|
7100
7117
|
});
|
|
7101
7118
|
errorDiv.setAttribute('style', "position: fixed;\n top: 10px;\n left: 10px;\n right: 10px;\n font-size: 14px;\n background: #EEF2FF;\n color: #222222;\n z-index: 999999999;\n text-align: left;\n border: 1px solid #EEEEEE;\n padding: 10px 11px 10px 50px;\n border-radius: 8px;\n font-family: Helvetica Neue, Helvetica, Arial;");
|
|
7102
7119
|
document.body.appendChild(errorDiv);
|
|
7120
|
+
banner = false;
|
|
7103
7121
|
}
|
|
7104
7122
|
this.isLicensed = false;
|
|
7105
7123
|
}
|
|
@@ -9969,6 +9987,7 @@ var jsEvents = ['onchange',
|
|
|
9969
9987
|
'onbeforeprint',
|
|
9970
9988
|
'oncanplay',
|
|
9971
9989
|
'oncanplaythrough',
|
|
9990
|
+
'oncontentvisibilityautostatechange',
|
|
9972
9991
|
'oncontextmenu',
|
|
9973
9992
|
'ondblclick',
|
|
9974
9993
|
'ondrag',
|