@metamask-previews/geolocation-controller 1.0.0-preview-8bfa290fb → 2.0.0-preview-0a30e47

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.
Files changed (64) hide show
  1. package/CHANGELOG.md +15 -1
  2. package/dist/{GeolocationController-method-action-types.d.mts → GeolocationController-method-action-types.d.ts} +2 -2
  3. package/dist/GeolocationController-method-action-types.d.ts.map +1 -0
  4. package/dist/{GeolocationController-method-action-types.mjs → GeolocationController-method-action-types.js} +1 -1
  5. package/dist/GeolocationController-method-action-types.js.map +1 -0
  6. package/dist/{GeolocationController.d.cts → GeolocationController.d.ts} +8 -8
  7. package/dist/GeolocationController.d.ts.map +1 -0
  8. package/dist/{GeolocationController.mjs → GeolocationController.js} +40 -48
  9. package/dist/GeolocationController.js.map +1 -0
  10. package/dist/geolocation-api-service/{geolocation-api-service-method-action-types.d.cts → geolocation-api-service-method-action-types.d.ts} +2 -2
  11. package/dist/geolocation-api-service/geolocation-api-service-method-action-types.d.ts.map +1 -0
  12. package/dist/geolocation-api-service/{geolocation-api-service-method-action-types.mjs → geolocation-api-service-method-action-types.js} +1 -1
  13. package/dist/geolocation-api-service/geolocation-api-service-method-action-types.js.map +1 -0
  14. package/dist/geolocation-api-service/{geolocation-api-service.d.cts → geolocation-api-service.d.ts} +6 -6
  15. package/dist/geolocation-api-service/geolocation-api-service.d.ts.map +1 -0
  16. package/dist/geolocation-api-service/{geolocation-api-service.mjs → geolocation-api-service.js} +73 -77
  17. package/dist/geolocation-api-service/geolocation-api-service.js.map +1 -0
  18. package/dist/index.d.ts +9 -0
  19. package/dist/index.d.ts.map +1 -0
  20. package/dist/index.js +4 -0
  21. package/dist/index.js.map +1 -0
  22. package/dist/{types.d.mts → types.d.ts} +1 -1
  23. package/dist/types.d.ts.map +1 -0
  24. package/dist/{types.mjs → types.js} +1 -1
  25. package/dist/types.js.map +1 -0
  26. package/package.json +15 -19
  27. package/dist/GeolocationController-method-action-types.cjs +0 -7
  28. package/dist/GeolocationController-method-action-types.cjs.map +0 -1
  29. package/dist/GeolocationController-method-action-types.d.cts +0 -54
  30. package/dist/GeolocationController-method-action-types.d.cts.map +0 -1
  31. package/dist/GeolocationController-method-action-types.d.mts.map +0 -1
  32. package/dist/GeolocationController-method-action-types.mjs.map +0 -1
  33. package/dist/GeolocationController.cjs +0 -214
  34. package/dist/GeolocationController.cjs.map +0 -1
  35. package/dist/GeolocationController.d.cts.map +0 -1
  36. package/dist/GeolocationController.d.mts +0 -140
  37. package/dist/GeolocationController.d.mts.map +0 -1
  38. package/dist/GeolocationController.mjs.map +0 -1
  39. package/dist/geolocation-api-service/geolocation-api-service-method-action-types.cjs +0 -7
  40. package/dist/geolocation-api-service/geolocation-api-service-method-action-types.cjs.map +0 -1
  41. package/dist/geolocation-api-service/geolocation-api-service-method-action-types.d.cts.map +0 -1
  42. package/dist/geolocation-api-service/geolocation-api-service-method-action-types.d.mts +0 -42
  43. package/dist/geolocation-api-service/geolocation-api-service-method-action-types.d.mts.map +0 -1
  44. package/dist/geolocation-api-service/geolocation-api-service-method-action-types.mjs.map +0 -1
  45. package/dist/geolocation-api-service/geolocation-api-service.cjs +0 -305
  46. package/dist/geolocation-api-service/geolocation-api-service.cjs.map +0 -1
  47. package/dist/geolocation-api-service/geolocation-api-service.d.cts.map +0 -1
  48. package/dist/geolocation-api-service/geolocation-api-service.d.mts +0 -175
  49. package/dist/geolocation-api-service/geolocation-api-service.d.mts.map +0 -1
  50. package/dist/geolocation-api-service/geolocation-api-service.mjs.map +0 -1
  51. package/dist/index.cjs +0 -14
  52. package/dist/index.cjs.map +0 -1
  53. package/dist/index.d.cts +0 -9
  54. package/dist/index.d.cts.map +0 -1
  55. package/dist/index.d.mts +0 -9
  56. package/dist/index.d.mts.map +0 -1
  57. package/dist/index.mjs +0 -4
  58. package/dist/index.mjs.map +0 -1
  59. package/dist/types.cjs +0 -13
  60. package/dist/types.cjs.map +0 -1
  61. package/dist/types.d.cts +0 -13
  62. package/dist/types.d.cts.map +0 -1
  63. package/dist/types.d.mts.map +0 -1
  64. package/dist/types.mjs.map +0 -1
