@codeleap/types 7.0.1 → 7.0.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.
@@ -1,2 +1,3 @@
1
- export {};
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
2
3
  //# sourceMappingURL=appSettings.js.map
package/dist/common.js CHANGED
@@ -1,2 +1,3 @@
1
- export {};
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
2
3
  //# sourceMappingURL=common.js.map
@@ -1,2 +1,3 @@
1
- export {};
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
2
3
  //# sourceMappingURL=google-places.js.map
package/dist/index.js CHANGED
@@ -1,8 +1,47 @@
1
- export * from './google-places';
2
- export * from './pathMapping';
3
- export * from './utility';
4
- export * from './common';
5
- export * as TypeGuards from './typeGuards';
6
- export * from './appSettings';
7
- export * as RNMaskedTextTypes from './react-native-masked-text';
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
19
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
20
+ };
21
+ var __importStar = (this && this.__importStar) || (function () {
22
+ var ownKeys = function(o) {
23
+ ownKeys = Object.getOwnPropertyNames || function (o) {
24
+ var ar = [];
25
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
26
+ return ar;
27
+ };
28
+ return ownKeys(o);
29
+ };
30
+ return function (mod) {
31
+ if (mod && mod.__esModule) return mod;
32
+ var result = {};
33
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
34
+ __setModuleDefault(result, mod);
35
+ return result;
36
+ };
37
+ })();
38
+ Object.defineProperty(exports, "__esModule", { value: true });
39
+ exports.RNMaskedTextTypes = exports.TypeGuards = void 0;
40
+ __exportStar(require("./google-places"), exports);
41
+ __exportStar(require("./pathMapping"), exports);
42
+ __exportStar(require("./utility"), exports);
43
+ __exportStar(require("./common"), exports);
44
+ exports.TypeGuards = __importStar(require("./typeGuards"));
45
+ __exportStar(require("./appSettings"), exports);
46
+ exports.RNMaskedTextTypes = __importStar(require("./react-native-masked-text"));
8
47
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAA;AAC/B,cAAc,eAAe,CAAA;AAC7B,cAAc,WAAW,CAAA;AACzB,cAAc,UAAU,CAAA;AACxB,OAAO,KAAK,UAAU,MAAM,cAAc,CAAA;AAC1C,cAAc,eAAe,CAAA;AAC7B,OAAO,KAAK,iBAAiB,MAAM,4BAA4B,CAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,kDAA+B;AAC/B,gDAA6B;AAC7B,4CAAyB;AACzB,2CAAwB;AACxB,2DAA0C;AAC1C,gDAA6B;AAC7B,gFAA+D"}
@@ -1,2 +1,3 @@
1
- export {};
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
2
3
  //# sourceMappingURL=pathMapping.js.map
@@ -1,2 +1,3 @@
1
- export {};
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
2
3
  //# sourceMappingURL=react-native-masked-text.js.map
