@scayle/omnichannel-nuxt 1.1.19 → 2.0.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.
Files changed (110) hide show
  1. package/CHANGELOG.md +28 -0
  2. package/README.md +23 -35
  3. package/dist/chunks/createOmnichannelHandler.mjs +790 -0
  4. package/dist/index.d.mts +40 -0
  5. package/dist/index.d.ts +40 -9
  6. package/dist/index.mjs +96 -0
  7. package/dist/module.cjs +5 -0
  8. package/dist/module.d.mts +6 -0
  9. package/dist/module.d.ts +6 -0
  10. package/dist/module.json +4 -0
  11. package/dist/module.mjs +36 -0
  12. package/dist/runtime/composables/useStoreLocator.d.ts +9 -0
  13. package/dist/runtime/composables/useStoreLocator.mjs +18 -0
  14. package/dist/{composables → runtime/composables}/useStoreVariantById.d.ts +1 -2
  15. package/dist/runtime/composables/useStoreVariantById.mjs +20 -0
  16. package/dist/runtime/composables/useStores.d.ts +6 -0
  17. package/dist/runtime/composables/useStores.mjs +14 -0
  18. package/dist/runtime/composables/useVariantStores.d.ts +6 -0
  19. package/dist/runtime/composables/useVariantStores.mjs +14 -0
  20. package/dist/{constants → runtime/constants}/httpStatus.d.ts +1 -2
  21. package/dist/runtime/constants/httpStatus.mjs +629 -0
  22. package/dist/runtime/constants/index.d.ts +1 -0
  23. package/dist/runtime/constants/index.mjs +1 -0
  24. package/dist/{error → runtime/error}/errorHandler.d.ts +0 -1
  25. package/dist/runtime/error/errorHandler.mjs +20 -0
  26. package/dist/runtime/handler.d.ts +2 -0
  27. package/dist/runtime/handler.mjs +48 -0
  28. package/dist/runtime/lib/init.d.ts +26 -0
  29. package/dist/runtime/lib/init.mjs +72 -0
  30. package/dist/{rpc → runtime/rpc}/storeLocator.d.ts +4 -11
  31. package/dist/runtime/rpc/storeLocator.mjs +32 -0
  32. package/dist/{types/omnichannel.d.ts → shared/omnichannel-nuxt.9b492196.d.mts} +25 -24
  33. package/dist/shared/omnichannel-nuxt.9b492196.d.ts +146 -0
  34. package/dist/types.d.mts +8 -0
  35. package/dist/types.d.ts +8 -0
  36. package/package.json +42 -17
  37. package/dist/composables/sharedRef.d.ts +0 -3
  38. package/dist/composables/sharedRef.d.ts.map +0 -1
  39. package/dist/composables/sharedRef.js +0 -16
  40. package/dist/composables/sharedRef.js.map +0 -1
  41. package/dist/composables/useGeocode.d.ts +0 -7
  42. package/dist/composables/useGeocode.d.ts.map +0 -1
  43. package/dist/composables/useGeocode.js +0 -17
  44. package/dist/composables/useGeocode.js.map +0 -1
  45. package/dist/composables/useStoreLocator.d.ts +0 -10
  46. package/dist/composables/useStoreLocator.d.ts.map +0 -1
  47. package/dist/composables/useStoreLocator.js +0 -17
  48. package/dist/composables/useStoreLocator.js.map +0 -1
  49. package/dist/composables/useStoreVariantById.d.ts.map +0 -1
  50. package/dist/composables/useStoreVariantById.js +0 -20
  51. package/dist/composables/useStoreVariantById.js.map +0 -1
  52. package/dist/composables/useStores.d.ts +0 -7
  53. package/dist/composables/useStores.d.ts.map +0 -1
  54. package/dist/composables/useStores.js +0 -17
  55. package/dist/composables/useStores.js.map +0 -1
  56. package/dist/composables/useVariantStores.d.ts +0 -7
  57. package/dist/composables/useVariantStores.d.ts.map +0 -1
  58. package/dist/composables/useVariantStores.js +0 -17
  59. package/dist/composables/useVariantStores.js.map +0 -1
  60. package/dist/constants/httpStatus.d.ts.map +0 -1
  61. package/dist/constants/httpStatus.js +0 -634
  62. package/dist/constants/httpStatus.js.map +0 -1
  63. package/dist/constants/index.d.ts +0 -2
  64. package/dist/constants/index.d.ts.map +0 -1
  65. package/dist/constants/index.js +0 -5
  66. package/dist/constants/index.js.map +0 -1
  67. package/dist/constants/omnichannel.d.ts +0 -12
  68. package/dist/constants/omnichannel.d.ts.map +0 -1
  69. package/dist/constants/omnichannel.js +0 -13
  70. package/dist/constants/omnichannel.js.map +0 -1
  71. package/dist/error/errorHandler.d.ts.map +0 -1
  72. package/dist/error/errorHandler.js +0 -27
  73. package/dist/error/errorHandler.js.map +0 -1
  74. package/dist/index.d.ts.map +0 -1
  75. package/dist/index.js +0 -18
  76. package/dist/index.js.map +0 -1
  77. package/dist/lib/init.d.ts +0 -11
  78. package/dist/lib/init.d.ts.map +0 -1
  79. package/dist/lib/init.js +0 -49
  80. package/dist/lib/init.js.map +0 -1
  81. package/dist/module/createOmnichannelHandler.d.ts +0 -3
  82. package/dist/module/createOmnichannelHandler.d.ts.map +0 -1
  83. package/dist/module/createOmnichannelHandler.js +0 -56
  84. package/dist/module/createOmnichannelHandler.js.map +0 -1
  85. package/dist/module/register.d.ts +0 -6
  86. package/dist/module/register.d.ts.map +0 -1
  87. package/dist/module/register.js +0 -12
  88. package/dist/module/register.js.map +0 -1
  89. package/dist/rpc/geocode.d.ts +0 -23
  90. package/dist/rpc/geocode.d.ts.map +0 -1
  91. package/dist/rpc/geocode.js +0 -46
  92. package/dist/rpc/geocode.js.map +0 -1
  93. package/dist/rpc/index.d.ts +0 -3
  94. package/dist/rpc/index.d.ts.map +0 -1
  95. package/dist/rpc/index.js +0 -6
  96. package/dist/rpc/index.js.map +0 -1
  97. package/dist/rpc/storeLocator.d.ts.map +0 -1
  98. package/dist/rpc/storeLocator.js +0 -69
  99. package/dist/rpc/storeLocator.js.map +0 -1
  100. package/dist/types/geocode.d.ts +0 -8
  101. package/dist/types/geocode.d.ts.map +0 -1
  102. package/dist/types/geocode.js +0 -3
  103. package/dist/types/geocode.js.map +0 -1
  104. package/dist/types/index.d.ts +0 -3
  105. package/dist/types/index.d.ts.map +0 -1
  106. package/dist/types/index.js +0 -6
  107. package/dist/types/index.js.map +0 -1
  108. package/dist/types/omnichannel.d.ts.map +0 -1
  109. package/dist/types/omnichannel.js +0 -3
  110. package/dist/types/omnichannel.js.map +0 -1
