@ni/nimble-components 29.3.6 → 29.3.7

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.
@@ -16280,7 +16280,7 @@
16280
16280
 
16281
16281
  /**
16282
16282
  * Do not edit directly
16283
- * Generated on Thu, 13 Jun 2024 16:48:33 GMT
16283
+ * Generated on Mon, 17 Jun 2024 15:00:56 GMT
16284
16284
  */
16285
16285
 
16286
16286
  const Information100DarkUi = "#a46eff";
@@ -51839,38 +51839,35 @@ img.ProseMirror-separator {
51839
51839
  LinkifyIt.prototype.onCompile = function onCompile () {
51840
51840
  };
51841
51841
 
51842
- /*! https://mths.be/punycode v1.4.1 by @mathias */
51843
-
51844
-
51845
51842
  /** Highest positive signed 32-bit float value */
51846
- var maxInt = 2147483647; // aka. 0x7FFFFFFF or 2^31-1
51843
+ const maxInt = 2147483647; // aka. 0x7FFFFFFF or 2^31-1
51847
51844
 
51848
51845
  /** Bootstring parameters */
51849
- var base = 36;
51850
- var tMin = 1;
51851
- var tMax = 26;
51852
- var skew = 38;
51853
- var damp = 700;
51854
- var initialBias = 72;
51855
- var initialN = 128; // 0x80
51856
- var delimiter = '-'; // '\x2D'
51846
+ const base = 36;
51847
+ const tMin = 1;
51848
+ const tMax = 26;
51849
+ const skew = 38;
51850
+ const damp = 700;
51851
+ const initialBias = 72;
51852
+ const initialN = 128; // 0x80
51853
+ const delimiter = '-'; // '\x2D'
51857
51854
 
51858
51855
  /** Regular expressions */
51859
- var regexPunycode = /^xn--/;
51860
- var regexNonASCII = /[^\x20-\x7E]/; // unprintable ASCII chars + non-ASCII chars
51861
- var regexSeparators = /[\x2E\u3002\uFF0E\uFF61]/g; // RFC 3490 separators
51856
+ const regexPunycode = /^xn--/;
51857
+ const regexNonASCII = /[^\0-\x7F]/; // Note: U+007F DEL is excluded too.
51858
+ const regexSeparators = /[\x2E\u3002\uFF0E\uFF61]/g; // RFC 3490 separators
51862
51859
 
51863
51860
  /** Error messages */
51864
- var errors = {
51865
- 'overflow': 'Overflow: input needs wider integers to process',
51866
- 'not-basic': 'Illegal input >= 0x80 (not a basic code point)',
51867
- 'invalid-input': 'Invalid input'
51861
+ const errors = {
51862
+ 'overflow': 'Overflow: input needs wider integers to process',
51863
+ 'not-basic': 'Illegal input >= 0x80 (not a basic code point)',
51864
+ 'invalid-input': 'Invalid input'
51868
51865
  };
51869
51866
 
51870
51867
  /** Convenience shortcuts */
51871
- var baseMinusTMin = base - tMin;
51872
- var floor = Math.floor;
51873
- var stringFromCharCode = String.fromCharCode;
51868
+ const baseMinusTMin = base - tMin;
51869
+ const floor = Math.floor;
51870
+ const stringFromCharCode = String.fromCharCode;
51874
51871
 
51875
51872
  /*--------------------------------------------------------------------------*/
51876
51873
 
@@ -51881,7 +51878,7 @@ img.ProseMirror-separator {
51881
51878
  * @returns {Error} Throws a `RangeError` with the applicable error message.
51882
51879
  */
51883
51880
  function error(type) {
51884
- throw new RangeError(errors[type]);
51881
+ throw new RangeError(errors[type]);
51885
51882
  }
51886
51883
 
51887
51884
  /**
@@ -51892,13 +51889,13 @@ img.ProseMirror-separator {
51892
51889
  * item.
51893
51890
  * @returns {Array} A new array of values returned by the callback function.
51894
51891
  */
51895
- function map$1(array, fn) {
51896
- var length = array.length;
51897
- var result = [];
51898
- while (length--) {
51899
- result[length] = fn(array[length]);
51900
- }
51901
- return result;
51892
+ function map$1(array, callback) {
51893
+ const result = [];
51894
+ let length = array.length;
51895
+ while (length--) {
51896
+ result[length] = callback(array[length]);
51897
+ }
51898
+ return result;
51902
51899
  }
51903
51900
 
51904
51901
  /**
@@ -51908,23 +51905,23 @@ img.ProseMirror-separator {
51908
51905
  * @param {String} domain The domain name or email address.
51909
51906
  * @param {Function} callback The function that gets called for every
51910
51907
  * character.
51911
- * @returns {Array} A new string of characters returned by the callback
51908
+ * @returns {String} A new string of characters returned by the callback
51912
51909
  * function.
51913
51910
  */
51914
- function mapDomain(string, fn) {
51915
- var parts = string.split('@');
51916
- var result = '';
51917
- if (parts.length > 1) {
51918
- // In email addresses, only the domain name should be punycoded. Leave
51919
- // the local part (i.e. everything up to `@`) intact.
51920
- result = parts[0] + '@';
51921
- string = parts[1];
51922
- }
51923
- // Avoid `split(regex)` for IE8 compatibility. See #17.
51924
- string = string.replace(regexSeparators, '\x2E');
51925
- var labels = string.split('.');
51926
- var encoded = map$1(labels, fn).join('.');
51927
- return result + encoded;
51911
+ function mapDomain(domain, callback) {
51912
+ const parts = domain.split('@');
51913
+ let result = '';
51914
+ if (parts.length > 1) {
51915
+ // In email addresses, only the domain name should be punycoded. Leave
51916
+ // the local part (i.e. everything up to `@`) intact.
51917
+ result = parts[0] + '@';
51918
+ domain = parts[1];
51919
+ }
51920
+ // Avoid `split(regex)` for IE8 compatibility. See #17.
51921
+ domain = domain.replace(regexSeparators, '\x2E');
51922
+ const labels = domain.split('.');
51923
+ const encoded = map$1(labels, callback).join('.');
51924
+ return result + encoded;
51928
51925
  }
51929
51926
 
51930
51927
  /**
@@ -51941,29 +51938,27 @@ img.ProseMirror-separator {
51941
51938
  * @returns {Array} The new array of code points.
51942
51939
  */
51943
51940
  function ucs2decode(string) {
51944
- var output = [],
51945
- counter = 0,
51946
- length = string.length,
51947
- value,
51948
- extra;
51949
- while (counter < length) {
51950
- value = string.charCodeAt(counter++);
51951
- if (value >= 0xD800 && value <= 0xDBFF && counter < length) {
51952
- // high surrogate, and there is a next character
51953
- extra = string.charCodeAt(counter++);
51954
- if ((extra & 0xFC00) == 0xDC00) { // low surrogate
51955
- output.push(((value & 0x3FF) << 10) + (extra & 0x3FF) + 0x10000);
51956
- } else {
51957
- // unmatched surrogate; only append this code unit, in case the next
51958
- // code unit is the high surrogate of a surrogate pair
51959
- output.push(value);
51960
- counter--;
51961
- }
51962
- } else {
51963
- output.push(value);
51964
- }
51965
- }
51966
- return output;
51941
+ const output = [];
51942
+ let counter = 0;
51943
+ const length = string.length;
51944
+ while (counter < length) {
51945
+ const value = string.charCodeAt(counter++);
51946
+ if (value >= 0xD800 && value <= 0xDBFF && counter < length) {
51947
+ // It's a high surrogate, and there is a next character.
51948
+ const extra = string.charCodeAt(counter++);
51949
+ if ((extra & 0xFC00) == 0xDC00) { // Low surrogate.
51950
+ output.push(((value & 0x3FF) << 10) + (extra & 0x3FF) + 0x10000);
51951
+ } else {
51952
+ // It's an unmatched surrogate; only append this code unit, in case the
51953
+ // next code unit is the high surrogate of a surrogate pair.
51954
+ output.push(value);
51955
+ counter--;
51956
+ }
51957
+ } else {
51958
+ output.push(value);
51959
+ }
51960
+ }
51961
+ return output;
51967
51962
  }
51968
51963
 
51969
51964
  /**
@@ -51974,18 +51969,7 @@ img.ProseMirror-separator {
51974
51969
  * @param {Array} codePoints The array of numeric code points.
51975
51970
  * @returns {String} The new Unicode string (UCS-2).
51976
51971
  */
51977
- function ucs2encode(array) {
51978
- return map$1(array, function(value) {
51979
- var output = '';
51980
- if (value > 0xFFFF) {
51981
- value -= 0x10000;
51982
- output += stringFromCharCode(value >>> 10 & 0x3FF | 0xD800);
51983
- value = 0xDC00 | value & 0x3FF;
51984
- }
51985
- output += stringFromCharCode(value);
51986
- return output;
51987
- }).join('');
51988
- }
51972
+ const ucs2encode = codePoints => String.fromCodePoint(...codePoints);
51989
51973
 
51990
51974
  /**
51991
51975
  * Converts a basic code point into a digit/integer.
@@ -51996,18 +51980,18 @@ img.ProseMirror-separator {
51996
51980
  * representing integers) in the range `0` to `base - 1`, or `base` if
51997
51981
  * the code point does not represent a value.
51998
51982
  */
51999
- function basicToDigit(codePoint) {
52000
- if (codePoint - 48 < 10) {
52001
- return codePoint - 22;
52002
- }
52003
- if (codePoint - 65 < 26) {
52004
- return codePoint - 65;
52005
- }
52006
- if (codePoint - 97 < 26) {
52007
- return codePoint - 97;
52008
- }
52009
- return base;
52010
- }
51983
+ const basicToDigit = function(codePoint) {
51984
+ if (codePoint >= 0x30 && codePoint < 0x3A) {
51985
+ return 26 + (codePoint - 0x30);
51986
+ }
51987
+ if (codePoint >= 0x41 && codePoint < 0x5B) {
51988
+ return codePoint - 0x41;
51989
+ }
51990
+ if (codePoint >= 0x61 && codePoint < 0x7B) {
51991
+ return codePoint - 0x61;
51992
+ }
51993
+ return base;
51994
+ };
52011
51995
 
52012
51996
  /**
52013
51997
  * Converts a digit/integer into a basic code point.
@@ -52020,26 +52004,26 @@ img.ProseMirror-separator {
52020
52004
  * used; else, the lowercase form is used. The behavior is undefined
52021
52005
  * if `flag` is non-zero and `digit` has no uppercase form.
52022
52006
  */
52023
- function digitToBasic(digit, flag) {
52024
- // 0..25 map to ASCII a..z or A..Z
52025
- // 26..35 map to ASCII 0..9
52026
- return digit + 22 + 75 * (digit < 26) - ((flag != 0) << 5);
52027
- }
52007
+ const digitToBasic = function(digit, flag) {
52008
+ // 0..25 map to ASCII a..z or A..Z
52009
+ // 26..35 map to ASCII 0..9
52010
+ return digit + 22 + 75 * (digit < 26) - ((flag != 0) << 5);
52011
+ };
52028
52012
 
52029
52013
  /**
52030
52014
  * Bias adaptation function as per section 3.4 of RFC 3492.
52031
52015
  * https://tools.ietf.org/html/rfc3492#section-3.4
52032
52016
  * @private
52033
52017
  */
52034
- function adapt(delta, numPoints, firstTime) {
52035
- var k = 0;
52036
- delta = firstTime ? floor(delta / damp) : delta >> 1;
52037
- delta += floor(delta / numPoints);
52038
- for ( /* no initialization */ ; delta > baseMinusTMin * tMax >> 1; k += base) {
52039
- delta = floor(delta / baseMinusTMin);
52040
- }
52041
- return floor(k + (baseMinusTMin + 1) * delta / (delta + skew));
52042
- }
52018
+ const adapt = function(delta, numPoints, firstTime) {
52019
+ let k = 0;
52020
+ delta = firstTime ? floor(delta / damp) : delta >> 1;
52021
+ delta += floor(delta / numPoints);
52022
+ for (/* no initialization */; delta > baseMinusTMin * tMax >> 1; k += base) {
52023
+ delta = floor(delta / baseMinusTMin);
52024
+ }
52025
+ return floor(k + (baseMinusTMin + 1) * delta / (delta + skew));
52026
+ };
52043
52027
 
52044
52028
  /**
52045
52029
  * Converts a Punycode string of ASCII-only symbols to a string of Unicode
@@ -52048,213 +52032,187 @@ img.ProseMirror-separator {
52048
52032
  * @param {String} input The Punycode string of ASCII-only symbols.
52049
52033
  * @returns {String} The resulting string of Unicode symbols.
52050
52034
  */
52051
- function decode(input) {
52052
- // Don't use UCS-2
52053
- var output = [],
52054
- inputLength = input.length,
52055
- out,
52056
- i = 0,
52057
- n = initialN,
52058
- bias = initialBias,
52059
- basic,
52060
- j,
52061
- index,
52062
- oldi,
52063
- w,
52064
- k,
52065
- digit,
52066
- t,
52067
- /** Cached calculation results */
52068
- baseMinusT;
52069
-
52070
- // Handle the basic code points: let `basic` be the number of input code
52071
- // points before the last delimiter, or `0` if there is none, then copy
52072
- // the first basic code points to the output.
52073
-
52074
- basic = input.lastIndexOf(delimiter);
52075
- if (basic < 0) {
52076
- basic = 0;
52077
- }
52078
-
52079
- for (j = 0; j < basic; ++j) {
52080
- // if it's not a basic code point
52081
- if (input.charCodeAt(j) >= 0x80) {
52082
- error('not-basic');
52083
- }
52084
- output.push(input.charCodeAt(j));
52085
- }
52086
-
52087
- // Main decoding loop: start just after the last delimiter if any basic code
52088
- // points were copied; start at the beginning otherwise.
52089
-
52090
- for (index = basic > 0 ? basic + 1 : 0; index < inputLength; /* no final expression */ ) {
52091
-
52092
- // `index` is the index of the next character to be consumed.
52093
- // Decode a generalized variable-length integer into `delta`,
52094
- // which gets added to `i`. The overflow checking is easier
52095
- // if we increase `i` as we go, then subtract off its starting
52096
- // value at the end to obtain `delta`.
52097
- for (oldi = i, w = 1, k = base; /* no condition */ ; k += base) {
52098
-
52099
- if (index >= inputLength) {
52100
- error('invalid-input');
52101
- }
52035
+ const decode = function(input) {
52036
+ // Don't use UCS-2.
52037
+ const output = [];
52038
+ const inputLength = input.length;
52039
+ let i = 0;
52040
+ let n = initialN;
52041
+ let bias = initialBias;
52102
52042
 
52103
- digit = basicToDigit(input.charCodeAt(index++));
52043
+ // Handle the basic code points: let `basic` be the number of input code
52044
+ // points before the last delimiter, or `0` if there is none, then copy
52045
+ // the first basic code points to the output.
52104
52046
 
52105
- if (digit >= base || digit > floor((maxInt - i) / w)) {
52106
- error('overflow');
52107
- }
52047
+ let basic = input.lastIndexOf(delimiter);
52048
+ if (basic < 0) {
52049
+ basic = 0;
52050
+ }
52108
52051
 
52109
- i += digit * w;
52110
- t = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);
52052
+ for (let j = 0; j < basic; ++j) {
52053
+ // if it's not a basic code point
52054
+ if (input.charCodeAt(j) >= 0x80) {
52055
+ error('not-basic');
52056
+ }
52057
+ output.push(input.charCodeAt(j));
52058
+ }
52111
52059
 
52112
- if (digit < t) {
52113
- break;
52114
- }
52060
+ // Main decoding loop: start just after the last delimiter if any basic code
52061
+ // points were copied; start at the beginning otherwise.
52115
52062
 
52116
- baseMinusT = base - t;
52117
- if (w > floor(maxInt / baseMinusT)) {
52118
- error('overflow');
52119
- }
52063
+ for (let index = basic > 0 ? basic + 1 : 0; index < inputLength; /* no final expression */) {
52120
52064
 
52121
- w *= baseMinusT;
52065
+ // `index` is the index of the next character to be consumed.
52066
+ // Decode a generalized variable-length integer into `delta`,
52067
+ // which gets added to `i`. The overflow checking is easier
52068
+ // if we increase `i` as we go, then subtract off its starting
52069
+ // value at the end to obtain `delta`.
52070
+ const oldi = i;
52071
+ for (let w = 1, k = base; /* no condition */; k += base) {
52122
52072
 
52123
- }
52073
+ if (index >= inputLength) {
52074
+ error('invalid-input');
52075
+ }
52124
52076
 
52125
- out = output.length + 1;
52126
- bias = adapt(i - oldi, out, oldi == 0);
52077
+ const digit = basicToDigit(input.charCodeAt(index++));
52127
52078
 
52128
- // `i` was supposed to wrap around from `out` to `0`,
52129
- // incrementing `n` each time, so we'll fix that now:
52130
- if (floor(i / out) > maxInt - n) {
52131
- error('overflow');
52132
- }
52079
+ if (digit >= base) {
52080
+ error('invalid-input');
52081
+ }
52082
+ if (digit > floor((maxInt - i) / w)) {
52083
+ error('overflow');
52084
+ }
52133
52085
 
52134
- n += floor(i / out);
52135
- i %= out;
52086
+ i += digit * w;
52087
+ const t = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);
52136
52088
 
52137
- // Insert `n` at position `i` of the output
52138
- output.splice(i++, 0, n);
52089
+ if (digit < t) {
52090
+ break;
52091
+ }
52139
52092
 
52140
- }
52141
-
52142
- return ucs2encode(output);
52143
- }
52093
+ const baseMinusT = base - t;
52094
+ if (w > floor(maxInt / baseMinusT)) {
52095
+ error('overflow');
52096
+ }
52144
52097
 
52145
- /**
52146
- * Converts a string of Unicode symbols (e.g. a domain name label) to a
52147
- * Punycode string of ASCII-only symbols.
52148
- * @memberOf punycode
52149
- * @param {String} input The string of Unicode symbols.
52150
- * @returns {String} The resulting Punycode string of ASCII-only symbols.
52151
- */
52152
- function encode(input) {
52153
- var n,
52154
- delta,
52155
- handledCPCount,
52156
- basicLength,
52157
- bias,
52158
- j,
52159
- m,
52160
- q,
52161
- k,
52162
- t,
52163
- currentValue,
52164
- output = [],
52165
- /** `inputLength` will hold the number of code points in `input`. */
52166
- inputLength,
52167
- /** Cached calculation results */
52168
- handledCPCountPlusOne,
52169
- baseMinusT,
52170
- qMinusT;
52171
-
52172
- // Convert the input in UCS-2 to Unicode
52173
- input = ucs2decode(input);
52174
-
52175
- // Cache the length
52176
- inputLength = input.length;
52177
-
52178
- // Initialize the state
52179
- n = initialN;
52180
- delta = 0;
52181
- bias = initialBias;
52182
-
52183
- // Handle the basic code points
52184
- for (j = 0; j < inputLength; ++j) {
52185
- currentValue = input[j];
52186
- if (currentValue < 0x80) {
52187
- output.push(stringFromCharCode(currentValue));
52188
- }
52189
- }
52190
-
52191
- handledCPCount = basicLength = output.length;
52192
-
52193
- // `handledCPCount` is the number of code points that have been handled;
52194
- // `basicLength` is the number of basic code points.
52195
-
52196
- // Finish the basic string - if it is not empty - with a delimiter
52197
- if (basicLength) {
52198
- output.push(delimiter);
52199
- }
52200
-
52201
- // Main encoding loop:
52202
- while (handledCPCount < inputLength) {
52203
-
52204
- // All non-basic code points < n have been handled already. Find the next
52205
- // larger one:
52206
- for (m = maxInt, j = 0; j < inputLength; ++j) {
52207
- currentValue = input[j];
52208
- if (currentValue >= n && currentValue < m) {
52209
- m = currentValue;
52210
- }
52211
- }
52098
+ w *= baseMinusT;
52212
52099
 
52213
- // Increase `delta` enough to advance the decoder's <n,i> state to <m,0>,
52214
- // but guard against overflow
52215
- handledCPCountPlusOne = handledCPCount + 1;
52216
- if (m - n > floor((maxInt - delta) / handledCPCountPlusOne)) {
52217
- error('overflow');
52218
- }
52100
+ }
52219
52101
 
52220
- delta += (m - n) * handledCPCountPlusOne;
52221
- n = m;
52102
+ const out = output.length + 1;
52103
+ bias = adapt(i - oldi, out, oldi == 0);
52222
52104
 
52223
- for (j = 0; j < inputLength; ++j) {
52224
- currentValue = input[j];
52105
+ // `i` was supposed to wrap around from `out` to `0`,
52106
+ // incrementing `n` each time, so we'll fix that now:
52107
+ if (floor(i / out) > maxInt - n) {
52108
+ error('overflow');
52109
+ }
52225
52110
 
52226
- if (currentValue < n && ++delta > maxInt) {
52227
- error('overflow');
52228
- }
52111
+ n += floor(i / out);
52112
+ i %= out;
52229
52113
 
52230
- if (currentValue == n) {
52231
- // Represent delta as a generalized variable-length integer
52232
- for (q = delta, k = base; /* no condition */ ; k += base) {
52233
- t = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);
52234
- if (q < t) {
52235
- break;
52236
- }
52237
- qMinusT = q - t;
52238
- baseMinusT = base - t;
52239
- output.push(
52240
- stringFromCharCode(digitToBasic(t + qMinusT % baseMinusT, 0))
52241
- );
52242
- q = floor(qMinusT / baseMinusT);
52243
- }
52114
+ // Insert `n` at position `i` of the output.
52115
+ output.splice(i++, 0, n);
52244
52116
 
52245
- output.push(stringFromCharCode(digitToBasic(q, 0)));
52246
- bias = adapt(delta, handledCPCountPlusOne, handledCPCount == basicLength);
52247
- delta = 0;
52248
- ++handledCPCount;
52249
- }
52250
- }
52117
+ }
52251
52118
 
52252
- ++delta;
52253
- ++n;
52119
+ return String.fromCodePoint(...output);
52120
+ };
52254
52121
 
52255
- }
52256
- return output.join('');
52257
- }
52122
+ /**
52123
+ * Converts a string of Unicode symbols (e.g. a domain name label) to a
52124
+ * Punycode string of ASCII-only symbols.
52125
+ * @memberOf punycode
52126
+ * @param {String} input The string of Unicode symbols.
52127
+ * @returns {String} The resulting Punycode string of ASCII-only symbols.
52128
+ */
52129
+ const encode = function(input) {
52130
+ const output = [];
52131
+
52132
+ // Convert the input in UCS-2 to an array of Unicode code points.
52133
+ input = ucs2decode(input);
52134
+
52135
+ // Cache the length.
52136
+ const inputLength = input.length;
52137
+
52138
+ // Initialize the state.
52139
+ let n = initialN;
52140
+ let delta = 0;
52141
+ let bias = initialBias;
52142
+
52143
+ // Handle the basic code points.
52144
+ for (const currentValue of input) {
52145
+ if (currentValue < 0x80) {
52146
+ output.push(stringFromCharCode(currentValue));
52147
+ }
52148
+ }
52149
+
52150
+ const basicLength = output.length;
52151
+ let handledCPCount = basicLength;
52152
+
52153
+ // `handledCPCount` is the number of code points that have been handled;
52154
+ // `basicLength` is the number of basic code points.
52155
+
52156
+ // Finish the basic string with a delimiter unless it's empty.
52157
+ if (basicLength) {
52158
+ output.push(delimiter);
52159
+ }
52160
+
52161
+ // Main encoding loop:
52162
+ while (handledCPCount < inputLength) {
52163
+
52164
+ // All non-basic code points < n have been handled already. Find the next
52165
+ // larger one:
52166
+ let m = maxInt;
52167
+ for (const currentValue of input) {
52168
+ if (currentValue >= n && currentValue < m) {
52169
+ m = currentValue;
52170
+ }
52171
+ }
52172
+
52173
+ // Increase `delta` enough to advance the decoder's <n,i> state to <m,0>,
52174
+ // but guard against overflow.
52175
+ const handledCPCountPlusOne = handledCPCount + 1;
52176
+ if (m - n > floor((maxInt - delta) / handledCPCountPlusOne)) {
52177
+ error('overflow');
52178
+ }
52179
+
52180
+ delta += (m - n) * handledCPCountPlusOne;
52181
+ n = m;
52182
+
52183
+ for (const currentValue of input) {
52184
+ if (currentValue < n && ++delta > maxInt) {
52185
+ error('overflow');
52186
+ }
52187
+ if (currentValue === n) {
52188
+ // Represent delta as a generalized variable-length integer.
52189
+ let q = delta;
52190
+ for (let k = base; /* no condition */; k += base) {
52191
+ const t = k <= bias ? tMin : (k >= bias + tMax ? tMax : k - bias);
52192
+ if (q < t) {
52193
+ break;
52194
+ }
52195
+ const qMinusT = q - t;
52196
+ const baseMinusT = base - t;
52197
+ output.push(
52198
+ stringFromCharCode(digitToBasic(t + qMinusT % baseMinusT, 0))
52199
+ );
52200
+ q = floor(qMinusT / baseMinusT);
52201
+ }
52202
+
52203
+ output.push(stringFromCharCode(digitToBasic(q, 0)));
52204
+ bias = adapt(delta, handledCPCountPlusOne, handledCPCount === basicLength);
52205
+ delta = 0;
52206
+ ++handledCPCount;
52207
+ }
52208
+ }
52209
+
52210
+ ++delta;
52211
+ ++n;
52212
+
52213
+ }
52214
+ return output.join('');
52215
+ };
52258
52216
 
52259
52217
  /**
52260
52218
  * Converts a Punycode string representing a domain name or an email address
@@ -52267,13 +52225,13 @@ img.ProseMirror-separator {
52267
52225
  * @returns {String} The Unicode representation of the given Punycode
52268
52226
  * string.
52269
52227
  */
52270
- function toUnicode(input) {
52271
- return mapDomain(input, function(string) {
52272
- return regexPunycode.test(string) ?
52273
- decode(string.slice(4).toLowerCase()) :
52274
- string;
52275
- });
52276
- }
52228
+ const toUnicode = function(input) {
52229
+ return mapDomain(input, function(string) {
52230
+ return regexPunycode.test(string)
52231
+ ? decode(string.slice(4).toLowerCase())
52232
+ : string;
52233
+ });
52234
+ };
52277
52235
 
52278
52236
  /**
52279
52237
  * Converts a Unicode string representing a domain name or an email address to
@@ -52286,33 +52244,39 @@ img.ProseMirror-separator {
52286
52244
  * @returns {String} The Punycode representation of the given domain name or
52287
52245
  * email address.
52288
52246
  */
52289
- function toASCII(input) {
52290
- return mapDomain(input, function(string) {
52291
- return regexNonASCII.test(string) ?
52292
- 'xn--' + encode(string) :
52293
- string;
52294
- });
52295
- }
52296
- var version = '1.4.1';
52297
- /**
52298
- * An object of methods to convert from JavaScript's internal character
52299
- * representation (UCS-2) to Unicode code points, and back.
52300
- * @see <https://mathiasbynens.be/notes/javascript-encoding>
52301
- * @memberOf punycode
52302
- * @type Object
52303
- */
52304
-
52305
- var ucs2 = {
52306
- decode: ucs2decode,
52307
- encode: ucs2encode
52247
+ const toASCII = function(input) {
52248
+ return mapDomain(input, function(string) {
52249
+ return regexNonASCII.test(string)
52250
+ ? 'xn--' + encode(string)
52251
+ : string;
52252
+ });
52308
52253
  };
52309
- var punycode = {
52310
- version: version,
52311
- ucs2: ucs2,
52312
- toASCII: toASCII,
52313
- toUnicode: toUnicode,
52314
- encode: encode,
52315
- decode: decode
52254
+
52255
+ /*--------------------------------------------------------------------------*/
52256
+
52257
+ /** Define the public API */
52258
+ const punycode = {
52259
+ /**
52260
+ * A string representing the current Punycode.js version number.
52261
+ * @memberOf punycode
52262
+ * @type String
52263
+ */
52264
+ 'version': '2.3.1',
52265
+ /**
52266
+ * An object of methods to convert from JavaScript's internal character
52267
+ * representation (UCS-2) to Unicode code points, and back.
52268
+ * @see <https://mathiasbynens.be/notes/javascript-encoding>
52269
+ * @memberOf punycode
52270
+ * @type Object
52271
+ */
52272
+ 'ucs2': {
52273
+ 'decode': ucs2decode,
52274
+ 'encode': ucs2encode
52275
+ },
52276
+ 'decode': decode,
52277
+ 'encode': encode,
52278
+ 'toASCII': toASCII,
52279
+ 'toUnicode': toUnicode
52316
52280
  };
52317
52281
 
52318
52282
  // markdown-it default options