@hpcc-js/ddl-shim 2.17.21 → 2.17.23

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.es6.js CHANGED
@@ -1,21 +1,6 @@
1
- function _mergeNamespaces(n, m) {
2
- m.forEach(function (e) {
3
- e && typeof e !== 'string' && !Array.isArray(e) && Object.keys(e).forEach(function (k) {
4
- if (k !== 'default' && !(k in n)) {
5
- var d = Object.getOwnPropertyDescriptor(e, k);
6
- Object.defineProperty(n, k, d.get ? d : {
7
- enumerable: true,
8
- get: function () { return e[k]; }
9
- });
10
- }
11
- });
12
- });
13
- return Object.freeze(n);
14
- }
15
-
16
1
  var PKG_NAME = "@hpcc-js/ddl-shim";
17
- var PKG_VERSION = "2.17.21";
18
- var BUILD_VERSION = "2.97.0";
2
+ var PKG_VERSION = "2.17.23";
3
+ var BUILD_VERSION = "2.99.0";
19
4
 
20
5
  function isWorkunitDatasource(ref) {
21
6
  return ref.WUID !== undefined;
@@ -110,7 +95,7 @@ function isLimitActivity(activity) {
110
95
  }
111
96
  var VisibilitySet = ["normal", "flyout"];
112
97
 
113
- var v2$1 = /*#__PURE__*/Object.freeze({
98
+ var v2 = /*#__PURE__*/Object.freeze({
114
99
  __proto__: null,
115
100
  isDatabombRef: isDatabombRef,
116
101
  isWUResultRef: isWUResultRef,
@@ -158,7 +143,7 @@ function __spreadArray(to, from, pack) {
158
143
  ar[i] = from[i];
159
144
  }
160
145
  }
161
- return to.concat(ar || Array.prototype.slice.call(from));
146
+ return to.concat(ar || from);
162
147
  }
163
148
 
164
149
  var classMappings = {
@@ -374,7 +359,7 @@ function apply_to_properties_layout(ddl2, dermObj) {
374
359
  });
375
360
  return retVal;
376
361
  }
377
- function upgrade$1(ddl2, dermObj) {
362
+ function upgrade(ddl2, dermObj) {
378
363
  apply_to_dataviews(ddl2, dermObj);
379
364
  return apply_to_properties_layout(ddl2, dermObj);
380
365
  }
@@ -594,7 +579,7 @@ var DDLUpgrade = /** @class */ (function () {
594
579
  break;
595
580
  default:
596
581
  groupByColumns.push(this.toLowerCase(field.id));
597
- throw new Error("Unhandled field function: ".concat(field.properties.function));
582
+ throw new Error("Unhandled field function: " + field.properties.function);
598
583
  }
599
584
  }
600
585
  else {
@@ -605,7 +590,7 @@ var DDLUpgrade = /** @class */ (function () {
605
590
  this._ddl2DataviewActivities[viz.id].project.transformations = projectTransformations;
606
591
  }
607
592
  if (aggrFields.length) {
608
- this._ddl2DataviewActivities[viz.id].groupBy.groupByIDs = __spreadArray([], groupByColumns, true);
593
+ this._ddl2DataviewActivities[viz.id].groupBy.groupByIDs = __spreadArray([], groupByColumns);
609
594
  this._ddl2DataviewActivities[viz.id].groupBy.aggregates = aggrFields;
610
595
  }
611
596
  }
@@ -623,7 +608,7 @@ var DDLUpgrade = /** @class */ (function () {
623
608
  case "MAX":
624
609
  return "max";
625
610
  }
626
- throw new Error("Unknown DDL1 Function Type: ".concat(func));
611
+ throw new Error("Unknown DDL1 Function Type: " + func);
627
612
  };
628
613
  DDLUpgrade.prototype.readMappings = function () {
629
614
  for (var _i = 0, _a = this._ddl.dashboards; _i < _a.length; _i++) {
@@ -650,7 +635,7 @@ var DDLUpgrade = /** @class */ (function () {
650
635
  this.readSliderMappings(viz);
651
636
  }
652
637
  else {
653
- throw new Error("Unkown DDL1 mapping type: ".concat(viz.type));
638
+ throw new Error("Unkown DDL1 mapping type: " + viz.type);
654
639
  }
655
640
  }
656
641
  }
@@ -765,7 +750,7 @@ var DDLUpgrade = /** @class */ (function () {
765
750
  var flag = _a[_i];
766
751
  if (flag.fieldid) {
767
752
  mappings.transformations.push({
768
- fieldID: "annotation_".concat(idx++),
753
+ fieldID: "annotation_" + idx++,
769
754
  type: "map",
770
755
  sourceFieldID: this.toLowerCase(flag.fieldid),
771
756
  default: {},
@@ -824,7 +809,7 @@ var DDLUpgrade = /** @class */ (function () {
824
809
  var mapping = update.mappings[key];
825
810
  var dsFilter = (mapping && dsFilters[mapping]) ? dsFilters[mapping].filter : undefined;
826
811
  if (!dsFilter) {
827
- console.warn("Select Mapping \"".concat(mapping, "\" in viz \"").concat(viz.id, "\" not found in filters for \"").concat(otherViz.id, "\""));
812
+ console.warn("Select Mapping \"" + mapping + "\" in viz \"" + viz.id + "\" not found in filters for \"" + otherViz.id + "\"");
828
813
  }
829
814
  else {
830
815
  condition.mappings.push({
@@ -1075,24 +1060,43 @@ var DDLUpgrade = /** @class */ (function () {
1075
1060
  };
1076
1061
  return DDLUpgrade;
1077
1062
  }());
1078
- function upgrade(ddl, baseUrl, wuid, toLowerCase, dermatologyJson) {
1063
+ function upgrade$1(ddl, baseUrl, wuid, toLowerCase, dermatologyJson) {
1079
1064
  if (toLowerCase === void 0) { toLowerCase = true; }
1080
1065
  if (dermatologyJson === void 0) { dermatologyJson = {}; }
1081
1066
  var ddlUp = new DDLUpgrade(ddl, baseUrl, wuid, toLowerCase);
1082
1067
  var retVal = ddlUp.write();
1083
- retVal.properties = upgrade$1(retVal, dermatologyJson);
1068
+ retVal.properties = upgrade(retVal, dermatologyJson);
1084
1069
  return retVal;
1085
1070
  }
1086
1071
 
1087
1072
  var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
1088
1073
 
1089
- var uri_all = {exports: {}};
1074
+ function unwrapExports (x) {
1075
+ return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
1076
+ }
1090
1077
 
1091
- /** @license URI.js v4.4.1 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js */
1078
+ function createCommonjsModule(fn, basedir, module) {
1079
+ return module = {
1080
+ path: basedir,
1081
+ exports: {},
1082
+ require: function (path, base) {
1083
+ return commonjsRequire(path, (base === undefined || base === null) ? module.path : base);
1084
+ }
1085
+ }, fn(module, module.exports), module.exports;
1086
+ }
1092
1087
 
1093
- (function (module, exports) {
1088
+ function getCjsExportFromNamespace (n) {
1089
+ return n && n['default'] || n;
1090
+ }
1091
+
1092
+ function commonjsRequire () {
1093
+ throw new Error('Dynamic requires are not currently supported by @rollup/plugin-commonjs');
1094
+ }
1095
+
1096
+ var uri_all = createCommonjsModule(function (module, exports) {
1097
+ /** @license URI.js v4.4.1 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js */
1094
1098
  (function (global, factory) {
1095
- factory(exports) ;
1099
+ factory(exports) ;
1096
1100
  }(commonjsGlobal, (function (exports) {
1097
1101
  function merge() {
1098
1102
  for (var _len = arguments.length, sets = Array(_len), _key = 0; _key < _len; _key++) {
@@ -1146,10 +1150,10 @@ function buildExps(isIRI) {
1146
1150
  //subset, excludes bidi control characters
1147
1151
  IPRIVATE$$ = isIRI ? "[\\uE000-\\uF8FF]" : "[]",
1148
1152
  //subset
1149
- UNRESERVED$$ = merge(ALPHA$$, DIGIT$$, "[\\-\\.\\_\\~]", UCSCHAR$$);
1150
- subexp(ALPHA$$ + merge(ALPHA$$, DIGIT$$, "[\\+\\-\\.]") + "*");
1151
- subexp(subexp(PCT_ENCODED$ + "|" + merge(UNRESERVED$$, SUB_DELIMS$$, "[\\:]")) + "*");
1152
- var DEC_OCTET_RELAXED$ = subexp(subexp("25[0-5]") + "|" + subexp("2[0-4]" + DIGIT$$) + "|" + subexp("1" + DIGIT$$ + DIGIT$$) + "|" + subexp("0?[1-9]" + DIGIT$$) + "|0?0?" + DIGIT$$),
1153
+ UNRESERVED$$ = merge(ALPHA$$, DIGIT$$, "[\\-\\.\\_\\~]", UCSCHAR$$),
1154
+ SCHEME$ = subexp(ALPHA$$ + merge(ALPHA$$, DIGIT$$, "[\\+\\-\\.]") + "*"),
1155
+ USERINFO$ = subexp(subexp(PCT_ENCODED$ + "|" + merge(UNRESERVED$$, SUB_DELIMS$$, "[\\:]")) + "*"),
1156
+ DEC_OCTET_RELAXED$ = subexp(subexp("25[0-5]") + "|" + subexp("2[0-4]" + DIGIT$$) + "|" + subexp("1" + DIGIT$$ + DIGIT$$) + "|" + subexp("0?[1-9]" + DIGIT$$) + "|0?0?" + DIGIT$$),
1153
1157
  //relaxed parsing rules
1154
1158
  IPV4ADDRESS$ = subexp(DEC_OCTET_RELAXED$ + "\\." + DEC_OCTET_RELAXED$ + "\\." + DEC_OCTET_RELAXED$ + "\\." + DEC_OCTET_RELAXED$),
1155
1159
  H16$ = subexp(HEXDIG$$ + "{1,4}"),
@@ -1173,14 +1177,14 @@ function buildExps(isIRI) {
1173
1177
  IPV6ADDRESS9$ = subexp(subexp(subexp(H16$ + "\\:") + "{0,6}" + H16$) + "?\\:\\:"),
1174
1178
  //[ *6( h16 ":" ) h16 ] "::"
1175
1179
  IPV6ADDRESS$ = subexp([IPV6ADDRESS1$, IPV6ADDRESS2$, IPV6ADDRESS3$, IPV6ADDRESS4$, IPV6ADDRESS5$, IPV6ADDRESS6$, IPV6ADDRESS7$, IPV6ADDRESS8$, IPV6ADDRESS9$].join("|")),
1176
- ZONEID$ = subexp(subexp(UNRESERVED$$ + "|" + PCT_ENCODED$) + "+");
1180
+ ZONEID$ = subexp(subexp(UNRESERVED$$ + "|" + PCT_ENCODED$) + "+"),
1177
1181
  //RFC 6874, with relaxed parsing rules
1178
- subexp("[vV]" + HEXDIG$$ + "+\\." + merge(UNRESERVED$$, SUB_DELIMS$$, "[\\:]") + "+");
1182
+ IPVFUTURE$ = subexp("[vV]" + HEXDIG$$ + "+\\." + merge(UNRESERVED$$, SUB_DELIMS$$, "[\\:]") + "+"),
1179
1183
  //RFC 6874
1180
- subexp(subexp(PCT_ENCODED$ + "|" + merge(UNRESERVED$$, SUB_DELIMS$$)) + "*");
1181
- var PCHAR$ = subexp(PCT_ENCODED$ + "|" + merge(UNRESERVED$$, SUB_DELIMS$$, "[\\:\\@]"));
1182
- subexp(subexp(PCT_ENCODED$ + "|" + merge(UNRESERVED$$, SUB_DELIMS$$, "[\\@]")) + "+");
1183
- subexp(subexp(PCHAR$ + "|" + merge("[\\/\\?]", IPRIVATE$$)) + "*");
1184
+ REG_NAME$ = subexp(subexp(PCT_ENCODED$ + "|" + merge(UNRESERVED$$, SUB_DELIMS$$)) + "*"),
1185
+ PCHAR$ = subexp(PCT_ENCODED$ + "|" + merge(UNRESERVED$$, SUB_DELIMS$$, "[\\:\\@]")),
1186
+ SEGMENT_NZ_NC$ = subexp(subexp(PCT_ENCODED$ + "|" + merge(UNRESERVED$$, SUB_DELIMS$$, "[\\@]")) + "+"),
1187
+ QUERY$ = subexp(subexp(PCHAR$ + "|" + merge("[\\/\\?]", IPRIVATE$$)) + "*");
1184
1188
  return {
1185
1189
  NOT_SCHEME: new RegExp(merge("[^]", ALPHA$$, DIGIT$$, "[\\+\\-\\.]"), "g"),
1186
1190
  NOT_USERINFO: new RegExp(merge("[^\\%\\:]", UNRESERVED$$, SUB_DELIMS$$), "g"),
@@ -2294,7 +2298,7 @@ var handler$3 = {
2294
2298
 
2295
2299
  var O = {};
2296
2300
  //RFC 3986
2297
- var UNRESERVED$$ = "[A-Za-z0-9\\-\\.\\_\\~" + ("\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF" ) + "]";
2301
+ var UNRESERVED$$ = "[A-Za-z0-9\\-\\.\\_\\~" + ( "\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF" ) + "]";
2298
2302
  var HEXDIG$$ = "[0-9A-Fa-f]"; //case-insensitive
2299
2303
  var PCT_ENCODED$ = subexp(subexp("%[EFef]" + HEXDIG$$ + "%" + HEXDIG$$ + HEXDIG$$ + "%" + HEXDIG$$ + HEXDIG$$) + "|" + subexp("%[89A-Fa-f]" + HEXDIG$$ + "%" + HEXDIG$$ + HEXDIG$$) + "|" + subexp("%" + HEXDIG$$ + HEXDIG$$)); //expanded
2300
2304
  //RFC 5322, except these symbols as per RFC 6068: @ : / ? # [ ] & ; =
@@ -2492,7 +2496,9 @@ Object.defineProperty(exports, '__esModule', { value: true });
2492
2496
 
2493
2497
  })));
2494
2498
 
2495
- }(uri_all, uri_all.exports));
2499
+ });
2500
+
2501
+ unwrapExports(uri_all);
2496
2502
 
2497
2503
  var isArray = Array.isArray;
2498
2504
  var keyList = Object.keys;
@@ -2550,7 +2556,7 @@ var fastDeepEqual = function equal(a, b) {
2550
2556
 
2551
2557
  // https://mathiasbynens.be/notes/javascript-encoding
2552
2558
  // https://github.com/bestiejs/punycode.js - punycode.ucs2.decode
2553
- var ucs2length$1 = function ucs2length(str) {
2559
+ var ucs2length = function ucs2length(str) {
2554
2560
  var length = 0
2555
2561
  , len = str.length
2556
2562
  , pos = 0
@@ -2567,16 +2573,16 @@ var ucs2length$1 = function ucs2length(str) {
2567
2573
  return length;
2568
2574
  };
2569
2575
 
2570
- var util$5 = {
2576
+ var util = {
2571
2577
  copy: copy,
2572
2578
  checkDataType: checkDataType,
2573
2579
  checkDataTypes: checkDataTypes,
2574
2580
  coerceToTypes: coerceToTypes,
2575
- toHash: toHash$1,
2581
+ toHash: toHash,
2576
2582
  getProperty: getProperty,
2577
2583
  escapeQuotes: escapeQuotes,
2578
2584
  equal: fastDeepEqual,
2579
- ucs2length: ucs2length$1,
2585
+ ucs2length: ucs2length,
2580
2586
  varOccurences: varOccurences,
2581
2587
  varReplace: varReplace,
2582
2588
  cleanUpCode: cleanUpCode,
@@ -2626,7 +2632,7 @@ function checkDataTypes(dataTypes, data) {
2626
2632
  case 1: return checkDataType(dataTypes[0], data, true);
2627
2633
  default:
2628
2634
  var code = '';
2629
- var types = toHash$1(dataTypes);
2635
+ var types = toHash(dataTypes);
2630
2636
  if (types.array && types.object) {
2631
2637
  code = types.null ? '(': '(!' + data + ' || ';
2632
2638
  code += 'typeof ' + data + ' !== "object")';
@@ -2643,7 +2649,7 @@ function checkDataTypes(dataTypes, data) {
2643
2649
  }
2644
2650
 
2645
2651
 
2646
- var COERCE_TO_TYPES = toHash$1([ 'string', 'number', 'integer', 'boolean', 'null' ]);
2652
+ var COERCE_TO_TYPES = toHash([ 'string', 'number', 'integer', 'boolean', 'null' ]);
2647
2653
  function coerceToTypes(optionCoerceTypes, dataTypes) {
2648
2654
  if (Array.isArray(dataTypes)) {
2649
2655
  var types = [];
@@ -2661,19 +2667,19 @@ function coerceToTypes(optionCoerceTypes, dataTypes) {
2661
2667
  }
2662
2668
 
2663
2669
 
2664
- function toHash$1(arr) {
2670
+ function toHash(arr) {
2665
2671
  var hash = {};
2666
2672
  for (var i=0; i<arr.length; i++) hash[arr[i]] = true;
2667
2673
  return hash;
2668
2674
  }
2669
2675
 
2670
2676
 
2671
- var IDENTIFIER$1 = /^[a-z$_][a-z$_0-9]*$/i;
2677
+ var IDENTIFIER = /^[a-z$_][a-z$_0-9]*$/i;
2672
2678
  var SINGLE_QUOTE = /'|\\/g;
2673
2679
  function getProperty(key) {
2674
2680
  return typeof key == 'number'
2675
2681
  ? '[' + key + ']'
2676
- : IDENTIFIER$1.test(key)
2682
+ : IDENTIFIER.test(key)
2677
2683
  ? '.' + key
2678
2684
  : "['" + escapeQuotes(key) + "']";
2679
2685
  }
@@ -2777,17 +2783,17 @@ function getPath(currentPath, prop, jsonPointers) {
2777
2783
  }
2778
2784
 
2779
2785
 
2780
- var JSON_POINTER$1 = /^\/(?:[^~]|~0|~1)*$/;
2781
- var RELATIVE_JSON_POINTER$1 = /^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;
2786
+ var JSON_POINTER = /^\/(?:[^~]|~0|~1)*$/;
2787
+ var RELATIVE_JSON_POINTER = /^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;
2782
2788
  function getData($data, lvl, paths) {
2783
2789
  var up, jsonPointer, data, matches;
2784
2790
  if ($data === '') return 'rootData';
2785
2791
  if ($data[0] == '/') {
2786
- if (!JSON_POINTER$1.test($data)) throw new Error('Invalid JSON-pointer: ' + $data);
2792
+ if (!JSON_POINTER.test($data)) throw new Error('Invalid JSON-pointer: ' + $data);
2787
2793
  jsonPointer = $data;
2788
2794
  data = 'rootData';
2789
2795
  } else {
2790
- matches = $data.match(RELATIVE_JSON_POINTER$1);
2796
+ matches = $data.match(RELATIVE_JSON_POINTER);
2791
2797
  if (!matches) throw new Error('Invalid JSON-pointer: ' + $data);
2792
2798
  up = +matches[1];
2793
2799
  jsonPointer = matches[2];
@@ -2839,17 +2845,15 @@ function unescapeJsonPointer(str) {
2839
2845
  return str.replace(/~1/g, '/').replace(/~0/g, '~');
2840
2846
  }
2841
2847
 
2842
- var util$4 = util$5;
2843
-
2844
- var schema_obj = SchemaObject$2;
2848
+ var schema_obj = SchemaObject;
2845
2849
 
2846
- function SchemaObject$2(obj) {
2847
- util$4.copy(obj, this);
2850
+ function SchemaObject(obj) {
2851
+ util.copy(obj, this);
2848
2852
  }
2849
2853
 
2850
- var jsonSchemaTraverse = {exports: {}};
2854
+ var jsonSchemaTraverse = createCommonjsModule(function (module) {
2851
2855
 
2852
- var traverse$1 = jsonSchemaTraverse.exports = function (schema, opts, cb) {
2856
+ var traverse = module.exports = function (schema, opts, cb) {
2853
2857
  // Legacy support for v0.3.1 and earlier.
2854
2858
  if (typeof opts == 'function') {
2855
2859
  cb = opts;
@@ -2864,7 +2868,7 @@ var traverse$1 = jsonSchemaTraverse.exports = function (schema, opts, cb) {
2864
2868
  };
2865
2869
 
2866
2870
 
2867
- traverse$1.keywords = {
2871
+ traverse.keywords = {
2868
2872
  additionalItems: true,
2869
2873
  items: true,
2870
2874
  contains: true,
@@ -2873,21 +2877,21 @@ traverse$1.keywords = {
2873
2877
  not: true
2874
2878
  };
2875
2879
 
2876
- traverse$1.arrayKeywords = {
2880
+ traverse.arrayKeywords = {
2877
2881
  items: true,
2878
2882
  allOf: true,
2879
2883
  anyOf: true,
2880
2884
  oneOf: true
2881
2885
  };
2882
2886
 
2883
- traverse$1.propsKeywords = {
2887
+ traverse.propsKeywords = {
2884
2888
  definitions: true,
2885
2889
  properties: true,
2886
2890
  patternProperties: true,
2887
2891
  dependencies: true
2888
2892
  };
2889
2893
 
2890
- traverse$1.skipKeywords = {
2894
+ traverse.skipKeywords = {
2891
2895
  default: true,
2892
2896
  enum: true,
2893
2897
  const: true,
@@ -2915,16 +2919,16 @@ function _traverse(opts, pre, post, schema, jsonPtr, rootSchema, parentJsonPtr,
2915
2919
  for (var key in schema) {
2916
2920
  var sch = schema[key];
2917
2921
  if (Array.isArray(sch)) {
2918
- if (key in traverse$1.arrayKeywords) {
2922
+ if (key in traverse.arrayKeywords) {
2919
2923
  for (var i=0; i<sch.length; i++)
2920
2924
  _traverse(opts, pre, post, sch[i], jsonPtr + '/' + key + '/' + i, rootSchema, jsonPtr, key, schema, i);
2921
2925
  }
2922
- } else if (key in traverse$1.propsKeywords) {
2926
+ } else if (key in traverse.propsKeywords) {
2923
2927
  if (sch && typeof sch == 'object') {
2924
2928
  for (var prop in sch)
2925
2929
  _traverse(opts, pre, post, sch[prop], jsonPtr + '/' + key + '/' + escapeJsonPtr(prop), rootSchema, jsonPtr, key, schema, prop);
2926
2930
  }
2927
- } else if (key in traverse$1.keywords || (opts.allKeys && !(key in traverse$1.skipKeywords))) {
2931
+ } else if (key in traverse.keywords || (opts.allKeys && !(key in traverse.skipKeywords))) {
2928
2932
  _traverse(opts, pre, post, sch, jsonPtr + '/' + key, rootSchema, jsonPtr, key, schema);
2929
2933
  }
2930
2934
  }
@@ -2936,21 +2940,16 @@ function _traverse(opts, pre, post, schema, jsonPtr, rootSchema, parentJsonPtr,
2936
2940
  function escapeJsonPtr(str) {
2937
2941
  return str.replace(/~/g, '~0').replace(/\//g, '~1');
2938
2942
  }
2943
+ });
2939
2944
 
2940
- var URI$1 = uri_all.exports
2941
- , equal$1 = fastDeepEqual
2942
- , util$3 = util$5
2943
- , SchemaObject$1 = schema_obj
2944
- , traverse = jsonSchemaTraverse.exports;
2945
-
2946
- var resolve_1 = resolve$3;
2945
+ var resolve_1 = resolve;
2947
2946
 
2948
- resolve$3.normalizeId = normalizeId;
2949
- resolve$3.fullPath = getFullPath;
2950
- resolve$3.url = resolveUrl;
2951
- resolve$3.ids = resolveIds;
2952
- resolve$3.inlineRef = inlineRef;
2953
- resolve$3.schema = resolveSchema;
2947
+ resolve.normalizeId = normalizeId;
2948
+ resolve.fullPath = getFullPath;
2949
+ resolve.url = resolveUrl;
2950
+ resolve.ids = resolveIds;
2951
+ resolve.inlineRef = inlineRef;
2952
+ resolve.schema = resolveSchema;
2954
2953
 
2955
2954
  /**
2956
2955
  * [resolve and compile the references ($ref)]
@@ -2960,16 +2959,16 @@ resolve$3.schema = resolveSchema;
2960
2959
  * @param {String} ref reference to resolve
2961
2960
  * @return {Object|Function} schema object (if the schema can be inlined) or validation function
2962
2961
  */
2963
- function resolve$3(compile, root, ref) {
2962
+ function resolve(compile, root, ref) {
2964
2963
  /* jshint validthis: true */
2965
2964
  var refVal = this._refs[ref];
2966
2965
  if (typeof refVal == 'string') {
2967
2966
  if (this._refs[refVal]) refVal = this._refs[refVal];
2968
- else return resolve$3.call(this, compile, root, refVal);
2967
+ else return resolve.call(this, compile, root, refVal);
2969
2968
  }
2970
2969
 
2971
2970
  refVal = refVal || this._schemas[ref];
2972
- if (refVal instanceof SchemaObject$1) {
2971
+ if (refVal instanceof schema_obj) {
2973
2972
  return inlineRef(refVal.schema, this._opts.inlineRefs)
2974
2973
  ? refVal.schema
2975
2974
  : refVal.validate || this._compile(refVal);
@@ -2983,7 +2982,7 @@ function resolve$3(compile, root, ref) {
2983
2982
  baseId = res.baseId;
2984
2983
  }
2985
2984
 
2986
- if (schema instanceof SchemaObject$1) {
2985
+ if (schema instanceof schema_obj) {
2987
2986
  v = schema.validate || compile.call(this, schema.schema, root, undefined, baseId);
2988
2987
  } else if (schema !== undefined) {
2989
2988
  v = inlineRef(schema, this._opts.inlineRefs)
@@ -3004,7 +3003,7 @@ function resolve$3(compile, root, ref) {
3004
3003
  */
3005
3004
  function resolveSchema(root, ref) {
3006
3005
  /* jshint validthis: true */
3007
- var p = URI$1.parse(ref)
3006
+ var p = uri_all.parse(ref)
3008
3007
  , refPath = _getFullPath(p)
3009
3008
  , baseId = getFullPath(this._getId(root.schema));
3010
3009
  if (Object.keys(root.schema).length === 0 || refPath !== baseId) {
@@ -3012,12 +3011,12 @@ function resolveSchema(root, ref) {
3012
3011
  var refVal = this._refs[id];
3013
3012
  if (typeof refVal == 'string') {
3014
3013
  return resolveRecursive.call(this, root, refVal, p);
3015
- } else if (refVal instanceof SchemaObject$1) {
3014
+ } else if (refVal instanceof schema_obj) {
3016
3015
  if (!refVal.validate) this._compile(refVal);
3017
3016
  root = refVal;
3018
3017
  } else {
3019
3018
  refVal = this._schemas[id];
3020
- if (refVal instanceof SchemaObject$1) {
3019
+ if (refVal instanceof schema_obj) {
3021
3020
  if (!refVal.validate) this._compile(refVal);
3022
3021
  if (id == normalizeId(ref))
3023
3022
  return { schema: refVal, root: root, baseId: baseId };
@@ -3048,7 +3047,7 @@ function resolveRecursive(root, ref, parsedRef) {
3048
3047
  }
3049
3048
 
3050
3049
 
3051
- var PREVENT_SCOPE_CHANGE = util$3.toHash(['properties', 'patternProperties', 'enum', 'dependencies', 'definitions']);
3050
+ var PREVENT_SCOPE_CHANGE = util.toHash(['properties', 'patternProperties', 'enum', 'dependencies', 'definitions']);
3052
3051
  /* @this Ajv */
3053
3052
  function getJsonPointer(parsedRef, baseId, schema, root) {
3054
3053
  /* jshint validthis: true */
@@ -3059,7 +3058,7 @@ function getJsonPointer(parsedRef, baseId, schema, root) {
3059
3058
  for (var i = 1; i < parts.length; i++) {
3060
3059
  var part = parts[i];
3061
3060
  if (part) {
3062
- part = util$3.unescapeFragment(part);
3061
+ part = util.unescapeFragment(part);
3063
3062
  schema = schema[part];
3064
3063
  if (schema === undefined) break;
3065
3064
  var id;
@@ -3083,7 +3082,7 @@ function getJsonPointer(parsedRef, baseId, schema, root) {
3083
3082
  }
3084
3083
 
3085
3084
 
3086
- var SIMPLE_INLINED = util$3.toHash([
3085
+ var SIMPLE_INLINED = util.toHash([
3087
3086
  'type', 'format', 'pattern',
3088
3087
  'maxLength', 'minLength',
3089
3088
  'maxProperties', 'minProperties',
@@ -3143,13 +3142,13 @@ function countKeys(schema) {
3143
3142
 
3144
3143
  function getFullPath(id, normalize) {
3145
3144
  if (normalize !== false) id = normalizeId(id);
3146
- var p = URI$1.parse(id);
3145
+ var p = uri_all.parse(id);
3147
3146
  return _getFullPath(p);
3148
3147
  }
3149
3148
 
3150
3149
 
3151
3150
  function _getFullPath(p) {
3152
- return URI$1.serialize(p).split('#')[0] + '#';
3151
+ return uri_all.serialize(p).split('#')[0] + '#';
3153
3152
  }
3154
3153
 
3155
3154
 
@@ -3161,7 +3160,7 @@ function normalizeId(id) {
3161
3160
 
3162
3161
  function resolveUrl(baseId, id) {
3163
3162
  id = normalizeId(id);
3164
- return URI$1.resolve(baseId, id);
3163
+ return uri_all.resolve(baseId, id);
3165
3164
  }
3166
3165
 
3167
3166
 
@@ -3173,25 +3172,25 @@ function resolveIds(schema) {
3173
3172
  var localRefs = {};
3174
3173
  var self = this;
3175
3174
 
3176
- traverse(schema, {allKeys: true}, function(sch, jsonPtr, rootSchema, parentJsonPtr, parentKeyword, parentSchema, keyIndex) {
3175
+ jsonSchemaTraverse(schema, {allKeys: true}, function(sch, jsonPtr, rootSchema, parentJsonPtr, parentKeyword, parentSchema, keyIndex) {
3177
3176
  if (jsonPtr === '') return;
3178
3177
  var id = self._getId(sch);
3179
3178
  var baseId = baseIds[parentJsonPtr];
3180
3179
  var fullPath = fullPaths[parentJsonPtr] + '/' + parentKeyword;
3181
3180
  if (keyIndex !== undefined)
3182
- fullPath += '/' + (typeof keyIndex == 'number' ? keyIndex : util$3.escapeFragment(keyIndex));
3181
+ fullPath += '/' + (typeof keyIndex == 'number' ? keyIndex : util.escapeFragment(keyIndex));
3183
3182
 
3184
3183
  if (typeof id == 'string') {
3185
- id = baseId = normalizeId(baseId ? URI$1.resolve(baseId, id) : id);
3184
+ id = baseId = normalizeId(baseId ? uri_all.resolve(baseId, id) : id);
3186
3185
 
3187
3186
  var refVal = self._refs[id];
3188
3187
  if (typeof refVal == 'string') refVal = self._refs[refVal];
3189
3188
  if (refVal && refVal.schema) {
3190
- if (!equal$1(sch, refVal.schema))
3189
+ if (!fastDeepEqual(sch, refVal.schema))
3191
3190
  throw new Error('id "' + id + '" resolves to more than one schema');
3192
3191
  } else if (id != normalizeId(fullPath)) {
3193
3192
  if (id[0] == '#') {
3194
- if (localRefs[id] && !equal$1(sch, localRefs[id]))
3193
+ if (localRefs[id] && !fastDeepEqual(sch, localRefs[id]))
3195
3194
  throw new Error('id "' + id + '" resolves to more than one schema');
3196
3195
  localRefs[id] = sch;
3197
3196
  } else {
@@ -3206,30 +3205,28 @@ function resolveIds(schema) {
3206
3205
  return localRefs;
3207
3206
  }
3208
3207
 
3209
- var resolve$2 = resolve_1;
3210
-
3211
3208
  var error_classes = {
3212
- Validation: errorSubclass(ValidationError$1),
3213
- MissingRef: errorSubclass(MissingRefError$1)
3209
+ Validation: errorSubclass(ValidationError),
3210
+ MissingRef: errorSubclass(MissingRefError)
3214
3211
  };
3215
3212
 
3216
3213
 
3217
- function ValidationError$1(errors) {
3214
+ function ValidationError(errors) {
3218
3215
  this.message = 'validation failed';
3219
3216
  this.errors = errors;
3220
3217
  this.ajv = this.validation = true;
3221
3218
  }
3222
3219
 
3223
3220
 
3224
- MissingRefError$1.message = function (baseId, ref) {
3221
+ MissingRefError.message = function (baseId, ref) {
3225
3222
  return 'can\'t resolve reference ' + ref + ' from id ' + baseId;
3226
3223
  };
3227
3224
 
3228
3225
 
3229
- function MissingRefError$1(baseId, ref, message) {
3230
- this.message = message || MissingRefError$1.message(baseId, ref);
3231
- this.missingRef = resolve$2.url(baseId, ref);
3232
- this.missingSchema = resolve$2.normalizeId(resolve$2.fullPath(this.missingRef));
3226
+ function MissingRefError(baseId, ref, message) {
3227
+ this.message = message || MissingRefError.message(baseId, ref);
3228
+ this.missingRef = resolve_1.url(baseId, ref);
3229
+ this.missingSchema = resolve_1.normalizeId(resolve_1.fullPath(this.missingRef));
3233
3230
  }
3234
3231
 
3235
3232
 
@@ -3297,7 +3294,7 @@ var fastJsonStableStringify = function (data, opts) {
3297
3294
  })(data);
3298
3295
  };
3299
3296
 
3300
- var validate$1 = function generate_validate(it, $keyword, $ruleType) {
3297
+ var validate = function generate_validate(it, $keyword, $ruleType) {
3301
3298
  var out = '';
3302
3299
  var $async = it.schema.$async === true,
3303
3300
  $refKeywords = it.util.schemaHasRulesExcept(it.schema, it.RULES.all, '$ref'),
@@ -3791,24 +3788,17 @@ var validate$1 = function generate_validate(it, $keyword, $ruleType) {
3791
3788
  return out;
3792
3789
  };
3793
3790
 
3794
- var resolve$1 = resolve_1
3795
- , util$2 = util$5
3796
- , errorClasses$1 = error_classes
3797
- , stableStringify$1 = fastJsonStableStringify;
3798
-
3799
- var validateGenerator = validate$1;
3800
-
3801
3791
  /**
3802
3792
  * Functions below are used inside compiled validations function
3803
3793
  */
3804
3794
 
3805
- var ucs2length = util$2.ucs2length;
3806
- var equal = fastDeepEqual;
3795
+ var ucs2length$1 = util.ucs2length;
3796
+
3807
3797
 
3808
3798
  // this error is thrown by async schemas to return validation errors via exception
3809
- var ValidationError = errorClasses$1.Validation;
3799
+ var ValidationError$1 = error_classes.Validation;
3810
3800
 
3811
- var compile_1 = compile$1;
3801
+ var compile_1 = compile;
3812
3802
 
3813
3803
 
3814
3804
  /**
@@ -3820,7 +3810,7 @@ var compile_1 = compile$1;
3820
3810
  * @param {String} baseId base ID for IDs in the schema
3821
3811
  * @return {Function} validation function
3822
3812
  */
3823
- function compile$1(schema, root, localRefs, baseId) {
3813
+ function compile(schema, root, localRefs, baseId) {
3824
3814
  /* jshint validthis: true, evil: true */
3825
3815
  /* eslint no-shadow: 0 */
3826
3816
  var self = this
@@ -3872,11 +3862,11 @@ function compile$1(schema, root, localRefs, baseId) {
3872
3862
  function localCompile(_schema, _root, localRefs, baseId) {
3873
3863
  var isRoot = !_root || (_root && _root.schema == _schema);
3874
3864
  if (_root.schema != root.schema)
3875
- return compile$1.call(self, _schema, _root, localRefs, baseId);
3865
+ return compile.call(self, _schema, _root, localRefs, baseId);
3876
3866
 
3877
3867
  var $async = _schema.$async === true;
3878
3868
 
3879
- var sourceCode = validateGenerator({
3869
+ var sourceCode = validate({
3880
3870
  isTop: true,
3881
3871
  schema: _schema,
3882
3872
  isRoot: isRoot,
@@ -3885,11 +3875,11 @@ function compile$1(schema, root, localRefs, baseId) {
3885
3875
  schemaPath: '',
3886
3876
  errSchemaPath: '#',
3887
3877
  errorPath: '""',
3888
- MissingRefError: errorClasses$1.MissingRef,
3878
+ MissingRefError: error_classes.MissingRef,
3889
3879
  RULES: RULES,
3890
- validate: validateGenerator,
3891
- util: util$2,
3892
- resolve: resolve$1,
3880
+ validate: validate,
3881
+ util: util,
3882
+ resolve: resolve_1,
3893
3883
  resolveRef: resolveRef,
3894
3884
  usePattern: usePattern,
3895
3885
  useDefault: useDefault,
@@ -3901,12 +3891,12 @@ function compile$1(schema, root, localRefs, baseId) {
3901
3891
  });
3902
3892
 
3903
3893
  sourceCode = vars(refVal, refValCode) + vars(patterns, patternCode)
3904
- + vars(defaults, defaultCode) + vars(customRules, customRuleCode$1)
3894
+ + vars(defaults, defaultCode) + vars(customRules, customRuleCode)
3905
3895
  + sourceCode;
3906
3896
 
3907
3897
  if (opts.processCode) sourceCode = opts.processCode(sourceCode);
3908
3898
  // console.log('\n\n\n *** \n', JSON.stringify(sourceCode));
3909
- var validate;
3899
+ var validate$1;
3910
3900
  try {
3911
3901
  var makeValidate = new Function(
3912
3902
  'self',
@@ -3922,7 +3912,7 @@ function compile$1(schema, root, localRefs, baseId) {
3922
3912
  sourceCode
3923
3913
  );
3924
3914
 
3925
- validate = makeValidate(
3915
+ validate$1 = makeValidate(
3926
3916
  self,
3927
3917
  RULES,
3928
3918
  formats,
@@ -3930,36 +3920,36 @@ function compile$1(schema, root, localRefs, baseId) {
3930
3920
  refVal,
3931
3921
  defaults,
3932
3922
  customRules,
3933
- equal,
3934
- ucs2length,
3935
- ValidationError
3923
+ fastDeepEqual,
3924
+ ucs2length$1,
3925
+ ValidationError$1
3936
3926
  );
3937
3927
 
3938
- refVal[0] = validate;
3928
+ refVal[0] = validate$1;
3939
3929
  } catch(e) {
3940
3930
  self.logger.error('Error compiling schema, function code:', sourceCode);
3941
3931
  throw e;
3942
3932
  }
3943
3933
 
3944
- validate.schema = _schema;
3945
- validate.errors = null;
3946
- validate.refs = refs;
3947
- validate.refVal = refVal;
3948
- validate.root = isRoot ? validate : _root;
3949
- if ($async) validate.$async = true;
3934
+ validate$1.schema = _schema;
3935
+ validate$1.errors = null;
3936
+ validate$1.refs = refs;
3937
+ validate$1.refVal = refVal;
3938
+ validate$1.root = isRoot ? validate$1 : _root;
3939
+ if ($async) validate$1.$async = true;
3950
3940
  if (opts.sourceCode === true) {
3951
- validate.source = {
3941
+ validate$1.source = {
3952
3942
  code: sourceCode,
3953
3943
  patterns: patterns,
3954
3944
  defaults: defaults
3955
3945
  };
3956
3946
  }
3957
3947
 
3958
- return validate;
3948
+ return validate$1;
3959
3949
  }
3960
3950
 
3961
3951
  function resolveRef(baseId, ref, isRoot) {
3962
- ref = resolve$1.url(baseId, ref);
3952
+ ref = resolve_1.url(baseId, ref);
3963
3953
  var refIndex = refs[ref];
3964
3954
  var _refVal, refCode;
3965
3955
  if (refIndex !== undefined) {
@@ -3977,13 +3967,13 @@ function compile$1(schema, root, localRefs, baseId) {
3977
3967
  }
3978
3968
 
3979
3969
  refCode = addLocalRef(ref);
3980
- var v = resolve$1.call(self, localCompile, root, ref);
3970
+ var v = resolve_1.call(self, localCompile, root, ref);
3981
3971
  if (v === undefined) {
3982
3972
  var localSchema = localRefs && localRefs[ref];
3983
3973
  if (localSchema) {
3984
- v = resolve$1.inlineRef(localSchema, opts.inlineRefs)
3974
+ v = resolve_1.inlineRef(localSchema, opts.inlineRefs)
3985
3975
  ? localSchema
3986
- : compile$1.call(self, localSchema, root, localRefs, baseId);
3976
+ : compile.call(self, localSchema, root, localRefs, baseId);
3987
3977
  }
3988
3978
  }
3989
3979
 
@@ -4032,10 +4022,10 @@ function compile$1(schema, root, localRefs, baseId) {
4032
4022
  case 'number':
4033
4023
  return '' + value;
4034
4024
  case 'string':
4035
- return util$2.toQuotedString(value);
4025
+ return util.toQuotedString(value);
4036
4026
  case 'object':
4037
4027
  if (value === null) return 'null';
4038
- var valueStr = stableStringify$1(value);
4028
+ var valueStr = fastJsonStableStringify(value);
4039
4029
  var index = defaultsHash[valueStr];
4040
4030
  if (index === undefined) {
4041
4031
  index = defaultsHash[valueStr] = defaults.length;
@@ -4150,7 +4140,7 @@ function compIndex(schema, root, baseId) {
4150
4140
 
4151
4141
 
4152
4142
  function patternCode(i, patterns) {
4153
- return 'var pattern' + i + ' = new RegExp(' + util$2.toQuotedString(patterns[i]) + ');';
4143
+ return 'var pattern' + i + ' = new RegExp(' + util.toQuotedString(patterns[i]) + ');';
4154
4144
  }
4155
4145
 
4156
4146
 
@@ -4164,7 +4154,7 @@ function refValCode(i, refVal) {
4164
4154
  }
4165
4155
 
4166
4156
 
4167
- function customRuleCode$1(i) {
4157
+ function customRuleCode(i) {
4168
4158
  return 'var customRule' + i + ' = customRules[' + i + '];';
4169
4159
  }
4170
4160
 
@@ -4177,33 +4167,33 @@ function vars(arr, statement) {
4177
4167
  return code;
4178
4168
  }
4179
4169
 
4180
- var cache = {exports: {}};
4170
+ var cache = createCommonjsModule(function (module) {
4181
4171
 
4182
- var Cache$1 = cache.exports = function Cache() {
4172
+
4173
+ var Cache = module.exports = function Cache() {
4183
4174
  this._cache = {};
4184
4175
  };
4185
4176
 
4186
4177
 
4187
- Cache$1.prototype.put = function Cache_put(key, value) {
4178
+ Cache.prototype.put = function Cache_put(key, value) {
4188
4179
  this._cache[key] = value;
4189
4180
  };
4190
4181
 
4191
4182
 
4192
- Cache$1.prototype.get = function Cache_get(key) {
4183
+ Cache.prototype.get = function Cache_get(key) {
4193
4184
  return this._cache[key];
4194
4185
  };
4195
4186
 
4196
4187
 
4197
- Cache$1.prototype.del = function Cache_del(key) {
4188
+ Cache.prototype.del = function Cache_del(key) {
4198
4189
  delete this._cache[key];
4199
4190
  };
4200
4191
 
4201
4192
 
4202
- Cache$1.prototype.clear = function Cache_clear() {
4193
+ Cache.prototype.clear = function Cache_clear() {
4203
4194
  this._cache = {};
4204
4195
  };
4205
-
4206
- var util$1 = util$5;
4196
+ });
4207
4197
 
4208
4198
  var DATE = /^(\d\d\d\d)-(\d\d)-(\d\d)$/;
4209
4199
  var DAYS = [0,31,28,31,30,31,30,31,31,30,31,30,31];
@@ -4219,20 +4209,20 @@ var URITEMPLATE = /^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|
4219
4209
  // var URL = /^(?:(?:https?|ftp):\/\/)(?:\S+(?::\S*)?@)?(?:(?!10(?:\.\d{1,3}){3})(?!127(?:\.\d{1,3}){3})(?!169\.254(?:\.\d{1,3}){2})(?!192\.168(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z\u{00a1}-\u{ffff}0-9]+-?)*[a-z\u{00a1}-\u{ffff}0-9]+)(?:\.(?:[a-z\u{00a1}-\u{ffff}0-9]+-?)*[a-z\u{00a1}-\u{ffff}0-9]+)*(?:\.(?:[a-z\u{00a1}-\u{ffff}]{2,})))(?::\d{2,5})?(?:\/[^\s]*)?$/iu;
4220
4210
  var URL = /^(?:(?:http[s\u017F]?|ftp):\/\/)(?:(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+(?::(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])*)?@)?(?:(?!10(?:\.[0-9]{1,3}){3})(?!127(?:\.[0-9]{1,3}){3})(?!169\.254(?:\.[0-9]{1,3}){2})(?!192\.168(?:\.[0-9]{1,3}){2})(?!172\.(?:1[6-9]|2[0-9]|3[01])(?:\.[0-9]{1,3}){2})(?:[1-9][0-9]?|1[0-9][0-9]|2[01][0-9]|22[0-3])(?:\.(?:1?[0-9]{1,2}|2[0-4][0-9]|25[0-5])){2}(?:\.(?:[1-9][0-9]?|1[0-9][0-9]|2[0-4][0-9]|25[0-4]))|(?:(?:(?:[0-9KSa-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+-?)*(?:[0-9KSa-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+)(?:\.(?:(?:[0-9KSa-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+-?)*(?:[0-9KSa-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+)*(?:\.(?:(?:[KSa-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]){2,})))(?::[0-9]{2,5})?(?:\/(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])*)?$/i;
4221
4211
  var UUID = /^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i;
4222
- var JSON_POINTER = /^(?:\/(?:[^~/]|~0|~1)*)*$/;
4212
+ var JSON_POINTER$1 = /^(?:\/(?:[^~/]|~0|~1)*)*$/;
4223
4213
  var JSON_POINTER_URI_FRAGMENT = /^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i;
4224
- var RELATIVE_JSON_POINTER = /^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/;
4214
+ var RELATIVE_JSON_POINTER$1 = /^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/;
4225
4215
 
4226
4216
 
4227
- var formats_1 = formats$1;
4217
+ var formats_1 = formats;
4228
4218
 
4229
- function formats$1(mode) {
4219
+ function formats(mode) {
4230
4220
  mode = mode == 'full' ? 'full' : 'fast';
4231
- return util$1.copy(formats$1[mode]);
4221
+ return util.copy(formats[mode]);
4232
4222
  }
4233
4223
 
4234
4224
 
4235
- formats$1.fast = {
4225
+ formats.fast = {
4236
4226
  // date: http://tools.ietf.org/html/rfc3339#section-5.6
4237
4227
  date: /^\d\d\d\d-[0-1]\d-[0-3]\d$/,
4238
4228
  // date-time: http://tools.ietf.org/html/rfc3339#section-5.6
@@ -4257,14 +4247,14 @@ formats$1.fast = {
4257
4247
  uuid: UUID,
4258
4248
  // JSON-pointer: https://tools.ietf.org/html/rfc6901
4259
4249
  // uri fragment: https://tools.ietf.org/html/rfc3986#appendix-A
4260
- 'json-pointer': JSON_POINTER,
4250
+ 'json-pointer': JSON_POINTER$1,
4261
4251
  'json-pointer-uri-fragment': JSON_POINTER_URI_FRAGMENT,
4262
4252
  // relative JSON-pointer: http://tools.ietf.org/html/draft-luff-relative-json-pointer-00
4263
- 'relative-json-pointer': RELATIVE_JSON_POINTER
4253
+ 'relative-json-pointer': RELATIVE_JSON_POINTER$1
4264
4254
  };
4265
4255
 
4266
4256
 
4267
- formats$1.full = {
4257
+ formats.full = {
4268
4258
  date: date,
4269
4259
  time: time,
4270
4260
  'date-time': date_time,
@@ -4278,9 +4268,9 @@ formats$1.full = {
4278
4268
  ipv6: /^\s*(?:(?:(?:[0-9a-f]{1,4}:){7}(?:[0-9a-f]{1,4}|:))|(?:(?:[0-9a-f]{1,4}:){6}(?::[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){5}(?:(?:(?::[0-9a-f]{1,4}){1,2})|:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){4}(?:(?:(?::[0-9a-f]{1,4}){1,3})|(?:(?::[0-9a-f]{1,4})?:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){3}(?:(?:(?::[0-9a-f]{1,4}){1,4})|(?:(?::[0-9a-f]{1,4}){0,2}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){2}(?:(?:(?::[0-9a-f]{1,4}){1,5})|(?:(?::[0-9a-f]{1,4}){0,3}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){1}(?:(?:(?::[0-9a-f]{1,4}){1,6})|(?:(?::[0-9a-f]{1,4}){0,4}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?::(?:(?:(?::[0-9a-f]{1,4}){1,7})|(?:(?::[0-9a-f]{1,4}){0,5}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(?:%.+)?\s*$/i,
4279
4269
  regex: regex,
4280
4270
  uuid: UUID,
4281
- 'json-pointer': JSON_POINTER,
4271
+ 'json-pointer': JSON_POINTER$1,
4282
4272
  'json-pointer-uri-fragment': JSON_POINTER_URI_FRAGMENT,
4283
- 'relative-json-pointer': RELATIVE_JSON_POINTER
4273
+ 'relative-json-pointer': RELATIVE_JSON_POINTER$1
4284
4274
  };
4285
4275
 
4286
4276
 
@@ -4596,7 +4586,7 @@ var comment = function generate_comment(it, $keyword, $ruleType) {
4596
4586
  var out = ' ';
4597
4587
  var $schema = it.schema[$keyword];
4598
4588
  var $errSchemaPath = it.errSchemaPath + '/' + $keyword;
4599
- !it.opts.allErrors;
4589
+ var $breakOnError = !it.opts.allErrors;
4600
4590
  var $comment = it.util.toQuotedString($schema);
4601
4591
  if (it.opts.$comment === true) {
4602
4592
  out += ' console.log(' + ($comment) + ');';
@@ -6067,7 +6057,7 @@ var pattern = function generate_pattern(it, $keyword, $ruleType) {
6067
6057
  return out;
6068
6058
  };
6069
6059
 
6070
- var properties$2 = function generate_properties(it, $keyword, $ruleType) {
6060
+ var properties = function generate_properties(it, $keyword, $ruleType) {
6071
6061
  var out = ' ';
6072
6062
  var $lvl = it.level;
6073
6063
  var $dataLvl = it.dataLevel;
@@ -6479,7 +6469,7 @@ var propertyNames = function generate_propertyNames(it, $keyword, $ruleType) {
6479
6469
  return out;
6480
6470
  };
6481
6471
 
6482
- var required$1 = function generate_required(it, $keyword, $ruleType) {
6472
+ var required = function generate_required(it, $keyword, $ruleType) {
6483
6473
  var out = ' ';
6484
6474
  var $lvl = it.level;
6485
6475
  var $dataLvl = it.dataLevel;
@@ -6856,17 +6846,16 @@ var dotjs = {
6856
6846
  not: not,
6857
6847
  oneOf: oneOf,
6858
6848
  pattern: pattern,
6859
- properties: properties$2,
6849
+ properties: properties,
6860
6850
  propertyNames: propertyNames,
6861
- required: required$1,
6851
+ required: required,
6862
6852
  uniqueItems: uniqueItems,
6863
- validate: validate$1
6853
+ validate: validate
6864
6854
  };
6865
6855
 
6866
- var ruleModules = dotjs
6867
- , toHash = util$5.toHash;
6856
+ var toHash$1 = util.toHash;
6868
6857
 
6869
- var rules$1 = function rules() {
6858
+ var rules = function rules() {
6870
6859
  var RULES = [
6871
6860
  { type: 'number',
6872
6861
  rules: [ { 'maximum': ['exclusiveMaximum'] },
@@ -6890,8 +6879,8 @@ var rules$1 = function rules() {
6890
6879
  'additionalItems', 'then', 'else'
6891
6880
  ];
6892
6881
  var TYPES = [ 'number', 'integer', 'string', 'array', 'object', 'boolean', 'null' ];
6893
- RULES.all = toHash(ALL);
6894
- RULES.types = toHash(TYPES);
6882
+ RULES.all = toHash$1(ALL);
6883
+ RULES.types = toHash$1(TYPES);
6895
6884
 
6896
6885
  RULES.forEach(function (group) {
6897
6886
  group.rules = group.rules.map(function (keyword) {
@@ -6908,7 +6897,7 @@ var rules$1 = function rules() {
6908
6897
  ALL.push(keyword);
6909
6898
  var rule = RULES.all[keyword] = {
6910
6899
  keyword: keyword,
6911
- code: ruleModules[keyword],
6900
+ code: dotjs[keyword],
6912
6901
  implements: implKeywords
6913
6902
  };
6914
6903
  return rule;
@@ -6916,13 +6905,13 @@ var rules$1 = function rules() {
6916
6905
 
6917
6906
  RULES.all.$comment = {
6918
6907
  keyword: '$comment',
6919
- code: ruleModules.$comment
6908
+ code: dotjs.$comment
6920
6909
  };
6921
6910
 
6922
6911
  if (group.type) RULES.types[group.type] = group;
6923
6912
  });
6924
6913
 
6925
- RULES.keywords = toHash(ALL.concat(KEYWORDS));
6914
+ RULES.keywords = toHash$1(ALL.concat(KEYWORDS));
6926
6915
  RULES.custom = {};
6927
6916
 
6928
6917
  return RULES;
@@ -6976,7 +6965,7 @@ var data = function (metaSchema, keywordsJsonPointers) {
6976
6965
  return metaSchema;
6977
6966
  };
6978
6967
 
6979
- var MissingRefError = error_classes.MissingRef;
6968
+ var MissingRefError$1 = error_classes.MissingRef;
6980
6969
 
6981
6970
  var async = compileAsync;
6982
6971
 
@@ -7029,7 +7018,7 @@ function compileAsync(schema, meta, callback) {
7029
7018
  function _compileAsync(schemaObj) {
7030
7019
  try { return self._compile(schemaObj); }
7031
7020
  catch(e) {
7032
- if (e instanceof MissingRefError) return loadMissingSchema(e);
7021
+ if (e instanceof MissingRefError$1) return loadMissingSchema(e);
7033
7022
  throw e;
7034
7023
  }
7035
7024
 
@@ -7293,10 +7282,10 @@ var custom = function generate_custom(it, $keyword, $ruleType) {
7293
7282
  return out;
7294
7283
  };
7295
7284
 
7296
- var $schema$2 = "http://json-schema.org/draft-07/schema#";
7297
- var $id$1 = "http://json-schema.org/draft-07/schema#";
7285
+ var $schema = "http://json-schema.org/draft-07/schema#";
7286
+ var $id = "http://json-schema.org/draft-07/schema#";
7298
7287
  var title = "Core schema meta-schema";
7299
- var definitions$1 = {
7288
+ var definitions = {
7300
7289
  schemaArray: {
7301
7290
  type: "array",
7302
7291
  minItems: 1,
@@ -7339,7 +7328,7 @@ var definitions$1 = {
7339
7328
  ]
7340
7329
  }
7341
7330
  };
7342
- var type$1 = [
7331
+ var type = [
7343
7332
  "object",
7344
7333
  "boolean"
7345
7334
  ];
@@ -7535,19 +7524,32 @@ var properties$1 = {
7535
7524
  $ref: "#"
7536
7525
  }
7537
7526
  };
7538
- var require$$13 = {
7539
- $schema: $schema$2,
7540
- $id: $id$1,
7527
+ var jsonSchemaDraft07 = {
7528
+ $schema: $schema,
7529
+ $id: $id,
7541
7530
  title: title,
7542
- definitions: definitions$1,
7543
- type: type$1,
7531
+ definitions: definitions,
7532
+ type: type,
7544
7533
  properties: properties$1,
7545
7534
  "default": true
7546
7535
  };
7547
7536
 
7548
- var IDENTIFIER = /^[a-z_$][a-z0-9_$-]*$/i;
7549
- var customRuleCode = custom;
7550
- var metaSchema = require$$13;
7537
+ var jsonSchemaDraft07$1 = /*#__PURE__*/Object.freeze({
7538
+ __proto__: null,
7539
+ $schema: $schema,
7540
+ $id: $id,
7541
+ title: title,
7542
+ definitions: definitions,
7543
+ type: type,
7544
+ properties: properties$1,
7545
+ 'default': jsonSchemaDraft07
7546
+ });
7547
+
7548
+ var require$$2 = getCjsExportFromNamespace(jsonSchemaDraft07$1);
7549
+
7550
+ var IDENTIFIER$1 = /^[a-z_$][a-z0-9_$-]*$/i;
7551
+
7552
+ var metaSchema = require$$2;
7551
7553
 
7552
7554
  var keyword = {
7553
7555
  add: addKeyword,
@@ -7603,7 +7605,7 @@ function addKeyword(keyword, definition) {
7603
7605
  if (RULES.keywords[keyword])
7604
7606
  throw new Error('Keyword ' + keyword + ' is already defined');
7605
7607
 
7606
- if (!IDENTIFIER.test(keyword))
7608
+ if (!IDENTIFIER$1.test(keyword))
7607
7609
  throw new Error('Keyword ' + keyword + ' is not a valid identifier');
7608
7610
 
7609
7611
  if (definition) {
@@ -7653,7 +7655,7 @@ function addKeyword(keyword, definition) {
7653
7655
  keyword: keyword,
7654
7656
  definition: definition,
7655
7657
  custom: true,
7656
- code: customRuleCode,
7658
+ code: custom,
7657
7659
  implements: definition.implements
7658
7660
  };
7659
7661
  ruleGroup.rules.push(rule);
@@ -7723,13 +7725,13 @@ function validateKeyword(definition, throwError) {
7723
7725
  }
7724
7726
 
7725
7727
  var $schema$1 = "http://json-schema.org/draft-07/schema#";
7726
- var $id = "https://raw.githubusercontent.com/epoberezkin/ajv/master/lib/refs/data.json#";
7728
+ var $id$1 = "https://raw.githubusercontent.com/epoberezkin/ajv/master/lib/refs/data.json#";
7727
7729
  var description = "Meta-schema for $data reference (JSON Schema extension proposal)";
7728
- var type = "object";
7729
- var required = [
7730
+ var type$1 = "object";
7731
+ var required$1 = [
7730
7732
  "$data"
7731
7733
  ];
7732
- var properties = {
7734
+ var properties$2 = {
7733
7735
  $data: {
7734
7736
  type: "string",
7735
7737
  anyOf: [
@@ -7743,52 +7745,56 @@ var properties = {
7743
7745
  }
7744
7746
  };
7745
7747
  var additionalProperties = false;
7746
- var require$$12 = {
7748
+ var data$1 = {
7747
7749
  $schema: $schema$1,
7748
- $id: $id,
7750
+ $id: $id$1,
7749
7751
  description: description,
7750
- type: type,
7751
- required: required,
7752
- properties: properties,
7752
+ type: type$1,
7753
+ required: required$1,
7754
+ properties: properties$2,
7753
7755
  additionalProperties: additionalProperties
7754
7756
  };
7755
7757
 
7756
- var compileSchema = compile_1
7757
- , resolve = resolve_1
7758
- , Cache = cache.exports
7759
- , SchemaObject = schema_obj
7760
- , stableStringify = fastJsonStableStringify
7761
- , formats = formats_1
7762
- , rules = rules$1
7763
- , $dataMetaSchema = data
7764
- , util = util$5;
7765
-
7766
- var ajv = Ajv$1;
7767
-
7768
- Ajv$1.prototype.validate = validate;
7769
- Ajv$1.prototype.compile = compile;
7770
- Ajv$1.prototype.addSchema = addSchema;
7771
- Ajv$1.prototype.addMetaSchema = addMetaSchema;
7772
- Ajv$1.prototype.validateSchema = validateSchema;
7773
- Ajv$1.prototype.getSchema = getSchema;
7774
- Ajv$1.prototype.removeSchema = removeSchema;
7775
- Ajv$1.prototype.addFormat = addFormat;
7776
- Ajv$1.prototype.errorsText = errorsText;
7777
-
7778
- Ajv$1.prototype._addSchema = _addSchema;
7779
- Ajv$1.prototype._compile = _compile;
7780
-
7781
- Ajv$1.prototype.compileAsync = async;
7782
- var customKeyword = keyword;
7783
- Ajv$1.prototype.addKeyword = customKeyword.add;
7784
- Ajv$1.prototype.getKeyword = customKeyword.get;
7785
- Ajv$1.prototype.removeKeyword = customKeyword.remove;
7786
- Ajv$1.prototype.validateKeyword = customKeyword.validate;
7787
-
7788
- var errorClasses = error_classes;
7789
- Ajv$1.ValidationError = errorClasses.Validation;
7790
- Ajv$1.MissingRefError = errorClasses.MissingRef;
7791
- Ajv$1.$dataMetaSchema = $dataMetaSchema;
7758
+ var data$2 = /*#__PURE__*/Object.freeze({
7759
+ __proto__: null,
7760
+ $schema: $schema$1,
7761
+ $id: $id$1,
7762
+ description: description,
7763
+ type: type$1,
7764
+ required: required$1,
7765
+ properties: properties$2,
7766
+ additionalProperties: additionalProperties,
7767
+ 'default': data$1
7768
+ });
7769
+
7770
+ var require$$1 = getCjsExportFromNamespace(data$2);
7771
+
7772
+ var ajv = Ajv;
7773
+
7774
+ Ajv.prototype.validate = validate$1;
7775
+ Ajv.prototype.compile = compile$1;
7776
+ Ajv.prototype.addSchema = addSchema;
7777
+ Ajv.prototype.addMetaSchema = addMetaSchema;
7778
+ Ajv.prototype.validateSchema = validateSchema;
7779
+ Ajv.prototype.getSchema = getSchema;
7780
+ Ajv.prototype.removeSchema = removeSchema;
7781
+ Ajv.prototype.addFormat = addFormat;
7782
+ Ajv.prototype.errorsText = errorsText;
7783
+
7784
+ Ajv.prototype._addSchema = _addSchema;
7785
+ Ajv.prototype._compile = _compile;
7786
+
7787
+ Ajv.prototype.compileAsync = async;
7788
+
7789
+ Ajv.prototype.addKeyword = keyword.add;
7790
+ Ajv.prototype.getKeyword = keyword.get;
7791
+ Ajv.prototype.removeKeyword = keyword.remove;
7792
+ Ajv.prototype.validateKeyword = keyword.validate;
7793
+
7794
+
7795
+ Ajv.ValidationError = error_classes.Validation;
7796
+ Ajv.MissingRefError = error_classes.MissingRef;
7797
+ Ajv.$dataMetaSchema = data;
7792
7798
 
7793
7799
  var META_SCHEMA_ID = 'http://json-schema.org/draft-07/schema';
7794
7800
 
@@ -7801,16 +7807,16 @@ var META_SUPPORT_DATA = ['/properties'];
7801
7807
  * @param {Object} opts optional options
7802
7808
  * @return {Object} ajv instance
7803
7809
  */
7804
- function Ajv$1(opts) {
7805
- if (!(this instanceof Ajv$1)) return new Ajv$1(opts);
7810
+ function Ajv(opts) {
7811
+ if (!(this instanceof Ajv)) return new Ajv(opts);
7806
7812
  opts = this._opts = util.copy(opts) || {};
7807
7813
  setLogger(this);
7808
7814
  this._schemas = {};
7809
7815
  this._refs = {};
7810
7816
  this._fragments = {};
7811
- this._formats = formats(opts.format);
7817
+ this._formats = formats_1(opts.format);
7812
7818
 
7813
- this._cache = opts.cache || new Cache;
7819
+ this._cache = opts.cache || new cache;
7814
7820
  this._loadingSchemas = {};
7815
7821
  this._compilations = [];
7816
7822
  this.RULES = rules();
@@ -7818,7 +7824,7 @@ function Ajv$1(opts) {
7818
7824
 
7819
7825
  opts.loopRequired = opts.loopRequired || Infinity;
7820
7826
  if (opts.errorDataPath == 'property') opts._errorDataPathProperty = true;
7821
- if (opts.serialize === undefined) opts.serialize = stableStringify;
7827
+ if (opts.serialize === undefined) opts.serialize = fastJsonStableStringify;
7822
7828
  this._metaOpts = getMetaSchemaOptions(this);
7823
7829
 
7824
7830
  if (opts.formats) addInitialFormats(this);
@@ -7838,7 +7844,7 @@ function Ajv$1(opts) {
7838
7844
  * @param {Any} data to be validated
7839
7845
  * @return {Boolean} validation result. Errors from the last validation will be available in `ajv.errors` (and also in compiled schema: `schema.errors`).
7840
7846
  */
7841
- function validate(schemaKeyRef, data) {
7847
+ function validate$1(schemaKeyRef, data) {
7842
7848
  var v;
7843
7849
  if (typeof schemaKeyRef == 'string') {
7844
7850
  v = this.getSchema(schemaKeyRef);
@@ -7861,7 +7867,7 @@ function validate(schemaKeyRef, data) {
7861
7867
  * @param {Boolean} _meta true if schema is a meta-schema. Used internally to compile meta schemas of custom keywords.
7862
7868
  * @return {Function} validating function
7863
7869
  */
7864
- function compile(schema, _meta) {
7870
+ function compile$1(schema, _meta) {
7865
7871
  var schemaObj = this._addSchema(schema, undefined, _meta);
7866
7872
  return schemaObj.validate || this._compile(schemaObj);
7867
7873
  }
@@ -7884,7 +7890,7 @@ function addSchema(schema, key, _skipValidation, _meta) {
7884
7890
  var id = this._getId(schema);
7885
7891
  if (id !== undefined && typeof id != 'string')
7886
7892
  throw new Error('schema id must be string');
7887
- key = resolve.normalizeId(key || id);
7893
+ key = resolve_1.normalizeId(key || id);
7888
7894
  checkUnique(this, key);
7889
7895
  this._schemas[key] = this._addSchema(schema, _skipValidation, _meta, true);
7890
7896
  return this;
@@ -7961,13 +7967,13 @@ function getSchema(keyRef) {
7961
7967
 
7962
7968
 
7963
7969
  function _getSchemaFragment(self, ref) {
7964
- var res = resolve.schema.call(self, { schema: {} }, ref);
7970
+ var res = resolve_1.schema.call(self, { schema: {} }, ref);
7965
7971
  if (res) {
7966
7972
  var schema = res.schema
7967
7973
  , root = res.root
7968
7974
  , baseId = res.baseId;
7969
- var v = compileSchema.call(self, schema, root, undefined, baseId);
7970
- self._fragments[ref] = new SchemaObject({
7975
+ var v = compile_1.call(self, schema, root, undefined, baseId);
7976
+ self._fragments[ref] = new schema_obj({
7971
7977
  ref: ref,
7972
7978
  fragment: true,
7973
7979
  schema: schema,
@@ -7981,7 +7987,7 @@ function _getSchemaFragment(self, ref) {
7981
7987
 
7982
7988
 
7983
7989
  function _getSchemaObj(self, keyRef) {
7984
- keyRef = resolve.normalizeId(keyRef);
7990
+ keyRef = resolve_1.normalizeId(keyRef);
7985
7991
  return self._schemas[keyRef] || self._refs[keyRef] || self._fragments[keyRef];
7986
7992
  }
7987
7993
 
@@ -8019,7 +8025,7 @@ function removeSchema(schemaKeyRef) {
8019
8025
  this._cache.del(cacheKey);
8020
8026
  var id = this._getId(schemaKeyRef);
8021
8027
  if (id) {
8022
- id = resolve.normalizeId(id);
8028
+ id = resolve_1.normalizeId(id);
8023
8029
  delete this._schemas[id];
8024
8030
  delete this._refs[id];
8025
8031
  }
@@ -8050,17 +8056,17 @@ function _addSchema(schema, skipValidation, meta, shouldAddSchema) {
8050
8056
 
8051
8057
  shouldAddSchema = shouldAddSchema || this._opts.addUsedSchema !== false;
8052
8058
 
8053
- var id = resolve.normalizeId(this._getId(schema));
8059
+ var id = resolve_1.normalizeId(this._getId(schema));
8054
8060
  if (id && shouldAddSchema) checkUnique(this, id);
8055
8061
 
8056
8062
  var willValidate = this._opts.validateSchema !== false && !skipValidation;
8057
8063
  var recursiveMeta;
8058
- if (willValidate && !(recursiveMeta = id && id == resolve.normalizeId(schema.$schema)))
8064
+ if (willValidate && !(recursiveMeta = id && id == resolve_1.normalizeId(schema.$schema)))
8059
8065
  this.validateSchema(schema, true);
8060
8066
 
8061
- var localRefs = resolve.ids.call(this, schema);
8067
+ var localRefs = resolve_1.ids.call(this, schema);
8062
8068
 
8063
- var schemaObj = new SchemaObject({
8069
+ var schemaObj = new schema_obj({
8064
8070
  id: id,
8065
8071
  schema: schema,
8066
8072
  localRefs: localRefs,
@@ -8097,7 +8103,7 @@ function _compile(schemaObj, root) {
8097
8103
  }
8098
8104
 
8099
8105
  var v;
8100
- try { v = compileSchema.call(this, schemaObj.schema, root, schemaObj.localRefs); }
8106
+ try { v = compile_1.call(this, schemaObj.schema, root, schemaObj.localRefs); }
8101
8107
  catch(e) {
8102
8108
  delete schemaObj.validate;
8103
8109
  throw e;
@@ -8193,12 +8199,12 @@ function addFormat(name, format) {
8193
8199
  function addDefaultMetaSchema(self) {
8194
8200
  var $dataSchema;
8195
8201
  if (self._opts.$data) {
8196
- $dataSchema = require$$12;
8202
+ $dataSchema = require$$1;
8197
8203
  self.addMetaSchema($dataSchema, $dataSchema.$id, true);
8198
8204
  }
8199
8205
  if (self._opts.meta === false) return;
8200
- var metaSchema = require$$13;
8201
- if (self._opts.$data) metaSchema = $dataMetaSchema(metaSchema, META_SUPPORT_DATA);
8206
+ var metaSchema = require$$2;
8207
+ if (self._opts.$data) metaSchema = data(metaSchema, META_SUPPORT_DATA);
8202
8208
  self.addMetaSchema(metaSchema, META_SCHEMA_ID, true);
8203
8209
  self._refs['http://json-schema.org/schema'] = META_SCHEMA_ID;
8204
8210
  }
@@ -8249,14 +8255,14 @@ function setLogger(self) {
8249
8255
 
8250
8256
  function noop() {}
8251
8257
 
8252
- var _Ajv = /*#__PURE__*/Object.freeze(/*#__PURE__*/_mergeNamespaces({
8253
- __proto__: null,
8254
- 'default': ajv
8255
- }, [ajv]));
8258
+ var _Ajv = /*#__PURE__*/Object.freeze(/*#__PURE__*/Object.assign(/*#__PURE__*/Object.create(null), ajv, {
8259
+ 'default': ajv,
8260
+ __moduleExports: ajv
8261
+ }));
8256
8262
 
8257
8263
  var $ref = "#/definitions/Schema";
8258
- var $schema = "http://json-schema.org/draft-07/schema#";
8259
- var definitions = {
8264
+ var $schema$2 = "http://json-schema.org/draft-07/schema#";
8265
+ var definitions$1 = {
8260
8266
  ActivityType: {
8261
8267
  anyOf: [
8262
8268
  {
@@ -9899,21 +9905,21 @@ var definitions = {
9899
9905
  type: "string"
9900
9906
  }
9901
9907
  };
9902
- var v2 = {
9908
+ var v2$1 = {
9903
9909
  $ref: $ref,
9904
- $schema: $schema,
9905
- definitions: definitions
9910
+ $schema: $schema$2,
9911
+ definitions: definitions$1
9906
9912
  };
9907
9913
 
9908
9914
  var _ddl2Schema = /*#__PURE__*/Object.freeze({
9909
9915
  __proto__: null,
9910
9916
  $ref: $ref,
9911
- $schema: $schema,
9912
- definitions: definitions,
9913
- 'default': v2
9917
+ $schema: $schema$2,
9918
+ definitions: definitions$1,
9919
+ 'default': v2$1
9914
9920
  });
9915
9921
 
9916
- var Ajv = ajv || _Ajv;
9922
+ var Ajv$1 = ajv || _Ajv;
9917
9923
  var ddl2Schema = _ddl2Schema;
9918
9924
  var options = {
9919
9925
  allErrors: false,
@@ -9921,7 +9927,7 @@ var options = {
9921
9927
  jsonPointers: false
9922
9928
  };
9923
9929
  function doValidate(ddl, schema) {
9924
- var ajv = new Ajv(options);
9930
+ var ajv = new Ajv$1(options);
9925
9931
  var validate = ajv.compile(schema);
9926
9932
  var success = validate(ddl);
9927
9933
  return {
@@ -9937,5 +9943,5 @@ function isDDL2Schema(ref) {
9937
9943
  return ref.version !== undefined && ref.datasources !== undefined && ref.dataviews !== undefined;
9938
9944
  }
9939
9945
 
9940
- export { BUILD_VERSION, v1 as DDL1, v2$1 as DDL2, PKG_NAME, PKG_VERSION, ddl2Schema, isDDL2Schema, upgrade, validate2 };
9946
+ export { BUILD_VERSION, v1 as DDL1, v2 as DDL2, PKG_NAME, PKG_VERSION, ddl2Schema, isDDL2Schema, upgrade$1 as upgrade, validate2 };
9941
9947
  //# sourceMappingURL=index.es6.js.map