@@ -1 +0,0 @@
1
- {"version":3,"file":"useGeocode.js","sourceRoot":"","sources":["../../src/composables/useGeocode.ts"],"names":[],"mappings":";;;AAAA,0DAA4C;AAC5C,6DAAkD;AAElD,2CAAuC;AAEvC,kBAAe,CAAC,GAAG,GAAG,YAAY,EAAE,EAAE;IACpC,MAAM,QAAQ,GAAG,IAAA,qBAAS,EAAuB,IAAI,EAAE,GAAG,CAAC,CAAA;IAE3D,MAAM,OAAO,GAAG,KAAK,EACnB,YAA4D,EAC5D,EAAE;QACF,QAAQ,CAAC,KAAK,GAAG,MAAM,eAAK,CAAC,IAAI,CAAC,0BAA0B,EAAE,YAAY,CAAC,CAAA;IAC7E,CAAC,CAAA;IAED,OAAO;QACL,IAAI,EAAE,IAAA,0BAAQ,EAAC,GAAG,EAAE,WAAC,OAAA,MAAA,QAAQ,CAAC,KAAK,0CAAE,IAAI,CAAA,EAAA,CAAC;QAC1C,OAAO;KACR,CAAA;AACH,CAAC,CAAA"}
@@ -1,10 +0,0 @@
1
- declare const _default: (key?: string) => {
2
- storesData: import("vue").ComputedRef<any>;
3
- refreshStores: (searchParams: import("../index").StoreLocatorSearchParams) => Promise<void>;
4
- storeVariantData: import("vue").ComputedRef<any>;
5
- refreshStoreVariant: (variantId: number, storeId: number) => Promise<void>;
6
- variantStoresData: import("vue").ComputedRef<any>;
7
- refreshVariantStores: (searchParams: import("../index").VariantLocatorSearchParams) => Promise<void>;
8
- };
9
- export default _default;
10
- //# sourceMappingURL=useStoreLocator.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"useStoreLocator.d.ts","sourceRoot":"","sources":["../../src/composables/useStoreLocator.ts"],"names":[],"mappings":"+BAEqB,MAAM;;;;;;;;AAA3B,wBAmBC"}
@@ -1,17 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const index_1 = require("../index");
4
- exports.default = (key = 'useStoreLocator') => {
5
- const { data: storesData, getData: refreshStores } = (0, index_1.useStores)(`${key}-stores`);
6
- const { data: variantStoresData, getData: refreshVariantStores } = (0, index_1.useVariantStores)(`${key}-variant-stores`);
7
- const { data: storeVariantData, getData: refreshStoreVariant } = (0, index_1.useStoreVariantById)(`${key}-variant-by-id`);
8
- return {
9
- storesData,
10
- refreshStores,
11
- storeVariantData,
12
- refreshStoreVariant,
13
- variantStoresData,
14
- refreshVariantStores,
15
- };
16
- };
17
- //# sourceMappingURL=useStoreLocator.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"useStoreLocator.js","sourceRoot":"","sources":["../../src/composables/useStoreLocator.ts"],"names":[],"mappings":";;AAAA,oCAA2E;AAE3E,kBAAe,CAAC,MAAc,iBAAiB,EAAE,EAAE;IACjD,MAAM,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAE,aAAa,EAAE,GAAG,IAAA,iBAAS,EAC5D,GAAG,GAAG,SAAS,CAChB,CAAA;IAED,MAAM,EAAE,IAAI,EAAE,iBAAiB,EAAE,OAAO,EAAE,oBAAoB,EAAE,GAC9D,IAAA,wBAAgB,EAAC,GAAG,GAAG,iBAAiB,CAAC,CAAA;IAE3C,MAAM,EAAE,IAAI,EAAE,gBAAgB,EAAE,OAAO,EAAE,mBAAmB,EAAE,GAC5D,IAAA,2BAAmB,EAAC,GAAG,GAAG,gBAAgB,CAAC,CAAA;IAE7C,OAAO;QACL,UAAU;QACV,aAAa;QACb,gBAAgB;QAChB,mBAAmB;QACnB,iBAAiB;QACjB,oBAAoB;KACrB,CAAA;AACH,CAAC,CAAA"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"useStoreVariantById.d.ts","sourceRoot":"","sources":["../../src/composables/useStoreVariantById.ts"],"names":[],"mappings":"+BAGqB,MAAM;;yBAGS,MAAM,WAAW,MAAM;;AAH3D,wBAcC"}
@@ -1,20 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- const axios_1 = tslib_1.__importDefault(require("axios"));
5
- const composition_api_1 = require("@nuxtjs/composition-api");
6
- const sharedRef_1 = require("./sharedRef");
7
- exports.default = (key = 'useStoreVariantById') => {
8
- const response = (0, sharedRef_1.sharedRef)(null, key);
9
- const getData = async (variantId, storeId) => {
10
- response.value = await axios_1.default.post('/api/omnichannel/storeVariantById', {
11
- storeId,
12
- variantId,
13
- });
14
- };
15
- return {
16
- data: (0, composition_api_1.computed)(() => { var _a; return (_a = response.value) === null || _a === void 0 ? void 0 : _a.data; }),
17
- getData,
18
- };
19
- };
20
- //# sourceMappingURL=useStoreVariantById.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"useStoreVariantById.js","sourceRoot":"","sources":["../../src/composables/useStoreVariantById.ts"],"names":[],"mappings":";;;AAAA,0DAA4C;AAC5C,6DAAkD;AAClD,2CAAuC;AACvC,kBAAe,CAAC,MAAc,qBAAqB,EAAE,EAAE;IACrD,MAAM,QAAQ,GAAG,IAAA,qBAAS,EAAuB,IAAI,EAAE,GAAG,CAAC,CAAA;IAE3D,MAAM,OAAO,GAAG,KAAK,EAAE,SAAiB,EAAE,OAAe,EAAE,EAAE;QAC3D,QAAQ,CAAC,KAAK,GAAG,MAAM,eAAK,CAAC,IAAI,CAAC,mCAAmC,EAAE;YACrE,OAAO;YACP,SAAS;SACV,CAAC,CAAA;IACJ,CAAC,CAAA;IAED,OAAO;QACL,IAAI,EAAE,IAAA,0BAAQ,EAAC,GAAG,EAAE,WAAC,OAAA,MAAA,QAAQ,CAAC,KAAK,0CAAE,IAAI,CAAA,EAAA,CAAC;QAC1C,OAAO;KACR,CAAA;AACH,CAAC,CAAA"}
@@ -1,7 +0,0 @@
1
- import { StoreLocatorSearchParams } from '../types';
2
- declare const _default: (key?: string) => {
3
- data: import("@nuxtjs/composition-api").ComputedRef<any>;
4
- getData: (searchParams: StoreLocatorSearchParams) => Promise<void>;
5
- };
6
- export default _default;
7
- //# sourceMappingURL=useStores.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"useStores.d.ts","sourceRoot":"","sources":["../../src/composables/useStores.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,wBAAwB,EAAE,MAAM,UAAU,CAAA;+BAG9B,MAAM;;4BAGY,wBAAwB;;AAH/D,wBAWC"}
@@ -1,17 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- const axios_1 = tslib_1.__importDefault(require("axios"));
5
- const composition_api_1 = require("@nuxtjs/composition-api");
6
- const sharedRef_1 = require("./sharedRef");
7
- exports.default = (key = 'useStores') => {
8
- const response = (0, sharedRef_1.sharedRef)(null, key);
9
- const getData = async (searchParams) => {
10
- response.value = await axios_1.default.post('/api/omnichannel/stores', searchParams);
11
- };
12
- return {
13
- data: (0, composition_api_1.computed)(() => { var _a; return (_a = response.value) === null || _a === void 0 ? void 0 : _a.data; }),
14
- getData,
15
- };
16
- };
17
- //# sourceMappingURL=useStores.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"useStores.js","sourceRoot":"","sources":["../../src/composables/useStores.ts"],"names":[],"mappings":";;;AAAA,0DAA4C;AAC5C,6DAAkD;AAElD,2CAAuC;AAEvC,kBAAe,CAAC,MAAc,WAAW,EAAE,EAAE;IAC3C,MAAM,QAAQ,GAAG,IAAA,qBAAS,EAAuB,IAAI,EAAE,GAAG,CAAC,CAAA;IAE3D,MAAM,OAAO,GAAG,KAAK,EAAE,YAAsC,EAAE,EAAE;QAC/D,QAAQ,CAAC,KAAK,GAAG,MAAM,eAAK,CAAC,IAAI,CAAC,yBAAyB,EAAE,YAAY,CAAC,CAAA;IAC5E,CAAC,CAAA;IAED,OAAO;QACL,IAAI,EAAE,IAAA,0BAAQ,EAAC,GAAG,EAAE,WAAC,OAAA,MAAA,QAAQ,CAAC,KAAK,0CAAE,IAAI,CAAA,EAAA,CAAC;QAC1C,OAAO;KACR,CAAA;AACH,CAAC,CAAA"}
@@ -1,7 +0,0 @@
1
- import { VariantLocatorSearchParams } from '../types';
2
- declare const _default: (key?: string) => {
3
- data: import("@nuxtjs/composition-api").ComputedRef<any>;
4
- getData: (searchParams: VariantLocatorSearchParams) => Promise<void>;
5
- };
6
- export default _default;
7
- //# sourceMappingURL=useVariantStores.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"useVariantStores.d.ts","sourceRoot":"","sources":["../../src/composables/useVariantStores.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,0BAA0B,EAAE,MAAM,UAAU,CAAA;+BAEhC,MAAM;;4BAGY,0BAA0B;;AAHjE,wBAcC"}
@@ -1,17 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("tslib");
4
- const axios_1 = tslib_1.__importDefault(require("axios"));
5
- const composition_api_1 = require("@nuxtjs/composition-api");
6
- const sharedRef_1 = require("./sharedRef");
7
- exports.default = (key = 'useVariantStores') => {
8
- const response = (0, sharedRef_1.sharedRef)(null, key);
9
- const getData = async (searchParams) => {
10
- response.value = await axios_1.default.post('/api/omnichannel/variantStores', searchParams);
11
- };
12
- return {
13
- data: (0, composition_api_1.computed)(() => { var _a; return (_a = response.value) === null || _a === void 0 ? void 0 : _a.data; }),
14
- getData,
15
- };
16
- };
17
- //# sourceMappingURL=useVariantStores.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"useVariantStores.js","sourceRoot":"","sources":["../../src/composables/useVariantStores.ts"],"names":[],"mappings":";;;AAAA,0DAA4C;AAC5C,6DAAkD;AAElD,2CAAuC;AACvC,kBAAe,CAAC,MAAc,kBAAkB,EAAE,EAAE;IAClD,MAAM,QAAQ,GAAG,IAAA,qBAAS,EAAuB,IAAI,EAAE,GAAG,CAAC,CAAA;IAE3D,MAAM,OAAO,GAAG,KAAK,EAAE,YAAwC,EAAE,EAAE;QACjE,QAAQ,CAAC,KAAK,GAAG,MAAM,eAAK,CAAC,IAAI,CAC/B,gCAAgC,EAChC,YAAY,CACb,CAAA;IACH,CAAC,CAAA;IAED,OAAO;QACL,IAAI,EAAE,IAAA,0BAAQ,EAAC,GAAG,EAAE,WAAC,OAAA,MAAA,QAAQ,CAAC,KAAK,0CAAE,IAAI,CAAA,EAAA,CAAC;QAC1C,OAAO;KACR,CAAA;AACH,CAAC,CAAA"}
@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