@es-joy/jsoe 0.20.5 → 0.21.0

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.
@@ -1 +1 @@
1
- {"version":3,"file":"buffersourceType.d.ts","sourceRoot":"","sources":["../../src/superTypes/buffersourceType.js"],"names":[],"mappings":";yBA4Da,WAAW,GAAC,YAAY,GAAC,mBAAmB,GACxD,YAAgB,GAAC,aAAa,GAAC,YAAY,GAAC,aAAa,GACzD,cAAkB,GAAC,cAAc,GAAC,eAAe,GACjD,gBAAoB;iCAIR,SAAS,GAAC,UAAU,GAAC,iBAAiB,GAC9C,UAAU,GAAC,WAAW,GAAC,UAAU,GAAC,WAAW,GAC9C,YAAY,GAAC,YAAY,GAAC,aAAa,GACvC,cAAc;AAmDlB;;GAEG;AACH,gCAFU,OAAO,aAAa,EAAE,eAAe,CA02C7C"}
1
+ {"version":3,"file":"buffersourceType.d.ts","sourceRoot":"","sources":["../../src/superTypes/buffersourceType.js"],"names":[],"mappings":";yBA4Da,WAAW,GAAC,YAAY,GAAC,mBAAmB,GACxD,YAAgB,GAAC,aAAa,GAAC,YAAY,GAAC,aAAa,GACzD,cAAkB,GAAC,cAAc,GAAC,eAAe,GACjD,gBAAoB;iCAIR,SAAS,GAAC,UAAU,GAAC,iBAAiB,GAC9C,UAAU,GAAC,WAAW,GAAC,UAAU,GAAC,WAAW,GAC9C,YAAY,GAAC,YAAY,GAAC,aAAa,GACvC,cAAc;AAmDlB;;GAEG;AACH,gCAFU,OAAO,aAAa,EAAE,eAAe,CA22C7C"}
@@ -1 +1 @@
1
- {"version":3,"file":"dommatrixType.d.ts","sourceRoot":"","sources":["../../src/superTypes/dommatrixType.js"],"names":[],"mappings":";AAKA;;GAEG;AACH,6BAFU,OAAO,aAAa,EAAE,eAAe,CAma7C"}
1
+ {"version":3,"file":"dommatrixType.d.ts","sourceRoot":"","sources":["../../src/superTypes/dommatrixType.js"],"names":[],"mappings":";AAKA;;GAEG;AACH,6BAFU,OAAO,aAAa,EAAE,eAAe,CAoa7C"}
@@ -1 +1 @@
1
- {"version":3,"file":"dompointType.d.ts","sourceRoot":"","sources":["../../src/superTypes/dompointType.js"],"names":[],"mappings":";AAKA;;GAEG;AACH,4BAFU,OAAO,aAAa,EAAE,eAAe,CAyK7C"}
1
+ {"version":3,"file":"dompointType.d.ts","sourceRoot":"","sources":["../../src/superTypes/dompointType.js"],"names":[],"mappings":";AAKA;;GAEG;AACH,4BAFU,OAAO,aAAa,EAAE,eAAe,CA0K7C"}
@@ -1 +1 @@
1
- {"version":3,"file":"domrectType.d.ts","sourceRoot":"","sources":["../../src/superTypes/domrectType.js"],"names":[],"mappings":";AAKA;;GAEG;AACH,2BAFU,OAAO,aAAa,EAAE,eAAe,CA8K7C"}
1
+ {"version":3,"file":"domrectType.d.ts","sourceRoot":"","sources":["../../src/superTypes/domrectType.js"],"names":[],"mappings":";AAKA;;GAEG;AACH,2BAFU,OAAO,aAAa,EAAE,eAAe,CA+K7C"}
@@ -1 +1 @@
1
- {"version":3,"file":"errorsSpecialType.d.ts","sourceRoot":"","sources":["../../src/superTypes/errorsSpecialType.js"],"names":[],"mappings":";sBAOa,MAAM;+BAaN,gBAAgB,GAAC,yBAAyB;AAyBvD;;GAEG;AACH,iCAFU,OAAO,aAAa,EAAE,eAAe,CAsuB7C"}
1
+ {"version":3,"file":"errorsSpecialType.d.ts","sourceRoot":"","sources":["../../src/superTypes/errorsSpecialType.js"],"names":[],"mappings":";sBAOa,MAAM;+BAaN,gBAAgB,GAAC,yBAAyB;AAyBvD;;GAEG;AACH,iCAFU,OAAO,aAAa,EAAE,eAAe,CAwuB7C"}
@@ -1 +1 @@
1
- {"version":3,"file":"typeChoices.d.ts","sourceRoot":"","sources":["../src/typeChoices.js"],"names":[],"mappings":"AASA;;;;;;;;GAQG;AAEH;;;;;;GAMG;AAEH;;;;;;;GAOG;AAEH;;GAEG;AAEH;;;;;GAKG;AAEH;;;;;;GAMG;AAEH;;;GAGG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,OAAW,CAAC,EAAE,OAAO,YAAY,EAAE,WAAW,CAAC;IAC/C,OAAW,CAAC,EAAE,OAAO,cAAc,EAAE,OAAO,CAAA;IAC5C,KAAS,CAAC,EAAE,OAAO,YAAY,EAAE,OAAO,CAAA;IACxC,MAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAa,CAAC,EAAE,MAAM,CAAC;IACvB,cAAkB,CAAC,EAAE,OAAO,2BAA2B,EAAE,WAAW,CAAC;IACrE,aAAiB,CAAC,EAAE,OAAO,2BAA2B,EAAE,WAAW,CAAC;CACjE,KACS;IACZ,QAAY,EAAE,CAAC,MAAM,EAAE,WAAW,EAAE,aAAa,EAAE,WAAW,CAAC,CAAC;IAChE,QAAY,EAAE,QAAQ,CAAC;IACvB,OAAW,EAAE,OAAO,CAAC;IACrB,cAAkB,EAAE,cAAc,CAAC;IACnC,QAAY,EAAE,QAAQ,CAAA;CACnB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@es-joy/jsoe",
3
- "version": "0.20.5",
3
+ "version": "0.21.0",
4
4
  "type": "module",
5
5
  "types": "./dist/index.d.ts",
6
6
  "main": "./src/index.js",
@@ -37,18 +37,19 @@
37
37
  "@babel/plugin-transform-modules-commonjs": "^7.24.8",
38
38
  "@babel/preset-env": "^7.25.3",
39
39
  "@babel/register": "^7.24.6",
40
- "@cypress/code-coverage": "^3.12.44",
40
+ "@cypress/code-coverage": "^3.12.45",
41
41
  "@rollup/plugin-babel": "^6.0.4",
42
42
  "@rollup/plugin-commonjs": "^26.0.1",
43
43
  "@rollup/plugin-node-resolve": "^15.2.3",
44
44
  "@types/jsdom": "^21.1.7",
45
- "@types/node": "^22.1.0",
45
+ "@types/node": "^22.5.0",
46
46
  "axe-core": "^4.10.0",
47
47
  "coveradge": "^0.8.2",
48
- "cypress": "^13.13.2",
48
+ "cypress": "^13.13.3",
49
49
  "cypress-axe": "^1.5.0",
50
- "eslint": "^9.8.0",
51
- "eslint-config-ash-nazg": "^36.11.1",
50
+ "cypress-terminal-report": "^6.1.2",
51
+ "eslint": "^9.9.0",
52
+ "eslint-config-ash-nazg": "^36.13.0",
52
53
  "fast-deep-equal": "^3.1.3",
53
54
  "jsdom": "^24.1.1",
54
55
  "license-badger": "^0.21.1",
@@ -56,7 +57,7 @@
56
57
  "nyc": "^17.0.0",
57
58
  "open-cli": "^8.0.0",
58
59
  "rimraf": "^6.0.1",
59
- "rollup": "4.20.0",
60
+ "rollup": "4.21.0",
60
61
  "rollup-plugin-istanbul": "^5.0.0",
61
62
  "rollup-plugin-no-op": "^1.0.2",
62
63
  "rollup-plugin-node-builtins": "^2.1.2",
package/rollup.config.js CHANGED
@@ -10,6 +10,7 @@ export default [{
10
10
  input: 'src/index.js',
11
11
  external: ['react'], // Todo: remove when removed from Zodex
12
12
  output: {
13
+ sourcemap: true,
13
14
  file: 'dist/index.js',
14
15
  format: 'es'
15
16
  },
@@ -70,6 +71,7 @@ export default [{
70
71
  output: {
71
72
  file: 'src/deepEqual.js',
72
73
  format: 'es',
74
+ sourcemap: true,
73
75
  name: 'deepEqual'
74
76
  },
75
77
  plugins: [
package/src/deepEqual.js CHANGED
@@ -70,3 +70,4 @@ var es6 = function equal(a, b) {
70
70
  var index = /*@__PURE__*/getDefaultExportFromCjs(es6);
71
71
 
72
72
  export { index as default };
73
+ //# sourceMappingURL=deepEqual.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"deepEqual.js","sources":["../node_modules/.pnpm/fast-deep-equal@3.1.3/node_modules/fast-deep-equal/es6/index.js"],"sourcesContent":["'use strict';\n\n// do not edit .js files directly - edit src/index.jst\n\n\n var envHasBigInt64Array = typeof BigInt64Array !== 'undefined';\n\n\nmodule.exports = function equal(a, b) {\n if (a === b) return true;\n\n if (a && b && typeof a == 'object' && typeof b == 'object') {\n if (a.constructor !== b.constructor) return false;\n\n var length, i, keys;\n if (Array.isArray(a)) {\n length = a.length;\n if (length != b.length) return false;\n for (i = length; i-- !== 0;)\n if (!equal(a[i], b[i])) return false;\n return true;\n }\n\n\n if ((a instanceof Map) && (b instanceof Map)) {\n if (a.size !== b.size) return false;\n for (i of a.entries())\n if (!b.has(i[0])) return false;\n for (i of a.entries())\n if (!equal(i[1], b.get(i[0]))) return false;\n return true;\n }\n\n if ((a instanceof Set) && (b instanceof Set)) {\n if (a.size !== b.size) return false;\n for (i of a.entries())\n if (!b.has(i[0])) return false;\n return true;\n }\n\n if (ArrayBuffer.isView(a) && ArrayBuffer.isView(b)) {\n length = a.length;\n if (length != b.length) return false;\n for (i = length; i-- !== 0;)\n if (a[i] !== b[i]) return false;\n return true;\n }\n\n\n if (a.constructor === RegExp) return a.source === b.source && a.flags === b.flags;\n if (a.valueOf !== Object.prototype.valueOf) return a.valueOf() === b.valueOf();\n if (a.toString !== Object.prototype.toString) return a.toString() === b.toString();\n\n keys = Object.keys(a);\n length = keys.length;\n if (length !== Object.keys(b).length) return false;\n\n for (i = length; i-- !== 0;)\n if (!Object.prototype.hasOwnProperty.call(b, keys[i])) return false;\n\n for (i = length; i-- !== 0;) {\n var key = keys[i];\n\n if (!equal(a[key], b[key])) return false;\n }\n\n return true;\n }\n\n // true if both NaN, false otherwise\n return a!==a && b!==b;\n};\n"],"names":[],"mappings":";;;;AAQA,IAAA,GAAc,GAAG,SAAS,KAAK,CAAC,CAAC,EAAE,CAAC,EAAE;AACtC,EAAE,IAAI,CAAC,KAAK,CAAC,EAAE,OAAO,IAAI,CAAC;AAC3B;AACA,EAAE,IAAI,CAAC,IAAI,CAAC,IAAI,OAAO,CAAC,IAAI,QAAQ,IAAI,OAAO,CAAC,IAAI,QAAQ,EAAE;AAC9D,IAAI,IAAI,CAAC,CAAC,WAAW,KAAK,CAAC,CAAC,WAAW,EAAE,OAAO,KAAK,CAAC;AACtD;AACA,IAAI,IAAI,MAAM,EAAE,CAAC,EAAE,IAAI,CAAC;AACxB,IAAI,IAAI,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE;AAC1B,MAAM,M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K,CAAC;AAC9B,MAAM,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC,EAAE,OAAO,KAAK,CAAC;AAC1E;AACA,IAAI,KAAK,CAAC,GAAG,MAAM,EAAE,CAAC,EAAE,KAAK,CAAC,GAAG;AACjC,MAAM,IAAI,GAAG,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC;AACxB;AACA,MAAM,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,EAAE,OAAO,KAAK,CAAC;AAC/C,KAAK;AACL;AACA,IAAI,OAAO,IAAI,CAAC;AAChB,GAAG;AACH;AACA;AACA,EAAE,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AACxB,CAAC,CAAA;;;;;;","x_google_ignoreList":[0]}
@@ -182,9 +182,11 @@ export async function formatAndTypeChoices ({
182
182
  requireObject: hasKeyPath,
183
183
  objectHasValue: hasValue,
184
184
  schema,
185
- schemaContent: await getSchemaContent?.(
186
- /** @type {string} */ (schema)
187
- )
185
+ schemaContent: schema
186
+ ? await getSchemaContent?.(
187
+ /** @type {string} */ (schema)
188
+ )
189
+ : undefined
188
190
  }).domArray}, typesHolder);
189
191
  }
190
192
  },
@@ -69,10 +69,12 @@ const zodexToStructuredCloningTypeMap = new Map([
69
69
  * @returns {ZodexSchema}
70
70
  */
71
71
  function mergeSchema (leftItem, rightItem) {
72
+ /* istanbul ignore if -- Guard */
72
73
  if (leftItem.type !== 'object') {
73
74
  console.log('leftItem', leftItem);
74
75
  throw new Error('Unexpected leftItem of type ' + leftItem.type);
75
76
  }
77
+ /* istanbul ignore if -- Guard */
76
78
  if (rightItem.type !== 'object') {
77
79
  console.log('rightItem', rightItem);
78
80
  throw new Error('Unexpected rightItem of type ' + rightItem.type);
@@ -99,6 +101,7 @@ function mergeSchema (leftItem, rightItem) {
99
101
 
100
102
  newLeftObj[prop] = val && typeof val === 'object'
101
103
  ? copyObject(val)
104
+ /* istanbul ignore next -- Guard */
102
105
  : val;
103
106
  }
104
107
  }
@@ -115,9 +118,11 @@ function mergeSchema (leftItem, rightItem) {
115
118
  }
116
119
  /** @type {NestedObject} */ (
117
120
  newLeftObj.properties
118
- )[prop] = val && typeof val === 'object'
119
- ? copyObject(val)
120
- : val;
121
+ )[prop] = /* istanbul ignore next -- Guard */
122
+ val && typeof val === 'object'
123
+ ? copyObject(val)
124
+ /* istanbul ignore next -- Guard */
125
+ : val;
121
126
  }
122
127
 
123
128
  return newLeftObj;
@@ -579,6 +584,7 @@ const schema = {
579
584
  ) {
580
585
  // eslint-disable-next-line prefer-const -- Convenient
581
586
  let [parentSchema, parentSchemaIdx] = parentSchemaInfo ?? [];
587
+ /* istanbul ignore if -- Guard */
582
588
  if (!stateObj) {
583
589
  throw new Error('State object expected for schema');
584
590
  }
@@ -625,12 +631,13 @@ const schema = {
625
631
  parentSchema
626
632
  ).inner;
627
633
  break;
628
- // eslint-disable-next-line sonarjs/no-duplicated-branches -- Maintenance
629
- case 'promise':
630
- currentSchema = /** @type {import('zodex').SzPromise} */ (
631
- parentSchema
632
- ).value;
633
- break;
634
+ // Todo: Reenable
635
+ // // eslint-disable-next-line sonarjs/no-duplicated-branches -- Maintenance
636
+ // case 'promise':
637
+ // currentSchema = /** @type {import('zodex').SzPromise} */ (
638
+ // parentSchema
639
+ // ).value;
640
+ // break;
634
641
  case 'tuple':
635
642
  currentSchema = /** @type {import('zodex').SzTuple} */ (
636
643
  parentSchema
@@ -646,6 +653,8 @@ const schema = {
646
653
  default:
647
654
  break;
648
655
  }
656
+
657
+ /* istanbul ignore if -- Guard */
649
658
  if (!currentSchema) {
650
659
  return {type: typesonType};
651
660
  }
@@ -677,9 +686,6 @@ const schema = {
677
686
  }
678
687
  // console.log('parsed', parsed.success, v, schema);
679
688
  if (parsed.success) {
680
- if (currentSchema.type === 'any' && schema.description) {
681
- schema.description += ' (any)';
682
- }
683
689
  let type = zodexToStructuredCloningTypeMap.get(schema.type);
684
690
  if (!type && schema.type === 'effect') {
685
691
  type = /** @type {import('../types.js').AvailableType} */ (
@@ -721,7 +727,9 @@ const schema = {
721
727
  return {type: typesonType};
722
728
  },
723
729
 
730
+ /* istanbul ignore next -- Not in use */
724
731
  types () {
732
+ /* istanbul ignore next -- Not in use */
725
733
  return structuredCloning.types();
726
734
  },
727
735
 
@@ -111,9 +111,10 @@ const arrayType = {
111
111
  const state = sparse
112
112
  ? 'arrayNonindexKeys'
113
113
  // ? 'sparseArrays'
114
- : (this.array ? 'array' : 'object');
114
+ : (this.array && !this.record ? 'array' : 'object');
115
115
  /** @type {{[key: (string|number)]: any}} */
116
- const retObj = this.array ? [] : {};
116
+ const retObj = this.array && !this.record ? [] : {};
117
+ /* istanbul ignore next -- Unreachable? */
117
118
  let stringVal = innerContents !== undefined
118
119
  ? innerContents
119
120
  /* istanbul ignore next -- Unreachable? */
@@ -140,7 +141,7 @@ const arrayType = {
140
141
  }
141
142
  return false;
142
143
  };
143
- if (this.array) {
144
+ if (this.array && !this.record) {
144
145
  let idx = 0;
145
146
  const parse = () => {
146
147
  if (!stringVal) {
@@ -835,7 +836,11 @@ const arrayType = {
835
836
  input.setCustomValidity(
836
837
  invalidStr
837
838
  );
838
- // input.reportValidity(); // Might not want this as changes focus
839
+ if (invalidStr) {
840
+ // Might not want this as changes focus; if ok, will hopefully be
841
+ // marked as such elsewhere
842
+ input.reportValidity();
843
+ }
839
844
  }
840
845
  return invalidStr; // Don't give a chance to become valid
841
846
  });
@@ -1052,8 +1057,11 @@ const arrayType = {
1052
1057
  ? elementDesc ?? 'Item'
1053
1058
  : {'#': required
1054
1059
  ? [
1055
- ['b', {className, title: description ? propName : undefined}, [
1056
- elementDesc ?? description ?? propName ?? ''
1060
+ ['b', {
1061
+ className,
1062
+ title: (elementDesc ?? description) ? propName : undefined
1063
+ }, [
1064
+ elementDesc ?? description ?? propName
1057
1065
  ]]
1058
1066
  ]
1059
1067
  : [
@@ -1074,6 +1082,7 @@ const arrayType = {
1074
1082
  ]?.description ?? propName
1075
1083
  : /** @type {import('zodex').SzObject} */ (
1076
1084
  specificSchemaObject
1085
+ /* istanbul ignore next -- Guard */
1077
1086
  )?.catchall?.description ?? propName
1078
1087
  ]]
1079
1088
  ]
@@ -1998,6 +2007,7 @@ const arrayType = {
1998
2007
  */
1999
2008
  async change () {
2000
2009
  if (preventAdding()) {
2010
+ /* istanbul ignore next -- Just a guard */
2001
2011
  this.value = this.$oldvalue ?? this.defaultValue;
2002
2012
  return;
2003
2013
  }
@@ -2424,6 +2434,7 @@ const arrayType = {
2424
2434
  Object.entries(
2425
2435
  /** @type {import('zodex').SzObject} */ (
2426
2436
  specificSchemaObject
2437
+ /* istanbul ignore next -- Should always have `properties` */
2427
2438
  ).properties ?? {}
2428
2439
  )
2429
2440
  ) {
@@ -2451,10 +2462,12 @@ const arrayType = {
2451
2462
  }
2452
2463
  }
2453
2464
  break;
2454
- } case 'array': case 'arrayNonindexKeys': {
2465
+ }
2466
+ // case 'array': // None with schemas?
2467
+ case 'arrayNonindexKeys': {
2455
2468
  const {minLength = 0} = /** @type {import('zodex').SzArray} */ (
2456
2469
  specificSchemaObject
2457
- ) ?? {};
2470
+ );
2458
2471
  const arrayLengthInput =
2459
2472
  /** @type {HTMLInputElement & {$oldvalue: string}} */ (
2460
2473
  $e(div, '.arrayLength')
@@ -2471,7 +2484,7 @@ const arrayType = {
2471
2484
  if (!schemaFallingBack) {
2472
2485
  const {minSize = 0} = /** @type {import('zodex').SzSet} */ (
2473
2486
  specificSchemaObject
2474
- ) ?? {};
2487
+ );
2475
2488
  for (let i = 0; i < minSize; i++) {
2476
2489
  div.$addArrayElement({required: true});
2477
2490
  }
@@ -32,7 +32,7 @@ const nativeEnumType = {
32
32
  return {value};
33
33
  },
34
34
  getInput ({root}) {
35
- return /** @type {HTMLTextAreaElement} */ ($e(root, 'input'));
35
+ return /** @type {HTMLTextAreaElement} */ ($e(root, 'input.nativeEnumKey'));
36
36
  },
37
37
  setValue ({root, value}) {
38
38
  const input = /**
@@ -45,9 +45,11 @@ const nativeEnumType = {
45
45
  ).find(([, val]) => {
46
46
  return val === value;
47
47
  })?.[0] ?? '';
48
- /** @type {HTMLSpanElement} */ (
49
- $e(root, '.enumeratedValue')
50
- ).textContent = value;
48
+ if (input.value) { // If key was found, the value is ok
49
+ /** @type {HTMLSpanElement} */ (
50
+ $e(root, '.enumeratedValue')
51
+ ).textContent = value;
52
+ }
51
53
  },
52
54
  getValue ({root}) {
53
55
  const {value, $schemaNativeEnumValues} =
@@ -11,16 +11,11 @@ const neverType = {
11
11
  /* istanbul ignore next -- Back-up in case shows */
12
12
  return false;
13
13
  },
14
- /* istanbul ignore next -- Back-up in case shows */
15
14
  toValue (/* _s */) {
16
- /* istanbul ignore next -- Back-up in case shows */
17
15
  throw new Error('Cannot convert to value');
18
16
  },
19
- /* istanbul ignore next -- Back-up in case shows */
20
17
  getValue () {
21
- /* istanbul ignore next -- Back-up in case shows */
22
18
  return /** @type {import('../types.js').ToValue} */ (
23
- /* istanbul ignore next -- Back-up in case shows */
24
19
  this.toValue
25
20
  )('');
26
21
  },
@@ -136,6 +136,7 @@ const buffersourceType = {
136
136
  return bufferSourceClasses.has(toStringTag(x));
137
137
  },
138
138
  toValue (s, rootInfo) {
139
+ /* istanbul ignore next -- Should always be found */
139
140
  const {groups: {
140
141
  bufferSourceClass
141
142
  /* istanbul ignore next -- Should always be found */
@@ -14,6 +14,7 @@ const dommatrixType = {
14
14
  return ['DOMMatrix', 'DOMMatrixReadOnly'].includes(toStringTag(x));
15
15
  },
16
16
  toValue (s, rootInfo) {
17
+ /* istanbul ignore next -- Should always be found */
17
18
  const {groups: {
18
19
  domMatrixClass
19
20
  /* istanbul ignore next -- Should always be found */
@@ -14,6 +14,7 @@ const dompointType = {
14
14
  return ['DOMPoint', 'DOMPointReadOnly'].includes(toStringTag(x));
15
15
  },
16
16
  toValue (s, rootInfo) {
17
+ /* istanbul ignore next -- Should always be found */
17
18
  const {groups: {
18
19
  domPointClass
19
20
  /* istanbul ignore next -- Should always be found */
@@ -14,6 +14,7 @@ const domrectType = {
14
14
  return ['DOMRect', 'DOMRectReadOnly'].includes(toStringTag(x));
15
15
  },
16
16
  toValue (s, rootInfo) {
17
+ /* istanbul ignore next -- Should always be found */
17
18
  const {groups: {
18
19
  domRectClass
19
20
  /* istanbul ignore next -- Should always be found */
@@ -63,6 +63,7 @@ const errorsSpecialType = {
63
63
  String.raw`)\((?<innerContent>.*)\)$`, 'u'
64
64
  ),
65
65
  toValue (s, rootInfo) {
66
+ /* istanbul ignore next -- Just a guard */
66
67
  const {groups: {
67
68
  errorClass
68
69
  /* istanbul ignore next -- Should always be found */
@@ -366,6 +367,7 @@ const errorsSpecialType = {
366
367
  ).textContent = aggregateErrorsContents.hidden ? '+' : '-';
367
368
  }}}, ['-']],
368
369
  ['div', {class: 'aggregateErrorsContents'}, [
370
+ /* istanbul ignore next -- Just a guard */
369
371
  (o.errors
370
372
  ? (() => {
371
373
  const [div] = arrayType.viewUI({
@@ -170,7 +170,6 @@ export const buildTypeChoices = ({
170
170
  return JSON.stringify(obj);
171
171
  }).indexOf(JSON.stringify(specificSchema));
172
172
  if (idx === -1) {
173
- console.log('schemaObjs', schemaObjs, specificSchema);
174
173
  this.value = type;
175
174
  } else {
176
175
  this.selectedIndex = idx + 1;
@@ -225,8 +224,9 @@ export const buildTypeChoices = ({
225
224
  },
226
225
 
227
226
  /** @type {AddAndValidateEditUI} */
228
- $addAndValidateEditUI ({
227
+ $addAndValidateEditUI (/* istanbul ignore next -- Backup */ {
229
228
  baseValue, bringIntoFocus, schemaObject, avoidReport
229
+ /* istanbul ignore next -- Backup */
230
230
  } = {}) {
231
231
  const {value: type} = this;
232
232
 
@@ -263,8 +263,12 @@ export const buildTypeChoices = ({
263
263
  // Avoid JSON references by using this by default (or only?)
264
264
  (schemaObjs?.[sel.selectedIndex - 1]) ??
265
265
 
266
+ // eslint-disable-next-line @stylistic/max-len -- Long
267
+ /* istanbul ignore next -- Can probably remove as `schemaObjs` will be set */
266
268
  (schemaContent?.type === 'union' && schemaIdx !== undefined
269
+ /* istanbul ignore next -- Can probably remove */
267
270
  ? schemaContent.options[schemaIdx]
271
+ // This is probably just `undefined` by here
268
272
  : schemaContent),
269
273
  schemaFallingBack: Boolean(!schemaObject && schemaContent)
270
274
  });
package/src/types.js CHANGED
@@ -827,7 +827,7 @@ class Types {
827
827
  valid
828
828
  ? ''
829
829
  /* istanbul ignore next -- Should always have a message */
830
- : message || 'Invalid'
830
+ : (message || 'Invalid')
831
831
  );
832
832
 
833
833
  // We don't want a focus as `reportValidity` does in at least