package/dist/index.cjs DELETED
@@ -1,14 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.UNKNOWN_LOCATION = exports.toLocationCode = exports.getUnknownGeolocationData = exports.GeolocationApiService = exports.getDefaultGeolocationControllerState = exports.GeolocationController = exports.Env = void 0;
4
- var types_js_1 = require("./types.cjs");
5
- Object.defineProperty(exports, "Env", { enumerable: true, get: function () { return types_js_1.Env; } });
6
- var GeolocationController_js_1 = require("./GeolocationController.cjs");
7
- Object.defineProperty(exports, "GeolocationController", { enumerable: true, get: function () { return GeolocationController_js_1.GeolocationController; } });
8
- Object.defineProperty(exports, "getDefaultGeolocationControllerState", { enumerable: true, get: function () { return GeolocationController_js_1.getDefaultGeolocationControllerState; } });
9
- var geolocation_api_service_js_1 = require("./geolocation-api-service/geolocation-api-service.cjs");
10
- Object.defineProperty(exports, "GeolocationApiService", { enumerable: true, get: function () { return geolocation_api_service_js_1.GeolocationApiService; } });
11
- Object.defineProperty(exports, "getUnknownGeolocationData", { enumerable: true, get: function () { return geolocation_api_service_js_1.getUnknownGeolocationData; } });
12
- Object.defineProperty(exports, "toLocationCode", { enumerable: true, get: function () { return geolocation_api_service_js_1.toLocationCode; } });
13
- Object.defineProperty(exports, "UNKNOWN_LOCATION", { enumerable: true, get: function () { return geolocation_api_service_js_1.UNKNOWN_LOCATION; } });
14
- //# sourceMappingURL=index.cjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.cjs","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AAeA,wCAAiC;AAAxB,+FAAA,GAAG,OAAA;AACZ,wEAGoC;AAFlC,iIAAA,qBAAqB,OAAA;AACrB,gJAAA,oCAAoC,OAAA;AAEtC,oGAK8D;AAJ5D,mIAAA,qBAAqB,OAAA;AACrB,uIAAA,yBAAyB,OAAA;AACzB,4HAAA,cAAc,OAAA;AACd,8HAAA,gBAAgB,OAAA","sourcesContent":["export type {\n GeolocationControllerState,\n GeolocationControllerGetStateAction,\n GeolocationControllerActions,\n GeolocationControllerStateChangeEvent,\n GeolocationControllerEvents,\n GeolocationControllerMessenger,\n GeolocationControllerOptions,\n} from './GeolocationController.js';\nexport type {\n GeolocationControllerGetGeolocationAction,\n GeolocationControllerGetGeolocationDataAction,\n GeolocationControllerRefreshGeolocationAction,\n} from './GeolocationController-method-action-types.js';\nexport type { GeolocationRequestStatus } from './types.js';\nexport { Env } from './types.js';\nexport {\n GeolocationController,\n getDefaultGeolocationControllerState,\n} from './GeolocationController.js';\nexport {\n GeolocationApiService,\n getUnknownGeolocationData,\n toLocationCode,\n UNKNOWN_LOCATION,\n} from './geolocation-api-service/geolocation-api-service.js';\nexport type {\n GeolocationApiServiceMessenger,\n GeolocationApiServiceActions,\n GeolocationApiServiceEvents,\n FetchGeolocationOptions,\n GeolocationData,\n} from './geolocation-api-service/geolocation-api-service.js';\nexport type {\n GeolocationApiServiceFetchGeolocationAction,\n GeolocationApiServiceFetchGeolocationDataAction,\n} from './geolocation-api-service/geolocation-api-service-method-action-types.js';\n"]}
package/dist/index.d.cts DELETED
@@ -1,9 +0,0 @@
1
- export type { GeolocationControllerState, GeolocationControllerGetStateAction, GeolocationControllerActions, GeolocationControllerStateChangeEvent, GeolocationControllerEvents, GeolocationControllerMessenger, GeolocationControllerOptions, } from "./GeolocationController.cjs";
2
- export type { GeolocationControllerGetGeolocationAction, GeolocationControllerGetGeolocationDataAction, GeolocationControllerRefreshGeolocationAction, } from "./GeolocationController-method-action-types.cjs";
3
- export type { GeolocationRequestStatus } from "./types.cjs";
4
- export { Env } from "./types.cjs";
5
- export { GeolocationController, getDefaultGeolocationControllerState, } from "./GeolocationController.cjs";
6
- export { GeolocationApiService, getUnknownGeolocationData, toLocationCode, UNKNOWN_LOCATION, } from "./geolocation-api-service/geolocation-api-service.cjs";
7
- export type { GeolocationApiServiceMessenger, GeolocationApiServiceActions, GeolocationApiServiceEvents, FetchGeolocationOptions, GeolocationData, } from "./geolocation-api-service/geolocation-api-service.cjs";
8
- export type { GeolocationApiServiceFetchGeolocationAction, GeolocationApiServiceFetchGeolocationDataAction, } from "./geolocation-api-service/geolocation-api-service-method-action-types.cjs";
9
- //# sourceMappingURL=index.d.cts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.cts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,0BAA0B,EAC1B,mCAAmC,EACnC,4BAA4B,EAC5B,qCAAqC,EACrC,2BAA2B,EAC3B,8BAA8B,EAC9B,4BAA4B,GAC7B,oCAAmC;AACpC,YAAY,EACV,yCAAyC,EACzC,6CAA6C,EAC7C,6CAA6C,GAC9C,wDAAuD;AACxD,YAAY,EAAE,wBAAwB,EAAE,oBAAmB;AAC3D,OAAO,EAAE,GAAG,EAAE,oBAAmB;AACjC,OAAO,EACL,qBAAqB,EACrB,oCAAoC,GACrC,oCAAmC;AACpC,OAAO,EACL,qBAAqB,EACrB,yBAAyB,EACzB,cAAc,EACd,gBAAgB,GACjB,8DAA6D;AAC9D,YAAY,EACV,8BAA8B,EAC9B,4BAA4B,EAC5B,2BAA2B,EAC3B,uBAAuB,EACvB,eAAe,GAChB,8DAA6D;AAC9D,YAAY,EACV,2CAA2C,EAC3C,+CAA+C,GAChD,kFAAiF"}
package/dist/index.d.mts DELETED
@@ -1,9 +0,0 @@
1
- export type { GeolocationControllerState, GeolocationControllerGetStateAction, GeolocationControllerActions, GeolocationControllerStateChangeEvent, GeolocationControllerEvents, GeolocationControllerMessenger, GeolocationControllerOptions, } from "./GeolocationController.mjs";
2
- export type { GeolocationControllerGetGeolocationAction, GeolocationControllerGetGeolocationDataAction, GeolocationControllerRefreshGeolocationAction, } from "./GeolocationController-method-action-types.mjs";
3
- export type { GeolocationRequestStatus } from "./types.mjs";
4
- export { Env } from "./types.mjs";
5
- export { GeolocationController, getDefaultGeolocationControllerState, } from "./GeolocationController.mjs";
6
- export { GeolocationApiService, getUnknownGeolocationData, toLocationCode, UNKNOWN_LOCATION, } from "./geolocation-api-service/geolocation-api-service.mjs";
7
- export type { GeolocationApiServiceMessenger, GeolocationApiServiceActions, GeolocationApiServiceEvents, FetchGeolocationOptions, GeolocationData, } from "./geolocation-api-service/geolocation-api-service.mjs";
8
- export type { GeolocationApiServiceFetchGeolocationAction, GeolocationApiServiceFetchGeolocationDataAction, } from "./geolocation-api-service/geolocation-api-service-method-action-types.mjs";
9
- //# sourceMappingURL=index.d.mts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,0BAA0B,EAC1B,mCAAmC,EACnC,4BAA4B,EAC5B,qCAAqC,EACrC,2BAA2B,EAC3B,8BAA8B,EAC9B,4BAA4B,GAC7B,oCAAmC;AACpC,YAAY,EACV,yCAAyC,EACzC,6CAA6C,EAC7C,6CAA6C,GAC9C,wDAAuD;AACxD,YAAY,EAAE,wBAAwB,EAAE,oBAAmB;AAC3D,OAAO,EAAE,GAAG,EAAE,oBAAmB;AACjC,OAAO,EACL,qBAAqB,EACrB,oCAAoC,GACrC,oCAAmC;AACpC,OAAO,EACL,qBAAqB,EACrB,yBAAyB,EACzB,cAAc,EACd,gBAAgB,GACjB,8DAA6D;AAC9D,YAAY,EACV,8BAA8B,EAC9B,4BAA4B,EAC5B,2BAA2B,EAC3B,uBAAuB,EACvB,eAAe,GAChB,8DAA6D;AAC9D,YAAY,EACV,2CAA2C,EAC3C,+CAA+C,GAChD,kFAAiF"}
package/dist/index.mjs DELETED
@@ -1,4 +0,0 @@
1
- export { Env } from "./types.mjs";
2
- export { GeolocationController, getDefaultGeolocationControllerState } from "./GeolocationController.mjs";
3
- export { GeolocationApiService, getUnknownGeolocationData, toLocationCode, UNKNOWN_LOCATION } from "./geolocation-api-service/geolocation-api-service.mjs";
4
- //# sourceMappingURL=index.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.mjs","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAeA,OAAO,EAAE,GAAG,EAAE,oBAAmB;AACjC,OAAO,EACL,qBAAqB,EACrB,oCAAoC,EACrC,oCAAmC;AACpC,OAAO,EACL,qBAAqB,EACrB,yBAAyB,EACzB,cAAc,EACd,gBAAgB,EACjB,8DAA6D","sourcesContent":["export type {\n GeolocationControllerState,\n GeolocationControllerGetStateAction,\n GeolocationControllerActions,\n GeolocationControllerStateChangeEvent,\n GeolocationControllerEvents,\n GeolocationControllerMessenger,\n GeolocationControllerOptions,\n} from './GeolocationController.js';\nexport type {\n GeolocationControllerGetGeolocationAction,\n GeolocationControllerGetGeolocationDataAction,\n GeolocationControllerRefreshGeolocationAction,\n} from './GeolocationController-method-action-types.js';\nexport type { GeolocationRequestStatus } from './types.js';\nexport { Env } from './types.js';\nexport {\n GeolocationController,\n getDefaultGeolocationControllerState,\n} from './GeolocationController.js';\nexport {\n GeolocationApiService,\n getUnknownGeolocationData,\n toLocationCode,\n UNKNOWN_LOCATION,\n} from './geolocation-api-service/geolocation-api-service.js';\nexport type {\n GeolocationApiServiceMessenger,\n GeolocationApiServiceActions,\n GeolocationApiServiceEvents,\n FetchGeolocationOptions,\n GeolocationData,\n} from './geolocation-api-service/geolocation-api-service.js';\nexport type {\n GeolocationApiServiceFetchGeolocationAction,\n GeolocationApiServiceFetchGeolocationDataAction,\n} from './geolocation-api-service/geolocation-api-service-method-action-types.js';\n"]}
package/dist/types.cjs DELETED
@@ -1,13 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Env = void 0;
4
- /**
5
- * Deployment environment for API endpoint selection.
6
- */
7
- var Env;
8
- (function (Env) {
9
- Env["DEV"] = "dev";
10
- Env["UAT"] = "uat";
11
- Env["PRD"] = "prd";
12
- })(Env || (exports.Env = Env = {}));
13
- //# sourceMappingURL=types.cjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.cjs","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":";;;AASA;;GAEG;AACH,IAAY,GAIX;AAJD,WAAY,GAAG;IACb,kBAAW,CAAA;IACX,kBAAW,CAAA;IACX,kBAAW,CAAA;AACb,CAAC,EAJW,GAAG,mBAAH,GAAG,QAId","sourcesContent":["/**\n * The status of a geolocation fetch operation.\n */\nexport type GeolocationRequestStatus =\n | 'idle'\n | 'loading'\n | 'complete'\n | 'error';\n\n/**\n * Deployment environment for API endpoint selection.\n */\nexport enum Env {\n DEV = 'dev',\n UAT = 'uat',\n PRD = 'prd',\n}\n"]}
package/dist/types.d.cts DELETED
@@ -1,13 +0,0 @@
1
- /**
2
- * The status of a geolocation fetch operation.
3
- */
4
- export type GeolocationRequestStatus = 'idle' | 'loading' | 'complete' | 'error';
5
- /**
6
- * Deployment environment for API endpoint selection.
7
- */
8
- export declare enum Env {
9
- DEV = "dev",
10
- UAT = "uat",
11
- PRD = "prd"
12
- }
13
- //# sourceMappingURL=types.d.cts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.d.cts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,MAAM,wBAAwB,GAChC,MAAM,GACN,SAAS,GACT,UAAU,GACV,OAAO,CAAC;AAEZ;;GAEG;AACH,oBAAY,GAAG;IACb,GAAG,QAAQ;IACX,GAAG,QAAQ;IACX,GAAG,QAAQ;CACZ"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.d.mts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,MAAM,wBAAwB,GAChC,MAAM,GACN,SAAS,GACT,UAAU,GACV,OAAO,CAAC;AAEZ;;GAEG;AACH,oBAAY,GAAG;IACb,GAAG,QAAQ;IACX,GAAG,QAAQ;IACX,GAAG,QAAQ;CACZ"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.mjs","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AASA;;GAEG;AACH,MAAM,CAAN,IAAY,GAIX;AAJD,WAAY,GAAG;IACb,kBAAW,CAAA;IACX,kBAAW,CAAA;IACX,kBAAW,CAAA;AACb,CAAC,EAJW,GAAG,KAAH,GAAG,QAId","sourcesContent":["/**\n * The status of a geolocation fetch operation.\n */\nexport type GeolocationRequestStatus =\n | 'idle'\n | 'loading'\n | 'complete'\n | 'error';\n\n/**\n * Deployment environment for API endpoint selection.\n */\nexport enum Env {\n DEV = 'dev',\n UAT = 'uat',\n PRD = 'prd',\n}\n"]}