@digipair/skill-keycloak 0.21.2 → 0.21.7

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. package/index.cjs.js +121 -911
  2. package/index.esm.js +121 -911
  3. package/package.json +1 -1
package/index.cjs.js CHANGED
@@ -10247,7 +10247,7 @@ var InvalidZone = /*#__PURE__*/ function(Zone) {
10247
10247
 
10248
10248
  /**
10249
10249
  * @private
10250
- */ function _instanceof$h(left, right) {
10250
+ */ function _instanceof$g(left, right) {
10251
10251
  if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
10252
10252
  return !!right[Symbol.hasInstance](left);
10253
10253
  } else {
@@ -10257,7 +10257,7 @@ var InvalidZone = /*#__PURE__*/ function(Zone) {
10257
10257
  function normalizeZone(input, defaultZone) {
10258
10258
  if (isUndefined(input) || input === null) {
10259
10259
  return defaultZone;
10260
- } else if (_instanceof$h(input, Zone)) {
10260
+ } else if (_instanceof$g(input, Zone)) {
10261
10261
  return input;
10262
10262
  } else if (isString$4(input)) {
10263
10263
  var lowered = input.toLowerCase();
@@ -12231,7 +12231,7 @@ function _define_property$4(obj, key, value) {
12231
12231
  }
12232
12232
  return obj;
12233
12233
  }
12234
- function _instanceof$g(left, right) {
12234
+ function _instanceof$f(left, right) {
12235
12235
  if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
12236
12236
  return !!right[Symbol.hasInstance](left);
12237
12237
  } else {
@@ -13367,7 +13367,7 @@ var Duration = /*#__PURE__*/ function() {
13367
13367
  if (!reason) {
13368
13368
  throw new InvalidArgumentError("need to specify a reason the Duration is invalid");
13369
13369
  }
13370
- var invalid = _instanceof$g(reason, Invalid) ? reason : new Invalid(reason, explanation);
13370
+ var invalid = _instanceof$f(reason, Invalid) ? reason : new Invalid(reason, explanation);
13371
13371
  if (Settings.throwOnInvalid) {
13372
13372
  throw new InvalidDurationError(invalid);
13373
13373
  } else {
@@ -13450,7 +13450,7 @@ function _create_class$b(Constructor, protoProps, staticProps) {
13450
13450
  if (staticProps) _defineProperties$b(Constructor, staticProps);
13451
13451
  return Constructor;
13452
13452
  }
13453
- function _instanceof$f(left, right) {
13453
+ function _instanceof$e(left, right) {
13454
13454
  if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
13455
13455
  return !!right[Symbol.hasInstance](left);
13456
13456
  } else {
@@ -14002,7 +14002,7 @@ var Interval = /*#__PURE__*/ function() {
14002
14002
  if (!reason) {
14003
14003
  throw new InvalidArgumentError("need to specify a reason the Interval is invalid");
14004
14004
  }
14005
- var invalid = _instanceof$f(reason, Invalid) ? reason : new Invalid(reason, explanation);
14005
+ var invalid = _instanceof$e(reason, Invalid) ? reason : new Invalid(reason, explanation);
14006
14006
  if (Settings.throwOnInvalid) {
14007
14007
  throw new InvalidIntervalError(invalid);
14008
14008
  } else {
@@ -15397,7 +15397,7 @@ function _define_property$2(obj, key, value) {
15397
15397
  }
15398
15398
  return obj;
15399
15399
  }
15400
- function _instanceof$e(left, right) {
15400
+ function _instanceof$d(left, right) {
15401
15401
  if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
15402
15402
  return !!right[Symbol.hasInstance](left);
15403
15403
  } else {
@@ -17584,7 +17584,7 @@ var DateTime = /*#__PURE__*/ function() {
17584
17584
  if (!reason) {
17585
17585
  throw new InvalidArgumentError("need to specify a reason the DateTime is invalid");
17586
17586
  }
17587
- var invalid = _instanceof$e(reason, Invalid) ? reason : new Invalid(reason, explanation);
17587
+ var invalid = _instanceof$d(reason, Invalid) ? reason : new Invalid(reason, explanation);
17588
17588
  if (Settings.throwOnInvalid) {
17589
17589
  throw new InvalidDateTimeError(invalid);
17590
17590
  } else {
@@ -17969,7 +17969,7 @@ function _inherits$2(subClass, superClass) {
17969
17969
  });
17970
17970
  if (superClass) _set_prototype_of$2(subClass, superClass);
17971
17971
  }
17972
- function _instanceof$d(left, right) {
17972
+ function _instanceof$c(left, right) {
17973
17973
  if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
17974
17974
  return !!right[Symbol.hasInstance](left);
17975
17975
  } else {
@@ -18898,14 +18898,14 @@ function resolveNode(node, pos, side, overlays) {
18898
18898
  var _a;
18899
18899
  // Move up to a node that actually holds the position, if possible
18900
18900
  while(node.from == node.to || (side < 1 ? node.from >= pos : node.from > pos) || (side > -1 ? node.to <= pos : node.to < pos)){
18901
- var parent = !overlays && _instanceof$d(node, TreeNode) && node.index < 0 ? null : node.parent;
18901
+ var parent = !overlays && _instanceof$c(node, TreeNode) && node.index < 0 ? null : node.parent;
18902
18902
  if (!parent) return node;
18903
18903
  node = parent;
18904
18904
  }
18905
18905
  var mode = overlays ? 0 : IterMode.IgnoreOverlays;
18906
18906
  // Must go up out of overlays when those do not overlap with pos
18907
18907
  if (overlays) for(var scan = node, parent1 = scan.parent; parent1; scan = parent1, parent1 = scan.parent){
18908
- if (_instanceof$d(scan, TreeNode) && scan.index < 0 && ((_a = parent1.enter(pos, side, mode)) === null || _a === void 0 ? void 0 : _a.from) != scan.from) node = parent1;
18908
+ if (_instanceof$c(scan, TreeNode) && scan.index < 0 && ((_a = parent1.enter(pos, side, mode)) === null || _a === void 0 ? void 0 : _a.from) != scan.from) node = parent1;
18909
18909
  }
18910
18910
  for(;;){
18911
18911
  var inner = node.enter(pos, side, mode);
@@ -19033,7 +19033,7 @@ var TreeNode = /*#__PURE__*/ function(BaseNode) {
19033
19033
  for(var _parent__tree = parent._tree, children = _parent__tree.children, positions = _parent__tree.positions, e = dir > 0 ? children.length : -1; i != e; i += dir){
19034
19034
  var next = children[i], start = positions[i] + parent.from;
19035
19035
  if (!checkSide(side, pos, start, start + next.length)) continue;
19036
- if (_instanceof$d(next, TreeBuffer)) {
19036
+ if (_instanceof$c(next, TreeBuffer)) {
19037
19037
  if (mode & IterMode.ExcludeBuffers) continue;
19038
19038
  var index = next.findChild(0, next.buffer.length, dir, pos - start, side);
19039
19039
  if (index > -1) return new BufferNode(new BufferContext(parent, next, i, start), null, index);
@@ -19332,7 +19332,7 @@ function iterStack(heads) {
19332
19332
  pick = i;
19333
19333
  }
19334
19334
  }
19335
- var next = _instanceof$d(picked, TreeNode) && picked.index < 0 ? null : picked.parent;
19335
+ var next = _instanceof$c(picked, TreeNode) && picked.index < 0 ? null : picked.parent;
19336
19336
  var newHeads = heads.slice();
19337
19337
  if (next) newHeads[pick] = next;
19338
19338
  else newHeads.splice(pick, 1);
@@ -19356,7 +19356,7 @@ var StackIterator = /*#__PURE__*/ function() {
19356
19356
  }();
19357
19357
  function stackIterator(tree, pos, side) {
19358
19358
  var inner = tree.resolveInner(pos, side), layers = null;
19359
- for(var scan = _instanceof$d(inner, TreeNode) ? inner : inner.context.parent; scan; scan = scan.parent){
19359
+ for(var scan = _instanceof$c(inner, TreeNode) ? inner : inner.context.parent; scan; scan = scan.parent){
19360
19360
  if (scan.index < 0) {
19361
19361
  var parent = scan.parent;
19362
19362
  (layers || (layers = [
@@ -19394,7 +19394,7 @@ allows you to move to adjacent nodes.
19394
19394
  @internal
19395
19395
  */ this.index = 0;
19396
19396
  this.bufferNode = null;
19397
- if (_instanceof$d(node, TreeNode)) {
19397
+ if (_instanceof$c(node, TreeNode)) {
19398
19398
  this.yieldNode(node);
19399
19399
  } else {
19400
19400
  this._tree = node.context.parent;
@@ -19441,7 +19441,7 @@ allows you to move to adjacent nodes.
19441
19441
  */ key: "yield",
19442
19442
  value: function _yield(node) {
19443
19443
  if (!node) return false;
19444
- if (_instanceof$d(node, TreeNode)) {
19444
+ if (_instanceof$c(node, TreeNode)) {
19445
19445
  this.buffer = null;
19446
19446
  return this.yieldNode(node);
19447
19447
  }
@@ -19582,7 +19582,7 @@ allows you to move to adjacent nodes.
19582
19582
  for(; parent; ref2 = parent, index = ref2.index, parent = ref2._parent, ref2){
19583
19583
  if (index > -1) for(var i1 = index + dir, e = dir < 0 ? -1 : parent._tree.children.length; i1 != e; i1 += dir){
19584
19584
  var child = parent._tree.children[i1];
19585
- if (this.mode & IterMode.IncludeAnonymous || _instanceof$d(child, TreeBuffer) || !child.type.isAnonymous || hasChild(child)) return false;
19585
+ if (this.mode & IterMode.IncludeAnonymous || _instanceof$c(child, TreeBuffer) || !child.type.isAnonymous || hasChild(child)) return false;
19586
19586
  }
19587
19587
  }
19588
19588
  return true;
@@ -19725,7 +19725,7 @@ allows you to move to adjacent nodes.
19725
19725
  }();
19726
19726
  function hasChild(tree) {
19727
19727
  return tree.children.some(function(ch) {
19728
- return _instanceof$d(ch, TreeBuffer) || !ch.type.isAnonymous || hasChild(ch);
19728
+ return _instanceof$c(ch, TreeBuffer) || !ch.type.isAnonymous || hasChild(ch);
19729
19729
  });
19730
19730
  }
19731
19731
  function buildTree(data) {
@@ -19828,7 +19828,7 @@ function buildTree(data) {
19828
19828
  function makeBalanced(type) {
19829
19829
  return function(children, positions, length) {
19830
19830
  var lookAhead = 0, lastI = children.length - 1, last, lookAheadProp;
19831
- if (lastI >= 0 && _instanceof$d(last = children[lastI], Tree)) {
19831
+ if (lastI >= 0 && _instanceof$c(last = children[lastI], Tree)) {
19832
19832
  if (!lastI && last.type == type && last.length == length) return last;
19833
19833
  if (lookAheadProp = last.prop(NodeProp.lookAhead)) lookAhead = positions[lastI] + last.length + lookAheadProp;
19834
19834
  }
@@ -19950,7 +19950,7 @@ function buildTree(data) {
19950
19950
  }
19951
19951
  var nodeSizeCache = new WeakMap;
19952
19952
  function nodeSize(balanceType, node) {
19953
- if (!balanceType.isAnonymous || _instanceof$d(node, TreeBuffer) || node.type != balanceType) return 1;
19953
+ if (!balanceType.isAnonymous || _instanceof$c(node, TreeBuffer) || node.type != balanceType) return 1;
19954
19954
  var size = nodeSizeCache.get(node);
19955
19955
  if (size == null) {
19956
19956
  size = 1;
@@ -19958,7 +19958,7 @@ function nodeSize(balanceType, node) {
19958
19958
  try {
19959
19959
  for(var _iterator = node.children[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true){
19960
19960
  var child = _step.value;
19961
- if (child.type != balanceType || !_instanceof$d(child, Tree)) {
19961
+ if (child.type != balanceType || !_instanceof$c(child, Tree)) {
19962
19962
  size = 1;
19963
19963
  break;
19964
19964
  }
@@ -20157,7 +20157,7 @@ function _inherits$1(subClass, superClass) {
20157
20157
  });
20158
20158
  if (superClass) _set_prototype_of$1(subClass, superClass);
20159
20159
  }
20160
- function _instanceof$c(left, right) {
20160
+ function _instanceof$b(left, right) {
20161
20161
  if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
20162
20162
  return !!right[Symbol.hasInstance](left);
20163
20163
  } else {
@@ -20356,6 +20356,7 @@ about the parse state.
20356
20356
  var _a;
20357
20357
  var depth = action >> 19 /* Action.ReduceDepthShift */ , type = action & 65535 /* Action.ValueMask */ ;
20358
20358
  var parser = this.p.parser;
20359
+ if (this.reducePos < this.pos - 25 /* Lookahead.Margin */ ) this.setLookAhead(this.pos);
20359
20360
  var dPrec = parser.dynamicPrecedence(type);
20360
20361
  if (dPrec) this.score += dPrec;
20361
20362
  if (depth == 0) {
@@ -21308,7 +21309,7 @@ function cutAt(tree, pos, side) {
21308
21309
  cursor.moveTo(pos);
21309
21310
  for(;;){
21310
21311
  if (!(side < 0 ? cursor.childBefore(pos) : cursor.childAfter(pos))) for(;;){
21311
- if ((side < 0 ? cursor.to < pos : cursor.from > pos) && !cursor.type.isError) return side < 0 ? Math.max(0, Math.min(cursor.to - 1, pos - 25 /* Safety.Margin */ )) : Math.min(tree.length, Math.max(cursor.from + 1, pos + 25 /* Safety.Margin */ ));
21312
+ if ((side < 0 ? cursor.to < pos : cursor.from > pos) && !cursor.type.isError) return side < 0 ? Math.max(0, Math.min(cursor.to - 1, pos - 25 /* Lookahead.Margin */ )) : Math.min(tree.length, Math.max(cursor.from + 1, pos + 25 /* Lookahead.Margin */ ));
21312
21313
  if (side < 0 ? cursor.prevSibling() : cursor.nextSibling()) break;
21313
21314
  if (!cursor.parent()) return side < 0 ? 0 : tree.length;
21314
21315
  }
@@ -21376,7 +21377,7 @@ var FragmentCursor = /*#__PURE__*/ function() {
21376
21377
  this.nextStart = start;
21377
21378
  return null;
21378
21379
  }
21379
- if (_instanceof$c(next, Tree)) {
21380
+ if (_instanceof$b(next, Tree)) {
21380
21381
  if (start == pos) {
21381
21382
  if (start < this.safeFrom) return null;
21382
21383
  var end = start + next.length;
@@ -21431,7 +21432,7 @@ var TokenCache = /*#__PURE__*/ function() {
21431
21432
  token.mask = mask;
21432
21433
  token.context = context;
21433
21434
  }
21434
- if (token.lookAhead > token.end + 25 /* Safety.Margin */ ) lookAhead = Math.max(token.lookAhead, lookAhead);
21435
+ if (token.lookAhead > token.end + 25 /* Lookahead.Margin */ ) lookAhead = Math.max(token.lookAhead, lookAhead);
21435
21436
  if (token.value != 0 /* Term.Err */ ) {
21436
21437
  var startIndex = actionIndex;
21437
21438
  if (token.extended > -1) actionIndex = this.addActions(stack, token.extended, token.end, actionIndex);
@@ -21679,9 +21680,9 @@ var Parse = /*#__PURE__*/ function() {
21679
21680
  if (verbose) console.log(base + this.stackID(stack) + " (via reuse of ".concat(parser.getName(cached.type.id), ")"));
21680
21681
  return true;
21681
21682
  }
21682
- if (!_instanceof$c(cached, Tree) || cached.children.length == 0 || cached.positions[0] > 0) break;
21683
+ if (!_instanceof$b(cached, Tree) || cached.children.length == 0 || cached.positions[0] > 0) break;
21683
21684
  var inner = cached.children[0];
21684
- if (_instanceof$c(inner, Tree) && cached.positions[0] == 0) cached = inner;
21685
+ if (_instanceof$b(inner, Tree) && cached.positions[0] == 0) cached = inner;
21685
21686
  else break;
21686
21687
  }
21687
21688
  }
@@ -23255,7 +23256,7 @@ function _define_property$1(obj, key, value) {
23255
23256
  }
23256
23257
  return obj;
23257
23258
  }
23258
- function _instanceof$b(left, right) {
23259
+ function _instanceof$a(left, right) {
23259
23260
  if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
23260
23261
  return !!right[Symbol.hasInstance](left);
23261
23262
  } else {
@@ -23522,14 +23523,14 @@ function indent(str, spaces) {
23522
23523
  var match = parseIdentifier(input, i1, namePart) || namePart && parseAdditionalSymbol(input, i1) || maybeSpace && parseSpaces(input, i1);
23523
23524
  // match is required
23524
23525
  if (!match) {
23525
- return i = i1, nextMatch = nextMatch1, tokens = tokens1, {
23526
+ return tokens = tokens1, i = i1, nextMatch = nextMatch1, {
23526
23527
  v: nextMatch1
23527
23528
  };
23528
23529
  }
23529
23530
  var token = match.token, offset = match.offset;
23530
23531
  i1 += offset;
23531
23532
  if (token === " ") {
23532
- return i = i1, nextMatch = nextMatch1, tokens = tokens1, "continue";
23533
+ return tokens = tokens1, i = i1, nextMatch = nextMatch1, "continue";
23533
23534
  }
23534
23535
  tokens1 = _to_consumable_array$3(tokens1).concat([
23535
23536
  token
@@ -23548,7 +23549,7 @@ function indent(str, spaces) {
23548
23549
  if (contextKeys.some(function(el) {
23549
23550
  return el.startsWith(name);
23550
23551
  })) {
23551
- return i = i1, nextMatch = nextMatch1, tokens = tokens1, "continue";
23552
+ return tokens = tokens1, i = i1, nextMatch = nextMatch1, "continue";
23552
23553
  }
23553
23554
  if (dateTimeIdentifiers.some(function(el) {
23554
23555
  return el === name;
@@ -23567,9 +23568,9 @@ function indent(str, spaces) {
23567
23568
  if (dateTimeIdentifiers.some(function(el) {
23568
23569
  return el.startsWith(name);
23569
23570
  })) {
23570
- return i = i1, nextMatch = nextMatch1, tokens = tokens1, "continue";
23571
+ return tokens = tokens1, i = i1, nextMatch = nextMatch1, "continue";
23571
23572
  }
23572
- return i = i1, nextMatch = nextMatch1, tokens = tokens1, {
23573
+ return tokens = tokens1, i = i1, nextMatch = nextMatch1, {
23573
23574
  v: nextMatch1
23574
23575
  };
23575
23576
  };
@@ -23732,7 +23733,7 @@ var dateTimeIdentifiers = Object.keys(dateTimeLiterals);
23732
23733
  * @param {any} value
23733
23734
  * @returns {Boolean}
23734
23735
  */ function isAtomic(value) {
23735
- return !value || _instanceof$b(value, this) || _instanceof$b(value, ValueProducer) || typeof value !== "object";
23736
+ return !value || _instanceof$a(value, this) || _instanceof$a(value, ValueProducer) || typeof value !== "object";
23736
23737
  }
23737
23738
  },
23738
23739
  {
@@ -23751,7 +23752,7 @@ var dateTimeIdentifiers = Object.keys(dateTimeLiterals);
23751
23752
  if (!context || typeof context !== "object") {
23752
23753
  return {};
23753
23754
  }
23754
- if (_instanceof$b(context, _this)) {
23755
+ if (_instanceof$a(context, _this)) {
23755
23756
  return context.value;
23756
23757
  }
23757
23758
  return _object_spread({}, context);
@@ -23870,7 +23871,7 @@ var Variables = /*#__PURE__*/ function() {
23870
23871
  return undefined;
23871
23872
  }
23872
23873
  var val = this.context.get(contextKey);
23873
- if (_instanceof$b(val, ValueProducer)) {
23874
+ if (_instanceof$a(val, ValueProducer)) {
23874
23875
  return val.get(this);
23875
23876
  } else {
23876
23877
  return val;
@@ -24372,6 +24373,7 @@ var parser = LRParser.deserialize({
24372
24373
  },
24373
24374
  dynamicPrecedences: {
24374
24375
  "31": -1,
24376
+ "67": 1,
24375
24377
  "71": -1,
24376
24378
  "73": -1
24377
24379
  },
@@ -24471,7 +24473,7 @@ function _inherits(subClass, superClass) {
24471
24473
  });
24472
24474
  if (superClass) _set_prototype_of(subClass, superClass);
24473
24475
  }
24474
- function _instanceof$a(left, right) {
24476
+ function _instanceof$9(left, right) {
24475
24477
  if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
24476
24478
  return !!right[Symbol.hasInstance](left);
24477
24479
  } else {
@@ -24644,10 +24646,10 @@ function getType(e) {
24644
24646
  }
24645
24647
  return "date time";
24646
24648
  }
24647
- if (_instanceof$a(e, Range$c)) {
24649
+ if (_instanceof$9(e, Range$c)) {
24648
24650
  return "range";
24649
24651
  }
24650
- if (_instanceof$a(e, FunctionWrapper)) {
24652
+ if (_instanceof$9(e, FunctionWrapper)) {
24651
24653
  return "function";
24652
24654
  }
24653
24655
  return "literal";
@@ -25909,13 +25911,13 @@ function createArgsValidator(argDefinitions) {
25909
25911
  * @param {Range|number} a
25910
25912
  * @param {Range|number} b
25911
25913
  */ function before$1(a, b) {
25912
- if (_instanceof$a(a, Range$c) && _instanceof$a(b, Range$c)) {
25914
+ if (_instanceof$9(a, Range$c) && _instanceof$9(b, Range$c)) {
25913
25915
  return a.end < b.start || (!a["end included"] || !b["start included"]) && a.end == b.start;
25914
25916
  }
25915
- if (_instanceof$a(a, Range$c)) {
25917
+ if (_instanceof$9(a, Range$c)) {
25916
25918
  return a.end < b || !a["end included"] && a.end === b;
25917
25919
  }
25918
- if (_instanceof$a(b, Range$c)) {
25920
+ if (_instanceof$9(b, Range$c)) {
25919
25921
  return b.start > a || !b["start included"] && b.start === a;
25920
25922
  }
25921
25923
  return a < b;
@@ -26581,7 +26583,7 @@ function evalNode(node, input, args) {
26581
26583
  return tag(function(context) {
26582
26584
  var a = args[0](context);
26583
26585
  var b = args[3](context);
26584
- return _instanceof$a(a, b);
26586
+ return _instanceof$9(a, b);
26585
26587
  }, Test("boolean"));
26586
26588
  case "every":
26587
26589
  return tag(function(context) {
@@ -26858,7 +26860,7 @@ function evalNode(node, input, args) {
26858
26860
  if (typeof result === "function") {
26859
26861
  result = result(el);
26860
26862
  }
26861
- if (_instanceof$a(result, Range$c)) {
26863
+ if (_instanceof$9(result, Range$c)) {
26862
26864
  result = result.includes(el);
26863
26865
  }
26864
26866
  if (result === true) {
@@ -26960,7 +26962,7 @@ function compareValue(test, value) {
26960
26962
  if (typeof test === "function") {
26961
26963
  return test(value);
26962
26964
  }
26963
- if (_instanceof$a(test, Range$c)) {
26965
+ if (_instanceof$9(test, Range$c)) {
26964
26966
  return test.includes(value);
26965
26967
  }
26966
26968
  return equals(test, value);
@@ -27261,10 +27263,10 @@ function Test(type) {
27261
27263
  if (!fn) {
27262
27264
  return null;
27263
27265
  }
27264
- if (_instanceof$a(fn, FunctionWrapper)) {
27266
+ if (_instanceof$9(fn, FunctionWrapper)) {
27265
27267
  return fn;
27266
27268
  }
27267
- if (_instanceof$a(fn, Range$c)) {
27269
+ if (_instanceof$9(fn, Range$c)) {
27268
27270
  return new FunctionWrapper(function(value) {
27269
27271
  return fn.includes(value);
27270
27272
  }, [
@@ -27373,7 +27375,9 @@ const applyTemplate = (value, context)=>{
27373
27375
  result = template(context);
27374
27376
  if (result.startsWith('EVALUATE:')) {
27375
27377
  const path = result.replace(/^EVALUATE:/, '');
27376
- result = evaluate(path, context);
27378
+ result = evaluate(path, _extends({}, context, {
27379
+ getTime: (time)=>new Date(time).getTime()
27380
+ }));
27377
27381
  }
27378
27382
  } else if (typeof value === 'object' && Array.isArray(value)) {
27379
27383
  result = value.map((item)=>isPinsSettings(item) ? item : applyTemplate(item, context));
@@ -28759,7 +28763,7 @@ function _create_class$3(Constructor, protoProps, staticProps) {
28759
28763
  if (staticProps) _defineProperties$3(Constructor, staticProps);
28760
28764
  return Constructor;
28761
28765
  }
28762
- function _instanceof$9(left, right) {
28766
+ function _instanceof$8(left, right) {
28763
28767
  if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
28764
28768
  return !!right[Symbol.hasInstance](left);
28765
28769
  } else {
@@ -28779,7 +28783,7 @@ var SemVer$f = /*#__PURE__*/ function() {
28779
28783
  function SemVer(version, options) {
28780
28784
  _class_call_check$3(this, SemVer);
28781
28785
  options = parseOptions$2(options);
28782
- if (_instanceof$9(version, SemVer)) {
28786
+ if (_instanceof$8(version, SemVer)) {
28783
28787
  if (version.loose === !!options.loose && version.includePrerelease === !!options.includePrerelease) {
28784
28788
  return version;
28785
28789
  } else {
@@ -28853,7 +28857,7 @@ var SemVer$f = /*#__PURE__*/ function() {
28853
28857
  key: "compare",
28854
28858
  value: function compare(other) {
28855
28859
  debug$2("SemVer.compare", this.version, this.options, other);
28856
- if (!_instanceof$9(other, SemVer)) {
28860
+ if (!_instanceof$8(other, SemVer)) {
28857
28861
  if (typeof other === "string" && other === this.version) {
28858
28862
  return 0;
28859
28863
  }
@@ -28868,7 +28872,7 @@ var SemVer$f = /*#__PURE__*/ function() {
28868
28872
  {
28869
28873
  key: "compareMain",
28870
28874
  value: function compareMain(other) {
28871
- if (!_instanceof$9(other, SemVer)) {
28875
+ if (!_instanceof$8(other, SemVer)) {
28872
28876
  other = new SemVer(other, this.options);
28873
28877
  }
28874
28878
  return compareIdentifiers(this.major, other.major) || compareIdentifiers(this.minor, other.minor) || compareIdentifiers(this.patch, other.patch);
@@ -28877,7 +28881,7 @@ var SemVer$f = /*#__PURE__*/ function() {
28877
28881
  {
28878
28882
  key: "comparePre",
28879
28883
  value: function comparePre(other) {
28880
- if (!_instanceof$9(other, SemVer)) {
28884
+ if (!_instanceof$8(other, SemVer)) {
28881
28885
  other = new SemVer(other, this.options);
28882
28886
  }
28883
28887
  // NOT having a prerelease is > having one
@@ -28910,14 +28914,14 @@ var SemVer$f = /*#__PURE__*/ function() {
28910
28914
  {
28911
28915
  key: "compareBuild",
28912
28916
  value: function compareBuild(other) {
28913
- if (!_instanceof$9(other, SemVer)) {
28917
+ if (!_instanceof$8(other, SemVer)) {
28914
28918
  other = new SemVer(other, this.options);
28915
28919
  }
28916
28920
  var i = 0;
28917
28921
  do {
28918
28922
  var a = this.build[i];
28919
28923
  var b = other.build[i];
28920
- debug$2("prerelease compare", i, a, b);
28924
+ debug$2("build compare", i, a, b);
28921
28925
  if (a === undefined && b === undefined) {
28922
28926
  return 0;
28923
28927
  } else if (b === undefined) {
@@ -29065,7 +29069,7 @@ var SemVer$f = /*#__PURE__*/ function() {
29065
29069
  }();
29066
29070
  var semver$4 = SemVer$f;
29067
29071
 
29068
- function _instanceof$8(left, right) {
29072
+ function _instanceof$7(left, right) {
29069
29073
  if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
29070
29074
  return !!right[Symbol.hasInstance](left);
29071
29075
  } else {
@@ -29075,7 +29079,7 @@ function _instanceof$8(left, right) {
29075
29079
  var SemVer$e = semver$4;
29076
29080
  var parse$6 = function(version, options) {
29077
29081
  var throwErrors = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : false;
29078
- if (_instanceof$8(version, SemVer$e)) {
29082
+ if (_instanceof$7(version, SemVer$e)) {
29079
29083
  return version;
29080
29084
  }
29081
29085
  try {
@@ -29103,7 +29107,7 @@ var clean$1 = function(version, options) {
29103
29107
  };
29104
29108
  var clean_1 = clean$1;
29105
29109
 
29106
- function _instanceof$7(left, right) {
29110
+ function _instanceof$6(left, right) {
29107
29111
  if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
29108
29112
  return !!right[Symbol.hasInstance](left);
29109
29113
  } else {
@@ -29118,7 +29122,7 @@ var inc$1 = function(version, release, options, identifier, identifierBase) {
29118
29122
  options = undefined;
29119
29123
  }
29120
29124
  try {
29121
- return new SemVer$d(_instanceof$7(version, SemVer$d) ? version.version : version, options).inc(release, identifier, identifierBase).version;
29125
+ return new SemVer$d(_instanceof$6(version, SemVer$d) ? version.version : version, options).inc(release, identifier, identifierBase).version;
29122
29126
  } catch (er) {
29123
29127
  return null;
29124
29128
  }
@@ -29323,7 +29327,7 @@ var cmp$2 = function(a, op, b, loose) {
29323
29327
  };
29324
29328
  var cmp_1 = cmp$2;
29325
29329
 
29326
- function _instanceof$6(left, right) {
29330
+ function _instanceof$5(left, right) {
29327
29331
  if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
29328
29332
  return !!right[Symbol.hasInstance](left);
29329
29333
  } else {
@@ -29334,7 +29338,7 @@ var SemVer$7 = semver$4;
29334
29338
  var parse$1 = parse_1;
29335
29339
  var _require$4 = re$4.exports, re$2 = _require$4.safeRe, t$2 = _require$4.t;
29336
29340
  var coerce$1 = function(version, options) {
29337
- if (_instanceof$6(version, SemVer$7)) {
29341
+ if (_instanceof$5(version, SemVer$7)) {
29338
29342
  return version;
29339
29343
  }
29340
29344
  if (typeof version === "number") {
@@ -29380,511 +29384,6 @@ var coerce$1 = function(version, options) {
29380
29384
  };
29381
29385
  var coerce_1 = coerce$1;
29382
29386
 
29383
- function _ts_generator(thisArg, body) {
29384
- var f, y, t, g, _ = {
29385
- label: 0,
29386
- sent: function() {
29387
- if (t[0] & 1) throw t[1];
29388
- return t[1];
29389
- },
29390
- trys: [],
29391
- ops: []
29392
- };
29393
- return g = {
29394
- next: verb(0),
29395
- "throw": verb(1),
29396
- "return": verb(2)
29397
- }, typeof Symbol === "function" && (g[Symbol.iterator] = function() {
29398
- return this;
29399
- }), g;
29400
- function verb(n) {
29401
- return function(v) {
29402
- return step([
29403
- n,
29404
- v
29405
- ]);
29406
- };
29407
- }
29408
- function step(op) {
29409
- if (f) throw new TypeError("Generator is already executing.");
29410
- while(_)try {
29411
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
29412
- if (y = 0, t) op = [
29413
- op[0] & 2,
29414
- t.value
29415
- ];
29416
- switch(op[0]){
29417
- case 0:
29418
- case 1:
29419
- t = op;
29420
- break;
29421
- case 4:
29422
- _.label++;
29423
- return {
29424
- value: op[1],
29425
- done: false
29426
- };
29427
- case 5:
29428
- _.label++;
29429
- y = op[1];
29430
- op = [
29431
- 0
29432
- ];
29433
- continue;
29434
- case 7:
29435
- op = _.ops.pop();
29436
- _.trys.pop();
29437
- continue;
29438
- default:
29439
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) {
29440
- _ = 0;
29441
- continue;
29442
- }
29443
- if (op[0] === 3 && (!t || op[1] > t[0] && op[1] < t[3])) {
29444
- _.label = op[1];
29445
- break;
29446
- }
29447
- if (op[0] === 6 && _.label < t[1]) {
29448
- _.label = t[1];
29449
- t = op;
29450
- break;
29451
- }
29452
- if (t && _.label < t[2]) {
29453
- _.label = t[2];
29454
- _.ops.push(op);
29455
- break;
29456
- }
29457
- if (t[2]) _.ops.pop();
29458
- _.trys.pop();
29459
- continue;
29460
- }
29461
- op = body.call(thisArg, _);
29462
- } catch (e) {
29463
- op = [
29464
- 6,
29465
- e
29466
- ];
29467
- y = 0;
29468
- } finally{
29469
- f = t = 0;
29470
- }
29471
- if (op[0] & 5) throw op[1];
29472
- return {
29473
- value: op[0] ? op[1] : void 0,
29474
- done: true
29475
- };
29476
- }
29477
- }
29478
- var iterator = function(Yallist) {
29479
- Yallist.prototype[Symbol.iterator] = function() {
29480
- var walker;
29481
- return _ts_generator(this, function(_state) {
29482
- switch(_state.label){
29483
- case 0:
29484
- walker = this.head;
29485
- _state.label = 1;
29486
- case 1:
29487
- if (!walker) return [
29488
- 3,
29489
- 4
29490
- ];
29491
- return [
29492
- 4,
29493
- walker.value
29494
- ];
29495
- case 2:
29496
- _state.sent();
29497
- _state.label = 3;
29498
- case 3:
29499
- walker = walker.next;
29500
- return [
29501
- 3,
29502
- 1
29503
- ];
29504
- case 4:
29505
- return [
29506
- 2
29507
- ];
29508
- }
29509
- });
29510
- };
29511
- };
29512
-
29513
- function _instanceof$5(left, right) {
29514
- if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
29515
- return !!right[Symbol.hasInstance](left);
29516
- } else {
29517
- return left instanceof right;
29518
- }
29519
- }
29520
- var yallist = Yallist$1;
29521
- Yallist$1.Node = Node;
29522
- Yallist$1.create = Yallist$1;
29523
- function Yallist$1(list) {
29524
- var self = this;
29525
- if (!_instanceof$5(self, Yallist$1)) {
29526
- self = new Yallist$1();
29527
- }
29528
- self.tail = null;
29529
- self.head = null;
29530
- self.length = 0;
29531
- if (list && typeof list.forEach === "function") {
29532
- list.forEach(function(item) {
29533
- self.push(item);
29534
- });
29535
- } else if (arguments.length > 0) {
29536
- for(var i = 0, l = arguments.length; i < l; i++){
29537
- self.push(arguments[i]);
29538
- }
29539
- }
29540
- return self;
29541
- }
29542
- Yallist$1.prototype.removeNode = function(node) {
29543
- if (node.list !== this) {
29544
- throw new Error("removing node which does not belong to this list");
29545
- }
29546
- var next = node.next;
29547
- var prev = node.prev;
29548
- if (next) {
29549
- next.prev = prev;
29550
- }
29551
- if (prev) {
29552
- prev.next = next;
29553
- }
29554
- if (node === this.head) {
29555
- this.head = next;
29556
- }
29557
- if (node === this.tail) {
29558
- this.tail = prev;
29559
- }
29560
- node.list.length--;
29561
- node.next = null;
29562
- node.prev = null;
29563
- node.list = null;
29564
- return next;
29565
- };
29566
- Yallist$1.prototype.unshiftNode = function(node) {
29567
- if (node === this.head) {
29568
- return;
29569
- }
29570
- if (node.list) {
29571
- node.list.removeNode(node);
29572
- }
29573
- var head = this.head;
29574
- node.list = this;
29575
- node.next = head;
29576
- if (head) {
29577
- head.prev = node;
29578
- }
29579
- this.head = node;
29580
- if (!this.tail) {
29581
- this.tail = node;
29582
- }
29583
- this.length++;
29584
- };
29585
- Yallist$1.prototype.pushNode = function(node) {
29586
- if (node === this.tail) {
29587
- return;
29588
- }
29589
- if (node.list) {
29590
- node.list.removeNode(node);
29591
- }
29592
- var tail = this.tail;
29593
- node.list = this;
29594
- node.prev = tail;
29595
- if (tail) {
29596
- tail.next = node;
29597
- }
29598
- this.tail = node;
29599
- if (!this.head) {
29600
- this.head = node;
29601
- }
29602
- this.length++;
29603
- };
29604
- Yallist$1.prototype.push = function() {
29605
- for(var i = 0, l = arguments.length; i < l; i++){
29606
- push(this, arguments[i]);
29607
- }
29608
- return this.length;
29609
- };
29610
- Yallist$1.prototype.unshift = function() {
29611
- for(var i = 0, l = arguments.length; i < l; i++){
29612
- unshift(this, arguments[i]);
29613
- }
29614
- return this.length;
29615
- };
29616
- Yallist$1.prototype.pop = function() {
29617
- if (!this.tail) {
29618
- return undefined;
29619
- }
29620
- var res = this.tail.value;
29621
- this.tail = this.tail.prev;
29622
- if (this.tail) {
29623
- this.tail.next = null;
29624
- } else {
29625
- this.head = null;
29626
- }
29627
- this.length--;
29628
- return res;
29629
- };
29630
- Yallist$1.prototype.shift = function() {
29631
- if (!this.head) {
29632
- return undefined;
29633
- }
29634
- var res = this.head.value;
29635
- this.head = this.head.next;
29636
- if (this.head) {
29637
- this.head.prev = null;
29638
- } else {
29639
- this.tail = null;
29640
- }
29641
- this.length--;
29642
- return res;
29643
- };
29644
- Yallist$1.prototype.forEach = function(fn, thisp) {
29645
- thisp = thisp || this;
29646
- for(var walker = this.head, i = 0; walker !== null; i++){
29647
- fn.call(thisp, walker.value, i, this);
29648
- walker = walker.next;
29649
- }
29650
- };
29651
- Yallist$1.prototype.forEachReverse = function(fn, thisp) {
29652
- thisp = thisp || this;
29653
- for(var walker = this.tail, i = this.length - 1; walker !== null; i--){
29654
- fn.call(thisp, walker.value, i, this);
29655
- walker = walker.prev;
29656
- }
29657
- };
29658
- Yallist$1.prototype.get = function(n) {
29659
- for(var i = 0, walker = this.head; walker !== null && i < n; i++){
29660
- // abort out of the list early if we hit a cycle
29661
- walker = walker.next;
29662
- }
29663
- if (i === n && walker !== null) {
29664
- return walker.value;
29665
- }
29666
- };
29667
- Yallist$1.prototype.getReverse = function(n) {
29668
- for(var i = 0, walker = this.tail; walker !== null && i < n; i++){
29669
- // abort out of the list early if we hit a cycle
29670
- walker = walker.prev;
29671
- }
29672
- if (i === n && walker !== null) {
29673
- return walker.value;
29674
- }
29675
- };
29676
- Yallist$1.prototype.map = function(fn, thisp) {
29677
- thisp = thisp || this;
29678
- var res = new Yallist$1();
29679
- for(var walker = this.head; walker !== null;){
29680
- res.push(fn.call(thisp, walker.value, this));
29681
- walker = walker.next;
29682
- }
29683
- return res;
29684
- };
29685
- Yallist$1.prototype.mapReverse = function(fn, thisp) {
29686
- thisp = thisp || this;
29687
- var res = new Yallist$1();
29688
- for(var walker = this.tail; walker !== null;){
29689
- res.push(fn.call(thisp, walker.value, this));
29690
- walker = walker.prev;
29691
- }
29692
- return res;
29693
- };
29694
- Yallist$1.prototype.reduce = function(fn, initial) {
29695
- var acc;
29696
- var walker = this.head;
29697
- if (arguments.length > 1) {
29698
- acc = initial;
29699
- } else if (this.head) {
29700
- walker = this.head.next;
29701
- acc = this.head.value;
29702
- } else {
29703
- throw new TypeError("Reduce of empty list with no initial value");
29704
- }
29705
- for(var i = 0; walker !== null; i++){
29706
- acc = fn(acc, walker.value, i);
29707
- walker = walker.next;
29708
- }
29709
- return acc;
29710
- };
29711
- Yallist$1.prototype.reduceReverse = function(fn, initial) {
29712
- var acc;
29713
- var walker = this.tail;
29714
- if (arguments.length > 1) {
29715
- acc = initial;
29716
- } else if (this.tail) {
29717
- walker = this.tail.prev;
29718
- acc = this.tail.value;
29719
- } else {
29720
- throw new TypeError("Reduce of empty list with no initial value");
29721
- }
29722
- for(var i = this.length - 1; walker !== null; i--){
29723
- acc = fn(acc, walker.value, i);
29724
- walker = walker.prev;
29725
- }
29726
- return acc;
29727
- };
29728
- Yallist$1.prototype.toArray = function() {
29729
- var arr = new Array(this.length);
29730
- for(var i = 0, walker = this.head; walker !== null; i++){
29731
- arr[i] = walker.value;
29732
- walker = walker.next;
29733
- }
29734
- return arr;
29735
- };
29736
- Yallist$1.prototype.toArrayReverse = function() {
29737
- var arr = new Array(this.length);
29738
- for(var i = 0, walker = this.tail; walker !== null; i++){
29739
- arr[i] = walker.value;
29740
- walker = walker.prev;
29741
- }
29742
- return arr;
29743
- };
29744
- Yallist$1.prototype.slice = function(from, to) {
29745
- to = to || this.length;
29746
- if (to < 0) {
29747
- to += this.length;
29748
- }
29749
- from = from || 0;
29750
- if (from < 0) {
29751
- from += this.length;
29752
- }
29753
- var ret = new Yallist$1();
29754
- if (to < from || to < 0) {
29755
- return ret;
29756
- }
29757
- if (from < 0) {
29758
- from = 0;
29759
- }
29760
- if (to > this.length) {
29761
- to = this.length;
29762
- }
29763
- for(var i = 0, walker = this.head; walker !== null && i < from; i++){
29764
- walker = walker.next;
29765
- }
29766
- for(; walker !== null && i < to; i++, walker = walker.next){
29767
- ret.push(walker.value);
29768
- }
29769
- return ret;
29770
- };
29771
- Yallist$1.prototype.sliceReverse = function(from, to) {
29772
- to = to || this.length;
29773
- if (to < 0) {
29774
- to += this.length;
29775
- }
29776
- from = from || 0;
29777
- if (from < 0) {
29778
- from += this.length;
29779
- }
29780
- var ret = new Yallist$1();
29781
- if (to < from || to < 0) {
29782
- return ret;
29783
- }
29784
- if (from < 0) {
29785
- from = 0;
29786
- }
29787
- if (to > this.length) {
29788
- to = this.length;
29789
- }
29790
- for(var i = this.length, walker = this.tail; walker !== null && i > to; i--){
29791
- walker = walker.prev;
29792
- }
29793
- for(; walker !== null && i > from; i--, walker = walker.prev){
29794
- ret.push(walker.value);
29795
- }
29796
- return ret;
29797
- };
29798
- Yallist$1.prototype.splice = function(start, deleteCount) {
29799
- for(var _len = arguments.length, nodes = new Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++){
29800
- nodes[_key - 2] = arguments[_key];
29801
- }
29802
- if (start > this.length) {
29803
- start = this.length - 1;
29804
- }
29805
- if (start < 0) {
29806
- start = this.length + start;
29807
- }
29808
- for(var i = 0, walker = this.head; walker !== null && i < start; i++){
29809
- walker = walker.next;
29810
- }
29811
- var ret = [];
29812
- for(var i = 0; walker && i < deleteCount; i++){
29813
- ret.push(walker.value);
29814
- walker = this.removeNode(walker);
29815
- }
29816
- if (walker === null) {
29817
- walker = this.tail;
29818
- }
29819
- if (walker !== this.head && walker !== this.tail) {
29820
- walker = walker.prev;
29821
- }
29822
- for(var i = 0; i < nodes.length; i++){
29823
- walker = insert(this, walker, nodes[i]);
29824
- }
29825
- return ret;
29826
- };
29827
- Yallist$1.prototype.reverse = function() {
29828
- var head = this.head;
29829
- var tail = this.tail;
29830
- for(var walker = head; walker !== null; walker = walker.prev){
29831
- var p = walker.prev;
29832
- walker.prev = walker.next;
29833
- walker.next = p;
29834
- }
29835
- this.head = tail;
29836
- this.tail = head;
29837
- return this;
29838
- };
29839
- function insert(self, node, value) {
29840
- var inserted = node === self.head ? new Node(value, null, node, self) : new Node(value, node, node.next, self);
29841
- if (inserted.next === null) {
29842
- self.tail = inserted;
29843
- }
29844
- if (inserted.prev === null) {
29845
- self.head = inserted;
29846
- }
29847
- self.length++;
29848
- return inserted;
29849
- }
29850
- function push(self, item) {
29851
- self.tail = new Node(item, self.tail, null, self);
29852
- if (!self.head) {
29853
- self.head = self.tail;
29854
- }
29855
- self.length++;
29856
- }
29857
- function unshift(self, item) {
29858
- self.head = new Node(item, null, self.head, self);
29859
- if (!self.tail) {
29860
- self.tail = self.head;
29861
- }
29862
- self.length++;
29863
- }
29864
- function Node(value, prev, next, list) {
29865
- if (!_instanceof$5(this, Node)) {
29866
- return new Node(value, prev, next, list);
29867
- }
29868
- this.list = list;
29869
- this.value = value;
29870
- if (prev) {
29871
- prev.next = this;
29872
- this.prev = prev;
29873
- } else {
29874
- this.prev = null;
29875
- }
29876
- if (next) {
29877
- next.prev = this;
29878
- this.next = next;
29879
- } else {
29880
- this.next = null;
29881
- }
29882
- }
29883
- try {
29884
- // add if support for Symbol.iterator is present
29885
- iterator(Yallist$1);
29886
- } catch (er) {}
29887
-
29888
29387
  function _class_call_check$2(instance, Constructor) {
29889
29388
  if (!(instance instanceof Constructor)) {
29890
29389
  throw new TypeError("Cannot call a class as a function");
@@ -29904,361 +29403,53 @@ function _create_class$2(Constructor, protoProps, staticProps) {
29904
29403
  if (staticProps) _defineProperties$2(Constructor, staticProps);
29905
29404
  return Constructor;
29906
29405
  }
29907
- // A linked list to keep track of recently-used-ness
29908
- var Yallist = yallist;
29909
- var MAX = Symbol("max");
29910
- var LENGTH = Symbol("length");
29911
- var LENGTH_CALCULATOR = Symbol("lengthCalculator");
29912
- var ALLOW_STALE = Symbol("allowStale");
29913
- var MAX_AGE = Symbol("maxAge");
29914
- var DISPOSE = Symbol("dispose");
29915
- var NO_DISPOSE_ON_SET = Symbol("noDisposeOnSet");
29916
- var LRU_LIST = Symbol("lruList");
29917
- var CACHE = Symbol("cache");
29918
- var UPDATE_AGE_ON_GET = Symbol("updateAgeOnGet");
29919
- var naiveLength = function() {
29920
- return 1;
29921
- };
29922
- // lruList is a yallist where the head is the youngest
29923
- // item, and the tail is the oldest. the list contains the Hit
29924
- // objects as the entries.
29925
- // Each Hit object has a reference to its Yallist.Node. This
29926
- // never changes.
29927
- //
29928
- // cache is a Map (or PseudoMap) that matches the keys to
29929
- // the Yallist.Node object.
29930
29406
  var LRUCache = /*#__PURE__*/ function() {
29931
- function LRUCache(options) {
29407
+ function LRUCache() {
29932
29408
  _class_call_check$2(this, LRUCache);
29933
- if (typeof options === "number") options = {
29934
- max: options
29935
- };
29936
- if (!options) options = {};
29937
- if (options.max && (typeof options.max !== "number" || options.max < 0)) throw new TypeError("max must be a non-negative number");
29938
- // Kind of weird to have a default max of Infinity, but oh well.
29939
- this[MAX] = options.max || Infinity;
29940
- var lc = options.length || naiveLength;
29941
- this[LENGTH_CALCULATOR] = typeof lc !== "function" ? naiveLength : lc;
29942
- this[ALLOW_STALE] = options.stale || false;
29943
- if (options.maxAge && typeof options.maxAge !== "number") throw new TypeError("maxAge must be a number");
29944
- this[MAX_AGE] = options.maxAge || 0;
29945
- this[DISPOSE] = options.dispose;
29946
- this[NO_DISPOSE_ON_SET] = options.noDisposeOnSet || false;
29947
- this[UPDATE_AGE_ON_GET] = options.updateAgeOnGet || false;
29948
- this.reset();
29409
+ this.max = 1000;
29410
+ this.map = new Map();
29949
29411
  }
29950
29412
  _create_class$2(LRUCache, [
29951
29413
  {
29952
- key: "max",
29953
- get: function get() {
29954
- return this[MAX];
29955
- },
29956
- set: // resize the cache when the max changes.
29957
- function set(mL) {
29958
- if (typeof mL !== "number" || mL < 0) throw new TypeError("max must be a non-negative number");
29959
- this[MAX] = mL || Infinity;
29960
- trim(this);
29961
- }
29962
- },
29963
- {
29964
- key: "allowStale",
29965
- get: function get() {
29966
- return this[ALLOW_STALE];
29967
- },
29968
- set: function set(allowStale) {
29969
- this[ALLOW_STALE] = !!allowStale;
29970
- }
29971
- },
29972
- {
29973
- key: "maxAge",
29974
- get: function get() {
29975
- return this[MAX_AGE];
29976
- },
29977
- set: function set(mA) {
29978
- if (typeof mA !== "number") throw new TypeError("maxAge must be a non-negative number");
29979
- this[MAX_AGE] = mA;
29980
- trim(this);
29981
- }
29982
- },
29983
- {
29984
- key: "lengthCalculator",
29985
- get: function get() {
29986
- return this[LENGTH_CALCULATOR];
29987
- },
29988
- set: // resize the cache when the lengthCalculator changes.
29989
- function set(lC) {
29990
- var _this = this;
29991
- if (typeof lC !== "function") lC = naiveLength;
29992
- if (lC !== this[LENGTH_CALCULATOR]) {
29993
- this[LENGTH_CALCULATOR] = lC;
29994
- this[LENGTH] = 0;
29995
- this[LRU_LIST].forEach(function(hit) {
29996
- hit.length = _this[LENGTH_CALCULATOR](hit.value, hit.key);
29997
- _this[LENGTH] += hit.length;
29998
- });
29999
- }
30000
- trim(this);
30001
- }
30002
- },
30003
- {
30004
- key: "length",
30005
- get: function get() {
30006
- return this[LENGTH];
30007
- }
30008
- },
30009
- {
30010
- key: "itemCount",
30011
- get: function get() {
30012
- return this[LRU_LIST].length;
30013
- }
30014
- },
30015
- {
30016
- key: "rforEach",
30017
- value: function rforEach(fn, thisp) {
30018
- thisp = thisp || this;
30019
- for(var walker = this[LRU_LIST].tail; walker !== null;){
30020
- var prev = walker.prev;
30021
- forEachStep(this, fn, walker, thisp);
30022
- walker = prev;
30023
- }
30024
- }
30025
- },
30026
- {
30027
- key: "forEach",
30028
- value: function forEach(fn, thisp) {
30029
- thisp = thisp || this;
30030
- for(var walker = this[LRU_LIST].head; walker !== null;){
30031
- var next = walker.next;
30032
- forEachStep(this, fn, walker, thisp);
30033
- walker = next;
30034
- }
30035
- }
30036
- },
30037
- {
30038
- key: "keys",
30039
- value: function keys() {
30040
- return this[LRU_LIST].toArray().map(function(k) {
30041
- return k.key;
30042
- });
30043
- }
30044
- },
30045
- {
30046
- key: "values",
30047
- value: function values() {
30048
- return this[LRU_LIST].toArray().map(function(k) {
30049
- return k.value;
30050
- });
30051
- }
30052
- },
30053
- {
30054
- key: "reset",
30055
- value: function reset() {
30056
- var _this = this;
30057
- if (this[DISPOSE] && this[LRU_LIST] && this[LRU_LIST].length) {
30058
- this[LRU_LIST].forEach(function(hit) {
30059
- return _this[DISPOSE](hit.key, hit.value);
30060
- });
29414
+ key: "get",
29415
+ value: function get(key) {
29416
+ var value = this.map.get(key);
29417
+ if (value === undefined) {
29418
+ return undefined;
29419
+ } else {
29420
+ // Remove the key from the map and add it to the end
29421
+ this.map.delete(key);
29422
+ this.map.set(key, value);
29423
+ return value;
30061
29424
  }
30062
- this[CACHE] = new Map() // hash of items by key
30063
- ;
30064
- this[LRU_LIST] = new Yallist() // list of items in order of use recency
30065
- ;
30066
- this[LENGTH] = 0 // length of items in the list
30067
- ;
30068
- }
30069
- },
30070
- {
30071
- key: "dump",
30072
- value: function dump() {
30073
- var _this = this;
30074
- return this[LRU_LIST].map(function(hit) {
30075
- return isStale(_this, hit) ? false : {
30076
- k: hit.key,
30077
- v: hit.value,
30078
- e: hit.now + (hit.maxAge || 0)
30079
- };
30080
- }).toArray().filter(function(h) {
30081
- return h;
30082
- });
30083
29425
  }
30084
29426
  },
30085
29427
  {
30086
- key: "dumpLru",
30087
- value: function dumpLru() {
30088
- return this[LRU_LIST];
29428
+ key: "delete",
29429
+ value: function _delete(key) {
29430
+ return this.map.delete(key);
30089
29431
  }
30090
29432
  },
30091
29433
  {
30092
29434
  key: "set",
30093
- value: function set(key, value, maxAge) {
30094
- maxAge = maxAge || this[MAX_AGE];
30095
- if (maxAge && typeof maxAge !== "number") throw new TypeError("maxAge must be a number");
30096
- var now = maxAge ? Date.now() : 0;
30097
- var len = this[LENGTH_CALCULATOR](value, key);
30098
- if (this[CACHE].has(key)) {
30099
- if (len > this[MAX]) {
30100
- del(this, this[CACHE].get(key));
30101
- return false;
30102
- }
30103
- var node = this[CACHE].get(key);
30104
- var item = node.value;
30105
- // dispose of the old one before overwriting
30106
- // split out into 2 ifs for better coverage tracking
30107
- if (this[DISPOSE]) {
30108
- if (!this[NO_DISPOSE_ON_SET]) this[DISPOSE](key, item.value);
30109
- }
30110
- item.now = now;
30111
- item.maxAge = maxAge;
30112
- item.value = value;
30113
- this[LENGTH] += len - item.length;
30114
- item.length = len;
30115
- this.get(key);
30116
- trim(this);
30117
- return true;
30118
- }
30119
- var hit = new Entry(key, value, len, now, maxAge);
30120
- // oversized objects fall out of cache automatically.
30121
- if (hit.length > this[MAX]) {
30122
- if (this[DISPOSE]) this[DISPOSE](key, value);
30123
- return false;
30124
- }
30125
- this[LENGTH] += hit.length;
30126
- this[LRU_LIST].unshift(hit);
30127
- this[CACHE].set(key, this[LRU_LIST].head);
30128
- trim(this);
30129
- return true;
30130
- }
30131
- },
30132
- {
30133
- key: "has",
30134
- value: function has(key) {
30135
- if (!this[CACHE].has(key)) return false;
30136
- var hit = this[CACHE].get(key).value;
30137
- return !isStale(this, hit);
30138
- }
30139
- },
30140
- {
30141
- key: "get",
30142
- value: function get1(key) {
30143
- return get(this, key, true);
30144
- }
30145
- },
30146
- {
30147
- key: "peek",
30148
- value: function peek(key) {
30149
- return get(this, key, false);
30150
- }
30151
- },
30152
- {
30153
- key: "pop",
30154
- value: function pop() {
30155
- var node = this[LRU_LIST].tail;
30156
- if (!node) return null;
30157
- del(this, node);
30158
- return node.value;
30159
- }
30160
- },
30161
- {
30162
- key: "del",
30163
- value: function del1(key) {
30164
- del(this, this[CACHE].get(key));
30165
- }
30166
- },
30167
- {
30168
- key: "load",
30169
- value: function load(arr) {
30170
- // reset the cache
30171
- this.reset();
30172
- var now = Date.now();
30173
- // A previous serialized cache has the most recent items first
30174
- for(var l = arr.length - 1; l >= 0; l--){
30175
- var hit = arr[l];
30176
- var expiresAt = hit.e || 0;
30177
- if (expiresAt === 0) // the item was created without expiration in a non aged cache
30178
- this.set(hit.k, hit.v);
30179
- else {
30180
- var maxAge = expiresAt - now;
30181
- // dont add already expired items
30182
- if (maxAge > 0) {
30183
- this.set(hit.k, hit.v, maxAge);
30184
- }
29435
+ value: function set(key, value) {
29436
+ var deleted = this.delete(key);
29437
+ if (!deleted && value !== undefined) {
29438
+ // If cache is full, delete the least recently used item
29439
+ if (this.map.size >= this.max) {
29440
+ var firstKey = this.map.keys().next().value;
29441
+ this.delete(firstKey);
30185
29442
  }
29443
+ this.map.set(key, value);
30186
29444
  }
30187
- }
30188
- },
30189
- {
30190
- key: "prune",
30191
- value: function prune() {
30192
- var _this = this;
30193
- this[CACHE].forEach(function(value, key) {
30194
- return get(_this, key, false);
30195
- });
29445
+ return this;
30196
29446
  }
30197
29447
  }
30198
29448
  ]);
30199
29449
  return LRUCache;
30200
29450
  }();
30201
- var get = function(self, key, doUse) {
30202
- var node = self[CACHE].get(key);
30203
- if (node) {
30204
- var hit = node.value;
30205
- if (isStale(self, hit)) {
30206
- del(self, node);
30207
- if (!self[ALLOW_STALE]) return undefined;
30208
- } else {
30209
- if (doUse) {
30210
- if (self[UPDATE_AGE_ON_GET]) node.value.now = Date.now();
30211
- self[LRU_LIST].unshiftNode(node);
30212
- }
30213
- }
30214
- return hit.value;
30215
- }
30216
- };
30217
- var isStale = function(self, hit) {
30218
- if (!hit || !hit.maxAge && !self[MAX_AGE]) return false;
30219
- var diff = Date.now() - hit.now;
30220
- return hit.maxAge ? diff > hit.maxAge : self[MAX_AGE] && diff > self[MAX_AGE];
30221
- };
30222
- var trim = function(self) {
30223
- if (self[LENGTH] > self[MAX]) {
30224
- for(var walker = self[LRU_LIST].tail; self[LENGTH] > self[MAX] && walker !== null;){
30225
- // We know that we're about to delete this one, and also
30226
- // what the next least recently used key will be, so just
30227
- // go ahead and set it now.
30228
- var prev = walker.prev;
30229
- del(self, walker);
30230
- walker = prev;
30231
- }
30232
- }
30233
- };
30234
- var del = function(self, node) {
30235
- if (node) {
30236
- var hit = node.value;
30237
- if (self[DISPOSE]) self[DISPOSE](hit.key, hit.value);
30238
- self[LENGTH] -= hit.length;
30239
- self[CACHE].delete(hit.key);
30240
- self[LRU_LIST].removeNode(node);
30241
- }
30242
- };
30243
- var Entry = function Entry(key, value, length, now, maxAge) {
30244
- _class_call_check$2(this, Entry);
30245
- this.key = key;
30246
- this.value = value;
30247
- this.length = length;
30248
- this.now = now;
30249
- this.maxAge = maxAge || 0;
30250
- };
30251
- var forEachStep = function(self, fn, node, thisp) {
30252
- var hit = node.value;
30253
- if (isStale(self, hit)) {
30254
- del(self, node);
30255
- if (!self[ALLOW_STALE]) hit = undefined;
30256
- }
30257
- if (hit) fn.call(thisp, hit.value, hit.key, self);
30258
- };
30259
- var lruCache = LRUCache;
29451
+ var lrucache = LRUCache;
30260
29452
 
30261
- // hoisted class for cyclic dependency
30262
29453
  function _array_like_to_array$1(arr, len) {
30263
29454
  if (len == null || len > arr.length) len = arr.length;
30264
29455
  for(var i = 0, arr2 = new Array(len); i < len; i++)arr2[i] = arr[i];
@@ -30310,6 +29501,8 @@ function _unsupported_iterable_to_array$1(o, minLen) {
30310
29501
  if (n === "Map" || n === "Set") return Array.from(n);
30311
29502
  if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array$1(o, minLen);
30312
29503
  }
29504
+ var SPACE_CHARACTERS = /\s+/g;
29505
+ // hoisted class for cyclic dependency
30313
29506
  var Range$b = /*#__PURE__*/ function() {
30314
29507
  function Range(range, options) {
30315
29508
  var _this = this;
@@ -30330,7 +29523,7 @@ var Range$b = /*#__PURE__*/ function() {
30330
29523
  range
30331
29524
  ]
30332
29525
  ];
30333
- this.format();
29526
+ this.formatted = undefined;
30334
29527
  return this;
30335
29528
  }
30336
29529
  this.options = options;
@@ -30339,7 +29532,7 @@ var Range$b = /*#__PURE__*/ function() {
30339
29532
  // First reduce all whitespace as much as possible so we do not have to rely
30340
29533
  // on potentially slow regexes like \s*. This is then stored and used for
30341
29534
  // future error messages as well.
30342
- this.raw = range.trim().split(/\s+/).join(" ");
29535
+ this.raw = range.trim().replace(SPACE_CHARACTERS, " ");
30343
29536
  // First, split on ||
30344
29537
  this.set = this.raw.split("||")// map the range to a 2d array of comparators
30345
29538
  .map(function(r) {
@@ -30393,15 +29586,33 @@ var Range$b = /*#__PURE__*/ function() {
30393
29586
  }
30394
29587
  }
30395
29588
  }
30396
- this.format();
29589
+ this.formatted = undefined;
30397
29590
  }
30398
29591
  _create_class$1(Range, [
29592
+ {
29593
+ key: "range",
29594
+ get: function get() {
29595
+ if (this.formatted === undefined) {
29596
+ this.formatted = "";
29597
+ for(var i = 0; i < this.set.length; i++){
29598
+ if (i > 0) {
29599
+ this.formatted += "||";
29600
+ }
29601
+ var comps = this.set[i];
29602
+ for(var k = 0; k < comps.length; k++){
29603
+ if (k > 0) {
29604
+ this.formatted += " ";
29605
+ }
29606
+ this.formatted += comps[k].toString().trim();
29607
+ }
29608
+ }
29609
+ }
29610
+ return this.formatted;
29611
+ }
29612
+ },
30399
29613
  {
30400
29614
  key: "format",
30401
29615
  value: function format() {
30402
- this.range = this.set.map(function(comps) {
30403
- return comps.join(" ").trim();
30404
- }).join("||").trim();
30405
29616
  return this.range;
30406
29617
  }
30407
29618
  },
@@ -30536,10 +29747,8 @@ var Range$b = /*#__PURE__*/ function() {
30536
29747
  return Range;
30537
29748
  }();
30538
29749
  var range = Range$b;
30539
- var LRU = lruCache;
30540
- var cache = new LRU({
30541
- max: 1000
30542
- });
29750
+ var LRU = lrucache;
29751
+ var cache = new LRU();
30543
29752
  var parseOptions$1 = parseOptions_1;
30544
29753
  var Comparator$4 = comparator;
30545
29754
  var debug$1 = debug_1;
@@ -30763,8 +29972,9 @@ var replaceGTE0 = function(comp, options) {
30763
29972
  // 1.2 - 3.4.5 => >=1.2.0 <=3.4.5
30764
29973
  // 1.2.3 - 3.4 => >=1.2.0 <3.5.0-0 Any 3.4.x will do
30765
29974
  // 1.2 - 3.4 => >=1.2.0 <3.5.0-0
29975
+ // TODO build?
30766
29976
  var hyphenReplace = function(incPr) {
30767
- return function($0, from, fM, fm, fp, fpr, fb, to, tM, tm, tp, tpr, tb) {
29977
+ return function($0, from, fM, fm, fp, fpr, fb, to, tM, tm, tp, tpr) {
30768
29978
  if (isX(fM)) {
30769
29979
  from = "";
30770
29980
  } else if (isX(fm)) {