@@ -1,54 +1,74 @@
1
- import React from 'react';
2
- export function isNumber(x) {
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.isNumber = isNumber;
7
+ exports.isString = isString;
8
+ exports.isObject = isObject;
9
+ exports.isBoolean = isBoolean;
10
+ exports.isFunction = isFunction;
11
+ exports.isConstructor = isConstructor;
12
+ exports.isArray = isArray;
13
+ exports.isUndefined = isUndefined;
14
+ exports.isNull = isNull;
15
+ exports.isNil = isNil;
16
+ exports.is = is;
17
+ exports.isInstance = isInstance;
18
+ exports.isElement = isElement;
19
+ exports.isComponentOrElement = isComponentOrElement;
20
+ exports.isPromise = isPromise;
21
+ const react_1 = __importDefault(require("react"));
22
+ function isNumber(x) {
3
23
  return typeof x === 'number';
4
24
  }
5
- export function isString(x) {
25
+ function isString(x) {
6
26
  return typeof x === 'string';
7
27
  }
8
28
  /** Returns `true` for any value whose `typeof` is `'object'`, including `null`. Pair with `isNil` when null must be excluded. */
9
- export function isObject(x) {
29
+ function isObject(x) {
10
30
  return typeof x === 'object';
11
31
  }
12
- export function isBoolean(x) {
32
+ function isBoolean(x) {
13
33
  return typeof x === 'boolean';
14
34
  }
15
- export function isFunction(x) {
35
+ function isFunction(x) {
16
36
  return typeof x === 'function';
17
37
  }
18
38
  /** Checks callable shape only — does not distinguish between regular functions and class constructors. Use `isConstructor` when the `new` signature matters. */
19
- export function isConstructor(x) {
39
+ function isConstructor(x) {
20
40
  return typeof x === 'function';
21
41
  }
22
- export function isArray(x) {
42
+ function isArray(x) {
23
43
  return Array.isArray(x);
24
44
  }
25
- export function isUndefined(x) {
45
+ function isUndefined(x) {
26
46
  return typeof x === 'undefined';
27
47
  }
28
- export function isNull(x) {
48
+ function isNull(x) {
29
49
  return x === null;
30
50
  }
31
- export function isNil(x) {
51
+ function isNil(x) {
32
52
  return isNull(x) || isUndefined(x);
33
53
  }
34
54
  /** Checks membership of `x` in the `Enum` array — useful for narrowing to a specific string/number literal union at runtime. */
35
- export function is(x, Enum) {
55
+ function is(x, Enum) {
36
56
  return Enum.includes(x);
37
57
  }
38
58
  /** Works for both concrete classes and abstract classes via the `Abstract<T>` branch. */
39
- export function isInstance(x, cls) {
59
+ function isInstance(x, cls) {
40
60
  return x instanceof cls;
41
61
  }
42
62
  /** Delegates to `React.isValidElement` — returns `true` for JSX elements but `false` for plain components (functions/classes). */
43
- export function isElement(x) {
44
- return React.isValidElement(x);
63
+ function isElement(x) {
64
+ return react_1.default.isValidElement(x);
45
65
  }
46
66
  /** Accepts both a component type (function/class) and a rendered element — use when a prop can receive either form. */
47
- export function isComponentOrElement(x) {
67
+ function isComponentOrElement(x) {
48
68
  return isFunction(x) || isElement(x);
49
69
  }
50
70
  /** Duck-types against `.then` and `.catch` rather than `instanceof Promise`, so it works across realms and custom thenables. */
51
- export function isPromise(x) {
71
+ function isPromise(x) {
52
72
  return isFunction(x === null || x === void 0 ? void 0 : x.then) && isFunction(x === null || x === void 0 ? void 0 : x.catch);
53
73
  }
54
74
  //# sourceMappingURL=typeGuards.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"typeGuards.js","sourceRoot":"","sources":["../src/typeGuards.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,MAAM,UAAU,QAAQ,CAAC,CAAU;IACjC,OAAO,OAAO,CAAC,KAAK,QAAQ,CAAA;AAC9B,CAAC;AAED,MAAM,UAAU,QAAQ,CAAC,CAAU;IACjC,OAAO,OAAO,CAAC,KAAK,QAAQ,CAAA;AAC9B,CAAC;AAED,iIAAiI;AACjI,MAAM,UAAU,QAAQ,CAAC,CAAU;IACj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M,CAAC,CAAU;IAC/B,OAAO,CAAC,KAAK,IAAI,CAAA;AACnB,CAAC;AAED,SAAgB,KAAK,CAAC,CAAU;IAC9B,OAAO,MAAM,CAAC,CAAC,CAAC,IAAI,WAAW,CAAC,CAAC,CAAC,CAAA;AACpC,CAAC;AAED,gIAAgI;AAChI,SAAgB,EAAE,CAAK,CAAU,EAAE,IAAS;IAC1C,OAAO,IAAI,CAAC,QAAQ,CAAC,CAAM,CAAC,CAAA;AAC9B,CAAC;AAMD,yFAAyF;AACzF,SAAgB,UAAU,CAA4D,CAAU,EAAE,GAAM;IACtG,OAAO,CAAC,YAAa,GAAsB,CAAA;AAC7C,CAAC;AAED,kIAAkI;AAClI,SAAgB,SAAS,CAAC,CAAU;IAClC,OAAO,eAAK,CAAC,cAAc,CAAC,CAAC,CAAC,CAAA;AAChC,CAAC;AAED,uHAAuH;AACvH,SAAgB,oBAAoB,CAAI,CAAM;IAC5C,OAAO,UAAU,CAAC,CAAC,CAAC,IAAI,SAAS,CAAC,CAAC,CAAC,CAAA;AACtC,CAAC;AAED,gIAAgI;AAChI,SAAgB,SAAS,CAAC,CAAU;IAClC,OAAO,UAAU,CAAE,CAAS,aAAT,CAAC,uBAAD,CAAC,CAAU,IAAI,CAAC,IAAI,UAAU,CAAE,CAAS,aAAT,CAAC,uBAAD,CAAC,CAAU,KAAK,CAAC,CAAA;AACtE,CAAC"}
package/dist/utility.js CHANGED
@@ -1,2 +1,3 @@
1
- export {};
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
2
3
  //# sourceMappingURL=utility.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@codeleap/types",
3
- "version": "7.0.1",
3
+ "version": "7.0.2",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "exports": {