@kne/react-pdf-sign 1.1.5 → 1.1.6
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/dist/index.js +87 -42
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +87 -42
- package/dist/index.modern.js.map +1 -1
- package/package.json +1 -1
package/dist/index.modern.js
CHANGED
|
@@ -933,17 +933,17 @@ var Symbol = _root.Symbol;
|
|
|
933
933
|
var _Symbol = Symbol;
|
|
934
934
|
|
|
935
935
|
/** Used for built-in method references. */
|
|
936
|
-
var objectProto$
|
|
936
|
+
var objectProto$e = Object.prototype;
|
|
937
937
|
|
|
938
938
|
/** Used to check objects for own properties. */
|
|
939
|
-
var hasOwnProperty$
|
|
939
|
+
var hasOwnProperty$b = objectProto$e.hasOwnProperty;
|
|
940
940
|
|
|
941
941
|
/**
|
|
942
942
|
* Used to resolve the
|
|
943
943
|
* [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
|
|
944
944
|
* of values.
|
|
945
945
|
*/
|
|
946
|
-
var nativeObjectToString$1 = objectProto$
|
|
946
|
+
var nativeObjectToString$1 = objectProto$e.toString;
|
|
947
947
|
|
|
948
948
|
/** Built-in value references. */
|
|
949
949
|
var symToStringTag$1 = _Symbol ? _Symbol.toStringTag : undefined;
|
|
@@ -956,7 +956,7 @@ var symToStringTag$1 = _Symbol ? _Symbol.toStringTag : undefined;
|
|
|
956
956
|
* @returns {string} Returns the raw `toStringTag`.
|
|
957
957
|
*/
|
|
958
958
|
function getRawTag(value) {
|
|
959
|
-
var isOwn = hasOwnProperty$
|
|
959
|
+
var isOwn = hasOwnProperty$b.call(value, symToStringTag$1),
|
|
960
960
|
tag = value[symToStringTag$1];
|
|
961
961
|
|
|
962
962
|
try {
|
|
@@ -978,14 +978,14 @@ function getRawTag(value) {
|
|
|
978
978
|
var _getRawTag = getRawTag;
|
|
979
979
|
|
|
980
980
|
/** Used for built-in method references. */
|
|
981
|
-
var objectProto$
|
|
981
|
+
var objectProto$d = Object.prototype;
|
|
982
982
|
|
|
983
983
|
/**
|
|
984
984
|
* Used to resolve the
|
|
985
985
|
* [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)
|
|
986
986
|
* of values.
|
|
987
987
|
*/
|
|
988
|
-
var nativeObjectToString = objectProto$
|
|
988
|
+
var nativeObjectToString = objectProto$d.toString;
|
|
989
989
|
|
|
990
990
|
/**
|
|
991
991
|
* Converts `value` to a string using `Object.prototype.toString`.
|
|
@@ -1154,17 +1154,17 @@ var reIsHostCtor = /^\[object .+?Constructor\]$/;
|
|
|
1154
1154
|
|
|
1155
1155
|
/** Used for built-in method references. */
|
|
1156
1156
|
var funcProto$1 = Function.prototype,
|
|
1157
|
-
objectProto$
|
|
1157
|
+
objectProto$c = Object.prototype;
|
|
1158
1158
|
|
|
1159
1159
|
/** Used to resolve the decompiled source of functions. */
|
|
1160
1160
|
var funcToString$1 = funcProto$1.toString;
|
|
1161
1161
|
|
|
1162
1162
|
/** Used to check objects for own properties. */
|
|
1163
|
-
var hasOwnProperty$
|
|
1163
|
+
var hasOwnProperty$a = objectProto$c.hasOwnProperty;
|
|
1164
1164
|
|
|
1165
1165
|
/** Used to detect if a method is native. */
|
|
1166
1166
|
var reIsNative = RegExp('^' +
|
|
1167
|
-
funcToString$1.call(hasOwnProperty$
|
|
1167
|
+
funcToString$1.call(hasOwnProperty$a).replace(reRegExpChar, '\\$&')
|
|
1168
1168
|
.replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?') + '$'
|
|
1169
1169
|
);
|
|
1170
1170
|
|
|
@@ -1261,10 +1261,10 @@ var _hashDelete = hashDelete;
|
|
|
1261
1261
|
var HASH_UNDEFINED$1 = '__lodash_hash_undefined__';
|
|
1262
1262
|
|
|
1263
1263
|
/** Used for built-in method references. */
|
|
1264
|
-
var objectProto$
|
|
1264
|
+
var objectProto$b = Object.prototype;
|
|
1265
1265
|
|
|
1266
1266
|
/** Used to check objects for own properties. */
|
|
1267
|
-
var hasOwnProperty$
|
|
1267
|
+
var hasOwnProperty$9 = objectProto$b.hasOwnProperty;
|
|
1268
1268
|
|
|
1269
1269
|
/**
|
|
1270
1270
|
* Gets the hash value for `key`.
|
|
@@ -1281,16 +1281,16 @@ function hashGet(key) {
|
|
|
1281
1281
|
var result = data[key];
|
|
1282
1282
|
return result === HASH_UNDEFINED$1 ? undefined : result;
|
|
1283
1283
|
}
|
|
1284
|
-
return hasOwnProperty$
|
|
1284
|
+
return hasOwnProperty$9.call(data, key) ? data[key] : undefined;
|
|
1285
1285
|
}
|
|
1286
1286
|
|
|
1287
1287
|
var _hashGet = hashGet;
|
|
1288
1288
|
|
|
1289
1289
|
/** Used for built-in method references. */
|
|
1290
|
-
var objectProto$
|
|
1290
|
+
var objectProto$a = Object.prototype;
|
|
1291
1291
|
|
|
1292
1292
|
/** Used to check objects for own properties. */
|
|
1293
|
-
var hasOwnProperty$
|
|
1293
|
+
var hasOwnProperty$8 = objectProto$a.hasOwnProperty;
|
|
1294
1294
|
|
|
1295
1295
|
/**
|
|
1296
1296
|
* Checks if a hash value for `key` exists.
|
|
@@ -1303,7 +1303,7 @@ var hasOwnProperty$7 = objectProto$9.hasOwnProperty;
|
|
|
1303
1303
|
*/
|
|
1304
1304
|
function hashHas(key) {
|
|
1305
1305
|
var data = this.__data__;
|
|
1306
|
-
return _nativeCreate ? (data[key] !== undefined) : hasOwnProperty$
|
|
1306
|
+
return _nativeCreate ? (data[key] !== undefined) : hasOwnProperty$8.call(data, key);
|
|
1307
1307
|
}
|
|
1308
1308
|
|
|
1309
1309
|
var _hashHas = hashHas;
|
|
@@ -1613,10 +1613,10 @@ function baseAssignValue(object, key, value) {
|
|
|
1613
1613
|
var _baseAssignValue = baseAssignValue;
|
|
1614
1614
|
|
|
1615
1615
|
/** Used for built-in method references. */
|
|
1616
|
-
var objectProto$
|
|
1616
|
+
var objectProto$9 = Object.prototype;
|
|
1617
1617
|
|
|
1618
1618
|
/** Used to check objects for own properties. */
|
|
1619
|
-
var hasOwnProperty$
|
|
1619
|
+
var hasOwnProperty$7 = objectProto$9.hasOwnProperty;
|
|
1620
1620
|
|
|
1621
1621
|
/**
|
|
1622
1622
|
* Assigns `value` to `key` of `object` if the existing value is not equivalent
|
|
@@ -1630,7 +1630,7 @@ var hasOwnProperty$6 = objectProto$8.hasOwnProperty;
|
|
|
1630
1630
|
*/
|
|
1631
1631
|
function assignValue(object, key, value) {
|
|
1632
1632
|
var objValue = object[key];
|
|
1633
|
-
if (!(hasOwnProperty$
|
|
1633
|
+
if (!(hasOwnProperty$7.call(object, key) && eq_1(objValue, value)) ||
|
|
1634
1634
|
(value === undefined && !(key in object))) {
|
|
1635
1635
|
_baseAssignValue(object, key, value);
|
|
1636
1636
|
}
|
|
@@ -1744,13 +1744,13 @@ function baseIsArguments(value) {
|
|
|
1744
1744
|
var _baseIsArguments = baseIsArguments;
|
|
1745
1745
|
|
|
1746
1746
|
/** Used for built-in method references. */
|
|
1747
|
-
var objectProto$
|
|
1747
|
+
var objectProto$8 = Object.prototype;
|
|
1748
1748
|
|
|
1749
1749
|
/** Used to check objects for own properties. */
|
|
1750
|
-
var hasOwnProperty$
|
|
1750
|
+
var hasOwnProperty$6 = objectProto$8.hasOwnProperty;
|
|
1751
1751
|
|
|
1752
1752
|
/** Built-in value references. */
|
|
1753
|
-
var propertyIsEnumerable$1 = objectProto$
|
|
1753
|
+
var propertyIsEnumerable$1 = objectProto$8.propertyIsEnumerable;
|
|
1754
1754
|
|
|
1755
1755
|
/**
|
|
1756
1756
|
* Checks if `value` is likely an `arguments` object.
|
|
@@ -1771,7 +1771,7 @@ var propertyIsEnumerable$1 = objectProto$7.propertyIsEnumerable;
|
|
|
1771
1771
|
* // => false
|
|
1772
1772
|
*/
|
|
1773
1773
|
var isArguments = _baseIsArguments(function() { return arguments; }()) ? _baseIsArguments : function(value) {
|
|
1774
|
-
return isObjectLike_1(value) && hasOwnProperty$
|
|
1774
|
+
return isObjectLike_1(value) && hasOwnProperty$6.call(value, 'callee') &&
|
|
1775
1775
|
!propertyIsEnumerable$1.call(value, 'callee');
|
|
1776
1776
|
};
|
|
1777
1777
|
|
|
@@ -2051,10 +2051,10 @@ var isTypedArray = nodeIsTypedArray ? _baseUnary(nodeIsTypedArray) : _baseIsType
|
|
|
2051
2051
|
var isTypedArray_1 = isTypedArray;
|
|
2052
2052
|
|
|
2053
2053
|
/** Used for built-in method references. */
|
|
2054
|
-
var objectProto$
|
|
2054
|
+
var objectProto$7 = Object.prototype;
|
|
2055
2055
|
|
|
2056
2056
|
/** Used to check objects for own properties. */
|
|
2057
|
-
var hasOwnProperty$
|
|
2057
|
+
var hasOwnProperty$5 = objectProto$7.hasOwnProperty;
|
|
2058
2058
|
|
|
2059
2059
|
/**
|
|
2060
2060
|
* Creates an array of the enumerable property names of the array-like `value`.
|
|
@@ -2074,7 +2074,7 @@ function arrayLikeKeys(value, inherited) {
|
|
|
2074
2074
|
length = result.length;
|
|
2075
2075
|
|
|
2076
2076
|
for (var key in value) {
|
|
2077
|
-
if ((inherited || hasOwnProperty$
|
|
2077
|
+
if ((inherited || hasOwnProperty$5.call(value, key)) &&
|
|
2078
2078
|
!(skipIndexes && (
|
|
2079
2079
|
// Safari 9 has enumerable `arguments.length` in strict mode.
|
|
2080
2080
|
key == 'length' ||
|
|
@@ -2094,7 +2094,7 @@ function arrayLikeKeys(value, inherited) {
|
|
|
2094
2094
|
var _arrayLikeKeys = arrayLikeKeys;
|
|
2095
2095
|
|
|
2096
2096
|
/** Used for built-in method references. */
|
|
2097
|
-
var objectProto$
|
|
2097
|
+
var objectProto$6 = Object.prototype;
|
|
2098
2098
|
|
|
2099
2099
|
/**
|
|
2100
2100
|
* Checks if `value` is likely a prototype object.
|
|
@@ -2105,7 +2105,7 @@ var objectProto$5 = Object.prototype;
|
|
|
2105
2105
|
*/
|
|
2106
2106
|
function isPrototype(value) {
|
|
2107
2107
|
var Ctor = value && value.constructor,
|
|
2108
|
-
proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto$
|
|
2108
|
+
proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto$6;
|
|
2109
2109
|
|
|
2110
2110
|
return value === proto;
|
|
2111
2111
|
}
|
|
@@ -2134,10 +2134,10 @@ var nativeKeys = _overArg(Object.keys, Object);
|
|
|
2134
2134
|
var _nativeKeys = nativeKeys;
|
|
2135
2135
|
|
|
2136
2136
|
/** Used for built-in method references. */
|
|
2137
|
-
var objectProto$
|
|
2137
|
+
var objectProto$5 = Object.prototype;
|
|
2138
2138
|
|
|
2139
2139
|
/** Used to check objects for own properties. */
|
|
2140
|
-
var hasOwnProperty$
|
|
2140
|
+
var hasOwnProperty$4 = objectProto$5.hasOwnProperty;
|
|
2141
2141
|
|
|
2142
2142
|
/**
|
|
2143
2143
|
* The base implementation of `_.keys` which doesn't treat sparse arrays as dense.
|
|
@@ -2152,7 +2152,7 @@ function baseKeys(object) {
|
|
|
2152
2152
|
}
|
|
2153
2153
|
var result = [];
|
|
2154
2154
|
for (var key in Object(object)) {
|
|
2155
|
-
if (hasOwnProperty$
|
|
2155
|
+
if (hasOwnProperty$4.call(object, key) && key != 'constructor') {
|
|
2156
2156
|
result.push(key);
|
|
2157
2157
|
}
|
|
2158
2158
|
}
|
|
@@ -2263,10 +2263,10 @@ function nativeKeysIn(object) {
|
|
|
2263
2263
|
var _nativeKeysIn = nativeKeysIn;
|
|
2264
2264
|
|
|
2265
2265
|
/** Used for built-in method references. */
|
|
2266
|
-
var objectProto$
|
|
2266
|
+
var objectProto$4 = Object.prototype;
|
|
2267
2267
|
|
|
2268
2268
|
/** Used to check objects for own properties. */
|
|
2269
|
-
var hasOwnProperty$
|
|
2269
|
+
var hasOwnProperty$3 = objectProto$4.hasOwnProperty;
|
|
2270
2270
|
|
|
2271
2271
|
/**
|
|
2272
2272
|
* The base implementation of `_.keysIn` which doesn't treat sparse arrays as dense.
|
|
@@ -2283,7 +2283,7 @@ function baseKeysIn(object) {
|
|
|
2283
2283
|
result = [];
|
|
2284
2284
|
|
|
2285
2285
|
for (var key in object) {
|
|
2286
|
-
if (!(key == 'constructor' && (isProto || !hasOwnProperty$
|
|
2286
|
+
if (!(key == 'constructor' && (isProto || !hasOwnProperty$3.call(object, key)))) {
|
|
2287
2287
|
result.push(key);
|
|
2288
2288
|
}
|
|
2289
2289
|
}
|
|
@@ -2444,10 +2444,10 @@ function stubArray() {
|
|
|
2444
2444
|
var stubArray_1 = stubArray;
|
|
2445
2445
|
|
|
2446
2446
|
/** Used for built-in method references. */
|
|
2447
|
-
var objectProto$
|
|
2447
|
+
var objectProto$3 = Object.prototype;
|
|
2448
2448
|
|
|
2449
2449
|
/** Built-in value references. */
|
|
2450
|
-
var propertyIsEnumerable = objectProto$
|
|
2450
|
+
var propertyIsEnumerable = objectProto$3.propertyIsEnumerable;
|
|
2451
2451
|
|
|
2452
2452
|
/* Built-in method references for those with the same name as other `lodash` methods. */
|
|
2453
2453
|
var nativeGetSymbols$1 = Object.getOwnPropertySymbols;
|
|
@@ -2663,10 +2663,10 @@ if ((_DataView && getTag(new _DataView(new ArrayBuffer(1))) != dataViewTag$2) ||
|
|
|
2663
2663
|
var _getTag = getTag;
|
|
2664
2664
|
|
|
2665
2665
|
/** Used for built-in method references. */
|
|
2666
|
-
var objectProto$
|
|
2666
|
+
var objectProto$2 = Object.prototype;
|
|
2667
2667
|
|
|
2668
2668
|
/** Used to check objects for own properties. */
|
|
2669
|
-
var hasOwnProperty$
|
|
2669
|
+
var hasOwnProperty$2 = objectProto$2.hasOwnProperty;
|
|
2670
2670
|
|
|
2671
2671
|
/**
|
|
2672
2672
|
* Initializes an array clone.
|
|
@@ -2680,7 +2680,7 @@ function initCloneArray(array) {
|
|
|
2680
2680
|
result = new array.constructor(length);
|
|
2681
2681
|
|
|
2682
2682
|
// Add properties assigned by `RegExp#exec`.
|
|
2683
|
-
if (length && typeof array[0] == 'string' && hasOwnProperty$
|
|
2683
|
+
if (length && typeof array[0] == 'string' && hasOwnProperty$2.call(array, 'index')) {
|
|
2684
2684
|
result.index = array.index;
|
|
2685
2685
|
result.input = array.input;
|
|
2686
2686
|
}
|
|
@@ -3477,6 +3477,12 @@ function parent(object, path) {
|
|
|
3477
3477
|
|
|
3478
3478
|
var _parent = parent;
|
|
3479
3479
|
|
|
3480
|
+
/** Used for built-in method references. */
|
|
3481
|
+
var objectProto$1 = Object.prototype;
|
|
3482
|
+
|
|
3483
|
+
/** Used to check objects for own properties. */
|
|
3484
|
+
var hasOwnProperty$1 = objectProto$1.hasOwnProperty;
|
|
3485
|
+
|
|
3480
3486
|
/**
|
|
3481
3487
|
* The base implementation of `_.unset`.
|
|
3482
3488
|
*
|
|
@@ -3487,8 +3493,47 @@ var _parent = parent;
|
|
|
3487
3493
|
*/
|
|
3488
3494
|
function baseUnset(object, path) {
|
|
3489
3495
|
path = _castPath(path, object);
|
|
3490
|
-
|
|
3491
|
-
|
|
3496
|
+
|
|
3497
|
+
// Prevent prototype pollution, see: https://github.com/lodash/lodash/security/advisories/GHSA-xxjr-mmjv-4gpg
|
|
3498
|
+
var index = -1,
|
|
3499
|
+
length = path.length;
|
|
3500
|
+
|
|
3501
|
+
if (!length) {
|
|
3502
|
+
return true;
|
|
3503
|
+
}
|
|
3504
|
+
|
|
3505
|
+
var isRootPrimitive = object == null || (typeof object !== 'object' && typeof object !== 'function');
|
|
3506
|
+
|
|
3507
|
+
while (++index < length) {
|
|
3508
|
+
var key = path[index];
|
|
3509
|
+
|
|
3510
|
+
// skip non-string keys (e.g., Symbols, numbers)
|
|
3511
|
+
if (typeof key !== 'string') {
|
|
3512
|
+
continue;
|
|
3513
|
+
}
|
|
3514
|
+
|
|
3515
|
+
// Always block "__proto__" anywhere in the path if it's not expected
|
|
3516
|
+
if (key === '__proto__' && !hasOwnProperty$1.call(object, '__proto__')) {
|
|
3517
|
+
return false;
|
|
3518
|
+
}
|
|
3519
|
+
|
|
3520
|
+
// Block "constructor.prototype" chains
|
|
3521
|
+
if (key === 'constructor' &&
|
|
3522
|
+
(index + 1) < length &&
|
|
3523
|
+
typeof path[index + 1] === 'string' &&
|
|
3524
|
+
path[index + 1] === 'prototype') {
|
|
3525
|
+
|
|
3526
|
+
// Allow ONLY when the path starts at a primitive root, e.g., _.unset(0, 'constructor.prototype.a')
|
|
3527
|
+
if (isRootPrimitive && index === 0) {
|
|
3528
|
+
continue;
|
|
3529
|
+
}
|
|
3530
|
+
|
|
3531
|
+
return false;
|
|
3532
|
+
}
|
|
3533
|
+
}
|
|
3534
|
+
|
|
3535
|
+
var obj = _parent(object, path);
|
|
3536
|
+
return obj == null || delete obj[_toKey(last_1(path))];
|
|
3492
3537
|
}
|
|
3493
3538
|
|
|
3494
3539
|
var _baseUnset = baseUnset;
|
|
@@ -4107,8 +4152,8 @@ const Signature = withLocale(({
|
|
|
4107
4152
|
scale: 2
|
|
4108
4153
|
});
|
|
4109
4154
|
const canvas = document.createElement('canvas');
|
|
4110
|
-
canvas.width = width * 2;
|
|
4111
|
-
canvas.height = height *
|
|
4155
|
+
canvas.width = Math.min(width * 2, 300);
|
|
4156
|
+
canvas.height = Math.round(height * 368 / canvas.width);
|
|
4112
4157
|
const ctx = canvas.getContext('2d');
|
|
4113
4158
|
ctx.drawImage(maskPng, 0, 0, canvas.width, canvas.height);
|
|
4114
4159
|
const resultImage = new Image();
|