inferred-types 0.55.0 → 0.55.2

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.
@@ -18,8 +18,8 @@ var __copyProps = (to, from, except, desc) => {
18
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
19
 
20
20
  // src/index.ts
21
- var src_exports = {};
22
- __export(src_exports, {
21
+ var index_exports = {};
22
+ __export(index_exports, {
23
23
  ACCELERATION_METRICS_LOOKUP: () => ACCELERATION_METRICS_LOOKUP,
24
24
  ALPHA_CHARS: () => ALPHA_CHARS,
25
25
  AMAZON_BOOKS: () => AMAZON_BOOKS,
@@ -208,7 +208,7 @@ __export(src_exports, {
208
208
  ZIP_TO_STATE: () => ZIP_TO_STATE,
209
209
  createConstant: () => createConstant
210
210
  });
211
- module.exports = __toCommonJS(src_exports);
211
+ module.exports = __toCommonJS(index_exports);
212
212
 
213
213
  // src/Alpha.ts
214
214
  var LOWER_ALPHA_CHARS = [
@@ -18,8 +18,8 @@ var __copyProps = (to, from, except, desc) => {
18
18
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
19
 
20
20
  // src/index.ts
21
- var src_exports = {};
22
- __export(src_exports, {
21
+ var index_exports = {};
22
+ __export(index_exports, {
23
23
  ACCELERATION_METRICS_LOOKUP: () => ACCELERATION_METRICS_LOOKUP,
24
24
  ALPHA_CHARS: () => ALPHA_CHARS,
25
25
  AMAZON_BOOKS: () => AMAZON_BOOKS,
@@ -381,6 +381,7 @@ __export(src_exports, {
381
381
  isDutchNewsUrl: () => isDutchNewsUrl,
382
382
  isEbayUrl: () => isEbayUrl,
383
383
  isEmail: () => isEmail,
384
+ isEmpty: () => isEmpty,
384
385
  isEnergyMetric: () => isEnergyMetric,
385
386
  isEnergyUom: () => isEnergyUom,
386
387
  isEqual: () => isEqual,
@@ -681,7 +682,7 @@ __export(src_exports, {
681
682
  youtubeEmbed: () => youtubeEmbed,
682
683
  youtubeMeta: () => youtubeMeta
683
684
  });
684
- module.exports = __toCommonJS(src_exports);
685
+ module.exports = __toCommonJS(index_exports);
685
686
 
686
687
  // ../constants/dist/index.js
687
688
  var LOWER_ALPHA_CHARS = [
@@ -6103,6 +6104,9 @@ function intersect(value, _intersectedWith) {
6103
6104
  return value;
6104
6105
  }
6105
6106
  function stripTrailing(content, ...strip2) {
6107
+ if (isUndefined(content)) {
6108
+ return void 0;
6109
+ }
6106
6110
  let output = String(content);
6107
6111
  for (const s of strip2) {
6108
6112
  if (output.endsWith(String(s))) {
@@ -6344,6 +6348,9 @@ function isEmail(val) {
6344
6348
  const firstChar = val[0].toLowerCase();
6345
6349
  return isString(val) && (LOWER_ALPHA_CHARS2.includes(firstChar) && parts.length === 2 && domain.length >= 1 && tld.length >= 2);
6346
6350
  }
6351
+ function isEmpty(val) {
6352
+ return isUndefined(val) || isNull(val) || isString(val) && val.length === 0 || isObject(val) && Object.keys(val).length === 0 || isArray(val) && val.length === 0;
6353
+ }
6347
6354
  function isErrorCondition(value, kind = null) {
6348
6355
  return isObject(value) && "__kind" in value && value.__kind === "ErrorCondition" && "kind" in value ? kind !== null ? value.kind === kind : true : false;
6349
6356
  }
@@ -7256,6 +7263,9 @@ function stripChars(content, ...strip2) {
7256
7263
  return chars.filter((c) => !strip2.includes(c)).join("");
7257
7264
  }
7258
7265
  function stripLeading(content, ...strip2) {
7266
+ if (isUndefined(content)) {
7267
+ return void 0;
7268
+ }
7259
7269
  let output = String(content);
7260
7270
  for (const s of strip2) {
7261
7271
  if (output.startsWith(String(s))) {
@@ -8473,6 +8483,7 @@ var ExifSaturation = /* @__PURE__ */ ((ExifSaturation2) => {
8473
8483
  isDutchNewsUrl,
8474
8484
  isEbayUrl,
8475
8485
  isEmail,
8486
+ isEmpty,
8476
8487
  isEnergyMetric,
8477
8488
  isEnergyUom,
8478
8489
  isEqual,